forest.vue 63 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501
  1. <!--可视化公共模板 林业-->
  2. <template>
  3. <div class="visual-con">
  4. <!--头部-->
  5. <vheader></vheader>
  6. <!--主体-->
  7. <div class="visual-body">
  8. <!-- 左侧 -->
  9. <div class="leftbar" ref="left">
  10. <!-- 1 通知公告 -->
  11. <div class="forthis">
  12. <dv-border-box-13 backgroundColor="rgba(12, 19, 38, .90)" style="padding-bottom: 1rem;">
  13. <img src="../assets/images/integrated/light.png" style="width: 100%; margin-top: .4rem;"/>
  14. <div class="this-title">
  15. <span>通知公告</span>
  16. <dv-decoration-3 style="width:150px;height:15px;margin-right: 1rem;"/>
  17. </div>
  18. <div class="i-list-con h-14">
  19. <div class="d-l-con no_hover">
  20. <div class="d-l-l-text w-100p no-weight">
  21. <h4 class="line-h-1 w-100p" v-html="noticeContent">{{ noticeContent }}</h4>
  22. </div>
  23. </div>
  24. </div>
  25. </dv-border-box-13>
  26. </div>
  27. <!-- 2 事件统计-->
  28. <div class="forthis">
  29. <dv-border-box-13 backgroundColor="rgba(12, 19, 38, .90)" style="padding-bottom: 1rem;">
  30. <img src="../assets/images/integrated/light.png" style="width: 100%; margin-top: .4rem;"/>
  31. <div class="i-list-con h-29-5">
  32. <div class="d-l-con no_hover">
  33. <div class="event-count">
  34. <div class="count-number">{{ totalStr.charAt(0) }}</div>
  35. <div class="count-number">{{ totalStr.charAt(1) }}</div>
  36. <div class="count-number">{{ totalStr.charAt(2) }}</div>
  37. <div class="count-number">{{ totalStr.charAt(3) }}</div>
  38. <div class="count-number">{{ totalStr.charAt(4) }}</div>
  39. <div class="count-number">{{ totalStr.charAt(5) }}</div>
  40. <dv-decoration-5
  41. style="width:81%;height:15px;position: absolute; top:4.2rem;z-index: 0; "/>
  42. </div>
  43. </div>
  44. <div class="d-l-con-icon no_hover">
  45. <div class="icon-con w-33 flex-d t-a-center">
  46. <dv-decoration-9
  47. style="width: 5.5rem;height: 5.5rem; color:#16e29e;font-size: 1rem;font-weight: bolder;">
  48. {{ newReport_pre }}%
  49. </dv-decoration-9>
  50. <div class="e-state"
  51. :style="{'background-image':`url(${require('@/assets/images/integrated/state-bg.png')})`}">
  52. <span>新上报</span> <span>{{ newReport }}</span>
  53. </div>
  54. </div>
  55. <div class="icon-con w-33 flex-d t-a-center">
  56. <dv-decoration-9
  57. style="width: 5.5rem;height: 5.5rem; color:#f18425;font-size: 1rem;font-weight: bolder;">
  58. {{ readySure_pre }}%
  59. </dv-decoration-9>
  60. <div class="e-state"
  61. :style="{'background-image':`url(${require('@/assets/images/integrated/state-bg.png')})`}">
  62. <span>处理中</span> <span>{{ readySure }}</span>
  63. </div>
  64. </div>
  65. <div class="icon-con w-33 flex-d t-a-center">
  66. <dv-decoration-9
  67. style="width: 5.5rem;height: 5.5rem; color:#9179f1;font-size: 1rem;font-weight: bolder;">
  68. {{ readyFinish_pre }}%
  69. </dv-decoration-9>
  70. <div class="e-state"
  71. :style="{'background-image':`url(${require('@/assets/images/integrated/state-bg.png')})`}">
  72. <span>已完成</span> <span>{{ readyFinish }}</span>
  73. </div>
  74. </div>
  75. </div>
  76. <div class="d-l-con no_hover">
  77. <div id="chart-event-ai" style="width: 100%;height:6vh;"></div>
  78. </div>
  79. </div>
  80. </dv-border-box-13>
  81. </div>
  82. <!-- 3 组织机构 -->
  83. <div class="forthis">
  84. <dv-border-box-13 backgroundColor="rgba(12, 19, 38, .90)" style="padding-bottom: 1rem;">
  85. <img src="../assets/images/integrated/light.png" style="width: 100%; margin-top: .4rem;"/>
  86. <div class="i-list-con h-27">
  87. <div class="d-l-con " v-for="(item,index) in forestFarm" :key="index" :class="{on:listCurrentIndex1==item.deptId}"
  88. v-on:click="selectCameraByDeptId(item.deptId)">
  89. <div class="d-l-l-text">
  90. <i class="i-small"></i>
  91. <h4 >{{ item.deptName }}</h4>
  92. </div>
  93. <div class="d-l-l-count">{{ item.eventCount }}</div>
  94. </div>
  95. </div>
  96. </dv-border-box-13>
  97. </div>
  98. </div>
  99. <!-- 地图 -->
  100. <supermap ref="supermap" style="width: 100%;height: 100vh;" @showEventDialog="showEventDialog" :showLayer="true" @fatherMethod="fatherMethod"></supermap>
  101. <!-- 右侧 -->
  102. <div class="rightbar rightbar-index" ref="right">
  103. <div class="right-item1">
  104. <!-- 天气 -->
  105. <div class="forthis">
  106. <dv-border-box-13 backgroundColor="rgba(12, 19, 38, .90)" >
  107. <img src="../assets/images/integrated/light.png" style="width: 100%; margin-top: .4rem;"/>
  108. <div class="i-list-con small-bottom-margin h-18">
  109. <el-row :gutter="20" v-if="todatWeather">
  110. <el-col :span="9">
  111. <div class="weather-img">
  112. <img v-if="weatherinformationWeather==1"
  113. src="../assets/images/integrated/weather/qing-1.png">
  114. <img v-if="weatherinformationWeather==2"
  115. src="../assets/images/integrated/weather/duoyun-2.png">
  116. <img v-if="weatherinformationWeather==3"
  117. src="../assets/images/integrated/weather/yin-3.png">
  118. <img v-if="weatherinformationWeather==4"
  119. src="../assets/images/integrated/weather/zhenyu-4.png">
  120. <img v-if="weatherinformationWeather==5"
  121. src="../assets/images/integrated/weather/leizhenyu-5.png">
  122. <img v-if="weatherinformationWeather==6"
  123. src="../assets/images/integrated/weather/leizhenyubingbao-6.png">
  124. <img v-if="weatherinformationWeather==7"
  125. src="../assets/images/integrated/weather/yujiaxue-7.png">
  126. <img v-if="weatherinformationWeather==8"
  127. src="../assets/images/integrated/weather/xiaoyu-8.png">
  128. <img v-if="weatherinformationWeather==9||weatherinformationWeather==22"
  129. src="../assets/images/integrated/weather/zhongyu-9.png">
  130. <img v-if="weatherinformationWeather==10||weatherinformationWeather==23"
  131. src="../assets/images/integrated/weather/dayu-10.png">
  132. <img v-if="weatherinformationWeather==11||weatherinformationWeather==24"
  133. src="../assets/images/integrated/weather/baoyu-11.png">
  134. <img v-if="weatherinformationWeather==12||weatherinformationWeather==25"
  135. src="../assets/images/integrated/weather/dabaoyu-12.png">
  136. <img v-if="weatherinformationWeather==13||weatherinformationWeather==26"
  137. src="../assets/images/integrated/weather/tedabaoyu-13.png">
  138. <img v-if="weatherinformationWeather==14"
  139. src="../assets/images/integrated/weather/zhenxue-14.png">
  140. <img v-if="weatherinformationWeather==15"
  141. src="../assets/images/integrated/weather/xiaoxue-15.png">
  142. <img v-if="weatherinformationWeather==16||weatherinformationWeather==27"
  143. src="../assets/images/integrated/weather/zhongxue-16.png">
  144. <img v-if="weatherinformationWeather==17||weatherinformationWeather==28"
  145. src="../assets/images/integrated/weather/daxue-17.png">
  146. <img v-if="weatherinformationWeather==18||weatherinformationWeather==29"
  147. src="../assets/images/integrated/weather/baoxue-18.png">
  148. <img v-if="weatherinformationWeather==19"
  149. src="../assets/images/integrated/weather/wu-19.png">
  150. <img v-if="weatherinformationWeather==20"
  151. src="../assets/images/integrated/weather/dongyu-20.png">
  152. <img v-if="weatherinformationWeather==21"
  153. src="../assets/images/integrated/weather/shachenbao-21.png">
  154. <img v-if="weatherinformationWeather==30"
  155. src="../assets/images/integrated/weather/fuchen-30.png">
  156. <img v-if="weatherinformationWeather==31"
  157. src="../assets/images/integrated/weather/yangsha-31.png">
  158. <img v-if="weatherinformationWeather==32"
  159. src="../assets/images/integrated/weather/qiangshachenbao-32.png">
  160. <span v-if="weatherinformationWeather==1">晴</span>
  161. <span v-if="weatherinformationWeather==2">多云</span>
  162. <span v-if="weatherinformationWeather==3">阴</span>
  163. <span v-if="weatherinformationWeather==4">阵雨</span>
  164. <span v-if="weatherinformationWeather==5">雷阵雨</span>
  165. <span v-if="weatherinformationWeather==6">雷阵雨伴有冰雹</span>
  166. <span v-if="weatherinformationWeather==7">雨夹雪</span>
  167. <span v-if="weatherinformationWeather==8">小雨</span>
  168. <span v-if="weatherinformationWeather==9">中雨</span>
  169. <span v-if="weatherinformationWeather==10">大雨</span>
  170. <span v-if="weatherinformationWeather==11">暴雨</span>
  171. <span v-if="weatherinformationWeather==12">大暴雨</span>
  172. <span v-if="weatherinformationWeather==13">特大暴雨</span>
  173. <span v-if="weatherinformationWeather==14">阵雪</span>
  174. <span v-if="weatherinformationWeather==15">小雪</span>
  175. <span v-if="weatherinformationWeather==16">中雪</span>
  176. <span v-if="weatherinformationWeather==17">大雪</span>
  177. <span v-if="weatherinformationWeather==18">暴雪</span>
  178. <span v-if="weatherinformationWeather==19">雾</span>
  179. <span v-if="weatherinformationWeather==20">冻雨</span>
  180. <span v-if="weatherinformationWeather==21">沙尘暴</span>
  181. <span v-if="weatherinformationWeather==22">小雨—中雨</span>
  182. <span v-if="weatherinformationWeather==23">中雨—大雨</span>
  183. <span v-if="weatherinformationWeather==24">大雨—暴雨</span>
  184. <span v-if="weatherinformationWeather==25">暴雨—大暴雨</span>
  185. <span v-if="weatherinformationWeather==26">大暴雨—特大暴雨</span>
  186. <span v-if="weatherinformationWeather==27">小雪—中雪</span>
  187. <span v-if="weatherinformationWeather==28">中雪—大雪</span>
  188. <span v-if="weatherinformationWeather==29">大雪—暴雪</span>
  189. <span v-if="weatherinformationWeather==30">浮尘</span>
  190. <span v-if="weatherinformationWeather==31">扬沙</span>
  191. <span v-if="weatherinformationWeather==32">强沙尘暴</span>
  192. </div>
  193. </el-col>
  194. <el-col :span="15">
  195. <div class="weather-info">
  196. <ul>
  197. <li>风力:{{ weatherinformationPower }}级</li>
  198. <li>低温:{{ weatherinformationLow }}℃</li>
  199. <li v-if="weatherinformationDirection==1">风向:东风</li>
  200. <li v-if="weatherinformationDirection==2">风向:东南风</li>
  201. <li v-if="weatherinformationDirection==3">风向:南风</li>
  202. <li v-if="weatherinformationDirection==4">风向:西南风</li>
  203. <li v-if="weatherinformationDirection==5">风向:西风</li>
  204. <li v-if="weatherinformationDirection==6">风向:西北风</li>
  205. <li v-if="weatherinformationDirection==7">风向:北风</li>
  206. <li v-if="weatherinformationDirection==8">风向:东北风</li>
  207. <li>高温:{{ weatherinformationHigh }}℃</li>
  208. <li>火险:{{ weatherinformationLevelValue }}
  209. </li>
  210. <li>湿度:{{ weatherinformationTemperature }}</li>
  211. </ul>
  212. </div>
  213. </el-col>
  214. </el-row>
  215. <el-row :gutter="20" v-else>
  216. <el-col :span="24">
  217. <div class="weather-img">
  218. 暂无天气信息!
  219. </div>
  220. </el-col>
  221. </el-row>
  222. <div class="firestate" v-if="todatWeather">
  223. <div
  224. :class="weatherinformationLevel=='forest_weatherinformation_level_1'? 'state-block1 state-on':'state-block1'">
  225. </div>
  226. <div
  227. :class="weatherinformationLevel=='forest_weatherinformation_level_2'? 'state-block2 state-on':'state-block2'">
  228. </div>
  229. <div
  230. :class="weatherinformationLevel=='forest_weatherinformation_level_3'? 'state-block3 state-on':'state-block3'">
  231. </div>
  232. <div
  233. :class="weatherinformationLevel=='forest_weatherinformation_level_4'? 'state-block4 state-on':'state-block4'">
  234. </div>
  235. <div
  236. :class="weatherinformationLevel=='forest_weatherinformation_level_5'? 'state-block5 state-on':'state-block5'">
  237. </div>
  238. </div>
  239. </div>
  240. </dv-border-box-13>
  241. </div>
  242. <!-- 曝光台 -->
  243. <div class="forthis">
  244. <dv-border-box-13 backgroundColor="rgba(12, 19, 38, .90)" style="padding-bottom: 1rem;">
  245. <img src="../assets/images/integrated/light.png" style="width: 100%; margin-top: .4rem;"/>
  246. <div class="this-title">
  247. <span>超期事件</span>
  248. <dv-decoration-3 style="width:150px;height:15px;margin-right: 1rem;"/>
  249. </div>
  250. <div class="i-list-con small-bottom-margin h-18">
  251. <div class="d-l-con padding-box nowrap" v-for="(item,index) in exposureStageList">
  252. <div class="bgt-state">
  253. <div class="bgt-state-frequency">{{ item.urgeCount }}</div>
  254. <div class="bgt-state-minute">{{ item.timeDiff }}分钟</div>
  255. </div>
  256. <div class="bgt-info">
  257. <div class="bgt-info-name">{{ item.eventName }}</div>
  258. <div class="bgt-info-place">
  259. <ul>
  260. <li>{{ item.deptNames }}</li>
  261. </ul>
  262. </div>
  263. </div>
  264. </div>
  265. </div>
  266. </dv-border-box-13>
  267. </div>
  268. <!-- 事件列表 -->
  269. <div class="forthis">
  270. <dv-border-box-13 backgroundColor="rgba(12, 19, 38, .90)" style="padding-bottom: 1rem;">
  271. <img src="../assets/images/integrated/light.png" style="width: 100%; margin-top: .4rem;"/>
  272. <div class="this-title">
  273. <span>事件列表</span>
  274. <dv-decoration-3 style="width:150px;height:15px;margin-right: 1rem;"/>
  275. </div>
  276. <div class="sj-search">
  277. <el-input placeholder="请输入内容" prefix-icon="el-icon-search" v-model="eventSearch"
  278. @change="getEventList(calendarDay,10,1,eventSearch)">
  279. </el-input>
  280. </div>
  281. <div class="i-list-con small-bottom-margin" style="height: 24vh;">
  282. <div class="d-l-con padding-box nowrap" v-for="(item,index) in eventList"
  283. @click="dropLocation(item.latitude,item.longitude,item.eventCode)" data-html2canvas-ignore>
  284. <div class="bgt-img">
  285. <img v-if="item.picturePath!=null&&item.picturePath!=''&& item.pictureType=='image'"
  286. :src="item.picturePath" style="width: 93px;height: 64px" loading="lazy" @error="showDefaultImg"/>
  287. <img v-else-if="item.eventType == '601'"
  288. src="../assets/images/大气监测.png"
  289. style="width: 93px;height: 64px"/>
  290. <img v-else-if="item.eventType == '602'"
  291. src="../assets/images/水质监测.png"
  292. style="width: 93px;height: 64px"/>
  293. <img v-else src="../assets/images/integrated/event-img-sub.png"
  294. style="width: 93px;height: 64px"/>
  295. </div>
  296. <div class="bgt-info">
  297. <div v-if="item.eventStatusValue=='forest_event_status_1'&&item.urgeCount==0"
  298. class="event-state-sb">
  299. <i class="el-icon-caret-left"></i>
  300. <div class="event-list-state-sb">
  301. 新上报
  302. </div>
  303. </div>
  304. <div v-if="item.eventStatusValue=='forest_event_status_1'&&item.urgeCount>0"
  305. class="event-state-cb">
  306. <i class="el-icon-caret-left"></i>
  307. <div class="event-list-state-cb">
  308. 催办
  309. </div>
  310. </div>
  311. <div v-if="item.eventStatusValue=='forest_event_status_2'"
  312. class="event-state-qs">
  313. <i class="el-icon-caret-left"></i>
  314. <div class="event-list-state-qs">
  315. 签收
  316. </div>
  317. </div>
  318. <div v-if="item.eventStatusValue=='forest_event_status_3'"
  319. class="event-state-wb">
  320. <i class="el-icon-caret-left"></i>
  321. <div class="event-list-state-wb">
  322. 误报
  323. </div>
  324. </div>
  325. <div v-if="item.eventStatusValue=='forest_event_status_4'"
  326. class="event-state-cf">
  327. <i class="el-icon-caret-left"></i>
  328. <div class="event-list-state-cf">
  329. 重复
  330. </div>
  331. </div>
  332. <div v-if="item.eventStatusValue=='forest_event_status_5'"
  333. class="event-state-bj">
  334. <i class="el-icon-caret-left"></i>
  335. <div class="event-list-state-bj">
  336. 办结
  337. </div>
  338. </div>
  339. <div v-if="item.eventStatusValue=='forest_event_status_6'"
  340. class="event-state-gd">
  341. <i class="el-icon-caret-left"></i>
  342. <div class="event-list-state-gd">
  343. 归档
  344. </div>
  345. </div>
  346. <div v-if="item.eventStatusValue=='forest_event_status_7'"
  347. class="event-state-qr">
  348. <i class="el-icon-caret-left"></i>
  349. <div class="event-list-state-qr">
  350. 确认
  351. </div>
  352. </div>
  353. <div class="bgt-info-name">{{ item.reportor }} {{ item.eventName }}</div>
  354. <div class="bgt-info-place">
  355. <ul>
  356. <li>{{ item.createTime }}</li>
  357. </ul>
  358. </div>
  359. </div>
  360. </div>
  361. </div>
  362. <!--分页-->
  363. <div class="paging">
  364. <el-button type="button" @click="getEventList(calendarDay,10,pageNum-1,eventSearch)">上一页
  365. </el-button>
  366. <span>第{{pageNum}}页</span>
  367. <el-button type="button" :disabled="nextbutton" @click="getEventList(calendarDay,10,pageNum+1,eventSearch)">下一页
  368. </el-button>
  369. </div>
  370. </dv-border-box-13>
  371. </div>
  372. </div>
  373. <div class="right-item2">
  374. <!-- 日历 -->
  375. <div class="forthis">
  376. <dv-border-box-13 backgroundColor="rgba(12, 19, 38, .90)" style="padding-bottom: 1rem;">
  377. <img src="../assets/images/integrated/light.png" style="width: 100%; margin-top: .4rem;"/>
  378. <div class="i-list-con small-bottom-margin h-30">
  379. <dateChoose @selectDay="selectDay"></dateChoose>
  380. </div>
  381. </dv-border-box-13>
  382. </div>
  383. <!-- 事件分类 -->
  384. <div class="forthis">
  385. <dv-border-box-13 backgroundColor="rgba(12, 19, 38, .90)" style="padding-bottom: 1rem;">
  386. <img src="../assets/images/integrated/light.png" style="width: 100%; margin-top: .4rem;"/>
  387. <div class="this-title" style="cursor: pointer" @click="setEventTypeId({eventTypeIdDl: [], eventTypeId: []})">
  388. <span>事件分类</span>
  389. <dv-decoration-3 style="width:150px;height:15px;margin-right: 1rem;"/>
  390. </div>
  391. <div class="i-list-con small-bottom-margin h-19">
  392. <chart v-if="showEventKind" :config="eventKind" @setEventTypeId="setEventTypeId"
  393. style="width: 90%;height: 18vh; padding:.5rem 1rem"/>
  394. </div>
  395. </dv-border-box-13>
  396. </div>
  397. <!-- 上报排行 -->
  398. <div class="forthis">
  399. <dv-border-box-13 backgroundColor="rgba(12, 19, 38, .90)" style="padding-bottom: 1rem;">
  400. <img src="../assets/images/integrated/light.png" style="width: 100%; margin-top: .4rem;"/>
  401. <div class="this-title">
  402. <span>上报排行</span>
  403. <dv-decoration-3 style="width:150px;height:15px;margin-right: 1rem;"/>
  404. </div>
  405. <div class="i-list-con small-bottom-margin h-19">
  406. <dv-scroll-ranking-board :config="reportList"
  407. style="width: 100%;height: 300px; padding:.5rem 1rem"/>
  408. </div>
  409. </dv-border-box-13>
  410. </div>
  411. </div>
  412. </div>
  413. <vBottomMenu ref="bottomMenu" @stopAudio="stopAudio"></vBottomMenu>
  414. </div>
  415. <audio id="resource" ref="up" :src="audioSrc" controls style="display: none;"></audio>
  416. <eventdetailsdialog ref="eventdetailsdialog" :calendarDay="calendarDay" @getEventList="getEventList"
  417. @getTodayEvents="getTodayEvents" @getFirespread="getFirespread" @showEventDialog="showEventDialog" @getSupermap="getSupermap"></eventdetailsdialog>
  418. <firespread ref="firespread" :calendarDay="calendarDay" @getEventList="getEventList"
  419. @getTodayEvents="getTodayEvents" @showEventDialog="showEventDialog" @getFirespread="getFirespread" @getSupermap="getSupermap"
  420. @showDialog="showDialog"></firespread>
  421. <eventLocation ref="eventLocation"></eventLocation>
  422. <TVWall ref="TVWall"></TVWall>
  423. <TVWalls ref="TVWalls"></TVWalls>
  424. </div>
  425. </template>
  426. <script>
  427. import dateChoose from '@/views/date.vue' //日历
  428. /** ----------------------------------weosocket开始------------------------------------- */
  429. import Cookies from 'js-cookie'
  430. /** ----------------------------------weosocket结束------------------------------------- */
  431. import {
  432. getMenuEventType,
  433. getEventPush,
  434. getLatestNotice,
  435. getBaseInfo,
  436. getTodayEvents,
  437. getDeptEventCount,
  438. getWeather,
  439. getEventList,
  440. getEventByEventType,
  441. getEventByReportorOrder,
  442. getExposureStage
  443. } from '@/api/forest'
  444. import {
  445. getNearEvent
  446. } from '@/api/event'
  447. import supermap from '@/components/supermap-2.5d' //超图
  448. // import supermapNotProcessed from '@/components/supermap' //超图
  449. // import supermapProcessed from '@/components/supermap' //超图
  450. import vheader from '@/components/v-header.vue' //一体化共用头部
  451. import vBottomMenu from '@/components/vBottomMenu.vue' //一体化公共底部菜单
  452. import eventLocation from '@/components/eventLocation.vue' //事件定位弹窗
  453. import TVWall from '@/components/TVWall.vue' //电视墙弹窗
  454. import TVWalls from '@/components/TVWalls.vue' //电视墙弹窗
  455. import eventdetailsdialog from '@/views/eventdetailsdialog.vue' //事件详情弹窗
  456. import firespread from '@/views/firespread.vue' //事件详情弹窗
  457. import Firespread from "./firespread";
  458. import chart from "./from/dvCapsuleChart.vue";
  459. import {selectConfigKey} from "@/api/system/config";
  460. import {getUserProfile} from "@/api/system/user";
  461. let echarts = require('echarts')
  462. export default {
  463. components: {
  464. Firespread,
  465. supermap,
  466. chart,
  467. // supermapNotProcessed,
  468. // supermapProcessed,
  469. vheader,
  470. vBottomMenu,
  471. eventLocation,
  472. TVWall,
  473. TVWalls,
  474. dateChoose,
  475. eventdetailsdialog,
  476. firespread
  477. },
  478. metaInfo () {
  479. return {
  480. title:this.title,
  481. meta:[{
  482. charset: "utf-8"
  483. },
  484. {
  485. name: "viewport",
  486. content: "width=device-width, initial-scale=1.0,minimum-scale=1.0, maximum-scale=1.0, user-scalable=no"
  487. }]
  488. }
  489. },
  490. created() {
  491. /** ----------------------------------底部按钮公用组件开始------------------------------------- */
  492. window.showDialog = this.showDialog
  493. window.choseLayerSwitching = this.choseLayerSwitching
  494. window.choseLayerSwitchingList = this.choseLayerSwitchingList
  495. /** ----------------------------------底部按钮公用组件结束------------------------------------- */
  496. },
  497. mounted() {
  498. // 初始化地图数据
  499. this.getSuperMapUrl();
  500. setTimeout(() => {
  501. this.getLatestNotice()
  502. this.getTodayEvents(this.getCurrentDataStr())
  503. this.getDeptEventCount(this.getCurrentDataStr())
  504. this.getWeather(this.getCurrentDataStr())
  505. this.getEventList(this.getCurrentDataStr(), this.pageSize, this.pageNum)
  506. this.getEventByEventType(this.getCurrentDataStr())
  507. this.getEventByReportorOrder(this.getCurrentDataStr())
  508. this.getExposureStage(this.getCurrentDataStr())
  509. this.getSupermap(this.getCurrentDataStr())
  510. this.getMenuEventType()
  511. }, 2000)
  512. this.bottomMenuList() //获取底部公共组件消息和任务
  513. setTimeout(() => {
  514. this.title = '四平市态势感知平台'
  515. }, 1000)
  516. /** ----------------------------------weosocket开始------------------------------------- */
  517. // this.initWebSocket()
  518. /** ----------------------------------weosocket结束------------------------------------- */
  519. },
  520. data() {
  521. return {
  522. noticeContent: '', //通知公告
  523. title:"",
  524. //警报MP3文件
  525. audioSrc: require('@/assets/jingbao.mp3'),
  526. nextbutton:true,
  527. calendarDay: this.getCurrentDataStr(),
  528. //基本情况
  529. forestInfo: '', //基本情况
  530. //左侧获取事件信息统计
  531. totalStr: '000000',
  532. totalAllEvent: 0,
  533. aiTotal: '',
  534. newReport: '',
  535. otherTotal: '',
  536. readyFinish: '',
  537. readySure: '',
  538. total: '',
  539. aiTotal_pre: '',
  540. newReport_pre: '',
  541. otherTotal_pre: '',
  542. readyFinish_pre: '',
  543. readySure_pre: '',
  544. //左侧部门事件数量
  545. forestFarm: [],
  546. //右侧天气
  547. todatWeather: false,
  548. weatherinformationDirection: '',
  549. weatherinformationHigh: '',
  550. weatherinformationLevel: '',
  551. weatherinformationLevelValue: '', //火险登记中文
  552. weatherinformationLow: '',
  553. weatherinformationPower: '',
  554. weatherinformationTemperature: '',
  555. weatherinformationTime: '',
  556. weatherinformationWeather: '',
  557. //右侧曝光台
  558. exposureStageList: [],
  559. //右侧事件列表
  560. eventList: [],
  561. pageSize: 10,
  562. pageNum: 1,
  563. eventTypeIdDl:[],
  564. eventTypeId:[],
  565. eventListnew: [],
  566. eventListAll: [],
  567. eventSearch: '', //事件列表搜索
  568. listCurrentIndex1: '',
  569. // ----------------------------------事件分类柱状----------------------------------------
  570. eventKind: {},
  571. showEventKind: false,
  572. // ----------------------------------上报排行----------------------------------------
  573. reportList: {
  574. data: []
  575. },
  576. /** ----------------------------------weosocket开始------------------------------------- */
  577. weosocket: false,
  578. websock: '',
  579. setIntervalWesocketPush: null,
  580. websockSid: {
  581. userId: '',
  582. eventTypeDl: '',
  583. eventType: '',
  584. },
  585. /** ----------------------------------weosocket结束------------------------------------- */
  586. /** ----------------------------------摄像头预览开始------------------------------------- */
  587. activePanel: 'key1',
  588. isLogin: false,
  589. cameraParams: [],
  590. ws: null,
  591. /** ----------------------------------摄像头预览结束------------------------------------- */
  592. markersList: [], //点位列表
  593. cameraList: [] //摄像头列表
  594. }
  595. },
  596. /** ----------------------------------weosocket开始------------------------------------- */
  597. destroyed() { //离开页面关闭Socket连接
  598. if (this.websock) {
  599. clearInterval(this.setIntervalWesocketPush)
  600. this.websock.close()
  601. this.websock = null
  602. }
  603. },
  604. /** ----------------------------------weosocket结束------------------------------------- */
  605. methods: {
  606. showDefaultImg(){
  607. let img = event.srcElement;
  608. img.src = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAF0AAABACAYAAAB4OXuGAAAE2UlEQVR4nO2b2XbaSBCGS2hhByEwCXaSizxArucJ5v1fYG5mJnbGrGIVYlHO30RYYkmM7e4Sk/7O0YVt3JL+Lv1dVS2ML3/8GZFGKTktt3q06Axo0RnQojOgRWdAi86AFp0BLToDWnQGLLmnNLJ5179EbpEuRXTDMKjV+UxG7nofpGA+ofHgm5SxpaiSy5lXLTgolKrSxpajjHGttqIGyZ6+Y+r3aLvdZOF+f0qhWCWnUJJ+HiWiLxdT2qxXKk71Kiw7Tw7JF12njAxkQnRkO6blUM5U8uCxw3qXtlOgcq1JTqG4z+m3mw0F8zHNJgOKttssaPTmsIlerLhUdW+Ofp8zTSpVG5QvVmjU+6p0LUieS+aEs9iLUyifFDyJadnktm6F9agimPm0mPm0Wi6kFUbEFemHgq9XS1EBwtOL5RoZxi4W4PN4IuaToZLriqKIJsNH6edRLjp8HFEcEwZzGvXu9/2OYDamRvvjPsKRO6sSXRXKRUf0JtkJ+tRgQtSHwUx4uvi87ZwbSsK12VRv3pJl2zQbD8QhA/WefmDR0YmOHh5z1aBXtBPcEReJrEoWykXfrNLZSKnipn5GtOWL5afPr0Ml11X3Oj8El49ye1mFC9pu1vtCCDbitu5ouZiQkTOpVGnsF1L60UKQDRZ2FT2XGJbsBQ2wmvd+/zNu+NRNY3Lm05HUaylW6iJDUglLno708FeLFLqSyGpkFimY6Krbljb+Odgq0tm4T+swoHK9Kbp7MVhEl/MJTcd9EemygH/Dx5Pg3CqKMdbeyzKYiQP+bpo2RdFWLJyH2QsWVnj9ehXSdNx7dfRjZwuZSnJ3C2sNxi+W668a+zlkoq2HiD4X1fDc2ALsfFEcfv/+xT0ZRHK92UkVaBjL7z1Qqea98A4uI9P99HLNO/Jc2AIqVoj/EqqNd6n/xVODSVS5s5VZ0SvuzdkCBfbQaN1dbAWlqne04ewPHoStqCSTote8d0dFE1oDKQsyDKo22mJyngPqgUo9PYmTUVf0flSTqa0a+G3N66QqUoB2K7p/WHDdZocsp7D/GybHshwRsecWWMvJp+oCMebUp4XkGuAcmYl00fto3R0JjoZY3G5FpA+7/4o8Pwnyba/9MbU4xuwmKt2XR3RPRvJbuOfIhOg7j/5AzsHiiMoVRxKkk9hgQJ6fBN1Lr/2JnPxTZQuhsRGS3HuFf+Op4IRddAjSaH8QFpBkPPzvp310VLR+/yGV0+NpcW9uRZpJYm14nyq8kKEgU+Hee2X1dERn4+Yu/RZAFJE/+PasRhc+M3z8h+qtWzL3YxgizURmkxRcjNt/yMT7N2yRjsUQEZ4UHBUp+i2XdBax6TF8/JtWYZAe3z5+crD3mQVYREdxgjwbXh4jGlzdrxQuL0/h8NrG6MQCGzOfDM7+jQMW0WuNdqrvgawEoh1G6yXEC+zhwounZur3XzyuDJg8/Sl9g8dC8M0bdRSx+CJDQf6+Xoc0O5iELMAiOiISLV3YwnTUffO+B6pXHFmFRXTYCPz7d0W/tcuAFp0BLToDSjwdbdVr+PqLZf2P3nup1FsqTnM1yLEXhtfirgkposNKrv1bFDLbBlLsBSV59/4v/TX1M0j2dG0zp9ApIwNadAa06Axo0RnQojOgRWdAi86AFp0BLbpqiOg74YbqU8Iw/dEAAAAASUVORK5CYII=";
  609. },
  610. //初始化地图数据
  611. getSuperMapUrl(){
  612. getUserProfile().then(response => {
  613. let mapDeptId=response.mapDeptId
  614. let num = 0;
  615. if (mapDeptId == "365") {
  616. num = 0;
  617. } else if (mapDeptId == "369") {
  618. num = 1;
  619. } else if (mapDeptId == "371") {
  620. num = 2;
  621. } else if (mapDeptId == "373") {
  622. num = 3;
  623. } else if (mapDeptId == "372") {
  624. num = 4;
  625. } else if (mapDeptId == "370") {
  626. num = 5;
  627. }
  628. this.$refs.supermap.removeAllviewer(num, -1);
  629. });
  630. },
  631. getMenuEventType() {
  632. let that = this
  633. getMenuEventType().then(res => {
  634. that.websockSid.userId = Cookies.get('userId')
  635. that.websockSid.eventTypeDl = res.data.eventTypeDl
  636. that.websockSid.eventType = res.data.eventType
  637. that.initWebSocket(that.websockSid.userId, that.websockSid.eventTypeDl, that.websockSid.eventType)
  638. console.log(that.websockSid)
  639. })
  640. },
  641. setEventTypeId(data) {
  642. // let data = {eventTypeIdDl: [], eventTypeId: []}
  643. // let data = {eventTypeIdDl: that.eventTypeIdDl, eventTypeId: that.eventTypeId}
  644. let that = this
  645. that.eventTypeIdDl = data.eventTypeIdDl
  646. that.eventTypeId = data.eventTypeId
  647. that.getSupermap(that.calendarDay, false)
  648. that.getTodayEvents(that.calendarDay, false)
  649. that.getEventByEventType(that.calendarDay, false)
  650. that.getExposureStage(that.calendarDay, false)
  651. that.getEventByReportorOrder(that.calendarDay, false)
  652. that.getDeptEventCount(that.calendarDay, false)
  653. that.getEventList(that.calendarDay, that.pageSize, that.pageNum, '', false)
  654. },
  655. // searchEvent(pageSize,pageNum,eventSearch) {
  656. // this.pageSize = pageSize;
  657. // this.pageNum = pageNum;
  658. // let that = this
  659. // //事件列表搜索
  660. // this.eventList = []
  661. // //右侧获取事件列表
  662. // getEventList({ day: that.calendarDay,pageSize:pageSize,pageNum: pageNum ,eventName:eventSearch}).then(res => {
  663. // this.eventList = res.data
  664. // if (this.eventList != null && this.eventList.length > 0) {
  665. // if(this.eventList[0].eventStatusValue == 'forest_event_status_1'){
  666. // that.$refs.bottomMenu.updateAlert();
  667. // that.$refs.up.play();
  668. // }
  669. // }
  670. // })
  671. // },
  672. fatherMethod(dianshiqiang, longitude, latitude, item) {
  673. this.$refs.TVWalls.showTVWall(
  674. dianshiqiang, {
  675. longitude: longitude,
  676. latitude: latitude,
  677. },
  678. item
  679. );
  680. },
  681. dropLocation(lat, lng,eventCode) {
  682. this.$refs.supermap.dropLocation(lat, lng,18)
  683. this.showEventDialog(eventCode)
  684. },
  685. showEventDialog(eventCode) {
  686. //事件信息弹出
  687. this.$refs.firespread.showEventDialog(eventCode)
  688. },
  689. getFirespread(eventCode) {
  690. this.$refs.eventdetailsdialog.showEventDialog(eventCode);
  691. //this.$refs.eventdetailsdialog.fireControlViewList()
  692. },
  693. getCurrentDataStr() {
  694. let date = new Date()
  695. let y = date.getFullYear()
  696. let m = date.getMonth() + 1
  697. m = m < 10 ? '0' + m : m
  698. let d = date.getDate()
  699. d = d < 10 ? '0' + d : d
  700. return y + '-' + m + '-' + d
  701. },
  702. selectDay(day) { //日历点击
  703. this.pageNum = 1
  704. this.getTodayEvents(day)
  705. this.getDeptEventCount(day)
  706. this.getWeather(day)
  707. this.getEventList(day, 10, 1)
  708. this.getEventByEventType(day)
  709. this.getEventByReportorOrder(day)
  710. this.getExposureStage(day)
  711. this.getSupermap(day);
  712. this.calendarDay = day
  713. },
  714. //事件数量统计chart 样例地址http://192.144.199.210:8080/editor/index.html?chart_id=jTXf0Rv4A3oiBONB
  715. eventChartAi(aiTotal_pre, otherTotal_pre) {
  716. // 基于准备好的dom,初始化echarts实例
  717. let myChart = echarts.init(document.getElementById('chart-event-ai'))
  718. myChart.setOption({
  719. tooltip: {
  720. trigger: 'none'
  721. },
  722. grid: {
  723. top: '65%',
  724. left: '5%',
  725. right: '5%'
  726. },
  727. yAxis: {
  728. data: ['百分比'],
  729. axisTick: {
  730. show: false
  731. },
  732. axisLine: {
  733. show: false
  734. },
  735. axisLabel: {
  736. show: false
  737. }
  738. },
  739. xAxis: {
  740. splitLine: {
  741. show: false
  742. },
  743. axisTick: {
  744. show: false
  745. },
  746. axisLine: {
  747. show: false
  748. },
  749. axisLabel: {
  750. show: false
  751. }
  752. },
  753. legend: {
  754. data: ['AI', '其他'],
  755. bottom: '5%',
  756. textStyle: {
  757. color: '#1FC3CE',
  758. fontSize: 14
  759. }
  760. },
  761. series: [{
  762. // name: '最上层立体圆',
  763. type: 'pictorialBar',
  764. symbolSize: [10, 20],
  765. symbolOffset: [2, 0],
  766. z: 12,
  767. itemStyle: {
  768. normal: {
  769. color: '#293CA0'
  770. }
  771. },
  772. data: [{
  773. value: 100,
  774. symbolPosition: 'end'
  775. }]
  776. }, {
  777. // name: '中间立体圆',
  778. type: 'pictorialBar',
  779. symbolSize: [10, 20],
  780. symbolOffset: [2, 0],
  781. z: 12,
  782. itemStyle: {
  783. normal: {
  784. color: '#45ac8d'
  785. }
  786. },
  787. data: [{
  788. value: aiTotal_pre,
  789. symbolPosition: 'end'
  790. }]
  791. }, {
  792. // name: '最底部立体圆',
  793. type: 'pictorialBar',
  794. symbolSize: [10, 20],
  795. symbolOffset: [-4, 0],
  796. z: 12,
  797. itemStyle: {
  798. normal: {
  799. color: '#196d59'
  800. }
  801. },
  802. data: [otherTotal_pre]
  803. }, {
  804. name: 'AI',
  805. //底部立体柱
  806. stack: '1',
  807. type: 'bar',
  808. itemStyle: {
  809. normal: {
  810. color: new echarts.graphic.LinearGradient(0, 0, 1, 0, [{
  811. offset: 0,
  812. color: '#29ac8f'
  813. }, {
  814. offset: 1,
  815. color: '#0a3f3f'
  816. }])
  817. }
  818. },
  819. label: {
  820. normal: {
  821. show: true,
  822. position: 'inside',
  823. offset: [0, 1],
  824. formatter: function (obj) {
  825. return (obj.value).toLocaleString() + '%'
  826. },
  827. textStyle: {
  828. align: 'center',
  829. baseline: 'middle',
  830. fontSize: 14,
  831. fontWeight: '400',
  832. color: '#fff',
  833. textShadowColor: '#000',
  834. textShadowBlur: '0',
  835. textShadowOffsetX: 1,
  836. textShadowOffsetY: 1
  837. }
  838. }
  839. },
  840. silent: true,
  841. barWidth: 20,
  842. barGap: '-100%', // Make series be overlap
  843. data: [aiTotal_pre]
  844. }, {
  845. name: '其他',
  846. //上部立体柱
  847. stack: '1',
  848. type: 'bar',
  849. itemStyle: {
  850. normal: {
  851. color: '#14257B',
  852. opacity: .7
  853. }
  854. },
  855. silent: true,
  856. barWidth: 20,
  857. barGap: '-100%', // Make series be overlap
  858. data: [otherTotal_pre],
  859. // itemStyle: {
  860. // normal: {
  861. // color: 'rgba(29,67,243,1)',
  862. // }
  863. // },
  864. label: {
  865. normal: {
  866. show: true,
  867. position: 'inside',
  868. offset: [0, 1],
  869. formatter: function (obj) {
  870. return (obj.value).toLocaleString() + '%'
  871. },
  872. textStyle: {
  873. align: 'center',
  874. baseline: 'middle',
  875. fontSize: 14,
  876. fontWeight: '400',
  877. color: '#fff',
  878. textShadowColor: '#000',
  879. textShadowBlur: '0',
  880. textShadowOffsetX: 1,
  881. textShadowOffsetY: 1
  882. }
  883. }
  884. }
  885. }]
  886. })
  887. },
  888. getLatestNotice() {
  889. getLatestNotice().then(res => {
  890. if (res.code == 200) {
  891. this.noticeContent = res.data.noticeContent //通知公告
  892. }
  893. })
  894. },
  895. getTodayEvents(day, loading) {
  896. let that = this
  897. //左侧获取事件信息统计
  898. getTodayEvents({eventTypeIdDl: that.eventTypeIdDl,eventTypeId: that.eventTypeId,day: day}, loading).then(res => {
  899. this.aiTotal = res.data.aiTotal
  900. this.aiTotal_pre = res.data.aiTotal_pre
  901. this.newReport = res.data.newReport
  902. this.newReport_pre = res.data.newReport_pre
  903. this.otherTotal = res.data.otherTotal
  904. this.otherTotal_pre = res.data.otherTotal_pre
  905. this.readyFinish = res.data.readyFinish
  906. this.readyFinish_pre = res.data.readyFinish_pre
  907. this.readySure = res.data.readySure
  908. this.readySure_pre = res.data.readySure_pre
  909. this.totalStr = res.data.totalStr
  910. this.totalAllEvent = +res.data.totalStr
  911. this.total = res.data.total
  912. this.eventChartAi(this.aiTotal_pre, this.otherTotal_pre)
  913. })
  914. },
  915. getDeptEventCount(day, loading) {
  916. let that = this
  917. //左侧获取事件部门数量
  918. getDeptEventCount({eventTypeIdDl: that.eventTypeIdDl,eventTypeId: that.eventTypeId,day: day}, loading).then(res => {
  919. this.forestFarm = res.data
  920. })
  921. },
  922. getWeather(day) {
  923. let that = this
  924. //右侧获取天气信息
  925. getWeather({day: day}).then(res => {
  926. if (res.code == 200) {
  927. if (res.msg == '天气未添加') {
  928. this.todatWeather = false
  929. } else {
  930. this.todatWeather = true
  931. this.weatherinformationDirection = res.data.weatherinformationDirection
  932. this.weatherinformationHigh = res.data.weatherinformationHigh
  933. this.weatherinformationLevel = res.data.weatherinformationLevel
  934. this.weatherinformationLevelValue = res.data.weatherinformationLevelValue
  935. this.weatherinformationLow = res.data.weatherinformationLow
  936. this.weatherinformationPower = res.data.weatherinformationPower
  937. this.weatherinformationTemperature = res.data.weatherinformationTemperature
  938. this.weatherinformationTime = res.data.weatherinformationTime
  939. this.weatherinformationWeather = res.data.weatherinformationWeather
  940. }
  941. } else {
  942. this.todatWeather = false
  943. }
  944. })
  945. },
  946. getSupermap(day, loading) {
  947. let that = this
  948. getNearEvent('', '', day, loading, that.eventTypeIdDl, that.eventTypeId).then(res => {
  949. that.markersList = [];
  950. if (res.data != null && res.data.length > 0) {
  951. for (let i = 0; i < res.data.length; i++) {
  952. let markersMap = {
  953. lng: 124.59,
  954. lat: 43.02,
  955. icon: 'marker',
  956. bindPopupHtml: '',
  957. click: '',
  958. parameter: '',
  959. keepBindPopup: false,
  960. isAggregation: false
  961. }
  962. if (res.data.length > 200) {
  963. markersMap.isAggregation = true
  964. }
  965. if (res.data[i].eventStatusValue == 'forest_event_status_1' && res.data[i].urgeCount == 0) {
  966. markersMap.click = 'showEventDialog'
  967. markersMap.icon = 'sj-icon-map-xinshangbao'
  968. }
  969. if (res.data[i].eventStatusValue == 'forest_event_status_1' && res.data[i].urgeCount > 0) {
  970. markersMap.click = 'showEventDialog'
  971. markersMap.icon = 'sj-icon-map-cuiban'
  972. } else if (res.data[i].eventStatusValue == 'forest_event_status_2') {
  973. markersMap.click = 'showEventDialog'
  974. markersMap.icon = 'sj-icon-map-qianshou'
  975. markersMap.isAggregation = false
  976. } else if (res.data[i].eventStatusValue == 'forest_event_status_5') {
  977. markersMap.click = 'showEventDialog'
  978. markersMap.icon = 'sj-icon-map-banjie'
  979. markersMap.isAggregation = false
  980. } else if (res.data[i].eventStatusValue == 'forest_event_status_6') {
  981. markersMap.click = 'showEventDialog'
  982. markersMap.icon = 'sj-icon-map-guidang'
  983. } else if (res.data[i].eventStatusValue == 'forest_event_status_7') {
  984. markersMap.click = 'showEventDialog'
  985. markersMap.icon = 'sj-icon-map-queren'
  986. }
  987. markersMap.parameter = res.data[i].eventCode
  988. markersMap.lng = res.data[i].longitude
  989. markersMap.lat = res.data[i].latitude
  990. markersMap.bindPopupHtml = '<div class="map-tip">' +
  991. '<span>' +
  992. ' <div class="d-l-con">' +
  993. ' <div class="d-l-l-text">' +
  994. ' <h4>经纬度:' + res.data[i].longitude + ',' + res.data[i].latitude + '</h4>' +
  995. ' </div>' +
  996. ' </div>' +
  997. ' </span>' +
  998. '<span>' +
  999. ' <div class="d-l-con">' +
  1000. ' <div class="d-l-l-text">' +
  1001. ' <h4>事件名称:' + res.data[i].eventName + '</h4>' +
  1002. ' </div>' +
  1003. ' </div>' +
  1004. ' </span>' +
  1005. '<span>' +
  1006. ' <div class="d-l-con">' +
  1007. ' <div class="d-l-l-text">' +
  1008. ' <h4>事件时间:' + res.data[i].createTime + '</h4>' +
  1009. ' </div>' +
  1010. ' </div>' +
  1011. ' </span>';
  1012. if (res.data[i].pictureType == 'image' && res.data[i].picturePath != null && res.data[i].picturePath != '') {
  1013. markersMap.bindPopupHtml += '<span>' +
  1014. ' <div class="d-l-con">' +
  1015. ' <div class="d-l-l-text">' +
  1016. '<img src="' + res.data[i].picturePath + '" style="width: 150px;height: 100px"/>' +
  1017. ' </div>' +
  1018. ' </div>' +
  1019. ' </span>'
  1020. }
  1021. markersMap.bindPopupHtml += '</div>'
  1022. that.markersList.push(markersMap)
  1023. }
  1024. setTimeout(() => {
  1025. that.$refs.supermap.clearM()
  1026. that.$refs.supermap.setMarkers(that.markersList)
  1027. }, 3000)
  1028. } else {
  1029. setTimeout(() => {
  1030. that.$refs.supermap.clearM()
  1031. }, 3000)
  1032. }
  1033. })
  1034. },
  1035. getEventList(day, pageSize, pageNum, eventSearch, loading) {
  1036. let num=this.eventList.length/pageSize+1
  1037. if (pageNum < 1) {
  1038. this.$modal.msg('当前已是第一页')
  1039. return;
  1040. }else if(pageNum>this.totalAllEvent/10+1)
  1041. {
  1042. this.$modal.msg('当前已是最后一页')
  1043. return;
  1044. }
  1045. this.pageSize = pageSize;
  1046. this.pageNum = pageNum;
  1047. let that = this
  1048. //右侧获取事件列表
  1049. getEventList({eventTypeIdDl: that.eventTypeIdDl,eventTypeId: that.eventTypeId, day: day, pageSize: pageSize, pageNum: pageNum, eventName: eventSearch}, loading).then(res => {
  1050. this.eventList = []
  1051. this.eventList = res.data
  1052. if(res.data!==null&&res.data.length!==0&&res.data.length==10)
  1053. {
  1054. this.nextbutton=false
  1055. }else
  1056. {
  1057. this.nextbutton=true
  1058. }
  1059. if (this.eventList != null && this.eventList.length > 0) {
  1060. if (this.eventList[0].eventStatusValue == 'forest_event_status_1') {
  1061. that.$refs.bottomMenu.updateAlert();
  1062. that.$refs.up.play();
  1063. } else {
  1064. that.$refs.bottomMenu.updateAlertFalse();
  1065. }
  1066. }
  1067. })
  1068. },
  1069. getEventByEventType(day, loading) {
  1070. let that = this
  1071. //右侧获取事件分类
  1072. getEventByEventType({eventTypeIdDl: that.eventTypeIdDl,eventTypeId: that.eventTypeId, day: day}, loading).then(res => {
  1073. if (res.data != null && res.data.length > 0) {
  1074. this.showEventKind = true
  1075. this.eventKind.data = res.data
  1076. this.eventKind.colors = ['#1ce0a9', '#d6333b', '#e68d3f', '#32c5e9', '#2abc65']
  1077. this.eventKind.showValue = true
  1078. this.eventKind = {...this.eventKind}
  1079. } else {
  1080. this.showEventKind = false
  1081. this.eventKind = {}
  1082. this.eventKind = {...this.eventKind}
  1083. }
  1084. })
  1085. },
  1086. getEventByReportorOrder(day, loading) {
  1087. let that = this
  1088. //右侧获取上报排名
  1089. getEventByReportorOrder({eventTypeIdDl: that.eventTypeIdDl,eventTypeId: that.eventTypeId,day: day}, loading).then(res => {
  1090. if (res.data != null && res.data.length > 0) {
  1091. this.reportList.data = res.data
  1092. this.reportList = {...this.reportList}
  1093. } else {
  1094. this.reportList.data = []
  1095. this.reportList = {...this.reportList}
  1096. }
  1097. })
  1098. },
  1099. getEventListNew() {
  1100. this.eventList = []
  1101. this.eventListAll = []
  1102. //右侧获取事件列表
  1103. getEventList({day: this.getCurrentDataStr()}).then(res => {
  1104. this.eventList = res.data
  1105. this.eventListAll = res.data
  1106. })
  1107. },
  1108. getWebSocketEvent(data) {
  1109. let that = this
  1110. let event = data
  1111. if (typeof data != 'object') {
  1112. event = JSON.parse(data);
  1113. }
  1114. //右侧获取事件列表
  1115. that.markersList = []
  1116. let markersMap = {
  1117. lng: 124.59,
  1118. lat: 43.02,
  1119. icon: 'marker',
  1120. bindPopupHtml: '',
  1121. click: '',
  1122. parameter: '',
  1123. keepBindPopup: false,
  1124. isAggregation: false
  1125. }
  1126. if (event.eventStatusValue == 'forest_event_status_1' && event.urgeCount == 0) {
  1127. markersMap.click = 'showEventDialog'
  1128. markersMap.icon = 'sj-icon-map-xinshangbao'
  1129. }
  1130. if (event.eventStatusValue == 'forest_event_status_1' && event.urgeCount > 0) {
  1131. markersMap.click = 'showEventDialog'
  1132. markersMap.icon = 'sj-icon-map-cuiban'
  1133. } else if (event.eventStatusValue == 'forest_event_status_2') {
  1134. markersMap.click = 'showEventDialog'
  1135. markersMap.icon = 'sj-icon-map-qianshou'
  1136. markersMap.isAggregation = false
  1137. } else if (event.eventStatusValue == 'forest_event_status_5') {
  1138. markersMap.click = 'showEventDialog'
  1139. markersMap.icon = 'sj-icon-map-banjie'
  1140. markersMap.isAggregation = false
  1141. } else if (event.eventStatusValue == 'forest_event_status_6') {
  1142. markersMap.click = 'showEventDialog'
  1143. markersMap.icon = 'sj-icon-map-guidang'
  1144. } else if (event.eventStatusValue == 'forest_event_status_7') {
  1145. markersMap.click = 'showEventDialog'
  1146. markersMap.icon = 'sj-icon-map-queren'
  1147. }
  1148. markersMap.parameter = event.eventCode
  1149. markersMap.lng = event.longitude
  1150. markersMap.lat = event.latitude
  1151. markersMap.bindPopupHtml = '<div class="map-tip">' +
  1152. '<span>' +
  1153. ' <div class="d-l-con">' +
  1154. ' <div class="d-l-l-text">' +
  1155. ' <h4>经纬度:' + event.longitude + ',' + event.latitude + '</h4>' +
  1156. ' </div>' +
  1157. ' </div>' +
  1158. ' </span>' +
  1159. '<span>' +
  1160. ' <div class="d-l-con">' +
  1161. ' <div class="d-l-l-text">' +
  1162. ' <h4>事件名称:' + event.eventName + '</h4>' +
  1163. ' </div>' +
  1164. ' </div>' +
  1165. ' </span>' +
  1166. '<span>' +
  1167. ' <div class="d-l-con">' +
  1168. ' <div class="d-l-l-text">' +
  1169. ' <h4>事件时间:' + event.createTime + '</h4>' +
  1170. ' </div>' +
  1171. ' </div>' +
  1172. ' </span>';
  1173. if (event.pictureType == 'image' && event.picturePath != null && event.picturePath != '') {
  1174. markersMap.bindPopupHtml += '<span>' +
  1175. ' <div class="d-l-con">' +
  1176. ' <div class="d-l-l-text">' +
  1177. '<img src="' + event.picturePath + '" style="width: 150px;height: 100px"/>' +
  1178. ' </div>' +
  1179. ' </div>' +
  1180. ' </span>'
  1181. }
  1182. markersMap.bindPopupHtml += '</div>'
  1183. that.markersList.push(markersMap)
  1184. setTimeout(() => {
  1185. that.$refs.supermap.clearM()
  1186. that.$refs.supermap.setMarkers(that.markersList)
  1187. }, 3000)
  1188. },
  1189. getExposureStage(day, loading) {
  1190. let that = this
  1191. //右侧获取曝光台
  1192. getExposureStage({eventTypeIdDl: that.eventTypeIdDl,eventTypeId: that.eventTypeId,day: day}, loading).then(res => {
  1193. this.exposureStageList = res.data
  1194. })
  1195. },
  1196. /** ----------------------------------weosocket开始------------------------------------- */
  1197. initWebSocket(userId, eventTypeDl, eventType) { //初始化weosocket
  1198. selectConfigKey('KSH_SOCKET').then(res => {
  1199. const wsuri = res.data + userId + '/' + eventTypeDl + '/' + eventType
  1200. this.websock = new WebSocket(wsuri)
  1201. console.log('建立websocket连接')
  1202. this.websock.onopen = this.websocketonopen
  1203. this.websock.onmessage = this.websocketonmessage
  1204. this.websock.onerror = this.websocketonerror
  1205. })
  1206. },
  1207. websocketonopen() { //连接建立之后执行send方法发送数据
  1208. console.log('websocket连接成功')
  1209. this.weosocket = true
  1210. this.sendPing()
  1211. },
  1212. websocketonerror() { //连接建立失败重连
  1213. this.initWebSocket(this.websockSid.userId, this.websockSid.eventTypeDl, this.websockSid.eventType,)
  1214. },
  1215. websocketonmessage(e) { //数据接收
  1216. console.log('接收数据', e.data)
  1217. // let data = "{\"fromId\":\"forest\",\"fromUserId\":\""+Cookies.get('username')+"\",\"toUserId\":\""+Cookies.get('username')+"\"}";
  1218. let data = "{\"fromId\":\"environment\"}";
  1219. if (this.calendarDay == this.getCurrentDataStr() && data != e.data) {
  1220. // 处理收到的消息
  1221. this.handleWebSoceketEvent(e.data)
  1222. this.getTodayEvents(this.getCurrentDataStr(), true);
  1223. this.getDeptEventCount(this.getCurrentDataStr(), true);
  1224. this.getEventByEventType(this.getCurrentDataStr(), true);
  1225. this.getEventByReportorOrder(this.getCurrentDataStr(), true);
  1226. this.getExposureStage(this.getCurrentDataStr(), true);
  1227. // thes.$refs.up.pause();//停止播放音乐
  1228. }
  1229. },
  1230. // 处理WebSocket事件
  1231. handleWebSoceketEvent(val) {
  1232. let that = this
  1233. let data = JSON.parse(val)
  1234. /**
  1235. * that.markersList.filter( item => data.eventCode == item.parameter).length == 0 如果地图中不存在当前事件则添加
  1236. * eventPush: 事件列表消息
  1237. * */
  1238. if (data.tag == "eventPush" && that.markersList.filter( item => data.eventCode == item.parameter).length == 0) {
  1239. getEventPush({eventCode: data.eventCode}).then((res) => {
  1240. if (res.data != undefined) {
  1241. if (res.data.eventType == 601) {
  1242. res.data.picturePath = "../assets/images/大气监测.png"
  1243. } else if (res.data.eventType == 602) {
  1244. res.data.picturePath = "../assets/images/水质监测.png"
  1245. }
  1246. // if (res.data.eventStatusValue !== "forest_event_status_1") {
  1247. //插入到第一条
  1248. this.eventList.unshift(res.data)
  1249. // 插入后删除最后一条 保证列表中为10条数据
  1250. if (this.eventList.length > 9)
  1251. this.eventList.splice(10, 1)
  1252. // 将收到的数据在地图上添加
  1253. this.getWebSocketEvent(res.data)
  1254. // }
  1255. this.$refs.bottomMenu.updateAlert();
  1256. this.$refs.up.play();
  1257. }
  1258. })
  1259. }
  1260. console.log(that.eventList[0])
  1261. },
  1262. websocketsend(Data) { //数据发送
  1263. this.websock.send(Data)
  1264. },
  1265. websocketclose(e) { //关闭
  1266. console.log('断开连接', e)
  1267. // clearInterval(this.setIntervalWesocketPush)
  1268. this.weosocket = false
  1269. },
  1270. /**发送心跳
  1271. * @param {number} time 心跳间隔毫秒 默认5000
  1272. * @param {string} ping 心跳名称 默认字符串ping
  1273. */
  1274. sendPing(time = 60000, ping = {
  1275. 'fromId': 'environment'
  1276. }) {
  1277. clearInterval(this.setIntervalWesocketPush)
  1278. this.setIntervalWesocketPush = setInterval(() => {
  1279. if (this.weosocket) {
  1280. this.websock.send(JSON.stringify(ping))
  1281. } else {
  1282. // this.initWebSocket()
  1283. }
  1284. }, time)
  1285. },
  1286. stopAudio() {
  1287. this.$refs.up.pause(); //停止播放音乐
  1288. this.$refs.up.currentTime = 0;
  1289. },
  1290. /** ----------------------------------weosocket结束------------------------------------- */
  1291. /** ----------------------------------底部按钮公用组件开始------------------------------------- */
  1292. bottomMenuList() {
  1293. this.$refs.bottomMenu.selectTaskList()
  1294. this.$refs.bottomMenu.selectMessageList()
  1295. },
  1296. showDialog(click) {
  1297. if (click == 'eventLocation') {
  1298. this.$refs.eventLocation.showEventLocation()
  1299. this.$refs.bottomMenu.showMeasure = false
  1300. this.$refs.bottomMenu.showChild = false
  1301. this.$refs.bottomMenu.showBanChild = false
  1302. this.$refs.bottomMenu.showChangChild = false
  1303. } else if (click == 'editableLayers') {
  1304. this.$refs.bottomMenu.showChild = false
  1305. this.$refs.bottomMenu.showBanChild = false
  1306. this.$refs.bottomMenu.showChangChild = false
  1307. if (!this.$refs.bottomMenu.showMeasure) {
  1308. this.$refs.bottomMenu.showMeasure = true
  1309. } else {
  1310. this.$refs.bottomMenu.showMeasure = false
  1311. }
  1312. } else if (click == 'layerSwitching') {
  1313. this.$refs.bottomMenu.showMeasure = false
  1314. this.$refs.bottomMenu.showBanChild = false
  1315. this.$refs.bottomMenu.showChangChild = false
  1316. if (!this.$refs.bottomMenu.showChild) {
  1317. this.$refs.bottomMenu.showChild = true
  1318. } else {
  1319. this.$refs.bottomMenu.showChild = false
  1320. }
  1321. } else if (click == 'TVWall') {
  1322. this.$refs.TVWall.showTVWall()
  1323. this.$refs.bottomMenu.showMeasure = false
  1324. this.$refs.bottomMenu.showChild = false
  1325. this.$refs.bottomMenu.showBanChild = false
  1326. this.$refs.bottomMenu.showChangChild = false
  1327. } else if (click == 'forestban') {
  1328. this.$refs.bottomMenu.showMeasure = false
  1329. this.$refs.bottomMenu.showChild = false
  1330. this.$refs.bottomMenu.showChangChild = false
  1331. if (!this.$refs.bottomMenu.showBanChild) {
  1332. this.$refs.bottomMenu.showBanChild = true
  1333. } else {
  1334. this.$refs.bottomMenu.showBanChild = false
  1335. }
  1336. } else if (click == 'forestchang') {
  1337. this.$refs.bottomMenu.showMeasure = false
  1338. this.$refs.bottomMenu.showBanChild = false
  1339. this.$refs.bottomMenu.showChild = false
  1340. if (!this.$refs.bottomMenu.showChangChild) {
  1341. this.$refs.bottomMenu.showChangChild = true
  1342. } else {
  1343. this.$refs.bottomMenu.showChangChild = false
  1344. }
  1345. }
  1346. },
  1347. //选择图层
  1348. choseLayerSwitching(url, isClear) {
  1349. this.$refs.supermap.layerSwitching(url, isClear)
  1350. },
  1351. //选择图层(传递数组)
  1352. choseLayerSwitchingList(urlList) {
  1353. this.$refs.supermap.layerSwitchingList(urlList)
  1354. },
  1355. /** ----------------------------------底部按钮公用组件结束------------------------------------- */
  1356. }
  1357. }
  1358. </script>
  1359. <style rel="stylesheet/scss" lang="scss" scoped>
  1360. @import '@/assets/styles/base.scss';
  1361. .paging {
  1362. padding: .5rem .3rem;
  1363. display: flex;
  1364. justify-content: center;
  1365. align-content: center;
  1366. span {
  1367. color: #2bacf7;
  1368. display: flex;
  1369. align-items: center;
  1370. padding: 0 1rem;
  1371. }
  1372. button {
  1373. padding: 0 0.3rem;
  1374. height: 1.5rem;
  1375. background-color: #112543;
  1376. color: #2bacf7;
  1377. border: 1px solid #33467f;
  1378. }
  1379. button:hover {
  1380. padding: 0 0.3rem;
  1381. height: 1.5rem;
  1382. background-color: #112543;
  1383. color: #0ff7c5;
  1384. border: 1px solid #1d657f;
  1385. }
  1386. }
  1387. </style>
  1388. <style lang="scss">
  1389. @import '@/assets/styles/base.scss';
  1390. .bottomRight{
  1391. .el-table .el-table__header-wrapper th, .el-table .el-table__fixed-header-wrapper th {
  1392. background-color: $searchBG;
  1393. }
  1394. .el-table td.el-table__cell, .el-table th.el-table__cell.is-leaf {
  1395. border-bottom: 1px $tableBorder;
  1396. }
  1397. .el-table--border, .el-table--border::after {
  1398. border: 1px $tableBorder;
  1399. background-color: $searchBG
  1400. }
  1401. .el-table--border {
  1402. .el-table--group {
  1403. border: 1px $tableBorder;
  1404. }
  1405. .el-table__cell {
  1406. border-right: 1px $tableBorder;;
  1407. }
  1408. }
  1409. .el-table::before {
  1410. background: $searchBG;
  1411. }
  1412. .el-table {
  1413. background: $searchBG;
  1414. color: $inBlue;
  1415. thead {
  1416. }
  1417. tr {
  1418. background: $searchBG;
  1419. }
  1420. td {
  1421. text-align: center;
  1422. }
  1423. .el-table__header-wrapper {
  1424. th {
  1425. color: $inBlue;
  1426. font-size: .8rem;
  1427. }
  1428. }
  1429. thead.is-group {
  1430. .el-table__cell {
  1431. text-align: center;
  1432. background: $searchBG;
  1433. border-bottom: 1px $tableBorder;
  1434. border-right: 1px $tableBorder;
  1435. padding: 0;
  1436. font-weight: normal;
  1437. }
  1438. }
  1439. }
  1440. .el-table__empty-block {
  1441. min-height: auto;
  1442. }
  1443. .el-table__empty-text {
  1444. line-height: 30px;
  1445. }
  1446. .el-table__header {
  1447. width: auto !important
  1448. }
  1449. .el-table__empty-block {
  1450. width: auto !important
  1451. }
  1452. .el-table__body-wrapper {
  1453. .el-table__body {
  1454. width: auto !important
  1455. }
  1456. }
  1457. .el-table--enable-row-hover .el-table__body tr:hover > td.el-table__cell {
  1458. background-color: #0f3655;
  1459. }
  1460. }
  1461. </style>