nitrogenHome_blt.vue 24 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855
  1. <template>
  2. <div>{{ Math.random() }}</div>
  3. <div id="nitrogen3D" style="width: 100%; height: 100%; position: absolute; overflow: hidden"></div>
  4. <div
  5. id="nitrogenCss3D"
  6. class="threejs-Object-CSS"
  7. style="width: 100%; height: 100%; position: absolute; pointer-events: none; overflow: hidden; z-index: 2; top: 0px; left: 0px"
  8. >
  9. <a-spin :spinning="loading" />
  10. <div v-for="groupNum in monitorDataGroupNum" :key="groupNum" class="modal-monitor">
  11. <fourBorderBg :class="`kyj${groupNum}`" :id="`nitrogenMonitor${groupNum}`">
  12. <div class="title">
  13. {{ monitorData[groupNum - 1]['strname'] }}
  14. <span :style="{ color: monitorData[groupNum - 1]['AirCompressor_Status'] == '1' ? '#67fc00' : '#e9170b' }">
  15. {{ monitorData[groupNum - 1]['AirCompressor_Status'] == '1' ? '(运行)' : '(停止)' }}
  16. </span>
  17. </div>
  18. <template v-for="(preMonitor, preMonitorIndex) in preMonitorList" :key="preMonitorIndex">
  19. <div v-if="preMonitor.code !== 'signal'" class="monitor-item">
  20. <span class="monitor-title">{{ preMonitor.title }}:</span>
  21. <span class="monitor-val"
  22. ><span class="val">{{ monitorData[groupNum - 1][preMonitor.code] ? formatNum(monitorData[groupNum - 1][preMonitor.code]) : '-' }}</span
  23. ><span class="unit">{{ preMonitor.unit }}</span></span
  24. >
  25. </div>
  26. <div v-else class="signal-item">
  27. <div class="signal" v-for="(signal, childIndex) in preMonitor.child" :key="childIndex">
  28. <span class="monitor-title">{{ signal.title }}</span>
  29. <span
  30. v-if="signal.isFault !== -1"
  31. :class="{
  32. 'signal-round': true,
  33. 'signal-round-run': !signal.isFault && monitorData[groupNum - 1][preMonitor.code] == '1',
  34. 'signal-round-warning': signal.isFault && monitorData[groupNum - 1][preMonitor.code] == '1',
  35. 'signal-round-gry': monitorData[groupNum - 1][preMonitor.code] != '1',
  36. }"
  37. ></span>
  38. <span style="display: inline-block; width: 30px; text-align: center" v-else>{{
  39. monitorData[groupNum - 1][preMonitor.code] == '1' ? '加载' : monitorData[groupNum - 1][preMonitor.code] == '2' ? '卸载' : '-'
  40. }}</span>
  41. </div>
  42. </div>
  43. </template>
  44. </fourBorderBg>
  45. </div>
  46. </div>
  47. <div class="nitrogen-home">
  48. <div class="nitrogen-container">
  49. <div v-if="monitorNetStatus == 0" class="device-state">网络断开</div>
  50. <div class="top-box">
  51. <!-- 底部区域故障数据 -->
  52. <div class="footer-item-box">
  53. <div class="device-detail">
  54. <div class="device-title">&nbsp</div>
  55. <div v-for="groupNum in monitorDataGroupNum" :key="groupNum" class="device-title">
  56. {{ monitorData[groupNum - 1]['strname'] }}
  57. </div>
  58. <!-- <div class="device-val">故障</div> -->
  59. </div>
  60. <div v-for="(device, key) in deviceFault" class="device-detail" :key="key">
  61. <div class="device-title">{{ device.title }}</div>
  62. <div v-for="groupNum in monitorDataGroupNum" :key="groupNum" class="device-val">
  63. <span :style="{ color: monitorData[groupNum - 1][device.code] != '1' ? '#BFBFBF' : '#10BC79' }">{{
  64. monitorData[groupNum - 1][device.code] == '0' ? '正常' : monitorData[groupNum - 1][device.code] == '1' ? '故障' : '-'
  65. }}</span>
  66. </div>
  67. </div>
  68. </div>
  69. <!-- 左边监测数据 -->
  70. <div class="lr-box left-box">
  71. <div class="item item-l" v-for="groupNum in monitorDataGroupNum" :key="groupNum">
  72. <ventBox1>
  73. <template #title>
  74. <div>{{ monitorData[groupNum - 1]['strname'] }}</div>
  75. </template>
  76. <template #container>
  77. <div class="monitor-box">
  78. <!-- <div class="parameter-title group-parameter-title">
  79. <SvgIcon class="icon" size="38" name="device-group-paramer" /><span>机组参数</span>
  80. </div> -->
  81. <div class="monitor-item">
  82. <div class="state-item" v-for="(preFan, index) in preFanMonitorData" :key="index">
  83. <div class="state-title">{{ preFan.title + (preFan.unit !== 'signal' ? `(${preFan.unit})` : '') }}</div>
  84. <div v-if="preFan.unit !== 'signal'" class="state-val">{{
  85. monitorData[groupNum - 1][preFan.code] >= 0 ? formatNum(Number(monitorData[groupNum - 1][preFan.code])) : '-'
  86. }}</div>
  87. <div
  88. v-else
  89. :class="{
  90. 'signal-round': true,
  91. 'signal-round-warning': monitorData[groupNum - 1][preFan.code] == '1',
  92. 'signal-round-gry': monitorData[groupNum - 1][preFan.code] != '1',
  93. }"
  94. ></div>
  95. </div>
  96. </div>
  97. </div>
  98. </template>
  99. </ventBox1>
  100. </div>
  101. </div>
  102. <!-- 右边控制状态 -->
  103. <div class="lr-box right-box">
  104. <ventBox1 class="vent-margin-t-10">
  105. <template #title>
  106. <div>设备实时监测曲线</div>
  107. </template>
  108. <template #container>
  109. <BarAndLine
  110. v-if="chartsColumns.length > 0"
  111. xAxisPropType="readTime"
  112. :dataSource="echartData"
  113. height="340px"
  114. :chartsColumns="chartsColumns"
  115. :option="echatsOption"
  116. />
  117. <!-- :option="zhudanOption" -->
  118. </template>
  119. </ventBox1>
  120. </div>
  121. </div>
  122. </div>
  123. <div v-if="renderPlayer" ref="playerRef" class="player-box"></div>
  124. </div>
  125. <HandleModal :modal-is-show="modalIsShow" :modal-title="modalTitle" :modal-type="modalType" @handle-ok="handleOK" @handle-cancel="handleCancel" />
  126. </template>
  127. <script lang="ts" setup name="nitrogenHome">
  128. import { onMounted, onUnmounted, ref, watch, reactive, defineProps, nextTick, inject, computed } from 'vue';
  129. import ventBox1 from '/@/components/vent/ventBox1.vue';
  130. import fourBorderBg from '../../../comment/components/fourBorderBg.vue';
  131. import { mountedThree, destroy, setModelType, addText } from '../nitrogen.threejs';
  132. import { getDevice } from '../nitrogen.api';
  133. import { SvgIcon } from '/@/components/Icon';
  134. import BarAndLine from '/@/components/chart/BarAndLine.vue';
  135. import HandleModal from './modal.vue';
  136. import { deviceControlApi } from '/@/api/vent/index';
  137. import { preMonitorList, preFanMonitorData, deviceFault } from '../nitrogen.data.blt';
  138. import { message } from 'ant-design-vue';
  139. import lodash from 'lodash';
  140. import { formatNum } from '/@/utils/ventutil';
  141. import { getTableHeaderColumns } from '/@/hooks/web/useWebColumns';
  142. import { useCamera } from '/@/hooks/system/useCamera';
  143. const globalConfig = inject('globalConfig');
  144. const props = defineProps({
  145. deviceId: {
  146. type: String,
  147. require: true,
  148. },
  149. modalType: {
  150. type: String,
  151. require: true,
  152. },
  153. });
  154. const renderPlayer = ref(true);
  155. const playerRef = ref();
  156. const { getCamera, removeCamera } = useCamera();
  157. const refresh = ref(false);
  158. const modalTitle = ref(''); // 模态框标题显示内容,根据设备操作类型决定
  159. const modalType = ref(''); // 模态框内容显示类型,设备操作类型
  160. const modalIsShow = ref<boolean>(false); // 是否显示模态框
  161. const loading = ref(true);
  162. let kzParam = reactive<any>({
  163. data: {},
  164. isFw: null,
  165. });
  166. // const kyjs = ['1号空压机', '1号空压机', '1号空压机', '1号空压机'];
  167. const flvURL1 = () => {
  168. // return `https://sf1-hscdn-tos.pstatp.com/obj/media-fe/xgplayer_doc_video/flv/xgplayer-demo-360p.flv`;
  169. return '';
  170. };
  171. const colors = ['#FDB146', '#EE6666', '#9BCB75', '#03C2EC', '#DA3914', '#9C83D9'];
  172. const echatsOption = {
  173. grid: {
  174. top: '35%',
  175. left: '15%',
  176. right: '20px',
  177. bottom: '8%',
  178. // containLabel: true
  179. },
  180. toolbox: {
  181. feature: {},
  182. },
  183. };
  184. const monitorNetStatus = ref(0);
  185. const monitorDataGroupNum = ref(0);
  186. let airCompressorState = reactive<any[]>([]);
  187. const chartsColumns = ref(getTableHeaderColumns('sys_nitrogen_chart'));
  188. // const propTypeArr = ref([])
  189. // watch(monitorDataGroupNum, () => {
  190. // const arr = <any[]>[]
  191. // const item = getTableHeaderColumns('sys_nitrogen_chart')
  192. // const propTypeList = []
  193. // for (let i = 1; i <= monitorDataGroupNum.value; i++) {
  194. // const lineType = lodash.cloneDeep(item[0])
  195. // lineType.legend = `制氮机${i}瞬时流量`;
  196. // lineType.dataIndex = `${item[0].dataIndex}${i}`
  197. // lineType.color = colors[i - 1]
  198. // arr.push(lineType)
  199. // }
  200. // chartsColumns.value = arr
  201. // })
  202. const monitorData = ref(
  203. new Array(3).fill({
  204. // strName: '空压机',
  205. // cumulativeFlow: '-',
  206. // centerTemperature: '-',
  207. // outletTemperature: '-',
  208. // Ia: '-',
  209. // Ib: '-',
  210. // Ic: '-',
  211. // Vab: '-',
  212. // Vac: '-',
  213. // Vbc: '-',
  214. // compressGroupName: '',
  215. // compressExhaustPressF1: '-',
  216. // compressSeparatePressF1: '-',
  217. // compressHostTempF1: '-',
  218. // compressCrewTempF1: '-',
  219. // compressRunTimeF1: '-',
  220. // controlModel: 'LOC'
  221. })
  222. );
  223. //图表数据
  224. let echartData = ref<any>([]);
  225. // https获取监测数据
  226. let timer: null | NodeJS.Timeout = null;
  227. async function getMonitor(flag?) {
  228. if (Object.prototype.toString.call(timer) === '[object Null]') {
  229. timer = await setTimeout(
  230. async () => {
  231. if (props.deviceId) {
  232. await getDataSource(props.deviceId, flag);
  233. }
  234. if (timer) {
  235. timer = null;
  236. }
  237. await getMonitor();
  238. },
  239. flag ? 0 : 3000
  240. );
  241. }
  242. }
  243. async function getDataSource(systemID, flag?) {
  244. const res = await getDevice({ devicetype: 'sys', systemID, type: 'all' });
  245. console.log(res, 'res---------------');
  246. if (res) {
  247. const result = res;
  248. if (!result || result.msgTxt.length < 1) return;
  249. monitorData.value = [];
  250. result.msgTxt.forEach((item) => {
  251. if (item.type && item.type.startsWith('nitrogen')) {
  252. airCompressorState.length = 0;
  253. let netStatus = 0;
  254. const dataList: any[] = item['datalist'].filter((data) => {
  255. const readData = data.readData;
  256. if (data['netStatus'] == 1) {
  257. netStatus = 1;
  258. }
  259. airCompressorState.push({
  260. id: data.deviceID,
  261. deviceType: data.deviceType,
  262. HMIReset: readData.HMIReset,
  263. HMIStartStop: readData.HMIStartStop,
  264. });
  265. return Object.assign(data, readData);
  266. });
  267. monitorData.value.push(...dataList);
  268. monitorNetStatus.value = netStatus;
  269. }
  270. });
  271. const airCompressor = { readTime: monitorData.value[0]['readTime'].substring(11) };
  272. const dataArr = lodash.cloneDeep(echartData.value);
  273. //图表数据
  274. if (dataArr.length <= 5) {
  275. monitorData.value.forEach((el, index) => {
  276. airCompressor[`InputFlux${index + 1}`] = el['InputFlux'] || 0;
  277. });
  278. dataArr.push(airCompressor);
  279. } else {
  280. dataArr.shift();
  281. dataArr.push(airCompressor);
  282. }
  283. echartData.value = dataArr;
  284. if (flag) monitorDataGroupNum.value = monitorData.value.length;
  285. refresh.value = true;
  286. nextTick(() => {
  287. refresh.value = false;
  288. });
  289. }
  290. }
  291. function handlerDevice(data, bol) {
  292. // console.log(bol, 'bol-------')
  293. kzParam.data = data;
  294. kzParam.isFw = bol;
  295. // console.log(kzParam, 'kz--------')
  296. if (bol) {
  297. modalTitle.value = '一键复位';
  298. modalType.value = '1';
  299. modalIsShow.value = true;
  300. kzParam.data.HMIReset = !data.HMIReset;
  301. } else {
  302. modalTitle.value = '一键启停';
  303. modalType.value = '2';
  304. modalIsShow.value = true;
  305. kzParam.data.HMIStartStop = !data.HMIStartStop;
  306. }
  307. }
  308. function handleOK(passWord, handlerState) {
  309. // console.log(kzParam, 'kz----------');
  310. // if (passWord !== '123456') {
  311. // message.warning('密码不正确,请重新输入');
  312. // return;
  313. // }
  314. let data = {};
  315. if (kzParam.isFw) {
  316. data = {
  317. deviceid: kzParam.data.id,
  318. devicetype: kzParam.data.deviceType,
  319. password: passWord,
  320. HMIReset: kzParam.data.HMIReset,
  321. };
  322. } else {
  323. data = {
  324. deviceid: kzParam.data.id,
  325. password: passWord,
  326. devicetype: kzParam.data.deviceType,
  327. HMIStartStop: kzParam.data.HMIStartStop,
  328. };
  329. }
  330. deviceControlApi(data).then((res) => {
  331. // 模拟时开启
  332. if (res.success) {
  333. modalIsShow.value = false;
  334. getDataSource(props.deviceId);
  335. if (globalConfig.History_Type == 'remote') {
  336. message.success('指令已下发至生产管控平台成功!');
  337. } else {
  338. message.success('指令已下发成功!');
  339. }
  340. }
  341. });
  342. }
  343. function handleCancel() {
  344. modalIsShow.value = false;
  345. modalTitle.value = '';
  346. modalType.value = '';
  347. }
  348. watch(
  349. () => props.deviceId,
  350. async (deviceId) => {
  351. if (deviceId) {
  352. await getCamera(deviceId, playerRef, renderPlayer, 'nitrogen');
  353. getDataSource(props.deviceId, true);
  354. }
  355. }
  356. );
  357. watch([monitorDataGroupNum, loading], ([newMonitorDataGroupNum, newLoading]) => {
  358. nextTick(() => {
  359. if (newMonitorDataGroupNum && !newLoading) {
  360. setModelType(props.modalType, newMonitorDataGroupNum);
  361. }
  362. });
  363. });
  364. onMounted(async () => {
  365. await getMonitor(true);
  366. await mountedThree().then(() => {
  367. loading.value = false;
  368. });
  369. });
  370. onUnmounted(() => {
  371. destroy();
  372. if (timer) {
  373. clearTimeout(timer);
  374. timer = undefined;
  375. }
  376. });
  377. </script>
  378. <style lang="less" scoped>
  379. @ventSpace: zxm;
  380. .nitrogen-box {
  381. width: 100%;
  382. height: 100%;
  383. display: flex;
  384. justify-content: center;
  385. }
  386. #nitrogenCss3D {
  387. .modal-monitor {
  388. width: 200px;
  389. position: absolute;
  390. left: 0px;
  391. top: 0px;
  392. }
  393. &:deep(.win) {
  394. margin: 0 !important;
  395. background: #00000044;
  396. }
  397. }
  398. .nitrogen-home {
  399. width: 100%;
  400. height: 100%;
  401. position: fixed;
  402. z-index: 9999;
  403. display: flex;
  404. flex-direction: column;
  405. justify-content: center;
  406. align-items: center;
  407. pointer-events: none;
  408. top: 20px;
  409. .nitrogen-container {
  410. width: 100%;
  411. height: calc(100% - 100px);
  412. display: flex;
  413. justify-content: space-between;
  414. margin-bottom: 100px;
  415. .device-state {
  416. width: 100%;
  417. position: absolute;
  418. top: 20px;
  419. color: #e90000;
  420. display: flex;
  421. justify-content: center;
  422. font-size: 20px;
  423. }
  424. .top-box {
  425. width: 100%;
  426. padding: 10px;
  427. overflow: hidden;
  428. display: flex;
  429. justify-content: space-between;
  430. // margin-top: 40px;
  431. .footer-item-box {
  432. width: calc(100% - 20px);
  433. height: auto;
  434. position: fixed;
  435. bottom: 130px;
  436. display: flex;
  437. justify-content: center;
  438. color: #fff;
  439. // box-shadow: 0 0 30px rgb(0, 153, 184) inset;
  440. pointer-events: auto;
  441. .device-detail {
  442. text-align: center;
  443. &:first-child {
  444. background-color: #00bbff11;
  445. }
  446. &:last-child {
  447. .device-val,
  448. .device-title {
  449. border-right: 1px solid #00baffd4;
  450. }
  451. }
  452. .device-val {
  453. line-height: 36px;
  454. border-top: 1px solid #00baffd4;
  455. border-left: 1px solid #00baffd4;
  456. &:last-child {
  457. border-bottom: 1px solid #00baffd4;
  458. }
  459. }
  460. }
  461. .device-title {
  462. width: 110px;
  463. text-align: center;
  464. border-top: 1px solid #00baffd4;
  465. border-left: 1px solid #00baffd4;
  466. line-height: 36px;
  467. color: #00e5ff;
  468. background-color: #00bbff21;
  469. backdrop-filter: blur(5px);
  470. &:last-child {
  471. border-bottom: 1px solid #00baffd4;
  472. }
  473. }
  474. }
  475. .lr-box {
  476. height: 100%;
  477. display: flex;
  478. flex-direction: column;
  479. position: relative;
  480. // overflow: hidden;
  481. z-index: 9999;
  482. pointer-events: auto;
  483. overflow-y: auto;
  484. overflow-x: hidden;
  485. height: calc(100% - 70px);
  486. }
  487. .item {
  488. width: 285px;
  489. height: auto;
  490. position: relative;
  491. border-radius: 5px;
  492. margin-top: 10px;
  493. margin-bottom: 0px;
  494. pointer-events: auto;
  495. color: #fff;
  496. // overflow: hidden;
  497. &:first-child {
  498. margin-top: 0px;
  499. }
  500. .base-title {
  501. color: #fff;
  502. margin-bottom: 8px;
  503. padding-left: 10px;
  504. position: relative;
  505. font-size: 16px;
  506. &::after {
  507. content: '';
  508. position: absolute;
  509. display: block;
  510. width: 4px;
  511. height: 12px;
  512. top: 7px;
  513. left: 0px;
  514. background: #45d3fd;
  515. border-radius: 4px;
  516. }
  517. }
  518. .monitor-item {
  519. width: 100%;
  520. display: flex;
  521. flex-direction: row;
  522. flex-wrap: wrap;
  523. .state-item {
  524. width: 50%;
  525. padding: 5px;
  526. display: flex;
  527. align-items: center;
  528. justify-content: space-between;
  529. .state-title {
  530. width: 100px;
  531. color: #ffffffdd;
  532. flex: 9;
  533. font-size: 14px;
  534. .unit {
  535. // color: #ffffffbb;
  536. }
  537. }
  538. .state-val {
  539. flex: 1;
  540. color: #e4a300;
  541. margin-right: 5px;
  542. text-align: right;
  543. font-size: 14px;
  544. }
  545. }
  546. }
  547. .signal-box {
  548. margin: 5px 0;
  549. display: flex;
  550. align-items: center;
  551. .signal-title {
  552. color: #7af5ff;
  553. margin: 0 5px;
  554. }
  555. &:last-child {
  556. margin-right: 0px;
  557. }
  558. }
  559. .list-item {
  560. padding: 0 10px;
  561. display: flex;
  562. justify-content: space-between;
  563. align-items: center;
  564. .item-data-key {
  565. color: #ffffff99;
  566. }
  567. }
  568. .item-data-box {
  569. color: #fff;
  570. .state-icon {
  571. display: inline-block;
  572. width: 12px;
  573. height: 12px;
  574. border-radius: 12px;
  575. }
  576. .open {
  577. border: 5px solid #133a56;
  578. background: #4ecb73;
  579. }
  580. .close {
  581. border: 5px solid #192961;
  582. background: #6d7898;
  583. }
  584. }
  585. }
  586. .item-l {
  587. width: 100%;
  588. .monitor-box {
  589. width: 100%;
  590. .parameter-title {
  591. position: relative;
  592. width: 100%;
  593. height: 14px;
  594. margin-top: 10px;
  595. .icon,
  596. span {
  597. position: absolute;
  598. top: -10px;
  599. }
  600. }
  601. .group-parameter-title {
  602. background-image: linear-gradient(to right, #39a3ff50, #39a3ff00);
  603. .icon {
  604. left: -12px;
  605. top: -17px;
  606. }
  607. span {
  608. left: 18px;
  609. }
  610. .item-col {
  611. background-image: linear-gradient(to right, #39a3ff00, #39a3ff10);
  612. }
  613. }
  614. .device-parameter-title {
  615. background-image: linear-gradient(to right, #3df6ff40, #3df6ff00);
  616. .icon {
  617. left: -10px;
  618. top: -14px;
  619. }
  620. span {
  621. left: 18px;
  622. }
  623. .item-col {
  624. background-image: linear-gradient(to right, #3df6ff10, #3df6ff00);
  625. }
  626. }
  627. }
  628. }
  629. .right-box {
  630. width: 330px;
  631. margin-top: 50px;
  632. .control-group {
  633. display: flex;
  634. // justify-content: space-around;
  635. flex-wrap: wrap;
  636. .control-item {
  637. width: 50%; //lxh
  638. display: flex;
  639. flex-direction: column;
  640. justify-content: center;
  641. align-items: center;
  642. padding: 0 4px;
  643. .control-item-title {
  644. color: #a6dce9;
  645. position: relative;
  646. top: 5px;
  647. }
  648. .control-item-state {
  649. width: 94px;
  650. height: 47px;
  651. background: url('/@/assets/images/vent/control-switch-bg.png');
  652. display: flex;
  653. justify-content: center;
  654. align-items: center;
  655. color: #fff;
  656. }
  657. .button-box {
  658. position: relative;
  659. padding: 5px;
  660. border: 1px transparent solid;
  661. background-clip: border-box;
  662. border-radius: 5px;
  663. margin-left: 8px;
  664. }
  665. .a-button {
  666. pointer-events: auto;
  667. }
  668. &::v-deep .a-button--mini {
  669. padding: 6px 10px;
  670. }
  671. &::v-deep .a-button--mini.is-round {
  672. padding: 6px 10px;
  673. }
  674. }
  675. }
  676. }
  677. .left-box {
  678. width: 335px;
  679. margin-top: 80px;
  680. }
  681. }
  682. &:deep(.win) {
  683. width: 100%;
  684. margin: 0 !important;
  685. }
  686. }
  687. }
  688. &:deep(.main) {
  689. .title {
  690. height: 34px;
  691. text-align: center;
  692. font-weight: 600;
  693. color: #7af5ff;
  694. // background-image: url('../../../assets/img/yfj/light.png');
  695. background-repeat: no-repeat;
  696. background-position-x: center;
  697. background-position-y: 100%;
  698. background-size: 80%;
  699. font-size: 16px;
  700. }
  701. .monitor-item {
  702. width: 200px;
  703. display: flex;
  704. flex-direction: row;
  705. width: auto;
  706. margin-bottom: 3px;
  707. .monitor-val {
  708. color: #ffb700;
  709. display: flex;
  710. width: auto;
  711. .val {
  712. width: 80px;
  713. font-size: 14px;
  714. }
  715. .unit {
  716. color: #ffffffbb;
  717. font-size: 14px;
  718. }
  719. }
  720. }
  721. .monitor-title {
  722. width: 100px;
  723. color: #7af5ff;
  724. font-weight: 400;
  725. font-size: 14px;
  726. }
  727. .signal-item {
  728. display: flex;
  729. justify-content: space-between;
  730. // margin-bottom: 5px;
  731. .signal-round {
  732. display: inline-block;
  733. width: 8px;
  734. height: 8px;
  735. border-radius: 50%;
  736. margin: 0 10px;
  737. position: relative;
  738. &::after {
  739. display: block;
  740. content: '';
  741. position: absolute;
  742. width: 12px;
  743. height: 12px;
  744. top: -2px;
  745. left: -2px;
  746. border-radius: 50%;
  747. }
  748. }
  749. .signal-round-gry {
  750. background-color: #858585;
  751. &::after {
  752. background-color: #85858544;
  753. box-shadow: 0 0 1px 1px #85858599;
  754. }
  755. }
  756. .signal-round-run {
  757. background-color: #67fc00;
  758. &::after {
  759. background-color: #67fc0044;
  760. box-shadow: 0 0 1px 1px #c6ff77;
  761. }
  762. }
  763. .signal-round-warning {
  764. background-color: #e9170b;
  765. &::after {
  766. background-color: #e9170b44;
  767. box-shadow: 0 0 1px 1px #e9170b;
  768. }
  769. }
  770. }
  771. }
  772. :deep(.zxm-radio-wrapper) {
  773. color: #fff !important;
  774. }
  775. </style>