collection.vue 25 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078
  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/icon-collection-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. <template v-if="userIdentity == 4">
  46. <view class="list-details-price" v-if="pros.priceFlag == 1">
  47. <view class="list-none"><view class="price-small">¥未公开价格</view></view>
  48. </view>
  49. <view class="list-details-price" v-else-if="pros.priceFlag == 2">
  50. <view class="list-none"><view class="price-small">¥价格仅会员可见</view></view>
  51. </view>
  52. <template v-else>
  53. <view class="list-details-price">
  54. <view class="list-price">
  55. <text
  56. class="price-larger"
  57. :class="PromotionsFormat(pros.promotions) ? 'none' : ''"
  58. >
  59. ¥{{
  60. (PromotionsFormat(pros.promotions)
  61. ? pros.originalPrice
  62. : pros.price) | NumFormat
  63. }}
  64. </text>
  65. </view>
  66. <view class="add-cart-btn" v-if="!popupShow" @click.stop="showPopup(1, pros)"
  67. >数量</view
  68. >
  69. </view>
  70. <view class="list-details-price none">
  71. <view class="floor-item-act" v-if="pros.actStatus == 1">
  72. <template>
  73. <view class="floor-tags" v-if="PromotionsFormat(pros.promotions)">
  74. {{ pros.promotions.name }}
  75. <text v-if="pros.priceFlag != 1"
  76. >:¥{{ pros.price | NumFormat }}</text
  77. >
  78. </view>
  79. <view class="floor-tags" v-else>{{ pros.promotions.name }}</view>
  80. </template>
  81. </view>
  82. <view class="floor-item-act" v-if="pros.actStatus == 0">
  83. <view
  84. class="floor-tags"
  85. v-if="pros.actStatus == 0 && pros.ladderPriceFlag == 1"
  86. >阶梯价格</view
  87. >
  88. </view>
  89. </view>
  90. </template>
  91. </template>
  92. <template v-else>
  93. <view class="list-details-price" v-if="pros.priceFlag == 1">
  94. <view class="list-none"><view class="price-small">¥未公开价格</view></view>
  95. </view>
  96. <template v-else>
  97. <view class="list-details-price">
  98. <view class="list-price">
  99. <text
  100. class="price-larger"
  101. :class="PromotionsFormat(pros.promotions) ? 'none' : ''"
  102. >
  103. ¥{{
  104. (PromotionsFormat(pros.promotions)
  105. ? pros.originalPrice
  106. : pros.price) | NumFormat
  107. }}
  108. </text>
  109. </view>
  110. <view class="add-cart-btn" v-if="!popupShow" @click.stop="showPopup(1, pros)"
  111. >数量</view
  112. >
  113. </view>
  114. <view class="list-details-price none">
  115. <view class="floor-item-act" v-if="pros.actStatus == 1">
  116. <template>
  117. <view class="floor-tags" v-if="PromotionsFormat(pros.promotions)">
  118. {{ pros.promotions.name }}
  119. <text v-if="pros.priceFlag != 1"
  120. >:¥{{ pros.price | NumFormat }}</text
  121. >
  122. </view>
  123. <view class="floor-tags" v-else>{{ pros.promotions.name }}</view>
  124. </template>
  125. </view>
  126. <view class="floor-item-act" v-if="pros.actStatus == 0">
  127. <view
  128. class="floor-tags"
  129. v-if="pros.actStatus == 0 && pros.ladderPriceFlag == 1"
  130. >阶梯价格</view
  131. >
  132. </view>
  133. </view>
  134. </template>
  135. </template>
  136. </view>
  137. </view>
  138. </view>
  139. </view>
  140. <!--加载loadding-->
  141. <tui-loadmore :visible="loadding" :index="3" type="black"></tui-loadmore>
  142. <tui-nomore :visible="!pullUpOn" :backgroundColor="'#ffffff'" :text="nomoreText"></tui-nomore>
  143. <!--加载loadding-->
  144. </view>
  145. </view>
  146. <!-- 取消收藏操作 -->
  147. <tui-bottom-popup :radius="false" :mask="false" :show="popupShow">
  148. <view class="tui-popup-box clearfix">
  149. <view class="tui-right-flex tui-popup-btn" :style="{ paddingBottom: isIphoneX ? '68rpx' : '0rpx' }">
  150. <view class="tui-flex-1">
  151. <view class="superv-header-checked">
  152. <view class="oltext" @click="isCheckedAll">
  153. <view
  154. class="checkbox iconfont"
  155. :class="[isAllChecked ? 'icon-yixuanze' : 'icon-weixuanze']"
  156. ></view>
  157. <view class="text">全选</view>
  158. </view>
  159. </view>
  160. <view class="tui-button" :class="isProductChecked ? 'active' : ''" @click="handleAllUnder"
  161. >取消收藏</view
  162. >
  163. </view>
  164. </view>
  165. </view>
  166. </tui-bottom-popup>
  167. <!-- 购买弹窗 -->
  168. <tui-bottom-popup :radius="true" :show="popupShow1" @close="hidePopup(1)">
  169. <view class="tui-popup-box clearfix">
  170. <view class="tui-popup-content">
  171. <view class="layer-smimg"> <image :src="handleData.image" mode=""></image> </view>
  172. <view class="layer-nunbox">
  173. <view class="layer-nunbox-t">
  174. <view class="layer-nunbox-text">数量:</view>
  175. <view class="number-box">
  176. <view
  177. class="iconfont icon-jianhao"
  178. :class="[isQuantity == true ? 'disabled' : '']"
  179. @click="changeCountSub()"
  180. ></view>
  181. <input
  182. class="btn-input"
  183. type="number"
  184. v-model="number"
  185. maxlength="4"
  186. @blur="changeNumber($event)"
  187. />
  188. <view
  189. class="iconfont icon-jiahao"
  190. :class="[isStock == true ? 'disabled' : '']"
  191. @click="changeCountAdd()"
  192. ></view>
  193. </view>
  194. </view>
  195. <view class="layer-nunbox-b">
  196. <view class="text"
  197. >单价: <text class="p sm">¥</text>
  198. <text class="p bg">{{ buyRetailPrice.toFixed(2) }}</text>
  199. </view>
  200. </view>
  201. </view>
  202. </view>
  203. <view class="tui-right-flex tui-popup-btn" :style="{ paddingBottom: isIphoneX ? '68rpx' : '0rpx' }">
  204. <view class="tui-flex-btn">
  205. <view class="button add" @click="getAddProductCart">加入购物车</view>
  206. <view class="button buy" @click="toConfirmation">立即购买</view>
  207. </view>
  208. </view>
  209. </view>
  210. </tui-bottom-popup>
  211. <!-- 弹窗提示 -->
  212. <tui-modal
  213. :show="modal"
  214. @click="handleClick"
  215. @cancel="hideMobel"
  216. :content="contentModalText"
  217. :button="modalButton"
  218. color="#333"
  219. :size="32"
  220. shape="circle"
  221. :maskClosable="false"
  222. >
  223. </tui-modal>
  224. <!-- 可拖动悬浮按钮 -->
  225. <cm-drag
  226. :cartNum="cartQuantity"
  227. :isDock="true"
  228. :existTabBar="true"
  229. @btnClick="btnClick"
  230. @btnTouchstart="btnTouchstart"
  231. @btnTouchend="btnTouchend"
  232. >
  233. </cm-drag>
  234. </view>
  235. </template>
  236. <script>
  237. import tuiLoadmore from '@/components/tui-components/loadmore/loadmore'
  238. import tuiNomore from '@/components/tui-components/nomore/nomore'
  239. import cmDrag from '@/components/cm-custom/cm-drag.vue'
  240. import { mapState, mapMutations } from 'vuex'
  241. const defaultListQuery = {
  242. userId: 0,
  243. pageNum: 1,
  244. pageSize: 10
  245. }
  246. export default {
  247. components: {
  248. tuiLoadmore,
  249. tuiNomore,
  250. cmDrag
  251. },
  252. data() {
  253. return {
  254. StaticUrl: this.$Static,
  255. isIphoneX: this.$store.state.isIphoneX,
  256. modalButton: [
  257. {
  258. text: '取消',
  259. type: 'gray',
  260. plain: true //是否空心
  261. },
  262. {
  263. text: '确认',
  264. customStyle: {
  265. color: '#fff',
  266. bgColor: 'linear-gradient(90deg, #F28F31 0%, #E15616 100%)'
  267. },
  268. plain: false
  269. }
  270. ],
  271. totalRecord: 0,
  272. cartQuantity: 0,
  273. popupShow: false,
  274. popupShow1: false,
  275. isProductChecked: false,
  276. listQuery: Object.assign({}, defaultListQuery),
  277. productList: [],
  278. handleData: {},
  279. number: 0,
  280. buyRetailPrice: 0,
  281. buyRetailPriceStep: 1,
  282. isQuantity: false,
  283. scrollTop: 0,
  284. isEmpty: false,
  285. isAllChecked: false,
  286. loadding: false,
  287. pullUpOn: true,
  288. pullFlag: true,
  289. hasNextPage: false,
  290. navbarHeight: '',
  291. nomoreText: '上拉显示更多',
  292. contentModalText: '', //操作文字提示语句
  293. modal: false,
  294. userIdentity:0,
  295. }
  296. },
  297. onLoad() {
  298. this.initGetStotage()
  299. },
  300. filters: {
  301. NumFormat: function(value) {
  302. //处理金额
  303. if (!value) return '0.00'
  304. let number = Number(value).toFixed(2)
  305. return number
  306. }
  307. },
  308. computed: {
  309. ...mapState(['hasLogin', 'userInfo'])
  310. },
  311. methods: {
  312. ...mapMutations(['login', 'logout']),
  313. async initGetStotage() {
  314. const userInfo = await this.$api.getStorage()
  315. this.listQuery.userId = userInfo.userId ? userInfo.userId : 0
  316. this.userIdentity = userInfo.userIdentity ? userInfo.userIdentity : 0
  317. this.GetProductListInfo()
  318. this.shoppingHeaderCartNumber()
  319. },
  320. GetProductListInfo() {
  321. this.productList = []
  322. this.listQuery.pageNum = 1
  323. this.ProductService.getProductUserLikeList(this.listQuery)
  324. .then(response => {
  325. let data = response.data
  326. if (data.results && data.results.length > 0) {
  327. this.isEmpty = false
  328. this.hasNextPage = data.hasNextPage
  329. this.totalRecord = data.totalRecord
  330. this.productList = data.results
  331. this.pullFlag = false
  332. setTimeout(() => {
  333. this.pullFlag = true
  334. }, 500)
  335. if (this.hasNextPage) {
  336. this.pullUpOn = false
  337. this.nomoreText = '上拉显示更多'
  338. } else {
  339. if (this.productList.length < 8) {
  340. this.pullUpOn = true
  341. } else {
  342. this.pullUpOn = false
  343. this.loadding = false
  344. this.nomoreText = '已至底部'
  345. }
  346. }
  347. } else {
  348. this.isEmpty = true
  349. }
  350. this.isRequest = true
  351. })
  352. .catch(error => {
  353. this.$util.msg(error.msg, 2000)
  354. })
  355. },
  356. GetOnReachBottomData(index) {
  357. //上拉加载
  358. this.listQuery.pageNum += 1
  359. this.ProductService.getProductUserLikeList(this.listQuery)
  360. .then(response => {
  361. let data = response.data
  362. if (data.results && data.results.length > 0) {
  363. this.hasNextPage = data.hasNextPage
  364. this.productList = this.productList.concat(data.results)
  365. this.pullFlag = false // 防上拉暴滑
  366. setTimeout(() => {
  367. this.pullFlag = true
  368. }, 500)
  369. if (this.hasNextPage) {
  370. this.pullUpOn = false
  371. this.nomoreText = '上拉显示更多'
  372. } else {
  373. this.pullUpOn = false
  374. this.loadding = false
  375. this.nomoreText = '已至底部'
  376. }
  377. }
  378. })
  379. .catch(error => {
  380. this.$util.msg(error.msg, 2000)
  381. })
  382. },
  383. shoppingHeaderCartNumber() {
  384. // 获取用户购物车储量
  385. this.ProductService.shoppingHeaderCartNumber({
  386. userId: this.listQuery.userId
  387. })
  388. .then(response => {
  389. this.cartQuantity = response.data.length
  390. })
  391. .catch(error => {
  392. console.log('获取购物车数量失败')
  393. })
  394. },
  395. handleAllUnder() {
  396. //批量下架操作
  397. let checkedArray = []
  398. this.productIds = ''
  399. if (this.isProductChecked) {
  400. this.productList.forEach(el => {
  401. if (el.isChecked) {
  402. checkedArray.push(el)
  403. }
  404. })
  405. checkedArray.forEach(el => {
  406. this.productIds += el.productId + ','
  407. })
  408. this.modal = true
  409. this.contentModalText = '确定要取消收藏吗?'
  410. }
  411. },
  412. handleClick(e) {
  413. //取消收藏
  414. if (e.index == 1) {
  415. this.handleDeleteUserLike()
  416. }
  417. this.modal = false
  418. },
  419. handleDeleteUserLike() {
  420. //操作取消收藏
  421. this.ProductService.getDeleteUserLike({
  422. productIds: this.productIds,
  423. userId: this.listQuery.userId
  424. })
  425. .then(response => {
  426. this.$util.msg('取消收藏成功', 2000, true, 'success')
  427. setTimeout(() => {
  428. this.GetProductListInfo()
  429. }, 2000)
  430. })
  431. .catch(error => {
  432. this.$util.msg(error.msg, 2000)
  433. })
  434. },
  435. hideMobel() {
  436. this.modal = false
  437. },
  438. updateCheckAllBtn() {
  439. //勾选单个判断全选
  440. let goodsCheckedLength = 0
  441. this.productList.forEach(item => {
  442. if (item.isChecked) {
  443. goodsCheckedLength++
  444. }
  445. })
  446. this.isAllChecked = goodsCheckedLength === this.productList.length
  447. if (goodsCheckedLength > 0) {
  448. this.isProductChecked = true
  449. } else {
  450. this.isProductChecked = false
  451. }
  452. },
  453. updateBothCheckBtn() {
  454. //全选勾选判断
  455. this.productList.forEach(item => {
  456. item.isChecked = this.isAllChecked
  457. })
  458. },
  459. isCheckedAll() {
  460. //全选
  461. this.isAllChecked = !this.isAllChecked
  462. if (this.isAllChecked) {
  463. this.isProductChecked = true
  464. } else {
  465. this.isProductChecked = false
  466. }
  467. this.updateBothCheckBtn()
  468. },
  469. checkedSoperv(item) {
  470. //选择
  471. item.isChecked = !item.isChecked
  472. console.log(item)
  473. this.updateCheckAllBtn()
  474. },
  475. PromotionsFormat(promo) {
  476. //促销活动类型数据处理
  477. if (promo != null) {
  478. if (promo.type == 1 && promo.mode == 1) {
  479. return true
  480. } else {
  481. return false
  482. }
  483. }
  484. return false
  485. },
  486. changeCountAdd() {
  487. //popup弹窗数量增加按钮
  488. if (this.buyRetailPriceStep == 2) {
  489. this.number += this.minBuyNumber
  490. } else {
  491. this.number++
  492. }
  493. this.calculatPerice()
  494. },
  495. changeCountSub() {
  496. //popup弹窗数量减按钮
  497. if (this.number <= this.minBuyNumber) {
  498. this.number = this.minBuyNumber
  499. this.isQuantity = true
  500. this.$util.msg(`该商品最小起订量为${this.minBuyNumber}`, 2000)
  501. return
  502. } else {
  503. if (this.buyRetailPriceStep == 2) {
  504. this.number -= this.minBuyNumber
  505. } else {
  506. this.number--
  507. }
  508. this.calculatPerice()
  509. this.isQuantity = false
  510. }
  511. },
  512. changeNumber(e) {
  513. let _value = e.detail.value
  514. if (!this.$api.isNumber(_value)) {
  515. this.number = this.minBuyNumber
  516. } else if (_value < this.minBuyNumber) {
  517. this.$util.msg(`该商品最小起订量为${this.minBuyNumber}`, 2000)
  518. this.number = this.minBuyNumber
  519. } else if (_value % this.minBuyNumber != 0) {
  520. this.$util.msg('购买量必须为起订量的整数倍', 2000)
  521. this.number = this.minBuyNumber
  522. } else {
  523. this.number = e.detail.value
  524. this.calculatPerice()
  525. }
  526. },
  527. calculatPerice() {
  528. //判断是否为阶梯价然后做计算价格处理
  529. if (this.handleData.ladderPriceFlag == 1) {
  530. this.handleData.ladderPrices.forEach((item, index) => {
  531. if (this.number >= item.buyNum) {
  532. this.buyRetailPrice = item.buyPrice
  533. }
  534. })
  535. }
  536. },
  537. toConfirmation() {
  538. //跳转确认订单页面
  539. this.popupShow1 = false
  540. let productStp = {
  541. allPrice: this.number * this.buyRetailPrice,
  542. allCount: this.number,
  543. productID: this.handleData.productId,
  544. productCount: this.number
  545. }
  546. this.$api.navigateTo(
  547. `/pages/user/order/create-order?type=prodcut&data=${JSON.stringify({ data: productStp })}`
  548. )
  549. },
  550. getAddProductCart() {
  551. //增加购物车成功和toast弹窗提示成功
  552. this.ProductService.shoppingAddCart({
  553. productID: this.handleData.productId,
  554. userID: this.listQuery.userId,
  555. productCount: this.number
  556. })
  557. .then(response => {
  558. this.popupShow1 = false
  559. this.$util.msg('加入购物车成功', 1500, true, 'success')
  560. this.shoppingHeaderCartNumber()
  561. })
  562. .catch(error => {
  563. this.$util.msg(error.msg, 2000)
  564. })
  565. },
  566. showPopup(index, pros) {
  567. // 弹窗显示
  568. switch (index) {
  569. case 0:
  570. this.popupShow = true
  571. break
  572. case 1:
  573. this.popupShow1 = true
  574. this.handleData = pros
  575. console.log(this.handleData)
  576. this.buyRetailPrice = this.handleData.price
  577. this.buyRetailPriceStep = this.handleData.step
  578. if (this.handleData.ladderPriceFlag == 1) {
  579. this.number = this.handleData.maxBuyNumber ? this.handleData.maxBuyNumber : 1
  580. } else {
  581. this.number = this.handleData.minBuyNumber
  582. }
  583. break
  584. }
  585. },
  586. hidePopup(index) {
  587. // 弹窗隐藏
  588. switch (index) {
  589. case 0:
  590. this.popupShow = false
  591. break
  592. case 1:
  593. this.popupShow1 = false
  594. break
  595. }
  596. },
  597. navToDetailPage(id) {
  598. this.isModallayer = true
  599. this.$api.navigateTo(`/pages/goods/product?id=${id}`)
  600. this.isModallayer = false
  601. },
  602. btnClick() {
  603. this.$api.switchTabTo('/pages/tabBar/cart/index')
  604. },
  605. btnTouchstart() {
  606. // console.log('btnTouchstart');
  607. },
  608. btnTouchend() {
  609. // console.log('btnTouchend');
  610. }
  611. },
  612. onPageScroll(e) {
  613. //实时获取到滚动的值
  614. },
  615. onReachBottom() {
  616. if (this.hasNextPage) {
  617. this.loadding = true
  618. this.pullUpOn = true
  619. this.GetOnReachBottomData()
  620. }
  621. },
  622. onPullDownRefresh() {
  623. setTimeout(() => {
  624. this.listQuery.pageNum = 1
  625. uni.stopPullDownRefresh()
  626. }, 200)
  627. },
  628. onShow() {}
  629. }
  630. </script>
  631. <style lang="scss">
  632. @import '@/uni.scss';
  633. page {
  634. background: #fff;
  635. }
  636. .empty-container {
  637. z-index: 9999;
  638. }
  639. .superv-header {
  640. width: 100%;
  641. height: 80rpx;
  642. background-color: #f7f7f7;
  643. line-height: 80rpx;
  644. position: fixed;
  645. top: 0;
  646. left: 0;
  647. box-sizing: border-box;
  648. padding: 0 24rpx;
  649. z-index: 99;
  650. .superv-header-click {
  651. width: 100%;
  652. height: 80rpx;
  653. font-size: $font-size-30;
  654. .oltext {
  655. float: left;
  656. color: #666666;
  657. .red {
  658. color: $color-system;
  659. }
  660. }
  661. .ortext {
  662. float: right;
  663. color: #333333;
  664. text-align: right;
  665. }
  666. }
  667. }
  668. .tui-header {
  669. width: 100%;
  670. font-size: 16px;
  671. font-weight: 500;
  672. height: 32px;
  673. display: flex;
  674. align-items: center;
  675. justify-content: center;
  676. position: relative;
  677. padding: 0 40rpx;
  678. }
  679. .header-sit {
  680. width: 100%;
  681. box-sizing: border-box;
  682. height: 80rpx;
  683. line-height: 80rpx;
  684. box-sizing: border-box;
  685. padding: 0 40rpx;
  686. text-align: left;
  687. font-size: $font-size-40;
  688. color: #ffffff;
  689. font-weight: 600;
  690. font-family: '正楷';
  691. margin-top: 30rpx;
  692. .iconfont {
  693. font-size: 42rpx;
  694. margin-left: 30rpx;
  695. }
  696. }
  697. .mine {
  698. width: 100%;
  699. height: 100%;
  700. position: relative;
  701. }
  702. .product-content {
  703. width: 100%;
  704. height: auto;
  705. position: relative;
  706. padding: 0;
  707. padding-top: 80rpx;
  708. box-sizing: border-box;
  709. .empty-container-image {
  710. width: 260rpx;
  711. height: 260rpx;
  712. margin-top: -300rpx;
  713. }
  714. }
  715. .tui-goods-item {
  716. padding: 30rpx 20rpx 0 20rpx;
  717. box-sizing: border-box;
  718. position: relative;
  719. .tui-goods-main {
  720. display: flex;
  721. width: 100%;
  722. height: 100%;
  723. border-bottom: 1px solid #ebebeb;
  724. padding-bottom: 24rpx;
  725. }
  726. }
  727. .tui-goods-checkBox {
  728. display: flex;
  729. align-items: center;
  730. margin: 0 15rpx;
  731. .checkbox {
  732. display: flex;
  733. margin: 0;
  734. padding: 0;
  735. display: flex;
  736. flex-direction: column;
  737. align-items: center;
  738. box-sizing: border-box;
  739. text-align: center;
  740. text-decoration: none;
  741. border-radius: 0;
  742. -webkit-tap-highlight-color: transparent;
  743. overflow: hidden;
  744. background-color: #ffffff;
  745. font-size: 36rpx;
  746. color: $color-system;
  747. }
  748. .text {
  749. font-size: $font-size-24;
  750. margin-left: 10rpx;
  751. }
  752. }
  753. .tui-goods-image {
  754. width: 180rpx;
  755. height: 180rpx !important;
  756. border-radius: 12rpx;
  757. .tui-goods-img {
  758. width: 180rpx;
  759. height: 180rpx !important;
  760. border-radius: 12rpx;
  761. flex-shrink: 0;
  762. display: block;
  763. }
  764. }
  765. .tui-goods-info {
  766. padding-left: 20rpx;
  767. box-sizing: border-box;
  768. position: relative;
  769. .list-details-title {
  770. line-height: 38rpx;
  771. text-overflow: ellipsis;
  772. overflow: hidden;
  773. display: -webkit-box;
  774. -webkit-line-clamp: 2;
  775. line-clamp: 2;
  776. -webkit-box-orient: vertical;
  777. font-size: 26rpx;
  778. color: #333333;
  779. }
  780. .list-details-specs {
  781. width: 100%;
  782. display: inline-block;
  783. margin-top: 8rpx;
  784. color: #999999;
  785. font-size: 24rpx;
  786. }
  787. .list-details-price {
  788. width: 100%;
  789. line-height: 54rpx;
  790. float: left;
  791. &.none {
  792. height: 32rpx;
  793. line-height: 32rpx;
  794. }
  795. .floor-item-act {
  796. height: 54rpx;
  797. text-align: center;
  798. box-sizing: border-box;
  799. float: left;
  800. .coupon-tags {
  801. height: 32rpx;
  802. box-sizing: border-box;
  803. border-radius: 8rpx;
  804. background-color: #fff1eb;
  805. line-height: 28rpx;
  806. color: #f94b4b;
  807. text-align: center;
  808. display: inline-block;
  809. padding: 0 10rpx;
  810. font-size: $font-size-20;
  811. border: 1px solid #f94b4b;
  812. float: left;
  813. margin-right: 12rpx;
  814. }
  815. .floor-tags {
  816. height: 32rpx;
  817. box-sizing: border-box;
  818. border-radius: 8rpx;
  819. background-color: #ffffff;
  820. line-height: 28rpx;
  821. color: $color-system;
  822. text-align: center;
  823. display: inline-block;
  824. padding: 0 16rpx;
  825. font-size: $font-size-20;
  826. border: 1px solid #e15616;
  827. float: left;
  828. }
  829. }
  830. .price-icon {
  831. width: 22rpx;
  832. height: 28rpx;
  833. vertical-align: middle;
  834. margin-right: 10rpx;
  835. }
  836. .price-icon + text {
  837. font-size: 25rpx;
  838. vertical-align: middle;
  839. }
  840. .list-login-now {
  841. width: 375rpx;
  842. color: #f8c499;
  843. position: absolute;
  844. bottom: 0;
  845. .p-no {
  846. float: left;
  847. font-size: $font-size-24;
  848. color: $color-system;
  849. margin-right: 10rpx;
  850. }
  851. }
  852. .login-now {
  853. padding: 10rpx 10rpx 10rpx 0;
  854. }
  855. .list-none {
  856. margin-top: 20rpx;
  857. .price-small {
  858. font-size: $font-size-26;
  859. line-height: 40rpx;
  860. color: #ff2a2a;
  861. }
  862. }
  863. .list-price {
  864. color: #ff2a2a;
  865. float: left;
  866. line-height: 54rpx;
  867. align-items: center;
  868. justify-content: center;
  869. .price-larger {
  870. font-size: $font-size-30;
  871. display: inline-block;
  872. &.none {
  873. text-decoration: line-through;
  874. color: #999999;
  875. }
  876. }
  877. }
  878. .add-cart-btn {
  879. float: right;
  880. width: 140rpx;
  881. height: 54rpx;
  882. line-height: 54rpx;
  883. border-radius: 30rpx;
  884. color: #fff;
  885. font-size: 24rpx;
  886. margin-right: 0;
  887. background: #ffffff;
  888. border: 1px solid #c9c9c9;
  889. color: $text-color;
  890. text-align: center;
  891. }
  892. }
  893. }
  894. .tui-popup-box {
  895. position: relative;
  896. box-sizing: border-box;
  897. min-height: 168rpx;
  898. padding: 6rpx 24rpx;
  899. .tui-popup-content {
  900. padding-top: 30rpx;
  901. }
  902. }
  903. .layer-smimg {
  904. width: 114rpx;
  905. height: 114rpx;
  906. float: left;
  907. border-radius: 10rpx;
  908. margin-right: 24rpx;
  909. image {
  910. width: 114rpx;
  911. height: 114rpx;
  912. border-radius: 10rpx;
  913. }
  914. }
  915. .layer-nunbox {
  916. justify-content: space-between;
  917. align-items: center;
  918. width: 536rpx;
  919. height: 88rpx;
  920. padding: 13rpx 0 0 0;
  921. float: left;
  922. .layer-nunbox-t {
  923. width: 100%;
  924. height: 44rpx;
  925. position: relative;
  926. display: flex;
  927. .layer-nunbox-text {
  928. line-height: 44rpx;
  929. font-size: $font-size-28;
  930. }
  931. .number-box {
  932. display: flex;
  933. justify-content: center;
  934. align-items: center;
  935. border: 2rpx solid #ffe6dc;
  936. border-radius: 30rpx;
  937. height: 48rpx;
  938. margin-left: 20rpx;
  939. .iconfont {
  940. font-size: $font-size-24;
  941. padding: 0 18rpx;
  942. color: #999999;
  943. text-align: center;
  944. line-height: 48rpx;
  945. font-weight: bold;
  946. background: #fef6f3;
  947. &.icon-jianhao {
  948. border-radius: 30rpx 0 0 30rpx;
  949. }
  950. &.icon-jiahao {
  951. border-radius: 0 30rpx 30rpx 0;
  952. }
  953. }
  954. .btn-input {
  955. width: 62rpx;
  956. height: 48rpx;
  957. line-height: 48rpx;
  958. background: #ffffff;
  959. border-radius: 4rpx;
  960. text-align: center;
  961. font-size: $font-size-28;
  962. }
  963. }
  964. .product-step {
  965. position: absolute;
  966. left: 45rpx;
  967. bottom: 0;
  968. height: 44rpx;
  969. background: #ffffff;
  970. }
  971. }
  972. .layer-nunbox-b {
  973. width: 100%;
  974. height: 44rpx;
  975. margin-top: 13rpx;
  976. }
  977. .text {
  978. line-height: 44rpx;
  979. font-size: $font-size-28;
  980. .p {
  981. color: #ff2a2a;
  982. }
  983. .p:first-child {
  984. margin-left: 30rpx;
  985. }
  986. .p.sm {
  987. font-size: $font-size-24;
  988. }
  989. }
  990. }
  991. .tui-popup-btn {
  992. width: 100%;
  993. height: auto;
  994. float: left;
  995. box-sizing: border-box;
  996. margin-top: 30rpx;
  997. .superv-header-checked {
  998. float: left;
  999. font-size: $font-size-30;
  1000. .oltext {
  1001. width: 120rpx;
  1002. float: left;
  1003. color: #666666;
  1004. display: flex;
  1005. margin-left: 10rpx;
  1006. .checkbox {
  1007. display: flex;
  1008. margin: 0;
  1009. padding: 0;
  1010. display: flex;
  1011. flex-direction: column;
  1012. align-items: center;
  1013. box-sizing: border-box;
  1014. text-align: center;
  1015. text-decoration: none;
  1016. border-radius: 0;
  1017. -webkit-tap-highlight-color: transparent;
  1018. overflow: hidden;
  1019. font-size: 34rpx;
  1020. color: $color-system;
  1021. line-height: 80rpx;
  1022. }
  1023. .text {
  1024. float: left;
  1025. line-height: 80rpx;
  1026. margin-left: 15rpx;
  1027. }
  1028. }
  1029. .ortext {
  1030. width: 120rpx;
  1031. float: right;
  1032. color: $color-system;
  1033. text-align: right;
  1034. }
  1035. }
  1036. .tui-button {
  1037. width: 210rpx;
  1038. height: 88rpx;
  1039. float: right;
  1040. background: #e1e1e1;
  1041. line-height: 88rpx;
  1042. text-align: center;
  1043. color: #ffffff;
  1044. font-size: $font-size-28;
  1045. border-radius: 44rpx;
  1046. &.active {
  1047. background: $btn-confirm;
  1048. }
  1049. }
  1050. .tui-flex-btn {
  1051. width: 100%;
  1052. height: 88rpx;
  1053. display: flex;
  1054. box-sizing: border-box;
  1055. padding: 0 34rpx;
  1056. .button {
  1057. width: 280rpx;
  1058. height: 88rpx;
  1059. color: #fff;
  1060. display: flex;
  1061. align-items: center;
  1062. justify-content: center;
  1063. font-size: $font-size-28;
  1064. border-radius: 44rpx;
  1065. &.buy {
  1066. background: $btn-confirm;
  1067. margin-left: 78rpx;
  1068. }
  1069. &.add {
  1070. background: #ffe6dc;
  1071. color: #e15616;
  1072. }
  1073. }
  1074. }
  1075. }
  1076. </style>