Commit 30282880a7d974f9414aa1cbe9d82d6e808d537a

Authored by 潘钊
1 parent 4b460f3d

update...

src/main/java/com/bsth/controller/realcontrol/ScheduleRealInfoController.java
... ... @@ -529,8 +529,8 @@ public class ScheduleRealInfoController extends BaseController<ScheduleRealInfo,
529 529 }
530 530  
531 531 @RequestMapping(value="/changeBcType/{id}", method=RequestMethod.POST)
532   - public Map<String, Object> changeBcType(@PathVariable("id") Long id, String bcType, String remarks){
533   - return scheduleRealInfoService.changeBcType(id, bcType, remarks);
  532 + public Map<String, Object> changeBcType(@PathVariable("id") Long id, String bcType, String remarks, String majorStationName){
  533 + return scheduleRealInfoService.changeBcType(id, bcType, remarks, majorStationName);
534 534 }
535 535  
536 536 @RequestMapping(value="/history", method=RequestMethod.POST)
... ...
src/main/java/com/bsth/entity/realcontrol/ScheduleRealInfo.java
... ... @@ -108,6 +108,9 @@ public class ScheduleRealInfo {
108 108 */
109 109 private String bcType;
110 110  
  111 + //放站班次 站点名称
  112 + private String majorStationName;
  113 +
111 114 /** 创建人 */
112 115 @JsonIgnore
113 116 @ManyToOne(fetch = FetchType.LAZY)
... ... @@ -971,4 +974,12 @@ public class ScheduleRealInfo {
971 974 public void setCcService(boolean ccService) {
972 975 this.ccService = ccService;
973 976 }
  977 +
  978 + public String getMajorStationName() {
  979 + return majorStationName;
  980 + }
  981 +
  982 + public void setMajorStationName(String majorStationName) {
  983 + this.majorStationName = majorStationName;
  984 + }
974 985 }
... ...
src/main/java/com/bsth/service/directive/DirectiveServiceImpl.java
... ... @@ -110,8 +110,15 @@ public class DirectiveServiceImpl extends BaseServiceImpl&lt;D60, Integer&gt; implemen
110 110 logger.warn("烂班不允许发送调度指令....");
111 111 return -1;
112 112 }
113   - String text = "已完成" + finish + "个班次,下一发车时间" + fmtHHmm_CN.print(sch.getDfsjT()) + ",由"
114   - + sch.getQdzName() + "发往" + sch.getZdzName();
  113 + String text = "您已完成" + finish + "个班次,下一发车时间" + fmtHHmm_CN.print(sch.getDfsjT()) + ",由"
  114 + + sch.getQdzName() + "发往" + sch.getZdzName() ;
  115 +
  116 + if(sch.getBcType().equals("venting")){
  117 + text += " (直放)";
  118 + }
  119 + else if(sch.getBcType().equals("major")){
  120 + text += " (放站到"+sch.getMajorStationName()+"带客)";
  121 + }
115 122  
116 123 //下发0x01指令 调度指令(闹钟有效)
117 124 long t = System.currentTimeMillis() + 1000 * 30,
... ...
src/main/java/com/bsth/service/realcontrol/ScheduleRealInfoService.java
... ... @@ -139,9 +139,9 @@ public interface ScheduleRealInfoService extends BaseService&lt;ScheduleRealInfo, L
139 139  
140 140 Map<String, Object> multi_dftz(List<DfsjChange> dfsjcs);
141 141  
142   - Map<String,Object> changeBcType(Long id, String bcType, String remarks);
  142 + Map<String, Object> changeBcType(Long id, String bcType, String remarks, String majorStationName);
143 143  
144   - Map<String,Object> historySave(ScheduleRealInfo sch);
  144 + Map<String,Object> historySave(ScheduleRealInfo sch);
145 145  
146 146 Map<String, Object> MapById(Long id) ;
147 147  
... ...
src/main/java/com/bsth/service/realcontrol/impl/ScheduleRealInfoServiceImpl.java
... ... @@ -24,7 +24,6 @@ import com.bsth.data.utils.CustomStringUtils;
24 24 import com.bsth.entity.Cars;
25 25 import com.bsth.entity.Line;
26 26 import com.bsth.entity.Personnel;
27   -import com.bsth.entity.mcy_forms.Waybillday;
28 27 import com.bsth.entity.oil.Dlb;
29 28 import com.bsth.entity.oil.Ylb;
30 29 import com.bsth.entity.oil.Ylxxb;
... ... @@ -3241,7 +3240,7 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl&lt;ScheduleRealInf
3241 3240 * @return
3242 3241 */
3243 3242 @Override
3244   - public Map<String, Object> changeBcType(Long id, String bcType, String remarks) {
  3243 + public Map<String, Object> changeBcType(Long id, String bcType, String remarks, String majorStationName) {
3245 3244 Map<String, Object> rs = new HashMap<>();
3246 3245  
3247 3246 try {
... ... @@ -3251,6 +3250,10 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl&lt;ScheduleRealInf
3251 3250 sch.addRemarks(remarks);
3252 3251 rs.put("status", ResponseCode.SUCCESS);
3253 3252 rs.put("t", sch);
  3253 +
  3254 + if("major".equals(bcType)){
  3255 + sch.setMajorStationName(majorStationName);
  3256 + }
3254 3257 }
3255 3258 } catch (Exception e) {
3256 3259 logger.error("", e);
... ...
src/main/resources/static/real_control_v2/fragments/line_schedule/context_menu/bc_type_major.html
... ... @@ -178,7 +178,8 @@
178 178 //将班次类型调整为放站
179 179 gb_common.$post('/realSchedule/changeBcType/' + sch.id, {
180 180 bcType: 'major',
181   - remarks: remarks
  181 + remarks: remarks,
  182 + majorStationName: $('[name=endStation]').find("option:selected").text()
182 183 }, function (rs) {
183 184 UIkit.modal(modal).hide();
184 185 gb_schedule_table.updateSchedule(rs.t);
... ...