detail.vue 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720
  1. <template>
  2. <view class="device-detail" v-show="!loading">
  3. <view class="device-detail__header">
  4. <u-icon
  5. size="36"
  6. class="arrow-left"
  7. name="arrow-left"
  8. @click="handleBack"
  9. ></u-icon>
  10. {{ deviceInfo.name }}
  11. </view>
  12. <view class="operation" @click.stop="isShowOperation = !isShowOperation">操作</view>
  13. <view class="operation-container" v-if="isShowOperation" @click="closeOperationHandler">
  14. <view class="operation-background"></view>
  15. <view class="operation-content">
  16. <view class="operation-item" v-if="isShowPhoto" @click="handlePhotoClick">
  17. <image :src="photoIcon" class="operation-icon"></image>
  18. 拍照
  19. </view>
  20. <view class="operation-item" @click="handleServiceClick">
  21. <image :src="serviceIcon" class="operation-icon"></image>
  22. 维修
  23. </view>
  24. <view class="operation-item" @click="handleSettingClick">
  25. <image :src="settingIcon" class="operation-icon"></image>
  26. 设置
  27. </view>
  28. <view class="operation-item" @click="handleSimClick">
  29. <image :src="simIcon" class="operation-icon"></image>
  30. SIM卡
  31. </view>
  32. <view class="operation-item" @click="modification">
  33. <image :src="editIcon" class="operation-icon"></image>
  34. 修改
  35. </view>
  36. </view>
  37. </view>
  38. <view class="device-detail__body">
  39. <DeviceCard
  40. :dataSource="deviceInfo"
  41. :collectTime="time"
  42. :title="deviceInfo.name"
  43. :deviceType="deviceType"
  44. />
  45. <view class="tabs">
  46. <view class="tab-container" v-if="isShowTab">
  47. <view class="tab-item" :class="activeTab === 'pestAnalysis'?'active':''" @click="handleTabClick('pestAnalysis')" v-if="disableShow">
  48. 害虫分析
  49. </view>
  50. <view class="tab-item" :class="activeTab === 'viewImage'?'active':''" @click="handleTabClick('viewImage')">
  51. 查看图片
  52. </view>
  53. <view class="tab-item" :class="activeTab === 'deviceData'?'active':''" @click="handleTabClick('deviceData')">
  54. 设备数据
  55. </view>
  56. </view>
  57. <view class="select-timer-container">
  58. <view class="select-year">
  59. <view class="select-year-item" @click="showPicker = true">
  60. {{ currentYear }}
  61. <u-icon name="arrow-down" size="18" class="arrow-down"></u-icon>
  62. </view>
  63. </view>
  64. <view class="tabs-timer-container" @click="showCalendar">
  65. <view class="tabs-timer-item">
  66. {{startDate}}
  67. </view>
  68. 至
  69. <view class="tabs-timer-item">
  70. {{endDate}}
  71. </view>
  72. <u-icon name="calendar" size="36" class="calendar-icon"></u-icon>
  73. </view>
  74. </view>
  75. </view>
  76. <view v-if="activeTab === 'pestAnalysis'" class="tab-content">
  77. <PestDiscern
  78. :total="total"
  79. :pest_order="pest_order"
  80. />
  81. <PestEchart
  82. :pest_order="pest_order"
  83. @getInfo="getInfo"
  84. :endDate="endDate"
  85. :d_id="deviceInfo.d_id"
  86. :day="day"
  87. :pest="pest"
  88. />
  89. <PestArchive
  90. :pest_info="pestInfo"
  91. />
  92. <view v-if="!pests.length">
  93. <u-empty text="暂无数据"></u-empty>
  94. </view>
  95. </view>
  96. <view v-show="activeTab === 'viewImage'">
  97. <scroll-view class="scroll-view" scroll-y style="height: 60vh;" @scrolltolower="handleReachBottom">
  98. <photoImage
  99. :images="imageList"
  100. :pestList="pestList"
  101. :disableShow="disableShow"
  102. @changeTab="changeTab"
  103. :currentYear="currentYear"
  104. :deviceInfo="deviceInfo"
  105. />
  106. </scroll-view>
  107. </view>
  108. <view v-show="activeTab === 'deviceData'">
  109. <DeviceData
  110. :activeTabLabel="activeTab"
  111. :deviceStatic="deviceStatic"
  112. :deviceInfo="deviceInfo"
  113. :polylineList="polylineList"
  114. :deviceHistoryList="deviceHistoryList"
  115. :totalPage="totalPage"
  116. :currentPage="page"
  117. :page_size="page_size"
  118. @prevPage="prevPage"
  119. @nextPage="nextPage"
  120. />
  121. </view>
  122. </view>
  123. <u-calendar v-model="show" :mode="mode" range-color="#999" btn-type="success" active-bg-color="#0BBC58" range-bg-color="rgba(11,188,88,0.13)" @change="handleChange" :max-date="maxDate" :min-date="minDate"></u-calendar>
  124. <u-picker v-model="showPicker" mode="selector" :range="selectorRange" range-key="id" :default-selector="[0]" @confirm="confirmHandler"></u-picker>
  125. </view>
  126. </template>
  127. <script>
  128. import DeviceCard from './components/DeviceCard.vue';
  129. import PestDiscern from './components/pestDiscern.vue';
  130. import PestEchart from './components/pestEchart.vue';
  131. import PestArchive from './components/pestArchive.vue';
  132. import photoImage from './components/photoImage.vue';
  133. import DeviceData from './components/deviceData.vue';
  134. export default {
  135. components: {
  136. DeviceCard,
  137. PestDiscern,
  138. PestEchart,
  139. PestArchive,
  140. photoImage,
  141. DeviceData,
  142. },
  143. data(){
  144. return {
  145. isShowTab:false,
  146. showPicker: false,
  147. loading: false,
  148. disableShow: false,
  149. isShowOperation: false,
  150. photoIcon:'https://s3.hnyfwlw.com/webstaticimg/bigdata_app/newImg/home/photoIcon.png',
  151. editIcon:'https://s3.hnyfwlw.com/webstaticimg/bigdata_app/newImg/home/editIcon.png',
  152. serviceIcon:'https://s3.hnyfwlw.com/webstaticimg/bigdata_app/newImg/home/serviceIcon.png',
  153. simIcon:'https://s3.hnyfwlw.com/webstaticimg/bigdata_app/newImg/home/simIcon.png',
  154. settingIcon:'https://s3.hnyfwlw.com/webstaticimg/bigdata_app/newImg/home/settingIcon.png',
  155. totalPage:0,
  156. currentYear: new Date().getFullYear(),
  157. selectorRange: [],
  158. maxDate: this.formatDate(new Date()),
  159. minDate: this.formatDate(new Date(new Date().getFullYear(), 0, 1)),
  160. show: false,
  161. showSim: false,
  162. // 当前日期向前推30天 格式2026-01-01 月份和日期小于10的时候前面加个0
  163. startDate: this.formatDate(new Date(new Date().getTime() - 30 * 24 * 60 * 60 * 1000)),
  164. endDate: this.formatDate(new Date()),
  165. mode: 'range',
  166. imageList: [],
  167. pest_order:{},
  168. deviceInfo: {},
  169. pestInfo: {},
  170. time: '',
  171. activeTab: 'pestAnalysis',
  172. deviceType: '',
  173. location: '',
  174. total: 0,
  175. imgTotal: 0,
  176. day: [],
  177. pest: [],
  178. page:1,
  179. is_pest:'',
  180. page_size:24,
  181. pestList:[],
  182. pest_names:'',
  183. pests:[],
  184. polylineList:[],
  185. isShowPhoto:false,
  186. deviceHistoryList:[],
  187. deviceStatic:{}
  188. }
  189. },
  190. onLoad(options){
  191. this.deviceInfo = JSON.parse(options.info);
  192. const newVal = this.deviceInfo;
  193. if (newVal.device_model == '11'){
  194. this.isShowPhoto = true
  195. } else if(newVal.device_model == '12'){
  196. this.isShowPhoto = false
  197. } else if(newVal.device_model == '13'){
  198. this.isShowPhoto = true
  199. } else if(newVal.device_model == '14'){
  200. this.isShowPhoto = true
  201. } else if(newVal.device_model == '15'){
  202. this.isShowPhoto = false
  203. } else{
  204. this.isShowPhoto = true
  205. }
  206. this.getPestAnalysis();
  207. this.isShow();
  208. const currentYear = new Date().getFullYear();
  209. this.selectorRange = [];
  210. for(let i = 0;i<50;i++){
  211. const item = {
  212. label: currentYear - i,
  213. id: currentYear - i
  214. }
  215. this.selectorRange.push(item);
  216. }
  217. },
  218. methods: {
  219. handleReachBottom(){
  220. if (this.activeTab === 'viewImage') {
  221. if(this.imageList.length >= this.imgTotal){
  222. return
  223. }
  224. this.initImageList(true);
  225. }
  226. },
  227. handleSimClick(){
  228. // this.showSim = true;
  229. //`/pages/deviceDetails/weatherStation/${type}?deviceInfo=${encodeURIComponent(JSON.stringify(this.deviceInfo))}`
  230. uni.navigateTo({
  231. url:
  232. '/pages/deviceDetails/weatherStation/simDetail?deviceInfo=' +
  233. encodeURIComponent(JSON.stringify(this.deviceInfo))
  234. });
  235. },
  236. modification() {
  237. uni.navigateTo({
  238. url:
  239. '/pages/equipList2/seabox/modification?data=' +
  240. JSON.stringify(this.deviceInfo) +
  241. '&id=' +
  242. this.deviceInfo.type,
  243. });
  244. },
  245. async handlePhotoClick(){
  246. const res = await this.$myRequest({
  247. url: '/api/api_gateway?method=forecast.send_control.admin_device_control',
  248. method: 'POST',
  249. data: {
  250. device_type_id: this.deviceInfo.type,
  251. d_id: this.deviceInfo.d_id,
  252. cmd: 'takephoto',
  253. },
  254. });
  255. if(res){
  256. this.$u.toast('拍照成功')
  257. }
  258. },
  259. handleServiceClick(){
  260. uni.navigateTo({
  261. url: '/pages/afterSale/addafter?d_id=' + this.deviceInfo.d_id +'&device_id='+this.deviceInfo.id + '&device_type=' + this.deviceInfo.type,
  262. })
  263. },
  264. handleSettingClick(){
  265. uni.navigateTo({
  266. url: '/pages/cbd/deviceControl?deviceId=' + this.deviceInfo.id + '&d_id=' + this.deviceInfo.d_id,
  267. });
  268. },
  269. closeOperationHandler(){
  270. this.isShowOperation = false;
  271. },
  272. isShow(){
  273. // disable == 0 或者 device_model == 15 表示不可以查看
  274. if(!this.deviceInfo.d_id){
  275. return false;
  276. }
  277. let showStatus = true;
  278. if(this.deviceInfo.device_model == 15 || this.deviceInfo.device_model == 12){
  279. showStatus = false;
  280. }
  281. if(showStatus){
  282. this.activeTab = 'pestAnalysis';
  283. }else{
  284. this.activeTab = 'deviceData';
  285. }
  286. this.initAction();
  287. this.isShowTab = showStatus;
  288. if(this.deviceInfo.disable == 0){
  289. this.disableShow = false;
  290. if(showStatus){
  291. this.activeTab = 'viewImage';
  292. this.handleTabClick('viewImage');
  293. }
  294. }else{
  295. this.disableShow = true;
  296. }
  297. },
  298. prevPage(e){
  299. if(e == 1){
  300. return
  301. }
  302. this.page = e-=1;
  303. this.getDeviceHistoryData();
  304. },
  305. nextPage(e){
  306. if(e * this.page_size >= this.totalPage){
  307. return
  308. }
  309. this.page = e+=1;
  310. this.getDeviceHistoryData();
  311. },
  312. changeTab(pestList){
  313. let pest_names = pestList.map(item => item.pest_name);
  314. this.pest_names = pest_names.join(',');
  315. this.initImageList();
  316. },
  317. confirmHandler(e){
  318. this.currentYear = this.selectorRange[e].id;
  319. if(this.currentYear == new Date().getFullYear()){
  320. // 结束日期为this.endDate的月份和日期加上选择的年份
  321. const timeDate = this.currentYear + '-' + this.endDate.split('-')[1] + '-' + this.endDate.split('-')[2];
  322. this.endDate = this.formatDate(new Date(timeDate));
  323. // 开始日期为结束日期前30天
  324. this.startDate = this.formatDate(new Date(new Date(this.endDate).getTime() - 30 * 24 * 60 * 60 * 1000));
  325. this.maxDate = this.formatDate(new Date());
  326. this.minDate = this.formatDate(new Date(new Date().getFullYear(), 0, 1));
  327. }else{
  328. // 结束日期为this.endDate的月份和日期加上选择的年份
  329. const timeDate = this.currentYear + '-' + this.endDate.split('-')[1] + '-' + this.endDate.split('-')[2];
  330. this.endDate = this.formatDate(new Date(timeDate));
  331. // 开始日期为结束日期前30天
  332. this.startDate = this.formatDate(new Date(new Date(this.endDate).getTime() - 30 * 24 * 60 * 60 * 1000));
  333. this.maxDate = this.formatDate(new Date(this.currentYear, 11, 31));
  334. this.minDate = this.formatDate(new Date(this.currentYear, 0, 1));
  335. }
  336. this.initAction();
  337. this.showPicker = false;
  338. },
  339. getInfo(info){
  340. this.pestInfo = info;
  341. },
  342. // 格式化日期为YYYY-MM-DD格式,月份和日期小于10时前面加0
  343. formatDate(date) {
  344. const year = date.getFullYear();
  345. const month = String(date.getMonth() + 1).padStart(2, '0');
  346. const day = String(date.getDate()).padStart(2, '0');
  347. return `${year}-${month}-${day}`;
  348. },
  349. handleChange(e){
  350. this.startDate = e.startDate;
  351. this.endDate = e.endDate;
  352. this.page = 1;
  353. this.initAction();
  354. },
  355. showCalendar(){
  356. this.show = true;
  357. },
  358. handleBack() {
  359. uni.navigateBack({
  360. delta: 1
  361. });
  362. },
  363. initAction(){
  364. this.pest_order = {}
  365. if(this.activeTab === 'pestAnalysis'){
  366. this.getPestAnalysis();
  367. }else if(this.activeTab === 'viewImage'){
  368. this.initPest();
  369. this.initImageList();
  370. }else if(this.activeTab === 'deviceData'){
  371. this.getDeviceData();
  372. this.getPolylineData();
  373. this.getDeviceHistoryData();
  374. }
  375. },
  376. handleTabClick(tab) {
  377. this.activeTab = tab;
  378. this.initAction();
  379. },
  380. async getDeviceData(){
  381. const res = await this.$myRequest({
  382. url: '/api/api_gateway?method=forecast.worm_lamp.device_status_data',
  383. method: 'POST',
  384. data: {
  385. device_id: this.deviceInfo.id,
  386. },
  387. });
  388. this.deviceStatic = res;
  389. },
  390. async initImageList(isLoadMore){
  391. if(isLoadMore){
  392. this.page++;
  393. }
  394. uni.showLoading({
  395. title: '加载中',
  396. })
  397. const res = await this.$myRequest({
  398. url: '/api/api_gateway?method=forecast.new_cbd.photo_list',
  399. method: 'POST',
  400. data: {
  401. page:this.page,
  402. page_size:this.page_size,
  403. device_id: this.deviceInfo.id,
  404. is_pest: this.is_pest,
  405. identify_model: 'B',
  406. pest_names: this.pest_names,
  407. time_begin: this.formatDate(new Date(this.startDate)) + ' 00:00:00',// 格式化开始时间YYYY-MM-DD HH:MM:SS
  408. time_end: this.formatDate(new Date(this.endDate)) + ' 23:59:59',// 格式化结束时间YYYY-MM-DD HH:MM:SS
  409. },
  410. });
  411. const data = res?.data || [];
  412. uni.hideLoading();
  413. this.imgTotal = res?.num || 0;
  414. if (isLoadMore) {
  415. this.imageList = [...this.imageList, ...data];
  416. } else {
  417. this.imageList = data;
  418. }
  419. },
  420. async initPest(){
  421. const res = await this.$myRequest({
  422. url: '/api/api_gateway?method=forecast.new_cbd.pest_type_list',
  423. method: 'POST',
  424. data:{
  425. page:1,
  426. page_size:999999,
  427. device_id: this.deviceInfo.id,
  428. identify_model: 'B',
  429. time_begin: this.formatDate(new Date(this.startDate)) + ' 00:00:00',// 格式化开始时间YYYY-MM-DD HH:MM:SS
  430. time_end: this.formatDate(new Date(this.endDate)) + ' 23:59:59',// 格式化结束时间YYYY-MM-DD HH:MM:SS
  431. },
  432. });
  433. const data = res?.data || [];
  434. this.pestList = data
  435. },
  436. async getPolylineData(){
  437. this.loading = true;
  438. const res = await this.$myRequest({
  439. url: '/api/api_gateway?method=forecast.worm_lamp.device_polyline_data',
  440. method: 'POST',
  441. data: {
  442. device_type_id: this.deviceInfo.type_id,
  443. d_id: this.deviceInfo.d_id,
  444. start_time: new Date(this.startDate + ' 00:00:00').getTime()/1000,// 转成毫秒
  445. end_time: new Date(this.endDate + ' 23:59:59').getTime()/1000,// 转成毫秒
  446. },
  447. });
  448. this.loading = false;
  449. const data = res || [];
  450. this.polylineList = data
  451. },
  452. async getDeviceHistoryData(){
  453. const res = await this.$myRequest({
  454. url: '/api/api_gateway?method=forecast.worm_lamp.device_history_data',
  455. method: 'POST',
  456. data: {
  457. device_type_id: this.deviceInfo.type_id,
  458. device_id: this.deviceInfo.id,
  459. start_time: new Date(this.startDate + ' 00:00:00').getTime()/1000,
  460. end_time: new Date(this.endDate + ' 23:59:59').getTime()/1000,
  461. page: this.page,
  462. page_size: this.page_size,
  463. },
  464. });
  465. const data = res?.data || [];
  466. this.totalPage = res.counts;
  467. this.deviceHistoryList = data
  468. },
  469. async getPestAnalysis(){
  470. const res = await this.$myRequest({
  471. url: '/api/api_gateway?method=forecast.cbd_analysis.analysis_pest_result',
  472. method: 'POST',
  473. data: {
  474. d_id: this.deviceInfo.d_id,
  475. start: this.startDate,
  476. end: this.endDate,
  477. model: 'B'
  478. },
  479. });
  480. const pest_order = res?.pest_order;
  481. this.getInfo({});
  482. let total = 0;
  483. this.pests = [];
  484. for(let key in pest_order){
  485. total += pest_order[key] || 0;
  486. this.pests.push({
  487. name: key,
  488. percent: (pest_order[key] / total) * 100
  489. })
  490. }
  491. this.pest_order = pest_order;
  492. this.day = res?.day || [];
  493. const pest = res?.pest || [];
  494. this.pest = pest;
  495. // pest.forEach(p =>{
  496. // for(let i = 0;i< p.length;i++){
  497. // this.pest.push(p[i]);
  498. // }
  499. // })
  500. this.total = total;
  501. }
  502. }
  503. }
  504. </script>
  505. <style scoped lang="scss">
  506. ::v-deep .u-calendar__action{
  507. display:flex;
  508. justify-content: space-between;
  509. }
  510. ::v-deep .u-hover-class{
  511. .u-calendar__content__item__inner{
  512. color:#aaa !important;
  513. }
  514. }
  515. .operation-container{
  516. position: fixed;
  517. right: 0;
  518. top: 0;
  519. width: 100%;
  520. height: 100%;
  521. z-index: 99;
  522. }
  523. .operation{
  524. position: fixed;
  525. top: 260rpx;
  526. right: 0;
  527. z-index: 999;
  528. width:48rpx;
  529. height: 100rpx;
  530. line-height: 50rpx;
  531. border-radius: 8px 0 0 8px;
  532. border-top: 4rpx solid #FFF;
  533. border-bottom: 4rpx solid #FFF;
  534. border-left: 4rpx solid #FFF;
  535. background: #dddfe6a3;
  536. color: #515153;
  537. text-align: center;
  538. font-family: "Source Han Sans CN VF";
  539. font-size: 24rpx;
  540. font-weight: 500;
  541. writing-mode: vertical-rl;
  542. }
  543. .operation-background{
  544. position: fixed;
  545. right: 0;
  546. top: 0;
  547. width: 100%;
  548. height: 100%;
  549. z-index: 998;
  550. background: #00000040;
  551. }
  552. .operation-content{
  553. position: fixed;
  554. top: 240rpx;
  555. right: 80rpx;
  556. height: 126rpx;
  557. display: flex;
  558. padding: 16rpx 32rpx;
  559. align-items: center;
  560. gap: 64rpx;
  561. z-index: 999;
  562. border-radius: 32rpx;
  563. border: 2rpx solid #FFF;
  564. background: #FFF;
  565. backdrop-filter: blur(8rpx);
  566. .operation-item{
  567. display: flex;
  568. flex-direction: column;
  569. align-items: center;
  570. justify-content: center;
  571. color: #333333;
  572. text-align: center;
  573. font-family: "Source Han Sans CN VF";
  574. font-size: 24rpx;
  575. font-weight: 400;
  576. }
  577. .operation-icon{
  578. width: 58rpx;
  579. height: 58rpx;
  580. }
  581. }
  582. .device-detail {
  583. display: flex;
  584. width: 100%;
  585. height: calc(100vh - 112rpx);
  586. padding-top: 112rpx;
  587. flex-direction: column;
  588. align-items: center;
  589. overflow-y: scroll;
  590. background: linear-gradient(180deg, #ffffff00 0%, #F5F6FA 23.64%, #F5F6FA 100%), linear-gradient(102deg, #BFEADD 6.77%, #B8F1E7 40.15%, #B9EEF5 84.02%);
  591. .device-detail__header {
  592. width: 100%;
  593. font-size: 28rpx;
  594. color: #999;
  595. color: #042118;
  596. font-family: 'Source Han Sans CN VF';
  597. font-weight: 700;
  598. position: relative;
  599. text-align: center;
  600. .arrow-left {
  601. position: absolute;
  602. left: 32rpx;
  603. margin-right: 12rpx;
  604. }
  605. }
  606. .device-detail__body {
  607. width: calc(100% - 64rpx);
  608. margin: 0 auto;
  609. border-radius: 16rpx;
  610. overflow-x: hidden;
  611. overflow-y: auto;
  612. // 隐藏滚动条
  613. -ms-overflow-style: none;
  614. scrollbar-width: none;
  615. }
  616. .tab-content{
  617. width: 100%;
  618. padding-bottom: 32rpx;
  619. }
  620. .tabs {
  621. background: #ffffff;
  622. margin: 24rpx 0;
  623. border-radius: 16rpx;
  624. padding: 16rpx 0;
  625. padding-top: 0;
  626. .tab-container{
  627. display: flex;
  628. width: 100%;
  629. height: 88rpx;
  630. line-height: 88rpx;
  631. text-align: center;
  632. font-size: 28rpx;
  633. font-weight: 700;
  634. color: #042118;
  635. font-family: 'Source Han Sans CN VF';
  636. }
  637. .select-timer-container{
  638. display:flex;
  639. align-items: center;
  640. padding-left: 32rpx;
  641. .select-year{
  642. width: 110rpx;
  643. text-align: center;
  644. height: 64rpx;
  645. border-radius: 32rpx;
  646. font-family: 'Source Han Sans CN VF';
  647. line-height: 64rpx;
  648. background: #F1F4F8;
  649. padding: 0 32rpx;
  650. .select-year-item{
  651. color: #656565;
  652. font-size: 24rpx;
  653. display: flex;
  654. align-items: center;
  655. justify-content: space-around;
  656. }
  657. }
  658. }
  659. .tabs-timer-container{
  660. display: flex;
  661. align-items: center;
  662. width: calc(100% - 256rpx);
  663. height: 64rpx;
  664. line-height: 64rpx;
  665. text-align: center;
  666. font-size: 24rpx;
  667. font-weight: 500;
  668. font-family: 'Source Han Sans CN VF';
  669. border-radius: 32rpx;
  670. background: #F1F4F8;
  671. padding: 0 32rpx;
  672. color: #656565;
  673. margin: 16rpx;
  674. position: relative;
  675. .tabs-timer-item{
  676. width: 42%;
  677. color: #656565;
  678. text-align: center;
  679. font-family: "Source Han Sans CN VF";
  680. font-size: 24rpx;
  681. font-weight: 400;
  682. }
  683. .calendar-icon{
  684. margin-left: 24rpx;
  685. }
  686. }
  687. .tab-item {
  688. flex: 1;
  689. color: #999999;
  690. text-align: center;
  691. font-family: "Source Han Sans CN VF";
  692. font-size: 28rpx;
  693. font-weight: 400;
  694. }
  695. .active{
  696. position: relative;
  697. color: #303133;
  698. text-align: center;
  699. font-family: "Source Han Sans CN VF";
  700. font-size: 28rpx;
  701. font-weight: 700;
  702. &::after {
  703. content: '';
  704. position: absolute;
  705. bottom: 0;
  706. left: 50%;
  707. -webkit-transform: translateX(-50%);
  708. transform: translateX(-50%);
  709. width: 36rpx;
  710. height: 36rpx;
  711. border: 6rpx solid #0BBC58;
  712. border-radius: 50%;
  713. border-color: transparent;
  714. border-bottom-color: #0BBC58;
  715. }
  716. }
  717. }
  718. }
  719. </style>