|
@@ -1,45 +1,54 @@
|
|
|
<template>
|
|
<template>
|
|
|
<div class="info-container">
|
|
<div class="info-container">
|
|
|
- <CollapseItem
|
|
|
|
|
- v-for="reportTask in disasterLossDetailList?.reportTaskList"
|
|
|
|
|
- :key="reportTask.reportDeptId"
|
|
|
|
|
- :name="`上报单位:${reportTask.reportDeptName}`"
|
|
|
|
|
- :isActive="activeId === reportTask.reportDeptId"
|
|
|
|
|
- @toggle="handleCollapseToggle(reportTask.reportDeptId)"
|
|
|
|
|
- >
|
|
|
|
|
- <template #view-operation>
|
|
|
|
|
- <div class="rectification-info">
|
|
|
|
|
- <span class="num">{{ reportTask.lossRecordCount }}</span>
|
|
|
|
|
- <span>条,整改完成{{ reportTask.fixFinishCount }}条</span>
|
|
|
|
|
- </div>
|
|
|
|
|
- </template>
|
|
|
|
|
- <template #right-header>
|
|
|
|
|
- <span class="collapse-item__header--right">
|
|
|
|
|
- {{ activeId === reportTask.reportDeptId ? '收起' : '展开' }}
|
|
|
|
|
- </span>
|
|
|
|
|
- </template>
|
|
|
|
|
- <template #main-table>
|
|
|
|
|
- <div class="rectification-table">
|
|
|
|
|
- <section class="damaged-list-container">
|
|
|
|
|
- <DamagedList
|
|
|
|
|
- :damagedList="reportTask.lossRecordList"
|
|
|
|
|
- :active-id="activeTaskId || reportTask.lossRecordList[0].fixTaskId"
|
|
|
|
|
- @update:activeId="handleActiveTask"
|
|
|
|
|
- />
|
|
|
|
|
- </section>
|
|
|
|
|
- <section class="disaster-info-container">
|
|
|
|
|
- <DisasterInfo :LossReportItemFormData="lossRecordListInfo" rectification v-if="lossRecordListInfo" />
|
|
|
|
|
- <Rectification
|
|
|
|
|
- v-if="lossRecordListInfo?.fixRecordList"
|
|
|
|
|
- :rectification-list="lossRecordListInfo?.fixRecordList"
|
|
|
|
|
- :rectification-dept-name="lossRecordListInfo?.responsibleDeptName"
|
|
|
|
|
- :rectification-responsible-user-list="rectificationResponsibleUserList"
|
|
|
|
|
- :rectification-priority="lossRecordListInfo?.priority"
|
|
|
|
|
- />
|
|
|
|
|
- </section>
|
|
|
|
|
- </div>
|
|
|
|
|
- </template>
|
|
|
|
|
- </CollapseItem>
|
|
|
|
|
|
|
+ <template v-for="reportTask in disasterLossDetailList?.reportTaskList" :key="reportTask.reportDeptId">
|
|
|
|
|
+ <CollapseItem
|
|
|
|
|
+ v-if="reportTask.lossRecordList.length"
|
|
|
|
|
+ :name="`上报单位:${reportTask.reportDeptName}`"
|
|
|
|
|
+ :isActive="activeId === reportTask.reportDeptId"
|
|
|
|
|
+ @toggle="handleCollapseToggle(reportTask.reportDeptId)"
|
|
|
|
|
+ >
|
|
|
|
|
+ <template #view-operation>
|
|
|
|
|
+ <div class="rectification-info">
|
|
|
|
|
+ <span class="num">{{ reportTask.lossRecordCount }}</span>
|
|
|
|
|
+ <span>条,整改完成{{ reportTask.fixFinishCount }}条</span>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <template #right-header>
|
|
|
|
|
+ <span class="collapse-item__header--right">
|
|
|
|
|
+ {{ activeId === reportTask.reportDeptId ? '收起' : '展开' }}
|
|
|
|
|
+ </span>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ <template #main-table>
|
|
|
|
|
+ <div class="rectification-table">
|
|
|
|
|
+ <section class="damaged-list-container">
|
|
|
|
|
+ <DamagedList
|
|
|
|
|
+ :damagedList="reportTask.lossRecordList"
|
|
|
|
|
+ :active-id="activeTaskId || reportTask.lossRecordList[0].fixTaskId"
|
|
|
|
|
+ @update:activeId="handleActiveTask"
|
|
|
|
|
+ />
|
|
|
|
|
+ </section>
|
|
|
|
|
+ <section class="disaster-info-container">
|
|
|
|
|
+ <DisasterInfo :LossReportItemFormData="lossRecordListInfo" rectification v-if="lossRecordListInfo" />
|
|
|
|
|
+ <Rectification
|
|
|
|
|
+ v-if="lossRecordListInfo?.fixRecordList"
|
|
|
|
|
+ :rectification-list="lossRecordListInfo?.fixRecordList"
|
|
|
|
|
+ :rectification-dept-name="lossRecordListInfo?.responsibleDeptName"
|
|
|
|
|
+ :rectification-responsible-user-list="rectificationResponsibleUserList"
|
|
|
|
|
+ :rectification-priority="lossRecordListInfo?.priority"
|
|
|
|
|
+ />
|
|
|
|
|
+ </section>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </CollapseItem>
|
|
|
|
|
+ <NoCollapseItem v-else :name="`上报单位:${reportTask.reportDeptName}`">
|
|
|
|
|
+ <template #view-operation>
|
|
|
|
|
+ <div class="rectification-info">
|
|
|
|
|
+ <span class="num">{{ reportTask.lossRecordCount }}</span>
|
|
|
|
|
+ <span class="info-text">条,上报时间:{{ reportTask.reportTime }}</span>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </NoCollapseItem>
|
|
|
|
|
+ </template>
|
|
|
</div>
|
|
</div>
|
|
|
</template>
|
|
</template>
|
|
|
|
|
|
|
@@ -47,12 +56,13 @@
|
|
|
import { useRoute } from 'vue-router';
|
|
import { useRoute } from 'vue-router';
|
|
|
import { onMounted, ref } from 'vue';
|
|
import { onMounted, ref } from 'vue';
|
|
|
import CollapseItem from './CollapseItem.vue';
|
|
import CollapseItem from './CollapseItem.vue';
|
|
|
|
|
+ import NoCollapseItem from './NoCollapseItem.vue';
|
|
|
import DamagedList from './DamagedList.vue';
|
|
import DamagedList from './DamagedList.vue';
|
|
|
import DisasterInfo from './DisasterInfo.vue';
|
|
import DisasterInfo from './DisasterInfo.vue';
|
|
|
import Rectification from './Rectification.vue';
|
|
import Rectification from './Rectification.vue';
|
|
|
import { useDisasterControlHook } from '../hook';
|
|
import { useDisasterControlHook } from '../hook';
|
|
|
import type { PersonGroupItem } from '@/types/person-group/type';
|
|
import type { PersonGroupItem } from '@/types/person-group/type';
|
|
|
- import type { ReportTaskListDetail, LossRecordListDetail, OverviewLossRecordInfo } from '@/types/disaster-control';
|
|
|
|
|
|
|
+ import type { ReportTaskListDetail, LossRecordListDetail } from '@/types/disaster-control';
|
|
|
import { queryUserInfoByIds } from '@/api/system/person-group';
|
|
import { queryUserInfoByIds } from '@/api/system/person-group';
|
|
|
|
|
|
|
|
const route = useRoute();
|
|
const route = useRoute();
|
|
@@ -113,13 +123,6 @@
|
|
|
});
|
|
});
|
|
|
}
|
|
}
|
|
|
};
|
|
};
|
|
|
- const getLossRecordListInfo = () => {
|
|
|
|
|
- if (!lossRecordListInfo.value) return;
|
|
|
|
|
- return {
|
|
|
|
|
- id: lossRecordListInfo.value.id,
|
|
|
|
|
- name: lossRecordListInfo.value.affectedItems,
|
|
|
|
|
- };
|
|
|
|
|
- };
|
|
|
|
|
onMounted(async () => {
|
|
onMounted(async () => {
|
|
|
await getDisasterLossDetailList({ handleTaskId });
|
|
await getDisasterLossDetailList({ handleTaskId });
|
|
|
if (!disasterLossDetailList.value?.reportTaskList.length) return;
|
|
if (!disasterLossDetailList.value?.reportTaskList.length) return;
|
|
@@ -128,14 +131,12 @@
|
|
|
reportTaskListInfo.value = reportTaskList.value.find((item) => item.reportDeptId === activeId.value);
|
|
reportTaskListInfo.value = reportTaskList.value.find((item) => item.reportDeptId === activeId.value);
|
|
|
if (!reportTaskListInfo.value) return;
|
|
if (!reportTaskListInfo.value) return;
|
|
|
lossRecordList.value = reportTaskListInfo.value?.lossRecordList;
|
|
lossRecordList.value = reportTaskListInfo.value?.lossRecordList;
|
|
|
|
|
+ if (!lossRecordList.value.length) return;
|
|
|
activeTaskId.value = lossRecordList.value[0].fixTaskId;
|
|
activeTaskId.value = lossRecordList.value[0].fixTaskId;
|
|
|
lossRecordListInfo.value = lossRecordList.value.find((item) => item.fixTaskId === activeTaskId.value);
|
|
lossRecordListInfo.value = lossRecordList.value.find((item) => item.fixTaskId === activeTaskId.value);
|
|
|
getFixUserList(lossRecordListInfo.value?.fixPrincipals);
|
|
getFixUserList(lossRecordListInfo.value?.fixPrincipals);
|
|
|
getFixRecordUser();
|
|
getFixRecordUser();
|
|
|
});
|
|
});
|
|
|
- defineExpose({
|
|
|
|
|
- getLossRecordListInfo,
|
|
|
|
|
- });
|
|
|
|
|
</script>
|
|
</script>
|
|
|
|
|
|
|
|
<style lang="scss" scoped>
|
|
<style lang="scss" scoped>
|