emergencyEvacuationBig.vue 42 KB

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