buildingCheck.vue 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262
  1. <template>
  2. <view>
  3. <!-- 筛选框start -->
  4. <view style="line-height:100rpx;text-align:center">建筑名称:{{getDetailData.company_name}}</view>
  5. <!-- 筛选框end -->
  6. <view class="processStatus bg-white margin-bottom-sm" style="">
  7. <view class="info-tit margin-left-xs">
  8. <text class="cuIcon-titles margin-right-xs"></text>
  9. 安全分析
  10. </view>
  11. <view class="padding-lr padding-bottom-lg" style="min-height:500rpx">
  12. <chart :bindData="this.getDetailData" v-if="this.getDetailData.address"></chart>
  13. </view>
  14. </view>
  15. <view class="basic-info bg-white margin-bottom-sm">
  16. <view class="info-tit margin-left-xs">
  17. <text class="cuIcon-titles margin-right-xs"></text>
  18. 消防各子系统安装情况
  19. </view>
  20. <view class="info-content padding-lr padding-bottom">
  21. <table style="border:1px solid #ccc" cellspacing="0" cellpadding="0" align="center">
  22. <tr>
  23. <td>子系统安装情况</td>
  24. <td>报警数</td>
  25. <td>误报频率</td>
  26. </tr>
  27. <tr>
  28. <td>用户信息传输装置 </td>
  29. <td>报警数量{{this.getDetailData.count_yc}},处理{{this.getDetailData.count_ycl_yc}}</td>
  30. <td>{{GetPercent(this.getDetailData.count_ycl_yc,this.getDetailData.count_yc)}}</td>
  31. </tr>
  32. <tr>
  33. <td>水系统</td>
  34. <td>报警数量{{this.getDetailData.count_sj}},处理{{this.getDetailData.count_ycl_sj}}</td>
  35. <td>{{GetPercent(this.getDetailData.count_ycl_sj,this.getDetailData.count_sj)}}</td>
  36. </tr>
  37. <tr>
  38. <td>烟感</td>
  39. <td>报警数量{{this.getDetailData.count_yg}},处理1{{this.getDetailData.count_ycl_yg}} </td>
  40. <td>{{GetPercent(this.getDetailData.count_ycl_yg,this.getDetailData.count_yg)}} </td>
  41. </tr>
  42. <tr>
  43. <td>消防栓</td>
  44. <td>报警数量{{this.getDetailData.count_xfs}},处理{{this.getDetailData.count_ycl_xfs}}</td>
  45. <td>{{GetPercent(this.getDetailData.count_ycl_xfs,this.getDetailData.count_xfs)}} </td>
  46. </tr>
  47. <tr>
  48. <td>液位</td>
  49. <td>报警数量{{this.getDetailData.count_yw}},处理{{this.getDetailData.count_ycl_yw}}</td>
  50. <td>{{GetPercent(this.getDetailData.count_ycl_yw,this.getDetailData.count_yw)}} </td>
  51. </tr>
  52. <tr>
  53. <td>RTU</td>
  54. <td>报警数量{{this.getDetailData.count_rtu}},处理{{this.getDetailData.count_ycl_rtu}}</td>
  55. <td>{{GetPercent(this.getDetailData.count_ycl_rtu,this.getDetailData.count_rtu)}} </td>
  56. </tr>
  57. <tr>
  58. <td>电气火灾</td>
  59. <td>报警数量{{this.getDetailData.count_dqhz}},处理{{this.getDetailData.count_ycl_dqhz}}</td>
  60. <td>{{GetPercent(this.getDetailData.count_ycl_dqhz,this.getDetailData.count_dqhz)}} </td>
  61. </tr>
  62. <tr>
  63. <td>视频监测</td>
  64. <td>报警数量{{this.getDetailData.count_spjc}},处理{{this.getDetailData.count_ycl_spjc}}</td>
  65. <td>{{GetPercent(this.getDetailData.count_ycl_spjc,this.getDetailData.count_spjc)}} </td>
  66. </tr>
  67. <tr>
  68. <td>电梯监测</td>
  69. <td>报警数量{{this.getDetailData.count_dtjc}},处理{{this.getDetailData.count_ycl_dtjc}}</td>
  70. <td>{{GetPercent(this.getDetailData.count_ycl_dtjc,this.getDetailData.count_dtjc)}} </td>
  71. </tr>
  72. <tr>
  73. <td>井盖监测</td>
  74. <td>报警数量{{this.getDetailData.count_jgjc}},处理{{this.getDetailData.count_ycl_jgjc}}</td>
  75. <td>{{GetPercent(this.getDetailData.count_ycl_jgjc,this.getDetailData.count_jgjc)}} </td>
  76. </tr>
  77. <tr>
  78. <td>地磁监测</td>
  79. <td>报警数量{{this.getDetailData.count_dcjc}},处理{{this.getDetailData.count_ycl_dcjc}}</td>
  80. <td>{{GetPercent(this.getDetailData.count_ycl_dcjc,this.getDetailData.count_dcjc)}} </td>
  81. </tr>
  82. <tr>
  83. <td>门禁监测</td>
  84. <td>报警数量{{this.getDetailData.count_mcjc}},处理{{this.getDetailData.count_ycl_mcjc}}</td>
  85. <td>{{GetPercent(this.getDetailData.count_ycl_mcjc,this.getDetailData.count_mcjc)}} </td>
  86. </tr>
  87. <tr>
  88. <td>可燃气体监测</td>
  89. <td>报警数量{{this.getDetailData.count_krqt}},处理{{this.getDetailData.count_ycl_krqt}}</td>
  90. <td>{{GetPercent(this.getDetailData.count_ycl_krqt,this.getDetailData.count_krqt)}} </td>
  91. </tr>
  92. </table>
  93. </view>
  94. </view>
  95. <view class="processStatus bg-white margin-bottom-sm">
  96. <view class="info-tit margin-left-xs">
  97. <text class="cuIcon-titles margin-right-xs"></text>
  98. 存在问题或需要改进事项
  99. </view>
  100. <view class="padding-lr padding-bottom-lg" style="font-size:30rpx;text-indent:60rpx;line-height:1.7">
  101. <view v-if="this.getDetailData.state_yc==1">用户信息传输装置该类设备隐患极高或存在故障,建议尽早进行排查;</view>
  102. <view v-if="this.getDetailData.state_sj==1">水系统该类设备隐患极高或存在故障,建议尽早进行排查;</view>
  103. <view v-if="this.getDetailData.state_yg==1"> 烟感栓该类设备隐患极高或存在故障,建议尽早进行排查;</view>
  104. <view v-if="this.getDetailData.state_xfs==1"> 消防栓该类设备隐患极高或存在故障,建议尽早进行排查;</view>
  105. <view v-if="this.getDetailData.state_yw==1">液位该类设备隐患极高或存在故障,建议尽早进行排查;</view>
  106. <view v-if="this.getDetailData.state_rtu==1">RTU该类设备隐患极高或存在故障,建议尽早进行排查;</view>
  107. <view v-if="this.getDetailData.state_dqhz==1">电气火灾该类设备隐患极高或存在故障,建议尽早进行排查;</view>
  108. <view v-if="this.getDetailData.state_spjc==1"> 视频监测该类设备隐患极高或存在故障,建议尽早进行排查;</view>
  109. <view v-if="this.getDetailData.state_dtjc==1"> 电梯监测该类设备隐患极高或存在故障,建议尽早进行排查; </view>
  110. <view v-if="this.getDetailData.state_dcjc==1">地磁监测该类设备隐患极高或存在故障,建议尽早进行排查;</view>
  111. <view v-if="this.getDetailData.state_mcjc ==1">门禁监测该类设备隐患极高或存在故障,建议尽早进行排查;</view>
  112. <view v-if="this.getDetailData.state_krqt==1">可燃气体监测该类设备隐患极高或存在故障,建议尽早进行排查;</view>
  113. </view>
  114. </view>
  115. <view class="processStatus bg-white margin-bottom-sm">
  116. <view class="info-tit margin-left-xs">
  117. <text class="cuIcon-titles margin-right-xs"></text>
  118. 其他事宜
  119. </view>
  120. <view class="padding-lr padding-bottom-lg" style="font-size:30rpx;text-indent:60rpx;line-height:1.7">
  121. <view v-if="this.getDetailData.state_yc==0">目前数据反映:用户信息传输装置该类设备通信情况较好,需要保持;</view>
  122. <view v-if="this.getDetailData.state_sj==0">目前数据反映:水系统该类设备通信情况较好,需要保持;</view>
  123. <view v-if="this.getDetailData.state_yg==0">目前数据反映: 烟感栓该类设备通信情况较好,需要保持;</view>
  124. <view v-if="this.getDetailData.state_xfs==0">目前数据反映: 消防栓该类设备通信情况较好,需要保持;</view>
  125. <view v-if="this.getDetailData.state_yw==0">目前数据反映:液位该类设备通信情况较好,需要保持;</view>
  126. <view v-if="this.getDetailData.state_rtu==0">目前数据反映:RTU该类设备通信情况较好,需要保持;</view>
  127. <view v-if="this.getDetailData.state_dqhz==0">目前数据反映:电气火灾该类设备通信情况较好,需要保持;</view>
  128. <view v-if="this.getDetailData.state_spjc==0">目前数据反映: 视频监测该类设备通信情况较好,需要保持;</view>
  129. <view v-if="this.getDetailData.state_dtjc==0">目前数据反映: 电梯监测该类设备通信情况较好,需要保持; </view>
  130. <view v-if="this.getDetailData.state_dcjc==0">目前数据反映:地磁监测该类设备通信情况较好,需要保持;</view>
  131. <view v-if="this.getDetailData.state_mcjc ==0">目前数据反映:门禁监测该类设备通信情况较好,需要保持;</view>
  132. <view v-if="this.getDetailData.state_krqt==0">目前数据反映:可燃气体监测该类设备通信情况较好,需要保持;</view>
  133. </view>
  134. </view>
  135. </view>
  136. </template>
  137. <script>
  138. // import json from '../../data/json.js';
  139. import chart from './components/chart/chart.vue';
  140. export default {
  141. components: {
  142. chart,
  143. },
  144. data() {
  145. return {
  146. getDetailData:{},
  147. // deviceOffLineData:json.deviceOffLineData,
  148. siteListRes: 0,
  149. siteName: '',
  150. type: '0',
  151. siteListData: [],
  152. modalName: null,
  153. listTouchStart: 0,
  154. listTouchDirection: null,
  155. CustomBar: this.CustomBar,
  156. staticData: {
  157. "msg": "\u64cd\u4f5c\u6210\u529f",
  158. "flag": true,
  159. "companyCode": "1,2,3,4,5,6,7,8,12,13,14,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39",
  160. "data": [{
  161. "statisticalPeriod": "2021-03-16~2021-04-16",
  162. "smartElectricityCount": "178",
  163. "videoMonitoringCount": "12456",
  164. "alarmCount": 12627,
  165. "eventCount": 2,
  166. "hiddenDangerCount": 4,
  167. "offlineCount": 20,
  168. "faultCount": 30,
  169. "earlyWarningCount": 100,
  170. "otherCount": 99,
  171. "normalCount": 66,
  172. "integratedAlarmCount": 12627,
  173. "unprocessedCount": 0
  174. }]
  175. }
  176. }
  177. },
  178. onLoad: function(option) {
  179. this.getDetails({'company_code':uni.getStorageSync('selectedCode')})
  180. },
  181. methods: {
  182. GetPercent(num, total) {
  183. /// <summary>
  184. /// 求百分比
  185. /// </summary>
  186. /// <param name="num">当前数</param>
  187. /// <param name="total">总数</param>
  188. num = parseFloat(num);
  189. total = parseFloat(total);
  190. if (isNaN(num) || isNaN(total)) {
  191. return "-";
  192. }
  193. return total <= 0 ? "0%" : (Math.round(num / total * 10000) / 100.00)+"%";
  194. },
  195. // 建筑体检数据请求
  196. async getDetails(params = {}) {
  197. const res = await this.$myRequest({
  198. url: 'PhysicalExamination/getPhysicalExamination',
  199. data: params,
  200. showLoading: true
  201. })
  202. this.getDetailData = res.data.data[0];
  203. },
  204. InputFocus(e) {
  205. this.InputBottom = e.detail.height
  206. },
  207. InputBlur(e) {
  208. this.InputBottom = 0
  209. },
  210. }
  211. }
  212. </script>
  213. <style lang="scss">
  214. page {
  215. background: #EDEDED;
  216. }
  217. /deep/ .leave_cont .ul .li {
  218. width: 42% !important;
  219. }
  220. /deep/ .leave_cont .ul {
  221. background: #fff;
  222. }
  223. /deep/ .date {
  224. font-size: 28rpx;
  225. }
  226. /deep/ .leave_cont {
  227. width: 76%
  228. }
  229. </style>