积分商品流程完成,billpirce改为flowprice,必填项提示错误

master
mabo 2021-08-05 17:10:10 +08:00
parent 35881e30e0
commit 1f054b796d
15 changed files with 273 additions and 165 deletions

View File

@ -97,13 +97,11 @@ export default {
const time = new Date().getTime() - 5 * 60 * 1000
if (!reloadTime) {
hotWords({count: 5}).then(res => {
console.log(res);
if (res.success && res.result) storage.setItem('hotWordsList', res.result)
})
storage.setItem('hotWordsReloadTime', new Date().getTime())
} else if (reloadTime && time > reloadTime) {
hotWords({count: 5}).then(res => {
console.log(res);
if (res.success && res.result) storage.setItem('hotWordsList', res.result)
})
storage.setItem('hotWordsReloadTime', new Date().getTime())

View File

@ -556,9 +556,6 @@ export default {
}
.item-select-row {
// display: flex;
// flex-direction: row;
// flex-wrap: wrap;
margin-bottom: 8px;
}
@ -568,10 +565,6 @@ export default {
align-items: center;
}
.item-select-img {
width: 36px;
}
.item-select-box {
padding: 5px;
margin-right: 8px;
@ -589,31 +582,11 @@ export default {
border: 0.5px solid $theme_color;
}
.item-select-box-disabled {
background-color: gray;
}
.item-select-img img {
width: 100%;
}
.item-select-intro p {
margin: 0px;
padding: 5px;
}
.item-select-class {
padding: 5px;
margin-right: 8px;
@include sub_background_color($light_background_color);
border: 0.5px solid #ccc;
cursor: pointer;
}
.item-select-class:hover {
border: 0.5px solid $theme_color;
}
.add-buy-car-box {
width: 100%;
margin-top: 15px;

View File

@ -17,10 +17,10 @@ export default {
* @description api请求基础路径
*/
api_dev: {
// common: 'http://192.168.0.101:8890',
// buyer: 'http://192.168.0.101:8888',
// seller: 'http://192.168.0.101:8889',
// manager: 'http://192.168.0.101:8887'
// common: 'http://192.168.0.100:8890',
// buyer: 'http://192.168.0.100:8888',
// seller: 'http://192.168.0.100:8889',
// manager: 'http://192.168.0.100:8887'
common: 'https://common-api.pickmall.cn',
buyer: 'https://buyer-api.pickmall.cn',

View File

@ -117,7 +117,7 @@
已节省<span>{{ priceDetailDTO.discountPrice | unitPrice("¥") }}</span>
</div>
<div class="ml_20 total-price">
总价不含运费:<div>{{ priceDetailDTO.billPrice | unitPrice("¥") }}</div>
总价不含运费:<div>{{ priceDetailDTO.flowPrice | unitPrice("¥") }}</div>
</div>
<div class="pay ml_20" @click="pay"></div>
</div>

View File

@ -8,7 +8,7 @@
<h3>积分日志</h3>
<Table :columns="logColumns" :data="logData.records">
<template slot-scope="{ row }" slot="point">
<div><span>{{row.pointType == "INCREASE" ? '+' : '-'}}</span>{{ row.variablePoint }}</div>
<div :style="{color:row.pointType === 'INCREASE' ? 'green' : 'red'}"><span>{{row.pointType === "INCREASE" ? '+' : ''}}</span>{{ row.variablePoint }}</div>
</template>
</Table>
<!-- 分页 -->

View File

@ -50,10 +50,12 @@
</div>
<div>
<!-- 订单基础操作 -->
<Button @click="goDetail(order.sn)" size="small">售后详情</Button>
<Button @click="openModal(order)" v-if="order.serviceStatus == 'PASS' &&
order.serviceType != 'RETURN_MONEY'" size="small">提交物流</Button>
<Button @click="cancel(order.sn)" v-if="order.afterSaleAllowOperationVO.cancel" size="small"></Button>
<Button @click="goDetail(order.sn)" type="info" size="small">售后详情</Button>
<Button @click="openModal(order)"
v-if="order.serviceStatus == 'PASS' &&
order.serviceType != 'RETURN_MONEY'"
type="warning" size="small">提交物流</Button>
<Button @click="cancel(order.sn)" type="error" v-if="order.afterSaleAllowOperationVO.cancel" size="small"></Button>
</div>
</div>
</div>

View File

@ -65,10 +65,10 @@
</div>
<div>
<!-- 订单基础操作 -->
<Button @click="orderDetail(order.sn)" size="small">订单详情</Button>
<Button @click="handleCancelOrder(order.sn)" v-if="order.allowOperationVO.cancel" size="small"></Button>
<Button @click="goPay(order.sn)" size="small" v-if="order.allowOperationVO.pay"></Button>
<Button @click="received(order.sn)" size="small" v-if="order.allowOperationVO.rog"></Button>
<Button @click="orderDetail(order.sn)" type="info" size="small">订单详情</Button>
<Button @click="handleCancelOrder(order.sn)" type="error" v-if="order.allowOperationVO.cancel" size="small"></Button>
<Button @click="goPay(order.sn)" size="small" type="success" v-if="order.allowOperationVO.pay"></Button>
<Button @click="received(order.sn)" size="small" type="warning" v-if="order.allowOperationVO.rog"></Button>
<!-- 售后 -->
<Button v-if="order.groupAfterSaleStatus.includes('NOT_APPLIED')" @click="applyAfterSale(order.orderItems)" size="small"></Button>
</div>

View File

@ -213,29 +213,6 @@
</li>
</ul>
</div>
<!-- 其他信息 -->
<div class="other" v-if="$route.query.way === 'POINT'">
<div class="card-head mt_20 mb_20">
<span>其他信息</span>
</div>
<div>
<div>
<span>使用积分</span
><Input
type="text"
style="width: 100px"
v-model.number="otherMsgForm.point"
placeholder="请输入使用积分"
/>
<span style="color: #999"
>您当前的可用积分为
{{ otherMsgForm.totalPoint }} 本订单最多可以使用{{
otherMsgForm.availablePoint
}}</span
>
</div>
</div>
</div>
<!-- 订单价格 -->
<div class="order-price">
<div>
@ -257,7 +234,13 @@
}}</span
>
</div>
<div>
<div v-if="$route.query.way === 'POINTS'">
<span>应付积分</span
><span class="actrual-price">{{
priceDetailDTO.payPoint
}}</span>
</div>
<div v-else>
<span>应付金额</span
><span class="actrual-price">{{
priceDetailDTO.flowPrice | unitPrice("¥")
@ -299,7 +282,6 @@ import {
cartGoodsPay,
createTrade,
selectAddr,
shippingMethod,
selectCoupon,
couponNum
} from '@/api/cart';
@ -318,13 +300,6 @@ export default {
receiptTitle: '个人',
receiptContent: '不开发票'
},
otherMsgForm: {
//
point: 0,
availablePoint: 10,
totalPoint: 100,
noGoods: 0
},
addressList: [], //
selectedAddress: {}, //
goodsList: [], //
@ -549,10 +524,14 @@ export default {
.then((res) => {
this.$Spin.hide();
if (res.success) {
this.$router.push({
path: '/payment',
query: { orderType: 'TRADE', sn: res.result.sn }
});
if (params.way === 'POINTS') { //
this.$router.push('/payDone')
} else {
this.$router.push({
path: '/payment',
query: { orderType: 'TRADE', sn: res.result.sn }
});
}
}
})
.catch(() => {

View File

@ -1,12 +1,12 @@
<template>
<div style="background:#fff;">
<BaseHeader></BaseHeader>
<Search></Search>
<Search style="border-bottom:2px solid red;"></Search>
<!-- <drawer></drawer> -->
<div class="base-width cate-container">
<Breadcrumb>
<BreadcrumbItem to="/">首页</BreadcrumbItem>
<BreadcrumbItem v-for="(item, index) in categoryBar" :to="goGoodsList(index)" target="_blank" :key="index">{{item.name}}</BreadcrumbItem>
<BreadcrumbItem>{{goodsMsg.pointsGoodsCategoryName}}</BreadcrumbItem>
</Breadcrumb>
</div>
<!-- 商品信息展示 -->
@ -15,87 +15,62 @@
<div class="item-detail-left">
<!-- 大图放大镜 -->
<div class="item-detail-big-img">
<pic-zoom :url="imgList[imgIndex].url" :scale="2"></pic-zoom>
<pic-zoom v-if="goodsSku.thumbnail" :url="goodsSku.thumbnail" :scale="2"></pic-zoom>
</div>
<div class="item-detail-img-row">
<div
class="item-detail-img-small"
@mouseover="imgIndex = index"
v-for="(item, index) in imgList"
:key="index"
>
<img :src="item.url" />
<div class="item-detail-img-small">
<img :src="goodsSku.thumbnail" />
</div>
</div>
<div class="goodsConfig mt_10">
<span @click="collect" ><Icon type="ios-heart" :color="isCollected ? '#ed3f14' : '#666'" />{{isCollected?'已收藏':'收藏'}}</span>
</div>
</div>
<!-- 右侧商品信息活动信息操作展示 -->
<div class="item-detail-right">
<div class="item-detail-title">
<p>
{{ skuDetail.goodsName }}
</p>
<p>{{ goodsSku.goodsName }}</p>
</div>
<div class="sell-point">
{{skuDetail.sellingPoint}}
{{goodsSku.sellingPoint}}
</div>
<!-- 商品详细 价格优惠券促销 -->
<!-- 商品详细 -->
<div class="item-detail-price-row">
<div class="item-price-left">
<!-- 商品原价 -->
<div class="item-price-row" v-if="!skuDetail.promotionPrice">
<div class="item-price-row">
<p>
<span class="item-price-title"> &nbsp;&nbsp;&nbsp;&nbsp;</span>
<span class="item-price">{{skuDetail.price | unitPrice("¥")}}</span>
<span class="item-price-title"> &nbsp;&nbsp;&nbsp;&nbsp;</span>
<span class="item-price">{{goodsMsg.points}}</span>
</p>
</div>
</div>
<!-- 选择规格 -->
<div class="item-select" v-for="(sku, index) in formatList" :key="sku.name">
<div class="item-select-title">
<p>{{ sku.name }}</p>
</div>
<div class="item-select-column">
<div class="item-select-row" v-for="(item) in sku.values" :key="item.value">
<div class="item-select-box" @click="select(index, item.value)"
:class="{ 'item-select-box-active': item.value === currentSelceted[index] }"
>
<div class="item-select-intro">
<p>{{ item.value }}</p>
</div>
</div>
</div>
</div>
</div>
<br />
<div class="add-buy-car-box">
<div class="item-select">
<div class="item-select-title">
<p>数量</p>
</div>
<div class="item-select-row">
<InputNumber :min="1" :disabled="skuDetail.quantity === 0" v-model="count"></InputNumber>
<span class="inventory"> 库存{{skuDetail.quantity}}</span>
<InputNumber :min="1" :disabled="goodsSku.quantity === 0" v-model="count"></InputNumber>
<span class="inventory"> 库存{{goodsSku.quantity}}</span>
</div>
</div>
<div class="item-select" v-if="skuDetail.goodsType !== 'VIRTUAL_GOODS' && skuDetail.weight !== 0">
<div class="item-select" v-if="goodsSku.goodsType !== 'VIRTUAL_GOODS' && goodsSku.weight !== 0">
<div class="item-select-title">
<p>重量</p>
</div>
<div class="item-select-row">
<span class="inventory"> {{skuDetail.weight}}kg</span>
<span class="inventory"> {{goodsSku.weight}}kg</span>
</div>
</div>
<div class="add-buy-car">
<Button type="error" :loading="loading" :disabled="goodsSku.quantity === 0" @click="pointBuy"></Button>
</div>
</div>
</div>
</div>
<!-- 商品详情 -->
<div class="base-width item-intro" ref="itemIntroGoods">
<div>商品介绍</div>
<div v-html="goodsSku.intro" v-if="goodsSku.intro"></div>
<div v-html="goodsSku.intro" class="mt_10 ml_10" v-if="goodsSku.intro"></div>
<div v-else style="margin:20px;">暂无商品介绍</div>
</div>
<Spin size="large" fix v-if="isLoading"></Spin>
@ -105,7 +80,8 @@
<script>
import Search from '@/components/Search';
import PicZoom from 'vue-piczoom';
import PicZoom from 'vue-piczoom';
import { addCartGoods } from '@/api/cart.js';
import { pointGoodsDetail } from '@/api/promotion';
export default {
name: 'PointGoodsDetail',
@ -125,7 +101,9 @@ export default {
goodsSku: {}, // sku
isLoading: false, //
categoryBar: [], //
onceFlag: true //
onceFlag: true, //
count: 1, //
loading: false //
};
},
methods: {
@ -139,28 +117,43 @@ export default {
this.goodsSku = res.result.goodsSku
} else {
this.$Message.error(res.message)
// this.$router.push('/')
this.$router.push('/')
}
}).catch(() => {
// this.$router.push('/')
this.$router.push('/')
});
},
goGoodsList (currIndex) { //
const arr = []
this.categoryBar.forEach((e, index) => {
if (index <= currIndex) {
arr.push(e.id)
pointBuy () {
const params = {
num: this.count,
skuId: this.goodsMsg.skuId,
cartType: 'POINTS'
};
this.loading = true;
addCartGoods(params).then(res => {
this.loading = false;
if (res.success) {
this.$router.push({path: '/pay', query: {way: params.cartType}});
} else {
this.$Message.warning(res.message);
}
})
return location.origin + '/goodsList?categoryId=' + arr.toString()
}).catch(() => {
this.loading = false;
});
},
handleScroll () { //
if (this.onceFlag) {
this.$nextTick(() => {
this.changeHeight('itemIntroGoods')
this.changeHeight()
});
this.onceFlag = false
}
},
changeHeight () { //
let goodsDetailCon = document.querySelector('.item-intro')
let heightCss = window.getComputedStyle(goodsDetailCon).height;
heightCss = parseInt(heightCss.substr(0, heightCss.length - 2)) + 89;
this.$refs.itemIntroGoods.style.height = heightCss + 'px';
}
},
components: {
@ -174,9 +167,178 @@ export default {
margin: 0 auto;
position: relative;
}
.cate-container {
.cate-container{
background-color: #eee;
height: 30px;
line-height: 30px;
padding-left: 10px;
margin-top: 10px;
}
//
.item-detail-show {
width: 1200px;
margin: 0 auto;
padding: 30px;
display: flex;
flex-direction: row;
}
.item-detail-left {
width: 350px;
margin-right: 30px;
}
.item-detail-big-img {
width: 350px;
height: 350px;
box-shadow: 0px 0px 8px $border_color;
cursor: pointer;
img {
width: 100%;
}
}
.item-detail-img-row {
margin-top: 15px;
display: flex;
}
.item-detail-img-small {
width: 68px;
height: 68px;
box-shadow: 0px 0px 8px #ccc;
cursor: pointer;
margin-left: 5px;
img {
height: 100%;
width: 100%;
}
}
/*商品选购详情*/
.item-detail-right {
flex: 1;
display: flex;
flex-direction: column;
}
.item-detail-title p {
@include content_color($light_content_color);
font-weight: bold;
font-size: 20px;
padding: 8px 0;
}
.item-detail-express {
font-size: 14px;
padding: 2px 3px;
border-radius: 3px;
background-color: $theme_color;
color: #fff;
}
/*商品标签*/
.item-detail-tag {
padding: 8px 0;
font-size: 12px;
color: $theme_color;
}
/*价格详情等*/
.item-detail-price-row {
padding: 10px;
display: flex;
flex-direction: row;
justify-content: space-between;
background: url("../../assets/images/goodsDetail/price-bg.png");
}
.item-price-left {
display: flex;
flex-direction: column;
}
.item-price-title {
color: #999999;
font-size: 14px;
margin-right: 15px;
}
.item-price-row {
margin: 5px 0px;
}
.item-price {
color: $theme_color;
font-size: 20px;
cursor: pointer;
}
.item-price-old {
color: gray;
text-decoration: line-through;
font-size: 14px;
margin-left: 5px;
}
.add-buy-car-box {
width: 100%;
margin-top: 15px;
border-top: 1px dotted $border_color;
}
.add-buy-car {
margin-top: 15px;
}
.item-select {
display: flex;
flex-direction: row;
margin-top: 15px;
}
.item-select-title {
@include content_color($light_content_color);
font-size: 14px;
margin-right: 15px;
width: 60px;
}
.item-select-column {
display: flex;
flex-wrap: wrap;
flex: 1;
}
.item-select-row {
margin-bottom: 8px;
}
.item-select-box {
display: flex;
flex-direction: row;
align-items: center;
padding: 5px;
margin-right: 8px;
@include background_color($light_background_color);
border: 0.5px solid $border_color;
cursor: pointer;
@include content_color($light_content_color);
}
.item-select-box:hover {
border: 0.5px solid $theme_color;
}
.item-select-box-active {
border: 0.5px solid $theme_color;
}
.item-select-intro p {
margin: 0px;
padding: 5px;
}
.sell-point {
font-size: 12px;
color: red;
margin-bottom: 5px;
}
//
.item-intro {
margin-top: 10px;
>div:nth-child(1) {

View File

@ -22,9 +22,7 @@
</div>
<div class="goods-show-price">
<span>
<span class="seckill-price text-danger">{{
item.settlementPrice | unitPrice("¥")
}} + {{item.points}}积分</span>
<span class="seckill-price text-danger">{{item.points}}积分</span>
</span>
</div>
<div class="goods-show-detail">

View File

@ -229,8 +229,8 @@ export default {
],
linkName: [{ required: true, message: '请填写联系人姓名' }],
linkPhone: [
{ required: true, message: '请填写联系人姓名' },
{ pattern: RegExp.mobile, message: '请填写正确手机号' }
{ required: true, message: '请填写公司电话' },
{ pattern: RegExp.mobile, message: '请填写正确的号码' }
],
companyEmail: [
{ required: true, message: '请填写电子邮箱' },

View File

@ -17,14 +17,14 @@ export default {
* @description api请求基础路径
*/
api_dev: {
// common: "https://common-api.pickmall.cn",
// buyer: "https://buyer-api.pickmall.cn",
// seller: "https://store-api.pickmall.cn",
// manager: "https://admin-api.pickmall.cn"
common: 'http://192.168.0.100:8890',
buyer: 'http://192.168.0.100:8888',
seller: 'http://192.168.0.100:8889',
manager: 'http://192.168.0.100:8887'
common: "https://common-api.pickmall.cn",
buyer: "https://buyer-api.pickmall.cn",
seller: "https://store-api.pickmall.cn",
manager: "https://admin-api.pickmall.cn"
// common: 'http://192.168.0.100:8890',
// buyer: 'http://192.168.0.100:8888',
// seller: 'http://192.168.0.100:8889',
// manager: 'http://192.168.0.100:8887'
},
api_prod: {
common: "https://common-api.pickmall.cn",

View File

@ -42,7 +42,7 @@
</p>
<p class="item">
<span class="label">性别</span>
<span v-if="memberInfo.sex==1" class="info"></span>
<span v-if="memberInfo.sex===1" class="info"></span>
<span v-else class="info"></span>
</p>
<p class="item">
@ -414,7 +414,6 @@
key: "beforePoint",
width: 150,
},
{
title: "变动积分",
key: "variablePoint",
@ -434,10 +433,9 @@
style: {
color: 'red'
}
}, "-" + params.row.variablePoint),
}, params.row.variablePoint),
]);
}
}
},
{
@ -483,7 +481,6 @@
} else if (params.row.orderType == "PINTUAN") {
return h('div', [h('span', {}, '拼团订单'),]);
}
}
},
{
@ -538,7 +535,6 @@
}
}
},
{
title: "售后状态",
key: "groupAfterSaleStatus",

View File

@ -106,7 +106,7 @@
style: {
color: 'red'
}
}, "-" + params.row.variablePoint),
}, params.row.variablePoint),
]);
}

View File

@ -18,14 +18,14 @@ export default {
* @description api请求基础路径
*/
api_dev: {
common: "https://common-api.pickmall.cn",
buyer: "https://buyer-api.pickmall.cn",
seller: "https://store-api.pickmall.cn",
manager: "https://admin-api.pickmall.cn"
// common: 'http://192.168.0.100:8890',
// buyer: 'http://192.168.0.100:8888',
// seller: 'http://192.168.0.100:8889',
// manager: 'http://192.168.0.100:8887'
// common: "https://common-api.pickmall.cn",
// buyer: "https://buyer-api.pickmall.cn",
// seller: "https://store-api.pickmall.cn",
// manager: "https://admin-api.pickmall.cn"
common: 'http://192.168.0.100:8890',
buyer: 'http://192.168.0.100:8888',
seller: 'http://192.168.0.100:8889',
manager: 'http://192.168.0.100:8887'
},
api_prod: {
common: "https://common-api.pickmall.cn",