Commit 709d0d2fc7e9a937584daba88420837024bfb479

Authored by 娄高锋
1 parent f819254f

青浦250411工单:行车路单加实际损失公里等。

src/main/java/com/bsth/service/realcontrol/impl/ScheduleRealInfoServiceImpl.java
... ... @@ -4491,12 +4491,13 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf
4491 4491 // int cjbc = scheduleRealInfoRepository.findCjbc(jName, clZbh, lpName);
4492 4492 // int ljbc = scheduleRealInfoRepository.findLjbc(jName, clZbh, lpName);
4493 4493 int jhbc = 0, cjbc = 0, ljbc = 0, sjbc = 0;
4494   - double jhlc = 0, yygl = 0, ksgl = 0, tempJhlc = 0, jcclc = 0, ljjcclc = 0, jhjcclc = 0;
4495   - double addMileage = 0, remMileage = 0, addgl = 0, remgl = 0;
  4494 + double jhlc = 0, yygl = 0, ksgl = 0, jcclc = 0, jhzks = 0, jhjcclc = 0;
  4495 + double addMileage = 0, remMileage = 0, sjssgl = 0;
4496 4496 Map<String, Object> map = new HashMap<String, Object>();
4497 4497 jhlc = culateMieageService.culateJhgl(lists);
4498 4498 jcclc = culateMieageService.culateJccgl(lists);
4499   - jhjcclc = culateMieageService.culateJhJccgl(lists);
  4499 + jhzks = culateMieageService.culateJhJccgl(lists);
  4500 + jhjcclc = culateMieageService.culateJhJccgl_real(lists);
4500 4501 remMileage = culateMieageService.culateLbgl(lists);
4501 4502 ksgl = culateMieageService.culateKsgl(lists_sj);
4502 4503 yygl = culateMieageService.culateSjgl(lists_sj);
... ... @@ -4505,14 +4506,17 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl&lt;ScheduleRealInf
4505 4506 cjbc = culateMieageService.culateLbbc(lists);
4506 4507 sjbc = culateMieageService.culateSjbc(lists_sj, "");
4507 4508 ljbc = culateMieageService.culateLjbc(lists_sj, "");
  4509 + sjssgl = Arith.sub(remMileage, addMileage);
4508 4510 double zyygl = Arith.add(yygl, addMileage);
4509 4511 double zksgl = Arith.add(ksgl, jcclc);
4510   - map.put("jhlc", Arith.add(jhlc, jhjcclc));
  4512 +
  4513 + map.put("jhlc", Arith.add(jhlc, jhzks));
4511 4514 map.put("yygljh", jhlc);
4512 4515 map.put("ssgl", remMileage);
4513 4516 map.put("ksgl", ksgl);
4514 4517 map.put("yyglsj", Arith.add(yygl, addMileage));
4515 4518 map.put("jcclc", jcclc);
  4519 + map.put("jhjcclc", jhjcclc);
4516 4520 map.put("jhbc", jhbc);
4517 4521 map.put("ljgl", addMileage);
4518 4522 map.put("ssbc", cjbc);
... ... @@ -4520,6 +4524,7 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl&lt;ScheduleRealInf
4520 4524 map.put("sjbc", sjbc);
4521 4525 map.put("zgl", Arith.add(zyygl, zksgl));
4522 4526 map.put("ljbc", ljbc);
  4527 + map.put("sjssgl", sjssgl); // 250423 实际损失公里:损失公里-加车公里,业主说是丢失公里和增加公里抵消掉,方便统计
4523 4528  
4524 4529 return map;
4525 4530  
... ...
src/main/java/com/bsth/service/report/CulateMileageService.java
... ... @@ -34,6 +34,8 @@ public interface CulateMileageService {
34 34 double culateJccgl(List<ScheduleRealInfo> lists);
35 35 double culateSjfyylc_spy(List<ScheduleRealInfo> lists);
36 36 double culateJhJccgl(List<ScheduleRealInfo> lists);
  37 + double culateJhKsgl_real(List<ScheduleRealInfo> lists);
  38 + double culateJhJccgl_real(List<ScheduleRealInfo> lists);
37 39  
38 40 double culateCJLC(List<ScheduleRealInfo> lists,String item);
39 41  
... ...
src/main/java/com/bsth/service/report/impl/CulateMileageServiceImpl.java
... ... @@ -665,13 +665,31 @@ public class CulateMileageServiceImpl implements CulateMileageService{
665 665 return sjbc;
666 666 }
667 667  
  668 + //空驶公里(空驶班次和子任务空驶,不含进出场班次);culateKsgl + culateJccgl = 总空驶公里
668 669 @Override
669 670 public double culateKsgl(List<ScheduleRealInfo> lists) {
670 671 // TODO Auto-generated method stub
671 672 double ksgl =0;
672 673 for (int i = 0; i < lists.size(); i++) {
673 674 ScheduleRealInfo scheduleRealInfo=lists.get(i);
674   - if (!isInOut(scheduleRealInfo)) {
  675 + if (scheduleRealInfo.getBcType().equals("ldks")) {
  676 + Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks();
  677 + if(childTaskPlans.isEmpty()){
  678 + if(!scheduleRealInfo.isDestroy())
  679 + ksgl =Arith.add(ksgl, scheduleRealInfo.getJhlc()==null?0:scheduleRealInfo.getJhlc());
  680 + }else{
  681 + Iterator<ChildTaskPlan> it = childTaskPlans.iterator();
  682 + while (it.hasNext()) {
  683 + ChildTaskPlan childTaskPlan = it.next();
  684 + if(childTaskPlan.getMileageType().equals("empty") && childTaskPlan.getCcId()==null){
  685 + if (!childTaskPlan.isDestroy()) {
  686 + Float jhgl=childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage();
  687 + ksgl=Arith.add(ksgl,jhgl);
  688 + }
  689 + }
  690 + }
  691 + }
  692 + }else if (!isInOut(scheduleRealInfo)) {
675 693 Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks();
676 694 if(!childTaskPlans.isEmpty()){
677 695 Iterator<ChildTaskPlan> it = childTaskPlans.iterator();
... ... @@ -690,6 +708,7 @@ public class CulateMileageServiceImpl implements CulateMileageService{
690 708 return ksgl;
691 709 }
692 710  
  711 + //进出场公里(进出场班次,不含空驶班次和子任务空驶);culateKsgl + culateJccgl = 总空驶公里
693 712 @Override
694 713 public double culateJccgl(List<ScheduleRealInfo> lists) {
695 714 // TODO Auto-generated method stub
... ... @@ -697,7 +716,7 @@ public class CulateMileageServiceImpl implements CulateMileageService{
697 716 for (int i = 0; i < lists.size(); i++) {
698 717 ScheduleRealInfo scheduleRealInfo=lists.get(i);
699 718 if (scheduleRealInfo.getBcType().equals("in")
700   - || scheduleRealInfo.getBcType().equals("out")||scheduleRealInfo.getBcType().equals("ldks")) {
  719 + || scheduleRealInfo.getBcType().equals("out")) {
701 720 Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks();
702 721 if(childTaskPlans.isEmpty()){
703 722 if(!scheduleRealInfo.isDestroy())
... ... @@ -821,6 +840,7 @@ public class CulateMileageServiceImpl implements CulateMileageService{
821 840 return m;
822 841 }
823 842  
  843 + //其实是计划总空驶公里(含计划进出场公里和计划空驶公里); = culateJhKsgl_real + culateJhJccgl_real
824 844 @Override
825 845 public double culateJhJccgl(List<ScheduleRealInfo> lists) {
826 846 // TODO Auto-generated method stub
... ... @@ -839,6 +859,40 @@ public class CulateMileageServiceImpl implements CulateMileageService{
839 859 return jcclc;
840 860 }
841 861  
  862 + //仅计划进出场公里
  863 + @Override
  864 + public double culateJhKsgl_real(List<ScheduleRealInfo> lists) {
  865 + double jcclc = 0;
  866 + for (int i = 0; i < lists.size(); i++) {
  867 + ScheduleRealInfo scheduleRealInfo=lists.get(i);
  868 + if(!scheduleRealInfo.isSflj() && !scheduleRealInfo.isCcService()){
  869 + if (scheduleRealInfo.getBcType().equals("ldks")) {
  870 + if(!scheduleRealInfo.isSflj()){
  871 + jcclc =Arith.add(jcclc, scheduleRealInfo.getJhlcOrig()==null?0:scheduleRealInfo.getJhlcOrig());
  872 + }
  873 + }
  874 + }
  875 + }
  876 + return jcclc;
  877 + }
  878 +
  879 + //仅计划进出场公里
  880 + @Override
  881 + public double culateJhJccgl_real(List<ScheduleRealInfo> lists) {
  882 + double jcclc = 0;
  883 + for (int i = 0; i < lists.size(); i++) {
  884 + ScheduleRealInfo scheduleRealInfo=lists.get(i);
  885 + if(!scheduleRealInfo.isSflj() && !scheduleRealInfo.isCcService()){
  886 + if (scheduleRealInfo.getBcType().equals("in") || scheduleRealInfo.getBcType().equals("out")) {
  887 + if(!scheduleRealInfo.isSflj()){
  888 + jcclc =Arith.add(jcclc, scheduleRealInfo.getJhlcOrig()==null?0:scheduleRealInfo.getJhlcOrig());
  889 + }
  890 + }
  891 + }
  892 + }
  893 + return jcclc;
  894 + }
  895 +
842 896 public static boolean isInOut(ScheduleRealInfo s){
843 897 boolean fage=false;
844 898 if(s.getBcType().equals("in")){
... ...
src/main/resources/static/pages/forms/mould/waybill_qingpu.xls
No preview for this file type
src/main/resources/static/pages/forms/statement/waybillQp.html
... ... @@ -375,40 +375,40 @@
375 375 </script>
376 376 <script type="text/html" id="ludan_3">
377 377 <tr>
378   - <td colspan="2">计划公里</td>
  378 + <td colspan="2" title="计划营运公里+计划进出场公里(含计划空驶公里)">计划公里</td>
379 379 <td>{{map.jhlc}}</td>
380   - <td colspan="2">营运公里(计划)</td>
  380 + <td colspan="2" title="计划营运公里">营运公里(计划)</td>
381 381 <td >{{map.yygljh}}</td>
382   - <td >损失公里</td>
  382 + <td title="烂班公里">损失公里</td>
383 383 <td>{{map.ssgl}}</td>
384   - <td colspan="3">空驶公里</td>
  384 + <td colspan="3" title="实际空驶公里,主要是子任务里的空驶公里">空驶公里</td>
385 385 <td colspan="1">{{map.ksgl}}</td>
386   - <td colspan="3">营运公里(实际)</td>
  386 + <td colspan="3" title="实际营运公里+临加公里">营运公里(实际)</td>
387 387 <td colspan="2">{{map.yyglsj}}</td>
388 388  
389 389 </tr>
390 390 <tr>
391   - <td colspan="2">计划班次</td>
  391 + <td colspan="2" title="计划营运班次数">计划班次</td>
392 392 <td>{{map.jhbc}}</td>
393   - <td colspan="2">进出场公里</td>
394   - <td>{{map.jcclc}}</td>
395   - <td >加车公里</td>
  393 + <td colspan="2" title="计划进出场公里(不含计划空驶公里)">进出场公里(计划)</td>
  394 + <td>{{map.jhjcclc}}</td>
  395 + <td title="临加公里">加车公里</td>
396 396 <td>{{map.ljgl}}</td>
397   - <td colspan="3">损失班次</td>
  397 + <td colspan="3" title="烂班班次数">损失班次</td>
398 398 <td colspan="1">{{map.ssbc}}</td>
399   - <td colspan="3"></td>
400   - <td colspan="2"></td>
  399 + <td colspan="3" title="实际进出场公里(不含实际空驶公里)">进出场公里(实际)</td>
  400 + <td colspan="2">{{map.jcclc}}</td>
401 401 </tr>
402 402 <tr>
403 403  
404   - <td colspan="2">实际班次</td>
  404 + <td colspan="2" title="实际营运班次数(计划班次-损失班次+加车班次)">实际班次</td>
405 405 <td>{{map.sjbc}}</td>
406   - <td colspan="2">总公里</td>
  406 + <td colspan="2" title="实际营运公里+临加公里+实际进出场公里(不含实际空驶公里)+实际空驶公里">总公里</td>
407 407 <td>{{map.zgl}}</td>
408   - <td >加车班次</td>
  408 + <td title="临加班次数">加车班次</td>
409 409 <td>{{map.ljbc}}</td>
410   -
411   - <td colspan="4"></td>
  410 + <td colspan="3" title="损失公里-加车公里">实际损失公里</td>
  411 + <td colspan="1">{{map.sjssgl}}</td>
412 412 <td colspan="5"></td>
413 413 </tr>
414 414 </script>
... ...