vBottomMenu.vue 44 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388
  1. <template>
  2. <div class="btm-box">
  3. <img class="light" src="../assets/images/integrated/btm-light.png"/>
  4. <div class="btm-left" :class="btmTipIndent">
  5. <div class="btm-left-tip">
  6. <div class="btm-left-block btm-left-state-c1"></div>
  7. 新上报
  8. </div>
  9. <div class="btm-left-tip">
  10. <div class="btm-left-block btm-left-state-c2"></div>
  11. 催办
  12. </div>
  13. <div class="btm-left-tip">
  14. <div class="btm-left-block btm-left-state-c3"></div>
  15. 已签收
  16. </div>
  17. <!-- div class="btm-left-tip">
  18. <div class="btm-left-block btm-left-state-c4"></div>
  19. 联动
  20. </div> -->
  21. <div class="btm-left-tip">
  22. <div class="btm-left-block btm-left-state-c5"></div>
  23. 办结
  24. </div>
  25. <div class="btm-left-tip">
  26. <div class="btm-left-block btm-left-state-c6"></div>
  27. 归档
  28. </div>
  29. <div class="btm-legend" @click="btmIndent">
  30. <span>图例</span>
  31. <i class="el-icon-caret-right" v-if="this.btmTipIndent !== 'btm-tip-to-right'"></i>
  32. <i class="el-icon-caret-left" v-if="this.btmTipIndent == 'btm-tip-to-right'"></i>
  33. </div>
  34. </div>
  35. <div class="bottom-menu-normal">
  36. <div v-for="(fastMenu,index) in fastMenu" :key="index" class="btm-m-con">
  37. <a><i :class="fastMenu.icon" @click.stop="showDialog(fastMenu.click)"></i><a
  38. @click.stop="showDialog(fastMenu.click)">{{ fastMenu.name }}</a>
  39. <div v-if="showChild && fastMenu.click == 'layerSwitching'" class="nav-child">
  40. <el-button type="primary"
  41. @click.stop="choseLayerSwitching('http://218.27.1.154:8090/iserver/services/map-sipingshi/rest/maps/tiedong_lunkuo',true)"
  42. class="nav-child-btn" plain>铁东
  43. </el-button>
  44. <el-button type="primary"
  45. @click.stop="choseLayerSwitching('http://218.27.1.154:8090/iserver/services/map-sipingshi/rest/maps/tiexi_lunkuo',true)"
  46. class="nav-child-btn" plain>铁西
  47. </el-button>
  48. <!-- <el-button type="danger" icon="el-icon-close" style="position: absolute;right: 0;top: 0;width: 1rem;height: 1rem;padding:0;"
  49. @click.stop="closeChild"></el-button> -->
  50. </div>
  51. <div v-if="showMeasure && fastMenu.click == 'editableLayers'" class="nav-child">
  52. <el-button type="primary"
  53. @click.stop="choseMeasuringDistance"
  54. class="nav-child-btn" plain>测距
  55. </el-button>
  56. <el-button type="primary"
  57. @click.stop="choseMeasuringArea"
  58. class="nav-child-btn" plain>测面
  59. </el-button>
  60. <el-button type="primary"
  61. @click.stop="choseMeasuringClear"
  62. class="nav-child-btn" plain>清除
  63. </el-button>
  64. </div>
  65. <!-- 林斑 -->
  66. <div v-show="showBanChild && fastMenu.click == 'forestban'" class="nav-child">
  67. <div class="forestban">
  68. <div class="forestban-con">
  69. <!-- <el-input-->
  70. <!-- placeholder="输入关键字进行过滤"-->
  71. <!-- v-model="filterbanText">-->
  72. <!-- </el-input>-->
  73. <el-tree :data="deptOptionsLiandong" ref="banDept" node-key="id" :check-strictly="true"
  74. :filter-node-method="filterbanNode" @click :accordion="true" empty-text="加载中,请稍候"
  75. :props="defaultProps"></el-tree>
  76. </div>
  77. <div class="forestban-right">
  78. <el-input placeholder="请输入内容" prefix-icon="el-icon-search" v-model="searchFB">
  79. </el-input>
  80. <el-checkbox-group v-model="banCheckList" @change="handleCheckedCitiesChangeBan">
  81. <el-checkbox v-for="(fastMenu,index) in filterbanList"
  82. label="http://218.27.1.154:8090/iserver/services/map-sipingshi/rest/maps/tiedong_lunkuo">
  83. 铁东
  84. </el-checkbox>
  85. </el-checkbox-group>
  86. </div>
  87. <el-button type="danger" icon="el-icon-close"
  88. style="position: absolute;right: 0;top: 0;width: 1rem;height: 1rem;padding:0;"
  89. @click.stop="closeBanChild"></el-button>
  90. </div>
  91. </div>
  92. <!-- 林场 -->
  93. <div v-show="showChangChild && fastMenu.click == 'forestchang'" class="nav-child">
  94. <div class="forestban">
  95. <div class="forestban-con">
  96. <!-- <el-input-->
  97. <!-- placeholder="输入关键字进行过滤"-->
  98. <!-- v-model="filterchangText">-->
  99. <!-- </el-input>-->
  100. <el-tree :data="deptOptionsLiandong" ref="changDept" node-key="id"
  101. :check-strictly="true" :filter-node-method="filterchangNode"
  102. @node-click="handlechangNodeClick" :accordion="true" empty-text="加载中,请稍候"
  103. :props="defaultProps"></el-tree>
  104. </div>
  105. <div class="forestban-right">
  106. <el-input placeholder="请输入内容" prefix-icon="el-icon-search" v-model="filterchang"
  107. @change="searchFilterchang(filterchang)">
  108. </el-input>
  109. <el-checkbox-group v-model="changCheckList" @change="handleCheckedCitiesChangeChang">
  110. <el-checkbox v-for="(item,index) in filterchangList" :label="item.farmAddress">
  111. {{ item.farmName }}
  112. </el-checkbox>
  113. </el-checkbox-group>
  114. </div>
  115. <el-button type="danger" icon="el-icon-close"
  116. style="position: absolute;right: 0;top: 0;width: 1rem;height: 1rem;padding:0;"
  117. @click.stop="closeChangChild"></el-button>
  118. </div>
  119. </div>
  120. </a>
  121. </div>
  122. </div>
  123. <div class="btm-right">
  124. <el-popover placement="top" trigger="click" :disabled="taskCount==0">
  125. <div class="btm-r-pop-info">
  126. <div class="btm-r-pop-info-box" v-for="(item,index) in taskList">
  127. <div class="btm-r-pop-info-tit">
  128. <h3>{{ item.taskSourceValue }}</h3>
  129. </div>
  130. <div class="btm-r-pop-info-con">
  131. <div class="btm-r-pop-info-list">
  132. <div class="btm-r-pop-info-list-name">标题</div>
  133. <div class="btm-r-pop-info-list-text">{{ item.taskTitle }}</div>
  134. </div>
  135. <div class="btm-r-pop-info-list">
  136. <div class="btm-r-pop-info-list-name">发起人</div>
  137. <div class="btm-r-pop-info-list-text">{{ item.sendPersonName }}</div>
  138. </div>
  139. <div class="btm-r-pop-info-list">
  140. <div class="btm-r-pop-info-list-name">发起时间</div>
  141. <div class="btm-r-pop-info-list-text">{{ item.taskSendTime }}</div>
  142. </div>
  143. <div class="btm-r-pop-info-list">
  144. <div class="btm-r-pop-info-list-name">关联事件</div>
  145. <div class="btm-r-pop-info-list-text">{{ item.eventName }}</div>
  146. </div>
  147. <div class="btm-r-pop-info-list">
  148. <div class="btm-r-pop-info-list-name">催办状态</div>
  149. <div class="btm-r-pop-info-list-text" style="color: red" v-if="item.isUrged==1">
  150. 任务催办中,请及时处理!!
  151. </div>
  152. <div class="btm-r-pop-info-list-text" v-else>正常</div>
  153. </div>
  154. </div>
  155. <div class="btm-r-pop-info-btm">
  156. <el-link type="success" @click="showEventDialog( item.eventCode )">查看详情</el-link>
  157. <div class="btm-r-pop-info-btm-btn">
  158. <el-button type="danger" @click="refusedTask(item.taskId,item.eventCode)">拒绝
  159. </el-button>
  160. <el-button type="primary" @click="receiveTask(item.taskId,item.eventCode)">领取
  161. </el-button>
  162. </div>
  163. </div>
  164. </div>
  165. </div>
  166. <el-badge :value="taskCount" slot="reference" :hidden="taskCount==0">
  167. <el-button size="small" icon="el-icon-bank-card" >任务</el-button>
  168. </el-badge>
  169. </el-popover>
  170. <el-popover placement="top" trigger="click" :disabled="messageCount==0"
  171. >
  172. <div class="btm-r-pop-info">
  173. <div class="btm-r-pop-info-box" v-for="(item,index) in messageList">
  174. <div class="btm-r-pop-info-con">
  175. <div class="btm-r-pop-info-list">
  176. <div class="btm-r-pop-info-list-name">{{ item.title }}</div>
  177. <div class="btm-r-pop-info-list-text">{{ item.content }}</div>
  178. </div>
  179. </div>
  180. <div class="btm-r-pop-info-btm">
  181. <el-link type="success" @click="selectMessageById(item.id)">标记已读</el-link>
  182. </div>
  183. </div>
  184. </div>
  185. <el-badge :value="messageCount" slot="reference" :hidden="messageCount==0"
  186. >
  187. <el-button size="small" icon="el-icon-chat-line-round">消息</el-button>
  188. </el-badge>
  189. </el-popover>
  190. <!-- 警报铃 必须放在这,放在别处不好使 -->
  191. <div class="bell" v-if="eventWarn" @click="updateAlertFalse">
  192. <div class="dot"></div>
  193. <div class="pulse"></div>
  194. <div class="pulse-big"></div>
  195. </div>
  196. <!--<el-badge type="primary">-->
  197. <!--<el-button size="small" icon="el-icon-bell" @click="updateAlertFalse">警报</el-button>-->
  198. <!--</el-badge>-->
  199. <el-badge type="warning">
  200. <el-button size="small" icon="el-icon-refresh-right" @click="refresh">刷新</el-button>
  201. </el-badge>
  202. </div>
  203. <!-- 事件详情弹层 -->
  204. <el-dialog title="事件详情" :visible.sync="eventDialog" v-if="eventDialog" customClass="customWidth" append-to-body
  205. @close="cancelEventShow()">
  206. <div class="dia-event-info">
  207. <el-row>
  208. <!-- 左侧 -->
  209. <el-col :span="18" class="dia-left">
  210. <div ref="imageTofile" style="height: 75vh;">
  211. <!-- 应急预案 -->
  212. <div class="dia-left-top">
  213. <div class="dia-left-top-tit">应急预案</div>
  214. <div class="dia-left-top-carousel">
  215. <el-carousel height="30px" direction="vertical" :interval="2000">
  216. <el-carousel-item v-if="visuForestCloudYuAnBo!=null">
  217. <a
  218. :href="visuForestCloudYuAnBo.fileUrl">{{ visuForestCloudYuAnBo.reserveName }}</a>
  219. </el-carousel-item>
  220. <el-carousel-item v-else>
  221. <a href="#">未选预案</a>
  222. </el-carousel-item>
  223. </el-carousel>
  224. </div>
  225. </div>
  226. <!-- 应急预案end -->
  227. <!-- 地图 -->
  228. <supermapTaskDialog ref="supermapTaskDialog" style="position: absolute; top:0;left: 0;"
  229. :mapDiv="'taskDialogSuperMap'"
  230. :mapSite="{zoom:12,doubleClickZoom:false,dragging:false,scrollWheelZoom:false}"
  231. :codes="['9fa5']" :isSideBySide="false" :isdynamicPlotting="false"/>
  232. <!-- 地图end -->
  233. </div>
  234. </el-col>
  235. <!-- 左侧end -->
  236. <!-- 右侧 -->
  237. <el-col :span="6" class="dia-right">
  238. <div class="e-right">
  239. <div class="forthis1-1">
  240. <dv-border-box-7 backgroundColor="#040b1f" :color="['#25335d', '#5baffd']"
  241. style="padding-bottom:1rem ;">
  242. <div class="i-list-con">
  243. <div class="this-con">
  244. <div class="z-info-list" style="margin-top: 0;">
  245. <el-timeline>
  246. <el-timeline-item color="#2bacf7" :timestamp="item.createTime"
  247. placement="top" v-for="(item,index) in eventLogList">
  248. <el-card style="width: 40vh">
  249. <div class="z-info-list-con">
  250. <div class="user-and-time flex-d">
  251. <span>{{ item.createName }}</span>
  252. <span
  253. v-if="eventLogList.length - 1 == index&&address!=null&&address!=''"><i
  254. class="el-icon-location"></i>
  255. {{ address }}</span>
  256. <span v-else></span>
  257. </div>
  258. <div class="z-info">
  259. <div class="this-con-list-info">
  260. {{ item.logContent }}
  261. </div>
  262. <div>
  263. <router-link to="#"
  264. @click.native="clickFile(itemfile.fileUrl,itemfile.fileName,itemfile.fileType)"
  265. v-for="(itemfile,indexfile) in item.fileVOs">
  266. <el-image :src="itemfile.fileUrl"
  267. v-if="itemfile.fileType=='image'"
  268. :preview-src-list="assetTypeAnImage(item.fileVOs)"
  269. style="width:3rem; height:3rem;margin: 2px;"
  270. :title="itemfile.fileName">
  271. </el-image>
  272. <img v-else-if="itemfile.fileType=='video'"
  273. style="width:3rem; height:3rem;margin: 2px;"
  274. :src="require('@/assets/fileTypeImage/mp4.png')"
  275. :title="itemfile.fileName">
  276. </img>
  277. <img v-else-if="itemfile.fileType=='word'"
  278. style="width:3rem; height:3rem;margin: 2px;"
  279. :src="require('@/assets/fileTypeImage/word.png')"
  280. :title="itemfile.fileName">
  281. </img>
  282. <img v-else-if="itemfile.fileType=='excel'"
  283. style="width:3rem; height:3rem;margin: 2px;"
  284. :src="require('@/assets/fileTypeImage/excel.png')"
  285. :title="itemfile.fileName">
  286. </img>
  287. <img v-else
  288. style="width:3rem; height:3rem;margin: 2px;"
  289. :src="require('@/assets/fileTypeImage/file.png')"
  290. :title="itemfile.fileName">
  291. </img>
  292. </router-link>
  293. </div>
  294. </div>
  295. </div>
  296. </el-card>
  297. </el-timeline-item>
  298. </el-timeline>
  299. </div>
  300. </div>
  301. </div>
  302. </dv-border-box-7>
  303. </div>
  304. <!-- <div class="forthis">-->
  305. <!-- <dv-border-box-7 backgroundColor="#040b1f" :color="['#25335d', '#5baffd']">-->
  306. <!-- <div class="i-list-con">-->
  307. <!-- <div class="this-con h-25 no-padding">-->
  308. <!-- <div class="z-info-list" style="margin-top: 0;">-->
  309. <!-- <div class="z-info-btm-grp">-->
  310. <!-- <div class="z-info-btm-grp-top">-->
  311. <!-- <div class="z-info-btm-grp-left">-->
  312. <!-- &lt;!&ndash; <el-button size="small" icon="el-icon-s-flag">责任制&ndash;&gt;-->
  313. <!-- &lt;!&ndash; </el-button>&ndash;&gt;-->
  314. <!-- <el-button size="small" icon="el-icon-upload" @click="showEventLogUpload()">上传-->
  315. <!-- </el-button>-->
  316. <!-- <el-button size="small" icon="el-icon-download" @click="toImage()">保存-->
  317. <!-- </el-button>-->
  318. <!-- </div>-->
  319. <!-- <div class="z-info-btm-grp-right">-->
  320. <!-- <el-button size="small" icon="el-icon-mic">会议-->
  321. <!-- </el-button>-->
  322. <!-- </div>-->
  323. <!-- </div>-->
  324. <!-- </div>-->
  325. <!-- </div>-->
  326. <!-- </div>-->
  327. <!-- </div>-->
  328. <!-- </dv-border-box-7>-->
  329. <!-- </div>-->
  330. </div>
  331. </el-col>
  332. <!-- 左侧end -->
  333. </el-row>
  334. </div>
  335. </el-dialog>
  336. <!-- 任务选择领取部门弹层 -->
  337. <el-dialog title="选择部门" :visible.sync="showDeptConfirm" v-if="showDeptConfirm" width="30%" append-to-body
  338. @close="cancelEventConfirm()">
  339. <el-form label-width="80px">
  340. <el-form-item label="选择部门">
  341. <el-select v-model="deptName" multiple placeholder="请选择部门" class="m-r-1rem" @change="setValue">
  342. <el-option v-for="item in deptOptions" :key="item.taskDeptId" :label="item.taskDeptName"
  343. :value="{value:item.taskDeptId,label:item.taskDeptName}">
  344. <!--:disabled="item.eventStatus=='未处理' ? false:true"-->
  345. </el-option>
  346. </el-select>
  347. </el-form-item>
  348. <el-button size="mini" type="primary" v-if="taskStatusButton=='lq'"
  349. @click="receiveTask(taskId,eventCode)">领取
  350. </el-button>
  351. <el-button size="mini" type="primary" v-if="taskStatusButton=='jj'"
  352. @click="refusedTask(taskId,eventCode)">拒绝
  353. </el-button>
  354. </el-form>
  355. </el-dialog>
  356. <!-- 图片,视频预览 -->
  357. <el-dialog title="视频预览" :visible.sync="showTcPlayer" width="40%" append-to-body>
  358. <TcPlayer ref="TcPlayer" :playVideo="playVideo" :widthHeigt="[100,100]"></TcPlayer>
  359. </el-dialog>
  360. </div>
  361. </template>
  362. <script>
  363. import {
  364. selectTaskBO,
  365. getEventDetail,
  366. selectTaskDtpts,
  367. receiveTask,
  368. refusedTask,
  369. selectMessageCount,
  370. selectMessageList,
  371. selectMessageById
  372. } from '@/api/forest'
  373. import {
  374. selectFarmByDeptId
  375. } from '@/api/vBottomMenu'
  376. import {
  377. treeselectAll as deptTreeselect
  378. } from '@/api/system/dept'
  379. import supermapTaskDialog from '@/components/supermap' //超图
  380. import TcPlayer from '@/components/TcPlayer' //视频预览
  381. import Cookies from 'js-cookie'
  382. import {selectConfigKey} from "@/api/system/config";
  383. export default {
  384. components: {
  385. supermapTaskDialog,
  386. TcPlayer
  387. },
  388. watch: {
  389. filterbanText(val) {
  390. console.log(this.$refs)
  391. this.$refs.banDept.filter(val)
  392. },
  393. filterchangText(val) {
  394. console.log(this.$refs)
  395. this.$refs.changDept.filter(val)
  396. }
  397. },
  398. data() {
  399. return {
  400. playVideo: '', //视频预览地址
  401. showTcPlayer: false, //视频预览弹窗
  402. filterbanText: '',
  403. filterchangText: '',
  404. filterbanList: [],
  405. filterchangList: [],
  406. filterchangListAll: [],
  407. eventId: null,
  408. eventCode: null,
  409. longitude: null,
  410. latitude: null,
  411. eventLogList: [], //事件详情日志
  412. eventDialog: false, //事件详情弹层
  413. taskStatusButton: null, //任务按钮
  414. visuForestCloudYuAnBo: null,
  415. address: null, //事件上报地址
  416. taskId: null, //任务ID
  417. showDeptConfirm: false, //任务领取选择部门弹窗
  418. deptOptions: [], //任务领取部门列表
  419. centerTaskTaskDepts: [], //任务领取部门
  420. deptName: [], //任务领取部门
  421. taskCount: 0, //任务数量
  422. taskList: 0, //任务列表
  423. messageCount: 0, //消息数量
  424. messageList: 0, //消息列表
  425. btmTipIndent: '', //图例收起弹出
  426. eventLocationVisible: false,
  427. showChild: false,
  428. showMeasure: false, //测量工具
  429. showBanChild: false, //林斑
  430. showChangChild: false, //林场
  431. fastMenu: [{
  432. name: '事件定位',
  433. icon: 'iconfont sj-icon-sjdw',
  434. click: 'eventLocation'
  435. },
  436. // {
  437. // name: '图层切换',
  438. // icon: 'iconfont sj-icon-tcqh',
  439. // click: 'layerSwitching'
  440. // },
  441. {
  442. name: '测量工具',
  443. icon: 'iconfont sj-icon-clgj',
  444. click: 'editableLayers'
  445. },
  446. // {
  447. // name: '林班',
  448. // icon: 'iconfont sj-icon-lbzy',
  449. // click: 'forestban'
  450. // },
  451. //
  452. // {
  453. // name: '林场',
  454. // icon: 'iconfont sj-icon-lczy',
  455. // click: 'forestchang'
  456. // },
  457. {
  458. name: '电视墙',
  459. icon: 'el-icon-s-grid',
  460. click: 'TVWall'
  461. }
  462. ],
  463. deptOptionsLiandong: [],
  464. data: [{
  465. label: '一级 1',
  466. children: [{
  467. label: '二级 1-1',
  468. children: [{
  469. label: '三级 1-1-1'
  470. }]
  471. }]
  472. }, {
  473. label: '一级 2',
  474. children: [{
  475. label: '二级 2-1',
  476. children: [{
  477. label: '三级 2-1-1'
  478. }]
  479. }, {
  480. label: '二级 2-2',
  481. children: [{
  482. label: '三级 2-2-1'
  483. }]
  484. }]
  485. }, {
  486. label: '一级 3',
  487. children: [{
  488. label: '二级 3-1',
  489. children: [{
  490. label: '三级 3-1-1'
  491. }]
  492. }, {
  493. label: '二级 3-2',
  494. children: [{
  495. label: '三级 3-2-1'
  496. }]
  497. }]
  498. }],
  499. defaultProps: {
  500. children: 'children',
  501. label: 'label'
  502. },
  503. banCheckList: [], //林班
  504. changCheckList: [], //林场
  505. searchFB: '',
  506. filterchang: '', //林场搜索
  507. btmCurrent: '',
  508. websock: '',
  509. wsurl:'',
  510. postName:'',
  511. setIntervalWesocketPush: null,
  512. websockSid: {
  513. userId: ''
  514. },
  515. eventWarn: false //webSocket事件问题警报标记
  516. }
  517. },
  518. created() {
  519. /** 查询部门树结构 */
  520. deptTreeselect().then(response => {
  521. this.deptOptionsLiandong = response.data
  522. })
  523. },
  524. destroyed() { //离开页面关闭Socket连接
  525. if (this.websock) {
  526. clearInterval(this.setIntervalWesocketPush)
  527. this.websock.close()
  528. this.websock = null
  529. }
  530. },
  531. mounted() {
  532. this.websockSid.userId=Cookies.get("userId")
  533. },
  534. methods: {
  535. // 测量距离
  536. choseMeasuringDistance(){
  537. this.$parent.$refs.supermap.choseMeasuringDistance()
  538. },
  539. // 测量面积
  540. choseMeasuringArea(){
  541. this.$parent.$refs.supermap.choseMeasuringArea()
  542. },
  543. // 测量清除
  544. choseMeasuringClear(){
  545. this.$parent.$refs.supermap.choseMeasuringAreaAll()
  546. },
  547. initWebSocket(wsurl,postName,userId) {
  548. this.postName=postName
  549. this.wsurl=wsurl
  550. selectConfigKey(wsurl).then(res => {
  551. //初始化weosocket
  552. //const wsuri = 'ws://127.0.0.1:10003/eventPush/' + userId + '/' + eventTypeDl + '/' + eventType
  553. const wsuri = res.data +postName+ userId
  554. // const wsuri = 'ws://172.28.20.82:10012/taskPush/'+userId
  555. this.websock = new WebSocket(wsuri)
  556. //console.log('建立websocket连接' + wsuri)
  557. this.websock.onopen = this.websocketonopen
  558. this.websock.onmessage = this.websocketonmessage
  559. this.websock.onerror = this.websocketonerror
  560. })
  561. },
  562. websocketonopen() { //连接建立之后执行send方法发送数据
  563. console.log('websocket连接成功')
  564. this.weosocket = true
  565. this.sendPing()
  566. },
  567. websocketonerror() { //连接建立失败重连
  568. this.initWebSocket(this.wsurl,this.postName,this.websockSid.userId)
  569. },
  570. websocketonmessage(e) { //数据接收
  571. console.log('接收数据', e.data)
  572. // let data = "{\"fromId\":\"farming\"}";
  573. // 处理收到的消息
  574. this.handleWebSoceketEvent(e.data)
  575. },
  576. handleWebSoceketEvent(val) {
  577. let that = this
  578. let data = JSON.parse(val)
  579. console.log('数据数据数据数据',data)
  580. /**
  581. * that.markersList.filter( item => data.eventCode == item.parameter).length == 0 如果地图中不存在当前事件则添加
  582. * eventPush: 事件列表消息
  583. * */
  584. let message=data.centermessageTPushrecord
  585. let message2=data.centertaskTTask
  586. if (null!=message)
  587. {
  588. console.log(message)
  589. this.messageList.push(message)
  590. this.messageCount++
  591. }else if (null!=message2)
  592. {
  593. this.taskList.push(message2)
  594. this.taskCount ++
  595. }
  596. // if (data.tag == "eventPush" && that.markersList.filter( item => data.eventCode == item.parameter).length == 0) {
  597. // getEventPush({eventCode: data.eventCode}).then((res) => {
  598. // if (res.data != undefined) {
  599. // //插入到第一条
  600. // this.eventList.unshift(res.data)
  601. // // 插入后删除最后一条 保证列表中为10条数据
  602. // if (this.eventList.length > 9)
  603. // this.eventList.splice(10, 1)
  604. // // 将收到的数据在地图上添加
  605. // this.getWebSocketEvent(res.data)
  606. // }
  607. // })
  608. // }
  609. console.log(data)
  610. },
  611. websocketsend(Data) { //数据发送
  612. this.websock.send(Data)
  613. },
  614. websocketclose(e) { //关闭
  615. console.log('断开连接', e)
  616. // clearInterval(this.setIntervalWesocketPush)
  617. this.weosocket = false
  618. },
  619. /**发送心跳
  620. * @param {number} time 心跳间隔毫秒 默认5000
  621. * @param {string} ping 心跳名称 默认字符串ping
  622. */
  623. sendPing(time = 60000, ping = {
  624. 'fromId': 'farming'
  625. }) {
  626. clearInterval(this.setIntervalWesocketPush)
  627. this.setIntervalWesocketPush = setInterval(() => {
  628. if (this.weosocket) {
  629. this.websock.send(JSON.stringify(ping))
  630. } else {
  631. // this.initWebSocket()
  632. }
  633. }, time)
  634. },
  635. filterbanNode(value, data) {
  636. //树搜索
  637. if (!value) return true
  638. return data.label.indexOf(value) !== -1
  639. },
  640. filterchangNode(value, data) {
  641. //树搜索
  642. if (!value) return true
  643. return data.label.indexOf(value) !== -1
  644. },
  645. handlechangNodeClick(node, data, value) {
  646. //获取林场列表
  647. this.filterchang = ''
  648. selectFarmByDeptId({
  649. deptId: node.id
  650. }).then(res => {
  651. this.filterchangList = res.data
  652. this.filterchangListAll = res.data
  653. })
  654. },
  655. // 返回图片列表
  656. assetTypeAnImage(filePath) {
  657. let imageList = []
  658. if (filePath != null && filePath.length > 0) {
  659. for (let i = 0; i < filePath.length; i++) {
  660. if (filePath[i].fileType == 'image') {
  661. imageList.push(filePath[i].fileUrl)
  662. }
  663. }
  664. }
  665. return imageList
  666. },
  667. clickFile(fileUrl, fileName, fileType) {
  668. if (fileType == 'image') {
  669. return
  670. } else if (fileType == 'video') {
  671. this.showTcPlayer = true
  672. setTimeout(() => {
  673. this.playVideo = fileUrl
  674. }, 500)
  675. } else {
  676. let a = document.createElement('a')
  677. a.download = fileName
  678. a.href = fileUrl
  679. a.target = '_blank'
  680. a.click()
  681. }
  682. },
  683. setValue(event) {
  684. this.centerTaskTaskDepts = []
  685. //签收选择部门
  686. if (event != null && event.length > 0) {
  687. for (let i = 0; i < event.length; i++) {
  688. if (event[i].label != undefined && event[i].value != undefined) {
  689. this.centerTaskTaskDepts.push({
  690. taskDeptId: event[i].value,
  691. taskDeptName: event[i].label
  692. })
  693. }
  694. }
  695. }
  696. },
  697. receiveTask(taskId, eventCode) {
  698. let param = {
  699. taskId: taskId,
  700. eventCode: eventCode,
  701. centerTaskTaskDepts: this.centerTaskTaskDepts
  702. }
  703. receiveTask(param).then(res => {
  704. //任务领取
  705. if (res.code == 200) {
  706. this.$message.success(`任务领取成功!`)
  707. this.deptOptions = []
  708. this.deptName = []
  709. this.centerTaskTaskDepts = []
  710. //刷新任务列表
  711. this.selectTaskList()
  712. this.showDeptConfirm = false
  713. }
  714. })
  715. },
  716. refusedTask(taskId, eventCode) {
  717. let param = {
  718. taskId: taskId,
  719. eventCode: eventCode,
  720. centerTaskTaskDepts: this.centerTaskTaskDepts
  721. }
  722. refusedTask(param).then(res => {
  723. //任务拒绝
  724. if (res.code == 200) {
  725. this.$message.success(`任务拒绝成功!`)
  726. this.deptOptions = []
  727. this.deptName = []
  728. this.centerTaskTaskDepts = []
  729. //刷新任务列表
  730. this.selectTaskList()
  731. this.showDeptConfirm = false
  732. }
  733. })
  734. },
  735. selectTaskDtpts(taskId, eventCode, state) {
  736. this.taskId = taskId
  737. this.eventCode = eventCode
  738. selectTaskDtpts({
  739. taskId: taskId
  740. }).then(res => {
  741. //任务领取部门列表
  742. if (res.code == 200) {
  743. this.deptOptions = res.data
  744. this.taskStatusButton = state
  745. this.showDeptConfirm = true
  746. }
  747. })
  748. },
  749. cancelEventShow() {
  750. console.log('关闭事件弹窗')
  751. this.eventCode = null
  752. this.eventLogList = []
  753. },
  754. cancelEventConfirm() {
  755. console.log('关闭任务选择部门')
  756. this.eventCode = null
  757. this.deptOptions = []
  758. this.deptName = []
  759. this.centerTaskTaskDepts = []
  760. },
  761. showEventDialog(eventCode) {
  762. this.eventCode = eventCode
  763. let that = this
  764. //获取事件详情
  765. getEventDetail({
  766. eventCode: eventCode
  767. }).then(res => {
  768. this.eventDialog = true
  769. this.eventLogList = res.data.eventlog
  770. this.visuForestCloudYuAnBo = res.data.visuForestCloudYuAnBo //应急预案
  771. this.address = res.data.catalogue.address
  772. this.eventType = res.data.catalogue.eventType
  773. this.eventId = res.data.catalogue.id
  774. this.longitude = res.data.catalogue.longitude
  775. this.latitude = res.data.catalogue.latitude
  776. let markersMap = {
  777. lng: 124.59,
  778. lat: 43.02,
  779. icon: 'marker',
  780. bindPopupHtml: '',
  781. click: '',
  782. parameter: '',
  783. keepBindPopup: false,
  784. isAggregation: false,
  785. radius: 0
  786. }
  787. if (res.data.catalogue.eventStatusValue == 'forest_event_status_1' && res.data.catalogue
  788. .urgeCount == 0) {
  789. markersMap.icon = 'sj-icon-map-xinshangbao'
  790. }
  791. if (res.data.catalogue.eventStatusValue == 'forest_event_status_1' && res.data.catalogue
  792. .urgeCount > 0) {
  793. markersMap.icon = 'sj-icon-map-cuiban'
  794. } else if (res.data.catalogue.eventStatusValue == 'forest_event_status_2') {
  795. markersMap.icon = 'sj-icon-map-qianshou'
  796. } else if (res.data.catalogue.eventStatusValue == 'forest_event_status_5') {
  797. markersMap.icon = 'sj-icon-map-banjie'
  798. } else if (res.data.catalogue.eventStatusValue == 'forest_event_status_6') {
  799. markersMap.icon = 'sj-icon-map-guidang'
  800. }
  801. markersMap.lng = res.data.catalogue.longitude
  802. markersMap.lat = res.data.catalogue.latitude
  803. if (res.data.eventdetail != null && res.data.eventdetail.length > 0 && res.data.eventdetail[0]
  804. .fireRadius != null && res.data.eventdetail[0].fireRadius != '' && res.data.eventdetail[0]
  805. .fireRadius > 0) {
  806. markersMap.radius = res.data.eventdetail[0].fireRadius
  807. }
  808. setTimeout(() => {
  809. // that.$refs.supermapTaskDialog.dynamicPlotting()//弹出动态绘制窗口,防止截图位置改变
  810. that.$refs.supermapTaskDialog.clearM(false)
  811. that.$refs.supermapTaskDialog.setMarkersRadius([markersMap])
  812. that.$refs.supermapTaskDialog.dropLocation(res.data.catalogue.latitude, res.data
  813. .catalogue.longitude)
  814. }, 1000)
  815. })
  816. },
  817. selectTaskList: async function() {
  818. //获取任务列表
  819. selectTaskBO().then(res => {
  820. this.taskList = res.data
  821. this.taskCount = res.data.length
  822. })
  823. this.initWebSocket('TASK_SOCKET','/taskPush/',this.websockSid.userId)
  824. },
  825. selectMessageById(id) {
  826. selectMessageById(id).then(response => {
  827. /** 获取消息列表 */
  828. this.selectMessageList();
  829. });
  830. },
  831. /** 获取消息个数 */
  832. selectMessageCount(){
  833. selectMessageCount(Cookies.get("userId")).then(response => {
  834. this.messageCount = response.data
  835. });
  836. },
  837. /** 获取消息列表 */
  838. selectMessageList(){
  839. selectMessageList(Cookies.get("userId")).then(response => {
  840. this.messageList = response.data
  841. this.messageCount = response.data.length
  842. });
  843. this.initWebSocket('MESSAGE_SOCKET','/messagePush/',this.websockSid.userId)
  844. },
  845. handleCheckedCitiesChangeBan(value) {
  846. this.choseLayerSwitchingList(this.banCheckList)
  847. },
  848. handleCheckedCitiesChangeChang(value) {
  849. this.choseLayerSwitchingList(this.changCheckList)
  850. },
  851. refresh() {
  852. window.location.reload()
  853. },
  854. showDialog(click) {
  855. window.showDialog(click)
  856. },
  857. choseLayerSwitching(url, isClear) {
  858. window.choseLayerSwitching(url, isClear)
  859. },
  860. choseLayerSwitchingList(urlList) { //选择图层(传递数组)
  861. window.choseLayerSwitchingList(urlList)
  862. },
  863. forestban() {
  864. window.forestban()
  865. console.log('林班')
  866. },
  867. forestchang() {
  868. window.forestchang()
  869. console.log('林场')
  870. },
  871. closeBanChild() {
  872. this.banCheckList = []
  873. this.showBanChild = false
  874. },
  875. closeChangChild() {
  876. this.changCheckList = []
  877. this.showChangChild = false
  878. },
  879. //图例收起弹出
  880. btmIndent() {
  881. if (this.btmTipIndent == '') {
  882. this.btmTipIndent = 'btm-tip-to-right'
  883. } else if (this.btmTipIndent == 'btm-tip-to-right') {
  884. this.btmTipIndent = ''
  885. }
  886. },
  887. searchFilterchang(filterchang) {
  888. //林场列表搜索
  889. let searchFilterchangnew = []
  890. if (filterchang != null && filterchang != '') {
  891. for (var i = 0; i < this.filterchangListAll.length; i++) {
  892. if (this.filterchangListAll[i].farmName.indexOf(filterchang) > -1) {
  893. searchFilterchangnew.push(this.filterchangListAll[i])
  894. }
  895. }
  896. this.filterchangList = searchFilterchangnew
  897. } else {
  898. this.filterchangList = this.filterchangListAll
  899. }
  900. },
  901. //标记警报
  902. updateAlert() {
  903. this.eventWarn = true
  904. },
  905. updateAlertFalse() {
  906. this.eventWarn = false
  907. this.$emit('stopAudio')
  908. }
  909. }
  910. }
  911. </script>
  912. <style rel="stylesheet/scss" lang="scss" scoped>
  913. @import '@/assets/styles/base.scss';
  914. .dotClass {
  915. width: 10px;
  916. height: 10px;
  917. border-radius: 50%;
  918. display: block;
  919. margin: -5px;
  920. }
  921. .redClass {
  922. background-color: red;
  923. width: 10px;
  924. height: 10px;
  925. border-radius: 50%;
  926. display: block;
  927. }
  928. .btm-box {
  929. width: 100%;
  930. height: auto;
  931. background: linear-gradient($btmMemu);
  932. position: absolute;
  933. z-index: 999;
  934. bottom: 0;
  935. height: 2.5rem;
  936. display: flex;
  937. align-items: center;
  938. z-index: 9999;
  939. .light {
  940. position: absolute;
  941. top: -.5rem;
  942. }
  943. .btm-left {
  944. position: absolute;
  945. font-size: .7rem;
  946. height: 2rem;
  947. line-height: 2rem;
  948. border: 1px $searchBorder;
  949. border-left: none;
  950. color: $inBlue;
  951. display: flex;
  952. -webkit-transform: translateX(-21rem) !important;
  953. transform: translateX(-21rem) !important;
  954. transition: all 0.5s ease-in-out !important;
  955. .btm-legend {
  956. height: 2rem;
  957. text-align: center;
  958. color: $inBlue;
  959. padding: 0 .5rem;
  960. cursor: pointer;
  961. }
  962. .btm-legend:hover {
  963. background-color: $tipHover;
  964. color: $white;
  965. }
  966. .btm-left-tip {
  967. display: flex;
  968. align-items: center;
  969. margin: 0 .5rem;
  970. .btm-left-block {
  971. width: 1rem;
  972. height: 1rem;
  973. margin-right: .3rem;
  974. border-radius: .2rem;
  975. }
  976. .btm-left-state-c1 {
  977. background-color: $eventStateColor-xsb;
  978. }
  979. .btm-left-state-c2 {
  980. background-color: $eventStateColor-cb;
  981. }
  982. .btm-left-state-c3 {
  983. background-color: $eventStateColor-yqs;
  984. }
  985. .btm-left-state-c4 {
  986. background-color: $eventStateColor-ld;
  987. }
  988. .btm-left-state-c5 {
  989. background-color: $eventStateColor-bj;
  990. }
  991. .btm-left-state-c6 {
  992. background-color: $eventStateColor-tb;
  993. }
  994. }
  995. }
  996. .btm-tip-to-right {
  997. -webkit-transform: translateX(0) !important;
  998. transform: translateX(0) !important;
  999. transition: all 0.5s ease-in-out !important;
  1000. }
  1001. .bottom-menu-normal {
  1002. max-width: 70%;
  1003. padding: 0 3rem;
  1004. position: absolute;
  1005. left: 50%;
  1006. transform: translateX(-50%);
  1007. bottom: 0;
  1008. z-index: 999;
  1009. border-radius: 5px;
  1010. display: flex;
  1011. justify-content: center;
  1012. align-items: center;
  1013. // background: url(../assets/images/integrated/btm-menu.png) center no-repeat;
  1014. // background-size: cover;
  1015. .btm-m-con {
  1016. position: relative;
  1017. color: $inBlue;
  1018. font-size: .5rem;
  1019. padding: .6rem 1rem;
  1020. display: flex;
  1021. align-items: center;
  1022. justify-content: center;
  1023. -webkit-transform: translateY(0);
  1024. transform: translateY(0);
  1025. transition: all 0.2s ease-in-out;
  1026. cursor: pointer;
  1027. white-space: nowrap;
  1028. i {
  1029. font-size: 1rem;
  1030. color: $inBlue;
  1031. text-shadow: 0 0 10px rgba($color: $inBlue, $alpha: .6);
  1032. margin-right: 0.2rem;
  1033. }
  1034. .nav-child {
  1035. text-shadow: none !important;
  1036. position: absolute;
  1037. bottom: 3rem;
  1038. border: 1px solid saddlebrown;
  1039. padding: .5rem;
  1040. -moz-border-radius-topleft: 0;
  1041. -moz-border-radius-bottomright: 0;
  1042. background-color: $barBgc;
  1043. box-shadow: $barShadow;
  1044. border: 1px $barBorder;
  1045. left: 50%;
  1046. transform: translateX(-50%);
  1047. color: $inBlue;
  1048. .nav-child-btn {
  1049. padding: .2rem;
  1050. }
  1051. .forestban {
  1052. display: flex;
  1053. .forestban-con {
  1054. width: 20rem;
  1055. height: 20rem;
  1056. overflow-y: scroll;
  1057. border: 1px solid rgba(51, 70, 127, 0.7);
  1058. }
  1059. .forestban-right {
  1060. width: 10rem;
  1061. height: 20rem;
  1062. overflow-y: scroll;
  1063. padding: 0 1rem;
  1064. .el-checkbox-group {
  1065. display: flex;
  1066. flex-direction: column;
  1067. label {
  1068. padding: .4rem 0;
  1069. }
  1070. .el-checkbox {
  1071. color: $white;
  1072. }
  1073. }
  1074. }
  1075. }
  1076. }
  1077. }
  1078. .btm-m-con:hover,
  1079. .on {
  1080. text-shadow: 0 0 20px rgba($color: $inBlueHover, $alpha: 1.0);
  1081. -webkit-transform: translateX(0.2rem);
  1082. transform: translateX(0.2rem);
  1083. transition: all 0.2s ease-in-out;
  1084. .nav-child {
  1085. text-shadow: none !important;
  1086. }
  1087. i {
  1088. color: $inBlueHover;
  1089. text-shadow: 0 0 20px rgba($color: $inBlueHover, $alpha: 1.0);
  1090. }
  1091. }
  1092. }
  1093. .btm-right {
  1094. position: absolute;
  1095. font-size: .7rem;
  1096. height: 2rem;
  1097. display: flex;
  1098. right: 1rem;
  1099. align-items: center;
  1100. .el-badge {
  1101. display: flex !important;
  1102. margin-left: 1.5rem;
  1103. button {
  1104. padding: 0 .3rem;
  1105. height: 1.5rem;
  1106. background-color: #112543;
  1107. color: $inBlue;
  1108. border: 1px $searchBorder;
  1109. }
  1110. }
  1111. .el-badge:hover {
  1112. -webkit-transform: translateX(0.1rem);
  1113. transform: translateX(0.1rem);
  1114. transition: all 0.2s ease-in-out;
  1115. button {
  1116. text-shadow: 0 0 15px rgba($color: $inBlueHover, $alpha: 1.0);
  1117. }
  1118. }
  1119. }
  1120. }
  1121. .btm-r-pop-info {
  1122. display: flex;
  1123. width: 35rem;
  1124. flex-direction: column;
  1125. max-height: 85vh;
  1126. min-height: fit-content;
  1127. overflow-y: scroll;
  1128. padding: 1rem;
  1129. .btm-r-pop-info-box:hover {
  1130. box-shadow: $shadowListHover;
  1131. color: $inBlue;
  1132. border: 1px $countBorder;
  1133. }
  1134. .btm-r-pop-info-box {
  1135. width: 100%;
  1136. display: flex;
  1137. flex-direction: column;
  1138. background-color: $deepBG;
  1139. padding: .5rem;
  1140. border-radius: .5rem;
  1141. color: $inBlue;
  1142. border: 1px $searchBorder;
  1143. margin-bottom: 1rem;
  1144. .btm-r-pop-info-tit {
  1145. display: flex;
  1146. padding: .5rem;
  1147. h3 {
  1148. font-weight: bolder;
  1149. }
  1150. }
  1151. .btm-r-pop-info-con {
  1152. padding: .5rem;
  1153. display: flex;
  1154. flex-direction: column;
  1155. border-top: 1px $searchBorder;
  1156. border-bottom: 1px $searchBorder;
  1157. .btm-r-pop-info-list {
  1158. display: flex;
  1159. padding: .3rem 0;
  1160. .btm-r-pop-info-list-name {
  1161. width: 3.6rem;
  1162. text-align: right;
  1163. margin-right: 1rem;
  1164. }
  1165. .btm-r-pop-info-list-text {
  1166. }
  1167. }
  1168. }
  1169. .btm-r-pop-info-btm {
  1170. padding: .5rem;
  1171. display: flex;
  1172. justify-content: space-between;
  1173. .btm-r-pop-info-btm-btn {
  1174. button {
  1175. padding: .5rem;
  1176. }
  1177. }
  1178. }
  1179. }
  1180. }
  1181. //警铃
  1182. .fire-tip {
  1183. text-align: center;
  1184. width: 100%;
  1185. font-size: 44px;
  1186. color: #ff0000;
  1187. text-shadow: 0 0 1px #ffffff;
  1188. }
  1189. .fire-address {
  1190. text-align: center;
  1191. width: 100%;
  1192. font-size: 14px;
  1193. color: rgba(255, 255, 255, 0.8);
  1194. margin-top: 44px;
  1195. }
  1196. .fire-handle {
  1197. display: block;
  1198. text-align: center;
  1199. background: #00BFF0;
  1200. color: #ffffff;
  1201. border-radius: 20px;
  1202. font-size: 14px;
  1203. width: 80px;
  1204. height: 40px;
  1205. line-height: 40px;
  1206. margin: 24px auto;
  1207. text-decoration: none
  1208. }
  1209. .fire-handle:hover {
  1210. background: #06a2ca;
  1211. }
  1212. .bell {
  1213. position: absolute;
  1214. right: 10px;
  1215. bottom: -20px;
  1216. width: 100%;
  1217. height: 320px;
  1218. z-index: 999;
  1219. }
  1220. .bell canvas {
  1221. display: block;
  1222. position: absolute;
  1223. left: 0;
  1224. top: -9px;
  1225. }
  1226. /* 保持大小不变的小圆圈 */
  1227. .dot {
  1228. position: absolute;
  1229. width: 96px;
  1230. height: 96px;
  1231. left: 160px;
  1232. top: 160px;
  1233. background: url('../assets/images/bell.gif') no-repeat;
  1234. // background: url(.) no-repeat;
  1235. background-size: 100%;
  1236. z-index: 200;
  1237. }
  1238. /* 产生动画(向外扩散变大)的圆圈 */
  1239. .pulse,
  1240. .pulse-big {
  1241. position: absolute;
  1242. width: 420px;
  1243. height: 420px;
  1244. border: 2px solid #EF2D02;
  1245. background: rgba(239, 45, 2, 0.8);
  1246. border-radius: 50%;
  1247. z-index: 100;
  1248. opacity: 0;
  1249. }
  1250. .pulse {
  1251. background: rgba(239, 45, 2, 0.6) !important;
  1252. -webkit-animation: warn 0.9s ease-out;
  1253. -moz-animation: warn 0.9s ease-out;
  1254. animation: warn 0.9s ease-out;
  1255. -webkit-animation-iteration-count: infinite;
  1256. -moz-animation-iteration-count: infinite;
  1257. animation-iteration-count: infinite;
  1258. box-shadow: 1px 1px 30px #EF2D02;
  1259. }
  1260. .pulse-big {
  1261. background: rgba(239, 45, 2, 0.6) !important;
  1262. -webkit-animation: warn1 0.9s ease-out;
  1263. -moz-animation: warn1 0.9s ease-out;
  1264. animation: warn1 0.9s ease-out;
  1265. -webkit-animation-iteration-count: infinite;
  1266. -moz-animation-iteration-count: infinite;
  1267. animation-iteration-count: infinite;
  1268. box-shadow: 1px 1px 30px #EF2D02;
  1269. }
  1270. @keyframes warn {
  1271. 0% {
  1272. -moz-transform: scale(0);
  1273. transform: scale(0);
  1274. opacity: 1;
  1275. }
  1276. 100% {
  1277. -moz-transform: scale(1);
  1278. transform: scale(1);
  1279. opacity: 0;
  1280. }
  1281. }
  1282. @keyframes warn1 {
  1283. 0% {
  1284. -o-transform: scale(0);
  1285. transform: scale(0);
  1286. opacity: 1;
  1287. }
  1288. 100% {
  1289. -o-transform: scale(0.6);
  1290. transform: scale(0.6);
  1291. opacity: 0;
  1292. }
  1293. }
  1294. </style>