diff --git a/admin-assistant/src/main/resources/template/js/assetReportManage/assetReportUnUseChoose.js b/admin-assistant/src/main/resources/template/js/assetReportManage/assetReportUnUseChoose.js
index a7fc472c561b12fd3d07a3dd0508f0628c63563f..9342886cedef1de6763a249a9662902bc375e3f6 100644
--- a/admin-assistant/src/main/resources/template/js/assetReportManage/assetReportUnUseChoose.js
+++ b/admin-assistant/src/main/resources/template/js/assetReportManage/assetReportUnUseChoose.js
@@ -51,6 +51,7 @@ layui.config({
{ field: 'name', title: '资产名称', width: 120, templet: function(d) {
return getNotUndefinedVal(d.assetMation?.name);
}},
+ { field: 'assetNum', title: '资产编号', width: 200 },
{ field: 'specifications', title: '资产规格', width: 120, templet: function(d) {
return getNotUndefinedVal(d.assetMation?.specifications);
}},
@@ -60,7 +61,6 @@ layui.config({
{ field: 'typeId', title: '资产类型', width: 120, templet: function(d) {
return sysDictDataUtil.getDictDataNameByCodeAndKey("ADM_ASSET_TYPE", d.assetMation?.typeId);
}},
- { field: 'assetNum', title: '资产编号', width: 160 },
{ field: 'storageArea', title: '存放区域', width: 200 },
{ field: 'assetAdminMation', title: '管理员', width: 120, templet: function(d) {
return getNotUndefinedVal(d.assetAdminMation?.name);
@@ -69,7 +69,7 @@ layui.config({
done: function(res) {
matchingLanguage();
- initTableSearchUtil.initAdvancedSearch(this, res.searchFilter, form, "请输入资产名称,资产编号", function () {
+ initTableSearchUtil.initAdvancedSearch(this, res.searchFilter, form, "请输入资产编号", function () {
table.reloadData("messageTable", {page: {curr: 1}, where: getTableParams()});
});
if (assetReportCheckType) {
diff --git a/erp/src/main/resources/template/js/turnIocatorManage/addWarehouseLevelValue.js b/erp/src/main/resources/template/js/turnIocatorManage/addWarehouseLevelValue.js
index 48fd3bc1568c4ab6929038e2478dd6b052aeb0ea..7147004fe9a4899f0eeb1063f10432e4f919fcae 100644
--- a/erp/src/main/resources/template/js/turnIocatorManage/addWarehouseLevelValue.js
+++ b/erp/src/main/resources/template/js/turnIocatorManage/addWarehouseLevelValue.js
@@ -1,6 +1,7 @@
// 以下两个参数开启团队权限时有值
var objectId = '', objectKey = '';
+var objectParams = {};
// 根据以下两个参数判断:工作流的判断是否要根据serviceClassName的判断
var serviceClassName;
@@ -14,36 +15,36 @@ layui.config({
var index = parent.layer.getFrameIndex(window.name);
var $ = layui.$;
var id = GetUrlParam("id");
+ var depotId = GetUrlParam("depotId");
+ var parentId = GetUrlParam("parentId");
+ // var depotLevelId = GetUrlParam("depotLevelId");
- // 根据仓库id获取仓库级别信息
- AjaxPostUtil.request({url: sysMainMation.erpBasePath + "queryDepotLevelValById", params: {id: id}, type: 'json', method: 'GET', callback: function (json) {
- let data = json.bean;
- // 仓库级别的值的【编辑布局】
- dsFormUtil.initEditPageForStatic('content', 'FP2024071200008', data, {
-
+ if (isNull(id)) {
+ dsFormUtil.initAddPageForStatic('content', 'FP2024071200007', {
savePreParams: function (params) {
- params.parentId=data.parentId
- params.depotId=data.depotId
- },
-
- saveData: function (params) {
- // 保存数据
- AjaxPostUtil.request({url: sysMainMation.erpBasePath + "writeDepotLevelVal", params: params, type: 'json', method: "POST", callback: function(json) {
- parent.layer.close(index);
- parent.refreshCode = '0';
- }});
- },
- // loadComponentCallback: function () {
- // // $("div[controlType='assetPurchasePutFromType']").remove();
- // },
- tableAddRowCallback: function (tableId) {
- $("#addRow" + tableId).remove();
- // $("div[controlType='simpleTable']").find(".assetId").prop('disabled', true);
- // $("div[controlType='simpleTable']").find(".fromId").prop('disabled', true);
- // $("div[controlType='simpleTable']").find(".unitPrice").prop('disabled', true);
- // $("div[controlType='simpleTable']").find(".chooseAssetBtn").prop('disabled', true);
+ params.depotId = depotId;
+ // params.depotLevelId = depotLevelId;
+ params.parentId = parentId;
+ // params.depotLevelId = depotLevelId;
}
});
- }});
+ }else{
+ AjaxPostUtil.request({
+ url: sysMainMation.erpBasePath + "queryDepotLevelValById",
+ params: {id: id},
+ type: 'json',
+ method: 'GET',
+ callback: function (json) {
+ let data = json.bean;
+ dsFormUtil.initEditPageForStatic('content', 'FP2024071200008', data, {
+ savePreParams: function (params) {
+ params.parentId = parentId;
+ params.depotId = depotId;
+ }
+ });
+ }
+ });
+
+ }
});
\ No newline at end of file
diff --git a/erp/src/main/resources/template/js/turnIocatorManage/batchAdd.js b/erp/src/main/resources/template/js/turnIocatorManage/batchAdd.js
new file mode 100644
index 0000000000000000000000000000000000000000..7f9391de6dd2c0280d68634436d5189e3a223aa8
--- /dev/null
+++ b/erp/src/main/resources/template/js/turnIocatorManage/batchAdd.js
@@ -0,0 +1,47 @@
+
+layui.config({
+ base: basePath,
+ version: skyeyeVersion
+}).extend({
+ window: 'js/winui.window'
+}).define(['window', 'jquery', 'winui', 'form', 'textool'], function (exports) {
+ winui.renderColor();
+ var index = parent.layer.getFrameIndex(window.name);
+ var $ = layui.$,
+ textool = layui.textool,
+ form = layui.form;
+ var parentId = getNotUndefinedVal(GetUrlParam("parentId"));
+ var depotId = getNotUndefinedVal(GetUrlParam("depotId"));
+
+ skyeyeClassEnumUtil.showEnumDataListByClassName("generateDepotLevelValType", 'select', "type", '', form);
+ form.render("select");
+
+ textool.init({
+ eleId: 'barCode',
+ tools: ['copy', 'reset', 'clear']
+ });
+
+ matchingLanguage();
+ form.render();
+ form.on('submit(getBean)', function (data) {
+ if (winui.verifyForm(data.elem)) {
+ let params = {
+ parentId: parentId,
+ depotId: depotId,
+ type: $("#type").val(),
+ number:$("#number").val(),
+ }
+ AjaxPostUtil.request({url: sysMainMation.erpBasePath + "batchGenerateDepotLevelVal", params: params, type: 'json', method: 'POST', callback: function (json) {
+ parent.layer.close(index);
+ }});
+ }
+ return false;
+ });
+
+ $("body").on("click", "#cancle", function() {
+ parent.layer.close(index);
+ });
+});
+
+
+
diff --git a/erp/src/main/resources/template/js/turnIocatorManage/turnIocatorManage.js b/erp/src/main/resources/template/js/turnIocatorManage/turnIocatorManage.js
index cf7c2add33033b9c0c0395aa7c06a19388621b88..2fa1a42695b047f7187ba509dca930bf8c0bbc98 100644
--- a/erp/src/main/resources/template/js/turnIocatorManage/turnIocatorManage.js
+++ b/erp/src/main/resources/template/js/turnIocatorManage/turnIocatorManage.js
@@ -19,8 +19,12 @@ layui.config({
tableTree = layui.tableTreeDj;
var ztree;
var id = GetUrlParam("id");
- var objectKey = GetUrlParam("objectKey")
- var objectId = GetUrlParam("objectId")
+ var objectKey = GetUrlParam("objectKey");
+ var objectId = GetUrlParam("objectId");
+ var parentId = GetUrlParam("parentId");
+ var depotId = GetUrlParam("id");
+ var depotLevelId = GetUrlParam("depotLevelId");
+
// 下拉按钮
var dropdown = new Dropdown();
@@ -49,9 +53,9 @@ layui.config({
//异步加载的方法
function onClickTree(event, treeId, treeNode) {
if(treeNode == undefined) {
- dictTypeId = "";
+ depotLevelId = "";
} else {
- dictTypeId = treeNode.id;
+ depotLevelId = treeNode.id;
}
loadTable();
}
@@ -68,44 +72,52 @@ layui.config({
limits: getLimits(),
limit: getLimit(),
cols: [[
- { title: systemLanguage["com.skyeye.serialNumber"][languageType], rowspan: '2', type: 'numbers' },
- { field: 'number', title: '编号', rowspan: '2', align: 'left', width: 350 },
- { field: 'createName', title: systemLanguage["com.skyeye.createName"][languageType], rowspan: '2', align: 'left', 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.serialNumber"][languageType], rowspan: '2', type: 'numbers'},
+ {field: 'number', title: '编号', rowspan: '2', align: 'left', width: 200},
+ { field: 'name', title: '级别', width: 200, templet: function (d) {
+ return getNotUndefinedVal(d.depotLevelMation?.name);
+ }},
+ {field: 'createName', title: systemLanguage["com.skyeye.createName"][languageType],rowspan: '2', align: 'left', 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], fixed: 'right', align: 'center', width: 350, toolbar: '#tableBar' }
]],
- done: function(json) {
+ done: function (json) {
matchingLanguage();
initTableSearchUtil.initAdvancedSearch(this, json.searchFilter, form, "请输入编号", function () {
tableTree.reload("messageTable", {page: {curr: 1}, where: getTableParams()});
});
}
- }
- // , {
- // keyId: 'id',
- // keyPid: 'parentId',
- // title: 'dictName',
- // }
- );
-
- tableTree.getTable().on('tool(messageTable)', function (obj) {
- var data = obj.data;
- var layEvent = obj.event;
- if (layEvent === 'edit') { //编辑
- edit(data);
- } else if (layEvent === 'details'){ //详情
- details(data);
- } else if (layEvent === 'del') { //删除
- del(data);
- }
+ }, {
+ keyId: 'id',
+ keyPid: 'parentId',
+ title: 'number',
+ showCache: "turnIocatorManageStatus"
});
}
+ tableTree.getTable().on('tool(messageTable)', function (obj) {
+ var data = obj.data;
+ var layEvent = obj.event;
+ if (layEvent === 'edit') { //编辑
+ edit(data);
+ } else if (layEvent === 'batchAddChildNodes') { //批量新增子节点
+ batchAddChildNodes(data);
+ } else if (layEvent === 'del') { //删除
+ del(data);
+ } else if(layEvent ==='add') { //新增子节点
+ parentId = data.id;
+ addChildNodes(data)
+ }
+ });
+
// 添加
$("body").on("click", "#addBean", function() {
+ parentId = 0;
_openNewWindows({
- url: "../../tpl/turnIocatorManage/addWarehouseLevelValue.html?id=" + id,
+ url: "../../tpl/turnIocatorManage/addWarehouseLevelValue.html?depotId=" + id
+ + "&parentId=" + parentId,
title: "新增仓库级别的值",
pageId: "warehouseLevelValueAdd",
area: ['90vw', '90vh'],
@@ -113,27 +125,15 @@ layui.config({
winui.window.msg(systemLanguage["com.skyeye.successfulOperation"][languageType], {icon: 1, time: 2000});
loadTable();
}});
-
-
-
- // _openNewWindows({
- // url: "../../tpl/turnIocatorManage/writeWarehouseLevel.html?id=" + id,
- // title: "新增仓库级别",
- // pageId: "addWarehouseLevel",
- // area: ['90vw', '90vh'],
- // callBack: function (refreshCode) {
- // winui.window.msg(systemLanguage["com.skyeye.successfulOperation"][languageType], {icon: 1, time: 2000});
- // // 刷新节点
- // var nownode = ztree.getNodesByParam("id", "0", null);
- // ztree.reAsyncChildNodes(nownode[0], "refresh");
- // }});
});
// 编辑
function edit(data) {
+ console.log('11',data)
_openNewWindows({
- url: systemCommonUtil.getUrl('FP2024071200008&id=' + data.id, null),
- title: systemLanguage["com.skyeye.editPageTitle"][languageType],
+ url: "../../tpl/turnIocatorManage/addWarehouseLevelValue.html?id=" + data.id
+ + "&parentId=" + data.parentId +"&depotId=" + data.depotId,
+ title: "编辑仓库级别的值",
pageId: "warehouseLevelValueEdit",
area: ['90vw', '90vh'],
callBack: function (refreshCode) {
@@ -142,18 +142,6 @@ layui.config({
}});
}
- // 详情
- function details(data) {
- _openNewWindows({
- url: systemCommonUtil.getUrl('FP2024071200009&id=' + data.id, null),
- title: systemLanguage["com.skyeye.detailsPageTitle"][languageType],
- pageId: "warehouseLevelValueDetails",
- area: ['90vw', '90vh'],
- callBack: function (refreshCode) {
- }});
- }
-
-
// 删除
function del(data) {
layer.confirm(systemLanguage["com.skyeye.deleteOperationMsg"][languageType], {icon: 3, title: systemLanguage["com.skyeye.deleteOperation"][languageType]}, function (index) {
@@ -165,6 +153,45 @@ layui.config({
});
}
+ function addChildNodes(data){
+ _openNewWindows({
+ url: "../../tpl/turnIocatorManage/addWarehouseLevelValue.html?depotId=" + data.depotId
+ + "&parentId=" + data.id,
+ title: "新增子节点仓库级别的值",
+ pageId: "warehouseLevelValueAdd",
+ area: ['90vw', '90vh'],
+ callBack: function (refreshCode) {
+ winui.window.msg(systemLanguage["com.skyeye.successfulOperation"][languageType], {icon: 1, time: 2000});
+ loadTable();
+ }});
+ }
+
+ //批量新增子节点
+ function batchAddChildNodes(data){
+
+ console.log('ds',data)
+ _openNewWindows({
+ url: "../../tpl/turnIocatorManage/batchAdd.html?depotId=" + data.depotId + "&parentId=" + data.id,
+ title: '批量新增',
+ pageId: "warehouseLevelValueBatchAdd",
+ area: ['90vw', '90vh'],
+ callBack: function (refreshCode) {
+ }});
+ }
+
+
+ // 批量新增
+ $("body").on("click", "#batchAdd", function() {
+ parentId = 0
+ _openNewWindows({
+ url: "../../tpl/turnIocatorManage/batchAdd.html?depotId=" + depotId + "&parentId=" + parentId,
+ title: '批量新增',
+ pageId: "warehouseLevelValueBatchAdd",
+ area: ['90vw', '90vh'],
+ callBack: function (refreshCode) {
+ }});
+ });
+
// 树节点右键
function onRightClick(event, treeId, treeNode) {
@@ -207,6 +234,7 @@ layui.config({
function chooseNodeSelect(nodeId){
var selNode = ztree.getNodeByParam("id", nodeId, null);
ztree.selectNode(selNode);
+ depotLevelId = nodeId;
}
// 树操作--文件夹或者文件删除
@@ -257,11 +285,15 @@ layui.config({
});
function loadTable() {
- table.reload("messageTable", {where: getTableParams()});
+ tableTree.reload("messageTable", {where: getTableParams()});
}
function getTableParams() {
- return $.extend(true, {objectKey:objectKey,objectId:objectId}, initTableSearchUtil.getSearchValue("messageTable"));
+ var params = {
+ objectId: depotId,
+ holderId: depotLevelId
+ };
+ return $.extend(true, params, initTableSearchUtil.getSearchValue("messageTable"));
}
exports('turnIocatorManage', {});
diff --git a/erp/src/main/resources/template/tpl/turnIocatorManage/addWarehouseLevelValue.html b/erp/src/main/resources/template/tpl/turnIocatorManage/addWarehouseLevelValue.html
index 1a44d29dfea7cc3c422cf0ac37397ea9362c54e7..06f3bf0dccd834eb1971ae986841458a1f69b39e 100644
--- a/erp/src/main/resources/template/tpl/turnIocatorManage/addWarehouseLevelValue.html
+++ b/erp/src/main/resources/template/tpl/turnIocatorManage/addWarehouseLevelValue.html
@@ -23,7 +23,7 @@