From 53bc8cc8fd330d5e2a4a3698967548a0b74a395a Mon Sep 17 00:00:00 2001
From: 吴羡 <16976746+Xian-TT3@user.noreply.gitee.com>
Date: 星期五, 23 十月 2026 18:09:16 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'
---
src/views/standard/model/index.vue | 28 +++++++++++++++++++++++++---
1 files changed, 25 insertions(+), 3 deletions(-)
diff --git a/src/views/standard/model/index.vue b/src/views/standard/model/index.vue
index 14b6e38..3c90eea 100644
--- a/src/views/standard/model/index.vue
+++ b/src/views/standard/model/index.vue
@@ -41,6 +41,9 @@
<el-form-item label="澶囨敞" prop="remark">
<el-input v-model="copyForm.remark" clearable size="small"></el-input>
</el-form-item>
+ <el-form-item label="鏍囧噯瑕佹眰鍊�" prop="standardRequirement">
+ <el-input v-model="copyForm.standardRequirement" clearable size="small"></el-input>
+ </el-form-item>
<el-form-item label="浠锋牸(鍏�)" prop="price">
<el-input v-model="copyForm.price" clearable size="small"></el-input>
</el-form-item>
@@ -64,6 +67,7 @@
delStandardTemplate,
getEditTemplatePreparation,
} from "@/api/standard/model";
+import { validateInspectionValueAnnotation } from "@/utils/inspectionValueFormat";
export default {
name: 'Model',
components: {
@@ -87,6 +91,7 @@
number: "",
name: "",
remark: "",
+ standardRequirement: "",
price: "",
id: "",
},
@@ -102,6 +107,7 @@
{ label: "妫�楠屼緷鎹�", prop: "number" },
{ label: "妫�楠岄」鐩�", prop: "name" },
{ label: "澶囨敞", prop: "remark" },
+ { label: "鏍囧噯瑕佹眰鍊�", prop: "standardRequirement" },
{ label: "浠锋牸(鍏�)", prop: "price" },
{ label: "鍒涘缓鐢ㄦ埛", prop: "createUserName" },
{ label: "鍒涘缓鏃堕棿", prop: "createTime", width: "160" },
@@ -162,7 +168,7 @@
page: {
total: 0,
size: 10,
- current: 0,
+ current: 1,
},
tableLoading: false,
};
@@ -215,7 +221,7 @@
copyTemplate(row) {
this.title = "澶嶅埗妯$増";
this.isShowCopyTem = true;
- this.copyForm.id = row.id;
+ this.copyForm = this.HaveJson(row);
},
// 鏂板/缂栬緫/澶嶅埗妯℃澘
submitCopyInfo() {
@@ -227,6 +233,7 @@
name: this.copyForm.name,
number: this.copyForm.number,
remark: this.copyForm.remark,
+ standardRequirement: this.copyForm.standardRequirement,
price: this.copyForm.price === "" || this.copyForm.price == null ? null : this.copyForm.price,
};
switch (this.title) {
@@ -246,6 +253,8 @@
break;
case "缂栬緫":
params.thing = this.copyForm.thing ? this.copyForm.thing : "";
+ // 浠锋牸鐣欑┖浠嶆寜 0 淇濆瓨锛涙ā鏉跨紪鍒朵繚瀛樹笉浼犱环鏍硷紝闇�鐢卞悗绔繚鎸佸師鍊�
+ params.price = params.price == null ? 0 : params.price;
upStandardTemplate(params)
.then((res) => {
this.isShowCopyTem = false;
@@ -349,7 +358,12 @@
}
}
}
+ let annotationError = null;
data.data[0].celldata.forEach((a) => {
+ if (a.v && a.v.ps && typeof a.v.ps.value === "string") {
+ const error = validateInspectionValueAnnotation(a.v.ps.value);
+ if (!annotationError && error) annotationError = `鍗曞厓鏍�(${a.r + 1}琛�${a.c + 1}鍒�)锛�${error}`;
+ }
if (
a.v.ps != undefined &&
(a.v.ps.value === "妫�楠屽��" ||
@@ -362,6 +376,11 @@
}
}
});
+ if (annotationError) {
+ this.loading = false;
+ this.$message.error(annotationError);
+ return;
+ }
upStandardTemplate({
id: this.row.id,
thing: JSON.stringify(data),
@@ -370,6 +389,9 @@
this.loading = false;
this.$message.success("宸蹭繚瀛�");
this.isShow = false;
+ }).catch((error) => {
+ this.loading = false;
+ this.$message.error(error.message || "妯℃澘淇濆瓨澶辫触");
});
},
isClose(done) {
@@ -409,7 +431,7 @@
width: 88px;
font-size: 14px;
font-weight: 700;
- color: #606266;
+ color: var(--lims-text-2);
}
.search_button {
line-height: 26px;
--
Gitblit v1.9.3