fireWork.vue 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381
  1. <template>
  2. <div class="fireWork">
  3. <!-- 顶部区域 -->
  4. <div class="work-nav">
  5. <div class="nav" v-for="(item, index) in topList" :key="index">
  6. <div class="pic" v-if="item.imgSrc">
  7. <img :src="imgUrl" alt="" />
  8. </div>
  9. <div class="content" v-if="item.label && item.value">
  10. <span>{{ item.label }}</span>
  11. <span>{{ item.value }}</span>
  12. </div>
  13. <div class="text" v-if="item.text">{{ item.text }}</div>
  14. <div class="percent" v-if="item.list.length != 0">
  15. <div class="title">{{ item.label }}</div>
  16. <div class="value">
  17. <div class="box" v-for="(items, ind) in item.list" :key="ind">
  18. <span style="color: #b3b8cc">{{ `${items.label} :` }}</span>
  19. <span style="color: #3df6ff; margin-left: 10px">{{ `${items.value}%` }}</span>
  20. </div>
  21. </div>
  22. </div>
  23. </div>
  24. </div>
  25. <!-- 中间区域 -->
  26. <div class="center-echart">
  27. <div class="nav-title">
  28. <div class="title">光纤测温系统温度实时监测</div>
  29. <a-select style="width: 240px; margin-left: 10px" v-model="pointCode" allowClear class="code-mode-select"
  30. placeholder="请选择" @change="handleChange">
  31. <a-select-option v-for="device in pointList" :key="device.value" :value="device.value">{{ device.label
  32. }}
  33. </a-select-option>
  34. </a-select>
  35. </div>
  36. <div class="echart-box">
  37. <echartLine :echartDataGq="echartDataGq"></echartLine>
  38. </div>
  39. </div>
  40. <!-- 底部区域 -->
  41. <div class="bot-content">
  42. <div class="title">
  43. <div class="text">束管系统监测</div>
  44. <div class="search">
  45. <a-range-picker v-model="TimeRange" :show-time="{ format: 'HH:mm:ss' }" format="YYYY-MM-DD HH:mm:ss"
  46. :placeholder="['开始时间', '终止时间']" @change="onDataChange" />
  47. <a-select style="width: 240px; margin-left: 10px" v-model="pointCode1" allowClear
  48. class="code-mode-select" placeholder="请选择" @change="handleChange1">
  49. <a-select-option v-for="device in pointList1" :key="device.value" :value="device.value">{{
  50. device.label }}
  51. </a-select-option>
  52. </a-select>
  53. </div>
  54. </div>
  55. <div class="content">
  56. <div class="box" v-for="(item, index) in contentList" :key="index">
  57. <div class="box-item" v-for="(items, ind) in item.list" :key="ind" @click="getSgClick(items)">
  58. <div class="content-title">{{ items.title }}</div>
  59. <div class="content-item">
  60. <span>{{ items.label }}</span>
  61. <span class="bolds">{{ items.value }}</span>
  62. </div>
  63. <div class="content-item">
  64. <span>{{ items.label1 }}</span>
  65. <span class="bolds">{{ items.time }}</span>
  66. </div>
  67. </div>
  68. </div>
  69. </div>
  70. <div class="echart-box">
  71. <echartLine1 :echartDataSg="echartDataSg"></echartLine1>
  72. </div>
  73. </div>
  74. </div>
  75. </template>
  76. <script lang="ts" setup>
  77. import { onMounted, ref, defineEmits, reactive, onUnmounted, watch, markRaw, defineAsyncComponent } from 'vue';
  78. import imgUrl from '../../../../../assets/images/fire/pie.png'
  79. import echartLine from './common/echartLine.vue'
  80. import echartLine1 from './common/echartLine1.vue'
  81. import { topList,pointList,echartDataGq,pointList1,contentList,echartDataSg} from '../fire.data'
  82. //光钎测温测点编号
  83. let pointCode = ref('')
  84. //束管监测-查询时间
  85. let TimeRange = reactive<any>([])
  86. //束管监测-测点编号
  87. let pointCode1 = ref('')
  88. //光钎测温测点编号选项切换
  89. function handleChange(val) {
  90. console.log(val, '光钎测温测点编号')
  91. pointCode.value = val
  92. }
  93. //束管监测-时间选项切换
  94. function onDataChange(value, dateString) {
  95. TimeRange = [dateString[0], dateString[1]]
  96. console.log(TimeRange, 'TimeRange')
  97. }
  98. //束管监测测点编号选项切换
  99. function handleChange1(val) {
  100. pointCode1.value = val
  101. }
  102. //束管实时数据选项点击
  103. function getSgClick(items) {
  104. console.log(items, '000000')
  105. // this.sgType = items.title
  106. // this.getSgjcHistoryDataList()
  107. }
  108. </script>
  109. <style lang="less" scoped>
  110. .fireWork {
  111. width: 100%;
  112. height: 100%;
  113. padding: 20px;
  114. box-sizing: border-box;
  115. .work-nav {
  116. height: 115px;
  117. width: 100%;
  118. margin-bottom: 20px;
  119. background: url('../../../../../assets/images/fire/bj1.png') no-repeat;
  120. background-size: 100% 100%;
  121. display: flex;
  122. justify-content: space-between;
  123. align-items: center;
  124. .nav {
  125. display: flex;
  126. justify-content: center;
  127. align-items: center;
  128. &:nth-child(1) {
  129. flex: 1;
  130. height: 100%;
  131. border-right: 2px solid;
  132. border-image: linear-gradient(to bottom, transparent, rgba(2, 70, 136, 1), transparent) 1 1 1;
  133. }
  134. &:nth-child(2) {
  135. flex: 1;
  136. height: 100%;
  137. border-right: 2px solid;
  138. border-image: linear-gradient(to bottom, transparent, rgba(2, 70, 136, 1), transparent) 1 1 1;
  139. }
  140. &:nth-child(3) {
  141. flex: 1;
  142. height: 100%;
  143. border-right: 2px solid;
  144. border-image: linear-gradient(to bottom, transparent, rgba(2, 70, 136, 1), transparent) 1 1 1;
  145. }
  146. &:nth-child(4) {
  147. flex: 0.6;
  148. color: #b3b8cc;
  149. font-size: 16px;
  150. height: 100%;
  151. border-right: 2px solid;
  152. border-image: linear-gradient(to bottom, transparent, rgba(2, 70, 136, 1), transparent) 1 1 1;
  153. }
  154. &:nth-child(5) {
  155. flex: 1.4;
  156. height: 100%;
  157. .percent {
  158. width: 100%;
  159. height: 94px;
  160. padding: 0px 20px;
  161. box-sizing: border-box;
  162. display: flex;
  163. flex-direction: column;
  164. justify-content: space-around;
  165. .title {
  166. font-size: 14px;
  167. padding: 5px 0px;
  168. color: #b3b8cc;
  169. text-align: center;
  170. }
  171. .value {
  172. display: flex;
  173. justify-content: space-between;
  174. span {
  175. font-family: 'douyuFont';
  176. font-size: 18px;
  177. }
  178. }
  179. }
  180. }
  181. .pic {
  182. width: 94px;
  183. height: 94px;
  184. img {
  185. width: 100%;
  186. height: 100%;
  187. }
  188. }
  189. .content {
  190. height: 94px;
  191. margin-left: 15px;
  192. color: #fff;
  193. display: flex;
  194. flex-direction: column;
  195. justify-content: space-around;
  196. span {
  197. font-size: 14px;
  198. &:nth-child(1) {
  199. padding: 5px 0px;
  200. color: #b3b8cc;
  201. }
  202. &:nth-child(2) {
  203. font-family: 'douyuFont';
  204. font-size: 24px;
  205. color: #3df6ff;
  206. }
  207. }
  208. }
  209. }
  210. .nav:nth-child(1) .pic {
  211. background: url('../../../../../assets/images/fire/max.svg') no-repeat;
  212. background-position: 50% 50%;
  213. }
  214. .nav:nth-child(2) .pic {
  215. background: url('../../../../../assets/images/fire/min.svg') no-repeat;
  216. background-position: 50% 50%;
  217. }
  218. .nav:nth-child(3) .pic {
  219. background: url('../../../../../assets/images/fire/pj.svg') no-repeat;
  220. background-position: 50% 50%;
  221. }
  222. }
  223. .center-echart {
  224. width: 100%;
  225. height: 242px;
  226. padding: 15px;
  227. margin-bottom: 20px;
  228. box-sizing: border-box;
  229. background: url('../../../../../assets/images/fire/bj1.png') no-repeat;
  230. background-size: 100% 100%;
  231. .nav-title {
  232. height: 30px;
  233. display: flex;
  234. justify-content: space-between;
  235. align-items: center;
  236. .title {
  237. font-family: 'douyuFont';
  238. font-size: 16px;
  239. color: #3df6ff;
  240. }
  241. }
  242. .echart-box {
  243. width: 100%;
  244. height: calc(100% - 30px);
  245. }
  246. }
  247. .bot-content {
  248. position: relative;
  249. width: 100%;
  250. height: calc(100% - 397px);
  251. padding: 15px 15px 0px 15px;
  252. box-sizing: border-box;
  253. background: url('../../../../../assets/images/fire/bj1.png') no-repeat;
  254. background-size: 100% 100%;
  255. .title {
  256. height: 32px;
  257. display: flex;
  258. justify-content: space-between;
  259. margin-bottom: 10px;
  260. .text {
  261. height: 32px;
  262. line-height: 32px;
  263. font-family: 'douyuFont';
  264. font-size: 16px;
  265. color: #3df6ff;
  266. }
  267. }
  268. .content {
  269. height: calc(100% - 42px);
  270. display: flex;
  271. flex-direction: column;
  272. justify-content: space-between;
  273. .box {
  274. width: 100%;
  275. height: 90px;
  276. display: flex;
  277. justify-content: space-between;
  278. .box-item {
  279. position: relative;
  280. width: 242px;
  281. height: 100%;
  282. background: url('../../../../../assets/images/fire/14174.png') no-repeat;
  283. background-size: 100% 100%;
  284. cursor: pointer;
  285. .content-title {
  286. position: absolute;
  287. left: 50%;
  288. top: 0;
  289. transform: translate(-50%);
  290. color: #fff;
  291. font-size: 16px;
  292. }
  293. .content-item {
  294. position: absolute;
  295. width: 226px;
  296. height: 24px;
  297. line-height: 24px;
  298. padding: 0px 10px;
  299. box-sizing: border-box;
  300. color: #fff;
  301. font-size: 14px;
  302. background: url('../../../../../assets/images/fire/contetn.png') no-repeat;
  303. background-size: 100% 100%;
  304. &:nth-child(2) {
  305. left: 50%;
  306. top: 26px;
  307. transform: translate(-50%);
  308. display: flex;
  309. justify-content: space-between;
  310. }
  311. &:nth-child(3) {
  312. left: 50%;
  313. top: 56px;
  314. transform: translate(-50%);
  315. display: flex;
  316. justify-content: space-between;
  317. }
  318. .bolds {
  319. font-family: 'douyuFont';
  320. color: #3df6ff;
  321. font-size: 12px;
  322. }
  323. }
  324. }
  325. }
  326. }
  327. .echart-box {
  328. position: absolute;
  329. left: 50%;
  330. top: 57px;
  331. transform: translate(-50%, 0);
  332. width: calc(100% - 514px);
  333. height: calc(100% - 57px);
  334. }
  335. }
  336. }
  337. </style>