|
@@ -15,33 +15,25 @@
|
|
|
<view class="commodity-view">
|
|
<view class="commodity-view">
|
|
|
<view class="commodity-list">
|
|
<view class="commodity-list">
|
|
|
<view class="commodity-item" :class="{'limit-exceed-item': isLimitExceededItem(item)}" v-for="(item, index) in selectList" :key="index">
|
|
<view class="commodity-item" :class="{'limit-exceed-item': isLimitExceededItem(item)}" v-for="(item, index) in selectList" :key="index">
|
|
|
- <image class="item-icon" :src="item.cover" alt="" />
|
|
|
|
|
|
|
+ <image class="item-icon" :src="item.cover" mode="aspectFill" />
|
|
|
<view class="item-info">
|
|
<view class="item-info">
|
|
|
-
|
|
|
|
|
- <view class="info-line">
|
|
|
|
|
|
|
+ <view class="item-row-top">
|
|
|
<text class="item-name">{{ item.itemName }}</text>
|
|
<text class="item-name">{{ item.itemName }}</text>
|
|
|
- <text class="item-price">
|
|
|
|
|
- <text class="unit"></text>
|
|
|
|
|
- <text class="price">
|
|
|
|
|
- ¥{{ Number(item.bigCount)>0 ? parseFloat(item.bigPrice) : parseFloat(item.smallPrice) }}
|
|
|
|
|
- </text>
|
|
|
|
|
- </text>
|
|
|
|
|
- </view>
|
|
|
|
|
-
|
|
|
|
|
- <view style="text-align:right;position:relative;">
|
|
|
|
|
- <view class="open-bx" >
|
|
|
|
|
- <text class="num">
|
|
|
|
|
- <text v-if="item.bigCount > 0" style="font-size:30upx;font-weight:bold;color:#3385ff;">
|
|
|
|
|
- {{ item.bigCount }}{{item.bigUnit}}
|
|
|
|
|
- </text>
|
|
|
|
|
- <text v-if="item.smallCount > 0" style="font-size:30upx;">
|
|
|
|
|
- {{ item.smallCount }}{{item.smallUnit}}
|
|
|
|
|
- </text>
|
|
|
|
|
- </text>
|
|
|
|
|
|
|
+ <view class="item-price-block">
|
|
|
|
|
+ <text class="price-current">{{ affirmCommodityPriceParts[index].main }}</text>
|
|
|
|
|
+ <text v-if="affirmCommodityPriceParts[index].showStrike" class="price-original">{{ affirmCommodityPriceParts[index].strike }}</text>
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
|
- <text v-if="isLimitExceededItem(item)" class="limit-exceed-tip">限购 {{ limitExceedLimitBuy }},超出 {{ limitExceedNum }}</text>
|
|
|
|
|
- <text v-if="item.presell == 1" style="position:absolute;top:86upx;font-weight:bold;color:red;font-size:30upx;">预售花材下单不能退款</text>
|
|
|
|
|
|
|
+ <view class="item-row-qty">
|
|
|
|
|
+ <text v-if="item.bigCount > 0" class="qty-part qty-big">{{ item.bigCount }}{{ item.bigUnit }}</text>
|
|
|
|
|
+ <text v-if="item.bigCount > 0 && item.smallCount > 0" class="qty-sep">·</text>
|
|
|
|
|
+ <text v-if="item.smallCount > 0" class="qty-part qty-small">{{ item.smallCount }}{{ item.smallUnit }}</text>
|
|
|
|
|
+ </view>
|
|
|
|
|
+ <view v-if="isLimitExceededItem(item) || getLimitBuyPriceTip(item) || item.presell == 1" class="item-row-tips">
|
|
|
|
|
+ <text v-if="isLimitExceededItem(item)" class="limit-exceed-tip">限购 {{ limitExceedLimitBuy }},超出 {{ limitExceedNum }}</text>
|
|
|
|
|
+ <text v-if="getLimitBuyPriceTip(item)" class="limit-buy-price-tip">{{ getLimitBuyPriceTip(item) }}</text>
|
|
|
|
|
+ <text v-if="item.presell == 1" class="presell-tip">预售花材下单不能退款</text>
|
|
|
|
|
+ </view>
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
@@ -57,8 +49,6 @@
|
|
|
</view>
|
|
</view>
|
|
|
|
|
|
|
|
<view class="module-com input-line-wrap">
|
|
<view class="module-com input-line-wrap">
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
<block v-if="ghsInfo.pfLevel && ghsInfo.pfLevel == 1">
|
|
<block v-if="ghsInfo.pfLevel && ghsInfo.pfLevel == 1">
|
|
|
|
|
|
|
|
<tui-list-cell class="line-cell" :hover="false" :arrow="false" v-if="ghsInfo.shopId == 14636">
|
|
<tui-list-cell class="line-cell" :hover="false" :arrow="false" v-if="ghsInfo.shopId == 14636">
|
|
@@ -508,6 +498,11 @@ export default {
|
|
|
},
|
|
},
|
|
|
computed: {
|
|
computed: {
|
|
|
...mapGetters(["getMerchantInfo", "getLoginInfo","getDictionariesInfo"]),
|
|
...mapGetters(["getMerchantInfo", "getLoginInfo","getDictionariesInfo"]),
|
|
|
|
|
+ /** 确认页列表每行价格展示(与 selectList 顺序一致) */
|
|
|
|
|
+ affirmCommodityPriceParts() {
|
|
|
|
|
+ const list = this.selectList || [];
|
|
|
|
|
+ return list.map(item => this.getLimitBuyPriceDisplayParts(item));
|
|
|
|
|
+ },
|
|
|
displayAddress(){
|
|
displayAddress(){
|
|
|
if(this.form.sendType != 1){
|
|
if(this.form.sendType != 1){
|
|
|
return true
|
|
return true
|
|
@@ -628,7 +623,7 @@ export default {
|
|
|
* @returns {number}
|
|
* @returns {number}
|
|
|
*/
|
|
*/
|
|
|
modifyPrice(){
|
|
modifyPrice(){
|
|
|
- let allPrice = this.allPrice.toFixed(2)
|
|
|
|
|
|
|
+ let allPrice = this.allPriceFun.toFixed(2)
|
|
|
allPrice = Number(allPrice)
|
|
allPrice = Number(allPrice)
|
|
|
let price = allPrice
|
|
let price = allPrice
|
|
|
|
|
|
|
@@ -1088,6 +1083,7 @@ export default {
|
|
|
confirmFn(options) {
|
|
confirmFn(options) {
|
|
|
createOrder(options).then(res => {
|
|
createOrder(options).then(res => {
|
|
|
this.resetSelectInfoByType(this.pageType);
|
|
this.resetSelectInfoByType(this.pageType);
|
|
|
|
|
+ this.resetLimitBuyInfoByType(this.pageType);
|
|
|
const { data: { id, orderSn } } = res;
|
|
const { data: { id, orderSn } } = res;
|
|
|
let url = `/admin/billing/result?orderId=${id}&orderSn=${orderSn}`;
|
|
let url = `/admin/billing/result?orderId=${id}&orderSn=${orderSn}`;
|
|
|
uni.redirectTo({ url: url })
|
|
uni.redirectTo({ url: url })
|
|
@@ -1154,6 +1150,7 @@ export default {
|
|
|
self.pageTo({url: '/pagesPurchase/wechatPay',query:{orderSn,realPrice,id}, type: 2})
|
|
self.pageTo({url: '/pagesPurchase/wechatPay',query:{orderSn,realPrice,id}, type: 2})
|
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
|
self.removeMemory(self.ghsInfo.id)
|
|
self.removeMemory(self.ghsInfo.id)
|
|
|
|
|
+ self.resetLimitBuyInfoByType(self.pageType)
|
|
|
}, 600)
|
|
}, 600)
|
|
|
return true
|
|
return true
|
|
|
}
|
|
}
|
|
@@ -1278,103 +1275,105 @@ export default {
|
|
|
flex-shrink: 0;
|
|
flex-shrink: 0;
|
|
|
width: 140upx;
|
|
width: 140upx;
|
|
|
height: 140upx;
|
|
height: 140upx;
|
|
|
|
|
+ border-radius: 4upx;
|
|
|
|
|
+ background-color: #f5f5f5;
|
|
|
}
|
|
}
|
|
|
.item-info {
|
|
.item-info {
|
|
|
- position: relative;
|
|
|
|
|
display: flex;
|
|
display: flex;
|
|
|
flex-direction: column;
|
|
flex-direction: column;
|
|
|
- justify-content: center;
|
|
|
|
|
|
|
+ justify-content: flex-start;
|
|
|
flex: 1;
|
|
flex: 1;
|
|
|
margin-left: 20upx;
|
|
margin-left: 20upx;
|
|
|
- .limit-exceed-tip {
|
|
|
|
|
|
|
+ min-width: 0;
|
|
|
|
|
+ .item-row-top {
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ flex-direction: row;
|
|
|
|
|
+ align-items: center;
|
|
|
|
|
+ justify-content: space-between;
|
|
|
|
|
+ width: 100%;
|
|
|
|
|
+ }
|
|
|
|
|
+ .item-name {
|
|
|
|
|
+ flex: 1;
|
|
|
|
|
+ min-width: 0;
|
|
|
|
|
+ padding-right: 16upx;
|
|
|
|
|
+ color: #333333;
|
|
|
|
|
+ font-size: 30upx;
|
|
|
|
|
+ font-weight: bold;
|
|
|
|
|
+ overflow: hidden;
|
|
|
|
|
+ white-space: nowrap;
|
|
|
|
|
+ text-overflow: ellipsis;
|
|
|
|
|
+ line-height: 1.3;
|
|
|
|
|
+ }
|
|
|
|
|
+ .item-price-block {
|
|
|
|
|
+ flex-shrink: 0;
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ flex-direction: row;
|
|
|
|
|
+ align-items: baseline;
|
|
|
|
|
+ max-width: 48%;
|
|
|
|
|
+ }
|
|
|
|
|
+ .price-current {
|
|
|
|
|
+ font-size: 32upx;
|
|
|
|
|
+ font-weight: bold;
|
|
|
|
|
+ color: #333333;
|
|
|
|
|
+ white-space: nowrap;
|
|
|
|
|
+ line-height: 1.2;
|
|
|
|
|
+ }
|
|
|
|
|
+ .price-original {
|
|
|
|
|
+ margin-left: 12upx;
|
|
|
|
|
+ font-size: 26upx;
|
|
|
|
|
+ color: #999999;
|
|
|
|
|
+ text-decoration: line-through;
|
|
|
|
|
+ white-space: nowrap;
|
|
|
|
|
+ line-height: 1.2;
|
|
|
|
|
+ }
|
|
|
|
|
+ .item-row-qty {
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ flex-direction: row;
|
|
|
|
|
+ justify-content: flex-end;
|
|
|
|
|
+ align-items: center;
|
|
|
|
|
+ margin-top: 10upx;
|
|
|
|
|
+ flex-wrap: wrap;
|
|
|
|
|
+ }
|
|
|
|
|
+ .qty-sep {
|
|
|
|
|
+ margin: 0 8upx;
|
|
|
|
|
+ color: #cccccc;
|
|
|
|
|
+ font-size: 28upx;
|
|
|
|
|
+ }
|
|
|
|
|
+ .qty-part {
|
|
|
|
|
+ font-size: 28upx;
|
|
|
|
|
+ color: #666666;
|
|
|
|
|
+ }
|
|
|
|
|
+ .qty-big {
|
|
|
|
|
+ font-size: 30upx;
|
|
|
|
|
+ font-weight: bold;
|
|
|
|
|
+ color: #3385ff;
|
|
|
|
|
+ }
|
|
|
|
|
+ .item-row-tips {
|
|
|
|
|
+ display: flex;
|
|
|
|
|
+ flex-direction: column;
|
|
|
margin-top: 10upx;
|
|
margin-top: 10upx;
|
|
|
|
|
+ }
|
|
|
|
|
+ .limit-exceed-tip {
|
|
|
|
|
+ margin-top: 4upx;
|
|
|
color: #ff4d4f;
|
|
color: #ff4d4f;
|
|
|
font-size: 24upx;
|
|
font-size: 24upx;
|
|
|
font-weight: bold;
|
|
font-weight: bold;
|
|
|
|
|
+ line-height: 1.45;
|
|
|
}
|
|
}
|
|
|
- .info-line {
|
|
|
|
|
- margin-bottom: 20upx;
|
|
|
|
|
- display: flex;
|
|
|
|
|
- justify-content: space-between;
|
|
|
|
|
- align-items: flex-end;
|
|
|
|
|
- .item-name {
|
|
|
|
|
- color: #333333;
|
|
|
|
|
- font-size: 32upx;
|
|
|
|
|
- font-weight:bold;
|
|
|
|
|
- overflow: hidden;
|
|
|
|
|
- white-space: nowrap;
|
|
|
|
|
- text-overflow: ellipsis;
|
|
|
|
|
- width:400upx;
|
|
|
|
|
- }
|
|
|
|
|
- .item-price {
|
|
|
|
|
- color: #333;
|
|
|
|
|
- font-size: 22upx;
|
|
|
|
|
- .price {
|
|
|
|
|
- font-size: 32upx;
|
|
|
|
|
- font-weight: bold;
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
- .item-type {
|
|
|
|
|
- color: #999;
|
|
|
|
|
- font-size: 24upx;
|
|
|
|
|
- }
|
|
|
|
|
- .item-count {
|
|
|
|
|
- color: #666;
|
|
|
|
|
- font-size: 24upx;
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ .limit-buy-price-tip {
|
|
|
|
|
+ margin-top: 4upx;
|
|
|
|
|
+ color: #ff7a00;
|
|
|
|
|
+ font-size: 24upx;
|
|
|
|
|
+ font-weight: bold;
|
|
|
|
|
+ line-height: 1.45;
|
|
|
|
|
+ }
|
|
|
|
|
+ .presell-tip {
|
|
|
|
|
+ margin-top: 4upx;
|
|
|
|
|
+ color: #e53935;
|
|
|
|
|
+ font-size: 24upx;
|
|
|
|
|
+ font-weight: bold;
|
|
|
|
|
+ line-height: 1.45;
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
- .open-bx {
|
|
|
|
|
- align-items: center;
|
|
|
|
|
- & .iconfont {
|
|
|
|
|
- color: #3385ff;
|
|
|
|
|
- font-size: 42upx;
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- .position{
|
|
|
|
|
- display: block;
|
|
|
|
|
- width: 70upx;
|
|
|
|
|
- text-align: center;
|
|
|
|
|
- }
|
|
|
|
|
- .iconcachu {
|
|
|
|
|
- margin: 0 6upx 0 20upx;
|
|
|
|
|
- color: #ccc;
|
|
|
|
|
- &.edit {
|
|
|
|
|
- color: #3385ff;
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
- & > .num {
|
|
|
|
|
- display: inline-block;
|
|
|
|
|
- width: 120upx;
|
|
|
|
|
- height:45upx;
|
|
|
|
|
- text-align:right;
|
|
|
|
|
- margin: 0 8upx;
|
|
|
|
|
- color: #868686;
|
|
|
|
|
- padding: 3upx 0;
|
|
|
|
|
- font-size: 25upx;
|
|
|
|
|
- }
|
|
|
|
|
- .change-input {
|
|
|
|
|
- width: 164upx;
|
|
|
|
|
- height: 60upx;
|
|
|
|
|
- line-height: 60upx;
|
|
|
|
|
- text-align: center;
|
|
|
|
|
- background: #ffffff;
|
|
|
|
|
- border: 1upx solid #dddddd;
|
|
|
|
|
- border-radius: 4upx;
|
|
|
|
|
- font-size: 25upx;
|
|
|
|
|
- }
|
|
|
|
|
- .btn-box{
|
|
|
|
|
- width: 100upx;
|
|
|
|
|
- height: 60upx;
|
|
|
|
|
- line-height: 60upx;
|
|
|
|
|
- color: #ffffff;
|
|
|
|
|
- background: #3385ff;
|
|
|
|
|
- text-align: center;
|
|
|
|
|
- border-radius: 10upx;
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|