Commit 99f219666c1070ed67fbce625e2bd679aea91d48
1 parent
f9aeede9
mcy
Showing
2 changed files
with
18 additions
and
15 deletions
src/main/java/com/bsth/service/forms/impl/FormsServiceImpl.java
| @@ -48,15 +48,18 @@ public class FormsServiceImpl implements FormsService { | @@ -48,15 +48,18 @@ public class FormsServiceImpl implements FormsService { | ||
| 48 | @Override | 48 | @Override |
| 49 | public List<Waybillday> waybillday(Map<String, Object> map) { | 49 | public List<Waybillday> waybillday(Map<String, Object> map) { |
| 50 | List list1 = new ArrayList<>();// | 50 | List list1 = new ArrayList<>();// |
| 51 | - String sql = "select y.RQ,y.XLBM,y.NBBM,y.JSY,y.JZL,y.YH,y.YH,c.personnel_name from bsth_c_ylb y" | ||
| 52 | - + " LEFT JOIN bsth_c_personnel c ON c.job_code=y.JSY " + " where to_days(y.RQ)=to_days('" | ||
| 53 | - + map.get("date").toString() + "') " + " and y.XLBM=" + map.get("line").toString() + " GROUP BY y.NBBM"; | ||
| 54 | - | 51 | + String sql ="select x.schedule_date,x.j_gh,x.cl_zbh,z.JZL,z.YH,z.personnel_name " |
| 52 | + + "from bsth_c_s_sp_info_real x join " | ||
| 53 | + + "( select y.RQ,y.XLBM,y.NBBM,y.JSY,y.JZL,y.YH,c.personnel_name from" | ||
| 54 | + + " bsth_c_ylb y LEFT JOIN bsth_c_personnel c ON c.job_code=y.JSY " | ||
| 55 | + + "where to_days(y.RQ)=to_days('"+map.get("date").toString() + "') and y.XLBM= '"+ map.get("line").toString()+"' GROUP BY y.NBBM) " | ||
| 56 | + + "z on x.cl_zbh=z.nbbm where to_days( x.schedule_date)=to_days('"+map.get("date").toString()+"') " | ||
| 57 | + + "and x.xl_bm='"+map.get("line").toString()+"' GROUP BY x.cl_zbh,j_gh"; | ||
| 55 | List<Waybillday> list = jdbcTemplate.query(sql, new RowMapper<Waybillday>() { | 58 | List<Waybillday> list = jdbcTemplate.query(sql, new RowMapper<Waybillday>() { |
| 56 | @Override | 59 | @Override |
| 57 | public Waybillday mapRow(ResultSet arg0, int arg1) throws SQLException { | 60 | public Waybillday mapRow(ResultSet arg0, int arg1) throws SQLException { |
| 58 | Waybillday wbd = new Waybillday(); | 61 | Waybillday wbd = new Waybillday(); |
| 59 | - wbd.setCarPlate(arg0.getString("NBBM")); | 62 | + wbd.setCarPlate(arg0.getString("cl_zbh")); |
| 60 | wbd.setJzl(arg0.getString("JZL")); | 63 | wbd.setJzl(arg0.getString("JZL")); |
| 61 | wbd.setYh(arg0.getString("YH")); | 64 | wbd.setYh(arg0.getString("YH")); |
| 62 | wbd.setjName(arg0.getString("personnel_name")); | 65 | wbd.setjName(arg0.getString("personnel_name")); |
| @@ -65,8 +68,8 @@ public class FormsServiceImpl implements FormsService { | @@ -65,8 +68,8 @@ public class FormsServiceImpl implements FormsService { | ||
| 65 | // wbd.setYl(arg0.getString("yl")); | 68 | // wbd.setYl(arg0.getString("yl")); |
| 66 | // wbd.setNbbm(arg0.getString("nbbm")); | 69 | // wbd.setNbbm(arg0.getString("nbbm")); |
| 67 | Map<String, Object> maps = new HashMap<>(); | 70 | Map<String, Object> maps = new HashMap<>(); |
| 68 | - maps = scheduleRealInfoService.findKMBC2(arg0.getString("JSY"), arg0.getString("nbbm"), | ||
| 69 | - arg0.getString("RQ")); | 71 | + maps = scheduleRealInfoService.findKMBC2(arg0.getString("j_gh"), arg0.getString("cl_zbh"), |
| 72 | + arg0.getString("schedule_date")); | ||
| 70 | wbd.setJzl1(maps.get("ksgl").toString()); | 73 | wbd.setJzl1(maps.get("ksgl").toString()); |
| 71 | wbd.setZlc(maps.get("realMileage").toString()); | 74 | wbd.setZlc(maps.get("realMileage").toString()); |
| 72 | 75 | ||
| @@ -81,8 +84,9 @@ public class FormsServiceImpl implements FormsService { | @@ -81,8 +84,9 @@ public class FormsServiceImpl implements FormsService { | ||
| 81 | @Override | 84 | @Override |
| 82 | public List<Linepasswengerflow> linepasswengerflow(Map<String, Object> map) { | 85 | public List<Linepasswengerflow> linepasswengerflow(Map<String, Object> map) { |
| 83 | String sql = " SELECT s.station_name,l.name,l.create_date from bsth_c_stationroute s " | 86 | String sql = " SELECT s.station_name,l.name,l.create_date from bsth_c_stationroute s " |
| 84 | - + " LEFT JOIN bsth_c_line l on s.line_code=l.line_code " + " where to_days(l.create_date)=to_days('" | ||
| 85 | - + map.get("date").toString() + "') " + " and l.line_code=" + map.get("line").toString() | 87 | + + " LEFT JOIN bsth_c_line l on s.line_code=l.line_code " |
| 88 | + + " where to_days(l.create_date)=to_days('"+map.get("date").toString() + "') " | ||
| 89 | + + " and l.line_code=" + map.get("line").toString() | ||
| 86 | + " GROUP BY s.station_name "; | 90 | + " GROUP BY s.station_name "; |
| 87 | 91 | ||
| 88 | List<Linepasswengerflow> list = jdbcTemplate.query(sql, new RowMapper<Linepasswengerflow>() { | 92 | List<Linepasswengerflow> list = jdbcTemplate.query(sql, new RowMapper<Linepasswengerflow>() { |
| @@ -341,7 +345,6 @@ public class FormsServiceImpl implements FormsService { | @@ -341,7 +345,6 @@ public class FormsServiceImpl implements FormsService { | ||
| 341 | return list; | 345 | return list; |
| 342 | } | 346 | } |
| 343 | 347 | ||
| 344 | - | ||
| 345 | // 营运线路出车率统计表 | 348 | // 营运线路出车率统计表 |
| 346 | @Override | 349 | @Override |
| 347 | public List<Turnoutrate> turnoutrate(Map<String, Object> map) { | 350 | public List<Turnoutrate> turnoutrate(Map<String, Object> map) { |
| @@ -398,7 +401,7 @@ public class FormsServiceImpl implements FormsService { | @@ -398,7 +401,7 @@ public class FormsServiceImpl implements FormsService { | ||
| 398 | tu.setBcjh(arg0.getString("jbc").toString()); | 401 | tu.setBcjh(arg0.getString("jbc").toString()); |
| 399 | tu.setBcsj(arg0.getString("sbc").toString()); | 402 | tu.setBcsj(arg0.getString("sbc").toString()); |
| 400 | tu.setBbzxl(result2 + "%");// 班次执行率 | 403 | tu.setBbzxl(result2 + "%");// 班次执行率 |
| 401 | - //tu.setSm(arg0.getString("gs_name").toString()); | 404 | + // tu.setSm(arg0.getString("gs_name").toString()); |
| 402 | tu.setGsgs(arg0.getString("gslsbm").toString()); | 405 | tu.setGsgs(arg0.getString("gslsbm").toString()); |
| 403 | tu.setFgsgs(arg0.getString("fgsbm").toString()); | 406 | tu.setFgsgs(arg0.getString("fgsbm").toString()); |
| 404 | return tu; | 407 | return tu; |
| @@ -463,7 +466,7 @@ public class FormsServiceImpl implements FormsService { | @@ -463,7 +466,7 @@ public class FormsServiceImpl implements FormsService { | ||
| 463 | tu.setBcjh(arg0.getString("jbc").toString()); | 466 | tu.setBcjh(arg0.getString("jbc").toString()); |
| 464 | tu.setBcsj(arg0.getString("sbc").toString()); | 467 | tu.setBcsj(arg0.getString("sbc").toString()); |
| 465 | tu.setBbzxl(result2 + "%");// 班次执行率 | 468 | tu.setBbzxl(result2 + "%");// 班次执行率 |
| 466 | - tu.setSm(arg0.getString("xl_name").toString()); | 469 | + tu.setSm(arg0.getString("xl_name").toString()); |
| 467 | tu.setGsgs(arg0.getString("gslsbm").toString()); | 470 | tu.setGsgs(arg0.getString("gslsbm").toString()); |
| 468 | tu.setFgsgs(arg0.getString("fgsbm").toString()); | 471 | tu.setFgsgs(arg0.getString("fgsbm").toString()); |
| 469 | return tu; | 472 | return tu; |
| @@ -474,7 +477,7 @@ public class FormsServiceImpl implements FormsService { | @@ -474,7 +477,7 @@ public class FormsServiceImpl implements FormsService { | ||
| 474 | return list; | 477 | return list; |
| 475 | } | 478 | } |
| 476 | 479 | ||
| 477 | - //营运线路名称统计表 | 480 | + // 营运线路名称统计表 |
| 478 | @Override | 481 | @Override |
| 479 | public List<Allline> allline(Map<String, Object> map) { | 482 | public List<Allline> allline(Map<String, Object> map) { |
| 480 | SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); | 483 | SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); |
| @@ -529,7 +532,7 @@ public class FormsServiceImpl implements FormsService { | @@ -529,7 +532,7 @@ public class FormsServiceImpl implements FormsService { | ||
| 529 | tu.setBcjh(arg0.getString("jbc").toString()); | 532 | tu.setBcjh(arg0.getString("jbc").toString()); |
| 530 | tu.setBcsj(arg0.getString("sbc").toString()); | 533 | tu.setBcsj(arg0.getString("sbc").toString()); |
| 531 | tu.setBbzxl(result2 + "%");// 班次执行率 | 534 | tu.setBbzxl(result2 + "%");// 班次执行率 |
| 532 | - //tu.setSm(arg0.getString("xl_name").toString()); | 535 | + // tu.setSm(arg0.getString("xl_name").toString()); |
| 533 | tu.setGsgs(arg0.getString("gslsbm").toString()); | 536 | tu.setGsgs(arg0.getString("gslsbm").toString()); |
| 534 | tu.setFgsgs(arg0.getString("fgsbm").toString()); | 537 | tu.setFgsgs(arg0.getString("fgsbm").toString()); |
| 535 | return tu; | 538 | return tu; |
src/main/resources/static/pages/forms/statement/waybillday.html
| @@ -94,7 +94,7 @@ | @@ -94,7 +94,7 @@ | ||
| 94 | $("#query").on("click",function(){ | 94 | $("#query").on("click",function(){ |
| 95 | line = $("#line").val(); | 95 | line = $("#line").val(); |
| 96 | date = $("#date").val(); | 96 | date = $("#date").val(); |
| 97 | - $post('/mcy_forms/waybillday',{line:line,date:date},function(result){ | 97 | + $post('/mcy_forms/waybillday',{line:line,date:$("#date").val(),type:'query'},function(result){ |
| 98 | $.each(result, function(i, obj) { | 98 | $.each(result, function(i, obj) { |
| 99 | obj.requestType = reqCodeMap[obj.requestType]; | 99 | obj.requestType = reqCodeMap[obj.requestType]; |
| 100 | }); | 100 | }); |