add_quality_testing.vue 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736
  1. <template>
  2. <view>
  3. <view class='wrap'>
  4. <view class='title_b'>基本信息</view>
  5. <view class="c-row ">
  6. <view class="title">仓库</view>
  7. <view class="con-list">
  8. {{gridList.warehouseName}}
  9. </view>
  10. </view>
  11. <view class="c-row ">
  12. <view class="title">编号</view>
  13. <view class="con-list">
  14. {{gridList.qualityNo}}
  15. </view>
  16. </view>
  17. <view class="c-row ">
  18. <view class="title">客户</view>
  19. <view class="con-list">
  20. <view @click='gocustomer' v-if='gridList.customerName'>
  21. {{gridList.customerName}}({{gridList.customerPhone}})
  22. </view>
  23. <view @click='gocustomer' v-else>
  24. 选择客户
  25. </view>
  26. </view>
  27. </view>
  28. <view class="c-row ">
  29. <view class="title">车牌号</view>
  30. <view class="con-list">
  31. <input v-model='gridList.carNumber' placeholder="请输入车牌号" name="input"></input>
  32. </view>
  33. </view>
  34. <view v-if="gridList.paramType != '1'" class="c-row ">
  35. <view class="title">扣重比</view>
  36. <view class="con-list">
  37. <input v-model='gridList.buckleWeightRatio' placeholder="请输入扣重比" name="input"></input>
  38. </view>
  39. </view>
  40. <view v-else class="c-row ">
  41. <view class="title">扣杂</view>
  42. <view class="con-list">
  43. <input v-model='gridList.buckleMiscellaneous' placeholder="初检扣杂" @input="waterContentChange"
  44. name="input"></input>
  45. <input v-model='gridList.reBuckleMiscellaneous' placeholder="复检扣杂" @input="waterContentChange"
  46. name="input"></input>
  47. </view>
  48. </view>
  49. <view class="c-row ">
  50. <view class="title">购粮性质</view>
  51. <view class="con-list">
  52. <input v-model='gridList.natureOfGrainPurchase' placeholder="请输入购粮性质" name="input"></input>
  53. </view>
  54. </view>
  55. <view class="c-row ">
  56. <view class="title">仓位号</view>
  57. <view class="con-list">
  58. <view @click='show=true'>{{gridList.binNumber?gridList.binNumber:'请选择仓位号'}}</view>
  59. <u-picker :range="warehouseList" range-key="binNumber" @confirm='binNumberpicker($event)'
  60. v-model="show" mode="selector">
  61. </u-picker>
  62. </view>
  63. </view>
  64. <view class="c-row ">
  65. <view class="title">囤位号</view>
  66. <view class="con-list">
  67. <input type='number' v-model='gridList.storageTagNo' placeholder="请输入囤位号" name="input"></input>
  68. </view>
  69. </view>
  70. <view class="c-row ">
  71. <view class="title">货名</view>
  72. <view class="con-list">
  73. <view @click='show2=true'>{{gridList.goodsName}}</view>
  74. <u-picker :range="goodsList" range-key="goodsName" @confirm='goodspicker($event)' v-model="show2"
  75. mode="selector">
  76. </u-picker>
  77. </view>
  78. </view>
  79. <view class="c-row ">
  80. <view class="title">类型</view>
  81. <view v-if="!edit" class="con-list">
  82. <view @click='show3=true'>{{gridList.type}}</view>
  83. <u-picker :range="typeList" @confirm='typepicker($event)' v-model="show3" mode="selector">
  84. </u-picker>
  85. </view>
  86. <view v-else class="con-list">{{gridList.type}}</view>
  87. </view>
  88. <view v-if="gridList.type == '潮粮'" class="c-row">
  89. <view class="title">净重单价(元/公斤)</view>
  90. <view class="con-list">
  91. <input v-model='gridList.tidalGrainPrice' disabled placeholder="自动获取,不可编辑" name="input"></input>
  92. </view>
  93. </view>
  94. <view v-if="gridList.type == '干粮'" class="c-row">
  95. <view class="title">干粮单价(元/公斤)</view>
  96. <view class="con-list">
  97. <input v-model='gridList.dryGrainPrice' placeholder="请输入干粮单价" name="input"></input>
  98. </view>
  99. </view>
  100. </view>
  101. <view style='padding-bottom:300rpx;'>
  102. <view class='wrap'>
  103. <view class='title_b'>化验信息</view>
  104. <view class="c-row ">
  105. <view class="title">等级</view>
  106. <view class="con-list">
  107. <view @click='show1=true'>{{gridList.grade?gridList.grade:'请选择等级'}}</view>
  108. <u-picker :range="gradeList" range-key="value" @confirm='gradepicker($event)' v-model="show1"
  109. mode="selector">
  110. </u-picker>
  111. </view>
  112. </view>
  113. <view class="c-row ">
  114. <view class="title">水分(%)</view>
  115. <view class="con-list">
  116. <input v-model='gridList.waterContent' placeholder="初检水分" @input="waterContentChange"
  117. name="input"></input>
  118. <input v-model='gridList.rewaterContent' placeholder="复检水分" @input="waterContentChange"
  119. name="input"></input>
  120. </view>
  121. </view>
  122. <view class="c-row ">
  123. <view class="title">容重(克/升)</view>
  124. <view class="con-list">
  125. <input v-model='gridList.bulkDensity' placeholder="请输入容重" name="input"></input>
  126. </view>
  127. </view>
  128. <view class="c-row ">
  129. <view class="title">不完善粒(%)</view>
  130. <view class="con-list">
  131. <input v-model='gridList.imperfectGrain' placeholder="请输入不完整粒占比" name="input"></input>
  132. </view>
  133. </view>
  134. <view class="c-row ">
  135. <view class="title">杂质(%)</view>
  136. <view class="con-list">
  137. <input v-model='gridList.impurity' placeholder="请输入杂质占比" name="input"></input>
  138. </view>
  139. </view>
  140. <view class="c-row ">
  141. <view class="title">霉变粒(%)</view>
  142. <view class="con-list">
  143. <input v-model='gridList.mildewGrain' placeholder="请输入霉变粒占比" name="input"></input>
  144. </view>
  145. </view>
  146. <view class="c-row">
  147. <view class="title">热损伤(%)</view>
  148. <view class="con-list">
  149. <input v-model='gridList.jiaorenli' placeholder="请输入热损伤占比" name="input"></input>
  150. </view>
  151. </view>
  152. </view>
  153. </view>
  154. <view class="footer">
  155. <view @click='submit' class="button">提交</view>
  156. </view>
  157. </view>
  158. </template>
  159. <script>
  160. import dragButton from "@/components/drag-button/drag-button.vue";
  161. import {
  162. mapState
  163. } from 'vuex';
  164. let startY = 0,
  165. moveY = 0,
  166. pageAtTop = true;
  167. export default {
  168. components: {
  169. dragButton
  170. },
  171. data() {
  172. return {
  173. inputShow: false,
  174. modalName: '',
  175. mycarStyle: '',
  176. feild: undefined,
  177. id: 0,
  178. show: false,
  179. edit:true,
  180. selector: [],
  181. show1: false,
  182. inputContent: '',
  183. coverTransform: 'translateY(0px)',
  184. coverTransition: '0s',
  185. moving: false,
  186. footprintList: [],
  187. searchKeyWord: '',
  188. isVip: false,
  189. userInfoTmp: [],
  190. inputStatus: 'none',
  191. carInfo: [],
  192. gridCol: 4,
  193. pageSize: 10,
  194. show3: false,
  195. show2: false,
  196. goodsList: [],
  197. currentPage: 1,
  198. gridBorder: false,
  199. headUrl: "../../static/img/myimg/YongHu@3x.png",
  200. userphone: "",
  201. username: "请更改昵称",
  202. gridList: {
  203. natureOfGrainPurchase: '贸易粮',
  204. type: '潮粮',
  205. tidalGrainPrice: '',
  206. dryGrainPrice: '',
  207. buckleMiscellaneous: '',
  208. },
  209. typeList: ['潮粮', '干粮'],
  210. managementType: '',
  211. warehouseName: '',
  212. warehouseList: [],
  213. warehouseCount: '',
  214. commonWarehouseNo: '',
  215. showTran: true,
  216. companyId: 1,
  217. current: 4,
  218. gradeList: [{
  219. key: 1,
  220. value: '一等品'
  221. },
  222. {
  223. key: 2,
  224. value: '二等品'
  225. },
  226. {
  227. key: 3,
  228. value: '三等品'
  229. },
  230. {
  231. key: 4,
  232. value: '等外'
  233. },
  234. ],
  235. cangid: ''
  236. }
  237. },
  238. // #ifndef MP
  239. onNavigationBarButtonTap(e) {
  240. const index = e.index;
  241. if (index === 0) {
  242. this.navTo('/pages/set/set');
  243. } else if (index === 1) {
  244. // #ifdef APP-PLUS
  245. const pages = getCurrentPages();
  246. const page = pages[pages.length - 1];
  247. const currentWebview = page.$getAppWebview();
  248. currentWebview.hideTitleNViewButtonRedDot({
  249. index
  250. });
  251. // #endif
  252. uni.navigateTo({
  253. url: '/pages/notice/notice'
  254. })
  255. }
  256. },
  257. // #endif
  258. computed: {
  259. ...mapState(['hasLogin', 'userInfo']),
  260. // 手机号中间4位加*
  261. starUserphone() {
  262. let reg = /^(\d{3})\d{4}(\d{4})$/;
  263. if (this.userphone) {
  264. return this.userphone.replace(reg, "$1****$2");
  265. }
  266. }
  267. },
  268. onLoad(options) {
  269. this.commonWarehouseNo = options.commonWarehouseNo
  270. this.warehouseCount = Number(options.warehouseCount) + 1
  271. let number = '000' + this.warehouseCount
  272. number = number.substring(number.length - 4, number.length)
  273. this.gridList.warehouseName = options.warehouseName
  274. this.gridList.qualityNo = 'SGRK' + this.getdate() + this.commonWarehouseNo + number
  275. this.cangid = options.cangid
  276. this.$api.doRequest('get', '/qualityInspectionManagement/api/goodsName', {
  277. warehouseId: this.cangid
  278. }).then(res => {
  279. if (res.data.data) {
  280. }
  281. })
  282. this.managementType = options.managementType
  283. },
  284. onShow() {
  285. this.purchasePriceList = uni.getStorageSync('purchasePriceList')
  286. if (uni.getStorageSync('checkcustomer')) {
  287. this.gridList.customerName = uni.getStorageSync('checkcustomer').customerName
  288. this.gridList.customerPhone = uni.getStorageSync('checkcustomer').customerPhone
  289. this.gridList.customerNumberCard = uni.getStorageSync('checkcustomer').customerNumberCard
  290. }
  291. this.gridList.grade = this.gradeList[0].value
  292. this.gridList.gradeKey = this.gradeList[0].key
  293. var that = this
  294. this.$api.doRequest('get', '/identityAuthenticationInfo/identityAuthenticationInfoCustomer', {
  295. compId: '',
  296. authenticationStatusKey: 7
  297. }).then(res => {
  298. if (res.data.data) {
  299. // let data = res.data.data
  300. // that.gridList =data
  301. that.$api.doRequest('get', '/warehouseBaseInfo/getWarehouse', {
  302. id: this.cangid
  303. }).then(res => {
  304. that.warehouseList = res.data.data.warehousePositionInfoList
  305. })
  306. }
  307. })
  308. this.$api.doRequest('get', '/qualityInspectionManagement/api/goodsName', {
  309. warehouseId: this.cangid
  310. }).then(res => {
  311. if (res.data.data) {
  312. that.goodsList = res.data.data
  313. if (that.goodsList.length > 0) {
  314. that.gridList.goodsName = that.goodsList[0].goodsName
  315. uni.setStorageSync('purchasePriceList', that.goodsList)
  316. that.purchasePriceList = uni.getStorageSync('purchasePriceList')
  317. that.waterContentChange()
  318. }
  319. // for (let i = 0; i < res.data.data.length; i++) {
  320. // this.goodsList.push(res.data.data[i].goodsName)
  321. // }
  322. // if(this.goodsList.some(item=>{return item.goodsName=='玉米'})){
  323. // this.gridList.goodsName='玉米'
  324. // uni.setStorageSync('goodsName',this.gridList.goodsName)
  325. // }else{
  326. // this.gridList.goodsName=this.goodsList[0].goodsName
  327. // uni.setStorageSync('goodsName',this.gridList.goodsName)
  328. // }
  329. }
  330. })
  331. },
  332. methods: {
  333. waterContentChange() {
  334. var that = this
  335. if (this.gridList.goodsName && this.cangid) {
  336. if (!this.gridList.dryGrainPrice || this.gridList.dryGrainPrice == 0) {
  337. this.$api.doRequest('get', '/purchasePrice/dryGrainPrice', {
  338. warehouseId: this.cangid,
  339. goodsName: this.gridList.goodsName
  340. }).then(res => {
  341. that.gridList.dryGrainPrice = res.data.data
  342. })
  343. }
  344. }
  345. if (this.gridList.goodsName) {
  346. for (var i = 0; i < this.purchasePriceList.length; i++) {
  347. if (this.purchasePriceList[i].goodsName == this.gridList.goodsName) {
  348. this.gridList.buckleWeightRatio = this.purchasePriceList[i].deductWeight
  349. this.gridList.paramType = this.purchasePriceList[i].paramType
  350. }
  351. }
  352. }
  353. var numReg = /^[0-9]*$/
  354. var numRe = new RegExp(numReg)
  355. //潮粮单价改变事件
  356. if (
  357. this.gridList.goodsName &&
  358. this.gridList.waterContent &&
  359. this.gridList.grade &&
  360. numRe.test(this.gridList.waterContent)
  361. ) {
  362. this.$api.doRequest('get', '/purchasePrice/tidalGrainPrice', {
  363. warehouseId: this.cangid,
  364. goodsName: this.gridList.goodsName,
  365. waterContent: this.gridList.waterContent,
  366. grade: this.gridList.grade,
  367. }).then(res => {
  368. if (that.gridList.paramType == '1') {
  369. that.gridList.tidalGrainPrice = parseFloat(parseFloat(res.data.data) - parseFloat(that
  370. .gridList.buckleMiscellaneous) / 100 * parseFloat(that.gridList
  371. .dryGrainPrice)).toFixed(4)
  372. if (!that.gridList.tidalGrainPrice) {
  373. that.gridList.tidalGrainPrice = ''
  374. }
  375. } else {
  376. that.gridList.tidalGrainPrice = res.data.data
  377. }
  378. })
  379. }
  380. },
  381. gocustomer() {
  382. uni.navigateTo({
  383. url: '/pages/erpbusiness/customer?cangid=' + this.cangid
  384. })
  385. },
  386. getdate() {
  387. var date = new Date()
  388. var year = date.getFullYear() //获取完整的年份(4位)
  389. var mouth = date.getMonth() + 1 //获取当前月份(0-11,0代表1月)
  390. var datetime = date.getDate() //获取当前日(1-31)
  391. if (mouth < 10) {
  392. mouth = '0' + mouth
  393. }
  394. if (datetime < 10) {
  395. datetime = '0' + datetime
  396. }
  397. return year + '' + mouth + '' + datetime
  398. },
  399. submit() {
  400. var that = this
  401. if (!this.gridList.qualityNo) {
  402. this.$api.msg('编号不能为空')
  403. return
  404. }
  405. if (!this.gridList.binNumber) {
  406. this.$api.msg('仓位不能为空')
  407. return
  408. }
  409. if (!this.gridList.customerName) {
  410. this.$api.msg('客户不能为空')
  411. return
  412. }
  413. if (!this.gridList.storageTagNo) {
  414. this.$api.msg('囤位号不能为空')
  415. return
  416. }
  417. if (this.gridList.storageTagNo.length > 10) {
  418. this.$api.msg('囤位号不能为空')
  419. return
  420. }
  421. if (!this.gridList.carNumber) {
  422. this.$api.msg('车牌号不能为空')
  423. return
  424. }
  425. if (this.gridList.carNumber.length != 7) {
  426. this.$api.msg('车牌号输入错误')
  427. return
  428. }
  429. if (!this.gridList.goodsName) {
  430. this.$api.msg('货名不能为空')
  431. return
  432. }
  433. if (this.gridList.buckleWeightRatio < 0 || this.gridList.buckleWeightRatio > 2) {
  434. this.$api.msg('扣重比输入错误')
  435. return
  436. }
  437. if (
  438. String(this.gridList.buckleWeightRatio).indexOf('.') != -1 &&
  439. String(this.gridList.buckleWeightRatio).length -
  440. (String(this.gridList.buckleWeightRatio).indexOf('.') + 1) > 2) {
  441. this.$api.msg('扣重比输入错误')
  442. return
  443. }
  444. if (!this.gridList.type) {
  445. this.$api.msg('类型不能为空')
  446. return
  447. }
  448. if (!this.gridList.natureOfGrainPurchase) {
  449. this.$api.msg('购粮性质不能为空')
  450. return
  451. }
  452. if (!this.gridList.grade) {
  453. this.$api.msg('等级不能为空')
  454. return
  455. }
  456. if (!this.gridList.impurity) {
  457. this.$api.msg('杂质不能为空')
  458. return
  459. }
  460. if (!this.gridList.waterContent) {
  461. this.$api.msg('水分不能为空')
  462. return
  463. }
  464. if (!this.gridList.mildewGrain) {
  465. this.$api.msg('霉变粒不能为空')
  466. return
  467. }
  468. if (!this.gridList.bulkDensity) {
  469. this.$api.msg('容重不能为空')
  470. return
  471. }
  472. if (!this.gridList.jiaorenli) {
  473. this.$api.msg('热损伤不能为空')
  474. return
  475. }
  476. if (!this.gridList.imperfectGrain) {
  477. this.$api.msg('不完整粒不能为空')
  478. return
  479. }
  480. uni.showModal({
  481. content: "确定提交质检信息?",
  482. showCancel: true,
  483. confirmText: '提交',
  484. success: function(res) {
  485. if (res.confirm) {
  486. that.$api.doRequest('post',
  487. '/qualityInspectionManagement/api/addQualityInspection', that.gridList)
  488. .then(res => {
  489. if (res.data.code == 200) {
  490. that.$api.msg('提交成功')
  491. uni.navigateBack({})
  492. } else {
  493. hat.$api.msg('提交失败')
  494. }
  495. })
  496. }
  497. }
  498. })
  499. },
  500. gradepicker(e) {
  501. console.log(e)
  502. // this.$set(this.gradeList,'grade',this.gradeList[e[0]].value)
  503. this.gridList.grade = this.gradeList[e[0]].value
  504. this.gridList.gradeKey = this.gradeList[e[0]].key
  505. this.waterContentChange()
  506. },
  507. goodspicker(e) {
  508. console.log(e)
  509. // this.$set(this.gradeList,'grade',this.gradeList[e[0]].value)
  510. if(this.goodsList[e[0]].goodsName=='玉米'){
  511. this.gridList.type='干粮'
  512. this.edit=true
  513. }
  514. else if(this.goodsList[e[0]].goodsName=='玉米(潮粮)'){
  515. this.gridList.type='潮粮'
  516. this.edit=true
  517. }else{
  518. this.edit=false
  519. }
  520. this.gridList.goodsName = this.goodsList[e[0]].goodsName
  521. uni.setStorageSync('goodsName', this.gridList.goodsName)
  522. if (this.gridList.type == "干粮" && this.gridList.goodsName) {
  523. this.$api.doRequest('get', '/purchasePrice/dryGrainPrice', {
  524. warehouseId: this.cangid,
  525. goodsName: this.gridList.goodsName
  526. }).then(res => {
  527. that.gridList.dryGrainPrice = res.data.data
  528. })
  529. }
  530. this.waterContentChange()
  531. },
  532. typepicker(e) {
  533. var that = this
  534. this.gridList.type = this.typeList[e[0]]
  535. if (this.gridList.type == "干粮" && this.gridList.goodsName) {
  536. this.$api.doRequest('get', '/purchasePrice/dryGrainPrice', {
  537. warehouseId: this.cangid,
  538. goodsName: this.gridList.goodsName
  539. }).then(res => {
  540. that.gridList.dryGrainPrice = res.data.data
  541. })
  542. }
  543. },
  544. binNumberpicker(e) {
  545. this.gridList.binNumber = this.warehouseList[e[0]].binNumber
  546. },
  547. del(item) {
  548. this.$api.doRequest('get', '/qualityInspectionManagement/api/deleteQualityInspection', {
  549. id: item.id
  550. }).then(res => {
  551. if (res.data.code == 200) {
  552. this.$api.msg('删除成功')
  553. } else {
  554. this.$api.msg('系统异常,请联系管理员')
  555. }
  556. })
  557. },
  558. contactUs() {
  559. const that = this
  560. uni.makePhoneCall({
  561. // 手机号
  562. phoneNumber: '18241771147',
  563. // 成功回调
  564. success: (res) => {},
  565. // 失败回调
  566. fail: (res) => {}
  567. });
  568. },
  569. loadData() {
  570. // const that = this
  571. // if(uni.getStorageSync("PageCur")){
  572. // that.PageCur = uni.getStorageSync("PageCur");
  573. // }
  574. // that.userInfoTmp = uni.getStorageSync("userInfo")
  575. // uni.showLoading({
  576. // title: '正在加载',
  577. // mask:true
  578. // })
  579. // that.$api.request('integral', 'getIndexData', failres => {
  580. // that.$api.msg(failres.errmsg)
  581. // uni.hideLoading()
  582. // }).then(res => {
  583. // let data = res.data
  584. // uni.setStorageSync("message", data.message);
  585. // uni.setStorageSync("task", data.task);
  586. // uni.setStorageSync("contract", data.contract);
  587. // uni.setStorageSync('showTran', data.showTran);
  588. // that.showTran = data.showTran
  589. // that.gridList[4].tips = data.task
  590. // that.gridList[2].tips = data.contract
  591. // that.companyId = data.companyId
  592. // uni.hideLoading()
  593. // })
  594. },
  595. confirm() {
  596. const that = this
  597. if (!that.inputContent) {
  598. that.$api.msg('输入不能为空')
  599. return
  600. }
  601. let obj = {}
  602. obj[that.feild] = that.inputContent
  603. that.$api.request('user', 'syncUserInfo', obj).then(res => {
  604. that.userInfo.nickname = that.inputContent
  605. that.inputContent = ''
  606. that.$store.commit('login', that.userInfo)
  607. })
  608. },
  609. cancel() {
  610. this.inputShow = false
  611. this.inputStatus = 'none'
  612. this.genderShow = false
  613. },
  614. myAccount() {
  615. uni.navigateTo({
  616. url: `/pageA/pages/contract`
  617. })
  618. },
  619. /**
  620. * 统一跳转接口,拦截未登录路由
  621. * navigator标签现在默认没有转场动画,所以用view
  622. */
  623. navTo(url) {
  624. if (!this.hasLogin) {
  625. url = '/pages/public/login';
  626. }
  627. uni.navigateTo({
  628. url
  629. })
  630. },
  631. mycarClick(carNo) {
  632. this.modalName = null
  633. uni.navigateTo({
  634. url: `/pageB/car/mycar_detail?carNo=${carNo}`
  635. })
  636. },
  637. scanCode() {
  638. uni.scanCode({
  639. success: function(res) {
  640. uni.navigateTo({
  641. url: res.result
  642. })
  643. }
  644. })
  645. },
  646. hideModal(e) {
  647. this.modalName = null
  648. },
  649. }
  650. }
  651. </script>
  652. <style lang='scss' scoped>
  653. page {
  654. background: #F5F6FA;
  655. }
  656. .title_b {
  657. margin: 20rpx 20rpx 0rpx 20rpx;
  658. padding: 20rpx 10rpx 20rpx 10rpx;
  659. font-size: 18px;
  660. font-weight: 550;
  661. }
  662. .c-row {
  663. display: -webkit-box;
  664. display: -webkit-flex;
  665. display: flex;
  666. -webkit-box-align: center;
  667. -webkit-align-items: center;
  668. align-items: center;
  669. padding: 20rpx 30rpx;
  670. position: relative;
  671. }
  672. .con-list {
  673. -webkit-box-flex: 1;
  674. -webkit-flex: 1;
  675. flex: 1;
  676. display: -webkit-box;
  677. display: -webkit-flex;
  678. display: flex;
  679. -webkit-box-orient: vertical;
  680. -webkit-box-direction: normal;
  681. -webkit-flex-direction: column;
  682. flex-direction: column;
  683. color: #303133;
  684. line-height: 40rpx;
  685. text-align: right;
  686. padding-right: 20rpx;
  687. }
  688. .wrap {
  689. padding-bottom: 10px;
  690. font-size: 14px;
  691. background: #fff;
  692. margin: 10px;
  693. border-radius: 10px;
  694. input {
  695. font-size: 14px;
  696. }
  697. >.title {
  698. padding: 10px 16px;
  699. }
  700. }
  701. .footer {
  702. background: #fff;
  703. position: fixed;
  704. bottom: 0;
  705. width: 100%;
  706. padding: 20px 10px;
  707. z-index: 10;
  708. .button {
  709. background: #22C572;
  710. width: 90%;
  711. margin: 0 auto;
  712. padding: 10px;
  713. color: #fff;
  714. text-align: center;
  715. border-radius: 30px;
  716. }
  717. }
  718. </style>