forked from integrated_whb/integrated_whb_vue
bug优化
parent
cf7e5686e4
commit
301b97d4f4
|
@ -125,6 +125,11 @@
|
||||||
</template>
|
</template>
|
||||||
</layout-table>
|
</layout-table>
|
||||||
</layout-card>
|
</layout-card>
|
||||||
|
<layout-import-file
|
||||||
|
v-model:visible="data.importDialogVisible"
|
||||||
|
template-url="/template/truckExcelTemplate.xls"
|
||||||
|
@submit="fnSubmitImport"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
@ -139,7 +144,13 @@ import {
|
||||||
} from "@/request/enterprise_management.js";
|
} from "@/request/enterprise_management.js";
|
||||||
import { debounce } from "throttle-debounce";
|
import { debounce } from "throttle-debounce";
|
||||||
import { ElMessageBox, ElMessage } from "element-plus";
|
import { ElMessageBox, ElMessage } from "element-plus";
|
||||||
|
import { setRiskPointImport } from "@/request/risk_control.js";
|
||||||
|
import LayoutImportFile from "@/components/import_file/index.vue";
|
||||||
|
import { reactive } from "vue";
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
|
const data = reactive({
|
||||||
|
importDialogVisible: false,
|
||||||
|
});
|
||||||
const { list, pagination, searchForm, fnGetData, fnResetPagination, tableRef } =
|
const { list, pagination, searchForm, fnGetData, fnResetPagination, tableRef } =
|
||||||
useListData(getFreightTrailerList);
|
useListData(getFreightTrailerList);
|
||||||
const fnGetDataTransfer = () => {
|
const fnGetDataTransfer = () => {
|
||||||
|
@ -158,6 +169,21 @@ const fnResetPaginationTransfer = () => {
|
||||||
DEPARTMENT_NAME: searchForm.value.DEPARTMENT_NAME,
|
DEPARTMENT_NAME: searchForm.value.DEPARTMENT_NAME,
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
const fnImportDialogChangeShow = () => {
|
||||||
|
data.importDialogVisible = !data.importDialogVisible;
|
||||||
|
};
|
||||||
|
const fnSubmitImport = async (formData) => {
|
||||||
|
const resData = await setRiskPointImport(formData);
|
||||||
|
if (resData.resultStr) {
|
||||||
|
ElMessage({
|
||||||
|
dangerouslyUseHTMLString: true,
|
||||||
|
message: resData.resultStr,
|
||||||
|
type: resData.resultType,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
fnImportDialogChangeShow();
|
||||||
|
fnResetPaginationTransfer();
|
||||||
|
};
|
||||||
const fnExport = async () => {
|
const fnExport = async () => {
|
||||||
const selectionData = tableRef.value.getSelectionRows();
|
const selectionData = tableRef.value.getSelectionRows();
|
||||||
if (selectionData.length === 0) {
|
if (selectionData.length === 0) {
|
||||||
|
@ -165,7 +191,9 @@ const fnExport = async () => {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
await ElMessageBox.confirm("确定要导出到excel吗?", { type: "warning" });
|
await ElMessageBox.confirm("确定要导出到excel吗?", { type: "warning" });
|
||||||
const DATA_IDS = selectionData.map((item) => item.RISKUNIT_ID).join(",");
|
const DATA_IDS = selectionData
|
||||||
|
.map((item) => item.FREIGHTTRAILER_ID)
|
||||||
|
.join(",");
|
||||||
window.location.href =
|
window.location.href =
|
||||||
import.meta.env[import.meta.env.DEV ? "VITE_PROXY" : "VITE_BASE_URL"] +
|
import.meta.env[import.meta.env.DEV ? "VITE_PROXY" : "VITE_BASE_URL"] +
|
||||||
"/freightTrailer/excel?" +
|
"/freightTrailer/excel?" +
|
||||||
|
|
|
@ -33,13 +33,9 @@
|
||||||
<el-descriptions-item label-class-name="width_200" label="车主电话">
|
<el-descriptions-item label-class-name="width_200" label="车主电话">
|
||||||
{{ info.CAR_OWNERS_TEL }}
|
{{ info.CAR_OWNERS_TEL }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
|
|
||||||
<el-descriptions-item label-class-name="width_200" label="联系人">
|
<el-descriptions-item label-class-name="width_200" label="联系人">
|
||||||
{{ info.CONTACTS }}
|
{{ info.CONTACTS }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
<!-- <el-descriptions-item label-class-name="width_200" label="车主电话">-->
|
|
||||||
<!-- {{ info.CAR_OWNERS_TEL }}-->
|
|
||||||
<!-- </el-descriptions-item>-->
|
|
||||||
<el-descriptions-item label-class-name="width_200" label="联系电话">
|
<el-descriptions-item label-class-name="width_200" label="联系电话">
|
||||||
{{ info.CONTACT_PHONE }}
|
{{ info.CONTACT_PHONE }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
|
|
|
@ -148,12 +148,6 @@
|
||||||
width="140"
|
width="140"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
|
||||||
prop="OPERATTIME"
|
|
||||||
label="修改时间"
|
|
||||||
width="140"
|
|
||||||
show-overflow-tooltip
|
|
||||||
/>
|
|
||||||
<el-table-column label="操作" width="150">
|
<el-table-column label="操作" width="150">
|
||||||
<template #default="{ row }">
|
<template #default="{ row }">
|
||||||
<el-button
|
<el-button
|
||||||
|
|
|
@ -295,11 +295,21 @@ const rules = {
|
||||||
};
|
};
|
||||||
const getRemiderDate = (val) => {
|
const getRemiderDate = (val) => {
|
||||||
if (val) {
|
if (val) {
|
||||||
if (form.value.DUE_DATE && form.value.REMINDER_DAYS) {
|
if (form.value.DUE_DATE) {
|
||||||
form.value.REMINDER_DATE = subtractDaysFromDate(
|
// 计算提醒日期
|
||||||
form.value.DUE_DATE,
|
const reminderDateStr = subtractDaysFromDate(form.value.DUE_DATE, val);
|
||||||
form.value.REMINDER_DAYS
|
const reminderDate = new Date(reminderDateStr);
|
||||||
);
|
const today = new Date();
|
||||||
|
|
||||||
|
// 检查计算出的提醒日期是否早于当前时间
|
||||||
|
if (reminderDate < today) {
|
||||||
|
// 如果提醒日期早于当前日期,显示错误提示并重置提醒日期
|
||||||
|
ElMessage.error("输入的提醒天数错误,提醒日期不能早于当前日期。");
|
||||||
|
form.value.REMINDER_DATE = ""; // 重置提醒日期
|
||||||
|
} else {
|
||||||
|
// 如果提醒日期正常,更新表单值
|
||||||
|
form.value.REMINDER_DATE = reminderDateStr;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
form.value.REMINDER_DATE = "";
|
form.value.REMINDER_DATE = "";
|
||||||
|
|
|
@ -112,7 +112,13 @@
|
||||||
<el-tag v-else-if="row.DUE_DATE_TYPE === 2">即将到期</el-tag>
|
<el-tag v-else-if="row.DUE_DATE_TYPE === 2">即将到期</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="ARCHIVES_TYPE" label="档案状态" width="150" />
|
<el-table-column prop="NEW_ARCHIVES_TYPE" label="车辆状态" width="150">
|
||||||
|
<template #default="{ row }">
|
||||||
|
<el-tag v-if="row.NEW_ARCHIVES_TYPE === '1'">报废</el-tag>
|
||||||
|
<el-tag v-else-if="row.NEW_ARCHIVES_TYPE === '0'">正常</el-tag>
|
||||||
|
<el-tag v-else-if="row.NEW_ARCHIVES_TYPE === '2'">过户</el-tag>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column prop="CREATTIME" label="创建时间" width="150" />
|
<el-table-column prop="CREATTIME" label="创建时间" width="150" />
|
||||||
<el-table-column prop="OPERATTIME" label="修改时间" width="150" />
|
<el-table-column prop="OPERATTIME" label="修改时间" width="150" />
|
||||||
<el-table-column label="操作" width="250">
|
<el-table-column label="操作" width="250">
|
||||||
|
|
|
@ -17,12 +17,6 @@
|
||||||
<el-descriptions-item label-class-name="width_200" label="车辆类型">
|
<el-descriptions-item label-class-name="width_200" label="车辆类型">
|
||||||
{{ data.busInfo.TRAILER_TYPE }}
|
{{ data.busInfo.TRAILER_TYPE }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
<el-descriptions-item label-class-name="width_200" label="车辆型号">
|
|
||||||
{{ data.busInfo.VEHICLE_MODEL }}
|
|
||||||
</el-descriptions-item>
|
|
||||||
<el-descriptions-item label-class-name="width_200" label="车辆品牌">
|
|
||||||
{{ data.busInfo.VEHICLE_BRAND }}
|
|
||||||
</el-descriptions-item>
|
|
||||||
<el-descriptions-item label-class-name="width_200" label="车主业户">
|
<el-descriptions-item label-class-name="width_200" label="车主业户">
|
||||||
{{ data.busInfo.CAR_OWNERS }}
|
{{ data.busInfo.CAR_OWNERS }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
|
|
|
@ -344,12 +344,26 @@ const getDueDate = () => {
|
||||||
const getRemiderDate = (val) => {
|
const getRemiderDate = (val) => {
|
||||||
if (val) {
|
if (val) {
|
||||||
if (form.value.DUE_DATE) {
|
if (form.value.DUE_DATE) {
|
||||||
form.value.REMINDER_DATE = subtractDaysFromDate(form.value.DUE_DATE, val);
|
// 计算提醒日期
|
||||||
|
const reminderDateStr = subtractDaysFromDate(form.value.DUE_DATE, val);
|
||||||
|
const reminderDate = new Date(reminderDateStr);
|
||||||
|
const today = new Date();
|
||||||
|
|
||||||
|
// 检查计算出的提醒日期是否早于当前时间
|
||||||
|
if (reminderDate < today) {
|
||||||
|
// 如果提醒日期早于当前日期,显示错误提示并重置提醒日期
|
||||||
|
ElMessage.error("输入的提醒天数错误,提醒日期不能早于当前日期。");
|
||||||
|
form.value.REMINDER_DATE = ""; // 重置提醒日期
|
||||||
|
} else {
|
||||||
|
// 如果提醒日期正常,更新表单值
|
||||||
|
form.value.REMINDER_DATE = reminderDateStr;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
form.value.REMINDER_DATE = "";
|
form.value.REMINDER_DATE = "";
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
const getVehicle = async (event) => {
|
const getVehicle = async (event) => {
|
||||||
const resData = await getTrailerList({ TRAFFIC_TYPE: event });
|
const resData = await getTrailerList({ TRAFFIC_TYPE: event });
|
||||||
data.vehicleList = resData.list;
|
data.vehicleList = resData.list;
|
||||||
|
|
|
@ -401,7 +401,20 @@ const getDueDate = (val) => {
|
||||||
const getRemiderDate = (val) => {
|
const getRemiderDate = (val) => {
|
||||||
if (val) {
|
if (val) {
|
||||||
if (form.value.DUE_DATE) {
|
if (form.value.DUE_DATE) {
|
||||||
form.value.REMINDER_DATE = subtractDaysFromDate(form.value.DUE_DATE, val);
|
// 计算提醒日期
|
||||||
|
const reminderDateStr = subtractDaysFromDate(form.value.DUE_DATE, val);
|
||||||
|
const reminderDate = new Date(reminderDateStr);
|
||||||
|
const today = new Date();
|
||||||
|
|
||||||
|
// 检查计算出的提醒日期是否早于当前时间
|
||||||
|
if (reminderDate < today) {
|
||||||
|
// 如果提醒日期早于当前日期,显示错误提示并重置提醒日期
|
||||||
|
ElMessage.error("输入的提醒天数错误,提醒日期不能早于当前日期。");
|
||||||
|
form.value.REMINDER_DATE = ""; // 重置提醒日期
|
||||||
|
} else {
|
||||||
|
// 如果提醒日期正常,更新表单值
|
||||||
|
form.value.REMINDER_DATE = reminderDateStr;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
form.value.REMINDER_DATE = "";
|
form.value.REMINDER_DATE = "";
|
||||||
|
|
|
@ -116,7 +116,7 @@
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="12">
|
||||||
<el-form-item label="维保周期" prop="MAINTENANCE_CYCLE">
|
<el-form-item label="维保周期(天)" prop="MAINTENANCE_CYCLE">
|
||||||
<el-input
|
<el-input
|
||||||
v-model.number="form.MAINTENANCE_CYCLE"
|
v-model.number="form.MAINTENANCE_CYCLE"
|
||||||
type="number"
|
type="number"
|
||||||
|
@ -330,12 +330,26 @@ const getDueDate = () => {
|
||||||
const getRemiderDate = (val) => {
|
const getRemiderDate = (val) => {
|
||||||
if (val) {
|
if (val) {
|
||||||
if (form.value.DUE_DATE) {
|
if (form.value.DUE_DATE) {
|
||||||
form.value.REMINDER_DATE = subtractDaysFromDate(form.value.DUE_DATE, val);
|
// 计算提醒日期
|
||||||
|
const reminderDateStr = subtractDaysFromDate(form.value.DUE_DATE, val);
|
||||||
|
const reminderDate = new Date(reminderDateStr);
|
||||||
|
const today = new Date();
|
||||||
|
|
||||||
|
// 检查计算出的提醒日期是否早于当前时间
|
||||||
|
if (reminderDate < today) {
|
||||||
|
// 如果提醒日期早于当前日期,显示错误提示并重置提醒日期
|
||||||
|
ElMessage.error("输入的提醒天数错误,提醒日期不能早于当前日期。");
|
||||||
|
form.value.REMINDER_DATE = ""; // 重置提醒日期
|
||||||
|
} else {
|
||||||
|
// 如果提醒日期正常,更新表单值
|
||||||
|
form.value.REMINDER_DATE = reminderDateStr;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
form.value.REMINDER_DATE = "";
|
form.value.REMINDER_DATE = "";
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
const getVehicle = async (event) => {
|
const getVehicle = async (event) => {
|
||||||
const resData = await getTrailerList({ TRAFFIC_TYPE: event });
|
const resData = await getTrailerList({ TRAFFIC_TYPE: event });
|
||||||
data.vehicleList = resData.list;
|
data.vehicleList = resData.list;
|
||||||
|
|
|
@ -98,11 +98,11 @@
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="PROCESSING_DATE" label="办理日期" width="150" />
|
<el-table-column prop="PROCESSING_DATE" label="办理日期" width="150" />
|
||||||
<el-table-column
|
<el-table-column prop="MAINTENANCE_CYCLE" label="维保周期" width="150">
|
||||||
prop="MAINTENANCE_CYCLE"
|
<template #default="{ row }">
|
||||||
label="维保周期"
|
{{ row.MAINTENANCE_CYCLE + "天" }}
|
||||||
width="150"
|
</template>
|
||||||
/>
|
</el-table-column>
|
||||||
<el-table-column prop="DUE_DATE" label="到期日期" width="150" />
|
<el-table-column prop="DUE_DATE" label="到期日期" width="150" />
|
||||||
<el-table-column prop="REGISTRANT" label="登记人" width="150" />
|
<el-table-column prop="REGISTRANT" label="登记人" width="150" />
|
||||||
<!--<el-table-column prop="CONTACTS" label="经营企业" width="150"/>-->
|
<!--<el-table-column prop="CONTACTS" label="经营企业" width="150"/>-->
|
||||||
|
@ -119,7 +119,13 @@
|
||||||
<el-tag v-else-if="row.DUE_DATE_TYPE === 2">即将到期</el-tag>
|
<el-tag v-else-if="row.DUE_DATE_TYPE === 2">即将到期</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="ARCHIVES_TYPE" label="档案状态" width="150" />
|
<el-table-column prop="NEW_ARCHIVES_TYPE" label="车辆状态" width="150">
|
||||||
|
<template #default="{ row }">
|
||||||
|
<el-tag v-if="row.NEW_ARCHIVES_TYPE === '1'">报废</el-tag>
|
||||||
|
<el-tag v-else-if="row.NEW_ARCHIVES_TYPE === '0'">正常</el-tag>
|
||||||
|
<el-tag v-else-if="row.NEW_ARCHIVES_TYPE === '2'">过户</el-tag>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column prop="CREATTIME" label="创建时间" width="150" />
|
<el-table-column prop="CREATTIME" label="创建时间" width="150" />
|
||||||
<el-table-column prop="OPERATTIME" label="修改时间" width="150" />
|
<el-table-column prop="OPERATTIME" label="修改时间" width="150" />
|
||||||
<el-table-column label="操作" width="250">
|
<el-table-column label="操作" width="250">
|
||||||
|
|
|
@ -17,12 +17,12 @@
|
||||||
<el-descriptions-item label-class-name="width_200" label="车辆类型">
|
<el-descriptions-item label-class-name="width_200" label="车辆类型">
|
||||||
{{ data.busInfo.TRAILER_TYPE }}
|
{{ data.busInfo.TRAILER_TYPE }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
<el-descriptions-item label-class-name="width_200" label="车辆型号">
|
<!-- <el-descriptions-item label-class-name="width_200" label="车辆型号">-->
|
||||||
{{ data.busInfo.VEHICLE_MODEL }}
|
<!-- {{ data.busInfo.VEHICLE_MODEL }}-->
|
||||||
</el-descriptions-item>
|
<!-- </el-descriptions-item>-->
|
||||||
<el-descriptions-item label-class-name="width_200" label="车辆品牌">
|
<!-- <el-descriptions-item label-class-name="width_200" label="车辆品牌">-->
|
||||||
{{ data.busInfo.VEHICLE_BRAND }}
|
<!-- {{ data.busInfo.VEHICLE_BRAND }}-->
|
||||||
</el-descriptions-item>
|
<!-- </el-descriptions-item>-->
|
||||||
<el-descriptions-item label-class-name="width_200" label="车主业户">
|
<el-descriptions-item label-class-name="width_200" label="车主业户">
|
||||||
{{ data.busInfo.CAR_OWNERS }}
|
{{ data.busInfo.CAR_OWNERS }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
|
@ -53,7 +53,7 @@
|
||||||
{{ info.KILOMETERS }}
|
{{ info.KILOMETERS }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
<el-descriptions-item label-class-name="width_200" label="维保周期">
|
<el-descriptions-item label-class-name="width_200" label="维保周期">
|
||||||
{{ info.MAINTENANCE_CYCLE }}
|
{{ info.MAINTENANCE_CYCLE + "天" }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
<el-descriptions-item label-class-name="width_200" label="办理日期">
|
<el-descriptions-item label-class-name="width_200" label="办理日期">
|
||||||
{{ info.PROCESSING_DATE }}
|
{{ info.PROCESSING_DATE }}
|
||||||
|
|
|
@ -311,7 +311,15 @@ const getDueDate = () => {
|
||||||
const getRemiderDate = (val) => {
|
const getRemiderDate = (val) => {
|
||||||
if (val) {
|
if (val) {
|
||||||
if (form.value.DUE_DATE) {
|
if (form.value.DUE_DATE) {
|
||||||
form.value.REMINDER_DATE = subtractDaysFromDate(form.value.DUE_DATE, val);
|
const reminderDateStr = subtractDaysFromDate(form.value.DUE_DATE, val);
|
||||||
|
const reminderDate = new Date(reminderDateStr);
|
||||||
|
const today = new Date();
|
||||||
|
if (reminderDate < today) {
|
||||||
|
ElMessage.error("输入的提醒天数错误,提醒日期不能早于当前日期。");
|
||||||
|
form.value.REMINDER_DAYS = "";
|
||||||
|
} else {
|
||||||
|
form.value.REMINDER_DATE = reminderDateStr;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
form.value.REMINDER_DATE = "";
|
form.value.REMINDER_DATE = "";
|
||||||
|
|
|
@ -98,7 +98,7 @@
|
||||||
{{ serialNumber(pagination, $index) }}
|
{{ serialNumber(pagination, $index) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="OPERATIONS_ID" label="编号" width="150" />
|
<!-- <el-table-column prop="OPERATIONS_ID" label="编号" width="150" />-->
|
||||||
<el-table-column prop="VEHICLE_MODEL" label="运营车型" width="150">
|
<el-table-column prop="VEHICLE_MODEL" label="运营车型" width="150">
|
||||||
<template #default="{ row }">
|
<template #default="{ row }">
|
||||||
{{
|
{{
|
||||||
|
@ -133,7 +133,13 @@
|
||||||
<span v-else-if="row.DUE_DATE_TYPE === 2">即将到期</span>
|
<span v-else-if="row.DUE_DATE_TYPE === 2">即将到期</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="ARCHIVES_TYPE" label="档案状态" width="150" />
|
<el-table-column prop="NEW_ARCHIVES_TYPE" label="车辆状态" width="150">
|
||||||
|
<template #default="{ row }">
|
||||||
|
<el-tag v-if="row.NEW_ARCHIVES_TYPE === '1'">报废</el-tag>
|
||||||
|
<el-tag v-else-if="row.NEW_ARCHIVES_TYPE === '0'">正常</el-tag>
|
||||||
|
<el-tag v-else-if="row.NEW_ARCHIVES_TYPE === '2'">过户</el-tag>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column prop="CREATTIME" label="创建时间" width="150" />
|
<el-table-column prop="CREATTIME" label="创建时间" width="150" />
|
||||||
<el-table-column prop="OPERATTIME" label="修改时间" width="150" />
|
<el-table-column prop="OPERATTIME" label="修改时间" width="150" />
|
||||||
<el-table-column label="操作" width="250">
|
<el-table-column label="操作" width="250">
|
||||||
|
|
|
@ -17,12 +17,12 @@
|
||||||
<el-descriptions-item label-class-name="width_200" label="车辆类型">
|
<el-descriptions-item label-class-name="width_200" label="车辆类型">
|
||||||
{{ data.busInfo.TRAILER_TYPE }}
|
{{ data.busInfo.TRAILER_TYPE }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
<el-descriptions-item label-class-name="width_200" label="车辆型号">
|
<!-- <el-descriptions-item label-class-name="width_200" label="车辆型号">-->
|
||||||
{{ data.busInfo.VEHICLE_MODEL }}
|
<!-- {{ data.busInfo.VEHICLE_MODEL }}-->
|
||||||
</el-descriptions-item>
|
<!-- </el-descriptions-item>-->
|
||||||
<el-descriptions-item label-class-name="width_200" label="车辆品牌">
|
<!-- <el-descriptions-item label-class-name="width_200" label="车辆品牌">-->
|
||||||
{{ data.busInfo.VEHICLE_BRAND }}
|
<!-- {{ data.busInfo.VEHICLE_BRAND }}-->
|
||||||
</el-descriptions-item>
|
<!-- </el-descriptions-item>-->
|
||||||
<el-descriptions-item label-class-name="width_200" label="车主业户">
|
<el-descriptions-item label-class-name="width_200" label="车主业户">
|
||||||
{{ data.busInfo.CAR_OWNERS }}
|
{{ data.busInfo.CAR_OWNERS }}
|
||||||
</el-descriptions-item>
|
</el-descriptions-item>
|
||||||
|
|
|
@ -402,7 +402,7 @@
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import { getUserListAll } from "@/request/safety_production_related.js";
|
import { getUserListAll } from "@/request/safety_production_related.js";
|
||||||
import { onMounted, reactive, ref, toRaw } from "vue";
|
import { reactive, ref, toRaw } from "vue";
|
||||||
import { ACCIDENTNATUREMENU, EDUCATIONALMENU } from "@/assets/js/constant.js";
|
import { ACCIDENTNATUREMENU, EDUCATIONALMENU } from "@/assets/js/constant.js";
|
||||||
import LayoutUpload from "@/components/upload/index.vue";
|
import LayoutUpload from "@/components/upload/index.vue";
|
||||||
import useFormValidate from "@/assets/js/useFormValidate.js";
|
import useFormValidate from "@/assets/js/useFormValidate.js";
|
||||||
|
@ -411,6 +411,7 @@ import { useRouter, useRoute } from "vue-router";
|
||||||
import {
|
import {
|
||||||
addAccidentInvestigationView,
|
addAccidentInvestigationView,
|
||||||
editAccidentInvestigation,
|
editAccidentInvestigation,
|
||||||
|
infoAccidentInvestigation,
|
||||||
} from "@/request/production_accident.js";
|
} from "@/request/production_accident.js";
|
||||||
|
|
||||||
// 获取路由实例
|
// 获取路由实例
|
||||||
|
@ -510,17 +511,6 @@ const rules = reactive({
|
||||||
],
|
],
|
||||||
});
|
});
|
||||||
|
|
||||||
onMounted(() => {
|
|
||||||
isEditMode.value = route.query.mode === "edit";
|
|
||||||
ACCIDENTINVESTIGATION_ID.value = route.query.ACCIDENTINVESTIGATION_ID || "";
|
|
||||||
|
|
||||||
if (isEditMode.value) {
|
|
||||||
Object.keys(rules).forEach((key) => {
|
|
||||||
rules[key] = []; // 清空每项校验规则
|
|
||||||
});
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
const fnGetUnitsList = async () => {
|
const fnGetUnitsList = async () => {
|
||||||
const resData = await getUserListAll({});
|
const resData = await getUserListAll({});
|
||||||
|
@ -570,6 +560,23 @@ const data = reactive({
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const fnGetData = async () => {
|
||||||
|
isEditMode.value = route.query.mode === "edit";
|
||||||
|
ACCIDENTINVESTIGATION_ID.value = route.query.ACCIDENTINVESTIGATION_ID || "";
|
||||||
|
if (ACCIDENTINVESTIGATION_ID.value) {
|
||||||
|
const resData = await infoAccidentInvestigation({
|
||||||
|
ACCIDENTINVESTIGATION_ID: ACCIDENTINVESTIGATION_ID.value,
|
||||||
|
});
|
||||||
|
if (resData && resData.pd) {
|
||||||
|
Object.keys(resData.pd).forEach((key) => {
|
||||||
|
if (Object.prototype.hasOwnProperty.call(data.form, key)) {
|
||||||
|
data.form[key] = resData.pd[key];
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
fnGetData();
|
||||||
const fnSubmit = async () => {
|
const fnSubmit = async () => {
|
||||||
await useFormValidate(formRef);
|
await useFormValidate(formRef);
|
||||||
|
|
||||||
|
@ -580,13 +587,17 @@ const fnSubmit = async () => {
|
||||||
formData.append(key, value);
|
formData.append(key, value);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
if (Array.isArray(data.form.fileList)) {
|
||||||
data.form.fileList.forEach((file) => {
|
data.form.fileList.forEach((file) => {
|
||||||
if (file.raw) formData.append("FFILEONE", file.raw);
|
if (file.raw) formData.append("FFILEONE", file.raw);
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
if (Array.isArray(data.form.ACCIDENTANALYSISRECORD)) {
|
||||||
data.form.ACCIDENTANALYSISRECORD.forEach((file) => {
|
data.form.ACCIDENTANALYSISRECORD.forEach((file) => {
|
||||||
if (file.raw) formData.append("FFILETWO", file.raw);
|
if (file.raw) formData.append("FFILETWO", file.raw);
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
|
||||||
if (isEditMode.value && ACCIDENTINVESTIGATION_ID.value) {
|
if (isEditMode.value && ACCIDENTINVESTIGATION_ID.value) {
|
||||||
formData.append("ACCIDENTINVESTIGATION_ID", ACCIDENTINVESTIGATION_ID.value);
|
formData.append("ACCIDENTINVESTIGATION_ID", ACCIDENTINVESTIGATION_ID.value);
|
||||||
|
|
|
@ -52,7 +52,7 @@
|
||||||
{{ serialNumber(pagination, $index) }}
|
{{ serialNumber(pagination, $index) }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="INCIDENTNUMBER" label="事故编号" width="250" />
|
<!-- <el-table-column prop="INCIDENTNUMBER" label="事故编号" width="250" />-->
|
||||||
<el-table-column prop="NAME" label="事故人员" />
|
<el-table-column prop="NAME" label="事故人员" />
|
||||||
<el-table-column prop="CORP_NAME" label="工作部门" />
|
<el-table-column prop="CORP_NAME" label="工作部门" />
|
||||||
<el-table-column prop="JOBTYPE" label="人员工种" />
|
<el-table-column prop="JOBTYPE" label="人员工种" />
|
||||||
|
@ -66,7 +66,7 @@
|
||||||
prop="WORKINJURYIDENTIFICATIONLEVEL"
|
prop="WORKINJURYIDENTIFICATIONLEVEL"
|
||||||
label="工伤等级"
|
label="工伤等级"
|
||||||
/>
|
/>
|
||||||
<el-table-column prop="CERTIFICATIONNUMBER" label="认定书编号" />
|
<!-- <el-table-column prop="CERTIFICATIONNUMBER" label="认定书编号" />-->
|
||||||
<el-table-column prop="ACCIDENTRECORDPERSON" label="事故登记人" />
|
<el-table-column prop="ACCIDENTRECORDPERSON" label="事故登记人" />
|
||||||
<el-table-column prop="ACCIDENTDATE" label="事故日期" />
|
<el-table-column prop="ACCIDENTDATE" label="事故日期" />
|
||||||
<el-table-column prop="REGISTRATIONDATE" label="登记日期" />
|
<el-table-column prop="REGISTRATIONDATE" label="登记日期" />
|
||||||
|
|
|
@ -101,12 +101,6 @@
|
||||||
width="140"
|
width="140"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
/>
|
/>
|
||||||
<el-table-column
|
|
||||||
prop="OPERATTIME"
|
|
||||||
label="修改时间"
|
|
||||||
width="140"
|
|
||||||
show-overflow-tooltip
|
|
||||||
/>
|
|
||||||
<el-table-column label="操作" width="150">
|
<el-table-column label="操作" width="150">
|
||||||
<template #default="{ row }">
|
<template #default="{ row }">
|
||||||
<el-button
|
<el-button
|
||||||
|
|
|
@ -48,12 +48,8 @@
|
||||||
v-model="searchForm.EXPIRE_STATUS"
|
v-model="searchForm.EXPIRE_STATUS"
|
||||||
placeholder="请选择到期状态"
|
placeholder="请选择到期状态"
|
||||||
>
|
>
|
||||||
<el-option
|
<el-option label="未到期" value="1"></el-option>
|
||||||
v-for="item in EXPIRE_STATUS"
|
<el-option label="已到期" value="0"></el-option>
|
||||||
:key="item.NAME"
|
|
||||||
:label="item.NAME"
|
|
||||||
:value="item.NAME"
|
|
||||||
/>
|
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
@ -117,14 +113,15 @@
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="EXPIRE_STATUS" label="到期状态">
|
<el-table-column prop="EXPIRE_STATUS" label="到期状态">
|
||||||
<template #default="{ row }">
|
<template #default="{ row }">
|
||||||
<el-tag v-if="row.EXPIRE_STATUS === '已到期'">已到期</el-tag>
|
<el-tag v-if="row.EXPIRE_STATUS === '0'">已到期</el-tag>
|
||||||
<el-tag v-else-if="row.EXPIRE_STATUS === '未到期'">未到期</el-tag>
|
<el-tag v-else-if="row.EXPIRE_STATUS === '1'">未到期</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column prop="RECORD_STATUS" label="档案状态" >
|
<el-table-column prop="NEW_ARCHIVES_TYPE" label="车辆状态" width="150">
|
||||||
<template #default="{ row }">
|
<template #default="{ row }">
|
||||||
<el-tag v-if="row.RECORD_STATUS === ''">正常</el-tag>
|
<el-tag v-if="row.NEW_ARCHIVES_TYPE === '1'">报废</el-tag>
|
||||||
<el-tag v-else>过户</el-tag>
|
<el-tag v-else-if="row.NEW_ARCHIVES_TYPE === '0'">正常</el-tag>
|
||||||
|
<el-tag v-else-if="row.NEW_ARCHIVES_TYPE === '2'">过户</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="操作" width="150">
|
<el-table-column label="操作" width="150">
|
||||||
|
@ -186,9 +183,7 @@
|
||||||
<script setup>
|
<script setup>
|
||||||
import { serialNumber } from "@/assets/js/utils.js";
|
import { serialNumber } from "@/assets/js/utils.js";
|
||||||
import useListData from "@/assets/js/useListData.js";
|
import useListData from "@/assets/js/useListData.js";
|
||||||
import {
|
import { layoutFnGetRemindStatus } from "@/assets/js/taxation_manage.js";
|
||||||
layoutFnGetRemindStatus,
|
|
||||||
} from "@/assets/js/taxation_manage.js";
|
|
||||||
import {
|
import {
|
||||||
getTaxationManageList,
|
getTaxationManageList,
|
||||||
setTaxatonManageDelete,
|
setTaxatonManageDelete,
|
||||||
|
|
Loading…
Reference in New Issue