作者 xudada

运单,理货手动编辑,添加功能

@@ -533,6 +533,7 @@ @@ -533,6 +533,7 @@
533 <script> 533 <script>
534 import{addResponse,selectResponseList} from "../../api/InResponse"; 534 import{addResponse,selectResponseList} from "../../api/InResponse";
535 import { QueryData,ediAllocat,sendCreateMt6202,sendRemoveMt6202,sendCreateMt3202,sendRemoveMt3202 } from '../../api/Allocat' 535 import { QueryData,ediAllocat,sendCreateMt6202,sendRemoveMt6202,sendCreateMt3202,sendRemoveMt3202 } from '../../api/Allocat'
  536 + import loginUserInfo from '@/api/base'
536 export default{ 537 export default{
537 data(){ 538 data(){
538 return{ 539 return{
@@ -790,7 +791,7 @@ @@ -790,7 +791,7 @@
790 }, 791 },
791 //发送分拨申请报 792 //发送分拨申请报
792 importSend(index,row){ 793 importSend(index,row){
793 - const map = {'mt6202':row} 794 + const map = {'mt6202':row,'username':loginUserInfo.username}
794 sendCreateMt6202(map).then(res=>{ 795 sendCreateMt6202(map).then(res=>{
795 let response=res.data; 796 let response=res.data;
796 //console.log(res); 797 //console.log(res);
@@ -839,7 +840,8 @@ @@ -839,7 +840,8 @@
839 'reason' :this.Udform.operreason, 840 'reason' :this.Udform.operreason,
840 'contactName':this.Udform.operperson, 841 'contactName':this.Udform.operperson,
841 'contactTel':this.Udform.opertel, 842 'contactTel':this.Udform.opertel,
842 - 'carrier':this.rows.carrier} 843 + 'carrier':this.rows.carrier,
  844 + 'username':loginUserInfo.username}
843 if(this.rows.turntype=='MT6202'){ 845 if(this.rows.turntype=='MT6202'){
844 sendRemoveMt6202(map).then(res=>{ 846 sendRemoveMt6202(map).then(res=>{
845 let response=res.data; 847 let response=res.data;
@@ -889,7 +891,7 @@ @@ -889,7 +891,7 @@
889 //发送分拨运抵报 891 //发送分拨运抵报
890 arriveSend(index,row){ 892 arriveSend(index,row){
891 893
892 - const map = {'mt3202':row} 894 + const map = {'mt3202':row,'username':loginUserInfo.username}
893 sendCreateMt3202(map).then(res=>{ 895 sendCreateMt3202(map).then(res=>{
894 let response=res.data; 896 let response=res.data;
895 //console.log(res); 897 //console.log(res);
@@ -160,6 +160,7 @@ @@ -160,6 +160,7 @@
160 /*加载默认参数*/ 160 /*加载默认参数*/
161 getDefaultData(){ 161 getDefaultData(){
162 if(this.$route.query!=null){ 162 if(this.$route.query!=null){
  163 + console.log(this.$route.query)
163 this.ruleForm.flightno=JSON.parse(this.$route.query.flightno); 164 this.ruleForm.flightno=JSON.parse(this.$route.query.flightno);
164 this.ruleForm.flightdate=JSON.parse(this.$route.query.flightdate); 165 this.ruleForm.flightdate=JSON.parse(this.$route.query.flightdate);
165 this.ruleForm.originstation=JSON.parse(this.$route.query.originstation); 166 this.ruleForm.originstation=JSON.parse(this.$route.query.originstation);
@@ -645,7 +645,7 @@ @@ -645,7 +645,7 @@
645 <el-dialog title="回执明细列表" :visible.sync="dialogTableVisible" width="70%"> 645 <el-dialog title="回执明细列表" :visible.sync="dialogTableVisible" width="70%">
646 <el-table :data="gridData"> 646 <el-table :data="gridData">
647 <el-table-column property="busdate" label="时间" width="160"></el-table-column> 647 <el-table-column property="busdate" label="时间" width="160"></el-table-column>
648 - <el-table-column property="username" label="操作人" width="130"></el-table-column> 648 + <el-table-column property="operusername" label="操作人" width="130"></el-table-column>
649 <el-table-column property="buspiece" label="发送件数" width="130"></el-table-column> 649 <el-table-column property="buspiece" label="发送件数" width="130"></el-table-column>
650 <el-table-column property="busweight" label="发送重量" width="130"></el-table-column> 650 <el-table-column property="busweight" label="发送重量" width="130"></el-table-column>
651 <el-table-column property="cusrestext" label="回执内容"></el-table-column> 651 <el-table-column property="cusrestext" label="回执内容"></el-table-column>
@@ -721,7 +721,8 @@ @@ -721,7 +721,8 @@
721 import{addResponse,selectResponseList} from "../../api/InResponse"; 721 import{addResponse,selectResponseList} from "../../api/InResponse";
722 import FileSaver from "file-saver"; 722 import FileSaver from "file-saver";
723 import XLSX from "xlsx"; 723 import XLSX from "xlsx";
724 - import htmlToPdf from "../../api/htmlToPdf" 724 + import htmlToPdf from "../../api/htmlToPdf";
  725 + import loginUserInfo from '@/api/base.js'
725 export default { 726 export default {
726 data() { 727 data() {
727 /*初始数据*/ 728 /*初始数据*/
@@ -733,6 +734,7 @@ @@ -733,6 +734,7 @@
733 destinationstation: undefined, 734 destinationstation: undefined,
734 awba: undefined 735 awba: undefined
735 }, 736 },
  737 + LoginUserInfo: loginUserInfo,
736 FenQuery:{ 738 FenQuery:{
737 flightno: undefined, 739 flightno: undefined,
738 flightdate: undefined, 740 flightdate: undefined,
@@ -767,6 +769,7 @@ @@ -767,6 +769,7 @@
767 weight: undefined, 769 weight: undefined,
768 goodsname: undefined, 770 goodsname: undefined,
769 splitcode: 'T', 771 splitcode: 'T',
  772 + isDelete:0,
770 uldType: undefined, 773 uldType: undefined,
771 uldNo: undefined, 774 uldNo: undefined,
772 status: '22', 775 status: '22',
@@ -804,6 +807,9 @@ @@ -804,6 +807,9 @@
804 weight: undefined, 807 weight: undefined,
805 awbtype:'001', 808 awbtype:'001',
806 }, 809 },
  810 + userinfo: {
  811 + username: '11111'
  812 + },
807 waybill:undefined, 813 waybill:undefined,
808 customText:undefined 814 customText:undefined
809 }, 815 },
@@ -927,6 +933,7 @@ @@ -927,6 +933,7 @@
927 this.dialogTableVisible=true; 933 this.dialogTableVisible=true;
928 let response=res.data.data; 934 let response=res.data.data;
929 this.gridData=response; 935 this.gridData=response;
  936 + console.log(response)
930 }); 937 });
931 }, 938 },
932 //更改状态 939 //更改状态
@@ -986,8 +993,8 @@ @@ -986,8 +993,8 @@
986 this.dialogStatus='update'; 993 this.dialogStatus='update';
987 this.FenStatus='ediAwbh'; 994 this.FenStatus='ediAwbh';
988 this.ruleForm=row; 995 this.ruleForm=row;
989 - this.ruleForm.originstation=row.originstation+"-"+row.destinationstation;  
990 - this.ruleForm.flightno=row.carrier+row.flightno; 996 + this.ruleForm.originstation=this.defaultQuery.originstation+"-"+this.defaultQuery.destinationstation;
  997 + this.ruleForm.flightno=this.defaultQuery.flightno;
991 this.FenQuery.awba=row.awba; 998 this.FenQuery.awba=row.awba;
992 this.FenQuery.flightno= row.flightno; 999 this.FenQuery.flightno= row.flightno;
993 this.FenQuery.flightdate=row.flightdate 1000 this.FenQuery.flightdate=row.flightdate
@@ -1012,7 +1019,7 @@ @@ -1012,7 +1019,7 @@
1012 }else{ 1019 }else{
1013 row.flightno=row.flightno; 1020 row.flightno=row.flightno;
1014 } 1021 }
1015 - const map = {'mt1201':row} 1022 + const map = {'mt1201':row,'username':loginUserInfo.username}
1016 sendCreateMt1201(map).then(res=>{ 1023 sendCreateMt1201(map).then(res=>{
1017 let response=res.data; 1024 let response=res.data;
1018 //console.log(res); 1025 //console.log(res);
@@ -1062,7 +1069,8 @@ @@ -1062,7 +1069,8 @@
1062 'reason' :this.Udform.operreason, 1069 'reason' :this.Udform.operreason,
1063 'contactName':this.Udform.operperson, 1070 'contactName':this.Udform.operperson,
1064 'contactTel':this.Udform.opertel, 1071 'contactTel':this.Udform.opertel,
1065 - 'carrier':this.Udform.carrier} 1072 + 'carrier':this.Udform.carrier,
  1073 + 'username':loginUserInfo.username}
1066 sendRemoveMt1201(map).then(res=>{ 1074 sendRemoveMt1201(map).then(res=>{
1067 let response=res.data; 1075 let response=res.data;
1068 //console.log(res); 1076 //console.log(res);
@@ -1116,7 +1124,8 @@ @@ -1116,7 +1124,8 @@
1116 const map = {'mt1201':this.temprows, 1124 const map = {'mt1201':this.temprows,
1117 'reason' :this.Udform.operreason, 1125 'reason' :this.Udform.operreason,
1118 'contactName':this.Udform.operperson, 1126 'contactName':this.Udform.operperson,
1119 - 'contactTel':this.Udform.opertel} 1127 + 'contactTel':this.Udform.opertel,
  1128 + 'username':loginUserInfo.username}
1120 sendEditeMt1201(map).then(res=>{ 1129 sendEditeMt1201(map).then(res=>{
1121 let response=res.data; 1130 let response=res.data;
1122 //console.log(res); 1131 //console.log(res);
@@ -1158,6 +1167,7 @@ @@ -1158,6 +1167,7 @@
1158 this.defaultQuery.originstation = JSON.parse(this.$route.query.originstation); 1167 this.defaultQuery.originstation = JSON.parse(this.$route.query.originstation);
1159 this.defaultQuery.destinationstation = JSON.parse(this.$route.query.destinationstation); 1168 this.defaultQuery.destinationstation = JSON.parse(this.$route.query.destinationstation);
1160 this.defaultQuery.awba=JSON.parse(this.$route.query.awba); 1169 this.defaultQuery.awba=JSON.parse(this.$route.query.awba);
  1170 +
1161 }, 1171 },
1162 /*获取默认数据列表*/ 1172 /*获取默认数据列表*/
1163 getList(){ 1173 getList(){
@@ -1172,7 +1182,7 @@ @@ -1172,7 +1182,7 @@
1172 if(item.awba!=null&&item.awbh==""); 1182 if(item.awba!=null&&item.awbh=="");
1173 this.sumNmmsCount=Number(this.sumNmmsCount)+1; 1183 this.sumNmmsCount=Number(this.sumNmmsCount)+1;
1174 this.sumNmmsPrice=Number(this.sumNmmsPrice)+Number(item.piece); 1184 this.sumNmmsPrice=Number(this.sumNmmsPrice)+Number(item.piece);
1175 - this.sumNmmsWeight=Number(this.sumNmmsWeight)+Number(item.weight); 1185 + this.sumNmmsWeight=Number(Number(this.sumNmmsWeight)+Number(item.weight)).toFixed(2);
1176 }) 1186 })
1177 }); 1187 });
1178 }, 1188 },
@@ -1229,25 +1239,29 @@ @@ -1229,25 +1239,29 @@
1229 this.FenStatus='addAwbh'; 1239 this.FenStatus='addAwbh';
1230 }, 1240 },
1231 //新增原始舱单数据 1241 //新增原始舱单数据
1232 - createData(formName){ 1242 + createData:function(formName){
  1243 + let _this = this;
1233 this.$refs[formName].validate((valid) => { 1244 this.$refs[formName].validate((valid) => {
1234 if (valid) { 1245 if (valid) {
1235 - this.ruleForm.status='22'  
1236 - addMt1201(this.ruleForm).then(res=>{ 1246 + _this.ruleForm.userinfo = {
  1247 + username: ''
  1248 + }
  1249 + _this.ruleForm.userinfo.username=_this.LoginUserInfo.username;
  1250 + _this.ruleForm.status='22';
  1251 + addMt1201(_this.ruleForm).then(res=>{
1237 let response=res.data; 1252 let response=res.data;
1238 - //console.log(res);  
1239 - this.code=response.code;  
1240 - if(this.code=='200'){  
1241 - this.outerVisible = false;  
1242 - this.$refs[formName].resetFields();  
1243 - this.centerDialogVisible=true;  
1244 - this.msg=response.msg;  
1245 - this.getList(); 1253 + _this.code=response.code;
  1254 + if(_this.code=='200'){
  1255 + _this.outerVisible = false;
  1256 + _this.$refs[formName].resetFields();
  1257 + _this.centerDialogVisible=true;
  1258 + _this.msg=response.msg;
  1259 + _this.getList();
1246 }else{ 1260 }else{
1247 - this.outerVisible = false;  
1248 - this.centerDialogVisible=true;  
1249 - this.$refs[formName].resetFields();  
1250 - this.msg=response.msg; 1261 + _this.outerVisible = false;
  1262 + _this.centerDialogVisible=true;
  1263 + _this.$refs[formName].resetFields();
  1264 + _this.msg=response.msg;
1251 } 1265 }
1252 }); 1266 });
1253 } else { 1267 } else {
@@ -1258,22 +1272,27 @@ @@ -1258,22 +1272,27 @@
1258 1272
1259 }, 1273 },
1260 //修改原始舱单数据 1274 //修改原始舱单数据
1261 - updateData(formName){ 1275 + updateData: function(formName){
  1276 + let _this = this;
1262 this.$refs[formName].validate((valid) => { 1277 this.$refs[formName].validate((valid) => {
1263 if (valid) { 1278 if (valid) {
1264 - ediMt1201(this.ruleForm).then(res=>{ 1279 + _this.ruleForm.userinfo = {
  1280 + username: ''
  1281 + }
  1282 + _this.ruleForm.userinfo.username=_this.LoginUserInfo.username;
  1283 + ediMt1201(_this.ruleForm).then(res=>{
1265 let response=res.data; 1284 let response=res.data;
1266 //console.log(res); 1285 //console.log(res);
1267 - this.code=response.code;  
1268 - if(this.code=='200'){  
1269 - this.outerVisible = false;  
1270 - this.centerDialogVisible=true;  
1271 - this.msg=response.msg;  
1272 - this.getList(); 1286 + _this.code=response.code;
  1287 + if(_this.code=='200'){
  1288 + _this.outerVisible = false;
  1289 + _this.centerDialogVisible=true;
  1290 + _this.msg=response.msg;
  1291 + _this.getList();
1273 }else{ 1292 }else{
1274 - this.outerVisible = false;  
1275 - this.centerDialogVisible=true;  
1276 - this.msg=response.msg; 1293 + _this.outerVisible = false;
  1294 + _this.centerDialogVisible=true;
  1295 + _this.msg=response.msg;
1277 } 1296 }
1278 }); 1297 });
1279 } else { 1298 } else {
@@ -1301,8 +1320,9 @@ @@ -1301,8 +1320,9 @@
1301 this.$router.push({name:'分拨运抵',params:{carrier:row.carrier,flightno:row.flightno,awba:row.awba,flightdate:row.flightdate, 1320 this.$router.push({name:'分拨运抵',params:{carrier:row.carrier,flightno:row.flightno,awba:row.awba,flightdate:row.flightdate,
1302 turnpiece:row.awbinfo.pcs,turnweight:row.awbinfo.weight,customcode:row.customcode,goodsname:row.goodsname}}); 1321 turnpiece:row.awbinfo.pcs,turnweight:row.awbinfo.weight,customcode:row.customcode,goodsname:row.goodsname}});
1303 }, 1322 },
  1323 + //返回上一层
1304 back(){ 1324 back(){
1305 - this.$router.go(-1);//返回上一层 1325 + this.$router.go(-1);
1306 }, 1326 },
1307 1327
1308 }, 1328 },
@@ -441,6 +441,7 @@ @@ -441,6 +441,7 @@
441 <script> 441 <script>
442 import{addResponse,selectResponseList} from "../../api/InResponse"; 442 import{addResponse,selectResponseList} from "../../api/InResponse";
443 import { getMt5201List,addMt5201,ediMt5201,delMt5201,sendCreateMt520x,sendRemoveMt520x,selectCustomcode} from '../../api/mt5201' 443 import { getMt5201List,addMt5201,ediMt5201,delMt5201,sendCreateMt520x,sendRemoveMt520x,selectCustomcode} from '../../api/mt5201'
  444 + import loginUserInfo from '@/api/base'
444 export default { 445 export default {
445 data() { 446 data() {
446 return { 447 return {
@@ -451,6 +452,7 @@ @@ -451,6 +452,7 @@
451 destinationstation:undefined, 452 destinationstation:undefined,
452 awba:undefined, 453 awba:undefined,
453 }, 454 },
  455 + LoginUserInfo: loginUserInfo,
454 tableData: [], 456 tableData: [],
455 tableData2: [], 457 tableData2: [],
456 multipleSelection: [], 458 multipleSelection: [],
@@ -482,7 +484,10 @@ @@ -482,7 +484,10 @@
482 isdelete:undefined, 484 isdelete:undefined,
483 pcs:undefined, 485 pcs:undefined,
484 wei:undefined, 486 wei:undefined,
485 - ext5:undefined 487 + ext5:undefined,
  488 + userinfo: {
  489 + username: '11111'
  490 + },
486 }, 491 },
487 FenStatus:'', 492 FenStatus:'',
488 rules: { 493 rules: {
@@ -613,7 +618,7 @@ @@ -613,7 +618,7 @@
613 if(row.awbh==null){ 618 if(row.awbh==null){
614 row.awbh=""; 619 row.awbh="";
615 } 620 }
616 - const map = {'mt520x':row} 621 + const map = {'mt520x':row,'username':loginUserInfo.username}
617 sendCreateMt520x(map).then(res=>{ 622 sendCreateMt520x(map).then(res=>{
618 let response=res.data; 623 let response=res.data;
619 //console.log(res); 624 //console.log(res);
@@ -667,7 +672,8 @@ @@ -667,7 +672,8 @@
667 'contactName':this.Udform.operperson, 672 'contactName':this.Udform.operperson,
668 'contactTel':this.Udform.opertel, 673 'contactTel':this.Udform.opertel,
669 'rcfdep':this.rows.rcfdep, 674 'rcfdep':this.rows.rcfdep,
670 - 'carrier':this.rows.carrier} 675 + 'carrier':this.rows.carrier,
  676 + 'username':loginUserInfo.username}
671 sendRemoveMt520x(map).then(res=>{ 677 sendRemoveMt520x(map).then(res=>{
672 let response=res.data; 678 let response=res.data;
673 //console.log(res); 679 //console.log(res);
@@ -756,25 +762,30 @@ @@ -756,25 +762,30 @@
756 this.ruleForm.destinationstation=JSON.parse(this.$route.query.destinationstation); 762 this.ruleForm.destinationstation=JSON.parse(this.$route.query.destinationstation);
757 }, 763 },
758 //新增原始舱单数据 764 //新增原始舱单数据
759 - createData(formName){ 765 + createData:function(formName){
  766 + let _this = this;
760 this.$refs[formName].validate((valid) => { 767 this.$refs[formName].validate((valid) => {
761 if (valid) { 768 if (valid) {
762 - this.ruleForm.status='22'; 769 + _this.ruleForm.userinfo = {
  770 + username: ''
  771 + }
  772 + _this.ruleForm.userinfo.username=_this.LoginUserInfo.username;
  773 + _this.ruleForm.status='22';
763 //this.ruleForm.endtime=this.ruleForm.starttime.add(Calendar.MINUTE, 15); 774 //this.ruleForm.endtime=this.ruleForm.starttime.add(Calendar.MINUTE, 15);
764 - addMt5201(this.ruleForm).then(res=>{ 775 + addMt5201(_this.ruleForm).then(res=>{
765 let response=res.data; 776 let response=res.data;
766 - this.code=response.code;  
767 - if(this.code=='200'){  
768 - this.outerVisible = false;  
769 - this.$refs[formName].resetFields();  
770 - this.centerDialogVisible=true;  
771 - this.msg=response.msg;  
772 - this.getMt5201List(); 777 + _this.code=response.code;
  778 + if(_this.code=='200'){
  779 + _this.outerVisible = false;
  780 + _this.$refs[formName].resetFields();
  781 + _this.centerDialogVisible=true;
  782 + _this.msg=response.msg;
  783 + _this.getMt5201List();
773 }else{ 784 }else{
774 - this.outerVisible = false;  
775 - this.centerDialogVisible=true;  
776 - this.$refs[formName].resetFields();  
777 - this.msg=response.msg; 785 + _this.outerVisible = false;
  786 + _this.centerDialogVisible=true;
  787 + _this.$refs[formName].resetFields();
  788 + _this.msg=response.msg;
778 } 789 }
779 }); 790 });
780 } else { 791 } else {
@@ -784,21 +795,26 @@ @@ -784,21 +795,26 @@
784 }); 795 });
785 }, 796 },
786 //修改进港理货数据 797 //修改进港理货数据
787 - updateData(formName){ 798 + updateData:function(formName){
  799 + let _this = this;
788 this.$refs[formName].validate((valid) => { 800 this.$refs[formName].validate((valid) => {
789 if (valid) { 801 if (valid) {
790 - ediMt5201(this.ruleForm).then(res=>{ 802 + _this.ruleForm.userinfo = {
  803 + username: ''
  804 + }
  805 + _this.ruleForm.userinfo.username=_this.LoginUserInfo.username;
  806 + ediMt5201(_this.ruleForm).then(res=>{
791 let response=res.data; 807 let response=res.data;
792 - this.code=response.code;  
793 - if(this.code=='200'){  
794 - this.outerVisible = false;  
795 - this.centerDialogVisible=true;  
796 - this.msg=response.msg;  
797 - this.getMt5201List(); 808 + _this.code=response.code;
  809 + if(_this.code=='200'){
  810 + _this.outerVisible = false;
  811 + _this.centerDialogVisible=true;
  812 + _this.msg=response.msg;
  813 + _this.getMt5201List();
798 }else{ 814 }else{
799 - this.outerVisible = false;  
800 - this.centerDialogVisible=true;  
801 - this.msg=response.msg; 815 + _this.outerVisible = false;
  816 + _this.centerDialogVisible=true;
  817 + _this.msg=response.msg;
802 } 818 }
803 }); 819 });
804 } else { 820 } else {