Commit ec964a95 by chenwq

秒杀活动联调;订单管理样式

1 parent d78b2bc0
...@@ -145,6 +145,7 @@ html { ...@@ -145,6 +145,7 @@ html {
.marketing .default-blue-btn { .marketing .default-blue-btn {
color: #5850ff; color: #5850ff;
border-color: #5850ff; border-color: #5850ff;
height: 32px;
} }
.el-scrollbar__bar.is-horizontal { .el-scrollbar__bar.is-horizontal {
...@@ -160,7 +161,7 @@ html { ...@@ -160,7 +161,7 @@ html {
line-height: 32px; line-height: 32px;
} }
.marketing .table-cicle { .marketing .table-circle {
display: inline-block; display: inline-block;
width: 6px; width: 6px;
height: 6px; height: 6px;
...@@ -180,11 +181,11 @@ html { ...@@ -180,11 +181,11 @@ html {
} }
.marketing .back-green { .marketing .back-green {
background-color: #2CCA74; background-color: #2cca74;
} }
.marketing .back-red { .marketing .back-red {
background-color: #EB4E4E; background-color: #eb4e4e;
} }
.marketing .el-table .cell { .marketing .el-table .cell {
...@@ -335,8 +336,8 @@ html { ...@@ -335,8 +336,8 @@ html {
.marketing .txt-grey { .marketing .txt-grey {
color: #999999; color: #999999;
} }
.marketing .text-e8{ .marketing .text-e8 {
color: #EB4E4E!important; color: #eb4e4e !important;
} }
.marketing .txt-center { .marketing .txt-center {
text-align: center; text-align: center;
...@@ -496,17 +497,19 @@ html { ...@@ -496,17 +497,19 @@ html {
} }
.marketing .el-tabs__item { .marketing .el-tabs__item {
box-sizing: border-box;
width: 120px; width: 120px;
height: 40px !important; height: 48px !important;
line-height: 40px !important; line-height: 48px !important;
font-size: 14px; font-size: 14px;
text-align: center; text-align: center;
border: 0 !important; border: 0 !important;
background: #ffffff; color: #666666;
color: #999999; background: #fafafa;
border-radius: 0px 4px 0px 0px; border-radius: 4px 4px 0px 0px;
border: 1px solid #f4f6fc; border: 1px solid #eeedff;
padding: 0; padding: 0;
margin-right: 1px;
} }
.marketing .el-tabs__active-bar { .marketing .el-tabs__active-bar {
...@@ -519,10 +522,11 @@ html { ...@@ -519,10 +522,11 @@ html {
.marketing .el-tabs__item.is-active { .marketing .el-tabs__item.is-active {
color: #5850ff; color: #5850ff;
background: #f4f6fc !important; background: #ffffff !important;
border-radius: 4px 0px 0px 0px; border-radius: 4px 4px 0px 0px;
border: 1px solid #f4f6fc !important; border: 1px solid #eeedff !important;
} }
.marketing .tips-icon { .marketing .tips-icon {
display: inline-block; display: inline-block;
width: 14px; width: 14px;
...@@ -565,14 +569,14 @@ html { ...@@ -565,14 +569,14 @@ html {
.el-tooltip__popper.is-light { .el-tooltip__popper.is-light {
background: #ffffff; background: #ffffff;
box-shadow: 0px 4px 12px 0px rgba(0, 0, 0, 0.08); box-shadow: 0px 4px 12px 0px rgba(0, 0, 0, 0.08);
border: 1px solid #e4e7ed!important; border: 1px solid #e4e7ed !important;
width: 177px; width: 177px;
box-sizing: border-box; box-sizing: border-box;
} }
.el-tooltip__popper[x-placement^="top"] .popper__arrow { .el-tooltip__popper[x-placement^='top'] .popper__arrow {
border-top-color: #e4e7ed !important; border-top-color: #e4e7ed !important;
} }
.el-tooltip__popper[x-placement^="top"] .popper__arrow:after { .el-tooltip__popper[x-placement^='top'] .popper__arrow:after {
border-top-color: #e4e7ed !important; border-top-color: #e4e7ed !important;
} }
/* tab */ /* tab */
...@@ -28,7 +28,7 @@ ...@@ -28,7 +28,7 @@
<img :src="require(`@/assets/coupon/icon-${attrToIcon[scope.scope.discountType]}.png`)" /> <img :src="require(`@/assets/coupon/icon-${attrToIcon[scope.scope.discountType]}.png`)" />
</template> </template>
<div slot="status" slot-scope="scope"> <div slot="status" slot-scope="scope">
<span :class="['table-cicle', 'm-r-8', scope.scope.status == 1 ? 'back-orange' : scope.scope.status == 2 ? 'back-blue' : 'back-grey']"></span> <span :class="['table-circle', 'm-r-8', scope.scope.status == 1 ? 'back-orange' : scope.scope.status == 2 ? 'back-blue' : 'back-grey']"></span>
<span>{{ baseData.statusList.find(item => item.confId == scope.scope.status).confName }}</span> <span>{{ baseData.statusList.find(item => item.confId == scope.scope.status).confName }}</span>
</div> </div>
<div class="table-btns" slot="auth-button" slot-scope="scope"> <div class="table-btns" slot="auth-button" slot-scope="scope">
......
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
<!-- 表格区域 开始 --> <!-- 表格区域 开始 -->
<GLTable ref="receiveList" :getListApi="getListApi" :noDataImg="url" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun"> <GLTable ref="receiveList" :getListApi="getListApi" :noDataImg="url" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun">
<div slot="userStatus" slot-scope="scope"> <div slot="userStatus" slot-scope="scope">
<span :class="['table-cicle', 'm-r-8', scope.scope.userStatus == 1 ? 'back-green' : scope.scope.userStatus == 2 ? 'back-red' : 'back-grey']"></span> <span :class="['table-circle', 'm-r-8', scope.scope.userStatus == 1 ? 'back-green' : scope.scope.userStatus == 2 ? 'back-red' : 'back-grey']"></span>
<span>{{ baseData.userStatusList.find(item => item.confId == scope.scope.userStatus).confName }}</span> <span>{{ baseData.userStatusList.find(item => item.confId == scope.scope.userStatus).confName }}</span>
</div> </div>
</GLTable> </GLTable>
......
<!-- 订单管理 --> <!-- 订单管理 -->
<template> <template>
<div class="marketing p-t-20"> <div class="marketing p-t-20 order-manage">
<div class="container"> <div class="container">
<div class="list-tips">
<img class="tips-img" src="@/assets/icon-info.png" />
<span>
已生成有效订单
<span class="red-txt">&nbsp;{{ statisticsInfo.orderCount || 0 }}&nbsp;</span>
项 累计订单总额:
<span class="red-txt">{{ statisticsInfo.payPriceTotal || 0 }}&nbsp;</span>
元 累计退款总额:
<span class="red-txt">{{ statisticsInfo.refundTotal || 0 }}&nbsp;</span>
元
</span>
</div>
<div> <div>
<glsx-combi-form ref="showSearch" :formObj="searchForm" :formData="searchFormData1"></glsx-combi-form> <glsx-combi-form ref="showSearch" :formObj="searchForm" :formData="searchFormData1"></glsx-combi-form>
<glsx-combi-form ref="showSearch" :formObj="searchForm" :formData="searchFormData2"></glsx-combi-form> <glsx-combi-form ref="showSearch" :formObj="searchForm" :formData="searchFormData2"></glsx-combi-form>
...@@ -21,18 +9,43 @@ ...@@ -21,18 +9,43 @@
<span slot="footer" class="footer-btns"> <span slot="footer" class="footer-btns">
<el-button :size="size" type="default" @click="handleReset">重置</el-button> <el-button :size="size" type="default" @click="handleReset">重置</el-button>
<el-button :size="size" type="primary" @click="handleSearch">查询</el-button> <el-button :size="size" type="primary" @click="handleSearch">查询</el-button>
<el-button :size="size" type="primary" @click="handleExport">导出</el-button>
</span> </span>
</glsx-combi-form> </glsx-combi-form>
</div> </div>
<el-tabs v-model="activeName" @tab-click="handleTabClick"> <div class="flex">
<el-tab-pane label="全部订单" name="allOrder"></el-tab-pane> <div class="flex-default">
<el-tab-pane label="售后订单" name="afterOrder"></el-tab-pane> <el-tabs v-model="activeName" @tab-click="handleTabClick">
</el-tabs> <el-tab-pane label="全部订单" name="allOrder"></el-tab-pane>
<el-tab-pane label="售后订单" name="afterOrder"></el-tab-pane>
</el-tabs>
<span class="table-tips">
已生成有效订单
<span class="txt-blue">&nbsp;{{ statisticsInfo.orderCount || 0 }}&nbsp;</span>
项 累计订单总额:
<span class="txt-blue">{{ statisticsInfo.payPriceTotal || 0 }}&nbsp;</span>
元 累计退款总额:
<span class="txt-blue">{{ statisticsInfo.refundTotal || 0 }}&nbsp;</span>
元
</span>
</div>
<el-button class="default-blue-btn" :size="size" type="default" @click="handleExport">导出</el-button>
</div>
<!-- 表格区域 - 全部订单/售后订单 - 开始 --> <!-- 表格区域 - 全部订单/售后订单 - 开始 -->
<GLTable ref="allOrderRef" :getListApi="getListApi" :noDataImg="url" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun"> <GLTable ref="allOrderRef" :getListApi="getListApi" :noDataImg="url" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun">
<template slot="carNo" slot-scope="scope">
{{ Array.isArray(scope.scope.carNo) ? scope.scope.carNo[0] : scope.scope.carNo }}
<el-popover popper-class="order-table-popover" placement="right-start" trigger="click">
<p v-for="(item, index) in scope.scope.carNo" :key="index">{{ item }}</p>
<span class="car-no" slot="reference" v-show="Array.isArray(scope.scope.carNo)">...({{ scope.scope.carNo.length - 1 }})</span>
</el-popover>
</template>
<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>
<div class="table-btns" slot="auth-button" slot-scope="scope"> <div class="table-btns" slot="auth-button" slot-scope="scope">
<!-- <el-button type="text" @click="handleDetail(scope.scope)">查看订单</el-button> --> <!-- <el-button type="text" @click="handleDetail(scope.scope)">查看订单</el-button> -->
<GLButton type="text" fn="查看订单" @click="handleDetail(scope.scope)">查看订单</GLButton> <GLButton type="text" fn="查看订单" @click="handleDetail(scope.scope)">查看订单</GLButton>
...@@ -134,7 +147,8 @@ export default { ...@@ -134,7 +147,8 @@ export default {
customerName: '', customerName: '',
createDate: [], createDate: [],
orderSource: '', orderSource: '',
deliveryType: '' deliveryType: '',
carNo: ''
}, },
tableSearchForm: {}, tableSearchForm: {},
statisticsInfo: { statisticsInfo: {
...@@ -252,6 +266,12 @@ export default { ...@@ -252,6 +266,12 @@ export default {
optionId: 'confId', optionId: 'confId',
optionLabel: 'confName', optionLabel: 'confName',
optionsName: 'deliveryTypeList' optionsName: 'deliveryTypeList'
},
{
label: '车架号',
name: 'carNo',
labelWidth: 56,
type: 'input'
} }
], ],
// 快递信息 // 快递信息
...@@ -360,16 +380,21 @@ export default { ...@@ -360,16 +380,21 @@ export default {
} }
}, },
{ {
label: '客户信息', label: '客户名称',
prop: 'customerName', prop: 'customerName',
line: 2 line: 2
}, },
{ {
label: '车架号',
prop: 'carNo',
width: 120,
addHtml: 'carNo'
},
{
label: '订单状态', label: '订单状态',
prop: 'orderStatus', prop: 'orderStatus',
formatter: cellValue => { addHtml: 'orderStatus',
return this.baseData.orderStatusList.map(item => item.confId).includes(cellValue.orderStatus + '') ? this.baseData.orderStatusList.find(item => item.confId == cellValue.orderStatus).confName : '-' width: 160
}
}, },
{ {
label: '支付总价', label: '支付总价',
...@@ -684,6 +709,10 @@ export default { ...@@ -684,6 +709,10 @@ export default {
// 确认收货 - end // 确认收货 - end
setTableFinishFun() { setTableFinishFun() {
this.$refs.allOrderRef.data.forEach(item => {
item.carNum = Math.floor(Math.random() * 10) % 2 ? '999999,222222,333333' : '999999'
item.carNo = item.carNum.split(',').length > 1 ? item.carNum.split(',') : item.carNum
})
//接收到的数据为空 //接收到的数据为空
this.$refs.allOrderRef.data.length ? (this.$refs.allOrderRef.tableHeightValues = '') : this.$refs.allOrderRef.setTableHeightFun() this.$refs.allOrderRef.data.length ? (this.$refs.allOrderRef.tableHeightValues = '') : this.$refs.allOrderRef.setTableHeightFun()
this.getCount() this.getCount()
...@@ -713,7 +742,8 @@ export default { ...@@ -713,7 +742,8 @@ export default {
customerName: '', customerName: '',
createDate: [], createDate: [],
orderSource: '', orderSource: '',
deliveryType: '' deliveryType: '',
carNo: ''
} }
this.handleSearch() this.handleSearch()
} }
...@@ -721,4 +751,26 @@ export default { ...@@ -721,4 +751,26 @@ export default {
} }
</script> </script>
<style lang="scss"></style> <style lang="scss">
.order-table-popover {
min-width: 80px !important;
padding: 8px 12px !important;
}
.order-manage {
.table-tips {
height: 48px;
line-height: 48px;
font-size: 14px;
color: #333333;
margin-left: 16px;
}
.car-no {
cursor: pointer;
font-size: 12px;
border-radius: 4px;
border: 1px solid #e8e8ea;
padding: 2px 4px;
line-height: 25px;
}
}
</style>
...@@ -54,14 +54,14 @@ ...@@ -54,14 +54,14 @@
</table> </table>
</div> </div>
</div> </div>
<template slot="isLimit" slot-scope="scope"> <template slot="limitPurchaseFlag" slot-scope="scope">
<el-radio-group v-model="editForm[scope.scope.name]" @change="handleIsLimit"> <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 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> </el-radio-group>
<span class="m-l-20" v-if="editForm[scope.scope.name] == 2" id="limitNum"> <span class="m-l-20" v-if="editForm[scope.scope.name] == 2" id="limitPurchaseNumber">
每人限购 每人限购
<el-form-item prop="limitNum"> <el-form-item prop="limitPurchaseNumber">
<el-input v-model="editForm.limitNum" placeholder="请输入限购次数" :disabled="isDisabled"></el-input> <el-input v-model="editForm.limitPurchaseNumber" placeholder="请输入限购次数" :disabled="isDisabled"></el-input>
</el-form-item> </el-form-item>
件 件
</span> </span>
...@@ -126,8 +126,8 @@ export default { ...@@ -126,8 +126,8 @@ export default {
activityPrice: '', activityPrice: '',
goodsStock: '', goodsStock: '',
goodsId: '', goodsId: '',
isLimit: 1, limitPurchaseFlag: 1,
limitNum: '' limitPurchaseNumber: ''
}, },
//商品列表 //商品列表
tableParams: { tableParams: {
...@@ -177,12 +177,12 @@ export default { ...@@ -177,12 +177,12 @@ export default {
} }
], ],
goodsId: [{ required: true, message: '请选择商品', trigger: ['change', 'blur'] }], goodsId: [{ required: true, message: '请选择商品', trigger: ['change', 'blur'] }],
isLimit: [{ required: true, message: '请选择是否限购', trigger: 'change' }], limitPurchaseFlag: [{ required: true, message: '请选择是否限购', trigger: 'change' }],
limitNum: [ limitPurchaseNumber: [
{ required: false, message: '请输入限购次数', trigger: 'blur' }, { required: false, message: '请输入限购次数', trigger: 'blur' },
{ {
validator: (rule, value, callback) => { validator: (rule, value, callback) => {
if (this.editForm.isLimit == 2 && (value < 1 || value > 10 || !/^\d+$/.test(value))) { if (this.editForm.limitPurchaseFlag == 2 && (value < 1 || value > 10 || !/^\d+$/.test(value))) {
return callback('请输入1-10的限购次数') return callback('请输入1-10的限购次数')
} }
return callback() return callback()
...@@ -243,8 +243,8 @@ export default { ...@@ -243,8 +243,8 @@ export default {
}, },
{ {
label: '是否限购', label: '是否限购',
name: 'isLimit', name: 'limitPurchaseFlag',
addHtml: 'isLimit', addHtml: 'limitPurchaseFlag',
optionId: 'confId', optionId: 'confId',
optionLabel: 'confName', optionLabel: 'confName',
optionList: [ optionList: [
...@@ -334,8 +334,8 @@ export default { ...@@ -334,8 +334,8 @@ export default {
}, },
handleIsLimit(val) { handleIsLimit(val) {
this.editForm.limitNum = '' this.editForm.limitPurchaseNumber = ''
this.editRule.limitNum[0].required = val != 1 this.editRule.limitPurchaseNumber[0].required = val != 1
}, },
handleRelateProChange(val) { handleRelateProChange(val) {
...@@ -485,6 +485,8 @@ export default { ...@@ -485,6 +485,8 @@ export default {
form.promotion = info.promotion form.promotion = info.promotion
form.activityTime = [info.startTime, info.endTime] form.activityTime = [info.startTime, info.endTime]
form.goodsId = info.goodsId form.goodsId = info.goodsId
form.limitPurchaseFlag = info.limitPurchaseFlag
form.limitPurchaseNumber = info.limitPurchaseNumber
this.getGoodInfo(info.goodsId) this.getGoodInfo(info.goodsId)
if (info.activityPrice != null && info.goodsStock != null) { if (info.activityPrice != null && info.goodsStock != null) {
form.activityPrice = (info.activityPrice / 100).toFixed(2) form.activityPrice = (info.activityPrice / 100).toFixed(2)
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!