Commit 7935a71d by 前端

Merge branch 'SAAS+V4.25.1' into 'master'

Saas+v4.25.1

See merge request !535
2 parents 2f0e2deb 2bafba9d
import {http} from '@/main'
const getListApi = params => {
params.method = `scrm.api.shopmall.integralorder.page`
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true
})
}
const pointWriteOffExportApi = params => {
params.method = `scrm.api.shopmall.integralorder.export`
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true
})
}
const pointWriteOffDetail = params => {
params.method = `scrm.api.shopmall.integralorder.detail`
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true
})
}
export default {getListApi, pointWriteOffExportApi, pointWriteOffDetail}
...@@ -129,7 +129,8 @@ const orderSourceList = [ ...@@ -129,7 +129,8 @@ const orderSourceList = [
{ confId: '2', confName: '直播订单' }, { confId: '2', confName: '直播订单' },
{ confId: '3', confName: '秒杀订单' }, { confId: '3', confName: '秒杀订单' },
{ confId: '4', confName: '众筹订单' }, { confId: '4', confName: '众筹订单' },
{ confId: '6', confName: '配置升级订单' } { confId: '6', confName: '配置升级订单' },
{ confId: '7', confName: '车主优选订单' }
] ]
const deliveryTypeList = [ const deliveryTypeList = [
...@@ -213,14 +214,6 @@ const memberTypeList = [ ...@@ -213,14 +214,6 @@ const memberTypeList = [
{ {
confId: 2, confId: 2,
confName: '试用会员' confName: '试用会员'
},
{
confId: 3,
confName: '金卡会员'
},
{
confId: 4,
confName: '银卡会员'
} }
] ]
const stateList = [ const stateList = [
......
...@@ -88,7 +88,6 @@ export default { ...@@ -88,7 +88,6 @@ export default {
getList(page, isMounted = false) { getList(page, isMounted = false) {
var params = { var params = {
goodsStatus: 1, goodsStatus: 1,
goodsSources: [1,4],
currentPage: 1, currentPage: 1,
pageNum: 1, pageNum: 1,
pageSize: 100000, pageSize: 100000,
......
...@@ -536,7 +536,6 @@ export default { ...@@ -536,7 +536,6 @@ export default {
pageSize: 100000, pageSize: 100000,
pageStart: 0, pageStart: 0,
goodsStatus: 1, goodsStatus: 1,
goodsSources: [1, 4],
goodsName: '' goodsName: ''
} }
if (goodsName) { if (goodsName) {
......
...@@ -241,7 +241,9 @@ export default { ...@@ -241,7 +241,9 @@ export default {
itemValue: 4, itemValue: 4,
itemType: 'package', itemType: 'package',
getInterfaceApi: this.$apis.welcomeword.getPackage, getInterfaceApi: this.$apis.welcomeword.getPackage,
params: {} params: {
// state: 1
}
}, },
{ {
itemName: '商城券', itemName: '商城券',
...@@ -251,7 +253,8 @@ export default { ...@@ -251,7 +253,8 @@ export default {
params: { params: {
discountTypes: [2, 3, 4], discountTypes: [2, 3, 4],
directionalFlag: 1, // 1所有人可用2定向礼包专用3关联优惠券 directionalFlag: 1, // 1所有人可用2定向礼包专用3关联优惠券
validType: 'valid' validType: 'valid',
// status: 2
} }
}, },
{ {
......
...@@ -65,7 +65,8 @@ ...@@ -65,7 +65,8 @@
<td <td
style="text-align: left;" style="text-align: left;"
colspan="3" colspan="3"
>优惠券</td> >优惠券
</td>
<td>{{ detailForm.subOrderCoupon.discountAmount }}元</td> <td>{{ detailForm.subOrderCoupon.discountAmount }}元</td>
</tr> </tr>
</tbody> </tbody>
...@@ -124,17 +125,19 @@ ...@@ -124,17 +125,19 @@
<el-button <el-button
@click="handleCancel" @click="handleCancel"
size="medium" size="medium"
>取消</el-button> >取消
</el-button>
</GLFooter> </GLFooter>
</div> </div>
</template> </template>
<script> <script>
import * as dayjs from 'dayjs' import * as dayjs from 'dayjs'
import { orderManageStatusList, orderSourceList, deliveryTypeList } from '@/common/constant' import {orderManageStatusList, orderSourceList, deliveryTypeList} from '@/common/constant'
export default { export default {
name: 'orderDetail', name: 'orderDetail',
data () { data() {
return { return {
size: 'small', size: 'small',
title: '查看订单', title: '查看订单',
...@@ -186,27 +189,28 @@ export default { ...@@ -186,27 +189,28 @@ export default {
orderSourceList: orderSourceList, orderSourceList: orderSourceList,
deliveryTypeList: deliveryTypeList, deliveryTypeList: deliveryTypeList,
refundTypeList: [ refundTypeList: [
{ confId: '1', confName: '退款退货' }, {confId: '1', confName: '退款退货'},
{ confId: '2', confName: '退款不退货' }, {confId: '2', confName: '退款不退货'},
{ confId: '3', confName: '众筹订单退款' } {confId: '3', confName: '众筹订单退款'}
], ],
shareStaffTypeList: [ shareStaffTypeList: [
{ confId: '1', confName: '个微' }, {confId: '1', confName: '个微'},
{ confId: '2', confName: '企微' } {confId: '2', confName: '企微'}
] ]
}, },
configShow: false configShow: false
} }
}, },
created () { }, created() {
},
mounted () { mounted() {
this.getCrowdfundingOrderConfig() this.getCrowdfundingOrderConfig()
}, },
methods: { methods: {
async getCrowdfundingOrderConfig () { async getCrowdfundingOrderConfig() {
let detailFormData = [ let detailFormData = [
{ {
label: '订单编号', label: '订单编号',
...@@ -289,7 +293,7 @@ export default { ...@@ -289,7 +293,7 @@ export default {
const res = await this.$apis.common.getCrowdfundingOrderConfig() const res = await this.$apis.common.getCrowdfundingOrderConfig()
let configShow = res != 1 let configShow = res != 1
if (!configShow) { if (!configShow) {
const filterFormList = ['customerPhone','shareStaffName', 'shareStaffTypeName', 'vin', 'shipAddress'] const filterFormList = ['customerPhone', 'shareStaffName', 'shareStaffTypeName', 'vin', 'shipAddress']
for (let i = 0; i < detailFormData.length; i++) { for (let i = 0; i < detailFormData.length; i++) {
if (filterFormList.includes(detailFormData[i].name)) { if (filterFormList.includes(detailFormData[i].name)) {
detailFormData.splice(i, 1) detailFormData.splice(i, 1)
...@@ -304,7 +308,7 @@ export default { ...@@ -304,7 +308,7 @@ export default {
this.getInfo() this.getInfo()
this.formToRow('afterInfoData') this.formToRow('afterInfoData')
}, },
formToRow (formName, numOfRow = 3) { formToRow(formName, numOfRow = 3) {
var rowNum = Math.ceil(this[formName].length / numOfRow) var rowNum = Math.ceil(this[formName].length / numOfRow)
for (var i = 0; i < rowNum; i++) { for (var i = 0; i < rowNum; i++) {
for (var j = 0; j < numOfRow; j++) { for (var j = 0; j < numOfRow; j++) {
...@@ -319,10 +323,20 @@ export default { ...@@ -319,10 +323,20 @@ export default {
} }
} }
}, },
getInfo () { getInfo() {
this.$apis.orderManage.getOrderDetailApi({ orderCode: this.routeInfo.orderCode }).then(res => { this.$apis.orderManage.getOrderDetailApi({orderCode: this.routeInfo.orderCode}).then(res => {
this.detailForm = res this.detailForm = res
this.orderRefund = res.orderRefund || null this.orderRefund = res.orderRefund || null
if (res.orderSource == 6 || res.orderSource == 7) {
this.detailFormData.find(item => {
if (item.label == '支付定金') {
item.name = 'orderPrice'
}
if (item.label == '尾款') {
item.name = 'finalPaymentAmount'
}
})
}
this.detailForm.createdDateStr = dayjs(this.detailForm.createdDate).format('YYYY-MM-DD HH:mm:ss') this.detailForm.createdDateStr = dayjs(this.detailForm.createdDate).format('YYYY-MM-DD HH:mm:ss')
if (this.orderRefund) { if (this.orderRefund) {
this.orderRefund.refundTypeName = this.baseData.refundTypeList.map(item => item.confId).includes(res.orderRefund.refundType + '') ? this.baseData.refundTypeList.find(item => item.confId == res.orderRefund.refundType).confName : '-' this.orderRefund.refundTypeName = this.baseData.refundTypeList.map(item => item.confId).includes(res.orderRefund.refundType + '') ? this.baseData.refundTypeList.find(item => item.confId == res.orderRefund.refundType).confName : '-'
...@@ -340,6 +354,12 @@ export default { ...@@ -340,6 +354,12 @@ export default {
this.detailForm.crowdFundingPrice = (res.crowdFundingPrice - res.payPrice).toFixed(2) + '元' this.detailForm.crowdFundingPrice = (res.crowdFundingPrice - res.payPrice).toFixed(2) + '元'
} }
this.detailForm.payPrice = res.payPrice ? res.payPrice + '元' : '0元' this.detailForm.payPrice = res.payPrice ? res.payPrice + '元' : '0元'
// 尾款转化为元
if ((res.finalPaymentAmount || res.finalPaymentAmount == 0) && (res.orderPrice || res.orderPrice == 0)) {
this.detailForm.finalPaymentAmount = (res.finalPaymentAmount / 100).toFixed(2) + '元'
}
this.detailForm.orderPrice = res.orderPrice ? res.orderPrice + '元' : '0元'
this.detailForm.orderSourceName = this.baseData.orderSourceList.map(item => item.confId).includes(res.orderSource + '') ? this.baseData.orderSourceList.find(item => item.confId == res.orderSource).confName : '-' this.detailForm.orderSourceName = this.baseData.orderSourceList.map(item => item.confId).includes(res.orderSource + '') ? this.baseData.orderSourceList.find(item => item.confId == res.orderSource).confName : '-'
this.detailForm.orderStatusName = this.baseData.orderStatusList.map(item => item.confId).includes(res.orderStatus + '') ? this.baseData.orderStatusList.find(item => item.confId == res.orderStatus).confName : '-' this.detailForm.orderStatusName = this.baseData.orderStatusList.map(item => item.confId).includes(res.orderStatus + '') ? this.baseData.orderStatusList.find(item => item.confId == res.orderStatus).confName : '-'
if (!this.detailForm.takeFee) { if (!this.detailForm.takeFee) {
...@@ -374,7 +394,7 @@ export default { ...@@ -374,7 +394,7 @@ export default {
this.formToRow('detailFormData') this.formToRow('detailFormData')
}) })
}, },
handleCancel () { handleCancel() {
this.$router.push({ this.$router.push({
path: '/orderManage/index' path: '/orderManage/index'
}) })
...@@ -386,29 +406,37 @@ export default { ...@@ -386,29 +406,37 @@ export default {
.marketing.order-detail .el-form--inline .el-form-item { .marketing.order-detail .el-form--inline .el-form-item {
margin: 0; margin: 0;
} }
.marketing.order-detail .el-form--inline .el-form-item__content { .marketing.order-detail .el-form--inline .el-form-item__content {
height: 30px; height: 30px;
} }
.marketing.order-detail .form-img .el-form--inline .el-form-item__content { .marketing.order-detail .form-img .el-form--inline .el-form-item__content {
height: auto !important; height: auto !important;
} }
.marketing.order-detail .flex { .marketing.order-detail .flex {
justify-content: flex-start; justify-content: flex-start;
} }
.marketing.order-detail .row-item { .marketing.order-detail .row-item {
width: 33%; width: 33%;
} }
.detail-txt { .detail-txt {
display: inline-block; display: inline-block;
width: 220px; width: 220px;
} }
.marketing.order-detail .show-table > tbody > tr > td { .marketing.order-detail .show-table > tbody > tr > td {
text-align: center; text-align: center;
vertical-align: middle; vertical-align: middle;
} }
.marketing.order-detail .show-table td { .marketing.order-detail .show-table td {
padding-right: 20px; padding-right: 20px;
} }
.order-detail .comment-img { .order-detail .comment-img {
margin-top: 10px; margin-top: 10px;
margin-right: 20px; margin-right: 20px;
......
<template>
<div class="marketing">
<div class="wa-container">
<div class="big-title">查看详情</div>
<div class="details-content">
<div class="content" v-for="(item,index) in detailsList" :key="index">
<div class="list-text">
<span class="label">{{ item.label }}:</span>
<span class="prop" v-if="detailsRes">{{ detailsRes[item.prop] || '--' }}</span>
</div>
</div>
</div>
</div>
<el-button type="primary" class="back-btn" @click="handleBack">返回</el-button>
</div>
</template>
<script>
export default {
name: "details",
data() {
return {
detailsList: [
{
label: '项目名称',
prop: 'bizRelName'
},
{
label: '消费积分',
prop: 'integralValue'
},
{
label: '客户昵称',
prop: 'customerWechatName'
},
{
label: '手机号',
prop: 'customerPhone'
},
{
label: '核销员工',
prop: 'verificationStaff'
},
{
label: '结算状态',
prop: 'settlementStatus'
},
{
label: '核销日期',
prop: 'verificationTime'
},
{
label: '订单编号',
prop: 'orderCode'
}
],
detailsRes: null
}
},
methods: {
getDetails(id) {
let params = {
id
}
this.$apis.pointWriteOff.pointWriteOffDetail(params).then(res => {
res.settlementStatus = res.settlementStatus == 0 ? '未结算' : '已结算'
this.detailsRes = res
})
},
handleBack() {
this.$router.back()
}
},
created() {
let id = this.$route.query.id || ''
this.getDetails(id)
}
}
</script>
<style lang="scss" scoped>
.wa-container {
background: #FFFFFF;
min-height: 80vh;
.big-title {
font-size: 16px;
font-weight: 600;
padding: 15px 20px;
color: #333;
border-bottom: 1px solid #E5E5E5;
}
.details-content {
padding: 50px 120px;
display: grid;
grid-template-columns: 33.3% 33.3% 33.3%;
.list-text {
margin-bottom: 20px;
font-size: 14px;
.label {
color: #666666;
}
.prop{
color: #333333;
}
}
}
}
.back-btn {
margin: 16px auto;
display: flex;
}
</style>
<template>
<div class=" marketing pointerWriteOff">
<div class="container">
<GLCombiForm ref="pointerWriteOffSearch" :rowNumber="1" :formObj="searchForm" :formData="searchFormData"
@handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm>
<div class="exportBtn">
<el-button :size="size" @click="handleExport" class="default-blue-btn" type="default">导出</el-button>
</div>
<GLTable ref="pointerWriteOffRef" :getListApi="getListApi" :noDataImg="url" :searchForm="searchForm"
:tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn">
<div class="table-btns" slot="auth-button" slot-scope="scope">
<GLTableButton :buttonList="tableButtonList" :buttonItem="scope.scope" :buttonNum="3"></GLTableButton>
</div>
</GLTable>
</div>
</div>
</template>
<script>
import {exportFn} from "@/common/constant";
export default {
name: "index",
data() {
return {
size: 'small',
searchForm: {
// merchantId: this.$globalState.session.merchantId,
// merchantName: this.$globalState.session.merchantName
},
searchFormData: [
{
label: '项目名称',
name: 'bizRelName',
type: 'input',
placeholder: '请输入项目名称'
},
{
label: '核销日期',
name: 'createDate',
type: 'datePicker',
isClear: true,
pickerOptions: 'beforeRangePickerOptions'
},
{
label: '结算状态',
name: 'settlementStatus',
type: 'select',
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'waiteOffStatusList'
}
],
baseData: {
waiteOffStatusList: [
{
confId: '0',
confName: '未结算'
},
{
confId: '1',
confName: '已结算'
}
],
},
getListApi: this.$apis.pointWriteOff.getListApi,
tableParams: {
listName: 'list',
tableOption: true,
tableColumns: [
{
label: '项目名称',
prop: 'bizRelName',
width: 280
},
{
label: '消费积分',
prop: 'integralValue',
width: 150
},
{
label: '客户昵称',
width: 150,
prop: 'customerWechatName'
},
{
label: '手机号',
prop: 'customerPhone',
width: 200,
line: 1
},
{
label: '核销员工',
prop: 'verificationStaffName',
width: 150
},
{
label: '结算状态',
prop: 'settlementStatus',
width: 100,
formatter: cellValue => {
return this.baseData.waiteOffStatusList.find(item => item.confId == cellValue.settlementStatus).confName
}
},
{
label: '核销日期',
width: 200,
prop: 'verificationTime'
},
{
label: '订单编号',
prop: 'orderCode',
width: 220
}
],
},
tableButtonList: [
{
type: 'el-button',
name: '查看',
attrs: {
type: 'text'
},
// condition: row => {
// return row.sopStatus != 1
// },
listeners: {
click: row => this.$router.push({
path: '/pointWriteOff/details',
query: row ? { id: row.id } : ''
})
}
},
],
pageConf: {pageSize: 'pageSize', pageNum: 'currentPage', totalCount: 'total'},
}
},
mounted() {
this.getOptionsList('searchFormData')
},
methods: {
getParams() {
var params = JSON.parse(JSON.stringify(this.searchForm))
if (this.searchForm.createDate?.length) {
params.verificationStartTime = new Date(this.searchForm.createDate[0]).toLocaleDateString().replace(/\//g, '-') + ' 00:00:00'
params.verificationEndTime = new Date(this.searchForm.createDate[1]).toLocaleDateString().replace(/\//g, '-') + ' 23:59:59'
}
delete params.createDate
return params
},
handleReset() {
this.searchForm = {
bizRelName: '',
settlementStatus: '',
createDate: []
}
this.handleSearch()
},
getOptionsList(formName, hasAll = true, refreshSigle) {
if (refreshSigle) {
var item = this[formName].find(k => k.name == refreshSigle)
var index = this[formName].findIndex(k => k.name == refreshSigle)
this.$set(this[formName][index], 'optionList', this.$common.utils.deepClone(this.baseData[item.optionsName]))
if (hasAll && this.baseData[item.optionsName].length && this.baseData[item.optionsName][0][this[formName][index].optionLabel] !== '全部') {
const temp = {}
temp[this[formName][index].optionId] = ''
temp[this[formName][index].optionLabel] = '全部'
this[formName][index].optionList.unshift(temp)
}
} else {
this[formName].forEach((item, index) => {
if (item.type === 'select' && this.baseData[item.optionsName].length) {
this.$set(this[formName][index], 'optionList', this.$common.utils.deepClone(this.baseData[item.optionsName]))
if (hasAll && this.baseData[item.optionsName].length && this.baseData[item.optionsName][0][this[formName][index].optionLabel] !== '全部') {
const temp = {}
temp[this[formName][index].optionId] = ''
temp[this[formName][index].optionLabel] = '全部'
this[formName][index].optionList.unshift(temp)
}
}
})
}
},
handleSearch() {
this.$refs.pointerWriteOffRef.refreshTable()
},
beforeSearchFn() {
return new Promise(resolve => {
this.searchForm = this.getParams()
// delete this.searchForm.createDate
resolve()
})
},
handleExport() {
var params = this.getParams()
this.$apis.pointWriteOff.pointWriteOffExportApi(params).then(res => {
exportFn(res)
})
},
}
}
</script>
<style lang="scss" scoped>
.exportBtn {
float: right;
margin-bottom: 10px;
}
</style>
...@@ -339,6 +339,10 @@ export default { ...@@ -339,6 +339,10 @@ export default {
{ {
confId: '4', confId: '4',
confName: '配置升级商品' confName: '配置升级商品'
},
{
confId: '5',
confName: '车主优选商品'
} }
] ]
} }
......
...@@ -209,7 +209,9 @@ export default { ...@@ -209,7 +209,9 @@ export default {
itemValue: 4, itemValue: 4,
itemType: 'package', itemType: 'package',
getInterfaceApi: this.$apis.welcomeword.getPackage, getInterfaceApi: this.$apis.welcomeword.getPackage,
params: {} params: {
// state: 1
}
}, },
{ {
itemName: '商城券', itemName: '商城券',
...@@ -219,7 +221,8 @@ export default { ...@@ -219,7 +221,8 @@ export default {
params: { params: {
discountTypes: [2, 3, 4], discountTypes: [2, 3, 4],
directionalFlag: 1, // 1所有人可用2定向礼包专用3关联优惠券 directionalFlag: 1, // 1所有人可用2定向礼包专用3关联优惠券
validType: 'valid' validType: 'valid',
// status: 2
} }
}, },
{ {
......
...@@ -175,7 +175,8 @@ export default { ...@@ -175,7 +175,8 @@ export default {
//position: relative; //position: relative;
.sort-box { .sort-box {
margin: 38px 0; margin: 38px 0;
.sort-title{
.sort-title {
margin-left: 12px; margin-left: 12px;
} }
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!