Commit 86f6b477 by 张立顺

20221210 版本第一轮bug修复

1 parent d9154261
...@@ -2,7 +2,8 @@ import { http, http_common, http2, http_merchant } from '@/main' ...@@ -2,7 +2,8 @@ import { http, http_common, http2, http_merchant } from '@/main'
const defaultPath = 'scrm.api.carlife.' const defaultPath = 'scrm.api.carlife.'
const getMerchantGoodsListApi = params => { const getMerchantGoodsListApi = params => {
params.method = 'scrm.api.shopmall.goods.page.curMerchant' // params.method = 'scrm.api.shopmall.goods.page.curMerchant'
params.method = 'scrm.api.shopmall.goods.page.allMerchant'
return http({ return http({
url: 'rop-scrm-shopmall/router', url: 'rop-scrm-shopmall/router',
method: 'GET', method: 'GET',
......
...@@ -133,7 +133,7 @@ const updateOrderType = params => { ...@@ -133,7 +133,7 @@ const updateOrderType = params => {
method: 'POST', method: 'POST',
data: params, data: params,
sign: true, sign: true,
returnAll: false returnAll: true
}) })
} }
......
...@@ -15,7 +15,7 @@ const getActivityPageApi = params => { ...@@ -15,7 +15,7 @@ const getActivityPageApi = params => {
//分页众筹活动 //分页众筹活动
const getCrowdfundListApi = params => { const getCrowdfundListApi = params => {
params.method = 'scrm.api.shopmall.crowdfunding.activity.page' params.method = 'scrm.api.shopmall.all.crowdfunding.activity.page'
return http({ return http({
url: 'rop-scrm-shopmall/router', url: 'rop-scrm-shopmall/router',
method: 'GET', method: 'GET',
...@@ -26,7 +26,7 @@ const getCrowdfundListApi = params => { ...@@ -26,7 +26,7 @@ const getCrowdfundListApi = params => {
// 众筹-导出 // 众筹-导出
const exportCrowdfundApi = params => { const exportCrowdfundApi = params => {
params.method = 'scrm.api.shopmall.crowdfunding.activity.export' params.method = 'scrm.api.shopmall.all.crowdfunding.activity.export'
return http({ return http({
url: 'rop-scrm-shopmall/router', url: 'rop-scrm-shopmall/router',
method: 'GET', method: 'GET',
......
...@@ -84,7 +84,8 @@ const orderManageStatusList = [ ...@@ -84,7 +84,8 @@ const orderManageStatusList = [
// { confId: '7', confName: '待核销' }, // { confId: '7', confName: '待核销' },
// { confId: '8', confName: '已核销' }, // { confId: '8', confName: '已核销' },
{ confId: '9', confName: '售后中' }, { confId: '9', confName: '售后中' },
{ confId: '10', confName: '售后完成' } { confId: '10', confName: '售后完成' },
{ confId: '11', confName: '待审批' }
] ]
const orderSourceList = [ const orderSourceList = [
...@@ -202,6 +203,21 @@ const stateList = [ ...@@ -202,6 +203,21 @@ const stateList = [
} }
] ]
const businessType = [
{
optionId: 1,
optionLabel: '1.2'
},
{
optionId: 2,
optionLabel: '1.3'
},
{
optionId: 3,
optionLabel: '2.0'
}
]
function getExplorer() { function getExplorer() {
var ua = navigator.userAgent.toLocaleLowerCase() var ua = navigator.userAgent.toLocaleLowerCase()
var browserType = null var browserType = null
...@@ -244,4 +260,4 @@ function setMinHeight(calssName = '.edit-container') { ...@@ -244,4 +260,4 @@ function setMinHeight(calssName = '.edit-container') {
document.querySelector(calssName).style.minHeight = minHeight document.querySelector(calssName).style.minHeight = minHeight
} }
export { limitPrice, aToExport, orderManageStatusList, orderSourceList, deliveryTypeList, statusList, serviceStatusList, memberTypeList, stateList, orderTypesList, orderStatusList, afterSaleStatusList, exportFn, setMinHeight, downLoadFile } export { limitPrice, aToExport, businessType, orderManageStatusList, orderSourceList, deliveryTypeList, statusList, serviceStatusList, memberTypeList, stateList, orderTypesList, orderStatusList, afterSaleStatusList, exportFn, setMinHeight, downLoadFile }
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
<div :class="['glsx-combi-form', isEdit ? 'gl-form-page' : '']"> <div :class="['glsx-combi-form', isEdit ? 'gl-form-page' : '']">
<el-form :ref="formRef" :inline="true" :model="formObj" :rules="formRules" size="small" class="glsx-combi-form-block"> <el-form :ref="formRef" :inline="true" :model="formObj" :rules="formRules" size="small" class="glsx-combi-form-block">
<template v-for="(item, index) in formData"> <template v-for="(item, index) in formData">
<el-form-item v-if="!item.isHide" :key="index" :id="item.name" :labelWidth="isEdit ? '154px' : labelWidth" :class="[{ 'no-label': !item.label, isBlock: isBlock }, { textBox: item.type == 'textBox' }]" :style="{ 'margin-bottom': isEdit ? '24px' : '', 'margin-right': isEdit ? '0px' : '30px', ...item.style }" :label="item.label" :prop="item.name"> <el-form-item v-if="!item.isHide" :key="index" :id="item.name" :labelWidth="isEdit ? '154px' : labelWidth" :class="[{ 'no-label': !item.label, isBlock: isBlock },{'textBox':item.type=='textBox'}]" :style="{ 'margin-bottom': isEdit ? '24px' : '', 'margin-right': isEdit ? '0px' : '30px', ...item.style }" :label="item.label" :prop="item.name">
<span v-if="!item.isHide && item.tips" class="tips-block" slot="label"> <span v-if="!item.isHide && item.tips" class="tips-block" slot="label">
<span class="tips-label">{{ item.label }}</span> <span class="tips-label">{{ item.label }}</span>
<el-popover placement="top" width="200" trigger="hover" :content="item.tips"> <el-popover placement="top" width="200" trigger="hover" :content="item.tips">
...@@ -157,17 +157,13 @@ export default { ...@@ -157,17 +157,13 @@ export default {
// 默认是四个字符长度 // 默认是四个字符长度
default: '154px' default: '154px'
}, },
// labelPaddingRight: {
// type: Number,
// default: 15
// },
formData: { formData: {
type: Array, type: Array,
default: () => [] default: () => []
}, },
formObj: { formObj: {
type: Object, type: Object,
default: () => {} default: () => { }
}, },
hasTitle: { hasTitle: {
type: Boolean, type: Boolean,
...@@ -175,12 +171,12 @@ export default { ...@@ -175,12 +171,12 @@ export default {
}, },
formRules: { formRules: {
type: Object, type: Object,
default: () => {} default: () => { }
}, },
// 搜索+输入框/搜索组合组件,搜索栏绑值 // 搜索+输入框/搜索组合组件,搜索栏绑值
searchSelectObj: { searchSelectObj: {
type: Object, type: Object,
default: () => {} default: () => { }
} }
}, },
...@@ -190,7 +186,7 @@ export default { ...@@ -190,7 +186,7 @@ export default {
mapView mapView
}, },
mounted() {}, mounted() { },
methods: { methods: {
// 选择框-添加其他属性 // 选择框-添加其他属性
...@@ -449,6 +445,7 @@ export default { ...@@ -449,6 +445,7 @@ export default {
background-color: #f7f7f7; background-color: #f7f7f7;
border: 1px dotted #d9d9d9; border: 1px dotted #d9d9d9;
cursor: pointer; cursor: pointer;
margin-top: 10px;
} }
.glsx-combi-form .activity-Input { .glsx-combi-form .activity-Input {
......
...@@ -77,7 +77,7 @@ export default { ...@@ -77,7 +77,7 @@ export default {
map.addControl(new AMap.ToolBar()) map.addControl(new AMap.ToolBar())
this.geocoder = new AMap.Geocoder() this.geocoder = new AMap.Geocoder()
map.setDefaultCursor('pointer') map.setDefaultCursor('pointer')
AMap.plugin(['AMap.PlaceSearch'], function() { AMap.plugin(['AMap.PlaceSearch'], function () {
//构造地点查询类 //构造地点查询类
placeSearch = new AMap.PlaceSearch({ placeSearch = new AMap.PlaceSearch({
pageSize: 8, // 单页显示结果条数 pageSize: 8, // 单页显示结果条数
...@@ -99,7 +99,7 @@ export default { ...@@ -99,7 +99,7 @@ export default {
return true return true
} }
let _this = this let _this = this
placeSearch.search(query, function(status, result) { placeSearch.search(query, function (status, result) {
if (status === 'complete' && result.poiList.pois.length) { if (status === 'complete' && result.poiList.pois.length) {
_this.adrList = result.poiList.pois _this.adrList = result.poiList.pois
} }
...@@ -206,4 +206,4 @@ export default { ...@@ -206,4 +206,4 @@ export default {
margin-right: 6px; margin-right: 6px;
} }
} }
</style> </style>
\ No newline at end of file \ No newline at end of file
...@@ -19,8 +19,8 @@ export const fetchConfig = function(isEnv = true) { ...@@ -19,8 +19,8 @@ export const fetchConfig = function(isEnv = true) {
// return Promise.resolve(cfg) // return Promise.resolve(cfg)
// } // }
//return window.fetch('https://', {}).then(res => res.json()) //return window.fetch('https://', {}).then(res => res.json())
// return new Http().get('https://oss-config.dev.glsx.com.cn/mock/6345096902322627d6b83e83/battles/config') return new Http().get('https://oss-config.dev.glsx.com.cn/mock/6345096902322627d6b83e83/battles/config')
return new Http().get('https://oss-config.glsx.com.cn/mock/635fc7a254298ae78614407a/battles/config') // return new Http().get('https://oss-config.glsx.com.cn/mock/635fc7a254298ae78614407a/battles/config')
} }
export const config = { export const config = {
install(vue, cfg) { install(vue, cfg) {
......
...@@ -11,7 +11,7 @@ let router = null ...@@ -11,7 +11,7 @@ let router = null
let instance = null let instance = null
Vue.use(ElementUI) Vue.use(ElementUI)
Vue.use(GLTable) Vue.use(GLTable)
export async function bootstrap({ history, common, messenger, globalState }) { export async function bootstrap({ history, common, messenger, globalState, routerBase }) {
const { response, request, sign, secret, sign_common, request_common, merchantId } = await fetchConfig() const { response, request, sign, secret, sign_common, request_common, merchantId } = await fetchConfig()
Vue.prototype.$history = history Vue.prototype.$history = history
Vue.prototype.$merchantId = merchantId Vue.prototype.$merchantId = merchantId
...@@ -28,8 +28,8 @@ export async function bootstrap({ history, common, messenger, globalState }) { ...@@ -28,8 +28,8 @@ export async function bootstrap({ history, common, messenger, globalState }) {
const routesData = common.utils.deepClone(globalState.routers) const routesData = common.utils.deepClone(globalState.routers)
routes = getRoutes(routesData) routes = getRoutes(routesData)
subscribe({ messenger }) subscribe({ messenger })
// Vue.use(GLButton, { routes, routerBase }) Vue.use(GLButton, { routes, routerBase })
Vue.use(GLButton, { permissions: globalState.permissions || ['1-1-1-1', '2-1-1-1', '3-1-1-1'] }) // Vue.use(GLButton, { permissions: globalState.permissions || ['1-1-1-1', '2-1-1-1', '3-1-1-1'] })
} }
export async function mount(props) { export async function mount(props) {
const insts = render(props.routerBase, routes) const insts = render(props.routerBase, routes)
......
...@@ -167,7 +167,8 @@ export default { ...@@ -167,7 +167,8 @@ export default {
}, },
handleClose() { handleClose() {
this.$emit('handleStoreClose') // console.log('handleStoreClose')
this.$emit('handleStaffClose')
}, },
handleConfirm() { handleConfirm() {
if (!this.staffUuid) if (!this.staffUuid)
......
...@@ -109,16 +109,32 @@ ...@@ -109,16 +109,32 @@
<div slot="assignName" <div slot="assignName"
slot-scope="scope"> slot-scope="scope">
<div> <div>
<img class="img-36 pointer img-circle" <template v-if="scope.scope.assignStaffName">
:src="scope.scope.assignStaffImageUrl || scope.scope.shareStaffImageUrl" /> <img class="img-36 pointer img-circle"
<span>{{ scope.scope.assignStaffName || scope.scope.shareStaffName }}</span> v-if="scope.scope.assignStaffImageUrl"
:src="scope.scope.assignStaffImageUrl" />
<span class="m-l-10">
<span>{{ scope.scope.assignStaffName }}</span>
</span>
</template>
<template v-else-if="scope.scope.shareStaffName">
<img class="img-36 pointer img-circle"
v-if="scope.scope.shareStaffImageUrl"
:src="scope.scope.shareStaffImageUrl" />
<span class="m-l-10">
<span>{{ scope.scope.shareStaffName }}</span>
</span>
</template>
<template v-else>
<span>{{ scope.scope.assignStaffName || scope.scope.shareStaffName || '-' }}</span>
</template>
<span @click="handlerAssign(scope.scope)" <span @click="handlerAssign(scope.scope)"
class="assignLabel">指派</span> class="assignLabel">指派</span>
</div> </div>
</div> </div>
<div slot="orderType" <div slot="orderType"
slot-scope="scope"> slot-scope="scope">
<el-switch v-model="scope.scope.orderType" <el-switch :value="scope.scope.orderType == 1 ? true : false"
class="switchStyle" class="switchStyle"
@change="changeOrderType(scope.scope)" @change="changeOrderType(scope.scope)"
active-text="是" active-text="是"
...@@ -287,8 +303,9 @@ ...@@ -287,8 +303,9 @@
<script> <script>
import * as dayjs from 'dayjs' import * as dayjs from 'dayjs'
import url from '@/assets/empty.png' import url from '@/assets/empty.png'
import { utils } from 'glsx-common'
import selectStaff from './components/selectStaff.vue' import selectStaff from './components/selectStaff.vue'
import { orderManageStatusList, afterSaleStatusList, orderSourceList, deliveryTypeList, exportFn } from '@/common/constant' import { businessType, orderManageStatusList, afterSaleStatusList, orderSourceList, deliveryTypeList, exportFn } from '@/common/constant'
export default { export default {
name: 'orderManage', name: 'orderManage',
components: { components: {
...@@ -507,6 +524,15 @@ export default { ...@@ -507,6 +524,15 @@ export default {
optionId: 'confId', optionId: 'confId',
optionLabel: 'confName', optionLabel: 'confName',
optionsName: 'testSheetTypeList' optionsName: 'testSheetTypeList'
},
{
label: '业务场景',
name: 'businessType',
type: 'select',
optionList: [],
optionId: 'optionId',
optionLabel: 'optionLabel',
optionsName: 'businessTypeList'
} }
], ],
// 快递信息 // 快递信息
...@@ -621,7 +647,7 @@ export default { ...@@ -621,7 +647,7 @@ export default {
}, },
listeners: { listeners: {
click: row => { click: row => {
this.secondConfirm('退款', '请确定是否发起退款?', 'orderManage', 'crowdFundRefundApi', { orderCode: row.orderCode }) this.secondConfirm('退款', '请确定是否发起退款?', 'orderManage', 'crowdFundRefundApi', { orderCode: row.orderCode }, () => { }, this.searchForm.requestSource != 0)
} }
} }
}, },
...@@ -689,7 +715,7 @@ export default { ...@@ -689,7 +715,7 @@ export default {
}, },
condition: row => { condition: row => {
// return true // return true
return row.afterSaleStatus == 11 return row.orderStatus == 11
}, },
listeners: { listeners: {
click: this.handleWriteOffApproval click: this.handleWriteOffApproval
...@@ -786,6 +812,20 @@ export default { ...@@ -786,6 +812,20 @@ export default {
width: 160 width: 160
}, },
{ {
label: '业务场景',
prop: 'businessType',
width: 120,
formatter: cellValue => {
let type = cellValue.businessType
if (type) {
return businessType.find(item => item.optionId == type).optionLabel
} else {
return '-'
}
}
},
{
label: '商品名称', label: '商品名称',
prop: '', prop: '',
width: '120', width: '120',
...@@ -879,7 +919,8 @@ export default { ...@@ -879,7 +919,8 @@ export default {
testSheetTypeList: [ testSheetTypeList: [
{ confId: '0', confName: '否' }, { confId: '0', confName: '否' },
{ confId: '1', confName: '是' } { confId: '1', confName: '是' }
] ],
businessTypeList: utils.deepClone(businessType)
} }
} }
}, },
...@@ -968,21 +1009,23 @@ export default { ...@@ -968,21 +1009,23 @@ export default {
// 改变订单类型 // 改变订单类型
changeOrderType(item) { changeOrderType(item) {
console.log(item) console.log(item)
// return
let params = { let params = {
orderCode: item.orderCode, subOrderCode: item.orderCode,
orderType: item.orderType ? 0 : 1 orderType: item.orderType ? 0 : 1
} }
this.$apis.orderManage this.secondConfirm('测试单', '测试单数据不纳入对应战报和喜报的排名展示', 'orderManage', 'updateOrderType', params, false)
.updateOrderType(params) // return
.then(result => {
this.handleSearch() // this.$apis.orderManage
}) // .updateOrderType(params)
.catch(err => { // .then(result => {
console.log(err) // this.handleSearch()
}) // })
// .catch(err => {
// console.log(err)
// })
}, },
secondConfirm(title, txt, apiModule, apiName, apiParams, fn) { secondConfirm(title, txt, apiModule, apiName, apiParams, fn, isResetPage = true) {
this.$confirm(txt, title, { this.$confirm(txt, title, {
confirmButtonText: '确定', confirmButtonText: '确定',
cancelButtonText: '取消', cancelButtonText: '取消',
...@@ -996,7 +1039,8 @@ export default { ...@@ -996,7 +1039,8 @@ export default {
}) })
if (res.code == '0') { if (res.code == '0') {
fn && fn() fn && fn()
this.handleSearch() // this.handleSearch()
isResetPage ? this.handleSearch() : this.$refs.allOrderRef.refreshTable(false)
} }
}) })
} }
...@@ -1080,7 +1124,7 @@ export default { ...@@ -1080,7 +1124,7 @@ export default {
}) })
if (res.code == '0') { if (res.code == '0') {
this.handleWriteOffClose() this.handleWriteOffClose()
this.handleSearch() this.searchForm.requestSource == 0 ? this.$refs.allOrderRef.refreshTable(false) : this.handleSearch()
} }
}) })
} }
...@@ -1088,6 +1132,7 @@ export default { ...@@ -1088,6 +1132,7 @@ export default {
}, },
handleStaffClose() { handleStaffClose() {
console.log('dialogVisible')
this.isStaffVisible = !this.isStaffVisible this.isStaffVisible = !this.isStaffVisible
}, },
handleDialogConfirm() { handleDialogConfirm() {
...@@ -1096,7 +1141,7 @@ export default { ...@@ -1096,7 +1141,7 @@ export default {
}, },
handleWriteOff(row) { handleWriteOff(row) {
if (row.orderSource == 4) { if (row.orderSource == 4) {
this.secondConfirm('订单核销', '请确定是否核销此订单?', 'orderManage', 'crowdFundWriteOffApi', { orderCode: row.orderCode }) this.secondConfirm('订单核销', '请确定是否核销此订单?', 'orderManage', 'crowdFundWriteOffApi', { orderCode: row.orderCode }, () => { }, this.searchForm.requestSource != 0)
return true return true
} }
this.isWriteOffVisible = !this.isWriteOffVisible this.isWriteOffVisible = !this.isWriteOffVisible
...@@ -1126,7 +1171,7 @@ export default { ...@@ -1126,7 +1171,7 @@ export default {
}) })
if (res.code == '0') { if (res.code == '0') {
this.handleExamineClose() this.handleExamineClose()
this.handleSearch() this.searchForm.requestSource == 0 ? this.$refs.allOrderRef.refreshTable(false) : this.handleSearch()
} }
}) })
}, },
......
...@@ -110,6 +110,13 @@ export default { ...@@ -110,6 +110,13 @@ export default {
formatter: cellValue => { formatter: cellValue => {
return cellValue.merchantName || '-' return cellValue.merchantName || '-'
} }
},
{
label: '商户id',
prop: 'merchantNo',
formatter: cellValue => {
return cellValue.merchantNo || '-'
}
} }
] ]
}, },
...@@ -149,11 +156,13 @@ export default { ...@@ -149,11 +156,13 @@ export default {
methods: { methods: {
getList() { getList() {
var params = { // var params = {
merchantId: this.merchantId, // merchantId: this.merchantId,
// merchantId: '44209390', // ...this.searchForm
...this.searchForm // // merchantId: '44209390',
} // }
this.$refs.storeRef.refreshTable()
// this.$apis.common.getSimpleMerchantList(params).then(res => { // this.$apis.common.getSimpleMerchantList(params).then(res => {
// console.log(res) // console.log(res)
// this.storeList = res // this.storeList = res
......
...@@ -161,7 +161,9 @@ export default { ...@@ -161,7 +161,9 @@ export default {
fn: '编辑众筹' fn: '编辑众筹'
}, },
condition: row => { condition: row => {
return row.activityStatus == '1' || row.activityStatus == '2' || row.activityStatus == '3' // 结束的直播不能再开
return ['1', '2'].includes(row.activityStatus)
// return ['1','2','3'].includes(row.activityStatus )
}, },
listeners: { listeners: {
click: row => { click: row => {
...@@ -389,7 +391,7 @@ export default { ...@@ -389,7 +391,7 @@ export default {
}, },
mounted() { mounted() {
// this.getOptionsList('searchFormData') this.getOptionsList('searchFormData')
// const { // const {
// $GLBUTTION_PERMISSIONS: { routes = [], routerBase } // $GLBUTTION_PERMISSIONS: { routes = [], routerBase }
// } = this // } = this
......
...@@ -94,21 +94,28 @@ ...@@ -94,21 +94,28 @@
type="default" type="default"
@click="handleExport('dailyOrders')">导出</el-button> @click="handleExport('dailyOrders')">导出</el-button>
</div> </div>
<el-table v-if="DailyOrderQuantityList.length"
<el-table :data="DailyOrderQuantityListFormat" :data="DailyOrderQuantityListFormat"
style="width: 100%"> style="width: 100%">
<el-table-column :formatter="formatterHeader" <el-table-column :formatter="formatterHeader"
label=""></el-table-column> label=""></el-table-column>
<!-- width="140px" -->
<el-table-column v-for="(item, index) in DailyOrderQuantityList" <el-table-column v-for="(item, index) in DailyOrderQuantityList"
:key="index" :key="index"
:prop="item" :prop="item"
width="140px"
:label="item.day"> :label="item.day">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ scope.$index ? item.currentOrderQuantity : item.specificDate }}</span> <span>{{ scope.$index ? item.currentOrderQuantity : item.specificDate }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column :formatter="formatterEnd"
fixed="right"
label="总计"></el-table-column>
</el-table> </el-table>
<div v-else>
<img src="url"
alt="" />
</div>
</div> </div>
</div> </div>
<div class="data-board-box"> <div class="data-board-box">
...@@ -195,6 +202,7 @@ export default { ...@@ -195,6 +202,7 @@ export default {
return { return {
url, url,
dataList, dataList,
totalCount: 0,
searchForm: { searchForm: {
statDate: dayjs().format('YYYY-MM-DD') statDate: dayjs().format('YYYY-MM-DD')
}, },
...@@ -202,6 +210,7 @@ export default { ...@@ -202,6 +210,7 @@ export default {
baseData: { baseData: {
searchOrderStatusList: orderManageStatusList.filter(item => ['1', '3', '21', '22', '6', '9'].includes(item.confId)) searchOrderStatusList: orderManageStatusList.filter(item => ['1', '3', '21', '22', '6', '9'].includes(item.confId))
}, },
DailyOrderQuantityList: [],
DailyOrderQuantityListFormat: [{}, {}], DailyOrderQuantityListFormat: [{}, {}],
searchFormData: [ searchFormData: [
{ {
...@@ -376,11 +385,17 @@ export default { ...@@ -376,11 +385,17 @@ export default {
.getDailyOrderQuantityStatistics({ id: this.activityId }) .getDailyOrderQuantityStatistics({ id: this.activityId })
.then(result => { .then(result => {
console.log(result) console.log(result)
// let totalCount = {
// currentOrderQuantity: 0,
// specificDate: '',
// day: '总计'
// }
if (result.length) { if (result.length) {
this.DailyOrderQuantityList = result.reduce((arr, item, index) => { this.totalCount = result.reduce((total, item, index, arr) => {
return arr return (total += item.currentOrderQuantity)
}, []) }, 0)
} }
// result.push(totalCount)
this.DailyOrderQuantityList = result || [] this.DailyOrderQuantityList = result || []
}) })
.catch(err => { .catch(err => {
...@@ -428,12 +443,11 @@ export default { ...@@ -428,12 +443,11 @@ export default {
//接收到的数据为空 //接收到的数据为空
this.$refs.dataTableRef.data.length ? (this.$refs.dataTableRef.tableHeightValues = '') : this.$refs.dataTableRef.setTableHeightFun() this.$refs.dataTableRef.data.length ? (this.$refs.dataTableRef.tableHeightValues = '') : this.$refs.dataTableRef.setTableHeightFun()
}, },
formatterHeader(row, column) { formatterHeader(row, column, cellValue, index) {
if (row == 0) { return index == 0 ? '活动日期' : '订单量'
return '活动日期' },
} else { formatterEnd(row, column, cellValue, index) {
return '订单量' return index == 1 ? this.totalCount : ''
}
} }
} }
} }
......
...@@ -84,7 +84,7 @@ ...@@ -84,7 +84,7 @@
style="width: 150px" style="width: 150px"
:disabled="isDisabled"><span slot="append">元</span></el-input> :disabled="isDisabled"><span slot="append">元</span></el-input>
<span class="balancePayment">尾款: <span class="balancePayment">尾款:
{{ editForm.crowdFundingPrice - editForm.activityPrice || '' }}</span> {{ editForm.crowdFundingPrice | filterBalancePayment(editForm.activityPrice) }}</span>
</el-form-item> </el-form-item>
<el-form-item label="众筹价:" <el-form-item label="众筹价:"
...@@ -760,7 +760,8 @@ ...@@ -760,7 +760,8 @@
</template> </template>
<script> <script>
import { limitPrice } from '@/common/constant' import { limitPrice, businessType } from '@/common/constant'
import { utils } from 'glsx-common'
import crowdEditWechat from './crowdEditWechat.vue' import crowdEditWechat from './crowdEditWechat.vue'
import selectStore from './components/selectStore' import selectStore from './components/selectStore'
export default { export default {
...@@ -865,6 +866,7 @@ export default { ...@@ -865,6 +866,7 @@ export default {
selectCarNumberFlag: 2, selectCarNumberFlag: 2,
selectVehicleTypeFlag: 2, selectVehicleTypeFlag: 2,
selectPhoneNumberFlag: 2, selectPhoneNumberFlag: 2,
businessType: 2, //业务场景
formDescribeCheck: ['selectCarNumberFlag', 'selectVehicleTypeFlag', 'selectPhoneNumberFlag'], formDescribeCheck: ['selectCarNumberFlag', 'selectVehicleTypeFlag', 'selectPhoneNumberFlag'],
activityServices: [], activityServices: [],
activityCommoditys: [], activityCommoditys: [],
...@@ -933,9 +935,23 @@ export default { ...@@ -933,9 +935,23 @@ export default {
promotion: [{ required: true, message: '请输入活动宣传语', trigger: 'change' }], promotion: [{ required: true, message: '请输入活动宣传语', trigger: 'change' }],
activityTime: [{ required: true, message: '活动时间不能为空', trigger: 'change' }], activityTime: [{ required: true, message: '活动时间不能为空', trigger: 'change' }],
activityPrice: [ activityPrice: [
{ required: true, message: '请设置秒杀价', trigger: 'change' }, { required: true, message: '请设置定金价', trigger: 'change' },
{ {
validator: (rule, value, callback) => { validator: (rule, value, callback) => {
if (!this.editForm.crowdFundingPrice) return callback(new Error('请先填写众筹价'))
if (value > Number(this.editForm.crowdFundingPrice)) return callback(new Error('定金不能大于众筹价格'))
return value >= +(this.selectedProInfo.retailPrice / 100).toFixed(2) ? callback(new Error('秒杀价必须小于零售价')) : callback()
},
trigger: 'change'
}
],
crowdFundingPrice: [
{ required: true, message: '请设置众筹价', trigger: 'change' },
{
validator: (rule, value, callback) => {
if (value < +this.editForm.activityPrice) {
return callback(new Error('众筹价需要大于定金'))
}
return value >= +(this.selectedProInfo.retailPrice / 100).toFixed(2) ? callback(new Error('秒杀价必须小于零售价')) : callback() return value >= +(this.selectedProInfo.retailPrice / 100).toFixed(2) ? callback(new Error('秒杀价必须小于零售价')) : callback()
}, },
trigger: 'change' trigger: 'change'
...@@ -975,7 +991,8 @@ export default { ...@@ -975,7 +991,8 @@ export default {
activityBigImg: [{ required: true, message: '请选择活动大图', trigger: 'change' }], activityBigImg: [{ required: true, message: '请选择活动大图', trigger: 'change' }],
activityDetail: [{ required: true, message: '请输入活动详情', trigger: 'change' }], activityDetail: [{ required: true, message: '请输入活动详情', trigger: 'change' }],
forwardTitle: [{ required: true, message: '请输入转发标题', trigger: 'change' }], forwardTitle: [{ required: true, message: '请输入转发标题', trigger: 'change' }],
paymentAccountId: [{ required: true, message: '请选择定金收款账户', trigger: 'change' }] paymentAccountId: [{ required: true, message: '请选择定金收款账户', trigger: 'change' }],
businessType: [{ required: true, message: '请选择业务场景', trigger: 'change' }]
}, },
// 表单设置 // 表单设置
formDescribeCheckList: [ formDescribeCheckList: [
...@@ -1015,7 +1032,7 @@ export default { ...@@ -1015,7 +1032,7 @@ export default {
label: '活动名称', label: '活动名称',
name: 'activityName', name: 'activityName',
type: 'input', type: 'input',
maxlength: 20, maxlength: 40,
tips: '如XX店车主关怀活动', tips: '如XX店车主关怀活动',
isDisabled: false isDisabled: false
}, },
...@@ -1092,6 +1109,7 @@ export default { ...@@ -1092,6 +1109,7 @@ export default {
isClear: true, isClear: true,
isHide: true isHide: true
}, },
{ {
label: '规格明细', label: '规格明细',
name: '', name: '',
...@@ -1099,6 +1117,16 @@ export default { ...@@ -1099,6 +1117,16 @@ export default {
isHide: true isHide: true
}, },
{ {
label: '业务场景',
name: 'businessType',
type: 'select',
optionList: utils.deepClone(businessType),
optionId: 'optionId',
optionLabel: 'optionLabel',
isClear: true
// isHide: true
},
{
label: '是否限购', label: '是否限购',
name: 'limitPurchaseFlag', name: 'limitPurchaseFlag',
addHtml: 'limitPurchaseFlag', addHtml: 'limitPurchaseFlag',
...@@ -1652,7 +1680,13 @@ export default { ...@@ -1652,7 +1680,13 @@ export default {
defaultFloatingMaskDiagram: 'https://wx.glsx.com.cn/upload/biz/ba63349f-8e9e-4e80-be3b-45cc38dcf13f.gif' defaultFloatingMaskDiagram: 'https://wx.glsx.com.cn/upload/biz/ba63349f-8e9e-4e80-be3b-45cc38dcf13f.gif'
} }
}, },
filters: {
filterBalancePayment(crowdFundingPrice, activityPrice) {
let BalancePaymentNum = Number(crowdFundingPrice) - Number(activityPrice)
if (BalancePaymentNum == 0) return 0
return BalancePaymentNum > 0 ? BalancePaymentNum : ''
}
},
mounted() { mounted() {
this.getLiveList() this.getLiveList()
this.setMinHeight('.crowd-config') this.setMinHeight('.crowd-config')
...@@ -1694,7 +1728,7 @@ export default { ...@@ -1694,7 +1728,7 @@ export default {
newValue && newValue.length && this.countDown() newValue && newValue.length && this.countDown()
}, },
'editForm.predictVolume'(newValue, oldValue) { 'editForm.predictVolume'(newValue, oldValue) {
this.editForm.predictVolume = limitPrice(newValue, oldValue, 7, 2, 0, 1000000) this.editForm.predictVolume = limitPrice(newValue, oldValue, 10, 2, 0, 1000000000)
}, },
'editForm.fictitiousGroupQuantity'(newValue, oldValue) { 'editForm.fictitiousGroupQuantity'(newValue, oldValue) {
this.editForm.fictitiousGroupQuantity = limitPrice(newValue, oldValue, 3, 0, 0, 501) this.editForm.fictitiousGroupQuantity = limitPrice(newValue, oldValue, 3, 0, 0, 501)
...@@ -1876,7 +1910,7 @@ export default { ...@@ -1876,7 +1910,7 @@ export default {
}, },
handleRelateProClose(targetItem) { handleRelateProClose(targetItem) {
// 先选门店在选商品 // 先选门店在选商品
if (this.editForm.merchantId) return this.$message.error('请先选择门店!') if (!this.editForm.merchantId) return this.$message.error('请先选择门店!')
this.selectedProInfo = this.editForm.goodsId ? { id: this.editForm.goodsId } : {} this.selectedProInfo = this.editForm.goodsId ? { id: this.editForm.goodsId } : {}
this.handleSingleSelectClose() this.handleSingleSelectClose()
}, },
......
...@@ -9,7 +9,7 @@ const cdn = { ...@@ -9,7 +9,7 @@ const cdn = {
js: [`${CDN_DOMAIN}ajax/libs/vue/2.6.11/vue.min.js`, `${CDN_DOMAIN}ajax/libs/vue-router/3.2.0/vue-router.min.js`, `${CDN_DOMAIN}ajax/libs/element-ui/2.11.1/index.js`, `${CDN_DOMAIN}ajax/libs/vuex/3.6.2/vuex.min.js`, `${CDN_DOMAIN}ajax/libs/echarts/5.1.2/echarts.min.js`, 'https://webapi.amap.com/loader.js'] js: [`${CDN_DOMAIN}ajax/libs/vue/2.6.11/vue.min.js`, `${CDN_DOMAIN}ajax/libs/vue-router/3.2.0/vue-router.min.js`, `${CDN_DOMAIN}ajax/libs/element-ui/2.11.1/index.js`, `${CDN_DOMAIN}ajax/libs/vuex/3.6.2/vuex.min.js`, `${CDN_DOMAIN}ajax/libs/echarts/5.1.2/echarts.min.js`, 'https://webapi.amap.com/loader.js']
} }
module.exports = { module.exports = {
outputDir: `dist`, outputDir: `../dist/${packageName}`,
publicPath, publicPath,
assetsDir: 'static', assetsDir: 'static',
productionSourceMap: false, productionSourceMap: false,
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!