Commit c4687838 by chenwq

众筹活动

1 parent 199af93c
...@@ -124,7 +124,8 @@ const afterSaleStatusList = [ ...@@ -124,7 +124,8 @@ const afterSaleStatusList = [
const orderSourceList = [ const orderSourceList = [
{ confId: '1', confName: '商城订单' }, { confId: '1', confName: '商城订单' },
{ confId: '2', confName: '直播订单' }, { confId: '2', confName: '直播订单' },
{ confId: '3', confName: '秒杀订单' } { confId: '3', confName: '秒杀订单' },
{ confId: '4', confName: '众筹订单' }
] ]
const deliveryTypeList = [ const deliveryTypeList = [
......
...@@ -135,7 +135,8 @@ export default { ...@@ -135,7 +135,8 @@ export default {
orderSource: '', orderSource: '',
deliveryType: '', deliveryType: '',
vin: '', vin: '',
shareStaffName: '' shareStaffName: '',
shareStaffType: ''
}, },
tableSearchForm: {}, tableSearchForm: {},
statisticsInfo: { statisticsInfo: {
...@@ -276,12 +277,12 @@ export default { ...@@ -276,12 +277,12 @@ export default {
}, },
{ {
label: '推荐人类型', label: '推荐人类型',
name: 'orderSource', name: 'shareStaffType',
type: 'select', type: 'select',
optionList: [], optionList: [],
optionId: 'confId', optionId: 'confId',
optionLabel: 'confName', optionLabel: 'confName',
optionsName: 'orderSourceList' optionsName: 'shareStaffTypeList'
} }
], ],
// 快递信息 // 快递信息
...@@ -468,6 +469,22 @@ export default { ...@@ -468,6 +469,22 @@ export default {
} }
}, },
{ {
label: '支付时间',
prop: 'payDate',
width: '180',
formatter: cellValue => {
return cellValue.payDate ? dayjs(cellValue.payDate).format('YYYY-MM-DD HH:mm:ss') : '-'
}
},
{
label: '核销时间',
prop: 'verificationDate',
width: '180',
formatter: cellValue => {
return cellValue.verificationDate ? dayjs(cellValue.verificationDate).format('YYYY-MM-DD HH:mm:ss') : '-'
}
},
{
label: '客户名称', label: '客户名称',
prop: 'customerName', prop: 'customerName',
line: 2, line: 2,
...@@ -498,10 +515,10 @@ export default { ...@@ -498,10 +515,10 @@ export default {
}, },
{ {
label: '推荐人类型', label: '推荐人类型',
prop: 'shareStaffName', prop: 'shareStaffType',
width: '180', width: '180',
formatter: cellValue => { formatter: cellValue => {
return cellValue.shareStaffName || '-' return this.baseData.shareStaffTypeList.map(item => item.confId).includes(cellValue.shareStaffType + '') ? this.baseData.shareStaffTypeList.find(item => item.confId == cellValue.shareStaffType).confName : '-'
} }
}, },
{ {
...@@ -555,6 +572,10 @@ export default { ...@@ -555,6 +572,10 @@ export default {
refundTypeList: [ refundTypeList: [
{ confId: '1', confName: '退款退货' }, { confId: '1', confName: '退款退货' },
{ confId: '2', confName: '我要退款(无需退货)' } { confId: '2', confName: '我要退款(无需退货)' }
],
shareStaffTypeList: [
{ confId: '1', confName: '个微' },
{ confId: '2', confName: '企微' }
] ]
} }
} }
...@@ -850,7 +871,8 @@ export default { ...@@ -850,7 +871,8 @@ export default {
orderSource: '', orderSource: '',
deliveryType: '', deliveryType: '',
vin: '', vin: '',
shareStaffName: '' shareStaffName: '',
shareStaffType: ''
} }
this.handleSearch() this.handleSearch()
} }
......
...@@ -185,6 +185,10 @@ export default { ...@@ -185,6 +185,10 @@ export default {
refundTypeList: [ refundTypeList: [
{ confId: '1', confName: '退款退货' }, { confId: '1', confName: '退款退货' },
{ confId: '2', confName: '退款不退货' } { confId: '2', confName: '退款不退货' }
],
shareStaffTypeList: [
{ confId: '1', confName: '个微' },
{ confId: '2', confName: '企微' }
] ]
} }
} }
...@@ -220,12 +224,16 @@ export default { ...@@ -220,12 +224,16 @@ export default {
getInfo() { getInfo() {
this.$apis.orderManage.getOrderDetailApi({ orderCode: this.routeInfo.orderCode }).then(res => { this.$apis.orderManage.getOrderDetailApi({ orderCode: this.routeInfo.orderCode }).then(res => {
this.detailForm = res this.detailForm = res
console.log(this.detailForm)
this.orderRefund = res.orderRefund || null this.orderRefund = res.orderRefund || null
this.detailForm.createdDateStr = dayjs(this.detailForm.createdDate).format('YYYY-MM-DD HH:mm:ss') this.detailForm.createdDateStr = dayjs(this.detailForm.createdDate).format('YYYY-MM-DD HH:mm:ss')
if (this.orderRefund) { if (this.orderRefund) {
this.orderRefund.refundTypeName = this.baseData.refundTypeList.map(item => item.confId).includes(res.orderRefund.refundType + '') ? this.baseData.refundTypeList.find(item => item.confId == res.orderRefund.refundType).confName : '-' this.orderRefund.refundTypeName = this.baseData.refundTypeList.map(item => item.confId).includes(res.orderRefund.refundType + '') ? this.baseData.refundTypeList.find(item => item.confId == res.orderRefund.refundType).confName : '-'
this.orderRefund.createdDateStr = dayjs(this.orderRefund.createdDate).format('YYYY-MM-DD HH:mm:ss') this.orderRefund.createdDateStr = dayjs(this.orderRefund.createdDate).format('YYYY-MM-DD HH:mm:ss')
} }
if (this.detailForm.shareStaffType) {
this.baseData.shareStaffTypeList.map(item => item.confId).includes(this.detailForm.shareStaffType + '') ? this.baseData.shareStaffTypeList.find(item => item.confId == this.detailForm.shareStaffType).confName : '-'
}
if (this.detailForm.subOrderCoupon) { if (this.detailForm.subOrderCoupon) {
this.detailForm.subOrderCoupon.discountAmount = (this.detailForm.subOrderCoupon.discountAmount / 100).toFixed(2) this.detailForm.subOrderCoupon.discountAmount = (this.detailForm.subOrderCoupon.discountAmount / 100).toFixed(2)
} }
......
...@@ -198,8 +198,7 @@ ...@@ -198,8 +198,7 @@
</el-radio-group> </el-radio-group>
</template> </template>
<template slot="serviceDescHtml"> <template slot="serviceDescHtml">
<el-input type="textarea" v-model="editForm.serviceDesc" style="width: 320px" placeholder="请输入商品描述" <el-input type="textarea" v-model="editForm.serviceDesc" style="width: 320px" placeholder="请输入商品描述" :autosize="{ minRows: 2, maxRows: 4 }" maxlength="30" :disabled="isDisabled" />
:autosize="{ minRows: 2, maxRows: 4 }" maxlength="30" :disabled="isDisabled" />
</template> </template>
<div slot="selectMerchant" slot-scope="scope" class="select-merchant"> <div slot="selectMerchant" slot-scope="scope" class="select-merchant">
<div> <div>
...@@ -516,7 +515,7 @@ export default { ...@@ -516,7 +515,7 @@ export default {
// 带货是否选择全部商户(0:否,1:是) // 带货是否选择全部商户(0:否,1:是)
takeAllMerchant: '1', takeAllMerchant: '1',
supplyMerchantList: [], supplyMerchantList: [],
serviceDesc:'' serviceDesc: ''
}, },
isEdit: true, isEdit: true,
labelWidth: '144px', labelWidth: '144px',
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
<glsx-combi-form class="edit-form-container" ref="editFormRef" :isEdit="true" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule"> <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> <div slot="activityImg" class="edit-tips m-t-8">展示在首页的活动详情页</div>
<template slot="activityTimeHtml"> <template slot="activityTimeHtml">
<el-date-picker style="width: 474px" v-model="editForm.activityTime" type="datetimerange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="yyyy-MM-dd HH:mm:ss" :picker-options="pickerOptions" :default-time="['00:00:00', '23:59:59']" :disabled="isDisabled" clearable></el-date-picker> <el-date-picker style="width: 474px" v-model="editForm.activityTime" type="datetimerange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="yyyy-MM-dd HH:mm:ss" :picker-options="pickerOptions" :default-time="['00:00:00', '23:59:59']" :disabled="isDisabled" :clearable="false"></el-date-picker>
</template> </template>
<div slot="goodsHtml"> <div slot="goodsHtml">
<el-button type="default" class="default-blue-btn el-icon-plus" v-if="apear != 'see'" @click="handleRelateProClose">选择商品</el-button> <el-button type="default" class="default-blue-btn el-icon-plus" v-if="apear != 'see'" @click="handleRelateProClose">选择商品</el-button>
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
<glsx-combi-form class="edit-form-container" ref="editFormRef" :isEdit="true" :isBlock="true" :formRef="editChildRef" :formObj="editForm" :formData="editFormData" :formRules="editRule"> <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> <div slot="activityImg" class="edit-tips m-t-8">展示在首页的活动详情页</div>
<template slot="activityTimeHtml"> <template slot="activityTimeHtml">
<el-date-picker style="width: 474px" v-model="editForm.activityTime" type="datetimerange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="yyyy-MM-dd HH:mm:ss" :picker-options="pickerOptions" :default-time="['00:00:00', '23:59:59']" :disabled="isDisabled" clearable></el-date-picker> <el-date-picker style="width: 474px" v-model="editForm.activityTime" type="datetimerange" range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期" value-format="yyyy-MM-dd HH:mm:ss" :picker-options="pickerOptions" :default-time="['00:00:00', '23:59:59']" :disabled="isDisabled" :clearable="false"></el-date-picker>
</template> </template>
<div slot="goodsHtml"> <div slot="goodsHtml">
<el-button type="default" class="default-blue-btn el-icon-plus" v-if="!isDisabled" @click="handleRelateProClose">选择商品</el-button> <el-button type="default" class="default-blue-btn el-icon-plus" v-if="!isDisabled" @click="handleRelateProClose">选择商品</el-button>
...@@ -113,13 +113,52 @@ ...@@ -113,13 +113,52 @@
</glsx-combi-form> </glsx-combi-form>
</div> </div>
<div class="wechat-box"> <div class="wechat-box">
<img class="w-100-percent" src="@/assets/wechat-activity.png" /> <img class="w-100-percent" src="@/assets/seckillActivity/phone.png" />
<img class="wechat-nav" src="@/assets/wechat-nav.png" /> <div class="wechat-back">
<div v-show="selectedProInfo.goodsImage" class="wechant-banner-img">
<img class="w-100-percent" :src="selectedProInfo.goodsImage" />
</div>
<p class="wechat-name one-line-ellipsis">{{ editForm.activityName }}</p> <p class="wechat-name one-line-ellipsis">{{ editForm.activityName }}</p>
<p v-show="editForm.limitPurchaseNumber" class="wechat-limit-num one-line-ellipsis">{{ editForm.limitPurchaseNumber }}</p> <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.activityImg || 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.activityVideos.length" class="wechat-video" controls>
<source :src="editForm.activityVideos[0]" type="video/mp4" />
</video>
</div>
<div class="wechat-block">
<p class="wechat-block-title">活动举办方</p>
<div class="flex-center">
<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.length">活动时间:{{ editForm.activityTime[0].split(' ')[0] }}-{{ editForm.activityTime[1].split(' ')[0] }}</p>
</div>
<img class="icon-addr" src="@/assets/seckillActivity/icon-addr.png" />
</div>
</div>
<div class="wechat-block">
<p class="wechat-block-title">距离活动开始</p>
<p class="wechat-count-down m-b-10">
<span v-if="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>秒
</p>
</div>
<div class="w-100-percent txt-center">
<img class="crowd-jdt" src="@/assets/seckillActivity/crowd-jdt.png" />
</div>
<div v-html="editForm.activityDetail"></div>
</div>
</div>
<img class="wechat-footer" src="@/assets/seckillActivity/crowd-footer.png" />
</div>
</div> </div>
<div class="footer" :style="{ left: footerLeft + 'px', width: footerWidth + 'px' }"> <div class="footer" :style="{ left: footerLeft + 'px', width: footerWidth + 'px' }">
<el-button type="primary" v-if="routeInfo.addOrEdit != 'detail'" @click="handleConfirm">确定</el-button> <el-button type="primary" v-if="routeInfo.addOrEdit != 'detail'" @click="handleConfirm">确定</el-button>
...@@ -282,6 +321,13 @@ export default { ...@@ -282,6 +321,13 @@ export default {
value: '' value: ''
} }
], ],
// 倒计时
countDownObj: {
d: '',
h: '',
m: '',
s: ''
},
// 基本信息 // 基本信息
editFormData: [ editFormData: [
{ {
...@@ -483,6 +529,7 @@ export default { ...@@ -483,6 +529,7 @@ export default {
name: 'predictVolume', name: 'predictVolume',
width: '474px', width: '474px',
type: 'input', type: 'input',
append: '件',
maxlength: 20, maxlength: 20,
tips: '用作战报的销量展示' tips: '用作战报的销量展示'
}, },
...@@ -559,6 +606,9 @@ export default { ...@@ -559,6 +606,9 @@ export default {
}, },
'editForm.goodsStock'(newValue, oldValue) { 'editForm.goodsStock'(newValue, oldValue) {
this.editForm.goodsStock = limitPrice(newValue, oldValue, 5, 0, 0) this.editForm.goodsStock = limitPrice(newValue, oldValue, 5, 0, 0)
},
'editForm.activityTime'(newValue) {
newValue && this.countDown()
} }
}, },
...@@ -593,6 +643,32 @@ export default { ...@@ -593,6 +643,32 @@ export default {
} }
}, },
addZero(i) {
return i < 10 ? `0${i}` : `${i}`
},
countDown() {
let lefttime = parseInt((new Date(this.editForm.activityTime[0]).getTime() - new Date().getTime()) / 1000)
let d = parseInt(lefttime / (24 * 60 * 60))
let h = parseInt((lefttime / (60 * 60)) % 24)
let m = parseInt((lefttime / 60) % 60)
let s = parseInt(lefttime % 60)
h = this.addZero(h)
m = this.addZero(m)
s = this.addZero(s)
if (this.time) clearTimeout(this.time)
this.time = setTimeout(() => {
if (d > 0) d = this.addZero(d)
this.countDownObj = {
d: d,
h: h,
m: m,
s: s
}
this.countDown()
}, 1 * 1000)
},
handleIsLimit(val) { handleIsLimit(val) {
this.editForm.limitPurchaseNumber = val == 1 ? '' : '1' this.editForm.limitPurchaseNumber = val == 1 ? '' : '1'
this.editRule.limitPurchaseNumber[0].required = val != 1 this.editRule.limitPurchaseNumber[0].required = val != 1
...@@ -794,7 +870,7 @@ export default { ...@@ -794,7 +870,7 @@ export default {
var info = res var info = res
this.editForm = this.$common.utils.deepClone(res) this.editForm = this.$common.utils.deepClone(res)
this.activityInfo = info this.activityInfo = info
this.editForm.activityTime = [info.startTime, info.endTime] this.$set(this.editForm, 'activityTime', [info.startTime, info.endTime])
this.getGoodInfo(info.goodsId) this.getGoodInfo(info.goodsId)
if (info.activityPrice != null && info.goodsStock != null) { if (info.activityPrice != null && info.goodsStock != null) {
this.editForm.activityPrice = (info.activityPrice / 100).toFixed(2) this.editForm.activityPrice = (info.activityPrice / 100).toFixed(2)
...@@ -974,7 +1050,7 @@ export default { ...@@ -974,7 +1050,7 @@ export default {
} }
} }
</script> </script>
<style scoped> <style scoped lang="scss">
/* 规格 */ /* 规格 */
.edit-product-dh .spesc-label { .edit-product-dh .spesc-label {
padding: 1px 10px; padding: 1px 10px;
...@@ -1021,40 +1097,125 @@ export default { ...@@ -1021,40 +1097,125 @@ export default {
box-sizing: border-box; box-sizing: border-box;
position: absolute; position: absolute;
top: 100px; top: 100px;
right: 19px; right: 20px;
} }
.edit-activity .wechat-nav { .edit-activity .wechat-box .wechat-inner-box {
position: absolute; position: absolute;
top: 20px; top: 73px;
right: 20px; left: 20px;
z-index: 20; width: 236px;
height: 424px;
background-color: #f7f8fa;
overflow-y: scroll;
overflow-x: hidden;
} }
.edit-activity .wechat-box .wechant-banner-img { .edit-activity .wechat-box .wechat-footer {
position: absolute; position: absolute;
width: 236px;
height: 35px;
bottom: 20px;
left: 20px;
}
.edit-activity .wechat-box .wechat-head {
position: absolute;
width: 236px;
height: 53px;
top: 20px; top: 20px;
left: 21px; left: 20px;
width: 234px; }
.edit-activity .wechat-box .wechat-banner-img {
width: 100%;
height: 552px; height: 552px;
} }
.edit-activity .wechat-box .wechant-banner-img img { .edit-activity .wechat-box .icon-server {
height: 235px; position: absolute;
border-radius: 18px 18px 0 0; width: 34px;
height: 42px;
top: 320px;
right: 30px;
z-index: 999;
}
.edit-activity .wechat-box .wechat-banner-img img {
width: 100%;
height: 385px;
}
.edit-activity .wechat-box .wechat-video {
width: 160px;
height: 90px;
margin: 10px auto;
}
.edit-activity .wechat-box .wechat-banner-img .icon-music {
position: absolute;
width: 20px;
height: 20px;
top: 20px;
right: 10px;
}
.edit-activity .wechat-box .wechat-banner-img .wechat-customer {
position: absolute;
width: 100px;
height: 137px;
top: 240px;
left: 10px;
}
.edit-activity .wechat-box .wechat-banner-img {
.wechat-block-title {
text-align: center;
color: #fc5b32;
}
.wechat-block {
box-sizing: border-box;
background-color: #fff;
width: 205px;
font-size: 14px;
padding: 10px;
margin: 10px 12px;
.wechat-sub-addr {
font-size: 12px;
color: #656566;
}
.wechat-time {
font-size: 12px;
color: #fc5b32;
}
.icon-addr {
width: 34px;
height: 34px;
}
.wechat-count-down {
line-height: 22px;
padding: 15px;
border: 1px dotted #e3e3e3;
}
.wechat-txt {
color: #f13c3d;
background-color: #fff4f4;
padding: 4px;
margin: 0 4px;
}
}
}
.edit-activity .wechat-box .wechat-banner-img .crowd-jdt {
width: 205px;
height: 80px;
margin-bottom: 6px;
} }
.edit-activity .wechat-box .wechat-name { .edit-activity .wechat-box .wechat-name {
position: absolute; position: absolute;
top: 300px; top: 50px;
left: 26px; left: 58px;
font-size: 18px; width: 138px;
width: 180px;
color: #282829; color: #282829;
z-index: 99;
text-align: center;
} }
.edit-activity .wechat-box .wechat-limit-num { /* .edit-activity .wechat-box .wechat-limit-num {
position: absolute; position: absolute;
bottom: 93px; bottom: 93px;
left: 160px; left: 160px;
font-size: 10px; font-size: 10px;
width: 20px; width: 20px;
} } */
.edit-activity .customer-service { .edit-activity .customer-service {
width: 656px; width: 656px;
padding: 20px 20px 0 20px; padding: 20px 20px 0 20px;
...@@ -1076,4 +1237,16 @@ export default { ...@@ -1076,4 +1237,16 @@ export default {
.edit-activity .describe-delete { .edit-activity .describe-delete {
margin-left: 8px; margin-left: 8px;
} }
::-webkit-scrollbar {
/*滚动条整体样式*/
width: 6px;
height: 3px;
}
::-webkit-scrollbar-thumb {
/*滚动条里面小方块*/
border-radius: 4px;
background-color: rgba(144, 147, 153, 0.3);
}
</style> </style>
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!