Browse Source

[fix]

委外加工 委外计划
修改委外计划列表页面;
修改委外计划详情页面;
dev
王晓迪 4 days ago
parent
commit
c2e0e15d3f
  1. 67
      ruoyi-admin/src/main/resources/templates/system/outsource_plan/detail.html
  2. 14
      ruoyi-admin/src/main/resources/templates/system/outsource_plan/outsource_plan.html

67
ruoyi-admin/src/main/resources/templates/system/outsource_plan/detail.html

@ -80,6 +80,8 @@
$("#form-outsource_plan-edit").validate({ $("#form-outsource_plan-edit").validate({
focusCleanup: true focusCleanup: true
}); });
var processMethodDatas = [[${@dict.getType('processMethod')}]];
var materialTypeDatas = [[${@category.getChildByCode('materialType')}]];
$(function() { $(function() {
var options = { var options = {
@ -90,45 +92,25 @@
showToggle: false, showToggle: false,
showColumns: false, showColumns: false,
sidePagination: "client", sidePagination: "client",
columns: [{ columns: [
checkbox: true
},
{
field: 'index',
align: 'center',
title: "序号",
formatter: function (value, row, index) {
var columnIndex = $.common.sprintf("<input type='hidden' name='index' value='%s'>", $.table.serialNumber(index));
return columnIndex + $.table.serialNumber(index);
}
},
{ {
field: 'materialNo', field: 'materialNo',
align: 'center', align: 'center',
title: '料号', title: '料号',
formatter: function(value, row, index) {
var html = $.common.sprintf("<input class='form-control' type='text' name='outsourcePlanDetailList[%s].materialNo' value='%s'>", index, value);
return html;
}
}, },
{ {
field: 'materialName', field: 'materialName',
align: 'center', align: 'center',
title: '物料名称', title: '物料名称',
formatter: function(value, row, index) {
var html = $.common.sprintf("<input class='form-control' type='text' name='outsourcePlanDetailList[%s].materialName' value='%s'>", index, value);
return html;
}
}, },
{ {
field: 'materialType', field: 'materialType',
align: 'center', align: 'center',
title: '物料类型', title: '物料类型',
formatter: function(value, row, index) { formatter: function (value, row, index) {
var html = $.common.sprintf("<input class='form-control' type='text' name='outsourcePlanDetailList[%s].materialType' value='%s'>", index, value); return $.table.selectCategoryLabel(materialTypeDatas, value);
return html;
} }
}, },
@ -136,39 +118,28 @@
field: 'materialPhotourl', field: 'materialPhotourl',
align: 'center', align: 'center',
title: '物料图片', title: '物料图片',
formatter: function(value, row, index) {
var html = $.common.sprintf("<input class='form-control' type='text' name='outsourcePlanDetailList[%s].materialPhotourl' value='%s'>", index, value);
return html;
}
}, },
{ {
field: 'description', field: 'description',
align: 'center', align: 'center',
title: '描述', title: '描述',
formatter: function(value, row, index) {
var html = $.common.sprintf("<input class='form-control' type='text' name='outsourcePlanDetailList[%s].description' value='%s'>", index, value);
return html;
}
}, },
{ {
field: 'brand', field: 'brand',
align: 'center', align: 'center',
title: '品牌', title: '品牌',
formatter: function(value, row, index) {
var html = $.common.sprintf("<input class='form-control' type='text' name='outsourcePlanDetailList[%s].brand' value='%s'>", index, value);
return html;
}
}, },
{ {
field: 'processMethod', field: 'processMethod',
align: 'center', align: 'center',
title: '加工方式', title: '加工方式',
formatter: function(value, row, index) { formatter: function (value, row, index) {
var html = $.common.sprintf("<input class='form-control' type='text' name='outsourcePlanDetailList[%s].processMethod' value='%s'>", index, value); return $.table.selectDictLabel(processMethodDatas, value);
return html;
} }
}, },
@ -176,40 +147,28 @@
field: 'unit', field: 'unit',
align: 'center', align: 'center',
title: '单位', title: '单位',
formatter: function(value, row, index) {
var html = $.common.sprintf("<input class='form-control' type='text' name='outsourcePlanDetailList[%s].unit' value='%s'>", index, value);
return html;
}
}, },
{ {
field: 'plannedOutsourceAmount', field: 'plannedOutsourceAmount',
align: 'center', align: 'center',
title: '计划委外数', title: '计划委外数',
formatter: function(value, row, index) {
var html = $.common.sprintf("<input class='form-control' type='text' name='outsourcePlanDetailList[%s].plannedOutsourceAmount' value='%s'>", index, value);
return html;
}
}, },
{ {
field: 'outsourceProcessType', field: 'outsourceProcessType',
align: 'center', align: 'center',
title: '委外工序种类', title: '委外工序种类',
formatter: function(value, row, index) {
var html = $.common.sprintf("<input class='form-control' type='text' name='outsourcePlanDetailList[%s].outsourceProcessType' value='%s'>", index, value);
return html;
}
}, },
{ {
field: 'outsourceProcessAmount', field: 'outsourceProcessAmount',
align: 'center', align: 'center',
title: '委外工序合计', title: '委外工序合计',
formatter: function(value, row, index) {
var html = $.common.sprintf("<input class='form-control' type='text' name='outsourcePlanDetailList[%s].outsourceProcessAmount' value='%s'>", index, value);
return html;
}
},] },]
}; };
$.table.init(options); $.table.init(options);

14
ruoyi-admin/src/main/resources/templates/system/outsource_plan/outsource_plan.html

@ -24,7 +24,7 @@
</li> </li>
<li> <li>
<label>审核状态:</label> <label>审核状态:</label>
<select name="auditStatus" th:with="type=${@dict.getType('sys_yes_no')}"> <select name="auditStatus" th:with="type=${@dict.getType('auditStatus')}">
<option value="">所有</option> <option value="">所有</option>
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option> <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select> </select>
@ -59,6 +59,8 @@
<th:block th:include="include :: footer" /> <th:block th:include="include :: footer" />
<script th:inline="javascript"> <script th:inline="javascript">
var detailFlag = [[${@permission.hasPermi('system:outsource_plan:detail')}]]; var detailFlag = [[${@permission.hasPermi('system:outsource_plan:detail')}]];
var processMethodDatas = [[${@dict.getType('processMethod')}]];
var materialTypeDatas = [[${@category.getChildByCode('materialType')}]];
var prefix = ctx + "system/outsource_plan"; var prefix = ctx + "system/outsource_plan";
@ -172,7 +174,10 @@
}, },
{ {
field : 'materialType', field : 'materialType',
title : '物料类型' title : '物料类型',
formatter: function (value, row, index) {
return $.table.selectCategoryLabel(materialTypeDatas, value);
}
}, },
{ {
field : 'description', field : 'description',
@ -184,7 +189,10 @@
}, },
{ {
field : 'processMethod', field : 'processMethod',
title : '加工方式' title : '加工方式',
formatter: function (value, row, index) {
return $.table.selectDictLabel(processMethodDatas, value);
}
}, },
{ {
field : 'unit', field : 'unit',

Loading…
Cancel
Save