Commit e4860026 by yancanhua

fix: 自测问题调整

1 parent 80b850cd
......@@ -248,13 +248,28 @@ export default class DetectionInspectorPage extends PaginationComponent<Vehicle>
}
DetectionController.inspectExport(this.axios, paramsData, { responseType: 'blob' }).then(response => {
message.success('导出任务已创建,请稍后在浏览器下载列表中查看');
ExportUtil.downloadExcelFile(response.data, '检测师列表');
ExportUtil.downloadExcelFile(response.data, '检测师列表' + this.getNewTime());
}).catch(error => {
console.error('Error downloading Word file:', error);
}).finally(() => {
this.exporting = false;
});
}
getNewTime() {
//获取当前年月日时分秒
const date = new Date();
const year = date.getFullYear();
const month = date.getMonth() + 1;
const monthStr = month < 10 ? '0' + month : month;
const day = date.getDate();
const dayStr = day < 10 ? '0' + day : day;
const hour = date.getHours();
const minute = date.getMinutes();
const minuteStr = minute < 10 ? '0' + minute : minute;
return `${year}-${monthStr}-${dayStr}-${hour}-${minuteStr}`
}
}
</script>
......
......@@ -43,12 +43,14 @@
</template>
<template v-if="column.key === 'custodianName'">
<div class="templateName" :title="record.vehicle?.custodianInfo?.custodianName || '-'" >{{ record.vehicle?.custodianInfo?.custodianName || '-' }}</div>
<div class="templateName" :title="record.vehicle?.custodianInfo?.custodianName || '-'">{{
record.vehicle?.custodianInfo?.custodianName || '-' }}</div>
<div class="templatePhone">{{ record.vehicle?.custodianInfo?.custodianPhone || '-' }}</div>
</template>
<template v-if="column.key === 'name'">
<div class="templateName" :title="record.inspector?.name || '-'" >{{ record.inspector?.name || '-' }}</div>
<div class="templateName" :title="record.inspector?.name || '-'">{{ record.inspector?.name || '-' }}
</div>
<div class="templatePhone">{{ record.inspector?.phone || '-' }}</div>
</template>
......@@ -288,13 +290,28 @@ export default class DetectionOrderPage extends PaginationComponent<Vehicle> {
}
DetectionController.inspectOrderExport(this.axios, paramsData, { responseType: 'blob' }).then(response => {
message.success('导出任务已创建,请在下载中心查看');
ExportUtil.downloadExcelFile(response.data, '检测订单管理列表');
ExportUtil.downloadExcelFile(response.data, '检测订单管理列表' + this.getNewTime());
}).catch(error => {
console.error('Error downloading Word file:', error);
}).finally(() => {
this.exporting = false;
});
}
getNewTime() {
//获取当前年月日时分秒
const date = new Date();
const year = date.getFullYear();
const month = date.getMonth() + 1;
const monthStr = month < 10 ? '0' + month : month;
const day = date.getDate();
const dayStr = day < 10 ? '0' + day : day;
const hour = date.getHours();
const minute = date.getMinutes();
const minuteStr = minute < 10 ? '0' + minute : minute;
return `${year}-${monthStr}-${dayStr}-${hour}-${minuteStr}`
}
}
</script>
......
......@@ -23,7 +23,7 @@
<a-descriptions-item label="车源号">{{ vehicleData.sourceNo || '-' }}</a-descriptions-item>
<a-descriptions-item label="VIN码">{{ vehicleData.vin || '-' }}</a-descriptions-item>
<a-descriptions-item label="车牌号">{{ vehicleData.licensePlate || '-'
}}</a-descriptions-item>
}}</a-descriptions-item>
</a-descriptions>
</div>
</a-form-item>
......@@ -177,7 +177,14 @@ export default class OrderAddForm extends EnhanceFormComponent<User> {
//检测人员获取
getInspectPageList() {
DetectionController.inspectPage(this.axios, {}).then(response => {
const params = {
"offset": 0,
"limit": 1000,
"filters": [{ "field": "status", "operator": "eq", "value": "1", "logic": "and" }],
"sort": "createTime",
"order": "desc"
}
DetectionController.inspectPage(this.axios, params).then(response => {
this.inspectPageList = response?.data?.content || [];
})
}
......
......@@ -220,20 +220,33 @@ export default class DetectionReportPage extends PaginationComponent<Vehicle> {
this.exporting = true;
DetectionController.inspectReportExport(this.axios, this.pagination.requestParams, { responseType: 'blob' }).then(response => {
message.success('导出任务已创建,请稍后在浏览器下载列表中查看');
ExportUtil.downloadExcelFile(response.data, '检测报告管理列表');
ExportUtil.downloadExcelFile(response.data, '检测报告管理列表' + this.getNewTime());
}).catch(error => {
console.error('Error downloading Word file:', error);
}).finally(() => {
this.exporting = false;
});
}
getNewTime() {
//获取当前年月日时分秒
const date = new Date();
const year = date.getFullYear();
const month = date.getMonth() + 1;
const monthStr = month < 10 ? '0' + month : month;
const day = date.getDate();
const dayStr = day < 10 ? '0' + day : day;
const hour = date.getHours();
const minute = date.getMinutes();
const minuteStr = minute < 10 ? '0' + minute : minute;
return `${year}-${monthStr}-${dayStr}-${hour}-${minuteStr}`
}
}
</script>
<style scoped lang="less">
.carTypeNameBox {
width: 100%;
display: flex;
......
......@@ -252,22 +252,26 @@ export default class PreferencePage extends PaginationComponent<Deposit> {
}
PreferenceController.exportPreference(this.axios, paramsData, { responseType: 'blob' }).then(response => {
message.success('导出任务已创建,请在下载中心查看');
//获取当前年月日时分秒
const date = new Date();
const year = date.getFullYear();
const month = date.getMonth() + 1;
const monthStr = month < 10 ? '0' + month : month;
const day = date.getDate();
const dayStr = day < 10 ? '0' + day : day;
const hour = date.getHours();
const minute = date.getMinutes();
const minuteStr = minute < 10 ? '0' + minute : minute;
ExportUtil.downloadExcelFile(response.data, '收车偏好列表' + year + monthStr + dayStr + hour + minuteStr);
ExportUtil.downloadExcelFile(response.data, '收车偏好列表' + this.getNewTime());
}).catch(error => {
console.error('Error downloading Word file:', error);
}).finally(() => {
this.exporting = false;
});
}
getNewTime() {
//获取当前年月日时分秒
const date = new Date();
const year = date.getFullYear();
const month = date.getMonth() + 1;
const monthStr = month < 10 ? '0' + month : month;
const day = date.getDate();
const dayStr = day < 10 ? '0' + day : day;
const hour = date.getHours();
const minute = date.getMinutes();
const minuteStr = minute < 10 ? '0' + minute : minute;
return `${year}-${monthStr}-${dayStr}-${hour}-${minuteStr}`
}
onSelectChange(selectedRowKeys: number[], selectedRows: []): void {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!