detailsPage.vue 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380
  1. <template>
  2. <div class="infoPage">
  3. <div class="title-box">
  4. <p>详情</p>
  5. <p class="inquire-button-one">处理</p>
  6. <p class="reset-button-one" @click="backPage">返回</p>
  7. </div>
  8. <div class="bottom-max-bug-box scrollbar-box">
  9. <div class="left-max-big-box scrollbar-box">
  10. <div class="text-box">
  11. <p>报警时间:</p>
  12. <p>内容内容内容内容内容内容内容内容内容内容内容内容内容内容内容内容内容内容</p>
  13. </div>
  14. <div class="text-box">
  15. <p>报警内容:</p>
  16. <p></p>
  17. </div>
  18. <div class="text-box">
  19. <p>学院:</p>
  20. <p></p>
  21. </div>
  22. <div class="text-box">
  23. <p>位置:</p>
  24. <p></p>
  25. </div>
  26. <div class="text-box">
  27. <p>气瓶规格:</p>
  28. <p></p>
  29. </div>
  30. <div class="text-box">
  31. <p>气体余量:</p>
  32. <p></p>
  33. </div>
  34. <div class="text-box">
  35. <p>当前使用人:</p>
  36. <p></p>
  37. </div>
  38. <div class="text-box">
  39. <p>气瓶所有人:</p>
  40. <p></p>
  41. </div>
  42. <div class="img-max-box">
  43. <img v-for="(url,index) in imgList" :key="index"
  44. :src="url" @click="lockImg(url)">
  45. </div>
  46. </div>
  47. <div class="right-max-big-box">
  48. <div class="right-top-max-big-box">
  49. <p class="right-title-p">查看监控</p>
  50. <div class="right-top-button-box scrollbar-x-box">
  51. <p :class="topButtonIndex == index?'buttonColorA':'buttonColorB'"
  52. @click="topButtonClick(index)"
  53. v-for="(item,index) in topButton" :key="index">{{item.name}}</p>
  54. </div>
  55. <video class="video-box" id="alarmRecordDetailsPageVideo" ref="videoRef" autoplay controls muted width="454px" height="252px" :poster="videoCover"></video>
  56. </div>
  57. <div class="right-bottom-max-big-box">
  58. <p class="right-title-p">语音广播</p>
  59. <div class="right-bottom-button-max-box">
  60. <p class="right-bottom-button-title-p">选择播放喇叭</p>
  61. <div class="right-bottom-button-box scrollbar-x-box">
  62. <p :class="item.type?'buttonColorA':'buttonColorB'"
  63. @click="bottomButtonClick(item)"
  64. v-for="(item,index) in bottomButton" :key="index">{{item.name}}</p>
  65. </div>
  66. </div>
  67. <div class="right-bottom-input-box">
  68. <p>播报内容</p>
  69. <el-input
  70. type="textarea"
  71. resize="none"
  72. :rows="4"
  73. style="width:668px;height:100px;"
  74. v-model="text"
  75. placeholder="请输入播报内容"
  76. maxLength="50"
  77. clearable/>
  78. </div>
  79. <p class="inquire-button-one right-bottom-button" @click="releaseButton">发布</p>
  80. </div>
  81. </div>
  82. </div>
  83. <!--查看图片-->
  84. <el-dialog title="抓拍照片" :visible.sync="imgOpen" width="1200px" append-to-body
  85. :close-on-click-modal="false">
  86. <div class="scrollbar-box" style="width:1160px;margin:0 auto;max-height:700px;overflow-y: scroll">
  87. <img :src="imgUrl" style="display:block;max-width:1156px;margin:0 auto;">
  88. </div>
  89. </el-dialog>
  90. </div>
  91. </template>
  92. <script>
  93. import { handle } from "@/api/medicUniversity-3_1/index";
  94. export default {
  95. name: "infoPage",
  96. props:{
  97. propsInfoData:{},
  98. },
  99. data() {
  100. return {
  101. imgList:[
  102. 'https://img2.baidu.com/it/u=3596352791,3086982929&fm=253&fmt=auto&app=120&f=JPEG?w=1280&h=800',
  103. 'https://img2.baidu.com/it/u=3596352791,3086982929&fm=253&fmt=auto&app=120&f=JPEG?w=1280&h=800',
  104. 'https://img2.baidu.com/it/u=3596352791,3086982929&fm=253&fmt=auto&app=120&f=JPEG?w=1280&h=800',
  105. 'https://img2.baidu.com/it/u=3596352791,3086982929&fm=253&fmt=auto&app=120&f=JPEG?w=1280&h=800',
  106. ],
  107. videoCover:window.location.href.split('://')[0]+'://' + this.judgmentNetworkReturnAddress() + "/admin/" + localStorage.getItem('videoCover'),
  108. topButtonIndex:0,
  109. topButton:[
  110. {id:'1',name:'走廊摄像头1'},{id:'2',name:'走廊摄像头2'},{id:'3',name:'走廊摄像头3'},
  111. {id:'1',name:'走廊摄像头1'},{id:'2',name:'走廊摄像头2'},{id:'3',name:'走廊摄像头3'},
  112. {id:'1',name:'走廊摄像头1'},{id:'2',name:'走廊摄像头2'},{id:'3',name:'走廊摄像头3'},
  113. ],
  114. bottomButtonIndex:0,
  115. bottomButton:[
  116. {id:'1',name:'喇叭1',type:false},{id:'2',name:'喇叭1',type:false},
  117. {id:'3',name:'喇叭1',type:false},{id:'4',name:'喇叭1',type:false},
  118. {id:'5',name:'喇叭1',type:false},{id:'6',name:'喇叭1',type:false},
  119. {id:'7',name:'喇叭1',type:false},{id:'8',name:'喇叭1',type:false},
  120. {id:'9',name:'喇叭1',type:false},{id:'10',name:'喇叭1',type:false},
  121. ],
  122. text:"",
  123. //查看图片
  124. imgOpen:false,
  125. imgUrl:"",
  126. }
  127. },
  128. created() {
  129. },
  130. mounted(){
  131. },
  132. methods:{
  133. //发布按钮
  134. releaseButton(){
  135. let self = this;
  136. let num = 0;
  137. for(let i=0;i<self.bottomButton.length;i++){
  138. if(self.bottomButton[i].type){
  139. num++
  140. }
  141. }
  142. if(num == 0){
  143. this.msgError('请选择喇叭')
  144. return
  145. }
  146. if(!this.text){
  147. this.msgError('请输入播报内容')
  148. return
  149. }
  150. },
  151. //查看图片
  152. lockImg(url){
  153. console.log("url",url);
  154. this.imgUrl = url;
  155. this.imgOpen = true;
  156. },
  157. // 监控选择
  158. topButtonClick(type){
  159. if(this.topButtonIndex != type){
  160. this.topButtonIndex = type;
  161. }
  162. },
  163. //喇叭选择
  164. bottomButtonClick(item){
  165. item.type = !item.type
  166. },
  167. //处理报警记录
  168. handle(){
  169. let self = this;
  170. if(self.propsInfoData.buttonType != 1){
  171. self.msgError('只有该实验室负责人可以处理')
  172. return
  173. }
  174. this.$confirm('确定要处理吗?', "警告", {
  175. confirmButtonText: "确定",
  176. cancelButtonText: "取消",
  177. type: "warning"
  178. }).then(function() {
  179. handle({id:self.propsInfoData.id}).then(response => {
  180. self.msgSuccess(response.msg);
  181. self.$set(self.propsInfoData,'handlingStatus',2);
  182. self.$set(self.propsInfoData,'operate','已处理');
  183. })
  184. }).then(() => {
  185. }).catch(() => {});
  186. },
  187. backPage(){
  188. this.$parent.pageToggle(1);
  189. },
  190. }
  191. }
  192. </script>
  193. <style scoped lang="scss">
  194. .infoPage{
  195. flex:1;
  196. display: flex;
  197. flex-direction: column;
  198. overflow: hidden;
  199. border:1px solid #dedede;
  200. p{
  201. margin:0;
  202. padding:0;
  203. }
  204. .title-box{
  205. display: flex;
  206. height:90px;
  207. border-bottom: 1px solid #D8D8D8;
  208. p:nth-child(1){
  209. flex:1;
  210. font-size:16px;
  211. line-height:90px;
  212. margin-left:18px;
  213. color:#0045AF;
  214. }
  215. p:nth-child(2),p:nth-child(3){
  216. margin:25px 25px 0 0;
  217. }
  218. }
  219. .bottom-max-bug-box{
  220. font-weight: 500;
  221. flex:1;
  222. padding:20px 79px;
  223. .left-max-big-box{
  224. width:559px;
  225. height:750px;
  226. display: inline-block;
  227. margin-right:22px;
  228. border-radius:10px;
  229. box-shadow: 0 0 8px 1px rgba(0, 0, 0, 0.1) !important;
  230. padding:28px 28px 0 28px;
  231. .text-box{
  232. display: flex;
  233. font-size:14px;
  234. line-height:20px;
  235. margin-bottom:28px;
  236. p:nth-child(1){
  237. width:100px;
  238. text-align: right;
  239. color:#333;
  240. }
  241. p:nth-child(2){
  242. flex: 1;
  243. color:#666;
  244. margin-left:6px;
  245. }
  246. }
  247. .img-max-box{
  248. img{
  249. cursor: pointer;
  250. display: inline-block;
  251. width:240px;
  252. height:160px;
  253. margin-bottom:14px;
  254. }
  255. img:nth-child(odd){
  256. margin-right:18px;
  257. }
  258. }
  259. }
  260. .right-max-big-box{
  261. width:839px;
  262. display: inline-block;
  263. .right-top-max-big-box{
  264. height:414px;
  265. overflow: hidden;
  266. border-radius:10px;
  267. box-shadow: 0 0 8px 1px rgba(0, 0, 0, 0.1) !important;
  268. .right-title-p{
  269. font-size:16px;
  270. color:#333;
  271. line-height:24px;
  272. margin:18px 0 12px 24px;
  273. }
  274. .right-top-button-box{
  275. margin:0 25px;
  276. width:788px;
  277. height: 42px;
  278. p:nth-child(1){
  279. margin:0;
  280. }
  281. p{
  282. display: inline-block;
  283. margin:0 0 0 18px;
  284. padding:0 18px;
  285. line-height:30px;
  286. border-radius:6px;
  287. font-size:14px;
  288. cursor: pointer;
  289. }
  290. .buttonColorA{
  291. border:1px solid #0183FA;
  292. background:#0183FA;
  293. color:#fff;
  294. }
  295. .buttonColorB{
  296. border:1px solid #E0E0E0;
  297. color:#333;
  298. }
  299. }
  300. .video-box{
  301. height:252px;
  302. width:454px;
  303. margin:34px 192px;
  304. }
  305. }
  306. .right-bottom-max-big-box{
  307. margin-top:20px;
  308. height:316px;
  309. overflow: hidden;
  310. border-radius:10px;
  311. box-shadow: 0 0 8px 1px rgba(0, 0, 0, 0.1) !important;
  312. .right-title-p{
  313. font-size:16px;
  314. color:#333;
  315. line-height:24px;
  316. margin:18px 0 12px 24px;
  317. }
  318. .right-bottom-button-max-box{
  319. margin-top:25px;
  320. display: flex;
  321. .right-bottom-button-title-p{
  322. line-height:32px;
  323. margin-left:25px;
  324. font-size:16px;
  325. margin-right:25px;
  326. }
  327. .right-bottom-button-box{
  328. width:668px;
  329. height: 42px;
  330. p:nth-child(1){
  331. margin:0;
  332. }
  333. p{
  334. display: inline-block;
  335. margin-left:18px;
  336. padding:0 30px;
  337. line-height:30px;
  338. border-radius:6px;
  339. font-size:14px;
  340. cursor: pointer;
  341. }
  342. .buttonColorA{
  343. border:1px solid #0183FA;
  344. background:#0183FA;
  345. color:#fff;
  346. }
  347. .buttonColorB{
  348. border:1px solid #E0E0E0;
  349. color:#333;
  350. }
  351. }
  352. }
  353. .right-bottom-input-box{
  354. margin-top:30px;
  355. display: flex;
  356. p{
  357. line-height:32px;
  358. margin-left:25px;
  359. font-size:16px;
  360. text-align: right;
  361. width:98px;
  362. margin-right:24px;
  363. }
  364. }
  365. .right-bottom-button{
  366. width:100px;
  367. line-height:40px;
  368. text-align: center;
  369. margin:15px 370px;
  370. }
  371. }
  372. }
  373. }
  374. }
  375. </style>