提交 dfd32335 编写于 作者: L LAPTOP-UV1MNL38\18023

feat:物料确认模块三个功能

上级 5f4536fc
......@@ -21,6 +21,9 @@ layui.config({
// 仓库出库的【编辑布局】
dsFormUtil.initEditPageForStatic('content', 'FP2024070100006', data, {
savePreParams: function (params) {
params.farmId=data.farmId
params.departmentId=data.departmentId
params.salesman=data.salesman
},
saveData: function (params) {
// 保存数据
......@@ -30,8 +33,7 @@ layui.config({
}});
},
loadComponentCallback: function () {
$("select[attrkey='holderIdType']").prop('disabled', true);
$("select[attrkey='holderIdType']").parent().next().children('i').remove();
$("div[controlType='correspondentAllEnter']").remove();
$("div[controlType='depotOutFromType']").remove();
},
tableAddRowCallback: function (tableId) {
......
......@@ -21,6 +21,9 @@ layui.config({
// 仓库出库的【编辑布局】
dsFormUtil.initEditPageForStatic('content', 'FP2024070100006', data, {
savePreParams: function (params) {
params.farmId=data.farmId
params.departmentId=data.departmentId
params.salesman=data.salesman
},
saveData: function (params) {
// 保存数据
......
......@@ -32,14 +32,24 @@ layui.config({
}},
{ field: 'operTime', title: '单据日期', rowspan: '2', align: 'center', width: 140 },
{ colspan: '2', title: '来源单据信息', align: 'center' },
{ field: 'departmentMation', title: '部门', rowspan: '2', align: 'left', width: 200, templet: function (d) {
return getNotUndefinedVal(d.departmentMation?.name);
}},
{ field: 'farmMation', title: '车间', rowspan: '2', align: 'left', width: 200, templet: function (d) {
return getNotUndefinedVal(d.farmMation?.name);
}},
{ field: 'salesmanMation', title: '业务员', rowspan: '2', align: 'left', width: 200, templet: function (d) {
return getNotUndefinedVal(d.salesmanMation?.name);
}},
{ field: 'totalPrice', title: '总金额', rowspan: '2', align: 'center', width: 140 },
{ field: 'processInstanceId', title: '流程ID', rowspan: '2', width: 100, templet: function (d) {
return '<a lay-event="processDetails" class="notice-title-click">' + getNotUndefinedVal(d.processInstanceId) + '</a>';
}},
{ field: 'state', title: '状态', rowspan: '2', width: 90, templet: function (d) {
return skyeyeClassEnumUtil.getEnumDataNameByCodeAndKey("flowableStateEnum", 'id', d.state, 'name');
}},
{ field: 'otherState', title: '出库状态', rowspan: '2', width: 90, templet: function (d) {
return skyeyeClassEnumUtil.getEnumDataNameByCodeAndKey("outLetState", 'id', d.otherState, 'name');
{ field: 'otherState', title: '确认状态', rowspan: '2', width: 90, templet: function (d) {
return skyeyeClassEnumUtil.getEnumDataNameByCodeAndKey("depotOutOtherState", 'id', d.otherState, 'name');
}},
{ field: 'createName', title: systemLanguage["com.skyeye.createName"][languageType], rowspan: '2', width: 120 },
{ field: 'createTime', title: systemLanguage["com.skyeye.createTime"][languageType], rowspan: '2', align: 'center', width: 150 },
......@@ -48,7 +58,7 @@ layui.config({
{ title: systemLanguage["com.skyeye.operation"][languageType], rowspan: '2', fixed: 'right', align: 'center', width: 200, toolbar: '#tableBar'}
], [
{ field: 'fromTypeId', title: '来源类型', width: 150, templet: function (d) {
return skyeyeClassEnumUtil.getEnumDataNameByCodeAndKey("pickFromType", 'id', d.fromTypeId, 'name');
return skyeyeClassEnumUtil.getEnumDataNameByCodeAndKey("confirmFromType", 'id', d.fromTypeId, 'name');
}},
{ field: 'fromId', title: '单据编号', width: 200, templet: function (d) {
return getNotUndefinedVal(d.fromMation?.oddNumber);
......
// 以下两个参数开启团队权限时有值
var objectId = '', objectKey = '';
// 根据以下两个参数判断:工作流的判断是否要根据serviceClassName的判断
var serviceClassName;
layui.config({
base: basePath,
version: skyeyeVersion
}).extend({
window: 'js/winui.window'
}).define(['window', 'table', 'jquery'], function (exports) {
winui.renderColor();
var index = parent.layer.getFrameIndex(window.name);
var $ = layui.$;
var id = GetUrlParam("id");
// 待确认物料转物料接收
AjaxPostUtil.request({url: sysMainMation.erpBasePath + "queryDepotOutTransById", params: {id: id}, type: 'json', method: 'GET', callback: function (json) {
let data = json.bean;
// 物料接收的【编辑布局】
dsFormUtil.initEditPageForStatic('content', 'FP2024071500004', data, {
savePreParams: function (params) {
},
saveData: function (params) {
// 保存数据
AjaxPostUtil.request({url: sysMainMation.erpBasePath + "insertDepotOutToTurnPut", params: params, type: 'json', method: "POST", callback: function(json) {
parent.layer.close(index);
parent.refreshCode = '0';
}});
},
loadComponentCallback: function () {
$("select[attrkey='departmentId']").prop('disabled', true);
$("select[attrkey='farmId']").prop('disabled', true);
$("div[controlType='userStaffChoose']").children().children('i').remove();
$("div[controlType='userStaffChoose']").children().children().children().children().children('i').remove();
$("div[controlType='confirmFromType']").remove();
},
tableAddRowCallback: function (tableId) {
$("#addRow" + tableId).remove();
$("div[controlType='simpleTable']").find(".unitPrice").prop('disabled', true);
$("div[controlType='simpleTable']").find(".amountOfMoney").prop('disabled', true);
$("div[controlType='simpleTable']").find(".taxRate").prop('disabled', true);
$("div[controlType='simpleTable']").find(".taxMoney").prop('disabled', true);
$("div[controlType='simpleTable']").find(".taxUnitPrice").prop('disabled', true);
$("div[controlType='simpleTable']").find(".taxLastMoney").prop('disabled', true);
$("div[controlType='simpleTable']").find(".chooseProductBtn").prop('disabled', true);
$("div[controlType='simpleTable']").find(".normsId").prop('disabled', true);
$("div[controlType='simpleTable']").find(".warehouse").prop('disabled', true);
}
});
}});
});
\ No newline at end of file
......@@ -32,14 +32,24 @@ layui.config({
}},
{ field: 'operTime', title: '单据日期', rowspan: '2', align: 'center', width: 140 },
{ colspan: '2', title: '来源单据信息', align: 'center' },
{ field: 'departmentMation', title: '部门', rowspan: '2', align: 'left', width: 200, templet: function (d) {
return getNotUndefinedVal(d.departmentMation?.name);
}},
{ field: 'farmMation', title: '车间', rowspan: '2', align: 'left', width: 200, templet: function (d) {
return getNotUndefinedVal(d.farmMation?.name);
}},
{ field: 'salesmanMation', title: '业务员', rowspan: '2', align: 'left', width: 200, templet: function (d) {
return getNotUndefinedVal(d.salesmanMation?.name);
}},
{ field: 'totalPrice', title: '总金额', rowspan: '2', align: 'center', width: 140 },
{ field: 'processInstanceId', title: '流程ID', rowspan: '2', width: 100, templet: function (d) {
return '<a lay-event="processDetails" class="notice-title-click">' + getNotUndefinedVal(d.processInstanceId) + '</a>';
}},
{ field: 'state', title: '状态', rowspan: '2', width: 90, templet: function (d) {
return skyeyeClassEnumUtil.getEnumDataNameByCodeAndKey("flowableStateEnum", 'id', d.state, 'name');
}},
{ field: 'otherState', title: '出库状态', rowspan: '2', width: 90, templet: function (d) {
return skyeyeClassEnumUtil.getEnumDataNameByCodeAndKey("outLetState", 'id', d.otherState, 'name');
{ field: 'otherState', title: '确认状态', rowspan: '2', width: 90, templet: function (d) {
return skyeyeClassEnumUtil.getEnumDataNameByCodeAndKey("depotOutOtherState", 'id', d.otherState, 'name');
}},
{ field: 'createName', title: systemLanguage["com.skyeye.createName"][languageType], rowspan: '2', width: 120 },
{ field: 'createTime', title: systemLanguage["com.skyeye.createTime"][languageType], rowspan: '2', align: 'center', width: 150 },
......@@ -48,7 +58,7 @@ layui.config({
{ title: systemLanguage["com.skyeye.operation"][languageType], rowspan: '2', fixed: 'right', align: 'center', width: 200, toolbar: '#tableBar'}
], [
{ field: 'fromTypeId', title: '来源类型', width: 150, templet: function (d) {
return skyeyeClassEnumUtil.getEnumDataNameByCodeAndKey("pickFromType", 'id', d.fromTypeId, 'name');
return skyeyeClassEnumUtil.getEnumDataNameByCodeAndKey("confirmFromType", 'id', d.fromTypeId, 'name');
}},
{ field: 'fromId', title: '单据编号', width: 200, templet: function (d) {
return getNotUndefinedVal(d.fromMation?.oddNumber);
......
// 以下两个参数开启团队权限时有值
var objectId = '', objectKey = '';
// 根据以下两个参数判断:工作流的判断是否要根据serviceClassName的判断
var serviceClassName;
layui.config({
base: basePath,
version: skyeyeVersion
}).extend({
window: 'js/winui.window'
}).define(['window', 'table', 'jquery'], function (exports) {
winui.renderColor();
var index = parent.layer.getFrameIndex(window.name);
var $ = layui.$;
var id = GetUrlParam("id");
// 待确认物料转物料退货
AjaxPostUtil.request({url: sysMainMation.erpBasePath + "queryDepotOutTransById", params: {id: id}, type: 'json', method: 'GET', callback: function (json) {
let data = json.bean;
// 物料退货的【编辑布局】
dsFormUtil.initEditPageForStatic('content', 'FP2024071500005', data, {
savePreParams: function (params) {
},
saveData: function (params) {
// 保存数据
AjaxPostUtil.request({url: sysMainMation.erpBasePath + "insertDepotOutToSealsReturns", params: params, type: 'json', method: "POST", callback: function(json) {
parent.layer.close(index);
parent.refreshCode = '0';
}});
},
loadComponentCallback: function () {
$("select[attrkey='departmentId']").prop('disabled', true);
$("select[attrkey='farmId']").prop('disabled', true);
$("div[controlType='userStaffChoose']").children().children('i').remove();
$("div[controlType='confirmFromType']").remove();
},
tableAddRowCallback: function (tableId) {
$("#addRow" + tableId).remove();
$("div[controlType='simpleTable']").find(".unitPrice").prop('disabled', true);
$("div[controlType='simpleTable']").find(".amountOfMoney").prop('disabled', true);
$("div[controlType='simpleTable']").find(".taxRate").prop('disabled', true);
$("div[controlType='simpleTable']").find(".taxMoney").prop('disabled', true);
$("div[controlType='simpleTable']").find(".taxUnitPrice").prop('disabled', true);
$("div[controlType='simpleTable']").find(".taxLastMoney").prop('disabled', true);
$("div[controlType='simpleTable']").find(".chooseProductBtn").prop('disabled', true);
$("div[controlType='simpleTable']").find(".normsId").prop('disabled', true);
$("div[controlType='simpleTable']").find(".warehouse").prop('disabled', true);
}
});
}});
});
\ No newline at end of file
layui.config({
base: basePath,
version: skyeyeVersion
}).extend({
window: 'js/winui.window'
}).define(['window', 'table', 'jquery', 'winui', 'form'], function (exports) {
winui.renderColor();
var $ = layui.$,
form = layui.form,
table = layui.table;
// 加载列表数据权限
loadAuthBtnGroup('messageTable', '1721045686446');
table.render({
id: 'messageTable',
elem: '#messageTable',
method: 'post',
url: sysMainMation.erpBasePath + 'queryNeedConfirmDepotOutList',
where: getTableParams(),
even: true,
page: true,
limits: getLimits(),
limit: getLimit(),
cols: [[
{ title: systemLanguage["com.skyeye.serialNumber"][languageType], type: 'numbers', rowspan: '2' },
{ field: 'oddNumber', title: '单号', rowspan: '2', width: 200, align: 'center', templet: function (d) {
var str = '<a lay-event="details" class="notice-title-click">' + d.oddNumber + '</a>';
if (!isNull(d.fromId)) {
str += '<span class="state-new">[转]</span>';
}
return str;
}},
{ field: 'operTime', title: '单据日期', rowspan: '2', align: 'center', width: 140 },
{ colspan: '2', title: '来源单据信息', align: 'center' },
{ field: 'departmentMation', title: '部门', rowspan: '2', align: 'left', width: 200, templet: function (d) {
return getNotUndefinedVal(d.departmentMation?.name);
}},
{ field: 'farmMation', title: '车间', rowspan: '2', align: 'left', width: 200, templet: function (d) {
return getNotUndefinedVal(d.farmMation?.name);
}},
{ field: 'salesmanMation', title: '业务员', rowspan: '2', align: 'left', width: 200, templet: function (d) {
return getNotUndefinedVal(d.salesmanMation?.name);
}},
{ field: 'totalPrice', title: '总金额', rowspan: '2', align: 'center', width: 140 },
{ field: 'processInstanceId', title: '流程ID', rowspan: '2', width: 100, templet: function (d) {
return '<a lay-event="processDetails" class="notice-title-click">' + getNotUndefinedVal(d.processInstanceId) + '</a>';
}},
{ field: 'state', title: '状态', rowspan: '2', width: 90, templet: function (d) {
return skyeyeClassEnumUtil.getEnumDataNameByCodeAndKey("flowableStateEnum", 'id', d.state, 'name');
}},
{ field: 'otherState', title: '确认状态', rowspan: '2', width: 90, templet: function (d) {
return skyeyeClassEnumUtil.getEnumDataNameByCodeAndKey("depotOutOtherState", 'id', d.otherState, 'name');
}},
{ field: 'createName', title: systemLanguage["com.skyeye.createName"][languageType], rowspan: '2', width: 120 },
{ field: 'createTime', title: systemLanguage["com.skyeye.createTime"][languageType], rowspan: '2', align: 'center', width: 150 },
{ field: 'lastUpdateName', title: systemLanguage["com.skyeye.lastUpdateName"][languageType], rowspan: '2', align: 'left', width: 120 },
{ field: 'lastUpdateTime', title: systemLanguage["com.skyeye.lastUpdateTime"][languageType], rowspan: '2', align: 'center', width: 150 },
{ title: systemLanguage["com.skyeye.operation"][languageType], rowspan: '2', fixed: 'right', align: 'center', width: 200, toolbar: '#tableBar'}
], [
{ field: 'fromTypeId', title: '来源类型', width: 150, templet: function (d) {
return skyeyeClassEnumUtil.getEnumDataNameByCodeAndKey("depotOutFromType", 'id', d.fromTypeId, 'name');
}},
{ field: 'fromId', title: '单据编号', width: 200, templet: function (d) {
return getNotUndefinedVal(d.fromMation?.oddNumber);
}}
]],
done: function(json) {
matchingLanguage();
initTableSearchUtil.initAdvancedSearch(this, json.searchFilter, form, "请输入单号,项目名称", function () {
table.reloadData("messageTable", {page: {curr: 1}, where: getTableParams()});
});
}
});
table.on('tool(messageTable)', function (obj) {
var data = obj.data;
var layEvent = obj.event;
if (layEvent === 'materialReceipt') { // 物料接收
materialReceipt(data);
} else if (layEvent === 'materialReturn'){ // 物料退货
materialReturn(data);
}
});
// 物料接收
function materialReceipt(data) {
_openNewWindows({
url: "../../tpl/materialReceiptForm/materialsAwaitingToReceipt.html?id=" + data.id,
title: "转物料接收",
pageId: "materialsAwaitingToReceipt",
area: ['90vw', '90vh'],
callBack: function (refreshCode) {
winui.window.msg(systemLanguage["com.skyeye.successfulOperation"][languageType], {icon: 1, time: 2000});
loadTable();
}});
}
// 物料退货
function materialReturn(data) {
_openNewWindows({
url: "../../tpl/materialReturnOrder/materialsAwaitingToReturn.html?id=" + data.id,
title: "转物料退货",
pageId: "materialsAwaitingToReturn",
area: ['90vw', '90vh'],
callBack: function (refreshCode) {
winui.window.msg(systemLanguage["com.skyeye.successfulOperation"][languageType], {icon: 1, time: 2000});
loadTable();
}});
}
form.render();
$("body").on("click", "#reloadTable", function() {
loadTable();
});
function loadTable() {
table.reloadData("messageTable", {where: getTableParams()});
}
function getTableParams() {
return $.extend(true, {}, initTableSearchUtil.getSearchValue("messageTable"));
}
exports('materialsAwaitingConfirmationList', {});
});
\ No newline at end of file
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title></title>
<link href="../../assets/lib/layui/css/layui.css" rel="stylesheet"/>
<link href="../../assets/lib/winui/css/winui.css" rel="stylesheet"/>
</head>
<body>
<div style="margin:0 auto;padding:20px;">
<form class="layui-form" action="" id="showForm" autocomplete="off">
<div id="content"></div>
<div class="layui-form-item layui-col-xs12">
<div class="layui-input-block">
<button class="winui-btn" type="button" id="cancle">
<language showName="com.skyeye.cancel"></language>
</button>
<button class="winui-btn" lay-submit lay-filter="formSaveDraft" id="formSaveDraft">保存为草稿</button>
<button class="winui-btn" lay-submit lay-filter="formWriteBean" id="formWriteBean">提交</button>
</div>
</div>
</form>
</div>
<script src="../../assets/lib/layui/layui.js"></script>
<script src="../../assets/lib/layui/custom.js"></script>
<script type="text/javascript">
layui.config({base: '../../js/materialReceiptForm/'}).use('materialsAwaitingToReceipt');
</script>
</body>
</html>
\ No newline at end of file
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title></title>
<link href="../../assets/lib/layui/css/layui.css" rel="stylesheet"/>
<link href="../../assets/lib/winui/css/winui.css" rel="stylesheet"/>
</head>
<body>
<div style="margin:0 auto;padding:20px;">
<form class="layui-form" action="" id="showForm" autocomplete="off">
<div id="content"></div>
<div class="layui-form-item layui-col-xs12">
<div class="layui-input-block">
<button class="winui-btn" type="button" id="cancle">
<language showName="com.skyeye.cancel"></language>
</button>
<button class="winui-btn" lay-submit lay-filter="formSaveDraft" id="formSaveDraft">保存为草稿</button>
<button class="winui-btn" lay-submit lay-filter="formWriteBean" id="formWriteBean">提交</button>
</div>
</div>
</form>
</div>
<script src="../../assets/lib/layui/layui.js"></script>
<script src="../../assets/lib/layui/custom.js"></script>
<script type="text/javascript">
layui.config({base: '../../js/materialReturnOrder/'}).use('materialsAwaitingToReturn');
</script>
</body>
</html>
\ No newline at end of file
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8"/>
<title></title>
<link href="../../assets/lib/layui/css/layui.css" rel="stylesheet"/>
<link href="../../assets/lib/winui/css/winui.css" rel="stylesheet"/>
</head>
<body>
<div class="winui-toolbar">
<div class="winui-tool">
<button id="reloadTable" class="winui-toolbtn search-table-btn-right"><i class="fa fa-refresh" aria-hidden="true"></i>
<language showName="com.skyeye.refreshDataBtn"></language>
</button>
</div>
</div>
<div style="margin:auto 10px;">
<table id="messageTable" lay-filter="messageTable"></table>
<script type="text/html" id="tableBar">
{{# if (d.state == 'pass') { }}
{{# if (d.otherState == 1 ||d.otherState == 2) { }}
{{# if(auth('1721046594407')) { }}
<a class="layui-btn layui-btn-xs" lay-event="materialReceipt">物料接收</a>
{{# } }}
{{# if(auth('1721046610103')) { }}
<a class="layui-btn layui-btn-xs layui-btn-danger" lay-event="materialReturn">物料退货</a>
{{# } }}
{{# } }}
{{# } }}
</script>
</div>
<script src="../../assets/lib/layui/layui.js"></script>
<script src="../../assets/lib/layui/custom.js"></script>
<script type="text/javascript">
layui.config({base: '../../js/materialsAwaitingConfirmation/'}).use('materialsAwaitingConfirmationList');
</script>
</body>
</html>
\ No newline at end of file
......@@ -52,6 +52,7 @@
"machinStateEnum": {"name": "加工单状态", "className": "skyeye-erp#com.skyeye.machin.classenum.MachinStateEnum"},
"machinPickStateEnum": {"name": "加工单领料状态", "className": "skyeye-erp#com.skyeye.machin.classenum.MachinPickStateEnum"},
"outLetState": {"name": "领料/补料单出库状态", "className": "skyeye-erp#com.skyeye.pick.classenum.OutLetState"},
"depotOutOtherState": {"name": "待确认物料单确认状态", "className": "skyeye-erp#com.skyeye.depot.classenum.DepotOutOtherState"},
"putState": {"name": "退料单入库状态", "className": "skyeye-erp#com.skyeye.pick.classenum.PutState"},
"machinChildStateEnum": {"name": "工序验收单状态", "className": "skyeye-erp#com.skyeye.machin.classenum.MachinChildStateEnum"},
"machinProcedureAcceptChildType": {"name": "工序验收单耗材类型枚举", "className": "skyeye-erp#com.skyeye.machinprocedure.classenum.MachinProcedureAcceptChildType"},
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册