Commit a539fb6f99ddac81610c5b38c34b58f438517441

Authored by 廖磊
1 parent a18cd454

烂班班次 临加子任务公里 油量表页面

src/main/java/com/bsth/controller/report/ReportController.java
@@ -82,7 +82,8 @@ public class ReportController { @@ -82,7 +82,8 @@ public class ReportController {
82 @RequestMapping(value="/queryStrinon" ,method = RequestMethod.GET) 82 @RequestMapping(value="/queryStrinon" ,method = RequestMethod.GET)
83 public List<StationRoute> queryStrinon(@RequestParam String line, 83 public List<StationRoute> queryStrinon(@RequestParam String line,
84 @RequestParam int zd){ 84 @RequestParam int zd){
85 - return service.queryStrinon(line,zd); 85 + List<StationRoute> list=service.queryStrinon(line,zd);
  86 + return list;
86 } 87 }
87 //根据排班查到离站 88 //根据排班查到离站
88 @RequestMapping(value="/queryInOutStrtion" ,method = RequestMethod.GET) 89 @RequestMapping(value="/queryInOutStrtion" ,method = RequestMethod.GET)
src/main/java/com/bsth/service/report/impl/CulateMileageServiceImpl.java
@@ -71,29 +71,59 @@ public class CulateMileageServiceImpl implements CulateMileageService{ @@ -71,29 +71,59 @@ public class CulateMileageServiceImpl implements CulateMileageService{
71 71
72 } else { 72 } else {
73 Iterator<ChildTaskPlan> it = childTaskPlans.iterator(); 73 Iterator<ChildTaskPlan> it = childTaskPlans.iterator();
74 - while (it.hasNext()) {  
75 - ChildTaskPlan childTaskPlan = it.next();  
76 - if (childTaskPlan.isDestroy()) {  
77 - String destroyReason = "";  
78 - if (childTaskPlan.getDestroyReason() == "" || childTaskPlan.getDestroyReason() == null) {  
79 - destroyReason = "其他";  
80 - } else {  
81 - destroyReason = childTaskPlan.getDestroyReason(); 74 + if (scheduleRealInfo.getStatus() == -1) {
  75 + double zlblc=0.0;
  76 + while (it.hasNext()) {
  77 + ChildTaskPlan childTaskPlan = it.next();
  78 + if(childTaskPlan.getMileageType().equals("service")){
  79 + if (childTaskPlan.isDestroy()) {
  80 + zlblc=Arith.add(zlblc,childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage());
  81 + }
  82 + }
  83 + }
  84 + Map<String, Object> newMap = new HashMap<String, Object>();
  85 + String adjustExps = "";
  86 + if (scheduleRealInfo.getAdjustExps() == "" || scheduleRealInfo.getAdjustExps() == null) {
  87 + adjustExps = "其他";
  88 + } else {
  89 + adjustExps = scheduleRealInfo.getAdjustExps();
  90 + }
  91 + newMap.put("nr", adjustExps);
  92 + newMap.put("lp", scheduleRealInfo.getLpName());
  93 + newMap.put("nbbm", scheduleRealInfo.getClZbh());
  94 + newMap.put("jgh", scheduleRealInfo.getjGh());
  95 + newMap.put("dz", scheduleRealInfo.getQdzName());
  96 + newMap.put("sj", scheduleRealInfo.getFcsj());
  97 + newMap.put("lbbc", 1);
  98 + newMap.put("lblc", zlblc);
  99 + newMap.put("jyqp", scheduleRealInfo.getRealMileage());
  100 + list.add(newMap);
  101 + }else{
  102 + while (it.hasNext()) {
  103 + ChildTaskPlan childTaskPlan = it.next();
  104 + if (childTaskPlan.isDestroy()) {
  105 + String destroyReason = "";
  106 + if (childTaskPlan.getDestroyReason() == "" || childTaskPlan.getDestroyReason() == null) {
  107 + destroyReason = "其他";
  108 + } else {
  109 + destroyReason = childTaskPlan.getDestroyReason();
  110 + }
  111 + Map<String, Object> newMap = new HashMap<String, Object>();
  112 + newMap.put("nr", destroyReason);
  113 + newMap.put("lp", scheduleRealInfo.getLpName());
  114 + newMap.put("nbbm", scheduleRealInfo.getClZbh());
  115 + newMap.put("jgh", scheduleRealInfo.getjGh());
  116 + newMap.put("dz", childTaskPlan.getStartStationName());
  117 + newMap.put("sj", childTaskPlan.getStartDate());
  118 + newMap.put("lbbc", 0);
  119 + newMap.put("lblc", childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage());
  120 + newMap.put("jyqp", scheduleRealInfo.getRealMileage());
  121 + list.add(newMap);
82 } 122 }
83 - Map<String, Object> newMap = new HashMap<String, Object>();  
84 - newMap.put("nr", destroyReason);  
85 - newMap.put("lp", scheduleRealInfo.getLpName());  
86 - newMap.put("nbbm", scheduleRealInfo.getClZbh());  
87 - newMap.put("jgh", scheduleRealInfo.getjGh());  
88 - newMap.put("dz", childTaskPlan.getStartStationName());  
89 - newMap.put("sj", childTaskPlan.getStartDate());  
90 - newMap.put("lbbc", 0);  
91 - newMap.put("lblc", childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage());  
92 - newMap.put("jyqp", scheduleRealInfo.getRealMileage());  
93 - list.add(newMap);  
94 -  
95 } 123 }
96 } 124 }
  125 +
  126 +
97 } 127 }
98 } 128 }
99 } 129 }
@@ -168,12 +198,12 @@ public class CulateMileageServiceImpl implements CulateMileageService{ @@ -168,12 +198,12 @@ public class CulateMileageServiceImpl implements CulateMileageService{
168 for (int i = 0; i < lists.size(); i++) { 198 for (int i = 0; i < lists.size(); i++) {
169 ScheduleRealInfo scheduleRealInfo=lists.get(i); 199 ScheduleRealInfo scheduleRealInfo=lists.get(i);
170 if (!isInOut(scheduleRealInfo)) { 200 if (!isInOut(scheduleRealInfo)) {
171 - Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks();  
172 - if(childTaskPlans.isEmpty()){ 201 +// Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks();
  202 +// if(childTaskPlans.isEmpty()){
173 if(scheduleRealInfo.getStatus() == -1){ 203 if(scheduleRealInfo.getStatus() == -1){
174 lbbc++; 204 lbbc++;
175 } 205 }
176 - } 206 +// }
177 /*else{ 207 /*else{
178 if(scheduleRealInfo.getStatus() == -1){ 208 if(scheduleRealInfo.getStatus() == -1){
179 boolean fage=true; 209 boolean fage=true;
@@ -263,6 +293,17 @@ public class CulateMileageServiceImpl implements CulateMileageService{ @@ -263,6 +293,17 @@ public class CulateMileageServiceImpl implements CulateMileageService{
263 if(zjlc>0){ 293 if(zjlc>0){
264 ljgl=Arith.add(zjlc, ljgl); 294 ljgl=Arith.add(zjlc, ljgl);
265 } 295 }
  296 + }else{
  297 + Iterator<ChildTaskPlan> it = childTaskPlans.iterator();
  298 + while (it.hasNext()) {
  299 + ChildTaskPlan childTaskPlan = it.next();
  300 + if("service".equals(childTaskPlan.getMileageType())&&"临加".equals(childTaskPlan.getType1())){
  301 + if (!childTaskPlan.isDestroy()) {
  302 + Float jhgl=childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage();
  303 + ljgl=Arith.add(ljgl,jhgl);
  304 + }
  305 + }
  306 + }
266 } 307 }
267 } 308 }
268 } 309 }
@@ -380,7 +421,7 @@ public class CulateMileageServiceImpl implements CulateMileageService{ @@ -380,7 +421,7 @@ public class CulateMileageServiceImpl implements CulateMileageService{
380 Iterator<ChildTaskPlan> it = childTaskPlans.iterator(); 421 Iterator<ChildTaskPlan> it = childTaskPlans.iterator();
381 while (it.hasNext()) { 422 while (it.hasNext()) {
382 ChildTaskPlan childTaskPlan = it.next(); 423 ChildTaskPlan childTaskPlan = it.next();
383 - if(childTaskPlan.getMileageType().equals("service")){ 424 + if(childTaskPlan.getMileageType().equals("service")&&"正常".equals(childTaskPlan.getType1())){
384 if (!childTaskPlan.isDestroy()) { 425 if (!childTaskPlan.isDestroy()) {
385 Float jhgl=childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage(); 426 Float jhgl=childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage();
386 sjgl=Arith.add(sjgl,jhgl); 427 sjgl=Arith.add(sjgl,jhgl);
src/main/java/com/bsth/service/report/impl/ReportServiceImpl.java
@@ -1727,14 +1727,41 @@ public class ReportServiceImpl implements ReportService{ @@ -1727,14 +1727,41 @@ public class ReportServiceImpl implements ReportService{
1727 1727
1728 } else { 1728 } else {
1729 Iterator<ChildTaskPlan> it = childTaskPlans.iterator(); 1729 Iterator<ChildTaskPlan> it = childTaskPlans.iterator();
1730 - /*if (scheduleRealInfo.getStatus() == -1) { 1730 + if (scheduleRealInfo.getStatus() == -1) {
  1731 + double zlblc=0.0;
  1732 + while (it.hasNext()) {
  1733 + ChildTaskPlan childTaskPlan = it.next();
  1734 + if(childTaskPlan.getMileageType().equals("service")){
  1735 + if (childTaskPlan.isDestroy()) {
  1736 + zlblc=Arith.add(zlblc,childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage());
  1737 + }
  1738 + }
  1739 + }
  1740 + Map<String, Object> newMap = new HashMap<String, Object>();
  1741 + String adjustExps = "";
  1742 + if (scheduleRealInfo.getAdjustExps() == "" || scheduleRealInfo.getAdjustExps() == null) {
  1743 + adjustExps = "其他";
  1744 + } else {
  1745 + adjustExps = scheduleRealInfo.getAdjustExps();
  1746 + }
  1747 + newMap.put("nr", adjustExps);
  1748 + newMap.put("lp", scheduleRealInfo.getLpName());
  1749 + newMap.put("nbbm", scheduleRealInfo.getClZbh());
  1750 + newMap.put("jgh", scheduleRealInfo.getjGh());
  1751 + newMap.put("dz", scheduleRealInfo.getQdzName());
  1752 + newMap.put("sj", scheduleRealInfo.getFcsj());
  1753 + newMap.put("lbbc", 1);
  1754 + newMap.put("lblc", zlblc);
  1755 + newMap.put("jyqp", scheduleRealInfo.getRealMileage());
  1756 + list.add(newMap);
  1757 + } else {
1731 while (it.hasNext()) { 1758 while (it.hasNext()) {
1732 ChildTaskPlan childTaskPlan = it.next(); 1759 ChildTaskPlan childTaskPlan = it.next();
1733 if (childTaskPlan.isDestroy()) { 1760 if (childTaskPlan.isDestroy()) {
1734 String destroyReason = ""; 1761 String destroyReason = "";
1735 - if ( childTaskPlan.getDestroyReason() == null) { 1762 + if (childTaskPlan.getDestroyReason() == null) {
1736 destroyReason = "其他"; 1763 destroyReason = "其他";
1737 - }else if(childTaskPlan.getDestroyReason().equals("")){ 1764 + } else if (childTaskPlan.getDestroyReason().equals("")) {
1738 destroyReason = "其他"; 1765 destroyReason = "其他";
1739 } else { 1766 } else {
1740 destroyReason = childTaskPlan.getDestroyReason(); 1767 destroyReason = childTaskPlan.getDestroyReason();
@@ -1747,41 +1774,14 @@ public class ReportServiceImpl implements ReportService{ @@ -1747,41 +1774,14 @@ public class ReportServiceImpl implements ReportService{
1747 newMap.put("dz", childTaskPlan.getStartStationName()); 1774 newMap.put("dz", childTaskPlan.getStartStationName());
1748 newMap.put("sj", childTaskPlan.getStartDate()); 1775 newMap.put("sj", childTaskPlan.getStartDate());
1749 newMap.put("gzf", " "); 1776 newMap.put("gzf", " ");
1750 - newMap.put("lbbc", 1); 1777 + newMap.put("lbbc", 0);
1751 newMap.put("lblc", childTaskPlan.getMileage()); 1778 newMap.put("lblc", childTaskPlan.getMileage());
1752 newMap.put("jyqp", childTaskPlan.getRemarks()); 1779 newMap.put("jyqp", childTaskPlan.getRemarks());
1753 list.add(newMap); 1780 list.add(newMap);
1754 1781
1755 } 1782 }
1756 } 1783 }
1757 - }else{*/  
1758 - while (it.hasNext()) {  
1759 - ChildTaskPlan childTaskPlan = it.next();  
1760 - if (childTaskPlan.isDestroy()) {  
1761 - String destroyReason = "";  
1762 - if ( childTaskPlan.getDestroyReason() == null) {  
1763 - destroyReason = "其他";  
1764 - }else if(childTaskPlan.getDestroyReason().equals("")){  
1765 - destroyReason = "其他";  
1766 - } else {  
1767 - destroyReason = childTaskPlan.getDestroyReason();  
1768 - }  
1769 - Map<String, Object> newMap = new HashMap<String, Object>();  
1770 - newMap.put("nr", destroyReason);  
1771 - newMap.put("lp", scheduleRealInfo.getLpName());  
1772 - newMap.put("nbbm", scheduleRealInfo.getClZbh());  
1773 - newMap.put("jgh", scheduleRealInfo.getjGh());  
1774 - newMap.put("dz", childTaskPlan.getStartStationName());  
1775 - newMap.put("sj", childTaskPlan.getStartDate());  
1776 - newMap.put("gzf", " ");  
1777 - newMap.put("lbbc", 0);  
1778 - newMap.put("lblc", childTaskPlan.getMileage());  
1779 - newMap.put("jyqp", childTaskPlan.getRemarks());  
1780 - list.add(newMap);  
1781 -  
1782 - }  
1783 } 1784 }
1784 -// }  
1785 1785
1786 } 1786 }
1787 } 1787 }
@@ -2051,12 +2051,13 @@ public class ReportServiceImpl implements ReportService{ @@ -2051,12 +2051,13 @@ public class ReportServiceImpl implements ReportService{
2051 String d1=date+" "+minfcsj+":01"; 2051 String d1=date+" "+minfcsj+":01";
2052 // Date dates2=simpleDateFormat.parse(date+" 23:59:59"); 2052 // Date dates2=simpleDateFormat.parse(date+" 23:59:59");
2053 date1=dates1.getTime(); 2053 date1=dates1.getTime();
2054 -// date2=dates2.getTime(); 2054 +
2055 cal.setTime(dates1); 2055 cal.setTime(dates1);
2056 int weeks_year1 = cal.get(Calendar.WEEK_OF_YEAR); 2056 int weeks_year1 = cal.get(Calendar.WEEK_OF_YEAR);
2057 cal.add(cal.DATE,1);//把日期往后增加一天.整数往后推,负数往前移动 2057 cal.add(cal.DATE,1);//把日期往后增加一天.整数往后推,负数往前移动
2058 int weeks_year2 = cal.get(Calendar.WEEK_OF_YEAR); 2058 int weeks_year2 = cal.get(Calendar.WEEK_OF_YEAR);
2059 Date dates2=cal.getTime(); 2059 Date dates2=cal.getTime();
  2060 + date2=dates2.getTime();
2060 String d2=simpleDateFormat.format(dates2); 2061 String d2=simpleDateFormat.format(dates2);
2061 /*String sql="select *,UNIX_TIMESTAMP(times) as ts from bsth_c_arrival_info where times >= '"+d1 +"'and " 2062 /*String sql="select *,UNIX_TIMESTAMP(times) as ts from bsth_c_arrival_info where times >= '"+d1 +"'and "
2062 + " times <='"+d2+"' and line_id = '"+line+"' and up_down = '"+zd+"'" 2063 + " times <='"+d2+"' and line_id = '"+line+"' and up_down = '"+zd+"'"
src/main/resources/static/index.html
@@ -74,6 +74,7 @@ @@ -74,6 +74,7 @@
74 <!-- schedule计划调度AngularJS模块主css --> 74 <!-- schedule计划调度AngularJS模块主css -->
75 <link rel="stylesheet" href="/pages/scheduleApp/module/common/main.css" 75 <link rel="stylesheet" href="/pages/scheduleApp/module/common/main.css"
76 type="text/css" /> 76 type="text/css" />
  77 + <link rel="stylesheet" href="/real_control_v2/assets/plugins/perfect-scrollbar/perfect-scrollbar.css" merge="plugins"/>
77 78
78 <!-- CSS动画 --> 79 <!-- CSS动画 -->
79 <link 80 <link
@@ -629,5 +630,8 @@ tr.row-active td { @@ -629,5 +630,8 @@ tr.row-active td {
629 <script 630 <script
630 src="http://webapi.amap.com/maps?v=1.3&key=16cb1c5043847e09ef9edafdd77befda" 631 src="http://webapi.amap.com/maps?v=1.3&key=16cb1c5043847e09ef9edafdd77befda"
631 data-exclude=1></script> 632 data-exclude=1></script>
  633 +
  634 + <script src="/real_control_v2/assets/plugins/perfect-scrollbar/perfect-scrollbar.jquery.js" merge="plugins"></script>
  635 +
632 </body> 636 </body>
633 </html> 637 </html>
634 \ No newline at end of file 638 \ No newline at end of file
src/main/resources/static/pages/oil/list_ph.html
  1 +<style type="text/css">
  2 + #ylbtable table>tr> td {
  3 + white-space: nowrap;
  4 + overflow: hidden;
  5 + text-overflow: ellipsis;
  6 + }
  7 +
  8 + #ylbtable .ps-scrollbar-y{
  9 + min-height:100px;
  10 + }
  11 +</style>
1 <div class="page-head"> 12 <div class="page-head">
2 <div class="page-title"> 13 <div class="page-title">
3 <h1>进出场存油量</h1> 14 <h1>进出场存油量</h1>
@@ -9,244 +20,258 @@ @@ -9,244 +20,258 @@
9 <li><span class="active">用油管理</span> <i class="fa fa-circle"></i></li> 20 <li><span class="active">用油管理</span> <i class="fa fa-circle"></i></li>
10 <li><span class="active">进出场存油量</span></li> 21 <li><span class="active">进出场存油量</span></li>
11 </ul> 22 </ul>
  23 +<div id="ll_oil_list"
  24 + class=" row col-md-12 portlet light porttlet-fit portlet-datatable bordered" style="height: calc(100% - 100px);background-color: #fff">
  25 + <!-- Begin: life time stats -->
  26 + <div class="portlet-title" >
  27 + <div class="caption">
  28 + <i class="fa fa-fire-extinguisher"></i> <span
  29 + class="caption-subject font-dark sbold uppercase">进出场存油量表</span>
  30 + </div>
  31 + <div class="actions">
  32 + <a class="btn btn-circle blue" href="add.html" data-pjax><i
  33 + class="fa fa-plus"></i> 添加</a>
  34 + <button type="button" class="btn btn-circle blue" id="removeButton">
  35 + <i class="fa fa-trash-o"></i> 删除
  36 + </button>
  37 + <button type="button" class="btn btn-circle blue" id="sortButton">
  38 + <i class="fa fa-minus-square"></i> 拆分
  39 + </button>
  40 + <button type="button" class="btn btn-circle blue" id="saveButton">
  41 + <i class="fa fa-check-circle"></i> 保存
  42 + </button>
  43 + <!-- <button type="button" class="btn btn-circle red" disabled="disabled" id="removeButton"><i class="fa fa-trash"></i> 删除用户</button> -->
  44 + <div class="btn-group">
  45 + <a class="btn red btn-outline btn-circle" href="javascript:;"
  46 + data-toggle="dropdown"> <i class="fa fa-share"></i> <span
  47 + class="hidden-xs"> 系统工具 </span> <i class="fa fa-angle-down"></i>
  48 + </a>
  49 + <ul class="dropdown-menu pull-right" id="datatable_ajax_tools">
  50 + <li><a href="javascript:;" data-action="0" class="tool-action"
  51 + id="obtain"> <i class="fa fa-hourglass-half"></i> 获取加/存油信息
  52 + </a></li>
  53 + <li><a href="javascript:;" data-action="1" class="tool-action"
  54 + id="outAndIn"> <i class="fa fa-pencil"></i> 油耗计算(进场=出场)
  55 + </a></li>
  56 + <li><a href="javascript:;" id="checkYl" data-action="3"
  57 + class="tool-action"> <i class="fa fa-gg-circle"></i>
  58 + 核对加注量(有加油无里程)
  59 + </a></li>
  60 + <li class="divider"></li>
  61 + <li><a href="javascript:;" data-action="3" class="tool-action"
  62 + id="export"> <i class="fa fa-file-excel-o"></i> 导出Excel
  63 + </a></li>
  64 + </ul>
  65 + </div>
  66 + </div>
  67 + <div>
  68 + <table
  69 + class="table table-striped table-bordered table-hover table-checkable"
  70 + id="datatable_ylb" style="table-layout: fixed;margin-bottom: 0px">
  71 + <thead>
  72 + <tr role="row" class="filter">
  73 + <td colspan="2">
  74 + <div style="float: right;">&nbsp;公司&nbsp;</div>
  75 + </td>
  76 + <td colspan="3">
  77 + <div style="float: left; width: 150px">
  78 + <select class="form-control" name="ssgsdm_like"
  79 + id="ylbListGsdmId"></select>
  80 + </div>
  81 + </td>
  82 + <td colspan="2">
  83 + <div style="float: right;">&nbsp;分公司&nbsp;</div>
  84 + </td>
  85 + <td colspan="4">
  86 + <div style="float: left;">
  87 + <select class="form-control" name="fgsdm_like"
  88 + id="ylbListFgsdmId" style="width: 150px"></select>
  89 + </div>
  90 + </td>
  91 + <td>
  92 + <div style="float: right;">日期</div>
  93 + </td>
  94 + <td colspan="3">
  95 + <div style="float: left;">
  96 + <input type="text" style="width: 120px" name="rq" id="rq" />
  97 + </div>
  98 + </td>
  99 + <td rowspan="2" colspan="2">
  100 + <div style="float: left;">
  101 + &nbsp;
  102 + <button
  103 + class="btn btn-sm green btn-outline filter-submit margin-bottom"
  104 + style="margin-right: 0px">
  105 + <i class="fa fa-search"></i> 搜索
  106 + </button>
  107 + <!-- <button class="btn btn-sm red btn-outline filter-cancel" style="margin-right:0px"> -->
  108 + <!-- <i class="fa fa-times"></i> 重置 -->
  109 + <!-- </button> -->
12 110
13 -<div class="row" id="ll_oil_list">  
14 - <div class="col-md-12">  
15 - <!-- Begin: life time stats -->  
16 - <div class="portlet light portlet-fit portlet-datatable bordered">  
17 - <div class="portlet-title">  
18 - <div class="caption">  
19 - <i class="fa fa-fire-extinguisher"></i> <span  
20 - class="caption-subject font-dark sbold uppercase">进出场存油量表</span>  
21 - </div>  
22 - <div class="actions">  
23 - <a class="btn btn-circle blue" href="add.html" data-pjax><i class="fa fa-plus"></i> 添加</a>  
24 - <button type="button" class="btn btn-circle blue" id="removeButton"><i class="fa fa-trash-o"></i> 删除</button>  
25 - <button type="button" class="btn btn-circle blue" id="sortButton"><i class="fa fa-minus-square"></i>  
26 - 拆分  
27 - </button>  
28 - <button type="button" class="btn btn-circle blue" id="saveButton"><i class="fa fa-check-circle"></i>  
29 - 保存  
30 - </button>  
31 - <!-- <button type="button" class="btn btn-circle red" disabled="disabled" id="removeButton"><i class="fa fa-trash"></i> 删除用户</button> -->  
32 - <div class="btn-group">  
33 - <a class="btn red btn-outline btn-circle" href="javascript:;"  
34 - data-toggle="dropdown"> <i class="fa fa-share"></i> <span  
35 - class="hidden-xs"> 系统工具 </span> <i class="fa fa-angle-down"></i>  
36 - </a>  
37 - <ul class="dropdown-menu pull-right" id="datatable_ajax_tools">  
38 - <li><a href="javascript:;" data-action="0"  
39 - class="tool-action" id="obtain"> <i class="fa fa-hourglass-half"></i> 获取加/存油信息  
40 - </a></li>  
41 - <li><a href="javascript:;" data-action="1"  
42 - class="tool-action" id="outAndIn"> <i class="fa fa-pencil"></i> 油耗计算(进场=出场)  
43 - </a></li>  
44 - <li><a href="javascript:;" id="checkYl" data-action="3"  
45 - class="tool-action"> <i class="fa fa-gg-circle"></i>  
46 - 核对加注量(有加油无里程)  
47 - </a></li>  
48 - <li class="divider"></li>  
49 - <li><a href="javascript:;" data-action="3"  
50 - class="tool-action" id="export"> <i class="fa fa-file-excel-o"></i>  
51 - 导出Excel  
52 - </a></li>  
53 - </ul>  
54 - </div>  
55 - </div>  
56 - </div>  
57 - <div class="portlet-body">  
58 - <div class="table-container" style="margin-top: 10px">  
59 - <table  
60 - class="table table-striped table-bordered table-hover table-checkable"  
61 - id="datatable_ylb">  
62 - <thead >  
63 - <tr role="row" class="filter">  
64 - <td colspan="2">  
65 - <div style="float: right; " >&nbsp;公司&nbsp;</div>  
66 - </td>  
67 - <td colspan="3">  
68 - <div style="float: left;width: 150px">  
69 - <select class="form-control" name="ssgsdm_like"  
70 - id="ylbListGsdmId"></select>  
71 - </div>  
72 - </td>  
73 - <td colspan="2">  
74 - <div style="float: right; " >&nbsp;分公司&nbsp;</div>  
75 - </td>  
76 - <td colspan="4">  
77 - <div style="float: left;">  
78 - <select class="form-control" name="fgsdm_like"  
79 - id="ylbListFgsdmId" style="width: 150px"></select>  
80 - </div>  
81 - </td>  
82 - <td >  
83 - <div style="float: right; ">日期</div>  
84 - </td>  
85 - <td colspan="3">  
86 - <div style="float: left;">  
87 - <input type="text" style="width: 120px" name="rq" id="rq" />  
88 - </div>  
89 - </td>  
90 - <td rowspan="2" colspan="2">  
91 - <div style="float: left;">  
92 - &nbsp;<button  
93 - class="btn btn-sm green btn-outline filter-submit margin-bottom"  
94 - style="margin-right: 0px">  
95 - <i class="fa fa-search"></i> 搜索  
96 - </button> <!-- <button class="btn btn-sm red btn-outline filter-cancel" style="margin-right:0px"> -->  
97 - <!-- <i class="fa fa-times"></i> 重置 -->  
98 - <!-- </button> --> 111 + </div>
  112 + </td>
  113 + </tr>
  114 + <tr class="filter2">
  115 + <td colspan="2">
  116 + <div style="float: right;">&nbsp;线路</div>
  117 + </td>
  118 + <td colspan="3">
  119 + <div style="float: left;">
  120 + <select class="form-control" name="xlbm_like" id="xlbm"
  121 + style="width: 150px;"></select>
  122 + </div>
  123 + </td>
  124 + <td colspan="2">
  125 + <div style="float: right;">&nbsp;内部编码</div>
  126 + </td>
  127 + <td colspan="4">
  128 + <div style="float: left;">
  129 + <select class="form-control" name="nbbm_eq" id="nbbm"
  130 + style="width: 120px;"></select>
  131 + </div>
  132 + <div style="float: left;">
  133 + <button class="btn btn-sm #000 btn-outline filter-cancel"
  134 + style="margin-right: 0px">
  135 + <i class="fa fa-times"></i>
  136 + </button>
  137 + </div>
  138 + </td>
  139 + <td>
  140 + <div style="float: right;">类型</div>
  141 + </td>
  142 + <td colspan="3">
  143 + <div style="float: left;">
  144 + <select class="form-control" name="sxtj">
  145 + <option value="0">全部</option>
  146 + <option value="1">一车一单</option>
  147 + <option value="2">一车多单</option>
  148 + <option value="3">有加油没里程</option>
  149 + <option value="4">有里程没加油</option>
  150 + </select>
  151 + </div>
99 152
100 - </div>  
101 - </td>  
102 - </tr>  
103 - <tr class="filter2">  
104 - <td colspan="2">  
105 - <div style="float: right; ">&nbsp;线路</div>  
106 - </td>  
107 - <td colspan="3">  
108 - <div style="float: left;">  
109 - <select class="form-control" name="xlbm_like" id="xlbm"  
110 - style="width: 150px;"></select>  
111 - </div>  
112 - </td>  
113 - <td colspan="2">  
114 - <div style="float: right;">&nbsp;内部编码</div>  
115 - </td>  
116 - <td colspan="4">  
117 - <div style="float: left;">  
118 - <select class="form-control" name="nbbm_eq" id="nbbm"  
119 - style="width: 120px;"></select>  
120 - </div>  
121 - <div style="float: left;">  
122 - <button class="btn btn-sm #000 btn-outline filter-cancel"  
123 - style="margin-right: 0px">  
124 - <i class="fa fa-times"></i>  
125 - </button>  
126 - </div>  
127 - </td>  
128 - <td >  
129 - <div style="float: right;">  
130 - 类型  
131 - </div>  
132 - </td>  
133 - <td colspan="3">  
134 - <div style="float: left;">  
135 - <select class="form-control" name="sxtj">  
136 - <option value="0">全部</option>  
137 - <option value="1">一车一单</option>  
138 - <option value="2">一车多单</option>  
139 - <option value="3">有加油没里程</option>  
140 - <option value="4">有里程没加油</option>  
141 - </select>  
142 - </div>  
143 -  
144 - </td>  
145 - </tr>  
146 - <tr>  
147 - <td colspan="17">  
148 - <div style="float: left;">  
149 - 总计  
150 - &nbsp;&nbsp;  
151 - 加注量:&nbsp;<label id="sumJzl"></label>  
152 - &nbsp;&nbsp;  
153 - 耗油量:&nbsp;<label id="sumYh"></label>  
154 - &nbsp;&nbsp;  
155 - 损耗量:&nbsp;<label id="sumSh"></label>  
156 - </div>  
157 - </td>  
158 - </tr>  
159 - <tr role="row" class="heading">  
160 - <th width="2%">#</th>  
161 - <th width="8%">日期</th>  
162 - <th width="5%">公司</th>  
163 - <th width="8%">线路</th>  
164 - <th width="5%">自编号</th>  
165 - <th width="6%">驾驶员</th>  
166 - <th width="4%">加油量</th>  
167 - <th width="4%">出场存油</th>  
168 - <th width="4%">进场存油</th>  
169 - <th width="5%">油耗</th>  
170 - <th width="5%">燃油类型</th>  
171 - <th width="4%">尿素</th>  
172 - <th width="5%">耗损原因</th>  
173 - <th width="5%">耗损油量</th>  
174 - <th width="5%">当日总里程</th>  
175 - <th width="5%">数据类型</th>  
176 - <th width="5%">百公里油耗</th>  
177 -<!-- <th width="5%">操作</th> -->  
178 - </tr>  
179 - </thead>  
180 - <tbody></tbody>  
181 - </table>  
182 - <div style="text-align: right;">  
183 - <ul id="pagination" class="pagination"></ul>  
184 - </div>  
185 - </div>  
186 - </div>  
187 - </div>  
188 - </div>  
189 -</div> 153 + </td>
  154 + </tr>
  155 + <tr>
  156 + <td colspan="17">
  157 + <div style="float: left;">
  158 + 总计 &nbsp;&nbsp; 加注量:&nbsp;<label id="sumJzl"></label>
  159 + &nbsp;&nbsp; 耗油量:&nbsp;<label id="sumYh"></label> &nbsp;&nbsp;
  160 + 损耗量:&nbsp;<label id="sumSh"></label>
  161 + </div>
  162 + </td>
  163 + </tr>
  164 +
  165 + </thead>
190 166
  167 + </table>
  168 + </div>
  169 + </div>
  170 +
  171 + <div id="ylbtable" class="portlet-body table-container " style="height: calc(100% - 200px);overflow: hidden;position: absolute;background: #fff;">
  172 +
  173 + <table
  174 + class="table table-striped table-bordered table-hover table-checkable"
  175 + style="table-layout: fixed;margin-bottom: 0px;">
  176 + <thead>
  177 + <tr role="row" class="heading">
  178 + <td width="40px">
  179 + <input type="checkbox" id="selectAll" class="group-checkable icheck" >
  180 + </td>
  181 + <td width="40px">序号</td>
  182 + <td width="8%">日期</td>
  183 + <td width="5%">公司</td>
  184 + <td width="8%">线路</td>
  185 + <td width="5%">自编号</td>
  186 + <td width="7%">驾驶员</td>
  187 + <td width="4%">加油量</td>
  188 + <td width="5%">出场存油</td>
  189 + <td width="5%">进场存油</td>
  190 + <td width="5%">油耗</td>
  191 + <td width="8%">燃油类型</td>
  192 + <td width="4%">尿素</td>
  193 + <td width="8%">耗损原因</td>
  194 + <td width="5%">耗损油量</td>
  195 + <td width="5%">当日总里程</td>
  196 + <td width="5%">数据类型</td>
  197 + <td >百公里油耗</td>
  198 + </tr>
  199 + </thead>
  200 + </table>
  201 + <div id="datatable_ylb_body_div" style="display: block;position:absolute;overflow: auto;height: calc(100% - 80px);">
  202 + <table
  203 + class="table table-striped table-bordered table-hover table-checkable"
  204 + id="datatable_ylb_body"
  205 + style="table-layout: fixed; overflow: auto; height: calc(100% - 80px);">
  206 + <tbody></tbody>
  207 + </table>
  208 + </div>
  209 +
  210 +
  211 + <div style="text-align: right;">
  212 + <ul id="pagination" class="pagination"></ul>
  213 + </div>
  214 + </div>
  215 +</div>
191 <script id="ylb_list_temp" type="text/html"> 216 <script id="ylb_list_temp" type="text/html">
192 {{each list as obj i}} 217 {{each list as obj i}}
193 <tr> 218 <tr>
194 - <td style="vertical-align: middle;"> 219 + <td style="vertical-align: middle;" width="40px">
195 <input type="checkbox" name="id" class="group-checkable icheck" data-id="{{obj.id}}"> 220 <input type="checkbox" name="id" class="group-checkable icheck" data-id="{{obj.id}}">
196 </td> 221 </td>
197 -  
198 - <td> 222 + <td width="40px">{{i+1}}</td>
  223 + <td width="8%">
199 {{obj.rq}} 224 {{obj.rq}}
200 </td> 225 </td>
201 - <td> 226 + <td width="5%">
202 {{obj.fgsname}} 227 {{obj.fgsname}}
203 </td> 228 </td>
204 - <td> 229 + <td width="8%">
205 {{obj.xlname}} 230 {{obj.xlname}}
206 </td> 231 </td>
207 - <td> 232 + <td width="5%">
208 <lable data-id="{{obj.id}}" class="in_carpark_nbbm">{{obj.nbbm}}</lable> 233 <lable data-id="{{obj.id}}" class="in_carpark_nbbm">{{obj.nbbm}}</lable>
209 234
210 </td> 235 </td>
211 - <td> 236 + <td width="7%">
212 {{obj.jsy}}/{{obj.name}} 237 {{obj.jsy}}/{{obj.name}}
213 </td> 238 </td>
214 - <td> 239 + <td width="4%">
215 240
216 - <lable data-id="{{obj.id}}" class="in_carpark_jzl"> {{obj.jzl}}</lable> 241 + <lable data-id="{{obj.id}}" class="in_carpark_jzl"> {{obj.jzl}}</lable>
217 </td> 242 </td>
218 - <td> 243 + <td width="5%">
219 244
220 - <input data-id="{{obj.id}}" href="javascript:;" class="in_carpark_czyl"  
221 - type="text" value=" {{obj.czyl}}" style=" width:45px" 245 + <input data-id="{{obj.id}}" id="{{(i+1)}}_1" href="javascript:;" class="in_carpark_czyl yl_sxzy"
  246 + type="text" value=" {{obj.czyl}}" style=" width:100%"
222 onkeyup="this.value=this.value.replace(/[^(\d||/.)]/g,'').replace('.','$#$').replace(/\./g,'').replace('$#$','.')" 247 onkeyup="this.value=this.value.replace(/[^(\d||/.)]/g,'').replace('.','$#$').replace(/\./g,'').replace('$#$','.')"
223 onafterpaste="this.value=this.value.replace(/[^(\d||/.)]/g,'').replace('.','$#$').replace(/\./g,'').replace('$#$','.')"> 248 onafterpaste="this.value=this.value.replace(/[^(\d||/.)]/g,'').replace('.','$#$').replace(/\./g,'').replace('$#$','.')">
224 </td> 249 </td>
225 - <td>  
226 - <input data-id="{{obj.id}}" href="javascript:;" class="in_carpark_jzyl"  
227 - type="text" value=" {{obj.jzyl}}" style=" width:45px" 250 + <td width="5%">
  251 + <input data-id="{{obj.id}}" id="{{(i+1)}}_2" href="javascript:;" class="in_carpark_jzyl yl_sxzy"
  252 + type="text" value=" {{obj.jzyl}}" style=" width:100%"
228 onkeyup="this.value=this.value.replace(/[^(\d||/.)]/g,'').replace('.','$#$').replace(/\./g,'').replace('$#$','.')" 253 onkeyup="this.value=this.value.replace(/[^(\d||/.)]/g,'').replace('.','$#$').replace(/\./g,'').replace('$#$','.')"
229 onafterpaste="this.value=this.value.replace(/[^(\d||/.)]/g,'').replace('.','$#$').replace(/\./g,'').replace('$#$','.')"> 254 onafterpaste="this.value=this.value.replace(/[^(\d||/.)]/g,'').replace('.','$#$').replace(/\./g,'').replace('$#$','.')">
230 </td> 255 </td>
231 - <td> 256 + <td width="5%">
232 257
233 - <input data-id="{{obj.id}}" href="javascript:;" class="in_carpark_yh"  
234 - type="text" value="{{obj.yh}}" style=" width:50px" disabled="true" readOnly="true" /> 258 + <input data-id="{{obj.id}}" id="{{(i+1)}}_3" href="javascript:;" class="in_carpark_yh yl_sxzy"
  259 + type="text" value="{{obj.yh}}" style=" width:100%"  readOnly="true" />
235 </td> 260 </td>
236 - <td>  
237 - <select data-id="{{obj.id}}" class="in_carpark_rylx" style=" width:80px" > 261 + <td width="8%">
  262 + <select data-id="{{obj.id}}" class="in_carpark_rylx" style=" width:100%" >
238 <option value='0' {{if obj.rylx==0}} selected = 'selected' {{/if}}>0号柴油</option> 263 <option value='0' {{if obj.rylx==0}} selected = 'selected' {{/if}}>0号柴油</option>
239 <option value='1' {{if obj.rylx==1}} selected = 'selected' {{/if}}>负10号柴油</option> 264 <option value='1' {{if obj.rylx==1}} selected = 'selected' {{/if}}>负10号柴油</option>
240 </select> 265 </select>
241 </td> 266 </td>
242 - <td> 267 + <td width="4%">
243 <input data-id="{{obj.id}}" href="javascript:;" 268 <input data-id="{{obj.id}}" href="javascript:;"
244 - class="in_carpark_ns" type="text" value=" {{obj.ns}}" style=" width:40px" 269 + class="in_carpark_ns yl_sxzy" id="{{(i+1)}}_4" type="text" value=" {{obj.ns}}" style=" width:100%"
245 onkeyup="this.value=this.value.replace(/[^(\d||/.)]/g,'').replace('.','$#$').replace(/\./g,'').replace('$#$','.')" 270 onkeyup="this.value=this.value.replace(/[^(\d||/.)]/g,'').replace('.','$#$').replace(/\./g,'').replace('$#$','.')"
246 onafterpaste="this.value=this.value.replace(/[^(\d||/.)]/g,'').replace('.','$#$').replace(/\./g,'').replace('$#$','.')"> 271 onafterpaste="this.value=this.value.replace(/[^(\d||/.)]/g,'').replace('.','$#$').replace(/\./g,'').replace('$#$','.')">
247 </td> 272 </td>
248 - <td>  
249 - <select data-id="{{obj.id}}" class="in_carpark_shyy" style=" width:80px"> 273 + <td width="8%">
  274 + <select data-id="{{obj.id}}" class="in_carpark_shyy" style=" width:100%" >
250 <option value='0' {{if obj.shyy==0}} selected = 'selected' {{/if}}>请选择</option> 275 <option value='0' {{if obj.shyy==0}} selected = 'selected' {{/if}}>请选择</option>
251 <option value='1' {{if obj.shyy==1}} selected = 'selected' {{/if}}>票务用油</option> 276 <option value='1' {{if obj.shyy==1}} selected = 'selected' {{/if}}>票务用油</option>
252 <option value='2' {{if obj.shyy==2}} selected = 'selected' {{/if}}>保养用油</option> 277 <option value='2' {{if obj.shyy==2}} selected = 'selected' {{/if}}>保养用油</option>
@@ -258,23 +283,23 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep @@ -258,23 +283,23 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep
258 <option value='8' {{if obj.shyy==8}} selected = 'selected' {{/if}}>车间(小修)</option> 283 <option value='8' {{if obj.shyy==8}} selected = 'selected' {{/if}}>车间(小修)</option>
259 </select> 284 </select>
260 </td> 285 </td>
261 - <td>  
262 - <input data-id="{{obj.id}}" href="javascript:;" class="in_carpark_shyl"  
263 - value={{obj.sh}} style=" width:40px" type="text" 286 + <td width="5%">
  287 + <input data-id="{{obj.id}}" id="{{(i+1)}}_5" href="javascript:;" class="in_carpark_shyl yl_sxzy"
  288 + value={{obj.sh}} style=" width:100%" type="text"
264 onkeyup="this.value=this.value.replace(/[^(\d||/.)]/g,'').replace('.','$#$').replace(/\./g,'').replace('$#$','.')" 289 onkeyup="this.value=this.value.replace(/[^(\d||/.)]/g,'').replace('.','$#$').replace(/\./g,'').replace('$#$','.')"
265 onafterpaste="this.value=this.value.replace(/[^(\d||/.)]/g,'').replace('.','$#$').replace(/\./g,'').replace('$#$','.')" /> 290 onafterpaste="this.value=this.value.replace(/[^(\d||/.)]/g,'').replace('.','$#$').replace(/\./g,'').replace('$#$','.')" />
266 291
267 </td> 292 </td>
268 - <td> 293 + <td width="5%">
269 {{obj.zlc}} 294 {{obj.zlc}}
270 </td> 295 </td>
271 - <td> 296 + <td width="5%">
272 <select data-id="{{obj.id}}" class="in_carpark_yhlx"> 297 <select data-id="{{obj.id}}" class="in_carpark_yhlx">
273 <option value='0' {{if obj.yhlx==0}} selected = 'selected' {{/if}}>手录</option> 298 <option value='0' {{if obj.yhlx==0}} selected = 'selected' {{/if}}>手录</option>
274 <option value='1' {{if obj.yhlx==1}} selected = 'selected' {{/if}}>拆分</option> 299 <option value='1' {{if obj.yhlx==1}} selected = 'selected' {{/if}}>拆分</option>
275 </select> 300 </select>
276 </td> 301 </td>
277 - <td> 302 + <td >
278 {{obj.bglyh}} 303 {{obj.bglyh}}
279 </td> 304 </td>
280 </tr> 305 </tr>
@@ -293,7 +318,7 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep @@ -293,7 +318,7 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep
293 //$('.in_carpark_jzyl[data-id='+id+']', '#ll_oil_list') 318 //$('.in_carpark_jzyl[data-id='+id+']', '#ll_oil_list')
294 319
295 $("#checkYl").on('click', function () { 320 $("#checkYl").on('click', function () {
296 - console.log("核对加注量"); 321 + //console.log("核对加注量");
297 if ($("#rq").val() != "") { 322 if ($("#rq").val() != "") {
298 var params=getParamsList(); 323 var params=getParamsList();
299 var i = layer.load(2); 324 var i = layer.load(2);
@@ -308,7 +333,7 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep @@ -308,7 +333,7 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep
308 333
309 //进场等于出场 334 //进场等于出场
310 $("#outAndIn").on('click', function () { 335 $("#outAndIn").on('click', function () {
311 - console.log("进场油量等于出场油量"); 336 + // console.log("进场油量等于出场油量");
312 if ($("#rq").val() != "") { 337 if ($("#rq").val() != "") {
313 var params=getParamsList(); 338 var params=getParamsList();
314 var i = layer.load(2); 339 var i = layer.load(2);
@@ -380,6 +405,112 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep @@ -380,6 +405,112 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep
380 //拆分 405 //拆分
381 $("#sortButton").on('click', function () { 406 $("#sortButton").on('click', function () {
382 if ($("#rq").val() != "") { 407 if ($("#rq").val() != "") {
  408 + //拆分前先保存全部
  409 + var ylArray = [];
  410 + $('input.icheck').each(function(){
  411 + var map = {};
  412 + var id=$(this).data('id');
  413 + var nbbm =$('.in_carpark_nbbm[data-id='+id+']', '#ll_oil_list').html();
  414 + var jzl =$('.in_carpark_jzl[data-id='+id+']', '#ll_oil_list').html();
  415 + if(jzl=="" || jzl ==null){
  416 + jzl=0;
  417 + }
  418 + var czyl=$('.in_carpark_czyl[data-id='+id+']', '#ll_oil_list').val();
  419 + if(czyl=="" || czyl==null){
  420 + czyl=0;
  421 + }
  422 + var jzyl=$('.in_carpark_jzyl[data-id='+id+']', '#ll_oil_list').val();
  423 + if(jzyl=="" || jzyl==null){
  424 + jzyl=0;
  425 + }
  426 +
  427 + var sh = $('.in_carpark_shyl[data-id='+id+']', '#ll_oil_list').val();
  428 + if(sh=="" || sh==null){
  429 + sh=0;
  430 + }
  431 +
  432 + var shyy = $('.in_carpark_shyy[data-id='+id+']', '#ll_oil_list').val();
  433 + var ns = $('.in_carpark_ns[data-id='+id+']', '#ll_oil_list').val();
  434 + if(ns=="" || ns==null){
  435 + ns=0;
  436 + }
  437 +
  438 + var rylx= $('.in_carpark_rylx[data-id='+id+']', '#ll_oil_list').val();
  439 + var yhlx = $('.in_carpark_yhlx[data-id='+id+']', '#ll_oil_list').val();
  440 +
  441 + map['id']=id;
  442 + map['jzl']=jzl;
  443 + map['czyl']=czyl;
  444 + map['jzyl']=jzyl;
  445 + map['sh']=sh;
  446 + map['shyy']=shyy;
  447 + map['ns']=ns;
  448 + map['rylx']=rylx;
  449 + map['yhlx']=yhlx;
  450 + map['nbbm']=nbbm;
  451 + map['rq']=$("#rq").val();
  452 + ylArray.push(map);
  453 + })
  454 + var params = {};
  455 + params['ylbList']=JSON.stringify(ylArray);
  456 +
  457 +
  458 + //拆分操作
  459 + var ylArray2 = [];
  460 + var nbbm="";
  461 + var msg="";
  462 + $('input.icheck:checked').each(function(){
  463 + var map = {};
  464 + var id=$(this).data('id');
  465 + var clzbh =$('.in_carpark_nbbm[data-id='+id+']', '#ll_oil_list').html();
  466 + if(nbbm.indexOf(clzbh)>-1){
  467 + if(msg==""){
  468 + msg += clzbh;
  469 + }else{
  470 + msg += ","+clzbh;
  471 + }
  472 + }else{
  473 + nbbm +=clzbh;
  474 + var jzyl=$('.in_carpark_jzyl[data-id='+id+']', '#ll_oil_list').val();
  475 + var sh = $('.in_carpark_shyl[data-id='+id+']', '#ll_oil_list').val();
  476 + var shyy = $('.in_carpark_shyy[data-id='+id+']', '#ll_oil_list').val();
  477 + var ns = $('.in_carpark_ns[data-id='+id+']', '#ll_oil_list').val();
  478 + var rylx= $('.in_carpark_rylx[data-id='+id+']', '#ll_oil_list').val();
  479 + map['id']=id;
  480 + map['jzyl']=jzyl;
  481 + map['sh']=sh;
  482 + map['shyy']=shyy;
  483 + map['ns']=ns;
  484 + map['rylx']=rylx;
  485 + ylArray2.push(map);
  486 + }
  487 +
  488 + }) ;
  489 + if(msg!=""){
  490 + layer.msg('内部编码为:【'+msg +'】的车辆请选择一条数据进行拆分.');
  491 + }else{
  492 + var params2 = {};
  493 + params2['ylbList']=JSON.stringify(ylArray2);
  494 + var i = layer.load(2);
  495 + //保存操作
  496 + $post('/ylb/saveYlbList', params, function () {
  497 + //拆分操作
  498 + $post('/ylb/sort', params2, function () {
  499 + layer.close(i);
  500 + var params1 =getParamsList();
  501 + jsDoQuery(params1, true);
  502 + });
  503 + });
  504 + }
  505 +
  506 + } else {
  507 + layer.msg('请选择日期.');
  508 + }
  509 + })
  510 +
  511 + /* //拆分
  512 + $("#sortButton").on('click', function () {
  513 + if ($("#rq").val() != "") {
383 var ylArray = []; 514 var ylArray = [];
384 var nbbm=""; 515 var nbbm="";
385 var msg=""; 516 var msg="";
@@ -424,36 +555,13 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep @@ -424,36 +555,13 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep
424 555
425 } 556 }
426 557
427 - /* var id = $('input.icheck:checked').data('id');  
428 -  
429 - if (typeof(id) == 'undefined') {  
430 - layer.msg("请选择一行进行拆分");  
431 - } else {  
432 - //获取输入的进场存油  
433 - var jzyl = $('.in_carpark_jzyl[data-id='+id+']', '#ll_oil_list').html();  
434 - var sh = $('.in_carpark_shyl[data-id='+id+']', '#ll_oil_list').html();  
435 - var shyy = $('.in_carpark_shyy[data-id='+id+']', '#ll_oil_list').val();  
436 - // $("#jzyl" + id).html();  
437 - var params = {};  
438 - params['jzyl'] = jzyl;  
439 - params['sh'] =sh;  
440 - params['shyy']=shyy;  
441 - params['id'] = id;  
442 - var i = layer.load(2);  
443 - $get('/ylb/sort', params, function () {  
444 - layer.close(i);  
445 - var params1 =getParamsList();  
446 - jsDoQuery(params1, true);  
447 - });  
448 -  
449 - } */  
450 } else { 558 } else {
451 layer.msg('请选择日期.'); 559 layer.msg('请选择日期.');
452 } 560 }
453 - }) 561 + }) */
454 //获取加存信息 562 //获取加存信息
455 $("#obtain").on('click', function () { 563 $("#obtain").on('click', function () {
456 - console.log("获取加存"); 564 + //console.log("获取加存");
457 if ($("#rq").val() != "") { 565 if ($("#rq").val() != "") {
458 var params =getParamsList(); 566 var params =getParamsList();
459 567
@@ -493,8 +601,6 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep @@ -493,8 +601,6 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep
493 layer.msg('请选择公司和分公司.'); 601 layer.msg('请选择公司和分公司.');
494 }else { 602 }else {
495 var params = getParamsList(); 603 var params = getParamsList();
496 -  
497 -  
498 page = 0; 604 page = 0;
499 jsDoQuery(params, true); 605 jsDoQuery(params, true);
500 } 606 }
@@ -526,8 +632,6 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep @@ -526,8 +632,6 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep
526 return params; 632 return params;
527 } 633 }
528 634
529 -// var gsqxdm="";  
530 -  
531 var xlList; 635 var xlList;
532 var obj=[]; 636 var obj=[];
533 $.get('/report/lineList',function(result){ 637 $.get('/report/lineList',function(result){
@@ -535,32 +639,17 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep @@ -535,32 +639,17 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep
535 $.get('/user/companyData', function(result){ 639 $.get('/user/companyData', function(result){
536 obj = result; 640 obj = result;
537 var options=""; 641 var options="";
538 - // = '<option value="">请选择</option>';  
539 for(var i = 0; i < obj.length; i++){ 642 for(var i = 0; i < obj.length; i++){
540 options += '<option value="'+obj[i].companyCode+'">'+obj[i].companyName+'</option>'; 643 options += '<option value="'+obj[i].companyCode+'">'+obj[i].companyName+'</option>';
541 - // setFgsqx(obj[i].companyCode);  
542 } 644 }
543 $('#ylbListGsdmId').html(options); 645 $('#ylbListGsdmId').html(options);
544 updateCompany(); 646 updateCompany();
545 }); 647 });
546 }) 648 })
547 - /* function setFgsqx(gs){  
548 - var company =gs  
549 - var options = '';  
550 - for(var i = 0; i < obj.length; i++){  
551 - if(obj[i].companyCode == company){  
552 - var children = obj[i].children;  
553 - for(var j = 0; j < children.length; j++){  
554 - gsqxdm +=company+""+children[j].code+",";  
555 - }  
556 - }  
557 - }  
558 - } */  
559 $("#ylbListGsdmId").on("change",updateCompany); 649 $("#ylbListGsdmId").on("change",updateCompany);
560 function updateCompany(){ 650 function updateCompany(){
561 var company = $('#ylbListGsdmId').val(); 651 var company = $('#ylbListGsdmId').val();
562 var options =""; 652 var options ="";
563 -// = '<option value="">请选择</option>';  
564 for(var i = 0; i < obj.length; i++){ 653 for(var i = 0; i < obj.length; i++){
565 if(obj[i].companyCode == company){ 654 if(obj[i].companyCode == company){
566 var children = obj[i].children; 655 var children = obj[i].children;
@@ -576,6 +665,7 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep @@ -576,6 +665,7 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep
576 /* 665 /*
577 * 获取数据 p: 要提交的参数, pagination: 是否重新分页 666 * 获取数据 p: 要提交的参数, pagination: 是否重新分页
578 */ 667 */
  668 + var moveArray=new Array(); //存放文本框数组
579 function jsDoQuery(p, pagination) { 669 function jsDoQuery(p, pagination) {
580 var params = {}; 670 var params = {};
581 if (p) 671 if (p)
@@ -584,50 +674,29 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep @@ -584,50 +674,29 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep
584 params['order'] = 'nbbm'; 674 params['order'] = 'nbbm';
585 params['page'] = page; 675 params['page'] = page;
586 params['rq'] = $("#rq").val(); 676 params['rq'] = $("#rq").val();
587 -  
588 - /* var ylbGsdm=$("#ylbListGsdmId").val();  
589 - var ylbFgsdm=$("#ylbListFgsdmId").val();  
590 - if(ylbGsdm==''|| ylbGsdm==null){  
591 - params['concat(ssgsdm,fgsdm)_in']=gsqxdm;  
592 - }else{  
593 - if(ylbFgsdm==''||ylbFgsdm==null){  
594 - var fgsqx1='';  
595 - for(var i = 0; i < obj.length; i++){  
596 - if(obj[i].companyCode == ylbGsdm){  
597 - var children = obj[i].children;  
598 - for(var j = 0; j < children.length; j++){  
599 - fgsqx1 +=children[j].code+",";  
600 - }  
601 - }  
602 - }  
603 - params['fgsdm_in']=fgsqx1;  
604 - }  
605 - } */  
606 - 677 +
607 var l = layer.load(2); 678 var l = layer.load(2);
608 $get('/ylb/ylbList', params, function (data) { 679 $get('/ylb/ylbList', params, function (data) {
609 - 680 +
  681 + for(var i=1;i<data.length;i++){
  682 + moveArray[i]=new Array();
  683 + for(var j=1;j<6;j++){
  684 + moveArray[i][j]=i+"_"+j;
  685 + }
  686 + }
610 $.each(data, function (i, obj) { 687 $.each(data, function (i, obj) {
611 obj.rq = moment(obj.rq).format("YYYY-MM-DD"); 688 obj.rq = moment(obj.rq).format("YYYY-MM-DD");
612 }); 689 });
613 var bodyHtm = template('ylb_list_temp', {list:data}); 690 var bodyHtm = template('ylb_list_temp', {list:data});
614 - $('#datatable_ylb tbody').html(bodyHtm);  
615 - /* $('#datatable_ylb tbody').html(bodyHtm)  
616 - .find('.icheck').iCheck(icheckOptions)  
617 - .on('ifChanged', iCheckChange);  
618 - if (pagination && data.content.length > 0) {  
619 - //重新分页  
620 - initPagination = true;  
621 - showPagination(data);  
622 - } */ 691 +
  692 + $('#datatable_ylb_body tbody').html(bodyHtm);
  693 + $('.yl_sxzy').on('mouseup', yhSxzy);
623 layer.close(l); 694 layer.close(l);
624 $get('/ylb/sumYlb',params,function(returns){ 695 $get('/ylb/sumYlb',params,function(returns){
625 $("#sumJzl").html(returns.jzl); 696 $("#sumJzl").html(returns.jzl);
626 $("#sumYh").html(returns.yh); 697 $("#sumYh").html(returns.yh);
627 $("#sumSh").html(returns.sh); 698 $("#sumSh").html(returns.sh);
628 }); 699 });
629 -// startOptJzylLink($('#ll_oil_list .in_carpark_jzyl'));  
630 -// startOptShylLink($('#ll_oil_list .in_carpark_shyl'));  
631 $('input').on('input propertychange',function(){ 700 $('input').on('input propertychange',function(){
632 var id=$(this).data('id'); 701 var id=$(this).data('id');
633 var jzl =$('.in_carpark_jzl[data-id='+id+']', '#ll_oil_list').html(); 702 var jzl =$('.in_carpark_jzl[data-id='+id+']', '#ll_oil_list').html();
@@ -754,11 +823,6 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep @@ -754,11 +823,6 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep
754 tr.addClass('row-active'); 823 tr.addClass('row-active');
755 else 824 else
756 tr.removeClass('row-active'); 825 tr.removeClass('row-active');
757 -  
758 - /* if($('#datatable_resource input.icheck:checked').length == 1)  
759 - $('#removeButton').removeAttr('disabled');  
760 - else  
761 - $('#removeButton').attr('disabled', 'disabled'); */  
762 } 826 }
763 827
764 function showPagination(data) { 828 function showPagination(data) {
@@ -785,7 +849,6 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep @@ -785,7 +849,6 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep
785 }); 849 });
786 } 850 }
787 851
788 -  
789 //删除 852 //删除
790 $('#removeButton').on('click', function () { 853 $('#removeButton').on('click', function () {
791 var idArray = []; 854 var idArray = [];
@@ -814,18 +877,6 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep @@ -814,18 +877,6 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep
814 } 877 }
815 } 878 }
816 }); 879 });
817 -  
818 - //搜索线路  
819 - /* $.get('/basic/lineCode2Name',function(result){  
820 - var data=[];  
821 - data.push({id: " ", text: "全部线路"});  
822 - for(var code in result){  
823 - data.push({id: code, text: result[code]});  
824 - }  
825 - initPinYinSelect2('#xlbm',data,'');  
826 -  
827 - }) */  
828 -  
829 880
830 $("#ylbListFgsdmId").on("change",initXl); 881 $("#ylbListFgsdmId").on("change",initXl);
831 function initXl(){ 882 function initXl(){
@@ -852,13 +903,6 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep @@ -852,13 +903,6 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep
852 initPinYinSelect2('#xlbm',data,''); 903 initPinYinSelect2('#xlbm',data,'');
853 fage=true; 904 fage=true;
854 } 905 }
855 -// $("#ylbListGsdmId").on("change",initNbbm);  
856 -// $("#ylbListFgsdmId").on("change",initNbbm);  
857 -// $("#xlbm").on("change",initNbbm);  
858 -// function initNbbm(){  
859 -// var gsbm=$('#ylbListGsdmId').val(),  
860 -// var fgsbm=$('#ylbListFgsdmId').val(),  
861 -// var xlbm=$('#xlbm').val();  
862 906
863 $("#xlbm").on("change",initCl); 907 $("#xlbm").on("change",initCl);
864 function initCl(){ 908 function initCl(){
@@ -910,7 +954,6 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep @@ -910,7 +954,6 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep
910 } 954 }
911 // } 955 // }
912 956
913 -  
914 //导出 957 //导出
915 958
916 $("#export").on("click", function () { 959 $("#export").on("click", function () {
@@ -923,6 +966,103 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep @@ -923,6 +966,103 @@ onkeyup=&quot;this.value=this.value.replace(/[^(\d||/.)]/g,&#39;&#39;).replace(&#39;.&#39;,&#39;$#$&#39;).rep
923 layer.msg('请选择日期.'); 966 layer.msg('请选择日期.');
924 } 967 }
925 }); 968 });
  969 +
  970 + //表格滚动条
  971 + var modal='#ylbtable';
  972 + $('#datatable_ylb_body_div', modal).perfectScrollbar({suppressScrollX: true});
  973 +
  974 + //全选 全不选
  975 + $("#selectAll").on("click", function () {
  976 + if ($(this).is(":checked")) {
  977 + $("[name=id]:checkbox").prop("checked", true);
  978 + } else {
  979 + $("[name=id]:checkbox").prop("checked", false);
  980 + }
  981 + });
  982 +
  983 +
  984 + //键盘上下左右移动
  985 + var mouseInfo={}; //存放鼠标的当前位置
  986 + function yhSxzy(){
  987 + tdid=$(this).attr('id');
  988 + var rc=tdid.split("_");
  989 + mouseInfo["row"]=rc[0];
  990 + mouseInfo["col"]=rc[1];
  991 + }
  992 +
  993 + document.body.onkeydown=function(e){ //监听鼠标操作
  994 + e=window.event||e;
  995 + switch(e.keyCode){
  996 + case 37: //左键
  997 + moveLeft();
  998 + break;
  999 + case 38: //向上键
  1000 + moveUp();
  1001 + break;
  1002 + case 39: //右键
  1003 + moveRight();
  1004 + break;
  1005 + case 40: //向下键
  1006 + moveDown();
  1007 + break;
  1008 + default:
  1009 + break;
  1010 + }
  1011 + }
  1012 +
  1013 + function moveLeft(){
  1014 + var row=mouseInfo["row"];
  1015 + var col=mouseInfo["col"];
  1016 +
  1017 + var key=moveArray[row][col-1];
  1018 + if(document.getElementById(key)!=undefined)
  1019 + {
  1020 + var textFiled=document.getElementById(key);
  1021 + textFiled.focus(false, 1000);
  1022 + textFiled.select();
  1023 + mouseInfo["col"]=parseInt(col)-1;
  1024 + }
  1025 +
  1026 + }
  1027 + function moveRight(){
  1028 + var row=mouseInfo["row"];
  1029 + var col=mouseInfo["col"];
  1030 +
  1031 + var key=moveArray[row][parseInt(col)+1];
  1032 + if(document.getElementById(key)!=undefined)
  1033 + {
  1034 + var textFiled=document.getElementById(key);
  1035 + textFiled.focus(false, 1000);
  1036 + textFiled.select();
  1037 + mouseInfo["col"]=parseInt(col)+1;
  1038 + }
  1039 + }
  1040 + function moveUp(){
  1041 + var row=mouseInfo["row"];
  1042 + var col=mouseInfo["col"];
  1043 +
  1044 + var key=moveArray[parseInt(row)-1][col];
  1045 + if(document.getElementById(key)!=undefined)
  1046 + {
  1047 + var textFiled=document.getElementById(key);
  1048 + textFiled.focus(false, 1000);
  1049 + textFiled.select();
  1050 + mouseInfo["row"]=parseInt(row)-1;
  1051 + }
  1052 + }
  1053 + function moveDown(){
  1054 + var row=mouseInfo["row"];
  1055 + var col=mouseInfo["col"];
  1056 +
  1057 + var key=moveArray[parseInt(row)+1][col];
  1058 + if(document.getElementById(key)!=undefined)
  1059 + {
  1060 + var textFiled=document.getElementById(key);
  1061 + textFiled.focus(false, 1000);
  1062 + textFiled.select();
  1063 + mouseInfo["row"]=parseInt(row)+1;
  1064 + }
  1065 + }
926 1066
927 }); 1067 });
928 -</script>  
929 \ No newline at end of file 1068 \ No newline at end of file
  1069 +</script>
src/main/resources/static/pages/report/inoutstation/inoutstation.html
@@ -113,78 +113,6 @@ @@ -113,78 +113,6 @@
113 initPinYinSelect2('#line',data,''); 113 initPinYinSelect2('#line',data,'');
114 114
115 }) 115 })
116 - /* var fage=false;  
117 - var obj = [];  
118 - var xlList;  
119 - $.get('/report/lineList',function(result){  
120 - xlList=result;  
121 -  
122 - $.get('/user/companyData', function(result){  
123 - obj = result;  
124 - console.log(obj);  
125 - var options = '';  
126 - for(var i = 0; i < obj.length; i++){  
127 - options += '<option value="'+obj[i].companyCode+'">'+obj[i].companyName+'</option>';  
128 - }  
129 -  
130 - if(obj.length ==0){  
131 - $("#gsdmDiv").css('display','none');  
132 - }else if(obj.length ==1){  
133 - $("#gsdmDiv").css('display','none');  
134 - if(obj[0].children.length == 1 || obj[0].children.length ==0)  
135 - $('#fgsdmDiv').css('display','none');  
136 - }  
137 - $('#gsdm').html(options);  
138 -  
139 - updateCompany();  
140 - });  
141 - });  
142 -  
143 - $("#gsdm").on("change",updateCompany);  
144 - function updateCompany(){  
145 - var company = $('#gsdm').val();  
146 - var options = '';  
147 - for(var i = 0; i < obj.length; i++){  
148 - if(obj[i].companyCode == company){  
149 - var children = obj[i].children;  
150 - for(var j = 0; j < children.length; j++){  
151 - options += '<option value="'+children[j].code+'">'+children[j].name+'</option>';  
152 - }  
153 - }  
154 - }  
155 - $('#fgsdm').html(options);  
156 - initXl();  
157 - initCl();  
158 - }  
159 -  
160 -  
161 -  
162 -  
163 - $("#fgsdm").on("change",initXl);  
164 - function initXl(){  
165 - var data=[];  
166 - if(fage){  
167 - $("#line").select2("destroy").html('');  
168 - }  
169 - var fgs=$('#fgsdm').val();  
170 - var gs=$('#gsdm').val();  
171 - for(var i=0;i<xlList.length;i++){  
172 - if(gs!=""){  
173 - if(fgs!=""){  
174 - if(xlList[i]["fgsbm"]==fgs && xlList[i]["gsbm"]==gs){  
175 - data.push({id: xlList[i]["xlbm"], text: xlList[i]["xlname"]});  
176 - }  
177 - }else{  
178 - if(xlList[i]["gsbm"]==gs){  
179 - data.push({id: xlList[i]["xlbm"], text: xlList[i]["xlname"]});  
180 - }  
181 - }  
182 - }  
183 - }  
184 - initPinYinSelect2('#line',data,'');  
185 - fage=true;  
186 - }  
187 - */  
188 116
189 $("#query").on("click",function(){ 117 $("#query").on("click",function(){
190 var line = $("#line").val(); 118 var line = $("#line").val();
@@ -198,12 +126,13 @@ @@ -198,12 +126,13 @@
198 }else if(zdlx=="" || zdlx==null){ 126 }else if(zdlx=="" || zdlx==null){
199 layer.msg("请选择方向"); 127 layer.msg("请选择方向");
200 }else{ 128 }else{
201 - $get('/report/queryStrinon',{line:line,zd:zdlx},function(result){  
202 - $get('/report/queryInOutStrtion',{line:line,date:date,zd:zdlx,lzsj:lzsj},function(result2){ 129 + $get('/report/queryStrinon',{line:line,zd:zdlx},function(result){
  130 + console.log(result);
  131 + $get('/report/queryInOutStrtions',{line:line,date:date,zd:zdlx,lzsj:lzsj},function(result2){
203 console.log(result2); 132 console.log(result2);
204 - /* getTime(result); */  
205 - var ludan_ll_1 = template('ludan_ll_1',{list:result2,lists:result});  
206 - // 把渲染好的模版html文本追加到表格中 133 +// /* getTime(result); */
  134 + var ludan_ll_1 = template('ludan_ll_1',{lists:result,list:result2});
  135 +// // 把渲染好的模版html文本追加到表格中
207 $('#forms .ludan_ll_1').html(ludan_ll_1); 136 $('#forms .ludan_ll_1').html(ludan_ll_1);
208 }); 137 });
209 }); 138 });
@@ -263,30 +192,28 @@ @@ -263,30 +192,28 @@
263 </script> 192 </script>
264 <script type="text/html" id="ludan_ll_1"> 193 <script type="text/html" id="ludan_ll_1">
265 {{each list as obj i}} 194 {{each list as obj i}}
266 -  
267 <tr> 195 <tr>
268 <td>{{obj.bc}}</td> 196 <td>{{obj.bc}}</td>
269 <td><label>{{obj.nbbm}}</label></td> 197 <td><label>{{obj.nbbm}}</label></td>
270 - {{each lists as o j}}  
271 - {{if i==0}}  
272 - <td>  
273 - <label>{{obj[(o.stationCode)+'in']}}  
274 - ({{obj[(o.stationCode)+'out']}})  
275 - </label>  
276 - </td>  
277 - {{else}}  
278 - <td {{if obj[o.stationCode] =='y'}}style="color: red"{{/if}}>  
279 - {{if obj[(o.stationCode)+'in']!=''}}  
280 - <label> I {{obj[(o.stationCode)+'in']}}</label> 198 + {{each lists as o j}}
  199 + {{if i==0}}
  200 + <td>
  201 + <label>{{obj[(o.stationCode)+'in']}}
  202 + ({{obj[(o.stationCode)+'out']}})
  203 + </label>
  204 + </td>
  205 + {{else}}
  206 + <td {{if obj[o.stationCode] =='y'}}style="color: red"{{/if}}>
  207 + {{if obj[(o.stationCode)+'in']!=''}}
  208 + <label> I {{obj[(o.stationCode)+'in']}}</label>
281 {{/if}} 209 {{/if}}
282 <br/> 210 <br/>
283 {{if obj[(o.stationCode)+'out']!=''}} 211 {{if obj[(o.stationCode)+'out']!=''}}
284 - <label> O {{obj[(o.stationCode)+'out']}}</label> 212 + <label> O{{obj[(o.stationCode)+'out']}}</label>
285 {{/if}} 213 {{/if}}
286 </td> 214 </td>
287 {{/if}} 215 {{/if}}
288 {{/each}} 216 {{/each}}
289 -  
290 </tr> 217 </tr>
291 {{/each}} 218 {{/each}}
292 {{if list.length == 0}} 219 {{if list.length == 0}}