huyuguo 4 ans auparavant
Parent
commit
5c68143e90

+ 2 - 4
app/src/main/java/com/electric/chargingpile/activity/LoginActivity.java

@ -60,7 +60,7 @@ public class LoginActivity extends Activity implements View.OnClickListener {
60 60
    String encode_token;
61 61
    Context mContext;
62 62
    public static final int RESULT_SUCCESS = 0;
63
    private Boolean flag = true;
63
    private Boolean flag = false;
64 64
65 65
    public void createDialog() {
66 66
        if (pd_info == null) {
@ -281,9 +281,7 @@ public class LoginActivity extends Activity implements View.OnClickListener {
281 281
            Toast.makeText(this, "手机号码错误,您输入的是一个无效手机号码", Toast.LENGTH_SHORT).show();
282 282
            return;
283 283
        } else if (!flag) {
284
            Toast.makeText(this, "请勾选协议与隐私政策", Toast.LENGTH_SHORT).show();
285
            login.setEnabled(false);
286
            login.setBackgroundResource(R.drawable.textview_1green);
284
            Toast.makeText(this, "请阅读并同意相关协议", Toast.LENGTH_SHORT).show();
287 285
        } else {
288 286
            createDialog();
289 287
            getUserInfo();

+ 2 - 12
app/src/main/java/com/electric/chargingpile/activity/RegisterActivity.java

@ -82,7 +82,7 @@ public class RegisterActivity extends Activity implements OnClickListener {
82 82
    Context context;
83 83
    String no;
84 84
    private Bitmap download_bmp;
85
    private Boolean flag = true;
85
    private Boolean flag = false;
86 86
    private android.view.animation.Animation animation;
87 87
    private static final int RC_CAMERA_PERM = 123;
88 88

@ -352,18 +352,9 @@ public class RegisterActivity extends Activity implements OnClickListener {
352 352
                }
353 353
                break;
354 354
            case R.id.tv_make_sure:
355
//                SharedPreferences mySharedPreferences = getSharedPreferences(imei,
356
//                        Activity.MODE_PRIVATE);
357
//                no = mySharedPreferences.getString(imei, "0");
358
//                Log.e("@@@",no);
359
//                if (Integer.parseInt(no) < 2){
360

361 355
                if (checkTextSubmit()) {
362 356
                    if (!flag) {
363
                        Toast.makeText(this, "请勾选协议与隐私政策", Toast.LENGTH_SHORT).show();
364
                        tvSure.setEnabled(false);
365
                        tvSure.setBackgroundResource(R.drawable.textview_1green);
366

357
                        Toast.makeText(this, "请阅读并同意相关协议", Toast.LENGTH_SHORT).show();
367 358
                    } else {
368 359
                        MobclickAgent.onEvent(getApplicationContext(), "0901");
369 360
                        tvSure.setEnabled(true);
@ -397,7 +388,6 @@ public class RegisterActivity extends Activity implements OnClickListener {
397 388
                    iv_tongyi.setImageResource(R.drawable.icon_login_select);
398 389
                    flag = false;
399 390
                    tvSure.setBackgroundResource(R.drawable.textview_1green);
400
//                    tvSure.setTextColor(getResources().getColor(R.color.lvse));
401 391
                    tvSure.setEnabled(false);
402 392
                } else {
403 393
                    iv_tongyi.setImageResource(R.drawable.icon_login_selected);

+ 2 - 2
app/src/main/res/layout/activity_login.xml

@ -150,7 +150,7 @@
150 150
                    android:id="@+id/iv_tongyi"
151 151
                    android:layout_width="48px"
152 152
                    android:layout_height="48px"
153
                    android:src="@drawable/icon_login_selected"
153
                    android:src="@drawable/icon_login_select"
154 154
                    android:layout_gravity="center"
155 155
                    android:layout_marginLeft="58px"
156 156
                    android:layout_marginBottom="1dp"/>
@ -158,7 +158,7 @@
158 158
                <TextView
159 159
                    android:layout_width="wrap_content"
160 160
                    android:layout_height="wrap_content"
161
                    android:text="登录即代表您同意"
161
                    android:text="已阅读并同意"
162 162
                    android:textSize="13sp"
163 163
                    android:textColor="@color/ui_69"
164 164
                    android:layout_marginLeft="10px"

+ 2 - 2
app/src/main/res/layout/activity_register.xml

@ -236,7 +236,7 @@
236 236
                        android:id="@+id/iv_tongyi"
237 237
                        android:layout_width="48px"
238 238
                        android:layout_height="48px"
239
                        android:src="@drawable/icon_login_selected"
239
                        android:src="@drawable/icon_login_select"
240 240
                        android:layout_gravity="center"
241 241
                        android:layout_marginLeft="58px"
242 242
                        android:layout_marginBottom="1dp"/>
@ -244,7 +244,7 @@
244 244
                    <TextView
245 245
                        android:layout_width="wrap_content"
246 246
                        android:layout_height="wrap_content"
247
                        android:text="注册即代表您同意"
247
                        android:text="已阅读并同意"
248 248
                        android:textSize="13sp"
249 249
                        android:textColor="@color/ui_69"
250 250
                        android:layout_marginLeft="10px"