From ef9eb48046f8dfbb3c18b0f45befcbeddbdf6899 Mon Sep 17 00:00:00 2001
From: value <z1292839451@163.com>
Date: 星期三, 29 五月 2024 03:56:23 +0800
Subject: [PATCH] 光纤配置数据回显和保存
---
src/components/view/a7-standard-method.vue | 19 +++++++++++++++----
1 files changed, 15 insertions(+), 4 deletions(-)
diff --git a/src/components/view/a7-standard-method.vue b/src/components/view/a7-standard-method.vue
index b210005..83bfa02 100644
--- a/src/components/view/a7-standard-method.vue
+++ b/src/components/view/a7-standard-method.vue
@@ -42,6 +42,9 @@
<el-row class="title">
<el-col :span="12" style="padding-left: 20px;">鏍囧噯鏂规硶</el-col>
<el-col :span="12" style="text-align: right;">
+ <el-button size="medium" @click="$refs.ValueTable.openUpload()" v-if="inPower">
+ <i class="el-icon-upload2" style="color: #3A7BFA;"></i>
+ <span style="color: #3A7BFA;">瀵煎叆</span></el-button>
<el-button size="medium" type="primary" @click="openAdd" v-if="addPower">鏂板</el-button>
</el-col>
</el-row>
@@ -65,7 +68,7 @@
<div class="table">
<ValueTable ref="ValueTable" :url="$api.standardMethod.selectStandardMethodList"
:delUrl="$api.standardMethod.delStandardMethod" :upUrl="$api.standardMethod.upStandardMethod"
- :componentData="componentData" :key="upIndex" />
+ :componentData="componentData" :key="upIndex" :inputUrl="$api.standardMethod.importStandardDetails"/>
</div>
</div>
</template>
@@ -164,13 +167,16 @@
multiple: true
},
},
- requiredAdd: ['code', 'name', 'structureTestObjectId', 'isProduct', 'isUse', 'nameEn'],
- requiredUp: ['code', 'name', 'structureTestObjectId', 'isProduct', 'isUse', 'nameEn']
+ requiredAdd: ['code', 'name', 'isProduct', 'isUse', 'nameEn'],
+ requiredUp: ['code', 'name', 'isProduct', 'isUse', 'nameEn'],
+ accept:聽'.xlsx',
+ inputType:聽'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'
},
entityCopy: {},
upIndex: 0,
addDia: false,
- addPower: true
+ addPower: true,
+ inPower: true,
}
},
mounted() {
@@ -195,6 +201,7 @@
let up = false
let del = false
let add = false
+ let inPower = false
for (var i = 0; i < power.length; i++) {
if (power[i].menuMethod == 'addStandardMethod') {
add = true
@@ -205,6 +212,9 @@
if (power[i].menuMethod == 'upStandardMethod') {
up = true
}
+ if (power[i].menuMethod == 'importStandardDetails') {
+ inPower = true
+ }
}
if (!del) {
this.componentData.do.splice(1, 1)
@@ -213,6 +223,7 @@
this.componentData.do.splice(0, 1)
}
this.addPower = add
+ this.inPower = inPower
},
openAdd() {
this.$refs.ValueTable.openAddDia(this.$api.standardMethod.addStandardMethod);
--
Gitblit v1.9.3