Commit 7a659fa5d188325588d012c90938eaee612fd693

Authored by 娄高锋
1 parent ad153921

修改了一些小问题

src/main/java/com/bsth/controller/forms/ExportController.java
@@ -98,14 +98,14 @@ public class ExportController { @@ -98,14 +98,14 @@ public class ExportController {
98 m.put("lpName", l.getLpName()); 98 m.put("lpName", l.getLpName());
99 m.put("carPlate", l.getCarPlate()); 99 m.put("carPlate", l.getCarPlate());
100 m.put("jhlc", l.getJhlc()); 100 m.put("jhlc", l.getJhlc());
101 - // m.put("sjjhlc", l.getSjjhlc()); 101 + m.put("sjjhlc", l.getSjjhlc());
102 m.put("yygl", l.getYygl()); 102 m.put("yygl", l.getYygl());
103 m.put("emptMileage", l.getEmptMileage()); 103 m.put("emptMileage", l.getEmptMileage());
104 m.put("remMileage", l.getRemMileage()); 104 m.put("remMileage", l.getRemMileage());
105 m.put("addMileage", l.getAddMileage()); 105 m.put("addMileage", l.getAddMileage());
106 m.put("totalm", l.getTotalm()); 106 m.put("totalm", l.getTotalm());
107 m.put("jhbc", l.getJhbc()); 107 m.put("jhbc", l.getJhbc());
108 - // m.put("sjjhbc", l.getSjjhbc()); 108 + m.put("sjjhbc", l.getSjjhbc());
109 m.put("cjbc", l.getCjbc()); 109 m.put("cjbc", l.getCjbc());
110 m.put("ljbc", l.getLjbc()); 110 m.put("ljbc", l.getLjbc());
111 m.put("sjbc", l.getSjbc()); 111 m.put("sjbc", l.getSjbc());
src/main/java/com/bsth/service/forms/impl/FormsServiceImpl.java
@@ -1961,6 +1961,7 @@ public class FormsServiceImpl implements FormsService { @@ -1961,6 +1961,7 @@ public class FormsServiceImpl implements FormsService {
1961 tempMap.put("jhbc", jhbc); 1961 tempMap.put("jhbc", jhbc);
1962 tempMap.put("sjbc", sjbc); 1962 tempMap.put("sjbc", sjbc);
1963 tempMap.put("qz", qz); 1963 tempMap.put("qz", qz);
  1964 + tempMap.put("sm", "");
1964 if(jhcc != 0 && sjcc != 0){ 1965 if(jhcc != 0 && sjcc != 0){
1965 tempMap.put("ccl", numberFormat.format(((float)sjcc / jhcc)*100)+"%"); 1966 tempMap.put("ccl", numberFormat.format(((float)sjcc / jhcc)*100)+"%");
1966 }else{ 1967 }else{
src/main/java/com/bsth/service/impl/BusIntervalServiceImpl.java
@@ -165,9 +165,14 @@ public class BusIntervalServiceImpl implements BusIntervalService { @@ -165,9 +165,14 @@ public class BusIntervalServiceImpl implements BusIntervalService {
165 schedule.setZdsjActual(null); 165 schedule.setZdsjActual(null);
166 } 166 }
167 String[] split1 = schedule.getFcsj().split(":"); 167 String[] split1 = schedule.getFcsj().split(":");
168 - String[] split3 = schedule.getZdsj().split(":");  
169 long fcsj = Long.valueOf(split1[0]) * 60 + Long.valueOf(split1[1]); 168 long fcsj = Long.valueOf(split1[0]) * 60 + Long.valueOf(split1[1]);
170 - long zdsj = Long.valueOf(split3[0]) * 60 + Long.valueOf(split3[1]); 169 + long zdsj = 0l;
  170 + if(schedule.getZdsj() == null){
  171 + zdsj = fcsj + schedule.getBcsj();
  172 + } else {
  173 + String[] split3 = schedule.getZdsj().split(":");
  174 + zdsj = Long.valueOf(split3[0]) * 60 + Long.valueOf(split3[1]);
  175 + }
171 if(!schedule.getScheduleDateStr().equals(schedule.getRealExecDate())){ 176 if(!schedule.getScheduleDateStr().equals(schedule.getRealExecDate())){
172 if(fcsj<23*60) fcsj += 1440l; 177 if(fcsj<23*60) fcsj += 1440l;
173 if(zdsj<23*60) zdsj += 1440l; 178 if(zdsj<23*60) zdsj += 1440l;
@@ -904,7 +909,15 @@ public class BusIntervalServiceImpl implements BusIntervalService { @@ -904,7 +909,15 @@ public class BusIntervalServiceImpl implements BusIntervalService {
904 } 909 }
905 } 910 }
906 911
907 - sql = "select destroy, start_date, end_date, mileage, mileage_type, schedule from bsth_c_s_child_task order by start_date"; 912 + long id1 = 0, id2 = 0;
  913 + for(ScheduleRealInfo s : list){
  914 + if(s.getId() > id2)
  915 + id2 = s.getId();
  916 + if(id1 == 0 || id1 > s.getId())
  917 + id1 = s.getId();
  918 + }
  919 + sql = "select destroy, start_date, end_date, mileage, mileage_type, schedule from bsth_c_s_child_task";
  920 + sql += " where id >= "+id1+" and id <= "+id2+" order by start_date";
908 921
909 cList = jdbcTemplate.query(sql, 922 cList = jdbcTemplate.query(sql,
910 new RowMapper<ChildTaskPlan>(){ 923 new RowMapper<ChildTaskPlan>(){
@@ -2162,9 +2175,9 @@ public class BusIntervalServiceImpl implements BusIntervalService { @@ -2162,9 +2175,9 @@ public class BusIntervalServiceImpl implements BusIntervalService {
2162 // tempMap.put("dxtz", dxtz); 2175 // tempMap.put("dxtz", dxtz);
2163 tempMap.put("lbtz", lbtz); 2176 tempMap.put("lbtz", lbtz);
2164 tempMap.put("correct", sddf + zddf + lbtz); 2177 tempMap.put("correct", sddf + zddf + lbtz);
2165 - tempMap.put("dfbl", sjbc>0?df.format((double)(sddf + zddf)/sjbc*100):0 + "%"); 2178 + tempMap.put("dfbl", (sjbc>0?df.format((double)(sddf + zddf)/sjbc*100):0) + "%");
2166 // tempMap.put("dxbl", df.format((double)(dxtz)/sjbc*100) + "%"); 2179 // tempMap.put("dxbl", df.format((double)(dxtz)/sjbc*100) + "%");
2167 - tempMap.put("lbbl", sjbc>0?df.format((double)(lbtz)/sjbc*100):0 + "%"); 2180 + tempMap.put("lbbl", (sjbc>0?df.format((double)(lbtz)/sjbc*100):0) + "%");
2168 // tempMap.put("correctbl", df.format((double)(sddf + zddf + dxtz + lbtz)/sjbc*100) + "%"); 2181 // tempMap.put("correctbl", df.format((double)(sddf + zddf + dxtz + lbtz)/sjbc*100) + "%");
2169 // tempMap.put("workList", tempList); 2182 // tempMap.put("workList", tempList);
2170 2183
@@ -2294,9 +2307,9 @@ public class BusIntervalServiceImpl implements BusIntervalService { @@ -2294,9 +2307,9 @@ public class BusIntervalServiceImpl implements BusIntervalService {
2294 // tempMap.put("dxtz", dxtz); 2307 // tempMap.put("dxtz", dxtz);
2295 tempMap.put("lbtz", lbtz); 2308 tempMap.put("lbtz", lbtz);
2296 tempMap.put("correct", sddf + zddf + lbtz); 2309 tempMap.put("correct", sddf + zddf + lbtz);
2297 - tempMap.put("dfbl", sjbc>0?df.format((double)(sddf + zddf)/sjbc*100):0 + "%"); 2310 + tempMap.put("dfbl", (sjbc>0?df.format((double)(sddf + zddf)/sjbc*100):0) + "%");
2298 2311
2299 - tempMap.put("lbbl", sjbc>0?df.format((double)(lbtz)/sjbc*100):0 + "%"); 2312 + tempMap.put("lbbl", (sjbc>0?df.format((double)(lbtz)/sjbc*100):0) + "%");
2300 // tempMap.put("correctbl", df.format((double)(sddf + zddf + dxtz + lbtz)/sjbc*100) + "%"); 2313 // tempMap.put("correctbl", df.format((double)(sddf + zddf + dxtz + lbtz)/sjbc*100) + "%");
2301 resList.add(tempMap); 2314 resList.add(tempMap);
2302 } 2315 }
@@ -2319,11 +2332,11 @@ public class BusIntervalServiceImpl implements BusIntervalService { @@ -2319,11 +2332,11 @@ public class BusIntervalServiceImpl implements BusIntervalService {
2319 resMap.put("dxtz", dxtzz); 2332 resMap.put("dxtz", dxtzz);
2320 resMap.put("correct",correct+dxtzz); 2333 resMap.put("correct",correct+dxtzz);
2321 if(sjbc<=0){ 2334 if(sjbc<=0){
2322 - resMap.put("dxbl", "0");  
2323 - resMap.put("correctbl", "0"); 2335 + resMap.put("dxbl", "0%");
  2336 + resMap.put("correctbl", "0%");
2324 }else{ 2337 }else{
2325 - resMap.put("dxbl", sjbc>0?df.format((double)(dxtzz)/sjbc*100):0 + "%");  
2326 - resMap.put("correctbl", sjbc>0?df.format((double)(correct+dxtzz)/sjbc*100):0 + "%"); 2338 + resMap.put("dxbl", (sjbc>0?df.format((double)(dxtzz)/sjbc*100):0) + "%");
  2339 + resMap.put("correctbl", (sjbc>0?df.format((double)(correct+dxtzz)/sjbc*100):0) + "%");
2327 } 2340 }
2328 2341
2329 2342
@@ -2374,11 +2387,11 @@ public class BusIntervalServiceImpl implements BusIntervalService { @@ -2374,11 +2387,11 @@ public class BusIntervalServiceImpl implements BusIntervalService {
2374 resMap.put("dxtz", dxtzf); 2387 resMap.put("dxtz", dxtzf);
2375 resMap.put("correct",correct+dxtzf); 2388 resMap.put("correct",correct+dxtzf);
2376 if(sjbc<=0){ 2389 if(sjbc<=0){
2377 - resMap.put("dxbl", "0");  
2378 - resMap.put("correctbl", "0"); 2390 + resMap.put("dxbl", "0%");
  2391 + resMap.put("correctbl", "0%");
2379 }else{ 2392 }else{
2380 - resMap.put("dxbl", sjbc>0?df.format((double)(dxtzf)/sjbc*100):0 + "%");  
2381 - resMap.put("correctbl", sjbc>0?df.format((double)(correct+dxtzf)/sjbc*100):0 + "%"); 2393 + resMap.put("dxbl", (sjbc>0?df.format((double)(dxtzf)/sjbc*100):0) + "%");
  2394 + resMap.put("correctbl", (sjbc>0?df.format((double)(correct+dxtzf)/sjbc*100):0) + "%");
2382 } 2395 }
2383 resMap.put("xlname",BasicData.lineCode2NameMap.get(xlbm)); 2396 resMap.put("xlname",BasicData.lineCode2NameMap.get(xlbm));
2384 } 2397 }
src/main/resources/static/pages/forms/mould/shifday.xls
No preview for this file type
src/main/resources/static/pages/forms/mould/shiftuehiclemanth.xls
No preview for this file type
src/main/resources/static/pages/forms/mould/shiftuehiclemanthclzbh.xls
No preview for this file type
src/main/resources/static/pages/forms/mould/shiftuehiclemanthspy.xls
No preview for this file type
src/main/resources/static/pages/forms/mould/timeAndSpeed.xls
No preview for this file type
src/main/resources/static/pages/forms/statement/lineTimeAnaly.html
@@ -170,14 +170,6 @@ @@ -170,14 +170,6 @@
170 if (!$('body').hasClass('page-sidebar-closed')) 170 if (!$('body').hasClass('page-sidebar-closed'))
171 $('.menu-toggler.sidebar-toggler').click(); 171 $('.menu-toggler.sidebar-toggler').click();
172 172
173 - $("#startDate").datetimepicker({  
174 - format : 'YYYY-MM-DD',  
175 - locale : 'zh-cn'  
176 - });  
177 - $("#endDate").datetimepicker({  
178 - format : 'YYYY-MM-DD',  
179 - locale : 'zh-cn'  
180 - });  
181 173
182 $("#times1").datetimepicker({ 174 $("#times1").datetimepicker({
183 format : 'HH:mm', 175 format : 'HH:mm',
@@ -189,6 +181,7 @@ @@ -189,6 +181,7 @@
189 }); 181 });
190 182
191 var d = new Date(); 183 var d = new Date();
  184 + d.setTime(d.getTime() - 1*1000*60*60*24);
192 var year = d.getFullYear(); 185 var year = d.getFullYear();
193 var month = d.getMonth() + 1; 186 var month = d.getMonth() + 1;
194 var day = d.getDate(); 187 var day = d.getDate();
@@ -196,8 +189,19 @@ @@ -196,8 +189,19 @@
196 month = "0" + month; 189 month = "0" + month;
197 if(day < 10) 190 if(day < 10)
198 day = "0" + day; 191 day = "0" + day;
199 - $("#startDate").val(year + "-" + month + "-" + day);  
200 - $("#endDate").val(year + "-" + month + "-" + day); 192 + var dateTime = year + "-" + month + "-" + day;
  193 + $("#startDate").datetimepicker({
  194 + format : 'YYYY-MM-DD',
  195 + locale : 'zh-cn',
  196 + maxDate : dateTime
  197 + });
  198 + $("#endDate").datetimepicker({
  199 + format : 'YYYY-MM-DD',
  200 + locale : 'zh-cn',
  201 + maxDate : dateTime
  202 + });
  203 + $("#startDate").val(dateTime);
  204 + $("#endDate").val(dateTime);
201 205
202 $("#times1").val("05:00"); 206 $("#times1").val("05:00");
203 $("#times2").val("23:00"); 207 $("#times2").val("23:00");
@@ -391,7 +395,8 @@ @@ -391,7 +395,8 @@
391 var tbodyHtml = template('list_lineTimeAnaly',{list:result}); 395 var tbodyHtml = template('list_lineTimeAnaly',{list:result});
392 // 把渲染好的模版html文本追加到表格中 396 // 把渲染好的模版html文本追加到表格中
393 $('#forms tbody').html(tbodyHtml); 397 $('#forms tbody').html(tbodyHtml);
394 - 398 + $("#works_hidden").addClass("hidden");
  399 + $("#printArea").addClass("hidden");
395 list = result; 400 list = result;
396 }); 401 });
397 402
@@ -413,6 +418,7 @@ @@ -413,6 +418,7 @@
413 $('#works tbody').html(tbodyHtml); 418 $('#works tbody').html(tbodyHtml);
414 $("#works_hidden").removeClass("hidden"); 419 $("#works_hidden").removeClass("hidden");
415 $("#works .hidden").removeClass("hidden"); 420 $("#works .hidden").removeClass("hidden");
  421 + $("#printArea").removeClass("hidden");
416 $("#date1").html(g.dates); 422 $("#date1").html(g.dates);
417 $("#line1").html(g.line); 423 $("#line1").html(g.line);
418 $("#lp1").html(g.lp); 424 $("#lp1").html(g.lp);
src/main/resources/static/pages/report/countInterval/countInterval.html
@@ -314,7 +314,7 @@ @@ -314,7 +314,7 @@
314 {{/each}} 314 {{/each}}
315 {{if list.length == 0}} 315 {{if list.length == 0}}
316 <tr> 316 <tr>
317 - <td colspan="7"><h6 class="muted">没有找到相关数据</h6></td> 317 + <td colspan="9"><h6 class="muted">没有找到相关数据</h6></td>
318 </tr> 318 </tr>
319 {{/if}} 319 {{/if}}
320 </script> 320 </script>