From 7cf54012c46c54bd701310cc29caaa94676ea570 Mon Sep 17 00:00:00 2001
From: ludc
Date: 星期一, 18 三月 2024 23:04:51 +0800
Subject: [PATCH] 分类授权功能完善
---
Source/UBCS-WEB/src/components/BatchImport/index.vue | 62 +++++++++++++++++++------------
1 files changed, 38 insertions(+), 24 deletions(-)
diff --git a/Source/UBCS-WEB/src/components/BatchImport/index.vue b/Source/UBCS-WEB/src/components/BatchImport/index.vue
index 45efd2b..d9f082b 100644
--- a/Source/UBCS-WEB/src/components/BatchImport/index.vue
+++ b/Source/UBCS-WEB/src/components/BatchImport/index.vue
@@ -13,7 +13,7 @@
</li>
</ul>
<div
- v-show="currentTypeObj[type]['upParams'] === 'classifyAttr' && this.type !== 'bulkEdit'"
+ v-show="currentTypeObj[type]['upParams'] === 'classifyAttr' && this.type !== 'bulkEdit'&& this.type !== 'groupCode'"
class="radio_box"
>
<span>鍒嗙被鐨勮矾寰勪娇鐢ㄧ殑灞炴��:</span>
@@ -61,22 +61,27 @@
>
</el-upload>
<template #footer>
- <el-button
- v-if="type !== 'bulkEdit'"
- :loading="downloadLoading"
- size="small"
- type="primary"
- @click="downloadTemplateFun"
- >涓嬭浇瀵煎叆妯℃澘
- </el-button>
- <el-button v-if="type === 'bulkEdit'"
- :loading="downloadLoading"
- size="small"
- type="primary"
- @click="downloadTemplateFun"
- >涓嬭浇缂栬緫妯℃澘
- </el-button>
- <el-button size="small" @click="dialogVisible = false">鍏抽棴</el-button>
+ <div style="display: inline-block" v-if="type != 'groupCode'">
+ <el-button
+ v-if="type !== 'bulkEdit' "
+ :loading="downloadLoading"
+ size="small"
+ type="primary"
+ @click="downloadTemplateFun"
+ >涓嬭浇瀵煎叆妯℃澘
+ </el-button>
+ <el-button v-if="type === 'bulkEdit'"
+ :loading="downloadLoading"
+ size="small"
+ type="primary"
+ @click="downloadTemplateFun"
+ >涓嬭浇缂栬緫妯℃澘
+ </el-button>
+ </div>
+ <div style="display: inline-block">
+ <el-button size="small" @click="dialogVisible = false">鍏抽棴</el-button>
+ </div>
+
</template>
<ShowImportData
v-if="showVisible"
@@ -189,6 +194,10 @@
return {
codeClassifyOid: this.codeClassifyOid,
};
+ } else if (this.type === 'groupCode') {
+ return {
+ codeClassifyOid: this.codeClassifyOid,
+ };
}
},
},
@@ -248,6 +257,17 @@
downloadTemplateFun: downloadBatchApplyCodeTemplate,
upParams: "classifyAttr",
},
+ groupCode: {
+ title: "闆嗗洟鐮佸鍏�",
+ tipList: [
+ "1.鏍囬甯︿簲瑙掓槦鐨勮〃绀哄叧閿睘鎬э紝甯︽槦鍙疯〃绀哄繀杈撻」",
+ "2.姣忔浠呰兘鏈�澶氬鍏�5000鏉℃暟鎹�(鍙�氳繃nacos杩涜閰嶇疆锛屾帹鑽�5000/娆″鍏�)锛屽鏋滃嚭閿欎細杩斿洖閿欒鐨勬暟鎹拰鍘熷洜锛屼絾鏄纭暟鎹彲浠ョ户缁繚瀛�",
+ "3.Excel绗竴琛屽拰绗簩琛屼緷娆′负浼佷笟缂栫爜鍜岄泦鍥㈢紪鐮侊紙蹇呭~锛�"
+ ],
+ action: "/api/ubcs-code/mdmEngineController/importGroupCode",
+ downloadTemplateFun: null,
+ upParams: "classifyAttr",
+ }
},
secDTOList: [],
};
@@ -291,16 +311,9 @@
return;
}
if (this.type === 'bulkEdit') {
- this.tableHeadFindData.map(item => item.prop)
- .forEach((prop, index) => {
- this.exportArrTwo[`attrIdIndexMap[${index}]`] = prop;
- });
downloadExcelBatchEdit({
codeClassifyOid: this.codeClassifyOid,
- 'conditionMap[oid]': this.ids, ...this.exportArrTwo,
- limit: -1
}).then(res => {
- // console.log('res',res)
if (res) {
func.downloadFileByBlobHandler(res);
this.$message.success('涓嬭浇鎴愬姛锛岃鏌ョ湅锛�')
@@ -310,6 +323,7 @@
}
},
onSuccess(res) {
+ console.log(res)
if (Object.keys(res.data).length === 0) {
this.$message.success(this.title + "瀵煎叆鎴愬姛锛�");
this.resetTable()
--
Gitblit v1.9.3