public static final String IFCODE1004 = "1004"; //统一门户账号密码登录 | public static final String IFCODE1004 = "1004"; //统一门户账号密码登录 | ||||
public static final String IFCODE1005 = "1005"; //统一门户手机号验证码登录 | public static final String IFCODE1005 = "1005"; //统一门户手机号验证码登录 | ||||
public static final String IFCODE1006 = "1006"; //登录确认(获取Access-Token) | public static final String IFCODE1006 = "1006"; //登录确认(获取Access-Token) | ||||
public static final String IFCODETOKEN = "2b9345f4bf234719ab6830c94e7e2a6f"; //异地 Token) | |||||
public static final String IFCODE1009 = "1009"; //修改密码 | public static final String IFCODE1009 = "1009"; //修改密码 | ||||
public static final String IFCODE_ACTIVE_OBUIMG = "4a95e1d90e824ee8a50aa9826617e736"; //设备激活照片上传 | public static final String IFCODE_ACTIVE_OBUIMG = "4a95e1d90e824ee8a50aa9826617e736"; //设备激活照片上传 | ||||
public static final String IFCODE_ADD_OBU = "837c22e80fa34506a0855306d9cbb6f7"; //增补OBU | public static final String IFCODE_ADD_OBU = "837c22e80fa34506a0855306d9cbb6f7"; //增补OBU |
new Utils().showMessDialog(YDPlatformNewlyStep2Activity.this, plateNumber+"已在统一平台办理"); | new Utils().showMessDialog(YDPlatformNewlyStep2Activity.this, plateNumber+"已在统一平台办理"); | ||||
break; | break; | ||||
case "3": | case "3": | ||||
new Utils().showMessDialog(YDPlatformNewlyStep2Activity.this, null!=linkedTreeMap.get("info").toString() ? linkedTreeMap.get("info").toString() : "未关联"); | |||||
new Utils().showMessDialog(YDPlatformNewlyStep2Activity.this, | |||||
null!=linkedTreeMap.get("info").toString() ? linkedTreeMap.get("info").toString() : "未关联"); | |||||
break; | break; | ||||
case "4": | case "4": | ||||
checkUserAccountList(); | checkUserAccountList(); | ||||
MyRetrofit.ydNewInstance(this, true,"", params, new MyRetrofit.ReturnResult() { | MyRetrofit.ydNewInstance(this, true,"", params, new MyRetrofit.ReturnResult() { | ||||
@Override | @Override | ||||
public void onSuccess(ResultBean resultBean, ResultBean.BizContent bizContent) { | public void onSuccess(ResultBean resultBean, ResultBean.BizContent bizContent) { | ||||
LinkedTreeMap<String,Object> linkedTreeMap = JSONObject.parseObject(resultBean.getBizContent().toString(),LinkedTreeMap.class); | |||||
List<ResultBean.BizContent> dataList = (List<ResultBean.BizContent>) JSON.parseArray(linkedTreeMap.get("data").toString(),ResultBean.BizContent.class); | |||||
LinkedTreeMap<String,Object> linkedTreeMap = | |||||
JSONObject.parseObject(resultBean.getBizContent().toString(),LinkedTreeMap.class); | |||||
List<ResultBean.BizContent> dataList = (List<ResultBean.BizContent>) | |||||
JSON.parseArray(linkedTreeMap.get("data").toString(),ResultBean.BizContent.class); | |||||
if (null!=dataList&&dataList.size()>0){//存在账户直接去车辆信息上传,行驶证认证 | if (null!=dataList&&dataList.size()>0){//存在账户直接去车辆信息上传,行驶证认证 | ||||
List<ResultBean.BizContent> list = dataList; | List<ResultBean.BizContent> list = dataList; | ||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N) { | if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N) { | ||||
list = list.stream().filter(item->item.accountType.equals(getIntent().getStringExtra("userType"))).collect(Collectors.toList()); | list = list.stream().filter(item->item.accountType.equals(getIntent().getStringExtra("userType"))).collect(Collectors.toList()); | ||||
}else { | |||||
} else { | |||||
for (int i = 0; i < list.size(); i++) { | for (int i = 0; i < list.size(); i++) { | ||||
if (!list.get(i).accountType.equals(getIntent().getStringExtra("userType"))){ | if (!list.get(i).accountType.equals(getIntent().getStringExtra("userType"))){ | ||||
list.remove(i); | list.remove(i); | ||||
} | } | ||||
if (list.size()>0){//存在对应类型的账户 | if (list.size()>0){//存在对应类型的账户 | ||||
MyShared.getInstance().put(MyShared.YDACCOUNTID,list.get(0).accountId); | MyShared.getInstance().put(MyShared.YDACCOUNTID,list.get(0).accountId); | ||||
//车辆信息上传页面 | |||||
Intent intent = new Intent(YDPlatformNewlyStep2Activity.this, YDPlatformNewlyStep4Activity.class); | Intent intent = new Intent(YDPlatformNewlyStep2Activity.this, YDPlatformNewlyStep4Activity.class); | ||||
intent.putExtra("type",getIntent().getStringExtra("type"));//1客车 2货车 | intent.putExtra("type",getIntent().getStringExtra("type"));//1客车 2货车 | ||||
intent.putExtra("userType",getIntent().getStringExtra("userType"));//1个人 2企业 | intent.putExtra("userType",getIntent().getStringExtra("userType"));//1个人 2企业 | ||||
intent.putExtra("plateColor",plateColor); | intent.putExtra("plateColor",plateColor); | ||||
startActivity(intent); | startActivity(intent); | ||||
}else {//不存在对应类型的账户 | }else {//不存在对应类型的账户 | ||||
//用户信息上传页面 | |||||
Intent intent = new Intent(YDPlatformNewlyStep2Activity.this, YDPlatformNewlyStep3Activity.class); | Intent intent = new Intent(YDPlatformNewlyStep2Activity.this, YDPlatformNewlyStep3Activity.class); | ||||
intent.putExtra("type",getIntent().getStringExtra("type")); | intent.putExtra("type",getIntent().getStringExtra("type")); | ||||
intent.putExtra("userType",getIntent().getStringExtra("userType")); | intent.putExtra("userType",getIntent().getStringExtra("userType")); |
import com.alibaba.fastjson.JSONObject; | import com.alibaba.fastjson.JSONObject; | ||||
import com.bumptech.glide.Glide; | import com.bumptech.glide.Glide; | ||||
import com.google.gson.internal.LinkedTreeMap; | import com.google.gson.internal.LinkedTreeMap; | ||||
import com.hjq.base.BaseDialog; | |||||
import com.huntersun.vkyes.etcopencard.R; | import com.huntersun.vkyes.etcopencard.R; | ||||
import com.huntersun.vkyes.etcopencard.databinding.ActivityYdplatformNewlyStep4Binding; | import com.huntersun.vkyes.etcopencard.databinding.ActivityYdplatformNewlyStep4Binding; | ||||
import com.huntersun.vkyes.etcopencard.project.api.MyRetrofit; | import com.huntersun.vkyes.etcopencard.project.api.MyRetrofit; | ||||
import com.huntersun.vkyes.etcopencard.src.http.glide.GlideApp; | import com.huntersun.vkyes.etcopencard.src.http.glide.GlideApp; | ||||
import com.huntersun.vkyes.etcopencard.src.ui.dialog.DateDialog; | import com.huntersun.vkyes.etcopencard.src.ui.dialog.DateDialog; | ||||
import com.huntersun.vkyes.etcopencard.src.ui.dialog.MenuDialog; | import com.huntersun.vkyes.etcopencard.src.ui.dialog.MenuDialog; | ||||
import com.huntersun.vkyes.etcopencard.src.ui.dialog.MessageDialog; | |||||
import com.parkingwang.keyboard.OnInputChangedListener; | import com.parkingwang.keyboard.OnInputChangedListener; | ||||
import com.parkingwang.keyboard.PopupKeyboard; | import com.parkingwang.keyboard.PopupKeyboard; | ||||
import com.parkingwang.keyboard.view.callback; | |||||
import java.io.File; | import java.io.File; | ||||
import java.util.Arrays; | import java.util.Arrays; | ||||
} | } | ||||
private void initRadioView() { | private void initRadioView() { | ||||
binding.radioGroup.setOnCheckedChangeListener(new RadioGroup.OnCheckedChangeListener() { | |||||
@Override | |||||
public void onCheckedChanged(RadioGroup radioGroup, int i) {//是否牵引车 | |||||
switch (i) { | |||||
case R.id.rb_1: | |||||
isQY = 1; | |||||
binding.layout5.setVisibility(View.VISIBLE); | |||||
break; | |||||
case R.id.rb_2: | |||||
isQY = 0; | |||||
binding.layout5.setVisibility(View.GONE); | |||||
break; | |||||
} | |||||
binding.radioGroup.setOnCheckedChangeListener((radioGroup, i) -> {//是否牵引车 | |||||
switch (i) { | |||||
case R.id.rb_1: | |||||
isQY = 1; | |||||
binding.layout5.setVisibility(View.VISIBLE); | |||||
break; | |||||
case R.id.rb_2: | |||||
isQY = 0; | |||||
binding.layout5.setVisibility(View.GONE); | |||||
break; | |||||
} | } | ||||
}); | }); | ||||
} | } | ||||
// } | // } | ||||
// }); | // }); | ||||
// } else {//行驶证识别 | // } else {//行驶证识别 | ||||
String type = ""; | |||||
file1 = FileUtil.getSaveFile(getApplication()).getAbsolutePath(); | |||||
if (view == binding.image1) { | |||||
type = CameraActivity.CONTENT_TYPE_BANK_CARD; | |||||
} else { | |||||
type = CameraActivity.CONTENT_TYPE_BANK_BACK; | |||||
} | |||||
HashMap<String, String> params = new HashMap<>(); | |||||
params.put("filename", YdCode.YDCODE_OCR_CAR_LICENSE); | |||||
params.put("side", view == binding.image1 ? "1" : "2");//1正,2反 | |||||
FileUtils.getInstance(this).uploadOcrDrivingLicenseNewYD(true, type, file1, params, new FileUtils.OnOcrUploadCallback2() { | |||||
@Override | |||||
public void onSuccess(ResultBean.BizContent bizContent, File file) { | |||||
if (view == binding.image1){ | |||||
imgUrl1 = file.getAbsolutePath(); | |||||
GlideApp.with(getActivity()).load(file).into(binding.image1); | |||||
}else { | |||||
imgUrl2 = file.getAbsolutePath(); | |||||
GlideApp.with(getActivity()).load(file).into(binding.image2); | |||||
} | |||||
updateView(bizContent, view); | |||||
String type = ""; | |||||
file1 = FileUtil.getSaveFile(getApplication()).getAbsolutePath(); | |||||
if (view == binding.image1) { | |||||
type = CameraActivity.CONTENT_TYPE_BANK_CARD; | |||||
} else { | |||||
type = CameraActivity.CONTENT_TYPE_BANK_BACK; | |||||
} | |||||
HashMap<String, String> params = new HashMap<>(); | |||||
params.put("filename", YdCode.YDCODE_OCR_CAR_LICENSE); | |||||
params.put("side", view == binding.image1 ? "1" : "2");//1正,2反 | |||||
FileUtils.getInstance(this).uploadOcrDrivingLicenseNewYD(true, type, file1, params, new FileUtils.OnOcrUploadCallback2() { | |||||
@Override | |||||
public void onSuccess(ResultBean.BizContent bizContent, File file) { | |||||
if (view == binding.image1) { | |||||
imgUrl1 = file.getAbsolutePath(); | |||||
GlideApp.with(getActivity()).load(file).into(binding.image1); | |||||
} else { | |||||
imgUrl2 = file.getAbsolutePath(); | |||||
GlideApp.with(getActivity()).load(file).into(binding.image2); | |||||
} | } | ||||
}); | |||||
updateView(bizContent, view); | |||||
} | |||||
}); | |||||
// } | // } | ||||
} | } | ||||
params.put("type", "1".equals(getIntent().getStringExtra("userType")) ? ("1".equals(getIntent().getStringExtra("type")) ? "1" : "2") : ("1".equals(getIntent().getStringExtra("type")) ? "3" : "4")); | params.put("type", "1".equals(getIntent().getStringExtra("userType")) ? ("1".equals(getIntent().getStringExtra("type")) ? "1" : "2") : ("1".equals(getIntent().getStringExtra("type")) ? "3" : "4")); | ||||
params.put("productId", getIntent().getStringExtra("productId")); | params.put("productId", getIntent().getStringExtra("productId")); | ||||
params.put("encryptedData", JSONObject.toJSONString(encryptedData)); | params.put("encryptedData", JSONObject.toJSONString(encryptedData)); | ||||
params.put("staffId",MyShared.getInstance().get(MyShared.OPENID,"")+""); | |||||
params.put("staffId", MyShared.getInstance().get(MyShared.OPENID, "") + ""); | |||||
params.put("filename", YdCode.YDCODE_CAR_LICENSE_ISSUE); | params.put("filename", YdCode.YDCODE_CAR_LICENSE_ISSUE); | ||||
MyRetrofit.ydNewInstance(YDPlatformNewlyStep4Activity.this, true, "", params, new MyRetrofit.ReturnResult() { | MyRetrofit.ydNewInstance(YDPlatformNewlyStep4Activity.this, true, "", params, new MyRetrofit.ReturnResult() { | ||||
@Override | @Override | ||||
intent.setClass(YDPlatformNewlyStep4Activity.this, YDPlatformNewlyStep6Activity.class); | intent.setClass(YDPlatformNewlyStep4Activity.this, YDPlatformNewlyStep6Activity.class); | ||||
} | } | ||||
} else {//车主不一致 | } else {//车主不一致 | ||||
intent.setClass(YDPlatformNewlyStep4Activity.this, YDPlatformNewlyStep5Activity.class); | |||||
// intent.setClass(YDPlatformNewlyStep4Activity.this, YDPlatformNewlyStep5Activity.class); | |||||
// 消息对话框 | |||||
new MessageDialog.Builder(YDPlatformNewlyStep4Activity.this) | |||||
// 标题可以不用填写 | |||||
.setTitle("提示") | |||||
.setCanceledOnTouchOutside(false) | |||||
.setCancel("上传企业证") | |||||
.setConfirm("上传身份证") | |||||
// 内容必须要填写 | |||||
.setMessage("车主身份信息与行驶证所有人信息不一致,请选择上传车主身份证或当前行驶证企业证件") | |||||
.setListener(new MessageDialog.OnListener() { | |||||
@Override | |||||
public void onConfirm(BaseDialog dialog) { | |||||
Intent intent = new Intent(YDPlatformNewlyStep4Activity.this, YDPlatformNewlyStep3Activity.class); | |||||
intent.putExtra("type", getIntent().getStringExtra("type"));//1客车 2货车 | |||||
intent.putExtra("userType", "2");//1个人 2企业 | |||||
intent.putExtra("productId", getIntent().getStringExtra("productId")); | |||||
intent.putExtra("vehicleId", linkedTreeMap.get("vehicleId").toString()); | |||||
intent.putExtra("plateNum", getIntent().getStringExtra("plateNum")); | |||||
intent.putExtra("plateColor", getIntent().getStringExtra("plateColor")); | |||||
startActivity(intent); | |||||
} | |||||
@Override | |||||
public void onCancel(BaseDialog dialog) { | |||||
Intent intent = new Intent(YDPlatformNewlyStep4Activity.this, YDPlatformNewlyStep3Activity.class); | |||||
intent.putExtra("type", getIntent().getStringExtra("type"));//1客车 2货车 | |||||
intent.putExtra("userType", "1");//1个人 2企业 | |||||
intent.putExtra("productId", getIntent().getStringExtra("productId")); | |||||
intent.putExtra("vehicleId", linkedTreeMap.get("vehicleId").toString()); | |||||
intent.putExtra("plateNum", getIntent().getStringExtra("plateNum")); | |||||
intent.putExtra("plateColor", getIntent().getStringExtra("plateColor")); | |||||
startActivity(intent); | |||||
} | |||||
}) | |||||
.show(); | |||||
} | } | ||||
intent.putExtra("userType", getIntent().getStringExtra("userType"));//1个人 2企业 | intent.putExtra("userType", getIntent().getStringExtra("userType"));//1个人 2企业 | ||||
intent.putExtra("type", getIntent().getStringExtra("type"));//1客车 2货车 | intent.putExtra("type", getIntent().getStringExtra("type"));//1客车 2货车 | ||||
intent.putExtra("plateNum",getIntent().getStringExtra("plateNum")); | |||||
intent.putExtra("plateColor",getIntent().getStringExtra("plateColor")); | |||||
intent.putExtra("productId",getIntent().getStringExtra("productId")); | |||||
intent.putExtra("plateNum", getIntent().getStringExtra("plateNum")); | |||||
intent.putExtra("plateColor", getIntent().getStringExtra("plateColor")); | |||||
intent.putExtra("productId", getIntent().getStringExtra("productId")); | |||||
intent.putExtra("vehicleId", linkedTreeMap.get("vehicleId").toString()); | intent.putExtra("vehicleId", linkedTreeMap.get("vehicleId").toString()); | ||||
startActivity(intent); | startActivity(intent); | ||||
finish(); | finish(); | ||||
} else if ("2".equals(linkedTreeMap.get("result").toString())) { | } else if ("2".equals(linkedTreeMap.get("result").toString())) { | ||||
new Utils().showMessDialog(YDPlatformNewlyStep4Activity.this, "认证不通过"); | new Utils().showMessDialog(YDPlatformNewlyStep4Activity.this, "认证不通过"); | ||||
} | } | ||||
} | } | ||||
}); | }); |
import android.app.Activity; | import android.app.Activity; | ||||
import android.content.Context; | import android.content.Context; | ||||
import android.content.Intent; | import android.content.Intent; | ||||
import android.os.Bundle; | |||||
import android.util.Log; | import android.util.Log; | ||||
import com.alibaba.fastjson.JSONObject; | import com.alibaba.fastjson.JSONObject; | ||||
import com.google.gson.internal.LinkedTreeMap; | import com.google.gson.internal.LinkedTreeMap; | ||||
import com.hjq.base.BaseDialog; | |||||
import com.huntersun.vkyes.etcopencard.R; | |||||
import com.huntersun.vkyes.etcopencard.project.api.MyRetrofit; | import com.huntersun.vkyes.etcopencard.project.api.MyRetrofit; | ||||
import com.huntersun.vkyes.etcopencard.project.api.bean.IFCode; | |||||
import com.huntersun.vkyes.etcopencard.project.api.bean.ResultBean; | import com.huntersun.vkyes.etcopencard.project.api.bean.ResultBean; | ||||
import com.huntersun.vkyes.etcopencard.project.tool.MyShared; | import com.huntersun.vkyes.etcopencard.project.tool.MyShared; | ||||
import com.huntersun.vkyes.etcopencard.project.ui.activity.MainActivity; | |||||
import com.huntersun.vkyes.etcopencard.project.ui.activity.RealUserAuthenticationActivity; | |||||
import com.huntersun.vkyes.etcopencard.project.ui.activity.ydplatform.YDPlatformLoginActivity; | import com.huntersun.vkyes.etcopencard.project.ui.activity.ydplatform.YDPlatformLoginActivity; | ||||
import com.huntersun.vkyes.etcopencard.project.ui.activity.ydplatform.util.MD5Utils; | import com.huntersun.vkyes.etcopencard.project.ui.activity.ydplatform.util.MD5Utils; | ||||
import com.huntersun.vkyes.etcopencard.project.ui.activity.ydplatform.ydCode.YdCode; | import com.huntersun.vkyes.etcopencard.project.ui.activity.ydplatform.ydCode.YdCode; | ||||
import com.huntersun.vkyes.etcopencard.src.ui.dialog.MessageDialog; | |||||
import java.io.IOException; | import java.io.IOException; | ||||
import java.nio.charset.Charset; | import java.nio.charset.Charset; | ||||
import java.util.HashMap; | import java.util.HashMap; | ||||
import java.util.Map; | |||||
import okhttp3.FormBody; | import okhttp3.FormBody; | ||||
import okhttp3.Interceptor; | import okhttp3.Interceptor; | ||||
MyShared.getInstance().put(MyShared.YDTOKEN,linkedTreeMap.get("token")); | MyShared.getInstance().put(MyShared.YDTOKEN,linkedTreeMap.get("token")); | ||||
} | } | ||||
}); | }); | ||||
// Map<String, String> params = new HashMap<>(); | |||||
// MyRetrofit.newInstance(IFCode.IFCODETOKEN, params, new MyRetrofit.ReturnResult() { | |||||
// @Override | |||||
// public void onSuccess(ResultBean resultBean, ResultBean.BizContent bizContent) { | |||||
// LinkedTreeMap<String,String> linkedTreeMap = JSONObject.parseObject(resultBean.getBizContent().toString(),LinkedTreeMap.class); | |||||
// Log.e("okhttp","打印标题:" + linkedTreeMap.get("token") ); | |||||
// MyShared.getInstance().put(MyShared.YDTOKEN,linkedTreeMap.get("token")); | |||||
// } | |||||
// @Override | |||||
// public void onError() {} | |||||
// }); | |||||
}else if (linkedTreeMap != null && "4000".equals(linkedTreeMap.get("statusCode") + "")){ | }else if (linkedTreeMap != null && "4000".equals(linkedTreeMap.get("statusCode") + "")){ | ||||
Intent intent = new Intent(context, YDPlatformLoginActivity.class); | Intent intent = new Intent(context, YDPlatformLoginActivity.class); | ||||
intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK); | intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK); |
import android.widget.LinearLayout; | import android.widget.LinearLayout; | ||||
import android.widget.TextView; | import android.widget.TextView; | ||||
import com.alibaba.fastjson.JSONObject; | |||||
import com.google.gson.Gson; | import com.google.gson.Gson; | ||||
import com.google.gson.internal.LinkedTreeMap; | |||||
import com.gyf.immersionbar.ImmersionBar; | import com.gyf.immersionbar.ImmersionBar; | ||||
import com.hjq.base.BaseDialog; | import com.hjq.base.BaseDialog; | ||||
import com.hjq.umeng.UmengClient; | import com.hjq.umeng.UmengClient; | ||||
MyShared.getInstance().put(MyShared.CHANNELID, bizContent.serviceHallId); | MyShared.getInstance().put(MyShared.CHANNELID, bizContent.serviceHallId); | ||||
MyShared.getInstance().put(MyShared.STAFFID, bizContent.getStaffId()); | MyShared.getInstance().put(MyShared.STAFFID, bizContent.getStaffId()); | ||||
// 跳转到首页 | |||||
if ("1".equals(bizContent.realNameAuthentication)){ | |||||
new MessageDialog.Builder(getActivity()) | |||||
// 内容必须要填写 | |||||
.setMessage("需要实名认证后才可登录") | |||||
// 确定按钮文本 | |||||
.setConfirm(getString(R.string.common_confirm)) | |||||
// 设置 null 表示不显示取消按钮 | |||||
.setCancel(getString(R.string.common_cancel)) | |||||
// 设置点击按钮后不关闭对话框 | |||||
//.setAutoDismiss(false) | |||||
.setListener(new MessageDialog.OnListener() { | |||||
@Override | |||||
public void onConfirm(BaseDialog dialog) { | |||||
Bundle bundle = new Bundle(); | |||||
bundle.putString("source","0");//0未实名跳转 1手机号更改跳转 | |||||
jumpToPage(RealUserAuthenticationActivity.class,bundle); | |||||
postDelayed(() -> { | |||||
mCommitView.showError(1000); | |||||
}, 1000); | |||||
} | |||||
@Override | |||||
public void onCancel(BaseDialog dialog) { | |||||
postDelayed(() -> { | |||||
mCommitView.showError(1000); | |||||
}, 1000); | |||||
} | |||||
}) | |||||
.show(); | |||||
}else { | |||||
MainActivity.start(getContext()); | |||||
finish(); | |||||
} | |||||
// Map<String, String> params = new HashMap<>(); | |||||
// MyRetrofit.newInstance(this,IFCode.IFCODETOKEN, params, new MyRetrofit.ReturnResult() { | |||||
// @Override | |||||
// public void onSuccess(ResultBean resultBean, ResultBean.BizContent bizContent) { | |||||
// LinkedTreeMap<String,String> linkedTreeMap = JSONObject.parseObject(resultBean.getBizContent().toString(),LinkedTreeMap.class);;; | |||||
// | |||||
// Log.e("okhttp","打印标题:" + linkedTreeMap.get("token") ); | |||||
// MyShared.getInstance().put(MyShared.YDTOKEN,linkedTreeMap.get("token")); | |||||
// 跳转到首页 | |||||
if ("1".equals(bizContent.realNameAuthentication)){ | |||||
new MessageDialog.Builder(getActivity()) | |||||
// 内容必须要填写 | |||||
.setMessage("需要实名认证后才可登录") | |||||
// 确定按钮文本 | |||||
.setConfirm(getString(R.string.common_confirm)) | |||||
// 设置 null 表示不显示取消按钮 | |||||
.setCancel(getString(R.string.common_cancel)) | |||||
// 设置点击按钮后不关闭对话框 | |||||
//.setAutoDismiss(false) | |||||
.setListener(new MessageDialog.OnListener() { | |||||
@Override | |||||
public void onConfirm(BaseDialog dialog) { | |||||
Bundle bundle = new Bundle(); | |||||
bundle.putString("source","0");//0未实名跳转 1手机号更改跳转 | |||||
jumpToPage(RealUserAuthenticationActivity.class,bundle); | |||||
postDelayed(() -> { | |||||
mCommitView.showError(1000); | |||||
}, 1000); | |||||
} | |||||
@Override | |||||
public void onCancel(BaseDialog dialog) { | |||||
postDelayed(() -> { | |||||
mCommitView.showError(1000); | |||||
}, 1000); | |||||
} | |||||
}) | |||||
.show(); | |||||
}else { | |||||
MainActivity.start(getContext()); | |||||
finish(); | |||||
} | |||||
// } | |||||
// | |||||
// @Override | |||||
// public void onError() {} | |||||
// }); | |||||
} | } | ||||
/* | /* |