2025-10-31 15:35:10 +08:00
|
|
|
<template>
|
|
|
|
|
<div class="emergency-resources">
|
|
|
|
|
<div class="panel-header">
|
|
|
|
|
<span class="title">应急资源</span>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<!-- 资源列表 -->
|
|
|
|
|
<div class="resource-table">
|
|
|
|
|
<div class="table-header">
|
|
|
|
|
<span>所属区县</span>
|
|
|
|
|
<span>服务站点</span>
|
|
|
|
|
<span>应急物资</span>
|
|
|
|
|
<span>应急设备</span>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
<div
|
|
|
|
|
v-for="(resource, index) in resources"
|
|
|
|
|
:key="resource.id"
|
|
|
|
|
class="table-row"
|
|
|
|
|
:class="{ 'row-alt': index % 2 === 0 }"
|
|
|
|
|
>
|
|
|
|
|
<div class="row-number">{{ index + 1 }}</div>
|
|
|
|
|
<span class="district-name">{{ resource.name }}</span>
|
|
|
|
|
<span class="count green">{{ resource.stations }}</span>
|
|
|
|
|
<span class="count orange">{{ resource.supplies }}</span>
|
|
|
|
|
<div class="equipment-cell">
|
|
|
|
|
<span class="count" :class="resource.equipmentClass">{{ resource.equipment }}</span>
|
|
|
|
|
<img
|
|
|
|
|
v-if="resource.hasAlert"
|
|
|
|
|
src="../assets/img/emergency-alert-icon.png"
|
|
|
|
|
alt="alert"
|
|
|
|
|
class="alert-icon"
|
|
|
|
|
/>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<script setup>
|
|
|
|
|
import { ref } from 'vue'
|
|
|
|
|
|
|
|
|
|
const resources = ref([
|
|
|
|
|
{
|
|
|
|
|
id: 1,
|
|
|
|
|
name: '万州区',
|
|
|
|
|
stations: 32,
|
|
|
|
|
supplies: 32,
|
|
|
|
|
equipment: 25,
|
|
|
|
|
equipmentClass: 'red',
|
|
|
|
|
hasAlert: true
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
id: 2,
|
|
|
|
|
name: '城口区',
|
|
|
|
|
stations: 11,
|
|
|
|
|
supplies: 11,
|
|
|
|
|
equipment: 15,
|
|
|
|
|
equipmentClass: 'red',
|
|
|
|
|
hasAlert: true
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
id: 3,
|
|
|
|
|
name: '长寿区',
|
|
|
|
|
stations: 136,
|
|
|
|
|
supplies: 136,
|
|
|
|
|
equipment: 12,
|
|
|
|
|
equipmentClass: 'red',
|
|
|
|
|
hasAlert: false
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
id: 4,
|
|
|
|
|
name: '涪陵区',
|
|
|
|
|
stations: 35,
|
|
|
|
|
supplies: 35,
|
|
|
|
|
equipment: 12,
|
|
|
|
|
equipmentClass: 'red',
|
|
|
|
|
hasAlert: false
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
id: 5,
|
|
|
|
|
name: '合川区',
|
|
|
|
|
stations: 46,
|
|
|
|
|
supplies: 46,
|
|
|
|
|
equipment: 12,
|
|
|
|
|
equipmentClass: 'red',
|
|
|
|
|
hasAlert: false
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
id: 6,
|
|
|
|
|
name: '永川区',
|
|
|
|
|
stations: 35,
|
|
|
|
|
supplies: 35,
|
|
|
|
|
equipment: 12,
|
|
|
|
|
equipmentClass: 'red',
|
|
|
|
|
hasAlert: false
|
|
|
|
|
}
|
|
|
|
|
])
|
|
|
|
|
</script>
|
|
|
|
|
|
2025-10-31 20:08:49 +08:00
|
|
|
<style scoped lang="scss">
|
|
|
|
|
@import '@/styles/mixins.scss';
|
|
|
|
|
|
2025-10-31 15:35:10 +08:00
|
|
|
.emergency-resources {
|
|
|
|
|
background: url(../assets/img/emergency-panel-bg.png) no-repeat;
|
|
|
|
|
background-size: 100% 100%;
|
2025-10-31 20:08:49 +08:00
|
|
|
padding: vw(20) vw(30);
|
2025-10-31 15:35:10 +08:00
|
|
|
flex: 1;
|
|
|
|
|
display: flex;
|
|
|
|
|
flex-direction: column;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.panel-header {
|
|
|
|
|
position: relative;
|
2025-10-31 20:08:49 +08:00
|
|
|
width: vw(293);
|
|
|
|
|
height: vh(49);
|
2025-10-31 15:35:10 +08:00
|
|
|
background: url(../assets/img/common-panel-header-bg.png) no-repeat;
|
|
|
|
|
background-size: 100% 100%;
|
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
2025-10-31 20:08:49 +08:00
|
|
|
padding-left: vw(24);
|
|
|
|
|
margin-bottom: vh(30);
|
2025-10-31 15:35:10 +08:00
|
|
|
|
|
|
|
|
.title {
|
|
|
|
|
color: rgba(255, 255, 255, 1);
|
2025-10-31 20:08:49 +08:00
|
|
|
font-size: fs(22);
|
2025-10-31 15:35:10 +08:00
|
|
|
font-family: SourceHanSansCN-Medium, sans-serif;
|
|
|
|
|
font-weight: 500;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.resource-table {
|
|
|
|
|
flex: 1;
|
|
|
|
|
display: flex;
|
|
|
|
|
flex-direction: column;
|
|
|
|
|
|
|
|
|
|
.table-header {
|
2025-10-31 20:08:49 +08:00
|
|
|
height: vh(35);
|
2025-10-31 15:35:10 +08:00
|
|
|
background: url(../assets/img/emergency-table-header-bg.png) no-repeat;
|
|
|
|
|
background-size: 100% 100%;
|
|
|
|
|
display: grid;
|
|
|
|
|
grid-template-columns: 1fr 1fr 1fr 1fr;
|
|
|
|
|
align-items: center;
|
|
|
|
|
text-align: center;
|
|
|
|
|
color: rgba(255, 255, 255, 1);
|
2025-10-31 20:08:49 +08:00
|
|
|
font-size: fs(16);
|
2025-10-31 15:35:10 +08:00
|
|
|
font-family: SourceHanSansCN-Medium, sans-serif;
|
|
|
|
|
font-weight: 500;
|
2025-10-31 20:08:49 +08:00
|
|
|
margin-bottom: vh(5);
|
2025-10-31 15:35:10 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.table-row {
|
2025-10-31 20:08:49 +08:00
|
|
|
height: vh(35);
|
2025-10-31 15:35:10 +08:00
|
|
|
display: grid;
|
2025-10-31 20:08:49 +08:00
|
|
|
grid-template-columns: vw(35) 1fr 1fr 1fr 1fr;
|
2025-10-31 15:35:10 +08:00
|
|
|
align-items: center;
|
2025-10-31 20:08:49 +08:00
|
|
|
gap: vw(10);
|
2025-10-31 15:35:10 +08:00
|
|
|
color: rgba(255, 255, 255, 1);
|
2025-10-31 20:08:49 +08:00
|
|
|
font-size: fs(14);
|
2025-10-31 15:35:10 +08:00
|
|
|
font-family: PingFangSC-Medium, sans-serif;
|
|
|
|
|
font-weight: 500;
|
|
|
|
|
|
|
|
|
|
&.row-alt {
|
|
|
|
|
background: url(../assets/img/common-table-row-bg.png) no-repeat;
|
|
|
|
|
background-size: 100% 100%;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
&:not(.row-alt) {
|
|
|
|
|
background: url(../assets/img/common-table-row-bg-alt.png) no-repeat;
|
|
|
|
|
background-size: 100% 100%;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.row-number {
|
2025-10-31 20:08:49 +08:00
|
|
|
width: vw(35);
|
|
|
|
|
height: vh(35);
|
2025-10-31 15:35:10 +08:00
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
justify-content: center;
|
|
|
|
|
background-color: rgba(28, 161, 255, 0.44);
|
|
|
|
|
color: rgba(255, 255, 255, 1);
|
2025-10-31 20:08:49 +08:00
|
|
|
font-size: fs(14);
|
2025-10-31 15:35:10 +08:00
|
|
|
font-family: FZZYJW--GB1-0, sans-serif;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
&:not(.row-alt) .row-number {
|
|
|
|
|
background-color: rgba(28, 161, 255, 0.2);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.district-name {
|
|
|
|
|
text-align: left;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.count {
|
|
|
|
|
text-align: center;
|
|
|
|
|
font-family: PingFangSC-Semibold, sans-serif;
|
|
|
|
|
font-weight: 600;
|
2025-10-31 20:08:49 +08:00
|
|
|
font-size: fs(14);
|
2025-10-31 15:35:10 +08:00
|
|
|
|
|
|
|
|
&.green {
|
|
|
|
|
color: rgba(17, 187, 119, 1);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
&.orange {
|
|
|
|
|
color: rgba(255, 128, 11, 1);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
&.red {
|
|
|
|
|
color: rgba(255, 6, 36, 1);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.equipment-cell {
|
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
justify-content: center;
|
2025-10-31 20:08:49 +08:00
|
|
|
gap: vw(5);
|
2025-10-31 15:35:10 +08:00
|
|
|
|
|
|
|
|
.alert-icon {
|
2025-10-31 20:08:49 +08:00
|
|
|
width: vw(10);
|
|
|
|
|
height: vh(10);
|
2025-10-31 15:35:10 +08:00
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
</style>
|