Shopping.vue 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672
  1. <!-- Shopping.vue -->
  2. <template>
  3. <view class="div container">
  4. <uni-popup
  5. background-color="#fff"
  6. ref="isShowcartInfo"
  7. type="bottom"
  8. v-if="detailInfo"
  9. >
  10. <view class="div ui-add-shopping" :style="'height:'+(screenHeight*.7)+'px'" v-if="detailInfo">
  11. <view class="div shopping-info">
  12. <view class="div info-header">
  13. <image mode="aspectFit"
  14. v-bind:src="detailInfo.photos[0]"
  15. class="img info-image"
  16. v-if="detailInfo.photos && detailInfo.photos.length > 0"
  17. />
  18. <view class="div">
  19. <text class="span header-price" >¥{{ propertiPrice }}</text>
  20. <text class="span">
  21. <text class="span iconfont" v-if="detailInfo.activity">&#xe631;</text>
  22. <text class="span" v-if="detailInfo.activity">{{
  23. detailInfo.activity.name
  24. }}</text>
  25. </text>
  26. <!-- {{ chooseinfo}} -->
  27. <text class="span">库存{{ currentStock }}件</text>
  28. <text class="span">数量:{{ numbers }}</text>
  29. </view>
  30. <text class="span iconfont close" v-on:click="closeCartInfo(false)">&#xe65a;</text>
  31. </view>
  32. <view class="div goods-detail-properties">
  33. <view class="div"
  34. v-if="
  35. detailInfo &&
  36. detailInfo.goods_spec
  37. "
  38. v-for="(item, index) in detailInfo.spec_name"
  39. :key="index"
  40. >
  41. <view
  42. class="div goods-properties"
  43. v-if="detailInfo.spec_value && detailInfo.spec_value[index] && Object.keys(detailInfo.spec_value[index]).length"
  44. >
  45. <view class="p">{{ item }}</view>
  46. <view class="div properties-list">
  47. <view class="div" v-for="(key, keyindex) in detailInfo.spec_value[index]" :key="keyindex">
  48. <text class="span"
  49. @click="setCurrentIndex(keyindex,detailInfo.spec_value[index])"
  50. v-bind:class="{
  51. 'active-properties': detailInfo.goods_spec[keyindex],
  52. 'disabled-properties':(detailInfo.spec_disable.indexOf(keyindex)>-1)
  53. }"
  54. >{{ key }}</text
  55. >
  56. </view>
  57. </view>
  58. </view>
  59. </view>
  60. <view class="div info-body">
  61. <view class="p">数量</view>
  62. <view class="div ui-number">
  63. <view
  64. class="div reduce ui-common"
  65. @click.stop="reduceNumber()"
  66. v-bind:class="{ 'reduce-opacity': numbers <= 1 }"
  67. >
  68. -
  69. </view>
  70. <input
  71. type="number"
  72. min="1"
  73. class="number"
  74. value="1"
  75. v-model="numbers"
  76. />
  77. <view class="div add ui-common" @click.stop="addNumber()">+</view>
  78. </view>
  79. </view>
  80. </view>
  81. <view class="div info-footer">
  82. <view
  83. class="div footer-button"
  84. :class="canBuy?'active-cart':'disabled-cart'"
  85. v-on:click="checkProduct(false)"
  86. v-if="!detailInfo.bargain_info && ((!detailInfo.pintuan_type && detailInfo.cart) || (detailInfo.pintuan_type && (detailInfo.pintuangroup_list.length || detailInfo.pintuanorder_state)))"
  87. >
  88. {{addCartText}}
  89. </view>
  90. <view
  91. class="div footer-button"
  92. :class="canBuy?'active-buy':'disabled-buy'"
  93. v-on:click="checkProduct(true)"
  94. >
  95. {{buyNowText}}
  96. </view>
  97. </view>
  98. </view>
  99. </view>
  100. </uni-popup>
  101. <uni-popup background-color="#fff" v-if="detailInfo.pintuan_type && detailInfo.pintuangroup_list.length" ref="subjectVisible" type="right" >
  102. <view :style="'width:'+screenWidth+'px'" class="common-popup-wrapper">
  103. <view class="div common-header-wrap">
  104. <view :style="'height:'+navHeight+'px'"></view>
  105. <view class="common-header-holder"></view>
  106. <view class="common-header-fixed">
  107. <title-header />
  108. <uni-nav-bar title="拼团列表" class="common-header" left-icon="back" @clickLeft="hidePopup('subjectVisible')">
  109. </uni-nav-bar>
  110. </view>
  111. </view>
  112. <view class="div common-popup-content">
  113. <scroll-view style="position: absolute;top:0;right:0;left:0;bottom:0" scroll-y="true">
  114. <view class="div" v-for="(item, index) in detailInfo.pintuangroup_list" :key="index" @click="goPintuan(item)">
  115. <flex-line :is-link="true" :show-border="true" v-if="!(detailInfo.pintuangroup_share_id>0 && item.pintuangroup_headid != detailInfo.pintuangroup_share_id)"><!--通过拼团分享会员ID判断其他组团是否显示-->
  116. <view class="div">
  117. <image mode="aspectFit" class="img" :src="item.pintuangroup_avatar" width="24" height="24">
  118. <text class="span">{{item.member_name}}</text>
  119. </view>
  120. <view class="div" slot="right">
  121. <text class="span">{{item.pintuangroup_surplus>0?('还差'+item.pintuangroup_surplus+'人'):'已满员'}}&nbsp;</text>
  122. <count-down :timetype="2" :timesurplus="item.pintuangroup_starttime" :timelimithour="item.pintuangroup_limit_hour"></count-down>
  123. </view>
  124. </flex-line>
  125. </view>
  126. </scroll-view>
  127. </view>
  128. </view>
  129. </uni-popup>
  130. </view>
  131. </template>
  132. <script>
  133. import TitleHeader from '../../../TitleHeader'
  134. import { urlencode } from '@/util/common'
  135. import CountDown from '../../../CountDown'
  136. import { mapState, mapMutations, mapActions } from 'vuex'
  137. import { cartAdd } from '../../../../api/homecart'
  138. import { addBargain } from '../../../../api/memberBargain'
  139. import flexLine from '../../../flexLine'
  140. export default {
  141. components:{
  142. TitleHeader,
  143. flexLine,
  144. CountDown
  145. },
  146. data(){
  147. return {
  148. navHeight: 0,
  149. screenWidth:0,
  150. screenHeight:0,
  151. pintuangroup_id: 0,
  152. addCartText: '加入购物车',
  153. buyNowText: '立即购买',
  154. numbers: this.$store.state.goodsdetail.number > 0 ? this.$store.state.goodsdetail.number : 1, // todo 临时解决
  155. currentStock: this.$store.state.goodsdetail.detailInfo.goods_storage,
  156. productId: this.$store.state.goodsdetail.currentProductId,
  157. toastConfig: {
  158. message: '商品达到每单限购数量',
  159. position: 'middle'
  160. },
  161. ids: [],
  162. info: [],
  163. propertiPrice: 0,
  164. earlier: {}
  165. }
  166. },
  167. created () {
  168. if (this.detailInfo.promotion_type) {
  169. this.propertiPrice = this.detailInfo.promotion_price
  170. } else {
  171. this.propertiPrice = this.detailInfo.goods_price
  172. }
  173. if (this.detailInfo.bargain_info) {
  174. if (this.detailInfo.bargainorder_info) {
  175. if (this.detailInfo.bargainorder_info.bargainorder_state == 2) {
  176. this.buyNowText = '砍价成功去下单'
  177. } else {
  178. this.buyNowText = '正在砍价'
  179. }
  180. } else {
  181. this.buyNowText = '发起砍价'
  182. }
  183. this.propertiPrice = this.detailInfo.bargain_info.bargain_floorprice
  184. } else if (this.detailInfo.pintuan_type) {
  185. if (this.detailInfo.pintuanorder_state) {
  186. if (this.detailInfo.pintuanorder_state == 1) {
  187. this.addCartText = '参团中'
  188. } else {
  189. this.addCartText = '已成团'
  190. }
  191. this.buyNowText = '原价购买'
  192. } else {
  193. this.addCartText = '参加拼团'
  194. this.buyNowText = '立刻开团'
  195. }
  196. this.propertiPrice = this.detailInfo.pintuan_price
  197. } else if (this.detailInfo.is_goodsfcode == 1) {
  198. this.buyNowText = 'F码购买'
  199. } else if (this.detailInfo.presell_type) {
  200. this.buyNowText = '预售购买'
  201. }
  202. this.info = this.chooseinfo.specification
  203. this.ids = Object.assign([], this.chooseinfo.ids)
  204. },
  205. computed: {
  206. ...mapState({
  207. // 是否显示购物车浮层
  208. isShowcartInfo: state => state.goodsdetail.isShowcartInfo,
  209. isOnline: state => state.member.isOnline,
  210. token: state => state.member.token,
  211. user: state => state.member.info,
  212. detailInfo: state => state.goodsdetail.detailInfo,
  213. storeInfo: state => state.goodsdetail.storeInfo,
  214. specList: state => state.goodsdetail.specList,
  215. number: state => state.goodsdetail.number,
  216. chooseinfo: state => state.goodsdetail.chooseinfo
  217. }),
  218. canBuy () {
  219. if (this.detailInfo.goods_storage > 0 && this.detailInfo.goods_state == 1 && this.detailInfo.goods_verify == 1) {
  220. return true
  221. } else {
  222. return false
  223. }
  224. }
  225. },
  226. watch: {
  227. isShowcartInfo: function (value) {
  228. if(value){
  229. this.showPopup('isShowcartInfo')
  230. }else{
  231. this.hidePopup('isShowcartInfo')
  232. }
  233. },
  234. numbers: function (value) {
  235. if (value) {
  236. let goodStorage = this.detailInfo.goods_storage
  237. if (value <= 0) {
  238. this.numbers = 1
  239. this.toastConfig.message = '受不了了,宝贝不能再少了'
  240. uni.showToast({icon:'none',title: this.toastConfig})
  241. } else if (value > goodStorage) {
  242. this.toastConfig.message = '商品库存不足'
  243. uni.showToast({icon:'none',title: this.toastConfig})
  244. this.numbers = goodStorage
  245. }
  246. // 批发
  247. if (this.detailInfo.wholesale_info) {
  248. this.propertiPrice = this.detailInfo.goods_price
  249. for (var i in this.detailInfo.wholesale_info.wholesalegoods_price) {
  250. if (this.detailInfo.wholesale_info.wholesalegoods_price[i].num <= this.numbers) {
  251. this.propertiPrice = this.detailInfo.wholesale_info.wholesalegoods_price[i].price
  252. }
  253. }
  254. }
  255. this.saveNumber(this.numbers)
  256. }
  257. }
  258. },
  259. mounted(){
  260. // #ifdef MP-WEIXIN
  261. this.navHeight = uni.getMenuButtonBoundingClientRect().top
  262. // #endif
  263. const res = uni.getSystemInfoSync()
  264. this.screenWidth = res.windowWidth
  265. this.screenHeight = res.windowHeight
  266. },
  267. methods:{
  268. showPopup(id){
  269. this.$refs[id].open()
  270. },
  271. hidePopup(id){
  272. this.$refs[id].close()
  273. },
  274. ...mapActions({
  275. getGoodsDetail: 'getGoodsDetail'
  276. }),
  277. ...mapMutations({
  278. saveCartState: 'saveCartState',
  279. saveNumber: 'saveNumber',
  280. saveChooseInfo: 'saveChooseInfo',
  281. saveProperties: 'saveProperties',
  282. setCartNumber: 'setCartNumber',
  283. saveSelectedCartGoods: 'saveSelectedCartGoods'
  284. }),
  285. goPintuan (item) {
  286. if (this.detailInfo.pintuanorder_state) {
  287. if (this.detailInfo.pintuanorder_state == 1) {
  288. uni.showToast({icon:'none',title: '您正在参团中'})
  289. } else {
  290. uni.showToast({icon:'none',title: '您已拼团成功'})
  291. }
  292. return
  293. }
  294. if (item.pintuangroup_surplus > 0) {
  295. this.pintuangroup_id = item.pintuangroup_id
  296. this.checkProduct(true)
  297. } else {
  298. uni.showToast({icon:'none',title: '该团已满员'})
  299. }
  300. },
  301. // 关闭购物车浮层
  302. closeCartInfo (value) {
  303. this.saveCartState(value)
  304. },
  305. // 数量加
  306. addNumber () {
  307. if (this.detailInfo.goods_storage && this.numbers > this.detailInfo.goods_storage) {
  308. this.toastConfig.message = '商品库存不足'
  309. uni.showToast({icon:'none',title: this.toastConfig})
  310. this.numbers = this.detailInfo.goods_storage
  311. } else {
  312. this.numbers++
  313. }
  314. },
  315. // 数量减
  316. reduceNumber () {
  317. if (this.numbers > 1) {
  318. this.numbers--
  319. } else {
  320. this.numbers = 1
  321. this.toastConfig.message = '受不了了,宝贝不能再少了'
  322. uni.showToast({icon:'none',title: this.toastConfig})
  323. }
  324. },
  325. // 加入购物车
  326. checkProduct (checkout) {
  327. if (!this.canBuy) {
  328. return
  329. }
  330. if (!this.isOnline) {
  331. uni.navigateTo({ url: '/pages/home/memberlogin/Login' })
  332. } else {
  333. if (checkout) { // 立即购买
  334. if (this.user.store_id == this.storeInfo.store_id) {
  335. uni.showToast({icon:'none',title: '不能购买自己的商品'})
  336. return
  337. }
  338. if (this.detailInfo.is_virtual == '1') {
  339. let params = { goods_id: this.detailInfo.goods_id, quantity: this.numbers }
  340. if (this.detailInfo.pintuan_type && !this.detailInfo.pintuanorder_state) {
  341. params['pintuan_id'] = this.detailInfo.pintuan_id
  342. params['pintuangroup_id'] = this.pintuangroup_id
  343. }
  344. uni.navigateTo({ url: '/pages/member/vrbuy/step1'+'?'+urlencode( params )})
  345. } else {
  346. let params = { buy_now: 1, cart_id: this.detailInfo.goods_id + '|' + this.numbers }
  347. if (this.detailInfo.bargain_info) {
  348. if (this.detailInfo.bargainorder_info) {
  349. if (this.detailInfo.bargainorder_info.bargainorder_state == 2) {
  350. params['bargainorder_id'] = this.detailInfo.bargainorder_info.bargainorder_id
  351. } else {
  352. uni.navigateTo({ url: '/pages/home/bargain/Bargainshare'+'?'+urlencode( { bargainorder_id: this.detailInfo.bargainorder_info.bargainorder_id } )})
  353. return
  354. }
  355. } else {
  356. // 新增砍价
  357. addBargain(this.detailInfo.bargain_info.bargain_id).then(res => {
  358. uni.navigateTo({ url: '/pages/home/bargain/Bargainshare'+'?'+urlencode( { bargainorder_id: res.result.bargainorder_id })})
  359. }).catch(function (error) {
  360. uni.showToast({icon:'none',title: error.message})
  361. })
  362. return
  363. }
  364. } else if (this.detailInfo.pintuan_type && !this.detailInfo.pintuanorder_state) {
  365. params['pintuan_id'] = this.detailInfo.pintuan_id
  366. params['pintuangroup_id'] = this.pintuangroup_id
  367. }
  368. uni.navigateTo({ url: '/pages/member/buy/step1'+'?'+urlencode( params )})
  369. }
  370. } else {
  371. if (this.detailInfo.pintuan_type) {
  372. this.showPopup('subjectVisible')
  373. } else {
  374. cartAdd(this.detailInfo.goods_id, this.numbers).then(
  375. res => {
  376. uni.$emit('update-cart-num')
  377. uni.$emit('end-addcart-animation')
  378. uni.showToast({icon:'none',title: res.message})
  379. },
  380. error => {
  381. uni.showToast({icon:'none',title: error.message})
  382. }
  383. )
  384. }
  385. }
  386. }
  387. },
  388. keyDown (event) {},
  389. /*
  390. * setCurrentIndex: 设置当前选中的规格的id,
  391. * @parmas: index 当前规格的index
  392. * @parmas: specList 同类规格的列表
  393. */
  394. setCurrentIndex (index, specList) {
  395. if(this.detailInfo.spec_disable.indexOf(index)>-1){
  396. return
  397. }
  398. let specIndex = []
  399. for (var k in specList) {
  400. if (typeof (this.detailInfo.goods_spec[k]) !== 'undefined') {
  401. delete this.detailInfo.goods_spec[k]
  402. this.detailInfo.goods_spec[index] = specList[index]
  403. break
  404. }
  405. }
  406. for (var k in this.detailInfo.goods_spec) {
  407. specIndex.push(k)
  408. }
  409. specIndex = specIndex.sort(this.sortNumber).join('|')
  410. this.getGoodsDetail({ goods_id: this.specList[specIndex], token: this.token, extra: {} }).then(res => {
  411. if (res.result.goods_info.promotion_type) {
  412. this.propertiPrice = res.result.goods_info.promotion_price
  413. } else {
  414. this.propertiPrice = res.result.goods_info.goods_price
  415. }
  416. this.currentStock = res.result.goods_info.goods_storage
  417. }).catch(error => {
  418. uni.showToast({icon:'none',title: error.message})
  419. })
  420. },
  421. sortNumber (a, b) {
  422. return a - b
  423. }
  424. }
  425. }
  426. </script>
  427. <style lang="scss" scoped>
  428. .mint-popup-bottom {
  429. overflow: initial;
  430. height: 70%;
  431. }
  432. .ui-add-shopping {
  433. /* position: fixed;
  434. top: 0;
  435. bottom: 0;
  436. left: 0;
  437. right: 0;
  438. width: 100%;
  439. height: 100%; */
  440. /* z-index: 200; */
  441. /* background:rgba(0,0,0, 0.4); */
  442. .shopping-info {
  443. background: rgba(255, 255, 255, 1);
  444. height: 100%;
  445. position: relative;
  446. width: -webkit-fill-available;
  447. /* bottom: 0; */
  448. z-index: 10;
  449. width: 100%;
  450. .info-header {
  451. padding:0.75rem;
  452. display: flex;
  453. justify-content: flex-start;
  454. padding-bottom:1.25rem;
  455. border-bottom: 0.5px solid rgba(232, 234, 237, 1);
  456. .img.info-image {
  457. width:6rem;
  458. height:6rem;
  459. border-radius: 1px;
  460. margin-top: -0.75rem;
  461. position: absolute;
  462. top: -0.65rem;
  463. }
  464. .div {
  465. padding-left:6.5rem;
  466. width: 100%;
  467. .span {
  468. display: block;
  469. color: #999999;
  470. &.header-price {
  471. font-size:$h1;
  472. line-height:1rem;
  473. padding-bottom:0.6rem;
  474. color: $primaryColor;
  475. }
  476. &:nth-child(2) {
  477. .img {
  478. vertical-align: middle;
  479. padding-right:0.5rem;
  480. width:2.5rem;
  481. height:1rem;
  482. }
  483. .span {
  484. display: inline;
  485. font-size:$subFontSize;
  486. line-height:0.7rem;
  487. padding-bottom:0.45rem;
  488. padding-top:0.6rem;
  489. }
  490. }
  491. &:nth-child(3) {
  492. line-height:1rem;
  493. font-size:$subFontSize;
  494. width: 100%;
  495. overflow: hidden;
  496. text-overflow: ellipsis;
  497. white-space: nowrap;
  498. padding-right:0.75rem;
  499. }
  500. &:last-child {
  501. line-height:1rem;
  502. font-size:$subFontSize;
  503. padding-top:0.6rem;
  504. width: 100%;
  505. overflow: hidden;
  506. text-overflow: ellipsis;
  507. white-space: nowrap;
  508. padding-right:0.75rem;
  509. }
  510. }
  511. }
  512. .close {
  513. position: absolute;
  514. top:0.75rem;
  515. right:0.75rem;
  516. width:0.65rem;
  517. height:0.65rem;
  518. cursor: pointer;
  519. opacity: 1;
  520. }
  521. }
  522. .div.goods-detail-properties {
  523. width: 100%;
  524. overflow: auto;
  525. height: auto;
  526. position: absolute;
  527. top:6.2rem;
  528. bottom:2.2rem;
  529. /* height: 100%; */
  530. }
  531. .div.goods-properties {
  532. padding: 0.75rem 0;
  533. .p {
  534. font-size:$subFontSize;
  535. color: rgba(41, 43, 45, 1);
  536. line-height:0.8rem;
  537. margin: 0;
  538. padding: 0 0.75rem;
  539. }
  540. .div.properties-list {
  541. .div {
  542. display: inline-block;
  543. margin-left: 0.75rem;
  544. .span {
  545. font-size:$subFontSize;
  546. color: rgba(78, 84, 93, 1);
  547. line-height: 0.7rem;
  548. display: inline-block;
  549. padding: 0.35rem 0.7rem;
  550. border: 1px solid #404245;
  551. border-radius:0.1rem;
  552. cursor: pointer;
  553. margin-top:0.75rem;
  554. &.active-properties {
  555. background: $primaryColor;
  556. color: rgba(255, 255, 255, 1);
  557. border: 1px solid $primaryColor;
  558. }
  559. &.disabled-properties {
  560. color: #b1b5bb;
  561. cursor: none;
  562. border: 1px solid #a2a6ad;
  563. }
  564. }
  565. /* &:nth-child(even) {
  566. margin-left: 0.75rem;
  567. } */
  568. }
  569. }
  570. }
  571. .info-body {
  572. padding:0.75rem 0.75rem 1rem 0.75rem;
  573. .p {
  574. font-size:$subFontSize;
  575. color: rgba(41, 43, 45, 1);
  576. line-height:0.8rem;
  577. padding: 0;
  578. margin: 0;
  579. padding-bottom:0.8rem;
  580. }
  581. .div.ui-number {
  582. height: 1.5rem;
  583. display: flex;
  584. border-radius: 0.15rem 0 0 0.15rem;
  585. input,
  586. .div {
  587. height:1.4rem;
  588. line-height:1.4rem;
  589. text-align: center;
  590. color: #404245;
  591. display: inline-block;
  592. padding: 0;
  593. margin: 0;
  594. border: 0;
  595. outline-offset: 0;
  596. }
  597. .ui-common {
  598. line-height:1.4rem;
  599. width:1.4rem ;
  600. height:1.4rem;
  601. border: 1px solid #c7c7cd;
  602. cursor: pointer;
  603. }
  604. .reduce {
  605. border-right: 0;
  606. }
  607. .reduce-opacity {
  608. opacity: 0.4;
  609. }
  610. .add {
  611. border-left: 0;
  612. }
  613. .number {
  614. width:2rem;
  615. border: 1px solid #c7c7cd;
  616. border-radius: 0;
  617. border-image-width: 0;
  618. box-shadow: 0;
  619. vertical-align: bottom;
  620. &:focus {
  621. outline: none;
  622. }
  623. }
  624. }
  625. }
  626. .info-footer {
  627. width: 100%;
  628. position: fixed;
  629. bottom: 0;
  630. display: flex;
  631. .footer-button {
  632. flex: 1;
  633. color: #ffffff;
  634. line-height:2.2rem;
  635. text-align: center;
  636. font-size:$subFontSize;
  637. height:2.2rem;
  638. }
  639. .active-cart {
  640. background: $primaryColor;
  641. }
  642. .active-buy {
  643. background: #000;
  644. }
  645. .disabled-buy {
  646. background: #999999;
  647. }
  648. .disabled-cart {
  649. background: #c3c3c3;
  650. }
  651. }
  652. }
  653. }
  654. </style>