123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295 |
- <template>
- <div :class="props.deviceType == 'fireWarnInfo' ? 'dzCard1' : 'dzCard'">
- <div class="gas-box">
- <div class="gas-item">
- <div class="detail-box">
- <div class="detail-container">
- <vue3-seamless-scroll hover-stop="true" :list="infoData.dataOn" :hover="true" :step="0.18"
- class="seamless-warp">
- <div class="detail-item" v-for="(item, index) in infoData.dataOn" :key="index">
- <div class="item-box">
- <div class="item-box-label">{{ titleLeft.address }}</div>
- <div class="item-box-val">{{ item.value1 || '-' }}</div>
- </div>
- <div class="item-box">
- <div class="item-box-label">{{ titleLeft.gradewarn }}</div>
- <div class="item-box-val">{{ item.warnLevel || '-' }}</div>
- </div>
- <div class="item-box">
- <div class="item-box-label">{{ titleLeft.smoke }}</div>
- <div class="item-box-val">{{ item.smokeJd || '-' }}</div>
- </div>
- </div>
- </vue3-seamless-scroll>
- </div>
- </div>
- </div>
- <div class="gas-item">
- <div class="detail-box">
- <div class="detail-container">
- <div class="detail-item">
- <div class="item-box1">
- <div class="item-box-label">{{ titleRight.temp }}</div>
- <div class="item-box-val1">{{ infoData.tempVal }}</div>
- </div>
- <div class="item-box1">
- <div class="item-box-label">{{ titleRight.smokeing }}</div>
- <div class="item-box-val1">{{ infoData.smokeVal }}</div>
- </div>
- <div class="item-box1">
- <div class="item-box-label">{{ titleRight.fire }}</div>
- <div class="item-box-val1">{{ infoData.fireVal }}</div>
- </div>
- <div class="item-box1">
- <div class="item-box-label">{{ titleRight.comax }}</div>
- <div class="item-box-val1">{{ infoData.coVal }}</div>
- </div>
- </div>
- </div>
- </div>
- </div>
- </div>
- </div>
- </template>
- <script lang="ts" setup>
- import { ref, reactive, watch } from 'vue';
- import { Vue3SeamlessScroll } from 'vue3-seamless-scroll';
- let props = defineProps({
- titleLeft: {
- type: Object,
- default: () => {
- return {};
- },
- },
- titleRight: {
- type: Object,
- default: () => {
- return {};
- },
- },
- paramData: {
- type: Object,
- default: () => {
- return {};
- },
- },
- deviceType: {
- type: String,
- default: '',
- },
- });
- let infoData = reactive({});
- watch(
- () => props.paramData,
- (newV, oldV) => {
- infoData = Object.assign({}, newV);
- },
- { immediate: true }
- );
- </script>
- <style lang="less" scoped>
- @import '/@/design/theme.less';
- @{theme-deepblue} {
- .dzCard {
- --image-model_gas_item: url('@/assets/images/themify/deepblue/home-container/configurable/900.png');
- --image-model_gas_item1: url('@/assets/images/themify/deepblue/home-container/configurable/1100.png');
- }
- }
- .dzCard {
- --image-model_gas_item: url('@/assets/images/home-green/900.png');
- --image-model_gas_item1: url('@/assets/images/home-green/1100.png');
- --image-model_fire_item: url('@/assets/images/home-warn/4-2.png');
- width: 100%;
- height: 72%;
- position: absolute;
- left: 0;
- top: 86px;
- .gas-box {
- display: flex;
- justify-content: center;
- height: 100%;
- .gas-item {
- position: relative;
- width: 50%;
- height: 100%;
- margin: 0px 5px;
- &:nth-child(1) {
- background: var(--image-model_gas_item) no-repeat;
- background-size: 100% 100%;
- }
- &:nth-child(2) {
- background: var(--image-model_gas_item1) no-repeat;
- background-size: 100% 100%;
- }
- .detail-box {
- position: relative;
- height: 100%;
- padding-top: 68px;
- .detail-container {
- height: 100%;
- //overflow-y: auto;
- .seamless-warp {
- height: 100%;
- width: 100%;
- overflow: hidden;
- }
- .detail-item {
- width: 100%;
- height: 100%;
- .item-box {
- width: 100%;
- padding: 0px 10px;
- height: 60px;
- display: flex;
- justify-content: space-between;
- align-items: center;
- }
- .item-box1 {
- width: 100%;
- padding: 0px 10px;
- height: 42px;
- display: flex;
- justify-content: space-between;
- align-items: center;
- }
- .item-box-label {
- flex-shrink: 0;
- width: 60px;
- font-size: 12px;
- text-align: left;
- margin-right: 10px;
- }
- .item-box-val {
- text-align: right;
- color: #b9ffe5;
- font-family: 'douyuFont';
- font-size: 12px;
- }
- .item-box-val1 {
- text-align: right;
- color: #b9f1ff;
- font-family: 'douyuFont';
- font-size: 12px;
- }
- }
- }
- }
- }
- }
- }
- .dzCard1 {
- --image-model_gas_item: url('@/assets/images/home-green/900.png');
- --image-model_gas_item1: url('@/assets/images/home-green/1100.png');
- --image-model_fire_item: url('@/assets/images/home-warn/4-2.png');
- width: 100%;
- height: 72%;
- position: absolute;
- left: 0;
- .gas-box {
- display: flex;
- justify-content: center;
- height: 100%;
- .gas-item {
- position: relative;
- width: 50%;
- height: 100%;
- margin: 0px 5px;
- &:nth-child(1) {
- background: var(--image-model_fire_item) no-repeat;
- background-size: 100% 100%;
- }
- &:nth-child(2) {
- background: var(--image-model_fire_item) no-repeat;
- background-size: 100% 100%;
- }
- .detail-box {
- position: relative;
- height: 100%;
- padding-top: 15px;
- .detail-container {
- height: 100%;
- overflow-y: hidden;
- &:hover {
- overflow-y: auto;
- }
- .detail-item {
- width: 100%;
- height: 100%;
- .item-box {
- width: 100%;
- padding: 0px 10px;
- height: 60px;
- display: flex;
- justify-content: space-between;
- align-items: center;
- }
- .item-box1 {
- width: 100%;
- padding: 0px 10px;
- height: 42px;
- display: flex;
- justify-content: space-between;
- align-items: center;
- }
- .item-box-label {
- flex-shrink: 0;
- width: 60px;
- font-size: 12px;
- text-align: left;
- margin-right: 10px;
- }
- .item-box-val {
- text-align: right;
- color: #c0fbff;
- font-family: 'douyuFont';
- font-size: 12px;
- }
- .item-box-val1 {
- text-align: right;
- color: #53f696;
- font-family: 'douyuFont';
- font-size: 12px;
- }
- }
- }
- }
- }
- }
- }
- </style>
|