collection.vue 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791
  1. <template>
  2. <view class="container product clearfix">
  3. <view class="superv-header" v-if="!isEmpty">
  4. <view class="superv-header-click">
  5. <view class="oltext"
  6. >共<text class="red">{{ totalRecord }}</text
  7. >件商品</view
  8. >
  9. <view class="ortext" @click="showPopup(0)" v-if="!popupShow">编辑</view>
  10. <view class="ortext" @click="hidePopup(0)" v-else>完成</view>
  11. </view>
  12. </view>
  13. <view class="product-content" :style="{ paddingBottom: popupShow ? '68rpx' : '0' }">
  14. <view :class="{ 'tui-order-list': scrollTop >= 0 }" class="clearfix">
  15. <!-- 空白页 -->
  16. <view class="empty-container" v-if="isEmpty">
  17. <image
  18. class="empty-container-image"
  19. :src="staticUrl + 'icon_like_empty@2x.png'"
  20. ></image>
  21. <text class="error-text">暂无收藏商品~</text>
  22. </view>
  23. <!-- 列表 -->
  24. <view class="tui-cart-cell tui-mtop" v-for="(pros, index) in productList" :key="index">
  25. <view class="tui-goods-item">
  26. <view class="tui-goods-main">
  27. <view class="tui-goods-checkBox" v-if="popupShow">
  28. <view
  29. class="checkbox iconfont"
  30. :class="[pros.isChecked ? 'icon-yixuanze' : 'icon-weixuanze']"
  31. @click="checkedSoperv(pros)"
  32. >
  33. </view>
  34. </view>
  35. <view class="tui-goods-image" @click.stop="navToDetailPage(pros.productId)">
  36. <image :src="pros.image" class="tui-goods-img" />
  37. </view>
  38. <view
  39. class="tui-goods-info"
  40. :style="{ width: popupShow ? '420rpx' : '528rpx' }"
  41. @click.stop="navToDetailPage(pros.productId)"
  42. >
  43. <text class="list-details-title">{{ pros.name }}</text>
  44. <text class="list-details-specs">规格:{{ pros.unit != null ? pros.unit : '' }}</text>
  45. <view class="list-details-price">
  46. <view class="list-price">
  47. <text class="price-larger"> ¥{{ pros.price | NumFormat }} </text>
  48. </view>
  49. <view class="add-cart-btn" v-if="!popupShow" @click.stop="showPopup(1, pros)"
  50. >数量</view
  51. >
  52. </view>
  53. </view>
  54. </view>
  55. </view>
  56. </view>
  57. <!--加载loadding-->
  58. <tui-loadmore :visible="loadding" :index="3" type="black"></tui-loadmore>
  59. <tui-nomore :visible="!pullUpOn" :backgroundColor="'#ffffff'" :text="nomoreText"></tui-nomore>
  60. <!--加载loadding-->
  61. </view>
  62. </view>
  63. <!-- 取消收藏操作 -->
  64. <tui-bottom-popup :radius="false" :mask="false" :show="popupShow">
  65. <view class="tui-popup-box clearfix">
  66. <view class="tui-right-flex tui-popup-btn" :style="{ paddingBottom: isIphoneX ? '68rpx' : '0rpx' }">
  67. <view class="tui-flex-1">
  68. <view class="superv-header-checked">
  69. <view class="oltext" @click="isCheckedAll">
  70. <view
  71. class="checkbox iconfont"
  72. :class="[isAllChecked ? 'icon-yixuanze' : 'icon-weixuanze']"
  73. ></view>
  74. <view class="text">全选</view>
  75. </view>
  76. </view>
  77. <view class="tui-button" :class="isProductChecked ? 'active' : ''" @click="handleAllUnder"
  78. >取消收藏</view
  79. >
  80. </view>
  81. </view>
  82. </view>
  83. </tui-bottom-popup>
  84. <!-- 选择规格弹窗 -->
  85. <cm-unit-popup
  86. v-if="popupShow1"
  87. :popupShow="popupShow1"
  88. :skuProduct="handleData"
  89. @skuClick="handleSkuClick"
  90. ></cm-unit-popup>
  91. <!-- 弹窗提示 -->
  92. <tui-modal
  93. :show="modal"
  94. @click="handleClick"
  95. @cancel="hideMobel"
  96. :content="contentModalText"
  97. :button="modalButton"
  98. color="#333"
  99. :size="32"
  100. shape="circle"
  101. :maskClosable="false"
  102. >
  103. </tui-modal>
  104. <!-- 可拖动悬浮按钮 -->
  105. <cm-drag
  106. :cartNum="cartQuantity"
  107. :isDock="true"
  108. :existTabBar="true"
  109. @btnClick="btnClick"
  110. @btnTouchstart="btnTouchstart"
  111. @btnTouchend="btnTouchend"
  112. >
  113. </cm-drag>
  114. </view>
  115. </template>
  116. <script>
  117. import cmDrag from '@/components/cm-custom/cm-drag.vue'
  118. import cmUnitPopup from '@/components/cm-module/productDetails/cm-unit-popup.vue'
  119. import { mapState, mapMutations } from 'vuex'
  120. const defaultListQuery = {
  121. userId: 0,
  122. pageNum: 1,
  123. pageSize: 10
  124. }
  125. export default {
  126. components: {
  127. cmDrag,
  128. cmUnitPopup
  129. },
  130. data() {
  131. return {
  132. staticUrl:this.global.staticUrl,
  133. isIphoneX: this.$store.state.isIphoneX,
  134. modalButton: [
  135. {
  136. text: '取消',
  137. type: 'gray',
  138. plain: true //是否空心
  139. },
  140. {
  141. text: '确认',
  142. customStyle: {
  143. color: '#fff',
  144. bgColor: 'linear-gradient(90deg, #F28F31 0%, #F3B574 100%)'
  145. },
  146. plain: false
  147. }
  148. ],
  149. totalRecord: 0,
  150. cartQuantity: 0,
  151. popupShow: false,
  152. popupShow1: false,
  153. isProductChecked: false,
  154. listQuery: Object.assign({}, defaultListQuery),
  155. productList: [],
  156. handleData: {},
  157. scrollTop: 0,
  158. isEmpty: false,
  159. isAllChecked: false,
  160. loadding: false,
  161. pullUpOn: true,
  162. pullFlag: true,
  163. hasNextPage: false,
  164. navbarHeight: '',
  165. nomoreText: '上拉显示更多',
  166. contentModalText: '', //操作文字提示语句
  167. modal: false,
  168. vipFlag: 0,
  169. userIdentity: 0,
  170. firstClubType: 0
  171. }
  172. },
  173. onLoad() {
  174. this.initGetStotage()
  175. },
  176. filters: {
  177. NumFormat: function(value) {
  178. //处理金额
  179. if (!value) return '0.00'
  180. let number = Number(value).toFixed(2)
  181. return number
  182. }
  183. },
  184. computed: {
  185. ...mapState(['hasLogin', 'userInfo', 'clubType'])
  186. },
  187. methods: {
  188. ...mapMutations(['login', 'logout']),
  189. async initGetStotage() {
  190. const userInfo = await this.$api.getStorage()
  191. this.listQuery.userId = userInfo.userId ? userInfo.userId : 0
  192. this.vipFlag = userInfo.vipFlag ? userInfo.vipFlag : 0
  193. this.userIdentity = userInfo.userIdentity ? userInfo.userIdentity : 0
  194. this.firstClubType = this.clubType
  195. this.GetProductListInfo()
  196. this.ProductCartNumber()
  197. },
  198. GetProductListInfo() {
  199. this.productList = []
  200. this.listQuery.pageNum = 1
  201. this.ProductService.getProductUserLikeList(this.listQuery)
  202. .then(response => {
  203. let data = response.data
  204. if (data.results && data.results.length > 0) {
  205. this.isEmpty = false
  206. this.hasNextPage = data.hasNextPage
  207. this.totalRecord = data.totalRecord
  208. this.productList = data.results
  209. this.pullFlag = false
  210. setTimeout(() => {
  211. this.pullFlag = true
  212. }, 500)
  213. if (this.hasNextPage) {
  214. this.pullUpOn = false
  215. this.nomoreText = '上拉显示更多'
  216. } else {
  217. if (this.productList.length < 8) {
  218. this.pullUpOn = true
  219. } else {
  220. this.pullUpOn = false
  221. this.loadding = false
  222. this.nomoreText = '已至底部'
  223. }
  224. }
  225. } else {
  226. this.isEmpty = true
  227. }
  228. this.isRequest = true
  229. })
  230. .catch(error => {
  231. this.$util.msg(error.msg, 2000)
  232. })
  233. },
  234. GetOnReachBottomData(index) {
  235. //上拉加载
  236. this.listQuery.pageNum += 1
  237. this.ProductService.getProductUserLikeList(this.listQuery)
  238. .then(response => {
  239. let data = response.data
  240. if (data.results && data.results.length > 0) {
  241. this.hasNextPage = data.hasNextPage
  242. this.productList = this.productList.concat(data.results)
  243. this.pullFlag = false // 防上拉暴滑
  244. setTimeout(() => {
  245. this.pullFlag = true
  246. }, 500)
  247. if (this.hasNextPage) {
  248. this.pullUpOn = false
  249. this.nomoreText = '上拉显示更多'
  250. } else {
  251. this.pullUpOn = false
  252. this.loadding = false
  253. this.nomoreText = '已至底部'
  254. }
  255. }
  256. })
  257. .catch(error => {
  258. this.$util.msg(error.msg, 2000)
  259. })
  260. },
  261. handleSkuClick(sku) {
  262. this.handleData.price = sku.price
  263. },
  264. ProductCartNumber() {
  265. // 获取用户购物车储量
  266. this.ProductService.ProductCartNumber({
  267. userId: this.listQuery.userId
  268. })
  269. .then(response => {
  270. this.cartQuantity = response.data
  271. })
  272. .catch(error => {
  273. console.log('获取购物车数量失败')
  274. })
  275. },
  276. handleAllUnder() {
  277. //批量下架操作
  278. let checkedArray = []
  279. this.productIds = ''
  280. if (this.isProductChecked) {
  281. this.productList.forEach(el => {
  282. if (el.isChecked) {
  283. checkedArray.push(el)
  284. }
  285. })
  286. checkedArray.forEach(el => {
  287. this.productIds += el.productId + ','
  288. })
  289. this.modal = true
  290. this.contentModalText = '确定要取消收藏吗?'
  291. }
  292. },
  293. handleClick(e) {
  294. //取消收藏
  295. if (e.index == 1) {
  296. this.handleDeleteUserLike()
  297. }
  298. this.modal = false
  299. },
  300. handleDeleteUserLike() {
  301. //操作取消收藏
  302. this.ProductService.getDeleteUserLike({
  303. productIds: this.productIds,
  304. userId: this.listQuery.userId
  305. })
  306. .then(response => {
  307. this.$util.msg('取消收藏成功', 2000, true, 'success')
  308. setTimeout(() => {
  309. this.GetProductListInfo()
  310. }, 2000)
  311. })
  312. .catch(error => {
  313. this.$util.msg(error.msg, 2000)
  314. })
  315. },
  316. hideMobel() {
  317. this.modal = false
  318. },
  319. updateCheckAllBtn() {
  320. //勾选单个判断全选
  321. let goodsCheckedLength = 0
  322. this.productList.forEach(item => {
  323. if (item.isChecked) {
  324. goodsCheckedLength++
  325. }
  326. })
  327. this.isAllChecked = goodsCheckedLength === this.productList.length
  328. if (goodsCheckedLength > 0) {
  329. this.isProductChecked = true
  330. } else {
  331. this.isProductChecked = false
  332. }
  333. },
  334. updateBothCheckBtn() {
  335. //全选勾选判断
  336. this.productList.forEach(item => {
  337. item.isChecked = this.isAllChecked
  338. })
  339. },
  340. isCheckedAll() {
  341. //全选
  342. this.isAllChecked = !this.isAllChecked
  343. if (this.isAllChecked) {
  344. this.isProductChecked = true
  345. } else {
  346. this.isProductChecked = false
  347. }
  348. this.updateBothCheckBtn()
  349. },
  350. checkedSoperv(item) {
  351. //选择
  352. item.isChecked = !item.isChecked
  353. console.log(item)
  354. this.updateCheckAllBtn()
  355. },
  356. showPopup(index, pros) {
  357. // 弹窗显示
  358. switch (index) {
  359. case 0:
  360. this.popupShow = true
  361. break
  362. case 1:
  363. this.popupShow1 = true
  364. this.handleData = pros
  365. break
  366. }
  367. },
  368. hidePopup(index) {
  369. // 弹窗隐藏
  370. switch (index) {
  371. case 0:
  372. this.popupShow = false
  373. break
  374. case 1:
  375. this.popupShow1 = false
  376. break
  377. }
  378. },
  379. navToDetailPage(id) {
  380. this.isModallayer = true
  381. this.$api.navigateTo(`/pages/goods/product?id=${id}`)
  382. this.isModallayer = false
  383. },
  384. btnClick() {
  385. this.$api.switchTabTo('/pages/tabBar/cart/index')
  386. },
  387. btnTouchstart() {
  388. // console.log('btnTouchstart');
  389. },
  390. btnTouchend() {
  391. // console.log('btnTouchend');
  392. }
  393. },
  394. onPageScroll(e) {
  395. //实时获取到滚动的值
  396. },
  397. onReachBottom() {
  398. if (this.hasNextPage) {
  399. this.loadding = true
  400. this.pullUpOn = true
  401. this.GetOnReachBottomData()
  402. }
  403. },
  404. onPullDownRefresh() {
  405. setTimeout(() => {
  406. this.listQuery.pageNum = 1
  407. uni.stopPullDownRefresh()
  408. }, 200)
  409. },
  410. onShow() {}
  411. }
  412. </script>
  413. <style lang="scss">
  414. @import '@/uni.scss';
  415. page {
  416. background: #fff;
  417. }
  418. .empty-container {
  419. z-index: 9999;
  420. }
  421. .superv-header {
  422. width: 100%;
  423. height: 80rpx;
  424. background-color: #f7f7f7;
  425. line-height: 80rpx;
  426. position: fixed;
  427. top: 0;
  428. left: 0;
  429. box-sizing: border-box;
  430. padding: 0 24rpx;
  431. z-index: 99;
  432. .superv-header-click {
  433. width: 100%;
  434. height: 80rpx;
  435. font-size: $font-size-30;
  436. .oltext {
  437. float: left;
  438. color: #666666;
  439. .red {
  440. color: $color-system;
  441. }
  442. }
  443. .ortext {
  444. float: right;
  445. color: #333333;
  446. text-align: right;
  447. }
  448. }
  449. }
  450. .tui-header {
  451. width: 100%;
  452. font-size: 16px;
  453. font-weight: 500;
  454. height: 32px;
  455. display: flex;
  456. align-items: center;
  457. justify-content: center;
  458. position: relative;
  459. padding: 0 40rpx;
  460. }
  461. .header-sit {
  462. width: 100%;
  463. box-sizing: border-box;
  464. height: 80rpx;
  465. line-height: 80rpx;
  466. box-sizing: border-box;
  467. padding: 0 40rpx;
  468. text-align: left;
  469. font-size: $font-size-40;
  470. color: #ffffff;
  471. font-weight: 600;
  472. font-family: '正楷';
  473. margin-top: 30rpx;
  474. .iconfont {
  475. font-size: 42rpx;
  476. margin-left: 30rpx;
  477. }
  478. }
  479. .mine {
  480. width: 100%;
  481. height: 100%;
  482. position: relative;
  483. }
  484. .product-content {
  485. width: 100%;
  486. height: auto;
  487. position: relative;
  488. padding: 0;
  489. padding-top: 80rpx;
  490. box-sizing: border-box;
  491. .empty-container-image {
  492. width: 386rpx;
  493. height: 286rpx;
  494. margin-top: -300rpx;
  495. }
  496. }
  497. .tui-goods-item {
  498. padding: 30rpx 20rpx 0 20rpx;
  499. box-sizing: border-box;
  500. position: relative;
  501. .tui-goods-main {
  502. display: flex;
  503. width: 100%;
  504. height: 100%;
  505. border-bottom: 1px solid #ebebeb;
  506. padding-bottom: 24rpx;
  507. }
  508. }
  509. .tui-goods-checkBox {
  510. display: flex;
  511. align-items: center;
  512. margin: 0 15rpx;
  513. .checkbox {
  514. display: flex;
  515. margin: 0;
  516. padding: 0;
  517. display: flex;
  518. flex-direction: column;
  519. align-items: center;
  520. box-sizing: border-box;
  521. text-align: center;
  522. text-decoration: none;
  523. border-radius: 0;
  524. -webkit-tap-highlight-color: transparent;
  525. overflow: hidden;
  526. background-color: #ffffff;
  527. font-size: 36rpx;
  528. color: $color-system;
  529. }
  530. .text {
  531. font-size: $font-size-24;
  532. margin-left: 10rpx;
  533. }
  534. }
  535. .tui-goods-image {
  536. width: 180rpx;
  537. height: 180rpx !important;
  538. border: 2rpx solid #f3f3f3;
  539. border-radius: 12rpx;
  540. position: relative;
  541. border: 2rpx solid #f3f3f3;
  542. .tui-goods-img {
  543. width: 180rpx;
  544. height: 180rpx !important;
  545. border-radius: 12rpx;
  546. flex-shrink: 0;
  547. display: block;
  548. }
  549. }
  550. .tui-goods-info {
  551. padding-left: 20rpx;
  552. box-sizing: border-box;
  553. position: relative;
  554. .list-details-title {
  555. line-height: 38rpx;
  556. text-overflow: ellipsis;
  557. overflow: hidden;
  558. display: -webkit-box;
  559. -webkit-line-clamp: 2;
  560. line-clamp: 2;
  561. -webkit-box-orient: vertical;
  562. font-size: 26rpx;
  563. color: #333333;
  564. }
  565. .list-details-specs {
  566. width: 100%;
  567. display: inline-block;
  568. margin-top: 8rpx;
  569. color: #999999;
  570. font-size: 24rpx;
  571. }
  572. .list-details-price {
  573. width: 100%;
  574. line-height: 54rpx;
  575. float: left;
  576. margin-top: 24rpx;
  577. .list-price {
  578. color: #ff2a2a;
  579. float: left;
  580. line-height: 54rpx;
  581. align-items: center;
  582. justify-content: center;
  583. .price-larger {
  584. font-size: $font-size-30;
  585. display: inline-block;
  586. &.none {
  587. text-decoration: line-through;
  588. color: #999999;
  589. }
  590. }
  591. }
  592. .add-cart-btn {
  593. float: right;
  594. width: 160rpx;
  595. height: 56rpx;
  596. line-height: 56rpx;
  597. border-radius: 30rpx;
  598. color: #fff;
  599. font-size: 24rpx;
  600. margin-right: 0;
  601. background: #F3B574;
  602. color: #ffffff;
  603. text-align: center;
  604. }
  605. }
  606. }
  607. .tui-popup-box {
  608. position: relative;
  609. box-sizing: border-box;
  610. min-height: 168rpx;
  611. padding: 6rpx 24rpx;
  612. .tui-popup-content {
  613. padding-top: 30rpx;
  614. }
  615. }
  616. .layer-smimg {
  617. width: 114rpx;
  618. height: 114rpx;
  619. float: left;
  620. border-radius: 10rpx;
  621. margin-right: 24rpx;
  622. image {
  623. width: 114rpx;
  624. height: 114rpx;
  625. border-radius: 10rpx;
  626. }
  627. }
  628. .layer-nunbox {
  629. justify-content: space-between;
  630. align-items: center;
  631. width: 536rpx;
  632. height: 88rpx;
  633. padding: 13rpx 0 0 0;
  634. float: left;
  635. .layer-nunbox-t {
  636. width: 100%;
  637. height: 44rpx;
  638. position: relative;
  639. display: flex;
  640. .layer-nunbox-text {
  641. line-height: 44rpx;
  642. font-size: $font-size-28;
  643. }
  644. .number-box {
  645. display: flex;
  646. justify-content: center;
  647. align-items: center;
  648. border: 2rpx solid #ffe6dc;
  649. border-radius: 30rpx;
  650. height: 48rpx;
  651. margin-left: 20rpx;
  652. .iconfont {
  653. font-size: $font-size-24;
  654. padding: 0 18rpx;
  655. color: #999999;
  656. text-align: center;
  657. line-height: 48rpx;
  658. font-weight: bold;
  659. background: #fef6f3;
  660. &.icon-jianhao {
  661. border-radius: 30rpx 0 0 30rpx;
  662. }
  663. &.icon-jiahao {
  664. border-radius: 0 30rpx 30rpx 0;
  665. }
  666. }
  667. .btn-input {
  668. width: 62rpx;
  669. height: 48rpx;
  670. line-height: 48rpx;
  671. background: #ffffff;
  672. border-radius: 4rpx;
  673. text-align: center;
  674. font-size: $font-size-28;
  675. }
  676. }
  677. .product-step {
  678. position: absolute;
  679. left: 45rpx;
  680. bottom: 0;
  681. height: 44rpx;
  682. background: #ffffff;
  683. }
  684. }
  685. .layer-nunbox-b {
  686. width: 100%;
  687. height: 44rpx;
  688. margin-top: 13rpx;
  689. }
  690. .text {
  691. line-height: 44rpx;
  692. font-size: $font-size-28;
  693. .p {
  694. color: #ff2a2a;
  695. }
  696. .p:first-child {
  697. margin-left: 30rpx;
  698. }
  699. .p.sm {
  700. font-size: $font-size-24;
  701. }
  702. }
  703. }
  704. .tui-popup-btn {
  705. width: 100%;
  706. height: auto;
  707. float: left;
  708. box-sizing: border-box;
  709. margin-top: 30rpx;
  710. .superv-header-checked {
  711. float: left;
  712. font-size: $font-size-30;
  713. .oltext {
  714. width: 120rpx;
  715. float: left;
  716. color: #666666;
  717. display: flex;
  718. margin-left: 10rpx;
  719. .checkbox {
  720. display: flex;
  721. margin: 0;
  722. padding: 0;
  723. display: flex;
  724. flex-direction: column;
  725. align-items: center;
  726. box-sizing: border-box;
  727. text-align: center;
  728. text-decoration: none;
  729. border-radius: 0;
  730. -webkit-tap-highlight-color: transparent;
  731. overflow: hidden;
  732. font-size: 34rpx;
  733. color: $color-system;
  734. line-height: 80rpx;
  735. }
  736. .text {
  737. float: left;
  738. line-height: 80rpx;
  739. margin-left: 15rpx;
  740. }
  741. }
  742. .ortext {
  743. width: 120rpx;
  744. float: right;
  745. color: $color-system;
  746. text-align: right;
  747. }
  748. }
  749. .tui-button {
  750. width: 210rpx;
  751. height: 88rpx;
  752. float: right;
  753. background: #e1e1e1;
  754. line-height: 88rpx;
  755. text-align: center;
  756. color: #ffffff;
  757. font-size: $font-size-28;
  758. border-radius: 44rpx;
  759. &.active {
  760. background: $btn-confirm;
  761. }
  762. }
  763. .tui-flex-btn {
  764. width: 100%;
  765. height: 88rpx;
  766. display: flex;
  767. box-sizing: border-box;
  768. padding: 0 34rpx;
  769. .button {
  770. width: 280rpx;
  771. height: 88rpx;
  772. color: #fff;
  773. display: flex;
  774. align-items: center;
  775. justify-content: center;
  776. font-size: $font-size-28;
  777. border-radius: 44rpx;
  778. &.buy {
  779. background: $btn-confirm;
  780. margin-left: 78rpx;
  781. }
  782. &.add {
  783. background: #ffe6dc;
  784. color: #F3B574;
  785. }
  786. }
  787. }
  788. }
  789. </style>