Commit 73e24d52d44cb61591420c299860f9941088de32
1 parent
ee4c3fd153
Exists in
master
个人中心完善
Showing
37 changed files
with
265 additions
and
201 deletions
Show diff stats
PersonalCenter/.idea/encodings.xml
PersonalCenter/app/src/main/AndroidManifest.xml
... | ... | @@ -5,20 +5,20 @@ |
5 | 5 | <application |
6 | 6 | android:name=".activity.MyApplication" |
7 | 7 | android:allowBackup="true" |
8 | - android:icon="@mipmap/ic_launcher" | |
8 | + android:icon="@mipmap/icon" | |
9 | 9 | android:label="@string/app_name" |
10 | 10 | android:supportsRtl="true" |
11 | - android:theme="@style/Theme.AppCompat.Light.NoActionBar"> | |
11 | + android:theme="@android:style/Theme.Light.NoTitleBar.Fullscreen"> | |
12 | 12 | <activity |
13 | 13 | android:name=".activity.MainActivity" |
14 | 14 | android:launchMode="singleTask" |
15 | - android:screenOrientation="landscape"> | |
15 | + android:screenOrientation="sensorLandscape"> | |
16 | 16 | </activity> |
17 | 17 | <activity |
18 | 18 | android:name=".activity.LoginAndRegisterActivity" |
19 | 19 | android:launchMode="singleTask" |
20 | 20 | |
21 | - android:screenOrientation="landscape"> | |
21 | + android:screenOrientation="sensorLandscape"> | |
22 | 22 | <intent-filter> |
23 | 23 | <action android:name="android.intent.action.MAIN" /> |
24 | 24 | |
... | ... | @@ -29,97 +29,100 @@ |
29 | 29 | <activity |
30 | 30 | android:name=".activity.ForgotPasswordActivity" |
31 | 31 | android:launchMode="singleTask" |
32 | - android:screenOrientation="landscape"> | |
32 | + android:screenOrientation="sensorLandscape"> | |
33 | 33 | |
34 | 34 | </activity> |
35 | 35 | <activity |
36 | 36 | android:name=".activity.ChangePasswordActivity" |
37 | 37 | android:launchMode="singleTask" |
38 | - android:screenOrientation="landscape"> | |
38 | + android:screenOrientation="sensorLandscape"> | |
39 | 39 | |
40 | 40 | </activity> |
41 | 41 | <activity |
42 | 42 | android:name=".activity.RegisterInfoActivity" |
43 | 43 | android:launchMode="singleTask" |
44 | - android:screenOrientation="landscape"> | |
44 | + android:screenOrientation="sensorLandscape"> | |
45 | 45 | |
46 | 46 | </activity> |
47 | 47 | <activity |
48 | 48 | android:name=".activity.ElectronicCardValidationActivity" |
49 | 49 | android:launchMode="singleTask" |
50 | - android:screenOrientation="landscape"> | |
50 | + android:screenOrientation="sensorLandscape"> | |
51 | 51 | |
52 | 52 | </activity> |
53 | 53 | <activity |
54 | 54 | android:name=".activity.ChangeBangDingActivity" |
55 | 55 | android:launchMode="singleTask" |
56 | - android:screenOrientation="landscape"> | |
56 | + android:screenOrientation="sensorLandscape"> | |
57 | 57 | |
58 | 58 | </activity> |
59 | 59 | <activity |
60 | 60 | android:name=".activity.ChangeElectronicCardAdressInfoActivity" |
61 | 61 | android:launchMode="singleTask" |
62 | - android:screenOrientation="landscape"> | |
62 | + android:screenOrientation="sensorLandscape"> | |
63 | 63 | |
64 | 64 | </activity> |
65 | 65 | <activity |
66 | 66 | android:name=".activity.ChangeEletronicCardPhoneActivity" |
67 | 67 | android:launchMode="singleTask" |
68 | - android:screenOrientation="landscape"> | |
68 | + android:screenOrientation="sensorLandscape"> | |
69 | 69 | |
70 | 70 | </activity> |
71 | 71 | <activity |
72 | 72 | android:name=".activity.ChoiseTextBookActivity" |
73 | 73 | android:launchMode="singleTask" |
74 | - android:screenOrientation="landscape"> | |
74 | + android:screenOrientation="sensorLandscape"> | |
75 | 75 | |
76 | 76 | </activity> |
77 | 77 | <activity |
78 | 78 | android:name=".activity.TheStartPageActivity" |
79 | 79 | android:launchMode="singleTask" |
80 | - android:screenOrientation="landscape"> | |
80 | + android:screenOrientation="sensorLandscape"> | |
81 | 81 | |
82 | 82 | </activity> |
83 | 83 | <activity |
84 | 84 | android:name=".activity.ElectronicCardEditInfoActivity" |
85 | 85 | android:launchMode="singleTask" |
86 | - android:screenOrientation="landscape"> | |
86 | + android:screenOrientation="sensorLandscape" | |
87 | + android:windowSoftInputMode="adjustPan"> | |
87 | 88 | |
88 | 89 | </activity> |
89 | 90 | <activity |
90 | 91 | android:name=".activity.ElectronicCardInfoOKActivity" |
91 | 92 | android:launchMode="singleTask" |
92 | - android:screenOrientation="landscape"> | |
93 | + android:screenOrientation="sensorLandscape"> | |
93 | 94 | |
94 | 95 | </activity> |
95 | 96 | <activity |
96 | 97 | android:name=".activity.ElectronicCardLookInfoActivity" |
97 | 98 | android:launchMode="singleTask" |
98 | - android:screenOrientation="landscape"> | |
99 | + android:screenOrientation="sensorLandscape" | |
100 | + > | |
99 | 101 | |
100 | 102 | </activity> |
101 | 103 | <activity |
102 | 104 | android:name=".activity.FeedBackActivity" |
103 | 105 | android:launchMode="singleTask" |
104 | - android:screenOrientation="landscape"> | |
106 | + android:screenOrientation="sensorLandscape"> | |
105 | 107 | |
106 | 108 | </activity> |
107 | 109 | <activity |
108 | 110 | android:name=".activity.AccountManagementActivity" |
109 | 111 | android:launchMode="singleTask" |
110 | - android:screenOrientation="landscape"> | |
112 | + android:screenOrientation="sensorLandscape"> | |
111 | 113 | |
112 | 114 | </activity> |
113 | 115 | <activity |
114 | 116 | android:name=".activity.ChangePresonalInfoActivity" |
115 | 117 | android:launchMode="singleTask" |
116 | - android:screenOrientation="landscape"> | |
118 | + android:screenOrientation="sensorLandscape" | |
119 | + android:windowSoftInputMode="adjustPan"> | |
117 | 120 | |
118 | 121 | </activity> |
119 | 122 | <activity |
120 | 123 | android:name=".activity.BangDingCode" |
121 | 124 | android:launchMode="singleTask" |
122 | - android:screenOrientation="landscape"> | |
125 | + android:screenOrientation="sensorLandscape"> | |
123 | 126 | |
124 | 127 | </activity> |
125 | 128 | <service android:name="com.hjx.personalcenter.service.CenterService" | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/AccountManagementActivity.java
... | ... | @@ -4,9 +4,10 @@ import android.content.Intent; |
4 | 4 | import android.os.Bundle; |
5 | 5 | import android.os.Handler; |
6 | 6 | import android.os.Message; |
7 | -import android.support.v7.app.AppCompatActivity; | |
7 | +import android.support.v4.app.FragmentActivity; | |
8 | 8 | import android.support.v7.widget.LinearLayoutManager; |
9 | 9 | import android.support.v7.widget.RecyclerView; |
10 | +import android.util.Log; | |
10 | 11 | import android.view.View; |
11 | 12 | import android.widget.ImageView; |
12 | 13 | import android.widget.LinearLayout; |
... | ... | @@ -32,7 +33,7 @@ import java.util.List; |
32 | 33 | * Created by h on 2017/8/12. |
33 | 34 | */ |
34 | 35 | |
35 | -public class AccountManagementActivity extends AppCompatActivity implements View.OnClickListener { | |
36 | +public class AccountManagementActivity extends FragmentActivity implements View.OnClickListener { | |
36 | 37 | private TextView changbangding, changpassword, usernames, |
37 | 38 | tv_username, tv_grade, tv_school, tv_adress, tv_changzhu; |
38 | 39 | private ImageView iv_useing, cancel; |
... | ... | @@ -135,7 +136,6 @@ public class AccountManagementActivity extends AppCompatActivity implements View |
135 | 136 | iv_useing.setVisibility(View.VISIBLE); |
136 | 137 | ll_zhu_backgrangd.setBackgroundResource(R.drawable.corcle_blue_bg); |
137 | 138 | } else { |
138 | - | |
139 | 139 | tv_changzhu.setText("切换主账户"); |
140 | 140 | tv_changzhu.setEnabled(true); |
141 | 141 | iv_useing.setVisibility(View.GONE); |
... | ... | @@ -190,8 +190,21 @@ public class AccountManagementActivity extends AppCompatActivity implements View |
190 | 190 | String userID = SaveParam.getInstance().getLoginParam(this, "userId"); |
191 | 191 | SaveParam.getInstance().saveCustomizeParam(this, SaveParam.ACCOUNT, "1"); |
192 | 192 | String devicenumber = GetDevicesUtil.getDevicesInfo(this).getDeviceNumber(); |
193 | + String ss = SaveParam.getInstance().getLoginParam(AccountManagementActivity.this, SaveParam.GRADENS); | |
194 | + String zizhuanhui = SaveParam.getInstance().getLoginParam(AccountManagementActivity.this, SaveParam.CHILDSGRADENS); | |
193 | 195 | try { |
194 | 196 | long auserID = Long.parseLong(userID); |
197 | + int zhugrade = Integer.parseInt(ss); | |
198 | + int zigrade = Integer.parseInt(zizhuanhui); | |
199 | + if ((zhugrade < 8)&&(zigrade>=8)||(zhugrade >= 8)&&(zigrade<8)) { | |
200 | + Intent intentbroad = new Intent(); | |
201 | + intentbroad.putExtra("info", "小学"); | |
202 | + //4、定义广播发送的action | |
203 | + intentbroad.setAction("com.ozing.launcher.SWITCH_GRADE"); | |
204 | + //5、发送广播 | |
205 | + sendBroadcast(intentbroad); | |
206 | + Log.i("---", "发送完了"); | |
207 | + } | |
195 | 208 | HttpManager.getInstance().Accountinfo(AccountManagementActivity.this, auserID, |
196 | 209 | devicenumber, 1); |
197 | 210 | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/BangDingCode.java
... | ... | @@ -3,7 +3,7 @@ package com.hjx.personalcenter.activity; |
3 | 3 | import android.content.Intent; |
4 | 4 | import android.graphics.Bitmap; |
5 | 5 | import android.os.Bundle; |
6 | -import android.support.v7.app.AppCompatActivity; | |
6 | +import android.support.v4.app.FragmentActivity; | |
7 | 7 | import android.util.DisplayMetrics; |
8 | 8 | import android.view.KeyEvent; |
9 | 9 | import android.view.View; |
... | ... | @@ -21,7 +21,7 @@ import java.io.File; |
21 | 21 | * Created by h on 2017/8/31. |
22 | 22 | */ |
23 | 23 | |
24 | -public class BangDingCode extends AppCompatActivity { | |
24 | +public class BangDingCode extends FragmentActivity { | |
25 | 25 | private ImageView EQpicture; |
26 | 26 | private Button btn_next_tep; |
27 | 27 | File file; | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/ChangeBangDingActivity.java
1 | 1 | package com.hjx.personalcenter.activity; |
2 | 2 | |
3 | -import android.app.Activity; | |
4 | 3 | import android.os.Bundle; |
4 | +import android.support.v4.app.FragmentActivity; | |
5 | 5 | |
6 | 6 | import com.hjx.personalcenter.R; |
7 | 7 | |
... | ... | @@ -9,7 +9,7 @@ import com.hjx.personalcenter.R; |
9 | 9 | * Created by h on 2017/8/9. |
10 | 10 | */ |
11 | 11 | |
12 | -public class ChangeBangDingActivity extends Activity { | |
12 | +public class ChangeBangDingActivity extends FragmentActivity { | |
13 | 13 | @Override |
14 | 14 | protected void onCreate(Bundle savedInstanceState) { |
15 | 15 | super.onCreate(savedInstanceState); | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/ChangeElectronicCardAdressInfoActivity.java
... | ... | @@ -3,7 +3,7 @@ package com.hjx.personalcenter.activity; |
3 | 3 | import android.os.Bundle; |
4 | 4 | import android.os.Handler; |
5 | 5 | import android.os.Message; |
6 | -import android.support.v7.app.AppCompatActivity; | |
6 | +import android.support.v4.app.FragmentActivity; | |
7 | 7 | import android.text.TextUtils; |
8 | 8 | import android.view.View; |
9 | 9 | import android.widget.Button; |
... | ... | @@ -36,7 +36,7 @@ import java.util.TimerTask; |
36 | 36 | * Created by h on 2017/8/9. |
37 | 37 | */ |
38 | 38 | |
39 | -public class ChangeElectronicCardAdressInfoActivity extends AppCompatActivity implements View.OnClickListener | |
39 | +public class ChangeElectronicCardAdressInfoActivity extends FragmentActivity implements View.OnClickListener | |
40 | 40 | ,DialogCallBack.ProvincesCallBack |
41 | 41 | ,DialogCallBack.CitysCallBack,DialogCallBack.CountryCallBack{ |
42 | 42 | private ImageView back_forgit; |
... | ... | @@ -134,13 +134,8 @@ public class ChangeElectronicCardAdressInfoActivity extends AppCompatActivity im |
134 | 134 | } else { |
135 | 135 | //修改地址接口 |
136 | 136 | String userID = GetDevicesUtil.getDevicesInfo(this).getDeviceNumber(); |
137 | - long auserID = 0; | |
138 | - try { | |
139 | - auserID = Long.parseLong(userID); | |
140 | - HttpManager.getInstance().changecardadressinfo(this,auserID,forot_pwd_phone1,forot_pwd_anthcode1,forot_pwd_pwd3+forot_pwd_pwd4); | |
141 | - } catch (NumberFormatException e) { | |
142 | - e.printStackTrace(); | |
143 | - } | |
137 | + HttpManager.getInstance().changecardadressinfo(this,userID,forot_pwd_phone1,forot_pwd_anthcode1,forot_pwd_pwd3+forot_pwd_pwd4); | |
138 | + | |
144 | 139 | |
145 | 140 | } |
146 | 141 | break; | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/ChangeEletronicCardPhoneActivity.java
1 | 1 | package com.hjx.personalcenter.activity; |
2 | 2 | |
3 | 3 | import android.os.Bundle; |
4 | -import android.support.v7.app.AppCompatActivity; | |
4 | +import android.support.v4.app.FragmentActivity; | |
5 | 5 | |
6 | 6 | import com.hjx.personalcenter.R; |
7 | 7 | |
... | ... | @@ -9,7 +9,7 @@ import com.hjx.personalcenter.R; |
9 | 9 | * Created by h on 2017/8/9. |
10 | 10 | */ |
11 | 11 | |
12 | -public class ChangeEletronicCardPhoneActivity extends AppCompatActivity { | |
12 | +public class ChangeEletronicCardPhoneActivity extends FragmentActivity { | |
13 | 13 | |
14 | 14 | |
15 | 15 | @Override | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/ChangePasswordActivity.java
1 | 1 | package com.hjx.personalcenter.activity; |
2 | 2 | |
3 | 3 | import android.os.Bundle; |
4 | -import android.support.v7.app.AppCompatActivity; | |
4 | +import android.support.v4.app.FragmentActivity; | |
5 | 5 | import android.text.TextUtils; |
6 | 6 | import android.text.method.HideReturnsTransformationMethod; |
7 | 7 | import android.text.method.PasswordTransformationMethod; |
... | ... | @@ -20,7 +20,7 @@ import com.hjx.personalcenter.util.PasswordCheckUtils; |
20 | 20 | * Created by h on 2017/6/27. |
21 | 21 | */ |
22 | 22 | |
23 | -public class ChangePasswordActivity extends AppCompatActivity implements View.OnClickListener { | |
23 | +public class ChangePasswordActivity extends FragmentActivity implements View.OnClickListener { | |
24 | 24 | private EditText old_pwd,newpassword,newpassword1; |
25 | 25 | private Button sub_change_pwd; |
26 | 26 | private ImageView back_change_pwd,eyes_iv_change1; | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/ChangePresonalInfoActivity.java
... | ... | @@ -2,8 +2,8 @@ package com.hjx.personalcenter.activity; |
2 | 2 | |
3 | 3 | import android.os.Bundle; |
4 | 4 | import android.support.v4.app.Fragment; |
5 | +import android.support.v4.app.FragmentActivity; | |
5 | 6 | import android.support.v4.view.ViewPager; |
6 | -import android.support.v7.app.AppCompatActivity; | |
7 | 7 | |
8 | 8 | import com.hjx.personalcenter.R; |
9 | 9 | import com.hjx.personalcenter.adapter.LoginAndRegisterAdapter; |
... | ... | @@ -18,7 +18,7 @@ import java.util.List; |
18 | 18 | * Created by h on 2017/8/12. |
19 | 19 | */ |
20 | 20 | |
21 | -public class ChangePresonalInfoActivity extends AppCompatActivity { | |
21 | +public class ChangePresonalInfoActivity extends FragmentActivity { | |
22 | 22 | private ViewPager viewPager; |
23 | 23 | // private SlidingTabLayout tableLayout; |
24 | 24 | private List<Fragment> presoninfo; | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/ChoiseTextBookActivity.java
... | ... | @@ -4,6 +4,7 @@ import android.content.Intent; |
4 | 4 | import android.os.Bundle; |
5 | 5 | import android.os.Handler; |
6 | 6 | import android.os.Message; |
7 | +import android.support.v4.app.FragmentActivity; | |
7 | 8 | import android.support.v7.app.AppCompatActivity; |
8 | 9 | import android.util.Log; |
9 | 10 | import android.view.View; |
... | ... | @@ -39,7 +40,7 @@ import java.util.List; |
39 | 40 | * Created by h on 2017/8/10. |
40 | 41 | */ |
41 | 42 | |
42 | -public class ChoiseTextBookActivity extends AppCompatActivity implements View.OnClickListener, AdapterView.OnItemClickListener, DialogCallBack.VersionCallBack { | |
43 | +public class ChoiseTextBookActivity extends FragmentActivity implements View.OnClickListener, AdapterView.OnItemClickListener, DialogCallBack.VersionCallBack { | |
43 | 44 | private GridView gridView; |
44 | 45 | private Button btn_ok; |
45 | 46 | private ImageView cancel; | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/ElectronicCardEditInfoActivity.java
... | ... | @@ -2,7 +2,7 @@ package com.hjx.personalcenter.activity; |
2 | 2 | |
3 | 3 | import android.content.Intent; |
4 | 4 | import android.os.Bundle; |
5 | -import android.support.v7.app.AppCompatActivity; | |
5 | +import android.support.v4.app.FragmentActivity; | |
6 | 6 | import android.text.TextUtils; |
7 | 7 | import android.view.View; |
8 | 8 | import android.widget.Button; |
... | ... | @@ -31,7 +31,7 @@ import java.util.ArrayList; |
31 | 31 | * Created by h on 2017/8/11. |
32 | 32 | */ |
33 | 33 | |
34 | -public class ElectronicCardEditInfoActivity extends AppCompatActivity implements View.OnClickListener | |
34 | +public class ElectronicCardEditInfoActivity extends FragmentActivity implements View.OnClickListener | |
35 | 35 | ,DialogCallBack.ProvincesCallBack |
36 | 36 | ,DialogCallBack.CitysCallBack,DialogCallBack.CountryCallBack{ |
37 | 37 | private LinearLayout lineL_buy_time; | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/ElectronicCardInfoOKActivity.java
1 | 1 | package com.hjx.personalcenter.activity; |
2 | 2 | |
3 | 3 | import android.os.Bundle; |
4 | -import android.support.v7.app.AppCompatActivity; | |
4 | +import android.support.v4.app.FragmentActivity; | |
5 | 5 | import android.view.View; |
6 | 6 | import android.widget.Button; |
7 | 7 | import android.widget.ImageView; |
... | ... | @@ -17,7 +17,7 @@ import com.hjx.personalcenter.util.GetDevicesUtil; |
17 | 17 | * Created by h on 2017/8/11. |
18 | 18 | */ |
19 | 19 | |
20 | -public class ElectronicCardInfoOKActivity extends AppCompatActivity implements View.OnClickListener { | |
20 | +public class ElectronicCardInfoOKActivity extends FragmentActivity implements View.OnClickListener { | |
21 | 21 | private Button btn_finish,btn_bangding; |
22 | 22 | private ImageView iv_last_step; |
23 | 23 | private TextView usename,deviceModel,customer_address,mac_adress,shoptime,deviceNumber,shopadress,phone,tlePhone; | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/ElectronicCardLookInfoActivity.java
... | ... | @@ -4,13 +4,14 @@ import android.content.Intent; |
4 | 4 | import android.os.Bundle; |
5 | 5 | import android.os.Handler; |
6 | 6 | import android.os.Message; |
7 | -import android.support.v7.app.AppCompatActivity; | |
7 | +import android.support.v4.app.FragmentActivity; | |
8 | 8 | import android.view.View; |
9 | 9 | import android.widget.ImageView; |
10 | 10 | import android.widget.TextView; |
11 | 11 | |
12 | 12 | import com.hjx.personalcenter.R; |
13 | 13 | import com.hjx.personalcenter.db.Content; |
14 | +import com.hjx.personalcenter.db.SaveParam; | |
14 | 15 | import com.hjx.personalcenter.http.HttpCode; |
15 | 16 | import com.hjx.personalcenter.http.HttpManager; |
16 | 17 | import com.hjx.personalcenter.model.CardInfo; |
... | ... | @@ -23,7 +24,7 @@ import java.util.ArrayList; |
23 | 24 | * Created by h on 2017/8/11. |
24 | 25 | */ |
25 | 26 | |
26 | -public class ElectronicCardLookInfoActivity extends AppCompatActivity implements View.OnClickListener { | |
27 | +public class ElectronicCardLookInfoActivity extends FragmentActivity implements View.OnClickListener { | |
27 | 28 | private ImageView iv_last_step; |
28 | 29 | private TextView usename, deviceModel, customer_address, mac_adress, shoptime, deviceNumber, |
29 | 30 | shopadress, phone, tlePhone, tv_card_adress_change, tv_card_phone_change; |
... | ... | @@ -44,11 +45,18 @@ public class ElectronicCardLookInfoActivity extends AppCompatActivity implements |
44 | 45 | mac_adress.setText(cardinfoBean.getMacAddress()); |
45 | 46 | //获取保卡信息 |
46 | 47 | usename.setText(cardinfoBean.getCustomerName()); |
48 | + SaveParam.getInstance().saveCustomizeParam(ElectronicCardLookInfoActivity.this,SaveParam.CUNSTEMNAME, cardinfoBean.getCustomerName()); | |
47 | 49 | customer_address.setText(cardinfoBean.getCustomerAddress()); |
50 | + SaveParam.getInstance().saveCustomizeParam(ElectronicCardLookInfoActivity.this,SaveParam.ADRESSCUNSTEM, cardinfoBean.getCustomerAddress()); | |
48 | 51 | shoptime.setText(cardinfoBean.getBuyTime()); |
52 | + SaveParam.getInstance().saveCustomizeParam(ElectronicCardLookInfoActivity.this,SaveParam.SHOPTIME, cardinfoBean.getBuyTime()); | |
49 | 53 | shopadress.setText(cardinfoBean.getBuyAddress()); |
54 | + SaveParam.getInstance().saveCustomizeParam(ElectronicCardLookInfoActivity.this,SaveParam.SHOPADRESS, cardinfoBean.getBuyAddress()); | |
50 | 55 | tlePhone.setText(cardinfoBean.getAlterSaleCall()); |
56 | + SaveParam.getInstance().saveCustomizeParam(ElectronicCardLookInfoActivity.this,SaveParam.SHOPTLEPHONE, cardinfoBean.getMobilePhone()); | |
51 | 57 | phone.setText(cardinfoBean.getMobilePhone()); |
58 | + SaveParam.getInstance().saveCustomizeParam(ElectronicCardLookInfoActivity.this,SaveParam.CARDPHONE, cardinfoBean.getMobilePhone() ); | |
59 | + initData(); | |
52 | 60 | }else { |
53 | 61 | AlertUtils.showToast(ElectronicCardLookInfoActivity.this,"您的机器还没有保卡信息,请重新登录"); |
54 | 62 | } | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/ElectronicCardValidationActivity.java
... | ... | @@ -4,7 +4,7 @@ import android.content.Intent; |
4 | 4 | import android.os.Bundle; |
5 | 5 | import android.os.Handler; |
6 | 6 | import android.os.Message; |
7 | -import android.support.v7.app.AppCompatActivity; | |
7 | +import android.support.v4.app.FragmentActivity; | |
8 | 8 | import android.text.TextUtils; |
9 | 9 | import android.view.View; |
10 | 10 | import android.widget.Button; |
... | ... | @@ -29,7 +29,7 @@ import java.util.TimerTask; |
29 | 29 | * Created by h on 2017/8/9. |
30 | 30 | */ |
31 | 31 | |
32 | -public class ElectronicCardValidationActivity extends AppCompatActivity implements View.OnClickListener { | |
32 | +public class ElectronicCardValidationActivity extends FragmentActivity implements View.OnClickListener { | |
33 | 33 | private Button btn_card_valiyanzhen,get_authcode; |
34 | 34 | private EditText phonenumber,anth_6num;//;//密码 |
35 | 35 | private TextView menu_title; |
... | ... | @@ -37,7 +37,7 @@ public class ElectronicCardValidationActivity extends AppCompatActivity implemen |
37 | 37 | private int delayTime=60; |
38 | 38 | private java.util.Timer Delaytimer; |
39 | 39 | private String sourceStr ="android"; |
40 | - private String typeStr = "register"; | |
40 | + private String typeStr = "general"; | |
41 | 41 | String authcode = ""; |
42 | 42 | Handler handler = new Handler() { |
43 | 43 | @Override | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/FeedBackActivity.java
... | ... | @@ -8,8 +8,8 @@ import android.os.Build; |
8 | 8 | import android.os.Bundle; |
9 | 9 | import android.provider.MediaStore; |
10 | 10 | import android.support.annotation.NonNull; |
11 | +import android.support.v4.app.FragmentActivity; | |
11 | 12 | import android.support.v4.content.FileProvider; |
12 | -import android.support.v7.app.AppCompatActivity; | |
13 | 13 | import android.text.TextUtils; |
14 | 14 | import android.view.Gravity; |
15 | 15 | import android.view.View; |
... | ... | @@ -46,7 +46,7 @@ import java.io.File; |
46 | 46 | * Created by h on 2017/8/11. |
47 | 47 | */ |
48 | 48 | |
49 | -public class FeedBackActivity extends AppCompatActivity implements View.OnClickListener { | |
49 | +public class FeedBackActivity extends FragmentActivity implements View.OnClickListener { | |
50 | 50 | private ImageView iv_cance, iv_show, iv_take; |
51 | 51 | private EditText content, phone; |
52 | 52 | private TextView tv_sub; | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/ForgotPasswordActivity.java
... | ... | @@ -3,6 +3,7 @@ package com.hjx.personalcenter.activity; |
3 | 3 | import android.os.Bundle; |
4 | 4 | import android.os.Handler; |
5 | 5 | import android.os.Message; |
6 | +import android.support.v4.app.FragmentActivity; | |
6 | 7 | import android.support.v7.app.AppCompatActivity; |
7 | 8 | import android.text.TextUtils; |
8 | 9 | import android.text.method.HideReturnsTransformationMethod; |
... | ... | @@ -30,7 +31,7 @@ import java.util.TimerTask; |
30 | 31 | * Created by h on 2017/6/17. |
31 | 32 | */ |
32 | 33 | |
33 | -public class ForgotPasswordActivity extends AppCompatActivity implements View.OnClickListener { | |
34 | +public class ForgotPasswordActivity extends FragmentActivity implements View.OnClickListener { | |
34 | 35 | private ImageView back_forgit, iv_pwd_change; |
35 | 36 | private EditText forot_pwd_phone, forot_pwd_anthcode, forot_pwd_pwd, forot_pwd_pwd2; |
36 | 37 | private Button forot_pwd_sub, forot_pwd_getanthcode; | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/LoginAndRegisterActivity.java
... | ... | @@ -5,8 +5,8 @@ import android.os.Bundle; |
5 | 5 | import android.provider.Settings; |
6 | 6 | import android.support.annotation.Nullable; |
7 | 7 | import android.support.v4.app.Fragment; |
8 | +import android.support.v4.app.FragmentActivity; | |
8 | 9 | import android.support.v4.view.ViewPager; |
9 | -import android.support.v7.app.AppCompatActivity; | |
10 | 10 | import android.view.Gravity; |
11 | 11 | import android.view.View; |
12 | 12 | |
... | ... | @@ -30,7 +30,7 @@ import java.util.List; |
30 | 30 | * Created by h on 2017/8/8. |
31 | 31 | */ |
32 | 32 | |
33 | -public class LoginAndRegisterActivity extends AppCompatActivity { | |
33 | +public class LoginAndRegisterActivity extends FragmentActivity { | |
34 | 34 | private ViewPager viewPager; |
35 | 35 | private SlidingTabLayout tableLayout; |
36 | 36 | private List<Fragment> loginlist; | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/MainActivity.java
... | ... | @@ -10,8 +10,8 @@ import android.os.Handler; |
10 | 10 | import android.os.Message; |
11 | 11 | import android.provider.MediaStore; |
12 | 12 | import android.support.annotation.NonNull; |
13 | +import android.support.v4.app.FragmentActivity; | |
13 | 14 | import android.support.v4.content.FileProvider; |
14 | -import android.support.v7.app.AppCompatActivity; | |
15 | 15 | import android.support.v7.widget.LinearLayoutManager; |
16 | 16 | import android.support.v7.widget.RecyclerView; |
17 | 17 | import android.util.Log; |
... | ... | @@ -67,12 +67,12 @@ import java.io.UnsupportedEncodingException; |
67 | 67 | import java.util.ArrayList; |
68 | 68 | import java.util.List; |
69 | 69 | |
70 | -public class MainActivity extends AppCompatActivity implements View.OnClickListener, DialogCallBack.CallBackView { | |
71 | - private ImageView iv_imformatioan, iv_setting, iv_sign, iv_sex,tv_edit_presoninfo; | |
72 | - private TextView tv_sign, | |
70 | +public class MainActivity extends FragmentActivity implements View.OnClickListener, DialogCallBack.CallBackView { | |
71 | + private ImageView iv_imformatioan, iv_setting, iv_sign, iv_sex, tv_edit_presoninfo; | |
72 | + private TextView tv_sign, | |
73 | 73 | tv_username, tv_username1, tv_mygad, tv_sex, tv_useinfo_adress, tv_useinfo_birthday, |
74 | 74 | tv_useinfo_qq, tv_useinfo_school, tv_useinfo_gender, tv_yangji; |
75 | - private TextView linel_mycuoti, linel_mynote, linel_mycollege, linel_myclass,iv_look_card; | |
75 | + private TextView linel_mycuoti, linel_mynote, linel_mycollege, linel_myclass, iv_look_card; | |
76 | 76 | private TopRightMenu mTopRightMenu; |
77 | 77 | private LinearLayout view_novedeo; |
78 | 78 | //水平滑动 |
... | ... | @@ -83,8 +83,8 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe |
83 | 83 | private ArrayList<DefautPublishInfo.DataBean> defautPublishInfos = new ArrayList<>(); |
84 | 84 | |
85 | 85 | private ArrayList<VideoInfo.DataBean> videoinfo = new ArrayList<>(); |
86 | - private boolean showIcon = true; | |
87 | - private boolean dimBg = true; | |
86 | + private boolean showIcon = false; | |
87 | + private boolean dimBg = false; | |
88 | 88 | private boolean needAnim = true; |
89 | 89 | private static final int REQUEST_CODE_TAKE_PHOTO = 1; |
90 | 90 | private static final int REQUEST_CODE_ALBUM = 2; |
... | ... | @@ -117,31 +117,32 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe |
117 | 117 | mSimpleDraweeView.setImageURI(cardinfoBean.getPortrait()); |
118 | 118 | //加载星座 |
119 | 119 | BrithdayStar brithdayStar = new BrithdayStar(); |
120 | - if (cardinfoBean.getBirthday() ==null||"".equals(cardinfoBean.getBirthday())) { | |
120 | + if (cardinfoBean.getBirthday() == null || "".equals(cardinfoBean.getBirthday())) { | |
121 | 121 | tv_mygad.setText(""); |
122 | 122 | } else { |
123 | 123 | String xiongzuo = brithdayStar.getConstellations(cardinfoBean.getBirthday()); |
124 | 124 | tv_mygad.setText(xiongzuo); |
125 | 125 | } |
126 | 126 | //保存个人信息 |
127 | - SaveParam.getInstance().saveLoginParam(MainActivity.this,SaveParam.ACCOUNTUSERNAME,cardinfoBean.getNickName()); | |
128 | - SaveParam.getInstance().saveLoginParam(MainActivity.this,SaveParam.ACCOUNTGRADES,cardinfoBean.getGrade().getGradeName()); | |
129 | - SaveParam.getInstance().saveLoginParam(MainActivity.this,SaveParam.ACCOUNTSCHOOL,cardinfoBean.getSchool().getSchoolName()); | |
130 | - SaveParam.getInstance().saveLoginParam(MainActivity.this,SaveParam.ACCOUNTCONSTELLATION,cardinfoBean.getBirthday()); | |
131 | - SaveParam.getInstance().saveLoginParam(MainActivity.this,SaveParam.ACCOUNTSEX,tv_sex.getText().toString()); | |
132 | - SaveParam.getInstance().saveLoginParam(MainActivity.this,SaveParam.ACCOUNTQQ,cardinfoBean.getQq()); | |
133 | - SaveParam.getInstance().saveLoginParam(MainActivity.this,SaveParam.ACCOUNTADRESS,cardinfoBean.getRegion().getRegionName()); | |
134 | - SaveParam.getInstance().saveLoginParam(MainActivity.this,SaveParam.ACCOUNTXINGZUO,cardinfoBean.getAddress()); | |
135 | - SaveParam.getInstance().saveLoginParam(MainActivity.this,SaveParam.ADRESSID,cardinfoBean.getRegion().getRegionId()); | |
136 | - SaveParam.getInstance().saveLoginParam(MainActivity.this,SaveParam.PORTAIT,cardinfoBean.getPortrait()); | |
127 | + SaveParam.getInstance().saveLoginParam(MainActivity.this, SaveParam.ACCOUNTUSERNAME, cardinfoBean.getNickName()); | |
128 | + SaveParam.getInstance().saveLoginParam(MainActivity.this, SaveParam.ACCOUNTGRADES, cardinfoBean.getGrade().getGradeName()); | |
129 | + SaveParam.getInstance().saveLoginParam(MainActivity.this, SaveParam.ACCOUNTSCHOOL, cardinfoBean.getSchool().getSchoolName()); | |
130 | + SaveParam.getInstance().saveLoginParam(MainActivity.this, SaveParam.ACCOUNTCONSTELLATION, cardinfoBean.getBirthday()); | |
131 | + SaveParam.getInstance().saveLoginParam(MainActivity.this, SaveParam.ACCOUNTSEX, tv_sex.getText().toString()); | |
132 | + SaveParam.getInstance().saveLoginParam(MainActivity.this, SaveParam.ACCOUNTQQ, cardinfoBean.getQq()); | |
133 | + SaveParam.getInstance().saveLoginParam(MainActivity.this, SaveParam.ACCOUNTADRESS, cardinfoBean.getRegion().getRegionName()); | |
134 | + SaveParam.getInstance().saveLoginParam(MainActivity.this, SaveParam.ACCOUNTXINGZUO, cardinfoBean.getAddress()); | |
135 | + SaveParam.getInstance().saveLoginParam(MainActivity.this, SaveParam.ADRESSID, cardinfoBean.getRegion().getRegionId()); | |
136 | + SaveParam.getInstance().saveLoginParam(MainActivity.this, SaveParam.PORTAIT, cardinfoBean.getPortrait()); | |
137 | + SaveParam.getInstance().saveLoginParam(MainActivity.this, SaveParam.MAINSHOOLID, cardinfoBean.getSchool().getSchoolId()); | |
137 | 138 | String graderID = cardinfoBean.getGrade().getGradeId(); |
138 | - Log.e("test","nianji"+graderID); | |
139 | + Log.e("test", "nianji" + graderID); | |
139 | 140 | try { |
140 | 141 | long auserID = Long.parseLong(graderID); |
141 | - String ss =SaveParam.getInstance().getLoginParam(MainActivity.this, SaveParam.GRADENS); | |
142 | - if ((auserID<8)&&(ss ==null)){ | |
142 | + String ss = SaveParam.getInstance().getLoginParam(MainActivity.this, SaveParam.GRADENS); | |
143 | + if ((auserID < 8) && (ss == null)) { | |
143 | 144 | Intent intentbroad = new Intent(); |
144 | - intentbroad.putExtra("info","小学"); | |
145 | + intentbroad.putExtra("info", "小学"); | |
145 | 146 | //4、定义广播发送的action |
146 | 147 | intentbroad.setAction("com.ozing.launcher.SWITCH_GRADE"); |
147 | 148 | //5、发送广播 |
... | ... | @@ -193,18 +194,13 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe |
193 | 194 | defautPublishInfos.addAll((List<DefautPublishInfo.DataBean>) msg.obj); |
194 | 195 | RecyclerViewadapterpublish.notifyDataSetChanged(); |
195 | 196 | Gson gson = new Gson(); |
196 | - Log.e("test","(List<DefautPublishInfo.DataBean>) msg.obj"+ gson.toJson( msg.obj)); | |
197 | - SaveParam.getInstance().saveLoginParam(MainActivity.this,SaveParam.VERSIONINTEFACE, gson.toJson( msg.obj)); | |
197 | + Log.e("test", "(List<DefautPublishInfo.DataBean>) msg.obj" + gson.toJson(msg.obj)); | |
198 | + SaveParam.getInstance().saveLoginParam(MainActivity.this, SaveParam.VERSIONINTEFACE, gson.toJson(msg.obj)); | |
198 | 199 | break; |
199 | 200 | case HttpCode.GETVIDIO_SUCESS: |
200 | 201 | videoinfo.clear(); |
201 | - if (((List<VideoInfo.DataBean>) msg.obj).size()==0) { | |
202 | - view_novedeo.setVisibility(View.VISIBLE); | |
203 | - } else { | |
204 | - view_novedeo.setVisibility(View.GONE); | |
205 | - videoinfo.addAll((List<VideoInfo.DataBean>) msg.obj); | |
206 | - } | |
207 | - | |
202 | + view_novedeo.setVisibility(View.GONE); | |
203 | + videoinfo.addAll((List<VideoInfo.DataBean>) msg.obj); | |
208 | 204 | RecyclerViewadapter.notifyDataSetChanged(); |
209 | 205 | break; |
210 | 206 | case HttpCode.SUCHCARDINFOONE: |
... | ... | @@ -305,7 +301,7 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe |
305 | 301 | } |
306 | 302 | //设置布局管理器 |
307 | 303 | LinearLayoutManager linearLayoutManager = new LinearLayoutManager(this); |
308 | - linearLayoutManager.setOrientation(LinearLayoutManager.HORIZONTAL); | |
304 | + linearLayoutManager.setOrientation(LinearLayoutManager.VERTICAL); | |
309 | 305 | |
310 | 306 | // LinearLayoutManager linearLayoutManagerpublish = new LinearLayoutManager(this); |
311 | 307 | // linearLayoutManagerpublish.setOrientation(LinearLayoutManager.HORIZONTAL); |
... | ... | @@ -318,7 +314,7 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe |
318 | 314 | |
319 | 315 | //设置视频适配器 |
320 | 316 | RecyclerViewadapter = new VideoAdapter(this, videoinfo); |
321 | - RecyclerViewadapterpublish = new MianGridAdapter(defautPublishInfos,this); | |
317 | + RecyclerViewadapterpublish = new MianGridAdapter(defautPublishInfos, this); | |
322 | 318 | |
323 | 319 | //版本信息适配器 |
324 | 320 | mRecyclerView.setAdapter(RecyclerViewadapter); |
... | ... | @@ -334,28 +330,6 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe |
334 | 330 | HttpManager.getInstance().getcardinfo1(this, deviceNumber, handler); |
335 | 331 | |
336 | 332 | } |
337 | - String userID = SaveParam.getInstance().getLoginParam(this, "userId"); | |
338 | - //获取个性签名 | |
339 | - String typeaccount = SaveParam.getInstance().getCustomizeParam(this, SaveParam.ACCOUNT); | |
340 | - String childsID = SaveParam.getInstance().getCustomizeParam(this, SaveParam.CHILDSID); | |
341 | - | |
342 | - try { | |
343 | - long auserID = 1; | |
344 | - long id = Long.parseLong(userID); | |
345 | - long childssID = Long.parseLong(childsID); | |
346 | - | |
347 | - int typeaccount1 = Integer.parseInt(typeaccount); | |
348 | - if (typeaccount1==2){ | |
349 | - auserID =childssID; | |
350 | - }else { | |
351 | - auserID =id; | |
352 | - } | |
353 | - | |
354 | - HttpManager.getInstance().getsignatures(MainActivity.this, auserID, typeaccount1, handler); | |
355 | - | |
356 | - } catch (NumberFormatException e) { | |
357 | - e.printStackTrace(); | |
358 | - } | |
359 | 333 | |
360 | 334 | |
361 | 335 | } |
... | ... | @@ -401,11 +375,11 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe |
401 | 375 | case R.id.iv_setting: |
402 | 376 | mTopRightMenu = new TopRightMenu(MainActivity.this); |
403 | 377 | List<MenuItem> menuItems = new ArrayList<>(); |
404 | - menuItems.add(new MenuItem(R.mipmap.blank, "切换账户")); | |
405 | - menuItems.add(new MenuItem(R.mipmap.blank, "账户管理")); | |
378 | + menuItems.add(new MenuItem(R.mipmap.blank, " 切换账户")); | |
379 | + menuItems.add(new MenuItem(R.mipmap.blank, " 账户管理")); | |
406 | 380 | mTopRightMenu |
407 | 381 | .setHeight(150) //默认高度480 |
408 | - .setWidth(320) //默认宽度wrap_content | |
382 | + .setWidth(180) //默认宽度wrap_content | |
409 | 383 | .showIcon(showIcon) //显示菜单图标,默认为true |
410 | 384 | .dimBackground(dimBg) //背景变暗,默认为true |
411 | 385 | .needAnimationStyle(needAnim) //显示动画,默认为true |
... | ... | @@ -426,9 +400,9 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe |
426 | 400 | public void onClick(View v) { |
427 | 401 | String graderID = SaveParam.getInstance().getLoginParam(MainActivity.this, SaveParam.GRADENS); |
428 | 402 | int graderIDs = Integer.parseInt(graderID); |
429 | - if (graderIDs<8){ | |
403 | + if (graderIDs < 8) { | |
430 | 404 | Intent intentbroad = new Intent(); |
431 | - intentbroad.putExtra("info","小学"); | |
405 | + intentbroad.putExtra("info", "小学"); | |
432 | 406 | //4、定义广播发送的action |
433 | 407 | intentbroad.setAction("com.ozing.launcher.SWITCH_GRADE"); |
434 | 408 | //5、发送广播 |
... | ... | @@ -456,7 +430,7 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe |
456 | 430 | } |
457 | 431 | }) |
458 | 432 | .addMenuList(menuItems) |
459 | - .showAsDropDown(iv_setting, -250, 0); | |
433 | + .showAsDropDown(iv_setting, -120, 0); | |
460 | 434 | break; |
461 | 435 | case R.id.iv_sign: |
462 | 436 | new CircleDialog.Builder(this) |
... | ... | @@ -486,9 +460,16 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe |
486 | 460 | try { |
487 | 461 | String typeaccount = SaveParam.getInstance().getCustomizeParam(MainActivity.this, SaveParam.ACCOUNT); |
488 | 462 | String userID = SaveParam.getInstance().getLoginParam(MainActivity.this, "userId"); |
463 | + String childsID = SaveParam.getInstance().getCustomizeParam(MainActivity.this, SaveParam.CHILDSID); | |
464 | + Object id = null; | |
489 | 465 | long auserID = Long.parseLong(userID); |
490 | 466 | int typeaccount1 = Integer.parseInt(typeaccount); |
491 | - HttpManager.getInstance().changsignature(MainActivity.this, auserID, typeaccount1, text); | |
467 | + if (typeaccount1 ==2){ | |
468 | + id =childsID; | |
469 | + }else { | |
470 | + id =auserID; | |
471 | + } | |
472 | + HttpManager.getInstance().changsignature(MainActivity.this, id, typeaccount1, text); | |
492 | 473 | RecyclerViewadapterpublish.notifyDataSetChanged(); |
493 | 474 | } catch (NumberFormatException e) { |
494 | 475 | e.printStackTrace(); |
... | ... | @@ -538,17 +519,25 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe |
538 | 519 | protected void onResume() { |
539 | 520 | super.onResume(); |
540 | 521 | String userID = SaveParam.getInstance().getLoginParam(this, "userId"); |
541 | - //账户类型 | |
542 | - String accounts = SaveParam.getInstance().getCustomizeParam(this, SaveParam.ACCOUNT); | |
522 | + //获取个性签名 | |
523 | + String typeaccount = SaveParam.getInstance().getCustomizeParam(this, SaveParam.ACCOUNT); | |
524 | + String childsID = SaveParam.getInstance().getCustomizeParam(this, SaveParam.CHILDSID); | |
525 | + | |
543 | 526 | try { |
544 | - int graderID; | |
545 | - long auserID = Long.parseLong(userID); | |
546 | - int typeaccount1 = Integer.parseInt(accounts); | |
547 | - //获取最近播放视频 | |
548 | - HttpManager.getInstance().getstuyvidioinfo(this, auserID, handler); | |
527 | + Object auserID = 1; | |
528 | + long id = Long.parseLong(userID); | |
529 | + int typeaccount1 = Integer.parseInt(typeaccount); | |
549 | 530 | //获取个人信息 |
550 | - HttpManager.getInstance().getpresonalinfo(MainActivity.this, auserID, typeaccount1, handler); | |
551 | - | |
531 | + HttpManager.getInstance().getpresonalinfo(MainActivity.this, id, typeaccount1, handler); | |
532 | + if (typeaccount1 == 2) { | |
533 | + auserID = childsID; | |
534 | + } else { | |
535 | + auserID = id; | |
536 | + } | |
537 | + Log.e("test","个性签名的ID"+auserID); | |
538 | + HttpManager.getInstance().getsignatures(MainActivity.this, auserID, typeaccount1, handler); | |
539 | + //获取最近播放视频 | |
540 | + HttpManager.getInstance().getstuyvidioinfo(this, auserID, handler); | |
552 | 541 | |
553 | 542 | } catch (NumberFormatException e) { |
554 | 543 | e.printStackTrace(); |
... | ... | @@ -629,6 +618,7 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe |
629 | 618 | } |
630 | 619 | |
631 | 620 | } |
621 | + | |
632 | 622 | //照相 |
633 | 623 | private void uploadAvatarFromPhotoRequest() { |
634 | 624 | Intent intent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE); |
... | ... | @@ -761,7 +751,6 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe |
761 | 751 | } |
762 | 752 | |
763 | 753 | |
764 | - | |
765 | 754 | private long exitTime = 0; |
766 | 755 | |
767 | 756 | @Override | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/MyApplication.java
... | ... | @@ -12,7 +12,6 @@ import com.facebook.drawee.backends.pipeline.Fresco; |
12 | 12 | import com.hjx.personalcenter.R; |
13 | 13 | import com.hjx.personalcenter.crash.CrashHandler; |
14 | 14 | import com.hjx.personalcenter.util.ImageCache; |
15 | -import com.squareup.leakcanary.LeakCanary; | |
16 | 15 | import com.tencent.bugly.crashreport.CrashReport; |
17 | 16 | |
18 | 17 | /** |
... | ... | @@ -28,7 +27,7 @@ public class MyApplication extends Application { |
28 | 27 | public void onCreate() { |
29 | 28 | context = getApplicationContext(); |
30 | 29 | //c初始化内存检测 |
31 | - LeakCanary.install(this); | |
30 | + // LeakCanary.install(this); | |
32 | 31 | //初始化Fresco |
33 | 32 | Fresco.initialize(this); |
34 | 33 | mImageCache = new ImageCache(); | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/RegisterInfoActivity.java
... | ... | @@ -2,9 +2,8 @@ package com.hjx.personalcenter.activity; |
2 | 2 | |
3 | 3 | import android.content.Intent; |
4 | 4 | import android.os.Bundle; |
5 | -import android.support.v7.app.AppCompatActivity; | |
5 | +import android.support.v4.app.FragmentActivity; | |
6 | 6 | import android.text.TextUtils; |
7 | -import android.view.KeyEvent; | |
8 | 7 | import android.view.View; |
9 | 8 | import android.widget.Button; |
10 | 9 | import android.widget.EditText; |
... | ... | @@ -35,7 +34,7 @@ import java.util.ArrayList; |
35 | 34 | * Created by h on 2017/8/9. |
36 | 35 | */ |
37 | 36 | |
38 | -public class RegisterInfoActivity extends AppCompatActivity implements View.OnClickListener, DialogCallBack.GradeCallBack, DialogCallBack.ProvincesCallBack | |
37 | +public class RegisterInfoActivity extends FragmentActivity implements View.OnClickListener, DialogCallBack.GradeCallBack, DialogCallBack.ProvincesCallBack | |
39 | 38 | , DialogCallBack.CitysCallBack, DialogCallBack.CountryCallBack, DialogCallBack.SchoolCallBack { |
40 | 39 | private EditText et_username; |
41 | 40 | private TextView et_region, et_grade, et_school; |
... | ... | @@ -211,14 +210,6 @@ public class RegisterInfoActivity extends AppCompatActivity implements View.OnCl |
211 | 210 | |
212 | 211 | } |
213 | 212 | |
214 | - @Override | |
215 | - public boolean onKeyUp(int keyCode, KeyEvent event) { | |
216 | - if (keyCode == KeyEvent.KEYCODE_BACK) { | |
217 | - finish(); | |
218 | - | |
219 | - } | |
220 | - return super.onKeyUp(keyCode, event); | |
221 | - } | |
222 | 213 | |
223 | 214 | @Override |
224 | 215 | public void province3OnItemClick(ArrayList<GradeInfo.DataBean.ChildrenBean> data, int position, int type) { | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/activity/TheStartPageActivity.java
... | ... | @@ -2,7 +2,7 @@ package com.hjx.personalcenter.activity; |
2 | 2 | |
3 | 3 | import android.content.Intent; |
4 | 4 | import android.os.Bundle; |
5 | -import android.support.v7.app.AppCompatActivity; | |
5 | +import android.support.v4.app.FragmentActivity; | |
6 | 6 | import android.view.KeyEvent; |
7 | 7 | import android.view.View; |
8 | 8 | import android.widget.Button; |
... | ... | @@ -14,7 +14,7 @@ import com.hjx.personalcenter.db.SaveParam; |
14 | 14 | * Created by h on 2017/8/10. |
15 | 15 | */ |
16 | 16 | |
17 | -public class TheStartPageActivity extends AppCompatActivity implements View.OnClickListener { | |
17 | +public class TheStartPageActivity extends FragmentActivity implements View.OnClickListener { | |
18 | 18 | private Button btn_start; |
19 | 19 | @Override |
20 | 20 | protected void onCreate(Bundle savedInstanceState) { | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/adapter/AccountChildsAdapter.java
... | ... | @@ -5,6 +5,7 @@ import android.content.Context; |
5 | 5 | import android.content.Intent; |
6 | 6 | import android.support.v4.app.FragmentActivity; |
7 | 7 | import android.support.v7.widget.RecyclerView; |
8 | +import android.util.Log; | |
8 | 9 | import android.view.LayoutInflater; |
9 | 10 | import android.view.View; |
10 | 11 | import android.view.ViewGroup; |
... | ... | @@ -167,6 +168,24 @@ public class AccountChildsAdapter extends RecyclerView.Adapter<RecyclerView.View |
167 | 168 | @Override |
168 | 169 | public void onClick(View v) { |
169 | 170 | Content.changgeaccountflag = 2; |
171 | + String ss = SaveParam.getInstance().getLoginParam(mContext, SaveParam.GRADENS); | |
172 | + try { | |
173 | + int zhugrade = Integer.parseInt(ss); | |
174 | + int zigrade =Integer.parseInt(bean.getGradeId()); | |
175 | + if ((zhugrade < 8)&&(zigrade>=8)||(zhugrade >= 8)&&(zigrade<8)) { | |
176 | + Intent intentbroad = new Intent(); | |
177 | + intentbroad.putExtra("info", "小学"); | |
178 | + //4、定义广播发送的action | |
179 | + intentbroad.setAction("com.ozing.launcher.SWITCH_GRADE"); | |
180 | + //5、发送广播 | |
181 | + mContext.sendBroadcast(intentbroad); | |
182 | + Log.i("---", "发送完了"); | |
183 | + } | |
184 | + | |
185 | + } catch (NumberFormatException e) { | |
186 | + e.printStackTrace(); | |
187 | + } | |
188 | + | |
170 | 189 | SaveParam.getInstance().saveCustomizeParam(mContext, SaveParam.ACCOUNT, "2"); |
171 | 190 | SaveParam.getInstance().saveCustomizeParam(mContext, SaveParam.CHILDSID, bean.getSubAccountId()); |
172 | 191 | //保存子账号年级id | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/customdialog/SchoolListDialog.java
... | ... | @@ -96,7 +96,7 @@ public class SchoolListDialog extends BaseCircleDialog implements AdapterView.On |
96 | 96 | school_sech = (EditText) getView().findViewById(R.id.et_school_sech); |
97 | 97 | cance = (ImageView) getView().findViewById(R.id.cancel); |
98 | 98 | String citys = SaveParam.getInstance().getsaveCityParam(getActivity(), SaveParam.CITYS); |
99 | - String country = SaveParam.getInstance().getLoginParam(getActivity(), SaveParam.ADRESSID); | |
99 | + String country = SaveParam.getInstance().getsaveCityParam(getActivity(), SaveParam.COUNTRY); | |
100 | 100 | if (country==null){ |
101 | 101 | country =citys; |
102 | 102 | } | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/db/SaveParam.java
... | ... | @@ -37,6 +37,7 @@ public class SaveParam { |
37 | 37 | public static String ACCOUNTXINGZUO = "accountxingzuo";//详细地址 |
38 | 38 | public static String PORTAIT = "portrait";//头像 |
39 | 39 | public static String ADRESSID = "adressid";//地址id |
40 | + public static String MAINSHOOLID = "mainshoolid";//地址id | |
40 | 41 | |
41 | 42 | //电子保卡信息 |
42 | 43 | public static String CARDPHONE = "cardphone";//保卡手机号 | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/fragment/PresonInfoFragment.java
... | ... | @@ -242,25 +242,41 @@ public class PresonInfoFragment extends Fragment implements View.OnClickListener |
242 | 242 | } else { |
243 | 243 | int a = 0, b = 0; |
244 | 244 | int d = 1,gradeold =0; |
245 | + Long f ; | |
245 | 246 | Object schoolids; |
246 | - Long f = null; | |
247 | 247 | String regionId2 = SaveParam.getInstance().getsaveCityParam(getActivity(), SaveParam.COUNTRY); |
248 | 248 | String regionId1 = SaveParam.getInstance().getsaveCityParam(getActivity(), SaveParam.CITYS); |
249 | - String regionId = SaveParam.getInstance().getLoginParam(getActivity(), SaveParam.ADRESSID); | |
250 | - if (regionId == null ) { | |
251 | - if (regionId1!=null){ | |
252 | - regionId = regionId1; | |
249 | + String regionId = null; | |
250 | + if (regionId2 ==null&®ionId1==null){ | |
251 | + regionId =SaveParam.getInstance().getLoginParam(getActivity(), SaveParam.ADRESSID); | |
252 | + }else { | |
253 | + if (regionId2==null){ | |
254 | + regionId =regionId1; | |
253 | 255 | }else { |
254 | - regionId = regionId2; | |
256 | + regionId =regionId2; | |
255 | 257 | } |
256 | - | |
257 | 258 | } |
258 | - String gradeolds = SaveParam.getInstance().getLoginParam(getActivity(), SaveParam.GRADENS); | |
259 | + | |
260 | + String gradenid =null; | |
261 | + String gradeolds = SaveParam.getInstance().getLoginParam(getActivity(), SaveParam.CHILDSGRADENS); | |
259 | 262 | String grade = SaveParam.getInstance().getLoginParam(getActivity(), SaveParam.GRADENS); |
260 | - String schoolid = SaveParam.getInstance().getLoginParam(getActivity(), SaveParam.SCHOOOlID); | |
263 | + if (grade.equals(gradeolds)||gradeolds == null){ | |
264 | + gradenid =grade; | |
265 | + }else { | |
266 | + gradenid =gradeolds; | |
267 | + } | |
268 | + String schoolid = null; | |
269 | + String mainshoolids = SaveParam.getInstance().getLoginParam(getActivity(), SaveParam.SCHOOOlID); | |
270 | + String mainschoolid = SaveParam.getInstance().getLoginParam(getActivity(), SaveParam.MAINSHOOLID); | |
271 | + if (mainshoolids ==null||mainschoolid.equals(mainshoolids)){ | |
272 | + schoolid =mainschoolid; | |
273 | + }else { | |
274 | + schoolid =mainshoolids; | |
275 | + } | |
276 | + | |
261 | 277 | String type = SaveParam.getInstance().getCustomizeParam(getActivity(), SaveParam.ACCOUNT); |
262 | 278 | String userID = SaveParam.getInstance().getLoginParam(getActivity(), "userId"); |
263 | - String childsID = SaveParam.getInstance().getCustomizeParam(getActivity(), SaveParam.CHILDSID); | |
279 | + //String childsID = SaveParam.getInstance().getCustomizeParam(getActivity(), SaveParam.CHILDSID); | |
264 | 280 | |
265 | 281 | String devicenumber = GetDevicesUtil.getDevicesInfo(getActivity()).getDeviceNumber(); |
266 | 282 | String changeinfo = null; |
... | ... | @@ -271,9 +287,9 @@ public class PresonInfoFragment extends Fragment implements View.OnClickListener |
271 | 287 | } |
272 | 288 | try { |
273 | 289 | a = Integer.parseInt(regionId); |
274 | - b = Integer.parseInt(grade); | |
275 | - gradeold = Integer.parseInt(gradeolds); | |
276 | - if ((gradeold<8&&b>=8)||((gradeold>8&&b<=8))){ | |
290 | + b = Integer.parseInt(gradenid); | |
291 | + gradeold = Integer.parseInt(grade); | |
292 | + if ((b<8&&gradeold>=8)||((b>8&&gradeold<=8))){ | |
277 | 293 | Intent intentbroad = new Intent(); |
278 | 294 | intentbroad.putExtra("info","小学"); |
279 | 295 | //4、定义广播发送的action |
... | ... | @@ -288,13 +304,7 @@ public class PresonInfoFragment extends Fragment implements View.OnClickListener |
288 | 304 | schoolids = Long.parseLong(schoolid); |
289 | 305 | } |
290 | 306 | d = Integer.parseInt(type); |
291 | - if (d==2){ | |
292 | - f = Long.parseLong(childsID); | |
293 | - | |
294 | - }else{ | |
295 | - f = Long.parseLong(userID); | |
296 | - } | |
297 | - | |
307 | + f = Long.parseLong(userID); | |
298 | 308 | |
299 | 309 | //提交个人信息 |
300 | 310 | HttpManager.getInstance().changepresonalinfo(getActivity(), | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/http/HttpManager.java
... | ... | @@ -447,7 +447,7 @@ public class HttpManager { |
447 | 447 | //修改保卡信息电话 |
448 | 448 | public void changecardinfophone(final Context mContext, String userId, final String customerPhone, String authCode) { |
449 | 449 | RequestParams params = new RequestParams(); |
450 | - params.put("userId", userId); | |
450 | + params.put("deviceNumber", userId); | |
451 | 451 | params.put("customerPhone", customerPhone); |
452 | 452 | params.put("authCode", authCode); |
453 | 453 | HttpClient.getInstance().addHeader("Accept", "*/*"); |
... | ... | @@ -480,9 +480,9 @@ public class HttpManager { |
480 | 480 | } |
481 | 481 | |
482 | 482 | //修改保卡信息地址 |
483 | - public void changecardadressinfo(final Context mContext, long userId, final String customerPhone, String authCode, final String customerAddress) { | |
483 | + public void changecardadressinfo(final Context mContext, String userId, final String customerPhone, String authCode, final String customerAddress) { | |
484 | 484 | RequestParams params = new RequestParams(); |
485 | - params.put("userId", userId); | |
485 | + params.put("deviceNumber", userId); | |
486 | 486 | params.put("customerPhone", customerPhone); |
487 | 487 | params.put("authCode", authCode); |
488 | 488 | params.put("customerAddress", customerAddress); |
... | ... | @@ -675,7 +675,7 @@ public class HttpManager { |
675 | 675 | public void changepresonalinfo(final Context mContext, Long id, int type |
676 | 676 | , String name, String birthday, int gradeId, long regionId, |
677 | 677 | Object schoolId, String qq, String gender |
678 | - , String regionName,String address, String devicenumber) throws UnsupportedEncodingException { | |
678 | + , String regionName, String address, String devicenumber) throws UnsupportedEncodingException { | |
679 | 679 | mProgress = DialogPermission.showProgress(mContext, null, "正在保存个人信息...", |
680 | 680 | false, true, null); |
681 | 681 | RequestParams params = new RequestParams(); |
... | ... | @@ -819,7 +819,7 @@ public class HttpManager { |
819 | 819 | } |
820 | 820 | |
821 | 821 | //修改个性签名 |
822 | - public void changsignature(final Context mContext, long userId, int type, final String signature) { | |
822 | + public void changsignature(final Context mContext, Object userId, int type, final String signature) { | |
823 | 823 | RequestParams params = new RequestParams(); |
824 | 824 | params.put("userId", userId); |
825 | 825 | params.put("type", type); |
... | ... | @@ -856,7 +856,7 @@ public class HttpManager { |
856 | 856 | * @param userId |
857 | 857 | * @param handler |
858 | 858 | */ |
859 | - public void getsignatures(final Context mContext, long userId, int type, final Handler handler) { | |
859 | + public void getsignatures(final Context mContext, Object userId, int type, final Handler handler) { | |
860 | 860 | HttpClient.getInstance().addHeader("Accept", "text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8"); |
861 | 861 | HttpClient.getInstance().get(HttpUrl.getsignature + "?userId=" + userId + "&type=" + type, new AsyncHttpResponseHandler() { |
862 | 862 | @Override |
... | ... | @@ -1335,7 +1335,7 @@ public class HttpManager { |
1335 | 1335 | * @param mContext |
1336 | 1336 | * @param userId |
1337 | 1337 | */ |
1338 | - public void getstuyvidioinfo(final Context mContext, long userId, final Handler handler) { | |
1338 | + public void getstuyvidioinfo(final Context mContext, Object userId, final Handler handler) { | |
1339 | 1339 | mProgress = DialogPermission.showProgress(mContext, null, "正在获取最近学习视频...", |
1340 | 1340 | false, true, null); |
1341 | 1341 | HttpClient.getInstance().setTimeout(5 * 1000); |
... | ... | @@ -1356,9 +1356,11 @@ public class HttpManager { |
1356 | 1356 | msg.obj = schoolInfoBeanList; |
1357 | 1357 | handler.sendMessage(msg); |
1358 | 1358 | |
1359 | - } else { | |
1360 | - AlertUtils.showToast(mContext, "你好,服务器异常,请稍后再试!"); | |
1359 | + } else if (status == 1000){ | |
1360 | + //AlertUtils.showToast(mContext, "暂无最近学习视频!"); | |
1361 | 1361 | |
1362 | + }else { | |
1363 | + AlertUtils.showToast(mContext, "无法链接到服务器,请检查您的网络或稍后重试!"); | |
1362 | 1364 | } |
1363 | 1365 | } catch (JSONException e) { |
1364 | 1366 | e.printStackTrace(); | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/http/HttpUrl.java
1 | 1 | package com.hjx.personalcenter.http; |
2 | 2 | |
3 | +import com.hjx.personalcenter.BuildConfig; | |
4 | + | |
3 | 5 | /** |
4 | 6 | * Created by h on 2017/8/15. |
5 | 7 | */ |
6 | 8 | |
7 | 9 | public class HttpUrl { |
8 | 10 | private final static String Enviroment = "DEVELOPMENT"; |
9 | - | |
11 | + //BuildConfig.BUILD_TYPE.equals("release") ? "http://boss.hjx.com" : "http://boss.test.hjx.com" ; | |
10 | 12 | public static String GetDomain(){ |
11 | - return Enviroment.equals("DEVELOPMENT") ? "http://boss.test.hjx.com" : "http://boss.hjx.com"; | |
13 | + return BuildConfig.BUILD_TYPE.equals("release") ? "http://boss.hjx.com" : "http://boss.test.hjx.com" ; | |
12 | 14 | } |
13 | 15 | |
14 | 16 | public static String loginUrl = GetDomain()+"/user/access_token";//登录 | ... | ... |
PersonalCenter/app/src/main/java/com/hjx/personalcenter/model/SignInfo.java
... | ... | @@ -68,14 +68,14 @@ public class SignInfo implements Serializable{ |
68 | 68 | * signature : 广告广告广告费 |
69 | 69 | */ |
70 | 70 | |
71 | - private long userId; | |
71 | + private String userId; | |
72 | 72 | private String signature; |
73 | 73 | |
74 | - public long getUserId() { | |
74 | + public String getUserId() { | |
75 | 75 | return userId; |
76 | 76 | } |
77 | 77 | |
78 | - public void setUserId(long userId) { | |
78 | + public void setUserId(String userId) { | |
79 | 79 | this.userId = userId; |
80 | 80 | } |
81 | 81 | ... | ... |
PersonalCenter/app/src/main/res/layout/activity_account_management_add.xml
... | ... | @@ -6,7 +6,7 @@ |
6 | 6 | <LinearLayout |
7 | 7 | android:id="@+id/add_account" |
8 | 8 | android:layout_width="400dp" |
9 | - android:layout_height="165dp" | |
9 | + android:layout_height="158dp" | |
10 | 10 | android:layout_alignParentRight="true" |
11 | 11 | android:layout_marginRight="20dp" |
12 | 12 | android:background="@drawable/corcle_black_bg" | ... | ... |
PersonalCenter/app/src/main/res/layout/activity_electroniccard_info.xml
... | ... | @@ -74,7 +74,9 @@ |
74 | 74 | android:layout_width="0dp" |
75 | 75 | android:layout_height="80dp" |
76 | 76 | android:layout_weight="1" |
77 | - android:gravity="center_vertical"> | |
77 | + android:gravity="center_vertical" | |
78 | + android:focusable="true" | |
79 | + android:focusableInTouchMode="true"> | |
78 | 80 | |
79 | 81 | <TextView |
80 | 82 | android:layout_width="wrap_content" |
... | ... | @@ -88,7 +90,8 @@ |
88 | 90 | android:layout_height="wrap_content" |
89 | 91 | android:layout_marginLeft="50dp" |
90 | 92 | android:background="@null" |
91 | - android:textColor="@color/electronic_text" | |
93 | + android:padding="20dp" | |
94 | + android:textColor="@color/login_text_black" | |
92 | 95 | android:hint="请输入" |
93 | 96 | android:textSize="22sp" /> |
94 | 97 | |
... | ... | @@ -111,7 +114,8 @@ |
111 | 114 | android:layout_width="wrap_content" |
112 | 115 | android:layout_height="wrap_content" |
113 | 116 | android:layout_marginLeft="20dp" |
114 | - android:textColor="@color/electronic_text" | |
117 | + android:padding="20dp" | |
118 | + android:textColor="@color/login_text_black" | |
115 | 119 | android:hint="请选择地区" |
116 | 120 | android:textSize="22sp" /> |
117 | 121 | |
... | ... | @@ -119,6 +123,7 @@ |
119 | 123 | android:id="@+id/shopdizhi" |
120 | 124 | android:layout_width="wrap_content" |
121 | 125 | android:layout_height="wrap_content" |
126 | + android:padding="20dp" | |
122 | 127 | android:layout_marginLeft="60dp" |
123 | 128 | android:src="@mipmap/xiajiantou"> |
124 | 129 | |
... | ... | @@ -175,8 +180,9 @@ |
175 | 180 | android:layout_width="wrap_content" |
176 | 181 | android:layout_height="wrap_content" |
177 | 182 | android:layout_marginLeft="50dp" |
178 | - android:textColor="@color/electronic_text" | |
183 | + android:textColor="@color/login_text_black" | |
179 | 184 | android:hint="请选择地区" |
185 | + android:padding="20dp" | |
180 | 186 | android:textSize="22sp" /> |
181 | 187 | |
182 | 188 | <ImageView |
... | ... | @@ -184,6 +190,7 @@ |
184 | 190 | android:layout_width="wrap_content" |
185 | 191 | android:layout_height="wrap_content" |
186 | 192 | android:layout_marginLeft="60dp" |
193 | + android:padding="20dp" | |
187 | 194 | android:src="@mipmap/xiajiantou"> |
188 | 195 | |
189 | 196 | </ImageView> |
... | ... | @@ -210,7 +217,8 @@ |
210 | 217 | android:layout_height="wrap_content" |
211 | 218 | android:layout_marginLeft="20dp" |
212 | 219 | android:background="@null" |
213 | - android:textColor="@color/electronic_text" | |
220 | + android:padding="20dp" | |
221 | + android:textColor="@color/login_text_black" | |
214 | 222 | android:hint="请输入商店名称" |
215 | 223 | android:textSize="22sp" /> |
216 | 224 | |
... | ... | @@ -269,7 +277,8 @@ |
269 | 277 | android:layout_height="wrap_content" |
270 | 278 | android:layout_marginLeft="100dp" |
271 | 279 | android:background="@null" |
272 | - android:textColor="@color/electronic_text" | |
280 | + android:padding="20dp" | |
281 | + android:textColor="@color/login_text_black" | |
273 | 282 | android:hint="请输入详细地址" |
274 | 283 | android:textSize="22sp" /> |
275 | 284 | |
... | ... | @@ -291,9 +300,10 @@ |
291 | 300 | android:id="@+id/et_edit_telphone" |
292 | 301 | android:layout_width="wrap_content" |
293 | 302 | android:layout_height="wrap_content" |
303 | + android:padding="20dp" | |
294 | 304 | android:layout_marginLeft="20dp" |
295 | 305 | android:background="@null" |
296 | - android:textColor="@color/electronic_text" | |
306 | + android:textColor="@color/login_text_black" | |
297 | 307 | android:hint="请输入" |
298 | 308 | android:textSize="22sp" /> |
299 | 309 | </LinearLayout> |
... | ... | @@ -349,6 +359,7 @@ |
349 | 359 | android:id="@+id/tv_buy_time" |
350 | 360 | android:layout_width="wrap_content" |
351 | 361 | android:layout_height="wrap_content" |
362 | + android:textColor="@color/login_text_black" | |
352 | 363 | android:layout_marginLeft="50dp" |
353 | 364 | android:hint="请选择时间" |
354 | 365 | android:textSize="22sp" /> | ... | ... |
PersonalCenter/app/src/main/res/layout/activity_feedback.xml
... | ... | @@ -83,7 +83,7 @@ |
83 | 83 | android:hint="@string/qq" |
84 | 84 | android:inputType="number" |
85 | 85 | android:padding="20dp" |
86 | - android:layout_height="60dp" /> | |
86 | + android:layout_height="wrap_content" /> | |
87 | 87 | <TextView |
88 | 88 | android:layout_width="match_parent" |
89 | 89 | android:text="@string/hint" | ... | ... |
PersonalCenter/app/src/main/res/layout/activity_loginandregister.xml
... | ... | @@ -4,8 +4,7 @@ |
4 | 4 | android:id="@android:id/tabhost" |
5 | 5 | android:layout_width="fill_parent" |
6 | 6 | android:layout_height="fill_parent" |
7 | - android:background="@color/white" | |
8 | - tools:context="com.hjx.personalcenter.activity.LoginAndRegisterActivity"> | |
7 | + android:background="@color/white"> | |
9 | 8 | |
10 | 9 | |
11 | 10 | <ImageView | ... | ... |
PersonalCenter/app/src/main/res/layout/activity_main.xml
... | ... | @@ -314,7 +314,7 @@ |
314 | 314 | |
315 | 315 | <LinearLayout |
316 | 316 | android:layout_width="match_parent" |
317 | - android:layout_height="match_parent" | |
317 | + android:layout_height="100dp" | |
318 | 318 | android:background="@mipmap/xiaoguanggao"> |
319 | 319 | |
320 | 320 | </LinearLayout> |
... | ... | @@ -574,6 +574,7 @@ |
574 | 574 | <TextView |
575 | 575 | android:layout_width="wrap_content" |
576 | 576 | android:layout_height="wrap_content" |
577 | + android:layout_marginTop="10dp" | |
577 | 578 | android:layout_marginLeft="5dp" |
578 | 579 | android:text="版本信息" |
579 | 580 | android:textSize="22sp" /> |
... | ... | @@ -643,8 +644,7 @@ |
643 | 644 | android:layout_width="match_parent" |
644 | 645 | android:layout_height="match_parent" |
645 | 646 | android:gravity="center" |
646 | - android:orientation="vertical" | |
647 | - android:visibility="gone"> | |
647 | + android:orientation="vertical"> | |
648 | 648 | <ImageView |
649 | 649 | android:layout_width="wrap_content" |
650 | 650 | android:layout_height="wrap_content" | ... | ... |
PersonalCenter/app/src/main/res/layout/fragment_changge_presonal_info.xml
... | ... | @@ -125,12 +125,15 @@ |
125 | 125 | android:layout_width="0dp" |
126 | 126 | android:layout_height="80dp" |
127 | 127 | android:layout_weight="1" |
128 | - android:gravity="center_vertical"> | |
128 | + android:gravity="center_vertical" | |
129 | + android:focusable="true" | |
130 | + android:focusableInTouchMode="true"> | |
129 | 131 | |
130 | 132 | <TextView |
131 | 133 | android:layout_width="wrap_content" |
132 | 134 | android:layout_height="wrap_content" |
133 | 135 | android:text="昵称" |
136 | + android:textColor="@color/electronic_text" | |
134 | 137 | android:textSize="22sp" /> |
135 | 138 | |
136 | 139 | <EditText |
... | ... | @@ -155,6 +158,7 @@ |
155 | 158 | android:layout_width="wrap_content" |
156 | 159 | android:layout_height="wrap_content" |
157 | 160 | android:text="地区" |
161 | + android:textColor="@color/electronic_text" | |
158 | 162 | android:textSize="22sp" /> |
159 | 163 | |
160 | 164 | <TextView |
... | ... | @@ -162,6 +166,7 @@ |
162 | 166 | android:layout_width="wrap_content" |
163 | 167 | android:layout_height="wrap_content" |
164 | 168 | android:layout_marginLeft="50dp" |
169 | + android:textColor="@color/login_text_black" | |
165 | 170 | android:hint="请选择" |
166 | 171 | android:textSize="22sp" /> |
167 | 172 | |
... | ... | @@ -219,6 +224,7 @@ |
219 | 224 | android:layout_width="wrap_content" |
220 | 225 | android:layout_height="wrap_content" |
221 | 226 | android:text="性别" |
227 | + android:textColor="@color/electronic_text" | |
222 | 228 | android:textSize="22sp" /> |
223 | 229 | |
224 | 230 | <TextView |
... | ... | @@ -226,6 +232,7 @@ |
226 | 232 | android:layout_width="wrap_content" |
227 | 233 | android:layout_height="wrap_content" |
228 | 234 | android:layout_marginLeft="50dp" |
235 | + android:textColor="@color/login_text_black" | |
229 | 236 | android:hint="请选择" |
230 | 237 | android:textSize="22sp" /> |
231 | 238 | |
... | ... | @@ -312,6 +319,7 @@ |
312 | 319 | android:layout_width="wrap_content" |
313 | 320 | android:layout_height="wrap_content" |
314 | 321 | android:text="生日" |
322 | + android:textColor="@color/electronic_text" | |
315 | 323 | android:textSize="22sp" /> |
316 | 324 | |
317 | 325 | <TextView |
... | ... | @@ -320,6 +328,7 @@ |
320 | 328 | android:layout_height="wrap_content" |
321 | 329 | android:layout_marginLeft="50dp" |
322 | 330 | android:hint="请选择" |
331 | + android:textColor="@color/login_text_black" | |
323 | 332 | android:textSize="22sp" /> |
324 | 333 | |
325 | 334 | <ImageView |
... | ... | @@ -328,6 +337,7 @@ |
328 | 337 | android:layout_width="wrap_content" |
329 | 338 | android:layout_height="wrap_content" |
330 | 339 | android:layout_marginLeft="150dp" |
340 | + android:textColor="@color/login_text_black" | |
331 | 341 | android:src="@mipmap/xiajiantou"/> |
332 | 342 | </LinearLayout> |
333 | 343 | <LinearLayout |
... | ... | @@ -340,6 +350,7 @@ |
340 | 350 | android:layout_width="wrap_content" |
341 | 351 | android:layout_height="wrap_content" |
342 | 352 | android:text="年级" |
353 | + android:textColor="@color/electronic_text" | |
343 | 354 | android:textSize="22sp" /> |
344 | 355 | |
345 | 356 | <TextView |
... | ... | @@ -348,6 +359,7 @@ |
348 | 359 | android:layout_height="wrap_content" |
349 | 360 | android:layout_marginLeft="50dp" |
350 | 361 | android:hint="请选择" |
362 | + android:textColor="@color/login_text_black" | |
351 | 363 | android:textSize="22sp" /> |
352 | 364 | |
353 | 365 | <ImageView |
... | ... | @@ -404,6 +416,7 @@ |
404 | 416 | android:layout_width="wrap_content" |
405 | 417 | android:layout_height="wrap_content" |
406 | 418 | android:text="Q Q" |
419 | + android:textColor="@color/electronic_text" | |
407 | 420 | android:textSize="22sp" /> |
408 | 421 | |
409 | 422 | <EditText |
... | ... | @@ -429,6 +442,7 @@ |
429 | 442 | android:layout_width="wrap_content" |
430 | 443 | android:layout_height="wrap_content" |
431 | 444 | android:text="学校" |
445 | + android:textColor="@color/electronic_text" | |
432 | 446 | android:textSize="22sp" /> |
433 | 447 | |
434 | 448 | <TextView |
... | ... | @@ -437,6 +451,7 @@ |
437 | 451 | android:layout_height="wrap_content" |
438 | 452 | android:layout_marginLeft="50dp" |
439 | 453 | android:hint="请选择" |
454 | + android:textColor="@color/login_text_black" | |
440 | 455 | android:textSize="22sp" /> |
441 | 456 | |
442 | 457 | <ImageView | ... | ... |
PersonalCenter/app/src/main/res/layout/fragment_changge_version_info_itmes.xml
... | ... | @@ -3,26 +3,25 @@ |
3 | 3 | xmlns:fresco="http://schemas.android.com/apk/res-auto" |
4 | 4 | android:orientation="vertical" |
5 | 5 | android:layout_marginLeft="10dp" |
6 | - android:layout_width="wrap_content" | |
6 | + android:layout_width="match_parent" | |
7 | 7 | android:layout_height="wrap_content" |
8 | 8 | android:gravity="center"> |
9 | 9 | |
10 | 10 | |
11 | 11 | <com.facebook.drawee.view.SimpleDraweeView |
12 | 12 | android:id="@+id/image_publish" |
13 | - android:layout_width="120dp" | |
14 | - android:layout_height="100dp" | |
13 | + android:layout_width="180dp" | |
14 | + android:layout_height="120dp" | |
15 | 15 | android:layout_gravity="center" |
16 | 16 | android:background="@drawable/corcle_black_bg" |
17 | 17 | fresco:placeholderImage="@mipmap/header_default" |
18 | - fresco:roundAsCircle="true" | |
19 | 18 | fresco:placeholderImageScaleType="fitCenter" /> |
20 | 19 | |
21 | 20 | <TextView |
22 | 21 | android:id="@+id/subject" |
23 | 22 | android:layout_marginTop="5dp" |
24 | 23 | android:textSize="18sp" |
25 | - android:layout_width="100dp" | |
24 | + android:layout_width="160dp" | |
26 | 25 | android:layout_height="wrap_content" |
27 | 26 | android:width="100dp" |
28 | 27 | android:singleLine="true" | ... | ... |
PersonalCenter/app/src/main/res/mipmap-xhdpi/icon.png
3.75 KB
PersonalCenter/app/src/main/res/values/styles.xml
... | ... | @@ -46,13 +46,13 @@ |
46 | 46 | <item name="android:textSize">22sp</item> |
47 | 47 | <item name="android:gravity">center</item> |
48 | 48 | <item name="android:padding">10dp</item> |
49 | + | |
49 | 50 | </style> |
50 | - <style name="button_login_register_style"> | |
51 | + <style name="button_login_register_style" parent="@style/Widget.AppCompat.Button.Borderless"> | |
51 | 52 | <item name="android:layout_width">match_parent</item> |
52 | 53 | <item name="android:layout_height">wrap_content</item> |
53 | 54 | <item name="android:background">@drawable/selector_blue_btn_bg</item> |
54 | 55 | <item name="android:textSize">23sp</item> |
55 | - | |
56 | 56 | <item name="android:gravity">center</item> |
57 | 57 | <item name="android:padding">10dp</item> |
58 | 58 | <item name="android:textColor">@android:color/white</item> | ... | ... |