emergencyEvacuationBig.vue 50 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789
  1. <!-- 应急疏散 -->
  2. <template>
  3. <view id="emergencyEvacuationBig">
  4. <view class="setUpEvacuation" v-if="pageType == 1">
  5. <view class="evacuation-max-box">
  6. <view class="picker-max-box">
  7. <view class="picker-title-box">
  8. <view></view>
  9. <view>学院楼栋</view>
  10. </view>
  11. <picker @change="buildingChange"
  12. :range-key="'label'" :value="value" :range="buildingList">
  13. <view class="picker-min-box">
  14. <view>{{buildingName?buildingName:'请选择学院楼栋'}}</view>
  15. <img src="@/images/icon_06.png">
  16. </view>
  17. </picker>
  18. </view>
  19. <view class="picker-max-box">
  20. <view class="picker-title-box">
  21. <view></view>
  22. <view>楼层</view>
  23. </view>
  24. <picker @change="floorChange" :disabled="!buildingId"
  25. :range-key="'name'" :value="id" :range="floorList">
  26. <view class="picker-min-box">
  27. <view>{{floorName?floorName:'请选择楼层'}}</view>
  28. <img src="@/images/icon_06.png">
  29. </view>
  30. </picker>
  31. </view>
  32. <view class="picker-max-box">
  33. <view class="picker-title-box">
  34. <view></view>
  35. <view>实验室</view>
  36. </view>
  37. <picker @change="fjListChange" :disabled="!floorId"
  38. :range-key="'subjectName'" :value="id" :range="fjListArray">
  39. <view class="picker-min-box">
  40. <view>{{subName?subName:'请选择实验室'}}</view>
  41. <img src="@/images/icon_06.png">
  42. </view>
  43. </picker>
  44. </view>
  45. </view>
  46. <view class="setUpEvacuation-bottom-button" @click="confirmBtn">确认</view>
  47. </view>
  48. <view class="implementEvacuation" v-if="pageType == 2">
  49. <view class="evacuation-max-box">
  50. <!-- 头部 -->
  51. <view class="evacuation-title-box">
  52. <view class="evacuation-title-name-box">{{subName}}</view>
  53. <view class="site"><img src="@/images/icon_14.png">{{address}}</view>
  54. </view>
  55. <!-- 地图部分 -->
  56. <view class="roadmap">
  57. <view class="roadmap_t">
  58. <view class="monito_li_r_l">选择疏散路径</view>
  59. <view class="monito_li_r">
  60. <picker @change="buttonChange"
  61. :range-key="'name'" :value="id" :range="buttonArray">
  62. <view class="evacuation-title-button-box">
  63. <view :class="buttonArrayIndex?'colorB':'colorA'">{{buttonArrayIndex?buttonArray[buttonArrayIndex].name:'修改疏散路径'}}</view>
  64. <img src="@/images/icon_06.png">
  65. </view>
  66. </picker>
  67. </view>
  68. </view>
  69. <view class="evacuation-map-box">
  70. <view class="evacuation-map-big-box" :class="floorId==5?'map-1':(floorId==6?'map-2':(floorId==7?'map-3':''))">
  71. <view class="evacuation-map-min-for-box" :class="subId == item.subjectId?'evacuation-map-min-for-box-color':''"
  72. v-for="(item,index) in fjList" :key="index">{{item.room}}</view>
  73. <img class="map-min-img" src="@/images/Version2.3/icon_zjt.gif" v-show="lightList[0].type">
  74. <img class="map-min-img" src="@/images/Version2.3/icon_yjt.gif" v-show="lightList[1].type">
  75. <img class="map-min-img" src="@/images/Version2.3/icon_zjt.gif" v-show="lightList[2].type">
  76. <img class="map-min-img" src="@/images/Version2.3/icon_yjt.gif" v-show="lightList[3].type">
  77. <img class="map-min-img" src="@/images/Version2.3/icon_zjt.gif" v-show="lightList[4].type">
  78. <img class="map-min-img" src="@/images/Version2.3/icon_yjt.gif" v-show="lightList[5].type">
  79. </view>
  80. </view>
  81. </view>
  82. <!-- 一键灭火 -->
  83. <view class="outfire" v-if='outfireData.isexist'>
  84. <view class="outfire_li" v-if="outfireData.online">
  85. <img src="@/images/icon_sy_wt.png">
  86. <text style="color: #FF7B1A;">设备已离线,请及时处理。</text>
  87. </view>
  88. <view class="outfire_li" v-if="outfireData.outfireing">
  89. <img src="@/images/icon_sy_mhwc.png">
  90. <text style="color: #FF2333;">灭火中,灭火程序将于<text>{{conductCountdown}}</text>秒后结束</text>
  91. </view>
  92. <view class="outfire_li" v-if="outfireEnd">
  93. <img src="@/images/icon_sy_mhwc.png">
  94. <text style="color: #FF2333;">灭火完成,请您及时补充灭火设备耗材</text>
  95. </view>
  96. <template v-if="!outfireData.online && !outfireData.outfireing && !outfireEnd">
  97. <view class="outfire_li">
  98. <img v-if='!outfireData.smoke' src="@/images/icon_yw_zc.png">
  99. <img v-if='outfireData.smoke' src="@/images/icon_yw_yc.png">
  100. <text :class="outfireData.smoke?'abnormal':'normal'">{{outfireData.smoke?'有烟雾':'无烟雾'}}</text>
  101. </view>
  102. <view class="outfire_li">
  103. <img v-if='!outfireData.temperature' src="@/images/icon_wd_zc.png">
  104. <img v-if='outfireData.temperature' src="@/images/icon_wd_yc.png">
  105. <text :class="outfireData.temperature?'abnormal':'normal'">{{outfireData.temperature?'温度异常':'温度正常'}}</text>
  106. </view>
  107. <view class="outfire_li">
  108. <img v-if='!outfireData.fire' src="@/images/icon_hy_zc.png">
  109. <img v-if='outfireData.fire' src="@/images/icon_hy_yc.png">
  110. <text :class="outfireData.fire?'abnormal':'normal'">{{outfireData.fire?'发现火焰':'无火焰'}}</text>
  111. </view>
  112. </template>
  113. <view v-if="!outfireData.online && !outfireData.outfireing && !outfireEnd" :class="!outfireData.online?'outfire_yes_btn':'outfire_no_btn'" @click="outfireFun()">一键灭火</view>
  114. </view>
  115. <!-- 视频部分 -->
  116. <view class="video-max-box" v-if="urlList[0]">
  117. <video
  118. v-for="(item,index) in urlList" :key="index" :id="urlList.id" :src="item.url"
  119. :poster="videoCover"
  120. :custom-cache='false' :autoplay="true" :controls="true"
  121. :enable-danmu="false" :muted="true" :show-fullscreen-btn="true"
  122. :show-center-play-btn="false" :show-play-btn="false"
  123. @error="videoErrorCallback" >
  124. </video>
  125. </view>
  126. <view class="bottom-button-box">
  127. <view @click="shadeTypeClick()">语音广播</view>
  128. <view @click="lineEvacuate" v-if="isEvacuate">执行疏散</view>
  129. <view @click="closireButton" v-if="!isEvacuate">结束疏散</view>
  130. </view>
  131. </view>
  132. <!-- 语音广播-->
  133. <view class="shade-max-big-box" v-if="broadcastType">
  134. <view class="null-box" @click="shadeTypeClick()"></view>
  135. <!-- 语音广播-执行疏散 -->
  136. <view class="broadcast">
  137. <view class="broadcast_t">语音广播<label>选择喇叭位置</label></view>
  138. <!-- 按钮部分 -->
  139. <view class="trumpet-max-box">
  140. <view @click="trumpetClick(index)"
  141. class="trumpet-for-box" :class="item.type?'trumpet-color-a':'trumpet-color-b'"
  142. v-for="(item,index) in trumpetList" :key="index">
  143. <img src="@/images/icon_sskz_zc.png" v-if="!item.type">
  144. <img src="@/images/icon_sskz_xz.png" v-if="item.type">
  145. {{item.name}}
  146. </view>
  147. </view>
  148. <view class="broadcast_m">
  149. <view class="broadcast_m_t" :class="liveType?'broadcast_m_t_back_a':'broadcast_m_t_back_b'" @longpress.stop="recordButton" @touchmove.stop="cancelButton" @touchend.stop="sendButton">
  150. {{liveType?'松开发送':'按住说话'}}
  151. </view>
  152. <view class="broadcast_m_b" v-if="!liveType">按住说话,录入广播内容</view>
  153. <view class="broadcast_m_b" v-if="liveType">松开发送,向上滑动取消发送</view>
  154. </view>
  155. </view>
  156. </view>
  157. <!-- 一键灭火遮罩-->
  158. <view class="shade-outfire" v-if="dialogVisible">
  159. <view class="null-box" @click="dialogOutfire()"></view>
  160. <view class="shade-outfire-n">
  161. <img class="shade-outfire-n-t" src="@/images/icon_mh.png"/>
  162. <view class="shade-outfire-n-m">一键灭火启动中,倒计时<text>{{countdown}}</text>秒</view>
  163. <view class="shade-outfire-n-b" @click="cancelOutfire()">放弃一键灭火</view>
  164. </view>
  165. </view>
  166. </view>
  167. </view>
  168. </template>
  169. <script>
  170. import $mqtt from '@/utils/mqtt.min.js';
  171. import { config } from '@/api/request/config.js'
  172. import { lablayout,evacuate,closure,lineEvacuate,getRedis,getDeviceList,textParseUrlIps,laboratoryInfo,
  173. getCameraByFloor,lineEvacuateTow,treeselectByUser,getBuilding,getDeviceListBySub,
  174. GetStartList,firedeviceStatus,firedeviceStatusTiming,firedeviceStart} from '@/api/index.js'
  175. export default {
  176. data() {
  177. return {
  178. videoCover:uni.getStorageSync('videoCover'),
  179. //页面状态
  180. pageType:"2",
  181. deptIndex:0,
  182. //院系楼栋数据
  183. buildingList:[],
  184. buildingName:"",
  185. buildingId:"",
  186. //楼层数据
  187. floorList:[],
  188. floorName:"",
  189. floorId:"",
  190. //实验室
  191. fjListArray:[],
  192. //疏散方向
  193. buttonArray:[
  194. {name:"向左疏散",id:"1"},
  195. {name:"向右疏散",id:"2"},
  196. {name:"两侧疏散",id:"0"},
  197. ],
  198. buttonArrayIndex:"2",
  199. //视频数据
  200. urlList:[],
  201. //布局数据
  202. fjList:[],
  203. lightList:[
  204. {
  205. id:"5",
  206. type:false,
  207. },
  208. {
  209. id:"2",
  210. type:false,
  211. },
  212. {
  213. id:"3",
  214. type:false,
  215. },
  216. {
  217. id:"4",
  218. type:false,
  219. },
  220. {
  221. id:"1",
  222. type:false,
  223. },
  224. {
  225. id:"6",
  226. type:false,
  227. },
  228. ],
  229. //接收参数
  230. subId:"",
  231. subName:"",
  232. title:"",
  233. type:"",
  234. //喇叭数据
  235. trumpetList:[],
  236. //广播相关
  237. liveType:false,
  238. sendLock: true, //发送锁,当为true时上锁,false时解锁发送
  239. recorderManager : wx.getRecorderManager(),
  240. isEvacuate:true,//疏散按钮控制,当为true时候执行疏散
  241. //滑动记录
  242. startPoint:{},
  243. //摄像头信息
  244. deptId:'',
  245. itemData:{
  246. hardwareNUM:'',
  247. name:'',
  248. },
  249. broadcastType:false,
  250. address:"",
  251. videoHardwareNUM:[],//实验室和楼道摄像头编码
  252. outfireData:{},//一键灭火
  253. countdown:'',//倒计时
  254. timer2: null,//倒计时
  255. dialogVisible:false,//一键灭火弹出层
  256. conductCountdown:'',
  257. timer3: null,//倒计时
  258. outfireEnd:false,//灭火结束状态
  259. }
  260. },
  261. onLoad(option) {
  262. let self = this;
  263. //一键灭火正式使用需要注销
  264. this.itemData.subjectId=85
  265. this.firedeviceStatus();
  266. //定时请求一键灭火设备状态
  267. this.treeselectByUser(option);
  268. this.getAppExitLine();
  269. this.getAppOutfire();
  270. getApp().watch(this.getMqttLineData,'lineData');
  271. //判断入口(执行疏散)
  272. },
  273. onShow(){
  274. },
  275. onUnload(){
  276. },
  277. methods: {
  278. //根据账户信息查询学院楼栋数据
  279. async treeselectByUser(option){
  280. const {data} = await treeselectByUser()
  281. let list = [];
  282. for(let i=0;i<data.data.length;i++){
  283. for(let o=0;o<data.data[i].children.length;o++){
  284. let obj = {
  285. label:data.data[i].label+'-'+data.data[i].children[o].label,
  286. value:data.data[i].children[o].id,
  287. }
  288. list.push(obj);
  289. }
  290. }
  291. this.$set(this,'buildingList',list);
  292. this.$set(this,'buildingName',"");
  293. this.$set(this,'buildingId',"");
  294. this.$set(this,'deptId',"");
  295. this.$set(this,'floorList',[]);
  296. this.$set(this,'floorName',"");
  297. this.$set(this,'floorId',"");
  298. this.$set(this,'fjListArray',[]);
  299. this.$set(this,'subName',"");
  300. this.$set(this,'subId',"");
  301. // this.getBuilding(this.buildingId);
  302. if(option.item){
  303. let item = JSON.parse(decodeURIComponent(option.item));
  304. console.log("item",item)
  305. this.subId = item.subId;
  306. this.subName = item.subjectName;
  307. this.address = item.address
  308. this.buildingId = item.buildingId;
  309. this.deptId = item.buildingId;
  310. this.floorId = item.floorId;
  311. this.title = item.title;
  312. this.type = item.type;
  313. this.lablayout(this.buildingId,this.floorId);
  314. this.evacuateTwo();
  315. this.itemData.subjectId = item.subId;
  316. this.laboratoryInfo();
  317. this.firedeviceStatus();
  318. }else{
  319. //判断入口(首页按钮)
  320. this.getRedis();
  321. }
  322. },
  323. //一键灭火-查询设备状态
  324. async firedeviceStatus(){
  325. let _this=this;
  326. const {data} = await firedeviceStatus(_this.itemData.subjectId)
  327. if(data.code==200){
  328. _this.outfireData=data.data
  329. //灭火进行中倒计时
  330. if(_this.conductCountdown==30){
  331. _this.conductCountdown+=data.data.fireDevice.deviceCountDown
  332. _this.sendCode2()
  333. }
  334. }
  335. },
  336. //一键灭火-查询设备状态
  337. async firedeviceStatusTiming(){
  338. let _this=this;
  339. const {data} = await firedeviceStatusTiming(_this.outfireData.fireDevice.deviceCode)
  340. if(data.code==200){
  341. _this.outfireData.fire=data.data.fire
  342. _this.outfireData.online=data.data.online
  343. _this.outfireData.smoke=data.data.smoke
  344. _this.outfireData.temperature=data.data.temperature
  345. }
  346. },
  347. //启动灭火设备
  348. async firedeviceStart(){
  349. let _this=this;
  350. const {data} = await firedeviceStart(_this.itemData.subjectId)
  351. if(data.code==200){
  352. if(data.data.flg){
  353. _this.conductCountdown=30;
  354. _this.firedeviceStatus();
  355. }else{
  356. wx.showToast({
  357. title: data.data.msg,
  358. icon: "none",
  359. duration:6000
  360. });
  361. }
  362. }
  363. },
  364. //一键灭火按钮
  365. outfireFun(){
  366. let _this=this;
  367. uni.showModal({
  368. title:"是否确认执行一键灭火?",
  369. content: '该操作存在风险,请您务必确认实验室内人员已安全撤离?',
  370. cancelColor:"#999",
  371. confirmColor:"#0183FA",
  372. success: function (res) {
  373. if (res.confirm) {
  374. console.log('用户点击确定');
  375. _this.dialogVisible=true;
  376. _this.countdown=6;
  377. _this.sendCode()//倒计时
  378. } else if (res.cancel) {
  379. console.log('用户点击取消');
  380. }
  381. }
  382. });
  383. },
  384. //一键灭火弹出层关闭
  385. dialogOutfire(){
  386. this.dialogVisible=!this.dialogVisible
  387. this.clearTimer(); //关闭定时器
  388. },
  389. //取消一键灭火
  390. cancelOutfire(){
  391. this.dialogVisible=false;
  392. this.clearTimer(); //关闭定时器
  393. },
  394. //倒计时
  395. sendCode(){
  396. let _this=this;
  397. _this.loading(); //启动定时器
  398. _this.timer2 = setInterval(() =>{
  399. //创建定时器
  400. if(_this.countdown === 1){
  401. _this.clearTimer(); //关闭定时器
  402. _this.firedeviceStart();//启动灭火设备
  403. }else{
  404. _this.loading();
  405. }
  406. },1000);
  407. },
  408. loading(){
  409. //启动定时器
  410. this.countdown--; //定时器减1
  411. },
  412. clearTimer(){
  413. //清除定时器
  414. clearInterval(this.timer2);
  415. this.timer2 = null;
  416. this.dialogVisible=false;
  417. this.countdown=6;
  418. },
  419. //进行中倒计时
  420. sendCode2(){
  421. let _this=this;
  422. _this.loading2(); //启动定时器
  423. _this.timer3 = setInterval(() =>{
  424. //创建定时器
  425. if(_this.conductCountdown === 1){
  426. _this.clearTimer2(); //关闭定时器
  427. _this.outfireEnd=true;//灭火倒计时结束
  428. }else{
  429. _this.loading2();
  430. }
  431. },1000);
  432. },
  433. loading2(){
  434. //启动定时器
  435. this.conductCountdown--; //定时器减1
  436. },
  437. clearTimer2(){
  438. //清除定时器
  439. clearInterval(this.timer3);
  440. this.timer3 = null;
  441. },
  442. //根据账户信息查询学院楼栋数据
  443. async getBuilding(buildingId){
  444. const {data} = await getBuilding(buildingId)
  445. // 过滤了三楼
  446. let list = [];
  447. for(let i=0;i<data.data.length;i++){
  448. if(data.data[i].id != 7){
  449. list.push(data.data[i]);
  450. }
  451. }
  452. this.$set(this,'floorList',list);
  453. this.$set(this,'floorName',"");
  454. this.$set(this,'floorId',"");
  455. this.$set(this,'fjListArray',[]);
  456. this.$set(this,'subName',"");
  457. this.$set(this,'subId',"");
  458. },
  459. //获取实验室布局
  460. async lablayout(buildingId,floorId){
  461. console.log('buildingId',buildingId)
  462. console.log('floorId',floorId)
  463. let self = this;
  464. const {data} = await lablayout(buildingId)
  465. if(data.code == 200){
  466. for(let i=0;i<data.data.length;i++){
  467. if(data.data[i].id == floorId){
  468. let newList = [];
  469. self.fjList = data.data[i].list;
  470. for(let o=0;o<data.data[i].list.length;o++){
  471. if(data.data[i].list[o].subjectId != -1){
  472. newList.push(data.data[i].list[o]);
  473. }
  474. }
  475. this.$set(this,'fjListArray',newList);
  476. }
  477. }
  478. }
  479. },
  480. //学院楼栋选中
  481. buildingChange(e){
  482. this.$set(this,'buildingName',this.buildingList[e.detail.value].label);
  483. this.$set(this,'buildingId',this.buildingList[e.detail.value].value);
  484. this.$set(this,'deptId',this.buildingList[e.detail.value].value);
  485. this.getBuilding(this.buildingList[e.detail.value].value);
  486. },
  487. //楼层选中
  488. floorChange(e){
  489. this.$set(this,'floorName',this.floorList[e.detail.value].name);
  490. this.$set(this,'floorId',this.floorList[e.detail.value].id);
  491. this.lablayout(this.buildingId,this.floorList[e.detail.value].id);
  492. },
  493. //实验室选择
  494. fjListChange(e){
  495. this.$set(this,'subName',this.fjListArray[e.detail.value].subjectName);
  496. this.$set(this,'subId',this.fjListArray[e.detail.value].subjectId);
  497. this.itemData.name=this.fjListArray[e.detail.value].subjectName
  498. this.itemData.floorId=this.fjListArray[e.detail.value].floorId
  499. this.itemData.id=this.fjListArray[e.detail.value].id
  500. this.itemData.subjectId=this.fjListArray[e.detail.value].subjectId
  501. },
  502. getAppExitLine(){
  503. let list = [{type:"lab/exit/line"}];
  504. getApp().appMqttOn(1,list);
  505. },
  506. getAppOutfire(){
  507. let list = [{type:"lab/fireDevice/Warn/"}];
  508. getApp().appMqttOn(1,list);
  509. },
  510. shadeTypeClick(){
  511. this.broadcastType = !this.broadcastType
  512. },
  513. async evacuateTwo(){
  514. const {data} = await lineEvacuateTow(this.subId,0)
  515. if(data.code == 200){
  516. if(data.data){
  517. this.pageType = 2;
  518. uni.showToast({
  519. title: '执行成功',
  520. icon:"none",
  521. mask:true,
  522. duration: 2000
  523. });
  524. this.initialization(data.data);
  525. }
  526. }
  527. },
  528. //获取实验室摄像头
  529. async laboratoryInfo(){
  530. let _this = this;
  531. const {data} = await laboratoryInfo(_this.itemData.subjectId);
  532. if(data.code == 200){
  533. let list = data.data[0];
  534. list.labHardwareVOList.forEach(function(item){
  535. if(item.hardwareTypeEnum.enumName=='VIDEO_MONITOR'){
  536. console.log(item.hardwareNUM)
  537. _this.videoHardwareNUM.push(item.hardwareNUM)
  538. }
  539. })
  540. this.getCameraByFloor();
  541. }
  542. },
  543. //获取楼层摄像头列表
  544. async getCameraByFloor(){
  545. let _this=this;
  546. const {data} = await getCameraByFloor({floorId:this.floorId})
  547. if(data.code == 200){
  548. if(data.data[0]){
  549. let list=_this.videoHardwareNUM.concat(data.data)
  550. let qc=[]
  551. for(var i = 0; i < list.length-1; i++){
  552. for(var j = i+1; j < list.length; j++){
  553. if(list[i]===list[j]){
  554. list.splice(j,1);
  555. j--;
  556. }
  557. }
  558. }
  559. this.GetStartList(list);
  560. }else{
  561. this.GetStartList(_this.videoHardwareNUM);
  562. }
  563. }
  564. },
  565. async GetStartList(rows){
  566. let self = this;
  567. let list = "";
  568. for(let i=0;i<rows.length;i++){
  569. list = list + rows[i]+","
  570. }
  571. let obj = {
  572. page:"1",
  573. count:"100",
  574. deviceIds:list,
  575. };
  576. const {data} = await GetStartList(obj)
  577. if(data.code == 200){
  578. let list = [];
  579. for(let i=0;i<data.data.length;i++){
  580. let text = uni.getStorageSync('cameraUrl');
  581. let url = data.data[i].result.body.data.hls;
  582. url = url.split("rtp/");
  583. let newUrl = text+'rtp/'+url[1];
  584. let obj = {
  585. name:"楼道监控"+(i+1),
  586. id:data.data[i].result.body.data.deviceID,
  587. url:newUrl,
  588. }
  589. list.push(obj)
  590. }
  591. this.urlList = list;
  592. }
  593. },
  594. //点击选择喇叭
  595. trumpetClick(index){
  596. this.trumpetList[index].type = !this.trumpetList[index].type
  597. let _this=this;
  598. if(_this.trumpetList[index].type==true){
  599. _this.trumpetList.forEach(function(item2) {
  600. if(item2.deviceSn==_this.trumpetList[index].deviceSn){
  601. item2.type=true
  602. }else{
  603. item2.type=false
  604. }
  605. })
  606. }
  607. },
  608. //录制
  609. recordButton(e){
  610. console.log("按下")
  611. let self = this;
  612. let num = 0;
  613. for(let i=0;i<self.trumpetList.length;i++){
  614. if(self.trumpetList[i].type){
  615. num++
  616. }
  617. }
  618. if(num == 0){
  619. uni.showToast({
  620. title: '请选择喇叭',
  621. icon:"none",
  622. mask:true,
  623. duration: 2000
  624. });
  625. return
  626. }
  627. this.liveType=true;
  628. console.log('录制',e)
  629. this.startPoint = e.touches[0];//记录长按时开始点信息,后面用于计算上划取消时手指滑动的距离。
  630. const options = {
  631. duration: 10000,
  632. sampleRate: 16000,
  633. numberOfChannels: 1,
  634. encodeBitRate: 48000,
  635. format: 'mp3',
  636. frameSize: 50
  637. }
  638. this.recorderManager.start(options);//开始录音
  639. this.recorderManager.onStart(() => {
  640. console.log('recorder start')
  641. })
  642. this.recorderManager.onError((res) => {
  643. console.log(res);
  644. })
  645. wx.showToast({
  646. title: "正在录音,上划取消发送",
  647. icon: "none",
  648. duration: 60000//先定义个60秒,后面可以手动调用wx.hideToast()隐藏
  649. });
  650. this.sendLock = false;//长按时是不上锁的。
  651. },
  652. //取消
  653. cancelButton(e){
  654. console.log("移动")
  655. let self = this;
  656. let num = 0;
  657. for(let i=0;i<self.trumpetList.length;i++){
  658. if(self.trumpetList[i].type){
  659. num++
  660. }
  661. }
  662. if(num == 0){
  663. return
  664. }
  665. this.liveType=false;
  666. console.log('取消',e)
  667. let moveLenght = e.touches[e.touches.length - 1].clientY - this.startPoint.clientY; //移动距离
  668. if (Math.abs(moveLenght) > 50) {
  669. wx.showToast({
  670. title: "松开手指,取消发送",
  671. icon: "none",
  672. duration: 60000
  673. });
  674. this.sendLock = true;//触发了上滑取消发送,上锁
  675. } else {
  676. wx.showToast({
  677. title: "正在录音,上划取消发送",
  678. icon: "none",
  679. duration: 60000
  680. });
  681. this.sendLock = false;//上划距离不足,依然可以发送,不上锁
  682. }
  683. },
  684. //发送
  685. sendButton(e){
  686. console.log("松开")
  687. let self = this;
  688. let num = 0;
  689. for(let i=0;i<self.trumpetList.length;i++){
  690. if(self.trumpetList[i].type){
  691. num++
  692. }
  693. }
  694. if(num == 0){
  695. return
  696. }
  697. this.liveType=false;
  698. console.log('发送',e)
  699. wx.hideToast();//结束录音、隐藏Toast提示框
  700. this.recorderManager.stop();//结束录音
  701. this.recorderManager.onStop((res) => {
  702. if(!this.sendLock){
  703. console.log('1', this.recorderManager)
  704. this.uploadImg(res.tempFilePath);
  705. }
  706. console.log('停止录音', res.tempFilePath)
  707. console.log("sendLock",this.sendLock);
  708. })
  709. },
  710. //上传MP3
  711. async uploadImg(tempFilePaths){
  712. var self = this;
  713. uni.uploadFile({
  714. url: config.base_url+'/file/upload', //仅为示例,非真实的接口地址
  715. header:{'Authorization':uni.getStorageSync('token')},
  716. filePath: tempFilePaths,
  717. name: 'file',
  718. formData: {
  719. 'user': 'test'
  720. },
  721. success: (uploadFileRes) => {
  722. let res = JSON.parse(uploadFileRes.data);
  723. if(res.code == 200){
  724. console.log("上传成功",res)
  725. self.textParseUrlIps(config.base_url+ '/' +res.data.url);
  726. }else{
  727. uni.showToast({
  728. title: res.msg,
  729. icon:"none",
  730. mask:true,
  731. duration: 2000
  732. });
  733. }
  734. },
  735. fail: err => {
  736. uni.hideLoading()
  737. },
  738. complete: () => {
  739. }
  740. });
  741. },
  742. //发送语音
  743. async textParseUrlIps(text){
  744. let self = this;
  745. let newList = [];
  746. for(let i=0;i<self.trumpetList.length;i++){
  747. if(self.trumpetList[i].type){
  748. let obj = {
  749. sn:self.trumpetList[i].deviceSn,
  750. port:self.trumpetList[i].port,
  751. deviceIp:self.trumpetList[i].deviceIp,
  752. type:"",
  753. name:"",
  754. speed:"",
  755. params:{
  756. tid:"",
  757. vol:self.trumpetList[i].deviceVol,
  758. urls:[]
  759. }
  760. };
  761. newList.push(obj);
  762. }
  763. }
  764. const {data} = await textParseUrlIps(newList,text)
  765. if(data.code == 200){
  766. uni.showToast({
  767. title: '发送成功',
  768. icon:"none",
  769. mask:true,
  770. duration: 2000
  771. });
  772. }
  773. },
  774. //监听应急疏散数据变更
  775. getMqttLineData(val){
  776. console.log('收到疏散MQTT')
  777. let self = this;
  778. if(val.EXIT_LINE_MESSAGE){
  779. console.log('数据改变')
  780. this.evacuate();
  781. }else{
  782. console.log('应急疏散已结束')
  783. uni.showToast({
  784. title: '应急疏散已结束',
  785. icon:"none",
  786. mask:true,
  787. duration: 2000
  788. });
  789. setTimeout(function(){
  790. uni.navigateBack();
  791. },2000);
  792. }
  793. },
  794. //获取当前疏散数据
  795. async getRedis(){
  796. let self = this;
  797. const {data} = await getRedis()
  798. if(data.code == 200){
  799. if(data.data){
  800. this.isEvacuate=false;
  801. this.deptId = data.data.deptId;
  802. this.buildingId = data.data.buildId;
  803. this.floorId = data.data.floorId;
  804. this.subId = data.data.subId;
  805. this.subName = data.data.subName;
  806. this.address = data.data.deptName+'-'+data.data.buildName+'-'+data.data.floorName
  807. this.lablayout(this.buildingId,this.floorId);
  808. this.evacuate();
  809. this.itemData.subjectId = data.data.subId;
  810. this.laboratoryInfo();
  811. this.firedeviceStatus();
  812. }else{
  813. this.isEvacuate=true;
  814. }
  815. }
  816. },
  817. //疏散路线选择
  818. buttonChangeTwo(e){
  819. this.buttonArrayIndex = e.detail.value;
  820. },
  821. //执行疏散
  822. async evacuate(){
  823. console.log("执行疏散")
  824. const {data} = await evacuate(this.subId)
  825. if(data.code == 200){
  826. if(data.data){
  827. this.initialization(data.data);
  828. }
  829. }
  830. },
  831. //结束疏散
  832. closireButton(){
  833. let self = this;
  834. uni.showModal({
  835. content: '确认结束疏散吗?',
  836. cancelColor:"#999",
  837. confirmColor:"#0183FA",
  838. success: function (res) {
  839. if (res.confirm) {
  840. self.closure();
  841. this.isEvacuate=true;
  842. console.log('用户点击确定');
  843. } else if (res.cancel) {
  844. console.log('用户点击取消');
  845. }
  846. }
  847. });
  848. },
  849. async closure(){
  850. const {data} = await closure(this.subId)
  851. if(data.code == 200){
  852. uni.showToast({
  853. title: '操作成功',
  854. icon:"none",
  855. mask:true,
  856. duration: 2000
  857. });
  858. setTimeout(function(){
  859. uni.navigateBack();
  860. },2000);
  861. }
  862. },
  863. buttonChange(e){
  864. this.buttonArrayIndex = e.detail.value;
  865. this.lineEvacuate();
  866. },
  867. /* 确认 */
  868. confirmBtn(){
  869. if(!this.subId){
  870. uni.showToast({
  871. title: '请选择实验室',
  872. icon:"none",
  873. mask:true,
  874. duration: 2000
  875. });
  876. return
  877. }
  878. this.address = this.buildingName+''+this.floorName
  879. this.lineEvacuateTow();
  880. this.laboratoryInfo();
  881. },
  882. /* 2.5获取疏散线路 */
  883. async lineEvacuateTow(){
  884. if(!this.buttonArrayIndex){
  885. uni.showToast({
  886. title: '请选择疏散路线',
  887. icon:"none",
  888. mask:true,
  889. duration: 2000
  890. });
  891. return
  892. }
  893. const {data} = await lineEvacuateTow(this.subId,this.buttonArray[this.buttonArrayIndex].id)
  894. if(data.code == 200){
  895. if(data.data){
  896. this.pageType = 2;
  897. uni.showToast({
  898. title: '执行成功',
  899. icon:"none",
  900. mask:true,
  901. duration: 2000
  902. });
  903. this.initialization(data.data);
  904. }
  905. }
  906. },
  907. //执行疏散
  908. async lineEvacuate(){
  909. if(!this.subId){
  910. uni.showToast({
  911. title: '请选择实验室',
  912. icon:"none",
  913. mask:true,
  914. duration: 2000
  915. });
  916. return
  917. }
  918. if(!this.buttonArrayIndex){
  919. uni.showToast({
  920. title: '请选择疏散路线',
  921. icon:"none",
  922. mask:true,
  923. duration: 2000
  924. });
  925. return
  926. }
  927. const {data} = await lineEvacuate(this.subId,this.buttonArray[this.buttonArrayIndex].id)
  928. if(data.code == 200){
  929. if(data.data){
  930. console.log('执行疏散')
  931. this.isEvacuate=false;
  932. uni.showToast({
  933. title: '执行成功',
  934. icon:"none",
  935. mask:true,
  936. duration: 2000
  937. });
  938. this.initialization(data.data);
  939. }
  940. }
  941. },
  942. //灯初始化
  943. initialization(list){
  944. console.log('灯数据',list);
  945. let self = this;
  946. let newList = [
  947. {
  948. id:"5",
  949. type:false,
  950. },
  951. {
  952. id:"2",
  953. type:false,
  954. },
  955. {
  956. id:"3",
  957. type:false,
  958. },
  959. {
  960. id:"4",
  961. type:false,
  962. },
  963. {
  964. id:"1",
  965. type:false,
  966. },
  967. {
  968. id:"6",
  969. type:false,
  970. },
  971. ];
  972. for(let i=0;i<list.length;i++){
  973. for(let o=0;o<newList.length;o++){
  974. if(list[i].lightId == newList[o].id){
  975. newList[o].type = true;
  976. }
  977. }
  978. }
  979. this.lightList = newList;
  980. console.log('灯数据改变',this.lightList);
  981. this.pageType = 2;
  982. this.$forceUpdate();
  983. this.getDeviceList();
  984. },
  985. async getDeviceList(){
  986. let obj ={
  987. subId:this.itemData.subjectId,
  988. floorId:this.floorId,
  989. page:1,
  990. pageSize:100,
  991. };
  992. const {data} = await getDeviceListBySub(obj)
  993. if(data.code == 200){
  994. for(let i=0;i<data.data.length;i++){
  995. data.data[i].type = false;
  996. }
  997. this.$set(this,'trumpetList',data.data)
  998. }
  999. },
  1000. //摄像头切换
  1001. scrollBoxClick(index){
  1002. this.videoIndex = index;
  1003. },
  1004. },
  1005. beforeDestroy(){
  1006. //断开mqtt连接
  1007. getApp().offMQTT();
  1008. //删除应急疏散监听
  1009. getApp().deleteLineData();
  1010. }
  1011. }
  1012. </script>
  1013. <style lang="stylus" scoped>
  1014. #emergencyEvacuationBig{
  1015. height:100%;
  1016. width:100%;
  1017. display:flex;
  1018. flex-direction:column;
  1019. overflow-y:scroll;
  1020. .setUpEvacuation{
  1021. flex:1;
  1022. display:flex;
  1023. flex-direction:column;
  1024. overflow-y:scroll;
  1025. .evacuation-max-box{
  1026. width:710rpx;
  1027. margin:20rpx 20rpx;
  1028. background #fff
  1029. border-radius:20rpx;
  1030. padding:20rpx 0;
  1031. .picker-max-box{
  1032. .picker-title-box{
  1033. padding:0 20rpx;
  1034. display flex
  1035. view{
  1036. line-height:80rpx;
  1037. font-size:28rpx;
  1038. }
  1039. view:nth-child(1){
  1040. color:red;
  1041. }
  1042. view:nth-child(2){
  1043. }
  1044. view:nth-child(3){
  1045. color:#999;
  1046. }
  1047. }
  1048. .picker-min-box{
  1049. display flex;
  1050. height:80rpx;
  1051. width:667rpx;
  1052. border:1rpx solid #a2a2a2;
  1053. border-radius:10rpx;
  1054. margin:0 20rpx;
  1055. view{
  1056. flex:1;
  1057. line-height:80rpx;
  1058. padding:0 20rpx;
  1059. color:#999;
  1060. font-size:28rpx;
  1061. overflow: hidden
  1062. }
  1063. img{
  1064. width:24rpx;
  1065. height:12rpx;
  1066. margin:35rpx 23rpx;
  1067. }
  1068. }
  1069. }
  1070. }
  1071. }
  1072. .implementEvacuation{
  1073. flex:1;
  1074. display:flex;
  1075. flex-direction:column;
  1076. overflow-y:scroll;
  1077. .evacuation-max-box{
  1078. width:710rpx;
  1079. margin:20rpx 20rpx;
  1080. /* background #fff */
  1081. border-radius:20rpx;
  1082. padding:20rpx 0 30rpx;
  1083. .evacuation-title-box{
  1084. // height:150rpx;
  1085. //border-bottom:1rpx solid #dedede;
  1086. background: #FFFFFF;
  1087. border-radius: 20rpx;
  1088. padding:34rpx 22rpx;
  1089. box-sizing :border-box;
  1090. .evacuation-title-name-box{
  1091. font-size: 30rpx;
  1092. font-family: PingFang SC;
  1093. font-weight: 500;
  1094. color: #333333;
  1095. line-height: 30rpx;
  1096. }
  1097. .site{
  1098. font-size: 28rpx;
  1099. font-family: PingFang SC;
  1100. font-weight: 500;
  1101. color: #999999;
  1102. line-height: 30rpx;
  1103. margin-top:32rpx;
  1104. display :flex;
  1105. justify-content :flex-start;
  1106. align-items center;
  1107. >img{
  1108. width: 28rpx;
  1109. height: 30rpx;
  1110. margin-right:18rpx;
  1111. }
  1112. }
  1113. }
  1114. /* 一键灭火 */
  1115. .outfire{
  1116. width: 710rpx;
  1117. height: 80rpx;
  1118. background: #FFFFFF;
  1119. border-radius: 20rpx;
  1120. margin:20rpx 0;
  1121. padding: 0 10rpx;
  1122. box-sizing: border-box;
  1123. display: flex;
  1124. justify-content: space-between;
  1125. align-items: center;
  1126. .outfire_li{
  1127. display: flex;
  1128. justify-content: flex-start;
  1129. align-items: center;
  1130. >img{
  1131. width: 24rpx;
  1132. height: 30rpx;
  1133. margin-right: 12rpx;
  1134. }
  1135. .normal{
  1136. font-size: 24rpx;
  1137. font-family: PingFang SC;
  1138. font-weight: 500;
  1139. color: #333333;
  1140. }
  1141. .abnormal{
  1142. font-size: 24rpx;
  1143. font-family: PingFang SC;
  1144. font-weight: 500;
  1145. color: #F11C00;
  1146. }
  1147. }
  1148. .outfire_li:nth-of-type(1){
  1149. >img{
  1150. width: 30rpx;
  1151. height: 28rpx;
  1152. margin-right: 12rpx;
  1153. }
  1154. }
  1155. .outfire_yes_btn{
  1156. width: 120rpx;
  1157. height: 40rpx;
  1158. font-size: 24rpx;
  1159. font-family: PingFang SC;
  1160. font-weight: 500;
  1161. color: #F21C00;
  1162. line-height: 40rpx;
  1163. border: 1px solid #F21C00;
  1164. border-radius: 8rpx;
  1165. text-align: center;
  1166. margin-left: 54rpx;
  1167. }
  1168. .outfire_no_btn{
  1169. width: 120rpx;
  1170. height: 40rpx;
  1171. font-size: 24rpx;
  1172. font-family: PingFang SC;
  1173. font-weight: 500;
  1174. color: #CCCCCC;
  1175. line-height: 40rpx;
  1176. border: 1px solid #E0E0E0;
  1177. border-radius: 8rpx;
  1178. text-align: center;
  1179. margin-left: 54rpx;
  1180. }
  1181. }
  1182. .evacuation-scroll-box{
  1183. height:95rpx;
  1184. overflow-x scroll
  1185. overflow-y hidden
  1186. white-space:nowrap;
  1187. margin:0 20rpx;
  1188. view{
  1189. line-height:95rpx;
  1190. font-size:28rpx;
  1191. display inline-block
  1192. margin-right:45rpx;
  1193. }
  1194. .scroll-box-color{
  1195. color:#0183FA;
  1196. }
  1197. }
  1198. .evacuation-video-box{
  1199. width:668rpx;
  1200. height:341rpx;
  1201. margin:0 auto;
  1202. position relative
  1203. video{
  1204. position absolute
  1205. top:0;
  1206. left:0;
  1207. width:668rpx;
  1208. height:341rpx;
  1209. margin:0 auto;
  1210. }
  1211. .video-a{
  1212. z-index:100;
  1213. }
  1214. .video-b{
  1215. z-index:0;
  1216. }
  1217. }
  1218. /* 路线图 */
  1219. .roadmap{
  1220. width: 710rpx;
  1221. height: 464rpx;
  1222. background: #FFFFFF;
  1223. border-radius: 20rpx;
  1224. padding :20rpx 20rpx 0;
  1225. box-sizing :border-box;
  1226. margin-top :20rpx;
  1227. .roadmap_t{
  1228. font-size: 30rpx;
  1229. font-family: PingFang SC;
  1230. font-weight: 500;
  1231. color: #333333;
  1232. line-height: 30rpx;
  1233. display:flex;
  1234. .monito_li_r_l{
  1235. flex:1;
  1236. line-height:61rpx;
  1237. font-size:28rpx;
  1238. }
  1239. .monito_li_r{
  1240. width :380rpx;
  1241. font-size: 24rpx;
  1242. font-family: PingFang SC;
  1243. font-weight: 500;
  1244. color: #0183FA;
  1245. line-height: 80rpx;
  1246. display :flex;
  1247. justify-content :flex-end;
  1248. align-items center;
  1249. >img{
  1250. width: 9rpx;
  1251. height: 22rpx;
  1252. margin-left :20rpx;
  1253. }
  1254. .evacuation-title-button-box{
  1255. display flex
  1256. overflow hidden
  1257. view{
  1258. line-height:61rpx;
  1259. font-size:28rpx;
  1260. }
  1261. .colorA{
  1262. color: #0183FA;
  1263. }
  1264. .colorB{
  1265. color:#0183FA;
  1266. }
  1267. img{
  1268. margin:28rpx 20rpx 0;
  1269. width:24rpx;
  1270. height:9rpx;
  1271. }
  1272. }
  1273. }
  1274. }
  1275. .evacuation-map-box{
  1276. width:668rpx;
  1277. height:348rpx;
  1278. margin:0 auto;
  1279. overflow:hidden;
  1280. border:1rpx solid #E0E0E0;
  1281. margin-top:20rpx;
  1282. .map-1{
  1283. background:url(../images/kuangdaMap/map1.png);
  1284. .evacuation-map-min-for-box:nth-child(1){
  1285. margin:4rpx 0 0 0;
  1286. width:54rpx;
  1287. height:102rpx;
  1288. }
  1289. .evacuation-map-min-for-box:nth-child(2){
  1290. margin:4rpx 54rpx 0 0;
  1291. width:54rpx;
  1292. height:102rpx;
  1293. }
  1294. .evacuation-map-min-for-box:nth-child(3){
  1295. margin:4rpx 54rpx 0 0;
  1296. width:100rpx;
  1297. height:102rpx;
  1298. }
  1299. .evacuation-map-min-for-box:nth-child(4){
  1300. margin:4rpx 0 0 0;
  1301. width:135rpx;
  1302. height:102rpx;
  1303. }
  1304. .evacuation-map-min-for-box:nth-child(5){
  1305. margin:4rpx 0 0 0;
  1306. width:95rpx;
  1307. height:102rpx;
  1308. }
  1309. .evacuation-map-min-for-box:nth-child(6){
  1310. margin:4rpx 0 0 0;
  1311. width:54rpx;
  1312. height:102rpx;
  1313. }
  1314. .evacuation-map-min-for-box:nth-child(7){
  1315. margin:78rpx 0 0 0;
  1316. width:130rpx;
  1317. height:102rpx;
  1318. }
  1319. .evacuation-map-min-for-box:nth-child(8){
  1320. margin:78rpx 0 0 0;
  1321. width:149rpx;
  1322. height:102rpx;
  1323. }
  1324. .evacuation-map-min-for-box:nth-child(9){
  1325. margin:78rpx 0 0 0;
  1326. width:84rpx;
  1327. height:102rpx;
  1328. }
  1329. .evacuation-map-min-for-box:nth-child(10){
  1330. margin:78rpx 0 0 0;
  1331. width:84rpx;
  1332. height:102rpx;
  1333. }
  1334. .evacuation-map-min-for-box:nth-child(11){
  1335. margin:78rpx 0 0 0;
  1336. width:94rpx;
  1337. height:102rpx;
  1338. }
  1339. .evacuation-map-min-for-box:nth-child(12){
  1340. margin:78rpx 0 0 0;
  1341. width:44rpx;
  1342. height:102rpx;
  1343. }
  1344. .evacuation-map-min-for-box:nth-child(13){
  1345. margin:78rpx 0 0 0;
  1346. width:64rpx;
  1347. height:102rpx;
  1348. }
  1349. .map-min-img:nth-child(14){
  1350. top: 134rpx;
  1351. left: 80rpx;
  1352. }
  1353. .map-min-img:nth-child(15){
  1354. top: 134rpx;
  1355. left: 160rpx;
  1356. }
  1357. .map-min-img:nth-child(16){
  1358. top: 134rpx;
  1359. left:280rpx;
  1360. }
  1361. .map-min-img:nth-child(17){
  1362. top: 134rpx;
  1363. left:340rpx;
  1364. }
  1365. .map-min-img:nth-child(18){
  1366. top: 134rpx;
  1367. left:460rpx;
  1368. }
  1369. .map-min-img:nth-child(19){
  1370. top: 134rpx;
  1371. left:540rpx;
  1372. }
  1373. }
  1374. .map-2{
  1375. background:url(../images/kuangdaMap/map2.png);
  1376. .evacuation-map-min-for-box:nth-child(1){
  1377. margin:4rpx 0 0 0;
  1378. width:54rpx;
  1379. height:102rpx;
  1380. }
  1381. .evacuation-map-min-for-box:nth-child(2){
  1382. margin:4rpx 54rpx 0 0;
  1383. width:54rpx;
  1384. height:102rpx;
  1385. }
  1386. .evacuation-map-min-for-box:nth-child(3){
  1387. margin:4rpx 54rpx 0 0;
  1388. width:100rpx;
  1389. height:102rpx;
  1390. }
  1391. .evacuation-map-min-for-box:nth-child(4){
  1392. margin:4rpx 0 0 0;
  1393. width:135rpx;
  1394. height:102rpx;
  1395. }
  1396. .evacuation-map-min-for-box:nth-child(5){
  1397. margin:4rpx 0 0 0;
  1398. width:145rpx;
  1399. height:102rpx;
  1400. }
  1401. .evacuation-map-min-for-box:nth-child(6){
  1402. margin:4rpx 0 0 0;
  1403. width:106rpx;
  1404. height:102rpx;
  1405. }
  1406. .evacuation-map-min-for-box:nth-child(7){
  1407. margin:78rpx 0 0 0;
  1408. width:106rpx;
  1409. height:102rpx;
  1410. }
  1411. .evacuation-map-min-for-box:nth-child(8){
  1412. margin:78rpx 0 0 0;
  1413. width:100rpx;
  1414. height:102rpx;
  1415. }
  1416. .evacuation-map-min-for-box:nth-child(9){
  1417. margin:78rpx 0 0 0;
  1418. width:100rpx;
  1419. height:102rpx;
  1420. }
  1421. .evacuation-map-min-for-box:nth-child(10){
  1422. margin:78rpx 0 0 0;
  1423. width:92rpx;
  1424. height:102rpx;
  1425. }
  1426. .evacuation-map-min-for-box:nth-child(11){
  1427. margin:78rpx 0 0 0;
  1428. width:90rpx;
  1429. height:102rpx;
  1430. }
  1431. .evacuation-map-min-for-box:nth-child(12){
  1432. margin:78rpx 0 0 0;
  1433. width:53rpx;
  1434. height:102rpx;
  1435. }
  1436. .map-min-img:nth-child(13){
  1437. top: 134rpx;
  1438. left: 80rpx;
  1439. }
  1440. .map-min-img:nth-child(14){
  1441. top: 134rpx;
  1442. left: 160rpx;
  1443. }
  1444. .map-min-img:nth-child(15){
  1445. top: 134rpx;
  1446. left:280rpx;
  1447. }
  1448. .map-min-img:nth-child(16){
  1449. top: 134rpx;
  1450. left:340rpx;
  1451. }
  1452. .map-min-img:nth-child(17){
  1453. top: 134rpx;
  1454. left:460rpx;
  1455. }
  1456. .map-min-img:nth-child(18){
  1457. top: 134rpx;
  1458. left:540rpx;
  1459. }
  1460. }
  1461. .map-3{
  1462. background:url(../images/kuangdaMap/map3.png);
  1463. }
  1464. .evacuation-map-big-box{
  1465. height:293rpx;
  1466. width:644rpx;
  1467. // background:url(../images/Version2.3/icon_bj_syspmtcy_jinan.png);
  1468. background-size 100%
  1469. margin:28rpx 13rpx ;
  1470. position relative
  1471. .evacuation-map-min-for-box{
  1472. overflow: hidden;
  1473. display: inline-block;
  1474. line-height:70rpx;
  1475. text-align: center;
  1476. font-size:14rpx;
  1477. }
  1478. .evacuation-map-min-for-box-color{
  1479. background: rgba(0,189,255,0.3);
  1480. }
  1481. .map-min-img{
  1482. position: absolute;
  1483. width:34rpx;
  1484. height:22rpx;
  1485. }
  1486. }
  1487. }
  1488. }
  1489. .video-max-box{
  1490. width: 710rpx;
  1491. height: 780rpx;
  1492. overflow-y scroll;
  1493. background: #FFFFFF;
  1494. border-radius: 20rpx;
  1495. padding :22rpx 30rpx 30rpx;
  1496. box-sizing :border-box;
  1497. margin-top :20rpx;
  1498. margin-bottom:120rpx;
  1499. video{
  1500. width:645rpx;
  1501. height:355rpx;
  1502. }
  1503. }
  1504. .bottom-button-box{
  1505. position absolute;
  1506. bottom:20rpx;
  1507. display flex;
  1508. width:670rpx;
  1509. margin:20rpx;
  1510. view{
  1511. width:335rpx;
  1512. height:100rpx;
  1513. line-height:100rpx;
  1514. text-align center;
  1515. color:#fff;
  1516. font-size:28rpx;
  1517. }
  1518. view:nth-child(1){
  1519. border-top-left-radius :50rpx;
  1520. border-bottom-left-radius :50rpx;
  1521. background:#FF9C00;
  1522. }
  1523. view:nth-child(2){
  1524. border-top-right-radius :50rpx;
  1525. border-bottom-right-radius :50rpx;
  1526. background:#0183FA;
  1527. }
  1528. }
  1529. }
  1530. .live-button{
  1531. width:650rpx;
  1532. height:100rpx;
  1533. line-height:100rpx;
  1534. text-align center;
  1535. font-size:28rpx;
  1536. margin:50rpx auto 0;
  1537. border-radius:20rpx;
  1538. }
  1539. .live-color-a{
  1540. color:#fff;
  1541. background:#FF8686;
  1542. }
  1543. .live-color-b{
  1544. color:#fff;
  1545. background:#25C95B;
  1546. }
  1547. /* 语音广播 */
  1548. .shade-max-big-box{
  1549. height:100%;
  1550. width:100%;
  1551. position fixed
  1552. display flex;
  1553. flex-direction column
  1554. z-index:10;
  1555. background :rgba(0,0,0,0.2);
  1556. .null-box{
  1557. flex:1;
  1558. }
  1559. /* 语音广播-执行疏散 */
  1560. .broadcast{
  1561. width: 100%;
  1562. // height: 532rpx;
  1563. background: #FFFFFF;
  1564. border-top-left-radius :20rpx;
  1565. border-top-right-radius :20rpx
  1566. padding :22rpx 30rpx 30rpx;
  1567. box-sizing :border-box;
  1568. margin-top:20rpx;
  1569. .broadcast_t{
  1570. font-size: 30rpx;
  1571. font-family: PingFang SC;
  1572. font-weight: 500;
  1573. color: #333333;
  1574. line-height: 30rpx;
  1575. >label{
  1576. font-size: 24rpx;
  1577. font-family: PingFang SC;
  1578. font-weight: 500;
  1579. color: #999999;
  1580. line-height: 30rpx;
  1581. margin-left :16rpx;
  1582. }
  1583. }
  1584. .trumpet-max-box{
  1585. display :flex;
  1586. justify-content :flex-start;
  1587. margin-top :22rpx;
  1588. flex-wrap: wrap;
  1589. .trumpet-for-box{
  1590. display:inline-block;
  1591. width:200rpx;
  1592. height:60rpx;
  1593. line-height:60rpx;
  1594. font-size:24rpx;
  1595. text-align center;
  1596. cursor: pointer;
  1597. overflow: hidden;
  1598. border: 1rpx solid #E0E0E0;
  1599. border-radius:10rpx;
  1600. color: #E0E0E0;
  1601. display :flex;
  1602. justify-content :center;
  1603. margin-right :20rpx;
  1604. margin-bottom: 10rpx;
  1605. >img{
  1606. width:36rpx;
  1607. height:34rpx;
  1608. margin :12rpx 20rpx 0 25rpx;
  1609. }
  1610. }
  1611. .trumpet-color-a{
  1612. border:1px solid #0183FA;
  1613. color:#0183FA;
  1614. }
  1615. .trumpet-color-b{
  1616. border:1px solid #CCCCCC;
  1617. color:#999;
  1618. }
  1619. }
  1620. .broadcast_m{
  1621. width :100%;
  1622. .broadcast_m_t{
  1623. width: 142rpx;
  1624. height: 142rpx;
  1625. margin :30rpx 0 0 258rpx;
  1626. position :relative;
  1627. font-size: 24rpx;
  1628. font-family: PingFang SC;
  1629. font-weight: 500;
  1630. line-height: 170rpx;
  1631. text-align center
  1632. >img{
  1633. width: 142rpx;
  1634. height: 142rpx;
  1635. position :absolute;
  1636. }
  1637. >label{
  1638. width :100%;
  1639. font-size: 24rpx;
  1640. font-family: PingFang SC;
  1641. font-weight: 500;
  1642. color: #0183FA;
  1643. line-height: 24rpx;
  1644. display :inline-block;
  1645. text-align :center;
  1646. position :absolute;
  1647. top:76rpx;
  1648. }
  1649. /* 按下 */
  1650. .press_color{
  1651. color: #FFFFFF;
  1652. }
  1653. /* 松开 */
  1654. .slip_color{
  1655. color: #0183FA;
  1656. }
  1657. }
  1658. .broadcast_m_t_back_a{
  1659. background:url(@/images/icon_sskz_skfs.png);
  1660. background-size 100%
  1661. color: #FFFFFF;
  1662. }
  1663. .broadcast_m_t_back_b{
  1664. background:url(@/images/icon_sskz_azsh.png);
  1665. background-size 100%
  1666. color: #0183FA;
  1667. }
  1668. .broadcast_m_b{
  1669. font-size: 24rpx;
  1670. font-family: PingFang SC;
  1671. font-weight: 500;
  1672. color: #999999;
  1673. line-height: 24rpx;
  1674. text-align center;
  1675. margin-top :14rpx;
  1676. }
  1677. }
  1678. /* 疏散按钮 */
  1679. .evacuation-button-box{
  1680. width:650rpx;
  1681. height:100rpx;
  1682. background #0183FA
  1683. color:#fff;
  1684. text-align center;
  1685. line-height:100rpx;
  1686. font-size:28rpx;
  1687. margin:88rpx auto 0;
  1688. border-radius:20rpx;
  1689. }
  1690. }
  1691. }
  1692. /* 一键灭火 */
  1693. .shade-outfire{
  1694. height:100%;
  1695. width:100%;
  1696. position fixed
  1697. display flex;
  1698. flex-direction column
  1699. z-index:10;
  1700. background :rgba(0,0,0,0.2);
  1701. .null-box{
  1702. flex:1;
  1703. }
  1704. /* 语音广播-执行疏散 */
  1705. .shade-outfire-n{
  1706. width: 625rpx;
  1707. height: 450rpx;
  1708. background: #FFFFFF;
  1709. border-radius: 20rpx;
  1710. position: absolute;
  1711. top: 370rpx;
  1712. left: 62rpx;
  1713. .shade-outfire-n-t{
  1714. width: 172rpx;
  1715. height: 172rpx;
  1716. margin: 38rpx 0 0 226rpx;
  1717. }
  1718. .shade-outfire-n-m{
  1719. font-size: 30rpx;
  1720. font-family: PingFang SC;
  1721. font-weight: 500;
  1722. color: #E30000;
  1723. line-height: 84rpx;
  1724. text-align: center
  1725. border-bottom: 1px solid #E0E0E0;
  1726. >text{
  1727. font-size: 40rpx;
  1728. }
  1729. }
  1730. .shade-outfire-n-b{
  1731. width: 402rpx;
  1732. height: 82rpx;
  1733. background: #FFFFFF;
  1734. border: 2rpx solid #0183FA;
  1735. border-radius: 10rpx;
  1736. font-size: 28rpx;
  1737. line-height: 82rpx;
  1738. font-family: PingFang SC;
  1739. font-weight: 500;
  1740. color: #0183FA;
  1741. text-align: center;
  1742. margin: 30rpx 0 0 112rpx;
  1743. }
  1744. }
  1745. }
  1746. }
  1747. .setUpEvacuation-bottom-button{
  1748. width:650rpx;
  1749. height:100rpx;
  1750. background #0183FA
  1751. color:#fff;
  1752. text-align center;
  1753. line-height:100rpx;
  1754. font-size:28rpx;
  1755. margin:50rpx auto;
  1756. border-radius:20rpx;
  1757. }
  1758. }
  1759. </style>