unprocessDetail.vue 7.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283
  1. <template>
  2. <view>
  3. <view class="timeBox flex justify-between align-center padding-lr-sm">
  4. <view class="time">2021-01-18 15:16:45</view>
  5. <button class="cu-btn radius bg-red sm">未处理</button>
  6. </view>
  7. <view v-if="type==1">
  8. <view class="basic-info" >
  9. <view class="info-tit margin-left-xs">
  10. <text class="cuIcon-titles margin-right-xs"></text>
  11. 基本信息
  12. </view>
  13. <view class="info-content">
  14. <view class="info-one-info ">
  15. <text>站点名称:</text>
  16. <text>{{detailMessage.siteName}}</text>
  17. </view>
  18. <view>
  19. <text>线路名称:</text>
  20. <text>{{detailMessage.deviceName}}</text>
  21. </view>
  22. <view>
  23. <text>警告信息:</text>
  24. <text>{{detailMessage.measValue}}</text>
  25. </view>
  26. <view>
  27. <text>警告状态:</text>
  28. <text>{{detailMessage.measValue?'动作':'复归'}}</text>
  29. </view>
  30. <view>
  31. <text>采集终端:</text>
  32. <text>{{detailMessage.deviceCode}}</text>
  33. </view>
  34. <view>
  35. <text>站点地址:</text>
  36. <text>{{detailMessage.address}}<text class="icon iconfont map" @click="mapLocation()">&#xe612;</text></text>
  37. </view>
  38. <view>
  39. <text>联系人:</text>
  40. <text>{{detailMessage.userName}}</text>
  41. </view>
  42. <view>
  43. <text>联系方式:</text>
  44. <text>
  45. {{detailMessage.phone}}
  46. <text class="phone icon iconfont" @click="submit()">&#xe61d;</text>
  47. </text>
  48. </view>
  49. <view>
  50. <text>运行数据:</text>
  51. <text class="checkMore" @tap="goOpeDataDetail(detailMessage)">点击查看</text>
  52. </view>
  53. <view>
  54. <text>视频:</text>
  55. <text class="checkMore" @tap="goVideoDetail">点击查看</text>
  56. </view>
  57. </view>
  58. </view>
  59. <!-- 处理状态start -->
  60. <view class="processStatus">
  61. <view class="info-tit margin-left-xs">
  62. <text class="cuIcon-titles margin-right-xs"></text>
  63. 处理内容
  64. </view>
  65. <view class="padding-lr padding-bottom-lg">
  66. <form action="">
  67. <view class="cu-form-group">
  68. <!-- <textarea maxlength="-1" :disabled="modalName!=null" @input="textareaAInput" placeholder="备注信息,最多可输入50个字..."></textarea>-->
  69. <textarea class="JTxtArea lg" placeholder="备注信息,最多可输入50个字..." :maxlength="50" :data-maxnum="reason.length+'/50'"
  70. auto-height v-model="reason"></textarea>
  71. </view>
  72. <view class="btn-area">
  73. <!-- <button class="bg-orange round missReport margin-top">误 报 </button> -->
  74. <button class="bg-blue round missReport margin-top ">告警确认 </button>
  75. </view>
  76. </form>
  77. </view>
  78. </view>
  79. <!-- 处理状态end -->
  80. </view>
  81. <view v-else>
  82. <view class="basic-info">
  83. <view class="info-tit margin-left-xs">
  84. <text class="cuIcon-titles margin-right-xs"></text>
  85. 基本信息
  86. </view>
  87. <view class="info-content">
  88. <view class="info-one-info ">
  89. <text>设备名称:</text>
  90. <text>{{detailMessage.deviceName}}</text>
  91. </view>
  92. <view>
  93. <text>设备地址:</text>
  94. <text>{{detailMessage.address}}</text>
  95. </view>
  96. <view>
  97. <text>告警信息:</text>
  98. <text>{{detailMessage.address}}</text>
  99. </view>
  100. </view>
  101. </view>
  102. <!-- 报警当前情况截图start -->
  103. <view class="basic-info">
  104. <view class="info-tit margin-left-xs">
  105. <text class="cuIcon-titles margin-right-xs"></text>
  106. 报警当前情况截图
  107. </view>
  108. <view class="info-content padding-lr-lg">
  109. <image src="../../static/video-img.png" style="width:100%"></image>
  110. </view>
  111. </view>
  112. <!-- 报警当前情况截图end -->
  113. <!-- 处理状态start -->
  114. <view class="processStatus">
  115. <view class="info-tit margin-left-xs">
  116. <text class="cuIcon-titles margin-right-xs"></text>
  117. 处理内容
  118. </view>
  119. <view class="padding-lr padding-bottom-lg">
  120. <form action="">
  121. <!-- <radio-group class="block" @change="RadioChange">
  122. <view class=" flex align-center ">
  123. <radio class="blue mr-sm margin-right-xs" :class="radio=='A'?'checked':''" :checked="radio=='A'?true:false"
  124. value="A"></radio>
  125. <view class="title">单个处理</view>
  126. <radio class="blue margin-left-lg margin-right-xs" :class="radio=='B'?'checked':''" :checked="radio=='B'?true:false"
  127. value="B"></radio>
  128. <view class="title ">批量处理</view>
  129. </view>
  130. </radio-group> -->
  131. <view class="cu-form-group">
  132. <!-- <textarea maxlength="-1" :disabled="modalName!=null" @input="textareaAInput" placeholder="备注信息,最多可输入50个字..."></textarea>-->
  133. <textarea class="JTxtArea lg" placeholder="备注信息,最多可输入50个字..." :maxlength="50" :data-maxnum="reason.length+'/50'"
  134. auto-height v-model="reason"></textarea>
  135. </view>
  136. <view class="btn-area">
  137. <button class="bg-orange round missReport margin-top">误 报 </button>
  138. <button class="bg-blue round missReport margin-top ">告警确认 </button>
  139. </view>
  140. </form>
  141. </view>
  142. </view>
  143. <!-- 处理状态end -->
  144. </view>
  145. </view>
  146. </template>
  147. <script>
  148. export default {
  149. data() {
  150. return {
  151. radio: 'A',
  152. radio: 'B',
  153. modalName: null,
  154. reason: '',
  155. type: '0',
  156. detailMessage:{}
  157. }
  158. },
  159. onLoad: function(option) {
  160. this.type = option.type;
  161. this.companyCode = option.companyCode;
  162. this.processingStatus=option.processingStatus;
  163. this.alarmId = option.id;
  164. this.getUnProcessDetail({"companyCode":option.companyCode,"processingStatus":option.processingStatus,"alarmId":option.id})
  165. },
  166. methods: {
  167. async getUnProcessDetail(ming={}) {
  168. const res= await this.$myRequest({
  169. url:'IntegratedAlarm/getPowerAlarmDetails',
  170. data:ming
  171. })
  172. // this.unporcessList=res.data.data;
  173. // this.alarmUntreatedCount=res.data.alarmUntreatedCount
  174. console.log(res.data.data[0]);
  175. this.detailMessage=res.data.data[0]
  176. },
  177. submit() {
  178. uni.makePhoneCall({
  179. phoneNumber: '15122423833' //仅为示例
  180. });
  181. },
  182. mapLocation() {
  183. uni.openLocation({
  184. latitude: parseInt(this.detailMessage.latitude),
  185. longitude: parseInt(this.detailMessage.longitude),
  186. success: function() {
  187. console.log('success');
  188. }
  189. });
  190. },
  191. // 页面跳转
  192. goOpeDataDetail(detailMessage) {
  193. uni.navigateTo({
  194. url: '/pages/unprocessDetail/opeDataDetail/opeDataDetail?companyCode='+this.companyCode+'&deviceCode='+detailMessage.deviceCode+'&deviceType='+this.type+'',
  195. success: res => {},
  196. fail: () => {},
  197. complete: () => {}
  198. });
  199. },
  200. goVideoDetail() {
  201. uni.navigateTo({
  202. url: '/pages/unprocessDetail/videoDetail/videoDetail',
  203. success: res => {},
  204. fail: () => {},
  205. complete: () => {}
  206. });
  207. },
  208. RadioChange(e) {
  209. this.radio = e.detail.value
  210. },
  211. textareaAInput(e) {
  212. this.textareaAValue = e.detail.value
  213. },
  214. // textarea
  215. inputReason(e) {
  216. this.reason = e.detail.value;
  217. }
  218. }
  219. }
  220. </script>
  221. <style lang="scss">
  222. /* // 处理内容 */
  223. .cu-form-group {
  224. background: #f5f5f5;
  225. }
  226. .processStatus {
  227. textarea {
  228. background: #F5F5F5;
  229. color: #999999;
  230. }
  231. }
  232. // textarea
  233. .JTxtArea {
  234. position: relative;
  235. &.sm {
  236. min-height: 60rpx;
  237. }
  238. &.lg {
  239. min-height: 100rpx;
  240. }
  241. &:after {
  242. content: attr(data-maxnum);
  243. position: absolute;
  244. right: 10rpx;
  245. bottom: 0px;
  246. }
  247. }
  248. </style>