Merge branch 'master' of http://121.40.234.130:8899/root/lanzhouhailiang_one
This commit is contained in:
@@ -108,6 +108,7 @@ public class CrmToLmsServiceImpl implements CrmToLmsService {
|
||||
String warehouse_code = jo.getString("warehouse_code");
|
||||
String dateoffginbound = jo.getString("dateoffginbound");
|
||||
String packageboxsn = jo.getString("packageboxsn");
|
||||
String container_name = jo.getString("container_name");
|
||||
|
||||
HashMap map = new HashMap<>();
|
||||
if (StrUtil.isNotEmpty(material_code)) {
|
||||
@@ -146,6 +147,9 @@ public class CrmToLmsServiceImpl implements CrmToLmsService {
|
||||
if (StrUtil.isNotEmpty(warehouse_code)) {
|
||||
map.put("warehouse_code", warehouse_code);
|
||||
}
|
||||
if (StrUtil.isNotEmpty(container_name)) {
|
||||
map.put("container_name", container_name);
|
||||
}
|
||||
//将查询条件带入,查询LMS成品库库存信息
|
||||
JSONArray rows = WQL.getWO("QCRM_001").addParamMap(map).addParam("flag", "1").process().getResultJSONArray(0);
|
||||
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
输入.dateoffginbound TYPEAS s_string
|
||||
输入.warehouse_code TYPEAS s_string
|
||||
输入.customerdescription TYPEAS s_string
|
||||
输入.container_name TYPEAS s_string
|
||||
输入.width TYPEAS f_string
|
||||
|
||||
|
||||
@@ -64,6 +65,7 @@
|
||||
sub.length,
|
||||
stor.ext_id AS warehouse_code,
|
||||
sub.date_of_production AS dateofproduction,
|
||||
sub.container_name,
|
||||
CONCAT(sub.un_plan_product_property1,sub.un_plan_product_property2,sub.un_plan_product_property3) AS unplanproductproperty
|
||||
FROM
|
||||
pdm_bi_subpackagerelation sub
|
||||
|
||||
@@ -55,14 +55,20 @@ public class PrintServiceImpl implements PrintService {
|
||||
if (ObjectUtil.isEmpty(box_jo)) {
|
||||
throw new BadRequestException("未查询到木箱相关信息!");
|
||||
}
|
||||
|
||||
//组织木箱打印信息
|
||||
//箱号
|
||||
String package_box_sn = box_jo.getString("package_box_sn");
|
||||
// 木箱1
|
||||
String package_box_sn1 = package_box_sn.substring(0,package_box_sn.indexOf("@")+1);
|
||||
// 木箱2
|
||||
String package_box_sn2 = package_box_sn.substring(package_box_sn.indexOf("@") + 1, package_box_sn.length());
|
||||
|
||||
String package_box_sn1 = "";
|
||||
String package_box_sn2 = "";
|
||||
try {
|
||||
// 木箱1
|
||||
package_box_sn1 = package_box_sn.substring(0,package_box_sn.indexOf("@")+1);
|
||||
// 木箱2
|
||||
package_box_sn2 = package_box_sn.substring(package_box_sn.indexOf("@") + 1, package_box_sn.length());
|
||||
} catch (Exception e) {
|
||||
package_box_sn2 = package_box_sn;
|
||||
}
|
||||
//订单号
|
||||
String sale_order_name = box_jo.getString("sale_order_name");
|
||||
//品名
|
||||
@@ -132,13 +138,13 @@ public class PrintServiceImpl implements PrintService {
|
||||
+ width + ","
|
||||
+ pcsn + ","
|
||||
+ date_of_FG_inbound + ","
|
||||
+ box_weight + ","
|
||||
+ box_weight + "KG,"
|
||||
+ date_of_production + ","
|
||||
+ quanlity_in_box + ","
|
||||
+ quality_guaran_period + ","
|
||||
+ nspector + ","
|
||||
+ storage_conditions + ","
|
||||
+ NumberUtil.round(weight,2).toString() + ","
|
||||
+ NumberUtil.round(weight,2).toString() + "KG,"
|
||||
+ box_jo.getString("customer_name") + ","
|
||||
+ box_jo.getString("customer_description") + ","
|
||||
+ box_jo.getString("thickness") + ","
|
||||
|
||||
@@ -106,6 +106,11 @@ public interface CheckOutBillService {
|
||||
* @param whereJson /
|
||||
*/
|
||||
void allCancel(JSONObject whereJson);
|
||||
/**
|
||||
* 取消一个
|
||||
* @param whereJson /
|
||||
*/
|
||||
void oneCancel(JSONObject whereJson);
|
||||
/**
|
||||
* 设置检验站点
|
||||
* @param whereJson /
|
||||
|
||||
@@ -193,6 +193,7 @@ public class InchargeServiceImpl implements InchargeService {
|
||||
WQLObject disTab = WQLObject.getWQLObject("ST_IVT_IOStorInvDis"); // 出入库分配表
|
||||
WQLObject ivtTab = WQLObject.getWQLObject("ST_IVT_StructIvt"); // 仓位库存表
|
||||
WQLObject attrTab = WQLObject.getWQLObject("ST_IVT_StructAttr"); // 仓位表
|
||||
WQLObject wo_sect = WQLObject.getWQLObject("st_ivt_sectattr"); // 库区表
|
||||
|
||||
Long currentUserId = SecurityUtils.getCurrentUserId();
|
||||
String nickName = SecurityUtils.getCurrentNickName();
|
||||
@@ -274,7 +275,8 @@ public class InchargeServiceImpl implements InchargeService {
|
||||
jsonOutDis.put("box_no", json2.getString("box_no"));
|
||||
jsonOutDis.put("quality_scode", "01");
|
||||
// 如果是虚拟库区则将执行状态改为生成:01
|
||||
if (StrUtil.equals(jsonOutDis.getString("sect_code"), "XN01")) {
|
||||
JSONObject jsonSect = wo_sect.query("sect_id = '" + json2.getString("sect_id") + "'").uniqueResult(0);
|
||||
if (StrUtil.equals(jsonSect.getString("sect_type_attr"), "09")) {
|
||||
jsonOutDis.put("work_status", "01");
|
||||
} else {
|
||||
jsonOutDis.put("work_status", "00");
|
||||
|
||||
@@ -98,6 +98,13 @@ public class CheckOutBillController {
|
||||
checkOutBillService.allCancel(whereJson);
|
||||
return new ResponseEntity<>(HttpStatus.NO_CONTENT);
|
||||
}
|
||||
@PostMapping("/oneCancel")
|
||||
@Log("出库单全部取消")
|
||||
@ApiOperation("出库单全部取消")
|
||||
public ResponseEntity<Object> oneCancel(@RequestBody JSONObject whereJson) {
|
||||
checkOutBillService.oneCancel(whereJson);
|
||||
return new ResponseEntity<>(HttpStatus.NO_CONTENT);
|
||||
}
|
||||
@GetMapping("/getOutBillDis")
|
||||
@Log("查询出库单分配")
|
||||
@ApiOperation("查询出库单分配")
|
||||
|
||||
@@ -703,6 +703,8 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
WQLObject wo_dtl = WQLObject.getWQLObject("ST_IVT_IOStorInvDtl");
|
||||
//出库主表
|
||||
WQLObject wo_mst = WQLObject.getWQLObject("ST_IVT_IOStorInv");
|
||||
//库区表
|
||||
WQLObject wo_sect = WQLObject.getWQLObject("st_ivt_sectattr");
|
||||
|
||||
//定义需要更新的仓位集合
|
||||
HashMap<String, JSONObject> Struct_map = new HashMap<String, JSONObject>();
|
||||
@@ -741,6 +743,8 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
is_top3 = true;
|
||||
}
|
||||
JSONObject jsonMap = new JSONObject();
|
||||
// 已分配重量
|
||||
double assign_qty = dtl.getDoubleValue("assign_qty");
|
||||
|
||||
if (ObjectUtil.isNotEmpty(dtl.getString("source_bill_code")) || is_top3) {
|
||||
while (unassign_qty > 0) {
|
||||
@@ -762,6 +766,7 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
for (int j = 0; j < ivtAllArr.size(); j++) {
|
||||
JSONObject ivt = ivtAllArr.getJSONObject(j);
|
||||
double canuse_qty = ivt.getDoubleValue("canuse_qty");
|
||||
assign_qty = NumberUtil.add(assign_qty,canuse_qty);
|
||||
|
||||
if (unassign_qty >= canuse_qty) {
|
||||
unassign_qty = NumberUtil.sub(unassign_qty,canuse_qty);
|
||||
@@ -803,7 +808,8 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
dtl.put("plan_qty", ivt2.getDoubleValue("change_qty"));
|
||||
dtl.put("real_qty", ivt2.getDoubleValue("change_qty"));
|
||||
// 如果所属仓位是虚拟区 则将分配明细状态变为生成
|
||||
if (StrUtil.equals(ivt2.getString("sect_code"), "XN01")) {
|
||||
JSONObject jsonSect = wo_sect.query("sect_id = '" + ivt2.getString("sect_id") + "'").uniqueResult(0);
|
||||
if (StrUtil.equals(jsonSect.getString("sect_type_attr"), "09")) {
|
||||
dtl.put("work_status", "01");
|
||||
} else {
|
||||
dtl.put("work_status", "00");
|
||||
@@ -832,6 +838,7 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
double canuse_qty = jsonIvt.getDoubleValue("canuse_qty");
|
||||
jsonIvt.put("change_qty", canuse_qty + "");
|
||||
unassign_qty = 0;
|
||||
assign_qty = NumberUtil.add(assign_qty,canuse_qty);
|
||||
|
||||
//更新库存
|
||||
jsonIvt.put("bill_type_scode", jo_mst.getString("bill_type"));
|
||||
@@ -856,7 +863,8 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
dtl.put("plan_qty", jsonIvt.getDoubleValue("change_qty"));
|
||||
dtl.put("real_qty", jsonIvt.getDoubleValue("change_qty"));
|
||||
// 如果所属仓位是虚拟区 则将分配明细状态变为生成
|
||||
if (StrUtil.equals(jsonIvt.getString("sect_code"), "XN01")) {
|
||||
JSONObject jsonSect = wo_sect.query("sect_id = '" + jsonIvt.getString("sect_id") + "'").uniqueResult(0);
|
||||
if (StrUtil.equals(jsonSect.getString("sect_type_attr"), "09")) {
|
||||
dtl.put("work_status", "01");
|
||||
} else {
|
||||
dtl.put("work_status", "00");
|
||||
@@ -877,7 +885,7 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
HashMap<String, String> map_dtl = new HashMap<String, String>();
|
||||
//更新明细
|
||||
map_dtl.put("unassign_qty", unassign_qty + "");
|
||||
map_dtl.put("assign_qty", (plan_qty - unassign_qty) + "");
|
||||
map_dtl.put("assign_qty", assign_qty + "");
|
||||
if (unassign_qty == 0) {
|
||||
map_dtl.put("bill_status", "40");
|
||||
} else {
|
||||
@@ -913,6 +921,8 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
WQLObject wo_dtl = WQLObject.getWQLObject("ST_IVT_IOStorInvDtl");
|
||||
//出库主表
|
||||
WQLObject wo_mst = WQLObject.getWQLObject("ST_IVT_IOStorInv");
|
||||
//库区表
|
||||
WQLObject wo_sect = WQLObject.getWQLObject("st_ivt_sectattr");
|
||||
|
||||
//定义需要更新的仓位集合
|
||||
HashMap<String, JSONObject> Struct_map = new HashMap<String, JSONObject>();
|
||||
@@ -951,7 +961,8 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
is_top3 = true;
|
||||
}
|
||||
JSONObject jsonMap = new JSONObject();
|
||||
|
||||
// 已分配数量
|
||||
double assign_qty = dtl.getDoubleValue("assign_qty");
|
||||
if (ObjectUtil.isNotEmpty(dtl.getString("source_bill_code")) || is_top3) {
|
||||
while (unassign_qty > 0) {
|
||||
// 1.有销售订单号
|
||||
@@ -972,6 +983,7 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
for (int j = 0; j < ivtAllArr.size(); j++) {
|
||||
JSONObject ivt = ivtAllArr.getJSONObject(j);
|
||||
double canuse_qty = ivt.getDoubleValue("canuse_qty");
|
||||
assign_qty = NumberUtil.add(assign_qty,canuse_qty);
|
||||
|
||||
if (unassign_qty >= canuse_qty) {
|
||||
unassign_qty = unassign_qty - canuse_qty;
|
||||
@@ -1013,7 +1025,8 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
dtl.put("plan_qty", ivt2.getDoubleValue("change_qty"));
|
||||
dtl.put("real_qty", ivt2.getDoubleValue("change_qty"));
|
||||
// 如果所属仓位是虚拟区 则将分配明细状态变为生成
|
||||
if (StrUtil.equals(ivt2.getString("sect_code"), "XN01")) {
|
||||
JSONObject jsonSect = wo_sect.query("sect_id = '" + ivt2.getString("sect_id") + "'").uniqueResult(0);
|
||||
if (StrUtil.equals(jsonSect.getString("sect_type_attr"), "09")) {
|
||||
dtl.put("work_status", "01");
|
||||
} else {
|
||||
dtl.put("work_status", "00");
|
||||
@@ -1040,6 +1053,7 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
if (ObjectUtil.isEmpty(jsonIvt)) throw new BadRequestException("库存不足");
|
||||
|
||||
double canuse_qty = jsonIvt.getDoubleValue("canuse_qty");
|
||||
assign_qty = NumberUtil.add(assign_qty,canuse_qty);
|
||||
jsonIvt.put("change_qty", canuse_qty + "");
|
||||
unassign_qty = 0;
|
||||
|
||||
@@ -1066,7 +1080,8 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
dtl.put("plan_qty", jsonIvt.getDoubleValue("change_qty"));
|
||||
dtl.put("real_qty", jsonIvt.getDoubleValue("change_qty"));
|
||||
// 如果所属仓位是虚拟区 则将分配明细状态变为生成
|
||||
if (StrUtil.equals(jsonIvt.getString("sect_code"), "XN01")) {
|
||||
JSONObject jsonSect = wo_sect.query("sect_id = '" + jsonIvt.getString("sect_id") + "'").uniqueResult(0);
|
||||
if (StrUtil.equals(jsonSect.getString("sect_type_attr"), "09")) {
|
||||
dtl.put("work_status", "01");
|
||||
} else {
|
||||
dtl.put("work_status", "00");
|
||||
@@ -1079,7 +1094,7 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
HashMap<String, String> map_dtl = new HashMap<String, String>();
|
||||
//更新明细
|
||||
map_dtl.put("unassign_qty", unassign_qty + "");
|
||||
map_dtl.put("assign_qty", (plan_qty - unassign_qty) + "");
|
||||
map_dtl.put("assign_qty", assign_qty + "");
|
||||
if (unassign_qty == 0) {
|
||||
map_dtl.put("bill_status", "40");
|
||||
} else {
|
||||
@@ -1128,7 +1143,8 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
json.put("plan_qty", ivt.getDoubleValue("change_qty"));
|
||||
json.put("real_qty", ivt.getDoubleValue("change_qty"));
|
||||
// 如果所属仓位是虚拟区 则将分配明细状态变为生成
|
||||
if (StrUtil.equals(ivt.getString("sect_code"), "XN01")) {
|
||||
JSONObject jsonSect = wo_sect.query("sect_id = '" + ivt.getString("sect_id") + "'").uniqueResult(0);
|
||||
if (StrUtil.equals(jsonSect.getString("sect_type_attr"), "09")) {
|
||||
json.put("work_status", "01");
|
||||
} else {
|
||||
json.put("work_status", "00");
|
||||
@@ -1160,7 +1176,6 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void allCancel(JSONObject whereJson) {
|
||||
@@ -1218,8 +1233,115 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
//更新【出入库单明细表】中分配记录
|
||||
JSONObject jo_dtl = wo_dtl.query("iostorinvdtl_id = '" + iostorinvdtl_id + "'").uniqueResult(0);
|
||||
|
||||
jo_dtl.put("assign_qty", jo_dtl.getDoubleValue("assign_qty") - plan_qty);
|
||||
jo_dtl.put("unassign_qty", jo_dtl.getDoubleValue("unassign_qty") + plan_qty);
|
||||
|
||||
jo_dtl.put("assign_qty", NumberUtil.sub(jo_dtl.getDoubleValue("assign_qty") ,plan_qty));
|
||||
jo_dtl.put("unassign_qty", NumberUtil.sub(jo_dtl.getDoubleValue("plan_qty"),jo_dtl.getDoubleValue("assign_qty")));
|
||||
|
||||
if (jo_dtl.getDoubleValue("assign_qty") < 0) {
|
||||
jo_dtl.put("assign_qty", 0);
|
||||
}
|
||||
|
||||
if (jo_dtl.getDoubleValue("unassign_qty") > jo_dtl.getDoubleValue("plan_qty")) {
|
||||
jo_dtl.put("unassign_qty", jo_dtl.getDoubleValue("plan_qty"));
|
||||
}
|
||||
|
||||
if (jo_dtl.getDoubleValue("unassign_qty") == jo_dtl.getDoubleValue("plan_qty")) {
|
||||
jo_dtl.put("bill_status", "10");
|
||||
} else {
|
||||
jo_dtl.put("bill_status", "30");
|
||||
}
|
||||
wo_dtl.update(jo_dtl);
|
||||
//更新主表状态
|
||||
this.updateMststatus(iostorinv_id);
|
||||
//判断是否存在同单据的同起点仓位的分配
|
||||
JSONArray flag = WQL.getWO("QST_IVT_CHECKOUTBILL")
|
||||
.addParam("flag", "5")
|
||||
.addParam("is_issued", "0")
|
||||
.addParam("struct_id", dis.getString("struct_id"))
|
||||
.addParam("iostorinv_id", iostorinv_id)
|
||||
.addParam("bill_status", "01")
|
||||
.process()
|
||||
.getResultJSONArray(0);
|
||||
if (flag.size() == 0) {//仓位载具冻结数为0
|
||||
//任务号不为空
|
||||
if (ObjectUtil.isNotEmpty(dis.getString("task_id"))) {
|
||||
//更新对应任务为删除
|
||||
map.put("is_delete", "1");
|
||||
wo_Task.update(map, "task_id='" + dis.getString("task_id") + "'");
|
||||
}
|
||||
//解锁起点仓位点位
|
||||
JSONObject from_start = new JSONObject();
|
||||
from_start.put("struct_id", dis.getString("struct_id"));
|
||||
from_start.put("lock_type", "1");
|
||||
storPublicService.updateStructAndPoint2(from_start);
|
||||
//解锁终点仓位点位
|
||||
if (StrUtil.isNotEmpty(dis.getString("point_code"))) {
|
||||
JSONObject from_end = new JSONObject();
|
||||
from_end.put("point_code", dis.getString("point_code"));
|
||||
from_end.put("lock_type", "1");
|
||||
storPublicService.updateStructAndPoint2(from_end);
|
||||
}
|
||||
} else {//仓位载具扔有冻结数,需改任务类型为拣选出库
|
||||
//任务号不为空
|
||||
/* if (ObjectUtil.isNotEmpty(dis.getString("task_id"))) {
|
||||
//更新对应任务为拣选出库
|
||||
map.put("taskdtl_type", "05");
|
||||
wo_Task.update(map, "task_id='" + dis.getString("task_id") + "'");
|
||||
}*/
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void oneCancel(JSONObject whereJson) {
|
||||
//出库分配表
|
||||
WQLObject wo_dis = WQLObject.getWQLObject("ST_IVT_IOStorInvDis");
|
||||
//出库明细表
|
||||
WQLObject wo_dtl = WQLObject.getWQLObject("ST_IVT_IOStorInvDtl");
|
||||
//出库主表
|
||||
WQLObject wo_mst = WQLObject.getWQLObject("ST_IVT_IOStorInv");
|
||||
//任务表
|
||||
WQLObject wo_Task = WQLObject.getWQLObject("SCH_BASE_Task");
|
||||
|
||||
String iostorinv_id = whereJson.getString("iostorinv_id");
|
||||
//查询主表信息
|
||||
JSONObject jo_mst = wo_mst.query("iostorinv_id = '" + iostorinv_id + "'").uniqueResult(0);
|
||||
// 查询此分配明细下的所有相同箱号的分配明细
|
||||
JSONArray diss = wo_dis.query("box_no = '" + whereJson.getString("storagevehicle_code") + "' and iostorinv_id = '"+iostorinv_id+"'").getResultJSONArray(0);
|
||||
|
||||
for (int i = 0; i < diss.size(); i++) {
|
||||
JSONObject dis = diss.getJSONObject(i);
|
||||
HashMap<String, String> map = new HashMap<>();
|
||||
|
||||
String iostorinvdtl_id = dis.getString("iostorinvdtl_id");
|
||||
//统计【出入库单分配表】执行状态大于等于执行中,或【任务指令表】任务状态大于等于下发时的记录和
|
||||
JSONArray dtl = WQL.getWO("QST_IVT_CHECKOUTBILL")
|
||||
.addParam("flag", "4")
|
||||
.addParam("iostorinvdtl_id", iostorinvdtl_id)
|
||||
.process()
|
||||
.getResultJSONArray(0);
|
||||
//若存在记录,则不可取消该出库明细对应的任何分配记录
|
||||
if (dtl.size() != 0) {
|
||||
throw new BadRequestException("存在出库明细对应任务执行中或完成!");
|
||||
}
|
||||
double plan_qty = dis.getDoubleValue("plan_qty");
|
||||
//更新库存
|
||||
dis.put("change_qty", plan_qty + "");
|
||||
dis.put("bill_type_scode", jo_mst.getString("bill_type"));
|
||||
dis.put("inv_id", iostorinv_id);
|
||||
dis.put("bill_code", jo_mst.getString("bill_code"));
|
||||
dis.put("bill_table", "ST_IVT_IOStorInv");
|
||||
storPublicService.IOStor(dis, "12");
|
||||
//删除【出入库单分配表】中分配记录
|
||||
wo_dis.delete("iostorinvdis_id='" + dis.getString("iostorinvdis_id") + "'");
|
||||
//更新【出入库单明细表】中分配记录
|
||||
JSONObject jo_dtl = wo_dtl.query("iostorinvdtl_id = '" + iostorinvdtl_id + "'").uniqueResult(0);
|
||||
|
||||
|
||||
jo_dtl.put("assign_qty", NumberUtil.sub(jo_dtl.getDoubleValue("assign_qty") ,plan_qty));
|
||||
jo_dtl.put("unassign_qty", NumberUtil.sub(jo_dtl.getDoubleValue("plan_qty"),jo_dtl.getDoubleValue("assign_qty")));
|
||||
|
||||
if (jo_dtl.getDoubleValue("assign_qty") < 0) {
|
||||
jo_dtl.put("assign_qty", 0);
|
||||
@@ -1668,6 +1790,8 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
WQLObject wo_dtl = WQLObject.getWQLObject("ST_IVT_IOStorInvDtl");
|
||||
//出库主表
|
||||
WQLObject wo_mst = WQLObject.getWQLObject("ST_IVT_IOStorInv");
|
||||
//库区表
|
||||
WQLObject wo_sect = WQLObject.getWQLObject("st_ivt_sectattr");
|
||||
|
||||
//定义需要更新的仓位集合
|
||||
HashMap<String, JSONObject> Struct_map = new HashMap<>();
|
||||
@@ -1693,6 +1817,30 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
throw new BadRequestException("当前订单无可分配出库明细");
|
||||
}
|
||||
|
||||
// 判断此明细是否有子卷号:没有则过滤箱号、将此箱子里的所有子卷带出来
|
||||
if (ObjectUtil.isEmpty(dtl.getString("pcsn"))) {
|
||||
HashSet<String> boxSet = new HashSet<>();
|
||||
JSONArray boxArr = new JSONArray();
|
||||
|
||||
for (int i = 0; i < rows.size(); i++) {
|
||||
JSONObject json = rows.getJSONObject(i);
|
||||
boxSet.add(json.getString("storagevehicle_code"));
|
||||
}
|
||||
|
||||
for (String box_no : boxSet) {
|
||||
JSONArray boxIvtArr = WQL.getWO("QST_IVT_CHECKOUTBILL")
|
||||
.addParam("flag", "3")
|
||||
.addParam("box_no", box_no)
|
||||
.process()
|
||||
.getResultJSONArray(0);
|
||||
|
||||
boxArr.addAll(boxIvtArr);
|
||||
}
|
||||
rows.clear();
|
||||
rows.addAll(boxArr);
|
||||
}
|
||||
|
||||
double assign_qty = dtl.getDoubleValue("assign_qty");
|
||||
double unassign_qty = dtl.getDoubleValue("unassign_qty");
|
||||
double plan_qty = dtl.getDoubleValue("plan_qty");
|
||||
|
||||
@@ -1701,6 +1849,8 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
JSONObject ivt = rows.getJSONObject(j);
|
||||
|
||||
double canuse_qty = ivt.getDoubleValue("ivt_qty");
|
||||
assign_qty = NumberUtil.add(assign_qty,canuse_qty);
|
||||
|
||||
if (unassign_qty >= canuse_qty) {
|
||||
unassign_qty = unassign_qty - canuse_qty;
|
||||
ivt.put("change_qty", canuse_qty + "");
|
||||
@@ -1731,7 +1881,8 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
dtl.put("plan_qty", ivt.getDoubleValue("change_qty"));
|
||||
dtl.put("real_qty", ivt.getDoubleValue("change_qty"));
|
||||
// 如果所属仓位是虚拟区 则将分配明细状态变为生成
|
||||
if (StrUtil.equals(ivt.getString("sect_code"), "XN01")) {
|
||||
JSONObject jsonSect = wo_sect.query("sect_id = '" + ivt.getString("sect_id") + "'").uniqueResult(0);
|
||||
if (StrUtil.equals(jsonSect.getString("sect_type_attr"), "09")) {
|
||||
dtl.put("work_status", "01");
|
||||
} else {
|
||||
dtl.put("work_status", "00");
|
||||
@@ -1746,7 +1897,7 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
HashMap<String, String> map_dtl = new HashMap<String, String>();
|
||||
//更新明细
|
||||
map_dtl.put("unassign_qty", unassign_qty + "");
|
||||
map_dtl.put("assign_qty", (plan_qty - unassign_qty) + "");
|
||||
map_dtl.put("assign_qty", assign_qty + "");
|
||||
if (unassign_qty == 0) {
|
||||
map_dtl.put("bill_status", "40");
|
||||
} else {
|
||||
@@ -1756,59 +1907,62 @@ public class CheckOutBillServiceImpl implements CheckOutBillService {
|
||||
}
|
||||
|
||||
// 判断是否还有相同物料相同仓位的明细
|
||||
JSONObject jsonMap = new JSONObject();
|
||||
jsonMap.put("flag", "4");
|
||||
jsonMap.put("material_id", dtl.getString("material_id"));
|
||||
jsonMap.put("iostorinv_id", iostorinv_id);
|
||||
jsonMap.put("iostorinvdtl_id", whereJson.getString("iostorinvdtl_id"));
|
||||
if (ObjectUtil.isNotEmpty(dtl.getString("pcsn"))) {
|
||||
JSONObject jsonMap = new JSONObject();
|
||||
jsonMap.put("flag", "4");
|
||||
jsonMap.put("material_id", dtl.getString("material_id"));
|
||||
jsonMap.put("iostorinv_id", iostorinv_id);
|
||||
jsonMap.put("iostorinvdtl_id", whereJson.getString("iostorinvdtl_id"));
|
||||
|
||||
JSONArray dtlArr = WQL.getWO("ST_OUTIVT01").addParamMap(jsonMap).process().getResultJSONArray(0);
|
||||
for (int i = 0; i < dtlArr.size(); i++) {
|
||||
JSONObject json = dtlArr.getJSONObject(i);
|
||||
JSONArray dtlArr = WQL.getWO("ST_OUTIVT01").addParamMap(jsonMap).process().getResultJSONArray(0);
|
||||
for (int i = 0; i < dtlArr.size(); i++) {
|
||||
JSONObject json = dtlArr.getJSONObject(i);
|
||||
|
||||
JSONObject ivt = WQL.getWO("ST_OUTIVT01")
|
||||
.addParam("flag", "1")
|
||||
.addParam("material_id", json.getString("material_id"))
|
||||
.addParam("pcsn", json.getString("pcsn"))
|
||||
.process().uniqueResult(0);
|
||||
JSONObject ivt = WQL.getWO("ST_OUTIVT01")
|
||||
.addParam("flag", "1")
|
||||
.addParam("material_id", json.getString("material_id"))
|
||||
.addParam("pcsn", json.getString("pcsn"))
|
||||
.process().uniqueResult(0);
|
||||
|
||||
//更新库存
|
||||
ivt.put("change_qty", ivt.getDoubleValue("canuse_qty"));
|
||||
ivt.put("bill_type_scode", jo_mst.getString("bill_type"));
|
||||
ivt.put("inv_id", json.getString("iostorinv_id"));
|
||||
ivt.put("bill_code", jo_mst.getString("bill_code"));
|
||||
ivt.put("bill_table", "ST_IVT_IOStorInv");
|
||||
storPublicService.IOStor(ivt, "11");
|
||||
//生成分配明细
|
||||
json.put("iostorinvdis_id", IdUtil.getSnowflake(1, 1).nextId());
|
||||
json.put("sect_id", ivt.getString("sect_id"));
|
||||
json.put("sect_code", ivt.getString("sect_code"));
|
||||
json.put("sect_name", ivt.getString("sect_name"));
|
||||
json.put("struct_id", ivt.getString("struct_id"));
|
||||
json.put("struct_code", ivt.getString("struct_code"));
|
||||
json.put("struct_name", ivt.getString("struct_name"));
|
||||
json.put("pcsn", ivt.getString("pcsn"));
|
||||
json.put("box_no", ivt.getString("storagevehicle_code"));
|
||||
json.put("storagevehicle_id", ivt.getString("storagevehicle_id"));
|
||||
json.put("storagevehicle_code", ivt.getString("storagevehicle_code"));
|
||||
json.put("storagevehicle_type", ivt.getString("storagevehicle_type"));
|
||||
json.put("is_issued", "0");
|
||||
json.put("plan_qty", ivt.getDoubleValue("change_qty"));
|
||||
json.put("real_qty", ivt.getDoubleValue("change_qty"));
|
||||
// 如果所属仓位是虚拟区 则将分配明细状态变为生成
|
||||
if (StrUtil.equals(ivt.getString("sect_code"), "XN01")) {
|
||||
json.put("work_status", "01");
|
||||
} else {
|
||||
json.put("work_status", "00");
|
||||
//更新库存
|
||||
ivt.put("change_qty", ivt.getDoubleValue("canuse_qty"));
|
||||
ivt.put("bill_type_scode", jo_mst.getString("bill_type"));
|
||||
ivt.put("inv_id", json.getString("iostorinv_id"));
|
||||
ivt.put("bill_code", jo_mst.getString("bill_code"));
|
||||
ivt.put("bill_table", "ST_IVT_IOStorInv");
|
||||
storPublicService.IOStor(ivt, "11");
|
||||
//生成分配明细
|
||||
json.put("iostorinvdis_id", IdUtil.getSnowflake(1, 1).nextId());
|
||||
json.put("sect_id", ivt.getString("sect_id"));
|
||||
json.put("sect_code", ivt.getString("sect_code"));
|
||||
json.put("sect_name", ivt.getString("sect_name"));
|
||||
json.put("struct_id", ivt.getString("struct_id"));
|
||||
json.put("struct_code", ivt.getString("struct_code"));
|
||||
json.put("struct_name", ivt.getString("struct_name"));
|
||||
json.put("pcsn", ivt.getString("pcsn"));
|
||||
json.put("box_no", ivt.getString("storagevehicle_code"));
|
||||
json.put("storagevehicle_id", ivt.getString("storagevehicle_id"));
|
||||
json.put("storagevehicle_code", ivt.getString("storagevehicle_code"));
|
||||
json.put("storagevehicle_type", ivt.getString("storagevehicle_type"));
|
||||
json.put("is_issued", "0");
|
||||
json.put("plan_qty", ivt.getDoubleValue("change_qty"));
|
||||
json.put("real_qty", ivt.getDoubleValue("change_qty"));
|
||||
// 如果所属仓位是虚拟区 则将分配明细状态变为生成
|
||||
JSONObject jsonSect = wo_sect.query("sect_id = '" + ivt.getString("sect_id") + "'").uniqueResult(0);
|
||||
if (StrUtil.equals(jsonSect.getString("sect_type_attr"), "09")) {
|
||||
json.put("work_status", "01");
|
||||
} else {
|
||||
json.put("work_status", "00");
|
||||
}
|
||||
wo_dis.insert(json);
|
||||
|
||||
// 更新明细
|
||||
HashMap<String, String> map_dtl = new HashMap<String, String>();
|
||||
map_dtl.put("unassign_qty", "0");
|
||||
map_dtl.put("assign_qty", ivt.getString("change_qty"));
|
||||
map_dtl.put("bill_status", "40");
|
||||
wo_dtl.update(map_dtl, "iostorinvdtl_id='" + json.getString("iostorinvdtl_id") + "'");
|
||||
}
|
||||
wo_dis.insert(json);
|
||||
|
||||
// 更新明细
|
||||
HashMap<String, String> map_dtl = new HashMap<String, String>();
|
||||
map_dtl.put("unassign_qty", "0");
|
||||
map_dtl.put("assign_qty", ivt.getString("change_qty"));
|
||||
map_dtl.put("bill_status", "40");
|
||||
wo_dtl.update(map_dtl, "iostorinvdtl_id='" + json.getString("iostorinvdtl_id") + "'");
|
||||
}
|
||||
|
||||
//更新主表状态
|
||||
|
||||
@@ -219,6 +219,9 @@
|
||||
OPTION 输入.stor_id <> ""
|
||||
struct.stor_id = 输入.stor_id
|
||||
ENDOPTION
|
||||
OPTION 输入.box_no <> ""
|
||||
sub.package_box_sn = 输入.box_no
|
||||
ENDOPTION
|
||||
order by ivt.canuse_qty,ivt.pcsn desc
|
||||
) t1
|
||||
UNION
|
||||
@@ -269,6 +272,9 @@
|
||||
OPTION 输入.stor_id <> ""
|
||||
struct.stor_id = 输入.stor_id
|
||||
ENDOPTION
|
||||
OPTION 输入.box_no <> ""
|
||||
sub.package_box_sn = 输入.box_no
|
||||
ENDOPTION
|
||||
order by ivt2.canuse_qty,ivt2.pcsn desc
|
||||
) t2
|
||||
ENDSELECT
|
||||
|
||||
@@ -96,21 +96,21 @@
|
||||
<!--表格渲染-->
|
||||
<el-table ref="table" v-loading="crud.loading" :data="crud.data" size="mini" style="width: 100%;" @selection-change="crud.selectionChangeHandler">
|
||||
<el-table-column type="selection" width="55" />
|
||||
<el-table-column prop="struct_code" label="仓位编码" min-width="120" show-overflow-tooltip />
|
||||
<el-table-column prop="struct_name" label="仓位名称" min-width="120" show-overflow-tooltip />
|
||||
<el-table-column prop="stor_name" label="仓库" min-width="120" show-overflow-tooltip />
|
||||
<el-table-column prop="sect_name" label="库区" min-width="120" show-overflow-tooltip />
|
||||
<el-table-column prop="struct_code" label="仓位编码" :min-width="flexWidth('struct_code',crud.data,'仓位编码')" />
|
||||
<el-table-column prop="struct_name" label="仓位名称" :min-width="flexWidth('struct_name',crud.data,'仓位名称')" />
|
||||
<el-table-column prop="stor_name" label="仓库" :min-width="flexWidth('stor_name',crud.data,'仓库')" />
|
||||
<el-table-column prop="sect_name" label="库区" :min-width="flexWidth('sect_name',crud.data,'库区')" />
|
||||
<el-table-column prop="material_code" label="物料编码" :min-width="flexWidth('material_code',crud.data,'物料编码')" />
|
||||
<el-table-column prop="material_name" label="物料名称" :min-width="flexWidth('material_name',crud.data,'物料名称')" />
|
||||
<!-- <el-table-column prop="region_name" label="下料区域" min-width="120" show-overflow-tooltip />-->
|
||||
<el-table-column prop="material_code" label="物料编码" min-width="120" show-overflow-tooltip />
|
||||
<el-table-column prop="material_name" label="物料名称" min-width="120" show-overflow-tooltip />
|
||||
<el-table-column prop="quality_scode" label="品质类型" min-width="120" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
{{ dict.label.ST_QUALITY_SCODE[scope.row.quality_scode] }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="package_box_sn" label="木箱码" min-width="120"/>
|
||||
<el-table-column prop="pcsn" label="子卷号" min-width="120" show-overflow-tooltip />
|
||||
<el-table-column prop="sap_pcsn" label="sap批次" min-width="120" show-overflow-tooltip />
|
||||
<el-table-column prop="package_box_sn" label="木箱码" :min-width="flexWidth('package_box_sn',crud.data,'木箱码')" />
|
||||
<el-table-column prop="pcsn" label="子卷号" :min-width="flexWidth('pcsn',crud.data,'子卷号')" />
|
||||
<el-table-column prop="sap_pcsn" label="sap批次" :min-width="flexWidth('sap_pcsn',crud.data,'sap批次')" />
|
||||
<el-table-column prop="canuse_qty" label="可用数" :formatter="rounding" />
|
||||
<el-table-column prop="frozen_qty" label="冻结数" :formatter="rounding" />
|
||||
<el-table-column prop="ivt_qty" label="库存数" :formatter="rounding" />
|
||||
|
||||
@@ -131,17 +131,18 @@
|
||||
<el-card class="box-card" shadow="never" :body-style="{padding:'20px 20px 0 20px'}" style="margin-top: 5px;">
|
||||
<el-form ref="form2" :inline="true" :model="form" :rules="rules" size="mini">
|
||||
<el-form-item label="销售订单-新" prop="new_sale_order_name">
|
||||
<el-input v-model="form.new_sale_order_name" class="input-with-select"/>
|
||||
<el-input v-model="form.new_sale_order_name" :disabled="crud.status.view > 0" class="input-with-select"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="客户编码-新" prop="new_sale_order_name">
|
||||
<el-input v-model="form.new_customer_name" class="input-with-select"/>
|
||||
<el-input v-model="form.new_customer_name" :disabled="crud.status.view > 0" class="input-with-select"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="客户描述-新" prop="form.new_sale_order_name">
|
||||
<el-input v-model="form.new_customer_description" class="input-with-select"/>
|
||||
<el-input v-model="form.new_customer_description" :disabled="crud.status.view > 0" class="input-with-select"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="交货日期-新" prop="demand_date">
|
||||
<el-date-picker
|
||||
v-model="form.demand_date"
|
||||
:disabled="crud.status.view > 0"
|
||||
type="date"
|
||||
placeholder="选择日期"
|
||||
value-format="yyyy-MM-dd">
|
||||
@@ -150,6 +151,7 @@
|
||||
<el-form-item label="制造日期-新" prop="date_of_fg_inbound">
|
||||
<el-date-picker
|
||||
v-model="form.date_of_fg_inbound"
|
||||
:disabled="crud.status.view > 0"
|
||||
type="date"
|
||||
placeholder="选择日期"
|
||||
value-format="yyyy-MM-dd">
|
||||
@@ -161,6 +163,7 @@
|
||||
active-value="1"
|
||||
inactive-value="0"
|
||||
active-color="#13ce66"
|
||||
:disabled="crud.status.view > 0"
|
||||
inactive-color="#ff4949">
|
||||
</el-switch>
|
||||
</el-form-item>
|
||||
@@ -170,11 +173,12 @@
|
||||
active-value="1"
|
||||
inactive-value="0"
|
||||
active-color="#13ce66"
|
||||
:disabled="crud.status.view > 0"
|
||||
inactive-color="#ff4949">
|
||||
</el-switch>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<el-button class="filter-item" @click="allSend()" size="medium" icon="el-icon-plus" style="float: right; padding: 3px 0" type="warning">一键填充</el-button>
|
||||
<el-button class="filter-item" :disabled="crud.status.view > 0" @click="allSend()" size="medium" icon="el-icon-plus" style="float: right; padding: 3px 0" type="warning">一键填充</el-button>
|
||||
</el-card>
|
||||
<div class="crud-opts2">
|
||||
<span class="role-span">变更明细</span>
|
||||
|
||||
@@ -47,6 +47,7 @@
|
||||
<rrOperation />
|
||||
</el-col>
|
||||
</el-row>
|
||||
<div style="padding: 10px" />
|
||||
<!--表格渲染-->
|
||||
<el-table
|
||||
ref="table"
|
||||
@@ -58,10 +59,10 @@
|
||||
>
|
||||
<el-table-column type="selection" width="55" />
|
||||
<el-table-column show-overflow-tooltip prop="sect_name" label="库区" width="110px" />
|
||||
<el-table-column show-overflow-tooltip prop="struct_code" label="货位" width="110px" />
|
||||
<el-table-column show-overflow-tooltip prop="storagevehicle_code" label="箱号" />
|
||||
<el-table-column show-overflow-tooltip prop="material_code" label="物料编码" width="150px" />
|
||||
<el-table-column show-overflow-tooltip prop="material_name" label="物料名称" width="110px" />
|
||||
<el-table-column prop="struct_code" label="货位" :min-width="flexWidth('struct_code',crud.data,'货位')" />
|
||||
<el-table-column prop="storagevehicle_code" label="箱号" :min-width="flexWidth('storagevehicle_code',crud.data,'箱号')" />
|
||||
<el-table-column prop="material_code" label="物料编码" :min-width="flexWidth('material_code',crud.data,'物料编码')" />
|
||||
<el-table-column prop="material_name" label="物料名称" :min-width="flexWidth('material_name',crud.data,'物料名称')" />
|
||||
<el-table-column show-overflow-tooltip prop="base_qty" label="数量" :formatter="crud.formatNum0" />
|
||||
<el-table-column show-overflow-tooltip prop="qty_unit_name" label="计量单位" />
|
||||
</el-table>
|
||||
|
||||
@@ -59,6 +59,7 @@
|
||||
</el-col>
|
||||
</el-row>
|
||||
<!--表格渲染-->
|
||||
<div style="padding: 10px" />
|
||||
<el-table
|
||||
ref="table"
|
||||
v-loading="crud.loading"
|
||||
@@ -68,12 +69,12 @@
|
||||
:header-cell-style="{background:'#f5f7fa',color:'#606266'}"
|
||||
>
|
||||
<el-table-column type="selection" width="55" />
|
||||
<el-table-column show-overflow-tooltip prop="turnout_sect_name" label="库区" width="110px" />
|
||||
<el-table-column show-overflow-tooltip prop="turnout_struct_code" label="货位" width="110px" />
|
||||
<el-table-column show-overflow-tooltip prop="storagevehicle_code" label="载具号" />
|
||||
<el-table-column show-overflow-tooltip prop="material_code" label="物料编码" width="150px" />
|
||||
<el-table-column show-overflow-tooltip prop="material_name" label="物料名称" width="110px" />
|
||||
<el-table-column show-overflow-tooltip prop="pcsn" label="批次" />
|
||||
<el-table-column prop="turnout_sect_name" label="库区" :min-width="flexWidth('turnout_sect_name',crud.data,'库区')" />
|
||||
<el-table-column prop="turnout_struct_code" label="货位" :min-width="flexWidth('turnout_struct_code',crud.data,'货位')" />
|
||||
<el-table-column prop="storagevehicle_code" label="木箱号" :min-width="flexWidth('storagevehicle_code',crud.data,'木箱号')" />
|
||||
<el-table-column prop="material_code" label="物料编码" :min-width="flexWidth('material_code',crud.data,'物料编码')" />
|
||||
<el-table-column prop="material_name" label="物料名称" :min-width="flexWidth('material_name',crud.data,'物料名称')" />
|
||||
<el-table-column prop="pcsn" label="子卷号" :min-width="flexWidth('pcsn',crud.data,'子卷号')" />
|
||||
<el-table-column prop="quality_scode" label="品质类型" align="center" width="110px" :formatter="quality_scodeFormat" />
|
||||
<el-table-column show-overflow-tooltip prop="qty" label="重量" :formatter="crud.formatNum3" width="110px" />
|
||||
<el-table-column show-overflow-tooltip prop="qty_unit_name" label="重量单位" />
|
||||
|
||||
@@ -53,13 +53,13 @@
|
||||
:header-cell-style="{background:'#f5f7fa',color:'#606266'}"
|
||||
>
|
||||
<el-table-column type="selection" width="55" />
|
||||
<el-table-column show-overflow-tooltip prop="instorage_time" label="入库日期" />
|
||||
<el-table-column show-overflow-tooltip prop="material_code" label="物料编码" />
|
||||
<el-table-column show-overflow-tooltip prop="material_name" label="物料名称" />
|
||||
<el-table-column show-overflow-tooltip prop="struct_name" label="仓位" />
|
||||
<el-table-column show-overflow-tooltip prop="box_no" label="箱号" />
|
||||
<el-table-column show-overflow-tooltip prop="pcsn" label="子卷号" />
|
||||
<el-table-column show-overflow-tooltip prop="sap_pcsn" label="sap批次" />
|
||||
<el-table-column prop="instorage_time" label="入库日期" :min-width="flexWidth('instorage_time',crud.data,'入库日期')" />
|
||||
<el-table-column prop="material_code" label="物料编码" :min-width="flexWidth('material_code',crud.data,'物料编码')" />
|
||||
<el-table-column prop="material_name" label="物料名称" :min-width="flexWidth('material_name',crud.data,'物料名称')" />
|
||||
<el-table-column prop="struct_name" label="仓位" :min-width="flexWidth('struct_name',crud.data,'仓位')" />
|
||||
<el-table-column prop="box_no" label="箱号" :min-width="flexWidth('box_no',crud.data,'箱号')" />
|
||||
<el-table-column prop="pcsn" label="子卷号" :min-width="flexWidth('pcsn',crud.data,'子卷号')" />
|
||||
<el-table-column prop="sap_pcsn" label="sap批次" :min-width="flexWidth('sap_pcsn',crud.data,'sap批次')" />
|
||||
<el-table-column show-overflow-tooltip prop="plan_qty" :formatter="crud.formatNum3" label="重量" />
|
||||
<el-table-column show-overflow-tooltip prop="qty_unit_name" label="重量单位" />
|
||||
</el-table>
|
||||
|
||||
@@ -100,6 +100,7 @@
|
||||
style="width: 100%;"
|
||||
max-height="300"
|
||||
border
|
||||
:cell-style="cellStyle"
|
||||
:highlight-current-row="true"
|
||||
:header-cell-style="{background:'#f5f7fa',color:'#606266'}"
|
||||
@current-change="handleDtlCurrentChange"
|
||||
@@ -180,7 +181,7 @@
|
||||
ref="table2"
|
||||
:data="tabledis"
|
||||
style="width: 100%;"
|
||||
max-height="300"
|
||||
max-height="400"
|
||||
border
|
||||
:highlight-current-row="true"
|
||||
:header-cell-style="{background:'#f5f7fa',color:'#606266'}"
|
||||
@@ -202,9 +203,10 @@
|
||||
</el-select>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column show-overflow-tooltip prop="material_code" label="物料编码" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="material_name" label="物料名称" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="pcsn" label="子卷批次号" align="center" />
|
||||
<el-table-column prop="material_code" label="物料编码" :min-width="flexWidth('material_code',crud.data,'物料编码')"/>
|
||||
<el-table-column prop="material_name" label="物料名称" :min-width="flexWidth('material_name',crud.data,'物料名称')"/>
|
||||
<el-table-column prop="box_no" label="木箱号" :min-width="flexWidth('box_no',crud.data,'木箱号')"/>
|
||||
<el-table-column prop="pcsn" label="子卷批次号" :min-width="flexWidth('pcsn',crud.data,'子卷批次号')"/>
|
||||
<el-table-column show-overflow-tooltip prop="plan_qty" label="出库重量" :formatter="crud.formatNum3" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="struct_code" label="仓位编码" align="center" />
|
||||
<el-table-column show-overflow-tooltip prop="struct_name" label="仓位名称" align="center" />
|
||||
@@ -396,7 +398,7 @@ export default {
|
||||
}
|
||||
},
|
||||
deleteRow(row) {
|
||||
checkoutbill.allCancel(row).then(res => {
|
||||
checkoutbill.oneCancel(row).then(res => {
|
||||
this.queryTableDtl()
|
||||
})
|
||||
},
|
||||
@@ -504,6 +506,16 @@ export default {
|
||||
}).catch(() => {
|
||||
this.tabledis = []
|
||||
})
|
||||
},
|
||||
cellStyle({ row, column, rowIndex, columnIndex }) {
|
||||
const assign_qty = parseInt(row.assign_qty)
|
||||
const plan_qty = parseInt(row.plan_qty)
|
||||
|
||||
if (column.property === 'assign_qty') {
|
||||
if (assign_qty > plan_qty) {
|
||||
return 'background: yellow'
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -86,6 +86,13 @@ export function allCancel(data) {
|
||||
data
|
||||
})
|
||||
}
|
||||
export function oneCancel(data) {
|
||||
return request({
|
||||
url: '/api/checkoutbill/oneCancel',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
export function setPoint(data) {
|
||||
return request({
|
||||
url: '/api/checkoutbill/setPoint',
|
||||
@@ -190,4 +197,4 @@ export function getOutBillTask2(data) {
|
||||
data
|
||||
})
|
||||
}
|
||||
export default { add, edit, del, allDiv, allCancel, getOutBillDtl, getOutBillDis, setPoint, getOutBillTask, getStructIvt, manualDiv, confirm, issueTask, finishTask, cancleTaskfinish, getInvTypes, paramByCodeType, schAreaType, backConfirm, getOutBillDisDtl, getType, allDivOne, moneySubmit, getDisNum, queryBox, getOutBillTask2 }
|
||||
export default { add, edit, del, allDiv, allCancel, getOutBillDtl, getOutBillDis, setPoint, getOutBillTask, getStructIvt, manualDiv, confirm, issueTask, finishTask, cancleTaskfinish, getInvTypes, paramByCodeType, schAreaType, backConfirm, getOutBillDisDtl, getType, allDivOne, moneySubmit, getDisNum, queryBox, getOutBillTask2, oneCancel }
|
||||
|
||||
Reference in New Issue
Block a user