Commit b14500e4199b634d2aafc12661c17318207efef5
Merge branch 'pudong_jdk8' of 192.168.168.201:panzhaov5/bsth_control into pudong_jdk8
Showing
11 changed files
with
1240 additions
and
1095 deletions
src/main/java/com/bsth/controller/oil/YlbController.java
| ... | ... | @@ -234,8 +234,24 @@ public class YlbController extends BaseController<Ylb, Integer>{ |
| 234 | 234 | |
| 235 | 235 | @RequestMapping(value = "/checkDate",method = RequestMethod.GET) |
| 236 | 236 | public String checkDate(@RequestParam Map<String, Object> map){ |
| 237 | - String list=ylbService.checkDate(map); | |
| 238 | - return list; | |
| 237 | + String result=ylbService.checkDate(map); | |
| 238 | + return result; | |
| 239 | + } | |
| 240 | + | |
| 241 | + @RequestMapping(value = "/getModifyRights",method = RequestMethod.GET) | |
| 242 | + public Map<String, Object> getModifyRights(@RequestParam Map<String, Object> map){ | |
| 243 | + String result=ylbService.getModifyRights(); | |
| 244 | + Map<String, Object> resMap = new HashMap<String, Object>(); | |
| 245 | + resMap.put("text", result); | |
| 246 | + return resMap; | |
| 247 | + } | |
| 248 | + | |
| 249 | + @RequestMapping(value = "/modifyRightsChange",method = RequestMethod.GET) | |
| 250 | + public Map<String, Object> modifyRightsChange(@RequestParam Map<String, Object> map){ | |
| 251 | + String result=ylbService.modifyRightsChange(); | |
| 252 | + Map<String, Object> resMap = new HashMap<String, Object>(); | |
| 253 | + resMap.put("text", result); | |
| 254 | + return resMap; | |
| 239 | 255 | } |
| 240 | 256 | |
| 241 | 257 | @RequestMapping(value = "/sumYlb",method = RequestMethod.GET) | ... | ... |
src/main/java/com/bsth/service/forms/impl/RevenueLoader.java
| ... | ... | @@ -40,13 +40,13 @@ public class RevenueLoader { |
| 40 | 40 | */ |
| 41 | 41 | public static List<Map<String, Object>> load(String date, String gsBm){ |
| 42 | 42 | try { |
| 43 | - url = ConfigUtil.get("http.ticketing.interface") + "?txnType=getLineRevenue&busiDate="+date+"&companyCode="+gsBm; | |
| 43 | + url = ConfigUtil.get("http.ticketing.interface") + "?revenueFlag=1&txnType=getLineRevenue&busiDate="+date+"&companyCode="+gsBm; | |
| 44 | 44 | list = new ArrayList<>(); |
| 45 | 45 | httpClient = HttpClients.createDefault(); |
| 46 | 46 | get = new HttpGet(url); |
| 47 | 47 | requestConfig = RequestConfig.custom() |
| 48 | - .setConnectTimeout(2500).setConnectionRequestTimeout(2000) | |
| 49 | - .setSocketTimeout(2500).build(); | |
| 48 | + .setConnectTimeout(10000).setConnectionRequestTimeout(10000) | |
| 49 | + .setSocketTimeout(60000).build(); | |
| 50 | 50 | get.setConfig(requestConfig); |
| 51 | 51 | if(list.size() > 0) |
| 52 | 52 | list.clear(); | ... | ... |
src/main/java/com/bsth/service/impl/TrafficManageServiceImpl.java
| ... | ... | @@ -19,6 +19,7 @@ import com.bsth.repository.traffic.SKBUploadLoggerRepository; |
| 19 | 19 | import com.bsth.security.util.SecurityUtils; |
| 20 | 20 | import com.bsth.service.TrafficManageService; |
| 21 | 21 | import com.bsth.service.traffic.YgcBasicDataService; |
| 22 | +import com.bsth.util.IpUtils; | |
| 22 | 23 | import com.bsth.util.TimeUtils; |
| 23 | 24 | import com.bsth.util.db.DBUtils_MS; |
| 24 | 25 | import com.bsth.webService.trafficManage.org.tempuri.Results; |
| ... | ... | @@ -528,7 +529,7 @@ public class TrafficManageServiceImpl implements TrafficManageService{ |
| 528 | 529 | try { |
| 529 | 530 | //发送邮件 |
| 530 | 531 | EmailBean mail = new EmailBean(); |
| 531 | - mail.setSubject(InetAddress.getLocalHost().getHostAddress()+":路单日志数据"+date); | |
| 532 | + mail.setSubject(IpUtils.getLocalIpAddress() +":路单日志数据"+date); | |
| 532 | 533 | mail.setContent("总数:" + (listGroup == null ? 0 : listGroup.size()) + "<br/>成功数:" + scount + "<br/>跳过数:" + ccount + "<br/>耗时:" + (System.currentTimeMillis() - start)); |
| 533 | 534 | sendEmailController.sendMail(emailSendToAddress, mail); |
| 534 | 535 | logger.info("setLD-sendMail:邮件发送成功!"); | ... | ... |
src/main/java/com/bsth/service/oil/YlbService.java
| ... | ... | @@ -20,6 +20,9 @@ public interface YlbService extends BaseService<Ylb, Integer>{ |
| 20 | 20 | Map<String, Object> sumYlb(Map<String, Object> map); |
| 21 | 21 | String checkJsy(Map<String, Object> map); |
| 22 | 22 | String checkDate(Map<String, Object> map); |
| 23 | + | |
| 24 | + String getModifyRights(); | |
| 25 | + String modifyRightsChange(); | |
| 23 | 26 | |
| 24 | 27 | List<Map<String, Object>> oilListMonth(Map<String, Object> map); |
| 25 | 28 | List<Ylb> listYlb(Map<String, Object> map); | ... | ... |
src/main/java/com/bsth/service/oil/impl/YlbServiceImpl.java
| ... | ... | @@ -92,7 +92,7 @@ public class YlbServiceImpl extends BaseServiceImpl<Ylb,Integer> implements YlbS |
| 92 | 92 | |
| 93 | 93 | Logger logger = LoggerFactory.getLogger(this.getClass()); |
| 94 | 94 | |
| 95 | - | |
| 95 | + private static boolean modify_rights_close = true; | |
| 96 | 96 | |
| 97 | 97 | /** |
| 98 | 98 | * 获取进存油信息 |
| ... | ... | @@ -1602,7 +1602,7 @@ public class YlbServiceImpl extends BaseServiceImpl<Ylb,Integer> implements YlbS |
| 1602 | 1602 | String rq=map.get("rq").toString(); |
| 1603 | 1603 | String gsbm=map.get("ssgsdm_like").toString(); |
| 1604 | 1604 | String type="1"; |
| 1605 | - if(gsbm.equals("26")){ | |
| 1605 | + if(gsbm.equals("26") && modify_rights_close){ | |
| 1606 | 1606 | Date date=new Date(); |
| 1607 | 1607 | try { |
| 1608 | 1608 | long day2=date.getTime(); |
| ... | ... | @@ -1619,6 +1619,21 @@ public class YlbServiceImpl extends BaseServiceImpl<Ylb,Integer> implements YlbS |
| 1619 | 1619 | return type; |
| 1620 | 1620 | } |
| 1621 | 1621 | |
| 1622 | + @Override | |
| 1623 | + public String getModifyRights(){ | |
| 1624 | + return modify_rights_close?"关闭":"打开"; | |
| 1625 | + } | |
| 1626 | + | |
| 1627 | + @Override | |
| 1628 | + public String modifyRightsChange(){ | |
| 1629 | + if(modify_rights_close){ | |
| 1630 | + modify_rights_close = false; | |
| 1631 | + } else { | |
| 1632 | + modify_rights_close = true; | |
| 1633 | + } | |
| 1634 | + return modify_rights_close?"权限关闭":"权限打开"; | |
| 1635 | + } | |
| 1636 | + | |
| 1622 | 1637 | |
| 1623 | 1638 | |
| 1624 | 1639 | @Override | ... | ... |
src/main/java/com/bsth/util/IpUtils.java
| 1 | -package com.bsth.util; | |
| 2 | - | |
| 3 | -import javax.servlet.http.HttpServletRequest; | |
| 4 | - | |
| 5 | -public class IpUtils { | |
| 6 | - | |
| 7 | - public static String getIpAddr(HttpServletRequest request) { | |
| 8 | - if (request == null) { | |
| 9 | - return "unknown"; | |
| 10 | - } | |
| 11 | - String ip = request.getHeader("x-forwarded-for"); | |
| 12 | - if (ip == null || ip.length() == 0 || "unknown".equalsIgnoreCase(ip)) { | |
| 13 | - ip = request.getHeader("Proxy-Client-IP"); | |
| 14 | - } | |
| 15 | - if (ip == null || ip.length() == 0 || "unknown".equalsIgnoreCase(ip)) { | |
| 16 | - ip = request.getHeader("X-Forwarded-For"); | |
| 17 | - } | |
| 18 | - if (ip == null || ip.length() == 0 || "unknown".equalsIgnoreCase(ip)) { | |
| 19 | - ip = request.getHeader("WL-Proxy-Client-IP"); | |
| 20 | - } | |
| 21 | - if (ip == null || ip.length() == 0 || "unknown".equalsIgnoreCase(ip)) { | |
| 22 | - ip = request.getHeader("X-Real-IP"); | |
| 23 | - } | |
| 24 | - if (ip == null || ip.length() == 0 || "unknown".equalsIgnoreCase(ip)) { | |
| 25 | - ip = request.getRemoteAddr(); | |
| 26 | - } | |
| 27 | - return ip; | |
| 28 | - } | |
| 29 | -} | |
| 1 | +package com.bsth.util; | |
| 2 | + | |
| 3 | +import javax.servlet.http.HttpServletRequest; | |
| 4 | +import java.net.Inet4Address; | |
| 5 | +import java.net.InetAddress; | |
| 6 | +import java.net.NetworkInterface; | |
| 7 | +import java.util.Enumeration; | |
| 8 | + | |
| 9 | +public class IpUtils { | |
| 10 | + | |
| 11 | + public static String getIpAddr(HttpServletRequest request) { | |
| 12 | + if (request == null) { | |
| 13 | + return "unknown"; | |
| 14 | + } | |
| 15 | + String ip = request.getHeader("x-forwarded-for"); | |
| 16 | + if (ip == null || ip.length() == 0 || "unknown".equalsIgnoreCase(ip)) { | |
| 17 | + ip = request.getHeader("Proxy-Client-IP"); | |
| 18 | + } | |
| 19 | + if (ip == null || ip.length() == 0 || "unknown".equalsIgnoreCase(ip)) { | |
| 20 | + ip = request.getHeader("X-Forwarded-For"); | |
| 21 | + } | |
| 22 | + if (ip == null || ip.length() == 0 || "unknown".equalsIgnoreCase(ip)) { | |
| 23 | + ip = request.getHeader("WL-Proxy-Client-IP"); | |
| 24 | + } | |
| 25 | + if (ip == null || ip.length() == 0 || "unknown".equalsIgnoreCase(ip)) { | |
| 26 | + ip = request.getHeader("X-Real-IP"); | |
| 27 | + } | |
| 28 | + if (ip == null || ip.length() == 0 || "unknown".equalsIgnoreCase(ip)) { | |
| 29 | + ip = request.getRemoteAddr(); | |
| 30 | + } | |
| 31 | + return ip; | |
| 32 | + } | |
| 33 | + | |
| 34 | + /** | |
| 35 | + * 获取本地IP地址 | |
| 36 | + * @return | |
| 37 | + */ | |
| 38 | + public static String getLocalIpAddress() { | |
| 39 | + try { | |
| 40 | + Enumeration<NetworkInterface> allNetInterfaces = NetworkInterface.getNetworkInterfaces(); | |
| 41 | + InetAddress ip = null; | |
| 42 | + while (allNetInterfaces.hasMoreElements()) { | |
| 43 | + NetworkInterface netInterface = (NetworkInterface) allNetInterfaces.nextElement(); | |
| 44 | + if (netInterface.isLoopback() || netInterface.isVirtual() || !netInterface.isUp() || "docker0".equals(netInterface.getDisplayName())) { | |
| 45 | + continue; | |
| 46 | + } else { | |
| 47 | + Enumeration<InetAddress> addresses = netInterface.getInetAddresses(); | |
| 48 | + while (addresses.hasMoreElements()) { | |
| 49 | + ip = addresses.nextElement(); | |
| 50 | + if (ip != null && ip instanceof Inet4Address) { | |
| 51 | + return ip.getHostAddress(); | |
| 52 | + } | |
| 53 | + } | |
| 54 | + } | |
| 55 | + } | |
| 56 | + } catch (Exception e) { | |
| 57 | + System.err.println("IP地址获取失败" + e.toString()); | |
| 58 | + } | |
| 59 | + | |
| 60 | + return ""; | |
| 61 | + } | |
| 62 | +} | ... | ... |
src/main/resources/static/index.html
| 1 | -<!DOCTYPE html> | |
| 2 | -<html lang="zh"> | |
| 3 | -<head> | |
| 4 | - <meta name="renderer" content="webkit" /> | |
| 5 | - <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" /> | |
| 6 | - <meta charset="UTF-8"> | |
| 7 | - <title>调度系统</title> | |
| 8 | - | |
| 9 | - <meta http-equiv="Pragma" content="no-cache"> | |
| 10 | - <meta http-equiv="Cache-control" content="no-cache"> | |
| 11 | - <meta http-equiv="Cache" content="no-cache"> | |
| 12 | - | |
| 13 | - <!-- Font Awesome 图标字体 --> | |
| 14 | - <link | |
| 15 | - href="/metronic_v4.5.4/plugins/font-awesome/css/font-awesome.min.css" | |
| 16 | - rel="stylesheet" type="text/css" /> | |
| 17 | - <!-- Bootstrap style --> | |
| 18 | - <link href="/metronic_v4.5.4/plugins/bootstrap/css/bootstrap.min.css" | |
| 19 | - rel="stylesheet" type="text/css" /> | |
| 20 | - <!-- jsTree 数插件 --> | |
| 21 | - <link | |
| 22 | - href="/metronic_v4.5.4/plugins/jstree/dist/themes/default/style.min.css" | |
| 23 | - rel="stylesheet" type="text/css" /> | |
| 24 | - <!-- MULTI-select 多选下拉框美化 --> | |
| 25 | - <link | |
| 26 | - href="/metronic_v4.5.4/plugins/jquery-multi-select/css/multi-select.css" | |
| 27 | - rel="stylesheet" type="text/css" /> | |
| 28 | - | |
| 29 | - <!-- editable --> | |
| 30 | - <link | |
| 31 | - href="/metronic_v4.5.4/plugins/bootstrap-editable/bootstrap-editable/css/bootstrap-editable.css" | |
| 32 | - rel="stylesheet" type="text/css" /> | |
| 33 | - <!-- METRONIC style --> | |
| 34 | - <link href="/metronic_v4.5.4/layout4/css/themes/light.min.css" | |
| 35 | - rel="stylesheet" type="text/css" id="style_color" /> | |
| 36 | - <link href="/metronic_v4.5.4/css/components.css" rel="stylesheet" | |
| 37 | - type="text/css" /> | |
| 38 | - <link href="/metronic_v4.5.4/css/plugins.css" rel="stylesheet" | |
| 39 | - type="text/css" /> | |
| 40 | - <link href="/metronic_v4.5.4/layout4/css/layout.min.css" | |
| 41 | - rel="stylesheet" type="text/css" /> | |
| 42 | - <link href="/metronic_v4.5.4/layout4/css/custom.min.css" | |
| 43 | - rel="stylesheet" type="text/css" /> | |
| 44 | - <!-- select2 下拉框插件 --> | |
| 45 | - <link href="/metronic_v4.5.4/plugins/select2/css/select2.min.css" | |
| 46 | - rel="stylesheet" type="text/css" /> | |
| 47 | - <link | |
| 48 | - href="/metronic_v4.5.4/plugins/select2/css/select2-bootstrap.min.css" | |
| 49 | - rel="stylesheet" type="text/css" /> | |
| 50 | - <!-- layer 弹层 插件 --> | |
| 51 | - <link href="/assets/plugins/layer-v2.4/layer/skin/layer.css" | |
| 52 | - rel="stylesheet" type="text/css" /> | |
| 53 | - <!-- fileinput 上传 插件 --> | |
| 54 | - <link href="/assets/plugins/fileinput/css/fileinput.min.css" | |
| 55 | - rel="stylesheet" type="text/css" /> | |
| 56 | - <!-- iCheck 单选框和复选框 --> | |
| 57 | - <link href="/metronic_v4.5.4/plugins/icheck/skins/all.css" | |
| 58 | - rel="stylesheet" type="text/css" /> | |
| 59 | - <!-- 日期控件 --> | |
| 60 | - <link | |
| 61 | - href="/metronic_v4.5.4/plugins/bootstrap-datetimepicker-2/css/bootstrap-datetimepicker.min.css" | |
| 62 | - rel="stylesheet" type="text/css" /> | |
| 63 | - <!-- table 表格控件 --> | |
| 64 | - <!--<link rel="stylesheet"--> | |
| 65 | - <!--href="http://api.map.baidu.com/library/DrawingManager/1.4/src/DrawingManager_min.css"--> | |
| 66 | - <!--type="text/css" />--> | |
| 67 | - <link href="/metronic_v4.5.4/plugins/bootstrap-tagsinput/bootstrap-tagsinput.css" rel="stylesheet" type="text/css"/> | |
| 68 | - <!-- handsontable样式 --> | |
| 69 | - <link rel="stylesheet" | |
| 70 | - href="/assets/bower_components/handsontable/dist/handsontable.full.css" /> | |
| 71 | - <!-- sweetalert样式 --> | |
| 72 | - <link rel="stylesheet" | |
| 73 | - href="/assets/bower_components/sweetalert/dist/sweetalert.css" /> | |
| 74 | - <!-- schedule计划调度AngularJS模块主css --> | |
| 75 | - <link rel="stylesheet" href="/pages/scheduleApp/module/common/main.css" | |
| 76 | - type="text/css" /> | |
| 77 | - <link rel="stylesheet" href="/real_control_v2/assets/plugins/perfect-scrollbar/perfect-scrollbar.css" merge="plugins"/> | |
| 78 | - | |
| 79 | - <!-- CSS动画 --> | |
| 80 | - <link | |
| 81 | - href="/metronic_v4.5.4/plugins/tipso/css/animate.css" | |
| 82 | - rel="stylesheet" type="text/css" /> | |
| 83 | - | |
| 84 | - <!-- 提示工具样式 --> | |
| 85 | - <link | |
| 86 | - href="/metronic_v4.5.4/plugins/tipso/css/tipso.css" | |
| 87 | - rel="stylesheet" type="text/css" /> | |
| 88 | - | |
| 89 | - <style type="text/css"> | |
| 90 | - .searchForm { | |
| 91 | - | |
| 92 | - } | |
| 93 | - | |
| 94 | - .searchForm .form-group .control-label { | |
| 95 | - padding-right: 0px; | |
| 96 | - text-align: right; | |
| 97 | - margin-top: 7px; | |
| 98 | - } | |
| 99 | - | |
| 100 | - .searchForm .form-group>div { | |
| 101 | - padding-left: 10px; | |
| 102 | - padding-right: 0px; | |
| 103 | - } | |
| 104 | - | |
| 105 | - .searchForm .row>div { | |
| 106 | - padding-left: 0px; | |
| 107 | - padding-right: 0px; | |
| 108 | - padding: 5px 0 5px 0; | |
| 109 | - width: 270px; | |
| 110 | - display: inline-block; | |
| 111 | - } | |
| 112 | - | |
| 113 | - .searchForm .form-actions { | |
| 114 | - | |
| 115 | - } | |
| 116 | - | |
| 117 | - tr.row-active td { | |
| 118 | - border-bottom: 1px solid blue !important; | |
| 119 | - color: blue; | |
| 120 | - } | |
| 121 | - | |
| 122 | - .ms-container .ms-selectable li.ms-elem-selectable,.ms-container .ms-selection li.ms-elem-selection | |
| 123 | - { | |
| 124 | - font-size: 14px; | |
| 125 | - } | |
| 126 | - | |
| 127 | - .ms-container .ms-selectable li.ms-elem-selectable,.ms-container .ms-selection li.ms-elem-selection | |
| 128 | - { | |
| 129 | - padding: 6px 26px; | |
| 130 | - } | |
| 131 | - | |
| 132 | - .ms-container .ms-list { | |
| 133 | - height: 306px; | |
| 134 | - } | |
| 135 | - | |
| 136 | - .ms-container .ms-selectable,.ms-container .ms-selection { | |
| 137 | - width: 47%; | |
| 138 | - } | |
| 139 | - | |
| 140 | - .ms-container { | |
| 141 | - width: 470px; | |
| 142 | - margin: auto; | |
| 143 | - } | |
| 144 | - | |
| 145 | - .multi-custom-header-left { | |
| 146 | - text-align: center; | |
| 147 | - padding: 7px; | |
| 148 | - color: #3B3F51; | |
| 149 | - } | |
| 150 | - | |
| 151 | - .multi-custom-header-right { | |
| 152 | - text-align: center; | |
| 153 | - padding: 7px; | |
| 154 | - font-weight: bold; | |
| 155 | - color: #36C6D3; | |
| 156 | - } | |
| 157 | - | |
| 158 | - .mt-element-list .list-simple.mt-list-container ul>.mt-list-item>.list-item-content | |
| 159 | - { | |
| 160 | - padding: 0 55px 0 0px; | |
| 161 | - } | |
| 162 | - | |
| 163 | - .mt-element-list .list-simple.mt-list-container ul>.mt-list-item { | |
| 164 | - padding: 3.3px 0; | |
| 165 | - } | |
| 166 | - | |
| 167 | - #route-container { | |
| 168 | - display: none; | |
| 169 | - } | |
| 170 | - | |
| 171 | - .page-content.active { | |
| 172 | - display: block !important; | |
| 173 | - } | |
| 174 | - | |
| 175 | - .page-header.navbar .page-logo .logo-default { | |
| 176 | - margin: 0; | |
| 177 | - } | |
| 178 | - | |
| 179 | - .page-header.navbar .top-menu .navbar-nav>li.dropdown.open .dropdown-toggle | |
| 180 | - { | |
| 181 | - background-color: #284a99; | |
| 182 | - } | |
| 183 | - | |
| 184 | - .page-header.navbar .page-logo { | |
| 185 | - padding-right: 10px; | |
| 186 | - } | |
| 187 | - | |
| 188 | - .page-logo .logo-default.logo-default-text { | |
| 189 | - font-weight: 600; | |
| 190 | - color: white !important; | |
| 191 | - margin-top: 19px !important; | |
| 192 | - font-size: 24px; | |
| 193 | - text-decoration: none; | |
| 194 | - } | |
| 195 | - | |
| 196 | - .page-logo .logo-default.logo-default-text:HOVER { | |
| 197 | - color: #dedede !important; | |
| 198 | - } | |
| 199 | - | |
| 200 | - body,.page-content-wrapper,#pjax-container{ | |
| 201 | - height: 100%; | |
| 202 | - } | |
| 203 | - html{ | |
| 204 | - height: 90%; | |
| 205 | - } | |
| 206 | - .page-container{ | |
| 207 | - height: 100%; | |
| 208 | - } | |
| 209 | - </style> | |
| 210 | - | |
| 211 | - <!-- ocLazyLoading载入文件的位置 --> | |
| 212 | - <link id="ng_load_plugins_before" /> | |
| 213 | - | |
| 214 | -</head> | |
| 215 | -<body | |
| 216 | - class="page-container-bg-solid page-header-fixed page-sidebar-closed-hide-logo page-sidebar-fixed"> | |
| 217 | -<div class="page-header navbar navbar-fixed-top" | |
| 218 | - style="background: linear-gradient(to bottom, #124e78, #125688);"> | |
| 219 | - <div class="page-header-inner "> | |
| 220 | - <!-- LOGO --> | |
| 221 | - <div class="page-logo"> | |
| 222 | - <a href="index.html" class="logo-default logo-default-text"> | |
| 223 | - 浦东公交调度系统 </a> | |
| 224 | - <div class="menu-toggler sidebar-toggler"></div> | |
| 225 | - </div> | |
| 226 | - <!-- END LOGO --> | |
| 227 | - <a href="javascript:;" class="menu-toggler responsive-toggler" | |
| 228 | - data-toggle="collapse" data-target=".navbar-collapse"> </a> | |
| 229 | - <div class="page-top"> | |
| 230 | - <div class="top-menu"> | |
| 231 | - <ul class="nav navbar-nav pull-right"> | |
| 232 | - <!-- 信息通知区 --> | |
| 233 | - <li | |
| 234 | - class="dropdown dropdown-extended dropdown-notification dropdown-dark" | |
| 235 | - id="header_notification_bar"><a href="javascript:;" | |
| 236 | - class="dropdown-toggle" data-toggle="dropdown" | |
| 237 | - data-hover="dropdown" data-close-others="true"> <i | |
| 238 | - class="fa fa-bell"></i> <span class="badge badge-success"> | |
| 239 | - 0 </span> | |
| 240 | - </a> | |
| 241 | - <ul class="dropdown-menu" style="max-width: 345px; width: 345px;"> | |
| 242 | - <li class="external"> | |
| 243 | - <h3> | |
| 244 | - 今日 <span class="bold">0 条</span> 通知 | |
| 245 | - </h3> <a href="javascript:;">查看全部</a> | |
| 246 | - </li> | |
| 247 | - <li> | |
| 248 | - <ul class="dropdown-menu-list scroller" style="height: 250px;" | |
| 249 | - data-handle-color="#637283"> | |
| 250 | - </ul> | |
| 251 | - </li> | |
| 252 | - </ul></li> | |
| 253 | - <li class="dropdown dropdown-user dropdown-dark"><a | |
| 254 | - href="javascript:;" class="dropdown-toggle" | |
| 255 | - data-toggle="dropdown" data-hover="dropdown" | |
| 256 | - data-close-others="true"> <span id="indexTopUName" | |
| 257 | - class="username username-hide-on-mobile" | |
| 258 | - style="vertical-align: middle;"> <i class="fa fa-user"></i></span> | |
| 259 | - </a> | |
| 260 | - <ul class="dropdown-menu dropdown-menu-default"> | |
| 261 | - <li><a href="javascript:;"> <i class="fa fa-user"></i> | |
| 262 | - 我的信息 | |
| 263 | - </a></li> | |
| 264 | - <li><a href="javascript:;" id="changePWD"> <i | |
| 265 | - class="fa fa-unlock-alt"></i> 修改密码 | |
| 266 | - </a></li> | |
| 267 | - <li class="divider"></li> | |
| 268 | - <li><a href="javascript:;"> <i class="fa fa-lock"></i> | |
| 269 | - 锁屏 | |
| 270 | - </a></li> | |
| 271 | - <li><a href="/logout"> <i class="fa fa-key"></i> 注销登陆 | |
| 272 | - </a></li> | |
| 273 | - </ul></li> | |
| 274 | - </ul> | |
| 275 | - </div> | |
| 276 | - </div> | |
| 277 | - </div> | |
| 278 | -</div> | |
| 279 | -<div class="page-container"> | |
| 280 | - <div class="page-sidebar-wrapper"> | |
| 281 | - <div class="page-sidebar navbar-collapse collapse"> | |
| 282 | - <ul class="page-sidebar-menu page-sidebar-menu-fixed" | |
| 283 | - data-keep-expanded="false" data-auto-scroll="true" | |
| 284 | - data-slide-speed="200" id="leftMenuSidebar"> | |
| 285 | - </ul> | |
| 286 | - </div> | |
| 287 | - </div> | |
| 288 | - <div class="page-content-wrapper"> | |
| 289 | - <div id="pjax-container" class="page-content"></div> | |
| 290 | - | |
| 291 | - <div id="route-container"> | |
| 292 | - <div ng-app="ScheduleApp"> | |
| 293 | - <div ng-controller="ScheduleAppController"> | |
| 294 | - | |
| 295 | - <!-- loading widget --> | |
| 296 | - <div id="loadingWidget" class="flyover mask" loading-widget> | |
| 297 | - <div class="alert alert-info"> | |
| 298 | - <strong>载入中......</strong> | |
| 299 | - </div> | |
| 300 | - </div> | |
| 301 | - | |
| 302 | - <div ui-view class="uv"></div> | |
| 303 | - </div> | |
| 304 | - </div> | |
| 305 | - </div> | |
| 306 | - </div> | |
| 307 | -</div> | |
| 308 | - | |
| 309 | -<script id="menu_list_temp" type="text/html"> | |
| 310 | - {{each list as group i}} | |
| 311 | - <li class="heading"> | |
| 312 | - <h3 class="uppercase">{{group.name}}</h3> | |
| 313 | - </li> | |
| 314 | - {{each group.children as dir j}} | |
| 315 | - <li class="nav-item"> | |
| 316 | - <a href="javascript:;" class="nav-link nav-toggle "> | |
| 317 | - <i class="{{dir.icon}}"></i> | |
| 318 | - <span class="title">{{dir.name}}</span> | |
| 319 | - <span class="arrow"></span> | |
| 320 | - </a> | |
| 321 | - <ul class="sub-menu"> | |
| 322 | - {{each dir.children as module s}} | |
| 323 | - <li class="nav-item "> | |
| 324 | - {{if module.container=="pjax-container"}} | |
| 325 | - <a href="/pages/{{module.path}}" class="nav-link " data-pjax> | |
| 326 | - <span class="title">{{module.name}}</span> | |
| 327 | - </a> | |
| 328 | - {{else}} | |
| 329 | - <a href="{{module.path}}" class="nav-link " data-angularjs> | |
| 330 | - <span class="title">{{module.name}}</span> | |
| 331 | - </a> | |
| 332 | - {{/if}} | |
| 333 | - </li> | |
| 334 | - {{/each}} | |
| 335 | - </ul> | |
| 336 | - </li> | |
| 337 | - {{/each}} | |
| 338 | - {{/each}} | |
| 339 | - | |
| 340 | -</script> | |
| 341 | -<script> | |
| 342 | - delete window.require; | |
| 343 | - delete window.exports; | |
| 344 | - delete window.module; | |
| 345 | -</script> | |
| 346 | -<!-- jQuery --> | |
| 347 | -<script src="/metronic_v4.5.4/plugins/jquery.min.js" data-exclude=1></script> | |
| 348 | -<!-- bootstrap --> | |
| 349 | -<script src="/metronic_v4.5.4/plugins/bootstrap/js/bootstrap.min.js" | |
| 350 | - data-exclude=1></script> | |
| 351 | -<script src="/pages/forms/statement/js/jquery.autocompleter.js"></script> | |
| 352 | -<script src="/pages/forms/statement/js/jquery.PrintArea.js"></script> | |
| 353 | -<!-- MTRONIC JS --> | |
| 354 | -<script src="/metronic_v4.5.4/scripts/app.min.js" data-exclude=1></script> | |
| 355 | -<script src="/metronic_v4.5.4/layout4/scripts/layout.min.js" | |
| 356 | - data-exclude=1></script> | |
| 357 | -<!-- 虚拟滚动条 --> | |
| 358 | -<script | |
| 359 | - src="/metronic_v4.5.4/plugins/jquery-slimscroll/jquery.slimscroll.min.js"></script> | |
| 360 | -<!-- jsTree 树插件 --> | |
| 361 | -<script src="/metronic_v4.5.4/plugins/jstree/dist/jstree.min.js"></script> | |
| 362 | -<!-- bootstrap-hover-dropDown --> | |
| 363 | -<script | |
| 364 | - src="/metronic_v4.5.4/plugins/bootstrap-hover-dropdown/bootstrap-hover-dropdown.min.js"></script> | |
| 365 | -<!-- jquery.validate 表单验证 --> | |
| 366 | -<script | |
| 367 | - src="/metronic_v4.5.4/plugins/jquery-validation/js/jquery.validate.min.js"></script> | |
| 368 | -<script | |
| 369 | - src="/metronic_v4.5.4/plugins/jquery-validation/js/localization/messages_zh.js"></script> | |
| 370 | -<!-- 向导式插件 --> | |
| 371 | -<script | |
| 372 | - src="/metronic_v4.5.4//plugins/bootstrap-wizard/jquery.bootstrap.wizard.min.js"></script> | |
| 373 | -<!-- iCheck 单选框和复选框 --> | |
| 374 | -<script src="/metronic_v4.5.4/plugins/icheck/icheck.min.js"></script> | |
| 375 | -<!-- select2 下拉框 --> | |
| 376 | -<script src="/metronic_v4.5.4/plugins/select2/js/select2.full.min.js"></script> | |
| 377 | -<!-- MULTI SELECT 多选下拉框 --> | |
| 378 | -<script | |
| 379 | - src="/metronic_v4.5.4/plugins/jquery-multi-select/js/jquery.multi-select.js"></script> | |
| 380 | -<!-- editable.js --> | |
| 381 | -<script | |
| 382 | - src="/metronic_v4.5.4/plugins/bootstrap-editable/bootstrap-editable/js/bootstrap-editable.min.js"></script> | |
| 383 | -<!-- PJAX --> | |
| 384 | -<script src="/assets/plugins/jquery.pjax.js"></script> | |
| 385 | -<!-- layer 弹层 --> | |
| 386 | -<script src="/assets/plugins/layer-v2.4/layer/layer.js" data-exclude=1></script> | |
| 387 | -<!-- fileinput 上传 --> | |
| 388 | -<script src="/assets/plugins/fileinput/canvas-to-blob.min.js"></script> | |
| 389 | -<script src="/assets/plugins/fileinput/purify.min.js"></script> | |
| 390 | -<script src="/assets/plugins/fileinput/sortable.min.js"></script> | |
| 391 | -<script src="/assets/plugins/fileinput/fileinput.min.js"></script> | |
| 392 | -<script src="/assets/plugins/fileinput/fileinput_locale_zh.js"></script> | |
| 393 | -<!-- jquery.purl URL解析 --> | |
| 394 | -<script src="/assets/plugins/purl.js"></script> | |
| 395 | -<!-- jquery.serializejson JSON序列化插件 --> | |
| 396 | -<script src="/assets/plugins/jquery.serializejson.js"></script> | |
| 397 | -<!-- art-template 模版引擎 --> | |
| 398 | -<script src="/assets/plugins/template.js"></script> | |
| 399 | -<!-- jquery.pageinator 分页 --> | |
| 400 | -<script src="/assets/plugins/jqPaginator.min.js"></script> | |
| 401 | -<!-- moment.js 日期处理类库 --> | |
| 402 | -<script src="/assets/plugins/moment-with-locales.js"></script> | |
| 403 | - | |
| 404 | -<script src="/assets/plugins/pinyin.js"></script> | |
| 405 | -<!-- 日期控件 --> | |
| 406 | -<script | |
| 407 | - src="/metronic_v4.5.4/plugins/bootstrap-datetimepicker-2/js/bootstrap-datetimepicker.min.js"></script> | |
| 408 | -<!-- 表格控件 --> | |
| 409 | -<script src="/metronic_v4.5.4/plugins/bootstrap-tagsinput/bootstrap-tagsinput.min.js"></script> | |
| 410 | -<!-- 统计图控件 --> | |
| 411 | -<!--<script src="/assets/global/getEchart.js"></script> | |
| 412 | -<script src="/assets/global/echarts.js"></script> --> | |
| 413 | -<script src="/assets/js/common.js"></script> | |
| 414 | -<script src="/assets/js/dictionary.js"></script> | |
| 415 | -<!-- tipso JS --> | |
| 416 | -<script src="/metronic_v4.5.4/plugins/tipso/js/tipso.js"></script> | |
| 417 | -<script data-exclude=1> | |
| 418 | - //初始打开的片段地址 | |
| 419 | - var initFragment = "^_^initFragment^_^"; | |
| 420 | - //静态文件目录 | |
| 421 | - var dir = '/pages/'; | |
| 422 | - //片段容器 | |
| 423 | - var pjaxContainer = '#pjax-container' | |
| 424 | - , angJsContainer = '#route-container'; | |
| 425 | - | |
| 426 | - $(document).ajaxError(function (event, jqxhr, settings, thrownError) { | |
| 427 | - if(jqxhr.status == 403){ | |
| 428 | - layer.closeAll(); | |
| 429 | - layer.alert(jqxhr.message?jqxhr.message:'访问被拒绝', {icon: 2, title: '操作失败'}); | |
| 430 | - } | |
| 431 | - }); | |
| 432 | - | |
| 433 | - $(function () { | |
| 434 | - $.get('/user/currentUser', function (user) { | |
| 435 | - $('#indexTopUName').text(user.userName); | |
| 436 | - }); | |
| 437 | - | |
| 438 | - //带 data-pjax 的链接由pjax加载 | |
| 439 | - $(document).pjax('a[data-pjax]', pjaxContainer); | |
| 440 | - | |
| 441 | - //pjax左菜单点击事件 | |
| 442 | - $(document).on('click', '#leftMenuSidebar a[data-pjax]', function () { | |
| 443 | - setTitle(this); | |
| 444 | - | |
| 445 | - $('#leftMenuSidebar li.nav-item.active').removeClass('active'); | |
| 446 | - $(this).parent().addClass('active'); | |
| 447 | - showPjax(); | |
| 448 | - }); | |
| 449 | - | |
| 450 | - //angularjs左菜单点击事件 | |
| 451 | - $(document).on('click', '#leftMenuSidebar a[data-angularjs]', function () { | |
| 452 | - setTitle(this); | |
| 453 | - | |
| 454 | - $('#leftMenuSidebar li.nav-item.active').removeClass('active'); | |
| 455 | - $(this).parent().addClass('active'); | |
| 456 | - showAngJs(); | |
| 457 | - }); | |
| 458 | - | |
| 459 | - //加载左菜单栏 | |
| 460 | - $get('/module/findByCurrentUser', null, | |
| 461 | - function (ms) { | |
| 462 | - var treeArray = createTreeData(ms); | |
| 463 | - treeArray.sort(function (a, b) { | |
| 464 | - return a.createDate - b.createDate; | |
| 465 | - }); | |
| 466 | - var menuHtml = template('menu_list_temp', {list: treeArray}); | |
| 467 | - $('#leftMenuSidebar').html(menuHtml); | |
| 468 | - | |
| 469 | - //----------- 检查URL ---------------- | |
| 470 | - var h = location.hash; | |
| 471 | - if (initFragment && initFragment != '') { | |
| 472 | - showPjax(); | |
| 473 | - //普通片段 | |
| 474 | - loadPage(initFragment); | |
| 475 | - //选中菜单 | |
| 476 | - $.each($('#leftMenuSidebar a'), function (i, item) { | |
| 477 | - if (urlPattern($(item).attr('href'), initFragment)) { | |
| 478 | - activeLeftMenu(item); | |
| 479 | - } | |
| 480 | - }); | |
| 481 | - } else if (h) { | |
| 482 | - //angularjs片段 | |
| 483 | - showAngJs(); | |
| 484 | - //选中菜单 | |
| 485 | - $.each($('#leftMenuSidebar a'), function (i, item) { | |
| 486 | - if ($(item).attr('href') == h) { | |
| 487 | - activeLeftMenu(item); | |
| 488 | - } | |
| 489 | - }); | |
| 490 | - } | |
| 491 | - else { | |
| 492 | - //加载主页 | |
| 493 | - loadPage('/pages/home.html'); | |
| 494 | - } | |
| 495 | - }); | |
| 496 | - | |
| 497 | - //修改密码 | |
| 498 | - $('#changePWD').on('click', function () { | |
| 499 | - $.get('/pages/permission/user/changePWD.html', function (content) { | |
| 500 | - layer.open({ | |
| 501 | - type: 1, | |
| 502 | - area: ['600px', '360px'], | |
| 503 | - content: content, | |
| 504 | - title: '修改密码', | |
| 505 | - shift: 5, | |
| 506 | - scrollbar: false, | |
| 507 | - success: function () { | |
| 508 | - } | |
| 509 | - }); | |
| 510 | - }); | |
| 511 | - }); | |
| 512 | - }); | |
| 513 | - | |
| 514 | - //modal关闭时销毁dom | |
| 515 | - $(document).on('hidden.bs.modal', '.modal', function () { | |
| 516 | - $(this).remove(); | |
| 517 | - }); | |
| 518 | - | |
| 519 | - //pjax加载完成事件 | |
| 520 | - $(document).on('pjax:success', function () { | |
| 521 | - var dicts = $(pjaxContainer).find('.nt-dictionary'); | |
| 522 | - dictionaryUtils.transformDom(dicts); | |
| 523 | - }); | |
| 524 | - | |
| 525 | - function loadPage(url) { | |
| 526 | - $.pjax({url: url, container: pjaxContainer}) | |
| 527 | - } | |
| 528 | - | |
| 529 | - function urlPattern(a, b) { | |
| 530 | - var r; | |
| 531 | - try { | |
| 532 | - r = a.substring(0, a.lastIndexOf('/')) == b.substring(0, b.lastIndexOf('/')); | |
| 533 | - } catch (e) { | |
| 534 | - r = false; | |
| 535 | - } | |
| 536 | - return r; | |
| 537 | - } | |
| 538 | - | |
| 539 | - function showPjax() { | |
| 540 | - $(angJsContainer).removeClass('page-content active').hide(); | |
| 541 | - $(pjaxContainer).addClass('page-content active'); | |
| 542 | - } | |
| 543 | - | |
| 544 | - function showAngJs() { | |
| 545 | - $(pjaxContainer).html('').removeClass('page-content active').hide(); | |
| 546 | - $(angJsContainer).addClass('page-content active'); | |
| 547 | - } | |
| 548 | - | |
| 549 | - function activeLeftMenu(item) { | |
| 550 | - $(item).parent('.nav-item').addClass('active').parent('.sub-menu').show().parent().addClass('open'); | |
| 551 | - setTitle(item); | |
| 552 | - } | |
| 553 | - | |
| 554 | - function setTitle(menuItem){ | |
| 555 | - document.title = $('span.title', menuItem).text(); | |
| 556 | - } | |
| 557 | - | |
| 558 | -</script> | |
| 559 | -<!-- d3 --> | |
| 560 | -<script src="/assets/js/d3.min.js" data-exclude=1></script> | |
| 561 | -<!-- webSocket JS --> | |
| 562 | -<script src="/assets/js/sockjs.min.js"></script> | |
| 563 | - | |
| 564 | -<!-- TODO:angularJS相关库 --> | |
| 565 | - | |
| 566 | -<!-- angularJS相关库 --> | |
| 567 | -<!-- 这个是基于angularjs 1.4.10修改的版本,主要是修改了history控制部分,用于兼容route和pjax的同时操作history的冲突 --> | |
| 568 | -<script src="/assets/js/angular.js" data-autocephaly=1></script> | |
| 569 | -<script src="/assets/bower_components/angular-i18n/angular-locale_zh-cn.js" data-autocephaly=1></script> | |
| 570 | -<script | |
| 571 | - src="/assets/bower_components/angular-resource/angular-resource.min.js" | |
| 572 | - data-exclude=1></script> | |
| 573 | -<script | |
| 574 | - src="/assets/bower_components/angular-sanitize/angular-sanitize.min.js" | |
| 575 | - data-exclude=1></script> | |
| 576 | -<script | |
| 577 | - src="/assets/bower_components/angular-animate/angular-animate.min.js" | |
| 578 | - data-exclude=1></script> | |
| 579 | -<script | |
| 580 | - src="/assets/bower_components/angular-touch/angular-touch.min.js" | |
| 581 | - data-exclude=1></script> | |
| 582 | -<script | |
| 583 | - src="/assets/bower_components/angular-ui-router/release/angular-ui-router.min.js" | |
| 584 | - data-exclude=1></script> | |
| 585 | -<script | |
| 586 | - src="/assets/bower_components/oclazyload/dist/ocLazyLoad.min.js" | |
| 587 | - data-exclude=1></script> | |
| 588 | -<script | |
| 589 | - src="/assets/bower_components/angular-bootstrap/ui-bootstrap-tpls.min.js" | |
| 590 | - data-exclude=1></script> | |
| 591 | -<!-- handsontable相关js --> | |
| 592 | -<script | |
| 593 | - src="/assets/bower_components/handsontable/dist/handsontable.full.js"></script> | |
| 594 | -<script | |
| 595 | - src="/assets/bower_components/ngHandsontable/dist/ngHandsontable.js"></script> | |
| 596 | -<!-- sweetalert相关js --> | |
| 597 | -<script src="/assets/bower_components/sweetalert/dist/sweetalert.min.js"></script> | |
| 598 | -<script src="/assets/bower_components/ng-sweet-alert/ng-sweet-alert.js"></script> | |
| 599 | - | |
| 600 | -<!-- schedule计划调度AngularJS模块主JS --> | |
| 601 | -<script src="/pages/scheduleApp/module/common/main.js" data-exclude=1></script> | |
| 602 | -<script | |
| 603 | - src="/pages/scheduleApp/module/common/prj-common-globalservice.js" | |
| 604 | - data-exclude=1></script> | |
| 605 | -<script src="/pages/scheduleApp/module/common/prj-common-filter.js" | |
| 606 | - data-exclude=1></script> | |
| 607 | -<script src="/pages/scheduleApp/module/common/prj-common-directive.js" | |
| 608 | - data-exclude=1></script> | |
| 609 | -<script | |
| 610 | - src="/pages/scheduleApp/module/common/prj-common-ui-route-state.js" | |
| 611 | - data-exclude=1></script> | |
| 612 | - | |
| 613 | -<!-- 地图相关 --> | |
| 614 | -<!-- 百度 --> | |
| 615 | -<script | |
| 616 | - src="http://api.map.baidu.com/api?v=2.0&ak=IGGrr4UjwIYzatoCRFKEL8sT" | |
| 617 | - data-exclude=1></script> | |
| 618 | -<script | |
| 619 | - src="http://api.map.baidu.com/library/TrafficControl/1.4/src/TrafficControl_min.js" | |
| 620 | - data-exclude=1></script> | |
| 621 | -<script type="text/javascript" | |
| 622 | - src="http://api.map.baidu.com/library/DrawingManager/1.4/src/DrawingManager_min.js" | |
| 623 | - data-exclude=1></script> | |
| 624 | -<script type="text/javascript" | |
| 625 | - src="http://api.map.baidu.com/library/RichMarker/1.2/src/RichMarker_min.js " | |
| 626 | - data-exclude=1></script> | |
| 627 | -<script src="/assets/js/baidu/TextIconOverlay.js" data-exclude=1></script> | |
| 628 | -<script src="/assets/js/baidu//MarkerClusterer.js" data-exclude=1></script> | |
| 629 | -<!-- 高德 --> | |
| 630 | -<script | |
| 631 | - src="http://webapi.amap.com/maps?v=1.3&key=16cb1c5043847e09ef9edafdd77befda" | |
| 632 | - data-exclude=1></script> | |
| 633 | -<!-- echarts4 --> | |
| 634 | -<script src="/metronic_v4.5.4/plugins/echarts4/echarts.min.js"></script> | |
| 635 | -<script src="/real_control_v2/assets/plugins/perfect-scrollbar/perfect-scrollbar.jquery.js" merge="plugins"></script> | |
| 636 | -<!-- RSA加密 --> | |
| 637 | -<script src="/assets/plugins/jsencrypt.min.js"></script> | |
| 638 | - | |
| 639 | -</body> | |
| 1 | +<!DOCTYPE html> | |
| 2 | +<html lang="zh"> | |
| 3 | +<head> | |
| 4 | + <meta name="renderer" content="webkit" /> | |
| 5 | + <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" /> | |
| 6 | + <meta charset="UTF-8"> | |
| 7 | + <title>调度系统</title> | |
| 8 | + | |
| 9 | + <meta http-equiv="Pragma" content="no-cache"> | |
| 10 | + <meta http-equiv="Cache-control" content="no-cache"> | |
| 11 | + <meta http-equiv="Cache" content="no-cache"> | |
| 12 | + | |
| 13 | + <!-- Font Awesome 图标字体 --> | |
| 14 | + <link | |
| 15 | + href="/metronic_v4.5.4/plugins/font-awesome/css/font-awesome.min.css" | |
| 16 | + rel="stylesheet" type="text/css" /> | |
| 17 | + <!-- Bootstrap style --> | |
| 18 | + <link href="/metronic_v4.5.4/plugins/bootstrap/css/bootstrap.min.css" | |
| 19 | + rel="stylesheet" type="text/css" /> | |
| 20 | + <!-- jsTree 数插件 --> | |
| 21 | + <link | |
| 22 | + href="/metronic_v4.5.4/plugins/jstree/dist/themes/default/style.min.css" | |
| 23 | + rel="stylesheet" type="text/css" /> | |
| 24 | + <!-- MULTI-select 多选下拉框美化 --> | |
| 25 | + <link | |
| 26 | + href="/metronic_v4.5.4/plugins/jquery-multi-select/css/multi-select.css" | |
| 27 | + rel="stylesheet" type="text/css" /> | |
| 28 | + | |
| 29 | + <!-- editable --> | |
| 30 | + <link | |
| 31 | + href="/metronic_v4.5.4/plugins/bootstrap-editable/bootstrap-editable/css/bootstrap-editable.css" | |
| 32 | + rel="stylesheet" type="text/css" /> | |
| 33 | + <!-- METRONIC style --> | |
| 34 | + <link href="/metronic_v4.5.4/layout4/css/themes/light.min.css" | |
| 35 | + rel="stylesheet" type="text/css" id="style_color" /> | |
| 36 | + <link href="/metronic_v4.5.4/css/components.css" rel="stylesheet" | |
| 37 | + type="text/css" /> | |
| 38 | + <link href="/metronic_v4.5.4/css/plugins.css" rel="stylesheet" | |
| 39 | + type="text/css" /> | |
| 40 | + <link href="/metronic_v4.5.4/layout4/css/layout.min.css" | |
| 41 | + rel="stylesheet" type="text/css" /> | |
| 42 | + <link href="/metronic_v4.5.4/layout4/css/custom.min.css" | |
| 43 | + rel="stylesheet" type="text/css" /> | |
| 44 | + <!-- select2 下拉框插件 --> | |
| 45 | + <link href="/metronic_v4.5.4/plugins/select2/css/select2.min.css" | |
| 46 | + rel="stylesheet" type="text/css" /> | |
| 47 | + <link | |
| 48 | + href="/metronic_v4.5.4/plugins/select2/css/select2-bootstrap.min.css" | |
| 49 | + rel="stylesheet" type="text/css" /> | |
| 50 | + <!-- layer 弹层 插件 --> | |
| 51 | + <link href="/assets/plugins/layer-v2.4/layer/skin/layer.css" | |
| 52 | + rel="stylesheet" type="text/css" /> | |
| 53 | + <!-- fileinput 上传 插件 --> | |
| 54 | + <link href="/assets/plugins/fileinput/css/fileinput.min.css" | |
| 55 | + rel="stylesheet" type="text/css" /> | |
| 56 | + <!-- iCheck 单选框和复选框 --> | |
| 57 | + <link href="/metronic_v4.5.4/plugins/icheck/skins/all.css" | |
| 58 | + rel="stylesheet" type="text/css" /> | |
| 59 | + <!-- 日期控件 --> | |
| 60 | + <link | |
| 61 | + href="/metronic_v4.5.4/plugins/bootstrap-datetimepicker-2/css/bootstrap-datetimepicker.min.css" | |
| 62 | + rel="stylesheet" type="text/css" /> | |
| 63 | + <!-- table 表格控件 --> | |
| 64 | + <!--<link rel="stylesheet"--> | |
| 65 | + <!--href="//api.map.baidu.com/library/DrawingManager/1.4/src/DrawingManager_min.css"--> | |
| 66 | + <!--type="text/css" />--> | |
| 67 | + <link href="/metronic_v4.5.4/plugins/bootstrap-tagsinput/bootstrap-tagsinput.css" rel="stylesheet" type="text/css"/> | |
| 68 | + <!-- handsontable样式 --> | |
| 69 | + <link rel="stylesheet" | |
| 70 | + href="/assets/bower_components/handsontable/dist/handsontable.full.css" /> | |
| 71 | + <!-- sweetalert样式 --> | |
| 72 | + <link rel="stylesheet" | |
| 73 | + href="/assets/bower_components/sweetalert/dist/sweetalert.css" /> | |
| 74 | + <!-- schedule计划调度AngularJS模块主css --> | |
| 75 | + <link rel="stylesheet" href="/pages/scheduleApp/module/common/main.css" | |
| 76 | + type="text/css" /> | |
| 77 | + <link rel="stylesheet" href="/real_control_v2/assets/plugins/perfect-scrollbar/perfect-scrollbar.css" merge="plugins"/> | |
| 78 | + | |
| 79 | + <!-- CSS动画 --> | |
| 80 | + <link | |
| 81 | + href="/metronic_v4.5.4/plugins/tipso/css/animate.css" | |
| 82 | + rel="stylesheet" type="text/css" /> | |
| 83 | + | |
| 84 | + <!-- 提示工具样式 --> | |
| 85 | + <link | |
| 86 | + href="/metronic_v4.5.4/plugins/tipso/css/tipso.css" | |
| 87 | + rel="stylesheet" type="text/css" /> | |
| 88 | + | |
| 89 | + <style type="text/css"> | |
| 90 | + .searchForm { | |
| 91 | + | |
| 92 | + } | |
| 93 | + | |
| 94 | + .searchForm .form-group .control-label { | |
| 95 | + padding-right: 0px; | |
| 96 | + text-align: right; | |
| 97 | + margin-top: 7px; | |
| 98 | + } | |
| 99 | + | |
| 100 | + .searchForm .form-group>div { | |
| 101 | + padding-left: 10px; | |
| 102 | + padding-right: 0px; | |
| 103 | + } | |
| 104 | + | |
| 105 | + .searchForm .row>div { | |
| 106 | + padding-left: 0px; | |
| 107 | + padding-right: 0px; | |
| 108 | + padding: 5px 0 5px 0; | |
| 109 | + width: 270px; | |
| 110 | + display: inline-block; | |
| 111 | + } | |
| 112 | + | |
| 113 | + .searchForm .form-actions { | |
| 114 | + | |
| 115 | + } | |
| 116 | + | |
| 117 | + tr.row-active td { | |
| 118 | + border-bottom: 1px solid blue !important; | |
| 119 | + color: blue; | |
| 120 | + } | |
| 121 | + | |
| 122 | + .ms-container .ms-selectable li.ms-elem-selectable,.ms-container .ms-selection li.ms-elem-selection | |
| 123 | + { | |
| 124 | + font-size: 14px; | |
| 125 | + } | |
| 126 | + | |
| 127 | + .ms-container .ms-selectable li.ms-elem-selectable,.ms-container .ms-selection li.ms-elem-selection | |
| 128 | + { | |
| 129 | + padding: 6px 26px; | |
| 130 | + } | |
| 131 | + | |
| 132 | + .ms-container .ms-list { | |
| 133 | + height: 306px; | |
| 134 | + } | |
| 135 | + | |
| 136 | + .ms-container .ms-selectable,.ms-container .ms-selection { | |
| 137 | + width: 47%; | |
| 138 | + } | |
| 139 | + | |
| 140 | + .ms-container { | |
| 141 | + width: 470px; | |
| 142 | + margin: auto; | |
| 143 | + } | |
| 144 | + | |
| 145 | + .multi-custom-header-left { | |
| 146 | + text-align: center; | |
| 147 | + padding: 7px; | |
| 148 | + color: #3B3F51; | |
| 149 | + } | |
| 150 | + | |
| 151 | + .multi-custom-header-right { | |
| 152 | + text-align: center; | |
| 153 | + padding: 7px; | |
| 154 | + font-weight: bold; | |
| 155 | + color: #36C6D3; | |
| 156 | + } | |
| 157 | + | |
| 158 | + .mt-element-list .list-simple.mt-list-container ul>.mt-list-item>.list-item-content | |
| 159 | + { | |
| 160 | + padding: 0 55px 0 0px; | |
| 161 | + } | |
| 162 | + | |
| 163 | + .mt-element-list .list-simple.mt-list-container ul>.mt-list-item { | |
| 164 | + padding: 3.3px 0; | |
| 165 | + } | |
| 166 | + | |
| 167 | + #route-container { | |
| 168 | + display: none; | |
| 169 | + } | |
| 170 | + | |
| 171 | + .page-content.active { | |
| 172 | + display: block !important; | |
| 173 | + } | |
| 174 | + | |
| 175 | + .page-header.navbar .page-logo .logo-default { | |
| 176 | + margin: 0; | |
| 177 | + } | |
| 178 | + | |
| 179 | + .page-header.navbar .top-menu .navbar-nav>li.dropdown.open .dropdown-toggle | |
| 180 | + { | |
| 181 | + background-color: #284a99; | |
| 182 | + } | |
| 183 | + | |
| 184 | + .page-header.navbar .page-logo { | |
| 185 | + padding-right: 10px; | |
| 186 | + } | |
| 187 | + | |
| 188 | + .page-logo .logo-default.logo-default-text { | |
| 189 | + font-weight: 600; | |
| 190 | + color: white !important; | |
| 191 | + margin-top: 19px !important; | |
| 192 | + font-size: 24px; | |
| 193 | + text-decoration: none; | |
| 194 | + } | |
| 195 | + | |
| 196 | + .page-logo .logo-default.logo-default-text:HOVER { | |
| 197 | + color: #dedede !important; | |
| 198 | + } | |
| 199 | + | |
| 200 | + body,.page-content-wrapper,#pjax-container{ | |
| 201 | + height: 100%; | |
| 202 | + } | |
| 203 | + html{ | |
| 204 | + height: 90%; | |
| 205 | + } | |
| 206 | + .page-container{ | |
| 207 | + height: 100%; | |
| 208 | + } | |
| 209 | + </style> | |
| 210 | + | |
| 211 | + <!-- ocLazyLoading载入文件的位置 --> | |
| 212 | + <link id="ng_load_plugins_before" /> | |
| 213 | + | |
| 214 | +</head> | |
| 215 | +<body | |
| 216 | + class="page-container-bg-solid page-header-fixed page-sidebar-closed-hide-logo page-sidebar-fixed"> | |
| 217 | +<div class="page-header navbar navbar-fixed-top" | |
| 218 | + style="background: linear-gradient(to bottom, #124e78, #125688);"> | |
| 219 | + <div class="page-header-inner "> | |
| 220 | + <!-- LOGO --> | |
| 221 | + <div class="page-logo"> | |
| 222 | + <a href="index.html" class="logo-default logo-default-text"> | |
| 223 | + 浦东公交调度系统 </a> | |
| 224 | + <div class="menu-toggler sidebar-toggler"></div> | |
| 225 | + </div> | |
| 226 | + <!-- END LOGO --> | |
| 227 | + <a href="javascript:;" class="menu-toggler responsive-toggler" | |
| 228 | + data-toggle="collapse" data-target=".navbar-collapse"> </a> | |
| 229 | + <div class="page-top"> | |
| 230 | + <div class="top-menu"> | |
| 231 | + <ul class="nav navbar-nav pull-right"> | |
| 232 | + <!-- 信息通知区 --> | |
| 233 | + <li | |
| 234 | + class="dropdown dropdown-extended dropdown-notification dropdown-dark" | |
| 235 | + id="header_notification_bar"><a href="javascript:;" | |
| 236 | + class="dropdown-toggle" data-toggle="dropdown" | |
| 237 | + data-hover="dropdown" data-close-others="true"> <i | |
| 238 | + class="fa fa-bell"></i> <span class="badge badge-success"> | |
| 239 | + 0 </span> | |
| 240 | + </a> | |
| 241 | + <ul class="dropdown-menu" style="max-width: 345px; width: 345px;"> | |
| 242 | + <li class="external"> | |
| 243 | + <h3> | |
| 244 | + 今日 <span class="bold">0 条</span> 通知 | |
| 245 | + </h3> <a href="javascript:;">查看全部</a> | |
| 246 | + </li> | |
| 247 | + <li> | |
| 248 | + <ul class="dropdown-menu-list scroller" style="height: 250px;" | |
| 249 | + data-handle-color="#637283"> | |
| 250 | + </ul> | |
| 251 | + </li> | |
| 252 | + </ul></li> | |
| 253 | + <li class="dropdown dropdown-user dropdown-dark"><a | |
| 254 | + href="javascript:;" class="dropdown-toggle" | |
| 255 | + data-toggle="dropdown" data-hover="dropdown" | |
| 256 | + data-close-others="true"> <span id="indexTopUName" | |
| 257 | + class="username username-hide-on-mobile" | |
| 258 | + style="vertical-align: middle;"> <i class="fa fa-user"></i></span> | |
| 259 | + </a> | |
| 260 | + <ul class="dropdown-menu dropdown-menu-default"> | |
| 261 | + <li><a href="javascript:;"> <i class="fa fa-user"></i> | |
| 262 | + 我的信息 | |
| 263 | + </a></li> | |
| 264 | + <li><a href="javascript:;" id="changePWD"> <i | |
| 265 | + class="fa fa-unlock-alt"></i> 修改密码 | |
| 266 | + </a></li> | |
| 267 | + <li class="divider"></li> | |
| 268 | + <li><a href="javascript:;"> <i class="fa fa-lock"></i> | |
| 269 | + 锁屏 | |
| 270 | + </a></li> | |
| 271 | + <li><a href="/logout"> <i class="fa fa-key"></i> 注销登陆 | |
| 272 | + </a></li> | |
| 273 | + </ul></li> | |
| 274 | + </ul> | |
| 275 | + </div> | |
| 276 | + </div> | |
| 277 | + </div> | |
| 278 | +</div> | |
| 279 | +<div class="page-container"> | |
| 280 | + <div class="page-sidebar-wrapper"> | |
| 281 | + <div class="page-sidebar navbar-collapse collapse"> | |
| 282 | + <ul class="page-sidebar-menu page-sidebar-menu-fixed" | |
| 283 | + data-keep-expanded="false" data-auto-scroll="true" | |
| 284 | + data-slide-speed="200" id="leftMenuSidebar"> | |
| 285 | + </ul> | |
| 286 | + </div> | |
| 287 | + </div> | |
| 288 | + <div class="page-content-wrapper"> | |
| 289 | + <div id="pjax-container" class="page-content"></div> | |
| 290 | + | |
| 291 | + <div id="route-container"> | |
| 292 | + <div ng-app="ScheduleApp"> | |
| 293 | + <div ng-controller="ScheduleAppController"> | |
| 294 | + | |
| 295 | + <!-- loading widget --> | |
| 296 | + <div id="loadingWidget" class="flyover mask" loading-widget> | |
| 297 | + <div class="alert alert-info"> | |
| 298 | + <strong>载入中......</strong> | |
| 299 | + </div> | |
| 300 | + </div> | |
| 301 | + | |
| 302 | + <div ui-view class="uv"></div> | |
| 303 | + </div> | |
| 304 | + </div> | |
| 305 | + </div> | |
| 306 | + </div> | |
| 307 | +</div> | |
| 308 | + | |
| 309 | +<script id="menu_list_temp" type="text/html"> | |
| 310 | + {{each list as group i}} | |
| 311 | + <li class="heading"> | |
| 312 | + <h3 class="uppercase">{{group.name}}</h3> | |
| 313 | + </li> | |
| 314 | + {{each group.children as dir j}} | |
| 315 | + <li class="nav-item"> | |
| 316 | + <a href="javascript:;" class="nav-link nav-toggle "> | |
| 317 | + <i class="{{dir.icon}}"></i> | |
| 318 | + <span class="title">{{dir.name}}</span> | |
| 319 | + <span class="arrow"></span> | |
| 320 | + </a> | |
| 321 | + <ul class="sub-menu"> | |
| 322 | + {{each dir.children as module s}} | |
| 323 | + <li class="nav-item "> | |
| 324 | + {{if module.container=="pjax-container"}} | |
| 325 | + <a href="/pages/{{module.path}}" class="nav-link " data-pjax> | |
| 326 | + <span class="title">{{module.name}}</span> | |
| 327 | + </a> | |
| 328 | + {{else}} | |
| 329 | + <a href="{{module.path}}" class="nav-link " data-angularjs> | |
| 330 | + <span class="title">{{module.name}}</span> | |
| 331 | + </a> | |
| 332 | + {{/if}} | |
| 333 | + </li> | |
| 334 | + {{/each}} | |
| 335 | + </ul> | |
| 336 | + </li> | |
| 337 | + {{/each}} | |
| 338 | + {{/each}} | |
| 339 | + | |
| 340 | +</script> | |
| 341 | +<script> | |
| 342 | + delete window.require; | |
| 343 | + delete window.exports; | |
| 344 | + delete window.module; | |
| 345 | +</script> | |
| 346 | +<!-- jQuery --> | |
| 347 | +<script src="/metronic_v4.5.4/plugins/jquery.min.js" data-exclude=1></script> | |
| 348 | +<!-- bootstrap --> | |
| 349 | +<script src="/metronic_v4.5.4/plugins/bootstrap/js/bootstrap.min.js" | |
| 350 | + data-exclude=1></script> | |
| 351 | +<script src="/pages/forms/statement/js/jquery.autocompleter.js"></script> | |
| 352 | +<script src="/pages/forms/statement/js/jquery.PrintArea.js"></script> | |
| 353 | +<!-- MTRONIC JS --> | |
| 354 | +<script src="/metronic_v4.5.4/scripts/app.min.js" data-exclude=1></script> | |
| 355 | +<script src="/metronic_v4.5.4/layout4/scripts/layout.min.js" | |
| 356 | + data-exclude=1></script> | |
| 357 | +<!-- 虚拟滚动条 --> | |
| 358 | +<script | |
| 359 | + src="/metronic_v4.5.4/plugins/jquery-slimscroll/jquery.slimscroll.min.js"></script> | |
| 360 | +<!-- jsTree 树插件 --> | |
| 361 | +<script src="/metronic_v4.5.4/plugins/jstree/dist/jstree.min.js"></script> | |
| 362 | +<!-- bootstrap-hover-dropDown --> | |
| 363 | +<script | |
| 364 | + src="/metronic_v4.5.4/plugins/bootstrap-hover-dropdown/bootstrap-hover-dropdown.min.js"></script> | |
| 365 | +<!-- jquery.validate 表单验证 --> | |
| 366 | +<script | |
| 367 | + src="/metronic_v4.5.4/plugins/jquery-validation/js/jquery.validate.min.js"></script> | |
| 368 | +<script | |
| 369 | + src="/metronic_v4.5.4/plugins/jquery-validation/js/localization/messages_zh.js"></script> | |
| 370 | +<!-- 向导式插件 --> | |
| 371 | +<script | |
| 372 | + src="/metronic_v4.5.4//plugins/bootstrap-wizard/jquery.bootstrap.wizard.min.js"></script> | |
| 373 | +<!-- iCheck 单选框和复选框 --> | |
| 374 | +<script src="/metronic_v4.5.4/plugins/icheck/icheck.min.js"></script> | |
| 375 | +<!-- select2 下拉框 --> | |
| 376 | +<script src="/metronic_v4.5.4/plugins/select2/js/select2.full.min.js"></script> | |
| 377 | +<!-- MULTI SELECT 多选下拉框 --> | |
| 378 | +<script | |
| 379 | + src="/metronic_v4.5.4/plugins/jquery-multi-select/js/jquery.multi-select.js"></script> | |
| 380 | +<!-- editable.js --> | |
| 381 | +<script | |
| 382 | + src="/metronic_v4.5.4/plugins/bootstrap-editable/bootstrap-editable/js/bootstrap-editable.min.js"></script> | |
| 383 | +<!-- PJAX --> | |
| 384 | +<script src="/assets/plugins/jquery.pjax.js"></script> | |
| 385 | +<!-- layer 弹层 --> | |
| 386 | +<script src="/assets/plugins/layer-v2.4/layer/layer.js" data-exclude=1></script> | |
| 387 | +<!-- fileinput 上传 --> | |
| 388 | +<script src="/assets/plugins/fileinput/canvas-to-blob.min.js"></script> | |
| 389 | +<script src="/assets/plugins/fileinput/purify.min.js"></script> | |
| 390 | +<script src="/assets/plugins/fileinput/sortable.min.js"></script> | |
| 391 | +<script src="/assets/plugins/fileinput/fileinput.min.js"></script> | |
| 392 | +<script src="/assets/plugins/fileinput/fileinput_locale_zh.js"></script> | |
| 393 | +<!-- jquery.purl URL解析 --> | |
| 394 | +<script src="/assets/plugins/purl.js"></script> | |
| 395 | +<!-- jquery.serializejson JSON序列化插件 --> | |
| 396 | +<script src="/assets/plugins/jquery.serializejson.js"></script> | |
| 397 | +<!-- art-template 模版引擎 --> | |
| 398 | +<script src="/assets/plugins/template.js"></script> | |
| 399 | +<!-- jquery.pageinator 分页 --> | |
| 400 | +<script src="/assets/plugins/jqPaginator.min.js"></script> | |
| 401 | +<!-- moment.js 日期处理类库 --> | |
| 402 | +<script src="/assets/plugins/moment-with-locales.js"></script> | |
| 403 | + | |
| 404 | +<script src="/assets/plugins/pinyin.js"></script> | |
| 405 | +<!-- 日期控件 --> | |
| 406 | +<script | |
| 407 | + src="/metronic_v4.5.4/plugins/bootstrap-datetimepicker-2/js/bootstrap-datetimepicker.min.js"></script> | |
| 408 | +<!-- 表格控件 --> | |
| 409 | +<script src="/metronic_v4.5.4/plugins/bootstrap-tagsinput/bootstrap-tagsinput.min.js"></script> | |
| 410 | +<!-- 统计图控件 --> | |
| 411 | +<!--<script src="/assets/global/getEchart.js"></script> | |
| 412 | +<script src="/assets/global/echarts.js"></script> --> | |
| 413 | +<script src="/assets/js/common.js"></script> | |
| 414 | +<script src="/assets/js/dictionary.js"></script> | |
| 415 | +<!-- tipso JS --> | |
| 416 | +<script src="/metronic_v4.5.4/plugins/tipso/js/tipso.js"></script> | |
| 417 | +<script data-exclude=1> | |
| 418 | + //初始打开的片段地址 | |
| 419 | + var initFragment = "^_^initFragment^_^"; | |
| 420 | + //静态文件目录 | |
| 421 | + var dir = '/pages/'; | |
| 422 | + //片段容器 | |
| 423 | + var pjaxContainer = '#pjax-container' | |
| 424 | + , angJsContainer = '#route-container'; | |
| 425 | + | |
| 426 | + $(document).ajaxError(function (event, jqxhr, settings, thrownError) { | |
| 427 | + if(jqxhr.status == 403){ | |
| 428 | + layer.closeAll(); | |
| 429 | + layer.alert(jqxhr.message?jqxhr.message:'访问被拒绝', {icon: 2, title: '操作失败'}); | |
| 430 | + } | |
| 431 | + }); | |
| 432 | + | |
| 433 | + $(function () { | |
| 434 | + $.get('/user/currentUser', function (user) { | |
| 435 | + $('#indexTopUName').text(user.userName); | |
| 436 | + }); | |
| 437 | + | |
| 438 | + //带 data-pjax 的链接由pjax加载 | |
| 439 | + $(document).pjax('a[data-pjax]', pjaxContainer); | |
| 440 | + | |
| 441 | + //pjax左菜单点击事件 | |
| 442 | + $(document).on('click', '#leftMenuSidebar a[data-pjax]', function () { | |
| 443 | + setTitle(this); | |
| 444 | + | |
| 445 | + $('#leftMenuSidebar li.nav-item.active').removeClass('active'); | |
| 446 | + $(this).parent().addClass('active'); | |
| 447 | + showPjax(); | |
| 448 | + }); | |
| 449 | + | |
| 450 | + //angularjs左菜单点击事件 | |
| 451 | + $(document).on('click', '#leftMenuSidebar a[data-angularjs]', function () { | |
| 452 | + setTitle(this); | |
| 453 | + | |
| 454 | + $('#leftMenuSidebar li.nav-item.active').removeClass('active'); | |
| 455 | + $(this).parent().addClass('active'); | |
| 456 | + showAngJs(); | |
| 457 | + }); | |
| 458 | + | |
| 459 | + //加载左菜单栏 | |
| 460 | + $get('/module/findByCurrentUser', null, | |
| 461 | + function (ms) { | |
| 462 | + var treeArray = createTreeData(ms); | |
| 463 | + treeArray.sort(function (a, b) { | |
| 464 | + return a.createDate - b.createDate; | |
| 465 | + }); | |
| 466 | + var menuHtml = template('menu_list_temp', {list: treeArray}); | |
| 467 | + $('#leftMenuSidebar').html(menuHtml); | |
| 468 | + | |
| 469 | + //----------- 检查URL ---------------- | |
| 470 | + var h = location.hash; | |
| 471 | + if (initFragment && initFragment != '') { | |
| 472 | + showPjax(); | |
| 473 | + //普通片段 | |
| 474 | + loadPage(initFragment); | |
| 475 | + //选中菜单 | |
| 476 | + $.each($('#leftMenuSidebar a'), function (i, item) { | |
| 477 | + if (urlPattern($(item).attr('href'), initFragment)) { | |
| 478 | + activeLeftMenu(item); | |
| 479 | + } | |
| 480 | + }); | |
| 481 | + } else if (h) { | |
| 482 | + //angularjs片段 | |
| 483 | + showAngJs(); | |
| 484 | + //选中菜单 | |
| 485 | + $.each($('#leftMenuSidebar a'), function (i, item) { | |
| 486 | + if ($(item).attr('href') == h) { | |
| 487 | + activeLeftMenu(item); | |
| 488 | + } | |
| 489 | + }); | |
| 490 | + } | |
| 491 | + else { | |
| 492 | + //加载主页 | |
| 493 | + loadPage('/pages/home.html'); | |
| 494 | + } | |
| 495 | + }); | |
| 496 | + | |
| 497 | + //修改密码 | |
| 498 | + $('#changePWD').on('click', function () { | |
| 499 | + $.get('/pages/permission/user/changePWD.html', function (content) { | |
| 500 | + layer.open({ | |
| 501 | + type: 1, | |
| 502 | + area: ['600px', '360px'], | |
| 503 | + content: content, | |
| 504 | + title: '修改密码', | |
| 505 | + shift: 5, | |
| 506 | + scrollbar: false, | |
| 507 | + success: function () { | |
| 508 | + } | |
| 509 | + }); | |
| 510 | + }); | |
| 511 | + }); | |
| 512 | + }); | |
| 513 | + | |
| 514 | + //modal关闭时销毁dom | |
| 515 | + $(document).on('hidden.bs.modal', '.modal', function () { | |
| 516 | + $(this).remove(); | |
| 517 | + }); | |
| 518 | + | |
| 519 | + //pjax加载完成事件 | |
| 520 | + $(document).on('pjax:success', function () { | |
| 521 | + var dicts = $(pjaxContainer).find('.nt-dictionary'); | |
| 522 | + dictionaryUtils.transformDom(dicts); | |
| 523 | + }); | |
| 524 | + | |
| 525 | + function loadPage(url) { | |
| 526 | + $.pjax({url: url, container: pjaxContainer}) | |
| 527 | + } | |
| 528 | + | |
| 529 | + function urlPattern(a, b) { | |
| 530 | + var r; | |
| 531 | + try { | |
| 532 | + r = a.substring(0, a.lastIndexOf('/')) == b.substring(0, b.lastIndexOf('/')); | |
| 533 | + } catch (e) { | |
| 534 | + r = false; | |
| 535 | + } | |
| 536 | + return r; | |
| 537 | + } | |
| 538 | + | |
| 539 | + function showPjax() { | |
| 540 | + $(angJsContainer).removeClass('page-content active').hide(); | |
| 541 | + $(pjaxContainer).addClass('page-content active'); | |
| 542 | + } | |
| 543 | + | |
| 544 | + function showAngJs() { | |
| 545 | + $(pjaxContainer).html('').removeClass('page-content active').hide(); | |
| 546 | + $(angJsContainer).addClass('page-content active'); | |
| 547 | + } | |
| 548 | + | |
| 549 | + function activeLeftMenu(item) { | |
| 550 | + $(item).parent('.nav-item').addClass('active').parent('.sub-menu').show().parent().addClass('open'); | |
| 551 | + setTitle(item); | |
| 552 | + } | |
| 553 | + | |
| 554 | + function setTitle(menuItem){ | |
| 555 | + document.title = $('span.title', menuItem).text(); | |
| 556 | + } | |
| 557 | + | |
| 558 | +</script> | |
| 559 | +<!-- d3 --> | |
| 560 | +<script src="/assets/js/d3.min.js" data-exclude=1></script> | |
| 561 | +<!-- webSocket JS --> | |
| 562 | +<script src="/assets/js/sockjs.min.js"></script> | |
| 563 | + | |
| 564 | +<!-- TODO:angularJS相关库 --> | |
| 565 | + | |
| 566 | +<!-- angularJS相关库 --> | |
| 567 | +<!-- 这个是基于angularjs 1.4.10修改的版本,主要是修改了history控制部分,用于兼容route和pjax的同时操作history的冲突 --> | |
| 568 | +<script src="/assets/js/angular.js" data-autocephaly=1></script> | |
| 569 | +<script src="/assets/bower_components/angular-i18n/angular-locale_zh-cn.js" data-autocephaly=1></script> | |
| 570 | +<script | |
| 571 | + src="/assets/bower_components/angular-resource/angular-resource.min.js" | |
| 572 | + data-exclude=1></script> | |
| 573 | +<script | |
| 574 | + src="/assets/bower_components/angular-sanitize/angular-sanitize.min.js" | |
| 575 | + data-exclude=1></script> | |
| 576 | +<script | |
| 577 | + src="/assets/bower_components/angular-animate/angular-animate.min.js" | |
| 578 | + data-exclude=1></script> | |
| 579 | +<script | |
| 580 | + src="/assets/bower_components/angular-touch/angular-touch.min.js" | |
| 581 | + data-exclude=1></script> | |
| 582 | +<script | |
| 583 | + src="/assets/bower_components/angular-ui-router/release/angular-ui-router.min.js" | |
| 584 | + data-exclude=1></script> | |
| 585 | +<script | |
| 586 | + src="/assets/bower_components/oclazyload/dist/ocLazyLoad.min.js" | |
| 587 | + data-exclude=1></script> | |
| 588 | +<script | |
| 589 | + src="/assets/bower_components/angular-bootstrap/ui-bootstrap-tpls.min.js" | |
| 590 | + data-exclude=1></script> | |
| 591 | +<!-- handsontable相关js --> | |
| 592 | +<script | |
| 593 | + src="/assets/bower_components/handsontable/dist/handsontable.full.js"></script> | |
| 594 | +<script | |
| 595 | + src="/assets/bower_components/ngHandsontable/dist/ngHandsontable.js"></script> | |
| 596 | +<!-- sweetalert相关js --> | |
| 597 | +<script src="/assets/bower_components/sweetalert/dist/sweetalert.min.js"></script> | |
| 598 | +<script src="/assets/bower_components/ng-sweet-alert/ng-sweet-alert.js"></script> | |
| 599 | + | |
| 600 | +<!-- schedule计划调度AngularJS模块主JS --> | |
| 601 | +<script src="/pages/scheduleApp/module/common/main.js" data-exclude=1></script> | |
| 602 | +<script | |
| 603 | + src="/pages/scheduleApp/module/common/prj-common-globalservice.js" | |
| 604 | + data-exclude=1></script> | |
| 605 | +<script src="/pages/scheduleApp/module/common/prj-common-filter.js" | |
| 606 | + data-exclude=1></script> | |
| 607 | +<script src="/pages/scheduleApp/module/common/prj-common-directive.js" | |
| 608 | + data-exclude=1></script> | |
| 609 | +<script | |
| 610 | + src="/pages/scheduleApp/module/common/prj-common-ui-route-state.js" | |
| 611 | + data-exclude=1></script> | |
| 612 | + | |
| 613 | +<!-- 地图相关 --> | |
| 614 | +<!-- 百度 --> | |
| 615 | +<script | |
| 616 | + src="//api.map.baidu.com/api?v=2.0&ak=IGGrr4UjwIYzatoCRFKEL8sT" | |
| 617 | + data-exclude=1></script> | |
| 618 | +<script | |
| 619 | + src="//api.map.baidu.com/library/TrafficControl/1.4/src/TrafficControl_min.js" | |
| 620 | + data-exclude=1></script> | |
| 621 | +<script type="text/javascript" | |
| 622 | + src="//api.map.baidu.com/library/DrawingManager/1.4/src/DrawingManager_min.js" | |
| 623 | + data-exclude=1></script> | |
| 624 | +<script type="text/javascript" | |
| 625 | + src="//api.map.baidu.com/library/RichMarker/1.2/src/RichMarker_min.js " | |
| 626 | + data-exclude=1></script> | |
| 627 | +<script src="/assets/js/baidu/TextIconOverlay.js" data-exclude=1></script> | |
| 628 | +<script src="/assets/js/baidu//MarkerClusterer.js" data-exclude=1></script> | |
| 629 | +<!-- 高德 --> | |
| 630 | +<script | |
| 631 | + src="//webapi.amap.com/maps?v=1.3&key=16cb1c5043847e09ef9edafdd77befda" | |
| 632 | + data-exclude=1></script> | |
| 633 | +<!-- echarts4 --> | |
| 634 | +<script src="/metronic_v4.5.4/plugins/echarts4/echarts.min.js"></script> | |
| 635 | +<script src="/real_control_v2/assets/plugins/perfect-scrollbar/perfect-scrollbar.jquery.js" merge="plugins"></script> | |
| 636 | +<!-- RSA加密 --> | |
| 637 | +<script src="/assets/plugins/jsencrypt.min.js"></script> | |
| 638 | + | |
| 639 | +</body> | |
| 640 | 640 | </html> |
| 641 | 641 | \ No newline at end of file | ... | ... |
src/main/resources/static/pages/base/line/editRoute.html
| 1 | -<!-- 手动添加站点 --> | |
| 2 | -<div class="modal fade" id="edit_route_mobal" tabindex="-1" role="basic" | |
| 3 | - aria-hidden="true"> | |
| 4 | - | |
| 5 | - <div class="modal-dialog"> | |
| 6 | - | |
| 7 | - <div class="modal-content" > | |
| 8 | - | |
| 9 | - <div class="modal-header"> | |
| 10 | - <button type="button" class="close" data-dismiss="modal" | |
| 11 | - aria-hidden="true"></button> | |
| 12 | - <h4 class="modal-title">生成路线(站点和路段)</h4> | |
| 13 | - </div> | |
| 14 | - | |
| 15 | - <div class="modal-body"> | |
| 16 | - | |
| 17 | - <form class="form-horizontal" role="form" | |
| 18 | - id="save_route_template_form" action="" method=""> | |
| 19 | - | |
| 20 | - <div class="alert alert-danger display-hide"> | |
| 21 | - <button class="close" data-close="alert"></button> | |
| 22 | - 您的输入有误,请检查下面的输入项 | |
| 23 | - </div> | |
| 24 | - | |
| 25 | - <!-- 站点名称 --> | |
| 26 | - <div class="form-body"> | |
| 27 | - | |
| 28 | - <div class="form-group"> | |
| 29 | - <label class="control-label col-md-2"> <span | |
| 30 | - class="required"> * </span> 坐标: | |
| 31 | - </label> | |
| 32 | - <div class="col-md-10"> | |
| 33 | - <textarea class="form-control" rows="12" name="points" | |
| 34 | - id="pointInput" placeholder="坐标点"></textarea> | |
| 35 | - </div> | |
| 36 | - </div> | |
| 37 | - </div> | |
| 38 | - <div class="form-group"> | |
| 39 | - <label class="col-md-3 control-label">选择文本类型:</label> | |
| 40 | - <div class="col-md-3"> | |
| 41 | - <div class="icheck-list"> | |
| 42 | - <label> <input type="radio" class="icheck" | |
| 43 | - name="typeCheck" value='0' checked> txt | |
| 44 | - </label> <label> <input type="radio" class="icheck" | |
| 45 | - name="typeCheck" value='1'> xml | |
| 46 | - </label> | |
| 47 | - </div> | |
| 48 | - </div> | |
| 49 | - <label class="col-md-3 control-label">选择方向:</label> | |
| 50 | - <div class="col-md-3"> | |
| 51 | - <div class="icheck-list"> | |
| 52 | - <label> <input type="radio" class="icheck" | |
| 53 | - name="dirCheck" value='0' checked> 上行 | |
| 54 | - </label> <label> <input type="radio" class="icheck" | |
| 55 | - name="dirCheck" value='1'> 下行 | |
| 56 | - </label> | |
| 57 | - </div> | |
| 58 | - </div> | |
| 59 | - </div> | |
| 60 | - <div class="form-group"> | |
| 61 | - <div class="alert alert-info font-blue-chambray" | |
| 62 | - style="background-color: #2C3E50"> | |
| 63 | - <h5 class="block"> | |
| 64 | - <span class="help-block" style="color: #1bbc9b;"> * | |
| 65 | - 坐标生成路线规划说明: </span> | |
| 66 | - </h5> | |
| 67 | - <p> | |
| 68 | - | |
| 69 | - <span class="help-block" style="color: #1bbc9b;"> | |
| 70 | - 1.txt格式 | |
| 71 | - <br> 请在文本域中按顺序依次输坐标点,每行中的数据之间用【Tab】键隔开(如果是站点,请将在坐标后面加 stop;没有 | |
| 72 | - stop默认是路段点,连续带stop的坐标认为是同一个站点),每输入完一个坐标时请按回车键【Enter】换行. 例如: | |
| 73 | - <br>121.511870 31.180638 043703.000 | |
| 74 | - <br>121.511870 31.180643 043705.000 | |
| 75 | - <br>121.511870 31.180648 043706.000 Stop | |
| 76 | - <br>121.511872 31.180653 043707.000 | |
| 77 | - </span> | |
| 78 | - </p> | |
| 79 | - <p> | |
| 80 | - | |
| 81 | - <span class="help-block" style="color: #1bbc9b;"> | |
| 82 | - 2.xml格式 | |
| 83 | - <br>用gps生成工具,生成的kml文件里的数据 | |
| 84 | - </span> | |
| 85 | - </p> | |
| 86 | - </div> | |
| 87 | - </div> | |
| 88 | - </form> | |
| 89 | - </div> | |
| 90 | - <div class="modal-footer"> | |
| 91 | - <button type="button" class="btn default" data-dismiss="modal" | |
| 92 | - id="addMobalHiden">取消</button> | |
| 93 | -<!-- <button type="button" class="btn btn-primary hidden" id="referenceCurrentVersion">引用当前版本</button> --> | |
| 94 | - <button type="button" class="btn btn-primary" id="templateSaveData">提交数据</button> | |
| 95 | - </div> | |
| 96 | - </div> | |
| 97 | - </div> | |
| 98 | -</div> | |
| 99 | -<script type="text/javascript"> | |
| 100 | - | |
| 101 | -$('#edit_route_mobal').on('editRouteMobal.show', function(e,transGPS,editRoute,map,dra,ajaxd,fun){ | |
| 102 | - // 延迟加载显示mobal | |
| 103 | - setTimeout(function(){$('#edit_route_mobal').modal({show : true,backdrop: 'static', keyboard: false});},200); | |
| 104 | - // 获取表单元素 | |
| 105 | - var form = $('#save_route_template_form'); | |
| 106 | - | |
| 107 | - // 获取错误提示信息元素 | |
| 108 | - var error = $('.alert-danger', form); | |
| 109 | - | |
| 110 | - // 提交数据点击事件 | |
| 111 | - $('.modal-footer #templateSaveData').on('click',function() { | |
| 112 | - form.submit(); | |
| 113 | - }); | |
| 114 | - | |
| 115 | - | |
| 116 | - //从xml中获取节点内容 | |
| 117 | - function getXmlNode(str){ | |
| 118 | - //创建文档对象 | |
| 119 | - var parser=new DOMParser(); | |
| 120 | - var xmlDoc=parser.parseFromString(str,"text/xml"); | |
| 121 | - | |
| 122 | - //提取数据 | |
| 123 | - var countrys = xmlDoc.getElementsByTagName('coordinates'); | |
| 124 | - //var countrys = xmlDoc.getElementsByTagName('DataSource'); | |
| 125 | - | |
| 126 | - var arr = []; | |
| 127 | - | |
| 128 | - for (var i = 0; i < countrys.length; i++) { | |
| 129 | - arr.push(countrys[i].textContent); | |
| 130 | - }; | |
| 131 | - // console.log(arr); | |
| 132 | - return arr; | |
| 133 | - | |
| 134 | - } | |
| 135 | - | |
| 136 | - // xml方式上传是,处理转成txt格式的方法 | |
| 137 | - var getXmlSection = function (xml) { | |
| 138 | - // var xml = $("#xmlText").val(); | |
| 139 | - var stationPointList = getXmlNode(xml); | |
| 140 | - var sListSize = stationPointList.length; | |
| 141 | - var sectionPointListStr = stationPointList[stationPointList.length - 1]; | |
| 142 | - var sectionPointList = sectionPointListStr.split(" "); | |
| 143 | - var index = 0; | |
| 144 | - | |
| 145 | - // var sectionStr = ""; | |
| 146 | - var sections = []; | |
| 147 | - for (var i = 0; i < sectionPointList.length; i++) { | |
| 148 | - var pointStr = sectionPointList[i], | |
| 149 | - point = pointStr.split(","); | |
| 150 | - | |
| 151 | - if (index < sListSize - 1 && point == stationPointList[index]) { | |
| 152 | - sections.push(point[0] + " " + point[1] + " " + point[2] + " Stop"); | |
| 153 | - index++; | |
| 154 | - } else { | |
| 155 | - sections.push(point[0] + " " + point[1] + " " + point[2]); | |
| 156 | - } | |
| 157 | - } | |
| 158 | - return sections; | |
| 159 | - }; | |
| 160 | - | |
| 161 | - | |
| 162 | - // 表单验证 | |
| 163 | - form.validate({ | |
| 164 | - | |
| 165 | - errorElement : 'span', | |
| 166 | - | |
| 167 | - errorClass : 'help-block help-block-error', | |
| 168 | - | |
| 169 | - focusInvalid : false, | |
| 170 | - | |
| 171 | - rules : { | |
| 172 | - | |
| 173 | - 'points' : { | |
| 174 | - | |
| 175 | - required : true, | |
| 176 | - | |
| 177 | - } | |
| 178 | - | |
| 179 | - }, | |
| 180 | - | |
| 181 | - invalidHandler : function(event, validator) { | |
| 182 | - | |
| 183 | - error.show(); | |
| 184 | - | |
| 185 | - App.scrollTo(error, -200); | |
| 186 | - | |
| 187 | - }, | |
| 188 | - | |
| 189 | - highlight : function(element) { | |
| 190 | - | |
| 191 | - $(element).closest('.form-group').addClass('has-error'); | |
| 192 | - | |
| 193 | - }, | |
| 194 | - | |
| 195 | - unhighlight : function(element) { | |
| 196 | - | |
| 197 | - $(element).closest('.form-group').removeClass('has-error'); | |
| 198 | - | |
| 199 | - }, | |
| 200 | - | |
| 201 | - success : function(label) { | |
| 202 | - | |
| 203 | - label.closest('.form-group').removeClass('has-error'); | |
| 204 | - | |
| 205 | - }, | |
| 206 | - submitHandler : function(f) { | |
| 207 | - // 隐藏弹出层 | |
| 208 | - $('#edit_route_mobal').modal('hide'); | |
| 209 | - // 获取线路对象 | |
| 210 | - var line = editRoute.getLineObj(); | |
| 211 | - // 原坐标类型 | |
| 212 | - var baseRes = "WGS84"; | |
| 213 | - // 定义线路名称 | |
| 214 | - var lineNameV = $('.portlet-title .caption').text(); | |
| 215 | - var dirStr = ''; | |
| 216 | - // 路线方向 | |
| 217 | - var directionData = $("input[name='dirCheck']:checked").val(); | |
| 218 | - /** | |
| 219 | - * 添加类型0(txt)/1(xml) | |
| 220 | - * txt方式路段需要30个点取一个 | |
| 221 | - * xml路段取所有点 | |
| 222 | - */ | |
| 223 | - var type = $("input[name='typeCheck']:checked").val(); | |
| 224 | - editRoute.setLineDir(directionData); | |
| 225 | - // 设置线路对象生成方式 | |
| 226 | - editRoute.setLineGenerationType('uploadGPS'); | |
| 227 | - // 弹出正在加载层 | |
| 228 | - var i = layer.load(2); | |
| 229 | - // 表单序列化 | |
| 230 | - var paramsForm = form.serializeJSON(); | |
| 231 | - var array = []; | |
| 232 | - if(type == 1){ | |
| 233 | - array = getXmlSection(paramsForm.points); | |
| 234 | - } else { | |
| 235 | - // 切割坐标点 | |
| 236 | - array = paramsForm.points.split('\r\n'); | |
| 237 | - } | |
| 238 | - // 把坐标点转换为站点或路段 | |
| 239 | - var arrayFormat = inputStationValueFormat(array); | |
| 240 | - var stationList = arrayFormat.stationList; | |
| 241 | - var sectionListTemp = arrayFormat.sectionList; | |
| 242 | - var sectionList = []; | |
| 243 | - // 隔30个取一个点(相当于30s) | |
| 244 | - var typeNum = type == 0 ? 30:1; | |
| 245 | - for(var i = 0; i*typeNum < sectionListTemp.length; i++) { | |
| 246 | - sectionList[i] = sectionListTemp[i*typeNum]; | |
| 247 | - } | |
| 248 | - sectionList[sectionList.length] = sectionListTemp[sectionListTemp.length-1]; | |
| 249 | - | |
| 250 | - var sectionListFinal = []; | |
| 251 | - sectionListFinal.push({sectionName : lineNameV, points : sectionList}); | |
| 252 | - // 根据站点名称获取百度坐标 | |
| 253 | - map.stationsPointsToLibraryPoint(stationList,function(resultJson) { | |
| 254 | - // 根据坐标点获取两点之间的时间与距离 | |
| 255 | - map.getDistanceAndDuration(resultJson,function(stationdataList) { | |
| 256 | - // 设置第一个站的距离 | |
| 257 | - stationdataList[0].distance = ''; | |
| 258 | - // 设置第一个站的时间 | |
| 259 | - stationdataList[0].duration = ''; | |
| 260 | - // 定义站点信息JSON字符串 | |
| 261 | - var stationJSON = JSON.stringify(stationdataList); | |
| 262 | - // 参数集合 | |
| 263 | - var params = {}; | |
| 264 | - params.baseRes = baseRes; | |
| 265 | - // 是否添加该站点 | |
| 266 | - | |
| 267 | - // 站点信息JSON字符串 | |
| 268 | - params.stationJSON = stationJSON; | |
| 269 | - // 线路ID | |
| 270 | - params.lineId = line.id; | |
| 271 | - // 方向 | |
| 272 | - params.directions = directionData; | |
| 273 | - // 原始坐标类型 | |
| 274 | - params.dbType = 'b'; | |
| 275 | - // 圆形半径 | |
| 276 | - params.radius = '80'; | |
| 277 | - // 限速 | |
| 278 | - params.speedLimit = '60'; | |
| 279 | - // 图形类型(r:圆形;p:多边形) | |
| 280 | - params.shapesType = 'r'; | |
| 281 | - // destroy:是否撤销 | |
| 282 | - params.destroy = '0'; | |
| 283 | - // versions:版本号 | |
| 284 | - params.versions = '1'; | |
| 285 | - // 定义路段信息字符串 | |
| 286 | - var sectionJSON = JSON.stringify(sectionListFinal); | |
| 287 | - // 路段信息JSON字符串 | |
| 288 | - params.sectionJSON = sectionJSON; | |
| 289 | - addSave(params,line.id,directionData); | |
| 290 | - }); | |
| 291 | - | |
| 292 | - }); | |
| 293 | - }, | |
| 294 | - | |
| 295 | - }); | |
| 296 | - | |
| 297 | - function inputStationValueFormat(paramsStationsArray) { | |
| 298 | - var stationList = []; | |
| 299 | - var sectionList = []; | |
| 300 | - var routeList = {"stationList":stationList, "sectionList":sectionList}; | |
| 301 | - var len = paramsStationsArray.length; | |
| 302 | - // 处理相同站点判断值 | |
| 303 | - var isPush = true; | |
| 304 | - for(var k =0;k<len;k++) { | |
| 305 | - if(paramsStationsArray[k]=="") | |
| 306 | - continue; | |
| 307 | - var tempStr = paramsStationsArray[k].split('\t'); | |
| 308 | - var tempPoint = transGpsLoc(tempStr[0],tempStr[1]); | |
| 309 | - var point = {lng:tempPoint.lng, lat:tempPoint.lat}; | |
| 310 | - if(tempStr.length < 4){ | |
| 311 | - sectionList[k] = point; | |
| 312 | - isPush = true; | |
| 313 | - }else { | |
| 314 | - if(isPush) { | |
| 315 | - sectionList[k] = point; | |
| 316 | - stationList.push({name:tempStr[3], potion:{lng:tempPoint.lng, lat:tempPoint.lat} , wgs:{x:tempStr[0], y:tempStr[1]}}); | |
| 317 | - } | |
| 318 | - isPush = false; | |
| 319 | - } | |
| 320 | - } | |
| 321 | - for(var i = 0 ;i<sectionList.length;i++) { | |
| 322 | - if(sectionList[i] == "" || typeof(sectionList[i]) == "undefined" || sectionList[i] == null) { | |
| 323 | - sectionList.splice(i,1);//删除数组中下表i-i+1之间的值 | |
| 324 | - i= i-1; | |
| 325 | - } | |
| 326 | - | |
| 327 | - } | |
| 328 | - return routeList; | |
| 329 | - } | |
| 330 | - | |
| 331 | - function transGpsLoc(lng,lat) { | |
| 332 | - var bdLoc = transGPS.locationMake(lng, lat); | |
| 333 | - var gcjLoc = transGPS.transformFromWGSToGCJ(bdLoc); | |
| 334 | - var bdEn = transGPS.bd_encrypt(gcjLoc); | |
| 335 | - return bdEn; | |
| 336 | - } | |
| 337 | - | |
| 338 | - /** 引用当前版本站点和走向*/ | |
| 339 | - /* $("#referenceCurrentVersion").on('click',function() { | |
| 340 | - // 获取线路对象 | |
| 341 | - var line = editRoute.getLineObj(); | |
| 342 | - // 路线方向 | |
| 343 | - var direction = $("input[name='dirCheck']:checked").val(); | |
| 344 | - // 设置线路对象方向 | |
| 345 | - editRoute.setLineDir(direction); | |
| 346 | - // 设置线路对象生成方式 | |
| 347 | - editRoute.setLineGenerationType('cite'); | |
| 348 | - $.post("/station/referenceCurrentVersion",{'lineId' : line.id , 'directions' : direction},function(rd){ | |
| 349 | - // 隐藏弹出层 | |
| 350 | - $('#edit_route_mobal').modal('hide'); | |
| 351 | - // 关闭弹出层 | |
| 352 | - layer.closeAll(); | |
| 353 | - if(rd.status='SUCCESS') { | |
| 354 | - // 清除地图覆盖物 | |
| 355 | - map.clearMarkAndOverlays(); | |
| 356 | - // 查询路段信息 | |
| 357 | - var params = {}; | |
| 358 | - params.lineId=line.id; | |
| 359 | - params.dir = direction; | |
| 360 | - // 查询路段信息 | |
| 361 | - $get('/sectionroute/findCacheSection',params,function(data) { | |
| 362 | - // 在地图上画出线路走向 | |
| 363 | - fun.linePanlThree(line.id,data,direction); | |
| 364 | - }); | |
| 365 | - $('#route_show').removeClass('hidden'); | |
| 366 | - $('#generationRoute_div').addClass('hidden'); | |
| 367 | - // 刷新路段列表 | |
| 368 | - $('#section').click(); | |
| 369 | - layer.msg('引用当前版本成功!'); | |
| 370 | - }else { | |
| 371 | - layer.msg('引用当前版本失败,请重新引用或选择其他方式!'); | |
| 372 | - } | |
| 373 | - }) | |
| 374 | - }); */ | |
| 375 | - | |
| 376 | - function addSave(params,lineid,directionData) { | |
| 377 | - // 保存 | |
| 378 | - $post("/station/cacheSave",params,function(rd) { | |
| 379 | - // 关闭弹出层 | |
| 380 | - layer.closeAll(); | |
| 381 | - if(rd.status='SUCCESS') { | |
| 382 | - var stationD = rd.stationData,isNullStr = ''; | |
| 383 | - for(var t = 0 ;t<stationD.length;t++) { | |
| 384 | - if(stationD[t].potion.lat =='' || stationD[t].potion.lat ==null || | |
| 385 | - stationD[t].potion.lng =='' || stationD[t].potion.lng ==null) | |
| 386 | - isNullStr = isNullStr + stationD[t].name + ' , '; | |
| 387 | - } | |
| 388 | - if(isNullStr!='') { | |
| 389 | - layer.open({ | |
| 390 | - title: '提示', | |
| 391 | - content:'【' + isNullStr + '】' + '地址系统无法解析!,请手动调整位置!' | |
| 392 | - }); | |
| 393 | - } | |
| 394 | - // 清除地图覆盖物 | |
| 395 | - map.clearMarkAndOverlays(); | |
| 396 | - var params = {}; | |
| 397 | - params.lineId = lineid; | |
| 398 | - params.dir = directionData; | |
| 399 | - // 查询路段信息 | |
| 400 | - $get('/sectionroute/findCacheSection',params,function(data) { | |
| 401 | - // 在地图上画出线路走向 | |
| 402 | - fun.linePanlThree(lineid,data,directionData); | |
| 403 | - }); | |
| 404 | - $('#route_show').removeClass('hidden'); | |
| 405 | - $('#generationRoute_div').addClass('hidden'); | |
| 406 | - // 刷新路段列表 | |
| 407 | - $('#section').click(); | |
| 408 | - layer.open({title: '友情提示' | |
| 409 | - ,content: '生成路线成功,生成的线路可能会有误差。请先单击路段,拖动编辑、然后双击保存!'}); | |
| 410 | - }else { | |
| 411 | - layer.msg('生成路线失败!'); | |
| 412 | - } | |
| 413 | - }); | |
| 414 | - } | |
| 415 | -}); | |
| 1 | +<!-- 手动添加站点 --> | |
| 2 | +<div class="modal fade" id="edit_route_mobal" tabindex="-1" role="basic" | |
| 3 | + aria-hidden="true"> | |
| 4 | + | |
| 5 | + <div class="modal-dialog"> | |
| 6 | + | |
| 7 | + <div class="modal-content" > | |
| 8 | + | |
| 9 | + <div class="modal-header"> | |
| 10 | + <button type="button" class="close" data-dismiss="modal" | |
| 11 | + aria-hidden="true"></button> | |
| 12 | + <h4 class="modal-title">生成路线(站点和路段)</h4> | |
| 13 | + </div> | |
| 14 | + | |
| 15 | + <div class="modal-body"> | |
| 16 | + | |
| 17 | + <form class="form-horizontal" role="form" | |
| 18 | + id="save_route_template_form" action="" method=""> | |
| 19 | + | |
| 20 | + <div class="alert alert-danger display-hide"> | |
| 21 | + <button class="close" data-close="alert"></button> | |
| 22 | + 您的输入有误,请检查下面的输入项 | |
| 23 | + </div> | |
| 24 | + | |
| 25 | + <!-- 站点名称 --> | |
| 26 | + <div class="form-body"> | |
| 27 | + | |
| 28 | + <div class="form-group"> | |
| 29 | + <label class="control-label col-md-2"> <span | |
| 30 | + class="required"> * </span> 坐标: | |
| 31 | + </label> | |
| 32 | + <div class="col-md-10"> | |
| 33 | + <textarea class="form-control" rows="12" name="points" | |
| 34 | + id="pointInput" placeholder="坐标点"></textarea> | |
| 35 | + </div> | |
| 36 | + </div> | |
| 37 | + </div> | |
| 38 | + <div class="form-group"> | |
| 39 | + <label class="col-md-3 control-label">选择文本类型:</label> | |
| 40 | + <div class="col-md-3"> | |
| 41 | + <div class="icheck-list"> | |
| 42 | + <label> <input type="radio" class="icheck" | |
| 43 | + name="typeCheck" value='0' checked> txt | |
| 44 | + </label> <label> <input type="radio" class="icheck" | |
| 45 | + name="typeCheck" value='1'> xml | |
| 46 | + </label> | |
| 47 | + </div> | |
| 48 | + </div> | |
| 49 | + <label class="col-md-3 control-label">选择方向:</label> | |
| 50 | + <div class="col-md-3"> | |
| 51 | + <div class="icheck-list"> | |
| 52 | + <label> <input type="radio" class="icheck" | |
| 53 | + name="dirCheck" value='0' checked> 上行 | |
| 54 | + </label> <label> <input type="radio" class="icheck" | |
| 55 | + name="dirCheck" value='1'> 下行 | |
| 56 | + </label> | |
| 57 | + </div> | |
| 58 | + </div> | |
| 59 | + </div> | |
| 60 | + <div class="form-group"> | |
| 61 | + <div class="alert alert-info font-blue-chambray" | |
| 62 | + style="background-color: #2C3E50"> | |
| 63 | + <h5 class="block"> | |
| 64 | + <span class="help-block" style="color: #1bbc9b;"> * | |
| 65 | + 坐标生成路线规划说明: </span> | |
| 66 | + </h5> | |
| 67 | + <p> | |
| 68 | + | |
| 69 | + <span class="help-block" style="color: #1bbc9b;"> | |
| 70 | + 1.txt格式 | |
| 71 | + <br> 请在文本域中按顺序依次输坐标点,每行中的数据之间用【Tab】键隔开(如果是站点,请将在坐标后面加 stop;没有 | |
| 72 | + stop默认是路段点,连续带stop的坐标认为是同一个站点),每输入完一个坐标时请按回车键【Enter】换行. 例如: | |
| 73 | + <br>121.511870 31.180638 043703.000 | |
| 74 | + <br>121.511870 31.180643 043705.000 | |
| 75 | + <br>121.511870 31.180648 043706.000 Stop | |
| 76 | + <br>121.511872 31.180653 043707.000 | |
| 77 | + </span> | |
| 78 | + </p> | |
| 79 | + <p> | |
| 80 | + | |
| 81 | + <span class="help-block" style="color: #1bbc9b;"> | |
| 82 | + 2.xml格式 | |
| 83 | + <br>用gps生成工具,生成的kml文件里的数据 | |
| 84 | + </span> | |
| 85 | + </p> | |
| 86 | + </div> | |
| 87 | + </div> | |
| 88 | + </form> | |
| 89 | + </div> | |
| 90 | + <div class="modal-footer"> | |
| 91 | + <button type="button" class="btn default" data-dismiss="modal" | |
| 92 | + id="addMobalHiden">取消</button> | |
| 93 | +<!-- <button type="button" class="btn btn-primary hidden" id="referenceCurrentVersion">引用当前版本</button> --> | |
| 94 | + <button type="button" class="btn btn-primary" id="templateSaveData">提交数据</button> | |
| 95 | + </div> | |
| 96 | + </div> | |
| 97 | + </div> | |
| 98 | +</div> | |
| 99 | +<script type="text/javascript"> | |
| 100 | + | |
| 101 | +$('#edit_route_mobal').on('editRouteMobal.show', function(e,transGPS,editRoute,map,dra,ajaxd,fun){ | |
| 102 | + // 延迟加载显示mobal | |
| 103 | + setTimeout(function(){$('#edit_route_mobal').modal({show : true,backdrop: 'static', keyboard: false});},200); | |
| 104 | + // 获取表单元素 | |
| 105 | + var form = $('#save_route_template_form'); | |
| 106 | + | |
| 107 | + // 获取错误提示信息元素 | |
| 108 | + var error = $('.alert-danger', form); | |
| 109 | + | |
| 110 | + // 提交数据点击事件 | |
| 111 | + $('.modal-footer #templateSaveData').on('click',function() { | |
| 112 | + form.submit(); | |
| 113 | + }); | |
| 114 | + | |
| 115 | + | |
| 116 | + //从xml中获取节点内容 | |
| 117 | + function getXmlNode(str){ | |
| 118 | + //创建文档对象 | |
| 119 | + var parser=new DOMParser(); | |
| 120 | + var xmlDoc=parser.parseFromString(str,"text/xml"); | |
| 121 | + | |
| 122 | + //提取数据 | |
| 123 | + var countrys = xmlDoc.getElementsByTagName('coordinates'); | |
| 124 | + //var countrys = xmlDoc.getElementsByTagName('DataSource'); | |
| 125 | + | |
| 126 | + var arr = []; | |
| 127 | + | |
| 128 | + for (var i = 0; i < countrys.length; i++) { | |
| 129 | + arr.push(countrys[i].textContent); | |
| 130 | + }; | |
| 131 | + // console.log(arr); | |
| 132 | + return arr; | |
| 133 | + | |
| 134 | + } | |
| 135 | + | |
| 136 | + // xml方式上传是,处理转成txt格式的方法 | |
| 137 | + var getXmlSection = function (xml) { | |
| 138 | + // var xml = $("#xmlText").val(); | |
| 139 | + var stationPointList = getXmlNode(xml); | |
| 140 | + var sListSize = stationPointList.length; | |
| 141 | + var sectionPointListStr = stationPointList[stationPointList.length - 1]; | |
| 142 | + var sectionPointList = sectionPointListStr.split(" "); | |
| 143 | + | |
| 144 | + // var sectionStr = ""; | |
| 145 | + var sections = []; | |
| 146 | + var mapping = nearestSectionPoint(stationPointList, sectionPointList); | |
| 147 | + for (var i = 0; i < sectionPointList.length; i++) { | |
| 148 | + var pointStr = sectionPointList[i], | |
| 149 | + point = pointStr.split(","); | |
| 150 | + | |
| 151 | + if (mapping[pointStr]) { | |
| 152 | + sections.push(point[0] + " " + point[1] + " " + point[2] + " Stop"); | |
| 153 | + } else { | |
| 154 | + sections.push(point[0] + " " + point[1] + " " + point[2]); | |
| 155 | + } | |
| 156 | + } | |
| 157 | + return sections; | |
| 158 | + }; | |
| 159 | + | |
| 160 | + var nearestSectionPoint = function (stationPointList, sectionPointList) { | |
| 161 | + var mapping = {}; | |
| 162 | + for (var i = 0;i < stationPointList.length - 1;i++) { | |
| 163 | + var minDistance = 999999999, stationPoint = stationPointList[i].split(","), pointStr; | |
| 164 | + for (var j = 0;j < sectionPointList.length;j++) { | |
| 165 | + var sectionPointStr = sectionPointList[j], sectionPoint = sectionPointStr.split(","); | |
| 166 | + var distance = Math.sqrt(Math.pow(parseFloat(stationPoint[0]) - parseFloat(sectionPoint[0]), 2) + Math.pow(parseFloat(stationPoint[1]) - parseFloat(sectionPoint[1]), 2)); | |
| 167 | + if (distance < minDistance) { | |
| 168 | + minDistance = distance; | |
| 169 | + pointStr = sectionPointStr; | |
| 170 | + } | |
| 171 | + } | |
| 172 | + mapping[pointStr] = stationPointList[i]; | |
| 173 | + } | |
| 174 | + | |
| 175 | + return mapping; | |
| 176 | + } | |
| 177 | + | |
| 178 | + | |
| 179 | + // 表单验证 | |
| 180 | + form.validate({ | |
| 181 | + | |
| 182 | + errorElement : 'span', | |
| 183 | + | |
| 184 | + errorClass : 'help-block help-block-error', | |
| 185 | + | |
| 186 | + focusInvalid : false, | |
| 187 | + | |
| 188 | + rules : { | |
| 189 | + | |
| 190 | + 'points' : { | |
| 191 | + | |
| 192 | + required : true, | |
| 193 | + | |
| 194 | + } | |
| 195 | + | |
| 196 | + }, | |
| 197 | + | |
| 198 | + invalidHandler : function(event, validator) { | |
| 199 | + | |
| 200 | + error.show(); | |
| 201 | + | |
| 202 | + App.scrollTo(error, -200); | |
| 203 | + | |
| 204 | + }, | |
| 205 | + | |
| 206 | + highlight : function(element) { | |
| 207 | + | |
| 208 | + $(element).closest('.form-group').addClass('has-error'); | |
| 209 | + | |
| 210 | + }, | |
| 211 | + | |
| 212 | + unhighlight : function(element) { | |
| 213 | + | |
| 214 | + $(element).closest('.form-group').removeClass('has-error'); | |
| 215 | + | |
| 216 | + }, | |
| 217 | + | |
| 218 | + success : function(label) { | |
| 219 | + | |
| 220 | + label.closest('.form-group').removeClass('has-error'); | |
| 221 | + | |
| 222 | + }, | |
| 223 | + submitHandler : function(f) { | |
| 224 | + // 隐藏弹出层 | |
| 225 | + $('#edit_route_mobal').modal('hide'); | |
| 226 | + // 获取线路对象 | |
| 227 | + var line = editRoute.getLineObj(); | |
| 228 | + // 原坐标类型 | |
| 229 | + var baseRes = "WGS84"; | |
| 230 | + // 定义线路名称 | |
| 231 | + var lineNameV = $('.portlet-title .caption').text(); | |
| 232 | + var dirStr = ''; | |
| 233 | + // 路线方向 | |
| 234 | + var directionData = $("input[name='dirCheck']:checked").val(); | |
| 235 | + /** | |
| 236 | + * 添加类型0(txt)/1(xml) | |
| 237 | + * txt方式路段需要30个点取一个 | |
| 238 | + * xml路段取所有点 | |
| 239 | + */ | |
| 240 | + var type = $("input[name='typeCheck']:checked").val(); | |
| 241 | + editRoute.setLineDir(directionData); | |
| 242 | + // 设置线路对象生成方式 | |
| 243 | + editRoute.setLineGenerationType('uploadGPS'); | |
| 244 | + // 弹出正在加载层 | |
| 245 | + var i = layer.load(2); | |
| 246 | + // 表单序列化 | |
| 247 | + var paramsForm = form.serializeJSON(); | |
| 248 | + var array = []; | |
| 249 | + if(type == 1){ | |
| 250 | + array = getXmlSection(paramsForm.points); | |
| 251 | + } else { | |
| 252 | + // 切割坐标点 | |
| 253 | + array = paramsForm.points.split('\r\n'); | |
| 254 | + } | |
| 255 | + // 把坐标点转换为站点或路段 | |
| 256 | + var arrayFormat = inputStationValueFormat(array); | |
| 257 | + var stationList = arrayFormat.stationList; | |
| 258 | + var sectionListTemp = arrayFormat.sectionList; | |
| 259 | + var sectionList = []; | |
| 260 | + // 隔30个取一个点(相当于30s) | |
| 261 | + var typeNum = type == 0 ? 30:1; | |
| 262 | + for(var i = 0; i*typeNum < sectionListTemp.length; i++) { | |
| 263 | + sectionList[i] = sectionListTemp[i*typeNum]; | |
| 264 | + } | |
| 265 | + sectionList[sectionList.length] = sectionListTemp[sectionListTemp.length-1]; | |
| 266 | + | |
| 267 | + var sectionListFinal = []; | |
| 268 | + sectionListFinal.push({sectionName : lineNameV, points : sectionList}); | |
| 269 | + // 根据站点名称获取百度坐标 | |
| 270 | + map.stationsPointsToLibraryPoint(stationList,function(resultJson) { | |
| 271 | + // 根据坐标点获取两点之间的时间与距离 | |
| 272 | + map.getDistanceAndDuration(resultJson,function(stationdataList) { | |
| 273 | + // 设置第一个站的距离 | |
| 274 | + stationdataList[0].distance = ''; | |
| 275 | + // 设置第一个站的时间 | |
| 276 | + stationdataList[0].duration = ''; | |
| 277 | + // 定义站点信息JSON字符串 | |
| 278 | + var stationJSON = JSON.stringify(stationdataList); | |
| 279 | + // 参数集合 | |
| 280 | + var params = {}; | |
| 281 | + params.baseRes = baseRes; | |
| 282 | + // 是否添加该站点 | |
| 283 | + | |
| 284 | + // 站点信息JSON字符串 | |
| 285 | + params.stationJSON = stationJSON; | |
| 286 | + // 线路ID | |
| 287 | + params.lineId = line.id; | |
| 288 | + // 方向 | |
| 289 | + params.directions = directionData; | |
| 290 | + // 原始坐标类型 | |
| 291 | + params.dbType = 'b'; | |
| 292 | + // 圆形半径 | |
| 293 | + params.radius = '80'; | |
| 294 | + // 限速 | |
| 295 | + params.speedLimit = '60'; | |
| 296 | + // 图形类型(r:圆形;p:多边形) | |
| 297 | + params.shapesType = 'r'; | |
| 298 | + // destroy:是否撤销 | |
| 299 | + params.destroy = '0'; | |
| 300 | + // versions:版本号 | |
| 301 | + params.versions = '1'; | |
| 302 | + // 定义路段信息字符串 | |
| 303 | + var sectionJSON = JSON.stringify(sectionListFinal); | |
| 304 | + // 路段信息JSON字符串 | |
| 305 | + params.sectionJSON = sectionJSON; | |
| 306 | + addSave(params,line.id,directionData); | |
| 307 | + }); | |
| 308 | + | |
| 309 | + }); | |
| 310 | + }, | |
| 311 | + | |
| 312 | + }); | |
| 313 | + | |
| 314 | + function inputStationValueFormat(paramsStationsArray) { | |
| 315 | + var stationList = []; | |
| 316 | + var sectionList = []; | |
| 317 | + var routeList = {"stationList":stationList, "sectionList":sectionList}; | |
| 318 | + var len = paramsStationsArray.length; | |
| 319 | + // 处理相同站点判断值 | |
| 320 | + var isPush = true; | |
| 321 | + for(var k =0;k<len;k++) { | |
| 322 | + if(paramsStationsArray[k]=="") | |
| 323 | + continue; | |
| 324 | + var tempStr = paramsStationsArray[k].split('\t'); | |
| 325 | + var tempPoint = transGpsLoc(tempStr[0],tempStr[1]); | |
| 326 | + var point = {lng:tempPoint.lng, lat:tempPoint.lat}; | |
| 327 | + if(tempStr.length < 4){ | |
| 328 | + sectionList[k] = point; | |
| 329 | + isPush = true; | |
| 330 | + }else { | |
| 331 | + if(isPush) { | |
| 332 | + sectionList[k] = point; | |
| 333 | + stationList.push({name:tempStr[3], potion:{lng:tempPoint.lng, lat:tempPoint.lat} , wgs:{x:tempStr[0], y:tempStr[1]}}); | |
| 334 | + } | |
| 335 | + isPush = false; | |
| 336 | + } | |
| 337 | + } | |
| 338 | + for(var i = 0 ;i<sectionList.length;i++) { | |
| 339 | + if(sectionList[i] == "" || isNaN(sectionList[i].lng) || typeof(sectionList[i]) == "undefined" || sectionList[i] == null) { | |
| 340 | + sectionList.splice(i,1);//删除数组中下表i-i+1之间的值 | |
| 341 | + i= i-1; | |
| 342 | + } | |
| 343 | + | |
| 344 | + } | |
| 345 | + return routeList; | |
| 346 | + } | |
| 347 | + | |
| 348 | + function transGpsLoc(lng,lat) { | |
| 349 | + var bdLoc = transGPS.locationMake(lng, lat); | |
| 350 | + var gcjLoc = transGPS.transformFromWGSToGCJ(bdLoc); | |
| 351 | + var bdEn = transGPS.bd_encrypt(gcjLoc); | |
| 352 | + return bdEn; | |
| 353 | + } | |
| 354 | + | |
| 355 | + /** 引用当前版本站点和走向*/ | |
| 356 | + /* $("#referenceCurrentVersion").on('click',function() { | |
| 357 | + // 获取线路对象 | |
| 358 | + var line = editRoute.getLineObj(); | |
| 359 | + // 路线方向 | |
| 360 | + var direction = $("input[name='dirCheck']:checked").val(); | |
| 361 | + // 设置线路对象方向 | |
| 362 | + editRoute.setLineDir(direction); | |
| 363 | + // 设置线路对象生成方式 | |
| 364 | + editRoute.setLineGenerationType('cite'); | |
| 365 | + $.post("/station/referenceCurrentVersion",{'lineId' : line.id , 'directions' : direction},function(rd){ | |
| 366 | + // 隐藏弹出层 | |
| 367 | + $('#edit_route_mobal').modal('hide'); | |
| 368 | + // 关闭弹出层 | |
| 369 | + layer.closeAll(); | |
| 370 | + if(rd.status='SUCCESS') { | |
| 371 | + // 清除地图覆盖物 | |
| 372 | + map.clearMarkAndOverlays(); | |
| 373 | + // 查询路段信息 | |
| 374 | + var params = {}; | |
| 375 | + params.lineId=line.id; | |
| 376 | + params.dir = direction; | |
| 377 | + // 查询路段信息 | |
| 378 | + $get('/sectionroute/findCacheSection',params,function(data) { | |
| 379 | + // 在地图上画出线路走向 | |
| 380 | + fun.linePanlThree(line.id,data,direction); | |
| 381 | + }); | |
| 382 | + $('#route_show').removeClass('hidden'); | |
| 383 | + $('#generationRoute_div').addClass('hidden'); | |
| 384 | + // 刷新路段列表 | |
| 385 | + $('#section').click(); | |
| 386 | + layer.msg('引用当前版本成功!'); | |
| 387 | + }else { | |
| 388 | + layer.msg('引用当前版本失败,请重新引用或选择其他方式!'); | |
| 389 | + } | |
| 390 | + }) | |
| 391 | + }); */ | |
| 392 | + | |
| 393 | + function addSave(params,lineid,directionData) { | |
| 394 | + // 保存 | |
| 395 | + $post("/station/cacheSave",params,function(rd) { | |
| 396 | + // 关闭弹出层 | |
| 397 | + layer.closeAll(); | |
| 398 | + if(rd.status='SUCCESS') { | |
| 399 | + var stationD = rd.stationData,isNullStr = ''; | |
| 400 | + for(var t = 0 ;t<stationD.length;t++) { | |
| 401 | + if(stationD[t].potion.lat =='' || stationD[t].potion.lat ==null || | |
| 402 | + stationD[t].potion.lng =='' || stationD[t].potion.lng ==null) | |
| 403 | + isNullStr = isNullStr + stationD[t].name + ' , '; | |
| 404 | + } | |
| 405 | + if(isNullStr!='') { | |
| 406 | + layer.open({ | |
| 407 | + title: '提示', | |
| 408 | + content:'【' + isNullStr + '】' + '地址系统无法解析!,请手动调整位置!' | |
| 409 | + }); | |
| 410 | + } | |
| 411 | + // 清除地图覆盖物 | |
| 412 | + map.clearMarkAndOverlays(); | |
| 413 | + var params = {}; | |
| 414 | + params.lineId = lineid; | |
| 415 | + params.dir = directionData; | |
| 416 | + // 查询路段信息 | |
| 417 | + $get('/sectionroute/findCacheSection',params,function(data) { | |
| 418 | + // 在地图上画出线路走向 | |
| 419 | + fun.linePanlThree(lineid,data,directionData); | |
| 420 | + }); | |
| 421 | + $('#route_show').removeClass('hidden'); | |
| 422 | + $('#generationRoute_div').addClass('hidden'); | |
| 423 | + // 刷新路段列表 | |
| 424 | + $('#section').click(); | |
| 425 | + layer.open({title: '友情提示' | |
| 426 | + ,content: '生成路线成功,生成的线路可能会有误差。请先单击路段,拖动编辑、然后双击保存!'}); | |
| 427 | + }else { | |
| 428 | + layer.msg('生成路线失败!'); | |
| 429 | + } | |
| 430 | + }); | |
| 431 | + } | |
| 432 | +}); | |
| 416 | 433 | </script> |
| 417 | 434 | \ No newline at end of file | ... | ... |
src/main/resources/static/pages/oil/list_ph.html
| ... | ... | @@ -652,6 +652,7 @@ onkeyup="this.value=this.value.replace(/[^(\d||/.)]/g,'').replace('.','$#$').rep |
| 652 | 652 | layer.msg('只能操作一天内数据.'); |
| 653 | 653 | }else{ |
| 654 | 654 | var i = layer.load(2); |
| 655 | + params["fgsdm_like"] = ''; | |
| 655 | 656 | $get('/ylb/obtain', params, function () { |
| 656 | 657 | layer.close(i); |
| 657 | 658 | jsDoQuery(params, true); | ... | ... |
src/main/resources/static/pages/oil/modifyRights.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><span class="active">编辑权限</span></li> | |
| 9 | +</ul> | |
| 10 | + | |
| 11 | +<div class="portlet light bordered"> | |
| 12 | + <div class="portlet-title"> | |
| 13 | + <div class="caption"> | |
| 14 | + <i class="icon-equalizer font-red-sunglo"></i> <span | |
| 15 | + class="caption-subject font-red-sunglo bold uppercase"></span> | |
| 16 | + </div> | |
| 17 | + </div> | |
| 18 | + <div class="portlet-body form"> | |
| 19 | + <form action="/addYlb" class="form-horizontal" id="ylb_add_form" > | |
| 20 | + | |
| 21 | + <div class="alert alert-danger display-hide"> | |
| 22 | + <button class="close" data-close="alert"></button> | |
| 23 | + 您的输入有误,请检查下面的输入项 | |
| 24 | + </div> | |
| 25 | + <input type="hidden" value="0" name="yhlx" /> | |
| 26 | + <div class="form-body"> | |
| 27 | + <div class="form-group"> | |
| 28 | + <label class="col-md-3 control-label">修改历史油/电权限:</label> | |
| 29 | + <div class="col-md-2"> | |
| 30 | + <input type="text" class="form-control" name="modify_rights" id="modify_rights" readonly="readonly"> | |
| 31 | + </div> | |
| 32 | + <button type="button" class="btn green" id="change" >修改</button> | |
| 33 | + </div> | |
| 34 | + </div> | |
| 35 | + </form> | |
| 36 | + <!-- END FORM--> | |
| 37 | + </div> | |
| 38 | +</div> | |
| 39 | +<script> | |
| 40 | +(function(){ | |
| 41 | + | |
| 42 | + function getModifyRights(){ | |
| 43 | + $get('/ylb/getModifyRights',"",function(result){ | |
| 44 | + $("#modify_rights").val(result.text); | |
| 45 | + }); | |
| 46 | + } | |
| 47 | + getModifyRights(); | |
| 48 | + | |
| 49 | + $("#change").on('click', function () { | |
| 50 | + var par={}; | |
| 51 | + par["modify_rights"] = $("#modify_rights").val(); | |
| 52 | + $get('/ylb/modifyRightsChange',par,function(result){ | |
| 53 | + layer.msg(result.text); | |
| 54 | + getModifyRights(); | |
| 55 | + }); | |
| 56 | + }); | |
| 57 | + | |
| 58 | +})(); | |
| 59 | +</script> | |
| 0 | 60 | \ No newline at end of file | ... | ... |
src/main/resources/static/real_control_v2/main.html
| ... | ... | @@ -110,12 +110,12 @@ |
| 110 | 110 | </script> |
| 111 | 111 | |
| 112 | 112 | <!-- 地图相关 --> |
| 113 | -<script src="http://api.map.baidu.com/api?v=2.0&ak=IGGrr4UjwIYzatoCRFKEL8sT"></script> | |
| 114 | -<script src="http://api.map.baidu.com/library/TrafficControl/1.4/src/TrafficControl_min.js"></script> | |
| 113 | +<script src="//api.map.baidu.com/api?v=2.0&ak=IGGrr4UjwIYzatoCRFKEL8sT"></script> | |
| 114 | +<script src="//api.map.baidu.com/library/TrafficControl/1.4/src/TrafficControl_min.js"></script> | |
| 115 | 115 | <script src="/assets/js/baidu//MarkerClusterer.js" merge="plugins"></script> |
| 116 | 116 | <script src="/assets/js/TransGPS.js" merge="plugins"></script> |
| 117 | 117 | <!-- 高德 --> |
| 118 | -<script src="http://webapi.amap.com/maps?v=1.3&key=16cb1c5043847e09ef9edafdd77befda"></script> | |
| 118 | +<script src="//webapi.amap.com/maps?v=1.3&key=16cb1c5043847e09ef9edafdd77befda"></script> | |
| 119 | 119 | <!-- jquery --> |
| 120 | 120 | <script src="/real_control_v2/assets/js/jquery.min.js"></script> |
| 121 | 121 | <!-- jquery actual --> |
| ... | ... | @@ -266,7 +266,7 @@ |
| 266 | 266 | </div> |
| 267 | 267 | </div> |
| 268 | 268 | <div class="uk-form-row"> |
| 269 | - <label class="uk-form-label" ">分机号:</label> | |
| 269 | + <label class="uk-form-label">分机号:</label> | |
| 270 | 270 | <div class="uk-form-controls"> |
| 271 | 271 | <input type="text" name="dn" value="" > |
| 272 | 272 | </div> | ... | ... |