Commit 7b255c1160f48a48f431c76c63ca8cb176ded847
1 parent
69c03969
烂班情况表 统计数据
Showing
8 changed files
with
1266 additions
and
0 deletions
src/main/java/com/bsth/controller/calc/CalcExportController.java
| ... | ... | @@ -16,6 +16,7 @@ import org.springframework.web.bind.annotation.RestController; |
| 16 | 16 | import com.bsth.common.ResponseCode; |
| 17 | 17 | import com.bsth.entity.calc.CalcWaybill; |
| 18 | 18 | import com.bsth.entity.mcy_forms.Waybillday; |
| 19 | +import com.bsth.service.calc.CalcLbStatuAnalyService; | |
| 19 | 20 | import com.bsth.service.calc.CalcMixService; |
| 20 | 21 | import com.bsth.service.calc.CalcWaybillService; |
| 21 | 22 | import com.bsth.util.ReportUtils; |
| ... | ... | @@ -26,6 +27,9 @@ public class CalcExportController { |
| 26 | 27 | |
| 27 | 28 | @Autowired |
| 28 | 29 | CalcWaybillService service; |
| 30 | + | |
| 31 | + @Autowired | |
| 32 | + CalcLbStatuAnalyService lbService; | |
| 29 | 33 | |
| 30 | 34 | @Autowired |
| 31 | 35 | CalcMixService clacMixService; |
| ... | ... | @@ -204,5 +208,84 @@ public class CalcExportController { |
| 204 | 208 | } |
| 205 | 209 | return resMap; |
| 206 | 210 | } |
| 211 | + | |
| 212 | + @RequestMapping(value = "/lbStatuAnalyExport", method = RequestMethod.GET) | |
| 213 | + public Map<String, Object> lbStatuAnalyExport(@RequestParam Map<String, Object> map) { | |
| 214 | + | |
| 215 | + String gsdm=""; | |
| 216 | + if(map.get("company")!=null){ | |
| 217 | + gsdm=map.get("company").toString().trim(); | |
| 218 | + } | |
| 219 | + String fgsdm=""; | |
| 220 | + if(map.get("subCompany")!=null){ | |
| 221 | + fgsdm=map.get("subCompany").toString().trim(); | |
| 222 | + } | |
| 223 | + String line=""; | |
| 224 | + if(map.get("line")!=null){ | |
| 225 | + line=map.get("line").toString().trim(); | |
| 226 | + } | |
| 227 | + String lineName=""; | |
| 228 | + if(map.get("lineName")!=null){ | |
| 229 | + lineName=map.get("lineName").toString().trim(); | |
| 230 | + } | |
| 231 | + String date=""; | |
| 232 | + if(map.get("startDate")!=null){ | |
| 233 | + date=map.get("startDate").toString().trim(); | |
| 234 | + } | |
| 235 | + String date2=""; | |
| 236 | + if(map.get("endDate")!=null){ | |
| 237 | + date2=map.get("endDate").toString().trim(); | |
| 238 | + } | |
| 239 | + String sfyy=""; | |
| 240 | + if(map.get("sfyy")!=null){ | |
| 241 | + sfyy=map.get("sfyy").toString().trim(); | |
| 242 | + } | |
| 243 | + String type=""; | |
| 244 | + if(map.get("type")!=null){ | |
| 245 | + type=map.get("type").toString().trim(); | |
| 246 | + } | |
| 247 | + | |
| 248 | + Map<String, Object> resMap = new HashMap<String, Object>(); | |
| 249 | + List<Map<String, Object>> resList = new ArrayList<Map<String, Object>>(); | |
| 250 | + List<Map<String, Object>> list = lbService.lbStatuAnaly(gsdm, fgsdm, line, date, date2, sfyy, type); | |
| 251 | + | |
| 252 | + for(int i = 0; i < list.size(); i++){ | |
| 253 | + Map<String, Object> temp = list.get(i); | |
| 254 | + temp.put("i", i+1); | |
| 255 | + if(!temp.containsKey("date") || temp.get("date") == null){ | |
| 256 | + temp.put("date", ""); | |
| 257 | + } | |
| 258 | + if(!temp.containsKey("company") || temp.get("company") == null){ | |
| 259 | + temp.put("company", ""); | |
| 260 | + } | |
| 261 | + if(!temp.containsKey("subCompany") || temp.get("subCompany") == null){ | |
| 262 | + temp.put("subCompany", ""); | |
| 263 | + } | |
| 264 | + resList.add(temp); | |
| 265 | + } | |
| 266 | + | |
| 267 | + String Data = date.replaceAll("-", ""); | |
| 268 | + if(!date.equals(date2)){ | |
| 269 | + Data = date.replaceAll("-", "") + "-" + date2.replaceAll("-", ""); | |
| 270 | + } | |
| 271 | + | |
| 272 | + SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"), | |
| 273 | + sdfSimple = new SimpleDateFormat("yyyyMMdd"); | |
| 274 | + List<Iterator<?>> listI = new ArrayList<Iterator<?>>(); | |
| 275 | + Map<String,Object> mm = new HashMap<String, Object>(); | |
| 276 | + ReportUtils ee = new ReportUtils(); | |
| 277 | + | |
| 278 | + try { | |
| 279 | + listI.add(resList.iterator()); | |
| 280 | + String path = this.getClass().getResource("/").getPath()+"static/pages/forms/"; | |
| 281 | + ee.excelReplace(listI, new Object[] { mm }, path+"mould/calcLbStatuAnaly.xls", | |
| 282 | + path+"export/"+Data+"-"+lineName+"-烂班情况分析表(统计).xls"); | |
| 283 | + resMap.put("status", ResponseCode.SUCCESS); | |
| 284 | + } catch (Exception e) { | |
| 285 | + e.printStackTrace(); | |
| 286 | + resMap.put("status", ResponseCode.ERROR); | |
| 287 | + } | |
| 288 | + return resMap; | |
| 289 | + } | |
| 207 | 290 | |
| 208 | 291 | } | ... | ... |
src/main/java/com/bsth/controller/calc/CalcLbStatuAnalyController.java
0 → 100644
| 1 | +package com.bsth.controller.calc; | |
| 2 | + | |
| 3 | +import java.util.List; | |
| 4 | +import java.util.Map; | |
| 5 | + | |
| 6 | +import com.bsth.controller.BaseController; | |
| 7 | +import com.bsth.entity.calc.CalcLbStatuAnaly; | |
| 8 | +import com.bsth.service.calc.CalcLbStatuAnalyService; | |
| 9 | +import org.springframework.beans.factory.annotation.Autowired; | |
| 10 | +import org.springframework.web.bind.annotation.RequestMapping; | |
| 11 | +import org.springframework.web.bind.annotation.RequestParam; | |
| 12 | +import org.springframework.web.bind.annotation.RestController; | |
| 13 | + | |
| 14 | +/** | |
| 15 | + * Created by 19/03/18. | |
| 16 | + */ | |
| 17 | +@RestController | |
| 18 | +@RequestMapping("calcLbStatuAnaly") | |
| 19 | +public class CalcLbStatuAnalyController extends BaseController<CalcLbStatuAnaly, Integer> { | |
| 20 | + | |
| 21 | + @Autowired | |
| 22 | + private CalcLbStatuAnalyService service; | |
| 23 | + | |
| 24 | + | |
| 25 | + @RequestMapping(value="/lbStatuAnaly") | |
| 26 | + public List<Map<String,Object>> lbStatuAnaly(@RequestParam Map<String, Object> map){ | |
| 27 | + String gsdm=""; | |
| 28 | + if(map.get("company")!=null){ | |
| 29 | + gsdm=map.get("company").toString().trim(); | |
| 30 | + } | |
| 31 | + String fgsdm=""; | |
| 32 | + if(map.get("subCompany")!=null){ | |
| 33 | + fgsdm=map.get("subCompany").toString().trim(); | |
| 34 | + } | |
| 35 | + String line=""; | |
| 36 | + if(map.get("line")!=null){ | |
| 37 | + line=map.get("line").toString().trim(); | |
| 38 | + } | |
| 39 | + String date=""; | |
| 40 | + if(map.get("startDate")!=null){ | |
| 41 | + date=map.get("startDate").toString().trim(); | |
| 42 | + } | |
| 43 | + String date2=""; | |
| 44 | + if(map.get("endDate")!=null){ | |
| 45 | + date2=map.get("endDate").toString().trim(); | |
| 46 | + } | |
| 47 | + String sfyy=""; | |
| 48 | + if(map.get("sfyy")!=null){ | |
| 49 | + sfyy=map.get("sfyy").toString().trim(); | |
| 50 | + } | |
| 51 | + String type=""; | |
| 52 | + if(map.get("type")!=null){ | |
| 53 | + type=map.get("type").toString().trim(); | |
| 54 | + } | |
| 55 | + return service.lbStatuAnaly(gsdm,fgsdm,line,date,date2,sfyy,type); | |
| 56 | + } | |
| 57 | + | |
| 58 | +} | ... | ... |
src/main/java/com/bsth/entity/calc/CalcLbStatuAnaly.java
0 → 100644
| 1 | +package com.bsth.entity.calc; | |
| 2 | + | |
| 3 | +import java.util.Date; | |
| 4 | + | |
| 5 | +import javax.persistence.Entity; | |
| 6 | +import javax.persistence.GeneratedValue; | |
| 7 | +import javax.persistence.Id; | |
| 8 | +import javax.persistence.Table; | |
| 9 | + | |
| 10 | +@Entity | |
| 11 | +@Table(name = "calc_lb_statu_analy") | |
| 12 | +public class CalcLbStatuAnaly { | |
| 13 | + /* 主键*/ | |
| 14 | + @Id | |
| 15 | + @GeneratedValue | |
| 16 | + private Long id; | |
| 17 | + /* 公司代码*/ | |
| 18 | + private String gsdm; | |
| 19 | + /* 公司名称*/ | |
| 20 | + private String gsname; | |
| 21 | + /* 分公司代码*/ | |
| 22 | + private String fgsdm; | |
| 23 | + /* 分公司名称*/ | |
| 24 | + private String fgsname; | |
| 25 | + /* 日期*/ | |
| 26 | + private Date rq; | |
| 27 | + /* 日期字符串*/ | |
| 28 | + private String rqStr; | |
| 29 | + /* 线路编码*/ | |
| 30 | + private String xl; | |
| 31 | + /* 线路名称*/ | |
| 32 | + private String xlName; | |
| 33 | + /* 计划班次*/ | |
| 34 | + private int jhbc; | |
| 35 | + /* 实际班次*/ | |
| 36 | + private int sjbc; | |
| 37 | + /* 计划里程*/ | |
| 38 | + private Double jhlc; | |
| 39 | + /* 实际公里*/ | |
| 40 | + private Double sjlc; | |
| 41 | + /* 路阻(烂班班次)*/ | |
| 42 | + private int lzbc; | |
| 43 | + /* 路阻(烂班里程)*/ | |
| 44 | + private Double lzlc; | |
| 45 | + /* 吊慢(烂班班次)*/ | |
| 46 | + private int dmbc; | |
| 47 | + /* 吊慢(烂班里程)*/ | |
| 48 | + private Double dmlc; | |
| 49 | + /* 故障(烂班班次)*/ | |
| 50 | + private int gzbc; | |
| 51 | + /* 故障(烂班里程)*/ | |
| 52 | + private Double gzlc; | |
| 53 | + /* 纠纷(烂班班次)*/ | |
| 54 | + private int jfbc; | |
| 55 | + /* 纠纷(烂班里程)*/ | |
| 56 | + private Double jflc; | |
| 57 | + /* 肇事(烂班班次)*/ | |
| 58 | + private int zsbc; | |
| 59 | + /* 肇事(烂班里程)*/ | |
| 60 | + private Double zslc; | |
| 61 | + /* 缺人(烂班班次)*/ | |
| 62 | + private int qrbc; | |
| 63 | + /* 缺人(烂班里程)*/ | |
| 64 | + private Double qrlc; | |
| 65 | + /* 缺车(烂班班次)*/ | |
| 66 | + private int qcbc; | |
| 67 | + /* 缺车(烂班里程)*/ | |
| 68 | + private Double qclc; | |
| 69 | + /* 客稀(烂班班次)*/ | |
| 70 | + private int kxbc; | |
| 71 | + /* 客稀(烂班里程)*/ | |
| 72 | + private Double kxlc; | |
| 73 | + /* 气候(烂班班次)*/ | |
| 74 | + private int qhbc; | |
| 75 | + /* 气候(烂班里程)*/ | |
| 76 | + private Double qhlc; | |
| 77 | + /* 援外(烂班班次)*/ | |
| 78 | + private int ywbc; | |
| 79 | + /* 援外(烂班里程)*/ | |
| 80 | + private Double ywlc; | |
| 81 | + /* 其他(烂班班次)*/ | |
| 82 | + private int qtbc; | |
| 83 | + /* 其他(烂班里程)*/ | |
| 84 | + private Double qtlc; | |
| 85 | + /* 备注*/ | |
| 86 | + private String remark; | |
| 87 | + | |
| 88 | + | |
| 89 | + public Long getId() { | |
| 90 | + return id; | |
| 91 | + } | |
| 92 | + public void setId(Long id) { | |
| 93 | + this.id = id; | |
| 94 | + } | |
| 95 | + public String getGsdm() { | |
| 96 | + return gsdm; | |
| 97 | + } | |
| 98 | + public void setGsdm(String gsdm) { | |
| 99 | + this.gsdm = gsdm; | |
| 100 | + } | |
| 101 | + public String getGsname() { | |
| 102 | + return gsname; | |
| 103 | + } | |
| 104 | + public void setGsname(String gsname) { | |
| 105 | + this.gsname = gsname; | |
| 106 | + } | |
| 107 | + public String getFgsdm() { | |
| 108 | + return fgsdm; | |
| 109 | + } | |
| 110 | + public void setFgsdm(String fgsdm) { | |
| 111 | + this.fgsdm = fgsdm; | |
| 112 | + } | |
| 113 | + public String getFgsname() { | |
| 114 | + return fgsname; | |
| 115 | + } | |
| 116 | + public void setFgsname(String fgsname) { | |
| 117 | + this.fgsname = fgsname; | |
| 118 | + } | |
| 119 | + public Date getRq() { | |
| 120 | + return rq; | |
| 121 | + } | |
| 122 | + public void setRq(Date rq) { | |
| 123 | + this.rq = rq; | |
| 124 | + } | |
| 125 | + public String getRqStr() { | |
| 126 | + return rqStr; | |
| 127 | + } | |
| 128 | + public void setRqStr(String rqStr) { | |
| 129 | + this.rqStr = rqStr; | |
| 130 | + } | |
| 131 | + public String getXl() { | |
| 132 | + return xl; | |
| 133 | + } | |
| 134 | + public void setXl(String xl) { | |
| 135 | + this.xl = xl; | |
| 136 | + } | |
| 137 | + public String getXlName() { | |
| 138 | + return xlName; | |
| 139 | + } | |
| 140 | + public void setXlName(String xlName) { | |
| 141 | + this.xlName = xlName; | |
| 142 | + } | |
| 143 | + public int getJhbc() { | |
| 144 | + return jhbc; | |
| 145 | + } | |
| 146 | + public void setJhbc(int jhbc) { | |
| 147 | + this.jhbc = jhbc; | |
| 148 | + } | |
| 149 | + public int getSjbc() { | |
| 150 | + return sjbc; | |
| 151 | + } | |
| 152 | + public void setSjbc(int sjbc) { | |
| 153 | + this.sjbc = sjbc; | |
| 154 | + } | |
| 155 | + public Double getJhlc() { | |
| 156 | + return jhlc; | |
| 157 | + } | |
| 158 | + public void setJhlc(Double jhlc) { | |
| 159 | + this.jhlc = jhlc; | |
| 160 | + } | |
| 161 | + public Double getSjlc() { | |
| 162 | + return sjlc; | |
| 163 | + } | |
| 164 | + public void setSjlc(Double sjlc) { | |
| 165 | + this.sjlc = sjlc; | |
| 166 | + } | |
| 167 | + public int getLzbc() { | |
| 168 | + return lzbc; | |
| 169 | + } | |
| 170 | + public void setLzbc(int lzbc) { | |
| 171 | + this.lzbc = lzbc; | |
| 172 | + } | |
| 173 | + public Double getLzlc() { | |
| 174 | + return lzlc; | |
| 175 | + } | |
| 176 | + public void setLzlc(Double lzlc) { | |
| 177 | + this.lzlc = lzlc; | |
| 178 | + } | |
| 179 | + public int getDmbc() { | |
| 180 | + return dmbc; | |
| 181 | + } | |
| 182 | + public void setDmbc(int dmbc) { | |
| 183 | + this.dmbc = dmbc; | |
| 184 | + } | |
| 185 | + public Double getDmlc() { | |
| 186 | + return dmlc; | |
| 187 | + } | |
| 188 | + public void setDmlc(Double dmlc) { | |
| 189 | + this.dmlc = dmlc; | |
| 190 | + } | |
| 191 | + public int getGzbc() { | |
| 192 | + return gzbc; | |
| 193 | + } | |
| 194 | + public void setGzbc(int gzbc) { | |
| 195 | + this.gzbc = gzbc; | |
| 196 | + } | |
| 197 | + public Double getGzlc() { | |
| 198 | + return gzlc; | |
| 199 | + } | |
| 200 | + public void setGzlc(Double gzlc) { | |
| 201 | + this.gzlc = gzlc; | |
| 202 | + } | |
| 203 | + public int getJfbc() { | |
| 204 | + return jfbc; | |
| 205 | + } | |
| 206 | + public void setJfbc(int jfbc) { | |
| 207 | + this.jfbc = jfbc; | |
| 208 | + } | |
| 209 | + public Double getJflc() { | |
| 210 | + return jflc; | |
| 211 | + } | |
| 212 | + public void setJflc(Double jflc) { | |
| 213 | + this.jflc = jflc; | |
| 214 | + } | |
| 215 | + public int getZsbc() { | |
| 216 | + return zsbc; | |
| 217 | + } | |
| 218 | + public void setZsbc(int zsbc) { | |
| 219 | + this.zsbc = zsbc; | |
| 220 | + } | |
| 221 | + public Double getZslc() { | |
| 222 | + return zslc; | |
| 223 | + } | |
| 224 | + public void setZslc(Double zslc) { | |
| 225 | + this.zslc = zslc; | |
| 226 | + } | |
| 227 | + public int getQrbc() { | |
| 228 | + return qrbc; | |
| 229 | + } | |
| 230 | + public void setQrbc(int qrbc) { | |
| 231 | + this.qrbc = qrbc; | |
| 232 | + } | |
| 233 | + public Double getQrlc() { | |
| 234 | + return qrlc; | |
| 235 | + } | |
| 236 | + public void setQrlc(Double qrlc) { | |
| 237 | + this.qrlc = qrlc; | |
| 238 | + } | |
| 239 | + public int getQcbc() { | |
| 240 | + return qcbc; | |
| 241 | + } | |
| 242 | + public void setQcbc(int qcbc) { | |
| 243 | + this.qcbc = qcbc; | |
| 244 | + } | |
| 245 | + public Double getQclc() { | |
| 246 | + return qclc; | |
| 247 | + } | |
| 248 | + public void setQclc(Double qclc) { | |
| 249 | + this.qclc = qclc; | |
| 250 | + } | |
| 251 | + public int getKxbc() { | |
| 252 | + return kxbc; | |
| 253 | + } | |
| 254 | + public void setKxbc(int kxbc) { | |
| 255 | + this.kxbc = kxbc; | |
| 256 | + } | |
| 257 | + public Double getKxlc() { | |
| 258 | + return kxlc; | |
| 259 | + } | |
| 260 | + public void setKxlc(Double kxlc) { | |
| 261 | + this.kxlc = kxlc; | |
| 262 | + } | |
| 263 | + public int getQhbc() { | |
| 264 | + return qhbc; | |
| 265 | + } | |
| 266 | + public void setQhbc(int qhbc) { | |
| 267 | + this.qhbc = qhbc; | |
| 268 | + } | |
| 269 | + public Double getQhlc() { | |
| 270 | + return qhlc; | |
| 271 | + } | |
| 272 | + public void setQhlc(Double qhlc) { | |
| 273 | + this.qhlc = qhlc; | |
| 274 | + } | |
| 275 | + public int getYwbc() { | |
| 276 | + return ywbc; | |
| 277 | + } | |
| 278 | + public void setYwbc(int ywbc) { | |
| 279 | + this.ywbc = ywbc; | |
| 280 | + } | |
| 281 | + public Double getYwlc() { | |
| 282 | + return ywlc; | |
| 283 | + } | |
| 284 | + public void setYwlc(Double ywlc) { | |
| 285 | + this.ywlc = ywlc; | |
| 286 | + } | |
| 287 | + public int getQtbc() { | |
| 288 | + return qtbc; | |
| 289 | + } | |
| 290 | + public void setQtbc(int qtbc) { | |
| 291 | + this.qtbc = qtbc; | |
| 292 | + } | |
| 293 | + public Double getQtlc() { | |
| 294 | + return qtlc; | |
| 295 | + } | |
| 296 | + public void setQtlc(Double qtlc) { | |
| 297 | + this.qtlc = qtlc; | |
| 298 | + } | |
| 299 | + public String getRemark() { | |
| 300 | + return remark; | |
| 301 | + } | |
| 302 | + public void setRemark(String remark) { | |
| 303 | + this.remark = remark; | |
| 304 | + } | |
| 305 | + | |
| 306 | +} | ... | ... |
src/main/java/com/bsth/repository/calc/CalcLbStatuAnalyRepository.java
0 → 100644
| 1 | +package com.bsth.repository.calc; | |
| 2 | + | |
| 3 | +import java.util.List; | |
| 4 | + | |
| 5 | +import javax.transaction.Transactional; | |
| 6 | + | |
| 7 | +import com.bsth.entity.calc.CalcLbStatuAnaly; | |
| 8 | +import com.bsth.repository.BaseRepository; | |
| 9 | + | |
| 10 | +import org.springframework.data.jpa.repository.Modifying; | |
| 11 | +import org.springframework.data.jpa.repository.Query; | |
| 12 | +import org.springframework.stereotype.Repository; | |
| 13 | + | |
| 14 | +/** | |
| 15 | + * | |
| 16 | + */ | |
| 17 | +@Repository | |
| 18 | +public interface CalcLbStatuAnalyRepository extends BaseRepository<CalcLbStatuAnaly, Integer>{ | |
| 19 | + | |
| 20 | + //按照时间段统计,公司下线路 | |
| 21 | + @Query(value="select DISTINCT c from CalcLbStatuAnaly c where c.xl like %?1% and c.rqStr between ?2 and ?3 and c.gsdm like %?4% and c.fgsdm like %?5% order by c.xl") | |
| 22 | + List<CalcLbStatuAnaly> selectByDateAndLine(String line,String date,String date2,String gsdm,String fgsdm); | |
| 23 | + | |
| 24 | + //按照时间段统计,单条线路 | |
| 25 | + @Query(value="select DISTINCT c from CalcLbStatuAnaly c where c.xl = ?1 and c.rqStr between ?2 and ?3 order by c.xl") | |
| 26 | + List<CalcLbStatuAnaly> selectByDateAndLine(String line,String date,String date2); | |
| 27 | + | |
| 28 | + //按照日期和线路删除数据 | |
| 29 | + @Modifying | |
| 30 | + @Transactional | |
| 31 | + @Query(value = "delete CalcLbStatuAnaly c where c.rqStr=?1 and c.xl=?2") | |
| 32 | + void deleteByDateAndLine(String date, String line); | |
| 33 | + | |
| 34 | + //按照日期删除数据 | |
| 35 | + @Modifying | |
| 36 | + @Transactional | |
| 37 | + @Query(value = "delete CalcLbStatuAnaly c where c.rqStr=?1") | |
| 38 | + void deleteByDate(String date); | |
| 39 | + | |
| 40 | +} | ... | ... |
src/main/java/com/bsth/service/calc/CalcLbStatuAnalyService.java
0 → 100644
| 1 | +package com.bsth.service.calc; | |
| 2 | + | |
| 3 | +import java.util.List; | |
| 4 | +import java.util.Map; | |
| 5 | + | |
| 6 | +import com.bsth.entity.calc.CalcLbStatuAnaly; | |
| 7 | +import com.bsth.service.BaseService; | |
| 8 | + | |
| 9 | +/** | |
| 10 | + * Created by 19/03/18. | |
| 11 | + */ | |
| 12 | +public interface CalcLbStatuAnalyService extends BaseService<CalcLbStatuAnaly, Integer> { | |
| 13 | + | |
| 14 | + List<Map<String, Object>> lbStatuAnaly(String gsdm, String fgsdm, String line, String date, String date2, String sfyy, String type); | |
| 15 | + | |
| 16 | +} | ... | ... |
src/main/java/com/bsth/service/calc/impl/CalcLbStatuAnalyServiceImpl.java
0 → 100644
| 1 | +package com.bsth.service.calc.impl; | |
| 2 | + | |
| 3 | +import java.util.ArrayList; | |
| 4 | +import java.util.Collections; | |
| 5 | +import java.util.Comparator; | |
| 6 | +import java.util.HashMap; | |
| 7 | +import java.util.List; | |
| 8 | +import java.util.Map; | |
| 9 | + | |
| 10 | +import com.bsth.entity.calc.CalcLbStatuAnaly; | |
| 11 | +import com.bsth.repository.calc.CalcLbStatuAnalyRepository; | |
| 12 | +import com.bsth.service.LineService; | |
| 13 | +import com.bsth.service.calc.CalcLbStatuAnalyService; | |
| 14 | +import com.bsth.service.impl.BaseServiceImpl; | |
| 15 | +import com.bsth.util.Arith; | |
| 16 | + | |
| 17 | +import org.slf4j.Logger; | |
| 18 | +import org.slf4j.LoggerFactory; | |
| 19 | +import org.springframework.beans.factory.annotation.Autowired; | |
| 20 | +import org.springframework.jdbc.core.JdbcTemplate; | |
| 21 | +import org.springframework.stereotype.Service; | |
| 22 | + | |
| 23 | +/** | |
| 24 | + * Created by 19/03/18. | |
| 25 | + */ | |
| 26 | +@Service | |
| 27 | +public class CalcLbStatuAnalyServiceImpl extends BaseServiceImpl<CalcLbStatuAnaly, Integer> implements CalcLbStatuAnalyService { | |
| 28 | + | |
| 29 | + @Autowired | |
| 30 | + private CalcLbStatuAnalyRepository calcRepository; | |
| 31 | + | |
| 32 | + @Autowired | |
| 33 | + private LineService lineService; | |
| 34 | + | |
| 35 | + @Autowired | |
| 36 | + JdbcTemplate jdbcTemplate; | |
| 37 | + | |
| 38 | + | |
| 39 | + Logger logger = LoggerFactory.getLogger(this.getClass()); | |
| 40 | + | |
| 41 | + | |
| 42 | + @Override | |
| 43 | + public List<Map<String, Object>> lbStatuAnaly(String gsdm, String fgsdm, | |
| 44 | + String line, String date, String date2, String sfyy, String type) { | |
| 45 | + // TODO Auto-generated method stub | |
| 46 | + List<Map<String, Object>> resList = new ArrayList<Map<String, Object>>(); | |
| 47 | + List<CalcLbStatuAnaly> query = calcRepository.selectByDateAndLine(line, date, date2, gsdm, fgsdm); | |
| 48 | + Map<String, Boolean> lineNature = lineService.lineNature(); | |
| 49 | + Map<String, List<CalcLbStatuAnaly>> keyMap = new HashMap<String, List<CalcLbStatuAnaly>>(); | |
| 50 | + List<String> keyList = new ArrayList<String>(); | |
| 51 | + | |
| 52 | + String[] Date1 = date.split("-"); | |
| 53 | + String[] Date2 = date2.split("-"); | |
| 54 | + String Date = ""; | |
| 55 | + if(date.equals(date2)) | |
| 56 | + Date = Date1[0] + "年" + Date1[1] + "月" + Date1[2] + "日"; | |
| 57 | + else | |
| 58 | + Date = Date1[0] + "年" + Date1[1] + "月" + Date1[2] + "日 - " | |
| 59 | + + Date2[0] + "年" + Date2[1] + "月" + Date2[2] + "日"; | |
| 60 | + | |
| 61 | + for(CalcLbStatuAnaly lb : query){ | |
| 62 | + String xlBm = lb.getXl(); | |
| 63 | + if(lineNature.containsKey(xlBm) && lineNature.get(xlBm) != null){ | |
| 64 | + if(sfyy.equals("1") && !lineNature.get(xlBm)){ | |
| 65 | + continue; | |
| 66 | + } else if(sfyy.equals("2") && lineNature.get(xlBm)){ | |
| 67 | + continue; | |
| 68 | + } | |
| 69 | + } else if(sfyy.equals("2")){ | |
| 70 | + continue; | |
| 71 | + } | |
| 72 | + | |
| 73 | + String key = lb.getGsdm() + "/" + lb.getFgsdm() + "/" + lb.getXl(); | |
| 74 | + | |
| 75 | + if(!keyMap.containsKey(key)){ | |
| 76 | + keyMap.put(key, new ArrayList<CalcLbStatuAnaly>()); | |
| 77 | + keyList.add(key); | |
| 78 | + } | |
| 79 | + keyMap.get(key).add(lb); | |
| 80 | + } | |
| 81 | + | |
| 82 | + Collections.sort(keyList, new Comparator<String>() { | |
| 83 | + | |
| 84 | + public int compare(String o1, String o2) { | |
| 85 | + | |
| 86 | + Long a = 0l; | |
| 87 | + Long b = 0l; | |
| 88 | + String[] split1 = o1.split("/"); | |
| 89 | + String[] split2 = o2.split("/"); | |
| 90 | + char[] charArray1 = split1[2].toCharArray(); | |
| 91 | + char[] charArray2 = split2[2].toCharArray(); | |
| 92 | + for(int i = 0; i < charArray1.length; i++){ | |
| 93 | + long temp = 1l; | |
| 94 | + for(int j = 0; j < i; j++) | |
| 95 | + temp *= 10; | |
| 96 | + a += (long)charArray1[charArray1.length - 1 - i] * temp; | |
| 97 | + } | |
| 98 | + for(int i = 0; i < charArray2.length; i++){ | |
| 99 | + long temp = 1l; | |
| 100 | + for(int j = 0; j < i; j++) | |
| 101 | + temp *= 10; | |
| 102 | + b += (long)charArray2[charArray2.length - 1 - i] * temp; | |
| 103 | + } | |
| 104 | + | |
| 105 | + return a.compareTo(b); | |
| 106 | + } | |
| 107 | + }); | |
| 108 | + Collections.sort(keyList, new Comparator<String>() { | |
| 109 | + | |
| 110 | + public int compare(String o1, String o2) { | |
| 111 | + | |
| 112 | + Long a = 0l; | |
| 113 | + Long b = 0l; | |
| 114 | + String[] split1 = o1.split("/"); | |
| 115 | + String[] split2 = o2.split("/"); | |
| 116 | + char[] charArray1 = split1[1].toCharArray(); | |
| 117 | + char[] charArray2 = split2[1].toCharArray(); | |
| 118 | + for(int i = 0; i < charArray1.length; i++){ | |
| 119 | + long temp = 1l; | |
| 120 | + for(int j = 0; j < i; j++) | |
| 121 | + temp *= 10; | |
| 122 | + a += (long)charArray1[charArray1.length - 1 - i] * temp; | |
| 123 | + } | |
| 124 | + for(int i = 0; i < charArray2.length; i++){ | |
| 125 | + long temp = 1l; | |
| 126 | + for(int j = 0; j < i; j++) | |
| 127 | + temp *= 10; | |
| 128 | + b += (long)charArray2[charArray2.length - 1 - i] * temp; | |
| 129 | + } | |
| 130 | + | |
| 131 | + return a.compareTo(b); | |
| 132 | + } | |
| 133 | + }); | |
| 134 | + | |
| 135 | + String company = "", subCompany = "", lineName = ""; | |
| 136 | + Map<String, Object> lastMap = new HashMap<String, Object>(); | |
| 137 | + lastMap.put("line", "合计"); | |
| 138 | + for(String key : keyList){ | |
| 139 | + List<CalcLbStatuAnaly> list = keyMap.get(key); | |
| 140 | + Map<String, Object> m = new HashMap<String, Object>(); | |
| 141 | + company = ""; | |
| 142 | + subCompany = ""; | |
| 143 | + lineName = ""; | |
| 144 | + for(CalcLbStatuAnaly lb : list){ | |
| 145 | + if(lb.getGsname() != null && company.trim().length() == 0) | |
| 146 | + company = lb.getGsname(); | |
| 147 | + if(lb.getFgsname() != null && subCompany.trim().length() == 0) | |
| 148 | + subCompany = lb.getFgsname(); | |
| 149 | + if(lb.getXlName() != null && lineName.trim().length() == 0) | |
| 150 | + lineName = lb.getXlName(); | |
| 151 | + m.put("jhbc", Arith.add(m.get("jhbc")!=null?m.get("jhbc"):"0", lb.getJhbc())); | |
| 152 | + m.put("sjbc", Arith.add(m.get("sjbc")!=null?m.get("sjbc"):"0", lb.getSjbc())); | |
| 153 | + m.put("jhlc", Arith.add(m.get("jhlc")!=null?m.get("jhlc"):"0", lb.getJhlc()!=null?lb.getJhlc():"0")); | |
| 154 | + m.put("sjlc", Arith.add(m.get("sjlc")!=null?m.get("sjlc"):"0", lb.getSjlc()!=null?lb.getSjlc():"0")); | |
| 155 | + m.put("lzbc", Arith.add(m.get("lzbc")!=null?m.get("lzbc"):"0", lb.getLzbc())); | |
| 156 | + m.put("lzlc", Arith.add(m.get("lzlc")!=null?m.get("lzlc"):"0", lb.getLzlc()!=null?lb.getLzlc():"0")); | |
| 157 | + m.put("dmbc", Arith.add(m.get("dmbc")!=null?m.get("dmbc"):"0", lb.getDmbc())); | |
| 158 | + m.put("dmlc", Arith.add(m.get("dmlc")!=null?m.get("dmlc"):"0", lb.getDmlc()!=null?lb.getDmlc():"0")); | |
| 159 | + m.put("gzbc", Arith.add(m.get("gzbc")!=null?m.get("gzbc"):"0", lb.getGzbc())); | |
| 160 | + m.put("gzlc", Arith.add(m.get("gzlc")!=null?m.get("gzlc"):"0", lb.getGzlc()!=null?lb.getGzlc():"0")); | |
| 161 | + m.put("jfbc", Arith.add(m.get("jfbc")!=null?m.get("jfbc"):"0", lb.getJfbc())); | |
| 162 | + m.put("jflc", Arith.add(m.get("jflc")!=null?m.get("jflc"):"0", lb.getJflc()!=null?lb.getJflc():"0")); | |
| 163 | + m.put("zsbc", Arith.add(m.get("zsbc")!=null?m.get("zsbc"):"0", lb.getZsbc())); | |
| 164 | + m.put("zslc", Arith.add(m.get("zslc")!=null?m.get("zslc"):"0", lb.getZslc()!=null?lb.getZslc():"0")); | |
| 165 | + m.put("qrbc", Arith.add(m.get("qrbc")!=null?m.get("qrbc"):"0", lb.getQrbc())); | |
| 166 | + m.put("qrlc", Arith.add(m.get("qrlc")!=null?m.get("qrlc"):"0", lb.getQrlc()!=null?lb.getQrlc():"0")); | |
| 167 | + m.put("qcbc", Arith.add(m.get("qcbc")!=null?m.get("qcbc"):"0", lb.getQcbc())); | |
| 168 | + m.put("qclc", Arith.add(m.get("qclc")!=null?m.get("qclc"):"0", lb.getQclc()!=null?lb.getQclc():"0")); | |
| 169 | + m.put("kxbc", Arith.add(m.get("kxbc")!=null?m.get("kxbc"):"0", lb.getKxbc())); | |
| 170 | + m.put("kxlc", Arith.add(m.get("kxlc")!=null?m.get("kxlc"):"0", lb.getKxlc()!=null?lb.getKxlc():"0")); | |
| 171 | + m.put("qhbc", Arith.add(m.get("qhbc")!=null?m.get("qhbc"):"0", lb.getQhbc())); | |
| 172 | + m.put("qhlc", Arith.add(m.get("qhlc")!=null?m.get("qhlc"):"0", lb.getQhlc()!=null?lb.getQhlc():"0")); | |
| 173 | + m.put("ywbc", Arith.add(m.get("ywbc")!=null?m.get("ywbc"):"0", lb.getYwbc())); | |
| 174 | + m.put("ywlc", Arith.add(m.get("ywlc")!=null?m.get("ywlc"):"0", lb.getYwlc()!=null?lb.getYwlc():"0")); | |
| 175 | + m.put("qtbc", Arith.add(m.get("qtbc")!=null?m.get("qtbc"):"0", lb.getQtbc())); | |
| 176 | + m.put("qtlc", Arith.add(m.get("qtlc")!=null?m.get("qtlc"):"0", lb.getQtlc()!=null?lb.getQtlc():"0")); | |
| 177 | + } | |
| 178 | + m.put("date", Date); | |
| 179 | + m.put("company", company); | |
| 180 | + m.put("subCompany", subCompany); | |
| 181 | + m.put("line", lineName); | |
| 182 | + resList.add(m); | |
| 183 | + | |
| 184 | + lastMap.put("jhbc", Arith.add(m.get("jhbc")!=null?m.get("jhbc"):"0", lastMap.get("jhbc")!=null?lastMap.get("jhbc"):"0")); | |
| 185 | + lastMap.put("sjbc", Arith.add(m.get("sjbc")!=null?m.get("sjbc"):"0", lastMap.get("sjbc")!=null?lastMap.get("sjbc"):"0")); | |
| 186 | + lastMap.put("jhlc", Arith.add(m.get("jhlc")!=null?m.get("jhlc"):"0", lastMap.get("jhlc")!=null?lastMap.get("jhlc"):"0")); | |
| 187 | + lastMap.put("sjlc", Arith.add(m.get("sjlc")!=null?m.get("sjlc"):"0", lastMap.get("sjlc")!=null?lastMap.get("sjlc"):"0")); | |
| 188 | + lastMap.put("lzbc", Arith.add(m.get("lzbc")!=null?m.get("lzbc"):"0", lastMap.get("lzbc")!=null?lastMap.get("lzbc"):"0")); | |
| 189 | + lastMap.put("lzlc", Arith.add(m.get("lzlc")!=null?m.get("lzlc"):"0", lastMap.get("lzlc")!=null?lastMap.get("lzlc"):"0")); | |
| 190 | + lastMap.put("dmbc", Arith.add(m.get("dmbc")!=null?m.get("dmbc"):"0", lastMap.get("dmbc")!=null?lastMap.get("dmbc"):"0")); | |
| 191 | + lastMap.put("dmlc", Arith.add(m.get("dmlc")!=null?m.get("dmlc"):"0", lastMap.get("dmlc")!=null?lastMap.get("dmlc"):"0")); | |
| 192 | + lastMap.put("gzbc", Arith.add(m.get("gzbc")!=null?m.get("gzbc"):"0", lastMap.get("gzbc")!=null?lastMap.get("gzbc"):"0")); | |
| 193 | + lastMap.put("gzlc", Arith.add(m.get("gzlc")!=null?m.get("gzlc"):"0", lastMap.get("gzlc")!=null?lastMap.get("gzlc"):"0")); | |
| 194 | + lastMap.put("jfbc", Arith.add(m.get("jfbc")!=null?m.get("jfbc"):"0", lastMap.get("jfbc")!=null?lastMap.get("jfbc"):"0")); | |
| 195 | + lastMap.put("jflc", Arith.add(m.get("jflc")!=null?m.get("jflc"):"0", lastMap.get("jflc")!=null?lastMap.get("jflc"):"0")); | |
| 196 | + lastMap.put("zsbc", Arith.add(m.get("zsbc")!=null?m.get("zsbc"):"0", lastMap.get("zsbc")!=null?lastMap.get("zsbc"):"0")); | |
| 197 | + lastMap.put("zslc", Arith.add(m.get("zslc")!=null?m.get("zslc"):"0", lastMap.get("zslc")!=null?lastMap.get("zslc"):"0")); | |
| 198 | + lastMap.put("qrbc", Arith.add(m.get("qrbc")!=null?m.get("qrbc"):"0", lastMap.get("qrbc")!=null?lastMap.get("qrbc"):"0")); | |
| 199 | + lastMap.put("qrlc", Arith.add(m.get("qrlc")!=null?m.get("qrlc"):"0", lastMap.get("qrlc")!=null?lastMap.get("qrlc"):"0")); | |
| 200 | + lastMap.put("qcbc", Arith.add(m.get("qcbc")!=null?m.get("qcbc"):"0", lastMap.get("qcbc")!=null?lastMap.get("qcbc"):"0")); | |
| 201 | + lastMap.put("qclc", Arith.add(m.get("qclc")!=null?m.get("qclc"):"0", lastMap.get("qclc")!=null?lastMap.get("qclc"):"0")); | |
| 202 | + lastMap.put("kxbc", Arith.add(m.get("kxbc")!=null?m.get("kxbc"):"0", lastMap.get("kxbc")!=null?lastMap.get("kxbc"):"0")); | |
| 203 | + lastMap.put("kxlc", Arith.add(m.get("kxlc")!=null?m.get("kxlc"):"0", lastMap.get("kxlc")!=null?lastMap.get("kxlc"):"0")); | |
| 204 | + lastMap.put("qhbc", Arith.add(m.get("qhbc")!=null?m.get("qhbc"):"0", lastMap.get("qhbc")!=null?lastMap.get("qhbc"):"0")); | |
| 205 | + lastMap.put("qhlc", Arith.add(m.get("qhlc")!=null?m.get("qhlc"):"0", lastMap.get("qhlc")!=null?lastMap.get("qhlc"):"0")); | |
| 206 | + lastMap.put("ywbc", Arith.add(m.get("ywbc")!=null?m.get("ywbc"):"0", lastMap.get("ywbc")!=null?lastMap.get("ywbc"):"0")); | |
| 207 | + lastMap.put("ywlc", Arith.add(m.get("ywlc")!=null?m.get("ywlc"):"0", lastMap.get("ywlc")!=null?lastMap.get("ywlc"):"0")); | |
| 208 | + lastMap.put("qtbc", Arith.add(m.get("qtbc")!=null?m.get("qtbc"):"0", lastMap.get("qtbc")!=null?lastMap.get("qtbc"):"0")); | |
| 209 | + lastMap.put("qtlc", Arith.add(m.get("qtlc")!=null?m.get("qtlc"):"0", lastMap.get("qtlc")!=null?lastMap.get("qtlc"):"0")); | |
| 210 | + } | |
| 211 | + | |
| 212 | + if(resList.size() > 0){ | |
| 213 | + resList.add(lastMap); | |
| 214 | + for(Map<String, Object> m : resList){ | |
| 215 | + if(Arith.compareTo(m.get("sjbc"), 0) == 1 && Arith.compareTo(m.get("jhbc"), 0) == 1){ | |
| 216 | + m.put("bcbfb", Arith.div(Arith.mul(m.get("sjbc"), 100), m.get("jhbc"), 2) + "%"); | |
| 217 | + } else { | |
| 218 | + m.put("bcbfb", "0%"); | |
| 219 | + } | |
| 220 | + if(Arith.compareTo(m.get("sjlc"), 0) == 1 && Arith.compareTo(m.get("jhlc"), 0) == 1){ | |
| 221 | + m.put("lcbfb", Arith.div(Arith.mul(m.get("sjlc"), 100), m.get("jhlc"), 2) + "%"); | |
| 222 | + } else { | |
| 223 | + m.put("lcbfb", "0%"); | |
| 224 | + } | |
| 225 | + if(Arith.compareTo(m.get("lzbc"), 0) == 1 && Arith.compareTo(m.get("jhbc"), 0) == 1){ | |
| 226 | + m.put("lzbfb", Arith.div(Arith.mul(m.get("lzbc"), 100), m.get("jhbc"), 2) + "%"); | |
| 227 | + } else { | |
| 228 | + m.put("lzbfb", "0%"); | |
| 229 | + } | |
| 230 | + if(Arith.compareTo(m.get("dmbc"), 0) == 1 && Arith.compareTo(m.get("jhbc"), 0) == 1){ | |
| 231 | + m.put("dmbfb", Arith.div(Arith.mul(m.get("dmbc"), 100), m.get("jhbc"), 2) + "%"); | |
| 232 | + } else { | |
| 233 | + m.put("dmbfb", "0%"); | |
| 234 | + } | |
| 235 | + if(Arith.compareTo(m.get("gzbc"), 0) == 1 && Arith.compareTo(m.get("jhbc"), 0) == 1){ | |
| 236 | + m.put("gzbfb", Arith.div(Arith.mul(m.get("gzbc"), 100), m.get("jhbc"), 2) + "%"); | |
| 237 | + } else { | |
| 238 | + m.put("gzbfb", "0%"); | |
| 239 | + } | |
| 240 | + if(Arith.compareTo(m.get("jfbc"), 0) == 1 && Arith.compareTo(m.get("jhbc"), 0) == 1){ | |
| 241 | + m.put("jfbfb", Arith.div(Arith.mul(m.get("jfbc"), 100), m.get("jhbc"), 2) + "%"); | |
| 242 | + } else { | |
| 243 | + m.put("jfbfb", "0%"); | |
| 244 | + } | |
| 245 | + if(Arith.compareTo(m.get("zsbc"), 0) == 1 && Arith.compareTo(m.get("jhbc"), 0) == 1){ | |
| 246 | + m.put("zsbfb", Arith.div(Arith.mul(m.get("zsbc"), 100), m.get("jhbc"), 2) + "%"); | |
| 247 | + } else { | |
| 248 | + m.put("zsbfb", "0%"); | |
| 249 | + } | |
| 250 | + if(Arith.compareTo(m.get("qrbc"), 0) == 1 && Arith.compareTo(m.get("jhbc"), 0) == 1){ | |
| 251 | + m.put("qrbfb", Arith.div(Arith.mul(m.get("qrbc"), 100), m.get("jhbc"), 2) + "%"); | |
| 252 | + } else { | |
| 253 | + m.put("qrbfb", "0%"); | |
| 254 | + } | |
| 255 | + if(Arith.compareTo(m.get("qcbc"), 0) == 1 && Arith.compareTo(m.get("jhbc"), 0) == 1){ | |
| 256 | + m.put("qcbfb", Arith.div(Arith.mul(m.get("qcbc"), 100), m.get("jhbc"), 2) + "%"); | |
| 257 | + } else { | |
| 258 | + m.put("qcbfb", "0%"); | |
| 259 | + } | |
| 260 | + if(Arith.compareTo(m.get("kxbc"), 0) == 1 && Arith.compareTo(m.get("jhbc"), 0) == 1){ | |
| 261 | + m.put("kxbfb", Arith.div(Arith.mul(m.get("kxbc"), 100), m.get("jhbc"), 2) + "%"); | |
| 262 | + } else { | |
| 263 | + m.put("kxbfb", "0%"); | |
| 264 | + } | |
| 265 | + if(Arith.compareTo(m.get("qhbc"), 0) == 1 && Arith.compareTo(m.get("jhbc"), 0) == 1){ | |
| 266 | + m.put("qhbfb", Arith.div(Arith.mul(m.get("qhbc"), 100), m.get("jhbc"), 2) + "%"); | |
| 267 | + } else { | |
| 268 | + m.put("qhbfb", "0%"); | |
| 269 | + } | |
| 270 | + if(Arith.compareTo(m.get("ywbc"), 0) == 1 && Arith.compareTo(m.get("jhbc"), 0) == 1){ | |
| 271 | + m.put("ywbfb", Arith.div(Arith.mul(m.get("ywbc"), 100), m.get("jhbc"), 2) + "%"); | |
| 272 | + } else { | |
| 273 | + m.put("ywbfb", "0%"); | |
| 274 | + } | |
| 275 | + if(Arith.compareTo(m.get("qtbc"), 0) == 1 && Arith.compareTo(m.get("jhbc"), 0) == 1){ | |
| 276 | + m.put("qtbfb", Arith.div(Arith.mul(m.get("qtbc"), 100), m.get("jhbc"), 2) + "%"); | |
| 277 | + } else { | |
| 278 | + m.put("qtbfb", "0%"); | |
| 279 | + } | |
| 280 | + } | |
| 281 | + } | |
| 282 | + | |
| 283 | + return resList; | |
| 284 | + } | |
| 285 | + | |
| 286 | +} | ... | ... |
src/main/resources/static/pages/forms/calc/calcLbStatuAnaly.html
0 → 100644
| 1 | +<style type="text/css"> | |
| 2 | + .table-bordered { | |
| 3 | + border: 1px solid; } | |
| 4 | + .table-bordered > thead > tr > th, | |
| 5 | + .table-bordered > thead > tr > td, | |
| 6 | + .table-bordered > tbody > tr > th, | |
| 7 | + .table-bordered > tbody > tr > td, | |
| 8 | + .table-bordered > tfoot > tr > th, | |
| 9 | + .table-bordered > tfoot > tr > td { | |
| 10 | + border: 1px solid; } | |
| 11 | + .table-bordered > thead > tr > th, | |
| 12 | + .table-bordered > thead > tr > td { | |
| 13 | + border-bottom-width: 2px; } | |
| 14 | + .table > tbody + tbody { | |
| 15 | + border-top: 1px solid; } | |
| 16 | + #forms > tbody > tr{ | |
| 17 | + background-color: #FFFFFF; | |
| 18 | + } | |
| 19 | +</style> | |
| 20 | + | |
| 21 | +<div class="page-head"> | |
| 22 | + <div class="page-title"> | |
| 23 | + <h1>烂班情况分析表(统计)</h1> | |
| 24 | + </div> | |
| 25 | +</div> | |
| 26 | + | |
| 27 | +<div class="row"> | |
| 28 | + <div class="col-md-12"> | |
| 29 | + <div class="portlet light porttlet-fit bordered"> | |
| 30 | + <div class="portlet-title"> | |
| 31 | + <form id="history" class="form-inline" action=""> | |
| 32 | + <div style="display: inline-block;margin-left: 5px;"> | |
| 33 | + <span class="item-label" style="width: 80px;">烂班原因: </span> | |
| 34 | + <input class="form-control" type="checkbox" id="totalLb" style="width: 20px;" checked="true"/>全选 | |
| 35 | + <input class="form-control" type="checkbox" name="reason" style="width: 20px;" value="0" checked="true"/>路阻 | |
| 36 | + <input class="form-control" type="checkbox" name="reason" style="width: 20px;" value="1" checked="true"/>吊慢 | |
| 37 | + <input class="form-control" type="checkbox" name="reason" style="width: 20px;" value="2" checked="true"/>故障 | |
| 38 | + <input class="form-control" type="checkbox" name="reason" style="width: 20px;" value="3" checked="true"/>纠纷 | |
| 39 | + <input class="form-control" type="checkbox" name="reason" style="width: 20px;" value="4" checked="true"/>肇事 | |
| 40 | + <input class="form-control" type="checkbox" name="reason" style="width: 20px;" value="5" checked="true"/>缺人 | |
| 41 | + <input class="form-control" type="checkbox" name="reason" style="width: 20px;" value="6" checked="true"/>缺车 | |
| 42 | + <input class="form-control" type="checkbox" name="reason" style="width: 20px;" value="7" checked="true"/>客稀 | |
| 43 | + <input class="form-control" type="checkbox" name="reason" style="width: 20px;" value="8" checked="true"/>气候 | |
| 44 | + <input class="form-control" type="checkbox" name="reason" style="width: 20px;" value="9" checked="true"/>援外 | |
| 45 | + <input class="form-control" type="checkbox" name="reason" style="width: 20px;" value="10" checked="true"/>其他 | |
| 46 | + </div> | |
| 47 | + <div style="margin-top: 5px"></div> | |
| 48 | + <div style="display: inline-block; margin-left: 33px;" id="company1"> | |
| 49 | + <span class="item-label" style="width: 80px;">公司: </span> | |
| 50 | + <select class="form-control" name="company" id="company" style="width: 140px;"></select> | |
| 51 | + </div> | |
| 52 | + <div style="display: inline-block; margin-left: 24px;" id="subCompany1"> | |
| 53 | + <span class="item-label" style="width: 80px;">分公司: </span> | |
| 54 | + <select class="form-control" name="subCompany" id="subCompany" style="width: 140px;"></select> | |
| 55 | + </div> | |
| 56 | + <div style="display: inline-block; margin-left: 10px;"> | |
| 57 | + <span class="item-label" style="width: 80px;">选择线路: </span> | |
| 58 | + <select class="form-control" name="line" id="line" style="width: 150px;"></select> | |
| 59 | + </div> | |
| 60 | + <div style="margin-top: 10px"></div> | |
| 61 | + <div style="display: inline-block; margin-left: 5px"> | |
| 62 | + <span class="item-label" style="width: 80px;">是否营运: </span> | |
| 63 | + <select class="form-control" name="sfyy" id="sfyy" style="width: 140px;"> | |
| 64 | + <option value="0">全部线路</option> | |
| 65 | + <option value="1" selected="selected">营运线路</option> | |
| 66 | + <option value="2">非营运线路</option> | |
| 67 | + </select> | |
| 68 | + </div> | |
| 69 | + <div style="display: inline-block;margin-left: 10px;"> | |
| 70 | + <span class="item-label" style="width: 80px;">开始时间: </span> | |
| 71 | + <input class="form-control" type="text" id="startDate" style="width: 140px;"/> | |
| 72 | + </div> | |
| 73 | + <div style="display: inline-block;margin-left: 10px;"> | |
| 74 | + <span class="item-label" style="width: 80px;">结束时间: </span> | |
| 75 | + <input class="form-control" type="text" id="endDate" style="width: 140px;"/> | |
| 76 | + </div> | |
| 77 | + <div class="form-group" style="margin-left: 10px"> | |
| 78 | + <input class="btn btn-default" type="button" id="query" value="筛选"/> | |
| 79 | + <input class="btn btn-default" type="button" id="export" value="导出"/> | |
| 80 | + </div> | |
| 81 | + </form> | |
| 82 | + </div> | |
| 83 | + <div class="portlet-body"> | |
| 84 | + <div class="table-container" id="table" style="margin-top: 0px;overflow:auto;min-width: 906px;"> | |
| 85 | + <table class="table table-bordered table-hover table-checkable" id="forms"> | |
| 86 | + <thead> | |
| 87 | + | |
| 88 | + </thead> | |
| 89 | + <tbody> | |
| 90 | + | |
| 91 | + </tbody> | |
| 92 | + </table> | |
| 93 | + <div style="text-align: right;"> | |
| 94 | + <ul id="pagination" class="pagination"></ul> | |
| 95 | + </div> | |
| 96 | + </div> | |
| 97 | + </div> | |
| 98 | + </div> | |
| 99 | + </div> | |
| 100 | +</div> | |
| 101 | + | |
| 102 | +<script> | |
| 103 | + $(function(){ | |
| 104 | + $('#export').attr('disabled', "true"); | |
| 105 | + | |
| 106 | + // 关闭左侧栏 | |
| 107 | + if (!$('body').hasClass('page-sidebar-closed')) | |
| 108 | + $('.menu-toggler.sidebar-toggler').click(); | |
| 109 | + | |
| 110 | + | |
| 111 | + var d = new Date(); | |
| 112 | + d.setTime(d.getTime() - 1*1000*60*60*24); | |
| 113 | + var year = d.getFullYear(); | |
| 114 | + var month = d.getMonth() + 1; | |
| 115 | + var day = d.getDate(); | |
| 116 | + if(month < 10) | |
| 117 | + month = "0" + month; | |
| 118 | + if(day < 10) | |
| 119 | + day = "0" + day; | |
| 120 | + var dateTime = year + "-" + month + "-" + day; | |
| 121 | + $("#startDate").datetimepicker({ | |
| 122 | + format : 'YYYY-MM-DD', | |
| 123 | + locale : 'zh-cn', | |
| 124 | + maxDate : dateTime | |
| 125 | + }); | |
| 126 | + $("#endDate").datetimepicker({ | |
| 127 | + format : 'YYYY-MM-DD', | |
| 128 | + locale : 'zh-cn', | |
| 129 | + maxDate : dateTime | |
| 130 | + }); | |
| 131 | + $("#startDate").val(dateTime); | |
| 132 | + $("#endDate").val(dateTime); | |
| 133 | + | |
| 134 | + | |
| 135 | + var fage=false; | |
| 136 | + var xlList; | |
| 137 | + var obj = []; | |
| 138 | + | |
| 139 | + $.get('/report/lineList',function(result){ | |
| 140 | + xlList=result; | |
| 141 | + $.get('/user/companyData', function(result){ | |
| 142 | + obj = result; | |
| 143 | + var options = ''; | |
| 144 | + for(var i = 0; i < obj.length; i++){ | |
| 145 | + options += '<option value="'+obj[i].companyCode+'">'+obj[i].companyName+'</option>'; | |
| 146 | + } | |
| 147 | + | |
| 148 | + if(obj.length ==0){ | |
| 149 | + $("#company1").css('display','none'); | |
| 150 | + }else if(obj.length ==1){ | |
| 151 | + $("#company1").css('display','none'); | |
| 152 | + if(obj[0].children.length == 1 || obj[0].children.length ==0) | |
| 153 | + $('#subCompany1').css('display','none'); | |
| 154 | + } | |
| 155 | + $('#company').html(options); | |
| 156 | + updateCompany(); | |
| 157 | + }); | |
| 158 | + }) | |
| 159 | + $("#company").on("change",updateCompany); | |
| 160 | + function updateCompany(){ | |
| 161 | + var company = $('#company').val(); | |
| 162 | + var options = '<option value="">全部分公司</option>'; | |
| 163 | + for(var i = 0; i < obj.length; i++){ | |
| 164 | + if(obj[i].companyCode == company){ | |
| 165 | + var children = obj[i].children; | |
| 166 | + for(var j = 0; j < children.length; j++){ | |
| 167 | + options += '<option value="'+children[j].code+'">'+children[j].name+'</option>'; | |
| 168 | + } | |
| 169 | + } | |
| 170 | + } | |
| 171 | + $('#subCompany').html(options); | |
| 172 | + } | |
| 173 | + | |
| 174 | + var tempData = {}; | |
| 175 | + $.get('/report/lineList',function(xlList){ | |
| 176 | + var data = []; | |
| 177 | + data.push({id: " ", text: "全部线路"}); | |
| 178 | + $.get('/user/companyData', function(result){ | |
| 179 | + for(var i = 0; i < result.length; i++){ | |
| 180 | + var companyCode = result[i].companyCode; | |
| 181 | + var children = result[i].children; | |
| 182 | + for(var j = 0; j < children.length; j++){ | |
| 183 | + var code = children[j].code; | |
| 184 | + for(var k=0;k < xlList.length;k++ ){ | |
| 185 | + if(xlList[k]["fgsbm"]==code && xlList[k]["gsbm"]==companyCode){ | |
| 186 | + data.push({id: xlList[k]["xlbm"], text: xlList[k]["xlname"]}); | |
| 187 | + tempData[xlList[k]["xlbm"]] = companyCode+":"+code; | |
| 188 | + } | |
| 189 | + } | |
| 190 | + } | |
| 191 | + } | |
| 192 | + initPinYinSelect2('#line',data,''); | |
| 193 | + | |
| 194 | + }); | |
| 195 | + }); | |
| 196 | + | |
| 197 | + $("#line").on("change", function(){ | |
| 198 | + if($("#line").val() == " "){ | |
| 199 | + $("#company").attr("disabled", false); | |
| 200 | + $("#subCompany").attr("disabled", false); | |
| 201 | + } else { | |
| 202 | + var temp = tempData[$("#line").val()].split(":"); | |
| 203 | + $("#company").val(temp[0]); | |
| 204 | + updateCompany(); | |
| 205 | +// $("#subCompany").val(temp[1]); | |
| 206 | + $("#subCompany").val(""); | |
| 207 | + $("#company").attr("disabled", true); | |
| 208 | +// $("#subCompany").attr("disabled", true); | |
| 209 | + } | |
| 210 | + }); | |
| 211 | + | |
| 212 | + var lb = 0; //标志是否有选择至少一个烂班类型 | |
| 213 | + $("#totalLb").on("change", function(){ | |
| 214 | + var reason = $("input[name='reason']"); | |
| 215 | + var checked = this.checked; | |
| 216 | + $.each(reason, function(i, g){ | |
| 217 | + g.checked = checked; | |
| 218 | + }); | |
| 219 | + if(checked == true) | |
| 220 | + lb = 33; | |
| 221 | + else | |
| 222 | + lb = 0; | |
| 223 | + }); | |
| 224 | + | |
| 225 | + $("input[name='reason']").on("change", function(){ | |
| 226 | + var totalLb = $("#totalLb")[0]; | |
| 227 | + totalLb.checked = true; | |
| 228 | + lb = 0; | |
| 229 | + $.each($("input[name='reason']"), function(i, g){ | |
| 230 | + if(g.checked == false){ | |
| 231 | + totalLb.checked = false; | |
| 232 | + }else{ | |
| 233 | + lb += 3; | |
| 234 | + } | |
| 235 | + }); | |
| 236 | + }); | |
| 237 | + | |
| 238 | + $("#query").on("click",jsDoQuery); | |
| 239 | + | |
| 240 | + var sfyy = 1; | |
| 241 | + var line = $("#line").val(); | |
| 242 | + var startDate = $("#startDate").val(); | |
| 243 | + var endDate = $("#endDate").val(); | |
| 244 | + var company = $("#company").val(); | |
| 245 | + var subCompany = $("#subCompany").val(); | |
| 246 | + var lineName = $('#line option:selected').text(); | |
| 247 | + function jsDoQuery(pagination){ | |
| 248 | + if($("#startDate").val().trim().length == 0 || $("#endDate").val().trim().length == 0){ | |
| 249 | + layer.msg("请选择日期"); | |
| 250 | + return; | |
| 251 | + } | |
| 252 | + var reason = $("input[name='reason']"); | |
| 253 | + var params = {}; | |
| 254 | + if(line == " ") | |
| 255 | + line = ""; | |
| 256 | +// line = $("#line").val(); | |
| 257 | + sfyy = $("#sfyy").val(); | |
| 258 | + startDate = $("#startDate").val(); | |
| 259 | + endDate = $("#endDate").val(); | |
| 260 | + company = $("#company").val(); | |
| 261 | + subCompany = $("#subCompany").val(); | |
| 262 | + params['line'] = line; | |
| 263 | + params['sfyy'] = sfyy; | |
| 264 | + params['startDate'] = startDate; | |
| 265 | + params['endDate'] = endDate; | |
| 266 | + params['company'] = company; | |
| 267 | + params['subCompany'] = subCompany; | |
| 268 | + params['type'] = "query"; | |
| 269 | + lineName = $('#line option:selected').text(); | |
| 270 | + if(lineName == "全部线路") | |
| 271 | + lineName = $('#subCompany option:selected').text(); | |
| 272 | + var i = layer.load(2); | |
| 273 | +// $(".hidden").removeClass("hidden"); | |
| 274 | + $get('/calcLbStatuAnaly/lbStatuAnaly', params, function(result){ | |
| 275 | + // 把数据填充到模版中 | |
| 276 | + var tbodyHtml = template('list_lbAnaly',{list:result, reason:reason, lb:lb}); | |
| 277 | + // 把渲染好的模版html文本追加到表格中 | |
| 278 | + $('#forms').html(tbodyHtml); | |
| 279 | + layer.close(i); | |
| 280 | + | |
| 281 | + _w_table_rowspan("#forms", 1); | |
| 282 | + _w_table_rowspan("#forms", 2); | |
| 283 | + _w_table_rowspan("#forms", 3); | |
| 284 | + _w_table_rowspan("#forms", 4); | |
| 285 | +// _w_table_rowspan("#forms", 5); | |
| 286 | + | |
| 287 | + if(result.length == 0) | |
| 288 | + $('#export').attr('disabled', "true"); | |
| 289 | + else | |
| 290 | + $("#export").removeAttr("disabled"); | |
| 291 | + | |
| 292 | + if($("#forms").height()+70 > $(window).height()-110){ | |
| 293 | + $("#table").height($(window).height()-110); | |
| 294 | + } else { | |
| 295 | + $("#table").height($("#forms").height()+70); | |
| 296 | + } | |
| 297 | + }); | |
| 298 | + } | |
| 299 | + | |
| 300 | + $("#export").on("click", function(){ | |
| 301 | + if($("#startDate").val().trim().length == 0 || $("#endDate").val().trim().length == 0){ | |
| 302 | + layer.msg("请选择日期"); | |
| 303 | + return; | |
| 304 | + } | |
| 305 | + var params = {}; | |
| 306 | + params['line'] = line; | |
| 307 | + params['sfyy'] = sfyy; | |
| 308 | + params['startDate'] = startDate; | |
| 309 | + params['endDate'] = endDate; | |
| 310 | + params['company'] = company; | |
| 311 | + params['subCompany'] = subCompany; | |
| 312 | + params['type'] = "export"; | |
| 313 | + params['lineName'] = lineName; | |
| 314 | + var i = layer.load(2); | |
| 315 | + $get('/calc_export/lbStatuAnalyExport', params, function(result){ | |
| 316 | + var dd = ""; | |
| 317 | + if(startDate == endDate){ | |
| 318 | + dd = moment(startDate).format("YYYYMMDD"); | |
| 319 | + } else { | |
| 320 | + dd = moment(startDate).format("YYYYMMDD") | |
| 321 | + +"-"+moment(endDate).format("YYYYMMDD"); | |
| 322 | + } | |
| 323 | + window.open("/downloadFile/download?fileName=" | |
| 324 | + +dd+"-"+lineName+"-烂班情况分析表(统计)"); | |
| 325 | + layer.close(i); | |
| 326 | + }); | |
| 327 | + }); | |
| 328 | + | |
| 329 | + | |
| 330 | + $("#line").on("change", function(){ | |
| 331 | + line = $("#line").val(); | |
| 332 | + if(line == " ") | |
| 333 | + line = ""; | |
| 334 | + }); | |
| 335 | + $('#startDate').on("blur", function(){ | |
| 336 | + startDate = $("#startDate").val(); | |
| 337 | + endDate = $("#endDate").val(); | |
| 338 | + }); | |
| 339 | + $('#endDate').on("blur", function(){ | |
| 340 | + startDate = $("#startDate").val(); | |
| 341 | + endDate = $("#endDate").val(); | |
| 342 | + }); | |
| 343 | + | |
| 344 | + | |
| 345 | + /** | |
| 346 | + * 将模块List 转换为树结构 | |
| 347 | + * @param arr | |
| 348 | + * @returns {Array} | |
| 349 | + */ | |
| 350 | + function createTreeData(arr){ | |
| 351 | + var treeData = []; | |
| 352 | + var len = arr.length; | |
| 353 | + for(var i = 0; i < len; i ++){ | |
| 354 | + var pId = arr[i].pId; | |
| 355 | + arr[i].text = arr[i].name; | |
| 356 | + if(!pId){ | |
| 357 | + treeData.push(arr[i]); | |
| 358 | + } | |
| 359 | + | |
| 360 | + for(var j = 0; j < len; j ++){ | |
| 361 | + if(pId == arr[j].id){ | |
| 362 | + if(!arr[j].children) | |
| 363 | + arr[j].children = []; | |
| 364 | + arr[j].children.push(arr[i]); | |
| 365 | + break; | |
| 366 | + } | |
| 367 | + } | |
| 368 | + } | |
| 369 | + return treeData; | |
| 370 | + } | |
| 371 | + | |
| 372 | + function _w_table_rowspan(_w_table_id, _w_table_colnum){ | |
| 373 | + _w_table_firsttd = ""; | |
| 374 | + _w_table_currenttd = ""; | |
| 375 | + _w_table_SpanNum = 0; | |
| 376 | + _w_table_Obj = jQuery(_w_table_id + " tr td:nth-child(" + _w_table_colnum + ")"); | |
| 377 | + _w_table_Obj.each(function(i){ | |
| 378 | + if(i==0){ | |
| 379 | + _w_table_firsttd = jQuery(this); | |
| 380 | + _w_table_SpanNum = 1; | |
| 381 | + }else{ | |
| 382 | + _w_table_currenttd = jQuery(this); | |
| 383 | + if(_w_table_firsttd.text()==_w_table_currenttd.text()){ | |
| 384 | + _w_table_SpanNum++; | |
| 385 | + _w_table_currenttd.hide(); //remove(); | |
| 386 | + _w_table_firsttd.attr("rowSpan",_w_table_SpanNum); | |
| 387 | + }else{ | |
| 388 | + _w_table_firsttd = jQuery(this); | |
| 389 | + _w_table_SpanNum = 1; | |
| 390 | + } | |
| 391 | + } | |
| 392 | + }); | |
| 393 | + } | |
| 394 | + | |
| 395 | + | |
| 396 | + }); | |
| 397 | + | |
| 398 | +</script> | |
| 399 | +<script type="text/html" id="list_lbAnaly"> | |
| 400 | +<thead> | |
| 401 | + <tr> | |
| 402 | + <th class="hidden"></th> | |
| 403 | + <th rowspan="3" style=" width:120px;">日期</th> | |
| 404 | + <th rowspan="3">公司</th> | |
| 405 | + <th rowspan="3">分公司</th> | |
| 406 | + <th rowspan="3">线路</th> | |
| 407 | + <th rowspan="2" colspan="3">总班次</th> | |
| 408 | + <th rowspan="2" colspan="3">总营运公里</th> | |
| 409 | + {{if lb != 0}} | |
| 410 | + <th colspan={{lb}}>烂班原因</th> | |
| 411 | + {{/if}} | |
| 412 | + </tr> | |
| 413 | + <tr> | |
| 414 | + <th class="hidden"></th> | |
| 415 | + {{if reason[0].checked == true}}<th colspan="3">路阻</th>{{/if}} | |
| 416 | + {{if reason[1].checked == true}}<th colspan="3">吊慢</th>{{/if}} | |
| 417 | + {{if reason[2].checked == true}}<th colspan="3">故障</th>{{/if}} | |
| 418 | + {{if reason[3].checked == true}}<th colspan="3">纠纷</th>{{/if}} | |
| 419 | + {{if reason[4].checked == true}}<th colspan="3">肇事</th>{{/if}} | |
| 420 | + {{if reason[5].checked == true}}<th colspan="3">缺人</th>{{/if}} | |
| 421 | + {{if reason[6].checked == true}}<th colspan="3">缺车</th>{{/if}} | |
| 422 | + {{if reason[7].checked == true}}<th colspan="3">客稀</th>{{/if}} | |
| 423 | + {{if reason[8].checked == true}}<th colspan="3">气候</th>{{/if}} | |
| 424 | + {{if reason[9].checked == true}}<th colspan="3">援外</th>{{/if}} | |
| 425 | + {{if reason[10].checked == true}}<th colspan="3">其他</th>{{/if}} | |
| 426 | + </tr> | |
| 427 | + <tr> | |
| 428 | + <th class="hidden"></th> | |
| 429 | + <th>计划</th><th>实际</th><th>百分比</th> | |
| 430 | + <th>计划</th><th>实际</th><th>百分比</th> | |
| 431 | + {{if reason[0].checked==true}}<th>烂班班次</th><th>烂班公里</th><th>百分比</th>{{/if}} | |
| 432 | + {{if reason[1].checked==true}}<th>烂班班次</th><th>烂班公里</th><th>百分比</th>{{/if}} | |
| 433 | + {{if reason[2].checked==true}}<th>烂班班次</th><th>烂班公里</th><th>百分比</th>{{/if}} | |
| 434 | + {{if reason[3].checked==true}}<th>烂班班次</th><th>烂班公里</th><th>百分比</th>{{/if}} | |
| 435 | + {{if reason[4].checked==true}}<th>烂班班次</th><th>烂班公里</th><th>百分比</th>{{/if}} | |
| 436 | + {{if reason[5].checked==true}}<th>烂班班次</th><th>烂班公里</th><th>百分比</th>{{/if}} | |
| 437 | + {{if reason[6].checked==true}}<th>烂班班次</th><th>烂班公里</th><th>百分比</th>{{/if}} | |
| 438 | + {{if reason[7].checked==true}}<th>烂班班次</th><th>烂班公里</th><th>百分比</th>{{/if}} | |
| 439 | + {{if reason[8].checked==true}}<th>烂班班次</th><th>烂班公里</th><th>百分比</th>{{/if}} | |
| 440 | + {{if reason[9].checked==true}}<th>烂班班次</th><th>烂班公里</th><th>百分比</th>{{/if}} | |
| 441 | + {{if reason[10].checked==true}}<th>烂班班次</th><th>烂班公里</th><th>百分比</th>{{/if}} | |
| 442 | + </tr> | |
| 443 | +</thead> | |
| 444 | +<tbody> | |
| 445 | + {{each list as obj i}} | |
| 446 | + <tr> | |
| 447 | + {{if obj.line!='合计'}} | |
| 448 | + <td>{{obj.date}}</td> | |
| 449 | + <td>{{obj.company}}</td> | |
| 450 | + <td>{{obj.subCompany}}</td> | |
| 451 | + <td>{{obj.line}}</td> | |
| 452 | + {{/if}} | |
| 453 | + {{if obj.line=='合计'}} | |
| 454 | + <td colspan="4">{{obj.line}}</td> | |
| 455 | + {{/if}} | |
| 456 | + <td>{{obj.jhbc}}</td><td>{{obj.sjbc}}</td><td>{{obj.bcbfb}}</td> | |
| 457 | + <td>{{obj.jhlc}}</td><td>{{obj.sjlc}}</td><td>{{obj.lcbfb}}</td> | |
| 458 | + {{if reason[0].checked==true}}<td>{{obj.lzbc}}</td><td>{{obj.lzlc}}</td><td>{{obj.lzbfb}}</td>{{/if}} | |
| 459 | + {{if reason[1].checked==true}}<td>{{obj.dmbc}}</td><td>{{obj.dmlc}}</td><td>{{obj.dmbfb}}</td>{{/if}} | |
| 460 | + {{if reason[2].checked==true}}<td>{{obj.gzbc}}</td><td>{{obj.gzlc}}</td><td>{{obj.gzbfb}}</td>{{/if}} | |
| 461 | + {{if reason[3].checked==true}}<td>{{obj.jfbc}}</td><td>{{obj.jflc}}</td><td>{{obj.jfbfb}}</td>{{/if}} | |
| 462 | + {{if reason[4].checked==true}}<td>{{obj.zsbc}}</td><td>{{obj.zslc}}</td><td>{{obj.zsbfb}}</td>{{/if}} | |
| 463 | + {{if reason[5].checked==true}}<td>{{obj.qrbc}}</td><td>{{obj.qrlc}}</td><td>{{obj.qrbfb}}</td>{{/if}} | |
| 464 | + {{if reason[6].checked==true}}<td>{{obj.qcbc}}</td><td>{{obj.qclc}}</td><td>{{obj.qcbfb}}</td>{{/if}} | |
| 465 | + {{if reason[7].checked==true}}<td>{{obj.kxbc}}</td><td>{{obj.kxlc}}</td><td>{{obj.kxbfb}}</td>{{/if}} | |
| 466 | + {{if reason[8].checked==true}}<td>{{obj.qhbc}}</td><td>{{obj.qhlc}}</td><td>{{obj.qhbfb}}</td>{{/if}} | |
| 467 | + {{if reason[9].checked==true}}<td>{{obj.ywbc}}</td><td>{{obj.ywlc}}</td><td>{{obj.ywbfb}}</td>{{/if}} | |
| 468 | + {{if reason[10].checked==true}}<td>{{obj.qtbc}}</td><td>{{obj.qtlc}}</td><td>{{obj.qtbfb}}</td>{{/if}} | |
| 469 | + </tr> | |
| 470 | + {{/each}} | |
| 471 | + {{if list.length == 0}} | |
| 472 | + <tr> | |
| 473 | + <td colspan="44"><h6 class="muted">没有找到相关数据</h6></td> | |
| 474 | + </tr> | |
| 475 | + {{/if}} | |
| 476 | +</tbody> | |
| 477 | +</script> | |
| 0 | 478 | \ No newline at end of file | ... | ... |
src/main/resources/static/pages/forms/mould/calcLbStatuAnaly.xls
0 → 100644
No preview for this file type