dialog-end-inner-work.vue 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690
  1. <template>
  2. <view class="mask" v-if="isLoading"></view>
  3. <dialog-base ref="baseDialog" title="结束报工">
  4. <view class="list-container">
  5. <view class="list-title uni-row">
  6. <text class="label">合格量</text>
  7. <input class="input" @input="handleInputQualifiedNum" style="width: 70%;"
  8. v-model="workInfo.qualifiedNum" placeholder="请输入合格量" />
  9. </view>
  10. <view class="list-title uni-row">
  11. <text class="label">废品信息</text>
  12. <view class="uni-row" style="justify-content: flex-end;"><text class="label" style="color: blue;"
  13. @click="handleAddWasteInfo">+添加</text></view>
  14. </view>
  15. <view class="list-title uni-row" v-for="(item, index) in wasteInfo">
  16. <input class="input" @input="handleInputRejectNum(item)" style="width: 20%;" v-model="item.rejectNum"
  17. placeholder="废品量" />
  18. <uni-data-select style="margin-left: 40rpx;width: 70%;" v-model="item.reason" :localdata="reasonList"
  19. @change="handleReasonChange(item)"></uni-data-select>
  20. <uni-icons class="icon-gear" type="close" size="40" color="red"
  21. @click="handleDeleteWasteInfo(index)"></uni-icons>
  22. </view>
  23. <view class="list-title uni-row">
  24. <text class="label">当前序是否完成</text><text>否</text>
  25. <switch class="switch" @change="switchChange" color="rgba(103, 195, 55, 1.0)" />
  26. <text>是</text>
  27. </view>
  28. <view v-if="showCarrierList && !store.isPreProcess" class="confirmCarrier">
  29. <text class="label">确认载具</text>
  30. <view class="vehicleList uni-row">
  31. <view v-for="(item,index) in bindList" :key="index"
  32. :class="{ 'vehicleNo': true, 'uni-row': true, 'blueBorder': item.flag }">
  33. <text>{{item.carrierCode}}</text>
  34. </view>
  35. </view>
  36. </view>
  37. </view>
  38. <view v-if="store.isPreProcess" class="add-btn-container uni-row">
  39. <button type="default" class="btn" @click="handlePreFinishReporting">结束报工</button>
  40. </view>
  41. <view v-if="!store.isPreProcess" class="add-btn-container uni-row">
  42. <button v-if="showCarrierList" type="primary" class="btnScan" @click="handleScanCode">扫码确认载具</button>
  43. <button type="default" class="btn" @click="handleFinishReporting">结束报工</button>
  44. </view>
  45. </dialog-base>
  46. <QrScanner v-if="showQrCodeReader" @decode="onDecodeHandler" @close="qrReaderClose" />
  47. </template>
  48. <script setup>
  49. import {
  50. ref,
  51. getCurrentInstance
  52. } from 'vue'
  53. import QrScanner from '@/pages/vueQrCode/index.vue'
  54. import {
  55. onLoad
  56. } from '@dcloudio/uni-app'
  57. import {
  58. updateDayWorkItem,
  59. saveInnerDayworkItem
  60. } from "@/api/business/dayWorkItem.js"
  61. import {
  62. getDayworkCarrierList
  63. } from '@/api/business/dayworkCarrier.js'
  64. import {
  65. store
  66. } from '@/store/index.js'
  67. import {
  68. timestampToTime,
  69. toHHmmss
  70. } from '@/utils/common.js'
  71. import {
  72. getDictInfoByType
  73. } from '@/api/dict/dict.js'
  74. import {
  75. getSpecialDeptProcessList
  76. } from '@/api/business/deptProcess.js'
  77. import {
  78. debounce
  79. } from '@/utils/common.js'
  80. import {
  81. getDayWorkItemList,
  82. listItem,
  83. getIsFirstOrder,
  84. } from '@/api/business/dayWorkItem.js'
  85. const baseDialog = ref(null)
  86. const workInfo = ref({})
  87. const showQrCodeReader = ref(false);
  88. const wasteInfo = ref([])
  89. const reasonList = ref([])
  90. const emit = defineEmits(['resflushItem'])
  91. const showCarrierList = ref(false) // 工序是否完成显示载具列表
  92. const bindList = ref([])
  93. const confirmCarrierList = ref([])
  94. const isFirstOrder = ref(true); //是否为首序
  95. const isLoading = ref(false);
  96. const endFlag = ref(0)
  97. const specialDeptProcessList = ref([])
  98. const temp = ref(0) // 保存workInfo.value.qualifiedNum的值(还原用)
  99. const lotPreSumReject = ref(0)
  100. const lotPreSumQualifiedNum = ref(0)
  101. const remainingQualifiedNum = ref(0) // 当前的合格量还能最大添加多少(剩余数量)
  102. onLoad(() => {})
  103. function open(data, itemListData) {
  104. console.log(store.isPreProcess)
  105. console.log("777")
  106. resetPage();
  107. workInfo.value = {
  108. ...data,
  109. };
  110. console.log("数据data", workInfo);
  111. //查看是否为首序
  112. getIsFirst(store.dayworkInfo.id);
  113. workInfo.value.qualifiedNum = 0;
  114. Promise.all([getSpecialDeptProcessList(), listItem({
  115. dayworkId: store.dayworkInfo.id,
  116. status: 2
  117. }), ], )
  118. .then(([res, response]) => {
  119. if (res.code == 200 && response.code == 200) {
  120. for (let i = 0; i < res.data.length; i++) {
  121. specialDeptProcessList.value[i] = res.data[i].processId;
  122. }
  123. for (let i = 0; i < response.rows.length; i++) {
  124. if (response.rows[i].processStepNumber == workInfo.value.processStepNumber) {
  125. lotPreSumReject.value += response.rows[i].rejectSum;
  126. lotPreSumQualifiedNum.value += response.rows[i].qualifiedNum;
  127. }
  128. }
  129. }
  130. if (specialDeptProcessList.value.includes(workInfo.value.processId)) {
  131. workInfo.value.qualifiedNum = store.dayworkInfo.prevProcess != null ?
  132. Math.max(0, store.dayworkInfo.processQualifiedNum - lotPreSumQualifiedNum.value -
  133. lotPreSumReject.value) :
  134. Math.max(0, store.dayworkInfo.productionQuantity - lotPreSumQualifiedNum.value -
  135. lotPreSumReject
  136. .value);
  137. // temp.value = workInfo.value.qualifiedNum;
  138. } else {
  139. workInfo.value.qualifiedNum = 0;
  140. }
  141. }).catch(err => {
  142. console.log('146 err')
  143. });
  144. init();
  145. baseDialog.value.open()
  146. }
  147. function close() {
  148. baseDialog.value.close()
  149. }
  150. function getIsFirst(dayworkId) {
  151. getIsFirstOrder(dayworkId).then(res => {
  152. if (res.code == 200) {
  153. isFirstOrder.value = res.data.isFirstOrder;
  154. }
  155. }).catch(err => {
  156. console.log(err)
  157. })
  158. }
  159. function resetPage() {
  160. workInfo.value.qualifiedNum = null;
  161. workInfo.value = {};
  162. wasteInfo.value = [];
  163. reasonList.value = [];
  164. showCarrierList.value = false;
  165. bindList.value = [];
  166. confirmCarrierList.value = [];
  167. endFlag.value = 0;
  168. lotPreSumReject.value = 0;
  169. lotPreSumQualifiedNum.value = 0;
  170. remainingQualifiedNum.value = 0;
  171. }
  172. function init() {
  173. getDictInfoByType("waste_causes").then(res => {
  174. for (let i = 0; i < res.data.length; i++) {
  175. reasonList.value[i] = {
  176. value: res.data[i].dictValue,
  177. text: res.data[i].dictLabel
  178. }
  179. }
  180. }).catch(err => {
  181. console.log('189 err')
  182. })
  183. getDayworkCarrierList({
  184. dayworkId: store.dayworkInfo.id,
  185. isChanged: 0,
  186. processInspectionId: 0
  187. }).then(res => {
  188. console.log(res)
  189. if (res.code == 200) {
  190. bindList.value = res.rows;
  191. for (let i = 0; i < bindList.value.length; i++) {
  192. bindList.value[i].flag = false;
  193. }
  194. }
  195. }).catch(err => {
  196. console.log('203 err')
  197. })
  198. }
  199. function switchChange(event) {
  200. if (event.detail.value) {
  201. workInfo.value.status = "3"
  202. } else {
  203. workInfo.value.status = "2"
  204. }
  205. console.log(event.detail.value, !store.isPreProcess)
  206. showCarrierList.value = event.detail.value;
  207. }
  208. function handleInputQualifiedNum() {
  209. workInfo.value.qualifiedNum = workInfo.value.qualifiedNum.replace(/^-+|[^\d]/g, '');
  210. }
  211. function handleInputRejectNum(item) {
  212. item.rejectNum = item.rejectNum.replace(/^0+|^-|[^\d]/g, '');
  213. // 合格数随着投产数
  214. //let sumRejectNum = 0;
  215. // for (let i = 0; i < wasteInfo.value.length; i++) {
  216. // wasteInfo.value[i].rejectNum = wasteInfo.value[i].rejectNum.replace(/^0+|^-|[^\d]/g, '');
  217. // // sumRejectNum += Number(wasteInfo.value[i].rejectNum);
  218. // }
  219. // if (temp.value > 0) {
  220. // debounce(function() {
  221. // workInfo.value.qualifiedNum = temp.value;
  222. // workInfo.value.qualifiedNum -= sumRejectNum;
  223. // }, 500)
  224. // }
  225. }
  226. /*
  227. function handleScanCode() {
  228. // 引入原生插件
  229. const mpaasScanModule = uni.requireNativePlugin("Mpaas-Scan-Module");
  230. if (mpaasScanModule) {
  231. //调用插件的 mpaasScan 方法
  232. mpaasScanModule.mpaasScan({
  233. // 扫码识别类型,参数可多选,qrCode、barCode,
  234. // 如不设置,默认识别所有扫码类型,可能有些许影响识别效率
  235. scanType: ["qrCode", "barCode"],
  236. // 是否隐藏相册,默认false不隐藏
  237. hideAlbum: false,
  238. },
  239. (ret) => {
  240. let vehicleObj = JSON.parse(ret.resp_result);
  241. let hasInFlag = false
  242. for (let i = 0; i < bindList.value.length; i++) {
  243. if (vehicleObj.carrierCode == bindList.value[i].carrierCode) {
  244. hasInFlag = true
  245. if (!bindList.value[i].flag) {
  246. endFlag.value += 1;
  247. }
  248. bindList.value[i].flag = true;
  249. }
  250. }
  251. if(!hasInFlag) {
  252. uni.showToast({
  253. icon: 'none',
  254. title: '该批次没有绑定此箱',
  255. duration: 2000
  256. })
  257. }
  258. if (endFlag.value < bindList.value.length && hasInFlag) {
  259. setTimeout(() => {
  260. handleScanCode();
  261. }, 700);
  262. }
  263. }
  264. );
  265. }
  266. }
  267. */
  268. function handleScanCode() {
  269. // 引入原生插件
  270. // const mpaasScanModule = uni.requireNativePlugin("Mpaas-Scan-Module");
  271. // if (mpaasScanModule) {
  272. // //调用插件的 mpaasScan 方法
  273. // mpaasScanModule.mpaasScan({
  274. // // 扫码识别类型,参数可多选,qrCode、barCode,
  275. // // 如不设置,默认识别所有扫码类型,可能有些许影响识别效率
  276. // scanType: ["qrCode", "barCode"],
  277. // // 是否隐藏相册,默认false不隐藏
  278. // hideAlbum: false,
  279. // },
  280. // (ret) => {
  281. // let vehicleObj = {
  282. // carrierCode: ret.resp_result
  283. // };
  284. // let hasInFlag = false
  285. // for (let i = 0; i < bindList.value.length; i++) {
  286. // if (vehicleObj.carrierCode == bindList.value[i].carrierCode) {
  287. // hasInFlag = true
  288. // if (!bindList.value[i].flag) {
  289. // endFlag.value += 1;
  290. // }
  291. // bindList.value[i].flag = true;
  292. // }
  293. // }
  294. // if (!hasInFlag) {
  295. // uni.showToast({
  296. // icon: 'none',
  297. // title: '该批次没有绑定此箱',
  298. // duration: 2000
  299. // })
  300. // }
  301. // if (endFlag.value < bindList.value.length && hasInFlag) {
  302. // setTimeout(() => {
  303. // handleScanCode();
  304. // }, 700);
  305. // }
  306. // }
  307. // );
  308. // } else {
  309. // let vehicleObj = {
  310. // carrierCode: bindList.value[0].carrierCode
  311. // };
  312. // let hasInFlag = false
  313. // for (let i = 0; i < bindList.value.length; i++) {
  314. // if (vehicleObj.carrierCode == bindList.value[i].carrierCode) {
  315. // hasInFlag = true
  316. // if (!bindList.value[i].flag) {
  317. // endFlag.value += 1;
  318. // }
  319. // bindList.value[i].flag = true;
  320. // }
  321. // }
  322. // if (!hasInFlag) {
  323. // uni.showToast({
  324. // icon: 'none',
  325. // title: '该批次没有绑定此箱',
  326. // duration: 2000
  327. // })
  328. // }
  329. // if (endFlag.value < bindList.value.length && hasInFlag) {
  330. // setTimeout(() => {
  331. // handleScanCode();
  332. // }, 700);
  333. // }
  334. // }
  335. showQrCodeReader.value = true;
  336. }
  337. function qrReaderClose() {
  338. showQrCodeReader.value = false;
  339. }
  340. function onDecodeHandler(ret) {
  341. showQrCodeReader.value = false;
  342. let vehicleObj = {
  343. carrierCode: ret
  344. };
  345. let hasInFlag = false
  346. for (let i = 0; i < bindList.value.length; i++) {
  347. if (vehicleObj.carrierCode == bindList.value[i].carrierCode) {
  348. hasInFlag = true
  349. if (!bindList.value[i].flag) {
  350. endFlag.value += 1;
  351. }
  352. bindList.value[i].flag = true;
  353. }
  354. }
  355. if (!hasInFlag) {
  356. uni.showToast({
  357. icon: 'none',
  358. title: '该批次没有绑定此箱',
  359. duration: 2000
  360. })
  361. }
  362. if (endFlag.value < bindList.value.length && hasInFlag) {
  363. setTimeout(() => {
  364. handleScanCode();
  365. }, 700);
  366. }
  367. }
  368. function handlePreFinishReporting() {
  369. console.log("999")
  370. //投产数
  371. let number = store.dayworkInfo.prevProcess == null ? store.dayworkInfo.productionQuantity : store.dayworkInfo
  372. .processQualifiedNum;
  373. workInfo.value.prodNum = number
  374. console.log(parseInt(workInfo.value.qualifiedNum))
  375. console.log(lotPreSumQualifiedNum.value)
  376. console.log(number)
  377. // 填入数大于剩余量情况
  378. if (parseInt(workInfo.value.qualifiedNum) + lotPreSumQualifiedNum.value - number > 0) {
  379. console.log("555")
  380. uni.showToast({
  381. icon: 'none',
  382. title: '当前序合格总数不能超过投产数'
  383. })
  384. } else {
  385. //判断当前序合格总数为0 ,不允许保存
  386. if (workInfo.value.status == "3" && parseInt(workInfo.value.qualifiedNum) + lotPreSumQualifiedNum.value == 0) {
  387. uni.showToast({
  388. icon: 'none',
  389. title: '当前序合格总数不能为0',
  390. duration: 2000
  391. })
  392. } else {
  393. handleSave();
  394. }
  395. }
  396. }
  397. function handleFinishReporting() {
  398. console.log(store.isPreProcess)
  399. //投产数
  400. let number = workInfo.value.prodNum;
  401. //判断当前序合格总数为0 ,不允许保存
  402. if (workInfo.value.status == "3" && parseInt(workInfo.value.qualifiedNum) + lotPreSumQualifiedNum.value == 0) {
  403. uni.showToast({
  404. icon: 'none',
  405. title: '当前序合格总数不能为0'
  406. })
  407. return;
  408. }
  409. console.log(parseInt(workInfo.value.qualifiedNum))
  410. console.log(lotPreSumQualifiedNum.value)
  411. console.log(number)
  412. if (parseInt(workInfo.value.qualifiedNum) + lotPreSumQualifiedNum.value > number) {
  413. uni.showToast({
  414. icon: 'none',
  415. title: '当前序合格总数不能超过投产数'
  416. })
  417. return;
  418. }
  419. if (showCarrierList.value) {
  420. if (endFlag.value >= bindList.value.length) {
  421. handleSave();
  422. } else {
  423. uni.showToast({
  424. icon: "none",
  425. title: "请先扫码确认载具",
  426. duration: 2000
  427. })
  428. return;
  429. }
  430. } else {
  431. handleSave();
  432. }
  433. }
  434. function handleSave() {
  435. console.log(workInfo.value.qualifiedNum)
  436. if (workInfo.value.qualifiedNum === null || workInfo.value.qualifiedNum === '') {
  437. uni.showToast({
  438. icon: "none",
  439. title: "请输入合格数",
  440. duration: 2000
  441. })
  442. return;
  443. }
  444. let rejectSum = 0
  445. console.log(rejectSum);
  446. for (let i = 0; i < wasteInfo.value.length; i++) {
  447. if ((!wasteInfo.value[i].rejectNum && wasteInfo.value[i].reason) ||
  448. (wasteInfo.value[i].rejectNum && !wasteInfo.value[i].reason) ||
  449. (!wasteInfo.value[i].rejectNum && !wasteInfo.value[i].reason)) {
  450. uni.showToast({
  451. icon: 'none',
  452. title: "请输入废弃数或废弃原因",
  453. duration: 2000
  454. })
  455. return;
  456. }
  457. rejectSum += Number(wasteInfo.value[i].rejectNum);
  458. }
  459. if (rejectSum > workInfo.value.prodNum) {
  460. uni.showToast({
  461. icon: 'none',
  462. title: '废品数不能大于投产数',
  463. duration: 2000
  464. })
  465. return;
  466. }
  467. if (workInfo.value.status != '3') {
  468. workInfo.value.status = '2';
  469. }
  470. isLoading.value = true; // 显示遮罩层
  471. workInfo.value.endTime = timestampToTime(new Date());
  472. uni.showLoading({
  473. title: '加载中'
  474. });
  475. workInfo.value.rejectList = wasteInfo.value;
  476. workInfo.value.isPreProcess = store.isPreProcess;
  477. workInfo.value.processStepNumber = store.dayworkInfo.currentProcess.processStepNumber
  478. console.log(workInfo.value)
  479. saveInnerDayworkItem(workInfo.value).then(res => {
  480. isLoading.value = false; // 隐藏遮罩层
  481. uni.hideLoading();
  482. if (res.code === 200) {
  483. uni.showToast({
  484. icon: 'success',
  485. title: '操作成功',
  486. });
  487. emit('resflushItem');
  488. close();
  489. } else {
  490. uni.showToast({
  491. icon: 'none',
  492. title: res.msg
  493. });
  494. }
  495. })
  496. }
  497. function handleAddWasteInfo() {
  498. if (wasteInfo.value.length > 0) {
  499. if (wasteInfo.value.some(item => item.rejectNum == '' || item.reason == '')) {
  500. uni.showToast({
  501. icon: 'none',
  502. title: '请填写废品量或废品原因再点击添加'
  503. })
  504. } else {
  505. wasteInfo.value.push({
  506. rejectNum: '',
  507. reason: ''
  508. })
  509. }
  510. } else {
  511. wasteInfo.value.push({
  512. rejectNum: store.dayworkInfo.processQualifiedNum > 0 ? store.dayworkInfo
  513. .processQualifiedNum - lotPreSumQualifiedNum.value - lotPreSumReject.value - workInfo.value
  514. .qualifiedNum > 0 ? store.dayworkInfo
  515. .processQualifiedNum - lotPreSumQualifiedNum.value - lotPreSumReject.value - workInfo.value
  516. .qualifiedNum : 1 : store.dayworkInfo.isLast == 1 ?
  517. store.dayworkInfo.lastLotQuantity - lotPreSumQualifiedNum.value - lotPreSumReject.value -
  518. workInfo.value.qualifiedNum > 0 ?
  519. store.dayworkInfo.lastLotQuantity - lotPreSumQualifiedNum.value - lotPreSumReject.value -
  520. workInfo.value.qualifiedNum : 1 : store.dayworkInfo.oneLotQuantity - lotPreSumQualifiedNum
  521. .value - lotPreSumReject.value -
  522. workInfo.value.qualifiedNum > 0 ?
  523. store.dayworkInfo.oneLotQuantity - lotPreSumQualifiedNum.value - lotPreSumReject.value -
  524. workInfo.value.qualifiedNum : 1,
  525. reason: ''
  526. })
  527. }
  528. }
  529. function handleDeleteWasteInfo(index) {
  530. wasteInfo.value.splice(index, 1);
  531. }
  532. function handleReasonChange(item) {
  533. if (wasteInfo.value.filter(waste => waste.reason == item.reason).length > 1) {
  534. wasteInfo.value.splice(wasteInfo.value.indexOf(item), 1);
  535. uni.showToast({
  536. icon: 'none',
  537. title: '请勿重复选择废品原因',
  538. duration: 2000
  539. })
  540. }
  541. }
  542. defineExpose({
  543. open
  544. })
  545. </script>
  546. <style lang="scss">
  547. .dialog-body {
  548. .list-container {
  549. width: 100%;
  550. display: flex;
  551. align-items: flex-start;
  552. padding: 0 4rpx;
  553. .list-title {
  554. width: 100%;
  555. margin-top: 16rpx;
  556. height: 64rpx;
  557. line-height: 64rpx;
  558. align-items: center;
  559. .label {
  560. flex: 1;
  561. font-size: 32rpx;
  562. }
  563. .input {
  564. width: 40%;
  565. height: 66rpx;
  566. padding-left: 10rpx;
  567. font-size: 22rpx;
  568. border: 1rpx solid #e1e1e1;
  569. border-radius: 8rpx;
  570. }
  571. .icon-gear {
  572. font-size: 56rpx;
  573. }
  574. }
  575. .switch {
  576. margin-top: -8rpx;
  577. align-items: center;
  578. transform: scale(0.7);
  579. }
  580. .confirmCarrier {
  581. .label {
  582. padding-top: 20rpx;
  583. font-size: 32rpx;
  584. }
  585. .vehicleList {
  586. justify-content: baseline;
  587. align-content: flex-start;
  588. flex-wrap: wrap;
  589. width: 100%;
  590. height: 120rpx;
  591. overflow: auto;
  592. .vehicleNo {
  593. padding: 0 10rpx;
  594. margin: 10rpx 20rpx 0 0;
  595. justify-content: space-between;
  596. align-items: center;
  597. width: auto;
  598. height: 60rpx;
  599. border: 2rpx solid rgba(213, 213, 213, 1);
  600. border-radius: 6rpx;
  601. }
  602. .blueBorder {
  603. background-color: #1684fc;
  604. color: #FFFFFF;
  605. }
  606. }
  607. }
  608. }
  609. .add-btn-container {
  610. margin-top: 32rpx;
  611. .btn {
  612. flex: 1;
  613. background-color: rgba(255, 85, 85, 1);
  614. color: #FFFFFF;
  615. margin-left: 5rpx;
  616. padding: 0;
  617. }
  618. .btnScan {
  619. flex: 1;
  620. color: #FFFFFF;
  621. margin-right: 5rpx;
  622. padding: 0;
  623. }
  624. }
  625. }
  626. .mask {
  627. position: fixed;
  628. top: 0;
  629. left: 0;
  630. right: 0;
  631. bottom: 0;
  632. background-color: rgba(0, 0, 0, 0.5);
  633. z-index: 2000;
  634. display: flex;
  635. justify-content: center;
  636. align-items: center;
  637. }
  638. .mask .loading-text {
  639. color: #fff;
  640. font-size: 36rpx;
  641. }
  642. </style>