Commit 4bfdebb3 by 张立顺

v3.2 众筹模块迁移

1 parent 026cf89d
......@@ -161,4 +161,15 @@ const getMerchantInfoApi = params => {
})
}
export default { getMerchantGoodsListApi, getGoodsListApi, uploadImgApi, uploadMusicApi, uploadVideoApi, uploadFundingVideoApi, getMerchantList, getSimpleMerchantList, getZoneListApi, getClassifyListApi, pictureUpload, querylabeltree, getCrowdTreeListApi, getStaffFollowerListApi, getMerchantInfoApi }
// 根据门店号获取员工列表
const getMerchantStaff = params => {
params.method = 'scrm.api.shopmall.crowd.funding.staff.get'
return http({
url: '/rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true
})
}
export default { getMerchantGoodsListApi, getGoodsListApi, uploadImgApi, uploadMusicApi, uploadVideoApi, uploadFundingVideoApi, getMerchantList, getSimpleMerchantList, getZoneListApi, getClassifyListApi, pictureUpload, querylabeltree, getCrowdTreeListApi, getStaffFollowerListApi, getMerchantInfoApi, getMerchantStaff }
......@@ -137,4 +137,42 @@ const updateOrderType = params => {
})
}
export default { getListApi, getCountApi, getOrderDetailApi, orderExportApi, writeOffApi, crowdFundWriteOffApi, crowdFundRefundApi, addDeliveryApi, examineDetailApi, examineAllowApi, confirmReceiptGoodsApi, updateOrderType }
/** 设置活动的指派人 */
const signerOrder = params => {
params.method = 'scrm.api.shopmall.crowd.funding.order.appointer.update'
return http({
url: '/rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true,
returnAll: false
})
}
// /router/scrm.api.stoassistant.user.activity.confirm.install.info/1.0.0
/** 获取确认安装待审核信息 */
const getInstallInfo = params => {
params.method = 'scrm.api.stoassistant.user.activity.confirm.install.info'
return http({
url: '/rop-scrm-stoassistant/router',
method: 'POST',
data: params,
sign: true,
returnAll: false
})
}
/** 根据订单号核销众筹活动订单 */
const orderVerfication = params => {
params.method = 'scrm.api.shopmall.crowd.funding.order.verfication'
return http({
url: '/rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true,
returnAll: false
})
}
export default { getInstallInfo, orderVerfication, signerOrder, getListApi, getCountApi, getOrderDetailApi, orderExportApi, writeOffApi, crowdFundWriteOffApi, crowdFundRefundApi, addDeliveryApi, examineDetailApi, examineAllowApi, confirmReceiptGoodsApi, updateOrderType }
import { http } from '@/main'
const defaultPath = 'scrm.api.shopmall.goods.'
const getListApi = params => {
params.method = `${defaultPath}page.curMerchant`
return http({
url: 'rop-scrm-shopmall/router',
method: 'GET',
data: params,
sign: true
})
}
const getProShareApi = params => {
params.method = `${defaultPath}get.shared`
return http({
url: 'rop-scrm-shopmall/router',
method: 'GET',
data: params,
sign: true
})
}
const topProApi = params => {
params.method = `${defaultPath}updateToTop`
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true,
returnAll: true
})
}
const updateStatusProApi = params => {
params.method = `${defaultPath}updateStatus`
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true,
returnAll: true
})
}
const deleteTakeProApi = params => {
params.method = `${defaultPath}deleteTakeGoods`
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true,
returnAll: true
})
}
const getProInfoApi = params => {
params.method = `${defaultPath}getById`
return http({
url: 'rop-scrm-shopmall/router',
method: 'GET',
data: params,
sign: true
})
}
const insertOrUpdateProApi = params => {
params.method = `${defaultPath}insertOrUpdate`
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true,
returnAll: true
})
}
const updateTakeProApi = params => {
params.method = `${defaultPath}updateTake`
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true,
returnAll: true
})
}
const getGoodsCommentListApi = params => {
params.method = 'scrm.api.shopmall.backstage.orderGoodsComment.page'
return http({
url: 'rop-scrm-shopmall/router',
method: 'GET',
data: params,
sign: true
})
}
const getBusinessTypeByIdApi = params => {
params.method = 'scrm.api.shopmall.goods.getBusinessTypeById'
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true
})
}
const deleteGoodsApi = params => {
params.method = 'scrm.api.shopmall.goods.deleteGoods'
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true,
returnAll: true
})
}
export default { getBusinessTypeByIdApi, getListApi, getProShareApi, topProApi, updateStatusProApi, deleteTakeProApi, getProInfoApi, insertOrUpdateProApi, updateTakeProApi, getGoodsCommentListApi, deleteGoodsApi }
......@@ -172,6 +172,17 @@ const getLiveListApi = params => {
})
}
/**定金收款账户下拉列表 */
const getPayListApi = params => {
params.method = 'scrm.api.shopmall.activity.payment.account.list'
return http({
url: 'rop-scrm-shopmall/router',
method: 'GET',
data: params,
sign: true
})
}
/**数据看板员工排名 */
const getRankListApi = params => {
params.method = 'scrm.api.shopmall.activity.ranking.page'
......@@ -202,4 +213,60 @@ const getDataBoardApi = params => {
sign: true
})
}
export default { getActivityPageApi, getCrowdfundListApi, exportCrowdfundApi, getBrowseListApi, exportBrowseApi, toggleStatusApi, deleteActivityApi, topActivityApi, getSharedApi, addOrUpdateActivityApi, getActivityDetailApi, getCrowdSharedApi, getLiveListApi, getRankListApi, exportRankListApi, getDataBoardApi, getVisitorListApi, getSharedListApi }
/**每日订单量统计 */
const getDailyOrderQuantityStatistics = params => {
params.method = 'scrm.api.shopmall.activity.daily.order.quantity'
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true
})
}
/**导出每日订单量统计 */
const exportDailyOrderQuantityStatistics = params => {
params.method = 'scrm.api.shopmall.activity.daily.order.quantity.export'
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true
})
}
/**活动直播间数据统计-详情导出 */
const liveroomDetailexport = params => {
params.method = 'scrm.api.shopmall.activity.liveroom.detailexport'
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true
})
}
/**活动直播间数据统计-分页详情 */
const liveroomDetailpage = params => {
params.method = 'scrm.api.shopmall.activity.liveroom.detailpage'
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true
})
}
/**活动直播间数据统计-概览 */
const liveroomOverview = params => {
params.method = 'scrm.api.shopmall.activity.liveroom.overview'
return http({
url: 'rop-scrm-shopmall/router',
method: 'POST',
data: params,
sign: true
})
}
export default { getPayListApi, liveroomDetailexport, liveroomDetailpage, liveroomOverview, getActivityPageApi, getCrowdfundListApi, exportCrowdfundApi, getBrowseListApi, exportBrowseApi, toggleStatusApi, deleteActivityApi, topActivityApi, getSharedApi, addOrUpdateActivityApi, getActivityDetailApi, getCrowdSharedApi, getLiveListApi, getRankListApi, exportRankListApi, getDataBoardApi, getVisitorListApi, getSharedListApi, getDailyOrderQuantityStatistics, exportDailyOrderQuantityStatistics }
......@@ -133,16 +133,6 @@ html {
word-break: break-all;
}
body,
html {
width: 100%;
height: 100%;
margin: 0;
padding: 0;
overflow: hidden;
background-color: #f4f5fa;
}
.el-range-editor.is-active,
.el-range-editor.is-active:hover {
border-color: #5850ff;
......@@ -882,4 +872,11 @@ html {
display: inline-block;
vertical-align: middle;
margin-right: 8px;
}
ul li {
padding: 0;
margin: 0;
list-style: none;
}
\ No newline at end of file
......@@ -31,22 +31,60 @@ function limitPrice(newValue, oldValue, intergerDigit, pointDigit, minValue, max
}
}
function aToExport(url) {
var a = document.createElement('a')
a.setAttribute('id', 'exportToExport')
a.setAttribute('href', url)
a.setAttribute('target', '_blank')
document.body.appendChild(a)
a.click()
}
/**
* url下载文件
*
*/
function downLoadFile(url) {
// console.log(row)
// return
const Temp = document.createElement('a')
// Temp.href = process.env.VUE_APP_BASE_URL + '/article/export.do?articleId=' + row.id
Temp.href = url
// console.log(url)
// console.log(Temp.href)
document.body.append(Temp)
Temp.click()
document.body.removeChild(Temp)
}
// const orderManageStatusList = [
// { confId: '1', confName: '未支付' },
// { confId: '2', confName: '已支付' },
// { confId: '3', confName: '已失效' },
// { confId: '4', confName: '已发货' },
// { confId: '5', confName: '已收货' },
// { confId: '6', confName: '待审核' },
// { confId: '7', confName: '审核成功' },
// { confId: '8', confName: '审核失败' },
// { confId: '9', confName: '待确认' },
// { confId: '10', confName: '退款中' },
// { confId: '11', confName: '已退款' },
// { confId: '12', confName: '退款失败' },
// { confId: '13', confName: '待发货' },
// { confId: '14', confName: '待安装' },
// { confId: '15', confName: '已安装' }
// ]
const orderManageStatusList = [
{ confId: '1', confName: '未支付' },
{ confId: '1', confName: '待付款' },
{ confId: '2', confName: '已支付' },
{ confId: '3', confName: '已失效' },
{ confId: '4', confName: '已发货' },
{ confId: '5', confName: '已收货' },
{ confId: '6', confName: '待审核' },
{ confId: '7', confName: '审核成功' },
{ confId: '8', confName: '审核失败' },
{ confId: '9', confName: '待确认' },
{ confId: '10', confName: '退款中' },
{ confId: '11', confName: '已退款' },
{ confId: '12', confName: '退款失败' },
{ confId: '13', confName: '待发货' },
{ confId: '14', confName: '待安装' },
{ confId: '15', confName: '已安装' }
// { confId: '21', confName: '待收货(待核销)' },
{ confId: '21', confName: '待核销' },
{ confId: '22', confName: '已核销' },
// { confId: '22', confName: '已收货(已核销)' },
{ confId: '6', confName: '待发货' },
// { confId: '7', confName: '待核销' },
// { confId: '8', confName: '已核销' },
{ confId: '9', confName: '售后中' },
{ confId: '10', confName: '售后完成' }
]
const orderSourceList = [
......@@ -206,4 +244,4 @@ function setMinHeight(calssName = '.edit-container') {
document.querySelector(calssName).style.minHeight = minHeight
}
export { limitPrice, orderManageStatusList, orderSourceList, deliveryTypeList, statusList, serviceStatusList, memberTypeList, stateList, orderTypesList, orderStatusList, afterSaleStatusList, exportFn, setMinHeight }
export { limitPrice, aToExport, orderManageStatusList, orderSourceList, deliveryTypeList, statusList, serviceStatusList, memberTypeList, stateList, orderTypesList, orderStatusList, afterSaleStatusList, exportFn, setMinHeight, downLoadFile }
<!-- 选择商品 - 单选 -->
<template>
<GLDialog class="single-pro" bigTitle="选择商品" mode="big" :before-close="handleSingleSelectClose" :okText="productList.length ? '确定' : '创建商品'" :visible.sync="isSingleSelectVisible" @onOk="handleSingleSelectConfirm" @onCancel="handleSingleSelectClose">
<GLDialog class="single-pro"
bigTitle="选择商品"
mode="big"
:before-close="handleSingleSelectClose"
:okText="productList.length ? '确定' : '创建商品'"
:visible.sync="isSingleSelectVisible"
@onOk="handleSingleSelectConfirm"
@onCancel="handleSingleSelectClose">
<div style="max-height:60vh">
<div class="noproDiv" v-if="!productList.length && fnCallBack">
<div class="noproDiv"
v-if="!productList.length && fnCallBack">
<img src="@/assets/noPro.png" />
<p class="noproP">系统暂无已创建的商品</p>
</div>
<el-radio-group v-model="infoId" v-if="productList.length" class="pro-group">
<el-radio :class="['pro-box', item.id == infoId ? 'active' : '']" v-for="item in productList" :key="item.id" :label="item.id">
<img v-show="item.id == infoId" class="icon-check" src="@/assets/icon-check.png" />
<img class="goods-img" :src="item.goodsImage" />
<el-radio-group v-model="infoId"
v-if="productList.length"
class="pro-group">
<el-radio :class="['pro-box', item.id == infoId ? 'active' : '']"
v-for="item in productList"
:key="item.id"
:label="item.id">
<img v-show="item.id == infoId"
class="icon-check"
src="@/assets/icon-check.png" />
<img class="goods-img"
:src="item.goodsImage" />
<div class="txt-box">
<p :title="item.goodsName" class="ellipsis">{{ item.goodsName }}</p>
<p :title="item.goodsName"
class="ellipsis">{{ item.goodsName }}</p>
<p class="f-s-12">销量:{{ item.saleAmount }}</p>
<p class="f-s-12">库存:{{ item.goodsStock }}</p>
<p class="f-s-12">零售价:{{ item.retailPrice }}</p>
<p :title="item.merchantName" class="ellipsis f-s-12">门店名称:{{ item.merchantName }}</p>
<p :title="item.merchantName"
class="ellipsis f-s-12">门店名称:{{ item.merchantName }}</p>
</div>
</el-radio>
</el-radio-group>
......@@ -44,7 +62,11 @@ export default {
},
selectedProInfo: {
type: Object,
default: () => {}
default: () => { }
},
merchantId: {
type: String,
required: true
}
},
......@@ -62,20 +84,21 @@ export default {
goodsStatus: 1,
goodsSource: 1,
pageNum: 1,
pageSize: 100000
pageSize: 100000,
merchantId: this.merchantId
}
var that = this
this.$apis.common.getMerchantGoodsListApi(params).then(res => {
// console.log(res)
this.fnCallBack = true
this.productList = res.list
this.productList.forEach(function(item) {
this.productList.forEach(function (item) {
item.saleAmount = item.goodsStatistics.saleAmount
if (item.specificationDetailList.length > 1) {
let retailPriceList = item.specificationDetailList.sort(function(a, b) {
let retailPriceList = item.specificationDetailList.sort(function (a, b) {
return a.retailPrice - b.retailPrice
})
let stockeList = item.specificationDetailList.sort(function(a, b) {
let stockeList = item.specificationDetailList.sort(function (a, b) {
return a.stock - b.stock
})
let minRatilPrice = retailPriceList[0].retailPrice / 100
......
<template>
<div class="select-crowd">
<GLDialog bigTitle="选择人群" mode="big" :visible.sync="dialogVisible" :before-close="handleClose" :close-on-click-modal="false" @onOk="handleConfirm" @onCancel="handleClose">
<glsx-combi-form ref="showSearch" :formObj="searchForm" :formData="searchFormData">
<div class="select-staff">
<!-- class="staffDailog" -->
<GLDialog bigTitle="选择员工"
mode="big"
width="600px"
:visible.sync="dialogVisible"
:before-close="handleClose"
:close-on-click-modal="false"
@onOk="handleConfirm"
@onCancel="handleClose">
<glsx-combi-form ref="showSearch"
labelWidth="105px"
:formObj="searchForm"
:formData="searchFormData">
<span slot="footer">
<el-button :size="size" type="primary" @click="getList">查询</el-button>
<el-button :size="size"
type="primary"
@click="getList">查询</el-button>
</span>
</glsx-combi-form>
<GLTable ref="crowdRef" :pageConf="pageConf" :hasNum="false" :noDataImg="url" :tableData="crowdList" :tableTotal="total" :tableParams="tableParams" @refreshTable="getList" :setTableFinishFun="setTableFinishFun">
<div slot="radioHtml" class="crowd-table" slot-scope="scope">
<el-radio v-model="selectedCrowdId" :label="scope.scope.crowdId" @click.native="handleClick(scope.scope)"></el-radio>
<!-- :pageConf="pageConf" -->
<GLTable ref="staffRef"
:hasPage="false"
:hasNum="false"
:noDataImg="url"
:tableData="staffList"
:tableTotal="total"
:tableParams="tableParams"
@refreshTable="getList"
:setTableFinishFun="setTableFinishFun">
<div slot="radioHtml"
class="staff-table"
slot-scope="scope">
<el-radio v-model="staffUuid"
:label="scope.scope.uuid"
@click.native="handleClick(scope.scope)"></el-radio>
</div>
</GLTable>
<!-- <span slot="footer" class="dialog-footer">
......@@ -22,33 +48,35 @@
<script>
import url from '@/assets/empty.png'
export default {
name: 'selectCrowd',
name: 'selectStaff',
data() {
return {
url: url,
searchForm: {
keyword: ''
name: ''
},
total: 0,
crowdList: [],
staffList: [],
heightBox: 200,
selectedCrowdId: '',
staffUuid: '',
// 搜索
searchFormData: [
{
label: '关键字',
name: 'keyword',
label: '员工',
name: 'name',
type: 'input',
placeholder: '请输入人群名称'
placeholder: '请输入员工名称',
width: '300px',
labelWidth: '10px'
}
],
// 表格
// getListApi: this.$apis.common.getCrowdTreeListApi,
// getListApi: this.$apis.common.getstaffTreeListApi,
tableParams: {
listName: 'crowdUnitList',
listName: 'staffUnitList',
// 行数据的key
// mutiSelectUniqueKey: 'crowdId',
// checkSelectKey: 'crowdId',
// mutiSelectUniqueKey: 'staffId',
// checkSelectKey: 'staffId',
// checkSelectVal: [],
// 多选ref的名称
// mutiSelectName: 'list',
......@@ -65,23 +93,11 @@ export default {
width: 80
},
{
label: '人群名称',
prop: 'crowdName',
label: '员工姓名',
prop: 'staffName',
formatter: cellValue => {
return cellValue.crowdName || '-'
return cellValue.staffName || '-'
}
},
{
label: '人群描述',
prop: 'crowdDesc',
formatter: cellValue => {
return cellValue.crowdDesc || '-'
}
},
{
label: '预估人数',
prop: 'total',
width: '160px'
}
]
},
......@@ -95,67 +111,89 @@ export default {
type: Boolean,
default: false
},
selectedCrowdList: {
type: Array,
default: () => []
selectedstaffUuid: {
type: String
},
merchantId: {
type: String,
required: true
},
orderCode: {
type: String,
required: true
}
},
mounted() {
this.userInfo = this.$globalState.session
// this.userInfo = this.$globalState.session
let clientHeight = document.documentElement.clientHeight
this.heightBox = clientHeight - 0.15 * clientHeight - 425
this.staffUuid = this.selectedstaffUuid
this.getList()
},
methods: {
getList() {
var params = {
req: {
...this.searchForm,
crowdType: 3,
merchantId: this.userInfo.merchantId,
pageNum: this.$refs.crowdRef ? this.$refs.crowdRef.page.pageNum : 1,
pageSize: this.$refs.crowdRef ? this.$refs.crowdRef.page.pageSize : 10
}
merchantId: this.merchantId,
// merchantId: '44209390',
...this.searchForm
}
this.$apis.common.getCrowdTreeListApi(params).then(res => {
this.crowdList = res.crowdUnitList
this.total = res.total
var page = this.$refs.crowdRef.page
// 添加序号
this.crowdList.forEach((item, index) => {
item.idx = index + (page[this.pageConf.pageNum] - 1) * page[this.pageConf.pageSize] + 1
this.$apis.common.getMerchantStaff(params).then(res => {
console.log(res)
this.staffList = res
// this.staffList = res.staffUnitList
// this.total = res.total
// var page = this.$refs.staffRef.page
// // 添加序号
this.staffList.forEach((item, index) => {
item.idx = index + 1
})
this.selectedCrowdList.length && (this.selectedCrowdId = +this.selectedCrowdList[0].crowdId)
this.$refs.crowdRef.tableHeightValues = '460px'
this.$refs.staffRef.tableHeightValues = '460px'
})
},
setTableFinishFun() {
this.crowdList = this.$refs.crowdRef.data
this.staffList = this.$refs.staffRef.data
//接收到的数据为空
this.$refs.crowdRef.tableHeightValues = '460px'
this.$refs.staffRef.tableHeightValues = '460px'
},
handleClick(val) {
let temp = JSON.parse(JSON.stringify(val))
delete temp.idx
this.selectedCrowdList = [temp]
console.log(val)
// let temp = JSON.parse(JSON.stringify(val))
// delete temp.idx
// this.staffUuid = val.uuid
},
handleClose() {
this.$emit('handleCrowdCustClose')
this.$emit('handleStoreClose')
},
handleConfirm() {
this.$emit('handleCrowdCustConfirm', this.selectedCrowdList)
if (!this.staffUuid)
return this.$message({
message: '请先选择员工',
type: 'error'
})
let parmas = {
subOrderCode: this.orderCode,
staffUuid: this.staffUuid
}
this.$apis.orderManage.signerOrder(parmas).then(res => {
console.log(res)
this.$emit('handleStaffConfirm', this.staffUuid)
})
}
}
}
</script>
<style lang="scss">
.select-crowd {
.select-staff {
.staffDailog {
width: 500px;
}
.title {
margin-bottom: 12px;
}
......@@ -201,7 +239,7 @@ export default {
.p-16 {
padding: 16px;
}
.crowd-table .el-radio__label {
.staff-table .el-radio__label {
display: none;
}
}
......
......@@ -37,7 +37,7 @@
name="3"></el-tab-pane>
<el-tab-pane label="售后订单"
name="4"></el-tab-pane>
<el-tab-pane label="售后订单"
<el-tab-pane label="待审批"
name="5"></el-tab-pane>
</el-tabs>
</div>
......@@ -109,7 +109,9 @@
<div slot="assignName"
slot-scope="scope">
<div>
<span>{{ scope.scope.assignStaffName }}</span>
<img class="img-36 pointer img-circle"
:src="scope.scope.assignStaffImageUrl || scope.scope.shareStaffImageUrl" />
<span>{{ scope.scope.assignStaffName || scope.scope.shareStaffName }}</span>
<span @click="handlerAssign(scope.scope)"
class="assignLabel">指派</span>
</div>
......@@ -245,11 +247,31 @@
</el-form>
</GLDialog>
<!-- 指派员工 -->
<select-Crowd v-if="isCrowdCustVisible"
:dialogVisible="isCrowdCustVisible"
:selectedCrowdList="JSON.parse(JSON.stringify(customerDataList[0].list))"
@handleCrowdCustClose="handleCrowdCustClose"
@handleCrowdCustConfirm="handleDialogConfirm"></select-Crowd>
<select-staff v-if="isStaffVisible"
:merchantId="merchantId"
:orderCode="orderCode"
:dialogVisible="isStaffVisible"
@handleStaffClose="handleStaffClose"
@handleStaffConfirm="handleDialogConfirm"></select-staff>
<!-- 核销审批 -->
<GLDialog v-if="writeOffApprovalVisible"
title="核销审批"
width="400px"
:visible.sync="writeOffApprovalVisible"
@onCancel="handleApprovalClose"
@onOk="handleApprovalComfirm"
:orderCode="orderCode">
<ul>
<li class="approvalInfoTips">
<img class="tips-img"
src="@/assets/icon-info.png" />
请确定是否核销此订单?
</li>
<li class="approvalInfoItem">员工名称: {{ approvalInfo.staffName }}</li>
<li class="approvalInfoItem">提交时间: {{ approvalInfo.confirmInstallTime }}</li>
</ul>
</GLDialog>
<!-- :selectedCrowdList="JSON.parse(JSON.stringify(customerDataList[0].list))" -->
<!-- <GLDialog :bigTitle="'选择成员'"
mode="big"
:visible.sync="membersVisible"
......@@ -265,21 +287,23 @@
<script>
import * as dayjs from 'dayjs'
import url from '@/assets/empty.png'
import selectCrowd from './components/selectCrowd.vue'
import selectStaff from './components/selectStaff.vue'
import { orderManageStatusList, afterSaleStatusList, orderSourceList, deliveryTypeList, exportFn } from '@/common/constant'
export default {
name: 'orderManage',
components: {
// SelectMember,
selectCrowd
selectStaff
},
data() {
return {
isCrowdCustVisible: false,
isStaffVisible: false,
size: 'small',
url: url,
isEdit: true,
orderCode: '',
merchantId: '',
approvalInfo: {},
oldVal: {
orderStatuses: [],
afterSaleStatuses: []
......@@ -291,7 +315,8 @@ export default {
merchantName: '',
customerName: '',
createDate: [],
orderSource: '',
orderSource: '4',
requestType: '1', //运营版 固定传值 实现筛选全部订单
deliveryType: '',
vin: '',
shareStaffName: '',
......@@ -399,15 +424,15 @@ export default {
isClear: true,
pickerOptions: 'beforeRangePickerOptions'
},
{
label: '订单类型',
name: 'orderSource',
type: 'select',
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'orderSourceList'
},
// {
// label: '订单类型',
// name: 'orderSource',
// type: 'select',
// optionList: [],
// optionId: 'confId',
// optionLabel: 'confName',
// optionsName: 'orderSourceList'
// },
{
label: '结算方式',
name: 'deliveryType',
......@@ -473,10 +498,20 @@ export default {
labelWidth: 56,
type: 'input',
maxlength: 11
},
{
label: '测试单',
name: 'orderType',
type: 'select',
optionList: [],
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'testSheetTypeList'
}
],
// 快递信息
isExpressVisible: false,
writeOffApprovalVisible: false,
editChildRef: 'editChildRef',
expressForm: {
deliveryCompany: '',
......@@ -501,7 +536,7 @@ export default {
}
],
// 订单核销
isWriteOffVisible: false,
writeOffForm: {
verificationCode: ''
},
......@@ -645,6 +680,20 @@ export default {
listeners: {
click: this.handleReceiving
}
},
{
type: 'el-button',
name: '核销审批',
attrs: {
type: 'text'
},
condition: row => {
// return true
return row.afterSaleStatus == 11
},
listeners: {
click: this.handleWriteOffApproval
}
}
],
// 表格
......@@ -826,6 +875,10 @@ export default {
shareStaffTypeList: [
{ confId: '1', confName: '个微' },
{ confId: '2', confName: '企微' }
],
testSheetTypeList: [
{ confId: '0', confName: '否' },
{ confId: '1', confName: '是' }
]
}
}
......@@ -881,10 +934,36 @@ export default {
})
}
},
handleApprovalClose() {
this.writeOffApprovalVisible = !this.writeOffApprovalVisible
},
handleApprovalComfirm() {
this.$apis.orderManage.orderVerfication({ orderCode: this.orderCode }).then(result => {
this.handleApprovalClose()
this.handleSearch()
})
},
// 核销审批
handleWriteOffApproval(val) {
this.orderCode = val.orderCode
this.$apis.orderManage
.getInstallInfo({
subOrderCode: val.orderCode
// subOrderCode: 'S2211111603132050'
})
.then(result => {
this.approvalInfo = result
// console.log(result)
})
this.handleApprovalClose()
},
// 订单指派
handlerAssign(item) {
// this.
console.log(item)
this.merchantId = item.merchantId
this.orderCode = item.orderCode
this.isStaffVisible = true
},
// 改变订单类型
changeOrderType(item) {
......@@ -1008,8 +1087,12 @@ export default {
})
},
handleCrowdCustClose() {
this.isCrowdCustVisible = !this.isCrowdCustVisible
handleStaffClose() {
this.isStaffVisible = !this.isStaffVisible
},
handleDialogConfirm() {
this.handleStaffClose()
this.handleSearch()
},
handleWriteOff(row) {
if (row.orderSource == 4) {
......@@ -1223,4 +1306,14 @@ export default {
}
}
}
.approvalInfoTips {
font-weight: 500;
font-size: 16px;
color: #1d1d1d;
margin-bottom: 16px;
}
.approvalInfoItem {
margin-left: 20px;
margin-bottom: 10px;
}
</style>
......@@ -4,10 +4,16 @@
<div class="edit-box">
<div class="container m-b-20">
<p class="edit-title">订单信息</p>
<el-form label-width="100px" :inline="true">
<el-row v-for="(item, index) in detailFormDataRow" :key="index">
<el-form-item v-for="(subItem, subIndex) in item.rowList" :key="subIndex" :label="subItem.label" class="row-item">
<span class="detail-txt ellipsis-1" :title="detailForm[subItem.name]">{{ detailForm[subItem.name] ? detailForm[subItem.name] + (subItem.suffix || '') : '-' }}</span>
<el-form label-width="100px"
:inline="true">
<el-row v-for="(item, index) in detailFormDataRow"
:key="index">
<el-form-item v-for="(subItem, subIndex) in item.rowList"
:key="subIndex"
:label="subItem.label"
class="row-item">
<span class="detail-txt ellipsis-1"
:title="detailForm[subItem.name]">{{ detailForm[subItem.name] ? detailForm[subItem.name] + (subItem.suffix || '') : '-' }}</span>
</el-form-item>
</el-row>
<el-form-item label="其他信息">{{ detailForm.formDescribe }}</el-form-item>
......@@ -15,43 +21,61 @@
</div>
<div :class="['container', orderRefund ? 'm-b-20' : 'edit-container']">
<p class="edit-title">发货信息</p>
<el-form label-width="100px" :inline="true">
<el-form label-width="100px"
:inline="true">
<el-form-item label="物流信息">
<span>{{ detailForm.deliveryCompany }}&nbsp;&nbsp;&nbsp;{{ detailForm.deliveryNumber }}</span>
</el-form-item>
</el-form>
<div v-if="orderGoods.length" class="p-l-40">
<div v-if="orderGoods.length"
class="p-l-40">
<table class="show-table">
<tbody>
<tr v-for="(item, index) in orderGoods" :key="index" style="height: 70px;">
<td><img :src="item.goodsImage" class="img-60" /></td>
<tr v-for="(item, index) in orderGoods"
:key="index"
style="height: 70px;">
<td><img :src="item.goodsImage"
class="img-60" /></td>
<td>{{ item.goodsName }}</td>
<td>{{ item.specificationData }}</td>
<td>{{ item.activityPrice ? item.activityPrice : item.retailPrice }}元 * {{ item.goodsNumber }}</td>
<td>{{ item.activityPrice ? item.activityPrice : item.retailPrice }}元 *
{{ item.goodsNumber }}</td>
</tr>
<tr v-if="detailForm.subOrderCoupon" style="height: 40px;">
<td style="text-align: left;" colspan="3">优惠券</td>
<tr v-if="detailForm.subOrderCoupon"
style="height: 40px;">
<td style="text-align: left;"
colspan="3">优惠券</td>
<td>{{ detailForm.subOrderCoupon.discountAmount }}元</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="container edit-container" v-if="orderRefund">
<div class="container edit-container"
v-if="orderRefund">
<p class="edit-title">售后信息</p>
<el-form label-width="100px" :inline="true">
<el-row v-for="(item, index) in afterInfoDataRow" :key="index">
<el-form-item v-for="(subItem, subIndex) in item.rowList" :key="subIndex" :label="subItem.label">
<span class="detail-txt ellipsis-1" :title="orderRefund[subItem.name]">{{ orderRefund[subItem.name] || '-' }}</span>
<el-form label-width="100px"
:inline="true">
<el-row v-for="(item, index) in afterInfoDataRow"
:key="index">
<el-form-item v-for="(subItem, subIndex) in item.rowList"
:key="subIndex"
:label="subItem.label">
<span class="detail-txt ellipsis-1"
:title="orderRefund[subItem.name]">{{ orderRefund[subItem.name] || '-' }}</span>
</el-form-item>
</el-row>
</el-form>
<div class="form-img">
<el-form label-width="100px" :inline="true">
<el-form label-width="100px"
:inline="true">
<el-form-item label="售后凭证">
<div class="flex">
<span v-for="(item, index) in orderRefund.imgUrls" :key="index">
<el-image class="img-60 comment-img" :src="item" :preview-src-list="[item]"></el-image>
<span v-for="(item, index) in orderRefund.imgUrls"
:key="index">
<el-image class="img-60 comment-img"
:src="item"
:preview-src-list="[item]"></el-image>
</span>
</div>
</el-form-item>
......@@ -60,7 +84,8 @@
</div>
</div>
<GLFooter>
<el-button @click="handleCancel" size="medium">取消</el-button>
<el-button @click="handleCancel"
size="medium">取消</el-button>
</GLFooter>
</div>
</template>
......@@ -134,10 +159,14 @@ export default {
name: 'orderStatusName'
},
{
label: '支付总价',
label: '支付定金',
name: 'payPrice'
},
{
label: '尾款',
name: 'crowdFundingPrice'
},
{
label: '发货地址',
name: 'shipAddress'
},
......@@ -248,6 +277,10 @@ export default {
}
this.orderGoods = res.orderGoods || []
this.detailForm.payPrice = res.payPrice ? res.payPrice + '元' : '0元'
this.detailForm.crowdFundingPrice = ''
if (res.payPrice && res.crowdFundingPrice) {
this.detailForm.crowdFundingPrice = res.crowdFundingPrice - res.payPrice + '元'
}
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 : '-'
if (!this.detailForm.takeFee) {
......
<template>
<div class="select-store">
<!-- width="600px" -->
<GLDialog bigTitle="选择门店"
mode="big"
:visible.sync="dialogVisible"
:before-close="handleClose"
:close-on-click-modal="false"
@onOk="handleConfirm"
@onCancel="handleClose">
<glsx-combi-form ref="showSearch"
labelWidth="105px"
:formObj="searchForm"
:formData="searchFormData">
<span slot="footer">
<el-button :size="size"
type="primary"
@click="getList">查询</el-button>
</span>
</glsx-combi-form>
<!-- : :hasPage="false"
:hasNum="false" :tableData="storeList" -->
<GLTable ref="storeRef"
:noDataImg="url"
:tableTotal="total"
:searchForm="searchForm"
:tableParams="tableParams"
:pageConf="pageConf"
@refreshTable="getList"
:getListApi="getListApi"
:setTableFinishFun="setTableFinishFun">
<div slot="radioHtml"
class="store-table"
slot-scope="scope">
<el-radio v-model="merchantId"
:label="scope.scope.merchantNo"
@click.native="handleClick(scope.scope)"></el-radio>
</div>
</GLTable>
<!-- <span slot="footer" class="dialog-footer">
<el-button size="small" @click="handleClose">取 消</el-button>
<el-button size="small" type="primary" @click="handleConfirm">确 定</el-button>
</span> -->
</GLDialog>
</div>
</template>
<script>
import url from '@/assets/empty.png'
export default {
name: 'selectStore',
data() {
return {
url: url,
searchForm: {
merchantId: '',
merchantName: ''
},
getListApi: this.$apis.common.getMerchantList,
total: 0,
// storeList: [],
heightBox: 200,
merchantId: '',
merchantName: '',
// 搜索
searchFormData: [
{
label: '商户ID',
name: 'merchantId',
type: 'input',
placeholder: '请输入商户ID',
width: '300px',
labelWidth: '10px'
},
{
label: '商户名称',
name: 'merchantName',
type: 'input',
placeholder: '请输入商户名称',
width: '300px',
labelWidth: '10px'
}
],
// 表格
// getListApi: this.$apis.common.getstaffTreeListApi,
tableParams: {
listName: 'list',
// tableOption: true,
// 行数据的key
// mutiSelectUniqueKey: 'staffId',
// checkSelectKey: 'staffId',
// checkSelectVal: [],
// 多选ref的名称
// mutiSelectName: 'list',
tableColumns: [
{
label: '',
prop: '',
width: 80,
addHtml: 'radioHtml'
},
// {
// label: '序号',
// prop: 'idx',
// width: 80
// },
{
label: '商户名称',
prop: 'merchantName',
formatter: cellValue => {
return cellValue.merchantName || '-'
}
}
]
},
pageConf: { pageSize: 'pageSize', pageNum: 'currentPage', totalCount: 'total' },
baseData: {}
}
},
props: {
dialogVisible: {
type: Boolean,
default: false
},
storeSearchForm: {
type: Object
},
merchantInfo: {
required: true
}
// merchantId: {
// type: String,
//
// }
// orderCode: {
// type: String,
// required: true
// }
},
mounted() {
// this.userInfo = this.$globalState.session
let clientHeight = document.documentElement.clientHeight
this.heightBox = clientHeight - 0.15 * clientHeight - 425
this.merchantId = this.merchantInfo
// this.getList()
},
methods: {
getList() {
var params = {
merchantId: this.merchantId,
// merchantId: '44209390',
...this.searchForm
}
// this.$apis.common.getSimpleMerchantList(params).then(res => {
// console.log(res)
// this.storeList = res
// // this.storeList = res.staffUnitList
// // this.total = res.total
// // var page = this.$refs.staffRef.page
// // // 添加序号
// this.storeList.forEach((item, index) => {
// item.idx = index + 1
// })
// this.$refs.staffRef.tableHeightValues = '460px'
// })
},
setTableFinishFun() {
// console.log(this.$refs.staffRef.data)
// this.storeList = this.$refs.staffRef.data
//接收到的数据为空
this.$refs.staffRef.tableHeightValues = '460px'
},
handleClick(val) {
console.log(val)
// let { merchantId, merchantName } =val
this.merchantId = val.merchantNo
this.merchantName = val.merchantName
// let temp = JSON.parse(JSON.stringify(val))
// delete temp.idx
// this.staffUuid = val.uuid
// this.store = val
},
handleClose() {
this.$emit('handleRelateStoreClose')
},
handleConfirm() {
// if (!this.staffUuid)
// return this.$message({
// message: '请先选择员工',
// type: 'error'
// })
// let parmas = {
// subOrderCode: this.orderCode,
// staffUuid: this.staffUuid
// }
// this.$apis.orderManage.signerOrder(parmas).then(res => {
// console.log(res)
// })
// this.staffUuid
this.$emit('handleRelateStoreConfirm', {
merchantId: this.merchantId,
merchantName: this.merchantName
})
}
}
}
</script>
<style lang="scss">
.select-store {
.storeDailog {
width: 500px;
}
.title {
margin-bottom: 12px;
}
.customer-tag-box {
display: flex;
margin: 20px 16px;
.tag-label {
display: inline-block;
height: 30px;
line-height: 30px;
}
.input-tag-wrapper {
max-height: 75px;
overflow: auto;
position: relative;
font-size: 14px;
background-color: #fff;
background-image: none;
border-radius: 4px;
border: 1px solid #dcdfe6;
box-sizing: border-box;
color: #666;
display: inline-block;
outline: none;
padding: 5px;
flex-wrap: wrap;
transition: border-color 0.2s cubic-bezier(0.645, 0.045, 0.355, 1);
width: 648px;
display: flex;
align-items: center;
cursor: pointer;
i {
color: #75acff;
margin-right: 3px;
font-size: 14px;
}
}
}
// .customer-list {
// width: calc(100% - 280px);
// margin-right: 10px;
// }
.p-16 {
padding: 16px;
}
.store-table .el-radio__label {
display: none;
}
}
</style>
<template>
<div class="wechat-box marketing">
<img class="w-100-percent"
src="@/assets/seckillActivity/phone.png" />
<img class="w-100-percent" src="@/assets/seckillActivity/phone.png" />
<div class="wechat-back">
<p class="wechat-name one-line-ellipsis">{{ editForm.activityName }}</p>
<img class="wechat-head"
src="@/assets/seckillActivity/crowd-head.png" />
<img class="icon-server"
src="@/assets/seckillActivity/icon-server.png" />
<img class="wechat-head" src="@/assets/seckillActivity/crowd-head.png" />
<img class="icon-server" src="@/assets/seckillActivity/icon-server.png" />
<div class="wechat-inner-box">
<div class="wechat-banner-img">
<img class="icon-music"
src="@/assets/seckillActivity/icon-music.png" />
<img
:src="editForm.activityBigImg || require('@/assets/seckillActivity/icon-default.png')" />
<img class="wechat-customer"
src="@/assets/seckillActivity/crowd-customer.png" />
<img class="icon-music" src="@/assets/seckillActivity/icon-music.png" />
<img :src="editForm.activityBigImg || require('@/assets/seckillActivity/icon-default.png')" />
<img class="wechat-customer" src="@/assets/seckillActivity/crowd-customer.png" />
<div class="w-100-percent txt-center">
<video v-if="editForm.activityVideoList.length"
class="wechat-video"
controls>
<source :src="editForm.activityVideoList[0]"
type="video/mp4" />
<video v-if="editForm.activityVideoList.length" class="wechat-video" controls>
<source :src="editForm.activityVideoList[0]" type="video/mp4" />
</video>
</div>
<div class="wechat-block">
......@@ -30,51 +21,36 @@
<div>
<p class="m-b-10">{{ editForm.sponsorName }}</p>
<p class="m-b-10 wechat-sub-addr">{{ editForm.activityAddressDetailName }}</p>
<p class="wechat-time"
v-if="editForm.activityTime && editForm.activityTime.length">
活动时间:{{ editForm.activityTime[0].split(' ')[0] }}-{{ editForm.activityTime[1].split(' ')[0] }}
</p>
<p class="wechat-time" v-if="editForm.activityTime && editForm.activityTime.length">活动时间:{{ editForm.activityTime[0].split(' ')[0] }}-{{ editForm.activityTime[1].split(' ')[0] }}</p>
</div>
<img class="icon-addr"
src="@/assets/seckillActivity/icon-addr.png" />
<img class="icon-addr" src="@/assets/seckillActivity/icon-addr.png" />
</div>
</div>
<div class="wechat-block">
<p class="wechat-block-title">{{ countDownObj.typeTxt }}</p>
<p v-if="countDownObj.activityStatus != 3"
class="wechat-count-down">
<span
v-if="editForm.activityTime && editForm.activityTime.length">{{ editForm.activityTime[0].split(' ')[0].split('-')[2] }}</span>
<p v-if="countDownObj.activityStatus != 3" class="wechat-count-down">
<span v-if="editForm.activityTime && editForm.activityTime.length">{{ editForm.activityTime[0].split(' ')[0].split('-')[2] }}</span>
日开始活动,还差
<span class="wechat-txt">{{ countDownObj.d }}</span>
天
<span class="wechat-txt">{{ countDownObj.h }}</span>
时
<span class="wechat-txt">{{ countDownObj.m }}</span>
分
<span class="wechat-txt">{{ countDownObj.s }}</span>
秒
<span class="wechat-txt">{{ countDownObj.d }}</span>天
<span class="wechat-txt">{{ countDownObj.h }}</span>时
<span class="wechat-txt">{{ countDownObj.m }}</span>分
<span class="wechat-txt">{{ countDownObj.s }}</span>秒
</p>
<img v-else
class="count-down-img"
src="@/assets/seckillActivity/count-down.png" />
<img v-else class="count-down-img" src="@/assets/seckillActivity/count-down.png" />
</div>
<div class="w-100-percent txt-center">
<img class="crowd-jdt"
src="@/assets/seckillActivity/crowd-jdt.png" />
<img class="crowd-jdt" src="@/assets/seckillActivity/crowd-jdt.png" />
</div>
<div class="wechat-block service">
<div class="serve"
v-if="editForm.activityServices.length">
<div class="serve" v-if="editForm.activityServices.length">
<div class="box flex">
<div style="width: 26px;">服务</div>
<div class="serve-text flex-center">
<template v-for="(i, index) in editForm.activityServices">
<div :key="index"
class="flex-default">
<div :key="index" class="flex-default">
{{ i.title }}
<span v-if="index != editForm.activityServices.length - 1">·</span>
</div>
......@@ -93,16 +69,12 @@
</div>
<div v-if="editForm.activityExperienceDTOs.length">
<div class="head-box">
<img class="icon-head"
src="@/assets/seckillActivity/icon-default-head.png" />
<img class="icon-head" src="@/assets/seckillActivity/icon-default-head.png" />
<span>虚拟人物1</span>
</div>
<div class="m-t-10">{{ editForm.activityExperienceDTOs[0].experience }}</div>
<div v-if="editForm.activityExperienceDTOs[0].activityExperienceImgs.length">
<img class="img-w-h m-t-10"
v-for="(item, index) in editForm.activityExperienceDTOs[0].activityExperienceImgs"
:key="index"
:src="item" />
<img class="img-w-h m-t-10" v-for="(item, index) in editForm.activityExperienceDTOs[0].activityExperienceImgs" :key="index" :src="item" />
</div>
</div>
</div>
......@@ -129,8 +101,7 @@
</div>
</div>
<div>
<img class="wechat-footer"
src="@/assets/seckillActivity/crowd-footer.png" />
<img class="wechat-footer" src="@/assets/seckillActivity/crowd-footer.png" />
</div>
</div>
</div>
......@@ -147,18 +118,16 @@ export default {
props: {
editForm: {
type: Object,
default: () => {
return {}
}
default: () => { }
},
countDownObj: {
type: Object,
default: () => {
return {}
}
default: () => { }
}
},
mounted() { },
methods: {}
}
</script>
......
......@@ -394,9 +394,10 @@ export default {
// $GLBUTTION_PERMISSIONS: { routes = [], routerBase }
// } = this
// console.log(this.$GLBUTTION_PERMISSIONS)
console.log(this.$GLBUTTION_PERMISSIONS)
// console.log(this.$GLBUTTION_PERMISSIONS)
// debugger
let test = this.__getRoutes(this)
console.log(test, 'test')
// console.log(test, 'test')
},
methods: {
......
......@@ -52,7 +52,7 @@
<el-button :size="size"
class="default-blue-btn"
type="default"
@click="handleExport">导出</el-button>
@click="handleExport('rank')">导出</el-button>
</div>
<GLTable ref="dataTableRef"
:getListApi="getListApi"
......@@ -92,36 +92,23 @@
<el-button :size="size"
class="default-blue-btn"
type="default"
@click="handleExport">导出</el-button>
@click="handleExport('dailyOrders')">导出</el-button>
</div>
<GLTable ref="dataTableRef"
:getListApi="getListApi"
:noDataImg="url"
:searchForm="tableSearchForm"
:tableParams="tableParams"
:pageConf="pageConf"
:beforeSearchFn="beforeSearchFn"
@setTableFinishFun="setTableFinishFun"
:hasNum="false">
<div slot="shareName"
class="flex-align"
slot-scope="scope">
<template v-if="scope.scope.shareAvatar">
<el-popover placement="top"
width="160"
trigger="hover"
popper-class="table-popover-block">
<img class="table-popover-img"
:src="scope.scope.shareAvatar" />
<img class="img-36 pointer"
slot="reference"
:src="scope.scope.shareAvatar" />
</el-popover>
<el-table :data="DailyOrderQuantityListFormat"
style="width: 100%">
<el-table-column :formatter="formatterHeader"
label=""></el-table-column>
<el-table-column v-for="(item, index) in DailyOrderQuantityList"
:key="index"
:prop="item"
width="140px"
:label="item.day">
<template slot-scope="scope">
<span>{{ scope.$index ? item.currentOrderQuantity : item.specificDate }}</span>
</template>
<span class="m-l-10">{{ scope.scope.shareName }}</span>
<span class="m-l-10">{{ scope.scope.sharePhone || '' }}</span>
</div>
</GLTable>
</el-table-column>
</el-table>
</div>
</div>
<div class="data-board-box">
......@@ -130,40 +117,51 @@
<!-- <GLCombiForm ref="rankRef" :rowNumber="1" :formObj="searchRankForm" :formData="searchFormRankData" @handleOk="handleSearchRank"></GLCombiForm> -->
<div class="flex m-b-10 w-100-percent">
<span class="table-title">
当前直播间在线人数:4569737 人已下单 450 人 已下单 450 人
<span>
当前直播间在线人数:
<span class="txt-red">{{ liveInfo.onlineMemberNum }}</span>
人
</span>
<span>
已下单
<span class="txt-red">{{ liveInfo.dealOrderCount }}</span>
人
</span>
<span>
已成交
<span class="txt-red">{{ liveInfo.dealPeopleCount }}</span>
人
</span>
</span>
<el-button :size="size"
class="default-blue-btn"
type="default"
@click="handleExport">导出</el-button>
@click="handleExport('liveData')">导出</el-button>
</div>
<!-- :searchForm="tableSearchForm" -->
<GLTable ref="dataTableRef"
:getListApi="getListApi"
:getListApi="getLiveDetailPage"
:noDataImg="url"
:searchForm="tableSearchForm"
:tableParams="tableParams"
:tableParams="liveTableParams"
:searchForm="LiveTableSearchForm"
:pageConf="pageConf"
:beforeSearchFn="beforeSearchFn"
@setTableFinishFun="setTableFinishFun"
:hasNum="false">
<div slot="shareName"
@setTableFinishFun="setTableFinishFun">
<div slot="weChatName"
class="flex-align"
slot-scope="scope">
<template v-if="scope.scope.shareAvatar">
<el-popover placement="top"
width="160"
trigger="hover"
popper-class="table-popover-block">
<img class="table-popover-img"
:src="scope.scope.shareAvatar" />
<img class="img-36 pointer"
slot="reference"
:src="scope.scope.shareAvatar" />
</el-popover>
</template>
<span class="m-l-10">{{ scope.scope.shareName }}</span>
<span class="m-l-10">{{ scope.scope.sharePhone || '' }}</span>
<img v-if="scope.scope.avatar"
class="img-36 pointer img-circle"
:src="scope.scope.avatar" />
<span class="m-l-10">{{ scope.scope.nickname }}</span>
<span v-if="!scope.scope.avatar && !scope.scope.nickname">-</span>
</div>
<!-- <div slot="orderStatus"
slot-scope="scope">
<span
:class="['table-circle', 'm-r-8', [2, 10, 22].includes(scope.scope.orderStatus) ? 'back-green' : [9].includes(scope.scope.orderStatus) ? 'back-blue' : [1, 21, 6].includes(scope.scope.orderStatus) ? 'back-orange' : 'back-grey']"></span>
<span>{{ baseData.orderStatusList.map(item => item.confId).includes(scope.scope.orderStatus + '') ? baseData.orderStatusList.find(item => item.confId == scope.scope.orderStatus).confName : '-' }}</span>
</div> -->
</GLTable>
</div>
</div>
......@@ -172,7 +170,7 @@
<script>
import * as dayjs from 'dayjs'
import { exportFn } from '@/common/constant'
import { downLoadFile, orderManageStatusList } from '@/common/constant'
import url from '@/assets/empty.png'
const dataList = [
......@@ -200,6 +198,11 @@ export default {
searchForm: {
statDate: dayjs().format('YYYY-MM-DD')
},
// 基本数据
baseData: {
searchOrderStatusList: orderManageStatusList.filter(item => ['1', '3', '21', '22', '6', '9'].includes(item.confId))
},
DailyOrderQuantityListFormat: [{}, {}],
searchFormData: [
{
label: '统计日期',
......@@ -225,6 +228,7 @@ export default {
}
],
getListApi: this.$apis.seckillActivity.getRankListApi,
getLiveDetailPage: this.$apis.seckillActivity.liveroomDetailpage,
tableSearchForm: {},
tableParams: {
listName: 'list',
......@@ -265,12 +269,78 @@ export default {
}
]
},
liveTableParams: {
listName: 'list',
// tableOption: true,
tableColumns: [
{
label: '微信名称',
prop: 'weChatName',
addHtml: 'weChatName'
// width: 210
},
{
label: '手机号',
prop: 'phone',
// width: 160,
formatter: cellValue => {
return cellValue.phone || '-'
}
},
{
label: '浏览时长',
name: 'visitDuration',
prop: 'visitDuration'
// width: 120
// formatter: cellValue => {
// // return dayjs(cellValue.visitDuration).format('YYYY-MM-DD HH:mm:ss')
// }
},
{
label: '进入直播间时间',
name: 'entryTime',
prop: 'entryTime'
// width: 200
// formatter: cellValue => {
// return dayjs(cellValue.entryTime).format('YYYY-MM-DD HH:mm:ss')
// }
},
{
label: '离开直播间时间',
name: 'leaveTime',
prop: 'leaveTime'
// width: 200
// formatter: cellValue => {
// return dayjs(cellValue.leaveTime).format('YYYY-MM-DD HH:mm:ss')
// }
},
{
label: '订单状态',
prop: 'orderStatus',
// addHtml: 'orderStatus',
width: 160
}
]
},
pageConf: { pageSize: 'pageSize', pageNum: 'currentPage', totalCount: 'total' },
dataBoard: {}
dataBoard: {},
activityId: '',
liveInfo: {}
}
},
computed: {
LiveTableSearchForm() {
return {
activityId: this.activityId
}
}
},
created() {
this.activityId = this.$route.query.activityId
// 获取每日订单量统计
this.getDailyOrderQuantityStatistics()
this.getDataBoardApi()
this.getLiveData()
},
mounted() {
let [dataResetBtn] = this.$refs.dataRef.$el.getElementsByClassName('el-button--default'),
......@@ -280,12 +350,42 @@ export default {
},
methods: {
getLiveData() {
this.$apis.seckillActivity
.liveroomOverview({ activityId: this.activityId })
.then(result => {
console.log(result)
this.liveInfo = {
...result
}
})
.catch(err => { })
},
getDataBoardApi() {
let { activityId } = this.$route.query,
{ statDate } = this.searchForm
this.$apis.seckillActivity.getDataBoardApi({ activityId, statDimension: dayjs(statDate).format('YYYY-MM-DD') }).then(res => {
// { activityId } = this.$route.query,
let { statDate } = this.searchForm
this.$apis.seckillActivity.getDataBoardApi({ activityId: this.activityId, statDimension: dayjs(statDate).format('YYYY-MM-DD') }).then(res => {
this.dataBoard = res || {}
})
// 直播间数据统计
// this.getLiveBroadcastRoomDataStatistics()
},
getDailyOrderQuantityStatistics() {
this.$apis.seckillActivity
.getDailyOrderQuantityStatistics({ id: this.activityId })
.then(result => {
console.log(result)
if (result.length) {
this.DailyOrderQuantityList = result.reduce((arr, item, index) => {
return arr
}, [])
}
this.DailyOrderQuantityList = result || []
})
.catch(err => {
console.log(err)
})
},
getParams() {
let { activityId } = this.$route.query,
......@@ -299,12 +399,25 @@ export default {
handleSearchRank() {
this.$refs.dataTableRef.refreshTable()
},
handleExport() {
let params = this.getParams()
this.$apis.seckillActivity.exportRankListApi(params).then(res => {
exportFn(res)
})
handleExport(name) {
if (name == 'rank') {
let params = this.getParams()
this.$apis.seckillActivity.exportRankListApi(params).then(res => {
downLoadFile(res)
})
}
if (name == 'dailyOrders') {
this.$apis.seckillActivity.exportDailyOrderQuantityStatistics({ id: this.activityId }).then(result => {
downLoadFile(result)
})
}
if (name == 'liveData') {
this.$apis.seckillActivity.liveroomDetailexport({ activityId: this.activityId }).then(result => {
downLoadFile(result)
})
}
},
beforeSearchFn() {
return new Promise(resolve => {
this.tableSearchForm = this.getParams()
......@@ -314,6 +427,13 @@ export default {
setTableFinishFun() {
//接收到的数据为空
this.$refs.dataTableRef.data.length ? (this.$refs.dataTableRef.tableHeightValues = '') : this.$refs.dataTableRef.setTableHeightFun()
},
formatterHeader(row, column) {
if (row == 0) {
return '活动日期'
} else {
return '订单量'
}
}
}
}
......
<!-- 众筹活动 -->
<template>
<div v-loading="loading" class="edit-activity">
<div v-loading="loading"
class="edit-activity">
<!-- 导航 -->
<el-tabs :tab-position="tabPosition" v-model="tabName" class="nav-tabs" @tab-click="whereToGo(tabName)">
<el-tab-pane label="基本信息" name="basic"></el-tab-pane>
<el-tab-pane label="活动配置" name="config"></el-tab-pane>
<el-tabs :tab-position="tabPosition"
v-model="tabName"
class="nav-tabs"
@tab-click="whereToGo(tabName)">
<el-tab-pane label="基本信息"
name="basic"></el-tab-pane>
<el-tab-pane label="活动配置"
name="config"></el-tab-pane>
<el-tab-pane name="activityServices">
<span class="p-l-23" slot="label">服务说明</span>
<span class="p-l-23"
slot="label">服务说明</span>
</el-tab-pane>
<el-tab-pane name="activityCommoditys">
<span class="p-l-23" slot="label">商品答疑</span>
<span class="p-l-23"
slot="label">商品答疑</span>
</el-tab-pane>
<el-tab-pane name="activityExperienceDTOs">
<span class="p-l-23" slot="label">玩家心得</span>
<span class="p-l-23"
slot="label">服务评价</span>
</el-tab-pane>
<el-tab-pane name="live">
<span class="p-l-23" slot="label">直播配置</span>
<span class="p-l-23"
slot="label">直播配置</span>
</el-tab-pane>
</el-tabs>
<div class="marketing edit-box">
<!-- 基本信息 -->
<div class="container edit-container" style="min-height: 520px !important;">
<p class="edit-title" id="basic">基本信息</p>
<glsx-combi-form class="edit-form-container" ref="editFormRef" :isEdit="true" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule">
<div slot="activityImg" class="edit-tips m-t-8">展示在首页的活动详情页</div>
<template slot="activityTimeHtml" slot-scope="scope">
<el-date-picker v-model="editForm.activityTime" type="datetimerange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="yyyy-MM-dd HH:mm:ss" :default-time="['00:00:00', '23:59:59']" :disabled="isDisabled" @change="e => handleTimeChange(e, scope.scope)"></el-date-picker>
<div class="container edit-container"
style="min-height: 520px !important;">
<p class="edit-title"
id="basic">基本信息</p>
<glsx-combi-form class="edit-form-container"
ref="editFormRef"
:isEdit="true"
:isBlock="true"
:formRef="editChildRef"
:formObj="editForm"
:formData="editFormData"
:formRules="editRule">
<div slot="merchantHtml">
<el-button type="default"
class="el-icon-plus"
v-if="!isDisabled"
@click="handleRelateStoreClose">选择门店</el-button>
<span v-if="editForm.merchantName"
class="merchantNameLabel">门店名称: {{ editForm.merchantName }}</span>
</div>
<div slot="activityImg"
class="edit-tips m-t-8">展示在首页的活动详情页</div>
<template slot="activityTimeHtml"
slot-scope="scope">
<el-date-picker v-model="editForm.activityTime"
type="datetimerange"
range-separator="至"
start-placeholder="开始日期"
end-placeholder="结束日期"
value-format="yyyy-MM-dd HH:mm:ss"
:default-time="['00:00:00', '23:59:59']"
:disabled="isDisabled"
@change="e => handleTimeChange(e, scope.scope)"></el-date-picker>
</template>
<div slot="goodsHtml">
<el-button type="default" class="el-icon-plus" v-if="!isDisabled" @click="handleRelateProClose">选择商品</el-button>
<div v-if="selectedProInfo.id && !specificationDetailList.length" style="margin-top: 10px">
<el-button type="default"
class="el-icon-plus"
v-if="!isDisabled"
@click="handleRelateProClose">选择商品</el-button>
<div v-if="selectedProInfo.id && !specificationDetailList.length"
style="margin-top: 10px">
<p>
<img class="img-60" :src="selectedProInfo.goodsImage" />
&nbsp;&nbsp;&nbsp; 零售价 {{ (selectedProInfo.retailPrice / 100).toFixed(2) }}元 &nbsp;&nbsp;&nbsp; 商品库存 {{ selectedProInfo.goodsStock }}件
<img class="img-60"
:src="selectedProInfo.goodsImage" />
&nbsp;&nbsp;&nbsp; 零售价 {{ (selectedProInfo.retailPrice / 100).toFixed(2) }}元
&nbsp;&nbsp;&nbsp; 商品库存 {{ selectedProInfo.goodsStock }}件
</p>
<el-form-item label="设置秒杀价:" prop="activityPrice" id="activityPrice">
<el-input v-model="editForm.activityPrice" style="width: 150px" :disabled="isDisabled"><span slot="append">元</span></el-input>
<el-form-item label="定金:"
prop="activityPrice"
id="activityPrice">
<el-input v-model="editForm.activityPrice"
style="width: 150px"
:disabled="isDisabled"><span slot="append">元</span></el-input>
<span class="balancePayment">尾款:
{{ editForm.crowdFundingPrice - editForm.activityPrice || '' }}</span>
</el-form-item>
<el-form-item label="众筹价:"
prop="crowdFundingPrice"
id="crowdFundingPrice">
<el-input v-model="editForm.crowdFundingPrice"
style="width: 150px"
:disabled="isDisabled"><span slot="append">元</span></el-input>
</el-form-item>
<el-form-item label="活动库存:" prop="goodsStock" id="goodsStock">
<el-input v-model="editForm.goodsStock" style="width: 150px" :disabled="isDisabled"><span slot="append">件</span></el-input>
<el-form-item label="活动库存:"
prop="goodsStock"
id="goodsStock">
<el-input v-model="editForm.goodsStock"
style="width: 150px"
:disabled="isDisabled"><span slot="append">件</span></el-input>
</el-form-item>
</div>
</div>
<div slot="specificationsHtml" v-if="specificationDetailList.length" class="flex" style="min-width: 600px" id="specificationDetailList">
<div slot="specificationsHtml"
v-if="specificationDetailList.length"
class="flex"
style="min-width: 600px"
id="specificationDetailList">
<div style="width: calc(100%)">
<table class="table-spesc" style="width: calc(100%)">
<table class="table-spesc"
style="width: calc(100%)">
<tbody>
<tr>
<td :style="{ width: specsWidth }" v-for="(subItem, subIndex) in specificationDetailList" :key="subIndex">{{ subItem.specificationName }}</td>
<td :style="{ width: specsWidth }"
v-for="(subItem, subIndex) in specificationDetailList"
:key="subIndex">{{ subItem.specificationName }}</td>
<td :style="{ width: specsWidth }">零售价(元)</td>
<td :style="{ width: specsWidth }">库存</td>
<td :style="{ width: specsWidth }">设置秒杀价</td>
......@@ -55,31 +123,55 @@
</tr>
</tbody>
</table>
<table class="table-spesc" style="max-height: 400px">
<table class="table-spesc"
style="max-height: 400px">
<tbody>
<tr style="border-bottom: 1px solid rgb(235, 235, 235)" v-for="(item, index) in nameToValSpecsList" :key="index">
<td :style="{ width: specsWidth }" v-for="(n, idx) in item.specsValueList" :key="idx">{{ n }}</td>
<tr style="border-bottom: 1px solid rgb(235, 235, 235)"
v-for="(item, index) in nameToValSpecsList"
:key="index">
<td :style="{ width: specsWidth }"
v-for="(n, idx) in item.specsValueList"
:key="idx">{{ n }}</td>
<td :style="{ width: specsWidth }">{{ item.retailPrice }}元</td>
<td :style="{ width: specsWidth }">{{ item.stock }}件</td>
<td :style="{ width: specsWidth }">
<el-input :disabled="isDisabled" placeholder="秒杀价" style="width: 90%" v-model="item.activityPrice" @input="item.activityPrice = activityPrice_input($event, item.retailPrice)"></el-input>
<el-input :disabled="isDisabled"
placeholder="秒杀价"
style="width: 90%"
v-model="item.activityPrice"
@input="item.activityPrice = activityPrice_input($event, item.retailPrice)">
</el-input>
</td>
<td :style="{ width: specsWidth }">
<el-input :disabled="isDisabled" placeholder="活动库存" style="width: 90%" v-model="item.goodsStock" @input="item.goodsStock = goodsStock_input($event, item.stock)"></el-input>
<el-input :disabled="isDisabled"
placeholder="活动库存"
style="width: 90%"
v-model="item.goodsStock"
@input="item.goodsStock = goodsStock_input($event, item.stock)">
</el-input>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<template slot="limitPurchaseFlag" slot-scope="scope">
<el-radio-group v-model="editForm[scope.scope.name]" @change="handleIsLimit">
<el-radio v-for="(item, index) in scope.scope.optionList" :key="index" :label="item[scope.scope.optionId]" :disabled="isDisabled">{{ item[scope.scope.optionLabel] }}</el-radio>
<template slot="limitPurchaseFlag"
slot-scope="scope">
<el-radio-group v-model="editForm[scope.scope.name]"
@change="handleIsLimit">
<el-radio v-for="(item, index) in scope.scope.optionList"
:key="index"
:label="item[scope.scope.optionId]"
:disabled="isDisabled">{{ item[scope.scope.optionLabel] }}</el-radio>
</el-radio-group>
<p v-if="editForm[scope.scope.name] == 2" id="limitPurchaseNumber" style="color: #333333;">
<p v-if="editForm[scope.scope.name] == 2"
id="limitPurchaseNumber"
style="color: #333333;">
每人限购
<el-form-item prop="limitPurchaseNumber">
<el-input v-model="editForm.limitPurchaseNumber" placeholder="请输入限购次数" :disabled="isDisabled"></el-input>
<el-input v-model="editForm.limitPurchaseNumber"
placeholder="请输入限购次数"
:disabled="isDisabled"></el-input>
</el-form-item>
件
</p>
......@@ -88,35 +180,76 @@
</div>
<!-- 活动配置 -->
<div class="container edit-container crowd-config">
<p class="edit-title" id="config">活动配置</p>
<glsx-combi-form class="edit-form-container" ref="configEditFormRef" :isEdit="true" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="configEditFormData" :formRules="editRule">
<template slot="customerServiceFlag" slot-scope="scope">
<p class="edit-title"
id="config">活动配置</p>
<glsx-combi-form class="edit-form-container"
ref="configEditFormRef"
:isEdit="true"
:isBlock="true"
:formRef="editChildRef"
:formObj="editForm"
:formData="configEditFormData"
:formRules="editRule">
<template slot="customerServiceFlag"
slot-scope="scope">
<el-radio-group v-model="editForm[scope.scope.name]">
<el-radio v-for="(item, index) in scope.scope.optionList" :key="index" :label="item[scope.scope.optionId]">{{ item[scope.scope.optionLabel] }}</el-radio>
<el-radio v-for="(item, index) in scope.scope.optionList"
:key="index"
:label="item[scope.scope.optionId]">{{ item[scope.scope.optionLabel] }}
</el-radio>
</el-radio-group>
<div class="customer-service" v-if="editForm[scope.scope.name] == 2" id="customerServiceFlag">
<glsx-combi-form class="edit-form-container" ref="customerEditFormRef" :isEdit="true" :isBlock="false" :formRef="editChildRef" :formObj="editForm" :formData="customerEditFormData" :formRules="editRule"></glsx-combi-form>
<div class="customer-service"
v-if="editForm[scope.scope.name] == 2"
id="customerServiceFlag">
<glsx-combi-form class="edit-form-container"
ref="customerEditFormRef"
:isEdit="true"
:isBlock="false"
:formRef="editChildRef"
:formObj="editForm"
:formData="customerEditFormData"
:formRules="editRule"></glsx-combi-form>
</div>
</template>
<template slot="activityMusic" slot-scope="scope">
<template slot="activityMusic"
slot-scope="scope">
<div class="flex">
<div class="music-box flex-center" v-for="(item, index) in musicList" :key="index" @click="handleMusicChange(index)">
<div class="music-icon" @click.stop="handleMusic(item, index)">
<div class="music-box flex-center"
v-for="(item, index) in musicList"
:key="index"
@click="handleMusicChange(index)">
<div class="music-icon"
@click.stop="handleMusic(item, index)">
<div :class="[index != playObj.idx ? 'icon-start' : 'icon-stop']"></div>
<img src="@/assets/seckillActivity/icon-music-default.png" />
</div>
<div class="music-name">
<p class="ellipsis-1" style="max-width: 90%;">{{ item.name }}</p>
<p class="ellipsis-1"
style="max-width: 90%;">{{ item.name }}</p>
.mp3
</div>
<img v-show="item.isCheck" :class="{ 'icon-check': item.isCheck }" src="@/assets/seckillActivity/icon-check.png" />
<img v-show="item.isCheck"
:class="{ 'icon-check': item.isCheck }"
src="@/assets/seckillActivity/icon-check.png" />
</div>
</div>
<el-upload class="m-t-10" action="" accept="audio/mp3, audio/m4a" :show-file-list="false" :http-request="handleMusicUpload" :before-upload="e => handleMusicBeforeUpload(e, scope.scope)" :file-list="fileList">
<el-button class="el-icon-plus" size="small" type="default">背景音乐</el-button>
<el-upload class="m-t-10"
action=""
accept="audio/mp3, audio/m4a"
:show-file-list="false"
:http-request="handleMusicUpload"
:before-upload="e => handleMusicBeforeUpload(e, scope.scope)"
:file-list="fileList">
<el-button class="el-icon-plus"
size="small"
type="default">背景音乐</el-button>
</el-upload>
<audio v-if="playObj.src" style="display: none;" id="music-audio" controls>
<source type="audio/mpeg" :src="playObj.src" />
<audio v-if="playObj.src"
style="display: none;"
id="music-audio"
controls>
<source type="audio/mpeg"
:src="playObj.src" />
</audio>
<!-- <div v-if="editForm[scope.scope.name]" class="flex">
<audio controls>
......@@ -126,33 +259,69 @@
</div> -->
</template>
<template slot="fictitious">
<div class="fictitious" id="fictitious">
<el-form-item label="参团:" prop="fictitiousGroupQuantity" labelWidth="60px">
<el-input v-model="editForm.fictitiousGroupQuantity" style="width: 90px" maxlength="50" placeholder="参团人数"></el-input>
<div class="fictitious"
id="fictitious">
<el-form-item label="参团:"
prop="fictitiousGroupQuantity"
labelWidth="60px">
<el-input v-model="editForm.fictitiousGroupQuantity"
style="width: 90px"
maxlength="50"
placeholder="参团人数"></el-input>
</el-form-item>
<el-form-item id="fictitiousLadderQuantity" label="阶梯人数:" prop="fictitiousLadderQuantity" labelWidth="90px">
<el-input v-model="editForm.fictitiousLadderQuantity" style="width: 90px" maxlength="50" placeholder="阶梯人数"></el-input>
<el-form-item id="fictitiousLadderQuantity"
label="阶梯人数:"
prop="fictitiousLadderQuantity"
labelWidth="90px">
<el-input v-model="editForm.fictitiousLadderQuantity"
style="width: 90px"
maxlength="50"
placeholder="阶梯人数"></el-input>
</el-form-item>
<el-form-item id="fictitiousViewQuantity" label="浏览:" prop="fictitiousViewQuantity" labelWidth="60px">
<el-input v-model="editForm.fictitiousViewQuantity" style="width: 90px" maxlength="50" placeholder="浏览人数"></el-input>
<el-form-item id="fictitiousViewQuantity"
label="浏览:"
prop="fictitiousViewQuantity"
labelWidth="60px">
<el-input v-model="editForm.fictitiousViewQuantity"
style="width: 90px"
maxlength="50"
placeholder="浏览人数"></el-input>
</el-form-item>
</div>
</template>
<div slot="activityBigImg" class="edit-tips m-t-8">建议尺寸750*1258</div>
<div slot="activityVideos" class="edit-tips m-t-8">最多上传6个视频</div>
<div slot="posterImg" class="edit-tips m-t-8">建议尺寸640*1008</div>
<div class="form-describe-box" slot="formDescribe">
<div slot="activityBigImg"
class="edit-tips m-t-8">建议尺寸750*1258</div>
<div slot="activityVideos"
class="edit-tips m-t-8">最多上传6个视频</div>
<div slot="posterImg"
class="edit-tips m-t-8">建议尺寸640*1008</div>
<div class="form-describe-box"
slot="formDescribe">
<el-checkbox-group v-model="editForm.formDescribeCheck">
<el-checkbox v-for="(item, index) in formDescribeCheckList" :label="item.value" :key="index">{{ item.label }}</el-checkbox>
<el-checkbox v-for="(item, index) in formDescribeCheckList"
:label="item.value"
:key="index">{{ item.label }}</el-checkbox>
</el-checkbox-group>
<div v-for="(item, index) in formDescribeList" :key="index" class="form-describe flex-default">
<el-input class="describe-input" v-model="item.value" placeholder="请输入" maxlength="20"></el-input>
<div v-for="(item, index) in formDescribeList"
:key="index"
class="form-describe flex-default">
<el-input class="describe-input"
v-model="item.value"
placeholder="请输入"
maxlength="20"></el-input>
<p class="describe-delete">
<img v-show="!(index == 0 && formDescribeList.length == 1)" @click="handleDescribeDelete(index)" src="@/assets/icon-delete.png" />
<img v-show="!(index == 0 && formDescribeList.length == 1)"
@click="handleDescribeDelete(index)"
src="@/assets/icon-delete.png" />
</p>
</div>
<el-button class="btn-basic" v-show="formDescribeList.length < describeNum" :size="size" type="text" @click="handleDescribeAdd">
<img class="icon-add" src="@/assets/seckillActivity/icon-add.png" />
<el-button class="btn-basic"
v-show="formDescribeList.length < describeNum"
:size="size"
type="text"
@click="handleDescribeAdd">
<img class="icon-add"
src="@/assets/seckillActivity/icon-add.png" />
新增表单
</el-button>
</div>
......@@ -163,93 +332,184 @@
</el-radio-group>
</div>
<!-- 服务说明 -->
<div slot="activityServices" id="activityServices" class="flex-default">
<span class="custom-label arrow" slot="label" @click="handleArrow('activityServices')" :style="{ width: defaultLabelWidth }">
<i :class="[arrowFlagObj.activityServices == 'open' ? 'el-icon-caret-bottom' : 'el-icon-caret-right']"></i>
<div slot="activityServices"
id="activityServices"
class="flex-default">
<span class="custom-label arrow"
slot="label"
@click="handleArrow('activityServices')"
:style="{ width: defaultLabelWidth }">
<i
:class="[arrowFlagObj.activityServices == 'open' ? 'el-icon-caret-bottom' : 'el-icon-caret-right']"></i>
服务说明:
</span>
<div class="form-show-box">
<div :class="['btn-box', arrowFlagObj.activityServices == 'open' && editForm.activityServices.length ? 'line' : '']">
<el-button :class="[editForm.activityServices.length < 9 ? 'btn-basic' : 'btn-disable']" :size="size" type="text" @click="handleAddItem('services', 'activityServices', 9)">
<img class="icon-add" src="@/assets/seckillActivity/icon-add.png" />
<div
:class="['btn-box', arrowFlagObj.activityServices == 'open' && editForm.activityServices.length ? 'line' : '']">
<el-button :class="[editForm.activityServices.length < 9 ? 'btn-basic' : 'btn-disable']"
:size="size"
type="text"
@click="handleAddItem('services', 'activityServices', 9)">
<img class="icon-add"
src="@/assets/seckillActivity/icon-add.png" />
新增一项
</el-button>
</div>
<div :class="['form-show-block', arrowFlagObj.activityServices == 'close' ? 'form-close' : 'form-open']">
<div v-for="(item, index) in editForm.activityServices" :key="index" :class="['form-show-item', editForm.activityServices.length > index + 1 ? 'line' : '']">
<glsx-combi-form class="p-t-20" ref="serviceEditFormRef" :formRef="editChildRef" :isEdit="true" :isBlock="true" :formObj="item" :formData="serviceEditFormData" :formRules="serviceEditRule"></glsx-combi-form>
<el-button :class="['btn-basic', 'btn-delete', index == editForm.activityServices.length - 1 ? 'last-btn-delete' : '']" :size="size" type="text" @click="handleDeleteItem('services', 'activityServices', index)">
<img class="icon-add" src="@/assets/icon-delete.png" />
<div
:class="['form-show-block', arrowFlagObj.activityServices == 'close' ? 'form-close' : 'form-open']">
<div v-for="(item, index) in editForm.activityServices"
:key="index"
:class="['form-show-item', editForm.activityServices.length > index + 1 ? 'line' : '']">
<glsx-combi-form class="p-t-20"
ref="serviceEditFormRef"
:formRef="editChildRef"
:isEdit="true"
:isBlock="true"
:formObj="item"
:formData="serviceEditFormData"
:formRules="serviceEditRule"></glsx-combi-form>
<el-button :class="['btn-basic', 'btn-delete', index == editForm.activityServices.length - 1 ? 'last-btn-delete' : '']"
:size="size"
type="text"
@click="handleDeleteItem('services', 'activityServices', index)">
<img class="icon-add"
src="@/assets/icon-delete.png" />
</el-button>
</div>
</div>
</div>
</div>
<!-- 商品答疑 -->
<div slot="activityCommoditys" id="activityCommoditys" class="flex-default">
<span class="custom-label arrow" slot="label" @click="handleArrow('activityCommoditys')" :style="{ width: defaultLabelWidth }">
<i :class="[arrowFlagObj.activityCommoditys == 'open' ? 'el-icon-caret-bottom' : 'el-icon-caret-right']"></i>
<div slot="activityCommoditys"
id="activityCommoditys"
class="flex-default">
<span class="custom-label arrow"
slot="label"
@click="handleArrow('activityCommoditys')"
:style="{ width: defaultLabelWidth }">
<i
:class="[arrowFlagObj.activityCommoditys == 'open' ? 'el-icon-caret-bottom' : 'el-icon-caret-right']"></i>
商品答疑:
</span>
<div class="form-show-box">
<div :class="['btn-box', arrowFlagObj.activityCommoditys == 'open' && editForm.activityCommoditys.length ? 'line' : '']">
<el-button :class="[editForm.activityCommoditys.length < 9 ? 'btn-basic' : 'btn-disable']" :size="size" type="text" @click="handleAddItem('commoditys', 'activityCommoditys', 9)">
<img class="icon-add" src="@/assets/seckillActivity/icon-add.png" />
<div
:class="['btn-box', arrowFlagObj.activityCommoditys == 'open' && editForm.activityCommoditys.length ? 'line' : '']">
<el-button :class="[editForm.activityCommoditys.length < 9 ? 'btn-basic' : 'btn-disable']"
:size="size"
type="text"
@click="handleAddItem('commoditys', 'activityCommoditys', 9)">
<img class="icon-add"
src="@/assets/seckillActivity/icon-add.png" />
新增一项
</el-button>
</div>
<div :class="['form-show-block', arrowFlagObj.activityCommoditys == 'close' ? 'form-close' : 'form-open']">
<div v-for="(item, index) in editForm.activityCommoditys" :key="index" :class="['form-show-item', editForm.activityCommoditys.length > index + 1 ? 'line' : '']">
<glsx-combi-form class="p-t-20" ref="commoditysEditFormRef" :formRef="editChildRef" :isEdit="true" :isBlock="true" :formObj="item" :formData="commoditysEditFormData" :formRules="commoditysEditRule"></glsx-combi-form>
<el-button :class="['btn-basic', 'btn-delete', index == editForm.activityCommoditys.length - 1 ? 'last-btn-delete' : '']" :size="size" type="text" @click="handleDeleteItem('commoditys', 'activityCommoditys', index)">
<img class="icon-add" src="@/assets/icon-delete.png" />
<div
:class="['form-show-block', arrowFlagObj.activityCommoditys == 'close' ? 'form-close' : 'form-open']">
<div v-for="(item, index) in editForm.activityCommoditys"
:key="index"
:class="['form-show-item', editForm.activityCommoditys.length > index + 1 ? 'line' : '']">
<glsx-combi-form class="p-t-20"
ref="commoditysEditFormRef"
:formRef="editChildRef"
:isEdit="true"
:isBlock="true"
:formObj="item"
:formData="commoditysEditFormData"
:formRules="commoditysEditRule"></glsx-combi-form>
<el-button :class="['btn-basic', 'btn-delete', index == editForm.activityCommoditys.length - 1 ? 'last-btn-delete' : '']"
:size="size"
type="text"
@click="handleDeleteItem('commoditys', 'activityCommoditys', index)">
<img class="icon-add"
src="@/assets/icon-delete.png" />
</el-button>
</div>
</div>
</div>
</div>
<!-- 玩家心得 -->
<div slot="activityExperienceDTOs" id="activityExperienceDTOs" class="flex-default">
<span class="custom-label arrow" slot="label" @click="handleArrow('activityExperienceDTOs')" :style="{ width: defaultLabelWidth }">
<i :class="[arrowFlagObj.activityExperienceDTOs == 'open' ? 'el-icon-caret-bottom' : 'el-icon-caret-right']"></i>
玩家心得:
<!-- 服务评价 -->
<div slot="activityExperienceDTOs"
id="activityExperienceDTOs"
class="flex-default">
<span class="custom-label arrow"
slot="label"
@click="handleArrow('activityExperienceDTOs')"
:style="{ width: defaultLabelWidth }">
<i
:class="[arrowFlagObj.activityExperienceDTOs == 'open' ? 'el-icon-caret-bottom' : 'el-icon-caret-right']"></i>
服务评价:
</span>
<div class="form-show-box">
<div :class="['btn-box', arrowFlagObj.activityExperienceDTOs == 'open' && editForm.activityExperienceDTOs.length ? 'line' : '']">
<el-button :class="[editForm.activityExperienceDTOs.length < 9 ? 'btn-basic' : 'btn-disable']" :size="size" type="text" @click="handleAddItem('experiences', 'activityExperienceDTOs', 9)">
<img class="icon-add" src="@/assets/seckillActivity/icon-add.png" />
<div
:class="['btn-box', arrowFlagObj.activityExperienceDTOs == 'open' && editForm.activityExperienceDTOs.length ? 'line' : '']">
<el-button :class="[editForm.activityExperienceDTOs.length < 9 ? 'btn-basic' : 'btn-disable']"
:size="size"
type="text"
@click="handleAddItem('experiences', 'activityExperienceDTOs', 9)">
<img class="icon-add"
src="@/assets/seckillActivity/icon-add.png" />
新增一项
</el-button>
</div>
<div :class="['form-show-block', arrowFlagObj.activityExperienceDTOs == 'close' ? 'form-close' : 'form-open']">
<div v-for="(item, index) in editForm.activityExperienceDTOs" :key="index" :class="['form-show-item', editForm.activityExperienceDTOs.length > index + 1 ? 'line' : '']">
<div
:class="['form-show-block', arrowFlagObj.activityExperienceDTOs == 'close' ? 'form-close' : 'form-open']">
<div v-for="(item, index) in editForm.activityExperienceDTOs"
:key="index"
:class="['form-show-item', editForm.activityExperienceDTOs.length > index + 1 ? 'line' : '']">
<div class="head-box">
<img class="icon-head" src="@/assets/seckillActivity/icon-default-head.png" />
<img class="icon-head"
src="@/assets/seckillActivity/icon-default-head.png" />
<span>虚拟人物{{ index + 1 }}</span>
</div>
<glsx-combi-form class="p-t-20" :formRef="editChildRef" :isEdit="true" :isBlock="true" :formObj="item" :formData="experiencesEditFormData" :formRules="editRule">
<div slot="activityExperienceImgs" class="edit-tips m-t-8">建议尺寸:图片大小不超过5m,最多可添加9张图片</div>
<glsx-combi-form class="p-t-20"
:formRef="editChildRef"
:isEdit="true"
:isBlock="true"
:formObj="item"
:formData="experiencesEditFormData"
:formRules="editRule">
<div slot="activityExperienceImgs"
class="edit-tips m-t-8">建议尺寸:图片大小不超过5m,最多可添加9张图片</div>
</glsx-combi-form>
<el-button :class="['btn-basic', 'btn-delete', index == editForm.activityExperienceDTOs.length - 1 ? 'last-btn-delete' : '']" :size="size" type="text" @click="handleDeleteItem('experiences', 'activityExperienceDTOs', index)">
<img class="icon-add" src="@/assets/icon-delete.png" />
<el-button :class="['btn-basic', 'btn-delete', index == editForm.activityExperienceDTOs.length - 1 ? 'last-btn-delete' : '']"
:size="size"
type="text"
@click="handleDeleteItem('experiences', 'activityExperienceDTOs', index)">
<img class="icon-add"
src="@/assets/icon-delete.png" />
</el-button>
</div>
</div>
</div>
</div>
<!-- 员工注册链接 -->
<div slot="employeeRegistrationLinkFlag" slot-scope="scope">
<div slot="employeeRegistrationLinkFlag"
slot-scope="scope">
<el-radio-group v-model="editForm[scope.scope.name]">
<el-radio v-for="(item, index) in scope.scope.optionList" :key="index" :label="item[scope.scope.optionId]">{{ item[scope.scope.optionLabel] }}</el-radio>
<el-radio v-for="(item, index) in scope.scope.optionList"
:key="index"
:label="item[scope.scope.optionId]">{{ item[scope.scope.optionLabel] }}
</el-radio>
</el-radio-group>
</div>
<template slot="appointmentContacts">
<div class="appointmentContactsClass">
<el-form-item label="姓名:" prop="reservationInstallContactsName" labelWidth="60px">
<el-input v-model="editForm.reservationInstallContactsName" style="width: 432px;display: block;" maxlength="10" placeholder="请输入姓名"></el-input>
<el-form-item label="姓名:"
prop="reservationInstallContactsName"
labelWidth="60px">
<el-input v-model="editForm.reservationInstallContactsName"
style="width: 432px;display: block;"
maxlength="10"
placeholder="请输入姓名"></el-input>
</el-form-item>
<el-form-item label="电话:" prop="reservationInstallContactsPhone" labelWidth="60px" class="phoneClass">
<el-input v-model="editForm.reservationInstallContactsPhone" style="width: 432px" maxlength="11" placeholder="请输入电话"></el-input>
<el-form-item label="电话:"
prop="reservationInstallContactsPhone"
labelWidth="60px"
class="phoneClass">
<el-input v-model="editForm.reservationInstallContactsPhone"
style="width: 432px"
maxlength="11"
placeholder="请输入电话"></el-input>
</el-form-item>
</div>
</template>
......@@ -257,49 +517,122 @@
<template slot="reportConfigure">
<div class="reportConfigure-bag">
<el-tabs v-model="reportFlag">
<el-tab-pane label="进行中战报" name="1">
<el-form-item label="产值活动报告:" prop="produceReportSummary" labelWidth="100px">
<el-input v-model="editForm.activityActionReport.produceReportSummary" placeholder="根据以往经验,活动前三天转发效果最好,赶紧督促大家转发起来吧" type="textarea" maxlength="200" show-word-limit style="width:580px;height:79px;" rows="3"></el-input>
<el-tab-pane label="进行中战报"
name="1">
<el-form-item label="产值活动报告:"
prop="produceReportSummary"
labelWidth="100px">
<el-input v-model="editForm.activityActionReport.produceReportSummary"
placeholder="根据以往经验,活动前三天转发效果最好,赶紧督促大家转发起来吧"
type="textarea"
maxlength="200"
show-word-limit
style="width:580px;height:79px;"
rows="3"></el-input>
</el-form-item>
</el-tab-pane>
<el-tab-pane label="已结束战报" name="2">
<el-form-item label="客户资产分析总结:" prop="customerAssetSummary" labelWidth="140px" style="margin-left: 27px;margin-bottom: 0px;">
<el-input v-model="editForm.activityActionReport.customerAssetSummary" placeholder="请输入" type="textarea" maxlength="200" show-word-limit style="width:580px;height:79px;" rows="3"></el-input>
<el-tab-pane label="已结束战报"
name="2">
<el-form-item label="客户资产分析总结:"
prop="customerAssetSummary"
labelWidth="140px"
style="margin-left: 27px;margin-bottom: 0px;">
<el-input v-model="editForm.activityActionReport.customerAssetSummary"
placeholder="请输入"
type="textarea"
maxlength="200"
show-word-limit
style="width:580px;height:79px;"
rows="3"></el-input>
</el-form-item>
<el-form-item label="触达通道分析总结:" prop="touchPassageSummary" labelWidth="140px" style="margin-left: 27px;margin-top: 10px;">
<el-input v-model="editForm.activityActionReport.touchPassageSummary" placeholder="请输入" type="textarea" maxlength="200" show-word-limit style="width:580px;height:79px;" rows="3"></el-input>
<el-form-item label="触达通道分析总结:"
prop="touchPassageSummary"
labelWidth="140px"
style="margin-left: 27px;margin-top: 10px;">
<el-input v-model="editForm.activityActionReport.touchPassageSummary"
placeholder="请输入"
type="textarea"
maxlength="200"
show-word-limit
style="width:580px;height:79px;"
rows="3"></el-input>
</el-form-item>
<div class="reportConfigureList">
<span class="reportConfigureLabel">标杆门店数据:</span>
<el-form-item label="分享数(次)" prop="signMerchantShareCount" labelWidth="70px" style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.signMerchantShareCount" style="width: 136px;height:32px;" placeholder="请输入"></el-input>
<el-form-item label="分享数(次)"
prop="signMerchantShareCount"
labelWidth="70px"
style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.signMerchantShareCount"
style="width: 136px;height:32px;"
placeholder="请输入"></el-input>
</el-form-item>
<el-form-item label="浏览数(次)" prop="signMerchantBrowseCount" labelWidth="70px" style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.signMerchantBrowseCount" style="width: 136px;height:32px;" placeholder="请输入"></el-input>
<el-form-item label="浏览数(次)"
prop="signMerchantBrowseCount"
labelWidth="70px"
style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.signMerchantBrowseCount"
style="width: 136px;height:32px;"
placeholder="请输入"></el-input>
</el-form-item>
<el-form-item label="访客数(人)" prop="signMerchantVisitorCount" labelWidth="70px" style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.signMerchantVisitorCount" style="width: 136px;height:32px;" placeholder="请输入"></el-input>
<el-form-item label="访客数(人)"
prop="signMerchantVisitorCount"
labelWidth="70px"
style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.signMerchantVisitorCount"
style="width: 136px;height:32px;"
placeholder="请输入"></el-input>
</el-form-item>
<el-form-item label="订单数(单)" prop="signMerchantOrderCount" labelWidth="70px" style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.signMerchantOrderCount" style="width: 136px;height:32px;" placeholder="请输入"></el-input>
<el-form-item label="订单数(单)"
prop="signMerchantOrderCount"
labelWidth="70px"
style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.signMerchantOrderCount"
style="width: 136px;height:32px;"
placeholder="请输入"></el-input>
</el-form-item>
<el-form-item label="总产值(万)" prop="signMerchantProduceCount" labelWidth="70px" style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.signMerchantProduceCount" style="width: 136px;height:32px;" placeholder="请输入"></el-input>
<el-form-item label="总产值(万)"
prop="signMerchantProduceCount"
labelWidth="70px"
style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.signMerchantProduceCount"
style="width: 136px;height:32px;"
placeholder="请输入"></el-input>
</el-form-item>
</div>
<div class="reportConfigureList">
<span class="reportConfigureLabel">短信触达数据:</span>
<el-form-item label="目标客户数(人)" prop="noteTouchCustomerCount" labelWidth="100px" style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.noteTouchCustomerCount" style="width: 136px;height:32px;" placeholder="请输入"></el-input>
<el-form-item label="目标客户数(人)"
prop="noteTouchCustomerCount"
labelWidth="100px"
style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.noteTouchCustomerCount"
style="width: 136px;height:32px;"
placeholder="请输入"></el-input>
</el-form-item>
<el-form-item label="访客数(人)" prop="noteTouchVisitorCount" labelWidth="70px" style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.noteTouchVisitorCount" style="width: 136px;height:32px;" placeholder="请输入"></el-input>
<el-form-item label="访客数(人)"
prop="noteTouchVisitorCount"
labelWidth="70px"
style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.noteTouchVisitorCount"
style="width: 136px;height:32px;"
placeholder="请输入"></el-input>
</el-form-item>
<el-form-item label="订单数(单)" prop="noteTouchOrderCount" labelWidth="70px" style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.noteTouchOrderCount" style="width: 136px;height:32px;" placeholder="请输入"></el-input>
<el-form-item label="订单数(单)"
prop="noteTouchOrderCount"
labelWidth="70px"
style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.noteTouchOrderCount"
style="width: 136px;height:32px;"
placeholder="请输入"></el-input>
</el-form-item>
<el-form-item label="转化率(%)" prop="noteTouchConversionRate" labelWidth="70px" style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.noteTouchConversionRate" style="width: 136px;height:32px;" readonly></el-input>
<el-form-item label="转化率(%)"
prop="noteTouchConversionRate"
labelWidth="70px"
style="margin: 0px 8px 0px 0px;">
<el-input v-model="editForm.activityActionReport.noteTouchConversionRate"
style="width: 136px;height:32px;"
readonly></el-input>
</el-form-item>
</div>
</el-tab-pane>
......@@ -309,28 +642,119 @@
<!-- 直播配置 -->
<div slot="live">
<el-switch v-model="editForm.liveFlag"></el-switch>
<div class="customer-service" v-if="editForm.liveFlag" id="liveFlag">
<glsx-combi-form class="edit-form-container" ref="liveEditFormRef" :formRef="editChildRef" :isEdit="true" :isBlock="false" :formObj="editForm" :formData="liveEditFormData" :formRules="liveEditRule">
<div slot="groupQrCode" class="edit-tips m-t-8">建议尺寸:284*284</div>
<div v-if="!editForm.floatingMaskDiagram" slot="defaultImg" class="default-live-img">
<div class="customer-service"
v-if="editForm.liveFlag"
id="liveFlag">
<glsx-combi-form class="edit-form-container"
ref="liveEditFormRef"
:formRef="editChildRef"
:isEdit="true"
:isBlock="true"
:formObj="editForm"
:formData="liveEditFormData"
:formRules="liveEditRule">
<div slot="groupQrCode"
class="edit-tips m-t-8">注:用于直播间内加群展示;请上传2M以内的jpg、jpeg、png图片,建议图片尺寸284*284</div>
<div v-if="!editForm.floatingMaskDiagram"
slot="defaultImg"
class="default-live-img">
<img :src="defaultFloatingMaskDiagram" />
</div>
<div slot="floatingMaskDiagram" class="edit-tips m-t-8">建议格式:GIF,尺寸228*346</div>
<div slot="floatingMaskDiagram"
class="edit-tips m-t-8">注:用于直播间内浮动元素展示;请上传2M以内的gif、jpg、jpeg、png图片,建议图片尺寸120*176
</div>
<div v-if="!editForm.liveBroadcastRoomCover"
slot="defaultImgCover"
class="default-live-img">
<img :src="defaultImgObj.COVER_LIVE" />
</div>
<div v-if="!editForm.liveBroadcastRoomEndCover"
slot="defaultImgEndCover"
class="default-live-img">
<img :src="defaultImgObj.COVER_REPLAY" />
</div>
<div slot="liveBroadcastRoomEndCover"
class="edit-tips m-t-8">注:用于活动中直播小窗口展示;请上传2M以内的gif、jpg、jpeg、png图片,建议图片尺寸164*252
</div>
</glsx-combi-form>
</div>
</div>
<!-- 收款模式 -->
<div slot="paymentModel"
class="paymentModelSlot">
<el-radio-group v-model="editForm.payMentModel">
<el-radio :label="1">广联收定金和尾款</el-radio>
<el-radio :label="2">广联收定金门店收尾款</el-radio>
<el-radio :label="3">广联收定金门店收全款退定金</el-radio>
<el-radio :label="4">门店收定金和尾款</el-radio>
</el-radio-group>
</div>
</glsx-combi-form>
</div>
<GLFooter>
<el-button @click="handleCancel" size="medium">{{ routeInfo.addOrEdit != 'detail' ? '取消' : '返回' }}</el-button>
<el-button @click="handleWechat" size="medium">预览</el-button>
<el-button v-if="routeInfo.addOrEdit != 'detail'" type="primary" @click="handleConfirm" size="medium" :loading="loading">提交</el-button>
<el-button @click="handleCancel"
size="medium">{{ routeInfo.addOrEdit != 'detail' ? '取消' : '返回' }}</el-button>
<el-button @click="handleWechat"
size="medium">预览</el-button>
<el-button v-if="routeInfo.addOrEdit != 'detail'"
type="primary"
@click="handleConfirm"
size="medium"
:loading="loading">提交</el-button>
</GLFooter>
<!-- 展示 -->
<GLDialog bigTitle="预览" mode="big" :visible.sync="wechatVisible" @onOk="handleWechat" @onCancel="handleWechat">
<crowdEditWechat ref="crowdEditWechat" :editForm="editForm" :countDownObj="countDownObj"></crowdEditWechat>
<GLDialog bigTitle="预览"
mode="big"
:visible.sync="wechatVisible"
@onOk="handleWechat"
@onCancel="handleWechat">
<crowdEditWechat ref="crowdEditWechat"
:editForm="editForm"
:countDownObj="countDownObj"></crowdEditWechat>
</GLDialog>
<select-single-pro-dialog v-if="isSingleSelectVisible" :isSingleSelectVisible="isSingleSelectVisible" :selectedProInfo="selectedProInfo" @handleSingleSelectConfirm="handleSingleSelectConfirm" @handleSingleSelectClose="handleSingleSelectClose(true)"></select-single-pro-dialog>
<select-single-pro-dialog v-if="isSingleSelectVisible"
:merchantId="editForm.merchantId"
:isSingleSelectVisible="isSingleSelectVisible"
:propSearch="{ deliveryType: 1 }"
:selectedProInfo="selectedProInfo"
@handleSingleSelectConfirm="handleSingleSelectConfirm"
@handleSingleSelectClose="handleSingleSelectClose(true)">
</select-single-pro-dialog>
<!-- :storeSelected="selectedList" -->
<select-store v-if="relateStoreVisible"
ref="relateStore"
:dialogVisible="relateStoreVisible"
:storeSelected="selectedList"
:merchantInfo="editForm.merchantId"
@handleRelateStoreConfirm="handleRelateStoreConfirm"
@handleRelateStoreClose="handleRelateStoreClose">
<!-- <el-row slot>
<el-form :model="storeSearchForm"
ref="relate"
:inline="true"
label-width="90px">
<el-form-item label="商户ID:"
prop="merchantId">
<el-input :size="size"
v-model.trim="storeSearchForm.merchantId"
placeholder="请输入商户ID"
clearable></el-input>
</el-form-item>
<el-form-item label="门店名称:"
prop="merchantName">
<el-input :size="size"
v-model.trim="storeSearchForm.merchantName"
placeholder="请输入门店名称"
clearable></el-input>
</el-form-item>
<el-form-item>
<el-button :size="size"
type="primary"
@click="handleSearchStore">搜索</el-button>
</el-form-item>
</el-form>
</el-row> -->
</select-store>
</div>
</div>
</template>
......@@ -338,13 +762,15 @@
<script>
import { limitPrice } from '@/common/constant'
import crowdEditWechat from './crowdEditWechat.vue'
import selectStore from './components/selectStore'
export default {
name: 'editActivity',
components: {
crowdEditWechat
crowdEditWechat,
selectStore
},
data() {
var validatorPhone = function(rule, value, callback) {
var validatorPhone = function (rule, value, callback) {
if (value && !/^(0|86|17951)?(13[0-9]|15[0123456789]|17[678]|18[0-9]|14[57])[0-9]{8}$/.test(value)) {
callback(new Error('手机号格式错误'))
} else {
......@@ -389,15 +815,20 @@ export default {
s: ''
},
isDisabled: false,
// 预览
wechatVisible: false,
// 商品选择
isSingleSelectVisible: false,
wechatVisible: false, // 预览
isSingleSelectVisible: false, // 商品选择
relateStoreVisible: false, // 选择门店
selectedList: [],
selectedProInfo: {},
specificationDetailList: [],
nameToValSpecsList: [],
activityInfo: {},
editForm: {
merchantId: '',
merchantName: '',
activityName: '',
activityImg: '',
promotion: '',
......@@ -409,7 +840,7 @@ export default {
limitPurchaseNumber: '',
goodsCategory: '',
// 活动配置
customerServiceFlag: 1,
customerServiceFlag: 3,
customerServiceName: '',
customerServicePhone: '',
customerServiceQrImg: '',
......@@ -446,10 +877,14 @@ export default {
liveBroadcastRoomId: '',
groupQrCode: '',
floatingMaskDiagram: '',
liveBroadcastRoomCover: '',
liveBroadcastRoomEndCover: '',
employeeRegistrationLinkFlag: 2,
reservationInstallContactsName: '',
reservationInstallContactsPhone: '',
targetStock: '',
paymentAccountId: '',
paymentModel: 1,
// 战报内容配置
activityActionReport: {
produceReportSummary: '',
......@@ -492,6 +927,7 @@ export default {
// selectedAllProList: [],
// selectedProList: [],
editRule: {
merchantId: [{ required: true, message: '请选择商户', trigger: 'change' }],
activityName: [{ required: true, message: '请输入活动名称', trigger: 'change' }],
activityImg: [{ required: true, message: '请选择活动宣传图', trigger: 'change' }],
promotion: [{ required: true, message: '请输入活动宣传语', trigger: 'change' }],
......@@ -538,7 +974,8 @@ export default {
],
activityBigImg: [{ 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' }]
},
// 表单设置
formDescribeCheckList: [
......@@ -570,6 +1007,11 @@ export default {
// 基本信息
editFormData: [
{
label: '门店',
name: 'merchantId',
addHtml: 'merchantHtml'
},
{
label: '活动名称',
name: 'activityName',
type: 'input',
......@@ -767,14 +1209,14 @@ export default {
maxlength: 80
}
],
// 玩家心得Obj
// 服务评价Obj
experiencesObj: {
name: '',
imageUrl: '',
experience: '',
activityExperienceImgs: []
},
// 玩家心得
// 服务评价
experiencesEditFormData: [
{
label: '心得内容',
......@@ -858,6 +1300,10 @@ export default {
optionLabel: 'confName',
optionList: [
{
confId: 3,
confName: '不显示'
},
{
confId: 1,
confName: '同步在线客服'
},
......@@ -1078,6 +1524,20 @@ export default {
label: '直播配置',
name: 'live',
addHtml: 'live'
},
{
label: '定金收款账户',
name: 'paymentAccountId',
type: 'select',
tips: '定金收款账户只包含定金需要支付的目标账户',
optionId: 'id',
optionLabel: 'accountName',
optionList: []
},
{
label: '收款模式',
name: 'paymentModel',
addHtml: 'paymentModel'
}
],
//直播配置
......@@ -1120,30 +1580,46 @@ export default {
name: 'floatingMaskDiagram',
type: 'upload',
width: '320px',
limitSize: 5,
limitSize: 2,
maxPhotoNum: 1,
supportGif: true,
prefixSlot: 'defaultImg',
suffixSlot: 'floatingMaskDiagram',
handleUpload: (e, file, targetItem) => {
const imgFile = e.target.result,
target = file.type == 'image/gif' ? 'uploadVideoApi' : 'uploadImgApi'
const base64 = file.name.split('.')[file.name.split('.').length - 1] + '@' + imgFile.split(',')[1]
this.loading = true
this.$apis.common[target]({ file: base64 })
.then(res => {
this.editForm[targetItem.name] = res
this.$refs.editFormRef.$refs[this.editChildRef].validateField(targetItem.name)
})
.finally(() => {
this.loading = false
})
this.uploadImgOrGif(e, file, targetItem)
}
},
{
label: '直播缩略图',
name: 'liveBroadcastRoomCover',
type: 'upload',
width: '320px',
limitSize: 2,
maxPhotoNum: 1,
supportGif: true,
prefixSlot: 'defaultImgCover',
handleUpload: (e, file, targetItem) => {
this.uploadImgOrGif(e, file, targetItem)
}
},
{
label: '回放缩略图',
name: 'liveBroadcastRoomEndCover',
type: 'upload',
width: '320px',
limitSize: 2,
maxPhotoNum: 1,
supportGif: true,
prefixSlot: 'defaultImgEndCover',
suffixSlot: 'liveBroadcastRoomEndCover',
handleUpload: (e, file, targetItem) => {
this.uploadImgOrGif(e, file, targetItem)
}
}
],
liveEditRule: {
liveBroadcastRoomId: [{ required: true, message: '请选择直播', trigger: 'change' }],
groupQrCode: [{ required: true, message: '请选择加群二维码', trigger: 'change' }],
// groupQrCode: [{ required: true, message: '请选择加群二维码', trigger: 'change' }],
floatingMaskDiagram: [
{
required: true,
......@@ -1151,8 +1627,28 @@ export default {
callback()
}
}
],
liveBroadcastRoomCover: [
{
required: true,
validator: (rule, value, callback) => {
callback()
}
}
],
liveBroadcastRoomEndCover: [
{
required: true,
validator: (rule, value, callback) => {
callback()
}
}
]
},
defaultImgObj: Object.freeze({
COVER_LIVE: 'https://img02.glsx.com.cn/weapp/resource/scrm-mobile/crowdfunding/COVER_LIVE.gif',
COVER_REPLAY: 'https://img02.glsx.com.cn/weapp/resource/scrm-mobile/crowdfunding/COVER_REPLAY.gif'
}),
defaultFloatingMaskDiagram: 'https://wx.glsx.com.cn/upload/biz/ba63349f-8e9e-4e80-be3b-45cc38dcf13f.gif'
}
},
......@@ -1161,7 +1657,7 @@ export default {
this.getLiveList()
this.setMinHeight('.crowd-config')
this.routeInfo = this.$route.query
this.routeInfo.addOrEdit != 'add' ? this.getInfo() : ''
this.routeInfo.addOrEdit != 'add' ? this.getInfo() : this.getPayList()
var id = this.routeInfo.id
var detailDisableList = ['editFormData']
if (id) {
......@@ -1176,6 +1672,7 @@ export default {
true
)
})
this.changeFormAttr('configEditFormData', 'isDisabled', ['定金收款账户'], true)
}
}
},
......@@ -1200,7 +1697,7 @@ export default {
this.editForm.predictVolume = limitPrice(newValue, oldValue, 7, 2, 0, 1000000)
},
'editForm.fictitiousGroupQuantity'(newValue, oldValue) {
this.editForm.fictitiousGroupQuantity = limitPrice(newValue, oldValue, 3, 0, 0, 100)
this.editForm.fictitiousGroupQuantity = limitPrice(newValue, oldValue, 3, 0, 0, 501)
},
'editForm.fictitiousLadderQuantity'(newValue, oldValue) {
this.editForm.fictitiousLadderQuantity = limitPrice(newValue, oldValue, 7, 0, 0)
......@@ -1277,6 +1774,21 @@ export default {
}
},
uploadImgOrGif(e, file, targetItem) {
const imgFile = e.target.result,
target = file.type == 'image/gif' ? 'uploadVideoApi' : 'uploadImgApi'
const base64 = file.name.split('.')[file.name.split('.').length - 1] + '@' + imgFile.split(',')[1]
this.loading = true
this.$apis.common[target]({ file: base64 })
.then(res => {
this.editForm[targetItem.name] = res
this.$refs.editFormRef.$refs[this.editChildRef].validateField(targetItem.name)
})
.finally(() => {
this.loading = false
})
},
addZero(i) {
return i < 10 ? `0${i}` : `${i}`
},
......@@ -1332,7 +1844,22 @@ export default {
}
}
},
// 选择门店
handleRelateStoreClose() {
// console.log('handleRelateStoreClose')
// this.selectedList = this.$common.utils.deepClone(this.editForm.supplyMerchantList)
this.relateStoreVisible = !this.relateStoreVisible
},
handleRelateStoreConfirm(selectedData) {
// this.editForm.supplyMerchantList = selectedData
selectedData.merchantId && (this.editForm.merchantId = selectedData.merchantId)
selectedData.merchantName && (this.editForm.merchantName = selectedData.merchantName)
// this.selectedList = selectedData
this.handleRelateStoreClose()
},
handleSearchStore() {
this.$refs.relateStore.handleCurrentChange(1)
},
handleTimeChange(value, targetItem) {
!value && (this.editForm[targetItem.name] = [])
},
......@@ -1348,6 +1875,8 @@ export default {
this.editFormData[idx].isHide = val != 2
},
handleRelateProClose(targetItem) {
// 先选门店在选商品
if (this.editForm.merchantId) return this.$message.error('请先选择门店!')
this.selectedProInfo = this.editForm.goodsId ? { id: this.editForm.goodsId } : {}
this.handleSingleSelectClose()
},
......@@ -1482,7 +2011,7 @@ export default {
},
// 音乐
handleMusicUpload() {},
handleMusicUpload() { },
musicUpload(e, targetItem) {
var reader = new FileReader()
......@@ -1605,7 +2134,7 @@ export default {
}
},
// 服务说明,商品答疑,玩家心得
// 服务说明,商品答疑,服务评价
handleAddItem(attr, formAttr, limitNum) {
if (this.editForm[formAttr].length >= limitNum) {
return true
......@@ -1729,7 +2258,7 @@ export default {
if (!this.formDescribeList.length) {
this.formDescribeList = [{ value: '' }]
}
// 玩家心得
// 服务评价
if (this.editForm.activityExperienceDTOs.length) {
this.editForm.activityExperienceDTOs.forEach((item, index) => {
item.idx = index
......@@ -1738,7 +2267,7 @@ export default {
}
// 复制
if (this.routeInfo.addOrEdit == 'copy') {
let resetArr = [{ name: 'id' }, { name: 'activityTime', type: 'array' }, { name: 'liveBroadcastRoomId' }, { name: 'groupQrCode' }, { name: 'floatingMaskDiagram' }, { name: 'selectedProInfo', type: 'Object' }, { name: 'goodsId' }, { name: 'activityPrice' }, { name: 'goodsStock' }]
let resetArr = [{ name: 'id' }, { name: 'activityTime', type: 'array' }, { name: 'liveBroadcastRoomId' }, { name: 'groupQrCode' }, { name: 'floatingMaskDiagram' }, { name: 'liveBroadcastRoomCover' }, { name: 'liveBroadcastRoomEndCover' }, { name: 'selectedProInfo', type: 'Object' }, { name: 'goodsId' }, { name: 'activityPrice' }, { name: 'goodsStock' }]
this.copyReset(resetArr)
}
// 兼容以前众筹活动没有战报内容配置,展示页面
......@@ -1766,6 +2295,7 @@ export default {
if (this.editForm.activityActionReport.noteTouchConversionRate) {
this.editForm.activityActionReport.noteTouchConversionRate = (info.activityActionReport.noteTouchConversionRate / 100).toFixed(2)
}
this.getPayList()
this.$nextTick(() => {
this.editStatus = false
})
......@@ -1814,7 +2344,7 @@ export default {
delete param.activityPrice
delete param.goodsStock
param.specificationDetailList = []
this.nameToValSpecsList.forEach(function(item) {
this.nameToValSpecsList.forEach(function (item) {
var obj = {
retailPrice: (item.activityPrice * 100).toFixed(0), //存的分,需乘100
stock: item.goodsStock,
......@@ -1849,10 +2379,13 @@ export default {
//直播
if (param.liveFlag) {
if (!param.floatingMaskDiagram) param.floatingMaskDiagram = this.defaultFloatingMaskDiagram
if (!param.liveBroadcastRoomCover) param.liveBroadcastRoomCover = this.defaultImgObj.COVER_LIVE
if (!param.liveBroadcastRoomEndCover) param.liveBroadcastRoomEndCover = this.defaultImgObj.COVER_REPLAY
} else {
param.liveBroadcastRoomId = ''
param.groupQrCode = ''
param.floatingMaskDiagram = ''
let resetAttr = this.liveEditFormData.map(item => item.name)
resetAttr.forEach(item => {
param[item] = ''
})
}
// 标杆门店总产值/元(已结束战报)
if (param.activityActionReport.signMerchantProduceCount) {
......@@ -2065,7 +2598,7 @@ export default {
.then(() => {
this.cancelJump()
})
.catch(() => {})
.catch(() => { })
} else {
this.cancelJump()
}
......@@ -2085,6 +2618,16 @@ export default {
})
this.liveEditFormData.find(item => item.name == 'liveBroadcastRoomId').optionList = staff
})
},
// 定金收款账户
getPayList() {
this.$apis.seckillActivity.getPayListApi({}).then(res => {
this.configEditFormData.find(item => item.name == 'paymentAccountId').optionList = res
this.editForm.paymentAccountId = this.editForm.paymentAccountId || res.find(item => item.isDefault == 'Y').id
this.$nextTick(() => {
this.editStatus = false
})
})
}
}
}
......@@ -2099,6 +2642,12 @@ export default {
text-align: right;
padding-right: 12px;
}
.edit-activity .el-form-item__content {
width: auto;
}
#customerServiceFlag .el-form-item__content .el-radio-group {
width: 400px;
}
.edit-product-dh .table-spesc {
width: 100%;
text-align: center;
......@@ -2107,7 +2656,10 @@ export default {
.edit-product-dh .table-spesc tbody tr {
border: 1px solid #e7e7e7;
}
.merchantNameLabel {
color: #606266;
margin-left: 50px;
}
.edit-product-dh .table-spesc tbody td {
display: inline-block;
box-sizing: border-box;
......@@ -2141,8 +2693,8 @@ export default {
min-height: 680px;
}
.edit-activity .customer-service {
width: 656px;
padding: 20px 20px 0 20px;
width: 766px;
padding: 20px 20px 2px 20px;
background: #f9f9f9;
}
.edit-activity .music-box {
......@@ -2306,6 +2858,7 @@ export default {
opacity: 0.1;
}
}
.btn-box {
padding: 0 20px 2px;
}
......@@ -2316,6 +2869,10 @@ export default {
width: auto !important;
}
}
.balancePayment {
margin-left: 100px;
color: #666;
}
.el-switch {
.el-switch__core {
width: 44px !important;
......@@ -2359,8 +2916,8 @@ export default {
display: inline-block;
border-radius: 4px;
cursor: pointer;
margin-right: 8px;
position: relative;
margin: 10px 8px 0 0;
&::after {
position: absolute;
right: 0;
......@@ -2437,4 +2994,10 @@ export default {
}
}
}
.paymentModelSlot {
.el-radio {
margin-top: 10px;
}
}
</style>
......@@ -98,13 +98,6 @@ export default {
optionId: 'confId',
optionLabel: 'confName',
optionsName: 'statusList'
},
{
label: '门店',
name: 'merchantName',
type: 'input',
width: '215px',
maxlength: 20
}
],
// 表格按钮
......@@ -212,11 +205,6 @@ export default {
addHtml: 'activityImg'
},
{
label: '门店',
prop: 'merchantName',
width: 220
},
{
label: '浏览量(次)',
prop: 'viewAmount',
width: 140
......@@ -226,14 +214,6 @@ export default {
prop: 'saleAmount'
},
{
label: '退单数',
prop: 'chargeBackNumber'
},
{
label: '核销数',
prop: 'verificationNumber'
},
{
label: '秒杀价(元)',
name: 'activityPrice',
width: 140,
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!