rankList.vue 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738
  1. <!--
  2. [报名] 样式3 - 排名列表
  3. http://localhost:5173/card/#/pages/bm/style3/rankList
  4. https://oss-mbh5.colormaprun.com/card/#/pages/bm/style3/rankList
  5. -->
  6. <template>
  7. <view class="body">
  8. <view class="content uni-column">
  9. <view class="uni-column" :class="cssTop">
  10. <view class="topbar uni-row" :class="cssTopbarColor">
  11. <uni-icons type="left" class="topbar-back" @click="btnBack"></uni-icons>
  12. <text class="mcName">{{mcName}}</text>
  13. <text class="topbar-rule" @click="btnInfo">规则</text>
  14. <!-- <image mode="aspectFit" class="topbar-info" @click="btnInfo" src="/static/default/info.png"></image> -->
  15. </view>
  16. <view class="topbtm uni-row">
  17. <!-- <view class="topbtm-null"></view> -->
  18. <view class="topbtm-egg" @click="btnMyEgg">蛋叔券</view>
  19. <text class="topbtm-name">{{nickName}}</text>
  20. <view class="topbtm-egg" @click="btnExchg">兑换地址</view>
  21. </view>
  22. </view>
  23. <view class="main uni-column">
  24. <view class="main-bar uni-row uni-jcse">
  25. <text>总距离:{{fmtDistanct(totalDistanct)}}km</text>
  26. <text>总打点数:{{totalCp}}个</text>
  27. <text>总百味豆数:{{totalSysPoint}}个</text>
  28. </view>
  29. <uni-segmented-control class="main-tab" :current="tabCurrent" :values="tabItems"
  30. @clickItem="onClickTabItem" styleType="button" :activeColor="tabActiveColor"></uni-segmented-control>
  31. <view class="tab-view uni-column">
  32. <!-- 总距离 -->
  33. <my-ranklist v-show="tabCurrent === 0" :rankRs="rankList.totalDistanceRs" rank-type="totalDistance"></my-ranklist>
  34. <!-- 打点数 -->
  35. <my-ranklist v-show="tabCurrent === 1" :rankRs="rankList.totalCpRs" rank-type="totalCp"></my-ranklist>
  36. <!-- 百味豆 -->
  37. <my-ranklist v-show="tabCurrent === 2" :rankRs="rankList.totalSysPointRs" rank-type="totalSysPoint"></my-ranklist>
  38. <!-- 配速 -->
  39. <my-ranklist v-show="tabCurrent === 3" :rankRs="rankList.fastPaceRs" rank-type="fastPace"></my-ranklist>
  40. </view>
  41. <button class="btnBack" @click="btnStartGame">我要比赛</button>
  42. <!-- <button class="btnBack" @click="btnBack">返回</button> -->
  43. </view>
  44. <my-popup ref="mypopup" :dataList="popupDataList" :acttime="acttime"></my-popup>
  45. <my-popup ref="mypopupExchg" :dataList="popupExchgList"></my-popup>
  46. </view>
  47. </view>
  48. </template>
  49. <script>
  50. import tools from '/common/tools';
  51. import { teamName, defaultPopUpDataList } from '/common/define';
  52. import {
  53. token,
  54. apiMatchRsDetailQuery,
  55. apiCardRankDetailQuery,
  56. apiCardConfigQuery,
  57. apiUserCurrentRankNumQuery,
  58. apiIsAllowMcSignUp,
  59. checkResCode
  60. } from '/common/api';
  61. export default {
  62. data() {
  63. return {
  64. pageName: "rankList",
  65. firstEnterKey: 'firstEnter-bm-style3',
  66. rankKey: "rank-bm-style3",
  67. queryObj: {},
  68. queryString: "",
  69. token: "",
  70. ovtype: "",
  71. ecId: 0, // 卡片id
  72. mcId: 0, // 赛事id
  73. mcType: 0, // 赛事类型 1 普通活动 2 线下赛 3 线上赛
  74. mcName: "", // 赛事名称
  75. acttime: "", // 活动时间
  76. beginSecond: null, // 活动或赛事开始时间戳,单位秒
  77. endSecond: null, // 活动或赛事结束时间戳,单位秒
  78. ocaId: 0, // 关联id,带入到App活动详情页面
  79. nickName: "", // 昵称
  80. totalNum: null, // 总场次
  81. totalDistanct: null, // 总距离,单位米
  82. totalDistanctRankNum: null, // 总距离排名
  83. totalCp: null, // 总打点数
  84. totalCpRankNum: null, // 总打点数排名
  85. totalSysPoint: null, // 总百味豆
  86. totalSysPointRankNum: null, // 总百味豆排名
  87. fastPace: null, // 个人最快配速
  88. fastPaceRankNum: null, // 个人最快配速排名
  89. // ocaRs: [], // 卡片对应活动集合
  90. mcState: 0 , // 赛事/活动状态 0: 未开始 1: 进行中 2: 已结束
  91. allowMcSignUp: false, // 是否允许重新分组
  92. countdown: "", // 倒计时
  93. rankList: { // 排名列表
  94. totalDistanceRs: [],
  95. totalCpRs: [],
  96. totalSysPointRs: [],
  97. fastPaceRs: []
  98. },
  99. interval: null,
  100. teamType: 0, // 队伍类型
  101. dispArrStr: "totalDistance,totalCp,totalSysPoint,fastPace", // 要显示的集合范围
  102. tabItems: ["总距离", "打点数", "百味豆", "配速"],
  103. tabCurrent: 0,
  104. tabActiveColor: "#81cd00",
  105. cssTop: "",
  106. cssTopbarColor: "",
  107. popupDataList: [],
  108. popupExchgList: []
  109. }
  110. },
  111. computed: {},
  112. onLoad(query) { // 类型非必填,可自动推导
  113. // console.log(query);
  114. this.queryObj = query;
  115. this.queryString = tools.objectToQueryString(this.queryObj);
  116. // console.log(queryString);
  117. this.token = query["token"] ?? token;
  118. this.ecId = query["id"] ?? 0;
  119. this.ovtype = query["ovtype"] ?? "";
  120. this.firstEnterKey += "-" + this.ecId;
  121. console.log("firstEnterKey:", this.firstEnterKey);
  122. this.rankKey += "-" + this.ecId;
  123. console.log("rankKey:", this.rankKey);
  124. tools.removeCssCode();
  125. this.getCardConfigQuery();
  126. this.dealOvtype();
  127. },
  128. // 页面初次渲染完成,此时组件已挂载完成,DOM 树($el)已可用
  129. onReady() {
  130. // this.dealFirstEnter();
  131. },
  132. onUnload() {
  133. this.clear();
  134. },
  135. methods: {
  136. dealOvtype() {
  137. if (this.ovtype == "totalDistance") {
  138. this.tabCurrent = 0;
  139. } else if (this.ovtype == "totalCp") {
  140. this.tabCurrent = 1;
  141. } else if (this.ovtype == "totalSysPoint") {
  142. this.tabCurrent = 2;
  143. } else if (this.ovtype == "fastPace") {
  144. this.tabCurrent = 3;
  145. }
  146. console.log(`dealOvtype: ${this.ovtype} tabCurrent: ${this.tabCurrent}`);
  147. },
  148. dealNotice(rank) {
  149. // console.log('[dealFirstEnter]');
  150. let that = this;
  151. uni.getStorage({
  152. key: that.rankKey,
  153. success: (res) => {
  154. console.log('[getStorage]', that.rankKey, res.data);
  155. const oldRank = res.data;
  156. if (oldRank != rank) {
  157. // that.notice = true;
  158. that.setRankValue(rank);
  159. }
  160. },
  161. fail: (e) => {
  162. console.log('[getStorage] fail', that.rankKey, e);
  163. // that.notice = false;
  164. that.setRankValue(rank);
  165. },
  166. })
  167. },
  168. setRankValue(data) {
  169. let that = this;
  170. uni.setStorage({
  171. key: that.rankKey,
  172. data: data,
  173. success: () => {
  174. console.log('[setStorage] success', that.rankKey, data);
  175. },
  176. fail: (e) => {
  177. console.log('[setStorage] fail', that.rankKey, e);
  178. },
  179. })
  180. },
  181. dealFirstEnter() {
  182. // console.log('[dealFirstEnter]');
  183. let that = this;
  184. uni.getStorage({
  185. key: that.firstEnterKey,
  186. success: (res) => {
  187. console.log('[getStorage]', that.firstEnterKey, res.data);
  188. },
  189. fail: (e) => {
  190. console.log('[getStorage] fail', that.firstEnterKey, e);
  191. that.btnInfo();
  192. that.setFirstEnterValue(true);
  193. },
  194. })
  195. },
  196. setFirstEnterValue(data) {
  197. let that = this;
  198. uni.setStorage({
  199. key: that.firstEnterKey,
  200. data: data,
  201. success: () => {
  202. console.log('[setStorage] success', that.firstEnterKey, data);
  203. },
  204. fail: (e) => {
  205. console.log('[setStorage] fail', that.firstEnterKey, e);
  206. },
  207. })
  208. },
  209. clear() {
  210. if (this.interval != null) {
  211. clearInterval(this.interval);
  212. this.interval = null;
  213. }
  214. },
  215. loadConfig(config) {
  216. // console.log("config", config);
  217. // 加载CSS样式
  218. const css = config.css;
  219. if (css != undefined && css.length > 0) {
  220. tools.loadCssCode(css);
  221. if (css.indexOf(".top{") >= 0) {
  222. this.cssTop = "top";
  223. }
  224. if (css.indexOf(".topbar-color{") >= 0) {
  225. this.cssTopbarColor = "topbar-color";
  226. }
  227. }
  228. if (this.cssTop == "") {
  229. this.cssTop = "top-default";
  230. }
  231. if (this.cssTopbarColor == "") {
  232. this.cssTopbarColor = "topbar-color-default";
  233. }
  234. console.log("[loadConfig] cssTop:", this.cssTop);
  235. console.log("[loadConfig] cssTopbarColor:", this.cssTopbarColor);
  236. const tabActiveColor = config.tabActiveColor;
  237. if (tabActiveColor != undefined && tabActiveColor.length > 0) {
  238. this.tabActiveColor = tabActiveColor;
  239. }
  240. // 加载弹窗数据
  241. const popupDataList = config.popupDataList;
  242. // console.log("[loadConfig] popupDataList:", popupDataList);
  243. if (popupDataList != undefined && popupDataList.length > 0) {
  244. for (var i = 0; i < popupDataList.length; i++) {
  245. // console.log("[loadConfig] popupDataList", i, popupDataList[i]);
  246. if (popupDataList[i] == 'default') {
  247. for (var j = 0; j < defaultPopUpDataList.length; j++) {
  248. this.popupDataList.push(defaultPopUpDataList[j]);
  249. }
  250. } else {
  251. this.popupDataList.push(popupDataList[i]);
  252. }
  253. }
  254. } else {
  255. this.popupDataList = defaultPopUpDataList;
  256. console.log("[loadConfig] popupDataList 加载默认列表");
  257. }
  258. // console.log("[loadConfig] popupDataList:", this.popupDataList);
  259. // 加载弹窗(兑换地点)数据
  260. const popupExchgList = config.popupExchgList;
  261. if (popupExchgList != undefined && popupExchgList.length > 0) {
  262. for (var i = 0; i < popupExchgList.length; i++) {
  263. // console.log("[loadConfig] popupExchgList", i, popupExchgList[i]);
  264. this.popupExchgList.push(popupExchgList[i]);
  265. }
  266. }
  267. // console.log("[loadConfig] popupExchgList:", this.popupExchgList);
  268. },
  269. // 获取倒计时
  270. getCountdown() {
  271. // console.log(this.endSecond)
  272. if (this.endSecond > 0) {
  273. const now = Date.now() / 1000;
  274. const dif = this.endSecond - now;
  275. // const dif = 3600*24 - 60;
  276. if (dif > 0) {
  277. this.countdown = '距结束 ' + tools.convertSecondsToDHM(dif);
  278. } else {
  279. this.countdown = "活动已结束";
  280. }
  281. // this.countdown = tools.convertSecondsToHMS(dif);
  282. } else {
  283. this.countdown = "距结束 --天--小时";
  284. }
  285. },
  286. // 格式化 距离
  287. fmtDistanct(val) {
  288. return Math.round(val * 100 / 1000) / 100;
  289. /* if (val < 10000)
  290. return Math.round(val * 10 / 1000) / 10;
  291. else
  292. return Math.round(val / 1000); */
  293. },
  294. fmtMcTime(timestamp) {
  295. return tools.fmtMcTime(timestamp);
  296. },
  297. // 获取活动时间
  298. getActtime() {
  299. this.acttime = tools.getActtime(this.beginSecond, this.endSecond);
  300. },
  301. getTeamName(teamType, teamIndex) {
  302. return teamName[teamType][teamIndex];
  303. },
  304. getCardConfigQuery() {
  305. uni.request({
  306. url: apiCardConfigQuery,
  307. header: {
  308. "Content-Type": "application/x-www-form-urlencoded",
  309. "token": this.token,
  310. },
  311. method: "POST",
  312. data: {
  313. ecId: this.ecId,
  314. pageName: this.pageName
  315. },
  316. success: (res) => {
  317. // console.log("getCardConfigQuery", res)
  318. const data = res.data.data;
  319. // console.log("configJson", data.configJson);
  320. const config = data.configJson != "" ? JSON.parse(data.configJson) : "";
  321. // console.log("configJson", data.configJson);
  322. /* const config = {
  323. "css": `
  324. .top{
  325. width: 100%;
  326. height: 170px;
  327. padding-top: 36px;
  328. justify-content: space-between;
  329. background-image: url('static/backgroud/top_bg_egg3.png');
  330. background-repeat: no-repeat;
  331. background-position: center;
  332. background-size: cover;
  333. }
  334. .topbar-color{
  335. color: #333333;
  336. }
  337. .topbtm-name{
  338. background-color: #c77f34 !important;
  339. color: #ffffff !important;
  340. }
  341. .topbtm-egg{
  342. background-color: #c6690a !important;
  343. color: #ffffff !important;
  344. }
  345. .btnBack{
  346. background-color: #ff870d !important;
  347. }
  348. .main-bar{
  349. background-color: #FFEDDB !important;
  350. color: #ff870d !important;
  351. }
  352. .swiper-item-button {
  353. background-color: #ff870e !important;
  354. }
  355. .uni-swiper-dot-active {
  356. background: #ff870e !important;
  357. }
  358. `,
  359. "tabActiveColor": "#ff870d",
  360. "popupDataList": [{
  361. "type": 1,
  362. "data": {
  363. "title": "小飞龙定向赛",
  364. "img": "/static/common/egg.png",
  365. "content": "济南奥体中心“一场三馆”包括体育场、体育馆、网球馆和游泳馆,呈现出“东荷西柳”的总体布局。 体育场以济南的“市树”柳树为母题,将垂柳柔美飘逸的形态固化为建筑语言。"
  366. }
  367. },
  368. "default"
  369. ],
  370. "popupExchgList": [{
  371. "type": 5,
  372. "data": {
  373. "title": "兑换地点",
  374. "img": "/static/common/wslgwcs.png",
  375. "point": {
  376. "longitude": 117.022194,
  377. "latitude": 36.661612,
  378. "name": "万盛隆购物超市"
  379. }
  380. }
  381. }
  382. ]
  383. }; */
  384. this.loadConfig(config);
  385. this.matchRsDetailQuery();
  386. setTimeout(this.dealFirstEnter, 500);
  387. },
  388. fail: (err) => {
  389. console.log("getCardConfigQuery err", err)
  390. },
  391. });
  392. },
  393. // 卡片对应活动或赛事详情查询
  394. // getCardDetailQuery() {
  395. // uni.request({
  396. // url: apiCardDetailQuery,
  397. // header: {
  398. // "Content-Type": "application/x-www-form-urlencoded",
  399. // "token": this.token,
  400. // },
  401. // method: "POST",
  402. // data: {
  403. // ecId: this.ecId
  404. // },
  405. // success: (res) => {
  406. // // console.log("getCardDetailQuery", res)
  407. // const data = res.data.data;
  408. // this.mcType = data.mcType;
  409. // this.mcId = data.mcId;
  410. // this.mcName = data.mcName;
  411. // this.beginSecond = data.beginSecond;
  412. // this.endSecond = data.endSecond;
  413. // this.coiName = data.coiName;
  414. // this.teamNum = data.teamNum;
  415. // this.mcState = tools.checkMcState(this.beginSecond, this.endSecond);
  416. // this.getCountdown();
  417. // this.getActtime();
  418. // this.getCardRankDetailQuery();
  419. // this.clear();
  420. // this.interval = setInterval(this.getCountdown, 60000);
  421. // },
  422. // fail: (err) => {
  423. // console.log("getCardDetailQuery err", err)
  424. // },
  425. // });
  426. // },
  427. // 卡片对应线上赛多个活动查询
  428. matchRsDetailQuery() {
  429. uni.request({
  430. url: apiMatchRsDetailQuery,
  431. header: {
  432. "Content-Type": "application/x-www-form-urlencoded",
  433. "token": this.token,
  434. },
  435. method: "POST",
  436. data: {
  437. ecId: this.ecId
  438. },
  439. success: (res) => {
  440. console.log("matchRsDetailQuery", res);
  441. if (checkResCode(res)) {
  442. const data = res.data.data;
  443. this.mcType = data.mcType;
  444. this.mcId = data.mcId;
  445. this.mcName = data.mcName;
  446. this.beginSecond = data.beginSecond;
  447. this.endSecond = data.endSecond;
  448. this.nickName = data.nickName;
  449. this.totalNum = data.totalNum;
  450. this.totalDistanct = data.totalDistanct;
  451. this.totalDistanctRankNum = data.totalDistanctRankNum;
  452. this.totalCp = data.totalCp;
  453. this.totalCpRankNum = data.totalCpRankNum;
  454. this.totalSysPoint = data.totalSysPoint;
  455. this.totalSysPointRankNum = data.totalSysPointRankNum;
  456. this.fastPace = data.fastPace;
  457. this.fastPaceRankNum = data.fastPaceRankNum;
  458. // this.ocaRs = data.ocaRs;
  459. this.mcState = tools.checkMcState(this.beginSecond, this.endSecond);
  460. this.getCountdown();
  461. this.getActtime();
  462. this.getCardRankDetailQuery();
  463. this.clear();
  464. this.interval = setInterval(this.getCountdown, 60000);
  465. }
  466. },
  467. fail: (err) => {
  468. console.log("matchRsDetailQuery err", err)
  469. },
  470. });
  471. },
  472. // 排名查询
  473. getCardRankDetailQuery() {
  474. uni.request({
  475. url: apiCardRankDetailQuery,
  476. header: {
  477. "Content-Type": "application/x-www-form-urlencoded",
  478. "token": this.token,
  479. },
  480. method: "POST",
  481. data: {
  482. mcIdListStr: this.mcId,
  483. mcType: this.mcType,
  484. dispArrStr: this.dispArrStr
  485. },
  486. success: (res) => {
  487. console.log("getCardRankDetailQuery", res);
  488. const rankdata = res.data.data;
  489. this.rankList.totalDistanceRs = rankdata.totalDistanceRs;
  490. this.rankList.totalCpRs = rankdata.totalCpRs;
  491. this.rankList.totalSysPointRs = rankdata.totalSysPointRs;
  492. this.rankList.fastPaceRs = rankdata.fastPaceRs;
  493. },
  494. fail: (err) => {
  495. console.log("getCardRankDetailQuery err", err)
  496. },
  497. });
  498. },
  499. // 卡片用户当前排名查询
  500. // getUserCurrentRankNumQuery() {
  501. // uni.request({
  502. // url: apiUserCurrentRankNumQuery,
  503. // header: {
  504. // "Content-Type": "application/x-www-form-urlencoded",
  505. // "token": this.token,
  506. // },
  507. // method: "POST",
  508. // data: {
  509. // ecId: this.ecId
  510. // },
  511. // success: (res) => {
  512. // // console.log("getUserCurrentRankNumQuery", res)
  513. // if (res.data.code == 0) {
  514. // const data = res.data.data;
  515. // const rankNum = data.rankNum;
  516. // this.dealNotice(rankNum);
  517. // }
  518. // },
  519. // fail: (err) => {
  520. // console.log("getUserCurrentRankNumQuery err", err)
  521. // },
  522. // });
  523. // },
  524. // 是否允许重新分组(报名)
  525. isAllowMcSignUp() {
  526. uni.request({
  527. url: apiIsAllowMcSignUp,
  528. header: {
  529. "Content-Type": "application/x-www-form-urlencoded",
  530. "token": this.token,
  531. },
  532. method: "POST",
  533. data: {
  534. ecId: this.ecId
  535. },
  536. success: (res) => {
  537. // console.log("isAllowMcSignUp", res)
  538. if (res.data.code == 0) {
  539. const data = res.data.data;
  540. this.allowMcSignUp = data.allowSignUp;
  541. }
  542. },
  543. fail: (err) => {
  544. console.log("isAllowMcSignUp err", err)
  545. },
  546. });
  547. },
  548. btnBack() {
  549. // window.history.back();
  550. /* uni.navigateTo({
  551. url: "/pages/bm/style3/rankOverview?" + this.queryString
  552. }); */
  553. const url = `action://to_home/`;
  554. // window.location.href = url;
  555. tools.appAction(url);
  556. },
  557. btnStartGame() {
  558. uni.navigateTo({
  559. url: "/pages/bm/style3/rankOverview?" + this.queryString
  560. });
  561. },
  562. btnInfo() {
  563. // console.log(this.$refs.mypopup);
  564. this.$refs.mypopup.popupOpen();
  565. },
  566. btnMyEgg() {
  567. uni.navigateTo({
  568. url: "/pages/achievement/index2?tabCurrent=2&" + this.queryString
  569. });
  570. },
  571. btnExchg() {
  572. this.$refs.mypopupExchg.popupOpen();
  573. },
  574. onClickTabItem(e) {
  575. if (this.tabCurrent != e.currentIndex) {
  576. this.tabCurrent = e.currentIndex;
  577. }
  578. }
  579. }
  580. }
  581. </script>
  582. <style scoped>
  583. .content {
  584. width: 100vw;
  585. height: 100vh;
  586. }
  587. .top-default {
  588. width: 100%;
  589. height: 170px;
  590. padding-top: 36px;
  591. justify-content: space-between;
  592. background-image: url("/static/backgroud/top_bg2.png");
  593. background-repeat: no-repeat;
  594. background-position: center;
  595. background-size: cover;
  596. }
  597. .topbar {
  598. width: 90%;
  599. justify-content: space-between;
  600. }
  601. .topbar-color-default {
  602. color: #5b9100;
  603. }
  604. .topbar-back { width: 43rpx; height: 43rpx; color: inherit !important; font-size: 48rpx !important; /* opacity: 0; */ }
  605. .topbar-info {
  606. width: 46rpx;
  607. height: 46rpx;
  608. }
  609. .topbar-rule {
  610. font-size: 32rpx;
  611. }
  612. .mcName {
  613. font-size: 40rpx;
  614. font-weight: 550;
  615. }
  616. .topbtm {
  617. width: 100%;
  618. margin-bottom: 5px;
  619. justify-content: space-around;
  620. }
  621. .topbtm-name {
  622. padding: 3px 12px;
  623. background-color: #9fda39;
  624. border-radius: 5px;
  625. text-align: center;
  626. font-weight: 500;
  627. color: #497400;
  628. font-size: 14px;
  629. }
  630. .topbtm-egg {
  631. width: 60px;
  632. padding: 3px 12px;
  633. background-color: #9fda39;
  634. border-radius: 50px;
  635. text-align: center;
  636. color: #497400;
  637. font-size: 14px;
  638. }
  639. .topbtm-null {
  640. width: 60px;
  641. padding: 3px 12px;
  642. }
  643. .cal {
  644. width: 46rpx;
  645. height: 46rpx;
  646. margin-right: 20rpx;
  647. }
  648. .main {
  649. width: 100%;
  650. /* height: 70vh; */
  651. flex-grow: 1;
  652. justify-content: space-around;
  653. /* justify-content: space-between; */
  654. }
  655. .main-bar {
  656. width: 100%;
  657. height: 21px;
  658. background-color: #d8e8c6;
  659. font-size: 10px;
  660. font-weight: 500;
  661. color: #3d6706;
  662. }
  663. .main-tab {
  664. width: 90%;
  665. margin-top: 20rpx;
  666. }
  667. .tab-view {
  668. width: 100%;
  669. /* height: 69vh; */
  670. flex-grow: 1;
  671. }
  672. .btnBack {
  673. width: 70%;
  674. /* height: 6vh; */
  675. height: 80rpx;
  676. /* margin-bottom: 1vh; */
  677. margin-bottom: 20rpx;
  678. /* font-weight: bold; */
  679. color: white;
  680. font-size: 32rpx;
  681. line-height: 80rpx;
  682. border-radius: 27px;
  683. background-color: #81cd00;
  684. }
  685. </style>