Commit 6e952fde by 前端

Merge branch 'develop' into 'master'

上线合并

See merge request !15
2 parents b60f25d8 e916d995
...@@ -3550,7 +3550,7 @@ ...@@ -3550,7 +3550,7 @@
}, },
"clone-deep": { "clone-deep": {
"version": "4.0.1", "version": "4.0.1",
"resolved": "https://registry.npmmirror.com/clone-deep/-/clone-deep-4.0.1.tgz", "resolved": "https://registry.npmjs.org/clone-deep/-/clone-deep-4.0.1.tgz",
"integrity": "sha512-neHB9xuzh/wk0dIHweyAXv2aPGZIVk3pLMe+/RNzINf17fe0OG96QroktYAUm7SM1PBnzTabaLboqqxDyMU+SQ==", "integrity": "sha512-neHB9xuzh/wk0dIHweyAXv2aPGZIVk3pLMe+/RNzINf17fe0OG96QroktYAUm7SM1PBnzTabaLboqqxDyMU+SQ==",
"dev": true, "dev": true,
"requires": { "requires": {
...@@ -10719,7 +10719,7 @@ ...@@ -10719,7 +10719,7 @@
"dependencies": { "dependencies": {
"json5": { "json5": {
"version": "1.0.2", "version": "1.0.2",
"resolved": "https://registry.npmmirror.com/json5/-/json5-1.0.2.tgz", "resolved": "https://registry.npmjs.org/json5/-/json5-1.0.2.tgz",
"integrity": "sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA==", "integrity": "sha512-g1MWMLBiz8FKi1e4w0UyVL3w+iJceWAFBAaBnnGKOpNa5f8TLktkbre1+s6oICydWAm+HRUGTmI+//xv2hvXYA==",
"dev": true, "dev": true,
"requires": { "requires": {
...@@ -10728,7 +10728,7 @@ ...@@ -10728,7 +10728,7 @@
}, },
"loader-utils": { "loader-utils": {
"version": "1.4.2", "version": "1.4.2",
"resolved": "https://registry.npmmirror.com/loader-utils/-/loader-utils-1.4.2.tgz", "resolved": "https://registry.npmjs.org/loader-utils/-/loader-utils-1.4.2.tgz",
"integrity": "sha512-I5d00Pd/jwMD2QCduo657+YM/6L3KZu++pmX9VFncxaxvHcru9jx1lBaFft+r4Mt2jK0Yhp41XlRAihzPxHNCg==", "integrity": "sha512-I5d00Pd/jwMD2QCduo657+YM/6L3KZu++pmX9VFncxaxvHcru9jx1lBaFft+r4Mt2jK0Yhp41XlRAihzPxHNCg==",
"dev": true, "dev": true,
"requires": { "requires": {
...@@ -10980,7 +10980,7 @@ ...@@ -10980,7 +10980,7 @@
}, },
"shallow-clone": { "shallow-clone": {
"version": "3.0.1", "version": "3.0.1",
"resolved": "https://registry.npmmirror.com/shallow-clone/-/shallow-clone-3.0.1.tgz", "resolved": "https://registry.npmjs.org/shallow-clone/-/shallow-clone-3.0.1.tgz",
"integrity": "sha512-/6KqX+GVUdqPuPPd2LxDDxzX6CAbjJehAAOKlNpqqUpAqPM6HeL8f+o3a+JsyGjn2lv0WY8UsTgUJjU9Ok55NA==", "integrity": "sha512-/6KqX+GVUdqPuPPd2LxDDxzX6CAbjJehAAOKlNpqqUpAqPM6HeL8f+o3a+JsyGjn2lv0WY8UsTgUJjU9Ok55NA==",
"dev": true, "dev": true,
"requires": { "requires": {
...@@ -12574,7 +12574,7 @@ ...@@ -12574,7 +12574,7 @@
}, },
"vue-loader-v16": { "vue-loader-v16": {
"version": "npm:vue-loader@16.8.3", "version": "npm:vue-loader@16.8.3",
"resolved": "https://registry.npmmirror.com/vue-loader/-/vue-loader-16.8.3.tgz", "resolved": "https://registry.npmjs.org/vue-loader/-/vue-loader-16.8.3.tgz",
"integrity": "sha512-7vKN45IxsKxe5GcVCbc2qFU5aWzyiLrYJyUuMz4BQLKctCj/fmCa0w6fGiiQ2cLFetNcek1ppGJQDCup0c1hpA==", "integrity": "sha512-7vKN45IxsKxe5GcVCbc2qFU5aWzyiLrYJyUuMz4BQLKctCj/fmCa0w6fGiiQ2cLFetNcek1ppGJQDCup0c1hpA==",
"dev": true, "dev": true,
"optional": true, "optional": true,
...@@ -12586,7 +12586,7 @@ ...@@ -12586,7 +12586,7 @@
"dependencies": { "dependencies": {
"ansi-styles": { "ansi-styles": {
"version": "4.3.0", "version": "4.3.0",
"resolved": "https://registry.npmmirror.com/ansi-styles/-/ansi-styles-4.3.0.tgz", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz",
"integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==",
"dev": true, "dev": true,
"optional": true, "optional": true,
...@@ -12596,7 +12596,7 @@ ...@@ -12596,7 +12596,7 @@
}, },
"chalk": { "chalk": {
"version": "4.1.2", "version": "4.1.2",
"resolved": "https://registry.npmmirror.com/chalk/-/chalk-4.1.2.tgz", "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz",
"integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==",
"dev": true, "dev": true,
"optional": true, "optional": true,
...@@ -12607,7 +12607,7 @@ ...@@ -12607,7 +12607,7 @@
}, },
"color-convert": { "color-convert": {
"version": "2.0.1", "version": "2.0.1",
"resolved": "https://registry.npmmirror.com/color-convert/-/color-convert-2.0.1.tgz", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz",
"integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==",
"dev": true, "dev": true,
"optional": true, "optional": true,
...@@ -12617,21 +12617,21 @@ ...@@ -12617,21 +12617,21 @@
}, },
"color-name": { "color-name": {
"version": "1.1.4", "version": "1.1.4",
"resolved": "https://registry.npmmirror.com/color-name/-/color-name-1.1.4.tgz", "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz",
"integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==",
"dev": true, "dev": true,
"optional": true "optional": true
}, },
"has-flag": { "has-flag": {
"version": "4.0.0", "version": "4.0.0",
"resolved": "https://registry.npmmirror.com/has-flag/-/has-flag-4.0.0.tgz", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz",
"integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==",
"dev": true, "dev": true,
"optional": true "optional": true
}, },
"supports-color": { "supports-color": {
"version": "7.2.0", "version": "7.2.0",
"resolved": "https://registry.npmmirror.com/supports-color/-/supports-color-7.2.0.tgz", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz",
"integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==",
"dev": true, "dev": true,
"optional": true, "optional": true,
......
...@@ -210,4 +210,16 @@ const listContracts = params => { ...@@ -210,4 +210,16 @@ const listContracts = params => {
}) })
} }
export default { getList, getOrderDetail, getOrderCount, shopmallOrderList, goodsOrderDetail, getServiceStore, getListApi, getCrowdfundingParams, getCountApi, orderExportApi, getOrderDetailApi, getQuotationPageApi, quotationFindByIdApi, exportOrderApi, quotationExportApi, quotationPrintApi, contractExportApi, listContracts } // 订单管理excel导出表头字段模板
const exportHeadTemplate = params => {
params.method = `scrm.api.boutiquecoupon.rop.router.twoCityTale`
params.routerMethod = `dj.api.smartcarlife.ordermanage.export.head.template`
return http({
url: 'rop-scrm-boutiquecoupon/router',
method: 'POST',
data: params,
sign: true
})
}
export default { getList, getOrderDetail, getOrderCount, shopmallOrderList, goodsOrderDetail, getServiceStore, getListApi, getCrowdfundingParams, getCountApi, orderExportApi, getOrderDetailApi, getQuotationPageApi, quotationFindByIdApi, exportOrderApi, quotationExportApi, quotationPrintApi, contractExportApi, listContracts, exportHeadTemplate }
...@@ -2,38 +2,62 @@ ...@@ -2,38 +2,62 @@
<template> <template>
<div class="purchase"> <div class="purchase">
<div class="container"> <div class="container">
<GLCombiForm ref="showSearch" :rowNumber="1" :formObj="searchForm" :formData="showFormData" @handleOk="handleSearch" @handleRest="handleReset"></GLCombiForm> <GLCombiForm ref="showSearch"
:rowNumber="1"
:formObj="searchForm"
:formData="showFormData"
@handleOk="handleSearch"
@handleRest="handleReset"></GLCombiForm>
<div class="table-header"> <div class="table-header">
<span class="priceSpan">累计订单金额:¥{{ totalCount }}元</span> <span class="priceSpan">累计订单金额:¥{{ totalCount }}元</span>
<el-button type="primary" class="btn" size="small" @click="exportExcel">导出</el-button> <el-button type="primary"
class="btn"
size="small"
@click="exportExcel">导出</el-button>
</div> </div>
<!-- 表格区域 开始 --> <!-- 表格区域 开始 -->
<GLTable ref="orderRef" :getListApi="getListApi" :noDataImg="url" :searchForm="tableSearchForm" :tableParams="tableParams" :pageConf="pageConf" :beforeSearchFn="beforeSearchFn" @setTableFinishFun="setTableFinishFun"> <GLTable ref="orderRef"
<template slot="carTypeName" slot-scope="scope"> :getListApi="getListApi"
:noDataImg="url"
:searchForm="tableSearchForm"
:tableParams="tableParams"
:pageConf="pageConf"
:beforeSearchFn="beforeSearchFn"
@setTableFinishFun="setTableFinishFun">
<template slot="carTypeName"
slot-scope="scope">
<span v-show="scope.scope.carBrand">{{ scope.scope.carBrand }}</span> <span v-show="scope.scope.carBrand">{{ scope.scope.carBrand }}</span>
<span v-show="scope.scope.carChildsBrandName">-{{ scope.scope.carChildsBrandName }}</span> <span v-show="scope.scope.carChildsBrandName">-{{ scope.scope.carChildsBrandName }}</span>
<span v-show="scope.scope.carSeriesName">-{{ scope.scope.carSeriesName }}</span> <span v-show="scope.scope.carSeriesName">-{{ scope.scope.carSeriesName }}</span>
</template> </template>
<template slot="upgradeGoodsNames" slot-scope="scope"> <template slot="upgradeGoodsNames"
<span v-for="(item, index) in scope.scope.subOrderList" :key="index"> slot-scope="scope">
<span v-for="(item, index) in scope.scope.subOrderList"
:key="index">
<p v-if="item.upgradeGoodsId">{{ item.upgradeGoodsName }}</p> <p v-if="item.upgradeGoodsId">{{ item.upgradeGoodsName }}</p>
<p v-else>{{ item.baseGoodsName }}</p> <p v-else>{{ item.baseGoodsName }}</p>
</span> </span>
</template> </template>
<template slot="upgradeGoodsAlias" slot-scope="scope"> <template slot="upgradeGoodsAlias"
<span v-for="(item, index) in scope.scope.subOrderList" :key="index"> slot-scope="scope">
<span v-for="(item, index) in scope.scope.subOrderList"
:key="index">
<p>{{ item.upgradeGoodsAlias }}</p> <p>{{ item.upgradeGoodsAlias }}</p>
</span> </span>
</template> </template>
<template slot="goodsPrice" slot-scope="scope"> <template slot="goodsPrice"
<span v-for="(item, index) in scope.scope.subOrderList" :key="index"> slot-scope="scope">
<span v-for="(item, index) in scope.scope.subOrderList"
:key="index">
<p v-if="item.upgradeGoodsId">¥ {{ item.totalPrice }}</p> <p v-if="item.upgradeGoodsId">¥ {{ item.totalPrice }}</p>
<p v-else>¥ {{ item.baseRetailPrice }}</p> <p v-else>¥ {{ item.baseRetailPrice }}</p>
</span> </span>
</template> </template>
<template slot="upgradeWarrantyPeriod" slot-scope="scope"> <template slot="upgradeWarrantyPeriod"
<span v-for="(item, index) in scope.scope.subOrderList" :key="index"> slot-scope="scope">
<span v-for="(item, index) in scope.scope.subOrderList"
:key="index">
<p>{{ item.upgradeWarrantyPeriod ? item.upgradeWarrantyPeriod + '年' : '无' }}</p> <p>{{ item.upgradeWarrantyPeriod ? item.upgradeWarrantyPeriod + '年' : '无' }}</p>
</span> </span>
</template> </template>
...@@ -45,13 +69,46 @@ ...@@ -45,13 +69,46 @@
<span>{{ scope.scope.status | orderStatus }}</span> <span>{{ scope.scope.status | orderStatus }}</span>
</div> </div>
</template> --> </template> -->
<div class="table-btns" slot="auth-button" slot-scope="scope"> <div class="table-btns"
<el-button type="text" @click="handleDetail(scope.scope)">查看详情</el-button> slot="auth-button"
slot-scope="scope">
<el-button type="text"
@click="handleDetail(scope.scope)">查看详情</el-button>
</div> </div>
</GLTable> </GLTable>
<!-- 表格区域 end --> <!-- 表格区域 end -->
</div> </div>
<orderDeatilDialog :visible.sync="detailVisible" :paramsObj="paramsObj"></orderDeatilDialog> <orderDeatilDialog :visible.sync="detailVisible"
:paramsObj="paramsObj"></orderDeatilDialog>
<!-- 导出字段选择 -->
<GLDialog title="请选择导出的字段"
:visible.sync="chooseFieldVisible"
class="statementOfAccountDialog"
:destroy-on-close="true"
:close-on-click-modal="false"
:before-close="handleClose"
:width="'850px'"
@onOk="exportExcel_handleConfirm"
@onCancel="handleClose">
<div class="add-dialog">
<el-form ref="editFormRef"
:model="infoForm"
label-width="1px"
size="small">
<el-form-item class="elItem">
<el-checkbox-group v-model="infoForm.fields"
@change="handleCheckChange">
<el-checkbox v-for="(item, index) in baseData.fieldList"
:key="index"
:label="item.code"
:disabled="item.required"
class="region-list-item">{{
item.name }}</el-checkbox>
</el-checkbox-group>
</el-form-item>
</el-form>
</div>
</GLDialog>
</div> </div>
</template> </template>
...@@ -415,14 +472,19 @@ export default { ...@@ -415,14 +472,19 @@ export default {
storeIdList: [], storeIdList: [],
channelTypeList: [], channelTypeList: [],
manageTypeList: manageTypeList, manageTypeList: manageTypeList,
subShopMerchantList: [] subShopMerchantList: [],
fieldList: []
}, },
totalCount: '', totalCount: '',
subShopMerchanShowHide: true subShopMerchanShowHide: true,
chooseFieldVisible: false,
infoForm: {
fields: [],
},
} }
}, },
created() {}, created() { },
mounted() { mounted() {
this.getChannelType() this.getChannelType()
...@@ -559,11 +621,45 @@ export default { ...@@ -559,11 +621,45 @@ export default {
this.$refs.orderRef.data.length ? (this.$refs.orderRef.tableHeightValues = '') : this.$refs.orderRef.setTableHeightFun() this.$refs.orderRef.data.length ? (this.$refs.orderRef.tableHeightValues = '') : this.$refs.orderRef.setTableHeightFun()
}, },
exportExcel() { exportExcel() {
this.$apis.order.exportHeadTemplate({}).then(res => {
this.baseData.fieldList = res
this.chooseFieldVisible = true
console.log(this.baseData.fieldList);
this.infoForm.fields = []
this.baseData.fieldList.forEach(item => {
if (item.selected) {
this.infoForm.fields.push(item.code)
}
})
})
},
exportExcel_handleConfirm() {
let fields = this.infoForm.fields
this.baseData.fieldList = this.baseData.fieldList.map(item => {
if (fields.find(code => (code == item.code))) {
item.selected = true
} else {
item.selected = false
}
return item
})
console.log(this.baseData.fieldList);
var params = this.getParams() var params = this.getParams()
params.pageNum = 1
params.fieldList = this.baseData.fieldList
this.$apis.order.exportOrderApi(params).then(res => { this.$apis.order.exportOrderApi(params).then(res => {
console.log(res);
downLoadFile(res) downLoadFile(res)
this.chooseFieldVisible = false
}) })
}, },
handleClose() {
this.chooseFieldVisible = false
},
handleSearch() { handleSearch() {
this.$refs.orderRef.refreshTable() this.$refs.orderRef.refreshTable()
this.getOrderCount() this.getOrderCount()
...@@ -649,5 +745,21 @@ export default { ...@@ -649,5 +745,21 @@ export default {
color: #2a58ad; color: #2a58ad;
margin: 0 2px; margin: 0 2px;
} }
.add-dialog {
// margin: 20px 0;
/* 用来调整每一项的宽度 */
.region-list-item {
width: 100px;
white-space: nowrap;
/* text-overflow: ellipsis; */
overflow: hidden;
}
::v-deep .el-form-item {
.el-form-item__content {
width: 100%;
}
}
}
} }
</style> </style>
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!