Commit 3ca30ba4 by 李伟康

紧急版本

1 parent 1f045200
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
<template> <template>
<div class="marketing order-manage"> <div class="marketing order-manage">
<div class="container"> <div class="container">
<template v-if="showTable">
<div class="sticky"> <div class="sticky">
<GLCombiForm <GLCombiForm
ref="showSearch" ref="showSearch"
...@@ -57,7 +58,6 @@ ...@@ -57,7 +58,6 @@
:disabled="selectList.length == 0" :disabled="selectList.length == 0"
>批量退款</el-button> >批量退款</el-button>
</div> </div>
<template v-if="showTable">
<GLTable <GLTable
ref="allOrderRef" ref="allOrderRef"
:getListApi="getListApi" :getListApi="getListApi"
...@@ -194,7 +194,12 @@ ...@@ -194,7 +194,12 @@
<template v-if="scope.scope.marketingStatus"> <template v-if="scope.scope.marketingStatus">
<span :class="['table-circle', 'm-r-8', [1, 2].includes(scope.scope.marketingStatus) ? 'back-green' : 'back-grey']"></span> <span :class="['table-circle', 'm-r-8', [1, 2].includes(scope.scope.marketingStatus) ? 'back-green' : 'back-grey']"></span>
</template> </template>
<span>{{ baseData.marketingStatusList.map(item => item.confId).includes(scope.scope.marketingStatus + '') ? baseData.marketingStatusList.find(item => item.confId == scope.scope.marketingStatus).confName : '-' }}</span> <span>{{ scope.scope.marketingStatus ?{
1:'已完结',
2:'已完结',
3:'未完结',
4:'已取消'
}[scope.scope.marketingStatus]: '-' }}</span>
</div> </div>
<div <div
class="table-btns" class="table-btns"
...@@ -208,8 +213,8 @@ ...@@ -208,8 +213,8 @@
></GLTableButton> ></GLTableButton>
</div> </div>
</GLTable> </GLTable>
</template>
</div> </div>
</template>
<!-- 表格区域 - 全部订单/售后订单 - end --> <!-- 表格区域 - 全部订单/售后订单 - end -->
</div> </div>
<!-- 快递信息 --> <!-- 快递信息 -->
...@@ -580,246 +585,7 @@ export default { ...@@ -580,246 +585,7 @@ export default {
refundTotal: '' refundTotal: ''
}, },
// 搜索 // 搜索
searchFormData: [ searchFormData: [],
{
label: '订单编号',
name: 'orderCode',
type: 'input'
},
{
label: '订单状态',
name: 'orderStatuses',
type: 'select',
multiple: true,
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'searchOrderStatusList',
changeAttr: (value, targetItem) => {
var isAdd = value.length > this.oldVal.orderStatuses.length
var targetVal = value[value.length - 1]
var formIdx = this.searchFormData.findIndex(item => item.label == '订单状态')
if (!isAdd) {
for (var i = 0; i < this.oldVal.orderStatuses.length; i++) {
if (!value.includes(this.oldVal.orderStatuses[i])) {
targetVal = this.oldVal.orderStatuses[i]
break
}
}
}
!targetVal && (this.searchForm.orderStatuses = isAdd ? this.searchFormData[formIdx].optionList.map(item => item.confId) : [])
if (targetVal) {
var idx = value.findIndex(item => item == '')
if (idx != -1 && this.searchForm.orderStatuses.length < this.searchFormData[formIdx].optionList.length) {
this.searchForm.orderStatuses.splice(idx, 1)
} else if (idx == -1 && this.searchForm.orderStatuses.length == this.searchFormData[formIdx].optionList.length - 1) {
this.searchForm.orderStatuses.push('')
}
}
this.oldVal.orderStatuses = this.$common.utils.deepClone(this.searchForm.orderStatuses)
}
},
{
label: '售后状态',
name: 'afterSaleStatuses',
type: 'select',
labelWidth: 72,
multiple: true,
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'searchAfterSaleStatusList',
changeAttr: (value, targetItem) => {
var isAdd = value.length > this.oldVal.afterSaleStatuses.length
var targetVal = value[value.length - 1]
var formIdx = this.searchFormData.findIndex(item => item.label == '售后状态')
if (!isAdd) {
for (var i = 0; i < this.oldVal.afterSaleStatuses.length; i++) {
if (!value.includes(this.oldVal.afterSaleStatuses[i])) {
targetVal = this.oldVal.afterSaleStatuses[i]
break
}
}
}
!targetVal && (this.searchForm.afterSaleStatuses = isAdd ? this.searchFormData[formIdx].optionList.map(item => item.confId) : [])
if (targetVal) {
var idx = value.findIndex(item => item == '')
if (idx != -1 && this.searchForm.afterSaleStatuses.length < this.searchFormData[formIdx].optionList.length) {
this.searchForm.afterSaleStatuses.splice(idx, 1)
} else if (idx == -1 && this.searchForm.afterSaleStatuses.length == this.searchFormData[formIdx].optionList.length - 1) {
this.searchForm.afterSaleStatuses.push('')
}
}
this.oldVal.afterSaleStatuses = this.$common.utils.deepClone(this.searchForm.afterSaleStatuses)
}
},
{
label: '门店',
name: 'merchantNames',
type: 'select',
labelWidth: 56,
multiple: true,
attrs: {
multipleLimit: 10,
},
noFilter: false,
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
},
{
label: '客户姓名',
name: 'customerName',
type: 'input'
},
{
label: '订单日期',
name: 'createDate',
type: 'datePicker',
labelWidth: 72,
isClear: true,
pickerOptions: 'beforeRangePickerOptions'
},
// {
// label: '订单类型',
// name: 'orderSource',
// type: 'select',
// optionList: [],
// optionId: 'confId',
// optionLabel: 'confName',
// optionsName: 'orderSourceList'
// },
{
label: '结算方式',
name: 'deliveryType',
type: 'select',
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'deliveryTypeList'
},
{
label: '商户订单号',
name: 'outTradeNo',
type: 'input',
maxlength: 50
},
{
label: '车架号',
name: 'vin',
labelWidth: 56,
type: 'input',
maxlength: 50
},
{
label: '推荐人',
name: 'shareStaffName',
labelWidth: 56,
type: 'input',
maxlength: 100
},
{
label: '推荐人类型',
name: 'shareStaffSource',
type: 'select',
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'shareStaffSourceList'
},
{
label: '活动名称',
name: 'activityNames',
labelWidth: 56,
type: 'select',
multiple: true,
attrs: {
multipleLimit: 10,
},
noFilter: false,
optionList: [],
optionId: 'confId',
optionLabel: 'confName'
},
{
label: '商品名称',
name: 'goodsName',
labelWidth: 56,
type: 'input',
maxlength: 100
},
{
label: '手机号',
name: 'customerPhone',
labelWidth: 56,
type: 'input',
maxlength: 11
},
{
label: '推荐人手机号',
name: 'shareStaffPhone',
labelWidth: 56,
type: 'input',
maxlength: 11
},
{
label: '测试单',
name: 'orderType',
type: 'select',
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'testSheetTypeList'
},
{
label: '退款类型',
name: 'afterSaleType',
type: 'select',
optionList: [
{
confId: null,
confName: '全部'
},
{
confId: '2',
confName: '退定金'
},
{
confId: '1',
confName: '退订单'
}
],
optionId: 'confId',
optionLabel: 'confName',
},
{
label: '线下订单',
name: 'isOffline',
type: 'select',
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'isOffSheetTypeList'
},
{
label: '业务场景',
name: 'businessType',
type: 'select',
optionList: [],
optionId: 'optionId',
optionLabel: 'optionLabel',
optionsName: 'businessTypeList'
},
{
label: '营销状态',
name: 'marketingStatus',
type: 'select',
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'marketingStatusList'
}
],
// 快递信息 // 快递信息
isExpressVisible: false, isExpressVisible: false,
writeOffApprovalVisible: false, writeOffApprovalVisible: false,
...@@ -1076,8 +842,7 @@ export default { ...@@ -1076,8 +842,7 @@ export default {
], ],
businessTypeList: utils.deepClone(businessType), businessTypeList: utils.deepClone(businessType),
marketingStatusList: [ marketingStatusList: [
{ confId: '1', confName: '已完结(自动)' }, { confId: '1', confName: '已完结' },
{ confId: '2', confName: '已完结(手动)' },
{ confId: '3', confName: '未完结' }, { confId: '3', confName: '未完结' },
{ confId: '4', confName: '已取消' } { confId: '4', confName: '已取消' }
] ]
...@@ -1138,7 +903,6 @@ export default { ...@@ -1138,7 +903,6 @@ export default {
this.getCrowdfundingOrderConfig() this.getCrowdfundingOrderConfig()
this.getCrowdfundingParams() this.getCrowdfundingParams()
// this.getCount() // this.getCount()
this.getOptionsList('searchFormData')
}, },
methods: { methods: {
...@@ -1340,23 +1104,263 @@ export default { ...@@ -1340,23 +1104,263 @@ export default {
return cellValue.outTradeNo || '-' return cellValue.outTradeNo || '-'
} }
} }
],
searchFormData = [
{
label: '订单编号',
name: 'orderCode',
type: 'input'
},
{
label: '订单状态',
name: 'orderStatuses',
type: 'select',
multiple: true,
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'searchOrderStatusList',
changeAttr: (value, targetItem) => {
var isAdd = value.length > this.oldVal.orderStatuses.length
var targetVal = value[value.length - 1]
var formIdx = this.searchFormData.findIndex(item => item.label == '订单状态')
if (!isAdd) {
for (var i = 0; i < this.oldVal.orderStatuses.length; i++) {
if (!value.includes(this.oldVal.orderStatuses[i])) {
targetVal = this.oldVal.orderStatuses[i]
break
}
}
}
!targetVal && (this.searchForm.orderStatuses = isAdd ? this.searchFormData[formIdx].optionList.map(item => item.confId) : [])
if (targetVal) {
var idx = value.findIndex(item => item == '')
if (idx != -1 && this.searchForm.orderStatuses.length < this.searchFormData[formIdx].optionList.length) {
this.searchForm.orderStatuses.splice(idx, 1)
} else if (idx == -1 && this.searchForm.orderStatuses.length == this.searchFormData[formIdx].optionList.length - 1) {
this.searchForm.orderStatuses.push('')
}
}
this.oldVal.orderStatuses = this.$common.utils.deepClone(this.searchForm.orderStatuses)
}
},
{
label: '售后状态',
name: 'afterSaleStatuses',
type: 'select',
labelWidth: 72,
multiple: true,
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'searchAfterSaleStatusList',
changeAttr: (value, targetItem) => {
var isAdd = value.length > this.oldVal.afterSaleStatuses.length
var targetVal = value[value.length - 1]
var formIdx = this.searchFormData.findIndex(item => item.label == '售后状态')
if (!isAdd) {
for (var i = 0; i < this.oldVal.afterSaleStatuses.length; i++) {
if (!value.includes(this.oldVal.afterSaleStatuses[i])) {
targetVal = this.oldVal.afterSaleStatuses[i]
break
}
}
}
!targetVal && (this.searchForm.afterSaleStatuses = isAdd ? this.searchFormData[formIdx].optionList.map(item => item.confId) : [])
if (targetVal) {
var idx = value.findIndex(item => item == '')
if (idx != -1 && this.searchForm.afterSaleStatuses.length < this.searchFormData[formIdx].optionList.length) {
this.searchForm.afterSaleStatuses.splice(idx, 1)
} else if (idx == -1 && this.searchForm.afterSaleStatuses.length == this.searchFormData[formIdx].optionList.length - 1) {
this.searchForm.afterSaleStatuses.push('')
}
}
this.oldVal.afterSaleStatuses = this.$common.utils.deepClone(this.searchForm.afterSaleStatuses)
}
},
{
label: '门店',
name: 'merchantNames',
type: 'select',
labelWidth: 56,
multiple: true,
attrs: {
multipleLimit: 10,
},
noFilter: false,
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
},
{
label: '客户姓名',
name: 'customerName',
type: 'input'
},
{
label: '订单日期',
name: 'createDate',
type: 'datePicker',
labelWidth: 72,
isClear: true,
pickerOptions: 'beforeRangePickerOptions'
},
{
label: '结算方式',
name: 'deliveryType',
type: 'select',
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'deliveryTypeList'
},
{
label: '商户订单号',
name: 'outTradeNo',
type: 'input',
maxlength: 50
},
{
label: '车架号',
name: 'vin',
labelWidth: 56,
type: 'input',
maxlength: 50
},
{
label: '推荐人',
name: 'shareStaffName',
labelWidth: 56,
type: 'input',
maxlength: 100
},
{
label: '推荐人类型',
name: 'shareStaffSource',
type: 'select',
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'shareStaffSourceList'
},
{
label: '活动名称',
name: 'activityNames',
labelWidth: 56,
type: 'select',
multiple: true,
attrs: {
multipleLimit: 10,
},
noFilter: false,
optionList: [],
optionId: 'confId',
optionLabel: 'confName'
},
{
label: '商品名称',
name: 'goodsName',
labelWidth: 56,
type: 'input',
maxlength: 100
},
{
label: '手机号',
name: 'customerPhone',
labelWidth: 56,
type: 'input',
maxlength: 11
},
{
label: '推荐人手机号',
name: 'shareStaffPhone',
labelWidth: 56,
type: 'input',
maxlength: 11
},
{
label: '测试单',
name: 'orderType',
type: 'select',
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'testSheetTypeList'
},
{
label: '退款类型',
name: 'afterSaleType',
type: 'select',
optionList: [
{
confId: null,
confName: '全部'
},
{
confId: '2',
confName: '退定金'
},
{
confId: '1',
confName: '退订单'
}
],
optionId: 'confId',
optionLabel: 'confName',
},
{
label: '线下订单',
name: 'isOffline',
type: 'select',
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'isOffSheetTypeList'
},
{
label: '业务场景',
name: 'businessType',
type: 'select',
optionList: [],
optionId: 'optionId',
optionLabel: 'optionLabel',
optionsName: 'businessTypeList'
},
{
label: '营销状态',
name: 'marketingStatus',
type: 'select',
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'marketingStatusList'
}
] ]
try { try {
const res = await this.$apis.common.getCrowdfundingOrderConfig(), const res = await this.$apis.common.getCrowdfundingOrderConfig(),
filterList = ['customerPhone', 'otherInformation', 'shareStaffName', 'assignName', 'shareStaffPhone', 'verificationDate', 'vinNo', 'afterSaleStatus'] filterTableList = ['customerPhone', 'otherInformation', 'shareStaffName', 'assignName', 'shareStaffPhone', 'verificationDate', 'vinNo', 'afterSaleStatus'],
filterFormList = ['afterSaleStatuses', 'vin', 'shareStaffName', 'shareStaffSource', 'customerPhone', 'shareStaffPhone']
if (res == 1) { if (res == 1) {
for (let i = 0; i < tableColumns.length; i++) { for (let i = 0; i < tableColumns.length; i++) {
if (filterList.includes(tableColumns[i].prop)) { if (filterTableList.includes(tableColumns[i].prop)) {
tableColumns.splice(i, 1) tableColumns.splice(i, 1)
i-- i--
} }
} }
for (let i = 0; i < searchFormData.length; i++) {
if (filterFormList.includes(searchFormData[i].name)) {
searchFormData.splice(i, 1)
i--
}
}
} }
} catch (error) { } catch (error) {
console.log(error) console.log(error)
} }
this.tableParams.tableColumns = tableColumns this.tableParams.tableColumns = tableColumns
this.searchFormData = searchFormData
this.showTable = true this.showTable = true
this.getOptionsList('searchFormData')
}, },
getParams () { getParams () {
var params = JSON.parse(JSON.stringify(this.searchForm)) var params = JSON.parse(JSON.stringify(this.searchForm))
......
...@@ -4,78 +4,116 @@ ...@@ -4,78 +4,116 @@
<div class="edit-box"> <div class="edit-box">
<div class="container m-b-20"> <div class="container m-b-20">
<p class="edit-title">订单信息</p> <p class="edit-title">订单信息</p>
<el-form label-width="100px" <el-form
:inline="true"> label-width="100px"
<el-row v-for="(item, index) in detailFormDataRow" :inline="true"
:key="index"> >
<el-form-item v-for="(subItem, subIndex) in item.rowList" <el-row
v-for="(item, index) in detailFormDataRow"
:key="index"
>
<el-form-item
v-for="(subItem, subIndex) in item.rowList"
:key="subIndex" :key="subIndex"
:label="subItem.label" :label="subItem.label"
class="row-item"> class="row-item"
<span class="detail-txt ellipsis-1" >
:title="detailForm[subItem.name]">{{ detailForm[subItem.name] ? detailForm[subItem.name] + (subItem.suffix || '') : '-' }}</span> <span
class="detail-txt ellipsis-1"
:title="detailForm[subItem.name]"
>{{ detailForm[subItem.name] ? detailForm[subItem.name] + (subItem.suffix || '') : '-' }}</span>
</el-form-item> </el-form-item>
</el-row> </el-row>
<template v-if="detailForm.formDescribe">
<el-form-item label="其他信息">{{ detailForm.formDescribe }}</el-form-item> <el-form-item label="其他信息">{{ detailForm.formDescribe }}</el-form-item>
</template>
</el-form> </el-form>
</div> </div>
<div :class="['container', orderRefund ? 'm-b-20' : 'edit-container']"> <div :class="['container', orderRefund ? 'm-b-20' : 'edit-container']">
<p class="edit-title">发货信息</p> <p class="edit-title">发货信息</p>
<el-form label-width="100px" <el-form
:inline="true"> label-width="100px"
:inline="true"
>
<el-form-item label="物流信息"> <el-form-item label="物流信息">
<span>{{ detailForm.deliveryCompany }}&nbsp;&nbsp;&nbsp;{{ detailForm.deliveryNumber }}</span> <span>{{ detailForm.deliveryCompany }}&nbsp;&nbsp;&nbsp;{{ detailForm.deliveryNumber }}</span>
</el-form-item> </el-form-item>
</el-form> </el-form>
<div v-if="orderGoods.length" <div
class="p-l-40"> v-if="orderGoods.length"
class="p-l-40"
>
<table class="show-table"> <table class="show-table">
<tbody> <tbody>
<tr v-for="(item, index) in orderGoods" <tr
v-for="(item, index) in orderGoods"
:key="index" :key="index"
style="height: 70px;"> style="height: 70px;"
<td><img :src="item.goodsImage" >
class="img-60" /></td> <td><img
:src="item.goodsImage"
class="img-60"
/></td>
<td>{{ item.goodsName }}</td> <td>{{ item.goodsName }}</td>
<td>{{ item.specificationData }}</td> <td>{{ item.specificationData }}</td>
<td>{{ item.activityPrice ? item.activityPrice : item.retailPrice }}元 * <td>{{ item.activityPrice ? item.activityPrice : item.retailPrice }}元 *
{{ item.goodsNumber }}</td> {{ item.goodsNumber }}</td>
</tr> </tr>
<tr v-if="detailForm.subOrderCoupon" <tr
style="height: 40px;"> v-if="detailForm.subOrderCoupon"
<td style="text-align: left;" style="height: 40px;"
colspan="3">优惠券</td> >
<td
style="text-align: left;"
colspan="3"
>优惠券</td>
<td>{{ detailForm.subOrderCoupon.discountAmount }}元</td> <td>{{ detailForm.subOrderCoupon.discountAmount }}元</td>
</tr> </tr>
</tbody> </tbody>
</table> </table>
</div> </div>
</div> </div>
<div class="container edit-container" <div
v-if="orderRefund"> class="container edit-container"
v-if="orderRefund"
>
<p class="edit-title">售后信息</p> <p class="edit-title">售后信息</p>
<el-form label-width="100px" <el-form
:inline="true"> label-width="100px"
<el-row v-for="(item, index) in afterInfoDataRow" :inline="true"
:key="index"> >
<el-form-item v-for="(subItem, subIndex) in item.rowList" <el-row
v-for="(item, index) in afterInfoDataRow"
:key="index"
>
<el-form-item
v-for="(subItem, subIndex) in item.rowList"
:key="subIndex" :key="subIndex"
:label="subItem.label"> :label="subItem.label"
<span class="detail-txt ellipsis-1" >
:title="orderRefund[subItem.name]">{{ orderRefund[subItem.name] || '-' }}</span> <span
class="detail-txt ellipsis-1"
:title="orderRefund[subItem.name]"
>{{ orderRefund[subItem.name] || '-' }}</span>
</el-form-item> </el-form-item>
</el-row> </el-row>
</el-form> </el-form>
<div class="form-img"> <div class="form-img">
<el-form label-width="100px" <el-form
:inline="true"> label-width="100px"
:inline="true"
>
<el-form-item label="售后凭证"> <el-form-item label="售后凭证">
<div class="flex"> <div class="flex">
<span v-for="(item, index) in orderRefund.imgUrls" <span
:key="index"> v-for="(item, index) in orderRefund.imgUrls"
<el-image class="img-60 comment-img" :key="index"
>
<el-image
class="img-60 comment-img"
:src="item" :src="item"
:preview-src-list="[item]"></el-image> :preview-src-list="[item]"
></el-image>
</span> </span>
</div> </div>
</el-form-item> </el-form-item>
...@@ -84,8 +122,10 @@ ...@@ -84,8 +122,10 @@
</div> </div>
</div> </div>
<GLFooter> <GLFooter>
<el-button @click="handleCancel" <el-button
size="medium">取消</el-button> @click="handleCancel"
size="medium"
>取消</el-button>
</GLFooter> </GLFooter>
</div> </div>
</template> </template>
...@@ -95,7 +135,7 @@ import * as dayjs from 'dayjs' ...@@ -95,7 +135,7 @@ 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: '查看订单',
...@@ -108,7 +148,70 @@ export default { ...@@ -108,7 +148,70 @@ export default {
orderGoods: [], orderGoods: [],
// 订单信息 // 订单信息
detailFormDataRow: [], detailFormDataRow: [],
detailFormData: [ detailFormData: [],
// 售后信息
afterInfoDataRow: [],
afterInfoData: [
{
label: '售后类型',
name: 'refundTypeName'
},
{
label: '申请金额',
name: 'refundPrice'
},
{
label: '申请时间',
name: 'createdDateStr'
},
{
label: '申请描述',
name: 'remark'
},
{
label: '快递公司',
name: 'deliveryCompany'
},
{
label: '快递单号',
name: 'deliveryNumber'
}
// {
// label: '售后凭证',
// name: ''
// }
],
// 基本数据
baseData: {
orderStatusList: orderManageStatusList,
orderSourceList: orderSourceList,
deliveryTypeList: deliveryTypeList,
refundTypeList: [
{ confId: '1', confName: '退款退货' },
{ confId: '2', confName: '退款不退货' },
{ confId: '3', confName: '众筹订单退款' }
],
shareStaffTypeList: [
{ confId: '1', confName: '个微' },
{ confId: '2', confName: '企微' }
]
},
hideStatus: false
}
},
created () {
},
mounted () {
this.getCrowdfundingOrderConfig()
},
methods: {
async getCrowdfundingOrderConfig () {
let detailFormData = [
{ {
label: '订单编号', label: '订单编号',
name: 'orderCode' name: 'orderCode'
...@@ -182,69 +285,26 @@ export default { ...@@ -182,69 +285,26 @@ export default {
label: '商品名称', label: '商品名称',
name: 'goodsName' name: 'goodsName'
} }
],
// 售后信息
afterInfoDataRow: [],
afterInfoData: [
{
label: '售后类型',
name: 'refundTypeName'
},
{
label: '申请金额',
name: 'refundPrice'
},
{
label: '申请时间',
name: 'createdDateStr'
},
{
label: '申请描述',
name: 'remark'
},
{
label: '快递公司',
name: 'deliveryCompany'
},
{
label: '快递单号',
name: 'deliveryNumber'
}
// {
// label: '售后凭证',
// name: ''
// }
],
// 基本数据
baseData: {
orderStatusList: orderManageStatusList,
orderSourceList: orderSourceList,
deliveryTypeList: deliveryTypeList,
refundTypeList: [
{ confId: '1', confName: '退款退货' },
{ confId: '2', confName: '退款不退货' },
{ confId: '3', confName: '众筹订单退款' }
],
shareStaffTypeList: [
{ confId: '1', confName: '个微' },
{ confId: '2', confName: '企微' }
] ]
const res = await this.$apis.common.getCrowdfundingOrderConfig()
let hideStatus = res == 1
if (hideStatus) {
const filterFormList = ['customerPhone', 'shareStaffName', 'shareStaffTypeName', 'vin', 'shipAddress']
for (let i = 0; i < detailFormData.length; i++) {
if (filterFormList.includes(detailFormData[i].name)) {
detailFormData.splice(i, 1)
i--
} }
} }
}, }
this.hideStatus = hideStatus
created() { this.detailFormData = detailFormData
this.formToRow('afterInfoData')
},
mounted() {
this.setMinHeight('.edit-box') this.setMinHeight('.edit-box')
this.routeInfo = this.$route.query this.routeInfo = this.$route.query
this.getInfo() this.getInfo()
this.formToRow('afterInfoData')
}, },
formToRow (formName, numOfRow = 3) {
methods: {
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++) {
...@@ -259,7 +319,7 @@ export default { ...@@ -259,7 +319,7 @@ 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
...@@ -288,6 +348,7 @@ export default { ...@@ -288,6 +348,7 @@ export default {
this.detailFormData.splice(takeFeeIdx, 1) this.detailFormData.splice(takeFeeIdx, 1)
} }
// 其他信息 // 其他信息
if (!this.hideStatus) {
var formDescribeObj = { var formDescribeObj = {
label: '其他信息', label: '其他信息',
name: 'formDescribe', name: 'formDescribe',
...@@ -304,12 +365,13 @@ export default { ...@@ -304,12 +365,13 @@ export default {
this.detailForm[formDescribeObj.name] += label + ':' + value + ' ' this.detailForm[formDescribeObj.name] += label + ':' + value + ' '
} }
}) })
}
// 商品名称 // 商品名称
this.detailForm.goodsName = this.detailForm.orderGoods.length ? this.detailForm.orderGoods.map(item => item.goodsName).join(',') : '-' this.detailForm.goodsName = this.detailForm.orderGoods.length ? this.detailForm.orderGoods.map(item => item.goodsName).join(',') : '-'
this.formToRow('detailFormData') this.formToRow('detailFormData')
}) })
}, },
handleCancel() { handleCancel () {
this.$router.push({ this.$router.push({
path: '/orderManage/index' path: '/orderManage/index'
}) })
......
...@@ -2,41 +2,108 @@ ...@@ -2,41 +2,108 @@
<template> <template>
<div class="marketing"> <div class="marketing">
<div class="m-b-20"> <div class="m-b-20">
<GLButton :size="size" class="default-blue-btn el-icon-plus" type="default" @click="handleEdit('add')" fn="新增众筹" mode="el-button">新建众筹</GLButton> <GLButton
<el-button :size="size" type="default" class="default-blue-btn" @click="handleJump">订单管理</el-button> :size="size"
class="default-blue-btn el-icon-plus"
type="default"
@click="handleEdit('add')"
fn="新增众筹"
mode="el-button"
>新建众筹</GLButton>
<el-button
:size="size"
type="default"
class="default-blue-btn"
@click="handleJump"
>订单管理</el-button>
</div> </div>
<div class="container"> <div class="container">
<GLCombiForm ref="showSearch" :rowNumber="1" :formObj="searchForm" :formData="searchFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm> <GLCombiForm
ref="showSearch"
:rowNumber="1"
:formObj="searchForm"
:formData="searchFormData"
@handleOk="handleSearch"
@handleRest="handleReset"
></GLCombiForm>
<div class="flex m-b-10 w-100-percent"> <div class="flex m-b-10 w-100-percent">
<span class="table-title"></span> <span class="table-title"></span>
<el-button :size="size" class="default-blue-btn" type="default" @click="handleExport">导出</el-button> <el-button
:size="size"
class="default-blue-btn"
type="default"
@click="handleExport"
>导出</el-button>
</div> </div>
<!-- 表格区域 开始 --> <!-- 表格区域 开始 -->
<single-gltable ref="activity" :getListApi="getListApi" :noDataImg="url" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun"> <single-gltable
<div slot="activityImg" class="table-image" slot-scope="scope"> ref="activity"
<el-popover placement="top" width="160" trigger="hover" popper-class="table-popover-block"> :getListApi="getListApi"
<img class="table-popover-img" :src="scope.scope.activityImg" /> :noDataImg="url"
<img class="img-60 pointer" slot="reference" :src="scope.scope.activityImg" /> :searchForm="tableSearchForm"
:tableParams="tableParams"
:pageConf="pageConf"
:beforeSearchFn="beforeSearchFn"
@setTableFinishFun="setTableFinishFun"
>
<div
slot="activityImg"
class="table-image"
slot-scope="scope"
>
<el-popover
placement="top"
width="160"
trigger="hover"
popper-class="table-popover-block"
>
<img
class="table-popover-img"
:src="scope.scope.activityImg"
/>
<img
class="img-60 pointer"
slot="reference"
:src="scope.scope.activityImg"
/>
</el-popover> </el-popover>
</div> </div>
<div slot="linkText" slot-scope="scope"> <div
<template v-if="scope.scope.incrementFlag == 'Y'"> slot="linkText"
slot-scope="scope"
>
<template v-if="scope.scope.incrementFlag == 'Y' || hideStatus">
{{scope.scope[scope.prop] || 0 }} {{scope.scope[scope.prop] || 0 }}
</template> </template>
<template v-else> <template v-else>
<p class="cursor-pointer" @click="handleDetail(scope)">{{ scope.scope[scope.prop] || 0 }}</p> <p
class="cursor-pointer"
@click="handleDetail(scope)"
>{{ scope.scope[scope.prop] || 0 }}</p>
</template> </template>
</div> </div>
<div class="table-btns" slot="auth-button" slot-scope="scope"> <div
<GLTableButton :buttonList="tableButtonList" :buttonItem="scope.scope" :buttonNum="3"></GLTableButton> class="table-btns"
slot="auth-button"
slot-scope="scope"
>
<GLTableButton
:buttonList="tableButtonList"
:buttonItem="scope.scope"
:buttonNum="3"
></GLTableButton>
</div> </div>
</single-gltable> </single-gltable>
<!-- 表格区域 end --> <!-- 表格区域 end -->
</div> </div>
<!-- 众筹分享 --> <!-- 众筹分享 -->
<crowdFundingShare :isShareVisible="isShareVisible" :shareForm="shareForm" @handleShareClose="handleShareClose"></crowdFundingShare> <crowdFundingShare
:isShareVisible="isShareVisible"
:shareForm="shareForm"
@handleShareClose="handleShareClose"
></crowdFundingShare>
</div> </div>
</template> </template>
...@@ -48,7 +115,7 @@ import url from '@/assets/empty.png' ...@@ -48,7 +115,7 @@ import url from '@/assets/empty.png'
import { exportFn } from '@/common/constant' import { exportFn } from '@/common/constant'
export default { export default {
name: 'crowdFundList', name: 'crowdFundList',
data() { data () {
return { return {
size: 'small', size: 'small',
url: url, url: url,
...@@ -374,7 +441,8 @@ export default { ...@@ -374,7 +441,8 @@ export default {
confName: '已结束' confName: '已结束'
} }
] ]
} },
hideStatus: false
} }
}, },
...@@ -383,7 +451,8 @@ export default { ...@@ -383,7 +451,8 @@ export default {
singleGltable: GLTable singleGltable: GLTable
}, },
mounted() { mounted () {
this.getCrowdfundingOrderConfig()
this.getCrowdfundingParams() this.getCrowdfundingParams()
this.getOptionsList('searchFormData') this.getOptionsList('searchFormData')
...@@ -399,17 +468,21 @@ export default { ...@@ -399,17 +468,21 @@ export default {
}, },
methods: { methods: {
__getRoutes(ctx) { async getCrowdfundingOrderConfig () {
const res = await this.$apis.common.getCrowdfundingOrderConfig()
this.hideStatus = res == 1
},
__getRoutes (ctx) {
const { const {
$GLBUTTION_PERMISSIONS: { routes = [], routerBase } $GLBUTTION_PERMISSIONS: { routes = [], routerBase }
} = ctx } = ctx
return routes.find(route => location.pathname === `${routerBase}${route.path.split(':/')[0]}`) return routes.find(route => location.pathname === `${routerBase}${route.path.split(':/')[0]}`)
}, },
getParams() { getParams () {
var params = JSON.parse(JSON.stringify(this.searchForm)) var params = JSON.parse(JSON.stringify(this.searchForm))
return params return params
}, },
beforeSearchFn() { beforeSearchFn () {
return new Promise(resolve => { return new Promise(resolve => {
this.tableSearchForm = this.getParams() this.tableSearchForm = this.getParams()
// delete this.tableSearchForm.createDate // delete this.tableSearchForm.createDate
...@@ -417,13 +490,13 @@ export default { ...@@ -417,13 +490,13 @@ export default {
}) })
}, },
handleJump(path, row = {}) { handleJump (path, row = {}) {
this.$router.push({ this.$router.push({
path: '/orderManage/index' path: '/orderManage/index'
}) })
}, },
secondConfirm(title, txt, apiModule, apiName, apiParams, fn) { secondConfirm (title, txt, apiModule, apiName, apiParams, fn) {
this.$confirm(txt, title, { this.$confirm(txt, title, {
confirmButtonText: '确定', confirmButtonText: '确定',
cancelButtonText: '取消', cancelButtonText: '取消',
...@@ -449,16 +522,16 @@ export default { ...@@ -449,16 +522,16 @@ export default {
}, },
//开始 //开始
start(item) { start (item) {
this.startOrEndConfirm('开始', item) this.startOrEndConfirm('开始', item)
}, },
//结束 //结束
end(item) { end (item) {
this.startOrEndConfirm('结束', item) this.startOrEndConfirm('结束', item)
}, },
startOrEndConfirm(txt, row) { startOrEndConfirm (txt, row) {
var title = txt var title = txt
var params = {} var params = {}
params.id = row.id params.id = row.id
...@@ -471,21 +544,21 @@ export default { ...@@ -471,21 +544,21 @@ export default {
}, },
//置顶 //置顶
topping(row) { topping (row) {
var params = {} var params = {}
params.id = row.id params.id = row.id
this.secondConfirm('删除', '确定置顶此活动?', 'seckillActivity', 'topActivityApi', params) this.secondConfirm('删除', '确定置顶此活动?', 'seckillActivity', 'topActivityApi', params)
}, },
//删除 //删除
del(row) { del (row) {
var params = {} var params = {}
params.id = row.id params.id = row.id
this.secondConfirm('删除', '确定删除此活动?', 'seckillActivity', 'deleteActivityApi', params) this.secondConfirm('删除', '确定删除此活动?', 'seckillActivity', 'deleteActivityApi', params)
}, },
// 1-新增;2-编辑 // 1-新增;2-编辑
handleEdit(addOrEdit, row) { handleEdit (addOrEdit, row) {
var txtObj = { var txtObj = {
add: '新建', add: '新建',
edit: '编辑', edit: '编辑',
...@@ -504,11 +577,11 @@ export default { ...@@ -504,11 +577,11 @@ export default {
query: params query: params
}) })
}, },
test(option) { test (option) {
console.log(JSON.parse(JSON.stringify(option))) console.log(JSON.parse(JSON.stringify(option)))
}, },
// 明细 // 明细
handleDetail({ prop, scope }) { handleDetail ({ prop, scope }) {
let data = { let data = {
viewAmount: { viewAmount: {
type: 1, type: 1,
...@@ -534,25 +607,25 @@ export default { ...@@ -534,25 +607,25 @@ export default {
}) })
}, },
handleExport() { handleExport () {
var params = this.getParams() var params = this.getParams()
this.$apis.seckillActivity.exportCrowdfundApi(params).then(res => { this.$apis.seckillActivity.exportCrowdfundApi(params).then(res => {
exportFn(res) exportFn(res)
}) })
}, },
handleShare(row) { handleShare (row) {
this.$apis.seckillActivity.getCrowdSharedApi({ id: row.id }).then(res => { this.$apis.seckillActivity.getCrowdSharedApi({ id: row.id }).then(res => {
this.shareForm = res this.shareForm = res
this.handleShareClose() this.handleShareClose()
}) })
}, },
handleShareClose() { handleShareClose () {
this.isShareVisible = !this.isShareVisible this.isShareVisible = !this.isShareVisible
}, },
getOptionsList(formName, hasAll = true, refreshSigle) { getOptionsList (formName, hasAll = true, refreshSigle) {
if (refreshSigle) { if (refreshSigle) {
var item = this[formName].find(k => k.name == refreshSigle) var item = this[formName].find(k => k.name == refreshSigle)
var index = this[formName].findIndex(k => k.name == refreshSigle) var index = this[formName].findIndex(k => k.name == refreshSigle)
...@@ -578,11 +651,11 @@ export default { ...@@ -578,11 +651,11 @@ export default {
} }
}, },
handleSearch() { handleSearch () {
this.$refs.activity.refreshTable() this.$refs.activity.refreshTable()
}, },
handleReset() { handleReset () {
this.searchForm = { this.searchForm = {
activityNames: [], activityNames: [],
activityStatus: '', activityStatus: '',
...@@ -591,12 +664,12 @@ export default { ...@@ -591,12 +664,12 @@ export default {
this.handleSearch() this.handleSearch()
}, },
setTableFinishFun() { setTableFinishFun () {
//接收到的数据为空 //接收到的数据为空
this.$refs.activity.data.length ? (this.$refs.activity.tableHeightValues = '') : this.$refs.activity.setTableHeightFun() this.$refs.activity.data.length ? (this.$refs.activity.tableHeightValues = '') : this.$refs.activity.setTableHeightFun()
}, },
async getCrowdfundingParams() { async getCrowdfundingParams () {
/**参数类型 1:众筹活动名称(返回类型String),2:众筹活动门店 */ /**参数类型 1:众筹活动名称(返回类型String),2:众筹活动门店 */
const activity = await this.$apis.seckillActivity.getCrowdfundingParams({ const activity = await this.$apis.seckillActivity.getCrowdfundingParams({
parameterType: 1 parameterType: 1
......
...@@ -966,6 +966,10 @@ ...@@ -966,6 +966,10 @@
:disabled="isDisabled" :disabled="isDisabled"
:label="4" :label="4"
>门店收定金和尾款</el-radio> >门店收定金和尾款</el-radio>
<el-radio
:disabled="isDisabled"
:label="5"
>服务商收定金门店收尾款</el-radio>
</el-radio-group> </el-radio-group>
</div> </div>
</glsx-combi-form> </glsx-combi-form>
...@@ -1160,7 +1164,7 @@ export default { ...@@ -1160,7 +1164,7 @@ export default {
selectVehicleTypeFlag: 2, selectVehicleTypeFlag: 2,
selectPhoneNumberFlag: 2, selectPhoneNumberFlag: 2,
businessType: 2, //业务场景 businessType: 2, //业务场景
orderEndDays: 30, //订单完结时间天数 orderEndDays: 60, //订单完结时间天数
formDescribeCheck: ['selectCarNumberFlag', 'selectVehicleTypeFlag', 'selectPhoneNumberFlag'], formDescribeCheck: ['selectCarNumberFlag', 'selectVehicleTypeFlag', 'selectPhoneNumberFlag'],
activityServices: [], activityServices: [],
activityCommoditys: [], activityCommoditys: [],
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!