cardDetail.vue 24 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141
  1. <template>
  2. <view>
  3. <ujp-navbar title="会员卡详情" :isBack="isMe">
  4. <view slot="right" style="margin-right: 10px;">
  5. <view class="iconfont qr-code" @click="openModalBl=true">
  6. &#xe60d;
  7. </view>
  8. </view>
  9. </ujp-navbar>
  10. <u-mask :show="show" @click="show = false">
  11. <u-image width="100%" :mode="'widthFix'" src="@/assets/static/img/guide_point2.png"></u-image>
  12. </u-mask>
  13. <u-modal v-model="show2" :content="content2" @confirm="confirmShow2" :show-cancel-button="true"
  14. confirm-color="#00b962"></u-modal>
  15. <u-modal v-model="show3" :content="content3" @confirm="confirmShow3" :show-cancel-button="true"
  16. confirm-color="#00b962"></u-modal>
  17. <u-modal v-model="openModalBl" @confirm="confirmPhone" confirm-text="拨打电话" confirm-color="#606266"
  18. :show-cancel-button="true" ref="uModal" :asyncClose="true" title="客服电话" :content="content"
  19. :content-style="{fontSize: '24px',color: '#101010'}"></u-modal>
  20. <!-- 头部 -->
  21. <view class="header4" v-if="item.type==4">
  22. <view class="discount-card-4" >
  23. <img v-if="regUserCard.status==2" class="corner-mark" src="@/assets/img/nonactivated.png" alt="">
  24. <view class="top" >
  25. <view class="right-corner">
  26. <img class="rightCorner" src="@/assets/img/rightCorner.png" alt="">
  27. </view>
  28. </view>
  29. <view class="img">
  30. {{item.name}}
  31. </view>
  32. <view class="card-number2" v-if="regUserCard.status==2" >
  33. 湖北省内平台自营站点充电通用
  34. </view>
  35. <view class="card-number" v-if="regUserCard.status==2">
  36. 卡号:{{regUserCard.cardNo}}
  37. </view>
  38. <view class="progress" v-if="regUserCard.status==1">
  39. <view class="time">
  40. {{thisendTime(regUserCard.endTime)}}到期 剩余{{setValidity(thisdaysDistance(regUserCard.endTime))}}
  41. </view>
  42. <view class="electric-quantity" v-if="regUserCard.classify==2">
  43. 已用{{regUserCard.chargedDegree}}度 / 共{{regUserCard.chargeDegreeLimit}}度
  44. </view>
  45. </view>
  46. <ujp-line-progress v-if="regUserCard.status==1" active-color="#2979ff"
  47. :percent="thispercent(regUserCard)"></ujp-line-progress>
  48. </view>
  49. <img class="cardCover" src="@/assets/img/cardCover.png" alt="">
  50. </view>
  51. <view :class="{
  52. header:regUserCard.status==1,
  53. header2:regUserCard.status==2
  54. }" v-else >
  55. <view class="discount-card" >
  56. <img v-if="regUserCard.status==2" class="corner-mark" src="@/assets/img/nonactivated.png" alt="">
  57. <view class="top" v-if="regUserCard.status==2">
  58. <view class="right-corner">
  59. <img class="rightCorner" src="@/assets/img/rightCorner.png" alt="">
  60. <img class="icon" v-if="item.type==3" src="@/assets/img/mb-times@3x.png" alt="">
  61. <img class="picc" v-if="item.type==3" src="@/assets/img/picc.png" alt="">
  62. </view>
  63. </view>
  64. <view class="img">
  65. <img v-if="item.classify==1" src="@/assets/img/monthCard.png" alt="">
  66. <img v-else-if="item.classify==2&&item.serviceFeeDiscountRate==60" src="@/assets/img/0.6off.png"
  67. alt="">
  68. <img v-else-if="item.classify==2&&item.serviceFeeDiscountRate==50" src="@/assets/img/halfoff.png"
  69. alt="">
  70. <img v-else src="@/assets/img/monthCard.png" alt="">
  71. </view>
  72. <view class="card-number" v-if="regUserCard.status==2">
  73. 卡号:{{regUserCard.cardNo}}
  74. </view>
  75. <view class="progress" v-if="regUserCard.status==1">
  76. <view class="time">
  77. {{thisendTime(regUserCard.endTime)}}到期 剩余{{setValidity(thisdaysDistance(regUserCard.endTime))}}
  78. </view>
  79. <view class="electric-quantity" v-if="regUserCard.classify==2">
  80. 已用{{regUserCard.chargedDegree}}度 / 共{{regUserCard.chargeDegreeLimit}}度
  81. </view>
  82. </view>
  83. <ujp-line-progress v-if="regUserCard.status==1" active-color="#2979ff"
  84. :percent="thispercent(regUserCard)"></ujp-line-progress>
  85. <view class="bottom" v-if="regUserCard.status==1">
  86. <view class="right-corner">
  87. <img class="rightCorner" src="@/assets/img/rightCorner.png" alt="">
  88. <img v-if="item.type==3" class="icon" src="@/assets/img/mb-times@3x.png" alt="">
  89. <img v-if="item.type==3" class="picc" src="@/assets/img/picc.png" alt="">
  90. </view>
  91. </view>
  92. </view>
  93. <img class="cardCover" src="@/assets/img/cardCover.png" alt="">
  94. </view>
  95. <!-- 卡片信息 -->
  96. <view class="main" v-if="regUserCard.status==2">
  97. <view class="details">
  98. <view class="headline">
  99. <view class="title">
  100. 卡片信息
  101. </view>
  102. <view class="show" v-if="!this.showHide" @click="showHide=true">
  103. 显示<u-icon name="eye"></u-icon>
  104. </view>
  105. <view class="hide" v-if="this.showHide" @click="showHide=false">
  106. 隐藏<u-icon name="eye-off"></u-icon>
  107. </view>
  108. </view>
  109. <view class="content" v-if="this.showHide">
  110. <view class="item">
  111. <view class="item-title">
  112. 卡名
  113. </view>
  114. <view class="item-value">
  115. {{item.name}}
  116. </view>
  117. </view>
  118. <view class="item" v-if="item.type==4">
  119. <view class="item-title">
  120. 折扣率
  121. </view>
  122. <view class="item-value" style="
  123. ">
  124. {{item.remark}}
  125. </view>
  126. </view>
  127. <view class="item" v-else >
  128. <view class="item-title">
  129. 折扣率
  130. </view>
  131. <view class="item-value">
  132. {{regUserCard.classify==1?"服务费全免":""}}
  133. {{regUserCard.classify==2?"服务费"+(item.serviceFeeDiscountRate/10)+"折":""}}
  134. </view>
  135. </view>
  136. <view class="item">
  137. <view class="item-title">
  138. 规格
  139. </view>
  140. <view class="item-value" v-if="regUserCard.classify==1">
  141. 服务费全免 (有效期{{setValidity(item.periodOfValidity)}})
  142. </view>
  143. <view class="item-value" v-if="regUserCard.classify==2">
  144. 可用{{item.chargeDegreeLimit}}度(有效期{{setValidity(item.periodOfValidity)}})
  145. </view>
  146. </view>
  147. </view>
  148. </view>
  149. <!-- 按钮 -->
  150. <view class="btn" v-if="isMe">
  151. <button class="share" @click="show=true">转赠分享<img class="icon"
  152. src="@/assets/img/riLine-gift-2-line@3x.png" alt=""></button>
  153. <button class="activate" @click="show2Btn">立即激活</button>
  154. </view>
  155. <view class="btn2" v-else>
  156. <button class="get" @click="show2Btn">领用会员卡</button>
  157. </view>
  158. </view>
  159. <!-- 卡片信息 -->
  160. <view class="main" v-if="regUserCard.status==1">
  161. <view class="title">
  162. 会员信息
  163. </view>
  164. <view class="details">
  165. <view class="item">
  166. <view class="item-title">
  167. 会员昵称
  168. </view>
  169. <view class="item-value">
  170. {{userInfo.nickName}}
  171. </view>
  172. </view>
  173. <view class="item">
  174. <view class="item-title">
  175. 绑定账号
  176. </view>
  177. <view class="item-value">
  178. {{getphone(userInfo.phone)}}
  179. </view>
  180. </view>
  181. <view class="item">
  182. <view class="item-title">
  183. 绑定车辆
  184. </view>
  185. <view class="item-value">
  186. {{userInfo.carNum}}
  187. </view>
  188. </view>
  189. </view>
  190. <view class="title">
  191. 卡片信息
  192. </view>
  193. <view class="details">
  194. <view class="item">
  195. <view class="item-title">
  196. 卡状态
  197. </view>
  198. <view class="item-value">
  199. 已激活
  200. </view>
  201. </view>
  202. <view class="item">
  203. <view class="item-title">
  204. 卡名
  205. </view>
  206. <view class="item-value">
  207. {{item.name}}
  208. </view>
  209. </view>
  210. <view class="item" v-if="item.type==4">
  211. <view class="item-title">
  212. 折扣率
  213. </view>
  214. <view class="item-value" style="
  215. ">
  216. {{item.remark}}
  217. </view>
  218. </view>
  219. <view class="item" v-else>
  220. <view class="item-title">
  221. 折扣率
  222. </view>
  223. <view class="item-value" v-if="item.classify==1">
  224. 服务费全免
  225. </view>
  226. <view class="item-value" v-if="item.classify==2">
  227. {{item.serviceFeeDiscountRate/10}}折
  228. </view>
  229. </view>
  230. <view class="item">
  231. <view class="item-title">
  232. 规格
  233. </view>
  234. <view class="item-value" v-if="regUserCard.classify==1">
  235. 服务费全免 (有效期{{setValidity(item.periodOfValidity)}})
  236. </view>
  237. <view class="item-value" v-if="regUserCard.classify==2">
  238. 可用{{item.chargeDegreeLimit}}度(有效期{{setValidity(item.periodOfValidity)}})
  239. </view>
  240. </view>
  241. <view class="item">
  242. <view class="item-title">
  243. 有效期
  244. </view>
  245. <view class="item-value">
  246. {{regUserCard.startTime.substring(0,10)}}至{{regUserCard.endTime.substring(0,10)}}
  247. </view>
  248. </view>
  249. <view class="item" v-if="regUserCard.classify==2">
  250. <view class="item-title">
  251. 剩余度数
  252. </view>
  253. <view class="item-value">
  254. {{(regUserCard.chargeDegreeLimit-regUserCard.chargedDegree).toFixed(0)}}度
  255. </view>
  256. </view>
  257. <view class="item">
  258. <view class="item-title">
  259. 卡号
  260. </view>
  261. <view class="item-value">
  262. {{regUserCard.cardNo}}
  263. </view>
  264. </view>
  265. </view>
  266. <!-- 按钮 -->
  267. <button class="check" @click="gotoUrl('pages/article/details?code=FWF6ZK')">查看使用规则</button>
  268. </view>
  269. </view>
  270. </template>
  271. <script>
  272. // import * as API from '@/apis/index.js'
  273. import * as API from '@/apis/order.js'
  274. import * as API_weixin from '@/apis/weixin.js'
  275. import wx from 'weixin-js-sdk'
  276. import {
  277. newDate,
  278. daysDistance
  279. } from '@/utils'
  280. export default {
  281. data() {
  282. return {
  283. id: "",
  284. item: {},
  285. regUserCard: {},
  286. orderInfo: {},
  287. content: "400-8899-619",
  288. openModalBl: false,
  289. expireUserCardList: [],
  290. showHide: false,
  291. show2: false,
  292. show: false,
  293. content2: '确认激活此会员卡吗?',
  294. content3: '领用会员卡需要注册成为会员,点击前往',
  295. show3: false,
  296. //userCard: {},
  297. isMe: false,
  298. projectName: "",
  299. userInfo: {},
  300. carNum: ""
  301. }
  302. },
  303. onLoad(op) {
  304. this.id = op.id
  305. this.get_wx_config();
  306. //this.userInfo=this.carhelp.getPersonInfo()
  307. this.projectName = process.car.ProjectName;
  308. var info = this.carhelp.getPersonInfo()
  309. if (info.id && info.userType == 2) {
  310. } else {
  311. this.show3 = true
  312. }
  313. this.getChargeList();
  314. },
  315. onReady() {
  316. var consumerPhone = "400-8899-619"
  317. // img="https://yktwechat.xiaoxinda.com/config/xxd2021.jpg"
  318. if (consumerPhone) {
  319. this.content = consumerPhone
  320. }
  321. },
  322. methods: {
  323. getphone(phone) {
  324. var phoneget = ""
  325. if (phone) {
  326. var phone1 = phone.slice(0, 3);
  327. var phone2 = phone.slice(-4);
  328. phoneget = phone1 + '****' + phone2;
  329. }
  330. return phoneget;
  331. },
  332. show2Btn() {
  333. var info = this.carhelp.getPersonInfo()
  334. if (info.id && info.userType == 2) {
  335. this.show2 = true
  336. } else {
  337. this.show3 = true
  338. }
  339. },
  340. confirmShow3() {
  341. uni.navigateTo({
  342. url: "/pages/login/login?jpcode2=card&codeId=" + this.id
  343. })
  344. },
  345. confirmShow2() {
  346. uni.showLoading({
  347. title: "加载中",
  348. mask: true,
  349. })
  350. API.activateCard({
  351. id: this.id
  352. }).then((res) => {
  353. uni.hideLoading();
  354. uni.showToast({
  355. title: "领取成功"
  356. })
  357. this.getChargeList();
  358. //console.log(obj)
  359. //this.recordsTotal = res.data.recordsTotal;
  360. }).catch(error => {
  361. uni.showToast({
  362. title: error,
  363. icon: "none"
  364. })
  365. })
  366. },
  367. //获取微信jssdk配置信息
  368. get_wx_config() {
  369. //("get_wx_configget_wx_configget_wx_configget_wx_config")
  370. var _this = this
  371. API_weixin.getConfig().then(response => {
  372. var wxconfig = response.data.wxConfig;
  373. console.log(222)
  374. wx.config({
  375. debug: false, // 开启调试模式,
  376. appId: wxconfig.appId, // 必填,企业号的唯一标识,此处填写企业号corpid
  377. timestamp: wxconfig.timestamp, // 必填,生成签名的时间戳
  378. nonceStr: wxconfig.nonceStr, // 必填,生成签名的随机串
  379. signature: wxconfig.signature, // 必填,签名,见附录1
  380. jsApiList: ['updateAppMessageShareData',
  381. 'updateTimelineShareData', 'onMenuShareTimeline', 'onMenuShareAppMessage',
  382. 'onMenuShareQQ', 'onMenuShareQZone'
  383. ], // 必填,需要使用的JS接口列表,所有JS接口列表见附录2
  384. });
  385. console.log(222)
  386. _this.wxShare()
  387. wx.error(function(res) {
  388. console.log('微信api配置出错');
  389. });
  390. }).catch(error => {
  391. //(error);
  392. })
  393. },
  394. //微信分享自定义
  395. wxShare() {
  396. console.log(111)
  397. var img =
  398. "http://oss.xiaoxinda.com/charging/chargingconfigure/2022/6/6/ec228c56-487a-4ae1-ac6f-37284060fbba/hongbao.jpg"
  399. // img="https://yktwechat.xiaoxinda.com/config/xxd2021.jpg"
  400. // if (indexLogo) {
  401. // this.indexLogo = indexLogo;
  402. // }
  403. var info = this.carhelp.getPersonInfo()
  404. //var img=require("@/static/img/aboutus.png")
  405. ////(this.nowItem);
  406. var ProjectName = process.car.ProjectName; //info.nickName+
  407. var nickName = info.nickName ? info.nickName : '好友';
  408. var title = nickName + "赠送您一张"
  409. if(this.item.type==4){
  410. title += "'"+this.projectName+this.item.name+"'"
  411. }else if (this.item.classify == 1) {
  412. title += "'服务费月卡'"
  413. } else if (this.item.classify == 2 && this.item.serviceFeeDiscountRate == 60) {
  414. title += "'服务费6折卡'"
  415. } else if (this.item.classify == 2 && this.item.serviceFeeDiscountRate == 50 && this.item
  416. .periodOfValidity == 365) {
  417. title += "'充电5折卡年卡'"
  418. } else if (this.item.classify == 2 && this.item.serviceFeeDiscountRate == 50) {
  419. title += "'服务费5折卡'"
  420. }
  421. var desc = ProjectName
  422. let joinUrl = window.location.href.split("/team51/")[0] + "/team51/#/pages/cardBag/cardDetail?id=" + this
  423. .id
  424. //this.joinUrl=joinUrl;
  425. var _this = this;
  426. wx.ready(function() {
  427. wx.onMenuShareAppMessage({
  428. title: title,
  429. desc: desc,
  430. link: joinUrl,
  431. imgUrl: img,
  432. success: function() {
  433. // 设置成功
  434. _this.$emit("wxShare", null);
  435. }
  436. })
  437. wx.onMenuShareTimeline({
  438. title: title,
  439. desc: desc,
  440. link: joinUrl,
  441. imgUrl: img,
  442. success: function() {
  443. // 设置成功
  444. _this.$emit("wxShare", null);
  445. }
  446. })
  447. wx.updateAppMessageShareData({
  448. title: title,
  449. desc: desc,
  450. link: joinUrl,
  451. imgUrl: img,
  452. success: function() {
  453. //("updateAppMessageShareData")
  454. // 设置成功
  455. _this.$emit("wxShare", null);
  456. }
  457. })
  458. wx.updateTimelineShareData({
  459. title: title,
  460. desc: desc,
  461. link: joinUrl,
  462. imgUrl: img,
  463. success: function() {
  464. //("updateTimelineShareData")
  465. // 设置成功
  466. _this.$emit("wxShare", null);
  467. }
  468. })
  469. console.log("readyreadyreadyreadyready")
  470. });
  471. },
  472. thisendTime(endTime) {
  473. if (endTime) {
  474. var reg = new RegExp('-', 'gi')
  475. var str = endTime.substring(0, 10).replace(reg, '.')
  476. return str
  477. }
  478. return ''
  479. },
  480. thispercent(userCard) {
  481. if (userCard.classify == 1) {
  482. var k1 = daysDistance(userCard.startTime, userCard.endTime)
  483. var k2 = this.thisdaysDistance(userCard.endTime)
  484. var p = (k1 - k2) / k2 * 100
  485. if (p > 100) {
  486. p = 100
  487. }
  488. return p.toFixed(0)
  489. } else if (userCard.classify == 2) {
  490. var p = 0
  491. if (userCard && userCard.chargeDegreeLimit) {
  492. p = userCard.chargedDegree / userCard.chargeDegreeLimit * 100
  493. }
  494. if (p > 100) {
  495. p = 100
  496. }
  497. return p.toFixed(0)
  498. } else {
  499. return 0
  500. }
  501. },
  502. thisdaysDistance(endTime) {
  503. var date = new Date()
  504. var date2 = newDate(endTime);
  505. return daysDistance(date, date2)
  506. },
  507. thisdaysDistance2() {
  508. if (this.item.endTime) {
  509. var date = newDate(this.item.startTime)
  510. var date2 = newDate(this.item.endTime);
  511. return daysDistance(date, date2)
  512. }
  513. return 0
  514. },
  515. regUserCarList() {
  516. uni.showLoading({
  517. title: "加载中",
  518. mask: true,
  519. })
  520. API.regUserCarList({
  521. id: this.id
  522. }).then((res) => {
  523. uni.hideLoading();
  524. if (res.data && res.data.length) {
  525. this.carNum = res.data[0].carNum
  526. }
  527. //this.recordsTotal = res.data.recordsTotal;
  528. }).catch(error => {
  529. uni.showToast({
  530. title: error,
  531. icon: "none"
  532. })
  533. })
  534. },
  535. getChargeList() {
  536. uni.showLoading({
  537. title: "加载中",
  538. mask: true,
  539. })
  540. API.buyCardDetail({
  541. id: this.id
  542. }).then((res) => {
  543. uni.hideLoading();
  544. this.item = res.data.monthlyRentCard;
  545. this.regUserCard = res.data.regUserCard;
  546. // if(this.regUserCard.status==1){
  547. // this.regUserCarList()
  548. // }
  549. this.userInfo = res.data.buyUser;
  550. var info = this.carhelp.getPersonInfo()
  551. if (info && info.id && info.id == this.regUserCard.regUserId) {
  552. this.isMe = true
  553. }
  554. this.orderInfo = res.data.orderInfo;
  555. //console.log(obj)
  556. //this.recordsTotal = res.data.recordsTotal;
  557. }).catch(error => {
  558. uni.showToast({
  559. title: error,
  560. icon: "none"
  561. })
  562. })
  563. },
  564. confirmPhone() {
  565. this.openModalBl = false;
  566. uni.makePhoneCall({
  567. phoneNumber: this.content //仅为示例
  568. });
  569. },
  570. }
  571. }
  572. </script>
  573. <style lang="scss" scoped>
  574. page {
  575. background-color: #fff;
  576. }
  577. // 头部
  578. .header4 {
  579. padding: 24rpx 32rpx 0;
  580. opacity: 0.9;
  581. background: linear-gradient(30deg, rgba(59, 182, 254, 1) 13.4%, rgba(0, 185, 98, 1) 85.87%);
  582. position: relative;
  583. .discount-card-4 {
  584. background: url(@/assets/img/card/lovecn.jpg);
  585. background-size: 686rpx 400rpx;
  586. border-radius: 8px 8px 0 0;
  587. // background-color: #1D1F2A;
  588. padding: 40rpx;
  589. margin-top: 24rpx;
  590. height: 400rpx;
  591. position: relative;
  592. .corner-mark {
  593. width: 128rpx;
  594. height: 128rpx;
  595. position: absolute;
  596. top: 0;
  597. right: 0;
  598. }
  599. .img {
  600. margin-top: 120rpx;
  601. color: rgba(255, 214, 149, 1);
  602. font-size: 48rpx;
  603. font-family: "SimSun", Arial, sans-serif;
  604. font-weight: 400;
  605. text-shadow: 2px 1px 0px #800400 ;
  606. }
  607. .u-progress {
  608. //height: 20rpx !important;
  609. background-color: rgb(207, 76, 66) !important;
  610. color: #fff;
  611. }
  612. .progress {
  613. display: flex;
  614. justify-content: space-between;
  615. color: #FFF;
  616. font-size: 24rpx;
  617. margin-bottom: 16rpx;
  618. //margin-top: 24rpx;
  619. }
  620. ::v-deep .u-active {
  621. background: linear-gradient(84.49deg, rgba(59, 182, 254, 1) 4.25%, rgba(0, 185, 98, 1) 95.02%);
  622. }
  623. .top {
  624. .right-corner {
  625. display: flex;
  626. align-items: center;
  627. height: 36rpx;
  628. .rightCorner {
  629. width: 168rpx;
  630. margin-left: 8rpx;
  631. }
  632. .icon {
  633. width: 24rpx;
  634. height: 24rpx;
  635. margin-left: 8rpx;
  636. }
  637. .picc {
  638. width: 124rpx;
  639. height: 32rpx;
  640. margin-left: 8rpx;
  641. }
  642. }
  643. }
  644. // 右下角角标
  645. .bottom {
  646. position: absolute;
  647. bottom: 48rpx;
  648. right: 40rpx;
  649. .right-corner {
  650. display: flex;
  651. align-items: center;
  652. justify-content: flex-end;
  653. height: 32rpx;
  654. .rightCorner {
  655. width: 148rpx;
  656. }
  657. .icon {
  658. width: 24rpx;
  659. height: 24rpx;
  660. margin-left: 8rpx;
  661. }
  662. .picc {
  663. width: 124rpx;
  664. margin-left: 8rpx;
  665. }
  666. }
  667. }
  668. }
  669. .cardCover {
  670. width: 100%;
  671. height: 70rpx;
  672. position: absolute;
  673. left: 0;
  674. right: 0;
  675. bottom: 0rpx;
  676. z-index: 999;
  677. }
  678. .card-number2{
  679. font-size: 24rpx;
  680. color: rgba(255, 255, 255, 1);
  681. }
  682. .card-number{
  683. font-size: 28rpx;
  684. color: rgba(255, 255, 255, 1);
  685. }
  686. }
  687. // 头部
  688. .header {
  689. padding: 24rpx 32rpx 0;
  690. opacity: 0.9;
  691. background: linear-gradient(30deg, rgba(59, 182, 254, 1) 13.4%, rgba(0, 185, 98, 1) 85.87%);
  692. position: relative;
  693. .discount-card {
  694. background: url(@/assets/img/cardDetail.png);
  695. background-size: 686rpx 400rpx;
  696. border-radius: 8px 8px 0 0;
  697. background-color: #1D1F2A;
  698. padding: 24rpx;
  699. margin-top: 24rpx;
  700. height: 400rpx;
  701. position: relative;
  702. .corner-mark {
  703. width: 128rpx;
  704. height: 128rpx;
  705. position: absolute;
  706. top: 0;
  707. right: 0;
  708. }
  709. .img {
  710. width: 262rpx;
  711. height: 56rpx;
  712. img {
  713. width: 100%;
  714. }
  715. }
  716. .u-progress {
  717. height: 20rpx !important;
  718. }
  719. .progress {
  720. display: flex;
  721. justify-content: space-between;
  722. color: rgba(219, 219, 219, 1);
  723. font-size: 24rpx;
  724. margin-bottom: 16rpx;
  725. margin-top: 24rpx;
  726. }
  727. ::v-deep .u-active {
  728. background: linear-gradient(84.49deg, rgba(59, 182, 254, 1) 4.25%, rgba(0, 185, 98, 1) 95.02%);
  729. }
  730. .top {
  731. .right-corner {
  732. display: flex;
  733. align-items: center;
  734. height: 36rpx;
  735. .rightCorner {
  736. width: 148rpx;
  737. margin-left: 8rpx;
  738. }
  739. .icon {
  740. width: 24rpx;
  741. height: 24rpx;
  742. margin-left: 8rpx;
  743. }
  744. .picc {
  745. width: 124rpx;
  746. height: 32rpx;
  747. margin-left: 8rpx;
  748. }
  749. }
  750. }
  751. // 右下角角标
  752. .bottom {
  753. position: absolute;
  754. bottom: 48rpx;
  755. right: 40rpx;
  756. .right-corner {
  757. display: flex;
  758. align-items: center;
  759. justify-content: flex-end;
  760. height: 32rpx;
  761. .rightCorner {
  762. width: 148rpx;
  763. }
  764. .icon {
  765. width: 24rpx;
  766. height: 24rpx;
  767. margin-left: 8rpx;
  768. }
  769. .picc {
  770. width: 124rpx;
  771. margin-left: 8rpx;
  772. }
  773. }
  774. }
  775. }
  776. .cardCover {
  777. width: 100%;
  778. height: 70rpx;
  779. position: absolute;
  780. left: 0;
  781. right: 0;
  782. bottom: 0rpx;
  783. z-index: 999;
  784. }
  785. }
  786. .header2 {
  787. padding: 24rpx 32rpx 0;
  788. opacity: 0.9;
  789. background: linear-gradient(30deg, rgba(59, 182, 254, 1) 13.4%, rgba(0, 185, 98, 1) 85.87%);
  790. position: relative;
  791. .discount-card {
  792. background: url(@/assets/img/cardDetail.png);
  793. background-size: 686rpx 400rpx;
  794. border-radius: 8px 8px 0 0;
  795. background-color: #1D1F2A;
  796. padding: 24rpx;
  797. margin-top: 24rpx;
  798. height: 400rpx;
  799. position: relative;
  800. .corner-mark {
  801. width: 128rpx;
  802. height: 128rpx;
  803. position: absolute;
  804. top: 0;
  805. right: 0;
  806. }
  807. .img {
  808. margin: 82rpx auto 0;
  809. width: 486rpx;
  810. height: 104rpx;
  811. img {
  812. width: 100%;
  813. }
  814. }
  815. .top {
  816. .right-corner {
  817. display: flex;
  818. align-items: center;
  819. height: 36rpx;
  820. .rightCorner {
  821. width: 148rpx;
  822. margin-left: 8rpx;
  823. }
  824. .icon {
  825. width: 24rpx;
  826. height: 24rpx;
  827. margin-left: 8rpx;
  828. }
  829. .picc {
  830. width: 124rpx;
  831. height: 32rpx;
  832. margin-left: 8rpx;
  833. }
  834. }
  835. }
  836. }
  837. .cardCover {
  838. width: 100%;
  839. height: 70rpx;
  840. position: absolute;
  841. left: 0;
  842. right: 0;
  843. bottom: 0rpx;
  844. z-index: 999;
  845. }
  846. .card-number {
  847. color: rgba(209, 178, 121, 1);
  848. text-align: center;
  849. margin-top: 8rpx;
  850. }
  851. }
  852. // 卡片信息
  853. .main {
  854. background-color: #fff;
  855. padding: 32rpx;
  856. padding-bottom: 60px;
  857. .headline {
  858. display: flex;
  859. justify-content: space-between;
  860. align-items: center;
  861. font-size: 32rpx;
  862. .title {
  863. color: rgba(16, 16, 16, 1);
  864. }
  865. .show,
  866. .hide {
  867. color: rgba(119, 119, 119, 1);
  868. }
  869. }
  870. .title {
  871. color: rgba(16, 16, 16, 1);
  872. font-size: 32rpx;
  873. }
  874. .details {
  875. margin-top: 16rpx;
  876. border-radius: 12px;
  877. padding: 32rpx 24rpx;
  878. background-color: rgba(255, 255, 255, 1);
  879. text-align: center;
  880. border: 1px solid rgba(226, 226, 226, 1);
  881. margin-bottom: 40rpx;
  882. .item {
  883. display: flex;
  884. margin-top: 24rpx;
  885. .item-title {
  886. min-width: 128rpx;
  887. color: #777777;
  888. text-align: left;
  889. }
  890. .item-value {
  891. margin-left: 16rpx;
  892. color: #101010;
  893. text-align: start;
  894. }
  895. }
  896. }
  897. .btn2 {
  898. margin-top: 32rpx;
  899. .get {
  900. border-radius: 50px;
  901. background: linear-gradient(90deg, rgba(0, 171, 91, 1) 0%, rgba(0, 209, 66, 1) 100%);
  902. color: rgba(255, 255, 255, 1);
  903. font-size: 16px;
  904. text-align: center;
  905. }
  906. }
  907. //按钮
  908. .btn {
  909. margin-top: 32rpx;
  910. display: flex;
  911. justify-content: space-between;
  912. .share {
  913. width: 328rpx;
  914. height: 88rpx;
  915. line-height: 88rpx;
  916. border-radius: 50px;
  917. background-color: rgba(255, 255, 255, 1);
  918. text-align: center;
  919. border: 1px solid rgba(255, 150, 0, 1);
  920. color: rgba(255, 150, 0, 1);
  921. font-size: 32rpx;
  922. display: flex;
  923. align-items: center;
  924. justify-content: center;
  925. .icon {
  926. width: 36rpx;
  927. height: 36rpx;
  928. }
  929. }
  930. .activate {
  931. width: 328rpx;
  932. height: 88rpx;
  933. line-height: 88rpx;
  934. border-radius: 50px;
  935. background: linear-gradient(90deg, rgba(0, 171, 91, 1) 0%, rgba(0, 209, 66, 1) 100%);
  936. color: rgba(255, 255, 255, 1);
  937. font-size: 32rpx
  938. }
  939. }
  940. }
  941. // 查看
  942. .check {
  943. position: fixed;
  944. bottom: 32rpx;
  945. left: 32rpx;
  946. right: 32rpx;
  947. font-size: 32rpx;
  948. border-radius: 50px;
  949. background-color: rgba(255, 255, 255, 1);
  950. color: rgba(0, 185, 98, 1);
  951. border: 1px solid rgba(0, 185, 98, 1);
  952. }
  953. </style>