From 46246f37b47d24c37fc5976d9125bf18c5e084ed Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期三, 12 三月 2025 16:20:29 +0800
Subject: [PATCH] 设备搬迁-设备借用联调
---
src/views/structural/capabilityAndLaboratory/capabilityComponents/testObjectEditForm.vue | 32 +++++++++++++-------------------
1 files changed, 13 insertions(+), 19 deletions(-)
diff --git a/src/views/structural/capabilityAndLaboratory/capabilityComponents/testObjectEditForm.vue b/src/views/structural/capabilityAndLaboratory/capabilityComponents/testObjectEditForm.vue
index e92119c..d2ac2e6 100644
--- a/src/views/structural/capabilityAndLaboratory/capabilityComponents/testObjectEditForm.vue
+++ b/src/views/structural/capabilityAndLaboratory/capabilityComponents/testObjectEditForm.vue
@@ -1,10 +1,12 @@
<template>
<div>
- <el-dialog :title="operationType === 'add' ? '鏂板' : '缂栬緫'" :visible.sync="editFormDia" width="500px" @close="closeDia">
+ <el-dialog :title="operationType === 'add' ? '鏂板' : '缂栬緫'" :visible.sync="editFormDia" width="500px"
+ @close="closeDia">
<el-form ref="editForm" :model="editForm" :rules="editFormRules" label-width="120px" label-position="right">
<el-form-item label="鍦烘墍锛�" prop="laboratoryId">
<el-select v-model="editForm.laboratoryId" clearable placeholder="璇烽�夋嫨" size="small" style="width: 100%">
- <el-option v-for="item in laboratoryList" :key="item.value" :label="item.label" :value="item.value"></el-option>
+ <el-option v-for="item in laboratoryList" :key="item.value" :label="item.label"
+ :value="item.value"></el-option>
</el-select>
</el-form-item>
<el-form-item label="妫�楠屽璞★細" prop="specimenName">
@@ -15,11 +17,6 @@
</el-form-item>
<el-form-item label="瀵硅薄浠e彿锛�" prop="code">
<el-input v-model="editForm.code" clearable size="small"></el-input>
- </el-form-item>
- <el-form-item label="瀵硅薄绫诲瀷锛�" prop="objectType">
- <el-select v-model="editForm.objectType" clearable placeholder="璇烽�夋嫨" size="small" style="width: 100%">
- <el-option v-for="item in dict.type.object_type" :key="item.value" :label="item.label" :value="item.value"></el-option>
- </el-select>
</el-form-item>
</el-form>
<span slot="footer" class="dialog-footer">
@@ -32,8 +29,8 @@
<script>
-import {obtainItemParameterList} from "@/api/structural/laboratoryScope";
-import {addTestObject, upTestObject} from "@/api/structural/capability";
+import { obtainItemParameterList } from "@/api/structural/laboratoryScope";
+import { addTestObject, upTestObject } from "@/api/structural/capability";
export default {
name: "EditForm",
@@ -51,7 +48,6 @@
specimenName: '', // 妫�楠屽璞�
specimenNameEn: '', // 妫�楠屽璞N
code: '', // 瀵硅薄浠e彿
- objectType: '', // 瀵硅薄绫诲瀷
},
laboratoryList: [],
editFormRules: {
@@ -70,22 +66,22 @@
},
// 鏂规硶闆嗗悎
methods: {
- openDia (type, row) {
+ openDia(type, row) {
this.operationType = type
this.obtainItemParameterList()
this.editFormDia = true
if (type === 'add') {
this.resetForm("editForm");
} else {
- this.editForm = {...row}
+ this.editForm = { ...row }
}
},
// 鎻愪氦缂栬緫
- handleEdit () {
+ handleEdit() {
this.$refs.editForm.validate(valid => {
if (valid) {
this.editLoad = true
- if(this.editForm.id){
+ if (this.editForm.id) {
// 淇敼
upTestObject(this.editForm).then(res => {
this.editLoad = false
@@ -98,7 +94,7 @@
}).catch(e => {
this.editLoad = false
})
- }else{
+ } else {
// 鏂板
addTestObject(this.editForm).then(res => {
this.editLoad = false
@@ -116,7 +112,7 @@
})
},
// 鍏抽棴寮规
- closeDia () {
+ closeDia() {
this.editFormDia = false
this.resetForm("editForm");
},
@@ -137,6 +133,4 @@
}
</script>
-<style scoped>
-
-</style>
+<style scoped></style>
--
Gitblit v1.9.3