Commit 841c9a3e6066d2b9899c7fb53f2be1a7e37ec37c
Merge branch 'lggj' of http://192.168.168.245:8888/panzhaov5/bsth_control into lggj
Showing
149 changed files
with
9511 additions
and
1584 deletions
src/main/java/com/bsth/Application.java
| 1 | package com.bsth; | 1 | package com.bsth; |
| 2 | 2 | ||
| 3 | import com.bsth.data.SystemParamCache; | 3 | import com.bsth.data.SystemParamCache; |
| 4 | -import com.bsth.service.SystemParamService; | ||
| 5 | import com.fasterxml.jackson.annotation.JsonInclude; | 4 | import com.fasterxml.jackson.annotation.JsonInclude; |
| 6 | import com.fasterxml.jackson.databind.ObjectMapper; | 5 | import com.fasterxml.jackson.databind.ObjectMapper; |
| 7 | import com.fasterxml.jackson.databind.SerializationFeature; | 6 | import com.fasterxml.jackson.databind.SerializationFeature; |
| @@ -23,7 +22,7 @@ import java.util.concurrent.ScheduledExecutorService; | @@ -23,7 +22,7 @@ import java.util.concurrent.ScheduledExecutorService; | ||
| 23 | @SpringBootApplication | 22 | @SpringBootApplication |
| 24 | public class Application extends SpringBootServletInitializer { | 23 | public class Application extends SpringBootServletInitializer { |
| 25 | 24 | ||
| 26 | - public static ScheduledExecutorService mainServices = Executors.newScheduledThreadPool(21); | 25 | + public static ScheduledExecutorService mainServices = Executors.newScheduledThreadPool(30); |
| 27 | 26 | ||
| 28 | @Autowired | 27 | @Autowired |
| 29 | private SystemParamCache systemParamCache; | 28 | private SystemParamCache systemParamCache; |
src/main/java/com/bsth/XDApplication.java
| @@ -23,6 +23,7 @@ import com.bsth.data.schedule.thread.SchedulePstThread; | @@ -23,6 +23,7 @@ import com.bsth.data.schedule.thread.SchedulePstThread; | ||
| 23 | import com.bsth.data.schedule.thread.ScheduleRefreshThread; | 23 | import com.bsth.data.schedule.thread.ScheduleRefreshThread; |
| 24 | import com.bsth.data.schedule.thread.SubmitToTrafficManage; | 24 | import com.bsth.data.schedule.thread.SubmitToTrafficManage; |
| 25 | import com.bsth.data.zndd.ZnddThread; | 25 | import com.bsth.data.zndd.ZnddThread; |
| 26 | +import com.bsth.data.zndd.ZnddTwoThread; | ||
| 26 | import com.bsth.util.DateUtils; | 27 | import com.bsth.util.DateUtils; |
| 27 | import com.bsth.util.Tools; | 28 | import com.bsth.util.Tools; |
| 28 | import org.slf4j.Logger; | 29 | import org.slf4j.Logger; |
| @@ -85,6 +86,9 @@ public class XDApplication implements CommandLineRunner { | @@ -85,6 +86,9 @@ public class XDApplication implements CommandLineRunner { | ||
| 85 | FixedEnableVerionsThread fixedEnableVerionsThread;*/ | 86 | FixedEnableVerionsThread fixedEnableVerionsThread;*/ |
| 86 | @Autowired | 87 | @Autowired |
| 87 | ZnddThread znddThread; | 88 | ZnddThread znddThread; |
| 89 | + | ||
| 90 | + @Autowired | ||
| 91 | + ZnddTwoThread ZnddtwoThread; | ||
| 88 | @Autowired | 92 | @Autowired |
| 89 | SafeDrivDataLoadThread safeDrivDataLoadThread; | 93 | SafeDrivDataLoadThread safeDrivDataLoadThread; |
| 90 | 94 | ||
| @@ -145,8 +149,9 @@ public class XDApplication implements CommandLineRunner { | @@ -145,8 +149,9 @@ public class XDApplication implements CommandLineRunner { | ||
| 145 | //dayOfSchedule.dataRecovery(); | 149 | //dayOfSchedule.dataRecovery(); |
| 146 | 150 | ||
| 147 | //智能调度 | 151 | //智能调度 |
| 148 | - sexec.scheduleWithFixedDelay(znddThread, 15, 25, TimeUnit.SECONDS); | ||
| 149 | - | 152 | + sexec.scheduleWithFixedDelay(znddThread, 30, 30, TimeUnit.SECONDS); |
| 153 | + //智能调度 | ||
| 154 | + sexec.scheduleWithFixedDelay(ZnddtwoThread, 30, 60, TimeUnit.SECONDS); | ||
| 150 | //安全驾驶 | 155 | //安全驾驶 |
| 151 | sexec.scheduleWithFixedDelay(safeDrivDataLoadThread, 180, 10, TimeUnit.SECONDS); | 156 | sexec.scheduleWithFixedDelay(safeDrivDataLoadThread, 180, 10, TimeUnit.SECONDS); |
| 152 | 157 | ||
| @@ -190,10 +195,14 @@ public class XDApplication implements CommandLineRunner { | @@ -190,10 +195,14 @@ public class XDApplication implements CommandLineRunner { | ||
| 190 | public void prodInit(){ | 195 | public void prodInit(){ |
| 191 | log.info("prodInit..."); | 196 | log.info("prodInit..."); |
| 192 | ScheduledExecutorService sexec = Application.mainServices; | 197 | ScheduledExecutorService sexec = Application.mainServices; |
| 198 | + | ||
| 199 | + | ||
| 193 | //安全驾驶 | 200 | //安全驾驶 |
| 194 | sexec.scheduleWithFixedDelay(safeDrivDataLoadThread, 180, 10, TimeUnit.SECONDS); | 201 | sexec.scheduleWithFixedDelay(safeDrivDataLoadThread, 180, 10, TimeUnit.SECONDS); |
| 195 | //智能调度 | 202 | //智能调度 |
| 196 | - sexec.scheduleWithFixedDelay(znddThread, 15, 25, TimeUnit.SECONDS); | 203 | + sexec.scheduleWithFixedDelay(znddThread, 30, 30, TimeUnit.SECONDS); |
| 204 | + //智能调度 | ||
| 205 | + sexec.scheduleWithFixedDelay(ZnddtwoThread, 30, 60, TimeUnit.SECONDS); | ||
| 197 | GpsDataLoaderThread.setFlag(-1); | 206 | GpsDataLoaderThread.setFlag(-1); |
| 198 | /** 线调业务 */ | 207 | /** 线调业务 */ |
| 199 | sexec.scheduleWithFixedDelay(scheduleRefreshThread, 10, 120, TimeUnit.SECONDS);//班次更新线程 | 208 | sexec.scheduleWithFixedDelay(scheduleRefreshThread, 10, 120, TimeUnit.SECONDS);//班次更新线程 |
| @@ -237,8 +246,11 @@ public class XDApplication implements CommandLineRunner { | @@ -237,8 +246,11 @@ public class XDApplication implements CommandLineRunner { | ||
| 237 | ScheduledExecutorService sexec = Application.mainServices; | 246 | ScheduledExecutorService sexec = Application.mainServices; |
| 238 | //安全驾驶 | 247 | //安全驾驶 |
| 239 | sexec.scheduleWithFixedDelay(safeDrivDataLoadThread, 180, 10, TimeUnit.SECONDS); | 248 | sexec.scheduleWithFixedDelay(safeDrivDataLoadThread, 180, 10, TimeUnit.SECONDS); |
| 249 | + | ||
| 240 | //智能调度 | 250 | //智能调度 |
| 241 | - sexec.scheduleWithFixedDelay(znddThread, 15, 25, TimeUnit.SECONDS); | 251 | + sexec.scheduleWithFixedDelay(znddThread, 30, 30, TimeUnit.SECONDS); |
| 252 | + //智能调度 | ||
| 253 | + sexec.scheduleWithFixedDelay(ZnddtwoThread, 30, 60, TimeUnit.SECONDS); | ||
| 242 | GpsDataLoaderThread.setFlag(-1); | 254 | GpsDataLoaderThread.setFlag(-1); |
| 243 | //dayOfSchedule.dataRecovery(); | 255 | //dayOfSchedule.dataRecovery(); |
| 244 | /** 线调业务 */ | 256 | /** 线调业务 */ |
| @@ -260,7 +272,7 @@ public class XDApplication implements CommandLineRunner { | @@ -260,7 +272,7 @@ public class XDApplication implements CommandLineRunner { | ||
| 260 | WebSocketPushQueue.start();//消息队列 -webSocket ,推送至线调web页面的 | 272 | WebSocketPushQueue.start();//消息队列 -webSocket ,推送至线调web页面的 |
| 261 | 273 | ||
| 262 | /** 线调为其他程序提供的数据 --写入数据库 */ | 274 | /** 线调为其他程序提供的数据 --写入数据库 */ |
| 263 | - sexec.scheduleWithFixedDelay(fcxxUpdateThread, 160, 30, TimeUnit.SECONDS);//发车信息(发车屏、信息发布) | 275 | + //sexec.scheduleWithFixedDelay(fcxxUpdateThread, 160, 30, TimeUnit.SECONDS);//发车信息(发车屏、信息发布) |
| 264 | //线路首末班数据(网关用,班次更新时写入) | 276 | //线路首末班数据(网关用,班次更新时写入) |
| 265 | //com.bsth.data.schedule.f_a_l.FirstAndLastHandler | 277 | //com.bsth.data.schedule.f_a_l.FirstAndLastHandler |
| 266 | sexec.scheduleWithFixedDelay(schSiginUpdateDBThread, 160, 60 * 30, TimeUnit.SECONDS);//无法自动完成的班次信息(网关用,补信号) | 278 | sexec.scheduleWithFixedDelay(schSiginUpdateDBThread, 160, 60 * 30, TimeUnit.SECONDS);//无法自动完成的班次信息(网关用,补信号) |
| @@ -284,7 +296,7 @@ public class XDApplication implements CommandLineRunner { | @@ -284,7 +296,7 @@ public class XDApplication implements CommandLineRunner { | ||
| 284 | //安全驾驶 | 296 | //安全驾驶 |
| 285 | sexec.scheduleWithFixedDelay(safeDrivDataLoadThread, 180, 10, TimeUnit.SECONDS); | 297 | sexec.scheduleWithFixedDelay(safeDrivDataLoadThread, 180, 10, TimeUnit.SECONDS); |
| 286 | //智能调度 | 298 | //智能调度 |
| 287 | - sexec.scheduleWithFixedDelay(znddThread, 15, 30, TimeUnit.SECONDS); | 299 | + sexec.scheduleWithFixedDelay(znddThread, 15, 60, TimeUnit.SECONDS); |
| 288 | 300 | ||
| 289 | GpsDataLoaderThread.setFlag(-1); | 301 | GpsDataLoaderThread.setFlag(-1); |
| 290 | /** 线调业务 */ | 302 | /** 线调业务 */ |
src/main/java/com/bsth/controller/lg_travel/RegionConterller.java
0 → 100644
| 1 | +package com.bsth.controller.lg_travel; | ||
| 2 | + | ||
| 3 | +import com.bsth.controller.BaseController; | ||
| 4 | +import com.bsth.entity.lg_travel.Region; | ||
| 5 | +import org.springframework.web.bind.annotation.RequestMapping; | ||
| 6 | +import org.springframework.web.bind.annotation.RestController; | ||
| 7 | + | ||
| 8 | +/** | ||
| 9 | + * 区域 | ||
| 10 | + */ | ||
| 11 | + | ||
| 12 | +@RestController | ||
| 13 | +@RequestMapping("region") | ||
| 14 | +public class RegionConterller extends BaseController<Region, Long> { | ||
| 15 | + | ||
| 16 | + | ||
| 17 | +} |
src/main/java/com/bsth/controller/lg_travel/RegionLineCarConterller.java
0 → 100644
| 1 | +package com.bsth.controller.lg_travel; | ||
| 2 | + | ||
| 3 | +import com.bsth.controller.BaseController; | ||
| 4 | +import com.bsth.entity.lg_travel.RegionLineCar; | ||
| 5 | +import org.springframework.web.bind.annotation.RequestMapping; | ||
| 6 | +import org.springframework.web.bind.annotation.RestController; | ||
| 7 | + | ||
| 8 | +/** | ||
| 9 | + * 区域 | ||
| 10 | + */ | ||
| 11 | + | ||
| 12 | +@RestController | ||
| 13 | +@RequestMapping("regionLineCar") | ||
| 14 | +public class RegionLineCarConterller extends BaseController<RegionLineCar, Long> { | ||
| 15 | + | ||
| 16 | + | ||
| 17 | +} |
src/main/java/com/bsth/controller/oil/JdlController.java
| @@ -2,21 +2,22 @@ package com.bsth.controller.oil; | @@ -2,21 +2,22 @@ package com.bsth.controller.oil; | ||
| 2 | 2 | ||
| 3 | import java.io.File; | 3 | import java.io.File; |
| 4 | import java.util.HashMap; | 4 | import java.util.HashMap; |
| 5 | +import java.util.List; | ||
| 5 | import java.util.Map; | 6 | import java.util.Map; |
| 6 | 7 | ||
| 8 | +import javax.servlet.http.HttpServletResponse; | ||
| 9 | + | ||
| 7 | import org.springframework.beans.factory.annotation.Autowired; | 10 | import org.springframework.beans.factory.annotation.Autowired; |
| 8 | import org.springframework.web.bind.annotation.RequestMapping; | 11 | import org.springframework.web.bind.annotation.RequestMapping; |
| 9 | import org.springframework.web.bind.annotation.RequestMethod; | 12 | import org.springframework.web.bind.annotation.RequestMethod; |
| 10 | import org.springframework.web.bind.annotation.RequestParam; | 13 | import org.springframework.web.bind.annotation.RequestParam; |
| 11 | import org.springframework.web.bind.annotation.RestController; | 14 | import org.springframework.web.bind.annotation.RestController; |
| 12 | import org.springframework.web.multipart.MultipartFile; | 15 | import org.springframework.web.multipart.MultipartFile; |
| 13 | -import org.springframework.web.servlet.ModelAndView; | ||
| 14 | 16 | ||
| 15 | -import com.alibaba.fastjson.JSON; | ||
| 16 | -import com.alibaba.fastjson.JSONArray; | ||
| 17 | -import com.alibaba.fastjson.JSONObject; | ||
| 18 | import com.bsth.controller.BaseController; | 17 | import com.bsth.controller.BaseController; |
| 19 | import com.bsth.entity.oil.Jdl; | 18 | import com.bsth.entity.oil.Jdl; |
| 19 | +import com.bsth.entity.oil.JdlConnector; | ||
| 20 | +import com.bsth.entity.oil.JdlReception; | ||
| 20 | import com.bsth.service.oil.JdlService; | 21 | import com.bsth.service.oil.JdlService; |
| 21 | import com.google.common.io.Files; | 22 | import com.google.common.io.Files; |
| 22 | 23 | ||
| @@ -46,9 +47,87 @@ public class JdlController extends BaseController<Jdl, Integer> { | @@ -46,9 +47,87 @@ public class JdlController extends BaseController<Jdl, Integer> { | ||
| 46 | return "{\"result\":" + "\""+result+"\"}"; | 47 | return "{\"result\":" + "\""+result+"\"}"; |
| 47 | } | 48 | } |
| 48 | 49 | ||
| 50 | + /** 24年12月工单更新电量导入 */ | ||
| 51 | + @RequestMapping(value = "/uploadFile_2412",method = RequestMethod.POST) | ||
| 52 | + public String uploadFile_2412(MultipartFile file, String gsbm_, String gsName, | ||
| 53 | + String fgsbm_, String fgsName, String stationName) throws Exception{ | ||
| 54 | + File newFile = new File( | ||
| 55 | + getDataImportClasspath() + File.separator + | ||
| 56 | + file.getOriginalFilename()); | ||
| 57 | + Files.write(file.getBytes(), newFile); | ||
| 58 | + | ||
| 59 | + String result = jdlService.importExcel_2412(newFile, gsbm_, gsName, fgsbm_, fgsName, stationName); | ||
| 60 | + return "{\"result\":" + "\""+result+"\"}"; | ||
| 61 | + } | ||
| 62 | + | ||
| 49 | @RequestMapping(value = "/query",method = RequestMethod.GET) | 63 | @RequestMapping(value = "/query",method = RequestMethod.GET) |
| 50 | public Map<String, Object> query(@RequestParam Map<String, Object> map) throws Exception{ | 64 | public Map<String, Object> query(@RequestParam Map<String, Object> map) throws Exception{ |
| 51 | return jdlService.query(map); | 65 | return jdlService.query(map); |
| 52 | } | 66 | } |
| 53 | 67 | ||
| 68 | + @RequestMapping(value = "/query_2412",method = RequestMethod.GET) | ||
| 69 | + public Map<String, Object> query_2412(@RequestParam Map<String, Object> map) throws Exception{ | ||
| 70 | + return jdlService.query_2412(map); | ||
| 71 | + } | ||
| 72 | + | ||
| 73 | + @RequestMapping(value = "/queryJdlReception",method = RequestMethod.GET) | ||
| 74 | + public List<JdlReception> queryJdlReception(@RequestParam Map<String, Object> map) throws Exception{ | ||
| 75 | + return jdlService.queryJdlReception(map); | ||
| 76 | + } | ||
| 77 | + | ||
| 78 | + @RequestMapping(value = "/queryJdlReceptionBatch",method = RequestMethod.GET) | ||
| 79 | + public Map<String, Object> queryJdlReceptionBatch(@RequestParam Map<String, Object> map) throws Exception{ | ||
| 80 | + return jdlService.queryJdlReceptionBatch(map); | ||
| 81 | + } | ||
| 82 | + | ||
| 83 | + @RequestMapping(value = "/queryJdlReceptionBatchData",method = RequestMethod.GET) | ||
| 84 | + public List<JdlReception> queryJdlReceptionBatchData(@RequestParam Map<String, Object> map) throws Exception{ | ||
| 85 | + return jdlService.queryJdlReceptionBatchData(map); | ||
| 86 | + } | ||
| 87 | + | ||
| 88 | + @RequestMapping(value = "/deleteJdlReceptionBatch",method = RequestMethod.POST) | ||
| 89 | + public Map<String, Object> deleteJdlReceptionBatch(@RequestParam Map<String, Object> map) throws Exception{ | ||
| 90 | + return jdlService.deleteJdlReceptionBatch(map); | ||
| 91 | + } | ||
| 92 | + | ||
| 93 | + @RequestMapping(value = "/updateJdlReceptionBatch",method = RequestMethod.POST) | ||
| 94 | + public Map<String, Object> updateJdlReceptionBatch(@RequestParam Map<String, Object> map) throws Exception{ | ||
| 95 | + return jdlService.updateJdlReceptionBatch(map); | ||
| 96 | + } | ||
| 97 | + | ||
| 98 | + @RequestMapping(value = "/downloadJdlReceptionImportFile",method = RequestMethod.GET) | ||
| 99 | + public void downloadJdlReceptionImportFile(@RequestParam Map<String, Object> map, HttpServletResponse response) throws Exception{ | ||
| 100 | + jdlService.downloadJdlReceptionImportFile(map, response); | ||
| 101 | + } | ||
| 102 | + | ||
| 103 | + @RequestMapping(value = "/queryJdlConnector",method = RequestMethod.GET) | ||
| 104 | + public List<JdlConnector> queryJdlConnector(@RequestParam Map<String, Object> map) throws Exception{ | ||
| 105 | + return jdlService.queryJdlConnector(map); | ||
| 106 | + } | ||
| 107 | + | ||
| 108 | + @RequestMapping(value = "/queryJdlConnectorById",method = RequestMethod.GET) | ||
| 109 | + public JdlConnector queryJdlConnectorById(@RequestParam int id) throws Exception{ | ||
| 110 | + return jdlService.queryJdlConnectorById(id); | ||
| 111 | + } | ||
| 112 | + | ||
| 113 | + @RequestMapping(value = "/queryJdlStationName",method = RequestMethod.GET) | ||
| 114 | + public List<String> queryJdlStationName() throws Exception{ | ||
| 115 | + return jdlService.queryJdlStationName(); | ||
| 116 | + } | ||
| 117 | + | ||
| 118 | + @RequestMapping(value = "/addJdlConnector",method = RequestMethod.POST) | ||
| 119 | + public Map<String, Object> addJdlConnector(@RequestParam Map<String, Object> map) throws Exception{ | ||
| 120 | + return jdlService.addJdlConnector(map); | ||
| 121 | + } | ||
| 122 | + | ||
| 123 | + @RequestMapping(value = "/deleteJdlConnector",method = RequestMethod.POST) | ||
| 124 | + public Map<String, Object> deleteJdlConnector(@RequestParam Map<String, Object> map) throws Exception{ | ||
| 125 | + return jdlService.deleteJdlConnector(map); | ||
| 126 | + } | ||
| 127 | + | ||
| 128 | + @RequestMapping(value = "/updateJdlConnector",method = RequestMethod.POST) | ||
| 129 | + public Map<String, Object> updateJdlConnector(@RequestParam Map<String, Object> map) throws Exception{ | ||
| 130 | + return jdlService.updateJdlConnector(map); | ||
| 131 | + } | ||
| 132 | + | ||
| 54 | } | 133 | } |
src/main/java/com/bsth/controller/realcontrol/ServiceDataInterface.java
| @@ -87,6 +87,7 @@ public class ServiceDataInterface { | @@ -87,6 +87,7 @@ public class ServiceDataInterface { | ||
| 87 | if (null == sch) | 87 | if (null == sch) |
| 88 | continue; | 88 | continue; |
| 89 | map = new HashMap<>(); | 89 | map = new HashMap<>(); |
| 90 | + map.put("id", sch.getId()); | ||
| 90 | map.put("clZbh", sch.getClZbh()); | 91 | map.put("clZbh", sch.getClZbh()); |
| 91 | map.put("jGh", sch.getjGh()); | 92 | map.put("jGh", sch.getjGh()); |
| 92 | map.put("jName", sch.getjName()); | 93 | map.put("jName", sch.getjName()); |
src/main/java/com/bsth/controller/zndd/LoggerZnddController.java
| @@ -54,4 +54,15 @@ public class LoggerZnddController extends BaseController<LoggerZndd, Integer> { | @@ -54,4 +54,15 @@ public class LoggerZnddController extends BaseController<LoggerZndd, Integer> { | ||
| 54 | public Map<String, Object> schTZSF(String line,String date,String endDate,String changType,String type){ | 54 | public Map<String, Object> schTZSF(String line,String date,String endDate,String changType,String type){ |
| 55 | return loggerZnddService.schTZSF(line,date,endDate,changType,type); | 55 | return loggerZnddService.schTZSF(line,date,endDate,changType,type); |
| 56 | } | 56 | } |
| 57 | + | ||
| 58 | + /** | ||
| 59 | + * 获取当前方向下的下一个班次 | ||
| 60 | + * @param id | ||
| 61 | + * @return | ||
| 62 | + */ | ||
| 63 | + @RequestMapping(value = "nextSch/{id}", method = RequestMethod.GET) | ||
| 64 | + public ScheduleRealInfo nextSch(@PathVariable("id") Long id){ | ||
| 65 | + return loggerZnddService.nextSch(id); | ||
| 66 | + | ||
| 67 | + } | ||
| 57 | } | 68 | } |
src/main/java/com/bsth/controller/zndd/ZnddStatusController.java
| @@ -7,6 +7,7 @@ import com.bsth.service.zndd.ZnddStatusService; | @@ -7,6 +7,7 @@ import com.bsth.service.zndd.ZnddStatusService; | ||
| 7 | import org.springframework.beans.factory.annotation.Autowired; | 7 | import org.springframework.beans.factory.annotation.Autowired; |
| 8 | import org.springframework.web.bind.annotation.RequestMapping; | 8 | import org.springframework.web.bind.annotation.RequestMapping; |
| 9 | import org.springframework.web.bind.annotation.RequestMethod; | 9 | import org.springframework.web.bind.annotation.RequestMethod; |
| 10 | +import org.springframework.web.bind.annotation.RequestParam; | ||
| 10 | import org.springframework.web.bind.annotation.RestController; | 11 | import org.springframework.web.bind.annotation.RestController; |
| 11 | 12 | ||
| 12 | import java.util.HashMap; | 13 | import java.util.HashMap; |
| @@ -34,4 +35,21 @@ public class ZnddStatusController extends BaseController<znddStatus, Integer> { | @@ -34,4 +35,21 @@ public class ZnddStatusController extends BaseController<znddStatus, Integer> { | ||
| 34 | return result; | 35 | return result; |
| 35 | } | 36 | } |
| 36 | 37 | ||
| 38 | + | ||
| 39 | + /** | ||
| 40 | + *新增类型 | ||
| 41 | + * */ | ||
| 42 | + @RequestMapping(value = "/update", method = RequestMethod.POST) | ||
| 43 | + public Map<String, Object> update(@RequestParam Integer id, @RequestParam Integer openStatus) { | ||
| 44 | + Map<String, Object> result = new HashMap<>(); | ||
| 45 | + try { | ||
| 46 | + znddStatusService.update(id,openStatus); | ||
| 47 | + result.put("status", ResponseCode.SUCCESS); | ||
| 48 | + } catch (Exception e) { | ||
| 49 | + result.put("status", ResponseCode.ERROR); | ||
| 50 | + result.put("msg", e.getMessage()); | ||
| 51 | + } | ||
| 52 | + return result; | ||
| 53 | + } | ||
| 54 | + | ||
| 37 | } | 55 | } |
src/main/java/com/bsth/data/car_out_info/CarOutInfoHandler.java
| @@ -117,8 +117,8 @@ public class CarOutInfoHandler { | @@ -117,8 +117,8 @@ public class CarOutInfoHandler { | ||
| 117 | //删除 | 117 | //删除 |
| 118 | jdbcTemplate.update("delete from bsth_t_clfcxxb"); | 118 | jdbcTemplate.update("delete from bsth_t_clfcxxb"); |
| 119 | //重新写入 | 119 | //重新写入 |
| 120 | - jdbcTemplate.batchUpdate("insert into bsth_t_clfcxxb(rq, line_code, line_name, lp_name, lp_sn, dfsj, nbbm, cph, bc_type, end_station_name, updown, jGh, jName, remarks, sn)" + | ||
| 121 | - " VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)", new BatchPreparedStatementSetter() { | 120 | + jdbcTemplate.batchUpdate("insert into bsth_t_clfcxxb(rq, line_code, line_name, lp_name, lp_sn, dfsj, nbbm, cph, bc_type, end_station_name, updown, jGh, jName, remarks, sn, sch)" + |
| 121 | + " VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)", new BatchPreparedStatementSetter() { | ||
| 122 | @Override | 122 | @Override |
| 123 | public void setValues(PreparedStatement ps, int i) throws SQLException { | 123 | public void setValues(PreparedStatement ps, int i) throws SQLException { |
| 124 | ScheduleRealInfo sch = pstList.get(i); | 124 | ScheduleRealInfo sch = pstList.get(i); |
| @@ -137,6 +137,7 @@ public class CarOutInfoHandler { | @@ -137,6 +137,7 @@ public class CarOutInfoHandler { | ||
| 137 | ps.setString(13, sch.getjName()); | 137 | ps.setString(13, sch.getjName()); |
| 138 | ps.setString(14, sch.getRemarks()); | 138 | ps.setString(14, sch.getRemarks()); |
| 139 | ps.setInt(15, sch.getFcpSn()); | 139 | ps.setInt(15, sch.getFcpSn()); |
| 140 | + ps.setLong(16, sch.getId()); | ||
| 140 | } | 141 | } |
| 141 | 142 | ||
| 142 | @Override | 143 | @Override |
src/main/java/com/bsth/data/kl/KlData.java
| @@ -6,9 +6,10 @@ import org.slf4j.Logger; | @@ -6,9 +6,10 @@ import org.slf4j.Logger; | ||
| 6 | import org.slf4j.LoggerFactory; | 6 | import org.slf4j.LoggerFactory; |
| 7 | import org.springframework.beans.factory.annotation.Autowired; | 7 | import org.springframework.beans.factory.annotation.Autowired; |
| 8 | import org.springframework.beans.factory.annotation.Value; | 8 | import org.springframework.beans.factory.annotation.Value; |
| 9 | -import org.springframework.scheduling.annotation.Scheduled; | ||
| 10 | import org.springframework.stereotype.Component; | 9 | import org.springframework.stereotype.Component; |
| 11 | -import java.util.*; | 10 | + |
| 11 | +import java.util.HashMap; | ||
| 12 | +import java.util.Map; | ||
| 12 | 13 | ||
| 13 | /** | 14 | /** |
| 14 | * @author ym | 15 | * @author ym |
| @@ -30,7 +31,7 @@ public class KlData { | @@ -30,7 +31,7 @@ public class KlData { | ||
| 30 | @Value("${passengerFlow.url}") | 31 | @Value("${passengerFlow.url}") |
| 31 | private String url; | 32 | private String url; |
| 32 | 33 | ||
| 33 | - @Scheduled(cron = "0/10 * * * * ?") | 34 | + /* @Scheduled(cron = "0/10 * * * * ?") |
| 34 | public void loadKl() { | 35 | public void loadKl() { |
| 35 | Map<String,Kl> map= new HashMap<>(); | 36 | Map<String,Kl> map= new HashMap<>(); |
| 36 | List<Kl> list = klService.loadKl(); | 37 | List<Kl> list = klService.loadKl(); |
| @@ -40,7 +41,7 @@ public class KlData { | @@ -40,7 +41,7 @@ public class KlData { | ||
| 40 | map.put(kl.getDeviceId(),kl); | 41 | map.put(kl.getDeviceId(),kl); |
| 41 | } | 42 | } |
| 42 | KlData =map; | 43 | KlData =map; |
| 43 | - } | 44 | + }*/ |
| 44 | 45 | ||
| 45 | public static Kl getKl(String deviceId){ | 46 | public static Kl getKl(String deviceId){ |
| 46 | //return KlData.get( KlData.keySet().toArray()[0]); | 47 | //return KlData.get( KlData.keySet().toArray()[0]); |
src/main/java/com/bsth/data/pilot80/PilotReport.java
| 1 | package com.bsth.data.pilot80; | 1 | package com.bsth.data.pilot80; |
| 2 | 2 | ||
| 3 | +import com.alibaba.fastjson.JSON; | ||
| 3 | import com.alibaba.fastjson.JSONObject; | 4 | import com.alibaba.fastjson.JSONObject; |
| 4 | import com.bsth.data.BasicData; | 5 | import com.bsth.data.BasicData; |
| 5 | import com.bsth.data.LineConfigData; | 6 | import com.bsth.data.LineConfigData; |
| @@ -23,7 +24,10 @@ import org.slf4j.LoggerFactory; | @@ -23,7 +24,10 @@ import org.slf4j.LoggerFactory; | ||
| 23 | import org.springframework.beans.factory.annotation.Autowired; | 24 | import org.springframework.beans.factory.annotation.Autowired; |
| 24 | import org.springframework.stereotype.Component; | 25 | import org.springframework.stereotype.Component; |
| 25 | 26 | ||
| 26 | -import java.util.*; | 27 | +import java.util.ArrayList; |
| 28 | +import java.util.Collection; | ||
| 29 | +import java.util.Date; | ||
| 30 | +import java.util.List; | ||
| 27 | import java.util.concurrent.ConcurrentHashMap; | 31 | import java.util.concurrent.ConcurrentHashMap; |
| 28 | 32 | ||
| 29 | /** | 33 | /** |
| @@ -102,21 +106,11 @@ public class PilotReport { | @@ -102,21 +106,11 @@ public class PilotReport { | ||
| 102 | } | 106 | } |
| 103 | break; | 107 | break; |
| 104 | //报警请求 | 108 | //报警请求 |
| 105 | - case 0x10: | ||
| 106 | - try { | ||
| 107 | - String url = systemParamService.getValue("url.yjbj")+"dataDockingApi/accident/saveAccident?"; | ||
| 108 | - url = url + "accidentTime=" + new Date().getTime() + "&nbbm=" + nbbm; | ||
| 109 | - logger.info("url===="+url); | ||
| 110 | - String res = HttpClientUtils.get(url).toString(); | ||
| 111 | - JSONObject jsonObject = JSONObject.parseObject(res); | ||
| 112 | - if ((int) jsonObject.get("code") == 200) { | ||
| 113 | - logger.info("报警请求成功"); | ||
| 114 | - }else { | ||
| 115 | - logger.info("报警请求失败"); | ||
| 116 | - } | ||
| 117 | - }catch (Exception e){ | ||
| 118 | - logger.info("报警请求异常"); | ||
| 119 | - } | 109 | + case 0x21: |
| 110 | + case 0x22: | ||
| 111 | + case 0x23: | ||
| 112 | + case 0x24: | ||
| 113 | + yjbj(nbbm,d80); | ||
| 120 | break; | 114 | break; |
| 121 | } | 115 | } |
| 122 | 116 | ||
| @@ -132,6 +126,39 @@ public class PilotReport { | @@ -132,6 +126,39 @@ public class PilotReport { | ||
| 132 | } | 126 | } |
| 133 | } | 127 | } |
| 134 | 128 | ||
| 129 | + public void yjbj(String nbbm,D80 d80){ | ||
| 130 | + try { | ||
| 131 | + ScheduleRealInfo sch = null; | ||
| 132 | + | ||
| 133 | + if (d80.getData().getStopNo() != null && !d80.getData().getStopNo().equals("")){ | ||
| 134 | + d80.setStationName(BasicData.stationCode2NameMap.get(d80.getData().getStopNo())); | ||
| 135 | + } | ||
| 136 | + if (d80.getSchId() != null){ | ||
| 137 | + sch = dayOfSchedule.get(d80.getSchId()); | ||
| 138 | + Long nextschid = dayOfSchedule.nextByLp(sch).getId(); | ||
| 139 | + d80.setNextschId(nextschid); | ||
| 140 | + } | ||
| 141 | + String url = systemParamService.getValue("url.yjbj")+"dataDockingApi/accident/saveAccident?"; | ||
| 142 | + url = url + "accidentTime=" + new Date().getTime() + "&nbbm=" + nbbm +"&requestCode=" +d80.getData().getRequestCode() | ||
| 143 | + +"&lon=" +d80.getData().getLon()+"&lat="+d80.getData().getLat(); | ||
| 144 | + if (sch != null){ | ||
| 145 | + url = url + "&lineName=" +sch.getXlName()+"&jsy=" +sch.getjGh()+"&jsName=" +sch.getjName(); | ||
| 146 | + } | ||
| 147 | + logger.info("url===="+url); | ||
| 148 | + StringBuilder sb = HttpClientUtils.get(url); | ||
| 149 | + | ||
| 150 | + | ||
| 151 | + JSONObject jsonObject = JSON.parseObject(sb.toString()); | ||
| 152 | + if ((int) jsonObject.get("code") == 200) { | ||
| 153 | + logger.info("报警请求成功=" + jsonObject.get("msg")); | ||
| 154 | + }else { | ||
| 155 | + logger.info("报警请求失败="+ jsonObject.get("msg")); | ||
| 156 | + } | ||
| 157 | + }catch (Exception e){ | ||
| 158 | + logger.info("报警请求异常",e); | ||
| 159 | + } | ||
| 160 | + } | ||
| 161 | + | ||
| 135 | public void report(DC0_A4 c0a4) { | 162 | public void report(DC0_A4 c0a4) { |
| 136 | String deviceId = c0a4.getData().getDeviceId(); | 163 | String deviceId = c0a4.getData().getDeviceId(); |
| 137 | if (StringUtils.isNotEmpty(deviceId)) | 164 | if (StringUtils.isNotEmpty(deviceId)) |
src/main/java/com/bsth/data/zndd/AutomaticSch.java
| 1 | package com.bsth.data.zndd; | 1 | package com.bsth.data.zndd; |
| 2 | 2 | ||
| 3 | import com.alibaba.fastjson.JSON; | 3 | import com.alibaba.fastjson.JSON; |
| 4 | +import com.alibaba.fastjson.JSONArray; | ||
| 4 | import com.alibaba.fastjson.JSONObject; | 5 | import com.alibaba.fastjson.JSONObject; |
| 5 | import com.alibaba.fastjson.TypeReference; | 6 | import com.alibaba.fastjson.TypeReference; |
| 6 | import com.bsth.data.BasicData; | 7 | import com.bsth.data.BasicData; |
| @@ -8,18 +9,24 @@ import com.bsth.data.adjg.domain.LargeGap; | @@ -8,18 +9,24 @@ import com.bsth.data.adjg.domain.LargeGap; | ||
| 8 | import com.bsth.data.directive.DayOfDirectives; | 9 | import com.bsth.data.directive.DayOfDirectives; |
| 9 | import com.bsth.data.gpsdata_v2.GpsRealData; | 10 | import com.bsth.data.gpsdata_v2.GpsRealData; |
| 10 | import com.bsth.data.gpsdata_v2.entity.GpsEntity; | 11 | import com.bsth.data.gpsdata_v2.entity.GpsEntity; |
| 12 | +import com.bsth.data.gpsdata_v2.rfid.RfidHttpLoader; | ||
| 13 | +import com.bsth.data.gpsdata_v2.rfid.entity.RfidInfo; | ||
| 11 | import com.bsth.data.schedule.DayOfSchedule; | 14 | import com.bsth.data.schedule.DayOfSchedule; |
| 12 | import com.bsth.data.schedule.ScheduleComparator; | 15 | import com.bsth.data.schedule.ScheduleComparator; |
| 16 | +import com.bsth.data.schedule.edit_logs.entity.SchEditInfo; | ||
| 17 | +import com.bsth.data.schedule.edit_logs.service.SchEditInfoService; | ||
| 13 | import com.bsth.data.schedule.late_adjust.LateAdjustHandle; | 18 | import com.bsth.data.schedule.late_adjust.LateAdjustHandle; |
| 14 | import com.bsth.entity.directive.D60; | 19 | import com.bsth.entity.directive.D60; |
| 15 | import com.bsth.entity.realcontrol.ScheduleRealInfo; | 20 | import com.bsth.entity.realcontrol.ScheduleRealInfo; |
| 21 | +import com.bsth.entity.zndd.StationPeopleLogger; | ||
| 16 | import com.bsth.entity.zndd.ZnddYuAn; | 22 | import com.bsth.entity.zndd.ZnddYuAn; |
| 17 | import com.bsth.repository.StationRouteRepository; | 23 | import com.bsth.repository.StationRouteRepository; |
| 18 | import com.bsth.service.directive.DirectiveService; | 24 | import com.bsth.service.directive.DirectiveService; |
| 19 | import com.bsth.service.realcontrol.ScheduleRealInfoService; | 25 | import com.bsth.service.realcontrol.ScheduleRealInfoService; |
| 26 | +import com.bsth.service.zndd.ZnddLoggerService; | ||
| 20 | import com.bsth.service.zndd.ZnddYuAnService; | 27 | import com.bsth.service.zndd.ZnddYuAnService; |
| 28 | +import com.bsth.util.DateUtils; | ||
| 21 | import com.bsth.util.HttpClientUtils; | 29 | import com.bsth.util.HttpClientUtils; |
| 22 | -import com.google.gson.Gson; | ||
| 23 | import org.apache.commons.lang3.StringUtils; | 30 | import org.apache.commons.lang3.StringUtils; |
| 24 | import org.slf4j.Logger; | 31 | import org.slf4j.Logger; |
| 25 | import org.slf4j.LoggerFactory; | 32 | import org.slf4j.LoggerFactory; |
| @@ -29,8 +36,6 @@ import org.springframework.stereotype.Component; | @@ -29,8 +36,6 @@ import org.springframework.stereotype.Component; | ||
| 29 | import java.text.ParseException; | 36 | import java.text.ParseException; |
| 30 | import java.text.SimpleDateFormat; | 37 | import java.text.SimpleDateFormat; |
| 31 | import java.util.*; | 38 | import java.util.*; |
| 32 | -import java.util.concurrent.ConcurrentHashMap; | ||
| 33 | -import java.util.concurrent.ConcurrentMap; | ||
| 34 | import java.util.regex.Matcher; | 39 | import java.util.regex.Matcher; |
| 35 | import java.util.regex.Pattern; | 40 | import java.util.regex.Pattern; |
| 36 | 41 | ||
| @@ -62,38 +67,77 @@ public class AutomaticSch { | @@ -62,38 +67,77 @@ public class AutomaticSch { | ||
| 62 | @Autowired | 67 | @Autowired |
| 63 | ZnddYuAnService znddYuAnService; | 68 | ZnddYuAnService znddYuAnService; |
| 64 | 69 | ||
| 65 | - Queue<Map> queue = new LinkedList<>(); | 70 | + @Autowired |
| 71 | + ZnddLoggerService znddLoggerService; | ||
| 72 | + @Autowired | ||
| 73 | + SchEditInfoService schEditInfoService; | ||
| 74 | + | ||
| 66 | 75 | ||
| 67 | private static SimpleDateFormat sdfHHmm = new SimpleDateFormat("HH:mm"); | 76 | private static SimpleDateFormat sdfHHmm = new SimpleDateFormat("HH:mm"); |
| 77 | + private static SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"); | ||
| 68 | SimpleDateFormat sdf=new SimpleDateFormat("yyyy-MM-dd HH:mm"); | 78 | SimpleDateFormat sdf=new SimpleDateFormat("yyyy-MM-dd HH:mm"); |
| 69 | 79 | ||
| 70 | private static Comparator<ScheduleRealInfo> cpm = new ScheduleComparator.DFSJ2(); | 80 | private static Comparator<ScheduleRealInfo> cpm = new ScheduleComparator.DFSJ2(); |
| 71 | private Map<String,Long> drivreMap =new HashMap<>(); //自动重发map | 81 | private Map<String,Long> drivreMap =new HashMap<>(); //自动重发map |
| 72 | - // 当日60指令缓存 | ||
| 73 | - private ConcurrentMap<Integer, D60> d60Map = new ConcurrentHashMap<>();//d60map | ||
| 74 | 82 | ||
| 75 | - String urldkl = "http://10.10.200.202:5580/monitor/api/getMonitorInfoByDay?key=1&solt=1111&t=1&dayStr=2024-10-23"; //大间隔接口 | 83 | + String urldkl = "http://10.10.200.202:5580/monitor/api/getMonitorInfoByDay?key=1&solt=1111&t=1&dayStr="; //大间隔接口 |
| 76 | 84 | ||
| 77 | //http://10.10.200.201:8083/wxk-prod-api/service-api/lggj/schedule/drByInfo 维修接口 | 85 | //http://10.10.200.201:8083/wxk-prod-api/service-api/lggj/schedule/drByInfo 维修接口 |
| 78 | - | ||
| 79 | - private Map<String,Long> SFMAP = new HashMap<>(); | 86 | + String urldkls = "http://10.10.200.140:13089/bsth_passengerflow/klbus/currentInsideNum.do"; //满载接口 |
| 87 | + private Map<Long,Long> SFMAP = new HashMap<>(); | ||
| 80 | 88 | ||
| 81 | //满载 | 89 | //满载 |
| 82 | public void mz(){ | 90 | public void mz(){ |
| 83 | try { | 91 | try { |
| 92 | + StringBuilder sb = HttpClientUtils.get(urldkls); | ||
| 93 | + List<Object> list = JSONArray.parseArray(String.valueOf(sb)); | ||
| 94 | + for (Object b :list){ | ||
| 95 | + Map m = (Map) b; | ||
| 96 | + Integer num = Integer.parseInt(m.get("inside_num").toString()); | ||
| 97 | + | ||
| 98 | + int count= getPenum("MZ","0"); | ||
| 99 | + if(num < count){//大间隔阈值 检测到超过15个人的时候推送 | ||
| 100 | + return; | ||
| 101 | + } | ||
| 102 | + ScheduleRealInfo sr = dayOfSchedule.executeCurr(m.get("nbbm").toString()); //查询当前车辆执行班次 | ||
| 103 | + GpsEntity gps = gpsRealData.get(m.get("sbbh").toString()); | ||
| 104 | + Map msp = new HashMap(); | ||
| 105 | + msp.put("lineCode",m.get("xlbm")); | ||
| 106 | + msp.put("lineName",m.get("XLMC")); | ||
| 107 | + msp.put("stationName",gps.getStationName()); | ||
| 108 | + msp.put("rqStr",sdfMonth.format(new Date())); | ||
| 109 | + msp.put("rq",sdfHHmm.format(new Date())); | ||
| 110 | + msp.put("type","MZ"); | ||
| 111 | + msp.put("xlDir",gps.getUpDown()); | ||
| 112 | + msp.put("fcsj",""); | ||
| 113 | + msp.put("clzbh",gps.getNbbm()); | ||
| 114 | + msp.put("numType",num); | ||
| 115 | + if (sr != null ) | ||
| 116 | + msp.put("xlDir",sr.getXlDir()); | ||
| 117 | + | ||
| 118 | + if (gps != null ) | ||
| 119 | + msp.put("station",gps.getStation().getCode()); | ||
| 120 | + | ||
| 121 | + ts(msp); | ||
| 122 | + LogerWait("满载",sr); | ||
| 123 | + } | ||
| 84 | 124 | ||
| 85 | - List<ScheduleRealInfo> sr = dayOfSchedule.findByBcType("W9G-041","normal"); | 125 | + //测试使用 |
| 126 | + /* List<ScheduleRealInfo> sr = dayOfSchedule.findByBcType("W9G-041","normal"); | ||
| 86 | ts(addStationPeople(sr.get(5), "MZ", 0L));//第二种 设备未离线 出站时间内未出站 | 127 | ts(addStationPeople(sr.get(5), "MZ", 0L));//第二种 设备未离线 出站时间内未出站 |
| 128 | + | ||
| 129 | + String chartStr = JSON.toJSONString(sr.get(5)); | ||
| 130 | + logger.info("满载--"+chartStr);*/ | ||
| 87 | } | 131 | } |
| 88 | catch (Exception e){ | 132 | catch (Exception e){ |
| 89 | - logger.error("满载------------------",e); | 133 | + logger.error("满载检测接口出错------------------",e); |
| 90 | } | 134 | } |
| 91 | } | 135 | } |
| 92 | 136 | ||
| 93 | //大间隔的情况 | 137 | //大间隔的情况 |
| 94 | public void dfTz(int k ){ | 138 | public void dfTz(int k ){ |
| 95 | try{ | 139 | try{ |
| 96 | - StringBuilder sb = HttpClientUtils.get(urldkl /*+ sdfMonth.format(new Date())*/); | 140 | + StringBuilder sb = HttpClientUtils.get(urldkl + sdfMonth.format(new Date())); |
| 97 | if (sb == null) | 141 | if (sb == null) |
| 98 | return; | 142 | return; |
| 99 | JSONObject obj = JSON.parseObject(sb.toString()); | 143 | JSONObject obj = JSON.parseObject(sb.toString()); |
| @@ -106,44 +150,39 @@ public class AutomaticSch { | @@ -106,44 +150,39 @@ public class AutomaticSch { | ||
| 106 | }else { | 150 | }else { |
| 107 | continue; | 151 | continue; |
| 108 | } | 152 | } |
| 109 | - if (k == 0 ){ | ||
| 110 | - if(lg.getlGType() == 0){ | ||
| 111 | - ts(ConvertDJK(lg,sch,"FCJG")); | 153 | + Long t0 = new Date().getTime() - (1000 * 60 * 2); |
| 154 | + Long t1 = t0 - (1000 * 60 * 2); | ||
| 155 | + Long t2 = t0 + (1000 * 60 * 2); | ||
| 156 | + //判断当前间隔是否出现过并且在当前时间段内 大于2分钟 小于1分钟的时间之内 | ||
| 157 | + if (SFMAP.get(lg.getId()) == null) { | ||
| 158 | + if (k == 0) { | ||
| 159 | + if (lg.getlGType() == 0) { | ||
| 160 | + ts(ConvertDJK(lg, sch, "FCJG")); | ||
| 161 | + SFMAP.put(lg.getId(), lg.getTsTime()); | ||
| 162 | + LogerWait("发车大间隔",sch); | ||
| 163 | + } | ||
| 164 | + } else { | ||
| 165 | + if (lg.getlGType() != 0) { | ||
| 166 | + ts(ConvertDJK(lg, sch, "DJG")); | ||
| 167 | + SFMAP.put(lg.getId(), lg.getTsTime()); | ||
| 168 | + LogerWait("行车大间隔",sch); | ||
| 169 | + } | ||
| 112 | } | 170 | } |
| 113 | - }else { | ||
| 114 | - if(lg.getlGType() != 0){ | ||
| 115 | - ts(ConvertDJK(lg,sch,"DJG")); | 171 | + } |
| 172 | + //大于10000条的时候开始清理map | ||
| 173 | + if (SFMAP.size() > 10000){ | ||
| 174 | + for (Map.Entry<Long, Long> m : SFMAP.entrySet()){ | ||
| 175 | + if(m.getValue() < DateUtils.getTimestamp()){ | ||
| 176 | + SFMAP.remove(m.getKey()); | ||
| 177 | + } | ||
| 116 | } | 178 | } |
| 117 | } | 179 | } |
| 118 | - | ||
| 119 | } | 180 | } |
| 120 | 181 | ||
| 121 | }catch (Exception e){ | 182 | }catch (Exception e){ |
| 122 | logger.error("大间隔推送失败------------------",e); | 183 | logger.error("大间隔推送失败------------------",e); |
| 123 | } | 184 | } |
| 124 | } | 185 | } |
| 125 | - //发现大客流 -> 大客流情况 ->处置大客流 | ||
| 126 | - public void Dkl(){ | ||
| 127 | - //推送 | ||
| 128 | - | ||
| 129 | - try{ | ||
| 130 | - Map m = queue.poll(); | ||
| 131 | - if (m != null) { | ||
| 132 | - if (Integer.valueOf(m.get("num").toString()) > 15) { | ||
| 133 | - //超过10的时候 判断为大客流 | ||
| 134 | - ts(ConvertDKL(m)); | ||
| 135 | - } | ||
| 136 | - } | ||
| 137 | - | ||
| 138 | - ScheduleRealInfo sr = dayOfSchedule.findByNbbm("W8A-027").get(0); | ||
| 139 | - ts(addStationPeople(sr, "DKL", 0L));//大客流 | ||
| 140 | - | ||
| 141 | - | ||
| 142 | - }catch (Exception e){ | ||
| 143 | - logger.error("大客流推送失败------------------",e); | ||
| 144 | - } | ||
| 145 | - | ||
| 146 | - } | ||
| 147 | 186 | ||
| 148 | //实发未发检测 -- 车辆GPS掉线的情况下,车辆该出站了 | 187 | //实发未发检测 -- 车辆GPS掉线的情况下,车辆该出站了 |
| 149 | /** | 188 | /** |
| @@ -175,18 +214,33 @@ public class AutomaticSch { | @@ -175,18 +214,33 @@ public class AutomaticSch { | ||
| 175 | //1。一直没收到gps | 214 | //1。一直没收到gps |
| 176 | //2.gps长时间离线的情况下 | 215 | //2.gps长时间离线的情况下 |
| 177 | //3.人为调整过的都跳过 | 216 | //3.人为调整过的都跳过 |
| 178 | - if (gps == null || gps.getTimestamp() + (1000 * 60 * 3) < time || (gps.getAbnormalStatus() != null && gps.getAbnormalStatus().equals("offline"))) { | ||
| 179 | - ts(addStationPeople(sr, "SFTZ_1", 0L)); | ||
| 180 | - Gson gson = new Gson(); | ||
| 181 | - String chartStr = gson.toJsonTree(sr).toString(); | ||
| 182 | - logger.info("实发调整--" + chartStr); | 217 | + if (gps == null || gps.getTimestamp() + (1000 * 60 * 5) < time || (gps.getAbnormalStatus() != null && gps.getAbnormalStatus().equals("offline"))) { |
| 218 | + String sfsj = null; | ||
| 219 | + //rfid 判断 | ||
| 220 | + List<RfidInfo> list = RfidHttpLoader.load(); | ||
| 221 | + for (RfidInfo ri : list) { | ||
| 222 | + if (ri.getRecogTime() != null && ri.getRecogTime().getTime() > System.currentTimeMillis() - 300000) { | ||
| 223 | + //最新的rfid是出站状态 | ||
| 224 | + if (ri.getNbbm().equals(sr.getClZbh())){ | ||
| 225 | + sfsj = sdfHHmm.format(ri.getInoutStation().getTimestamp()); | ||
| 226 | + } | ||
| 227 | + if (ri.getNbbm().equals(sr.getClZbh()) && ri.getInoutStation().getInout() == 0) { | ||
| 228 | + sfsj = sdfHHmm.format(ri.getInoutStation().getTimestamp()); | ||
| 229 | + } | ||
| 230 | + } | ||
| 231 | + } | ||
| 232 | + if (sfsj != null){ | ||
| 233 | + sr.setFcsjActual(sfsj); | ||
| 234 | + ts(addStationPeople(sr, "SFTZ_1", 0L)); | ||
| 235 | + LogerWait("实发调整",sr); | ||
| 236 | + } | ||
| 183 | } | 237 | } |
| 184 | } | 238 | } |
| 185 | } | 239 | } |
| 186 | } | 240 | } |
| 187 | 241 | ||
| 188 | } | 242 | } |
| 189 | - }catch (Exception e){ | 243 | + }catch (Throwable e){ |
| 190 | logger.error("自动调度,实发未发推送失败---",e); | 244 | logger.error("自动调度,实发未发推送失败---",e); |
| 191 | } | 245 | } |
| 192 | logger.warn("实发未发扫描结束"); | 246 | logger.warn("实发未发扫描结束"); |
| @@ -196,6 +250,7 @@ public class AutomaticSch { | @@ -196,6 +250,7 @@ public class AutomaticSch { | ||
| 196 | public void sfCX(){ | 250 | public void sfCX(){ |
| 197 | //查询所有班次 | 251 | //查询所有班次 |
| 198 | //remark 人工干预过的的不检测 | 252 | //remark 人工干预过的的不检测 |
| 253 | + logger.warn("实发撤销检测扫描开始"); | ||
| 199 | try { | 254 | try { |
| 200 | 255 | ||
| 201 | Map<String, String> lineMap = BasicData.lineCode2NameMap; | 256 | Map<String, String> lineMap = BasicData.lineCode2NameMap; |
| @@ -211,8 +266,7 @@ public class AutomaticSch { | @@ -211,8 +266,7 @@ public class AutomaticSch { | ||
| 211 | for (ScheduleRealInfo t : oldSchDateList){ | 266 | for (ScheduleRealInfo t : oldSchDateList){ |
| 212 | // 发车误点 | 267 | // 发车误点 |
| 213 | if (t.getDfsj() != null && t.getFcsjActual() != null | 268 | if (t.getDfsj() != null && t.getFcsjActual() != null |
| 214 | - && (t.getBcType().equals("normal") || t.getBcType().equals("region")) | ||
| 215 | - && (StringUtils.isEmpty(t.getRemarks()) || t.getRemarks().equals("_智能调度-异常实发"))) { | 269 | + && (t.getBcType().equals("normal") || t.getBcType().equals("region"))) { |
| 216 | 270 | ||
| 217 | long sjc = t.getFcsjActualTime() - t.getDfsjT(); | 271 | long sjc = t.getFcsjActualTime() - t.getDfsjT(); |
| 218 | long time = System.currentTimeMillis();//当前时间 | 272 | long time = System.currentTimeMillis();//当前时间 |
| @@ -222,20 +276,35 @@ public class AutomaticSch { | @@ -222,20 +276,35 @@ public class AutomaticSch { | ||
| 222 | if (sjc >= -1 * 60 * 1000 && sjc <= 3 * 60 * 1000) { | 276 | if (sjc >= -1 * 60 * 1000 && sjc <= 3 * 60 * 1000) { |
| 223 | continue; | 277 | continue; |
| 224 | } else { | 278 | } else { |
| 279 | + //备注不为null时,查询是否有调度操作记录 | ||
| 280 | + List<SchEditInfo> seiList = new ArrayList<>(); | ||
| 281 | + if (!StringUtils.isEmpty(t.getRemarks())){ | ||
| 282 | + Map msp = new HashMap(); | ||
| 283 | + msp.put("schId_eq",t.getId()); | ||
| 284 | + seiList = (List<SchEditInfo>) schEditInfoService.list(msp); | ||
| 285 | + //有操作记录的跳过 | ||
| 286 | + Boolean isCZ = false; | ||
| 287 | + for(SchEditInfo e : seiList){ | ||
| 288 | + if (e.getType().equals("FCXXWT") || e.getType().equals("DFTZ") || e.getType().equals("SFTZ")){ | ||
| 289 | + isCZ = true; | ||
| 290 | + } | ||
| 291 | + } | ||
| 292 | + if (isCZ) | ||
| 293 | + continue; | ||
| 294 | + } | ||
| 225 | //异常实发 | 295 | //异常实发 |
| 226 | ts(addStationPeople(t, "YCSF", 0l)); | 296 | ts(addStationPeople(t, "YCSF", 0l)); |
| 227 | - Gson gson = new Gson(); | ||
| 228 | - String chartStr = gson.toJsonTree(t).toString(); | ||
| 229 | - logger.info("实发撤销--" + chartStr); | 297 | + LogerWait("实发撤销",t); |
| 230 | } | 298 | } |
| 231 | } | 299 | } |
| 232 | } | 300 | } |
| 233 | 301 | ||
| 234 | } | 302 | } |
| 235 | } | 303 | } |
| 236 | - }catch (Exception e){ | 304 | + }catch (Throwable e){ |
| 237 | logger.error("实发撤销推送接口出错-----------",e); | 305 | logger.error("实发撤销推送接口出错-----------",e); |
| 238 | } | 306 | } |
| 307 | + logger.warn("实发撤销检测扫描结束"); | ||
| 239 | } | 308 | } |
| 240 | 309 | ||
| 241 | public Boolean isLines(String line) { | 310 | public Boolean isLines(String line) { |
| @@ -273,8 +342,7 @@ public class AutomaticSch { | @@ -273,8 +342,7 @@ public class AutomaticSch { | ||
| 273 | String lineCode; | 342 | String lineCode; |
| 274 | for (Map.Entry<String, String> ts : lineMap.entrySet()) { | 343 | for (Map.Entry<String, String> ts : lineMap.entrySet()) { |
| 275 | lineCode = ts.getKey(); | 344 | lineCode = ts.getKey(); |
| 276 | - if(isLines(lineCode)) { | ||
| 277 | - | 345 | + /* if(isLines(lineCode)) {*/ |
| 278 | oldSchDateList = dayOfSchedule.findByLineCode(lineCode); | 346 | oldSchDateList = dayOfSchedule.findByLineCode(lineCode); |
| 279 | for (ScheduleRealInfo t : oldSchDateList) { | 347 | for (ScheduleRealInfo t : oldSchDateList) { |
| 280 | //指令重发 | 348 | //指令重发 |
| @@ -297,10 +365,10 @@ public class AutomaticSch { | @@ -297,10 +365,10 @@ public class AutomaticSch { | ||
| 297 | //下发时间未超过5分钟返回 | 365 | //下发时间未超过5分钟返回 |
| 298 | } | 366 | } |
| 299 | } | 367 | } |
| 300 | - } | 368 | + /*}*/ |
| 301 | } | 369 | } |
| 302 | } | 370 | } |
| 303 | - }catch (Exception e){ | 371 | + }catch (Throwable e){ |
| 304 | logger.error("自动调度,指令重发---",e); | 372 | logger.error("自动调度,指令重发---",e); |
| 305 | } | 373 | } |
| 306 | logger.warn("指令重发扫描结束"); | 374 | logger.warn("指令重发扫描结束"); |
| @@ -319,8 +387,8 @@ public class AutomaticSch { | @@ -319,8 +387,8 @@ public class AutomaticSch { | ||
| 319 | if(sch.getDfsjT() > t) | 387 | if(sch.getDfsjT() > t) |
| 320 | break; | 388 | break; |
| 321 | 389 | ||
| 322 | - /*if(sch.isLate()) //演示使用 不跳过 | ||
| 323 | - continue;*/ | 390 | + if(sch.isLate()) //演示使用 不跳过 |
| 391 | + continue; | ||
| 324 | 392 | ||
| 325 | if(sch.getStatus() == 0 | 393 | if(sch.getStatus() == 0 |
| 326 | && StringUtils.isEmpty(sch.getFcsjActual())){ | 394 | && StringUtils.isEmpty(sch.getFcsjActual())){ |
| @@ -336,10 +404,8 @@ public class AutomaticSch { | @@ -336,10 +404,8 @@ public class AutomaticSch { | ||
| 336 | for (Map m : dzList){ | 404 | for (Map m : dzList){ |
| 337 | if (basicData.nbbmCompanyPlateMap.get(prev.getClZbh()) != null && m.get("terminal").equals(basicData.nbbmCompanyPlateMap.get(prev.getClZbh()).replaceAll("-",""))){ | 405 | if (basicData.nbbmCompanyPlateMap.get(prev.getClZbh()) != null && m.get("terminal").equals(basicData.nbbmCompanyPlateMap.get(prev.getClZbh()).replaceAll("-",""))){ |
| 338 | sch.setRemark(m.get("sj").toString()); | 406 | sch.setRemark(m.get("sj").toString()); |
| 339 | - Gson gson = new Gson(); | ||
| 340 | - String chartStr = gson.toJsonTree(sch).toString(); | ||
| 341 | - logger.info("误点--"+chartStr); | ||
| 342 | ts(addStationPeople(sch, "WD", 0L)); | 407 | ts(addStationPeople(sch, "WD", 0L)); |
| 408 | + LogerWait("误点",sch); | ||
| 343 | } | 409 | } |
| 344 | } | 410 | } |
| 345 | } | 411 | } |
| @@ -353,31 +419,85 @@ public class AutomaticSch { | @@ -353,31 +419,85 @@ public class AutomaticSch { | ||
| 353 | } | 419 | } |
| 354 | 420 | ||
| 355 | 421 | ||
| 422 | + public void LogerWait(String type,ScheduleRealInfo sch){ | ||
| 423 | + String chartStr = "id-"+sch.getId() +",xlName-"+sch.getXlName() + ",fcsj-"+sch.getFcsj() + ",FcsjActual-"+ sch.getFcsjActual()+",clzbh-" + sch.getClZbh(); | ||
| 424 | + logger.info(type+"--" + chartStr); | ||
| 425 | + } | ||
| 356 | 426 | ||
| 357 | - public void ts(Map m) throws ParseException { | ||
| 358 | - //记录存一下 --超过当前时间的是否推送? | ||
| 359 | - String st = m.get("lineCode")+"_"+m.get("type")+"_"+m.get("rqStr"); | ||
| 360 | - Long sj = sdf.parse(m.get("rqStr").toString() +" "+ m.get("rq")).getTime(); | ||
| 361 | - Long dsj = new Date().getTime(); | ||
| 362 | - List<Long> list = new ArrayList(); | ||
| 363 | - //111_DJG_2024-06-24 | ||
| 364 | - if (ZnddThread.ZNDDTYPEMAP.get(st) != null ) { | ||
| 365 | - list = ZnddThread.ZNDDTYPEMAP.get(st); | ||
| 366 | - int i = 0; | ||
| 367 | - | ||
| 368 | - for (Long s : list){ //推送过的同样情况1小时内 &&//超过当前时间的不推送&& sj < dsj | ||
| 369 | - if (Math.abs(s - sj) > (60 * 60 * 1000)){ | ||
| 370 | - i ++ ; | 427 | + /** |
| 428 | + *每辆车倒数第二个班次执行之前3分钟提示 | ||
| 429 | + */ | ||
| 430 | + public void TowdescSch(){ | ||
| 431 | + logger.warn("末二班车执行方法开始"); | ||
| 432 | + try { | ||
| 433 | + //获取所有线路 | ||
| 434 | + Map<String, String> lineMap = BasicData.lineCode2NameMap; | ||
| 435 | + //findByNbbm车辆索引获取的班次 | ||
| 436 | + Map<String, List<ScheduleRealInfo>> groupedByCity = new HashMap<>(); | ||
| 437 | + if(System.currentTimeMillis() < DateUtils.getTimestamp() + (1000 * 60 * 60 * 20)){ | ||
| 438 | + logger.info("未到晚上8点----"+(DateUtils.getTimestamp() + (1000 * 60 * 60 * 20))); | ||
| 439 | + return; | ||
| 440 | + } | ||
| 441 | + | ||
| 442 | + for (Map.Entry<String, String> t : lineMap.entrySet()) { | ||
| 443 | + List<ScheduleRealInfo> srList = dayOfSchedule.findByLineCode(t.getKey()); | ||
| 444 | + Map<String, List<ScheduleRealInfo>> mapType = new HashMap(); | ||
| 445 | + //所有车辆 | ||
| 446 | + for (ScheduleRealInfo s : srList) { | ||
| 447 | + if (mapType.get(s.getClZbh()) != null) | ||
| 448 | + continue; | ||
| 449 | + | ||
| 450 | + List<ScheduleRealInfo> schadd = new ArrayList<>(); | ||
| 451 | + //每辆车下的班次 | ||
| 452 | + for (ScheduleRealInfo sch : srList) { | ||
| 453 | + if (s.getClZbh().equals(sch.getClZbh())) { | ||
| 454 | + schadd.add(sch); | ||
| 455 | + } | ||
| 456 | + } | ||
| 457 | + mapType.put(s.getClZbh(), schadd); | ||
| 458 | + } | ||
| 459 | + //判断倒数第二个班次是否快要发车 | ||
| 460 | + for (String key : mapType.keySet()) { | ||
| 461 | + List<ScheduleRealInfo> carList = mapType.get(key); | ||
| 462 | + Collections.sort(carList, new ScheduleComparator.FCSJ()); | ||
| 463 | + //倒数第二个班次保证数量超过两条 | ||
| 464 | + ScheduleRealInfo scht = carList.size() >= 2 ? carList.get(carList.size() - 2) : null; | ||
| 465 | + if (scht == null) | ||
| 466 | + continue; | ||
| 467 | + | ||
| 468 | + if (scht.getDfsjT() > DateUtils.getTimestamp() + (1000 * 60 * 60 * 20) && | ||
| 469 | + scht.getDfsjT() - System.currentTimeMillis() < (1000* 60 * 4) && | ||
| 470 | + scht.getDfsjT() - System.currentTimeMillis() >= (1000* 60 *3)) { | ||
| 471 | + //推送一下 | ||
| 472 | + ts(addStationPeople(scht,"DESCTWO",0l)); | ||
| 473 | + | ||
| 474 | + LogerWait("末二班车推送",scht); | ||
| 475 | + } | ||
| 371 | } | 476 | } |
| 372 | } | 477 | } |
| 373 | - outEntrance.Znddjk(m);//测试推送 | ||
| 374 | - }else { | ||
| 375 | - list.add(sj); | ||
| 376 | - ZnddThread.ZNDDTYPEMAP.put(st,list);//存记录 | ||
| 377 | - outEntrance.Znddjk(m);//推送 | 478 | + |
| 479 | + }catch (Exception e){ | ||
| 480 | + logger.error("(倒数第二班车)末二班车执行方法出错"+ e); | ||
| 378 | } | 481 | } |
| 482 | + } | ||
| 483 | + | ||
| 484 | + | ||
| 379 | 485 | ||
| 486 | + public void ts(Map m) throws ParseException { | ||
| 380 | 487 | ||
| 488 | + //储存日志 | ||
| 489 | + StationPeopleLogger splogger = new StationPeopleLogger(); | ||
| 490 | + splogger.setType(m.get("type").toString()); | ||
| 491 | + splogger.setLineName(m.get("lineName").toString()); | ||
| 492 | + splogger.setLineCode(m.get("lineCode").toString()); | ||
| 493 | + splogger.setRq(sdf.format(new Date())); | ||
| 494 | + splogger.setRqStr(m.get("rqStr").toString()); | ||
| 495 | + splogger.setXlDir(m.get("xlDir").toString()); | ||
| 496 | + splogger.setFcsj(m.get("fcsj").toString()); | ||
| 497 | + splogger.setClZbh(m.get("clzbh").toString()); | ||
| 498 | + znddLoggerService.save(splogger); | ||
| 499 | + | ||
| 500 | + outEntrance.Znddjk(m);//推送 | ||
| 381 | } | 501 | } |
| 382 | 502 | ||
| 383 | 503 | ||
| @@ -404,16 +524,6 @@ public class AutomaticSch { | @@ -404,16 +524,6 @@ public class AutomaticSch { | ||
| 404 | return sp; | 524 | return sp; |
| 405 | } | 525 | } |
| 406 | 526 | ||
| 407 | - //大间隔数据转换 | ||
| 408 | - public Map ConvertDKL(Map m){ | ||
| 409 | - Map sp = new HashMap(); | ||
| 410 | - sp.put("uuid",UUID()); | ||
| 411 | - sp.put("lineCode",m.get("lineCode")); | ||
| 412 | - sp.put("lineName",m.get("lineName")); | ||
| 413 | - sp.put("rqStr",sdf.format(new Date())); | ||
| 414 | - sp.put("rq",sdfHHmm.format(new Date())); //检测到时间 | ||
| 415 | - return sp; | ||
| 416 | - } | ||
| 417 | 527 | ||
| 418 | 528 | ||
| 419 | //转换 | 529 | //转换 |
src/main/java/com/bsth/data/zndd/OutEntrance.java
| @@ -6,9 +6,13 @@ import com.bsth.common.ResponseCode; | @@ -6,9 +6,13 @@ import com.bsth.common.ResponseCode; | ||
| 6 | import com.bsth.data.BasicData; | 6 | import com.bsth.data.BasicData; |
| 7 | import com.bsth.data.schedule.DayOfSchedule; | 7 | import com.bsth.data.schedule.DayOfSchedule; |
| 8 | import com.bsth.data.schedule.ScheduleComparator; | 8 | import com.bsth.data.schedule.ScheduleComparator; |
| 9 | +import com.bsth.data.schedule.late_adjust.LateAdjustHandle; | ||
| 10 | +import com.bsth.entity.DKLInfo; | ||
| 9 | import com.bsth.entity.realcontrol.ScheduleRealInfo; | 11 | import com.bsth.entity.realcontrol.ScheduleRealInfo; |
| 10 | -import com.bsth.entity.zndd.StationPeopleLogger; | ||
| 11 | import com.bsth.entity.zndd.StationSignsLogger; | 12 | import com.bsth.entity.zndd.StationSignsLogger; |
| 13 | +import com.bsth.entity.zndd.znddStatus; | ||
| 14 | +import com.bsth.repository.zndd.ZnddStatusRepository; | ||
| 15 | +import com.bsth.service.DKLInfoService; | ||
| 12 | import com.bsth.util.HttpClientUtils; | 16 | import com.bsth.util.HttpClientUtils; |
| 13 | import com.bsth.util.SignUtils; | 17 | import com.bsth.util.SignUtils; |
| 14 | import com.bsth.websocket.handler.SendUtils; | 18 | import com.bsth.websocket.handler.SendUtils; |
| @@ -17,20 +21,19 @@ import org.slf4j.Logger; | @@ -17,20 +21,19 @@ import org.slf4j.Logger; | ||
| 17 | import org.slf4j.LoggerFactory; | 21 | import org.slf4j.LoggerFactory; |
| 18 | import org.springframework.beans.factory.annotation.Autowired; | 22 | import org.springframework.beans.factory.annotation.Autowired; |
| 19 | import org.springframework.beans.factory.annotation.Value; | 23 | import org.springframework.beans.factory.annotation.Value; |
| 24 | +import org.springframework.dao.DataAccessException; | ||
| 25 | +import org.springframework.jdbc.core.JdbcTemplate; | ||
| 20 | import org.springframework.scheduling.annotation.Scheduled; | 26 | import org.springframework.scheduling.annotation.Scheduled; |
| 21 | import org.springframework.web.bind.annotation.*; | 27 | import org.springframework.web.bind.annotation.*; |
| 28 | + | ||
| 22 | import java.io.*; | 29 | import java.io.*; |
| 23 | import java.nio.file.Files; | 30 | import java.nio.file.Files; |
| 24 | import java.nio.file.Path; | 31 | import java.nio.file.Path; |
| 25 | import java.nio.file.Paths; | 32 | import java.nio.file.Paths; |
| 26 | import java.nio.file.StandardCopyOption; | 33 | import java.nio.file.StandardCopyOption; |
| 27 | - | ||
| 28 | -import java.io.ByteArrayInputStream; | ||
| 29 | -import java.io.File; | ||
| 30 | -import java.io.FileOutputStream; | ||
| 31 | -import java.io.InputStream; | ||
| 32 | import java.text.SimpleDateFormat; | 34 | import java.text.SimpleDateFormat; |
| 33 | import java.time.Duration; | 35 | import java.time.Duration; |
| 36 | +import java.time.LocalDateTime; | ||
| 34 | import java.time.LocalTime; | 37 | import java.time.LocalTime; |
| 35 | import java.time.format.DateTimeFormatter; | 38 | import java.time.format.DateTimeFormatter; |
| 36 | import java.util.*; | 39 | import java.util.*; |
| @@ -54,9 +57,8 @@ public class OutEntrance { | @@ -54,9 +57,8 @@ public class OutEntrance { | ||
| 54 | 57 | ||
| 55 | @Value("${dc.imgurl}") | 58 | @Value("${dc.imgurl}") |
| 56 | private String imgurl; //存储图片地址 | 59 | private String imgurl; //存储图片地址 |
| 57 | - | ||
| 58 | - @Value("${dc.profile}") | ||
| 59 | - private String profile; //存储图片地址*/ | 60 | + |
| 61 | + private String profile = "profile"; //存储图片地址*/ | ||
| 60 | 62 | ||
| 61 | @Value("${baidu.ak}") | 63 | @Value("${baidu.ak}") |
| 62 | private String ak; //百度api秘钥*/ | 64 | private String ak; //百度api秘钥*/ |
| @@ -69,6 +71,18 @@ public class OutEntrance { | @@ -69,6 +71,18 @@ public class OutEntrance { | ||
| 69 | @Autowired | 71 | @Autowired |
| 70 | AutomaticSch automaticSch; | 72 | AutomaticSch automaticSch; |
| 71 | 73 | ||
| 74 | + @Autowired | ||
| 75 | + private DKLInfoService dklInfoService; | ||
| 76 | + | ||
| 77 | + @Autowired | ||
| 78 | + JdbcTemplate jdbcTemplate; | ||
| 79 | + | ||
| 80 | + @Autowired | ||
| 81 | + ZnddStatusRepository znddStatusRepository; | ||
| 82 | + | ||
| 83 | + @Autowired | ||
| 84 | + BasicData basicData; | ||
| 85 | + | ||
| 72 | //调度屏小程序接口。 | 86 | //调度屏小程序接口。 |
| 73 | @RequestMapping(value = "/OutCar", method = RequestMethod.POST) | 87 | @RequestMapping(value = "/OutCar", method = RequestMethod.POST) |
| 74 | public Map OutCarOutCar(@RequestParam Map m,@RequestBody StationSignsLogger ssLogger) { | 88 | public Map OutCarOutCar(@RequestParam Map m,@RequestBody StationSignsLogger ssLogger) { |
| @@ -93,7 +107,7 @@ public class OutEntrance { | @@ -93,7 +107,7 @@ public class OutEntrance { | ||
| 93 | } | 107 | } |
| 94 | 108 | ||
| 95 | 109 | ||
| 96 | - //查询班次情况自动回复 | 110 | + //查询班次情况自动回复 --拥堵 |
| 97 | //当前日期 | 111 | //当前日期 |
| 98 | List<Map> dzList = carMonitor.carMonitor(ssLogger.getLineCode(), ssLogger.getDir(), ssLogger.getStation()); //信息发布接口 | 112 | List<Map> dzList = carMonitor.carMonitor(ssLogger.getLineCode(), ssLogger.getDir(), ssLogger.getStation()); //信息发布接口 |
| 99 | if (dzList.size() > 0){ | 113 | if (dzList.size() > 0){ |
| @@ -106,9 +120,36 @@ public class OutEntrance { | @@ -106,9 +120,36 @@ public class OutEntrance { | ||
| 106 | if(!"畅通".equals(trafficStatus)){ | 120 | if(!"畅通".equals(trafficStatus)){ |
| 107 | s=road+trafficStatus+","; | 121 | s=road+trafficStatus+","; |
| 108 | } | 122 | } |
| 109 | - rtn.put("message",s+"车辆预计还有"+dzList.get(0).get("sj")+"抵达,请耐心等待"); | 123 | + rtn.put("message",s+"亲爱的乘客,我们的调度员已接收到通知,车辆预计还有"+dzList.get(0).get("sj")+"抵达,请稍等片刻"); |
| 110 | }else { | 124 | }else { |
| 111 | - //筛选方向 | 125 | + //第一个班次 |
| 126 | + //所有应发未到的班次--晚点的情况 | ||
| 127 | + Collection<ScheduleRealInfo> all = LateAdjustHandle.allLateSch(); | ||
| 128 | + for (ScheduleRealInfo schc : all) { | ||
| 129 | + if(schc.getXlBm().equals(m.get("lineCode"))) { | ||
| 130 | + Long schId = schc.getId(); | ||
| 131 | + ScheduleRealInfo sch = null; | ||
| 132 | + if (schId != null) | ||
| 133 | + sch = dayOfSchedule.get(schId); | ||
| 134 | + | ||
| 135 | + ScheduleRealInfo prev = dayOfSchedule.prev(sch); | ||
| 136 | + List<Map> dzLists = carMonitor.carMonitor(prev.getXlBm(), prev.getXlDir(), prev.getZdzCode()); //信息发布接口 | ||
| 137 | + for (Map mst : dzLists) { | ||
| 138 | + //匹配到当前车辆 | ||
| 139 | + if (basicData.nbbmCompanyPlateMap.get(prev.getClZbh()) != null && mst.get("terminal").equals(basicData.nbbmCompanyPlateMap.get(prev.getClZbh()).replaceAll("-", ""))) { | ||
| 140 | + if (sch.getXlBm().equals(schc.getXlBm())) { | ||
| 141 | + rtn.put("message", "非常抱歉,车辆因路上交通拥堵,预计还需要" + mst.get("sj").toString() + "抵达,请稍等片刻"); | ||
| 142 | + rtn.put("status", ResponseCode.SUCCESS); | ||
| 143 | + return rtn; | ||
| 144 | + } | ||
| 145 | + } | ||
| 146 | + } | ||
| 147 | + } | ||
| 148 | + } | ||
| 149 | + | ||
| 150 | + | ||
| 151 | + | ||
| 152 | + //筛选方向 -- 正常班次未到发车时间 | ||
| 112 | List<ScheduleRealInfo> rs = dayOfSchedule.findByLineAndUpDown(ssLogger.getLineCode(),Integer.parseInt(ssLogger.getDir())); | 153 | List<ScheduleRealInfo> rs = dayOfSchedule.findByLineAndUpDown(ssLogger.getLineCode(),Integer.parseInt(ssLogger.getDir())); |
| 113 | if(rs.size()>0){ | 154 | if(rs.size()>0){ |
| 114 | //排序 | 155 | //排序 |
| @@ -125,7 +166,7 @@ public class OutEntrance { | @@ -125,7 +166,7 @@ public class OutEntrance { | ||
| 125 | } | 166 | } |
| 126 | } | 167 | } |
| 127 | if(sjtext!=null){ | 168 | if(sjtext!=null){ |
| 128 | - rtn.put("message","车辆预计"+sjtext+"发车,请耐心等待"); | 169 | + rtn.put("message","亲爱的乘客,我们的调度员已接收到通知,车辆将按照计划,在"+sjtext+"准时发车,请稍等片刻"); |
| 129 | }else { | 170 | }else { |
| 130 | rtn.put("message","当日运营已结束"); | 171 | rtn.put("message","当日运营已结束"); |
| 131 | } | 172 | } |
| @@ -153,6 +194,23 @@ public class OutEntrance { | @@ -153,6 +194,23 @@ public class OutEntrance { | ||
| 153 | rtn.put("status", "验证失败"); | 194 | rtn.put("status", "验证失败"); |
| 154 | return rtn; | 195 | return rtn; |
| 155 | } | 196 | } |
| 197 | + //大客流开关 | ||
| 198 | + List<znddStatus> znddStatusList = (List<znddStatus>) znddStatusRepository.findAll(); | ||
| 199 | + Boolean isType = false; | ||
| 200 | + String excuteStatus = null; | ||
| 201 | + for (znddStatus zs : znddStatusList) { | ||
| 202 | + if (zs.getType().equals("dkl")) { | ||
| 203 | + isType = true; | ||
| 204 | + excuteStatus = zs.getExcuteStatus(); | ||
| 205 | + } | ||
| 206 | + } | ||
| 207 | + | ||
| 208 | + if (!isType){ | ||
| 209 | + logger.info("大客流接口未开启--------------"); | ||
| 210 | + rtn.put("status",ResponseCode.SUCCESS); | ||
| 211 | + return rtn; | ||
| 212 | + } | ||
| 213 | + | ||
| 156 | String num=jsonObject.getString("num"); | 214 | String num=jsonObject.getString("num"); |
| 157 | int count=automaticSch.getPenum("DKL","0"); | 215 | int count=automaticSch.getPenum("DKL","0"); |
| 158 | if(Integer.parseInt(num)<count){ | 216 | if(Integer.parseInt(num)<count){ |
| @@ -169,15 +227,30 @@ public class OutEntrance { | @@ -169,15 +227,30 @@ public class OutEntrance { | ||
| 169 | String lineCode = line.get("lineCode").toString(); | 227 | String lineCode = line.get("lineCode").toString(); |
| 170 | String stationCode = line.get("stationCode").toString(); | 228 | String stationCode = line.get("stationCode").toString(); |
| 171 | String dir = line.get("dir").toString(); | 229 | String dir = line.get("dir").toString(); |
| 172 | - /*StationRoute stationRoute=BasicData.stationCode2StationMap.get(lineCode+"_"+stationCode);*/ | 230 | + imgMap.put(lineCode+"_"+dir,img); |
| 231 | + DKLInfo dklInfo =new DKLInfo(); | ||
| 232 | + dklInfo.setLineCode(stationCode); | ||
| 233 | + String lineName=BasicData.lineCode2NameMap.get(lineCode); | ||
| 234 | + String stationName=BasicData.stationCode2NameMap.get(lineCode+"_"+dir+"_"+stationCode); | ||
| 235 | + dklInfo.setLineName(lineName); | ||
| 236 | + dklInfo.setStationCode(stationCode); | ||
| 237 | + dklInfo.setStationName(stationName); | ||
| 238 | + dklInfo.setNum(Integer.parseInt(num)); | ||
| 239 | + dklInfo.setUpDown(dir); | ||
| 240 | + dklInfo.setImage(img); | ||
| 241 | + dklInfoService.save(dklInfo); | ||
| 242 | + if(Integer.parseInt(num)<count){ | ||
| 243 | + continue; | ||
| 244 | + } | ||
| 173 | Map m = new HashMap(); | 245 | Map m = new HashMap(); |
| 174 | m.put("image", img); | 246 | m.put("image", img); |
| 175 | m.put("stationCode", stationCode); | 247 | m.put("stationCode", stationCode); |
| 176 | m.put("lineCode", lineCode); | 248 | m.put("lineCode", lineCode); |
| 177 | - m.put("stationName",BasicData.stationCode2NameMap.get(lineCode+"_"+dir+"_"+stationCode)); | ||
| 178 | - m.put("lineName",BasicData.lineCode2NameMap.get(lineCode)); | 249 | + m.put("stationName",stationName); |
| 250 | + m.put("lineName",lineName); | ||
| 179 | m.put("num",num); | 251 | m.put("num",num); |
| 180 | m.put("xlDir",dir); | 252 | m.put("xlDir",dir); |
| 253 | + m.put("excuteStatus",excuteStatus); | ||
| 181 | List<ScheduleRealInfo> srList=dayOfSchedule.findByLineAndUpDown(lineCode,Integer.parseInt(dir)); | 254 | List<ScheduleRealInfo> srList=dayOfSchedule.findByLineAndUpDown(lineCode,Integer.parseInt(dir)); |
| 182 | List<ScheduleRealInfo> sl=new ArrayList<>(); | 255 | List<ScheduleRealInfo> sl=new ArrayList<>(); |
| 183 | for (ScheduleRealInfo scheduleRealInfo : srList) {//筛选出运营班次 | 256 | for (ScheduleRealInfo scheduleRealInfo : srList) {//筛选出运营班次 |
| @@ -253,33 +326,6 @@ public class OutEntrance { | @@ -253,33 +326,6 @@ public class OutEntrance { | ||
| 253 | } | 326 | } |
| 254 | 327 | ||
| 255 | 328 | ||
| 256 | - //智能调度接口-大客流 | ||
| 257 | - @RequestMapping(value="/dkl",method = RequestMethod.POST) | ||
| 258 | - public Map ddkl(@RequestParam Map m) { | ||
| 259 | - Map rtn = new HashMap<>(); | ||
| 260 | - | ||
| 261 | - try { | ||
| 262 | - ObjectMapper mapper = new ObjectMapper(); | ||
| 263 | - //map转换实体类 | ||
| 264 | - StationPeopleLogger ssLogger = mapper.convertValue(m, StationPeopleLogger.class); | ||
| 265 | - | ||
| 266 | - ssLogger.setType("大客流"); | ||
| 267 | - | ||
| 268 | - //保存记录 | ||
| 269 | - //znddLoggerService.save(ssLogger); | ||
| 270 | - //线调页面推送 | ||
| 271 | - //sendUtils.sendzndd(ssLogger); | ||
| 272 | - | ||
| 273 | - rtn.put("status",ResponseCode.SUCCESS); | ||
| 274 | - } catch (Exception e) { | ||
| 275 | - rtn.put("status", ResponseCode.ERROR); | ||
| 276 | - logger.error("大客流推送异常----",e); | ||
| 277 | - } | ||
| 278 | - return rtn; | ||
| 279 | - } | ||
| 280 | - | ||
| 281 | - | ||
| 282 | - | ||
| 283 | 329 | ||
| 284 | /** | 330 | /** |
| 285 | * 保存base64图片 | 331 | * 保存base64图片 |
| @@ -319,7 +365,7 @@ public class OutEntrance { | @@ -319,7 +365,7 @@ public class OutEntrance { | ||
| 319 | destfile.mkdirs(); | 365 | destfile.mkdirs(); |
| 320 | } | 366 | } |
| 321 | //文件新名称 | 367 | //文件新名称 |
| 322 | - String fileNameNew = AutomaticSch.UUID()+ ".png"; | 368 | + String fileNameNew = System.currentTimeMillis()+"_"+AutomaticSch.UUID()+ ".png"; |
| 323 | File f = new File(destfile.getAbsoluteFile() + File.separator + fileNameNew); | 369 | File f = new File(destfile.getAbsoluteFile() + File.separator + fileNameNew); |
| 324 | // 将字符串转换成二进制,用于显示图片 | 370 | // 将字符串转换成二进制,用于显示图片 |
| 325 | // 将上面生成的图片格式字符串 imgStr,还原成图片显示 | 371 | // 将上面生成的图片格式字符串 imgStr,还原成图片显示 |
| @@ -397,7 +443,9 @@ public class OutEntrance { | @@ -397,7 +443,9 @@ public class OutEntrance { | ||
| 397 | @Scheduled(cron = "0 0 0 * * ?") | 443 | @Scheduled(cron = "0 0 0 * * ?") |
| 398 | public void clearImg(){ | 444 | public void clearImg(){ |
| 399 | try { | 445 | try { |
| 400 | - File folder=new File(imgurl+"/avat"); | 446 | + LocalDateTime date =LocalDateTime.now().minusDays(7); |
| 447 | + String[] d=date.format(DateTimeFormatter.ofPattern("yyyy-MM-dd")).split("-"); | ||
| 448 | + File folder=new File(imgurl+"/avat/"+d[0]+"/"+d[1]+"/"+d[2]); | ||
| 401 | delete(folder); | 449 | delete(folder); |
| 402 | } catch (Exception e) { | 450 | } catch (Exception e) { |
| 403 | e.printStackTrace(); | 451 | e.printStackTrace(); |
| @@ -416,4 +464,28 @@ public class OutEntrance { | @@ -416,4 +464,28 @@ public class OutEntrance { | ||
| 416 | folder.delete(); // 删除空文件夹或者文件 | 464 | folder.delete(); // 删除空文件夹或者文件 |
| 417 | } | 465 | } |
| 418 | 466 | ||
| 467 | + private static Map<String,String> imgMap =new HashMap<>(); | ||
| 468 | + //调度获取站台视频 | ||
| 469 | + @RequestMapping(value = "/getStationVideo", method = RequestMethod.GET) | ||
| 470 | + public String getStationVideo(@RequestParam Map m) { | ||
| 471 | + if (m.get("lineCode")==null || m.get("upDown")==null){ | ||
| 472 | + return null; | ||
| 473 | + } | ||
| 474 | + String sql="select url from station_video where line_code ='"+m.get("lineCode")+"' and up_down ='"+m.get("upDown")+"'"; | ||
| 475 | + String url= null; | ||
| 476 | + try { | ||
| 477 | + url = jdbcTemplate.queryForObject(sql,String.class); | ||
| 478 | + } catch (DataAccessException e) { | ||
| 479 | + return null; | ||
| 480 | + } | ||
| 481 | + return url; | ||
| 482 | + } | ||
| 483 | + | ||
| 484 | + //调度获取站台图片 | ||
| 485 | + @RequestMapping(value = "/getStationImg", method = RequestMethod.GET) | ||
| 486 | + public String getStationImg(@RequestParam Map m) { | ||
| 487 | + String url=imgMap.get(m.get("lineCode")+"_"+m.get("upDown")); | ||
| 488 | + return url; | ||
| 489 | + } | ||
| 490 | + | ||
| 419 | } | 491 | } |
src/main/java/com/bsth/data/zndd/ZnddThread.java
| @@ -45,11 +45,8 @@ public class ZnddThread extends Thread{ | @@ -45,11 +45,8 @@ public class ZnddThread extends Thread{ | ||
| 45 | static Map<String,List> ZNDDTYPEMAP = new HashMap<>(); //已经推送过的检测 | 45 | static Map<String,List> ZNDDTYPEMAP = new HashMap<>(); //已经推送过的检测 |
| 46 | 46 | ||
| 47 | 47 | ||
| 48 | - String url = "https://lgapp.bsth.tech:13089/bsth_passengerflow/klbus/currentInsideNum.do"; //车内客流接口 | ||
| 49 | 48 | ||
| 50 | 49 | ||
| 51 | - String urldkl = "http://10.10.200.140:13089/bsth_passengerflow/klbus/currentInsideNum.do"; //大客流接口 | ||
| 52 | - | ||
| 53 | private static SimpleDateFormat sdfHHmm = new SimpleDateFormat("HH:mm"); | 50 | private static SimpleDateFormat sdfHHmm = new SimpleDateFormat("HH:mm"); |
| 54 | private static SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"); | 51 | private static SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"); |
| 55 | private static SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm"); | 52 | private static SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm"); |
| @@ -64,13 +61,7 @@ public class ZnddThread extends Thread{ | @@ -64,13 +61,7 @@ public class ZnddThread extends Thread{ | ||
| 64 | //automaticSch.mz(); | 61 | //automaticSch.mz(); |
| 65 | //automaticSch.dfTz();//大间隔 | 62 | //automaticSch.dfTz();//大间隔 |
| 66 | for (znddStatus zs : znddStatusList) { | 63 | for (znddStatus zs : znddStatusList) { |
| 67 | - if (zs.getOpenStatus().equals("0")) { | ||
| 68 | - //预案5个 | ||
| 69 | - if (zs.getType().equals("fcjg")) { | ||
| 70 | - automaticSch.dfTz(0); | ||
| 71 | - logger.info("发车间隔执行完毕"); | ||
| 72 | - } | ||
| 73 | - | 64 | + if (zs.getOpenStatus() != null && zs.getOpenStatus().equals("0")) { |
| 74 | if (zs.getType().equals("sftz")) { | 65 | if (zs.getType().equals("sftz")) { |
| 75 | automaticSch.sftz();//实发未发 | 66 | automaticSch.sftz();//实发未发 |
| 76 | logger.info("实发执行完毕"); | 67 | logger.info("实发执行完毕"); |
| @@ -79,31 +70,13 @@ public class ZnddThread extends Thread{ | @@ -79,31 +70,13 @@ public class ZnddThread extends Thread{ | ||
| 79 | automaticSch.sfCX();// 异常实发 - 实发撤销 | 70 | automaticSch.sfCX();// 异常实发 - 实发撤销 |
| 80 | logger.info("异常实发执行完毕"); | 71 | logger.info("异常实发执行完毕"); |
| 81 | } | 72 | } |
| 82 | - if (zs.getType().equals("zlcf")){ | ||
| 83 | - automaticSch.drivresponse(); | ||
| 84 | - logger.info("设备重发执行完毕"); | ||
| 85 | - } | ||
| 86 | - if (zs.getType().equals("wd")){ | ||
| 87 | - automaticSch.wd(); | ||
| 88 | - logger.info("误点执行完毕"); | ||
| 89 | - } | ||
| 90 | - if (zs.getType().equals("djg")){ | ||
| 91 | - automaticSch.dfTz(1); | ||
| 92 | - logger.info("行车大间隔执行完毕"); | ||
| 93 | - } | ||
| 94 | - | ||
| 95 | - if (zs.getType().equals("dkl")){ | ||
| 96 | - automaticSch.Dkl(); | ||
| 97 | - logger.info("大客流执行完毕"); | ||
| 98 | - } | ||
| 99 | - if (zs.getType().equals("mz")){ | ||
| 100 | - automaticSch.mz(); | ||
| 101 | - logger.info("满载执行完毕"); | ||
| 102 | - } | ||
| 103 | - | 73 | + if (zs.getType().equals("zlcf")){ |
| 74 | + automaticSch.drivresponse(); | ||
| 75 | + logger.info("设备重发执行完毕"); | ||
| 76 | + } | ||
| 104 | } | 77 | } |
| 105 | } | 78 | } |
| 106 | - }catch (Exception e){ | 79 | + }catch (Throwable e){ |
| 107 | logger.info("智能调度线程——————",e); | 80 | logger.info("智能调度线程——————",e); |
| 108 | } | 81 | } |
| 109 | 82 |
src/main/java/com/bsth/data/zndd/ZnddTwoThread.java
0 → 100644
| 1 | +package com.bsth.data.zndd; | ||
| 2 | + | ||
| 3 | +import com.bsth.data.LineConfigData; | ||
| 4 | +import com.bsth.data.gpsdata_v2.GpsRealData; | ||
| 5 | +import com.bsth.data.gpsdata_v2.entity.GpsEntity; | ||
| 6 | +import com.bsth.data.schedule.DayOfSchedule; | ||
| 7 | +import com.bsth.entity.realcontrol.ScheduleRealInfo; | ||
| 8 | +import com.bsth.entity.zndd.znddStatus; | ||
| 9 | +import com.bsth.repository.StationRouteRepository; | ||
| 10 | +import com.bsth.repository.zndd.ZnddStatusRepository; | ||
| 11 | +import org.slf4j.Logger; | ||
| 12 | +import org.slf4j.LoggerFactory; | ||
| 13 | +import org.springframework.beans.factory.annotation.Autowired; | ||
| 14 | +import org.springframework.stereotype.Component; | ||
| 15 | + | ||
| 16 | +import java.text.ParseException; | ||
| 17 | +import java.text.SimpleDateFormat; | ||
| 18 | +import java.util.Comparator; | ||
| 19 | +import java.util.HashMap; | ||
| 20 | +import java.util.List; | ||
| 21 | +import java.util.Map; | ||
| 22 | + | ||
| 23 | +/** | ||
| 24 | + * 调度预案 发车间隔、误点、大间隔、满载、大客流 | ||
| 25 | + */ | ||
| 26 | +@Component | ||
| 27 | +public class ZnddTwoThread extends Thread{ | ||
| 28 | + | ||
| 29 | + Logger logger = LoggerFactory.getLogger(this.getClass()); | ||
| 30 | + /*@Autowired | ||
| 31 | + StationPeopleLoggerRepository stationPeopleLoggerRepository;*/ | ||
| 32 | + @Autowired | ||
| 33 | + DayOfSchedule dayOfSchedule; | ||
| 34 | + @Autowired | ||
| 35 | + LineConfigData lineConfs; | ||
| 36 | + @Autowired | ||
| 37 | + GpsRealData gpsRealData; | ||
| 38 | + @Autowired | ||
| 39 | + StationRouteRepository stationRouteRepository; | ||
| 40 | + @Autowired | ||
| 41 | + OutEntrance outEntrance; | ||
| 42 | + @Autowired | ||
| 43 | + AutomaticSch automaticSch; | ||
| 44 | + | ||
| 45 | + @Autowired | ||
| 46 | + ZnddStatusRepository znddStatusRepository; | ||
| 47 | + | ||
| 48 | + static Map<String,List> ZNDDTYPEMAP = new HashMap<>(); //已经推送过的检测 | ||
| 49 | + | ||
| 50 | + | ||
| 51 | + | ||
| 52 | + | ||
| 53 | + private static SimpleDateFormat sdfHHmm = new SimpleDateFormat("HH:mm"); | ||
| 54 | + private static SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"); | ||
| 55 | + private static SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm"); | ||
| 56 | + @Override | ||
| 57 | + public void run() { | ||
| 58 | + try { | ||
| 59 | + List<znddStatus> znddStatusList = (List<znddStatus>) znddStatusRepository.findAll(); | ||
| 60 | + | ||
| 61 | + for (znddStatus zs : znddStatusList) { | ||
| 62 | + if (zs.getOpenStatus() != null && zs.getOpenStatus().equals("0")) { | ||
| 63 | + //预案5个 | ||
| 64 | + if (zs.getType().equals("fcjg")) { | ||
| 65 | + new Thread() { | ||
| 66 | + @Override | ||
| 67 | + public void run() { | ||
| 68 | + automaticSch.dfTz(0); | ||
| 69 | + logger.info("发车间隔执行完毕"); | ||
| 70 | + } | ||
| 71 | + }.start();//启动线程 | ||
| 72 | + } | ||
| 73 | + if (zs.getType().equals("wd")) { | ||
| 74 | + new Thread() { | ||
| 75 | + @Override | ||
| 76 | + public void run() { | ||
| 77 | + automaticSch.wd(); | ||
| 78 | + logger.info("误点执行完毕"); | ||
| 79 | + } | ||
| 80 | + }.start();//启动线程 | ||
| 81 | + } | ||
| 82 | + if (zs.getType().equals("djg")) { | ||
| 83 | + new Thread() { | ||
| 84 | + @Override | ||
| 85 | + public void run() { | ||
| 86 | + automaticSch.dfTz(1); | ||
| 87 | + logger.info("行车大间隔执行完毕"); | ||
| 88 | + } | ||
| 89 | + }.start();//启动线程 | ||
| 90 | + | ||
| 91 | + } | ||
| 92 | + if (zs.getType().equals("mz")) { | ||
| 93 | + new Thread() { | ||
| 94 | + @Override | ||
| 95 | + public void run() { | ||
| 96 | + automaticSch.mz(); | ||
| 97 | + logger.info("满载执行完毕"); | ||
| 98 | + } | ||
| 99 | + }.start();//启动线程 | ||
| 100 | + | ||
| 101 | + } | ||
| 102 | + if (zs.getType().equals("desctwo")) { | ||
| 103 | + new Thread() { | ||
| 104 | + @Override | ||
| 105 | + public void run() { | ||
| 106 | + automaticSch.TowdescSch(); | ||
| 107 | + logger.info("末二班车"); | ||
| 108 | + } | ||
| 109 | + }.start();//启动线程 | ||
| 110 | + | ||
| 111 | + | ||
| 112 | + } | ||
| 113 | + } | ||
| 114 | + } | ||
| 115 | + | ||
| 116 | + | ||
| 117 | + } catch (Exception e) { | ||
| 118 | + logger.info("智能调度线程——————", e); | ||
| 119 | + } | ||
| 120 | + } | ||
| 121 | + | ||
| 122 | + | ||
| 123 | + //满载 | ||
| 124 | + /* public void MZ(){ | ||
| 125 | + try { | ||
| 126 | + StringBuilder sb = HttpClientUtils.get(url); | ||
| 127 | + List<Object> list = JSONArray.parseArray(String.valueOf(sb)); | ||
| 128 | + for (Object b :list){ | ||
| 129 | + Map m = (Map) b; | ||
| 130 | + Integer num = Integer.parseInt(m.get("inside_num").toString()); | ||
| 131 | + if (num >= 15){ //大间隔阈值 检测到超过15个人的时候推送 | ||
| 132 | + ScheduleRealInfo sr = dayOfSchedule.executeCurr(m.get("nbbm").toString()); //查询当前车辆执行班次 | ||
| 133 | + GpsEntity gps = gpsRealData.get(m.get("sbbh").toString()); | ||
| 134 | + Map msp = new HashMap(); | ||
| 135 | + msp.put("lineCode",m.get("xlbm")); | ||
| 136 | + msp.put("lineName",m.get("xlmc")); | ||
| 137 | + msp.put("stationName",gps.getStationName()); | ||
| 138 | + msp.put("rqStr",sdfMonth.format(new Date())); | ||
| 139 | + msp.put("rq",sdfHHmm.format(new Date())); | ||
| 140 | + msp.put("type","MZ"); | ||
| 141 | + msp.put("numType",num); | ||
| 142 | + if (sr != null ) | ||
| 143 | + msp.put("xlDir",sr.getXlDir()); | ||
| 144 | + | ||
| 145 | + if (gps != null ) | ||
| 146 | + msp.put("station",gps.getStation().getCode()); | ||
| 147 | + | ||
| 148 | + ts(msp); | ||
| 149 | + } | ||
| 150 | + } | ||
| 151 | + | ||
| 152 | + }catch (Exception e){ | ||
| 153 | + logger.error("满载检测接口出错-----------",e); | ||
| 154 | + } | ||
| 155 | + }*/ | ||
| 156 | + public void ts(Map m) throws ParseException { | ||
| 157 | + outEntrance.Znddjk(m);//测试推送 | ||
| 158 | + } | ||
| 159 | + /* public void ts(Map m) throws ParseException { | ||
| 160 | + //记录存一下 --超过当前时间的是否推送? | ||
| 161 | + String st = m.get("lineCode")+"_"+m.get("type")+"_"+m.get("rqStr"); | ||
| 162 | + Long sj = sdf.parse(m.get("rqStr").toString() +" "+ m.get("rq")).getTime(); | ||
| 163 | + List<Long> list = new ArrayList(); | ||
| 164 | + //111_DJG_2024-06-24 | ||
| 165 | + if (ZNDDTYPEMAP.get(st) != null ) { | ||
| 166 | + list = ZNDDTYPEMAP.get(st); | ||
| 167 | + int i = 0; | ||
| 168 | + for (Long s : list){ | ||
| 169 | + if (Math.abs(s - sj) > (60 * 60 * 1000)){ | ||
| 170 | + i ++ ; | ||
| 171 | + } | ||
| 172 | + } | ||
| 173 | + if (i == list.size()){ | ||
| 174 | + list.add(sj); | ||
| 175 | + ZNDDTYPEMAP.put(st,list);//存记录 | ||
| 176 | + outEntrance.Znddjk(m);//推送 | ||
| 177 | + } | ||
| 178 | + return; | ||
| 179 | + }else { | ||
| 180 | + list.add(sj); | ||
| 181 | + ZNDDTYPEMAP.put(st,list);//存记录 | ||
| 182 | + outEntrance.Znddjk(m);//推送 | ||
| 183 | + } | ||
| 184 | + | ||
| 185 | + } | ||
| 186 | + | ||
| 187 | +*/ | ||
| 188 | + | ||
| 189 | + /* //发车间隔 | ||
| 190 | + public void FCJG(){ | ||
| 191 | + try { | ||
| 192 | + //无数据情况下 查看发车间隔配置数据是否正常bsth_c_calc_interval | ||
| 193 | + List<CalcIntervalDetail> fcjgList = userCarCountHandler.calcLast(); | ||
| 194 | + if (fcjgList!= null && !fcjgList.isEmpty()){ | ||
| 195 | + for (CalcIntervalDetail cd : fcjgList){ | ||
| 196 | + Map sp = new HashMap(); | ||
| 197 | + sp.put("lineCode",cd.getLineCode()); | ||
| 198 | + sp.put("lineName",cd.getLineName()); | ||
| 199 | + sp.put("rqStr",cd.getDate()); | ||
| 200 | + sp.put("rq",cd.getSjfc2()); | ||
| 201 | + sp.put("type","FCJG"); | ||
| 202 | + sp.put("xlDir",cd.getXlDir()); | ||
| 203 | + sp.put("numType",cd.getSubTime()); | ||
| 204 | + sp.put("fcsj",cd.getSjfc2()); | ||
| 205 | + sp.put("stationName",cd.getStation()); | ||
| 206 | + ts(sp); | ||
| 207 | + } | ||
| 208 | + } | ||
| 209 | + }catch (Exception e){ | ||
| 210 | + logger.error("发车间隔检测出现出错-----------",e); | ||
| 211 | + } | ||
| 212 | + } | ||
| 213 | +*/ | ||
| 214 | + | ||
| 215 | + //转换 | ||
| 216 | + public Map addStationPeople(ScheduleRealInfo info,String type,Long sst,String sj) throws ParseException{ | ||
| 217 | + Map sp = new HashMap(); | ||
| 218 | + sp.put("lineCode",info.getXlBm()); | ||
| 219 | + sp.put("lineName",info.getXlName() ); | ||
| 220 | + sp.put("rqStr",info.getScheduleDateStr()); | ||
| 221 | + sp.put("rq",new java.sql.Date(sdf.parse((info.getScheduleDateStr()+" " + sj)).getTime())); //检测到时间 | ||
| 222 | + sp.put("type",type); | ||
| 223 | + sp.put("xlDir",info.getXlDir()); | ||
| 224 | + sp.put("numType",sst); | ||
| 225 | + return sp; | ||
| 226 | + } | ||
| 227 | + | ||
| 228 | + | ||
| 229 | + | ||
| 230 | + //排序 | ||
| 231 | + public static class GpsComp implements Comparator<GpsEntity> { | ||
| 232 | + @Override | ||
| 233 | + public int compare(GpsEntity o1, GpsEntity o2) { | ||
| 234 | + return Integer.parseInt(o1.getRemark()) - Integer.parseInt(o2.getRemark()); | ||
| 235 | + } | ||
| 236 | + } | ||
| 237 | + | ||
| 238 | +} | ||
| 239 | + |
src/main/java/com/bsth/data/zndd/carMonitor.java
| @@ -81,6 +81,7 @@ public class carMonitor { | @@ -81,6 +81,7 @@ public class carMonitor { | ||
| 81 | map.put("lat",responseEle.elementTextTrim("lat")); | 81 | map.put("lat",responseEle.elementTextTrim("lat")); |
| 82 | map.put("nbbm",responseEle.elementTextTrim("insidecode")); | 82 | map.put("nbbm",responseEle.elementTextTrim("insidecode")); |
| 83 | map.put("road",responseEle.elementTextTrim("road")); | 83 | map.put("road",responseEle.elementTextTrim("road")); |
| 84 | + map.put("schId",responseEle.elementTextTrim("schId")); | ||
| 84 | list.add(map); | 85 | list.add(map); |
| 85 | } | 86 | } |
| 86 | } | 87 | } |
src/main/java/com/bsth/data/zndd/voice/GJC.java
| @@ -16,9 +16,9 @@ public enum GJC { | @@ -16,9 +16,9 @@ public enum GJC { | ||
| 16 | CC(7, "出场"), | 16 | CC(7, "出场"), |
| 17 | KQ(8, "开启"), | 17 | KQ(8, "开启"), |
| 18 | GB(9, "关闭"), | 18 | GB(9, "关闭"), |
| 19 | - ge(10, "个"), | 19 | + ge(10, "一个"), |
| 20 | dao(11, "到"), | 20 | dao(11, "到"), |
| 21 | - de(12, "的"); | 21 | + de(12, "的班次"); |
| 22 | 22 | ||
| 23 | private int code; | 23 | private int code; |
| 24 | private String description; | 24 | private String description; |
src/main/java/com/bsth/data/zndd/voice/UploadVideoServlet.java
| 1 | package com.bsth.data.zndd.voice; | 1 | package com.bsth.data.zndd.voice; |
| 2 | 2 | ||
| 3 | import com.alibaba.fastjson.JSONObject; | 3 | import com.alibaba.fastjson.JSONObject; |
| 4 | -import com.bsth.data.BasicData; | ||
| 5 | import com.bsth.data.zndd.baidu.speech.restapi.asrdemo.AsrMain; | 4 | import com.bsth.data.zndd.baidu.speech.restapi.asrdemo.AsrMain; |
| 6 | import com.bsth.entity.StationRoute; | 5 | import com.bsth.entity.StationRoute; |
| 7 | import com.bsth.entity.sys.SysUser; | 6 | import com.bsth.entity.sys.SysUser; |
| @@ -124,7 +123,7 @@ public class UploadVideoServlet extends HttpServlet { | @@ -124,7 +123,7 @@ public class UploadVideoServlet extends HttpServlet { | ||
| 124 | String text = textList.get(0).toString(); | 123 | String text = textList.get(0).toString(); |
| 125 | //text="新增出厂班次"; | 124 | //text="新增出厂班次"; |
| 126 | //text="帮我添加一个鸿音路南芦公路到临港大道枢纽站的班次"; | 125 | //text="帮我添加一个鸿音路南芦公路到临港大道枢纽站的班次"; |
| 127 | - if(isSimilarity(ZL.zdzdbc,text,null)){//帮我添加一个xx到xx站的班次(帮我添加一个鸿音路南芦公路到临港大道枢纽站的班次) | 126 | + /*if(isSimilarity(ZL.zdzdbc,text,null)){//帮我添加一个xx到xx站的班次(帮我添加一个鸿音路南芦公路到临港大道枢纽站的班次) |
| 128 | String[] ks = text.replace(",","").split("到"); | 127 | String[] ks = text.replace(",","").split("到"); |
| 129 | if(ks[0].split("个").length==1){ | 128 | if(ks[0].split("个").length==1){ |
| 130 | writer.write(text+"_识别失败"+",999"); | 129 | writer.write(text+"_识别失败"+",999"); |
| @@ -137,9 +136,9 @@ public class UploadVideoServlet extends HttpServlet { | @@ -137,9 +136,9 @@ public class UploadVideoServlet extends HttpServlet { | ||
| 137 | String Station1= ks[0].split("个")[1]; | 136 | String Station1= ks[0].split("个")[1]; |
| 138 | String Station2= ks[1].split("的")[0]; | 137 | String Station2= ks[1].split("的")[0]; |
| 139 | 138 | ||
| 140 | - /* String fcsj = null;//线路名,上下行,发车时间 | 139 | + *//* String fcsj = null;//线路名,上下行,发车时间 |
| 141 | //发车时间 | 140 | //发车时间 |
| 142 | - fcsj = extractTimes(text);*/ | 141 | + fcsj = extractTimes(text);*//* |
| 143 | //线路名称 - 线路编码和名称对照 | 142 | //线路名称 - 线路编码和名称对照 |
| 144 | 143 | ||
| 145 | Map<String, Object> param = new HashMap<>(); | 144 | Map<String, Object> param = new HashMap<>(); |
| @@ -163,7 +162,7 @@ public class UploadVideoServlet extends HttpServlet { | @@ -163,7 +162,7 @@ public class UploadVideoServlet extends HttpServlet { | ||
| 163 | } | 162 | } |
| 164 | writer.write(text +",1,"+m.get("stationcode1")+","+m.get("stationcode2")+","+0); | 163 | writer.write(text +",1,"+m.get("stationcode1")+","+m.get("stationcode2")+","+0); |
| 165 | return; | 164 | return; |
| 166 | - } | 165 | + }*/ |
| 167 | if(isSimilarity(ZL.LJCCBC,text,null)){//添加出厂班次 | 166 | if(isSimilarity(ZL.LJCCBC,text,null)){//添加出厂班次 |
| 168 | writer.write(text+"_"+ZL.LJCCBC.getDescription()+",2"); | 167 | writer.write(text+"_"+ZL.LJCCBC.getDescription()+",2"); |
| 169 | return; | 168 | return; |
src/main/java/com/bsth/data/zndd/voice/VoiceUtil.java
| 1 | -package com.bsth.data.zndd.voice; | ||
| 2 | - | ||
| 3 | -import com.alibaba.fastjson.JSON; | ||
| 4 | -import com.alibaba.fastjson.JSONObject; | ||
| 5 | -import com.sun.media.sound.WaveFileReader; | ||
| 6 | -import com.sun.media.sound.WaveFileWriter; | ||
| 7 | -import org.slf4j.Logger; | ||
| 8 | -import org.slf4j.LoggerFactory; | ||
| 9 | -import org.springframework.util.Assert; | ||
| 10 | -import org.springframework.util.StringUtils; | ||
| 11 | -import org.vosk.LibVosk; | ||
| 12 | -import org.vosk.LogLevel; | ||
| 13 | -import org.vosk.Model; | ||
| 14 | -import org.vosk.Recognizer; | ||
| 15 | - | ||
| 16 | -import javax.sound.sampled.*; | ||
| 17 | -import java.io.*; | ||
| 18 | -import java.nio.file.Files; | ||
| 19 | -import java.nio.file.Paths; | ||
| 20 | - | ||
| 21 | -public class VoiceUtil { | ||
| 22 | - /* @Value("${leenleda.vosk.model}") | ||
| 23 | - private String VOSKMODELPATH;*/ | ||
| 24 | - | ||
| 25 | - Logger log = LoggerFactory.getLogger(this.getClass()); | ||
| 26 | - public String getWord(String filePath) throws IOException, UnsupportedAudioFileException { | ||
| 27 | - Assert.isTrue(StringUtils.hasLength("D:\\pcm\\vosk-model-small-cn-0.22"), "无效的VOS模块!"); | ||
| 28 | - byte[] bytes = Files.readAllBytes(Paths.get(filePath)); | ||
| 29 | - // 转换为16KHZ | ||
| 30 | - reSamplingAndSave(bytes, filePath); | ||
| 31 | - File f = new File(filePath); | ||
| 32 | - RandomAccessFile rdf = null; | ||
| 33 | - rdf = new RandomAccessFile(f, "r"); | ||
| 34 | - log.info("声音尺寸:{}", toInt(read(rdf, 4, 4))); | ||
| 35 | - log.info("音频格式:{}", toShort(read(rdf, 20, 2))); | ||
| 36 | - short track = toShort(read(rdf, 22, 2)); | ||
| 37 | - log.info("1 单声道 2 双声道: {}", track); | ||
| 38 | - log.info("采样率、音频采样级别 16000 = 16KHz: {}", toInt(read(rdf, 24, 4))); | ||
| 39 | - log.info("每秒波形的数据量:{}", toShort(read(rdf, 22, 2))); | ||
| 40 | - log.info("采样帧的大小:{}", toShort(read(rdf, 32, 2))); | ||
| 41 | - log.info("采样位数:{}", toShort(read(rdf, 34, 2))); | ||
| 42 | - rdf.close(); | ||
| 43 | - LibVosk.setLogLevel(LogLevel.WARNINGS); | ||
| 44 | - try ( | ||
| 45 | - Model model = new Model("D:\\pcm\\vosk-model-small-cn-0.22"); | ||
| 46 | - InputStream ais = AudioSystem.getAudioInputStream(new BufferedInputStream(new FileInputStream(filePath))); | ||
| 47 | - // 采样率为音频采样率的声道倍数 | ||
| 48 | - Recognizer recognizer = new Recognizer(model, 16000 * track)) { | ||
| 49 | - | ||
| 50 | - recognizer.setWords(true); | ||
| 51 | - | ||
| 52 | - String result = recognizer.getFinalResult(); | ||
| 53 | - log.info("识别结果:{}", result); | ||
| 54 | - if (StringUtils.hasLength(result)) { | ||
| 55 | - JSONObject jsonObject = JSON.parseObject(result); | ||
| 56 | - return jsonObject.getString("text").replace(" ", ""); | ||
| 57 | - } | ||
| 58 | - return ""; | ||
| 59 | - } | ||
| 60 | - | ||
| 61 | - | ||
| 62 | - | ||
| 63 | - } | ||
| 64 | - | ||
| 65 | - public static int toInt(byte[] b) { | ||
| 66 | - return (((b[3] & 0xff) << 24) + ((b[2] & 0xff) << 16) + ((b[1] & 0xff) << 8) + ((b[0] & 0xff) << 0)); | ||
| 67 | - } | ||
| 68 | - | ||
| 69 | - public static short toShort(byte[] b) { | ||
| 70 | - return (short) ((b[1] << 8) + (b[0] << 0)); | ||
| 71 | - } | ||
| 72 | - | ||
| 73 | - public static byte[] read(RandomAccessFile rdf, int pos, int length) throws IOException { | ||
| 74 | - rdf.seek(pos); | ||
| 75 | - byte result[] = new byte[length]; | ||
| 76 | - for (int i = 0; i < length; i++) { | ||
| 77 | - result[i] = rdf.readByte(); | ||
| 78 | - } | ||
| 79 | - return result; | ||
| 80 | - } | ||
| 81 | - | ||
| 82 | - public static void reSamplingAndSave(byte[] data, String path) throws IOException, UnsupportedAudioFileException { | ||
| 83 | - WaveFileReader reader = new WaveFileReader(); | ||
| 84 | - AudioInputStream audioIn = reader.getAudioInputStream(new ByteArrayInputStream(data)); | ||
| 85 | - AudioFormat srcFormat = audioIn.getFormat(); | ||
| 86 | - int targetSampleRate = 16000; | ||
| 87 | - AudioFormat dstFormat = new AudioFormat(srcFormat.getEncoding(), | ||
| 88 | - targetSampleRate, | ||
| 89 | - srcFormat.getSampleSizeInBits(), | ||
| 90 | - srcFormat.getChannels(), | ||
| 91 | - srcFormat.getFrameSize(), | ||
| 92 | - srcFormat.getFrameRate(), | ||
| 93 | - srcFormat.isBigEndian()); | ||
| 94 | - AudioInputStream convertedIn = AudioSystem.getAudioInputStream(dstFormat, audioIn); | ||
| 95 | - File file = new File(path); | ||
| 96 | - WaveFileWriter writer = new WaveFileWriter(); | ||
| 97 | - writer.write(convertedIn, AudioFileFormat.Type.WAVE, file); | ||
| 98 | - } | ||
| 99 | -} | ||
| 100 | \ No newline at end of file | 1 | \ No newline at end of file |
| 2 | +//package com.bsth.data.zndd.voice; | ||
| 3 | +// | ||
| 4 | +//import com.alibaba.fastjson.JSON; | ||
| 5 | +//import com.alibaba.fastjson.JSONObject; | ||
| 6 | +//import com.sun.media.sound.WaveFileReader; | ||
| 7 | +//import com.sun.media.sound.WaveFileWriter; | ||
| 8 | +//import org.slf4j.Logger; | ||
| 9 | +//import org.slf4j.LoggerFactory; | ||
| 10 | +//import org.springframework.util.Assert; | ||
| 11 | +//import org.springframework.util.StringUtils; | ||
| 12 | +//import org.vosk.LibVosk; | ||
| 13 | +//import org.vosk.LogLevel; | ||
| 14 | +//import org.vosk.Model; | ||
| 15 | +//import org.vosk.Recognizer; | ||
| 16 | +// | ||
| 17 | +//import javax.sound.sampled.*; | ||
| 18 | +//import java.io.*; | ||
| 19 | +//import java.nio.file.Files; | ||
| 20 | +//import java.nio.file.Paths; | ||
| 21 | +// | ||
| 22 | +//public class VoiceUtil { | ||
| 23 | +// /* @Value("${leenleda.vosk.model}") | ||
| 24 | +// private String VOSKMODELPATH;*/ | ||
| 25 | +// | ||
| 26 | +// Logger log = LoggerFactory.getLogger(this.getClass()); | ||
| 27 | +// public String getWord(String filePath) throws IOException, UnsupportedAudioFileException { | ||
| 28 | +// Assert.isTrue(StringUtils.hasLength("D:\\pcm\\vosk-model-small-cn-0.22"), "无效的VOS模块!"); | ||
| 29 | +// byte[] bytes = Files.readAllBytes(Paths.get(filePath)); | ||
| 30 | +// // 转换为16KHZ | ||
| 31 | +// reSamplingAndSave(bytes, filePath); | ||
| 32 | +// File f = new File(filePath); | ||
| 33 | +// RandomAccessFile rdf = null; | ||
| 34 | +// rdf = new RandomAccessFile(f, "r"); | ||
| 35 | +// log.info("声音尺寸:{}", toInt(read(rdf, 4, 4))); | ||
| 36 | +// log.info("音频格式:{}", toShort(read(rdf, 20, 2))); | ||
| 37 | +// short track = toShort(read(rdf, 22, 2)); | ||
| 38 | +// log.info("1 单声道 2 双声道: {}", track); | ||
| 39 | +// log.info("采样率、音频采样级别 16000 = 16KHz: {}", toInt(read(rdf, 24, 4))); | ||
| 40 | +// log.info("每秒波形的数据量:{}", toShort(read(rdf, 22, 2))); | ||
| 41 | +// log.info("采样帧的大小:{}", toShort(read(rdf, 32, 2))); | ||
| 42 | +// log.info("采样位数:{}", toShort(read(rdf, 34, 2))); | ||
| 43 | +// rdf.close(); | ||
| 44 | +// LibVosk.setLogLevel(LogLevel.WARNINGS); | ||
| 45 | +// try ( | ||
| 46 | +// Model model = new Model("D:\\pcm\\vosk-model-small-cn-0.22"); | ||
| 47 | +// InputStream ais = AudioSystem.getAudioInputStream(new BufferedInputStream(new FileInputStream(filePath))); | ||
| 48 | +// // 采样率为音频采样率的声道倍数 | ||
| 49 | +// Recognizer recognizer = new Recognizer(model, 16000 * track)) { | ||
| 50 | +// | ||
| 51 | +// recognizer.setWords(true); | ||
| 52 | +// | ||
| 53 | +// String result = recognizer.getFinalResult(); | ||
| 54 | +// log.info("识别结果:{}", result); | ||
| 55 | +// if (StringUtils.hasLength(result)) { | ||
| 56 | +// JSONObject jsonObject = JSON.parseObject(result); | ||
| 57 | +// return jsonObject.getString("text").replace(" ", ""); | ||
| 58 | +// } | ||
| 59 | +// return ""; | ||
| 60 | +// } | ||
| 61 | +// | ||
| 62 | +// | ||
| 63 | +// | ||
| 64 | +// } | ||
| 65 | +// | ||
| 66 | +// public static int toInt(byte[] b) { | ||
| 67 | +// return (((b[3] & 0xff) << 24) + ((b[2] & 0xff) << 16) + ((b[1] & 0xff) << 8) + ((b[0] & 0xff) << 0)); | ||
| 68 | +// } | ||
| 69 | +// | ||
| 70 | +// public static short toShort(byte[] b) { | ||
| 71 | +// return (short) ((b[1] << 8) + (b[0] << 0)); | ||
| 72 | +// } | ||
| 73 | +// | ||
| 74 | +// public static byte[] read(RandomAccessFile rdf, int pos, int length) throws IOException { | ||
| 75 | +// rdf.seek(pos); | ||
| 76 | +// byte result[] = new byte[length]; | ||
| 77 | +// for (int i = 0; i < length; i++) { | ||
| 78 | +// result[i] = rdf.readByte(); | ||
| 79 | +// } | ||
| 80 | +// return result; | ||
| 81 | +// } | ||
| 82 | +// | ||
| 83 | +// public static void reSamplingAndSave(byte[] data, String path) throws IOException, UnsupportedAudioFileException { | ||
| 84 | +// WaveFileReader reader = new WaveFileReader(); | ||
| 85 | +// AudioInputStream audioIn = reader.getAudioInputStream(new ByteArrayInputStream(data)); | ||
| 86 | +// AudioFormat srcFormat = audioIn.getFormat(); | ||
| 87 | +// int targetSampleRate = 16000; | ||
| 88 | +// AudioFormat dstFormat = new AudioFormat(srcFormat.getEncoding(), | ||
| 89 | +// targetSampleRate, | ||
| 90 | +// srcFormat.getSampleSizeInBits(), | ||
| 91 | +// srcFormat.getChannels(), | ||
| 92 | +// srcFormat.getFrameSize(), | ||
| 93 | +// srcFormat.getFrameRate(), | ||
| 94 | +// srcFormat.isBigEndian()); | ||
| 95 | +// AudioInputStream convertedIn = AudioSystem.getAudioInputStream(dstFormat, audioIn); | ||
| 96 | +// File file = new File(path); | ||
| 97 | +// WaveFileWriter writer = new WaveFileWriter(); | ||
| 98 | +// writer.write(convertedIn, AudioFileFormat.Type.WAVE, file); | ||
| 99 | +// }*/ | ||
| 100 | +//} | ||
| 101 | \ No newline at end of file | 101 | \ No newline at end of file |
src/main/java/com/bsth/entity/Cars.java
| 1 | package com.bsth.entity; | 1 | package com.bsth.entity; |
| 2 | 2 | ||
| 3 | import com.bsth.entity.schedule.BEntity; | 3 | import com.bsth.entity.schedule.BEntity; |
| 4 | +import com.fasterxml.jackson.annotation.JsonIgnore; | ||
| 4 | import com.fasterxml.jackson.annotation.JsonIgnoreProperties; | 5 | import com.fasterxml.jackson.annotation.JsonIgnoreProperties; |
| 5 | import org.hibernate.annotations.Formula; | 6 | import org.hibernate.annotations.Formula; |
| 6 | 7 | ||
| @@ -145,6 +146,24 @@ public class Cars extends BEntity implements Serializable { | @@ -145,6 +146,24 @@ public class Cars extends BEntity implements Serializable { | ||
| 145 | /** 线路名称(TODO:在原系统里没有,这里暂时留着,并且不做线路关联,只保留个名字) */ | 146 | /** 线路名称(TODO:在原系统里没有,这里暂时留着,并且不做线路关联,只保留个名字) */ |
| 146 | private String xlmc; | 147 | private String xlmc; |
| 147 | 148 | ||
| 149 | + | ||
| 150 | + //** 车辆颜色 *//* | ||
| 151 | + @Transient | ||
| 152 | + @JsonIgnore | ||
| 153 | + private String color; | ||
| 154 | + //** 车辆最大乘坐人数 *//* | ||
| 155 | + @Transient | ||
| 156 | + @JsonIgnore | ||
| 157 | + private String maxPeople; | ||
| 158 | + //** 票价类型 *//* | ||
| 159 | + @Transient | ||
| 160 | + @JsonIgnore | ||
| 161 | + private String priceType; | ||
| 162 | + //** 票价 *//* | ||
| 163 | + @Transient | ||
| 164 | + @JsonIgnore | ||
| 165 | + private String price; | ||
| 166 | + | ||
| 148 | public Cars() {} | 167 | public Cars() {} |
| 149 | 168 | ||
| 150 | public Cars(Object id, Object nbbh, Object clbh, Object cph, Object sbbh) { | 169 | public Cars(Object id, Object nbbh, Object clbh, Object cph, Object sbbh) { |
| @@ -164,7 +183,40 @@ public class Cars extends BEntity implements Serializable { | @@ -164,7 +183,40 @@ public class Cars extends BEntity implements Serializable { | ||
| 164 | this.equipmentCode = sbbh.toString(); | 183 | this.equipmentCode = sbbh.toString(); |
| 165 | } | 184 | } |
| 166 | } | 185 | } |
| 167 | - | 186 | + |
| 187 | + | ||
| 188 | + public String getColor() { | ||
| 189 | + return color; | ||
| 190 | + } | ||
| 191 | + | ||
| 192 | + public void setColor(String color) { | ||
| 193 | + this.color = color; | ||
| 194 | + } | ||
| 195 | + | ||
| 196 | + public String getMaxPeople() { | ||
| 197 | + return maxPeople; | ||
| 198 | + } | ||
| 199 | + | ||
| 200 | + public void setMaxPeople(String maxPeople) { | ||
| 201 | + this.maxPeople = maxPeople; | ||
| 202 | + } | ||
| 203 | + | ||
| 204 | + public String getPriceType() { | ||
| 205 | + return priceType; | ||
| 206 | + } | ||
| 207 | + | ||
| 208 | + public void setPriceType(String priceType) { | ||
| 209 | + this.priceType = priceType; | ||
| 210 | + } | ||
| 211 | + | ||
| 212 | + public String getPrice() { | ||
| 213 | + return price; | ||
| 214 | + } | ||
| 215 | + | ||
| 216 | + public void setPrice(String price) { | ||
| 217 | + this.price = price; | ||
| 218 | + } | ||
| 219 | + | ||
| 168 | public String getServiceNo() { | 220 | public String getServiceNo() { |
| 169 | return serviceNo; | 221 | return serviceNo; |
| 170 | } | 222 | } |
src/main/java/com/bsth/entity/DKLInfo.java
0 → 100644
| 1 | +package com.bsth.entity; | ||
| 2 | + | ||
| 3 | +import javax.persistence.*; | ||
| 4 | +import java.util.Date; | ||
| 5 | + | ||
| 6 | + | ||
| 7 | + | ||
| 8 | +@Entity | ||
| 9 | +@Table(name = "dkl_info") | ||
| 10 | +public class DKLInfo { | ||
| 11 | + | ||
| 12 | + // ID | ||
| 13 | + @Id | ||
| 14 | + @GeneratedValue(strategy = GenerationType.IDENTITY) | ||
| 15 | + private Integer id; | ||
| 16 | + | ||
| 17 | + private String lineCode; | ||
| 18 | + | ||
| 19 | + private String lineName; | ||
| 20 | + | ||
| 21 | + private String stationCode; | ||
| 22 | + | ||
| 23 | + private String stationName; | ||
| 24 | + | ||
| 25 | + private int num; | ||
| 26 | + | ||
| 27 | + private String upDown; | ||
| 28 | + | ||
| 29 | + private String image; | ||
| 30 | + | ||
| 31 | + // 创建日期 | ||
| 32 | + @Column(updatable = false, name = "create_date", columnDefinition = "TIMESTAMP DEFAULT CURRENT_TIMESTAMP") | ||
| 33 | + private Date createDate; | ||
| 34 | + | ||
| 35 | + | ||
| 36 | + public Integer getId() { | ||
| 37 | + return id; | ||
| 38 | + } | ||
| 39 | + | ||
| 40 | + public void setId(Integer id) { | ||
| 41 | + this.id = id; | ||
| 42 | + } | ||
| 43 | + | ||
| 44 | + public String getLineCode() { | ||
| 45 | + return lineCode; | ||
| 46 | + } | ||
| 47 | + | ||
| 48 | + public void setLineCode(String lineCode) { | ||
| 49 | + this.lineCode = lineCode; | ||
| 50 | + } | ||
| 51 | + | ||
| 52 | + public String getLineName() { | ||
| 53 | + return lineName; | ||
| 54 | + } | ||
| 55 | + | ||
| 56 | + public void setLineName(String lineName) { | ||
| 57 | + this.lineName = lineName; | ||
| 58 | + } | ||
| 59 | + | ||
| 60 | + public String getStationCode() { | ||
| 61 | + return stationCode; | ||
| 62 | + } | ||
| 63 | + | ||
| 64 | + public void setStationCode(String stationCode) { | ||
| 65 | + this.stationCode = stationCode; | ||
| 66 | + } | ||
| 67 | + | ||
| 68 | + public String getStationName() { | ||
| 69 | + return stationName; | ||
| 70 | + } | ||
| 71 | + | ||
| 72 | + public void setStationName(String stationName) { | ||
| 73 | + this.stationName = stationName; | ||
| 74 | + } | ||
| 75 | + | ||
| 76 | + public int getNum() { | ||
| 77 | + return num; | ||
| 78 | + } | ||
| 79 | + | ||
| 80 | + public void setNum(int num) { | ||
| 81 | + this.num = num; | ||
| 82 | + } | ||
| 83 | + | ||
| 84 | + public String getUpDown() { | ||
| 85 | + return upDown; | ||
| 86 | + } | ||
| 87 | + | ||
| 88 | + public void setUpDown(String upDown) { | ||
| 89 | + this.upDown = upDown; | ||
| 90 | + } | ||
| 91 | + | ||
| 92 | + public String getImage() { | ||
| 93 | + return image; | ||
| 94 | + } | ||
| 95 | + | ||
| 96 | + public void setImage(String image) { | ||
| 97 | + this.image = image; | ||
| 98 | + } | ||
| 99 | + | ||
| 100 | + public Date getCreateDate() { | ||
| 101 | + return createDate; | ||
| 102 | + } | ||
| 103 | + | ||
| 104 | + public void setCreateDate(Date createDate) { | ||
| 105 | + this.createDate = createDate; | ||
| 106 | + } | ||
| 107 | + | ||
| 108 | +} |
src/main/java/com/bsth/entity/directive/D80.java
| @@ -78,6 +78,7 @@ public class D80 { | @@ -78,6 +78,7 @@ public class D80 { | ||
| 78 | @JsonIgnore | 78 | @JsonIgnore |
| 79 | private Short requestCode; | 79 | private Short requestCode; |
| 80 | 80 | ||
| 81 | + | ||
| 81 | public Long getSchId() { | 82 | public Long getSchId() { |
| 82 | return schId; | 83 | return schId; |
| 83 | } | 84 | } |
| @@ -110,6 +111,30 @@ public class D80 { | @@ -110,6 +111,30 @@ public class D80 { | ||
| 110 | this.requestCode = requestCode; | 111 | this.requestCode = requestCode; |
| 111 | } | 112 | } |
| 112 | 113 | ||
| 114 | + @Transient | ||
| 115 | + @JsonIgnore | ||
| 116 | + private String stationName; | ||
| 117 | + @Transient | ||
| 118 | + @JsonIgnore | ||
| 119 | + private Long nextschId; | ||
| 120 | + | ||
| 121 | + public Long getNextschId() { | ||
| 122 | + return nextschId; | ||
| 123 | + } | ||
| 124 | + | ||
| 125 | + public void setNextschId(Long nextschId) { | ||
| 126 | + this.nextschId = nextschId; | ||
| 127 | + } | ||
| 128 | + | ||
| 129 | + public String getStationName() { | ||
| 130 | + return stationName; | ||
| 131 | + } | ||
| 132 | + | ||
| 133 | + public void setStationName(String stationName) { | ||
| 134 | + this.stationName = stationName; | ||
| 135 | + } | ||
| 136 | + | ||
| 137 | + | ||
| 113 | @Embeddable | 138 | @Embeddable |
| 114 | public static class D80Data { | 139 | public static class D80Data { |
| 115 | 140 | ||
| @@ -121,6 +146,9 @@ public class D80 { | @@ -121,6 +146,9 @@ public class D80 { | ||
| 121 | /** | 146 | /** |
| 122 | * 请求代码 0xa1 恢复运营 0xa2 申请调档 0xa3 出场请求 0xa5 进场请求 0xa7 加油请求 0x50 车辆故障 0x70 | 147 | * 请求代码 0xa1 恢复运营 0xa2 申请调档 0xa3 出场请求 0xa5 进场请求 0xa7 加油请求 0x50 车辆故障 0x70 |
| 123 | * 路阻报告 0x60 事故报告 0x11 扣证纠纷 0x12 报警 0x10 S0S | 148 | * 路阻报告 0x60 事故报告 0x11 扣证纠纷 0x12 报警 0x10 S0S |
| 149 | + * 0x21 单车有人伤 0x22 单车无人伤 | ||
| 150 | + * 0x23 双车有人伤 0x24 双车无人伤 | ||
| 151 | + * | ||
| 124 | */ | 152 | */ |
| 125 | private Short requestCode; | 153 | private Short requestCode; |
| 126 | 154 | ||
| @@ -134,7 +162,48 @@ public class D80 { | @@ -134,7 +162,48 @@ public class D80 { | ||
| 134 | */ | 162 | */ |
| 135 | @Transient | 163 | @Transient |
| 136 | private String nbbm; | 164 | private String nbbm; |
| 137 | - | 165 | + /** |
| 166 | + * 经度 | ||
| 167 | + */ | ||
| 168 | + @Transient | ||
| 169 | + @JsonIgnore | ||
| 170 | + private Float lon; | ||
| 171 | + | ||
| 172 | + /** | ||
| 173 | + * 纬度 | ||
| 174 | + */ | ||
| 175 | + @Transient | ||
| 176 | + @JsonIgnore | ||
| 177 | + private Float lat; | ||
| 178 | + @Transient | ||
| 179 | + @JsonIgnore | ||
| 180 | + private String stopNo; | ||
| 181 | + | ||
| 182 | + | ||
| 183 | + public String getStopNo() { | ||
| 184 | + return stopNo; | ||
| 185 | + } | ||
| 186 | + | ||
| 187 | + public void setStopNo(String stopNo) { | ||
| 188 | + this.stopNo = stopNo; | ||
| 189 | + } | ||
| 190 | + | ||
| 191 | + public Float getLon() { | ||
| 192 | + return lon; | ||
| 193 | + } | ||
| 194 | + | ||
| 195 | + public void setLon(Float lon) { | ||
| 196 | + this.lon = lon; | ||
| 197 | + } | ||
| 198 | + | ||
| 199 | + public Float getLat() { | ||
| 200 | + return lat; | ||
| 201 | + } | ||
| 202 | + | ||
| 203 | + public void setLat(Float lat) { | ||
| 204 | + this.lat = lat; | ||
| 205 | + } | ||
| 206 | + | ||
| 138 | public Short getOperCode2() { | 207 | public Short getOperCode2() { |
| 139 | return operCode2; | 208 | return operCode2; |
| 140 | } | 209 | } |
src/main/java/com/bsth/entity/lg_travel/Region.java
0 → 100644
| 1 | +package com.bsth.entity.lg_travel; | ||
| 2 | + | ||
| 3 | +import com.bsth.entity.schedule.BEntity; | ||
| 4 | + | ||
| 5 | +import javax.persistence.Entity; | ||
| 6 | +import javax.persistence.Id; | ||
| 7 | +import javax.persistence.Table; | ||
| 8 | +import java.io.Serializable; | ||
| 9 | + | ||
| 10 | +/** | ||
| 11 | + * 区域 | ||
| 12 | + */ | ||
| 13 | +@Entity | ||
| 14 | +@Table(name = "bsth_c_region") | ||
| 15 | +public class Region extends BEntity implements Serializable { | ||
| 16 | + @Id | ||
| 17 | + private Long id; | ||
| 18 | + //区域名称 | ||
| 19 | + private String name; | ||
| 20 | + //是否删除 | ||
| 21 | + private String destroy; | ||
| 22 | + | ||
| 23 | + | ||
| 24 | + | ||
| 25 | + | ||
| 26 | + public void setId(Long id) { | ||
| 27 | + this.id = id; | ||
| 28 | + } | ||
| 29 | + | ||
| 30 | + public Long getId() { | ||
| 31 | + return id; | ||
| 32 | + } | ||
| 33 | + | ||
| 34 | + public String getName() { | ||
| 35 | + return name; | ||
| 36 | + } | ||
| 37 | + | ||
| 38 | + public void setName(String name) { | ||
| 39 | + this.name = name; | ||
| 40 | + } | ||
| 41 | + | ||
| 42 | + public String getDestroy() { | ||
| 43 | + return destroy; | ||
| 44 | + } | ||
| 45 | + | ||
| 46 | + public void setDestroy(String destroy) { | ||
| 47 | + this.destroy = destroy; | ||
| 48 | + } | ||
| 49 | +} | ||
| 0 | \ No newline at end of file | 50 | \ No newline at end of file |
src/main/java/com/bsth/entity/lg_travel/RegionLineCar.java
0 → 100644
| 1 | +package com.bsth.entity.lg_travel; | ||
| 2 | + | ||
| 3 | +import com.bsth.entity.Line; | ||
| 4 | +import com.bsth.entity.schedule.BEntity; | ||
| 5 | + | ||
| 6 | +import javax.persistence.*; | ||
| 7 | +import java.io.Serializable; | ||
| 8 | + | ||
| 9 | +/** | ||
| 10 | + * 区域 | ||
| 11 | + */ | ||
| 12 | +@Entity | ||
| 13 | +@Table(name = "bsth_c_region_line_car") | ||
| 14 | +public class RegionLineCar extends BEntity implements Serializable { | ||
| 15 | + @Id | ||
| 16 | + @GeneratedValue(strategy = GenerationType.IDENTITY) | ||
| 17 | + private Long id; | ||
| 18 | + //区域名称 | ||
| 19 | + @ManyToOne | ||
| 20 | + private Region region; | ||
| 21 | + //线路 | ||
| 22 | + @ManyToOne | ||
| 23 | + private Line line; | ||
| 24 | + //线路名称 | ||
| 25 | + private String lineName; | ||
| 26 | + //车辆自编号 | ||
| 27 | + private String clZbh; | ||
| 28 | + | ||
| 29 | + public Long getId() { | ||
| 30 | + return id; | ||
| 31 | + } | ||
| 32 | + | ||
| 33 | + public void setId(Long id) { | ||
| 34 | + this.id = id; | ||
| 35 | + } | ||
| 36 | + | ||
| 37 | + | ||
| 38 | + public Region getRegion() { | ||
| 39 | + return region; | ||
| 40 | + } | ||
| 41 | + | ||
| 42 | + public void setRegion(Region region) { | ||
| 43 | + this.region = region; | ||
| 44 | + } | ||
| 45 | + | ||
| 46 | + public Line getLine() { | ||
| 47 | + return line; | ||
| 48 | + } | ||
| 49 | + | ||
| 50 | + public void setLine(Line line) { | ||
| 51 | + this.line = line; | ||
| 52 | + } | ||
| 53 | + | ||
| 54 | + public String getLineName() { | ||
| 55 | + return lineName; | ||
| 56 | + } | ||
| 57 | + | ||
| 58 | + public void setLineName(String lineName) { | ||
| 59 | + this.lineName = lineName; | ||
| 60 | + } | ||
| 61 | + | ||
| 62 | + public String getClZbh() { | ||
| 63 | + return clZbh; | ||
| 64 | + } | ||
| 65 | + | ||
| 66 | + public void setClZbh(String clZbh) { | ||
| 67 | + this.clZbh = clZbh; | ||
| 68 | + } | ||
| 69 | + | ||
| 70 | + | ||
| 71 | +} | ||
| 0 | \ No newline at end of file | 72 | \ No newline at end of file |
src/main/java/com/bsth/entity/oil/Dlb.java
| 1 | -package com.bsth.entity.oil; | ||
| 2 | - | ||
| 3 | -import java.text.DecimalFormat; | ||
| 4 | -import java.util.Date; | ||
| 5 | - | ||
| 6 | -import javax.persistence.*; | ||
| 7 | - | ||
| 8 | -import org.springframework.format.annotation.DateTimeFormat; | ||
| 9 | - | ||
| 10 | -import com.bsth.data.BasicData; | ||
| 11 | - | ||
| 12 | -@Entity | ||
| 13 | -@Table(name = "bsth_c_dlb") | ||
| 14 | -public class Dlb { | ||
| 15 | - @Id | ||
| 16 | - @GeneratedValue(strategy = GenerationType.IDENTITY) | ||
| 17 | - private Integer id; | ||
| 18 | - @DateTimeFormat(pattern="yyyy-MM-dd") | ||
| 19 | - private Date rq; | ||
| 20 | - private String xlbm; | ||
| 21 | - private String linename; | ||
| 22 | - private String ssgsdm; | ||
| 23 | - private String fgsdm; | ||
| 24 | - private String nbbm; | ||
| 25 | - private String jsy; | ||
| 26 | - private Double czlc=0.0; | ||
| 27 | - private Double jzlc=0.0; | ||
| 28 | - //出站存电 | ||
| 29 | - private Double czcd=0.0; | ||
| 30 | - //进站存电 | ||
| 31 | - private Double jzcd=0.0; | ||
| 32 | - //充电量 | ||
| 33 | - private Double cdl; | ||
| 34 | - private int sfkt; | ||
| 35 | - private String jhsj; | ||
| 36 | - //耗电 | ||
| 37 | - private Double hd=0.0; | ||
| 38 | - private Double sh=0.0; | ||
| 39 | - private String shyy; | ||
| 40 | - private Double zlc=0.0; | ||
| 41 | - private int yhlx; | ||
| 42 | - | ||
| 43 | - private Double ns=0.0; | ||
| 44 | - private Double fyylc=0.0; | ||
| 45 | - private Double jhzlc=0.0; | ||
| 46 | - private Double jhfyylc=0.0; | ||
| 47 | - private int jhzbc; | ||
| 48 | - private int jhbc; | ||
| 49 | - private int sjzbc; | ||
| 50 | - private int sjbc; | ||
| 51 | - private String edituser; | ||
| 52 | - private Date edittime; | ||
| 53 | - private Date createtime; | ||
| 54 | - private Date updatetime; | ||
| 55 | - private int nylx; | ||
| 56 | - //进场顺序(根据最先出场和最后进场来关联车辆的存电量) | ||
| 57 | - private int jcsx; | ||
| 58 | - | ||
| 59 | - private String jname; | ||
| 60 | - @Transient | ||
| 61 | - private String name; | ||
| 62 | - @Transient | ||
| 63 | - private String bglyh; | ||
| 64 | - | ||
| 65 | - @Transient | ||
| 66 | - private String xlname; | ||
| 67 | - | ||
| 68 | - @Transient | ||
| 69 | - private String gsname; | ||
| 70 | - | ||
| 71 | - @Transient | ||
| 72 | - private String fgsname; | ||
| 73 | - | ||
| 74 | - | ||
| 75 | - | ||
| 76 | - private String lp; | ||
| 77 | - | ||
| 78 | - public Integer getId() { | ||
| 79 | - return id; | ||
| 80 | - } | ||
| 81 | - | ||
| 82 | - public void setId(Integer id) { | ||
| 83 | - this.id = id; | ||
| 84 | - } | ||
| 85 | - | ||
| 86 | - public Date getRq() { | ||
| 87 | - return rq; | ||
| 88 | - } | ||
| 89 | - | ||
| 90 | - public void setRq(Date rq) { | ||
| 91 | - this.rq = rq; | ||
| 92 | - } | ||
| 93 | - | ||
| 94 | - public String getXlbm() { | ||
| 95 | - return xlbm; | ||
| 96 | - } | ||
| 97 | - | ||
| 98 | - public void setXlbm(String xlbm) { | ||
| 99 | - this.xlbm = xlbm; | ||
| 100 | - } | ||
| 101 | - | ||
| 102 | - public String getLinename() { | ||
| 103 | - return linename; | ||
| 104 | - } | ||
| 105 | - | ||
| 106 | - public void setLinename(String linename) { | ||
| 107 | - this.linename = linename; | ||
| 108 | - } | ||
| 109 | - | ||
| 110 | - public String getSsgsdm() { | ||
| 111 | - return ssgsdm; | ||
| 112 | - } | ||
| 113 | - | ||
| 114 | - public void setSsgsdm(String ssgsdm) { | ||
| 115 | - this.ssgsdm = ssgsdm; | ||
| 116 | - } | ||
| 117 | - | ||
| 118 | - public String getFgsdm() { | ||
| 119 | - return fgsdm; | ||
| 120 | - } | ||
| 121 | - | ||
| 122 | - public void setFgsdm(String fgsdm) { | ||
| 123 | - this.fgsdm = fgsdm; | ||
| 124 | - } | ||
| 125 | - | ||
| 126 | - public String getNbbm() { | ||
| 127 | - return nbbm; | ||
| 128 | - } | ||
| 129 | - | ||
| 130 | - public void setNbbm(String nbbm) { | ||
| 131 | - this.nbbm = nbbm; | ||
| 132 | - } | ||
| 133 | - | ||
| 134 | - public String getJsy() { | ||
| 135 | - return jsy; | ||
| 136 | - } | ||
| 137 | - | ||
| 138 | - public void setJsy(String jsy) { | ||
| 139 | - this.jsy = jsy; | ||
| 140 | - } | ||
| 141 | - | ||
| 142 | - public Double getCzlc() { | ||
| 143 | - return czlc; | ||
| 144 | - } | ||
| 145 | - | ||
| 146 | - public void setCzlc(Double czlc) { | ||
| 147 | - this.czlc = czlc; | ||
| 148 | - } | ||
| 149 | - | ||
| 150 | - public Double getJzlc() { | ||
| 151 | - return jzlc; | ||
| 152 | - } | ||
| 153 | - | ||
| 154 | - public void setJzlc(Double jzlc) { | ||
| 155 | - this.jzlc = jzlc; | ||
| 156 | - } | ||
| 157 | - | ||
| 158 | - public Double getCzcd() { | ||
| 159 | - return czcd; | ||
| 160 | - } | ||
| 161 | - | ||
| 162 | - public void setCzcd(Double czcd) { | ||
| 163 | - this.czcd = czcd; | ||
| 164 | - } | ||
| 165 | - | ||
| 166 | - public Double getJzcd() { | ||
| 167 | - return jzcd; | ||
| 168 | - } | ||
| 169 | - | ||
| 170 | - public void setJzcd(Double jzcd) { | ||
| 171 | - this.jzcd = jzcd; | ||
| 172 | - } | ||
| 173 | - | ||
| 174 | - public Double getCdl() { | ||
| 175 | - return cdl; | ||
| 176 | - } | ||
| 177 | - | ||
| 178 | - public void setCdl(Double cdl) { | ||
| 179 | - this.cdl = cdl; | ||
| 180 | - } | ||
| 181 | - | ||
| 182 | - public int getSfkt() { | ||
| 183 | - return sfkt; | ||
| 184 | - } | ||
| 185 | - | ||
| 186 | - public void setSfkt(int sfkt) { | ||
| 187 | - this.sfkt = sfkt; | ||
| 188 | - } | ||
| 189 | - | ||
| 190 | - public String getJhsj() { | ||
| 191 | - return jhsj; | ||
| 192 | - } | ||
| 193 | - | ||
| 194 | - public void setJhsj(String jhsj) { | ||
| 195 | - this.jhsj = jhsj; | ||
| 196 | - } | ||
| 197 | - | ||
| 198 | - public Double getHd() { | ||
| 199 | - return hd; | ||
| 200 | - } | ||
| 201 | - | ||
| 202 | - public void setHd(Double hd) { | ||
| 203 | - this.hd = hd; | ||
| 204 | - } | ||
| 205 | - | ||
| 206 | - public Double getSh() { | ||
| 207 | - return sh; | ||
| 208 | - } | ||
| 209 | - | ||
| 210 | - public void setSh(Double sh) { | ||
| 211 | - this.sh = sh; | ||
| 212 | - } | ||
| 213 | - | ||
| 214 | - public String getShyy() { | ||
| 215 | - return shyy; | ||
| 216 | - } | ||
| 217 | - | ||
| 218 | - public void setShyy(String shyy) { | ||
| 219 | - this.shyy = shyy; | ||
| 220 | - } | ||
| 221 | - | ||
| 222 | - public Double getZlc() { | ||
| 223 | - return zlc; | ||
| 224 | - } | ||
| 225 | - | ||
| 226 | - public void setZlc(Double zlc) { | ||
| 227 | - this.zlc = zlc; | ||
| 228 | - } | ||
| 229 | - | ||
| 230 | - public int getYhlx() { | ||
| 231 | - return yhlx; | ||
| 232 | - } | ||
| 233 | - | ||
| 234 | - public void setYhlx(int yhlx) { | ||
| 235 | - this.yhlx = yhlx; | ||
| 236 | - } | ||
| 237 | - | ||
| 238 | - public Double getNs() { | ||
| 239 | - return ns; | ||
| 240 | - } | ||
| 241 | - | ||
| 242 | - public void setNs(Double ns) { | ||
| 243 | - this.ns = ns; | ||
| 244 | - } | ||
| 245 | - | ||
| 246 | - public Double getFyylc() { | ||
| 247 | - return fyylc; | ||
| 248 | - } | ||
| 249 | - | ||
| 250 | - public void setFyylc(Double fyylc) { | ||
| 251 | - this.fyylc = fyylc; | ||
| 252 | - } | ||
| 253 | - | ||
| 254 | - public Double getJhzlc() { | ||
| 255 | - return jhzlc; | ||
| 256 | - } | ||
| 257 | - | ||
| 258 | - public void setJhzlc(Double jhzlc) { | ||
| 259 | - this.jhzlc = jhzlc; | ||
| 260 | - } | ||
| 261 | - | ||
| 262 | - public Double getJhfyylc() { | ||
| 263 | - return jhfyylc; | ||
| 264 | - } | ||
| 265 | - | ||
| 266 | - public void setJhfyylc(Double jhfyylc) { | ||
| 267 | - this.jhfyylc = jhfyylc; | ||
| 268 | - } | ||
| 269 | - | ||
| 270 | - public int getJhzbc() { | ||
| 271 | - return jhzbc; | ||
| 272 | - } | ||
| 273 | - | ||
| 274 | - public void setJhzbc(int jhzbc) { | ||
| 275 | - this.jhzbc = jhzbc; | ||
| 276 | - } | ||
| 277 | - | ||
| 278 | - public int getJhbc() { | ||
| 279 | - return jhbc; | ||
| 280 | - } | ||
| 281 | - | ||
| 282 | - public void setJhbc(int jhbc) { | ||
| 283 | - this.jhbc = jhbc; | ||
| 284 | - } | ||
| 285 | - | ||
| 286 | - public int getSjzbc() { | ||
| 287 | - return sjzbc; | ||
| 288 | - } | ||
| 289 | - | ||
| 290 | - public void setSjzbc(int sjzbc) { | ||
| 291 | - this.sjzbc = sjzbc; | ||
| 292 | - } | ||
| 293 | - | ||
| 294 | - public int getSjbc() { | ||
| 295 | - return sjbc; | ||
| 296 | - } | ||
| 297 | - | ||
| 298 | - public void setSjbc(int sjbc) { | ||
| 299 | - this.sjbc = sjbc; | ||
| 300 | - } | ||
| 301 | - | ||
| 302 | - public String getEdituser() { | ||
| 303 | - return edituser; | ||
| 304 | - } | ||
| 305 | - | ||
| 306 | - public void setEdituser(String edituser) { | ||
| 307 | - this.edituser = edituser; | ||
| 308 | - } | ||
| 309 | - | ||
| 310 | - public Date getEdittime() { | ||
| 311 | - return edittime; | ||
| 312 | - } | ||
| 313 | - | ||
| 314 | - public void setEdittime(Date edittime) { | ||
| 315 | - this.edittime = edittime; | ||
| 316 | - } | ||
| 317 | - | ||
| 318 | - public Date getCreatetime() { | ||
| 319 | - return createtime; | ||
| 320 | - } | ||
| 321 | - | ||
| 322 | - public void setCreatetime(Date createtime) { | ||
| 323 | - this.createtime = createtime; | ||
| 324 | - } | ||
| 325 | - | ||
| 326 | - public int getNylx() { | ||
| 327 | - return nylx; | ||
| 328 | - } | ||
| 329 | - | ||
| 330 | - public void setNylx(int nylx) { | ||
| 331 | - this.nylx = nylx; | ||
| 332 | - } | ||
| 333 | - | ||
| 334 | - public int getJcsx() { | ||
| 335 | - return jcsx; | ||
| 336 | - } | ||
| 337 | - | ||
| 338 | - public void setJcsx(int jcsx) { | ||
| 339 | - this.jcsx = jcsx; | ||
| 340 | - } | ||
| 341 | - | ||
| 342 | - public String getBglyh() { | ||
| 343 | - if(this.getZlc()==0){ | ||
| 344 | - return "0"; | ||
| 345 | - }else{ | ||
| 346 | - DecimalFormat df = new DecimalFormat("0.00"); | ||
| 347 | - return df.format(this.getHd()/this.getZlc()*100); | ||
| 348 | - } | ||
| 349 | - } | ||
| 350 | - | ||
| 351 | - public void setBglyh(String bglyh) { | ||
| 352 | - this.bglyh = bglyh; | ||
| 353 | - } | ||
| 354 | - | ||
| 355 | - public String getXlname() { | ||
| 356 | - return BasicData.lineCodeAllNameMap.get(this.xlbm); | ||
| 357 | - } | ||
| 358 | - | ||
| 359 | - public void setXlname(String xlname) { | ||
| 360 | - this.xlname = xlname; | ||
| 361 | - } | ||
| 362 | - | ||
| 363 | - public String getGsname() { | ||
| 364 | - return BasicData.businessCodeNameMap.get(this.ssgsdm); | ||
| 365 | - } | ||
| 366 | - | ||
| 367 | - public void setGsname(String gsname) { | ||
| 368 | - this.gsname = gsname; | ||
| 369 | - } | ||
| 370 | - | ||
| 371 | - public String getName() { | ||
| 372 | - return BasicData.allPerson.get(this.ssgsdm+"-"+this.jsy); | ||
| 373 | - } | ||
| 374 | - | ||
| 375 | - public void setName(String name) { | ||
| 376 | - this.name = name; | ||
| 377 | - } | ||
| 378 | - | ||
| 379 | - public String getFgsname() { | ||
| 380 | - return BasicData.businessFgsCodeNameMap.get(this.fgsdm+"_"+this.ssgsdm); | ||
| 381 | - } | ||
| 382 | - | ||
| 383 | - public void setFgsname(String fgsname) { | ||
| 384 | - this.fgsname = fgsname; | ||
| 385 | - } | ||
| 386 | - | ||
| 387 | - public Date getUpdatetime() { | ||
| 388 | - return updatetime; | ||
| 389 | - } | ||
| 390 | - | ||
| 391 | - public void setUpdatetime(Date updatetime) { | ||
| 392 | - this.updatetime = updatetime; | ||
| 393 | - } | ||
| 394 | - | ||
| 395 | - public String getLp() { | ||
| 396 | - return lp; | ||
| 397 | - } | ||
| 398 | - | ||
| 399 | - public void setLp(String lp) { | ||
| 400 | - this.lp = lp; | ||
| 401 | - } | ||
| 402 | - | ||
| 403 | - public String getJname() { | ||
| 404 | - return jname; | ||
| 405 | - } | ||
| 406 | - | ||
| 407 | - public void setJname(String jname) { | ||
| 408 | - this.jname = jname; | ||
| 409 | - } | ||
| 410 | - | ||
| 411 | - | ||
| 412 | - | ||
| 413 | -} | 1 | +package com.bsth.entity.oil; |
| 2 | + | ||
| 3 | +import java.text.DecimalFormat; | ||
| 4 | +import java.util.Date; | ||
| 5 | + | ||
| 6 | +import javax.persistence.*; | ||
| 7 | + | ||
| 8 | +import org.springframework.format.annotation.DateTimeFormat; | ||
| 9 | + | ||
| 10 | +import com.bsth.data.BasicData; | ||
| 11 | + | ||
| 12 | +@Entity | ||
| 13 | +@Table(name = "bsth_c_dlb") | ||
| 14 | +public class Dlb { | ||
| 15 | + @Id | ||
| 16 | + @GeneratedValue(strategy = GenerationType.IDENTITY) | ||
| 17 | + private Integer id; | ||
| 18 | + @DateTimeFormat(pattern="yyyy-MM-dd") | ||
| 19 | + private Date rq; | ||
| 20 | + private String xlbm; | ||
| 21 | + private String linename; | ||
| 22 | + private String ssgsdm; | ||
| 23 | + private String fgsdm; | ||
| 24 | + private String nbbm; | ||
| 25 | + private String jsy; | ||
| 26 | + private Double czlc=0.0; | ||
| 27 | + private Double jzlc=0.0; | ||
| 28 | + //出站存电 | ||
| 29 | + private Double czcd=0.0; | ||
| 30 | + //进站存电 | ||
| 31 | + private Double jzcd=0.0; | ||
| 32 | + //充电量 | ||
| 33 | + private Double cdl; | ||
| 34 | + private int sfkt; | ||
| 35 | + private String jhsj; | ||
| 36 | + //耗电 | ||
| 37 | + private Double hd=0.0; | ||
| 38 | + private Double sh=0.0; | ||
| 39 | + private String shyy; | ||
| 40 | + private Double zlc=0.0; | ||
| 41 | + private int yhlx; | ||
| 42 | + | ||
| 43 | + private Double ns=0.0; | ||
| 44 | + private Double fyylc=0.0; | ||
| 45 | + private Double jhzlc=0.0; | ||
| 46 | + private Double jhfyylc=0.0; | ||
| 47 | + private int jhzbc; | ||
| 48 | + private int jhbc; | ||
| 49 | + private int sjzbc; | ||
| 50 | + private int sjbc; | ||
| 51 | + private String edituser; | ||
| 52 | + private Date edittime; | ||
| 53 | + private Date createtime; | ||
| 54 | + private Date updatetime; | ||
| 55 | + private int nylx; | ||
| 56 | + //进场顺序(根据最先出场和最后进场来关联车辆的存电量) | ||
| 57 | + private int jcsx; | ||
| 58 | + | ||
| 59 | + private String jname; | ||
| 60 | + @Transient | ||
| 61 | + private String name; | ||
| 62 | + @Transient | ||
| 63 | + private String bglyh; | ||
| 64 | + | ||
| 65 | + @Transient | ||
| 66 | + private String xlname; | ||
| 67 | + | ||
| 68 | + @Transient | ||
| 69 | + private String gsname; | ||
| 70 | + | ||
| 71 | + @Transient | ||
| 72 | + private String fgsname; | ||
| 73 | + | ||
| 74 | + | ||
| 75 | + | ||
| 76 | + private String lp; | ||
| 77 | + | ||
| 78 | + public Integer getId() { | ||
| 79 | + return id; | ||
| 80 | + } | ||
| 81 | + | ||
| 82 | + public void setId(Integer id) { | ||
| 83 | + this.id = id; | ||
| 84 | + } | ||
| 85 | + | ||
| 86 | + public Date getRq() { | ||
| 87 | + return rq; | ||
| 88 | + } | ||
| 89 | + | ||
| 90 | + public void setRq(Date rq) { | ||
| 91 | + this.rq = rq; | ||
| 92 | + } | ||
| 93 | + | ||
| 94 | + public String getXlbm() { | ||
| 95 | + return xlbm; | ||
| 96 | + } | ||
| 97 | + | ||
| 98 | + public void setXlbm(String xlbm) { | ||
| 99 | + this.xlbm = xlbm; | ||
| 100 | + } | ||
| 101 | + | ||
| 102 | + public String getLinename() { | ||
| 103 | + return linename; | ||
| 104 | + } | ||
| 105 | + | ||
| 106 | + public void setLinename(String linename) { | ||
| 107 | + this.linename = linename; | ||
| 108 | + } | ||
| 109 | + | ||
| 110 | + public String getSsgsdm() { | ||
| 111 | + return ssgsdm; | ||
| 112 | + } | ||
| 113 | + | ||
| 114 | + public void setSsgsdm(String ssgsdm) { | ||
| 115 | + this.ssgsdm = ssgsdm; | ||
| 116 | + } | ||
| 117 | + | ||
| 118 | + public String getFgsdm() { | ||
| 119 | + return fgsdm; | ||
| 120 | + } | ||
| 121 | + | ||
| 122 | + public void setFgsdm(String fgsdm) { | ||
| 123 | + this.fgsdm = fgsdm; | ||
| 124 | + } | ||
| 125 | + | ||
| 126 | + public String getNbbm() { | ||
| 127 | + return nbbm; | ||
| 128 | + } | ||
| 129 | + | ||
| 130 | + public void setNbbm(String nbbm) { | ||
| 131 | + this.nbbm = nbbm; | ||
| 132 | + } | ||
| 133 | + | ||
| 134 | + public String getJsy() { | ||
| 135 | + return jsy; | ||
| 136 | + } | ||
| 137 | + | ||
| 138 | + public void setJsy(String jsy) { | ||
| 139 | + this.jsy = jsy; | ||
| 140 | + } | ||
| 141 | + | ||
| 142 | + public Double getCzlc() { | ||
| 143 | + return czlc; | ||
| 144 | + } | ||
| 145 | + | ||
| 146 | + public void setCzlc(Double czlc) { | ||
| 147 | + this.czlc = czlc; | ||
| 148 | + } | ||
| 149 | + | ||
| 150 | + public Double getJzlc() { | ||
| 151 | + return jzlc; | ||
| 152 | + } | ||
| 153 | + | ||
| 154 | + public void setJzlc(Double jzlc) { | ||
| 155 | + this.jzlc = jzlc; | ||
| 156 | + } | ||
| 157 | + | ||
| 158 | + public Double getCzcd() { | ||
| 159 | + return czcd; | ||
| 160 | + } | ||
| 161 | + | ||
| 162 | + public void setCzcd(Double czcd) { | ||
| 163 | + this.czcd = czcd; | ||
| 164 | + } | ||
| 165 | + | ||
| 166 | + public Double getJzcd() { | ||
| 167 | + return jzcd; | ||
| 168 | + } | ||
| 169 | + | ||
| 170 | + public void setJzcd(Double jzcd) { | ||
| 171 | + this.jzcd = jzcd; | ||
| 172 | + } | ||
| 173 | + | ||
| 174 | + public Double getCdl() { | ||
| 175 | + return cdl; | ||
| 176 | + } | ||
| 177 | + | ||
| 178 | + public void setCdl(Double cdl) { | ||
| 179 | + this.cdl = cdl; | ||
| 180 | + } | ||
| 181 | + | ||
| 182 | + public int getSfkt() { | ||
| 183 | + return sfkt; | ||
| 184 | + } | ||
| 185 | + | ||
| 186 | + public void setSfkt(int sfkt) { | ||
| 187 | + this.sfkt = sfkt; | ||
| 188 | + } | ||
| 189 | + | ||
| 190 | + public String getJhsj() { | ||
| 191 | + return jhsj; | ||
| 192 | + } | ||
| 193 | + | ||
| 194 | + public void setJhsj(String jhsj) { | ||
| 195 | + this.jhsj = jhsj; | ||
| 196 | + } | ||
| 197 | + | ||
| 198 | + public Double getHd() { | ||
| 199 | + return hd; | ||
| 200 | + } | ||
| 201 | + | ||
| 202 | + public void setHd(Double hd) { | ||
| 203 | + this.hd = hd; | ||
| 204 | + } | ||
| 205 | + | ||
| 206 | + public Double getSh() { | ||
| 207 | + return sh; | ||
| 208 | + } | ||
| 209 | + | ||
| 210 | + public void setSh(Double sh) { | ||
| 211 | + this.sh = sh; | ||
| 212 | + } | ||
| 213 | + | ||
| 214 | + public String getShyy() { | ||
| 215 | + return shyy; | ||
| 216 | + } | ||
| 217 | + | ||
| 218 | + public void setShyy(String shyy) { | ||
| 219 | + this.shyy = shyy; | ||
| 220 | + } | ||
| 221 | + | ||
| 222 | + public Double getZlc() { | ||
| 223 | + return zlc; | ||
| 224 | + } | ||
| 225 | + | ||
| 226 | + public void setZlc(Double zlc) { | ||
| 227 | + this.zlc = zlc; | ||
| 228 | + } | ||
| 229 | + | ||
| 230 | + public int getYhlx() { | ||
| 231 | + return yhlx; | ||
| 232 | + } | ||
| 233 | + | ||
| 234 | + public void setYhlx(int yhlx) { | ||
| 235 | + this.yhlx = yhlx; | ||
| 236 | + } | ||
| 237 | + | ||
| 238 | + public Double getNs() { | ||
| 239 | + return ns; | ||
| 240 | + } | ||
| 241 | + | ||
| 242 | + public void setNs(Double ns) { | ||
| 243 | + this.ns = ns; | ||
| 244 | + } | ||
| 245 | + | ||
| 246 | + public Double getFyylc() { | ||
| 247 | + return fyylc; | ||
| 248 | + } | ||
| 249 | + | ||
| 250 | + public void setFyylc(Double fyylc) { | ||
| 251 | + this.fyylc = fyylc; | ||
| 252 | + } | ||
| 253 | + | ||
| 254 | + public Double getJhzlc() { | ||
| 255 | + return jhzlc; | ||
| 256 | + } | ||
| 257 | + | ||
| 258 | + public void setJhzlc(Double jhzlc) { | ||
| 259 | + this.jhzlc = jhzlc; | ||
| 260 | + } | ||
| 261 | + | ||
| 262 | + public Double getJhfyylc() { | ||
| 263 | + return jhfyylc; | ||
| 264 | + } | ||
| 265 | + | ||
| 266 | + public void setJhfyylc(Double jhfyylc) { | ||
| 267 | + this.jhfyylc = jhfyylc; | ||
| 268 | + } | ||
| 269 | + | ||
| 270 | + public int getJhzbc() { | ||
| 271 | + return jhzbc; | ||
| 272 | + } | ||
| 273 | + | ||
| 274 | + public void setJhzbc(int jhzbc) { | ||
| 275 | + this.jhzbc = jhzbc; | ||
| 276 | + } | ||
| 277 | + | ||
| 278 | + public int getJhbc() { | ||
| 279 | + return jhbc; | ||
| 280 | + } | ||
| 281 | + | ||
| 282 | + public void setJhbc(int jhbc) { | ||
| 283 | + this.jhbc = jhbc; | ||
| 284 | + } | ||
| 285 | + | ||
| 286 | + public int getSjzbc() { | ||
| 287 | + return sjzbc; | ||
| 288 | + } | ||
| 289 | + | ||
| 290 | + public void setSjzbc(int sjzbc) { | ||
| 291 | + this.sjzbc = sjzbc; | ||
| 292 | + } | ||
| 293 | + | ||
| 294 | + public int getSjbc() { | ||
| 295 | + return sjbc; | ||
| 296 | + } | ||
| 297 | + | ||
| 298 | + public void setSjbc(int sjbc) { | ||
| 299 | + this.sjbc = sjbc; | ||
| 300 | + } | ||
| 301 | + | ||
| 302 | + public String getEdituser() { | ||
| 303 | + return edituser; | ||
| 304 | + } | ||
| 305 | + | ||
| 306 | + public void setEdituser(String edituser) { | ||
| 307 | + this.edituser = edituser; | ||
| 308 | + } | ||
| 309 | + | ||
| 310 | + public Date getEdittime() { | ||
| 311 | + return edittime; | ||
| 312 | + } | ||
| 313 | + | ||
| 314 | + public void setEdittime(Date edittime) { | ||
| 315 | + this.edittime = edittime; | ||
| 316 | + } | ||
| 317 | + | ||
| 318 | + public Date getCreatetime() { | ||
| 319 | + return createtime; | ||
| 320 | + } | ||
| 321 | + | ||
| 322 | + public void setCreatetime(Date createtime) { | ||
| 323 | + this.createtime = createtime; | ||
| 324 | + } | ||
| 325 | + | ||
| 326 | + public int getNylx() { | ||
| 327 | + return nylx; | ||
| 328 | + } | ||
| 329 | + | ||
| 330 | + public void setNylx(int nylx) { | ||
| 331 | + this.nylx = nylx; | ||
| 332 | + } | ||
| 333 | + | ||
| 334 | + public int getJcsx() { | ||
| 335 | + return jcsx; | ||
| 336 | + } | ||
| 337 | + | ||
| 338 | + public void setJcsx(int jcsx) { | ||
| 339 | + this.jcsx = jcsx; | ||
| 340 | + } | ||
| 341 | + | ||
| 342 | + public String getBglyh() { | ||
| 343 | + if(this.getZlc()==0){ | ||
| 344 | + return "0"; | ||
| 345 | + }else{ | ||
| 346 | + DecimalFormat df = new DecimalFormat("0.000"); | ||
| 347 | + return df.format(this.getHd()/this.getZlc()*100); | ||
| 348 | + } | ||
| 349 | + } | ||
| 350 | + | ||
| 351 | + public void setBglyh(String bglyh) { | ||
| 352 | + this.bglyh = bglyh; | ||
| 353 | + } | ||
| 354 | + | ||
| 355 | + public String getXlname() { | ||
| 356 | + return BasicData.lineCodeAllNameMap.get(this.xlbm); | ||
| 357 | + } | ||
| 358 | + | ||
| 359 | + public void setXlname(String xlname) { | ||
| 360 | + this.xlname = xlname; | ||
| 361 | + } | ||
| 362 | + | ||
| 363 | + public String getGsname() { | ||
| 364 | + return BasicData.businessCodeNameMap.get(this.ssgsdm); | ||
| 365 | + } | ||
| 366 | + | ||
| 367 | + public void setGsname(String gsname) { | ||
| 368 | + this.gsname = gsname; | ||
| 369 | + } | ||
| 370 | + | ||
| 371 | + public String getName() { | ||
| 372 | + return BasicData.allPerson.get(this.ssgsdm+"-"+this.jsy); | ||
| 373 | + } | ||
| 374 | + | ||
| 375 | + public void setName(String name) { | ||
| 376 | + this.name = name; | ||
| 377 | + } | ||
| 378 | + | ||
| 379 | + public String getFgsname() { | ||
| 380 | + return BasicData.businessFgsCodeNameMap.get(this.fgsdm+"_"+this.ssgsdm); | ||
| 381 | + } | ||
| 382 | + | ||
| 383 | + public void setFgsname(String fgsname) { | ||
| 384 | + this.fgsname = fgsname; | ||
| 385 | + } | ||
| 386 | + | ||
| 387 | + public Date getUpdatetime() { | ||
| 388 | + return updatetime; | ||
| 389 | + } | ||
| 390 | + | ||
| 391 | + public void setUpdatetime(Date updatetime) { | ||
| 392 | + this.updatetime = updatetime; | ||
| 393 | + } | ||
| 394 | + | ||
| 395 | + public String getLp() { | ||
| 396 | + return lp; | ||
| 397 | + } | ||
| 398 | + | ||
| 399 | + public void setLp(String lp) { | ||
| 400 | + this.lp = lp; | ||
| 401 | + } | ||
| 402 | + | ||
| 403 | + public String getJname() { | ||
| 404 | + return jname; | ||
| 405 | + } | ||
| 406 | + | ||
| 407 | + public void setJname(String jname) { | ||
| 408 | + this.jname = jname; | ||
| 409 | + } | ||
| 410 | + | ||
| 411 | + | ||
| 412 | + | ||
| 413 | +} |
src/main/java/com/bsth/entity/oil/JdlConnector.java
0 → 100644
| 1 | +package com.bsth.entity.oil; | ||
| 2 | + | ||
| 3 | +import java.util.Date; | ||
| 4 | + | ||
| 5 | +import javax.persistence.Entity; | ||
| 6 | +import javax.persistence.GeneratedValue; | ||
| 7 | +import javax.persistence.GenerationType; | ||
| 8 | +import javax.persistence.Id; | ||
| 9 | +import javax.persistence.Table; | ||
| 10 | + | ||
| 11 | +import org.springframework.format.annotation.DateTimeFormat; | ||
| 12 | + | ||
| 13 | +/** | ||
| 14 | +-------------------------------------------------------- | ||
| 15 | + `id` bigint NOT NULL AUTO_INCREMENT COMMENT 'ID', | ||
| 16 | + `connector_name` varchar(255) COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '充电枪名称', | ||
| 17 | + `connector_id` varchar(255) COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '充电枪自编号', | ||
| 18 | + `station_name` varchar(255) COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '充电站名称', | ||
| 19 | + `remark` varchar(255) COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '备注', | ||
| 20 | + `create_by` varchar(255) COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '创建人', | ||
| 21 | + `create_date` datetime DEFAULT NULL COMMENT '创建时间', | ||
| 22 | + `update_by` varchar(255) COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '修改人', | ||
| 23 | + `update_date` datetime DEFAULT NULL ON UPDATE CURRENT_TIMESTAMP COMMENT '修改时间', | ||
| 24 | +*/ | ||
| 25 | +@Entity | ||
| 26 | +@Table(name = "bsth_c_jdl_connector") | ||
| 27 | +public class JdlConnector { | ||
| 28 | + @Id | ||
| 29 | + @GeneratedValue(strategy = GenerationType.IDENTITY) | ||
| 30 | + private Integer id; | ||
| 31 | + private String connectorName; | ||
| 32 | + private String connectorId; | ||
| 33 | + private String stationName; | ||
| 34 | + private String remark; | ||
| 35 | + private String createBy; | ||
| 36 | + @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") | ||
| 37 | + private Date createDate; | ||
| 38 | + private String updateBy; | ||
| 39 | + @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") | ||
| 40 | + private Date updateDate; | ||
| 41 | + | ||
| 42 | + | ||
| 43 | + public Integer getId() { | ||
| 44 | + return id; | ||
| 45 | + } | ||
| 46 | + public void setId(Integer id) { | ||
| 47 | + this.id = id; | ||
| 48 | + } | ||
| 49 | + public String getConnectorName() { | ||
| 50 | + return connectorName; | ||
| 51 | + } | ||
| 52 | + public void setConnectorName(String connectorName) { | ||
| 53 | + this.connectorName = connectorName; | ||
| 54 | + } | ||
| 55 | + public String getConnectorId() { | ||
| 56 | + return connectorId; | ||
| 57 | + } | ||
| 58 | + public void setConnectorId(String connectorId) { | ||
| 59 | + this.connectorId = connectorId; | ||
| 60 | + } | ||
| 61 | + public String getStationName() { | ||
| 62 | + return stationName; | ||
| 63 | + } | ||
| 64 | + public void setStationName(String stationName) { | ||
| 65 | + this.stationName = stationName; | ||
| 66 | + } | ||
| 67 | + public String getRemark() { | ||
| 68 | + return remark; | ||
| 69 | + } | ||
| 70 | + public void setRemark(String remark) { | ||
| 71 | + this.remark = remark; | ||
| 72 | + } | ||
| 73 | + public String getCreateBy() { | ||
| 74 | + return createBy; | ||
| 75 | + } | ||
| 76 | + public void setCreateBy(String createBy) { | ||
| 77 | + this.createBy = createBy; | ||
| 78 | + } | ||
| 79 | + public Date getCreateDate() { | ||
| 80 | + return createDate; | ||
| 81 | + } | ||
| 82 | + public void setCreateDate(Date createDate) { | ||
| 83 | + this.createDate = createDate; | ||
| 84 | + } | ||
| 85 | + public String getUpdateBy() { | ||
| 86 | + return updateBy; | ||
| 87 | + } | ||
| 88 | + public void setUpdateBy(String updateBy) { | ||
| 89 | + this.updateBy = updateBy; | ||
| 90 | + } | ||
| 91 | + public Date getUpdateDate() { | ||
| 92 | + return updateDate; | ||
| 93 | + } | ||
| 94 | + public void setUpdateDate(Date updateDate) { | ||
| 95 | + this.updateDate = updateDate; | ||
| 96 | + } | ||
| 97 | + | ||
| 98 | +} | ||
| 0 | \ No newline at end of file | 99 | \ No newline at end of file |
src/main/java/com/bsth/entity/oil/JdlReception.java
0 → 100644
| 1 | +package com.bsth.entity.oil; | ||
| 2 | + | ||
| 3 | +import java.util.Date; | ||
| 4 | + | ||
| 5 | +import javax.persistence.Entity; | ||
| 6 | +import javax.persistence.GeneratedValue; | ||
| 7 | +import javax.persistence.GenerationType; | ||
| 8 | +import javax.persistence.Id; | ||
| 9 | +import javax.persistence.Table; | ||
| 10 | + | ||
| 11 | +import org.springframework.format.annotation.DateTimeFormat; | ||
| 12 | + | ||
| 13 | +/** | ||
| 14 | +-------------------------------------------------------- | ||
| 15 | + `id` bigint(20) NOT NULL AUTO_INCREMENT COMMENT 'ID', | ||
| 16 | + `station_name` varchar(255) DEFAULT NULL COMMENT '站点名称', | ||
| 17 | + `connector_id` varchar(255) DEFAULT NULL COMMENT '枪编号', | ||
| 18 | + `connector_name` varchar(255) DEFAULT NULL COMMENT '充电枪名', | ||
| 19 | + `order_no` varchar(255) DEFAULT NULL COMMENT '订单编号', | ||
| 20 | + `start_time` varchar(255) DEFAULT NULL COMMENT '充电开始时间', | ||
| 21 | + `end_time` varchar(255) DEFAULT NULL COMMENT '充电结束时间', | ||
| 22 | + `start_soc` double(11,2) DEFAULT NULL COMMENT '开始 SOC(%)', | ||
| 23 | + `end_soc` double(11,2) DEFAULT NULL COMMENT '结束 SOC(%)', | ||
| 24 | + `stop_reason` varchar(255) DEFAULT NULL COMMENT '终止原因', | ||
| 25 | + `charge_capacity` double(11,3) DEFAULT NULL COMMENT '充电量,单位:度', | ||
| 26 | + `electric_charge` double(11,2) DEFAULT NULL COMMENT '电费,单位:元', | ||
| 27 | + `service_charge` double(11,2) DEFAULT NULL COMMENT '服务费,单位:元', | ||
| 28 | + `total_amount` double(11,2) DEFAULT NULL COMMENT '总费用,单位:元', | ||
| 29 | + `vin_code` varchar(255) DEFAULT NULL COMMENT '卡号', | ||
| 30 | + `card_no` varchar(255) DEFAULT NULL COMMENT 'VIN,车架号', | ||
| 31 | + `car_code` varchar(255) DEFAULT NULL COMMENT '车牌号', | ||
| 32 | + `date_str` varchar(255) DEFAULT NULL COMMENT '营运日期', | ||
| 33 | + `origin` int(2) NOT NULL DEFAULT '0' COMMENT '数据源(0:接口获取;1:导入)', | ||
| 34 | + `sum_time` bigint(11) DEFAULT NULL COMMENT '总计充电时间(分钟)', | ||
| 35 | + `pile_id` varchar(255) DEFAULT NULL COMMENT '桩号', | ||
| 36 | + `create_by` varchar(255) DEFAULT NULL COMMENT '创建人', | ||
| 37 | + `create_date` datetime DEFAULT NULL COMMENT '创建时间', | ||
| 38 | + `update_by` varchar(255) DEFAULT NULL COMMENT '修改人', | ||
| 39 | + `update_date` datetime DEFAULT NULL ON UPDATE CURRENT_TIMESTAMP COMMENT '修改时间', | ||
| 40 | +*/ | ||
| 41 | +@Entity | ||
| 42 | +@Table(name = "bsth_c_jdl_reception") | ||
| 43 | +public class JdlReception { | ||
| 44 | + @Id | ||
| 45 | + @GeneratedValue(strategy = GenerationType.IDENTITY) | ||
| 46 | + private Long id; | ||
| 47 | + private String stationName; | ||
| 48 | + private String connectorId; | ||
| 49 | + private String connectorName; | ||
| 50 | + private String orderNo; | ||
| 51 | + private String startTime; | ||
| 52 | + private String endTime; | ||
| 53 | + private Double startSoc; | ||
| 54 | + private Double endSoc; | ||
| 55 | + private String stopReason; | ||
| 56 | + private Double chargeCapacity; | ||
| 57 | + private Double electricCharge; | ||
| 58 | + private Double serviceCharge; | ||
| 59 | + private Double totalAmount; | ||
| 60 | + private String vinCode; | ||
| 61 | + private String cardNo; | ||
| 62 | + private String carCode; | ||
| 63 | + private String dateStr; | ||
| 64 | + private Integer origin; | ||
| 65 | + private Integer sumTime; | ||
| 66 | + private String batchNo; | ||
| 67 | + private String pileId; | ||
| 68 | + private String remark; | ||
| 69 | + private String createBy; | ||
| 70 | + @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") | ||
| 71 | + private Date createDate; | ||
| 72 | + private String updateBy; | ||
| 73 | + @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss") | ||
| 74 | + private Date updateDate; | ||
| 75 | + | ||
| 76 | + | ||
| 77 | + public Long getId() { | ||
| 78 | + return id; | ||
| 79 | + } | ||
| 80 | + public void setId(Long id) { | ||
| 81 | + this.id = id; | ||
| 82 | + } | ||
| 83 | + public String getStationName() { | ||
| 84 | + return stationName; | ||
| 85 | + } | ||
| 86 | + public void setStationName(String stationName) { | ||
| 87 | + this.stationName = stationName; | ||
| 88 | + } | ||
| 89 | + public String getConnectorId() { | ||
| 90 | + return connectorId; | ||
| 91 | + } | ||
| 92 | + public void setConnectorId(String connectorId) { | ||
| 93 | + this.connectorId = connectorId; | ||
| 94 | + } | ||
| 95 | + public String getConnectorName() { | ||
| 96 | + return connectorName; | ||
| 97 | + } | ||
| 98 | + public void setConnectorName(String connectorName) { | ||
| 99 | + this.connectorName = connectorName; | ||
| 100 | + } | ||
| 101 | + public String getOrderNo() { | ||
| 102 | + return orderNo; | ||
| 103 | + } | ||
| 104 | + public void setOrderNo(String orderNo) { | ||
| 105 | + this.orderNo = orderNo; | ||
| 106 | + } | ||
| 107 | + public String getStartTime() { | ||
| 108 | + return startTime; | ||
| 109 | + } | ||
| 110 | + public void setStartTime(String startTime) { | ||
| 111 | + this.startTime = startTime; | ||
| 112 | + } | ||
| 113 | + public String getEndTime() { | ||
| 114 | + return endTime; | ||
| 115 | + } | ||
| 116 | + public void setEndTime(String endTime) { | ||
| 117 | + this.endTime = endTime; | ||
| 118 | + } | ||
| 119 | + public Double getStartSoc() { | ||
| 120 | + return startSoc; | ||
| 121 | + } | ||
| 122 | + public void setStartSoc(Double startSoc) { | ||
| 123 | + this.startSoc = startSoc; | ||
| 124 | + } | ||
| 125 | + public Double getEndSoc() { | ||
| 126 | + return endSoc; | ||
| 127 | + } | ||
| 128 | + public void setEndSoc(Double endSoc) { | ||
| 129 | + this.endSoc = endSoc; | ||
| 130 | + } | ||
| 131 | + public String getStopReason() { | ||
| 132 | + return stopReason; | ||
| 133 | + } | ||
| 134 | + public void setStopReason(String stopReason) { | ||
| 135 | + this.stopReason = stopReason; | ||
| 136 | + } | ||
| 137 | + public Double getChargeCapacity() { | ||
| 138 | + return chargeCapacity; | ||
| 139 | + } | ||
| 140 | + public void setChargeCapacity(Double chargeCapacity) { | ||
| 141 | + this.chargeCapacity = chargeCapacity; | ||
| 142 | + } | ||
| 143 | + public Double getElectricCharge() { | ||
| 144 | + return electricCharge; | ||
| 145 | + } | ||
| 146 | + public void setElectricCharge(Double electricCharge) { | ||
| 147 | + this.electricCharge = electricCharge; | ||
| 148 | + } | ||
| 149 | + public Double getServiceCharge() { | ||
| 150 | + return serviceCharge; | ||
| 151 | + } | ||
| 152 | + public void setServiceCharge(Double serviceCharge) { | ||
| 153 | + this.serviceCharge = serviceCharge; | ||
| 154 | + } | ||
| 155 | + public Double getTotalAmount() { | ||
| 156 | + return totalAmount; | ||
| 157 | + } | ||
| 158 | + public void setTotalAmount(Double totalAmount) { | ||
| 159 | + this.totalAmount = totalAmount; | ||
| 160 | + } | ||
| 161 | + public String getVinCode() { | ||
| 162 | + return vinCode; | ||
| 163 | + } | ||
| 164 | + public void setVinCode(String vinCode) { | ||
| 165 | + this.vinCode = vinCode; | ||
| 166 | + } | ||
| 167 | + public String getCardNo() { | ||
| 168 | + return cardNo; | ||
| 169 | + } | ||
| 170 | + public void setCardNo(String cardNo) { | ||
| 171 | + this.cardNo = cardNo; | ||
| 172 | + } | ||
| 173 | + public String getCarCode() { | ||
| 174 | + return carCode; | ||
| 175 | + } | ||
| 176 | + public void setCarCode(String carCode) { | ||
| 177 | + this.carCode = carCode; | ||
| 178 | + } | ||
| 179 | + public String getDateStr() { | ||
| 180 | + return dateStr; | ||
| 181 | + } | ||
| 182 | + public void setDateStr(String dateStr) { | ||
| 183 | + this.dateStr = dateStr; | ||
| 184 | + } | ||
| 185 | + public Integer getOrigin() { | ||
| 186 | + return origin; | ||
| 187 | + } | ||
| 188 | + public void setOrigin(Integer origin) { | ||
| 189 | + this.origin = origin; | ||
| 190 | + } | ||
| 191 | + public Integer getSumTime() { | ||
| 192 | + return sumTime; | ||
| 193 | + } | ||
| 194 | + public void setSumTime(Integer sumTime) { | ||
| 195 | + this.sumTime = sumTime; | ||
| 196 | + } | ||
| 197 | + public String getBatchNo() { | ||
| 198 | + return batchNo; | ||
| 199 | + } | ||
| 200 | + public void setBatchNo(String batchNo) { | ||
| 201 | + this.batchNo = batchNo; | ||
| 202 | + } | ||
| 203 | + public String getPileId() { | ||
| 204 | + return pileId; | ||
| 205 | + } | ||
| 206 | + public void setPileId(String pileId) { | ||
| 207 | + this.pileId = pileId; | ||
| 208 | + } | ||
| 209 | + public String getRemark() { | ||
| 210 | + return remark; | ||
| 211 | + } | ||
| 212 | + public void setRemark(String remark) { | ||
| 213 | + this.remark = remark; | ||
| 214 | + } | ||
| 215 | + public String getCreateBy() { | ||
| 216 | + return createBy; | ||
| 217 | + } | ||
| 218 | + public void setCreateBy(String createBy) { | ||
| 219 | + this.createBy = createBy; | ||
| 220 | + } | ||
| 221 | + public Date getCreateDate() { | ||
| 222 | + return createDate; | ||
| 223 | + } | ||
| 224 | + public void setCreateDate(Date createDate) { | ||
| 225 | + this.createDate = createDate; | ||
| 226 | + } | ||
| 227 | + public String getUpdateBy() { | ||
| 228 | + return updateBy; | ||
| 229 | + } | ||
| 230 | + public void setUpdateBy(String updateBy) { | ||
| 231 | + this.updateBy = updateBy; | ||
| 232 | + } | ||
| 233 | + public Date getUpdateDate() { | ||
| 234 | + return updateDate; | ||
| 235 | + } | ||
| 236 | + public void setUpdateDate(Date updateDate) { | ||
| 237 | + this.updateDate = updateDate; | ||
| 238 | + } | ||
| 239 | + | ||
| 240 | +} | ||
| 0 | \ No newline at end of file | 241 | \ No newline at end of file |
src/main/java/com/bsth/entity/oil/Qlb.java
| @@ -348,7 +348,7 @@ public class Qlb { | @@ -348,7 +348,7 @@ public class Qlb { | ||
| 348 | if(this.getZlc()==0){ | 348 | if(this.getZlc()==0){ |
| 349 | return "0"; | 349 | return "0"; |
| 350 | }else{ | 350 | }else{ |
| 351 | - DecimalFormat df = new DecimalFormat("0.00"); | 351 | + DecimalFormat df = new DecimalFormat("0.000"); |
| 352 | return df.format(this.getHn()/this.getZlc()*100); | 352 | return df.format(this.getHn()/this.getZlc()*100); |
| 353 | } | 353 | } |
| 354 | } | 354 | } |
src/main/java/com/bsth/entity/oil/Ylb.java
| 1 | -package com.bsth.entity.oil; | ||
| 2 | - | ||
| 3 | -import java.text.DecimalFormat; | ||
| 4 | -import java.util.Date; | ||
| 5 | - | ||
| 6 | -import javax.persistence.*; | ||
| 7 | - | ||
| 8 | -import org.springframework.format.annotation.DateTimeFormat; | ||
| 9 | - | ||
| 10 | -import com.bsth.data.BasicData; | ||
| 11 | - | ||
| 12 | -@Entity | ||
| 13 | -@Table(name = "bsth_c_ylb") | ||
| 14 | -public class Ylb { | ||
| 15 | - @Id | ||
| 16 | - @GeneratedValue(strategy = GenerationType.IDENTITY) | ||
| 17 | - private Integer id; | ||
| 18 | - @DateTimeFormat(pattern="yyyy-MM-dd") | ||
| 19 | - private Date rq; | ||
| 20 | - private String xlbm; | ||
| 21 | - private String linename; | ||
| 22 | - private String ssgsdm; | ||
| 23 | - private String fgsdm; | ||
| 24 | - private String nbbm; | ||
| 25 | - private String jsy; | ||
| 26 | - private String jname; | ||
| 27 | - private Double czlc=0.0; | ||
| 28 | - private Double jzlc=0.0; | ||
| 29 | - private Double czyl=0.0; | ||
| 30 | - private Double jzyl=0.0; | ||
| 31 | - private Double jzl=0.0; | ||
| 32 | - private int sfkt; | ||
| 33 | - private String jhsj; | ||
| 34 | - private Double yh=0.0; | ||
| 35 | - private Double sh=0.0; | ||
| 36 | - private String shyy; | ||
| 37 | - private Double zlc=0.0; | ||
| 38 | - private int yhlx; | ||
| 39 | - private String rylx="0"; | ||
| 40 | - private Double ns=0.0; | ||
| 41 | - private Double fyylc=0.0; | ||
| 42 | - private Double jhzlc=0.0; | ||
| 43 | - private Double jhfyylc=0.0; | ||
| 44 | - private int jhzbc; | ||
| 45 | - private int jhbc; | ||
| 46 | - private int sjzbc; | ||
| 47 | - private int sjbc; | ||
| 48 | - private String edituser; | ||
| 49 | - private Date edittime; | ||
| 50 | - private Date updatetime; | ||
| 51 | - private Date createtime; | ||
| 52 | - | ||
| 53 | - private int nylx; | ||
| 54 | - //进场顺序(根据最先出场和最后进场来关联车辆的存油量) | ||
| 55 | - private int jcsx; | ||
| 56 | - | ||
| 57 | - private String lp; | ||
| 58 | - @Transient | ||
| 59 | - private String bglyh; | ||
| 60 | - | ||
| 61 | - @Transient | ||
| 62 | - private String xlname; | ||
| 63 | - | ||
| 64 | - @Transient | ||
| 65 | - private String gsname; | ||
| 66 | - | ||
| 67 | - @Transient | ||
| 68 | - private String fgsname; | ||
| 69 | - | ||
| 70 | - @Transient | ||
| 71 | - private String name; | ||
| 72 | - | ||
| 73 | - public Integer getId() { | ||
| 74 | - return id; | ||
| 75 | - } | ||
| 76 | - | ||
| 77 | - public void setId(Integer id) { | ||
| 78 | - this.id = id; | ||
| 79 | - } | ||
| 80 | - public Date getRq() { | ||
| 81 | - return rq; | ||
| 82 | - } | ||
| 83 | - | ||
| 84 | - public void setRq(Date rq) { | ||
| 85 | - this.rq = rq; | ||
| 86 | - } | ||
| 87 | - | ||
| 88 | - public String getXlbm() { | ||
| 89 | - return xlbm; | ||
| 90 | - } | ||
| 91 | - | ||
| 92 | - public void setXlbm(String xlbm) { | ||
| 93 | - this.xlbm = xlbm; | ||
| 94 | - } | ||
| 95 | - | ||
| 96 | - public String getLinename() { | ||
| 97 | - return linename; | ||
| 98 | - } | ||
| 99 | - | ||
| 100 | - public void setLinename(String linename) { | ||
| 101 | - this.linename = linename; | ||
| 102 | - } | ||
| 103 | - | ||
| 104 | - public String getSsgsdm() { | ||
| 105 | - return ssgsdm; | ||
| 106 | - } | ||
| 107 | - public void setSsgsdm(String ssgsdm) { | ||
| 108 | - this.ssgsdm = ssgsdm; | ||
| 109 | - } | ||
| 110 | - public String getFgsdm() { | ||
| 111 | - return fgsdm; | ||
| 112 | - } | ||
| 113 | - public void setFgsdm(String fgsdm) { | ||
| 114 | - this.fgsdm = fgsdm; | ||
| 115 | - } | ||
| 116 | - public String getNbbm() { | ||
| 117 | - return nbbm; | ||
| 118 | - } | ||
| 119 | - public void setNbbm(String nbbm) { | ||
| 120 | - this.nbbm = nbbm; | ||
| 121 | - } | ||
| 122 | - public String getJsy() { | ||
| 123 | - return jsy; | ||
| 124 | - } | ||
| 125 | - public void setJsy(String jsy) { | ||
| 126 | - this.jsy = jsy; | ||
| 127 | - } | ||
| 128 | - public Double getCzlc() { | ||
| 129 | - return czlc; | ||
| 130 | - } | ||
| 131 | - public void setCzlc(Double czlc) { | ||
| 132 | - this.czlc = czlc; | ||
| 133 | - } | ||
| 134 | - public Double getJzlc() { | ||
| 135 | - return jzlc; | ||
| 136 | - } | ||
| 137 | - public void setJzlc(Double jzlc) { | ||
| 138 | - this.jzlc = jzlc; | ||
| 139 | - } | ||
| 140 | - public Double getCzyl() { | ||
| 141 | - return czyl; | ||
| 142 | - } | ||
| 143 | - public void setCzyl(Double czyl) { | ||
| 144 | - this.czyl = czyl; | ||
| 145 | - } | ||
| 146 | - public Double getJzyl() { | ||
| 147 | - return jzyl; | ||
| 148 | - } | ||
| 149 | - public void setJzyl(Double jzyl) { | ||
| 150 | - this.jzyl = jzyl; | ||
| 151 | - } | ||
| 152 | - public Double getJzl() { | ||
| 153 | - return jzl; | ||
| 154 | - } | ||
| 155 | - public void setJzl(Double jzl) { | ||
| 156 | - this.jzl = jzl; | ||
| 157 | - } | ||
| 158 | - public int getSfkt() { | ||
| 159 | - return sfkt; | ||
| 160 | - } | ||
| 161 | - public void setSfkt(int sfkt) { | ||
| 162 | - this.sfkt = sfkt; | ||
| 163 | - } | ||
| 164 | - public String getJhsj() { | ||
| 165 | - return jhsj; | ||
| 166 | - } | ||
| 167 | - public void setJhsj(String jhsj) { | ||
| 168 | - this.jhsj = jhsj; | ||
| 169 | - } | ||
| 170 | - public Double getYh() { | ||
| 171 | - return yh; | ||
| 172 | - } | ||
| 173 | - public void setYh(Double yh) { | ||
| 174 | - this.yh = yh; | ||
| 175 | - } | ||
| 176 | - public Double getSh() { | ||
| 177 | - return sh; | ||
| 178 | - } | ||
| 179 | - public void setSh(Double sh) { | ||
| 180 | - this.sh = sh; | ||
| 181 | - } | ||
| 182 | - public String getShyy() { | ||
| 183 | - return shyy; | ||
| 184 | - } | ||
| 185 | - public void setShyy(String shyy) { | ||
| 186 | - this.shyy = shyy; | ||
| 187 | - } | ||
| 188 | - public Double getZlc() { | ||
| 189 | - return zlc; | ||
| 190 | - } | ||
| 191 | - public void setZlc(Double zlc) { | ||
| 192 | - this.zlc = zlc; | ||
| 193 | - } | ||
| 194 | - public int getYhlx() { | ||
| 195 | - return yhlx; | ||
| 196 | - } | ||
| 197 | - public void setYhlx(int yhlx) { | ||
| 198 | - this.yhlx = yhlx; | ||
| 199 | - } | ||
| 200 | - public String getRylx() { | ||
| 201 | - return rylx; | ||
| 202 | - } | ||
| 203 | - public void setRylx(String rylx) { | ||
| 204 | - this.rylx = rylx; | ||
| 205 | - } | ||
| 206 | - public Double getNs() { | ||
| 207 | - return ns; | ||
| 208 | - } | ||
| 209 | - public void setNs(Double ns) { | ||
| 210 | - this.ns = ns; | ||
| 211 | - } | ||
| 212 | - public Double getFyylc() { | ||
| 213 | - return fyylc; | ||
| 214 | - } | ||
| 215 | - public void setFyylc(Double fyylc) { | ||
| 216 | - this.fyylc = fyylc; | ||
| 217 | - } | ||
| 218 | - public Double getJhzlc() { | ||
| 219 | - return jhzlc; | ||
| 220 | - } | ||
| 221 | - public void setJhzlc(Double jhzlc) { | ||
| 222 | - this.jhzlc = jhzlc; | ||
| 223 | - } | ||
| 224 | - public Double getJhfyylc() { | ||
| 225 | - return jhfyylc; | ||
| 226 | - } | ||
| 227 | - public void setJhfyylc(Double jhfyylc) { | ||
| 228 | - this.jhfyylc = jhfyylc; | ||
| 229 | - } | ||
| 230 | - public int getJhzbc() { | ||
| 231 | - return jhzbc; | ||
| 232 | - } | ||
| 233 | - public void setJhzbc(int jhzbc) { | ||
| 234 | - this.jhzbc = jhzbc; | ||
| 235 | - } | ||
| 236 | - public int getJhbc() { | ||
| 237 | - return jhbc; | ||
| 238 | - } | ||
| 239 | - public void setJhbc(int jhbc) { | ||
| 240 | - this.jhbc = jhbc; | ||
| 241 | - } | ||
| 242 | - public int getSjzbc() { | ||
| 243 | - return sjzbc; | ||
| 244 | - } | ||
| 245 | - public void setSjzbc(int sjzbc) { | ||
| 246 | - this.sjzbc = sjzbc; | ||
| 247 | - } | ||
| 248 | - public int getSjbc() { | ||
| 249 | - return sjbc; | ||
| 250 | - } | ||
| 251 | - public void setSjbc(int sjbc) { | ||
| 252 | - this.sjbc = sjbc; | ||
| 253 | - } | ||
| 254 | - public String getEdituser() { | ||
| 255 | - return edituser; | ||
| 256 | - } | ||
| 257 | - public void setEdituser(String edituser) { | ||
| 258 | - this.edituser = edituser; | ||
| 259 | - } | ||
| 260 | - public Date getEdittime() { | ||
| 261 | - return edittime; | ||
| 262 | - } | ||
| 263 | - public void setEdittime(Date edittime) { | ||
| 264 | - this.edittime = edittime; | ||
| 265 | - } | ||
| 266 | - public Date getCreatetime() { | ||
| 267 | - return createtime; | ||
| 268 | - } | ||
| 269 | - public void setCreatetime(Date createtime) { | ||
| 270 | - this.createtime = createtime; | ||
| 271 | - } | ||
| 272 | - public int getNylx() { | ||
| 273 | - return nylx; | ||
| 274 | - } | ||
| 275 | - public void setNylx(int nylx) { | ||
| 276 | - this.nylx = nylx; | ||
| 277 | - } | ||
| 278 | - | ||
| 279 | - public int getJcsx(){ | ||
| 280 | - return jcsx; | ||
| 281 | - } | ||
| 282 | - | ||
| 283 | - public void setJcsx(int jcsx){ | ||
| 284 | - this.jcsx=jcsx; | ||
| 285 | - } | ||
| 286 | - | ||
| 287 | - public String getBglyh() { | ||
| 288 | - if(this.getZlc()==0){ | ||
| 289 | - return "0"; | ||
| 290 | - }else{ | ||
| 291 | - DecimalFormat df = new DecimalFormat("0.00"); | ||
| 292 | - return df.format(this.getYh()/this.getZlc()*100); | ||
| 293 | - } | ||
| 294 | - } | ||
| 295 | - | ||
| 296 | - public void setBglyh(String bglyh) { | ||
| 297 | - this.bglyh = bglyh; | ||
| 298 | - } | ||
| 299 | - | ||
| 300 | - public String getXlname() { | ||
| 301 | - return BasicData.lineCodeAllNameMap.get(this.xlbm); | ||
| 302 | - } | ||
| 303 | - | ||
| 304 | - public void setXlname(String xlname) { | ||
| 305 | - this.xlname = xlname; | ||
| 306 | - } | ||
| 307 | - | ||
| 308 | - public String getGsname() { | ||
| 309 | - return BasicData.businessCodeNameMap.get(this.ssgsdm); | ||
| 310 | - } | ||
| 311 | - | ||
| 312 | - public void setGsname(String gsname) { | ||
| 313 | - this.gsname = gsname; | ||
| 314 | - } | ||
| 315 | - | ||
| 316 | - | ||
| 317 | - public String getFgsname() { | ||
| 318 | - return BasicData.businessFgsCodeNameMap.get(this.fgsdm+"_"+this.ssgsdm); | ||
| 319 | - } | ||
| 320 | - | ||
| 321 | - public void setFgsname(String fgsname) { | ||
| 322 | - this.fgsname = fgsname; | ||
| 323 | - } | ||
| 324 | - | ||
| 325 | - public String getName() { | ||
| 326 | - return BasicData.allPerson.get(this.ssgsdm+"-"+this.jsy); | ||
| 327 | - } | ||
| 328 | - | ||
| 329 | - public void setName(String name) { | ||
| 330 | - this.name = name; | ||
| 331 | - } | ||
| 332 | - | ||
| 333 | - | ||
| 334 | - public Date getUpdatetime() { | ||
| 335 | - return updatetime; | ||
| 336 | - } | ||
| 337 | - | ||
| 338 | - public void setUpdatetime(Date updatetime) { | ||
| 339 | - this.updatetime = updatetime; | ||
| 340 | - } | ||
| 341 | - | ||
| 342 | - public String getLp() { | ||
| 343 | - return lp; | ||
| 344 | - } | ||
| 345 | - | ||
| 346 | - public void setLp(String lp) { | ||
| 347 | - this.lp = lp; | ||
| 348 | - } | ||
| 349 | - | ||
| 350 | - public String getJname() { | ||
| 351 | - return jname; | ||
| 352 | - } | ||
| 353 | - | ||
| 354 | - public void setJname(String jname) { | ||
| 355 | - this.jname = jname; | ||
| 356 | - } | ||
| 357 | - | ||
| 358 | - | ||
| 359 | -} | 1 | +package com.bsth.entity.oil; |
| 2 | + | ||
| 3 | +import java.text.DecimalFormat; | ||
| 4 | +import java.util.Date; | ||
| 5 | + | ||
| 6 | +import javax.persistence.*; | ||
| 7 | + | ||
| 8 | +import org.springframework.format.annotation.DateTimeFormat; | ||
| 9 | + | ||
| 10 | +import com.bsth.data.BasicData; | ||
| 11 | + | ||
| 12 | +@Entity | ||
| 13 | +@Table(name = "bsth_c_ylb") | ||
| 14 | +public class Ylb { | ||
| 15 | + @Id | ||
| 16 | + @GeneratedValue(strategy = GenerationType.IDENTITY) | ||
| 17 | + private Integer id; | ||
| 18 | + @DateTimeFormat(pattern="yyyy-MM-dd") | ||
| 19 | + private Date rq; | ||
| 20 | + private String xlbm; | ||
| 21 | + private String linename; | ||
| 22 | + private String ssgsdm; | ||
| 23 | + private String fgsdm; | ||
| 24 | + private String nbbm; | ||
| 25 | + private String jsy; | ||
| 26 | + private String jname; | ||
| 27 | + private Double czlc=0.0; | ||
| 28 | + private Double jzlc=0.0; | ||
| 29 | + private Double czyl=0.0; | ||
| 30 | + private Double jzyl=0.0; | ||
| 31 | + private Double jzl=0.0; | ||
| 32 | + private int sfkt; | ||
| 33 | + private String jhsj; | ||
| 34 | + private Double yh=0.0; | ||
| 35 | + private Double sh=0.0; | ||
| 36 | + private String shyy; | ||
| 37 | + private Double zlc=0.0; | ||
| 38 | + private int yhlx; | ||
| 39 | + private String rylx="0"; | ||
| 40 | + private Double ns=0.0; | ||
| 41 | + private Double fyylc=0.0; | ||
| 42 | + private Double jhzlc=0.0; | ||
| 43 | + private Double jhfyylc=0.0; | ||
| 44 | + private int jhzbc; | ||
| 45 | + private int jhbc; | ||
| 46 | + private int sjzbc; | ||
| 47 | + private int sjbc; | ||
| 48 | + private String edituser; | ||
| 49 | + private Date edittime; | ||
| 50 | + private Date updatetime; | ||
| 51 | + private Date createtime; | ||
| 52 | + | ||
| 53 | + private int nylx; | ||
| 54 | + //进场顺序(根据最先出场和最后进场来关联车辆的存油量) | ||
| 55 | + private int jcsx; | ||
| 56 | + | ||
| 57 | + private String lp; | ||
| 58 | + @Transient | ||
| 59 | + private String bglyh; | ||
| 60 | + | ||
| 61 | + @Transient | ||
| 62 | + private String xlname; | ||
| 63 | + | ||
| 64 | + @Transient | ||
| 65 | + private String gsname; | ||
| 66 | + | ||
| 67 | + @Transient | ||
| 68 | + private String fgsname; | ||
| 69 | + | ||
| 70 | + @Transient | ||
| 71 | + private String name; | ||
| 72 | + | ||
| 73 | + public Integer getId() { | ||
| 74 | + return id; | ||
| 75 | + } | ||
| 76 | + | ||
| 77 | + public void setId(Integer id) { | ||
| 78 | + this.id = id; | ||
| 79 | + } | ||
| 80 | + public Date getRq() { | ||
| 81 | + return rq; | ||
| 82 | + } | ||
| 83 | + | ||
| 84 | + public void setRq(Date rq) { | ||
| 85 | + this.rq = rq; | ||
| 86 | + } | ||
| 87 | + | ||
| 88 | + public String getXlbm() { | ||
| 89 | + return xlbm; | ||
| 90 | + } | ||
| 91 | + | ||
| 92 | + public void setXlbm(String xlbm) { | ||
| 93 | + this.xlbm = xlbm; | ||
| 94 | + } | ||
| 95 | + | ||
| 96 | + public String getLinename() { | ||
| 97 | + return linename; | ||
| 98 | + } | ||
| 99 | + | ||
| 100 | + public void setLinename(String linename) { | ||
| 101 | + this.linename = linename; | ||
| 102 | + } | ||
| 103 | + | ||
| 104 | + public String getSsgsdm() { | ||
| 105 | + return ssgsdm; | ||
| 106 | + } | ||
| 107 | + public void setSsgsdm(String ssgsdm) { | ||
| 108 | + this.ssgsdm = ssgsdm; | ||
| 109 | + } | ||
| 110 | + public String getFgsdm() { | ||
| 111 | + return fgsdm; | ||
| 112 | + } | ||
| 113 | + public void setFgsdm(String fgsdm) { | ||
| 114 | + this.fgsdm = fgsdm; | ||
| 115 | + } | ||
| 116 | + public String getNbbm() { | ||
| 117 | + return nbbm; | ||
| 118 | + } | ||
| 119 | + public void setNbbm(String nbbm) { | ||
| 120 | + this.nbbm = nbbm; | ||
| 121 | + } | ||
| 122 | + public String getJsy() { | ||
| 123 | + return jsy; | ||
| 124 | + } | ||
| 125 | + public void setJsy(String jsy) { | ||
| 126 | + this.jsy = jsy; | ||
| 127 | + } | ||
| 128 | + public Double getCzlc() { | ||
| 129 | + return czlc; | ||
| 130 | + } | ||
| 131 | + public void setCzlc(Double czlc) { | ||
| 132 | + this.czlc = czlc; | ||
| 133 | + } | ||
| 134 | + public Double getJzlc() { | ||
| 135 | + return jzlc; | ||
| 136 | + } | ||
| 137 | + public void setJzlc(Double jzlc) { | ||
| 138 | + this.jzlc = jzlc; | ||
| 139 | + } | ||
| 140 | + public Double getCzyl() { | ||
| 141 | + return czyl; | ||
| 142 | + } | ||
| 143 | + public void setCzyl(Double czyl) { | ||
| 144 | + this.czyl = czyl; | ||
| 145 | + } | ||
| 146 | + public Double getJzyl() { | ||
| 147 | + return jzyl; | ||
| 148 | + } | ||
| 149 | + public void setJzyl(Double jzyl) { | ||
| 150 | + this.jzyl = jzyl; | ||
| 151 | + } | ||
| 152 | + public Double getJzl() { | ||
| 153 | + return jzl; | ||
| 154 | + } | ||
| 155 | + public void setJzl(Double jzl) { | ||
| 156 | + this.jzl = jzl; | ||
| 157 | + } | ||
| 158 | + public int getSfkt() { | ||
| 159 | + return sfkt; | ||
| 160 | + } | ||
| 161 | + public void setSfkt(int sfkt) { | ||
| 162 | + this.sfkt = sfkt; | ||
| 163 | + } | ||
| 164 | + public String getJhsj() { | ||
| 165 | + return jhsj; | ||
| 166 | + } | ||
| 167 | + public void setJhsj(String jhsj) { | ||
| 168 | + this.jhsj = jhsj; | ||
| 169 | + } | ||
| 170 | + public Double getYh() { | ||
| 171 | + return yh; | ||
| 172 | + } | ||
| 173 | + public void setYh(Double yh) { | ||
| 174 | + this.yh = yh; | ||
| 175 | + } | ||
| 176 | + public Double getSh() { | ||
| 177 | + return sh; | ||
| 178 | + } | ||
| 179 | + public void setSh(Double sh) { | ||
| 180 | + this.sh = sh; | ||
| 181 | + } | ||
| 182 | + public String getShyy() { | ||
| 183 | + return shyy; | ||
| 184 | + } | ||
| 185 | + public void setShyy(String shyy) { | ||
| 186 | + this.shyy = shyy; | ||
| 187 | + } | ||
| 188 | + public Double getZlc() { | ||
| 189 | + return zlc; | ||
| 190 | + } | ||
| 191 | + public void setZlc(Double zlc) { | ||
| 192 | + this.zlc = zlc; | ||
| 193 | + } | ||
| 194 | + public int getYhlx() { | ||
| 195 | + return yhlx; | ||
| 196 | + } | ||
| 197 | + public void setYhlx(int yhlx) { | ||
| 198 | + this.yhlx = yhlx; | ||
| 199 | + } | ||
| 200 | + public String getRylx() { | ||
| 201 | + return rylx; | ||
| 202 | + } | ||
| 203 | + public void setRylx(String rylx) { | ||
| 204 | + this.rylx = rylx; | ||
| 205 | + } | ||
| 206 | + public Double getNs() { | ||
| 207 | + return ns; | ||
| 208 | + } | ||
| 209 | + public void setNs(Double ns) { | ||
| 210 | + this.ns = ns; | ||
| 211 | + } | ||
| 212 | + public Double getFyylc() { | ||
| 213 | + return fyylc; | ||
| 214 | + } | ||
| 215 | + public void setFyylc(Double fyylc) { | ||
| 216 | + this.fyylc = fyylc; | ||
| 217 | + } | ||
| 218 | + public Double getJhzlc() { | ||
| 219 | + return jhzlc; | ||
| 220 | + } | ||
| 221 | + public void setJhzlc(Double jhzlc) { | ||
| 222 | + this.jhzlc = jhzlc; | ||
| 223 | + } | ||
| 224 | + public Double getJhfyylc() { | ||
| 225 | + return jhfyylc; | ||
| 226 | + } | ||
| 227 | + public void setJhfyylc(Double jhfyylc) { | ||
| 228 | + this.jhfyylc = jhfyylc; | ||
| 229 | + } | ||
| 230 | + public int getJhzbc() { | ||
| 231 | + return jhzbc; | ||
| 232 | + } | ||
| 233 | + public void setJhzbc(int jhzbc) { | ||
| 234 | + this.jhzbc = jhzbc; | ||
| 235 | + } | ||
| 236 | + public int getJhbc() { | ||
| 237 | + return jhbc; | ||
| 238 | + } | ||
| 239 | + public void setJhbc(int jhbc) { | ||
| 240 | + this.jhbc = jhbc; | ||
| 241 | + } | ||
| 242 | + public int getSjzbc() { | ||
| 243 | + return sjzbc; | ||
| 244 | + } | ||
| 245 | + public void setSjzbc(int sjzbc) { | ||
| 246 | + this.sjzbc = sjzbc; | ||
| 247 | + } | ||
| 248 | + public int getSjbc() { | ||
| 249 | + return sjbc; | ||
| 250 | + } | ||
| 251 | + public void setSjbc(int sjbc) { | ||
| 252 | + this.sjbc = sjbc; | ||
| 253 | + } | ||
| 254 | + public String getEdituser() { | ||
| 255 | + return edituser; | ||
| 256 | + } | ||
| 257 | + public void setEdituser(String edituser) { | ||
| 258 | + this.edituser = edituser; | ||
| 259 | + } | ||
| 260 | + public Date getEdittime() { | ||
| 261 | + return edittime; | ||
| 262 | + } | ||
| 263 | + public void setEdittime(Date edittime) { | ||
| 264 | + this.edittime = edittime; | ||
| 265 | + } | ||
| 266 | + public Date getCreatetime() { | ||
| 267 | + return createtime; | ||
| 268 | + } | ||
| 269 | + public void setCreatetime(Date createtime) { | ||
| 270 | + this.createtime = createtime; | ||
| 271 | + } | ||
| 272 | + public int getNylx() { | ||
| 273 | + return nylx; | ||
| 274 | + } | ||
| 275 | + public void setNylx(int nylx) { | ||
| 276 | + this.nylx = nylx; | ||
| 277 | + } | ||
| 278 | + | ||
| 279 | + public int getJcsx(){ | ||
| 280 | + return jcsx; | ||
| 281 | + } | ||
| 282 | + | ||
| 283 | + public void setJcsx(int jcsx){ | ||
| 284 | + this.jcsx=jcsx; | ||
| 285 | + } | ||
| 286 | + | ||
| 287 | + public String getBglyh() { | ||
| 288 | + if(this.getZlc()==0){ | ||
| 289 | + return "0"; | ||
| 290 | + }else{ | ||
| 291 | + DecimalFormat df = new DecimalFormat("0.000"); | ||
| 292 | + return df.format(this.getYh()/this.getZlc()*100); | ||
| 293 | + } | ||
| 294 | + } | ||
| 295 | + | ||
| 296 | + public void setBglyh(String bglyh) { | ||
| 297 | + this.bglyh = bglyh; | ||
| 298 | + } | ||
| 299 | + | ||
| 300 | + public String getXlname() { | ||
| 301 | + return BasicData.lineCodeAllNameMap.get(this.xlbm); | ||
| 302 | + } | ||
| 303 | + | ||
| 304 | + public void setXlname(String xlname) { | ||
| 305 | + this.xlname = xlname; | ||
| 306 | + } | ||
| 307 | + | ||
| 308 | + public String getGsname() { | ||
| 309 | + return BasicData.businessCodeNameMap.get(this.ssgsdm); | ||
| 310 | + } | ||
| 311 | + | ||
| 312 | + public void setGsname(String gsname) { | ||
| 313 | + this.gsname = gsname; | ||
| 314 | + } | ||
| 315 | + | ||
| 316 | + | ||
| 317 | + public String getFgsname() { | ||
| 318 | + return BasicData.businessFgsCodeNameMap.get(this.fgsdm+"_"+this.ssgsdm); | ||
| 319 | + } | ||
| 320 | + | ||
| 321 | + public void setFgsname(String fgsname) { | ||
| 322 | + this.fgsname = fgsname; | ||
| 323 | + } | ||
| 324 | + | ||
| 325 | + public String getName() { | ||
| 326 | + return BasicData.allPerson.get(this.ssgsdm+"-"+this.jsy); | ||
| 327 | + } | ||
| 328 | + | ||
| 329 | + public void setName(String name) { | ||
| 330 | + this.name = name; | ||
| 331 | + } | ||
| 332 | + | ||
| 333 | + | ||
| 334 | + public Date getUpdatetime() { | ||
| 335 | + return updatetime; | ||
| 336 | + } | ||
| 337 | + | ||
| 338 | + public void setUpdatetime(Date updatetime) { | ||
| 339 | + this.updatetime = updatetime; | ||
| 340 | + } | ||
| 341 | + | ||
| 342 | + public String getLp() { | ||
| 343 | + return lp; | ||
| 344 | + } | ||
| 345 | + | ||
| 346 | + public void setLp(String lp) { | ||
| 347 | + this.lp = lp; | ||
| 348 | + } | ||
| 349 | + | ||
| 350 | + public String getJname() { | ||
| 351 | + return jname; | ||
| 352 | + } | ||
| 353 | + | ||
| 354 | + public void setJname(String jname) { | ||
| 355 | + this.jname = jname; | ||
| 356 | + } | ||
| 357 | + | ||
| 358 | + | ||
| 359 | +} |
src/main/java/com/bsth/entity/realcontrol/ScheduleRealInfo.java
| @@ -21,7 +21,7 @@ import java.util.Set; | @@ -21,7 +21,7 @@ import java.util.Set; | ||
| 21 | @NamedAttributeNode("cTasks") | 21 | @NamedAttributeNode("cTasks") |
| 22 | }) | 22 | }) |
| 23 | }) | 23 | }) |
| 24 | -public class ScheduleRealInfo { | 24 | +public class ScheduleRealInfo implements Cloneable{ |
| 25 | /** 主键Id */ | 25 | /** 主键Id */ |
| 26 | @Id | 26 | @Id |
| 27 | private Long id; | 27 | private Long id; |
| @@ -1054,4 +1054,10 @@ public class ScheduleRealInfo { | @@ -1054,4 +1054,10 @@ public class ScheduleRealInfo { | ||
| 1054 | public void setOperationType(String operationType) { | 1054 | public void setOperationType(String operationType) { |
| 1055 | this.operationType = operationType; | 1055 | this.operationType = operationType; |
| 1056 | } | 1056 | } |
| 1057 | + | ||
| 1058 | + @Override | ||
| 1059 | + public ScheduleRealInfo clone() throws CloneNotSupportedException { | ||
| 1060 | + ScheduleRealInfo cloned = (ScheduleRealInfo) super.clone(); | ||
| 1061 | + return cloned; | ||
| 1062 | + } | ||
| 1057 | } | 1063 | } |
src/main/java/com/bsth/entity/zndd/StationPeopleLogger.java
| @@ -7,7 +7,7 @@ import javax.persistence.*; | @@ -7,7 +7,7 @@ import javax.persistence.*; | ||
| 7 | import java.io.Serializable; | 7 | import java.io.Serializable; |
| 8 | 8 | ||
| 9 | @Entity | 9 | @Entity |
| 10 | -@Table(name = "bsth_c_t_station_people_logger") //智能调度记录查询表 | 10 | +@Table(name = "bsth_c_t_station_people_logger") //智能调度记录检测表 |
| 11 | @JsonIgnoreProperties(value={"hibernateLazyInitializer","handler","fieldHandler"}) | 11 | @JsonIgnoreProperties(value={"hibernateLazyInitializer","handler","fieldHandler"}) |
| 12 | public class StationPeopleLogger implements Serializable { | 12 | public class StationPeopleLogger implements Serializable { |
| 13 | // ID | 13 | // ID |
| @@ -19,8 +19,10 @@ public class StationPeopleLogger implements Serializable { | @@ -19,8 +19,10 @@ public class StationPeopleLogger implements Serializable { | ||
| 19 | //线路名称 | 19 | //线路名称 |
| 20 | private String lineName; | 20 | private String lineName; |
| 21 | //站点code | 21 | //站点code |
| 22 | + @Transient | ||
| 22 | private String station; | 23 | private String station; |
| 23 | //站点名称 | 24 | //站点名称 |
| 25 | + @Transient | ||
| 24 | private String stationName; | 26 | private String stationName; |
| 25 | //日期 | 27 | //日期 |
| 26 | private String rqStr; | 28 | private String rqStr; |
| @@ -31,8 +33,19 @@ public class StationPeopleLogger implements Serializable { | @@ -31,8 +33,19 @@ public class StationPeopleLogger implements Serializable { | ||
| 31 | //上下行 | 33 | //上下行 |
| 32 | private String xlDir; | 34 | private String xlDir; |
| 33 | //人数 or 差距时间 or 站点差数 根据类型判断 | 35 | //人数 or 差距时间 or 站点差数 根据类型判断 |
| 34 | - private Long numType; | ||
| 35 | - | 36 | + private String fcsj; |
| 37 | + | ||
| 38 | + private String clZbh; | ||
| 39 | + | ||
| 40 | + | ||
| 41 | + | ||
| 42 | + public String getClZbh() { | ||
| 43 | + return clZbh; | ||
| 44 | + } | ||
| 45 | + | ||
| 46 | + public void setClZbh(String clZbh) { | ||
| 47 | + this.clZbh = clZbh; | ||
| 48 | + } | ||
| 36 | 49 | ||
| 37 | public void setId(Long id) { | 50 | public void setId(Long id) { |
| 38 | this.id = id; | 51 | this.id = id; |
| @@ -90,8 +103,12 @@ public class StationPeopleLogger implements Serializable { | @@ -90,8 +103,12 @@ public class StationPeopleLogger implements Serializable { | ||
| 90 | this.rq = rq; | 103 | this.rq = rq; |
| 91 | } | 104 | } |
| 92 | 105 | ||
| 93 | - public Long getNumType() { | ||
| 94 | - return numType; | 106 | + public String getFcsj() { |
| 107 | + return fcsj; | ||
| 108 | + } | ||
| 109 | + | ||
| 110 | + public void setFcsj(String fcsj) { | ||
| 111 | + this.fcsj = fcsj; | ||
| 95 | } | 112 | } |
| 96 | 113 | ||
| 97 | public String getStation() { | 114 | public String getStation() { |
| @@ -110,8 +127,5 @@ public class StationPeopleLogger implements Serializable { | @@ -110,8 +127,5 @@ public class StationPeopleLogger implements Serializable { | ||
| 110 | this.stationName = stationName; | 127 | this.stationName = stationName; |
| 111 | } | 128 | } |
| 112 | 129 | ||
| 113 | - public void setNumType(Long numType) { | ||
| 114 | - this.numType = numType; | ||
| 115 | - } | ||
| 116 | 130 | ||
| 117 | } | 131 | } |
src/main/java/com/bsth/entity/zndd/znddStatus.java
| @@ -23,6 +23,25 @@ public class znddStatus { | @@ -23,6 +23,25 @@ public class znddStatus { | ||
| 23 | 23 | ||
| 24 | private String name; | 24 | private String name; |
| 25 | 25 | ||
| 26 | + //大客流是否自动执行班次 0开 1关 null关 | ||
| 27 | + private String excuteStatus; | ||
| 28 | + | ||
| 29 | + public String getExcuteStatus() { | ||
| 30 | + return excuteStatus; | ||
| 31 | + } | ||
| 32 | + | ||
| 33 | + public void setExcuteStatus(String excuteStatus) { | ||
| 34 | + this.excuteStatus = excuteStatus; | ||
| 35 | + } | ||
| 36 | + | ||
| 37 | + | ||
| 38 | + public Long getId() { | ||
| 39 | + return id; | ||
| 40 | + } | ||
| 41 | + | ||
| 42 | + public void setId(Long id) { | ||
| 43 | + this.id = id; | ||
| 44 | + } | ||
| 26 | 45 | ||
| 27 | public String getType() { | 46 | public String getType() { |
| 28 | return type; | 47 | return type; |
src/main/java/com/bsth/repository/DKLInfoRepository.java
0 → 100644
src/main/java/com/bsth/repository/lg_travel/RegionLineCarRepository.java
0 → 100644
| 1 | +package com.bsth.repository.lg_travel; | ||
| 2 | + | ||
| 3 | + | ||
| 4 | +import com.bsth.entity.lg_travel.RegionLineCar; | ||
| 5 | +import com.bsth.repository.BaseRepository; | ||
| 6 | +import org.springframework.stereotype.Repository; | ||
| 7 | + | ||
| 8 | +@Repository | ||
| 9 | +public interface RegionLineCarRepository extends BaseRepository<RegionLineCar, Long> { | ||
| 10 | +} |
src/main/java/com/bsth/repository/lg_travel/RegionRepository.java
0 → 100644
src/main/java/com/bsth/repository/oil/JdlConnectorRepository.java
0 → 100644
| 1 | +package com.bsth.repository.oil; | ||
| 2 | + | ||
| 3 | +import java.util.List; | ||
| 4 | + | ||
| 5 | +import org.springframework.data.jpa.repository.Modifying; | ||
| 6 | +import org.springframework.data.jpa.repository.Query; | ||
| 7 | +import org.springframework.stereotype.Repository; | ||
| 8 | +import org.springframework.transaction.annotation.Transactional; | ||
| 9 | + | ||
| 10 | +import com.bsth.entity.oil.JdlConnector; | ||
| 11 | +import com.bsth.repository.BaseRepository; | ||
| 12 | + | ||
| 13 | +@Repository | ||
| 14 | +public interface JdlConnectorRepository extends BaseRepository<JdlConnector, Integer>{ | ||
| 15 | + | ||
| 16 | + @Query(value="SELECT j FROM JdlConnector j WHERE connectorName like %?1% and connectorId like %?2% and stationName like %?3% order by stationName, connectorId ") | ||
| 17 | + List<JdlConnector> query(String connectorName, String connectorId, String stationName); | ||
| 18 | + | ||
| 19 | + @Query(value="SELECT j FROM JdlConnector j WHERE connectorName = ?1 ") | ||
| 20 | + List<JdlConnector> queryByGunName(String connectorName); | ||
| 21 | + | ||
| 22 | + @Query(value="SELECT j FROM JdlConnector j WHERE id = ?1 ") | ||
| 23 | + JdlConnector queryById(Integer id); | ||
| 24 | + | ||
| 25 | + @Query(value="SELECT j.stationName FROM JdlConnector j group by stationName ") | ||
| 26 | + List<String> queryStationName(); | ||
| 27 | + | ||
| 28 | + @Modifying | ||
| 29 | + @Transactional | ||
| 30 | + @Query(value = "delete JdlConnector j where id = ?1 ") | ||
| 31 | + void delete(Integer id); | ||
| 32 | + | ||
| 33 | + @Transactional | ||
| 34 | + @Modifying | ||
| 35 | + @Query(value="UPDATE bsth_c_jdl_connector SET " + | ||
| 36 | + " connector_name = ?2," + | ||
| 37 | + " connector_id = ?3," + | ||
| 38 | + " station_name = ?4" + | ||
| 39 | + " WHERE id = ?1 ", nativeQuery=true) | ||
| 40 | + public void update(Integer id, String connectorName, String connectorId, String stationName); | ||
| 41 | + | ||
| 42 | +} |
src/main/java/com/bsth/repository/oil/JdlReceptionRepository.java
0 → 100644
| 1 | +package com.bsth.repository.oil; | ||
| 2 | + | ||
| 3 | +import java.util.List; | ||
| 4 | + | ||
| 5 | +import org.springframework.data.jpa.repository.Modifying; | ||
| 6 | +import org.springframework.data.jpa.repository.Query; | ||
| 7 | +import org.springframework.stereotype.Repository; | ||
| 8 | +import org.springframework.transaction.annotation.Transactional; | ||
| 9 | + | ||
| 10 | +import com.bsth.entity.oil.JdlReception; | ||
| 11 | +import com.bsth.repository.BaseRepository; | ||
| 12 | + | ||
| 13 | +@Repository | ||
| 14 | +public interface JdlReceptionRepository extends BaseRepository<JdlReception, Integer>{ | ||
| 15 | + | ||
| 16 | + @Query(value="SELECT date_str, car_code, sum(CAST(charge_capacity AS DECIMAL(10, 3))) charge_capacity FROM bsth_c_jdl_reception where date_str = ?1 and car_code like %?2% group by date_str, car_code order by date_str" ,nativeQuery=true) | ||
| 17 | + List<Object[]> querySum(String rq, String nbbm); | ||
| 18 | + | ||
| 19 | + @Query(value="SELECT * FROM bsth_c_jdl_reception where date_str = ?1 and car_code like %?2% " ,nativeQuery=true) | ||
| 20 | + List<JdlReception> query(String rq, String nbbm); | ||
| 21 | + | ||
| 22 | + @Query(value="SELECT batch_no, create_by, DATE_FORMAT(create_date, '%Y-%m-%d %H:%i:%s') create_date FROM bsth_c_jdl_reception where DATE_FORMAT(create_date, '%Y-%m-%d') = ?1 and origin = 1 group by batch_no, create_by, create_date order by batch_no" ,nativeQuery=true) | ||
| 23 | + List<Object[]> queryBatch(String rq); | ||
| 24 | + | ||
| 25 | + @Query(value="SELECT batch_no, create_by, DATE_FORMAT(create_date, '%Y-%m-%d %H:%i:%s') create_date FROM bsth_c_jdl_reception where DATE_FORMAT(create_date, '%Y-%m-%d') >= ?1 and DATE_FORMAT(create_date, '%Y-%m-%d') <= ?2 and create_by like %?3% and origin = 1 group by batch_no, create_by, create_date order by create_date, create_by, batch_no" ,nativeQuery=true) | ||
| 26 | + List<Object[]> queryBatchByDates(String rq1, String rq2, String createBy); | ||
| 27 | + | ||
| 28 | + @Query(value="SELECT * FROM bsth_c_jdl_reception where create_by = ?1 and DATE_FORMAT(create_date, '%Y-%m-%d %H:%i:%s') = ?2 and origin = 1 " ,nativeQuery=true) | ||
| 29 | + List<JdlReception> queryBatchData(String createBy, String createDate); | ||
| 30 | + | ||
| 31 | + @Query(value="SELECT j FROM JdlReception j WHERE id = ?1 ") | ||
| 32 | + List<JdlReception> queryById(Long id); | ||
| 33 | + | ||
| 34 | + @Query(value="SELECT j FROM JdlReception j WHERE endTime >= ?1 and startTime <= ?2 and carCode = ?3 ") | ||
| 35 | + List<JdlReception> queryRepeatCar(String startTime, String endTime, String nbbm); | ||
| 36 | + | ||
| 37 | + @Query(value="SELECT j FROM JdlReception j WHERE endTime >= ?1 and startTime <= ?2 and connectorId = ?3 and carCode != ?4 ") | ||
| 38 | + List<JdlReception> queryRepeatConnector(String startTime, String endTime, String connectorId, String nbbm); | ||
| 39 | + | ||
| 40 | + @Modifying | ||
| 41 | + @Transactional | ||
| 42 | + @Query(value = "delete JdlReception j where createBy = ?1 and DATE_FORMAT(createDate, '%Y-%m-%d %H:%i:%s') = ?2 and origin = 1") | ||
| 43 | + void deleteBatch(String createBy, String createDate); | ||
| 44 | + | ||
| 45 | + @Transactional | ||
| 46 | + @Modifying | ||
| 47 | + @Query(value="UPDATE bsth_c_jdl_reception SET " + | ||
| 48 | + " date_str = ?2," + | ||
| 49 | + " pile_id = ?3," + | ||
| 50 | + " car_code = ?4," + | ||
| 51 | + " start_time = ?5," + | ||
| 52 | + " end_time = ?6," + | ||
| 53 | + " sum_time = ?7," + | ||
| 54 | + " start_soc = ?8," + | ||
| 55 | + " end_soc = ?9," + | ||
| 56 | + " charge_capacity = ?10," + | ||
| 57 | + " stop_reason = ?11" + | ||
| 58 | + " WHERE id = ?1", nativeQuery=true) | ||
| 59 | + public void update(Long id, String dateStr, String pileId, String carCode, String startTime, String endTime, Integer sumTime, Double startSoc, Double endSoc, Double chargeCapacity, String stopReason); | ||
| 60 | + | ||
| 61 | +} |
src/main/java/com/bsth/repository/oil/NylogRepository.java
| 1 | package com.bsth.repository.oil; | 1 | package com.bsth.repository.oil; |
| 2 | 2 | ||
| 3 | +import java.util.List; | ||
| 3 | 4 | ||
| 4 | - | 5 | +import org.springframework.data.jpa.repository.Query; |
| 5 | import org.springframework.stereotype.Repository; | 6 | import org.springframework.stereotype.Repository; |
| 7 | + | ||
| 6 | import com.bsth.entity.oil.Nylog; | 8 | import com.bsth.entity.oil.Nylog; |
| 7 | import com.bsth.repository.BaseRepository; | 9 | import com.bsth.repository.BaseRepository; |
| 8 | 10 | ||
| 9 | @Repository | 11 | @Repository |
| 10 | public interface NylogRepository extends BaseRepository<Nylog, Integer>{ | 12 | public interface NylogRepository extends BaseRepository<Nylog, Integer>{ |
| 13 | + | ||
| 14 | + @Query(value="select n from Nylog n where nylx = ?1 and czmc = ?2 and cxtj = ?3 order by createdate desc ") | ||
| 15 | + List<Nylog> selectByCxtj(String nylx, String czmc, String cxtj); | ||
| 16 | + | ||
| 11 | } | 17 | } |
src/main/java/com/bsth/repository/zndd/ZnddLoggerRepository.java
0 → 100644
src/main/java/com/bsth/repository/zndd/ZnddStatusRepository.java
| @@ -2,10 +2,20 @@ package com.bsth.repository.zndd; | @@ -2,10 +2,20 @@ package com.bsth.repository.zndd; | ||
| 2 | 2 | ||
| 3 | import com.bsth.entity.zndd.znddStatus; | 3 | import com.bsth.entity.zndd.znddStatus; |
| 4 | import com.bsth.repository.BaseRepository; | 4 | import com.bsth.repository.BaseRepository; |
| 5 | +import org.springframework.data.jpa.repository.Modifying; | ||
| 6 | +import org.springframework.data.jpa.repository.Query; | ||
| 5 | import org.springframework.stereotype.Repository; | 7 | import org.springframework.stereotype.Repository; |
| 8 | +import org.springframework.transaction.annotation.Transactional; | ||
| 6 | 9 | ||
| 7 | 10 | ||
| 8 | @Repository | 11 | @Repository |
| 9 | public interface ZnddStatusRepository extends BaseRepository<znddStatus, Integer> { | 12 | public interface ZnddStatusRepository extends BaseRepository<znddStatus, Integer> { |
| 13 | + | ||
| 14 | + | ||
| 15 | + @Transactional | ||
| 16 | + @Modifying | ||
| 17 | + @Query(value="UPDATE zndd_status SET " + | ||
| 18 | + "open_status = ?2 WHERE id = ?1", nativeQuery=true) | ||
| 19 | + void update(Integer id, Integer openStatus); | ||
| 10 | 20 | ||
| 11 | } | 21 | } |
src/main/java/com/bsth/service/DKLInfoService.java
0 → 100644
src/main/java/com/bsth/service/calc/impl/CalcWaybillServiceImpl.java
| @@ -2395,7 +2395,7 @@ public class CalcWaybillServiceImpl extends BaseServiceImpl<CalcWaybill, Integer | @@ -2395,7 +2395,7 @@ public class CalcWaybillServiceImpl extends BaseServiceImpl<CalcWaybill, Integer | ||
| 2395 | } | 2395 | } |
| 2396 | 2396 | ||
| 2397 | int i=1; | 2397 | int i=1; |
| 2398 | - DecimalFormat df = new DecimalFormat("0.00");//格式化小数 | 2398 | + DecimalFormat df = new DecimalFormat("0.000");//格式化小数 |
| 2399 | double allNum = 0.0; | 2399 | double allNum = 0.0; |
| 2400 | while (iter.hasNext()) { | 2400 | while (iter.hasNext()) { |
| 2401 | Map.Entry entry = (Map.Entry) iter.next(); | 2401 | Map.Entry entry = (Map.Entry) iter.next(); |
| @@ -2433,7 +2433,6 @@ public class CalcWaybillServiceImpl extends BaseServiceImpl<CalcWaybill, Integer | @@ -2433,7 +2433,6 @@ public class CalcWaybillServiceImpl extends BaseServiceImpl<CalcWaybill, Integer | ||
| 2433 | listStr.add(c.getTs()+""); | 2433 | listStr.add(c.getTs()+""); |
| 2434 | // 把列合计的数添加到最后一个 | 2434 | // 把列合计的数添加到最后一个 |
| 2435 | cList.add(c); | 2435 | cList.add(c); |
| 2436 | - // DecimalFormat df = new DecimalFormat("0.00");//格式化小数 | ||
| 2437 | for (CalcWaybillDetail c1:cList) { | 2436 | for (CalcWaybillDetail c1:cList) { |
| 2438 | if(StringUtils.isEmpty(c1.getXl())) { | 2437 | if(StringUtils.isEmpty(c1.getXl())) { |
| 2439 | listStr.add(""); | 2438 | listStr.add(""); |
src/main/java/com/bsth/service/impl/DKLInfoServiceImpl.java
0 → 100644
src/main/java/com/bsth/service/impl/StationRouteServiceImpl.java
| @@ -710,6 +710,9 @@ public class StationRouteServiceImpl extends BaseServiceImpl<StationRoute, Integ | @@ -710,6 +710,9 @@ public class StationRouteServiceImpl extends BaseServiceImpl<StationRoute, Integ | ||
| 710 | String sleepStr = ""; | 710 | String sleepStr = ""; |
| 711 | // 方向 | 711 | // 方向 |
| 712 | int directions = objects.get(i)[8]==null ? null : Integer.valueOf(objects.get(i)[8].toString()); | 712 | int directions = objects.get(i)[8]==null ? null : Integer.valueOf(objects.get(i)[8].toString()); |
| 713 | + if (directions == 1) { | ||
| 714 | + stationName = stationName.replaceAll("\\(起点站\\)", "").replaceAll("\\(终点站\\)", "").replaceAll("(起点站)", "").replaceAll("(终点站)", ""); | ||
| 715 | + } | ||
| 713 | /** 获取路段路由信息 @pararm:<lineId:线路ID;directions:方向> */ | 716 | /** 获取路段路由信息 @pararm:<lineId:线路ID;directions:方向> */ |
| 714 | List<Object[]> sobje = sectionRouteRepository.sectionRouteVector(lineId,directions); | 717 | List<Object[]> sobje = sectionRouteRepository.sectionRouteVector(lineId,directions); |
| 715 | if(sobje.size()==1) { | 718 | if(sobje.size()==1) { |
| @@ -799,6 +802,9 @@ public class StationRouteServiceImpl extends BaseServiceImpl<StationRoute, Integ | @@ -799,6 +802,9 @@ public class StationRouteServiceImpl extends BaseServiceImpl<StationRoute, Integ | ||
| 799 | String sleepStr = ""; | 802 | String sleepStr = ""; |
| 800 | // 方向 | 803 | // 方向 |
| 801 | int directions = objects.get(i)[8]==null ? null : Integer.valueOf(objects.get(i)[8].toString()); | 804 | int directions = objects.get(i)[8]==null ? null : Integer.valueOf(objects.get(i)[8].toString()); |
| 805 | + if (directions == 1) { | ||
| 806 | + stationName = stationName.replaceAll("\\(起点站\\)", "").replaceAll("\\(终点站\\)", "").replaceAll("(起点站)", "").replaceAll("(终点站)", ""); | ||
| 807 | + } | ||
| 802 | /** 获取路段路由信息 @pararm:<lineId:线路ID;directions:方向> */ | 808 | /** 获取路段路由信息 @pararm:<lineId:线路ID;directions:方向> */ |
| 803 | List<Object[]> sobje = sectionRouteRepository.sectionRouteVector(lineId,directions); | 809 | List<Object[]> sobje = sectionRouteRepository.sectionRouteVector(lineId,directions); |
| 804 | if(sobje.size()==1) { | 810 | if(sobje.size()==1) { |
src/main/java/com/bsth/service/lg_travel/RegionLineCarService.java
0 → 100644
src/main/java/com/bsth/service/lg_travel/RegionService.java
0 → 100644
src/main/java/com/bsth/service/lg_travel/impl/RegionLineCarServiceImpl.java
0 → 100644
| 1 | +package com.bsth.service.lg_travel.impl; | ||
| 2 | + | ||
| 3 | + | ||
| 4 | +import com.bsth.entity.lg_travel.RegionLineCar; | ||
| 5 | +import com.bsth.service.impl.BaseServiceImpl; | ||
| 6 | +import com.bsth.service.lg_travel.RegionLineCarService; | ||
| 7 | +import org.springframework.stereotype.Service; | ||
| 8 | + | ||
| 9 | +@Service | ||
| 10 | +public class RegionLineCarServiceImpl extends BaseServiceImpl<RegionLineCar, Long> implements RegionLineCarService { | ||
| 11 | + | ||
| 12 | + | ||
| 13 | + | ||
| 14 | +} |
src/main/java/com/bsth/service/lg_travel/impl/RegionServiceImpl.java
0 → 100644
| 1 | +package com.bsth.service.lg_travel.impl; | ||
| 2 | + | ||
| 3 | + | ||
| 4 | +import com.bsth.entity.lg_travel.Region; | ||
| 5 | +import com.bsth.service.impl.BaseServiceImpl; | ||
| 6 | +import com.bsth.service.lg_travel.RegionService; | ||
| 7 | +import org.springframework.stereotype.Service; | ||
| 8 | + | ||
| 9 | +@Service | ||
| 10 | +public class RegionServiceImpl extends BaseServiceImpl<Region, Long> implements RegionService { | ||
| 11 | + | ||
| 12 | + | ||
| 13 | + | ||
| 14 | +} |
src/main/java/com/bsth/service/oil/JdlService.java
| 1 | package com.bsth.service.oil; | 1 | package com.bsth.service.oil; |
| 2 | 2 | ||
| 3 | import java.io.File; | 3 | import java.io.File; |
| 4 | +import java.io.IOException; | ||
| 5 | +import java.util.List; | ||
| 4 | import java.util.Map; | 6 | import java.util.Map; |
| 5 | 7 | ||
| 8 | +import javax.servlet.http.HttpServletResponse; | ||
| 9 | + | ||
| 6 | import com.bsth.entity.oil.Jdl; | 10 | import com.bsth.entity.oil.Jdl; |
| 11 | +import com.bsth.entity.oil.JdlConnector; | ||
| 12 | +import com.bsth.entity.oil.JdlReception; | ||
| 7 | import com.bsth.service.BaseService; | 13 | import com.bsth.service.BaseService; |
| 8 | 14 | ||
| 9 | public interface JdlService extends BaseService<Jdl, Integer> { | 15 | public interface JdlService extends BaseService<Jdl, Integer> { |
| 10 | 16 | ||
| 11 | public String importExcel(File file, String gsbm_, String gsName, String fgsbm, String fgsName); | 17 | public String importExcel(File file, String gsbm_, String gsName, String fgsbm, String fgsName); |
| 18 | + | ||
| 19 | + /** 24年12月工单更新电量导入 */ | ||
| 20 | + public String importExcel_2412(File file, String gsbm_, String gsName, String fgsbm, String fgsName, String stationName); | ||
| 12 | 21 | ||
| 13 | public Map<String, Object> query(Map<String, Object> map); | 22 | public Map<String, Object> query(Map<String, Object> map); |
| 23 | + | ||
| 24 | + public Map<String, Object> query_2412(Map<String, Object> map); | ||
| 25 | + | ||
| 26 | + public List<JdlReception> queryJdlReception(Map<String, Object> map); | ||
| 27 | + | ||
| 28 | + public Map<String, Object> queryJdlReceptionBatch(Map<String, Object> map); | ||
| 29 | + | ||
| 30 | + public List<JdlReception> queryJdlReceptionBatchData(Map<String, Object> map); | ||
| 31 | + | ||
| 32 | + public Map<String, Object> deleteJdlReceptionBatch(Map<String, Object> map); | ||
| 33 | + | ||
| 34 | + public Map<String, Object> updateJdlReceptionBatch(Map<String, Object> map); | ||
| 35 | + | ||
| 36 | + public void downloadJdlReceptionImportFile(Map<String, Object> map, HttpServletResponse response) throws IOException; | ||
| 37 | + | ||
| 38 | + /** | ||
| 39 | + * 查询车辆充电量,以jdl表格式返回 | ||
| 40 | + * @param rq 营运日期 | ||
| 41 | + * @param nbbm 车辆自编号(为‘’时查询全部车辆) | ||
| 42 | + * @return | ||
| 43 | + */ | ||
| 44 | + public List<Jdl> queryJdlByJdlReception(String rq, String nbbm); | ||
| 45 | + | ||
| 46 | + public List<JdlConnector> queryJdlConnector(Map<String, Object> map); | ||
| 47 | + | ||
| 48 | + public JdlConnector queryJdlConnectorById(Integer id); | ||
| 49 | + | ||
| 50 | + public List<String> queryJdlStationName(); | ||
| 51 | + | ||
| 52 | + public Map<String, Object> addJdlConnector(Map<String, Object> map); | ||
| 53 | + | ||
| 54 | + public Map<String, Object> deleteJdlConnector(Map<String, Object> map); | ||
| 55 | + | ||
| 56 | + public Map<String, Object> updateJdlConnector(Map<String, Object> map); | ||
| 14 | 57 | ||
| 15 | } | 58 | } |
src/main/java/com/bsth/service/oil/impl/DlbServiceImpl.java
| @@ -48,6 +48,7 @@ import com.bsth.repository.CarsRepository; | @@ -48,6 +48,7 @@ import com.bsth.repository.CarsRepository; | ||
| 48 | import com.bsth.repository.oil.CdlRepository; | 48 | import com.bsth.repository.oil.CdlRepository; |
| 49 | import com.bsth.repository.oil.CylRepository; | 49 | import com.bsth.repository.oil.CylRepository; |
| 50 | import com.bsth.repository.oil.DlbRepository; | 50 | import com.bsth.repository.oil.DlbRepository; |
| 51 | +import com.bsth.repository.oil.JdlReceptionRepository; | ||
| 51 | import com.bsth.repository.oil.JdlRepository; | 52 | import com.bsth.repository.oil.JdlRepository; |
| 52 | import com.bsth.repository.oil.NylogRepository; | 53 | import com.bsth.repository.oil.NylogRepository; |
| 53 | import com.bsth.repository.oil.YlbRepository; | 54 | import com.bsth.repository.oil.YlbRepository; |
| @@ -55,6 +56,7 @@ import com.bsth.repository.oil.YlxxbRepository; | @@ -55,6 +56,7 @@ import com.bsth.repository.oil.YlxxbRepository; | ||
| 55 | import com.bsth.security.util.SecurityUtils; | 56 | import com.bsth.security.util.SecurityUtils; |
| 56 | import com.bsth.service.impl.BaseServiceImpl; | 57 | import com.bsth.service.impl.BaseServiceImpl; |
| 57 | import com.bsth.service.oil.DlbService; | 58 | import com.bsth.service.oil.DlbService; |
| 59 | +import com.bsth.service.oil.JdlService; | ||
| 58 | import com.bsth.service.realcontrol.ScheduleRealInfoService; | 60 | import com.bsth.service.realcontrol.ScheduleRealInfoService; |
| 59 | import com.bsth.util.Arith; | 61 | import com.bsth.util.Arith; |
| 60 | import com.bsth.util.BatchSaveUtils; | 62 | import com.bsth.util.BatchSaveUtils; |
| @@ -77,6 +79,8 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | @@ -77,6 +79,8 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | ||
| 77 | 79 | ||
| 78 | @Autowired | 80 | @Autowired |
| 79 | ScheduleRealInfoService scheduleRealInfoService; | 81 | ScheduleRealInfoService scheduleRealInfoService; |
| 82 | + @Autowired | ||
| 83 | + JdlService jdlService; | ||
| 80 | 84 | ||
| 81 | @Autowired | 85 | @Autowired |
| 82 | JdbcTemplate jdbcTemplate; | 86 | JdbcTemplate jdbcTemplate; |
| @@ -91,7 +95,8 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | @@ -91,7 +95,8 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | ||
| 91 | Map<String, Boolean> carsMap=new HashMap<String, Boolean>(); | 95 | Map<String, Boolean> carsMap=new HashMap<String, Boolean>(); |
| 92 | for (int i = 0; i < carsList.size(); i++) { | 96 | for (int i = 0; i < carsList.size(); i++) { |
| 93 | Cars c=carsList.get(i); | 97 | Cars c=carsList.get(i); |
| 94 | - carsMap.put(c.getInsideCode(), c.getSfdc()); | 98 | + carsMap.put(c.getInsideCode(), (c.getSfdc()!=null?c.getSfdc():false) |
| 99 | + || (c.getSfmix()!=null?c.getSfmix():false));//电车或油电混合,都可以充电 | ||
| 95 | } | 100 | } |
| 96 | SimpleDateFormat sdf=new SimpleDateFormat("yyyy-MM-dd"); | 101 | SimpleDateFormat sdf=new SimpleDateFormat("yyyy-MM-dd"); |
| 97 | Date dNow = new Date(); //当前时间 | 102 | Date dNow = new Date(); //当前时间 |
| @@ -103,8 +108,8 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | @@ -103,8 +108,8 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | ||
| 103 | String rq=sdf.format(dBefore); | 108 | String rq=sdf.format(dBefore); |
| 104 | // String rq="2017-11-02"; | 109 | // String rq="2017-11-02"; |
| 105 | String line=""; | 110 | String line=""; |
| 106 | - //保留两位小数 | ||
| 107 | - DecimalFormat df = new DecimalFormat("#.00"); | 111 | + //公里保留三位小数 |
| 112 | + DecimalFormat df = new DecimalFormat("#.000"); | ||
| 108 | // TODO Auto-generated method stub | 113 | // TODO Auto-generated method stub |
| 109 | Map<String, Object> newMap=new HashMap<String,Object>(); | 114 | Map<String, Object> newMap=new HashMap<String,Object>(); |
| 110 | //当天DLB信息 | 115 | //当天DLB信息 |
| @@ -112,7 +117,9 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | @@ -112,7 +117,9 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | ||
| 112 | //当天YLXXB信息 | 117 | //当天YLXXB信息 |
| 113 | List<Ylxxb> ylxxList=ylxxbRepository.obtainYlxx(rq,1,""); | 118 | List<Ylxxb> ylxxList=ylxxbRepository.obtainYlxx(rq,1,""); |
| 114 | //当天加电信息表 | 119 | //当天加电信息表 |
| 115 | - List<Jdl> jdlList=jdlRepository.JdlList(rq); | 120 | + List<Jdl> jdlList = jdlRepository.JdlList(rq); |
| 121 | +// List<Jdl> jdlList = jdlService.queryJdlByJdlReception(rq, ""); | ||
| 122 | +// jdlList.addAll(jdlRepository.JdlList(rq)); | ||
| 116 | //前一天所有车辆最后进场班次信息 | 123 | //前一天所有车辆最后进场班次信息 |
| 117 | // List<Dlb> dlListBe=repository.obtainYlbefore(rq, "", "", "", ""); | 124 | // List<Dlb> dlListBe=repository.obtainYlbefore(rq, "", "", "", ""); |
| 118 | List<Cdl> cdyList=cdlRepository.obtainCdl(); | 125 | List<Cdl> cdyList=cdlRepository.obtainCdl(); |
| @@ -123,7 +130,7 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | @@ -123,7 +130,7 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | ||
| 123 | boolean sfdc=false; | 130 | boolean sfdc=false; |
| 124 | Map<String, Object> map=listpb.get(x); | 131 | Map<String, Object> map=listpb.get(x); |
| 125 | if (carsMap.get(map.get("clZbh").toString())!=null) { | 132 | if (carsMap.get(map.get("clZbh").toString())!=null) { |
| 126 | - sfdc= carsMap.get(map.get("clZbh").toString()); | 133 | + sfdc = carsMap.get(map.get("clZbh").toString()); |
| 127 | }else{ | 134 | }else{ |
| 128 | sfdc=false; | 135 | sfdc=false; |
| 129 | } | 136 | } |
| @@ -237,7 +244,8 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | @@ -237,7 +244,8 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | ||
| 237 | Map<String, Boolean> carsMap = new HashMap<String, Boolean>(); | 244 | Map<String, Boolean> carsMap = new HashMap<String, Boolean>(); |
| 238 | for (int i = 0; i < carsList.size(); i++) { | 245 | for (int i = 0; i < carsList.size(); i++) { |
| 239 | Cars c = carsList.get(i); | 246 | Cars c = carsList.get(i); |
| 240 | - carsMap.put(c.getInsideCode(), c.getSfdc()); | 247 | + carsMap.put(c.getInsideCode(), (c.getSfdc()!=null?c.getSfdc():false) |
| 248 | + || (c.getSfmix()!=null?c.getSfmix():false));//电车或油电混合,都可以充电 | ||
| 241 | } | 249 | } |
| 242 | String rq = map2.get("rq").toString(); | 250 | String rq = map2.get("rq").toString(); |
| 243 | String line = ""; | 251 | String line = ""; |
| @@ -257,8 +265,8 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | @@ -257,8 +265,8 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | ||
| 257 | nbbm=map2.get("nbbm_eq").toString(); | 265 | nbbm=map2.get("nbbm_eq").toString(); |
| 258 | } | 266 | } |
| 259 | SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); | 267 | SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); |
| 260 | - // 保留两位小数 | ||
| 261 | - DecimalFormat df = new DecimalFormat("#.00"); | 268 | + // 加注量与能耗保留两位小数 |
| 269 | + DecimalFormat df = new DecimalFormat("0.##"); | ||
| 262 | // TODO Auto-generated method stub | 270 | // TODO Auto-generated method stub |
| 263 | // 当天DLB信息 | 271 | // 当天DLB信息 |
| 264 | List<Dlb> dlList = this.listOrderBy(rq,gsbm,fgsbm,"",nbbm,"nbbm"); | 272 | List<Dlb> dlList = this.listOrderBy(rq,gsbm,fgsbm,"",nbbm,"nbbm"); |
| @@ -281,8 +289,9 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | @@ -281,8 +289,9 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | ||
| 281 | } | 289 | } |
| 282 | } | 290 | } |
| 283 | 291 | ||
| 284 | - List<Jdl> jdlList=jdlRepository.JdlList(rq); | ||
| 285 | - List<Jdl> jdlList_1=jdlRepository.JdlList_1(rq, gsbm, "-1"); | 292 | + List<Jdl> jdlList = jdlRepository.JdlList(rq); |
| 293 | +// List<Jdl> jdlList = jdlService.queryJdlByJdlReception(rq, ""); | ||
| 294 | +// jdlList.addAll(jdlRepository.JdlList(rq)); | ||
| 286 | String sxtj=map2.get("sxtj").toString(); | 295 | String sxtj=map2.get("sxtj").toString(); |
| 287 | if(sxtj.equals("0")){ | 296 | if(sxtj.equals("0")){ |
| 288 | listpb=listpbs; | 297 | listpb=listpbs; |
| @@ -360,41 +369,15 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | @@ -360,41 +369,15 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | ||
| 360 | //车辆总里程 | 369 | //车辆总里程 |
| 361 | double zlc =lcMap.get(map_.get("clZbh").toString()); | 370 | double zlc =lcMap.get(map_.get("clZbh").toString()); |
| 362 | //车辆总加电量 | 371 | //车辆总加电量 |
| 363 | - double zjzl = 0.0, zjzl_1 = 0.0; | ||
| 364 | - for (int j = 0; j < ylxxList.size(); j++) { | ||
| 365 | - Ylxxb ylxxb = ylxxList.get(j); | ||
| 366 | - if (map_.get("clZbh").toString().equals(ylxxb.getNbbm()) | ||
| 367 | - && map_.get("company").toString().equals(ylxxb.getGsdm())) { | ||
| 368 | - zjzl = Arith.add(zjzl, ylxxb.getJzl()); | ||
| 369 | - } | ||
| 370 | - } | 372 | + double zjzl = 0.0; |
| 373 | + // 2022年12月20号要求不按车队导入,这之后导入的加注量将覆盖原加注量 | ||
| 371 | for (int i = 0; i < jdlList.size(); i++) { | 374 | for (int i = 0; i < jdlList.size(); i++) { |
| 372 | Jdl jdl=jdlList.get(i); | 375 | Jdl jdl=jdlList.get(i); |
| 373 | - if(map_.get("clZbh").toString().equals(jdl.getNbbm()) | ||
| 374 | - &&clFgs.get(map_.get("clZbh").toString()).contains(jdl.getGsBm()+"_"+jdl.getFgsBm())){ | ||
| 375 | - zjzl = Arith.add(zjzl,jdl.getJdl()); | 376 | + if(map_.get("clZbh").toString().equals(jdl.getNbbm())){ |
| 377 | + zjzl = Arith.add(zjzl, jdl.getJdl()); | ||
| 376 | } | 378 | } |
| 377 | } | 379 | } |
| 378 | - int num = 0; // 2022年12月20号要求不按车队导入,这之后导入的加注量将覆盖原加注量 | ||
| 379 | - for (int i = 0; i < jdlList_1.size(); i++) { | ||
| 380 | - Jdl jdl=jdlList_1.get(i); | ||
| 381 | - if(map_.get("clZbh").toString().equals(jdl.getNbbm()) | ||
| 382 | - &&map_.get("company").toString().equals(jdl.getGsBm())){ | ||
| 383 | - zjzl_1 = Arith.add(zjzl_1,jdl.getJdl()); | ||
| 384 | - num++; | ||
| 385 | - } | ||
| 386 | - } | ||
| 387 | - if(num > 0){ | ||
| 388 | - zjzl = zjzl_1; | ||
| 389 | - } | ||
| 390 | 380 | ||
| 391 | -// double clsh=0.0; | ||
| 392 | -// if(shMap.get(map_.get("clZbh").toString())==null){ | ||
| 393 | -// clsh=0.0; | ||
| 394 | -// }else{ | ||
| 395 | -// clsh=shMap.get(map_.get("clZbh").toString()); | ||
| 396 | -// } | ||
| 397 | -// zjzl =Arith.sub(zjzl, clsh); | ||
| 398 | Double nextJzyl = 0.0; | 381 | Double nextJzyl = 0.0; |
| 399 | for (int i = 0; i < listpb.size(); i++) { | 382 | for (int i = 0; i < listpb.size(); i++) { |
| 400 | Map<String, Object> map = listpb.get(i); | 383 | Map<String, Object> map = listpb.get(i); |
| @@ -934,18 +917,26 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | @@ -934,18 +917,26 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | ||
| 934 | String fgsdm,String xlbm,String nbbm, | 917 | String fgsdm,String xlbm,String nbbm, |
| 935 | String px) { | 918 | String px) { |
| 936 | // TODO Auto-generated method stub | 919 | // TODO Auto-generated method stub |
| 937 | - String sql="SELECT * FROM bsth_c_dlb " | ||
| 938 | - + " where rq='"+rq+"' and ssgsdm like '%"+gsdm+"%' " | ||
| 939 | - + " and fgsdm like '%"+fgsdm+"%'"; | 920 | + List<String> objList = new ArrayList<String>(); |
| 921 | + String sql="SELECT * FROM bsth_c_dlb " | ||
| 922 | + + " where rq = ? " | ||
| 923 | + + " and ssgsdm like ? " | ||
| 924 | + + " and fgsdm like ? "; | ||
| 925 | + objList.add(rq); | ||
| 926 | + objList.add('%' + gsdm + '%'); | ||
| 927 | + objList.add('%' + fgsdm + '%'); | ||
| 940 | if(xlbm.equals("")){ | 928 | if(xlbm.equals("")){ |
| 941 | - sql+= " and xlbm like '%"+xlbm+"%' "; | 929 | + sql+= " and xlbm like ? "; |
| 930 | + objList.add('%' + xlbm + '%'); | ||
| 942 | }else{ | 931 | }else{ |
| 943 | - sql+= " and xlbm = '"+xlbm+"' "; | 932 | + sql+= " and xlbm = ? "; |
| 933 | + objList.add(xlbm); | ||
| 944 | } | 934 | } |
| 945 | - | ||
| 946 | - sql += "and nbbm like '%"+nbbm+"%' order by "+px+" asc "; | ||
| 947 | 935 | ||
| 948 | - List<Dlb> list = jdbcTemplate.query(sql, new RowMapper<Dlb>() { | 936 | + sql += "and nbbm like ? order by "+px+" asc "; |
| 937 | + objList.add('%' + nbbm + '%'); | ||
| 938 | + | ||
| 939 | + List<Dlb> list = jdbcTemplate.query(sql, objList.toArray(), new RowMapper<Dlb>() { | ||
| 949 | @Override | 940 | @Override |
| 950 | public Dlb mapRow(ResultSet arg0, int arg1) throws SQLException { | 941 | public Dlb mapRow(ResultSet arg0, int arg1) throws SQLException { |
| 951 | Dlb y = new Dlb(); | 942 | Dlb y = new Dlb(); |
| @@ -1075,8 +1066,8 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | @@ -1075,8 +1066,8 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | ||
| 1075 | // TODO Auto-generated method stub | 1066 | // TODO Auto-generated method stub |
| 1076 | Map<String, List<Dlb>> mapList=new HashMap<String,List<Dlb>>(); | 1067 | Map<String, List<Dlb>> mapList=new HashMap<String,List<Dlb>>(); |
| 1077 | SimpleDateFormat sdf=new SimpleDateFormat("yyyy-MM-dd"); | 1068 | SimpleDateFormat sdf=new SimpleDateFormat("yyyy-MM-dd"); |
| 1078 | - // 保留两位小数 | ||
| 1079 | - DecimalFormat df = new DecimalFormat("#.00"); | 1069 | + // 加注量与能耗保留两位小数 |
| 1070 | + DecimalFormat df = new DecimalFormat("0.##"); | ||
| 1080 | List<Dlb> dlbList=this.listOrderBy(date,gsdm,fgsdm,"","","nbbm"); | 1071 | List<Dlb> dlbList=this.listOrderBy(date,gsdm,fgsdm,"","","nbbm"); |
| 1081 | List<Dlb> dlbList_upd=new ArrayList<Dlb>(); | 1072 | List<Dlb> dlbList_upd=new ArrayList<Dlb>(); |
| 1082 | List<Dlb> dlbList_del=new ArrayList<Dlb>(); | 1073 | List<Dlb> dlbList_del=new ArrayList<Dlb>(); |
| @@ -1132,8 +1123,11 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | @@ -1132,8 +1123,11 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | ||
| 1132 | shMap.put(cl, Arith.add(sh, dlb.getSh())); | 1123 | shMap.put(cl, Arith.add(sh, dlb.getSh())); |
| 1133 | } | 1124 | } |
| 1134 | } | 1125 | } |
| 1135 | - List<Jdl> jdlList=jdlRepository.JdlList(date); | ||
| 1136 | - List<Ylxxb> ylxxList = ylxxbRepository.obtainYlxx(date, 0,gsdm); | 1126 | + List<Jdl> jdlList = jdlRepository.JdlList(date); |
| 1127 | +// List<Jdl> jdlList = jdlService.queryJdlByJdlReception(date, ""); | ||
| 1128 | +// jdlList.addAll(jdlRepository.JdlList(date)); | ||
| 1129 | + | ||
| 1130 | +// List<Ylxxb> ylxxList = ylxxbRepository.obtainYlxx(date, 0,gsdm); | ||
| 1137 | Map<String, Object> newMap_=new HashMap<String,Object>(); | 1131 | Map<String, Object> newMap_=new HashMap<String,Object>(); |
| 1138 | Map<String, Object> cMap=new HashMap<String, Object>(); | 1132 | Map<String, Object> cMap=new HashMap<String, Object>(); |
| 1139 | List<Map<String, Object>> listpb_=listpbDc; | 1133 | List<Map<String, Object>> listpb_=listpbDc; |
| @@ -1148,19 +1142,10 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | @@ -1148,19 +1142,10 @@ public class DlbServiceImpl extends BaseServiceImpl<Dlb,Integer> implements DlbS | ||
| 1148 | double zlc =lcMap.get(map_.get("clZbh").toString()); | 1142 | double zlc =lcMap.get(map_.get("clZbh").toString()); |
| 1149 | //车辆总加电量 | 1143 | //车辆总加电量 |
| 1150 | double zjzl = 0.0; | 1144 | double zjzl = 0.0; |
| 1151 | - for (int j = 0; j < ylxxList.size(); j++) { | ||
| 1152 | - Ylxxb ylxxb = ylxxList.get(j); | ||
| 1153 | - if (map_.get("clZbh").toString().equals(ylxxb.getNbbm()) | ||
| 1154 | - && map_.get("company").toString().equals(ylxxb.getGsdm())) { | ||
| 1155 | - zjzl = Arith.add(zjzl, ylxxb.getJzl()); | ||
| 1156 | - } | ||
| 1157 | - } | ||
| 1158 | for (int i = 0; i < jdlList.size(); i++) { | 1145 | for (int i = 0; i < jdlList.size(); i++) { |
| 1159 | Jdl jdl=jdlList.get(i); | 1146 | Jdl jdl=jdlList.get(i); |
| 1160 | - if(map_.get("clZbh").toString().equals(jdl.getNbbm()) | ||
| 1161 | - &&map_.get("company").toString().equals(jdl.getGsBm()) | ||
| 1162 | - &&map_.get("bCompany").toString().equals(jdl.getFgsBm())){ | ||
| 1163 | - zjzl = Arith.add(zjzl,jdl.getJdl()); | 1147 | + if(map_.get("clZbh").toString().equals(jdl.getNbbm())){ |
| 1148 | + zjzl = Arith.add(zjzl, jdl.getJdl()); | ||
| 1164 | } | 1149 | } |
| 1165 | } | 1150 | } |
| 1166 | double clsh=0.0; | 1151 | double clsh=0.0; |
src/main/java/com/bsth/service/oil/impl/JdlServiceImpl.java
| 1 | package com.bsth.service.oil.impl; | 1 | package com.bsth.service.oil.impl; |
| 2 | 2 | ||
| 3 | +import java.io.BufferedInputStream; | ||
| 4 | +import java.io.BufferedOutputStream; | ||
| 3 | import java.io.File; | 5 | import java.io.File; |
| 4 | import java.io.FileInputStream; | 6 | import java.io.FileInputStream; |
| 7 | +import java.io.IOException; | ||
| 8 | +import java.io.InputStream; | ||
| 9 | +import java.io.OutputStream; | ||
| 10 | +import java.math.BigDecimal; | ||
| 11 | +import java.math.RoundingMode; | ||
| 5 | import java.text.DecimalFormat; | 12 | import java.text.DecimalFormat; |
| 6 | import java.text.SimpleDateFormat; | 13 | import java.text.SimpleDateFormat; |
| 7 | import java.util.ArrayList; | 14 | import java.util.ArrayList; |
| @@ -11,25 +18,51 @@ import java.util.Iterator; | @@ -11,25 +18,51 @@ import java.util.Iterator; | ||
| 11 | import java.util.List; | 18 | import java.util.List; |
| 12 | import java.util.Map; | 19 | import java.util.Map; |
| 13 | 20 | ||
| 21 | +import javax.servlet.http.HttpServletResponse; | ||
| 22 | + | ||
| 14 | import org.apache.poi.hssf.usermodel.HSSFCell; | 23 | import org.apache.poi.hssf.usermodel.HSSFCell; |
| 24 | +import org.apache.poi.hssf.usermodel.HSSFDateUtil; | ||
| 15 | import org.apache.poi.hssf.usermodel.HSSFRow; | 25 | import org.apache.poi.hssf.usermodel.HSSFRow; |
| 16 | import org.apache.poi.hssf.usermodel.HSSFSheet; | 26 | import org.apache.poi.hssf.usermodel.HSSFSheet; |
| 17 | import org.apache.poi.hssf.usermodel.HSSFWorkbook; | 27 | import org.apache.poi.hssf.usermodel.HSSFWorkbook; |
| 18 | import org.apache.poi.poifs.filesystem.POIFSFileSystem; | 28 | import org.apache.poi.poifs.filesystem.POIFSFileSystem; |
| 19 | import org.springframework.beans.factory.annotation.Autowired; | 29 | import org.springframework.beans.factory.annotation.Autowired; |
| 30 | +import org.springframework.beans.factory.annotation.Value; | ||
| 20 | import org.springframework.stereotype.Service; | 31 | import org.springframework.stereotype.Service; |
| 21 | 32 | ||
| 33 | +import com.bsth.common.ResponseCode; | ||
| 22 | import com.bsth.entity.oil.Jdl; | 34 | import com.bsth.entity.oil.Jdl; |
| 35 | +import com.bsth.entity.oil.JdlConnector; | ||
| 36 | +import com.bsth.entity.oil.JdlReception; | ||
| 37 | +import com.bsth.entity.oil.Nylog; | ||
| 38 | +import com.bsth.entity.sys.SysUser; | ||
| 39 | +import com.bsth.repository.oil.JdlConnectorRepository; | ||
| 40 | +import com.bsth.repository.oil.JdlReceptionRepository; | ||
| 23 | import com.bsth.repository.oil.JdlRepository; | 41 | import com.bsth.repository.oil.JdlRepository; |
| 42 | +import com.bsth.repository.oil.NylogRepository; | ||
| 43 | +import com.bsth.security.util.SecurityUtils; | ||
| 24 | import com.bsth.service.impl.BaseServiceImpl; | 44 | import com.bsth.service.impl.BaseServiceImpl; |
| 25 | import com.bsth.service.oil.JdlService; | 45 | import com.bsth.service.oil.JdlService; |
| 26 | import com.bsth.util.ReportUtils; | 46 | import com.bsth.util.ReportUtils; |
| 47 | +import com.google.common.io.Files; | ||
| 27 | 48 | ||
| 28 | @Service | 49 | @Service |
| 29 | public class JdlServiceImpl extends BaseServiceImpl<Jdl, Integer> implements JdlService { | 50 | public class JdlServiceImpl extends BaseServiceImpl<Jdl, Integer> implements JdlService { |
| 30 | 51 | ||
| 31 | @Autowired | 52 | @Autowired |
| 32 | JdlRepository repository; | 53 | JdlRepository repository; |
| 54 | + | ||
| 55 | + @Autowired | ||
| 56 | + JdlReceptionRepository jdlReceptionRepository; | ||
| 57 | + | ||
| 58 | + @Autowired | ||
| 59 | + JdlConnectorRepository jdlConnectorRepository; | ||
| 60 | + | ||
| 61 | + @Autowired | ||
| 62 | + NylogRepository nylogRepository; | ||
| 63 | + | ||
| 64 | + @Value("${electricity.importFile.path}") | ||
| 65 | + private String elecImportFilePath; | ||
| 33 | 66 | ||
| 34 | @Override | 67 | @Override |
| 35 | public String importExcel(File file, String gsbm, String gsName, String fgsbm, String fgsName) { | 68 | public String importExcel(File file, String gsbm, String gsName, String fgsbm, String fgsName) { |
| @@ -156,5 +189,576 @@ public class JdlServiceImpl extends BaseServiceImpl<Jdl, Integer> implements Jdl | @@ -156,5 +189,576 @@ public class JdlServiceImpl extends BaseServiceImpl<Jdl, Integer> implements Jdl | ||
| 156 | } | 189 | } |
| 157 | return modelMap; | 190 | return modelMap; |
| 158 | } | 191 | } |
| 192 | + | ||
| 193 | + @Override | ||
| 194 | + public String importExcel_2412(File file, String gsbm, String gsName, String fgsbm, String fgsName, String stationName) { | ||
| 195 | + SimpleDateFormat yearMonthFormat = new SimpleDateFormat("yyyy-MM"); | ||
| 196 | + SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); | ||
| 197 | + SimpleDateFormat sd = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); | ||
| 198 | + SimpleDateFormat SSSformat = new SimpleDateFormat("yyMMddHHmmssSS"); | ||
| 199 | + SimpleDateFormat ddFormat = new SimpleDateFormat("dd"); | ||
| 200 | + DecimalFormat df = new DecimalFormat("0.00"); | ||
| 201 | + df.setRoundingMode(RoundingMode.HALF_UP); // 设置为四舍五入的进位方式 | ||
| 202 | + SysUser user = SecurityUtils.getCurrentUser(); | ||
| 203 | + Date currDate = new Date(); | ||
| 204 | + List<String> textList = new ArrayList<String>(); | ||
| 205 | + String batchNo = user.getUserName() + SSSformat.format(currDate); | ||
| 206 | + String msg = ""; | ||
| 207 | + try { | ||
| 208 | + POIFSFileSystem fs = new POIFSFileSystem(new FileInputStream(file)); | ||
| 209 | + HSSFWorkbook wb = new HSSFWorkbook(fs); | ||
| 210 | + HSSFSheet sheet = wb.getSheetAt(0); | ||
| 211 | + // 取得总行数 | ||
| 212 | + int rowNum = sheet.getLastRowNum() + 1; | ||
| 213 | + // 取得总列数 | ||
| 214 | + int cellNum = sheet.getRow(0).getLastCellNum(); | ||
| 215 | + HSSFRow row = null; | ||
| 216 | + HSSFCell cell = null; | ||
| 217 | + for(int i = 3; i < rowNum; i++){ | ||
| 218 | + row = sheet.getRow(i); | ||
| 219 | + if (row == null){ | ||
| 220 | + continue; | ||
| 221 | + } | ||
| 222 | + String text = ""; | ||
| 223 | + for(int j = 0; j < cellNum; j++){ | ||
| 224 | + cell = row.getCell(j); | ||
| 225 | + if(cell == null){ | ||
| 226 | + text += ","; | ||
| 227 | + continue; | ||
| 228 | + } | ||
| 229 | + if(cell.getCellType() == HSSFCell.CELL_TYPE_NUMERIC && HSSFDateUtil.isCellDateFormatted(cell)){ | ||
| 230 | + Date dateCellValue = cell.getDateCellValue(); | ||
| 231 | + text += sd.format(dateCellValue) + ","; | ||
| 232 | + } else { | ||
| 233 | + text += String.valueOf(cell) + ","; | ||
| 234 | + } | ||
| 235 | + } | ||
| 236 | + String[] split = (text+";").split(","); | ||
| 237 | + String str = ""; | ||
| 238 | + for(int j = 0; j < split.length && j < 12; j++){ | ||
| 239 | + str += split[j]; | ||
| 240 | + } | ||
| 241 | + if(str.trim().length() == 0) | ||
| 242 | + continue; | ||
| 243 | + textList.add(text); | ||
| 244 | + } | ||
| 245 | + | ||
| 246 | + List<JdlConnector> connectorList = jdlConnectorRepository.query("", "", stationName); | ||
| 247 | + Map<String, JdlConnector> connectorNameMap = new HashMap<String, JdlConnector>(); | ||
| 248 | + Map<String, JdlConnector> connectorIdMap = new HashMap<String, JdlConnector>(); | ||
| 249 | + for(JdlConnector c : connectorList){ | ||
| 250 | + connectorNameMap.put(c.getConnectorName(), c); | ||
| 251 | + connectorIdMap.put(c.getConnectorId(), c); | ||
| 252 | + } | ||
| 253 | + | ||
| 254 | + // 校验车辆充电时间冲突的临时对象。 | ||
| 255 | + Map<String, List<JdlReception>> repeatCarMap = new HashMap<String, List<JdlReception>>(); | ||
| 256 | + Map<String, List<JdlReception>> repeatConnectorMap = new HashMap<String, List<JdlReception>>(); | ||
| 257 | + | ||
| 258 | + String str = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"; | ||
| 259 | + List<JdlReception> list = new ArrayList<JdlReception>(); | ||
| 260 | + for(int i = 0; i < textList.size(); i++){ | ||
| 261 | + String text = textList.get(i); | ||
| 262 | + String[] split = text.split(","); | ||
| 263 | + if(split.length > 4 && split[1] != null && split[1].trim().length() > 0 && | ||
| 264 | + split[3] != null && split[3].trim().length() > 0){ | ||
| 265 | + int lie = 1; | ||
| 266 | + try { | ||
| 267 | + Integer dd = Integer.valueOf(split[lie].trim().split("\\.")[0]); // 日期 | ||
| 268 | + lie++;String gun = split[lie].trim().split("\\.")[0]; // 充电枪 | ||
| 269 | + lie++;String nbbm = split[lie].trim(); // 车号 | ||
| 270 | + lie++;String startTime = split[lie].trim(); // 开始时间 | ||
| 271 | + lie++;String endTime = split[lie].trim(); // 结束时间 | ||
| 272 | + lie++;String sumTime = split[lie].trim(); // 总计(分钟) | ||
| 273 | + lie++;String startSoc = split[lie].trim(); // 起始电量SOC% | ||
| 274 | + lie++;String endSoc = split[lie].trim(); // 结束电量SOC% | ||
| 275 | + lie++;String jdl = split[lie].trim(); // 充电度数 | ||
| 276 | + String lc = "", stopReason = ""; | ||
| 277 | + lie++; | ||
| 278 | + if(split.length > lie) | ||
| 279 | + lc = split[lie].trim(); // 里程读数 | ||
| 280 | + lie++; | ||
| 281 | + if(split.length > lie) | ||
| 282 | + stopReason = split[lie].trim(); // 一次不能正常充电记录 | ||
| 283 | + | ||
| 284 | + sumTime = sumTime.split("\\.")[0]; | ||
| 285 | + | ||
| 286 | + Date parseStartTime = sd.parse(startTime); | ||
| 287 | + Date parseEndTime = sd.parse(endTime); | ||
| 288 | + if(parseStartTime.getTime() > parseEndTime.getTime()){ | ||
| 289 | + msg += System.lineSeparator() + "文档第"+(i + 4)+"行,充电结束时间小于开始时间;"; | ||
| 290 | + continue; | ||
| 291 | + } | ||
| 292 | + long sub = ((parseEndTime.getTime() - parseStartTime.getTime()) / (1l*1000*60)) - Long.valueOf(sumTime); | ||
| 293 | + if(sub > 2 || sub < -2){ | ||
| 294 | + msg += System.lineSeparator() + "文档第"+(i + 4)+"行,充电时间总计分钟数("+sumTime+")误差超过2分钟;"; | ||
| 295 | + } | ||
| 296 | + | ||
| 297 | + if(!connectorNameMap.containsKey(gun) && !connectorIdMap.containsKey(gun)){ | ||
| 298 | + msg += System.lineSeparator() + "文档第"+(i + 4)+"行,充电枪无法识别或不在库中;"; | ||
| 299 | + | ||
| 300 | + } | ||
| 301 | + JdlConnector jdlConnector = connectorNameMap.containsKey(gun) ? connectorNameMap.get(gun) | ||
| 302 | + : (connectorIdMap.containsKey(gun) ? connectorIdMap.get(gun) : new JdlConnector()); | ||
| 303 | + | ||
| 304 | + JdlReception jdlRe = new JdlReception(); | ||
| 305 | + Date date = sd.parse(startTime); | ||
| 306 | + if(!(dd == Integer.valueOf(ddFormat.format(date)))){ | ||
| 307 | + date.setTime(date.getTime() - 1l*1000*60*60*24); | ||
| 308 | + } | ||
| 309 | + | ||
| 310 | + jdl = df.format(new BigDecimal(jdl)); // 用Double或float总有各种格样的问题,这里直接用BigDecimal;也可以直接用BigDecimal做四舍五入 | ||
| 311 | + | ||
| 312 | + jdlRe.setBatchNo(batchNo); | ||
| 313 | + jdlRe.setDateStr(sdf.format(date)); | ||
| 314 | + jdlRe.setConnectorName(jdlConnector.getConnectorName()); | ||
| 315 | + jdlRe.setConnectorId(jdlConnector.getConnectorId()); | ||
| 316 | + jdlRe.setStationName(jdlConnector.getStationName()); | ||
| 317 | + jdlRe.setCarCode(nbbm); | ||
| 318 | + jdlRe.setStartTime(startTime); | ||
| 319 | + jdlRe.setEndTime(endTime); | ||
| 320 | + jdlRe.setSumTime(Integer.valueOf(sumTime)); | ||
| 321 | + jdlRe.setStartSoc(Double.valueOf(startSoc)); | ||
| 322 | + jdlRe.setEndSoc(Double.valueOf(endSoc)); | ||
| 323 | + jdlRe.setChargeCapacity(Double.valueOf(jdl)); | ||
| 324 | + jdlRe.setRemark(lc); // 里程读数目前用不到,暂时放到备注字段里。 | ||
| 325 | + jdlRe.setStopReason(stopReason); | ||
| 326 | + jdlRe.setCreateBy(user.getUserName()); | ||
| 327 | + jdlRe.setCreateDate(currDate); | ||
| 328 | + jdlRe.setOrigin(1); | ||
| 329 | + | ||
| 330 | + List<JdlReception> queryRepeatCar = jdlReceptionRepository.queryRepeatCar(startTime, endTime, nbbm); | ||
| 331 | + if(queryRepeatCar.size() > 0){ | ||
| 332 | + msg += System.lineSeparator() + "文档第"+(i + 4)+"行,车号("+nbbm+")充电时间与库中同车号存在重叠;"; | ||
| 333 | + | ||
| 334 | + } else if(repeatCarMap.containsKey(nbbm)){ | ||
| 335 | + Long startTimeLong = parseStartTime.getTime(); | ||
| 336 | + Long endTimeLong = parseEndTime.getTime(); | ||
| 337 | + List<JdlReception> JdlReceptionList = repeatCarMap.get(nbbm); | ||
| 338 | + boolean flag = false; | ||
| 339 | + for(JdlReception temp : JdlReceptionList){ | ||
| 340 | + Long tempStartTime = sd.parse(temp.getStartTime()).getTime(); | ||
| 341 | + Long tempEndTime = sd.parse(temp.getEndTime()).getTime(); | ||
| 342 | + if(startTimeLong <= tempEndTime && endTimeLong >= tempStartTime){ | ||
| 343 | + msg += System.lineSeparator() + "文档第"+(i + 4)+"行,车号("+nbbm+")充电时间与文档中同车号存在重叠;"; | ||
| 344 | + flag = true; | ||
| 345 | + break; // 判断重叠直接跳过,不需要再查询一次sql | ||
| 346 | + } | ||
| 347 | + } | ||
| 348 | + if(flag){ | ||
| 349 | + repeatCarMap.get(nbbm).add(jdlRe); | ||
| 350 | + list.add(jdlRe); | ||
| 351 | + } | ||
| 352 | + } | ||
| 353 | + if(!repeatCarMap.containsKey(nbbm)){ | ||
| 354 | + repeatCarMap.put(nbbm, new ArrayList<JdlReception>()); | ||
| 355 | + } | ||
| 356 | + repeatCarMap.get(nbbm).add(jdlRe); | ||
| 357 | + | ||
| 358 | + | ||
| 359 | + String connectorId = jdlConnector.getConnectorId(); | ||
| 360 | + if(connectorId != null){ | ||
| 361 | + List<JdlReception> queryRepeatConnector = jdlReceptionRepository.queryRepeatConnector(startTime, endTime, connectorId, nbbm); | ||
| 362 | + if(queryRepeatConnector.size() > 0){ | ||
| 363 | + msg += System.lineSeparator() + "文档第"+(i + 4)+"行,充电枪("+jdlConnector.getConnectorName()+")充电时间与库中其他车辆存在重叠;"; | ||
| 364 | + | ||
| 365 | + } else if(repeatConnectorMap.containsKey(connectorId)){ | ||
| 366 | + Long startTimeLong = parseStartTime.getTime(); | ||
| 367 | + Long endTimeLong = parseEndTime.getTime(); | ||
| 368 | + List<JdlReception> JdlReceptionList = repeatConnectorMap.get(connectorId); | ||
| 369 | + boolean flag = false; | ||
| 370 | + for(JdlReception temp : JdlReceptionList){ | ||
| 371 | + if(temp.getConnectorId() != null && !connectorId.equals(temp.getConnectorId())){ | ||
| 372 | + Long tempStartTime = sd.parse(temp.getStartTime()).getTime(); | ||
| 373 | + Long tempEndTime = sd.parse(temp.getEndTime()).getTime(); | ||
| 374 | + if(startTimeLong <= tempEndTime && endTimeLong >= tempStartTime){ | ||
| 375 | + msg += System.lineSeparator() + "文档第"+(i + 4)+"行,充电枪("+jdlConnector.getConnectorName()+")充电时间与文档中其他车辆存在重叠;"; | ||
| 376 | + flag = true; | ||
| 377 | + break; // 判断重叠直接跳过,不需要再查询一次sql | ||
| 378 | + } | ||
| 379 | + } | ||
| 380 | + } | ||
| 381 | + if(flag){ | ||
| 382 | + repeatCarMap.get(nbbm).add(jdlRe); | ||
| 383 | + list.add(jdlRe); | ||
| 384 | + } | ||
| 385 | + } | ||
| 386 | + if(!repeatConnectorMap.containsKey(nbbm)){ | ||
| 387 | + repeatConnectorMap.put(connectorId, new ArrayList<JdlReception>()); | ||
| 388 | + } | ||
| 389 | + repeatConnectorMap.get(connectorId).add(jdlRe); | ||
| 390 | + } | ||
| 391 | + | ||
| 392 | + list.add(jdlRe); | ||
| 393 | + } catch (Exception e) { | ||
| 394 | + // TODO: handle exception | ||
| 395 | + e.printStackTrace(); | ||
| 396 | + msg += System.lineSeparator() + "文档第"+(i + 4)+"行第"+str.charAt(lie)+"列,格式错误或无法识别;"; | ||
| 397 | + } | ||
| 398 | + } | ||
| 399 | + } | ||
| 400 | + wb.close(); | ||
| 401 | + fs.close(); | ||
| 402 | + if(msg.length() > 0){ | ||
| 403 | + return "文件导入失败" + msg; | ||
| 404 | + } else { | ||
| 405 | + jdlReceptionRepository.saveAll(list); | ||
| 406 | + return "文件导入成功," + "导入了" + list.size() + "条充电量。"; | ||
| 407 | + } | ||
| 408 | + } catch (Exception e) { | ||
| 409 | + // TODO Auto-generated catch block | ||
| 410 | + e.printStackTrace(); | ||
| 411 | + return "文件导入失败"; | ||
| 412 | + } finally { | ||
| 413 | +// file.delete(); | ||
| 414 | + try { | ||
| 415 | + String yearMonthPath = yearMonthFormat.format(currDate); | ||
| 416 | + File elecImportFile = new File(elecImportFilePath + File.separator + yearMonthPath); | ||
| 417 | + if(!elecImportFile.exists()){ | ||
| 418 | + elecImportFile.mkdirs(); | ||
| 419 | + } | ||
| 420 | + String path = file.getPath(); | ||
| 421 | + System.out.println(path); | ||
| 422 | + String[] split = file.getName().split("\\."); | ||
| 423 | + String suffix = split[split.length - 1]; | ||
| 424 | + Files.move(file, new File(elecImportFilePath + File.separator + yearMonthPath + File.separator + batchNo + "." + suffix)); | ||
| 425 | + Nylog nylog=new Nylog(); | ||
| 426 | + nylog.setCreatedate(currDate); | ||
| 427 | + nylog.setNylx("电"); | ||
| 428 | + nylog.setCzmc("导入"); | ||
| 429 | + nylog.setUserid(user.getUserName()); | ||
| 430 | + nylog.setUsername(user.getName()); | ||
| 431 | + nylog.setCxtj(batchNo); | ||
| 432 | + nylog.setFwdz(yearMonthPath + File.separator + batchNo + "." + suffix); | ||
| 433 | + nylogRepository.save(nylog); | ||
| 434 | + } catch (IOException e) { | ||
| 435 | + // TODO Auto-generated catch block | ||
| 436 | + e.printStackTrace(); | ||
| 437 | + } | ||
| 438 | + } | ||
| 439 | + } | ||
| 440 | + | ||
| 441 | + @Override | ||
| 442 | + public Map<String, Object> query_2412(Map<String, Object> map) { | ||
| 443 | + SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"), | ||
| 444 | + sdfSimple = new SimpleDateFormat("yyyyMMdd"); | ||
| 445 | + Map<String, Object> modelMap = new HashMap<String, Object>(); | ||
| 446 | + String rq = map.get("rq").toString(); | ||
| 447 | + String nbbm = map.get("nbbm").toString(); | ||
| 448 | + Integer page = Integer.valueOf(map.containsKey("page")?map.get("page").toString():"0"); | ||
| 449 | + List<Jdl> query = new ArrayList<Jdl>(); | ||
| 450 | + | ||
| 451 | + List<Object[]> querySum = jdlReceptionRepository.querySum(rq, nbbm); | ||
| 452 | + | ||
| 453 | + try { | ||
| 454 | + for(Object[] j : querySum){ | ||
| 455 | + Jdl jdl = new Jdl(); | ||
| 456 | + jdl.setRq(sdfMonth.parse(j[0].toString())); | ||
| 457 | + jdl.setNbbm(j[1].toString()); | ||
| 458 | + jdl.setJdl(Double.valueOf(j[2].toString())); | ||
| 459 | + jdl.setJdz(""); | ||
| 460 | + jdl.setRemarks(""); | ||
| 461 | + query.add(jdl); | ||
| 462 | + } | ||
| 463 | + } catch (Exception e) { | ||
| 464 | + // TODO Auto-generated catch block | ||
| 465 | + e.printStackTrace(); | ||
| 466 | + } | ||
| 467 | + | ||
| 468 | + if(!map.containsKey("type")){ | ||
| 469 | + | ||
| 470 | + int end = (page+1)*10>query.size()?query.size():(page+1)*10; | ||
| 471 | + modelMap.put("dataList", query.subList(page*10, end)); | ||
| 472 | + modelMap.put("totalPages", query.size()%10>0?query.size()/10+1:query.size()/10); | ||
| 473 | + | ||
| 474 | + } else if(map.get("type").toString().equals("export")){ | ||
| 475 | + | ||
| 476 | + List<Map<String, Object>> list = new ArrayList<Map<String, Object>>(); | ||
| 477 | + for(Jdl jdl : query){ | ||
| 478 | + Map<String, Object> m = new HashMap<String, Object>(); | ||
| 479 | + m.put("rq", sdfMonth.format(jdl.getRq())); | ||
| 480 | + m.put("nbbm", jdl.getNbbm()); | ||
| 481 | + m.put("jdl", jdl.getJdl()); | ||
| 482 | + m.put("jdz", jdl.getJdz()); | ||
| 483 | + m.put("remarks", jdl.getRemarks()); | ||
| 484 | + list.add(m); | ||
| 485 | + } | ||
| 486 | + | ||
| 487 | + List<Iterator<?>> listI = new ArrayList<Iterator<?>>(); | ||
| 488 | + Map<String, Object> m = new HashMap<String, Object>(); | ||
| 489 | + ReportUtils ee = new ReportUtils(); | ||
| 490 | + try { | ||
| 491 | + listI.add(list.iterator()); | ||
| 492 | + String path = this.getClass().getResource("/").getPath()+"static/pages/forms/"; | ||
| 493 | + ee.excelReplace(listI, new Object[] { m }, path+"mould/export_Jdl.xls", | ||
| 494 | + path+"export/车辆充电量" + sdfSimple.format(sdfMonth.parse(rq)) + ".xls"); | ||
| 495 | + } catch (Exception e) { | ||
| 496 | + // TODO: handle exception | ||
| 497 | + e.printStackTrace(); | ||
| 498 | + } | ||
| 499 | + } | ||
| 500 | + return modelMap; | ||
| 501 | + } | ||
| 502 | + | ||
| 503 | + @Override | ||
| 504 | + public List<JdlReception> queryJdlReception(Map<String, Object> map) { | ||
| 505 | + String rq = map.get("rq").toString(); | ||
| 506 | + String nbbm = map.get("nbbm").toString(); | ||
| 507 | + List<JdlReception> query = jdlReceptionRepository.query(rq, nbbm); | ||
| 508 | + return query; | ||
| 509 | + } | ||
| 510 | + | ||
| 511 | + @Override | ||
| 512 | + public Map<String, Object> queryJdlReceptionBatch(Map<String, Object> map) { | ||
| 513 | + SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"); | ||
| 514 | + Map<String, Object> modelMap = new HashMap<String, Object>(); | ||
| 515 | + String rq1 = map.get("rq1").toString(); | ||
| 516 | + String rq2 = map.get("rq2").toString(); | ||
| 517 | + String createBy = map.containsKey("createBy")?map.get("createBy").toString().trim():""; | ||
| 518 | + Integer page = Integer.valueOf(map.containsKey("page")?map.get("page").toString():"0"); | ||
| 519 | + List<Map<String, Object>> query = new ArrayList<Map<String, Object>>(); | ||
| 520 | + | ||
| 521 | + List<Object[]> queryBatch = jdlReceptionRepository.queryBatchByDates(rq1, rq2, createBy); | ||
| 522 | + | ||
| 523 | + try { | ||
| 524 | + for(Object[] j : queryBatch){ | ||
| 525 | + Map<String, Object> m = new HashMap<String, Object>(); | ||
| 526 | + m.put("batchNo", j[0]); | ||
| 527 | + m.put("createBy", j[1]); | ||
| 528 | + m.put("createDate", j[2]); | ||
| 529 | + query.add(m); | ||
| 530 | + } | ||
| 531 | + } catch (Exception e) { | ||
| 532 | + // TODO Auto-generated catch block | ||
| 533 | + e.printStackTrace(); | ||
| 534 | + } | ||
| 535 | + | ||
| 536 | + int end = (page+1)*10>query.size()?query.size():(page+1)*10; | ||
| 537 | + modelMap.put("dataList", query.subList(page*10, end)); | ||
| 538 | + modelMap.put("totalPages", query.size()%10>0?query.size()/10+1:query.size()/10); | ||
| 539 | + | ||
| 540 | + return modelMap; | ||
| 541 | + } | ||
| 542 | + | ||
| 543 | + @Override | ||
| 544 | + public List<JdlReception> queryJdlReceptionBatchData(Map<String, Object> map) { | ||
| 545 | + String createBy = map.get("createBy").toString(); | ||
| 546 | + String createDate = map.get("createDate").toString(); | ||
| 547 | + List<JdlReception> query = jdlReceptionRepository.queryBatchData(createBy, createDate); | ||
| 548 | + return query; | ||
| 549 | + } | ||
| 550 | + | ||
| 551 | + @Override | ||
| 552 | + public Map<String, Object> deleteJdlReceptionBatch(Map<String, Object> map) { | ||
| 553 | + Map<String, Object> resMap = new HashMap<>(); | ||
| 554 | + try{ | ||
| 555 | + String createBy = map.get("createBy").toString(); | ||
| 556 | + String createDate = map.get("createDate").toString(); | ||
| 557 | + jdlReceptionRepository.deleteBatch(createBy, createDate); | ||
| 558 | + resMap.put("status", ResponseCode.SUCCESS); | ||
| 559 | + }catch (Exception e){ | ||
| 560 | + resMap.put("status", ResponseCode.ERROR); | ||
| 561 | + resMap.put("msg", e.getMessage()); | ||
| 562 | + } | ||
| 563 | + return resMap; | ||
| 564 | + } | ||
| 565 | + | ||
| 566 | + @Override | ||
| 567 | + public Map<String, Object> updateJdlReceptionBatch(Map<String, Object> map) { | ||
| 568 | + Map<String, Object> resMap = new HashMap<>(); | ||
| 569 | + try{ | ||
| 570 | + String[] ids = map.get("ids").toString().length()>0?map.get("ids").toString().split(","):new String[0]; | ||
| 571 | + String[] dateStr = map.get("dateStr").toString().length()>0?map.get("dateStr").toString().split(","):new String[0]; | ||
| 572 | + String[] pileId = map.get("pileId").toString().length()>0?map.get("pileId").toString().split(","):new String[0]; | ||
| 573 | + String[] carCode = map.get("carCode").toString().length()>0?map.get("carCode").toString().split(","):new String[0]; | ||
| 574 | + String[] startTime = map.get("startTime").toString().length()>0?map.get("startTime").toString().split(","):new String[0]; | ||
| 575 | + String[] endTime = map.get("endTime").toString().length()>0?map.get("endTime").toString().split(","):new String[0]; | ||
| 576 | + String[] sumTime = map.get("sumTime").toString().length()>0?map.get("sumTime").toString().split(","):new String[0]; | ||
| 577 | + String[] startSoc = map.get("startSoc").toString().length()>0?map.get("startSoc").toString().split(","):new String[0]; | ||
| 578 | + String[] endSoc = map.get("endSoc").toString().length()>0?map.get("endSoc").toString().split(","):new String[0]; | ||
| 579 | + String[] chargeCapacity = map.get("chargeCapacity").toString().length()>0?map.get("chargeCapacity").toString().split(","):new String[0]; | ||
| 580 | + String[] stopReason = map.get("stopReason").toString().length()>0?map.get("stopReason").toString().split(","):new String[0]; | ||
| 581 | + List<JdlReception> list = new ArrayList<JdlReception>(); | ||
| 582 | + for(int i = 0; i < ids.length; i++){ | ||
| 583 | + if(ids[i].length() != 0){ | ||
| 584 | +// JdlReception jdlRe = new JdlReception(); | ||
| 585 | +// jdlRe.setId(Long.valueOf(ids[i])); | ||
| 586 | + JdlReception jdlRe = jdlReceptionRepository.queryById(Long.valueOf(ids[i])).get(0); | ||
| 587 | + if(dateStr.length > i) | ||
| 588 | + jdlRe.setDateStr(dateStr[i]); | ||
| 589 | + if(pileId.length > i) | ||
| 590 | + jdlRe.setPileId(pileId[i]); | ||
| 591 | + if(carCode.length > i) | ||
| 592 | + jdlRe.setCarCode(carCode[i]); | ||
| 593 | + if(startTime.length > i) | ||
| 594 | + jdlRe.setStartTime(startTime[i]); | ||
| 595 | + if(endTime.length > i) | ||
| 596 | + jdlRe.setEndTime(endTime[i]); | ||
| 597 | + if(sumTime.length > i) | ||
| 598 | + jdlRe.setSumTime(Integer.valueOf(sumTime[i])); | ||
| 599 | + if(startSoc.length > i) | ||
| 600 | + jdlRe.setStartSoc(Double.valueOf(startSoc[i])); | ||
| 601 | + if(endSoc.length > i) | ||
| 602 | + jdlRe.setEndSoc(Double.valueOf(endSoc[i])); | ||
| 603 | + if(chargeCapacity.length > i) | ||
| 604 | + jdlRe.setChargeCapacity(Double.valueOf(chargeCapacity[i])); | ||
| 605 | + if(stopReason.length > i) | ||
| 606 | + jdlRe.setStopReason(stopReason[i]); | ||
| 607 | + | ||
| 608 | + list.add(jdlRe); | ||
| 609 | + } | ||
| 610 | + } | ||
| 611 | + for(JdlReception jdlRe : list){ | ||
| 612 | + jdlReceptionRepository.update(jdlRe.getId(), jdlRe.getDateStr(), jdlRe.getPileId(), jdlRe.getCarCode(), | ||
| 613 | + jdlRe.getStartTime(), jdlRe.getEndTime(), jdlRe.getSumTime(), jdlRe.getStartSoc(), jdlRe.getEndSoc(), | ||
| 614 | + jdlRe.getChargeCapacity(), jdlRe.getStopReason()); | ||
| 615 | + } | ||
| 616 | + resMap.put("status", ResponseCode.SUCCESS); | ||
| 617 | + }catch (Exception e){ | ||
| 618 | + resMap.put("status", ResponseCode.ERROR); | ||
| 619 | + resMap.put("msg", e.getMessage()); | ||
| 620 | + } | ||
| 621 | + return resMap; | ||
| 622 | + } | ||
| 623 | + | ||
| 624 | + @Override | ||
| 625 | + public void downloadJdlReceptionImportFile(Map<String, Object> map, HttpServletResponse response) throws IOException { | ||
| 626 | + String batchNo = map.get("batchNo").toString(); | ||
| 627 | + List<Nylog> list = nylogRepository.selectByCxtj("电", "导入", batchNo); | ||
| 628 | + if(list.size() > 0){ | ||
| 629 | + Nylog nylog = list.get(0); | ||
| 630 | + String path = elecImportFilePath + File.separator + nylog.getFwdz(); | ||
| 631 | + String[] split = nylog.getFwdz().split("\\."); | ||
| 632 | + String fileName = batchNo + "." + split[split.length - 1]; | ||
| 633 | + File file = new File(path); | ||
| 634 | + InputStream fis = new BufferedInputStream(new FileInputStream(path)); | ||
| 635 | + byte[] buffer = new byte[fis.available()]; | ||
| 636 | + fis.read(buffer); | ||
| 637 | + fis.close(); | ||
| 638 | + response.reset(); | ||
| 639 | + response.addHeader("Content-Disposition", "attachment;filename=" + new String(fileName.replaceAll(" ", "").getBytes("utf-8"),"iso8859-1")); | ||
| 640 | + response.addHeader("Content-Length", "" + file.length()); | ||
| 641 | + OutputStream os = new BufferedOutputStream(response.getOutputStream()); | ||
| 642 | + response.setContentType("application/octet-stream"); | ||
| 643 | + os.write(buffer);// 输出文件 | ||
| 644 | + os.flush(); | ||
| 645 | + os.close(); | ||
| 646 | + } | ||
| 647 | + } | ||
| 648 | + | ||
| 649 | + @Override | ||
| 650 | + public List<Jdl> queryJdlByJdlReception(String rq, String nbbm) { | ||
| 651 | + List<Jdl> list = new ArrayList<Jdl>(); | ||
| 652 | + SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); | ||
| 653 | + List<JdlReception> query = jdlReceptionRepository.query(rq, nbbm); | ||
| 654 | + for(JdlReception jr : query){ | ||
| 655 | + try { | ||
| 656 | + Jdl jdl = new Jdl(); | ||
| 657 | + jdl.setFgsBm("-1"); | ||
| 658 | + jdl.setRq(sdf.parse(jr.getDateStr())); | ||
| 659 | + jdl.setJdl(jr.getChargeCapacity()); | ||
| 660 | + jdl.setNbbm(jr.getCarCode()); | ||
| 661 | + list.add(jdl); | ||
| 662 | + } catch (Exception e) { | ||
| 663 | + // TODO Auto-generated catch block | ||
| 664 | + e.printStackTrace(); | ||
| 665 | + } | ||
| 666 | + } | ||
| 667 | + return list; | ||
| 668 | + } | ||
| 669 | + | ||
| 670 | + | ||
| 671 | + @Override | ||
| 672 | + public List<JdlConnector> queryJdlConnector(Map<String, Object> map) { | ||
| 673 | + String connectorName = "", connectorId = "", stationName = ""; | ||
| 674 | + if(map.containsKey("connectorName")){ | ||
| 675 | + connectorName = map.get("connectorName").toString(); | ||
| 676 | + } | ||
| 677 | + if(map.containsKey("connectorId")){ | ||
| 678 | + connectorId = map.get("connectorId").toString(); | ||
| 679 | + } | ||
| 680 | + if(map.containsKey("stationName")){ | ||
| 681 | + stationName = map.get("stationName").toString(); | ||
| 682 | + } | ||
| 683 | + return jdlConnectorRepository.query(connectorName, connectorId, stationName); | ||
| 684 | + } | ||
| 685 | + | ||
| 686 | + @Override | ||
| 687 | + public JdlConnector queryJdlConnectorById(Integer id) { | ||
| 688 | + return jdlConnectorRepository.queryById(id); | ||
| 689 | + } | ||
| 690 | + | ||
| 691 | + @Override | ||
| 692 | + public List<String> queryJdlStationName() { | ||
| 693 | + List<String> queryStationName = jdlConnectorRepository.queryStationName(); | ||
| 694 | + return queryStationName; | ||
| 695 | + } | ||
| 696 | + | ||
| 697 | + @Override | ||
| 698 | + public Map<String, Object> addJdlConnector(Map<String, Object> map) { | ||
| 699 | + Map<String, Object> resMap = new HashMap<>(); | ||
| 700 | + try { | ||
| 701 | + JdlConnector jdlConnector = new JdlConnector(); | ||
| 702 | + if(map.containsKey("connectorName")){ | ||
| 703 | + jdlConnector.setConnectorName(map.get("connectorName").toString()); | ||
| 704 | + } | ||
| 705 | + if(map.containsKey("connectorId")){ | ||
| 706 | + jdlConnector.setConnectorId(map.get("connectorId").toString()); | ||
| 707 | + } | ||
| 708 | + if(map.containsKey("stationName")){ | ||
| 709 | + jdlConnector.setStationName(map.get("stationName").toString()); | ||
| 710 | + } | ||
| 711 | + jdlConnectorRepository.save(jdlConnector); | ||
| 712 | + resMap.put("status", ResponseCode.SUCCESS); | ||
| 713 | + } catch (Exception e) { | ||
| 714 | + // TODO: handle exception | ||
| 715 | + e.printStackTrace(); | ||
| 716 | + resMap.put("status", ResponseCode.ERROR); | ||
| 717 | + resMap.put("msg", "新建失败,可能缺少关键字段"); | ||
| 718 | + } | ||
| 719 | + return resMap; | ||
| 720 | + } | ||
| 721 | + | ||
| 722 | + @Override | ||
| 723 | + public Map<String, Object> deleteJdlConnector(Map<String, Object> map) { | ||
| 724 | + Map<String, Object> resMap = new HashMap<>(); | ||
| 725 | + try { | ||
| 726 | + Integer id = Integer.valueOf(map.get("id").toString()); | ||
| 727 | + jdlConnectorRepository.delete(id); | ||
| 728 | + resMap.put("status", ResponseCode.SUCCESS); | ||
| 729 | + } catch (Exception e) { | ||
| 730 | + // TODO: handle exception | ||
| 731 | + e.printStackTrace(); | ||
| 732 | + resMap.put("status", ResponseCode.ERROR); | ||
| 733 | + resMap.put("msg", "删除失败,可能缺少关键字段"); | ||
| 734 | + } | ||
| 735 | + return resMap; | ||
| 736 | + } | ||
| 737 | + | ||
| 738 | + @Override | ||
| 739 | + public Map<String, Object> updateJdlConnector(Map<String, Object> map) { | ||
| 740 | + Map<String, Object> resMap = new HashMap<>(); | ||
| 741 | + try { | ||
| 742 | + Integer id = Integer.valueOf(map.get("id").toString()); | ||
| 743 | + JdlConnector jdlConnector = jdlConnectorRepository.queryById(id); | ||
| 744 | + if(map.containsKey("connectorName")){ | ||
| 745 | + jdlConnector.setConnectorName(map.get("connectorName").toString()); | ||
| 746 | + } | ||
| 747 | + if(map.containsKey("connectorId")){ | ||
| 748 | + jdlConnector.setConnectorId(map.get("connectorId").toString()); | ||
| 749 | + } | ||
| 750 | + if(map.containsKey("stationName")){ | ||
| 751 | + jdlConnector.setStationName(map.get("stationName").toString()); | ||
| 752 | + } | ||
| 753 | + jdlConnectorRepository.update(id, jdlConnector.getConnectorName(), jdlConnector.getConnectorId(), jdlConnector.getStationName()); | ||
| 754 | + resMap.put("status", ResponseCode.SUCCESS); | ||
| 755 | + } catch (Exception e) { | ||
| 756 | + // TODO: handle exception | ||
| 757 | + e.printStackTrace(); | ||
| 758 | + resMap.put("status", ResponseCode.ERROR); | ||
| 759 | + resMap.put("msg", "修改失败,可能缺少关键字段"); | ||
| 760 | + } | ||
| 761 | + return resMap; | ||
| 762 | + } | ||
| 159 | 763 | ||
| 160 | } | 764 | } |
src/main/java/com/bsth/service/oil/impl/QlbServiceImpl.java
| @@ -90,8 +90,8 @@ public class QlbServiceImpl extends BaseServiceImpl<Qlb,Integer> implements QlbS | @@ -90,8 +90,8 @@ public class QlbServiceImpl extends BaseServiceImpl<Qlb,Integer> implements QlbS | ||
| 90 | String rq=sdf.format(dBefore); | 90 | String rq=sdf.format(dBefore); |
| 91 | // String rq="2017-11-02"; | 91 | // String rq="2017-11-02"; |
| 92 | String line=""; | 92 | String line=""; |
| 93 | - //保留两位小数 | ||
| 94 | - DecimalFormat df = new DecimalFormat("#.00"); | 93 | + //公里保留三位小数 |
| 94 | + DecimalFormat df = new DecimalFormat("#.000"); | ||
| 95 | // TODO Auto-generated method stub | 95 | // TODO Auto-generated method stub |
| 96 | Map<String, Object> newMap=new HashMap<String,Object>(); | 96 | Map<String, Object> newMap=new HashMap<String,Object>(); |
| 97 | //当天QLB信息 | 97 | //当天QLB信息 |
| @@ -228,8 +228,8 @@ public class QlbServiceImpl extends BaseServiceImpl<Qlb,Integer> implements QlbS | @@ -228,8 +228,8 @@ public class QlbServiceImpl extends BaseServiceImpl<Qlb,Integer> implements QlbS | ||
| 228 | nbbm=map2.get("nbbm_eq").toString(); | 228 | nbbm=map2.get("nbbm_eq").toString(); |
| 229 | } | 229 | } |
| 230 | SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); | 230 | SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); |
| 231 | - // 保留两位小数 | ||
| 232 | - DecimalFormat df = new DecimalFormat("#.00"); | 231 | + // 加注量与能耗保留两位小数 |
| 232 | + DecimalFormat df = new DecimalFormat("0.##"); | ||
| 233 | // TODO Auto-generated method stub | 233 | // TODO Auto-generated method stub |
| 234 | // 当天QLB信息 | 234 | // 当天QLB信息 |
| 235 | List<Qlb> qlList = this.listOrderBy(rq,gsbm,fgsbm,"",nbbm,"nbbm"); | 235 | List<Qlb> qlList = this.listOrderBy(rq,gsbm,fgsbm,"",nbbm,"nbbm"); |
| @@ -1019,8 +1019,8 @@ public class QlbServiceImpl extends BaseServiceImpl<Qlb,Integer> implements QlbS | @@ -1019,8 +1019,8 @@ public class QlbServiceImpl extends BaseServiceImpl<Qlb,Integer> implements QlbS | ||
| 1019 | // TODO Auto-generated method stub | 1019 | // TODO Auto-generated method stub |
| 1020 | Map<String, List<Qlb>> mapList=new HashMap<String,List<Qlb>>(); | 1020 | Map<String, List<Qlb>> mapList=new HashMap<String,List<Qlb>>(); |
| 1021 | SimpleDateFormat sdf=new SimpleDateFormat("yyyy-MM-dd"); | 1021 | SimpleDateFormat sdf=new SimpleDateFormat("yyyy-MM-dd"); |
| 1022 | - // 保留两位小数 | ||
| 1023 | - DecimalFormat df = new DecimalFormat("#.00"); | 1022 | + // 加注量与能耗保留两位小数 |
| 1023 | + DecimalFormat df = new DecimalFormat("0.##"); | ||
| 1024 | List<Qlb> qlbList=this.listOrderBy(date,gsdm,fgsdm,"","","nbbm"); | 1024 | List<Qlb> qlbList=this.listOrderBy(date,gsdm,fgsdm,"","","nbbm"); |
| 1025 | List<Qlb> qlbList_upd=new ArrayList<Qlb>(); | 1025 | List<Qlb> qlbList_upd=new ArrayList<Qlb>(); |
| 1026 | List<Qlb> qlbList_del=new ArrayList<Qlb>(); | 1026 | List<Qlb> qlbList_del=new ArrayList<Qlb>(); |
src/main/java/com/bsth/service/oil/impl/YlbServiceImpl.java
| @@ -119,8 +119,6 @@ public class YlbServiceImpl extends BaseServiceImpl<Ylb,Integer> implements YlbS | @@ -119,8 +119,6 @@ public class YlbServiceImpl extends BaseServiceImpl<Ylb,Integer> implements YlbS | ||
| 119 | calendar.add(Calendar.DAY_OF_MONTH, -1); //设置为前一天 | 119 | calendar.add(Calendar.DAY_OF_MONTH, -1); //设置为前一天 |
| 120 | dBefore = calendar.getTime(); //得到前一天的时间 | 120 | dBefore = calendar.getTime(); //得到前一天的时间 |
| 121 | String rq=sdf.format(dBefore); | 121 | String rq=sdf.format(dBefore); |
| 122 | - //保留两位小数 | ||
| 123 | - DecimalFormat df = new DecimalFormat("#.00"); | ||
| 124 | // TODO Auto-generated method stub | 122 | // TODO Auto-generated method stub |
| 125 | Map<String, Object> newMap=new HashMap<String,Object>(); | 123 | Map<String, Object> newMap=new HashMap<String,Object>(); |
| 126 | //当天YLB信息 | 124 | //当天YLB信息 |
| @@ -269,8 +267,6 @@ public class YlbServiceImpl extends BaseServiceImpl<Ylb,Integer> implements YlbS | @@ -269,8 +267,6 @@ public class YlbServiceImpl extends BaseServiceImpl<Ylb,Integer> implements YlbS | ||
| 269 | nbbm=map2.get("nbbm_eq").toString(); | 267 | nbbm=map2.get("nbbm_eq").toString(); |
| 270 | } | 268 | } |
| 271 | SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); | 269 | SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); |
| 272 | - // 保留两位小数 | ||
| 273 | - DecimalFormat df = new DecimalFormat("#.00"); | ||
| 274 | // TODO Auto-generated method stub | 270 | // TODO Auto-generated method stub |
| 275 | // 当天YLB信息 | 271 | // 当天YLB信息 |
| 276 | List<Ylb> ylList = this.listOrderBy(rq,gsbm,fgsbm,"",nbbm,"nbbm"); | 272 | List<Ylb> ylList = this.listOrderBy(rq,gsbm,fgsbm,"",nbbm,"nbbm"); |
| @@ -667,8 +663,8 @@ public class YlbServiceImpl extends BaseServiceImpl<Ylb,Integer> implements YlbS | @@ -667,8 +663,8 @@ public class YlbServiceImpl extends BaseServiceImpl<Ylb,Integer> implements YlbS | ||
| 667 | zsh = Arith.add(zsh, Double.valueOf(sumList.get(j)[2].toString())); | 663 | zsh = Arith.add(zsh, Double.valueOf(sumList.get(j)[2].toString())); |
| 668 | } | 664 | } |
| 669 | // jzl = Arith.sub(jzl, zsh); | 665 | // jzl = Arith.sub(jzl, zsh); |
| 670 | - // 保留两位小数 | ||
| 671 | - DecimalFormat df = new DecimalFormat("#.00"); | 666 | + // 加注量与能耗保留两位小数 |
| 667 | + DecimalFormat df = new DecimalFormat("0.##"); | ||
| 672 | Double zyl = 0.0; | 668 | Double zyl = 0.0; |
| 673 | Double nextJzyl = 0.0; | 669 | Double nextJzyl = 0.0; |
| 674 | // 保存已经计算过的车辆,相同车辆编号的车不在计算 | 670 | // 保存已经计算过的车辆,相同车辆编号的车不在计算 |
| @@ -1481,7 +1477,8 @@ public class YlbServiceImpl extends BaseServiceImpl<Ylb,Integer> implements YlbS | @@ -1481,7 +1477,8 @@ public class YlbServiceImpl extends BaseServiceImpl<Ylb,Integer> implements YlbS | ||
| 1481 | 1477 | ||
| 1482 | // repository.obtainYl(sdf.format(rq_eq),ylb.getSsgsdm(),ylb.getFgsdm(),"", | 1478 | // repository.obtainYl(sdf.format(rq_eq),ylb.getSsgsdm(),ylb.getFgsdm(),"", |
| 1483 | // ylb.getNbbm(),"jcsx"); | 1479 | // ylb.getNbbm(),"jcsx"); |
| 1484 | - DecimalFormat df = new DecimalFormat("#.00"); | 1480 | + // 加注量与能耗保留两位小数 |
| 1481 | + DecimalFormat df = new DecimalFormat("0.##"); | ||
| 1485 | Double zyl = 0.0; | 1482 | Double zyl = 0.0; |
| 1486 | Double nextJzyl = 0.0; | 1483 | Double nextJzyl = 0.0; |
| 1487 | // 车的,进,出油量及耗油 | 1484 | // 车的,进,出油量及耗油 |
| @@ -1983,8 +1980,8 @@ public class YlbServiceImpl extends BaseServiceImpl<Ylb,Integer> implements YlbS | @@ -1983,8 +1980,8 @@ public class YlbServiceImpl extends BaseServiceImpl<Ylb,Integer> implements YlbS | ||
| 1983 | jzl = Arith.add(jzl, Double.valueOf(sumList.get(j)[0].toString())); | 1980 | jzl = Arith.add(jzl, Double.valueOf(sumList.get(j)[0].toString())); |
| 1984 | zlc = Arith.add(zlc, Double.valueOf(sumList.get(j)[1].toString())); | 1981 | zlc = Arith.add(zlc, Double.valueOf(sumList.get(j)[1].toString())); |
| 1985 | } | 1982 | } |
| 1986 | - // 保留两位小数 | ||
| 1987 | - DecimalFormat df = new DecimalFormat("#.00"); | 1983 | + // 加注量与能耗保留两位小数 |
| 1984 | + DecimalFormat df = new DecimalFormat("0.##"); | ||
| 1988 | Double zyl = 0.0; | 1985 | Double zyl = 0.0; |
| 1989 | Double nextJzyl = 0.0; | 1986 | Double nextJzyl = 0.0; |
| 1990 | for (int j = 0; j < iterator2.size(); j++) { | 1987 | for (int j = 0; j < iterator2.size(); j++) { |
src/main/java/com/bsth/service/realcontrol/impl/ScheduleRealInfoServiceImpl.java
| 1 | package com.bsth.service.realcontrol.impl; | 1 | package com.bsth.service.realcontrol.impl; |
| 2 | 2 | ||
| 3 | -import java.io.*; | ||
| 4 | -import java.lang.reflect.Field; | ||
| 5 | -import java.math.BigDecimal; | ||
| 6 | -import java.net.HttpURLConnection; | ||
| 7 | -import java.net.MalformedURLException; | ||
| 8 | -import java.net.URL; | ||
| 9 | -import java.sql.ResultSet; | ||
| 10 | -import java.sql.SQLException; | ||
| 11 | -import java.text.DecimalFormat; | ||
| 12 | -import java.text.ParseException; | ||
| 13 | -import java.text.SimpleDateFormat; | ||
| 14 | -import java.time.LocalDate; | ||
| 15 | -import java.util.ArrayList; | ||
| 16 | -import java.util.Calendar; | ||
| 17 | -import java.util.Collection; | ||
| 18 | -import java.util.Collections; | ||
| 19 | -import java.util.Comparator; | ||
| 20 | -import java.util.Date; | ||
| 21 | -import java.util.GregorianCalendar; | ||
| 22 | -import java.util.HashMap; | ||
| 23 | -import java.util.HashSet; | ||
| 24 | -import java.util.Iterator; | ||
| 25 | -import java.util.List; | ||
| 26 | -import java.util.Map; | ||
| 27 | -import java.util.Queue; | ||
| 28 | -import java.util.Set; | ||
| 29 | -import java.util.concurrent.*; | ||
| 30 | -import java.util.regex.Pattern; | ||
| 31 | - | ||
| 32 | -import com.bsth.data.SystemParamCache; | ||
| 33 | -import com.bsth.data.zndd.OutEntrance; | ||
| 34 | -import com.bsth.entity.zndd.LoggerZndd; | ||
| 35 | -import com.bsth.repository.zndd.LoggerZnddRepository; | ||
| 36 | -import org.apache.commons.io.IOUtils; | ||
| 37 | -import org.apache.commons.lang3.StringEscapeUtils; | ||
| 38 | -import org.apache.commons.lang3.StringUtils; | ||
| 39 | -import org.joda.time.format.DateTimeFormat; | ||
| 40 | -import org.joda.time.format.DateTimeFormatter; | ||
| 41 | -import org.slf4j.Logger; | ||
| 42 | -import org.slf4j.LoggerFactory; | ||
| 43 | -import org.springframework.beans.factory.DisposableBean; | ||
| 44 | -import org.springframework.beans.factory.InitializingBean; | ||
| 45 | -import org.springframework.beans.factory.annotation.Autowired; | ||
| 46 | -import org.springframework.jdbc.core.BeanPropertyRowMapper; | ||
| 47 | -import org.springframework.jdbc.core.JdbcTemplate; | ||
| 48 | -import org.springframework.jdbc.core.RowMapper; | ||
| 49 | -import org.springframework.stereotype.Service; | ||
| 50 | -import org.springframework.transaction.annotation.Transactional; | ||
| 51 | - | ||
| 52 | import com.alibaba.fastjson.JSON; | 3 | import com.alibaba.fastjson.JSON; |
| 53 | import com.alibaba.fastjson.JSONArray; | 4 | import com.alibaba.fastjson.JSONArray; |
| 54 | import com.alibaba.fastjson.JSONObject; | 5 | import com.alibaba.fastjson.JSONObject; |
| @@ -60,6 +11,7 @@ import com.bsth.controller.realcontrol.dto.LpData; | @@ -60,6 +11,7 @@ import com.bsth.controller.realcontrol.dto.LpData; | ||
| 60 | import com.bsth.data.BasicData; | 11 | import com.bsth.data.BasicData; |
| 61 | import com.bsth.data.LineConfigData; | 12 | import com.bsth.data.LineConfigData; |
| 62 | import com.bsth.data.Station2ParkBuffer; | 13 | import com.bsth.data.Station2ParkBuffer; |
| 14 | +import com.bsth.data.SystemParamCache; | ||
| 63 | import com.bsth.data.schedule.DayOfSchedule; | 15 | import com.bsth.data.schedule.DayOfSchedule; |
| 64 | import com.bsth.data.schedule.SchAttrCalculator; | 16 | import com.bsth.data.schedule.SchAttrCalculator; |
| 65 | import com.bsth.data.schedule.ScheduleComparator; | 17 | import com.bsth.data.schedule.ScheduleComparator; |
| @@ -70,6 +22,7 @@ import com.bsth.data.schedule.edit_logs.loggers.FcxxwtLogger; | @@ -70,6 +22,7 @@ import com.bsth.data.schedule.edit_logs.loggers.FcxxwtLogger; | ||
| 70 | import com.bsth.data.schedule.edit_logs.service.dto.SchEditInfoDto; | 22 | import com.bsth.data.schedule.edit_logs.service.dto.SchEditInfoDto; |
| 71 | import com.bsth.data.schedule.late_adjust.LateAdjustHandle; | 23 | import com.bsth.data.schedule.late_adjust.LateAdjustHandle; |
| 72 | import com.bsth.data.utils.CustomStringUtils; | 24 | import com.bsth.data.utils.CustomStringUtils; |
| 25 | +import com.bsth.data.zndd.OutEntrance; | ||
| 73 | import com.bsth.entity.CarDevice; | 26 | import com.bsth.entity.CarDevice; |
| 74 | import com.bsth.entity.Cars; | 27 | import com.bsth.entity.Cars; |
| 75 | import com.bsth.entity.Line; | 28 | import com.bsth.entity.Line; |
| @@ -94,6 +47,7 @@ import com.bsth.entity.schedule.SchedulePlanInfo; | @@ -94,6 +47,7 @@ import com.bsth.entity.schedule.SchedulePlanInfo; | ||
| 94 | import com.bsth.entity.sys.Dictionary; | 47 | import com.bsth.entity.sys.Dictionary; |
| 95 | import com.bsth.entity.sys.DutyEmployee; | 48 | import com.bsth.entity.sys.DutyEmployee; |
| 96 | import com.bsth.entity.sys.SysUser; | 49 | import com.bsth.entity.sys.SysUser; |
| 50 | +import com.bsth.entity.zndd.LoggerZndd; | ||
| 97 | import com.bsth.repository.CarDeviceRepository; | 51 | import com.bsth.repository.CarDeviceRepository; |
| 98 | import com.bsth.repository.CarsRepository; | 52 | import com.bsth.repository.CarsRepository; |
| 99 | import com.bsth.repository.LineRepository; | 53 | import com.bsth.repository.LineRepository; |
| @@ -109,6 +63,7 @@ import com.bsth.repository.realcontrol.SvgAttributeRepository; | @@ -109,6 +63,7 @@ import com.bsth.repository.realcontrol.SvgAttributeRepository; | ||
| 109 | import com.bsth.repository.schedule.CarConfigInfoRepository; | 63 | import com.bsth.repository.schedule.CarConfigInfoRepository; |
| 110 | import com.bsth.repository.schedule.EmployeeConfigInfoRepository; | 64 | import com.bsth.repository.schedule.EmployeeConfigInfoRepository; |
| 111 | import com.bsth.repository.schedule.GuideboardInfoRepository; | 65 | import com.bsth.repository.schedule.GuideboardInfoRepository; |
| 66 | +import com.bsth.repository.zndd.LoggerZnddRepository; | ||
| 112 | import com.bsth.security.util.SecurityUtils; | 67 | import com.bsth.security.util.SecurityUtils; |
| 113 | import com.bsth.service.LineService; | 68 | import com.bsth.service.LineService; |
| 114 | import com.bsth.service.SectionRouteService; | 69 | import com.bsth.service.SectionRouteService; |
| @@ -121,15 +76,7 @@ import com.bsth.service.report.ReportService; | @@ -121,15 +76,7 @@ import com.bsth.service.report.ReportService; | ||
| 121 | import com.bsth.service.schedule.SchedulePlanInfoService; | 76 | import com.bsth.service.schedule.SchedulePlanInfoService; |
| 122 | import com.bsth.service.sys.DictionaryService; | 77 | import com.bsth.service.sys.DictionaryService; |
| 123 | import com.bsth.service.sys.DutyEmployeeService; | 78 | import com.bsth.service.sys.DutyEmployeeService; |
| 124 | -import com.bsth.util.Arith; | ||
| 125 | -import com.bsth.util.ComparableChild; | ||
| 126 | -import com.bsth.util.ComparableLp; | ||
| 127 | -import com.bsth.util.ComparableReal; | ||
| 128 | -import com.bsth.util.DateUtils; | ||
| 129 | -import com.bsth.util.ReportRelatedUtils; | ||
| 130 | -import com.bsth.util.ReportUtils; | ||
| 131 | -import com.bsth.util.TimeUtils; | ||
| 132 | -import com.bsth.util.CoordinateConverter; | 79 | +import com.bsth.util.*; |
| 133 | import com.bsth.websocket.handler.SendUtils; | 80 | import com.bsth.websocket.handler.SendUtils; |
| 134 | import com.fasterxml.jackson.databind.ObjectMapper; | 81 | import com.fasterxml.jackson.databind.ObjectMapper; |
| 135 | import com.github.stuxuhai.jpinyin.PinyinException; | 82 | import com.github.stuxuhai.jpinyin.PinyinException; |
| @@ -137,6 +84,40 @@ import com.github.stuxuhai.jpinyin.PinyinFormat; | @@ -137,6 +84,40 @@ import com.github.stuxuhai.jpinyin.PinyinFormat; | ||
| 137 | import com.github.stuxuhai.jpinyin.PinyinHelper; | 84 | import com.github.stuxuhai.jpinyin.PinyinHelper; |
| 138 | import com.google.common.base.Splitter; | 85 | import com.google.common.base.Splitter; |
| 139 | import com.google.common.collect.Lists; | 86 | import com.google.common.collect.Lists; |
| 87 | +import org.apache.commons.io.IOUtils; | ||
| 88 | +import org.apache.commons.lang3.StringEscapeUtils; | ||
| 89 | +import org.apache.commons.lang3.StringUtils; | ||
| 90 | +import org.joda.time.format.DateTimeFormat; | ||
| 91 | +import org.joda.time.format.DateTimeFormatter; | ||
| 92 | +import org.slf4j.Logger; | ||
| 93 | +import org.slf4j.LoggerFactory; | ||
| 94 | +import org.springframework.beans.factory.DisposableBean; | ||
| 95 | +import org.springframework.beans.factory.InitializingBean; | ||
| 96 | +import org.springframework.beans.factory.annotation.Autowired; | ||
| 97 | +import org.springframework.jdbc.core.BeanPropertyRowMapper; | ||
| 98 | +import org.springframework.jdbc.core.JdbcTemplate; | ||
| 99 | +import org.springframework.jdbc.core.RowMapper; | ||
| 100 | +import org.springframework.stereotype.Service; | ||
| 101 | +import org.springframework.transaction.annotation.Transactional; | ||
| 102 | + | ||
| 103 | +import java.io.ByteArrayOutputStream; | ||
| 104 | +import java.io.File; | ||
| 105 | +import java.io.IOException; | ||
| 106 | +import java.io.InputStream; | ||
| 107 | +import java.lang.reflect.Field; | ||
| 108 | +import java.math.BigDecimal; | ||
| 109 | +import java.net.HttpURLConnection; | ||
| 110 | +import java.net.MalformedURLException; | ||
| 111 | +import java.net.URL; | ||
| 112 | +import java.sql.ResultSet; | ||
| 113 | +import java.sql.SQLException; | ||
| 114 | +import java.text.DecimalFormat; | ||
| 115 | +import java.text.ParseException; | ||
| 116 | +import java.text.SimpleDateFormat; | ||
| 117 | +import java.time.LocalDate; | ||
| 118 | +import java.util.*; | ||
| 119 | +import java.util.concurrent.*; | ||
| 120 | +import java.util.regex.Pattern; | ||
| 140 | 121 | ||
| 141 | @Service | 122 | @Service |
| 142 | public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInfo, Long> | 123 | public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInfo, Long> |
| @@ -1233,6 +1214,10 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf | @@ -1233,6 +1214,10 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf | ||
| 1233 | s.setJhlc(0.0); | 1214 | s.setJhlc(0.0); |
| 1234 | } | 1215 | } |
| 1235 | 1216 | ||
| 1217 | + if (s.getZdsjActual() == null || s.getZdsjActual().isEmpty()){ | ||
| 1218 | + s.setJhlc(0.0); | ||
| 1219 | + } | ||
| 1220 | + | ||
| 1236 | if (s.isDestroy()) { | 1221 | if (s.isDestroy()) { |
| 1237 | s.setFcsjActual(""); | 1222 | s.setFcsjActual(""); |
| 1238 | s.setZdsjActual(""); | 1223 | s.setZdsjActual(""); |
| @@ -1725,8 +1710,11 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf | @@ -1725,8 +1710,11 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf | ||
| 1725 | try { | 1710 | try { |
| 1726 | ScheduleRealInfo sch = dayOfSchedule.get(id); | 1711 | ScheduleRealInfo sch = dayOfSchedule.get(id); |
| 1727 | if (sch.getFcsjActual() == null) { | 1712 | if (sch.getFcsjActual() == null) { |
| 1728 | - rs.put("status", ResponseCode.ERROR); | ||
| 1729 | - rs.put("msg", "无实发时间,无法撤销!"); | 1713 | + /*rs.put("status", ResponseCode.ERROR); |
| 1714 | + rs.put("msg", "无实发时间,无法撤销!");*/ | ||
| 1715 | + rs.put("status", ResponseCode.SUCCESS); | ||
| 1716 | + ts.add(sch); | ||
| 1717 | + rs.put("ts", ts); | ||
| 1730 | } else { | 1718 | } else { |
| 1731 | //日志记录 | 1719 | //日志记录 |
| 1732 | ScheduleModifyLogger.cxsf(sch); | 1720 | ScheduleModifyLogger.cxsf(sch); |
| @@ -1755,8 +1743,10 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf | @@ -1755,8 +1743,10 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf | ||
| 1755 | try { | 1743 | try { |
| 1756 | ScheduleRealInfo sch = dayOfSchedule.get(id); | 1744 | ScheduleRealInfo sch = dayOfSchedule.get(id); |
| 1757 | if (sch.getFcsjActual() == null) { | 1745 | if (sch.getFcsjActual() == null) { |
| 1758 | - rs.put("status", ResponseCode.ERROR); | ||
| 1759 | - rs.put("msg", "无实发时间,无法撤销!"); | 1746 | + //刷新班次不修改 |
| 1747 | + rs.put("status", ResponseCode.SUCCESS); | ||
| 1748 | + ts.add(sch); | ||
| 1749 | + rs.put("ts", ts); | ||
| 1760 | } else { | 1750 | } else { |
| 1761 | //日志记录 | 1751 | //日志记录 |
| 1762 | ScheduleModifyLogger.cxsf(sch); | 1752 | ScheduleModifyLogger.cxsf(sch); |
| @@ -2483,6 +2473,10 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf | @@ -2483,6 +2473,10 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf | ||
| 2483 | typeMap.put("0x60", "事故报告"); | 2473 | typeMap.put("0x60", "事故报告"); |
| 2484 | typeMap.put("0x11", "扣证纠纷"); | 2474 | typeMap.put("0x11", "扣证纠纷"); |
| 2485 | typeMap.put("0x12", "报警"); | 2475 | typeMap.put("0x12", "报警"); |
| 2476 | + typeMap.put("0x21", "单车有人伤"); | ||
| 2477 | + typeMap.put("0x22", "单车无人伤"); | ||
| 2478 | + typeMap.put("0x23", "双车有人伤"); | ||
| 2479 | + typeMap.put("0x24", "双车无人伤"); | ||
| 2486 | for (Map<String, Object> map1 : listMap) { | 2480 | for (Map<String, Object> map1 : listMap) { |
| 2487 | map1.put("requestText", typeMap.get(map1.get("requestType"))); | 2481 | map1.put("requestText", typeMap.get(map1.get("requestType"))); |
| 2488 | } | 2482 | } |
src/main/java/com/bsth/service/schedule/impl/PeopleCarPlanServiceImpl.java
| @@ -2053,12 +2053,12 @@ public class PeopleCarPlanServiceImpl implements PeopleCarPlanService { | @@ -2053,12 +2053,12 @@ public class PeopleCarPlanServiceImpl implements PeopleCarPlanService { | ||
| 2053 | Map<String,Object> m = new HashMap<String, Object>(); | 2053 | Map<String,Object> m = new HashMap<String, Object>(); |
| 2054 | ReportUtils ee = new ReportUtils(); | 2054 | ReportUtils ee = new ReportUtils(); |
| 2055 | try { | 2055 | try { |
| 2056 | - if(resList.size() > 0) | ||
| 2057 | - listI.add(((List<Map<String, Object>>)resList.get(resList.size() - 1).get("map")).iterator()); | ||
| 2058 | - listI.add(resList.iterator()); | ||
| 2059 | - String path = this.getClass().getResource("/").getPath()+"static/pages/forms/"; | ||
| 2060 | - ee.excelReplace(listI, new Object[] { tempMap }, path+"mould/firstAndLastBus_delay.xls", | ||
| 2061 | - path+"export/" + dateTime + "-" + lineName + "-首末班误点班次.xls"); | 2056 | + if(resList.size() > 0){ |
| 2057 | + listI.add(((List<Map<String, Object>>)tempMap.get("map")).iterator()); | ||
| 2058 | + String path = this.getClass().getResource("/").getPath()+"static/pages/forms/"; | ||
| 2059 | + ee.excelReplace(listI, new Object[] { tempMap }, path+"mould/firstAndLastBus_delay.xls", | ||
| 2060 | + path+"export/" + dateTime + "-" + lineName + "-首末班误点班次.xls"); | ||
| 2061 | + } | ||
| 2062 | } catch (Exception e) { | 2062 | } catch (Exception e) { |
| 2063 | // TODO: handle exception | 2063 | // TODO: handle exception |
| 2064 | e.printStackTrace(); | 2064 | e.printStackTrace(); |
src/main/java/com/bsth/service/zndd/LoggerZnddService.java
| @@ -23,4 +23,6 @@ public interface LoggerZnddService extends BaseService<LoggerZndd, Integer> { | @@ -23,4 +23,6 @@ public interface LoggerZnddService extends BaseService<LoggerZndd, Integer> { | ||
| 23 | String LineUserAll(@RequestParam Integer userId); | 23 | String LineUserAll(@RequestParam Integer userId); |
| 24 | 24 | ||
| 25 | Map<String, Object> schTZSF(String line,String date,String endDate,String changType,String type); | 25 | Map<String, Object> schTZSF(String line,String date,String endDate,String changType,String type); |
| 26 | + | ||
| 27 | + ScheduleRealInfo nextSch(Long id); | ||
| 26 | } | 28 | } |
src/main/java/com/bsth/service/zndd/ZnddLoggerService.java
0 → 100644
src/main/java/com/bsth/service/zndd/ZnddStatusService.java
| @@ -7,4 +7,7 @@ public interface ZnddStatusService extends BaseService<znddStatus, Integer> { | @@ -7,4 +7,7 @@ public interface ZnddStatusService extends BaseService<znddStatus, Integer> { | ||
| 7 | 7 | ||
| 8 | 8 | ||
| 9 | void add(znddStatus zs); | 9 | void add(znddStatus zs); |
| 10 | + | ||
| 11 | + | ||
| 12 | + void update(Integer id,Integer openStatus); | ||
| 10 | } | 13 | } |
src/main/java/com/bsth/service/zndd/impl/LoggerZnddServiceImpl.java
| @@ -135,7 +135,7 @@ public class LoggerZnddServiceImpl extends BaseServiceImpl<LoggerZndd, Integer> | @@ -135,7 +135,7 @@ public class LoggerZnddServiceImpl extends BaseServiceImpl<LoggerZndd, Integer> | ||
| 135 | int ms = mis[i]; | 135 | int ms = mis[i]; |
| 136 | //未发车时 才可改变 | 136 | //未发车时 才可改变 |
| 137 | if (info.getFcsjActual() == null || info.getFcsjActual().equals("")){ | 137 | if (info.getFcsjActual() == null || info.getFcsjActual().equals("")){ |
| 138 | - String dfsj = sdfMonth.format(sdf.parse(info.getScheduleDateStr()+ " " + info.getDfsj()).getTime() + (ms * 60 * 1000)); //延后几分钟 | 138 | + String dfsj = sdfMonth.format(sdf.parse(info.getScheduleDateStr()+ " " + info.getDfsj()).getTime() - (ms * 60 * 1000)); //延后几分钟 |
| 139 | cl.setSchId(info.getId()); | 139 | cl.setSchId(info.getId()); |
| 140 | cl.setOld_dfsj(info.getDfsj()); | 140 | cl.setOld_dfsj(info.getDfsj()); |
| 141 | cl.setNew_dfsj(dfsj); | 141 | cl.setNew_dfsj(dfsj); |
| @@ -154,7 +154,13 @@ public class LoggerZnddServiceImpl extends BaseServiceImpl<LoggerZndd, Integer> | @@ -154,7 +154,13 @@ public class LoggerZnddServiceImpl extends BaseServiceImpl<LoggerZndd, Integer> | ||
| 154 | 154 | ||
| 155 | 155 | ||
| 156 | public ScheduleRealInfo thissch(Integer ids){ | 156 | public ScheduleRealInfo thissch(Integer ids){ |
| 157 | - ScheduleRealInfo sch=dayOfSchedule.get(ids); | 157 | + ScheduleRealInfo sch2=dayOfSchedule.get(ids); |
| 158 | + ScheduleRealInfo sch= null; | ||
| 159 | + try { | ||
| 160 | + sch = sch2.clone(); | ||
| 161 | + } catch (CloneNotSupportedException e) { | ||
| 162 | + e.printStackTrace(); | ||
| 163 | + } | ||
| 158 | Line line = lineService.findByLineCode(sch.getXlBm()); | 164 | Line line = lineService.findByLineCode(sch.getXlBm()); |
| 159 | List<Map<String, Object>> lineList=reportService.lineList(); | 165 | List<Map<String, Object>> lineList=reportService.lineList(); |
| 160 | Set<String> lines = new HashSet<>(); | 166 | Set<String> lines = new HashSet<>(); |
| @@ -163,43 +169,78 @@ public class LoggerZnddServiceImpl extends BaseServiceImpl<LoggerZndd, Integer> | @@ -163,43 +169,78 @@ public class LoggerZnddServiceImpl extends BaseServiceImpl<LoggerZndd, Integer> | ||
| 163 | lines.add(map.get("xlbm").toString()); | 169 | lines.add(map.get("xlbm").toString()); |
| 164 | } | 170 | } |
| 165 | } | 171 | } |
| 166 | - List<String> nbbms=new ArrayList<>(); | ||
| 167 | - List<String> jghs=new ArrayList<>(); | ||
| 168 | - List<String> jNames=new ArrayList<>(); | 172 | + List<Map<String,String>> schs=new ArrayList<>(); |
| 173 | + LocalTime localTime=LocalTime.now().plusHours(1); | ||
| 174 | + LocalTime now=LocalTime.now(); | ||
| 175 | + DateTimeFormatter dtf=DateTimeFormatter.ofPattern("HH:mm"); | ||
| 169 | for (String lineCode : lines) { | 176 | for (String lineCode : lines) { |
| 170 | Set<String> set = dayOfSchedule.findCarByLineCode(lineCode); | 177 | Set<String> set = dayOfSchedule.findCarByLineCode(lineCode); |
| 171 | - LocalTime localTime=LocalTime.now().plusHours(1); | ||
| 172 | - DateTimeFormatter dtf=DateTimeFormatter.ofPattern("HH:mm"); | ||
| 173 | for (String nbbm : set) { | 178 | for (String nbbm : set) { |
| 174 | ScheduleRealInfo s=dayOfSchedule.executeCurr(nbbm);//当前执行班次 | 179 | ScheduleRealInfo s=dayOfSchedule.executeCurr(nbbm);//当前执行班次 |
| 175 | if(s==null){//当日班次执行完毕 | 180 | if(s==null){//当日班次执行完毕 |
| 176 | List<ScheduleRealInfo> list=dayOfSchedule.findByNbbm(nbbm); | 181 | List<ScheduleRealInfo> list=dayOfSchedule.findByNbbm(nbbm); |
| 177 | if(list.size()>0){ | 182 | if(list.size()>0){ |
| 178 | - ScheduleRealInfo s2=list.get(list.size()-1);//最后一个班次 | ||
| 179 | - nbbms.add(s2.getClZbh()); | ||
| 180 | - jghs.add(s2.getjGh()); | ||
| 181 | - jNames.add(s2.getjName()); | 183 | + ScheduleRealInfo s2=list.get(list.size()-1);//最后一个班次\ |
| 184 | + if(s2.getZdsjActual()!=null && LocalTime.parse(s2.getZdsjActual(),dtf).isBefore(now)){ | ||
| 185 | + Map<String,String> schMap = new HashMap<>(); | ||
| 186 | + schMap.put("nbbm",s2.getClZbh()); | ||
| 187 | + schMap.put("jgh",s2.getjGh()); | ||
| 188 | + schMap.put("jName",s2.getjName()); | ||
| 189 | + schMap.put("zdsjActual",s2.getZdsjActual()); | ||
| 190 | + System.out.println(s2.getClZbh()+s2.getZdsjActual()+lineCode); | ||
| 191 | + schs.add(schMap); | ||
| 192 | + } | ||
| 182 | } | 193 | } |
| 183 | }else {//1小时内是否有待执行班次 | 194 | }else {//1小时内是否有待执行班次 |
| 184 | LocalTime fcsj=LocalTime.parse(s.getFcsj(),dtf); | 195 | LocalTime fcsj=LocalTime.parse(s.getFcsj(),dtf); |
| 185 | if(fcsj.isAfter(localTime)){ | 196 | if(fcsj.isAfter(localTime)){ |
| 186 | - nbbms.add(s.getClZbh()); | ||
| 187 | - jghs.add(s.getjGh()); | ||
| 188 | - jNames.add(s.getjName()); | 197 | + //查询上一个班次 |
| 198 | + ScheduleRealInfo s2=dayOfSchedule.prev(s); | ||
| 199 | + if(s.getZdsjActual()!=null && LocalTime.parse(s2.getZdsjActual(),dtf).isBefore(now)){ | ||
| 200 | + Map<String,String> schMap = new HashMap<>(); | ||
| 201 | + schMap.put("nbbm",s2.getClZbh()); | ||
| 202 | + schMap.put("jgh",s2.getjGh()); | ||
| 203 | + schMap.put("jName",s2.getjName()); | ||
| 204 | + schMap.put("zdsjActual",s2.getZdsjActual()); | ||
| 205 | + System.out.println(s2.getClZbh()+s2.getZdsjActual()+lineCode); | ||
| 206 | + schs.add(schMap); | ||
| 207 | + } | ||
| 189 | } | 208 | } |
| 190 | } | 209 | } |
| 191 | } | 210 | } |
| 192 | } | 211 | } |
| 212 | + Collections.sort(schs, new Comparator<Map<String, String>>(){ | ||
| 213 | + public int compare(Map<String, String> o1, Map<String, String> o2) { | ||
| 214 | + String zdsjActual1 = o1.get("zdsjActual"); | ||
| 215 | + String zdsjActual2 = o2.get("zdsjActual"); | ||
| 216 | + return zdsjActual2.compareTo(zdsjActual1); | ||
| 217 | + } | ||
| 218 | + | ||
| 219 | + }); | ||
| 193 | StringBuffer sb=new StringBuffer(); | 220 | StringBuffer sb=new StringBuffer(); |
| 194 | String kscl=""; | 221 | String kscl=""; |
| 195 | - if(nbbms.size()>0){ | ||
| 196 | - sch.setClZbh(nbbms.get(0)); | ||
| 197 | - sch.setjGh(jghs.get(0)); | ||
| 198 | - sch.setjName(jNames.get(0)); | ||
| 199 | - int size =nbbms.size()>10?9:nbbms.size(); | 222 | + List<Map<String, String>> schs2 = new ArrayList<>(); |
| 223 | + | ||
| 224 | + // 创建用于去重的 Set<Map> | ||
| 225 | + Set<Map<String, String>> set = new HashSet<>(); | ||
| 226 | + // 遍历原始的 List<Map> | ||
| 227 | + for (Map<String, String> map : schs) { | ||
| 228 | + // 创建一个新的 Map 用于存储合并去重后的结果 | ||
| 229 | + Map<String, String> newMap = new HashMap<>(map); | ||
| 230 | + // 如果新的 Map 成功添加到 Set 中,说明是一个新的 Map,将其添加到结果 List<Map> 中 | ||
| 231 | + if (set.add(newMap)) { | ||
| 232 | + schs2.add(newMap); | ||
| 233 | + } | ||
| 234 | + } | ||
| 235 | + if(schs2.size()>0){ | ||
| 236 | + sch.setClZbh(schs2.get(0).get("nbbm")); | ||
| 237 | + sch.setjGh(schs2.get(0).get("jgh")); | ||
| 238 | + sch.setjName(schs2.get(0).get("jName")); | ||
| 239 | + int size =schs2.size()>8?8:schs2.size(); | ||
| 200 | for (int i = 0; i < size; i++) { | 240 | for (int i = 0; i < size; i++) { |
| 201 | - sb.append(nbbms.get(i)+"/"); | ||
| 202 | - sb.append(jNames.get(i)+","); | 241 | + sb.append(schs2.get(i).get("nbbm")+"/"); |
| 242 | + sb.append(schs2.get(i).get("jName")+"/"); | ||
| 243 | + sb.append(schs2.get(i).get("zdsjActual")+","); | ||
| 203 | } | 244 | } |
| 204 | kscl=sb.toString().substring(0,sb.length()-1); | 245 | kscl=sb.toString().substring(0,sb.length()-1); |
| 205 | } | 246 | } |
| @@ -297,4 +338,9 @@ public class LoggerZnddServiceImpl extends BaseServiceImpl<LoggerZndd, Integer> | @@ -297,4 +338,9 @@ public class LoggerZnddServiceImpl extends BaseServiceImpl<LoggerZndd, Integer> | ||
| 297 | } | 338 | } |
| 298 | return rs; | 339 | return rs; |
| 299 | } | 340 | } |
| 341 | + | ||
| 342 | + | ||
| 343 | + public ScheduleRealInfo nextSch(Long id){ | ||
| 344 | + return dayOfSchedule.next(dayOfSchedule.get(id)); | ||
| 345 | + } | ||
| 300 | } | 346 | } |
src/main/java/com/bsth/service/zndd/impl/ZnddLoggerServiceImpl.java
0 → 100644
| 1 | +package com.bsth.service.zndd.impl; | ||
| 2 | + | ||
| 3 | +import com.bsth.entity.zndd.StationPeopleLogger; | ||
| 4 | +import com.bsth.service.impl.BaseServiceImpl; | ||
| 5 | +import com.bsth.service.zndd.ZnddLoggerService; | ||
| 6 | +import org.springframework.stereotype.Service; | ||
| 7 | + | ||
| 8 | +@Service | ||
| 9 | +public class ZnddLoggerServiceImpl extends BaseServiceImpl<StationPeopleLogger, Integer> implements ZnddLoggerService { | ||
| 10 | +} |
src/main/java/com/bsth/service/zndd/impl/ZnddStatusServiceImpl.java
| @@ -17,4 +17,8 @@ public class ZnddStatusServiceImpl extends BaseServiceImpl<znddStatus, Integer> | @@ -17,4 +17,8 @@ public class ZnddStatusServiceImpl extends BaseServiceImpl<znddStatus, Integer> | ||
| 17 | public void add(znddStatus zs){ | 17 | public void add(znddStatus zs){ |
| 18 | znddStatusRepository.save(zs); | 18 | znddStatusRepository.save(zs); |
| 19 | } | 19 | } |
| 20 | + | ||
| 21 | + public void update(Integer id,Integer openStatus){ | ||
| 22 | + znddStatusRepository.update(id,openStatus); | ||
| 23 | + } | ||
| 20 | } | 24 | } |
src/main/resources/application-prod.properties
| 1 | -server.port=9088 | ||
| 2 | - | ||
| 3 | -# dubbo\uFFFD\uFFFD\uFFFD\uFFFD\u02B9\uFFFD\u00FF\uFFFD\uFFFD\uFFFDflag | ||
| 4 | -dubbo.use=false | ||
| 5 | - | ||
| 6 | -#JPA | ||
| 7 | -spring.jpa.hibernate.ddl-auto= none | ||
| 8 | -spring.jpa.hibernate.naming.implicit-strategy=org.hibernate.boot.model.naming.ImplicitNamingStrategyLegacyHbmImpl | ||
| 9 | -spring.jpa.hibernate.naming.physical-strategy=org.springframework.boot.orm.jpa.hibernate.SpringPhysicalNamingStrategy | ||
| 10 | -spring.jpa.database= MYSQL | ||
| 11 | -spring.jpa.properties.hibernate.enable_lazy_load_no_trans=true | ||
| 12 | -spring.jpa.show-sql= false | ||
| 13 | -spring.jpa.properties.hibernate.dialect= org.hibernate.spatial.dialect.mysql.MySQL56InnoDBSpatialDialect | ||
| 14 | - | ||
| 15 | -#DATABASE | ||
| 16 | -spring.datasource.driver-class-name= com.mysql.jdbc.Driver | ||
| 17 | -spring.datasource.url= jdbc:mysql://10.10.150.103:3306/control?useUnicode=true&characterEncoding=utf-8&useSSL=false&serverTimezone=Asia/Shanghai | ||
| 18 | -spring.datasource.username= root | ||
| 19 | -spring.datasource.password= fsodlgjiuigAQF2$9fs9 | ||
| 20 | -spring.datasource.type= com.zaxxer.hikari.HikariDataSource | ||
| 21 | - | ||
| 22 | -#DATASOURCE SETTING | ||
| 23 | -spring.datasource.hikari.minimum-idle= 8 | ||
| 24 | -spring.datasource.hikari.maximum-pool-size= 100 | ||
| 25 | -#spring.datasource.hikari.auto-commit= true | ||
| 26 | -spring.datasource.hikari.idle-timeout= 60000 | ||
| 27 | -#spring.datasource.hikari.pool-name= HikariPool | ||
| 28 | -spring.datasource.hikari.max-lifetime= 1800000 | ||
| 29 | -spring.datasource.hikari.connection-timeout= 3000 | ||
| 30 | -spring.datasource.hikari.connection-test-query= SELECT 1 | ||
| 31 | -spring.datasource.hikari.validation-timeout= 3000 | ||
| 32 | -spring.datasource.hikari.register-mbeans=true | ||
| 33 | - | ||
| 34 | -sso.enabled= true | ||
| 35 | -sso.systemcode = SYSUS023 | ||
| 36 | -sso.http.url.login= http://10.10.200.142:9112/login?redirect=%2Findex | ||
| 37 | -sso.http.url.logout= http://10.10.200.142:9112/login?redirect=%2Findex | ||
| 38 | -sso.http.url.auth= http://10.10.200.142:9112/prod-api/system/utilitySystem/checkToken | ||
| 39 | - | ||
| 40 | -dc.imgurl= /home/control/klimg | ||
| 41 | -dc.profile= profile | 1 | +server.port=9088 |
| 2 | + | ||
| 3 | +# dubbo\uFFFD\uFFFD\uFFFD\uFFFD\u02B9\uFFFD\u00FF\uFFFD\uFFFD\uFFFDflag | ||
| 4 | +dubbo.use=false | ||
| 5 | + | ||
| 6 | +#JPA | ||
| 7 | +spring.jpa.hibernate.ddl-auto= none | ||
| 8 | +spring.jpa.hibernate.naming.implicit-strategy=org.hibernate.boot.model.naming.ImplicitNamingStrategyLegacyHbmImpl | ||
| 9 | +spring.jpa.hibernate.naming.physical-strategy=org.springframework.boot.orm.jpa.hibernate.SpringPhysicalNamingStrategy | ||
| 10 | +spring.jpa.database= MYSQL | ||
| 11 | +spring.jpa.properties.hibernate.enable_lazy_load_no_trans=true | ||
| 12 | +spring.jpa.show-sql= false | ||
| 13 | +spring.jpa.properties.hibernate.dialect= org.hibernate.spatial.dialect.mysql.MySQL56InnoDBSpatialDialect | ||
| 14 | + | ||
| 15 | +#DATABASE | ||
| 16 | +spring.datasource.driver-class-name= com.mysql.jdbc.Driver | ||
| 17 | +spring.datasource.url= jdbc:mysql://10.10.150.103:3306/control?useUnicode=true&characterEncoding=utf-8&useSSL=false&serverTimezone=Asia/Shanghai | ||
| 18 | +spring.datasource.username= root | ||
| 19 | +spring.datasource.password= fsodlgjiuigAQF2$9fs9 | ||
| 20 | +spring.datasource.type= com.zaxxer.hikari.HikariDataSource | ||
| 21 | + | ||
| 22 | +#DATASOURCE SETTING | ||
| 23 | +spring.datasource.hikari.minimum-idle= 8 | ||
| 24 | +spring.datasource.hikari.maximum-pool-size= 100 | ||
| 25 | +#spring.datasource.hikari.auto-commit= true | ||
| 26 | +spring.datasource.hikari.idle-timeout= 60000 | ||
| 27 | +#spring.datasource.hikari.pool-name= HikariPool | ||
| 28 | +spring.datasource.hikari.max-lifetime= 1800000 | ||
| 29 | +spring.datasource.hikari.connection-timeout= 3000 | ||
| 30 | +spring.datasource.hikari.connection-test-query= SELECT 1 | ||
| 31 | +spring.datasource.hikari.validation-timeout= 3000 | ||
| 32 | +spring.datasource.hikari.register-mbeans=true | ||
| 33 | + | ||
| 34 | +sso.enabled= true | ||
| 35 | +sso.systemcode = SYSUS023 | ||
| 36 | +sso.http.url.login= http://10.10.200.142:9112/login?redirect=%2Findex | ||
| 37 | +sso.http.url.logout= http://10.10.200.142:9112/login?redirect=%2Findex | ||
| 38 | +sso.http.url.auth= http://10.10.200.142:9112/prod-api/system/utilitySystem/checkToken | ||
| 39 | + | ||
| 40 | +dc.imgurl= /home/control/klimg | ||
| 41 | +dc.profile= profile | ||
| 42 | + | ||
| 43 | +baidu.ak=AYiBOs3f9qBQFhdKFsaboX6CfObmKwRP | ||
| 44 | +passengerFlow.url = http://192.168.168.32:9999/images/ | ||
| 45 | + | ||
| 46 | +electricity.importFile.path= /home/control/elecImportFile |
src/main/resources/application-test.properties
| 1 | -server.port=9088 | ||
| 2 | - | ||
| 3 | -# dubbo\uFFFD\uFFFD\uFFFD\uFFFD\u02B9\uFFFD\u00FF\uFFFD\uFFFD\uFFFDflag | ||
| 4 | -dubbo.use=false | ||
| 5 | - | ||
| 6 | -#JPA | ||
| 7 | -spring.jpa.hibernate.ddl-auto= none | ||
| 8 | -spring.jpa.hibernate.naming.implicit-strategy=org.hibernate.boot.model.naming.ImplicitNamingStrategyLegacyHbmImpl | ||
| 9 | -spring.jpa.hibernate.naming.physical-strategy=org.springframework.boot.orm.jpa.hibernate.SpringPhysicalNamingStrategy | ||
| 10 | -spring.jpa.database= MYSQL | ||
| 11 | -spring.jpa.properties.hibernate.enable_lazy_load_no_trans=true | ||
| 12 | -spring.jpa.show-sql= false | ||
| 13 | -spring.jpa.properties.hibernate.dialect= org.hibernate.spatial.dialect.mysql.MySQL56InnoDBSpatialDialect | ||
| 14 | - | ||
| 15 | -#DATABASE | ||
| 16 | -spring.datasource.driver-class-name= com.mysql.cj.jdbc.Driver | ||
| 17 | -spring.datasource.url= jdbc:mysql://10.10.150.101/lg_control?useUnicode=true&characterEncoding=utf-8&useSSL=true&serverTimezone=Asia/Shanghai | ||
| 18 | -spring.datasource.username= root | ||
| 19 | -spring.datasource.password= A123456ab | ||
| 20 | -spring.datasource.type= com.zaxxer.hikari.HikariDataSource | ||
| 21 | - | ||
| 22 | -#DATASOURCE SETTING | ||
| 23 | -spring.datasource.hikari.minimum-idle= 8 | ||
| 24 | -spring.datasource.hikari.maximum-pool-size= 100 | ||
| 25 | -#spring.datasource.hikari.auto-commit= true | ||
| 26 | -spring.datasource.hikari.idle-timeout= 60000 | ||
| 27 | -#spring.datasource.hikari.pool-name= HikariPool | ||
| 28 | -spring.datasource.hikari.max-lifetime= 1800000 | ||
| 29 | -spring.datasource.hikari.connection-timeout= 3000 | ||
| 30 | -spring.datasource.hikari.connection-test-query= SELECT 1 | ||
| 31 | -spring.datasource.hikari.validation-timeout= 3000 | ||
| 32 | -spring.datasource.hikari.register-mbeans=true | ||
| 33 | - | ||
| 34 | -sso.enabled= true | ||
| 35 | -sso.systemcode = SYSUS023 | ||
| 36 | -sso.http.url.login= http://10.10.200.142:9112/login?redirect=%2Findex | ||
| 37 | -sso.http.url.logout= http://10.10.200.142:9112/login?redirect=%2Findex | ||
| 38 | -sso.http.url.auth= http://10.10.200.142:9112/prod-api/system/utilitySystem/checkToken | ||
| 39 | - | ||
| 40 | -dc.imgurl= E:/klimg | ||
| 41 | -dc.profile= profile | ||
| 42 | - | ||
| 43 | -baidu.ak=AYiBOs3f9qBQFhdKFsaboX6CfObmKwRP | ||
| 44 | -passengerFlow.url = http://127.0.0.1:9999/images/ | ||
| 45 | \ No newline at end of file | 1 | \ No newline at end of file |
| 2 | +server.port=9088 | ||
| 3 | + | ||
| 4 | +# dubbo\uFFFD\uFFFD\uFFFD\uFFFD\u02B9\uFFFD\u00FF\uFFFD\uFFFD\uFFFDflag | ||
| 5 | +dubbo.use=false | ||
| 6 | + | ||
| 7 | +#JPA | ||
| 8 | +spring.jpa.hibernate.ddl-auto= none | ||
| 9 | +spring.jpa.hibernate.naming.implicit-strategy=org.hibernate.boot.model.naming.ImplicitNamingStrategyLegacyHbmImpl | ||
| 10 | +spring.jpa.hibernate.naming.physical-strategy=org.springframework.boot.orm.jpa.hibernate.SpringPhysicalNamingStrategy | ||
| 11 | +spring.jpa.database= MYSQL | ||
| 12 | +spring.jpa.properties.hibernate.enable_lazy_load_no_trans=true | ||
| 13 | +spring.jpa.show-sql= false | ||
| 14 | +spring.jpa.properties.hibernate.dialect= org.hibernate.spatial.dialect.mysql.MySQL56InnoDBSpatialDialect | ||
| 15 | + | ||
| 16 | +#DATABASE | ||
| 17 | +spring.datasource.driver-class-name= com.mysql.cj.jdbc.Driver | ||
| 18 | +spring.datasource.url= jdbc:mysql://10.10.150.101/lg_control?useUnicode=true&characterEncoding=utf-8&useSSL=true&serverTimezone=Asia/Shanghai | ||
| 19 | +spring.datasource.username= root | ||
| 20 | +spring.datasource.password= A123456ab | ||
| 21 | +spring.datasource.type= com.zaxxer.hikari.HikariDataSource | ||
| 22 | + | ||
| 23 | +#DATASOURCE SETTING | ||
| 24 | +spring.datasource.hikari.minimum-idle= 8 | ||
| 25 | +spring.datasource.hikari.maximum-pool-size= 100 | ||
| 26 | +#spring.datasource.hikari.auto-commit= true | ||
| 27 | +spring.datasource.hikari.idle-timeout= 60000 | ||
| 28 | +#spring.datasource.hikari.pool-name= HikariPool | ||
| 29 | +spring.datasource.hikari.max-lifetime= 1800000 | ||
| 30 | +spring.datasource.hikari.connection-timeout= 3000 | ||
| 31 | +spring.datasource.hikari.connection-test-query= SELECT 1 | ||
| 32 | +spring.datasource.hikari.validation-timeout= 3000 | ||
| 33 | +spring.datasource.hikari.register-mbeans=true | ||
| 34 | + | ||
| 35 | +sso.enabled= true | ||
| 36 | +sso.systemcode = SYSUS023 | ||
| 37 | +sso.http.url.login= http://10.10.200.142:9112/login?redirect=%2Findex | ||
| 38 | +sso.http.url.logout= http://10.10.200.142:9112/login?redirect=%2Findex | ||
| 39 | +sso.http.url.auth= http://10.10.200.142:9112/prod-api/system/utilitySystem/checkToken | ||
| 40 | + | ||
| 41 | +dc.imgurl= E:/klimg | ||
| 42 | +dc.profile= profile | ||
| 43 | + | ||
| 44 | +baidu.ak=AYiBOs3f9qBQFhdKFsaboX6CfObmKwRP | ||
| 45 | +passengerFlow.url = http://127.0.0.1:9999/images/ | ||
| 46 | + | ||
| 47 | +electricity.importFile.path= E:/elecImportFile |
src/main/resources/fatso/start.js
| @@ -16,7 +16,7 @@ var platform = process.platform; | @@ -16,7 +16,7 @@ var platform = process.platform; | ||
| 16 | var iswin = platform == 'win32'; | 16 | var iswin = platform == 'win32'; |
| 17 | var sp = platform == 'win32' ? '\\' : '/'; | 17 | var sp = platform == 'win32' ? '\\' : '/'; |
| 18 | //不参与的目录 | 18 | //不参与的目录 |
| 19 | -var excludes = ['scheduleApp', 'trafficManage', 'control', 'permission' + sp + 'authorize_all','permission' + sp + 'user', 'summary', 'history_sch', 'report' + sp + 'oil', 'base' + sp + 'geo_data_edit', 'base' + sp + 'carpark', 'forms', 'mforms', 'report', 'punctual', 'base' + sp + 'timesmodel', 'base' + sp + 'stationroute','zndd_yuan','call'] | 19 | +var excludes = ['scheduleApp', 'trafficManage', 'control', 'permission' + sp + 'authorize_all','permission' + sp + 'user', 'summary', 'history_sch', 'report' + sp + 'oil', 'base' + sp + 'geo_data_edit', 'base' + sp + 'carpark', 'forms', 'mforms', 'report', 'punctual', 'base' + sp + 'timesmodel', 'base' + sp + 'stationroute','zndd_yuan','call','base' + sp + 'region',] |
| 20 | , ep = new EventProxy() | 20 | , ep = new EventProxy() |
| 21 | , pName = 'bsth_control' | 21 | , pName = 'bsth_control' |
| 22 | , path = process.cwd() | 22 | , path = process.cwd() |
src/main/resources/static/assets/bower_components/angular-bootstrap/ui-bootstrap-tpls.min.js
| @@ -5,7 +5,7 @@ | @@ -5,7 +5,7 @@ | ||
| 5 | * Version: 0.14.0 - 2015-10-08 | 5 | * Version: 0.14.0 - 2015-10-08 |
| 6 | * License: MIT | 6 | * License: MIT |
| 7 | */ | 7 | */ |
| 8 | -angular.module("ui.bootstrap",["ui.bootstrap.tpls","ui.bootstrap.collapse","ui.bootstrap.accordion","ui.bootstrap.alert","ui.bootstrap.buttons","ui.bootstrap.carousel","ui.bootstrap.dateparser","ui.bootstrap.position","ui.bootstrap.datepicker","ui.bootstrap.dropdown","ui.bootstrap.stackedMap","ui.bootstrap.modal","ui.bootstrap.pagination","ui.bootstrap.tooltip","ui.bootstrap.popover","ui.bootstrap.progressbar","ui.bootstrap.rating","ui.bootstrap.tabs","ui.bootstrap.timepicker","ui.bootstrap.typeahead"]),angular.module("ui.bootstrap.tpls",["template/accordion/accordion-group.html","template/accordion/accordion.html","template/alert/alert.html","template/carousel/carousel.html","template/carousel/slide.html","template/datepicker/datepicker.html","template/datepicker/day.html","template/datepicker/month.html","template/datepicker/popup.html","template/datepicker/year.html","template/modal/backdrop.html","template/modal/window.html","template/pagination/pager.html","template/pagination/pagination.html","template/tooltip/tooltip-html-popup.html","template/tooltip/tooltip-popup.html","template/tooltip/tooltip-template-popup.html","template/popover/popover-html.html","template/popover/popover-template.html","template/popover/popover.html","template/progressbar/bar.html","template/progressbar/progress.html","template/progressbar/progressbar.html","template/rating/rating.html","template/tabs/tab.html","template/tabs/tabset.html","template/timepicker/timepicker.html","template/typeahead/typeahead-match.html","template/typeahead/typeahead-popup.html"]),angular.module("ui.bootstrap.collapse",[]).directive("uibCollapse",["$animate","$injector",function(a,b){var c=b.has("$animateCss")?b.get("$animateCss"):null;return{link:function(b,d,e){function f(){d.removeClass("collapse").addClass("collapsing").attr("aria-expanded",!0).attr("aria-hidden",!1),c?c(d,{addClass:"in",easing:"ease",to:{height:d[0].scrollHeight+"px"}}).start().done(g):a.addClass(d,"in",{to:{height:d[0].scrollHeight+"px"}}).then(g)}function g(){d.removeClass("collapsing").addClass("collapse").css({height:"auto"})}function h(){return d.hasClass("collapse")||d.hasClass("in")?(d.css({height:d[0].scrollHeight+"px"}).removeClass("collapse").addClass("collapsing").attr("aria-expanded",!1).attr("aria-hidden",!0),void(c?c(d,{removeClass:"in",to:{height:"0"}}).start().done(i):a.removeClass(d,"in",{to:{height:"0"}}).then(i))):i()}function i(){d.css({height:"0"}),d.removeClass("collapsing").addClass("collapse")}b.$watch(e.uibCollapse,function(a){a?h():f()})}}}]),angular.module("ui.bootstrap.collapse").value("$collapseSuppressWarning",!1).directive("collapse",["$animate","$injector","$log","$collapseSuppressWarning",function(a,b,c,d){var e=b.has("$animateCss")?b.get("$animateCss"):null;return{link:function(b,f,g){function h(){f.removeClass("collapse").addClass("collapsing").attr("aria-expanded",!0).attr("aria-hidden",!1),e?e(f,{addClass:"in",easing:"ease",to:{height:f[0].scrollHeight+"px"}}).start().done(i):a.addClass(f,"in",{to:{height:f[0].scrollHeight+"px"}}).then(i)}function i(){f.removeClass("collapsing").addClass("collapse").css({height:"auto"})}function j(){return f.hasClass("collapse")||f.hasClass("in")?(f.css({height:f[0].scrollHeight+"px"}).removeClass("collapse").addClass("collapsing").attr("aria-expanded",!1).attr("aria-hidden",!0),void(e?e(f,{removeClass:"in",to:{height:"0"}}).start().done(k):a.removeClass(f,"in",{to:{height:"0"}}).then(k))):k()}function k(){f.css({height:"0"}),f.removeClass("collapsing").addClass("collapse")}d||c.warn("collapse is now deprecated. Use uib-collapse instead."),b.$watch(g.collapse,function(a){a?j():h()})}}}]),angular.module("ui.bootstrap.accordion",["ui.bootstrap.collapse"]).constant("uibAccordionConfig",{closeOthers:!0}).controller("UibAccordionController",["$scope","$attrs","uibAccordionConfig",function(a,b,c){this.groups=[],this.closeOthers=function(d){var e=angular.isDefined(b.closeOthers)?a.$eval(b.closeOthers):c.closeOthers;e&&angular.forEach(this.groups,function(a){a!==d&&(a.isOpen=!1)})},this.addGroup=function(a){var b=this;this.groups.push(a),a.$on("$destroy",function(c){b.removeGroup(a)})},this.removeGroup=function(a){var b=this.groups.indexOf(a);-1!==b&&this.groups.splice(b,1)}}]).directive("uibAccordion",function(){return{controller:"UibAccordionController",controllerAs:"accordion",transclude:!0,templateUrl:function(a,b){return b.templateUrl||"template/accordion/accordion.html"}}}).directive("uibAccordionGroup",function(){return{require:"^uibAccordion",transclude:!0,replace:!0,templateUrl:function(a,b){return b.templateUrl||"template/accordion/accordion-group.html"},scope:{heading:"@",isOpen:"=?",isDisabled:"=?"},controller:function(){this.setHeading=function(a){this.heading=a}},link:function(a,b,c,d){d.addGroup(a),a.openClass=c.openClass||"panel-open",a.panelClass=c.panelClass,a.$watch("isOpen",function(c){b.toggleClass(a.openClass,!!c),c&&d.closeOthers(a)}),a.toggleOpen=function(b){a.isDisabled||b&&32!==b.which||(a.isOpen=!a.isOpen)}}}}).directive("uibAccordionHeading",function(){return{transclude:!0,template:"",replace:!0,require:"^uibAccordionGroup",link:function(a,b,c,d,e){d.setHeading(e(a,angular.noop))}}}).directive("uibAccordionTransclude",function(){return{require:["?^uibAccordionGroup","?^accordionGroup"],link:function(a,b,c,d){d=d[0]?d[0]:d[1],a.$watch(function(){return d[c.uibAccordionTransclude]},function(a){a&&(b.find("span").html(""),b.find("span").append(a))})}}}),angular.module("ui.bootstrap.accordion").value("$accordionSuppressWarning",!1).controller("AccordionController",["$scope","$attrs","$controller","$log","$accordionSuppressWarning",function(a,b,c,d,e){return e||d.warn("AccordionController is now deprecated. Use UibAccordionController instead."),c("UibAccordionController",{$scope:a,$attrs:b})}]).directive("accordion",["$log","$accordionSuppressWarning",function(a,b){return{restrict:"EA",controller:"AccordionController",controllerAs:"accordion",transclude:!0,replace:!1,templateUrl:function(a,b){return b.templateUrl||"template/accordion/accordion.html"},link:function(){b||a.warn("accordion is now deprecated. Use uib-accordion instead.")}}}]).directive("accordionGroup",["$log","$accordionSuppressWarning",function(a,b){return{require:"^accordion",restrict:"EA",transclude:!0,replace:!0,templateUrl:function(a,b){return b.templateUrl||"template/accordion/accordion-group.html"},scope:{heading:"@",isOpen:"=?",isDisabled:"=?"},controller:function(){this.setHeading=function(a){this.heading=a}},link:function(c,d,e,f){b||a.warn("accordion-group is now deprecated. Use uib-accordion-group instead."),f.addGroup(c),c.openClass=e.openClass||"panel-open",c.panelClass=e.panelClass,c.$watch("isOpen",function(a){d.toggleClass(c.openClass,!!a),a&&f.closeOthers(c)}),c.toggleOpen=function(a){c.isDisabled||a&&32!==a.which||(c.isOpen=!c.isOpen)}}}}]).directive("accordionHeading",["$log","$accordionSuppressWarning",function(a,b){return{restrict:"EA",transclude:!0,template:"",replace:!0,require:"^accordionGroup",link:function(c,d,e,f,g){b||a.warn("accordion-heading is now deprecated. Use uib-accordion-heading instead."),f.setHeading(g(c,angular.noop))}}}]).directive("accordionTransclude",["$log","$accordionSuppressWarning",function(a,b){return{require:"^accordionGroup",link:function(c,d,e,f){b||a.warn("accordion-transclude is now deprecated. Use uib-accordion-transclude instead."),c.$watch(function(){return f[e.accordionTransclude]},function(a){a&&(d.find("span").html(""),d.find("span").append(a))})}}}]),angular.module("ui.bootstrap.alert",[]).controller("UibAlertController",["$scope","$attrs","$timeout",function(a,b,c){a.closeable=!!b.close,angular.isDefined(b.dismissOnTimeout)&&c(function(){a.close()},parseInt(b.dismissOnTimeout,10))}]).directive("uibAlert",function(){return{controller:"UibAlertController",controllerAs:"alert",templateUrl:function(a,b){return b.templateUrl||"template/alert/alert.html"},transclude:!0,replace:!0,scope:{type:"@",close:"&"}}}),angular.module("ui.bootstrap.alert").value("$alertSuppressWarning",!1).controller("AlertController",["$scope","$attrs","$controller","$log","$alertSuppressWarning",function(a,b,c,d,e){return e||d.warn("AlertController is now deprecated. Use UibAlertController instead."),c("UibAlertController",{$scope:a,$attrs:b})}]).directive("alert",["$log","$alertSuppressWarning",function(a,b){return{controller:"AlertController",controllerAs:"alert",templateUrl:function(a,b){return b.templateUrl||"template/alert/alert.html"},transclude:!0,replace:!0,scope:{type:"@",close:"&"},link:function(){b||a.warn("alert is now deprecated. Use uib-alert instead.")}}}]),angular.module("ui.bootstrap.buttons",[]).constant("uibButtonConfig",{activeClass:"active",toggleEvent:"click"}).controller("UibButtonsController",["uibButtonConfig",function(a){this.activeClass=a.activeClass||"active",this.toggleEvent=a.toggleEvent||"click"}]).directive("uibBtnRadio",function(){return{require:["uibBtnRadio","ngModel"],controller:"UibButtonsController",controllerAs:"buttons",link:function(a,b,c,d){var e=d[0],f=d[1];b.find("input").css({display:"none"}),f.$render=function(){b.toggleClass(e.activeClass,angular.equals(f.$modelValue,a.$eval(c.uibBtnRadio)))},b.on(e.toggleEvent,function(){if(!c.disabled){var d=b.hasClass(e.activeClass);(!d||angular.isDefined(c.uncheckable))&&a.$apply(function(){f.$setViewValue(d?null:a.$eval(c.uibBtnRadio)),f.$render()})}})}}}).directive("uibBtnCheckbox",["$document",function(a){return{require:["uibBtnCheckbox","ngModel"],controller:"UibButtonsController",controllerAs:"button",link:function(b,c,d,e){function f(){return h(d.btnCheckboxTrue,!0)}function g(){return h(d.btnCheckboxFalse,!1)}function h(a,c){return angular.isDefined(a)?b.$eval(a):c}var i=e[0],j=e[1];c.find("input").css({display:"none"}),j.$render=function(){c.toggleClass(i.activeClass,angular.equals(j.$modelValue,f()))},c.on(i.toggleEvent,function(){d.disabled||b.$apply(function(){j.$setViewValue(c.hasClass(i.activeClass)?g():f()),j.$render()})}),c.on("keypress",function(e){d.disabled||32!==e.which||a[0].activeElement!==c[0]||b.$apply(function(){j.$setViewValue(c.hasClass(i.activeClass)?g():f()),j.$render()})})}}}]),angular.module("ui.bootstrap.buttons").value("$buttonsSuppressWarning",!1).controller("ButtonsController",["$controller","$log","$buttonsSuppressWarning",function(a,b,c){return c||b.warn("ButtonsController is now deprecated. Use UibButtonsController instead."),a("UibButtonsController")}]).directive("btnRadio",["$log","$buttonsSuppressWarning",function(a,b){return{require:["btnRadio","ngModel"],controller:"ButtonsController",controllerAs:"buttons",link:function(c,d,e,f){b||a.warn("btn-radio is now deprecated. Use uib-btn-radio instead.");var g=f[0],h=f[1];d.find("input").css({display:"none"}),h.$render=function(){d.toggleClass(g.activeClass,angular.equals(h.$modelValue,c.$eval(e.btnRadio)))},d.bind(g.toggleEvent,function(){if(!e.disabled){var a=d.hasClass(g.activeClass);(!a||angular.isDefined(e.uncheckable))&&c.$apply(function(){h.$setViewValue(a?null:c.$eval(e.btnRadio)),h.$render()})}})}}}]).directive("btnCheckbox",["$document","$log","$buttonsSuppressWarning",function(a,b,c){return{require:["btnCheckbox","ngModel"],controller:"ButtonsController",controllerAs:"button",link:function(d,e,f,g){function h(){return j(f.btnCheckboxTrue,!0)}function i(){return j(f.btnCheckboxFalse,!1)}function j(a,b){var c=d.$eval(a);return angular.isDefined(c)?c:b}c||b.warn("btn-checkbox is now deprecated. Use uib-btn-checkbox instead.");var k=g[0],l=g[1];e.find("input").css({display:"none"}),l.$render=function(){e.toggleClass(k.activeClass,angular.equals(l.$modelValue,h()))},e.bind(k.toggleEvent,function(){f.disabled||d.$apply(function(){l.$setViewValue(e.hasClass(k.activeClass)?i():h()),l.$render()})}),e.on("keypress",function(b){f.disabled||32!==b.which||a[0].activeElement!==e[0]||d.$apply(function(){l.$setViewValue(e.hasClass(k.activeClass)?i():h()),l.$render()})})}}}]),angular.module("ui.bootstrap.carousel",[]).controller("UibCarouselController",["$scope","$element","$interval","$animate",function(a,b,c,d){function e(b,c,e){s||(angular.extend(b,{direction:e,active:!0}),angular.extend(m.currentSlide||{},{direction:e,active:!1}),d.enabled()&&!a.noTransition&&!a.$currentTransition&&b.$element&&m.slides.length>1&&(b.$element.data(q,b.direction),m.currentSlide&&m.currentSlide.$element&&m.currentSlide.$element.data(q,b.direction),a.$currentTransition=!0,o?d.on("addClass",b.$element,function(b,c){"close"===c&&(a.$currentTransition=null,d.off("addClass",b))}):b.$element.one("$animate:close",function(){a.$currentTransition=null})),m.currentSlide=b,r=c,g())}function f(a){if(angular.isUndefined(n[a].index))return n[a];var b;n.length;for(b=0;b<n.length;++b)if(n[b].index==a)return n[b]}function g(){h();var b=+a.interval;!isNaN(b)&&b>0&&(k=c(i,b))}function h(){k&&(c.cancel(k),k=null)}function i(){var b=+a.interval;l&&!isNaN(b)&&b>0&&n.length?a.next():a.pause()}function j(b){b.length||(a.$currentTransition=null)}var k,l,m=this,n=m.slides=a.slides=[],o=angular.version.minor>=4,p="uib-noTransition",q="uib-slideDirection",r=-1;m.currentSlide=null;var s=!1;m.select=a.select=function(b,c){var d=a.indexOfSlide(b);void 0===c&&(c=d>m.getCurrentIndex()?"next":"prev"),b&&b!==m.currentSlide&&!a.$currentTransition&&e(b,d,c)},a.$on("$destroy",function(){s=!0}),m.getCurrentIndex=function(){return m.currentSlide&&angular.isDefined(m.currentSlide.index)?+m.currentSlide.index:r},a.indexOfSlide=function(a){return angular.isDefined(a.index)?+a.index:n.indexOf(a)},a.next=function(){var b=(m.getCurrentIndex()+1)%n.length;return 0===b&&a.noWrap()?void a.pause():m.select(f(b),"next")},a.prev=function(){var b=m.getCurrentIndex()-1<0?n.length-1:m.getCurrentIndex()-1;return a.noWrap()&&b===n.length-1?void a.pause():m.select(f(b),"prev")},a.isActive=function(a){return m.currentSlide===a},a.$watch("interval",g),a.$watchCollection("slides",j),a.$on("$destroy",h),a.play=function(){l||(l=!0,g())},a.pause=function(){a.noPause||(l=!1,h())},m.addSlide=function(b,c){b.$element=c,n.push(b),1===n.length||b.active?(m.select(n[n.length-1]),1===n.length&&a.play()):b.active=!1},m.removeSlide=function(a){angular.isDefined(a.index)&&n.sort(function(a,b){return+a.index>+b.index});var b=n.indexOf(a);n.splice(b,1),n.length>0&&a.active?b>=n.length?m.select(n[b-1]):m.select(n[b]):r>b&&r--,0===n.length&&(m.currentSlide=null)},a.$watch("noTransition",function(a){b.data(p,a)})}]).directive("uibCarousel",[function(){return{transclude:!0,replace:!0,controller:"UibCarouselController",controllerAs:"carousel",require:"carousel",templateUrl:function(a,b){return b.templateUrl||"template/carousel/carousel.html"},scope:{interval:"=",noTransition:"=",noPause:"=",noWrap:"&"}}}]).directive("uibSlide",function(){return{require:"^uibCarousel",restrict:"EA",transclude:!0,replace:!0,templateUrl:function(a,b){return b.templateUrl||"template/carousel/slide.html"},scope:{active:"=?",actual:"=?",index:"=?"},link:function(a,b,c,d){d.addSlide(a,b),a.$on("$destroy",function(){d.removeSlide(a)}),a.$watch("active",function(b){b&&d.select(a)})}}}).animation(".item",["$injector","$animate",function(a,b){function c(a,b,c){a.removeClass(b),c&&c()}var d="uib-noTransition",e="uib-slideDirection",f=null;return a.has("$animateCss")&&(f=a.get("$animateCss")),{beforeAddClass:function(a,g,h){if("active"==g&&a.parent()&&a.parent().parent()&&!a.parent().parent().data(d)){var i=!1,j=a.data(e),k="next"==j?"left":"right",l=c.bind(this,a,k+" "+j,h);return a.addClass(j),f?f(a,{addClass:k}).start().done(l):b.addClass(a,k).then(function(){i||l(),h()}),function(){i=!0}}h()},beforeRemoveClass:function(a,g,h){if("active"===g&&a.parent()&&a.parent().parent()&&!a.parent().parent().data(d)){var i=!1,j=a.data(e),k="next"==j?"left":"right",l=c.bind(this,a,k,h);return f?f(a,{addClass:k}).start().done(l):b.addClass(a,k).then(function(){i||l(),h()}),function(){i=!0}}h()}}}]),angular.module("ui.bootstrap.carousel").value("$carouselSuppressWarning",!1).controller("CarouselController",["$scope","$element","$controller","$log","$carouselSuppressWarning",function(a,b,c,d,e){return e||d.warn("CarouselController is now deprecated. Use UibCarouselController instead."),c("UibCarouselController",{$scope:a,$element:b})}]).directive("carousel",["$log","$carouselSuppressWarning",function(a,b){return{transclude:!0,replace:!0,controller:"CarouselController",controllerAs:"carousel",require:"carousel",templateUrl:function(a,b){return b.templateUrl||"template/carousel/carousel.html"},scope:{interval:"=",noTransition:"=",noPause:"=",noWrap:"&"},link:function(){b||a.warn("carousel is now deprecated. Use uib-carousel instead.")}}}]).directive("slide",["$log","$carouselSuppressWarning",function(a,b){return{require:"^carousel",transclude:!0,replace:!0,templateUrl:function(a,b){return b.templateUrl||"template/carousel/slide.html"},scope:{active:"=?",actual:"=?",index:"=?"},link:function(c,d,e,f){b||a.warn("slide is now deprecated. Use uib-slide instead."),f.addSlide(c,d),c.$on("$destroy",function(){f.removeSlide(c)}),c.$watch("active",function(a){a&&f.select(c)})}}}]),angular.module("ui.bootstrap.dateparser",[]).service("uibDateParser",["$log","$locale","orderByFilter",function(a,b,c){function d(a){var b=[],d=a.split("");return angular.forEach(g,function(c,e){var f=a.indexOf(e);if(f>-1){a=a.split(""),d[f]="("+c.regex+")",a[f]="$";for(var g=f+1,h=f+e.length;h>g;g++)d[g]="",a[g]="$";a=a.join(""),b.push({index:f,apply:c.apply})}}),{regex:new RegExp("^"+d.join("")+"$"),map:c(b,"index")}}function e(a,b,c){return 1>c?!1:1===b&&c>28?29===c&&(a%4===0&&a%100!==0||a%400===0):3===b||5===b||8===b||10===b?31>c:!0}var f,g,h=/[\\\^\$\*\+\?\|\[\]\(\)\.\{\}]/g;this.init=function(){f=b.id,this.parsers={},g={yyyy:{regex:"\\d{4}",apply:function(a){this.year=+a}},yy:{regex:"\\d{2}",apply:function(a){this.year=+a+2e3}},y:{regex:"\\d{1,4}",apply:function(a){this.year=+a}},MMMM:{regex:b.DATETIME_FORMATS.MONTH.join("|"),apply:function(a){this.month=b.DATETIME_FORMATS.MONTH.indexOf(a)}},MMM:{regex:b.DATETIME_FORMATS.SHORTMONTH.join("|"),apply:function(a){this.month=b.DATETIME_FORMATS.SHORTMONTH.indexOf(a)}},MM:{regex:"0[1-9]|1[0-2]",apply:function(a){this.month=a-1}},M:{regex:"[1-9]|1[0-2]",apply:function(a){this.month=a-1}},dd:{regex:"[0-2][0-9]{1}|3[0-1]{1}",apply:function(a){this.date=+a}},d:{regex:"[1-2]?[0-9]{1}|3[0-1]{1}",apply:function(a){this.date=+a}},EEEE:{regex:b.DATETIME_FORMATS.DAY.join("|")},EEE:{regex:b.DATETIME_FORMATS.SHORTDAY.join("|")},HH:{regex:"(?:0|1)[0-9]|2[0-3]",apply:function(a){this.hours=+a}},hh:{regex:"0[0-9]|1[0-2]",apply:function(a){this.hours=+a}},H:{regex:"1?[0-9]|2[0-3]",apply:function(a){this.hours=+a}},h:{regex:"[0-9]|1[0-2]",apply:function(a){this.hours=+a}},mm:{regex:"[0-5][0-9]",apply:function(a){this.minutes=+a}},m:{regex:"[0-9]|[1-5][0-9]",apply:function(a){this.minutes=+a}},sss:{regex:"[0-9][0-9][0-9]",apply:function(a){this.milliseconds=+a}},ss:{regex:"[0-5][0-9]",apply:function(a){this.seconds=+a}},s:{regex:"[0-9]|[1-5][0-9]",apply:function(a){this.seconds=+a}},a:{regex:b.DATETIME_FORMATS.AMPMS.join("|"),apply:function(a){12===this.hours&&(this.hours=0),"PM"===a&&(this.hours+=12)}}}},this.init(),this.parse=function(c,g,i){if(!angular.isString(c)||!g)return c;g=b.DATETIME_FORMATS[g]||g,g=g.replace(h,"\\$&"),b.id!==f&&this.init(),this.parsers[g]||(this.parsers[g]=d(g));var j=this.parsers[g],k=j.regex,l=j.map,m=c.match(k);if(m&&m.length){var n,o;angular.isDate(i)&&!isNaN(i.getTime())?n={year:i.getFullYear(),month:i.getMonth(),date:i.getDate(),hours:i.getHours(),minutes:i.getMinutes(),seconds:i.getSeconds(),milliseconds:i.getMilliseconds()}:(i&&a.warn("dateparser:","baseDate is not a valid date"),n={year:1900,month:0,date:1,hours:0,minutes:0,seconds:0,milliseconds:0});for(var p=1,q=m.length;q>p;p++){var r=l[p-1];r.apply&&r.apply.call(n,m[p])}return e(n.year,n.month,n.date)&&(o=new Date(n.year,n.month,n.date,n.hours,n.minutes,n.seconds,n.milliseconds||0)),o}}}]),angular.module("ui.bootstrap.dateparser").value("$dateParserSuppressWarning",!1).service("dateParser",["$log","$dateParserSuppressWarning","uibDateParser",function(a,b,c){b||a.warn("dateParser is now deprecated. Use uibDateParser instead."),angular.extend(this,c)}]),angular.module("ui.bootstrap.position",[]).factory("$uibPosition",["$document","$window",function(a,b){function c(a,c){return a.currentStyle?a.currentStyle[c]:b.getComputedStyle?b.getComputedStyle(a)[c]:a.style[c]}function d(a){return"static"===(c(a,"position")||"static")}var e=function(b){for(var c=a[0],e=b.offsetParent||c;e&&e!==c&&d(e);)e=e.offsetParent;return e||c};return{position:function(b){var c=this.offset(b),d={top:0,left:0},f=e(b[0]);f!=a[0]&&(d=this.offset(angular.element(f)),d.top+=f.clientTop-f.scrollTop,d.left+=f.clientLeft-f.scrollLeft);var g=b[0].getBoundingClientRect();return{width:g.width||b.prop("offsetWidth"),height:g.height||b.prop("offsetHeight"),top:c.top-d.top,left:c.left-d.left}},offset:function(c){var d=c[0].getBoundingClientRect();return{width:d.width||c.prop("offsetWidth"),height:d.height||c.prop("offsetHeight"),top:d.top+(b.pageYOffset||a[0].documentElement.scrollTop),left:d.left+(b.pageXOffset||a[0].documentElement.scrollLeft)}},positionElements:function(a,b,c,d){var e,f,g,h,i=c.split("-"),j=i[0],k=i[1]||"center";e=d?this.offset(a):this.position(a),f=b.prop("offsetWidth"),g=b.prop("offsetHeight");var l={center:function(){return e.left+e.width/2-f/2},left:function(){return e.left},right:function(){return e.left+e.width}},m={center:function(){return e.top+e.height/2-g/2},top:function(){return e.top},bottom:function(){return e.top+e.height}};switch(j){case"right":h={top:m[k](),left:l[j]()};break;case"left":h={top:m[k](),left:e.left-f};break;case"bottom":h={top:m[j](),left:l[k]()};break;default:h={top:e.top-g,left:l[k]()}}return h}}}]),angular.module("ui.bootstrap.position").value("$positionSuppressWarning",!1).service("$position",["$log","$positionSuppressWarning","$uibPosition",function(a,b,c){b||a.warn("$position is now deprecated. Use $uibPosition instead."),angular.extend(this,c)}]),angular.module("ui.bootstrap.datepicker",["ui.bootstrap.dateparser","ui.bootstrap.position"]).value("$datepickerSuppressError",!1).constant("uibDatepickerConfig",{formatDay:"dd",formatMonth:"MMMM",formatYear:"yyyy",formatDayHeader:"EEE",formatDayTitle:"MMMM yyyy",formatMonthTitle:"yyyy",datepickerMode:"day",minMode:"day",maxMode:"year",showWeeks:!0,startingDay:0,yearRange:20,minDate:null,maxDate:null,shortcutPropagation:!1}).controller("UibDatepickerController",["$scope","$attrs","$parse","$interpolate","$log","dateFilter","uibDatepickerConfig","$datepickerSuppressError",function(a,b,c,d,e,f,g,h){var i=this,j={$setViewValue:angular.noop};this.modes=["day","month","year"],angular.forEach(["formatDay","formatMonth","formatYear","formatDayHeader","formatDayTitle","formatMonthTitle","showWeeks","startingDay","yearRange","shortcutPropagation"],function(c,e){i[c]=angular.isDefined(b[c])?6>e?d(b[c])(a.$parent):a.$parent.$eval(b[c]):g[c]}),angular.forEach(["minDate","maxDate"],function(d){b[d]?a.$parent.$watch(c(b[d]),function(a){i[d]=a?new Date(a):null,i.refreshView()}):i[d]=g[d]?new Date(g[d]):null}),angular.forEach(["minMode","maxMode"],function(d){b[d]?a.$parent.$watch(c(b[d]),function(c){i[d]=angular.isDefined(c)?c:b[d],a[d]=i[d],("minMode"==d&&i.modes.indexOf(a.datepickerMode)<i.modes.indexOf(i[d])||"maxMode"==d&&i.modes.indexOf(a.datepickerMode)>i.modes.indexOf(i[d]))&&(a.datepickerMode=i[d])}):(i[d]=g[d]||null,a[d]=i[d])}),a.datepickerMode=a.datepickerMode||g.datepickerMode,a.uniqueId="datepicker-"+a.$id+"-"+Math.floor(1e4*Math.random()),angular.isDefined(b.initDate)?(this.activeDate=a.$parent.$eval(b.initDate)||new Date,a.$parent.$watch(b.initDate,function(a){a&&(j.$isEmpty(j.$modelValue)||j.$invalid)&&(i.activeDate=a,i.refreshView())})):this.activeDate=new Date,a.isActive=function(b){return 0===i.compare(b.date,i.activeDate)?(a.activeDateId=b.uid,!0):!1},this.init=function(a){j=a,j.$render=function(){i.render()}},this.render=function(){if(j.$viewValue){var a=new Date(j.$viewValue),b=!isNaN(a);b?this.activeDate=a:h||e.error('Datepicker directive: "ng-model" value must be a Date object, a number of milliseconds since 01.01.1970 or a string representing an RFC2822 or ISO 8601 date.')}this.refreshView()},this.refreshView=function(){if(this.element){this._refreshView();var a=j.$viewValue?new Date(j.$viewValue):null;j.$setValidity("dateDisabled",!a||this.element&&!this.isDisabled(a))}},this.createDateObject=function(a,b){var c=j.$viewValue?new Date(j.$viewValue):null;return{date:a,label:f(a,b),selected:c&&0===this.compare(a,c),disabled:this.isDisabled(a),current:0===this.compare(a,new Date),customClass:this.customClass(a)}},this.isDisabled=function(c){return this.minDate&&this.compare(c,this.minDate)<0||this.maxDate&&this.compare(c,this.maxDate)>0||b.dateDisabled&&a.dateDisabled({date:c,mode:a.datepickerMode})},this.customClass=function(b){return a.customClass({date:b,mode:a.datepickerMode})},this.split=function(a,b){for(var c=[];a.length>0;)c.push(a.splice(0,b));return c},this.fixTimeZone=function(a){var b=a.getHours();a.setHours(23===b?b+2:0)},a.select=function(b){if(a.datepickerMode===i.minMode){var c=j.$viewValue?new Date(j.$viewValue):new Date(0,0,0,0,0,0,0);c.setFullYear(b.getFullYear(),b.getMonth(),b.getDate()),j.$setViewValue(c),j.$render()}else i.activeDate=b,a.datepickerMode=i.modes[i.modes.indexOf(a.datepickerMode)-1]},a.move=function(a){var b=i.activeDate.getFullYear()+a*(i.step.years||0),c=i.activeDate.getMonth()+a*(i.step.months||0);i.activeDate.setFullYear(b,c,1),i.refreshView()},a.toggleMode=function(b){b=b||1,a.datepickerMode===i.maxMode&&1===b||a.datepickerMode===i.minMode&&-1===b||(a.datepickerMode=i.modes[i.modes.indexOf(a.datepickerMode)+b])},a.keys={13:"enter",32:"space",33:"pageup",34:"pagedown",35:"end",36:"home",37:"left",38:"up",39:"right",40:"down"};var k=function(){i.element[0].focus()};a.$on("uib:datepicker.focus",k),a.keydown=function(b){var c=a.keys[b.which];if(c&&!b.shiftKey&&!b.altKey)if(b.preventDefault(),i.shortcutPropagation||b.stopPropagation(),"enter"===c||"space"===c){if(i.isDisabled(i.activeDate))return;a.select(i.activeDate)}else!b.ctrlKey||"up"!==c&&"down"!==c?(i.handleKeyDown(c,b),i.refreshView()):a.toggleMode("up"===c?1:-1)}}]).controller("UibDaypickerController",["$scope","$element","dateFilter",function(a,b,c){function d(a,b){return 1!==b||a%4!==0||a%100===0&&a%400!==0?f[b]:29}function e(a){var b=new Date(a);b.setDate(b.getDate()+4-(b.getDay()||7));var c=b.getTime();return b.setMonth(0),b.setDate(1),Math.floor(Math.round((c-b)/864e5)/7)+1}var f=[31,28,31,30,31,30,31,31,30,31,30,31];this.step={months:1},this.element=b,this.init=function(b){angular.extend(b,this),a.showWeeks=b.showWeeks,b.refreshView()},this.getDates=function(a,b){for(var c,d=new Array(b),e=new Date(a),f=0;b>f;)c=new Date(e),this.fixTimeZone(c),d[f++]=c,e.setDate(e.getDate()+1);return d},this._refreshView=function(){var b=this.activeDate.getFullYear(),d=this.activeDate.getMonth(),f=new Date(b,d,1),g=this.startingDay-f.getDay(),h=g>0?7-g:-g,i=new Date(f);h>0&&i.setDate(-h+1);for(var j=this.getDates(i,42),k=0;42>k;k++)j[k]=angular.extend(this.createDateObject(j[k],this.formatDay),{secondary:j[k].getMonth()!==d,uid:a.uniqueId+"-"+k});a.labels=new Array(7);for(var l=0;7>l;l++)a.labels[l]={abbr:c(j[l].date,this.formatDayHeader),full:c(j[l].date,"EEEE")};if(a.title=c(this.activeDate,this.formatDayTitle),a.rows=this.split(j,7),a.showWeeks){a.weekNumbers=[];for(var m=(11-this.startingDay)%7,n=a.rows.length,o=0;n>o;o++)a.weekNumbers.push(e(a.rows[o][m].date))}},this.compare=function(a,b){return new Date(a.getFullYear(),a.getMonth(),a.getDate())-new Date(b.getFullYear(),b.getMonth(),b.getDate())},this.handleKeyDown=function(a,b){var c=this.activeDate.getDate();if("left"===a)c-=1;else if("up"===a)c-=7;else if("right"===a)c+=1;else if("down"===a)c+=7;else if("pageup"===a||"pagedown"===a){var e=this.activeDate.getMonth()+("pageup"===a?-1:1);this.activeDate.setMonth(e,1),c=Math.min(d(this.activeDate.getFullYear(),this.activeDate.getMonth()),c)}else"home"===a?c=1:"end"===a&&(c=d(this.activeDate.getFullYear(),this.activeDate.getMonth()));this.activeDate.setDate(c)}}]).controller("UibMonthpickerController",["$scope","$element","dateFilter",function(a,b,c){this.step={years:1},this.element=b,this.init=function(a){angular.extend(a,this),a.refreshView()},this._refreshView=function(){for(var b,d=new Array(12),e=this.activeDate.getFullYear(),f=0;12>f;f++)b=new Date(e,f,1),this.fixTimeZone(b),d[f]=angular.extend(this.createDateObject(b,this.formatMonth),{uid:a.uniqueId+"-"+f});a.title=c(this.activeDate,this.formatMonthTitle),a.rows=this.split(d,3)},this.compare=function(a,b){return new Date(a.getFullYear(),a.getMonth())-new Date(b.getFullYear(),b.getMonth())},this.handleKeyDown=function(a,b){var c=this.activeDate.getMonth();if("left"===a)c-=1;else if("up"===a)c-=3;else if("right"===a)c+=1;else if("down"===a)c+=3;else if("pageup"===a||"pagedown"===a){var d=this.activeDate.getFullYear()+("pageup"===a?-1:1);this.activeDate.setFullYear(d)}else"home"===a?c=0:"end"===a&&(c=11);this.activeDate.setMonth(c)}}]).controller("UibYearpickerController",["$scope","$element","dateFilter",function(a,b,c){function d(a){return parseInt((a-1)/e,10)*e+1}var e;this.element=b,this.yearpickerInit=function(){e=this.yearRange,this.step={years:e}},this._refreshView=function(){for(var b,c=new Array(e),f=0,g=d(this.activeDate.getFullYear());e>f;f++)b=new Date(g+f,0,1),this.fixTimeZone(b),c[f]=angular.extend(this.createDateObject(b,this.formatYear),{uid:a.uniqueId+"-"+f});a.title=[c[0].label,c[e-1].label].join(" - "),a.rows=this.split(c,5)},this.compare=function(a,b){return a.getFullYear()-b.getFullYear()},this.handleKeyDown=function(a,b){var c=this.activeDate.getFullYear();"left"===a?c-=1:"up"===a?c-=5:"right"===a?c+=1:"down"===a?c+=5:"pageup"===a||"pagedown"===a?c+=("pageup"===a?-1:1)*this.step.years:"home"===a?c=d(this.activeDate.getFullYear()):"end"===a&&(c=d(this.activeDate.getFullYear())+e-1),this.activeDate.setFullYear(c)}}]).directive("uibDatepicker",function(){return{replace:!0,templateUrl:function(a,b){return b.templateUrl||"template/datepicker/datepicker.html"},scope:{datepickerMode:"=?",dateDisabled:"&",customClass:"&",shortcutPropagation:"&?"},require:["uibDatepicker","^ngModel"],controller:"UibDatepickerController",controllerAs:"datepicker",link:function(a,b,c,d){var e=d[0],f=d[1];e.init(f)}}}).directive("uibDaypicker",function(){return{replace:!0,templateUrl:"template/datepicker/day.html",require:["^?uibDatepicker","uibDaypicker","^?datepicker"],controller:"UibDaypickerController",link:function(a,b,c,d){var e=d[0]||d[2],f=d[1];f.init(e)}}}).directive("uibMonthpicker",function(){return{replace:!0,templateUrl:"template/datepicker/month.html",require:["^?uibDatepicker","uibMonthpicker","^?datepicker"],controller:"UibMonthpickerController",link:function(a,b,c,d){var e=d[0]||d[2],f=d[1];f.init(e)}}}).directive("uibYearpicker",function(){return{replace:!0,templateUrl:"template/datepicker/year.html",require:["^?uibDatepicker","uibYearpicker","^?datepicker"],controller:"UibYearpickerController",link:function(a,b,c,d){var e=d[0]||d[2];angular.extend(e,d[1]),e.yearpickerInit(),e.refreshView()}}}).constant("uibDatepickerPopupConfig",{datepickerPopup:"yyyy-MM-dd",datepickerPopupTemplateUrl:"template/datepicker/popup.html",datepickerTemplateUrl:"template/datepicker/datepicker.html",html5Types:{date:"yyyy-MM-dd","datetime-local":"yyyy-MM-ddTHH:mm:ss.sss",month:"yyyy-MM"},currentText:"Today",clearText:"Clear",closeText:"Done",closeOnDateSelection:!0,appendToBody:!1,showButtonBar:!0,onOpenFocus:!0}).controller("UibDatepickerPopupController",["$scope","$element","$attrs","$compile","$parse","$document","$rootScope","$uibPosition","dateFilter","uibDateParser","uibDatepickerPopupConfig","$timeout",function(a,b,c,d,e,f,g,h,i,j,k,l){function m(a){return a.replace(/([A-Z])/g,function(a){ | 8 | +angular.module("ui.bootstrap",["ui.bootstrap.tpls","ui.bootstrap.collapse","ui.bootstrap.accordion","ui.bootstrap.alert","ui.bootstrap.buttons","ui.bootstrap.carousel","ui.bootstrap.dateparser","ui.bootstrap.position","ui.bootstrap.datepicker","ui.bootstrap.dropdown","ui.bootstrap.stackedMap","ui.bootstrap.modal","ui.bootstrap.pagination","ui.bootstrap.tooltip","ui.bootstrap.popover","ui.bootstrap.progressbar","ui.bootstrap.rating","ui.bootstrap.tabs","ui.bootstrap.timepicker","ui.bootstrap.typeahead"]),angular.module("ui.bootstrap.tpls",["template/accordion/accordion-group.html","template/accordion/accordion.html","template/alert/alert.html","template/carousel/carousel.html","template/carousel/slide.html","template/datepicker/datepicker.html","template/datepicker/day.html","template/datepicker/month.html","template/datepicker/popup.html","template/datepicker/year.html","template/modal/backdrop.html","template/modal/window.html","template/pagination/pager.html","template/pagination/pagination.html","template/tooltip/tooltip-html-popup.html","template/tooltip/tooltip-popup.html","template/tooltip/tooltip-template-popup.html","template/popover/popover-html.html","template/popover/popover-template.html","template/popover/popover.html","template/progressbar/bar.html","template/progressbar/progress.html","template/progressbar/progressbar.html","template/rating/rating.html","template/tabs/tab.html","template/tabs/tabset.html","template/timepicker/timepicker.html","template/typeahead/typeahead-match.html","template/typeahead/typeahead-popup.html"]),angular.module("ui.bootstrap.collapse",[]).directive("uibCollapse",["$animate","$injector",function(a,b){var c=b.has("$animateCss")?b.get("$animateCss"):null;return{link:function(b,d,e){function f(){d.removeClass("collapse").addClass("collapsing").attr("aria-expanded",!0).attr("aria-hidden",!1),c?c(d,{addClass:"in",easing:"ease",to:{height:d[0].scrollHeight+"px"}}).start().done(g):a.addClass(d,"in",{to:{height:d[0].scrollHeight+"px"}}).then(g)}function g(){d.removeClass("collapsing").addClass("collapse").css({height:"auto"})}function h(){return d.hasClass("collapse")||d.hasClass("in")?(d.css({height:d[0].scrollHeight+"px"}).removeClass("collapse").addClass("collapsing").attr("aria-expanded",!1).attr("aria-hidden",!0),void(c?c(d,{removeClass:"in",to:{height:"0"}}).start().done(i):a.removeClass(d,"in",{to:{height:"0"}}).then(i))):i()}function i(){d.css({height:"0"}),d.removeClass("collapsing").addClass("collapse")}b.$watch(e.uibCollapse,function(a){a?h():f()})}}}]),angular.module("ui.bootstrap.collapse").value("$collapseSuppressWarning",!1).directive("collapse",["$animate","$injector","$log","$collapseSuppressWarning",function(a,b,c,d){var e=b.has("$animateCss")?b.get("$animateCss"):null;return{link:function(b,f,g){function h(){f.removeClass("collapse").addClass("collapsing").attr("aria-expanded",!0).attr("aria-hidden",!1),e?e(f,{addClass:"in",easing:"ease",to:{height:f[0].scrollHeight+"px"}}).start().done(i):a.addClass(f,"in",{to:{height:f[0].scrollHeight+"px"}}).then(i)}function i(){f.removeClass("collapsing").addClass("collapse").css({height:"auto"})}function j(){return f.hasClass("collapse")||f.hasClass("in")?(f.css({height:f[0].scrollHeight+"px"}).removeClass("collapse").addClass("collapsing").attr("aria-expanded",!1).attr("aria-hidden",!0),void(e?e(f,{removeClass:"in",to:{height:"0"}}).start().done(k):a.removeClass(f,"in",{to:{height:"0"}}).then(k))):k()}function k(){f.css({height:"0"}),f.removeClass("collapsing").addClass("collapse")}d||c.warn("collapse is now deprecated. Use uib-collapse instead."),b.$watch(g.collapse,function(a){a?j():h()})}}}]),angular.module("ui.bootstrap.accordion",["ui.bootstrap.collapse"]).constant("uibAccordionConfig",{closeOthers:!0}).controller("UibAccordionController",["$scope","$attrs","uibAccordionConfig",function(a,b,c){this.groups=[],this.closeOthers=function(d){var e=angular.isDefined(b.closeOthers)?a.$eval(b.closeOthers):c.closeOthers;e&&angular.forEach(this.groups,function(a){a!==d&&(a.isOpen=!1)})},this.addGroup=function(a){var b=this;this.groups.push(a),a.$on("$destroy",function(c){b.removeGroup(a)})},this.removeGroup=function(a){var b=this.groups.indexOf(a);-1!==b&&this.groups.splice(b,1)}}]).directive("uibAccordion",function(){return{controller:"UibAccordionController",controllerAs:"accordion",transclude:!0,templateUrl:function(a,b){return b.templateUrl||"template/accordion/accordion.html"}}}).directive("uibAccordionGroup",function(){return{require:"^uibAccordion",transclude:!0,replace:!0,templateUrl:function(a,b){return b.templateUrl||"template/accordion/accordion-group.html"},scope:{heading:"@",isOpen:"=?",isDisabled:"=?"},controller:function(){this.setHeading=function(a){this.heading=a}},link:function(a,b,c,d){d.addGroup(a),a.openClass=c.openClass||"panel-open",a.panelClass=c.panelClass,a.$watch("isOpen",function(c){b.toggleClass(a.openClass,!!c),c&&d.closeOthers(a)}),a.toggleOpen=function(b){a.isDisabled||b&&32!==b.which||(a.isOpen=!a.isOpen)}}}}).directive("uibAccordionHeading",function(){return{transclude:!0,template:"",replace:!0,require:"^uibAccordionGroup",link:function(a,b,c,d,e){d.setHeading(e(a,angular.noop))}}}).directive("uibAccordionTransclude",function(){return{require:["?^uibAccordionGroup","?^accordionGroup"],link:function(a,b,c,d){d=d[0]?d[0]:d[1],a.$watch(function(){return d[c.uibAccordionTransclude]},function(a){a&&(b.find("span").html(""),b.find("span").append(a))})}}}),angular.module("ui.bootstrap.accordion").value("$accordionSuppressWarning",!1).controller("AccordionController",["$scope","$attrs","$controller","$log","$accordionSuppressWarning",function(a,b,c,d,e){return e||d.warn("AccordionController is now deprecated. Use UibAccordionController instead."),c("UibAccordionController",{$scope:a,$attrs:b})}]).directive("accordion",["$log","$accordionSuppressWarning",function(a,b){return{restrict:"EA",controller:"AccordionController",controllerAs:"accordion",transclude:!0,replace:!1,templateUrl:function(a,b){return b.templateUrl||"template/accordion/accordion.html"},link:function(){b||a.warn("accordion is now deprecated. Use uib-accordion instead.")}}}]).directive("accordionGroup",["$log","$accordionSuppressWarning",function(a,b){return{require:"^accordion",restrict:"EA",transclude:!0,replace:!0,templateUrl:function(a,b){return b.templateUrl||"template/accordion/accordion-group.html"},scope:{heading:"@",isOpen:"=?",isDisabled:"=?"},controller:function(){this.setHeading=function(a){this.heading=a}},link:function(c,d,e,f){b||a.warn("accordion-group is now deprecated. Use uib-accordion-group instead."),f.addGroup(c),c.openClass=e.openClass||"panel-open",c.panelClass=e.panelClass,c.$watch("isOpen",function(a){d.toggleClass(c.openClass,!!a),a&&f.closeOthers(c)}),c.toggleOpen=function(a){c.isDisabled||a&&32!==a.which||(c.isOpen=!c.isOpen)}}}}]).directive("accordionHeading",["$log","$accordionSuppressWarning",function(a,b){return{restrict:"EA",transclude:!0,template:"",replace:!0,require:"^accordionGroup",link:function(c,d,e,f,g){b||a.warn("accordion-heading is now deprecated. Use uib-accordion-heading instead."),f.setHeading(g(c,angular.noop))}}}]).directive("accordionTransclude",["$log","$accordionSuppressWarning",function(a,b){return{require:"^accordionGroup",link:function(c,d,e,f){b||a.warn("accordion-transclude is now deprecated. Use uib-accordion-transclude instead."),c.$watch(function(){return f[e.accordionTransclude]},function(a){a&&(d.find("span").html(""),d.find("span").append(a))})}}}]),angular.module("ui.bootstrap.alert",[]).controller("UibAlertController",["$scope","$attrs","$timeout",function(a,b,c){a.closeable=!!b.close,angular.isDefined(b.dismissOnTimeout)&&c(function(){a.close()},parseInt(b.dismissOnTimeout,10))}]).directive("uibAlert",function(){return{controller:"UibAlertController",controllerAs:"alert",templateUrl:function(a,b){return b.templateUrl||"template/alert/alert.html"},transclude:!0,replace:!0,scope:{type:"@",close:"&"}}}),angular.module("ui.bootstrap.alert").value("$alertSuppressWarning",!1).controller("AlertController",["$scope","$attrs","$controller","$log","$alertSuppressWarning",function(a,b,c,d,e){return e||d.warn("AlertController is now deprecated. Use UibAlertController instead."),c("UibAlertController",{$scope:a,$attrs:b})}]).directive("alert",["$log","$alertSuppressWarning",function(a,b){return{controller:"AlertController",controllerAs:"alert",templateUrl:function(a,b){return b.templateUrl||"template/alert/alert.html"},transclude:!0,replace:!0,scope:{type:"@",close:"&"},link:function(){b||a.warn("alert is now deprecated. Use uib-alert instead.")}}}]),angular.module("ui.bootstrap.buttons",[]).constant("uibButtonConfig",{activeClass:"active",toggleEvent:"click"}).controller("UibButtonsController",["uibButtonConfig",function(a){this.activeClass=a.activeClass||"active",this.toggleEvent=a.toggleEvent||"click"}]).directive("uibBtnRadio",function(){return{require:["uibBtnRadio","ngModel"],controller:"UibButtonsController",controllerAs:"buttons",link:function(a,b,c,d){var e=d[0],f=d[1];b.find("input").css({display:"none"}),f.$render=function(){b.toggleClass(e.activeClass,angular.equals(f.$modelValue,a.$eval(c.uibBtnRadio)))},b.on(e.toggleEvent,function(){if(!c.disabled){var d=b.hasClass(e.activeClass);(!d||angular.isDefined(c.uncheckable))&&a.$apply(function(){f.$setViewValue(d?null:a.$eval(c.uibBtnRadio)),f.$render()})}})}}}).directive("uibBtnCheckbox",["$document",function(a){return{require:["uibBtnCheckbox","ngModel"],controller:"UibButtonsController",controllerAs:"button",link:function(b,c,d,e){function f(){return h(d.btnCheckboxTrue,!0)}function g(){return h(d.btnCheckboxFalse,!1)}function h(a,c){return angular.isDefined(a)?b.$eval(a):c}var i=e[0],j=e[1];c.find("input").css({display:"none"}),j.$render=function(){c.toggleClass(i.activeClass,angular.equals(j.$modelValue,f()))},c.on(i.toggleEvent,function(){d.disabled||b.$apply(function(){j.$setViewValue(c.hasClass(i.activeClass)?g():f()),j.$render()})}),c.on("keypress",function(e){d.disabled||32!==e.which||a[0].activeElement!==c[0]||b.$apply(function(){j.$setViewValue(c.hasClass(i.activeClass)?g():f()),j.$render()})})}}}]),angular.module("ui.bootstrap.buttons").value("$buttonsSuppressWarning",!1).controller("ButtonsController",["$controller","$log","$buttonsSuppressWarning",function(a,b,c){return c||b.warn("ButtonsController is now deprecated. Use UibButtonsController instead."),a("UibButtonsController")}]).directive("btnRadio",["$log","$buttonsSuppressWarning",function(a,b){return{require:["btnRadio","ngModel"],controller:"ButtonsController",controllerAs:"buttons",link:function(c,d,e,f){b||a.warn("btn-radio is now deprecated. Use uib-btn-radio instead.");var g=f[0],h=f[1];d.find("input").css({display:"none"}),h.$render=function(){d.toggleClass(g.activeClass,angular.equals(h.$modelValue,c.$eval(e.btnRadio)))},d.bind(g.toggleEvent,function(){if(!e.disabled){var a=d.hasClass(g.activeClass);(!a||angular.isDefined(e.uncheckable))&&c.$apply(function(){h.$setViewValue(a?null:c.$eval(e.btnRadio)),h.$render()})}})}}}]).directive("btnCheckbox",["$document","$log","$buttonsSuppressWarning",function(a,b,c){return{require:["btnCheckbox","ngModel"],controller:"ButtonsController",controllerAs:"button",link:function(d,e,f,g){function h(){return j(f.btnCheckboxTrue,!0)}function i(){return j(f.btnCheckboxFalse,!1)}function j(a,b){var c=d.$eval(a);return angular.isDefined(c)?c:b}c||b.warn("btn-checkbox is now deprecated. Use uib-btn-checkbox instead.");var k=g[0],l=g[1];e.find("input").css({display:"none"}),l.$render=function(){e.toggleClass(k.activeClass,angular.equals(l.$modelValue,h()))},e.bind(k.toggleEvent,function(){f.disabled||d.$apply(function(){l.$setViewValue(e.hasClass(k.activeClass)?i():h()),l.$render()})}),e.on("keypress",function(b){f.disabled||32!==b.which||a[0].activeElement!==e[0]||d.$apply(function(){l.$setViewValue(e.hasClass(k.activeClass)?i():h()),l.$render()})})}}}]),angular.module("ui.bootstrap.carousel",[]).controller("UibCarouselController",["$scope","$element","$interval","$animate",function(a,b,c,d){function e(b,c,e){s||(angular.extend(b,{direction:e,active:!0}),angular.extend(m.currentSlide||{},{direction:e,active:!1}),d.enabled()&&!a.noTransition&&!a.$currentTransition&&b.$element&&m.slides.length>1&&(b.$element.data(q,b.direction),m.currentSlide&&m.currentSlide.$element&&m.currentSlide.$element.data(q,b.direction),a.$currentTransition=!0,o?d.on("addClass",b.$element,function(b,c){"close"===c&&(a.$currentTransition=null,d.off("addClass",b))}):b.$element.one("$animate:close",function(){a.$currentTransition=null})),m.currentSlide=b,r=c,g())}function f(a){if(angular.isUndefined(n[a].index))return n[a];var b;n.length;for(b=0;b<n.length;++b)if(n[b].index==a)return n[b]}function g(){h();var b=+a.interval;!isNaN(b)&&b>0&&(k=c(i,b))}function h(){k&&(c.cancel(k),k=null)}function i(){var b=+a.interval;l&&!isNaN(b)&&b>0&&n.length?a.next():a.pause()}function j(b){b.length||(a.$currentTransition=null)}var k,l,m=this,n=m.slides=a.slides=[],o=angular.version.minor>=4,p="uib-noTransition",q="uib-slideDirection",r=-1;m.currentSlide=null;var s=!1;m.select=a.select=function(b,c){var d=a.indexOfSlide(b);void 0===c&&(c=d>m.getCurrentIndex()?"next":"prev"),b&&b!==m.currentSlide&&!a.$currentTransition&&e(b,d,c)},a.$on("$destroy",function(){s=!0}),m.getCurrentIndex=function(){return m.currentSlide&&angular.isDefined(m.currentSlide.index)?+m.currentSlide.index:r},a.indexOfSlide=function(a){return angular.isDefined(a.index)?+a.index:n.indexOf(a)},a.next=function(){var b=(m.getCurrentIndex()+1)%n.length;return 0===b&&a.noWrap()?void a.pause():m.select(f(b),"next")},a.prev=function(){var b=m.getCurrentIndex()-1<0?n.length-1:m.getCurrentIndex()-1;return a.noWrap()&&b===n.length-1?void a.pause():m.select(f(b),"prev")},a.isActive=function(a){return m.currentSlide===a},a.$watch("interval",g),a.$watchCollection("slides",j),a.$on("$destroy",h),a.play=function(){l||(l=!0,g())},a.pause=function(){a.noPause||(l=!1,h())},m.addSlide=function(b,c){b.$element=c,n.push(b),1===n.length||b.active?(m.select(n[n.length-1]),1===n.length&&a.play()):b.active=!1},m.removeSlide=function(a){angular.isDefined(a.index)&&n.sort(function(a,b){return+a.index>+b.index});var b=n.indexOf(a);n.splice(b,1),n.length>0&&a.active?b>=n.length?m.select(n[b-1]):m.select(n[b]):r>b&&r--,0===n.length&&(m.currentSlide=null)},a.$watch("noTransition",function(a){b.data(p,a)})}]).directive("uibCarousel",[function(){return{transclude:!0,replace:!0,controller:"UibCarouselController",controllerAs:"carousel",require:"carousel",templateUrl:function(a,b){return b.templateUrl||"template/carousel/carousel.html"},scope:{interval:"=",noTransition:"=",noPause:"=",noWrap:"&"}}}]).directive("uibSlide",function(){return{require:"^uibCarousel",restrict:"EA",transclude:!0,replace:!0,templateUrl:function(a,b){return b.templateUrl||"template/carousel/slide.html"},scope:{active:"=?",actual:"=?",index:"=?"},link:function(a,b,c,d){d.addSlide(a,b),a.$on("$destroy",function(){d.removeSlide(a)}),a.$watch("active",function(b){b&&d.select(a)})}}}).animation(".item",["$injector","$animate",function(a,b){function c(a,b,c){a.removeClass(b),c&&c()}var d="uib-noTransition",e="uib-slideDirection",f=null;return a.has("$animateCss")&&(f=a.get("$animateCss")),{beforeAddClass:function(a,g,h){if("active"==g&&a.parent()&&a.parent().parent()&&!a.parent().parent().data(d)){var i=!1,j=a.data(e),k="next"==j?"left":"right",l=c.bind(this,a,k+" "+j,h);return a.addClass(j),f?f(a,{addClass:k}).start().done(l):b.addClass(a,k).then(function(){i||l(),h()}),function(){i=!0}}h()},beforeRemoveClass:function(a,g,h){if("active"===g&&a.parent()&&a.parent().parent()&&!a.parent().parent().data(d)){var i=!1,j=a.data(e),k="next"==j?"left":"right",l=c.bind(this,a,k,h);return f?f(a,{addClass:k}).start().done(l):b.addClass(a,k).then(function(){i||l(),h()}),function(){i=!0}}h()}}}]),angular.module("ui.bootstrap.carousel").value("$carouselSuppressWarning",!1).controller("CarouselController",["$scope","$element","$controller","$log","$carouselSuppressWarning",function(a,b,c,d,e){return e||d.warn("CarouselController is now deprecated. Use UibCarouselController instead."),c("UibCarouselController",{$scope:a,$element:b})}]).directive("carousel",["$log","$carouselSuppressWarning",function(a,b){return{transclude:!0,replace:!0,controller:"CarouselController",controllerAs:"carousel",require:"carousel",templateUrl:function(a,b){return b.templateUrl||"template/carousel/carousel.html"},scope:{interval:"=",noTransition:"=",noPause:"=",noWrap:"&"},link:function(){b||a.warn("carousel is now deprecated. Use uib-carousel instead.")}}}]).directive("slide",["$log","$carouselSuppressWarning",function(a,b){return{require:"^carousel",transclude:!0,replace:!0,templateUrl:function(a,b){return b.templateUrl||"template/carousel/slide.html"},scope:{active:"=?",actual:"=?",index:"=?"},link:function(c,d,e,f){b||a.warn("slide is now deprecated. Use uib-slide instead."),f.addSlide(c,d),c.$on("$destroy",function(){f.removeSlide(c)}),c.$watch("active",function(a){a&&f.select(c)})}}}]),angular.module("ui.bootstrap.dateparser",[]).service("uibDateParser",["$log","$locale","orderByFilter",function(a,b,c){function d(a){var b=[],d=a.split("");return angular.forEach(g,function(c,e){var f=a.indexOf(e);if(f>-1){a=a.split(""),d[f]="("+c.regex+")",a[f]="$";for(var g=f+1,h=f+e.length;h>g;g++)d[g]="",a[g]="$";a=a.join(""),b.push({index:f,apply:c.apply})}}),{regex:new RegExp("^"+d.join("")+"$"),map:c(b,"index")}}function e(a,b,c){return 1>c?!1:1===b&&c>28?29===c&&(a%4===0&&a%100!==0||a%400===0):3===b||5===b||8===b||10===b?31>c:!0}var f,g,h=/[\\\^\$\*\+\?\|\[\]\(\)\.\{\}]/g;this.init=function(){f=b.id,this.parsers={},g={yyyy:{regex:"\\d{4}",apply:function(a){this.year=+a}},yy:{regex:"\\d{2}",apply:function(a){this.year=+a+2e3}},y:{regex:"\\d{1,4}",apply:function(a){this.year=+a}},MMMM:{regex:b.DATETIME_FORMATS.MONTH.join("|"),apply:function(a){this.month=b.DATETIME_FORMATS.MONTH.indexOf(a)}},MMM:{regex:b.DATETIME_FORMATS.SHORTMONTH.join("|"),apply:function(a){this.month=b.DATETIME_FORMATS.SHORTMONTH.indexOf(a)}},MM:{regex:"0[1-9]|1[0-2]",apply:function(a){this.month=a-1}},M:{regex:"[1-9]|1[0-2]",apply:function(a){this.month=a-1}},dd:{regex:"[0-2][0-9]{1}|3[0-1]{1}",apply:function(a){this.date=+a}},d:{regex:"[1-2]?[0-9]{1}|3[0-1]{1}",apply:function(a){this.date=+a}},EEEE:{regex:b.DATETIME_FORMATS.DAY.join("|")},EEE:{regex:b.DATETIME_FORMATS.SHORTDAY.join("|")},HH:{regex:"(?:0|1)[0-9]|2[0-3]",apply:function(a){this.hours=+a}},hh:{regex:"0[0-9]|1[0-2]",apply:function(a){this.hours=+a}},H:{regex:"1?[0-9]|2[0-3]",apply:function(a){this.hours=+a}},h:{regex:"[0-9]|1[0-2]",apply:function(a){this.hours=+a}},mm:{regex:"[0-5][0-9]",apply:function(a){this.minutes=+a}},m:{regex:"[0-9]|[1-5][0-9]",apply:function(a){this.minutes=+a}},sss:{regex:"[0-9][0-9][0-9]",apply:function(a){this.milliseconds=+a}},ss:{regex:"[0-5][0-9]",apply:function(a){this.seconds=+a}},s:{regex:"[0-9]|[1-5][0-9]",apply:function(a){this.seconds=+a}},a:{regex:b.DATETIME_FORMATS.AMPMS.join("|"),apply:function(a){12===this.hours&&(this.hours=0),"PM"===a&&(this.hours+=12)}}}},this.init(),this.parse=function(c,g,i){if(!angular.isString(c)||!g)return c;g=b.DATETIME_FORMATS[g]||g,g=g.replace(h,"\\$&"),b.id!==f&&this.init(),this.parsers[g]||(this.parsers[g]=d(g));var j=this.parsers[g],k=j.regex,l=j.map,m=c.match(k);if(m&&m.length){var n,o;angular.isDate(i)&&!isNaN(i.getTime())?n={year:i.getFullYear(),month:i.getMonth(),date:i.getDate(),hours:i.getHours(),minutes:i.getMinutes(),seconds:i.getSeconds(),milliseconds:i.getMilliseconds()}:(i&&a.warn("dateparser:","baseDate is not a valid date"),n={year:1900,month:0,date:1,hours:0,minutes:0,seconds:0,milliseconds:0});for(var p=1,q=m.length;q>p;p++){var r=l[p-1];r.apply&&r.apply.call(n,m[p])}return e(n.year,n.month,n.date)&&(o=new Date(n.year,n.month,n.date,n.hours,n.minutes,n.seconds,n.milliseconds||0)),o}}}]),angular.module("ui.bootstrap.dateparser").value("$dateParserSuppressWarning",!1).service("dateParser",["$log","$dateParserSuppressWarning","uibDateParser",function(a,b,c){b||a.warn("dateParser is now deprecated. Use uibDateParser instead."),angular.extend(this,c)}]),angular.module("ui.bootstrap.position",[]).factory("$uibPosition",["$document","$window",function(a,b){function c(a,c){return a.currentStyle?a.currentStyle[c]:b.getComputedStyle?b.getComputedStyle(a)[c]:a.style[c]}function d(a){return"static"===(c(a,"position")||"static")}var e=function(b){for(var c=a[0],e=b.offsetParent||c;e&&e!==c&&d(e);)e=e.offsetParent;return e||c};return{position:function(b){var c=this.offset(b),d={top:0,left:0},f=e(b[0]);f!=a[0]&&(d=this.offset(angular.element(f)),d.top+=f.clientTop-f.scrollTop,d.left+=f.clientLeft-f.scrollLeft);var g=b[0].getBoundingClientRect();return{width:g.width||b.prop("offsetWidth"),height:g.height||b.prop("offsetHeight"),top:c.top-d.top,left:c.left-d.left}},offset:function(c){var d=c[0].getBoundingClientRect();return{width:d.width||c.prop("offsetWidth"),height:d.height||c.prop("offsetHeight"),top:d.top+(b.pageYOffset||a[0].documentElement.scrollTop),left:d.left+(b.pageXOffset||a[0].documentElement.scrollLeft)}},positionElements:function(a,b,c,d){var e,f,g,h,i=c.split("-"),j=i[0],k=i[1]||"center";e=d?this.offset(a):this.position(a),f=b.prop("offsetWidth"),g=b.prop("offsetHeight");var l={center:function(){return e.left+e.width/2-f/2},left:function(){return e.left},right:function(){return e.left+e.width}},m={center:function(){return e.top+e.height/2-g/2},top:function(){return e.top},bottom:function(){return e.top+e.height}};switch(j){case"right":h={top:m[k](),left:l[j]()};break;case"left":h={top:m[k](),left:e.left-f};break;case"bottom":h={top:m[j](),left:l[k]()};break;default:h={top:e.top-g,left:l[k]()}}return h}}}]),angular.module("ui.bootstrap.position").value("$positionSuppressWarning",!1).service("$position",["$log","$positionSuppressWarning","$uibPosition",function(a,b,c){b||a.warn("$position is now deprecated. Use $uibPosition instead."),angular.extend(this,c)}]),angular.module("ui.bootstrap.datepicker",["ui.bootstrap.dateparser","ui.bootstrap.position"]).value("$datepickerSuppressError",!1).constant("uibDatepickerConfig",{formatDay:"dd",formatMonth:"MMMM",formatYear:"yyyy",formatDayHeader:"EEE",formatDayTitle:"MMMM yyyy",formatMonthTitle:"yyyy",datepickerMode:"day",minMode:"day",maxMode:"year",showWeeks:!0,startingDay:0,yearRange:20,minDate:null,maxDate:null,shortcutPropagation:!1}).controller("UibDatepickerController",["$scope","$attrs","$parse","$interpolate","$log","dateFilter","uibDatepickerConfig","$datepickerSuppressError",function(a,b,c,d,e,f,g,h){var i=this,j={$setViewValue:angular.noop};this.modes=["day","month","year"],angular.forEach(["formatDay","formatMonth","formatYear","formatDayHeader","formatDayTitle","formatMonthTitle","showWeeks","startingDay","yearRange","shortcutPropagation"],function(c,e){i[c]=angular.isDefined(b[c])?6>e?d(b[c])(a.$parent):a.$parent.$eval(b[c]):g[c]}),angular.forEach(["minDate","maxDate"],function(d){b[d]?a.$parent.$watch(c(b[d]),function(a){i[d]=a?new Date(a):null,i.refreshView()}):i[d]=g[d]?new Date(g[d]):null}),angular.forEach(["minMode","maxMode"],function(d){b[d]?a.$parent.$watch(c(b[d]),function(c){i[d]=angular.isDefined(c)?c:b[d],a[d]=i[d],("minMode"==d&&i.modes.indexOf(a.datepickerMode)<i.modes.indexOf(i[d])||"maxMode"==d&&i.modes.indexOf(a.datepickerMode)>i.modes.indexOf(i[d]))&&(a.datepickerMode=i[d])}):(i[d]=g[d]||null,a[d]=i[d])}),a.datepickerMode=a.datepickerMode||g.datepickerMode,a.uniqueId="datepicker-"+a.$id+"-"+Math.floor(1e4*Math.random()),angular.isDefined(b.initDate)?(this.activeDate=a.$parent.$eval(b.initDate)||new Date,a.$parent.$watch(b.initDate,function(a){a&&(j.$isEmpty(j.$modelValue)||j.$invalid)&&(i.activeDate=a,i.refreshView())})):this.activeDate=new Date,a.isActive=function(b){return 0===i.compare(b.date,i.activeDate)?(a.activeDateId=b.uid,!0):!1},this.init=function(a){j=a,j.$render=function(){i.render()}},this.render=function(){if(j.$viewValue){var a=new Date(j.$viewValue),b=!isNaN(a);b?this.activeDate=a:h||e.error('Datepicker directive: "ng-model" value must be a Date object, a number of milliseconds since 01.01.1970 or a string representing an RFC2822 or ISO 8601 date.')}this.refreshView()},this.refreshView=function(){if(this.element){this._refreshView();var a=j.$viewValue?new Date(j.$viewValue):null;j.$setValidity("dateDisabled",!a||this.element&&!this.isDisabled(a))}},this.createDateObject=function(a,b){var c=j.$viewValue?new Date(j.$viewValue):null;return{date:a,label:f(a,b),selected:c&&0===this.compare(a,c),disabled:this.isDisabled(a),current:0===this.compare(a,new Date),customClass:this.customClass(a)}},this.isDisabled=function(c){return this.minDate&&this.compare(c,this.minDate)<0||this.maxDate&&this.compare(c,this.maxDate)>0||b.dateDisabled&&a.dateDisabled({date:c,mode:a.datepickerMode})},this.customClass=function(b){return a.customClass({date:b,mode:a.datepickerMode})},this.split=function(a,b){for(var c=[];a.length>0;)c.push(a.splice(0,b));return c},this.fixTimeZone=function(a){var b=a.getHours();a.setHours(23===b?b+2:0)},a.select=function(b){if(a.datepickerMode===i.minMode){var c=j.$viewValue?new Date(j.$viewValue):new Date(0,0,0,0,0,0,0);c.setFullYear(b.getFullYear(),b.getMonth(),b.getDate()),j.$setViewValue(c),j.$render()}else i.activeDate=b,a.datepickerMode=i.modes[i.modes.indexOf(a.datepickerMode)-1]},a.move=function(a){var b=i.activeDate.getFullYear()+a*(i.step.years||0),c=i.activeDate.getMonth()+a*(i.step.months||0);i.activeDate.setFullYear(b,c,1),i.refreshView()},a.toggleMode=function(b){b=b||1,a.datepickerMode===i.maxMode&&1===b||a.datepickerMode===i.minMode&&-1===b||(a.datepickerMode=i.modes[i.modes.indexOf(a.datepickerMode)+b])},a.keys={13:"enter",32:"space",33:"pageup",34:"pagedown",35:"end",36:"home",37:"left",38:"up",39:"right",40:"down"};var k=function(){i.element[0].focus()};a.$on("uib:datepicker.focus",k),a.keydown=function(b){var c=a.keys[b.which];if(c&&!b.shiftKey&&!b.altKey)if(b.preventDefault(),i.shortcutPropagation||b.stopPropagation(),"enter"===c||"space"===c){if(i.isDisabled(i.activeDate))return;a.select(i.activeDate)}else!b.ctrlKey||"up"!==c&&"down"!==c?(i.handleKeyDown(c,b),i.refreshView()):a.toggleMode("up"===c?1:-1)}}]).controller("UibDaypickerController",["$scope","$element","dateFilter",function(a,b,c){function d(a,b){return 1!==b||a%4!==0||a%100===0&&a%400!==0?f[b]:29}function e(a){var b=new Date(a);b.setDate(b.getDate()+4-(b.getDay()||7));var c=b.getTime();return b.setMonth(0),b.setDate(1),Math.floor(Math.round((c-b)/864e5)/7)+1}var f=[31,28,31,30,31,30,31,31,30,31,30,31];this.step={months:1},this.element=b,this.init=function(b){angular.extend(b,this),a.showWeeks=b.showWeeks,b.refreshView()},this.getDates=function(a,b){for(var c,d=new Array(b),e=new Date(a),f=0;b>f;)c=new Date(e),this.fixTimeZone(c),d[f++]=c,e.setDate(e.getDate()+1);return d},this._refreshView=function(){var b=this.activeDate.getFullYear(),d=this.activeDate.getMonth(),f=new Date(b,d,1),g=this.startingDay-f.getDay(),h=g>0?7-g:-g,i=new Date(f);h>0&&i.setDate(-h+1);for(var j=this.getDates(i,42),k=0;42>k;k++)j[k]=angular.extend(this.createDateObject(j[k],this.formatDay),{secondary:j[k].getMonth()!==d,uid:a.uniqueId+"-"+k});a.labels=new Array(7);for(var l=0;7>l;l++)a.labels[l]={abbr:c(j[l].date,this.formatDayHeader),full:c(j[l].date,"EEEE")};if(a.title=c(this.activeDate,this.formatDayTitle),a.rows=this.split(j,7),a.showWeeks){a.weekNumbers=[];for(var m=(11-this.startingDay)%7,n=a.rows.length,o=0;n>o;o++)a.weekNumbers.push(e(a.rows[o][m].date))}},this.compare=function(a,b){return new Date(a.getFullYear(),a.getMonth(),a.getDate())-new Date(b.getFullYear(),b.getMonth(),b.getDate())},this.handleKeyDown=function(a,b){var c=this.activeDate.getDate();if("left"===a)c-=1;else if("up"===a)c-=7;else if("right"===a)c+=1;else if("down"===a)c+=7;else if("pageup"===a||"pagedown"===a){var e=this.activeDate.getMonth()+("pageup"===a?-1:1);this.activeDate.setMonth(e,1),c=Math.min(d(this.activeDate.getFullYear(),this.activeDate.getMonth()),c)}else"home"===a?c=1:"end"===a&&(c=d(this.activeDate.getFullYear(),this.activeDate.getMonth()));this.activeDate.setDate(c)}}]).controller("UibMonthpickerController",["$scope","$element","dateFilter",function(a,b,c){this.step={years:1},this.element=b,this.init=function(a){angular.extend(a,this),a.refreshView()},this._refreshView=function(){for(var b,d=new Array(12),e=this.activeDate.getFullYear(),f=0;12>f;f++)b=new Date(e,f,1),this.fixTimeZone(b),d[f]=angular.extend(this.createDateObject(b,this.formatMonth),{uid:a.uniqueId+"-"+f});a.title=c(this.activeDate,this.formatMonthTitle),a.rows=this.split(d,3)},this.compare=function(a,b){return new Date(a.getFullYear(),a.getMonth())-new Date(b.getFullYear(),b.getMonth())},this.handleKeyDown=function(a,b){var c=this.activeDate.getMonth();if("left"===a)c-=1;else if("up"===a)c-=3;else if("right"===a)c+=1;else if("down"===a)c+=3;else if("pageup"===a||"pagedown"===a){var d=this.activeDate.getFullYear()+("pageup"===a?-1:1);this.activeDate.setFullYear(d)}else"home"===a?c=0:"end"===a&&(c=11);this.activeDate.setMonth(c)}}]).controller("UibYearpickerController",["$scope","$element","dateFilter",function(a,b,c){function d(a){return parseInt((a-1)/e,10)*e+1}var e;this.element=b,this.yearpickerInit=function(){e=this.yearRange,this.step={years:e}},this._refreshView=function(){for(var b,c=new Array(e),f=0,g=d(this.activeDate.getFullYear());e>f;f++)b=new Date(g+f,0,1),this.fixTimeZone(b),c[f]=angular.extend(this.createDateObject(b,this.formatYear),{uid:a.uniqueId+"-"+f});a.title=[c[0].label,c[e-1].label].join(" - "),a.rows=this.split(c,5)},this.compare=function(a,b){return a.getFullYear()-b.getFullYear()},this.handleKeyDown=function(a,b){var c=this.activeDate.getFullYear();"left"===a?c-=1:"up"===a?c-=5:"right"===a?c+=1:"down"===a?c+=5:"pageup"===a||"pagedown"===a?c+=("pageup"===a?-1:1)*this.step.years:"home"===a?c=d(this.activeDate.getFullYear()):"end"===a&&(c=d(this.activeDate.getFullYear())+e-1),this.activeDate.setFullYear(c)}}]).directive("uibDatepicker",function(){return{replace:!0,templateUrl:function(a,b){return b.templateUrl||"template/datepicker/datepicker.html"},scope:{datepickerMode:"=?",dateDisabled:"&",customClass:"&",shortcutPropagation:"&?"},require:["uibDatepicker","^ngModel"],controller:"UibDatepickerController",controllerAs:"datepicker",link:function(a,b,c,d){var e=d[0],f=d[1];e.init(f)}}}).directive("uibDaypicker",function(){return{replace:!0,templateUrl:"template/datepicker/day.html",require:["^?uibDatepicker","uibDaypicker","^?datepicker"],controller:"UibDaypickerController",link:function(a,b,c,d){var e=d[0]||d[2],f=d[1];f.init(e)}}}).directive("uibMonthpicker",function(){return{replace:!0,templateUrl:"template/datepicker/month.html",require:["^?uibDatepicker","uibMonthpicker","^?datepicker"],controller:"UibMonthpickerController",link:function(a,b,c,d){var e=d[0]||d[2],f=d[1];f.init(e)}}}).directive("uibYearpicker",function(){return{replace:!0,templateUrl:"template/datepicker/year.html",require:["^?uibDatepicker","uibYearpicker","^?datepicker"],controller:"UibYearpickerController",link:function(a,b,c,d){var e=d[0]||d[2];angular.extend(e,d[1]),e.yearpickerInit(),e.refreshView()}}}).constant("uibDatepickerPopupConfig",{datepickerPopup:"yyyy-MM-dd",datepickerPopupTemplateUrl:"template/datepicker/popup.html",datepickerTemplateUrl:"template/datepicker/datepicker.html",html5Types:{date:"yyyy-MM-dd","datetime-local":"yyyy-MM-ddTHH:mm:ss.sss",month:"yyyy-MM"},currentText:"今日",clearText:"清除",closeText:"关闭",closeOnDateSelection:!0,appendToBody:!1,showButtonBar:!0,onOpenFocus:!0}).controller("UibDatepickerPopupController",["$scope","$element","$attrs","$compile","$parse","$document","$rootScope","$uibPosition","dateFilter","uibDateParser","uibDatepickerPopupConfig","$timeout",function(a,b,c,d,e,f,g,h,i,j,k,l){function m(a){return a.replace(/([A-Z])/g,function(a){ |
| 9 | return"-"+a.toLowerCase()})}function n(b){if(angular.isNumber(b)&&(b=new Date(b)),b){if(angular.isDate(b)&&!isNaN(b))return b;if(angular.isString(b)){var c=j.parse(b,r,a.date);return isNaN(c)?void 0:c}return void 0}return null}function o(a,b){var d=a||b;if(!c.ngRequired&&!d)return!0;if(angular.isNumber(d)&&(d=new Date(d)),d){if(angular.isDate(d)&&!isNaN(d))return!0;if(angular.isString(d)){var e=j.parse(d,r);return!isNaN(e)}return!1}return!0}function p(c){var d=A[0],e=b[0].contains(c.target),f=void 0!==d.contains&&d.contains(c.target);!a.isOpen||e||f||a.$apply(function(){a.isOpen=!1})}function q(c){27===c.which&&a.isOpen?(c.preventDefault(),c.stopPropagation(),a.$apply(function(){a.isOpen=!1}),b[0].focus()):40!==c.which||a.isOpen||(c.preventDefault(),c.stopPropagation(),a.$apply(function(){a.isOpen=!0}))}var r,s,t,u,v,w,x,y,z,A,B={},C=!1;a.watchData={},this.init=function(h){if(z=h,s=angular.isDefined(c.closeOnDateSelection)?a.$parent.$eval(c.closeOnDateSelection):k.closeOnDateSelection,t=angular.isDefined(c.datepickerAppendToBody)?a.$parent.$eval(c.datepickerAppendToBody):k.appendToBody,u=angular.isDefined(c.onOpenFocus)?a.$parent.$eval(c.onOpenFocus):k.onOpenFocus,v=angular.isDefined(c.datepickerPopupTemplateUrl)?c.datepickerPopupTemplateUrl:k.datepickerPopupTemplateUrl,w=angular.isDefined(c.datepickerTemplateUrl)?c.datepickerTemplateUrl:k.datepickerTemplateUrl,a.showButtonBar=angular.isDefined(c.showButtonBar)?a.$parent.$eval(c.showButtonBar):k.showButtonBar,k.html5Types[c.type]?(r=k.html5Types[c.type],C=!0):(r=c.datepickerPopup||k.datepickerPopup,c.$observe("uibDatepickerPopup",function(a,b){var c=a||k.datepickerPopup;if(c!==r&&(r=c,z.$modelValue=null,!r))throw new Error("uibDatepickerPopup must have a date format specified.")})),!r)throw new Error("uibDatepickerPopup must have a date format specified.");if(C&&c.datepickerPopup)throw new Error("HTML5 date input types do not support custom formats.");if(x=angular.element("<div uib-datepicker-popup-wrap><div uib-datepicker></div></div>"),x.attr({"ng-model":"date","ng-change":"dateSelection(date)","template-url":v}),y=angular.element(x.children()[0]),y.attr("template-url",w),C&&"month"===c.type&&(y.attr("datepicker-mode",'"month"'),y.attr("min-mode","month")),c.datepickerOptions){var l=a.$parent.$eval(c.datepickerOptions);l&&l.initDate&&(a.initDate=l.initDate,y.attr("init-date","initDate"),delete l.initDate),angular.forEach(l,function(a,b){y.attr(m(b),a)})}angular.forEach(["minMode","maxMode","minDate","maxDate","datepickerMode","initDate","shortcutPropagation"],function(b){if(c[b]){var d=e(c[b]);if(a.$parent.$watch(d,function(c){a.watchData[b]=c,("minDate"===b||"maxDate"===b)&&(B[b]=new Date(c))}),y.attr(m(b),"watchData."+b),"datepickerMode"===b){var f=d.assign;a.$watch("watchData."+b,function(b,c){angular.isFunction(f)&&b!==c&&f(a.$parent,b)})}}}),c.dateDisabled&&y.attr("date-disabled","dateDisabled({ date: date, mode: mode })"),c.showWeeks&&y.attr("show-weeks",c.showWeeks),c.customClass&&y.attr("custom-class","customClass({ date: date, mode: mode })"),C?z.$formatters.push(function(b){return a.date=b,b}):(z.$$parserName="date",z.$validators.date=o,z.$parsers.unshift(n),z.$formatters.push(function(b){return a.date=b,z.$isEmpty(b)?b:i(b,r)})),z.$viewChangeListeners.push(function(){a.date=j.parse(z.$viewValue,r,a.date)}),b.bind("keydown",q),A=d(x)(a),x.remove(),t?f.find("body").append(A):b.after(A),a.$on("$destroy",function(){a.isOpen===!0&&(g.$$phase||a.$apply(function(){a.isOpen=!1})),A.remove(),b.unbind("keydown",q),f.unbind("click",p)})},a.getText=function(b){return a[b+"Text"]||k[b+"Text"]},a.isDisabled=function(b){return"today"===b&&(b=new Date),a.watchData.minDate&&a.compare(b,B.minDate)<0||a.watchData.maxDate&&a.compare(b,B.maxDate)>0},a.compare=function(a,b){return new Date(a.getFullYear(),a.getMonth(),a.getDate())-new Date(b.getFullYear(),b.getMonth(),b.getDate())},a.dateSelection=function(c){angular.isDefined(c)&&(a.date=c);var d=a.date?i(a.date,r):null;b.val(d),z.$setViewValue(d),s&&(a.isOpen=!1,b[0].focus())},a.keydown=function(c){27===c.which&&(a.isOpen=!1,b[0].focus())},a.select=function(b){if("today"===b){var c=new Date;angular.isDate(a.date)?(b=new Date(a.date),b.setFullYear(c.getFullYear(),c.getMonth(),c.getDate())):b=new Date(c.setHours(0,0,0,0))}a.dateSelection(b)},a.close=function(){a.isOpen=!1,b[0].focus()},a.$watch("isOpen",function(c){c?(a.position=t?h.offset(b):h.position(b),a.position.top=a.position.top+b.prop("offsetHeight"),l(function(){u&&a.$broadcast("uib:datepicker.focus"),f.bind("click",p)},0,!1)):f.unbind("click",p)})}]).directive("uibDatepickerPopup",function(){return{require:["ngModel","uibDatepickerPopup"],controller:"UibDatepickerPopupController",scope:{isOpen:"=?",currentText:"@",clearText:"@",closeText:"@",dateDisabled:"&",customClass:"&"},link:function(a,b,c,d){var e=d[0],f=d[1];f.init(e)}}}).directive("uibDatepickerPopupWrap",function(){return{replace:!0,transclude:!0,templateUrl:function(a,b){return b.templateUrl||"template/datepicker/popup.html"}}}),angular.module("ui.bootstrap.datepicker").value("$datepickerSuppressWarning",!1).controller("DatepickerController",["$scope","$attrs","$log","$datepickerSuppressWarning","$controller",function(a,b,c,d,e){return d||c.warn("DatepickerController is now deprecated. Use UibDatepickerController instead."),e("UibDatepickerController",{$scope:a,$attrs:b})}]).directive("datepicker",["$log","$datepickerSuppressWarning",function(a,b){return{replace:!0,templateUrl:function(a,b){return b.templateUrl||"template/datepicker/datepicker.html"},scope:{datepickerMode:"=?",dateDisabled:"&",customClass:"&",shortcutPropagation:"&?"},require:["datepicker","^ngModel"],controller:"DatepickerController",controllerAs:"datepicker",link:function(c,d,e,f){b||a.warn("datepicker is now deprecated. Use uib-datepicker instead.");var g=f[0],h=f[1];g.init(h)}}}]).directive("daypicker",["$log","$datepickerSuppressWarning",function(a,b){return{replace:!0,templateUrl:"template/datepicker/day.html",require:["^datepicker","daypicker"],controller:"UibDaypickerController",link:function(c,d,e,f){b||a.warn("daypicker is now deprecated. Use uib-daypicker instead.");var g=f[0],h=f[1];h.init(g)}}}]).directive("monthpicker",["$log","$datepickerSuppressWarning",function(a,b){return{replace:!0,templateUrl:"template/datepicker/month.html",require:["^datepicker","monthpicker"],controller:"UibMonthpickerController",link:function(c,d,e,f){b||a.warn("monthpicker is now deprecated. Use uib-monthpicker instead.");var g=f[0],h=f[1];h.init(g)}}}]).directive("yearpicker",["$log","$datepickerSuppressWarning",function(a,b){return{replace:!0,templateUrl:"template/datepicker/year.html",require:["^datepicker","yearpicker"],controller:"UibYearpickerController",link:function(c,d,e,f){b||a.warn("yearpicker is now deprecated. Use uib-yearpicker instead.");var g=f[0];angular.extend(g,f[1]),g.yearpickerInit(),g.refreshView()}}}]).directive("datepickerPopup",["$log","$datepickerSuppressWarning",function(a,b){return{require:["ngModel","datepickerPopup"],controller:"UibDatepickerPopupController",scope:{isOpen:"=?",currentText:"@",clearText:"@",closeText:"@",dateDisabled:"&",customClass:"&"},link:function(c,d,e,f){b||a.warn("datepicker-popup is now deprecated. Use uib-datepicker-popup instead.");var g=f[0],h=f[1];h.init(g)}}}]).directive("datepickerPopupWrap",["$log","$datepickerSuppressWarning",function(a,b){return{replace:!0,transclude:!0,templateUrl:function(a,b){return b.templateUrl||"template/datepicker/popup.html"},link:function(){b||a.warn("datepicker-popup-wrap is now deprecated. Use uib-datepicker-popup-wrap instead.")}}}]),angular.module("ui.bootstrap.dropdown",["ui.bootstrap.position"]).constant("uibDropdownConfig",{openClass:"open"}).service("uibDropdownService",["$document","$rootScope",function(a,b){var c=null;this.open=function(b){c||(a.bind("click",d),a.bind("keydown",e)),c&&c!==b&&(c.isOpen=!1),c=b},this.close=function(b){c===b&&(c=null,a.unbind("click",d),a.unbind("keydown",e))};var d=function(a){if(c&&(!a||"disabled"!==c.getAutoClose())){var d=c.getToggleElement();if(!(a&&d&&d[0].contains(a.target))){var e=c.getDropdownElement();a&&"outsideClick"===c.getAutoClose()&&e&&e[0].contains(a.target)||(c.isOpen=!1,b.$$phase||c.$apply())}}},e=function(a){27===a.which?(c.focusToggleElement(),d()):c.isKeynavEnabled()&&/(38|40)/.test(a.which)&&c.isOpen&&(a.preventDefault(),a.stopPropagation(),c.focusDropdownEntry(a.which))}}]).controller("UibDropdownController",["$scope","$element","$attrs","$parse","uibDropdownConfig","uibDropdownService","$animate","$uibPosition","$document","$compile","$templateRequest",function(a,b,c,d,e,f,g,h,i,j,k){var l,m,n=this,o=a.$new(),p=e.openClass,q=angular.noop,r=c.onToggle?d(c.onToggle):angular.noop,s=!1,t=!1;b.addClass("dropdown"),this.init=function(){c.isOpen&&(m=d(c.isOpen),q=m.assign,a.$watch(m,function(a){o.isOpen=!!a})),s=angular.isDefined(c.dropdownAppendToBody),t=angular.isDefined(c.uibKeyboardNav),s&&n.dropdownMenu&&(i.find("body").append(n.dropdownMenu),b.on("$destroy",function(){n.dropdownMenu.remove()}))},this.toggle=function(a){return o.isOpen=arguments.length?!!a:!o.isOpen},this.isOpen=function(){return o.isOpen},o.getToggleElement=function(){return n.toggleElement},o.getAutoClose=function(){return c.autoClose||"always"},o.getElement=function(){return b},o.isKeynavEnabled=function(){return t},o.focusDropdownEntry=function(a){var c=n.dropdownMenu?angular.element(n.dropdownMenu).find("a"):angular.element(b).find("ul").eq(0).find("a");switch(a){case 40:angular.isNumber(n.selectedOption)?n.selectedOption=n.selectedOption===c.length-1?n.selectedOption:n.selectedOption+1:n.selectedOption=0;break;case 38:angular.isNumber(n.selectedOption)?n.selectedOption=0===n.selectedOption?0:n.selectedOption-1:n.selectedOption=c.length-1}c[n.selectedOption].focus()},o.getDropdownElement=function(){return n.dropdownMenu},o.focusToggleElement=function(){n.toggleElement&&n.toggleElement[0].focus()},o.$watch("isOpen",function(c,d){if(s&&n.dropdownMenu){var e=h.positionElements(b,n.dropdownMenu,"bottom-left",!0),i={top:e.top+"px",display:c?"block":"none"},m=n.dropdownMenu.hasClass("dropdown-menu-right");m?(i.left="auto",i.right=window.innerWidth-(e.left+b.prop("offsetWidth"))+"px"):(i.left=e.left+"px",i.right="auto"),n.dropdownMenu.css(i)}if(g[c?"addClass":"removeClass"](b,p).then(function(){angular.isDefined(c)&&c!==d&&r(a,{open:!!c})}),c)n.dropdownMenuTemplateUrl&&k(n.dropdownMenuTemplateUrl).then(function(a){l=o.$new(),j(a.trim())(l,function(a){var b=a;n.dropdownMenu.replaceWith(b),n.dropdownMenu=b})}),o.focusToggleElement(),f.open(o);else{if(n.dropdownMenuTemplateUrl){l&&l.$destroy();var t=angular.element('<ul class="dropdown-menu"></ul>');n.dropdownMenu.replaceWith(t),n.dropdownMenu=t}f.close(o),n.selectedOption=null}angular.isFunction(q)&&q(a,c)}),a.$on("$locationChangeSuccess",function(){"disabled"!==o.getAutoClose()&&(o.isOpen=!1)});var u=a.$on("$destroy",function(){o.$destroy()});o.$on("$destroy",u)}]).directive("uibDropdown",function(){return{controller:"UibDropdownController",link:function(a,b,c,d){d.init()}}}).directive("uibDropdownMenu",function(){return{restrict:"AC",require:"?^uibDropdown",link:function(a,b,c,d){if(d&&!angular.isDefined(c.dropdownNested)){b.addClass("dropdown-menu");var e=c.templateUrl;e&&(d.dropdownMenuTemplateUrl=e),d.dropdownMenu||(d.dropdownMenu=b)}}}}).directive("uibKeyboardNav",function(){return{restrict:"A",require:"?^uibDropdown",link:function(a,b,c,d){b.bind("keydown",function(a){if(-1!==[38,40].indexOf(a.which)){a.preventDefault(),a.stopPropagation();var b=d.dropdownMenu.find("a");switch(a.which){case 40:angular.isNumber(d.selectedOption)?d.selectedOption=d.selectedOption===b.length-1?d.selectedOption:d.selectedOption+1:d.selectedOption=0;break;case 38:angular.isNumber(d.selectedOption)?d.selectedOption=0===d.selectedOption?0:d.selectedOption-1:d.selectedOption=b.length-1}b[d.selectedOption].focus()}})}}}).directive("uibDropdownToggle",function(){return{require:"?^uibDropdown",link:function(a,b,c,d){if(d){b.addClass("dropdown-toggle"),d.toggleElement=b;var e=function(e){e.preventDefault(),b.hasClass("disabled")||c.disabled||a.$apply(function(){d.toggle()})};b.bind("click",e),b.attr({"aria-haspopup":!0,"aria-expanded":!1}),a.$watch(d.isOpen,function(a){b.attr("aria-expanded",!!a)}),a.$on("$destroy",function(){b.unbind("click",e)})}}}}),angular.module("ui.bootstrap.dropdown").value("$dropdownSuppressWarning",!1).service("dropdownService",["$log","$dropdownSuppressWarning","uibDropdownService",function(a,b,c){b||a.warn("dropdownService is now deprecated. Use uibDropdownService instead."),angular.extend(this,c)}]).controller("DropdownController",["$scope","$element","$attrs","$log","$dropdownSuppressWarning","$controller",function(a,b,c,d,e,f){return e||d.warn("DropdownController is now deprecated. Use UibDropdownController instead."),f("UibDropdownController",{$scope:a,$element:b,$attrs:c})}]).directive("dropdown",["$log","$dropdownSuppressWarning",function(a,b){return{controller:"DropdownController",link:function(c,d,e,f){b||a.warn("dropdown is now deprecated. Use uib-dropdown instead."),f.init()}}}]).directive("dropdownMenu",["$log","$dropdownSuppressWarning",function(a,b){return{restrict:"AC",require:"?^dropdown",link:function(c,d,e,f){if(f){b||a.warn("dropdown-menu is now deprecated. Use uib-dropdown-menu instead."),d.addClass("dropdown-menu");var g=e.templateUrl;g&&(f.dropdownMenuTemplateUrl=g),f.dropdownMenu||(f.dropdownMenu=d)}}}}]).directive("keyboardNav",["$log","$dropdownSuppressWarning",function(a,b){return{restrict:"A",require:"?^dropdown",link:function(c,d,e,f){b||a.warn("keyboard-nav is now deprecated. Use uib-keyboard-nav instead."),d.bind("keydown",function(a){if(-1!==[38,40].indexOf(a.which)){a.preventDefault(),a.stopPropagation();var b=f.dropdownMenu.find("a");switch(a.which){case 40:angular.isNumber(f.selectedOption)?f.selectedOption=f.selectedOption===b.length-1?f.selectedOption:f.selectedOption+1:f.selectedOption=0;break;case 38:angular.isNumber(f.selectedOption)?f.selectedOption=0===f.selectedOption?0:f.selectedOption-1:f.selectedOption=b.length-1}b[f.selectedOption].focus()}})}}}]).directive("dropdownToggle",["$log","$dropdownSuppressWarning",function(a,b){return{require:"?^dropdown",link:function(c,d,e,f){if(b||a.warn("dropdown-toggle is now deprecated. Use uib-dropdown-toggle instead."),f){d.addClass("dropdown-toggle"),f.toggleElement=d;var g=function(a){a.preventDefault(),d.hasClass("disabled")||e.disabled||c.$apply(function(){f.toggle()})};d.bind("click",g),d.attr({"aria-haspopup":!0,"aria-expanded":!1}),c.$watch(f.isOpen,function(a){d.attr("aria-expanded",!!a)}),c.$on("$destroy",function(){d.unbind("click",g)})}}}}]),angular.module("ui.bootstrap.stackedMap",[]).factory("$$stackedMap",function(){return{createNew:function(){var a=[];return{add:function(b,c){a.push({key:b,value:c})},get:function(b){for(var c=0;c<a.length;c++)if(b==a[c].key)return a[c]},keys:function(){for(var b=[],c=0;c<a.length;c++)b.push(a[c].key);return b},top:function(){return a[a.length-1]},remove:function(b){for(var c=-1,d=0;d<a.length;d++)if(b==a[d].key){c=d;break}return a.splice(c,1)[0]},removeTop:function(){return a.splice(a.length-1,1)[0]},length:function(){return a.length}}}}}),angular.module("ui.bootstrap.modal",["ui.bootstrap.stackedMap"]).factory("$$multiMap",function(){return{createNew:function(){var a={};return{entries:function(){return Object.keys(a).map(function(b){return{key:b,value:a[b]}})},get:function(b){return a[b]},hasKey:function(b){return!!a[b]},keys:function(){return Object.keys(a)},put:function(b,c){a[b]||(a[b]=[]),a[b].push(c)},remove:function(b,c){var d=a[b];if(d){var e=d.indexOf(c);-1!==e&&d.splice(e,1),d.length||delete a[b]}}}}}}).directive("uibModalBackdrop",["$animate","$injector","$uibModalStack",function(a,b,c){function d(b,d,f){d.addClass("modal-backdrop"),f.modalInClass&&(e?e(d,{addClass:f.modalInClass}).start():a.addClass(d,f.modalInClass),b.$on(c.NOW_CLOSING_EVENT,function(b,c){var g=c();e?e(d,{removeClass:f.modalInClass}).start().then(g):a.removeClass(d,f.modalInClass).then(g)}))}var e=null;return b.has("$animateCss")&&(e=b.get("$animateCss")),{replace:!0,templateUrl:"template/modal/backdrop.html",compile:function(a,b){return a.addClass(b.backdropClass),d}}}]).directive("uibModalWindow",["$uibModalStack","$q","$animate","$injector",function(a,b,c,d){var e=null;return d.has("$animateCss")&&(e=d.get("$animateCss")),{scope:{index:"@"},replace:!0,transclude:!0,templateUrl:function(a,b){return b.templateUrl||"template/modal/window.html"},link:function(d,f,g){f.addClass(g.windowClass||""),f.addClass(g.windowTopClass||""),d.size=g.size,d.close=function(b){var c=a.getTop();c&&c.value.backdrop&&"static"!==c.value.backdrop&&b.target===b.currentTarget&&(b.preventDefault(),b.stopPropagation(),a.dismiss(c.key,"backdrop click"))},f.on("click",d.close),d.$isRendered=!0;var h=b.defer();g.$observe("modalRender",function(a){"true"==a&&h.resolve()}),h.promise.then(function(){var h=null;g.modalInClass&&(h=e?e(f,{addClass:g.modalInClass}).start():c.addClass(f,g.modalInClass),d.$on(a.NOW_CLOSING_EVENT,function(a,b){var d=b();e?e(f,{removeClass:g.modalInClass}).start().then(d):c.removeClass(f,g.modalInClass).then(d)})),b.when(h).then(function(){var a=f[0].querySelectorAll("[autofocus]");a.length?a[0].focus():f[0].focus()});var i=a.getTop();i&&a.modalRendered(i.key)})}}}]).directive("uibModalAnimationClass",[function(){return{compile:function(a,b){b.modalAnimation&&a.addClass(b.uibModalAnimationClass)}}}]).directive("uibModalTransclude",function(){return{link:function(a,b,c,d,e){e(a.$parent,function(a){b.empty(),b.append(a)})}}}).factory("$uibModalStack",["$animate","$timeout","$document","$compile","$rootScope","$q","$injector","$$multiMap","$$stackedMap",function(a,b,c,d,e,f,g,h,i){function j(){for(var a=-1,b=u.keys(),c=0;c<b.length;c++)u.get(b[c]).value.backdrop&&(a=c);return a}function k(a,b){var d=c.find("body").eq(0),e=u.get(a).value;u.remove(a),n(e.modalDomEl,e.modalScope,function(){var b=e.openedClass||t;v.remove(b,a),d.toggleClass(b,v.hasKey(b)),l(!0)}),m(),b&&b.focus?b.focus():d.focus()}function l(a){var b;u.length()>0&&(b=u.top().value,b.modalDomEl.toggleClass(b.windowTopClass||"",a))}function m(){if(q&&-1==j()){var a=r;n(q,r,function(){a=null}),q=void 0,r=void 0}}function n(b,c,d){function e(){e.done||(e.done=!0,p?p(b,{event:"leave"}).start().then(function(){b.remove()}):a.leave(b),c.$destroy(),d&&d())}var g,h=null,i=function(){return g||(g=f.defer(),h=g.promise),function(){g.resolve()}};return c.$broadcast(w.NOW_CLOSING_EVENT,i),f.when(h).then(e)}function o(a,b,c){return!a.value.modalScope.$broadcast("modal.closing",b,c).defaultPrevented}var p=null;g.has("$animateCss")&&(p=g.get("$animateCss"));var q,r,s,t="modal-open",u=i.createNew(),v=h.createNew(),w={NOW_CLOSING_EVENT:"modal.stack.now-closing"},x=0,y="a[href], area[href], input:not([disabled]), button:not([disabled]),select:not([disabled]), textarea:not([disabled]), iframe, object, embed, *[tabindex], *[contenteditable=true]";return e.$watch(j,function(a){r&&(r.index=a)}),c.bind("keydown",function(a){if(a.isDefaultPrevented())return a;var b=u.top();if(b&&b.value.keyboard)switch(a.which){case 27:a.preventDefault(),e.$apply(function(){w.dismiss(b.key,"escape key press")});break;case 9:w.loadFocusElementList(b);var c=!1;a.shiftKey?w.isFocusInFirstItem(a)&&(c=w.focusLastFocusableElement()):w.isFocusInLastItem(a)&&(c=w.focusFirstFocusableElement()),c&&(a.preventDefault(),a.stopPropagation())}}),w.open=function(a,b){var f=c[0].activeElement,g=b.openedClass||t;l(!1),u.add(a,{deferred:b.deferred,renderDeferred:b.renderDeferred,modalScope:b.scope,backdrop:b.backdrop,keyboard:b.keyboard,openedClass:b.openedClass,windowTopClass:b.windowTopClass}),v.put(g,a);var h=c.find("body").eq(0),i=j();if(i>=0&&!q){r=e.$new(!0),r.index=i;var k=angular.element('<div uib-modal-backdrop="modal-backdrop"></div>');k.attr("backdrop-class",b.backdropClass),b.animation&&k.attr("modal-animation","true"),q=d(k)(r),h.append(q)}var m=angular.element('<div uib-modal-window="modal-window"></div>');m.attr({"template-url":b.windowTemplateUrl,"window-class":b.windowClass,"window-top-class":b.windowTopClass,size:b.size,index:u.length()-1,animate:"animate"}).html(b.content),b.animation&&m.attr("modal-animation","true");var n=d(m)(b.scope);u.top().value.modalDomEl=n,u.top().value.modalOpener=f,h.append(n),h.addClass(g),w.clearFocusListCache()},w.close=function(a,b){var c=u.get(a);return c&&o(c,b,!0)?(c.value.modalScope.$$uibDestructionScheduled=!0,c.value.deferred.resolve(b),k(a,c.value.modalOpener),!0):!c},w.dismiss=function(a,b){var c=u.get(a);return c&&o(c,b,!1)?(c.value.modalScope.$$uibDestructionScheduled=!0,c.value.deferred.reject(b),k(a,c.value.modalOpener),!0):!c},w.dismissAll=function(a){for(var b=this.getTop();b&&this.dismiss(b.key,a);)b=this.getTop()},w.getTop=function(){return u.top()},w.modalRendered=function(a){var b=u.get(a);b&&b.value.renderDeferred.resolve()},w.focusFirstFocusableElement=function(){return s.length>0?(s[0].focus(),!0):!1},w.focusLastFocusableElement=function(){return s.length>0?(s[s.length-1].focus(),!0):!1},w.isFocusInFirstItem=function(a){return s.length>0?(a.target||a.srcElement)==s[0]:!1},w.isFocusInLastItem=function(a){return s.length>0?(a.target||a.srcElement)==s[s.length-1]:!1},w.clearFocusListCache=function(){s=[],x=0},w.loadFocusElementList=function(a){if((void 0===s||!s.length0)&&a){var b=a.value.modalDomEl;b&&b.length&&(s=b[0].querySelectorAll(y))}},w}]).provider("$uibModal",function(){var a={options:{animation:!0,backdrop:!0,keyboard:!0},$get:["$injector","$rootScope","$q","$templateRequest","$controller","$uibModalStack",function(b,c,d,e,f,g){function h(a){return a.template?d.when(a.template):e(angular.isFunction(a.templateUrl)?a.templateUrl():a.templateUrl)}function i(a){var c=[];return angular.forEach(a,function(a){angular.isFunction(a)||angular.isArray(a)?c.push(d.when(b.invoke(a))):angular.isString(a)?c.push(d.when(b.get(a))):c.push(d.when(a))}),c}var j={},k=null;return j.getPromiseChain=function(){return k},j.open=function(b){var e=d.defer(),j=d.defer(),l=d.defer(),m={result:e.promise,opened:j.promise,rendered:l.promise,close:function(a){return g.close(m,a)},dismiss:function(a){return g.dismiss(m,a)}};if(b=angular.extend({},a.options,b),b.resolve=b.resolve||{},!b.template&&!b.templateUrl)throw new Error("One of template or templateUrl options is required.");var n,o=d.all([h(b)].concat(i(b.resolve)));return n=k=d.all([k]).then(function(){return o},function(){return o}).then(function(a){var d=(b.scope||c).$new();d.$close=m.close,d.$dismiss=m.dismiss,d.$on("$destroy",function(){d.$$uibDestructionScheduled||d.$dismiss("$uibUnscheduledDestruction")});var h,i={},k=1;b.controller&&(i.$scope=d,i.$modalInstance=m,angular.forEach(b.resolve,function(b,c){i[c]=a[k++]}),h=f(b.controller,i),b.controllerAs&&(b.bindToController&&angular.extend(h,d),d[b.controllerAs]=h)),g.open(m,{scope:d,deferred:e,renderDeferred:l,content:a[0],animation:b.animation,backdrop:b.backdrop,keyboard:b.keyboard,backdropClass:b.backdropClass,windowTopClass:b.windowTopClass,windowClass:b.windowClass,windowTemplateUrl:b.windowTemplateUrl,size:b.size,openedClass:b.openedClass}),j.resolve(!0)},function(a){j.reject(a),e.reject(a)})["finally"](function(){k===n&&(k=null)}),m},j}]};return a}),angular.module("ui.bootstrap.modal").value("$modalSuppressWarning",!1).directive("modalBackdrop",["$animate","$injector","$modalStack","$log","$modalSuppressWarning",function(a,b,c,d,e){function f(b,f,h){e||d.warn("modal-backdrop is now deprecated. Use uib-modal-backdrop instead."),f.addClass("modal-backdrop"),h.modalInClass&&(g?g(f,{addClass:h.modalInClass}).start():a.addClass(f,h.modalInClass),b.$on(c.NOW_CLOSING_EVENT,function(b,c){var d=c();g?g(f,{removeClass:h.modalInClass}).start().then(d):a.removeClass(f,h.modalInClass).then(d)}))}var g=null;return b.has("$animateCss")&&(g=b.get("$animateCss")),{replace:!0,templateUrl:"template/modal/backdrop.html",compile:function(a,b){return a.addClass(b.backdropClass),f}}}]).directive("modalWindow",["$modalStack","$q","$animate","$injector","$log","$modalSuppressWarning",function(a,b,c,d,e,f){var g=null;return d.has("$animateCss")&&(g=d.get("$animateCss")),{scope:{index:"@"},replace:!0,transclude:!0,templateUrl:function(a,b){return b.templateUrl||"template/modal/window.html"},link:function(d,h,i){f||e.warn("modal-window is now deprecated. Use uib-modal-window instead."),h.addClass(i.windowClass||""),h.addClass(i.windowTopClass||""),d.size=i.size,d.close=function(b){var c=a.getTop();c&&c.value.backdrop&&"static"!==c.value.backdrop&&b.target===b.currentTarget&&(b.preventDefault(),b.stopPropagation(),a.dismiss(c.key,"backdrop click"))},h.on("click",d.close),d.$isRendered=!0;var j=b.defer();i.$observe("modalRender",function(a){"true"==a&&j.resolve()}),j.promise.then(function(){var e=null;i.modalInClass&&(e=g?g(h,{addClass:i.modalInClass}).start():c.addClass(h,i.modalInClass),d.$on(a.NOW_CLOSING_EVENT,function(a,b){var d=b();g?g(h,{removeClass:i.modalInClass}).start().then(d):c.removeClass(h,i.modalInClass).then(d)})),b.when(e).then(function(){var a=h[0].querySelectorAll("[autofocus]");a.length?a[0].focus():h[0].focus()});var f=a.getTop();f&&a.modalRendered(f.key)})}}}]).directive("modalAnimationClass",["$log","$modalSuppressWarning",function(a,b){return{compile:function(c,d){b||a.warn("modal-animation-class is now deprecated. Use uib-modal-animation-class instead."),d.modalAnimation&&c.addClass(d.modalAnimationClass)}}}]).directive("modalTransclude",["$log","$modalSuppressWarning",function(a,b){return{link:function(c,d,e,f,g){b||a.warn("modal-transclude is now deprecated. Use uib-modal-transclude instead."),g(c.$parent,function(a){d.empty(),d.append(a)})}}}]).service("$modalStack",["$animate","$timeout","$document","$compile","$rootScope","$q","$injector","$$multiMap","$$stackedMap","$uibModalStack","$log","$modalSuppressWarning",function(a,b,c,d,e,f,g,h,i,j,k,l){l||k.warn("$modalStack is now deprecated. Use $uibModalStack instead."),angular.extend(this,j)}]).provider("$modal",["$uibModalProvider",function(a){angular.extend(this,a),this.$get=["$injector","$log","$modalSuppressWarning",function(b,c,d){return d||c.warn("$modal is now deprecated. Use $uibModal instead."),b.invoke(a.$get)}]}]),angular.module("ui.bootstrap.pagination",[]).controller("UibPaginationController",["$scope","$attrs","$parse",function(a,b,c){var d=this,e={$setViewValue:angular.noop},f=b.numPages?c(b.numPages).assign:angular.noop;this.init=function(g,h){e=g,this.config=h,e.$render=function(){d.render()},b.itemsPerPage?a.$parent.$watch(c(b.itemsPerPage),function(b){d.itemsPerPage=parseInt(b,10),a.totalPages=d.calculateTotalPages()}):this.itemsPerPage=h.itemsPerPage,a.$watch("totalItems",function(){a.totalPages=d.calculateTotalPages()}),a.$watch("totalPages",function(b){f(a.$parent,b),a.page>b?a.selectPage(b):e.$render()})},this.calculateTotalPages=function(){var b=this.itemsPerPage<1?1:Math.ceil(a.totalItems/this.itemsPerPage);return Math.max(b||0,1)},this.render=function(){a.page=parseInt(e.$viewValue,10)||1},a.selectPage=function(b,c){c&&c.preventDefault();var d=!a.ngDisabled||!c;d&&a.page!==b&&b>0&&b<=a.totalPages&&(c&&c.target&&c.target.blur(),e.$setViewValue(b),e.$render())},a.getText=function(b){return a[b+"Text"]||d.config[b+"Text"]},a.noPrevious=function(){return 1===a.page},a.noNext=function(){return a.page===a.totalPages}}]).constant("uibPaginationConfig",{itemsPerPage:10,boundaryLinks:!1,directionLinks:!0,firstText:"First",previousText:"Previous",nextText:"Next",lastText:"Last",rotate:!0}).directive("uibPagination",["$parse","uibPaginationConfig",function(a,b){return{restrict:"EA",scope:{totalItems:"=",firstText:"@",previousText:"@",nextText:"@",lastText:"@",ngDisabled:"="},require:["uibPagination","?ngModel"],controller:"UibPaginationController",controllerAs:"pagination",templateUrl:function(a,b){return b.templateUrl||"template/pagination/pagination.html"},replace:!0,link:function(c,d,e,f){function g(a,b,c){return{number:a,text:b,active:c}}function h(a,b){var c=[],d=1,e=b,f=angular.isDefined(k)&&b>k;f&&(l?(d=Math.max(a-Math.floor(k/2),1),e=d+k-1,e>b&&(e=b,d=e-k+1)):(d=(Math.ceil(a/k)-1)*k+1,e=Math.min(d+k-1,b)));for(var h=d;e>=h;h++){var i=g(h,h,h===a);c.push(i)}if(f&&!l){if(d>1){var j=g(d-1,"...",!1);c.unshift(j)}if(b>e){var m=g(e+1,"...",!1);c.push(m)}}return c}var i=f[0],j=f[1];if(j){var k=angular.isDefined(e.maxSize)?c.$parent.$eval(e.maxSize):b.maxSize,l=angular.isDefined(e.rotate)?c.$parent.$eval(e.rotate):b.rotate;c.boundaryLinks=angular.isDefined(e.boundaryLinks)?c.$parent.$eval(e.boundaryLinks):b.boundaryLinks,c.directionLinks=angular.isDefined(e.directionLinks)?c.$parent.$eval(e.directionLinks):b.directionLinks,i.init(j,b),e.maxSize&&c.$parent.$watch(a(e.maxSize),function(a){k=parseInt(a,10),i.render()});var m=i.render;i.render=function(){m(),c.page>0&&c.page<=c.totalPages&&(c.pages=h(c.page,c.totalPages))}}}}}]).constant("uibPagerConfig",{itemsPerPage:10,previousText:"« Previous",nextText:"Next »",align:!0}).directive("uibPager",["uibPagerConfig",function(a){return{restrict:"EA",scope:{totalItems:"=",previousText:"@",nextText:"@",ngDisabled:"="},require:["uibPager","?ngModel"],controller:"UibPaginationController",controllerAs:"pagination",templateUrl:function(a,b){return b.templateUrl||"template/pagination/pager.html"},replace:!0,link:function(b,c,d,e){var f=e[0],g=e[1];g&&(b.align=angular.isDefined(d.align)?b.$parent.$eval(d.align):a.align,f.init(g,a))}}}]),angular.module("ui.bootstrap.pagination").value("$paginationSuppressWarning",!1).controller("PaginationController",["$scope","$attrs","$parse","$controller","$element","$log","$paginationSuppressWarning",function(a,b,c,d,e,f,g){return g||f.warn("PaginationController is now deprecated. Use UibPaginationController instead."),d("UibPaginationController",{$scope:a,$element:e,$attrs:b})}]).directive("pagination",["$parse","uibPaginationConfig","$log","$paginationSuppressWarning",function(a,b,c,d){return{restrict:"EA",scope:{totalItems:"=",firstText:"@",previousText:"@",nextText:"@",lastText:"@",ngDisabled:"="},require:["pagination","?ngModel"],controller:"PaginationController",controllerAs:"pagination",templateUrl:function(a,b){return b.templateUrl||"template/pagination/pagination.html"},replace:!0,link:function(e,f,g,h){function i(a,b,c){return{number:a,text:b,active:c}}function j(a,b){var c=[],d=1,e=b,f=angular.isDefined(m)&&b>m;f&&(n?(d=Math.max(a-Math.floor(m/2),1),e=d+m-1,e>b&&(e=b,d=e-m+1)):(d=(Math.ceil(a/m)-1)*m+1,e=Math.min(d+m-1,b)));for(var g=d;e>=g;g++){var h=i(g,g,g===a);c.push(h)}if(f&&!n){if(d>1){var j=i(d-1,"...",!1);c.unshift(j)}if(b>e){var k=i(e+1,"...",!1);c.push(k)}}return c}d||c.warn("pagination is now deprecated. Use uib-pagination instead.");var k=h[0],l=h[1];if(l){var m=angular.isDefined(g.maxSize)?e.$parent.$eval(g.maxSize):b.maxSize,n=angular.isDefined(g.rotate)?e.$parent.$eval(g.rotate):b.rotate;e.boundaryLinks=angular.isDefined(g.boundaryLinks)?e.$parent.$eval(g.boundaryLinks):b.boundaryLinks,e.directionLinks=angular.isDefined(g.directionLinks)?e.$parent.$eval(g.directionLinks):b.directionLinks,k.init(l,b),g.maxSize&&e.$parent.$watch(a(g.maxSize),function(a){m=parseInt(a,10),k.render()});var o=k.render;k.render=function(){o(),e.page>0&&e.page<=e.totalPages&&(e.pages=j(e.page,e.totalPages))}}}}}]).directive("pager",["uibPagerConfig","$log","$paginationSuppressWarning",function(a,b,c){return{restrict:"EA",scope:{totalItems:"=",previousText:"@",nextText:"@",ngDisabled:"="},require:["pager","?ngModel"],controller:"PaginationController",controllerAs:"pagination",templateUrl:function(a,b){return b.templateUrl||"template/pagination/pager.html"},replace:!0,link:function(d,e,f,g){c||b.warn("pager is now deprecated. Use uib-pager instead.");var h=g[0],i=g[1];i&&(d.align=angular.isDefined(f.align)?d.$parent.$eval(f.align):a.align,h.init(i,a)); | 9 | return"-"+a.toLowerCase()})}function n(b){if(angular.isNumber(b)&&(b=new Date(b)),b){if(angular.isDate(b)&&!isNaN(b))return b;if(angular.isString(b)){var c=j.parse(b,r,a.date);return isNaN(c)?void 0:c}return void 0}return null}function o(a,b){var d=a||b;if(!c.ngRequired&&!d)return!0;if(angular.isNumber(d)&&(d=new Date(d)),d){if(angular.isDate(d)&&!isNaN(d))return!0;if(angular.isString(d)){var e=j.parse(d,r);return!isNaN(e)}return!1}return!0}function p(c){var d=A[0],e=b[0].contains(c.target),f=void 0!==d.contains&&d.contains(c.target);!a.isOpen||e||f||a.$apply(function(){a.isOpen=!1})}function q(c){27===c.which&&a.isOpen?(c.preventDefault(),c.stopPropagation(),a.$apply(function(){a.isOpen=!1}),b[0].focus()):40!==c.which||a.isOpen||(c.preventDefault(),c.stopPropagation(),a.$apply(function(){a.isOpen=!0}))}var r,s,t,u,v,w,x,y,z,A,B={},C=!1;a.watchData={},this.init=function(h){if(z=h,s=angular.isDefined(c.closeOnDateSelection)?a.$parent.$eval(c.closeOnDateSelection):k.closeOnDateSelection,t=angular.isDefined(c.datepickerAppendToBody)?a.$parent.$eval(c.datepickerAppendToBody):k.appendToBody,u=angular.isDefined(c.onOpenFocus)?a.$parent.$eval(c.onOpenFocus):k.onOpenFocus,v=angular.isDefined(c.datepickerPopupTemplateUrl)?c.datepickerPopupTemplateUrl:k.datepickerPopupTemplateUrl,w=angular.isDefined(c.datepickerTemplateUrl)?c.datepickerTemplateUrl:k.datepickerTemplateUrl,a.showButtonBar=angular.isDefined(c.showButtonBar)?a.$parent.$eval(c.showButtonBar):k.showButtonBar,k.html5Types[c.type]?(r=k.html5Types[c.type],C=!0):(r=c.datepickerPopup||k.datepickerPopup,c.$observe("uibDatepickerPopup",function(a,b){var c=a||k.datepickerPopup;if(c!==r&&(r=c,z.$modelValue=null,!r))throw new Error("uibDatepickerPopup must have a date format specified.")})),!r)throw new Error("uibDatepickerPopup must have a date format specified.");if(C&&c.datepickerPopup)throw new Error("HTML5 date input types do not support custom formats.");if(x=angular.element("<div uib-datepicker-popup-wrap><div uib-datepicker></div></div>"),x.attr({"ng-model":"date","ng-change":"dateSelection(date)","template-url":v}),y=angular.element(x.children()[0]),y.attr("template-url",w),C&&"month"===c.type&&(y.attr("datepicker-mode",'"month"'),y.attr("min-mode","month")),c.datepickerOptions){var l=a.$parent.$eval(c.datepickerOptions);l&&l.initDate&&(a.initDate=l.initDate,y.attr("init-date","initDate"),delete l.initDate),angular.forEach(l,function(a,b){y.attr(m(b),a)})}angular.forEach(["minMode","maxMode","minDate","maxDate","datepickerMode","initDate","shortcutPropagation"],function(b){if(c[b]){var d=e(c[b]);if(a.$parent.$watch(d,function(c){a.watchData[b]=c,("minDate"===b||"maxDate"===b)&&(B[b]=new Date(c))}),y.attr(m(b),"watchData."+b),"datepickerMode"===b){var f=d.assign;a.$watch("watchData."+b,function(b,c){angular.isFunction(f)&&b!==c&&f(a.$parent,b)})}}}),c.dateDisabled&&y.attr("date-disabled","dateDisabled({ date: date, mode: mode })"),c.showWeeks&&y.attr("show-weeks",c.showWeeks),c.customClass&&y.attr("custom-class","customClass({ date: date, mode: mode })"),C?z.$formatters.push(function(b){return a.date=b,b}):(z.$$parserName="date",z.$validators.date=o,z.$parsers.unshift(n),z.$formatters.push(function(b){return a.date=b,z.$isEmpty(b)?b:i(b,r)})),z.$viewChangeListeners.push(function(){a.date=j.parse(z.$viewValue,r,a.date)}),b.bind("keydown",q),A=d(x)(a),x.remove(),t?f.find("body").append(A):b.after(A),a.$on("$destroy",function(){a.isOpen===!0&&(g.$$phase||a.$apply(function(){a.isOpen=!1})),A.remove(),b.unbind("keydown",q),f.unbind("click",p)})},a.getText=function(b){return a[b+"Text"]||k[b+"Text"]},a.isDisabled=function(b){return"today"===b&&(b=new Date),a.watchData.minDate&&a.compare(b,B.minDate)<0||a.watchData.maxDate&&a.compare(b,B.maxDate)>0},a.compare=function(a,b){return new Date(a.getFullYear(),a.getMonth(),a.getDate())-new Date(b.getFullYear(),b.getMonth(),b.getDate())},a.dateSelection=function(c){angular.isDefined(c)&&(a.date=c);var d=a.date?i(a.date,r):null;b.val(d),z.$setViewValue(d),s&&(a.isOpen=!1,b[0].focus())},a.keydown=function(c){27===c.which&&(a.isOpen=!1,b[0].focus())},a.select=function(b){if("today"===b){var c=new Date;angular.isDate(a.date)?(b=new Date(a.date),b.setFullYear(c.getFullYear(),c.getMonth(),c.getDate())):b=new Date(c.setHours(0,0,0,0))}a.dateSelection(b)},a.close=function(){a.isOpen=!1,b[0].focus()},a.$watch("isOpen",function(c){c?(a.position=t?h.offset(b):h.position(b),a.position.top=a.position.top+b.prop("offsetHeight"),l(function(){u&&a.$broadcast("uib:datepicker.focus"),f.bind("click",p)},0,!1)):f.unbind("click",p)})}]).directive("uibDatepickerPopup",function(){return{require:["ngModel","uibDatepickerPopup"],controller:"UibDatepickerPopupController",scope:{isOpen:"=?",currentText:"@",clearText:"@",closeText:"@",dateDisabled:"&",customClass:"&"},link:function(a,b,c,d){var e=d[0],f=d[1];f.init(e)}}}).directive("uibDatepickerPopupWrap",function(){return{replace:!0,transclude:!0,templateUrl:function(a,b){return b.templateUrl||"template/datepicker/popup.html"}}}),angular.module("ui.bootstrap.datepicker").value("$datepickerSuppressWarning",!1).controller("DatepickerController",["$scope","$attrs","$log","$datepickerSuppressWarning","$controller",function(a,b,c,d,e){return d||c.warn("DatepickerController is now deprecated. Use UibDatepickerController instead."),e("UibDatepickerController",{$scope:a,$attrs:b})}]).directive("datepicker",["$log","$datepickerSuppressWarning",function(a,b){return{replace:!0,templateUrl:function(a,b){return b.templateUrl||"template/datepicker/datepicker.html"},scope:{datepickerMode:"=?",dateDisabled:"&",customClass:"&",shortcutPropagation:"&?"},require:["datepicker","^ngModel"],controller:"DatepickerController",controllerAs:"datepicker",link:function(c,d,e,f){b||a.warn("datepicker is now deprecated. Use uib-datepicker instead.");var g=f[0],h=f[1];g.init(h)}}}]).directive("daypicker",["$log","$datepickerSuppressWarning",function(a,b){return{replace:!0,templateUrl:"template/datepicker/day.html",require:["^datepicker","daypicker"],controller:"UibDaypickerController",link:function(c,d,e,f){b||a.warn("daypicker is now deprecated. Use uib-daypicker instead.");var g=f[0],h=f[1];h.init(g)}}}]).directive("monthpicker",["$log","$datepickerSuppressWarning",function(a,b){return{replace:!0,templateUrl:"template/datepicker/month.html",require:["^datepicker","monthpicker"],controller:"UibMonthpickerController",link:function(c,d,e,f){b||a.warn("monthpicker is now deprecated. Use uib-monthpicker instead.");var g=f[0],h=f[1];h.init(g)}}}]).directive("yearpicker",["$log","$datepickerSuppressWarning",function(a,b){return{replace:!0,templateUrl:"template/datepicker/year.html",require:["^datepicker","yearpicker"],controller:"UibYearpickerController",link:function(c,d,e,f){b||a.warn("yearpicker is now deprecated. Use uib-yearpicker instead.");var g=f[0];angular.extend(g,f[1]),g.yearpickerInit(),g.refreshView()}}}]).directive("datepickerPopup",["$log","$datepickerSuppressWarning",function(a,b){return{require:["ngModel","datepickerPopup"],controller:"UibDatepickerPopupController",scope:{isOpen:"=?",currentText:"@",clearText:"@",closeText:"@",dateDisabled:"&",customClass:"&"},link:function(c,d,e,f){b||a.warn("datepicker-popup is now deprecated. Use uib-datepicker-popup instead.");var g=f[0],h=f[1];h.init(g)}}}]).directive("datepickerPopupWrap",["$log","$datepickerSuppressWarning",function(a,b){return{replace:!0,transclude:!0,templateUrl:function(a,b){return b.templateUrl||"template/datepicker/popup.html"},link:function(){b||a.warn("datepicker-popup-wrap is now deprecated. Use uib-datepicker-popup-wrap instead.")}}}]),angular.module("ui.bootstrap.dropdown",["ui.bootstrap.position"]).constant("uibDropdownConfig",{openClass:"open"}).service("uibDropdownService",["$document","$rootScope",function(a,b){var c=null;this.open=function(b){c||(a.bind("click",d),a.bind("keydown",e)),c&&c!==b&&(c.isOpen=!1),c=b},this.close=function(b){c===b&&(c=null,a.unbind("click",d),a.unbind("keydown",e))};var d=function(a){if(c&&(!a||"disabled"!==c.getAutoClose())){var d=c.getToggleElement();if(!(a&&d&&d[0].contains(a.target))){var e=c.getDropdownElement();a&&"outsideClick"===c.getAutoClose()&&e&&e[0].contains(a.target)||(c.isOpen=!1,b.$$phase||c.$apply())}}},e=function(a){27===a.which?(c.focusToggleElement(),d()):c.isKeynavEnabled()&&/(38|40)/.test(a.which)&&c.isOpen&&(a.preventDefault(),a.stopPropagation(),c.focusDropdownEntry(a.which))}}]).controller("UibDropdownController",["$scope","$element","$attrs","$parse","uibDropdownConfig","uibDropdownService","$animate","$uibPosition","$document","$compile","$templateRequest",function(a,b,c,d,e,f,g,h,i,j,k){var l,m,n=this,o=a.$new(),p=e.openClass,q=angular.noop,r=c.onToggle?d(c.onToggle):angular.noop,s=!1,t=!1;b.addClass("dropdown"),this.init=function(){c.isOpen&&(m=d(c.isOpen),q=m.assign,a.$watch(m,function(a){o.isOpen=!!a})),s=angular.isDefined(c.dropdownAppendToBody),t=angular.isDefined(c.uibKeyboardNav),s&&n.dropdownMenu&&(i.find("body").append(n.dropdownMenu),b.on("$destroy",function(){n.dropdownMenu.remove()}))},this.toggle=function(a){return o.isOpen=arguments.length?!!a:!o.isOpen},this.isOpen=function(){return o.isOpen},o.getToggleElement=function(){return n.toggleElement},o.getAutoClose=function(){return c.autoClose||"always"},o.getElement=function(){return b},o.isKeynavEnabled=function(){return t},o.focusDropdownEntry=function(a){var c=n.dropdownMenu?angular.element(n.dropdownMenu).find("a"):angular.element(b).find("ul").eq(0).find("a");switch(a){case 40:angular.isNumber(n.selectedOption)?n.selectedOption=n.selectedOption===c.length-1?n.selectedOption:n.selectedOption+1:n.selectedOption=0;break;case 38:angular.isNumber(n.selectedOption)?n.selectedOption=0===n.selectedOption?0:n.selectedOption-1:n.selectedOption=c.length-1}c[n.selectedOption].focus()},o.getDropdownElement=function(){return n.dropdownMenu},o.focusToggleElement=function(){n.toggleElement&&n.toggleElement[0].focus()},o.$watch("isOpen",function(c,d){if(s&&n.dropdownMenu){var e=h.positionElements(b,n.dropdownMenu,"bottom-left",!0),i={top:e.top+"px",display:c?"block":"none"},m=n.dropdownMenu.hasClass("dropdown-menu-right");m?(i.left="auto",i.right=window.innerWidth-(e.left+b.prop("offsetWidth"))+"px"):(i.left=e.left+"px",i.right="auto"),n.dropdownMenu.css(i)}if(g[c?"addClass":"removeClass"](b,p).then(function(){angular.isDefined(c)&&c!==d&&r(a,{open:!!c})}),c)n.dropdownMenuTemplateUrl&&k(n.dropdownMenuTemplateUrl).then(function(a){l=o.$new(),j(a.trim())(l,function(a){var b=a;n.dropdownMenu.replaceWith(b),n.dropdownMenu=b})}),o.focusToggleElement(),f.open(o);else{if(n.dropdownMenuTemplateUrl){l&&l.$destroy();var t=angular.element('<ul class="dropdown-menu"></ul>');n.dropdownMenu.replaceWith(t),n.dropdownMenu=t}f.close(o),n.selectedOption=null}angular.isFunction(q)&&q(a,c)}),a.$on("$locationChangeSuccess",function(){"disabled"!==o.getAutoClose()&&(o.isOpen=!1)});var u=a.$on("$destroy",function(){o.$destroy()});o.$on("$destroy",u)}]).directive("uibDropdown",function(){return{controller:"UibDropdownController",link:function(a,b,c,d){d.init()}}}).directive("uibDropdownMenu",function(){return{restrict:"AC",require:"?^uibDropdown",link:function(a,b,c,d){if(d&&!angular.isDefined(c.dropdownNested)){b.addClass("dropdown-menu");var e=c.templateUrl;e&&(d.dropdownMenuTemplateUrl=e),d.dropdownMenu||(d.dropdownMenu=b)}}}}).directive("uibKeyboardNav",function(){return{restrict:"A",require:"?^uibDropdown",link:function(a,b,c,d){b.bind("keydown",function(a){if(-1!==[38,40].indexOf(a.which)){a.preventDefault(),a.stopPropagation();var b=d.dropdownMenu.find("a");switch(a.which){case 40:angular.isNumber(d.selectedOption)?d.selectedOption=d.selectedOption===b.length-1?d.selectedOption:d.selectedOption+1:d.selectedOption=0;break;case 38:angular.isNumber(d.selectedOption)?d.selectedOption=0===d.selectedOption?0:d.selectedOption-1:d.selectedOption=b.length-1}b[d.selectedOption].focus()}})}}}).directive("uibDropdownToggle",function(){return{require:"?^uibDropdown",link:function(a,b,c,d){if(d){b.addClass("dropdown-toggle"),d.toggleElement=b;var e=function(e){e.preventDefault(),b.hasClass("disabled")||c.disabled||a.$apply(function(){d.toggle()})};b.bind("click",e),b.attr({"aria-haspopup":!0,"aria-expanded":!1}),a.$watch(d.isOpen,function(a){b.attr("aria-expanded",!!a)}),a.$on("$destroy",function(){b.unbind("click",e)})}}}}),angular.module("ui.bootstrap.dropdown").value("$dropdownSuppressWarning",!1).service("dropdownService",["$log","$dropdownSuppressWarning","uibDropdownService",function(a,b,c){b||a.warn("dropdownService is now deprecated. Use uibDropdownService instead."),angular.extend(this,c)}]).controller("DropdownController",["$scope","$element","$attrs","$log","$dropdownSuppressWarning","$controller",function(a,b,c,d,e,f){return e||d.warn("DropdownController is now deprecated. Use UibDropdownController instead."),f("UibDropdownController",{$scope:a,$element:b,$attrs:c})}]).directive("dropdown",["$log","$dropdownSuppressWarning",function(a,b){return{controller:"DropdownController",link:function(c,d,e,f){b||a.warn("dropdown is now deprecated. Use uib-dropdown instead."),f.init()}}}]).directive("dropdownMenu",["$log","$dropdownSuppressWarning",function(a,b){return{restrict:"AC",require:"?^dropdown",link:function(c,d,e,f){if(f){b||a.warn("dropdown-menu is now deprecated. Use uib-dropdown-menu instead."),d.addClass("dropdown-menu");var g=e.templateUrl;g&&(f.dropdownMenuTemplateUrl=g),f.dropdownMenu||(f.dropdownMenu=d)}}}}]).directive("keyboardNav",["$log","$dropdownSuppressWarning",function(a,b){return{restrict:"A",require:"?^dropdown",link:function(c,d,e,f){b||a.warn("keyboard-nav is now deprecated. Use uib-keyboard-nav instead."),d.bind("keydown",function(a){if(-1!==[38,40].indexOf(a.which)){a.preventDefault(),a.stopPropagation();var b=f.dropdownMenu.find("a");switch(a.which){case 40:angular.isNumber(f.selectedOption)?f.selectedOption=f.selectedOption===b.length-1?f.selectedOption:f.selectedOption+1:f.selectedOption=0;break;case 38:angular.isNumber(f.selectedOption)?f.selectedOption=0===f.selectedOption?0:f.selectedOption-1:f.selectedOption=b.length-1}b[f.selectedOption].focus()}})}}}]).directive("dropdownToggle",["$log","$dropdownSuppressWarning",function(a,b){return{require:"?^dropdown",link:function(c,d,e,f){if(b||a.warn("dropdown-toggle is now deprecated. Use uib-dropdown-toggle instead."),f){d.addClass("dropdown-toggle"),f.toggleElement=d;var g=function(a){a.preventDefault(),d.hasClass("disabled")||e.disabled||c.$apply(function(){f.toggle()})};d.bind("click",g),d.attr({"aria-haspopup":!0,"aria-expanded":!1}),c.$watch(f.isOpen,function(a){d.attr("aria-expanded",!!a)}),c.$on("$destroy",function(){d.unbind("click",g)})}}}}]),angular.module("ui.bootstrap.stackedMap",[]).factory("$$stackedMap",function(){return{createNew:function(){var a=[];return{add:function(b,c){a.push({key:b,value:c})},get:function(b){for(var c=0;c<a.length;c++)if(b==a[c].key)return a[c]},keys:function(){for(var b=[],c=0;c<a.length;c++)b.push(a[c].key);return b},top:function(){return a[a.length-1]},remove:function(b){for(var c=-1,d=0;d<a.length;d++)if(b==a[d].key){c=d;break}return a.splice(c,1)[0]},removeTop:function(){return a.splice(a.length-1,1)[0]},length:function(){return a.length}}}}}),angular.module("ui.bootstrap.modal",["ui.bootstrap.stackedMap"]).factory("$$multiMap",function(){return{createNew:function(){var a={};return{entries:function(){return Object.keys(a).map(function(b){return{key:b,value:a[b]}})},get:function(b){return a[b]},hasKey:function(b){return!!a[b]},keys:function(){return Object.keys(a)},put:function(b,c){a[b]||(a[b]=[]),a[b].push(c)},remove:function(b,c){var d=a[b];if(d){var e=d.indexOf(c);-1!==e&&d.splice(e,1),d.length||delete a[b]}}}}}}).directive("uibModalBackdrop",["$animate","$injector","$uibModalStack",function(a,b,c){function d(b,d,f){d.addClass("modal-backdrop"),f.modalInClass&&(e?e(d,{addClass:f.modalInClass}).start():a.addClass(d,f.modalInClass),b.$on(c.NOW_CLOSING_EVENT,function(b,c){var g=c();e?e(d,{removeClass:f.modalInClass}).start().then(g):a.removeClass(d,f.modalInClass).then(g)}))}var e=null;return b.has("$animateCss")&&(e=b.get("$animateCss")),{replace:!0,templateUrl:"template/modal/backdrop.html",compile:function(a,b){return a.addClass(b.backdropClass),d}}}]).directive("uibModalWindow",["$uibModalStack","$q","$animate","$injector",function(a,b,c,d){var e=null;return d.has("$animateCss")&&(e=d.get("$animateCss")),{scope:{index:"@"},replace:!0,transclude:!0,templateUrl:function(a,b){return b.templateUrl||"template/modal/window.html"},link:function(d,f,g){f.addClass(g.windowClass||""),f.addClass(g.windowTopClass||""),d.size=g.size,d.close=function(b){var c=a.getTop();c&&c.value.backdrop&&"static"!==c.value.backdrop&&b.target===b.currentTarget&&(b.preventDefault(),b.stopPropagation(),a.dismiss(c.key,"backdrop click"))},f.on("click",d.close),d.$isRendered=!0;var h=b.defer();g.$observe("modalRender",function(a){"true"==a&&h.resolve()}),h.promise.then(function(){var h=null;g.modalInClass&&(h=e?e(f,{addClass:g.modalInClass}).start():c.addClass(f,g.modalInClass),d.$on(a.NOW_CLOSING_EVENT,function(a,b){var d=b();e?e(f,{removeClass:g.modalInClass}).start().then(d):c.removeClass(f,g.modalInClass).then(d)})),b.when(h).then(function(){var a=f[0].querySelectorAll("[autofocus]");a.length?a[0].focus():f[0].focus()});var i=a.getTop();i&&a.modalRendered(i.key)})}}}]).directive("uibModalAnimationClass",[function(){return{compile:function(a,b){b.modalAnimation&&a.addClass(b.uibModalAnimationClass)}}}]).directive("uibModalTransclude",function(){return{link:function(a,b,c,d,e){e(a.$parent,function(a){b.empty(),b.append(a)})}}}).factory("$uibModalStack",["$animate","$timeout","$document","$compile","$rootScope","$q","$injector","$$multiMap","$$stackedMap",function(a,b,c,d,e,f,g,h,i){function j(){for(var a=-1,b=u.keys(),c=0;c<b.length;c++)u.get(b[c]).value.backdrop&&(a=c);return a}function k(a,b){var d=c.find("body").eq(0),e=u.get(a).value;u.remove(a),n(e.modalDomEl,e.modalScope,function(){var b=e.openedClass||t;v.remove(b,a),d.toggleClass(b,v.hasKey(b)),l(!0)}),m(),b&&b.focus?b.focus():d.focus()}function l(a){var b;u.length()>0&&(b=u.top().value,b.modalDomEl.toggleClass(b.windowTopClass||"",a))}function m(){if(q&&-1==j()){var a=r;n(q,r,function(){a=null}),q=void 0,r=void 0}}function n(b,c,d){function e(){e.done||(e.done=!0,p?p(b,{event:"leave"}).start().then(function(){b.remove()}):a.leave(b),c.$destroy(),d&&d())}var g,h=null,i=function(){return g||(g=f.defer(),h=g.promise),function(){g.resolve()}};return c.$broadcast(w.NOW_CLOSING_EVENT,i),f.when(h).then(e)}function o(a,b,c){return!a.value.modalScope.$broadcast("modal.closing",b,c).defaultPrevented}var p=null;g.has("$animateCss")&&(p=g.get("$animateCss"));var q,r,s,t="modal-open",u=i.createNew(),v=h.createNew(),w={NOW_CLOSING_EVENT:"modal.stack.now-closing"},x=0,y="a[href], area[href], input:not([disabled]), button:not([disabled]),select:not([disabled]), textarea:not([disabled]), iframe, object, embed, *[tabindex], *[contenteditable=true]";return e.$watch(j,function(a){r&&(r.index=a)}),c.bind("keydown",function(a){if(a.isDefaultPrevented())return a;var b=u.top();if(b&&b.value.keyboard)switch(a.which){case 27:a.preventDefault(),e.$apply(function(){w.dismiss(b.key,"escape key press")});break;case 9:w.loadFocusElementList(b);var c=!1;a.shiftKey?w.isFocusInFirstItem(a)&&(c=w.focusLastFocusableElement()):w.isFocusInLastItem(a)&&(c=w.focusFirstFocusableElement()),c&&(a.preventDefault(),a.stopPropagation())}}),w.open=function(a,b){var f=c[0].activeElement,g=b.openedClass||t;l(!1),u.add(a,{deferred:b.deferred,renderDeferred:b.renderDeferred,modalScope:b.scope,backdrop:b.backdrop,keyboard:b.keyboard,openedClass:b.openedClass,windowTopClass:b.windowTopClass}),v.put(g,a);var h=c.find("body").eq(0),i=j();if(i>=0&&!q){r=e.$new(!0),r.index=i;var k=angular.element('<div uib-modal-backdrop="modal-backdrop"></div>');k.attr("backdrop-class",b.backdropClass),b.animation&&k.attr("modal-animation","true"),q=d(k)(r),h.append(q)}var m=angular.element('<div uib-modal-window="modal-window"></div>');m.attr({"template-url":b.windowTemplateUrl,"window-class":b.windowClass,"window-top-class":b.windowTopClass,size:b.size,index:u.length()-1,animate:"animate"}).html(b.content),b.animation&&m.attr("modal-animation","true");var n=d(m)(b.scope);u.top().value.modalDomEl=n,u.top().value.modalOpener=f,h.append(n),h.addClass(g),w.clearFocusListCache()},w.close=function(a,b){var c=u.get(a);return c&&o(c,b,!0)?(c.value.modalScope.$$uibDestructionScheduled=!0,c.value.deferred.resolve(b),k(a,c.value.modalOpener),!0):!c},w.dismiss=function(a,b){var c=u.get(a);return c&&o(c,b,!1)?(c.value.modalScope.$$uibDestructionScheduled=!0,c.value.deferred.reject(b),k(a,c.value.modalOpener),!0):!c},w.dismissAll=function(a){for(var b=this.getTop();b&&this.dismiss(b.key,a);)b=this.getTop()},w.getTop=function(){return u.top()},w.modalRendered=function(a){var b=u.get(a);b&&b.value.renderDeferred.resolve()},w.focusFirstFocusableElement=function(){return s.length>0?(s[0].focus(),!0):!1},w.focusLastFocusableElement=function(){return s.length>0?(s[s.length-1].focus(),!0):!1},w.isFocusInFirstItem=function(a){return s.length>0?(a.target||a.srcElement)==s[0]:!1},w.isFocusInLastItem=function(a){return s.length>0?(a.target||a.srcElement)==s[s.length-1]:!1},w.clearFocusListCache=function(){s=[],x=0},w.loadFocusElementList=function(a){if((void 0===s||!s.length0)&&a){var b=a.value.modalDomEl;b&&b.length&&(s=b[0].querySelectorAll(y))}},w}]).provider("$uibModal",function(){var a={options:{animation:!0,backdrop:!0,keyboard:!0},$get:["$injector","$rootScope","$q","$templateRequest","$controller","$uibModalStack",function(b,c,d,e,f,g){function h(a){return a.template?d.when(a.template):e(angular.isFunction(a.templateUrl)?a.templateUrl():a.templateUrl)}function i(a){var c=[];return angular.forEach(a,function(a){angular.isFunction(a)||angular.isArray(a)?c.push(d.when(b.invoke(a))):angular.isString(a)?c.push(d.when(b.get(a))):c.push(d.when(a))}),c}var j={},k=null;return j.getPromiseChain=function(){return k},j.open=function(b){var e=d.defer(),j=d.defer(),l=d.defer(),m={result:e.promise,opened:j.promise,rendered:l.promise,close:function(a){return g.close(m,a)},dismiss:function(a){return g.dismiss(m,a)}};if(b=angular.extend({},a.options,b),b.resolve=b.resolve||{},!b.template&&!b.templateUrl)throw new Error("One of template or templateUrl options is required.");var n,o=d.all([h(b)].concat(i(b.resolve)));return n=k=d.all([k]).then(function(){return o},function(){return o}).then(function(a){var d=(b.scope||c).$new();d.$close=m.close,d.$dismiss=m.dismiss,d.$on("$destroy",function(){d.$$uibDestructionScheduled||d.$dismiss("$uibUnscheduledDestruction")});var h,i={},k=1;b.controller&&(i.$scope=d,i.$modalInstance=m,angular.forEach(b.resolve,function(b,c){i[c]=a[k++]}),h=f(b.controller,i),b.controllerAs&&(b.bindToController&&angular.extend(h,d),d[b.controllerAs]=h)),g.open(m,{scope:d,deferred:e,renderDeferred:l,content:a[0],animation:b.animation,backdrop:b.backdrop,keyboard:b.keyboard,backdropClass:b.backdropClass,windowTopClass:b.windowTopClass,windowClass:b.windowClass,windowTemplateUrl:b.windowTemplateUrl,size:b.size,openedClass:b.openedClass}),j.resolve(!0)},function(a){j.reject(a),e.reject(a)})["finally"](function(){k===n&&(k=null)}),m},j}]};return a}),angular.module("ui.bootstrap.modal").value("$modalSuppressWarning",!1).directive("modalBackdrop",["$animate","$injector","$modalStack","$log","$modalSuppressWarning",function(a,b,c,d,e){function f(b,f,h){e||d.warn("modal-backdrop is now deprecated. Use uib-modal-backdrop instead."),f.addClass("modal-backdrop"),h.modalInClass&&(g?g(f,{addClass:h.modalInClass}).start():a.addClass(f,h.modalInClass),b.$on(c.NOW_CLOSING_EVENT,function(b,c){var d=c();g?g(f,{removeClass:h.modalInClass}).start().then(d):a.removeClass(f,h.modalInClass).then(d)}))}var g=null;return b.has("$animateCss")&&(g=b.get("$animateCss")),{replace:!0,templateUrl:"template/modal/backdrop.html",compile:function(a,b){return a.addClass(b.backdropClass),f}}}]).directive("modalWindow",["$modalStack","$q","$animate","$injector","$log","$modalSuppressWarning",function(a,b,c,d,e,f){var g=null;return d.has("$animateCss")&&(g=d.get("$animateCss")),{scope:{index:"@"},replace:!0,transclude:!0,templateUrl:function(a,b){return b.templateUrl||"template/modal/window.html"},link:function(d,h,i){f||e.warn("modal-window is now deprecated. Use uib-modal-window instead."),h.addClass(i.windowClass||""),h.addClass(i.windowTopClass||""),d.size=i.size,d.close=function(b){var c=a.getTop();c&&c.value.backdrop&&"static"!==c.value.backdrop&&b.target===b.currentTarget&&(b.preventDefault(),b.stopPropagation(),a.dismiss(c.key,"backdrop click"))},h.on("click",d.close),d.$isRendered=!0;var j=b.defer();i.$observe("modalRender",function(a){"true"==a&&j.resolve()}),j.promise.then(function(){var e=null;i.modalInClass&&(e=g?g(h,{addClass:i.modalInClass}).start():c.addClass(h,i.modalInClass),d.$on(a.NOW_CLOSING_EVENT,function(a,b){var d=b();g?g(h,{removeClass:i.modalInClass}).start().then(d):c.removeClass(h,i.modalInClass).then(d)})),b.when(e).then(function(){var a=h[0].querySelectorAll("[autofocus]");a.length?a[0].focus():h[0].focus()});var f=a.getTop();f&&a.modalRendered(f.key)})}}}]).directive("modalAnimationClass",["$log","$modalSuppressWarning",function(a,b){return{compile:function(c,d){b||a.warn("modal-animation-class is now deprecated. Use uib-modal-animation-class instead."),d.modalAnimation&&c.addClass(d.modalAnimationClass)}}}]).directive("modalTransclude",["$log","$modalSuppressWarning",function(a,b){return{link:function(c,d,e,f,g){b||a.warn("modal-transclude is now deprecated. Use uib-modal-transclude instead."),g(c.$parent,function(a){d.empty(),d.append(a)})}}}]).service("$modalStack",["$animate","$timeout","$document","$compile","$rootScope","$q","$injector","$$multiMap","$$stackedMap","$uibModalStack","$log","$modalSuppressWarning",function(a,b,c,d,e,f,g,h,i,j,k,l){l||k.warn("$modalStack is now deprecated. Use $uibModalStack instead."),angular.extend(this,j)}]).provider("$modal",["$uibModalProvider",function(a){angular.extend(this,a),this.$get=["$injector","$log","$modalSuppressWarning",function(b,c,d){return d||c.warn("$modal is now deprecated. Use $uibModal instead."),b.invoke(a.$get)}]}]),angular.module("ui.bootstrap.pagination",[]).controller("UibPaginationController",["$scope","$attrs","$parse",function(a,b,c){var d=this,e={$setViewValue:angular.noop},f=b.numPages?c(b.numPages).assign:angular.noop;this.init=function(g,h){e=g,this.config=h,e.$render=function(){d.render()},b.itemsPerPage?a.$parent.$watch(c(b.itemsPerPage),function(b){d.itemsPerPage=parseInt(b,10),a.totalPages=d.calculateTotalPages()}):this.itemsPerPage=h.itemsPerPage,a.$watch("totalItems",function(){a.totalPages=d.calculateTotalPages()}),a.$watch("totalPages",function(b){f(a.$parent,b),a.page>b?a.selectPage(b):e.$render()})},this.calculateTotalPages=function(){var b=this.itemsPerPage<1?1:Math.ceil(a.totalItems/this.itemsPerPage);return Math.max(b||0,1)},this.render=function(){a.page=parseInt(e.$viewValue,10)||1},a.selectPage=function(b,c){c&&c.preventDefault();var d=!a.ngDisabled||!c;d&&a.page!==b&&b>0&&b<=a.totalPages&&(c&&c.target&&c.target.blur(),e.$setViewValue(b),e.$render())},a.getText=function(b){return a[b+"Text"]||d.config[b+"Text"]},a.noPrevious=function(){return 1===a.page},a.noNext=function(){return a.page===a.totalPages}}]).constant("uibPaginationConfig",{itemsPerPage:10,boundaryLinks:!1,directionLinks:!0,firstText:"First",previousText:"Previous",nextText:"Next",lastText:"Last",rotate:!0}).directive("uibPagination",["$parse","uibPaginationConfig",function(a,b){return{restrict:"EA",scope:{totalItems:"=",firstText:"@",previousText:"@",nextText:"@",lastText:"@",ngDisabled:"="},require:["uibPagination","?ngModel"],controller:"UibPaginationController",controllerAs:"pagination",templateUrl:function(a,b){return b.templateUrl||"template/pagination/pagination.html"},replace:!0,link:function(c,d,e,f){function g(a,b,c){return{number:a,text:b,active:c}}function h(a,b){var c=[],d=1,e=b,f=angular.isDefined(k)&&b>k;f&&(l?(d=Math.max(a-Math.floor(k/2),1),e=d+k-1,e>b&&(e=b,d=e-k+1)):(d=(Math.ceil(a/k)-1)*k+1,e=Math.min(d+k-1,b)));for(var h=d;e>=h;h++){var i=g(h,h,h===a);c.push(i)}if(f&&!l){if(d>1){var j=g(d-1,"...",!1);c.unshift(j)}if(b>e){var m=g(e+1,"...",!1);c.push(m)}}return c}var i=f[0],j=f[1];if(j){var k=angular.isDefined(e.maxSize)?c.$parent.$eval(e.maxSize):b.maxSize,l=angular.isDefined(e.rotate)?c.$parent.$eval(e.rotate):b.rotate;c.boundaryLinks=angular.isDefined(e.boundaryLinks)?c.$parent.$eval(e.boundaryLinks):b.boundaryLinks,c.directionLinks=angular.isDefined(e.directionLinks)?c.$parent.$eval(e.directionLinks):b.directionLinks,i.init(j,b),e.maxSize&&c.$parent.$watch(a(e.maxSize),function(a){k=parseInt(a,10),i.render()});var m=i.render;i.render=function(){m(),c.page>0&&c.page<=c.totalPages&&(c.pages=h(c.page,c.totalPages))}}}}}]).constant("uibPagerConfig",{itemsPerPage:10,previousText:"« Previous",nextText:"Next »",align:!0}).directive("uibPager",["uibPagerConfig",function(a){return{restrict:"EA",scope:{totalItems:"=",previousText:"@",nextText:"@",ngDisabled:"="},require:["uibPager","?ngModel"],controller:"UibPaginationController",controllerAs:"pagination",templateUrl:function(a,b){return b.templateUrl||"template/pagination/pager.html"},replace:!0,link:function(b,c,d,e){var f=e[0],g=e[1];g&&(b.align=angular.isDefined(d.align)?b.$parent.$eval(d.align):a.align,f.init(g,a))}}}]),angular.module("ui.bootstrap.pagination").value("$paginationSuppressWarning",!1).controller("PaginationController",["$scope","$attrs","$parse","$controller","$element","$log","$paginationSuppressWarning",function(a,b,c,d,e,f,g){return g||f.warn("PaginationController is now deprecated. Use UibPaginationController instead."),d("UibPaginationController",{$scope:a,$element:e,$attrs:b})}]).directive("pagination",["$parse","uibPaginationConfig","$log","$paginationSuppressWarning",function(a,b,c,d){return{restrict:"EA",scope:{totalItems:"=",firstText:"@",previousText:"@",nextText:"@",lastText:"@",ngDisabled:"="},require:["pagination","?ngModel"],controller:"PaginationController",controllerAs:"pagination",templateUrl:function(a,b){return b.templateUrl||"template/pagination/pagination.html"},replace:!0,link:function(e,f,g,h){function i(a,b,c){return{number:a,text:b,active:c}}function j(a,b){var c=[],d=1,e=b,f=angular.isDefined(m)&&b>m;f&&(n?(d=Math.max(a-Math.floor(m/2),1),e=d+m-1,e>b&&(e=b,d=e-m+1)):(d=(Math.ceil(a/m)-1)*m+1,e=Math.min(d+m-1,b)));for(var g=d;e>=g;g++){var h=i(g,g,g===a);c.push(h)}if(f&&!n){if(d>1){var j=i(d-1,"...",!1);c.unshift(j)}if(b>e){var k=i(e+1,"...",!1);c.push(k)}}return c}d||c.warn("pagination is now deprecated. Use uib-pagination instead.");var k=h[0],l=h[1];if(l){var m=angular.isDefined(g.maxSize)?e.$parent.$eval(g.maxSize):b.maxSize,n=angular.isDefined(g.rotate)?e.$parent.$eval(g.rotate):b.rotate;e.boundaryLinks=angular.isDefined(g.boundaryLinks)?e.$parent.$eval(g.boundaryLinks):b.boundaryLinks,e.directionLinks=angular.isDefined(g.directionLinks)?e.$parent.$eval(g.directionLinks):b.directionLinks,k.init(l,b),g.maxSize&&e.$parent.$watch(a(g.maxSize),function(a){m=parseInt(a,10),k.render()});var o=k.render;k.render=function(){o(),e.page>0&&e.page<=e.totalPages&&(e.pages=j(e.page,e.totalPages))}}}}}]).directive("pager",["uibPagerConfig","$log","$paginationSuppressWarning",function(a,b,c){return{restrict:"EA",scope:{totalItems:"=",previousText:"@",nextText:"@",ngDisabled:"="},require:["pager","?ngModel"],controller:"PaginationController",controllerAs:"pagination",templateUrl:function(a,b){return b.templateUrl||"template/pagination/pager.html"},replace:!0,link:function(d,e,f,g){c||b.warn("pager is now deprecated. Use uib-pager instead.");var h=g[0],i=g[1];i&&(d.align=angular.isDefined(f.align)?d.$parent.$eval(f.align):a.align,h.init(i,a)); |
| 10 | }}}]),angular.module("ui.bootstrap.tooltip",["ui.bootstrap.position","ui.bootstrap.stackedMap"]).provider("$uibTooltip",function(){function a(a){var b=/[A-Z]/g,c="-";return a.replace(b,function(a,b){return(b?c:"")+a.toLowerCase()})}var b={placement:"top",animation:!0,popupDelay:0,popupCloseDelay:500,useContentExp:!1},c={mouseenter:"mouseleave",click:"click",focus:"blur",none:""},d={};this.options=function(a){angular.extend(d,a)},this.setTriggers=function(a){angular.extend(c,a)},this.$get=["$window","$compile","$timeout","$document","$uibPosition","$interpolate","$rootScope","$parse","$$stackedMap",function(e,f,g,h,i,j,k,l,m){var n=m.createNew();return h.on("keypress",function(a){if(27===a.which){var b=n.top();b&&(b.value.close(),n.removeTop(),b=null)}}),function(e,k,m,o){function p(a){var b=(a||o.trigger||m).split(" "),d=b.map(function(a){return c[a]||a});return{show:b,hide:d}}o=angular.extend({},b,d,o);var q=a(e),r=j.startSymbol(),s=j.endSymbol(),t="<div "+q+'-popup title="'+r+"title"+s+'" '+(o.useContentExp?'content-exp="contentExp()" ':'content="'+r+"content"+s+'" ')+'placement="'+r+"placement"+s+'" popup-class="'+r+"popupClass"+s+'" animation="animation" is-open="isOpen"origin-scope="origScope" style="visibility: hidden; display: block;"></div>';return{compile:function(a,b){var c=f(t);return function(a,b,d,f){function j(){H.isOpen?q():m()}function m(){(!G||a.$eval(d[k+"Enable"]))&&(v(),H.popupDelay?C||(C=g(r,H.popupDelay,!1)):r())}function q(){s()}function r(){return C&&(g.cancel(C),C=null),B&&(g.cancel(B),B=null),H.content?(t(),void H.$evalAsync(function(){H.isOpen=!0,J&&angular.isFunction(J.assign)&&J.assign(H.origScope,H.isOpen),M()})):angular.noop}function s(){H&&(H.$evalAsync(function(){H.isOpen=!1,J&&angular.isFunction(J.assign)&&J.assign(H.origScope,H.isOpen)}),g.cancel(C),C=null,g.cancel(D),D=null,H.animation?B||(B=g(u,H.popupCloseDelay)):u())}function t(){z||(A=H.$new(),z=c(A,function(a){E?h.find("body").append(a):b.after(a)}),w())}function u(){x(),B=null,z&&(z.remove(),z=null),A&&(A.$destroy(),A=null)}function v(){H.title=d[k+"Title"],K?H.content=K(a):H.content=d[e],H.popupClass=d[k+"Class"],H.placement=angular.isDefined(d[k+"Placement"])?d[k+"Placement"]:o.placement;var b=parseInt(d[k+"PopupDelay"],10),c=parseInt(d[k+"PopupCloseDelay"],10);H.popupDelay=isNaN(b)?o.popupDelay:b,H.popupCloseDelay=isNaN(c)?o.popupCloseDelay:c}function w(){L.length=0,K?(L.push(a.$watch(K,function(a){H.content=a,!a&&H.isOpen&&s()})),L.push(A.$watch(function(){I||(I=!0,A.$$postDigest(function(){I=!1,H&&H.isOpen&&M()}))}))):L.push(d.$observe(e,function(a){H.content=a,!a&&H.isOpen?s():M()})),L.push(d.$observe(k+"Title",function(a){H.title=a,H.isOpen&&M()})),L.push(d.$observe(k+"Placement",function(a){H.placement=a?a:o.placement,H.isOpen&&M()}))}function x(){L.length&&(angular.forEach(L,function(a){a()}),L.length=0)}function y(){var a=d[k+"Trigger"];N(),F=p(a),"none"!==F.show&&F.show.forEach(function(a,c){a===F.hide[c]?b[0].addEventListener(a,j):a&&(b[0].addEventListener(a,m),F.hide[c].split(" ").forEach(function(a){b[0].addEventListener(a,q)})),b.on("keypress",function(a){27===a.which&&q()})})}var z,A,B,C,D,E=angular.isDefined(o.appendToBody)?o.appendToBody:!1,F=p(void 0),G=angular.isDefined(d[k+"Enable"]),H=a.$new(!0),I=!1,J=angular.isDefined(d[k+"IsOpen"])?l(d[k+"IsOpen"]):!1,K=o.useContentExp?l(d[e]):!1,L=[],M=function(){z&&z.html()&&(D||(D=g(function(){z.css({top:0,left:0});var a=i.positionElements(b,z,H.placement,E);a.top+="px",a.left+="px",a.visibility="visible",z.css(a),D=null},0,!1)))};H.origScope=a,H.isOpen=!1,n.add(H,{close:s}),H.contentExp=function(){return H.content},d.$observe("disabled",function(a){C&&a&&(g.cancel(C),C=null),a&&H.isOpen&&s()}),J&&a.$watch(J,function(a){!a===H.isOpen&&j()});var N=function(){F.show.forEach(function(a){b.unbind(a,m)}),F.hide.forEach(function(a){a.split(" ").forEach(function(a){b[0].removeEventListener(a,q)})})};y();var O=a.$eval(d[k+"Animation"]);H.animation=angular.isDefined(O)?!!O:o.animation;var P=a.$eval(d[k+"AppendToBody"]);E=angular.isDefined(P)?P:E,E&&a.$on("$locationChangeSuccess",function(){H.isOpen&&s()}),a.$on("$destroy",function(){g.cancel(B),g.cancel(C),g.cancel(D),N(),u(),H=null})}}}}}]}).directive("uibTooltipTemplateTransclude",["$animate","$sce","$compile","$templateRequest",function(a,b,c,d){return{link:function(e,f,g){var h,i,j,k=e.$eval(g.tooltipTemplateTranscludeScope),l=0,m=function(){i&&(i.remove(),i=null),h&&(h.$destroy(),h=null),j&&(a.leave(j).then(function(){i=null}),i=j,j=null)};e.$watch(b.parseAsResourceUrl(g.uibTooltipTemplateTransclude),function(b){var g=++l;b?(d(b,!0).then(function(d){if(g===l){var e=k.$new(),i=d,n=c(i)(e,function(b){m(),a.enter(b,f)});h=e,j=n,h.$emit("$includeContentLoaded",b)}},function(){g===l&&(m(),e.$emit("$includeContentError",b))}),e.$emit("$includeContentRequested",b)):m()}),e.$on("$destroy",m)}}}]).directive("uibTooltipClasses",function(){return{restrict:"A",link:function(a,b,c){a.placement&&b.addClass(a.placement),a.popupClass&&b.addClass(a.popupClass),a.animation()&&b.addClass(c.tooltipAnimationClass)}}}).directive("uibTooltipPopup",function(){return{replace:!0,scope:{content:"@",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"template/tooltip/tooltip-popup.html",link:function(a,b){b.addClass("tooltip")}}}).directive("uibTooltip",["$uibTooltip",function(a){return a("uibTooltip","tooltip","mouseenter")}]).directive("uibTooltipTemplatePopup",function(){return{replace:!0,scope:{contentExp:"&",placement:"@",popupClass:"@",animation:"&",isOpen:"&",originScope:"&"},templateUrl:"template/tooltip/tooltip-template-popup.html",link:function(a,b){b.addClass("tooltip")}}}).directive("uibTooltipTemplate",["$uibTooltip",function(a){return a("uibTooltipTemplate","tooltip","mouseenter",{useContentExp:!0})}]).directive("uibTooltipHtmlPopup",function(){return{replace:!0,scope:{contentExp:"&",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"template/tooltip/tooltip-html-popup.html",link:function(a,b){b.addClass("tooltip")}}}).directive("uibTooltipHtml",["$uibTooltip",function(a){return a("uibTooltipHtml","tooltip","mouseenter",{useContentExp:!0})}]),angular.module("ui.bootstrap.tooltip").value("$tooltipSuppressWarning",!1).provider("$tooltip",["$uibTooltipProvider",function(a){angular.extend(this,a),this.$get=["$log","$tooltipSuppressWarning","$injector",function(b,c,d){return c||b.warn("$tooltip is now deprecated. Use $uibTooltip instead."),d.invoke(a.$get)}]}]).directive("tooltipTemplateTransclude",["$animate","$sce","$compile","$templateRequest","$log","$tooltipSuppressWarning",function(a,b,c,d,e,f){return{link:function(g,h,i){f||e.warn("tooltip-template-transclude is now deprecated. Use uib-tooltip-template-transclude instead.");var j,k,l,m=g.$eval(i.tooltipTemplateTranscludeScope),n=0,o=function(){k&&(k.remove(),k=null),j&&(j.$destroy(),j=null),l&&(a.leave(l).then(function(){k=null}),k=l,l=null)};g.$watch(b.parseAsResourceUrl(i.tooltipTemplateTransclude),function(b){var e=++n;b?(d(b,!0).then(function(d){if(e===n){var f=m.$new(),g=d,i=c(g)(f,function(b){o(),a.enter(b,h)});j=f,l=i,j.$emit("$includeContentLoaded",b)}},function(){e===n&&(o(),g.$emit("$includeContentError",b))}),g.$emit("$includeContentRequested",b)):o()}),g.$on("$destroy",o)}}}]).directive("tooltipClasses",["$log","$tooltipSuppressWarning",function(a,b){return{restrict:"A",link:function(c,d,e){b||a.warn("tooltip-classes is now deprecated. Use uib-tooltip-classes instead."),c.placement&&d.addClass(c.placement),c.popupClass&&d.addClass(c.popupClass),c.animation()&&d.addClass(e.tooltipAnimationClass)}}}]).directive("tooltipPopup",["$log","$tooltipSuppressWarning",function(a,b){return{replace:!0,scope:{content:"@",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"template/tooltip/tooltip-popup.html",link:function(c,d){b||a.warn("tooltip-popup is now deprecated. Use uib-tooltip-popup instead."),d.addClass("tooltip")}}}]).directive("tooltip",["$tooltip",function(a){return a("tooltip","tooltip","mouseenter")}]).directive("tooltipTemplatePopup",["$log","$tooltipSuppressWarning",function(a,b){return{replace:!0,scope:{contentExp:"&",placement:"@",popupClass:"@",animation:"&",isOpen:"&",originScope:"&"},templateUrl:"template/tooltip/tooltip-template-popup.html",link:function(c,d){b||a.warn("tooltip-template-popup is now deprecated. Use uib-tooltip-template-popup instead."),d.addClass("tooltip")}}}]).directive("tooltipTemplate",["$tooltip",function(a){return a("tooltipTemplate","tooltip","mouseenter",{useContentExp:!0})}]).directive("tooltipHtmlPopup",["$log","$tooltipSuppressWarning",function(a,b){return{replace:!0,scope:{contentExp:"&",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"template/tooltip/tooltip-html-popup.html",link:function(c,d){b||a.warn("tooltip-html-popup is now deprecated. Use uib-tooltip-html-popup instead."),d.addClass("tooltip")}}}]).directive("tooltipHtml",["$tooltip",function(a){return a("tooltipHtml","tooltip","mouseenter",{useContentExp:!0})}]),angular.module("ui.bootstrap.popover",["ui.bootstrap.tooltip"]).directive("uibPopoverTemplatePopup",function(){return{replace:!0,scope:{title:"@",contentExp:"&",placement:"@",popupClass:"@",animation:"&",isOpen:"&",originScope:"&"},templateUrl:"template/popover/popover-template.html",link:function(a,b){b.addClass("popover")}}}).directive("uibPopoverTemplate",["$uibTooltip",function(a){return a("uibPopoverTemplate","popover","click",{useContentExp:!0})}]).directive("uibPopoverHtmlPopup",function(){return{replace:!0,scope:{contentExp:"&",title:"@",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"template/popover/popover-html.html",link:function(a,b){b.addClass("popover")}}}).directive("uibPopoverHtml",["$uibTooltip",function(a){return a("uibPopoverHtml","popover","click",{useContentExp:!0})}]).directive("uibPopoverPopup",function(){return{replace:!0,scope:{title:"@",content:"@",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"template/popover/popover.html",link:function(a,b){b.addClass("popover")}}}).directive("uibPopover",["$uibTooltip",function(a){return a("uibPopover","popover","click")}]),angular.module("ui.bootstrap.popover").value("$popoverSuppressWarning",!1).directive("popoverTemplatePopup",["$log","$popoverSuppressWarning",function(a,b){return{replace:!0,scope:{title:"@",contentExp:"&",placement:"@",popupClass:"@",animation:"&",isOpen:"&",originScope:"&"},templateUrl:"template/popover/popover-template.html",link:function(c,d){b||a.warn("popover-template-popup is now deprecated. Use uib-popover-template-popup instead."),d.addClass("popover")}}}]).directive("popoverTemplate",["$tooltip",function(a){return a("popoverTemplate","popover","click",{useContentExp:!0})}]).directive("popoverHtmlPopup",["$log","$popoverSuppressWarning",function(a,b){return{replace:!0,scope:{contentExp:"&",title:"@",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"template/popover/popover-html.html",link:function(c,d){b||a.warn("popover-html-popup is now deprecated. Use uib-popover-html-popup instead."),d.addClass("popover")}}}]).directive("popoverHtml",["$tooltip",function(a){return a("popoverHtml","popover","click",{useContentExp:!0})}]).directive("popoverPopup",["$log","$popoverSuppressWarning",function(a,b){return{replace:!0,scope:{title:"@",content:"@",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"template/popover/popover.html",link:function(c,d){b||a.warn("popover-popup is now deprecated. Use uib-popover-popup instead."),d.addClass("popover")}}}]).directive("popover",["$tooltip",function(a){return a("popover","popover","click")}]),angular.module("ui.bootstrap.progressbar",[]).constant("uibProgressConfig",{animate:!0,max:100}).controller("UibProgressController",["$scope","$attrs","uibProgressConfig",function(a,b,c){var d=this,e=angular.isDefined(b.animate)?a.$parent.$eval(b.animate):c.animate;this.bars=[],a.max=angular.isDefined(a.max)?a.max:c.max,this.addBar=function(b,c,f){e||c.css({transition:"none"}),this.bars.push(b),b.max=a.max,b.title=f&&angular.isDefined(f.title)?f.title:"progressbar",b.$watch("value",function(a){b.recalculatePercentage()}),b.recalculatePercentage=function(){b.percent=+(100*b.value/b.max).toFixed(2);var a=d.bars.reduce(function(a,b){return a+b.percent},0);a>100&&(b.percent-=a-100)},b.$on("$destroy",function(){c=null,d.removeBar(b)})},this.removeBar=function(a){this.bars.splice(this.bars.indexOf(a),1)},a.$watch("max",function(b){d.bars.forEach(function(b){b.max=a.max,b.recalculatePercentage()})})}]).directive("uibProgress",function(){return{replace:!0,transclude:!0,controller:"UibProgressController",require:"uibProgress",scope:{max:"=?"},templateUrl:"template/progressbar/progress.html"}}).directive("uibBar",function(){return{replace:!0,transclude:!0,require:"^uibProgress",scope:{value:"=",type:"@"},templateUrl:"template/progressbar/bar.html",link:function(a,b,c,d){d.addBar(a,b,c)}}}).directive("uibProgressbar",function(){return{replace:!0,transclude:!0,controller:"UibProgressController",scope:{value:"=",max:"=?",type:"@"},templateUrl:"template/progressbar/progressbar.html",link:function(a,b,c,d){d.addBar(a,angular.element(b.children()[0]),{title:c.title})}}}),angular.module("ui.bootstrap.progressbar").value("$progressSuppressWarning",!1).controller("ProgressController",["$scope","$attrs","$controller","$log","$progressSuppressWarning",function(a,b,c,d,e){return e||d.warn("ProgressController is now deprecated. Use UibProgressController instead."),c("UibProgressController",{$scope:a,$attrs:b})}]).directive("progress",["$log","$progressSuppressWarning",function(a,b){return{replace:!0,transclude:!0,controller:"ProgressController",require:"progress",scope:{max:"=?",title:"@?"},templateUrl:"template/progressbar/progress.html",link:function(){b||a.warn("progress is now deprecated. Use uib-progress instead.")}}}]).directive("bar",["$log","$progressSuppressWarning",function(a,b){return{replace:!0,transclude:!0,require:"^progress",scope:{value:"=",type:"@"},templateUrl:"template/progressbar/bar.html",link:function(c,d,e,f){b||a.warn("bar is now deprecated. Use uib-bar instead."),f.addBar(c,d)}}}]).directive("progressbar",["$log","$progressSuppressWarning",function(a,b){return{replace:!0,transclude:!0,controller:"ProgressController",scope:{value:"=",max:"=?",type:"@"},templateUrl:"template/progressbar/progressbar.html",link:function(c,d,e,f){b||a.warn("progressbar is now deprecated. Use uib-progressbar instead."),f.addBar(c,angular.element(d.children()[0]),{title:e.title})}}}]),angular.module("ui.bootstrap.rating",[]).constant("uibRatingConfig",{max:5,stateOn:null,stateOff:null,titles:["one","two","three","four","five"]}).controller("UibRatingController",["$scope","$attrs","uibRatingConfig",function(a,b,c){var d={$setViewValue:angular.noop};this.init=function(e){d=e,d.$render=this.render,d.$formatters.push(function(a){return angular.isNumber(a)&&a<<0!==a&&(a=Math.round(a)),a}),this.stateOn=angular.isDefined(b.stateOn)?a.$parent.$eval(b.stateOn):c.stateOn,this.stateOff=angular.isDefined(b.stateOff)?a.$parent.$eval(b.stateOff):c.stateOff;var f=angular.isDefined(b.titles)?a.$parent.$eval(b.titles):c.titles;this.titles=angular.isArray(f)&&f.length>0?f:c.titles;var g=angular.isDefined(b.ratingStates)?a.$parent.$eval(b.ratingStates):new Array(angular.isDefined(b.max)?a.$parent.$eval(b.max):c.max);a.range=this.buildTemplateObjects(g)},this.buildTemplateObjects=function(a){for(var b=0,c=a.length;c>b;b++)a[b]=angular.extend({index:b},{stateOn:this.stateOn,stateOff:this.stateOff,title:this.getTitle(b)},a[b]);return a},this.getTitle=function(a){return a>=this.titles.length?a+1:this.titles[a]},a.rate=function(b){!a.readonly&&b>=0&&b<=a.range.length&&(d.$setViewValue(d.$viewValue===b?0:b),d.$render())},a.enter=function(b){a.readonly||(a.value=b),a.onHover({value:b})},a.reset=function(){a.value=d.$viewValue,a.onLeave()},a.onKeydown=function(b){/(37|38|39|40)/.test(b.which)&&(b.preventDefault(),b.stopPropagation(),a.rate(a.value+(38===b.which||39===b.which?1:-1)))},this.render=function(){a.value=d.$viewValue}}]).directive("uibRating",function(){return{require:["uibRating","ngModel"],scope:{readonly:"=?",onHover:"&",onLeave:"&"},controller:"UibRatingController",templateUrl:"template/rating/rating.html",replace:!0,link:function(a,b,c,d){var e=d[0],f=d[1];e.init(f)}}}),angular.module("ui.bootstrap.rating").value("$ratingSuppressWarning",!1).controller("RatingController",["$scope","$attrs","$controller","$log","$ratingSuppressWarning",function(a,b,c,d,e){return e||d.warn("RatingController is now deprecated. Use UibRatingController instead."),c("UibRatingController",{$scope:a,$attrs:b})}]).directive("rating",["$log","$ratingSuppressWarning",function(a,b){return{require:["rating","ngModel"],scope:{readonly:"=?",onHover:"&",onLeave:"&"},controller:"RatingController",templateUrl:"template/rating/rating.html",replace:!0,link:function(c,d,e,f){b||a.warn("rating is now deprecated. Use uib-rating instead.");var g=f[0],h=f[1];g.init(h)}}}]),angular.module("ui.bootstrap.tabs",[]).controller("UibTabsetController",["$scope",function(a){var b=this,c=b.tabs=a.tabs=[];b.select=function(a){angular.forEach(c,function(b){b.active&&b!==a&&(b.active=!1,b.onDeselect(),a.selectCalled=!1)}),a.active=!0,a.selectCalled||(a.onSelect(),a.selectCalled=!0)},b.addTab=function(a){c.push(a),1===c.length&&a.active!==!1?a.active=!0:a.active?b.select(a):a.active=!1},b.removeTab=function(a){var e=c.indexOf(a);if(a.active&&c.length>1&&!d){var f=e==c.length-1?e-1:e+1;b.select(c[f])}c.splice(e,1)};var d;a.$on("$destroy",function(){d=!0})}]).directive("uibTabset",function(){return{restrict:"EA",transclude:!0,replace:!0,scope:{type:"@"},controller:"UibTabsetController",templateUrl:"template/tabs/tabset.html",link:function(a,b,c){a.vertical=angular.isDefined(c.vertical)?a.$parent.$eval(c.vertical):!1,a.justified=angular.isDefined(c.justified)?a.$parent.$eval(c.justified):!1}}}).directive("uibTab",["$parse",function(a){return{require:"^uibTabset",restrict:"EA",replace:!0,templateUrl:"template/tabs/tab.html",transclude:!0,scope:{active:"=?",heading:"@",onSelect:"&select",onDeselect:"&deselect"},controller:function(){},link:function(b,c,d,e,f){b.$watch("active",function(a){a&&e.select(b)}),b.disabled=!1,d.disable&&b.$parent.$watch(a(d.disable),function(a){b.disabled=!!a}),b.select=function(){b.disabled||(b.active=!0)},e.addTab(b),b.$on("$destroy",function(){e.removeTab(b)}),b.$transcludeFn=f}}}]).directive("uibTabHeadingTransclude",function(){return{restrict:"A",require:["?^uibTab","?^tab"],link:function(a,b){a.$watch("headingElement",function(a){a&&(b.html(""),b.append(a))})}}}).directive("uibTabContentTransclude",function(){function a(a){return a.tagName&&(a.hasAttribute("tab-heading")||a.hasAttribute("data-tab-heading")||a.hasAttribute("x-tab-heading")||a.hasAttribute("uib-tab-heading")||a.hasAttribute("data-uib-tab-heading")||a.hasAttribute("x-uib-tab-heading")||"tab-heading"===a.tagName.toLowerCase()||"data-tab-heading"===a.tagName.toLowerCase()||"x-tab-heading"===a.tagName.toLowerCase()||"uib-tab-heading"===a.tagName.toLowerCase()||"data-uib-tab-heading"===a.tagName.toLowerCase()||"x-uib-tab-heading"===a.tagName.toLowerCase())}return{restrict:"A",require:["?^uibTabset","?^tabset"],link:function(b,c,d){var e=b.$eval(d.uibTabContentTransclude);e.$transcludeFn(e.$parent,function(b){angular.forEach(b,function(b){a(b)?e.headingElement=b:c.append(b)})})}}}),angular.module("ui.bootstrap.tabs").value("$tabsSuppressWarning",!1).controller("TabsetController",["$scope","$controller","$log","$tabsSuppressWarning",function(a,b,c,d){return d||c.warn("TabsetController is now deprecated. Use UibTabsetController instead."),b("UibTabsetController",{$scope:a})}]).directive("tabset",["$log","$tabsSuppressWarning",function(a,b){return{restrict:"EA",transclude:!0,replace:!0,scope:{type:"@"},controller:"TabsetController",templateUrl:"template/tabs/tabset.html",link:function(c,d,e){b||a.warn("tabset is now deprecated. Use uib-tabset instead."),c.vertical=angular.isDefined(e.vertical)?c.$parent.$eval(e.vertical):!1,c.justified=angular.isDefined(e.justified)?c.$parent.$eval(e.justified):!1}}}]).directive("tab",["$parse","$log","$tabsSuppressWarning",function(a,b,c){return{require:"^tabset",restrict:"EA",replace:!0,templateUrl:"template/tabs/tab.html",transclude:!0,scope:{active:"=?",heading:"@",onSelect:"&select",onDeselect:"&deselect"},controller:function(){},link:function(d,e,f,g,h){c||b.warn("tab is now deprecated. Use uib-tab instead."),d.$watch("active",function(a){a&&g.select(d)}),d.disabled=!1,f.disable&&d.$parent.$watch(a(f.disable),function(a){d.disabled=!!a}),d.select=function(){d.disabled||(d.active=!0)},g.addTab(d),d.$on("$destroy",function(){g.removeTab(d)}),d.$transcludeFn=h}}}]).directive("tabHeadingTransclude",["$log","$tabsSuppressWarning",function(a,b){return{restrict:"A",require:"^tab",link:function(c,d){b||a.warn("tab-heading-transclude is now deprecated. Use uib-tab-heading-transclude instead."),c.$watch("headingElement",function(a){a&&(d.html(""),d.append(a))})}}}]).directive("tabContentTransclude",["$log","$tabsSuppressWarning",function(a,b){function c(a){return a.tagName&&(a.hasAttribute("tab-heading")||a.hasAttribute("data-tab-heading")||a.hasAttribute("x-tab-heading")||"tab-heading"===a.tagName.toLowerCase()||"data-tab-heading"===a.tagName.toLowerCase()||"x-tab-heading"===a.tagName.toLowerCase())}return{restrict:"A",require:"^tabset",link:function(d,e,f){b||a.warn("tab-content-transclude is now deprecated. Use uib-tab-content-transclude instead.");var g=d.$eval(f.tabContentTransclude);g.$transcludeFn(g.$parent,function(a){angular.forEach(a,function(a){c(a)?g.headingElement=a:e.append(a)})})}}}]),angular.module("ui.bootstrap.timepicker",[]).constant("uibTimepickerConfig",{hourStep:1,minuteStep:1,showMeridian:!0,meridians:null,readonlyInput:!1,mousewheel:!0,arrowkeys:!0,showSpinners:!0}).controller("UibTimepickerController",["$scope","$attrs","$parse","$log","$locale","uibTimepickerConfig",function(a,b,c,d,e,f){function g(){var b=parseInt(a.hours,10),c=a.showMeridian?b>0&&13>b:b>=0&&24>b;return c?(a.showMeridian&&(12===b&&(b=0),a.meridian===q[1]&&(b+=12)),b):void 0}function h(){var b=parseInt(a.minutes,10);return b>=0&&60>b?b:void 0}function i(a){return angular.isDefined(a)&&a.toString().length<2?"0"+a:a.toString()}function j(a){k(),p.$setViewValue(new Date(o)),l(a)}function k(){p.$setValidity("time",!0),a.invalidHours=!1,a.invalidMinutes=!1}function l(b){var c=o.getHours(),d=o.getMinutes();a.showMeridian&&(c=0===c||12===c?12:c%12),a.hours="h"===b?c:i(c),"m"!==b&&(a.minutes=i(d)),a.meridian=o.getHours()<12?q[0]:q[1]}function m(a,b){var c=new Date(a.getTime()+6e4*b),d=new Date(a);return d.setHours(c.getHours(),c.getMinutes()),d}function n(a){o=m(o,a),j()}var o=new Date,p={$setViewValue:angular.noop},q=angular.isDefined(b.meridians)?a.$parent.$eval(b.meridians):f.meridians||e.DATETIME_FORMATS.AMPMS;this.init=function(c,d){p=c,p.$render=this.render,p.$formatters.unshift(function(a){return a?new Date(a):null});var e=d.eq(0),g=d.eq(1),h=angular.isDefined(b.mousewheel)?a.$parent.$eval(b.mousewheel):f.mousewheel;h&&this.setupMousewheelEvents(e,g);var i=angular.isDefined(b.arrowkeys)?a.$parent.$eval(b.arrowkeys):f.arrowkeys;i&&this.setupArrowkeyEvents(e,g),a.readonlyInput=angular.isDefined(b.readonlyInput)?a.$parent.$eval(b.readonlyInput):f.readonlyInput,this.setupInputEvents(e,g)};var r=f.hourStep;b.hourStep&&a.$parent.$watch(c(b.hourStep),function(a){r=parseInt(a,10)});var s=f.minuteStep;b.minuteStep&&a.$parent.$watch(c(b.minuteStep),function(a){s=parseInt(a,10)});var t;a.$parent.$watch(c(b.min),function(a){var b=new Date(a);t=isNaN(b)?void 0:b});var u;a.$parent.$watch(c(b.max),function(a){var b=new Date(a);u=isNaN(b)?void 0:b}),a.noIncrementHours=function(){var a=m(o,60*r);return a>u||o>a&&t>a},a.noDecrementHours=function(){var a=m(o,60*-r);return t>a||a>o&&a>u},a.noIncrementMinutes=function(){var a=m(o,s);return a>u||o>a&&t>a},a.noDecrementMinutes=function(){var a=m(o,-s);return t>a||a>o&&a>u},a.noToggleMeridian=function(){return o.getHours()<13?m(o,720)>u:m(o,-720)<t},a.showMeridian=f.showMeridian,b.showMeridian&&a.$parent.$watch(c(b.showMeridian),function(b){if(a.showMeridian=!!b,p.$error.time){var c=g(),d=h();angular.isDefined(c)&&angular.isDefined(d)&&(o.setHours(c),j())}else l()}),this.setupMousewheelEvents=function(b,c){var d=function(a){a.originalEvent&&(a=a.originalEvent);var b=a.wheelDelta?a.wheelDelta:-a.deltaY;return a.detail||b>0};b.bind("mousewheel wheel",function(b){a.$apply(d(b)?a.incrementHours():a.decrementHours()),b.preventDefault()}),c.bind("mousewheel wheel",function(b){a.$apply(d(b)?a.incrementMinutes():a.decrementMinutes()),b.preventDefault()})},this.setupArrowkeyEvents=function(b,c){b.bind("keydown",function(b){38===b.which?(b.preventDefault(),a.incrementHours(),a.$apply()):40===b.which&&(b.preventDefault(),a.decrementHours(),a.$apply())}),c.bind("keydown",function(b){38===b.which?(b.preventDefault(),a.incrementMinutes(),a.$apply()):40===b.which&&(b.preventDefault(),a.decrementMinutes(),a.$apply())})},this.setupInputEvents=function(b,c){if(a.readonlyInput)return a.updateHours=angular.noop,void(a.updateMinutes=angular.noop);var d=function(b,c){p.$setViewValue(null),p.$setValidity("time",!1),angular.isDefined(b)&&(a.invalidHours=b),angular.isDefined(c)&&(a.invalidMinutes=c)};a.updateHours=function(){var a=g(),b=h();angular.isDefined(a)&&angular.isDefined(b)?(o.setHours(a),t>o||o>u?d(!0):j("h")):d(!0)},b.bind("blur",function(b){!a.invalidHours&&a.hours<10&&a.$apply(function(){a.hours=i(a.hours)})}),a.updateMinutes=function(){var a=h(),b=g();angular.isDefined(a)&&angular.isDefined(b)?(o.setMinutes(a),t>o||o>u?d(void 0,!0):j("m")):d(void 0,!0)},c.bind("blur",function(b){!a.invalidMinutes&&a.minutes<10&&a.$apply(function(){a.minutes=i(a.minutes)})})},this.render=function(){var b=p.$viewValue;isNaN(b)?(p.$setValidity("time",!1),d.error('Timepicker directive: "ng-model" value must be a Date object, a number of milliseconds since 01.01.1970 or a string representing an RFC2822 or ISO 8601 date.')):(b&&(o=b),t>o||o>u?(p.$setValidity("time",!1),a.invalidHours=!0,a.invalidMinutes=!0):k(),l())},a.showSpinners=angular.isDefined(b.showSpinners)?a.$parent.$eval(b.showSpinners):f.showSpinners,a.incrementHours=function(){a.noIncrementHours()||n(60*r)},a.decrementHours=function(){a.noDecrementHours()||n(60*-r)},a.incrementMinutes=function(){a.noIncrementMinutes()||n(s)},a.decrementMinutes=function(){a.noDecrementMinutes()||n(-s)},a.toggleMeridian=function(){a.noToggleMeridian()||n(720*(o.getHours()<12?1:-1))}}]).directive("uibTimepicker",function(){return{restrict:"EA",require:["uibTimepicker","?^ngModel"],controller:"UibTimepickerController",controllerAs:"timepicker",replace:!0,scope:{},templateUrl:function(a,b){return b.templateUrl||"template/timepicker/timepicker.html"},link:function(a,b,c,d){var e=d[0],f=d[1];f&&e.init(f,b.find("input"))}}}),angular.module("ui.bootstrap.timepicker").value("$timepickerSuppressWarning",!1).controller("TimepickerController",["$scope","$attrs","$controller","$log","$timepickerSuppressWarning",function(a,b,c,d,e){return e||d.warn("TimepickerController is now deprecated. Use UibTimepickerController instead."),c("UibTimepickerController",{$scope:a,$attrs:b})}]).directive("timepicker",["$log","$timepickerSuppressWarning",function(a,b){return{restrict:"EA",require:["timepicker","?^ngModel"],controller:"TimepickerController",controllerAs:"timepicker",replace:!0,scope:{},templateUrl:function(a,b){return b.templateUrl||"template/timepicker/timepicker.html"},link:function(c,d,e,f){b||a.warn("timepicker is now deprecated. Use uib-timepicker instead.");var g=f[0],h=f[1];h&&g.init(h,d.find("input"))}}}]),angular.module("ui.bootstrap.typeahead",["ui.bootstrap.position"]).factory("uibTypeaheadParser",["$parse",function(a){var b=/^\s*([\s\S]+?)(?:\s+as\s+([\s\S]+?))?\s+for\s+(?:([\$\w][\$\w\d]*))\s+in\s+([\s\S]+?)$/;return{parse:function(c){var d=c.match(b);if(!d)throw new Error('Expected typeahead specification in form of "_modelValue_ (as _label_)? for _item_ in _collection_" but got "'+c+'".');return{itemName:d[3],source:a(d[4]),viewMapper:a(d[2]||d[1]),modelMapper:a(d[1])}}}}]).directive("uibTypeahead",["$compile","$parse","$q","$timeout","$document","$window","$rootScope","$uibPosition","uibTypeaheadParser",function(a,b,c,d,e,f,g,h,i){var j=[9,13,27,38,40],k=200;return{require:["ngModel","^?ngModelOptions"],link:function(l,m,n,o){function p(){L.moveInProgress||(L.moveInProgress=!0,L.$digest()),T&&d.cancel(T),T=d(function(){L.matches.length&&q(),L.moveInProgress=!1},k)}function q(){L.position=D?h.offset(m):h.position(m),L.position.top+=m.prop("offsetHeight")}var r=o[0],s=o[1],t=l.$eval(n.typeaheadMinLength);t||0===t||(t=1);var u,v,w=l.$eval(n.typeaheadWaitMs)||0,x=l.$eval(n.typeaheadEditable)!==!1,y=b(n.typeaheadLoading).assign||angular.noop,z=b(n.typeaheadOnSelect),A=angular.isDefined(n.typeaheadSelectOnBlur)?l.$eval(n.typeaheadSelectOnBlur):!1,B=b(n.typeaheadNoResults).assign||angular.noop,C=n.typeaheadInputFormatter?b(n.typeaheadInputFormatter):void 0,D=n.typeaheadAppendToBody?l.$eval(n.typeaheadAppendToBody):!1,E=n.typeaheadAppendToElementId||!1,F=l.$eval(n.typeaheadFocusFirst)!==!1,G=n.typeaheadSelectOnExact?l.$eval(n.typeaheadSelectOnExact):!1,H=b(n.ngModel),I=b(n.ngModel+"($$$p)"),J=function(a,b){return angular.isFunction(H(l))&&s&&s.$options&&s.$options.getterSetter?I(a,{$$$p:b}):H.assign(a,b)},K=i.parse(n.uibTypeahead),L=l.$new(),M=l.$on("$destroy",function(){L.$destroy()});L.$on("$destroy",M);var N="typeahead-"+L.$id+"-"+Math.floor(1e4*Math.random());m.attr({"aria-autocomplete":"list","aria-expanded":!1,"aria-owns":N});var O=angular.element("<div uib-typeahead-popup></div>");O.attr({id:N,matches:"matches",active:"activeIdx",select:"select(activeIdx)","move-in-progress":"moveInProgress",query:"query",position:"position"}),angular.isDefined(n.typeaheadTemplateUrl)&&O.attr("template-url",n.typeaheadTemplateUrl),angular.isDefined(n.typeaheadPopupTemplateUrl)&&O.attr("popup-template-url",n.typeaheadPopupTemplateUrl);var P=function(){L.matches=[],L.activeIdx=-1,m.attr("aria-expanded",!1)},Q=function(a){return N+"-option-"+a};L.$watch("activeIdx",function(a){0>a?m.removeAttr("aria-activedescendant"):m.attr("aria-activedescendant",Q(a))});var R=function(a,b){return L.matches.length>b&&a?a.toUpperCase()===L.matches[b].label.toUpperCase():!1},S=function(a){var b={$viewValue:a};y(l,!0),B(l,!1),c.when(K.source(l,b)).then(function(c){var d=a===r.$viewValue;if(d&&u)if(c&&c.length>0){L.activeIdx=F?0:-1,B(l,!1),L.matches.length=0;for(var e=0;e<c.length;e++)b[K.itemName]=c[e],L.matches.push({id:Q(e),label:K.viewMapper(L,b),model:c[e]});L.query=a,q(),m.attr("aria-expanded",!0),G&&1===L.matches.length&&R(a,0)&&L.select(0)}else P(),B(l,!0);d&&y(l,!1)},function(){P(),y(l,!1),B(l,!0)})};D&&(angular.element(f).bind("resize",p),e.find("body").bind("scroll",p));var T;L.moveInProgress=!1,P(),L.query=void 0;var U,V=function(a){U=d(function(){S(a)},w)},W=function(){U&&d.cancel(U)};r.$parsers.unshift(function(a){return u=!0,0===t||a&&a.length>=t?w>0?(W(),V(a)):S(a):(y(l,!1),W(),P()),x?a:a?void r.$setValidity("editable",!1):(r.$setValidity("editable",!0),null)}),r.$formatters.push(function(a){var b,c,d={};return x||r.$setValidity("editable",!0),C?(d.$model=a,C(l,d)):(d[K.itemName]=a,b=K.viewMapper(l,d),d[K.itemName]=void 0,c=K.viewMapper(l,d),b!==c?b:a)}),L.select=function(a){var b,c,e={};v=!0,e[K.itemName]=c=L.matches[a].model,b=K.modelMapper(l,e),J(l,b),r.$setValidity("editable",!0),r.$setValidity("parse",!0),z(l,{$item:c,$model:b,$label:K.viewMapper(l,e)}),P(),L.$eval(n.typeaheadFocusOnSelect)!==!1&&d(function(){m[0].focus()},0,!1)},m.bind("keydown",function(a){if(0!==L.matches.length&&-1!==j.indexOf(a.which)){if(-1===L.activeIdx&&(9===a.which||13===a.which))return P(),void L.$digest();a.preventDefault(), | 10 | }}}]),angular.module("ui.bootstrap.tooltip",["ui.bootstrap.position","ui.bootstrap.stackedMap"]).provider("$uibTooltip",function(){function a(a){var b=/[A-Z]/g,c="-";return a.replace(b,function(a,b){return(b?c:"")+a.toLowerCase()})}var b={placement:"top",animation:!0,popupDelay:0,popupCloseDelay:500,useContentExp:!1},c={mouseenter:"mouseleave",click:"click",focus:"blur",none:""},d={};this.options=function(a){angular.extend(d,a)},this.setTriggers=function(a){angular.extend(c,a)},this.$get=["$window","$compile","$timeout","$document","$uibPosition","$interpolate","$rootScope","$parse","$$stackedMap",function(e,f,g,h,i,j,k,l,m){var n=m.createNew();return h.on("keypress",function(a){if(27===a.which){var b=n.top();b&&(b.value.close(),n.removeTop(),b=null)}}),function(e,k,m,o){function p(a){var b=(a||o.trigger||m).split(" "),d=b.map(function(a){return c[a]||a});return{show:b,hide:d}}o=angular.extend({},b,d,o);var q=a(e),r=j.startSymbol(),s=j.endSymbol(),t="<div "+q+'-popup title="'+r+"title"+s+'" '+(o.useContentExp?'content-exp="contentExp()" ':'content="'+r+"content"+s+'" ')+'placement="'+r+"placement"+s+'" popup-class="'+r+"popupClass"+s+'" animation="animation" is-open="isOpen"origin-scope="origScope" style="visibility: hidden; display: block;"></div>';return{compile:function(a,b){var c=f(t);return function(a,b,d,f){function j(){H.isOpen?q():m()}function m(){(!G||a.$eval(d[k+"Enable"]))&&(v(),H.popupDelay?C||(C=g(r,H.popupDelay,!1)):r())}function q(){s()}function r(){return C&&(g.cancel(C),C=null),B&&(g.cancel(B),B=null),H.content?(t(),void H.$evalAsync(function(){H.isOpen=!0,J&&angular.isFunction(J.assign)&&J.assign(H.origScope,H.isOpen),M()})):angular.noop}function s(){H&&(H.$evalAsync(function(){H.isOpen=!1,J&&angular.isFunction(J.assign)&&J.assign(H.origScope,H.isOpen)}),g.cancel(C),C=null,g.cancel(D),D=null,H.animation?B||(B=g(u,H.popupCloseDelay)):u())}function t(){z||(A=H.$new(),z=c(A,function(a){E?h.find("body").append(a):b.after(a)}),w())}function u(){x(),B=null,z&&(z.remove(),z=null),A&&(A.$destroy(),A=null)}function v(){H.title=d[k+"Title"],K?H.content=K(a):H.content=d[e],H.popupClass=d[k+"Class"],H.placement=angular.isDefined(d[k+"Placement"])?d[k+"Placement"]:o.placement;var b=parseInt(d[k+"PopupDelay"],10),c=parseInt(d[k+"PopupCloseDelay"],10);H.popupDelay=isNaN(b)?o.popupDelay:b,H.popupCloseDelay=isNaN(c)?o.popupCloseDelay:c}function w(){L.length=0,K?(L.push(a.$watch(K,function(a){H.content=a,!a&&H.isOpen&&s()})),L.push(A.$watch(function(){I||(I=!0,A.$$postDigest(function(){I=!1,H&&H.isOpen&&M()}))}))):L.push(d.$observe(e,function(a){H.content=a,!a&&H.isOpen?s():M()})),L.push(d.$observe(k+"Title",function(a){H.title=a,H.isOpen&&M()})),L.push(d.$observe(k+"Placement",function(a){H.placement=a?a:o.placement,H.isOpen&&M()}))}function x(){L.length&&(angular.forEach(L,function(a){a()}),L.length=0)}function y(){var a=d[k+"Trigger"];N(),F=p(a),"none"!==F.show&&F.show.forEach(function(a,c){a===F.hide[c]?b[0].addEventListener(a,j):a&&(b[0].addEventListener(a,m),F.hide[c].split(" ").forEach(function(a){b[0].addEventListener(a,q)})),b.on("keypress",function(a){27===a.which&&q()})})}var z,A,B,C,D,E=angular.isDefined(o.appendToBody)?o.appendToBody:!1,F=p(void 0),G=angular.isDefined(d[k+"Enable"]),H=a.$new(!0),I=!1,J=angular.isDefined(d[k+"IsOpen"])?l(d[k+"IsOpen"]):!1,K=o.useContentExp?l(d[e]):!1,L=[],M=function(){z&&z.html()&&(D||(D=g(function(){z.css({top:0,left:0});var a=i.positionElements(b,z,H.placement,E);a.top+="px",a.left+="px",a.visibility="visible",z.css(a),D=null},0,!1)))};H.origScope=a,H.isOpen=!1,n.add(H,{close:s}),H.contentExp=function(){return H.content},d.$observe("disabled",function(a){C&&a&&(g.cancel(C),C=null),a&&H.isOpen&&s()}),J&&a.$watch(J,function(a){!a===H.isOpen&&j()});var N=function(){F.show.forEach(function(a){b.unbind(a,m)}),F.hide.forEach(function(a){a.split(" ").forEach(function(a){b[0].removeEventListener(a,q)})})};y();var O=a.$eval(d[k+"Animation"]);H.animation=angular.isDefined(O)?!!O:o.animation;var P=a.$eval(d[k+"AppendToBody"]);E=angular.isDefined(P)?P:E,E&&a.$on("$locationChangeSuccess",function(){H.isOpen&&s()}),a.$on("$destroy",function(){g.cancel(B),g.cancel(C),g.cancel(D),N(),u(),H=null})}}}}}]}).directive("uibTooltipTemplateTransclude",["$animate","$sce","$compile","$templateRequest",function(a,b,c,d){return{link:function(e,f,g){var h,i,j,k=e.$eval(g.tooltipTemplateTranscludeScope),l=0,m=function(){i&&(i.remove(),i=null),h&&(h.$destroy(),h=null),j&&(a.leave(j).then(function(){i=null}),i=j,j=null)};e.$watch(b.parseAsResourceUrl(g.uibTooltipTemplateTransclude),function(b){var g=++l;b?(d(b,!0).then(function(d){if(g===l){var e=k.$new(),i=d,n=c(i)(e,function(b){m(),a.enter(b,f)});h=e,j=n,h.$emit("$includeContentLoaded",b)}},function(){g===l&&(m(),e.$emit("$includeContentError",b))}),e.$emit("$includeContentRequested",b)):m()}),e.$on("$destroy",m)}}}]).directive("uibTooltipClasses",function(){return{restrict:"A",link:function(a,b,c){a.placement&&b.addClass(a.placement),a.popupClass&&b.addClass(a.popupClass),a.animation()&&b.addClass(c.tooltipAnimationClass)}}}).directive("uibTooltipPopup",function(){return{replace:!0,scope:{content:"@",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"template/tooltip/tooltip-popup.html",link:function(a,b){b.addClass("tooltip")}}}).directive("uibTooltip",["$uibTooltip",function(a){return a("uibTooltip","tooltip","mouseenter")}]).directive("uibTooltipTemplatePopup",function(){return{replace:!0,scope:{contentExp:"&",placement:"@",popupClass:"@",animation:"&",isOpen:"&",originScope:"&"},templateUrl:"template/tooltip/tooltip-template-popup.html",link:function(a,b){b.addClass("tooltip")}}}).directive("uibTooltipTemplate",["$uibTooltip",function(a){return a("uibTooltipTemplate","tooltip","mouseenter",{useContentExp:!0})}]).directive("uibTooltipHtmlPopup",function(){return{replace:!0,scope:{contentExp:"&",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"template/tooltip/tooltip-html-popup.html",link:function(a,b){b.addClass("tooltip")}}}).directive("uibTooltipHtml",["$uibTooltip",function(a){return a("uibTooltipHtml","tooltip","mouseenter",{useContentExp:!0})}]),angular.module("ui.bootstrap.tooltip").value("$tooltipSuppressWarning",!1).provider("$tooltip",["$uibTooltipProvider",function(a){angular.extend(this,a),this.$get=["$log","$tooltipSuppressWarning","$injector",function(b,c,d){return c||b.warn("$tooltip is now deprecated. Use $uibTooltip instead."),d.invoke(a.$get)}]}]).directive("tooltipTemplateTransclude",["$animate","$sce","$compile","$templateRequest","$log","$tooltipSuppressWarning",function(a,b,c,d,e,f){return{link:function(g,h,i){f||e.warn("tooltip-template-transclude is now deprecated. Use uib-tooltip-template-transclude instead.");var j,k,l,m=g.$eval(i.tooltipTemplateTranscludeScope),n=0,o=function(){k&&(k.remove(),k=null),j&&(j.$destroy(),j=null),l&&(a.leave(l).then(function(){k=null}),k=l,l=null)};g.$watch(b.parseAsResourceUrl(i.tooltipTemplateTransclude),function(b){var e=++n;b?(d(b,!0).then(function(d){if(e===n){var f=m.$new(),g=d,i=c(g)(f,function(b){o(),a.enter(b,h)});j=f,l=i,j.$emit("$includeContentLoaded",b)}},function(){e===n&&(o(),g.$emit("$includeContentError",b))}),g.$emit("$includeContentRequested",b)):o()}),g.$on("$destroy",o)}}}]).directive("tooltipClasses",["$log","$tooltipSuppressWarning",function(a,b){return{restrict:"A",link:function(c,d,e){b||a.warn("tooltip-classes is now deprecated. Use uib-tooltip-classes instead."),c.placement&&d.addClass(c.placement),c.popupClass&&d.addClass(c.popupClass),c.animation()&&d.addClass(e.tooltipAnimationClass)}}}]).directive("tooltipPopup",["$log","$tooltipSuppressWarning",function(a,b){return{replace:!0,scope:{content:"@",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"template/tooltip/tooltip-popup.html",link:function(c,d){b||a.warn("tooltip-popup is now deprecated. Use uib-tooltip-popup instead."),d.addClass("tooltip")}}}]).directive("tooltip",["$tooltip",function(a){return a("tooltip","tooltip","mouseenter")}]).directive("tooltipTemplatePopup",["$log","$tooltipSuppressWarning",function(a,b){return{replace:!0,scope:{contentExp:"&",placement:"@",popupClass:"@",animation:"&",isOpen:"&",originScope:"&"},templateUrl:"template/tooltip/tooltip-template-popup.html",link:function(c,d){b||a.warn("tooltip-template-popup is now deprecated. Use uib-tooltip-template-popup instead."),d.addClass("tooltip")}}}]).directive("tooltipTemplate",["$tooltip",function(a){return a("tooltipTemplate","tooltip","mouseenter",{useContentExp:!0})}]).directive("tooltipHtmlPopup",["$log","$tooltipSuppressWarning",function(a,b){return{replace:!0,scope:{contentExp:"&",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"template/tooltip/tooltip-html-popup.html",link:function(c,d){b||a.warn("tooltip-html-popup is now deprecated. Use uib-tooltip-html-popup instead."),d.addClass("tooltip")}}}]).directive("tooltipHtml",["$tooltip",function(a){return a("tooltipHtml","tooltip","mouseenter",{useContentExp:!0})}]),angular.module("ui.bootstrap.popover",["ui.bootstrap.tooltip"]).directive("uibPopoverTemplatePopup",function(){return{replace:!0,scope:{title:"@",contentExp:"&",placement:"@",popupClass:"@",animation:"&",isOpen:"&",originScope:"&"},templateUrl:"template/popover/popover-template.html",link:function(a,b){b.addClass("popover")}}}).directive("uibPopoverTemplate",["$uibTooltip",function(a){return a("uibPopoverTemplate","popover","click",{useContentExp:!0})}]).directive("uibPopoverHtmlPopup",function(){return{replace:!0,scope:{contentExp:"&",title:"@",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"template/popover/popover-html.html",link:function(a,b){b.addClass("popover")}}}).directive("uibPopoverHtml",["$uibTooltip",function(a){return a("uibPopoverHtml","popover","click",{useContentExp:!0})}]).directive("uibPopoverPopup",function(){return{replace:!0,scope:{title:"@",content:"@",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"template/popover/popover.html",link:function(a,b){b.addClass("popover")}}}).directive("uibPopover",["$uibTooltip",function(a){return a("uibPopover","popover","click")}]),angular.module("ui.bootstrap.popover").value("$popoverSuppressWarning",!1).directive("popoverTemplatePopup",["$log","$popoverSuppressWarning",function(a,b){return{replace:!0,scope:{title:"@",contentExp:"&",placement:"@",popupClass:"@",animation:"&",isOpen:"&",originScope:"&"},templateUrl:"template/popover/popover-template.html",link:function(c,d){b||a.warn("popover-template-popup is now deprecated. Use uib-popover-template-popup instead."),d.addClass("popover")}}}]).directive("popoverTemplate",["$tooltip",function(a){return a("popoverTemplate","popover","click",{useContentExp:!0})}]).directive("popoverHtmlPopup",["$log","$popoverSuppressWarning",function(a,b){return{replace:!0,scope:{contentExp:"&",title:"@",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"template/popover/popover-html.html",link:function(c,d){b||a.warn("popover-html-popup is now deprecated. Use uib-popover-html-popup instead."),d.addClass("popover")}}}]).directive("popoverHtml",["$tooltip",function(a){return a("popoverHtml","popover","click",{useContentExp:!0})}]).directive("popoverPopup",["$log","$popoverSuppressWarning",function(a,b){return{replace:!0,scope:{title:"@",content:"@",placement:"@",popupClass:"@",animation:"&",isOpen:"&"},templateUrl:"template/popover/popover.html",link:function(c,d){b||a.warn("popover-popup is now deprecated. Use uib-popover-popup instead."),d.addClass("popover")}}}]).directive("popover",["$tooltip",function(a){return a("popover","popover","click")}]),angular.module("ui.bootstrap.progressbar",[]).constant("uibProgressConfig",{animate:!0,max:100}).controller("UibProgressController",["$scope","$attrs","uibProgressConfig",function(a,b,c){var d=this,e=angular.isDefined(b.animate)?a.$parent.$eval(b.animate):c.animate;this.bars=[],a.max=angular.isDefined(a.max)?a.max:c.max,this.addBar=function(b,c,f){e||c.css({transition:"none"}),this.bars.push(b),b.max=a.max,b.title=f&&angular.isDefined(f.title)?f.title:"progressbar",b.$watch("value",function(a){b.recalculatePercentage()}),b.recalculatePercentage=function(){b.percent=+(100*b.value/b.max).toFixed(2);var a=d.bars.reduce(function(a,b){return a+b.percent},0);a>100&&(b.percent-=a-100)},b.$on("$destroy",function(){c=null,d.removeBar(b)})},this.removeBar=function(a){this.bars.splice(this.bars.indexOf(a),1)},a.$watch("max",function(b){d.bars.forEach(function(b){b.max=a.max,b.recalculatePercentage()})})}]).directive("uibProgress",function(){return{replace:!0,transclude:!0,controller:"UibProgressController",require:"uibProgress",scope:{max:"=?"},templateUrl:"template/progressbar/progress.html"}}).directive("uibBar",function(){return{replace:!0,transclude:!0,require:"^uibProgress",scope:{value:"=",type:"@"},templateUrl:"template/progressbar/bar.html",link:function(a,b,c,d){d.addBar(a,b,c)}}}).directive("uibProgressbar",function(){return{replace:!0,transclude:!0,controller:"UibProgressController",scope:{value:"=",max:"=?",type:"@"},templateUrl:"template/progressbar/progressbar.html",link:function(a,b,c,d){d.addBar(a,angular.element(b.children()[0]),{title:c.title})}}}),angular.module("ui.bootstrap.progressbar").value("$progressSuppressWarning",!1).controller("ProgressController",["$scope","$attrs","$controller","$log","$progressSuppressWarning",function(a,b,c,d,e){return e||d.warn("ProgressController is now deprecated. Use UibProgressController instead."),c("UibProgressController",{$scope:a,$attrs:b})}]).directive("progress",["$log","$progressSuppressWarning",function(a,b){return{replace:!0,transclude:!0,controller:"ProgressController",require:"progress",scope:{max:"=?",title:"@?"},templateUrl:"template/progressbar/progress.html",link:function(){b||a.warn("progress is now deprecated. Use uib-progress instead.")}}}]).directive("bar",["$log","$progressSuppressWarning",function(a,b){return{replace:!0,transclude:!0,require:"^progress",scope:{value:"=",type:"@"},templateUrl:"template/progressbar/bar.html",link:function(c,d,e,f){b||a.warn("bar is now deprecated. Use uib-bar instead."),f.addBar(c,d)}}}]).directive("progressbar",["$log","$progressSuppressWarning",function(a,b){return{replace:!0,transclude:!0,controller:"ProgressController",scope:{value:"=",max:"=?",type:"@"},templateUrl:"template/progressbar/progressbar.html",link:function(c,d,e,f){b||a.warn("progressbar is now deprecated. Use uib-progressbar instead."),f.addBar(c,angular.element(d.children()[0]),{title:e.title})}}}]),angular.module("ui.bootstrap.rating",[]).constant("uibRatingConfig",{max:5,stateOn:null,stateOff:null,titles:["one","two","three","four","five"]}).controller("UibRatingController",["$scope","$attrs","uibRatingConfig",function(a,b,c){var d={$setViewValue:angular.noop};this.init=function(e){d=e,d.$render=this.render,d.$formatters.push(function(a){return angular.isNumber(a)&&a<<0!==a&&(a=Math.round(a)),a}),this.stateOn=angular.isDefined(b.stateOn)?a.$parent.$eval(b.stateOn):c.stateOn,this.stateOff=angular.isDefined(b.stateOff)?a.$parent.$eval(b.stateOff):c.stateOff;var f=angular.isDefined(b.titles)?a.$parent.$eval(b.titles):c.titles;this.titles=angular.isArray(f)&&f.length>0?f:c.titles;var g=angular.isDefined(b.ratingStates)?a.$parent.$eval(b.ratingStates):new Array(angular.isDefined(b.max)?a.$parent.$eval(b.max):c.max);a.range=this.buildTemplateObjects(g)},this.buildTemplateObjects=function(a){for(var b=0,c=a.length;c>b;b++)a[b]=angular.extend({index:b},{stateOn:this.stateOn,stateOff:this.stateOff,title:this.getTitle(b)},a[b]);return a},this.getTitle=function(a){return a>=this.titles.length?a+1:this.titles[a]},a.rate=function(b){!a.readonly&&b>=0&&b<=a.range.length&&(d.$setViewValue(d.$viewValue===b?0:b),d.$render())},a.enter=function(b){a.readonly||(a.value=b),a.onHover({value:b})},a.reset=function(){a.value=d.$viewValue,a.onLeave()},a.onKeydown=function(b){/(37|38|39|40)/.test(b.which)&&(b.preventDefault(),b.stopPropagation(),a.rate(a.value+(38===b.which||39===b.which?1:-1)))},this.render=function(){a.value=d.$viewValue}}]).directive("uibRating",function(){return{require:["uibRating","ngModel"],scope:{readonly:"=?",onHover:"&",onLeave:"&"},controller:"UibRatingController",templateUrl:"template/rating/rating.html",replace:!0,link:function(a,b,c,d){var e=d[0],f=d[1];e.init(f)}}}),angular.module("ui.bootstrap.rating").value("$ratingSuppressWarning",!1).controller("RatingController",["$scope","$attrs","$controller","$log","$ratingSuppressWarning",function(a,b,c,d,e){return e||d.warn("RatingController is now deprecated. Use UibRatingController instead."),c("UibRatingController",{$scope:a,$attrs:b})}]).directive("rating",["$log","$ratingSuppressWarning",function(a,b){return{require:["rating","ngModel"],scope:{readonly:"=?",onHover:"&",onLeave:"&"},controller:"RatingController",templateUrl:"template/rating/rating.html",replace:!0,link:function(c,d,e,f){b||a.warn("rating is now deprecated. Use uib-rating instead.");var g=f[0],h=f[1];g.init(h)}}}]),angular.module("ui.bootstrap.tabs",[]).controller("UibTabsetController",["$scope",function(a){var b=this,c=b.tabs=a.tabs=[];b.select=function(a){angular.forEach(c,function(b){b.active&&b!==a&&(b.active=!1,b.onDeselect(),a.selectCalled=!1)}),a.active=!0,a.selectCalled||(a.onSelect(),a.selectCalled=!0)},b.addTab=function(a){c.push(a),1===c.length&&a.active!==!1?a.active=!0:a.active?b.select(a):a.active=!1},b.removeTab=function(a){var e=c.indexOf(a);if(a.active&&c.length>1&&!d){var f=e==c.length-1?e-1:e+1;b.select(c[f])}c.splice(e,1)};var d;a.$on("$destroy",function(){d=!0})}]).directive("uibTabset",function(){return{restrict:"EA",transclude:!0,replace:!0,scope:{type:"@"},controller:"UibTabsetController",templateUrl:"template/tabs/tabset.html",link:function(a,b,c){a.vertical=angular.isDefined(c.vertical)?a.$parent.$eval(c.vertical):!1,a.justified=angular.isDefined(c.justified)?a.$parent.$eval(c.justified):!1}}}).directive("uibTab",["$parse",function(a){return{require:"^uibTabset",restrict:"EA",replace:!0,templateUrl:"template/tabs/tab.html",transclude:!0,scope:{active:"=?",heading:"@",onSelect:"&select",onDeselect:"&deselect"},controller:function(){},link:function(b,c,d,e,f){b.$watch("active",function(a){a&&e.select(b)}),b.disabled=!1,d.disable&&b.$parent.$watch(a(d.disable),function(a){b.disabled=!!a}),b.select=function(){b.disabled||(b.active=!0)},e.addTab(b),b.$on("$destroy",function(){e.removeTab(b)}),b.$transcludeFn=f}}}]).directive("uibTabHeadingTransclude",function(){return{restrict:"A",require:["?^uibTab","?^tab"],link:function(a,b){a.$watch("headingElement",function(a){a&&(b.html(""),b.append(a))})}}}).directive("uibTabContentTransclude",function(){function a(a){return a.tagName&&(a.hasAttribute("tab-heading")||a.hasAttribute("data-tab-heading")||a.hasAttribute("x-tab-heading")||a.hasAttribute("uib-tab-heading")||a.hasAttribute("data-uib-tab-heading")||a.hasAttribute("x-uib-tab-heading")||"tab-heading"===a.tagName.toLowerCase()||"data-tab-heading"===a.tagName.toLowerCase()||"x-tab-heading"===a.tagName.toLowerCase()||"uib-tab-heading"===a.tagName.toLowerCase()||"data-uib-tab-heading"===a.tagName.toLowerCase()||"x-uib-tab-heading"===a.tagName.toLowerCase())}return{restrict:"A",require:["?^uibTabset","?^tabset"],link:function(b,c,d){var e=b.$eval(d.uibTabContentTransclude);e.$transcludeFn(e.$parent,function(b){angular.forEach(b,function(b){a(b)?e.headingElement=b:c.append(b)})})}}}),angular.module("ui.bootstrap.tabs").value("$tabsSuppressWarning",!1).controller("TabsetController",["$scope","$controller","$log","$tabsSuppressWarning",function(a,b,c,d){return d||c.warn("TabsetController is now deprecated. Use UibTabsetController instead."),b("UibTabsetController",{$scope:a})}]).directive("tabset",["$log","$tabsSuppressWarning",function(a,b){return{restrict:"EA",transclude:!0,replace:!0,scope:{type:"@"},controller:"TabsetController",templateUrl:"template/tabs/tabset.html",link:function(c,d,e){b||a.warn("tabset is now deprecated. Use uib-tabset instead."),c.vertical=angular.isDefined(e.vertical)?c.$parent.$eval(e.vertical):!1,c.justified=angular.isDefined(e.justified)?c.$parent.$eval(e.justified):!1}}}]).directive("tab",["$parse","$log","$tabsSuppressWarning",function(a,b,c){return{require:"^tabset",restrict:"EA",replace:!0,templateUrl:"template/tabs/tab.html",transclude:!0,scope:{active:"=?",heading:"@",onSelect:"&select",onDeselect:"&deselect"},controller:function(){},link:function(d,e,f,g,h){c||b.warn("tab is now deprecated. Use uib-tab instead."),d.$watch("active",function(a){a&&g.select(d)}),d.disabled=!1,f.disable&&d.$parent.$watch(a(f.disable),function(a){d.disabled=!!a}),d.select=function(){d.disabled||(d.active=!0)},g.addTab(d),d.$on("$destroy",function(){g.removeTab(d)}),d.$transcludeFn=h}}}]).directive("tabHeadingTransclude",["$log","$tabsSuppressWarning",function(a,b){return{restrict:"A",require:"^tab",link:function(c,d){b||a.warn("tab-heading-transclude is now deprecated. Use uib-tab-heading-transclude instead."),c.$watch("headingElement",function(a){a&&(d.html(""),d.append(a))})}}}]).directive("tabContentTransclude",["$log","$tabsSuppressWarning",function(a,b){function c(a){return a.tagName&&(a.hasAttribute("tab-heading")||a.hasAttribute("data-tab-heading")||a.hasAttribute("x-tab-heading")||"tab-heading"===a.tagName.toLowerCase()||"data-tab-heading"===a.tagName.toLowerCase()||"x-tab-heading"===a.tagName.toLowerCase())}return{restrict:"A",require:"^tabset",link:function(d,e,f){b||a.warn("tab-content-transclude is now deprecated. Use uib-tab-content-transclude instead.");var g=d.$eval(f.tabContentTransclude);g.$transcludeFn(g.$parent,function(a){angular.forEach(a,function(a){c(a)?g.headingElement=a:e.append(a)})})}}}]),angular.module("ui.bootstrap.timepicker",[]).constant("uibTimepickerConfig",{hourStep:1,minuteStep:1,showMeridian:!0,meridians:null,readonlyInput:!1,mousewheel:!0,arrowkeys:!0,showSpinners:!0}).controller("UibTimepickerController",["$scope","$attrs","$parse","$log","$locale","uibTimepickerConfig",function(a,b,c,d,e,f){function g(){var b=parseInt(a.hours,10),c=a.showMeridian?b>0&&13>b:b>=0&&24>b;return c?(a.showMeridian&&(12===b&&(b=0),a.meridian===q[1]&&(b+=12)),b):void 0}function h(){var b=parseInt(a.minutes,10);return b>=0&&60>b?b:void 0}function i(a){return angular.isDefined(a)&&a.toString().length<2?"0"+a:a.toString()}function j(a){k(),p.$setViewValue(new Date(o)),l(a)}function k(){p.$setValidity("time",!0),a.invalidHours=!1,a.invalidMinutes=!1}function l(b){var c=o.getHours(),d=o.getMinutes();a.showMeridian&&(c=0===c||12===c?12:c%12),a.hours="h"===b?c:i(c),"m"!==b&&(a.minutes=i(d)),a.meridian=o.getHours()<12?q[0]:q[1]}function m(a,b){var c=new Date(a.getTime()+6e4*b),d=new Date(a);return d.setHours(c.getHours(),c.getMinutes()),d}function n(a){o=m(o,a),j()}var o=new Date,p={$setViewValue:angular.noop},q=angular.isDefined(b.meridians)?a.$parent.$eval(b.meridians):f.meridians||e.DATETIME_FORMATS.AMPMS;this.init=function(c,d){p=c,p.$render=this.render,p.$formatters.unshift(function(a){return a?new Date(a):null});var e=d.eq(0),g=d.eq(1),h=angular.isDefined(b.mousewheel)?a.$parent.$eval(b.mousewheel):f.mousewheel;h&&this.setupMousewheelEvents(e,g);var i=angular.isDefined(b.arrowkeys)?a.$parent.$eval(b.arrowkeys):f.arrowkeys;i&&this.setupArrowkeyEvents(e,g),a.readonlyInput=angular.isDefined(b.readonlyInput)?a.$parent.$eval(b.readonlyInput):f.readonlyInput,this.setupInputEvents(e,g)};var r=f.hourStep;b.hourStep&&a.$parent.$watch(c(b.hourStep),function(a){r=parseInt(a,10)});var s=f.minuteStep;b.minuteStep&&a.$parent.$watch(c(b.minuteStep),function(a){s=parseInt(a,10)});var t;a.$parent.$watch(c(b.min),function(a){var b=new Date(a);t=isNaN(b)?void 0:b});var u;a.$parent.$watch(c(b.max),function(a){var b=new Date(a);u=isNaN(b)?void 0:b}),a.noIncrementHours=function(){var a=m(o,60*r);return a>u||o>a&&t>a},a.noDecrementHours=function(){var a=m(o,60*-r);return t>a||a>o&&a>u},a.noIncrementMinutes=function(){var a=m(o,s);return a>u||o>a&&t>a},a.noDecrementMinutes=function(){var a=m(o,-s);return t>a||a>o&&a>u},a.noToggleMeridian=function(){return o.getHours()<13?m(o,720)>u:m(o,-720)<t},a.showMeridian=f.showMeridian,b.showMeridian&&a.$parent.$watch(c(b.showMeridian),function(b){if(a.showMeridian=!!b,p.$error.time){var c=g(),d=h();angular.isDefined(c)&&angular.isDefined(d)&&(o.setHours(c),j())}else l()}),this.setupMousewheelEvents=function(b,c){var d=function(a){a.originalEvent&&(a=a.originalEvent);var b=a.wheelDelta?a.wheelDelta:-a.deltaY;return a.detail||b>0};b.bind("mousewheel wheel",function(b){a.$apply(d(b)?a.incrementHours():a.decrementHours()),b.preventDefault()}),c.bind("mousewheel wheel",function(b){a.$apply(d(b)?a.incrementMinutes():a.decrementMinutes()),b.preventDefault()})},this.setupArrowkeyEvents=function(b,c){b.bind("keydown",function(b){38===b.which?(b.preventDefault(),a.incrementHours(),a.$apply()):40===b.which&&(b.preventDefault(),a.decrementHours(),a.$apply())}),c.bind("keydown",function(b){38===b.which?(b.preventDefault(),a.incrementMinutes(),a.$apply()):40===b.which&&(b.preventDefault(),a.decrementMinutes(),a.$apply())})},this.setupInputEvents=function(b,c){if(a.readonlyInput)return a.updateHours=angular.noop,void(a.updateMinutes=angular.noop);var d=function(b,c){p.$setViewValue(null),p.$setValidity("time",!1),angular.isDefined(b)&&(a.invalidHours=b),angular.isDefined(c)&&(a.invalidMinutes=c)};a.updateHours=function(){var a=g(),b=h();angular.isDefined(a)&&angular.isDefined(b)?(o.setHours(a),t>o||o>u?d(!0):j("h")):d(!0)},b.bind("blur",function(b){!a.invalidHours&&a.hours<10&&a.$apply(function(){a.hours=i(a.hours)})}),a.updateMinutes=function(){var a=h(),b=g();angular.isDefined(a)&&angular.isDefined(b)?(o.setMinutes(a),t>o||o>u?d(void 0,!0):j("m")):d(void 0,!0)},c.bind("blur",function(b){!a.invalidMinutes&&a.minutes<10&&a.$apply(function(){a.minutes=i(a.minutes)})})},this.render=function(){var b=p.$viewValue;isNaN(b)?(p.$setValidity("time",!1),d.error('Timepicker directive: "ng-model" value must be a Date object, a number of milliseconds since 01.01.1970 or a string representing an RFC2822 or ISO 8601 date.')):(b&&(o=b),t>o||o>u?(p.$setValidity("time",!1),a.invalidHours=!0,a.invalidMinutes=!0):k(),l())},a.showSpinners=angular.isDefined(b.showSpinners)?a.$parent.$eval(b.showSpinners):f.showSpinners,a.incrementHours=function(){a.noIncrementHours()||n(60*r)},a.decrementHours=function(){a.noDecrementHours()||n(60*-r)},a.incrementMinutes=function(){a.noIncrementMinutes()||n(s)},a.decrementMinutes=function(){a.noDecrementMinutes()||n(-s)},a.toggleMeridian=function(){a.noToggleMeridian()||n(720*(o.getHours()<12?1:-1))}}]).directive("uibTimepicker",function(){return{restrict:"EA",require:["uibTimepicker","?^ngModel"],controller:"UibTimepickerController",controllerAs:"timepicker",replace:!0,scope:{},templateUrl:function(a,b){return b.templateUrl||"template/timepicker/timepicker.html"},link:function(a,b,c,d){var e=d[0],f=d[1];f&&e.init(f,b.find("input"))}}}),angular.module("ui.bootstrap.timepicker").value("$timepickerSuppressWarning",!1).controller("TimepickerController",["$scope","$attrs","$controller","$log","$timepickerSuppressWarning",function(a,b,c,d,e){return e||d.warn("TimepickerController is now deprecated. Use UibTimepickerController instead."),c("UibTimepickerController",{$scope:a,$attrs:b})}]).directive("timepicker",["$log","$timepickerSuppressWarning",function(a,b){return{restrict:"EA",require:["timepicker","?^ngModel"],controller:"TimepickerController",controllerAs:"timepicker",replace:!0,scope:{},templateUrl:function(a,b){return b.templateUrl||"template/timepicker/timepicker.html"},link:function(c,d,e,f){b||a.warn("timepicker is now deprecated. Use uib-timepicker instead.");var g=f[0],h=f[1];h&&g.init(h,d.find("input"))}}}]),angular.module("ui.bootstrap.typeahead",["ui.bootstrap.position"]).factory("uibTypeaheadParser",["$parse",function(a){var b=/^\s*([\s\S]+?)(?:\s+as\s+([\s\S]+?))?\s+for\s+(?:([\$\w][\$\w\d]*))\s+in\s+([\s\S]+?)$/;return{parse:function(c){var d=c.match(b);if(!d)throw new Error('Expected typeahead specification in form of "_modelValue_ (as _label_)? for _item_ in _collection_" but got "'+c+'".');return{itemName:d[3],source:a(d[4]),viewMapper:a(d[2]||d[1]),modelMapper:a(d[1])}}}}]).directive("uibTypeahead",["$compile","$parse","$q","$timeout","$document","$window","$rootScope","$uibPosition","uibTypeaheadParser",function(a,b,c,d,e,f,g,h,i){var j=[9,13,27,38,40],k=200;return{require:["ngModel","^?ngModelOptions"],link:function(l,m,n,o){function p(){L.moveInProgress||(L.moveInProgress=!0,L.$digest()),T&&d.cancel(T),T=d(function(){L.matches.length&&q(),L.moveInProgress=!1},k)}function q(){L.position=D?h.offset(m):h.position(m),L.position.top+=m.prop("offsetHeight")}var r=o[0],s=o[1],t=l.$eval(n.typeaheadMinLength);t||0===t||(t=1);var u,v,w=l.$eval(n.typeaheadWaitMs)||0,x=l.$eval(n.typeaheadEditable)!==!1,y=b(n.typeaheadLoading).assign||angular.noop,z=b(n.typeaheadOnSelect),A=angular.isDefined(n.typeaheadSelectOnBlur)?l.$eval(n.typeaheadSelectOnBlur):!1,B=b(n.typeaheadNoResults).assign||angular.noop,C=n.typeaheadInputFormatter?b(n.typeaheadInputFormatter):void 0,D=n.typeaheadAppendToBody?l.$eval(n.typeaheadAppendToBody):!1,E=n.typeaheadAppendToElementId||!1,F=l.$eval(n.typeaheadFocusFirst)!==!1,G=n.typeaheadSelectOnExact?l.$eval(n.typeaheadSelectOnExact):!1,H=b(n.ngModel),I=b(n.ngModel+"($$$p)"),J=function(a,b){return angular.isFunction(H(l))&&s&&s.$options&&s.$options.getterSetter?I(a,{$$$p:b}):H.assign(a,b)},K=i.parse(n.uibTypeahead),L=l.$new(),M=l.$on("$destroy",function(){L.$destroy()});L.$on("$destroy",M);var N="typeahead-"+L.$id+"-"+Math.floor(1e4*Math.random());m.attr({"aria-autocomplete":"list","aria-expanded":!1,"aria-owns":N});var O=angular.element("<div uib-typeahead-popup></div>");O.attr({id:N,matches:"matches",active:"activeIdx",select:"select(activeIdx)","move-in-progress":"moveInProgress",query:"query",position:"position"}),angular.isDefined(n.typeaheadTemplateUrl)&&O.attr("template-url",n.typeaheadTemplateUrl),angular.isDefined(n.typeaheadPopupTemplateUrl)&&O.attr("popup-template-url",n.typeaheadPopupTemplateUrl);var P=function(){L.matches=[],L.activeIdx=-1,m.attr("aria-expanded",!1)},Q=function(a){return N+"-option-"+a};L.$watch("activeIdx",function(a){0>a?m.removeAttr("aria-activedescendant"):m.attr("aria-activedescendant",Q(a))});var R=function(a,b){return L.matches.length>b&&a?a.toUpperCase()===L.matches[b].label.toUpperCase():!1},S=function(a){var b={$viewValue:a};y(l,!0),B(l,!1),c.when(K.source(l,b)).then(function(c){var d=a===r.$viewValue;if(d&&u)if(c&&c.length>0){L.activeIdx=F?0:-1,B(l,!1),L.matches.length=0;for(var e=0;e<c.length;e++)b[K.itemName]=c[e],L.matches.push({id:Q(e),label:K.viewMapper(L,b),model:c[e]});L.query=a,q(),m.attr("aria-expanded",!0),G&&1===L.matches.length&&R(a,0)&&L.select(0)}else P(),B(l,!0);d&&y(l,!1)},function(){P(),y(l,!1),B(l,!0)})};D&&(angular.element(f).bind("resize",p),e.find("body").bind("scroll",p));var T;L.moveInProgress=!1,P(),L.query=void 0;var U,V=function(a){U=d(function(){S(a)},w)},W=function(){U&&d.cancel(U)};r.$parsers.unshift(function(a){return u=!0,0===t||a&&a.length>=t?w>0?(W(),V(a)):S(a):(y(l,!1),W(),P()),x?a:a?void r.$setValidity("editable",!1):(r.$setValidity("editable",!0),null)}),r.$formatters.push(function(a){var b,c,d={};return x||r.$setValidity("editable",!0),C?(d.$model=a,C(l,d)):(d[K.itemName]=a,b=K.viewMapper(l,d),d[K.itemName]=void 0,c=K.viewMapper(l,d),b!==c?b:a)}),L.select=function(a){var b,c,e={};v=!0,e[K.itemName]=c=L.matches[a].model,b=K.modelMapper(l,e),J(l,b),r.$setValidity("editable",!0),r.$setValidity("parse",!0),z(l,{$item:c,$model:b,$label:K.viewMapper(l,e)}),P(),L.$eval(n.typeaheadFocusOnSelect)!==!1&&d(function(){m[0].focus()},0,!1)},m.bind("keydown",function(a){if(0!==L.matches.length&&-1!==j.indexOf(a.which)){if(-1===L.activeIdx&&(9===a.which||13===a.which))return P(),void L.$digest();a.preventDefault(), |
| 11 | 40===a.which?(L.activeIdx=(L.activeIdx+1)%L.matches.length,L.$digest()):38===a.which?(L.activeIdx=(L.activeIdx>0?L.activeIdx:L.matches.length)-1,L.$digest()):13===a.which||9===a.which?L.$apply(function(){L.select(L.activeIdx)}):27===a.which&&(a.stopPropagation(),P(),L.$digest())}}),m.bind("blur",function(){A&&L.matches.length&&-1!==L.activeIdx&&!v&&(v=!0,L.$apply(function(){L.select(L.activeIdx)})),u=!1,v=!1});var X=function(a){m[0]!==a.target&&3!==a.which&&0!==L.matches.length&&(P(),g.$$phase||L.$digest())};e.bind("click",X),l.$on("$destroy",function(){e.unbind("click",X),(D||E)&&Y.remove(),O.remove()});var Y=a(O)(L);D?e.find("body").append(Y):E!==!1?angular.element(e[0].getElementById(E)).append(Y):m.after(Y)}}}]).directive("uibTypeaheadPopup",function(){return{scope:{matches:"=",query:"=",active:"=",position:"&",moveInProgress:"=",select:"&"},replace:!0,templateUrl:function(a,b){return b.popupTemplateUrl||"template/typeahead/typeahead-popup.html"},link:function(a,b,c){a.templateUrl=c.templateUrl,a.isOpen=function(){return a.matches.length>0},a.isActive=function(b){return a.active==b},a.selectActive=function(b){a.active=b},a.selectMatch=function(b){a.select({activeIdx:b})}}}}).directive("uibTypeaheadMatch",["$templateRequest","$compile","$parse",function(a,b,c){return{scope:{index:"=",match:"=",query:"="},link:function(d,e,f){var g=c(f.templateUrl)(d.$parent)||"template/typeahead/typeahead-match.html";a(g).then(function(a){b(a.trim())(d,function(a){e.replaceWith(a)})})}}}]).filter("uibTypeaheadHighlight",["$sce","$injector","$log",function(a,b,c){function d(a){return a.replace(/([.?*+^$[\]\\(){}|-])/g,"\\$1")}function e(a){return/<.*>/g.test(a)}var f;return f=b.has("$sanitize"),function(b,g){return!f&&e(b)&&c.warn("Unsafe use of typeahead please use ngSanitize"),b=g?(""+b).replace(new RegExp(d(g),"gi"),"<strong>$&</strong>"):b,f||(b=a.trustAsHtml(b)),b}}]),angular.module("ui.bootstrap.typeahead").value("$typeaheadSuppressWarning",!1).service("typeaheadParser",["$parse","uibTypeaheadParser","$log","$typeaheadSuppressWarning",function(a,b,c,d){return d||c.warn("typeaheadParser is now deprecated. Use uibTypeaheadParser instead."),b}]).directive("typeahead",["$compile","$parse","$q","$timeout","$document","$window","$rootScope","$uibPosition","typeaheadParser","$log","$typeaheadSuppressWarning",function(a,b,c,d,e,f,g,h,i,j,k){var l=[9,13,27,38,40],m=200;return{require:["ngModel","^?ngModelOptions"],link:function(n,o,p,q){function r(){N.moveInProgress||(N.moveInProgress=!0,N.$digest()),V&&d.cancel(V),V=d(function(){N.matches.length&&s(),N.moveInProgress=!1},m)}function s(){N.position=F?h.offset(o):h.position(o),N.position.top+=o.prop("offsetHeight")}k||j.warn("typeahead is now deprecated. Use uib-typeahead instead.");var t=q[0],u=q[1],v=n.$eval(p.typeaheadMinLength);v||0===v||(v=1);var w,x,y=n.$eval(p.typeaheadWaitMs)||0,z=n.$eval(p.typeaheadEditable)!==!1,A=b(p.typeaheadLoading).assign||angular.noop,B=b(p.typeaheadOnSelect),C=angular.isDefined(p.typeaheadSelectOnBlur)?n.$eval(p.typeaheadSelectOnBlur):!1,D=b(p.typeaheadNoResults).assign||angular.noop,E=p.typeaheadInputFormatter?b(p.typeaheadInputFormatter):void 0,F=p.typeaheadAppendToBody?n.$eval(p.typeaheadAppendToBody):!1,G=p.typeaheadAppendToElementId||!1,H=n.$eval(p.typeaheadFocusFirst)!==!1,I=p.typeaheadSelectOnExact?n.$eval(p.typeaheadSelectOnExact):!1,J=b(p.ngModel),K=b(p.ngModel+"($$$p)"),L=function(a,b){return angular.isFunction(J(n))&&u&&u.$options&&u.$options.getterSetter?K(a,{$$$p:b}):J.assign(a,b)},M=i.parse(p.typeahead),N=n.$new(),O=n.$on("$destroy",function(){N.$destroy()});N.$on("$destroy",O);var P="typeahead-"+N.$id+"-"+Math.floor(1e4*Math.random());o.attr({"aria-autocomplete":"list","aria-expanded":!1,"aria-owns":P});var Q=angular.element("<div typeahead-popup></div>");Q.attr({id:P,matches:"matches",active:"activeIdx",select:"select(activeIdx)","move-in-progress":"moveInProgress",query:"query",position:"position"}),angular.isDefined(p.typeaheadTemplateUrl)&&Q.attr("template-url",p.typeaheadTemplateUrl),angular.isDefined(p.typeaheadPopupTemplateUrl)&&Q.attr("popup-template-url",p.typeaheadPopupTemplateUrl);var R=function(){N.matches=[],N.activeIdx=-1,o.attr("aria-expanded",!1)},S=function(a){return P+"-option-"+a};N.$watch("activeIdx",function(a){0>a?o.removeAttr("aria-activedescendant"):o.attr("aria-activedescendant",S(a))});var T=function(a,b){return N.matches.length>b&&a?a.toUpperCase()===N.matches[b].label.toUpperCase():!1},U=function(a){var b={$viewValue:a};A(n,!0),D(n,!1),c.when(M.source(n,b)).then(function(c){var d=a===t.$viewValue;if(d&&w)if(c&&c.length>0){N.activeIdx=H?0:-1,D(n,!1),N.matches.length=0;for(var e=0;e<c.length;e++)b[M.itemName]=c[e],N.matches.push({id:S(e),label:M.viewMapper(N,b),model:c[e]});N.query=a,s(),o.attr("aria-expanded",!0),I&&1===N.matches.length&&T(a,0)&&N.select(0)}else R(),D(n,!0);d&&A(n,!1)},function(){R(),A(n,!1),D(n,!0)})};F&&(angular.element(f).bind("resize",r),e.find("body").bind("scroll",r));var V;N.moveInProgress=!1,R(),N.query=void 0;var W,X=function(a){W=d(function(){U(a)},y)},Y=function(){W&&d.cancel(W)};t.$parsers.unshift(function(a){return w=!0,0===v||a&&a.length>=v?y>0?(Y(),X(a)):U(a):(A(n,!1),Y(),R()),z?a:a?void t.$setValidity("editable",!1):(t.$setValidity("editable",!0),null)}),t.$formatters.push(function(a){var b,c,d={};return z||t.$setValidity("editable",!0),E?(d.$model=a,E(n,d)):(d[M.itemName]=a,b=M.viewMapper(n,d),d[M.itemName]=void 0,c=M.viewMapper(n,d),b!==c?b:a)}),N.select=function(a){var b,c,e={};x=!0,e[M.itemName]=c=N.matches[a].model,b=M.modelMapper(n,e),L(n,b),t.$setValidity("editable",!0),t.$setValidity("parse",!0),B(n,{$item:c,$model:b,$label:M.viewMapper(n,e)}),R(),N.$eval(p.typeaheadFocusOnSelect)!==!1&&d(function(){o[0].focus()},0,!1)},o.bind("keydown",function(a){if(0!==N.matches.length&&-1!==l.indexOf(a.which)){if(-1===N.activeIdx&&(9===a.which||13===a.which))return R(),void N.$digest();a.preventDefault(),40===a.which?(N.activeIdx=(N.activeIdx+1)%N.matches.length,N.$digest()):38===a.which?(N.activeIdx=(N.activeIdx>0?N.activeIdx:N.matches.length)-1,N.$digest()):13===a.which||9===a.which?N.$apply(function(){N.select(N.activeIdx)}):27===a.which&&(a.stopPropagation(),R(),N.$digest())}}),o.bind("blur",function(){C&&N.matches.length&&-1!==N.activeIdx&&!x&&(x=!0,N.$apply(function(){N.select(N.activeIdx)})),w=!1,x=!1});var Z=function(a){o[0]!==a.target&&3!==a.which&&0!==N.matches.length&&(R(),g.$$phase||N.$digest())};e.bind("click",Z),n.$on("$destroy",function(){e.unbind("click",Z),(F||G)&&$.remove(),Q.remove()});var $=a(Q)(N);F?e.find("body").append($):G!==!1?angular.element(e[0].getElementById(G)).append($):o.after($)}}}]).directive("typeaheadPopup",["$typeaheadSuppressWarning","$log",function(a,b){return{scope:{matches:"=",query:"=",active:"=",position:"&",moveInProgress:"=",select:"&"},replace:!0,templateUrl:function(a,b){return b.popupTemplateUrl||"template/typeahead/typeahead-popup.html"},link:function(c,d,e){a||b.warn("typeahead-popup is now deprecated. Use uib-typeahead-popup instead."),c.templateUrl=e.templateUrl,c.isOpen=function(){return c.matches.length>0},c.isActive=function(a){return c.active==a},c.selectActive=function(a){c.active=a},c.selectMatch=function(a){c.select({activeIdx:a})}}}}]).directive("typeaheadMatch",["$templateRequest","$compile","$parse","$typeaheadSuppressWarning","$log",function(a,b,c,d,e){return{restrict:"EA",scope:{index:"=",match:"=",query:"="},link:function(f,g,h){d||e.warn("typeahead-match is now deprecated. Use uib-typeahead-match instead.");var i=c(h.templateUrl)(f.$parent)||"template/typeahead/typeahead-match.html";a(i).then(function(a){b(a.trim())(f,function(a){g.replaceWith(a)})})}}}]).filter("typeaheadHighlight",["$sce","$injector","$log","$typeaheadSuppressWarning",function(a,b,c,d){function e(a){return a.replace(/([.?*+^$[\]\\(){}|-])/g,"\\$1")}function f(a){return/<.*>/g.test(a)}var g;return g=b.has("$sanitize"),function(b,h){return d||c.warn("typeaheadHighlight is now deprecated. Use uibTypeaheadHighlight instead."),!g&&f(b)&&c.warn("Unsafe use of typeahead please use ngSanitize"),b=h?(""+b).replace(new RegExp(e(h),"gi"),"<strong>$&</strong>"):b,g||(b=a.trustAsHtml(b)),b}}]),angular.module("template/accordion/accordion-group.html",[]).run(["$templateCache",function(a){a.put("template/accordion/accordion-group.html",'<div class="panel {{panelClass || \'panel-default\'}}">\n <div class="panel-heading" ng-keypress="toggleOpen($event)">\n <h4 class="panel-title">\n <a href tabindex="0" class="accordion-toggle" ng-click="toggleOpen()" uib-accordion-transclude="heading"><span ng-class="{\'text-muted\': isDisabled}">{{heading}}</span></a>\n </h4>\n </div>\n <div class="panel-collapse collapse" uib-collapse="!isOpen">\n <div class="panel-body" ng-transclude></div>\n </div>\n</div>\n')}]),angular.module("template/accordion/accordion.html",[]).run(["$templateCache",function(a){a.put("template/accordion/accordion.html",'<div class="panel-group" ng-transclude></div>')}]),angular.module("template/alert/alert.html",[]).run(["$templateCache",function(a){a.put("template/alert/alert.html",'<div class="alert" ng-class="[\'alert-\' + (type || \'warning\'), closeable ? \'alert-dismissible\' : null]" role="alert">\n <button ng-show="closeable" type="button" class="close" ng-click="close({$event: $event})">\n <span aria-hidden="true">×</span>\n <span class="sr-only">Close</span>\n </button>\n <div ng-transclude></div>\n</div>\n')}]),angular.module("template/carousel/carousel.html",[]).run(["$templateCache",function(a){a.put("template/carousel/carousel.html",'<div ng-mouseenter="pause()" ng-mouseleave="play()" class="carousel" ng-swipe-right="prev()" ng-swipe-left="next()">\n <div class="carousel-inner" ng-transclude></div>\n <a role="button" href class="left carousel-control" ng-click="prev()" ng-show="slides.length > 1">\n <span aria-hidden="true" class="glyphicon glyphicon-chevron-left"></span>\n <span class="sr-only">previous</span>\n </a>\n <a role="button" href class="right carousel-control" ng-click="next()" ng-show="slides.length > 1">\n <span aria-hidden="true" class="glyphicon glyphicon-chevron-right"></span>\n <span class="sr-only">next</span>\n </a>\n <ol class="carousel-indicators" ng-show="slides.length > 1">\n <li ng-repeat="slide in slides | orderBy:indexOfSlide track by $index" ng-class="{ active: isActive(slide) }" ng-click="select(slide)">\n <span class="sr-only">slide {{ $index + 1 }} of {{ slides.length }}<span ng-if="isActive(slide)">, currently active</span></span>\n </li>\n </ol>\n</div>')}]),angular.module("template/carousel/slide.html",[]).run(["$templateCache",function(a){a.put("template/carousel/slide.html",'<div ng-class="{\n \'active\': active\n }" class="item text-center" ng-transclude></div>\n')}]),angular.module("template/datepicker/datepicker.html",[]).run(["$templateCache",function(a){a.put("template/datepicker/datepicker.html",'<div ng-switch="datepickerMode" role="application" ng-keydown="keydown($event)">\n <uib-daypicker ng-switch-when="day" tabindex="0"></uib-daypicker>\n <uib-monthpicker ng-switch-when="month" tabindex="0"></uib-monthpicker>\n <uib-yearpicker ng-switch-when="year" tabindex="0"></uib-yearpicker>\n</div>')}]),angular.module("template/datepicker/day.html",[]).run(["$templateCache",function(a){a.put("template/datepicker/day.html",'<table role="grid" aria-labelledby="{{::uniqueId}}-title" aria-activedescendant="{{activeDateId}}">\n <thead>\n <tr>\n <th><button type="button" class="btn btn-default btn-sm pull-left" ng-click="move(-1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-left"></i></button></th>\n <th colspan="{{::5 + showWeeks}}"><button id="{{::uniqueId}}-title" role="heading" aria-live="assertive" aria-atomic="true" type="button" class="btn btn-default btn-sm" ng-click="toggleMode()" ng-disabled="datepickerMode === maxMode" tabindex="-1" style="width:100%;"><strong>{{title}}</strong></button></th>\n <th><button type="button" class="btn btn-default btn-sm pull-right" ng-click="move(1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-right"></i></button></th>\n </tr>\n <tr>\n <th ng-if="showWeeks" class="text-center"></th>\n <th ng-repeat="label in ::labels track by $index" class="text-center"><small aria-label="{{::label.full}}">{{::label.abbr}}</small></th>\n </tr>\n </thead>\n <tbody>\n <tr ng-repeat="row in rows track by $index">\n <td ng-if="showWeeks" class="text-center h6"><em>{{ weekNumbers[$index] }}</em></td>\n <td ng-repeat="dt in row track by dt.date" class="text-center" role="gridcell" id="{{::dt.uid}}" ng-class="::dt.customClass">\n <button type="button" style="min-width:100%;" class="btn btn-default btn-sm" ng-class="{\'btn-info\': dt.selected, active: isActive(dt)}" ng-click="select(dt.date)" ng-disabled="dt.disabled" tabindex="-1"><span ng-class="::{\'text-muted\': dt.secondary, \'text-info\': dt.current}">{{::dt.label}}</span></button>\n </td>\n </tr>\n </tbody>\n</table>\n')}]),angular.module("template/datepicker/month.html",[]).run(["$templateCache",function(a){a.put("template/datepicker/month.html",'<table role="grid" aria-labelledby="{{::uniqueId}}-title" aria-activedescendant="{{activeDateId}}">\n <thead>\n <tr>\n <th><button type="button" class="btn btn-default btn-sm pull-left" ng-click="move(-1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-left"></i></button></th>\n <th><button id="{{::uniqueId}}-title" role="heading" aria-live="assertive" aria-atomic="true" type="button" class="btn btn-default btn-sm" ng-click="toggleMode()" ng-disabled="datepickerMode === maxMode" tabindex="-1" style="width:100%;"><strong>{{title}}</strong></button></th>\n <th><button type="button" class="btn btn-default btn-sm pull-right" ng-click="move(1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-right"></i></button></th>\n </tr>\n </thead>\n <tbody>\n <tr ng-repeat="row in rows track by $index">\n <td ng-repeat="dt in row track by dt.date" class="text-center" role="gridcell" id="{{::dt.uid}}" ng-class="::dt.customClass">\n <button type="button" style="min-width:100%;" class="btn btn-default" ng-class="{\'btn-info\': dt.selected, active: isActive(dt)}" ng-click="select(dt.date)" ng-disabled="dt.disabled" tabindex="-1"><span ng-class="::{\'text-info\': dt.current}">{{::dt.label}}</span></button>\n </td>\n </tr>\n </tbody>\n</table>\n')}]),angular.module("template/datepicker/popup.html",[]).run(["$templateCache",function(a){a.put("template/datepicker/popup.html",'<ul class="dropdown-menu" dropdown-nested ng-if="isOpen" style="display: block" ng-style="{top: position.top+\'px\', left: position.left+\'px\'}" ng-keydown="keydown($event)" ng-click="$event.stopPropagation()">\n <li ng-transclude></li>\n <li ng-if="showButtonBar" style="padding:10px 9px 2px">\n <span class="btn-group pull-left">\n <button type="button" class="btn btn-sm btn-info" ng-click="select(\'today\')" ng-disabled="isDisabled(\'today\')">{{ getText(\'current\') }}</button>\n <button type="button" class="btn btn-sm btn-danger" ng-click="select(null)">{{ getText(\'clear\') }}</button>\n </span>\n <button type="button" class="btn btn-sm btn-success pull-right" ng-click="close()">{{ getText(\'close\') }}</button>\n </li>\n</ul>\n')}]),angular.module("template/datepicker/year.html",[]).run(["$templateCache",function(a){a.put("template/datepicker/year.html",'<table role="grid" aria-labelledby="{{::uniqueId}}-title" aria-activedescendant="{{activeDateId}}">\n <thead>\n <tr>\n <th><button type="button" class="btn btn-default btn-sm pull-left" ng-click="move(-1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-left"></i></button></th>\n <th colspan="3"><button id="{{::uniqueId}}-title" role="heading" aria-live="assertive" aria-atomic="true" type="button" class="btn btn-default btn-sm" ng-click="toggleMode()" ng-disabled="datepickerMode === maxMode" tabindex="-1" style="width:100%;"><strong>{{title}}</strong></button></th>\n <th><button type="button" class="btn btn-default btn-sm pull-right" ng-click="move(1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-right"></i></button></th>\n </tr>\n </thead>\n <tbody>\n <tr ng-repeat="row in rows track by $index">\n <td ng-repeat="dt in row track by dt.date" class="text-center" role="gridcell" id="{{::dt.uid}}" ng-class="::dt.customClass">\n <button type="button" style="min-width:100%;" class="btn btn-default" ng-class="{\'btn-info\': dt.selected, active: isActive(dt)}" ng-click="select(dt.date)" ng-disabled="dt.disabled" tabindex="-1"><span ng-class="::{\'text-info\': dt.current}">{{::dt.label}}</span></button>\n </td>\n </tr>\n </tbody>\n</table>\n')}]),angular.module("template/modal/backdrop.html",[]).run(["$templateCache",function(a){a.put("template/modal/backdrop.html",'<div uib-modal-animation-class="fade"\n modal-in-class="in"\n ng-style="{\'z-index\': 1040 + (index && 1 || 0) + index*10}"\n></div>\n')}]),angular.module("template/modal/window.html",[]).run(["$templateCache",function(a){a.put("template/modal/window.html",'<div modal-render="{{$isRendered}}" tabindex="-1" role="dialog" class="modal"\n uib-modal-animation-class="fade"\n modal-in-class="in"\n ng-style="{\'z-index\': 1050 + index*10, display: \'block\'}">\n <div class="modal-dialog" ng-class="size ? \'modal-\' + size : \'\'"><div class="modal-content" uib-modal-transclude></div></div>\n</div>\n')}]),angular.module("template/pagination/pager.html",[]).run(["$templateCache",function(a){a.put("template/pagination/pager.html",'<ul class="pager">\n <li ng-class="{disabled: noPrevious()||ngDisabled, previous: align}"><a href ng-click="selectPage(page - 1, $event)">{{::getText(\'previous\')}}</a></li>\n <li ng-class="{disabled: noNext()||ngDisabled, next: align}"><a href ng-click="selectPage(page + 1, $event)">{{::getText(\'next\')}}</a></li>\n</ul>\n')}]),angular.module("template/pagination/pagination.html",[]).run(["$templateCache",function(a){a.put("template/pagination/pagination.html",'<ul class="pagination">\n <li ng-if="::boundaryLinks" ng-class="{disabled: noPrevious()||ngDisabled}" class="pagination-first"><a href ng-click="selectPage(1, $event)">{{::getText(\'first\')}}</a></li>\n <li ng-if="::directionLinks" ng-class="{disabled: noPrevious()||ngDisabled}" class="pagination-prev"><a href ng-click="selectPage(page - 1, $event)">{{::getText(\'previous\')}}</a></li>\n <li ng-repeat="page in pages track by $index" ng-class="{active: page.active,disabled: ngDisabled&&!page.active}" class="pagination-page"><a href ng-click="selectPage(page.number, $event)">{{page.text}}</a></li>\n <li ng-if="::directionLinks" ng-class="{disabled: noNext()||ngDisabled}" class="pagination-next"><a href ng-click="selectPage(page + 1, $event)">{{::getText(\'next\')}}</a></li>\n <li ng-if="::boundaryLinks" ng-class="{disabled: noNext()||ngDisabled}" class="pagination-last"><a href ng-click="selectPage(totalPages, $event)">{{::getText(\'last\')}}</a></li>\n</ul>\n')}]),angular.module("template/tooltip/tooltip-html-popup.html",[]).run(["$templateCache",function(a){a.put("template/tooltip/tooltip-html-popup.html",'<div\n tooltip-animation-class="fade"\n uib-tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="tooltip-arrow"></div>\n <div class="tooltip-inner" ng-bind-html="contentExp()"></div>\n</div>\n')}]),angular.module("template/tooltip/tooltip-html-unsafe-popup.html",[]).run(["$templateCache",function(a){a.put("template/tooltip/tooltip-html-unsafe-popup.html",'<div class="tooltip"\n tooltip-animation-class="fade"\n tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="tooltip-arrow"></div>\n <div class="tooltip-inner" bind-html-unsafe="content"></div>\n</div>\n')}]),angular.module("template/tooltip/tooltip-popup.html",[]).run(["$templateCache",function(a){a.put("template/tooltip/tooltip-popup.html",'<div\n tooltip-animation-class="fade"\n uib-tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="tooltip-arrow"></div>\n <div class="tooltip-inner" ng-bind="content"></div>\n</div>\n')}]),angular.module("template/tooltip/tooltip-template-popup.html",[]).run(["$templateCache",function(a){a.put("template/tooltip/tooltip-template-popup.html",'<div\n tooltip-animation-class="fade"\n uib-tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="tooltip-arrow"></div>\n <div class="tooltip-inner"\n uib-tooltip-template-transclude="contentExp()"\n tooltip-template-transclude-scope="originScope()"></div>\n</div>\n')}]),angular.module("template/popover/popover-html.html",[]).run(["$templateCache",function(a){a.put("template/popover/popover-html.html",'<div tooltip-animation-class="fade"\n uib-tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="arrow"></div>\n\n <div class="popover-inner">\n <h3 class="popover-title" ng-bind="title" ng-if="title"></h3>\n <div class="popover-content" ng-bind-html="contentExp()"></div>\n </div>\n</div>\n')}]),angular.module("template/popover/popover-template.html",[]).run(["$templateCache",function(a){a.put("template/popover/popover-template.html",'<div tooltip-animation-class="fade"\n uib-tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="arrow"></div>\n\n <div class="popover-inner">\n <h3 class="popover-title" ng-bind="title" ng-if="title"></h3>\n <div class="popover-content"\n uib-tooltip-template-transclude="contentExp()"\n tooltip-template-transclude-scope="originScope()"></div>\n </div>\n</div>\n')}]),angular.module("template/popover/popover.html",[]).run(["$templateCache",function(a){a.put("template/popover/popover.html",'<div tooltip-animation-class="fade"\n uib-tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="arrow"></div>\n\n <div class="popover-inner">\n <h3 class="popover-title" ng-bind="title" ng-if="title"></h3>\n <div class="popover-content" ng-bind="content"></div>\n </div>\n</div>\n')}]),angular.module("template/progressbar/bar.html",[]).run(["$templateCache",function(a){a.put("template/progressbar/bar.html",'<div class="progress-bar" ng-class="type && \'progress-bar-\' + type" role="progressbar" aria-valuenow="{{value}}" aria-valuemin="0" aria-valuemax="{{max}}" ng-style="{width: (percent < 100 ? percent : 100) + \'%\'}" aria-valuetext="{{percent | number:0}}%" aria-labelledby="{{::title}}" style="min-width: 0;" ng-transclude></div>\n')}]),angular.module("template/progressbar/progress.html",[]).run(["$templateCache",function(a){a.put("template/progressbar/progress.html",'<div class="progress" ng-transclude aria-labelledby="{{::title}}"></div>')}]),angular.module("template/progressbar/progressbar.html",[]).run(["$templateCache",function(a){a.put("template/progressbar/progressbar.html",'<div class="progress">\n <div class="progress-bar" ng-class="type && \'progress-bar-\' + type" role="progressbar" aria-valuenow="{{value}}" aria-valuemin="0" aria-valuemax="{{max}}" ng-style="{width: (percent < 100 ? percent : 100) + \'%\'}" aria-valuetext="{{percent | number:0}}%" aria-labelledby="{{::title}}" style="min-width: 0;" ng-transclude></div>\n</div>\n')}]),angular.module("template/rating/rating.html",[]).run(["$templateCache",function(a){a.put("template/rating/rating.html",'<span ng-mouseleave="reset()" ng-keydown="onKeydown($event)" tabindex="0" role="slider" aria-valuemin="0" aria-valuemax="{{range.length}}" aria-valuenow="{{value}}">\n <span ng-repeat-start="r in range track by $index" class="sr-only">({{ $index < value ? \'*\' : \' \' }})</span>\n <i ng-repeat-end ng-mouseenter="enter($index + 1)" ng-click="rate($index + 1)" class="glyphicon" ng-class="$index < value && (r.stateOn || \'glyphicon-star\') || (r.stateOff || \'glyphicon-star-empty\')" ng-attr-title="{{r.title}}" aria-valuetext="{{r.title}}"></i>\n</span>\n')}]),angular.module("template/tabs/tab.html",[]).run(["$templateCache",function(a){a.put("template/tabs/tab.html",'<li ng-class="{active: active, disabled: disabled}">\n <a href ng-click="select()" uib-tab-heading-transclude>{{heading}}</a>\n</li>\n')}]),angular.module("template/tabs/tabset.html",[]).run(["$templateCache",function(a){a.put("template/tabs/tabset.html",'<div>\n <ul class="nav nav-{{type || \'tabs\'}}" ng-class="{\'nav-stacked\': vertical, \'nav-justified\': justified}" ng-transclude></ul>\n <div class="tab-content">\n <div class="tab-pane" \n ng-repeat="tab in tabs" \n ng-class="{active: tab.active}"\n uib-tab-content-transclude="tab">\n </div>\n </div>\n</div>\n')}]),angular.module("template/timepicker/timepicker.html",[]).run(["$templateCache",function(a){a.put("template/timepicker/timepicker.html",'<table>\n <tbody>\n <tr class="text-center" ng-show="::showSpinners">\n <td><a ng-click="incrementHours()" ng-class="{disabled: noIncrementHours()}" class="btn btn-link"><span class="glyphicon glyphicon-chevron-up"></span></a></td>\n <td> </td>\n <td><a ng-click="incrementMinutes()" ng-class="{disabled: noIncrementMinutes()}" class="btn btn-link"><span class="glyphicon glyphicon-chevron-up"></span></a></td>\n <td ng-show="showMeridian"></td>\n </tr>\n <tr>\n <td class="form-group" ng-class="{\'has-error\': invalidHours}">\n <input style="width:50px;" type="text" ng-model="hours" ng-change="updateHours()" class="form-control text-center" ng-readonly="::readonlyInput" maxlength="2">\n </td>\n <td>:</td>\n <td class="form-group" ng-class="{\'has-error\': invalidMinutes}">\n <input style="width:50px;" type="text" ng-model="minutes" ng-change="updateMinutes()" class="form-control text-center" ng-readonly="::readonlyInput" maxlength="2">\n </td>\n <td ng-show="showMeridian"><button type="button" ng-class="{disabled: noToggleMeridian()}" class="btn btn-default text-center" ng-click="toggleMeridian()">{{meridian}}</button></td>\n </tr>\n <tr class="text-center" ng-show="::showSpinners">\n <td><a ng-click="decrementHours()" ng-class="{disabled: noDecrementHours()}" class="btn btn-link"><span class="glyphicon glyphicon-chevron-down"></span></a></td>\n <td> </td>\n <td><a ng-click="decrementMinutes()" ng-class="{disabled: noDecrementMinutes()}" class="btn btn-link"><span class="glyphicon glyphicon-chevron-down"></span></a></td>\n <td ng-show="showMeridian"></td>\n </tr>\n </tbody>\n</table>\n')}]),angular.module("template/typeahead/typeahead-match.html",[]).run(["$templateCache",function(a){a.put("template/typeahead/typeahead-match.html",'<a href tabindex="-1" ng-bind-html="match.label | uibTypeaheadHighlight:query"></a>\n')}]),angular.module("template/typeahead/typeahead-popup.html",[]).run(["$templateCache",function(a){a.put("template/typeahead/typeahead-popup.html",'<ul class="dropdown-menu" ng-show="isOpen() && !moveInProgress" ng-style="{top: position().top+\'px\', left: position().left+\'px\'}" style="display: block;" role="listbox" aria-hidden="{{!isOpen()}}">\n <li ng-repeat="match in matches track by $index" ng-class="{active: isActive($index) }" ng-mouseenter="selectActive($index)" ng-click="selectMatch($index)" role="option" id="{{::match.id}}">\n <div uib-typeahead-match index="$index" match="match" query="query" template-url="templateUrl"></div>\n </li>\n</ul>\n')}]),!angular.$$csp()&&angular.element(document).find("head").prepend('<style type="text/css">.ng-animate.item:not(.left):not(.right){-webkit-transition:0s ease-in-out left;transition:0s ease-in-out left}</style>'); | 11 | 40===a.which?(L.activeIdx=(L.activeIdx+1)%L.matches.length,L.$digest()):38===a.which?(L.activeIdx=(L.activeIdx>0?L.activeIdx:L.matches.length)-1,L.$digest()):13===a.which||9===a.which?L.$apply(function(){L.select(L.activeIdx)}):27===a.which&&(a.stopPropagation(),P(),L.$digest())}}),m.bind("blur",function(){A&&L.matches.length&&-1!==L.activeIdx&&!v&&(v=!0,L.$apply(function(){L.select(L.activeIdx)})),u=!1,v=!1});var X=function(a){m[0]!==a.target&&3!==a.which&&0!==L.matches.length&&(P(),g.$$phase||L.$digest())};e.bind("click",X),l.$on("$destroy",function(){e.unbind("click",X),(D||E)&&Y.remove(),O.remove()});var Y=a(O)(L);D?e.find("body").append(Y):E!==!1?angular.element(e[0].getElementById(E)).append(Y):m.after(Y)}}}]).directive("uibTypeaheadPopup",function(){return{scope:{matches:"=",query:"=",active:"=",position:"&",moveInProgress:"=",select:"&"},replace:!0,templateUrl:function(a,b){return b.popupTemplateUrl||"template/typeahead/typeahead-popup.html"},link:function(a,b,c){a.templateUrl=c.templateUrl,a.isOpen=function(){return a.matches.length>0},a.isActive=function(b){return a.active==b},a.selectActive=function(b){a.active=b},a.selectMatch=function(b){a.select({activeIdx:b})}}}}).directive("uibTypeaheadMatch",["$templateRequest","$compile","$parse",function(a,b,c){return{scope:{index:"=",match:"=",query:"="},link:function(d,e,f){var g=c(f.templateUrl)(d.$parent)||"template/typeahead/typeahead-match.html";a(g).then(function(a){b(a.trim())(d,function(a){e.replaceWith(a)})})}}}]).filter("uibTypeaheadHighlight",["$sce","$injector","$log",function(a,b,c){function d(a){return a.replace(/([.?*+^$[\]\\(){}|-])/g,"\\$1")}function e(a){return/<.*>/g.test(a)}var f;return f=b.has("$sanitize"),function(b,g){return!f&&e(b)&&c.warn("Unsafe use of typeahead please use ngSanitize"),b=g?(""+b).replace(new RegExp(d(g),"gi"),"<strong>$&</strong>"):b,f||(b=a.trustAsHtml(b)),b}}]),angular.module("ui.bootstrap.typeahead").value("$typeaheadSuppressWarning",!1).service("typeaheadParser",["$parse","uibTypeaheadParser","$log","$typeaheadSuppressWarning",function(a,b,c,d){return d||c.warn("typeaheadParser is now deprecated. Use uibTypeaheadParser instead."),b}]).directive("typeahead",["$compile","$parse","$q","$timeout","$document","$window","$rootScope","$uibPosition","typeaheadParser","$log","$typeaheadSuppressWarning",function(a,b,c,d,e,f,g,h,i,j,k){var l=[9,13,27,38,40],m=200;return{require:["ngModel","^?ngModelOptions"],link:function(n,o,p,q){function r(){N.moveInProgress||(N.moveInProgress=!0,N.$digest()),V&&d.cancel(V),V=d(function(){N.matches.length&&s(),N.moveInProgress=!1},m)}function s(){N.position=F?h.offset(o):h.position(o),N.position.top+=o.prop("offsetHeight")}k||j.warn("typeahead is now deprecated. Use uib-typeahead instead.");var t=q[0],u=q[1],v=n.$eval(p.typeaheadMinLength);v||0===v||(v=1);var w,x,y=n.$eval(p.typeaheadWaitMs)||0,z=n.$eval(p.typeaheadEditable)!==!1,A=b(p.typeaheadLoading).assign||angular.noop,B=b(p.typeaheadOnSelect),C=angular.isDefined(p.typeaheadSelectOnBlur)?n.$eval(p.typeaheadSelectOnBlur):!1,D=b(p.typeaheadNoResults).assign||angular.noop,E=p.typeaheadInputFormatter?b(p.typeaheadInputFormatter):void 0,F=p.typeaheadAppendToBody?n.$eval(p.typeaheadAppendToBody):!1,G=p.typeaheadAppendToElementId||!1,H=n.$eval(p.typeaheadFocusFirst)!==!1,I=p.typeaheadSelectOnExact?n.$eval(p.typeaheadSelectOnExact):!1,J=b(p.ngModel),K=b(p.ngModel+"($$$p)"),L=function(a,b){return angular.isFunction(J(n))&&u&&u.$options&&u.$options.getterSetter?K(a,{$$$p:b}):J.assign(a,b)},M=i.parse(p.typeahead),N=n.$new(),O=n.$on("$destroy",function(){N.$destroy()});N.$on("$destroy",O);var P="typeahead-"+N.$id+"-"+Math.floor(1e4*Math.random());o.attr({"aria-autocomplete":"list","aria-expanded":!1,"aria-owns":P});var Q=angular.element("<div typeahead-popup></div>");Q.attr({id:P,matches:"matches",active:"activeIdx",select:"select(activeIdx)","move-in-progress":"moveInProgress",query:"query",position:"position"}),angular.isDefined(p.typeaheadTemplateUrl)&&Q.attr("template-url",p.typeaheadTemplateUrl),angular.isDefined(p.typeaheadPopupTemplateUrl)&&Q.attr("popup-template-url",p.typeaheadPopupTemplateUrl);var R=function(){N.matches=[],N.activeIdx=-1,o.attr("aria-expanded",!1)},S=function(a){return P+"-option-"+a};N.$watch("activeIdx",function(a){0>a?o.removeAttr("aria-activedescendant"):o.attr("aria-activedescendant",S(a))});var T=function(a,b){return N.matches.length>b&&a?a.toUpperCase()===N.matches[b].label.toUpperCase():!1},U=function(a){var b={$viewValue:a};A(n,!0),D(n,!1),c.when(M.source(n,b)).then(function(c){var d=a===t.$viewValue;if(d&&w)if(c&&c.length>0){N.activeIdx=H?0:-1,D(n,!1),N.matches.length=0;for(var e=0;e<c.length;e++)b[M.itemName]=c[e],N.matches.push({id:S(e),label:M.viewMapper(N,b),model:c[e]});N.query=a,s(),o.attr("aria-expanded",!0),I&&1===N.matches.length&&T(a,0)&&N.select(0)}else R(),D(n,!0);d&&A(n,!1)},function(){R(),A(n,!1),D(n,!0)})};F&&(angular.element(f).bind("resize",r),e.find("body").bind("scroll",r));var V;N.moveInProgress=!1,R(),N.query=void 0;var W,X=function(a){W=d(function(){U(a)},y)},Y=function(){W&&d.cancel(W)};t.$parsers.unshift(function(a){return w=!0,0===v||a&&a.length>=v?y>0?(Y(),X(a)):U(a):(A(n,!1),Y(),R()),z?a:a?void t.$setValidity("editable",!1):(t.$setValidity("editable",!0),null)}),t.$formatters.push(function(a){var b,c,d={};return z||t.$setValidity("editable",!0),E?(d.$model=a,E(n,d)):(d[M.itemName]=a,b=M.viewMapper(n,d),d[M.itemName]=void 0,c=M.viewMapper(n,d),b!==c?b:a)}),N.select=function(a){var b,c,e={};x=!0,e[M.itemName]=c=N.matches[a].model,b=M.modelMapper(n,e),L(n,b),t.$setValidity("editable",!0),t.$setValidity("parse",!0),B(n,{$item:c,$model:b,$label:M.viewMapper(n,e)}),R(),N.$eval(p.typeaheadFocusOnSelect)!==!1&&d(function(){o[0].focus()},0,!1)},o.bind("keydown",function(a){if(0!==N.matches.length&&-1!==l.indexOf(a.which)){if(-1===N.activeIdx&&(9===a.which||13===a.which))return R(),void N.$digest();a.preventDefault(),40===a.which?(N.activeIdx=(N.activeIdx+1)%N.matches.length,N.$digest()):38===a.which?(N.activeIdx=(N.activeIdx>0?N.activeIdx:N.matches.length)-1,N.$digest()):13===a.which||9===a.which?N.$apply(function(){N.select(N.activeIdx)}):27===a.which&&(a.stopPropagation(),R(),N.$digest())}}),o.bind("blur",function(){C&&N.matches.length&&-1!==N.activeIdx&&!x&&(x=!0,N.$apply(function(){N.select(N.activeIdx)})),w=!1,x=!1});var Z=function(a){o[0]!==a.target&&3!==a.which&&0!==N.matches.length&&(R(),g.$$phase||N.$digest())};e.bind("click",Z),n.$on("$destroy",function(){e.unbind("click",Z),(F||G)&&$.remove(),Q.remove()});var $=a(Q)(N);F?e.find("body").append($):G!==!1?angular.element(e[0].getElementById(G)).append($):o.after($)}}}]).directive("typeaheadPopup",["$typeaheadSuppressWarning","$log",function(a,b){return{scope:{matches:"=",query:"=",active:"=",position:"&",moveInProgress:"=",select:"&"},replace:!0,templateUrl:function(a,b){return b.popupTemplateUrl||"template/typeahead/typeahead-popup.html"},link:function(c,d,e){a||b.warn("typeahead-popup is now deprecated. Use uib-typeahead-popup instead."),c.templateUrl=e.templateUrl,c.isOpen=function(){return c.matches.length>0},c.isActive=function(a){return c.active==a},c.selectActive=function(a){c.active=a},c.selectMatch=function(a){c.select({activeIdx:a})}}}}]).directive("typeaheadMatch",["$templateRequest","$compile","$parse","$typeaheadSuppressWarning","$log",function(a,b,c,d,e){return{restrict:"EA",scope:{index:"=",match:"=",query:"="},link:function(f,g,h){d||e.warn("typeahead-match is now deprecated. Use uib-typeahead-match instead.");var i=c(h.templateUrl)(f.$parent)||"template/typeahead/typeahead-match.html";a(i).then(function(a){b(a.trim())(f,function(a){g.replaceWith(a)})})}}}]).filter("typeaheadHighlight",["$sce","$injector","$log","$typeaheadSuppressWarning",function(a,b,c,d){function e(a){return a.replace(/([.?*+^$[\]\\(){}|-])/g,"\\$1")}function f(a){return/<.*>/g.test(a)}var g;return g=b.has("$sanitize"),function(b,h){return d||c.warn("typeaheadHighlight is now deprecated. Use uibTypeaheadHighlight instead."),!g&&f(b)&&c.warn("Unsafe use of typeahead please use ngSanitize"),b=h?(""+b).replace(new RegExp(e(h),"gi"),"<strong>$&</strong>"):b,g||(b=a.trustAsHtml(b)),b}}]),angular.module("template/accordion/accordion-group.html",[]).run(["$templateCache",function(a){a.put("template/accordion/accordion-group.html",'<div class="panel {{panelClass || \'panel-default\'}}">\n <div class="panel-heading" ng-keypress="toggleOpen($event)">\n <h4 class="panel-title">\n <a href tabindex="0" class="accordion-toggle" ng-click="toggleOpen()" uib-accordion-transclude="heading"><span ng-class="{\'text-muted\': isDisabled}">{{heading}}</span></a>\n </h4>\n </div>\n <div class="panel-collapse collapse" uib-collapse="!isOpen">\n <div class="panel-body" ng-transclude></div>\n </div>\n</div>\n')}]),angular.module("template/accordion/accordion.html",[]).run(["$templateCache",function(a){a.put("template/accordion/accordion.html",'<div class="panel-group" ng-transclude></div>')}]),angular.module("template/alert/alert.html",[]).run(["$templateCache",function(a){a.put("template/alert/alert.html",'<div class="alert" ng-class="[\'alert-\' + (type || \'warning\'), closeable ? \'alert-dismissible\' : null]" role="alert">\n <button ng-show="closeable" type="button" class="close" ng-click="close({$event: $event})">\n <span aria-hidden="true">×</span>\n <span class="sr-only">Close</span>\n </button>\n <div ng-transclude></div>\n</div>\n')}]),angular.module("template/carousel/carousel.html",[]).run(["$templateCache",function(a){a.put("template/carousel/carousel.html",'<div ng-mouseenter="pause()" ng-mouseleave="play()" class="carousel" ng-swipe-right="prev()" ng-swipe-left="next()">\n <div class="carousel-inner" ng-transclude></div>\n <a role="button" href class="left carousel-control" ng-click="prev()" ng-show="slides.length > 1">\n <span aria-hidden="true" class="glyphicon glyphicon-chevron-left"></span>\n <span class="sr-only">previous</span>\n </a>\n <a role="button" href class="right carousel-control" ng-click="next()" ng-show="slides.length > 1">\n <span aria-hidden="true" class="glyphicon glyphicon-chevron-right"></span>\n <span class="sr-only">next</span>\n </a>\n <ol class="carousel-indicators" ng-show="slides.length > 1">\n <li ng-repeat="slide in slides | orderBy:indexOfSlide track by $index" ng-class="{ active: isActive(slide) }" ng-click="select(slide)">\n <span class="sr-only">slide {{ $index + 1 }} of {{ slides.length }}<span ng-if="isActive(slide)">, currently active</span></span>\n </li>\n </ol>\n</div>')}]),angular.module("template/carousel/slide.html",[]).run(["$templateCache",function(a){a.put("template/carousel/slide.html",'<div ng-class="{\n \'active\': active\n }" class="item text-center" ng-transclude></div>\n')}]),angular.module("template/datepicker/datepicker.html",[]).run(["$templateCache",function(a){a.put("template/datepicker/datepicker.html",'<div ng-switch="datepickerMode" role="application" ng-keydown="keydown($event)">\n <uib-daypicker ng-switch-when="day" tabindex="0"></uib-daypicker>\n <uib-monthpicker ng-switch-when="month" tabindex="0"></uib-monthpicker>\n <uib-yearpicker ng-switch-when="year" tabindex="0"></uib-yearpicker>\n</div>')}]),angular.module("template/datepicker/day.html",[]).run(["$templateCache",function(a){a.put("template/datepicker/day.html",'<table role="grid" aria-labelledby="{{::uniqueId}}-title" aria-activedescendant="{{activeDateId}}">\n <thead>\n <tr>\n <th><button type="button" class="btn btn-default btn-sm pull-left" ng-click="move(-1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-left"></i></button></th>\n <th colspan="{{::5 + showWeeks}}"><button id="{{::uniqueId}}-title" role="heading" aria-live="assertive" aria-atomic="true" type="button" class="btn btn-default btn-sm" ng-click="toggleMode()" ng-disabled="datepickerMode === maxMode" tabindex="-1" style="width:100%;"><strong>{{title}}</strong></button></th>\n <th><button type="button" class="btn btn-default btn-sm pull-right" ng-click="move(1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-right"></i></button></th>\n </tr>\n <tr>\n <th ng-if="showWeeks" class="text-center"></th>\n <th ng-repeat="label in ::labels track by $index" class="text-center"><small aria-label="{{::label.full}}">{{::label.abbr}}</small></th>\n </tr>\n </thead>\n <tbody>\n <tr ng-repeat="row in rows track by $index">\n <td ng-if="showWeeks" class="text-center h6"><em>{{ weekNumbers[$index] }}</em></td>\n <td ng-repeat="dt in row track by dt.date" class="text-center" role="gridcell" id="{{::dt.uid}}" ng-class="::dt.customClass">\n <button type="button" style="min-width:100%;" class="btn btn-default btn-sm" ng-class="{\'btn-info\': dt.selected, active: isActive(dt)}" ng-click="select(dt.date)" ng-disabled="dt.disabled" tabindex="-1"><span ng-class="::{\'text-muted\': dt.secondary, \'text-info\': dt.current}">{{::dt.label}}</span></button>\n </td>\n </tr>\n </tbody>\n</table>\n')}]),angular.module("template/datepicker/month.html",[]).run(["$templateCache",function(a){a.put("template/datepicker/month.html",'<table role="grid" aria-labelledby="{{::uniqueId}}-title" aria-activedescendant="{{activeDateId}}">\n <thead>\n <tr>\n <th><button type="button" class="btn btn-default btn-sm pull-left" ng-click="move(-1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-left"></i></button></th>\n <th><button id="{{::uniqueId}}-title" role="heading" aria-live="assertive" aria-atomic="true" type="button" class="btn btn-default btn-sm" ng-click="toggleMode()" ng-disabled="datepickerMode === maxMode" tabindex="-1" style="width:100%;"><strong>{{title}}</strong></button></th>\n <th><button type="button" class="btn btn-default btn-sm pull-right" ng-click="move(1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-right"></i></button></th>\n </tr>\n </thead>\n <tbody>\n <tr ng-repeat="row in rows track by $index">\n <td ng-repeat="dt in row track by dt.date" class="text-center" role="gridcell" id="{{::dt.uid}}" ng-class="::dt.customClass">\n <button type="button" style="min-width:100%;" class="btn btn-default" ng-class="{\'btn-info\': dt.selected, active: isActive(dt)}" ng-click="select(dt.date)" ng-disabled="dt.disabled" tabindex="-1"><span ng-class="::{\'text-info\': dt.current}">{{::dt.label}}</span></button>\n </td>\n </tr>\n </tbody>\n</table>\n')}]),angular.module("template/datepicker/popup.html",[]).run(["$templateCache",function(a){a.put("template/datepicker/popup.html",'<ul class="dropdown-menu" dropdown-nested ng-if="isOpen" style="display: block" ng-style="{top: position.top+\'px\', left: position.left+\'px\'}" ng-keydown="keydown($event)" ng-click="$event.stopPropagation()">\n <li ng-transclude></li>\n <li ng-if="showButtonBar" style="padding:10px 9px 2px">\n <span class="btn-group pull-left">\n <button type="button" class="btn btn-sm btn-info" ng-click="select(\'today\')" ng-disabled="isDisabled(\'today\')">{{ getText(\'current\') }}</button>\n <button type="button" class="btn btn-sm btn-danger" ng-click="select(null)">{{ getText(\'clear\') }}</button>\n </span>\n <button type="button" class="btn btn-sm btn-success pull-right" ng-click="close()">{{ getText(\'close\') }}</button>\n </li>\n</ul>\n')}]),angular.module("template/datepicker/year.html",[]).run(["$templateCache",function(a){a.put("template/datepicker/year.html",'<table role="grid" aria-labelledby="{{::uniqueId}}-title" aria-activedescendant="{{activeDateId}}">\n <thead>\n <tr>\n <th><button type="button" class="btn btn-default btn-sm pull-left" ng-click="move(-1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-left"></i></button></th>\n <th colspan="3"><button id="{{::uniqueId}}-title" role="heading" aria-live="assertive" aria-atomic="true" type="button" class="btn btn-default btn-sm" ng-click="toggleMode()" ng-disabled="datepickerMode === maxMode" tabindex="-1" style="width:100%;"><strong>{{title}}</strong></button></th>\n <th><button type="button" class="btn btn-default btn-sm pull-right" ng-click="move(1)" tabindex="-1"><i class="glyphicon glyphicon-chevron-right"></i></button></th>\n </tr>\n </thead>\n <tbody>\n <tr ng-repeat="row in rows track by $index">\n <td ng-repeat="dt in row track by dt.date" class="text-center" role="gridcell" id="{{::dt.uid}}" ng-class="::dt.customClass">\n <button type="button" style="min-width:100%;" class="btn btn-default" ng-class="{\'btn-info\': dt.selected, active: isActive(dt)}" ng-click="select(dt.date)" ng-disabled="dt.disabled" tabindex="-1"><span ng-class="::{\'text-info\': dt.current}">{{::dt.label}}</span></button>\n </td>\n </tr>\n </tbody>\n</table>\n')}]),angular.module("template/modal/backdrop.html",[]).run(["$templateCache",function(a){a.put("template/modal/backdrop.html",'<div uib-modal-animation-class="fade"\n modal-in-class="in"\n ng-style="{\'z-index\': 1040 + (index && 1 || 0) + index*10}"\n></div>\n')}]),angular.module("template/modal/window.html",[]).run(["$templateCache",function(a){a.put("template/modal/window.html",'<div modal-render="{{$isRendered}}" tabindex="-1" role="dialog" class="modal"\n uib-modal-animation-class="fade"\n modal-in-class="in"\n ng-style="{\'z-index\': 1050 + index*10, display: \'block\'}">\n <div class="modal-dialog" ng-class="size ? \'modal-\' + size : \'\'"><div class="modal-content" uib-modal-transclude></div></div>\n</div>\n')}]),angular.module("template/pagination/pager.html",[]).run(["$templateCache",function(a){a.put("template/pagination/pager.html",'<ul class="pager">\n <li ng-class="{disabled: noPrevious()||ngDisabled, previous: align}"><a href ng-click="selectPage(page - 1, $event)">{{::getText(\'previous\')}}</a></li>\n <li ng-class="{disabled: noNext()||ngDisabled, next: align}"><a href ng-click="selectPage(page + 1, $event)">{{::getText(\'next\')}}</a></li>\n</ul>\n')}]),angular.module("template/pagination/pagination.html",[]).run(["$templateCache",function(a){a.put("template/pagination/pagination.html",'<ul class="pagination">\n <li ng-if="::boundaryLinks" ng-class="{disabled: noPrevious()||ngDisabled}" class="pagination-first"><a href ng-click="selectPage(1, $event)">{{::getText(\'first\')}}</a></li>\n <li ng-if="::directionLinks" ng-class="{disabled: noPrevious()||ngDisabled}" class="pagination-prev"><a href ng-click="selectPage(page - 1, $event)">{{::getText(\'previous\')}}</a></li>\n <li ng-repeat="page in pages track by $index" ng-class="{active: page.active,disabled: ngDisabled&&!page.active}" class="pagination-page"><a href ng-click="selectPage(page.number, $event)">{{page.text}}</a></li>\n <li ng-if="::directionLinks" ng-class="{disabled: noNext()||ngDisabled}" class="pagination-next"><a href ng-click="selectPage(page + 1, $event)">{{::getText(\'next\')}}</a></li>\n <li ng-if="::boundaryLinks" ng-class="{disabled: noNext()||ngDisabled}" class="pagination-last"><a href ng-click="selectPage(totalPages, $event)">{{::getText(\'last\')}}</a></li>\n</ul>\n')}]),angular.module("template/tooltip/tooltip-html-popup.html",[]).run(["$templateCache",function(a){a.put("template/tooltip/tooltip-html-popup.html",'<div\n tooltip-animation-class="fade"\n uib-tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="tooltip-arrow"></div>\n <div class="tooltip-inner" ng-bind-html="contentExp()"></div>\n</div>\n')}]),angular.module("template/tooltip/tooltip-html-unsafe-popup.html",[]).run(["$templateCache",function(a){a.put("template/tooltip/tooltip-html-unsafe-popup.html",'<div class="tooltip"\n tooltip-animation-class="fade"\n tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="tooltip-arrow"></div>\n <div class="tooltip-inner" bind-html-unsafe="content"></div>\n</div>\n')}]),angular.module("template/tooltip/tooltip-popup.html",[]).run(["$templateCache",function(a){a.put("template/tooltip/tooltip-popup.html",'<div\n tooltip-animation-class="fade"\n uib-tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="tooltip-arrow"></div>\n <div class="tooltip-inner" ng-bind="content"></div>\n</div>\n')}]),angular.module("template/tooltip/tooltip-template-popup.html",[]).run(["$templateCache",function(a){a.put("template/tooltip/tooltip-template-popup.html",'<div\n tooltip-animation-class="fade"\n uib-tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="tooltip-arrow"></div>\n <div class="tooltip-inner"\n uib-tooltip-template-transclude="contentExp()"\n tooltip-template-transclude-scope="originScope()"></div>\n</div>\n')}]),angular.module("template/popover/popover-html.html",[]).run(["$templateCache",function(a){a.put("template/popover/popover-html.html",'<div tooltip-animation-class="fade"\n uib-tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="arrow"></div>\n\n <div class="popover-inner">\n <h3 class="popover-title" ng-bind="title" ng-if="title"></h3>\n <div class="popover-content" ng-bind-html="contentExp()"></div>\n </div>\n</div>\n')}]),angular.module("template/popover/popover-template.html",[]).run(["$templateCache",function(a){a.put("template/popover/popover-template.html",'<div tooltip-animation-class="fade"\n uib-tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="arrow"></div>\n\n <div class="popover-inner">\n <h3 class="popover-title" ng-bind="title" ng-if="title"></h3>\n <div class="popover-content"\n uib-tooltip-template-transclude="contentExp()"\n tooltip-template-transclude-scope="originScope()"></div>\n </div>\n</div>\n')}]),angular.module("template/popover/popover.html",[]).run(["$templateCache",function(a){a.put("template/popover/popover.html",'<div tooltip-animation-class="fade"\n uib-tooltip-classes\n ng-class="{ in: isOpen() }">\n <div class="arrow"></div>\n\n <div class="popover-inner">\n <h3 class="popover-title" ng-bind="title" ng-if="title"></h3>\n <div class="popover-content" ng-bind="content"></div>\n </div>\n</div>\n')}]),angular.module("template/progressbar/bar.html",[]).run(["$templateCache",function(a){a.put("template/progressbar/bar.html",'<div class="progress-bar" ng-class="type && \'progress-bar-\' + type" role="progressbar" aria-valuenow="{{value}}" aria-valuemin="0" aria-valuemax="{{max}}" ng-style="{width: (percent < 100 ? percent : 100) + \'%\'}" aria-valuetext="{{percent | number:0}}%" aria-labelledby="{{::title}}" style="min-width: 0;" ng-transclude></div>\n')}]),angular.module("template/progressbar/progress.html",[]).run(["$templateCache",function(a){a.put("template/progressbar/progress.html",'<div class="progress" ng-transclude aria-labelledby="{{::title}}"></div>')}]),angular.module("template/progressbar/progressbar.html",[]).run(["$templateCache",function(a){a.put("template/progressbar/progressbar.html",'<div class="progress">\n <div class="progress-bar" ng-class="type && \'progress-bar-\' + type" role="progressbar" aria-valuenow="{{value}}" aria-valuemin="0" aria-valuemax="{{max}}" ng-style="{width: (percent < 100 ? percent : 100) + \'%\'}" aria-valuetext="{{percent | number:0}}%" aria-labelledby="{{::title}}" style="min-width: 0;" ng-transclude></div>\n</div>\n')}]),angular.module("template/rating/rating.html",[]).run(["$templateCache",function(a){a.put("template/rating/rating.html",'<span ng-mouseleave="reset()" ng-keydown="onKeydown($event)" tabindex="0" role="slider" aria-valuemin="0" aria-valuemax="{{range.length}}" aria-valuenow="{{value}}">\n <span ng-repeat-start="r in range track by $index" class="sr-only">({{ $index < value ? \'*\' : \' \' }})</span>\n <i ng-repeat-end ng-mouseenter="enter($index + 1)" ng-click="rate($index + 1)" class="glyphicon" ng-class="$index < value && (r.stateOn || \'glyphicon-star\') || (r.stateOff || \'glyphicon-star-empty\')" ng-attr-title="{{r.title}}" aria-valuetext="{{r.title}}"></i>\n</span>\n')}]),angular.module("template/tabs/tab.html",[]).run(["$templateCache",function(a){a.put("template/tabs/tab.html",'<li ng-class="{active: active, disabled: disabled}">\n <a href ng-click="select()" uib-tab-heading-transclude>{{heading}}</a>\n</li>\n')}]),angular.module("template/tabs/tabset.html",[]).run(["$templateCache",function(a){a.put("template/tabs/tabset.html",'<div>\n <ul class="nav nav-{{type || \'tabs\'}}" ng-class="{\'nav-stacked\': vertical, \'nav-justified\': justified}" ng-transclude></ul>\n <div class="tab-content">\n <div class="tab-pane" \n ng-repeat="tab in tabs" \n ng-class="{active: tab.active}"\n uib-tab-content-transclude="tab">\n </div>\n </div>\n</div>\n')}]),angular.module("template/timepicker/timepicker.html",[]).run(["$templateCache",function(a){a.put("template/timepicker/timepicker.html",'<table>\n <tbody>\n <tr class="text-center" ng-show="::showSpinners">\n <td><a ng-click="incrementHours()" ng-class="{disabled: noIncrementHours()}" class="btn btn-link"><span class="glyphicon glyphicon-chevron-up"></span></a></td>\n <td> </td>\n <td><a ng-click="incrementMinutes()" ng-class="{disabled: noIncrementMinutes()}" class="btn btn-link"><span class="glyphicon glyphicon-chevron-up"></span></a></td>\n <td ng-show="showMeridian"></td>\n </tr>\n <tr>\n <td class="form-group" ng-class="{\'has-error\': invalidHours}">\n <input style="width:50px;" type="text" ng-model="hours" ng-change="updateHours()" class="form-control text-center" ng-readonly="::readonlyInput" maxlength="2">\n </td>\n <td>:</td>\n <td class="form-group" ng-class="{\'has-error\': invalidMinutes}">\n <input style="width:50px;" type="text" ng-model="minutes" ng-change="updateMinutes()" class="form-control text-center" ng-readonly="::readonlyInput" maxlength="2">\n </td>\n <td ng-show="showMeridian"><button type="button" ng-class="{disabled: noToggleMeridian()}" class="btn btn-default text-center" ng-click="toggleMeridian()">{{meridian}}</button></td>\n </tr>\n <tr class="text-center" ng-show="::showSpinners">\n <td><a ng-click="decrementHours()" ng-class="{disabled: noDecrementHours()}" class="btn btn-link"><span class="glyphicon glyphicon-chevron-down"></span></a></td>\n <td> </td>\n <td><a ng-click="decrementMinutes()" ng-class="{disabled: noDecrementMinutes()}" class="btn btn-link"><span class="glyphicon glyphicon-chevron-down"></span></a></td>\n <td ng-show="showMeridian"></td>\n </tr>\n </tbody>\n</table>\n')}]),angular.module("template/typeahead/typeahead-match.html",[]).run(["$templateCache",function(a){a.put("template/typeahead/typeahead-match.html",'<a href tabindex="-1" ng-bind-html="match.label | uibTypeaheadHighlight:query"></a>\n')}]),angular.module("template/typeahead/typeahead-popup.html",[]).run(["$templateCache",function(a){a.put("template/typeahead/typeahead-popup.html",'<ul class="dropdown-menu" ng-show="isOpen() && !moveInProgress" ng-style="{top: position().top+\'px\', left: position().left+\'px\'}" style="display: block;" role="listbox" aria-hidden="{{!isOpen()}}">\n <li ng-repeat="match in matches track by $index" ng-class="{active: isActive($index) }" ng-mouseenter="selectActive($index)" ng-click="selectMatch($index)" role="option" id="{{::match.id}}">\n <div uib-typeahead-match index="$index" match="match" query="query" template-url="templateUrl"></div>\n </li>\n</ul>\n')}]),!angular.$$csp()&&angular.element(document).find("head").prepend('<style type="text/css">.ng-animate.item:not(.left):not(.right){-webkit-transition:0s ease-in-out left;transition:0s ease-in-out left}</style>'); |
| 12 | \ No newline at end of file | 12 | \ No newline at end of file |
src/main/resources/static/pages/base/region/add.html
0 → 100644
| 1 | +<!-- 片段标题 START --> | ||
| 2 | +<div class="page-head"> | ||
| 3 | + <div class="page-title"> | ||
| 4 | + <h1>添加公司</h1> | ||
| 5 | + </div> | ||
| 6 | +</div> | ||
| 7 | +<!-- 片段标题 END --> | ||
| 8 | + | ||
| 9 | +<!-- 公司信息导航栏组件 START --> | ||
| 10 | +<ul class="page-breadcrumb breadcrumb"> | ||
| 11 | + <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | ||
| 12 | + <li><span class="active">基础信息</span> <i class="fa fa-circle"></i></li> | ||
| 13 | + <li><a href="/pages/base/company/list.html" data-pjax>区域</a> <i class="fa fa-circle"></i></li> | ||
| 14 | + <li><span class="active">添加区域</span></li> | ||
| 15 | +</ul> | ||
| 16 | +<!-- 公司信息导航栏组件 END --> | ||
| 17 | + | ||
| 18 | +<!-- 信息容器组件 START --> | ||
| 19 | +<div class="portlet light bordered"> | ||
| 20 | + | ||
| 21 | + <!-- 信息容器组件标题 START --> | ||
| 22 | + <div class="portlet-title"> | ||
| 23 | + <div class="caption"> | ||
| 24 | + <i class="icon-equalizer font-red-sunglo"></i> | ||
| 25 | + <span class="caption-subject font-red-sunglo bold uppercase">添加区域</span> | ||
| 26 | + </div> | ||
| 27 | + </div> | ||
| 28 | + <!-- 信息容器组件标题 END --> | ||
| 29 | + | ||
| 30 | + <!-- 表单容器组件 START --> | ||
| 31 | + <div class="portlet-body form"> | ||
| 32 | + | ||
| 33 | + <!-- comp_add_form FORM START --> | ||
| 34 | + <form action="/line" class="form-horizontal" id="region_add_form" > | ||
| 35 | + | ||
| 36 | + <!-- 表单验证错误提示组件 START --> | ||
| 37 | + <div class="alert alert-danger display-hide"> | ||
| 38 | + <button class="close" data-close="alert"></button> | ||
| 39 | + 您的输入有误,请检查下面的输入项 | ||
| 40 | + </div> | ||
| 41 | + <!-- 表单验证错误提示组件 END --> | ||
| 42 | + | ||
| 43 | + <!-- 表单字段内容 START --> | ||
| 44 | + <div class="form-body"> | ||
| 45 | + <!-- 表单分组组件 form-group START --> | ||
| 46 | + <div class="form-group"> | ||
| 47 | + <!-- 公司编码 (* 必填项) START --> | ||
| 48 | + <div class="col-md-9"> | ||
| 49 | + <label class="control-label col-md-5"> | ||
| 50 | + <span class="required"> * </span>区域名称: | ||
| 51 | + </label> | ||
| 52 | + <div class="col-md-4"> | ||
| 53 | + <input type="text" class="form-control" name="name" id="name" placeholder="公司编码"> | ||
| 54 | + </div> | ||
| 55 | + </div> | ||
| 56 | + <!-- 公司编码 (* 必填项) END --> | ||
| 57 | + </div> | ||
| 58 | + <!-- 表单分组组件 form-group END --> | ||
| 59 | + | ||
| 60 | + </div> | ||
| 61 | + <!-- 表单字段内容 END --> | ||
| 62 | + | ||
| 63 | + <!-- 表单按钮组件 START --> | ||
| 64 | + <div class="form-actions"> | ||
| 65 | + <div class="row"> | ||
| 66 | + <div class="col-md-offset-3 col-md-4"> | ||
| 67 | + <button type="submit" class="btn green" id="submintBtn"><i class="fa fa-check"></i> 提交</button> | ||
| 68 | + <a type="button" class="btn default" href="list.html" data-pjax><i class="fa fa-times"></i> 取消</a> | ||
| 69 | + </div> | ||
| 70 | + </div> | ||
| 71 | + </div> | ||
| 72 | + <!-- 表单按钮组件 END --> | ||
| 73 | + </form> | ||
| 74 | + <!-- comp_add_form FORM END --> | ||
| 75 | + </div> | ||
| 76 | + <!-- 表单组件 END --> | ||
| 77 | +</div> | ||
| 78 | +<!-- 信息容器组件 END --> | ||
| 79 | +<!-- 公司信息添加片段JS模块 --> | ||
| 80 | +<script src="/pages/base/region/js/region_add.js"></script> | ||
| 0 | \ No newline at end of file | 81 | \ No newline at end of file |
src/main/resources/static/pages/base/region/js/region_add.js
0 → 100644
| 1 | +/** | ||
| 2 | + * @description TODO(区域信息添加片段JS模块) | ||
| 3 | + * | ||
| 4 | + * @author bsth@lq | ||
| 5 | + * | ||
| 6 | + * @date 二〇一六年十月十八日 13:31:58 | ||
| 7 | + * | ||
| 8 | + */ | ||
| 9 | + | ||
| 10 | +$(function(){ | ||
| 11 | + // 定义表单 | ||
| 12 | + var form = $('#region_add_form'); | ||
| 13 | + // 定义表单异常 | ||
| 14 | + var error = $('.alert-danger',form); | ||
| 15 | + // 表单验证 | ||
| 16 | + form.validate({ | ||
| 17 | + // 错误提示元素span对象 | ||
| 18 | + errorElement : 'span', | ||
| 19 | + // 错误提示元素class名称 | ||
| 20 | + errorClass : 'help-block help-block-error', | ||
| 21 | + // 验证错误获取焦点 | ||
| 22 | + focusInvalid : true, | ||
| 23 | + // 需要验证的表单元素 | ||
| 24 | + rules : { | ||
| 25 | + | ||
| 26 | + // 区域名称 | ||
| 27 | + 'name' : { | ||
| 28 | + // 必填项 | ||
| 29 | + required : true, | ||
| 30 | + // 最大长度 | ||
| 31 | + maxlength: 30 | ||
| 32 | + }, | ||
| 33 | + }, | ||
| 34 | + /** | ||
| 35 | + * 类型:Callback。当未通过验证的表单提交时,可以在该回调函数中处理一些事情。 | ||
| 36 | + * | ||
| 37 | + * 参数:该回调函数有两个参数:第一个为一个事件对象,第二个为验证器(validator) | ||
| 38 | + */ | ||
| 39 | + invalidHandler : function(event, validator) { | ||
| 40 | + // 显示表单未通过提示信息 | ||
| 41 | + error.show(); | ||
| 42 | + // 把提示信息放到指定的位置。 | ||
| 43 | + App.scrollTo(error, -200); | ||
| 44 | + }, | ||
| 45 | + /** | ||
| 46 | + * 类型:Callback。 | ||
| 47 | + * | ||
| 48 | + * 默认:添加errorClass("has-error")到表单元素。将未通过验证的表单元素设置高亮。 | ||
| 49 | + */ | ||
| 50 | + highlight : function(element) { | ||
| 51 | + // 添加errorClass("has-error")到表单元素 | ||
| 52 | + $(element).closest('.form-group').addClass('has-error'); | ||
| 53 | + | ||
| 54 | + }, | ||
| 55 | + /** | ||
| 56 | + * 类型:Callback。 | ||
| 57 | + * | ||
| 58 | + * 默认:移除errorClass("has-error")。与highlight操作相反 | ||
| 59 | + */ | ||
| 60 | + unhighlight : function(element) { | ||
| 61 | + // 移除errorClass("has-error") | ||
| 62 | + $(element).closest('.form-group').removeClass('has-error'); | ||
| 63 | + | ||
| 64 | + }, | ||
| 65 | + /** | ||
| 66 | + * 类型:String,Callback。 | ||
| 67 | + * | ||
| 68 | + * 如果指定它,当验证通过时显示一个消息。 | ||
| 69 | + * | ||
| 70 | + * 如果是String类型的,则添加该样式到标签中; | ||
| 71 | + * | ||
| 72 | + * 如果是一个回调函数,则将标签作为其唯一的参数。 | ||
| 73 | + */ | ||
| 74 | + success : function(label) { | ||
| 75 | + // 当验证通过时,移除errorClass("has-error") | ||
| 76 | + label.closest('.form-group').removeClass('has-error'); | ||
| 77 | + }, | ||
| 78 | + | ||
| 79 | + /** | ||
| 80 | + * 类型:Callback。 | ||
| 81 | + * | ||
| 82 | + * 默认:default (native) form submit;当表单通过验证,提交表单。回调函数有个默认参数form | ||
| 83 | + */ | ||
| 84 | + submitHandler : function(f) { | ||
| 85 | + // 隐藏错误提示 | ||
| 86 | + error.hide(); | ||
| 87 | + // 表单序列化 | ||
| 88 | + var params = form.serializeJSON(); | ||
| 89 | + // 提交 | ||
| 90 | + // 防止用户多次提交 | ||
| 91 | + $("#submintBtn").addClass("disabled"); | ||
| 92 | + // 添加数据 | ||
| 93 | + $post('/region', params, function(result) { | ||
| 94 | + // 如果返回结果不为空 | ||
| 95 | + if(result){ | ||
| 96 | + // 返回状态码为"SUCCESS" ,则添加成功;返回状态码为"ERROR" ,则添加失败 | ||
| 97 | + if(result.status=='SUCCESS') { | ||
| 98 | + // 弹出添加成功提示消息 | ||
| 99 | + layer.msg('添加成功...'); | ||
| 100 | + } else if(result.status=='ERROR') { | ||
| 101 | + // 弹出添加失败提示消息 | ||
| 102 | + layer.msg('添加失败...'); | ||
| 103 | + } | ||
| 104 | + } | ||
| 105 | + // 返回list.html页面 | ||
| 106 | + loadPage('list.html'); | ||
| 107 | + }); | ||
| 108 | + $("#submintBtn").removeClass("disabled"); | ||
| 109 | + | ||
| 110 | + } | ||
| 111 | + }); | ||
| 112 | +}); | ||
| 0 | \ No newline at end of file | 113 | \ No newline at end of file |
src/main/resources/static/pages/base/region/js/region_list.js
0 → 100644
| 1 | +/** | ||
| 2 | + * | ||
| 3 | + * @JSName : list.js(区域list.html页面js) | ||
| 4 | + * | ||
| 5 | + * @Author : bsth@lq | ||
| 6 | + * | ||
| 7 | + * @Description : TODO区域.html页面js) | ||
| 8 | + * | ||
| 9 | + * | ||
| 10 | + */ | ||
| 11 | + | ||
| 12 | +(function(){ | ||
| 13 | + // 关闭左侧栏 | ||
| 14 | + if (!$('body').hasClass('page-sidebar-closed')) {$('.menu-toggler.sidebar-toggler').click();} | ||
| 15 | + | ||
| 16 | + /** page : 当前页 initPag : */ | ||
| 17 | + var page = 0,initPag; | ||
| 18 | + /** 表格数据分页加载 */ | ||
| 19 | + loadTableDate(null,true); | ||
| 20 | + function getParams() { | ||
| 21 | + // cells 集合返回表格中所有(列)单元格的一个数组 | ||
| 22 | + var cells = $('tr.filter')[0].cells; | ||
| 23 | + // 搜索参数集合 | ||
| 24 | + var params = {}; | ||
| 25 | + // 搜索字段名称 | ||
| 26 | + var name; | ||
| 27 | + // 遍历cells数组 | ||
| 28 | + $.each(cells, function(i, cell){ | ||
| 29 | + // 获取第i列的input或者select集合 | ||
| 30 | + var items = $('input,select', cell); | ||
| 31 | + // 遍历items集合 | ||
| 32 | + for(var j = 0, item; item = items[j++];){ | ||
| 33 | + // 获取字段名称 | ||
| 34 | + name = $(item).attr('name'); | ||
| 35 | + if(name){ | ||
| 36 | + // 赋取相对应的值 | ||
| 37 | + params[name] = $(item).val(); | ||
| 38 | + } | ||
| 39 | + } | ||
| 40 | + }); | ||
| 41 | + if(params.parkName_like=='请选择...') | ||
| 42 | + params.parkName_like = ''; | ||
| 43 | + else | ||
| 44 | + params.parkName_like = params.parkName_like.split('_')[0]; | ||
| 45 | + return params; | ||
| 46 | + } | ||
| 47 | + | ||
| 48 | + /** | ||
| 49 | + * 表格数据分页加载事件 | ||
| 50 | + * | ||
| 51 | + * ------@param : 查询参数 | ||
| 52 | + * | ||
| 53 | + * ------@isPon : 是否重新分页 | ||
| 54 | + * | ||
| 55 | + */ | ||
| 56 | + function loadTableDate(param,isPon){ | ||
| 57 | + // 搜索参数 | ||
| 58 | + var params = {}; | ||
| 59 | + if(param) { | ||
| 60 | + params = param; | ||
| 61 | + } | ||
| 62 | + // 排序(按更新时间) | ||
| 63 | + params['order'] = 'id'; | ||
| 64 | + // 记录当前页数 | ||
| 65 | + params['page'] = page; | ||
| 66 | + // 弹出正在加载层 | ||
| 67 | + var i = layer.load(2); | ||
| 68 | + | ||
| 69 | + // 异步请求获取表格数据 | ||
| 70 | + $.get('/region',params,function(result){ | ||
| 71 | + // 添加序号 | ||
| 72 | + result.content.page = page; | ||
| 73 | + | ||
| 74 | + // 把数据填充到模版中 | ||
| 75 | + var tbodyHtml = template('region_list_table_temp',{list:result.content}); | ||
| 76 | + $('#datatable_region tbody').html(tbodyHtml); | ||
| 77 | + // 是重新分页且返回数据长度大于0 | ||
| 78 | + if(isPon && result.content.length > 0){ | ||
| 79 | + // 重新分页 | ||
| 80 | + initPag = true; | ||
| 81 | + // 分页栏 | ||
| 82 | + showPagination(result); | ||
| 83 | + } | ||
| 84 | + // 关闭弹出加载层 | ||
| 85 | + layer.close(i); | ||
| 86 | + }); | ||
| 87 | + | ||
| 88 | + } | ||
| 89 | + | ||
| 90 | + /** 分页栏组件 */ | ||
| 91 | + function showPagination(data){ | ||
| 92 | + // 分页组件 | ||
| 93 | + $('#pagination').jqPaginator({ | ||
| 94 | + // 总页数 | ||
| 95 | + totalPages: data.totalPages, | ||
| 96 | + // 中间显示页数 | ||
| 97 | + visiblePages: 6, | ||
| 98 | + // 当前页 | ||
| 99 | + currentPage: page + 1, | ||
| 100 | + first: '<li class="first"><a href="javascript:void(0);">首页<\/a><\/li>', | ||
| 101 | + prev: '<li class="prev"><a href="javascript:void(0);">上一页<\/a><\/li>', | ||
| 102 | + next: '<li class="next"><a href="javascript:void(0);">下一页<\/a><\/li>', | ||
| 103 | + last: '<li class="last"><a href="javascript:void(0);">尾页<\/a><\/li>', | ||
| 104 | + page: '<li class="page"><a href="javascript:void(0);">{{page}}<\/a><\/li>', | ||
| 105 | + onPageChange: function (num, type) { | ||
| 106 | + if(initPag){ | ||
| 107 | + initPag = false; | ||
| 108 | + return; | ||
| 109 | + } | ||
| 110 | + var pData = getParams(); | ||
| 111 | + page = num - 1; | ||
| 112 | + loadTableDate(pData, false); | ||
| 113 | + } | ||
| 114 | + }); | ||
| 115 | + } | ||
| 116 | +})(); | ||
| 0 | \ No newline at end of file | 117 | \ No newline at end of file |
src/main/resources/static/pages/base/region/list.html
0 → 100644
| 1 | +<div class="page-head"> | ||
| 2 | + <div class="page-title"> | ||
| 3 | + <h1>区域信息</h1> | ||
| 4 | + </div> | ||
| 5 | +</div> | ||
| 6 | + | ||
| 7 | +<ul class="page-breadcrumb breadcrumb"> | ||
| 8 | + <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | ||
| 9 | + <li><span class="active">基础信息</span> <i class="fa fa-circle"></i></li> | ||
| 10 | + <li><span class="active">区域信息</span></li> | ||
| 11 | +</ul> | ||
| 12 | + | ||
| 13 | +<div class="row"> | ||
| 14 | + <div class="col-md-12"> | ||
| 15 | + <div class="portlet light porttlet-fit bordered"> | ||
| 16 | + <div class="portlet-title"> | ||
| 17 | + <div class="caption"> | ||
| 18 | + <i class="fa fa-info-circle font-dark"></i> | ||
| 19 | + <span class="caption-subject font-dark sbold uppercase">区域信息</span> | ||
| 20 | + </div> | ||
| 21 | + <div class="actions"> | ||
| 22 | + <div class="btn-group btn-group-devided" data-toggle="buttons"> | ||
| 23 | + <a class="btn btn-circle blue" href="add.html" data-pjax><i class="fa fa-plus"></i> 添加区域</a> | ||
| 24 | + </div> | ||
| 25 | + </div> | ||
| 26 | + </div> | ||
| 27 | + <div class="portlet-body"> | ||
| 28 | + <div class="table-container" style="margin-top: 10px"> | ||
| 29 | + <table class="table table-striped table-bordered table-hover table-checkable" id="datatable_region"> | ||
| 30 | + <thead> | ||
| 31 | + <tr role="row" class="heading"> | ||
| 32 | + <th width="3%">序号</th> | ||
| 33 | + <th width="12%">区域</th> | ||
| 34 | + <th width="6%">是否撤销</th> | ||
| 35 | + <th width="10%">操作</th> | ||
| 36 | + </tr> | ||
| 37 | + <tr role="row" class="filter"> | ||
| 38 | + <td>#</td> | ||
| 39 | + <td>#</td> | ||
| 40 | + <td>#</td> | ||
| 41 | + <td> | ||
| 42 | + <button class="btn btn-sm green btn-outline filter-submit margin-bottom" > | ||
| 43 | + <i class="fa fa-search"></i> 搜索 | ||
| 44 | + </button> | ||
| 45 | + | ||
| 46 | + <button class="btn btn-sm red btn-outline filter-cancel"> | ||
| 47 | + <i class="fa fa-times"></i> 重置 | ||
| 48 | + </button> | ||
| 49 | + </td> | ||
| 50 | + </tr> | ||
| 51 | + </thead> | ||
| 52 | + <tbody></tbody> | ||
| 53 | + </table> | ||
| 54 | + <div style="text-align: right;"> | ||
| 55 | + <ul id="pagination" class="pagination"></ul> | ||
| 56 | + </div> | ||
| 57 | + </div> | ||
| 58 | + </div> | ||
| 59 | + </div> | ||
| 60 | + </div> | ||
| 61 | +</div> | ||
| 62 | + | ||
| 63 | +<script type="text/html" id="region_list_table_temp"> | ||
| 64 | + {{each list as obj i }} | ||
| 65 | + <tr> | ||
| 66 | + <td style="vertical-align: middle;"> | ||
| 67 | + {{(list.page*10)+(i+1)}} | ||
| 68 | + </td> | ||
| 69 | + <td> | ||
| 70 | + {{obj.name}} | ||
| 71 | + </td> | ||
| 72 | + | ||
| 73 | + <td> | ||
| 74 | + {{if obj.destroy == 1}} | ||
| 75 | + <span style="font-weight: bold; color: red; padding: 5px; background-color: #FFE4E1; margin: 5px; font-size: 9px;border-radius: 4px;">撤销</span> | ||
| 76 | + {{else if obj.destroy == 0}} | ||
| 77 | + <span style="font-weight: bold; color: #07824e; padding: 5px; background-color: #FFE4E1; margin: 5px; font-size: 9px;border-radius: 4px;">运营</span> | ||
| 78 | + {{/if}} | ||
| 79 | + </td> | ||
| 80 | + <td> | ||
| 81 | + <a href="edit.html?no={{obj.id}}" class="btn default blue-stripe btn-sm" data-pjax> 修改 </a> | ||
| 82 | + {{if obj.destroy==1}} | ||
| 83 | + <a class="ct_base_line_delete_link" data-id="{{obj.id}}" data-name="{{obj.name}}"> 删除 </a> | ||
| 84 | + {{/if}} | ||
| 85 | + </td> | ||
| 86 | + </tr> | ||
| 87 | + {{/each}} | ||
| 88 | + {{if list.length == 0}} | ||
| 89 | + <tr> | ||
| 90 | + <td colspan=10><h6 class="muted">没有找到相关数据</h6></td> | ||
| 91 | + </tr> | ||
| 92 | + {{/if}} | ||
| 93 | +</script> | ||
| 94 | +<script src="/pages/base/region/js/region_list.js"></script> | ||
| 0 | \ No newline at end of file | 95 | \ No newline at end of file |
src/main/resources/static/pages/base/region_line_car/add.html
0 → 100644
| 1 | +<!-- 片段标题 START --> | ||
| 2 | +<div class="page-head"> | ||
| 3 | + <div class="page-title"> | ||
| 4 | + <h1>添加公司</h1> | ||
| 5 | + </div> | ||
| 6 | +</div> | ||
| 7 | +<!-- 片段标题 END --> | ||
| 8 | + | ||
| 9 | +<!-- 公司信息导航栏组件 START --> | ||
| 10 | +<ul class="page-breadcrumb breadcrumb"> | ||
| 11 | + <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | ||
| 12 | + <li><span class="active">基础信息</span> <i class="fa fa-circle"></i></li> | ||
| 13 | + <li><a href="/pages/base/company/list.html" data-pjax>区域</a> <i class="fa fa-circle"></i></li> | ||
| 14 | + <li><span class="active">添加区域</span></li> | ||
| 15 | +</ul> | ||
| 16 | +<!-- 公司信息导航栏组件 END --> | ||
| 17 | + | ||
| 18 | +<!-- 信息容器组件 START --> | ||
| 19 | +<div class="portlet light bordered"> | ||
| 20 | + | ||
| 21 | + <!-- 信息容器组件标题 START --> | ||
| 22 | + <div class="portlet-title"> | ||
| 23 | + <div class="caption"> | ||
| 24 | + <i class="icon-equalizer font-red-sunglo"></i> | ||
| 25 | + <span class="caption-subject font-red-sunglo bold uppercase">添加区域</span> | ||
| 26 | + </div> | ||
| 27 | + </div> | ||
| 28 | + <!-- 信息容器组件标题 END --> | ||
| 29 | + | ||
| 30 | + <!-- 表单容器组件 START --> | ||
| 31 | + <div class="portlet-body form"> | ||
| 32 | + | ||
| 33 | + <!-- comp_add_form FORM START --> | ||
| 34 | + <form action="/line" class="form-horizontal" id="region_line_car_add_form" > | ||
| 35 | + | ||
| 36 | + <!-- 表单验证错误提示组件 START --> | ||
| 37 | + <div class="alert alert-danger display-hide"> | ||
| 38 | + <button class="close" data-close="alert"></button> | ||
| 39 | + 您的输入有误,请检查下面的输入项 | ||
| 40 | + </div> | ||
| 41 | + <!-- 表单验证错误提示组件 END --> | ||
| 42 | + | ||
| 43 | + | ||
| 44 | + <!-- 表单字段内容 START --> | ||
| 45 | + <div class="form-body"> | ||
| 46 | + <!-- 表单分组组件 form-group START --> | ||
| 47 | + <div class="form-group"> | ||
| 48 | + <!-- 公司编码 (* 必填项) START --> | ||
| 49 | + <div class="col-md-9"> | ||
| 50 | + <label class="control-label col-md-5"> | ||
| 51 | + <span class="required"> * </span>区域名称: | ||
| 52 | + </label> | ||
| 53 | + <div class="col-md-4"> | ||
| 54 | + <select name="region" class="form-control" style="width:100%" id="regionSelect"></select> | ||
| 55 | + </div> | ||
| 56 | + </div> | ||
| 57 | + </div> | ||
| 58 | + </div> | ||
| 59 | + | ||
| 60 | + <div class="form-body"> | ||
| 61 | + <div class="form-group"> | ||
| 62 | + <div class="col-md-9"> | ||
| 63 | + <label class="control-label col-md-5"> | ||
| 64 | + <span class="required"> * </span> 线路名称 : | ||
| 65 | + </label> | ||
| 66 | + <div class="col-md-4"> | ||
| 67 | + <select name="line" class="form-control" style="width:100%" id="lineSelect"></select> | ||
| 68 | + </div> | ||
| 69 | + </div> | ||
| 70 | + </div> | ||
| 71 | + </div> | ||
| 72 | + | ||
| 73 | + <div class="form-body"> | ||
| 74 | + <!-- 表单分组组件 form-group START --> | ||
| 75 | + <div class="form-group"> | ||
| 76 | + <!-- 公司编码 (* 必填项) START --> | ||
| 77 | + <div class="col-md-9"> | ||
| 78 | + <label class="control-label col-md-5"> | ||
| 79 | + <span class="required"> * </span>车辆: | ||
| 80 | + </label> | ||
| 81 | + <div class="col-md-4"> | ||
| 82 | + <select name="car" class="form-control" style="width:100%" id="carSelect"></select> | ||
| 83 | + </div> | ||
| 84 | + </div> | ||
| 85 | + <!-- 公司编码 (* 必填项) END --> | ||
| 86 | + </div> | ||
| 87 | + <!-- 表单分组组件 form-group END --> | ||
| 88 | + | ||
| 89 | + </div> | ||
| 90 | + <!-- 表单按钮组件 START --> | ||
| 91 | + <div class="form-actions"> | ||
| 92 | + <div class="row"> | ||
| 93 | + <div class="col-md-offset-3 col-md-4"> | ||
| 94 | + <button type="submit" class="btn green" id="submintBtn"><i class="fa fa-check"></i> 提交</button> | ||
| 95 | + <a type="button" class="btn default" href="list.html" data-pjax><i class="fa fa-times"></i> 取消</a> | ||
| 96 | + </div> | ||
| 97 | + </div> | ||
| 98 | + </div> | ||
| 99 | + <!-- 表单按钮组件 END --> | ||
| 100 | + </form> | ||
| 101 | + <!-- comp_add_form FORM END --> | ||
| 102 | + </div> | ||
| 103 | + <!-- 表单组件 END --> | ||
| 104 | +</div> | ||
| 105 | +<!-- 信息容器组件 END --> | ||
| 106 | +<!-- 公司信息添加片段JS模块 --> | ||
| 107 | +<script src="/pages/base/region_line_car/js/region_add.js"></script> | ||
| 0 | \ No newline at end of file | 108 | \ No newline at end of file |
src/main/resources/static/pages/base/region_line_car/js/region_add.js
0 → 100644
| 1 | +/** | ||
| 2 | + * @description TODO(区域信息添加片段JS模块) | ||
| 3 | + * | ||
| 4 | + * @author bsth@lq | ||
| 5 | + * | ||
| 6 | + * @date 二〇一六年十月十八日 13:31:58 | ||
| 7 | + * | ||
| 8 | + */ | ||
| 9 | + | ||
| 10 | +$(function(){ | ||
| 11 | + storage = window.localStorage; | ||
| 12 | + | ||
| 13 | + // 营运公司Map[key(businessCode)] = 名字 | ||
| 14 | + var companyMap = new Map(); | ||
| 15 | + // 分公司Map[key(upCode+_+businessCode)] = 名字 | ||
| 16 | + var branchMap = new Map(); | ||
| 17 | + initCompanySelect2(function(array) { | ||
| 18 | + $.each(array, function() { | ||
| 19 | + companyMap[this.businessCode] = this.businessName; | ||
| 20 | + // companyMap.put(this.businessCode.toString(), this.businessName); | ||
| 21 | + if(this.businessCode != null || this.businessCode !=''){ | ||
| 22 | + /** 查询出所属公司下的分公司名称和相应分公司代码 @param:<upCode_eq:公司代码> */ | ||
| 23 | + $get('/business/all', {upCode_eq: this.businessCode}, function(array){ | ||
| 24 | + // 遍历array | ||
| 25 | + $.each(array, function(i,d){ | ||
| 26 | + branchMap[this.upCode+"_"+this.businessCode] = this.businessName; | ||
| 27 | + // branchMap.put(this.upCode+"_"+this.businessCode, this.businessName); | ||
| 28 | + }); | ||
| 29 | + }); | ||
| 30 | + } | ||
| 31 | + }); | ||
| 32 | + // 公司下拉options属性值 | ||
| 33 | + var options = '<option value="">请选择...</option>'; | ||
| 34 | + // 遍历array | ||
| 35 | + $.each(array, function(i,d){ | ||
| 36 | + options += '<option value="'+d.businessCode+'">'+d.businessName+'</option>'; | ||
| 37 | + }); | ||
| 38 | + // 初始化公司下拉框并监听值改变事件. | ||
| 39 | + $('#companySelect').html(options).on('change', setBrancheCompanySelectOptions); | ||
| 40 | + // 初始化分公司下拉框. | ||
| 41 | + setBrancheCompanySelectOptions(); | ||
| 42 | + initLineSelect2(array); | ||
| 43 | + | ||
| 44 | + }); | ||
| 45 | + | ||
| 46 | + function initCompanySelect2(cb) { | ||
| 47 | + // get请求获取公司 | ||
| 48 | + $get('/business/all', {upCode_eq: '88'}, function(gs_d){ | ||
| 49 | + return cb && cb(gs_d); | ||
| 50 | + }); | ||
| 51 | + } | ||
| 52 | + function getComp(cb) { | ||
| 53 | + $.get('/user/companyData',null,function(rs) { | ||
| 54 | + return cb && cb(rs); | ||
| 55 | + }); | ||
| 56 | + } | ||
| 57 | + /** 填充分公司下拉框选择值 */ | ||
| 58 | + function setBrancheCompanySelectOptions(){ | ||
| 59 | + // 获取公司下拉框选择值 | ||
| 60 | + var businessCode = $('#companySelect').val(); | ||
| 61 | + // 分公司下拉框options属性值 | ||
| 62 | + var options = '<option value="">请选择...</option>'; | ||
| 63 | + // 如果公司选择为空则分公司为空 ; 否则查询出所属公司下的分公司名称和相应分公司代码 | ||
| 64 | + if(businessCode == null || businessCode ==''){ | ||
| 65 | + // 填充分公司下拉框options | ||
| 66 | + $('#brancheCompanySelect').html(options); | ||
| 67 | + } else { | ||
| 68 | + /** 查询出所属公司下的分公司名称和相应分公司代码 @param:<upCode_eq:公司代码> */ | ||
| 69 | + $get('/business/all', {upCode_eq: businessCode}, function(array){ | ||
| 70 | + // 遍历array | ||
| 71 | + $.each(array, function(i,d){ | ||
| 72 | + options += '<option value="'+d.businessCode+'">'+d.businessName+'</option>'; | ||
| 73 | + // 填充分公司下拉框options | ||
| 74 | + $('#brancheCompanySelect').html(options); | ||
| 75 | + }); | ||
| 76 | + }); | ||
| 77 | + } | ||
| 78 | + }; | ||
| 79 | + function initLineSelect2(compD) { | ||
| 80 | + getComp(function(rs) { | ||
| 81 | + var params = {}; | ||
| 82 | + if(rs.length>0) { | ||
| 83 | + var compA = new Array(); | ||
| 84 | + for(var c = 0 ; c<rs.length;c++) { | ||
| 85 | + var comC = rs[c].companyCode; | ||
| 86 | + var child = rs[c].children; | ||
| 87 | + if(child.length>0) { | ||
| 88 | + for(var d = 0 ;d< child.length;d++) { | ||
| 89 | + compA.push(comC + '_' + child[d].code); | ||
| 90 | + } | ||
| 91 | + }else { | ||
| 92 | + compA.push(comC); | ||
| 93 | + } | ||
| 94 | + } | ||
| 95 | + params.cgsbm_in = compA.toString(); | ||
| 96 | + } | ||
| 97 | + // 填充线路拉框选择值 | ||
| 98 | + $get('/line/all', params, function(array){ | ||
| 99 | + var len_ = array.length,paramsD = new Array(); | ||
| 100 | + if(len_>0) { | ||
| 101 | + $.each(array, function(i, g){ | ||
| 102 | + if(g.name!='' || g.name != null) { | ||
| 103 | + paramsD.push({'id':g.name + '_' + g.id + '_' + g.lineCode ,'text':g.name + gsdmTogsName(compD,g.company)}); | ||
| 104 | + } | ||
| 105 | + }); | ||
| 106 | + initPinYinSelect2($('#lineSelect'),paramsD,function(selector) { | ||
| 107 | + selector.select2("val", storage.xlName_AgursData); | ||
| 108 | + }); | ||
| 109 | + } | ||
| 110 | + }); | ||
| 111 | + | ||
| 112 | + | ||
| 113 | + // 填充车辆拉框选择值 | ||
| 114 | + $get('/cars/all', params, function(array){ | ||
| 115 | + var len_ = array.length,paramsD = new Array(); | ||
| 116 | + if(len_>0) { | ||
| 117 | + $.each(array, function(i, g){ | ||
| 118 | + if(g.name!='' || g.name != null) { | ||
| 119 | + | ||
| 120 | + paramsD.push({'id':g.insideCode,'text':g.insideCode + gsdmTogsName(compD,g.company)}); | ||
| 121 | + } | ||
| 122 | + }); | ||
| 123 | + initPinYinSelect2($('#carSelect'),paramsD,function(selector) { | ||
| 124 | + }); | ||
| 125 | + } | ||
| 126 | + }); | ||
| 127 | + | ||
| 128 | + | ||
| 129 | + // 填充车辆拉框选择值 | ||
| 130 | + $get('/region/all', null, function(array){ | ||
| 131 | + var len_ = array.length,paramsD = new Array(); | ||
| 132 | + if(len_>0) { | ||
| 133 | + $.each(array, function(i, g){ | ||
| 134 | + paramsD.push({'id':g.id ,'text':g.name}); | ||
| 135 | + }); | ||
| 136 | + | ||
| 137 | + initPinYinSelect2($('#regionSelect'),paramsD,function(selector) {}); | ||
| 138 | + } | ||
| 139 | + }); | ||
| 140 | + | ||
| 141 | + | ||
| 142 | + }); | ||
| 143 | + }; | ||
| 144 | + function gsdmTogsName(gsD,code) { | ||
| 145 | + var rsStr = ''; | ||
| 146 | + for(var s = 0 ; s < gsD.length; s++) { | ||
| 147 | + if(gsD[s].businessCode == code) { | ||
| 148 | + rsStr = rsStr + '(' + gsD[s].businessName.replace('公司','') + ')'; | ||
| 149 | + break; | ||
| 150 | + } | ||
| 151 | + } | ||
| 152 | + return rsStr; | ||
| 153 | + } | ||
| 154 | + | ||
| 155 | + | ||
| 156 | + // 定义表单 | ||
| 157 | + var form = $('#region_line_car_add_form'); | ||
| 158 | + // 定义表单异常 | ||
| 159 | + var error = $('.alert-danger',form); | ||
| 160 | + // 表单验证 | ||
| 161 | + form.validate({ | ||
| 162 | + submitHandler : function(f) { | ||
| 163 | + // 隐藏错误提示 | ||
| 164 | + error.hide(); | ||
| 165 | + // 表单序列化 | ||
| 166 | + var params = form.serializeJSON(); | ||
| 167 | + debugger | ||
| 168 | + | ||
| 169 | + let data = { | ||
| 170 | + region : params.region | ||
| 171 | + }; | ||
| 172 | + if (params.line != null){ | ||
| 173 | + let line = params.line.split("_"); | ||
| 174 | + data['line'] =line[1]; | ||
| 175 | + data['lineName'] =line[0]; | ||
| 176 | + } | ||
| 177 | + if (params.car != null){ | ||
| 178 | + data['clZbh'] =params.car; | ||
| 179 | + } | ||
| 180 | + | ||
| 181 | + | ||
| 182 | + | ||
| 183 | + | ||
| 184 | + | ||
| 185 | + // 提交 | ||
| 186 | + | ||
| 187 | + // 防止用户多次提交 | ||
| 188 | + $("#submintBtn").addClass("disabled"); | ||
| 189 | + // 添加数据 | ||
| 190 | + $post('/regionLineCar', data, function(result) { | ||
| 191 | + // 如果返回结果不为空 | ||
| 192 | + if(result){ | ||
| 193 | + // 返回状态码为"SUCCESS" ,则添加成功;返回状态码为"ERROR" ,则添加失败 | ||
| 194 | + if(result.status=='SUCCESS') { | ||
| 195 | + // 弹出添加成功提示消息 | ||
| 196 | + layer.msg('添加成功...'); | ||
| 197 | + } else if(result.status=='ERROR') { | ||
| 198 | + // 弹出添加失败提示消息 | ||
| 199 | + layer.msg('添加失败...'); | ||
| 200 | + } | ||
| 201 | + } | ||
| 202 | + // 返回list.html页面 | ||
| 203 | + loadPage('list.html'); | ||
| 204 | + }); | ||
| 205 | + $("#submintBtn").removeClass("disabled"); | ||
| 206 | + | ||
| 207 | + } | ||
| 208 | + }); | ||
| 209 | + | ||
| 210 | +}); | ||
| 211 | + | ||
| 212 | + |
src/main/resources/static/pages/base/region_line_car/js/region_list.js
0 → 100644
| 1 | +/** | ||
| 2 | + * | ||
| 3 | + * @JSName : list.js(区域list.html页面js) | ||
| 4 | + * | ||
| 5 | + * @Author : bsth@lq | ||
| 6 | + * | ||
| 7 | + * @Description : TODO区域.html页面js) | ||
| 8 | + * | ||
| 9 | + * | ||
| 10 | + */ | ||
| 11 | + | ||
| 12 | +(function(){ | ||
| 13 | + // 关闭左侧栏 | ||
| 14 | + if (!$('body').hasClass('page-sidebar-closed')) {$('.menu-toggler.sidebar-toggler').click();} | ||
| 15 | + | ||
| 16 | + /** page : 当前页 initPag : */ | ||
| 17 | + var page = 0,initPag; | ||
| 18 | + /** 表格数据分页加载 */ | ||
| 19 | + loadTableDate(null,true); | ||
| 20 | + function getParams() { | ||
| 21 | + // cells 集合返回表格中所有(列)单元格的一个数组 | ||
| 22 | + var cells = $('tr.filter')[0].cells; | ||
| 23 | + // 搜索参数集合 | ||
| 24 | + var params = {}; | ||
| 25 | + // 搜索字段名称 | ||
| 26 | + var name; | ||
| 27 | + // 遍历cells数组 | ||
| 28 | + $.each(cells, function(i, cell){ | ||
| 29 | + // 获取第i列的input或者select集合 | ||
| 30 | + var items = $('input,select', cell); | ||
| 31 | + // 遍历items集合 | ||
| 32 | + for(var j = 0, item; item = items[j++];){ | ||
| 33 | + // 获取字段名称 | ||
| 34 | + name = $(item).attr('name'); | ||
| 35 | + if(name){ | ||
| 36 | + // 赋取相对应的值 | ||
| 37 | + params[name] = $(item).val(); | ||
| 38 | + } | ||
| 39 | + } | ||
| 40 | + }); | ||
| 41 | + if(params.parkName_like=='请选择...') | ||
| 42 | + params.parkName_like = ''; | ||
| 43 | + else | ||
| 44 | + params.parkName_like = params.parkName_like.split('_')[0]; | ||
| 45 | + return params; | ||
| 46 | + } | ||
| 47 | + | ||
| 48 | + /** | ||
| 49 | + * 表格数据分页加载事件 | ||
| 50 | + * | ||
| 51 | + * ------@param : 查询参数 | ||
| 52 | + * | ||
| 53 | + * ------@isPon : 是否重新分页 | ||
| 54 | + * | ||
| 55 | + */ | ||
| 56 | + function loadTableDate(param,isPon){ | ||
| 57 | + // 搜索参数 | ||
| 58 | + var params = {}; | ||
| 59 | + if(param) { | ||
| 60 | + params = param; | ||
| 61 | + } | ||
| 62 | + // 排序(按更新时间) | ||
| 63 | + params['order'] = 'id'; | ||
| 64 | + // 记录当前页数 | ||
| 65 | + params['page'] = page; | ||
| 66 | + // 弹出正在加载层 | ||
| 67 | + var i = layer.load(2); | ||
| 68 | + | ||
| 69 | + // 异步请求获取表格数据 | ||
| 70 | + $.get('/regionLineCar',params,function(result){ | ||
| 71 | + // 添加序号 | ||
| 72 | + result.content.page = page; | ||
| 73 | + $.each(result.content, function(i, obj) { | ||
| 74 | + obj.createDate = moment(obj.createDate).format("YYYY-MM-DD"); | ||
| 75 | + }); | ||
| 76 | + // 把数据填充到模版中 | ||
| 77 | + var tbodyHtml = template('region_line_car_list_table_temp',{list:result.content}); | ||
| 78 | + | ||
| 79 | + | ||
| 80 | + $('#datatable_region tbody').html(tbodyHtml); | ||
| 81 | + // 是重新分页且返回数据长度大于0 | ||
| 82 | + if(isPon && result.content.length > 0){ | ||
| 83 | + // 重新分页 | ||
| 84 | + initPag = true; | ||
| 85 | + // 分页栏 | ||
| 86 | + showPagination(result); | ||
| 87 | + } | ||
| 88 | + // 关闭弹出加载层 | ||
| 89 | + layer.close(i); | ||
| 90 | + }); | ||
| 91 | + | ||
| 92 | + } | ||
| 93 | + | ||
| 94 | + /** 分页栏组件 */ | ||
| 95 | + function showPagination(data){ | ||
| 96 | + // 分页组件 | ||
| 97 | + $('#pagination').jqPaginator({ | ||
| 98 | + // 总页数 | ||
| 99 | + totalPages: data.totalPages, | ||
| 100 | + // 中间显示页数 | ||
| 101 | + visiblePages: 6, | ||
| 102 | + // 当前页 | ||
| 103 | + currentPage: page + 1, | ||
| 104 | + first: '<li class="first"><a href="javascript:void(0);">首页<\/a><\/li>', | ||
| 105 | + prev: '<li class="prev"><a href="javascript:void(0);">上一页<\/a><\/li>', | ||
| 106 | + next: '<li class="next"><a href="javascript:void(0);">下一页<\/a><\/li>', | ||
| 107 | + last: '<li class="last"><a href="javascript:void(0);">尾页<\/a><\/li>', | ||
| 108 | + page: '<li class="page"><a href="javascript:void(0);">{{page}}<\/a><\/li>', | ||
| 109 | + onPageChange: function (num, type) { | ||
| 110 | + if(initPag){ | ||
| 111 | + initPag = false; | ||
| 112 | + return; | ||
| 113 | + } | ||
| 114 | + var pData = getParams(); | ||
| 115 | + page = num - 1; | ||
| 116 | + loadTableDate(pData, false); | ||
| 117 | + } | ||
| 118 | + }); | ||
| 119 | + } | ||
| 120 | +})(); | ||
| 0 | \ No newline at end of file | 121 | \ No newline at end of file |
src/main/resources/static/pages/base/region_line_car/list.html
0 → 100644
| 1 | +<div class="page-head"> | ||
| 2 | + <div class="page-title"> | ||
| 3 | + <h1>区域信息</h1> | ||
| 4 | + </div> | ||
| 5 | +</div> | ||
| 6 | + | ||
| 7 | +<ul class="page-breadcrumb breadcrumb"> | ||
| 8 | + <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | ||
| 9 | + <li><span class="active">基础信息</span> <i class="fa fa-circle"></i></li> | ||
| 10 | + <li><span class="active">区域信息</span></li> | ||
| 11 | +</ul> | ||
| 12 | + | ||
| 13 | +<div class="row"> | ||
| 14 | + <div class="col-md-12"> | ||
| 15 | + <div class="portlet light porttlet-fit bordered"> | ||
| 16 | + <div class="portlet-title"> | ||
| 17 | + <div class="caption"> | ||
| 18 | + <i class="fa fa-info-circle font-dark"></i> | ||
| 19 | + <span class="caption-subject font-dark sbold uppercase">区域信息</span> | ||
| 20 | + </div> | ||
| 21 | + <div class="actions"> | ||
| 22 | + <div class="btn-group btn-group-devided" data-toggle="buttons"> | ||
| 23 | + <a class="btn btn-circle blue" href="add.html" data-pjax><i class="fa fa-plus"></i> 添加线路车辆</a> | ||
| 24 | + </div> | ||
| 25 | + </div> | ||
| 26 | + </div> | ||
| 27 | + <div class="portlet-body"> | ||
| 28 | + <div class="table-container" style="margin-top: 10px"> | ||
| 29 | + <table class="table table-striped table-bordered table-hover table-checkable" id="datatable_region"> | ||
| 30 | + <thead> | ||
| 31 | + <tr role="row" class="heading"> | ||
| 32 | + <th width="3%">序号</th> | ||
| 33 | + <th width="12%">区域</th> | ||
| 34 | + <th width="6%">线路</th> | ||
| 35 | + <th width="10%">车牌号</th> | ||
| 36 | + <th width="10%">日期</th> | ||
| 37 | + <th width="10%">操作</th> | ||
| 38 | + </tr> | ||
| 39 | + <tr role="row" class="filter"> | ||
| 40 | + <td>#</td> | ||
| 41 | + <td>#</td> | ||
| 42 | + <td>#</td> | ||
| 43 | + <td>#</td> | ||
| 44 | + <td>#</td> | ||
| 45 | + <td> | ||
| 46 | + <button class="btn btn-sm green btn-outline filter-submit margin-bottom" > | ||
| 47 | + <i class="fa fa-search"></i> 搜索 | ||
| 48 | + </button> | ||
| 49 | + | ||
| 50 | + <button class="btn btn-sm red btn-outline filter-cancel"> | ||
| 51 | + <i class="fa fa-times"></i> 重置 | ||
| 52 | + </button> | ||
| 53 | + </td> | ||
| 54 | + </tr> | ||
| 55 | + </thead> | ||
| 56 | + <tbody></tbody> | ||
| 57 | + </table> | ||
| 58 | + <div style="text-align: right;"> | ||
| 59 | + <ul id="pagination" class="pagination"></ul> | ||
| 60 | + </div> | ||
| 61 | + </div> | ||
| 62 | + </div> | ||
| 63 | + </div> | ||
| 64 | + </div> | ||
| 65 | +</div> | ||
| 66 | + | ||
| 67 | +<script type="text/html" id="region_line_car_list_table_temp"> | ||
| 68 | + {{each list as obj i }} | ||
| 69 | + <tr> | ||
| 70 | + <td style="vertical-align: middle;"> | ||
| 71 | + {{(list.page*10)+(i+1)}} | ||
| 72 | + </td> | ||
| 73 | + <td> | ||
| 74 | + {{obj.region.name}} | ||
| 75 | + </td> | ||
| 76 | + <td> | ||
| 77 | + {{obj.lineName}} | ||
| 78 | + </td> | ||
| 79 | + | ||
| 80 | + <td> | ||
| 81 | + {{obj.clZbh}} | ||
| 82 | + </td> | ||
| 83 | + <td> | ||
| 84 | + {{obj.createDate}} | ||
| 85 | + </td> | ||
| 86 | + | ||
| 87 | + <td> | ||
| 88 | + <a href="edit.html?no={{obj.id}}" class="btn default blue-stripe btn-sm" data-pjax> 修改 </a> | ||
| 89 | + {{if obj.destroy==1}} | ||
| 90 | + <a class="ct_base_line_delete_link" data-id="{{obj.id}}" data-name="{{obj.name}}"> 删除 </a> | ||
| 91 | + {{/if}} | ||
| 92 | + </td> | ||
| 93 | + </tr> | ||
| 94 | + {{/each}} | ||
| 95 | + {{if list.length == 0}} | ||
| 96 | + <tr> | ||
| 97 | + <td colspan=10><h6 class="muted">没有找到相关数据</h6></td> | ||
| 98 | + </tr> | ||
| 99 | + {{/if}} | ||
| 100 | +</script> | ||
| 101 | +<script src="/pages/base/region_line_car/js/region_list.js"></script> | ||
| 0 | \ No newline at end of file | 102 | \ No newline at end of file |
src/main/resources/static/pages/base/stationroute/js/routes-operation.js
| @@ -489,7 +489,7 @@ var RoutesOperation = (function () { | @@ -489,7 +489,7 @@ var RoutesOperation = (function () { | ||
| 489 | '<span class="help-block" >到站时间:' + stationRoute.toTime + ' 分钟</span>' + | 489 | '<span class="help-block" >到站时间:' + stationRoute.toTime + ' 分钟</span>' + |
| 490 | '<span class="help-block" >到站距离:' + stationRoute.distances + ' 公里</span>' + | 490 | '<span class="help-block" >到站距离:' + stationRoute.distances + ' 公里</span>' + |
| 491 | '<span class="help-block" >缓冲区形状:' + (shapes == 'r' ? '圆形' : '多边形') + '</span>' + | 491 | '<span class="help-block" >缓冲区形状:' + (shapes == 'r' ? '圆形' : '多边形') + '</span>' + |
| 492 | - (shapes=="r" ? ("<span class='help-block' >半径  :" + stationRoute.radius + "</span>") : " ")+ | 492 | + (shapes=="r" ? ("<span class='help-block' >半径  :" + stationRoute.radius + " 米</span>") : " ")+ |
| 493 | '<span class="help-block" >版本号  :' + stationRoute.versions + '</span>'; | 493 | '<span class="help-block" >版本号  :' + stationRoute.versions + '</span>'; |
| 494 | 494 | ||
| 495 | if(status > 0){ | 495 | if(status > 0){ |
src/main/resources/static/pages/control/line/child_pages/deviceReport.html
| @@ -91,7 +91,7 @@ | @@ -91,7 +91,7 @@ | ||
| 91 | ,$car = $('#deviceReportPanel #carSelect') | 91 | ,$car = $('#deviceReportPanel #carSelect') |
| 92 | ,$table = $('#deviceReportPanel table'); | 92 | ,$table = $('#deviceReportPanel table'); |
| 93 | 93 | ||
| 94 | - var reqCodeMap = {0xA1: '请求恢复运营', 0xA2: '申请调档', 0xA3: '出场请求', 0xA5: '进场请求', 0xA7: '加油请求', 0x50: '车辆故障', 0x70: '路阻报告', 0x60: '事故报告', 0x11: '扣证纠纷', 0x12 : '报警'}; | 94 | + var reqCodeMap = {0xA1: '请求恢复运营', 0xA2: '申请调档', 0xA3: '出场请求', 0xA5: '进场请求', 0xA7: '加油请求', 0x50: '车辆故障', 0x70: '路阻报告', 0x60: '事故报告', 0x11: '扣证纠纷', 0x12 : '报警', 0x21: '单车有人伤', 0x22: '单车无人伤', 0x23: '双车有人伤', 0x24: '双车无人伤'}; |
| 95 | 95 | ||
| 96 | var lineNameMap = JSON.parse(storage.getItem('lineIds')); | 96 | var lineNameMap = JSON.parse(storage.getItem('lineIds')); |
| 97 | //初始加载数据 | 97 | //初始加载数据 |
src/main/resources/static/pages/control/line/index.html
| @@ -281,7 +281,7 @@ $.get('/user/currentUser', function(user){ | @@ -281,7 +281,7 @@ $.get('/user/currentUser', function(user){ | ||
| 281 | //打个标记 | 281 | //打个标记 |
| 282 | storage.setItem('real_control_flag', 1); | 282 | storage.setItem('real_control_flag', 1); |
| 283 | 283 | ||
| 284 | -var reqCodeMap = {0xA1: '请求恢复运营', 0xA2: '申请调档', 0xA3: '出场请求', 0xA5: '进场请求', 0xA7: '加油请求', 0x50: '车辆故障', 0x70: '路阻报告', 0x60: '事故报告', 0x11: '扣证纠纷', 0x12 : '报警'}; | 284 | +var reqCodeMap = {0xA1: '请求恢复运营', 0xA2: '申请调档', 0xA3: '出场请求', 0xA5: '进场请求', 0xA7: '加油请求', 0x50: '车辆故障', 0x70: '路阻报告', 0x60: '事故报告', 0x11: '扣证纠纷', 0x12 : '报警', 0x21: '单车有人伤', 0x22: '单车无人伤', 0x23: '双车有人伤', 0x24: '双车无人伤'}; |
| 285 | 285 | ||
| 286 | function _fadeOut($that){ | 286 | function _fadeOut($that){ |
| 287 | $that.fadeOut('normal', function(){ | 287 | $that.fadeOut('normal', function(){ |
src/main/resources/static/pages/electricity/cdl/cdlAdd.html
| @@ -6,7 +6,7 @@ | @@ -6,7 +6,7 @@ | ||
| 6 | 6 | ||
| 7 | <ul class="page-breadcrumb breadcrumb"> | 7 | <ul class="page-breadcrumb breadcrumb"> |
| 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> |
| 9 | - <li><span class="active">用油管理</span> <i class="fa fa-circle"></i></li> | 9 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> |
| 10 | <li><a href="cylList.html" data-pjax>车辆存电</a> <i class="fa fa-circle"></i></li> | 10 | <li><a href="cylList.html" data-pjax>车辆存电</a> <i class="fa fa-circle"></i></li> |
| 11 | <li><span class="active">添加存电</span></li> | 11 | <li><span class="active">添加存电</span></li> |
| 12 | </ul> | 12 | </ul> |
src/main/resources/static/pages/electricity/cdl/cdlList.html
| @@ -6,7 +6,7 @@ | @@ -6,7 +6,7 @@ | ||
| 6 | 6 | ||
| 7 | <ul class="page-breadcrumb breadcrumb"> | 7 | <ul class="page-breadcrumb breadcrumb"> |
| 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> |
| 9 | - <li><span class="active">用点管理</span> <i class="fa fa-circle"></i></li> | 9 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> |
| 10 | <li><span class="active">车辆存电</span></li> | 10 | <li><span class="active">车辆存电</span></li> |
| 11 | </ul> | 11 | </ul> |
| 12 | 12 |
src/main/resources/static/pages/electricity/connector/edit.html
0 → 100644
| 1 | +<style type="text/css"> | ||
| 2 | + .table-bordered { | ||
| 3 | + border: 1px solid; } | ||
| 4 | + .table-bordered > thead > tr > th, | ||
| 5 | + .table-bordered > thead > tr > td, | ||
| 6 | + .table-bordered > tbody > tr > th, | ||
| 7 | + .table-bordered > tbody > tr > td, | ||
| 8 | + .table-bordered > tfoot > tr > th, | ||
| 9 | + .table-bordered > tfoot > tr > td { | ||
| 10 | + border: 1px solid; } | ||
| 11 | + .table-bordered > thead > tr > th, | ||
| 12 | + .table-bordered > thead > tr > td { | ||
| 13 | + border-bottom-width: 2px; } | ||
| 14 | + | ||
| 15 | + .table > tbody + tbody { | ||
| 16 | + border-top: 1px solid; } | ||
| 17 | + | ||
| 18 | + .jdlConnectorValueTd { | ||
| 19 | + width: 450px; | ||
| 20 | + } | ||
| 21 | + .jdlConnectorValueInput { | ||
| 22 | + width: 320px; | ||
| 23 | + } | ||
| 24 | +</style> | ||
| 25 | + | ||
| 26 | +<div id="jdlConnectorEdit"> | ||
| 27 | + <div class="col-md-12"> | ||
| 28 | +<!-- <div class="portlet light porttlet-fit bordered"> --> | ||
| 29 | + <div class="portlet-body"> | ||
| 30 | + <div class="table-container" style="margin-top: 10px;width: 620px;height: 280px;overflow:auto;"> | ||
| 31 | + <table class="table table-bordered table-hover table-checkable" id="forms_2"> | ||
| 32 | + <thead> | ||
| 33 | + </thead> | ||
| 34 | + | ||
| 35 | + <tbody id="jdlConnector_tbody"> | ||
| 36 | + | ||
| 37 | + </tbody> | ||
| 38 | + </table> | ||
| 39 | + </div> | ||
| 40 | + </div> | ||
| 41 | +<!-- </div> --> | ||
| 42 | + </div> | ||
| 43 | +</div> | ||
| 44 | +<script src="/pages/mforms/singledatas/jquery.table2excel.min.js"></script> | ||
| 45 | +<script> | ||
| 46 | + $(function(){ | ||
| 47 | + // 关闭左侧栏 | ||
| 48 | + if (!$('body').hasClass('page-sidebar-closed')) | ||
| 49 | + $('.menu-toggler.sidebar-toggler').click(); | ||
| 50 | + var date = ""; | ||
| 51 | + var nbbm = ""; | ||
| 52 | + $("#jdlConnectorEdit").on('init', function (e, id) { | ||
| 53 | + type = id.split(",")[1]; // 先取type,防止报错 | ||
| 54 | + id = id.split(",")[0]; | ||
| 55 | + var i = layer.load(2); | ||
| 56 | + if(type == "add"){ | ||
| 57 | + var jdlConnectorEditAdd = template('jdlConnector_tbody_add',{obj:{}}); | ||
| 58 | + $('#forms_2 tbody').html(jdlConnectorEditAdd); | ||
| 59 | + layer.close(i); | ||
| 60 | + } else if(type == "upd"){ | ||
| 61 | + $get('/jdl/queryJdlConnectorById',{id:id,type:'query'},function(result){ | ||
| 62 | + layer.close(i); | ||
| 63 | + $.each(result, function(i, e){ | ||
| 64 | +// console.log(e); | ||
| 65 | + if(e.origin == 1){ | ||
| 66 | + e.originName = "导入"; | ||
| 67 | + } else { | ||
| 68 | + e.originName = "接口"; | ||
| 69 | + } | ||
| 70 | + }); | ||
| 71 | + | ||
| 72 | + var jdlConnectorEditUpd = template('jdlConnector_tbody_upd',{obj:result}); | ||
| 73 | + $('#forms_2 tbody').html(jdlConnectorEditUpd); | ||
| 74 | + }); | ||
| 75 | + } | ||
| 76 | + }) | ||
| 77 | + | ||
| 78 | + }); | ||
| 79 | + | ||
| 80 | + function formatInputNumber(e){ | ||
| 81 | + // 获取输入值 | ||
| 82 | + var value = e.target.value; | ||
| 83 | + var v = value.replace(/[^0-9.]/g, ''); | ||
| 84 | + if('\.' == v.charAt(0)){ | ||
| 85 | + v = '0' + v; | ||
| 86 | + } | ||
| 87 | + if(v.indexOf('\.') > 0){ | ||
| 88 | + var split = v.split('\.'); | ||
| 89 | + if(split[1].length > 0){ | ||
| 90 | + v = split[0] + '\.' + (split[1].substring(0, 2)); | ||
| 91 | + } else { | ||
| 92 | + v = split[0] + '\.0'; | ||
| 93 | + } | ||
| 94 | + } | ||
| 95 | + // 更新输入框的值 | ||
| 96 | + e.target.value = v; | ||
| 97 | + } | ||
| 98 | +</script> | ||
| 99 | +<script type="text/html" id="jdlConnector_tbody_add"> | ||
| 100 | + <tr> | ||
| 101 | + <td>充电枪名称:</td> | ||
| 102 | + <td><input type="text" class="jdlConnectorValueInput" name="connectorName"/></td> | ||
| 103 | + </tr> | ||
| 104 | + <tr> | ||
| 105 | + <td>充电枪编号:</td> | ||
| 106 | + <td><input type="text" class="jdlConnectorValueInput" name="connectorId"/></td> | ||
| 107 | + </tr> | ||
| 108 | + <tr> | ||
| 109 | + <td>站名:</td> | ||
| 110 | + <td><input type="text" class="jdlConnectorValueInput" name="stationName"/></td> | ||
| 111 | + </tr> | ||
| 112 | +</script> | ||
| 113 | +<script type="text/html" id="jdlConnector_tbody_upd"> | ||
| 114 | + <tr> | ||
| 115 | + <td>充电枪名称:<input type="hidden" name="id" value="{{obj.id}}"/></td> | ||
| 116 | + <td class="jdlConnectorValueTd"> | ||
| 117 | + <input type="text" class="jdlConnectorValueInput" name="connectorName" value="{{obj.connectorName}}"/> | ||
| 118 | + </td> | ||
| 119 | + </tr> | ||
| 120 | + <tr> | ||
| 121 | + <td>充电枪编号:</td> | ||
| 122 | + <td class="jdlConnectorValueTd"> | ||
| 123 | + <input type="text" class="jdlConnectorValueInput" name="connectorId" value="{{obj.connectorId}}"/> | ||
| 124 | + </td> | ||
| 125 | + </tr> | ||
| 126 | + <tr> | ||
| 127 | + <td>站名:</td> | ||
| 128 | + <td class="jdlConnectorValueTd"> | ||
| 129 | + <input type="text" class="jdlConnectorValueInput" name="stationName" value="{{obj.stationName}}"/> | ||
| 130 | + </td> | ||
| 131 | + </tr> | ||
| 132 | +</script> | ||
| 0 | \ No newline at end of file | 133 | \ No newline at end of file |
src/main/resources/static/pages/electricity/connector/list.html
0 → 100644
| 1 | +<style> | ||
| 2 | +.blue{ | ||
| 3 | + background-color: #87CEFF | ||
| 4 | +} | ||
| 5 | +</style> | ||
| 6 | +<div class="page-head"> | ||
| 7 | + <div class="page-title"> | ||
| 8 | + <h1>充电枪自编号</h1> | ||
| 9 | + </div> | ||
| 10 | +</div> | ||
| 11 | +<ul class="page-breadcrumb breadcrumb"> | ||
| 12 | + <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | ||
| 13 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> | ||
| 14 | + <li><span class="active">充电枪自编号</span></li> | ||
| 15 | +</ul> | ||
| 16 | + | ||
| 17 | +<div class="row" id="jdlConnector_list"> | ||
| 18 | + <div class="col-md-12"> | ||
| 19 | + <!-- Begin: life time stats --> | ||
| 20 | + <div class="portlet light portlet-fit portlet-datatable bordered"> | ||
| 21 | + <div class="portlet-title"> | ||
| 22 | + <div class="caption"> | ||
| 23 | + <i class="fa fa-fire-extinguisher"></i> <span | ||
| 24 | + class="caption-subject font-dark sbold uppercase">充电枪自编号</span> | ||
| 25 | + </div> | ||
| 26 | + <div class="actions"> | ||
| 27 | + <div class="btn-group btn-group-devided btn-Connector-add" data-toggle="buttons"> | ||
| 28 | + <a class="btn btn-circle blue"><i class="fa fa-plus"></i> 新建充电枪</a> | ||
| 29 | + </div> | ||
| 30 | + </div> | ||
| 31 | + </div> | ||
| 32 | + <div class="portlet-body"> | ||
| 33 | + <div class="table-container" style="margin-top: 0px"> | ||
| 34 | + <table | ||
| 35 | + class="table table-striped table-bordered table-hover table-checkable" | ||
| 36 | + id="datatable_dlb"> | ||
| 37 | + <thead> | ||
| 38 | + <tr role="row" class="filter"> | ||
| 39 | + <td colspan="1">充电枪名称:</td> | ||
| 40 | + <td colspan="2"> | ||
| 41 | + <input type="text" style="width: 160px" name="connectorName" id="connectorName"/> | ||
| 42 | + </td> | ||
| 43 | + <td colspan="1">充电枪编号:</td> | ||
| 44 | + <td colspan="1"> | ||
| 45 | + <input type="text" style="width: 160px" name="connectorId" id="connectorId"/> | ||
| 46 | + </td> | ||
| 47 | + <td colspan="1">充电站:</td> | ||
| 48 | + <td colspan="1"> | ||
| 49 | + <input type="text" style="width: 160px" name="stationName" id="stationName"/> | ||
| 50 | + </td> | ||
| 51 | + <td width="16%"> | ||
| 52 | + <button class="btn btn-sm green btn-outline filter-submit margin-bottom" style="margin-right:0px"> | ||
| 53 | + <i class="fa fa-search"></i> 搜索 | ||
| 54 | + </button> | ||
| 55 | + <button class="btn btn-sm red btn-outline filter-cancel" style="margin-right:0px"> | ||
| 56 | + <i class="fa fa-times"></i> 重置 | ||
| 57 | + </button> | ||
| 58 | + </td> | ||
| 59 | + </tr> | ||
| 60 | + <tr role="row" class="heading"> | ||
| 61 | + <th>#</th> | ||
| 62 | + <th colspan="2">充电枪名称</th> | ||
| 63 | + <th colspan="2">充电枪编号</th> | ||
| 64 | + <th colspan="2">充电站</th> | ||
| 65 | + <td colspan="1">操作</td> | ||
| 66 | + </tr> | ||
| 67 | + </thead> | ||
| 68 | + <tbody></tbody> | ||
| 69 | + </table> | ||
| 70 | + <div style="text-align: right;"> | ||
| 71 | + <ul id="pagination" class="pagination"></ul> | ||
| 72 | + </div> | ||
| 73 | + </div> | ||
| 74 | + </div> | ||
| 75 | + <div class="portlet-body"> | ||
| 76 | + <div id="modules_tree"></div> | ||
| 77 | + </div> | ||
| 78 | + </div> | ||
| 79 | + </div> | ||
| 80 | +</div> | ||
| 81 | + | ||
| 82 | + | ||
| 83 | +<script src="/assets/js/ajaxfileupload/ajaxfileupload.js"></script> | ||
| 84 | +<script> | ||
| 85 | + $(function () { | ||
| 86 | + | ||
| 87 | + // 关闭左侧栏 | ||
| 88 | + if (!$('body').hasClass('page-sidebar-closed')) | ||
| 89 | + $('.menu-toggler.sidebar-toggler').click(); | ||
| 90 | + | ||
| 91 | + $("#rq").datetimepicker({ | ||
| 92 | + format: 'YYYY-MM-DD', | ||
| 93 | + locale: 'zh-cn' | ||
| 94 | + }); | ||
| 95 | + var d = new Date(); | ||
| 96 | +// d.setTime(d.getTime() - 1*1000*60*60*24); | ||
| 97 | + d.setTime(d.getTime()); | ||
| 98 | + var year = d.getFullYear(); | ||
| 99 | + var month = d.getMonth() + 1; | ||
| 100 | + var day = d.getDate(); | ||
| 101 | + if(month < 10) | ||
| 102 | + month = "0" + month; | ||
| 103 | + if(day < 10) | ||
| 104 | + day = "0" + day; | ||
| 105 | + $("#rq").val(year + "-" + month + "-" + day); | ||
| 106 | + | ||
| 107 | + var page = 0, initPagination; | ||
| 108 | + var icheckOptions = { | ||
| 109 | + radioClass: 'iradio_square-blue icheck', | ||
| 110 | + increaseArea: '20%' | ||
| 111 | + } | ||
| 112 | + | ||
| 113 | + //重置 | ||
| 114 | + $('tr.filter .filter-cancel').on('click', function () { | ||
| 115 | + $('tr.filter input, select').val('').change(); | ||
| 116 | + }); | ||
| 117 | + | ||
| 118 | + //提交 | ||
| 119 | + $('tr.filter .filter-submit').on('click', function () { | ||
| 120 | + | ||
| 121 | + var params = getParams(); | ||
| 122 | + | ||
| 123 | + page = 0; | ||
| 124 | + jsDoQuery(params, true); | ||
| 125 | + }); | ||
| 126 | + | ||
| 127 | + | ||
| 128 | + $.get('/user/companyData', function(result){ | ||
| 129 | + obj = result; | ||
| 130 | + var options=""; | ||
| 131 | +// = '<option value="">请选择</option>'; | ||
| 132 | + for(var i = 0; i < obj.length; i++){ | ||
| 133 | + options += '<option value="'+obj[i].companyCode+'">'+obj[i].companyName+'</option>'; | ||
| 134 | +// setFgsqx(obj[i].companyCode); | ||
| 135 | + } | ||
| 136 | + $('#gsbm').html(options); | ||
| 137 | + updateCompany(); | ||
| 138 | + }); | ||
| 139 | + | ||
| 140 | + $("#gsbm").on("change",updateCompany); | ||
| 141 | + function updateCompany(){ | ||
| 142 | + var company = $('#gsbm').val(); | ||
| 143 | + var options =""; | ||
| 144 | +// = '<option value="">请选择</option>'; | ||
| 145 | + for(var i = 0; i < obj.length; i++){ | ||
| 146 | + if(obj[i].companyCode == company){ | ||
| 147 | + var children = obj[i].children; | ||
| 148 | + for(var j = 0; j < children.length; j++){ | ||
| 149 | + options += '<option value="'+children[j].code+'">'+children[j].name+'</option>'; | ||
| 150 | + } | ||
| 151 | + } | ||
| 152 | + } | ||
| 153 | + $('#fgsbm').html(options); | ||
| 154 | + } | ||
| 155 | + /* | ||
| 156 | + * 获取数据 p: 要提交的参数, pagination: 是否重新分页 | ||
| 157 | + */ | ||
| 158 | + function jsDoQuery(p, pagination) { | ||
| 159 | + var params = {}; | ||
| 160 | + if (p) | ||
| 161 | + params = p; | ||
| 162 | + params['page'] = page; | ||
| 163 | + params['connectorName'] = $("#connectorName").val(); | ||
| 164 | + params['connectorId'] = $("#connectorId").val(); | ||
| 165 | + params['stationName'] = $("#stationName").val(); | ||
| 166 | + | ||
| 167 | + var j = layer.load(2); | ||
| 168 | + $get('/jdl/queryJdlConnector', params, function (data) { | ||
| 169 | + var bodyHtml = template('jdlConnectorList', {list:data}); | ||
| 170 | + $('#datatable_dlb tbody').html(bodyHtml); | ||
| 171 | + | ||
| 172 | + layer.close(j); | ||
| 173 | + | ||
| 174 | + $('.btn-Connector-upd').on('click', openConnectoraUpd); | ||
| 175 | + $('.btn-Connector-del').on('click', openReceptionBatchDataDel); | ||
| 176 | + }); | ||
| 177 | + } | ||
| 178 | + | ||
| 179 | + $('.btn-Connector-add').on('click', function(){ | ||
| 180 | + $.get('/pages/electricity/connector/edit.html', function (content) { | ||
| 181 | + layer.open({ | ||
| 182 | + type: 1, | ||
| 183 | + area: ['650px', '400px'], | ||
| 184 | + content: content, | ||
| 185 | + title: '新建充电枪', | ||
| 186 | + shift: 5, | ||
| 187 | + scrollbar: false, | ||
| 188 | + success: function () { | ||
| 189 | + $('#jdlConnectorEdit').trigger('init', "0,add"); | ||
| 190 | + }, | ||
| 191 | + btn:["保存", "取消"], | ||
| 192 | + btn1: function(index, layero){ | ||
| 193 | + layer.msg('操作中...', {icon: 16, shade: 0.31}); | ||
| 194 | + var connectorName = "", connectorId = "", stationName = ""; | ||
| 195 | + $('#jdlConnector_tbody input').each(function(i, e){ | ||
| 196 | + var obj = $(e); | ||
| 197 | + if("connectorName" == obj.attr("name")){ | ||
| 198 | + connectorName = obj.val(); | ||
| 199 | + } else if("connectorId" == obj.attr("name")){ | ||
| 200 | + connectorId = obj.val(); | ||
| 201 | + } else if("stationName" == obj.attr("name")){ | ||
| 202 | + stationName = obj.val(); | ||
| 203 | + } | ||
| 204 | + }); | ||
| 205 | + if(connectorName == null || connectorName.trim().length == 0 | ||
| 206 | + || connectorId == null || connectorId.trim().length == 0 | ||
| 207 | + || stationName == null || stationName.trim().length == 0){ | ||
| 208 | + layer.msg("请填写充电枪名称、编号、充电站信息"); | ||
| 209 | + return; | ||
| 210 | + } | ||
| 211 | + $get('/jdl/queryJdlConnector',{connectorId:connectorId,type:'query'},function(result){ | ||
| 212 | + if(result.length > 0){ | ||
| 213 | + layer.msg("充电枪编号已被使用,请重新输入编号"); | ||
| 214 | + } else { | ||
| 215 | + $post('/jdl/addJdlConnector', {connectorName:connectorName,connectorId:connectorId,stationName:stationName}, function (rs) { | ||
| 216 | + if(rs.status && rs.status == "SUCCESS"){ | ||
| 217 | + layer.msg('新建成功。'); | ||
| 218 | + $('.filter-submit.margin-bottom').trigger('click'); | ||
| 219 | + layer.close(index); | ||
| 220 | + } else { | ||
| 221 | + layer.msg(rs.msg); | ||
| 222 | + } | ||
| 223 | + }); | ||
| 224 | + } | ||
| 225 | + }); | ||
| 226 | + | ||
| 227 | + } | ||
| 228 | + }); | ||
| 229 | + }); | ||
| 230 | + }); | ||
| 231 | + | ||
| 232 | + function openConnectoraUpd(){ | ||
| 233 | + var id = $(this).data('id'); | ||
| 234 | + id += ",upd"; | ||
| 235 | + $.get('/pages/electricity/connector/edit.html', function (content) { | ||
| 236 | + layer.open({ | ||
| 237 | + type: 1, | ||
| 238 | + area: ['650px', '400px'], | ||
| 239 | + content: content, | ||
| 240 | + title: '充电枪修改', | ||
| 241 | + shift: 5, | ||
| 242 | + scrollbar: false, | ||
| 243 | + success: function () { | ||
| 244 | + $('#jdlConnectorEdit').trigger('init', id); | ||
| 245 | + }, | ||
| 246 | + btn:["保存", "取消"], | ||
| 247 | + btn1: function(index, layero){ | ||
| 248 | + layer.msg('操作中...', {icon: 16, shade: 0.31}); | ||
| 249 | + var id = "", connectorName = "", connectorId = "", stationName = ""; | ||
| 250 | + $('#jdlConnector_tbody input').each(function(i, e){ | ||
| 251 | + var obj = $(e); | ||
| 252 | + if("id" == obj.attr("name")){ | ||
| 253 | + id = obj.val(); | ||
| 254 | + } else if("connectorName" == obj.attr("name")){ | ||
| 255 | + connectorName = obj.val(); | ||
| 256 | + } else if("connectorId" == obj.attr("name")){ | ||
| 257 | + connectorId = obj.val(); | ||
| 258 | + } else if("stationName" == obj.attr("name")){ | ||
| 259 | + stationName = obj.val(); | ||
| 260 | + } | ||
| 261 | + }); | ||
| 262 | + if(connectorName == null || connectorName.trim().length == 0 | ||
| 263 | + || connectorId == null || connectorId.trim().length == 0 | ||
| 264 | + || stationName == null || stationName.trim().length == 0){ | ||
| 265 | + layer.msg("请填写充电枪名称、编号、充电站信息"); | ||
| 266 | + return; | ||
| 267 | + } | ||
| 268 | + $get('/jdl/queryJdlConnector',{connectorId:connectorId,type:'query'},function(result){ | ||
| 269 | + if(result.length > 0){ | ||
| 270 | + layer.msg("充电枪编号已被使用,请重新输入编号"); | ||
| 271 | + } else { | ||
| 272 | + $post('/jdl/updateJdlConnector', {id:id,connectorName:connectorName,connectorId:connectorId,stationName:stationName}, function (rs) { | ||
| 273 | + if(rs.status && rs.status == "SUCCESS"){ | ||
| 274 | + layer.msg('修改成功。'); | ||
| 275 | + $('.filter-submit.margin-bottom').trigger('click'); | ||
| 276 | + layer.close(index); | ||
| 277 | + } else { | ||
| 278 | + layer.msg(rs.msg); | ||
| 279 | + } | ||
| 280 | + }); | ||
| 281 | + } | ||
| 282 | + }); | ||
| 283 | + | ||
| 284 | + } | ||
| 285 | + }); | ||
| 286 | + }); | ||
| 287 | + } | ||
| 288 | + | ||
| 289 | + function openReceptionBatchDataDel(){ | ||
| 290 | + var id = $(this).data('id'); | ||
| 291 | + layer.confirm('你确定要删除充电量吗?', { | ||
| 292 | + btn: ['确定删除','取消'] //按钮 | ||
| 293 | + }, function(){ | ||
| 294 | + layer.msg('操作中...', {icon: 16,shade: 0.01}); | ||
| 295 | + $post('/jdl/deleteJdlConnector', {id:id}, function (rs) { | ||
| 296 | + layer.msg('删除成功!'); | ||
| 297 | + $('.filter-submit.margin-bottom').trigger('click'); | ||
| 298 | + }); | ||
| 299 | + }); | ||
| 300 | + } | ||
| 301 | + | ||
| 302 | + | ||
| 303 | + | ||
| 304 | + function getParams(){ | ||
| 305 | + var cells = $('tr.filter')[0].cells | ||
| 306 | + , params = {} | ||
| 307 | + , name; | ||
| 308 | + $.each(cells, function (i, cell) { | ||
| 309 | + var items = $('input,select', cell); | ||
| 310 | + for (var j = 0, item; item = items[j++];) { | ||
| 311 | + name = $(item).attr('name'); | ||
| 312 | + if (name) { | ||
| 313 | + params[name] = $(item).val(); | ||
| 314 | + } | ||
| 315 | + } | ||
| 316 | + }); | ||
| 317 | + return params; | ||
| 318 | + }; | ||
| 319 | + | ||
| 320 | + }); | ||
| 321 | + | ||
| 322 | +</script> | ||
| 323 | + | ||
| 324 | +<script id="jdlConnectorList" type="text/html"> | ||
| 325 | + {{each list as obj i}} | ||
| 326 | + <tr> | ||
| 327 | + <td style="vertical-align: middle;"> | ||
| 328 | + {{i + 1}} | ||
| 329 | + </td> | ||
| 330 | + <td colspan="2">{{obj.connectorName}}</td> | ||
| 331 | + <td colspan="2">{{obj.connectorId}}</td> | ||
| 332 | + <td colspan="2">{{obj.stationName}}</td> | ||
| 333 | + <td colspan="1"> | ||
| 334 | + <button class="btn blue-madison btn-sm btn-Connector-upd" data-id="{{obj.id}}"> | ||
| 335 | + <i class="fa fa-pencil"></i> 修改 | ||
| 336 | + </button> | ||
| 337 | + <button class="btn btn-danger btn-sm red btn-Connector-del" data-id="{{obj.id}}"> | ||
| 338 | + <i class="fa fa-times"></i> 删除 | ||
| 339 | + </button> | ||
| 340 | + </td> | ||
| 341 | + </tr> | ||
| 342 | + {{/each}} | ||
| 343 | + {{if list.length == 0}} | ||
| 344 | + <tr> | ||
| 345 | + <td colspan=8><h6 class="muted">没有找到相关数据</h6></td> | ||
| 346 | + </tr> | ||
| 347 | + {{/if}} | ||
| 348 | +</script> | ||
| 0 | \ No newline at end of file | 349 | \ No newline at end of file |
src/main/resources/static/pages/electricity/jdl/jdlReception.html
0 → 100644
| 1 | +<style type="text/css"> | ||
| 2 | + .table-bordered { | ||
| 3 | + border: 1px solid; } | ||
| 4 | + .table-bordered > thead > tr > th, | ||
| 5 | + .table-bordered > thead > tr > td, | ||
| 6 | + .table-bordered > tbody > tr > th, | ||
| 7 | + .table-bordered > tbody > tr > td, | ||
| 8 | + .table-bordered > tfoot > tr > th, | ||
| 9 | + .table-bordered > tfoot > tr > td { | ||
| 10 | + border: 1px solid; } | ||
| 11 | + .table-bordered > thead > tr > th, | ||
| 12 | + .table-bordered > thead > tr > td { | ||
| 13 | + border-bottom-width: 2px; } | ||
| 14 | + | ||
| 15 | + .table > tbody + tbody { | ||
| 16 | + border-top: 1px solid; } | ||
| 17 | +</style> | ||
| 18 | + | ||
| 19 | +<!-- <div class="page-head"> --> | ||
| 20 | +<!-- <div class="page-title" style="margin-left: 20px"> --> | ||
| 21 | +<!-- <button id="exportList">数据导出</button> --> | ||
| 22 | +<!-- </div> --> | ||
| 23 | +<!-- </div> --> | ||
| 24 | + | ||
| 25 | +<div class="row" id="jdlReception"> | ||
| 26 | + <div class="col-md-12"> | ||
| 27 | + <div class="portlet light porttlet-fit bordered"> | ||
| 28 | + <div class="portlet-body"> | ||
| 29 | + <div class="table-container" style="margin-top: 10px;overflow:auto;min-width: 600px"> | ||
| 30 | + <table class="table table-bordered table-hover table-checkable" id="forms_2"> | ||
| 31 | + <thead> | ||
| 32 | + <tr> | ||
| 33 | + <td style="min-width: 170px">批次号</td> | ||
| 34 | + <td style="min-width: 170px">枪号</td> | ||
| 35 | + <td>车号</td> | ||
| 36 | + <td>开始时间</td> | ||
| 37 | + <td>结束时间</td> | ||
| 38 | + <td>总计(分钟)</td> | ||
| 39 | + <td>起始电量SOC(%)</td> | ||
| 40 | + <td>结束电量SOC(%)</td> | ||
| 41 | + <td>充电度数</td> | ||
| 42 | + <td>来源</td> | ||
| 43 | + </tr> | ||
| 44 | + </thead> | ||
| 45 | + | ||
| 46 | + <tbody> | ||
| 47 | + | ||
| 48 | + </tbody> | ||
| 49 | + </table> | ||
| 50 | + </div> | ||
| 51 | + </div> | ||
| 52 | + </div> | ||
| 53 | + </div> | ||
| 54 | +</div> | ||
| 55 | +<script src="/pages/mforms/singledatas/jquery.table2excel.min.js"></script> | ||
| 56 | +<script> | ||
| 57 | + $(function(){ | ||
| 58 | + // 关闭左侧栏 | ||
| 59 | + if (!$('body').hasClass('page-sidebar-closed')) | ||
| 60 | + $('.menu-toggler.sidebar-toggler').click(); | ||
| 61 | + var date = ""; | ||
| 62 | + var nbbm = ""; | ||
| 63 | + $("#jdlReception").on('init', function (e, id) { | ||
| 64 | + date = id.split(",")[0]; | ||
| 65 | + nbbm = id.split(",")[1]; | ||
| 66 | + var i = layer.load(2); | ||
| 67 | + $get('/jdl/queryJdlReception',{rq:date,nbbm:nbbm,type:'query'},function(result){ | ||
| 68 | + layer.close(i); | ||
| 69 | + $.each(result, function(i, e){ | ||
| 70 | +// console.log(e); | ||
| 71 | + if(e.origin == 1){ | ||
| 72 | + e.originName = "导入"; | ||
| 73 | + } else { | ||
| 74 | + e.originName = "接口"; | ||
| 75 | + } | ||
| 76 | + }); | ||
| 77 | + var jdlReception = template('jdlReception_tbody',{list:result}); | ||
| 78 | + $('#forms_2 tbody').html(jdlReception); | ||
| 79 | + }); | ||
| 80 | + }) | ||
| 81 | + $("#exportList").on('click',function(){ | ||
| 82 | +// var i = layer.load(2); | ||
| 83 | +// var name=""; | ||
| 84 | +// if(dir=="1"){ | ||
| 85 | +// fileName="发车准点率"+dates; | ||
| 86 | +// }else{ | ||
| 87 | +// fileName="到站准点率"+dates; | ||
| 88 | +// } | ||
| 89 | +// $get('/calcSheet/calcSheet',{line:no,date:dates,dir:dir,type:'export'},function(result){ | ||
| 90 | +// window.open("/downloadFile/download?fileName="+fileName); | ||
| 91 | +// layer.close(i); | ||
| 92 | +// }); | ||
| 93 | + }); | ||
| 94 | + | ||
| 95 | + | ||
| 96 | + }); | ||
| 97 | +</script> | ||
| 98 | +<script type="text/html" id="jdlReception_tbody"> | ||
| 99 | + {{each list as obj i}} | ||
| 100 | + <tr> | ||
| 101 | + <td>{{obj.batchNo}}</td> | ||
| 102 | + <td>{{obj.connectorId}}</td> | ||
| 103 | + <td>{{obj.carCode}}</td> | ||
| 104 | + <td>{{obj.startTime}}</td> | ||
| 105 | + <td>{{obj.endTime}}</td> | ||
| 106 | + <td>{{obj.sumTime}}</td> | ||
| 107 | + <td>{{obj.startSoc}}</td> | ||
| 108 | + <td>{{obj.endSoc}}</td> | ||
| 109 | + <td>{{obj.chargeCapacity}}</td> | ||
| 110 | + <td>{{obj.originName}}</td> | ||
| 111 | + </tr> | ||
| 112 | + {{/each}} | ||
| 113 | + {{if list.length == 0}} | ||
| 114 | + <tr> | ||
| 115 | + <td colspan="10"><h6 class="muted">没有找到相关数据</h6></td> | ||
| 116 | + </tr> | ||
| 117 | + {{/if}} | ||
| 118 | +</script> | ||
| 0 | \ No newline at end of file | 119 | \ No newline at end of file |
src/main/resources/static/pages/electricity/jdl/jdlReceptionBatch.html
0 → 100644
| 1 | +<style> | ||
| 2 | +.blue{ | ||
| 3 | + background-color: #87CEFF | ||
| 4 | +} | ||
| 5 | +</style> | ||
| 6 | +<div class="page-head"> | ||
| 7 | + <div class="page-title"> | ||
| 8 | + <h1>充电量导入批次</h1> | ||
| 9 | + </div> | ||
| 10 | +</div> | ||
| 11 | +<ul class="page-breadcrumb breadcrumb"> | ||
| 12 | + <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | ||
| 13 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> | ||
| 14 | + <li><span class="active">充电量导入批次</span></li> | ||
| 15 | +</ul> | ||
| 16 | + | ||
| 17 | +<div class="row" id="jdlReceptionBatch_list"> | ||
| 18 | + <div class="col-md-12"> | ||
| 19 | + <!-- Begin: life time stats --> | ||
| 20 | + <div class="portlet light portlet-fit portlet-datatable bordered"> | ||
| 21 | + <div class="portlet-title"> | ||
| 22 | + <div class="caption"> | ||
| 23 | + <i class="fa fa-fire-extinguisher"></i> <span | ||
| 24 | + class="caption-subject font-dark sbold uppercase">充电量导入批次</span> | ||
| 25 | + </div> | ||
| 26 | +<!-- <div class="actions"> --> | ||
| 27 | +<!-- <button type="button" class="btn btn-circle blue" id="upload"><i class="fa fa-file-excel-o"></i> --> | ||
| 28 | +<!-- 导入Excel --> | ||
| 29 | +<!-- </button> --> | ||
| 30 | +<!-- <button type="button" class="btn btn-circle blue" id="export"><i class="fa fa-file-excel-o"></i> --> | ||
| 31 | +<!-- 导出Excel --> | ||
| 32 | +<!-- </button> --> | ||
| 33 | +<!-- </div> --> | ||
| 34 | + </div> | ||
| 35 | + <div class="portlet-body"> | ||
| 36 | + <div class="table-container" style="margin-top: 0px"> | ||
| 37 | + <table | ||
| 38 | + class="table table-striped table-bordered table-hover table-checkable" | ||
| 39 | + id="datatable_dlb"> | ||
| 40 | + <thead> | ||
| 41 | + <tr role="row" class="filter"> | ||
| 42 | + <td colspan="2">日期区间: | ||
| 43 | + <input type="text" style="width: 100px" name="rq1" id="rq1"/> | ||
| 44 | + - | ||
| 45 | + <input type="text" style="width: 100px" name="rq2" id="rq2"/> | ||
| 46 | + </td> | ||
| 47 | + <td colspan="2" width="120px">处理人: | ||
| 48 | + <input type="text" style="width: 100px" name="createBy" id="createBy"/> | ||
| 49 | + </td> | ||
| 50 | + <td width="24%"> | ||
| 51 | + <button class="btn btn-sm green btn-outline filter-submit margin-bottom" style="margin-right:0px"> | ||
| 52 | + <i class="fa fa-search"></i> 搜索 | ||
| 53 | + </button> | ||
| 54 | + <button class="btn btn-sm red btn-outline filter-cancel" style="margin-right:0px"> | ||
| 55 | + <i class="fa fa-times"></i> 重置 | ||
| 56 | + </button> | ||
| 57 | + </td> | ||
| 58 | + </tr> | ||
| 59 | + <tr role="row" class="heading"> | ||
| 60 | + <th>#</th> | ||
| 61 | + <th>导入时间</th> | ||
| 62 | + <th colspan="">处理人</th> | ||
| 63 | + <th colspan="">批次号</th> | ||
| 64 | + <td colspan="2">操作</td> | ||
| 65 | + </tr> | ||
| 66 | + </thead> | ||
| 67 | + <tbody></tbody> | ||
| 68 | + </table> | ||
| 69 | + <div style="text-align: right;"> | ||
| 70 | + <ul id="pagination" class="pagination"></ul> | ||
| 71 | + </div> | ||
| 72 | + </div> | ||
| 73 | + </div> | ||
| 74 | + <div class="portlet-body"> | ||
| 75 | + <div id="modules_tree"></div> | ||
| 76 | + </div> | ||
| 77 | + </div> | ||
| 78 | + </div> | ||
| 79 | +</div> | ||
| 80 | + | ||
| 81 | + | ||
| 82 | +<script src="/assets/js/ajaxfileupload/ajaxfileupload.js"></script> | ||
| 83 | +<script> | ||
| 84 | + $(function () { | ||
| 85 | + | ||
| 86 | + // 关闭左侧栏 | ||
| 87 | + if (!$('body').hasClass('page-sidebar-closed')) | ||
| 88 | + $('.menu-toggler.sidebar-toggler').click(); | ||
| 89 | + | ||
| 90 | + $("#rq1").datetimepicker({ | ||
| 91 | + format: 'YYYY-MM-DD', | ||
| 92 | + locale: 'zh-cn' | ||
| 93 | + }); | ||
| 94 | + $("#rq2").datetimepicker({ | ||
| 95 | + format: 'YYYY-MM-DD', | ||
| 96 | + locale: 'zh-cn' | ||
| 97 | + }); | ||
| 98 | + var d = new Date(); | ||
| 99 | +// d.setTime(d.getTime() - 1*1000*60*60*24); | ||
| 100 | + d.setTime(d.getTime()); | ||
| 101 | + var year = d.getFullYear(); | ||
| 102 | + var month = d.getMonth() + 1; | ||
| 103 | + var day = d.getDate(); | ||
| 104 | + if(month < 10) | ||
| 105 | + month = "0" + month; | ||
| 106 | + if(day < 10) | ||
| 107 | + day = "0" + day; | ||
| 108 | + $("#rq1").val(year + "-" + month + "-" + day); | ||
| 109 | + $("#rq2").val(year + "-" + month + "-" + day); | ||
| 110 | + | ||
| 111 | + var page = 0, initPagination; | ||
| 112 | + var icheckOptions = { | ||
| 113 | + radioClass: 'iradio_square-blue icheck', | ||
| 114 | + increaseArea: '20%' | ||
| 115 | + } | ||
| 116 | + | ||
| 117 | + //重置 | ||
| 118 | + $('tr.filter .filter-cancel').on('click', function () { | ||
| 119 | + $('tr.filter input, select').val('').change(); | ||
| 120 | + }); | ||
| 121 | + | ||
| 122 | + //提交 | ||
| 123 | + $('tr.filter .filter-submit').on('click', function () { | ||
| 124 | + if ($("#rq1").val() == "" || $("#rq1").val() ==null | ||
| 125 | + || $("#rq2").val() == "" || $("#rq2").val() ==null){ | ||
| 126 | + layer.msg('请选择日期.'); | ||
| 127 | + }else { | ||
| 128 | + | ||
| 129 | + var params = getParams(); | ||
| 130 | + | ||
| 131 | + page = 0; | ||
| 132 | + jsDoQuery(params, true); | ||
| 133 | + } | ||
| 134 | + }); | ||
| 135 | + | ||
| 136 | + | ||
| 137 | + $.get('/user/companyData', function(result){ | ||
| 138 | + obj = result; | ||
| 139 | + var options=""; | ||
| 140 | +// = '<option value="">请选择</option>'; | ||
| 141 | + for(var i = 0; i < obj.length; i++){ | ||
| 142 | + options += '<option value="'+obj[i].companyCode+'">'+obj[i].companyName+'</option>'; | ||
| 143 | +// setFgsqx(obj[i].companyCode); | ||
| 144 | + } | ||
| 145 | + $('#gsbm').html(options); | ||
| 146 | + updateCompany(); | ||
| 147 | + }); | ||
| 148 | + | ||
| 149 | + $("#gsbm").on("change",updateCompany); | ||
| 150 | + function updateCompany(){ | ||
| 151 | + var company = $('#gsbm').val(); | ||
| 152 | + var options =""; | ||
| 153 | +// = '<option value="">请选择</option>'; | ||
| 154 | + for(var i = 0; i < obj.length; i++){ | ||
| 155 | + if(obj[i].companyCode == company){ | ||
| 156 | + var children = obj[i].children; | ||
| 157 | + for(var j = 0; j < children.length; j++){ | ||
| 158 | + options += '<option value="'+children[j].code+'">'+children[j].name+'</option>'; | ||
| 159 | + } | ||
| 160 | + } | ||
| 161 | + } | ||
| 162 | + $('#fgsbm').html(options); | ||
| 163 | + } | ||
| 164 | + /* | ||
| 165 | + * 获取数据 p: 要提交的参数, pagination: 是否重新分页 | ||
| 166 | + */ | ||
| 167 | + function jsDoQuery(p, pagination) { | ||
| 168 | + var params = {}; | ||
| 169 | + if (p) | ||
| 170 | + params = p; | ||
| 171 | + params['order'] = 'nbbm'; | ||
| 172 | + params['page'] = page; | ||
| 173 | + params['rq1'] = $("#rq1").val(); | ||
| 174 | + params['rq2'] = $("#rq2").val(); | ||
| 175 | + | ||
| 176 | + var j = layer.load(2); | ||
| 177 | + $get('/jdl/queryJdlReceptionBatch', params, function (data) { | ||
| 178 | + $.each(data.dataList, function (i, obj) { | ||
| 179 | + obj.rq = moment(obj.rq).format("YYYY-MM-DD"); | ||
| 180 | + }); | ||
| 181 | + var bodyHtml = template('jdlReceptionBatch', {list:data.dataList}); | ||
| 182 | + | ||
| 183 | + $('#datatable_dlb tbody').html(bodyHtml) | ||
| 184 | + .find('.icheck').iCheck(icheckOptions) | ||
| 185 | + .on('ifChanged', iCheckChange); | ||
| 186 | + if (pagination && data.dataList.length > 0) { | ||
| 187 | + //重新分页 | ||
| 188 | + initPagination = true; | ||
| 189 | + showPagination(data); | ||
| 190 | + $('#pagination').show(); | ||
| 191 | + } else if(data.dataList.length == 0){ | ||
| 192 | + $('#pagination').hide(); | ||
| 193 | + } | ||
| 194 | + | ||
| 195 | + layer.close(j); | ||
| 196 | + | ||
| 197 | + startOptJzylLink($('#jdlReceptionBatch_list .in_carpark_jzyl')); | ||
| 198 | + | ||
| 199 | + $('.btn-ReceptionBatch').on('click', openReceptionBatchData); | ||
| 200 | + $('.btn-ReceptionBatch-upd').on('click', openReceptionBatchDataUpd); | ||
| 201 | + $('.btn-ReceptionBatch-del').on('click', openReceptionBatchDataDel); | ||
| 202 | + $('.btn-ReceptionBatch-export').on('click', openReceptionBatchDataExport); | ||
| 203 | + }); | ||
| 204 | + } | ||
| 205 | + | ||
| 206 | + function openReceptionBatchData(){ | ||
| 207 | + var id = $(this).data('date'); | ||
| 208 | + id += ","+$(this).data('by'); | ||
| 209 | + id += ",view"; | ||
| 210 | + $.get('/pages/electricity/jdl/jdlReceptionBatchData.html', function (content) { | ||
| 211 | + layer.open({ | ||
| 212 | + type: 1, | ||
| 213 | + area: ['1200px', '630px'], | ||
| 214 | + content: content, | ||
| 215 | + title: '充电量详细', | ||
| 216 | + shift: 5, | ||
| 217 | + scrollbar: false, | ||
| 218 | + success: function () { | ||
| 219 | + $('#jdlReceptionBatchData').trigger('init', id); | ||
| 220 | + } | ||
| 221 | + }); | ||
| 222 | + }); | ||
| 223 | + } | ||
| 224 | + | ||
| 225 | + function openReceptionBatchDataUpd(){ | ||
| 226 | + var id = $(this).data('date'); | ||
| 227 | + id += ","+$(this).data('by'); | ||
| 228 | + id += ",upd"; | ||
| 229 | + $.get('/pages/electricity/jdl/jdlReceptionBatchData.html', function (content) { | ||
| 230 | + layer.open({ | ||
| 231 | + type: 1, | ||
| 232 | + area: ['1200px', '660px'], | ||
| 233 | + content: content, | ||
| 234 | + title: '充电量详细修改', | ||
| 235 | + shift: 5, | ||
| 236 | + scrollbar: false, | ||
| 237 | + success: function () { | ||
| 238 | + $('#jdlReceptionBatchData').trigger('init', id); | ||
| 239 | + }, | ||
| 240 | + btn:["保存", "取消"], | ||
| 241 | + btn1: function(index, layero){ | ||
| 242 | + layer.msg('操作中...', {icon: 16, shade: 0.31}); | ||
| 243 | + var ids = "", dateStr = "", pileId = "", carCode = "", startTime = "", endTime = "", sumTime = "", | ||
| 244 | + startSoc = "", endSoc = "", chargeCapacity = "", stopReason = ""; | ||
| 245 | + $('#jdlReceptionBatchData_tbody input').each(function(i, e){ | ||
| 246 | + var obj = $(e); | ||
| 247 | + if("id" == obj.attr("name")){ | ||
| 248 | + ids += obj.val() + ","; | ||
| 249 | + } else if("dateStr" == obj.attr("name")){ | ||
| 250 | + dateStr += obj.val() + ","; | ||
| 251 | + } else if("pileId" == obj.attr("name")){ | ||
| 252 | + pileId += obj.val() + ","; | ||
| 253 | + } else if("carCode" == obj.attr("name")){ | ||
| 254 | + carCode += obj.val() + ","; | ||
| 255 | + } else if("startTime" == obj.attr("name")){ | ||
| 256 | + startTime += obj.val() + ","; | ||
| 257 | + } else if("endTime" == obj.attr("name")){ | ||
| 258 | + endTime += obj.val() + ","; | ||
| 259 | + } else if("sumTime" == obj.attr("name")){ | ||
| 260 | + sumTime += obj.val() + ","; | ||
| 261 | + } else if("startSoc" == obj.attr("name")){ | ||
| 262 | + startSoc += obj.val() + ","; | ||
| 263 | + } else if("endSoc" == obj.attr("name")){ | ||
| 264 | + endSoc += obj.val() + ","; | ||
| 265 | + } else if("chargeCapacity" == obj.attr("name")){ | ||
| 266 | + chargeCapacity += obj.val() + ","; | ||
| 267 | + } else if("stopReason" == obj.attr("name")){ | ||
| 268 | + stopReason += obj.val() + ","; | ||
| 269 | + } | ||
| 270 | + }); | ||
| 271 | + $post('/jdl/updateJdlReceptionBatch', {ids:ids,dateStr:dateStr,pileId:pileId,carCode:carCode, | ||
| 272 | + startTime:startTime,endTime:endTime,sumTime:sumTime, | ||
| 273 | + startSoc:startSoc,endSoc:endSoc,chargeCapacity:chargeCapacity,stopReason:stopReason}, function (rs) { | ||
| 274 | + console.log(rs); | ||
| 275 | + if(rs.status && rs.status == "SUCCESS"){ | ||
| 276 | + layer.msg('修改成功。'); | ||
| 277 | + layer.close(index); | ||
| 278 | + } else { | ||
| 279 | + layer.msg('操作失败,请检查内容是否有误。'); | ||
| 280 | + } | ||
| 281 | + }); | ||
| 282 | + } | ||
| 283 | + }); | ||
| 284 | + }); | ||
| 285 | + } | ||
| 286 | + | ||
| 287 | + function openReceptionBatchDataDel(){ | ||
| 288 | + var createDate = $(this).data('date'); | ||
| 289 | + var createBy = $(this).data('by'); | ||
| 290 | + layer.confirm('你确定要删除充电量吗?', { | ||
| 291 | + btn: ['确定删除','取消'] //按钮 | ||
| 292 | + }, function(){ | ||
| 293 | + layer.msg('操作中...', {icon: 16,shade: 0.01}); | ||
| 294 | + $post('/jdl/deleteJdlReceptionBatch', {createDate:createDate, createBy:createBy}, function (rs) { | ||
| 295 | + layer.msg('删除成功!'); | ||
| 296 | + $('.filter-submit.margin-bottom').trigger('click'); | ||
| 297 | + }); | ||
| 298 | + }); | ||
| 299 | + } | ||
| 300 | + | ||
| 301 | + function openReceptionBatchDataExport(){ | ||
| 302 | + var batchNo = $(this).data('batch'); | ||
| 303 | + window.open("/jdl/downloadJdlReceptionImportFile?batchNo=" + batchNo); | ||
| 304 | + } | ||
| 305 | + | ||
| 306 | + //改变状态 | ||
| 307 | + function startOptJzylLink(es) { | ||
| 308 | + es.editable({ | ||
| 309 | + type: 'text', | ||
| 310 | + placement: 'right', | ||
| 311 | + width: 100, | ||
| 312 | + display: false, | ||
| 313 | + validate: function (value) { | ||
| 314 | + if (!value) | ||
| 315 | + return '值不能为空!'; | ||
| 316 | + if (isNaN(value)) | ||
| 317 | + return '只能为数字!'; | ||
| 318 | + if (value < 0) | ||
| 319 | + return '值不能小于0!'; | ||
| 320 | + }, | ||
| 321 | + inputclass: 'form-control input-medium input-edtable-sm' | ||
| 322 | + }).on('save', function (e, params) { | ||
| 323 | + $(this).text(params.newValue); | ||
| 324 | + }); | ||
| 325 | + } | ||
| 326 | + | ||
| 327 | + function iCheckChange() { | ||
| 328 | + var tr = $(this).parents('tr'); | ||
| 329 | + if (this.checked) | ||
| 330 | + tr.addClass('row-active'); | ||
| 331 | + else | ||
| 332 | + tr.removeClass('row-active'); | ||
| 333 | + } | ||
| 334 | + | ||
| 335 | + function showPagination(data) { | ||
| 336 | + //分页 | ||
| 337 | + $('#pagination').jqPaginator({ | ||
| 338 | + totalPages: data.totalPages, | ||
| 339 | + visiblePages: 6, | ||
| 340 | + currentPage: page + 1, | ||
| 341 | + first: '<li class="first"><a href="javascript:void(0);">首页<\/a><\/li>', | ||
| 342 | + prev: '<li class="prev"><a href="javascript:void(0);">上一页<\/a><\/li>', | ||
| 343 | + next: '<li class="next"><a href="javascript:void(0);">下一页<\/a><\/li>', | ||
| 344 | + last: '<li class="last"><a href="javascript:void(0);">尾页<\/a><\/li>', | ||
| 345 | + page: '<li class="page"><a href="javascript:void(0);">{{page}}<\/a><\/li>', | ||
| 346 | + onPageChange: function (num, type) { | ||
| 347 | + if (initPagination) { | ||
| 348 | + initPagination = false; | ||
| 349 | + return; | ||
| 350 | + } | ||
| 351 | + | ||
| 352 | + var params = getParams(); | ||
| 353 | + | ||
| 354 | + page = num - 1; | ||
| 355 | + jsDoQuery(params, true); | ||
| 356 | + } | ||
| 357 | + }); | ||
| 358 | + } | ||
| 359 | + | ||
| 360 | + //搜索线路 | ||
| 361 | + $.get('/basic/lineCode2Name',function(result){ | ||
| 362 | + var data=[]; | ||
| 363 | + | ||
| 364 | + for(var code in result){ | ||
| 365 | + data.push({id: code, text: result[code]}); | ||
| 366 | + } | ||
| 367 | + initPinYinSelect2('#xlbm',data,''); | ||
| 368 | + | ||
| 369 | + }); | ||
| 370 | + | ||
| 371 | + $('#nbbm').select2({ | ||
| 372 | + placeholder: '搜索车辆...', | ||
| 373 | + ajax: { | ||
| 374 | + url: '/realSchedule/sreachVehic', | ||
| 375 | + dataType: 'json', | ||
| 376 | + delay: 150, | ||
| 377 | + data: function (params) { | ||
| 378 | + return {nbbm: params.term}; | ||
| 379 | + }, | ||
| 380 | + processResults: function (data) { | ||
| 381 | + return { | ||
| 382 | + results: data | ||
| 383 | + }; | ||
| 384 | + }, | ||
| 385 | + cache: true | ||
| 386 | + }, | ||
| 387 | + templateResult: function (repo) { | ||
| 388 | + if (repo.loading) return repo.text; | ||
| 389 | + var h = '<span>' + repo.text + '</span>'; | ||
| 390 | + h += (repo.lineName ? ' <span class="select2-desc">' + repo.lineName + '</span>' : ''); | ||
| 391 | + return h; | ||
| 392 | + }, | ||
| 393 | + escapeMarkup: function (markup) { | ||
| 394 | + return markup; | ||
| 395 | + }, | ||
| 396 | + minimumInputLength: 1, | ||
| 397 | + templateSelection: function (repo) { | ||
| 398 | + return repo.text; | ||
| 399 | + }, | ||
| 400 | + language: { | ||
| 401 | + noResults: function () { | ||
| 402 | + return '<span style="color:red;font-size: 12px;">没有搜索到车辆!</span>'; | ||
| 403 | + }, | ||
| 404 | + inputTooShort: function (e) { | ||
| 405 | + return '<span style="color:gray;font-size: 12px;"><i class="fa fa-search"></i> 输入自编号搜索车辆</span>'; | ||
| 406 | + }, | ||
| 407 | + searching: function () { | ||
| 408 | + return '<span style="color:gray;font-size: 12px;"> 正在搜索车辆...</span>'; | ||
| 409 | + } | ||
| 410 | + } | ||
| 411 | + }) | ||
| 412 | + | ||
| 413 | + function getParams(){ | ||
| 414 | + var cells = $('tr.filter')[0].cells | ||
| 415 | + , params = {} | ||
| 416 | + , name; | ||
| 417 | + $.each(cells, function (i, cell) { | ||
| 418 | + var items = $('input,select', cell); | ||
| 419 | + for (var j = 0, item; item = items[j++];) { | ||
| 420 | + name = $(item).attr('name'); | ||
| 421 | + if (name) { | ||
| 422 | + params[name] = $(item).val(); | ||
| 423 | + } | ||
| 424 | + } | ||
| 425 | + }); | ||
| 426 | + return params; | ||
| 427 | + }; | ||
| 428 | + | ||
| 429 | + }); | ||
| 430 | + | ||
| 431 | +</script> | ||
| 432 | + | ||
| 433 | +<script id="jdlReceptionBatch" type="text/html"> | ||
| 434 | + {{each list as obj i}} | ||
| 435 | + <tr> | ||
| 436 | + <td style="vertical-align: middle;"> | ||
| 437 | + <!-- <input type="radio" name="id" class="group-checkable icheck" data-id="{{obj.id}}"> --> | ||
| 438 | + {{i + 1}} | ||
| 439 | + </td> | ||
| 440 | + <td>{{obj.createDate}}</td> | ||
| 441 | + <td colspan="">{{obj.createBy}}</td> | ||
| 442 | + <td colspan="">{{obj.batchNo}}</td> | ||
| 443 | + <td colspan="2"> | ||
| 444 | + <button class="btn btn-info btn-sm btn-ReceptionBatch" data-date="{{obj.createDate}}" data-by="{{obj.createBy}}"> | ||
| 445 | + <i class="fa fa-search"></i> 查看 | ||
| 446 | + </button> | ||
| 447 | + <button class="btn blue-madison btn-sm btn-ReceptionBatch-upd" data-date="{{obj.createDate}}" data-by="{{obj.createBy}}"> | ||
| 448 | + <i class="fa fa-pencil"></i> 修改 | ||
| 449 | + </button> | ||
| 450 | + <button class="btn btn-danger btn-sm red btn-ReceptionBatch-del" data-date="{{obj.createDate}}" data-by="{{obj.createBy}}"> | ||
| 451 | + <i class="fa fa-times"></i> 删除 | ||
| 452 | + </button> | ||
| 453 | + | ||
| 454 | + <button class="btn btn-circle btn-sm blue btn-ReceptionBatch-export" data-batch="{{obj.batchNo}}"> | ||
| 455 | + <i class="fa fa-file-excel-o"></i> 下载导入文件 | ||
| 456 | + </button> | ||
| 457 | + </td> | ||
| 458 | + </tr> | ||
| 459 | + {{/each}} | ||
| 460 | + {{if list.length == 0}} | ||
| 461 | + <tr> | ||
| 462 | + <td colspan=9><h6 class="muted">没有找到相关数据</h6></td> | ||
| 463 | + </tr> | ||
| 464 | + {{/if}} | ||
| 465 | +</script> | ||
| 0 | \ No newline at end of file | 466 | \ No newline at end of file |
src/main/resources/static/pages/electricity/jdl/jdlReceptionBatchData.html
0 → 100644
| 1 | +<style type="text/css"> | ||
| 2 | + .table-bordered { | ||
| 3 | + border: 1px solid; } | ||
| 4 | + .table-bordered > thead > tr > th, | ||
| 5 | + .table-bordered > thead > tr > td, | ||
| 6 | + .table-bordered > tbody > tr > th, | ||
| 7 | + .table-bordered > tbody > tr > td, | ||
| 8 | + .table-bordered > tfoot > tr > th, | ||
| 9 | + .table-bordered > tfoot > tr > td { | ||
| 10 | + border: 1px solid; } | ||
| 11 | + .table-bordered > thead > tr > th, | ||
| 12 | + .table-bordered > thead > tr > td { | ||
| 13 | + border-bottom-width: 2px; } | ||
| 14 | + | ||
| 15 | + .table > tbody + tbody { | ||
| 16 | + border-top: 1px solid; } | ||
| 17 | +</style> | ||
| 18 | + | ||
| 19 | +<div id="jdlReceptionBatchData"> | ||
| 20 | + <div class="col-md-12"> | ||
| 21 | +<!-- <div class="portlet light porttlet-fit bordered"> --> | ||
| 22 | + <div class="portlet-body"> | ||
| 23 | + <div class="table-container" style="margin-top: 10px;width: 1180px;height: 550px;overflow:auto;"> | ||
| 24 | + <table class="table table-bordered table-hover table-checkable" id="forms_2"> | ||
| 25 | + <thead> | ||
| 26 | + <tr> | ||
| 27 | + <td style="min-width: 170px">批次号</td> | ||
| 28 | + <td style="min-width: 90px">营运日期</td> | ||
| 29 | + <td style="min-width: 80px">枪名</td> | ||
| 30 | + <td style="min-width: 80px">枪号</td> | ||
| 31 | + <td style="min-width: 80px">充电站</td> | ||
| 32 | + <td>车号</td> | ||
| 33 | + <td>开始时间</td> | ||
| 34 | + <td>结束时间</td> | ||
| 35 | + <td>总计(分钟)</td> | ||
| 36 | + <td>起始电量SOC(%)</td> | ||
| 37 | + <td>结束电量SOC(%)</td> | ||
| 38 | + <td>充电度数</td> | ||
| 39 | +<!-- <td>一次不能正常充电记录</td> --> | ||
| 40 | + </tr> | ||
| 41 | + </thead> | ||
| 42 | + | ||
| 43 | + <tbody id="jdlReceptionBatchData_tbody"> | ||
| 44 | + | ||
| 45 | + </tbody> | ||
| 46 | + </table> | ||
| 47 | + </div> | ||
| 48 | + </div> | ||
| 49 | +<!-- </div> --> | ||
| 50 | + </div> | ||
| 51 | +</div> | ||
| 52 | +<script src="/pages/mforms/singledatas/jquery.table2excel.min.js"></script> | ||
| 53 | +<script> | ||
| 54 | + $(function(){ | ||
| 55 | + // 关闭左侧栏 | ||
| 56 | + if (!$('body').hasClass('page-sidebar-closed')) | ||
| 57 | + $('.menu-toggler.sidebar-toggler').click(); | ||
| 58 | + var date = ""; | ||
| 59 | + var nbbm = ""; | ||
| 60 | + $("#jdlReceptionBatchData").on('init', function (e, id) { | ||
| 61 | + date = id.split(",")[0]; | ||
| 62 | + by = id.split(",")[1]; | ||
| 63 | + type = id.split(",")[2]; | ||
| 64 | + var i = layer.load(2); | ||
| 65 | + $get('/jdl/queryJdlReceptionBatchData',{createDate:date,createBy:by,type:'query'},function(result){ | ||
| 66 | + layer.close(i); | ||
| 67 | + $.each(result, function(i, e){ | ||
| 68 | +// console.log(e); | ||
| 69 | + if(e.origin == 1){ | ||
| 70 | + e.originName = "导入"; | ||
| 71 | + } else { | ||
| 72 | + e.originName = "接口"; | ||
| 73 | + } | ||
| 74 | + }); | ||
| 75 | + if(type == "upd"){ | ||
| 76 | + var jdlReceptionBatchDataUpd = template('jdlReceptionBatchData_tbody_upd',{list:result}); | ||
| 77 | + $('#forms_2 tbody').html(jdlReceptionBatchDataUpd); | ||
| 78 | +// $("input[name=dateStr]").datetimepicker({ | ||
| 79 | +// format: 'YYYY-MM-DD', | ||
| 80 | +// locale: 'zh-cn' | ||
| 81 | +// }); | ||
| 82 | + } else { | ||
| 83 | + var jdlReceptionBatchDataView = template('jdlReceptionBatchData_tbody_view',{list:result}); | ||
| 84 | + $('#forms_2 tbody').html(jdlReceptionBatchDataView); | ||
| 85 | + } | ||
| 86 | + }); | ||
| 87 | + }) | ||
| 88 | + | ||
| 89 | + }); | ||
| 90 | + | ||
| 91 | + function formatInputNumber(e){ | ||
| 92 | + // 获取输入值 | ||
| 93 | + var value = e.target.value; | ||
| 94 | + var v = value.replace(/[^0-9.]/g, ''); | ||
| 95 | + if('\.' == v.charAt(0)){ | ||
| 96 | + v = '0' + v; | ||
| 97 | + } | ||
| 98 | + if(v.indexOf('\.') > 0){ | ||
| 99 | + var split = v.split('\.'); | ||
| 100 | + if(split[1].length > 0){ | ||
| 101 | + v = split[0] + '\.' + (split[1].substring(0, 2)); | ||
| 102 | + } else { | ||
| 103 | + v = split[0] + '\.0'; | ||
| 104 | + } | ||
| 105 | + } | ||
| 106 | + // 更新输入框的值 | ||
| 107 | + e.target.value = v; | ||
| 108 | + } | ||
| 109 | +</script> | ||
| 110 | +<script type="text/html" id="jdlReceptionBatchData_tbody_view"> | ||
| 111 | + {{each list as obj i}} | ||
| 112 | + <tr> | ||
| 113 | + <td>{{obj.batchNo}}</td> | ||
| 114 | + <td>{{obj.dateStr}}</td> | ||
| 115 | + <td>{{obj.connectorName}}</td> | ||
| 116 | + <td>{{obj.connectorId}}</td> | ||
| 117 | + <td>{{obj.stationName}}</td> | ||
| 118 | + <td>{{obj.carCode}}</td> | ||
| 119 | + <td>{{obj.startTime}}</td> | ||
| 120 | + <td>{{obj.endTime}}</td> | ||
| 121 | + <td>{{obj.sumTime}}</td> | ||
| 122 | + <td>{{obj.startSoc}}</td> | ||
| 123 | + <td>{{obj.endSoc}}</td> | ||
| 124 | + <td>{{obj.chargeCapacity}}</td> | ||
| 125 | + </tr> | ||
| 126 | + {{/each}} | ||
| 127 | + {{if list.length == 0}} | ||
| 128 | + <tr> | ||
| 129 | + <td colspan="12"><h6 class="muted">没有找到相关数据</h6></td> | ||
| 130 | + </tr> | ||
| 131 | + {{/if}} | ||
| 132 | +</script> | ||
| 133 | +<script type="text/html" id="jdlReceptionBatchData_tbody_upd"> | ||
| 134 | + {{each list as obj i}} | ||
| 135 | + <tr> | ||
| 136 | + <td>{{obj.batchNo}}<input type="hidden" name="id" value="{{obj.id}}"/></td> | ||
| 137 | + <td>{{obj.dateStr}}</td> | ||
| 138 | + <td>{{obj.connectorName}}</td> | ||
| 139 | + <td>{{obj.connectorId}}</td> | ||
| 140 | + <td>{{obj.stationName}}</td> | ||
| 141 | + <td>{{obj.carCode}}</td> | ||
| 142 | + <td>{{obj.startTime}}</td> | ||
| 143 | + <td>{{obj.endTime}}</td> | ||
| 144 | + <td>{{obj.sumTime}}</td> | ||
| 145 | + <td>{{obj.startSoc}}</td> | ||
| 146 | + <td>{{obj.endSoc}}</td> | ||
| 147 | + <td><input type="text" name="chargeCapacity" value="{{obj.chargeCapacity}}" oninput="formatInputNumber(event)"/></td> | ||
| 148 | + </tr> | ||
| 149 | + {{/each}} | ||
| 150 | + {{if list.length == 0}} | ||
| 151 | + <tr> | ||
| 152 | + <td colspan="12"><h6 class="muted">没有找到相关数据</h6></td> | ||
| 153 | + </tr> | ||
| 154 | + {{/if}} | ||
| 155 | +</script> | ||
| 0 | \ No newline at end of file | 156 | \ No newline at end of file |
src/main/resources/static/pages/electricity/jdl/list.html
| @@ -10,7 +10,7 @@ | @@ -10,7 +10,7 @@ | ||
| 10 | </div> | 10 | </div> |
| 11 | <ul class="page-breadcrumb breadcrumb"> | 11 | <ul class="page-breadcrumb breadcrumb"> |
| 12 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | 12 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> |
| 13 | - <li><span class="active">用电管理</span> <i class="fa fa-circle"></i></li> | 13 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> |
| 14 | <li><span class="active">车辆充电管理</span></li> | 14 | <li><span class="active">车辆充电管理</span></li> |
| 15 | </ul> | 15 | </ul> |
| 16 | 16 |
src/main/resources/static/pages/electricity/jdl/list_2412.html
0 → 100644
| 1 | +<style> | ||
| 2 | +.blue{ | ||
| 3 | + background-color: #87CEFF | ||
| 4 | +} | ||
| 5 | +</style> | ||
| 6 | +<div class="page-head"> | ||
| 7 | + <div class="page-title"> | ||
| 8 | + <h1>车辆充电量</h1> | ||
| 9 | + </div> | ||
| 10 | +</div> | ||
| 11 | +<ul class="page-breadcrumb breadcrumb"> | ||
| 12 | + <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | ||
| 13 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> | ||
| 14 | + <li><span class="active">车辆充电管理</span></li> | ||
| 15 | +</ul> | ||
| 16 | + | ||
| 17 | +<div class="row" id="ll_oil_list"> | ||
| 18 | + <div class="col-md-12"> | ||
| 19 | + <!-- Begin: life time stats --> | ||
| 20 | + <div class="portlet light portlet-fit portlet-datatable bordered"> | ||
| 21 | + <div class="portlet-title"> | ||
| 22 | + <div class="caption"> | ||
| 23 | + <i class="fa fa-fire-extinguisher"></i> <span | ||
| 24 | + class="caption-subject font-dark sbold uppercase">车辆充电量</span> | ||
| 25 | + </div> | ||
| 26 | + <div class="actions"> | ||
| 27 | + <button type="button" class="btn btn-circle blue" id="upload"><i class="fa fa-file-excel-o"></i> | ||
| 28 | + 导入Excel | ||
| 29 | + </button> | ||
| 30 | + <button type="button" class="btn btn-circle blue" id="export"><i class="fa fa-file-excel-o"></i> | ||
| 31 | + 导出Excel | ||
| 32 | + </button> | ||
| 33 | + </div> | ||
| 34 | + </div> | ||
| 35 | + <div class="portlet-body"> | ||
| 36 | + <div class="table-container" style="margin-top: 0px"> | ||
| 37 | + <table | ||
| 38 | + class="table table-striped table-bordered table-hover table-checkable" | ||
| 39 | + id="datatable_dlb"> | ||
| 40 | + <thead> | ||
| 41 | + <tr role="row" class="filter"> | ||
| 42 | +<!-- <td width="80px">公司:</td> --> | ||
| 43 | +<!-- <td width="160px"> --> | ||
| 44 | +<!-- <select class="form-control" id="gsbm" ></select> --> | ||
| 45 | +<!-- </td> --> | ||
| 46 | +<!-- <td>分公司:</td> --> | ||
| 47 | +<!-- <td> --> | ||
| 48 | +<!-- <select class="form-control" id="fgsbm" ></select> --> | ||
| 49 | +<!-- </td> --> | ||
| 50 | + <td colspan="2">日期:</td> | ||
| 51 | + <td colspan="2" width="120px"> | ||
| 52 | + <input type="text" style="width: 100px" name="rq" id="rq"/> | ||
| 53 | + </td> | ||
| 54 | + <td colspan="2">内部编码:</td> | ||
| 55 | + <td colspan="2"> | ||
| 56 | + <select class="form-control" name="nbbm" id="nbbm" style="width: 120px;"></select> | ||
| 57 | + </td> | ||
| 58 | + | ||
| 59 | + <td width="24%"> | ||
| 60 | + <button class="btn btn-sm green btn-outline filter-submit margin-bottom" style="margin-right:0px"> | ||
| 61 | + <i class="fa fa-search"></i> 搜索 | ||
| 62 | + </button> | ||
| 63 | + <button class="btn btn-sm red btn-outline filter-cancel" style="margin-right:0px"> | ||
| 64 | + <i class="fa fa-times"></i> 重置 | ||
| 65 | + </button> | ||
| 66 | +<!-- <button class="btn btn-danger btn-sm red" id="del" style="margin-right:0px"> --> | ||
| 67 | +<!-- <i class="fa fa-times"></i> 删除 --> | ||
| 68 | +<!-- </button> --> | ||
| 69 | + </td> | ||
| 70 | + </tr> | ||
| 71 | + <tr role="row" class="heading"> | ||
| 72 | + <th>#</th> | ||
| 73 | + <th>日期</th> | ||
| 74 | + <th colspan="2">内部编码</th> | ||
| 75 | + <th colspan="4">充电量</th> | ||
| 76 | +<!-- <th colspan="2">充电站</th> --> | ||
| 77 | +<!-- <th colspan="2">备注</th> --> | ||
| 78 | + <td colspan="2">操作</td> | ||
| 79 | + </tr> | ||
| 80 | + </thead> | ||
| 81 | + <tbody></tbody> | ||
| 82 | + </table> | ||
| 83 | + <div style="text-align: right;"> | ||
| 84 | + <ul id="pagination" class="pagination"></ul> | ||
| 85 | + </div> | ||
| 86 | + </div> | ||
| 87 | + </div> | ||
| 88 | + <div class="portlet-body"> | ||
| 89 | + <div id="modules_tree"></div> | ||
| 90 | + </div> | ||
| 91 | + </div> | ||
| 92 | + </div> | ||
| 93 | +</div> | ||
| 94 | + | ||
| 95 | + | ||
| 96 | +<script src="/assets/js/ajaxfileupload/ajaxfileupload.js"></script> | ||
| 97 | +<script> | ||
| 98 | + $(function () { | ||
| 99 | + | ||
| 100 | + // 关闭左侧栏 | ||
| 101 | + if (!$('body').hasClass('page-sidebar-closed')) | ||
| 102 | + $('.menu-toggler.sidebar-toggler').click(); | ||
| 103 | + | ||
| 104 | + $("#rq").datetimepicker({ | ||
| 105 | + format: 'YYYY-MM-DD', | ||
| 106 | + locale: 'zh-cn' | ||
| 107 | + }); | ||
| 108 | + var d = new Date(); | ||
| 109 | + d.setTime(d.getTime() - 1*1000*60*60*24); | ||
| 110 | + var year = d.getFullYear(); | ||
| 111 | + var month = d.getMonth() + 1; | ||
| 112 | + var day = d.getDate(); | ||
| 113 | + if(month < 10) | ||
| 114 | + month = "0" + month; | ||
| 115 | + if(day < 10) | ||
| 116 | + day = "0" + day; | ||
| 117 | + $("#rq").val(year + "-" + month + "-" + day); | ||
| 118 | + | ||
| 119 | + var page = 0, initPagination; | ||
| 120 | + var icheckOptions = { | ||
| 121 | + radioClass: 'iradio_square-blue icheck', | ||
| 122 | + increaseArea: '20%' | ||
| 123 | + } | ||
| 124 | + | ||
| 125 | + //重置 | ||
| 126 | + $('tr.filter .filter-cancel').on('click', function () { | ||
| 127 | + $('tr.filter input, select').val('').change(); | ||
| 128 | + }); | ||
| 129 | + | ||
| 130 | + //提交 | ||
| 131 | + $('tr.filter .filter-submit').on('click', function () { | ||
| 132 | + var gsbm = $('#gsbm').val(); | ||
| 133 | +// var fgsbm = $('#fgsbm').val(); | ||
| 134 | + var fgsbm = -1; | ||
| 135 | + if ($("#rq").val() == "" || $("#rq").val() ==null){ | ||
| 136 | + layer.msg('请选择日期.'); | ||
| 137 | +// }else if(gsbm=="" || gsbm==null || fgsbm=="" ||fgsbm==null){ | ||
| 138 | +// layer.msg('请选择公司和分公司.'); | ||
| 139 | +// }else if(gsbm=="" || gsbm==null){ | ||
| 140 | +// layer.msg('请选择公司.'); | ||
| 141 | + }else { | ||
| 142 | + | ||
| 143 | + var params = getParams(); | ||
| 144 | + | ||
| 145 | + page = 0; | ||
| 146 | + jsDoQuery(params, true); | ||
| 147 | + } | ||
| 148 | + }); | ||
| 149 | + | ||
| 150 | + | ||
| 151 | + $.get('/user/companyData', function(result){ | ||
| 152 | + obj = result; | ||
| 153 | + var options=""; | ||
| 154 | +// = '<option value="">请选择</option>'; | ||
| 155 | + for(var i = 0; i < obj.length; i++){ | ||
| 156 | + options += '<option value="'+obj[i].companyCode+'">'+obj[i].companyName+'</option>'; | ||
| 157 | +// setFgsqx(obj[i].companyCode); | ||
| 158 | + } | ||
| 159 | + $('#gsbm').html(options); | ||
| 160 | + updateCompany(); | ||
| 161 | + }); | ||
| 162 | + | ||
| 163 | + $("#gsbm").on("change",updateCompany); | ||
| 164 | + function updateCompany(){ | ||
| 165 | + var company = $('#gsbm').val(); | ||
| 166 | + var options =""; | ||
| 167 | +// = '<option value="">请选择</option>'; | ||
| 168 | + for(var i = 0; i < obj.length; i++){ | ||
| 169 | + if(obj[i].companyCode == company){ | ||
| 170 | + var children = obj[i].children; | ||
| 171 | + for(var j = 0; j < children.length; j++){ | ||
| 172 | + options += '<option value="'+children[j].code+'">'+children[j].name+'</option>'; | ||
| 173 | + } | ||
| 174 | + } | ||
| 175 | + } | ||
| 176 | + $('#fgsbm').html(options); | ||
| 177 | + } | ||
| 178 | + /* | ||
| 179 | + * 获取数据 p: 要提交的参数, pagination: 是否重新分页 | ||
| 180 | + */ | ||
| 181 | + function jsDoQuery(p, pagination) { | ||
| 182 | + var params = {}; | ||
| 183 | + if (p) | ||
| 184 | + params = p; | ||
| 185 | + params['order'] = 'nbbm'; | ||
| 186 | + params['page'] = page; | ||
| 187 | + params['rq'] = $("#rq").val(); | ||
| 188 | + | ||
| 189 | + var j = layer.load(2); | ||
| 190 | + $get('/jdl/query_2412', params, function (data) { | ||
| 191 | + $.each(data.dataList, function (i, obj) { | ||
| 192 | + obj.rq = moment(obj.rq).format("YYYY-MM-DD"); | ||
| 193 | + }); | ||
| 194 | + var bodyHtm = template('jdl_2412_list', {list:data.dataList}); | ||
| 195 | + | ||
| 196 | + $('#datatable_dlb tbody').html(bodyHtm) | ||
| 197 | + .find('.icheck').iCheck(icheckOptions) | ||
| 198 | + .on('ifChanged', iCheckChange); | ||
| 199 | + if (pagination && data.dataList.length > 0) { | ||
| 200 | + //重新分页 | ||
| 201 | + initPagination = true; | ||
| 202 | + showPagination(data); | ||
| 203 | + $('#pagination').show(); | ||
| 204 | + } else if(data.dataList.length == 0){ | ||
| 205 | + $('#pagination').hide(); | ||
| 206 | + } | ||
| 207 | + | ||
| 208 | + layer.close(j); | ||
| 209 | + | ||
| 210 | + startOptJzylLink($('#ll_oil_list .in_carpark_jzyl')); | ||
| 211 | + | ||
| 212 | + $('.btn-Reception').on('click', openReception); | ||
| 213 | + }); | ||
| 214 | + } | ||
| 215 | + | ||
| 216 | + function openReception(){ | ||
| 217 | + var id = $(this).data('date'); | ||
| 218 | + id += ","+$(this).data('nbbm'); | ||
| 219 | + $.get('/pages/electricity/jdl/jdlReception.html', function (content) { | ||
| 220 | + layer.open({ | ||
| 221 | + type: 1, | ||
| 222 | + area: ['1200px', '600px'], | ||
| 223 | + content: content, | ||
| 224 | + title: '充电量详细', | ||
| 225 | + shift: 5, | ||
| 226 | + scrollbar: false, | ||
| 227 | + success: function () { | ||
| 228 | + $('#jdlReception').trigger('init', id); | ||
| 229 | + } | ||
| 230 | + }); | ||
| 231 | + }); | ||
| 232 | + } | ||
| 233 | + | ||
| 234 | + //改变状态 | ||
| 235 | + function startOptJzylLink(es) { | ||
| 236 | + es.editable({ | ||
| 237 | + type: 'text', | ||
| 238 | + placement: 'right', | ||
| 239 | + width: 100, | ||
| 240 | + display: false, | ||
| 241 | + validate: function (value) { | ||
| 242 | + if (!value) | ||
| 243 | + return '值不能为空!'; | ||
| 244 | + if (isNaN(value)) | ||
| 245 | + return '只能为数字!'; | ||
| 246 | + if (value < 0) | ||
| 247 | + return '值不能小于0!'; | ||
| 248 | + }, | ||
| 249 | + inputclass: 'form-control input-medium input-edtable-sm' | ||
| 250 | + }).on('save', function (e, params) { | ||
| 251 | + $(this).text(params.newValue); | ||
| 252 | + }); | ||
| 253 | + } | ||
| 254 | + | ||
| 255 | + function iCheckChange() { | ||
| 256 | + var tr = $(this).parents('tr'); | ||
| 257 | + if (this.checked) | ||
| 258 | + tr.addClass('row-active'); | ||
| 259 | + else | ||
| 260 | + tr.removeClass('row-active'); | ||
| 261 | + | ||
| 262 | + /* if($('#datatable_resource input.icheck:checked').length == 1) | ||
| 263 | + $('#removeButton').removeAttr('disabled'); | ||
| 264 | + else | ||
| 265 | + $('#removeButton').attr('disabled', 'disabled'); */ | ||
| 266 | + } | ||
| 267 | + | ||
| 268 | + function showPagination(data) { | ||
| 269 | + //分页 | ||
| 270 | + $('#pagination').jqPaginator({ | ||
| 271 | + totalPages: data.totalPages, | ||
| 272 | + visiblePages: 6, | ||
| 273 | + currentPage: page + 1, | ||
| 274 | + first: '<li class="first"><a href="javascript:void(0);">首页<\/a><\/li>', | ||
| 275 | + prev: '<li class="prev"><a href="javascript:void(0);">上一页<\/a><\/li>', | ||
| 276 | + next: '<li class="next"><a href="javascript:void(0);">下一页<\/a><\/li>', | ||
| 277 | + last: '<li class="last"><a href="javascript:void(0);">尾页<\/a><\/li>', | ||
| 278 | + page: '<li class="page"><a href="javascript:void(0);">{{page}}<\/a><\/li>', | ||
| 279 | + onPageChange: function (num, type) { | ||
| 280 | + if (initPagination) { | ||
| 281 | + initPagination = false; | ||
| 282 | + return; | ||
| 283 | + } | ||
| 284 | + | ||
| 285 | + var params = getParams(); | ||
| 286 | + | ||
| 287 | + page = num - 1; | ||
| 288 | + jsDoQuery(params, true); | ||
| 289 | + } | ||
| 290 | + }); | ||
| 291 | + } | ||
| 292 | + | ||
| 293 | + | ||
| 294 | + //删除 | ||
| 295 | + $('#del').on('click', function () { | ||
| 296 | + if ($(this).attr('disabled')) | ||
| 297 | + return; | ||
| 298 | + | ||
| 299 | + var id = $('input.icheck:checked').data('id'); | ||
| 300 | + removeConfirm('确定要删除选中的数据?', '/resource/' + id, function () { | ||
| 301 | + $('tr.filter .filter-submit').click(); | ||
| 302 | + }); | ||
| 303 | + }); | ||
| 304 | + | ||
| 305 | + //搜索线路 | ||
| 306 | + $.get('/basic/lineCode2Name',function(result){ | ||
| 307 | + var data=[]; | ||
| 308 | + | ||
| 309 | + for(var code in result){ | ||
| 310 | + data.push({id: code, text: result[code]}); | ||
| 311 | + } | ||
| 312 | + initPinYinSelect2('#xlbm',data,''); | ||
| 313 | + | ||
| 314 | + }); | ||
| 315 | + | ||
| 316 | + $('#nbbm').select2({ | ||
| 317 | + placeholder: '搜索车辆...', | ||
| 318 | + ajax: { | ||
| 319 | + url: '/realSchedule/sreachVehic', | ||
| 320 | + dataType: 'json', | ||
| 321 | + delay: 150, | ||
| 322 | + data: function (params) { | ||
| 323 | + return {nbbm: params.term}; | ||
| 324 | + }, | ||
| 325 | + processResults: function (data) { | ||
| 326 | + return { | ||
| 327 | + results: data | ||
| 328 | + }; | ||
| 329 | + }, | ||
| 330 | + cache: true | ||
| 331 | + }, | ||
| 332 | + templateResult: function (repo) { | ||
| 333 | + if (repo.loading) return repo.text; | ||
| 334 | + var h = '<span>' + repo.text + '</span>'; | ||
| 335 | + h += (repo.lineName ? ' <span class="select2-desc">' + repo.lineName + '</span>' : ''); | ||
| 336 | + return h; | ||
| 337 | + }, | ||
| 338 | + escapeMarkup: function (markup) { | ||
| 339 | + return markup; | ||
| 340 | + }, | ||
| 341 | + minimumInputLength: 1, | ||
| 342 | + templateSelection: function (repo) { | ||
| 343 | + return repo.text; | ||
| 344 | + }, | ||
| 345 | + language: { | ||
| 346 | + noResults: function () { | ||
| 347 | + return '<span style="color:red;font-size: 12px;">没有搜索到车辆!</span>'; | ||
| 348 | + }, | ||
| 349 | + inputTooShort: function (e) { | ||
| 350 | + return '<span style="color:gray;font-size: 12px;"><i class="fa fa-search"></i> 输入自编号搜索车辆</span>'; | ||
| 351 | + }, | ||
| 352 | + searching: function () { | ||
| 353 | + return '<span style="color:gray;font-size: 12px;"> 正在搜索车辆...</span>'; | ||
| 354 | + } | ||
| 355 | + } | ||
| 356 | + }) | ||
| 357 | + | ||
| 358 | + //导入 | ||
| 359 | + $("#upload").on("click", function(){ | ||
| 360 | + $.get('upload_2412.html', function(m){$(pjaxContainer).append(m);}); | ||
| 361 | + }); | ||
| 362 | + | ||
| 363 | + //导出 | ||
| 364 | + $("#export").on("click", function () { | ||
| 365 | + if ($("#rq").val() != "") { | ||
| 366 | + var gsbm=$("#gsbm").val(); | ||
| 367 | +// var fgsbm=$("#fgsbm").val(); | ||
| 368 | +// if(gsbm=="" || gsbm==null || fgsbm=="" ||fgsbm==null){ | ||
| 369 | +// layer.msg('请选择公司和分公司.'); | ||
| 370 | +// if(gsbm=="" || gsbm==null){ | ||
| 371 | +// layer.msg('请选择公司.'); | ||
| 372 | +// return; | ||
| 373 | +// } | ||
| 374 | + var params = getParams(); | ||
| 375 | + | ||
| 376 | + params["type"] = "export"; | ||
| 377 | + $get('/jdl/query_2412', params, function (result) { | ||
| 378 | + window.open("/downloadFile/download?fileName=车辆充电量" + moment($("#rq").val()).format("YYYYMMDD")); | ||
| 379 | + }); | ||
| 380 | + } else { | ||
| 381 | + layer.msg('请选择日期.'); | ||
| 382 | + } | ||
| 383 | + }); | ||
| 384 | + | ||
| 385 | + function getParams(){ | ||
| 386 | + var gsbm=$("#gsbm").val(); | ||
| 387 | +// var fgsbm=$("#fgsbm").val(); | ||
| 388 | + var cells = $('tr.filter')[0].cells | ||
| 389 | + , params = {} | ||
| 390 | + , name; | ||
| 391 | + params["gsbm"] = gsbm; | ||
| 392 | +// params["fgsbm"] = fgsbm; | ||
| 393 | + params["fgsbm"] = '-1'; | ||
| 394 | + $.each(cells, function (i, cell) { | ||
| 395 | + var items = $('input,select', cell); | ||
| 396 | + for (var j = 0, item; item = items[j++];) { | ||
| 397 | + name = $(item).attr('name'); | ||
| 398 | + if (name) { | ||
| 399 | + params[name] = $(item).val(); | ||
| 400 | + } | ||
| 401 | + } | ||
| 402 | + }); | ||
| 403 | + return params; | ||
| 404 | + }; | ||
| 405 | + | ||
| 406 | + }); | ||
| 407 | + | ||
| 408 | +</script> | ||
| 409 | + | ||
| 410 | +<script id="jdl_2412_list" type="text/html"> | ||
| 411 | + {{each list as obj i}} | ||
| 412 | + <tr> | ||
| 413 | + <td style="vertical-align: middle;"> | ||
| 414 | + <!-- <input type="radio" name="id" class="group-checkable icheck" data-id="{{obj.id}}"> --> | ||
| 415 | + {{i + 1}} | ||
| 416 | + </td> | ||
| 417 | + <td>{{obj.rq}}</td> | ||
| 418 | + <td colspan="2">{{obj.nbbm}}</td> | ||
| 419 | + <td colspan="4">{{obj.jdl}}</td> | ||
| 420 | + <!-- <td colspan="2">{{obj.jdz}}</td> --> | ||
| 421 | + <!-- <td>{{obj.remarks}}</td> --> | ||
| 422 | + <td colspan="2"> | ||
| 423 | + <button class="btn btn-info btn-sm btn-Reception" data-date="{{obj.rq}}" data-nbbm="{{obj.nbbm}}"> | ||
| 424 | + <i class="fa fa-search"></i> 查看 | ||
| 425 | + </button> | ||
| 426 | + </td> | ||
| 427 | + </tr> | ||
| 428 | + {{/each}} | ||
| 429 | + {{if list.length == 0}} | ||
| 430 | + <tr> | ||
| 431 | + <td colspan=9><h6 class="muted">没有找到相关数据</h6></td> | ||
| 432 | + </tr> | ||
| 433 | + {{/if}} | ||
| 434 | +</script> | ||
| 0 | \ No newline at end of file | 435 | \ No newline at end of file |
src/main/resources/static/pages/electricity/jdl/upload_2412.html
0 → 100644
| 1 | +<div class="modal fade" id="uploadFile" tabindex="-1" role="basic" | ||
| 2 | + aria-hidden="true"> | ||
| 3 | + <div class="modal-dialog"> | ||
| 4 | + <div class="modal-content"> | ||
| 5 | + <div class="modal-header"> | ||
| 6 | + <button type="button" class="close" data-dismiss="modal" | ||
| 7 | + aria-hidden="true"></button> | ||
| 8 | + <h4 class="modal-title">导入Excel</h4> | ||
| 9 | + </div> | ||
| 10 | + <div class="modal-body"> | ||
| 11 | + <form class="form-horizontal" role="form" id="excelFile" method="post" | ||
| 12 | + action="" enctype="multipart/form-data"> | ||
| 13 | + <input type="hidden" name="groupType" value="3"> | ||
| 14 | + <div class="alert alert-danger display-hide"> | ||
| 15 | + <button class="close" data-close="alert"></button> | ||
| 16 | + 您的输入有误,请检查下面的输入项 | ||
| 17 | + </div> | ||
| 18 | + <div class="form-body"> | ||
| 19 | + <div class="form-group"> | ||
| 20 | + <div class="col-md-12"> | ||
| 21 | + <label class="col-md-3 control-label">充电站:</label> | ||
| 22 | + <select name="stationName" id="stationName_"> | ||
| 23 | + </select> | ||
| 24 | + </div> | ||
| 25 | + <div style="margin-top: 50px;width: 100%;height: 1px;"></div> | ||
| 26 | + <label class="col-md-3 control-label">选择文件</label> | ||
| 27 | + <div class="col-md-9"> | ||
| 28 | + <input type="file" name="file" id="file" | ||
| 29 | + accept="application/vnd.ms-excel"/> | ||
| 30 | + <input type="hidden" name="gsbm_" id="gsbm_"> | ||
| 31 | + <input type="hidden" name="gsName" id="gsName"> | ||
| 32 | + <input type="hidden" name="fgsbm_" id="fgsbm_"> | ||
| 33 | + <input type="hidden" name="fgsName" id="fgsName"> | ||
| 34 | + </div> | ||
| 35 | + </div> | ||
| 36 | + </div> | ||
| 37 | + </form> | ||
| 38 | + </div> | ||
| 39 | + <div class="modal-footer"> | ||
| 40 | + <button type="button" class="btn default" id="downLoad">下载模板</button> | ||
| 41 | + <button type="button" class="btn default" data-dismiss="modal">取消</button> | ||
| 42 | + <button type="button" class="btn btn-primary" id="submit">确认导入</button> | ||
| 43 | + </div> | ||
| 44 | + </div> | ||
| 45 | + </div> | ||
| 46 | +</div> | ||
| 47 | +<script id="res_tbody_temp" type="text/html"> | ||
| 48 | + | ||
| 49 | +</script> | ||
| 50 | +<script data-exclude=1> | ||
| 51 | + $(function() { | ||
| 52 | + var form = $('#excelFile'); | ||
| 53 | + var error = $('.alert-danger', form); | ||
| 54 | + | ||
| 55 | + $('#gsbm_').val($("#gsbm").val()); | ||
| 56 | + $('#gsName').val($("#gsbm").find("option:selected").text()); | ||
| 57 | +// $('#fgsbm_').val($("#fgsbm").val()); | ||
| 58 | +// $('#fgsName').val($("#fgsbm").find("option:selected").text()); | ||
| 59 | + $('#fgsbm_').val('-1'); | ||
| 60 | + $('#fgsName').val('全部车队'); | ||
| 61 | + | ||
| 62 | + $get('/jdl/queryJdlStationName', {}, function(array){ | ||
| 63 | + var text = ''; | ||
| 64 | + $.each(array, function(i, e){ | ||
| 65 | + text += '<option value="'+e+'">'+e+'</option>'; | ||
| 66 | + }); | ||
| 67 | + $('#stationName_').html(text); | ||
| 68 | + }); | ||
| 69 | + | ||
| 70 | + //modal 显示事件 | ||
| 71 | + $('#uploadFile').on('show.bs.modal', function(){ | ||
| 72 | + }) | ||
| 73 | + .modal('show'); | ||
| 74 | + | ||
| 75 | + $('#submit').on('click', function() { | ||
| 76 | + var j = layer.load(2); | ||
| 77 | + var param = {}; | ||
| 78 | + param.uploadDir = 'upload'; | ||
| 79 | + param["gsbm_"] = $('#gsbm_').val(); | ||
| 80 | + param["gsName"] = $('#gsName').val(); | ||
| 81 | + param["fgsbm_"] = $('#fgsbm_').val(); | ||
| 82 | + param["fgsName"] = $('#fgsName').val(); | ||
| 83 | + var stationName = $('#stationName_').val(); | ||
| 84 | + param["stationName"] = stationName; | ||
| 85 | + $.ajaxFileUpload({ | ||
| 86 | + url : '/jdl/uploadFile_2412', | ||
| 87 | + secureuri : false, | ||
| 88 | + fileElementId : 'file', | ||
| 89 | + dataType : 'json', | ||
| 90 | + data : param, | ||
| 91 | + success : function(data) { | ||
| 92 | + layer.close(j); | ||
| 93 | + alert(data.result); | ||
| 94 | +// alert("文件导入成功"); | ||
| 95 | + $('#uploadFile').modal('hide'); | ||
| 96 | + $('tr.filter .filter-submit').click(); | ||
| 97 | + }, | ||
| 98 | + error : function(data, status, e) { | ||
| 99 | + layer.close(j); | ||
| 100 | +// alert("文件导入失败"); | ||
| 101 | + var resText = data.responseText; | ||
| 102 | + if(data.responseText && data.responseText != ""){ | ||
| 103 | + resText = resText.slice(resText.indexOf('"result":"') + 10, resText.indexOf('"}')); | ||
| 104 | + alert(resText); | ||
| 105 | + } else { | ||
| 106 | + alert("文件导入失败"); | ||
| 107 | + } | ||
| 108 | + } | ||
| 109 | + }) | ||
| 110 | + }); | ||
| 111 | + | ||
| 112 | + $('#downLoad').on('click', function(){ | ||
| 113 | + window.open("/downloadFile/downloadModel?fileName=import_Jdl_2412"); | ||
| 114 | + }); | ||
| 115 | + | ||
| 116 | + function getCurrSelNode(){ | ||
| 117 | + return $.jstree.reference("#modules_tree").get_selected(true); | ||
| 118 | + } | ||
| 119 | + }); | ||
| 120 | +</script> | ||
| 0 | \ No newline at end of file | 121 | \ No newline at end of file |
src/main/resources/static/pages/electricity/list/add.html
| @@ -6,7 +6,7 @@ | @@ -6,7 +6,7 @@ | ||
| 6 | 6 | ||
| 7 | <ul class="page-breadcrumb breadcrumb"> | 7 | <ul class="page-breadcrumb breadcrumb"> |
| 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> |
| 9 | - <li><span class="active">用电管理</span> <i class="fa fa-circle"></i></li> | 9 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> |
| 10 | <li><a href="list.html" data-pjax>进出场电量</a> <i class="fa fa-circle"></i></li> | 10 | <li><a href="list.html" data-pjax>进出场电量</a> <i class="fa fa-circle"></i></li> |
| 11 | <li><span class="active">进出站电量信息编辑</span></li> | 11 | <li><span class="active">进出站电量信息编辑</span></li> |
| 12 | </ul> | 12 | </ul> |
src/main/resources/static/pages/electricity/list/list.html
| @@ -6,7 +6,7 @@ | @@ -6,7 +6,7 @@ | ||
| 6 | 6 | ||
| 7 | <ul class="page-breadcrumb breadcrumb"> | 7 | <ul class="page-breadcrumb breadcrumb"> |
| 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> |
| 9 | - <li><span class="active">用电管理</span> <i class="fa fa-circle"></i></li> | 9 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> |
| 10 | <li><span class="active">进出场存电量</span></li> | 10 | <li><span class="active">进出场存电量</span></li> |
| 11 | </ul> | 11 | </ul> |
| 12 | 12 |
src/main/resources/static/pages/forms/export/import_Jdl_2412.xls
0 → 100644
No preview for this file type
src/main/resources/static/pages/forms/statement/account.html
| @@ -21,12 +21,12 @@ | @@ -21,12 +21,12 @@ | ||
| 21 | <h1>驾驶员请求台账</h1> | 21 | <h1>驾驶员请求台账</h1> |
| 22 | </div> | 22 | </div> |
| 23 | </div> | 23 | </div> |
| 24 | - | ||
| 25 | -<div class="row"> | ||
| 26 | - <div class="col-md-12"> | ||
| 27 | - <div class="portlet light porttlet-fit bordered"> | ||
| 28 | - <div class="portlet-title"> | ||
| 29 | - <form class="form-inline" action=""> | 24 | + |
| 25 | +<div class="row"> | ||
| 26 | + <div class="col-md-12"> | ||
| 27 | + <div class="portlet light porttlet-fit bordered"> | ||
| 28 | + <div class="portlet-title"> | ||
| 29 | + <form class="form-inline" action=""> | ||
| 30 | <div style="display: inline-block;"> | 30 | <div style="display: inline-block;"> |
| 31 | <span class="item-label" style="width: 80px;">线路: </span> | 31 | <span class="item-label" style="width: 80px;">线路: </span> |
| 32 | <select class="form-control" name="line" id="line" style="width: 180px;"></select> | 32 | <select class="form-control" name="line" id="line" style="width: 180px;"></select> |
| @@ -45,10 +45,10 @@ | @@ -45,10 +45,10 @@ | ||
| 45 | 45 | ||
| 46 | <input class="btn btn-default" type="button" id="query" value="筛选"/> | 46 | <input class="btn btn-default" type="button" id="query" value="筛选"/> |
| 47 | <input class="btn btn-default" type="button" id="export" value="导出"/> | 47 | <input class="btn btn-default" type="button" id="export" value="导出"/> |
| 48 | - </div> | ||
| 49 | - </form> | ||
| 50 | - </div> | ||
| 51 | - <div class="portlet-body"> | 48 | + </div> |
| 49 | + </form> | ||
| 50 | + </div> | ||
| 51 | + <div class="portlet-body"> | ||
| 52 | <div class="table-container" style="margin-top: 10px;overflow:auto;min-width: 906px"> | 52 | <div class="table-container" style="margin-top: 10px;overflow:auto;min-width: 906px"> |
| 53 | <table class="table table-bordered table-hover table-checkable" id="forms"> | 53 | <table class="table table-bordered table-hover table-checkable" id="forms"> |
| 54 | <thead> | 54 | <thead> |
| @@ -65,25 +65,25 @@ | @@ -65,25 +65,25 @@ | ||
| 65 | 65 | ||
| 66 | </tbody> | 66 | </tbody> |
| 67 | </table> | 67 | </table> |
| 68 | - </div> | ||
| 69 | - </div> | ||
| 70 | - </div> | ||
| 71 | - </div> | ||
| 72 | -</div> | ||
| 73 | - | ||
| 74 | -<script> | 68 | + </div> |
| 69 | + </div> | ||
| 70 | + </div> | ||
| 71 | + </div> | ||
| 72 | +</div> | ||
| 73 | + | ||
| 74 | +<script> | ||
| 75 | $(function(){ | 75 | $(function(){ |
| 76 | $("#export").attr('disabled',"true"); | 76 | $("#export").attr('disabled',"true"); |
| 77 | 77 | ||
| 78 | 78 | ||
| 79 | - var reqCodeMap = {"0xA1": '请求恢复运营', "0xA2": '申请调档', "0xA3": '出场请求', "0xA5": '进场请求', "0xA7": '加油请求', "0x50": '车辆故障', "0x70": '路阻报告', "0x60": '事故报告', "0x11": '扣证纠纷', "0x12" : '报警'}; | ||
| 80 | - // 关闭左侧栏 | ||
| 81 | - if (!$('body').hasClass('page-sidebar-closed')) | 79 | + var reqCodeMap = {"0xA1": '请求恢复运营', "0xA2": '申请调档', "0xA3": '出场请求', "0xA5": '进场请求', "0xA7": '加油请求', "0x50": '车辆故障', "0x70": '路阻报告', "0x60": '事故报告', "0x11": '扣证纠纷', "0x12" : '报警', 0x21: '单车有人伤', 0x22: '单车无人伤', 0x23: '双车有人伤', 0x24: '双车无人伤'}; |
| 80 | + // 关闭左侧栏 | ||
| 81 | + if (!$('body').hasClass('page-sidebar-closed')) | ||
| 82 | $('.menu-toggler.sidebar-toggler').click(); | 82 | $('.menu-toggler.sidebar-toggler').click(); |
| 83 | - | ||
| 84 | - $("#date").datetimepicker({ | ||
| 85 | - format : 'YYYY-MM-DD', | ||
| 86 | - locale : 'zh-cn' | 83 | + |
| 84 | + $("#date").datetimepicker({ | ||
| 85 | + format : 'YYYY-MM-DD', | ||
| 86 | + locale : 'zh-cn' | ||
| 87 | }); | 87 | }); |
| 88 | 88 | ||
| 89 | /* $.get('/basic/lineCode2Name',function(result){ | 89 | /* $.get('/basic/lineCode2Name',function(result){ |
| @@ -229,23 +229,23 @@ | @@ -229,23 +229,23 @@ | ||
| 229 | +"-"+xlName+"-驾驶员请求台账"); | 229 | +"-"+xlName+"-驾驶员请求台账"); |
| 230 | }); | 230 | }); |
| 231 | }); | 231 | }); |
| 232 | - | ||
| 233 | - }); | ||
| 234 | -</script> | ||
| 235 | -<script type="text/html" id="list_account"> | ||
| 236 | - {{each list as obj i}} | ||
| 237 | - <tr> | 232 | + |
| 233 | + }); | ||
| 234 | +</script> | ||
| 235 | +<script type="text/html" id="list_account"> | ||
| 236 | + {{each list as obj i}} | ||
| 237 | + <tr> | ||
| 238 | <td>{{i+1}}</td> | 238 | <td>{{i+1}}</td> |
| 239 | <td>{{obj.xlName}}</td> | 239 | <td>{{obj.xlName}}</td> |
| 240 | <td>{{obj.clZbh}}</td> | 240 | <td>{{obj.clZbh}}</td> |
| 241 | <td>{{obj.company}}</td> | 241 | <td>{{obj.company}}</td> |
| 242 | <td>{{obj.requestType}}</td> | 242 | <td>{{obj.requestType}}</td> |
| 243 | - <td>{{obj.requestTime}}</td> | ||
| 244 | - </tr> | 243 | + <td>{{obj.requestTime}}</td> |
| 244 | + </tr> | ||
| 245 | {{/each}} | 245 | {{/each}} |
| 246 | {{if list.length == 0}} | 246 | {{if list.length == 0}} |
| 247 | <tr> | 247 | <tr> |
| 248 | <td colspan="6"><h6 class="muted">没有找到相关数据</h6></td> | 248 | <td colspan="6"><h6 class="muted">没有找到相关数据</h6></td> |
| 249 | </tr> | 249 | </tr> |
| 250 | - {{/if}} | 250 | + {{/if}} |
| 251 | </script> | 251 | </script> |
| 252 | \ No newline at end of file | 252 | \ No newline at end of file |
src/main/resources/static/pages/forms/statement/daily_yanshou.html
0 → 100644
| 1 | +<style type="text/css"> | ||
| 2 | + .table-bordered { | ||
| 3 | + border: 1px solid; } | ||
| 4 | + .table-bordered > thead > tr > th, | ||
| 5 | + .table-bordered > thead > tr > td, | ||
| 6 | + .table-bordered > tbody > tr > th, | ||
| 7 | + .table-bordered > tbody > tr > td, | ||
| 8 | + .table-bordered > tfoot > tr > th, | ||
| 9 | + .table-bordered > tfoot > tr > td { | ||
| 10 | + border: 1px solid; } | ||
| 11 | + .table-bordered > thead > tr > th, | ||
| 12 | + .table-bordered > thead > tr > td { | ||
| 13 | + border-bottom-width: 2px; } | ||
| 14 | + | ||
| 15 | + .table > tbody + tbody { | ||
| 16 | + border-top: 1px solid; } | ||
| 17 | +</style> | ||
| 18 | + | ||
| 19 | +<div class="page-head"> | ||
| 20 | + <div class="page-title"> | ||
| 21 | + <h1>班次日报表</h1> | ||
| 22 | + </div> | ||
| 23 | +</div> | ||
| 24 | + | ||
| 25 | +<div class="row"> | ||
| 26 | + <div class="col-md-12"> | ||
| 27 | + <div class="portlet light porttlet-fit bordered"> | ||
| 28 | + <div class="portlet-title"> | ||
| 29 | + <form class="form-inline" action=""> | ||
| 30 | + <div style="display: inline-block; margin-left: 33px;" id="gsdmDiv_daily"> | ||
| 31 | + <span class="item-label" style="width: 80px;">公司: </span> | ||
| 32 | + <select class="form-control" name="company" id="gsdmDaily" style="width: 180px;"></select> | ||
| 33 | + </div> | ||
| 34 | + <div style="display: inline-block; margin-left: 24px;" id="fgsdmDiv_daily"> | ||
| 35 | + <span class="item-label" style="width: 80px;">分公司: </span> | ||
| 36 | + <select class="form-control" name="subCompany" id="fgsdmDaily" style="width: 180px;"></select> | ||
| 37 | + </div> | ||
| 38 | + <div style="margin-top: 2px"></div> | ||
| 39 | + <div style="display: inline-block;margin-left: 33px;"> | ||
| 40 | + <span class="item-label" style="width: 80px;">线路: </span> | ||
| 41 | + <select class="form-control" name="line" id="line" style="width: 180px;"></select> | ||
| 42 | + </div> | ||
| 43 | + <div style="display: inline-block;margin-left: 24px;"> | ||
| 44 | + <span class="item-label" style="width: 80px;"> 时间: </span> | ||
| 45 | + <input class="form-control" type="text" id="date" style="width: 180px;"/> | ||
| 46 | + </div> | ||
| 47 | + <div class="form-group"> | ||
| 48 | + <input class="btn btn-default" type="button" id="query" value="筛选"/> | ||
| 49 | + <input class="btn btn-default" type="button" id="export" value="导出"/> | ||
| 50 | + </div> | ||
| 51 | + </form> | ||
| 52 | + </div> | ||
| 53 | + <div class="portlet-body"> | ||
| 54 | + <div class="table-container" style="margin-top: 10px;overflow:auto;min-width: 906px"> | ||
| 55 | + <table class="table table-bordered table-hover table-checkable" id="forms"> | ||
| 56 | + <thead> | ||
| 57 | + <tr> | ||
| 58 | + <th colspan="8">调度班次日报</th> | ||
| 59 | + </tr> | ||
| 60 | + <tr> | ||
| 61 | + <td>路线:</td> | ||
| 62 | + <td colspan="2"><span id="form_line"> </span></td> | ||
| 63 | + <td>时间:</td> | ||
| 64 | + <td colspan="4"><span id="form_date"> </span></td> | ||
| 65 | + </tr> | ||
| 66 | + <tr> | ||
| 67 | + <td>车辆</td> | ||
| 68 | + <td>工号</td> | ||
| 69 | + <td>姓名</td> | ||
| 70 | + <td>总公里</td> | ||
| 71 | + <td>空驶公里</td> | ||
| 72 | + <td>油耗</td> | ||
| 73 | + <td>班次</td> | ||
| 74 | + <td>班次(自动)</td> | ||
| 75 | + </tr> | ||
| 76 | + </thead> | ||
| 77 | + <tbody id="tbody"> | ||
| 78 | + | ||
| 79 | + </tbody> | ||
| 80 | + <tr> | ||
| 81 | + <td colspan="3">小计</td> | ||
| 82 | + <td><span id="total_zgl"> </span></td> | ||
| 83 | + <td><span id="total_ks"> </span></td> | ||
| 84 | + <td><span id="total_yh"> </span></td> | ||
| 85 | + <td><span id="total_bc"> </span></td> | ||
| 86 | + </tr> | ||
| 87 | + </table> | ||
| 88 | + </div> | ||
| 89 | + </div> | ||
| 90 | + </div> | ||
| 91 | + </div> | ||
| 92 | +</div> | ||
| 93 | + | ||
| 94 | +<script> | ||
| 95 | + $(function(){ | ||
| 96 | + | ||
| 97 | + // 关闭左侧栏 | ||
| 98 | + if (!$('body').hasClass('page-sidebar-closed')) | ||
| 99 | + $('.menu-toggler.sidebar-toggler').click(); | ||
| 100 | + | ||
| 101 | + $("#date").datetimepicker({ | ||
| 102 | + format : 'YYYY-MM-DD', | ||
| 103 | + locale : 'zh-cn' | ||
| 104 | + }); | ||
| 105 | + var fage=false; | ||
| 106 | + var xlList; | ||
| 107 | + var obj = []; | ||
| 108 | + | ||
| 109 | + | ||
| 110 | + $.get('/report/lineList',function(result){ | ||
| 111 | + xlList=result; | ||
| 112 | + $.get('/user/companyData', function(result){ | ||
| 113 | + obj = result; | ||
| 114 | + var options = ''; | ||
| 115 | + for(var i = 0; i < obj.length; i++){ | ||
| 116 | + options += '<option value="'+obj[i].companyCode+'">'+obj[i].companyName+'</option>'; | ||
| 117 | + } | ||
| 118 | + | ||
| 119 | + if(obj.length ==0){ | ||
| 120 | + $("#gsdmDiv_daily").css('display','none'); | ||
| 121 | + }else if(obj.length ==1){ | ||
| 122 | + $("#gsdmDiv_daily").css('display','none'); | ||
| 123 | + if(obj[0].children.length == 1 || obj[0].children.length ==0) | ||
| 124 | + $('#fgsdmDiv_daily').css('display','none'); | ||
| 125 | + } | ||
| 126 | + $('#gsdmDaily').html(options); | ||
| 127 | + updateCompany(); | ||
| 128 | + }); | ||
| 129 | + }) | ||
| 130 | + $("#gsdmDaily").on("change",updateCompany); | ||
| 131 | + function updateCompany(){ | ||
| 132 | + var company = $('#gsdmDaily').val(); | ||
| 133 | + var options = ''; | ||
| 134 | + for(var i = 0; i < obj.length; i++){ | ||
| 135 | + if(obj[i].companyCode == company){ | ||
| 136 | + var children = obj[i].children; | ||
| 137 | + for(var j = 0; j < children.length; j++){ | ||
| 138 | + options += '<option value="'+children[j].code+'">'+children[j].name+'</option>'; | ||
| 139 | + } | ||
| 140 | + } | ||
| 141 | + } | ||
| 142 | + $('#fgsdmDaily').html(options); | ||
| 143 | + } | ||
| 144 | + | ||
| 145 | + var tempData = {}; | ||
| 146 | + $.get('/report/lineList',function(xlList){ | ||
| 147 | + var data = []; | ||
| 148 | +// data.push({id: " ", text: "全部线路"}); | ||
| 149 | + $.get('/user/companyData', function(result){ | ||
| 150 | + for(var i = 0; i < result.length; i++){ | ||
| 151 | + var companyCode = result[i].companyCode; | ||
| 152 | + var children = result[i].children; | ||
| 153 | + for(var j = 0; j < children.length; j++){ | ||
| 154 | + var code = children[j].code; | ||
| 155 | + for(var k=0;k < xlList.length;k++ ){ | ||
| 156 | + if(xlList[k]["fgsbm"]==code && xlList[k]["gsbm"]==companyCode){ | ||
| 157 | + data.push({id: xlList[k]["xlbm"], text: xlList[k]["xlname"]}); | ||
| 158 | + tempData[xlList[k]["xlbm"]] = companyCode+":"+code; | ||
| 159 | + } | ||
| 160 | + } | ||
| 161 | + } | ||
| 162 | + } | ||
| 163 | + initPinYinSelect2('#line',data,''); | ||
| 164 | + | ||
| 165 | + }); | ||
| 166 | + }); | ||
| 167 | + | ||
| 168 | + $("#line").on("change", function(){ | ||
| 169 | + if($("#line").val() == " "){ | ||
| 170 | + $("#gsdmDaily").attr("disabled", false); | ||
| 171 | + $("#fgsdmDaily").attr("disabled", false); | ||
| 172 | + } else { | ||
| 173 | + var temp = (tempData[$("#line").val()] ? tempData[$("#line").val()] : " : ").split(":"); | ||
| 174 | + $("#gsdmDaily").val(temp[0]); | ||
| 175 | + updateCompany(); | ||
| 176 | + $("#fgsdmDaily").val(temp[1]); | ||
| 177 | + $("#gsdmDaily").attr("disabled", true); | ||
| 178 | + $("#fgsdmDaily").attr("disabled", true); | ||
| 179 | + } | ||
| 180 | + }); | ||
| 181 | + | ||
| 182 | + | ||
| 183 | + var line; | ||
| 184 | + var date; | ||
| 185 | + var gsdmDaily; | ||
| 186 | + var fgsdmDaily; | ||
| 187 | + var lineName=$("#select2-line-container").html(); | ||
| 188 | + $("#query").on("click",function(){ | ||
| 189 | + if($("#date").val() == null || $("#date").val().trim().length == 0){ | ||
| 190 | + layer.msg("请选择时间"); | ||
| 191 | + return; | ||
| 192 | + } | ||
| 193 | + line = $("#line").val(); | ||
| 194 | + date = $("#date").val(); | ||
| 195 | + gsdmDaily=$("#gsdmDaily").val(); | ||
| 196 | + fgsdmDaily = $("#fgsdmDaily").val(); | ||
| 197 | + lineName=$("#select2-line-container").html(); | ||
| 198 | + var i = layer.load(2); | ||
| 199 | + $get('/mcy_forms/daily',{gsdmDaily:gsdmDaily,fgsdmDaily:fgsdmDaily, line:line,date:date,type:'query'},function(result){ | ||
| 200 | + $("#form_line").text(lineName); | ||
| 201 | + $("#form_date").text(date); | ||
| 202 | + // 把数据填充到模版中 | ||
| 203 | + var tbodyHtml = template('dailyInfo',{list:result}); | ||
| 204 | + // 把渲染好的模版html文本追加到表格中 | ||
| 205 | + $('#tbody').html(tbodyHtml); | ||
| 206 | + layer.close(i); | ||
| 207 | + | ||
| 208 | + line = $("#line").val(); | ||
| 209 | + startDate = $("#startDate").val(); | ||
| 210 | + endDate = $("#endDate").val(); | ||
| 211 | + $("#sDate").text(startDate); | ||
| 212 | + $("#eDate").text(endDate); | ||
| 213 | + | ||
| 214 | + var total_zgl = 0,total_ks = 0; | ||
| 215 | + var total_yh = 0,total_bc = 0; | ||
| 216 | + | ||
| 217 | + $.each(result, function(i, obj) { | ||
| 218 | + total_zgl +=Number(obj.zlc*10000); | ||
| 219 | + total_ks +=Number(obj.jzl1*10000); | ||
| 220 | + total_yh += Number(obj.yh*10000); | ||
| 221 | + total_bc += Number(obj.bc); | ||
| 222 | + | ||
| 223 | + }); | ||
| 224 | + $("#total_zgl").text((total_zgl/10000).toFixed(3)); | ||
| 225 | + $("#total_ks").text((total_ks/10000).toFixed(3)); | ||
| 226 | + $("#total_yh").text((total_yh/10000).toFixed(2)); | ||
| 227 | + $("#total_bc").text(total_bc.toFixed(0)); | ||
| 228 | + | ||
| 229 | + var temp = {}; | ||
| 230 | + var today_account = 0; | ||
| 231 | + | ||
| 232 | + temp["line"] = $("#line").text(); | ||
| 233 | + $.each(result, function(i, obj) { | ||
| 234 | + if(moment(obj.schedule_date_str).format("YYYY-MM-DD") == moment(obj.startDate).format("YYYY-MM-DD")){ | ||
| 235 | + today_account++; | ||
| 236 | + } | ||
| 237 | + obj.updateDate = moment(obj.startDate).format("YYYY-MM-DD HH:mm:ss"); | ||
| 238 | + }); | ||
| 239 | + }) | ||
| 240 | + }); | ||
| 241 | + | ||
| 242 | + $("#export").on("click",function(){ | ||
| 243 | + if($("#date").val() == null || $("#date").val().trim().length == 0){ | ||
| 244 | + layer.msg("请选择时间"); | ||
| 245 | + return; | ||
| 246 | + } | ||
| 247 | + line = $("#line").val(); | ||
| 248 | + date = $("#date").val(); | ||
| 249 | + gsdmDaily=$("#gsdmDaily").val(); | ||
| 250 | + fgsdmDaily = $("#fgsdmDaily").val(); | ||
| 251 | + lineName=$("#select2-line-container").html(); | ||
| 252 | + var i = layer.load(2); | ||
| 253 | + $post('/mcy_export/dailyExport',{gsdmDaily:gsdmDaily,fgsdmDaily:fgsdmDaily,line:line,date:date,type:'export',lineName:lineName},function(result){ | ||
| 254 | + window.open("/downloadFile/download?fileName=" | ||
| 255 | + +moment(date).format("YYYYMMDD")+"-"+lineName+"-班次日报表"); | ||
| 256 | + layer.close(i); | ||
| 257 | + }); | ||
| 258 | + }); | ||
| 259 | +}); | ||
| 260 | +</script> | ||
| 261 | +<script type="text/html" id="dailyInfo"> | ||
| 262 | + {{each list as obj i}} | ||
| 263 | + <tr> | ||
| 264 | + <td>{{obj.zbh}}</td> | ||
| 265 | + <td>{{obj.jgh}}</td> | ||
| 266 | + <td>{{obj.jName}}</td> | ||
| 267 | + <td>{{obj.zlc}}</td> | ||
| 268 | + <td>{{obj.jzl1}}</td> | ||
| 269 | + <td>{{obj.yh}}</td> | ||
| 270 | + <td>{{obj.bc}}</td> | ||
| 271 | + <td> | ||
| 272 | + | ||
| 273 | + {{if obj.bc > 5}} | ||
| 274 | + {{obj.bc % 5}} | ||
| 275 | + {{else}} | ||
| 276 | + 0 | ||
| 277 | + {{/if}} | ||
| 278 | + | ||
| 279 | + </td> | ||
| 280 | + </tr> | ||
| 281 | + {{/each}} | ||
| 282 | + {{if list.length == 0}} | ||
| 283 | + <tr> | ||
| 284 | + <td colspan="7"><h6 class="muted">没有找到相关数据</h6></td> | ||
| 285 | + </tr> | ||
| 286 | + {{/if}} | ||
| 287 | +</script> | ||
| 0 | \ No newline at end of file | 288 | \ No newline at end of file |
src/main/resources/static/pages/home.html
| @@ -59,15 +59,16 @@ | @@ -59,15 +59,16 @@ | ||
| 59 | } | 59 | } |
| 60 | </style> | 60 | </style> |
| 61 | <div class="system_change_log"> | 61 | <div class="system_change_log"> |
| 62 | - <h2 style="text-indent: 35px;margin: 10px 0 5px;">2022-06-13 更新说明 Changelog</h2> | 62 | + <h2 style="text-indent: 35px;margin: 10px 0 5px;">2025-03-04 更新说明 Changelog</h2> |
| 63 | <br><br> | 63 | <br><br> |
| 64 | <ul > | 64 | <ul > |
| 65 | - <li class="sub_title"><h6>系统安全</h6></li> | ||
| 66 | - <li><span class="label s_c_change">修改</span>1.登录密码错误2次加验证码,错4次锁定10分钟,管理员可解锁</li> | ||
| 67 | - <li><span class="label s_c_change">修改</span>2.登录时做弱密码检查,存在弱密码在进入主页面后强制修改密码</li> | ||
| 68 | - <li><span class="label s_c_change">修改</span>3.密码规则必须满足有大小写字母+数字+特殊字符的8-16位密码,加入连续性字符验证,如不能出现123、abc样的连续字符</li> | ||
| 69 | - <li class="sub_title"><h6>油电氢</h6></li> | ||
| 70 | - <li><span class="label s_c_change">修改</span>1.完善了备车的油电氢逻辑,以解决新增的车队属性造成的干扰</li> | 65 | + <li class="sub_title"><h6>智能调度</h6></li> |
| 66 | + <li><span class="label s_c_change">修改</span>1.智能调度实发二次调整刷新页面-后续程序上会对这块进行更新,已撤销的班次,你手动再次撤销会刷新这个班次不会再提示无法撤销。</li> | ||
| 67 | + <li><span class="label s_c_change">修改</span>2.末二班车提示上线</li> | ||
| 68 | + <li><span class="label s_c_change">修改</span>3.交互屏催发接口修复</li> | ||
| 69 | + <li><span class="label s_c_change">修改</span>4.行车路单有未实到的班次,导出的时候显示计划公里</li> | ||
| 70 | + <li><span class="label s_c_change">修改</span>5.自动调度实发未发只判断有rfid的班次</li> | ||
| 71 | + | ||
| 71 | </ul> | 72 | </ul> |
| 72 | 73 | ||
| 73 | </div> | 74 | </div> |
src/main/resources/static/pages/mforms/linepassengerflows/linepassengerflow.html
| @@ -72,7 +72,7 @@ | @@ -72,7 +72,7 @@ | ||
| 72 | 72 | ||
| 73 | <script> | 73 | <script> |
| 74 | $(function(){ | 74 | $(function(){ |
| 75 | - var reqCodeMap = {"0xA1": '请求恢复运营', "0xA2": '申请调档', "0xA3": '出场请求', "0xA5": '进场请求', "0xA7": '加油请求', "0x50": '车辆故障', "0x70": '路阻报告', "0x60": '事故报告', "0x11": '扣证纠纷', "0x12" : '报警'}; | 75 | + var reqCodeMap = {"0xA1": '请求恢复运营', "0xA2": '申请调档', "0xA3": '出场请求', "0xA5": '进场请求', "0xA7": '加油请求', "0x50": '车辆故障', "0x70": '路阻报告', "0x60": '事故报告', "0x11": '扣证纠纷', "0x12" : '报警', 0x21: '单车有人伤', 0x22: '单车无人伤', 0x23: '双车有人伤', 0x24: '双车无人伤'}; |
| 76 | // 关闭左侧栏 | 76 | // 关闭左侧栏 |
| 77 | if (!$('body').hasClass('page-sidebar-closed')) | 77 | if (!$('body').hasClass('page-sidebar-closed')) |
| 78 | $('.menu-toggler.sidebar-toggler').click(); | 78 | $('.menu-toggler.sidebar-toggler').click(); |
src/main/resources/static/pages/mforms/turnoutrates/calcTurnoutrate.html
src/main/resources/static/pages/oil/add.html
| @@ -6,7 +6,7 @@ | @@ -6,7 +6,7 @@ | ||
| 6 | 6 | ||
| 7 | <ul class="page-breadcrumb breadcrumb"> | 7 | <ul class="page-breadcrumb breadcrumb"> |
| 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> |
| 9 | - <li><span class="active">用油管理</span> <i class="fa fa-circle"></i></li> | 9 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> |
| 10 | <li><a href="list_ph.html" data-pjax>进出场油量</a> <i class="fa fa-circle"></i></li> | 10 | <li><a href="list_ph.html" data-pjax>进出场油量</a> <i class="fa fa-circle"></i></li> |
| 11 | <li><span class="active">进出站油量信息编辑</span></li> | 11 | <li><span class="active">进出站油量信息编辑</span></li> |
| 12 | </ul> | 12 | </ul> |
src/main/resources/static/pages/oil/checkJyryList.html
| @@ -6,7 +6,7 @@ | @@ -6,7 +6,7 @@ | ||
| 6 | 6 | ||
| 7 | <ul class="page-breadcrumb breadcrumb"> | 7 | <ul class="page-breadcrumb breadcrumb"> |
| 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> |
| 9 | - <li><span class="active">用油管理</span> <i class="fa fa-circle"></i></li> | 9 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> |
| 10 | <li><span class="active">加油人员不符</span></li> | 10 | <li><span class="active">加油人员不符</span></li> |
| 11 | </ul> | 11 | </ul> |
| 12 | 12 |
src/main/resources/static/pages/oil/checkNbbmList.html
| @@ -6,7 +6,7 @@ | @@ -6,7 +6,7 @@ | ||
| 6 | 6 | ||
| 7 | <ul class="page-breadcrumb breadcrumb"> | 7 | <ul class="page-breadcrumb breadcrumb"> |
| 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> |
| 9 | - <li><span class="active">用油管理</span> <i class="fa fa-circle"></i></li> | 9 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> |
| 10 | <li><span class="active">加油车辆备卡</span></li> | 10 | <li><span class="active">加油车辆备卡</span></li> |
| 11 | </ul> | 11 | </ul> |
| 12 | 12 |
src/main/resources/static/pages/oil/cylAdd.html
| @@ -6,7 +6,7 @@ | @@ -6,7 +6,7 @@ | ||
| 6 | 6 | ||
| 7 | <ul class="page-breadcrumb breadcrumb"> | 7 | <ul class="page-breadcrumb breadcrumb"> |
| 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> |
| 9 | - <li><span class="active">用油管理</span> <i class="fa fa-circle"></i></li> | 9 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> |
| 10 | <li><a href="cylList.html" data-pjax>车辆存油</a> <i class="fa fa-circle"></i></li> | 10 | <li><a href="cylList.html" data-pjax>车辆存油</a> <i class="fa fa-circle"></i></li> |
| 11 | <li><span class="active">添加存油</span></li> | 11 | <li><span class="active">添加存油</span></li> |
| 12 | </ul> | 12 | </ul> |
src/main/resources/static/pages/oil/cylList.html
| @@ -6,7 +6,7 @@ | @@ -6,7 +6,7 @@ | ||
| 6 | 6 | ||
| 7 | <ul class="page-breadcrumb breadcrumb"> | 7 | <ul class="page-breadcrumb breadcrumb"> |
| 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> |
| 9 | - <li><span class="active">用油管理</span> <i class="fa fa-circle"></i></li> | 9 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> |
| 10 | <li><span class="active">车辆存油</span></li> | 10 | <li><span class="active">车辆存油</span></li> |
| 11 | </ul> | 11 | </ul> |
| 12 | 12 |
src/main/resources/static/pages/oil/history/list_lsdl.html
| @@ -14,7 +14,7 @@ | @@ -14,7 +14,7 @@ | ||
| 14 | 14 | ||
| 15 | <ul class="page-breadcrumb breadcrumb"> | 15 | <ul class="page-breadcrumb breadcrumb"> |
| 16 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | 16 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> |
| 17 | - <li><span class="active">用电管理</span> <i class="fa fa-circle"></i></li> | 17 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> |
| 18 | <li><span class="active">进出场存电量</span></li> | 18 | <li><span class="active">进出场存电量</span></li> |
| 19 | </ul> | 19 | </ul> |
| 20 | <div id="ll_lsoil_list" | 20 | <div id="ll_lsoil_list" |
src/main/resources/static/pages/oil/history/list_lsyl.html
| @@ -14,7 +14,7 @@ | @@ -14,7 +14,7 @@ | ||
| 14 | 14 | ||
| 15 | <ul class="page-breadcrumb breadcrumb"> | 15 | <ul class="page-breadcrumb breadcrumb"> |
| 16 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | 16 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> |
| 17 | - <li><span class="active">用油管理</span> <i class="fa fa-circle"></i></li> | 17 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> |
| 18 | <li><span class="active">进出场存油量</span></li> | 18 | <li><span class="active">进出场存油量</span></li> |
| 19 | </ul> | 19 | </ul> |
| 20 | <div id="ll_lsoil_list" | 20 | <div id="ll_lsoil_list" |
src/main/resources/static/pages/oil/jyglList.html
| @@ -8,7 +8,7 @@ | @@ -8,7 +8,7 @@ | ||
| 8 | 8 | ||
| 9 | <ul class="page-breadcrumb breadcrumb"> | 9 | <ul class="page-breadcrumb breadcrumb"> |
| 10 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | 10 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> |
| 11 | - <li><span class="active">用油管理</span> <i class="fa fa-circle"></i></li> | 11 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> |
| 12 | <li><span class="active">场外加油管理</span></li> | 12 | <li><span class="active">场外加油管理</span></li> |
| 13 | </ul> | 13 | </ul> |
| 14 | 14 |
src/main/resources/static/pages/oil/jyszList.html
| @@ -7,7 +7,7 @@ | @@ -7,7 +7,7 @@ | ||
| 7 | 7 | ||
| 8 | <ul class="page-breadcrumb breadcrumb"> | 8 | <ul class="page-breadcrumb breadcrumb"> |
| 9 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | 9 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> |
| 10 | - <li><span class="active">用油管理</span> <i class="fa fa-circle"></i></li> | 10 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> |
| 11 | <li><span class="active">场外加油设置</span></li> | 11 | <li><span class="active">场外加油设置</span></li> |
| 12 | </ul> | 12 | </ul> |
| 13 | <div class="row"> | 13 | <div class="row"> |
src/main/resources/static/pages/oil/list.html
| @@ -6,7 +6,7 @@ | @@ -6,7 +6,7 @@ | ||
| 6 | 6 | ||
| 7 | <ul class="page-breadcrumb breadcrumb"> | 7 | <ul class="page-breadcrumb breadcrumb"> |
| 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> |
| 9 | - <li><span class="active">用油管理</span> <i class="fa fa-circle"></i></li> | 9 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> |
| 10 | <li><span class="active">进出场存油量</span></li> | 10 | <li><span class="active">进出场存油量</span></li> |
| 11 | </ul> | 11 | </ul> |
| 12 | 12 |
src/main/resources/static/pages/oil/list_ph.html
| @@ -14,7 +14,7 @@ | @@ -14,7 +14,7 @@ | ||
| 14 | 14 | ||
| 15 | <ul class="page-breadcrumb breadcrumb"> | 15 | <ul class="page-breadcrumb breadcrumb"> |
| 16 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | 16 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> |
| 17 | - <li><span class="active">用油管理</span> <i class="fa fa-circle"></i></li> | 17 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> |
| 18 | <li><span class="active">进出场存油量</span></li> | 18 | <li><span class="active">进出场存油量</span></li> |
| 19 | </ul> | 19 | </ul> |
| 20 | <div id="ll_oil_list" | 20 | <div id="ll_oil_list" |
src/main/resources/static/pages/oil/oillist/list.html
| @@ -6,7 +6,7 @@ | @@ -6,7 +6,7 @@ | ||
| 6 | 6 | ||
| 7 | <ul class="page-breadcrumb breadcrumb"> | 7 | <ul class="page-breadcrumb breadcrumb"> |
| 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> | 8 | <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li> |
| 9 | - <li><span class="active">用油管理</span> <i class="fa fa-circle"></i></li> | 9 | + <li><span class="active">能耗管理</span> <i class="fa fa-circle"></i></li> |
| 10 | <li><span class="active">进出场存油量</span></li> | 10 | <li><span class="active">进出场存油量</span></li> |
| 11 | </ul> | 11 | </ul> |
| 12 | 12 |
src/main/resources/static/pages/permission/authorize_all/user_auth.html
| @@ -58,6 +58,7 @@ | @@ -58,6 +58,7 @@ | ||
| 58 | <li><label><input class="uk-checkbox" type="checkbox" data-event="form_changetochange"> 换人换车情况统计表</label></li> | 58 | <li><label><input class="uk-checkbox" type="checkbox" data-event="form_changetochange"> 换人换车情况统计表</label></li> |
| 59 | <li><label><input class="uk-checkbox" type="checkbox" data-event="form_repairReport"> 维修上报记录</label></li> | 59 | <li><label><input class="uk-checkbox" type="checkbox" data-event="form_repairReport"> 维修上报记录</label></li> |
| 60 | <li><label><input class="uk-checkbox" type="checkbox" data-event="form_loggerr_zndd"> 智能调度日志</label></li> | 60 | <li><label><input class="uk-checkbox" type="checkbox" data-event="form_loggerr_zndd"> 智能调度日志</label></li> |
| 61 | + <li><label><input class="uk-checkbox" type="checkbox" data-event="form_message_two"> 调度消息分析</label></li> | ||
| 61 | 62 | ||
| 62 | </ul> | 63 | </ul> |
| 63 | </div> | 64 | </div> |
| @@ -81,6 +82,7 @@ | @@ -81,6 +82,7 @@ | ||
| 81 | <li><label><input class="uk-checkbox" type="checkbox" data-event="tts_config"> TTS</label></li> | 82 | <li><label><input class="uk-checkbox" type="checkbox" data-event="tts_config"> TTS</label></li> |
| 82 | <li><label><input class="uk-checkbox" type="checkbox" data-event="signal_state"> 信号标记</label></li> | 83 | <li><label><input class="uk-checkbox" type="checkbox" data-event="signal_state"> 信号标记</label></li> |
| 83 | <li><label><input class="uk-checkbox" type="checkbox" data-event="kl_config"> 客流信息</label></li> | 84 | <li><label><input class="uk-checkbox" type="checkbox" data-event="kl_config"> 客流信息</label></li> |
| 85 | + <li><label><input class="uk-checkbox" type="checkbox" data-event="zndd_status"> 智能调度开关</label></li> | ||
| 84 | </ul> | 86 | </ul> |
| 85 | </div> | 87 | </div> |
| 86 | <div> | 88 | <div> |
src/main/resources/static/pages/permission/user/edit.html
| @@ -113,7 +113,7 @@ | @@ -113,7 +113,7 @@ | ||
| 113 | $("#agencies").attr('value',obj.agencies); | 113 | $("#agencies").attr('value',obj.agencies); |
| 114 | $("#jobCode").attr('value',obj.jobCode); | 114 | $("#jobCode").attr('value',obj.jobCode); |
| 115 | $("#realName").attr('value',obj.realName); | 115 | $("#realName").attr('value',obj.realName); |
| 116 | - $("#lastPwdDate").attr('value',obj.lastPwdDate); | 116 | + $("#lastPwdDate").attr('value',moment(obj.lastPwdDate).format('YYYY-MM-DD')); |
| 117 | $("#pwdValidPeriod").attr('value',obj.pwdValidPeriod); | 117 | $("#pwdValidPeriod").attr('value',obj.pwdValidPeriod); |
| 118 | /*$get('/role/all',null,function(result){ | 118 | /*$get('/role/all',null,function(result){ |
| 119 | $.each(result,function(i,r){ | 119 | $.each(result,function(i,r){ |
src/main/resources/static/pages/report/message/message_two.html
0 → 100644
| 1 | +<style type="text/css"> | ||
| 2 | + .table-bordered { | ||
| 3 | + border: 1px solid; } | ||
| 4 | + .table-bordered > thead > tr > th, | ||
| 5 | + .table-bordered > thead > tr > td, | ||
| 6 | + .table-bordered > tbody > tr > th, | ||
| 7 | + .table-bordered > tbody > tr > td, | ||
| 8 | + .table-bordered > tfoot > tr > th, | ||
| 9 | + .table-bordered > tfoot > tr > td { | ||
| 10 | + border: 1px solid; } | ||
| 11 | + .table-bordered > thead > tr > th, | ||
| 12 | + .table-bordered > thead > tr > td { | ||
| 13 | + border-bottom-width: 2px; } | ||
| 14 | + | ||
| 15 | + .table > tbody + tbody { | ||
| 16 | + border-top: 1px solid; } | ||
| 17 | +</style> | ||
| 18 | + | ||
| 19 | +<div class="page-head"> | ||
| 20 | + <div class="page-title"> | ||
| 21 | + <h1>调度消息分析</h1> | ||
| 22 | + </div> | ||
| 23 | +</div> | ||
| 24 | + | ||
| 25 | +<div class="row"> | ||
| 26 | + <div class="col-md-12"> | ||
| 27 | + <div class="portlet light porttlet-fit bordered"> | ||
| 28 | + <div class="portlet-title"> | ||
| 29 | + <form class="form-inline" action=""> | ||
| 30 | + <div style="display: inline-block;"> | ||
| 31 | + <span class="item-label" style="width: 80px;">线路: </span> | ||
| 32 | + <select class="form-control" name="line" id="line" style="width: 180px;"></select> | ||
| 33 | + </div> | ||
| 34 | + <div style="display: inline-block;margin-left: 15px;"> | ||
| 35 | + <span class="item-label" style="width: 80px;">时间: </span> | ||
| 36 | + <input class="form-control" type="text" id="date" style="width: 180px;"/> | ||
| 37 | + </div> | ||
| 38 | + <div style="display: inline-block;margin-left: 15px"> | ||
| 39 | + <span class="item-label" style="width: 140px;">内部编码: </span> | ||
| 40 | + <select class="form-control" name="code" id="code" style="width: 180px;"></select> | ||
| 41 | + </div> | ||
| 42 | + <div class="form-group" style="display: inline-block;margin-left: 15px;"> | ||
| 43 | + <input class="btn btn-default" type="button" id="query" value="查询"/> | ||
| 44 | + <input class="btn btn-default" type="button" id="export" value="导出"/> | ||
| 45 | +<!-- <input class="btn btn-default" type="button" id="print" value="打印"/> --> | ||
| 46 | +<!-- <input class="btn btn-default" type="button" id="exportMore" value="批量导出"/> --> | ||
| 47 | + </div> | ||
| 48 | + </form> | ||
| 49 | + </div> | ||
| 50 | + <div class="portlet-body"> | ||
| 51 | + <div class="row"> | ||
| 52 | + <div class="col-md-3"> | ||
| 53 | + <div class="" id="left_table" style="margin-top: 10px;overflow:auto;height: 860px"> | ||
| 54 | + <table class="table table-bordered table-hover table-checkable pre-scrollable" id="info_msg"> | ||
| 55 | + <thead> | ||
| 56 | + <tr class="hidden"> | ||
| 57 | + <th>线路</th> | ||
| 58 | + <th>自编号</th> | ||
| 59 | + <th>路牌</th> | ||
| 60 | + <th>请求次数</th> | ||
| 61 | + </tr> | ||
| 62 | + </thead> | ||
| 63 | + <tbody> | ||
| 64 | + | ||
| 65 | + </tbody> | ||
| 66 | + </table> | ||
| 67 | + </div> | ||
| 68 | + </div> | ||
| 69 | + <div class="col-md-9" id="printArea"> | ||
| 70 | + <div class="table-container" id="table" style="margin-top: 10px;overflow:auto;min-width: 906px"> | ||
| 71 | + <table class="table table-bordered table-hover table-checkable" id="forms"> | ||
| 72 | + <thead> | ||
| 73 | + <tr class="hidden"> | ||
| 74 | + <th>序号</th> | ||
| 75 | + <th>线路</th> | ||
| 76 | +<!-- <th>路牌</th> --> | ||
| 77 | + <th>运营车辆</th> | ||
| 78 | + <th>发送人</th> | ||
| 79 | + <th>发送时间</th> | ||
| 80 | + <th>收到时间</th> | ||
| 81 | + <th>确认时间</th> | ||
| 82 | + <th>调度消息内容</th> | ||
| 83 | + </tr> | ||
| 84 | + </thead> | ||
| 85 | + <tbody> | ||
| 86 | + | ||
| 87 | + </tbody> | ||
| 88 | + </table> | ||
| 89 | + </div> | ||
| 90 | + </div> | ||
| 91 | + </div> | ||
| 92 | + </div> | ||
| 93 | + </div> | ||
| 94 | + </div> | ||
| 95 | +</div> | ||
| 96 | + | ||
| 97 | +<script> | ||
| 98 | + $(function(){ | ||
| 99 | + $('#print').attr('disabled', "true"); | ||
| 100 | + $('#export').attr('disabled', "true"); | ||
| 101 | + $('#printArea').hide(); | ||
| 102 | + | ||
| 103 | + // 关闭左侧栏 | ||
| 104 | + if (!$('body').hasClass('page-sidebar-closed')) | ||
| 105 | + $('.menu-toggler.sidebar-toggler').click(); | ||
| 106 | + | ||
| 107 | + $("#date").datetimepicker({ | ||
| 108 | + format : 'YYYY-MM-DD', | ||
| 109 | + locale : 'zh-cn' | ||
| 110 | + }); | ||
| 111 | + | ||
| 112 | + $("#left_table").height($(window).height()-100); | ||
| 113 | + $("#table").height($(window).height()-100); | ||
| 114 | + | ||
| 115 | + var d = new Date(); | ||
| 116 | + var year = d.getFullYear(); | ||
| 117 | + var month = d.getMonth() + 1; | ||
| 118 | + var day = d.getDate(); | ||
| 119 | + if(month < 9) | ||
| 120 | + month = "0" + month; | ||
| 121 | + if(day < 9) | ||
| 122 | + day = "0" + day; | ||
| 123 | + $("#date").val(year + "-" + month + "-" + day); | ||
| 124 | + | ||
| 125 | + $.get('/report/lineList',function(xlList){ | ||
| 126 | + var data = []; | ||
| 127 | + $.get('/user/companyData', function(result){ | ||
| 128 | + for(var i = 0; i < result.length; i++){ | ||
| 129 | + var companyCode = result[i].companyCode; | ||
| 130 | + var children = result[i].children; | ||
| 131 | + for(var j = 0; j < children.length; j++){ | ||
| 132 | + var code = children[j].code; | ||
| 133 | + for(var k=0;k < xlList.length;k++ ){ | ||
| 134 | + if(xlList[k]["fgsbm"]==code && xlList[k]["gsbm"]==companyCode){ | ||
| 135 | + data.push({id: xlList[k]["xlbm"], text: xlList[k]["xlname"]}); | ||
| 136 | + } | ||
| 137 | + } | ||
| 138 | + } | ||
| 139 | + } | ||
| 140 | + initPinYinSelect2('#line',data,''); | ||
| 141 | + | ||
| 142 | + }); | ||
| 143 | + }); | ||
| 144 | + $('#code').select2({ | ||
| 145 | + ajax: { | ||
| 146 | + url: '/realSchedule/sreachVehic', | ||
| 147 | + dataType: 'json', | ||
| 148 | + delay: 150, | ||
| 149 | + data: function(params){ | ||
| 150 | + return{nbbm: params.term}; | ||
| 151 | + }, | ||
| 152 | + processResults: function (data) { | ||
| 153 | + return { | ||
| 154 | + results: data | ||
| 155 | + }; | ||
| 156 | + }, | ||
| 157 | + cache: true | ||
| 158 | + }, | ||
| 159 | + templateResult: function(repo){ | ||
| 160 | + if (repo.loading) return repo.text; | ||
| 161 | + var h = '<span>'+repo.text+'</span>'; | ||
| 162 | + h += (repo.lineName?' <span class="select2-desc">'+repo.lineName+'</span>':''); | ||
| 163 | + return h; | ||
| 164 | + }, | ||
| 165 | + escapeMarkup: function (markup) { return markup; }, | ||
| 166 | + minimumInputLength: 1, | ||
| 167 | + templateSelection: function(repo){ | ||
| 168 | + return repo.text; | ||
| 169 | + }, | ||
| 170 | + language: { | ||
| 171 | + noResults: function(){ | ||
| 172 | + return '<span style="color:red;font-size: 12px;">没有搜索到车辆!</span>'; | ||
| 173 | + }, | ||
| 174 | + inputTooShort : function(e) { | ||
| 175 | + return '<span style="color:gray;font-size: 12px;"><i class="fa fa-search"></i> 输入自编号搜索车辆</span>'; | ||
| 176 | + }, | ||
| 177 | + searching : function() { | ||
| 178 | + return '<span style="color:gray;font-size: 12px;"> 正在搜索车辆...</span>'; | ||
| 179 | + } | ||
| 180 | + } | ||
| 181 | + }); | ||
| 182 | + | ||
| 183 | + var date = ''; | ||
| 184 | + var line = $("#line").val(); | ||
| 185 | + var lineName = $('#line option:selected').text(); | ||
| 186 | + $("#query").on("click",function(){ | ||
| 187 | + if($("#date").val() == null || $("#date").val().trim().length == 0){ | ||
| 188 | + layer.msg("请选择时间!"); | ||
| 189 | + return; | ||
| 190 | + } | ||
| 191 | + $("#left_table").height($(window).height()-100); | ||
| 192 | + line = $("#line").val(); | ||
| 193 | + date = $("#date").val(); | ||
| 194 | + var code = $("#code").val(); | ||
| 195 | + $(".hidden").removeClass("hidden"); | ||
| 196 | + $get('/report/historyMessageCount',{line:line,date:date,code:code},function(result){ | ||
| 197 | + // 把数据填充到模版中 | ||
| 198 | + var tbodyHtml = template('list_msg_info',{list:result}); | ||
| 199 | + // 把渲染好的模版html文本追加到表格中 | ||
| 200 | + $('#info_msg tbody').html(tbodyHtml); | ||
| 201 | + | ||
| 202 | + $('#print').attr('disabled', "true"); | ||
| 203 | + $('#export').attr('disabled', "true"); | ||
| 204 | + $('#printArea').hide(); | ||
| 205 | + | ||
| 206 | + }); | ||
| 207 | + }); | ||
| 208 | + | ||
| 209 | + var params = new Array(); | ||
| 210 | + var jName = ''; | ||
| 211 | + $("#info_msg tbody").on("click","tr",function(){ | ||
| 212 | + if($(this).children().size() < 2){ | ||
| 213 | + return; | ||
| 214 | + } | ||
| 215 | + $("#table").height($(window).height()-100); | ||
| 216 | + $(this).children().each(function(index){ | ||
| 217 | + params[index] = $(this).text(); | ||
| 218 | + }); | ||
| 219 | + jName = params[1]; | ||
| 220 | + line = $("#line").val(); | ||
| 221 | + date = $("#date").val(); | ||
| 222 | + lineName = $('#line option:selected').text(); | ||
| 223 | + var obj = $(this); | ||
| 224 | + $get('/report/historyMessageList',{line:line,date:date,code:jName,type:"query"},function(result){ | ||
| 225 | + | ||
| 226 | + result.forEach(function(item) { | ||
| 227 | + item[10] = moment(Date.parse(item[3]) + 1000*2).format('YYYY-MM-DD HH:mm:ss'); | ||
| 228 | + item[11] = moment(Date.parse(item[3]) + 1000*20).format('YYYY-MM-DD HH:mm:ss'); | ||
| 229 | + }) | ||
| 230 | + | ||
| 231 | + var list_history_msg = template('list_history_msg',{list:result}); | ||
| 232 | + // 把渲染好的模版html文本追加到表格中 | ||
| 233 | + $('#forms tbody').html(list_history_msg); | ||
| 234 | + | ||
| 235 | + if(result.length == 0){ | ||
| 236 | + $('#export').attr('disabled', "true"); | ||
| 237 | + $('#print').attr('disabled', "true"); | ||
| 238 | + } else { | ||
| 239 | + $("#export").removeAttr("disabled"); | ||
| 240 | + $("#print").removeAttr("disabled"); | ||
| 241 | + } | ||
| 242 | + $('#printArea').show(); | ||
| 243 | + | ||
| 244 | + $("#info_msg tbody tr").css('background-color', ''); | ||
| 245 | + obj.css('background-color', '#99CCFF'); | ||
| 246 | + }); | ||
| 247 | + }); | ||
| 248 | + | ||
| 249 | + $("#export").on("click",function(){ | ||
| 250 | + $get('/report/historyMessageList',{line:line,date:date,code:jName,type:"export_msg"},function(result){ | ||
| 251 | + window.open("/downloadFile/download?fileName=" | ||
| 252 | + +moment(date).format("YYYYMMDD")+"-"+lineName+"-调度消息分析"); | ||
| 253 | + }); | ||
| 254 | + }); | ||
| 255 | + | ||
| 256 | + $("#print").click(function(){ | ||
| 257 | + $("#printArea").printArea(); | ||
| 258 | + }); | ||
| 259 | + | ||
| 260 | + $("#exportMore").on("click",function(){ | ||
| 261 | + return; | ||
| 262 | + $post('/realSchedule/exportWaybillMore',{date:date},function(result){ | ||
| 263 | + window.open("/downloadFile/download?fileName="+jName); | ||
| 264 | + }); | ||
| 265 | + }); | ||
| 266 | + | ||
| 267 | + }); | ||
| 268 | +</script> | ||
| 269 | +<script type="text/html" id="list_msg_info"> | ||
| 270 | + {{each list as obj i}} | ||
| 271 | + <tr> | ||
| 272 | + <td width="25%">{{obj[0]}}\{{obj[1]}}</td> | ||
| 273 | + <td width="25%">{{obj[2]}}</td> | ||
| 274 | + <td width="25%">{{obj[1]}}</td> | ||
| 275 | + <td width="25%">{{obj[3]}}</td> | ||
| 276 | + </tr> | ||
| 277 | + {{/each}} | ||
| 278 | + {{if list.length == 0}} | ||
| 279 | + <tr> | ||
| 280 | + <td colspan="4"><h6 class="muted">没有找到相关数据</h6></td> | ||
| 281 | + </tr> | ||
| 282 | + {{/if}} | ||
| 283 | +</script> | ||
| 284 | +<script type="text/html" id="list_history_msg"> | ||
| 285 | + {{each list as obj i}} | ||
| 286 | + <tr> | ||
| 287 | + <td>{{i+1}}</td> | ||
| 288 | + <td>{{obj[0]}}</td> | ||
| 289 | + <!--<td>{{obj[6]}}</td>--> | ||
| 290 | + <td>{{obj[1]}}</td> | ||
| 291 | + <td>{{obj[2]}}</td> | ||
| 292 | + <td>{{obj[3]}}</td> | ||
| 293 | + <td>{{obj[10]}}</td> | ||
| 294 | + <td>{{obj[11]}}</td> | ||
| 295 | + <td>{{obj[4]}}</td> | ||
| 296 | + </tr> | ||
| 297 | + {{/each}} | ||
| 298 | + {{if list.length == 0}} | ||
| 299 | + <tr> | ||
| 300 | + <td colspan="7"><h6 class="muted">没有找到相关数据</h6></td> | ||
| 301 | + </tr> | ||
| 302 | + {{/if}} | ||
| 303 | +</script> |
src/main/resources/static/pages/report/sheet/calcList_yanshou.html
0 → 100644
| 1 | +<style type="text/css"> | ||
| 2 | + .table-bordered { | ||
| 3 | + border: 1px solid; } | ||
| 4 | + .table-bordered > thead > tr > th, | ||
| 5 | + .table-bordered > thead > tr > td, | ||
| 6 | + .table-bordered > tbody > tr > th, | ||
| 7 | + .table-bordered > tbody > tr > td, | ||
| 8 | + .table-bordered > tfoot > tr > th, | ||
| 9 | + .table-bordered > tfoot > tr > td { | ||
| 10 | + border: 1px solid; } | ||
| 11 | + .table-bordered > thead > tr > th, | ||
| 12 | + .table-bordered > thead > tr > td { | ||
| 13 | + border-bottom-width: 2px; } | ||
| 14 | + | ||
| 15 | + .table > tbody + tbody { | ||
| 16 | + border-top: 1px solid; } | ||
| 17 | +</style> | ||
| 18 | + | ||
| 19 | +<div class="page-head"> | ||
| 20 | + <div class="page-title" style="margin-left: 20px"> | ||
| 21 | + <button id="exportList">数据导出</button> | ||
| 22 | + </div> | ||
| 23 | +</div> | ||
| 24 | + | ||
| 25 | +<div class="row" id="calcSheetList"> | ||
| 26 | + <div class="col-md-12"> | ||
| 27 | + <div class="portlet light porttlet-fit bordered"> | ||
| 28 | + <div class="portlet-body"> | ||
| 29 | + <div class="table-container" style="margin-top: 10px;overflow:auto;min-width: 600px"> | ||
| 30 | + <table class="table table-bordered table-hover table-checkable" id="forms_2"> | ||
| 31 | + <thead> | ||
| 32 | + <tr> | ||
| 33 | + <td></td> | ||
| 34 | + <td>日期</td> | ||
| 35 | + <td>线路</td> | ||
| 36 | + <td>站点</td> | ||
| 37 | + <td>计划时间</td> | ||
| 38 | + <td>实际时间</td> | ||
| 39 | + <td>是否准点</td> | ||
| 40 | + <td>备注</td> | ||
| 41 | + </tr> | ||
| 42 | + </thead> | ||
| 43 | + | ||
| 44 | + <tbody> | ||
| 45 | + | ||
| 46 | + </tbody> | ||
| 47 | + </table> | ||
| 48 | + </div> | ||
| 49 | + </div> | ||
| 50 | + </div> | ||
| 51 | + </div> | ||
| 52 | +</div> | ||
| 53 | +<script src="/pages/mforms/singledatas/jquery.table2excel.min.js"></script> | ||
| 54 | +<script> | ||
| 55 | + $(function(){ | ||
| 56 | + // 关闭左侧栏 | ||
| 57 | + if (!$('body').hasClass('page-sidebar-closed')) | ||
| 58 | + $('.menu-toggler.sidebar-toggler').click(); | ||
| 59 | + var no=""; | ||
| 60 | + var dates=""; | ||
| 61 | + var dir=""; | ||
| 62 | + $("#calcSheetList").on('init', function (e, id) { | ||
| 63 | + no=id.split(",")[0]; | ||
| 64 | + dates = id.split(",")[1]; | ||
| 65 | + dir =id.split(",")[2]; | ||
| 66 | + var i = layer.load(2); | ||
| 67 | + $get('/calcSheet/calcSheet',{line:no,date:dates,dir:dir,type:'query'},function(result){ | ||
| 68 | + layer.close(i); | ||
| 69 | + var calcSheetList_2 = template('calcSheetList_2',{list:result}); | ||
| 70 | + $('#forms_2 tbody').html(calcSheetList_2); | ||
| 71 | + }); | ||
| 72 | + }) | ||
| 73 | + $("#exportList").on('click',function(){ | ||
| 74 | + var i = layer.load(2); | ||
| 75 | + var name=""; | ||
| 76 | + if(dir=="1"){ | ||
| 77 | + fileName="发车准点率"+dates; | ||
| 78 | + }else{ | ||
| 79 | + fileName="到站准点率"+dates; | ||
| 80 | + } | ||
| 81 | + $get('/calcSheet/calcSheet',{line:no,date:dates,dir:dir,type:'export'},function(result){ | ||
| 82 | + window.open("/downloadFile/download?fileName="+fileName); | ||
| 83 | + layer.close(i); | ||
| 84 | + }); | ||
| 85 | + }); | ||
| 86 | + | ||
| 87 | + | ||
| 88 | + }); | ||
| 89 | +</script> | ||
| 90 | +<script type="text/html" id="calcSheetList_2"> | ||
| 91 | + {{each list as obj i}} | ||
| 92 | + <tr {{if obj.sfzd!="准点"}}style="color: red" {{/if}}> | ||
| 93 | + <td>{{i+1}}</td> | ||
| 94 | + <td>{{obj.date}}</td> | ||
| 95 | + <td>{{obj.line}}</td> | ||
| 96 | + <td>{{obj.zdname}}</td> | ||
| 97 | + <td>{{obj.jhsj}}</td> | ||
| 98 | + <td>{{obj.sjsj}}</td> | ||
| 99 | + <td>{{obj.sfzd}}</td> | ||
| 100 | + <td>{{if i == 6}}自动调度{{/if}}</td> | ||
| 101 | + </tr> | ||
| 102 | + {{/each}} | ||
| 103 | + {{if list.length == 0}} | ||
| 104 | + <tr> | ||
| 105 | + <td colspan="7"><h6 class="muted">没有找到相关数据</h6></td> | ||
| 106 | + </tr> | ||
| 107 | + {{/if}} | ||
| 108 | +</script> | ||
| 0 | \ No newline at end of file | 109 | \ No newline at end of file |
src/main/resources/static/pages/report/timetable/timetable.html
| @@ -69,7 +69,7 @@ | @@ -69,7 +69,7 @@ | ||
| 69 | <td colspan="2" align="center">6:31-8:30</td> | 69 | <td colspan="2" align="center">6:31-8:30</td> |
| 70 | <td colspan="2" align="center">16:01-18:00</td> | 70 | <td colspan="2" align="center">16:01-18:00</td> |
| 71 | <td rowspan="2" style="text-align:center;vertical-align:middle;">总里程</td> | 71 | <td rowspan="2" style="text-align:center;vertical-align:middle;">总里程</td> |
| 72 | - <td rowspan="2" style="text-align:center;vertical-align:middle;">营业里程</td> | 72 | + <td rowspan="2" style="text-align:center;vertical-align:middle;">营运里程</td> |
| 73 | <td rowspan="2" style="text-align:center;vertical-align:middle;">空驶里程</td> | 73 | <td rowspan="2" style="text-align:center;vertical-align:middle;">空驶里程</td> |
| 74 | </tr> | 74 | </tr> |
| 75 | <tr> | 75 | <tr> |
| @@ -93,7 +93,7 @@ | @@ -93,7 +93,7 @@ | ||
| 93 | <td colspan="2"> 营运车时 (计划班次的营运时间/公里)</td> | 93 | <td colspan="2"> 营运车时 (计划班次的营运时间/公里)</td> |
| 94 | </tr> | 94 | </tr> |
| 95 | <tr> | 95 | <tr> |
| 96 | - <td colspan="2">营业里程/营运时间(小时)</td> | 96 | + <td colspan="2">营运里程/营运时间(小时)</td> |
| 97 | 97 | ||
| 98 | </tr> | 98 | </tr> |
| 99 | <tr> | 99 | <tr> |
src/main/resources/static/pages/scheduleApp/module/basicInfo/busInfoManage/detail.html
| @@ -307,7 +307,48 @@ | @@ -307,7 +307,48 @@ | ||
| 307 | 307 | ||
| 308 | 308 | ||
| 309 | <!-- 其他form-group --> | 309 | <!-- 其他form-group --> |
| 310 | + <div class="form-group"> | ||
| 311 | + <label class="col-md-2 control-label">最大乘坐人数:</label> | ||
| 312 | + <div class="col-md-4"> | ||
| 313 | + <input type="text" class="form-control" ng-model="ctrl.busInfoForSave.maxPeople" | ||
| 314 | + placeholder="请输入最大乘坐人数"/> | ||
| 315 | + </div> | ||
| 316 | + </div> | ||
| 317 | + <div class="form-group"> | ||
| 318 | + <label class="col-md-2 control-label">票价类型:</label> | ||
| 319 | + <div class="col-md-4"> | ||
| 320 | + <sa-Select5 name="priceType" | ||
| 321 | + model="ctrl.busInfoForSave" | ||
| 322 | + cmaps="{'priceType': 'code'}" | ||
| 323 | + dcname="priceType" | ||
| 324 | + icname="code" | ||
| 325 | + dsparams="{{ {type: 'dic', param: 'priceType' } | json }}" | ||
| 326 | + iterobjname="item" | ||
| 327 | + iterobjexp="item.name" | ||
| 328 | + searchph="请选择票价类型..." | ||
| 329 | + searchexp="this.name" | ||
| 330 | + > | ||
| 331 | + </sa-Select5> | ||
| 332 | + </div> | ||
| 333 | + </div> | ||
| 334 | + <div class="form-group"> | ||
| 335 | + <label class="col-md-2 control-label">票价:</label> | ||
| 336 | + <div class="col-md-4"> | ||
| 337 | + <input type="text" class="form-control" ng-model="ctrl.busInfoForSave.price" | ||
| 338 | + placeholder="请输入票价"/> | ||
| 339 | + </div> | ||
| 340 | + </div> | ||
| 341 | + | ||
| 342 | + </div> | ||
| 310 | 343 | ||
| 344 | + <div class="form-actions"> | ||
| 345 | + <div class="row"> | ||
| 346 | + <div class="col-md-offset-3 col-md-4"> | ||
| 347 | + <button type="submit" class="btn green" ng-disabled="!myForm.$valid"><i class="fa fa-check"></i> 提交</button> | ||
| 348 | + <a type="button" class="btn default" ui-sref="busInfoManage" ><i class="fa fa-times"></i> 取消</a> | ||
| 349 | + </div> | ||
| 350 | + </div> | ||
| 351 | + </div> | ||
| 311 | </div> | 352 | </div> |
| 312 | 353 | ||
| 313 | </form> | 354 | </form> |
src/main/resources/static/pages/scheduleApp/module/basicInfo/busInfoManage/edit.html
| @@ -477,6 +477,63 @@ | @@ -477,6 +477,63 @@ | ||
| 477 | 477 | ||
| 478 | <!-- 其他form-group --> | 478 | <!-- 其他form-group --> |
| 479 | 479 | ||
| 480 | + <div class="form-group"> | ||
| 481 | + <label class="col-md-2 control-label">颜色:</label> | ||
| 482 | + <div class="col-md-4"> | ||
| 483 | + <sa-Select5 name="color" | ||
| 484 | + model="ctrl.busInfoForSave" | ||
| 485 | + cmaps="{'color': 'code'}" | ||
| 486 | + dcname="color" | ||
| 487 | + icname="code" | ||
| 488 | + dsparams="{{ {type: 'dic', param: 'CarColor' } | json }}" | ||
| 489 | + iterobjname="item" | ||
| 490 | + iterobjexp="item.name" | ||
| 491 | + searchph="请选择车辆颜色..." | ||
| 492 | + searchexp="this.name" | ||
| 493 | + > | ||
| 494 | + </div> | ||
| 495 | + </div> | ||
| 496 | + <div class="form-group"> | ||
| 497 | + <label class="col-md-2 control-label">最大乘坐人数:</label> | ||
| 498 | + <div class="col-md-4"> | ||
| 499 | + <input type="text" class="form-control" ng-model="ctrl.busInfoForSave.maxPeople" | ||
| 500 | + placeholder="请输入最大乘坐人数"/> | ||
| 501 | + </div> | ||
| 502 | + </div> | ||
| 503 | + <div class="form-group"> | ||
| 504 | + <label class="col-md-2 control-label">票价类型:</label> | ||
| 505 | + <div class="col-md-4"> | ||
| 506 | + <sa-Select5 name="priceType" | ||
| 507 | + model="ctrl.busInfoForSave" | ||
| 508 | + cmaps="{'priceType': 'code'}" | ||
| 509 | + dcname="priceType" | ||
| 510 | + icname="code" | ||
| 511 | + dsparams="{{ {type: 'dic', param: 'priceType' } | json }}" | ||
| 512 | + iterobjname="item" | ||
| 513 | + iterobjexp="item.name" | ||
| 514 | + searchph="请选择票价类型..." | ||
| 515 | + searchexp="this.name" | ||
| 516 | + > | ||
| 517 | + </sa-Select5> | ||
| 518 | + </div> | ||
| 519 | + </div> | ||
| 520 | + <div class="form-group"> | ||
| 521 | + <label class="col-md-2 control-label">票价:</label> | ||
| 522 | + <div class="col-md-4"> | ||
| 523 | + <input type="text" class="form-control" ng-model="ctrl.busInfoForSave.price" | ||
| 524 | + placeholder="请输入票价"/> | ||
| 525 | + </div> | ||
| 526 | + </div> | ||
| 527 | + | ||
| 528 | + </div> | ||
| 529 | + | ||
| 530 | + <div class="form-actions"> | ||
| 531 | + <div class="row"> | ||
| 532 | + <div class="col-md-offset-3 col-md-4"> | ||
| 533 | + <button type="submit" class="btn green" ng-disabled="!myForm.$valid"><i class="fa fa-check"></i> 提交</button> | ||
| 534 | + <a type="button" class="btn default" ui-sref="busInfoManage" ><i class="fa fa-times"></i> 取消</a> | ||
| 535 | + </div> | ||
| 536 | + </div> | ||
| 480 | </div> | 537 | </div> |
| 481 | 538 | ||
| 482 | <div class="form-actions"> | 539 | <div class="form-actions"> |
src/main/resources/static/pages/scheduleApp/module/basicInfo/busInfoManage/form.html
| @@ -468,6 +468,53 @@ | @@ -468,6 +468,53 @@ | ||
| 468 | 468 | ||
| 469 | 469 | ||
| 470 | <!-- 其他form-group --> | 470 | <!-- 其他form-group --> |
| 471 | + <div class="form-group"> | ||
| 472 | + <label class="col-md-2 control-label">颜色:</label> | ||
| 473 | + <div class="col-md-4"> | ||
| 474 | + <sa-Select5 name="color" | ||
| 475 | + model="ctrl.busInfoForSave" | ||
| 476 | + cmaps="{'color': 'code'}" | ||
| 477 | + dcname="color" | ||
| 478 | + icname="code" | ||
| 479 | + dsparams="{{ {type: 'dic', param: 'CarColor' } | json }}" | ||
| 480 | + iterobjname="item" | ||
| 481 | + iterobjexp="item.name" | ||
| 482 | + searchph="请选择车辆颜色..." | ||
| 483 | + searchexp="this.name" | ||
| 484 | + > | ||
| 485 | + </div> | ||
| 486 | + </div> | ||
| 487 | + <div class="form-group"> | ||
| 488 | + <label class="col-md-2 control-label">最大乘坐人数:</label> | ||
| 489 | + <div class="col-md-4"> | ||
| 490 | + <input type="text" class="form-control" ng-model="ctrl.busInfoForSave.maxPeople" | ||
| 491 | + placeholder="请输入最大乘坐人数"/> | ||
| 492 | + </div> | ||
| 493 | + </div> | ||
| 494 | + <div class="form-group"> | ||
| 495 | + <label class="col-md-2 control-label">票价类型:</label> | ||
| 496 | + <div class="col-md-4"> | ||
| 497 | + <sa-Select5 name="priceType" | ||
| 498 | + model="ctrl.busInfoForSave" | ||
| 499 | + cmaps="{'priceType': 'code'}" | ||
| 500 | + dcname="priceType" | ||
| 501 | + icname="code" | ||
| 502 | + dsparams="{{ {type: 'dic', param: 'priceType' } | json }}" | ||
| 503 | + iterobjname="item" | ||
| 504 | + iterobjexp="item.name" | ||
| 505 | + searchph="请选择票价类型..." | ||
| 506 | + searchexp="this.name" | ||
| 507 | + > | ||
| 508 | + </sa-Select5> | ||
| 509 | + </div> | ||
| 510 | + </div> | ||
| 511 | + <div class="form-group"> | ||
| 512 | + <label class="col-md-2 control-label">票价:</label> | ||
| 513 | + <div class="col-md-4"> | ||
| 514 | + <input type="text" class="form-control" ng-model="ctrl.busInfoForSave.price" | ||
| 515 | + placeholder="请输入票价"/> | ||
| 516 | + </div> | ||
| 517 | + </div> | ||
| 471 | 518 | ||
| 472 | </div> | 519 | </div> |
| 473 | 520 |
src/main/resources/static/pages/scheduleApp/module/basicInfo/employeeInfoManage/edit.html
| @@ -164,8 +164,24 @@ | @@ -164,8 +164,24 @@ | ||
| 164 | </div> | 164 | </div> |
| 165 | 165 | ||
| 166 | </div> | 166 | </div> |
| 167 | - | ||
| 168 | - <!-- 其他form-group --> | 167 | + <div class="form-body"> |
| 168 | + <div class="form-group has-success has-feedback"> | ||
| 169 | + <label class="col-md-2 control-label">线路*:</label> | ||
| 170 | + <div class="col-md-3"> | ||
| 171 | + <sa-Select5 name="xl" | ||
| 172 | + model="ctrl.busConfigForSave" | ||
| 173 | + cmaps="{'xl.id': 'id', 'xl.name': 'name'}" | ||
| 174 | + dcname="xl.id" | ||
| 175 | + icname="id" | ||
| 176 | + dsparams="{{ {type: 'ajax', param:{type: 'all', 'destroy_eq': 0}, atype:'xl' } | json }}" | ||
| 177 | + iterobjname="item" | ||
| 178 | + iterobjexp="item.name" | ||
| 179 | + searchph="请输拼音..." | ||
| 180 | + searchexp="this.name" | ||
| 181 | + required > | ||
| 182 | + </sa-Select5> | ||
| 183 | + </div> | ||
| 184 | + </div> | ||
| 169 | 185 | ||
| 170 | </div> | 186 | </div> |
| 171 | 187 |
src/main/resources/static/pages/scheduleApp/module/basicInfo/employeeInfoManage/form.html
| @@ -163,7 +163,22 @@ | @@ -163,7 +163,22 @@ | ||
| 163 | </div> | 163 | </div> |
| 164 | 164 | ||
| 165 | </div> | 165 | </div> |
| 166 | - | 166 | + <div class="form-body"> |
| 167 | + <label class="col-md-2 control-label">熟悉线路信息*:</label> | ||
| 168 | + <div class="col-md-3"> | ||
| 169 | + <sa-Select5 name="xl" | ||
| 170 | + model="ctrl.busConfigForSave" | ||
| 171 | + cmaps="{'xl.id': 'id', 'xl.name': 'name'}" | ||
| 172 | + dcname="xl.id" | ||
| 173 | + icname="id" | ||
| 174 | + dsparams="{{ {type: 'ajax', param:{type: 'all', 'destroy_eq': 0}, atype:'xl' } | json }}" | ||
| 175 | + iterobjname="item" | ||
| 176 | + iterobjexp="item.name" | ||
| 177 | + searchph="请输拼音..." | ||
| 178 | + searchexp="this.name" | ||
| 179 | + required > | ||
| 180 | + </sa-Select5> | ||
| 181 | + </div> | ||
| 167 | <!-- 其他form-group --> | 182 | <!-- 其他form-group --> |
| 168 | 183 | ||
| 169 | </div> | 184 | </div> |
src/main/resources/static/pages/scheduleApp/module/core/guideboardManage/list.html
| @@ -34,7 +34,12 @@ | @@ -34,7 +34,12 @@ | ||
| 34 | <td> | 34 | <td> |
| 35 | <input type="text" class="form-control form-filter input-sm" ng-model="ctrl.searchCondition()['lpName_like']" placeholder="请输入路牌名字..."/> | 35 | <input type="text" class="form-control form-filter input-sm" ng-model="ctrl.searchCondition()['lpName_like']" placeholder="请输入路牌名字..."/> |
| 36 | </td> | 36 | </td> |
| 37 | - <td></td> | 37 | + <td> |
| 38 | + <select class="form-control"> | ||
| 39 | + <option>普通路牌</option> | ||
| 40 | + <option>特殊路牌</option> | ||
| 41 | + </select> | ||
| 42 | + </td> | ||
| 38 | <td> | 43 | <td> |
| 39 | <label class="checkbox-inline"> | 44 | <label class="checkbox-inline"> |
| 40 | <input type="checkbox" ng-model="ctrl.searchCondition()['isCancel_eq']"/>已作废 | 45 | <input type="checkbox" ng-model="ctrl.searchCondition()['isCancel_eq']"/>已作废 |
src/main/resources/static/pages/scheduleApp/module/core/guideboardManage/module.js
| @@ -385,7 +385,7 @@ angular.module('ScheduleApp').controller( | @@ -385,7 +385,7 @@ angular.module('ScheduleApp').controller( | ||
| 385 | 385 | ||
| 386 | // 当转向到此页面时,就获取明细信息并绑定 | 386 | // 当转向到此页面时,就获取明细信息并绑定 |
| 387 | Gb.get({id: id}, function(result) { | 387 | Gb.get({id: id}, function(result) { |
| 388 | - self.guideboardForDetail = result.data; | 388 | + self.guideboardForDetail = result; |
| 389 | self.title = "路牌 " + self.guideboardForDetail.lpName + " 详细信息"; | 389 | self.title = "路牌 " + self.guideboardForDetail.lpName + " 详细信息"; |
| 390 | }); | 390 | }); |
| 391 | } | 391 | } |
src/main/resources/static/real_control_v2/css/main.css
| @@ -2265,7 +2265,7 @@ g.gps-wrap rect.twinkle[updown="1"] { | @@ -2265,7 +2265,7 @@ g.gps-wrap rect.twinkle[updown="1"] { | ||
| 2265 | } | 2265 | } |
| 2266 | .warning-color { | 2266 | .warning-color { |
| 2267 | border: 1px solid #e79a00; | 2267 | border: 1px solid #e79a00; |
| 2268 | - background-color: #7ecbe4; | 2268 | + background-color: #0b3b5e; |
| 2269 | font-size: 18px; | 2269 | font-size: 18px; |
| 2270 | } | 2270 | } |
| 2271 | 2271 | ||
| @@ -2313,7 +2313,7 @@ g.gps-wrap rect.twinkle[updown="1"] { | @@ -2313,7 +2313,7 @@ g.gps-wrap rect.twinkle[updown="1"] { | ||
| 2313 | } | 2313 | } |
| 2314 | 2314 | ||
| 2315 | .multi_plat_config .timer{ | 2315 | .multi_plat_config .timer{ |
| 2316 | - background-color: #0575c3ba; | 2316 | + background-color: #115281; |
| 2317 | font-size: 15px; | 2317 | font-size: 15px; |
| 2318 | color: white; | 2318 | color: white; |
| 2319 | text-align: center; | 2319 | text-align: center; |
| @@ -2329,4 +2329,20 @@ g.gps-wrap rect.twinkle[updown="1"] { | @@ -2329,4 +2329,20 @@ g.gps-wrap rect.twinkle[updown="1"] { | ||
| 2329 | left: 40%; | 2329 | left: 40%; |
| 2330 | top: 20%; | 2330 | top: 20%; |
| 2331 | background: rgba(255, 255, 255, 0.5); | 2331 | background: rgba(255, 255, 255, 0.5); |
| 2332 | +} | ||
| 2333 | +.dkl_msg_text{ | ||
| 2334 | + margin-top: 6px; | ||
| 2335 | + border: 1px solid #b5afb1; | ||
| 2336 | +} | ||
| 2337 | +.zndd_text_input_color{ | ||
| 2338 | + border-color: #8ec73b!important; | ||
| 2339 | + background: #fafff2!important; | ||
| 2340 | + color: #659f13!important; | ||
| 2341 | + | ||
| 2342 | +} | ||
| 2343 | + | ||
| 2344 | +#depsepDiv{ | ||
| 2345 | + width: 413px; | ||
| 2346 | + height: 300px; | ||
| 2347 | + overflow-y: scroll; | ||
| 2332 | } | 2348 | } |
| 2333 | \ No newline at end of file | 2349 | \ No newline at end of file |
src/main/resources/static/real_control_v2/css/north.css
src/main/resources/static/real_control_v2/fragments/line_schedule/context_menu/temp_sch/add_normal_recoder.html
0 → 100644
| 1 | +<!-- 临加班次form --> | ||
| 2 | +<script id="add_normal_sch-form-temp" type="text/html"> | ||
| 3 | + <form class="uk-form uk-form-horizontal add-sch-form"> | ||
| 4 | + <div class="uk-grid"> | ||
| 5 | + <div class="uk-width-1-2"> | ||
| 6 | + <div class="uk-form-row"> | ||
| 7 | + <label class="uk-form-label">班次类型</label> | ||
| 8 | + <div class="uk-form-controls"> | ||
| 9 | + <select class="form-control nt-dictionary" name="bcType" data-code="{{bcType}}" | ||
| 10 | + data-group=ScheduleType></select> | ||
| 11 | + </div> | ||
| 12 | + </div> | ||
| 13 | + </div> | ||
| 14 | + <div class="uk-width-1-2"> | ||
| 15 | + <div class="uk-form-row"> | ||
| 16 | + <label class="uk-form-label">上下行</label> | ||
| 17 | + <div class="uk-form-controls"> | ||
| 18 | + <select name="xlDir" id="xlDir"> | ||
| 19 | + <option value="0">上行</option> | ||
| 20 | + <option value="1">下行</option> | ||
| 21 | + </select> | ||
| 22 | + </div> | ||
| 23 | + </div> | ||
| 24 | + </div> | ||
| 25 | + </div> | ||
| 26 | + <div class="uk-grid"> | ||
| 27 | + <div class="uk-width-1-2"> | ||
| 28 | + <div class="uk-form-row"> | ||
| 29 | + <label class="uk-form-label">起点站</label> | ||
| 30 | + <div class="uk-form-controls"> | ||
| 31 | + <select name="qdzCode" id="qdzCode"> | ||
| 32 | + </select> | ||
| 33 | + </div> | ||
| 34 | + </div> | ||
| 35 | + </div> | ||
| 36 | + <div class="uk-width-1-2"> | ||
| 37 | + <div class="uk-form-row"> | ||
| 38 | + <label class="uk-form-label">终点站</label> | ||
| 39 | + <div class="uk-form-controls"> | ||
| 40 | + <select name="zdzCode" id="zdzCode"> | ||
| 41 | + </select> | ||
| 42 | + </div> | ||
| 43 | + </div> | ||
| 44 | + </div> | ||
| 45 | + </div> | ||
| 46 | + <div class="uk-grid"> | ||
| 47 | + <div class="uk-width-1-2"> | ||
| 48 | + <div class="uk-form-row"> | ||
| 49 | + <label class="uk-form-label">开始时间</label> | ||
| 50 | + <div class="uk-form-controls"> | ||
| 51 | + <input type="time" value="{{zdsjActual==null?zdsj:zdsjActual}}" name="fcsj" required> | ||
| 52 | + </div> | ||
| 53 | + </div> | ||
| 54 | + </div> | ||
| 55 | + <div class="uk-width-1-2"> | ||
| 56 | + <div class="uk-form-row"> | ||
| 57 | + <label class="uk-form-label">结束时间</label> | ||
| 58 | + <div class="uk-form-controls"> | ||
| 59 | + <input type="time" name="zdsj" required> | ||
| 60 | + </div> | ||
| 61 | + </div> | ||
| 62 | + </div> | ||
| 63 | + </div> | ||
| 64 | + <div class="uk-grid"> | ||
| 65 | + <div class="uk-width-1-2"> | ||
| 66 | + <div class="uk-form-row"> | ||
| 67 | + <label class="uk-form-label">车辆</label> | ||
| 68 | + <div class="uk-form-controls"> | ||
| 69 | + <div class="uk-autocomplete uk-form car-autocom"> | ||
| 70 | + <input type="text" value="{{clZbh}}" name="clZbh" required> | ||
| 71 | + </div> | ||
| 72 | + </div> | ||
| 73 | + </div> | ||
| 74 | + </div> | ||
| 75 | + <div class="uk-width-1-2"> | ||
| 76 | + <div class="uk-form-row"> | ||
| 77 | + <label class="uk-form-label">里程</label> | ||
| 78 | + <div class="uk-form-controls"> | ||
| 79 | + <input type="text" name="jhlc" value="{{jhlc}}" max=400 data-fv-lessthan-inclusive="false" | ||
| 80 | + required> | ||
| 81 | + </div> | ||
| 82 | + </div> | ||
| 83 | + </div> | ||
| 84 | + </div> | ||
| 85 | + <div class="uk-grid"> | ||
| 86 | + <div class="uk-width-1-2"> | ||
| 87 | + <div class="uk-form-row"> | ||
| 88 | + <label class="uk-form-label">驾驶员</label> | ||
| 89 | + <div class="uk-form-controls"> | ||
| 90 | + <div class="uk-autocomplete uk-form jsy-autocom"> | ||
| 91 | + <input type="text" value="{{jGh}}/{{jName}}" name="jsy" required> | ||
| 92 | + </div> | ||
| 93 | + </div> | ||
| 94 | + </div> | ||
| 95 | + </div> | ||
| 96 | + <div class="uk-width-1-2"> | ||
| 97 | + <div class="uk-form-row"> | ||
| 98 | + <label class="uk-form-label">售票员</label> | ||
| 99 | + <div class="uk-form-controls"> | ||
| 100 | + <div class="uk-autocomplete uk-form spy-autocom"> | ||
| 101 | + <input type="text" name="spy" value="{{sGh}}/{{sName}}"> | ||
| 102 | + </div> | ||
| 103 | + </div> | ||
| 104 | + </div> | ||
| 105 | + </div> | ||
| 106 | + </div> | ||
| 107 | + <div class="uk-grid"> | ||
| 108 | + <div class="uk-width-1-1"> | ||
| 109 | + <div class="uk-form-row"> | ||
| 110 | + <label class="uk-form-label">备注</label> | ||
| 111 | + <div class="uk-form-controls"> | ||
| 112 | + <div class="uk-autocomplete uk-form remarks-autocom"> | ||
| 113 | + <input type="text" name="remarks"> | ||
| 114 | + </div> | ||
| 115 | + </div> | ||
| 116 | + </div> | ||
| 117 | + </div> | ||
| 118 | + </div> | ||
| 119 | + <div class="uk-modal-footer uk-text-right" style="margin-bottom: -20px;"> | ||
| 120 | + <span class="ct_line_lp_badge"></span> | ||
| 121 | + <button type="button" class="uk-button uk-modal-close">取消</button> | ||
| 122 | + <button type="submit" class="uk-button uk-button-primary"><i class="uk-icon-check"></i> 保存 | ||
| 123 | + </button> | ||
| 124 | + </div> | ||
| 125 | + </form> | ||
| 126 | +</script> | ||
| 127 | +<script> | ||
| 128 | + (function () { | ||
| 129 | + var wrap = '#schedule-addsch-modal .normalCont', sch, nf, submitFun; | ||
| 130 | + | ||
| 131 | + $(wrap).on('init', function (e, data) { | ||
| 132 | + e.stopPropagation(); | ||
| 133 | + sch = data.sch; | ||
| 134 | + submitFun = data.submitFun; | ||
| 135 | + | ||
| 136 | + nf = addForm(); | ||
| 137 | + //提交 | ||
| 138 | + nf.on('success.form.fv', function (e) { | ||
| 139 | + e.preventDefault(); | ||
| 140 | + | ||
| 141 | + disabled_submit_btn(nf); | ||
| 142 | + var data = nf.serializeJSON(); | ||
| 143 | + submitFun(data, function (rs) { | ||
| 144 | + //前端数据更新 | ||
| 145 | + gb_schedule_table.insertSchedule(rs.t, rs.ts); | ||
| 146 | + $('#schedule-lj_zrw-modal .main-schedule-table').trigger('refresh', {sch: rs.t}); | ||
| 147 | + try { | ||
| 148 | + if(rs.t.bcType=='in' || rs.t.bcType=='out') | ||
| 149 | + gb_data_basic.reload_stat_park_data(); | ||
| 150 | + }catch (e){ | ||
| 151 | + console.log(e);} | ||
| 152 | + UIkit.modal('#schedule-addsch-modal').hide(); | ||
| 153 | + //更新路牌公里统计面板 | ||
| 154 | + gb_schedule_table.showLpMileageTipBySch(rs.t); | ||
| 155 | + }, function () { | ||
| 156 | + enable_submit_btn(nf); | ||
| 157 | + }); | ||
| 158 | + }); | ||
| 159 | + $('.ct_line_lp_badge', nf).html(sch.xlName + ', '+sch.lpName); | ||
| 160 | + }); | ||
| 161 | + | ||
| 162 | + function addForm() { | ||
| 163 | + var htmlStr = template('add_normal_sch-form-temp', sch); | ||
| 164 | + var f = $(htmlStr); | ||
| 165 | + $(wrap).append(f); | ||
| 166 | + //字典转换 | ||
| 167 | + dictionaryUtils.transformDom($('.nt-dictionary', f)); | ||
| 168 | + //validation | ||
| 169 | + f.formValidation({framework: 'uikit', locale: 'zh_CN'}); | ||
| 170 | + //autocomp | ||
| 171 | + f.trigger('init-autoCom'); | ||
| 172 | + | ||
| 173 | + $("#xlDir").val(sch.xlDir); | ||
| 174 | + $f('bcType', f).trigger('change'); | ||
| 175 | + $("#qdzCode").val(sch.qdzCode); | ||
| 176 | + $("#zdzCode").val(sch.zdzCode); | ||
| 177 | + $f('zdzCode', f).trigger('change'); | ||
| 178 | + return f; | ||
| 179 | + } | ||
| 180 | + | ||
| 181 | + function $f(name, f) { | ||
| 182 | + return $('[name=' + name + ']', f); | ||
| 183 | + } | ||
| 184 | + })(); | ||
| 185 | +</script> | ||
| 0 | \ No newline at end of file | 186 | \ No newline at end of file |
src/main/resources/static/real_control_v2/fragments/line_schedule/context_menu/temp_sch/main_recorder.html
0 → 100644
| 1 | +<div class="uk-modal ct-form-modal ct_move_modal" id="schedule-addsch-modal"> | ||
| 2 | + <div class="uk-modal-dialog" style="width: 800px;"> | ||
| 3 | + <a href="" class="uk-modal-close uk-close"></a> | ||
| 4 | + <div class="uk-modal-header"> | ||
| 5 | + <h2>新增临加班次</h2></div> | ||
| 6 | + | ||
| 7 | + <div class="uk-grid"> | ||
| 8 | + <div class="uk-width-1-4"> | ||
| 9 | + <ul data-uk-switcher="{connect:'#tempScheduleContent'}" class="uk-nav uk-nav-side left_tabs_lg"> | ||
| 10 | + <li data-handle="normal"><a>1、临加班次</a></li> | ||
| 11 | + <li data-handle="toAndFro"><a>2、往返</a></li> | ||
| 12 | + <li data-handle="parkToPark"><a>3、场到场</a></li> | ||
| 13 | + </ul> | ||
| 14 | + </div> | ||
| 15 | + <div class="uk-width-3-4"> | ||
| 16 | + <ul id="tempScheduleContent" class="uk-switcher"> | ||
| 17 | + <li class="normalCont"></li> | ||
| 18 | + <li class="toAndFroCont"></li> | ||
| 19 | + <li class="parkToParkCont"></li> | ||
| 20 | + </ul> | ||
| 21 | + </div> | ||
| 22 | + </div> | ||
| 23 | + </div> | ||
| 24 | + | ||
| 25 | + <script> | ||
| 26 | + (function () { | ||
| 27 | + var modal = '#schedule-addsch-modal', | ||
| 28 | + sch, stationRoutes, parks, information, carsArray, st_park_data; | ||
| 29 | + | ||
| 30 | + $(modal).on('init', function (e, data) { | ||
| 31 | + e.stopPropagation(); | ||
| 32 | + sch = data.sch; | ||
| 33 | + //站到场数据 | ||
| 34 | + st_park_data = gb_data_basic.get_stat_park_data()[sch.xlBm]; | ||
| 35 | + //站点路由 | ||
| 36 | + stationRoutes = gb_common.groupBy(gb_data_basic.stationRoutes(sch.xlBm).sort(function (a, b) { | ||
| 37 | + return a.stationRouteCode - b.stationRouteCode; | ||
| 38 | + }), 'directions'); | ||
| 39 | + //停车场 | ||
| 40 | + parks = gb_data_basic.simpleParksArray(); | ||
| 41 | + //线路标准 | ||
| 42 | + information = gb_data_basic.getLineInformation(sch.xlBm); | ||
| 43 | + //停车场排序,常用的放前面 | ||
| 44 | + parks = sort_parks(parks, information, st_park_data); | ||
| 45 | + //车辆信息 | ||
| 46 | + carsArray = gb_data_basic.carsArray(); | ||
| 47 | + | ||
| 48 | + var st_doms = gb_schedule_context_menu.get_add_sch_doms(); | ||
| 49 | + //normal | ||
| 50 | + $('.normalCont', modal).html(st_doms.normal_recoder_dom) | ||
| 51 | + .trigger('init', {sch: sch, submitFun: submit_temp_schedule_form}); | ||
| 52 | + | ||
| 53 | + //to and fro | ||
| 54 | + $('.toAndFroCont', modal).html(st_doms.two_way_recoder_dom) | ||
| 55 | + .trigger('init', {sch: sch, submitFun: submit_temp_schedule_form, stationRoutes: stationRoutes}); | ||
| 56 | + | ||
| 57 | + //park to park | ||
| 58 | + $('.parkToParkCont', modal).html(st_doms.park_to_park_dom) | ||
| 59 | + .trigger('init', {sch: sch, submitFun: submit_temp_schedule_form, parks: parks, carsArray: carsArray}); | ||
| 60 | + }); | ||
| 61 | + | ||
| 62 | + //init-autoCom | ||
| 63 | + $(modal).on('init-autoCom', '.add-sch-form', function () { | ||
| 64 | + //车辆 | ||
| 65 | + if(carsArray) | ||
| 66 | + gb_common.carAutocomplete($('.car-autocom', this), carsArray); | ||
| 67 | + //驾驶员 | ||
| 68 | + gb_common.personAutocomplete($('.jsy-autocom', this)); | ||
| 69 | + //售票员 | ||
| 70 | + gb_common.personAutocomplete($('.spy-autocom', this)); | ||
| 71 | + //备注补全 | ||
| 72 | + gb_common.remarksAutocomplete($('.remarks-autocom', this)); | ||
| 73 | + }); | ||
| 74 | + | ||
| 75 | + //班次类型 和 上下行 切换事件 | ||
| 76 | + $(modal).on('change', '.add-sch-form [name=bcType],.add-sch-form [name=xlDir]', reCalcInputs_type); | ||
| 77 | + //起终点站改变事件 | ||
| 78 | + $(modal).on('change', '[name=qdzCode],[name=zdzCode]', reCalcInputs_station); | ||
| 79 | + //开始时间和公里改变 | ||
| 80 | + $(modal).on('input', '.add-sch-form [name=fcsj],.add-sch-form [name=jhlc]', reCalcEndTime); | ||
| 81 | + | ||
| 82 | + | ||
| 83 | + function reCalcInputs_type() { | ||
| 84 | + var f = $(this).parents('.add-sch-form'); | ||
| 85 | + var bcType_e = $('[name=bcType]', f) | ||
| 86 | + , xlDir_e = $('[name=xlDir]', f); | ||
| 87 | + | ||
| 88 | + var routes = stationRoutes[xlDir_e.val()] | ||
| 89 | + , lastCode = routes[routes.length - 1].stationCode | ||
| 90 | + , opts = '', park_opts = ''; | ||
| 91 | + //station options | ||
| 92 | + $.each(routes, function () { | ||
| 93 | + opts += '<option value="' + this.stationCode + '">' + this.stationName + '</option>' | ||
| 94 | + }); | ||
| 95 | + //park options | ||
| 96 | + for(var i=0,p;p=parks[i++];) | ||
| 97 | + park_opts += '<option value="' + p.code + '">' + p.name + '</option>'; | ||
| 98 | + | ||
| 99 | + var qdz = $('[name=qdzCode]', f), zdz = $('[name=zdzCode]', f); | ||
| 100 | + //var time, mileage; | ||
| 101 | + switch (bcType_e.val()) { | ||
| 102 | + case 'out': | ||
| 103 | + qdz.html(park_opts).val(information.carPark); | ||
| 104 | + zdz.html(opts); | ||
| 105 | + break; | ||
| 106 | + case 'in': | ||
| 107 | + qdz.html(opts); | ||
| 108 | + zdz.html(park_opts).val(information.carPark); | ||
| 109 | + break; | ||
| 110 | + default: | ||
| 111 | + qdz.html(opts); | ||
| 112 | + zdz.html(opts).val(lastCode); | ||
| 113 | + } | ||
| 114 | + | ||
| 115 | + zdz.trigger('change'); | ||
| 116 | + f.trigger('ct_callback'); | ||
| 117 | + } | ||
| 118 | + | ||
| 119 | + function reCalcInputs_station() { | ||
| 120 | + var f = $(this).parents('form'), | ||
| 121 | + bcType = $('[name=bcType]', f).val(), | ||
| 122 | + qdzCode = $('[name=qdzCode]', f).val(), | ||
| 123 | + zdzCode =$('[name=zdzCode]', f).val(), | ||
| 124 | + startDate = $('[name=fcsj]', f).val(), | ||
| 125 | + upDown = $('[name=xlDir]', f).val(), mileage, time; | ||
| 126 | + | ||
| 127 | + //从站到场里获取数据 | ||
| 128 | + var stp = search_st_park(f); | ||
| 129 | + if(stp){ | ||
| 130 | + mileage=bcType=='in'?stp['mileage1']:stp['mileage2']; | ||
| 131 | + time=bcType=='in'?stp['time1']:stp['time2']; | ||
| 132 | + } | ||
| 133 | + else{ | ||
| 134 | + switch (upDown + '_' + bcType) { | ||
| 135 | + case '0_out'://上行出场 | ||
| 136 | + mileage = information.upOutMileage; | ||
| 137 | + time = information.upOutTimer; | ||
| 138 | + break; | ||
| 139 | + case '1_out'://下行出场 | ||
| 140 | + mileage = information.downOutMileage; | ||
| 141 | + time = information.downOutTimer; | ||
| 142 | + break; | ||
| 143 | + case '0_in'://上行进场 | ||
| 144 | + mileage = information.upInMileage; | ||
| 145 | + time = information.upInTimer; | ||
| 146 | + break; | ||
| 147 | + case '1_in'://下行进场 | ||
| 148 | + mileage = information.downInMileage; | ||
| 149 | + time = information.downInTimer; | ||
| 150 | + break; | ||
| 151 | + default: | ||
| 152 | + | ||
| 153 | + var qc_time=upDown==0?information.upTravelTime:information.downTravelTime, | ||
| 154 | + qc_mileage=upDown==0?information.upMileage:information.downMileage, _type; | ||
| 155 | + if(is_normal_sch(f)){ | ||
| 156 | + _type='normal'; | ||
| 157 | + mileage=qc_mileage; | ||
| 158 | + } | ||
| 159 | + else{ | ||
| 160 | + _type='region'; | ||
| 161 | + mileage = calcMileage(stationRoutes[upDown], qdzCode, zdzCode); | ||
| 162 | + } | ||
| 163 | + | ||
| 164 | + time = gb_common.mul(gb_common.accDiv(qc_time, qc_mileage), mileage); | ||
| 165 | + if(bcType!='ldks' && bcType!='major' && bcType!='venting') | ||
| 166 | + $('[name=bcType]', f).val(_type); | ||
| 167 | + } | ||
| 168 | + } | ||
| 169 | + | ||
| 170 | + $('[name=jhlc]', f).val(mileage); | ||
| 171 | + var et = moment(startDate, 'HH:mm').add(time, 'minutes'); | ||
| 172 | + $f('zdsj', f).val(et.format('HH:mm')); | ||
| 173 | + f.trigger('ct_callback'); | ||
| 174 | + } | ||
| 175 | + | ||
| 176 | + | ||
| 177 | + function reCalcEndTime() { | ||
| 178 | + var f = $(this).parents('.add-sch-form') | ||
| 179 | + , startDate = $f('fcsj', f).val()//开始时间 | ||
| 180 | + , mileage = $f('jhlc', f).val()//公里 | ||
| 181 | + , type2 = $f('bcType', f).val(),//班次类型 | ||
| 182 | + upDown = $('[name=xlDir]', f).val(); | ||
| 183 | + if (!startDate || !mileage) | ||
| 184 | + return; | ||
| 185 | + | ||
| 186 | + var time; | ||
| 187 | + //从站到场里获取数据 | ||
| 188 | + var stp = search_st_park(f); | ||
| 189 | + if(stp){ | ||
| 190 | + time=type2=='in'?stp['time1']:stp['time2']; | ||
| 191 | + } | ||
| 192 | + else{ | ||
| 193 | + if (type2 == 'in') | ||
| 194 | + time = upDown == 0 ? information.upInTimer : information.downInTimer; | ||
| 195 | + else if (type2 == 'out') | ||
| 196 | + time = upDown == 0 ? information.upOutTimer : information.downOutTimer; | ||
| 197 | + else{ | ||
| 198 | + var qc_time=upDown==0?information.upTravelTime:information.downTravelTime, | ||
| 199 | + qc_mileage=upDown==0?information.upMileage:information.downMileage; | ||
| 200 | + | ||
| 201 | + time = gb_common.mul(gb_common.accDiv(qc_time, qc_mileage), mileage); | ||
| 202 | + } | ||
| 203 | + } | ||
| 204 | + | ||
| 205 | + var et = moment(startDate, 'HH:mm').add(time, 'minutes'); | ||
| 206 | + $f('zdsj', f).val(et.format('HH:mm')); | ||
| 207 | + f.trigger('ct_callback'); | ||
| 208 | + } | ||
| 209 | + | ||
| 210 | + function is_normal_sch(f) { | ||
| 211 | + var qdzCode = $('[name=qdzCode]', f).val(), | ||
| 212 | + zdzCode =$('[name=zdzCode]', f).val(), | ||
| 213 | + upDown = $('[name=xlDir]', f).val(), | ||
| 214 | + rts = stationRoutes[upDown]; | ||
| 215 | + | ||
| 216 | + if(rts[0].stationCode == qdzCode | ||
| 217 | + && rts[rts.length - 1].stationCode == zdzCode) | ||
| 218 | + return true; | ||
| 219 | + else | ||
| 220 | + return false; | ||
| 221 | + } | ||
| 222 | + | ||
| 223 | + function isInOut(bcType) { | ||
| 224 | + return bcType=='in' || bcType=='out'; | ||
| 225 | + } | ||
| 226 | + | ||
| 227 | + /** | ||
| 228 | + * 计算线路上站点间公里 | ||
| 229 | + */ | ||
| 230 | + function calcMileage(rts, s, e) { | ||
| 231 | + var mileage = 0, flag, code; | ||
| 232 | + $.each(rts, function () { | ||
| 233 | + code = this['stationCode']; | ||
| 234 | + if (flag) | ||
| 235 | + mileage = gb_common.accAdd(mileage, this.distances); | ||
| 236 | + if (code == s) | ||
| 237 | + flag = true; | ||
| 238 | + if (code == e) | ||
| 239 | + return false; | ||
| 240 | + }); | ||
| 241 | + return mileage; | ||
| 242 | + } | ||
| 243 | + | ||
| 244 | + function search_st_park(f) { | ||
| 245 | + if(!st_park_data) | ||
| 246 | + return; | ||
| 247 | + var stp; | ||
| 248 | + var qdSelect=$f('qdzCode', f)[0],zdSelect=$f('zdzCode', f)[0]; | ||
| 249 | + | ||
| 250 | + if(qdSelect.options.selectedIndex < 0 || zdSelect.options.selectedIndex < 0) | ||
| 251 | + return; | ||
| 252 | + var qdzName=qdSelect.options[qdSelect.options.selectedIndex].text, | ||
| 253 | + zdzName=zdSelect.options[zdSelect.options.selectedIndex].text, | ||
| 254 | + type2 = $f('bcType', f).val(); | ||
| 255 | + | ||
| 256 | + if(!isInOut(type2)) | ||
| 257 | + return; | ||
| 258 | + | ||
| 259 | + $.each(st_park_data, function () { | ||
| 260 | + if((type2=='in' && this.stationName==qdzName && this.parkName==zdzName) | ||
| 261 | + || (type2=='out' && this.stationName==zdzName && this.parkName==qdzName)){ | ||
| 262 | + stp = this; | ||
| 263 | + return false; | ||
| 264 | + } | ||
| 265 | + }); | ||
| 266 | + | ||
| 267 | + return stp; | ||
| 268 | + } | ||
| 269 | + | ||
| 270 | + /** | ||
| 271 | + * 停车场排序 | ||
| 272 | + * @param parks 停车场 code 2 name | ||
| 273 | + * @param information 线路标准 | ||
| 274 | + * @param st_park_data 站到场 | ||
| 275 | + */ | ||
| 276 | + function sort_parks(parks, information, st_park_data) { | ||
| 277 | + var array = [], names=[]; | ||
| 278 | + for(var code in parks){ | ||
| 279 | + array.push({code: code, name: parks[code]}); | ||
| 280 | + } | ||
| 281 | + | ||
| 282 | + if(st_park_data && st_park_data.length > 0){ | ||
| 283 | + $.each(st_park_data, function () { | ||
| 284 | + names.push(this.parkName); | ||
| 285 | + }); | ||
| 286 | + } | ||
| 287 | + | ||
| 288 | + //debugger | ||
| 289 | + array.sort(function (a, b) { | ||
| 290 | + if(a.code==information.carPark) | ||
| 291 | + return -1; | ||
| 292 | + if(b.code==information.carPark) | ||
| 293 | + return 1; | ||
| 294 | + | ||
| 295 | + var ai = names.indexOf(a.name), | ||
| 296 | + bi = names.indexOf(b.name); | ||
| 297 | + | ||
| 298 | + if(ai!=-1 && bi==-1) | ||
| 299 | + return -1; | ||
| 300 | + else if(ai==-1 && bi!=-1) | ||
| 301 | + return 1; | ||
| 302 | + else | ||
| 303 | + return $.trim(a.name).localeCompare($.trim(b.name), 'zh-CN'); | ||
| 304 | + }); | ||
| 305 | + return array; | ||
| 306 | + } | ||
| 307 | + | ||
| 308 | + function $f(name, f) { | ||
| 309 | + return $('[name=' + name + ']', f); | ||
| 310 | + } | ||
| 311 | + | ||
| 312 | + /** | ||
| 313 | + * 提交表单 | ||
| 314 | + */ | ||
| 315 | + function submit_temp_schedule_form(data, cb, err) { | ||
| 316 | + data.xlBm = sch.xlBm; | ||
| 317 | + data.xlName = sch.xlName; | ||
| 318 | + data.lpName = sch.lpName; | ||
| 319 | + //拆分驾驶员工号和姓名 | ||
| 320 | + data.jGh = data.jsy.split('/')[0]; | ||
| 321 | + data.jName = data.jsy.split('/')[1]; | ||
| 322 | + delete data.jsy; | ||
| 323 | + //拆分售票员工号和姓名 | ||
| 324 | + if (data.spy != '') { | ||
| 325 | + data.sGh = data.spy.split('/')[0]; | ||
| 326 | + data.sName = data.spy.split('/')[1]; | ||
| 327 | + delete data.spy; | ||
| 328 | + } | ||
| 329 | + | ||
| 330 | + //公司信息 | ||
| 331 | + var line = gb_data_basic.findLineByCodes([data.xlBm]); | ||
| 332 | + if(line && line.length > 0){ | ||
| 333 | + line = line[0]; | ||
| 334 | + data.gsBm = line.company; | ||
| 335 | + data.fgsBm = line.brancheCompany; | ||
| 336 | + } | ||
| 337 | + | ||
| 338 | + gb_common.$post('/realSchedule', data, function (rs) { | ||
| 339 | + notify_succ('新增临加班次成功'); | ||
| 340 | + cb && cb(rs); | ||
| 341 | + }, err); | ||
| 342 | + } | ||
| 343 | + })(); | ||
| 344 | + </script> | ||
| 345 | +</div> | ||
| 0 | \ No newline at end of file | 346 | \ No newline at end of file |
src/main/resources/static/real_control_v2/fragments/line_schedule/context_menu/temp_sch_v2/add_normal_znddType.html
0 → 100644
| 1 | +<!-- 临加班次form --> | ||
| 2 | +<script id="add_normal_sch-form-temp" type="text/html"> | ||
| 3 | + <form class="uk-form uk-form-horizontal add-sch-form"> | ||
| 4 | + <div class="uk-grid"> | ||
| 5 | + <div class="uk-width-1-2"> | ||
| 6 | + <div class="uk-form-row"> | ||
| 7 | + <label class="uk-form-label">班次类型</label> | ||
| 8 | + <div class="uk-form-controls"> | ||
| 9 | + <select class="form-control nt-dictionary" name="bcType" data-code="{{bcType}}" | ||
| 10 | + data-group=ScheduleType></select> | ||
| 11 | + </div> | ||
| 12 | + </div> | ||
| 13 | + </div> | ||
| 14 | + <div class="uk-width-1-2"> | ||
| 15 | + <div class="uk-form-row"> | ||
| 16 | + <label class="uk-form-label">上下行</label> | ||
| 17 | + <div class="uk-form-controls"> | ||
| 18 | + <select name="xlDir"> | ||
| 19 | + <option value="0">上行</option> | ||
| 20 | + <option value="1">下行</option> | ||
| 21 | + </select> | ||
| 22 | + </div> | ||
| 23 | + </div> | ||
| 24 | + </div> | ||
| 25 | + </div> | ||
| 26 | + <div class="uk-grid"> | ||
| 27 | + <div class="uk-width-1-2"> | ||
| 28 | + <div class="uk-form-row"> | ||
| 29 | + <label class="uk-form-label">起点站</label> | ||
| 30 | + <div class="uk-form-controls"> | ||
| 31 | + <select name="qdzCode"> | ||
| 32 | + </select> | ||
| 33 | + </div> | ||
| 34 | + </div> | ||
| 35 | + </div> | ||
| 36 | + <div class="uk-width-1-2"> | ||
| 37 | + <div class="uk-form-row"> | ||
| 38 | + <label class="uk-form-label">终点站</label> | ||
| 39 | + <div class="uk-form-controls"> | ||
| 40 | + <select name="zdzCode"> | ||
| 41 | + </select> | ||
| 42 | + </div> | ||
| 43 | + </div> | ||
| 44 | + </div> | ||
| 45 | + </div> | ||
| 46 | + <div class="uk-grid"> | ||
| 47 | + <div class="uk-width-1-2"> | ||
| 48 | + <div class="uk-form-row"> | ||
| 49 | + <label class="uk-form-label">开始时间</label> | ||
| 50 | + <div class="uk-form-controls"> | ||
| 51 | + <input type="time" class="zndd_text_input_color" value="{{zdsjActual==null?zdsj:zdsjActual}}" name="fcsj" required> | ||
| 52 | + </div> | ||
| 53 | + </div> | ||
| 54 | + </div> | ||
| 55 | + <div class="uk-width-1-2"> | ||
| 56 | + <div class="uk-form-row"> | ||
| 57 | + <label class="uk-form-label">结束时间</label> | ||
| 58 | + <div class="uk-form-controls"> | ||
| 59 | + <input type="time" class="zndd_text_input_color" name="zdsj" required> | ||
| 60 | + </div> | ||
| 61 | + </div> | ||
| 62 | + </div> | ||
| 63 | + </div> | ||
| 64 | + <div class="uk-grid"> | ||
| 65 | + <div class="uk-width-1-2"> | ||
| 66 | + <div class="uk-form-row"> | ||
| 67 | + <label class="uk-form-label">车辆</label> | ||
| 68 | + <div class="uk-form-controls"> | ||
| 69 | + <div class="uk-autocomplete uk-form car-autocom"> | ||
| 70 | + <input type="text" class="zndd_text_input_color" value="{{clZbh}}" name="clZbh" required> | ||
| 71 | + </div> | ||
| 72 | + </div> | ||
| 73 | + </div> | ||
| 74 | + </div> | ||
| 75 | + <div class="uk-width-1-2"> | ||
| 76 | + <div class="uk-form-row"> | ||
| 77 | + <label class="uk-form-label">里程</label> | ||
| 78 | + <div class="uk-form-controls"> | ||
| 79 | + <input type="text" class="zndd_text_input_color" name="jhlc" value="{{jhlc}}" max=400 data-fv-lessthan-inclusive="false" | ||
| 80 | + required> | ||
| 81 | + </div> | ||
| 82 | + </div> | ||
| 83 | + </div> | ||
| 84 | + </div> | ||
| 85 | + <div class="uk-grid"> | ||
| 86 | + <div class="uk-width-1-2"> | ||
| 87 | + <div class="uk-form-row"> | ||
| 88 | + <label class="uk-form-label">驾驶员</label> | ||
| 89 | + <div class="uk-form-controls"> | ||
| 90 | + <div class="uk-autocomplete uk-form jsy-autocom"> | ||
| 91 | + <input type="text" class="zndd_text_input_color" value="{{jGh}}/{{jName}}" name="jsy" required> | ||
| 92 | + </div> | ||
| 93 | + </div> | ||
| 94 | + </div> | ||
| 95 | + </div> | ||
| 96 | + <div class="uk-width-1-2"> | ||
| 97 | + <div class="uk-form-row"> | ||
| 98 | + <label class="uk-form-label">售票员</label> | ||
| 99 | + <div class="uk-form-controls"> | ||
| 100 | + <div class="uk-autocomplete uk-form spy-autocom"> | ||
| 101 | + <input type="text" name="spy" value="{{sGh}}/{{sName}}"> | ||
| 102 | + </div> | ||
| 103 | + </div> | ||
| 104 | + </div> | ||
| 105 | + </div> | ||
| 106 | + </div> | ||
| 107 | + <div class="uk-grid"> | ||
| 108 | + <div class="uk-width-1-2"> | ||
| 109 | + <div class="uk-form-row"> | ||
| 110 | + <label class="uk-form-label">路牌</label> | ||
| 111 | + <div class="uk-form-controls"> | ||
| 112 | + <input type="text" value="{{lpName}}" name="lpName" required> | ||
| 113 | + </div> | ||
| 114 | + </div> | ||
| 115 | + </div> | ||
| 116 | + </div> | ||
| 117 | + <div class="uk-grid"> | ||
| 118 | + <div class="uk-width-1-1"> | ||
| 119 | + <div class="uk-form-row"> | ||
| 120 | + <label class="uk-form-label">备注</label> | ||
| 121 | + <div class="uk-form-controls"> | ||
| 122 | + <div class="uk-autocomplete uk-form remarks-autocom"> | ||
| 123 | + <input type="text" name="remarks"> | ||
| 124 | + </div> | ||
| 125 | + </div> | ||
| 126 | + </div> | ||
| 127 | + </div> | ||
| 128 | + </div> | ||
| 129 | + <div class="uk-modal-footer uk-text-right" style="margin-bottom: -20px;"> | ||
| 130 | + <button type="button" class="uk-button uk-modal-close">取消</button> | ||
| 131 | + <button type="submit" class="uk-button uk-button-primary"><i class="uk-icon-check"></i> 保存 | ||
| 132 | + </button> | ||
| 133 | + </div> | ||
| 134 | + </form> | ||
| 135 | +</script> | ||
| 136 | +<script> | ||
| 137 | + (function () { | ||
| 138 | + var wrap = '#schedule-addsch-modal .normalCont', sch, nf, submitFun; | ||
| 139 | + | ||
| 140 | + $(wrap).on('init', function (e, data) { | ||
| 141 | + e.stopPropagation(); | ||
| 142 | + sch = data.sch; | ||
| 143 | + submitFun = data.submitFun; | ||
| 144 | + | ||
| 145 | + nf = addForm(); | ||
| 146 | + //提交 | ||
| 147 | + nf.on('success.form.fv', function (e) { | ||
| 148 | + e.preventDefault(); | ||
| 149 | + | ||
| 150 | + disabled_submit_btn(nf); | ||
| 151 | + var data = nf.serializeJSON(); | ||
| 152 | + submitFun(data, function (rs) { | ||
| 153 | + //前端数据更新 | ||
| 154 | + gb_schedule_table.insertSchedule(rs.t, rs.ts); | ||
| 155 | + $('#schedule-lj_zrw-modal .main-schedule-table').trigger('refresh', {sch: rs.t}); | ||
| 156 | + try { | ||
| 157 | + if(rs.t.bcType=='in' || rs.t.bcType=='out') | ||
| 158 | + gb_data_basic.reload_stat_park_data(); | ||
| 159 | + }catch (e){ | ||
| 160 | + console.log(e);} | ||
| 161 | + UIkit.modal('#schedule-addsch-modal').hide(); | ||
| 162 | + //更新路牌公里统计面板 | ||
| 163 | + gb_schedule_table.showLpMileageTipBySch(rs.t); | ||
| 164 | + }, function () { | ||
| 165 | + enable_submit_btn(nf); | ||
| 166 | + }); | ||
| 167 | + }); | ||
| 168 | + }); | ||
| 169 | + | ||
| 170 | + function addForm() { | ||
| 171 | + var htmlStr = template('add_normal_sch-form-temp', sch); | ||
| 172 | + var f = $(htmlStr); | ||
| 173 | + $(wrap).append(f); | ||
| 174 | + //字典转换 | ||
| 175 | + dictionaryUtils.transformDom($('.nt-dictionary', f)); | ||
| 176 | + //validation | ||
| 177 | + f.formValidation({framework: 'uikit', locale: 'zh_CN'}); | ||
| 178 | + //autocomp | ||
| 179 | + f.trigger('init-autoCom'); | ||
| 180 | + | ||
| 181 | + $f('bcType', f).trigger('change'); | ||
| 182 | + return f; | ||
| 183 | + } | ||
| 184 | + | ||
| 185 | + function $f(name, f) { | ||
| 186 | + return $('[name=' + name + ']', f); | ||
| 187 | + } | ||
| 188 | + })(); | ||
| 189 | +</script> | ||
| 0 | \ No newline at end of file | 190 | \ No newline at end of file |
src/main/resources/static/real_control_v2/fragments/line_schedule/context_menu/temp_sch_v2/add_two_way_znddType.html
0 → 100644
| 1 | +<!-- 线路上往返临加班次 --> | ||
| 2 | +<script id="add_toAndFro_sch-form-temp" type="text/html"> | ||
| 3 | + <form class="uk-form uk-form-horizontal add-sch-form one_form"> | ||
| 4 | + <div class="uk-grid"> | ||
| 5 | + <div class="uk-width-1-2"> | ||
| 6 | + <div class="uk-form-row"> | ||
| 7 | + <label class="uk-form-label">班次类型</label> | ||
| 8 | + <div class="uk-form-controls"> | ||
| 9 | + <select class="form-control nt-dictionary" name="bcType" data-code="{{bcType}}" | ||
| 10 | + data-group=ScheduleType></select> | ||
| 11 | + </div> | ||
| 12 | + </div> | ||
| 13 | + </div> | ||
| 14 | + <div class="uk-width-1-2"> | ||
| 15 | + <div class="uk-form-row"> | ||
| 16 | + <label class="uk-form-label">上下行</label> | ||
| 17 | + <div class="uk-form-controls"> | ||
| 18 | + <select name="xlDir"> | ||
| 19 | + <option value="0">上行</option> | ||
| 20 | + <option value="1">下行</option> | ||
| 21 | + </select> | ||
| 22 | + </div> | ||
| 23 | + </div> | ||
| 24 | + </div> | ||
| 25 | + </div> | ||
| 26 | + <div class="uk-grid"> | ||
| 27 | + <div class="uk-width-1-2"> | ||
| 28 | + <div class="uk-form-row"> | ||
| 29 | + <label class="uk-form-label">起点站</label> | ||
| 30 | + <div class="uk-form-controls"> | ||
| 31 | + <select name="qdzCode" > | ||
| 32 | + </select> | ||
| 33 | + </div> | ||
| 34 | + </div> | ||
| 35 | + </div> | ||
| 36 | + <div class="uk-width-1-2"> | ||
| 37 | + <div class="uk-form-row"> | ||
| 38 | + <label class="uk-form-label">终点站</label> | ||
| 39 | + <div class="uk-form-controls"> | ||
| 40 | + <select name="zdzCode" > | ||
| 41 | + </select> | ||
| 42 | + </div> | ||
| 43 | + </div> | ||
| 44 | + </div> | ||
| 45 | + </div> | ||
| 46 | + <div class="uk-grid"> | ||
| 47 | + <div class="uk-width-1-2"> | ||
| 48 | + <div class="uk-form-row"> | ||
| 49 | + <label class="uk-form-label">开始时间</label> | ||
| 50 | + <div class="uk-form-controls"> | ||
| 51 | + <input type="time" class="zndd_text_input_color" value="{{zdsj}}" name="fcsj" required> | ||
| 52 | + </div> | ||
| 53 | + </div> | ||
| 54 | + </div> | ||
| 55 | + <div class="uk-width-1-2"> | ||
| 56 | + <div class="uk-form-row"> | ||
| 57 | + <label class="uk-form-label">结束时间</label> | ||
| 58 | + <div class="uk-form-controls"> | ||
| 59 | + <input type="time" class="zndd_text_input_color" name="zdsj" required> | ||
| 60 | + </div> | ||
| 61 | + </div> | ||
| 62 | + </div> | ||
| 63 | + </div> | ||
| 64 | + <div class="uk-grid"> | ||
| 65 | + <div class="uk-width-1-2"> | ||
| 66 | + <div class="uk-form-row"> | ||
| 67 | + <label class="uk-form-label">车辆</label> | ||
| 68 | + <div class="uk-form-controls"> | ||
| 69 | + <div class="uk-autocomplete uk-form car-autocom"> | ||
| 70 | + <input type="text" class="zndd_text_input_color" value="{{clZbh}}" name="clZbh" required> | ||
| 71 | + </div> | ||
| 72 | + </div> | ||
| 73 | + </div> | ||
| 74 | + </div> | ||
| 75 | + <div class="uk-width-1-2"> | ||
| 76 | + <div class="uk-form-row"> | ||
| 77 | + <label class="uk-form-label">里程</label> | ||
| 78 | + <div class="uk-form-controls"> | ||
| 79 | + <input type="text" name="jhlc" class="zndd_text_input_color" value="{{jhlc}}" max=400 data-fv-lessthan-inclusive="false" | ||
| 80 | + required> | ||
| 81 | + </div> | ||
| 82 | + </div> | ||
| 83 | + </div> | ||
| 84 | + </div> | ||
| 85 | + <div class="uk-grid"> | ||
| 86 | + <div class="uk-width-1-2"> | ||
| 87 | + <div class="uk-form-row"> | ||
| 88 | + <label class="uk-form-label">驾驶员</label> | ||
| 89 | + <div class="uk-form-controls"> | ||
| 90 | + <div class="uk-autocomplete uk-form jsy-autocom"> | ||
| 91 | + <input type="text" class="zndd_text_input_color" value="{{jGh}}/{{jName}}" name="jsy" required> | ||
| 92 | + </div> | ||
| 93 | + </div> | ||
| 94 | + </div> | ||
| 95 | + </div> | ||
| 96 | + <div class="uk-width-1-2"> | ||
| 97 | + <div class="uk-form-row"> | ||
| 98 | + <label class="uk-form-label">售票员</label> | ||
| 99 | + <div class="uk-form-controls"> | ||
| 100 | + <div class="uk-autocomplete uk-form spy-autocom"> | ||
| 101 | + <input type="text" name="spy" value="{{sGh}}/{{sName}}"> | ||
| 102 | + </div> | ||
| 103 | + </div> | ||
| 104 | + </div> | ||
| 105 | + </div> | ||
| 106 | + </div> | ||
| 107 | + <div class="uk-grid"> | ||
| 108 | + <div class="uk-width-1-2"> | ||
| 109 | + <div class="uk-form-row"> | ||
| 110 | + <label class="uk-form-label">路牌</label> | ||
| 111 | + <div class="uk-form-controls"> | ||
| 112 | + <input type="text" value="{{lpName}}" name="lpName" required> | ||
| 113 | + </div> | ||
| 114 | + </div> | ||
| 115 | + </div> | ||
| 116 | + </div> | ||
| 117 | + <div class="uk-grid"> | ||
| 118 | + <div class="uk-width-1-1"> | ||
| 119 | + <div class="uk-form-row"> | ||
| 120 | + <label class="uk-form-label">备注</label> | ||
| 121 | + <div class="uk-form-controls"> | ||
| 122 | + <div class="uk-autocomplete uk-form remarks-autocom"> | ||
| 123 | + <input type="text" name="remarks"> | ||
| 124 | + </div> | ||
| 125 | + </div> | ||
| 126 | + </div> | ||
| 127 | + </div> | ||
| 128 | + </div> | ||
| 129 | + </form> | ||
| 130 | + <hr style="margin-top: 35px;"> | ||
| 131 | + <form class="uk-form uk-form-horizontal add-sch-form two_form"> | ||
| 132 | + <div class="uk-grid"> | ||
| 133 | + <div class="uk-width-1-2"> | ||
| 134 | + <div class="uk-form-row"> | ||
| 135 | + <label class="uk-form-label">班次类型</label> | ||
| 136 | + <div class="uk-form-controls"> | ||
| 137 | + <select class="form-control nt-dictionary" name="bcType" data-code="{{bcType}}" | ||
| 138 | + data-group=ScheduleType></select> | ||
| 139 | + </div> | ||
| 140 | + </div> | ||
| 141 | + </div> | ||
| 142 | + <div class="uk-width-1-2"> | ||
| 143 | + <div class="uk-form-row"> | ||
| 144 | + <label class="uk-form-label">上下行</label> | ||
| 145 | + <div class="uk-form-controls"> | ||
| 146 | + <select name="xlDir"> | ||
| 147 | + <option value="0">上行</option> | ||
| 148 | + <option value="1">下行</option> | ||
| 149 | + </select> | ||
| 150 | + </div> | ||
| 151 | + </div> | ||
| 152 | + </div> | ||
| 153 | + </div> | ||
| 154 | + <div class="uk-grid"> | ||
| 155 | + <div class="uk-width-1-2"> | ||
| 156 | + <div class="uk-form-row"> | ||
| 157 | + <label class="uk-form-label">起点站</label> | ||
| 158 | + <div class="uk-form-controls"> | ||
| 159 | + <select name="qdzCode" > | ||
| 160 | + </select> | ||
| 161 | + </div> | ||
| 162 | + </div> | ||
| 163 | + </div> | ||
| 164 | + <div class="uk-width-1-2"> | ||
| 165 | + <div class="uk-form-row"> | ||
| 166 | + <label class="uk-form-label">终点站</label> | ||
| 167 | + <div class="uk-form-controls"> | ||
| 168 | + <select name="zdzCode" > | ||
| 169 | + </select> | ||
| 170 | + </div> | ||
| 171 | + </div> | ||
| 172 | + </div> | ||
| 173 | + </div> | ||
| 174 | + <div class="uk-grid"> | ||
| 175 | + <div class="uk-width-1-2"> | ||
| 176 | + <div class="uk-form-row"> | ||
| 177 | + <label class="uk-form-label">开始时间</label> | ||
| 178 | + <div class="uk-form-controls"> | ||
| 179 | + <input type="time" class="zndd_text_input_color" value="{{zdsj}}" name="fcsj" required> | ||
| 180 | + </div> | ||
| 181 | + </div> | ||
| 182 | + </div> | ||
| 183 | + <div class="uk-width-1-2"> | ||
| 184 | + <div class="uk-form-row"> | ||
| 185 | + <label class="uk-form-label">结束时间</label> | ||
| 186 | + <div class="uk-form-controls"> | ||
| 187 | + <input type="time"class="zndd_text_input_color" name="zdsj" required> | ||
| 188 | + </div> | ||
| 189 | + </div> | ||
| 190 | + </div> | ||
| 191 | + </div> | ||
| 192 | + <div class="uk-grid"> | ||
| 193 | + <div class="uk-width-1-2"> | ||
| 194 | + <div class="uk-form-row"> | ||
| 195 | + <label class="uk-form-label">车辆</label> | ||
| 196 | + <div class="uk-form-controls"> | ||
| 197 | + <div class="uk-autocomplete uk-form car-autocom"> | ||
| 198 | + <input type="text" class="zndd_text_input_color" value="{{clZbh}}" name="clZbh" required> | ||
| 199 | + </div> | ||
| 200 | + </div> | ||
| 201 | + </div> | ||
| 202 | + </div> | ||
| 203 | + <div class="uk-width-1-2"> | ||
| 204 | + <div class="uk-form-row"> | ||
| 205 | + <label class="uk-form-label">里程</label> | ||
| 206 | + <div class="uk-form-controls"> | ||
| 207 | + <input type="text" class="zndd_text_input_color" name="jhlc" value="{{jhlc}}" max=400 data-fv-lessthan-inclusive="false" | ||
| 208 | + required> | ||
| 209 | + </div> | ||
| 210 | + </div> | ||
| 211 | + </div> | ||
| 212 | + </div> | ||
| 213 | + <div class="uk-grid"> | ||
| 214 | + <div class="uk-width-1-2"> | ||
| 215 | + <div class="uk-form-row"> | ||
| 216 | + <label class="uk-form-label">驾驶员</label> | ||
| 217 | + <div class="uk-form-controls"> | ||
| 218 | + <div class="uk-autocomplete uk-form jsy-autocom"> | ||
| 219 | + <input type="text" class="zndd_text_input_color" value="{{jGh}}/{{jName}}" name="jsy" required> | ||
| 220 | + </div> | ||
| 221 | + </div> | ||
| 222 | + </div> | ||
| 223 | + </div> | ||
| 224 | + <div class="uk-width-1-2"> | ||
| 225 | + <div class="uk-form-row"> | ||
| 226 | + <label class="uk-form-label">售票员</label> | ||
| 227 | + <div class="uk-form-controls"> | ||
| 228 | + <div class="uk-autocomplete uk-form spy-autocom"> | ||
| 229 | + <input type="text" name="spy" value="{{sGh}}/{{sName}}"> | ||
| 230 | + </div> | ||
| 231 | + </div> | ||
| 232 | + </div> | ||
| 233 | + </div> | ||
| 234 | + </div> | ||
| 235 | + <div class="uk-grid"> | ||
| 236 | + <div class="uk-width-1-2"> | ||
| 237 | + <div class="uk-form-row"> | ||
| 238 | + <label class="uk-form-label">路牌</label> | ||
| 239 | + <div class="uk-form-controls"> | ||
| 240 | + <input type="text" value="{{lpName}}" name="lpName" required> | ||
| 241 | + </div> | ||
| 242 | + </div> | ||
| 243 | + </div> | ||
| 244 | + </div> | ||
| 245 | + <div class="uk-grid"> | ||
| 246 | + <div class="uk-width-1-1"> | ||
| 247 | + <div class="uk-form-row"> | ||
| 248 | + <label class="uk-form-label">备注</label> | ||
| 249 | + <div class="uk-form-controls"> | ||
| 250 | + <div class="uk-autocomplete uk-form remarks-autocom"> | ||
| 251 | + <input type="text" name="remarks"> | ||
| 252 | + </div> | ||
| 253 | + </div> | ||
| 254 | + </div> | ||
| 255 | + </div> | ||
| 256 | + </div> | ||
| 257 | + </form> | ||
| 258 | + | ||
| 259 | + <div class="uk-modal-footer uk-text-right" style="margin-bottom: -20px;"> | ||
| 260 | + <button type="button" class="uk-button uk-modal-close">取消</button> | ||
| 261 | + <button type="submit" class="uk-button uk-button-primary"><i class="uk-icon-check"></i> 保存</button> | ||
| 262 | + </div> | ||
| 263 | +</script> | ||
| 264 | + | ||
| 265 | +<script> | ||
| 266 | + var addTwoWayZnddType = (function () { | ||
| 267 | + var wrap = '#schedule-addsch-modal .toAndFroCont', sch, f1, f2, submitFun, stationRoutes; | ||
| 268 | + | ||
| 269 | + $(wrap).on('init', function (e, data) { | ||
| 270 | + e.stopPropagation(); | ||
| 271 | + sch = data.sch; | ||
| 272 | + submitFun = data.submitFun; | ||
| 273 | + stationRoutes = data.stationRoutes; | ||
| 274 | + | ||
| 275 | + var htmlStr = template('add_toAndFro_sch-form-temp', sch); | ||
| 276 | + $(wrap).append(htmlStr); | ||
| 277 | + //字典转换 | ||
| 278 | + dictionaryUtils.transformDom($('.nt-dictionary', wrap)); | ||
| 279 | + //validation | ||
| 280 | + $('.add-sch-form', wrap).formValidation({framework: 'uikit', locale: 'zh_CN'}).trigger('init-autoCom'); | ||
| 281 | + $('.add-sch-form [name=bcType]', wrap).trigger('change'); | ||
| 282 | + | ||
| 283 | + f1 = $('.add-sch-form.one_form', wrap); | ||
| 284 | + f2 = $('.add-sch-form.two_form', wrap); | ||
| 285 | + | ||
| 286 | + //默认1备注同步到2 | ||
| 287 | + $f('remarks', f1).on('input', function () { | ||
| 288 | + $f('remarks', f2).val($(this).val()); | ||
| 289 | + }); | ||
| 290 | + //默认1备注同步到2 | ||
| 291 | + $('.remarks-autocom', f1).on('selectitem.uk.autocomplete', function (e, data, acobject) { | ||
| 292 | + $f('remarks', f2).val(data.value); | ||
| 293 | + }); | ||
| 294 | + | ||
| 295 | + //人车级联 | ||
| 296 | + $f('clZbh',f1).on('input change', function () { | ||
| 297 | + $f('clZbh', f2).val($(this).val()); | ||
| 298 | + }); | ||
| 299 | + $f('jsy',f1).on('input change', function () { | ||
| 300 | + $f('jsy', f2).val($(this).val()); | ||
| 301 | + }); | ||
| 302 | + $f('spy',f1).on('input change', function () { | ||
| 303 | + $f('spy', f2).val($(this).val()); | ||
| 304 | + }); | ||
| 305 | + $f('lpName',f1).on('input change', function () { | ||
| 306 | + $f('lpName', f2).val($(this).val()); | ||
| 307 | + }); | ||
| 308 | + //表单同步 | ||
| 309 | + $(f1).on('ct_callback', synchroFormData).trigger('ct_callback'); | ||
| 310 | + //修改1结束时间 | ||
| 311 | + $f('zdsj',f1).on('input', synchroFormData); | ||
| 312 | + | ||
| 313 | + //表单校验提交相关 | ||
| 314 | + | ||
| 315 | + var fs = $('.add-sch-form', wrap); | ||
| 316 | + fs.on('success.form.fv', function (e) { | ||
| 317 | + e.preventDefault(); | ||
| 318 | + dataArray.push($(this).serializeJSON()); | ||
| 319 | + $(this).data('valid', true); | ||
| 320 | + if (allValidSuccess()) { | ||
| 321 | + //开始post | ||
| 322 | + var i = 0; | ||
| 323 | + var inArr = []; | ||
| 324 | + var upArr = []; | ||
| 325 | + (function () { | ||
| 326 | + var f = arguments.callee; | ||
| 327 | + if (i >= dataArray.length) { | ||
| 328 | + //前端数据更新 | ||
| 329 | + var last = inArr.pop(); | ||
| 330 | + gb_schedule_table.insertSchedule(last, upArr); | ||
| 331 | + $('#schedule-lj_zrw-modal .main-schedule-table').trigger('refresh', {sch: last}); | ||
| 332 | + | ||
| 333 | + try { | ||
| 334 | + if(last.bcType=='in' || last.bcType=='out') | ||
| 335 | + gb_data_basic.reload_stat_park_data(); | ||
| 336 | + }catch (e){ | ||
| 337 | + console.log(e);} | ||
| 338 | + UIkit.modal('#schedule-addsch-modal').hide(); | ||
| 339 | + //更新路牌公里统计面板 | ||
| 340 | + gb_schedule_table.showLpMileageTipBySch(last); | ||
| 341 | + return; | ||
| 342 | + } | ||
| 343 | + submitFun(dataArray[i], function (rs) { | ||
| 344 | + inArr.push(rs.t); | ||
| 345 | + upArr = upArr.concat(rs.ts); | ||
| 346 | + upArr.push(rs.t); | ||
| 347 | + i++; | ||
| 348 | + f(); | ||
| 349 | + }, function () { | ||
| 350 | + $('[type=submit]', wrap).removeClass('disabled').removeAttr('disabled'); | ||
| 351 | + }); | ||
| 352 | + })(); | ||
| 353 | + } | ||
| 354 | + }); | ||
| 355 | + | ||
| 356 | + //提交 | ||
| 357 | + $('[type=submit]', wrap).on('click', function () { | ||
| 358 | + $(this).addClass('disabled').attr('disabled', 'disabled'); | ||
| 359 | + dataArray = []; | ||
| 360 | + fs.data('valid', false); | ||
| 361 | + fs.formValidation('validate'); | ||
| 362 | + }); | ||
| 363 | + }); | ||
| 364 | + var dataArray; | ||
| 365 | + | ||
| 366 | + var submit = function () { | ||
| 367 | + debugger | ||
| 368 | + $(this).addClass('disabled').attr('disabled', 'disabled'); | ||
| 369 | + dataArray = []; | ||
| 370 | + var fs = $('.add-sch-form', wrap); | ||
| 371 | + fs.data('valid', false); | ||
| 372 | + fs.formValidation('validate'); | ||
| 373 | + | ||
| 374 | + | ||
| 375 | + fs.on('success.form.fv', function (e) { | ||
| 376 | + e.preventDefault(); | ||
| 377 | + dataArray.push($(this).serializeJSON()); | ||
| 378 | + $(this).data('valid', true); | ||
| 379 | + if (allValidSuccess()) { | ||
| 380 | + //开始post | ||
| 381 | + var i = 0; | ||
| 382 | + var inArr = []; | ||
| 383 | + var upArr = []; | ||
| 384 | + (function () { | ||
| 385 | + var f = arguments.callee; | ||
| 386 | + if (i >= dataArray.length) { | ||
| 387 | + //前端数据更新 | ||
| 388 | + var last = inArr.pop(); | ||
| 389 | + gb_schedule_table.insertSchedule(last, upArr); | ||
| 390 | + $('#schedule-lj_zrw-modal .main-schedule-table').trigger('refresh', {sch: last}); | ||
| 391 | + | ||
| 392 | + try { | ||
| 393 | + if(last.bcType=='in' || last.bcType=='out') | ||
| 394 | + gb_data_basic.reload_stat_park_data(); | ||
| 395 | + }catch (e){ | ||
| 396 | + console.log(e);} | ||
| 397 | + UIkit.modal('#schedule-addsch-modal').hide(); | ||
| 398 | + //更新路牌公里统计面板 | ||
| 399 | + gb_schedule_table.showLpMileageTipBySch(last); | ||
| 400 | + return; | ||
| 401 | + } | ||
| 402 | + submitFun(dataArray[i], function (rs) { | ||
| 403 | + inArr.push(rs.t); | ||
| 404 | + upArr = upArr.concat(rs.ts); | ||
| 405 | + upArr.push(rs.t); | ||
| 406 | + i++; | ||
| 407 | + f(); | ||
| 408 | + }, function () { | ||
| 409 | + $('[type=submit]', wrap).removeClass('disabled').removeAttr('disabled'); | ||
| 410 | + }); | ||
| 411 | + })(); | ||
| 412 | + } | ||
| 413 | + }); | ||
| 414 | + } | ||
| 415 | + | ||
| 416 | + function $f(name, f) { | ||
| 417 | + return $('[name=' + name + ']', f); | ||
| 418 | + } | ||
| 419 | + | ||
| 420 | + function allValidSuccess() { | ||
| 421 | + var flag = true; | ||
| 422 | + $('form.add-sch-form:visible', wrap).each(function (i, f) { | ||
| 423 | + if (!$(f).data('valid')) { | ||
| 424 | + flag = false; | ||
| 425 | + return false; | ||
| 426 | + } | ||
| 427 | + }); | ||
| 428 | + return flag; | ||
| 429 | + } | ||
| 430 | + | ||
| 431 | + /** | ||
| 432 | + * 同步2个表单的数据 | ||
| 433 | + */ | ||
| 434 | + var bcTypes = {'normal': 'normal', 'region': 'region', 'out': 'in', 'in': 'out'}; | ||
| 435 | + var synchroFormData = function () { | ||
| 436 | + //同步班次类型 | ||
| 437 | + var type = $f('bcType', f1).val(); | ||
| 438 | + if (bcTypes[type]) | ||
| 439 | + $f('bcType', f2).val(bcTypes[type]).trigger('change'); | ||
| 440 | + var updown = $f('xlDir', f1).val(); | ||
| 441 | + | ||
| 442 | + //1 结束时间 = 2 开始时间 | ||
| 443 | + $f('fcsj', f2).val($f('zdsj', f1).val()); | ||
| 444 | + if (type != 'out' && type != 'in') { | ||
| 445 | + //走向 | ||
| 446 | + $f('xlDir', f2).val(updown == 0 ? 1 : 0).trigger('change'); | ||
| 447 | + | ||
| 448 | + //第一个表单终点 = 第二个起点 | ||
| 449 | + var oneZdName = $('[name=zdzCode] option:selected', f1).text(); | ||
| 450 | + $f('qdzCode', f2).val(searchParallelStation(oneZdName, updown == 0 ? 1 : 0)); | ||
| 451 | + //第一个表单起点 = 第二个终点 | ||
| 452 | + var oneQdName = $('[name=qdzCode] option:selected', f1).text(); | ||
| 453 | + $f('zdzCode', f2).val(searchParallelStation(oneQdName, updown == 0 ? 1 : 0)).trigger('change'); | ||
| 454 | + } | ||
| 455 | + else { | ||
| 456 | + //进出场走向相同 | ||
| 457 | + $f('xlDir', f2).val(updown).trigger('change'); | ||
| 458 | + //第一个表单终点 = 第二个起点 | ||
| 459 | + $f('qdzCode', f2).val($f('zdzCode', f1).val()); | ||
| 460 | + //第一个表单起点 = 第二个终点 | ||
| 461 | + $f('zdzCode', f2).val($f('qdzCode', f1).val()).trigger('change'); | ||
| 462 | + } | ||
| 463 | + | ||
| 464 | + }; | ||
| 465 | + | ||
| 466 | + | ||
| 467 | + //返回另一个走向对应的站点 | ||
| 468 | + function searchParallelStation(stationName, updown) { | ||
| 469 | + var routes = stationRoutes[updown] | ||
| 470 | + , len = routes.length; | ||
| 471 | + | ||
| 472 | + for (var i = 0; i < len; i++) { | ||
| 473 | + if (routes[i].stationName == stationName) | ||
| 474 | + return routes[i].stationCode; | ||
| 475 | + } | ||
| 476 | + } | ||
| 477 | + | ||
| 478 | + return { | ||
| 479 | + submit : submit | ||
| 480 | + } | ||
| 481 | + })(); | ||
| 482 | +</script> | ||
| 0 | \ No newline at end of file | 483 | \ No newline at end of file |
src/main/resources/static/real_control_v2/fragments/line_schedule/sch_table.html
| @@ -25,6 +25,8 @@ | @@ -25,6 +25,8 @@ | ||
| 25 | </div> | 25 | </div> |
| 26 | <i class="uk-icon-eye uk-icon-hover ct_eye_icon"></i> | 26 | <i class="uk-icon-eye uk-icon-hover ct_eye_icon"></i> |
| 27 | <i class="uk-icon-qrcode uk-icon-hover ct_calu_icon" data-toggle="tooltip" data-placement="bottom" title="计算应到实到时间对比"></i> | 27 | <i class="uk-icon-qrcode uk-icon-hover ct_calu_icon" data-toggle="tooltip" data-placement="bottom" title="计算应到实到时间对比"></i> |
| 28 | + <i class="uk-icon-video-camera uk-icon-hover ct_video_camera_icon" data-updown="{{dir}}" data-linecode="{{line.lineCode}}" data-toggle="tooltip" data-placement="bottom"></i> | ||
| 29 | + <i class="uk-icon-image uk-icon-hover ct_image_icon" data-updown="{{dir}}" data-linecode="{{line.lineCode}}" data-toggle="tooltip" data-placement="bottom"></i> | ||
| 28 | 30 | ||
| 29 | <!--<i class="uk-icon-share-alt uk-icon-hover tp_info_icon" ></i>--> | 31 | <!--<i class="uk-icon-share-alt uk-icon-hover tp_info_icon" ></i>--> |
| 30 | 32 |
src/main/resources/static/real_control_v2/fragments/line_schedule/sys_mailbox.html
| @@ -9,6 +9,17 @@ | @@ -9,6 +9,17 @@ | ||
| 9 | <button class="uk-button uk-button-mini reject">不同意</button> | 9 | <button class="uk-button uk-button-mini reject">不同意</button> |
| 10 | <a class="edit_link" data-id="{{schId}}" data-line="{{data.lineId}}" >编辑</a> | 10 | <a class="edit_link" data-id="{{schId}}" data-line="{{data.lineId}}" >编辑</a> |
| 11 | </div> | 11 | </div> |
| 12 | + <div style="display:{{isbj == true?'':'none'}}"> | ||
| 13 | + <h6 > 车辆事故最近的站点:{{stationName}}</h6> | ||
| 14 | + </div> | ||
| 15 | + <div class="uk-button-group" style="display:{{isbj == true?'':'none'}}"> | ||
| 16 | + <button class="uk-button uk-button-mini qxbc" data-id="{{schId}}" data-line="{{data.lineId}}" data-nextschid="{{nextschId}}">取消班次</button> | ||
| 17 | + <button class="uk-button uk-button-mini hrhc" data-id="{{schId}}" data-line="{{data.lineId}}" data-nextschid="{{nextschId}}">换人换车</button> | ||
| 18 | + | ||
| 19 | + </div> | ||
| 20 | + <div class="uk-button-group" style="display:{{isbj == true?'':'none'}}"> | ||
| 21 | + <button class="uk-button uk-button-mini zrw" data-id="{{schId}}" data-line="{{data.lineId}}" data-nextschid="{{nextschId}}">临加子任务</button> | ||
| 22 | + </div> | ||
| 12 | </div> | 23 | </div> |
| 13 | </div> | 24 | </div> |
| 14 | </script> | 25 | </script> |
src/main/resources/static/real_control_v2/js/common.js
| @@ -20,6 +20,10 @@ var gb_common = (function () { | @@ -20,6 +20,10 @@ var gb_common = (function () { | ||
| 20 | 0x11: '扣证纠纷', | 20 | 0x11: '扣证纠纷', |
| 21 | 0x12: '报警', | 21 | 0x12: '报警', |
| 22 | 0x10: 'SOS', | 22 | 0x10: 'SOS', |
| 23 | + 0x21: '单车有人伤', | ||
| 24 | + 0x22: '单车无人伤', | ||
| 25 | + 0x23: '双车有人伤', | ||
| 26 | + 0x24: '双车无人伤', | ||
| 23 | }; | 27 | }; |
| 24 | 28 | ||
| 25 | var adjustExps = ['配车', '保养', '故障', '肇事', '路阻', '纠纷', '缺人', '客稀', '缺车', '气候', '援外', '吊慢', '抽减', '路救抛锚', '无到', '无出', '掉线', '指令故障', '车辆漂移', '其他']; | 29 | var adjustExps = ['配车', '保养', '故障', '肇事', '路阻', '纠纷', '缺人', '客稀', '缺车', '气候', '援外', '吊慢', '抽减', '路救抛锚', '无到', '无出', '掉线', '指令故障', '车辆漂移', '其他']; |
src/main/resources/static/real_control_v2/js/data/json/north_toolbar.json
| @@ -139,6 +139,12 @@ | @@ -139,6 +139,12 @@ | ||
| 139 | "text": "智能调度执行记录", | 139 | "text": "智能调度执行记录", |
| 140 | "event": "form_loggerr_zndd", | 140 | "event": "form_loggerr_zndd", |
| 141 | "icon": "uk-icon-table" | 141 | "icon": "uk-icon-table" |
| 142 | + }, | ||
| 143 | + { | ||
| 144 | + "id": 2.8, | ||
| 145 | + "text": "调度消息分析", | ||
| 146 | + "event": "form_message_two", | ||
| 147 | + "icon": "uk-icon-table" | ||
| 142 | } | 148 | } |
| 143 | ] | 149 | ] |
| 144 | }, | 150 | }, |
| @@ -201,6 +207,17 @@ | @@ -201,6 +207,17 @@ | ||
| 201 | "id": 4.5, | 207 | "id": 4.5, |
| 202 | "text": "客流信息", | 208 | "text": "客流信息", |
| 203 | "event": "kl_config" | 209 | "event": "kl_config" |
| 210 | + }, | ||
| 211 | + { | ||
| 212 | + "id": 4.6, | ||
| 213 | + "text": "智能调度开关", | ||
| 214 | + "event": "zndd_status" | ||
| 215 | + }, | ||
| 216 | + | ||
| 217 | + { | ||
| 218 | + "id": 4.7, | ||
| 219 | + "text": "调度助手(deepseek)", | ||
| 220 | + "event": "deepseek" | ||
| 204 | } | 221 | } |
| 205 | 222 | ||
| 206 | ] | 223 | ] |
src/main/resources/static/real_control_v2/js/line_schedule/context_menu.js
| @@ -27,6 +27,10 @@ var gb_schedule_context_menu = (function () { | @@ -27,6 +27,10 @@ var gb_schedule_context_menu = (function () { | ||
| 27 | $.get(folder + '/temp_sch/add_normal.html', function (dom) { | 27 | $.get(folder + '/temp_sch/add_normal.html', function (dom) { |
| 28 | add_sch_doms.normal_dom=dom; | 28 | add_sch_doms.normal_dom=dom; |
| 29 | }); | 29 | }); |
| 30 | + //AI语音使用 | ||
| 31 | + $.get(folder + '/temp_sch/add_normal_recoder.html', function (dom) { | ||
| 32 | + add_sch_doms.normal_recoder_dom=dom; | ||
| 33 | + }); | ||
| 30 | $.get(folder + '/temp_sch/add_two_way.html', function (dom) { | 34 | $.get(folder + '/temp_sch/add_two_way.html', function (dom) { |
| 31 | add_sch_doms.two_way_dom=dom; | 35 | add_sch_doms.two_way_dom=dom; |
| 32 | }); | 36 | }); |
| @@ -44,6 +48,17 @@ var gb_schedule_context_menu = (function () { | @@ -44,6 +48,17 @@ var gb_schedule_context_menu = (function () { | ||
| 44 | }); | 48 | }); |
| 45 | 49 | ||
| 46 | 50 | ||
| 51 | + | ||
| 52 | + //智能调度使用 | ||
| 53 | + $.get(folder + '/temp_sch_v2/add_normal_znddType.html', function (dom) { | ||
| 54 | + add_sch_doms_v2.normal_znddType_dom=dom; | ||
| 55 | + }); | ||
| 56 | + $.get(folder + '/temp_sch_v2/add_two_way_znddType.html', function (dom) { | ||
| 57 | + add_sch_doms_v2.two_znddType_dom=dom; | ||
| 58 | + }); | ||
| 59 | + | ||
| 60 | + | ||
| 61 | + | ||
| 47 | var callbackHandler = { | 62 | var callbackHandler = { |
| 48 | get_st_doms: function () { | 63 | get_st_doms: function () { |
| 49 | return st_doms; | 64 | return st_doms; |
src/main/resources/static/real_control_v2/js/line_schedule/legend.js
| @@ -78,6 +78,55 @@ var gb_sch_legend = (function () { | @@ -78,6 +78,55 @@ var gb_sch_legend = (function () { | ||
| 78 | showYdSdDb(); | 78 | showYdSdDb(); |
| 79 | } | 79 | } |
| 80 | 80 | ||
| 81 | + $(document).on('click', '.schedule-wrap i.ct_video_camera_icon', function (event) { | ||
| 82 | + var upDown=event.target.dataset.updown; | ||
| 83 | + var lineCode=event.target.dataset.linecode; | ||
| 84 | + var params = {"upDown":upDown,"lineCode":lineCode}; | ||
| 85 | + $.get('/out/getStationVideo', params, function(url){ | ||
| 86 | + if(url!=''){ | ||
| 87 | + var imgHtml = "<iframe src='"+url+"?autoplay=1' style='width:100%;height:100%'/>"; | ||
| 88 | + layer.open({ | ||
| 89 | + type: 1, | ||
| 90 | + offset: 'auto', | ||
| 91 | + area: [700 + 'px', 394 + 'px'], | ||
| 92 | + shadeClose: true,//点击外围关闭弹窗 | ||
| 93 | + scrollbar: true,//不现实滚动条 | ||
| 94 | + title: false, //不显示标题 | ||
| 95 | + content: imgHtml, //捕获的元素,注意:最好该指定的元素要存放在body最外层,否则可能被其它的相对元素所影响 | ||
| 96 | + cancel: function () { | ||
| 97 | + } | ||
| 98 | + }) | ||
| 99 | + }/*else { | ||
| 100 | + notify_succ('设备不存在'); | ||
| 101 | + }*/ | ||
| 102 | + | ||
| 103 | + }); | ||
| 104 | + }); | ||
| 105 | + | ||
| 106 | + $(document).on('click', '.schedule-wrap i.ct_image_icon', function (event) { | ||
| 107 | + var upDown=event.target.dataset.updown; | ||
| 108 | + var lineCode=event.target.dataset.linecode; | ||
| 109 | + var params = {"upDown":upDown,"lineCode":lineCode}; | ||
| 110 | + $.get('/out/getStationImg', params, function(url){ | ||
| 111 | + if(url!=''){ | ||
| 112 | + var imgHtml = "<img src='"+url+"' style='width:700px;height:394px'/>"; | ||
| 113 | + layer.open({ | ||
| 114 | + type: 1, | ||
| 115 | + offset: 'auto', | ||
| 116 | + area: [700 + 'px', 394 + 'px'], | ||
| 117 | + shadeClose: true,//点击外围关闭弹窗 | ||
| 118 | + scrollbar: true,//不现实滚动条 | ||
| 119 | + title: false, //不显示标题 | ||
| 120 | + content: imgHtml, //捕获的元素,注意:最好该指定的元素要存放在body最外层,否则可能被其它的相对元素所影响 | ||
| 121 | + cancel: function () { | ||
| 122 | + } | ||
| 123 | + }) | ||
| 124 | + }/*else { | ||
| 125 | + notify_succ('设备不存在'); | ||
| 126 | + }*/ | ||
| 127 | + }); | ||
| 128 | + }); | ||
| 129 | + | ||
| 81 | function showYdSdDb() { | 130 | function showYdSdDb() { |
| 82 | if (ydsddb) { | 131 | if (ydsddb) { |
| 83 | var sdsjs = $('.schedule-wrap').find('.qdzArrDatesjDD'); | 132 | var sdsjs = $('.schedule-wrap').find('.qdzArrDatesjDD'); |
src/main/resources/static/real_control_v2/js/main.js
| @@ -4,33 +4,55 @@ var gb_main_ep = new EventProxy(), | @@ -4,33 +4,55 @@ var gb_main_ep = new EventProxy(), | ||
| 4 | 4 | ||
| 5 | 5 | ||
| 6 | var recorder; | 6 | var recorder; |
| 7 | - var fired = true; | ||
| 8 | - document.onkeypress =function(e) { //对整个页面监听 | ||
| 9 | - var keyNum = window.event ? e.keyCode : e.which; //获取被按下的键值 | ||
| 10 | - //判断如果用户按下了回车键(keycody=13) | ||
| 11 | - if (keyNum == 13) { | ||
| 12 | - var id = document.getElementById("len"); | ||
| 13 | - if(fired) | ||
| 14 | - fired = false; | ||
| 15 | - else | ||
| 16 | - return | ||
| 17 | - | 7 | + var fired = false; |
| 8 | + let timer = null;//定时器 | ||
| 9 | + const longPressDuration = 500; // 长按的阈值,单位毫秒 | ||
| 10 | + var zxFl = true; //定时器内只执行一次; | ||
| 11 | + | ||
| 12 | + function openAi(){ | ||
| 13 | + if (zxFl){ | ||
| 14 | + console.log('长按回车键'); | ||
| 15 | + zxFl = false; | ||
| 16 | + fired = true; | ||
| 18 | document.getElementById("recidress").style.display = ""; | 17 | document.getElementById("recidress").style.display = ""; |
| 19 | HZRecorder.get(function (rec) { | 18 | HZRecorder.get(function (rec) { |
| 20 | recorder = rec; | 19 | recorder = rec; |
| 21 | recorder.start(); | 20 | recorder.start(); |
| 22 | }); | 21 | }); |
| 22 | + } | ||
| 23 | + } | ||
| 23 | 24 | ||
| 24 | 25 | ||
| 26 | + document.addEventListener('keydown', function(event) { | ||
| 27 | + if (event.key === 'Enter' && zxFl) { | ||
| 28 | + // 开始计时 | ||
| 29 | + timer = setTimeout(() => { | ||
| 30 | + openAi(); | ||
| 31 | + // 执行长按的逻辑 | ||
| 32 | + }, longPressDuration); | ||
| 25 | } | 33 | } |
| 26 | - } | 34 | + }); |
| 35 | + | ||
| 36 | + document.addEventListener('keyup', function(event) { | ||
| 37 | + if (event.key === 'Enter') { | ||
| 38 | + // 清除计时器,表示短按 | ||
| 39 | + clearTimeout(timer); | ||
| 40 | + console.log('短按回车键'); | ||
| 41 | + // 执行短按的逻辑 | ||
| 42 | + } | ||
| 43 | + }); | ||
| 44 | + | ||
| 27 | 45 | ||
| 28 | document.onkeyup =function(e) { //对整个页面监听 | 46 | document.onkeyup =function(e) { //对整个页面监听 |
| 29 | var keyNum = window.event ? e.keyCode : e.which; //获取被按下的键值 | 47 | var keyNum = window.event ? e.keyCode : e.which; //获取被按下的键值 |
| 30 | //判断如果用户按下了回车键(keycody=13) | 48 | //判断如果用户按下了回车键(keycody=13) |
| 49 | + console.log('松开回车键'); | ||
| 50 | + clearTimeout(timer); | ||
| 31 | if (keyNum == 13) { | 51 | if (keyNum == 13) { |
| 32 | - fired = true; | 52 | + if(!fired) |
| 53 | + return; | ||
| 33 | 54 | ||
| 55 | + fired = false;zxFl= true; | ||
| 34 | let lineCode = gb_schedule_table.TablelineCode; | 56 | let lineCode = gb_schedule_table.TablelineCode; |
| 35 | document.getElementById("recidress").style.display = 'none'; | 57 | document.getElementById("recidress").style.display = 'none'; |
| 36 | recorder.upload("zndd/do/"+lineCode, function (state, e) { | 58 | recorder.upload("zndd/do/"+lineCode, function (state, e) { |
src/main/resources/static/real_control_v2/js/north/second_timer.js
| @@ -53,7 +53,7 @@ var gb_second_timer = (function () { | @@ -53,7 +53,7 @@ var gb_second_timer = (function () { | ||
| 53 | }; | 53 | }; |
| 54 | 54 | ||
| 55 | var setTime = function () { | 55 | var setTime = function () { |
| 56 | - _this.innerHTML = timeFormat(now.getHours()) + ':' + timeFormat(now.getMinutes()) + '.' + timeFormat(now.getSeconds()); | 56 | + _this.innerHTML = timeFormat(now.getHours()) + ':' + timeFormat(now.getMinutes()) + ':' + timeFormat(now.getSeconds()); |
| 57 | }; | 57 | }; |
| 58 | 58 | ||
| 59 | var minuteTimer = function () { | 59 | var minuteTimer = function () { |
src/main/resources/static/real_control_v2/js/north/toolbar.js
| @@ -147,6 +147,15 @@ var gb_northToolbar = (function () { | @@ -147,6 +147,15 @@ var gb_northToolbar = (function () { | ||
| 147 | kl_config: function () { | 147 | kl_config: function () { |
| 148 | open_modal('/real_control_v2/fragments/north/nav/kl_config.html', {}, modal_opts); | 148 | open_modal('/real_control_v2/fragments/north/nav/kl_config.html', {}, modal_opts); |
| 149 | }, | 149 | }, |
| 150 | + | ||
| 151 | + zndd_status: function () { | ||
| 152 | + open_modal('/real_control_v2/zndd/zndd_status.html', {}, modal_opts); | ||
| 153 | + }, | ||
| 154 | + | ||
| 155 | + deepseek: function () { | ||
| 156 | + open_modal('/real_control_v2/zndd/deepseek/deepseek.html', {}, modal_opts); | ||
| 157 | + }, | ||
| 158 | + | ||
| 150 | // bcgxsj_config: function () { | 159 | // bcgxsj_config: function () { |
| 151 | // open_modal('/real_control_v2/fragments/north/nav/line_config/bcgxsj_config.html', {}, modal_opts); | 160 | // open_modal('/real_control_v2/fragments/north/nav/line_config/bcgxsj_config.html', {}, modal_opts); |
| 152 | // }, | 161 | // }, |
| @@ -213,6 +222,9 @@ var gb_northToolbar = (function () { | @@ -213,6 +222,9 @@ var gb_northToolbar = (function () { | ||
| 213 | form_message: function () { | 222 | form_message: function () { |
| 214 | gb_embed_form_hanlde.open_modal_form_fragment('/pages/report/message/message.html', '调度消息分析'); | 223 | gb_embed_form_hanlde.open_modal_form_fragment('/pages/report/message/message.html', '调度消息分析'); |
| 215 | }, | 224 | }, |
| 225 | + form_message_two: function () { | ||
| 226 | + gb_embed_form_hanlde.open_modal_form_fragment('/pages/report/message/message_two.html', '调度消息分析'); | ||
| 227 | + }, | ||
| 216 | form_commandState: function () { | 228 | form_commandState: function () { |
| 217 | gb_embed_form_hanlde.open_modal_form_fragment('/pages/forms/statement/commandState.html', '指令状态分析'); | 229 | gb_embed_form_hanlde.open_modal_form_fragment('/pages/forms/statement/commandState.html', '指令状态分析'); |
| 218 | }, | 230 | }, |
src/main/resources/static/real_control_v2/js/stationcf/klyj.js
| @@ -28,10 +28,12 @@ var gb_klyj = (function () { | @@ -28,10 +28,12 @@ var gb_klyj = (function () { | ||
| 28 | $wrap.append(htmlStr); | 28 | $wrap.append(htmlStr); |
| 29 | }; | 29 | }; |
| 30 | 30 | ||
| 31 | - | 31 | + //临加班次 |
| 32 | $wrap.on('click', '.ljbc', function () { | 32 | $wrap.on('click', '.ljbc', function () { |
| 33 | var that = $(this); | 33 | var that = $(this); |
| 34 | var data = dataMap.get(that.data('uuid')); | 34 | var data = dataMap.get(that.data('uuid')); |
| 35 | + var ljtype = $('#ljtype').val(); | ||
| 36 | + data.ljtype = ljtype; | ||
| 35 | open_modal("/real_control_v2/zndd/type/dkl.html", { | 37 | open_modal("/real_control_v2/zndd/type/dkl.html", { |
| 36 | data: data | 38 | data: data |
| 37 | }, {center: true, bgclose: false, modal: true}); | 39 | }, {center: true, bgclose: false, modal: true}); |
| @@ -44,6 +46,25 @@ var gb_klyj = (function () { | @@ -44,6 +46,25 @@ var gb_klyj = (function () { | ||
| 44 | /*if (close) close = false*/ | 46 | /*if (close) close = false*/ |
| 45 | }); | 47 | }); |
| 46 | 48 | ||
| 49 | + $wrap.on('change', '#ljtype', function () { | ||
| 50 | + var fn = $('#ljtype').val(); | ||
| 51 | + if (fn == "lin1"){ | ||
| 52 | + $(".lin1").css({ display: ''}); | ||
| 53 | + $(".lin2").css({display: 'none'}); | ||
| 54 | + $(".lin3").css({display: 'none'}); | ||
| 55 | + }else if((fn == "lin2")) { | ||
| 56 | + $(".lin1").css({ display: 'none'}); | ||
| 57 | + $(".lin2").css({display: ''}); | ||
| 58 | + $(".lin3").css({display: 'none'}); | ||
| 59 | + }else { | ||
| 60 | + $(".lin1").css({ display: 'none'}); | ||
| 61 | + $(".lin2").css({display: 'none'}); | ||
| 62 | + $(".lin3").css({display: ''}); | ||
| 63 | + } | ||
| 64 | + | ||
| 65 | + }); | ||
| 66 | + | ||
| 67 | + | ||
| 47 | $wrap.on('click', '.images', function () { | 68 | $wrap.on('click', '.images', function () { |
| 48 | var image = $(this).data('image'); | 69 | var image = $(this).data('image'); |
| 49 | var imgHtml = "<img src='" + image + "' style='width: " + 600 + "px;height:" + 300 + "px'/>"; | 70 | var imgHtml = "<img src='" + image + "' style='width: " + 600 + "px;height:" + 300 + "px'/>"; |
src/main/resources/static/real_control_v2/js/websocket/sch_websocket.js
| @@ -86,6 +86,17 @@ var gb_sch_websocket = (function () { | @@ -86,6 +86,17 @@ var gb_sch_websocket = (function () { | ||
| 86 | if (!msg.text) | 86 | if (!msg.text) |
| 87 | msg.text = '(未知的请求码 ' + msg.data.requestCode + ')'; | 87 | msg.text = '(未知的请求码 ' + msg.data.requestCode + ')'; |
| 88 | 88 | ||
| 89 | + debugger | ||
| 90 | + switch (msg.data.requestCode) { | ||
| 91 | + //报警请求 | ||
| 92 | + case 0x21: | ||
| 93 | + case 0x22: | ||
| 94 | + case 0x23: | ||
| 95 | + case 0x24: | ||
| 96 | + msg.isbj = true; | ||
| 97 | + break; | ||
| 98 | + } | ||
| 99 | + | ||
| 89 | var $item = $(temps['sys-note-80-temp'](msg)); | 100 | var $item = $(temps['sys-note-80-temp'](msg)); |
| 90 | findMailBox(msg.data.lineId).prepend($item); | 101 | findMailBox(msg.data.lineId).prepend($item); |
| 91 | //tts | 102 | //tts |
| @@ -380,6 +391,7 @@ var gb_sch_websocket = (function () { | @@ -380,6 +391,7 @@ var gb_sch_websocket = (function () { | ||
| 380 | * 信使 sys-note-80 编辑 | 391 | * 信使 sys-note-80 编辑 |
| 381 | */ | 392 | */ |
| 382 | $(document).on('click', '.sys-note-80 .edit_link', function () { | 393 | $(document).on('click', '.sys-note-80 .edit_link', function () { |
| 394 | + | ||
| 383 | var id = $(this).data('id'), | 395 | var id = $(this).data('id'), |
| 384 | lineCode = $(this).data('line'); | 396 | lineCode = $(this).data('line'); |
| 385 | 397 | ||
| @@ -390,6 +402,58 @@ var gb_sch_websocket = (function () { | @@ -390,6 +402,58 @@ var gb_sch_websocket = (function () { | ||
| 390 | gb_schedule_context_menu.fcxxwt(sch); | 402 | gb_schedule_context_menu.fcxxwt(sch); |
| 391 | }); | 403 | }); |
| 392 | 404 | ||
| 405 | + | ||
| 406 | + | ||
| 407 | + /** | ||
| 408 | + * 信使 sys-note-80 取消班次 | ||
| 409 | + */ | ||
| 410 | + $(document).on('click', '.sys-note-80 .qxbc', function () { | ||
| 411 | + debugger | ||
| 412 | + var nextschId = $(this).data('nextschid'), | ||
| 413 | + lineCode = $(this).data('line'); | ||
| 414 | + | ||
| 415 | + var sch = gb_schedule_table.findScheduleByLine(lineCode)[nextschId]; | ||
| 416 | + if(!sch) | ||
| 417 | + return; | ||
| 418 | + | ||
| 419 | + var confirmBtn = $(this).parent().find('.uk-button-primary'); | ||
| 420 | + var fun =gb_schedule_context_menu.jhlb; | ||
| 421 | + fun(sch, function () { | ||
| 422 | + confirmBtn.trigger('click'); | ||
| 423 | + }); | ||
| 424 | + }); | ||
| 425 | + | ||
| 426 | + | ||
| 427 | + /** | ||
| 428 | + * 信使 sys-note-80 换人换车 | ||
| 429 | + */ | ||
| 430 | + $(document).on('click', '.sys-note-80 .hrhc', function () { | ||
| 431 | + debugger | ||
| 432 | + var nextschId = $(this).data('nextschid'), | ||
| 433 | + lineCode = $(this).data('line'); | ||
| 434 | + var sch = gb_schedule_table.findScheduleByLine(lineCode)[nextschId]; | ||
| 435 | + if(!sch) | ||
| 436 | + return; | ||
| 437 | + | ||
| 438 | + gb_schedule_context_menu.tzrc(sch); | ||
| 439 | + }); | ||
| 440 | + | ||
| 441 | + | ||
| 442 | + /** | ||
| 443 | + * 信使 sys-note-80 子任务 | ||
| 444 | + */ | ||
| 445 | + $(document).on('click', '.sys-note-80 .zrw', function () { | ||
| 446 | + debugger | ||
| 447 | + var id = $(this).data('id'), | ||
| 448 | + lineCode = $(this).data('line'); | ||
| 449 | + | ||
| 450 | + var sch = gb_schedule_table.findScheduleByLine(lineCode)[id]; | ||
| 451 | + if(!sch) | ||
| 452 | + return; | ||
| 453 | + | ||
| 454 | + gb_schedule_context_menu.lj_zrw(sch); | ||
| 455 | + }); | ||
| 456 | + | ||
| 393 | return { | 457 | return { |
| 394 | sock: function () { | 458 | sock: function () { |
| 395 | return schSock; | 459 | return schSock; |
src/main/resources/static/real_control_v2/js/zndd/data_zndd.js
| 1 | var gb_dataZndd = (function (){ | 1 | var gb_dataZndd = (function (){ |
| 2 | 2 | ||
| 3 | - var max = 1; | 3 | + var max = 3; |
| 4 | + var max_s = 5; | ||
| 4 | var $pop =$('.multi_plat_msg_pop_zndd'); | 5 | var $pop =$('.multi_plat_msg_pop_zndd'); |
| 5 | 6 | ||
| 6 | var codes = { | 7 | var codes = { |
| @@ -11,6 +12,7 @@ var gb_dataZndd = (function (){ | @@ -11,6 +12,7 @@ var gb_dataZndd = (function (){ | ||
| 11 | 'DKL': '大客流', | 12 | 'DKL': '大客流', |
| 12 | 'YCSF':'异常实发', | 13 | 'YCSF':'异常实发', |
| 13 | 'SFTZ_1': '实发未发,信号异常', | 14 | 'SFTZ_1': '实发未发,信号异常', |
| 15 | + 'DESCTWO':'末二班车即将发车' | ||
| 14 | }; | 16 | }; |
| 15 | 17 | ||
| 16 | 18 | ||
| @@ -18,15 +20,17 @@ var gb_dataZndd = (function (){ | @@ -18,15 +20,17 @@ var gb_dataZndd = (function (){ | ||
| 18 | var dataMap = new Map(); | 20 | var dataMap = new Map(); |
| 19 | var leftTime = 1000 * 10;//剩余的毫秒数 | 21 | var leftTime = 1000 * 10;//剩余的毫秒数 |
| 20 | var sop = function (data) { | 22 | var sop = function (data) { |
| 21 | - | ||
| 22 | //时间格式化 | 23 | //时间格式化 |
| 23 | data.types = codes[data.type]; | 24 | data.types = codes[data.type]; |
| 24 | 25 | ||
| 25 | - | ||
| 26 | - if (data.type == 'SFTZ_1' && sf_tz(data.lineCode) == false){ | 26 | + /* if (data.type == 'SFTZ_1' && sf_tz(data.lineCode) == false){ |
| 27 | return | 27 | return |
| 28 | } | 28 | } |
| 29 | +*/ | ||
| 29 | 30 | ||
| 31 | + if ((data.type == 'WD' || data.type == 'MZ' || data.type == 'FCJG' || data.type == 'DJG') && ycsf_sx(data.lineCode) == false){ | ||
| 32 | + return | ||
| 33 | + } | ||
| 30 | 34 | ||
| 31 | 35 | ||
| 32 | var stm = moment(new Date()); | 36 | var stm = moment(new Date()); |
| @@ -39,9 +43,15 @@ var gb_dataZndd = (function (){ | @@ -39,9 +43,15 @@ var gb_dataZndd = (function (){ | ||
| 39 | return; | 43 | return; |
| 40 | } | 44 | } |
| 41 | 45 | ||
| 46 | + if (data.type == 'DESCTWO'){ | ||
| 47 | + configurecell(); | ||
| 48 | + return; | ||
| 49 | + } | ||
| 50 | + | ||
| 51 | + | ||
| 42 | configure(); | 52 | configure(); |
| 43 | 53 | ||
| 44 | - //配置 随到随发 配置div方案 | 54 | + //定时方案 |
| 45 | function configure(){ | 55 | function configure(){ |
| 46 | 56 | ||
| 47 | var htmlStr = template('zndd_plat_msg_template_config', data); | 57 | var htmlStr = template('zndd_plat_msg_template_config', data); |
| @@ -63,6 +73,17 @@ var gb_dataZndd = (function (){ | @@ -63,6 +73,17 @@ var gb_dataZndd = (function (){ | ||
| 63 | 73 | ||
| 64 | //gb_tts.audition(msg, 1.2); //语音播报 | 74 | //gb_tts.audition(msg, 1.2); //语音播报 |
| 65 | } | 75 | } |
| 76 | + //无定时器方案 | ||
| 77 | + function configurecell(){ | ||
| 78 | + var htmlStr = template('zndd_plat_msg_template_config_s', data); | ||
| 79 | + var items = $pop.find('.multi_plat_config_s'), | ||
| 80 | + len = items.length; | ||
| 81 | + | ||
| 82 | + if (len >= max_s) | ||
| 83 | + $pop.find('.multi_plat_config_s:lt(' + (len - max_s) + ')').remove(); | ||
| 84 | + | ||
| 85 | + $pop.append(htmlStr); | ||
| 86 | + } | ||
| 66 | 87 | ||
| 67 | function configureDkl(){ | 88 | function configureDkl(){ |
| 68 | var htmlStr = template('zndd_plat_msg_template_dkl', data); | 89 | var htmlStr = template('zndd_plat_msg_template_dkl', data); |
| @@ -94,7 +115,7 @@ var gb_dataZndd = (function (){ | @@ -94,7 +115,7 @@ var gb_dataZndd = (function (){ | ||
| 94 | } | 115 | } |
| 95 | 116 | ||
| 96 | 117 | ||
| 97 | - //1078路,1135路,南临专线,临港4路,浦东111路,浦东74路,临港13路,申港3路,浦东29路,新芦专线 | 118 | + //芦潮港1路 新临专线,临港10路, 浦东107路, 浦东91路,1078路,1135路,南临专线,临港4路,浦东111路,浦东74路,临港13路,申港3路,浦东29路,新芦专线 |
| 98 | function ycsf_sx(line){ | 119 | function ycsf_sx(line){ |
| 99 | var t =['12101','200828','230308','220826','201012','10636','60033','88814','88818','180926','191221','210821','230311','230329','803111']; | 120 | var t =['12101','200828','230308','220826','201012','10636','60033','88814','88818','180926','191221','210821','230311','230329','803111']; |
| 100 | 121 | ||
| @@ -105,16 +126,7 @@ var gb_dataZndd = (function (){ | @@ -105,16 +126,7 @@ var gb_dataZndd = (function (){ | ||
| 105 | return false; | 126 | return false; |
| 106 | } | 127 | } |
| 107 | 128 | ||
| 108 | - //1078路,1135路,南临专线,临港4路,浦东111路,浦东74路,临港13路,申港3路,浦东29路,新芦专线 | ||
| 109 | - function sf_tz(line){ | ||
| 110 | - var t =['80301']; | ||
| 111 | 129 | ||
| 112 | - for (var lines in t){ | ||
| 113 | - if(line == t[lines]) | ||
| 114 | - return true; | ||
| 115 | - } | ||
| 116 | - return false; | ||
| 117 | - } | ||
| 118 | //发车信息微调 | 130 | //发车信息微调 |
| 119 | $pop.on('click', '.fcxxwts', function () { | 131 | $pop.on('click', '.fcxxwts', function () { |
| 120 | if (close) close = false | 132 | if (close) close = false |
| @@ -161,9 +173,9 @@ var gb_dataZndd = (function (){ | @@ -161,9 +173,9 @@ var gb_dataZndd = (function (){ | ||
| 161 | alt_confirm(content, function () { | 173 | alt_confirm(content, function () { |
| 162 | gb_common.$post('/realSchedule/realOutAdjust_zndd', { | 174 | gb_common.$post('/realSchedule/realOutAdjust_zndd', { |
| 163 | id: that.data('id'), | 175 | id: that.data('id'), |
| 164 | - remarks:'自动调度实发未发-车辆掉线', | ||
| 165 | - fcsjActual:that.data('fcsj') | ||
| 166 | - | 176 | + remarks:that.data('fcsjactual') != null ? '实发未发-车辆掉线-rfid' : '实发未发-车辆掉线' , |
| 177 | + fcsjActual: that.data('fcsjactual') != null ? that.data('fcsjactual') : that.data('fcsj'), | ||
| 178 | + | ||
| 167 | }, function (rs) { | 179 | }, function (rs) { |
| 168 | if(rs.length != 0) { | 180 | if(rs.length != 0) { |
| 169 | gb_schedule_table.updateSchedule(rs.ts); | 181 | gb_schedule_table.updateSchedule(rs.ts); |
| @@ -360,8 +372,8 @@ var gb_dataZndd = (function (){ | @@ -360,8 +372,8 @@ var gb_dataZndd = (function (){ | ||
| 360 | 372 | ||
| 361 | gb_common.$post('/realSchedule/realOutAdjust_zndd', { | 373 | gb_common.$post('/realSchedule/realOutAdjust_zndd', { |
| 362 | id: sch.sch.id, | 374 | id: sch.sch.id, |
| 363 | - remarks:'自动调度实发未发-车辆掉线', | ||
| 364 | - fcsjActual: sch.sch.dfsj, | 375 | + remarks:sch.sch.fcsjActual != null? '实发未发-车辆掉线-rfid' : '实发未发-车辆掉线' , |
| 376 | + fcsjActual: sch.sch.fcsjActual != null ? sch.sch.fcsjActual : sch.sch.dfsj, | ||
| 365 | }, function (rs) { | 377 | }, function (rs) { |
| 366 | gb_schedule_table.updateSchedule(rs.ts); | 378 | gb_schedule_table.updateSchedule(rs.ts); |
| 367 | notify_succ('实发未发操作成功!'); | 379 | notify_succ('实发未发操作成功!'); |
| @@ -377,10 +389,14 @@ var gb_dataZndd = (function (){ | @@ -377,10 +389,14 @@ var gb_dataZndd = (function (){ | ||
| 377 | } | 389 | } |
| 378 | });*/ | 390 | });*/ |
| 379 | } else if (type == "KLYJ"){ | 391 | } else if (type == "KLYJ"){ |
| 380 | - if(!$('#schedule-addsch-modal').hasClass('uk-open')){ | ||
| 381 | - open_modal("/real_control_v2/zndd/type/dkl.html", { | ||
| 382 | - data: data | ||
| 383 | - }, {center: true, bgclose: false, modal: true}); | 392 | + if (data.excuteStatus == 0){ |
| 393 | + if(!$('#schedule-addsch-modal').hasClass('uk-open')){ | ||
| 394 | + var ljtype = $('#ljtype').val(); | ||
| 395 | + data.ljtype = ljtype; | ||
| 396 | + open_modal("/real_control_v2/zndd/type/dkl.html", { | ||
| 397 | + data: data | ||
| 398 | + }, {center: true, bgclose: false, modal: true}); | ||
| 399 | + } | ||
| 384 | } | 400 | } |
| 385 | } | 401 | } |
| 386 | } | 402 | } |
| @@ -408,6 +424,7 @@ var gb_dataZndd = (function (){ | @@ -408,6 +424,7 @@ var gb_dataZndd = (function (){ | ||
| 408 | } | 424 | } |
| 409 | }; | 425 | }; |
| 410 | } | 426 | } |
| 427 | + | ||
| 411 | return { | 428 | return { |
| 412 | sop : sop, | 429 | sop : sop, |
| 413 | snt : snt, | 430 | snt : snt, |
src/main/resources/static/real_control_v2/js/zndd/recorder/recorder.js
| @@ -205,7 +205,7 @@ | @@ -205,7 +205,7 @@ | ||
| 205 | sch.zdzCode = responseText[3]; | 205 | sch.zdzCode = responseText[3]; |
| 206 | sch.xlDir = responseText[4]; | 206 | sch.xlDir = responseText[4]; |
| 207 | sch.zdsjActual = moment(new Date()).format("HH:mm") | 207 | sch.zdsjActual = moment(new Date()).format("HH:mm") |
| 208 | - open_modal(folder + '/temp_sch/main.html', { | 208 | + open_modal(folder + '/temp_sch/main_recorder.html', { |
| 209 | sch: sch | 209 | sch: sch |
| 210 | }, modal_opts); | 210 | }, modal_opts); |
| 211 | }); | 211 | }); |
src/main/resources/static/real_control_v2/main.html
| @@ -289,7 +289,7 @@ | @@ -289,7 +289,7 @@ | ||
| 289 | <script id="zndd_plat_msg_template_config" type="text/html"> | 289 | <script id="zndd_plat_msg_template_config" type="text/html"> |
| 290 | <div class="multi_plat_config" data-linecode="{{lineCode}}" data-station="{{station}}" data-stationname="{{stationName}}" data-numtype="{{numType}}" | 290 | <div class="multi_plat_config" data-linecode="{{lineCode}}" data-station="{{station}}" data-stationname="{{stationName}}" data-numtype="{{numType}}" |
| 291 | data-xlname="{{lineName}}" data-type="{{type}}" data-xldir="{{xlDir}}" data-rqstr="{{rqStr}}" data-types ="{{types}}" data-regionstopid="{{lg != null?lg.regionStopid:''}}" data-lgtype ="{{lg != null?lg.lGType:''}}" | 291 | data-xlname="{{lineName}}" data-type="{{type}}" data-xldir="{{xlDir}}" data-rqstr="{{rqStr}}" data-types ="{{types}}" data-regionstopid="{{lg != null?lg.regionStopid:''}}" data-lgtype ="{{lg != null?lg.lGType:''}}" |
| 292 | - data-rq="{{rq}}" data-ids="{{ids}}" data-uuid="{{uuid}}"> | 292 | + data-rq="{{rq}}" data-ids="{{ids}}" data-uuid="{{uuid}}" data-fcsjactual="{{fcsjActual}}"> |
| 293 | <div id ={{uuid}} class="timer"></div> | 293 | <div id ={{uuid}} class="timer"></div> |
| 294 | <div class="msg-popup warning-color"> | 294 | <div class="msg-popup warning-color"> |
| 295 | <div class="msg-times" style="cursor: pointer;">×</div> | 295 | <div class="msg-times" style="cursor: pointer;">×</div> |
| @@ -307,19 +307,74 @@ | @@ -307,19 +307,74 @@ | ||
| 307 | </div> | 307 | </div> |
| 308 | 308 | ||
| 309 | <div class="popup-msg-contents" style="display:{{type == 'WD'?'':'none'}}"> | 309 | <div class="popup-msg-contents" style="display:{{type == 'WD'?'':'none'}}"> |
| 310 | - <button class="uk-button uk-button-primary fcxxwts" data-fcsj="{{fcsj}}" data-clzbh="{{clzbh}}" data-id="{{id}}">发车信息微调</button> | 310 | + <button class="uk-button uk-button-primary fcxxwts" data-fcsj="{{fcsj}}" data-clzbh="{{clzbh}}" data-id="{{id}}">发车信息微调工具</button> |
| 311 | </div> | 311 | </div> |
| 312 | 312 | ||
| 313 | <div class="centerSpace msg-title"> | 313 | <div class="centerSpace msg-title"> |
| 314 | <div></div> | 314 | <div></div> |
| 315 | <div class="msg-date-infos" style="display:{{type == 'SFTZ_1'?'':'none'}}" > | 315 | <div class="msg-date-infos" style="display:{{type == 'SFTZ_1'?'':'none'}}" > |
| 316 | - <button class="uk-button uk-button-primary sfTzbc" data-fcsj="{{fcsj}}" data-clzbh="{{clzbh}}" data-id="{{id}}">补入发车时间</button> | 316 | + <button class="uk-button uk-button-primary sfTzbc" data-fcsj="{{fcsj}}" data-fcsjactual="{{fcsjActual}}" data-clzbh="{{clzbh}}" data-id="{{id}}">补入发车时间</button> |
| 317 | </div> | 317 | </div> |
| 318 | </div> | 318 | </div> |
| 319 | </div> | 319 | </div> |
| 320 | </div> | 320 | </div> |
| 321 | +</script> | ||
| 322 | +<script id="zndd_plat_msg_template_config_s" type="text/html"> | ||
| 321 | 323 | ||
| 324 | + <div class="multi_plat_config_s"> | ||
| 325 | + <div class="msg-popup warning-color"> | ||
| 326 | + <div class="msg-times" style="cursor: pointer;">×</div> | ||
| 327 | + <div class="centerSpace msg-title"> | ||
| 328 | + <div>自动调度消息-待确认</div> | ||
| 329 | + <div class="msg-date-info">{{datarq}}</div> | ||
| 330 | + </div> | ||
| 331 | + <div class="popup-msg-content"> | ||
| 332 | + <i class="fa fa-info-circle" aria-hidden="true"></i> | ||
| 333 | + <span>{{lineName}} {{xlDir ==0 ?'上行':'下行'}} {{clzbh}} {{fcsj}} 出现 {{types}}</span> | ||
| 334 | + </div> | ||
| 335 | + </div> | ||
| 336 | + </div> | ||
| 337 | +</script> | ||
| 338 | +<script id="sjZ-divs-temp" type="text/html"> | ||
| 339 | + | ||
| 340 | + <div class="history" style="margin-top:50px;height: 450px;overflow-y: scroll"> | ||
| 341 | + <div class="history-date" STYLE="padding-top:10px;"> | ||
| 342 | + <ul> | ||
| 343 | + <li> | ||
| 344 | + <h3>{{rq1}}<span>{{rqStr}}</span></h3> | ||
| 345 | + <dl> | ||
| 346 | + <dt>检测到异常情况</dt> | ||
| 347 | + </dl> | ||
| 348 | + </li> | ||
| 349 | + </ul> | ||
| 350 | + <ul> | ||
| 351 | + <li> | ||
| 352 | + <h3>{{rq2}}<span>{{rqStr}}</></h3> | ||
| 353 | + <dl> | ||
| 354 | + <dt>推送到线调页面</dt> | ||
| 355 | + </dl> | ||
| 356 | + </li> | ||
| 357 | + </ul> | ||
| 358 | + <ul> | ||
| 359 | + <li> | ||
| 360 | + <h3>{{rq2}}<span>{{rqStr}}</span></h3> | ||
| 361 | + <dl> | ||
| 362 | + <dt>生成配置调度工具</dt> | ||
| 363 | + </dl> | ||
| 364 | + </li> | ||
| 365 | + </ul> | ||
| 366 | + <ul> | ||
| 367 | + <li> | ||
| 368 | + <h3>{{rq2}}<span>{{rqStr}}</span></h3> | ||
| 369 | + <dl> | ||
| 370 | + <dt>生成最佳处置方式</dt> | ||
| 371 | + </dl> | ||
| 372 | + </li> | ||
| 373 | + </ul> | ||
| 374 | + </div> | ||
| 375 | + </div> | ||
| 322 | </script> | 376 | </script> |
| 377 | + | ||
| 323 | <div class="multi_plat_msg_pop_zndd"> | 378 | <div class="multi_plat_msg_pop_zndd"> |
| 324 | <!--<div id="timer"></div>--> | 379 | <!--<div id="timer"></div>--> |
| 325 | </div> | 380 | </div> |
| @@ -327,6 +382,8 @@ | @@ -327,6 +382,8 @@ | ||
| 327 | <div class="multi_plat_msg_pop_klyj" ></div> | 382 | <div class="multi_plat_msg_pop_klyj" ></div> |
| 328 | <script id="klyj_plat_msg_template" type="text/html"> | 383 | <script id="klyj_plat_msg_template" type="text/html"> |
| 329 | <div class="multi_plat_config" data-type="{{type}}" data-uuid="{{uuid}}"> | 384 | <div class="multi_plat_config" data-type="{{type}}" data-uuid="{{uuid}}"> |
| 385 | + <div class="msg-popup warning-color" style="text-align: center;min-height: 0;"> <span>智能调度助手分析</span></div> | ||
| 386 | + <div id="depsepDiv" class="msg-popup warning-color" style="white-space: pre-line;"></div> | ||
| 330 | <div id ={{uuid}} class="timer"></div> | 387 | <div id ={{uuid}} class="timer"></div> |
| 331 | <div class="msg-popup warning-color"> | 388 | <div class="msg-popup warning-color"> |
| 332 | <div class="msg-times" style="cursor: pointer;">×</div> | 389 | <div class="msg-times" style="cursor: pointer;">×</div> |
| @@ -339,9 +396,34 @@ | @@ -339,9 +396,34 @@ | ||
| 339 | <div class="popup-msg-content"> | 396 | <div class="popup-msg-content"> |
| 340 | <span>站点人数 {{num}} 预警时间 {{timeStr}}</span> | 397 | <span>站点人数 {{num}} 预警时间 {{timeStr}}</span> |
| 341 | </div> | 398 | </div> |
| 399 | + <div class=""> | ||
| 400 | + <select class="form-control uk-margin-small-top" id ="ljtype" style="width: 180px;" > | ||
| 401 | + <option value="lin1">方案1:临加正常班次</option> | ||
| 402 | + <option value="lin2">方案2:临加区间班次</option> | ||
| 403 | + <option value="lin3">方案3:调整发车时间</option> | ||
| 404 | + </select> | ||
| 405 | + </div> | ||
| 406 | + <div class="dkl_msg_text lin1"> | ||
| 407 | + <span> | ||
| 408 | + 添加一辆起点站到终点站的正常班次。<br> | ||
| 409 | + 较适于始发站<br> | ||
| 410 | + </span> | ||
| 411 | + </div> | ||
| 412 | + <div class="dkl_msg_text lin2" style="display: none"> | ||
| 413 | + <span> | ||
| 414 | + 车辆到当前站点,从当前站点开始营运。<br> | ||
| 415 | + 适用于中途站<br> | ||
| 416 | + </span> | ||
| 417 | + </div> | ||
| 418 | + <div class="dkl_msg_text lin3" style="display: none"> | ||
| 419 | + <span> | ||
| 420 | + 提前发车下一班车<br> | ||
| 421 | + 适用于起点站<br> | ||
| 422 | + </span> | ||
| 423 | + </div> | ||
| 342 | <div class="popup-msg-contents" > | 424 | <div class="popup-msg-contents" > |
| 343 | <button class="uk-button uk-button-primary images" data-image="{{image}}" value="{{dir}}">查看图片</button> | 425 | <button class="uk-button uk-button-primary images" data-image="{{image}}" value="{{dir}}">查看图片</button> |
| 344 | - <button class="uk-button uk-button-primary ljbc" data-uuid="{{uuid}}" data-linecode="{{sch.xlBm}}" data-id="{{sch.id}}">临加班次</button> | 426 | + <button class="uk-button uk-button-primary ljbc" data-uuid="{{uuid}}" data-linecode="{{sch.xlBm}}" data-id="{{sch.id}}">选择方案</button> |
| 345 | </div> | 427 | </div> |
| 346 | </div> | 428 | </div> |
| 347 | </div> | 429 | </div> |
src/main/resources/static/real_control_v2/zndd/deepseek/deepseek.html
0 → 100644
| 1 | +<div class="uk-modal ct-form-modal" id="tts-config-modal"> | ||
| 2 | + <div class="uk-modal-dialog" style="width: 1030px;"> | ||
| 3 | + <a href="" class="uk-modal-close uk-close"></a> | ||
| 4 | + <div class="uk-modal-header"> | ||
| 5 | + <h2>调度助手(deepseek)</h2></div> | ||
| 6 | + | ||
| 7 | + <div class="chat-container"> | ||
| 8 | + <div class="messages-container" id="messages"></div> | ||
| 9 | + <div class="typing-indicator" id="typing" style="display: none;">DeepSeek 正在思考输入...</div> | ||
| 10 | + <div class="input-container"> | ||
| 11 | + <input type="text" id="input" placeholder="输入你的问题..."> | ||
| 12 | + <button onclick="sendMessage()">发送</button> | ||
| 13 | + </div> | ||
| 14 | + </div> | ||
| 15 | + </div> | ||
| 16 | + <style> | ||
| 17 | + | ||
| 18 | + | ||
| 19 | + .chat-container { | ||
| 20 | + max-width: 800px; | ||
| 21 | + margin: 0 auto; | ||
| 22 | + background-color: white; | ||
| 23 | + border-radius: 10px; | ||
| 24 | + box-shadow: 0 2px 10px rgba(0,0,0,0.1); | ||
| 25 | + } | ||
| 26 | + | ||
| 27 | + .messages-container { | ||
| 28 | + height: 500px; | ||
| 29 | + overflow-y: auto; | ||
| 30 | + padding: 20px; | ||
| 31 | + } | ||
| 32 | + | ||
| 33 | + .message { | ||
| 34 | + display: flex; | ||
| 35 | + margin-bottom: 15px; | ||
| 36 | + } | ||
| 37 | + | ||
| 38 | + .message.user { | ||
| 39 | + justify-content: flex-end; | ||
| 40 | + } | ||
| 41 | + | ||
| 42 | + .message.bot { | ||
| 43 | + justify-content: flex-start; | ||
| 44 | + } | ||
| 45 | + | ||
| 46 | + .bubble { | ||
| 47 | + max-width: 70%; | ||
| 48 | + padding: 12px 18px; | ||
| 49 | + border-radius: 15px; | ||
| 50 | + line-height: 1.4; | ||
| 51 | + white-space: pre-line; | ||
| 52 | + } | ||
| 53 | + | ||
| 54 | + .user .bubble { | ||
| 55 | + background-color: #007bff; | ||
| 56 | + color: white; | ||
| 57 | + } | ||
| 58 | + | ||
| 59 | + .bot .bubble { | ||
| 60 | + background-color: #e9ecef; | ||
| 61 | + color: black; | ||
| 62 | + } | ||
| 63 | + | ||
| 64 | + .input-container { | ||
| 65 | + display: flex; | ||
| 66 | + padding: 20px; | ||
| 67 | + border-top: 1px solid #ddd; | ||
| 68 | + } | ||
| 69 | + | ||
| 70 | + input[type="text"] { | ||
| 71 | + flex: 1; | ||
| 72 | + padding: 12px; | ||
| 73 | + border: 1px solid #ddd; | ||
| 74 | + border-radius: 5px; | ||
| 75 | + margin-right: 10px; | ||
| 76 | + } | ||
| 77 | + | ||
| 78 | + button { | ||
| 79 | + padding: 12px 24px; | ||
| 80 | + background-color: #007bff; | ||
| 81 | + color: white; | ||
| 82 | + border: none; | ||
| 83 | + border-radius: 5px; | ||
| 84 | + cursor: pointer; | ||
| 85 | + } | ||
| 86 | + | ||
| 87 | + button:hover { | ||
| 88 | + background-color: #0056b3; | ||
| 89 | + } | ||
| 90 | + | ||
| 91 | + .typing-indicator { | ||
| 92 | + padding: 0 20px 10px; | ||
| 93 | + color: #666; | ||
| 94 | + font-style: italic; | ||
| 95 | + } | ||
| 96 | + </style> | ||
| 97 | + <script> | ||
| 98 | + const messagesContainer = document.getElementById('messages'); | ||
| 99 | + const input = document.getElementById('input'); | ||
| 100 | + const typingIndicator = document.getElementById('typing'); | ||
| 101 | + | ||
| 102 | + // 处理回车键 | ||
| 103 | + input.addEventListener('keypress', (e) => { | ||
| 104 | + if (e.key === 'Enter') { | ||
| 105 | + sendMessage(); | ||
| 106 | + } | ||
| 107 | + }); | ||
| 108 | + | ||
| 109 | + function sendMessage() { | ||
| 110 | + const message = input.value.trim(); | ||
| 111 | + if (!message) return; | ||
| 112 | + | ||
| 113 | + // 添加用户消息 | ||
| 114 | + addMessage(message, 'user'); | ||
| 115 | + input.value = ''; | ||
| 116 | + var tEnum ={ | ||
| 117 | + xl_1 : "线", | ||
| 118 | + xl_2 : "路", | ||
| 119 | + yyqk : "营运情况", | ||
| 120 | + } | ||
| 121 | + | ||
| 122 | + // 模拟AI回复 | ||
| 123 | + let date = { | ||
| 124 | + "message": message/*"遇到大客流帮我推荐一种方案"*/, //消息 | ||
| 125 | + "mode": "query" //chat聊天 query知识库查询 选一个 | ||
| 126 | + } | ||
| 127 | + //线路 | ||
| 128 | + if ((message.includes(tEnum.xl_1) && message.includes(tEnum.yyqk)) || (message.includes(tEnum.xl_2) && message.includes(tEnum.yyqk))){ | ||
| 129 | + bcyyqk(message); | ||
| 130 | + }else { | ||
| 131 | + subtim(date); | ||
| 132 | + } | ||
| 133 | + showTypingIndicator(); | ||
| 134 | + | ||
| 135 | + | ||
| 136 | + | ||
| 137 | + } | ||
| 138 | + | ||
| 139 | + function addMessage(text, sender) { | ||
| 140 | + const messageDiv = document.createElement('div'); | ||
| 141 | + messageDiv.className = `message ${sender}`; | ||
| 142 | + | ||
| 143 | + const bubble = document.createElement('div'); | ||
| 144 | + bubble.className = 'bubble'; | ||
| 145 | + bubble.textContent = text; | ||
| 146 | + if (sender == 'bot'){ | ||
| 147 | + bubble.textContent = ''; | ||
| 148 | + tests = text | ||
| 149 | + bubbles = bubble; | ||
| 150 | + char_index = 0; | ||
| 151 | + //type(text); | ||
| 152 | + } | ||
| 153 | + messageDiv.appendChild(bubble); | ||
| 154 | + messagesContainer.appendChild(messageDiv); | ||
| 155 | + | ||
| 156 | + // 自动滚动到底部 | ||
| 157 | + messagesContainer.scrollTop = messagesContainer.scrollHeight; | ||
| 158 | + } | ||
| 159 | + var tests ="" | ||
| 160 | + var bubbles; | ||
| 161 | + char_index = 0 | ||
| 162 | + | ||
| 163 | + function bcyyqk(message){ | ||
| 164 | + $.get("/logZndd/schDeepSeep",{message:message},function (re){ | ||
| 165 | + if (re.code == 200){ | ||
| 166 | + //根据返回的参数组成一句话,再让deepseep扩充一下 | ||
| 167 | + var mes = "根据后面这些话,解析并优化一下,"+"线路:"+re.xlName+",总班次数"+re.bcs | ||
| 168 | + +",进场班次数"+re.inbcs+",出场班次数"+re.outbcs+",临加班次数"+re.ljbcs+",正常班次数"+re.normalbcs | ||
| 169 | + +",区间班次"+re.regionbcs+",未执行班次数"+re.wzxbcs+",正在执行班次数"+re.zzxbcs+",已执行班次数"+re.yzxbcs | ||
| 170 | + +",烂班班次数" +re.lbbcs; | ||
| 171 | + | ||
| 172 | + console.log(mes); | ||
| 173 | + var datas = { | ||
| 174 | + "message": mes/*"遇到大客流帮我推荐一种方案"*/, //消息 | ||
| 175 | + "mode": "chat" //chat聊天 query知识库查询 选一个 | ||
| 176 | + } | ||
| 177 | + | ||
| 178 | + subtim(datas); | ||
| 179 | + }else { | ||
| 180 | + // 弹出添加失败提示消息 | ||
| 181 | + layer.msg('无法找到输入线路...'); | ||
| 182 | + hideTypingIndicator(); | ||
| 183 | + } | ||
| 184 | + }) | ||
| 185 | + } | ||
| 186 | + | ||
| 187 | + | ||
| 188 | + function subtim(date){ | ||
| 189 | + | ||
| 190 | + const apiUrl = 'http://61.169.120.202:3001/api/v1/workspace/deep/stream-chat'; // 替换为实际接口地址 | ||
| 191 | + let xhr = new XMLHttpRequest(); | ||
| 192 | + xhr.open('POST', apiUrl, true); | ||
| 193 | + // 设置请求头 | ||
| 194 | + xhr.setRequestHeader('Content-Type', 'application/json'); | ||
| 195 | + xhr.setRequestHeader('Authorization', `Bearer 701MSMS-JNS4WNG-JSDY4GH-RHD93NM`); | ||
| 196 | + | ||
| 197 | + addMessage("", 'bot'); | ||
| 198 | + var ins = 0; | ||
| 199 | + // 监听数据流 | ||
| 200 | + xhr.onprogress = function (event) { | ||
| 201 | + // 获取当前接收的数据片段 | ||
| 202 | + const responseText = xhr.responseText; | ||
| 203 | + const lines = responseText.split('\n').filter(line => line !== ''); | ||
| 204 | + try { | ||
| 205 | + for (var i = 0 ; i < lines.length ; i ++) { | ||
| 206 | + if (i >= ins || ins == 0) { | ||
| 207 | + ins = i +1; | ||
| 208 | + var line = lines[i].replace(/^data: /, ''); | ||
| 209 | + const data = JSON.parse(line); | ||
| 210 | + let txt = bubbles.textContent; | ||
| 211 | + bubbles.textContent += data.textResponse!= null? data.textResponse :""; | ||
| 212 | + //结束 | ||
| 213 | + if (data.type == "finalizeResponseStream"){ | ||
| 214 | + hideTypingIndicator(); | ||
| 215 | + } | ||
| 216 | + } | ||
| 217 | + } | ||
| 218 | + } catch (e) { | ||
| 219 | + console.error('解析错误:', e); | ||
| 220 | + } | ||
| 221 | + }; | ||
| 222 | + | ||
| 223 | + // 发送请求 | ||
| 224 | + const requestBody = JSON.stringify(date); | ||
| 225 | + xhr.send(requestBody); | ||
| 226 | + | ||
| 227 | + // 错误处理 | ||
| 228 | + xhr.onerror = function () { | ||
| 229 | + console.error('请求失败'); | ||
| 230 | + }; | ||
| 231 | + | ||
| 232 | + | ||
| 233 | + ///一次性请求的方法,慢弃用。 | ||
| 234 | + /* // 提交 | ||
| 235 | + $.ajax({ | ||
| 236 | + type: 'POST', | ||
| 237 | + url: "http://192.168.168.141:3001/api/v1/workspace/deep/stream-chat", | ||
| 238 | + contentType: "application/json", | ||
| 239 | + headers: { | ||
| 240 | + authorization: "Bearer 701MSMS-JNS4WNG-JSDY4GH-RHD93NM", | ||
| 241 | + }, | ||
| 242 | + timeout: 0, | ||
| 243 | + data: JSON.stringify(date), | ||
| 244 | + success: function(datas){ | ||
| 245 | + setTimeout(() => { | ||
| 246 | + hideTypingIndicator(); | ||
| 247 | + addMessage(datas.textResponse, 'bot'); | ||
| 248 | + }, 1500); | ||
| 249 | + }, | ||
| 250 | + error: function(xhr, type){ | ||
| 251 | + alert('错误:TODO'); | ||
| 252 | + } | ||
| 253 | + });*/ | ||
| 254 | + } | ||
| 255 | + | ||
| 256 | + | ||
| 257 | + function showTypingIndicator() { | ||
| 258 | + typingIndicator.style.display = 'block'; | ||
| 259 | + messagesContainer.scrollTop = messagesContainer.scrollHeight; | ||
| 260 | + } | ||
| 261 | + | ||
| 262 | + function hideTypingIndicator() { | ||
| 263 | + typingIndicator.style.display = 'none'; | ||
| 264 | + } | ||
| 265 | + | ||
| 266 | + </script> | ||
| 267 | +</div> | ||
| 268 | + |
src/main/resources/static/real_control_v2/zndd/qjgz/list.html
| @@ -22,12 +22,12 @@ | @@ -22,12 +22,12 @@ | ||
| 22 | <table class="ct-fixed-table uk-table uk-table-hover"> | 22 | <table class="ct-fixed-table uk-table uk-table-hover"> |
| 23 | <thead> | 23 | <thead> |
| 24 | <tr> | 24 | <tr> |
| 25 | - <th style="width: 10%;">线路</th> | ||
| 26 | - <th style="width: 10%;">车辆</th> | ||
| 27 | - <th style="width: 10%;">人员</th> | 25 | + <th style="width: 5%;">线路</th> |
| 26 | + <th style="width: 5%;">车辆</th> | ||
| 27 | + <th style="width: 5%;">人员</th> | ||
| 28 | <th style="width: 10%;">请假类型</th> | 28 | <th style="width: 10%;">请假类型</th> |
| 29 | <th style="width: 15%;">时间</th> | 29 | <th style="width: 15%;">时间</th> |
| 30 | - <th style="width: 35%;">处理方式</th> | 30 | + <th style="width: 50%;">处理方式</th> |
| 31 | </tr> | 31 | </tr> |
| 32 | </thead> | 32 | </thead> |
| 33 | <tbody> | 33 | <tbody> |
| @@ -54,10 +54,10 @@ | @@ -54,10 +54,10 @@ | ||
| 54 | <td>{{obj.rq}}</td> | 54 | <td>{{obj.rq}}</td> |
| 55 | <td > | 55 | <td > |
| 56 | {{if obj.qjType == 0}} | 56 | {{if obj.qjType == 0}} |
| 57 | - <button class="uk-button pllbon" data-id="{{obj.id}}"> 批量烂班</button> | ||
| 58 | - <button class="uk-button hrhc" data-id="{{obj.id}}"> 批量换人换车</button> | ||
| 59 | - <button class="uk-button lp_change" data-id="{{obj.id}}"> 路牌对调</button> | ||
| 60 | - <button class="uk-button cxlb" data-id="{{obj.id}}"> 恢复烂班</button> | 57 | + <button class="uk-button pllbon" data-id="{{obj.id}}"> 班次取消(烂班)工具</button> |
| 58 | + <button class="uk-button hrhc" data-id="{{obj.id}}"> 调整人车工具</button> | ||
| 59 | + <button class="uk-button lp_change" data-id="{{obj.id}}"> 路牌对调工具</button> | ||
| 60 | + <button class="uk-button cxlb" data-id="{{obj.id}}"> 撤销班次取消(烂班)工具</button> | ||
| 61 | {{else}} | 61 | {{else}} |
| 62 | 计划调度 -> 调度执勤日报 | 62 | 计划调度 -> 调度执勤日报 |
| 63 | {{/if}} | 63 | {{/if}} |
src/main/resources/static/real_control_v2/zndd/type/djg1.html
| 1 | <div class="uk-modal ct-form-modal ct_move_modal" id="schedule-addsch-modal"> | 1 | <div class="uk-modal ct-form-modal ct_move_modal" id="schedule-addsch-modal"> |
| 2 | - <div class="uk-modal-dialog" style="width: 1400px;"> | 2 | + <div class="uk-modal-dialog" style="width: 1500px;"> |
| 3 | <a href="" class="uk-modal-close uk-close"></a> | 3 | <a href="" class="uk-modal-close uk-close"></a> |
| 4 | <div class="uk-modal-header"> | 4 | <div class="uk-modal-header"> |
| 5 | <h2>新增临加班次</h2></div> | 5 | <h2>新增临加班次</h2></div> |
| 6 | - <div class="uk-grid uk-width-2-5" style="float: left"> | 6 | + |
| 7 | + <div class="uk-grid uk-width-1-6" style="float: left"> | ||
| 8 | + <div class="uk-width-5-5 sjzlist"> | ||
| 9 | + | ||
| 10 | + </div> | ||
| 11 | + </div> | ||
| 12 | + <div class="uk-grid uk-width-2-6" style="float: left"> | ||
| 7 | <div class="uk-width-5-5"> | 13 | <div class="uk-width-5-5"> |
| 8 | <form class="uk-form uk-form-horizontal"> </form> | 14 | <form class="uk-form uk-form-horizontal"> </form> |
| 9 | <div> | 15 | <div> |
| @@ -12,7 +18,7 @@ | @@ -12,7 +18,7 @@ | ||
| 12 | </div> | 18 | </div> |
| 13 | </div> | 19 | </div> |
| 14 | </div> | 20 | </div> |
| 15 | - <div class="uk-grid uk-width-3-5 lj_1" > | 21 | + <div class="uk-grid uk-width-3-6 lj_1" > |
| 16 | <div class="uk-width-1-4"> | 22 | <div class="uk-width-1-4"> |
| 17 | <ul data-uk-switcher="{connect:'#tempScheduleContent'}" class="uk-nav uk-nav-side left_tabs_lg"> | 23 | <ul data-uk-switcher="{connect:'#tempScheduleContent'}" class="uk-nav uk-nav-side left_tabs_lg"> |
| 18 | 24 | ||
| @@ -31,7 +37,7 @@ | @@ -31,7 +37,7 @@ | ||
| 31 | </div> | 37 | </div> |
| 32 | </div> | 38 | </div> |
| 33 | 39 | ||
| 34 | - <div class="uk-grid uk-width-3-5 lj_2" style="display: none; padding-left: 100px"> | 40 | + <div class="uk-grid uk-width-3-6 lj_2" style="display: none; padding-left: 100px"> |
| 35 | <div class="uk-width-1-1" id ="tempsdsf"></div> | 41 | <div class="uk-width-1-1" id ="tempsdsf"></div> |
| 36 | 42 | ||
| 37 | </div> | 43 | </div> |
| @@ -51,7 +57,10 @@ | @@ -51,7 +57,10 @@ | ||
| 51 | var formHtml = template('djg-form-temp', sch); | 57 | var formHtml = template('djg-form-temp', sch); |
| 52 | $('form', modal).html(formHtml); | 58 | $('form', modal).html(formHtml); |
| 53 | //切换 | 59 | //切换 |
| 54 | - | 60 | + sch.rq1 =moment(new Date().getTime() - (60 *1000)).format("HH:mm"); |
| 61 | + sch.rq2 =moment(new Date()).format("HH:mm") | ||
| 62 | + var formHtmls = template('sjZ-divs-temp', sch); | ||
| 63 | + $('.sjzlist', modal).html(formHtmls); | ||
| 55 | 64 | ||
| 56 | 65 | ||
| 57 | 66 |
src/main/resources/static/real_control_v2/zndd/type/dkl.html
| @@ -2,8 +2,15 @@ | @@ -2,8 +2,15 @@ | ||
| 2 | <div class="uk-modal-dialog" style="width: 1400px;"> | 2 | <div class="uk-modal-dialog" style="width: 1400px;"> |
| 3 | <a href="" class="uk-modal-close uk-close"></a> | 3 | <a href="" class="uk-modal-close uk-close"></a> |
| 4 | <div class="uk-modal-header"> | 4 | <div class="uk-modal-header"> |
| 5 | - <h2>新增临加班次<i class="uk-icon-question-circle uk-icon-hover"></i></h2></div> | ||
| 6 | - <div class="uk-grid uk-width-2-5" style="float: left"> | 5 | + <h2 style="width: 40%;float: left;">新增临加班次<i class="uk-icon-question-circle uk-icon-hover"></i></h2> |
| 6 | + <span style="color: red;font-weight: 700;"><div id ="xztimes" class="timer">------</div></span> | ||
| 7 | + </div> | ||
| 8 | + <div class="uk-grid uk-width-1-6" style="float: left"> | ||
| 9 | + <div class="uk-width-5-5 sjzlist"> | ||
| 10 | + | ||
| 11 | + </div> | ||
| 12 | + </div> | ||
| 13 | + <div class="uk-grid uk-width-2-6" style="float: left"> | ||
| 7 | <div class="uk-width-5-5"> | 14 | <div class="uk-width-5-5"> |
| 8 | <form class="uk-form uk-form-horizontal"> </form> | 15 | <form class="uk-form uk-form-horizontal"> </form> |
| 9 | <div> | 16 | <div> |
| @@ -12,7 +19,7 @@ | @@ -12,7 +19,7 @@ | ||
| 12 | </div> | 19 | </div> |
| 13 | </div> | 20 | </div> |
| 14 | </div> | 21 | </div> |
| 15 | - <div class="uk-grid uk-width-3-5 lj_1" > | 22 | + <div class="uk-grid uk-width-3-6 lj_1" > |
| 16 | <div class="uk-width-1-4"> | 23 | <div class="uk-width-1-4"> |
| 17 | <ul data-uk-switcher="{connect:'#tempScheduleContent'}" class="uk-nav uk-nav-side left_tabs_lg"> | 24 | <ul data-uk-switcher="{connect:'#tempScheduleContent'}" class="uk-nav uk-nav-side left_tabs_lg"> |
| 18 | <li data-handle="toAndFro"><a>1、往返</a></li> | 25 | <li data-handle="toAndFro"><a>1、往返</a></li> |
| @@ -29,14 +36,20 @@ | @@ -29,14 +36,20 @@ | ||
| 29 | </div> | 36 | </div> |
| 30 | </div> | 37 | </div> |
| 31 | 38 | ||
| 32 | - <div class="uk-grid uk-width-3-5 lj_2" style="display: none; padding-left: 100px"> | ||
| 33 | - <div class="uk-width-1-1" id ="tempsdsf"></div> | 39 | + <div class="uk-grid uk-width-3-6 lj_2" style="display: none; padding-left: 100px"> |
| 40 | + <form class="uk-form uk-form-horizontal add-sch-form one_form" id ="tempsdsf"> | ||
| 34 | 41 | ||
| 42 | + | ||
| 43 | + </form> | ||
| 35 | </div> | 44 | </div> |
| 36 | 45 | ||
| 37 | </div> | 46 | </div> |
| 38 | 47 | ||
| 39 | <script> | 48 | <script> |
| 49 | + | ||
| 50 | + | ||
| 51 | + var timemm = 1000 * 30 ; //定时器 自动执行 | ||
| 52 | + | ||
| 40 | (function () { | 53 | (function () { |
| 41 | var modal = '#schedule-addsch-modal', | 54 | var modal = '#schedule-addsch-modal', |
| 42 | sch, stationRoutes, parks, information, carsArray, st_park_data,conf; | 55 | sch, stationRoutes, parks, information, carsArray, st_park_data,conf; |
| @@ -48,25 +61,51 @@ | @@ -48,25 +61,51 @@ | ||
| 48 | 61 | ||
| 49 | var formHtml = template('djg-form-temp', sch); | 62 | var formHtml = template('djg-form-temp', sch); |
| 50 | $('form', modal).html(formHtml); | 63 | $('form', modal).html(formHtml); |
| 51 | - //切换 | ||
| 52 | - | ||
| 53 | - | ||
| 54 | 64 | ||
| 65 | + sch.rq1 =moment(new Date().getTime() - (60 *1000)).format("HH:mm"); | ||
| 66 | + sch.rq2 =moment(new Date()).format("HH:mm") | ||
| 67 | + var formHtmls = template('sjZ-divs-temp', sch); | ||
| 68 | + $('.sjzlist', modal).html(formHtmls); | ||
| 55 | 69 | ||
| 70 | + if (sch.ljtype == "lin3"){ | ||
| 71 | + $(".lj_1").css({ | ||
| 72 | + display: 'none' | ||
| 73 | + }); | ||
| 74 | + $(".lj_2").css({ | ||
| 75 | + display: '' | ||
| 76 | + }); | ||
| 56 | 77 | ||
| 57 | - //参数改变 | ||
| 58 | - $('form[name=yjtkForm] input', modal).on('blur', function () { | ||
| 59 | - var field = $(this).attr('name'); | ||
| 60 | - var val = $(this).val(); | ||
| 61 | - if (conf[field] != val) { | ||
| 62 | - var data = $('form[name=yjtkForm]', modal).serializeJSON(); | ||
| 63 | - data.lineCode = conf.line.lineCode; | ||
| 64 | - gb_common.$post('/lineConfig/yjtkSet', data, function (rs) { | ||
| 65 | - conf = rs.conf; | ||
| 66 | - notify_succ('调整随到随发参数'); | 78 | + $.get('/logZndd/nextSch/'+sch.sch.id, function (datan) { |
| 79 | + var formHtmls = template('sch_config_form-temp1', datan); | ||
| 80 | + $('#tempsdsf', modal).html(formHtmls); | ||
| 81 | + var f = $('#tempsdsf', modal).formValidation({ | ||
| 82 | + framework: 'uikit', | ||
| 83 | + locale: 'zh_CN' | ||
| 67 | }); | 84 | }); |
| 68 | - } | ||
| 69 | - }); | 85 | + $("#form-s-t").val("站点遭遇大客流"); |
| 86 | + f.on('success.form.fv', function(e) { | ||
| 87 | + e.preventDefault(); | ||
| 88 | + $('[type=submit]', f).attr('disabled', 'disabled'); | ||
| 89 | + var data = $(this).serializeJSON(); | ||
| 90 | + if(data.dfsj==sch.dfsj && data.remarks=='' && data.bcType == sch.bcType){ | ||
| 91 | + return; | ||
| 92 | + } | ||
| 93 | + gb_common.$post('/realSchedule/outgoAdjust', data, function(rs){ | ||
| 94 | + | ||
| 95 | + //更新班次信息 | ||
| 96 | + gb_schedule_table.updateSchedule(rs.ts); | ||
| 97 | + notify_succ('操作成功!'); | ||
| 98 | + UIkit.modal(modal).hide(); | ||
| 99 | + //重新计算应发未发 | ||
| 100 | + gb_schedule_table.calc_yfwf_num(sch.xlBm); | ||
| 101 | + }); | ||
| 102 | + }); | ||
| 103 | + }); | ||
| 104 | + } | ||
| 105 | + //定时器启动开关判定条件0开 1关 | ||
| 106 | + if (sch.excuteStatus == 0 && sch.ljtype == "lin1"){ | ||
| 107 | + var sntts = setInterval(function(){leftTimer();},1000); //开始倒计时 | ||
| 108 | + } | ||
| 70 | 109 | ||
| 71 | 110 | ||
| 72 | $("#destroySelect").on('change',function(){ | 111 | $("#destroySelect").on('change',function(){ |
| @@ -85,8 +124,8 @@ | @@ -85,8 +124,8 @@ | ||
| 85 | $(".lj_2").css({ | 124 | $(".lj_2").css({ |
| 86 | display: '' | 125 | display: '' |
| 87 | }); | 126 | }); |
| 88 | - $.get('/lineConfig/getByLineCode', {lineCode: sch.lineCode}, function (datan) { | ||
| 89 | - var formHtmls = template('buffer_config_form-temp1', datan); | 127 | + $.get('/nextSch/'+sch.sch.id, null, function (datan) { |
| 128 | + var formHtmls = template('sch_config_form-temp1', datan); | ||
| 90 | conf = datan; | 129 | conf = datan; |
| 91 | $('#tempsdsf', modal).html(formHtmls); | 130 | $('#tempsdsf', modal).html(formHtmls); |
| 92 | $('[name=enableYjtk]', modal).on('change', function () { | 131 | $('[name=enableYjtk]', modal).on('change', function () { |
| @@ -120,11 +159,11 @@ | @@ -120,11 +159,11 @@ | ||
| 120 | //to and fro | 159 | //to and fro |
| 121 | res.zdsjActual = moment(new Date().getTime() +(1000 * 60 *5)).format("HH:mm"); | 160 | res.zdsjActual = moment(new Date().getTime() +(1000 * 60 *5)).format("HH:mm"); |
| 122 | res.zdsj = moment(new Date().getTime() + (1000 * 60 * 5)).format("HH:mm"); | 161 | res.zdsj = moment(new Date().getTime() + (1000 * 60 * 5)).format("HH:mm"); |
| 123 | - $('.toAndFroCont', modal).html(st_doms.two_way_dom) | 162 | + $('.toAndFroCont', modal).html(st_doms.two_znddType_dom) |
| 124 | .trigger('init', {sch: res, submitFun: submit_temp_schedule_form, stationRoutes: stationRoutes}); | 163 | .trigger('init', {sch: res, submitFun: submit_temp_schedule_form, stationRoutes: stationRoutes}); |
| 125 | 164 | ||
| 126 | //normal | 165 | //normal |
| 127 | - $('.normalCont', modal).html(st_doms.normal_dom) | 166 | + $('.normalCont', modal).html(st_doms.normal_znddType_dom) |
| 128 | .trigger('init', {sch: res, submitFun: submit_temp_schedule_form}); | 167 | .trigger('init', {sch: res, submitFun: submit_temp_schedule_form}); |
| 129 | var kxcl=res.kxcl; | 168 | var kxcl=res.kxcl; |
| 130 | var arr=kxcl.split(','); | 169 | var arr=kxcl.split(','); |
| @@ -136,7 +175,7 @@ | @@ -136,7 +175,7 @@ | ||
| 136 | } | 175 | } |
| 137 | s+=arr[i]+","; | 176 | s+=arr[i]+","; |
| 138 | j++; | 177 | j++; |
| 139 | - if(j==4||i==arr.length-1){ | 178 | + if(j==3||i==arr.length-1){ |
| 140 | s=s.substring(0,s.length-1); | 179 | s=s.substring(0,s.length-1); |
| 141 | s+='</h3></label>'; | 180 | s+='</h3></label>'; |
| 142 | j=1; | 181 | j=1; |
| @@ -145,7 +184,9 @@ | @@ -145,7 +184,9 @@ | ||
| 145 | document.getElementById("nbbms").innerHTML=s; | 184 | document.getElementById("nbbms").innerHTML=s; |
| 146 | }); | 185 | }); |
| 147 | 186 | ||
| 148 | - }); | 187 | + |
| 188 | + | ||
| 189 | + | ||
| 149 | 190 | ||
| 150 | //init-autoCom | 191 | //init-autoCom |
| 151 | $(modal).on('init-autoCom', '.add-sch-form', function () { | 192 | $(modal).on('init-autoCom', '.add-sch-form', function () { |
| @@ -373,7 +414,6 @@ | @@ -373,7 +414,6 @@ | ||
| 373 | }); | 414 | }); |
| 374 | } | 415 | } |
| 375 | 416 | ||
| 376 | - //debugger | ||
| 377 | array.sort(function (a, b) { | 417 | array.sort(function (a, b) { |
| 378 | if(a.code==information.carPark) | 418 | if(a.code==information.carPark) |
| 379 | return -1; | 419 | return -1; |
| @@ -436,6 +476,8 @@ | @@ -436,6 +476,8 @@ | ||
| 436 | open_modal(folder + '/yanshi.html', { | 476 | open_modal(folder + '/yanshi.html', { |
| 437 | }, {center: true, bgclose: false, modal: true});*/ | 477 | }, {center: true, bgclose: false, modal: true});*/ |
| 438 | }, err); | 478 | }, err); |
| 479 | + //手动提交的时候清除一下,防止二次提交 | ||
| 480 | + clearInterval(sntts); | ||
| 439 | } | 481 | } |
| 440 | 482 | ||
| 441 | function enableYjtkForm() { | 483 | function enableYjtkForm() { |
| @@ -470,8 +512,6 @@ | @@ -470,8 +512,6 @@ | ||
| 470 | } | 512 | } |
| 471 | 513 | ||
| 472 | $(modal).on('mouseenter', '.uk-icon-question-circle', function() { | 514 | $(modal).on('mouseenter', '.uk-icon-question-circle', function() { |
| 473 | - | ||
| 474 | - debugger | ||
| 475 | $(this).qtip({ | 515 | $(this).qtip({ |
| 476 | show: { | 516 | show: { |
| 477 | ready: true, | 517 | ready: true, |
| @@ -495,6 +535,35 @@ | @@ -495,6 +535,35 @@ | ||
| 495 | }); | 535 | }); |
| 496 | }); | 536 | }); |
| 497 | 537 | ||
| 538 | + //定时器 | ||
| 539 | + function leftTimer(){ | ||
| 540 | + getTimerstring(timemm ? timemm -= 1000 : 0); | ||
| 541 | + if (!timemm){ | ||
| 542 | + addTwoWayZnddType.submit(); | ||
| 543 | + clearInterval(sntts); | ||
| 544 | + $("#xztimes").html("已自动执行"); | ||
| 545 | + } | ||
| 546 | + } | ||
| 547 | + //倒计时时间 | ||
| 548 | + function getTimerstring(leftTime){ | ||
| 549 | + var days = checkTime(parseInt(leftTime / 1000 / 60 / 60 / 24 , 10)); //计算剩余的天数 | ||
| 550 | + var hours = checkTime(parseInt(leftTime / 1000 / 60 / 60 % 24 , 10)); //计算剩余的小时 | ||
| 551 | + var minutes = checkTime(parseInt(leftTime / 1000 / 60 % 60, 10));//计算剩余的分钟 | ||
| 552 | + var seconds = checkTime(parseInt(leftTime / 1000 % 60, 10));//计算剩余的秒数 | ||
| 553 | + $("#xztimes").html(seconds+"秒后将自动执行"); | ||
| 554 | + } | ||
| 555 | + | ||
| 556 | + }); | ||
| 557 | + function checkTime(i){ //将0-9的数字前面加上0,例1变为01 | ||
| 558 | + | ||
| 559 | + if(i<10) | ||
| 560 | + { | ||
| 561 | + i = "0" + i; | ||
| 562 | + } | ||
| 563 | + return i; | ||
| 564 | + | ||
| 565 | + } | ||
| 566 | + | ||
| 498 | })(); | 567 | })(); |
| 499 | </script> | 568 | </script> |
| 500 | </div> | 569 | </div> |
| @@ -505,7 +574,7 @@ | @@ -505,7 +574,7 @@ | ||
| 505 | <div class="uk-grid"> | 574 | <div class="uk-grid"> |
| 506 | <div class="uk-width-4-2"> | 575 | <div class="uk-width-4-2"> |
| 507 | <div class="uk-form-row"> | 576 | <div class="uk-form-row"> |
| 508 | - <h3>大客流情况</h3> | 577 | + <h3 style="font-weight: 700;">大客流情况</h3> |
| 509 | </div> | 578 | </div> |
| 510 | </div> | 579 | </div> |
| 511 | </div> | 580 | </div> |
| @@ -540,7 +609,7 @@ | @@ -540,7 +609,7 @@ | ||
| 540 | <div class="uk-grid"> | 609 | <div class="uk-grid"> |
| 541 | <div class="uk-width-4-2"> | 610 | <div class="uk-width-4-2"> |
| 542 | <div class="uk-form-row"> | 611 | <div class="uk-form-row"> |
| 543 | - <h3>站点图片</h3> | 612 | + <h3 style="font-weight: 700;">站点图片</h3> |
| 544 | </div> | 613 | </div> |
| 545 | </div> | 614 | </div> |
| 546 | </div> | 615 | </div> |
| @@ -561,7 +630,7 @@ | @@ -561,7 +630,7 @@ | ||
| 561 | <div class="uk-grid"> | 630 | <div class="uk-grid"> |
| 562 | <div class="uk-width-4-2"> | 631 | <div class="uk-width-4-2"> |
| 563 | <div class="uk-form-row"> | 632 | <div class="uk-form-row"> |
| 564 | - <label class="uk-form-labels" ><h3>空闲车辆/人员</h3></label> | 633 | + <label class="uk-form-labels" ><h3 style="font-weight: 700;">空闲车辆/人员/班次结束时间</h3></label> |
| 565 | <div id="nbbms"> | 634 | <div id="nbbms"> |
| 566 | </div> | 635 | </div> |
| 567 | </div> | 636 | </div> |
| @@ -571,45 +640,111 @@ | @@ -571,45 +640,111 @@ | ||
| 571 | </script> | 640 | </script> |
| 572 | 641 | ||
| 573 | 642 | ||
| 574 | -<script id="buffer_config_form-temp1" type="text/html"> | ||
| 575 | - <div id="emergency_stop_panel"> | ||
| 576 | - <h3 class="btn_title_lines1"> | ||
| 577 | - <a class="uk-link-reset" >调整随到随发 </a> | ||
| 578 | - </h3> | ||
| 579 | - <div> | ||
| 580 | - <form class="uk-form" name="yjtkForm"> | ||
| 581 | - <table> | ||
| 582 | - <tr> | ||
| 583 | - <td colspan="2"> | ||
| 584 | - 是否启用 | ||
| 585 | - <select class="z-depth-input" name="enableYjtk"> | ||
| 586 | - <option value="0" >禁用</option> | ||
| 587 | - <option value="1" {{if enableYjtk}}selected{{/if}}>启用</option> | ||
| 588 | - </select> | ||
| 589 | - </td> | ||
| 590 | - </tr> | ||
| 591 | - <tr> | ||
| 592 | - <td colspan="2"> | ||
| 593 | - 时间 | ||
| 594 | - <input type="time" value="{{yjtkStart}}" name="yjtkStart" {{if !enableYjtk}}disabled{{/if}}>至 | ||
| 595 | - <input type="time" value="{{yjtkEnd}}" name="yjtkEnd" {{if !enableYjtk}}disabled{{/if}}> | ||
| 596 | - </td> | ||
| 597 | - </tr> | ||
| 598 | - <tr> | ||
| 599 | - <td> | ||
| 600 | - 上行停靠时间 | ||
| 601 | - <input type="number" value="{{upStopMinute}}" name="upStopMinute" {{if !enableYjtk}}disabled{{/if}}>分钟 | ||
| 602 | - </td> | ||
| 603 | - </tr> | ||
| 604 | - <tr> | ||
| 605 | - <td> | ||
| 606 | - 下行停靠时间 | ||
| 607 | - <input type="number" value="{{downStopMinute}}" name="downStopMinute" {{if !enableYjtk}}disabled{{/if}}>分钟 | ||
| 608 | - </td> | ||
| 609 | - </tr> | ||
| 610 | - </table> | ||
| 611 | - </form> | 643 | +<script id="sch_config_form-temp1" type="text/html"> |
| 644 | + | ||
| 645 | + <input type="hidden" name="id" value="{{id}}"/> | ||
| 646 | + <input type="hidden" name="opType" value="1"/> | ||
| 647 | + <div class="uk-grid"> | ||
| 648 | + <div class="uk-width-1-2"> | ||
| 649 | + <div class="uk-form-row"> | ||
| 650 | + <label class="uk-form-label">从</label> | ||
| 651 | + <div class="uk-form-controls"> | ||
| 652 | + <input type="text" value="{{qdzName}}" name="fcsj" disabled> | ||
| 653 | + </div> | ||
| 654 | + </div> | ||
| 655 | + </div> | ||
| 656 | + <div class="uk-width-1-2"> | ||
| 657 | + <div class="uk-form-row"> | ||
| 658 | + <label class="uk-form-label">到</label> | ||
| 659 | + <div class="uk-form-controls"> | ||
| 660 | + <input type="text" value="{{zdzName}}" name="fcsj" disabled> | ||
| 661 | + </div> | ||
| 662 | + </div> | ||
| 663 | + </div> | ||
| 612 | </div> | 664 | </div> |
| 665 | + | ||
| 666 | + | ||
| 667 | + <div class="uk-grid"> | ||
| 668 | + <div class="uk-width-1-1"> | ||
| 669 | + <div class="uk-form-row"> | ||
| 670 | + <label class="uk-form-label" for="form-s-t">备注<small class="font-danger">(不超过50个字符)</small></label> | ||
| 671 | + <div class="uk-form-controls"> | ||
| 672 | + <textarea class="zndd_text_input_color" id="form-s-t" cols="30" rows="5" name="remarks" data-fv-stringlength="true" data-fv-stringlength-max="50" style="width: 100%">{{remarks}}</textarea> | ||
| 673 | + </div> | ||
| 674 | + </div> | ||
| 675 | + </div> | ||
| 676 | + | ||
| 677 | + </div> | ||
| 678 | + | ||
| 679 | + <div class="uk-grid"> | ||
| 680 | + <div class="uk-width-1-2"> | ||
| 681 | + <div class="uk-form-row"> | ||
| 682 | + <label class="uk-form-label">车辆</label> | ||
| 683 | + <div class="uk-form-controls"> | ||
| 684 | + <div class="uk-autocomplete uk-form car-autocom"> | ||
| 685 | + <input type="text" value="{{clZbh}}" disabled> | ||
| 686 | + </div> | ||
| 687 | + </div> | ||
| 688 | + </div> | ||
| 689 | + </div> | ||
| 690 | + <div class="uk-width-1-2"> | ||
| 691 | + <div class="uk-form-row"> | ||
| 692 | + <label class="uk-form-label">路 牌</label> | ||
| 693 | + <div class="uk-form-controls"> | ||
| 694 | + <input type="text" value="{{lpName}}" disabled> | ||
| 695 | + </div> | ||
| 696 | + </div> | ||
| 697 | + </div> | ||
| 698 | + </div> | ||
| 699 | + <div class="uk-grid"> | ||
| 700 | + <div class="uk-width-1-2"> | ||
| 701 | + <div class="uk-form-row"> | ||
| 702 | + <label class="uk-form-label">计发时刻:</label> | ||
| 703 | + <div class="uk-form-controls"> | ||
| 704 | + <div class="uk-autocomplete uk-form jsy-autocom"> | ||
| 705 | + <input type="time" value="{{fcsj}}" disabled> | ||
| 706 | + </div> | ||
| 707 | + </div> | ||
| 708 | + </div> | ||
| 709 | + </div> | ||
| 710 | + <div class="uk-width-1-2"> | ||
| 711 | + <div class="uk-form-row"> | ||
| 712 | + <label class="uk-form-label">预发时刻</label> | ||
| 713 | + <div class="uk-form-controls"> | ||
| 714 | + <div class="uk-autocomplete uk-form spy-autocom"> | ||
| 715 | + <input type="time" class="zndd_text_input_color" name="dfsj" value="{{dfsj}}" required autofocus> | ||
| 716 | + </div> | ||
| 717 | + </div> | ||
| 718 | + </div> | ||
| 719 | + </div> | ||
| 720 | + </div> | ||
| 721 | + <div class="uk-grid"> | ||
| 722 | + <div class="uk-width-1-2"> | ||
| 723 | + <div class="uk-form-row"> | ||
| 724 | + <label class="uk-form-label">驾驶员:</label> | ||
| 725 | + <div class="uk-form-controls"> | ||
| 726 | + <div class="uk-autocomplete uk-form jsy-autocom"> | ||
| 727 | + <input class="form-control" value="{{jName}}" disabled></input> | ||
| 728 | + </div> | ||
| 729 | + </div> | ||
| 730 | + </div> | ||
| 731 | + </div> | ||
| 732 | + <div class="uk-width-1-2"> | ||
| 733 | + <div class="uk-form-row"> | ||
| 734 | + <label class="uk-form-label">售票员</label> | ||
| 735 | + <div class="uk-form-controls"> | ||
| 736 | + <div class="uk-autocomplete uk-form spy-autocom"> | ||
| 737 | + <input class="form-control" value="{{sName}}" disabled></input> | ||
| 738 | + </div> | ||
| 739 | + </div> | ||
| 740 | + </div> | ||
| 741 | + </div> | ||
| 742 | + </div> | ||
| 743 | + <hr style="margin-top: 35px;"> | ||
| 744 | + | ||
| 745 | + <div class="uk-modal-footer uk-text-right" style="margin-bottom: -20px;"> | ||
| 746 | + <button type="button" class="uk-button uk-modal-close">取消</button> | ||
| 747 | + <button type="submit" class="uk-button uk-button-primary"><i class="uk-icon-check"></i> 保存</button> | ||
| 613 | </div> | 748 | </div> |
| 614 | </script> | 749 | </script> |
| 615 | <script id="home-icoe-img" type="text/html"> | 750 | <script id="home-icoe-img" type="text/html"> |
src/main/resources/static/real_control_v2/zndd/type/fcjg.html
| 1 | <div class="uk-modal ct-form-modal ct_move_modal" id="schedule-addsch-modal"> | 1 | <div class="uk-modal ct-form-modal ct_move_modal" id="schedule-addsch-modal"> |
| 2 | - <div class="uk-modal-dialog" style="width: 920px;"> | 2 | + <div class="uk-modal-dialog" style="width: 1020px;"> |
| 3 | <a href="" class="uk-modal-close uk-close"></a> | 3 | <a href="" class="uk-modal-close uk-close"></a> |
| 4 | <div class="uk-modal-header"> | 4 | <div class="uk-modal-header"> |
| 5 | <h2>发车间隔</h2></div> | 5 | <h2>发车间隔</h2></div> |
| 6 | - <div class="uk-grid uk-width-3-5" style="float: left"> | 6 | + |
| 7 | + <div class="uk-grid uk-width-1-6" style="float: left"> | ||
| 8 | + <div class="uk-width-5-5 sjzlist"> | ||
| 9 | + | ||
| 10 | + </div> | ||
| 11 | + </div> | ||
| 12 | + <div class="uk-grid uk-width-3-6" style="float: left"> | ||
| 7 | <div class="uk-width-5-5"> | 13 | <div class="uk-width-5-5"> |
| 8 | <form class="uk-form uk-form-horizontal"> </form> | 14 | <form class="uk-form uk-form-horizontal"> </form> |
| 9 | <div> | 15 | <div> |
| @@ -13,13 +19,13 @@ | @@ -13,13 +19,13 @@ | ||
| 13 | </div> | 19 | </div> |
| 14 | </div> | 20 | </div> |
| 15 | 21 | ||
| 16 | - <div class="uk-grid uk-width-2-5 lj_2" style="padding-left: 100px"> | 22 | + <div class="uk-grid uk-width-2-6 lj_2" style="padding-left: 100px"> |
| 17 | <div class="uk-width-1-1" id ="tempsdsf"></div> | 23 | <div class="uk-width-1-1" id ="tempsdsf"></div> |
| 18 | 24 | ||
| 19 | </div> | 25 | </div> |
| 20 | 26 | ||
| 21 | 27 | ||
| 22 | - <div class="uk-grid uk-width-2-5 lj_1" style="padding-left: 100px"> | 28 | + <div class="uk-grid uk-width-2-6 lj_1" style="padding-left: 100px"> |
| 23 | <div class="uk-width-1-1" id ="tempcjs"></div> | 29 | <div class="uk-width-1-1" id ="tempcjs"></div> |
| 24 | 30 | ||
| 25 | </div> | 31 | </div> |
| @@ -41,7 +47,10 @@ | @@ -41,7 +47,10 @@ | ||
| 41 | var formHtml = template('djg-form-temp', sch); | 47 | var formHtml = template('djg-form-temp', sch); |
| 42 | $('form', modal).html(formHtml); | 48 | $('form', modal).html(formHtml); |
| 43 | //切换 | 49 | //切换 |
| 44 | - | 50 | + sch.rq1 =moment(new Date().getTime() - (60 *1000)).format("HH:mm"); |
| 51 | + sch.rq2 =moment(new Date()).format("HH:mm") | ||
| 52 | + var formHtmls = template('sjZ-divs-temp', sch); | ||
| 53 | + $('.sjzlist', modal).html(formHtmls); | ||
| 45 | 54 | ||
| 46 | 55 | ||
| 47 | $.get('/lineConfig/getByLineCode', {lineCode: sch.lineCode}, function (datan) { | 56 | $.get('/lineConfig/getByLineCode', {lineCode: sch.lineCode}, function (datan) { |
src/main/resources/static/real_control_v2/zndd/type/mz.html
| 1 | <div class="uk-modal ct-form-modal ct_move_modal" id="schedule-addsch-modal"> | 1 | <div class="uk-modal ct-form-modal ct_move_modal" id="schedule-addsch-modal"> |
| 2 | - <div class="uk-modal-dialog" style="width: 1400px;"> | 2 | + <div class="uk-modal-dialog" style="width: 1500px;"> |
| 3 | <a href="" class="uk-modal-close uk-close"></a> | 3 | <a href="" class="uk-modal-close uk-close"></a> |
| 4 | <div class="uk-modal-header"> | 4 | <div class="uk-modal-header"> |
| 5 | <h2>满载</h2></div> | 5 | <h2>满载</h2></div> |
| 6 | - <div class="uk-grid uk-width-2-5" style="float: left"> | 6 | + |
| 7 | + <div class="uk-grid uk-width-1-6" style="float: left"> | ||
| 8 | + <div class="uk-width-5-5 sjzlist"> | ||
| 9 | + | ||
| 10 | + </div> | ||
| 11 | + </div> | ||
| 12 | + | ||
| 13 | + <div class="uk-grid uk-width-2-6" style="float: left"> | ||
| 7 | <div class="uk-width-5-5"> | 14 | <div class="uk-width-5-5"> |
| 8 | <form class="uk-form uk-form-horizontal"> </form> | 15 | <form class="uk-form uk-form-horizontal"> </form> |
| 9 | <div> | 16 | <div> |
| @@ -12,11 +19,11 @@ | @@ -12,11 +19,11 @@ | ||
| 12 | </div> | 19 | </div> |
| 13 | </div> | 20 | </div> |
| 14 | </div> | 21 | </div> |
| 15 | - <div class="uk-grid uk-width-3-5 lj_1" > | 22 | + <div class="uk-grid uk-width-3-6 lj_1" > |
| 16 | <div class="uk-width-1-4"> | 23 | <div class="uk-width-1-4"> |
| 17 | <ul data-uk-switcher="{connect:'#tempScheduleContent'}" class="uk-nav uk-nav-side left_tabs_lg"> | 24 | <ul data-uk-switcher="{connect:'#tempScheduleContent'}" class="uk-nav uk-nav-side left_tabs_lg"> |
| 18 | <li data-handle="toAndFro"><a>1、往返</a></li> | 25 | <li data-handle="toAndFro"><a>1、往返</a></li> |
| 19 | - <li data-handle="normal"><a>2、临加班次</a></li> | 26 | + <li data-handle="normal"><a>2、新增临加班次工具</a></li> |
| 20 | <!-- <li data-handle="parkToPark"><a>3、场到场</a></li>--> | 27 | <!-- <li data-handle="parkToPark"><a>3、场到场</a></li>--> |
| 21 | </ul> | 28 | </ul> |
| 22 | </div> | 29 | </div> |
| @@ -53,6 +60,12 @@ | @@ -53,6 +60,12 @@ | ||
| 53 | sch.stopStation = route[route.length - 1]; | 60 | sch.stopStation = route[route.length - 1]; |
| 54 | var formHtml = template('djg-form-temp', sch); | 61 | var formHtml = template('djg-form-temp', sch); |
| 55 | $('form', modal).html(formHtml); | 62 | $('form', modal).html(formHtml); |
| 63 | + | ||
| 64 | + sch.rq1 =moment(new Date().getTime() - (60 *1000)).format("HH:mm"); | ||
| 65 | + sch.rq2 =moment(new Date()).format("HH:mm") | ||
| 66 | + var formHtmls = template('sjZ-divs-temp', sch); | ||
| 67 | + $('.sjzlist', modal).html(formHtmls); | ||
| 68 | + | ||
| 56 | //切换 | 69 | //切换 |
| 57 | $("#destroySelect").on('change',function(){ | 70 | $("#destroySelect").on('change',function(){ |
| 58 | let fn = $('#destroySelect').val(); | 71 | let fn = $('#destroySelect').val(); |
| @@ -384,7 +397,6 @@ | @@ -384,7 +397,6 @@ | ||
| 384 | })(); | 397 | })(); |
| 385 | </script> | 398 | </script> |
| 386 | </div> | 399 | </div> |
| 387 | - | ||
| 388 | <script id="djg-form-temp" type="text/html"> | 400 | <script id="djg-form-temp" type="text/html"> |
| 389 | <input type="hidden" name="id" value=""/> | 401 | <input type="hidden" name="id" value=""/> |
| 390 | 402 |
src/main/resources/static/real_control_v2/zndd/type/sftz_1.html
| @@ -3,7 +3,19 @@ | @@ -3,7 +3,19 @@ | ||
| 3 | <a href="" class="uk-modal-close uk-close"></a> | 3 | <a href="" class="uk-modal-close uk-close"></a> |
| 4 | <div class="uk-modal-header"> | 4 | <div class="uk-modal-header"> |
| 5 | <h2>实发未发<i class="uk-icon-question-circle uk-icon-hover"></i></h2></div> | 5 | <h2>实发未发<i class="uk-icon-question-circle uk-icon-hover"></i></h2></div> |
| 6 | - <form class="uk-form uk-form-horizontal"> </form> | 6 | + <div class="uk-grid uk-width-1-5" style="float: left"> |
| 7 | + <div class="uk-width-5-5 sjzlist"> | ||
| 8 | + | ||
| 9 | + </div> | ||
| 10 | + </div> | ||
| 11 | + | ||
| 12 | + <div class="uk-grid uk-width-4-5" > | ||
| 13 | + <div class="uk-width-5-5"> | ||
| 14 | + <form class="uk-form uk-form-horizontal"> </form> | ||
| 15 | + </div> | ||
| 16 | + | ||
| 17 | + </div> | ||
| 18 | + | ||
| 7 | </div> | 19 | </div> |
| 8 | 20 | ||
| 9 | <script> | 21 | <script> |
| @@ -27,12 +39,13 @@ | @@ -27,12 +39,13 @@ | ||
| 27 | sch.stopStation = route[route.length - 1]; | 39 | sch.stopStation = route[route.length - 1]; |
| 28 | var formHtml = template('sftz-form-temp',{sch: sch, reportTypes:reportTypes}); | 40 | var formHtml = template('sftz-form-temp',{sch: sch, reportTypes:reportTypes}); |
| 29 | $('form', modal).html(formHtml); | 41 | $('form', modal).html(formHtml); |
| 30 | - | ||
| 31 | - //frequent_phrases.init(modal); | ||
| 32 | - | ||
| 33 | - | ||
| 34 | - | ||
| 35 | - | 42 | + |
| 43 | + sch.rq1 =moment(new Date().getTime() - (60 *1000)).format("HH:mm"); | ||
| 44 | + sch.rq2 =moment(new Date()).format("HH:mm") | ||
| 45 | + var formHtmls = template('sjZ-divs-temp', sch); | ||
| 46 | + $('.sjzlist', modal).html(formHtmls); | ||
| 47 | + | ||
| 48 | + | ||
| 36 | f.formValidation(gb_form_validation_opts); | 49 | f.formValidation(gb_form_validation_opts); |
| 37 | f.on('success.form.fv', function(e) { | 50 | f.on('success.form.fv', function(e) { |
| 38 | debugger | 51 | debugger |
| @@ -153,7 +166,7 @@ | @@ -153,7 +166,7 @@ | ||
| 153 | <div class="uk-grid"> | 166 | <div class="uk-grid"> |
| 154 | <div class="uk-width-4-2"> | 167 | <div class="uk-width-4-2"> |
| 155 | <div class="uk-form-row"> | 168 | <div class="uk-form-row"> |
| 156 | - <h3>实发未发信息</h3> | 169 | + <h3>实发未发信息(实发调整工具)</h3> |
| 157 | </div> | 170 | </div> |
| 158 | </div> | 171 | </div> |
| 159 | </div> | 172 | </div> |
| @@ -238,7 +251,7 @@ | @@ -238,7 +251,7 @@ | ||
| 238 | <div class="uk-form-row"> | 251 | <div class="uk-form-row"> |
| 239 | <label class="uk-form-label">实发时间</label> | 252 | <label class="uk-form-label">实发时间</label> |
| 240 | <div class="uk-form-controls"> | 253 | <div class="uk-form-controls"> |
| 241 | - <input type="time" value="{{sch.sch.fcsj}}" name="fcsjActual"> | 254 | + <input type="time" value="{{sch.sch.fcsjActual != null ? sch.sch.fcsjActual : sch.sch.dfsj}}" name="fcsjActual"> |
| 242 | </div> | 255 | </div> |
| 243 | </div> | 256 | </div> |
| 244 | </div> | 257 | </div> |
src/main/resources/static/real_control_v2/zndd/type/wd.html
| 1 | <div class="uk-modal ct-form-modal ct_move_modal" id="wd-addsch-modal"> | 1 | <div class="uk-modal ct-form-modal ct_move_modal" id="wd-addsch-modal"> |
| 2 | - <div class="uk-modal-dialog" style="width: 850px;"> | 2 | + <div class="uk-modal-dialog" style="width: 1050px;"> |
| 3 | <a href="" class="uk-modal-close uk-close"></a> | 3 | <a href="" class="uk-modal-close uk-close"></a> |
| 4 | <div class="uk-modal-header"> | 4 | <div class="uk-modal-header"> |
| 5 | <h2>误点<i class="uk-icon-question-circle uk-icon-hover"></i></h2></div> | 5 | <h2>误点<i class="uk-icon-question-circle uk-icon-hover"></i></h2></div> |
| 6 | 6 | ||
| 7 | - <div class="uk-grid uk-width-3-5 lj_1" style="float: left"> | 7 | + |
| 8 | + <div class="uk-grid uk-width-1-6" style="float: left"> | ||
| 9 | + <div class="uk-width-5-5 sjzlist"> | ||
| 10 | + | ||
| 11 | + </div> | ||
| 12 | + </div> | ||
| 13 | + | ||
| 14 | + <div class="uk-grid uk-width-3-6 lj_1" style="float: left"> | ||
| 8 | <form class="uk-form uk-form-horizontal"> </form> | 15 | <form class="uk-form uk-form-horizontal"> </form> |
| 9 | </div> | 16 | </div> |
| 10 | 17 | ||
| 11 | 18 | ||
| 12 | 19 | ||
| 13 | - <div class="uk-grid uk-width-2-5 lj_2" style="padding-left: 100px"> | 20 | + <div class="uk-grid uk-width-2-6 lj_2" style="padding-left: 100px"> |
| 14 | <div class="uk-width-1-1" id ="tempsdsf"></div> | 21 | <div class="uk-width-1-1" id ="tempsdsf"></div> |
| 15 | 22 | ||
| 16 | </div> | 23 | </div> |
| @@ -36,6 +43,10 @@ | @@ -36,6 +43,10 @@ | ||
| 36 | sch.stopStation = route[route.length - 1]; | 43 | sch.stopStation = route[route.length - 1]; |
| 37 | var formHtml = template('wd-form-temp', sch); | 44 | var formHtml = template('wd-form-temp', sch); |
| 38 | $('form', modal).html(formHtml); | 45 | $('form', modal).html(formHtml); |
| 46 | + sch.rq1 =moment(new Date().getTime() - (60 *1000)).format("HH:mm"); | ||
| 47 | + sch.rq2 =moment(new Date()).format("HH:mm") | ||
| 48 | + var formHtmls = template('sjZ-divs-temp', sch); | ||
| 49 | + $('.sjzlist', modal).html(formHtmls); | ||
| 39 | //车辆信息 | 50 | //车辆信息 |
| 40 | carsArray = gb_data_basic.carsArray(); | 51 | carsArray = gb_data_basic.carsArray(); |
| 41 | initAutoCom(f); | 52 | initAutoCom(f); |
| @@ -60,7 +71,7 @@ | @@ -60,7 +71,7 @@ | ||
| 60 | e.preventDefault(); | 71 | e.preventDefault(); |
| 61 | var data = $(this).serializeJSON(); | 72 | var data = $(this).serializeJSON(); |
| 62 | let fn = $('#destroySelect').val(); | 73 | let fn = $('#destroySelect').val(); |
| 63 | - debugger | 74 | + |
| 64 | if (fn == "1"){ | 75 | if (fn == "1"){ |
| 65 | //调整人员车辆 | 76 | //调整人员车辆 |
| 66 | let datas = { | 77 | let datas = { |
| @@ -337,7 +348,7 @@ | @@ -337,7 +348,7 @@ | ||
| 337 | </div> | 348 | </div> |
| 338 | <div class="uk-width-1-2"> | 349 | <div class="uk-width-1-2"> |
| 339 | <div class="uk-form-row"> | 350 | <div class="uk-form-row"> |
| 340 | - <label class="uk-form-label">误点时间(分钟)</label> | 351 | + <label class="uk-form-label">误点调整工具</label> |
| 341 | <div class="uk-form-controls"> | 352 | <div class="uk-form-controls"> |
| 342 | <input value="6" name="wdsj" id="wdsj"> | 353 | <input value="6" name="wdsj" id="wdsj"> |
| 343 | </div> | 354 | </div> |
| @@ -355,7 +366,7 @@ | @@ -355,7 +366,7 @@ | ||
| 355 | </div> | 366 | </div> |
| 356 | <div class="uk-width-1-2"> | 367 | <div class="uk-width-1-2"> |
| 357 | <div class="uk-form-row"> | 368 | <div class="uk-form-row"> |
| 358 | - <label class="uk-form-label">待发时间</label> | 369 | + <label class="uk-form-label">待发调整工具</label> |
| 359 | <div class="uk-form-controls"> | 370 | <div class="uk-form-controls"> |
| 360 | <input value="{{sch.fcsj}} + {{sch.lateMinute}}" name="wd" id="dfsj" disabled> | 371 | <input value="{{sch.fcsj}} + {{sch.lateMinute}}" name="wd" id="dfsj" disabled> |
| 361 | </div> | 372 | </div> |
src/main/resources/static/real_control_v2/zndd/type/ycsf.html
| 1 | <div class="uk-modal ct-form-modal ct_move_modal" id="ycsf-addsch-modal"> | 1 | <div class="uk-modal ct-form-modal ct_move_modal" id="ycsf-addsch-modal"> |
| 2 | + | ||
| 2 | <div class="uk-modal-dialog" style="width: 850px;"> | 3 | <div class="uk-modal-dialog" style="width: 850px;"> |
| 3 | <a href="" class="uk-modal-close uk-close"></a> | 4 | <a href="" class="uk-modal-close uk-close"></a> |
| 4 | <div class="uk-modal-header"> | 5 | <div class="uk-modal-header"> |
| 5 | <h2>异常实发<i class="uk-icon-question-circle uk-icon-hover"></i></h2></div> | 6 | <h2>异常实发<i class="uk-icon-question-circle uk-icon-hover"></i></h2></div> |
| 6 | - <form class="uk-form uk-form-horizontal"> </form> | 7 | + |
| 8 | + <div class="uk-grid uk-width-1-5" style="float: left"> | ||
| 9 | + <div class="uk-width-5-5 sjzlist"> | ||
| 10 | + | ||
| 11 | + </div> | ||
| 12 | + </div> | ||
| 13 | + <div class="uk-grid uk-width-4-5" > | ||
| 14 | + | ||
| 15 | + <div class="uk-width-5-5"> | ||
| 16 | + <form class="uk-form uk-form-horizontal"> </form> | ||
| 17 | + </div> | ||
| 18 | + | ||
| 19 | + </div> | ||
| 20 | + | ||
| 7 | </div> | 21 | </div> |
| 8 | 22 | ||
| 9 | <script> | 23 | <script> |
| @@ -26,13 +40,18 @@ | @@ -26,13 +40,18 @@ | ||
| 26 | sch.stopStation = route[route.length - 1]; | 40 | sch.stopStation = route[route.length - 1]; |
| 27 | var formHtml = template('ycsf-form-temp', sch); | 41 | var formHtml = template('ycsf-form-temp', sch); |
| 28 | $('form', modal).html(formHtml); | 42 | $('form', modal).html(formHtml); |
| 43 | + | ||
| 44 | + | ||
| 45 | + | ||
| 46 | + sch.rq1 =moment(new Date().getTime() - (60 *1000)).format("HH:mm"); | ||
| 47 | + sch.rq2 =moment(new Date()).format("HH:mm") | ||
| 48 | + var formHtmls = template('sjZ-divs-temp', sch); | ||
| 49 | + $('.sjzlist', modal).html(formHtmls); | ||
| 29 | 50 | ||
| 30 | f.formValidation(gb_form_validation_opts); | 51 | f.formValidation(gb_form_validation_opts); |
| 31 | f.on('success.form.fv', function(e) { | 52 | f.on('success.form.fv', function(e) { |
| 32 | - debugger | ||
| 33 | e.preventDefault(); | 53 | e.preventDefault(); |
| 34 | var data = $(this).serializeJSON(); | 54 | var data = $(this).serializeJSON(); |
| 35 | - debugger | ||
| 36 | 55 | ||
| 37 | gb_common.$post('/realSchedule/revokeRealOutgo_zndd', { | 56 | gb_common.$post('/realSchedule/revokeRealOutgo_zndd', { |
| 38 | id: sch.sch.id, | 57 | id: sch.sch.id, |
| @@ -85,7 +104,7 @@ | @@ -85,7 +104,7 @@ | ||
| 85 | <div class="uk-grid"> | 104 | <div class="uk-grid"> |
| 86 | <div class="uk-width-4-2"> | 105 | <div class="uk-width-4-2"> |
| 87 | <div class="uk-form-row"> | 106 | <div class="uk-form-row"> |
| 88 | - <h3>异常实发信息</h3> | 107 | + <h3>异常实发信息(实发撤销工具)</h3> |
| 89 | </div> | 108 | </div> |
| 90 | </div> | 109 | </div> |
| 91 | </div> | 110 | </div> |
src/main/resources/static/real_control_v2/zndd/yanshi/static/css/sjz.css
| @@ -50,7 +50,7 @@ | @@ -50,7 +50,7 @@ | ||
| 50 | .history-date ul li { | 50 | .history-date ul li { |
| 51 | background:url(../image/yes.png) no-repeat 180px 0; | 51 | background:url(../image/yes.png) no-repeat 180px 0; |
| 52 | background-size: 15px 15px; | 52 | background-size: 15px 15px; |
| 53 | - padding-bottom:50px; | 53 | + padding-bottom:10px; |
| 54 | zoom:1; | 54 | zoom:1; |
| 55 | } | 55 | } |
| 56 | .history-date ul li.last { | 56 | .history-date ul li.last { |
| @@ -65,8 +65,8 @@ | @@ -65,8 +65,8 @@ | ||
| 65 | } | 65 | } |
| 66 | .history-date ul li h3 { | 66 | .history-date ul li h3 { |
| 67 | float:left; | 67 | float:left; |
| 68 | - width:20%; | ||
| 69 | - text-align:right; | 68 | + /*width:20%; |
| 69 | + text-align:right;*/ | ||
| 70 | padding-right:19px; | 70 | padding-right:19px; |
| 71 | color:#c3c3c3; | 71 | color:#c3c3c3; |
| 72 | font:normal 18px/16px Arial; | 72 | font:normal 18px/16px Arial; |
| @@ -77,14 +77,14 @@ | @@ -77,14 +77,14 @@ | ||
| 77 | font-size:12px; | 77 | font-size:12px; |
| 78 | } | 78 | } |
| 79 | .history-date ul li dl { | 79 | .history-date ul li dl { |
| 80 | - width: 70%; | 80 | + /*width: 70%;*/ |
| 81 | float:left; | 81 | float:left; |
| 82 | - padding-left:41px; | 82 | +/* padding-left:41px;*/ |
| 83 | margin-top:-5px; | 83 | margin-top:-5px; |
| 84 | font-family:微软雅黑; | 84 | font-family:微软雅黑; |
| 85 | } | 85 | } |
| 86 | .history-date ul li dl dt { | 86 | .history-date ul li dl dt { |
| 87 | - font:20px/22px 微软雅黑; | 87 | + /*font:20px/22px 微软雅黑;*/ |
| 88 | color:#737373; | 88 | color:#737373; |
| 89 | } | 89 | } |
| 90 | .history-date ul li dl dt span { | 90 | .history-date ul li dl dt span { |
src/main/resources/static/real_control_v2/zndd/zndd_status.html
0 → 100644
| 1 | +<div class="uk-modal ct-form-modal" id="tts-config-modal"> | ||
| 2 | + <div class="uk-modal-dialog" style="width: 530px;"> | ||
| 3 | + <a href="" class="uk-modal-close uk-close"></a> | ||
| 4 | + <div class="uk-modal-header"> | ||
| 5 | + <h2>智能调度开关</h2></div> | ||
| 6 | + | ||
| 7 | + <p style="border-bottom: 1px solid #efefef;color: grey;padding-bottom: 9px;"> | ||
| 8 | + <small> | ||
| 9 | + <i class="uk-icon-question-circle"> </i> | ||
| 10 | + 设置项将会调整所有线路配置,请谨慎调整</small> | ||
| 11 | + </p> | ||
| 12 | + | ||
| 13 | + <div class="zndd_su ct-fixed-table"> | ||
| 14 | + | ||
| 15 | + <table class="ct-fixed-table uk-table uk-table-hover"> | ||
| 16 | + <thead> | ||
| 17 | + <tr> | ||
| 18 | + <th style="width: 8%;">序号</th> | ||
| 19 | + <th style="width: 10%;">名称</th> | ||
| 20 | + <th style="width: 10%;">状态</th> | ||
| 21 | + <th style="width: 8%;">开关</th> | ||
| 22 | + </tr> | ||
| 23 | + </thead> | ||
| 24 | + <tbody> | ||
| 25 | + </tbody> | ||
| 26 | + </table> | ||
| 27 | + </div> | ||
| 28 | + | ||
| 29 | + </div> | ||
| 30 | + | ||
| 31 | + <script> | ||
| 32 | + (function() { | ||
| 33 | + | ||
| 34 | + list(); | ||
| 35 | + })(); | ||
| 36 | + | ||
| 37 | + function list(){ | ||
| 38 | + $(".zndd_su tbody").html(""); | ||
| 39 | + $.get('/znnd_status/all', null, function(data){ | ||
| 40 | + var tbodyHtml = template('zndd_list_all',{list:data}); | ||
| 41 | + $(".zndd_su tbody").html(tbodyHtml); | ||
| 42 | + }) | ||
| 43 | + } | ||
| 44 | + | ||
| 45 | + | ||
| 46 | + function opencloseStatus(el,status){ | ||
| 47 | + debugger | ||
| 48 | + var id = parseInt($(el).val()); | ||
| 49 | + var json ={ | ||
| 50 | + id : id, | ||
| 51 | + openStatus : status | ||
| 52 | + } | ||
| 53 | + $.post('/znnd_status/update', json, function(data){ | ||
| 54 | + if (data.status == "SUCCESS"){ | ||
| 55 | + notify_succ('调整成功!'); | ||
| 56 | + list(); | ||
| 57 | + } | ||
| 58 | + | ||
| 59 | + }) | ||
| 60 | + | ||
| 61 | + } | ||
| 62 | + | ||
| 63 | + </script> | ||
| 64 | + | ||
| 65 | + <script type="text/html" id="zndd_list_all"> | ||
| 66 | + {{each list as obj i}} | ||
| 67 | + <tr> | ||
| 68 | + <td>{{i +1 }}</td> | ||
| 69 | + <td>{{obj.name}}</td> | ||
| 70 | + <td> | ||
| 71 | + {{if obj.openStatus == 0}} | ||
| 72 | + <div class="uk-badge uk-badge-danger"> 开</div> | ||
| 73 | + {{else}} | ||
| 74 | + <div class="uk-badge uk-badge-danger"> 关</div> | ||
| 75 | + {{/if}} | ||
| 76 | + </td> | ||
| 77 | + | ||
| 78 | + <td> | ||
| 79 | + {{if obj.openStatus == 0}} | ||
| 80 | + <button class="btn btn-sm btn-outline filter-submit margin-bottom" value="{{obj.id}}" onclick="opencloseStatus(this,1)"> | ||
| 81 | + <i class="fa fa-search" ></i> 关闭</button> | ||
| 82 | + {{else}} | ||
| 83 | + <button class="btn btn-sm btn-outline filter-submit margin-bottom" value="{{obj.id}}" onclick="opencloseStatus(this,0)"> | ||
| 84 | + <i class="fa fa-search"></i> 开启</button> | ||
| 85 | + {{/if}} | ||
| 86 | + </td> | ||
| 87 | + </tr> | ||
| 88 | + {{/each}} | ||
| 89 | + | ||
| 90 | + </script> | ||
| 91 | +</div> | ||
| 92 | + |