benefitPackage.vue 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778
  1. <template>
  2. <view class="page">
  3. <!-- 头部切换 -->
  4. <u-sticky zIndex="999" customNavHeight="0">
  5. <uni-NavBar headerTitle="权益套餐" background="#fff" :isSlot="false" :rightSlot="true"
  6. borderBottom="1rpx solid #eee">
  7. </uni-NavBar>
  8. <uni-dropdown :close-on-click-mask="mask" ref="uDropdown" :activeColor="activeColor" border-radius="10"
  9. menuIcon="arrow-down-fill" :borderBottom="borderBottom" @menuClick="menuClick">
  10. <uni-dropdown-item :title="location.cityName || '地区'"></uni-dropdown-item>
  11. <uni-dropdown-item title="价格区间">
  12. <view class="slotArea">
  13. <view class="p-3">
  14. <!-- 双边滑动选择器 -->
  15. <view class="slider-header dis a-c j-s ">
  16. <text>价值</text>
  17. <text>{{ queryInfo.minPrice }}-{{ queryInfo.maxPrice }}元</text>
  18. </view>
  19. <view style="padding: 0 40rpx;">
  20. <uni-tianzai-slider-range :step="1" :min="0" :max="1000"
  21. :value="[queryInfo.minPrice, queryInfo.maxPrice]" @change="onChange" @end="onEnd">
  22. </uni-tianzai-slider-range>
  23. </view>
  24. <view class="options dis a-c f-wrap mt-3">
  25. <view class="options-card dis a-c j-c"
  26. :class="item.label == priceRangeName ? 'active' : ''"
  27. v-for="(item, index) in priceRangeOptions" :key="index"
  28. @click="filterCriteriaClick(item)">
  29. {{ item.label }}
  30. </view>
  31. </view>
  32. </view>
  33. <!-- 按钮 -->
  34. <view class="slider-btn dis a-c j-s">
  35. <view class="btn dis a-c j-c mr-3" @click="clearForm">
  36. 清空
  37. </view>
  38. <view class="btn btns dis a-c j-c" @click="querySearch">
  39. 确定
  40. </view>
  41. </view>
  42. </view>
  43. </uni-dropdown-item>
  44. <uni-dropdown-item title="默认排序">
  45. <view class="slotArea">
  46. <view class="sort">
  47. <view class="item dis a-c " @click="sortItem(item.value)"
  48. v-for="(item, index) in sortOrderOptions" :key="index">
  49. <text class="text" :class="{ 'sort-active': item.value === queryInfo.sortType }">{{
  50. item.label }}</text>
  51. <view class="slice dis a-c j-c " v-if="item.value === queryInfo.sortType">
  52. <u-icon name="checkmark" color="#333" size="11" :bold="true"></u-icon>
  53. </view>
  54. </view>
  55. </view>
  56. </view>
  57. </uni-dropdown-item>
  58. </uni-dropdown>
  59. </u-sticky>
  60. <!-- 内容 -->
  61. <view class="content-body">
  62. <!-- 权益列表 -->
  63. <view class="view-card dis f-c " v-for="(item, index) in benefitPackageList" :key="index"
  64. v-if="benefitPackageList.length">
  65. <!-- 权益信息 -->
  66. <view class="dis view-header">
  67. <!-- 图片 -->
  68. <image class="image" :src="item.packageImage" mode=""></image>
  69. <view class="content dis f-c j-s">
  70. <u--text :lines="1" :text="item.equityPackageName" color="#333" size="16" :bold="true"
  71. style="line-height: 1;flex:0 auto;"></u--text>
  72. <view class="sum dis a-c ">
  73. <!-- 市场价/ 券数量 -->
  74. <text class="couponCount mr-2">券数量{{ item.totalNumber }}张</text>
  75. <text class="marketPrice">市场价 {{ item.totalPackagePrice }}</text>
  76. <u-number-box v-model="item.rightsCount" :min="0" style="margin-left: auto;"
  77. @change="val => onRightsCountChange(val, index, 'benefitPackageList', 'packagePrice')"
  78. :asyncChange="true">
  79. <view slot="minus" class="numberBoxMinus dis a-c j-c ">
  80. <u-icon name="minus" size="12" color="#333" bold></u-icon>
  81. </view>
  82. <text slot="input" class="numberBoxInput">
  83. {{ item.rightsCount }}
  84. </text>
  85. <view slot="plus" class="numberBoxPlus dis a-c j-c ">
  86. <u-icon name="plus" color="#333" size="12" bold></u-icon>
  87. </view>
  88. </u-number-box>
  89. </view>
  90. <view class=" dis a-c j-s ">
  91. <text class="plice">¥{{ item.packagePrice }}</text>
  92. <view class="Detail dis a-c " @click="rightsDetails(item, index)">
  93. <text>查看明细</text>
  94. <u-icon :name="item.vehicleTaxIsExpanded ? 'arrow-up' : 'arrow-down'" color="#FFAC1D"
  95. size="12"></u-icon>
  96. </view>
  97. </view>
  98. </view>
  99. </view>
  100. <!-- 明细列表 -->
  101. <view class="Detail-list"
  102. v-if="item.vehicleTaxIsExpanded && item.rightsDetailsList && item.rightsDetailsList.length > 0">
  103. <view class="view">
  104. <view class="dis view-header" v-for="(DetailsItem, DetailsIndex) in item.rightsDetailsList"
  105. :key="DetailsIndex">
  106. <image class="image" :src="DetailsItem.rightsPicture" mode=""
  107. style="height: 116rpx;width: 116rpx;">
  108. </image>
  109. <view class="content dis f-c j-s ">
  110. <u--text :lines="1" :text="DetailsItem.rightsName" color="#333" size="16" :bold="true"
  111. style="line-height: 1;flex:0 auto;"></u--text>
  112. <view class="sum dis a-c mt-1 mb-1">
  113. <text class="marketPrice">市场价 {{ DetailsItem.marketPrice }}</text>
  114. </view>
  115. <text class="plice">¥{{ DetailsItem.contractRate }}</text>
  116. </view>
  117. </view>
  118. </view>
  119. </view>
  120. </view>
  121. </view>
  122. <u-empty v-if="benefitPackageList.length == 0" mode="car" icon="/static/image/Empty1.png"
  123. text="没有可用的权益券,换个地区试试~" width="120" height="120">
  124. </u-empty>
  125. <!-- 底部样式 -->
  126. <view class="footer dis a-c">
  127. <!-- 图标 -->
  128. <view class="icon-view dis f-c a-c ">
  129. <view class="">
  130. <image src="/static/icon/balance/balance.png" mode=""></image>
  131. <u-badge numberType="overflow" :max="99" :value="selectedCount" :absolute="true" color="#fff"
  132. bgColor="#FF4545" :offset="[-5, -5]" style="font-size: 18rpx;"></u-badge>
  133. </view>
  134. <text>已选</text>
  135. </view>
  136. <!-- 价格 -->
  137. <view class="dis f-c a-start">
  138. <view class="price">
  139. <text>¥</text>
  140. <text>{{ totalPriceCount }}</text>
  141. </view>
  142. <text class="marketPrice">市场价:{{ totalMarketPriceCount }}</text>
  143. </view>
  144. <view class="footer-btn" @click="userRightsSubmit">
  145. 立即发放
  146. </view>
  147. </view>
  148. <!-- 省市区组件 -->
  149. <uni-areaCascadePicker :show="addressPickershow" @confirm="addressConfirm" @close="areaCascadeClose"
  150. @cancel="addressPickershow = false"></uni-areaCascadePicker>
  151. <!-- 自定义加载动画 -->
  152. <global-loading :show="loadingShow" :text="loadingText"></global-loading>
  153. </view>
  154. </template>
  155. <script>
  156. import LocationService from '@/utils/location';
  157. import Decimal from 'decimal.js';
  158. export default {
  159. data() {
  160. return {
  161. availableAmount: 0, //可用金额
  162. loadingShow: true, //加载
  163. loadingText: '加载中', //加载提示文字
  164. vehicleTaxIsExpanded: false, //明细 展开收起
  165. // 位置信息
  166. location: {
  167. cityName: "",
  168. },
  169. benefitPackageList: [], //权益套餐列表
  170. privilegeItem: [], //权益单品列表
  171. // 页面初始化查询信息
  172. queryInfo: {
  173. countryAll: "", //省市区
  174. minPrice: 0,
  175. maxPrice: 1000,
  176. sortType: 0, //排序 0 默认 1低价 2高价
  177. pageNo: 1,
  178. pageSize: 20,
  179. },
  180. addressPickershow: false, //省市区组件
  181. mask: true, //点遮罩关闭
  182. borderBottom: true,
  183. activeColor: '#333', //下拉菜单选中激活项
  184. doubleResult: null,
  185. singleResult: null,
  186. statusCurrent: 1, //状态tabs切换
  187. statusList: [{
  188. name: "权益套餐",
  189. },
  190. {
  191. name: "权益单品",
  192. },
  193. ],
  194. // 排序
  195. sortOrderOptions: [{
  196. label: '默认排序',
  197. value: 0,
  198. },
  199. {
  200. label: '低价优先',
  201. value: 1,
  202. },
  203. {
  204. label: '高价优先',
  205. value: 2,
  206. }
  207. ],
  208. priceRangeName: "", //区间选中
  209. // 价格区间列表
  210. priceRangeOptions: [{
  211. label: "100元以下",
  212. value: [0, 100]
  213. },
  214. {
  215. label: "100-200元",
  216. value: [100, 200]
  217. },
  218. {
  219. label: "200-300元",
  220. value: [200, 300]
  221. },
  222. {
  223. label: "300-400元",
  224. value: [300, 400]
  225. },
  226. {
  227. label: "400-500元",
  228. value: [400, 500]
  229. },
  230. {
  231. label: "500-1000元",
  232. value: [500, 1000]
  233. },
  234. ],
  235. }
  236. },
  237. onShow() {
  238. },
  239. async onLoad(options) {
  240. this.loadingShow = true;
  241. try {
  242. if (options) {
  243. this.availableAmount = options.availableAmount;
  244. this.queryInfo.maxPrice = this.availableAmount;
  245. }
  246. // 获取定位城市信息
  247. const locationData = await LocationService.initLocation();
  248. if (locationData.provinceCode) {
  249. this.queryInfo.countryAll =
  250. `${locationData.provinceCode},${locationData.cityCode},${locationData.districtCode}`; //
  251. this.location.cityName =
  252. `${locationData.provinceName}-${locationData.cityName}-${locationData.districtName}`;
  253. }
  254. await this.getbenefitPackageList(); //权益套餐列表
  255. await this.getprivilegeItem(); //权益单品列表
  256. this.loadingShow = false;
  257. } catch (error) {
  258. this.loadingShow = false;
  259. }
  260. },
  261. computed: {
  262. selectedCount() {
  263. const total = this.benefitPackageList.reduce(
  264. (sum, item) => sum.plus(new Decimal(item.rightsCount)),
  265. new Decimal(0)
  266. );
  267. const sum = new Decimal(total);
  268. return sum.toString();
  269. },
  270. //选中售价总和
  271. totalPriceCount() {
  272. const total = this.benefitPackageList.reduce(
  273. (sum, item) => {
  274. // 计算当前项的 packagePrice * quantity(高精度乘法)
  275. const itemTotal = new Decimal(item.packagePrice).times(new Decimal(item.rightsCount));
  276. // 累加到总和
  277. return sum.plus(itemTotal);
  278. },
  279. new Decimal(0) // 初始值
  280. );
  281. const sum = new Decimal(total);
  282. return sum.toString(); // 返回字符串
  283. },
  284. //选中市场价总和
  285. totalMarketPriceCount() {
  286. const total = this.benefitPackageList.reduce(
  287. (sum, item) => {
  288. // 计算当前项的 packagePrice * quantity(高精度乘法)
  289. const itemTotal = new Decimal(item.totalPackagePrice).times(new Decimal(item.rightsCount));
  290. // 累加到总和
  291. return sum.plus(itemTotal);
  292. },
  293. new Decimal(0) // 初始值
  294. );
  295. const sum = new Decimal(total);
  296. return sum.toString(); // 返回字符串
  297. }
  298. },
  299. methods: {
  300. // 权益数量变化监听
  301. onRightsCountChange(e, index, name, field) {
  302. // 获取当前项
  303. const item = this[name][index];
  304. // 获取当前数量和新数量
  305. const currentCount = item.rightsCount;
  306. const newCount = e.value;
  307. // 计算价格
  308. const price = parseFloat(item[field]);
  309. // 计算当前总价
  310. const currentTotalPrice = parseFloat(this.totalPriceCount);
  311. // 计算数量变化和价格变化
  312. const countChange = newCount - currentCount;
  313. const priceChange = countChange * price;
  314. // 计算新总价
  315. const newTotalPrice = currentTotalPrice + priceChange;
  316. // 如果是增加数量,检查是否超过可用金额
  317. if (countChange > 0 && newTotalPrice > this.availableAmount) {
  318. uni.showToast({
  319. title: `权益总价不能超过可用金额${this.availableAmount}元`,
  320. icon: 'none'
  321. });
  322. } else {
  323. // 无论是减少数量还是增加数量且未超过限制,都允许更新
  324. item.rightsCount = newCount;
  325. }
  326. },
  327. // 确认选择
  328. async userRightsSubmit() {
  329. // 验证是否有选择权益
  330. if (parseInt(this.selectedCount) === 0) {
  331. uni.showToast({
  332. title: '请至少选择一项权益',
  333. icon: 'none'
  334. });
  335. return;
  336. }
  337. // 收集选择的权益套餐
  338. const selectedPackages = this.benefitPackageList
  339. .filter(item => item.rightsCount > 0)
  340. let pages = getCurrentPages(); //获取所有页面栈实例列表
  341. let prevPage = pages[pages.length - 2]; //上一页页面实例
  342. prevPage.$vm.insOrderRightsPackageList = selectedPackages; //选中权益列表
  343. uni.navigateBack({ //uni.navigateTo跳转的返回,默认1为返回上一级
  344. delta: 1
  345. });
  346. },
  347. //获取权益套餐列表
  348. async getbenefitPackageList() {
  349. let res = await this.$http.post('/rightsGrant/package/list', this.queryInfo);
  350. if (res.code == 200) {
  351. res.data.records.map(val => {
  352. val.vehicleTaxIsExpanded = false;
  353. return val;
  354. })
  355. this.benefitPackageList = res.data.records;
  356. }
  357. },
  358. // 获取权益明细
  359. async rightsDetails(item, index) {
  360. if (!item.rightsDetailsList) {
  361. let res = await this.$http.get(`/rightsGrant/package/detail/${item.id}`);
  362. if (res.code == 200) {
  363. this.benefitPackageList[index].rightsDetailsList = res.data; //群益明细赋值对应套餐
  364. this.benefitPackageList[index].vehicleTaxIsExpanded = !this.benefitPackageList[index]
  365. .vehicleTaxIsExpanded; //展开收起
  366. }
  367. } else {
  368. this.benefitPackageList[index].vehicleTaxIsExpanded = !this.benefitPackageList[index]
  369. .vehicleTaxIsExpanded; //展开收起
  370. }
  371. },
  372. // 省市区选择回调
  373. async addressConfirm(e) {
  374. this.queryInfo.countryAll = e.codes.join(',') || "";
  375. this.location.cityName = e.fullAddress;
  376. this.addressPickershow = false;
  377. this.$refs.uDropdown.close();
  378. await this.getbenefitPackageList();
  379. },
  380. // 查看明细
  381. detailClick() {
  382. },
  383. async querySearch() {
  384. console.log(this.statusCurrent);
  385. this.$refs.uDropdown.close();
  386. await this.getbenefitPackageList();
  387. },
  388. //清空价格区间
  389. async clearForm() {
  390. this.queryInfo.minPrice = 0;
  391. this.queryInfo.maxPrice = 1000;
  392. this.priceRangeName = "";
  393. this.$refs.uDropdown.close();
  394. await this.getbenefitPackageList();
  395. },
  396. filterCriteriaClick(item) {
  397. this.priceRangeName = item.label;
  398. this.queryInfo.minPrice = item.value[0];
  399. this.queryInfo.maxPrice = item.value[1];
  400. },
  401. //排序选择
  402. async sortItem(value) {
  403. this.queryInfo.sortType = value;
  404. this.$refs.uDropdown.close();
  405. await this.getbenefitPackageList();
  406. },
  407. // 价格区间选择
  408. onChange(values) {
  409. this.queryInfo.minPrice = values[0];
  410. this.queryInfo.maxPrice = values[1];
  411. },
  412. // 下拉菜单选项事件
  413. menuClick(value) {
  414. if (value == 0) {
  415. this.addressPickershow = true;
  416. }
  417. },
  418. onEnd(event) {
  419. console.log('最终选择:', event.values);
  420. },
  421. areaCascadeClose() {
  422. this.addressPickershow = false;
  423. this.$refs.uDropdown.close();
  424. },
  425. }
  426. }
  427. </script>
  428. <style lang="scss" scoped>
  429. page {
  430. background-color: #F8F8F8;
  431. height: 100vh;
  432. }
  433. .container {
  434. padding: 20rpx;
  435. }
  436. .dropdown-title {
  437. font-size: 32rpx;
  438. color: #333;
  439. }
  440. .reward-tabs {
  441. margin-right: 48rpx;
  442. flex: 1;
  443. }
  444. /* 自定义tab滑块样式 */
  445. ::v-deep .u-tabs__wrapper__nav__line {
  446. background-color: transparent !important;
  447. font-size: 30px;
  448. }
  449. ::v-deep .u-tabs__wrapper__nav__item__text {
  450. font-size: 32rpx;
  451. }
  452. .slotArea {
  453. background-color: #FFFFFF;
  454. border-top: 1rpx solid #eee;
  455. .slider-header {
  456. text:first-child {
  457. font-size: 30rpx;
  458. color: #333;
  459. font-weight: bold;
  460. }
  461. text:last-child {
  462. font-size: 28rpx;
  463. color: #333;
  464. }
  465. }
  466. .slider-btn {
  467. background: #FFFFFF;
  468. border-radius: 0rpx 0rpx 20rpx 20rpx;
  469. border-top: 1rpx solid #EEEEEE;
  470. padding: 30rpx 44rpx;
  471. box-sizing: border-box;
  472. .btn {
  473. padding: 18rpx 30rpx;
  474. box-sizing: border-box;
  475. width: 50%;
  476. border-radius: 50rpx 50rpx 50rpx 50rpx;
  477. border: 1rpx solid #FDE935;
  478. font-size: 30rpx;
  479. color: #333;
  480. }
  481. .btns {
  482. width: 50%;
  483. background: #FDE935;
  484. border-radius: 50rpx 50rpx 50rpx 50rpx;
  485. }
  486. }
  487. .sort {
  488. padding: 30rpx;
  489. box-sizing: border-box;
  490. display: grid;
  491. grid-template-columns: repeat(1, 1fr);
  492. grid-template-rows: auto;
  493. row-gap: 30rpx;
  494. .item {
  495. text {
  496. font-size: 30rpx;
  497. color: #333;
  498. }
  499. .slice {
  500. margin-left: auto;
  501. width: 32rpx;
  502. height: 32rpx;
  503. background: #FDE935;
  504. border-radius: 20rpx 20rpx 20rpx 20rpx;
  505. }
  506. }
  507. .sort-active {
  508. font-weight: bold;
  509. }
  510. }
  511. .item-box {
  512. margin-bottom: 50rpx;
  513. display: flex;
  514. flex-wrap: wrap;
  515. justify-content: space-between;
  516. .item {
  517. border: 1px solid #f2f2f2;
  518. color: #333;
  519. padding: 8rpx 40rpx;
  520. border-radius: 100rpx;
  521. margin-top: 30rpx;
  522. }
  523. .active {
  524. color: #FFFFFF;
  525. background-color: #000;
  526. }
  527. }
  528. .options {
  529. display: grid;
  530. /* 启用网格布局 */
  531. grid-template-columns: repeat(3, 1fr);
  532. /* 3 列,每列等宽 */
  533. grid-template-rows: auto;
  534. /* 行高自适应 */
  535. row-gap: 30rpx;
  536. /* 只设置行间距(上下) */
  537. column-gap: 20rpx;
  538. /* 列间距设为 0(可选) */
  539. }
  540. .options-card {
  541. padding: 11rpx 24rpx;
  542. box-sizing: border-box;
  543. border-radius: 4rpx 4rpx 4rpx 4rpx;
  544. border: 1rpx solid #EEEEEE;
  545. font-size: 28rpx;
  546. color: #666;
  547. }
  548. .active {
  549. background-color: rgba(253, 233, 53, 0.2);
  550. border: 1rpx solid #FDE935;
  551. color: #333;
  552. }
  553. }
  554. .content-body {
  555. padding: 20rpx 30rpx 166rpx;
  556. box-sizing: border-box;
  557. position: relative;
  558. .view-card {
  559. background-color: #fff;
  560. border-radius: 10rpx;
  561. margin-bottom: 20rpx;
  562. .view-header {
  563. padding: 25rpx 30rpx;
  564. box-sizing: border-box;
  565. .image {
  566. width: 136rpx;
  567. height: 136rpx;
  568. border-radius: 10rpx;
  569. flex-shrink: 0;
  570. margin-right: 20rpx;
  571. }
  572. .content {
  573. flex: 1;
  574. min-width: 0;
  575. line-height: 1;
  576. .sum {
  577. text {
  578. font-size: 24rpx;
  579. color: #666;
  580. }
  581. }
  582. .plice {
  583. font-size: 30rpx;
  584. color: #FF540A;
  585. font-weight: bold;
  586. line-height: 1;
  587. }
  588. .Detail {
  589. font-size: 26rpx;
  590. color: #FFAC1D;
  591. line-height: 1.4;
  592. text {
  593. margin-right: 5rpx;
  594. }
  595. }
  596. }
  597. }
  598. .Detail-list {
  599. padding: 0 30rpx 25rpx;
  600. box-sizing: border-box;
  601. .view {
  602. background-color: #f8f8f8;
  603. border-radius: 6rpx;
  604. padding: 10rpx 20rpx;
  605. .view-header {
  606. padding: 20rpx 0;
  607. box-sizing: border-box;
  608. border-bottom: 1rpx solid #eee;
  609. }
  610. .view-header:last-child {
  611. border-bottom: none;
  612. }
  613. }
  614. }
  615. }
  616. }
  617. // 步进器自定义样式
  618. .numberBoxMinus {
  619. width: 32rpx;
  620. height: 32rpx;
  621. border-radius: 20rpx 20rpx 20rpx 20rpx;
  622. border: 1rpx solid #FDE935;
  623. }
  624. .numberBoxInput {
  625. font-size: 30rpx;
  626. color: #333;
  627. padding: 0 20rpx;
  628. box-sizing: border-box;
  629. text-align: center;
  630. }
  631. .numberBoxPlus {
  632. width: 32rpx;
  633. height: 32rpx;
  634. border-radius: 20rpx 20rpx 20rpx 20rpx;
  635. background-color: #FDE935;
  636. border: 1rpx solid #FDE935;
  637. }
  638. .footer {
  639. position: fixed;
  640. bottom: 0;
  641. left: 0;
  642. right: 0;
  643. padding: 25rpx 30rpx 55rpx;
  644. box-sizing: border-box;
  645. background: linear-gradient(0deg, #FFFFFF 0%, rgba(255, 254, 245, 0.7) 100%);
  646. border-radius: 0rpx 0rpx 0rpx 0rpx;
  647. backdrop-filter: blur(12rpx);
  648. .icon-view {
  649. margin-right: 30rpx;
  650. >view {
  651. position: relative;
  652. image {
  653. width: 48rpx;
  654. height: 48rpx;
  655. }
  656. }
  657. text {
  658. font-size: 20rpx;
  659. color: #333;
  660. }
  661. }
  662. .price {
  663. text:nth-child(1) {
  664. font-size: 28rpx;
  665. color: #FF540A;
  666. }
  667. text:nth-child(2) {
  668. font-size: 42rpx;
  669. color: #FF540A;
  670. }
  671. }
  672. .marketPrice {
  673. font-size: 20rpx;
  674. color: #999;
  675. letter-spacing: 1rpx;
  676. margin-left: 4rpx;
  677. }
  678. .footer-btn {
  679. padding: 20rpx 68rpx;
  680. box-sizing: border-box;
  681. background: #FDE935;
  682. border-radius: 58rpx 58rpx 58rpx 58rpx;
  683. font-size: 36rpx;
  684. color: #1F1F1F;
  685. font-weight: bold;
  686. // #ifdef H5
  687. margin-right: 0;
  688. // #endif
  689. // #ifdef APP-PLUS
  690. margin-left: auto;
  691. // #endif
  692. }
  693. }
  694. .tabView {
  695. padding: 20rpx 0;
  696. box-sizing: border-box;
  697. background-color: #fff;
  698. }
  699. .u-empty {
  700. position: absolute;
  701. top: 50%;
  702. left: 50%;
  703. transform: translate(-50%, -50%);
  704. /* 反向偏移自身宽高的50% */
  705. }
  706. </style>