From 0a26d58a3906b9e13946c7cb46fae51a0de98920 Mon Sep 17 00:00:00 2001 From: Crunchy <3114200645@qq.com> Date: 星期一, 17 三月 2025 15:49:08 +0800 Subject: [PATCH] Merge branch 'dev' into dev_tides --- src/views/CNAS/systemManagement/measuresDealRisks/components/listRiskAnalysisControlPlans.vue | 23 ++++++----------------- 1 files changed, 6 insertions(+), 17 deletions(-) diff --git a/src/views/CNAS/systemManagement/measuresDealRisks/components/listRiskAnalysisControlPlans.vue b/src/views/CNAS/systemManagement/measuresDealRisks/components/listRiskAnalysisControlPlans.vue index 57ed36d..2cbdc4a 100644 --- a/src/views/CNAS/systemManagement/measuresDealRisks/components/listRiskAnalysisControlPlans.vue +++ b/src/views/CNAS/systemManagement/measuresDealRisks/components/listRiskAnalysisControlPlans.vue @@ -6,14 +6,15 @@ <el-button type="primary" size="small" @click="addFun">鏂� 澧�</el-button> <el-button type="primary" size="small" @click="approvalFun">瀹� 鎵�</el-button> <el-button type="primary" size="small" @click="approveFun">鎵� 鍑�</el-button> - <el-upload style="display: inline-block; padding: 0 6px" :action="action" :headers="headers" :on-error="onError" - :show-file-list="false" :on-success="onSuccess"> + <el-upload style="display: inline-block; padding: 0 6px" :action="action" :headers="uploadHeader" + :on-error="onError" :show-file-list="false" :on-success="onSuccess"> <el-button size="small" type="primary">瀵� 鍏�</el-button> </el-upload> <el-button size="small" @click="openDownloadDia">瀵煎嚭</el-button> </div> </div> - <el-table :data="tableData" style="width: 100%" height="calc(100vh - 18em)"> + <el-table :data="tableData" style="width: 100%" height="calc(100vh - 18em)" key="table0" + :header-cell-style="{ background: '#f8f8f9', color: '#515a6e' }" border> <el-table-column type="index" label="搴忓彿" width="120"> <template v-slot="scope"> <span>{{ (search.current - 1) * search.size + scope.$index + 1 }}</span> @@ -49,7 +50,7 @@ </el-table-column> </el-table> <el-pagination :current-page="1" :page-size="search.size" :page-sizes="[10, 20, 30, 50, 100]" :total="search.total" - layout="->,total, sizes, prev, pager, next, jumper" @size-change="handleSizeChange" + layout="->,total, sizes, prev, pager, next, jumper" @size-change="handleSizeChange" background @current-change="handleCurrentChange"> </el-pagination> <el-dialog title="鎻愮ず" :visible.sync="dialogVisible" width="50%"> @@ -96,7 +97,6 @@ </template> <script> -import { getToken } from "@/utils/auth"; import { getPageList, riskAnalysisApprovalOfControlPlanChecklist, @@ -121,11 +121,6 @@ } }, computed: { - headers() { - return { - 'Authorization': "Bearer " + getToken() - } - }, action() { return this.javaApi + '/manageControlPlanList/importControlPlanList' }, @@ -142,7 +137,6 @@ }, initData() { getPageList(this.search).then(res => { - if (res.code === 201) return; this.tableData = res.data.records; this.search.total = res.data.total; }); @@ -172,7 +166,6 @@ // 瀹℃壒鎺ュ彛 approvalApi(userId, status) { riskAnalysisApprovalOfControlPlanChecklist({ approval: userId, status }).then(res => { - if (res.code === 201) return; this.initData() this.$message({ type: 'success', @@ -205,7 +198,6 @@ // 鎵瑰噯鎺ュ彛 approveApi(userId, status) { approvalOfControlPlanChecklist({ approve: userId, status }).then(res => { - if (res.code === 201) return; this.initData() this.$message({ type: 'success', @@ -220,7 +212,7 @@ }); }, onSuccess(response) { - if (response.code == 201) { + if (response.code != 200) { this.$message({ type: 'error', message: response.message, @@ -245,7 +237,6 @@ type: 'warning' }).then(() => { deleteSignificantRiskFactorAnalysis({ id: row.id }).then(res => { - if (res.code === 201) return; this.initData() this.$message({ type: 'success', @@ -262,7 +253,6 @@ addApi() { this.loading = true analysisOfMajorRiskFactorsAdded(this.form).then(res => { - if (res.code === 201) return; this.dialogVisible = false this.loading = false this.initData() @@ -283,7 +273,6 @@ openDownloadDia() { exportSignificantRiskFactors().then(res => { this.outLoading = false - this.$message.success('瀵煎嚭鎴愬姛') const blob = new Blob([res], { type: 'application/msword' }); this.$download.saveAs(blob, '閲嶅ぇ椋庨櫓鍥犵礌鍒嗘瀽鍙婃帶鍒惰鍒掓竻鍗�' + '.docx'); }) -- Gitblit v1.9.3