Commit 5055a860 by mReturn

fix 多sop服务单处理问题

parent f64b991a
......@@ -60,19 +60,19 @@ public class Constants {
/**
* uat测试环境配置.
*/
// public static String ENVIROMENT = "uat";
// public static int LOG_LEVEL = LogUtils.LEVEL_ALL;
// public static String BASE_URL = "http://47.95.223.6:3112";
// public static String WEB_SOP = "http://47.95.223.6:9004/#/sop";
// public static String WEB_SOP_DETAIL = "http://47.95.223.6:9004/#/sopdetail";
// public static String WEB_ZHI_SHI = "http://47.95.223.6:9004/#/detail";
// public static String CHECK_MULTI_WEB_SOP = "http://47.95.223.6:9004/#/manyServiceResult";
// public static String MULTI_WEB_SOP = "http://47.95.223.6:9004/#/manySop";
// public static final String UP_PHOTO = "/file/uploadMore?targetPath=test/sp/mobile/android/business/checkApply";
// public static final String UP_VIDEO = "/file/uploadVideoOne?targetPath=test/video";
// public static final boolean IS_DEBUG = false;
// public static String VIDEO_SHARE_URL = "http://uat.kf.ai:9099/#/shareVideo?type=_type&id="; //uat 学习视频分享链接 type(课程: course 直播: live)
// public static int XLR_PID = 14; //小绿人商家id
public static String ENVIROMENT = "uat";
public static int LOG_LEVEL = LogUtils.LEVEL_ALL;
public static String BASE_URL = "http://47.95.223.6:3112";
public static String WEB_SOP = "http://47.95.223.6:9004/#/sop";
public static String WEB_SOP_DETAIL = "http://47.95.223.6:9004/#/sopdetail";
public static String WEB_ZHI_SHI = "http://47.95.223.6:9004/#/detail";
public static String CHECK_MULTI_WEB_SOP = "http://47.95.223.6:9004/#/manyServiceResult";
public static String MULTI_WEB_SOP = "http://47.95.223.6:9004/#/manySop";
public static final String UP_PHOTO = "/file/uploadMore?targetPath=test/sp/mobile/android/business/checkApply";
public static final String UP_VIDEO = "/file/uploadVideoOne?targetPath=test/video";
public static final boolean IS_DEBUG = false;
public static String VIDEO_SHARE_URL = "http://uat.kf.ai:9099/#/shareVideo?type=_type&id="; //uat 学习视频分享链接 type(课程: course 直播: live)
public static int XLR_PID = 14; //小绿人商家id
......@@ -80,19 +80,19 @@ public class Constants {
/**
* 正式环境.
*/
public static String ENVIROMENT = "release";
public static int LOG_LEVEL = LogUtils.LEVEL_OFF;
public static String BASE_URL = "https://mobile.kf.ai";
public static String WEB_SOP = "https://sop.kf.ai/#/sop";
public static String WEB_SOP_DETAIL = "https://sop.kf.ai/#/sopdetail";
public static String WEB_ZHI_SHI = "https://sop.kf.ai/#/detail";
public static String CHECK_MULTI_WEB_SOP = "https://sop.kf.ai/#/manyServiceResult";
public static String MULTI_WEB_SOP = "https://sop.kf.ai/#/manySop";
public static final String UP_PHOTO = "/file/uploadMore?targetPath=online/sp/mobile/android/business/checkApply";
public static final String UP_VIDEO = "/file/uploadVideoOne?targetPath=online/video";
public static final boolean IS_DEBUG = false;
public static String VIDEO_SHARE_URL = "http://app.dl.kf.ai/ext/#/shareVideo?type=_type&id="; //学习视频分享链接 type(课程: course 直播: live)
public static int XLR_PID = 1936; //小绿人商家id
// public static String ENVIROMENT = "release";
// public static int LOG_LEVEL = LogUtils.LEVEL_OFF;
// public static String BASE_URL = "https://mobile.kf.ai";
// public static String WEB_SOP = "https://sop.kf.ai/#/sop";
// public static String WEB_SOP_DETAIL = "https://sop.kf.ai/#/sopdetail";
// public static String WEB_ZHI_SHI = "https://sop.kf.ai/#/detail";
// public static String CHECK_MULTI_WEB_SOP = "https://sop.kf.ai/#/manyServiceResult";
// public static String MULTI_WEB_SOP = "https://sop.kf.ai/#/manySop";
// public static final String UP_PHOTO = "/file/uploadMore?targetPath=online/sp/mobile/android/business/checkApply";
// public static final String UP_VIDEO = "/file/uploadVideoOne?targetPath=online/video";
// public static final boolean IS_DEBUG = false;
// public static String VIDEO_SHARE_URL = "http://app.dl.kf.ai/ext/#/shareVideo?type=_type&id="; //学习视频分享链接 type(课程: course 直播: live)
// public static int XLR_PID = 1936; //小绿人商家id
......
......@@ -19,6 +19,7 @@ public class OrderConstant {
public final static String TITLE = "title";
public final static String SPUS = "spus";
public final static String SPUS_SOURCE = "spus_source";
public final static String SPU = "spu";
public final static String CREATEDSOURCE = "created_source";
public final static String KAADDRESSID = "ka_address_id";
......
......@@ -52,6 +52,7 @@ public class MultiProcessOrderPresenter extends MultiProcessOrderContract.Presen
public ObservableField<Boolean> mIsShowSn = new ObservableField<>(false);
public ObservableField<Boolean> mIsShowPhone = new ObservableField<>(false);
private ArrayList<Spu> mSpus;
private ArrayList<Spu> mSourceSpus;
private int mId;
private int mState;
private String mPhone;
......@@ -63,6 +64,7 @@ public class MultiProcessOrderPresenter extends MultiProcessOrderContract.Presen
Bundle bundle = mView.getBundle();
mSpu = (Spu) bundle.getSerializable(OrderConstant.SPU);
mSpus = bundle.getParcelableArrayList(OrderConstant.SPUS);
mSourceSpus = bundle.getParcelableArrayList(OrderConstant.SPUS_SOURCE);
mState = bundle.getInt(Constants.STATE);
mKaId = mView.getBundle().getInt(OrderConstant.KAADDRESSID, -1);
sopOrderVersion = bundle.getInt(Constants.SOP_ORDER_VERSION);
......@@ -171,8 +173,13 @@ public class MultiProcessOrderPresenter extends MultiProcessOrderContract.Presen
ArrayList<Spu> list = new ArrayList<>();
list.add(mDetail.get());
Bundle bundle = new Bundle();
if (mSourceSpus != null && mSourceSpus.size() >list.size()){
bundle.putParcelableArrayList(OrderConstant.SPUS, mSourceSpus);
bundle.putInt(OrderConstant.ORDER_TYPE, 0);
}else {
bundle.putParcelableArrayList(OrderConstant.SPUS, list);
bundle.putInt(OrderConstant.ORDER_TYPE, 1);
}
mView.startActivity(MultipleProcessActivity.class, bundle);
} else {
mView.dumpBack();
......@@ -185,8 +192,10 @@ public class MultiProcessOrderPresenter extends MultiProcessOrderContract.Presen
Bundle bundle = new Bundle();
bundle.putSerializable(OrderConstant.SPU, spu);
bundle.putParcelableArrayList(OrderConstant.SPUS, mSpus);
bundle.putSerializable(OrderConstant.SPUS_SOURCE, mSourceSpus);
bundle.putInt(Constants.ORDER_POSTION, 0);
bundle.putInt(Constants.STATE, mState);
bundle.putInt(Constants.SOP_ORDER_VERSION, sopOrderVersion);
mView.startActivityAndFinish(MultiProcessOrderActivity.class, bundle);
}
......@@ -221,6 +230,7 @@ public class MultiProcessOrderPresenter extends MultiProcessOrderContract.Presen
bundle.putInt(Constants.ORDER_ID, mSpu.getId());
bundle.putSerializable(OrderConstant.SPU, mSpu);
bundle.putParcelableArrayList(OrderConstant.SPUS, mSpus);
bundle.putSerializable(OrderConstant.SPUS_SOURCE, mSourceSpus);
bundle.putInt(Constants.STATE, mState);
bundle.putInt(Constants.SOP_ORDER_VERSION, sopOrderVersion);
mView.startActivityAndFinish(SopWebViewActivity.class, bundle);
......
......@@ -62,6 +62,7 @@ public class ServerListActivity extends BaseActivity<ServerListPresenter, Activi
bundle.putInt(Constants.STATE, state);
bundle.putSerializable(OrderConstant.SPU, item);
bundle.putParcelableArrayList(OrderConstant.SPUS, mUnFinishSpus);
bundle.putParcelableArrayList(OrderConstant.SPUS_SOURCE, spus);
bundle.putInt(Constants.ORDER_POSTION, 0);
intent.putExtra(Constants.BUNDLE, bundle);
bundle.putInt(Constants.SOP_ORDER_VERSION, mPresenter.sopOrderVersion);
......
......@@ -345,15 +345,18 @@ public class SopLocalActivity extends BaseActivity<SImplePresenter, ActivitySopL
int mSpuState = mBundle.getInt(Constants.STATE, 0);
Spu mSpu = (Spu) mBundle.getSerializable(OrderConstant.SPU);
ArrayList<Spu> mSpus = mBundle.getParcelableArrayList(OrderConstant.SPUS);
int version = mBundle.getInt(Constants.SOP_ORDER_VERSION, 2);
if (mSpu != null) {
Intent intent = new Intent(mActivity, MultiProcessOrderActivity.class);
Bundle bundle = new Bundle();
bundle.putSerializable(OrderConstant.SPU, mSpu);
bundle.putParcelableArrayList(OrderConstant.SPUS, mSpus);
bundle.putParcelableArrayList(OrderConstant.SPUS_SOURCE, mBundle.getParcelableArrayList(OrderConstant.SPUS_SOURCE));
bundle.putInt(Constants.ORDER_POSTION, 0);
bundle.putInt(Constants.ORDER_ID, mOrderId);
bundle.putInt(Constants.STATE, mSpuState);
intent.putExtra(Constants.BUNDLE, bundle);
bundle.putInt(Constants.SOP_ORDER_VERSION, version);
startActivity(intent);
} else {
EventBus.getDefault().post(new OrderState(ORDER_SOP_FINISH, mPositon));
......
......@@ -61,6 +61,7 @@ public class SopWebViewActivity extends BaseActivity<SopPresenter, ActivitySopWe
private int mState;
private Spu mSpu;
private ArrayList<Spu> mSpus;
private ArrayList<Spu> mSourceSpus;
private int mCreatedSource;
private int mSpuState;
private int version;
......@@ -104,6 +105,7 @@ public class SopWebViewActivity extends BaseActivity<SopPresenter, ActivitySopWe
mCreatedSource = bundle.getInt(OrderConstant.CREATEDSOURCE, 0);
mSpu = (Spu) bundle.getSerializable(OrderConstant.SPU);
mSpus = bundle.getParcelableArrayList(OrderConstant.SPUS);
mSourceSpus = bundle.getParcelableArrayList(OrderConstant.SPUS_SOURCE);
mBind.titleBack.setOnClickListener(o -> finish());
mWebView = new BridgeWebView(mActivity);
mWebView.setLayoutParams(new LinearLayout.LayoutParams(
......@@ -209,6 +211,7 @@ public class SopWebViewActivity extends BaseActivity<SopPresenter, ActivitySopWe
Bundle bundle = new Bundle();
bundle.putSerializable(OrderConstant.SPU, mSpu);
bundle.putParcelableArrayList(OrderConstant.SPUS, mSpus);
bundle.putParcelableArrayList(OrderConstant.SPUS_SOURCE, mSourceSpus);
bundle.putInt(Constants.ORDER_POSTION, 0);
bundle.putInt(Constants.ORDER_ID, mOrderId);
bundle.putInt(Constants.STATE, mSpuState);
......
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 sign in to comment