index.vue 23 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050
  1. <template>
  2. <view class="vip-container">
  3. <view class="heard-box" :class="`active${selectedPrice}`">
  4. <!-- 自定义头部 -->
  5. <PageHeader title="" class="PageHeader">
  6. <template slot="right">
  7. <view class="more-options" @tap="toggleDropdown">
  8. <text class="fa fa-ellipsis-h"></text>
  9. <view class="dropdown-menu" v-if="showDropdown">
  10. <view class="dropdown-item" @tap="handleOption('vipRecord')">VIP记录</view>
  11. <view class="dropdown-item" @tap="handleOption('contact')">联系客服</view>
  12. </view>
  13. </view>
  14. </template>
  15. </PageHeader>
  16. <view class="reserveASeat"></view>
  17. <view class="vip-card-box">
  18. <!-- 顶部会员信息 -->
  19. <view class="vip-header">
  20. <view class="vip-info">
  21. <CircleAvatar class="vip-info-left" v-if="userInfo.avator" :src="userInfo.avator">
  22. </CircleAvatar>
  23. <view class="vip-info-right">
  24. <view class="vip-nickname">{{ userInfo.nickname }}</view>
  25. <view class="vip-expire" v-if="userInfo.is_vip">VIP到期时间: {{ userInfo.vip_date }}</view>
  26. <view class="vip-expire" v-else>暂未开通</view>
  27. </view>
  28. </view>
  29. </view>
  30. </view>
  31. </view>
  32. <view class="vip-content">
  33. <!-- 会员价格选择 -->
  34. <view class="vip-price-options">
  35. <view class="price-option" v-for="(item, index) in priceOptions" :key="index"
  36. :class="{ active: selectedPrice === index }" @tap="selectPrice(index)">
  37. <view class="price-left-img" v-if="item.limitedTimeGift">
  38. 限时优惠M币{{ item.limitedTimeGift }}
  39. </view>
  40. <view class="price-tag" v-if="item.tag">{{ item.tag }}</view>
  41. <view class="duration">{{ item.name }}</view>
  42. <view class="price"><text style="font-size: 40rpx;">¥</text>{{ item.price }}</view>
  43. <view class="originalPrice">¥{{ item.originalPrice }}</view>
  44. </view>
  45. </view>
  46. <uv-notice-bar speed="250" color="#333"
  47. :text="'uv-ui众多组件覆盖开发过程的各个需求,组件功能丰富,多端兼容。让您快速集成,开箱即用'"></uv-notice-bar>
  48. <!-- 会员特权列表 -->
  49. <view class="vip-privileges">
  50. <view class="privileges-title">尊享特权</view>
  51. <view class="privileges-list">
  52. <view class="privilege-item" v-for="(item, index) in privileges" :key="index">
  53. <image class="privilege-icon" v-if="item.icon" :src="item.icon" mode="aspectFit"></image>
  54. <view class="privilege-info">
  55. <view class="privilege-name">{{ item.name }}</view>
  56. <view class="privilege-desc">{{ item.desc }}</view>
  57. </view>
  58. </view>
  59. </view>
  60. </view>
  61. <view class="agree">
  62. <view class="agree2" @click="agreeChk()">
  63. <image mode="widthFix" src="../../static/icon/wd_icon_gouxuan04.png" v-if="is_agree == 0"></image>
  64. <image mode="widthFix" src="../../static/icon/wd_icon_gouxuan05.png" v-if="is_agree == 1"></image>
  65. </view>
  66. <view>
  67. 同意《充值服务协议》
  68. <text class="xy" @click="goPage('/pages/AboutUs/pay_xy')">
  69. 充值服务协议
  70. </text>,充值M币仅【萌创星球】使用点击查看
  71. <text class="xy" @click="goPage('yszc')">
  72. 充值记录
  73. </text>
  74. </view>
  75. </view>
  76. <view class="bottom-pay-btn-bottom"
  77. v-if="priceOptions && priceOptions[selectedPrice] && priceOptions[selectedPrice].price"
  78. @tap="showPaymentOptions">
  79. <text>¥{{ priceOptions[selectedPrice].price }}</text> 立即购买
  80. </view>
  81. </view>
  82. <!-- 支付方式选择弹窗 -->
  83. <uni-popup ref="paymentPopup" type="bottom">
  84. <view class="payment-popup">
  85. <view class="popup-header">
  86. <view class="popup-title">选择支付方式</view>
  87. <!-- <view class="popup-close" @tap="closePaymentPopup">×</view> -->
  88. </view>
  89. <view class="payment-options">
  90. <view class="payment-option" @tap="selectPayment('alipay')">
  91. <image class="payment-icon" src="../../static/icon/pay_ali.png" mode="aspectFit"></image>
  92. <view class="payment-name">支付宝支付</view>
  93. <image class="payment-select"
  94. :src="paymentMethod === 'alipay' ? '../../static/icon/wd_icon_gouxuan05.png' : '../../static/icon/wd_icon_gouxuan04.png'"
  95. mode="aspectFit"></image>
  96. </view>
  97. <view v-if="false" class="payment-option" @tap="selectPayment('wechat')">
  98. <image class="payment-icon" src="../../static/icon/pay_wx.png" mode="aspectFit"></image>
  99. <view class="payment-name">微信支付</view>
  100. <image class="payment-select"
  101. :src="paymentMethod === 'wechat' ? '../../static/icon/wd_icon_gouxuan05.png' : '../../static/icon/wd_icon_gouxuan04.png'"
  102. mode="aspectFit"></image>
  103. </view>
  104. </view>
  105. <view class="confirm-payment" @tap="confirmPayment">立即支付</view>
  106. </view>
  107. </uni-popup>
  108. </view>
  109. </template>
  110. <script>
  111. export default {
  112. data() {
  113. return {
  114. userInfo: {
  115. is_vip: false,
  116. vip_date: '2023-10-23'
  117. },
  118. priceOptions: [
  119. ],
  120. selectedPrice: 1, // 默认选中的价格选项索引
  121. privileges: [{
  122. name: 'VIP专属通道',
  123. icon: '../../static/vip/hy_icon_quanyi01.png',
  124. desc: '创作加速,更快生成'
  125. },
  126. {
  127. name: '专属星源礼包',
  128. icon: '../../static/vip/hy_icon_quanyi02.png',
  129. desc: '每日登录领更多星源'
  130. },
  131. {
  132. name: '记忆增强',
  133. icon: '../../static/vip/hy_icon_quanyi03.png',
  134. desc: '创作加速,更快生成'
  135. },
  136. {
  137. name: '升级语言模型',
  138. icon: '../../static/vip/hy_icon_quanyi04.png',
  139. desc: '深度思考,提升50%'
  140. },
  141. {
  142. name: 'VIP专属通道',
  143. icon: '../../static/vip/hy_icon_quanyi05.png',
  144. desc: '创作加速,更快生成'
  145. },
  146. {
  147. name: '免广告',
  148. icon: '../../static/vip/hy_icon_quanyi06.png',
  149. desc: '无广告免费体验'
  150. }
  151. ],
  152. paymentMethod: 'alipay', // 默认支付方式
  153. privilegesHeight: 0, // 添加存储特权区域高度的变量
  154. showDropdown: false, // 控制下拉菜单显示状态
  155. is_agree: 0,
  156. linkid: '',
  157. }
  158. },
  159. onLoad() {
  160. // 获取用户信息,检查是否为VIP
  161. this.getUserInfo();
  162. },
  163. onReady() {
  164. // 页面渲染完成后获取vip-privileges的高度
  165. this.getPrivilegesHeight();
  166. },
  167. methods: {
  168. // 获取用户信息
  169. getUserInfo() {
  170. // 这里添加获取用户信息的API调用
  171. uni.request({
  172. url: this.$apiHost + "/User/getinfo",
  173. data: {
  174. uuid: getApp().globalData.uuid,
  175. skey: getApp().globalData.skey,
  176. },
  177. header: {
  178. "content-type": "application/json",
  179. sign: getApp().globalData.headerSign,
  180. },
  181. success: (res) => {
  182. if (res) {
  183. console.log("获取到用户信息", res.data);
  184. this.userInfo = res.data
  185. }
  186. },
  187. complete: (com) => {
  188. },
  189. fail: (e) => {
  190. console.log("----e:", e);
  191. },
  192. });
  193. uni.request({
  194. url: this.$apiHost + "/Member/vipList",
  195. data: {
  196. uuid: getApp().globalData.uuid,
  197. skey: getApp().globalData.skey,
  198. },
  199. header: {
  200. "content-type": "application/json",
  201. sign: getApp().globalData.headerSign,
  202. },
  203. success: (res) => {
  204. console.log("作品列表数据:", res.data);
  205. // 确保在任何情况下都完成加载
  206. if (
  207. res.data.success == "yes" &&
  208. res.data.list &&
  209. res.data.list.length > 0
  210. ) {
  211. console.log(res.data.list, "会员列表数据");
  212. res.data.list.reverse()
  213. res.data.list.forEach(v => {
  214. this.priceOptions.push({
  215. id: v.id,
  216. limitedTimeGift: v.price_market - v.price,
  217. name: v.name,
  218. price: v.price,
  219. originalPrice: v.price_market,
  220. tag: v.tag,
  221. numDay: v.num_day,
  222. numSong: v.num_song,
  223. })
  224. });
  225. this.priceOptions[1].tag = "推荐"
  226. console.log(this.priceOptions, "会员列表数据");
  227. } else {
  228. // priceOptions: [{
  229. // name: '月度VIP',
  230. // price: '98',
  231. // originalPrice: '168',
  232. // tag: '',
  233. // limitedTimeGift: ""
  234. // },
  235. // {
  236. // name: '季度VIP',
  237. // price: '198',
  238. // originalPrice: '268',
  239. // tag: '推荐',
  240. // limitedTimeGift: "100"
  241. // },
  242. // {
  243. // name: '年度VIP',
  244. // price: '398',
  245. // originalPrice: '498',
  246. // tag: '',
  247. // limitedTimeGift: "1500"
  248. // }
  249. // ],
  250. }
  251. },
  252. complete: () => {
  253. },
  254. fail: (e) => {
  255. console.log("请求关注列表失败:", e);
  256. },
  257. });
  258. },
  259. // 选择价格选项
  260. selectPrice(index) {
  261. this.selectedPrice = index;
  262. },
  263. // 显示支付方式选择弹窗
  264. showPaymentOptions() {
  265. if (this.is_agree == 0) {
  266. uni.showToast({
  267. title: "请确认并选择协议",
  268. icon: "none",
  269. });
  270. return;
  271. }
  272. this.$refs.paymentPopup.open();
  273. },
  274. // 关闭支付方式选择弹窗
  275. closePaymentPopup() {
  276. this.$refs.paymentPopup.close();
  277. },
  278. // 选择支付方式
  279. selectPayment(method) {
  280. this.paymentMethod = method;
  281. },
  282. // 确认支付
  283. confirmPayment() {
  284. if (!this.priceOptions || !this.priceOptions[this.selectedPrice]) {
  285. uni.showToast({
  286. title: '请选择会员套餐',
  287. icon: 'none'
  288. });
  289. return;
  290. }
  291. uni.showLoading({
  292. title: '支付中...'
  293. });
  294. uni.request({
  295. url: this.$apiHost + '/Order/submit',
  296. data: {
  297. uuid: getApp().globalData.uuid,
  298. skey: getApp().globalData.skey,
  299. product_id: this.priceOptions[this.selectedPrice].id,
  300. type: 'buyVip',
  301. payType: this.paymentMethod
  302. },
  303. header: {
  304. 'content-type': 'application/json',
  305. sign: getApp().globalData.headerSign
  306. },
  307. success: (res) => {
  308. console.log("支付订单创建结果:", res.data);
  309. if (res.data.success == 'yes') {
  310. this.linkid = res.data.linkid;
  311. // 根据支付方式调用不同的支付接口
  312. if (this.paymentMethod === 'wechat') {
  313. uni.requestPayment({
  314. provider: "wxpay",
  315. orderInfo: res.data.wepay,
  316. success: (payRes) => {
  317. console.log("微信支付成功:", payRes);
  318. this.checkPayStatus();
  319. },
  320. fail: (err) => {
  321. console.log("微信支付失败:", err);
  322. uni.hideLoading();
  323. uni.showToast({
  324. title: '支付取消',
  325. icon: 'none'
  326. });
  327. }
  328. });
  329. } else if (this.paymentMethod === 'alipay') {
  330. uni.requestPayment({
  331. provider: "alipay",
  332. orderInfo: res.data.alipay,
  333. success: (payRes) => {
  334. console.log("支付宝支付成功:", payRes);
  335. this.checkPayStatus();
  336. },
  337. fail: (err) => {
  338. console.log("支付宝支付失败:", err);
  339. uni.hideLoading();
  340. uni.showToast({
  341. title: '支付取消',
  342. icon: 'none'
  343. });
  344. }
  345. });
  346. }
  347. } else {
  348. uni.hideLoading();
  349. uni.showToast({
  350. title: res.data.msg || '创建订单失败',
  351. icon: "error"
  352. });
  353. }
  354. },
  355. fail: (err) => {
  356. console.log("创建订单失败:", err);
  357. uni.hideLoading();
  358. uni.showToast({
  359. title: '网络错误,请稍后重试',
  360. icon: "error"
  361. });
  362. }
  363. });
  364. },
  365. // 检查支付状态
  366. checkPayStatus() {
  367. if (!this.linkid) return;
  368. let checkCount = 0;
  369. const maxChecks = 10;
  370. const checkOrder = () => {
  371. if (checkCount >= maxChecks) {
  372. uni.hideLoading();
  373. uni.showToast({
  374. title: '支付结果查询超时',
  375. icon: 'none'
  376. });
  377. return;
  378. }
  379. uni.request({
  380. url: this.$apiHost + '/Order/check',
  381. data: {
  382. uuid: getApp().globalData.uuid,
  383. skey: getApp().globalData.skey,
  384. linkid: this.linkid
  385. },
  386. header: {
  387. 'content-type': 'application/json',
  388. sign: getApp().globalData.headerSign
  389. },
  390. success: (res) => {
  391. if (res.data.success == 'yes' && res.data.status == 'paid') {
  392. uni.hideLoading();
  393. uni.showToast({
  394. title: '支付成功',
  395. icon: 'success'
  396. });
  397. this.$refs.paymentPopup.close();
  398. // 刷新用户信息
  399. this.getUserInfo();
  400. } else if (res.data.status == 'unpaid' && checkCount < maxChecks) {
  401. checkCount++;
  402. setTimeout(checkOrder, 1000);
  403. } else {
  404. uni.hideLoading();
  405. uni.showToast({
  406. title: '支付结果异常',
  407. icon: 'none'
  408. });
  409. }
  410. },
  411. fail: () => {
  412. uni.hideLoading();
  413. uni.showToast({
  414. title: '查询支付结果失败',
  415. icon: 'none'
  416. });
  417. }
  418. });
  419. };
  420. checkOrder();
  421. },
  422. // 获取特权列表区域的高度
  423. getPrivilegesHeight() {
  424. const query = uni.createSelectorQuery().in(this);
  425. query.select('.vip-privileges').boundingClientRect(data => {
  426. if (data) {
  427. this.privilegesHeight = data.height;
  428. console.log('特权区域高度:', this.privilegesHeight);
  429. } else {
  430. console.log('未能获取到特权区域元素');
  431. // 如果首次获取失败,可以添加延迟重试
  432. setTimeout(() => {
  433. this.getPrivilegesHeight();
  434. }, 100);
  435. }
  436. }).exec();
  437. },
  438. // 如果需要在某些数据变化后重新获取高度
  439. updatePrivilegesHeight() {
  440. this.$nextTick(() => {
  441. this.getPrivilegesHeight();
  442. });
  443. },
  444. // 切换下拉菜单显示状态
  445. toggleDropdown() {
  446. this.showDropdown = !this.showDropdown;
  447. },
  448. // 处理下拉菜单选项点击
  449. handleOption(type) {
  450. this.showDropdown = false;
  451. switch (type) {
  452. case 'vipRecord':
  453. uni.navigateTo({
  454. url: '/pages/vip/record'
  455. });
  456. break;
  457. case 'help':
  458. uni.navigateTo({
  459. url: '/pages/help/index'
  460. });
  461. break;
  462. case 'contact':
  463. uni.navigateTo({
  464. url: '/pages/contact/index'
  465. });
  466. break;
  467. }
  468. },
  469. goPage(page) {
  470. uni.navigateTo({
  471. url: page,
  472. })
  473. }, agreeChk() {
  474. if (this.is_agree == 0) {
  475. this.is_agree = 1;
  476. } else {
  477. this.is_agree = 0;
  478. }
  479. },
  480. }
  481. }
  482. </script>
  483. <style lang="scss">
  484. // 导入FontAwesome
  485. @import url("https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css");
  486. .vip-container {
  487. min-height: 100vh;
  488. padding-bottom: 100rpx;
  489. .heard-box {
  490. .PageHeader {
  491. background-image: url("@/static/vip/hy_bg_01.png");
  492. background-size: 100% auto;
  493. background-repeat: no-repeat;
  494. background-position-y: -var(--status-bar-height);
  495. ::v-deep .uni-icons {
  496. color: #fff !important;
  497. }
  498. .fa {
  499. color: #fff;
  500. }
  501. }
  502. .vip-card-box {
  503. width: 100%;
  504. padding: 0 36rpx;
  505. height: 300rpx;
  506. padding-top: 50rpx;
  507. .vip-header {
  508. width: 100%;
  509. height: 210rpx;
  510. padding-left: 28rpx;
  511. padding-top: 110rpx;
  512. .vip-info {
  513. display: flex;
  514. .vip-info-left {
  515. width: 60rpx;
  516. height: 60rpx;
  517. border: #fff solid 2rpx;
  518. margin-right: 10rpx;
  519. }
  520. .vip-info-right {
  521. .vip-nickname {
  522. font-size: 24rpx;
  523. font-weight: 400;
  524. font-family: 'PingFang SC-Bold';
  525. }
  526. .vip-expire {
  527. font-size: 20rpx;
  528. font-family: 'PingFang SC-Medium';
  529. }
  530. }
  531. }
  532. }
  533. }
  534. &.active0 {
  535. background: url("@/static/vip/hy_bg_01.png") center/100% 100% no-repeat;
  536. .PageHeader {
  537. background-image: url("@/static/vip/hy_bg_01.png");
  538. }
  539. .vip-card-box {
  540. .vip-header {
  541. background: url("@/static/vip/hy_card_01.png") top center/100% auto no-repeat;
  542. .vip-info {
  543. .vip-nickname {
  544. color: #1f1f1f;
  545. }
  546. .vip-expire {
  547. color: rgba(31, 31, 31, 0.7);
  548. }
  549. }
  550. }
  551. }
  552. }
  553. &.active1 {
  554. background: url("@/static/vip/hy_bg_02.png") center/100% 100% no-repeat;
  555. .PageHeader {
  556. background-image: url("@/static/vip/hy_bg_02.png");
  557. }
  558. .vip-card-box {
  559. .vip-header {
  560. background: url("@/static/vip/hy_card_02.png") top center/100% auto no-repeat;
  561. .vip-info {
  562. .vip-nickname {
  563. color: #FFE590;
  564. }
  565. .vip-expire {
  566. color: rgba(255, 229, 144, 0.35);
  567. }
  568. }
  569. }
  570. }
  571. }
  572. &.active2 {
  573. background: url("@/static/vip/hy_bg_03.png") center/100% 100% no-repeat;
  574. .PageHeader {
  575. background-image: url("@/static/vip/hy_bg_03.png");
  576. }
  577. .vip-card-box {
  578. .vip-header {
  579. background: url("@/static/vip/hy_card_03.png") top center/100% auto no-repeat;
  580. .vip-info {
  581. .vip-nickname {
  582. color: #FFFFFF;
  583. }
  584. .vip-expire {
  585. color: rgba(255, 255, 255, 0.35);
  586. }
  587. }
  588. }
  589. }
  590. }
  591. .reserveASeat {
  592. width: 100%;
  593. background: transparent;
  594. height: calc(var(--status-bar-height) + 90rpx);
  595. }
  596. }
  597. .vip-content {
  598. background: #fff;
  599. border-top-left-radius: 32rpx;
  600. border-top-right-radius: 32rpx;
  601. .vip-price-options {
  602. display: flex;
  603. justify-content: space-between;
  604. padding: 32rpx;
  605. margin-top: -60rpx;
  606. .price-option {
  607. width: 218rpx;
  608. height: 250rpx;
  609. background-color: #fff;
  610. border-radius: 20rpx;
  611. display: flex;
  612. flex-direction: column;
  613. justify-content: center;
  614. align-items: center;
  615. position: relative;
  616. transition: all 0.3s;
  617. border-radius: 20rpx;
  618. border: 4rpx solid #E9E9E9;
  619. padding-top: 48rpx;
  620. padding-bottom: 34rpx;
  621. .price-left-img {
  622. min-width: 160rpx;
  623. height: 48rpx;
  624. padding: 6rpx 12rpx 14rpx 12rpx;
  625. position: absolute;
  626. left: -6rpx;
  627. top: -4rpx;
  628. background: url("../../static/vip/hy_biaoqian_02.png") center/100% 100% no-repeat;
  629. font-weight: 400;
  630. font-size: 10px;
  631. color: #898888;
  632. display: flex;
  633. align-items: center;
  634. justify-content: center;
  635. }
  636. .price-tag {
  637. position: absolute;
  638. bottom: -4rpx;
  639. right: -4rpx;
  640. font-family: 'PingFang SC-Bold';
  641. font-weight: 400;
  642. background-color: #4A4A4A;
  643. color: #ffffff;
  644. font-size: 24rpx;
  645. width: 86rpx;
  646. height: 36rpx;
  647. border-top-left-radius: 20rpx;
  648. border-bottom-right-radius: 20rpx;
  649. display: flex;
  650. align-items: center;
  651. justify-content: center;
  652. }
  653. .duration {
  654. font-family: 'PingFang SC-Bold';
  655. font-weight: 400;
  656. font-size: 32rpx;
  657. color: #1F1F1F;
  658. }
  659. .price {
  660. font-size: 68rpx;
  661. font-weight: bold;
  662. color: #4A4A4A;
  663. padding-top: 10rpx;
  664. padding-bottom: 5rpx;
  665. }
  666. .originalPrice {
  667. font-size: 28rpx;
  668. color: #999999;
  669. text-decoration: line-through;
  670. }
  671. &.active {
  672. background: linear-gradient(to bottom, #F0FFD9, rgba(0, 0, 0, 0));
  673. border-color: #1f1f1f;
  674. transform: scale(1.05);
  675. .price-left-img {
  676. background: url("../../static/vip/hy_biaoqian_01.png") center/100% no-repeat;
  677. color: #ACF934;
  678. }
  679. .price {
  680. color: #7CCB00;
  681. }
  682. }
  683. }
  684. }
  685. .vip-privileges {
  686. padding: 0 30rpx;
  687. .privileges-title {
  688. font-family: 'PingFang SC-Bold';
  689. font-weight: 400;
  690. font-size: 16px;
  691. color: #1F1F1F;
  692. padding-top: 36rpx;
  693. padding-bottom: 22rpx;
  694. }
  695. .privileges-list {
  696. display: flex;
  697. flex-wrap: wrap;
  698. justify-content: space-between;
  699. }
  700. .privilege-item {
  701. width: 330rpx;
  702. height: 136rpx;
  703. flex-grow: 0;
  704. background-color: #F7F7F7;
  705. border-radius: 16rpx;
  706. padding: 26rpx;
  707. padding-right: 0;
  708. // padding-left: 20rpx;
  709. margin-bottom: 26rpx;
  710. display: flex;
  711. align-items: center;
  712. }
  713. .privilege-icon {
  714. width: 84rpx;
  715. height: 84rpx;
  716. margin-right: 20rpx;
  717. }
  718. .privilege-name {
  719. font-size: 28rpx;
  720. font-weight: 400;
  721. color: #1C2C00;
  722. margin-bottom: 10rpx;
  723. }
  724. .privilege-desc {
  725. font-size: 20rpx;
  726. color: #999999;
  727. }
  728. }
  729. .bottom-pay-btn-bottom {
  730. width: 626rpx;
  731. height: 88rpx;
  732. background: linear-gradient(90deg, #1F1F1F 0%, #444444 100%);
  733. border-radius: 76rpx;
  734. margin: 0 auto;
  735. margin-top: 70rpx;
  736. color: #ACF934;
  737. display: flex;
  738. align-items: center;
  739. justify-content: center;
  740. font-size: 32rpx;
  741. line-height: 0;
  742. text {
  743. font-size: 44rpx;
  744. display: inline-block;
  745. margin-right: 10rpx;
  746. }
  747. }
  748. }
  749. .uv-notice-bar {
  750. background-color: #F2F6F2 !important;
  751. border-radius: 108rpx;
  752. width: calc(100% - 64rpx);
  753. margin: 0 auto;
  754. ::v-deep.uvicon-volume {
  755. color: #333 !important;
  756. }
  757. }
  758. .bottom-pay-btn {
  759. position: fixed;
  760. bottom: 0;
  761. left: 0;
  762. right: 0;
  763. display: flex;
  764. align-items: center;
  765. justify-content: space-between;
  766. background-color: #242424;
  767. padding: 30rpx 40rpx;
  768. box-sizing: border-box;
  769. .total-price {
  770. color: #cccccc;
  771. font-size: 28rpx;
  772. }
  773. .price-value {
  774. color: #ffffff;
  775. font-size: 40rpx;
  776. font-weight: bold;
  777. }
  778. .pay-button {
  779. background: linear-gradient(to right, #9758DE, #5F17DD);
  780. color: #ffffff;
  781. padding: 20rpx 60rpx;
  782. border-radius: 50rpx;
  783. font-size: 32rpx;
  784. }
  785. }
  786. /* 支付方式选择弹窗样式 */
  787. .payment-popup {
  788. background-color: #ffffff;
  789. border-radius: 24rpx 24rpx 0 0;
  790. padding: 40rpx;
  791. .popup-header {
  792. display: flex;
  793. justify-content: center;
  794. align-items: center;
  795. margin-bottom: 40rpx;
  796. position: relative;
  797. }
  798. .popup-title {
  799. font-size: 32rpx;
  800. color: #333;
  801. font-weight: 500;
  802. text-align: center;
  803. }
  804. .popup-close {
  805. position: absolute;
  806. right: 0;
  807. top: 50%;
  808. transform: translateY(-50%);
  809. font-size: 48rpx;
  810. color: #999999;
  811. line-height: 1;
  812. }
  813. .payment-options {
  814. margin-bottom: 40rpx;
  815. }
  816. .payment-option {
  817. display: flex;
  818. align-items: center;
  819. padding: 32rpx 0;
  820. border-bottom: 1rpx solid #EEEEEE;
  821. &:last-child {
  822. border-bottom: none;
  823. }
  824. }
  825. .payment-icon {
  826. width: 72rpx;
  827. height: 72rpx;
  828. margin-right: 24rpx;
  829. }
  830. .payment-name {
  831. flex: 1;
  832. color: #333;
  833. font-size: 32rpx;
  834. }
  835. .payment-select {
  836. width: 40rpx;
  837. height: 40rpx;
  838. }
  839. .confirm-payment {
  840. background: #333333;
  841. color: #ACF934;
  842. text-align: center;
  843. padding: 28rpx 0;
  844. border-radius: 76rpx;
  845. font-size: 32rpx;
  846. margin-top: 60rpx;
  847. font-weight: 500;
  848. }
  849. }
  850. ::v-deep .uni-popup .uni-popup__wrapper {
  851. border-radius: 24rpx 24rpx 0 0;
  852. }
  853. ::v-deep .uni-popup .uni-popup__wrapper-box {
  854. border-radius: 24rpx 24rpx 0 0;
  855. }
  856. .more-options {
  857. position: relative;
  858. display: inline-block;
  859. .fa {
  860. font-size: 40rpx;
  861. padding: 0 20rpx;
  862. }
  863. .dropdown-menu {
  864. position: absolute;
  865. top: calc(100% + 10rpx);
  866. right: 20rpx;
  867. background-color: #ffffff;
  868. border-radius: 20rpx;
  869. padding: 0;
  870. width: 200rpx;
  871. box-shadow: 0 4rpx 20rpx rgba(0, 0, 0, 0.1);
  872. z-index: 100;
  873. transform-origin: top right;
  874. animation: dropdownAnimation 0.2s ease-out;
  875. .dropdown-item {
  876. padding: 24rpx 0;
  877. color: #333333;
  878. font-size: 28rpx;
  879. position: relative;
  880. text-align: center;
  881. &:not(:last-child)::after {
  882. content: '';
  883. position: absolute;
  884. left: 0;
  885. right: 0;
  886. bottom: 0;
  887. height: 1rpx;
  888. background-color: #EEEEEE;
  889. }
  890. &:active {
  891. background-color: #f8f8f8;
  892. }
  893. }
  894. }
  895. }
  896. @keyframes dropdownAnimation {
  897. 0% {
  898. opacity: 0;
  899. transform: scale(0.95) translateY(-5rpx);
  900. }
  901. 100% {
  902. opacity: 1;
  903. transform: scale(1) translateY(0);
  904. }
  905. }
  906. }
  907. .agree {
  908. width: 80%;
  909. margin: 0 auto;
  910. text-align: center;
  911. color: #1f1f1f;
  912. font-size: 22rpx;
  913. margin-top: 40rpx;
  914. display: flex;
  915. align-items: center;
  916. text-align: left;
  917. .agree2 {
  918. display: flex;
  919. flex-direction: row;
  920. justify-content: center;
  921. align-items: center;
  922. }
  923. .xy {
  924. color: #0084FF;
  925. }
  926. image {
  927. width: 32rpx;
  928. margin-right: 8rpx;
  929. }
  930. }
  931. </style>