Commit b4c9153cd550eaafc6fa245255d0a60f01fc4559

Authored by 潘钊
2 parents 1e66396e 1c4d5623

Merge branch 'minhang' of http://222.66.0.204:8090/panzhaov5/bsth_control into minhang

src/main/java/com/bsth/entity/schedule/CarConfigInfo.java
@@ -58,6 +58,26 @@ public class CarConfigInfo extends BEntity implements Serializable { @@ -58,6 +58,26 @@ public class CarConfigInfo extends BEntity implements Serializable {
58 @Column(nullable = false) 58 @Column(nullable = false)
59 private Boolean isCancel = false; 59 private Boolean isCancel = false;
60 60
  61 + //-------------- 车辆配置的停车场及相关信息 ------------//
  62 + /** 车辆配置-CheLiangPeiZhi 字典,ZW(早晚),FS(复驶),BSY(不使用) */
  63 + private String pzType;
  64 + /** 上行出场里程 */
  65 + private Double upOutLc;
  66 + /** 上行出场时间 */
  67 + private Double upOutSj;
  68 + /** 下行出场里程 */
  69 + private Double downOutLc;
  70 + /** 下行出场时间 */
  71 + private Double downOutSj;
  72 + /** 上行进场里程 */
  73 + private Double upInLc;
  74 + /** 上行进场时间 */
  75 + private Double upInSj;
  76 + /** 下行进场里程 */
  77 + private Double downInLc;
  78 + /** 下行进场时间 */
  79 + private Double downInSj;
  80 +
61 public CarConfigInfo() {} 81 public CarConfigInfo() {}
62 public CarConfigInfo(Object id, Object xlid, Object xlname, Object clid) { 82 public CarConfigInfo(Object id, Object xlid, Object xlname, Object clid) {
63 if (id != null) { 83 if (id != null) {
@@ -156,4 +176,76 @@ public class CarConfigInfo extends BEntity implements Serializable { @@ -156,4 +176,76 @@ public class CarConfigInfo extends BEntity implements Serializable {
156 public void setIsCancel(Boolean isCancel) { 176 public void setIsCancel(Boolean isCancel) {
157 this.isCancel = isCancel; 177 this.isCancel = isCancel;
158 } 178 }
  179 +
  180 + public String getPzType() {
  181 + return pzType;
  182 + }
  183 +
  184 + public void setPzType(String pzType) {
  185 + this.pzType = pzType;
  186 + }
  187 +
  188 + public Double getUpOutLc() {
  189 + return upOutLc;
  190 + }
  191 +
  192 + public void setUpOutLc(Double upOutLc) {
  193 + this.upOutLc = upOutLc;
  194 + }
  195 +
  196 + public Double getUpOutSj() {
  197 + return upOutSj;
  198 + }
  199 +
  200 + public void setUpOutSj(Double upOutSj) {
  201 + this.upOutSj = upOutSj;
  202 + }
  203 +
  204 + public Double getDownOutLc() {
  205 + return downOutLc;
  206 + }
  207 +
  208 + public void setDownOutLc(Double downOutLc) {
  209 + this.downOutLc = downOutLc;
  210 + }
  211 +
  212 + public Double getDownOutSj() {
  213 + return downOutSj;
  214 + }
  215 +
  216 + public void setDownOutSj(Double downOutSj) {
  217 + this.downOutSj = downOutSj;
  218 + }
  219 +
  220 + public Double getUpInLc() {
  221 + return upInLc;
  222 + }
  223 +
  224 + public void setUpInLc(Double upInLc) {
  225 + this.upInLc = upInLc;
  226 + }
  227 +
  228 + public Double getUpInSj() {
  229 + return upInSj;
  230 + }
  231 +
  232 + public void setUpInSj(Double upInSj) {
  233 + this.upInSj = upInSj;
  234 + }
  235 +
  236 + public Double getDownInLc() {
  237 + return downInLc;
  238 + }
  239 +
  240 + public void setDownInLc(Double downInLc) {
  241 + this.downInLc = downInLc;
  242 + }
  243 +
  244 + public Double getDownInSj() {
  245 + return downInSj;
  246 + }
  247 +
  248 + public void setDownInSj(Double downInSj) {
  249 + this.downInSj = downInSj;
  250 + }
159 } 251 }
src/main/java/com/bsth/repository/realcontrol/ScheduleRealInfoRepository.java
@@ -28,14 +28,8 @@ public interface ScheduleRealInfoRepository extends BaseRepository<ScheduleRealI @@ -28,14 +28,8 @@ public interface ScheduleRealInfoRepository extends BaseRepository<ScheduleRealI
28 @Query(value="select s from ScheduleRealInfo s where s.xlBm = ?1 and DATE_FORMAT(s.scheduleDate,'%Y-%m-%d') = ?2 GROUP BY s.id,s.jGh,s.clZbh,s.lpName order by (lpName+1)") 28 @Query(value="select s from ScheduleRealInfo s where s.xlBm = ?1 and DATE_FORMAT(s.scheduleDate,'%Y-%m-%d') = ?2 GROUP BY s.id,s.jGh,s.clZbh,s.lpName order by (lpName+1)")
29 List<ScheduleRealInfo> queryUserInfo(String line,String date); 29 List<ScheduleRealInfo> queryUserInfo(String line,String date);
30 30
31 - @Query(value="select min(s.id), s.jGh,s.clZbh,s.lpName,s.jName,s.sGh,s.sName from ScheduleRealInfo s where s.xlBm = ?1 and DATE_FORMAT(s.scheduleDate,'%Y-%m-%d') = ?2 GROUP BY s.jGh,s.clZbh,s.lpName ,s.jName,s.sGh,s.sName order by (lpName+1)") 31 + @Query(value="select min(s.id), s.jGh,s.clZbh,s.lpName,s.jName from ScheduleRealInfo s where s.xlBm = ?1 and DATE_FORMAT(s.scheduleDate,'%Y-%m-%d') = ?2 GROUP BY s.jGh,s.clZbh,s.lpName ,s.jName order by (lpName+1)")
32 List<ScheduleRealInfo> queryUserInfo2(String line,String date); 32 List<ScheduleRealInfo> queryUserInfo2(String line,String date);
33 -  
34 - @Query(value="select min(s.id), s.jGh,s.clZbh,s.lpName,s.jName,s.sGh,s.sName from ScheduleRealInfo s where s.xlBm = ?1 and DATE_FORMAT(s.scheduleDate,'%Y-%m-%d') = ?2 GROUP BY s.jGh,s.clZbh,s.lpName ,s.jName,s.sGh,s.sName order by ?3 desc")  
35 - List<ScheduleRealInfo> queryUserInfoPxDesc(String line,String date,String state);  
36 -  
37 - @Query(value="select min(s.id), s.jGh,s.clZbh,s.lpName,s.jName,s.sGh,s.sName from ScheduleRealInfo s where s.xlBm = ?1 and DATE_FORMAT(s.scheduleDate,'%Y-%m-%d') = ?2 GROUP BY s.jGh,s.clZbh,s.lpName ,s.jName,s.sGh,s.sName order by ?3 asc")  
38 - List<ScheduleRealInfo> queryUserInfoPxAsc(String line,String date,String state);  
39 33
40 @Query(value="select min(s.id), s.clZbh from ScheduleRealInfo s where s.xlBm = ?1 and DATE_FORMAT(s.scheduleDate,'%Y-%m-%d') = ?2 GROUP BY s.clZbh ") 34 @Query(value="select min(s.id), s.clZbh from ScheduleRealInfo s where s.xlBm = ?1 and DATE_FORMAT(s.scheduleDate,'%Y-%m-%d') = ?2 GROUP BY s.clZbh ")
41 List<ScheduleRealInfo> queryUserInfo3(String line,String date); 35 List<ScheduleRealInfo> queryUserInfo3(String line,String date);
src/main/java/com/bsth/service/impl/PersonnelServiceImpl.java
@@ -34,8 +34,9 @@ public class PersonnelServiceImpl extends BaseServiceImpl&lt;Personnel, Integer&gt; im @@ -34,8 +34,9 @@ public class PersonnelServiceImpl extends BaseServiceImpl&lt;Personnel, Integer&gt; im
34 per=perIterator.next(); 34 per=perIterator.next();
35 if(per.getJobCode().indexOf(jobCode)!=-1){ 35 if(per.getJobCode().indexOf(jobCode)!=-1){
36 Map<String, String> jobCodeMap= new HashMap<>(); 36 Map<String, String> jobCodeMap= new HashMap<>();
37 - jobCodeMap.put("id",per.getJobCode());  
38 - jobCodeMap.put("text", per.getJobCode()+"/"+per.getPersonnelName()); 37 + String jboCode=per.getJobCode().substring(per.getJobCode().indexOf("-")+1);
  38 + jobCodeMap.put("id",jboCode);
  39 + jobCodeMap.put("text", jboCode+"/"+per.getPersonnelName());
39 jobCodeMap.put("gs", per.getCompanyCode()); 40 jobCodeMap.put("gs", per.getCompanyCode());
40 list.add(jobCodeMap); 41 list.add(jobCodeMap);
41 } 42 }
src/main/java/com/bsth/service/oil/impl/YlbServiceImpl.java
@@ -36,6 +36,7 @@ import com.bsth.repository.oil.YlxxbRepository; @@ -36,6 +36,7 @@ import com.bsth.repository.oil.YlxxbRepository;
36 import com.bsth.service.impl.BaseServiceImpl; 36 import com.bsth.service.impl.BaseServiceImpl;
37 import com.bsth.service.oil.YlbService; 37 import com.bsth.service.oil.YlbService;
38 import com.bsth.service.realcontrol.ScheduleRealInfoService; 38 import com.bsth.service.realcontrol.ScheduleRealInfoService;
  39 +import com.bsth.util.BatchSaveUtils;
39 import com.github.abel533.echarts.code.Y; 40 import com.github.abel533.echarts.code.Y;
40 41
41 @Service 42 @Service
@@ -183,9 +184,10 @@ public class YlbServiceImpl extends BaseServiceImpl&lt;Ylb,Integer&gt; implements YlbS @@ -183,9 +184,10 @@ public class YlbServiceImpl extends BaseServiceImpl&lt;Ylb,Integer&gt; implements YlbS
183 List<Cyl> clyList=cylRepository.obtainCyl(); 184 List<Cyl> clyList=cylRepository.obtainCyl();
184 //从排班表中计算出行驶的总里程 185 //从排班表中计算出行驶的总里程
185 List<Map<String,Object>> listpb=scheduleRealInfoService.yesterdayDataList(line,rq); 186 List<Map<String,Object>> listpb=scheduleRealInfoService.yesterdayDataList(line,rq);
186 - 187 + List<Ylb> addList=new ArrayList<Ylb>();
  188 + List<Ylb> updateList=new ArrayList<Ylb>();
187 for(int x=0;x<listpb.size();x++){ 189 for(int x=0;x<listpb.size();x++){
188 - 190 + String type="add";
189 Map<String, Object> map=listpb.get(x); 191 Map<String, Object> map=listpb.get(x);
190 192
191 //判断驾驶员驾驶的该车辆是否已经存入了(查出的结果集中日期是相同的,根据驾驶员、内部编号、线路编码判断) 193 //判断驾驶员驾驶的该车辆是否已经存入了(查出的结果集中日期是相同的,根据驾驶员、内部编号、线路编码判断)
@@ -197,6 +199,7 @@ public class YlbServiceImpl extends BaseServiceImpl&lt;Ylb,Integer&gt; implements YlbS @@ -197,6 +199,7 @@ public class YlbServiceImpl extends BaseServiceImpl&lt;Ylb,Integer&gt; implements YlbS
197 &&t1.getXlbm().equals(map.get("xlBm").toString())) 199 &&t1.getXlbm().equals(map.get("xlBm").toString()))
198 { 200 {
199 t=t1; 201 t=t1;
  202 + type="update";
200 } 203 }
201 } 204 }
202 try { 205 try {
@@ -238,6 +241,11 @@ public class YlbServiceImpl extends BaseServiceImpl&lt;Ylb,Integer&gt; implements YlbS @@ -238,6 +241,11 @@ public class YlbServiceImpl extends BaseServiceImpl&lt;Ylb,Integer&gt; implements YlbS
238 t.setSsgsdm(map.get("company")==null?"":map.get("company").toString()); 241 t.setSsgsdm(map.get("company")==null?"":map.get("company").toString());
239 t.setFgsdm(map.get("bCompany")==null?"":map.get("bCompany").toString()); 242 t.setFgsdm(map.get("bCompany")==null?"":map.get("bCompany").toString());
240 t.setRq(sdf.parse(rq)); 243 t.setRq(sdf.parse(rq));
  244 + /*if(type.equals("add")){
  245 + addList.add(t);
  246 + }else{
  247 + updateList.add(t);
  248 + }*/
241 repository.save(t); 249 repository.save(t);
242 newMap.put("status", ResponseCode.SUCCESS); 250 newMap.put("status", ResponseCode.SUCCESS);
243 } catch (ParseException e) { 251 } catch (ParseException e) {
@@ -246,7 +254,20 @@ public class YlbServiceImpl extends BaseServiceImpl&lt;Ylb,Integer&gt; implements YlbS @@ -246,7 +254,20 @@ public class YlbServiceImpl extends BaseServiceImpl&lt;Ylb,Integer&gt; implements YlbS
246 e.printStackTrace(); 254 e.printStackTrace();
247 } 255 }
248 } 256 }
249 - 257 + /* try {
  258 + if(addList.size()>0){
  259 + new BatchSaveUtils<Ylb>().saveList(addList, Ylb.class);
  260 + }
  261 +
  262 + if(updateList.size()>0){
  263 +
  264 + }
  265 + newMap.put("status", ResponseCode.SUCCESS);
  266 + }
  267 + catch (Exception e) {
  268 + // TODO: handle exception
  269 + newMap.put("status", ResponseCode.ERROR);
  270 + }*/
250 return newMap; 271 return newMap;
251 } 272 }
252 273
src/main/java/com/bsth/service/realcontrol/impl/ScheduleRealInfoServiceImpl.java
@@ -476,11 +476,11 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl&lt;ScheduleRealInf @@ -476,11 +476,11 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl&lt;ScheduleRealInf
476 type = "asc"; 476 type = "asc";
477 } 477 }
478 String sqlPlan = "select min(s.id) as id,s.j_Gh as jGh,s.cl_Zbh as clZbh," 478 String sqlPlan = "select min(s.id) as id,s.j_Gh as jGh,s.cl_Zbh as clZbh,"
479 - + " s.lp_Name as lpName,s.j_Name as jName,s.s_Gh as sGh,s.s_Name as sName" 479 + + " s.lp_Name as lpName,s.j_Name as jName"
480 + " from bsth_c_s_sp_info_real s " 480 + " from bsth_c_s_sp_info_real s "
481 + " where s.xl_Bm = '" + line + "' and DATE_FORMAT(s.schedule_Date,'%Y-%m-%d') ='" + date + "' " 481 + " where s.xl_Bm = '" + line + "' and DATE_FORMAT(s.schedule_Date,'%Y-%m-%d') ='" + date + "' "
482 - + " GROUP BY s.j_Gh,s.cl_Zbh,s.lp_Name ,s.j_Name,s.s_Gh,"  
483 - + " s.s_Name order by (" + state + ") " + type; 482 + + " GROUP BY s.j_Gh,s.cl_Zbh,s.lp_Name ,s.j_Name"
  483 + + " order by (" + state + ") " + type;
484 List<ScheduleRealInfo> list = jdbcTemplate.query(sqlPlan, 484 List<ScheduleRealInfo> list = jdbcTemplate.query(sqlPlan,
485 new RowMapper<ScheduleRealInfo>() { 485 new RowMapper<ScheduleRealInfo>() {
486 @Override 486 @Override
@@ -491,8 +491,6 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl&lt;ScheduleRealInf @@ -491,8 +491,6 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl&lt;ScheduleRealInf
491 t.setClZbh(rs.getString("clZbh")); 491 t.setClZbh(rs.getString("clZbh"));
492 t.setLpName(rs.getString("lpName")); 492 t.setLpName(rs.getString("lpName"));
493 t.setjName(rs.getString("jName")); 493 t.setjName(rs.getString("jName"));
494 - t.setsGh(rs.getString("sGh"));  
495 - t.setsName(rs.getString("sName"));  
496 return t; 494 return t;
497 } 495 }
498 }); 496 });
@@ -3173,6 +3171,7 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl&lt;ScheduleRealInf @@ -3173,6 +3171,7 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl&lt;ScheduleRealInf
3173 map.put("fcsjActual", s.getFcsjActual()); 3171 map.put("fcsjActual", s.getFcsjActual());
3174 map.put("zdzName", s.getZdzName()); 3172 map.put("zdzName", s.getZdzName());
3175 map.put("scheduleDate", s.getScheduleDateStr()); 3173 map.put("scheduleDate", s.getScheduleDateStr());
  3174 + map.put("lpName", s.getLpName());
3176 String zdp = "", zwdp = "", wdp = ""; 3175 String zdp = "", zwdp = "", wdp = "";
3177 String zdpT = "", zwdpT = "", wdpT = ""; 3176 String zdpT = "", zwdpT = "", wdpT = "";
3178 3177
src/main/resources/static/pages/oil/list_ph.html
@@ -82,7 +82,8 @@ @@ -82,7 +82,8 @@
82 线路: 82 线路:
83 </td> 83 </td>
84 <td colspan="3"> 84 <td colspan="3">
85 - <select class="form-control" name="xlbm_like" id="xlbm" style="width: 120px;"></select> 85 + <select class="form-control" name="xlbm_eq" id="xlbm" style="width: 120px;"></select>
  86 + <input type="hidden" name="xlbm_like" value=""/>
86 &nbsp; 87 &nbsp;
87 </td> 88 </td>
88 <td > 89 <td >
@@ -234,7 +235,7 @@ @@ -234,7 +235,7 @@
234 var i = layer.load(2); 235 var i = layer.load(2);
235 $get('/ylb/checkYl', params, function () { 236 $get('/ylb/checkYl', params, function () {
236 layer.close(i); 237 layer.close(i);
237 - jsDoQuery(null, true); 238 + jsDoQuery(params, true);
238 }); 239 });
239 } else { 240 } else {
240 layer.msg('请选择日期.'); 241 layer.msg('请选择日期.');
@@ -260,7 +261,7 @@ @@ -260,7 +261,7 @@
260 var i = layer.load(2); 261 var i = layer.load(2);
261 $get('/ylb/outAndIn', params, function () { 262 $get('/ylb/outAndIn', params, function () {
262 layer.close(i); 263 layer.close(i);
263 - jsDoQuery(null, true); 264 + jsDoQuery(params, true);
264 }); 265 });
265 } else { 266 } else {
266 layer.msg('请选择日期.'); 267 layer.msg('请选择日期.');
@@ -283,7 +284,19 @@ @@ -283,7 +284,19 @@
283 var i = layer.load(2); 284 var i = layer.load(2);
284 $get('/ylb/sort', params, function () { 285 $get('/ylb/sort', params, function () {
285 layer.close(i); 286 layer.close(i);
286 - jsDoQuery(null, true); 287 + var cells = $('tr.filter')[0].cells
  288 + , params1 = {}
  289 + , name;
  290 + $.each(cells, function (i, cell) {
  291 + var items = $('input,select', cell);
  292 + for (var j = 0, item; item = items[j++];) {
  293 + name = $(item).attr('name');
  294 + if (name) {
  295 + params1[name] = $(item).val();
  296 + }
  297 + }
  298 + });
  299 + jsDoQuery(params1, true);
287 }); 300 });
288 301
289 } 302 }
@@ -537,7 +550,7 @@ @@ -537,7 +550,7 @@
537 //搜索线路 550 //搜索线路
538 $.get('/basic/lineCode2Name',function(result){ 551 $.get('/basic/lineCode2Name',function(result){
539 var data=[]; 552 var data=[];
540 - data.push({id: " ", text: "全部线路"}); 553 +// data.push({id: " ", text: "全部线路"});
541 for(var code in result){ 554 for(var code in result){
542 data.push({id: code, text: result[code]}); 555 data.push({id: code, text: result[code]});
543 } 556 }
src/main/resources/static/pages/scheduleApp/module/basicInfo/deviceInfoManage/edit.html
@@ -61,7 +61,7 @@ @@ -61,7 +61,7 @@
61 <div class="col-md-3"> 61 <div class="col-md-3">
62 <sa-Select5 name="cl" 62 <sa-Select5 name="cl"
63 model="ctrl.deviceInfoForSave" 63 model="ctrl.deviceInfoForSave"
64 - cmaps="{'cl': 'id', 'clZbh': 'insideCode'}" 64 + cmaps="{'cl': 'id', 'clZbh': 'insideCode', 'oldDeviceNo': 'equipmentCode'}"
65 dcname="cl" 65 dcname="cl"
66 icname="id" 66 icname="id"
67 dsparams="{{ {type: 'ajax', param:{type: 'all'}, atype:'cl' } | json }}" 67 dsparams="{{ {type: 'ajax', param:{type: 'all'}, atype:'cl' } | json }}"
src/main/resources/static/pages/scheduleApp/module/basicInfo/deviceInfoManage/form.html
@@ -61,7 +61,7 @@ @@ -61,7 +61,7 @@
61 <div class="col-md-3"> 61 <div class="col-md-3">
62 <sa-Select5 name="cl" 62 <sa-Select5 name="cl"
63 model="ctrl.deviceInfoForSave" 63 model="ctrl.deviceInfoForSave"
64 - cmaps="{'cl': 'id', 'clZbh': 'insideCode'}" 64 + cmaps="{'cl': 'id', 'clZbh': 'insideCode', 'oldDeviceNo': 'equipmentCode'}"
65 dcname="cl" 65 dcname="cl"
66 icname="id" 66 icname="id"
67 dsparams="{{ {type: 'ajax', param:{type: 'all'}, atype:'cl' } | json }}" 67 dsparams="{{ {type: 'ajax', param:{type: 'all'}, atype:'cl' } | json }}"
src/main/resources/static/pages/scheduleApp/module/core/busConfig/edit.html
@@ -154,6 +154,149 @@ @@ -154,6 +154,149 @@
154 </div> 154 </div>
155 </div> 155 </div>
156 156
  157 + <div class="form-group has-success has-feedback">
  158 + <label class="col-md-2 control-label">配置类型*:</label>
  159 + <div class="col-md-3">
  160 + <sa-Radiogroup model="ctrl.busConfigForSave.pzType" dicgroup="CheLiangPeiZhi" name="pzType"></sa-Radiogroup>
  161 + </div>
  162 + </div>
  163 +
  164 + <div class="form-group has-success has-feedback"
  165 + ng-if="ctrl.busConfigForSave.pzType == 'ZW' || ctrl.busConfigForSave.pzType == 'FS'">
  166 + <label class="col-md-2 control-label">上行出场里程*:</label>
  167 + <div class="col-md-3">
  168 + <input type="text" class="form-control" name="upOutLc"
  169 + ng-model="ctrl.busConfigForSave.upOutLc" required ng-pattern="ctrl.float_regex"
  170 + />
  171 + </div>
  172 + <!-- 隐藏块,显示验证信息 -->
  173 + <div class="alert alert-danger well-sm" ng-show="myForm.upOutLc.$error.required">
  174 + 上行出场里程必须填写
  175 + </div>
  176 + <div class="alert alert-danger well-sm" ng-show="myForm.upOutLc.$error.pattern">
  177 + 输入数字
  178 + </div>
  179 + </div>
  180 +
  181 + <div class="form-group has-success has-feedback"
  182 + ng-if="ctrl.busConfigForSave.pzType == 'ZW' || ctrl.busConfigForSave.pzType == 'FS'">
  183 + <label class="col-md-2 control-label">上行出场时间*:</label>
  184 + <div class="col-md-3">
  185 + <input type="text" class="form-control" name="upOutSj"
  186 + ng-model="ctrl.busConfigForSave.upOutSj" required ng-pattern="ctrl.number_regex"
  187 + />
  188 + </div>
  189 + <!-- 隐藏块,显示验证信息 -->
  190 + <div class="alert alert-danger well-sm" ng-show="myForm.upOutSj.$error.required">
  191 + 上行出场时间必须填写
  192 + </div>
  193 + <div class="alert alert-danger well-sm" ng-show="myForm.upOutSj.$error.pattern">
  194 + 输入整数
  195 + </div>
  196 + </div>
  197 +
  198 + <div class="form-group has-success has-feedback"
  199 + ng-if="ctrl.busConfigForSave.pzType == 'ZW' || ctrl.busConfigForSave.pzType == 'FS'">
  200 + <label class="col-md-2 control-label">下行出场里程*:</label>
  201 + <div class="col-md-3">
  202 + <input type="text" class="form-control" name="downOutLc"
  203 + ng-model="ctrl.busConfigForSave.downOutLc" required ng-pattern="ctrl.float_regex"
  204 + />
  205 + </div>
  206 + <!-- 隐藏块,显示验证信息 -->
  207 + <div class="alert alert-danger well-sm" ng-show="myForm.downOutLc.$error.required">
  208 + 下行出场里程必须填写
  209 + </div>
  210 + <div class="alert alert-danger well-sm" ng-show="myForm.downOutLc.$error.pattern">
  211 + 输入数字
  212 + </div>
  213 + </div>
  214 +
  215 + <div class="form-group has-success has-feedback"
  216 + ng-if="ctrl.busConfigForSave.pzType == 'ZW' || ctrl.busConfigForSave.pzType == 'FS'">
  217 + <label class="col-md-2 control-label">下行出场时间*:</label>
  218 + <div class="col-md-3">
  219 + <input type="text" class="form-control" name="downOutSj"
  220 + ng-model="ctrl.busConfigForSave.downOutSj" required ng-pattern="ctrl.number_regex"
  221 + />
  222 + </div>
  223 + <!-- 隐藏块,显示验证信息 -->
  224 + <div class="alert alert-danger well-sm" ng-show="myForm.downOutSj.$error.required">
  225 + 下行出场时间必须填写
  226 + </div>
  227 + <div class="alert alert-danger well-sm" ng-show="myForm.downOutSj.$error.pattern">
  228 + 输入整数
  229 + </div>
  230 + </div>
  231 +
  232 + <div class="form-group has-success has-feedback"
  233 + ng-if="ctrl.busConfigForSave.pzType == 'ZW' || ctrl.busConfigForSave.pzType == 'FS'">
  234 + <label class="col-md-2 control-label">上行进场里程*:</label>
  235 + <div class="col-md-3">
  236 + <input type="text" class="form-control" name="upInLc"
  237 + ng-model="ctrl.busConfigForSave.upInLc" required ng-pattern="ctrl.float_regex"
  238 + />
  239 + </div>
  240 + <!-- 隐藏块,显示验证信息 -->
  241 + <div class="alert alert-danger well-sm" ng-show="myForm.upInLc.$error.required">
  242 + 上行进场里程必须填写
  243 + </div>
  244 + <div class="alert alert-danger well-sm" ng-show="myForm.upInLc.$error.pattern">
  245 + 输入数字
  246 + </div>
  247 + </div>
  248 +
  249 + <div class="form-group has-success has-feedback"
  250 + ng-if="ctrl.busConfigForSave.pzType == 'ZW' || ctrl.busConfigForSave.pzType == 'FS'">
  251 + <label class="col-md-2 control-label">上行进场时间*:</label>
  252 + <div class="col-md-3">
  253 + <input type="text" class="form-control" name="upInSj"
  254 + ng-model="ctrl.busConfigForSave.upInSj" required ng-pattern="ctrl.number_regex"
  255 + />
  256 + </div>
  257 + <!-- 隐藏块,显示验证信息 -->
  258 + <div class="alert alert-danger well-sm" ng-show="myForm.upInSj.$error.required">
  259 + 上行进场时间必须填写
  260 + </div>
  261 + <div class="alert alert-danger well-sm" ng-show="myForm.upInSj.$error.pattern">
  262 + 输入整数
  263 + </div>
  264 + </div>
  265 +
  266 + <div class="form-group has-success has-feedback"
  267 + ng-if="ctrl.busConfigForSave.pzType == 'ZW' || ctrl.busConfigForSave.pzType == 'FS'">
  268 + <label class="col-md-2 control-label">下行进场里程*:</label>
  269 + <div class="col-md-3">
  270 + <input type="text" class="form-control" name="downInLc"
  271 + ng-model="ctrl.busConfigForSave.downInLc" required ng-pattern="ctrl.float_regex"
  272 + />
  273 + </div>
  274 + <!-- 隐藏块,显示验证信息 -->
  275 + <div class="alert alert-danger well-sm" ng-show="myForm.downInLc.$error.required">
  276 + 下行进场里程必须填写
  277 + </div>
  278 + <div class="alert alert-danger well-sm" ng-show="myForm.downInLc.$error.pattern">
  279 + 输入数字
  280 + </div>
  281 + </div>
  282 +
  283 + <div class="form-group has-success has-feedback"
  284 + ng-if="ctrl.busConfigForSave.pzType == 'ZW' || ctrl.busConfigForSave.pzType == 'FS'">
  285 + <label class="col-md-2 control-label">下行进场时间*:</label>
  286 + <div class="col-md-3">
  287 + <input type="text" class="form-control" name="downInSj"
  288 + ng-model="ctrl.busConfigForSave.downInSj" required ng-pattern="ctrl.number_regex"
  289 + />
  290 + </div>
  291 + <!-- 隐藏块,显示验证信息 -->
  292 + <div class="alert alert-danger well-sm" ng-show="myForm.downInSj.$error.required">
  293 + 下行进场时间必须填写
  294 + </div>
  295 + <div class="alert alert-danger well-sm" ng-show="myForm.downInSj.$error.pattern">
  296 + 输入整数
  297 + </div>
  298 + </div>
  299 +
157 300
158 <!-- 其他form-group --> 301 <!-- 其他form-group -->
159 302
src/main/resources/static/pages/scheduleApp/module/core/busConfig/form.html
@@ -154,6 +154,149 @@ @@ -154,6 +154,149 @@
154 </div> 154 </div>
155 </div> 155 </div>
156 156
  157 + <div class="form-group has-success has-feedback">
  158 + <label class="col-md-2 control-label">配置类型*:</label>
  159 + <div class="col-md-3">
  160 + <sa-Radiogroup model="ctrl.busConfigForSave.pzType" dicgroup="CheLiangPeiZhi" name="pzType"></sa-Radiogroup>
  161 + </div>
  162 + </div>
  163 +
  164 + <div class="form-group has-success has-feedback"
  165 + ng-if="ctrl.busConfigForSave.pzType == 'ZW' || ctrl.busConfigForSave.pzType == 'FS'">
  166 + <label class="col-md-2 control-label">上行出场里程*:</label>
  167 + <div class="col-md-3">
  168 + <input type="text" class="form-control" name="upOutLc"
  169 + ng-model="ctrl.busConfigForSave.upOutLc" required ng-pattern="ctrl.float_regex"
  170 + />
  171 + </div>
  172 + <!-- 隐藏块,显示验证信息 -->
  173 + <div class="alert alert-danger well-sm" ng-show="myForm.upOutLc.$error.required">
  174 + 上行出场里程必须填写
  175 + </div>
  176 + <div class="alert alert-danger well-sm" ng-show="myForm.upOutLc.$error.pattern">
  177 + 输入数字
  178 + </div>
  179 + </div>
  180 +
  181 + <div class="form-group has-success has-feedback"
  182 + ng-if="ctrl.busConfigForSave.pzType == 'ZW' || ctrl.busConfigForSave.pzType == 'FS'">
  183 + <label class="col-md-2 control-label">上行出场时间*:</label>
  184 + <div class="col-md-3">
  185 + <input type="text" class="form-control" name="upOutSj"
  186 + ng-model="ctrl.busConfigForSave.upOutSj" required ng-pattern="ctrl.number_regex"
  187 + />
  188 + </div>
  189 + <!-- 隐藏块,显示验证信息 -->
  190 + <div class="alert alert-danger well-sm" ng-show="myForm.upOutSj.$error.required">
  191 + 上行出场时间必须填写
  192 + </div>
  193 + <div class="alert alert-danger well-sm" ng-show="myForm.upOutSj.$error.pattern">
  194 + 输入整数
  195 + </div>
  196 + </div>
  197 +
  198 + <div class="form-group has-success has-feedback"
  199 + ng-if="ctrl.busConfigForSave.pzType == 'ZW' || ctrl.busConfigForSave.pzType == 'FS'">
  200 + <label class="col-md-2 control-label">下行出场里程*:</label>
  201 + <div class="col-md-3">
  202 + <input type="text" class="form-control" name="downOutLc"
  203 + ng-model="ctrl.busConfigForSave.downOutLc" required ng-pattern="ctrl.float_regex"
  204 + />
  205 + </div>
  206 + <!-- 隐藏块,显示验证信息 -->
  207 + <div class="alert alert-danger well-sm" ng-show="myForm.downOutLc.$error.required">
  208 + 下行出场里程必须填写
  209 + </div>
  210 + <div class="alert alert-danger well-sm" ng-show="myForm.downOutLc.$error.pattern">
  211 + 输入数字
  212 + </div>
  213 + </div>
  214 +
  215 + <div class="form-group has-success has-feedback"
  216 + ng-if="ctrl.busConfigForSave.pzType == 'ZW' || ctrl.busConfigForSave.pzType == 'FS'">
  217 + <label class="col-md-2 control-label">下行出场时间*:</label>
  218 + <div class="col-md-3">
  219 + <input type="text" class="form-control" name="downOutSj"
  220 + ng-model="ctrl.busConfigForSave.downOutSj" required ng-pattern="ctrl.number_regex"
  221 + />
  222 + </div>
  223 + <!-- 隐藏块,显示验证信息 -->
  224 + <div class="alert alert-danger well-sm" ng-show="myForm.downOutSj.$error.required">
  225 + 下行出场时间必须填写
  226 + </div>
  227 + <div class="alert alert-danger well-sm" ng-show="myForm.downOutSj.$error.pattern">
  228 + 输入整数
  229 + </div>
  230 + </div>
  231 +
  232 + <div class="form-group has-success has-feedback"
  233 + ng-if="ctrl.busConfigForSave.pzType == 'ZW' || ctrl.busConfigForSave.pzType == 'FS'">
  234 + <label class="col-md-2 control-label">上行进场里程*:</label>
  235 + <div class="col-md-3">
  236 + <input type="text" class="form-control" name="upInLc"
  237 + ng-model="ctrl.busConfigForSave.upInLc" required ng-pattern="ctrl.float_regex"
  238 + />
  239 + </div>
  240 + <!-- 隐藏块,显示验证信息 -->
  241 + <div class="alert alert-danger well-sm" ng-show="myForm.upInLc.$error.required">
  242 + 上行进场里程必须填写
  243 + </div>
  244 + <div class="alert alert-danger well-sm" ng-show="myForm.upInLc.$error.pattern">
  245 + 输入数字
  246 + </div>
  247 + </div>
  248 +
  249 + <div class="form-group has-success has-feedback"
  250 + ng-if="ctrl.busConfigForSave.pzType == 'ZW' || ctrl.busConfigForSave.pzType == 'FS'">
  251 + <label class="col-md-2 control-label">上行进场时间*:</label>
  252 + <div class="col-md-3">
  253 + <input type="text" class="form-control" name="upInSj"
  254 + ng-model="ctrl.busConfigForSave.upInSj" required ng-pattern="ctrl.number_regex"
  255 + />
  256 + </div>
  257 + <!-- 隐藏块,显示验证信息 -->
  258 + <div class="alert alert-danger well-sm" ng-show="myForm.upInSj.$error.required">
  259 + 上行进场时间必须填写
  260 + </div>
  261 + <div class="alert alert-danger well-sm" ng-show="myForm.upInSj.$error.pattern">
  262 + 输入整数
  263 + </div>
  264 + </div>
  265 +
  266 + <div class="form-group has-success has-feedback"
  267 + ng-if="ctrl.busConfigForSave.pzType == 'ZW' || ctrl.busConfigForSave.pzType == 'FS'">
  268 + <label class="col-md-2 control-label">下行进场里程*:</label>
  269 + <div class="col-md-3">
  270 + <input type="text" class="form-control" name="downInLc"
  271 + ng-model="ctrl.busConfigForSave.downInLc" required ng-pattern="ctrl.float_regex"
  272 + />
  273 + </div>
  274 + <!-- 隐藏块,显示验证信息 -->
  275 + <div class="alert alert-danger well-sm" ng-show="myForm.downInLc.$error.required">
  276 + 下行进场里程必须填写
  277 + </div>
  278 + <div class="alert alert-danger well-sm" ng-show="myForm.downInLc.$error.pattern">
  279 + 输入数字
  280 + </div>
  281 + </div>
  282 +
  283 + <div class="form-group has-success has-feedback"
  284 + ng-if="ctrl.busConfigForSave.pzType == 'ZW' || ctrl.busConfigForSave.pzType == 'FS'">
  285 + <label class="col-md-2 control-label">下行进场时间*:</label>
  286 + <div class="col-md-3">
  287 + <input type="text" class="form-control" name="downInSj"
  288 + ng-model="ctrl.busConfigForSave.downInSj" required ng-pattern="ctrl.number_regex"
  289 + />
  290 + </div>
  291 + <!-- 隐藏块,显示验证信息 -->
  292 + <div class="alert alert-danger well-sm" ng-show="myForm.downInSj.$error.required">
  293 + 下行进场时间必须填写
  294 + </div>
  295 + <div class="alert alert-danger well-sm" ng-show="myForm.downInSj.$error.pattern">
  296 + 输入整数
  297 + </div>
  298 + </div>
  299 +
157 300
158 <!-- 其他form-group --> 301 <!-- 其他form-group -->
159 302
src/main/resources/static/pages/scheduleApp/module/core/busConfig/module.js
@@ -228,6 +228,11 @@ angular.module(&#39;ScheduleApp&#39;).controller( @@ -228,6 +228,11 @@ angular.module(&#39;ScheduleApp&#39;).controller(
228 self.zzrqOpen = true; 228 self.zzrqOpen = true;
229 }; 229 };
230 230
  231 + // 整数正则表达式
  232 + self.number_regex = /^-?\d+$/;
  233 + // 小数正则表达式
  234 + self.float_regex = /^-?(?:\d+|\d{1,3}(?:,\d{3})+)(?:\.\d+)?$/;
  235 +
231 // 欲保存的busInfo信息,绑定 236 // 欲保存的busInfo信息,绑定
232 self.busConfigForSave = new BusConfig; 237 self.busConfigForSave = new BusConfig;
233 self.busConfigForSave.xl = {}; 238 self.busConfigForSave.xl = {};