提交 4ae9620e authored 作者: lgd's avatar lgd

1.供应订单详情

2.//TODO erp用户激活测试,忘记/重置密码测试,质检接口数据问题,审核规则,领用申请列表/退件列表/参数,坩埚下单页面,组装下单,产品下单还差附件测试,mes,刷新token
上级 b1c6b0a7
...@@ -1024,6 +1024,14 @@ ...@@ -1024,6 +1024,14 @@
android:screenOrientation="portrait" android:screenOrientation="portrait"
android:theme="@style/Work.Base" android:theme="@style/Work.Base"
android:windowSoftInputMode="adjustPan" /> android:windowSoftInputMode="adjustPan" />
<activity
android:name=".ui.activity.bat.order.QualityApplyDetailActivity"
android:configChanges="keyboardHidden|orientation"
android:label="质检申请详情"
android:launchMode="singleTop"
android:screenOrientation="portrait"
android:theme="@style/Work.Base"
android:windowSoftInputMode="adjustPan" />
<provider <provider
android:name="androidx.core.content.FileProvider" android:name="androidx.core.content.FileProvider"
......
...@@ -10,13 +10,13 @@ import java.util.List; ...@@ -10,13 +10,13 @@ import java.util.List;
public class AddStockBean { public class AddStockBean {
/** /**
* records : [{"createdBy":675,"createdByName":"李凯","createdTime":"2020-04-12 20:34:30","updatedBy":null,"updatedByName":null,"updatedTime":null,"commenceFromId":null,"createdType":null,"id":223,"orderId":"SO10626","orderType":"SO","status":"0","applyRemark":"1","auditRemark":null,"serialNumber":"INI20041220342916","deptIdList":null,"ownId":null,"orderItemId":"4ae3333eebc5423e8a72e388e12fc42f","productId":29,"productName":"保护渣","productSoleCode":"70BHZBHZ1-1001","productSimpleCode":"BHZ1-1","productAmount":1,"qualityInspectionStatus":"0","qiApplyRemark":null,"qiAuditRemark":null,"boxCode":"1","qiAuditBy":null,"qiAuditTime":null,"qiAuditByName":null},{"createdBy":705,"createdByName":"Likai","createdTime":"2020-04-08 14:08:26","updatedBy":705,"updatedByName":"Likai","updatedTime":"2020-04-08 14:08:40","commenceFromId":null,"createdType":null,"id":222,"orderId":"SO10761","orderType":"SO","status":"1","applyRemark":"2","auditRemark":"s","serialNumber":"INI20040814082671","deptIdList":null,"ownId":null,"orderItemId":"9a1f38f80a564945987419817240a39b","productId":30,"productName":"整体塞棒","productSoleCode":"70GTB214001","productSimpleCode":"B214","productAmount":2,"qualityInspectionStatus":"0","qiApplyRemark":null,"qiAuditRemark":null,"boxCode":"2","qiAuditBy":null,"qiAuditTime":null,"qiAuditByName":null},{"createdBy":675,"createdByName":"李凯","createdTime":"2020-04-01 13:42:08","updatedBy":675,"updatedByName":"李凯","updatedTime":"2020-04-01 13:42:17","commenceFromId":null,"createdType":null,"id":221,"orderId":"SO10628","orderType":"SO","status":"1","applyRemark":"","auditRemark":"","serialNumber":"INI20040113420736","deptIdList":null,"ownId":null,"orderItemId":"9720e8cebb824bf1bbd4ee87d10f902c","productId":29,"productName":"保护渣","productSoleCode":"70BHZBHZ1-1001","productSimpleCode":"BHZ1-1","productAmount":1.2,"qualityInspectionStatus":"0","qiApplyRemark":null,"qiAuditRemark":null,"boxCode":"1","qiAuditBy":null,"qiAuditTime":null,"qiAuditByName":null},{"createdBy":675,"createdByName":"李凯","createdTime":"2020-04-01 11:16:40","updatedBy":675,"updatedByName":"李凯","updatedTime":"2020-04-01 11:16:46","commenceFromId":null,"createdType":null,"id":216,"orderId":"SO10744","orderType":"SO","status":"1","applyRemark":"","auditRemark":"","serialNumber":"INI20040111164043","deptIdList":null,"ownId":null,"orderItemId":"50207b598298430aa0b77cc5a6865844","productId":31,"productName":"塞棒","productSoleCode":"70TNB393001","productSimpleCode":"B393","productAmount":2,"qualityInspectionStatus":"0","qiApplyRemark":null,"qiAuditRemark":null,"boxCode":"2","qiAuditBy":null,"qiAuditTime":null,"qiAuditByName":null},{"createdBy":705,"createdByName":"Likai","createdTime":"2020-03-31 17:41:33","updatedBy":705,"updatedByName":"Likai","updatedTime":"2020-04-01 11:08:06","commenceFromId":null,"createdType":null,"id":213,"orderId":"SO10755","orderType":"SO","status":"1","applyRemark":"222","auditRemark":"","serialNumber":"INI20033117413361","deptIdList":null,"ownId":null,"orderItemId":"87395083e98b4828be9c52ceafeddfdb","productId":16404,"productName":"垫片","productSoleCode":"wer","productSimpleCode":"wer","productAmount":2,"qualityInspectionStatus":"0","qiApplyRemark":null,"qiAuditRemark":null,"boxCode":"2222","qiAuditBy":null,"qiAuditTime":null,"qiAuditByName":null},{"createdBy":803,"createdByName":"测试员","createdTime":"2020-03-31 09:52:19","updatedBy":803,"updatedByName":"测试员","updatedTime":"2020-03-31 09:52:47","commenceFromId":null,"createdType":null,"id":212,"orderId":"SO10750","orderType":"SO","status":"1","applyRemark":"1","auditRemark":"","serialNumber":"INI20033109521939","deptIdList":null,"ownId":null,"orderItemId":"0e071cf4258047c1b34e3d26891e2cfe","productId":16402,"productName":"测试单元","productSoleCode":"pinhao","productSimpleCode":"tuhao","productAmount":2,"qualityInspectionStatus":"0","qiApplyRemark":null,"qiAuditRemark":null,"boxCode":"1","qiAuditBy":null,"qiAuditTime":null,"qiAuditByName":null},{"createdBy":803,"createdByName":"测试员","createdTime":"2020-03-30 15:23:00","updatedBy":803,"updatedByName":"测试员","updatedTime":"2020-03-30 15:24:07","commenceFromId":null,"createdType":null,"id":210,"orderId":"SO10749","orderType":"SO","status":"1","applyRemark":"","auditRemark":"通过","serialNumber":"INI20033015225994","deptIdList":null,"ownId":null,"orderItemId":"88d163cc2a5b4547bdbafc797503a01f","productId":16402,"productName":"测试单元","productSoleCode":"pinhao","productSimpleCode":"tuhao","productAmount":1,"qualityInspectionStatus":"0","qiApplyRemark":null,"qiAuditRemark":null,"boxCode":"72","qiAuditBy":null,"qiAuditTime":null,"qiAuditByName":null},{"createdBy":680,"createdByName":"吴同得","createdTime":"2020-03-28 11:28:31","updatedBy":680,"updatedByName":"吴同得","updatedTime":"2020-03-28 11:29:59","commenceFromId":null,"createdType":null,"id":199,"orderId":"SO10744","orderType":"SO","status":"2","applyRemark":"1","auditRemark":"s","serialNumber":"INI20032811283095","deptIdList":null,"ownId":null,"orderItemId":"50207b598298430aa0b77cc5a6865844","productId":31,"productName":"塞棒","productSoleCode":"70TNB393001","productSimpleCode":"B393","productAmount":1,"qualityInspectionStatus":"0","qiApplyRemark":null,"qiAuditRemark":null,"boxCode":"1","qiAuditBy":null,"qiAuditTime":null,"qiAuditByName":null},{"createdBy":675,"createdByName":"李凯","createdTime":"2020-03-28 11:25:45","updatedBy":680,"updatedByName":"吴同得","updatedTime":"2020-03-28 11:26:45","commenceFromId":null,"createdType":null,"id":198,"orderId":"SO10744","orderType":"SO","status":"2","applyRemark":"1","auditRemark":"3","serialNumber":"INI20032811254474","deptIdList":null,"ownId":null,"orderItemId":"50207b598298430aa0b77cc5a6865844","productId":31,"productName":"塞棒","productSoleCode":"70TNB393001","productSimpleCode":"B393","productAmount":1,"qualityInspectionStatus":"0","qiApplyRemark":null,"qiAuditRemark":null,"boxCode":"1","qiAuditBy":null,"qiAuditTime":null,"qiAuditByName":null},{"createdBy":675,"createdByName":"李凯","createdTime":"2020-03-28 11:22:12","updatedBy":680,"updatedByName":"吴同得","updatedTime":"2020-03-28 11:24:54","commenceFromId":null,"createdType":null,"id":197,"orderId":"SO10744","orderType":"SO","status":"2","applyRemark":"","auditRemark":"e","serialNumber":"INI20032811221237","deptIdList":null,"ownId":null,"orderItemId":"50207b598298430aa0b77cc5a6865844","productId":31,"productName":"塞棒","productSoleCode":"70TNB393001","productSimpleCode":"B393","productAmount":1,"qualityInspectionStatus":"0","qiApplyRemark":null,"qiAuditRemark":null,"boxCode":"3","qiAuditBy":null,"qiAuditTime":null,"qiAuditByName":null}] * records : [{"createdBy":675,"createdByName":"李凯","createdTime":"2020-04-14 20:41:57","updatedBy":675,"updatedByName":"李凯","updatedTime":"2020-04-14 20:56:09","commenceFromId":null,"createdType":null,"id":226,"orderId":"FO10024","orderType":"FO","status":"2","applyRemark":"11","auditRemark":"122","serialNumber":"INI20041420415733","deptIdList":null,"ownId":null,"orderItemId":"086b3113f20043f7a9bb1c05d13f69e9","productId":33,"productName":"白刚玉","productSoleCode":"白刚玉","productSimpleCode":"白刚玉","productAmount":1,"qualityInspectionStatus":"0","qiApplyRemark":"11","qiAuditRemark":null,"boxCode":"1","qiAuditBy":null,"qiAuditTime":null,"qiAuditByName":null}]
* total : 35 * total : 1
* size : 10 * size : 10
* current : 1 * current : 1
* orders : [] * orders : []
* searchCount : true * searchCount : true
* pages : 4 * pages : 1
*/ */
private int total; private int total;
...@@ -87,29 +87,29 @@ public class AddStockBean { ...@@ -87,29 +87,29 @@ public class AddStockBean {
/** /**
* createdBy : 675 * createdBy : 675
* createdByName : 李凯 * createdByName : 李凯
* createdTime : 2020-04-12 20:34:30 * createdTime : 2020-04-14 20:41:57
* updatedBy : null * updatedBy : 675
* updatedByName : null * updatedByName : 李凯
* updatedTime : null * updatedTime : 2020-04-14 20:56:09
* commenceFromId : null * commenceFromId : null
* createdType : null * createdType : null
* id : 223 * id : 226
* orderId : SO10626 * orderId : FO10024
* orderType : SO * orderType : FO
* status : 0 * status : 2
* applyRemark : 1 * applyRemark : 11
* auditRemark : null * auditRemark : 122
* serialNumber : INI20041220342916 * serialNumber : INI20041420415733
* deptIdList : null * deptIdList : null
* ownId : null * ownId : null
* orderItemId : 4ae3333eebc5423e8a72e388e12fc42f * orderItemId : 086b3113f20043f7a9bb1c05d13f69e9
* productId : 29 * productId : 33
* productName : 保护渣 * productName : 白刚玉
* productSoleCode : 70BHZBHZ1-1001 * productSoleCode : 白刚玉
* productSimpleCode : BHZ1-1 * productSimpleCode : 白刚玉
* productAmount : 1.0 * productAmount : 1.0
* qualityInspectionStatus : 0 * qualityInspectionStatus : 0
* qiApplyRemark : null * qiApplyRemark : 11
* qiAuditRemark : null * qiAuditRemark : null
* boxCode : 1 * boxCode : 1
* qiAuditBy : null * qiAuditBy : null
...@@ -120,9 +120,9 @@ public class AddStockBean { ...@@ -120,9 +120,9 @@ public class AddStockBean {
private int createdBy; private int createdBy;
private String createdByName; private String createdByName;
private String createdTime; private String createdTime;
private Object updatedBy; private int updatedBy;
private Object updatedByName; private String updatedByName;
private Object updatedTime; private String updatedTime;
private Object commenceFromId; private Object commenceFromId;
private Object createdType; private Object createdType;
private int id; private int id;
...@@ -130,7 +130,7 @@ public class AddStockBean { ...@@ -130,7 +130,7 @@ public class AddStockBean {
private String orderType; private String orderType;
private String status; private String status;
private String applyRemark; private String applyRemark;
private Object auditRemark; private String auditRemark;
private String serialNumber; private String serialNumber;
private Object deptIdList; private Object deptIdList;
private Object ownId; private Object ownId;
...@@ -141,7 +141,7 @@ public class AddStockBean { ...@@ -141,7 +141,7 @@ public class AddStockBean {
private String productSimpleCode; private String productSimpleCode;
private double productAmount; private double productAmount;
private String qualityInspectionStatus; private String qualityInspectionStatus;
private Object qiApplyRemark; private String qiApplyRemark;
private Object qiAuditRemark; private Object qiAuditRemark;
private String boxCode; private String boxCode;
private Object qiAuditBy; private Object qiAuditBy;
...@@ -172,27 +172,27 @@ public class AddStockBean { ...@@ -172,27 +172,27 @@ public class AddStockBean {
this.createdTime = createdTime; this.createdTime = createdTime;
} }
public Object getUpdatedBy() { public int getUpdatedBy() {
return updatedBy; return updatedBy;
} }
public void setUpdatedBy(Object updatedBy) { public void setUpdatedBy(int updatedBy) {
this.updatedBy = updatedBy; this.updatedBy = updatedBy;
} }
public Object getUpdatedByName() { public String getUpdatedByName() {
return updatedByName; return updatedByName;
} }
public void setUpdatedByName(Object updatedByName) { public void setUpdatedByName(String updatedByName) {
this.updatedByName = updatedByName; this.updatedByName = updatedByName;
} }
public Object getUpdatedTime() { public String getUpdatedTime() {
return updatedTime; return updatedTime;
} }
public void setUpdatedTime(Object updatedTime) { public void setUpdatedTime(String updatedTime) {
this.updatedTime = updatedTime; this.updatedTime = updatedTime;
} }
...@@ -252,11 +252,11 @@ public class AddStockBean { ...@@ -252,11 +252,11 @@ public class AddStockBean {
this.applyRemark = applyRemark; this.applyRemark = applyRemark;
} }
public Object getAuditRemark() { public String getAuditRemark() {
return auditRemark; return auditRemark;
} }
public void setAuditRemark(Object auditRemark) { public void setAuditRemark(String auditRemark) {
this.auditRemark = auditRemark; this.auditRemark = auditRemark;
} }
...@@ -340,11 +340,11 @@ public class AddStockBean { ...@@ -340,11 +340,11 @@ public class AddStockBean {
this.qualityInspectionStatus = qualityInspectionStatus; this.qualityInspectionStatus = qualityInspectionStatus;
} }
public Object getQiApplyRemark() { public String getQiApplyRemark() {
return qiApplyRemark; return qiApplyRemark;
} }
public void setQiApplyRemark(Object qiApplyRemark) { public void setQiApplyRemark(String qiApplyRemark) {
this.qiApplyRemark = qiApplyRemark; this.qiApplyRemark = qiApplyRemark;
} }
......
...@@ -1346,7 +1346,7 @@ public interface ApiService { ...@@ -1346,7 +1346,7 @@ public interface ApiService {
* *
* @return * @return
*/ */
@POST("/enterStoreApply/fo/app/page/list") @GET("/enterStoreApply/fo/app/page/list")
Observable<BaseBean> addFoStockApplyList(@QueryMap Map<String, Object> param); Observable<BaseBean> addFoStockApplyList(@QueryMap Map<String, Object> param);
/** /**
...@@ -1354,7 +1354,7 @@ public interface ApiService { ...@@ -1354,7 +1354,7 @@ public interface ApiService {
* *
* @return * @return
*/ */
@POST("/enterStoreApply/co/app/page/list") @GET("/enterStoreApply/co/app/page/list")
Observable<BaseBean> addCoStockApplyList(@QueryMap Map<String, Object> param); Observable<BaseBean> addCoStockApplyList(@QueryMap Map<String, Object> param);
/** /**
...@@ -1403,6 +1403,14 @@ public interface ApiService { ...@@ -1403,6 +1403,14 @@ public interface ApiService {
Observable<BaseBean> enterStoreApplyList(@QueryMap Map<String, Object> param); Observable<BaseBean> enterStoreApplyList(@QueryMap Map<String, Object> param);
/**
* 质检审核
*
* @return
*/
@PUT("/enterStoreApply/fo/quality-inspection/audit/{id}")
Observable<BaseBean> enterFoStoreApplyList(@Path("id") String id, @Body RequestBody requestBody);
/** /**
* 获取一个订单子表的全部流水 * 获取一个订单子表的全部流水
* *
...@@ -1419,6 +1427,36 @@ public interface ApiService { ...@@ -1419,6 +1427,36 @@ public interface ApiService {
@PUT("/saleOrder/audit/{orderId}") @PUT("/saleOrder/audit/{orderId}")
Observable<BaseBean> saleOrderCheck(@Path("orderId") String orderId,@Body RequestBody requestBody); Observable<BaseBean> saleOrderCheck(@Path("orderId") String orderId,@Body RequestBody requestBody);
/**
* step2-审核
*
* @return
*/
@PUT("/supplierOrder/audit/{orderId}")
Observable<BaseBean> supplierOrderCheck(@Path("orderId") String orderId,@Body RequestBody requestBody);
/**
* step2-审核
*
* @return
*/
@PUT("/insideOrder/audit/{orderId}")
Observable<BaseBean> insideOrderCheck(@Path("orderId") String orderId,@Body RequestBody requestBody);
/**
* step2-审核
*
* @return
*/
@PUT("/purchaseOrder/audit/{orderId}")
Observable<BaseBean> purchaseOrderCheck(@Path("orderId") String orderId,@Body RequestBody requestBody);
/**
* step2-审核
*
* @return
*/
@PUT("/crucible/audit/{orderId}")
Observable<BaseBean> crucibleOrderCheck(@Path("orderId") String orderId,@Body RequestBody requestBody);
/** /**
* *获取当前用户某类消息 * *获取当前用户某类消息
* *
......
...@@ -14,6 +14,7 @@ import com.alibaba.fastjson.JSON; ...@@ -14,6 +14,7 @@ import com.alibaba.fastjson.JSON;
import com.wd.workoffice.R; import com.wd.workoffice.R;
import com.wd.workoffice.app.BaseBean; import com.wd.workoffice.app.BaseBean;
import com.wd.workoffice.app.WorkToolBarActivity; import com.wd.workoffice.app.WorkToolBarActivity;
import com.wd.workoffice.bean.AddStockBean;
import com.wd.workoffice.bean.UseApplyBean; import com.wd.workoffice.bean.UseApplyBean;
import com.wd.workoffice.bean.event.CheckAddStockEvent; import com.wd.workoffice.bean.event.CheckAddStockEvent;
import com.wd.workoffice.bean.event.CheckUseEvent; import com.wd.workoffice.bean.event.CheckUseEvent;
...@@ -67,7 +68,7 @@ public class AddStockApplyDetailActivity extends WorkToolBarActivity { ...@@ -67,7 +68,7 @@ public class AddStockApplyDetailActivity extends WorkToolBarActivity {
LinearLayout llCheck; LinearLayout llCheck;
@BindView(R.id.tv_box_num) @BindView(R.id.tv_box_num)
TextView tvBoxNum; TextView tvBoxNum;
private UseApplyBean.RecordsBean info; private AddStockBean.RecordsBean info;
private String orderType; private String orderType;
@Override @Override
...@@ -77,7 +78,7 @@ public class AddStockApplyDetailActivity extends WorkToolBarActivity { ...@@ -77,7 +78,7 @@ public class AddStockApplyDetailActivity extends WorkToolBarActivity {
@Override @Override
protected void initData() { protected void initData() {
info = JSON.parseObject(getIntent().getStringExtra("info"), UseApplyBean.RecordsBean.class); info = JSON.parseObject(getIntent().getStringExtra("info"), AddStockBean.RecordsBean.class);
orderType = getIntent().getStringExtra("orderType"); orderType = getIntent().getStringExtra("orderType");
tvNum.setText(String.valueOf(info.getProductAmount())); tvNum.setText(String.valueOf(info.getProductAmount()));
tvBoxNum.setText(String.valueOf(info.getBoxCode())); tvBoxNum.setText(String.valueOf(info.getBoxCode()));
...@@ -205,6 +206,7 @@ public class AddStockApplyDetailActivity extends WorkToolBarActivity { ...@@ -205,6 +206,7 @@ public class AddStockApplyDetailActivity extends WorkToolBarActivity {
} }
toast("操作成功"); toast("操作成功");
EventBus.getDefault().post(new CheckAddStockEvent()); EventBus.getDefault().post(new CheckAddStockEvent());
finish();
} }
}); });
} }
......
...@@ -265,7 +265,7 @@ public class CrucibleOrderDetailActivity extends WorkToolBarActivity { ...@@ -265,7 +265,7 @@ public class CrucibleOrderDetailActivity extends WorkToolBarActivity {
case R.id.tv_return: case R.id.tv_return:
startActivity(ReturnApplyActivity.class, startActivity(ReturnApplyActivity.class,
"status", dataBean.getStatus() + "", "status", dataBean.getStatus() + "",
"orderType", dataBean.getOrderType() + "", "orderType", dataBean.getExpandInfo().getOrderType(),
"num", proList.get(position).getStoreSum() + "", "num", proList.get(position).getStoreSum() + "",
"product", proList.get(position).getProductName(), "product", proList.get(position).getProductName(),
"simpleCode", proList.get(position).getProductSimpleCode(), "simpleCode", proList.get(position).getProductSimpleCode(),
...@@ -286,6 +286,7 @@ public class CrucibleOrderDetailActivity extends WorkToolBarActivity { ...@@ -286,6 +286,7 @@ public class CrucibleOrderDetailActivity extends WorkToolBarActivity {
case R.id.tv_quality: case R.id.tv_quality:
startActivity(QualityApplyActivity.class, startActivity(QualityApplyActivity.class,
"status", dataBean.getStatus() + "", "status", dataBean.getStatus() + "",
"orderType", dataBean.getExpandInfo().getOrderType(),
"num", proList.get(position).getStoreSum() + "", "num", proList.get(position).getStoreSum() + "",
"product", proList.get(position).getProductName(), "product", proList.get(position).getProductName(),
"simpleCode", proList.get(position).getProductSimpleCode(), "simpleCode", proList.get(position).getProductSimpleCode(),
...@@ -382,7 +383,7 @@ public class CrucibleOrderDetailActivity extends WorkToolBarActivity { ...@@ -382,7 +383,7 @@ public class CrucibleOrderDetailActivity extends WorkToolBarActivity {
Map<String, Object> dataParam = WorkUtils.simpleParam(); Map<String, Object> dataParam = WorkUtils.simpleParam();
dataParam.put("result", status); dataParam.put("result", status);
dataParam.put("comment", remark); dataParam.put("comment", remark);
RtfUtils.getRtf().saleOrderCheck(dataBean.getId(), WorkUtils.convertMapToBody(dataParam)).compose(Transformer.schedule()).subscribe(new WorkObserver<BaseBean>() { RtfUtils.getRtf().crucibleOrderCheck(dataBean.getId(), WorkUtils.convertMapToBody(dataParam)).compose(Transformer.schedule()).subscribe(new WorkObserver<BaseBean>() {
@Override @Override
public void doOnSubscribe(Disposable d) { public void doOnSubscribe(Disposable d) {
} }
......
...@@ -270,6 +270,7 @@ public class InsideOrderDetailActivity extends WorkToolBarActivity { ...@@ -270,6 +270,7 @@ public class InsideOrderDetailActivity extends WorkToolBarActivity {
case R.id.tv_quality: case R.id.tv_quality:
startActivity(QualityApplyActivity.class, startActivity(QualityApplyActivity.class,
"status", dataBean.getStatus() + "", "status", dataBean.getStatus() + "",
"orderType", dataBean.getExpandInfo().getOrderType(),
"num", proList.get(position).getStoreSum() + "", "num", proList.get(position).getStoreSum() + "",
"product", proList.get(position).getProductName(), "product", proList.get(position).getProductName(),
"simpleCode", proList.get(position).getProductSimpleCode(), "simpleCode", proList.get(position).getProductSimpleCode(),
...@@ -372,7 +373,7 @@ public class InsideOrderDetailActivity extends WorkToolBarActivity { ...@@ -372,7 +373,7 @@ public class InsideOrderDetailActivity extends WorkToolBarActivity {
Map<String, Object> dataParam = WorkUtils.simpleParam(); Map<String, Object> dataParam = WorkUtils.simpleParam();
dataParam.put("result", status); dataParam.put("result", status);
dataParam.put("comment", remark); dataParam.put("comment", remark);
RtfUtils.getRtf().saleOrderCheck(dataBean.getId(), WorkUtils.convertMapToBody(dataParam)).compose(Transformer.schedule()).subscribe(new WorkObserver<BaseBean>() { RtfUtils.getRtf().insideOrderCheck(dataBean.getId(), WorkUtils.convertMapToBody(dataParam)).compose(Transformer.schedule()).subscribe(new WorkObserver<BaseBean>() {
@Override @Override
public void doOnSubscribe(Disposable d) { public void doOnSubscribe(Disposable d) {
} }
......
...@@ -392,7 +392,7 @@ public class OutOrderDetailActivity extends WorkToolBarActivity { ...@@ -392,7 +392,7 @@ public class OutOrderDetailActivity extends WorkToolBarActivity {
Map<String, Object> dataParam = WorkUtils.simpleParam(); Map<String, Object> dataParam = WorkUtils.simpleParam();
dataParam.put("result", status); dataParam.put("result", status);
dataParam.put("comment", remark); dataParam.put("comment", remark);
RtfUtils.getRtf().saleOrderCheck(dataBean.getId(), WorkUtils.convertMapToBody(dataParam)).compose(Transformer.schedule()).subscribe(new WorkObserver<BaseBean>() { RtfUtils.getRtf().purchaseOrderCheck(dataBean.getId(), WorkUtils.convertMapToBody(dataParam)).compose(Transformer.schedule()).subscribe(new WorkObserver<BaseBean>() {
@Override @Override
public void doOnSubscribe(Disposable d) { public void doOnSubscribe(Disposable d) {
} }
......
package com.wd.workoffice.ui.activity.bat.order;
import android.text.Editable;
import android.text.TextUtils;
import android.text.TextWatcher;
import android.view.LayoutInflater;
import android.view.View;
import android.widget.EditText;
import android.widget.LinearLayout;
import android.widget.TextView;
import com.alibaba.fastjson.JSON;
import com.wd.workoffice.R;
import com.wd.workoffice.app.BaseBean;
import com.wd.workoffice.app.WorkToolBarActivity;
import com.wd.workoffice.bean.AddStockBean;
import com.wd.workoffice.bean.UseApplyBean;
import com.wd.workoffice.bean.event.CheckAddStockEvent;
import com.wd.workoffice.bean.workEnum.OrderType;
import com.wd.workoffice.retrofit.RtfUtils;
import com.wd.workoffice.retrofit.WorkObserver;
import com.wd.workoffice.util.WorkUtils;
import org.greenrobot.eventbus.EventBus;
import java.util.Map;
import androidx.appcompat.app.AlertDialog;
import butterknife.BindView;
import butterknife.ButterKnife;
import butterknife.OnClick;
import flexible.xd.android_base.network.rtfhttp.Transformer;
import io.reactivex.Observable;
import io.reactivex.disposables.Disposable;
/**
* 领用详情
* author : flexible
* email : lgd19940421@163.com
* github: https://github.com/FlexibleXd
**/
public class QualityApplyDetailActivity extends WorkToolBarActivity {
@BindView(R.id.tv_refuse)
TextView tvRefuse;
@BindView(R.id.tv_agree)
TextView tvAgree;
@BindView(R.id.ll_bottom)
LinearLayout llBottom;
@BindView(R.id.tv_num)
TextView tvNum;
@BindView(R.id.tv_person)
TextView tvPerson;
@BindView(R.id.tv_time)
TextView tvTime;
@BindView(R.id.tv_remark)
TextView tvRemark;
@BindView(R.id.tv_check_person)
TextView tvCheckPerson;
@BindView(R.id.tv_check_time)
TextView tvCheckTime;
@BindView(R.id.tv_check_remark)
TextView tvCheckRemark;
@BindView(R.id.tv_check_status)
TextView tvCheckStatus;
@BindView(R.id.ll_check)
LinearLayout llCheck;
@BindView(R.id.tv_box_num)
TextView tvBoxNum;
private AddStockBean.RecordsBean info;
private String orderType;
@Override
protected void initView() {
ButterKnife.bind(this);
}
@Override
protected void initData() {
info = JSON.parseObject(getIntent().getStringExtra("info"), AddStockBean.RecordsBean.class);
orderType = getIntent().getStringExtra("orderType");
tvNum.setText(String.valueOf(info.getProductAmount()));
tvBoxNum.setText(String.valueOf(info.getBoxCode()));
tvPerson.setText(String.valueOf(info.getCreatedByName()));
tvTime.setText(info.getCreatedTime());
tvRemark.setText(String.valueOf(info.getApplyRemark()));
if (TextUtils.equals(info.getQualityInspectionStatus(), "0")) {
llBottom.setVisibility(View.VISIBLE);
llCheck.setVisibility(View.GONE);
} else {
llBottom.setVisibility(View.GONE);
llCheck.setVisibility(View.VISIBLE);
tvCheckPerson.setText(info.getUpdatedByName());
tvCheckTime.setText(info.getUpdatedTime());
tvCheckRemark.setText(info.getAuditRemark());
tvCheckStatus.setText(WorkUtils.getFinancialStatus(Integer.valueOf(info.getQualityInspectionStatus())));
}
}
@Override
protected void initEvent() {
}
@Override
protected int layoutId() {
return R.layout.activity_add_stock_apply_detail;
}
@OnClick({R.id.tv_refuse, R.id.tv_agree})
public void onViewClicked(View view) {
switch (view.getId()) {
case R.id.tv_refuse:
checkDialog(2, info.getId());
break;
case R.id.tv_agree:
checkDialog(1, info.getId());
break;
}
}
private void checkDialog(int status, int id) {
AlertDialog.Builder builder = new AlertDialog.Builder(this);
View view = LayoutInflater.from(this).inflate(R.layout.view_check, null);
TextView tvOk = view.findViewById(R.id.tv_ok);
TextView tvDesc = view.findViewById(R.id.tv_desc);
tvDesc.setText(status == 1 ? "通过" : "拒绝");
TextView tvNum = view.findViewById(R.id.tv_num);
TextView tvCancel = view.findViewById(R.id.tv_cancel);
EditText etRemark = view.findViewById(R.id.et_content);
etRemark.addTextChangedListener(new TextWatcher() {
@Override
public void beforeTextChanged(CharSequence s, int start, int count, int after) {
}
@Override
public void onTextChanged(CharSequence s, int start, int before, int count) {
}
@Override
public void afterTextChanged(Editable s) {
tvNum.setText(s.length() + "/140");
}
});
builder.setView(view);
AlertDialog addCartDialog = builder.create();
tvOk.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
if (TextUtils.isEmpty(etRemark.getText().toString()) && status == 2) {
toast("请填写备注");
return;
}
check(status, etRemark.getText().toString(), id);
addCartDialog.dismiss();
}
});
tvCancel.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
addCartDialog.dismiss();
}
});
addCartDialog.show();
}
private void check(int status, String remark, int id) {
Map<String, Object> param = WorkUtils.simpleParam();
param.put("result", status);
param.put("comment", remark);
param.put("id", id);
Observable<BaseBean> observable;
if (TextUtils.equals(orderType, OrderType.SUPPLIER.getCode())) {
observable = RtfUtils.getRtf().enterFoStoreApplyList(id + "", WorkUtils.convertMapToBody(param));
} else {
observable = RtfUtils.getRtf().enterFoStoreApplyList(id + "", WorkUtils.convertMapToBody(param));
}
observable.compose(Transformer.schedule()).subscribe(new WorkObserver<BaseBean>() {
@Override
public void doOnSubscribe(Disposable d) {
}
@Override
public void onFail(String errorMsg) {
hideLoading();
toast(errorMsg);
}
@Override
public void onSuccess(BaseBean data) {
hideLoading();
if (data.getCode() != 0) {
toast(data.getMessage());
return;
}
toast("操作成功");
EventBus.getDefault().post(new CheckAddStockEvent());
finish();
}
});
}
}
...@@ -138,21 +138,12 @@ public class SupplierOrderDetailActivity extends WorkToolBarActivity { ...@@ -138,21 +138,12 @@ public class SupplierOrderDetailActivity extends WorkToolBarActivity {
case 200: case 200:
break; break;
case 300: case 300:
llBottom.setVisibility(View.VISIBLE);
llApply.setVisibility(View.VISIBLE);
tvSendApply.setVisibility(View.GONE);
break; break;
case 410: case 410:
llBottom.setVisibility(View.VISIBLE);
llApply.setVisibility(View.VISIBLE);
break; break;
case 500: case 500:
llBottom.setVisibility(View.VISIBLE);
llApply.setVisibility(View.VISIBLE);
break; break;
case 600: case 600:
llBottom.setVisibility(View.VISIBLE);
llApply.setVisibility(View.VISIBLE);
break; break;
default: default:
llBottom.setVisibility(View.VISIBLE); llBottom.setVisibility(View.VISIBLE);
...@@ -211,7 +202,7 @@ public class SupplierOrderDetailActivity extends WorkToolBarActivity { ...@@ -211,7 +202,7 @@ public class SupplierOrderDetailActivity extends WorkToolBarActivity {
tvOrderNo.setText(dataBean.getId()); tvOrderNo.setText(dataBean.getId());
tvTime.setText(dataBean.getCreatedTime()); tvTime.setText(dataBean.getCreatedTime());
tvSendTime.setText(dataBean.getRequireTime()); tvSendTime.setText(dataBean.getRequireTime());
tvDesc.setText(dataBean.getAttrName()); tvOrderDesc.setText(dataBean.getAttrName());
tvPrice.setText(String.valueOf(dataBean.getLaunchOrderAmount())); tvPrice.setText(String.valueOf(dataBean.getLaunchOrderAmount()));
OrderDetail.ExpandInfoBean expandInfo = dataBean.getExpandInfo(); OrderDetail.ExpandInfoBean expandInfo = dataBean.getExpandInfo();
...@@ -247,7 +238,7 @@ public class SupplierOrderDetailActivity extends WorkToolBarActivity { ...@@ -247,7 +238,7 @@ public class SupplierOrderDetailActivity extends WorkToolBarActivity {
case R.id.tv_add: case R.id.tv_add:
startActivity(AddStockApplyActivity.class, startActivity(AddStockApplyActivity.class,
"status", dataBean.getStatus() + "", "status", dataBean.getStatus() + "",
"orderType", dataBean.getOrderType() + "", "orderType", dataBean.getExpandInfo().getOrderType(),
"num", proList.get(position).getCanInStoreProductSum() + "", "num", proList.get(position).getCanInStoreProductSum() + "",
"product", proList.get(position).getProductName(), "product", proList.get(position).getProductName(),
"simpleCode", proList.get(position).getProductSimpleCode(), "simpleCode", proList.get(position).getProductSimpleCode(),
...@@ -258,7 +249,7 @@ public class SupplierOrderDetailActivity extends WorkToolBarActivity { ...@@ -258,7 +249,7 @@ public class SupplierOrderDetailActivity extends WorkToolBarActivity {
case R.id.tv_return: case R.id.tv_return:
startActivity(ReturnApplyActivity.class, startActivity(ReturnApplyActivity.class,
"status", dataBean.getStatus() + "", "status", dataBean.getStatus() + "",
"orderType", dataBean.getOrderType() + "", "orderType", dataBean.getExpandInfo().getOrderType(),
"num", proList.get(position).getStoreSum() + "", "num", proList.get(position).getStoreSum() + "",
"product", proList.get(position).getProductName(), "product", proList.get(position).getProductName(),
"simpleCode", proList.get(position).getProductSimpleCode(), "simpleCode", proList.get(position).getProductSimpleCode(),
...@@ -278,6 +269,7 @@ public class SupplierOrderDetailActivity extends WorkToolBarActivity { ...@@ -278,6 +269,7 @@ public class SupplierOrderDetailActivity extends WorkToolBarActivity {
break; break;
case R.id.tv_quality: case R.id.tv_quality:
startActivity(QualityApplyActivity.class, startActivity(QualityApplyActivity.class,
"orderType", dataBean.getExpandInfo().getOrderType(),
"status", dataBean.getStatus() + "", "status", dataBean.getStatus() + "",
"num", proList.get(position).getStoreSum() + "", "num", proList.get(position).getStoreSum() + "",
"product", proList.get(position).getProductName(), "product", proList.get(position).getProductName(),
...@@ -298,7 +290,7 @@ public class SupplierOrderDetailActivity extends WorkToolBarActivity { ...@@ -298,7 +290,7 @@ public class SupplierOrderDetailActivity extends WorkToolBarActivity {
} }
@OnClick({ R.id.tv_finish_apply, R.id.tv_send_apply, R.id.tv_refuse, R.id.tv_agree}) @OnClick({R.id.tv_finish_apply, R.id.tv_send_apply, R.id.tv_refuse, R.id.tv_agree})
public void onViewClicked(View view) { public void onViewClicked(View view) {
switch (view.getId()) { switch (view.getId()) {
case R.id.tv_refuse: case R.id.tv_refuse:
...@@ -381,7 +373,7 @@ public class SupplierOrderDetailActivity extends WorkToolBarActivity { ...@@ -381,7 +373,7 @@ public class SupplierOrderDetailActivity extends WorkToolBarActivity {
Map<String, Object> dataParam = WorkUtils.simpleParam(); Map<String, Object> dataParam = WorkUtils.simpleParam();
dataParam.put("result", status); dataParam.put("result", status);
dataParam.put("comment", remark); dataParam.put("comment", remark);
RtfUtils.getRtf().saleOrderCheck(dataBean.getId(), WorkUtils.convertMapToBody(dataParam)).compose(Transformer.schedule()).subscribe(new WorkObserver<BaseBean>() { RtfUtils.getRtf().supplierOrderCheck(dataBean.getId(), WorkUtils.convertMapToBody(dataParam)).compose(Transformer.schedule()).subscribe(new WorkObserver<BaseBean>() {
@Override @Override
public void doOnSubscribe(Disposable d) { public void doOnSubscribe(Disposable d) {
} }
......
package com.wd.workoffice.ui.adapter;
import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.wd.workoffice.R;
import com.wd.workoffice.bean.AddStockBean;
import com.wd.workoffice.util.WorkUtils;
import java.util.List;
import androidx.annotation.Nullable;
/**
* Created by flexible on 2018/8/13.
*/
public class QualitypplyAdapter extends BaseQuickAdapter<AddStockBean.RecordsBean, BaseViewHolder> {
int status;
public QualitypplyAdapter(int layoutResId, List data) {
super(layoutResId, data);
}
public QualitypplyAdapter(int layoutResId, @Nullable List<AddStockBean.RecordsBean> data, int status) {
super(layoutResId, data);
this.status = status;
}
@Override
protected void convert(BaseViewHolder helper, AddStockBean.RecordsBean item) {
helper.setText(R.id.tv_name, item.getSerialNumber());
helper.setText(R.id.tv_num, String.valueOf(item.getProductAmount()));
helper.setText(R.id.tv_box_num, String.valueOf(item.getBoxCode()));
helper.setText(R.id.tv_time, item.getCreatedTime());
helper.setText(R.id.tv_status, WorkUtils.getFinancialStatus(Integer.valueOf(item.getQualityInspectionStatus())));
if (status == 0) {
helper.setVisible(R.id.ll_btn, true);
helper.addOnClickListener(R.id.tv_agree);
helper.addOnClickListener(R.id.tv_refuse);
}
}
}
...@@ -248,7 +248,7 @@ public class AddStockApplyFragment extends WorkBaseFg { ...@@ -248,7 +248,7 @@ public class AddStockApplyFragment extends WorkBaseFg {
observable = RtfUtils.getRtf().addPoStockApplyCheck(id + "", WorkUtils.convertMapToBody(param)); observable = RtfUtils.getRtf().addPoStockApplyCheck(id + "", WorkUtils.convertMapToBody(param));
} else if (TextUtils.equals(orderType, OrderType.SUPPLIER.getCode())) { } else if (TextUtils.equals(orderType, OrderType.SUPPLIER.getCode())) {
observable = RtfUtils.getRtf().addFoStockApplyCheck(id + "", WorkUtils.convertMapToBody(param)); observable = RtfUtils.getRtf().addFoStockApplyCheck(id + "", WorkUtils.convertMapToBody(param));
} else if (TextUtils.equals(orderType, OrderType.SUPPLIER.getCode())) { } else if (TextUtils.equals(orderType, OrderType.CRUCIBLE.getCode())) {
observable = RtfUtils.getRtf().addCoStockApplyCheck(id + "", WorkUtils.convertMapToBody(param)); observable = RtfUtils.getRtf().addCoStockApplyCheck(id + "", WorkUtils.convertMapToBody(param));
}else { }else {
observable = RtfUtils.getRtf().addStockApplyCheck(id + "", WorkUtils.convertMapToBody(param)); observable = RtfUtils.getRtf().addStockApplyCheck(id + "", WorkUtils.convertMapToBody(param));
......
...@@ -21,7 +21,9 @@ import com.wd.workoffice.bean.workEnum.OrderType; ...@@ -21,7 +21,9 @@ import com.wd.workoffice.bean.workEnum.OrderType;
import com.wd.workoffice.retrofit.RtfUtils; import com.wd.workoffice.retrofit.RtfUtils;
import com.wd.workoffice.retrofit.WorkObserver; import com.wd.workoffice.retrofit.WorkObserver;
import com.wd.workoffice.ui.activity.bat.order.AddStockApplyDetailActivity; import com.wd.workoffice.ui.activity.bat.order.AddStockApplyDetailActivity;
import com.wd.workoffice.ui.activity.bat.order.QualityApplyDetailActivity;
import com.wd.workoffice.ui.adapter.AddStockSendApplyAdapter; import com.wd.workoffice.ui.adapter.AddStockSendApplyAdapter;
import com.wd.workoffice.ui.adapter.QualitypplyAdapter;
import com.wd.workoffice.util.WorkUtils; import com.wd.workoffice.util.WorkUtils;
import org.greenrobot.eventbus.EventBus; import org.greenrobot.eventbus.EventBus;
...@@ -56,7 +58,7 @@ public class QualityApplyFragment extends WorkBaseFg { ...@@ -56,7 +58,7 @@ public class QualityApplyFragment extends WorkBaseFg {
private String state; private String state;
private int page = 1; private int page = 1;
private Map<String, Object> param; private Map<String, Object> param;
private AddStockSendApplyAdapter dataAdapter; private QualitypplyAdapter dataAdapter;
private List<AddStockBean.RecordsBean> dataList; private List<AddStockBean.RecordsBean> dataList;
private String orderId; private String orderId;
private String productId; private String productId;
...@@ -72,13 +74,13 @@ public class QualityApplyFragment extends WorkBaseFg { ...@@ -72,13 +74,13 @@ public class QualityApplyFragment extends WorkBaseFg {
@Override @Override
protected void initData() { protected void initData() {
param = WorkUtils.pageKey(); param = WorkUtils.pageKey();
param.put("status", state); param.put("qualityInspectionStatus", state);
param.put("orderId", orderId); param.put("orderId", orderId);
param.put("productId", productId); param.put("productId", productId);
page = 1; page = 1;
param.put("current", page); param.put("current", page);
dataList = new ArrayList<>(); dataList = new ArrayList<>();
dataAdapter = new AddStockSendApplyAdapter(R.layout.item_add_stock_apply, dataList, Integer.valueOf(state)); dataAdapter = new QualitypplyAdapter(R.layout.item_add_stock_apply, dataList, Integer.valueOf(state));
dataAdapter.bindToRecyclerView(rvData); dataAdapter.bindToRecyclerView(rvData);
dataAdapter.setEmptyView(R.layout.view_empty_content, rvData); dataAdapter.setEmptyView(R.layout.view_empty_content, rvData);
getData(); getData();
...@@ -160,7 +162,7 @@ public class QualityApplyFragment extends WorkBaseFg { ...@@ -160,7 +162,7 @@ public class QualityApplyFragment extends WorkBaseFg {
dataAdapter.setOnItemClickListener(new BaseQuickAdapter.OnItemClickListener() { dataAdapter.setOnItemClickListener(new BaseQuickAdapter.OnItemClickListener() {
@Override @Override
public void onItemClick(BaseQuickAdapter adapter, View view, int position) { public void onItemClick(BaseQuickAdapter adapter, View view, int position) {
startActivity(AddStockApplyDetailActivity.class, startActivity(QualityApplyDetailActivity.class,
"orderType",orderType, "orderType",orderType,
"info", JSON.toJSONString(dataList.get(position))); "info", JSON.toJSONString(dataList.get(position)));
} }
...@@ -236,14 +238,10 @@ public class QualityApplyFragment extends WorkBaseFg { ...@@ -236,14 +238,10 @@ public class QualityApplyFragment extends WorkBaseFg {
param.put("comment", remark); param.put("comment", remark);
param.put("id", id); param.put("id", id);
Observable<BaseBean> observable; Observable<BaseBean> observable;
if (TextUtils.equals(orderType, OrderType.SALE.getCode())) { if (TextUtils.equals(orderType, OrderType.SUPPLIER.getCode())) {
observable = RtfUtils.getRtf().addStockApplyCheck(id + "", WorkUtils.convertMapToBody(param)); observable = RtfUtils.getRtf().enterFoStoreApplyList(id + "", WorkUtils.convertMapToBody(param));
} else if (TextUtils.equals(orderType, OrderType.OUT_BUY.getCode())) {
observable = RtfUtils.getRtf().addPoStockApplyCheck(id + "", WorkUtils.convertMapToBody(param));
} else if (TextUtils.equals(orderType, OrderType.SUPPLIER.getCode())) {
observable = RtfUtils.getRtf().addFoStockApplyCheck(id + "", WorkUtils.convertMapToBody(param));
} else { } else {
observable = RtfUtils.getRtf().addStockApplyCheck(id + "", WorkUtils.convertMapToBody(param)); observable = RtfUtils.getRtf().enterFoStoreApplyList(id + "", WorkUtils.convertMapToBody(param));
} }
observable.compose(Transformer.schedule()).subscribe(new WorkObserver<BaseBean>() { observable.compose(Transformer.schedule()).subscribe(new WorkObserver<BaseBean>() {
@Override @Override
......
...@@ -114,7 +114,7 @@ ...@@ -114,7 +114,7 @@
android:layout_weight="1" android:layout_weight="1"
android:background="@null" android:background="@null"
android:gravity="right" android:gravity="right"
android:hint="输入数量" android:hint="输入箱号"
android:padding="3mm" android:padding="3mm"
android:textColor="@color/flexible_text_gray" android:textColor="@color/flexible_text_gray"
android:textSize="14sp" /> android:textSize="14sp" />
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论