index.vue 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827
  1. <template>
  2. <div id="playing_container">
  3. <!-- 计费面板模块-->
  4. <div class="game_panel padding-top-sm">
  5. <van-row gutter="16">
  6. <van-col span="8" offset="2">
  7. <view class="text-sm">
  8. <text class="title">本次游玩时间</text>
  9. </view>
  10. <view class="text-lg padding-top">
  11. <text class="count_down_text">{{ played_time_text }}</text>
  12. </view>
  13. </van-col>
  14. <van-col span="10" offset="4">
  15. <view class="text-sm">
  16. <text class="title">计费模式</text>
  17. <text class="type padding-left-sm">{{ mode_item.name }}</text>
  18. </view>
  19. <button
  20. class="cu-btn bg-red text-white margin-top-sm"
  21. @click="game_finished"
  22. >
  23. <img
  24. src="https://img.shuimuai.com/m_duankainaohuan.png"
  25. class="cut_brain_icon"
  26. alt=""
  27. />
  28. <text class="padding-lr cut_text text-sm">结束游戏</text>
  29. </button>
  30. </van-col>
  31. </van-row>
  32. </div>
  33. <!-- 设备状态-->
  34. <div class="game_status padding-tb">
  35. <van-row>
  36. <van-col span="10" offset="2">
  37. <div
  38. class="flex flex-direction align-center justify-center"
  39. v-if="device_bg"
  40. >
  41. <img
  42. src="https://img.shuimuai.com/web/touhuanzhuangtai_2.png"
  43. alt=""
  44. class="device_img"
  45. />
  46. <text class="text-default">已经正确佩戴</text>
  47. </div>
  48. <div class="flex flex-direction align-center justify-center" v-else>
  49. <img
  50. src="https://img.shuimuai.com/web/touhuanzhuangtai_3.png"
  51. alt=""
  52. class="device_img"
  53. />
  54. <text class="text-default">未正确佩戴</text>
  55. </div>
  56. </van-col>
  57. <van-col span="10">
  58. <div class="flex flex-direction align-center justify-center">
  59. <view class="elc_power_container">
  60. <img
  61. src="https://img.shuimuai.com/web/dianchi_3.png"
  62. alt=""
  63. :style="{ width: device_power + '%' }"
  64. class="device_elc"
  65. />
  66. </view>
  67. <text class="text-default">{{ device_power }}%</text>
  68. <text class="text-default">设备电量</text>
  69. </div>
  70. </van-col>
  71. <!-- <van-col span="2">
  72. <div class="flex flex-direction align-center justify-center">
  73. <view>
  74. <text>-{{ rssi }}dbm</text>
  75. </view>
  76. <view>
  77. <text class="text-default">信号强度</text>
  78. </view>
  79. </div>
  80. </van-col> -->
  81. </van-row>
  82. </div>
  83. <!-- 图标模块-->
  84. <div class="ec_container">
  85. <view class="chart_view_first margin-tb-xl">
  86. <view class="bar">
  87. <view>
  88. <view class="line"></view>
  89. <view class="title">大脑状态</view>
  90. </view>
  91. <view class="label">
  92. <view>
  93. <view class="dot dot-orange"></view>
  94. <view class="name">Att(专注度)</view>
  95. </view>
  96. <view>
  97. <view class="dot dot-pink"></view>
  98. <view class="name">Med(放松度)</view>
  99. </view>
  100. </view>
  101. </view>
  102. <view class="chart">
  103. <mpvue-echarts
  104. :echarts="echarts"
  105. :onInit="attCharts"
  106. canvasId="canvasId-demo1"
  107. />
  108. </view>
  109. </view>
  110. <view class="chart_view_second margin-tb-xl">
  111. <view class="bar">
  112. <view>
  113. <view class="line"></view>
  114. <view class="title">基本脑波</view>
  115. </view>
  116. <view class="label">
  117. <view>
  118. <view class="dot dot-blue"></view>
  119. <view class="name">Delta</view>
  120. </view>
  121. <view>
  122. <view class="dot dot-green"></view>
  123. <view class="name">Theta</view>
  124. </view>
  125. <view>
  126. <view class="dot dot-yellow"></view>
  127. <view class="name">Beta</view>
  128. </view>
  129. <view>
  130. <view class="dot dot-orange-yellow"></view>
  131. <view class="name">Alpha</view>
  132. </view>
  133. </view>
  134. </view>
  135. <view class="chart">
  136. <mpvue-echarts
  137. :echarts="echarts"
  138. :onInit="medCharts"
  139. canvasId="canvasId-demo2"
  140. />
  141. </view>
  142. </view>
  143. </div>
  144. <van-dialog id="van-dialog" />
  145. <van-toast id="van-toast" />
  146. <van-notify id="van-notify" />
  147. </div>
  148. </template>
  149. <script>
  150. import util, { formatSeconds } from "../../utils/index";
  151. import bluetooth from "../../utils/bluetooth";
  152. import game_store from "@/store/game";
  153. import Toast from "../../../static/vant/toast/toast";
  154. import Dialog from "../../../static/vant/dialog/dialog";
  155. import Notify from "../../../static/vant/notify/notify";
  156. import { gameAddLine, gameEnd } from "../../requests/game";
  157. import mpvueEcharts from "mpvue-echarts";
  158. import echarts from "../../../static/echarts.min";
  159. var att_charts, med_charts, $this;
  160. // 大脑图表初始化
  161. function initAttChart(canvas, width, height) {
  162. att_charts = echarts.init(canvas, null, {
  163. width: width,
  164. height: height,
  165. });
  166. canvas.setChart(att_charts);
  167. let option = {}; // ECharts 配置项
  168. att_charts.setOption(option);
  169. return att_charts; // 返回 chart 后可以自动绑定触摸操作
  170. }
  171. // 我的设备图表初始化
  172. function initMedChart(canvas, width, height) {
  173. med_charts = echarts.init(canvas, null, {
  174. width: width,
  175. height: height,
  176. });
  177. canvas.setChart(med_charts);
  178. let option = {}; // ECharts 配置项
  179. med_charts.setOption(option);
  180. return med_charts; // 返回 chart 后可以自动绑定触摸操作
  181. }
  182. export default {
  183. name: "index_container",
  184. components: {
  185. mpvueEcharts,
  186. },
  187. data() {
  188. return {
  189. // 折线图
  190. echarts,
  191. attCharts: initAttChart,
  192. medCharts: initMedChart,
  193. // 使用类型 1次数 2时间 0未选择
  194. mode: 0,
  195. timeData: {},
  196. mode_item: {},
  197. device_power: 100,
  198. user_info: {},
  199. //设备值
  200. _deviceId: "",
  201. _serviceId: "",
  202. _characteristicId: "",
  203. toy_index: 0,
  204. toy_id: 0,
  205. toy: {},
  206. toy_hex: "",
  207. play_time: 0,
  208. //图标数据集合
  209. att_list: [],
  210. med_list: [],
  211. delta_list: [],
  212. alpha_list: [],
  213. beta_list: [],
  214. theta_list: [],
  215. //临时数据集合
  216. attList: [],
  217. medList: [],
  218. //判断是否结束游戏
  219. is_end: false,
  220. // 消耗的时间
  221. played_time: null,
  222. played_time_text: "--:--",
  223. //结束游戏时选择类型的时间
  224. over_play_time: 0,
  225. // 检测佩戴是否正确
  226. device_bg: true,
  227. // 蓝牙信号强度
  228. rssi: 0,
  229. game_status: 0,
  230. };
  231. },
  232. methods: {
  233. //游戏结束方法
  234. game_finished() {
  235. bluetooth.sendEnd(
  236. $this._deviceId,
  237. $this._serviceId,
  238. $this._characteristicId
  239. );
  240. $this.$emit("closePop", true);
  241. //取消监听低功耗蓝牙设备
  242. wx.offBLECharacteristicValueChange();
  243. //设置游戏状态为 停止游戏
  244. game_store.getters.getGameStatus() == 0
  245. ? game_store.setters.setGameStatus(0)
  246. : game_store.setters.setGameStatus(3);
  247. //游戏结束重置游戏时间
  248. wx.removeStorageSync("play_time");
  249. //删除游戏专注数据
  250. game_store.remover.rmGameAttMedDatas();
  251. //删除隐藏时间
  252. game_store.remover.rmHideTime();
  253. //游戏结束重置游戏模式
  254. // game_store.setters.setMode(0);
  255. //删除游戏得id
  256. game_store.setters.removeToyHex();
  257. // 结束游戏在提交报告函数里
  258. $this.post_data();
  259. Toast.loading({
  260. forbidClick: true,
  261. mask: true,
  262. message: "正在生成报告...",
  263. duration: 0,
  264. onClose() {
  265. for (var i = 0; i < 2; i++) {
  266. bluetooth.shutdownSendControl(
  267. $this._deviceId,
  268. $this._serviceId,
  269. $this._characteristicId
  270. );
  271. bluetooth.sendEnd(
  272. $this._deviceId,
  273. $this._serviceId,
  274. $this._characteristicId
  275. );
  276. }
  277. },
  278. });
  279. },
  280. to_report() {
  281. mpvue.redirectTo({
  282. url: "/pages/report/main",
  283. success() {
  284. $this.timeData = {};
  285. $this.attList = [];
  286. $this.medList = [];
  287. },
  288. });
  289. },
  290. // 开始游戏
  291. start_game() {
  292. wx.setKeepScreenOn({
  293. keepScreenOn: true,
  294. });
  295. //打开内存警告
  296. // wx.onMemoryWarning(() => {
  297. // console.log('内存告急警告')
  298. // game_store.setGameAttMedDatas({
  299. // att: $this.attList,
  300. // med: $this.medList
  301. // })
  302. // })
  303. // //初始化数据
  304. // $this.played_time = null
  305. // //设置未结束游戏
  306. // $this.is_end = false
  307. // $this.att_list = []
  308. // $this.med_list = []
  309. // $this.delta_list = []
  310. // $this.alpha_list = []
  311. // $this.theta_list = []
  312. // $this.beta_list = []
  313. bluetooth.watchingDevice($this);
  314. bluetooth.sendControl(
  315. $this._deviceId,
  316. $this._serviceId,
  317. $this._characteristicId
  318. );
  319. },
  320. // ArrayBuffer转16进度字符串示例
  321. ab2hex(buffer) {
  322. var hexArr = Array.prototype.map.call(
  323. new Uint8Array(buffer),
  324. function (bit) {
  325. return ("00" + bit.toString(16)).slice(-2);
  326. }
  327. );
  328. return hexArr.join("");
  329. },
  330. // 往后端推送一次定时数据
  331. post_data() {
  332. //判断数据长度大于理想状态 需要对数组进行切割 逐个提交数据
  333. let $len = 300;
  334. console.log($this.attList.length, "结束游戏提交的数据量");
  335. if ($this.attList.length > $len) {
  336. let $count = Math.ceil($this.attList.length / $len);
  337. let index = 0;
  338. let inter = setInterval(() => {
  339. if (index < $count) {
  340. let $params = {
  341. game_record_id: game_store.getters.getGameRecordId(),
  342. //数据段长度大于65 多个提交
  343. line: $this.attList.slice(index * $len, (index + 1) * $len),
  344. line_med: $this.medList.slice(index * $len, (index + 1) * $len),
  345. };
  346. gameAddLine($params).then((res) => {
  347. let $data = res.data;
  348. if ($data.code == 0) {
  349. console.log("ok", $params["line"]);
  350. }
  351. });
  352. }
  353. index++;
  354. if (index == $count) {
  355. clearInterval(inter);
  356. $this.game_over();
  357. $this.to_report();
  358. }
  359. }, 200);
  360. return $count * 500;
  361. } else {
  362. let $params = {
  363. game_record_id: game_store.getters.getGameRecordId(),
  364. //数据段长度小于65 单个提交
  365. line: $this.attList,
  366. line_med: $this.medList,
  367. };
  368. if (!$params.line) {
  369. return false;
  370. }
  371. gameAddLine($params).then((res) => {
  372. let $data = res.data;
  373. if ($data.code == 0) {
  374. $this.attList = [];
  375. $this.medList = [];
  376. }
  377. setTimeout(() => {
  378. $this.game_over();
  379. $this.to_report();
  380. }, 800);
  381. });
  382. return 800;
  383. }
  384. },
  385. // 结束游戏
  386. game_over() {
  387. $this.over_play_time = game_store.getters.getOverPlayTime();
  388. $this.played_time = $this.played_time >= 0 ? $this.played_time : 0;
  389. console.log(
  390. "结束游戏时游玩的时间倒计时~~played_time~~",
  391. $this.played_time,
  392. "~~play_time~~",
  393. $this.play_time,
  394. // "所选类型的时间",
  395. "~~$this.over_play_time~~",
  396. $this.over_play_time
  397. );
  398. let $params = {
  399. game_record_id: game_store.getters.getGameRecordId(),
  400. type: $this.mode,
  401. // play_time: $this.play_time - Math.abs($this.played_time),
  402. play_time: $this.over_play_time - $this.played_time,
  403. };
  404. //
  405. gameEnd($params).then((res) => {
  406. let $data = res.data;
  407. $this.played_time = null;
  408. //设置未结束游戏
  409. $this.is_end = false;
  410. $this.att_list = [];
  411. $this.med_list = [];
  412. $this.delta_list = [];
  413. $this.alpha_list = [];
  414. $this.theta_list = [];
  415. $this.beta_list = [];
  416. //游戏结束重置游戏卡卷类型时间和卡卷类型
  417. wx.removeStorageSync("over_play_time");
  418. game_store.setters.setMode(0);
  419. });
  420. },
  421. // 处理游戏中数据的方法
  422. do_datas: function ($data) {
  423. $this.att_list.push($data["att"]);
  424. $this.med_list.push($data["med"]);
  425. $this.delta_list.push(Math.round($data["delta"] / 10000));
  426. $this.alpha_list.push(Math.round($data["alpha"] / 1000000));
  427. $this.theta_list.push(Math.round($data["theta"] / 10000));
  428. $this.beta_list.push(Math.round($data["beta"]) / 1000000);
  429. if ($this.att_list.length > 50) {
  430. $this.att_list.shift();
  431. $this.med_list.shift();
  432. $this.delta_list.shift();
  433. $this.alpha_list.shift();
  434. $this.theta_list.shift();
  435. $this.beta_list.shift();
  436. }
  437. $this.attList.push($data["att"]);
  438. $this.medList.push($data["med"]);
  439. game_store.setters.setGameAttMedDatas({
  440. attList: $this.attList,
  441. medList: $this.medList,
  442. });
  443. //判断是否隐藏 隐藏则不绘画
  444. let $hide_status = game_store.getters.getHideStatus();
  445. if (!$hide_status) {
  446. //通过专注放松度 画图
  447. let $option = util.getLineOption($this.att_list, $this.med_list);
  448. att_charts.setOption($option);
  449. //通过基本脑波发送数据
  450. let $base_option = util.getBaseOption(
  451. $this.delta_list,
  452. $this.theta_list,
  453. $this.alpha_list,
  454. $this.beta_list
  455. );
  456. med_charts.setOption($base_option);
  457. }
  458. },
  459. //计算游玩时间
  460. calThePlayedTime() {
  461. //筛选模式
  462. $this.mode = game_store.getters.getMode();
  463. console.log("计费模式里面有什么数据~~~", game_store.getters.getMode());
  464. let mode_list = [
  465. {
  466. id: 1,
  467. name: "次卡(10分钟)",
  468. },
  469. {
  470. id: 2,
  471. name: "会员时间消费",
  472. },
  473. ];
  474. //可玩时间 (剩余时长)
  475. $this.play_time = game_store.getters.getPlayTime();
  476. //已经玩了多长时间
  477. $this.played_time = game_store.getters.getPlayedTime()
  478. ? game_store.getters.getPlayedTime()
  479. : game_store.getters.getPlayTime();
  480. $this.mode_item = {};
  481. $this.mode_item = mode_list[$this.mode - 1];
  482. },
  483. },
  484. mounted() {
  485. $this._deviceId = game_store.getters.getDeviceId();
  486. $this._serviceId = game_store.getters.getServiceId();
  487. $this._characteristicId = game_store.getters.getCharacterId();
  488. // setTimeout(() => {
  489. $this.game_status = game_store.getters.getGameStatus();
  490. // }, 1000)
  491. //判断是否结束游戏
  492. if ($this.is_end == true) {
  493. $this.game_finished();
  494. } else {
  495. $this.calThePlayedTime();
  496. $this.start_game();
  497. //打开蓝牙监听
  498. bluetooth.watch_bluetooth_status($this);
  499. }
  500. // Notify({
  501. // type: 'danger',
  502. // message: '智脑环已断开连接,请重新扫码智脑环',
  503. // duration: 0,
  504. // });
  505. },
  506. created() {
  507. $this = this;
  508. },
  509. // 加载完成后、后台切到前台或重新进入页面时触发
  510. onShow() {
  511. // 判断可游玩时间是否小于 0
  512. game_store.setters.setHideStatus(false);
  513. if ($this.played_time == 0) {
  514. $this.game_finished();
  515. } else {
  516. wx.getSystemInfoAsync({
  517. success(res) {
  518. if (res.platform != "android") {
  519. //获取 拉到后台得时间
  520. let $hide_time = game_store.getters.getHideTime();
  521. if ($hide_time) {
  522. //获取当前时间
  523. let $now = Math.round(new Date() / 1000);
  524. //获得后台到当前时间差
  525. let $residue = $now - $hide_time;
  526. //将原来的游玩时间+上 时间差
  527. let $played_time = $this.played_time * 1 - $residue * 1;
  528. //判断时间差
  529. if ($residue > $this.played_time) {
  530. console.log(
  531. "后台退出时间大于游玩剩余的时间~~",
  532. "后台返回前台的时间差",
  533. $residue,
  534. "游玩的剩余时间played_time~~",
  535. $this.played_time,
  536. "所选类型的时间 $this.play_time~~",
  537. $this.play_time
  538. );
  539. $this.game_finished();
  540. }
  541. //重新设置游玩时间
  542. game_store.setters.setPlayedTime($played_time);
  543. $this.calThePlayedTime();
  544. console.log(
  545. "一进游戏页面我能触发嘛,且我得到的数据为:",
  546. "当前时间",
  547. $now,
  548. "拉到后台时间",
  549. $hide_time,
  550. ""
  551. );
  552. }
  553. }
  554. },
  555. });
  556. }
  557. },
  558. onLoad(options) {
  559. if (options.end == 1) {
  560. $this.is_end = true;
  561. }
  562. },
  563. // 页面从前台切换到后台或者去别的页面时候触发的
  564. onHide() {
  565. game_store.setters.setHideStatus(true);
  566. game_store.setters.setHideTime(Math.round(new Date() / 1000));
  567. },
  568. // 页面卸载时候触发的生命周期
  569. onUnload() {
  570. console.log("小程序被销毁");
  571. if (!$this.is_end) {
  572. //停止传输数据
  573. bluetooth.sendEnd(
  574. $this._deviceId,
  575. $this._serviceId,
  576. $this._characteristicId
  577. );
  578. wx.offBLECharacteristicValueChange();
  579. //存储时间
  580. game_store.setters.setPlayedTime($this.played_time);
  581. //设置未结束游戏
  582. $this.is_end = false;
  583. }
  584. },
  585. };
  586. </script>
  587. <style scoped>
  588. #playing_container {
  589. width: 100%;
  590. background: linear-gradient(
  591. 0deg,
  592. rgba(40, 157, 206, 0.51),
  593. rgba(135, 145, 226, 0.26)
  594. );
  595. background-color: #46425e;
  596. padding: 5px;
  597. height: 750px;
  598. }
  599. .game_panel {
  600. width: 100%;
  601. height: 76px;
  602. background: #46425e;
  603. box-shadow: 0px 3px 4px 0px #302d43;
  604. border-radius: 11px;
  605. margin: 0px auto;
  606. }
  607. .game_panel .title {
  608. color: #9a96b7;
  609. }
  610. .game_panel .type {
  611. color: #ffffff;
  612. }
  613. .cut_brain_icon {
  614. width: 11px;
  615. height: 11px;
  616. }
  617. .device_img {
  618. width: 36px;
  619. height: 36px;
  620. }
  621. .text-default {
  622. color: #9a95b7;
  623. font-size: 10px;
  624. }
  625. /*电量显示*/
  626. .elc_power_container {
  627. width: 28px;
  628. border: #9a95b7 3px solid;
  629. border-radius: 5px;
  630. height: 22px;
  631. }
  632. .device_elc {
  633. height: 18px;
  634. }
  635. /* 节标题 */
  636. .bar {
  637. width: 100%;
  638. height: 15px;
  639. display: flex;
  640. align-items: center;
  641. justify-content: space-between;
  642. padding: 0 7px;
  643. box-sizing: border-box;
  644. margin: 11px 0;
  645. }
  646. .bar view {
  647. display: flex;
  648. align-items: center;
  649. justify-content: start;
  650. }
  651. .bar .line {
  652. width: 4px;
  653. height: 15px;
  654. background-color: #ffb400;
  655. margin-right: 7px;
  656. }
  657. .bar .title {
  658. color: #fff;
  659. font-size: 15px;
  660. }
  661. .label {
  662. color: #9a95b7;
  663. font-size: 10px;
  664. }
  665. /*点图*/
  666. .dot {
  667. width: 8px;
  668. height: 8px;
  669. border-radius: 50%;
  670. margin-right: 4px;
  671. margin-left: 15px;
  672. }
  673. .dot-orange {
  674. background: #ffb400;
  675. }
  676. .dot-pink {
  677. background: #d4327a;
  678. }
  679. .dot-blue {
  680. background: #00ccff;
  681. }
  682. .dot-green {
  683. background: #0cda2e;
  684. }
  685. .dot-yellow {
  686. background: #d1d310;
  687. }
  688. .dot-orange-yellow {
  689. background: #f8a117;
  690. }
  691. /* 图表 */
  692. #mychart-dom-multi-line {
  693. width: 100%;
  694. height: 175px;
  695. }
  696. #mychart-dom-multi-line-med {
  697. width: 100%;
  698. height: 100px;
  699. }
  700. /*弹窗模块*/
  701. .err_container {
  702. width: 260px;
  703. height: 300px;
  704. border-radius: 5px;
  705. }
  706. /*标题*/
  707. .err_container .title {
  708. font-size: 20px;
  709. font-weight: bold;
  710. color: #4c4c4c;
  711. line-height: 24px;
  712. }
  713. /*子标题*/
  714. .err_container .sub-title {
  715. font-size: 12px;
  716. font-family: Microsoft YaHei;
  717. font-weight: 400;
  718. color: #4b4b4b;
  719. line-height: 24px;
  720. }
  721. .err_img {
  722. width: 73px;
  723. height: 83px;
  724. }
  725. .chart_view_first {
  726. position: relative;
  727. bottom: 10px;
  728. }
  729. .chart_view_second {
  730. position: relative;
  731. bottom: 5px;
  732. }
  733. /*倒计时样式*/
  734. .count_down_text {
  735. font-size: 35px;
  736. font-family: PingFang SC;
  737. font-weight: 400;
  738. color: #fff;
  739. line-height: 28px;
  740. }
  741. .chart {
  742. width: 360px;
  743. height: 193px;
  744. background: #302d43;
  745. opacity: 0.6;
  746. border-radius: 10px;
  747. }
  748. /* 提高dialog提示的层级 */
  749. #van-dialog {
  750. z-index: 10000001 !important;
  751. }
  752. </style>