emergencyEvacuationBig.vue 49 KB

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