| | |
| | | </view> |
| | | <view class=""> |
| | | <no-data v-if="!list||list.length===0" style="width: 100%;"></no-data> |
| | | |
| | | <view class="shopping-item m-t-20" v-for="(item,index) of list" :key="index"> |
| | | |
| | | |
| | | <view class="sup-title"> |
| | | <radio :checked="ids.indexOf('supplier@'+item.supplierId)>=0" @click="changeItem(item,'supplier')"> |
| | | </radio> |
| | |
| | | <u-swipe-action-item :options="options1" @click="(e)=>{clickSwipeButton(dto,true)}"> |
| | | <view class="item-each flex"> |
| | | <radio :checked="ids.indexOf(dto.id)>=0" @click="changeItem(dto,'flower')"></radio> |
| | | <image class="img img100 m-r-6 br-4" :class="[!dto.stock?'component-stock-zero':'']" |
| | | :src="dto.url||dto.cover"></image> |
| | | <image class="img img100 m-r-6 br-4" :lazy-load="true" |
| | | :class="[!dto.stock?'component-stock-zero':'']" :src="dto.url||dto.cover"></image> |
| | | <view class="flex1"> |
| | | <view class="title" @click.stop="toDetail(dto)"><span class="m-r-5" |
| | | style="display: inline-block;">{{dto.categoryStr||''}}</span><span |
| | |
| | | totalprice() { |
| | | |
| | | let totalprice = 0 |
| | | this.list && this.list.forEach(dto => { |
| | | dto.flowerList && dto.flowerList.forEach(item => { |
| | | if (this.ids.indexOf(item.id) >= 0) { |
| | | totalprice += item.price * item.num |
| | | } |
| | | if (this.ids.length > 0) { |
| | | this.list && this.list.forEach(dto => { |
| | | dto.flowerList && dto.flowerList.forEach(item => { |
| | | if (this.ids.indexOf(item.id) >= 0) { |
| | | totalprice += item.price * item.num |
| | | } |
| | | }) |
| | | }) |
| | | }) |
| | | } |
| | | |
| | | return totalprice.toFixed(2) |
| | | }, |
| | | }, |
| | |
| | | this.$message.showToast('请先前往个人中心补充个人信息') |
| | | return |
| | | } |
| | | this.$store.dispatch('sign_clear', 'shopping'); |
| | | |
| | | this.$message.showLoading() |
| | | await this.$store.dispatch('sign_clear', 'shopping'); |
| | | const { |
| | | code, |
| | | data |
| | |
| | | this.list = [] |
| | | if (code === 0) { |
| | | this.list = data || [] |
| | | |
| | | this.$forceUpdate() |
| | | } |
| | | }, |
| | | toDetail(dto) { |