|
|
@@ -49,7 +49,17 @@
|
|
|
text="演练执行"
|
|
|
@click="handleToExecute(scope.row.id)"
|
|
|
/>
|
|
|
- <ActionButton v-else-if="scope.row.status < 7" text="演练记录" @click="handleToRecord(scope.row)" />
|
|
|
+ <ActionButton
|
|
|
+ v-else-if="scope.row.status < EMERGENCY_DRILL_STATUS.COMPLETE"
|
|
|
+ text="演练记录"
|
|
|
+ @click="handleToRecord(scope.row)"
|
|
|
+ />
|
|
|
+ <ActionButton
|
|
|
+ class="has-problem"
|
|
|
+ v-else-if="scope.row.status === EMERGENCY_DRILL_STATUS.HAS_PROBLEM"
|
|
|
+ text="演练问题"
|
|
|
+ @click="handleViewDrillPlan(scope.row.id, 'records')"
|
|
|
+ />
|
|
|
<ActionButton
|
|
|
text="删除"
|
|
|
:popconfirm="{
|
|
|
@@ -78,7 +88,7 @@
|
|
|
import { DRILL_PLAN_LIST_SEARCH_CONFIG } from './configs/plan/search';
|
|
|
import { TABLE_OPTIONS, DRILL_PLAN_LIST_TABLE_COLUMNS } from './configs/plan/table';
|
|
|
import { DrillPlanListSearch, DrillPlanItem } from './types';
|
|
|
- import { EMERGENCY_DRILL_STATUS_DICT } from './constants';
|
|
|
+ import { EMERGENCY_DRILL_STATUS, EMERGENCY_DRILL_STATUS_DICT } from './constants';
|
|
|
import { useEmergencyDrillHook } from './hook';
|
|
|
import { QueryPageRequest } from '@/types/basic-query';
|
|
|
|
|
|
@@ -165,11 +175,12 @@
|
|
|
});
|
|
|
}
|
|
|
|
|
|
- function handleViewDrillPlan(id: number) {
|
|
|
+ function handleViewDrillPlan(id: number, tab: string = 'activities') {
|
|
|
router.push({
|
|
|
name: 'emergency-drill-plan-view',
|
|
|
query: {
|
|
|
id: id,
|
|
|
+ tab: tab,
|
|
|
},
|
|
|
});
|
|
|
}
|
|
|
@@ -200,4 +211,8 @@
|
|
|
@use '@/styles/page-details-layout.scss' as *;
|
|
|
@use '@/styles/page-main-layout.scss' as *;
|
|
|
@use '@/styles/basic-table-action.scss' as *;
|
|
|
+
|
|
|
+ .has-problem {
|
|
|
+ color: #ec2828;
|
|
|
+ }
|
|
|
</style>
|