Videosurveillance.vue 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310
  1. <template>
  2. <view class="billall">
  3. <!-- <view class="topbill">
  4. <view class="topbilledit" @click="typechange">
  5. <view class="changetime1">
  6. {{mytype}}
  7. </view>
  8. <view class="changetime2">
  9. <u-icon name="arrow-down-fill" color="#666666" size="20"></u-icon>
  10. </view>
  11. </view>
  12. </view> -->
  13. <view class="u-listdata">
  14. <view style="padding:10rpx 0 0 30rpx">
  15. 共有 <span style="color: red">{{totalnumber}}</span>条记录
  16. </view>
  17. <u-list @scrolltolower="scrolltolower" :pagingEnabled='true'>
  18. <u-list-item v-for="(item, index) in indexList" :key="index">
  19. <view class="companylist" @click="seedetail(item)">
  20. <view class="settled">
  21. 查看
  22. </view>
  23. <view class="Currentamount" style="margin-top: 20rpx;">
  24. 通道名: {{item.channelName}}
  25. </view>
  26. <view class="Currentamount">
  27. 通道号: {{item.channelNo}}
  28. </view>
  29. <view class="Currentamount">
  30. 设备序列号: {{item.deviceSerial}}
  31. </view>
  32. <!-- <view class="Currentamount">
  33. 直播地址: {{item.url}}
  34. </view> -->
  35. </view>
  36. </u-list-item>
  37. </u-list>
  38. </view>
  39. <!--
  40. <u-picker :show="showtype" :columns="columnstype" keyName="label" @confirm="confirmtype" @cancel='canceltype'>
  41. </u-picker> -->
  42. </view>
  43. </template>
  44. <script>
  45. //import { isEmpty, getDictDataList } from "@/utils/index";
  46. export default {
  47. components: {
  48. },
  49. data() {
  50. return {
  51. totalnumber: 0,
  52. setyesno: true,
  53. indexList: [],
  54. dataList: [],
  55. dataForm: {
  56. "accessToken": "",
  57. "channelNo": "",
  58. "deviceSerial": "",
  59. "expireTime": "3600",
  60. "pageSize": 10,
  61. "pageStart": 0,
  62. "protocol": 1
  63. },
  64. pd: true,
  65. showtype: false,
  66. showdct: false,
  67. mytitle: '',
  68. alldata: [],
  69. showfloor: false,
  70. loading: false,
  71. columns: [],
  72. columnData: [],
  73. myday: '',
  74. mytype: '全部',
  75. showPicker: false,
  76. //myday: currentDate,
  77. columnstype: [
  78. [{
  79. label: '全部',
  80. id: ''
  81. }, {
  82. label: '已关闭',
  83. id: '-1'
  84. },
  85. {
  86. label: '待支付',
  87. id: '0'
  88. },
  89. {
  90. label: '已支付',
  91. id: '1'
  92. },
  93. ]
  94. ],
  95. }
  96. },
  97. //监听页面加载,其参数为上个页面传递的数据,参数类型为 Object(用于页面传参
  98. onLoad() {
  99. this.getalldata();
  100. // this.loadmore();
  101. },
  102. //监听页面初次渲染完成。注意如果渲染速度快,会在页面进入动画完成前触发
  103. onReady() {
  104. // 微信小程序需要用此写法
  105. },
  106. //监听页面隐藏
  107. onHide() {},
  108. //监听窗口尺寸变化
  109. onResize() {},
  110. //监听页面卸载
  111. onUnload() {},
  112. //监听用户下拉动作,一般用于下拉刷新
  113. onPullDownRefresh() {},
  114. methods: {
  115. seedetail(e) {
  116. uni.navigateTo({
  117. url: `/pages/Workorder/Videosurveillance/Videoplayback/Videoplayback?companyOrgId=${e.url}`
  118. });
  119. },
  120. scrolltolower() {
  121. if (this.pd) {
  122. this.getalldata();
  123. } else {
  124. return
  125. }
  126. },
  127. getalldata() {
  128. this.$api.post('/video/page', this.dataForm)
  129. .then(res => {
  130. console.log('111111111111111111', res.data.data)
  131. this.totalnumber = res.data.data.total;
  132. if (res.data.data.list.length != 0) {
  133. this.indexList.push(...res.data.data.list);
  134. this.dataForm.page = this.dataForm.page + 1;
  135. this.pd = true;
  136. } else {
  137. uni.showToast({
  138. title: '暂无更多数据了',
  139. icon: 'none',
  140. duration: 1500
  141. })
  142. this.pd = false;
  143. }
  144. })
  145. },
  146. // canceltype() {
  147. // this.showtype = false;
  148. // },
  149. // confirmtype(e) {
  150. // console.log('111111111111111111', e.value[0])
  151. // this.showtype = false;
  152. // this.mytype = e.value[0].label;
  153. // this.dataForm.status = e.value[0].id;
  154. // this.indexList = [];
  155. // this.dataForm.page = 1;
  156. // this.getalldata();
  157. // },
  158. // typechange() {
  159. // this.showtype = true;
  160. // },
  161. }
  162. }
  163. </script>
  164. <style lang="scss">
  165. .Currentamount {
  166. padding-left: 30rpx;
  167. height: 50rpx;
  168. line-height: 50rpx;
  169. color: #BCB3A7;
  170. span {
  171. color: #FA5555;
  172. padding-left: 9rpx;
  173. }
  174. }
  175. .Callfee {
  176. width: 100rpx;
  177. height: 45rpx;
  178. text-align: center;
  179. line-height: 45rpx;
  180. color: #5C8FFF;
  181. border: 1px solid #5C8FFF;
  182. font-size: 22rpx;
  183. position: absolute;
  184. bottom: 10rpx;
  185. right: 10px;
  186. font-weight: bold;
  187. }
  188. .companylist {
  189. margin: 20rpx 30rpx;
  190. background: #fff;
  191. height: 190rpx;
  192. border-radius: 10px;
  193. position: relative;
  194. h3 {
  195. height: 70rpx;
  196. line-height: 70rpx;
  197. padding-left: 30rpx;
  198. }
  199. }
  200. .settled {
  201. background-color: #09C700;
  202. width: 100rpx;
  203. height: 60rpx;
  204. text-align: center;
  205. line-height: 60rpx;
  206. color: #fff;
  207. font-size: 14rpx;
  208. position: absolute;
  209. top: 0px;
  210. right: 0px;
  211. border-top-right-radius: 10rpx;
  212. border-bottom-left-radius: 10rpx;
  213. }
  214. .outstanding {
  215. background-color: #30D3A2;
  216. width: 100rpx;
  217. height: 40rpx;
  218. text-align: center;
  219. line-height: 40rpx;
  220. color: #fff;
  221. font-size: 14rpx;
  222. position: absolute;
  223. top: 0px;
  224. right: 0px;
  225. border-top-right-radius: 10rpx;
  226. border-bottom-left-radius: 10rpx;
  227. }
  228. .guanbi {
  229. background-color: red;
  230. width: 100rpx;
  231. height: 40rpx;
  232. text-align: center;
  233. line-height: 40rpx;
  234. color: #fff;
  235. font-size: 14rpx;
  236. position: absolute;
  237. top: 0px;
  238. right: 0px;
  239. border-top-right-radius: 10rpx;
  240. border-bottom-left-radius: 10rpx;
  241. }
  242. .billall {}
  243. .topbill {
  244. display: flex;
  245. justify-content: center;
  246. align-items: center;
  247. height: 100rpx;
  248. background-color: #e6e6e6;
  249. }
  250. .topbilledit {
  251. display: flex;
  252. justify-content: space-around;
  253. align-items: center;
  254. }
  255. .changetime1 {
  256. padding-right: 10rpx;
  257. }
  258. </style>