|
@@ -98,7 +98,7 @@
|
|
<el-button class="btns" link @click="viewDetails(scope.row.id,scope.row.name)"
|
|
<el-button class="btns" link @click="viewDetails(scope.row.id,scope.row.name)"
|
|
> {{ routeType === 'auto' ? '设备历史记录' : '设备历史建议' }}</el-button
|
|
> {{ routeType === 'auto' ? '设备历史记录' : '设备历史建议' }}</el-button
|
|
>
|
|
>
|
|
- <el-button class="btns" link @click="exportRecord(scope.row.name)"
|
|
|
|
|
|
+ <el-button class="btns" link @click="exportRecord(scope.row)"
|
|
>导出记录</el-button
|
|
>导出记录</el-button
|
|
>
|
|
>
|
|
<!-- <el-button class="btns-warn" link @click="delBefore(scope.row.id)"
|
|
<!-- <el-button class="btns-warn" link @click="delBefore(scope.row.id)"
|
|
@@ -168,9 +168,12 @@ const getHealthStatusClass = (sts: number) => {
|
|
return "info"; // 处理未知或未定义的状态
|
|
return "info"; // 处理未知或未定义的状态
|
|
}
|
|
}
|
|
};
|
|
};
|
|
-const exportRecord=(value:string)=>{
|
|
|
|
-
|
|
|
|
-downloadFile(downloadDeviceRepair(), "设备历史维修策略.xlsx", {name:value });
|
|
|
|
|
|
+const exportRecord=(value:any)=>{
|
|
|
|
+ if (routeType.value == 'auto') {
|
|
|
|
+ downloadFile('/maintenanceStrategy/autoDetection/exportFaultHistoryRecords', "设备历史维修策略 (自动).xlsx", {id: value.id});
|
|
|
|
+ } else {
|
|
|
|
+ downloadFile(downloadDeviceRepair(), "设备历史维修策略.xlsx", {name: value.name});
|
|
|
|
+ }
|
|
}
|
|
}
|
|
// 当前健康状态:1-良好;2-一般;3-较差;4-危险
|
|
// 当前健康状态:1-良好;2-一般;3-较差;4-危险
|
|
const getHealthStatusText = (status: number) => {
|
|
const getHealthStatusText = (status: number) => {
|