Commit 42e5542188b2f1d8a09d25e3d7976515adba0775
1 parent
d3b6eb98
班次到离站 导出,营运服务阶段报表
Showing
15 changed files
with
343 additions
and
123 deletions
src/main/java/com/bsth/controller/forms/ExportController.java
| ... | ... | @@ -253,7 +253,7 @@ public class ExportController { |
| 253 | 253 | } |
| 254 | 254 | |
| 255 | 255 | // 运营服务阶段报表 |
| 256 | - @RequestMapping(value = "/operationserviceExport", method = RequestMethod.POST) | |
| 256 | + @RequestMapping(value = "/operationserviceExport", method = RequestMethod.GET) | |
| 257 | 257 | public List<Map<String, Object>> operationserviceExport(@RequestParam Map<String, Object> map) { |
| 258 | 258 | SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"), sdfSimple = new SimpleDateFormat("yyyyMMdd"); |
| 259 | 259 | List<Iterator<?>> listI = new ArrayList<Iterator<?>>(); | ... | ... |
src/main/java/com/bsth/controller/forms/MCY_FormsController.java
| ... | ... | @@ -86,7 +86,7 @@ public class MCY_FormsController { |
| 86 | 86 | } |
| 87 | 87 | |
| 88 | 88 | // 运营服务阶段报表 |
| 89 | - @RequestMapping(value = "/operationservice", method = RequestMethod.POST) | |
| 89 | + @RequestMapping(value = "/operationservice", method = RequestMethod.GET) | |
| 90 | 90 | public List<Operationservice> operationservice(@RequestParam Map<String, Object> map) { |
| 91 | 91 | |
| 92 | 92 | return formsService.operationservice(map); | ... | ... |
src/main/java/com/bsth/controller/report/ReportController.java
| 1 | 1 | package com.bsth.controller.report; |
| 2 | 2 | |
| 3 | +import java.util.ArrayList; | |
| 3 | 4 | import java.util.HashMap; |
| 5 | +import java.util.Iterator; | |
| 4 | 6 | import java.util.List; |
| 5 | 7 | import java.util.Map; |
| 6 | 8 | |
| ... | ... | @@ -13,6 +15,7 @@ import org.springframework.web.bind.annotation.RestController; |
| 13 | 15 | import com.bsth.entity.excep.ArrivalInfo; |
| 14 | 16 | import com.bsth.entity.realcontrol.ScheduleRealInfo; |
| 15 | 17 | import com.bsth.service.report.ReportService; |
| 18 | +import com.bsth.util.ReportUtils; | |
| 16 | 19 | |
| 17 | 20 | @RestController |
| 18 | 21 | @RequestMapping("report") |
| ... | ... | @@ -31,12 +34,74 @@ public class ReportController { |
| 31 | 34 | @RequestParam String date,@RequestParam String fcsj,@RequestParam String ddsj){ |
| 32 | 35 | return service.queryListZdxx(line,date,clzbh,fcsj,ddsj); |
| 33 | 36 | } |
| 37 | + | |
| 38 | + @RequestMapping(value="/exportQueryListZdxx" ,method = RequestMethod.GET) | |
| 39 | + public List<Map<String, Object>> exportQueryListZdxx(@RequestParam String clzbh,@RequestParam String line, | |
| 40 | + @RequestParam String date,@RequestParam String fcsj,@RequestParam String ddsj){ | |
| 41 | + List<Iterator<?>> listI = new ArrayList<Iterator<?>>(); | |
| 42 | + ReportUtils ee = new ReportUtils(); | |
| 43 | + List<ArrivalInfo> list=service.queryListZdxx(line,date,clzbh,fcsj,ddsj); | |
| 44 | + List<Map<String, Object>> resList = new ArrayList<Map<String, Object>>(); | |
| 45 | + int i=1; | |
| 46 | + for (ArrivalInfo a:list ) { | |
| 47 | + Map<String, Object> m = new HashMap<String, Object>(); | |
| 48 | + m.put("i", i); | |
| 49 | + m.put("mbbm", a.getNbbm()); | |
| 50 | + m.put("stopName", a.getStopName()); | |
| 51 | + m.put("jzsj", a.getJzsj()); | |
| 52 | + m.put("czsj", a.getCzsj()); | |
| 53 | + m.put("upDown", a.getUpDown()==0?"上行":"下行"); | |
| 54 | + i++; | |
| 55 | + } | |
| 56 | + | |
| 57 | + try { | |
| 58 | + Map<String, Object> map=new HashMap<String, Object>(); | |
| 59 | + listI.add(resList.iterator()); | |
| 60 | + String path = this.getClass().getResource("/").getPath() + "static/pages/forms/"; | |
| 61 | + ee.excelReplace(listI, new Object[] { map }, path + "mould/inoutstation.xls", | |
| 62 | + path + "export/班次到离站.xls"); | |
| 63 | + } catch (Exception e) { | |
| 64 | + e.printStackTrace(); | |
| 65 | + } | |
| 66 | + return resList; | |
| 67 | + } | |
| 68 | + | |
| 34 | 69 | @RequestMapping(value="/queryListClzd" ,method = RequestMethod.GET) |
| 35 | 70 | public List<ArrivalInfo> queryListClzd(@RequestParam String zd,@RequestParam String line, |
| 36 | 71 | @RequestParam String zdlx,@RequestParam String fcsj,@RequestParam String ddsj){ |
| 37 | 72 | return service.queryListClzd(line,zd,zdlx,fcsj,ddsj); |
| 38 | 73 | } |
| 39 | 74 | |
| 75 | + @RequestMapping(value="/exportQueryListClzd" ,method = RequestMethod.GET) | |
| 76 | + public List<Map<String, Object>> exportQueryListClzd(@RequestParam String zd,@RequestParam String line, | |
| 77 | + @RequestParam String zdlx,@RequestParam String fcsj,@RequestParam String ddsj){ | |
| 78 | + List<Iterator<?>> listI = new ArrayList<Iterator<?>>(); | |
| 79 | + ReportUtils ee = new ReportUtils(); | |
| 80 | + List<ArrivalInfo> list=service.queryListClzd(line, zd, zdlx, fcsj, ddsj); | |
| 81 | + List<Map<String, Object>> resList = new ArrayList<Map<String, Object>>(); | |
| 82 | + int i=1; | |
| 83 | + for (ArrivalInfo a:list ) { | |
| 84 | + Map<String, Object> m = new HashMap<String, Object>(); | |
| 85 | + m.put("i", i); | |
| 86 | + m.put("nbbm", a.getNbbm()); | |
| 87 | + m.put("stopName", a.getStopName()); | |
| 88 | + m.put("jzsj", a.getJzsj()); | |
| 89 | + m.put("czsj", a.getCzsj()); | |
| 90 | + m.put("upDown", a.getUpDown()==0?"上行":"下行"); | |
| 91 | + i++; | |
| 92 | + } | |
| 93 | + | |
| 94 | + try { | |
| 95 | + Map<String, Object> map=new HashMap<String, Object>(); | |
| 96 | + listI.add(resList.iterator()); | |
| 97 | + String path = this.getClass().getResource("/").getPath() + "static/pages/forms/"; | |
| 98 | + ee.excelReplace(listI, new Object[] { map }, path + "mould/inoutstation.xls", | |
| 99 | + path + "export/班次到离站.xls"); | |
| 100 | + } catch (Exception e) { | |
| 101 | + e.printStackTrace(); | |
| 102 | + } | |
| 103 | + return resList; | |
| 104 | + } | |
| 40 | 105 | @RequestMapping(value = "/sreachZd", method = RequestMethod.GET) |
| 41 | 106 | public List<Map<String, String>> sreachPersonnel(@RequestParam String line,@RequestParam int zdlx,@RequestParam String zd) { |
| 42 | 107 | return service.sreachZd(line,zdlx, zd); | ... | ... |
src/main/java/com/bsth/entity/mcy_forms/Operationservice.java
| ... | ... | @@ -3,7 +3,7 @@ package com.bsth.entity.mcy_forms; |
| 3 | 3 | public class Operationservice { |
| 4 | 4 | |
| 5 | 5 | private String xlName;//线路 |
| 6 | - | |
| 6 | + private String xlBm;//线路编码 | |
| 7 | 7 | private String jzl;//加注量 |
| 8 | 8 | |
| 9 | 9 | private String xhl;//消耗量 |
| ... | ... | @@ -81,6 +81,14 @@ public class Operationservice { |
| 81 | 81 | public void setSjbc(String sjbc) { |
| 82 | 82 | this.sjbc = sjbc; |
| 83 | 83 | } |
| 84 | + | |
| 85 | + public String getXlBm() { | |
| 86 | + return xlBm; | |
| 87 | + } | |
| 88 | + | |
| 89 | + public void setXlBm(String xlBm) { | |
| 90 | + this.xlBm = xlBm; | |
| 91 | + } | |
| 84 | 92 | |
| 85 | 93 | |
| 86 | 94 | } | ... | ... |
src/main/java/com/bsth/repository/realcontrol/ScheduleRealInfoRepository.java
| ... | ... | @@ -151,18 +151,19 @@ public interface ScheduleRealInfoRepository extends BaseRepository<ScheduleRealI |
| 151 | 151 | |
| 152 | 152 | //按照时间段统计 |
| 153 | 153 | @EntityGraph(value = "scheduleRealInfo_cTasks", type = EntityGraph.EntityGraphType.FETCH) |
| 154 | - @Query(value="select DISTINCT s from ScheduleRealInfo s where s.xlBm like %?1% and DATE_FORMAT(s.scheduleDate,'%Y-%m-%d') between ?2 and ?3 and s.bcType not in ('in','out') and gsBm like %?4% and fgsBm like %?5% order by s.xlBm") | |
| 154 | + @Query(value="select DISTINCT s from ScheduleRealInfo s where s.xlBm like %?1% and DATE_FORMAT(s.scheduleDate,'%Y-%m-%d') between ?2 and ?3 and gsBm like %?4% and fgsBm like %?5% order by s.xlBm") | |
| 155 | 155 | List<ScheduleRealInfo> scheduleByDateAndLineTj(String line,String date,String date2,String gsdm,String fgsdm); |
| 156 | 156 | |
| 157 | 157 | //按照时间段统计 |
| 158 | 158 | @EntityGraph(value = "scheduleRealInfo_cTasks", type = EntityGraph.EntityGraphType.FETCH) |
| 159 | - @Query(value="select DISTINCT s from ScheduleRealInfo s where s.xlBm = ?1 and DATE_FORMAT(s.scheduleDate,'%Y-%m-%d') between ?2 and ?3 and s.bcType not in ('in','out') order by s.xlBm") | |
| 159 | + @Query(value="select DISTINCT s from ScheduleRealInfo s where s.xlBm = ?1 and DATE_FORMAT(s.scheduleDate,'%Y-%m-%d') between ?2 and ?3 order by s.xlBm") | |
| 160 | 160 | List<ScheduleRealInfo> scheduleByDateAndLineTj2(String line,String date,String date2); |
| 161 | 161 | //月报表 |
| 162 | 162 | @EntityGraph(value = "scheduleRealInfo_cTasks", type = EntityGraph.EntityGraphType.FETCH) |
| 163 | 163 | @Query(value="select DISTINCT s from ScheduleRealInfo s where s.xlBm = ?1 and DATE_FORMAT(s.scheduleDate,'%Y-%m-%d') between ?2 and ?3 order by s.xlBm") |
| 164 | 164 | List<ScheduleRealInfo> scheduleByDateAndLineYbb(String line,String date,String date2); |
| 165 | 165 | |
| 166 | + | |
| 166 | 167 | @Query(value="select new map(s.scheduleDate as scheduleDate,s.xlBm as xlBm,s.clZbh as clZbh,s.jGh as jGh,min(s.fcsj) as fcsj ) from ScheduleRealInfo s where s.xlBm like %?1% and DATE_FORMAT(s.scheduleDate,'%Y-%m-%d') = ?2 and s.gsBm like %?3% and s.fgsBm like %?4% GROUP BY xlBm,clZbh,jGh,scheduleDate,jGh ORDER BY clZbh,fcsj") |
| 167 | 168 | List<Map<String,Object>> yesterdayDataList(String line,String date,String gsbm,String fgsbm); |
| 168 | 169 | ... | ... |
src/main/java/com/bsth/service/forms/impl/FormsServiceImpl.java
| ... | ... | @@ -539,55 +539,102 @@ public class FormsServiceImpl implements FormsService { |
| 539 | 539 | // 运营服务阶段报表 |
| 540 | 540 | @Override |
| 541 | 541 | public List<Operationservice> operationservice(Map<String, Object> map) { |
| 542 | - | |
| 543 | - String sql = " SELECT r.schedule_date_str,r.xl_bm,r.xl_name,r.cl_zbh,r.j_gh,r.j_name,y.YH,y.JZL,r.gs_bm,r.gs_name,r.fgs_bm,r.fgs_name,r.bc_type " | |
| 544 | - + " FROM bsth_c_s_sp_info_real r " | |
| 545 | - // + "LEFT JOIN bsth_c_s_sp_info_real r on r.cl_zbh=y.NBBM" | |
| 546 | - + " left join bsth_c_ylb y ON r.cl_zbh = y.nbbm " | |
| 547 | - + " where 1=1 "; | |
| 548 | - if(map.get("startDate").toString()!=""){ | |
| 549 | - sql+=" and to_days(r.schedule_date_str) BETWEEN to_days('" + map.get("startDate").toString() + "') "; | |
| 550 | - } | |
| 551 | 542 | |
| 552 | - if(map.get("endDate").toString()!=""){ | |
| 553 | - sql+=" and to_days('" + map.get("endDate").toString() + "') "; | |
| 554 | - } | |
| 555 | - sql+=" and r.xl_bm='" + map.get("line").toString() + "'" ; | |
| 556 | - sql+=" and r.bc_type not in('in','out')"; | |
| 557 | - if(map.get("gsdmOperat").toString()!=""){ | |
| 558 | - sql+=" and r.gs_bm='"+map.get("gsdmOperat").toString()+"'"; | |
| 543 | + String xlbm=map.get("line").toString().trim(); | |
| 544 | + String gsdm=""; | |
| 545 | + if(map.get("gsdmOperat")!=null){ | |
| 546 | + gsdm=map.get("gsdmOperat").toString(); | |
| 559 | 547 | } |
| 560 | - if(map.get("fgsdmOperat").toString()!=""){ | |
| 561 | - sql+=" and r.fgs_bm='"+map.get("fgsdmOperat").toString()+"'"; | |
| 548 | + String fgsdm=""; | |
| 549 | + if(map.get("fgsdmOperat")!=null){ | |
| 550 | + fgsdm=map.get("fgsdmOperat").toString(); | |
| 551 | + } | |
| 552 | + startDate=map.get("startDate").toString(); | |
| 553 | + endDate =map.get("endDate").toString(); | |
| 554 | + String sql="select r.xl_bm" | |
| 555 | + + " from bsth_c_s_sp_info_real r where" | |
| 556 | + + " r.schedule_date_str BETWEEN '"+startDate+"' and '"+endDate+"'"; | |
| 557 | + if(xlbm.equals("")){ | |
| 558 | + sql +="and r.gs_bm='"+gsdm+"' " | |
| 559 | + + " and r.fgs_bm='"+fgsdm+"'"; | |
| 560 | + }else{ | |
| 561 | + sql += " and r.xl_bm = '"+xlbm+"'"; | |
| 562 | 562 | } |
| 563 | - sql += " AND r.gs_bm is not null"; | |
| 564 | - sql += " GROUP BY r.xl_bm,r.xl_name,r.cl_zbh,r.j_gh,r.j_name,y.YH,y.JZL,r.gs_bm,r.gs_name,r.fgs_bm,r.fgs_name"; | |
| 565 | - startDate = map.get("startDate").toString(); | |
| 566 | - endDate = map.get("endDate").toString(); | |
| 567 | - List<Operationservice> list = jdbcTemplate.query(sql, new RowMapper<Operationservice>() { | |
| 568 | - | |
| 569 | - @Override | |
| 570 | - public Operationservice mapRow(ResultSet arg0, int arg1) throws SQLException { | |
| 571 | - Operationservice op = new Operationservice(); | |
| 572 | - op.setXlName(arg0.getString("xl_name")); | |
| 573 | - op.setJzl(arg0.getString("JZL")); | |
| 574 | - op.setXhl(arg0.getString("YH")); | |
| 575 | - op.setClzbh(arg0.getString("cl_zbh")); | |
| 576 | - op.setJname(arg0.getString("j_name")); | |
| 563 | + sql += " group by r.xl_bm"; | |
| 564 | + | |
| 565 | + | |
| 566 | + List<Operationservice> list= jdbcTemplate.query(sql, new RowMapper<Operationservice>() { | |
| 567 | + @Override | |
| 568 | + public Operationservice mapRow(ResultSet arg0, int arg1) throws SQLException { | |
| 569 | + Operationservice ve = new Operationservice(); | |
| 570 | + ve.setXlBm(arg0.getString("xl_bm")); | |
| 571 | + return ve; | |
| 572 | + } | |
| 573 | + }); | |
| 574 | + | |
| 575 | + String ylbSql=" select * from bsth_c_ylb where rq BETWEEN '"+startDate+"' and '"+endDate+"'"; | |
| 576 | + if(xlbm.equals("")){ | |
| 577 | + ylbSql +="and ssgsdm='"+gsdm+"' " | |
| 578 | + + " and fgsdm='"+fgsdm+"'"; | |
| 579 | + }else{ | |
| 580 | + ylbSql += " and xlbm = '"+xlbm+"'"; | |
| 581 | + } | |
| 582 | + List<Ylb> ylbList= jdbcTemplate.query(ylbSql, new RowMapper<Ylb>() { | |
| 583 | + @Override | |
| 584 | + public Ylb mapRow(ResultSet arg0, int arg1) throws SQLException { | |
| 585 | + Ylb y = new Ylb(); | |
| 586 | + y.setXlbm(arg0.getString("xlbm")); | |
| 587 | + y.setJzl(arg0.getDouble("jzl")); | |
| 588 | + y.setYh(arg0.getDouble("yh")); | |
| 589 | + return y; | |
| 590 | + } | |
| 591 | + }); | |
| 592 | + List<ScheduleRealInfo> listReal; | |
| 593 | + if(xlbm.equals("")){ | |
| 594 | + listReal=scheduleRealInfoRepository.scheduleByDateAndLineTj(xlbm, startDate, endDate, gsdm, fgsdm); | |
| 595 | + }else{ | |
| 596 | + listReal=scheduleRealInfoRepository.scheduleByDateAndLineTj2(xlbm, startDate, endDate); | |
| 597 | + } | |
| 598 | + | |
| 599 | + for (int i = 0; i < list.size(); i++) { | |
| 600 | + Operationservice o=list.get(i); | |
| 601 | + String line=o.getXlBm(); | |
| 602 | + String xlname=BasicData.lineCode2NameMap.get(line); | |
| 603 | + o.setXlName(xlname); | |
| 604 | + | |
| 605 | + List<ScheduleRealInfo> newList=new ArrayList<ScheduleRealInfo>(); | |
| 606 | + for (int j = 0; j < listReal.size(); j++) { | |
| 607 | + ScheduleRealInfo s=listReal.get(j); | |
| 608 | + if(s.getXlBm().equals(line)){ | |
| 609 | + newList.add(s); | |
| 610 | + } | |
| 611 | + } | |
| 612 | + | |
| 613 | + int sjbc=culateMileageService.culateSjbc(newList,""); | |
| 614 | + int ljbc=culateMileageService.culateLjbc(newList,""); | |
| 615 | + double ksgl=culateMileageService.culateKsgl(newList); | |
| 616 | + double jccgl=culateMileageService.culateJccgl(newList); | |
| 617 | + | |
| 618 | + double sjgl=culateMileageService.culateSjgl(newList); | |
| 619 | + double ljgl=culateMileageService.culateLjgl(newList); | |
| 577 | 620 | |
| 578 | - return op; | |
| 621 | + o.setEmptMileage(String.valueOf(Arith.add(ksgl, jccgl))); | |
| 622 | + o.setXsgl(String.valueOf(Arith.add(sjgl, ljgl))); | |
| 623 | + o.setSjbc(String.valueOf(sjbc+ljbc)); | |
| 624 | + | |
| 625 | + double jzl=0.0; | |
| 626 | + double xhl=0.0; | |
| 627 | + for (int j = 0; j < ylbList.size(); j++) { | |
| 628 | + Ylb t=ylbList.get(j); | |
| 629 | + if(t.getXlbm().equals(line)){ | |
| 630 | + jzl=Arith.add(jzl, t.getJzl()); | |
| 631 | + xhl=Arith.add(xhl, t.getYh()); | |
| 632 | + } | |
| 633 | + } | |
| 634 | + | |
| 635 | + o.setJzl(String.valueOf(jzl)); | |
| 636 | + o.setXhl(String.valueOf(xhl)); | |
| 579 | 637 | } |
| 580 | - }); | |
| 581 | - | |
| 582 | - for(int i=0;i<list.size();i++){ | |
| 583 | - Operationservice o=list.get(i); | |
| 584 | - Map<String, Object> maps = new HashMap<>(); | |
| 585 | - maps = commonService.findKMBC1(o.getJname(), o.getClzbh(), startDate, | |
| 586 | - endDate); | |
| 587 | - o.setXsgl(maps.get("jhlc").toString() == null ? "" : maps.get("jhlc").toString()); | |
| 588 | - o.setEmptMileage(maps.get("ksgl").toString() == null ? "" : maps.get("ksgl").toString()); | |
| 589 | - o.setSjbc(maps.get("sjbc").toString() == null ? "" : maps.get("sjbc").toString()); | |
| 590 | - } | |
| 591 | 638 | return list; |
| 592 | 639 | } |
| 593 | 640 | ... | ... |
src/main/java/com/bsth/service/realcontrol/impl/ScheduleRealInfoServiceImpl.java
| ... | ... | @@ -3,6 +3,7 @@ package com.bsth.service.realcontrol.impl; |
| 3 | 3 | import com.alibaba.fastjson.JSON; |
| 4 | 4 | import com.alibaba.fastjson.JSONArray; |
| 5 | 5 | import com.alibaba.fastjson.JSONObject; |
| 6 | +import com.alibaba.fastjson.support.odps.udf.CodecCheck.A; | |
| 6 | 7 | import com.bsth.common.Constants; |
| 7 | 8 | import com.bsth.common.ResponseCode; |
| 8 | 9 | import com.bsth.controller.realcontrol.dto.ChangePersonCar; |
| ... | ... | @@ -1646,9 +1647,11 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 1646 | 1647 | List<ScheduleRealInfo> lists = scheduleRealInfoRepository.scheduleByDateAndLine2(line, date); |
| 1647 | 1648 | Map<String, Object> map = new HashMap<String, Object>(); |
| 1648 | 1649 | map.put("xlName", xlName); |
| 1649 | - map.put("jhlc", culateService.culateJhgl(lists)); | |
| 1650 | + double jhlc=culateService.culateJhgl(lists); | |
| 1651 | + map.put("jhlc",jhlc); | |
| 1650 | 1652 | map.put("sjgl", Arith.add(culateService.culateSjgl(lists),culateService.culateLjgl(lists))); |
| 1651 | - map.put("ssgl", culateService.culateLbgl(lists)); | |
| 1653 | + double lbgl=culateService.culateLbgl(lists); | |
| 1654 | + map.put("ssgl", lbgl); | |
| 1652 | 1655 | map.put("ssgl_lz", culateService.culateCJLC(lists, "路阻")); |
| 1653 | 1656 | map.put("ssgl_dm", culateService.culateCJLC(lists, "吊慢")); |
| 1654 | 1657 | map.put("ssgl_gz", culateService.culateCJLC(lists, "故障")); |
| ... | ... | @@ -1665,7 +1668,8 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 1665 | 1668 | double ssgl_qt=culateService.culateCJLC(lists, "其他"); |
| 1666 | 1669 | map.put("ssgl_other", Arith.add(Arith.add(ssgl_pc, ssgl_by),Arith.add(ssgl_cj, ssgl_qt))); |
| 1667 | 1670 | map.put("ssbc", culateService.culateLbbc(lists)); |
| 1668 | - map.put("ljgl", culateService.culateLjgl(lists)); | |
| 1671 | + double ljgl=culateService.culateLjgl(lists); | |
| 1672 | + map.put("ljgl", ljgl); | |
| 1669 | 1673 | map.put("jhbc", culateService.culateJhbc(lists,"")); |
| 1670 | 1674 | map.put("jhbc_m", culateService.culateJhbc(lists, "zgf")); |
| 1671 | 1675 | map.put("jhbc_a", culateService.culateJhbc(lists, "wgf")); |
| ... | ... | @@ -1685,6 +1689,7 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 1685 | 1689 | map.put("djg_m", 0); |
| 1686 | 1690 | map.put("djg_a", 0); |
| 1687 | 1691 | map.put("djg_time", 0); |
| 1692 | + map.put("jls", Arith.sub(Arith.add(jhlc, ljgl), lbgl)); | |
| 1688 | 1693 | lMap.add(map); |
| 1689 | 1694 | return lMap; |
| 1690 | 1695 | } |
| ... | ... | @@ -2238,8 +2243,23 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 2238 | 2243 | public final Map<String, Object> staticTj(List<ScheduleRealInfo> lists){ |
| 2239 | 2244 | Map<String, Object> map = new HashMap<String, Object>(); |
| 2240 | 2245 | map.put("xlName", lists.get(0).getXlName()); |
| 2241 | - map.put("jhlc", culateService.culateJhgl(lists)); | |
| 2242 | - map.put("sjgl", Arith.add(culateService.culateSjgl(lists),culateService.culateLjgl(lists))); | |
| 2246 | + double jhyygl=culateService.culateJhgl(lists);//计划营运公里 | |
| 2247 | + double jhjcclc= culateService.culateJhJccgl(lists);//计划进出场公里(计划空驶公里) | |
| 2248 | + map.put("jhlc", jhyygl); | |
| 2249 | + map.put("jcclc", jhjcclc); | |
| 2250 | + map.put("jhzlc", Arith.add(jhyygl, jhjcclc)); | |
| 2251 | + | |
| 2252 | + double ljgl= culateService.culateLjgl(lists); | |
| 2253 | + double sjyygl= culateService.culateSjgl(lists); | |
| 2254 | + double zyygl= Arith.add(sjyygl,ljgl); | |
| 2255 | + | |
| 2256 | + double sjjccgl=culateService.culateJccgl(lists); | |
| 2257 | + double sjksgl=culateService.culateKsgl(lists); | |
| 2258 | + double zksgl=Arith.add(sjjccgl, sjksgl); | |
| 2259 | + map.put("sjzgl", Arith.add(zyygl, zksgl)); | |
| 2260 | + map.put("sjgl",zyygl); | |
| 2261 | + map.put("sjksgl", zksgl); | |
| 2262 | + | |
| 2243 | 2263 | map.put("ssgl", culateService.culateLbgl(lists)); |
| 2244 | 2264 | map.put("ssgl_lz", culateService.culateCJLC(lists, "路阻")); |
| 2245 | 2265 | map.put("ssgl_dm", culateService.culateCJLC(lists, "吊慢")); |
| ... | ... | @@ -2253,7 +2273,7 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 2253 | 2273 | map.put("ssgl_yw", culateService.culateCJLC(lists, "援外")); |
| 2254 | 2274 | map.put("ssgl_other", culateService.culateCJLC(lists, "其他")); |
| 2255 | 2275 | map.put("ssbc", culateService.culateLbbc(lists)); |
| 2256 | - map.put("ljgl", culateService.culateLjgl(lists)); | |
| 2276 | + map.put("ljgl", ljgl); | |
| 2257 | 2277 | map.put("jhbc", culateService.culateJhbc(lists,"")); |
| 2258 | 2278 | map.put("jhbc_m", culateService.culateJhbc(lists, "zgf")); |
| 2259 | 2279 | map.put("jhbc_a", culateService.culateJhbc(lists, "wgf")); |
| ... | ... | @@ -2316,8 +2336,22 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 2316 | 2336 | |
| 2317 | 2337 | Map<String, Object> map = new HashMap<String, Object>(); |
| 2318 | 2338 | map.put("xlName", "合计"); |
| 2319 | - map.put("jhlc", culateService.culateJhgl(list)); | |
| 2320 | - map.put("sjgl", Arith.add(culateService.culateSjgl(list),culateService.culateLjgl(list))); | |
| 2339 | + double jhyygl=culateService.culateJhgl(list);//计划营运公里 | |
| 2340 | + double jhjcclc= culateService.culateJhJccgl(list);//计划进出场公里(计划空驶公里) | |
| 2341 | + map.put("jhlc", jhyygl); | |
| 2342 | + map.put("jcclc", jhjcclc); | |
| 2343 | + map.put("jhzlc", Arith.add(jhyygl, jhjcclc)); | |
| 2344 | + | |
| 2345 | + double ljgl= culateService.culateLjgl(list); | |
| 2346 | + double sjyygl= culateService.culateSjgl(list); | |
| 2347 | + double zyygl= Arith.add(sjyygl,ljgl); | |
| 2348 | + | |
| 2349 | + double sjjccgl=culateService.culateJccgl(list); | |
| 2350 | + double sjksgl=culateService.culateKsgl(list); | |
| 2351 | + double zksgl=Arith.add(sjjccgl, sjksgl); | |
| 2352 | + map.put("sjzgl", Arith.add(zyygl, zksgl)); | |
| 2353 | + map.put("sjgl",zyygl); | |
| 2354 | + map.put("sjksgl", zksgl); | |
| 2321 | 2355 | map.put("ssgl", culateService.culateLbgl(list)); |
| 2322 | 2356 | map.put("ssgl_lz", culateService.culateCJLC(list, "路阻")); |
| 2323 | 2357 | map.put("ssgl_dm", culateService.culateCJLC(list, "吊慢")); |
| ... | ... | @@ -2331,7 +2365,7 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 2331 | 2365 | map.put("ssgl_yw", culateService.culateCJLC(list, "援外")); |
| 2332 | 2366 | map.put("ssgl_other", culateService.culateCJLC(list, "其他")); |
| 2333 | 2367 | map.put("ssbc", culateService.culateLbbc(list)); |
| 2334 | - map.put("ljgl", culateService.culateLjgl(list)); | |
| 2368 | + map.put("ljgl", ljgl); | |
| 2335 | 2369 | map.put("jhbc", culateService.culateJhbc(list,"")); |
| 2336 | 2370 | map.put("jhbc_m", culateService.culateJhbc(list, "zgf")); |
| 2337 | 2371 | map.put("jhbc_a", culateService.culateJhbc(list, "wgf")); |
| ... | ... | @@ -2506,7 +2540,7 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 2506 | 2540 | list.add(t); |
| 2507 | 2541 | } |
| 2508 | 2542 | |
| 2509 | - List<ScheduleRealInfo> listInfo2 = scheduleRealInfoRepository.scheduleByDateAndLine(line, date); | |
| 2543 | + List<ScheduleRealInfo> listInfo2 = scheduleRealInfoRepository.scheduleByDateAndLineQp(line, date); | |
| 2510 | 2544 | List<ScheduleRealInfo> xList = new ArrayList<ScheduleRealInfo>(); |
| 2511 | 2545 | List<ScheduleRealInfo> yList = new ArrayList<ScheduleRealInfo>(); |
| 2512 | 2546 | List<ScheduleRealInfo> zList = new ArrayList<ScheduleRealInfo>(); | ... | ... |
src/main/java/com/bsth/service/report/impl/ReportServiceImpl.java
| ... | ... | @@ -181,10 +181,10 @@ public class ReportServiceImpl implements ReportService{ |
| 181 | 181 | try { |
| 182 | 182 | SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); |
| 183 | 183 | SimpleDateFormat sdf = new SimpleDateFormat("HH:mm:ss"); |
| 184 | - Long date1=simpleDateFormat.parse(fcsj+" 00:00:00").getTime(); | |
| 185 | - Long date2=simpleDateFormat.parse(ddsj+" 23:59:59").getTime(); | |
| 186 | - Date dates1=simpleDateFormat.parse(fcsj+" 00:00:00"); | |
| 187 | - Date dates2=simpleDateFormat.parse(ddsj+" 00:00:00"); | |
| 184 | + Long date1=simpleDateFormat.parse(fcsj+":00").getTime(); | |
| 185 | + Long date2=simpleDateFormat.parse(ddsj+":00").getTime(); | |
| 186 | + Date dates1=simpleDateFormat.parse(fcsj+":00"); | |
| 187 | + Date dates2=simpleDateFormat.parse(ddsj+":00"); | |
| 188 | 188 | List<ArrivalInfo> lists=load2(line,date1,date2,dates1,dates2,zd,zdlx); |
| 189 | 189 | |
| 190 | 190 | for(int i=0;i<lists.size();i++){ | ... | ... |
src/main/resources/static/pages/forms/mould/inoutstation.xls
0 → 100644
No preview for this file type
src/main/resources/static/pages/forms/mould/operationservice.xls
No preview for this file type
src/main/resources/static/pages/forms/mould/statisticsDaily_.xls
No preview for this file type
src/main/resources/static/pages/forms/statement/scheduleDaily.html
| ... | ... | @@ -65,6 +65,7 @@ letter-spacing: 20px; |
| 65 | 65 | <div class="portlet-body"> |
| 66 | 66 | <div class="table-container" id="ddrbBody" style="margin-top: 10px;overflow:auto;min-width: 906px"> |
| 67 | 67 | <label>日期:<span id="rqxs"></span> 早高峰:6:31~8:30 晚高峰:16:01~18:00</label> |
| 68 | + <br/><label>计划+临加-少驶=<span id="jls"></span> 计算机实驶:<span id="jsjss"></span></label> | |
| 68 | 69 | <table class="table table-bordered table-hover table-checkable" id="forms"> |
| 69 | 70 | <thead> |
| 70 | 71 | <tr> |
| ... | ... | @@ -409,6 +410,8 @@ letter-spacing: 20px; |
| 409 | 410 | $("#export").removeAttr("disabled"); |
| 410 | 411 | $get('/realSchedule/statisticsDaily',{line:line,date:date,xlName:xlName,type:"query"},function(result){ |
| 411 | 412 | var scheduleDaily_1 = template('scheduleDaily_1',{list:result}); |
| 413 | + $("#jls").html(result[0].jls); | |
| 414 | + $("#jsjss").html(result[0].sjgl); | |
| 412 | 415 | $('#forms .scheduleDaily_1').html(scheduleDaily_1); |
| 413 | 416 | }); |
| 414 | 417 | $.get('/realSchedule/queryUserInfo',{line:line,date:date,state:2,type:"query"},function(result){ | ... | ... |
src/main/resources/static/pages/forms/statement/statisticsDaily.html
| ... | ... | @@ -14,6 +14,16 @@ |
| 14 | 14 | |
| 15 | 15 | .table > tbody + tbody { |
| 16 | 16 | border-top: 1px solid; } |
| 17 | + | |
| 18 | + #forms > thead > tr> td >span{ | |
| 19 | + width: 5px; | |
| 20 | + word-wrap: break-word; | |
| 21 | + letter-spacing: 20px; | |
| 22 | + } | |
| 23 | + | |
| 24 | + #forms > thead > tr> td >label{ | |
| 25 | + word-break: keep-all;white-space:nowrap; | |
| 26 | + } | |
| 17 | 27 | </style> |
| 18 | 28 | |
| 19 | 29 | <div class="page-head"> |
| ... | ... | @@ -55,64 +65,70 @@ |
| 55 | 65 | </form> |
| 56 | 66 | </div> |
| 57 | 67 | <div class="portlet-body"> |
| 58 | - <div class="table-container" style="margin-top: 10px;overflow:auto;min-width: 906px"> | |
| 68 | + <div class="table-container" id="ddrbBody" style="margin-top: 10px;overflow:auto;min-width: 906px"> | |
| 59 | 69 | <label>早高峰:6:31~8:30 晚高峰:16:01~18:00</label> |
| 60 | 70 | <table class="table table-bordered table-hover table-checkable" id="forms"> |
| 61 | 71 | <thead> |
| 62 | 72 | <tr> |
| 63 | - <th colspan="36">线路运营情况统计日报</th> | |
| 73 | + <th colspan="44">线路调度日报</th> | |
| 64 | 74 | </tr> |
| 65 | 75 | <tr> |
| 66 | - <td rowspan="3">路线别</td> | |
| 67 | - <td colspan="15">全日营运里程(公里)</td> | |
| 76 | + <td rowspan="3"><span >路线名</span></td> | |
| 77 | + <td colspan="20">全日营运里程(公里)</td> | |
| 68 | 78 | <td colspan="15">全日营运班次</td> |
| 69 | - <td colspan="5">大间隔情况</td> | |
| 79 | + <td colspan="9">大间隔情况</td> | |
| 70 | 80 | </tr> |
| 71 | 81 | <tr> |
| 72 | - <td rowspan="2">计划</td> | |
| 73 | - <td rowspan="2">实驶</td> | |
| 74 | - <td rowspan="2">少驶</td> | |
| 82 | + <td rowspan="2"><label>计划总</label> | |
| 83 | + <label>公里</label></td> | |
| 84 | + <td rowspan="2"><label>计划营</label><label>运公里</label></td> | |
| 85 | + <td rowspan="2"><label>计划空</label><label>驶公里</label></td> | |
| 86 | + <td rowspan="2"><label>实际</label><label>总公里</label></td> | |
| 87 | + <td rowspan="2"><label>实际营</label><label>运公里</label></td> | |
| 88 | + <td rowspan="2"><label>实际空</label><label>驶公里</label></td> | |
| 89 | + <td rowspan="2"><span>少驶公里</span></td> | |
| 90 | + <td rowspan="2"><span>少驶班次</span></td> | |
| 75 | 91 | <td colspan="11">少驶原因(公里)</td> |
| 76 | - <td rowspan="2">临加公里</td> | |
| 92 | + <td rowspan="2"><span >临加公里</span></td> | |
| 77 | 93 | <td colspan="3">计划班次</td> |
| 78 | 94 | <td colspan="3">实际班次</td> |
| 79 | 95 | <td colspan="3">临加班次</td> |
| 80 | 96 | <td colspan="3">放站班次</td> |
| 81 | 97 | <td colspan="3">调头班次</td> |
| 82 | 98 | <td colspan="3">发生次数</td> |
| 83 | - <td rowspan="2">最大间隔时间(秒)</td> | |
| 84 | - <td rowspan="2">原因</td> | |
| 99 | + <td rowspan="2">最大间隔时间(分)</td> | |
| 100 | + <td rowspan="2">原因</td> | |
| 85 | 101 | </tr> |
| 86 | 102 | <tr> |
| 87 | - <td width="31px">路阻</td> | |
| 88 | - <td>吊慢</td> | |
| 89 | - <td>故障</td> | |
| 90 | - <td>纠纷</td> | |
| 91 | - <td>肇事</td> | |
| 92 | - <td>缺人</td> | |
| 93 | - <td>缺车</td> | |
| 94 | - <td>客稀</td> | |
| 95 | - <td>气候</td> | |
| 96 | - <td>援外</td> | |
| 97 | - <td>其他</td> | |
| 98 | - <td>全日</td> | |
| 99 | - <td>早高峰</td> | |
| 100 | - <td>晚高峰</td> | |
| 101 | - <td>全日</td> | |
| 102 | - <td>早高峰</td> | |
| 103 | - <td>晚高峰</td> | |
| 104 | - <td>全日</td> | |
| 105 | - <td>早高峰</td> | |
| 106 | - <td>晚高峰</td> | |
| 107 | - <td>全日</td> | |
| 108 | - <td>早高峰</td> | |
| 109 | - <td>晚高峰</td> | |
| 110 | - <td>全日</td> | |
| 111 | - <td>早高峰</td> | |
| 112 | - <td>晚高峰</td> | |
| 113 | - <td>全日</td> | |
| 114 | - <td>早高峰</td> | |
| 115 | - <td>晚高峰</td> | |
| 103 | + <td><span >路阻</span></td> | |
| 104 | + <td><span>吊慢</span></td> | |
| 105 | + <td><span >故障</span></td> | |
| 106 | + <td><span >纠纷</span></td> | |
| 107 | + <td><span >肇事</span></td> | |
| 108 | + <td><span>缺人</span></td> | |
| 109 | + <td><span>缺车</span></td> | |
| 110 | + <td><span >客稀</span></td> | |
| 111 | + <td><span>气候</span></td> | |
| 112 | + <td><span>援外</span></td> | |
| 113 | + <td><span>其他</span></td> | |
| 114 | + <td><span>全日</span></td> | |
| 115 | + <td><span>早高峰</span></td> | |
| 116 | + <td><span>晚高峰</span></td> | |
| 117 | + <td><span>全日</span></td> | |
| 118 | + <td><span>早高峰</span></td> | |
| 119 | + <td><span>晚高峰</span></td> | |
| 120 | + <td><span>全日</span></td> | |
| 121 | + <td><span>早高峰</span></td> | |
| 122 | + <td><span>晚高峰</span></td> | |
| 123 | + <td><span>全日</span></td> | |
| 124 | + <td><span>早高峰</span></td> | |
| 125 | + <td><span>晚高峰</span></td> | |
| 126 | + <td><span>全日</span></td> | |
| 127 | + <td><span>早高峰</span></td> | |
| 128 | + <td><span>晚高峰</span></td> | |
| 129 | + <td><span>全日</span></td> | |
| 130 | + <td><span>早高峰</span></td> | |
| 131 | + <td><span>晚高峰</span></td> | |
| 116 | 132 | </tr> |
| 117 | 133 | </thead> |
| 118 | 134 | <tbody class="statisticsDaily"> |
| ... | ... | @@ -269,7 +285,7 @@ |
| 269 | 285 | } |
| 270 | 286 | |
| 271 | 287 | }); |
| 272 | - | |
| 288 | + $("#ddrbBody").height($(window).height()-280); | |
| 273 | 289 | $("#export").on("click",function(){ |
| 274 | 290 | var params = {}; |
| 275 | 291 | params['gsdm'] = gsdm; |
| ... | ... | @@ -290,9 +306,14 @@ |
| 290 | 306 | {{each list as obj i}} |
| 291 | 307 | <tr> |
| 292 | 308 | <td>{{obj.xlName}}</td> |
| 309 | + <td>{{obj.jhzlc}}</td> | |
| 293 | 310 | <td>{{obj.jhlc}}</td> |
| 311 | + <td>{{obj.jcclc}}</td> | |
| 312 | + <td>{{obj.sjzgl}}</td> | |
| 294 | 313 | <td>{{obj.sjgl}}</td> |
| 314 | + <td>{{obj.sjksgl}}</td> | |
| 295 | 315 | <td>{{obj.ssgl}}</td> |
| 316 | + <td>{{obj.ssbc}}</td> | |
| 296 | 317 | <td>{{obj.ssgl_lz}}</td> |
| 297 | 318 | <td>{{obj.ssgl_dm}}</td> |
| 298 | 319 | <td>{{obj.ssgl_gz}}</td> |
| ... | ... | @@ -329,7 +350,7 @@ |
| 329 | 350 | {{/each}} |
| 330 | 351 | {{if list.length == 0}} |
| 331 | 352 | <tr> |
| 332 | - <td colspan="36"><h6 class="muted">没有找到相关数据</h6></td> | |
| 353 | + <td colspan="44"><h6 class="muted">没有找到相关数据</h6></td> | |
| 333 | 354 | </tr> |
| 334 | 355 | {{/if}} |
| 335 | 356 | </script> |
| 336 | 357 | \ No newline at end of file | ... | ... |
src/main/resources/static/pages/mforms/operationservices/operationservice.html
| ... | ... | @@ -169,6 +169,7 @@ |
| 169 | 169 | $("#fgsdmOperat").on("change",initXl); |
| 170 | 170 | function initXl(){ |
| 171 | 171 | var data=[]; |
| 172 | + data.push({id: " ", text: "请选择"}); | |
| 172 | 173 | if(fage){ |
| 173 | 174 | $("#line").select2("destroy").html(''); |
| 174 | 175 | } |
| ... | ... | @@ -201,7 +202,7 @@ |
| 201 | 202 | var lpName = $("#lpName").val(); |
| 202 | 203 | var gsdmOperat = $("#gsdmOperat").val(); |
| 203 | 204 | var fgsdmOperat = $("#fgsdmOperat").val(); |
| 204 | - $post("/mcy_forms/operationservice", { | |
| 205 | + $get("/mcy_forms/operationservice", { | |
| 205 | 206 | gsdmOperat : gsdmOperat, |
| 206 | 207 | fgsdmOperat : fgsdmOperat, |
| 207 | 208 | line : line, |
| ... | ... | @@ -238,7 +239,7 @@ |
| 238 | 239 | endDate=$("#endDate").val(); |
| 239 | 240 | gsdmOperat=$("#gsdmOperat").val(); |
| 240 | 241 | fgsdmOperat=$("#fgsdmOperat").val(); |
| 241 | - $post('/mcy_export/operationserviceExport',{gsdmOperat:gsdmOperat,fgsdmOperat:fgsdmOperat,line:line,startDate:startDate,endDate:endDate,type:'export'},function(result){ | |
| 242 | + $get('/mcy_export/operationserviceExport',{gsdmOperat:gsdmOperat,fgsdmOperat:fgsdmOperat,line:line,startDate:startDate,endDate:endDate,type:'export'},function(result){ | |
| 242 | 243 | window.open("/downloadFile/download?fileName=运营服务阶段报表"+moment(startDate).format("YYYYMMDD")); |
| 243 | 244 | }); |
| 244 | 245 | }); | ... | ... |
src/main/resources/static/pages/report/inoutstation.html
| ... | ... | @@ -76,8 +76,9 @@ |
| 76 | 76 | </div> |
| 77 | 77 | <div class="form-group" style="display: inline-block;margin-left: 15px;"> |
| 78 | 78 | <input class="btn btn-default" type="button" id="query" value="查询"/> |
| 79 | + <input class="btn btn-default" type="button" id="export" value="导出"/> | |
| 79 | 80 | <input class="btn btn-default" type="button" style="display: none;" id="query2" value="查询"/> |
| 80 | -<!-- <input class="btn btn-default" type="button" id="export" value="导出"/> --> | |
| 81 | + <input class="btn btn-default" type="button" id="export2" style="display: none;" value="导出"/> | |
| 81 | 82 | <!-- <input class="btn btn-default" type="button" id="print" value="打印"/> --> |
| 82 | 83 | <!-- <input class="btn btn-default" type="button" id="exportMore" value="批量导出"/> --> |
| 83 | 84 | </div> |
| ... | ... | @@ -103,9 +104,12 @@ |
| 103 | 104 | </tbody> |
| 104 | 105 | </table> |
| 105 | 106 | </div> |
| 106 | - <div> | |
| 107 | - <span style="font-size: 20px" class="item-label" id="dlzmx"> </span> | |
| 108 | - | |
| 107 | + <div > | |
| 108 | + <span style="font-size: 20px" class="item-label" id="dlzmx"> | |
| 109 | + 到离站详细 待查询 | |
| 110 | + </span> | |
| 111 | + <input id="fcsj_xx" type="hidden" value=""> | |
| 112 | + <input id="ddsj_xx" type="hidden" value=""> | |
| 109 | 113 | </div> |
| 110 | 114 | <div style="margin-top: 20px; " id="forms1Div"> |
| 111 | 115 | <table class="table table-bordered table-checkable" id="forms1"> |
| ... | ... | @@ -148,13 +152,19 @@ |
| 148 | 152 | $("#formsDiv").css('display','inline-block'); |
| 149 | 153 | $("#query2").css('display','none'); |
| 150 | 154 | $("#query").css('display','inline-block'); |
| 155 | + $("#export2").css('display','none'); | |
| 156 | + $("#export").css('display','inline-block'); | |
| 151 | 157 | |
| 152 | 158 | }else{ |
| 159 | + $("#fcsj_xx").val(""); | |
| 160 | + $("#ddsj_xx").val(""); | |
| 153 | 161 | $("#clzdDiv").css('display','inline-block'); |
| 154 | 162 | $("#bczxDiv").css('display','none'); |
| 155 | 163 | $("#formsDiv").css('display','none'); |
| 156 | 164 | $("#query").css('display','none'); |
| 157 | 165 | $("#query2").css('display','inline-block'); |
| 166 | + $("#export").css('display','none'); | |
| 167 | + $("#export2").css('display','inline-block'); | |
| 158 | 168 | } |
| 159 | 169 | }); |
| 160 | 170 | |
| ... | ... | @@ -168,12 +178,12 @@ |
| 168 | 178 | }); |
| 169 | 179 | |
| 170 | 180 | $("#date1").datetimepicker({ |
| 171 | - format : 'YYYY-MM-DD', | |
| 181 | + format : 'YYYY-MM-DD HH:mm', | |
| 172 | 182 | locale : 'zh-cn' |
| 173 | 183 | }); |
| 174 | 184 | |
| 175 | 185 | $("#date2").datetimepicker({ |
| 176 | - format : 'YYYY-MM-DD', | |
| 186 | + format : 'YYYY-MM-DD HH:mm', | |
| 177 | 187 | locale : 'zh-cn' |
| 178 | 188 | }); |
| 179 | 189 | |
| ... | ... | @@ -282,16 +292,6 @@ |
| 282 | 292 | |
| 283 | 293 | var params = new Array(); |
| 284 | 294 | var jName = ''; |
| 285 | - | |
| 286 | -// $("#export").on("click",function(){ | |
| 287 | -// if(params.length < 1){ | |
| 288 | -// return; | |
| 289 | -// } | |
| 290 | -// $post('/realSchedule/exportWaybill',{jName:jName,clZbh:params[1],lpName:params[2],date:date},function(result){ | |
| 291 | -// window.open("/downloadFile/download?fileName="+jName); | |
| 292 | -// }); | |
| 293 | -// }); | |
| 294 | - | |
| 295 | 295 | // $("#print").click(function(){ |
| 296 | 296 | // $("#printArea").printArea(); |
| 297 | 297 | // }); |
| ... | ... | @@ -385,6 +385,8 @@ |
| 385 | 385 | var rqmc="日期: "+rq; |
| 386 | 386 | var bcmc="班次: "+fcsj+"-"+ddsj; |
| 387 | 387 | $("#dlzmx").html("到离站详细 "+xlmc+" "+clmc+" "+rqmc+" "+bcmc); |
| 388 | + $("#fcsj_xx").val(fcsj); | |
| 389 | + $("#ddsj_xx").val(ddsj); | |
| 388 | 390 | var ludan_ll_1 = template('ludan_ll_1',{list:result}); |
| 389 | 391 | // 把渲染好的模版html文本追加到表格中 |
| 390 | 392 | $('#forms1 .ludan_ll_1').html(ludan_ll_1); |
| ... | ... | @@ -472,6 +474,44 @@ |
| 472 | 474 | } |
| 473 | 475 | }) |
| 474 | 476 | |
| 477 | + | |
| 478 | + | |
| 479 | + $("#export").on("click",function(){ | |
| 480 | + var rq=$("#date").val(); | |
| 481 | + var line=$("#line").val(); | |
| 482 | + var nbbm=$("#nbbm").val(); | |
| 483 | + var fcsj=$("#fcsj_xx").val(); | |
| 484 | + var ddsj=$("#ddsj_xx").val(); | |
| 485 | + if(fcsj==""){ | |
| 486 | + layer.msg("没数据"); | |
| 487 | + }else{ | |
| 488 | + $get('/report/exportQueryListZdxx',{clzbh:nbbm,date:rq,line:line,fcsj:fcsj,ddsj:ddsj},function(result){ | |
| 489 | + window.open("/downloadFile/download?fileName=班次到离站"); | |
| 490 | + }); | |
| 491 | + } | |
| 492 | + | |
| 493 | + }); | |
| 494 | + | |
| 495 | + $("#export2").on("click",function(){ | |
| 496 | + var date1=$("#date1").val(); | |
| 497 | + var date2=$("#date2").val(); | |
| 498 | + var line=$("#line").val(); | |
| 499 | + var zdlx=$("#zdlx").val(); | |
| 500 | + var zd=$("#zd").val(); | |
| 501 | + if(date1=="" || date1==null){ | |
| 502 | + layer.msg("请选择时间"); | |
| 503 | + }else if( line=="" || line==null){ | |
| 504 | + layer.msg("请选择线路"); | |
| 505 | + }else if(date2 ==null || date2==""){ | |
| 506 | + layer.msg("请选择时间"); | |
| 507 | + }else if(zdlx=="" || zdlx==null){ | |
| 508 | + layer.msg("请选择方向"); | |
| 509 | + }else{ | |
| 510 | + $get('/report/exportQueryListClzd',{zd:zd,zdlx:zdlx,line:line,fcsj:date1,ddsj:date2},function(result){ | |
| 511 | + window.open("/downloadFile/download?fileName=班次到离站"); | |
| 512 | + }); | |
| 513 | + } | |
| 514 | + }); | |
| 475 | 515 | |
| 476 | 516 | }); |
| 477 | 517 | ... | ... |