member.vue 27 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056
  1. <template>
  2. <view class="container clearfix">
  3. <view class="cm-member-top">
  4. <view
  5. class="cm-member-cel"
  6. v-if="userVip.vipFlag == 1 || userVip.vipFlag == -1"
  7. @click="hanldPayUrl('/pages/user/member/member-record')"
  8. >购买记录</view
  9. >
  10. <view class="cm-member-head">
  11. <view class="cm-member-text" v-if="isRequest">
  12. <view class="cm-member-h1">
  13. <text v-if="userVip.vipFlag == 0">采美·超级会员</text>
  14. <text v-if="userVip.vipFlag == 1">已开通采美·超级会员</text>
  15. <text v-if="userVip.vipFlag == -1">采美·超级会员已过期</text>
  16. </view>
  17. <view class="cm-member-p">
  18. <text v-if="userVip.vipFlag == 0">享专属特权</text>
  19. <text v-else>有效期至:{{ userVip.time }}</text>
  20. </view>
  21. </view>
  22. <view class="cm-member-btn" v-if="userVip.vipFlag == 1 || userVip.vipFlag == -1">
  23. <view class="btn" @click="hanldPayUrl('/pages/user/member/member-renew')">续费</view>
  24. </view>
  25. </view>
  26. </view>
  27. <view class="cm-member-main" v-if="userVip.vipFlag == 0 || userVip.vipFlag == -1">
  28. <view class="title">超级会员套餐</view>
  29. <view class="cm-member-pay">
  30. <view
  31. class="pay-item"
  32. v-for="(pay, index) in payList"
  33. :key="index"
  34. :class="{ current: tabCurrent === index }"
  35. @click="handleCheckedPay(index, pay)"
  36. >
  37. <view class="hot" v-if="index == 0">推荐</view> <view class="text-1">{{ pay.duration }}个月</view>
  38. <view class="text-2"> <text>¥</text>{{ pay.price }}</view>
  39. <view class="text-3" v-if="index == 0 || index == 1">{{ pay.price / pay.duration }}元/月</view>
  40. </view>
  41. </view>
  42. <view class="cm-member-button" v-if="!popupShow">
  43. <view class="pay-btn pay" @click="hanldWechatPay">立即支付{{ handelPayMsg.price }}元开通</view>
  44. <view class="pay-btn none" @click="hanldeShowBeans">或抵扣{{ handelPayMsg.beans }}个采美豆开通</view>
  45. </view>
  46. </view>
  47. <view class="cm-member-main">
  48. <view class="title">专属特权</view>
  49. <view class="cm-member-privilege clearfix">
  50. <view class="privilege-item" v-for="(priv, index) in privilegeList" :key="index">
  51. <image class="image" :src="priv.icon" mode=""></image>
  52. <view class="text-2">{{ priv.privText }}</view> <view class="text-3">{{ priv.privName }}</view>
  53. </view>
  54. </view>
  55. </view>
  56. <view class="cm-member-main" v-if="productCouponList.length > 0">
  57. <view class="title">专属优惠券<text class="small">每月可领4个</text></view>
  58. <view class="cm-member-coupon clearfix">
  59. <view
  60. v-for="(coupon, index) in productCouponList"
  61. :key="index"
  62. :id="coupon.couponId"
  63. class="coupon-list"
  64. :class="coupon.useStatus == 2 ? 'none' : ''"
  65. >
  66. <view class="list-cell-tags">{{ coupon.couponType | TypeFormat }}</view>
  67. <view class="list-cell-le">
  68. <view class="coupon-maxMoney"><text class="small">¥</text>{{ coupon.couponAmount }}</view>
  69. <view class="coupon-minMoney">满{{ coupon.touchPrice }}可用</view>
  70. <view class="coupon-texts">
  71. <text v-if="coupon.couponType == 0">
  72. {{
  73. coupon.productType && coupon.productType == 1
  74. ? '全商城商品通用'
  75. : '仅可购买指定商品'
  76. }}
  77. </text>
  78. <text v-if="coupon.couponType == 1">
  79. {{ coupon.categoryType == 1 ? '仅限购买产品类商品' : '仅限购买仪器类商品' }}
  80. </text>
  81. <text v-if="coupon.couponType == 3">仅限购买店铺【...】</text>
  82. <text v-if="coupon.couponType == 4 || coupon.couponType == 2">全商城商品通用</text>
  83. </view>
  84. </view>
  85. <view class="list-cell-ri">
  86. <template v-if="coupon.useStatus == 2">
  87. <view class="icon-used-btn make">已使用</view>
  88. </template>
  89. <template v-else>
  90. <view
  91. class="icon-used-btn receive"
  92. v-if="coupon.getFlag == 0"
  93. @click="receiveCoupon(coupon)"
  94. >立即领取</view
  95. >
  96. <view class="icon-used-btn make" v-if="coupon.getFlag == 1" @click="toUseCoupon(coupon)">
  97. 去使用</view
  98. >
  99. </template>
  100. </view>
  101. </view>
  102. </view>
  103. </view>
  104. <view class="cm-member-main none" :style="{ paddingBottom: popupShow ? '260rpx' : '0rpx' }">
  105. <view class="title">
  106. 优惠商品
  107. <view class="more" @click="hanldPayUrl('/pages/user/member/member-product')"
  108. >更多<text class="iconfont icon-xiayibu"></text
  109. ></view>
  110. </view>
  111. <view class="cm-member-product clearfix">
  112. <view
  113. v-for="(pro, index) in productList"
  114. :key="index"
  115. :id="pro.productId"
  116. class="product-list"
  117. @click="productDetail(pro.productId)"
  118. >
  119. <view class="product-image"> <image :src="pro.image" mode=""></image> </view>
  120. <view class="product-mains">
  121. <view class="product-name"> {{ pro.name }} </view>
  122. <view class="product-tags">
  123. <view class="floor-item-act">
  124. <view class="coupon-tags" v-if="pro.couponsLogo">优惠券</view>
  125. <template v-if="pro.actStatus == 1">
  126. <view class="floor-tags" v-if="PromotionsFormat(pro.promotions)">
  127. {{ pro.promotions.name }}
  128. <text v-if="pro.priceFlag != 1">:¥{{ pro.price | NumFormat }}</text>
  129. </view>
  130. <view class="floor-tags" v-else>{{ pro.promotions.name }}</view>
  131. </template>
  132. <template v-if="pro.svipProductFlag == 1">
  133. <view class="svip-tags">
  134. <view class="tags" :class="{ none: userVip.vipFlag == 0 }">SVIP</view>
  135. <view class="price" v-if="isShowVipFlag(pro)">{{ pro.svipPriceTag }}</view>
  136. </view>
  137. </template>
  138. </view>
  139. </view>
  140. <view class="product-price">
  141. <view class="list-none" v-if="pro.priceFlag == 1">¥未公开价格</view>
  142. <template v-else>
  143. <view
  144. class="list-none"
  145. v-if="pro.priceFlag == 2 && (userIdentity == 4 && userVip.vipFlag == 0)"
  146. >¥价格仅会员可见</view
  147. >
  148. <view class="list-none-price" v-else>¥{{ pro.originalPrice | NumFormat }}</view>
  149. </template>
  150. </view>
  151. </view>
  152. </view>
  153. </view>
  154. </view>
  155. <!-- 透明模态层 -->
  156. <modal-layer v-if="isModallayer"></modal-layer>
  157. <!-- 弹窗 -->
  158. <template>
  159. <view class="cm-model-alert" v-if="isShowBeansModal">
  160. <view class="content">
  161. <view class="title">
  162. <text>购买超级会员</text>
  163. <text class="iconfont icon-iconfontguanbi" @click.stop="handelCanelBeans"></text>
  164. </view>
  165. <view class="text-content">
  166. <view class="text"
  167. >确定使用<text class="text-p">{{ handelPayMsg.beans }}</text
  168. >个采美豆抵扣{{ handelPayMsg.duration }}个月的采美超级会员吗?</view
  169. >
  170. </view>
  171. <view class="text-button">
  172. <view class="btn btn-cancel" @click="handelCanelBeans">取消</view>
  173. <view class="btn btn-confirm" @click="handelConfirmBeans">确定</view>
  174. </view>
  175. </view>
  176. </view>
  177. </template>
  178. <!-- 悬浮按钮 -->
  179. <tui-bottom-popup :radius="false" :mask="false" :show="popupShow">
  180. <view class="tui-popup-box clearfix" :style="{ paddingBottom: isIphoneX ? '68rpx' : '34rpx' }">
  181. <view class="cm-member-button">
  182. <view class="pay-btn pay" @click="hanldWechatPay">立即支付{{ handelPayMsg.price }}元开通</view>
  183. <view class="pay-btn none" @click="hanldeShowBeans"
  184. >或抵扣{{ handelPayMsg.beans }}个采美豆开通</view
  185. >
  186. </view>
  187. </view>
  188. </tui-bottom-popup>
  189. </view>
  190. </template>
  191. <script>
  192. import { mapState, mapMutations } from 'vuex'
  193. import modalLayer from '@/components/modal-layer'
  194. export default {
  195. components: {
  196. modalLayer
  197. },
  198. data() {
  199. return {
  200. StaticUrl: this.$Static,
  201. isIphoneX: this.$store.state.isIphoneX,
  202. isRequest: false,
  203. isModallayer: false,
  204. isShowBeansModal: false,
  205. popupShow: false,
  206. memberType: 0,
  207. tabCurrent: 0,
  208. userIdentity: 0,
  209. userVip: {},
  210. handelPayMsg: {
  211. beans: 0,
  212. price: 0,
  213. month: '',
  214. packageId: 0
  215. },
  216. payParam: {
  217. userId: 0,
  218. packageId: 0
  219. },
  220. payList: [],
  221. privilegeList: [
  222. {
  223. icon: 'https://static.caimei365.com/app/img/icon/icon-member-prer1@2x.png',
  224. privText: '优惠商品',
  225. privName: '超级会员专享'
  226. },
  227. {
  228. icon: 'https://static.caimei365.com/app/img/icon/icon-member-prer2@2x.png',
  229. privText: '专属优惠券',
  230. privName: '超级会员专享'
  231. },
  232. {
  233. icon: 'https://static.caimei365.com/app/img/icon/icon-member-prer3@2x.png',
  234. privText: '采美豆翻倍',
  235. privName: '下单返采美豆'
  236. },
  237. {
  238. icon: 'https://static.caimei365.com/app/img/icon/icon-member-prer4@2x.png',
  239. privText: '专属客服',
  240. privName: '一对一'
  241. },
  242. {
  243. icon: 'https://static.caimei365.com/app/img/icon/icon-member-prer5@2x.png',
  244. privText: '专属销售顾问',
  245. privName: '一对一'
  246. },
  247. {
  248. icon: 'https://static.caimei365.com/app/img/icon/icon-member-prer6@2x.png',
  249. privText: '快速发货',
  250. privName: '会员加速'
  251. },
  252. {
  253. icon: 'https://static.caimei365.com/app/img/icon/icon-member-prer7@2x.png',
  254. privText: '售后服务',
  255. privName: '会员加速'
  256. },
  257. {
  258. icon: 'https://static.caimei365.com/app/img/icon/icon-member-prer8@2x.png',
  259. privText: '敬请期待',
  260. privName: '更多特权'
  261. }
  262. ],
  263. listQuery: {
  264. userId: 0,
  265. source: 1,
  266. pageNum: 1,
  267. pageSize: 4
  268. },
  269. productCouponList: [],
  270. productList: [],
  271. isReceiveLoading: false
  272. }
  273. },
  274. onLoad() {
  275. this.getUserSuperPackage()
  276. },
  277. filters: {
  278. TypeFormat(value) {
  279. switch (value) {
  280. case 0:
  281. return '活动券'
  282. break
  283. case 1:
  284. return '品类券'
  285. break
  286. case 2:
  287. return '用户专享券'
  288. break
  289. case 3:
  290. return '店铺券'
  291. break
  292. case 4:
  293. return '新用户券'
  294. break
  295. }
  296. },
  297. NumFormat(value) {
  298. //处理金额
  299. return Number(value).toFixed(2)
  300. }
  301. },
  302. computed: {
  303. ...mapState(['hasLogin', 'userInfo', 'identity', 'isActivity'])
  304. },
  305. methods: {
  306. async initGetStotage() {
  307. const userInfo = await this.$api.getStorage()
  308. this.payParam.userId = this.listQuery.userId = userInfo.userId ? userInfo.userId : 0
  309. this.userIdentity = userInfo.userIdentity ? userInfo.userIdentity : 0
  310. this.getUserSuperCenter()
  311. this.getSvipProductPage()
  312. },
  313. getUserSuperCenter() {
  314. // 获取会员中心数据
  315. this.UserService.getUserSuperCenter({ userId: this.payParam.userId })
  316. .then(response => {
  317. let data = response.data
  318. this.userVip = data.vip
  319. this.productCouponList = data.coupon
  320. console.log('this.productCouponList', this.productCouponList)
  321. this.isRequest = true
  322. })
  323. .catch(error => {
  324. this.$util.msg(error.msg, 2000)
  325. })
  326. },
  327. getSvipProductPage() {
  328. // 获取会员中心商品数据
  329. this.ProductService.getSvipProductPage(this.listQuery)
  330. .then(response => {
  331. let data = response.data.svipProductPage
  332. this.productList = data.results
  333. })
  334. .catch(error => {
  335. this.$util.msg(error.msg, 2000)
  336. })
  337. },
  338. getUserSuperPackage() {
  339. //获取会员中心套餐
  340. this.UserService.getUserSuperPackage()
  341. .then(response => {
  342. let data = response.data
  343. data.forEach(el => {
  344. el.beans = el.price * el.proportion
  345. el.packageId = el.id
  346. })
  347. this.payList = data
  348. this.handelPayMsg = data[0]
  349. this.payParam.packageId = data[0].packageId
  350. })
  351. .catch(error => {
  352. console.log('获取会员套餐异常~')
  353. })
  354. },
  355. receiveCoupon(coupon) {
  356. // 点击优惠券领取按钮
  357. if (this.isReceiveLoading) {
  358. return
  359. }
  360. if (this.userVip.vipFlag != 1) {
  361. this.$util.msg('您还未开通超级会员,不能领取', 2000)
  362. return
  363. }
  364. this.ProductService.ReceiveCoupon({
  365. userId: this.payParam.userId,
  366. couponId: coupon.couponId,
  367. source: 2
  368. })
  369. .then(response => {
  370. this.isReceiveLoading = true
  371. this.$util.msg('领取成功', 1500, true, 'success')
  372. setTimeout(() => {
  373. coupon.getFlag = 1
  374. this.isReceiveLoading = false
  375. }, 1500)
  376. })
  377. .catch(error => {
  378. this.$util.msg(error.msg, 2000)
  379. this.isReceiveLoading = false
  380. })
  381. },
  382. hanldeShowBeans() {
  383. // 显示采美豆抵扣开通超级会员弹窗
  384. if (process.env.NODE_ENV != 'development') {
  385. // 友盟埋点收集采美豆抵扣会员
  386. this.$uma.trackEvent('Um_Event_userClubMemberBeansConfirm', {
  387. Um_Key_Month: `${this.handelPayMsg.duration}个月`,
  388. Um_Key_SourcePage: '会员中心'
  389. })
  390. }
  391. this.isShowBeansModal = true
  392. },
  393. handelCanelBeans() {
  394. // 取消采美豆抵扣超级会员
  395. if (process.env.NODE_ENV != 'development') {
  396. // 友盟埋点收集取消采抵扣会员
  397. this.$uma.trackEvent('Um_Event_userClubMemberBeansCancel', {
  398. Um_Key_Month: `${this.handelPayMsg.duration}个月`,
  399. Um_Key_SourcePage: '会员中心'
  400. })
  401. }
  402. this.isShowBeansModal = false
  403. },
  404. handelConfirmBeans() {
  405. // 确认采美豆抵扣开通超级会员
  406. if (process.env.NODE_ENV != 'development') {
  407. // 友盟埋点收集确定采抵扣会员
  408. this.$uma.trackEvent('Um_Event_userClubMemberBeansConfirms', {
  409. Um_Key_Month: `${this.handelPayMsg.duration}个月`,
  410. Um_Key_SourcePage: '会员中心'
  411. })
  412. }
  413. this.PayService.getUserRegisterSuperBeans(this.payParam)
  414. .then(response => {
  415. this.isShowBeansModal = false
  416. this.$util.msg('开通成功', 2000, true, 'success')
  417. setTimeout(() => {
  418. this.getUserSuperCenter()
  419. }, 2000)
  420. })
  421. .catch(error => {
  422. this.$util.msg(error.msg, 2000)
  423. })
  424. },
  425. hanldWechatPay() {
  426. // 跳转微信只开通超级会员
  427. if (process.env.NODE_ENV != 'development') {
  428. // 友盟埋点收集线上微信支付
  429. this.$uma.trackEvent('Um_Event_userClubMemberConfirm', {
  430. Um_Key_Month: `${this.handelPayMsg.duration}个月`,
  431. Um_Key_SourcePage: '会员中心'
  432. })
  433. }
  434. this.PayService.getUserRegisterSuperPay(this.payParam)
  435. .then(response => {
  436. this.handelPayMsg.vipRecordId = response.data
  437. this.$api.navigateTo(`/pages/user/member/member-pay?data=${JSON.stringify(this.handelPayMsg)}`)
  438. })
  439. .catch(error => {
  440. this.$util.msg(error.msg, 2000)
  441. })
  442. },
  443. handleCheckedPay(index, pay) {
  444. // 选择会员
  445. this.tabCurrent = index
  446. this.payParam.packageId = pay.packageId
  447. this.handelPayMsg = pay
  448. },
  449. toUseCoupon(coupon) {
  450. // 去使用跳转路径
  451. console.log('coupon', coupon)
  452. switch (coupon.couponType) {
  453. case 0: // 活动券:跳转到商城首页 / 或者活动页(看是否指定了商品)
  454. if (coupon.productType == 1) {
  455. // 1 全商城通用 2 指定商品
  456. this.$api.switchTabTo('/pages/tabBar/home/index')
  457. } else {
  458. this.$api.navigateTo('/pages/user/coupon/coupon-product?couponId=' + coupon.couponId)
  459. }
  460. break
  461. case 1: // 品类券:跳转到产品 287 / 仪器页 286
  462. let categoryId = 0
  463. if (coupon.categoryType == 1) {
  464. categoryId = 287
  465. } else {
  466. categoryId = 286
  467. }
  468. this.$api.navigateTo(`/pages/goods/good-floor?linkId=${coupon.categoryType == 1 ? 287 : 286}`)
  469. break
  470. case 2: // 用户专享券:跳转到商城首页
  471. this.$api.switchTabTo('/pages/tabBar/home/index')
  472. break
  473. case 3: // 店铺券:跳转到店铺首页
  474. this.$api.navigateTo('/pages/supplier/user/my-shop?shopId=' + coupon.shopId)
  475. break
  476. case 4: // 新用户券:跳转到商城首页
  477. this.$api.switchTabTo('/pages/tabBar/home/index')
  478. break
  479. }
  480. },
  481. hanldRenewPayUrl(url) {
  482. // 监听续费跳转并做友盟埋点
  483. if (process.env.NODE_ENV != 'development') {
  484. // 友盟埋点收集续费按钮点击事件
  485. this.$uma.trackEvent('Um_Event_userClubRenewMember', {
  486. Um_Key_Time: this.getNowTime(),
  487. Um_Key_SourcePage: '会员中心'
  488. })
  489. }
  490. this.$api.navigateTo(url)
  491. },
  492. hanldPayUrl(url) {
  493. // 跳转
  494. this.$api.navigateTo(url)
  495. },
  496. PromotionsFormat(promo) {
  497. //促销活动类型数据处理
  498. if (promo != null) {
  499. if (promo.type == 1 && promo.mode == 1) {
  500. return true
  501. } else {
  502. return false
  503. }
  504. }
  505. return false
  506. },
  507. productDetail(productId) {
  508. // 跳转商品详情
  509. this.isModallayer = true
  510. this.$api.navigateTo(`/pages/goods/product?id=${productId}`)
  511. this.isModallayer = false
  512. },
  513. isShowVipFlag(pros) {
  514. // 超级会员价格显示控制
  515. if (pros.priceFlag != 1) {
  516. if (this.userIdentity == 4 && this.userVip.vipFlag == 1) {
  517. return true
  518. } else if (this.userIdentity == 2) {
  519. return true
  520. }
  521. }
  522. },
  523. getNowTime() {
  524. let dateTime
  525. let yy = new Date().getFullYear()
  526. let mm = new Date().getMonth() + 1
  527. let dd = new Date().getDate()
  528. let hh = new Date().getHours()
  529. let mf = new Date().getMinutes() < 10 ? '0' + new Date().getMinutes() : new Date().getMinutes()
  530. let ss = new Date().getSeconds() < 10 ? '0' + new Date().getSeconds() : new Date().getSeconds()
  531. dateTime = yy + '-' + mm + '-' + dd + ' ' + hh + ':' + mf + ':' + ss
  532. console.log(dateTime)
  533. return dateTime
  534. }
  535. },
  536. onPageScroll(e) {
  537. //实时获取到滚动的值
  538. if (this.userVip.vipFlag == 0) {
  539. if (e.scrollTop > 400) {
  540. this.popupShow = true
  541. } else {
  542. this.popupShow = false
  543. }
  544. }
  545. },
  546. onPullDownRefresh() {
  547. setTimeout(() => {
  548. uni.stopPullDownRefresh()
  549. }, 200)
  550. },
  551. onShow() {
  552. this.initGetStotage()
  553. }
  554. }
  555. </script>
  556. <style lang="scss">
  557. page {
  558. background-color: #f7f7f7;
  559. }
  560. .container {
  561. width: 100%;
  562. height: auto;
  563. }
  564. .cm-member-top {
  565. width: 100%;
  566. height: 242rpx;
  567. box-sizing: border-box;
  568. padding: 0 24rpx;
  569. background: url(https://static.caimei365.com/app/img/icon/icon-member-bg01@2x.png) no-repeat;
  570. background-size: cover;
  571. position: relative;
  572. .cm-member-cel {
  573. float: right;
  574. line-height: 40rpx;
  575. font-size: $font-size-26;
  576. margin-top: 40rpx;
  577. color: #f0cb72;
  578. text-align: right;
  579. }
  580. .cm-member-head {
  581. width: 702rpx;
  582. height: 132rpx;
  583. box-sizing: border-box;
  584. padding: 30rpx 32rpx 0 109rpx;
  585. background: url(https://static.caimei365.com/app/img/icon/icon-member-bg02@2x.png) no-repeat;
  586. background-size: cover;
  587. position: absolute;
  588. bottom: 0;
  589. left: 24rpx;
  590. border-radius: 16rpx 16rpx 0 0;
  591. .cm-member-text {
  592. float: left;
  593. .cm-member-h1 {
  594. line-height: 42rpx;
  595. font-size: $font-size-30;
  596. color: #55331d;
  597. text-align: left;
  598. margin-bottom: 12rpx;
  599. font-weight: bold;
  600. }
  601. .cm-member-p {
  602. line-height: 30rpx;
  603. font-size: $font-size-22;
  604. color: #55331d;
  605. text-align: left;
  606. }
  607. }
  608. .cm-member-btn {
  609. float: right;
  610. padding-top: 12rpx;
  611. .btn {
  612. width: 118rpx;
  613. height: 48rpx;
  614. background: linear-gradient(270deg, #585658 0%, #323031 100%);
  615. border-radius: 24rpx;
  616. line-height: 48rpx;
  617. text-align: center;
  618. font-size: $font-size-24;
  619. color: #f0cb72;
  620. }
  621. }
  622. }
  623. }
  624. .cm-member-main {
  625. width: 100%;
  626. box-sizing: border-box;
  627. padding: 40rpx 24rpx;
  628. background-color: #ffffff;
  629. margin-bottom: 20rpx;
  630. &.none {
  631. background-color: #f7f7f7;
  632. padding: 20rpx 24rpx 0 24rpx;
  633. }
  634. .title {
  635. font-size: $font-size-32;
  636. line-height: 45rpx;
  637. text-align: left;
  638. color: #55331d;
  639. font-weight: bold;
  640. .small {
  641. font-size: $font-size-24;
  642. color: #e4aa43;
  643. font-weight: normal;
  644. margin-left: 15rpx;
  645. }
  646. .more {
  647. float: right;
  648. font-weight: normal;
  649. line-height: 45rpx;
  650. font-size: $font-size-26;
  651. color: #999999;
  652. .iconfont {
  653. margin-left: 10rpx;
  654. }
  655. }
  656. }
  657. .cm-member-pay {
  658. width: 100%;
  659. height: 236rpx;
  660. margin: 40rpx 0;
  661. .pay-item {
  662. width: 218rpx;
  663. height: 100%;
  664. float: left;
  665. margin-right: 24rpx;
  666. border: 1px solid #f0f0f0;
  667. border-radius: 16rpx;
  668. box-sizing: border-box;
  669. text-align: center;
  670. padding: 40rpx 0;
  671. position: relative;
  672. .hot {
  673. width: 80rpx;
  674. height: 36rpx;
  675. text-align: center;
  676. line-height: 36rpx;
  677. font-size: $font-size-24;
  678. color: #ffffff;
  679. background-color: #ff2a2a;
  680. border-radius: 0 8rpx 8rpx 8rpx;
  681. position: absolute;
  682. left: 0;
  683. top: -10rpx;
  684. }
  685. &.current {
  686. background-color: #fdf8ee;
  687. border: 1px solid #f0cc8c;
  688. }
  689. &:last-child {
  690. margin-right: 0;
  691. }
  692. .text-1 {
  693. line-height: 40rpx;
  694. font-size: $font-size-28;
  695. margin-bottom: 10rpx;
  696. color: #55331d;
  697. }
  698. .text-2 {
  699. line-height: 59rpx;
  700. font-size: $font-size-40;
  701. margin-bottom: 10rpx;
  702. color: #ff2a2a;
  703. font-weight: bold;
  704. text {
  705. font-size: $font-size-26;
  706. }
  707. }
  708. .text-3 {
  709. line-height: 33rpx;
  710. font-size: $font-size-24;
  711. color: #666666;
  712. }
  713. }
  714. }
  715. .cm-member-button {
  716. width: 100%;
  717. box-sizing: border-box;
  718. padding: 0 51rpx;
  719. .pay-btn {
  720. width: 100%;
  721. height: 90rpx;
  722. line-height: 90rpx;
  723. border-radius: 50rpx;
  724. text-align: center;
  725. font-size: $font-size-30;
  726. color: #55331d;
  727. box-sizing: border-box;
  728. margin-bottom: $font-size-24;
  729. &.pay {
  730. background: linear-gradient(90deg, #fee9ba 0%, #f0cb72 100%);
  731. font-weight: bold;
  732. }
  733. &.none {
  734. border: 1px solid #f0cb72;
  735. margin-bottom: 0;
  736. }
  737. }
  738. }
  739. .cm-member-privilege {
  740. width: 100%;
  741. margin: 24rpx 0 16rpx 0;
  742. background-color: #ffffff;
  743. .privilege-item {
  744. width: 25%;
  745. height: 196rpx;
  746. margin: 16rpx 0;
  747. float: left;
  748. display: flex;
  749. flex-direction: column;
  750. align-items: center;
  751. .image {
  752. width: 90rpx;
  753. height: 90rpx;
  754. display: block;
  755. }
  756. .text-2 {
  757. font-size: $font-size-26;
  758. color: #333333;
  759. line-height: 36rpx;
  760. margin-top: 12rpx;
  761. }
  762. .text-3 {
  763. font-size: $font-size-22;
  764. color: #999999;
  765. line-height: 30rpx;
  766. margin-top: 6rpx;
  767. }
  768. }
  769. }
  770. .cm-member-coupon {
  771. width: 100%;
  772. margin: 24rpx 0 0 0;
  773. .coupon-list {
  774. width: 338rpx;
  775. height: 148rpx;
  776. border-radius: 8rpx;
  777. margin-bottom: 24rpx;
  778. box-sizing: border-box;
  779. background: url(https://static.caimei365.com/app/img/icon/icon-member-coupon@2x.png);
  780. background-size: cover;
  781. margin-right: 24rpx;
  782. float: left;
  783. position: relative;
  784. &:nth-child(2n) {
  785. margin-right: 0;
  786. }
  787. &.none {
  788. background: url(https://static.caimei365.com/app/img/icon/icon-member-coupon-none@2x.png);
  789. background-size: cover;
  790. }
  791. .list-cell-tags {
  792. display: inline-block;
  793. padding: 0 10rpx;
  794. height: 27rpx;
  795. line-height: 27rpx;
  796. background-color: #e4aa43;
  797. color: #55331d;
  798. font-size: $font-size-20;
  799. border-radius: 8rpx 0 8rpx 0;
  800. text-align: center;
  801. position: absolute;
  802. top: 0;
  803. left: 0;
  804. }
  805. .list-cell-le {
  806. width: 258rpx;
  807. height: 100%;
  808. box-sizing: border-box;
  809. padding: 27rpx 24rpx 0 26rpx;
  810. float: left;
  811. .coupon-maxMoney {
  812. width: 100%;
  813. height: 50rpx;
  814. line-height: 50rpx;
  815. font-size: 40rpx;
  816. color: #55331d;
  817. text-align: left;
  818. .small {
  819. font-size: $font-size-24;
  820. }
  821. }
  822. .coupon-minMoney {
  823. width: 100%;
  824. height: 30rpx;
  825. line-height: 30rpx;
  826. font-size: $font-size-24;
  827. color: #55331d;
  828. text-align: left;
  829. }
  830. .coupon-texts {
  831. width: 100%;
  832. height: 30rpx;
  833. line-height: 30rpx;
  834. font-size: $font-size-24;
  835. color: #55331d;
  836. text-align: left;
  837. -o-text-overflow: ellipsis;
  838. text-overflow: ellipsis;
  839. display: -webkit-box;
  840. word-break: break-all;
  841. -webkit-box-orient: vertical;
  842. -webkit-line-clamp: 1;
  843. overflow: hidden;
  844. }
  845. }
  846. .list-cell-ri {
  847. width: 80rpx;
  848. height: 100%;
  849. float: right;
  850. .icon-used-btn {
  851. width: 100%;
  852. height: 100%;
  853. box-sizing: border-box;
  854. font-size: $font-size-22;
  855. text-align: center;
  856. &.receive {
  857. color: #55331d;
  858. padding: 15rpx 28rpx;
  859. }
  860. &.make {
  861. padding: 30rpx 28rpx;
  862. color: #55331d;
  863. }
  864. }
  865. }
  866. }
  867. }
  868. .cm-member-product {
  869. width: 100%;
  870. margin-top: 16rpx;
  871. .product-list {
  872. width: 339rpx;
  873. height: 516rpx;
  874. border-radius: 16rpx;
  875. float: left;
  876. margin-right: 24rpx;
  877. margin-bottom: 24rpx;
  878. background-color: #ffffff;
  879. &:nth-child(2n) {
  880. margin-right: 0;
  881. }
  882. .product-image {
  883. width: 339rpx;
  884. height: 339rpx;
  885. image {
  886. width: 339rpx;
  887. height: 339rpx;
  888. display: block;
  889. border-radius: 16rpx 16rpx 0 0;
  890. }
  891. }
  892. .product-mains {
  893. width: 100%;
  894. height: auto;
  895. box-sizing: border-box;
  896. padding: 0 24rpx;
  897. margin-top: 8rpx;
  898. .product-name {
  899. height: 72rpx;
  900. line-height: 36rpx;
  901. text-overflow: ellipsis;
  902. overflow: hidden;
  903. display: -webkit-box;
  904. -webkit-line-clamp: 2;
  905. line-clamp: 2;
  906. -webkit-box-orient: vertical;
  907. font-size: $font-size-26;
  908. color: #333333;
  909. text-align: justify;
  910. }
  911. .product-tags {
  912. width: 100%;
  913. height: 32rpx;
  914. margin-top: 6rpx;
  915. .floor-item-act {
  916. width: 100%;
  917. height: 32rpx;
  918. text-align: center;
  919. box-sizing: border-box;
  920. float: left;
  921. }
  922. }
  923. .product-price {
  924. width: 100%;
  925. line-height: 37rpx;
  926. font-size: $font-size-26;
  927. color: #f94b4b;
  928. margin-top: 8rpx;
  929. .list-none-price {
  930. text-decoration: line-through;
  931. color: #999999;
  932. }
  933. }
  934. }
  935. }
  936. }
  937. }
  938. .cm-model-alert {
  939. width: 100%;
  940. height: 100%;
  941. background: rgba(0, 0, 0, 0.5);
  942. position: fixed;
  943. top: 0;
  944. left: 0;
  945. z-index: 8888;
  946. transition: all 0.4s;
  947. .content {
  948. width: 580rpx;
  949. height: 390rpx;
  950. position: absolute;
  951. background: $bg-color;
  952. left: 0;
  953. right: 0;
  954. bottom: 0;
  955. top: 0;
  956. margin: auto;
  957. padding: 20rpx 32rpx;
  958. border-radius: 12rpx;
  959. .title {
  960. width: 100%;
  961. height: 68rpx;
  962. line-height: 68rpx;
  963. font-size: $font-size-28;
  964. color: $text-color;
  965. text-align: center;
  966. position: relative;
  967. .icon-iconfontguanbi {
  968. width: 68rpx;
  969. height: 68rpx;
  970. text-align: center;
  971. line-height: 68rpx;
  972. position: absolute;
  973. right: 0;
  974. top: 0;
  975. font-size: $font-size-36;
  976. color: #999999;
  977. }
  978. }
  979. .text-content {
  980. width: 100%;
  981. height: auto;
  982. margin-top: 20px;
  983. .text {
  984. padding: 20rpx 0 0 0;
  985. line-height: 44rpx;
  986. font-size: $font-size-26;
  987. color: #666666;
  988. text-align: justify;
  989. .text-p {
  990. color: #e15616;
  991. }
  992. }
  993. }
  994. .text-button {
  995. width: 100%;
  996. height: 72rpx;
  997. display: flex;
  998. box-sizing: border-box;
  999. padding: 0 50rpx;
  1000. margin-top: 30px;
  1001. .btn {
  1002. width: 200rpx;
  1003. height: 72rpx;
  1004. line-height: 72rpx;
  1005. color: #fff;
  1006. display: flex;
  1007. align-items: center;
  1008. justify-content: center;
  1009. font-size: $font-size-26;
  1010. border-radius: 44rpx;
  1011. box-sizing: border-box;
  1012. &.btn-confirm {
  1013. background: $btn-confirm;
  1014. margin-left: 78rpx;
  1015. }
  1016. &.btn-cancel {
  1017. border: 1px solid #b2b2b2;
  1018. color: #333333;
  1019. }
  1020. }
  1021. }
  1022. }
  1023. }
  1024. .tui-popup-box {
  1025. position: relative;
  1026. box-sizing: border-box;
  1027. min-height: 168rpx;
  1028. padding: 6rpx 24rpx;
  1029. .cm-member-button {
  1030. width: 100%;
  1031. box-sizing: border-box;
  1032. padding: 24rpx 51rpx;
  1033. .pay-btn {
  1034. width: 100%;
  1035. height: 90rpx;
  1036. line-height: 90rpx;
  1037. border-radius: 50rpx;
  1038. text-align: center;
  1039. font-size: $font-size-30;
  1040. color: #55331d;
  1041. box-sizing: border-box;
  1042. margin-bottom: $font-size-24;
  1043. &.pay {
  1044. background: linear-gradient(90deg, #fee9ba 0%, #f0cb72 100%);
  1045. font-weight: bold;
  1046. }
  1047. &.none {
  1048. border: 1px solid #f0cb72;
  1049. margin-bottom: 0;
  1050. }
  1051. }
  1052. }
  1053. }
  1054. </style>