|
|
@@ -47,29 +47,13 @@
|
|
|
</template>
|
|
|
</MenuItem>
|
|
|
</TechTabPane>
|
|
|
- <TechTabPane label="特勤" name="specialDuty" class="menu-scroll-view special-duty-pane">
|
|
|
- <TechTable ref="dutyTable" :columns="tableColumns" :data="tableData" class="duty-table">
|
|
|
- <template #name="{ row }">
|
|
|
- <span class="duty-name" :title="row.name">{{ row.name }}</span>
|
|
|
- </template>
|
|
|
- <template #level="{ row }">
|
|
|
- <span :title="row.level" :style="{ color: row.level === '二级' ? '#FFDF0C' : '#F00' }">
|
|
|
- {{ row.level }}
|
|
|
- </span>
|
|
|
- </template>
|
|
|
- <template #status="{ row }">
|
|
|
- <span :title="row.status" :style="{ color: row.status === '进行中' ? '#FFDF0C' : row.status === '未开始' ? '#fff' : '#8dc453' }">
|
|
|
- {{ row.status }}
|
|
|
- </span>
|
|
|
- </template>
|
|
|
- <template #action="{ row }">
|
|
|
- <div class="btn-group">
|
|
|
- <span class="action-btn" @click="handleSpecialTaskView(row)">查看</span>
|
|
|
- <span v-if="row.status === '未开始'" class="action-btn action-start" @click="handleSpecialTaskStart(row)">立即执行</span>
|
|
|
- <span v-if="row.status === '进行中'" class="action-btn action-end" @click="handleSpecialTaskEnd(row)">立即结束</span>
|
|
|
- </div>
|
|
|
- </template>
|
|
|
- </TechTable>
|
|
|
+ <TechTabPane label="特勤" name="specialDuty" class="menu-scroll-view">
|
|
|
+ <TaskCardList :listData="tableData" class="special-duty-pane"
|
|
|
+ @view="({ item }) => handleSpecialTaskView(item)"
|
|
|
+ @start="({ item }) => handleSpecialTaskStart(item)"
|
|
|
+ @end="({ item }) => handleSpecialTaskEnd(item)"
|
|
|
+ @restart="({ item }) => handleSpecialTaskRestart(item)"
|
|
|
+ />
|
|
|
</TechTabPane>
|
|
|
</TechTabs>
|
|
|
</div>
|
|
|
@@ -118,6 +102,7 @@ import TongzhouTrafficMap from '@/components/TongzhouTrafficMap.vue';
|
|
|
import MenuItem from '@/components/ui/MenuItem.vue';
|
|
|
import ButtonGroup from '@/components/ui/ButtonGroup.vue';
|
|
|
import TechTable from '@/components/ui/TechTable.vue';
|
|
|
+import TaskCardList from '@/components/ui/TaskCardList.vue';
|
|
|
import CrossingListPanel from '@/components/ui/CrossingListPanel.vue';
|
|
|
import OnlineStatusTabs from '@/components/ui/OnlineStatusTabs.vue';
|
|
|
import DeviceStatusTabs from '@/components/ui/DeviceStatusTabs.vue';
|
|
|
@@ -136,6 +121,7 @@ export default {
|
|
|
MenuItem,
|
|
|
ButtonGroup,
|
|
|
TechTable,
|
|
|
+ TaskCardList,
|
|
|
CrossingListPanel,
|
|
|
OnlineStatusTabs,
|
|
|
DeviceStatusTabs,
|
|
|
@@ -568,6 +554,10 @@ export default {
|
|
|
console.log('立即结束特勤任务:', row);
|
|
|
row.status = '已完成';
|
|
|
},
|
|
|
+ handleSpecialTaskRestart(row) {
|
|
|
+ console.log('重新开始特勤任务:', row);
|
|
|
+ row.status = '进行中';
|
|
|
+ },
|
|
|
|
|
|
|
|
|
}
|
|
|
@@ -646,43 +636,7 @@ export default {
|
|
|
}
|
|
|
/* 针对特勤 Tab 单独剥离背景和边框 */
|
|
|
::v-deep .special-duty-pane {
|
|
|
- background: transparent !important;
|
|
|
- background-color: transparent !important;
|
|
|
- background-image: none !important;
|
|
|
- border: none !important;
|
|
|
- box-shadow: none !important;
|
|
|
- outline: none !important;
|
|
|
-}
|
|
|
-
|
|
|
-/* 如果你的科技UI边框是利用伪元素(::before / ::after)绘制的,再加上这两句抹除 */
|
|
|
-::v-deep .special-duty-pane::before,
|
|
|
-::v-deep .special-duty-pane::after {
|
|
|
- display: none !important;
|
|
|
+ padding: 10px 20px;
|
|
|
}
|
|
|
|
|
|
-::v-deep .special-duty-pane .tech-table tbody td {
|
|
|
- color: #ffffff;
|
|
|
- font-size: clamp(12px, 2.5cqw, 14px);
|
|
|
- padding: clamp(8px, 1.5cqw, 10px) clamp(8px, 1.5cqw, 10px);
|
|
|
- white-space: normal !important;
|
|
|
- overflow: hidden;
|
|
|
- text-overflow: ellipsis;
|
|
|
-}
|
|
|
-::v-deep .special-duty-pane .tech-table thead th {
|
|
|
- background-color: rgba(17, 36, 70, 1);
|
|
|
-}
|
|
|
-::v-deep .special-duty-pane .tech-table tbody tr:nth-child(odd) {
|
|
|
- background-color: rgba(30, 50, 90, 1);
|
|
|
-}
|
|
|
-::v-deep .special-duty-pane .tech-table tbody .table-row {
|
|
|
- background-color: rgba(30, 50, 90, 1);
|
|
|
-}
|
|
|
-::v-deep .special-duty-pane .tech-table tbody .table-row:hover {
|
|
|
- background-color: rgb(75, 112, 185);
|
|
|
-}
|
|
|
-::v-deep .special-duty-pane .tech-table .btn-group {
|
|
|
- display: flex;
|
|
|
- gap: 10px;
|
|
|
- flex-direction: column;
|
|
|
-}
|
|
|
</style>
|