From 3f41182984d69d7fae703776edd1591f48dff93f Mon Sep 17 00:00:00 2001
From: mac <user@users-MacBook-Pro.local>
Date: 星期三, 22 十一月 2023 17:13:05 +0800
Subject: [PATCH] 2023年11月22日17:12:40
---
app/src/main/java/com/hdl/photovoltaic/ui/account/RegisterAccountActivity.java | 42 +++++++++++++++++++++---------------------
1 files changed, 21 insertions(+), 21 deletions(-)
diff --git a/app/src/main/java/com/hdl/photovoltaic/ui/account/RegisterAccountActivity.java b/app/src/main/java/com/hdl/photovoltaic/ui/account/RegisterAccountActivity.java
index 6da6dac..7dabc0e 100644
--- a/app/src/main/java/com/hdl/photovoltaic/ui/account/RegisterAccountActivity.java
+++ b/app/src/main/java/com/hdl/photovoltaic/ui/account/RegisterAccountActivity.java
@@ -29,7 +29,6 @@
import com.hdl.photovoltaic.widget.ConfirmationCancelDialog;
import com.hdl.photovoltaic.widget.ConfirmationTipDialog;
import com.hdl.photovoltaic.widget.ListDialog;
-import com.hdl.sdk.link.common.utils.ThreadToolUtils;
/**
* 娉ㄥ唽璐﹀彿鐣岄潰
@@ -91,7 +90,7 @@
private void initView() {
- switchPhoneOrMailView();
+ switchPhoneOrEmailStyleView();
}
private void initEvent() {
@@ -112,6 +111,7 @@
public void HDLChina() {
mUrl = "https://china-gateway.hdlcontrol.com";
viewBinding.regionTv.setText(listDialog.geHDLChinaText());
+ listDialog.dismiss();
}
});
@@ -120,6 +120,7 @@
public void HDLBahrain() {
mUrl = "https://bahrain-gateway.hdlcontrol.com";
viewBinding.regionTv.setText(listDialog.getHDLBahrainText());
+ listDialog.dismiss();
}
});
}
@@ -130,7 +131,7 @@
public void onClick(View v) {
isPhoneType = true;
- switchPhoneOrMailView();
+ switchPhoneOrEmailStyleView();
}
});
//鍒囨崲閭
@@ -138,7 +139,7 @@
@Override
public void onClick(View v) {
isPhoneType = false;
- switchPhoneOrMailView();
+ switchPhoneOrEmailStyleView();
}
});
@@ -222,7 +223,7 @@
} else {
verification_code = viewBinding.registerMailVerificationEt.getText().toString();
}
- HdlAccountLogic.getInstance().registerAccount(isPhoneType, account, psw, verification_code, new CloudCallBeak<Boolean>() {
+ HdlAccountLogic.getInstance().registerAccount_C(isPhoneType, account, psw, verification_code, new CloudCallBeak<Boolean>() {
@Override
public void onSuccess(Boolean obj) {
HdlThreadLogic.runMainThread(new Runnable() {
@@ -271,9 +272,8 @@
HdlAccountLogic.getInstance().regionByAccount(account, new CloudCallBeak<HDLUserRegionBean>() {
@Override
public void onSuccess(HDLUserRegionBean obj) {
- //鍙戦�佹秷鎭獙璇佺爜
HdlThreadLogic.toast(RegisterAccountActivity.this, getString(R.string.home_login_already_exists));
- HdlLogLogic.print("regionByAccount onSuccess==" + obj);
+ HdlLogLogic.print("鑾峰彇璐﹀彿鍖哄煙淇℃伅===" + obj, false);
}
@Override
@@ -318,7 +318,7 @@
long time = (millisUntilFinished / 1000);
String str = time + "s" + getString(R.string.home_login_psw_verification_repeater);
viewBinding.registerPhoneVerificationTv.setText(str);
- viewBinding.registerPhoneVerificationTv.setTextColor(getResources().getColor(R.color.text_25000000));
+ viewBinding.registerPhoneVerificationTv.setTextColor(getResources().getColor(R.color.text_25000000, null));
viewBinding.registerPhoneVerificationTv.setEnabled(false);
}
@@ -326,7 +326,7 @@
@Override
public void onFinish() {
viewBinding.registerPhoneVerificationTv.setText(getString(R.string.home_login_verification_regain));
- viewBinding.registerPhoneVerificationTv.setTextColor(getResources().getColor(R.color.text_245EC3));
+ viewBinding.registerPhoneVerificationTv.setTextColor(getResources().getColor(R.color.text_245EC3, null));
viewBinding.registerPhoneVerificationTv.setEnabled(true);
@@ -342,7 +342,7 @@
String str = time + "s" + getString(R.string.home_login_psw_verification_repeater);
viewBinding.registerMailVerificationTv.setText(str);
- viewBinding.registerMailVerificationTv.setTextColor(getResources().getColor(R.color.text_25000000));
+ viewBinding.registerMailVerificationTv.setTextColor(getResources().getColor(R.color.text_25000000, null));
viewBinding.registerMailVerificationTv.setEnabled(false);
}
@@ -350,7 +350,7 @@
@Override
public void onFinish() {
viewBinding.registerMailVerificationTv.setText(getString(R.string.home_login_verification_regain));
- viewBinding.registerMailVerificationTv.setTextColor(getResources().getColor(R.color.text_245EC3));
+ viewBinding.registerMailVerificationTv.setTextColor(getResources().getColor(R.color.text_245EC3, null));
viewBinding.registerMailVerificationTv.setEnabled(true);
}
@@ -359,22 +359,22 @@
/**
* 鍒囨崲鎵嬫満鍙锋垨鑰呴偖绠辩殑鏍峰紡
*/
- private void switchPhoneOrMailView() {
+ private void switchPhoneOrEmailStyleView() {
if (isPhoneType) {
//鎵嬫満鍙�
- viewBinding.registerPhoneTitleIc.accountTitleTv.setText(R.string.home_login_鎵嬫満鍙�);
+ viewBinding.registerPhoneTitleIc.accountTitleTv.setText(R.string.home_login_phone);
viewBinding.registerPhoneTitleIc.accountTitleTv.setTextSize(20);
- viewBinding.registerPhoneTitleIc.accountTitleTv.setTextColor(getResources().getColor(R.color.text_90000000));
+ viewBinding.registerPhoneTitleIc.accountTitleTv.setTextColor(getResources().getColor(R.color.text_90000000, null));
viewBinding.registerPhoneTitleIc.lineV.setVisibility(View.VISIBLE);
- viewBinding.registerMailTitleIc.accountTitleTv.setText(R.string.home_login_閭);
+ viewBinding.registerMailTitleIc.accountTitleTv.setText(R.string.home_login_email);
viewBinding.registerMailTitleIc.accountTitleTv.setTextSize(16);
- viewBinding.registerMailTitleIc.accountTitleTv.setTextColor(getResources().getColor(R.color.text_40000000));
+ viewBinding.registerMailTitleIc.accountTitleTv.setTextColor(getResources().getColor(R.color.text_40000000, null));
viewBinding.registerMailTitleIc.lineV.setVisibility(View.GONE);
//杈撳叆鎵嬫満鍙�
viewBinding.registerAccountEt.setInputType(InputType.TYPE_CLASS_NUMBER);
- viewBinding.registerAccountEt.setHint(R.string.home_login_璇疯緭鍏ユ墜鏈哄彿);
+ viewBinding.registerAccountEt.setHint(R.string.home_login_input_phone);
//鏄剧ず鎵嬫満鍙烽獙璇佺爜锛岄殣钘忛偖绠遍獙璇佺爜,
viewBinding.registerPhoneVerificationCodeRl.setVisibility(View.VISIBLE);
viewBinding.registerMailVerificationCodeRl.setVisibility(View.GONE);
@@ -392,14 +392,14 @@
} else {
//閭
- viewBinding.registerPhoneTitleIc.accountTitleTv.setText(R.string.home_login_鎵嬫満鍙�);
+ viewBinding.registerPhoneTitleIc.accountTitleTv.setText(R.string.home_login_phone);
viewBinding.registerPhoneTitleIc.accountTitleTv.setTextSize(16);
- viewBinding.registerPhoneTitleIc.accountTitleTv.setTextColor(getResources().getColor(R.color.text_40000000));
+ viewBinding.registerPhoneTitleIc.accountTitleTv.setTextColor(getResources().getColor(R.color.text_40000000, null));
viewBinding.registerPhoneTitleIc.lineV.setVisibility(View.GONE);
- viewBinding.registerMailTitleIc.accountTitleTv.setText(R.string.home_login_閭);
+ viewBinding.registerMailTitleIc.accountTitleTv.setText(R.string.home_login_email);
viewBinding.registerMailTitleIc.accountTitleTv.setTextSize(20);
- viewBinding.registerMailTitleIc.accountTitleTv.setTextColor(getResources().getColor(R.color.text_90000000));
+ viewBinding.registerMailTitleIc.accountTitleTv.setTextColor(getResources().getColor(R.color.text_90000000, null));
viewBinding.registerMailTitleIc.lineV.setVisibility(View.VISIBLE);
//杈撳叆閭
viewBinding.registerAccountEt.setInputType(InputType.TYPE_CLASS_TEXT);
--
Gitblit v1.8.0