eleDetail.vue 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816
  1. <template>
  2. <view class="ele-details-page">
  3. <cu-custom :isBack="true">
  4. <template slot="content">
  5. <view class="nav-title">小气候监测站II监测要素</view>
  6. </template>
  7. </cu-custom>
  8. <view class="date-picker" @click="openDatePicker">
  9. <text>{{ startDate }}</text>
  10. <text class="separator">-</text>
  11. <text>{{ endDate }}</text>
  12. <image class="date-icon" src="/static/images/device/date-active.svg" />
  13. </view>
  14. <u-calendar
  15. v-model="show"
  16. :mode="mode"
  17. @change="onDateChange"
  18. ref="calendar"
  19. range-color="#999"
  20. btn-type="success"
  21. active-bg-color="#0BBC58"
  22. range-bg-color="rgba(11,188,88,0.13)"
  23. ></u-calendar>
  24. <view class="echarts-board">
  25. <view class="period-tabs">
  26. <view
  27. class="tab-item"
  28. :class="{ active: activePeriod === '24h' }"
  29. @click="changePeriod('24h')"
  30. >24小时</view
  31. >
  32. <view
  33. class="tab-item"
  34. :class="{ active: activePeriod === '7d' }"
  35. @click="changePeriod('7d')"
  36. >一周</view
  37. >
  38. <view
  39. class="tab-item"
  40. :class="{ active: activePeriod === '30d' }"
  41. @click="changePeriod('30d')"
  42. >一月</view
  43. >
  44. </view>
  45. <view class="element-tabs" v-if="hasData">
  46. <view class="ele-board">
  47. <view
  48. v-for="(item, index) in eleTabs"
  49. :key="index"
  50. class="ele-item"
  51. :class="{ 'ele-active': eleActive === index }"
  52. @click="changeElement(index)"
  53. >{{ item.name }}</view
  54. >
  55. </view>
  56. <view class="fold-icon" @click="toggleFold">
  57. <u-icon :name="isFolded ? 'arrow-down' : 'arrow-up'"></u-icon>
  58. </view>
  59. </view>
  60. <!-- 展开后的所有要素 -->
  61. <view v-if="!isFolded && hasData" class="expanded-elements">
  62. <view
  63. class="expanded-item"
  64. v-for="(item, index) in eleTabs"
  65. :key="index"
  66. :class="{ 'ele-active': eleActive === index }"
  67. @click="changeElement(index)"
  68. >
  69. {{ item.name }}
  70. </view>
  71. </view>
  72. <view class="chart-container" v-if="hasData">
  73. <canvas
  74. canvas-id="temperatureChart"
  75. id="temperatureChart"
  76. class="chart"
  77. @touchstart="touchLineA($event)"
  78. @touchmove="moveLineA($event)"
  79. @touchend="touchEndLineA($event)"
  80. disable-scroll="true"
  81. ></canvas>
  82. </view>
  83. <view class="no-data" v-else>
  84. <text>暂无数据</text>
  85. </view>
  86. <!-- <view class="stats-panel">
  87. <view class="stat-item">
  88. <text class="value">27<text class="unit">°C</text></text>
  89. <text class="label">最低值</text>
  90. </view>
  91. <view class="stat-item">
  92. <text class="value">32<text class="unit">°C</text></text>
  93. <text class="label">平均值</text>
  94. </view>
  95. <view class="stat-item">
  96. <text class="value red">42<text class="unit red">°C</text></text>
  97. <text class="label">最高值</text>
  98. </view>
  99. </view> -->
  100. </view>
  101. <view class="history-section">
  102. <view class="section-title">历史数据</view>
  103. <view class="table-wrap">
  104. <view class="fixed-column">
  105. <view class="table-cell header">上报时间</view>
  106. <view class="table-cell" v-for="(item, idx) in tableList" :key="idx">
  107. {{ item.uptime }}
  108. </view>
  109. </view>
  110. <view class="table-bg"></view>
  111. <scroll-view class="scroll-column" scroll-x="true">
  112. <view class="scroll-content">
  113. <view class="table-row">
  114. <view class="table-cell header">{{
  115. activeChartInfo.name + "(" + activeChartInfo.unit + ")"
  116. }}</view>
  117. </view>
  118. <view class="table-row" v-for="(item, idx) in tableList" :key="idx">
  119. <view class="table-cell">{{ item[activeChartInfo.title] }}</view>
  120. </view>
  121. </view>
  122. </scroll-view>
  123. </view>
  124. <view class="pagination">
  125. <view
  126. class="page-item prev"
  127. @click="prevPage"
  128. :class="{ disabled: currentPage === 1 }"
  129. >上一页</view
  130. >
  131. <view class="page-info">
  132. <text class="curret-page">{{ currentPage }}</text>
  133. <text>/</text>
  134. <text>{{ totalPages }}</text>
  135. </view>
  136. <view
  137. class="page-item next"
  138. @click="nextPage"
  139. :class="{ disabled: currentPage >= totalPages }"
  140. >下一页</view
  141. >
  142. </view>
  143. </view>
  144. </view>
  145. </template>
  146. <script>
  147. import uCharts from "../../../components/js_sdk/u-charts/u-charts/u-charts.js";
  148. import baseCharts from "./charts.vue";
  149. export default {
  150. components: { baseCharts },
  151. onLoad(options) {
  152. const deviceInfo = JSON.parse(decodeURIComponent(options.deviceInfo));
  153. console.log(deviceInfo, "deviceInfo");
  154. this.eleKey = options.eleKey || "";
  155. this.initDateRange(deviceInfo.uptime);
  156. this.deviceInfo = deviceInfo;
  157. this.getChartData();
  158. this.getObData();
  159. },
  160. data() {
  161. return {
  162. temperatureChart: null,
  163. activePeriod: "",
  164. activeElement: "temperature",
  165. show: false,
  166. mode: "range",
  167. startDate: "",
  168. endDate: "",
  169. isFolded: true, // 控制要素是否收起
  170. eleTabs: [],
  171. eleActive: 0,
  172. hasData: true,
  173. tableList: [],
  174. currentPage: 1,
  175. pageSize: 9,
  176. total: 0,
  177. chartData: {
  178. categories: [],
  179. series: [],
  180. },
  181. activeChartInfo: {},
  182. eleKey: "",
  183. };
  184. },
  185. computed: {
  186. totalPages() {
  187. return Math.ceil(this.total / this.pageSize);
  188. },
  189. },
  190. methods: {
  191. initDateRange(timestamp) {
  192. if (!timestamp) {
  193. const today = new Date();
  194. this.endDate = this.formatDate(today);
  195. const startDate = new Date(today);
  196. startDate.setDate(startDate.getDate() - 7);
  197. this.startDate = this.formatDate(startDate);
  198. return;
  199. }
  200. const date = new Date(Number(timestamp) * 1000);
  201. this.endDate = this.formatDate(date);
  202. const startDate = new Date(date);
  203. startDate.setDate(startDate.getDate() - 7);
  204. this.startDate = this.formatDate(startDate);
  205. },
  206. formatDate(date) {
  207. const year = date.getFullYear();
  208. const month = String(date.getMonth() + 1).padStart(2, "0");
  209. const day = String(date.getDate()).padStart(2, "0");
  210. return `${year}-${month}-${day}`;
  211. },
  212. initChart() {
  213. const ctx = uni.createCanvasContext("temperatureChart", this);
  214. const currentEle = this.eleTabs[this.eleActive];
  215. console.log(currentEle, "currentEle");
  216. currentEle.data.forEach((item) => {
  217. if (item.value === "/") {
  218. item.value = "0";
  219. }
  220. });
  221. const series = [
  222. {
  223. name: currentEle.name,
  224. data: currentEle.data,
  225. lineWidth: 3,
  226. pointShape: "circle",
  227. pointSize: 12,
  228. pointColor: currentEle.color,
  229. pointBorderColor: "#fff",
  230. pointBorderWidth: 2,
  231. symbol: "emptyCircle",
  232. symbolSize: 6,
  233. legendShape: "circle",
  234. },
  235. ];
  236. const xData = currentEle.data.map((item) => item.time);
  237. this.temperatureChart = new uCharts({
  238. $this: this,
  239. canvasId: "temperatureChart",
  240. type: "line",
  241. context: ctx,
  242. width: 340,
  243. height: 180,
  244. categories: xData,
  245. series: series,
  246. legend: {
  247. position: "top",
  248. show: true,
  249. padding: 5,
  250. fontColor: "#303133",
  251. fontSize: 12,
  252. itemType: "circle",
  253. itemShape: "emptyCircle",
  254. itemWidth: 12,
  255. itemHeight: 12,
  256. lineWidth: 2,
  257. },
  258. xAxis: {
  259. axisLineColor: "#E4E7ED",
  260. disableGrid: true,
  261. fontColor: "#656565",
  262. fontSize: 10,
  263. itemCount: 5,
  264. scrollShow: true,
  265. },
  266. yAxis: {
  267. splitNumber: 4,
  268. axisLineColor: "#E4E7ED",
  269. fontColor: "#656565",
  270. gridColor: "#E4E7ED",
  271. dashLength: 4,
  272. disableGrid: false,
  273. fontSize: 10,
  274. },
  275. dataLabel: false,
  276. enableScroll: true,
  277. background: "#FFFFFF",
  278. extra: {
  279. line: {
  280. type: "curve",
  281. width: 2,
  282. activeType: "hollow",
  283. },
  284. },
  285. });
  286. },
  287. touchLineA(e) {
  288. this.temperatureChart.scrollStart(e);
  289. },
  290. moveLineA(e) {
  291. this.temperatureChart.scroll(e);
  292. },
  293. touchEndLineA(e) {
  294. this.temperatureChart.scrollEnd(e);
  295. //下面是toolTip事件,如果滚动后不需要显示,可不填写
  296. // this.temperatureChart.showToolTip(e, {
  297. // format: function(item, category) {
  298. // console.log(item, 'iyee', e)
  299. // return category + ' ' + item.name + ':' + item.data
  300. // }
  301. // });
  302. },
  303. // 打开日期选择器
  304. openDatePicker() {
  305. this.show = true;
  306. // 延迟设置日期,确保组件已经初始化
  307. this.$nextTick(() => {
  308. if (this.$refs.calendar) {
  309. // 直接设置组件内部的日期状态
  310. const calendar = this.$refs.calendar;
  311. calendar.startDate = this.startDate;
  312. calendar.endDate = this.endDate;
  313. // 如果有选中的日期范围,设置对应的年、月、日
  314. if (this.startDate) {
  315. const startParts = this.startDate.split("-");
  316. calendar.startYear = parseInt(startParts[0]);
  317. calendar.startMonth = parseInt(startParts[1]);
  318. calendar.startDay = parseInt(startParts[2]);
  319. }
  320. if (this.endDate) {
  321. const endParts = this.endDate.split("-");
  322. calendar.endYear = parseInt(endParts[0]);
  323. calendar.endMonth = parseInt(endParts[1]);
  324. calendar.endDay = parseInt(endParts[2]);
  325. }
  326. // 如果有开始日期,设置日历当前显示的年月为开始日期的年月
  327. if (this.startDate) {
  328. const startParts = this.startDate.split("-");
  329. calendar.year = parseInt(startParts[0]);
  330. calendar.month = parseInt(startParts[1]);
  331. calendar.changeData();
  332. }
  333. }
  334. });
  335. },
  336. // 日期选择变化事件
  337. onDateChange(e) {
  338. this.startDate = e.startDate;
  339. this.endDate = e.endDate;
  340. this.activePeriod = "custom"; // 设置为自定义周期
  341. this.show = false;
  342. this.getChartData();
  343. },
  344. // 切换时间周期
  345. changePeriod(period) {
  346. this.activePeriod = period;
  347. // 根据选择的周期自动计算日期范围
  348. const now = new Date();
  349. const endDate = now.toISOString().split("T")[0];
  350. const startDate = new Date();
  351. if (period === "24h") {
  352. startDate.setDate(now.getDate());
  353. } else if (period === "7d") {
  354. startDate.setDate(now.getDate() - 7);
  355. } else if (period === "30d") {
  356. startDate.setMonth(now.getMonth() - 1);
  357. }
  358. this.startDate = startDate.toISOString().split("T")[0];
  359. this.endDate = endDate;
  360. this.getChartData();
  361. },
  362. // 切换要素标签
  363. changeElement(index) {
  364. if (this.eleTabs.length === 0) return;
  365. this.eleActive = index;
  366. this.activeChartInfo = this.eleTabs[index];
  367. this.isFolded = true; // 关闭展开面板
  368. this.$nextTick(() => {
  369. this.initChart();
  370. });
  371. },
  372. // 切换要素展开/收起状态
  373. toggleFold() {
  374. this.isFolded = !this.isFolded;
  375. },
  376. // 上一页
  377. prevPage() {
  378. if (this.currentPage > 1) {
  379. this.currentPage--;
  380. this.getObData();
  381. }
  382. },
  383. // 下一页
  384. nextPage() {
  385. if (this.currentPage < this.totalPages) {
  386. this.currentPage++;
  387. this.getObData();
  388. }
  389. },
  390. // 折线图数据
  391. getChartData() {
  392. this.$myRequest({
  393. url: "/api/api_gateway?method=qxz.data.qxz_ob_data_map",
  394. data: {
  395. device_id: this.deviceInfo.devBid,
  396. start: String(
  397. Math.floor(new Date(this.startDate + " 00:00:00").getTime() / 1000),
  398. ),
  399. end: String(
  400. Math.floor(new Date(this.endDate + " 23:59:59").getTime() / 1000),
  401. ),
  402. page: 1,
  403. page_size: 999,
  404. },
  405. }).then((res) => {
  406. console.log("getChartData:", res);
  407. if (res && Array.isArray(res) && res.length > 0) {
  408. this.eleTabs = res;
  409. this.hasData = true;
  410. this.activeChartInfo =
  411. this.eleTabs.find((item) => item.title === this.eleKey) ||
  412. this.eleTabs[0];
  413. this.eleActive = this.eleTabs.indexOf(this.activeChartInfo);
  414. console.log(this.activeChartInfo, "activeChartInfo");
  415. this.$nextTick(() => {
  416. this.initChart();
  417. });
  418. } else {
  419. this.eleTabs = [];
  420. this.hasData = false;
  421. }
  422. });
  423. },
  424. // 历史数据
  425. getObData() {
  426. this.$myRequest({
  427. url: "/api/api_gateway?method=qxz.data.qxz_ob_data",
  428. data: {
  429. device_id: this.deviceInfo.devBid,
  430. start: String(
  431. Math.floor(new Date(this.startDate + " 00:00:00").getTime() / 1000),
  432. ),
  433. end: String(
  434. Math.floor(new Date(this.endDate + " 23:59:59").getTime() / 1000),
  435. ),
  436. page: this.currentPage,
  437. page_size: this.pageSize,
  438. },
  439. }).then((res) => {
  440. console.log("getObData:", res);
  441. const columns = res.title;
  442. const data = res.data;
  443. const newData = data.map((item) => {
  444. return this.processData(item);
  445. });
  446. const resCol = this.convertDynamic(columns, (prop, val) =>
  447. Array.isArray(val) ? `${val[1]}${val[3] || ""}` : val,
  448. );
  449. this.columns = resCol;
  450. this.tableList = newData;
  451. this.total = res.count;
  452. console.log("tableList:", this.columns);
  453. console.log("tableList", this.tableList);
  454. });
  455. },
  456. convertDynamic(data, getLabelValue) {
  457. if (!data || typeof data !== "object") return [];
  458. const result = [];
  459. const keys = Object.keys(data);
  460. for (const prop of keys) {
  461. const arr = data[prop];
  462. const value = getLabelValue(prop, arr, data);
  463. if (value !== undefined && value !== null) {
  464. result.push({
  465. label: String(value),
  466. prop,
  467. align: "center",
  468. });
  469. }
  470. }
  471. return result;
  472. },
  473. processData(data) {
  474. return Object.entries(data).reduce((acc, [key, value]) => {
  475. acc[key] = Array.isArray(value) ? value[0] : value;
  476. return acc;
  477. }, {});
  478. },
  479. },
  480. };
  481. </script>
  482. <style lang="scss">
  483. .ele-details-page {
  484. background:
  485. linear-gradient(180deg, #ffffff00 0%, #f5f6fa 23.64%, #f5f6fa 100%),
  486. linear-gradient(102deg, #bfeadd 6.77%, #b8f1e7 40.15%, #b9eef5 84.02%);
  487. min-height: 100vh;
  488. padding: 0 32rpx;
  489. padding-top: 98rpx;
  490. }
  491. .nav-title{
  492. text-align: center;
  493. }
  494. .date-picker {
  495. display: flex;
  496. align-items: center;
  497. justify-content: space-between;
  498. background-color: #fff;
  499. border-radius: 40rpx;
  500. padding: 16rpx 24rpx;
  501. margin-bottom: 36rpx;
  502. font-size: 28rpx;
  503. color: #999;
  504. margin-top: 46rpx;
  505. .date-icon {
  506. width: 32rpx;
  507. height: 32rpx;
  508. }
  509. }
  510. .separator {
  511. margin: 0 16rpx;
  512. }
  513. .echarts-board {
  514. padding: 32rpx;
  515. border-radius: 16rpx;
  516. background: #fff;
  517. margin-bottom: 24rpx;
  518. position: relative;
  519. .period-tabs {
  520. width: 350rpx;
  521. height: 64rpx;
  522. display: flex;
  523. justify-content: space-between;
  524. align-items: center;
  525. margin: auto;
  526. margin-bottom: 12rpx;
  527. border-radius: 32rpx;
  528. background: #f1f4f8;
  529. padding: 8rpx 10rpx;
  530. color: #303133;
  531. font-family: "Source Han Sans CN VF";
  532. font-size: 26rpx;
  533. font-style: normal;
  534. font-weight: 400;
  535. line-height: normal;
  536. .tab-item {
  537. padding: 5rpx 24rpx;
  538. height: 48rpx;
  539. line-height: 48rpx;
  540. border-radius: 32rpx;
  541. }
  542. .active {
  543. background: #fff;
  544. }
  545. }
  546. .element-tabs {
  547. display: flex;
  548. justify-content: space-between;
  549. align-items: center;
  550. overflow-x: auto;
  551. white-space: nowrap;
  552. .ele-board {
  553. flex: 1;
  554. display: flex;
  555. align-items: center;
  556. overflow-x: auto;
  557. overflow-y: hidden;
  558. white-space: nowrap;
  559. }
  560. .ele-item {
  561. position: relative;
  562. color: #999999;
  563. font-size: 28rpx;
  564. font-weight: 400;
  565. white-space: nowrap;
  566. margin-right: 16rpx;
  567. padding: 14rpx 16rpx;
  568. cursor: pointer;
  569. }
  570. .ele-active {
  571. color: #303133;
  572. font-weight: 500;
  573. &::after {
  574. content: "";
  575. position: absolute;
  576. left: 50%;
  577. transform: translateX(-50%);
  578. bottom: 4rpx;
  579. display: block;
  580. width: 30rpx;
  581. height: 8rpx;
  582. border-radius: 4rpx;
  583. background: #1fc676;
  584. }
  585. }
  586. .fold-icon {
  587. width: 48rpx;
  588. border-left: 2px solid #999;
  589. padding-left: 16rpx;
  590. margin-left: 16rpx;
  591. cursor: pointer;
  592. display: none;
  593. }
  594. }
  595. /* 展开后的要素容器样式 */
  596. .expanded-elements {
  597. position: absolute;
  598. top: 126rpx;
  599. left: 0;
  600. right: 0;
  601. background: #f5f7fa;
  602. border-radius: 12rpx;
  603. padding: 16rpx;
  604. display: flex;
  605. flex-wrap: wrap;
  606. gap: 16rpx;
  607. z-index: 10;
  608. box-shadow: 0 4rpx 12rpx rgba(0, 0, 0, 0.1);
  609. }
  610. .expanded-item {
  611. flex: 0 0 calc(33.33% - 16rpx);
  612. text-align: center;
  613. padding: 16rpx 0;
  614. border-radius: 8rpx;
  615. color: #999999;
  616. font-size: 26rpx;
  617. background: #ffffff;
  618. cursor: pointer;
  619. transition: all 0.3s ease;
  620. }
  621. .expanded-item.ele-active {
  622. color: #1fc676;
  623. background: #e6f7ef;
  624. font-weight: 500;
  625. }
  626. .chart-container {
  627. border-radius: 16rpx;
  628. margin-bottom: 24rpx;
  629. position: relative;
  630. padding: 10rpx;
  631. overflow: hidden;
  632. height: 336rpx;
  633. z-index: 0;
  634. .chart {
  635. width: 100%;
  636. height: 336rpx;
  637. }
  638. }
  639. .no-data {
  640. border-radius: 16rpx;
  641. margin-bottom: 24rpx;
  642. padding: 10rpx;
  643. height: 336rpx;
  644. display: flex;
  645. align-items: center;
  646. justify-content: center;
  647. background-color: #f9f9f9;
  648. text {
  649. color: #999;
  650. font-size: 32rpx;
  651. }
  652. }
  653. .stats-panel {
  654. display: flex;
  655. justify-content: space-between;
  656. background-color: #f1f4f8;
  657. border-radius: 16rpx;
  658. padding: 24rpx 64rpx;
  659. .stat-item {
  660. display: flex;
  661. flex-direction: column;
  662. align-items: center;
  663. .label {
  664. color: #656565;
  665. font-size: 24rpx;
  666. font-weight: 400;
  667. }
  668. .value {
  669. font-size: 40rpx;
  670. font-weight: bold;
  671. }
  672. .unit {
  673. color: #999999;
  674. font-size: 20rpx;
  675. }
  676. .red {
  677. color: #fb4e52;
  678. }
  679. }
  680. }
  681. }
  682. .history-section {
  683. background-color: #fff;
  684. border-radius: 16rpx;
  685. padding: 24rpx 32rpx;
  686. .section-title {
  687. font-size: 28rpx;
  688. font-weight: bold;
  689. margin-bottom: 16rpx;
  690. color: #303133;
  691. }
  692. .table-wrap {
  693. display: flex;
  694. width: 100%;
  695. box-sizing: border-box;
  696. margin: 20rpx 0;
  697. color: #042118;
  698. font-family: "Source Han Sans CN VF";
  699. font-size: 24rpx;
  700. font-style: normal;
  701. font-weight: 400;
  702. line-height: normal;
  703. .fixed-column {
  704. width: 250rpx;
  705. .table-cell {
  706. width: 100%;
  707. white-space: nowrap;
  708. }
  709. }
  710. .table-bg {
  711. width: 16rpx;
  712. background: linear-gradient(270deg, #ffffff33 0%, #9598a433 100%);
  713. }
  714. .scroll-column {
  715. flex: 1;
  716. height: auto;
  717. overflow: hidden;
  718. margin-left: -10rpx;
  719. }
  720. .scroll-content {
  721. min-width: 100%;
  722. width: fit-content;
  723. display: flex;
  724. flex-direction: column;
  725. .table-row {
  726. display: flex;
  727. .table-cell {
  728. flex: 1;
  729. }
  730. }
  731. }
  732. .table-cell {
  733. width: 160rpx;
  734. height: 64rpx;
  735. line-height: 64rpx;
  736. text-align: center;
  737. border-bottom: 2px solid #e4e7ed;
  738. box-sizing: border-box;
  739. }
  740. .table-cell.header {
  741. background: #f6f8fc;
  742. }
  743. }
  744. .pagination {
  745. display: flex;
  746. align-items: center;
  747. justify-content: space-between;
  748. margin-top: 24rpx;
  749. .page-item {
  750. width: 104rpx;
  751. height: 48rpx;
  752. color: #656565;
  753. font-size: 24rpx;
  754. line-height: 48rpx;
  755. text-align: center;
  756. border: 2rpx solid #e4e7ed;
  757. border-radius: 8rpx;
  758. }
  759. .page-item.disabled {
  760. color: #999;
  761. border-color: #e4e7ed;
  762. background-color: #f5f7fa;
  763. }
  764. .next {
  765. color: #0bbc58;
  766. border: 2rpx solid #0bbc58;
  767. }
  768. .next.disabled {
  769. color: #999;
  770. border-color: #e4e7ed;
  771. background-color: #f5f7fa;
  772. }
  773. .page-info {
  774. color: #999999;
  775. font-family: "Source Han Sans CN VF";
  776. font-size: 24rpx;
  777. font-style: normal;
  778. font-weight: 400;
  779. line-height: normal;
  780. .curret-page {
  781. color: #303133;
  782. }
  783. }
  784. }
  785. }
  786. ::v-deep .u-calendar__action {
  787. display: flex;
  788. justify-content: center;
  789. }
  790. </style>