Commit 19c778c7 authored by linfeng's avatar linfeng

bug修复

parent f5372260
......@@ -205,7 +205,7 @@ public class MainActivity extends BaseActivity<CommonPresenter>{
} else if (id == R.id.rl_camp) {
setCurrent(TYPE_CAMP);
} else if (id == R.id.rl_found) {
// setCurrent(TYPE_FOUND);
setCurrent(TYPE_FOUND);
} else if (id == R.id.rl_mine) {
setCurrent(TYPE_MINE);
}
......@@ -216,7 +216,7 @@ public class MainActivity extends BaseActivity<CommonPresenter>{
list.add(HomeFragment.getInstance(TYPE_HOME_PAGE));
list.add(TourismFragment.getInstance(TYPE_TRAVEL));
list.add(CampFragment.getInstance(TYPE_CAMP));
// list.add(DiscoveryFragment.getInstance(TYPE_FOUND));
list.add(DiscoveryFragment.getInstance(TYPE_FOUND));
list.add(MineFragment.getInstance(TYPE_MINE));
return list;
}
......
......@@ -15,6 +15,7 @@ public interface RvFrameConfig extends RvFrameConstant {
// String HOST = "https://api.dfangche.com";
String HOST = "https://mgmt.dfangche.com";
String HOST_H5_DETAIL = "https://mgmt.dfangche.com";
// String HOST_H5_DETAIL = "https://dev.dfangche.com";
String ADMIN_POST = HOST + "/api/admin/";
String AUTH_POST = HOST + "/api/auth/";
String VEHICLE_POST = HOST + "/vehicle/";//租车
......
......@@ -121,5 +121,5 @@ public class ApiConfig {
public static String HTTP_URL_WEBVIEW_CARGOODS = RvFrameConfig.HOST_H5_DETAIL + "/h5/appHtml/view/carGoods.html";
//押金退还进度
public static String HTTP_URL_WEBVIEW_REFUNDPROGRESS = RvFrameConfig.HOST_H5_DETAIL + "/h5/appHtml/view/refundProgress.html";
public static String HTTP_URL_WEBVIEW_REFUNDPROGRESS = RvFrameConfig.HOST_H5_DETAIL + "/h5/appHtml/view/depositProgress.html";
}
......@@ -53,7 +53,7 @@ public class DepositefundProgressDetailsActivity extends BaseStatusActivity<Pick
titleView.setTitle("押金退还进度");
String orderId = intent.getStringExtra("orderId");
webUrl = ApiConfig.HTTP_URL_WEBVIEW_REFUNDPROGRESS + "?orderId=" + orderId;
webUrl = ApiConfig.HTTP_URL_WEBVIEW_REFUNDPROGRESS + "?orderNo=" + orderId;
initWeb();
}
......
......@@ -181,6 +181,10 @@ public class TourismFragment extends BaseFragment<TourismPresenter> implements S
mTourAroundAdapter.setOnLoadMoreListener(new BaseQuickAdapter.RequestLoadMoreListener() {
@Override
public void onLoadMoreRequested() {
if (rvTourAround != null) {
rvTourAround.postDelayed(new Runnable() {
@Override
public void run() {
if (mPage >= countPage) {
mTourAroundAdapter.loadMoreEnd();
} else {
......@@ -188,6 +192,9 @@ public class TourismFragment extends BaseFragment<TourismPresenter> implements S
getLoadTourAroundData(mPage);
}
}
}, 200);
}
}
}, rvTourAround);
}
......@@ -195,7 +202,6 @@ public class TourismFragment extends BaseFragment<TourismPresenter> implements S
protected void loadData(Bundle savedInstanceState) {
loadBannerData();
loadPopularBrigadeData();
loadTourAroundData();
loadPopularBrigadeAllData();
}
......@@ -335,14 +341,19 @@ public class TourismFragment extends BaseFragment<TourismPresenter> implements S
if (mPage == 1) {
if (bean.getData().getTotalCount() == 0) {
// mTourAroundAdapter.setEmptyView(getEmptyView(recyclerView, -1, mActivity.getString(R.string.rv_driving_data_null)));
mTourAroundAdapter.notifyDataSetChanged();
return;
}
countPage = bean.getData().getTotalPage();
mTourAroundAdapter.addNewData(bean);
if (bean.getData().getData() != null) {
mTourAroundAdapter.setNewData(bean.getData().getData());
}
mTourAroundAdapter.loadMoreComplete();
} else {
if (bean.getData().getData() != null) {
mTourAroundAdapter.addData(bean.getData().getData());
}
mTourAroundAdapter.loadMoreComplete();
}
}
......@@ -606,6 +617,7 @@ public class TourismFragment extends BaseFragment<TourismPresenter> implements S
latLatitude = location.getLatitude();
lonLongitude = location.getLongitude();
mLatLng = new LatLng(location.getLatitude(), location.getLongitude());
loadTourAroundData();
if (!TextUtils.isEmpty(location.getCity()))
travelCityText.setText(location.getCity());
locationManager.stopLocation();
......
......@@ -24,10 +24,4 @@ public class TourAroundAdapter extends BaseQuickAdapter<BeanTourAround.DataBeanX
helper.setText(R.id.tv_people,item.getStock());
helper.setText(R.id.tv_price,String.format("¥%1$s%2$s",item.getPrice(),item.getUnit()));
}
public void addNewData(BeanTourAround bean) {
mData.clear();
addData(bean.getData().getData());
notifyDataSetChanged();
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment