|
@@ -61,7 +61,7 @@
|
|
|
<a-button style="margin-left: 8px" @click="resetSearchForm" :disabled="disabled" id="shortageStatisticsCList-reset">重置</a-button>
|
|
|
<a-button
|
|
|
style="margin-left: 8px"
|
|
|
- type="danger"
|
|
|
+ type="primary"
|
|
|
@click="handleExport"
|
|
|
:disabled="disabled"
|
|
|
:loading="exportLoading"
|
|
@@ -117,7 +117,7 @@ import { STable, VSelect } from '@/components'
|
|
|
import custList from '@/views/common/custList.vue'
|
|
|
import subarea from '@/views/common/subarea.js'
|
|
|
import { productTypeQuery } from '@/api/productType'
|
|
|
-import { oosBuyerList, oosBuyerDetailCount, oosBuyerDetailPageCount } from '@/api/oos'
|
|
|
+import { oosBuyerList, oosBuyerDetailCount, oosBuyerDetailPageCount, oosDetailExport } from '@/api/oos'
|
|
|
export default {
|
|
|
components: { STable, VSelect, custList, subarea },
|
|
|
data () {
|
|
@@ -235,11 +235,19 @@ export default {
|
|
|
},
|
|
|
// 导出
|
|
|
handleExport () {
|
|
|
- // this.exportLoading = true
|
|
|
- // customerBundleExportDelay({}).then(res => {
|
|
|
- // this.exportLoading = false
|
|
|
- // this.download(res)
|
|
|
- // })
|
|
|
+ const params = this.queryParam
|
|
|
+ if (this.time && this.time.length) {
|
|
|
+ params.beginDate = moment(this.time[0]).format('YYYY-MM-DD')
|
|
|
+ params.endDate = moment(this.time[1]).format('YYYY-MM-DD')
|
|
|
+ } else {
|
|
|
+ params.beginDate = ''
|
|
|
+ params.endDate = ''
|
|
|
+ }
|
|
|
+ this.exportLoading = true
|
|
|
+ oosDetailExport(params).then(res => {
|
|
|
+ this.exportLoading = false
|
|
|
+ this.download(res)
|
|
|
+ })
|
|
|
},
|
|
|
download (data) {
|
|
|
if (!data) { return }
|