Authored by zhangwenxue

商品详情: 修改变现的功能依赖求购的启用

... ... @@ -29,7 +29,7 @@
<transition name="slide-up">
<div class="footer" v-if="isAvailable">
<cube-button v-if="isMarketable" @click="convertToCash" :class="{active: isMarketable}">变现<span> <i>¥</i>{{cashPrice}}</span></cube-button>
<cube-button v-if="isQiugouEnabled && isMarketable" @click="convertToCash" :class="{active: isMarketable}">变现<span> <i>¥</i>{{cashPrice}}</span></cube-button>
<cube-button @click="select" :class="{active: isTradable}">{{config.title}}</cube-button>
</div>
</transition>
... ... @@ -41,7 +41,7 @@
<script>
import { Scroll, Button } from 'cube-ui';
import { get } from 'lodash';
import { createNamespacedHelpers, mapActions } from 'vuex';
import { createNamespacedHelpers, mapActions, mapGetters } from 'vuex';
import ActionSheet from './action-sheet';
import SizeList from './size-list';
... ... @@ -83,6 +83,7 @@ export default {
},
computed: {
...mapState(['selectedProductInfo']),
...mapGetters(['isQiugouEnabled']),
selectedSize() {
if (this.selectedProductInfo.productId === this.product.product_id) {
return this.selectedProductInfo.size;
... ...