From 3b1018a4868718c95875cc68e8679ab314510b1a Mon Sep 17 00:00:00 2001
From: llj <132905093+newwwwwwtree@users.noreply.github.com>
Date: 星期三, 16 七月 2025 11:08:23 +0800
Subject: [PATCH] 调拨申请单维护、直接调拨单维护、分步式调入单维护、分步式调出单维护工程项目维护、首件检验单维护、工序转移检验单维护、库存检验单维护、车间自检单维护异常反馈单维护、异常反馈接收单维护、异常反馈签到单维护、异常反处理单维护、异常反验收单维护检验取样单维护、检验还样单维护以上单据的维护列表快速过浦的 日期间隔 下拉框里,增加 近半年、近一年 的选项
---
WebTM/layuiadmin/MESLanguage.js | 41 ++++++++++++++++++++++++++++++++---------
1 files changed, 32 insertions(+), 9 deletions(-)
diff --git a/WebTM/layuiadmin/MESLanguage.js b/WebTM/layuiadmin/MESLanguage.js
index 8dda3cc..03170dd 100644
--- a/WebTM/layuiadmin/MESLanguage.js
+++ b/WebTM/layuiadmin/MESLanguage.js
@@ -89,12 +89,19 @@
//涓嬫媺妗嗘墍鏈夊�� select option
var OptionList = [];
const ddElementsOptionList = document.querySelectorAll("select option");
-
// 閬嶅巻鍏冪礌骞惰幏鍙栧唴瀹�
ddElementsOptionList.forEach((dd, index) => {
OptionList.push(dd.innerText.trim());
});
-
+
+ //琛ㄦ牸鍒楁暟鎹�
+ var tableColData = [];
+ const tableColDataList = document.querySelectorAll(".layui-table tr span");
+ // 閬嶅巻鍏冪礌骞惰幏鍙栧唴瀹�
+ tableColDataList.forEach((dd, index) => {
+ tableColData.push(dd.innerText.trim());
+ });
+
for (var i = 0; i < data.length; i++) {
var HTranslationText = "";
@@ -111,7 +118,7 @@
if (document.querySelectorAll("#" + data[i].HFieldCode)[0].innerHTML == data[i].HFieldName) {
document.querySelectorAll("#" + data[i].HFieldCode)[0].innerHTML = document.querySelectorAll("#" + data[i].HFieldCode)[0].innerHTML.replace(data[i].HFieldName.replace('*', ''), HTranslationText.replace('*', ''));
} else if (document.querySelectorAll("#" + data[i].HFieldCode)[0].innerText == data[i].HFieldName) {
- document.querySelectorAll("#" + data[i].HFieldCode)[0].innerHTML = document.querySelectorAll("#" + data[i].HFieldCode)[0].innerHTML.replace(data[i].HFieldName.replace('*', ''), HTranslationText.replace('*', ''));
+ document.querySelectorAll("#" + data[i].HFieldCode)[0].innerHTML = document.querySelectorAll("#" + data[i].HFieldCode)[0].innerText.replace(data[i].HFieldName.replace('*', ''), HTranslationText.replace('*', ''));
} else {
document.querySelectorAll("#" + data[i].HFieldCode)[0].innerText = document.querySelectorAll("#" + data[i].HFieldCode)[0].innerText.replace(data[i].HFieldName.replace('*', ''), HTranslationText.replace('*', ''));
}
@@ -120,10 +127,12 @@
if (InitiaType != 2) {
if (data[i].HFieldCode != "select option") {
- var count = document.querySelectorAll(data[i].HFieldCode).length;
- for (var j = 0; j < count; j++) {
- if (document.querySelectorAll(data[i].HFieldCode)[j].innerText.trim() == data[i].HFieldName) {
- document.querySelectorAll(data[i].HFieldCode)[j].innerHTML = document.querySelectorAll(data[i].HFieldCode)[j].innerHTML.replace(data[i].HFieldName, HTranslationText);
+ if (data[i].HFieldCode != ".layui-table tr span") {
+ var count = document.querySelectorAll(data[i].HFieldCode).length;
+ for (var j = 0; j < count; j++) {
+ if (document.querySelectorAll(data[i].HFieldCode)[j].innerText.trim() == data[i].HFieldName) {
+ document.querySelectorAll(data[i].HFieldCode)[j].innerHTML = document.querySelectorAll(data[i].HFieldCode)[j].innerHTML.replace(data[i].HFieldName, HTranslationText);
+ }
}
}
} else {
@@ -147,12 +156,12 @@
}
for (var j = 0; j < indicesList.length; j++) {
- document.querySelectorAll(data[i].HFieldCode)[indicesList[j]].innerHTML = document.querySelectorAll(data[i].HFieldCode)[indicesList[j]].innerHTML.replace(data[i].HFieldName, HTranslationText);
+ document.querySelectorAll(data[i].HFieldCode)[indicesList[j]].innerText = document.querySelectorAll(data[i].HFieldCode)[indicesList[j]].innerText.replace(data[i].HFieldName, HTranslationText);
}
}
} else {
- if (data[i].HFieldCode != "select option") {
+ if (data[i].HFieldCode != "select option" && data[i].HFieldCode != ".layui-table tr span") {
var count = document.querySelectorAll(data[i].HFieldCode).length;
for (var j = 0; j < count; j++) {
if (document.querySelectorAll(data[i].HFieldCode)[j].innerText.trim() == data[i].HFieldName) {
@@ -162,6 +171,20 @@
}
}
+ //琛ㄦ牸鍒楁暟鎹�
+ if (data[i].HFieldCode == ".layui-table tr span") {
+ var indicesData = [];
+ var currentIndex = -1;
+ while ((currentIndex = tableColData.indexOf(data[i].HFieldName, currentIndex + 1)) !== -1) {
+ indicesData.push(currentIndex);
+ }
+ if (data[i].HFieldCode != "select option") {
+ for (var j = 0; j < indicesData.length; j++) {
+ document.querySelectorAll(data[i].HFieldCode)[indicesData[j]].innerHTML = document.querySelectorAll(data[i].HFieldCode)[indicesData[j]].innerHTML.replace(data[i].HFieldName, HTranslationText);
+ }
+ }
+ }
+
//涓嬫媺妗嗙殑榛樿鍊�
if (data[i].HFieldCode == ".layui-unselect input") {
var uncount = document.querySelectorAll(".layui-unselect input").length;
--
Gitblit v1.9.1