diff --git a/ruoyi-admin/src/main/resources/templates/erp/bom/add.html b/ruoyi-admin/src/main/resources/templates/erp/bom/add.html
index d4e04253..fa8a082f 100644
--- a/ruoyi-admin/src/main/resources/templates/erp/bom/add.html
+++ b/ruoyi-admin/src/main/resources/templates/erp/bom/add.html
@@ -168,6 +168,7 @@
"");
}
$("#selectEngineer").val(loginName);
+ $("input[name='engineer']").val(loginName);
} else {
$.modal.msgError(res.msg);
}
diff --git a/ruoyi-admin/src/main/resources/templates/erp/bom/bom.html b/ruoyi-admin/src/main/resources/templates/erp/bom/bom.html
index 4f1b3307..af806cde 100644
--- a/ruoyi-admin/src/main/resources/templates/erp/bom/bom.html
+++ b/ruoyi-admin/src/main/resources/templates/erp/bom/bom.html
@@ -220,7 +220,7 @@
// 有待办人展示审批按钮,
if (row.todoUserId) {
var todoUserIdList = row.todoUserId.split(",");
- if(todoUserIdList.includes(loginName) || todoUserIdList.includes("admin")){
+ if(todoUserIdList.includes(loginName)){
var nodeName = row.taskName=='驳回调整'?' 调整申请':' 审批';
actions.push(' '+nodeName+' ');
}
diff --git a/ruoyi-admin/src/main/resources/templates/erp/bom/detail.html b/ruoyi-admin/src/main/resources/templates/erp/bom/detail.html
index abd9b705..17cf99c2 100644
--- a/ruoyi-admin/src/main/resources/templates/erp/bom/detail.html
+++ b/ruoyi-admin/src/main/resources/templates/erp/bom/detail.html
@@ -231,19 +231,19 @@
editable : {
editor: {
defaultValue: '%',
- title: '损耗率(%)',
- mode: 'inline',
+ title : '损耗率(%)',
+ mode:'inline',
type: 'text',
// 编辑时同样附带百分比符号
- formatter: function (value) {
+ formatter: function(value) {
return value + '%';
},
// 编辑后去除百分比符号
- custom_getter: function (value) {
+ custom_getter: function(value) {
return value.replace('%', '');
}
},
- validate : function (value) {
+ validate : function(value) {
if (!value) {
return '损耗率不能为空';
}
@@ -256,13 +256,19 @@
if (num < 0 || num > 100) {
return '损耗率必须大于等于0小于等于100';
}
- }
+ },
},
formatter: function (value,row,index){
- if(value == null){
+ if (value == null || value == ''){
return "%";
}
- return value + "%";
+ const regex = /(\d+(?:\.\d+)?)%/g; // 创建正则表达式,g标志表示全局匹配
+ const match = value.match(regex); // 使用match方法查找所有匹配
+ if (match) {
+ return value;
+ }else{
+ return value + "%";
+ }
},
},
{
diff --git a/ruoyi-admin/src/main/resources/templates/erp/bom/edit.html b/ruoyi-admin/src/main/resources/templates/erp/bom/edit.html
index 8b761f04..9c3b5c09 100644
--- a/ruoyi-admin/src/main/resources/templates/erp/bom/edit.html
+++ b/ruoyi-admin/src/main/resources/templates/erp/bom/edit.html
@@ -290,7 +290,7 @@
{
field: 'processMethod',
align: 'center',
- title: '半成品类型',
+ title: '加工方式',
formatter: function(value, row, index) {
return $.table.selectDictLabel(processMethodDatas, value);
}
diff --git a/ruoyi-admin/src/main/resources/templates/erp/bom/taskGcjlVerify.html b/ruoyi-admin/src/main/resources/templates/erp/bom/taskGcjlVerify.html
index 826598d4..e8410fb7 100644
--- a/ruoyi-admin/src/main/resources/templates/erp/bom/taskGcjlVerify.html
+++ b/ruoyi-admin/src/main/resources/templates/erp/bom/taskGcjlVerify.html
@@ -263,7 +263,6 @@
$.operate.save(prefix + "/complete/" + taskId, $('#form-edit').serialize());
}
}
-