diff --git a/src/api/consigner/customerconfig.js b/src/api/consigner/customerconfig.js index 89ceca8..f21fedc 100644 --- a/src/api/consigner/customerconfig.js +++ b/src/api/consigner/customerconfig.js @@ -12,3 +12,5 @@ export const delCustomer = params => { return axios.get(`${baseServiceURL2}/cust export const ediCustomer = params => { return http.post(`${baseServiceURL2}/customer/ediCustomer`, params); }; //客户配置列表 export const selectCustomers = params => { return axios.get(`${baseServiceURL2}/customer/selectCustomers`, { params: params }); }; +// 查询客户配置所有列表 +export const selectAll = params => {return axios.get(`${baseServiceURL2}/customer/selectAll`, {params: params});}; \ No newline at end of file diff --git a/src/api/consigner/exportOrder.js b/src/api/consigner/exportOrder.js index 1b908e2..ec8e3ab 100644 --- a/src/api/consigner/exportOrder.js +++ b/src/api/consigner/exportOrder.js @@ -7,11 +7,12 @@ let baseServiceURL2 = 'wlpt-cbed-system' //订单列表 -export const selectLists = params => { return axios.get(`${baseServiceURL2}/ExportOrderDeclaration/selectLists`, { params: params }); }; +// export const selectLists = params => { return axios.get(`${baseServiceURL2}/ExportOrderDeclaration/selectLists`, { params: params }); }; +export const selectLists = params => { return axios.get(`${baseServiceURL2}/ExportOrder/selectList`, { params: params }); }; //订单申报 export const sendOrder = params => { return http.post(`${baseServiceURL2}/ExportOrderDeclaration/sendOrder`, params); }; //上传EXCEL -export const importExcel = params => { return http.postExcelData(`${baseServiceURL2}/import/importExcel`, params); }; +// export const importExcel = params => { return http.postExcelData(`${baseServiceURL2}/import/importExcel`, params); }; //订单批量申报 export const batchOrder = params => { return http.post(`${baseServiceURL2}/ExportOrderDeclaration/batchOrder`, params); }; //订单批量导入申报 @@ -30,3 +31,11 @@ export const zfeldBatchDeclare = params => { return http.post(`${baseServiceURL2 export const zfeldImportDeclare = params => { return http.postExcelData(`${baseServiceURL2}/ExportWaybillDeclaration/eldImportDeclare`, params); }; //根据提运单统计信息 export const billNoStatistics = params => { return axios.get(`${baseServiceURL2}/ExportListDeclaration/billNoStatistics`, { params: params }); }; +// 根据guid删除订单信息 +export const deleteOrderByGuid = params => {return axios.get(`${baseServiceURL2}/ExportOrder/deleteByGuid`, {params: params}); }; +// 根据guid列表批量删除订单信息 +export const batchDelOrderByBeans = params =>{return http.post(`${baseServiceURL2}/ExportOrder/deleteByBeans`,params); }; +// 导入订单文件到minio +export const importExcelToMinio = params => { return http.postExcelData(`${baseServiceURL2}/import/importExcelToMinio`, params); }; +// 查询导入文件列表 +export const selectFilePage = params =>{return axios.get(`${baseServiceURL2}/import/selectFilePage`, { params: params }); } \ No newline at end of file diff --git a/src/api/remote_interface/byont_import.js b/src/api/remote_interface/byont_import.js index 9627d8a..193e501 100644 --- a/src/api/remote_interface/byont_import.js +++ b/src/api/remote_interface/byont_import.js @@ -32,6 +32,9 @@ export const addTeleAddr = params => {return axios.post(`${base1}/teleaddr/addTe export const delTeleAddr = params => {return http.get(`${base1}/teleaddr/delTeleAddr`, params);}; export const ediTeleAddr = params => {return axios.post(`${base1}/teleaddr/ediTeleAddr`, params);}; export const selectLists = params => {return http.get(`${base1}/teleaddr/selectLists`, params);}; +//结算统计 +export const selectStatistics = params => {return http.get(`${base1}/efre/selectStatistics`, params);}; + diff --git a/src/routes.js b/src/routes.js index ff06d9b..c7bc3e4 100755 --- a/src/routes.js +++ b/src/routes.js @@ -189,6 +189,7 @@ import TeleAddr from "./views/nav3/TeleAddr.vue"; //朱总让做的网页在线客服 import Webdialog from './views/bus/Webdialog.vue' import C6Way from './views/nav3/C6Way.vue' +import DBstatistics from './views/nav3/statistics.vue' //转运申请 import Transport from './views/nav4/Transport.vue' @@ -205,6 +206,7 @@ import satellite from "./views/deploy/satellite"; import ExortOrder from './views/exportorder/Exportorder.vue' import CustomerConfig from './views/exportorder/CustomerConfig.vue' import ManagerWaybill from "./views/exportorder/ManagerWaybill.vue"; +import ImportOrder from './views/exportorder/ImportOrder'; /*制单管理*/ import ZhiDan from './views/zhidan/zhidan.vue' @@ -244,7 +246,8 @@ let routes = [ children: [ {path: '/ExortOrder', component: ExortOrder, name: '出口订单'}, {path: '/CustomerConfig', component: CustomerConfig, name: '客户配置'}, - {path: '/ManagerWaybill', component: ManagerWaybill, name: '主单管理'} + {path: '/ManagerWaybill', component: ManagerWaybill, name: '主单管理'}, + {path: '/import', component: ImportOrder, name: '订单预录入'} ] }, { @@ -279,6 +282,7 @@ let routes = [ {path: '/Webdialog', component: Webdialog, name: '在线客服'}, {path: '/TeleAddr', component: TeleAddr, name: '电报地址'}, {path: '/C6Way', component: C6Way, name: 'C6货运单'}, + {path: '/DBstatistics', component: DBstatistics, name: '结算统计'}, ] }, { diff --git a/src/views/airtransport/aircraft.vue b/src/views/airtransport/aircraft.vue index 2a68e4c..0e4f701 100644 --- a/src/views/airtransport/aircraft.vue +++ b/src/views/airtransport/aircraft.vue @@ -282,7 +282,6 @@ this.loading = true; selectCountry(params).then(res =>{ if (res!=null) { - console.log(res.data.data) setTimeout(() => { this.loading = false; this.countryOptions=res.data.data; @@ -300,7 +299,6 @@ this.loading = true; selectCreden(params).then(res =>{ if (res!=null) { - console.log(res.data.data) setTimeout(() => { this.loading = false; this.certOptions=res.data.data; @@ -318,8 +316,9 @@ addAircraft(this.aircraft).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; + this.$message.success(response.msg) this.$router.push({path:'/queryAircraft',query:{airwayCode:this.aircraft.airwayCode,aircraftNo:this.aircraft.aircraftNo}}); }else{ this.msg=response.msg; @@ -338,17 +337,16 @@ this.aircraft.createBy=loginUserInfo.username sendAircraft(this.aircraft).then(res=>{ let response=res.data; - console.log(response); if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; this.$router.push({path:'/queryAircraft',query:{airwayCode:this.aircraft.airwayCode,aircraftNo:this.aircraft.aircraftNo}}); + this.$message.success(response.msg) }else{ - this.msg=response.msg; + this.$message.error(response.msg) } }); } else { - console.log('error submit!!'); return false; } }); @@ -368,7 +366,7 @@ return e.replace(/[^a-zA-Z0-9.-]/g,'').toUpperCase(); } }, - mounted(){ + activated(){ this.defaultData(); } } diff --git a/src/views/airtransport/arrival.vue b/src/views/airtransport/arrival.vue index fa10f29..f655832 100644 --- a/src/views/airtransport/arrival.vue +++ b/src/views/airtransport/arrival.vue @@ -241,15 +241,15 @@ submitForm(formName) { this.$refs[formName].validate((valid) => { if (valid) { - console.log(this.arrival) addPrediction(this.arrival).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + // this.centerDialogVisible=true; + //this.msg=response.msg; this.$router.push({path:'/queryArrival',query:{flightNo:this.arrival.flightNo,flightDate:this.arrival.flightDate}}); + this.$message.success(response.msg) }else{ - this.msg=response.msg; + this.$message.error(response.msg) } } ); @@ -292,7 +292,7 @@ return e.replace(/[^a-zA-Z0-9.-]/g,'').toUpperCase(); } }, - mounted(){ + activated(){ this.defaultData(); } } diff --git a/src/views/airtransport/bills.vue b/src/views/airtransport/bills.vue index 6992a56..9de2b97 100644 --- a/src/views/airtransport/bills.vue +++ b/src/views/airtransport/bills.vue @@ -641,8 +641,9 @@ background-color: white; addBillPerson(this.billperson).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; + this.$message.success(response.msg); this.transList() //document.getElementById("send").disabled=true; let sy=this.type="2"; @@ -771,15 +772,16 @@ background-color: white; addBill(this.bill).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + this.$message.success(response.msg) + //this.centerDialogVisible=true; + //this.msg=response.msg; // this.$router.push({path:'/queryBill',query:{aircraftNo:this.bill.aircraftNo,flightNo:this.bill.flightNo, // flightDate:this.bill.flightDate}}); //document.getElementById("add").disabled=true; let st=this.status="2"; this.btDeleStatusFormater(st); }else{ - this.msg=response.msg; + this.$message.error(response.msg) } }); } else { @@ -797,10 +799,11 @@ background-color: white; sendBill(this.bill).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; this.$router.push({path:'/queryBill',query:{aircraftNo:this.bill.aircraftNo,flightNo:this.bill.flightNo, flightDate:this.bill.flightDate}}); + this.$message.success(response.msg) //document.getElementById("add").disabled=true; // let st=this.status="2"; // this.btDeleStatusFormater(st); @@ -865,7 +868,7 @@ background-color: white; return uuid; }, }, - mounted(){ + activated(){ this.defaultData(); //this.transList(); // this.getCreden(); diff --git a/src/views/airtransport/conForConfigure.vue b/src/views/airtransport/conForConfigure.vue index e363e32..19b48c0 100644 --- a/src/views/airtransport/conForConfigure.vue +++ b/src/views/airtransport/conForConfigure.vue @@ -487,7 +487,6 @@ const _this = this selectExact(this.queryConfigure).then((response) => { const res = response.data - console.log(response.data) if (res.code !== '200') { return _this.$message.error('获取消息收发记录,失败!') } diff --git a/src/views/airtransport/configure.vue b/src/views/airtransport/configure.vue index 4812582..e7d1f94 100644 --- a/src/views/airtransport/configure.vue +++ b/src/views/airtransport/configure.vue @@ -93,7 +93,7 @@ configure:{ username:loginUserInfo.username, flightNo:undefined, - ietype:'0', + ietype:'1', reamrk:undefined, // accessFlag:'1', country:'', @@ -138,16 +138,15 @@ if (valid) { this.configure.createBy=loginUserInfo.username this.configure.username=loginUserInfo.username - console.log(this.configure.flightNo) addSchedule(this.configure).then(res=>{ let response=res.data; - console.log(response) if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; this.$router.push({path:'/queryConfigure',query:{flightNo:this.configure.flightNo}}); + this.$message.success(response.msg) }else{ - this.msg=response.msg; + this.$message.error(response.msg) } }); } else { @@ -167,7 +166,7 @@ return e.replace(/[^a-zA-Z0-9.-]/g,'').toUpperCase(); } }, - mounted(){ + activated(){ this.defaultData(); } } diff --git a/src/views/airtransport/confirmatory.vue b/src/views/airtransport/confirmatory.vue index 0bf30a5..6c99d01 100644 --- a/src/views/airtransport/confirmatory.vue +++ b/src/views/airtransport/confirmatory.vue @@ -218,11 +218,12 @@ addConfirm(this.confirmatory).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; this.$router.push({path:'/queryConfirmatory',query:{flightNo:this.confirmatory.flightNo,flightDate:this.confirmatory.flightDate}}); + this.$message.success(response.msg) }else{ - this.msg=response.msg; + this.$message.error(response.msg) } }); } else { @@ -235,17 +236,16 @@ sendForm(formName) { this.$refs[formName].validate((valid) => { if (valid) { - console.log(this.confirmatory) this.confirmatory.createBy=loginUserInfo.username - sendConfirmIn(this.confirmatory).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; this.$router.push({path:'/queryConfirmatory',query:{flightNo:this.confirmatory.flightNo,flightDate:this.confirmatory.flightDate}}); + this.$message.success(response.msg) }else{ - this.msg=response.msg; + this.$message.error(response.msg) } }); } else { @@ -265,7 +265,7 @@ return e.replace(/[^a-zA-Z0-9.-]/g,'').toUpperCase(); } }, - mounted(){ + activated(){ this.defaultData(); } } diff --git a/src/views/airtransport/declare.vue b/src/views/airtransport/declare.vue index cee976f..547410e 100644 --- a/src/views/airtransport/declare.vue +++ b/src/views/airtransport/declare.vue @@ -195,11 +195,12 @@ addConfirm(this.declare).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; + this.$message.success(response.msg) this.$router.push({path:'/queryDeclare',query:{flightNo:this.declare.flightNo,flightDate:this.declare.flightDate}}); }else{ - this.msg=response.msg; + this.$message.error(response.msg) } }); } else { @@ -216,11 +217,12 @@ sendConfirmOut(this.declare).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; + this.$message.success(response.msg) this.$router.push({path:'/queryDeclare',query:{flightNo:this.declare.flightNo,flightDate:this.declare.flightDate}}); }else{ - this.msg=response.msg; + this.$message.error(response.msg) } }); } else { @@ -240,7 +242,7 @@ return e.replace(/[^a-zA-Z0-9.-]/g,'').toUpperCase(); } }, - mounted(){ + activated(){ this.defaultData(); } } diff --git a/src/views/airtransport/departure.vue b/src/views/airtransport/departure.vue index 4197b66..a0cb330 100644 --- a/src/views/airtransport/departure.vue +++ b/src/views/airtransport/departure.vue @@ -216,11 +216,13 @@ addPrediction(this.departure).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; + this.$message.success(response.msg) this.$router.push({path:'/queryDeparture',query:{flightNo:this.departure.flightNo,flightDate:this.departure.flightDate}}); }else{ - this.msg=response.msg; + //this.msg=response.msg; + this.$message.error(response.msg) } }); } else { @@ -238,11 +240,12 @@ sendPredictionOut(this.departure).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; + this.$message.success(response.msg) this.$router.push({path:'/queryDeparture',query:{flightNo:this.departure.flightNo,flightDate:this.departure.flightDate}}); }else{ - this.msg=response.msg; + this.$message.error(response.msg) } }); } else { @@ -262,7 +265,7 @@ return e.replace(/[^a-zA-Z0-9.-]/g,'').toUpperCase(); } }, - mounted(){ + activated(){ this.defaultData(); } } diff --git a/src/views/airtransport/flight.vue b/src/views/airtransport/flight.vue index be15598..187222f 100644 --- a/src/views/airtransport/flight.vue +++ b/src/views/airtransport/flight.vue @@ -435,13 +435,15 @@ addFlight(this.flight).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; this.$router.push({path:'/queryFlights',query:{flightNo:this.flight.flightNo,flightDate:this.flight.flightDate}}); - this.centerDialogVisible=false; + //this.centerDialogVisible=false; + this.$message.success(response.msg) }else{ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; + this.$message.error(response.msg) } }); } else { @@ -457,13 +459,15 @@ sendFlight(this.flight).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; this.$router.push({path:'/queryFlights',query:{flightNo:this.flight.flightNo,flightDate:this.flight.flightDate}}); - this.centerDialogVisible=false; + //this.centerDialogVisible=false; + this.$message.success(response.msg) }else{ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; + this.$message.error(response.msg) } }); } else { @@ -505,7 +509,7 @@ } }, //渲染方法 - mounted(){ + activated(){ this.defaultData(); } } diff --git a/src/views/airtransport/flightplan.vue b/src/views/airtransport/flightplan.vue index 5808f64..5b4ccbc 100644 --- a/src/views/airtransport/flightplan.vue +++ b/src/views/airtransport/flightplan.vue @@ -257,9 +257,10 @@ addFlightPlan(this.flight).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; this.$router.push({path:'/queryFlightplan',query:{flightNo:this.flight.flightNo,flightDate:this.flight.flightDate,aircraftNo:this.flight.aircraftNo}}); + this.$message.success(response.msg) }else{ this.msg=response.msg; } @@ -277,9 +278,10 @@ sendFlightPlan(this.flight).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + // this.msg=response.msg; this.$router.push({path:'/queryFlightplan',query:{flightNo:this.flight.flightNo,flightDate:this.flight.flightDate,aircraftNo:this.flight.aircraftNo}}); + this.$message.success(response.msg) }else{ this.msg=response.msg; } @@ -304,7 +306,7 @@ }, }, - mounted(){ + activated(){ this.defaultData(); } } diff --git a/src/views/airtransport/outConfigure.vue b/src/views/airtransport/outConfigure.vue index 3452824..1c795af 100644 --- a/src/views/airtransport/outConfigure.vue +++ b/src/views/airtransport/outConfigure.vue @@ -78,7 +78,7 @@ outConfigure:{ username:loginUserInfo.username, flightNo:undefined, - ietype:'1', + ietype:'2', reamrk:undefined, // accessFlag:'2', createBy:loginUserInfo.username, @@ -113,11 +113,12 @@ addSchedule(this.outConfigure).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; + this.$message.success(response.msg) this.$router.push({path:'/queryFlightConfigure',query:{flightNo:this.outConfigure.flightNo}}); }else{ - this.msg=response.msg; + this.$message.error(response.msg) } }); } else { @@ -137,7 +138,7 @@ return e.replace(/[^a-zA-Z0-9.-]/g,'').toUpperCase(); } }, - mounted(){ + activated(){ this.defaultData(); } } diff --git a/src/views/airtransport/queryConfigure.vue b/src/views/airtransport/queryConfigure.vue index 161abde..e951447 100644 --- a/src/views/airtransport/queryConfigure.vue +++ b/src/views/airtransport/queryConfigure.vue @@ -159,7 +159,6 @@ let params={messageid:row.messageid}; selectReturnMsg(params).then(res=>{ let response=res.data.data; - console.log(response) this.gridData=response; }); }, @@ -174,7 +173,7 @@ //获取进港航班配置查询列表 submitForm() { let params = { - pageNum: this.pageNum, pageSize: this.pageSize, flightNo: this.queryConfigure.flightNo,ieType:'0' + pageNum: this.pageNum, pageSize: this.pageSize, flightNo: this.queryConfigure.flightNo,ieType:'2' }; this.tableloading = true; selectSchedule(params).then(res => { diff --git a/src/views/airtransport/queryFlightConfigure.vue b/src/views/airtransport/queryFlightConfigure.vue index 1ebcc08..9bcffa4 100644 --- a/src/views/airtransport/queryFlightConfigure.vue +++ b/src/views/airtransport/queryFlightConfigure.vue @@ -45,7 +45,7 @@ label="用户名"> </el-table-column> <el-table-column - prop="flightno" + prop="flightNo" label="航班号"> </el-table-column> <el-table-column @@ -180,6 +180,7 @@ selectSchedule(params).then(res => { let response = res.data.data; this.tableData = response.list; + console.log(response) this.tableloading = false; this.total = response.total; }); diff --git a/src/views/airtransport/queryForConfigure.vue b/src/views/airtransport/queryForConfigure.vue index 27e1ac3..5a17985 100644 --- a/src/views/airtransport/queryForConfigure.vue +++ b/src/views/airtransport/queryForConfigure.vue @@ -490,7 +490,6 @@ const _this = this selectPrePlanConfig(this.queryConfigure).then((response) => { const res = response.data - console.log(response.data) if (res.code !== '200') { return _this.$message.error('获取消息收发记录,失败!') } @@ -519,7 +518,6 @@ this.$refs.configure_addForm.validate(valid => { // 未通过,表单预校验 if (!valid) return - console.log(this.configure_addForm); addPrePlanConfig(this.configure_addForm).then((response) => { const res = response.data // 添加失败 @@ -541,7 +539,6 @@ // 打开编辑 handleEdit(index, row) { this.configure_addForm = Object.assign({}, row); - console.log(this.configure_addForm) this.configure_addForm.schedule.options=[]; for(var obj in row.schedulelist){ console.log(this.configure_addForm.schedule.options.push(row.schedulelist[obj]['weekday'])) diff --git a/src/views/airtransport/route.vue b/src/views/airtransport/route.vue index 34e2500..13f364a 100644 --- a/src/views/airtransport/route.vue +++ b/src/views/airtransport/route.vue @@ -109,7 +109,7 @@ </el-col> <el-col :span="8" style="margin-left: 120px"> <el-button type="primary" @click="submitForm('airline')">保 存</el-button> - <el-button type="success">保存并发送</el-button> + <!--<el-button type="success">保存并发送</el-button>--> </el-col> </el-form> </el-row> @@ -296,13 +296,15 @@ addRoute(this.airline).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; this.$router.push({path:'/queryRoute',query:{serialNo:this.airline.serialNo}}); - this.centerDialogVisible=false; + //this.centerDialogVisible=false; + this.$message.success(response.msg) }else{ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; + this.$message.error(response.msg) } }); } else { @@ -346,7 +348,7 @@ }, //渲染方法 - mounted(){ + activated(){ this.defaultData(); } } diff --git a/src/views/airtransport/routeaircraft.vue b/src/views/airtransport/routeaircraft.vue index c897f7d..55c5e09 100644 --- a/src/views/airtransport/routeaircraft.vue +++ b/src/views/airtransport/routeaircraft.vue @@ -279,11 +279,12 @@ addAirLineAircraft(this.aircraft).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; this.$router.push({path:'/queryRouteaircraft',query:{airwayCode:this.aircraft.airwayCode,aircraftNo:this.aircraft.aircraftNo},}); + this.$message.success(response.msg) }else{ - this.msg=response.msg; + this.$message.error(response.msg) } }); } else { @@ -300,11 +301,12 @@ sendAirLineAircraft(this.aircraft).then(res=>{ let response=res.data; if(response.code=='200'){ - this.centerDialogVisible=true; - this.msg=response.msg; + //this.centerDialogVisible=true; + //this.msg=response.msg; this.$router.push({path:'/queryRouteaircraft',query:{airwayCode:this.aircraft.airwayCode,aircraftNo:this.aircraft.aircraftNo},}); + this.$message.success(response.msg) }else{ - this.msg=response.msg; + this.$message.error(response.msg) } }); } else { @@ -325,7 +327,7 @@ } }, - mounted(){ + activated(){ this.defaultData(); } } diff --git a/src/views/exportorder/Exportorder.vue b/src/views/exportorder/Exportorder.vue index ef1d602..1a3fdf0 100644 --- a/src/views/exportorder/Exportorder.vue +++ b/src/views/exportorder/Exportorder.vue @@ -6,6 +6,9 @@ <el-input size="medium" v-model="queryInfo.ext1" class="" placeholder="客户编码"></el-input> </el-form-item> <el-form-item label=""> + <el-input size="medium" v-model="queryInfo.ext2" class="" placeholder="主单号"></el-input> + </el-form-item> + <el-form-item label=""> <el-input size="medium" v-model="queryInfo.orderno" placeholder="订单号"></el-input> </el-form-item> <el-form-item label=""> @@ -58,7 +61,7 @@ <el-form-item> <el-button size="medium" @click="getList" style="background: none">查询</el-button> </el-form-item> - <el-form-item> +<!-- <el-form-item> <el-upload class="upload-demo" action="" @@ -67,6 +70,9 @@ :show-file-list="false"> <el-button size="medium" type="primary">导入订单</el-button> </el-upload> + </el-form-item>--> + <el-form-item> + <el-button size="medium" @click="batchDelOrderByBeans" type="danger">批量删除</el-button> </el-form-item> </el-form> </div> @@ -163,6 +169,7 @@ </el-table-column> <el-table-column type="selection" width="55"></el-table-column> <el-table-column prop="ext1" label="客户编号" width="180"></el-table-column> + <el-table-column prop="ext2" label="主单号" width="180"></el-table-column> <el-table-column prop="orderno" label="订单编号" width="180"></el-table-column> <el-table-column prop="ordertype" label="订单类型" width="120"> <template slot-scope="scope"> @@ -210,6 +217,7 @@ <template slot-scope="scope"> <el-button type="text" size="small" @click="sendorder(scope.row)">订单申报</el-button> <el-button type="text" size="small" @click="sendDeclare(scope.row)">清单申报</el-button> + <el-button type="text" size="small" @click="deleteOrderByGuid(scope.row)">删除</el-button> </template> </el-table-column> </el-table> @@ -228,8 +236,9 @@ </template> <script> - import {sendOrder,selectLists,batchOrder,batchOrderImport,importExcel,eldhBatchDeclare,eldhImportDeclare, - eldBatchDeclare,eldImportDeclare,zfeldBatchDeclare,zfeldImportDeclare} from '../../api/consigner/exportOrder' + import {sendOrder,selectLists,batchOrder,batchOrderImport,eldhBatchDeclare,eldhImportDeclare, + eldBatchDeclare,eldImportDeclare,zfeldBatchDeclare,zfeldImportDeclare,deleteOrderByGuid, + batchDelOrderByBeans} from '../../api/consigner/exportOrder' export default { data() { return { @@ -272,6 +281,7 @@ orderno:'', ordertype:'', ext1:'', + ext2:'', starttime:'', endtime:'', pageNum:1, @@ -314,6 +324,7 @@ this.getList(); }, methods: { + //运单批量导入申报 zfbatchOrderImport({ file, onSuccess, onError }){ // 生成 FormData 对象 @@ -501,7 +512,7 @@ return true; // 允许上传 }, - uploadFile({ file, onSuccess, onError }){ + /*uploadFile({ file, onSuccess, onError }){ // 生成 FormData 对象 const formData = new FormData(); formData.append('file', file); @@ -518,7 +529,7 @@ this.$message.error(error.toString()) onError(error); // 调用 onError 回调通知上传失败 }) - }, + },*/ //订单申报 sendorder(row){ sendOrder(row).then((response)=>{ @@ -532,6 +543,44 @@ this.$message.error(error.toString()) }) }, + // 订单删除 + deleteOrderByGuid(row){ + const guid = row.guid; + deleteOrderByGuid({guid}).then((response) => { + const res = response.data; + const code = res.code; + const msg = res.msg; + if (code !== '200'){ + return this.$message.error(msg); + } + this.$message.success(`订单删除成功`); + this.getList(); + }).catch(error => { + this.$message.error(error.toString()) + }) + }, + // 订单批量删除 + batchDelOrderByBeans(){ + if (this.selectedRows.length!==0){ + batchDelOrderByBeans(this.selectedRows).then((response) => { + const res = response.data; + const code = res.code; + const msg = res.msg; + const data = res.data; + if (code !== '200'){ + const errMsg = `${msg}${data}`; + this.$message.error(errMsg); + return; + } + this.$message.success("订单批量删除成功"); + this.getList(); + }).catch(error => { + this.$message.error(error.toString()); + }) + }else { + this.$message.error('请勾选需要删除的订单信息!'); + } + }, //订单列表查询 getList(){ if(this.value2 !== null && this.value2 !== ""){ diff --git a/src/views/exportorder/ImportOrder.vue b/src/views/exportorder/ImportOrder.vue new file mode 100644 index 0000000..0a23314 --- /dev/null +++ b/src/views/exportorder/ImportOrder.vue @@ -0,0 +1,274 @@ +<template> + <div> + <div> + <el-form :inline="true" :model="queryInfo" class="demo-form-inline"> + <el-form-item label=""> + <el-select size="medium" v-model="queryInfo.clientCode" placeholder="客户编码" clearable> + <el-option + v-for="item in customerList" + :key="item.clientCode" + :label="item.clientName" + :value="item.clientCode" + > + </el-option> + </el-select> + </el-form-item> + <el-form-item label=""> + <el-select size="medium" v-model="queryInfo.fileStatus" placeholder="文件状态" clearable> + <el-option + v-for="item in fileStatus" + :key="item.value" + :label="item.label" + :value="item.value"> + </el-option> + </el-select> + </el-form-item> + <el-form-item label=""> + <el-input size="medium" v-model="queryInfo.fileName" placeholder="文件名称"></el-input> + </el-form-item> + <el-form-item> + <div class="block"> + <el-date-picker + style="background: none" + size="medium" + v-model="value2" + type="daterange" + align="right" + unlink-panels + range-separator="至" + start-placeholder="开始日期" + end-placeholder="结束日期" + value-format="yyyy-MM-dd HH:mm:ss" + :picker-options="pickerOptions"> + </el-date-picker> + </div> + </el-form-item> + <el-form-item> + <el-button type="primary" @click="getList">查询</el-button> + </el-form-item> + </el-form> + </div> + <div> + <el-row :gutter="20"> + <el-col :span="3"> + <el-button size="medium" @click="downloadOrderTemplate">模板下载</el-button> + </el-col> + <el-col :span="3"> + <el-upload + class="upload-demo" + action="" + :before-upload="beforeUpload" + :http-request="orderImport" + :show-file-list="false"> + <el-button size="medium" type="primary">导入订单</el-button> + </el-upload> + </el-col> + </el-row> + </div> + <el-row :gutter="20" style="height: 20px;"></el-row> + <div> + <el-table + :data="tableData" + style="width: 100%" + row-key="uuid" + border + stripe + > + <el-table-column prop="clientName" label="客户名称" width="180" show-overflow-tooltip></el-table-column> + <el-table-column prop="clientCode" label="客户编码" width="180" show-overflow-tooltip></el-table-column> + <el-table-column prop="fileStatus" label="文件状态" width="180" show-overflow-tooltip> + <template slot-scope="scope"> + <span v-if="scope.row.fileStatus === 1">入库中</span> + <span v-else-if="scope.row.fileStatus === 2">入库异常</span> + <span v-else-if="scope.row.fileStatus === 5">入库成功</span> + </template> + </el-table-column> + <el-table-column prop="fileName" label="文件名称" width="180" show-overflow-tooltip></el-table-column> + <el-table-column prop="handleRes" label="处理结果" width="180" show-overflow-tooltip></el-table-column> + <el-table-column prop="createTime" label="创建时间" width="180" show-overflow-tooltip></el-table-column> + </el-table> + </div> + <div class="block"> + <el-pagination + @size-change="handleSizeChange" + @current-change="handleCurrentChange" + :current-page="queryInfo.pageNum" + :page-sizes="[20, 30, 40, 100]" + :page-size="queryInfo.pageSize" + layout="total, sizes, prev, pager, next, jumper" + :total="total"> + </el-pagination> + </div> + </div> +</template> + +<script> + import {selectAll} from '../../api/consigner/customerconfig' + import {importExcelToMinio, selectFilePage} from '../../api/consigner/exportOrder' + export default { + data() { + return { + // 查询条件 + queryInfo: { + clientCode: '', + fileStatus: '', + fileName: '', + startTime: '', + endTime: '', + pageNum: 1, + pageSize: 20 + }, + // 列表数据 + tableData: [], + total: 0, + // 文件状态码 + fileStatus: [ + { + label: '入库中', + value: '1' + }, + { + label: '入库异常', + value: '2' + }, + { + label: '入库成功', + value: '5' + } + ], + pickerOptions: { + shortcuts: [{ + text: '最近一周', + onClick(picker) { + const end = new Date(); + const start = new Date(); + start.setTime(start.getTime() - 3600 * 1000 * 24 * 7); + picker.$emit('pick', [start, end]); + } + }, { + text: '最近一个月', + onClick(picker) { + const end = new Date(); + const start = new Date(); + start.setTime(start.getTime() - 3600 * 1000 * 24 * 30); + picker.$emit('pick', [start, end]); + } + }, { + text: '最近三个月', + onClick(picker) { + const end = new Date(); + const start = new Date(); + start.setTime(start.getTime() - 3600 * 1000 * 24 * 90); + picker.$emit('pick', [start, end]); + } + }] + }, + // 存储从后端获取的客户数据 + customerList: [], + value2:[], + } + }, + mounted() { + this.getCustomerList(); + this.getList(); + }, + methods: { + // 查询上传文件信息列表 + getList(){ + if (this.value2 !== null && this.value2 !== ''){ + this.queryInfo.startTime = this.value2[0]; + this.queryInfo.endTime = this.value2[1]; + } + selectFilePage(this.queryInfo).then((response) => { + const res = response.data; + const code = res.code; + const data = res.data; + if (code !== '200'){ + return this.$message.error("获取文件列表失败"); + } + this.tableData = data.list; + this.total = data.total; + this.$message.success("获取文件列表成功"); + this.queryInfo.startTime = ''; + this.queryInfo.endTime = ''; + }).catch(error => { + this.$message.error(error.toString()); + }) + }, + // 获取客户配置列表选项 + getCustomerList(){ + selectAll().then((response) =>{ + const res = response.data; + const code = res.code; + if (code !== '200'){ + return this.$message.error("客户信息获取失败"); + } + this.customerList = res.data; + } + ).catch(error => { + this.$message.error(error.toString()) + }) + }, + //导入订单excel + beforeUpload(file) { + // 检查文件类型 + const isExcel = file.type === 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet' || file.type === 'application/vnd.ms-excel'; + const fileMaxSize = 10 * 1024 * 1024; + if (!isExcel) { + this.$message.error('上传文件只能是 Excel 格式!'); + return false; // 取消文件上传 + } + // 检查文件大小 + const isLtMaxSize = file.size / 1024 / 1024 < fileMaxSize; + if (!isLtMaxSize) { + this.$message.error(`上传文件大小不能超过 ${fileMaxSize / (1024 * 1024)} MB!`); + return false; // 取消文件上传 + } + return true; // 允许上传 + }, + // 下载订单模板文件 + downloadOrderTemplate(){ + const fileUrl = '../../static/出口订单导入模板.xlsx'; + // 创建隐藏的<a>元素 + const link = document.createElement('a'); + link.href = fileUrl; + link.download = '出口订单导入模板.xlsx'; // 设置下载的文件名 + // 将<a>元素添加到DOM中 + document.body.appendChild(link); + // 触发点击事件 + link.click(); + // 移除<a>元素 + document.body.removeChild(link); + }, + // 导入订单文件到minio + orderImport({file, onSuccess, onError}){ + const formData = new FormData(); + formData.append('file', file); + importExcelToMinio(formData).then((response) => { + const res = response.data; + const code = res.code; + const msg = res.msg; + if (code !== '200'){ + return this.$message.error(msg); + } + this.$message.success(msg); + this.getList(); + onSuccess(res); + }).catch(error => { + this.$message.error(error.toString()); + onError(error); + }) + }, + //分页 + handleSizeChange(val) { + this.queryInfo.pageSize=val; + this.getList(); + }, + //分页 + handleCurrentChange(val) { + this.queryInfo.pageNum=val; + this.getList(); + }, + } + } +</script> diff --git a/src/views/nav3/C6Way.vue b/src/views/nav3/C6Way.vue index 9ae9bf3..15f8baa 100644 --- a/src/views/nav3/C6Way.vue +++ b/src/views/nav3/C6Way.vue @@ -2168,7 +2168,7 @@ Handling Information quantity_density:'', quantity_picecs:'', //体积 - quantity_volume:'0', + quantity_volume:'0.0', quantity_volume_code:'MC', quantity_weight:'', quantity_weight_code:'K', @@ -2987,7 +2987,7 @@ Handling Information if (totalVolume>0){ totalVolume = Math.floor(totalVolume * 100) / 100; } - + this.form.bill.quantity_volume=totalVolume; return { converted: output.trim(), totalVolume: totalVolume @@ -3110,7 +3110,7 @@ Handling Information this.form.cer.cer_signature=this.fileContent.O34; this.form.isu.isu_signature=this.fileContent.AF38; this.dimension_textarea=this.fileContent.AF23; - this.convertAndCalculateVolume(); + //this.convertAndCalculateVolume(); this.form.isu.isu_day_mounth_year=this.formattedDate(); }else{ @@ -3144,7 +3144,7 @@ Handling Information X38: X38, AF38: cleanString(AF38), }; - this.convertAndCalculateVolume(); + //this.convertAndCalculateVolume(); this.form.bill.waybillNum=this.fileContent.AF1; this.form.cvd.cvd_currency_code=this.fileContent.S16; this.form.rtg.destinationAirport=this.fileContent.A16; @@ -3165,7 +3165,6 @@ Handling Information this.dimension_textarea=this.fileContent.AF23; this.form.isu.isu_day_mounth_year=this.formattedDate(); - } } else { @@ -3173,6 +3172,7 @@ Handling Information } }; reader.readAsArrayBuffer(files); + this.convertAndCalculateVolume(); }, formattedDate() { // 格式化日期为 yyyy-MM-dd diff --git a/src/views/nav3/statistics.vue b/src/views/nav3/statistics.vue new file mode 100644 index 0000000..cc0097b --- /dev/null +++ b/src/views/nav3/statistics.vue @@ -0,0 +1,173 @@ +<template> + <div> + <el-form :inline="true" :model="formInline" class="demo-form-inline"> + <el-form-item label=""> + <div class="block"> + <el-date-picker + size="medium" + v-model="value2" + type="datetimerange" + :picker-options="pickerOptions" + value-format="yyyy-MM-dd HH:mm:ss" + range-separator="至" + start-placeholder="开始日期" + end-placeholder="结束日期" + align="right"> + </el-date-picker> + </div> + </el-form-item> + <el-form-item> + <el-button type="primary" size="medium" @click="onSubmit">查询</el-button> + </el-form-item> + <el-form-item> + <el-button type="primary" size="medium" @click="exportToExcel">导出</el-button> + </el-form-item> + </el-form> + <div style="margin-bottom: 10px"><span style="color: red">总计: {{ totalItems }} 主单: {{ emptyAwbhCount }} 分单: {{ nonEmptyAwbhCount }}</span></div> + <div> + <el-table + size="medium" + :data="tableData" + border + style="width: 100%"> + <el-table-column + prop="awba" + label="主单号" + width="180"> + </el-table-column> + <el-table-column + prop="awbh" + label="分单号" + width="180"> + </el-table-column> + <el-table-column + prop="billtype" + label="单证类型"> + </el-table-column> + <el-table-column + prop="costs" + label="应结费用"> + </el-table-column> + <el-table-column + prop="flightdate" + label="航班日期"> + </el-table-column> + </el-table> + </div> + </div> +</template> +<script> + import { + selectStatistics + } from '../../api/remote_interface/byont_import'; + import XLSX from 'xlsx'; + import { saveAs } from 'file-saver'; + import moment from 'moment'; + export default { + data() { + return { + pickerOptions: { + shortcuts: [{ + text: '最近一周', + onClick(picker) { + const end = new Date(); + const start = new Date(); + start.setTime(start.getTime() - 3600 * 1000 * 24 * 7); + picker.$emit('pick', [start, end]); + } + }, { + text: '最近一个月', + onClick(picker) { + const end = new Date(); + const start = new Date(); + start.setTime(start.getTime() - 3600 * 1000 * 24 * 30); + picker.$emit('pick', [start, end]); + } + }, { + text: '最近三个月', + onClick(picker) { + const end = new Date(); + const start = new Date(); + start.setTime(start.getTime() - 3600 * 1000 * 24 * 90); + picker.$emit('pick', [start, end]); + } + }] + }, + value2: '', + tableData: [], + query:{ + starttime:'', + endtime:'' + }, + formInline:{}, + columns: [ + { prop: 'awba', label: '主单号' }, + { prop: 'awbh', label: '分单号' }, + { prop: 'billtype', label: '单证类型' }, + { prop: 'costs', label: '应结费用' }, + { prop: 'flightdate', label: '航班日期' } + ] + }; + }, + computed: { + totalItems() { + return this.tableData.length; + }, + emptyAwbhCount() { + return this.tableData.filter(item => !item.awbh).length; + }, + nonEmptyAwbhCount() { + return this.tableData.filter(item => item.awbh).length; + } + }, + methods:{ + onSubmit(){ + if(this.value2 !== null && this.value2 !== ""){ + this.query.starttime = this.value2[0]; + this.query.endtime = this.value2[1]; + }else{ + return this.$message.error('请选取时间段!') + } + selectStatistics(this.query).then((response) => { + const res = response.data + if (res.code !== '200') { + return this.$message.error('获取消息收发记录,失败!') + } + // 获取列表数据 + this.tableData = res.data; + this.$message.success('获取消息收发记录,成功!'); + }).catch(error => { + // 关闭加载 + this.$message.error(error.toString()) + }) + }, + exportToExcel() { + // 创建一个新的工作簿 + const wb = XLSX.utils.book_new(); + + // 创建一个自定义的头部数组,按照 columns 中的顺序和 label + const header = this.columns.map(col => col.label); + + // 将 tableData 转换成二维数组,并添加到 worksheet 中 + const data = this.tableData.map(row => this.columns.map(col => row[col.prop])); + + // 使用 XLSX.utils.aoa_to_sheet 创建工作表,指定头部 + const ws = XLSX.utils.aoa_to_sheet([header, ...data]); + + // 添加 worksheet 到 workbook + XLSX.utils.book_append_sheet(wb, ws, 'Sheet1'); + + // 生成 Excel 文件并下载 + const wbout = XLSX.write(wb, { bookType: 'xlsx', type: 'array' }); + const blob = new Blob([wbout], { type: 'application/octet-stream' }); + + // 计算明天的日期 + const tomorrow = moment().add(1, 'days').format('M月D日'); + + // 使用 file-saver 保存文件,并使用明天的日期作为文件名 + saveAs(blob, `${tomorrow}航班结算统计.xlsx`); + } + } + + }; +</script> diff --git a/static/出口订单导入模板.xlsx b/static/出口订单导入模板.xlsx new file mode 100644 index 0000000..a6c4ddb Binary files /dev/null and b/static/出口订单导入模板.xlsx differ