Commit 86164cf2 authored by dragondean@qq.com's avatar dragondean@qq.com

自编号报表优化

parent c2fae766
...@@ -153,13 +153,10 @@ import { getCurrencyPage } from "@/api/ecw/currency"; ...@@ -153,13 +153,10 @@ import { getCurrencyPage } from "@/api/ecw/currency";
import {getWarehouseList} from '@/api/ecw/warehouse' import {getWarehouseList} from '@/api/ecw/warehouse'
import store from "@/store"; import store from "@/store";
import {boxSettlementPage, exportSettlementExcel} from "@/api/ecw/box"; import {boxSettlementPage, exportSettlementExcel} from "@/api/ecw/box";
import {DICT_TYPE} from "@/utils/dict";
import {getCountryListAll} from "@/api/ecw/country";
import {getListTree} from "@/api/ecw/region"; import {getListTree} from "@/api/ecw/region";
import Template from "@/views/cms/template/index.vue";
export default { export default {
components: {Template}, name: 'EcwFinancialSelfnoreport',
data() { data() {
return { return {
loading: false, // 是否加载中 loading: false, // 是否加载中
...@@ -199,9 +196,6 @@ export default { ...@@ -199,9 +196,6 @@ export default {
} }
}, },
computed: { computed: {
DICT_TYPE() {
return DICT_TYPE
},
permissions(){ permissions(){
return store.getters.permissions return store.getters.permissions
}, },
...@@ -255,16 +249,8 @@ export default { ...@@ -255,16 +249,8 @@ export default {
}, },
/** 搜索按钮操作 */ /** 搜索按钮操作 */
handleQuery() { handleQuery() {
this.$refs.queryForm.validate((valid) => { this.$refs.queryForm.validate().then(() => {
console.log({valid})
if(!valid) return
this.queryParams.page = 1; this.queryParams.page = 1;
if(!this.queryParams.destCountryId){
return this.$message.error(this.$t('请选择目的国'))
}
if(!this.queryParams.startWarehouseIdList || !this.queryParams.startWarehouseIdList.length){
return this.$message.error(this.$t('请选择始发仓'))
}
this.getList(); this.getList();
}) })
...@@ -276,13 +262,15 @@ export default { ...@@ -276,13 +262,15 @@ export default {
}, },
// 导出搜索 // 导出搜索
handleExport(){ handleExport(){
this.exporting = true this.$refs.queryForm.validate().then(() => {
let params = {...this.queryParams} this.exporting = true
this.addBeginAndEndTime(params, this.dateFilter, "JsDate", false); let params = {...this.queryParams}
exportSettlementExcel(params).then(res => { this.addBeginAndEndTime(params, this.dateFilter, "JsDate", false);
this.$download.excel(res, 'shipment-summary.xls'); exportSettlementExcel(params).then(res => {
}).finally(() => { this.$download.excel(res, 'shipment-summary.xls');
this.exporting = false }).finally(() => {
this.exporting = false
})
}) })
} }
}, },
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment