private void authenticate() {
String name = et_name.getText().toString().trim();
String id = et_id.getText().toString().trim();
//Only the second generation ID card is allowed to enter: 18 digits, the last digit may be a letter or a number. But the second generation ID card must be 18 digits
if (TextUtils.isEmpty(name) || !MShareUtil.isIDLegal(id)) {
ToastUtil.toast("Please check whether the input is legal");
return;
}
/* LoginResultBean currentProcessingUser = (this).queryCurrentProcessingUser();
int verificationState = ();
if(verificationState==1)
ToastUtil.toast_debug("verification_state is true.*_*");
else
ToastUtil.toast_debug("verification_state is false.*<>*");
//Do two ways to determine whether to open the deposit page: 1. Home page 2. Deposit page
Intent intent=new Intent();
if (() == 1 && () == 1) {//If the deposit page is opened (this,);
} else {
(this, );
}
startActivity(intent);
overridePendingTransition(.global_in, 0);
finish();*/
if (httpUtil == null)
httpUtil = new HttpUtil();
UserDao userDao = UserDao.getDaoInstance(this);
LoginResultBean currentUser = ();
String phoneNumber = ();
String[] params = new String[]{Constants.AppID, GlobalConfig.AppID,Constants.ECID, GlobalConfig.ECID, Constants.PhoneNumber, phoneNumber,
Constants.RealName, name, Constants.ID, id, Constants.AppType, GlobalConfig.AppType};
httpUtil.callJson(handler, this, GlobalConfig.MSHARE_SERVER_ROOT + GlobalConfig.MSHARE_VERIFY_NUMBER_OF_ID_CARD,
BaseResultBean.class, params);
}
@Override
protected void getMessage(Message msg) {
BaseResultBean result = (BaseResultBean) msg.obj;
if (result != null && ()) {
boolean update_result = UserDao.getDaoInstance(this).updateVerificationState();
ToastUtil.toast_debug("Verification Successfully"+ (update_result ?"true":"false"));
LoginResultBean currentProcessingUser = UserDao.getDaoInstance(this).queryCurrentProcessingUser();
int verificationState = ();
if(verificationState==1)
ToastUtil.toast_debug("verification_state is true.*_*");
else
ToastUtil.toast_debug("verification_state is false.*<>*");
//Do two ways to determine whether to open the deposit page: 1. Home page 2. Deposit page
Intent intent=new Intent();
if (() == 1 && () == 1) {//If the deposit page is opened (this,DepositActivity.class);
} else {
(this, MainActivity.class);
}
startActivity(intent);
overridePendingTransition(.global_in, 0);
finish();
} else {
ToastUtil.toast("Verification failed, please re-verify");
}
}