index.vue 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757
  1. <template>
  2. <view>
  3. <view class="content">
  4. <view class="header-box">
  5. <UniStatusBar></UniStatusBar>
  6. <view class="title flex align_center" :style="{height:(navHeight+'px')}">
  7. <u-image src="/static/logo-h.png" width="349" height='40'></u-image>
  8. </view>
  9. </view>
  10. <view class="cbody">
  11. <view class="body-box bg-blue">
  12. <!-- 滚动区域 -->
  13. <view class="scroll-list">
  14. <scrollBox v-if="list.length&&!hasRedPacket" :list="list"></scrollBox>
  15. <scrollBox v-if="slist.length&&hasRedPacket" :list="slist"></scrollBox>
  16. </view>
  17. <!-- 版本提示 -->
  18. <view class="notices flex align_center" v-if="showVersion">
  19. <view><u-icon name="volume" color="#f2a557" :size="28" :margin-right='15'></u-icon> 当前是体验版</view>
  20. </view>
  21. <!-- 保证金 -->
  22. <view class="notices flex align_center" v-if="bondRecord" @click="toPayBondAmount">
  23. <view><u-icon name="volume" color="#f2a557" :size="28" :margin-right='15'></u-icon> 您有一笔保证金待支付 ¥{{bondRecord.bondAmount}}</view>
  24. <!-- <text class="text">立即支付>></text> -->
  25. </view>
  26. <!-- 待取货提醒 -->
  27. <view class="notices flex align_center" v-if="!bondRecord&&orderTodo" @click="toOrder">
  28. <view><u-icon name="volume" color="#f2a557" :size="28" :margin-right='15'></u-icon> 您有待取货的货架订单哦!</view> <text class="text">立即处理>></text>
  29. </view>
  30. <!-- 门店审核不通过 -->
  31. <view class="notices flex justify_between" v-if="storeApply&&storeApply.auditStatus=='REFUSE'&&storeApply.readFlag=='0'">
  32. <view><u-icon name="volume" color="#f2a557" :size="28" :margin-right='15'></u-icon> 门店认证资料审核不通过,请重新提交审核!</view> <text class="text" @click="toKnow">知道了</text>
  33. </view>
  34. <!-- 名片 -->
  35. <view class="userCard flex align_center justify_between">
  36. <view class="userCard-info flex align_center">
  37. <view>
  38. <u-image shape='circle' v-if="!hasLogin" src="/static/def_personal_avatar.png" width="90" height="90"></u-image>
  39. <u-image shape='circle' v-else :src="avatarUrl||'/static/def_personal_avatar.png'" width="90" height="90"></u-image>
  40. </view>
  41. <view class="user-info" @click="toUser">
  42. <view v-if="!hasLogin" style="font-size: 40rpx;">
  43. 请点击登录
  44. </view>
  45. <view v-else>
  46. <view class="user-name">{{userInfo.userNameCN || userInfo.mobile}}</view>
  47. <view v-if="hasLogin&&userInfo&&userInfo.sysUserFlag == '0'">
  48. <u-tag text="个人用户" mode="dark" type="warning" shape="circle" size="mini" />
  49. </view>
  50. <view v-else>{{userInfo.orgName}}</view>
  51. </view>
  52. </view>
  53. </view>
  54. <view @click="toUser">
  55. <text v-if="hasLogin&&userInfo&&userInfo.sysUserFlag == '0'" class="user-rz">
  56. {{storeApply&&storeApply.auditStatus=='WAIT'?'认证门店审核中':'认证成为门店'}}
  57. </text>
  58. <u-icon name="arrow-right"></u-icon>
  59. </view>
  60. </view>
  61. </view>
  62. <view class="body-box">
  63. <!-- 扫描按钮 -->
  64. <view class="action-button flex" v-if="userInfo.sysUserFlag == '1'">
  65. <view class="f1" @click="openTakeGood(1)">
  66. <view class="icons"><u-icon name="shujuchaxun" custom-prefix="custom-icon"></u-icon></view>
  67. <view class="tits">产品编码取货</view>
  68. </view>
  69. <view class="f2" @click="openTakeGood(0)">
  70. <view class="icons"><u-icon name="saomasoudan" custom-prefix="custom-icon"></u-icon></view>
  71. <view class="tits">二维码/条形码取货</view>
  72. </view>
  73. </view>
  74. <view style="margin-top: 20upx;">
  75. <u-swiper mode="dot" bg-color="" img-mode="widthFix" @click="clickBanner" :interval="3000" :height="374" :list="imgList"></u-swiper>
  76. </view>
  77. </view>
  78. <!-- 扫描记录 -->
  79. <view class="list-box">
  80. <!-- 扫描记录 -->
  81. <u-cell-group :border="false">
  82. <u-cell-item title="VIN查询历史" @click="toAllRecord" :title-style="{fontSize:'1em'}" value="全部">
  83. <u-icon slot="icon" size="38" color="#066cff" style="margin-right: 0.3em;" name="order"></u-icon>
  84. </u-cell-item>
  85. </u-cell-group>
  86. <u-cell-group :border="false" v-if="hasLogin">
  87. <u-cell-item v-for="item in vinList"
  88. @click="toChoosePart(item)"
  89. :key="item.id"
  90. :title="item.vinCode"
  91. :title-style="{fontSize:'1em'}"
  92. :label="userInfo&&userInfo.sysUserFlag == '0' ? item.createDate : (item.brandName +' '+item.modelName)">
  93. <text slot="icon"></text>
  94. </u-cell-item>
  95. <view style="padding: 20upx;">
  96. <u-empty :src="`/static/nodata.png`" icon-size="180" :text="noDataText" img-width="120" v-if="vinList.length==0 && status!='loading'" mode="list"></u-empty>
  97. <u-loadmore v-if="status=='loading'" :status="status" />
  98. </view>
  99. </u-cell-group>
  100. <view class="des" v-if="vinList.length&&hasLogin">仅展示最近5条记录,点击“全部”查看更多</view>
  101. <view class="des" v-if="!hasLogin">请登录后查看历史记录</view>
  102. </view>
  103. </view>
  104. </view>
  105. <u-tabbar :list="vuex_tabBarList" :before-switch="beforeSwitch" :mid-button="true"></u-tabbar>
  106. </view>
  107. </template>
  108. <script>
  109. import {
  110. mapState,
  111. mapMutations,
  112. } from 'vuex'
  113. import scrollBox from '@/components/scrollBox.vue'
  114. import UniStatusBar from '@/components/uni-status-bar/uni-status-bar.vue'
  115. import { shelfBondRecordWaitPayRecord, findStoreShelf, shelfGetTotalWaitQty, getProductfindByScanCode, queryQplsConfig } from '@/api/shelf.js'
  116. import { xprhStoreApplyRead } from '@/api/xprh.js'
  117. import { findCurrentRewardRule } from '@/api/rewardRule.js'
  118. import { listLookUp, getLookUpDatas, getCurrUserInfo } from '@/api/data.js';
  119. import { scanVinLogQueryRoll, getScanVinLogList, getScanGetMaxQty }from '@/api/car.js'
  120. import { promoTerminalList } from '@/api/video.js'
  121. import { getRewardRollList } from '@/api/rewardRule.js'
  122. import { openWebView } from "@/utils/index.js"
  123. export default {
  124. components: {
  125. scrollBox, // 无缝滚动组件
  126. UniStatusBar // 状态栏组件
  127. },
  128. data() {
  129. return {
  130. status: 'loading',
  131. noDataText: '暂无数据',
  132. bondRecord: null, // 保证金
  133. list:[], // 扫描记录滚动
  134. slist:[], // 红包滚动
  135. vinList: [], // 扫描记录
  136. orderTodo: null, // 待取货的货架订单信息
  137. avatarUrl:'', // 用户图像
  138. navHeight: '44', // 头部高度
  139. scanMaxNums: 10, // 扫描VIN仅限10次
  140. carouselList: [] // 修理厂促销活动列表
  141. }
  142. },
  143. computed: {
  144. ...mapState(['hasLogin','vuex_vinScanNums','vuex_tabBarList']),
  145. // 显示开发版本信息
  146. showVersion () {
  147. const baseUrl = getApp().globalData.baseUrl
  148. return baseUrl.indexOf(".test.") >= 0
  149. },
  150. // 是否有数字货架
  151. hasShelf(){
  152. return this.$store.state.vuex_storeShelf
  153. },
  154. // 登录用户信息
  155. userInfo(){
  156. return this.$store.state.vuex_userInfo
  157. },
  158. // 是否有门店申请信息
  159. storeApply(){
  160. return this.$store.state.vuex_storeAuthInfo || null
  161. },
  162. // 是否有红包
  163. hasRedPacket(){
  164. const rule = this.$store.state.vuex_rewardRule
  165. return rule&&rule.ruleStatus == 'release'
  166. },
  167. // banner 图片列表
  168. imgList(){
  169. let list = [
  170. {
  171. image: '/static/banner1.png',
  172. activeType: ''
  173. }
  174. ]
  175. if(this.hasRedPacket&&this.hasShelf){
  176. list.push(
  177. {
  178. image: '/static/banner2.png',
  179. activeType: 'redPacket'
  180. })
  181. }
  182. return list.concat(this.carouselList)
  183. }
  184. },
  185. onReady() {
  186. // 滚动扫描记录
  187. this.getScrollLog()
  188. // 获取导航栏高度
  189. const res = uni.getSystemInfoSync()
  190. const system = res.platform
  191. if (system === 'android') {
  192. this.navHeight = 48
  193. } else if (system === 'ios') {
  194. this.navHeight = 44
  195. }
  196. },
  197. onLoad() {
  198. this.orderTodo = null
  199. this.bondRecord = null
  200. this.vinList = []
  201. // 视频类型
  202. this.getLookUpList('CONTENT_CATEGORY', 'vuex_videoTypeList');
  203. // 检测是否登录
  204. this.$store.dispatch('checkLogin',()=>{
  205. // 获取数据字典
  206. this.getListLookUp();
  207. // 获取支付,收款方式
  208. this.getLookUpList('PAY_PROCUCT_TYPE', 'vuex_paymentTypeList');
  209. // 价格类型
  210. this.getLookUpList('PRICE_SHOW_TYPE', 'vuex_priceTypeList');
  211. // 初始化页面
  212. this.pageInit()
  213. // 查询红包活动
  214. this.getRedPacketRule()
  215. // 更新用户信息
  216. this.getCurrUserInfo()
  217. })
  218. // 刷新首页数据
  219. uni.$on("refashHome",()=>{
  220. this.pageInit()
  221. })
  222. },
  223. // 页面卸载
  224. onUnload() {
  225. uni.$off('refashHome')
  226. },
  227. // 下拉刷新
  228. onPullDownRefresh(){
  229. this.pageInit()
  230. setTimeout(function () {
  231. uni.stopPullDownRefresh();
  232. }, 1000);
  233. },
  234. onShareAppMessage() {},
  235. onShow() {
  236. // 用户头像
  237. this.avatarUrl = uni.getStorageSync('userPhoto');
  238. if(this.hasLogin){
  239. // 更新用户信息
  240. this.getCurrUserInfo()
  241. // 查询门店认证信息
  242. if(this.userInfo.sysUserFlag == '0'){
  243. this.findLastApply()
  244. }
  245. if(this.userInfo.sysUserFlag == '1'){
  246. // 查询红包活动
  247. this.getRedPacketRule()
  248. }
  249. }
  250. },
  251. methods: {
  252. // 扫描vin
  253. beforeSwitch(index){
  254. if(index==2){
  255. this.openCamera()
  256. }else{
  257. return true
  258. }
  259. },
  260. // 轮播图片
  261. getCarousel(){
  262. this.carouselList = []
  263. const storeShelf = this.$store.state.vuex_storeShelf
  264. promoTerminalList({sn:storeShelf.dealerSn}).then(res => {
  265. if(res.status == 200){
  266. res.data&&res.data.map(item => {
  267. item.image = item.imageSet&&item.imageSet[0] // 默认取第一张图片
  268. })
  269. // 过滤掉产品促销活动
  270. this.carouselList = res.data.filter(item => item.content.indexOf("pages/promo/index") < 0)
  271. }
  272. })
  273. },
  274. pageInit(){
  275. this.carouselList = []
  276. if(this.hasLogin){
  277. // 获取扫描记录
  278. this.getVinLog()
  279. // 非游客
  280. if(this.userInfo.sysUserFlag == '1'){
  281. // 查询是否有数字货架
  282. this.getStoreShelf()
  283. }else{
  284. // 获取扫描次数
  285. this.$store.dispatch("getScanNums")
  286. // 获取最大扫描次数
  287. this.getMaxQty()
  288. // 查询门店认证信息
  289. this.findLastApply()
  290. }
  291. }else{
  292. uni.removeStorageSync('token')
  293. }
  294. },
  295. // 获取数据字典
  296. getListLookUp() {
  297. const _this = this;
  298. listLookUp({ pageNo: 1, pageSize: 1000 }).then(res => {
  299. if (res.status == 200) {
  300. _this.$store.state.vuex_allLookUp = res.data;
  301. }
  302. });
  303. },
  304. // 或某一项字典列表,参数code
  305. getLookUpList(code, vuexKey) {
  306. getLookUpDatas({ type: code }).then(res => {
  307. if (res.status == 200) {
  308. this.$store.state[vuexKey] = res.data || [];
  309. }
  310. });
  311. },
  312. // 获取价格配置
  313. getPriceCofig(){
  314. const data = this.$store.state.vuex_storeShelf
  315. queryQplsConfig({shelfSn: data.shelfSn}).then(res => {
  316. this.$store.state.vuex_configPrice = res.data || null
  317. })
  318. },
  319. // 最新用户信息
  320. getCurrUserInfo(){
  321. getCurrUserInfo().then(res => {
  322. if(res.data){
  323. this.$store.state.vuex_userInfo.userNameCN = res.data.name;
  324. this.$store.state.vuex_userInfo.mobile = res.data.mobile;
  325. this.$store.state.vuex_userInfo.adminId = res.data.id;
  326. this.$store.state.vuex_userPhoto = res.data.photo;
  327. uni.setStorageSync('userPhoto', res.data.photo);
  328. }
  329. })
  330. },
  331. // 获取最大扫描数
  332. getMaxQty(){
  333. getScanGetMaxQty().then(res => {
  334. this.scanMaxNums = res.data || 10
  335. this.$store.state.vuex_scanMaxNums = this.scanMaxNums
  336. })
  337. },
  338. // 获取最新申请门店
  339. findLastApply(){
  340. const mobile = this.userInfo.mobile
  341. this.$store.dispatch('getSotreAuth',mobile)
  342. },
  343. // 知道审核不通过
  344. toKnow(){
  345. uni.showLoading({
  346. title: "正在提交"
  347. })
  348. xprhStoreApplyRead({sn:this.storeApply.applySn}).then(res => {
  349. if(res.status == 200){
  350. this.findLastApply()
  351. }
  352. uni.hideLoading()
  353. })
  354. },
  355. // 待取货数量合计
  356. shelfGetTotalWaitQty(){
  357. shelfGetTotalWaitQty({billState:'WAIT'}).then(res => {
  358. if(res.status == 200){
  359. this.orderTodo = res.data;
  360. }
  361. })
  362. },
  363. // 货架订单列表
  364. toOrder(){
  365. if(this.hasShelf){
  366. uni.navigateTo({
  367. url: "/pagesA/digitalShelf/orderList"
  368. })
  369. }else{
  370. uni.showToast({
  371. icon:'none',
  372. title: '门店没有关联数字货架,无法使用此功能!'
  373. })
  374. }
  375. },
  376. // 获取上方滚动扫描记录
  377. getScrollLog(){
  378. scanVinLogQueryRoll({pageNo:1,pageSize:50}).then(res => {
  379. console.log(res)
  380. this.list = res.data.list || []
  381. this.list.map(item => {
  382. item.placeText = item.userName + '刚刚扫描了一个VIN'
  383. })
  384. })
  385. },
  386. // 获取当前门店扫描记录
  387. getVinLog(){
  388. this.vinList = []
  389. this.status = "loading"
  390. // VISITOR:游客,EMPLOYEE:雇员
  391. getScanVinLogList({ pageNo:1, pageSize:5, identifyType: this.userInfo.identifyType }).then(res => {
  392. this.vinList = res.data&&res.data.list || []
  393. this.vinList = this.vinList.filter(item => item.vinCode)
  394. this.status = 'nomore'
  395. })
  396. },
  397. // 查询是否支持数字货架
  398. getStoreShelf(){
  399. findStoreShelf().then(res => {
  400. console.log(res)
  401. this.$store.state.vuex_storeShelf = res.data;
  402. if(res.data){
  403. // 获取价格权限配置
  404. this.getPriceCofig()
  405. // 保证金查询
  406. this.getShelfBWPayRecord()
  407. // 获取订单信息
  408. this.shelfGetTotalWaitQty()
  409. // 获取轮播数据
  410. this.getCarousel()
  411. }
  412. })
  413. },
  414. // 查询是有红包活动
  415. getRedPacketRule(){
  416. findCurrentRewardRule().then(res => {
  417. this.$store.state.vuex_rewardRule = res.data;
  418. this.getRedScroll()
  419. })
  420. },
  421. getRedScroll(){
  422. getRewardRollList({pageNo:1,pageSize:50}).then(res => {
  423. this.slist = res.data || []
  424. this.slist.map(item => {
  425. item.placeText = item.userName + '刚刚得到了'+item.totalRewardAmount+'元 红包奖励'
  426. })
  427. })
  428. },
  429. // 获取保证金金额
  430. getShelfBWPayRecord(){
  431. const data = this.$store.state.vuex_storeShelf
  432. shelfBondRecordWaitPayRecord({shelfSn: data.shelfSn, storeSn: data.storeSn}).then(res => {
  433. console.log(res,'获取保证金金额')
  434. this.bondRecord = res.data
  435. })
  436. },
  437. // 保证金支付
  438. toPayBondAmount(){},
  439. openTakeGood(index){
  440. // 已有数字货架
  441. if(this.hasShelf){
  442. this.clickAction(index)
  443. }else{
  444. uni.showToast({
  445. icon:'none',
  446. title: '门店没有关联数字货架,无法使用此功能!'
  447. })
  448. }
  449. },
  450. // 单击banner
  451. clickBanner(index){
  452. const row = this.imgList[index]
  453. // 红包
  454. if(row.activeType == 'redPacket'){
  455. uni.navigateTo({url:"/pages/morePage/redPacket"})
  456. }
  457. // 图文
  458. if(row.contentType == 'IMAGE_CONTENT'){
  459. uni.navigateTo({url:"/pagesA/activeDetail/index?sn="+row.promoActiveSn})
  460. }
  461. // 视频
  462. if(row.contentType == 'VIDEO'){
  463. uni.navigateTo({url:"/pages/videos/detail?form=banner&&sn="+row.promoActiveSn})
  464. }
  465. // 链接
  466. if(row.contentType == 'LINK'){
  467. openWebView({url:row.content})
  468. }
  469. },
  470. // 选择取货方式
  471. clickAction(index){
  472. const shelfSn = this.hasShelf.shelfSn
  473. const _this = this
  474. // 扫描
  475. if(index == 0){
  476. uni.scanCode({
  477. success: function (ret) {
  478. console.log(ret);
  479. const params = {
  480. codeType: ret.scanType == 'QR_CODE' ? 0 : 1
  481. }
  482. // 二维码
  483. if(ret.scanType == 'QR_CODE'){
  484. const result = ret.result.split("&")
  485. params.productSn = result[2] // 产品编码sn
  486. }else{
  487. params.qrCode = ret.result
  488. }
  489. uni.showLoading({
  490. title: "正在查询产品..."
  491. })
  492. // 确认取货
  493. getProductfindByScanCode(params).then(res => {
  494. if(res.status == 200 && res.data){
  495. if(res.data.currentInven){
  496. const billSource = ret.scanType == 'QR_CODE' ? 'qr_code': 'bar_code'
  497. const retData = Object.assign({shelfSn: shelfSn, billSource: billSource},res.data)
  498. _this.$store.state.vuex_tempData = retData
  499. uni.navigateTo({
  500. url: '/pagesA/queryByCode/confirmQh'
  501. })
  502. }else{
  503. uni.showModal({
  504. title: '提示',
  505. content: '产品库存为0,无法取货!',
  506. confirmText: '好的',
  507. showCancel: false
  508. })
  509. }
  510. }else{
  511. uni.showModal({
  512. title: '提示',
  513. content: '产品不属于此货架,请重新扫描!',
  514. confirmText: '好的',
  515. showCancel: false
  516. })
  517. }
  518. uni.hideLoading()
  519. })
  520. }
  521. });
  522. }else{
  523. // 按编码搜索
  524. uni.navigateTo({
  525. url: '/pagesA/queryByCode/queryByCode'
  526. })
  527. }
  528. },
  529. // 去扫描
  530. openCamera(){
  531. if(this.hasLogin){
  532. // 游客身份
  533. if(this.userInfo.sysUserFlag == '0'){
  534. // 最多扫10次
  535. if(this.vuex_vinScanNums < this.scanMaxNums){
  536. uni.navigateTo({
  537. url: "/pages/scan-frame/scan-frame"
  538. })
  539. }else{
  540. uni.showModal({
  541. title: '提示',
  542. content: '个人用户扫描VIN仅限10次,您的次数已用完!',
  543. confirmText: '好的',
  544. showCancel: false,
  545. success(res) {}
  546. })
  547. }
  548. }else{
  549. // 非游客,直接扫
  550. uni.navigateTo({
  551. url: "/pages/scan-frame/scan-frame"
  552. })
  553. }
  554. }else{
  555. uni.navigateTo({
  556. url: '/pages/login/login'
  557. })
  558. }
  559. },
  560. // 查看扫描记录
  561. toAllRecord(){
  562. uni.navigateTo({
  563. url: this.hasLogin ? "/pagesA/vinRecord/vinRecord" : '/pages/login/login'
  564. })
  565. },
  566. // 查看用户信息
  567. toUser(){
  568. if(this.hasLogin){
  569. // 用户详细信息 或 门店认证
  570. uni.navigateTo({
  571. url: this.userInfo.sysUserFlag == '1' ? '/pages/personData/personData' : '/pages/storeManage/storeAuth'
  572. })
  573. }else{
  574. uni.navigateTo({
  575. url: '/pages/login/login'
  576. })
  577. }
  578. },
  579. // 选择配件
  580. toChoosePart(item){
  581. item.text = item.modelInfo
  582. uni.navigateTo({
  583. url: "/pagesA/digitalShelf/choosePart?vinNumber="+item.vinCode+"&carList="+encodeURIComponent(JSON.stringify(item))+'&type=log'
  584. })
  585. }
  586. }
  587. }
  588. </script>
  589. <style lang="less">
  590. page{
  591. background-color: #ffffff;
  592. }
  593. .content {
  594. margin: 0;
  595. padding: 0;
  596. height: 100vh;
  597. display: flex;
  598. flex-direction: column;
  599. background-image: linear-gradient(#86defa 0%,#cdeff9 25%,#ffffff 40%);
  600. .header-box{
  601. z-index: 5;
  602. padding: 0em 1em;
  603. background: #066cff;
  604. .title{
  605. padding: 0;
  606. }
  607. }
  608. .cbody{
  609. flex-grow: 1;
  610. overflow-y: auto;
  611. overflow-x: hidden;
  612. }
  613. .body-box{
  614. padding: 0em 1em 0.8em;
  615. z-index: 4;
  616. .notices{
  617. padding: 0.5em 0 0;
  618. font-size: 0.9em;
  619. margin-top: 0.5rem;
  620. view{
  621. color: #ffaf46;
  622. max-width: 80%;
  623. }
  624. .text{
  625. color: #ffffff;
  626. margin-left: 1em;
  627. }
  628. }
  629. .action-button{
  630. padding:40upx 0 0 0;
  631. justify-content: space-between;
  632. > view{
  633. display: flex;
  634. align-items: center;
  635. color: #fff;
  636. border-radius: 10rpx;
  637. width: 49%;
  638. }
  639. .f1{
  640. background: #ff9800;
  641. }
  642. .f2{
  643. background: #2196f3;
  644. }
  645. .icons{
  646. font-size: 50rpx;
  647. color: #fff;
  648. width: 80rpx;
  649. height: 80rpx;
  650. text-align:center;
  651. display: flex;
  652. align-items: center;
  653. flex-direction: column;
  654. justify-content: center;
  655. }
  656. .tits{
  657. font-size:28rpx;
  658. }
  659. }
  660. .scanButton{
  661. margin: 0.8em 0 0.5em;
  662. padding: 0.5em;
  663. background: #066cff;
  664. color: #fff;
  665. font-size: 1.5em;
  666. border-radius: 5em;
  667. justify-content: center;
  668. &:active{
  669. opacity: 0.8;
  670. }
  671. }
  672. .quickButton{
  673. margin: 0.8em 0 0.5em;
  674. padding: 0.5em;
  675. background: #fff;
  676. color: #333;
  677. font-size: 1.5em;
  678. border-radius: 5em;
  679. justify-content: center;
  680. border:0.1rpx solid #eee;
  681. box-shadow: 1rpx 2rpx 5rpx #f8f8f8;
  682. &:active{
  683. opacity: 0.8;
  684. }
  685. }
  686. .ml10{
  687. margin-left: 0.4em;
  688. }
  689. }
  690. .bg-blue{
  691. position: relative;
  692. > view{
  693. z-index: 100;
  694. position: relative;
  695. }
  696. &::after{
  697. /* 这个伪类的作用就是一个圆弧的背景色 */
  698. width: 130%;
  699. height: 100%;
  700. position: absolute;
  701. /*设置水平居中*/
  702. left: -15%;
  703. /* 之所以left:20%,是因为width:140%,若width:160%,那么left:30%才能水平居中 */
  704. top: -20%;
  705. /*层叠顺序,最底层显示*/
  706. content: '';
  707. border-radius: 0 0 50% 50%;
  708. /*分别对应 左上 右上 右下 左下 可以修改成其它颜色*/
  709. background: linear-gradient(to bottom, #066cff, #1d77ff);
  710. }
  711. .userCard{
  712. position:relative;
  713. left:0;
  714. bottom:-1rem;
  715. padding:0.8em;
  716. background: #fff;
  717. border-radius: 0.5em;
  718. box-shadow: 0.3em 0.3em 1em #c4e5ee;
  719. .userCard-info{
  720. flex-grow:1;
  721. > view{
  722. &:last-child{
  723. margin-left: 0.5em;
  724. line-height: 1.5em;
  725. .user-name{
  726. font-size: 1rem;
  727. }
  728. >view{
  729. padding: 0.2em;
  730. }
  731. }
  732. }
  733. .user-info{
  734. flex-grow:1;
  735. }
  736. }
  737. .user-rz{
  738. font-size: 0.8rem;
  739. color:#58aff5;
  740. }
  741. }
  742. }
  743. .list-box{
  744. padding: 0 1em;
  745. overflow: auto;
  746. .des{
  747. text-align: center;
  748. padding: 1em 0;
  749. color: #999;
  750. font-size: 0.8em;
  751. }
  752. }
  753. }
  754. </style>