pay.vue 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677
  1. <template>
  2. <view class="pay-page" :style="{ '--font-scale': fontScale }">
  3. <scroll-view class="page" scroll-y>
  4. <!-- 商品明细卡 -->
  5. <view class="order-card">
  6. <view class="order-header">
  7. <text class="order-title">{{ levelName }} · {{ periodLabel }}</text>
  8. <text class="order-sub">{{ levelCode }}</text>
  9. </view>
  10. <view class="price-row" v-if="showOriginal">
  11. <text class="price-label">原价</text>
  12. <text class="price-original">¥{{ originalPriceText }}</text>
  13. </view>
  14. <view class="price-row">
  15. <text class="price-label">现价</text>
  16. <text class="price-now">¥{{ priceText }}</text>
  17. </view>
  18. <view class="coupon-row" @click="openCouponPicker">
  19. <text class="coupon-row-label">优惠券</text>
  20. <text v-if="selectedCoupon" class="coupon-row-discount">-¥{{ couponDiscountText }} {{ selectedCoupon.name }}</text>
  21. <text v-else class="coupon-row-placeholder">选择优惠券</text>
  22. <text class="coupon-row-arrow">›</text>
  23. </view>
  24. <view v-if="!isMember && hasMembershipCoupons" class="member-hint-row" @click="goToMembership">
  25. <text class="member-hint-icon">👑</text>
  26. <text class="member-hint-text">开通会员可使用会员专属优惠券</text>
  27. <text class="coupon-row-arrow">›</text>
  28. </view>
  29. <view class="divider"></view>
  30. <view class="total-row">
  31. <text class="total-label">实付</text>
  32. <text class="total-amount">¥{{ finalPriceText }}</text>
  33. </view>
  34. </view>
  35. <!-- 拆单提示卡 -->
  36. <view class="split-card" v-if="totalPeriods > 1">
  37. <text class="split-title">💡 本订单将分 {{ totalPeriods }} 期支付</text>
  38. <text class="split-desc">每期 ¥{{ splitAmountText }},全部支付完成后自动开通会员</text>
  39. </view>
  40. <!-- 支付进度(拆单逐期时显示) -->
  41. <view class="progress-card" v-if="paying && totalPeriods > 1">
  42. <text class="progress-text">第 {{ currentPeriod }} / {{ totalPeriods }} 期</text>
  43. </view>
  44. </scroll-view>
  45. <!-- 底部固定支付栏 -->
  46. <view class="pay-bar">
  47. <button class="btn-pay" :loading="paying" :disabled="paying" @click="handlePay">
  48. {{ paying ? '支付中…' : '立即支付 ¥' + finalPriceText }}
  49. </button>
  50. </view>
  51. <!-- Coupon Picker Bottom Sheet -->
  52. <view class="modal-mask" v-if="showCouponPicker" @click="showCouponPicker = false">
  53. <view class="coupon-picker" @click.stop>
  54. <view class="picker-header">
  55. <text class="picker-title">选择优惠券</text>
  56. <text class="picker-close" @click="showCouponPicker = false">关闭</text>
  57. </view>
  58. <scroll-view scroll-y class="picker-list">
  59. <view
  60. v-for="coupon in availableCoupons"
  61. :key="coupon.id"
  62. class="picker-item"
  63. :class="selectedCoupon && selectedCoupon.id === coupon.id ? 'picker-item-active' : ''"
  64. @click="selectCoupon(coupon)"
  65. >
  66. <view class="picker-item-left">
  67. <text class="picker-item-value">{{ formatPrice(coupon.value) }}</text>
  68. </view>
  69. <view class="picker-item-right">
  70. <text class="picker-item-name">{{ coupon.name }}</text>
  71. <text class="picker-item-condition">{{ getCouponCondition(coupon) }}</text>
  72. </view>
  73. <view class="picker-item-check" v-if="selectedCoupon && selectedCoupon.id === coupon.id">
  74. <text>✓</text>
  75. </view>
  76. </view>
  77. <view class="picker-empty" v-if="availableCoupons.length === 0">
  78. <text>暂无可用优惠券</text>
  79. </view>
  80. </scroll-view>
  81. <view class="picker-footer" v-if="selectedCoupon">
  82. <button class="picker-btn-remove" @click="removeCoupon">不使用优惠券</button>
  83. </view>
  84. </view>
  85. </view>
  86. </view>
  87. </template>
  88. <script>
  89. import { getMembershipPlans, getCouponList, createOrder, requestVirtualPayment, nextOrder } from '../../utils/api.js'
  90. import fontScaleMixin from '../../mixins/font-scale.js'
  91. export default {
  92. mixins: [fontScaleMixin],
  93. data() {
  94. return {
  95. levelCode: 'FAMILY',
  96. period: 'yearly',
  97. levelName: '家庭会员',
  98. periodLabel: '年度',
  99. levels: [],
  100. coupons: [],
  101. selectedCoupon: null,
  102. showCouponPicker: false,
  103. originalPrice: null,
  104. price: 0,
  105. totalPeriods: 1,
  106. currentPeriod: 1,
  107. splitAmount: 0,
  108. orderNo: null,
  109. paying: false,
  110. isMember: false
  111. }
  112. },
  113. computed: {
  114. showOriginal: function() {
  115. return this.originalPrice != null && this.originalPrice > this.price
  116. },
  117. priceText: function() {
  118. return (this.price / 100).toFixed(2)
  119. },
  120. originalPriceText: function() {
  121. if (this.originalPrice == null) return '0.00'
  122. return (this.originalPrice / 100).toFixed(2)
  123. },
  124. couponDiscount: function() {
  125. if (!this.selectedCoupon) return 0
  126. if (this.selectedCoupon.type === 'DISCOUNT') {
  127. var rate = this.selectedCoupon.discountRate || 100
  128. return Math.round(this.price * (100 - rate) / 100)
  129. }
  130. return this.selectedCoupon.value || 0
  131. },
  132. couponDiscountText: function() {
  133. return (this.couponDiscount / 100).toFixed(2)
  134. },
  135. finalPrice: function() {
  136. return Math.max(0, this.price - this.couponDiscount)
  137. },
  138. finalPriceText: function() {
  139. return (this.finalPrice / 100).toFixed(2)
  140. },
  141. splitAmountText: function() {
  142. return (this.splitAmount / 100).toFixed(2)
  143. },
  144. availableCoupons: function() {
  145. var self = this
  146. return this.coupons.filter(function(c) {
  147. if (c.status && c.status !== 'AVAILABLE') return false
  148. if (c.applicableTo && c.applicableTo !== 'ALL' && c.applicableTo !== 'MEMBERSHIP') return false
  149. // 会员专属券:非会员不显示在可选列表中
  150. if (c.applicableTo === 'MEMBERSHIP' && !self.isMember) return false
  151. return true
  152. })
  153. },
  154. hasMembershipCoupons: function() {
  155. var self = this
  156. return this.coupons.some(function(c) {
  157. return c.applicableTo === 'MEMBERSHIP' && (!c.status || c.status === 'AVAILABLE')
  158. })
  159. }
  160. },
  161. onLoad: function(options) {
  162. this.levelCode = options.levelCode || 'FAMILY'
  163. this.period = options.period || 'yearly'
  164. this.periodLabel = this.getPeriodLabel(this.period)
  165. this.loadPlans()
  166. this.loadCoupons()
  167. this.checkMemberStatus()
  168. },
  169. methods: {
  170. getPeriodLabel: function(period) {
  171. var map = { monthly: '月度', quarterly: '季度', yearly: '年度' }
  172. return map[period] || '年度'
  173. },
  174. loadPlans: function() {
  175. var self = this
  176. getMembershipPlans().then(function(res) {
  177. var levels = res.data || []
  178. for (var i = 0; i < levels.length; i++) {
  179. if (levels[i].levelCode === self.levelCode) {
  180. self.levelName = levels[i].levelName || self.levelName
  181. if (self.period === 'monthly') {
  182. self.price = levels[i].monthly || 0
  183. self.originalPrice = levels[i].originalMonthly || null
  184. } else if (self.period === 'quarterly') {
  185. self.price = levels[i].quarterly || 0
  186. self.originalPrice = levels[i].originalQuarterly || null
  187. } else {
  188. self.price = levels[i].yearly || 0
  189. self.originalPrice = levels[i].originalYearly || null
  190. }
  191. break
  192. }
  193. }
  194. }).catch(function(e) {
  195. uni.showToast({ title: '加载价格失败', icon: 'none' })
  196. console.error('加载价格失败', e)
  197. })
  198. },
  199. loadCoupons: function() {
  200. var self = this
  201. getCouponList().then(function(res) {
  202. self.coupons = res.data || []
  203. }).catch(function() {})
  204. },
  205. openCouponPicker: function() {
  206. if (this.availableCoupons.length === 0 && !this.selectedCoupon) {
  207. uni.showToast({ title: '暂无可用优惠券', icon: 'none' })
  208. return
  209. }
  210. this.showCouponPicker = true
  211. },
  212. selectCoupon: function(coupon) {
  213. this.selectedCoupon = coupon
  214. this.showCouponPicker = false
  215. },
  216. removeCoupon: function() {
  217. this.selectedCoupon = null
  218. this.showCouponPicker = false
  219. },
  220. checkMemberStatus: function() {
  221. var self = this
  222. uni.request({
  223. url: getApp().$config.baseUrl + '/api/membership/my',
  224. method: 'POST',
  225. header: { 'Authorization': 'Bearer ' + uni.getStorageSync('token') },
  226. success: function(res) {
  227. if (res.data && res.data.code === 200 && res.data.data) {
  228. var membership = res.data.data.membership
  229. self.isMember = membership && membership.isActive
  230. }
  231. }
  232. })
  233. },
  234. getCouponCondition: function(coupon) {
  235. if (!coupon) return '无门槛'
  236. if (coupon.applicableTo === 'MEMBERSHIP' && !this.isMember) {
  237. return '开通会员后可用'
  238. }
  239. if (!coupon.minSpend || coupon.minSpend <= 0) return '无门槛'
  240. return '满' + (coupon.minSpend / 100).toFixed(2) + '元可用'
  241. },
  242. formatPrice: function(value) {
  243. if (value == null) return '0.00'
  244. return (value / 100).toFixed(2)
  245. },
  246. handlePay: function() {
  247. var self = this
  248. if (this.paying) return
  249. this.paying = true
  250. var couponId = this.selectedCoupon ? this.selectedCoupon.id : null
  251. var openid = uni.getStorageSync('openid') || ''
  252. createOrder(this.levelCode, 'pay', this.period, couponId, openid).then(function(res) {
  253. var data = res.data || {}
  254. self.orderNo = data.orderNo
  255. var payType = data.payType || 'virtual'
  256. if (payType === 'virtual' && data.orderInfo && data.sign) {
  257. // 虚拟支付(现有逻辑不变)
  258. self.totalPeriods = data.totalPeriods || 1
  259. self.currentPeriod = data.currentPeriod || 1
  260. self.splitAmount = data.orderInfo.goodsPrice || (self.finalPrice / (self.totalPeriods || 1))
  261. self.payInstallments(data)
  262. } else if (payType === 'wechat' && data.wechatPayParams) {
  263. // 普通微信支付(新增分支)
  264. self.payWechat(data.wechatPayParams)
  265. } else {
  266. // testMode/trial:模拟支付成功
  267. uni.showToast({ title: '支付成功,开通中…', icon: 'none' })
  268. setTimeout(function() {
  269. self.paying = false
  270. uni.redirectTo({ url: '/pages/membership/result?orderNo=' + (self.orderNo || '') + '&status=success' })
  271. }, 800)
  272. }
  273. }).catch(function(e) {
  274. self.paying = false
  275. if (e.code === 46001) {
  276. uni.showToast({ title: '该商品暂未开放购买', icon: 'none' })
  277. } else {
  278. uni.showToast({ title: e.message || '下单失败', icon: 'none' })
  279. }
  280. })
  281. },
  282. payWechat: function(pp) {
  283. var self = this
  284. if (!pp || !pp.package) {
  285. self.paying = false
  286. uni.showToast({ title: '支付参数异常', icon: 'none' })
  287. return
  288. }
  289. uni.requestPayment({
  290. provider: 'wxpay',
  291. timeStamp: pp.timeStamp,
  292. nonceStr: pp.nonceStr,
  293. package: pp.package,
  294. signType: pp.signType || 'RSA',
  295. paySign: pp.paySign || pp.sign,
  296. success: function() {
  297. uni.showToast({ title: '支付成功,开通中…', icon: 'none' })
  298. setTimeout(function() {
  299. self.paying = false
  300. uni.redirectTo({ url: '/pages/membership/result?orderNo=' + (self.orderNo || '') + '&status=success' })
  301. }, 800)
  302. },
  303. fail: function(err) {
  304. self.paying = false
  305. var errCode = err && err.errCode
  306. var msg = '支付取消'
  307. if (errCode === -15007 || errCode === -15005) msg = '登录态已过期,请重新登录'
  308. else if (err && err.errMsg) msg = err.errMsg
  309. uni.showToast({ title: msg, icon: 'none' })
  310. setTimeout(function() {
  311. uni.redirectTo({ url: '/pages/membership/result?orderNo=' + (self.orderNo || '') + '&status=fail' })
  312. }, 800)
  313. }
  314. })
  315. },
  316. payInstallments: function(dto) {
  317. var self = this
  318. var current = dto.currentPeriod || 1
  319. var total = dto.totalPeriods || 1
  320. requestVirtualPayment(dto, {
  321. success: function() {
  322. if (current < total) {
  323. uni.showToast({ title: '第' + current + '期支付成功', icon: 'none' })
  324. nextOrder({ orderNo: dto.orderNo }).then(function(res) {
  325. var nd = res.data
  326. if (nd && nd.done) {
  327. self.finishPay()
  328. } else if (nd && nd.orderInfo && nd.sign) {
  329. self.currentPeriod = nd.currentPeriod || 1
  330. self.payInstallments(nd)
  331. } else {
  332. self.finishPay()
  333. }
  334. }).catch(function() {
  335. self.finishPay()
  336. })
  337. } else {
  338. self.finishPay()
  339. }
  340. },
  341. fail: function(err) {
  342. self.paying = false
  343. var errCode = err && err.errCode
  344. var msg = ''
  345. if (errCode === -15007 || errCode === -15005) msg = '登录态已过期,请重新登录后支付'
  346. else if (errCode === -15010) msg = '商品未发布,请联系客服'
  347. else if (errCode === -15013) msg = '商品价格异常'
  348. else if (errCode === -2) msg = '支付已取消'
  349. else if (err && err.errMsg) msg = err.errMsg
  350. var status = (errCode === -2 || errCode === -15007 || errCode === -15005) ? 'fail' : 'fail'
  351. uni.redirectTo({ url: '/pages/membership/result?orderNo=' + (self.orderNo || '') + '&status=' + status })
  352. }
  353. })
  354. },
  355. finishPay: function() {
  356. var self = this
  357. uni.showToast({ title: '支付成功,开通中…', icon: 'none' })
  358. setTimeout(function() {
  359. self.paying = false
  360. uni.redirectTo({ url: '/pages/membership/result?orderNo=' + (self.orderNo || '') + '&status=success' })
  361. }, 800)
  362. },
  363. goToMembership: function() {
  364. uni.navigateTo({ url: '/pages/membership/index' })
  365. }
  366. }
  367. }
  368. </script>
  369. <style scoped>
  370. .pay-page {
  371. min-height: 100vh;
  372. background: #FFF7ED;
  373. padding-bottom: 160rpx;
  374. box-sizing: border-box;
  375. }
  376. .page {
  377. padding: 30rpx;
  378. }
  379. /* ===== 商品明细卡 ===== */
  380. .order-card {
  381. background: #FFFFFF;
  382. border-radius: 20rpx;
  383. padding: 40rpx;
  384. box-shadow: 0 4rpx 24rpx rgba(249, 115, 22, 0.08);
  385. }
  386. .order-header {
  387. margin-bottom: 24rpx;
  388. }
  389. .order-title {
  390. font-size: calc(34rpx * var(--font-scale, 1));
  391. font-weight: bold;
  392. color: #1E293B;
  393. display: block;
  394. }
  395. .order-sub {
  396. font-size: calc(24rpx * var(--font-scale, 1));
  397. color: #94A3B8;
  398. margin-top: 6rpx;
  399. display: block;
  400. }
  401. .price-row {
  402. display: flex;
  403. justify-content: space-between;
  404. align-items: center;
  405. padding: 16rpx 0;
  406. }
  407. .price-label {
  408. font-size: 26rpx;
  409. color: #64748B;
  410. }
  411. .price-original {
  412. font-size: 28rpx;
  413. color: #94A3B8;
  414. text-decoration: line-through;
  415. }
  416. .price-now {
  417. font-size: 36rpx;
  418. font-weight: bold;
  419. color: #F97316;
  420. }
  421. .coupon-row {
  422. display: flex;
  423. align-items: center;
  424. padding: 24rpx 0;
  425. border-top: 1rpx solid #f5f5f5;
  426. margin-top: 16rpx;
  427. }
  428. .coupon-row:active {
  429. opacity: 0.7;
  430. }
  431. .coupon-row-label {
  432. font-size: calc(26rpx * var(--font-scale, 1));
  433. color: #666;
  434. margin-right: 16rpx;
  435. }
  436. .coupon-row-discount {
  437. flex: 1;
  438. font-size: 26rpx;
  439. color: #F97316;
  440. font-weight: 600;
  441. text-align: right;
  442. }
  443. .coupon-row-placeholder {
  444. flex: 1;
  445. font-size: 26rpx;
  446. color: #ccc;
  447. text-align: right;
  448. }
  449. .coupon-row-arrow {
  450. font-size: 32rpx;
  451. color: #ccc;
  452. margin-left: 8rpx;
  453. }
  454. .member-hint-row {
  455. display: flex;
  456. align-items: center;
  457. padding: 20rpx 0;
  458. margin-top: 8rpx;
  459. background: #FFF7ED;
  460. border-radius: 12rpx;
  461. }
  462. .member-hint-row:active {
  463. opacity: 0.7;
  464. }
  465. .member-hint-icon {
  466. font-size: 28rpx;
  467. margin-right: 12rpx;
  468. }
  469. .member-hint-text {
  470. flex: 1;
  471. font-size: calc(26rpx * var(--font-scale, 1));
  472. color: #F97316;
  473. font-weight: 500;
  474. }
  475. .divider {
  476. height: 1rpx;
  477. background: #F1F5F9;
  478. margin: 16rpx 0;
  479. }
  480. .total-row {
  481. display: flex;
  482. justify-content: space-between;
  483. align-items: center;
  484. }
  485. .total-label {
  486. font-size: 28rpx;
  487. font-weight: 600;
  488. color: #1E293B;
  489. }
  490. .total-amount {
  491. font-size: 44rpx;
  492. font-weight: bold;
  493. color: #F97316;
  494. }
  495. /* ===== 拆单提示 ===== */
  496. .split-card {
  497. background: #FEF3C7;
  498. border-radius: 20rpx;
  499. padding: 24rpx;
  500. margin-top: 30rpx;
  501. }
  502. .split-title {
  503. font-size: calc(28rpx * var(--font-scale, 1));
  504. font-weight: 600;
  505. color: #92400E;
  506. display: block;
  507. margin-bottom: 8rpx;
  508. }
  509. .split-desc {
  510. font-size: calc(24rpx * var(--font-scale, 1));
  511. color: #B45309;
  512. display: block;
  513. }
  514. /* ===== 支付进度 ===== */
  515. .progress-card {
  516. background: #FFFFFF;
  517. border-radius: 20rpx;
  518. padding: 20rpx;
  519. margin-top: 20rpx;
  520. text-align: center;
  521. }
  522. .progress-text {
  523. font-size: calc(26rpx * var(--font-scale, 1));
  524. color: #F97316;
  525. font-weight: 600;
  526. }
  527. /* ===== 底部支付栏 ===== */
  528. .pay-bar {
  529. position: fixed;
  530. bottom: 0;
  531. left: 0;
  532. right: 0;
  533. background: #FFFFFF;
  534. padding: 20rpx 30rpx calc(20rpx + env(safe-area-inset-bottom));
  535. box-shadow: 0 -4rpx 20rpx rgba(0, 0, 0, 0.05);
  536. }
  537. .btn-pay {
  538. width: 100%;
  539. height: 96rpx;
  540. line-height: 96rpx;
  541. background: linear-gradient(135deg, #F97316 0%, #EA580C 100%);
  542. color: #fff;
  543. font-size: 34rpx;
  544. font-weight: 600;
  545. border-radius: 48rpx;
  546. border: none;
  547. }
  548. .btn-pay::after {
  549. border: none;
  550. }
  551. .btn-pay[disabled] {
  552. opacity: 0.7;
  553. color: #fff;
  554. }
  555. /* ===== Coupon Picker(复用 upgrade 样式) ===== */
  556. .modal-mask {
  557. position: fixed;
  558. top: 0;
  559. left: 0;
  560. right: 0;
  561. bottom: 0;
  562. background: rgba(0,0,0,0.5);
  563. z-index: 999;
  564. display: flex;
  565. align-items: flex-end;
  566. }
  567. .coupon-picker {
  568. background: #fff;
  569. border-radius: 24rpx 24rpx 0 0;
  570. width: 100%;
  571. max-height: 70vh;
  572. display: flex;
  573. flex-direction: column;
  574. }
  575. .picker-header {
  576. display: flex;
  577. justify-content: space-between;
  578. align-items: center;
  579. padding: 30rpx;
  580. border-bottom: 1rpx solid #eee;
  581. }
  582. .picker-title {
  583. font-size: 30rpx;
  584. font-weight: 600;
  585. color: #333;
  586. }
  587. .picker-close {
  588. font-size: 26rpx;
  589. color: #999;
  590. }
  591. .picker-list {
  592. max-height: 50vh;
  593. padding: 0 20rpx;
  594. }
  595. .picker-item {
  596. display: flex;
  597. align-items: center;
  598. padding: 24rpx 16rpx;
  599. border-bottom: 1rpx solid #f5f5f5;
  600. }
  601. .picker-item:active {
  602. background: #fafafa;
  603. }
  604. .picker-item-active {
  605. background: #FFF7ED;
  606. }
  607. .picker-item-left {
  608. width: 120rpx;
  609. text-align: center;
  610. flex-shrink: 0;
  611. }
  612. .picker-item-value {
  613. font-size: 32rpx;
  614. font-weight: bold;
  615. color: #F97316;
  616. }
  617. .picker-item-right {
  618. flex: 1;
  619. margin: 0 16rpx;
  620. }
  621. .picker-item-name {
  622. font-size: calc(26rpx * var(--font-scale, 1));
  623. color: #333;
  624. display: block;
  625. margin-bottom: 4rpx;
  626. }
  627. .picker-item-condition {
  628. font-size: calc(22rpx * var(--font-scale, 1));
  629. color: #999;
  630. }
  631. .picker-item-check {
  632. width: 40rpx;
  633. height: 40rpx;
  634. background: #F97316;
  635. border-radius: 50%;
  636. display: flex;
  637. align-items: center;
  638. justify-content: center;
  639. flex-shrink: 0;
  640. color: #fff;
  641. font-size: 24rpx;
  642. font-weight: bold;
  643. }
  644. .picker-empty {
  645. text-align: center;
  646. padding: 60rpx 0;
  647. font-size: calc(26rpx * var(--font-scale, 1));
  648. color: #999;
  649. }
  650. .picker-footer {
  651. padding: 20rpx;
  652. border-top: 1rpx solid #eee;
  653. }
  654. .picker-btn-remove {
  655. background: #f5f5f5;
  656. color: #666;
  657. font-size: calc(26rpx * var(--font-scale, 1));
  658. border-radius: 12rpx;
  659. border: none;
  660. }
  661. .picker-btn-remove::after {
  662. border: none;
  663. }
  664. </style>