diff --git a/ruoyi-admin/src/main/resources/templates/system/outsource_order/addRequisition.html b/ruoyi-admin/src/main/resources/templates/system/outsource_order/addRequisition.html
index 94a427cc..0c62d0b9 100644
--- a/ruoyi-admin/src/main/resources/templates/system/outsource_order/addRequisition.html
+++ b/ruoyi-admin/src/main/resources/templates/system/outsource_order/addRequisition.html
@@ -313,48 +313,42 @@
{
title: '阶层',
field: 'level',
+ align: 'center',
formatter: function(value, row, index) {
return $.table.selectDictLabel(levelDatas, value);
}
},
{title: '委外计划详情id', field: 'outsourcePlanDetailId',visible:false,},
- {title: '料号', field: 'materialNo'},
- {title: '图片', field: 'materialPhotourl', formatter: function (value, row, index) {
+ {title: '料号', field: 'materialNo', align: 'center',},
+ {title: '图片', field: 'materialPhotourl', align: 'center', formatter: function (value, row, index) {
return $.table.imageView(value);
}
},
- {title: '物料类型',field: 'materialType',
+ {title: '物料类型',field: 'materialType',align: 'center',
formatter: function(value, row, index) {return $.table.selectCategoryLabel(materialTypeDatas, value);}
},
- {title: '物料名称', field: 'materialName'},
- {title: '物料描述', field: 'description'},
- {title: '品牌', field: 'brand'},
+ {title: '物料名称', field: 'materialName', align: 'center',},
+ {title: '物料描述', field: 'description', align: 'center',},
+ {title: '品牌', field: 'brand', align: 'center',},
{title: '单位', field: 'unit', align: 'center', },
{title: '加工方式', field: 'processMethod', align: 'center',
formatter: function (value, row, index) {
return $.table.selectDictLabel(processMethodDatas, value);
}
},
- {title: '计划委外数', field: 'plannedOutsourceAmount',
- formatter: function (value, row, index) {
- if(value === null || value === ''||value === undefined){
- value = parentRow.plannedOutsourceAmount;
- }
- return value;
- }
+ {
+ title: '可用库存数',
+ field: 'stockNum',
+ align: 'center',
},
- {title: '实际委外数', field: 'actualOutsourceAmount',
- formatter: function (value, row, index) {
-
- if(value === null || value === ''||value === undefined){
- value = parentRow.actualOutsourceAmount;
- }
- return value;
- }
+ {
+ title: '已委外领料数',
+ field: 'pickedNum',
+ align: 'center',
},
- {title: '已委外领料数', field: 'pickedNum'},
{
title: '本次领料数',
+ align: 'center',
field: 'pickingNum',
formatter: function(value, row, index) {
var html = $.common.sprintf("", index, value);
@@ -427,8 +421,22 @@
var childDatas = $("#"+childTableId).bootstrapTable("getData");
if(childDatas.length <= 0) return;
+ var childValues = false;
+ childDatas.forEach(function (material,index) {
+ var inputId = "pickNum_" + childTableId + "_" + index;
+ if ($("#" + inputId).val() === "" || $("#" + inputId).val() === "0") {
+ return;
+ } else {
+ childValues = true;
+ }
+ });
+ if(childValues == false){
+ return;
+ }
+
if (typeof materialObj === 'undefined') return;
var rows = $("#" + "bootstrap-table_" + tableId).bootstrapTable('getData').length;
+
if(rows != 0) {
var data = $("#" + "bootstrap-table_" + tableId).bootstrapTable('getData')[0];
@@ -494,8 +502,7 @@
level: 1,
processMethod: material.processMethod,
materialType: material.materialType,
- plannedOutsourceAmount: data.plannedOutsourceAmount,
- actualOutsourceAmount: data.actualOutsourceAmount,
+ stockNum: material.stockNum,
outsourceOrderNo: outsourceRequisition.outsourceOrderNo,
takenMaterial:material.pickedNum,
takingMaterial: value,
diff --git a/ruoyi-admin/src/main/resources/templates/system/outsource_order/outsource_order.html b/ruoyi-admin/src/main/resources/templates/system/outsource_order/outsource_order.html
index dd7d70f8..4d518d67 100644
--- a/ruoyi-admin/src/main/resources/templates/system/outsource_order/outsource_order.html
+++ b/ruoyi-admin/src/main/resources/templates/system/outsource_order/outsource_order.html
@@ -292,18 +292,18 @@
// 审核状态-审核通过 使用状态-是 未发起作废流程
if(row.auditStatus=="1" && row.useStatus=="1"){//&& !row.cancelInstanceId
// 作废
- actions.push(' 作废');
+ actions.push(' 作废');
//领料,入库
- actions.push('领料 ');
- actions.push('入库 ');
+ actions.push('领料 ');
+ actions.push('入库 ');
}else if(row.auditStatus =="2"){
// 编辑
- actions.push(' 编辑 ');
+ actions.push(' 编辑 ');
}
// 已作废
if(row.useStatus=="2" && !row.restoreInstanceId){
// 恢复
- actions.push(' 恢复 ');
+ actions.push(' 恢复 ');
}
// 有流程实例id
if (row.instanceId) {
@@ -312,16 +312,17 @@
var todoUserIdList = row.todoUserId.split(",");
if(todoUserIdList.includes(loginName) || loginName == 'admin'){
var nodeName = row.taskName=='驳回调整'?' 调整申请':' 审批';
- actions.push(' '+nodeName+' ');
+ actions.push(' '+nodeName+' ');
}
}
// 审批历史
- actions.push(' 审批历史 ');
+ actions.push(' 审批历史 ');
// 进度查看
- actions.push(' 进度 ');
+ actions.push(' 进度查看 ');
}
- actions.push('详情');
- return actions.join('');
+ actions.push('详情');
+ var actionLinks = actions.join('');
+ return $.table.dropdownToggle(actionLinks);
}
}],
rowStyle: function (row, index) {
diff --git a/ruoyi-admin/src/main/resources/templates/system/outsource_plan/addOutsourceOrder.html b/ruoyi-admin/src/main/resources/templates/system/outsource_plan/addOutsourceOrder.html
index cc326e46..5c44a995 100644
--- a/ruoyi-admin/src/main/resources/templates/system/outsource_plan/addOutsourceOrder.html
+++ b/ruoyi-admin/src/main/resources/templates/system/outsource_plan/addOutsourceOrder.html
@@ -342,6 +342,9 @@
if (!existingRecord.outsourceProcessList) {
existingRecord.outsourceProcessList = [];
}
+ var planNum = Number(existingRecord.plannedOutsourceAmount);
+ planNum = planNum + Number(current.plannedOutsourceAmount);
+ existingRecord.plannedOutsourceAmount = planNum;
existingRecord.outsourceProcessList = current.material.outsourceProcessList;
if (typeof existingRecord.correlationCodes === 'string' && typeof current.material.correlationCodes === 'string') {
existingRecord.correlationCodes += current.material.correlationCodes.includes(',') ? current.material.correlationCodes : `,${current.material.correlationCodes}`;