alarModel.vue 26 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767
  1. <template>
  2. <!-- 告警弹窗 -->
  3. <view style="z-index: 999">
  4. <view class="mask" v-if="alarmModel"></view>
  5. <view class="alarm-modal" v-if="alarmModel">
  6. <view class="alarm">
  7. <!-- <image src="../../images/alram.png" mode="" /> -->
  8. <image src="../../static/alarm.png"></image>
  9. </view>
  10. <view class="alarm-header">
  11. <image src="../../static/alarm_event.png" mode="" />
  12. </view>
  13. <view class="nowTime">
  14. {{ nowTime }}
  15. </view>
  16. <view class="alarm-info">
  17. <text style="color: #ff6d6d">{{ devName }}</text>
  18. 检测到可能发生跌倒事件,请立即处理!
  19. </view>
  20. <view class="backImg">
  21. <image src="../../static/actionRed.png" mode="" />
  22. </view>
  23. <view class="alarm-bottom">
  24. <template v-if="voipFlag">
  25. <view
  26. class="alarm-voice"
  27. v-if="authorizeFlag"
  28. @click="gotoCallPage"
  29. >
  30. 语音确认
  31. </view>
  32. <view class="alarm-voice" v-else @click="authorizeIot">
  33. 语音确认
  34. </view>
  35. </template>
  36. <view class="alarm-handle" @click="handleAlarm()">
  37. 已知晓
  38. </view>
  39. </view>
  40. </view>
  41. </view>
  42. </template>
  43. <script>
  44. import config from "../../data/config.js";
  45. import mqtt from "../../utils/mqtt";
  46. import {
  47. getSnTicket,
  48. authorize,
  49. getDeviceVoIPList,
  50. getContactList,
  51. getUser,
  52. } from "../../api/index.js";
  53. import {
  54. CameraStatus,
  55. AuthorizeStatus,
  56. CallPagePlugin,
  57. isWmpf,
  58. } from "../../const.js";
  59. import { AsyncValue } from "../../utils";
  60. import { onShow } from "@dcloudio/uni-app";
  61. const wmpfVoip = requirePlugin("wmpf-voip").default;
  62. const envVersion = wx.getAccountInfoSync().miniProgram.envVersion;
  63. const apiTypes = ["校园模式", "硬件模式", "呼叫安卓", "校园+硬件模式"];
  64. const apiTypesWMPF = [1, 0, 3];
  65. const apiTypesWechat = [2];
  66. const getEnvVersionForVoip = (function () {
  67. const _map = {
  68. develop: "developer",
  69. trial: "trial",
  70. release: "formal",
  71. };
  72. return () => {
  73. return _map[envVersion];
  74. };
  75. })();
  76. export default {
  77. comments: {
  78. name: "alarModel",
  79. },
  80. props: {
  81. clientIdProp: {
  82. default: null,
  83. },
  84. },
  85. data() {
  86. return {
  87. alarmModel: false,
  88. eventListId: "",
  89. nowTime: "",
  90. devName: "",
  91. authorizeFlag: true,
  92. clientId: "",
  93. mqttClientTwo: "",
  94. // voip相关
  95. isWmpf: isWmpf,
  96. name: "用户",
  97. voipDevices: [],
  98. sn: "",
  99. isShowPopUp: false,
  100. contactList: [],
  101. isWmpf,
  102. envVersion,
  103. apiTypesValid: (isWmpf ? apiTypesWMPF : apiTypesWechat).map(
  104. (id) => apiTypes[id]
  105. ),
  106. apiTypeIndex: 0,
  107. currentIndex: 0,
  108. voipFlag: "",
  109. mqttClientFlag: false,
  110. inactivityTimer: "",
  111. };
  112. },
  113. computed: {},
  114. methods: {
  115. authorizeIot() {
  116. this.hanledList("Voice");
  117. this.sn = this.clientId;
  118. this.alarmModel = false;
  119. // const { name, sn, voipDevices } = this;
  120. const name = this.name;
  121. const sn = this.clientId;
  122. const voipDevices = this.voipDevices;
  123. if (!name || name.length === 0 || !sn || sn.length === 0) {
  124. wx.showToast({
  125. title: "请输入授权人名称和设备clientId",
  126. icon: "none",
  127. });
  128. return;
  129. }
  130. const { modelId } = config;
  131. console.log(sn, modelId, 77777);
  132. const { snTicket } = getSnTicket({
  133. sn,
  134. modelId,
  135. });
  136. console.log(snTicket, sn, 99999999);
  137. var that = this;
  138. wx.requestDeviceVoIP({
  139. sn,
  140. snTicket,
  141. modelId,
  142. deviceName: sn,
  143. async success(res) {
  144. console.log(`requestDeviceVoIP`, res);
  145. await authorize({
  146. sn,
  147. name,
  148. });
  149. wx.showToast({
  150. title: "授权成功",
  151. icon: "none",
  152. });
  153. const key = `voipDevices[${voipDevices.length}]`;
  154. // that.setData({
  155. // [key]: {
  156. // sn,
  157. // modelId,
  158. // status: 1,
  159. // },
  160. // });
  161. that.voipDevices[voipDevices.length] = {
  162. sn,
  163. modelId,
  164. status: 1,
  165. };
  166. that.sn = sn;
  167. that.modelId = modelId;
  168. that.status = 1;
  169. that.gotoCallPage();
  170. },
  171. fail(err) {
  172. console.error(`requestDeviceVoIP failOne`, err);
  173. wx.showToast({
  174. title: "授权失败, 请前往设置页开启",
  175. icon: "none",
  176. });
  177. },
  178. });
  179. },
  180. handleAlarm() {
  181. this.hanledList("noVoice");
  182. this.alarmModel = false;
  183. },
  184. // voip相关方法
  185. async getVoipDevices() {
  186. const { list } = await getDeviceVoIPList();
  187. console.log("getDeviceVoIPList:", list);
  188. if (list && list.length > 0) {
  189. const authorizeFlag = list.some(
  190. (item) => item.sn === this.clientId
  191. );
  192. console.log("authorizeFlag:", list, authorizeFlag);
  193. this.authorizeFlag = authorizeFlag;
  194. }
  195. if (!list || list.length === 0) {
  196. this.authorizeFlag = false;
  197. }
  198. if (typeof list === "object") {
  199. this.voipDevices = list;
  200. }
  201. },
  202. async authorizeIot() {
  203. this.sn = this.clientId;
  204. // this.alarmModel = false;
  205. const name = this.name;
  206. const sn = this.sn;
  207. const voipDevices = this.voipDevices;
  208. console.log(name, sn, voipDevices, 9999999999999);
  209. // const { name, sn, voipDevices } = this;
  210. if (!name || name.length === 0 || !sn || sn.length === 0) {
  211. wx.showToast({
  212. title: "请输入授权人名称和设备dev_id",
  213. icon: "none",
  214. });
  215. return;
  216. }
  217. const { modelId } = config;
  218. console.log(sn, modelId, 77777);
  219. const { snTicket } = await getSnTicket({
  220. sn,
  221. modelId,
  222. });
  223. console.log(snTicket, sn, 99999999);
  224. var that = this;
  225. wx.requestDeviceVoIP({
  226. sn,
  227. snTicket,
  228. modelId,
  229. deviceName: sn,
  230. async success(res) {
  231. console.log(`requestDeviceVoIP`, res);
  232. await authorize({
  233. sn,
  234. name,
  235. });
  236. wx.showToast({
  237. title: "授权成功",
  238. icon: "none",
  239. });
  240. const key = `voipDevices[${voipDevices.length}]`;
  241. // that.key = {
  242. // sn,
  243. // modelId,
  244. // status: 1,
  245. // };
  246. that.voipDevices[voipDevices.length] = {
  247. sn,
  248. modelId,
  249. status: 1,
  250. };
  251. that.gotoCallPage();
  252. },
  253. fail(err) {
  254. console.error(`requestDeviceVoIP failTwo`, err);
  255. wx.showToast({
  256. title: "授权失败, 请前往设置页开启",
  257. icon: "none",
  258. });
  259. },
  260. });
  261. },
  262. async gotoCallPage() {
  263. this.hanledList("Voice");
  264. wx.showToast({
  265. title: "通话加载中...",
  266. icon: "loading",
  267. duration: 2000, //持续的时间
  268. });
  269. // this.alarmModel = false;
  270. this._caller = new AsyncValue();
  271. let options = {
  272. sn: this.sn,
  273. };
  274. await this.getSelf(options);
  275. await this.getContactList();
  276. let voiceCan = {
  277. sn: this.sn,
  278. idx: 1,
  279. type: "voice",
  280. };
  281. await this.call(voiceCan);
  282. },
  283. async getSelf(options = {}) {
  284. if (!this._caller.isPending()) {
  285. return;
  286. }
  287. if (isWmpf) {
  288. const { sn } = options;
  289. if (sn) {
  290. config.sn = sn;
  291. this.sn = sn;
  292. }
  293. this._caller.set({
  294. id: config.sn,
  295. name: config.sn,
  296. });
  297. } else {
  298. try {
  299. const resp = await getUser();
  300. console.log(`getUser`, resp);
  301. this._caller.set({
  302. id: resp.openid,
  303. name: resp.name,
  304. });
  305. } catch (error) {
  306. console.error(`getself error`, error);
  307. }
  308. }
  309. },
  310. async getContactList() {
  311. wx.showLoading();
  312. try {
  313. let contactList = [];
  314. const raw_contactList = await getContactList({
  315. sn: isWmpf ? config.sn : null,
  316. });
  317. console.log(`raw_contactList`, raw_contactList);
  318. if (!isWmpf) {
  319. // 微信呼叫设备
  320. const { list } = await getDeviceVoIPList();
  321. contactList = raw_contactList.map(({ sn, pushToken }) => {
  322. let canCall = true;
  323. if (typeof list === "object") {
  324. const canCallList = list
  325. .filter(
  326. (item) =>
  327. item.status === AuthorizeStatus.ACCEPT
  328. )
  329. .map((item) => item.sn);
  330. canCall = canCallList.includes(sn);
  331. }
  332. return {
  333. id: sn,
  334. name: sn,
  335. canCall,
  336. ticket: pushToken,
  337. };
  338. });
  339. } else {
  340. // 设备呼叫微信
  341. const raw_contactList = await getContactList({
  342. sn: config.sn,
  343. });
  344. console.log(`raw_contactList: 业务方存储`, raw_contactList);
  345. if (raw_contactList.length > 0) {
  346. const canCallList = (
  347. await wmpfVoip.getIotBindContactList({
  348. sn: config.sn,
  349. model_id: config.modelId,
  350. openid_list: raw_contactList.map(
  351. (item) => item.openid
  352. ),
  353. })
  354. ).contact_list
  355. .filter(
  356. (item) => item.status === AuthorizeStatus.ACCEPT
  357. )
  358. .map((item) => item.openid);
  359. console.log(`canCallList: 微信授权存储`, canCallList);
  360. contactList = raw_contactList.map((item) => {
  361. const canCall = canCallList.includes(item.openid);
  362. return {
  363. id: item.openid,
  364. name: item.name,
  365. canCall,
  366. ticket: "",
  367. };
  368. });
  369. }
  370. }
  371. console.log(`getContactList: `, contactList);
  372. this.contactList = contactList;
  373. } catch (error) {
  374. console.error(`getContactList error: `, error);
  375. }
  376. wx.hideLoading();
  377. },
  378. async call(e) {
  379. console.log(`call`, "走到了call方法");
  380. const { sn, idx, type: roomtype } = e;
  381. // console.log(e, this.contactList, 888870);
  382. const target = this.contactList.find((item) => item.id === sn);
  383. console.log("走到了这里了。。。。1", target);
  384. // const target = this.contactList[idx];
  385. const apiTypeName = this.apiTypesValid[this.apiTypeIndex];
  386. const businessType = apiTypes.indexOf(apiTypeName);
  387. try {
  388. if (!target.canCall) {
  389. wx.showToast({
  390. title: "用户未授权或设备不在线",
  391. icon: "none",
  392. });
  393. throw Error("target can not call");
  394. }
  395. console.log("走到了这里了。。。。2");
  396. const _caller = await this._caller.get();
  397. console.log(`caller: `, _caller);
  398. console.log(`listener: `, target);
  399. const { roomId } = await wmpfVoip.callDevice({
  400. roomType: "voice",
  401. sn: sn,
  402. modelId: "iFJ2BNIQcd9WlUIaT7_l4Q",
  403. nickName: "xx",
  404. isCloud: true,
  405. payload: "radar-power.cn",
  406. });
  407. wx.redirectTo({
  408. url: CallPagePlugin,
  409. });
  410. } catch (error) {
  411. console.log(`>>>>>>>>>>>>>>>>>>>>>>>>>>>`);
  412. console.error(`call error`, error);
  413. }
  414. },
  415. // mqtt相关方法
  416. connectMQTTwo() {
  417. if (this.mqttClientFlag) {
  418. console.log("主题已订阅");
  419. return;
  420. }
  421. const THRESHOLD = 2;
  422. const params = {
  423. keepalive: 6000,
  424. clean: true,
  425. connectTimeout: 30 * 1000,
  426. clientId:
  427. "xcx_mqtt_cmd1" +
  428. uni.getStorageSync("userId") +
  429. Math.random().toString(16).substring(2, 8),
  430. username: "lnradar",
  431. password: "lnradar",
  432. // 微信小程序特定配置
  433. wsOptions: {
  434. WebSocket: function (url) {
  435. return wx.connectSocket({
  436. url: url,
  437. header: {
  438. "content-type": "application/json",
  439. },
  440. protocols: ["mqtt"],
  441. });
  442. },
  443. },
  444. reconnectPeriod: 0,
  445. rejectUnauthorized: false, // 仅开发环境使用,生产环境应设为true或移除
  446. };
  447. let client = "";
  448. let selectedService = uni.getStorageSync("sercviceChoice");
  449. if (!selectedService || selectedService == "aloneServe") {
  450. if (__wxConfig.envVersion == "develop") {
  451. client = mqtt.connect(
  452. "wxs://cmd.radar-power.cn/mqtt/",
  453. params
  454. );
  455. }
  456. if (__wxConfig.envVersion == "trial") {
  457. client = mqtt.connect(
  458. "wxs://cmd.radar-power.cn/mqtt/",
  459. params
  460. );
  461. }
  462. }
  463. // 存储client引用以便后续操作
  464. this.mqttClientTwo = client;
  465. client.on("connect", () => {
  466. console.log("MQTT连接成功");
  467. this.mqttClientFlag = true;
  468. let userId = uni.getStorageSync("userId");
  469. client.subscribe(`/mps/wx_${userId}/notice`, (err) => {
  470. if (err) {
  471. console.error("订阅失败", err);
  472. } else {
  473. console.log(
  474. `成功订阅设备主题: /mps/wx_${userId}/notice`
  475. );
  476. }
  477. });
  478. });
  479. client.on("disconnect", () => {
  480. console.log("MQTT不在连接");
  481. });
  482. client.on("error", (err) => {
  483. this.mqttClientFlag = false;
  484. setTimeout(() => {
  485. this.connectMQTTwo();
  486. }, 1000);
  487. });
  488. client.on("reconnect", () => {});
  489. client.on("close", () => {});
  490. client.on("message", (topic, message) => {
  491. console.log(JSON.parse(message.toString()), "8870");
  492. // 处理点位消息
  493. let userId = uni.getStorageSync("userId");
  494. console.log("topic777777", userId);
  495. const noticeMatch = /^\/mps\/wx_(.+)\/notice$/;
  496. const match = topic.match(noticeMatch);
  497. if (!match) return;
  498. this.alarmModel = true;
  499. const data = JSON.parse(message.toString());
  500. this.clientId = data.clientId;
  501. this.devName = data.devName;
  502. this.sn = data.clientId;
  503. this.eventListId = data.eventListId;
  504. this.getVoipAuthor(this.clientId, userId);
  505. console.log(data, topic, "接收到消息222:");
  506. console.log(
  507. "接收到消息:",
  508. this.clientId,
  509. this.devName,
  510. this.sn,
  511. this.eventListId,
  512. data
  513. );
  514. const now = new Date();
  515. const year = now.getFullYear();
  516. const month = (now.getMonth() + 1).toString().padStart(2, "0");
  517. const day = now.getDate().toString().padStart(2, "0");
  518. const hours = now.getHours().toString().padStart(2, "0");
  519. const minutes = now.getMinutes().toString().padStart(2, "0");
  520. const formattedTime = `${year}-${month}-${day} ${hours}:${minutes}`;
  521. this.nowTime = formattedTime;
  522. console.log("isWmpf:", isWmpf);
  523. if (!isWmpf) {
  524. console.log("isWmpf:", isWmpf);
  525. this.getVoipDevices();
  526. }
  527. console.log("接收到消息:", topic, data);
  528. });
  529. },
  530. hanledList(type) {
  531. this.$http
  532. .get(`wap/event/handleEvent`, {
  533. eventListId: this.eventListId,
  534. })
  535. .then((res) => {
  536. if (res.data.code == 200) {
  537. if (type === "noVoice") {
  538. uni.showToast({
  539. title: "已处理",
  540. icon: "success",
  541. duration: 1500,
  542. });
  543. }
  544. } else {
  545. uni.showToast({
  546. title: "处理失败",
  547. icon: "none",
  548. duration: 1500,
  549. });
  550. }
  551. });
  552. },
  553. closemqtt() {
  554. this.mqttClientFlag = false;
  555. if (this.mqttClientTwo) {
  556. this.mqttClientTwo.end();
  557. this.mqttClientTwo = null;
  558. console.log("MQTT连接已断开");
  559. }
  560. },
  561. getVoipAuthor(clientId, userId) {
  562. console.log(clientId, userId);
  563. this.$http
  564. .post(
  565. "wap/share/queryUserVoipPermission",
  566. {
  567. userId: userId,
  568. clientId: clientId,
  569. },
  570. {
  571. header: {
  572. "Content-Type": "application/json;charset=UTF-8",
  573. },
  574. }
  575. )
  576. .then((res) => {
  577. if (res.data.data) {
  578. console.log(res.data.data, 9999);
  579. if (res.data.data.voipFlag === 0) {
  580. this.voipFlag = true;
  581. } else {
  582. this.voipFlag = false;
  583. }
  584. }
  585. });
  586. },
  587. sendChange() {
  588. this.$emit("sendChange", this.targetPoints);
  589. },
  590. },
  591. // mounted() {
  592. // this.connectMQTTwo();
  593. // },
  594. // onShow() {
  595. // console.log("开始接受消息", "99999");
  596. // },
  597. mounted() {
  598. console.log("开始接受消息", "8870");
  599. // 通过全局 MQTT 客户端订阅主题或监听消息
  600. this.$mqttClient.on("message", (topic, message) => {
  601. console.log("接收到消息CMD:", JSON.parse(message.toString()));
  602. console.log(JSON.parse(message.toString()), "8870");
  603. // 处理点位消息
  604. let userId = uni.getStorageSync("userId");
  605. const noticeMatch = /^\/mps\/wx_(.+)\/notice$/;
  606. const match = topic.match(noticeMatch);
  607. if (!match) return;
  608. this.alarmModel = true;
  609. const data = JSON.parse(message.toString());
  610. this.clientId = data.clientId;
  611. this.devName = data.devName;
  612. this.sn = data.clientId;
  613. this.eventListId = data.eventListId;
  614. this.getVoipAuthor(this.clientId, userId);
  615. console.log(data, topic, "接收到消息222:");
  616. console.log(
  617. "接收到消息:",
  618. this.clientId,
  619. this.devName,
  620. this.sn,
  621. this.eventListId,
  622. data
  623. );
  624. const now = new Date();
  625. const year = now.getFullYear();
  626. const month = (now.getMonth() + 1).toString().padStart(2, "0");
  627. const day = now.getDate().toString().padStart(2, "0");
  628. const hours = now.getHours().toString().padStart(2, "0");
  629. const minutes = now.getMinutes().toString().padStart(2, "0");
  630. const formattedTime = `${year}-${month}-${day} ${hours}:${minutes}`;
  631. this.nowTime = formattedTime;
  632. console.log("isWmpf:", isWmpf);
  633. if (!isWmpf) {
  634. console.log("isWmpf:", isWmpf);
  635. this.getVoipDevices();
  636. }
  637. console.log("接收到消息:", topic, data);
  638. });
  639. },
  640. beforeDestroy() {
  641. this.closemqtt();
  642. },
  643. };
  644. </script>
  645. <style lang="less" scoped>
  646. /* 弹窗部分样式 */
  647. .mask {
  648. position: fixed;
  649. left: 0;
  650. top: 0;
  651. right: 0;
  652. bottom: 0;
  653. background: rgba(0, 0, 0, 0.3);
  654. z-index: 100;
  655. }
  656. .alarm-modal {
  657. width: 675rpx;
  658. height: 1100rpx;
  659. position: fixed;
  660. top: 50%;
  661. left: 50%;
  662. transform: translate(-50%, -50%);
  663. background: linear-gradient(180deg, #ffdfdf 0%, #ffffff 30.3%);
  664. border-radius: 37rpx 37rpx;
  665. z-index: 103;
  666. padding: 50rpx 55rpx;
  667. box-sizing: border-box;
  668. .alarm-header image {
  669. width: 315rpx;
  670. height: 40rpx;
  671. }
  672. .alarm image {
  673. position: fixed;
  674. top: 0;
  675. right: 0;
  676. width: 180rpx;
  677. height: 175rpx;
  678. }
  679. .nowTime {
  680. width: 270rpx;
  681. margin-top: 20rpx;
  682. text-align: center;
  683. align-items: center;
  684. line-height: 100%;
  685. background: #fed5d5;
  686. color: #111111;
  687. font-size: 28rpx;
  688. border-radius: 10rpx;
  689. padding: 5rpx 5rpx;
  690. }
  691. .alarm-info {
  692. margin-top: 40rpx;
  693. color: #111111;
  694. font-size: 28rpx;
  695. letter-spacing: 4%;
  696. }
  697. .backImg {
  698. margin: 37rpx auto;
  699. width: 400rpx;
  700. height: 600rpx;
  701. background-color: #fff;
  702. border: 12rpx solid #333333;
  703. background-image: url(http://jkld.radar-power.com//uploadFiles/framework/file/20250620/toilet_bg.png);
  704. background-repeat: no-repeat;
  705. background-position: center;
  706. image {
  707. position: absolute;
  708. top: 50%;
  709. left: 50%;
  710. width: 60rpx;
  711. height: 60rpx;
  712. }
  713. }
  714. .alarm-bottom {
  715. display: flex;
  716. justify-content: flex-end;
  717. align-items: center;
  718. .alarm-voice {
  719. width: 185rpx;
  720. height: 85rpx;
  721. background: #f3e2dd;
  722. border-radius: 28rpx;
  723. color: #111111;
  724. font-size: 32rpx;
  725. text-align: center;
  726. line-height: 85rpx;
  727. }
  728. .alarm-handle {
  729. margin-left: 20rpx;
  730. width: 185rpx;
  731. height: 85rpx;
  732. background: linear-gradient(114.23deg, #a27867 0%, #74483d 100%);
  733. border-radius: 28rpx;
  734. box-shadow: 0rpx 4.69rpx 18.75rpx rgba(72, 41, 29, 0.15),
  735. 0rpx 9.38rpx 9.38rpx rgba(154, 132, 89, 0.2),
  736. 0rpx -4.69rpx 28.13rpx 4.69rpx #a16647 inset;
  737. color: #ffffff;
  738. font-size: 32rpx;
  739. text-align: center;
  740. line-height: 85rpx;
  741. }
  742. }
  743. }
  744. </style>