|
|
@@ -48,7 +48,7 @@ public class LocationTransferFragment extends BaseFragment implements OnColumnIt
|
|
|
private TextView mOldLocationBtn, mNewLocationBtn,location_transfer_model_ok,location_transfer_quantity_ok;
|
|
|
private SmartTable mSmartTable;
|
|
|
private TableData<LocationCheckBean> mTableData;
|
|
|
- private Column<String>mBRANDColumn, mProdCodeColumn, mBarcodeColumn, mQuantityColumn;
|
|
|
+ private Column<String>mBRANDColumn, mProdCodeColumn,mLocationColumn, mBarcodeColumn, mQuantityColumn;
|
|
|
private List<LocationCheckBean> mLocationCheckBeans;
|
|
|
private RefreshLayout mRefreshLayout;
|
|
|
private int mPageIndex = 1, mPageSize = 20;
|
|
|
@@ -80,8 +80,9 @@ public class LocationTransferFragment extends BaseFragment implements OnColumnIt
|
|
|
mRefreshLayout.setEnableRefresh(false);
|
|
|
mSmartTable = root.findViewById(R.id.location_transfer_info_st);
|
|
|
CommonUtil.getDefaultTable(mActivity, mSmartTable);
|
|
|
- mBRANDColumn = new Column<>("仓位", "BRAND");
|
|
|
+ mBRANDColumn = new Column<>("仓位", "LOCATION");
|
|
|
mProdCodeColumn = new Column<>("型号", "PRODCODE");
|
|
|
+ mLocationColumn = new Column<>("品牌", "BRAND");
|
|
|
mBarcodeColumn = new Column<>("物料编号", "BARCODE");
|
|
|
mQuantityColumn = new Column<>("数量", "QUANTITY");
|
|
|
mLocationCheckBeans = new ArrayList<>();
|
|
|
@@ -152,13 +153,13 @@ public class LocationTransferFragment extends BaseFragment implements OnColumnIt
|
|
|
protected void initDatas() {
|
|
|
mBRANDColumn.setOnColumnItemClickListener(this);
|
|
|
mProdCodeColumn.setOnColumnItemClickListener(this);
|
|
|
+ mLocationColumn.setOnColumnItemClickListener(this);
|
|
|
mBarcodeColumn.setOnColumnItemClickListener(this);
|
|
|
mQuantityColumn.setOnColumnItemClickListener(this);
|
|
|
}
|
|
|
|
|
|
private void transferToNewLocation() {
|
|
|
String location_transfer_modeltrim = location_transfer_model.getText().toString().trim();
|
|
|
- String location_transfer_quantitytrim = location_transfer_quantity.getText().toString().trim();
|
|
|
String trim = mNewLocationEditText.getText().toString().trim();//
|
|
|
mLocation = mOldLocationEditText.getText().toString().trim();
|
|
|
if (TextUtils.isEmpty(mLocation)) {
|
|
|
@@ -169,10 +170,6 @@ public class LocationTransferFragment extends BaseFragment implements OnColumnIt
|
|
|
CommonUtil.toastNoRepeat(mActivity, "物料编码不可为空");
|
|
|
return;
|
|
|
}
|
|
|
- if (TextUtils.isEmpty(location_transfer_quantitytrim)) {
|
|
|
- CommonUtil.toastNoRepeat(mActivity, "数量不可为空");
|
|
|
- return;
|
|
|
- }
|
|
|
String newLocation = mNewLocationEditText.getText().toString().trim();
|
|
|
if (TextUtils.isEmpty(mLocation)) {
|
|
|
CommonUtil.toastNoRepeat(mActivity, "请采集新库位");
|
|
|
@@ -189,7 +186,6 @@ public class LocationTransferFragment extends BaseFragment implements OnColumnIt
|
|
|
.addParam("fromLo", mLocation)
|
|
|
.addParam("toLo", newLocation)
|
|
|
.addParam("prcode",location_transfer_modeltrim)//物料编号
|
|
|
- .addParam("qty",location_transfer_quantitytrim)//数量
|
|
|
.build(), new HttpCallback() {
|
|
|
@Override
|
|
|
public void onSuccess(int flag, Object o) throws Exception {
|
|
|
@@ -258,7 +254,7 @@ public class LocationTransferFragment extends BaseFragment implements OnColumnIt
|
|
|
locationCheckBean.setBarcode(FastjsonUtil.getText(dataObject, "BARCODE"));
|
|
|
locationCheckBean.setQuantity(FastjsonUtil.getText(dataObject, "QTY"));
|
|
|
locationCheckBean.setBrand(FastjsonUtil.getText(dataObject, "BRAND"));
|
|
|
-
|
|
|
+ locationCheckBean.setLOCATION(FastjsonUtil.getText(dataObject, "LOCATION"));
|
|
|
locationCheckBeans.add(locationCheckBean);
|
|
|
}
|
|
|
}
|
|
|
@@ -310,7 +306,7 @@ public class LocationTransferFragment extends BaseFragment implements OnColumnIt
|
|
|
|
|
|
private void setTableData(List<LocationCheckBean> locationCheckBeans) {
|
|
|
mTableData = new TableData<LocationCheckBean>("库位提示", locationCheckBeans,
|
|
|
- mBRANDColumn,mProdCodeColumn, mBarcodeColumn, mQuantityColumn);
|
|
|
+ mBRANDColumn,mProdCodeColumn,mLocationColumn,mBarcodeColumn, mQuantityColumn);
|
|
|
mSmartTable.setTableData(mTableData);
|
|
|
mSmartTable.postDelayed(new Runnable() {
|
|
|
@Override
|