Commit 7e5b2151 by 前端

Merge branch 'SAAS+V5.5.0' into 'master'

上线合并

See merge request !31
2 parents 09779cda e549376a
...@@ -132,6 +132,15 @@ const subOrderExpress = params => { ...@@ -132,6 +132,15 @@ const subOrderExpress = params => {
returnAll: true returnAll: true
}) })
} }
// 子订单确认收货(自营商品)
const subOrderReceive = params => {
params.method = 'scrm.api.shopmall.platform.web.confirm.receipt'
return http({
url,
data: params,
returnAll: true
})
}
// 售后列表 // 售后列表
const getSaleOrderList = params => { const getSaleOrderList = params => {
...@@ -345,6 +354,7 @@ export default { ...@@ -345,6 +354,7 @@ export default {
getOrderList, getOrderList,
getOrderDetail, getOrderDetail,
subOrderExpress, subOrderExpress,
subOrderReceive,
getSaleOrderList, getSaleOrderList,
getAfterSalesDetail, getAfterSalesDetail,
getYZHAfterSalesDetail, getYZHAfterSalesDetail,
......
...@@ -3,26 +3,22 @@ ...@@ -3,26 +3,22 @@
<div class="ctnr"> <div class="ctnr">
<div class="stutas-wrap"> <div class="stutas-wrap">
<span>订单状态:</span> <span>订单状态:</span>
<span v-if="!isLoading" class="stutas-circle" <span v-if="!isLoading" class="stutas-circle" :style="{ backgroundColor: transfStatus(orderInfo.payStatus, orderInfo.orderStatus, orderInfo.orderType).color }"></span>
:style="{ backgroundColor: transfStatus(orderInfo.payStatus, orderInfo.orderStatus, orderInfo.orderType).color }"></span>
<span v-if="!isLoading">{{ transfStatus(orderInfo.payStatus, orderInfo.orderStatus, orderInfo.orderType).name }}</span> <span v-if="!isLoading">{{ transfStatus(orderInfo.payStatus, orderInfo.orderStatus, orderInfo.orderType).name }}</span>
</div> </div>
<div class="info-wrap order-info"> <div class="info-wrap order-info">
<div class="title">订单信息</div> <div class="title">订单信息</div>
<div class="detail"> <div class="detail">
<glsxCombiForm ref="editFormRef" labelWidth="154px" defaultWidth="214px" :formObj="orderInfo" <glsxCombiForm ref="editFormRef" labelWidth="154px" defaultWidth="214px" :formObj="orderInfo" :formData="editFormData"></glsxCombiForm>
:formData="editFormData"></glsxCombiForm>
</div> </div>
</div> </div>
<div class="info-wrap"> <div class="info-wrap">
<div class="title">商品信息</div> <div class="title">商品信息</div>
<div class="detail"> <div class="detail">
<GLTable :hasPage="false" ref="goodsTableRef" :tableParams="tableParams" <GLTable :hasPage="false" ref="goodsTableRef" :tableParams="tableParams" :tableData="orderInfo.subOrderGoodsList">
:tableData="orderInfo.subOrderGoodsList">
<div slot="goodsNameSlot" class="goodsNameSlot" slot-scope="scope"> <div slot="goodsNameSlot" class="goodsNameSlot" slot-scope="scope">
<img :src="scope.scope.goodsImageUrl" alt=""> <img :src="scope.scope.goodsImageUrl" alt="">
<el-tooltip class="item" effect="dark" <el-tooltip class="item" effect="dark" :content="(scope.scope.brandName || '') + (scope.scope.goodsSkuName || '')" placement="top">
:content="(scope.scope.brandName || '') + (scope.scope.goodsSkuName || '')" placement="top">
<span class="name">{{ scope.scope.brandName }} {{ scope.scope.goodsSkuName }}</span> <span class="name">{{ scope.scope.brandName }} {{ scope.scope.goodsSkuName }}</span>
</el-tooltip> </el-tooltip>
</div> </div>
...@@ -38,19 +34,16 @@ ...@@ -38,19 +34,16 @@
<div class="info-wrap"> <div class="info-wrap">
<div class="title">发货信息</div> <div class="title">发货信息</div>
<div class="detail"> <div class="detail">
<GLTable :hasPage="false" ref="shipmentsRef" :tableParams="shipmentsParams" <GLTable :hasPage="false" ref="shipmentsRef" :tableParams="shipmentsParams" :tableData="orderInfo.subOrderGoodsList">
:tableData="orderInfo.subOrderGoodsList">
<div slot="goodsNameSlot" class="goodsNameSlot" slot-scope="scope"> <div slot="goodsNameSlot" class="goodsNameSlot" slot-scope="scope">
<img :src="scope.scope.goodsImageUrl" alt=""> <img :src="scope.scope.goodsImageUrl" alt="">
<el-tooltip class="item" effect="dark" <el-tooltip class="item" effect="dark" :content="(scope.scope.brandName || '') + (scope.scope.goodsSkuName || '')" placement="top">
:content="(scope.scope.brandName || '') + (scope.scope.goodsSkuName || '')" placement="top">
<span class="name">{{ scope.scope.brandName }} {{ scope.scope.goodsSkuName }}</span> <span class="name">{{ scope.scope.brandName }} {{ scope.scope.goodsSkuName }}</span>
</el-tooltip> </el-tooltip>
</div> </div>
<div slot="effectiveDays"> <div slot="effectiveDays">
<span v-show="orderInfo.logisticsStatus" class="circle" <span v-show="orderInfo.logisticsStatus" class="circle" :style="{backgroundColor: '#5850FF'}"></span>
:style="{backgroundColor: '#5850FF'}"></span>
<span>{{ <span>{{
{ {
1000: '待揽件', 1000: '待揽件',
...@@ -123,6 +116,13 @@ export default { ...@@ -123,6 +116,13 @@ export default {
// 1004: '拒收' // 1004: '拒收'
// }[this.orderInfo.logisticsStatus] || '--' // }[this.orderInfo.logisticsStatus] || '--'
// } // }
},
{
label: '发货时间',
prop: 'deliverTime',
formatter: cell => {
return this.orderInfo.deliverTime ? util.dateFormat(this.orderInfo.deliverTime, 'YYYY-MM-DD HH:mm:ss') : '--'
}
} }
] ]
}, },
...@@ -179,7 +179,7 @@ export default { ...@@ -179,7 +179,7 @@ export default {
type: 'showTxt' type: 'showTxt'
}, },
{ {
label: '支付金额', label: '商品总价',
name: 'payPrice', name: 'payPrice',
type: 'showTxt' type: 'showTxt'
}, },
...@@ -217,6 +217,11 @@ export default { ...@@ -217,6 +217,11 @@ export default {
label: '运费', label: '运费',
name: 'freightAmount', name: 'freightAmount',
type: 'showTxt' type: 'showTxt'
},
{
label: '实付金额',
name: 'totalScore',
type: 'showTxt'
} }
] ]
} }
...@@ -234,7 +239,7 @@ export default { ...@@ -234,7 +239,7 @@ export default {
methods: { methods: {
transfStatus: util.transfStatus, transfStatus: util.transfStatus,
getDetailById() { getDetailById() {
const {id} = this.$route.params const { id } = this.$route.params
const loading = this.$loading({ const loading = this.$loading({
lock: true, lock: true,
text: 'Loading', text: 'Loading',
...@@ -242,14 +247,15 @@ export default { ...@@ -242,14 +247,15 @@ export default {
background: 'rgba(0, 0, 0, 0.3)' background: 'rgba(0, 0, 0, 0.3)'
}) })
this.isLoading = true this.isLoading = true
this.$apis.platformGoods.getOrderDetail({subOrderCode: id}).then(res => { this.$apis.platformGoods.getOrderDetail({ subOrderCode: id }).then(res => {
loading.close() loading.close()
this.isLoading = false this.isLoading = false
if (res?.id) { if (res?.id) {
const {receiveName, receiveMobile, provinceName, cityName, townName, address} = res?.receiveAddress || {} const { receiveName, receiveMobile, provinceName, cityName, countyName, townName, address } = res?.receiveAddress || {}
res.addInfo = `${receiveName} ${receiveMobile} ${provinceName}${cityName}${townName}${address}` res.addInfo = `${receiveName} ${receiveMobile} ${provinceName}${cityName}${countyName}${townName}${address}`
res.addInfo = res.addInfo.replaceAll('null', '') res.addInfo = res.addInfo.replaceAll('null', '')
res.payPrice = res.redeemPoints ? res.redeemPoints + '积分' + '+' + (res.payPrice || 0) + '元' : res.payPrice + '元' res.payPrice = res.redeemPoints ? res.redeemPoints + '积分' + '+' + (res.payPrice || 0) + '元' : res.payPrice + '元'
res.totalScore = res.totalScore + '积分'
res.subOrderGoodsList = res?.subOrderGoodsList?.length ? res?.subOrderGoodsList : [] res.subOrderGoodsList = res?.subOrderGoodsList?.length ? res?.subOrderGoodsList : []
// res.logisticsStatus = undefined // res.logisticsStatus = undefined
this.orderInfo = res this.orderInfo = res
...@@ -280,7 +286,7 @@ export default { ...@@ -280,7 +286,7 @@ export default {
border-radius: 50%; border-radius: 50%;
width: 10px; width: 10px;
height: 10px; height: 10px;
background: #FDB757; background: #fdb757;
margin-right: 10px; margin-right: 10px;
vertical-align: middle; vertical-align: middle;
} }
...@@ -293,7 +299,7 @@ export default { ...@@ -293,7 +299,7 @@ export default {
.title { .title {
height: 60px; height: 60px;
line-height: 60px; line-height: 60px;
border-bottom: 1px solid #E5E5E5; border-bottom: 1px solid #e5e5e5;
padding: 0 20px; padding: 0 20px;
font-weight: 500; font-weight: 500;
font-size: 20px; font-size: 20px;
...@@ -306,11 +312,10 @@ export default { ...@@ -306,11 +312,10 @@ export default {
} }
.order-info { .order-info {
} }
} }
.orderAmount { .orderAmount {
color: #2CCA74; color: #2cca74;
} }
</style> </style>
...@@ -106,6 +106,18 @@ export default { ...@@ -106,6 +106,18 @@ export default {
listeners: { listeners: {
click: row => this.handleOrderExpress(row.scope) click: row => this.handleOrderExpress(row.scope)
} }
},
{
type: 'el-button',
name: '确认收货',
attrs: {
type: 'text',
fn: '确认收货'
},
condition: row => row.scope.goodsSource == 2 && row.scope.orderStatus == 1008,
listeners: {
click: row => this.handleOrderReceive(row.scope)
}
} }
], ],
searchForm: {}, searchForm: {},
...@@ -205,7 +217,7 @@ export default { ...@@ -205,7 +217,7 @@ export default {
prop: 'sellQty' prop: 'sellQty'
}, },
{ {
label: '实收金额 (元)', label: '商品总价',
width: 150, width: 150,
line: 1, line: 1,
align: 'right', align: 'right',
...@@ -381,6 +393,30 @@ export default { ...@@ -381,6 +393,30 @@ export default {
.finally(() => { .finally(() => {
this.batchLoading = false this.batchLoading = false
}) })
},
handleOrderReceive(row) {
this.$messageBox.confirm('请先与收货人确认收货后再进行此操作,是否确认收货?', '确认收货', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
callback: action => {
if (action == 'confirm') {
this.$apis.platformGoods
.subOrderReceive({
subOrderCode: row.subOrderCode
})
.then(res => {
let { code, message } = res
if (code == 0) {
this.$message.success('操作成功')
this.handleSearch()
} else {
this.$message.error(message)
}
})
}
}
})
} }
} }
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!