Commit 69e40270bec00e408fb8494212ad849b2158ca8d

Authored by 姚旭斌
2 parents 173b6348 9e6ee8e8

Merge branch 'developer' into yxb_dev

app/src/main/AndroidManifest.xml
@@ -112,7 +112,7 @@ @@ -112,7 +112,7 @@
112 android:name="com.amap.api.v2.apikey" 112 android:name="com.amap.api.v2.apikey"
113 android:value="1d130afb822d8a1019e6592cbaf10bcc"/> 113 android:value="1d130afb822d8a1019e6592cbaf10bcc"/>
114 114
115 - <activity android:name=".ui.MainActivity" 115 + <activity android:name=".ui.activity.StartActivity"
116 android:windowSoftInputMode="adjustPan|stateAlwaysHidden"> 116 android:windowSoftInputMode="adjustPan|stateAlwaysHidden">
117 <intent-filter> 117 <intent-filter>
118 <action android:name="android.intent.action.MAIN"/> 118 <action android:name="android.intent.action.MAIN"/>
@@ -130,7 +130,7 @@ @@ -130,7 +130,7 @@
130 <activity android:name=".ui.activity.consult.ConsultOneLevelActivity"/> 130 <activity android:name=".ui.activity.consult.ConsultOneLevelActivity"/>
131 <!-- <activity android:name=".ui.activity.LoginAndRegistActivity" /> --> 131 <!-- <activity android:name=".ui.activity.LoginAndRegistActivity" /> -->
132 <activity 132 <activity
133 - android:name=".ui.activity.StartActivity" 133 + android:name=".ui.MainActivity"
134 android:screenOrientation="portrait"/> 134 android:screenOrientation="portrait"/>
135 <activity 135 <activity
136 android:name=".ui.activity.ChildDetialActivity" 136 android:name=".ui.activity.ChildDetialActivity"
@@ -143,7 +143,7 @@ @@ -143,7 +143,7 @@
143 android:name=".ui.activity.binding.SelectSchoolActivity" 143 android:name=".ui.activity.binding.SelectSchoolActivity"
144 android:screenOrientation="portrait" 144 android:screenOrientation="portrait"
145 android:windowSoftInputMode="adjustPan|stateHidden"/> 145 android:windowSoftInputMode="adjustPan|stateHidden"/>
146 - android:windowSoftInputMode="adjustPan|stateHidden" /> 146 +
147 <activity android:name=".ui.activity.LoginAndRegistActivity" 147 <activity android:name=".ui.activity.LoginAndRegistActivity"
148 android:screenOrientation="portrait" 148 android:screenOrientation="portrait"
149 /> 149 />
app/src/main/java/com/shunzhi/parent/adapter/ChildAdapter.java
@@ -33,7 +33,7 @@ public class ChildAdapter extends BaseRecyclerViewAdapter&lt;ChildBean&gt; { @@ -33,7 +33,7 @@ public class ChildAdapter extends BaseRecyclerViewAdapter&lt;ChildBean&gt; {
33 33
34 @Override 34 @Override
35 public BaseRecyclerViewHolder onCreateViewHolder(ViewGroup parent, int viewType) { 35 public BaseRecyclerViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
36 - View view = LayoutInflater.from(context).inflate(R.layout.item_childlist, null); 36 + View view = LayoutInflater.from(context).inflate(R.layout.activity_web_view, null);
37 return new MyViewHolder(view); 37 return new MyViewHolder(view);
38 } 38 }
39 39
@@ -53,25 +53,29 @@ public class ChildAdapter extends BaseRecyclerViewAdapter&lt;ChildBean&gt; { @@ -53,25 +53,29 @@ public class ChildAdapter extends BaseRecyclerViewAdapter&lt;ChildBean&gt; {
53 53
54 @Override 54 @Override
55 public void onBindViewHolder(final ChildBean object, int position) { 55 public void onBindViewHolder(final ChildBean object, int position) {
56 - txt_childname.setText(object.getStudentName());  
57 - txt_childclass.setText(object.getSchoolName() + " " + object.getClassName());  
58 - itemView.setOnClickListener(new View.OnClickListener() {  
59 - @Override  
60 - public void onClick(View v) {  
61 - Gson g = new Gson();  
62 - String jsonString = g.toJson(object, ChildBean.class).toString();  
63 - context.startActivity(new Intent().putExtra("childJson", jsonString).setClass(context, ChildDetialActivity.class));  
64 - }  
65 - });  
66 -  
67 - go_buy.setOnClickListener(new View.OnClickListener() {  
68 - @Override  
69 - public void onClick(View v) {  
70 - WebViewActivity.getInstance(context,  
71 - AppConfig.BASE_URL_ORDER+"/ParentOrderCenter.aspx?userid="+  
72 - AppConfig.getAppConfig(AppContext.getInstance()).get(AppConfig.USER_ID),AppConfig.ORDER_CENTER);  
73 - }  
74 - }); 56 + try {
  57 + txt_childname.setText(object.getStudentName());
  58 + txt_childclass.setText(object.getSchoolName() + " " + object.getClassName());
  59 + itemView.setOnClickListener(new View.OnClickListener() {
  60 + @Override
  61 + public void onClick(View v) {
  62 + Gson g = new Gson();
  63 + String jsonString = g.toJson(object, ChildBean.class).toString();
  64 + context.startActivity(new Intent().putExtra("childJson", jsonString).setClass(context, ChildDetialActivity.class));
  65 + }
  66 + });
  67 +
  68 + go_buy.setOnClickListener(new View.OnClickListener() {
  69 + @Override
  70 + public void onClick(View v) {
  71 + WebViewActivity.getInstance(context,
  72 + AppConfig.BASE_URL_ORDER + "/ParentOrderCenter.aspx?userid=" +
  73 + AppConfig.getAppConfig(AppContext.getInstance()).get(AppConfig.USER_ID), AppConfig.ORDER_CENTER);
  74 + }
  75 + });
  76 + } catch (Exception e) {
  77 + e.printStackTrace();
  78 + }
75 } 79 }
76 80
77 } 81 }
app/src/main/java/com/shunzhi/parent/contract/consult/consultone/ConsultOneContract.java
@@ -26,6 +26,8 @@ public interface ConsultOneContract { @@ -26,6 +26,8 @@ public interface ConsultOneContract {
26 public abstract void getBanners(String position,String areaName); 26 public abstract void getBanners(String position,String areaName);
27 27
28 public abstract void getConsultContent(String areaName, int channel, int toFirstPage, int pageIndex); 28 public abstract void getConsultContent(String areaName, int channel, int toFirstPage, int pageIndex);
  29 +
  30 + public abstract void getInformationTopic(String keyword,String areaName,String channel,String toFirstPage,int pageIndex);
29 } 31 }
30 32
31 interface IConsultOneModel extends IBaseModel{ 33 interface IConsultOneModel extends IBaseModel{
@@ -34,6 +36,8 @@ public interface ConsultOneContract { @@ -34,6 +36,8 @@ public interface ConsultOneContract {
34 Observable<JsonObject> getBanners(String position,String areaName); 36 Observable<JsonObject> getBanners(String position,String areaName);
35 37
36 Observable<JsonObject> getConsultContent(String areaName, int channel, int toFirstPage, int pageIndex); 38 Observable<JsonObject> getConsultContent(String areaName, int channel, int toFirstPage, int pageIndex);
  39 +
  40 + Observable<JsonObject> getInformationTopic(String keyword,String areaName,String channel,String toFirstPage,int pageIndex);
37 } 41 }
38 42
39 interface IConsultOneView extends IBaseFragment{ 43 interface IConsultOneView extends IBaseFragment{
app/src/main/java/com/shunzhi/parent/presenter/ceping/CePingPresenter.java
@@ -41,6 +41,7 @@ public class CePingPresenter extends CepingContract.CePingPresenter { @@ -41,6 +41,7 @@ public class CePingPresenter extends CepingContract.CePingPresenter {
41 mRxManager.register(mIModel.getTools(areaName).subscribe(new Consumer<JsonObject>() { 41 mRxManager.register(mIModel.getTools(areaName).subscribe(new Consumer<JsonObject>() {
42 @Override 42 @Override
43 public void accept(JsonObject jsonObject) throws Exception { 43 public void accept(JsonObject jsonObject) throws Exception {
  44 +
44 if (jsonObject.get("status").getAsString().equals("1")){ 45 if (jsonObject.get("status").getAsString().equals("1")){
45 JsonArray jsonArray=jsonObject.getAsJsonArray("data"); 46 JsonArray jsonArray=jsonObject.getAsJsonArray("data");
46 layout_control.removeAllViews(); 47 layout_control.removeAllViews();
app/src/main/java/com/shunzhi/parent/presenter/consult/ConsultPresenter.java
@@ -68,6 +68,7 @@ public class ConsultPresenter extends ConsultContract.ConsultPresenter { @@ -68,6 +68,7 @@ public class ConsultPresenter extends ConsultContract.ConsultPresenter {
68 mRxManager.register(mIModel.getBanners(position, areaName).subscribe(new Consumer<JsonObject>() { 68 mRxManager.register(mIModel.getBanners(position, areaName).subscribe(new Consumer<JsonObject>() {
69 @Override 69 @Override
70 public void accept(JsonObject jsonObject) throws Exception { 70 public void accept(JsonObject jsonObject) throws Exception {
  71 + Log.d("666666","getBanners="+jsonObject.toString());
71 if (jsonObject.get("status").getAsString().equals("1")) { 72 if (jsonObject.get("status").getAsString().equals("1")) {
72 JsonArray jsonArray = jsonObject.getAsJsonArray("data"); 73 JsonArray jsonArray = jsonObject.getAsJsonArray("data");
73 List<GuangGaoBean> guangGaoBeanList = new ArrayList<>(); 74 List<GuangGaoBean> guangGaoBeanList = new ArrayList<>();
app/src/main/java/com/shunzhi/parent/presenter/consult/consultone/ConsultOnePresenter.java
@@ -93,7 +93,7 @@ public class ConsultOnePresenter extends ConsultOneContract.ConsultOnePresenter{ @@ -93,7 +93,7 @@ public class ConsultOnePresenter extends ConsultOneContract.ConsultOnePresenter{
93 JsonObject json=jsonObject.getAsJsonObject("data"); 93 JsonObject json=jsonObject.getAsJsonObject("data");
94 Gson g=new Gson(); 94 Gson g=new Gson();
95 ChannelInfo channelInfo = g.fromJson(json.toString(),ChannelInfo.class); 95 ChannelInfo channelInfo = g.fromJson(json.toString(),ChannelInfo.class);
96 - Log.e("ssss-===",channelInfo.toString()); 96 +// Log.e("ssss-===",channelInfo.toString());
97 List<ChannelContextBean> contextList = channelInfo.getChannelContent(); 97 List<ChannelContextBean> contextList = channelInfo.getChannelContent();
98 List<ChannelBean> channelList = channelInfo.getSubchannel(); 98 List<ChannelBean> channelList = channelInfo.getSubchannel();
99 mIView.showChannel(channelList); 99 mIView.showChannel(channelList);
@@ -109,6 +109,28 @@ public class ConsultOnePresenter extends ConsultOneContract.ConsultOnePresenter{ @@ -109,6 +109,28 @@ public class ConsultOnePresenter extends ConsultOneContract.ConsultOnePresenter{
109 109
110 } 110 }
111 111
  112 + @Override
  113 + public void getInformationTopic(String keyword, String areaName, String channel, String toFirstPage,int pageIndex) {
  114 + mRxManager.register(mIModel.getInformationTopic(keyword,areaName,channel,toFirstPage,pageIndex).subscribe(new Consumer<JsonObject>() {
  115 + @Override
  116 + public void accept(JsonObject jsonObject) throws Exception {
  117 + JsonObject json=jsonObject.getAsJsonObject("data");
  118 + Gson g=new Gson();
  119 + ChannelInfo channelInfo = g.fromJson(json.toString(),ChannelInfo.class);
  120 +// Log.e("ssss-===",channelInfo.toString());
  121 + List<ChannelContextBean> contextList = channelInfo.getChannelContent();
  122 + List<ChannelBean> channelList = channelInfo.getSubchannel();
  123 + mIView.showChannel(channelList);
  124 + mIView.showConsultContent(contextList);
  125 + }
  126 + }, new Consumer<Throwable>() {
  127 + @Override
  128 + public void accept(Throwable throwable) throws Exception {
  129 + OkHttpExceptionUtil.handOkHttpException((HttpException) throwable);
  130 + }
  131 + }));
  132 + }
  133 +
112 134
113 @Override 135 @Override
114 public ConsultOneContract.IConsultOneModel getModel() { 136 public ConsultOneContract.IConsultOneModel getModel() {
app/src/main/java/com/shunzhi/parent/ui/activity/mywebview/WebViewActivity.java
@@ -27,7 +27,7 @@ public class WebViewActivity extends BaseCompatActivity { @@ -27,7 +27,7 @@ public class WebViewActivity extends BaseCompatActivity {
27 27
28 NestedScrollWebView nesteScrollWebView; 28 NestedScrollWebView nesteScrollWebView;
29 LinearLayout binding_success, binding_success2; 29 LinearLayout binding_success, binding_success2;
30 - ImageView close; 30 + ImageView close_btn;
31 TextView tv_info,zuoye,title_web; 31 TextView tv_info,zuoye,title_web;
32 32
33 int type; 33 int type;
@@ -49,13 +49,13 @@ public class WebViewActivity extends BaseCompatActivity { @@ -49,13 +49,13 @@ public class WebViewActivity extends BaseCompatActivity {
49 binding_success=findViewById(R.id.binding_success1); 49 binding_success=findViewById(R.id.binding_success1);
50 50
51 binding_success2=findViewById(R.id.binding_success2); 51 binding_success2=findViewById(R.id.binding_success2);
52 - close = findViewById(R.id.close_btn); 52 + close_btn = findViewById(R.id.close_btn);
53 tv_info = findViewById(R.id.tv_info); 53 tv_info = findViewById(R.id.tv_info);
54 zuoye = findViewById(R.id.zuoye); 54 zuoye = findViewById(R.id.zuoye);
55 title_web = findViewById(R.id.title_web); 55 title_web = findViewById(R.id.title_web);
56 56
57 57
58 - close.setOnClickListener(new View.OnClickListener() { 58 + close_btn.setOnClickListener(new View.OnClickListener() {
59 @Override 59 @Override
60 public void onClick(View v) { 60 public void onClick(View v) {
61 onBackPressedSupport(); 61 onBackPressedSupport();
@@ -180,8 +180,8 @@ public class WebViewActivity extends BaseCompatActivity { @@ -180,8 +180,8 @@ public class WebViewActivity extends BaseCompatActivity {
180 @Override 180 @Override
181 public void onPageStarted(WebView view, String url, Bitmap favicon) { 181 public void onPageStarted(WebView view, String url, Bitmap favicon) {
182 // Log.d("666666","onPageStartedurl="+url); 182 // Log.d("666666","onPageStartedurl="+url);
183 - if (url.startsWith("http"))view.loadUrl(url);  
184 - view.getSettings().setJavaScriptEnabled(true); 183 +// if (url.startsWith("http"))view.loadUrl(url);
  184 +// view.getSettings().setJavaScriptEnabled(true);
185 super.onPageStarted(view, url, favicon); 185 super.onPageStarted(view, url, favicon);
186 } 186 }
187 187
app/src/main/java/com/shunzhi/parent/ui/activity/orderdetail/OrderDetailActivity.java
@@ -17,13 +17,16 @@ import com.share.mvpsdk.base.BasePresenter; @@ -17,13 +17,16 @@ import com.share.mvpsdk.base.BasePresenter;
17 import com.share.mvpsdk.base.activity.BaseMVPCompatActivity; 17 import com.share.mvpsdk.base.activity.BaseMVPCompatActivity;
18 import com.share.mvpsdk.base.adapter.BaseRecyclerViewAdapter; 18 import com.share.mvpsdk.base.adapter.BaseRecyclerViewAdapter;
19 import com.share.mvpsdk.base.adapter.BaseRecyclerViewHolder; 19 import com.share.mvpsdk.base.adapter.BaseRecyclerViewHolder;
  20 +import com.share.mvpsdk.base.adapter.OnItemClickListener;
20 import com.share.mvpsdk.utils.DateUtils; 21 import com.share.mvpsdk.utils.DateUtils;
21 import com.share.mvpsdk.utils.DisplayUtils; 22 import com.share.mvpsdk.utils.DisplayUtils;
  23 +import com.shunzhi.parent.AppConfig;
22 import com.shunzhi.parent.R; 24 import com.shunzhi.parent.R;
23 import com.shunzhi.parent.bean.orderdetail.OrderDetailBean; 25 import com.shunzhi.parent.bean.orderdetail.OrderDetailBean;
24 import com.shunzhi.parent.bean.orderdetail.OrderDetailBeanList; 26 import com.shunzhi.parent.bean.orderdetail.OrderDetailBeanList;
25 import com.shunzhi.parent.contract.orderdetail.OrderDetailContract; 27 import com.shunzhi.parent.contract.orderdetail.OrderDetailContract;
26 import com.shunzhi.parent.presenter.orederdetail.OrderDetailPresenter; 28 import com.shunzhi.parent.presenter.orederdetail.OrderDetailPresenter;
  29 +import com.shunzhi.parent.ui.activity.mywebview.WebViewActivity;
27 30
28 import java.util.List; 31 import java.util.List;
29 32
@@ -119,6 +122,14 @@ public class OrderDetailActivity extends BaseMVPCompatActivity&lt;OrderDetailContra @@ -119,6 +122,14 @@ public class OrderDetailActivity extends BaseMVPCompatActivity&lt;OrderDetailContra
119 tvDate.setText(object.date); 122 tvDate.setText(object.date);
120 123
121 myOrderBeanListAdapter.addAll(object.orderList); 124 myOrderBeanListAdapter.addAll(object.orderList);
  125 + myOrderBeanListAdapter.setOnItemClickListener(new OnItemClickListener() {
  126 + @Override
  127 + public void onItemClickListener(Object object, int position) {
  128 + OrderDetailBeanList orderDetailBeanList= (OrderDetailBeanList) object;
  129 + WebViewActivity.getInstance(OrderDetailActivity.this,
  130 + AppConfig.BASE_URL_ORDER+"OrderDetail.aspx?orderid="+orderDetailBeanList.orderId,-1);
  131 + }
  132 + });
122 133
123 } 134 }
124 135
@@ -154,7 +165,7 @@ public class OrderDetailActivity extends BaseMVPCompatActivity&lt;OrderDetailContra @@ -154,7 +165,7 @@ public class OrderDetailActivity extends BaseMVPCompatActivity&lt;OrderDetailContra
154 } 165 }
155 166
156 @Override 167 @Override
157 - public void onBindViewHolder(OrderDetailBeanList object, int position) { 168 + public void onBindViewHolder(final OrderDetailBeanList object, final int position) {
158 tvStartTIme_EndTime.setText(object.saleStartTime.split(" ")[0]+"-"+ 169 tvStartTIme_EndTime.setText(object.saleStartTime.split(" ")[0]+"-"+
159 object.saleEndTime.split(" ")[0]); 170 object.saleEndTime.split(" ")[0]);
160 tvProductName.setText(object.productName); 171 tvProductName.setText(object.productName);
@@ -168,7 +179,17 @@ public class OrderDetailActivity extends BaseMVPCompatActivity&lt;OrderDetailContra @@ -168,7 +179,17 @@ public class OrderDetailActivity extends BaseMVPCompatActivity&lt;OrderDetailContra
168 case 2://交易关闭 179 case 2://交易关闭
169 tvPayState.setText("交易关闭"); 180 tvPayState.setText("交易关闭");
170 break; 181 break;
  182 + case 3:
  183 + tvPayState.setText("支付失败");
  184 + break;
171 } 185 }
  186 +
  187 + layout_order_list.setOnClickListener(new View.OnClickListener() {
  188 + @Override
  189 + public void onClick(View view) {
  190 + onItemClickListener.onItemClickListener(object,position);
  191 + }
  192 + });
172 } 193 }
173 } 194 }
174 } 195 }
app/src/main/java/com/shunzhi/parent/ui/fragment/ConsultFragment.java
@@ -27,6 +27,7 @@ import com.shunzhi.parent.bean.channel.ChannelContextBean; @@ -27,6 +27,7 @@ import com.shunzhi.parent.bean.channel.ChannelContextBean;
27 import com.shunzhi.parent.contract.consult.ConsultContract; 27 import com.shunzhi.parent.contract.consult.ConsultContract;
28 import com.shunzhi.parent.presenter.consult.ConsultPresenter; 28 import com.shunzhi.parent.presenter.consult.ConsultPresenter;
29 import com.shunzhi.parent.ui.activity.consult.ConsultOneLevelActivity; 29 import com.shunzhi.parent.ui.activity.consult.ConsultOneLevelActivity;
  30 +import com.shunzhi.parent.ui.activity.mywebview.WebViewActivity;
30 import com.shunzhi.parent.util.AttrsUtils; 31 import com.shunzhi.parent.util.AttrsUtils;
31 import com.shunzhi.parent.views.TextAndImgShowView; 32 import com.shunzhi.parent.views.TextAndImgShowView;
32 import com.stx.xhb.xbanner.XBanner; 33 import com.stx.xhb.xbanner.XBanner;
@@ -69,7 +70,6 @@ public class ConsultFragment extends BaseMVPCompatFragment&lt;ConsultContract.Consu @@ -69,7 +70,6 @@ public class ConsultFragment extends BaseMVPCompatFragment&lt;ConsultContract.Consu
69 @Override 70 @Override
70 public void initUI(View view, @Nullable Bundle savedInstanceState) { 71 public void initUI(View view, @Nullable Bundle savedInstanceState) {
71 72
72 -  
73 recycler_context = view.findViewById(R.id.recycler_content); 73 recycler_context = view.findViewById(R.id.recycler_content);
74 initRecycler(); 74 initRecycler();
75 75
@@ -85,8 +85,8 @@ public class ConsultFragment extends BaseMVPCompatFragment&lt;ConsultContract.Consu @@ -85,8 +85,8 @@ public class ConsultFragment extends BaseMVPCompatFragment&lt;ConsultContract.Consu
85 videoplayer.backButton.setVisibility(View.GONE); 85 videoplayer.backButton.setVisibility(View.GONE);
86 86
87 // mPresenter.getTools(layout_control); 87 // mPresenter.getTools(layout_control);
88 - mPresenter.getBanners("2", "余杭区");  
89 - mPresenter.getContextChannel("余杭区", 0, 1, 1); 88 + mPresenter.getBanners("2", AppContext.getInstance().district);
  89 + mPresenter.getContextChannel(AppContext.getInstance().district, 0, 1, 1);
90 90
91 initBroadCast(); 91 initBroadCast();
92 92
@@ -114,6 +114,13 @@ public class ConsultFragment extends BaseMVPCompatFragment&lt;ConsultContract.Consu @@ -114,6 +114,13 @@ public class ConsultFragment extends BaseMVPCompatFragment&lt;ConsultContract.Consu
114 } 114 }
115 }); 115 });
116 116
  117 + xBanner.setOnItemClickListener(new XBanner.OnItemClickListener() {
  118 + @Override
  119 + public void onItemClick(XBanner banner, int position) {
  120 + WebViewActivity.getInstance(getContext(),imgesUrl.get(position),-1);
  121 + }
  122 + });
  123 +
117 } 124 }
118 125
119 @NonNull 126 @NonNull
app/src/main/java/com/shunzhi/parent/ui/fragment/ReportFragment.java
@@ -36,7 +36,7 @@ public class ReportFragment extends BaseMVPCompatFragment&lt;ReportContract.ReportP @@ -36,7 +36,7 @@ public class ReportFragment extends BaseMVPCompatFragment&lt;ReportContract.ReportP
36 36
37 MaterialCalendarView calendarView_month_mode; 37 MaterialCalendarView calendarView_month_mode;
38 38
39 - TextView tvDate,tvShaiXuan; 39 + TextView tvDate,tvShaiXuan,tvNoData;
40 40
41 ShaiXuanPop shaiXuanPop=null; 41 ShaiXuanPop shaiXuanPop=null;
42 42
@@ -57,6 +57,7 @@ public class ReportFragment extends BaseMVPCompatFragment&lt;ReportContract.ReportP @@ -57,6 +57,7 @@ public class ReportFragment extends BaseMVPCompatFragment&lt;ReportContract.ReportP
57 calendarView_month_mode = view.findViewById(R.id.calendarView_month_mode); 57 calendarView_month_mode = view.findViewById(R.id.calendarView_month_mode);
58 tvDate = view.findViewById(R.id.tvDate); 58 tvDate = view.findViewById(R.id.tvDate);
59 tvShaiXuan=view.findViewById(R.id.tvShaiXuan); 59 tvShaiXuan=view.findViewById(R.id.tvShaiXuan);
  60 + tvNoData=view.findViewById(R.id.tvNoData);
60 61
61 LinearLayoutManager layoutManager = new LinearLayoutManager(getActivity()); 62 LinearLayoutManager layoutManager = new LinearLayoutManager(getActivity());
62 layoutManager.setOrientation(LinearLayoutManager.VERTICAL); 63 layoutManager.setOrientation(LinearLayoutManager.VERTICAL);
@@ -117,6 +118,7 @@ public class ReportFragment extends BaseMVPCompatFragment&lt;ReportContract.ReportP @@ -117,6 +118,7 @@ public class ReportFragment extends BaseMVPCompatFragment&lt;ReportContract.ReportP
117 @Override 118 @Override
118 public void showReports(List<String> stringList) { 119 public void showReports(List<String> stringList) {
119 if (null!=shaiXuanPop){ 120 if (null!=shaiXuanPop){
  121 + if (stringList.size()>0)tvNoData.setVisibility(View.GONE);
120 shaiXuanPop.setDatas(stringList); 122 shaiXuanPop.setDatas(stringList);
121 shaiXuanPop.show(tvShaiXuan); 123 shaiXuanPop.show(tvShaiXuan);
122 } 124 }
app/src/main/java/com/shunzhi/parent/ui/fragment/StartFragment.java
@@ -7,11 +7,13 @@ import android.support.v4.view.ViewPager; @@ -7,11 +7,13 @@ import android.support.v4.view.ViewPager;
7 import android.text.TextUtils; 7 import android.text.TextUtils;
8 import android.view.View; 8 import android.view.View;
9 import android.widget.ImageView; 9 import android.widget.ImageView;
  10 +import android.widget.TextView;
10 11
11 import com.bumptech.glide.Glide; 12 import com.bumptech.glide.Glide;
12 import com.share.mvpsdk.base.BasePresenter; 13 import com.share.mvpsdk.base.BasePresenter;
13 import com.share.mvpsdk.base.fragment.BaseMVPCompatFragment; 14 import com.share.mvpsdk.base.fragment.BaseMVPCompatFragment;
14 import com.shunzhi.parent.AppConfig; 15 import com.shunzhi.parent.AppConfig;
  16 +import com.shunzhi.parent.AppContext;
15 import com.shunzhi.parent.R; 17 import com.shunzhi.parent.R;
16 import com.shunzhi.parent.bean.GuangGaoBean; 18 import com.shunzhi.parent.bean.GuangGaoBean;
17 import com.shunzhi.parent.bean.channel.ChannelBean; 19 import com.shunzhi.parent.bean.channel.ChannelBean;
@@ -29,6 +31,8 @@ public class StartFragment extends BaseMVPCompatFragment&lt;ConsultContract.Consult @@ -29,6 +31,8 @@ public class StartFragment extends BaseMVPCompatFragment&lt;ConsultContract.Consult
29 31
30 XBanner xBanner; 32 XBanner xBanner;
31 33
  34 + TextView tvJump;
  35 +
32 @Override 36 @Override
33 public int getLayoutId() { 37 public int getLayoutId() {
34 return R.layout.fragment_start; 38 return R.layout.fragment_start;
@@ -36,11 +40,23 @@ public class StartFragment extends BaseMVPCompatFragment&lt;ConsultContract.Consult @@ -36,11 +40,23 @@ public class StartFragment extends BaseMVPCompatFragment&lt;ConsultContract.Consult
36 40
37 @Override 41 @Override
38 public void initUI(View view, @Nullable Bundle savedInstanceState) { 42 public void initUI(View view, @Nullable Bundle savedInstanceState) {
  43 +
39 xBanner = view.findViewById(R.id.xBanner); 44 xBanner = view.findViewById(R.id.xBanner);
  45 + tvJump=view.findViewById(R.id.tvJump);
  46 +
40 if (!TextUtils.isEmpty(AppConfig.getAppConfig(getContext()).get(AppConfig.APP_IS_START))) { 47 if (!TextUtils.isEmpty(AppConfig.getAppConfig(getContext()).get(AppConfig.APP_IS_START))) {
41 - mPresenter.getBanners("0","杭州"); 48 + mPresenter.getBanners("0", "余杭区");
42 AppConfig.getAppConfig(getContext()).set(AppConfig.APP_IS_START, "1"); 49 AppConfig.getAppConfig(getContext()).set(AppConfig.APP_IS_START, "1");
43 - } else mPresenter.getBanners("1","杭州"); 50 + } else mPresenter.getBanners("1","余杭区");
  51 +
  52 +
  53 + tvJump.setOnClickListener(new View.OnClickListener() {
  54 + @Override
  55 + public void onClick(View view) {
  56 + startNewActivity(MainActivity.class);
  57 + }
  58 + });
  59 +
44 } 60 }
45 61
46 @NonNull 62 @NonNull
app/src/main/java/com/shunzhi/parent/ui/fragment/consult/ConsultOneLevelFragment.java
@@ -21,6 +21,7 @@ import com.share.mvpsdk.base.adapter.BaseRecyclerViewHolder; @@ -21,6 +21,7 @@ import com.share.mvpsdk.base.adapter.BaseRecyclerViewHolder;
21 import com.share.mvpsdk.base.fragment.BaseMVPCompatFragment; 21 import com.share.mvpsdk.base.fragment.BaseMVPCompatFragment;
22 import com.share.mvpsdk.utils.DisplayUtils; 22 import com.share.mvpsdk.utils.DisplayUtils;
23 import com.shunzhi.parent.AppConfig; 23 import com.shunzhi.parent.AppConfig;
  24 +import com.shunzhi.parent.AppContext;
24 import com.shunzhi.parent.R; 25 import com.shunzhi.parent.R;
25 import com.shunzhi.parent.adapter.MyConsultAdapter; 26 import com.shunzhi.parent.adapter.MyConsultAdapter;
26 import com.shunzhi.parent.bean.GuangGaoBean; 27 import com.shunzhi.parent.bean.GuangGaoBean;
@@ -85,8 +86,8 @@ public class ConsultOneLevelFragment extends BaseMVPCompatFragment&lt;ConsultOneCon @@ -85,8 +86,8 @@ public class ConsultOneLevelFragment extends BaseMVPCompatFragment&lt;ConsultOneCon
85 recyclerViewGrally = view.findViewById(R.id.recyclerViewGrally); 86 recyclerViewGrally = view.findViewById(R.id.recyclerViewGrally);
86 recyclerViewConsultOne = view.findViewById(R.id.recyclerViewConsultOne); 87 recyclerViewConsultOne = view.findViewById(R.id.recyclerViewConsultOne);
87 88
88 - mPresenter.getBanners("3","余杭");  
89 - mPresenter.getConsultContent("余杭区", 42, 0, 1); 89 + mPresenter.getBanners("3", AppContext.getInstance().district);
  90 + mPresenter.getConsultContent(AppContext.getInstance().district, 42, 0, 1);
90 // initRecyclerViewConsult(); 91 // initRecyclerViewConsult();
91 } 92 }
92 93
@@ -126,7 +127,6 @@ public class ConsultOneLevelFragment extends BaseMVPCompatFragment&lt;ConsultOneCon @@ -126,7 +127,6 @@ public class ConsultOneLevelFragment extends BaseMVPCompatFragment&lt;ConsultOneCon
126 127
127 @Override 128 @Override
128 public void showBanners(List<GuangGaoBean> guangGaoBeanList) { 129 public void showBanners(List<GuangGaoBean> guangGaoBeanList) {
129 - Log.d("6666","imgesUrl="+guangGaoBeanList);  
130 initRecyclerView(guangGaoBeanList); 130 initRecyclerView(guangGaoBeanList);
131 } 131 }
132 132
app/src/main/res/drawable/rudiobtn_unclick.xml
1 <?xml version="1.0" encoding="utf-8"?> 1 <?xml version="1.0" encoding="utf-8"?>
2 <shape android:shape="rectangle" xmlns:android="http://schemas.android.com/apk/res/android"> 2 <shape android:shape="rectangle" xmlns:android="http://schemas.android.com/apk/res/android">
3 <stroke android:color="#00000000" android:width="1dp"/> 3 <stroke android:color="#00000000" android:width="1dp"/>
4 - <solid android:color="#D2D2D2" /> 4 + <solid android:color="@color/xueqing_blue" />
5 <corners android:radius="5dp"/> 5 <corners android:radius="5dp"/>
6 </shape> 6 </shape>
7 \ No newline at end of file 7 \ No newline at end of file
app/src/main/res/layout/activity_mychild.xml
@@ -2,6 +2,7 @@ @@ -2,6 +2,7 @@
2 <LinearLayout 2 <LinearLayout
3 xmlns:android="http://schemas.android.com/apk/res/android" 3 xmlns:android="http://schemas.android.com/apk/res/android"
4 android:layout_width="match_parent" 4 android:layout_width="match_parent"
  5 + android:background="@color/bgColor"
5 android:layout_height="match_parent" 6 android:layout_height="match_parent"
6 android:orientation="vertical" 7 android:orientation="vertical"
7 > 8 >
@@ -24,9 +25,9 @@ @@ -24,9 +25,9 @@
24 android:text="添加绑定账号" 25 android:text="添加绑定账号"
25 android:textColor="@color/white" 26 android:textColor="@color/white"
26 android:textSize="@dimen/txtsize_title" 27 android:textSize="@dimen/txtsize_title"
  28 + android:layout_marginBottom="@dimen/size_dp_10"
27 android:gravity="center" 29 android:gravity="center"
28 android:background="@drawable/rudiobtn" 30 android:background="@drawable/rudiobtn"
29 - android:layout_marginBottom="10dp"  
30 /> 31 />
31 32
32 33
app/src/main/res/layout/fragment_login_and_regist.xml
@@ -3,6 +3,7 @@ @@ -3,6 +3,7 @@
3 xmlns:tools="http://schemas.android.com/tools" 3 xmlns:tools="http://schemas.android.com/tools"
4 android:layout_width="match_parent" 4 android:layout_width="match_parent"
5 android:layout_height="match_parent" 5 android:layout_height="match_parent"
  6 + android:background="@color/white"
6 tools:context="com.shunzhi.parent.ui.fragment.loginandregistfragment.LoginAndRegistFragment"> 7 tools:context="com.shunzhi.parent.ui.fragment.loginandregistfragment.LoginAndRegistFragment">
7 8
8 9
@@ -20,7 +21,7 @@ @@ -20,7 +21,7 @@
20 android:layout_width="60dp" 21 android:layout_width="60dp"
21 android:layout_height="20dp" 22 android:layout_height="20dp"
22 android:visibility="invisible" 23 android:visibility="invisible"
23 - android:src="@drawable/arrow_left" 24 + android:src="@drawable/back"
24 /> 25 />
25 </LinearLayout> 26 </LinearLayout>
26 27
@@ -59,6 +60,7 @@ @@ -59,6 +60,7 @@
59 android:text="" 60 android:text=""
60 android:maxLength="11" 61 android:maxLength="11"
61 android:textColorHint="@color/hintTextColor" 62 android:textColorHint="@color/hintTextColor"
  63 + android:textColor="@color/textColor"
62 android:textSize="@dimen/sp_16" /> 64 android:textSize="@dimen/sp_16" />
63 65
64 <TextView 66 <TextView
@@ -86,6 +88,7 @@ @@ -86,6 +88,7 @@
86 android:background="@null" 88 android:background="@null"
87 android:hint="请输入验证码" 89 android:hint="请输入验证码"
88 android:textColorHint="@color/hintTextColor" 90 android:textColorHint="@color/hintTextColor"
  91 + android:textColor="@color/textColor"
89 android:textSize="@dimen/sp_16" /> 92 android:textSize="@dimen/sp_16" />
90 93
91 <TextView 94 <TextView
app/src/main/res/layout/fragment_mine.xml
@@ -99,7 +99,7 @@ @@ -99,7 +99,7 @@
99 <LinearLayout 99 <LinearLayout
100 android:layout_width="match_parent" 100 android:layout_width="match_parent"
101 android:gravity="center_vertical" 101 android:gravity="center_vertical"
102 - android:layout_height="40dp"> 102 + android:layout_height="?android:actionBarSize">
103 103
104 <TextView 104 <TextView
105 android:layout_width="25dp" 105 android:layout_width="25dp"
@@ -136,7 +136,7 @@ @@ -136,7 +136,7 @@
136 <LinearLayout 136 <LinearLayout
137 android:id="@+id/layout_orderDetail" 137 android:id="@+id/layout_orderDetail"
138 android:layout_width="match_parent" 138 android:layout_width="match_parent"
139 - android:layout_height="40dp" 139 + android:layout_height="?android:actionBarSize"
140 android:gravity="center_vertical" 140 android:gravity="center_vertical"
141 141
142 > 142 >
@@ -167,7 +167,7 @@ @@ -167,7 +167,7 @@
167 <LinearLayout 167 <LinearLayout
168 android:id="@+id/layout_order" 168 android:id="@+id/layout_order"
169 android:layout_width="match_parent" 169 android:layout_width="match_parent"
170 - android:layout_height="40dp" 170 + android:layout_height="?android:actionBarSize"
171 android:gravity="center_vertical" 171 android:gravity="center_vertical"
172 > 172 >
173 173
@@ -197,7 +197,7 @@ @@ -197,7 +197,7 @@
197 <LinearLayout 197 <LinearLayout
198 android:id="@+id/childlayout" 198 android:id="@+id/childlayout"
199 android:layout_width="match_parent" 199 android:layout_width="match_parent"
200 - android:layout_height="40dp" 200 + android:layout_height="?android:actionBarSize"
201 android:gravity="center_vertical" 201 android:gravity="center_vertical"
202 > 202 >
203 203
app/src/main/res/layout/fragment_report.xml
@@ -46,6 +46,17 @@ @@ -46,6 +46,17 @@
46 android:textSize="@dimen/textSize16" /> 46 android:textSize="@dimen/textSize16" />
47 </LinearLayout> 47 </LinearLayout>
48 48
  49 + <TextView
  50 + android:layout_width="match_parent"
  51 + android:layout_height="match_parent"
  52 + android:textSize="@dimen/size_dp_16"
  53 + android:textColor="@color/xueqing_blue"
  54 + android:text="没有绑定孩子,\n请去个人中心绑定孩子"
  55 + android:gravity="center"
  56 + android:lineSpacingExtra="@dimen/size_dp_5"
  57 + android:id="@+id/tvNoData"
  58 + />
  59 +
49 <LinearLayout 60 <LinearLayout
50 android:layout_width="match_parent" 61 android:layout_width="match_parent"
51 android:layout_height="match_parent" 62 android:layout_height="match_parent"
app/src/main/res/layout/fragment_start.xml
@@ -2,6 +2,7 @@ @@ -2,6 +2,7 @@
2 xmlns:tools="http://schemas.android.com/tools" 2 xmlns:tools="http://schemas.android.com/tools"
3 android:layout_width="match_parent" 3 android:layout_width="match_parent"
4 android:layout_height="match_parent" 4 android:layout_height="match_parent"
  5 + android:background="@color/bgColor"
5 tools:context="com.shunzhi.parent.ui.fragment.StartFragment"> 6 tools:context="com.shunzhi.parent.ui.fragment.StartFragment">
6 7
7 <com.stx.xhb.xbanner.XBanner 8 <com.stx.xhb.xbanner.XBanner
@@ -9,4 +10,17 @@ @@ -9,4 +10,17 @@
9 android:layout_height="match_parent" 10 android:layout_height="match_parent"
10 android:id="@+id/xBanner" 11 android:id="@+id/xBanner"
11 ></com.stx.xhb.xbanner.XBanner> 12 ></com.stx.xhb.xbanner.XBanner>
  13 +
  14 + <TextView
  15 + android:id="@+id/tvJump"
  16 + android:layout_width="wrap_content"
  17 + android:layout_height="wrap_content"
  18 + android:text="跳过"
  19 + android:textColor="@color/white"
  20 + android:textSize="@dimen/size_dp_16"
  21 + android:padding="@dimen/size_dp_10"
  22 + android:layout_gravity="right"
  23 + android:layout_margin="@dimen/size_dp_10"
  24 + android:background="@drawable/shape_xueqing_radius8"
  25 + />
12 </FrameLayout> 26 </FrameLayout>
app/src/main/res/layout/item_childlist.xml
1 <?xml version="1.0" encoding="utf-8"?> 1 <?xml version="1.0" encoding="utf-8"?>
2 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" 2 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
3 android:layout_width="match_parent" 3 android:layout_width="match_parent"
  4 + android:background="@color/white"
  5 + android:divider="@color/divider_gray"
  6 + android:layout_marginTop="@dimen/size_dp_10"
4 android:layout_height="wrap_content"> 7 android:layout_height="wrap_content">
5 8
6 <LinearLayout 9 <LinearLayout
app/src/main/res/layout/item_order_list.xml
@@ -3,6 +3,7 @@ @@ -3,6 +3,7 @@
3 android:layout_width="match_parent" 3 android:layout_width="match_parent"
4 android:orientation="vertical" 4 android:orientation="vertical"
5 android:elevation="@dimen/size_dp_5" 5 android:elevation="@dimen/size_dp_5"
  6 + android:layout_margin="@dimen/size_dp_5"
6 android:background="@drawable/shape_xueqing_radius8" 7 android:background="@drawable/shape_xueqing_radius8"
7 android:id="@+id/layout_order_list" 8 android:id="@+id/layout_order_list"
8 android:layout_height="wrap_content"> 9 android:layout_height="wrap_content">
app/src/main/res/values/colors.xml
@@ -5,7 +5,7 @@ @@ -5,7 +5,7 @@
5 <color name="colorAccent">#FF4081</color> 5 <color name="colorAccent">#FF4081</color>
6 6
7 7
8 - <color name="hintTextColor">#C1C1C1</color> 8 + <color name="hintTextColor">#494947</color>
9 <color name="bottomline">#B8B8B9</color> 9 <color name="bottomline">#B8B8B9</color>
10 <color name="bg_main">#F0EFF5</color> 10 <color name="bg_main">#F0EFF5</color>
11 <color name="textRed">#FC5B6A</color> 11 <color name="textRed">#FC5B6A</color>