From 688fd8243286b342bfdeb3ee0b4ee45be4c005cc Mon Sep 17 00:00:00 2001
From: czt <czt18638530771@163.com>
Date: 星期三, 04 六月 2025 11:38:08 +0800
Subject: [PATCH] 增加货位卡设备配置
---
igds-dzhwk-web/src/main/resources/static/ruoyi/js/ry-ui.js | 84 +++++++++++++++++++++++++-----------------
1 files changed, 50 insertions(+), 34 deletions(-)
diff --git a/igds-dzhwk-web/src/main/resources/static/ruoyi/js/ry-ui.js b/igds-dzhwk-web/src/main/resources/static/ruoyi/js/ry-ui.js
index aee2d34..647c5ab 100644
--- a/igds-dzhwk-web/src/main/resources/static/ruoyi/js/ry-ui.js
+++ b/igds-dzhwk-web/src/main/resources/static/ruoyi/js/ry-ui.js
@@ -157,7 +157,7 @@
// 鑾峰彇瀹炰緥ID锛屽瀛樺湪澶氫釜杩斿洖#id1,#id2 delimeter鍒嗛殧绗�
getOptionsIds: function(separator) {
var _separator = $.common.isEmpty(separator) ? "," : separator;
- var optionsIds = "";
+ var optionsIds = "";
$.each(table.config, function(key, value){
optionsIds += "#" + key + _separator;
});
@@ -175,7 +175,7 @@
isAsc: params.order
};
var currentId = $.common.isEmpty(table.options.formId) ? $('form').attr('id') : table.options.formId;
- return $.extend(curParams, $.common.formToJSON(currentId));
+ return $.extend(curParams, $.common.formToJSON(currentId));
},
// 璇锋眰鑾峰彇鏁版嵁鍚庡鐞嗗洖璋冨嚱鏁�
responseHandler: function(res) {
@@ -393,6 +393,22 @@
});
});
},
+ // Dorado椤甸潰瀵煎嚭鏁版嵁锛歶rl-璺宠浆璺緞锛宯ame-鏁版嵁鍚嶇О锛宲aram-鏌ヨ鍙傛暟
+ exportExcelDorado: function(url, name, param) {
+ $.modal.confirm("纭畾瀵煎嚭褰撳墠椤甸潰" + name + "鍚楋紵", function() {
+ $.modal.loading("姝e湪瀵煎嚭鏁版嵁锛岃绋嶅��...");
+ $.post(url, param, function(result) {
+ if (result.code == web_status.SUCCESS) {
+ window.location.href = ctx + "common/download?fileName=" + encodeURI(result.msg) + "&delete=" + true;
+ } else if (result.code == web_status.WARNING) {
+ $.modal.alertWarning(result.msg)
+ } else {
+ $.modal.alertError(result.msg);
+ }
+ $.modal.closeLoading();
+ });
+ });
+ },
// 涓嬭浇妯℃澘
importTemplate: function() {
$.get(activeWindow().table.options.importTemplateUrl, function(result) {
@@ -441,12 +457,12 @@
type: 'POST',
success: function (result) {
if (result.code == web_status.SUCCESS) {
- $.modal.close(index);
+ $.modal.close(index);
$.modal.closeAll();
$.modal.alertSuccess(result.msg);
$.table.refresh();
} else if (result.code == web_status.WARNING) {
- $.modal.close(index);
+ $.modal.close(index);
$.modal.enable();
$.modal.alertWarning(result.msg)
} else {
@@ -456,7 +472,7 @@
}
},
complete: function () {
- layero.find('#file').val('');
+ layero.find('#file').val('');
}
});
}
@@ -751,9 +767,9 @@
// 娑堟伅鎻愮ず
msg: function(content, type) {
if (type != undefined) {
- top.layer.msg(content, { icon: $.modal.icon(type), time: 1000, shift: 5 });
+ top.layer.msg(content, { icon: $.modal.icon(type), time: 1000, shift: 5 });
} else {
- top.layer.msg(content);
+ top.layer.msg(content);
}
},
// 閿欒娑堟伅
@@ -792,17 +808,17 @@
// 娑堟伅鎻愮ず锛岄噸鏂板姞杞介〉闈�
msgReload: function(msg, type) {
top.layer.msg(msg, {
- icon: $.modal.icon(type),
- time: 500,
- shade: [0.1, '#8F8F8F']
- },
- function() {
- $.modal.reload();
- });
+ icon: $.modal.icon(type),
+ time: 500,
+ shade: [0.1, '#8F8F8F']
+ },
+ function() {
+ $.modal.reload();
+ });
},
// 娑堟伅鎻愮ず鎴愬姛骞跺埛鏂扮埗绐椾綋
msgSuccessReload: function(msg) {
- $.modal.msgReload(msg, modal_status.SUCCESS);
+ $.modal.msgReload(msg, modal_status.SUCCESS);
},
// 鑾峰彇iframe椤电殑DOM
getChildFrame: function (index) {
@@ -885,9 +901,9 @@
},
// 寮瑰嚭灞傛寚瀹氬弬鏁伴�夐」
openOptions: function (options) {
- var _url = $.common.isEmpty(options.url) ? "/404.html" : options.url;
- var _title = $.common.isEmpty(options.title) ? "绯荤粺绐楀彛" : options.title;
- var _width = $.common.isEmpty(options.width) ? "800" : options.width;
+ var _url = $.common.isEmpty(options.url) ? "/404.html" : options.url;
+ var _title = $.common.isEmpty(options.title) ? "绯荤粺绐楀彛" : options.title;
+ var _width = $.common.isEmpty(options.width) ? "800" : options.width;
var _height = $.common.isEmpty(options.height) ? ($(window).height() - 50) : options.height;
var _btn = ['<i class="fa fa-check"></i> 纭', '<i class="fa fa-close"></i> 鍏抽棴'];
// 濡傛灉鏄Щ鍔ㄧ锛屽氨浣跨敤鑷�傚簲澶у皬寮圭獥
@@ -980,8 +996,8 @@
top.layer.full(index);
},
// 閫夊崱椤垫柟寮忔墦寮�
- openTab: function (title, url, isRefresh) {
- createMenuItem(url, title, isRefresh);
+ openTab: function (title, url, isRefresh, panelId) {
+ createMenuItem(url, title, isRefresh, panelId);
},
// 閫夊崱椤靛悓涓�椤电鎵撳紑
parentTab: function (title, url) {
@@ -1318,7 +1334,7 @@
if (result.code == web_status.SUCCESS) {
var parent = activeWindow();
if ($.common.isEmpty(parent.table)) {
- $.modal.msgSuccessReload(result.msg);
+ $.modal.msgSuccessReload(result.msg);
} else if (parent.table.options.type == table_type.bootstrapTable) {
$.modal.close();
parent.$.modal.msgSuccess(result.msg);
@@ -1343,8 +1359,8 @@
var currentId = $('.page-tabs-content', topWindow).find('.active').attr('data-panel');
var topWindow = $('.RuoYi_iframe[data-id="' + currentId + '"]', topWindow)[0];
if ($.common.isNotEmpty(topWindow) && $.common.isNotEmpty(currentId)) {
- var $contentWindow = topWindow.contentWindow;
- $contentWindow.$.modal.msgSuccess(result.msg);
+ var $contentWindow = topWindow.contentWindow;
+ $contentWindow.$.modal.msgSuccess(result.msg);
$contentWindow.$(".layui-layer-padding").removeAttr("style");
if ($contentWindow.table.options.type == table_type.bootstrapTable) {
$contentWindow.$.table.refresh();
@@ -1636,12 +1652,12 @@
if (!date) return;
if (!format) format = "yyyy-MM-dd";
switch (typeof date) {
- case "string":
- date = new Date(date.replace(/-/g, "/"));
- break;
- case "number":
- date = new Date(date);
- break;
+ case "string":
+ date = new Date(date.replace(/-/g, "/"));
+ break;
+ case "number":
+ date = new Date(date);
+ break;
}
if (!date instanceof Date) return;
var dict = {
@@ -1658,9 +1674,9 @@
"ss": ("" + (date.getSeconds() + 100)).substr(1)
};
return format.replace(/(yyyy|MM?|dd?|HH?|ss?|mm?)/g,
- function() {
- return dict[arguments[0]];
- });
+ function() {
+ return dict[arguments[0]];
+ });
},
// 鑾峰彇鑺傜偣鏁版嵁锛屾敮鎸佸灞傜骇璁块棶
getItemField: function (item, field) {
@@ -1735,11 +1751,11 @@
},
// 鑾峰彇obj瀵硅薄闀垮害
getLength: function(obj) {
- var count = 0;銆�銆�
+ var count = 0;
for (var i in obj) {
if (obj.hasOwnProperty(i)) {
count++;
- }銆�銆�
+ }
}
return count;
},
--
Gitblit v1.9.3