From 60322c503d201e4d1000e62d8ecf17db4f628e4c Mon Sep 17 00:00:00 2001
From: spring <2396852758@qq.com>
Date: 星期三, 12 三月 2025 15:49:23 +0800
Subject: [PATCH] 合并冲突
---
src/views/CNAS/resourceDemand/device/component/check-and-accept.vue | 35 ++++++++++++++++++++---------------
1 files changed, 20 insertions(+), 15 deletions(-)
diff --git a/src/views/CNAS/resourceDemand/device/component/check-and-accept.vue b/src/views/CNAS/resourceDemand/device/component/check-and-accept.vue
index e940152..26680b7 100644
--- a/src/views/CNAS/resourceDemand/device/component/check-and-accept.vue
+++ b/src/views/CNAS/resourceDemand/device/component/check-and-accept.vue
@@ -17,7 +17,7 @@
</div>
</div>
<div class="tables" style="margin-top: 10px;">
- <el-table ref="table" :data="tableDataAlist" height="100%">
+ <el-table ref="table" :data="tableDataAlist" height="100%" v-loading="tableLoading">
<el-table-column label="搴忓彿" type="index" width="60">
<template v-slot="scope">
<span>{{ (search.current - 1) * search.size + scope.$index + 1 }}</span>
@@ -468,12 +468,13 @@
import { dateFormat } from '@/utils/date'
import file from "@/utils/file";
import {
- deleteCNASFile,
+ deleteCNASFile, deleteIncidentReport,
deleteIncidentReportAll, getShowIncidentReport, incidentReportExport, incidentReportPage,
saveIncidentReportData,
selectDeviceByCode
} from "@/api/cnas/resourceDemand/device";
import {selectUserCondition} from "@/api/system/user";
+import {mapGetters} from "vuex";
export default {
props: {
@@ -488,6 +489,7 @@
return {
//浜嬫晠璁惧淇℃伅
tableDataAlist: [], // 鏇存敼鍙橀噺鍚嶇О
+ tableLoading: false,
dialogVisible: false,
rules: {
quantity: [{ required: true, message: '璇疯緭鍏ユ暟閲�', trigger: 'blur' }],
@@ -517,7 +519,8 @@
computed: {
action() {
return this.javaApi + '/personBasicInfo/saveCNASFile'
- }
+ },
+ ...mapGetters(["nickName"]),
},
mounted() {
// 鑾峰彇璁惧浜嬫晠淇℃伅
@@ -661,32 +664,31 @@
this.$refs.form.validate((valid) => {
if (valid === true || saveState !== '1submit') {
// 缁欏綋鍓嶇幆鑺傝缃垱寤轰汉涓庢椂闂�
- let user = JSON.parse(localStorage.getItem('user'))
const dateTime = dateFormat(new Date())
// 鑾峰彇褰撳墠鐜妭鎿嶄綔浜轰笌鏃ユ湡
switch (this.currentStep) {
case 0:
- this.form.submitOperatingPersonnel = user.name
+ this.form.submitOperatingPersonnel = this.nickName
this.form.submitDate = dateTime
break
case 1:
- this.form.unpackingOperatingPersonnel = user.name
+ this.form.unpackingOperatingPersonnel = this.nickName
this.form.unpackingDate = dateTime
break
case 2:
- this.form.installOperatingPersonnel = user.name
+ this.form.installOperatingPersonnel = this.nickName
this.form.installDate = dateTime
break
case 3:
- this.form.installationAcceptanceOperatingPersonnel = user.name
+ this.form.installationAcceptanceOperatingPersonnel = this.nickName
this.form.installationAcceptanceDate = dateTime
break
case 4:
- this.form.acceptanceCheckOperatingPersonnel = user.name
+ this.form.acceptanceCheckOperatingPersonnel = this.nickName
this.form.acceptanceCheckDate = dateTime
break
case 5:
- this.form.acceptanceAuditOperatingPersonnel = user.name
+ this.form.acceptanceAuditOperatingPersonnel = this.nickName
this.form.acceptanceAuditDate = dateTime
break
default:
@@ -765,19 +767,21 @@
},
// 鑾峰彇璁惧浜嬫晠淇℃伅(鏍规嵁浠巚uex涓幏鍙栧埌鐨勮澶囧悕绉癷d杩涜鏁版嵁鏌ヨ)
getDeviceAList(deviceId) {
+ this.tableLoading = true
incidentReportPage({deviceId: deviceId, size:this.search.size, current:this.search.current, processNumber: this.search.processNumber}).then(res => {
+ this.tableLoading = false
if (res.code == 200) {
this.tableDataAlist = res.data.records
this.search.total = res.data.total
}
+ }).catch(err => {
+ this.tableLoading = false
})
},
//table 浜嬩欢澶勭悊寮�濮嬪
+ // 涓嬭浇闄勪欢
handleAttachmentClick(row) {
- // 妯℃嫙涓嬭浇闄勪欢
- const imageUrl = this.javaApi+'/img/'+row.systemFileName; // 鍥剧墖 URL
- // downloadImage(imageUrl);
- file.downloadIamge(imageUrl,row.fileName)
+ this.$download.saveAs(row.systemFileName, row.fileName)
},
handleViewClick(row) {
getShowIncidentReport({id: row.id}).then(res => {
@@ -797,7 +801,7 @@
cancelButtonText: '鍙栨秷',
type: 'warning'
}).then(() => {
- deleteIncidentReportAll({id: row.id}).then(res => {
+ deleteIncidentReport({id: row.id}).then(res => {
if (res.code == 200) {
this.$message.success('鍒犻櫎鎴愬姛')
this.getDeviceAList(this.clickNodeVal.value);
@@ -870,6 +874,7 @@
}
.search {
+ margin-top: 10px;
background-color: #fff;
height: 40px;
display: flex;
--
Gitblit v1.9.3