ucharts.vue 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699
  1. <template>
  2. <view>
  3. <view class="status_bar"></view>
  4. <view class="" style="position: relative;top: 44px;">
  5. <view style="position: fixed;z-index: 100;width: 100%;color: #FFFFFF;">
  6. <uni-nav-bar @clickLeft="clickLeft" left-icon="back" left-text="返回" title="历史数据"></uni-nav-bar>
  7. </view>
  8. <view class="selecttimes" @click="tiemshow=!tiemshow">
  9. <view class="timesbox">
  10. <image
  11. :src="'http://www.hnyfwlw.com:8006/bigdata_app'+'/image/prevention/1acfe2751c01d3786cdc49b83d7e505.png'"
  12. mode=""></image>
  13. <p>{{timetab(oldtime)}}</p>
  14. <p class="or">~</p>
  15. <p>{{timetab(newtime)}}</p>
  16. <u-icon name="rili" custom-prefix="custom-icon" class="icon"></u-icon>
  17. </view>
  18. <u-calendar v-model="tiemshow" mode="range" @change="tiemchange"></u-calendar>
  19. </view>
  20. <view class="shuju_one">
  21. <view class="shuju_one_title">
  22. <view :class="titleidnex==index?'title_text_color':'tltle_text'" v-for="(item,index) in titletext"
  23. :key="index" @click="changeindex(index)">
  24. {{item}}
  25. </view>
  26. </view>
  27. <view class="canvastishi" v-if="!canvastishiTF && !dataloadingtf">
  28. 暂无数据
  29. </view>
  30. <view class="canvastishi" v-if="dataloadingtf">
  31. <p class="dataloading">加载中</p>
  32. </view>
  33. <canvas v-if="canvastishiTF" canvas-id="canvasColumnA" id="canvasColumnA" class="charts"
  34. @touchstart="touchLineA($event)" @touchmove="moveLineA($event)" @touchend="touchEndLineA($event)"
  35. disable-scroll=true
  36. :style="{'width':cWidth*pixelRatio+'px','height':cHeight*pixelRatio+'px', 'transform': 'scale('+(1/pixelRatio)+')','margin-left':-cWidth*(pixelRatio-1)/2+'px','margin-top':-cHeight*(pixelRatio-1)/2+'px'}"></canvas>
  37. </view>
  38. <view class="shuju_two" v-if="allqingchong">
  39. <view class="canvastishi" v-if="!canvastishiTF && !dataloadingtf">
  40. 暂无数据
  41. </view>
  42. <view class="canvastishi" v-if="dataloadingtf">
  43. <p class="dataloading">加载中</p>
  44. </view>
  45. <canvas v-if="canvastishiTF" canvas-id="canvasColumnB" id="canvasColumnB" class="charts"
  46. @touchstart="touchLineBb($event)" @touchmove="moveLineBb($event)" @touchend="touchEndLineBb($event)"
  47. disable-scroll=true
  48. :style="{'width':cWidth*pixelRatio+'px','height':cHeight*pixelRatio+'px', 'transform': 'scale('+(1/pixelRatio)+')','margin-left':-cWidth*(pixelRatio-1)/2+'px','margin-top':-cHeight*(pixelRatio-1)/2+'px'}"></canvas>
  49. </view>
  50. <view class="refresh" @click="refresh" :style="{'top': allqingchong?'1380rpx':'790rpx'}">
  51. 刷 新
  52. </view>
  53. <view class="condition" :style="{'top': allqingchong?'1450rpx':'870rpx'}">
  54. <scroll-view scroll-top="0" scroll-x="true" class="scroll-X">
  55. <table class="table" v-if="$QueryPermission(264)">
  56. <tr class="tr">
  57. <th class="th" v-for="(item,index) in thdata" :key="'a'+index">{{item}}</th>
  58. </tr>
  59. <tr class="tr" v-for="(items,indexs) in eqlistdata" :key="'b'+indexs" v-if="forbidden">
  60. <td class="td">{{items.d_h_t.addtime|timeFormat()}}</td>
  61. <td class="td">{{items.d_h_t.ds}}</td>
  62. <td class="td">{{items.d_h_t.ws}}</td>
  63. <td class="td">{{items.d_h_t.rps}}</td>
  64. <td class="td">{{items.d_h_t.tps}}</td>
  65. <td class="td">{{items.d_h_t.dps}}</td>
  66. <td class="td">{{items.d_h_t.tt}}</td>
  67. <td class="td">{{items.d_h_t.ct}}</td>
  68. <td class="td">{{items.d_h_t.at==""?"--":items.d_h_t.at}}</td>
  69. <td class="td">{{items.d_h_t.ah==""?"--":items.d_h_t.ah}}</td>
  70. <td class="td">{{items.d_h_t.cv}}</td>
  71. <td class="td">{{ items.d_h_t.vps == 0 ? '正常' : items.d_h_t.vps == 1 ? '欠压' : items.d_h_t.vps == 2 ? '过压' : items.d_h_t.vps}}</td>
  72. <td class="td">{{items.d_h_t.bv}}</td>
  73. <td class="td">{{items.d_h_t.csq}}</td>
  74. </tr>
  75. <tr class="tr" v-if="!forbidden">
  76. <td class="td" v-for="item in 14">暂无数据</td>
  77. </tr>
  78. </table>
  79. <table class="table2" v-else-if="!allqingchong">
  80. <tr class="tr">
  81. <th class="th" v-for="(item,index) in thdata3" :key="'a'+index">{{item}}</th>
  82. </tr>
  83. <tr class="tr" v-for="(items,indexs) in eqlistdata" :key="'b'+indexs" v-if="forbidden">
  84. <td class="td">{{items.d_h_t.addtime|timeFormat()}}</td>
  85. <td class="td">{{items.d_h_t.ds}}</td>
  86. <td class="td">{{items.d_h_t.ws}}</td>
  87. <td class="td">{{items.d_h_t.tps}}</td>
  88. <td class="td">{{items.d_h_t.tt}}</td>
  89. <td class="td">{{items.d_h_t.at==""?"--":items.d_h_t.at}}</td>
  90. <td class="td">{{items.d_h_t.ah==""?"--":items.d_h_t.ah}}</td>
  91. </tr>
  92. <tr class="tr" v-if="!forbidden">
  93. <td class="td" v-for="item in 7">暂无数据</td>
  94. </tr>
  95. </table>
  96. <table class="table2" v-else>
  97. <tr class="tr">
  98. <th class="th" v-for="(item,index) in thdata2" :key="'a'+index">{{item}}</th>
  99. </tr>
  100. <tr class="tr" v-for="(items,indexs) in eqlistdata" :key="'b'+indexs" v-if="forbidden">
  101. <td class="td">{{items.d_h_t.addtime|timeFormat()}}</td>
  102. <td class="td">{{items.d_h_t.ds}}</td>
  103. <td class="td">{{items.d_h_t.ws}}</td>
  104. <td class="td">{{items.d_h_t.rps}}</td>
  105. <td class="td">{{items.d_h_t.tps}}</td>
  106. <td class="td">{{items.d_h_t.dps}}</td>
  107. <td class="td">{{items.d_h_t.tt}}</td>
  108. <td class="td">{{items.d_h_t.ct}}</td>
  109. <td class="td">{{items.d_h_t.at==""?"--":items.d_h_t.at}}</td>
  110. <td class="td">{{items.d_h_t.ah==""?"--":items.d_h_t.ah}}</td>
  111. </tr>
  112. <tr class="tr" v-if="!forbidden">
  113. <td class="td" v-for="item in 10">暂无数据</td>
  114. </tr>
  115. </table>
  116. </scroll-view>
  117. <view class="pagenumber">
  118. <button @click="prev">上一页</button>
  119. <view class="pagenumber_page">
  120. 第{{page}}页
  121. </view>
  122. <view class="pagenumber_page">
  123. 共 {{pagesum}} 页
  124. </view>
  125. <button @click="next" :disabled="!forbidden">下一页</button>
  126. </view>
  127. </view>
  128. </view>
  129. </view>
  130. </template>
  131. <style lang="scss">
  132. </style>
  133. <script>
  134. import uCharts from '../../components/js_sdk/u-charts/u-charts/u-charts.js';
  135. var canvaColumnA = null;
  136. var canvaColumnB = null;
  137. var presenttime = null
  138. // var oldpresenttime = presenttime - 24*60*60*1000
  139. export default {
  140. data() {
  141. return {
  142. thdata: ["上报时间", "设备开关", "工作状态", "雨控状态", "温控状态", "倾倒状态", "定时(h)", "电击次数", "温度(℃)", "湿度(%)", "充电电压(v)","电压状态",
  143. "电池电压(v)", "信号强度"
  144. ],
  145. thdata2: ["上报时间", "设备开关", "工作状态", "雨控状态", "温控状态", "倾倒状态", "定时(h)", "电击次数", "温度(℃)", "湿度(%)"],
  146. thdata3: ["上报时间", "设备开关", "工作状态", "温控状态", "定时(h)", "温度(℃)", "湿度(%)"],
  147. eqlistdata: [],
  148. cWidth: '400',
  149. cHeight: '400',
  150. pixelRatio: 1,
  151. titletext: ["24小时", "近一个月", "近半年", "近一年"],
  152. titleidnex: 0,
  153. oldtime: '',
  154. newtime: '',
  155. page: 1,
  156. forbidden: false, //暂无数据
  157. times: {
  158. d_id: null,
  159. start_time: null,
  160. end_time: null,
  161. device_id: null
  162. },
  163. canvastishiTF: false, //折线图暂无数据提示
  164. dataloadingtf: true, //加载中提示
  165. pagesum: 1,
  166. tiemshow: false, //日历选择器
  167. allqingchong: false
  168. }
  169. },
  170. // 页面加载执行的函数
  171. onLoad(option) {
  172. this.times.d_id = option.d_id
  173. this.times.imei = option.imei
  174. this.cWidth = uni.upx2px(650);
  175. this.cHeight = uni.upx2px(500);
  176. this.getworm()
  177. },
  178. onShow() {
  179. presenttime = +new Date();
  180. this.oldtime = parseInt((presenttime - 24 * 60 * 60 * 1000) / 1000)
  181. this.newtime = parseInt(presenttime / 1000)
  182. setTimeout(() => {
  183. this.getServerData(parseInt(presenttime / 1000), parseInt((presenttime - 24 * 60 * 60 * 1000) /
  184. 1000))
  185. this.historydata(parseInt(presenttime / 1000), parseInt((presenttime - 24 * 60 * 60 * 1000) /
  186. 1000))
  187. }, 1000)
  188. },
  189. onPullDownRefresh() {
  190. console.log('refresh');
  191. this.getServerData(parseInt(presenttime / 1000), parseInt((presenttime - 24 * 60 * 60 * 1000) /
  192. 1000))
  193. this.historydata(parseInt(presenttime / 1000), parseInt((presenttime - 24 * 60 * 60 * 1000) /
  194. 1000))
  195. setTimeout(function() {
  196. uni.stopPullDownRefresh();
  197. }, 1000);
  198. },
  199. methods: { //
  200. //forecast.worm_lamp.device_polyline_data
  201. // 获取数据,发请求
  202. async getServerData(newtime, oldtimes) { //设备折线图
  203. this.dataloadingtf = true
  204. const res = await this.$myRequest({
  205. url: '/api/api_gateway?method=forecast.worm_lamp.device_polyline_data',
  206. data: {
  207. device_type_id: 2,
  208. d_id: this.times.d_id,
  209. end_time: newtime,
  210. start_time: oldtimes
  211. }
  212. })
  213. this.dataloadingtf = false
  214. if (res.length == 0) {
  215. this.canvastishiTF = false
  216. } else {
  217. this.canvastishiTF = true
  218. var xtitle = []
  219. var arr = []
  220. var arr1 = []
  221. var arr2 = []
  222. var arr3 = []
  223. var arr4 = []
  224. var arr5 = []
  225. for (var i = 0; i < res.length; i++) {
  226. var times = new Date(res[i].addtime * 1000)
  227. xtitle.unshift(times.getMonth() + 1 + "/" + times.getDate() + "-" + times.getHours() + ":" +
  228. times.getMinutes())
  229. arr1.unshift(res[i].temperature)
  230. arr2.unshift(res[i].humidity)
  231. arr3.unshift(Number(res[i].others.bv))
  232. arr4.unshift(Number(res[i].others.cv))
  233. arr5.unshift(res[i].others.ct)
  234. }
  235. arr.unshift(arr1, arr2, arr3, arr4)
  236. var obj = [{
  237. name: '温度',
  238. data: arr[0],
  239. color: '#F97000'
  240. }, {
  241. name: '湿度',
  242. data: arr[1],
  243. color: '#00E29D'
  244. }, {
  245. name: '电池电压',
  246. data: arr[2],
  247. color: '#FF3F3F'
  248. }, {
  249. name: '充电电压',
  250. data: arr[3],
  251. color: '#6CBBFF'
  252. }]
  253. var obj2 = [{
  254. name: '击虫次数',
  255. data: arr5,
  256. color: '#00E29D'
  257. }]
  258. // console.log(obj)
  259. this.showColumn("canvasColumnA", xtitle, obj)
  260. this.showColumnb("canvasColumnB", xtitle, obj2)
  261. }
  262. },
  263. changeindex(index) { //选择日期
  264. this.titleidnex = index
  265. var now = new Date();
  266. if (index == 0) {
  267. this.newtime = parseInt(+new Date(now) / 1000)
  268. this.oldtime = parseInt((presenttime - 24 * 60 * 60 * 1000) / 1000)
  269. this.getServerData(parseInt(presenttime / 1000), parseInt((presenttime - 24 * 60 * 60 * 1000) / 1000))
  270. this.historydata(parseInt(presenttime / 1000), parseInt((presenttime - 24 * 60 * 60 * 1000) / 1000))
  271. } else if (index == 1) {
  272. this.newtime = parseInt(+new Date(now) / 1000)
  273. var oldtime = now.setMonth(now.getMonth() - 1) / 1000
  274. this.oldtime = parseInt(oldtime)
  275. this.getServerData(parseInt(presenttime / 1000), parseInt(oldtime))
  276. this.historydata(parseInt(presenttime / 1000), parseInt(oldtime))
  277. } else if (index == 2) {
  278. this.newtime = parseInt(+new Date(now) / 1000)
  279. var oldtime = now.setMonth(now.getMonth() - 6) / 1000
  280. this.oldtime = parseInt(oldtime)
  281. this.getServerData(parseInt(presenttime / 1000), parseInt(oldtime))
  282. this.historydata(parseInt(presenttime / 1000), parseInt(oldtime))
  283. } else if (index == 3) {
  284. this.newtime = parseInt(+new Date(now) / 1000)
  285. var oldtime = now.setFullYear(now.getFullYear() - 1) / 1000
  286. this.oldtime = parseInt(oldtime)
  287. this.getServerData(parseInt(presenttime / 1000), parseInt(oldtime))
  288. this.historydata(parseInt(presenttime / 1000), parseInt(oldtime))
  289. }
  290. },
  291. async historydata(newtime, oldtimes) { //设备表格数据
  292. const res = await this.$myRequest({
  293. url: '/api/api_gateway?method=forecast.worm_lamp.device_history_data',
  294. data: {
  295. device_type_id: 2,
  296. device_id: this.times.imei,
  297. page: this.page,
  298. page_size: 10,
  299. start_time: oldtimes,
  300. end_time: newtime
  301. }
  302. })
  303. console.log(res.data)
  304. this.pagesum = Math.ceil(res.counts / 10) || 1
  305. this.eqlistdata = res.data
  306. if (res.data.length == 0) {
  307. this.forbidden = false
  308. } else {
  309. this.forbidden = true
  310. }
  311. },
  312. prev() { //上一页
  313. if (this.page != 1) {
  314. this.page--
  315. this.historydata(this.newtime, this.oldtime)
  316. }
  317. },
  318. next() { //下一页
  319. if (this.page < this.pagesum) {
  320. this.page++
  321. this.historydata(this.newtime, this.oldtime)
  322. }
  323. },
  324. tiemchange(e) {
  325. console.log(e)
  326. this.oldtime = +new Date(e.startDate) / 1000
  327. this.newtime = +new Date(e.endDate) / 1000 + 16 * 60 * 60
  328. this.getServerData(this.newtime, this.oldtime)
  329. this.historydata(this.newtime, this.oldtime)
  330. },
  331. timetab(e) {
  332. e = new Date(e * 1000)
  333. var year = e.getFullYear()
  334. var month = e.getMonth() + 1 < 10 ? "0" + (e.getMonth() + 1) : e.getMonth() + 1
  335. var day = e.getDate() < 10 ? "0" + e.getDate() : e.getDate()
  336. var time = year + "/" + month + "/" + day
  337. return time
  338. },
  339. clickLeft() {
  340. uni.navigateBack({
  341. delta: 1
  342. })
  343. },
  344. showColumn(id, xtitle, xinfo) {
  345. var _self = this
  346. canvaColumnA = new uCharts({
  347. canvasId: id,
  348. type: 'line',
  349. legend: {
  350. position: "top"
  351. },
  352. fontSize: 11,
  353. background: '#FFFFFF',
  354. pixelRatio: 1,
  355. animation: true,
  356. dataLabel: false,
  357. categories: xtitle,
  358. series: xinfo,
  359. enableScroll: true, //开启图表拖拽功能
  360. xAxis: {
  361. disableGrid: true,
  362. type: 'grid',
  363. gridType: 'dash',
  364. itemCount: 4, //x轴单屏显示数据的数量,默认为5个
  365. scrollShow: true, //新增是否显示滚动条,默认false
  366. // scrollAlign: 'left', //滚动条初始位置
  367. scrollBackgroundColor: '#F7F7FF', //默认为 #EFEBEF
  368. scrollColor: '#DEE7F7', //默认为 #A6A6A6
  369. },
  370. yAxis: {},
  371. width: _self.cWidth * 1,
  372. height: _self.cHeight * 1,
  373. extra: {
  374. line: {
  375. type: 'curve'
  376. }
  377. }
  378. });
  379. },
  380. showColumnb(id, xtitle, xinfo) {
  381. var _self = this
  382. canvaColumnB = new uCharts({
  383. canvasId: id,
  384. type: 'line',
  385. legend: {
  386. position: "top"
  387. },
  388. fontSize: 11,
  389. background: '#FFFFFF',
  390. pixelRatio: 1,
  391. animation: true,
  392. dataLabel: false,
  393. categories: xtitle,
  394. series: xinfo,
  395. enableScroll: true, //开启图表拖拽功能
  396. xAxis: {
  397. disableGrid: true,
  398. type: 'grid',
  399. gridType: 'dash',
  400. itemCount: 4, //x轴单屏显示数据的数量,默认为5个
  401. scrollShow: true, //新增是否显示滚动条,默认false
  402. // scrollAlign: 'left', //滚动条初始位置
  403. scrollBackgroundColor: '#F7F7FF', //默认为 #EFEBEF
  404. scrollColor: '#DEE7F7', //默认为 #A6A6A6
  405. },
  406. yAxis: {},
  407. width: _self.cWidth * 1,
  408. height: _self.cHeight * 1,
  409. extra: {
  410. line: {
  411. type: 'curve'
  412. }
  413. }
  414. });
  415. },
  416. touchLineA(e) {
  417. console.log(e)
  418. canvaColumnA.scrollStart(e);
  419. },
  420. moveLineA(e) {
  421. canvaColumnA.scroll(e);
  422. },
  423. touchEndLineA(e) {
  424. canvaColumnA.scrollEnd(e);
  425. //下面是toolTip事件,如果滚动后不需要显示,可不填写
  426. canvaColumnA.showToolTip(e, {
  427. format: function(item, category) {
  428. return category + ' ' + item.name + ':' + Number(item.data).toFixed(3)
  429. }
  430. });
  431. },
  432. touchLineBb(e) {
  433. console.log(e)
  434. canvaColumnB.scrollStart(e);
  435. },
  436. moveLineBb(e) {
  437. canvaColumnB.scroll(e);
  438. },
  439. touchEndLineBb(e) {
  440. canvaColumnB.scrollEnd(e);
  441. //下面是toolTip事件,如果滚动后不需要显示,可不填写
  442. canvaColumnB.showToolTip(e, {
  443. format: function(item, category) {
  444. return category + ' ' + item.name + ':' + item.data
  445. }
  446. });
  447. },
  448. async newdata() {
  449. const res = await this.$myRequest({
  450. url: '/api/api_gateway?method=forecast.send_control.get_device_config',
  451. data: {
  452. device_type_id: 2,
  453. d_id: this.times.d_id,
  454. control_type: "data"
  455. }
  456. })
  457. if (res) {
  458. uni.showToast({
  459. title: '刷新成功',
  460. duration: 2000,
  461. icon: "none"
  462. });
  463. } else {
  464. uni.showToast({
  465. title: '刷新失败',
  466. duration: 2000,
  467. icon: "none"
  468. });
  469. }
  470. },
  471. refresh() { //获取当前时间的数据
  472. this.newdata()
  473. },
  474. async getworm() {
  475. const res = await this.$myRequest({
  476. url: '/api/api_gateway?method=forecast.send_control.clear_insects_permission',
  477. data: {}
  478. })
  479. console.log(res)
  480. this.allqingchong = res[2] == 1 ? false : true;
  481. },
  482. }
  483. }
  484. </script>
  485. <style lang="scss">
  486. /*样式的width和height一定要与定义的cWidth和cHeight相对应*/
  487. .shuju_one,
  488. .shuju_two {
  489. position: absolute;
  490. top: 190rpx;
  491. width: 90%;
  492. left: 5%;
  493. box-shadow: 0 0 10rpx #bcb9ca;
  494. padding-top: 20rpx;
  495. height: 550rpx;
  496. .canvastishi {
  497. font-size: 32rpx;
  498. position: absolute;
  499. top: 50%;
  500. left: 50%;
  501. margin-left: -64rpx;
  502. margin-top: -21rpx;
  503. .dataloading:after {
  504. overflow: hidden;
  505. display: inline-block;
  506. vertical-align: bottom;
  507. animation: ellipsis 2s infinite;
  508. content: "\2026";
  509. }
  510. @keyframes ellipsis {
  511. from {
  512. width: 2px;
  513. }
  514. to {
  515. width: 15px;
  516. }
  517. }
  518. }
  519. .shuju_one_title {
  520. width: 70%;
  521. margin: 0 auto;
  522. display: flex;
  523. .tltle_text {
  524. width: 25%;
  525. border: 2rpx solid #B2B2B2;
  526. color: #57c878;
  527. text-align: center;
  528. font-size: 24rpx;
  529. height: 50rpx;
  530. line-height: 50rpx;
  531. }
  532. .title_text_color {
  533. width: 25%;
  534. border: 2rpx solid #57c878;
  535. background-color: #57c878;
  536. color: #fff;
  537. text-align: center;
  538. font-size: 24rpx;
  539. height: 50rpx;
  540. line-height: 50rpx;
  541. }
  542. }
  543. .qiun-columns {
  544. .qiun-charts {
  545. width: 650upx;
  546. height: 400upx;
  547. background-color: #FFFFFF;
  548. }
  549. .charts {
  550. width: 650upx;
  551. height: 400upx;
  552. background-color: #FFFFFF;
  553. }
  554. }
  555. }
  556. .shuju_two {
  557. top: 790rpx;
  558. }
  559. .selecttimes {
  560. position: absolute;
  561. top: 54px;
  562. width: 90%;
  563. box-shadow: 0 0 10rpx #bcb9ca;
  564. left: 5%;
  565. padding: 10rpx 20rpx;
  566. box-sizing: border-box;
  567. .timesbox {
  568. display: flex;
  569. justify-content: space-around;
  570. image {
  571. width: 30rpx;
  572. height: 30rpx;
  573. margin-top: 6rpx;
  574. }
  575. .icon {
  576. color: #949494;
  577. text-align: right;
  578. margin-left: 30rpx;
  579. }
  580. }
  581. }
  582. .refresh {
  583. position: absolute;
  584. left: 5%;
  585. width: 160rpx;
  586. height: 50rpx;
  587. background-color: #57c878;
  588. color: #FFFFFF;
  589. line-height: 50rpx;
  590. text-align: center;
  591. box-shadow: 0 0 10rpx #bcb9ca;
  592. }
  593. .condition {
  594. position: absolute;
  595. display: flex;
  596. flex-wrap: wrap;
  597. width: 90%;
  598. left: 5%;
  599. box-shadow: 0 0 10rpx #bcb9ca;
  600. margin-bottom: 30rpx;
  601. .scroll-X {
  602. width: 95%;
  603. margin: 20rpx auto;
  604. .table {
  605. width: 1056px;
  606. }
  607. .tr {
  608. display: flex;
  609. overflow: hidden;
  610. .th,
  611. .td {
  612. display: inline-block;
  613. padding: 5rpx;
  614. width: 140rpx;
  615. text-align: center;
  616. height: 52rpx;
  617. line-height: 52rpx;
  618. // border: 2rpx solid #F1F1F1;
  619. }
  620. .th:first-child,
  621. .td:first-child {
  622. width: 300rpx;
  623. }
  624. .th:nth-last-child(1),
  625. .th:nth-last-child(2),
  626. .td:nth-last-child(1),
  627. .td:nth-last-child(2) {
  628. width: 200rpx;
  629. }
  630. }
  631. .tr:nth-child(2n-1) {
  632. background-color: #f5fff8;
  633. }
  634. .tr:first-child {
  635. background-color: #57c878;
  636. color: #fff;
  637. }
  638. }
  639. .pagenumber {
  640. display: flex;
  641. margin: 20rpx auto;
  642. button {
  643. width: 150rpx;
  644. height: 50rpx;
  645. line-height: 50rpx;
  646. font-size: 26rpx;
  647. text-align: center;
  648. background-color: #57c878;
  649. color: #FFFFFF;
  650. }
  651. .pagenumber_page {
  652. width: 150rpx;
  653. height: 50rpx;
  654. line-height: 50rpx;
  655. font-size: 26rpx;
  656. text-align: center;
  657. }
  658. }
  659. }
  660. /deep/.u-calendar__action {
  661. display: flex;
  662. justify-content: space-around;
  663. .u-calendar__action__text {
  664. line-height: 25px;
  665. }
  666. }
  667. </style>