Authored by zhichao

Merge branch 'master-500-dev' of http://192.168.1.136:82/monitor_v3/hg-monitor-w…

…eb into master-500-dev-lzc
1 ${AnsiColor.BRIGHT_YELLOW} 1 ${AnsiColor.BRIGHT_YELLOW}
2 2
3 -  
4 ${application.title} ${application.version} Base On Spring Boot ${spring-boot.version} 3 ${application.title} ${application.version} Base On Spring Boot ${spring-boot.version}
5 4
  5 +当前版本:5.2.0 访问地址:http://localhost:${server.port}/
6 ---------------------------------------------------------------------------------------------------------- 6 ----------------------------------------------------------------------------------------------------------
7 - \\\ /// .-. \\\ ///wW Ww(o)__(o) .-. )) (O)) ((O) _ 2022  
8 - ((O) (O)) c(O_O)c ((O)(O))(O)(O)(__ __)c(O_O)c (Oo)-. || || wWw /||_  
9 - | \ / | ,'.---.`, | \ || (..) ( ) ,'.---.`, | (_)) || /\ || (O)_ /`_)  
10 - ||\\//||/ /|_|_|\ \||\\|| || )( / /|_|_|\ \ | .' ||//\\|| .' __)| `.  
11 - || \/ ||| \_____/ ||| \ | _||_ ( )| \_____/ | )|\\ / / \ \( _) | (_))  
12 - || ||'. `---' .`|| || (_/\_) )/ '. `---' .`(/ \) ( / \ )`.__) (.'-'  
13 - (_/ \_) `-...-' (_/ \_) ( `-...-' ) ) ( )  
14 - ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______ ______  
15 -|______|______|______|______|______|______|______|______|______|______|______|______|______|______|______|  
16 -  
17 -  
18 -  
19 -  
20 -  
@@ -393,7 +393,7 @@ layui.define(['laytpl', 'admin', 'form', 'table', 'echarts', 'sessions', 'xmSele @@ -393,7 +393,7 @@ layui.define(['laytpl', 'admin', 'form', 'table', 'echarts', 'sessions', 'xmSele
393 var resStyle = obj.alarmEleMatchStyle(ar.flag, ar.kpiId); 393 var resStyle = obj.alarmEleMatchStyle(ar.flag, ar.kpiId);
394 span += ' <span ' + menuId + ' style="text-align:left;width:40%">' + ar.kpiName + '</span>' + 394 span += ' <span ' + menuId + ' style="text-align:left;width:40%">' + ar.kpiName + '</span>' +
395 '<span title="' + titleStr + '" style="width:60%;overflow: hidden;text-overflow: ellipsis;white-space: nowrap;' + resStyle + '">' 395 '<span title="' + titleStr + '" style="width:60%;overflow: hidden;text-overflow: ellipsis;white-space: nowrap;' + resStyle + '">'
396 - + $html + valueStr + '</span>'; 396 + + $html + valueStr +(ar.unit?ar.unit:'')+ '</span>';
397 //补充空白区域 397 //补充空白区域
398 if (v.length < cols) { 398 if (v.length < cols) {
399 var l = cols - v.length; 399 var l = cols - v.length;
@@ -91,24 +91,27 @@ layui.define(['laypage', 'commonDetail', 'common', 'element', 'admin'], function @@ -91,24 +91,27 @@ layui.define(['laypage', 'commonDetail', 'common', 'element', 'admin'], function
91 } 91 }
92 }) 92 })
93 for (let nodeInfo of nodeInfoList) { 93 for (let nodeInfo of nodeInfoList) {
  94 + // lsq 详情页节电池样式修改 2022-08-08
94 htmlStr += `<div class="detail-loadbalancing-vs" data-flag="${nodeInfo.flag}"> 95 htmlStr += `<div class="detail-loadbalancing-vs" data-flag="${nodeInfo.flag}">
95 <div class="vs-title"> 96 <div class="vs-title">
96 <p>${nodeInfo.nodeName}</p> 97 <p>${nodeInfo.nodeName}</p>
97 </div> 98 </div>
98 - <div class="vs-icon-div ${nodeInfo.healthStatus == 'normal' ? 'vs-icon-up' : 'vs-icon-down'}">  
99 - <div class="vs-icon"></div> 99 + <div class="vs-flex">
  100 + <div class="vs-icon-div ${nodeInfo.healthStatus == 'normal' ? 'vs-icon-up' : 'vs-icon-down'}">
  101 + <div class="vs-icon"></div>
  102 + </div>
  103 + <ul class="vs-info">
  104 + <li>
  105 + ${nodeInfo.configStatus == 'enable' ? '<i class="iconfont icon-size good">\ue659</i> 已启用' : '<i class="iconfont icon-size serious">\ue668</i> 未启用'}
  106 + </li>
  107 + <li>
  108 + 当前连接数: ${nodeInfo.currentConnections}
  109 + </li>
  110 + <li>
  111 + 新增连接数: ${nodeInfo.newConnections}
  112 + </li>
  113 + </ul>
100 </div> 114 </div>
101 - <ul class="vs-info">  
102 - <li>  
103 - ${nodeInfo.configStatus == 'enable' ? '<i class="iconfont icon-size good">\ue659</i> 已启用' : '<i class="iconfont icon-size serious">\ue668</i> 未启用'}  
104 - </li>  
105 - <li>  
106 - 当前连接数: ${nodeInfo.currentConnections}  
107 - </li>  
108 - <li>  
109 - 新增连接数: ${nodeInfo.newConnections}  
110 - </li>  
111 - </ul>  
112 </div>` 115 </div>`
113 } 116 }
114 $vsDiv.html(htmlStr) 117 $vsDiv.html(htmlStr)
@@ -168,27 +171,30 @@ layui.define(['laypage', 'commonDetail', 'common', 'element', 'admin'], function @@ -168,27 +171,30 @@ layui.define(['laypage', 'commonDetail', 'common', 'element', 'admin'], function
168 } 171 }
169 }) 172 })
170 for (let nodeInfo of nodeInfoList) { 173 for (let nodeInfo of nodeInfoList) {
  174 + // lsq 详情页节电池样式修改 2022-08-08
171 htmlStr += `<div class="detail-loadbalancing-vs" data-flag="${nodeInfo.flag}"> 175 htmlStr += `<div class="detail-loadbalancing-vs" data-flag="${nodeInfo.flag}">
172 <div class="vs-title"> 176 <div class="vs-title">
173 <p>${nodeInfo.nodeName}</p> 177 <p>${nodeInfo.nodeName}</p>
174 </div> 178 </div>
175 - <div class="node-icon-div ${nodeInfo.healthStatus == 'normal' ? 'vs-icon-up' : 'vs-icon-down'}">  
176 - <div class="node-icon"></div> 179 + <div class="vs-flex">
  180 + <div class="node-icon-div ${nodeInfo.healthStatus == 'normal' ? 'vs-icon-up' : 'vs-icon-down'}">
  181 + <div class="node-icon"></div>
  182 + </div>
  183 + <ul class="vs-info">
  184 + <li>
  185 + ${nodeInfo.configStatus == 'enable' ? '<i class="iconfont icon-size good">\ue659</i> 已启用' : '<i class="iconfont icon-size serious">\ue668</i> 未启用'}
  186 + </li>
  187 + <li>
  188 + 当前连接数: ${nodeInfo.currentConnections}
  189 + </li>
  190 + <li>
  191 + 新增连接数: ${nodeInfo.newConnections}
  192 + </li>
  193 + <li>
  194 + ${nodeInfo.ipAddr}:${nodeInfo.port}
  195 + </li>
  196 + </ul>
177 </div> 197 </div>
178 - <ul class="vs-info">  
179 - <li>  
180 - ${nodeInfo.configStatus == 'enable' ? '<i class="iconfont icon-size good">\ue659</i> 已启用' : '<i class="iconfont icon-size serious">\ue668</i> 未启用'}  
181 - </li>  
182 - <li>  
183 - 当前连接数: ${nodeInfo.currentConnections}  
184 - </li>  
185 - <li>  
186 - 新增连接数: ${nodeInfo.newConnections}  
187 - </li>  
188 - <li>  
189 - ${nodeInfo.ipAddr}:${nodeInfo.port}  
190 - </li>  
191 - </ul>  
192 </div>` 198 </div>`
193 } 199 }
194 $vsDiv.html(htmlStr) 200 $vsDiv.html(htmlStr)
@@ -537,16 +537,7 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'xmSelect @@ -537,16 +537,7 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'xmSelect
537 resType: resType, 537 resType: resType,
538 isSend: $('#notice_search_isSend').val() 538 isSend: $('#notice_search_isSend').val()
539 }; 539 };
540 - var typeName = new Map();  
541 - typeName.set("10", "告警通知");  
542 - typeName.set("11", "告警消除");  
543 - //2021-10-15 添加合并通知 XuHaoJie  
544 - typeName.set("13", "合并通知");  
545 - typeName.set("20", "巡检报表通知");  
546 - typeName.set("30", "系统通知");  
547 - typeName.set("40", "工单通知");  
548 - typeName.set("99", "测试通知");  
549 - typeName.set("0", "测试通知"); 540 + //lsq 分类分组统计的x轴标签显示undefined修改 2022-08-08
550 $.ajax({ 541 $.ajax({
551 url: `${common.domainName}/api-web/notice/groupByType`, 542 url: `${common.domainName}/api-web/notice/groupByType`,
552 method: 'GET', 543 method: 'GET',
@@ -556,7 +547,8 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'xmSelect @@ -556,7 +547,8 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'xmSelect
556 var yData = []; 547 var yData = [];
557 if (res && res.map) { 548 if (res && res.map) {
558 $.each(res.map.typeList, function (i, v) { 549 $.each(res.map.typeList, function (i, v) {
559 - xData.push(typeName.get(v)) 550 + //lsq 分类分组统计的x轴标签显示undefined修改 2022-08-08
  551 + xData.push(v)
560 }) 552 })
561 yData = res.map.countList; 553 yData = res.map.countList;
562 } 554 }
1 -layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTable', 'cron'], function (exports) { 1 +
  2 +layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTable','cron'], function (exports) {
2 var $ = layui.$; 3 var $ = layui.$;
3 var form = layui.form; 4 var form = layui.form;
4 var layer = layui.layer; 5 var layer = layui.layer;
@@ -36,7 +37,27 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl @@ -36,7 +37,27 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl
36 noticeTimely.sendState = noticeTimely.sendState == 1 ? 1 : 0; 37 noticeTimely.sendState = noticeTimely.sendState == 1 ? 1 : 0;
37 noticeTimely.state = noticeTimely.state == 2 ? 1 : 0; 38 noticeTimely.state = noticeTimely.state == 2 ? 1 : 0;
38 form.val('form-noticeTimely-add', noticeTimely); 39 form.val('form-noticeTimely-add', noticeTimely);
39 - bloatedSite(noticeTimely.site); 40 + $('[name="templates"]').val(noticeTimely.templates);
  41 +
  42 + var setting = noticeTimely.msgSetting;
  43 + if(setting){
  44 + try{
  45 + // "[{\"fieldName\":\"noticeType\",\"condition\":\"2\",\"conditionVal\":\"2\",\"msgLevel\":\"3\"}]"
  46 + var arr = JSON.parse(setting);
  47 + if(arr){
  48 + $(arr).each(function (i,v){
  49 + addCondition(v);
  50 + })
  51 + }
  52 +
  53 + }catch (e) {
  54 +
  55 + }
  56 +
  57 + }
  58 +
  59 +
  60 + //bloatedSite(noticeTimely.site);
40 bloatedParameter(noticeTimely); 61 bloatedParameter(noticeTimely);
41 if (response.data) { 62 if (response.data) {
42 $.each(response.data, function (i, v) { 63 $.each(response.data, function (i, v) {
@@ -45,13 +66,13 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl @@ -45,13 +66,13 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl
45 } 66 }
46 } 67 }
47 }); 68 });
48 - } else { 69 + }else{
49 //状态是否为开启 70 //状态是否为开启
50 - $("#switch_noticeTimely_state").attr("checked", "true"); 71 + $("#switch_noticeTimely_state").attr("checked","true");
51 } 72 }
52 form.render(); 73 form.render();
53 //corn表达式 74 //corn表达式
54 - $("#show_corn_info_frequency").on("click", function () { 75 + $("#show_corn_info_frequency").on("click",function (){
55 layer.open({ 76 layer.open({
56 type: 1 77 type: 1
57 , title: 'Cron表达式示例' 78 , title: 'Cron表达式示例'
@@ -71,72 +92,117 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl @@ -71,72 +92,117 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl
71 }, 92 },
72 }); 93 });
73 //响应声音事件 94 //响应声音事件
74 - form.on('select(noticeTimely_voice)', function (data) {  
75 - var url = '../src/style/mp3/' + data.value + '.mp3';  
76 - var audio = common.audioPlayer(url);  
77 - audio.playclip();  
78 - }); 95 + // form.on('select(noticeTimely_voice)', function(data){
  96 + // var url='../src/style/mp3/'+data.value+'.mp3';
  97 + // var audio=common.audioPlayer(url);
  98 + // audio.playclip();
  99 + // });
79 //选择用户 100 //选择用户
80 - $("#noticeTimely-form-select-users").on("click", function () { 101 + $("#noticeTimely-form-select-users").on("click",function (){
81 //获取 102 //获取
82 var selectedNames = $("#select_noticeTimely_id_user").find("span"); 103 var selectedNames = $("#select_noticeTimely_id_user").find("span");
83 - var set = new Set(); 104 + var set=new Set();
84 selectedNames.each(function () { 105 selectedNames.each(function () {
85 set.add($(this).data("username")); 106 set.add($(this).data("username"));
86 }); 107 });
87 - common.openWin("/template/user/userlist", "选择用户", {oldUsers: Array.from(set)}, ["选择", "取消"], function () { 108 + common.openWin("/template/user/userlist","选择用户", {oldUsers: Array.from(set)},["选择","取消"], function () {
88 var data = table.checkStatus('userlist-table').data; 109 var data = table.checkStatus('userlist-table').data;
89 - if (data && data.length > 0) { 110 + if(data && data.length > 0){
90 //清除之前的 111 //清除之前的
91 $("#select_noticeTimely_id_user").empty(); 112 $("#select_noticeTimely_id_user").empty();
92 - $.each(data, function (i, v) { 113 + $.each(data,function (i,v){
93 writeTagsInfo(v) 114 writeTagsInfo(v)
94 }); 115 });
95 return true; 116 return true;
96 - } else {  
97 - layer.msg('只能选择用户!', {icon: 7, time: 3000}); 117 + }else{
  118 + layer.msg('只能选择用户!', {icon: 7,time:3000});
98 return false; 119 return false;
99 } 120 }
100 }); 121 });
101 }); 122 });
102 - //添加消息状态  
103 - $("#editNoticeTimelyParamBtn").on("click", function () { 123 +
  124 + // 播放mp3
  125 + $("#playMp3").on("click",function () {
  126 + var name = $('#noticeTimely_voice').val();
  127 + var mp3Url = `/src/style/mp3/${name}.mp3`;
  128 + var player = new Audio(mp3Url);
  129 + player.play();
  130 + });
  131 +
  132 + function addCondition(defVal){
  133 + var settingItem = $('#notice_timely_param_level');
  134 +
104 var html = $("#noticeTimelyParamAddRowHtml").html(); 135 var html = $("#noticeTimelyParamAddRowHtml").html();
105 - $('#notice_timely_param_level').append(html); 136 + settingItem.append(html);
106 $('#notice_timely_param_sql').removeClass('hide'); 137 $('#notice_timely_param_sql').removeClass('hide');
107 - $('#notice_timely_param_level').removeClass('hide');  
108 - var number = $('#notice_timely_param_level').find('.notice_time_select_sql_value').length; 138 + settingItem.removeClass('hide');
  139 + var number = settingItem.find('.notice_time_select_sql_value').length;
109 getRowName(); 140 getRowName();
110 var ht = ''; 141 var ht = '';
111 rowNames.forEach(item => { 142 rowNames.forEach(item => {
112 ht += '<option value="' + item + '">' + item + '</option>' 143 ht += '<option value="' + item + '">' + item + '</option>'
113 }) 144 })
114 - $('#notice_timely_param_level').find('.notice_time_select_sql_value').eq(number - 1).append(ht); 145 + settingItem.find('.notice_time_select_sql_value').eq(number - 1).append(ht);
115 if (identifying == 0) { 146 if (identifying == 0) {
116 - $('#notice_timely_param_level').find('.notice_time_select_colour').eq(0).val(grade); 147 + settingItem.find('.notice_time_select_colour').eq(0).val(grade);
117 identifying = 1; 148 identifying = 1;
118 } 149 }
119 - })  
120 150
  151 + settingItem.find('.delete-condition').eq(0).attr('id','id'+(new Date()).getTime());
  152 +
  153 + settingItem.find('.delete-condition').on('click',function (){
  154 + var that = $(this);
  155 + layer.confirm('确认要删除吗?', {icon: 3}, function (index) {
  156 + that.parent().parent().remove();
  157 + layer.close(index);
  158 + });
  159 + })
  160 +
  161 + if(defVal){
  162 + // 设置默认值
  163 + settingItem.find('.notice_time_select_sql_value').val(defVal.fieldName);
  164 + settingItem.find('.notice_time_select_symbol').val(defVal.condition);
  165 + settingItem.find('.layui-notice-time-btn').val(defVal.conditionVal);
  166 + settingItem.find('.notice_time_select_colour').val(defVal.msgLevel);
  167 +
  168 + setDetailsTags(rowNames);
  169 + }
  170 + }
  171 +
  172 + //添加消息状态
  173 + $("#editNoticeTimelyParamBtn").on("click",function () {
  174 +
  175 + var rowNames = getRowName();
  176 + if(rowNames && rowNames.length == 0){
  177 + let testStatus = $('#layui-notice_timely_sql_test').attr('test-status');
  178 + if(!testStatus || testStatus != 'success'){
  179 + layer.msg('请先测试脚本!', {icon: 7,time:3000});
  180 + return;
  181 + }
  182 + }
  183 +
  184 + addCondition();
  185 +
  186 + })
121 //写入标签内容 187 //写入标签内容
122 function writeTagsInfo(data) { 188 function writeTagsInfo(data) {
123 var tags = ` 189 var tags = `
124 - <span id="tags_span_${data.id}" data-id="${data.id}" data-username="${data.username}" 190 + <span id="tags_span_${data.id}" style="margin: 3px;" data-id="${data.id}" data-username="${data.username}"
125 data-nickname="${data.nickname}" data-phone="${data.phone}" ><em>${data.nickname}</em> 191 data-nickname="${data.nickname}" data-phone="${data.phone}" ><em>${data.nickname}</em>
126 <button type="button" value="${data.id}" class="tagsclose close">×</button> 192 <button type="button" value="${data.id}" class="tagsclose close">×</button>
127 </span> 193 </span>
128 `; 194 `;
129 - if (data.username) {  
130 - var flag = true; 195 + if(data.username){
  196 + var flag=true;
131 var selectedNames = $("#select_noticeTimely_id_user").find("span"); 197 var selectedNames = $("#select_noticeTimely_id_user").find("span");
132 selectedNames.each(function () { 198 selectedNames.each(function () {
133 - var id = $(this).data("id");  
134 - if (data.id == id) {  
135 - flag = false; 199 + var id=$(this).data("id");
  200 + if(data.id==id){
  201 + flag=false;
136 return false; 202 return false;
137 } 203 }
138 }); 204 });
139 - if (flag == true) { 205 + if(flag==true){
140 //拼接标签 206 //拼接标签
141 $("#select_noticeTimely_id_user").append(tags); 207 $("#select_noticeTimely_id_user").append(tags);
142 //绑定标签的删除事件 208 //绑定标签的删除事件
@@ -144,34 +210,29 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl @@ -144,34 +210,29 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl
144 } 210 }
145 } 211 }
146 } 212 }
147 -  
148 //删除标签事件 213 //删除标签事件
149 function bindTagesDelEvent() { 214 function bindTagesDelEvent() {
150 //删除已选主体的页签 215 //删除已选主体的页签
151 - $("button.tagsclose").on("click", function () { 216 + $("button.tagsclose").on("click",function () {
152 var id = $(this).attr("value"); 217 var id = $(this).attr("value");
153 - $("#tags_span_" + id).remove(); 218 + $("#tags_span_"+id).remove();
154 }); 219 });
155 } 220 }
156 -  
157 //状态转换 221 //状态转换
158 - function statusChange(v) {  
159 - var x = parseInt(v);  
160 - var y = 2; 222 + function statusChange(v){
  223 + var x=parseInt(v);
  224 + var y=2;
161 switch (x) { 225 switch (x) {
162 - case 0:  
163 - y = 1;  
164 - break;  
165 - case 1:  
166 - y = 2;  
167 - break; 226 + case 0: y=1;
  227 + break;
  228 + case 1: y=2;
  229 + break;
168 } 230 }
169 return y; 231 return y;
170 } 232 }
171 -  
172 //保存 233 //保存
173 - $("#btn-noticeTimely-submit").on("click", function () {  
174 - var userNames = []; 234 + $("#btn-noticeTimely-submit").on("click",function (){
  235 + var userNames=[];
175 //获取用户 236 //获取用户
176 var selectedTags = $("#select_noticeTimely_id_user").find("span"); 237 var selectedTags = $("#select_noticeTimely_id_user").find("span");
177 var contents = []; 238 var contents = [];
@@ -184,30 +245,44 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl @@ -184,30 +245,44 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl
184 Object.assign(noticeTimely, form.val('form-noticeTimely-add')); 245 Object.assign(noticeTimely, form.val('form-noticeTimely-add'));
185 //状态是否为开启 246 //状态是否为开启
186 noticeTimely.state = statusChange(document.querySelector("#switch_noticeTimely_state").checked ? 1 : 0); 247 noticeTimely.state = statusChange(document.querySelector("#switch_noticeTimely_state").checked ? 1 : 0);
187 - noticeTimely.broadcast = statusChange(document.querySelector("#switch_noticeTimely_broadcast").checked ? 0 : 1);  
188 - noticeTimely.retry = statusChange(document.querySelector("#switch_noticeTimely_retry").checked ? 0 : 1);  
189 - noticeTimely.sendState = statusChange(document.querySelector("#switch_noticeTimely_sendState").checked ? 0 : 1); 248 + // 是否广播消息 1是,2否
  249 + noticeTimely.broadcast = 2;//statusChange(document.querySelector("#switch_noticeTimely_broadcast").checked ? 0 : 1);
  250 + // 是否重发 1重发,2不重发
  251 + noticeTimely.retry = 2;//statusChange(document.querySelector("#switch_noticeTimely_retry").checked ? 0 : 1); //
  252 +
  253 + // 发送状态 1已发送,2未发送
  254 + noticeTimely.sendState = 2;//statusChange(document.querySelector("#switch_noticeTimely_sendState").checked ? 0 : 1);
190 noticeTimely.noticeNames = userNames; 255 noticeTimely.noticeNames = userNames;
191 - var noticeStateList = [];  
192 - //获取消息状态列表  
193 - $.each($('#editNoticeTimely_add_table').find('tbody tr'), function (i, v) {  
194 - var noticeState = {};  
195 - noticeState.noticeName = $(this).find('input[name="noticeName"]').val();  
196 - noticeState.sendTime = $(this).find('input[name="sendTime"]').val();  
197 - noticeState.sendContent = $(this).find('input[name="sendContent"]').val();  
198 - noticeState.noticeState = $(this).find('select[name="noticeState"]').val();  
199 - noticeStateList.push(noticeState);  
200 - });  
201 - noticeTimely.noticeStateList = noticeStateList; 256 + // var noticeStateList = [];
  257 + // //获取消息状态列表
  258 + // $.each($('#editNoticeTimely_add_table').find('tbody tr'), function (i, v) {
  259 + // var noticeState = {};
  260 + // noticeState.noticeName = $(this).find('input[name="noticeName"]').val();
  261 + // noticeState.sendTime = $(this).find('input[name="sendTime"]').val();
  262 + // noticeState.sendContent = $(this).find('input[name="sendContent"]').val();
  263 + // noticeState.noticeState = $(this).find('select[name="noticeState"]').val();
  264 + // noticeStateList.push(noticeState);
  265 + // });
  266 + // noticeTimely.noticeStateList = noticeStateList;
202 if (!noticeTimely.noticeNames) { 267 if (!noticeTimely.noticeNames) {
203 layer.msg('请选择用户', {icon: 7, time: 3000}); 268 layer.msg('请选择用户', {icon: 7, time: 3000});
204 return false; 269 return false;
205 } 270 }
  271 +
206 noticeTimely.site = $('#notice_timely_select').val() + $('#notice_timely_site').val(); 272 noticeTimely.site = $('#notice_timely_select').val() + $('#notice_timely_site').val();
207 //获取配置参数 273 //获取配置参数
208 var map = getParam(); 274 var map = getParam();
209 - noticeTimely.grade = map.grade; 275 + if(!map){
  276 + return false;
  277 + }
  278 + if(map.msgSetting && map.msgSetting != '' && map.msgSetting != null){
  279 + noticeTimely.msgSetting = JSON.stringify(map.msgSetting);
  280 + }
210 noticeTimely.templates = map.templates; 281 noticeTimely.templates = map.templates;
  282 + if (!noticeTimely.templates || noticeTimely.templates == '' || noticeTimely.templates == null) {
  283 + layer.msg('请配置自定义展示中的展示内容', {icon: 7, time: 3000});
  284 + return false;
  285 + }
211 layer.load(2); 286 layer.load(2);
212 admin.req({ 287 admin.req({
213 url: domainName + '/api-web/noticeTimely/save?access_token=' + accessToken, 288 url: domainName + '/api-web/noticeTimely/save?access_token=' + accessToken,
@@ -329,15 +404,21 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl @@ -329,15 +404,21 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl
329 } 404 }
330 405
331 //测试按钮点击 406 //测试按钮点击
332 - $('#layui-notice_timely_sql_test').unbind("click").on("click", function () { 407 + $('#layui-notice_timely_sql_test').unbind("click").on("click", function (e) {
  408 + e.preventDefault();
333 var sql = $('#layui-notice_timely_sql').val(); 409 var sql = $('#layui-notice_timely_sql').val();
  410 + var type = $('#noticeTimely_type').val();
  411 +
334 admin.req({ 412 admin.req({
335 url: common.domainName + '/api-web/noticeTimely/executeSql' 413 url: common.domainName + '/api-web/noticeTimely/executeSql'
336 , data: { 414 , data: {
337 - sql: sql 415 + sql: sql,
  416 + type:type
338 } 417 }
339 , success: function (res) { 418 , success: function (res) {
340 if (res && res.data && res.data.length > 0) { 419 if (res && res.data && res.data.length > 0) {
  420 + // 增加测试成功属性
  421 + $('#layui-notice_timely_sql_test').attr('test-status','success');
341 //更新行数 422 //更新行数
342 var list = res.data; 423 var list = res.data;
343 //默认取值第一个 424 //默认取值第一个
@@ -350,57 +431,99 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl @@ -350,57 +431,99 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl
350 $(this).empty(); 431 $(this).empty();
351 $(this).append(html); 432 $(this).append(html);
352 }) 433 })
353 - layer.msg('验证SQL通过!', {icon: 1, time: 3000}); 434 + setDetailsTags(keys);
  435 + layer.msg('脚本验证通过!', {icon: 1, time: 3000});
354 } else { 436 } else {
355 - layer.msg('验证SQL失败!', {icon: 7, time: 3000}); 437 + layer.msg('脚本验证失败,请检查!', {icon: 7, time: 3000});
356 } 438 }
357 } 439 }
358 }); 440 });
359 }); 441 });
360 442
  443 + function setDetailsTags(arr){
  444 +
  445 + $('#details_tags').find('.layui-badge').remove();
  446 +
  447 + var details_tags = '';
  448 + arr.forEach(item => {
  449 + details_tags += `<span id="tags_span_${item}" class="layui-badge layui-bg-blue" style="margin: 3px;" ><em>${item}</em></span>`;
  450 + })
  451 +
  452 + $('#details_tags').append(details_tags);
  453 + $('#details_tags span').on('click',function (){
  454 + $('[name="templates"]').val($('[name="templates"]').val() + '#{'+$(this).text() + '}');
  455 + });
  456 + }
  457 +
361 //获取配置参数 458 //获取配置参数
362 function getParam() { 459 function getParam() {
363 - var map = getRowName();  
364 - var pa = '';  
365 - map.rowNameList.forEach(item => {  
366 - pa += '#{' + item + '},';  
367 - })  
368 - if (pa != '') {  
369 - pa = pa.substring(0, pa.length - 1);  
370 - } 460 +
371 //获取模板和等级 461 //获取模板和等级
372 - var str = {  
373 - grade: '1',  
374 - templates: pa 462 + var obj = {
  463 + msgSetting: '',
  464 + templates: $('#notice_timely_param_sql').find('textarea[name="templates"]').eq(0).val()
375 }; 465 };
  466 +
  467 + var errMsg = '';
  468 +
376 if (!$('#notice_timely_param_sql').hasClass('hide')) { 469 if (!$('#notice_timely_param_sql').hasClass('hide')) {
377 - //获取模板信息  
378 - var val = $('#notice_timely_param_sql').find('textarea[name="details"]').eq(0).val();  
379 - str.templates = val ? val : pa;  
380 - var btn = $('#notice_timely_param_level').find('.layui-notice-time-btn').eq(0).val();  
381 - if (btn) {  
382 - //获取颜色  
383 - //行名  
384 - var row = $('#notice_timely_param_level').find('.notice_time_select_sql_value').eq(0).val();  
385 - //条件  
386 - var condition = $('#notice_timely_param_level').find('.notice_time_select_symbol').eq(0).val();  
387 - //值1  
388 - var value1 = btn;  
389 - //颜色  
390 - var colour = $('#notice_timely_param_level').find('.notice_time_select_colour').eq(0).val();  
391 - //值2  
392 - var value2 = map.dataList[0][row] ? map.dataList[0][row] : '';  
393 - var sign = compareSize(value2, condition, value1);  
394 - //判断类型  
395 - if (sign) {  
396 - str.grade = colour; 470 + // 获取模板信息
  471 + var val = obj.templates;
  472 + if(!val || val == '' || val == null){
  473 + var map = getRowName();
  474 + var exp = [];
  475 + var templatesVal = '';
  476 + map.rowNameList.forEach(item => {
  477 + exp.push('#{' + item + '}')
  478 + })
  479 +
  480 + if (exp.length > 0) {
  481 + templatesVal = exp.join(",");
397 } 482 }
398 - } else {  
399 - var colour = $('#notice_timely_param_level').find('.notice_time_select_colour').eq(0).val();  
400 - str.grade = colour; 483 + val = templatesVal;
  484 + }
  485 + obj.templates = val;
  486 +
  487 + var arr = [];
  488 + // 获取条件行
  489 + var msgSettings = $('#notice_timely_param_level').find('.msgSetting');
  490 + if(msgSettings && msgSettings.length > 0){
  491 + $(msgSettings).each(function (i,v){
  492 + if(v){
  493 + var settingItem = $(v);
  494 + var fieldName = settingItem.find('.notice_time_select_sql_value').val();
  495 + var condition = settingItem.find('.notice_time_select_symbol').val();
  496 + var conditionVal = settingItem.find('.layui-notice-time-btn').val();
  497 + var msgLevel = settingItem.find('.notice_time_select_colour').val();
  498 +
  499 + if(fieldName == '' || condition =='' || conditionVal ==''|| msgLevel =='' ||
  500 + fieldName == null || condition == null || conditionVal == null|| msgLevel == null){
  501 + if(errMsg != ''){
  502 + errMsg = "请完善展示设置的条件!";
  503 + }
  504 + return;
  505 + }
  506 + arr.push({
  507 + fieldName:fieldName,
  508 + condition:condition,
  509 + conditionVal:conditionVal,
  510 + msgLevel:msgLevel,
  511 + })
  512 + }
  513 + })
  514 + }
  515 +
  516 + if(arr.length > 0){
  517 + obj.msgSetting = arr;
401 } 518 }
402 } 519 }
403 - return str; 520 + if(errMsg != ''){
  521 + layer.msg(errMsg.join('<br/>'), {icon: 7, time: 3000});
  522 + return undefined;
  523 + }
  524 +
  525 + // 验证数据
  526 + return obj;
404 } 527 }
405 528
406 //比大小 529 //比大小
@@ -113,7 +113,7 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl @@ -113,7 +113,7 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl
113 elem: '#table-noticeTimely-state-list', 113 elem: '#table-noticeTimely-state-list',
114 url: domainName + '/api-web/noticeTimely/statePage', 114 url: domainName + '/api-web/noticeTimely/statePage',
115 where: params, 115 where: params,
116 - height: 'full', 116 + height: 'full-450',
117 limit: common.limit, 117 limit: common.limit,
118 limits: common.limits, 118 limits: common.limits,
119 page: { 119 page: {
@@ -154,13 +154,13 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl @@ -154,13 +154,13 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl
154 deleteStateById(ids); 154 deleteStateById(ids);
155 }); 155 });
156 //全部删除 156 //全部删除
157 - $('#btn-notice-state-delete').unbind("click").on('click', function () { 157 + $('#btn-notice-state-delete').unbind("click").on('click',function () {
158 //获取选中数据 158 //获取选中数据
159 var checks = table.checkStatus('table-noticeTimely-state-list').data; 159 var checks = table.checkStatus('table-noticeTimely-state-list').data;
160 - var list = checks.map(item => item.id);  
161 - if (list.length > 0) { 160 + var list= checks.map(item => item.id);
  161 + if(list.length>0){
162 deleteStateById(list); 162 deleteStateById(list);
163 - } else { 163 + }else{
164 layer.msg('请最少选择一项数据', {icon: 7, time: 2000}); 164 layer.msg('请最少选择一项数据', {icon: 7, time: 2000});
165 } 165 }
166 }) 166 })
@@ -186,46 +186,48 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl @@ -186,46 +186,48 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl
186 cols: [[{ 186 cols: [[{
187 type: 'checkbox' 187 type: 'checkbox'
188 }, { 188 }, {
189 - field: 'name', title: '名称', align: 'center', width: '250', 189 + field: 'name', title: '名称', align: 'center', minWidth: '100',
190 templet: 190 templet:
191 '<div>' + 191 '<div>' +
192 ' <span data-id="{{d.id}}" class="link link-noticeTimely-edit">{{d.name}}</span>' + 192 ' <span data-id="{{d.id}}" class="link link-noticeTimely-edit">{{d.name}}</span>' +
193 '</div>' 193 '</div>'
194 }, { 194 }, {
195 - field: 'details', title: '内容', align: 'left', minWidth: '650', 195 + field: 'details', title: '内容', align: 'left', width: '15%',
196 templet: function (d) { 196 templet: function (d) {
197 // return '<input type="text" class="layui-input" style= "background-color:transparent;border:0;padding-bottom: 10px" readonly="readonly" name="details" value="' + d.details + '">' 197 // return '<input type="text" class="layui-input" style= "background-color:transparent;border:0;padding-bottom: 10px" readonly="readonly" name="details" value="' + d.details + '">'
198 return '<code>' + d.details + '</code>' 198 return '<code>' + d.details + '</code>'
199 } 199 }
200 }, { 200 }, {
201 - field: 'frequency', title: '频率', align: 'center', width: '130' 201 + field: 'frequency', title: '频率', align: 'center', minWidth: '120'
202 }, { 202 }, {
203 field: 'noticeNicknames', title: '用户', align: 'center', minWidth: '180' 203 field: 'noticeNicknames', title: '用户', align: 'center', minWidth: '180'
204 }, { 204 }, {
205 - field: 'state', title: '是否启用', align: 'center', width: '100',  
206 - templet: function (d) {  
207 - var checked = d.state == 2 ? 'checked' : '';  
208 - return '<div><input type="checkbox" data-id="' + d.id + '" lay-filter="switch_noticeTimely_checkbox_state" name="state" lay-skin="switch" lay-text="启用|禁用" ' + checked + ' ></div>' 205 + field: 'lastSendTime', title: '最后发送时间', align: 'center', minWidth: '170',templet: function (d) {
  206 + if(d.noticeStateNew && d.noticeStateNew.sendTime){
  207 + return d.noticeStateNew.sendTime;
  208 + }
  209 + return '';
209 } 210 }
210 - }, {  
211 - field: 'broadcast', title: '是否广播', align: 'center', width: '100',  
212 - templet: function (d) {  
213 - var checked = d.broadcast == 1 ? 'checked' : '';  
214 - return '<div><input type="checkbox" data-id="' + d.id + '" lay-filter="switch_noticeTimely_checkbox_broadcast" name="broadcast" lay-skin="switch" lay-text="是|否" ' + checked + ' ></div>' 211 + },{
  212 + field: 'lastSendContent', title: '最后发送内容', align: 'center', minWidth: '200',templet: function (d) {
  213 + if(d.noticeStateNew && d.noticeStateNew.sendContent){
  214 + return d.noticeStateNew.sendContent;
  215 + }
  216 + return '';
215 } 217 }
216 - }, {  
217 - field: 'retry', title: '是否轮循', align: 'center', width: '100', 218 + },{
  219 + field: 'state', title: '是否启用', align: 'center', minWidth: '60',
218 templet: function (d) { 220 templet: function (d) {
219 - var checked = d.retry == 1 ? 'checked' : '';  
220 - return '<div><input type="checkbox" data-id="' + d.id + '" lay-filter="switch_noticeTimely_checkbox_retry" name="retry" lay-skin="switch" lay-text="重发|不重发" ' + checked + ' ></div>' 221 + var checked = d.state == 2 ? 'checked' : '';
  222 + return '<div><input type="checkbox" data-id="' + d.id + '" lay-filter="switch_noticeTimely_checkbox_state" name="state" lay-skin="switch" lay-text="启用|禁用" ' + checked + ' ></div>'
221 } 223 }
222 }, { 224 }, {
223 - title: '操作', align: 'center', minWidth: '150', fixed: 'right',  
224 - templet:  
225 - '<div>' +  
226 - ' <button data-id="{{d.id}}" class="layui-btn layui-btn-xs layui-btn-normal link-noticeTimely-delete" lay-tips="删除"><i class="layui-icon">&#xe640;</i></button>' +  
227 - ' <button data-id="{{d.id}}" class="layui-btn layui-btn-xs layui-btn-normal link-noticeTimely-history" lay-tips="历史记录"><i class="layui-icon">&#xe705;</i></button>' +  
228 - '</div>' 225 + title: '操作', align: 'center', minWidth: '80', fixed: 'right',
  226 + templet:
  227 + '<div>' +
  228 + ' <button data-id="{{d.id}}" class="layui-btn layui-btn-xs layui-btn-normal link-noticeTimely-delete" lay-tips="删除"><i class="layui-icon">&#xe640;</i></button>' +
  229 + ' <button data-id="{{d.id}}" class="layui-btn layui-btn-xs layui-btn-normal link-noticeTimely-history" lay-tips="历史记录"><i class="layui-icon">&#xe60e;</i></button>' +
  230 + '</div>'
229 }]], 231 }]],
230 done: function (res) { 232 done: function (res) {
231 // 点击名称编辑事件 233 // 点击名称编辑事件
@@ -246,7 +248,7 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl @@ -246,7 +248,7 @@ layui.define(['table', 'form', 'admin', 'layer', 'common', 'sessions', 'treeTabl
246 layer.open({ 248 layer.open({
247 title: "已发送消息", 249 title: "已发送消息",
248 content: $("#noticeTimely-state-html").html(), 250 content: $("#noticeTimely-state-html").html(),
249 - area: ['80%', '70%'], 251 + area: ['80%', '670px'],
250 btns: ['确认', '取消'], 252 btns: ['确认', '取消'],
251 success: function (index) { 253 success: function (index) {
252 loadStateTable(id); 254 loadStateTable(id);
@@ -325,7 +325,20 @@ layui.define(['admin', 'form', 'table', 'element', 'sessions', 'common', 'echart @@ -325,7 +325,20 @@ layui.define(['admin', 'form', 'table', 'element', 'sessions', 'common', 'echart
325 color: '#333', 325 color: '#333',
326 show: true, 326 show: true,
327 interval: 0, 327 interval: 0,
328 - rotate: 15 328 + rotate: 15,
  329 + formatter: val => {
  330 + // 一行字数
  331 + const max = 6
  332 + // 标签长度
  333 + const valLength = val.length
  334 + // 换行数
  335 + const rowNum = valLength / 6
  336 + if (valLength > 6) {
  337 + return val.slice(0,5) + '...';
  338 + } else {
  339 + return val
  340 + }
  341 + }
329 }, 342 },
330 axisLine: { 343 axisLine: {
331 lineStyle: { 344 lineStyle: {
@@ -452,7 +452,7 @@ layui.extend({ @@ -452,7 +452,7 @@ layui.extend({
452 new msgTips({ 452 new msgTips({
453 dom: ".right-bottom-tips", 453 dom: ".right-bottom-tips",
454 title: "告警消息", 454 title: "告警消息",
455 - message: `<p style="line-height: 40px">${v.alarmContent}</p>`, 455 + message: `<p style="line-height: 20px">${v.alarmContent}</p>`,
456 duration: 10000, 456 duration: 10000,
457 space: 10, 457 space: 10,
458 firstSpace: 8, 458 firstSpace: 8,
@@ -551,6 +551,60 @@ layui.extend({ @@ -551,6 +551,60 @@ layui.extend({
551 } 551 }
552 } 552 }
553 553
  554 + var progressObject = {
  555 + }
  556 + let progressHandel = (element,obj) =>{
  557 + let id = obj.id;
  558 + if(!progressObject[id]){
  559 + progressObject[id] = {
  560 + start:null,
  561 + list:[],
  562 + proup:null
  563 + }
  564 + }
  565 + let progressBase = $('#progressBase')
  566 + if (progressBase == null || progressBase.length == 0) {
  567 + $(document.body).append(`<div id="progressBase" style="position: absolute;width: 100%;height: 100%;background: #b4b1b1;opacity: 0.5;z-index: 10000;"> </div>
  568 + <div id="progressView" style="position: absolute;right: calc((100% - 300px)/2);top: 40%;z-index: 11000;width: 300px;padding: 5px;height: auto;background: #ffffff;opacity: 1;border-radius: 10px;margin-right: 6px;color: black;"></div>`);
  569 + }
  570 +
  571 + if (!progressObject[id].start) {
  572 + $('#'+id).remove();
  573 + let item = `<div id="${id}" style="padding: 5px;">${obj.title}</div><div class="layui-progress layui-progress-big" lay-showPercent="true" lay-filter="${id}">
  574 + <div class="layui-progress-bar layui-bg-green" lay-percent="0/1"></div>
  575 + </div>
  576 + <div id="content_${id}" style="padding: 10px 10px 0px 10px;font-size: 12px"></div></div>`;
  577 + if(!$('#progressView').find('.layui-progress:last')){
  578 + $('#progressView').find('.layui-progress:last').append(item);
  579 + } else {
  580 + $('#progressView').append(item);
  581 + }
  582 +
  583 + element.progress(id, '0%');
  584 + progressObject[id].start = obj;
  585 + return;
  586 + }
  587 + progressObject[id].list.push(obj);
  588 + let count = progressObject[id].start.count;
  589 + let size = progressObject[id].list.length
  590 +
  591 + if(count == size){
  592 + element.progress(id, '100%')
  593 + setTimeout(function () {
  594 + $('#progressView').find(id).remove();
  595 + delete progressObject[id];
  596 + if(Object.keys(progressObject)){
  597 + $('#progressBase').remove();
  598 + $('#progressView').remove();
  599 + }
  600 + $('a[layadmin-event="refresh"]').click();
  601 + },1000)
  602 + } else {
  603 + element.progress(id, ((size/count)*100).toFixed(2) + '%')
  604 + $('#progressView').find('#content_'+id).text(obj.content);
  605 + }
  606 +
  607 + }
554 608
555 // 订阅实时消息 609 // 订阅实时消息
556 stompClient.subscribe('/realTime/', function (respnose) { 610 stompClient.subscribe('/realTime/', function (respnose) {
@@ -574,6 +628,9 @@ layui.extend({ @@ -574,6 +628,9 @@ layui.extend({
574 }, function () { 628 }, function () {
575 view.exit(); 629 view.exit();
576 }); 630 });
  631 + } else if (obj.msgType == 'PROGRESS') {
  632 + var element = layui.element;
  633 + progressHandel(element,obj);
577 } else { 634 } else {
578 showTips(obj.content, obj.title, obj.msgType.toLowerCase(), obj.href, 1000, obj.queryResult); 635 showTips(obj.content, obj.title, obj.msgType.toLowerCase(), obj.href, 1000, obj.queryResult);
579 if (typeof (obj.msgType) != "undefined") { 636 if (typeof (obj.msgType) != "undefined") {
@@ -595,15 +652,22 @@ layui.extend({ @@ -595,15 +652,22 @@ layui.extend({
595 connectFlg = false; 652 connectFlg = false;
596 if (location.hash.indexOf('#/user/login') == -1) { 653 if (location.hash.indexOf('#/user/login') == -1) {
597 // 调用测试接口,出现过期则会跳转到登录页面 654 // 调用测试接口,出现过期则会跳转到登录页面
598 - admin.req({  
599 - url: domainName + "/api-web/common/test"  
600 - , type: "get"  
601 - , async: false  
602 - , done: function (data) {  
603 - tryFunc();  
604 - }  
605 - }); 655 + try {
  656 + admin.req({
  657 + url: domainName + "/api-web/common/test"
  658 + , type: "get"
  659 + , async: false
  660 + , done: function (data) {
  661 + tryFunc();
  662 + }
  663 + });
  664 + }catch (e) {
  665 + tryIndex = 1;
  666 + // 服务异常:服务重启,网络问题等不可访问等因素
  667 + tryFunc();
  668 + }
606 } else { 669 } else {
  670 + tryIndex = 1;
607 tryFunc(); 671 tryFunc();
608 } 672 }
609 }) 673 })
@@ -16,6 +16,8 @@ layui.define(['element', 'admin'], function (exports) { @@ -16,6 +16,8 @@ layui.define(['element', 'admin'], function (exports) {
16 init: function () { 16 init: function () {
17 var that = this; 17 var that = this;
18 18
  19 + that.bindClickEvent();
  20 +
19 if (that.data.contextmenus.length > 0) { 21 if (that.data.contextmenus.length > 0) {
20 that.bindContextMenuEvent(); 22 that.bindContextMenuEvent();
21 return that.data.contextmenus; 23 return that.data.contextmenus;
@@ -74,6 +76,20 @@ layui.define(['element', 'admin'], function (exports) { @@ -74,6 +76,20 @@ layui.define(['element', 'admin'], function (exports) {
74 } 76 }
75 }) 77 })
76 }, 78 },
  79 + /**
  80 + * 鼠标点击事件
  81 + */
  82 + bindClickEvent(){
  83 + var eventKeys = ['a','button','[data-bizid]','.layui-table-link'];
  84 + // 菜单点击
  85 + $('#LAY-system-side-menu li a').click(function (e){
  86 + console.log($(this).text());
  87 + e.preventDefault();
  88 + });
  89 + },
  90 + /**
  91 + * 绑定鼠标右键事件
  92 + */
77 bindContextMenuEvent() { 93 bindContextMenuEvent() {
78 var that = this; 94 var that = this;
79 var contextmenus = that.data.contextmenus; 95 var contextmenus = that.data.contextmenus;
@@ -7992,12 +7992,13 @@ table.table-duty tbody td div.table-duty-td-day .duty-td-div-now { @@ -7992,12 +7992,13 @@ table.table-duty tbody td div.table-duty-td-day .duty-td-div-now {
7992 /*通知页面中间统计图布局样式*/ 7992 /*通知页面中间统计图布局样式*/
7993 7993
7994 .detail-loadbalancing-vs { 7994 .detail-loadbalancing-vs {
7995 - width: calc(12.5% - 22px); 7995 + /*lsq 详情页节电池样式修改 2022-08-08*/
  7996 + width: calc(14% - 0px);
7996 height: 115px; 7997 height: 115px;
7997 margin: 5px; 7998 margin: 5px;
7998 float: left; 7999 float: left;
7999 border: 1px solid #dcdcdc; 8000 border: 1px solid #dcdcdc;
8000 - padding: 10px 20px; 8001 + padding: 10px;
8001 border-radius: 5px; 8002 border-radius: 5px;
8002 cursor: pointer; 8003 cursor: pointer;
8003 } 8004 }
@@ -8006,15 +8007,20 @@ table.table-duty tbody td div.table-duty-td-day .duty-td-div-now { @@ -8006,15 +8007,20 @@ table.table-duty tbody td div.table-duty-td-day .duty-td-div-now {
8006 font-size: 15px; 8007 font-size: 15px;
8007 font-weight: bold; 8008 font-weight: bold;
8008 height: 30px; 8009 height: 30px;
  8010 + word-wrap: break-word;
8009 } 8011 }
8010 8012
8011 .detail-loadbalancing-vs .vs-title { 8013 .detail-loadbalancing-vs .vs-title {
8012 margin-bottom: 10px; 8014 margin-bottom: 10px;
8013 } 8015 }
8014 - 8016 +/*lsq 详情页节点池样式修改 2022-08-08*/
  8017 +.detail-loadbalancing-vs .vs-flex{
  8018 + display: flex;
  8019 + align-items: center;
  8020 +}
8015 .detail-loadbalancing-vs div.vs-icon-div { 8021 .detail-loadbalancing-vs div.vs-icon-div {
8016 - width: 55px;  
8017 - height: 55px; 8022 + width: 45px;
  8023 + height: 45px;
8018 padding: 4px; 8024 padding: 4px;
8019 float: left; 8025 float: left;
8020 border-radius: 10px; 8026 border-radius: 10px;
@@ -8030,8 +8036,8 @@ table.table-duty tbody td div.table-duty-td-day .duty-td-div-now { @@ -8030,8 +8036,8 @@ table.table-duty tbody td div.table-duty-td-day .duty-td-div-now {
8030 } 8036 }
8031 8037
8032 .detail-loadbalancing-vs div.vs-icon { 8038 .detail-loadbalancing-vs div.vs-icon {
8033 - width: 50px;  
8034 - height: 50px; 8039 + width: 40px;
  8040 + height: 40px;
8035 background-repeat: no-repeat; 8041 background-repeat: no-repeat;
8036 background-position: center; 8042 background-position: center;
8037 background-image: url(/src/style/img/icon-db.png); 8043 background-image: url(/src/style/img/icon-db.png);
@@ -8062,6 +8068,8 @@ table.table-duty tbody td div.table-duty-td-day .duty-td-div-now { @@ -8062,6 +8068,8 @@ table.table-duty tbody td div.table-duty-td-day .duty-td-div-now {
8062 width: 61%; 8068 width: 61%;
8063 float: left; 8069 float: left;
8064 padding-left: 10px; 8070 padding-left: 10px;
  8071 + /*lsq 详情页节点池样式修改 2022-08-08*/
  8072 + flex:1;
8065 } 8073 }
8066 8074
8067 .detail-loadbalancing-vs .vs-info li { 8075 .detail-loadbalancing-vs .vs-info li {
@@ -8552,3 +8560,6 @@ form.layui-card-header.layuiadmin-card-header-auto { @@ -8552,3 +8560,6 @@ form.layui-card-header.layuiadmin-card-header-auto {
8552 .res .layui-card-body{ 8560 .res .layui-card-body{
8553 background: #ffffff; 8561 background: #ffffff;
8554 } 8562 }
  8563 +.layui-layer-tips{
  8564 + word-break: break-all;
  8565 +}
1 <article class="page-container"> 1 <article class="page-container">
2 - <form action="" class="layui-form layui-form-pane" lay-filter="form-noticeTimely-add" onsubmit="return false;"> 2 + <form class="layui-form layui-form-pane" onsubmit="return false;" action="" lay-filter="form-noticeTimely-add">
3 <fieldset class="layui-elem-field layui-field-title"> 3 <fieldset class="layui-elem-field layui-field-title">
4 <legend>消息配置</legend> 4 <legend>消息配置</legend>
5 </fieldset> 5 </fieldset>
@@ -7,120 +7,108 @@ @@ -7,120 +7,108 @@
7 <div class="inline-half layui-inline"> 7 <div class="inline-half layui-inline">
8 <label class="layui-form-label">名称</label> 8 <label class="layui-form-label">名称</label>
9 <div class="layui-input-inline"> 9 <div class="layui-input-inline">
10 - <input class="layui-input" lay-verify="required" name="name" placeholder="请输入名称" type="text"> 10 + <input type="text" name="name" lay-verify="required" placeholder="请输入名称" class="layui-input">
11 </div> 11 </div>
12 </div> 12 </div>
13 <div class="inline-half layui-inline"> 13 <div class="inline-half layui-inline">
14 - <label class="layui-form-label">频率</label>  
15 - <div class="layui-input-inline">  
16 - <input class="layui-input" id="sentFrequency_input_noticeTimely" lay-verify="required" name="frequency"  
17 - placeholder="请输入频率" type="text">  
18 - </div>  
19 - <div class="layui-form-mid layui-word-aux" id="show_corn_info_frequency"  
20 - style="padding: 0!important;position: relative;line-height: 38px;display: flex;justify-content: center;margin: 0px;margin-left: 5px;">  
21 - <i class="layui-icon form-btn-icon">&#xe702;</i>  
22 - </div>  
23 - </div>  
24 - </div>  
25 - <div class="layui-form-item" style="display: flex;justify-content: space-between;">  
26 - <div class="layui-inline" style="flex: 1;">  
27 <label class="layui-form-label">状态</label> 14 <label class="layui-form-label">状态</label>
28 - <div class="layui-input-inline" style="margin-left: 20px;;width: 100px">  
29 - <!-- <div class="layui-input-inline" style="width: calc(20vw - 142px);margin-right:65px;margin-left: 50px;">-->  
30 - <input id="switch_noticeTimely_state" lay-skin="switch" lay-text="启用|禁用" name="state"  
31 - type="checkbox" value="0">  
32 - </div>  
33 - </div>  
34 - <div class="layui-inline" style="flex: 1;">  
35 - <label class="layui-form-label">是否广播</label>  
36 - <div class="layui-input-inline" style="margin-left: 20px;width: 100px">  
37 - <input id="switch_noticeTimely_broadcast" lay-skin="switch" lay-text="是|否" name="broadcast"  
38 - type="checkbox" value="0">  
39 - </div>  
40 - </div>  
41 - <div class="layui-inline" style="">  
42 - <label class="layui-form-label">是否轮循</label>  
43 - <div class="layui-input-inline" style="margin-left: 20px;width: 100px">  
44 - <input id="switch_noticeTimely_retry" lay-skin="switch" lay-text="轮循|不轮循" name="retry"  
45 - type="checkbox" value="0">  
46 - </div>  
47 - </div>  
48 - <div class="layui-inline" style="display: none !important;">  
49 - <label class="layui-form-label">发送状态</label>  
50 - <div class="layui-input-inline" style="width: calc(20vw - 142px);margin-right:0px;margin-left: 50px;">  
51 - <input id="switch_noticeTimely_sendState" lay-skin="switch" lay-text="已发送|未发送" name="sendState"  
52 - type="checkbox" value="0"> 15 + <div class="layui-input-inline" style="padding-left: 6px">
  16 + <input type="checkbox" id="switch_noticeTimely_state" name="state" lay-skin="switch" lay-text="启用|禁用" value="0" >
53 </div> 17 </div>
54 </div> 18 </div>
55 </div> 19 </div>
  20 +
56 <div class="layui-form-item"> 21 <div class="layui-form-item">
57 - <div class="inline-half layui-inline" style="display: none!important;">  
58 - <label class="layui-form-label" style="font-size: 12px">重发延迟时间</label>  
59 - <div class="layui-input-inline">  
60 - <input class="layui-input" name="retryTime" placeholder="请输入重发延迟时间(秒)" type="text"> 22 + <div class="inline-half layui-inline" style="width: 100%">
  23 + <label class="layui-form-label">频率</label>
  24 + <div style="width: calc(100% - 110px)">
  25 + <div class="layui-input-inline" style="width: calc(100% - 10px);display: inline-flex;">
  26 + <input type="text" id="sentFrequency_input_noticeTimely" name="frequency" lay-verify="required"
  27 + placeholder="请输入频率" class="layui-input">
  28 + <i id="show_corn_info_frequency" class="layui-icon form-btn-icon" style="line-height: 32px;margin-left: 5px;">&#xe702;</i>
  29 + </div>
61 </div> 30 </div>
62 </div> 31 </div>
  32 + </div>
  33 +
  34 + <!--添砖地址功能待优化-->
  35 + <!--<div class="layui-form-item">
63 <div class="inline-half layui-inline" style="width: 100%"> 36 <div class="inline-half layui-inline" style="width: 100%">
64 <label class="layui-form-label">跳转地址</label> 37 <label class="layui-form-label">跳转地址</label>
65 - <div style="width: 95%">  
66 - <div class="layui-input-inline" style="width: 46%;"> 38 + <div style="width: calc(100% - 110px)">
  39 + <div class="layui-input-inline" style="width: 200px;">
67 <select id="notice_timely_select"> 40 <select id="notice_timely_select">
68 - <option disabled="disabled" selected="selected" style='display: none' value=''></option> 41 + <option selected="selected" disabled="disabled" style='display: none' value=''></option>
69 </select> 42 </select>
70 </div> 43 </div>
71 - <div class="layui-input-inline" style="margin-left: 1px;width: 52%;">  
72 - <input class="layui-input" id="notice_timely_site" name="site" placeholder="请输入详情页地址"  
73 - type="text"> 44 + <div class="layui-input-inline" style="width: calc(100% - 210px);display: inline-flex;">
  45 + <input type="text" name="site" id="notice_timely_site" placeholder="请输入详情页地址" class="layui-input">
  46 + <i id="show_corn_info_state" class="layui-icon form-btn-icon" style="line-height: 32px;margin-left: 5px;">&#xe702;</i>
74 </div> 47 </div>
75 - <div class="layui-form-mid layui-word-aux" id="show_corn_info_state"  
76 - style="padding: 0!important;position: relative;line-height: 38px;display: flex;justify-content: center;margin: 0px;margin-left: 5px;">  
77 - <i class="layui-icon form-btn-icon">&#xe702;</i> 48 + </div>
  49 + </div>
  50 + </div>-->
  51 +
  52 + <div class="layui-form-item">
  53 + <div class="inline-half layui-inline" style="width: 100%">
  54 + <label class="layui-form-label">发送用户</label>
  55 + <div style="width: calc(100% - 110px)">
  56 + <div class="layui-input-inline" style="width: calc(100% - 10px);display: inline-flex;">
  57 + <div class="tags" id="select_noticeTimely_id_user" style="width: calc(100% - 20px);border: solid 1px #D2D2D2;margin-top: 0px;height: 36px;"></div>
  58 + <i class="layui-icon form-btn-icon" id="noticeTimely-form-select-users" style="line-height: 36px;margin-left: 5px;">&#xe615;</i>
78 </div> 59 </div>
79 </div> 60 </div>
80 </div> 61 </div>
81 </div> 62 </div>
  63 +
82 <div class="layui-form-item"> 64 <div class="layui-form-item">
83 - <div class="inline-half layui-inline" style="display: none!important;"> 65 + <div class="inline-half layui-inline">
84 <label class="layui-form-label">响应声音</label> 66 <label class="layui-form-label">响应声音</label>
85 <div class="layui-input-inline"> 67 <div class="layui-input-inline">
86 - <select id="noticeTimely_voice" lay-filter="noticeTimely_voice" name="voice">  
87 - <option value="咳咳">咳咳</option>  
88 - <option value="微信提醒">微信提醒</option>  
89 - <option value="滑稽">滑稽</option>  
90 - </select> 68 + <div style="display: flex">
  69 + <div style=" width: calc(100% - 60px);">
  70 + <select name="voice" id="noticeTimely_voice" lay-filter="noticeTimely_voice" >
  71 + <option value="14039">叮咚</option>
  72 + <option value="咳咳">咳咳</option>
  73 + <option value="微信提醒">微信提醒</option>
  74 + <option value="滑稽">滑稽</option>
  75 + </select>
  76 + </div>
  77 + <button type="button" class="layui-btn layui-btn-primary" id="playMp3" style="margin-left: 2px">
  78 + <i class="layui-icon">&#xe652;</i>
  79 + </button>
  80 + </div>
91 </div> 81 </div>
92 </div> 82 </div>
93 - <div class="inline-half layui-inline" style="display: none!important;"> 83 + <div class="inline-half layui-inline">
94 <label class="layui-form-label">类型</label> 84 <label class="layui-form-label">类型</label>
95 <div class="layui-input-inline"> 85 <div class="layui-input-inline">
96 - <input class="layui-input" name="type" placeholder="请输入类型" readonly="readonly" type="text"  
97 - value="sql"> 86 + <select name="type" id="noticeTimely_type" lay-filter="noticeTimely_type">
  87 + <option value="SQL">监控数据库</option>
  88 + <option value="TEXT">文本</option>
  89 + <option value="ES">es</option>
  90 + <option value="INFLUXDB">时序</option>
  91 + <!-- <option value="tdEngine">tdEngine</option>-->
  92 + </select>
  93 + <div style="padding: 3px">
  94 + 文本支持:#{now} 当前时间格式:yyyy-MM-dd HH:mm:ss
  95 + </div>
98 </div> 96 </div>
99 </div> 97 </div>
100 </div> 98 </div>
101 - <div class="layui-form-item layui-form-item-flex">  
102 - <label class="layui-form-label" style="height:42px;">用户</label>  
103 -<!-- lsq 输入框没在一行 2022-06-29 <div class="layui-input-block tags-input" style="height: auto;width: 90% !important;">-->  
104 - <div class="tags-input" style="height: auto;">  
105 - <div class="tags" id="select_noticeTimely_id_user"></div>  
106 - </div>  
107 - <div class="layui-form-mid layui-word-aux"  
108 - style="margin-left: 10px; ">  
109 - <i class="layui-icon form-btn-icon" id="noticeTimely-form-select-users">&#xe615;</i></div>  
110 - </div> 99 +
111 <div class="layui-form-item"> 100 <div class="layui-form-item">
112 <label class="layui-form-label textarea-label">内容</label> 101 <label class="layui-form-label textarea-label">内容</label>
113 <div class="layui-input-block" style="display: flex;flex-direction: column;align-items: flex-end;"> 102 <div class="layui-input-block" style="display: flex;flex-direction: column;align-items: flex-end;">
114 - <textarea class="layui-textarea" id="layui-notice_timely_sql" name="details" placeholder="请输入内容(SQL)"  
115 - style="width: 100%"></textarea>  
116 - <div style="width: 100px;height: auto;">  
117 - <div id="layui-notice_timely_sql_test"  
118 - style="background-color: #1E9FFF;width: 90px;float: right;display: flex;justify-content: center;height: 40px;line-height: 40px;margin-top: 30px; color: #fff;">测试  
119 - </div> 103 + <textarea name="details" placeholder="请输入脚本内容" class="layui-textarea" id="layui-notice_timely_sql" style="width: 100%"></textarea>
  104 + <div style="width: 100%;padding: 10px 0px;">
  105 + <button id="layui-notice_timely_sql_test" class="layui-btn layui-btn-normal">测试脚本</button>
  106 + <span style="color: red">* 脚本尽量添加条件,否则一次性查询内容过多导致发送消息失败!(建议发送内容不超过200个汉字)</span>
120 </div> 107 </div>
121 </div> 108 </div>
122 </div> 109 </div>
123 - <button class="hide" id="btn-noticeTimely-submit" lay-filter="btn-noticeTimely-submit" lay-submit>提交</button> 110 +
  111 + <button id="btn-noticeTimely-submit" class="hide" lay-submit lay-filter="btn-noticeTimely-submit">提交</button>
124 </form> 112 </form>
125 <div class="layui-card-body layui-form-pane editNoticeTimelyParam-list" style="padding-top: 0px;"> 113 <div class="layui-card-body layui-form-pane editNoticeTimelyParam-list" style="padding-top: 0px;">
126 <fieldset class="layui-elem-field layui-field-title"> 114 <fieldset class="layui-elem-field layui-field-title">
@@ -135,16 +123,18 @@ @@ -135,16 +123,18 @@
135 <div class="layui-form-item hide" id="notice_timely_param_sql"> 123 <div class="layui-form-item hide" id="notice_timely_param_sql">
136 <label class="layui-form-label textarea-label">展示内容</label> 124 <label class="layui-form-label textarea-label">展示内容</label>
137 <div class="layui-input-block" style="display: flex;"> 125 <div class="layui-input-block" style="display: flex;">
138 - <textarea class="layui-textarea" name="details" placeholder="请输入展示内容" style=""></textarea> 126 + <textarea name="templates" placeholder="请输入展示内容" class="layui-textarea" style=""></textarea>
139 </div> 127 </div>
  128 + <div id="details_tags" style="width: 100%;display: flex;flex-wrap: wrap;"></div>
140 </div> 129 </div>
141 <div class="layui-form-item hide" id="notice_timely_param_level"> 130 <div class="layui-form-item hide" id="notice_timely_param_level">
142 <label class="layui-form-label">展示设置</label> 131 <label class="layui-form-label">展示设置</label>
  132 + <span style="color: red;line-height:36px">* 列表数据的状态设置办法:获取“第一条”数据的内容进行判断。</span>
143 </div> 133 </div>
144 </div> 134 </div>
145 </article> 135 </article>
146 -<script id="noticeTimelyParamAddRowHtml" type="text/html">  
147 - <div class="layui-form-item"> 136 +<script type="text/html" id="noticeTimelyParamAddRowHtml">
  137 + <div class="layui-form-item msgSetting">
148 <div class="layui-inline" style="margin-left: 110px"> 138 <div class="layui-inline" style="margin-left: 110px">
149 <div class="layui-notice-time-lable">当数据集中的</div> 139 <div class="layui-notice-time-lable">当数据集中的</div>
150 <select class="layui-notice-time-select notice_time_select_sql_value"> 140 <select class="layui-notice-time-select notice_time_select_sql_value">
@@ -152,8 +142,8 @@ @@ -152,8 +142,8 @@
152 </select> 142 </select>
153 <div class="layui-notice-time-lable" style="width: 40px;">的值</div> 143 <div class="layui-notice-time-lable" style="width: 40px;">的值</div>
154 <select class="layui-notice-time-select notice_time_select_symbol"> 144 <select class="layui-notice-time-select notice_time_select_symbol">
155 - <option value="0">大于</option>  
156 - <option value="1">小于</option> 145 + <option value="0">大于(适用于数字类型、日期类型)</option>
  146 + <option value="1">小于(适用于数字类型、日期类型)</option>
157 <option value="2">等于</option> 147 <option value="2">等于</option>
158 </select> 148 </select>
159 <input type="text" class="layui-notice-time-btn" value=""> 149 <input type="text" class="layui-notice-time-btn" value="">
@@ -163,109 +153,66 @@ @@ -163,109 +153,66 @@
163 <option value="2">重要(黄色)</option> 153 <option value="2">重要(黄色)</option>
164 <option value="3">严重(红色)</option> 154 <option value="3">严重(红色)</option>
165 </select> 155 </select>
166 - <div class="layui-notice-time-lable" style="width: 40px;">提示</div> 156 + <div class="layui-notice-time-lable delete-condition" style="width: 40px;">删除</div>
167 </div> 157 </div>
168 </div> 158 </div>
169 </script> 159 </script>
170 <!--及时消息配置SQL示例--> 160 <!--及时消息配置SQL示例-->
171 -<script id="notice_timely_template" type="text/html"> 161 +<script type="text/html" id="notice_timely_template">
172 <div id="cronContent" style="color:#000000"> 162 <div id="cronContent" style="color:#000000">
173 <p style="margin: 10px auto; padding: 0px;"> 163 <p style="margin: 10px auto; padding: 0px;">
174 -   <strong style="margin: 0px; padding: 0px;"><span  
175 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);">展示内容用法详解</span></strong> 164 +   <strong style="margin: 0px; padding: 0px;"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);">展示内容用法详解</span></strong>
176 </p> 165 </p>
177 <p style="margin: 10px auto; padding: 0px;"> 166 <p style="margin: 10px auto; padding: 0px;">
178 -   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span  
179 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span  
180 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">1</span></span><strong  
181 - style="margin: 0px; padding: 0px;"><span  
182 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">如配置SQL为:select content,way from b_notice_his LIMIT 0,5</span></strong>&nbsp;&nbsp;</span>&nbsp;表示有两列数据,分别为content和way 167 +   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">1</span></span><strong style="margin: 0px; padding: 0px;"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">如配置SQL为:select content,way from b_notice_his LIMIT 0,5</span></strong>&nbsp;&nbsp;</span>&nbsp;表示有两列数据,分别为content和way
183 </p> 168 </p>
184 <p style="margin: 10px auto; padding: 0px;"> 169 <p style="margin: 10px auto; padding: 0px;">
185 -   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span  
186 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span  
187 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">2</span></span><strong  
188 - style="margin: 0px; padding: 0px;"><span  
189 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">若展示内容为:测试,发送内容为#{content},发送类型为#{way}</span></strong>&nbsp;&nbsp;</span>&nbsp;发送的内容就是拼接起来的内 170 +   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">2</span></span><strong style="margin: 0px; padding: 0px;"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">若展示内容为:测试,发送内容为#{content},发送类型为#{way}</span></strong>&nbsp;&nbsp;</span>&nbsp;发送的内容就是拼接起来的内
190 </p> 171 </p>
191 <p style="margin: 10px auto; padding: 0px;"> 172 <p style="margin: 10px auto; padding: 0px;">
192 -   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span  
193 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span  
194 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">3</span></span><strong  
195 - style="margin: 0px; padding: 0px;"><span  
196 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">只支持Mysql语法,且查询结果多行时,默认使用第一行数据</span></strong>&nbsp;&nbsp;</span>&nbsp;可嵌入&lt;/br&gt;进行换行 173 +   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">3</span></span><strong style="margin: 0px; padding: 0px;"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">只支持Mysql语法,且查询结果多行时,默认使用第一行数据</span></strong>&nbsp;&nbsp;</span>&nbsp;可嵌入&lt;/br&gt;进行换行
197 </p> 174 </p>
198 <p style="margin: 10px auto; padding: 0px;"> 175 <p style="margin: 10px auto; padding: 0px;">
199 -   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span  
200 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span  
201 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">4</span></span><strong  
202 - style="margin: 0px; padding: 0px;"><span  
203 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">#{}里面只支持单个参数,展示内容可以不填</span></strong>&nbsp;&nbsp;</span>&nbsp;默认为所有列加逗号的拼 176 +   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">4</span></span><strong style="margin: 0px; padding: 0px;"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">#{}里面只支持单个参数,展示内容可以不填</span></strong>&nbsp;&nbsp;</span>&nbsp;默认为所有列加逗号的拼
204 </p> 177 </p>
205 178
206 <p> 179 <p>
207 &nbsp; 180 &nbsp;
208 </p> 181 </p>
209 <p style="margin: 10px auto; padding: 0px;"> 182 <p style="margin: 10px auto; padding: 0px;">
210 -   <strong style="margin: 0px; padding: 0px;"><span  
211 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);">展示配置用法详解</span></strong> 183 +   <strong style="margin: 0px; padding: 0px;"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);">展示配置用法详解</span></strong>
212 </p> 184 </p>
213 <p style="margin: 10px auto; padding: 0px;"> 185 <p style="margin: 10px auto; padding: 0px;">
214 -   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span  
215 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span  
216 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">1</span></span><strong  
217 - style="margin: 0px; padding: 0px;"><span  
218 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">自定义展示设置可只选颜色,也可自定义条件。若不满足条件默认为绿色</span></strong>&nbsp;&nbsp;</span>&nbsp;展示设置中的颜色默认为绿 186 +   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">1</span></span><strong style="margin: 0px; padding: 0px;"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">自定义展示设置可只选颜色,也可自定义条件。若不满足条件默认为绿色</span></strong>&nbsp;&nbsp;</span>&nbsp;展示设置中的颜色默认为绿
219 </p> 187 </p>
220 <p style="margin: 10px auto; padding: 0px;"> 188 <p style="margin: 10px auto; padding: 0px;">
221 -   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span  
222 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span  
223 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">2</span></span><strong  
224 - style="margin: 0px; padding: 0px;"><span  
225 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">当自定义展示设置多天记录时,只会采用第一条</span></strong>&nbsp;&nbsp;</span>&nbsp;自动识别两者比较大小——数字或字符 189 +   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">2</span></span><strong style="margin: 0px; padding: 0px;"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">当自定义展示设置多天记录时,只会采用第一条</span></strong>&nbsp;&nbsp;</span>&nbsp;自动识别两者比较大小——数字或字符
226 </p> 190 </p>
227 <p style="margin: 10px auto; padding: 0px;"> 191 <p style="margin: 10px auto; padding: 0px;">
228 -   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span  
229 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span  
230 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">3</span></span><strong  
231 - style="margin: 0px; padding: 0px;"><span  
232 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">颜色的选择和弹出声音有关系</span></strong>&nbsp;&nbsp;</span>&nbsp;每种颜色对应不同的声 192 +   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">3</span></span><strong style="margin: 0px; padding: 0px;"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">颜色的选择和弹出声音有关系</span></strong>&nbsp;&nbsp;</span>&nbsp;每种颜色对应不同的声
233 </p> 193 </p>
234 </div> 194 </div>
235 </script> 195 </script>
236 196
237 <!--及时消息跳转地址示例--> 197 <!--及时消息跳转地址示例-->
238 -<script id="notice_timely_site_template" type="text/html"> 198 +<script type="text/html" id="notice_timely_site_template">
239 <div id="cronContent_site" style="color:#000000"> 199 <div id="cronContent_site" style="color:#000000">
240 <p style="margin: 10px auto; padding: 0px;"> 200 <p style="margin: 10px auto; padding: 0px;">
241 -   <strong style="margin: 0px; padding: 0px;"><span  
242 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);">跳转地址用法详解</span></strong> 201 +   <strong style="margin: 0px; padding: 0px;"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);">跳转地址用法详解</span></strong>
243 </p> 202 </p>
244 <p style="margin: 10px auto; padding: 0px;"> 203 <p style="margin: 10px auto; padding: 0px;">
245 -   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span  
246 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span  
247 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">1</span></span><strong  
248 - style="margin: 0px; padding: 0px;"><span  
249 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">跳转地址的文本框也支持模板配置</span></strong>&nbsp;&nbsp;</span>&nbsp;参数必须是SQL 204 +   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">1</span></span><strong style="margin: 0px; padding: 0px;"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">跳转地址的文本框也支持模板配置</span></strong>&nbsp;&nbsp;</span>&nbsp;参数必须是SQL
250 </p> 205 </p>
251 <p style="margin: 10px auto; padding: 0px;"> 206 <p style="margin: 10px auto; padding: 0px;">
252 -   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span  
253 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span  
254 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">2</span></span><strong  
255 - style="margin: 0px; padding: 0px;"><span  
256 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">跳转地址的下拉框数据在数据字典中配置</span></strong>&nbsp;&nbsp;</span>&nbsp;必须以http://https://开头 207 +   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">2</span></span><strong style="margin: 0px; padding: 0px;"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">跳转地址的下拉框数据在数据字典中配置</span></strong>&nbsp;&nbsp;</span>&nbsp;必须以http://https://开头
257 </p> 208 </p>
258 <p style="margin: 10px auto; padding: 0px;"> 209 <p style="margin: 10px auto; padding: 0px;">
259 -   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span  
260 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span  
261 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">3</span></span><strong  
262 - style="margin: 0px; padding: 0px;"><span  
263 - style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">跳转地址的实际数据是下拉框跟文本框拼接的内容</span></strong>&nbsp;&nbsp;</span>&nbsp;即时消息弹窗点击后会跳转该路 210 +   <span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(255, 0, 0);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 0);">3</span></span><strong style="margin: 0px; padding: 0px;"><span style="margin: 0px; padding: 0px; line-height: 18px; color: rgb(0, 0, 255);">跳转地址的实际数据是下拉框跟文本框拼接的内容</span></strong>&nbsp;&nbsp;</span>&nbsp;即时消息弹窗点击后会跳转该路
264 </p> 211 </p>
265 </div> 212 </div>
266 </script> 213 </script>
267 <script> 214 <script>
268 layui.use('noticeTimelyAdd', function (fn) { 215 layui.use('noticeTimelyAdd', function (fn) {
269 - fn({{ d }}); 216 + fn({{d}});
270 }); 217 });
271 </script> 218 </script>
1 <title>及时消息配置</title> 1 <title>及时消息配置</title>
2 <article class="page-container"> 2 <article class="page-container">
3 <div class="page-panel"> 3 <div class="page-panel">
4 - <div class="main commonDiv"> 4 + <div class="main">
5 <div class="layui-card"> 5 <div class="layui-card">
6 <div class="layui-card-header"> 6 <div class="layui-card-header">
7 <div class="layui-status"> 7 <div class="layui-status">
8 - <form class="layui-card-header layuiadmin-card-header-auto layui-form" lay-filter="form-noticeTimely-condition"  
9 - onsumit="return false"> 8 + <form class="layui-card-header layuiadmin-card-header-auto layui-form" onsumit="return false" lay-filter="form-noticeTimely-condition">
10 <div class="layui-form-item"> 9 <div class="layui-form-item">
11 <div class="layui-inline"> 10 <div class="layui-inline">
12 <div class="layui-input-inline layui-input-inline--long"> 11 <div class="layui-input-inline layui-input-inline--long">
13 - <input autocomplete="off" class="layui-input" lay-tips="关键字检索包含:</br>名称" name="keyword"  
14 - placeholder="输入关键字,回车搜索" type="text"> 12 + <input type="text" name="keyword" placeholder="输入关键字,回车搜索" autocomplete="off" class="layui-input" lay-tips="关键字检索包含:</br>名称">
15 </div> 13 </div>
16 </div> 14 </div>
17 - <button class="layui-btn layui-btn-normal" id="noticeTimelyQueryBtn" type="button">  
18 - <!--lsq 查询按钮取消掉图标 2022-06-29-->  
19 - 查询  
20 - </button> 15 + <div class="layui-inline">
  16 + <button id="noticeTimelyQueryBtn" type="button" class="layui-btn layui-btn-normal" >查询
  17 + </button>
  18 + </div>
21 </div> 19 </div>
22 </form> 20 </form>
23 </div> 21 </div>
@@ -40,7 +38,7 @@ @@ -40,7 +38,7 @@
40 </div> 38 </div>
41 </div> 39 </div>
42 </article> 40 </article>
43 -<script id="noticeTimely-state-html" type="text/html"> 41 +<script type="text/html" id="noticeTimely-state-html" >
44 <div class="layui-card-body"> 42 <div class="layui-card-body">
45 <div class="warn-btns"> 43 <div class="warn-btns">
46 <button class="layui-btn layui-btn-sm layui-btn-normal" id="btn-notice-state-delete"> 44 <button class="layui-btn layui-btn-sm layui-btn-normal" id="btn-notice-state-delete">
  1 +/*! Element Plus v2.2.5 */
  2 +
1 (function (global, factory) { 3 (function (global, factory) {
2 - if (typeof define === "function" && define.amd) {  
3 - define("element/locale/zh-cn", ["exports"], factory);  
4 - } else if (typeof exports !== "undefined") {  
5 - factory(exports);  
6 - } else {  
7 - var mod = {  
8 - exports: {}  
9 - };  
10 - factory(mod.exports);  
11 - global.ElementPlus.lang = global.ElementPlus.lang || {};  
12 - global.ElementPlus.lang.zhCn = mod.exports.default;  
13 - }  
14 -})(typeof globalThis !== "undefined" ? globalThis : typeof self !== "undefined" ? self : this, function (_exports) {  
15 - "use strict"; 4 + typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
  5 + typeof define === 'function' && define.amd ? define(factory) :
  6 + (global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.ElementPlusLocaleZhCn = factory());
  7 +})(this, (function () { 'use strict';
16 8
17 - Object.defineProperty(_exports, "__esModule", {  
18 - value: true  
19 - });  
20 - _exports.default = void 0;  
21 - var _default = {  
22 - name: 'zh-cn',  
23 - el: {  
24 - colorpicker: {  
25 - confirm: '确定',  
26 - clear: '清空'  
27 - },  
28 - datepicker: {  
29 - now: '此刻',  
30 - today: '今天',  
31 - cancel: '取消',  
32 - clear: '清空',  
33 - confirm: '确定',  
34 - selectDate: '选择日期',  
35 - selectTime: '选择时间',  
36 - startDate: '开始日期',  
37 - startTime: '开始时间',  
38 - endDate: '结束日期',  
39 - endTime: '结束时间',  
40 - prevYear: '前一年',  
41 - nextYear: '后一年',  
42 - prevMonth: '上个月',  
43 - nextMonth: '下个月',  
44 - year: '年',  
45 - month1: '1 月',  
46 - month2: '2 月',  
47 - month3: '3 月',  
48 - month4: '4 月',  
49 - month5: '5 月',  
50 - month6: '6 月',  
51 - month7: '7 月',  
52 - month8: '8 月',  
53 - month9: '9 月',  
54 - month10: '10 月',  
55 - month11: '11 月',  
56 - month12: '12 月',  
57 - // week: '周次',  
58 - weeks: {  
59 - sun: '日',  
60 - mon: '一',  
61 - tue: '二',  
62 - wed: '三',  
63 - thu: '四',  
64 - fri: '五',  
65 - sat: '六'  
66 - },  
67 - months: {  
68 - jan: '一月',  
69 - feb: '二月',  
70 - mar: '三月',  
71 - apr: '四月',  
72 - may: '五月',  
73 - jun: '六月',  
74 - jul: '七月',  
75 - aug: '八月',  
76 - sep: '九月',  
77 - oct: '十月',  
78 - nov: '十一月',  
79 - dec: '十二月'  
80 - }  
81 - },  
82 - select: {  
83 - loading: '加载中',  
84 - noMatch: '无匹配数据',  
85 - noData: '无数据',  
86 - placeholder: '请选择'  
87 - },  
88 - cascader: {  
89 - noMatch: '无匹配数据',  
90 - loading: '加载中',  
91 - placeholder: '请选择',  
92 - noData: '暂无数据'  
93 - },  
94 - pagination: {  
95 - goto: '前往',  
96 - pagesize: '条/页',  
97 - total: '共 {total} 条',  
98 - pageClassifier: '页',  
99 - deprecationWarning: '你使用了一些已被废弃的用法,请参考 el-pagination 的官方文档'  
100 - },  
101 - messagebox: {  
102 - title: '提示',  
103 - confirm: '确定',  
104 - cancel: '取消',  
105 - error: '输入的数据不合法!'  
106 - },  
107 - upload: {  
108 - deleteTip: '按 delete 键可删除',  
109 - delete: '删除',  
110 - preview: '查看图片',  
111 - continue: '继续上传'  
112 - },  
113 - table: {  
114 - emptyText: '暂无数据',  
115 - confirmFilter: '筛选',  
116 - resetFilter: '重置',  
117 - clearFilter: '全部',  
118 - sumText: '合计'  
119 - },  
120 - tree: {  
121 - emptyText: '暂无数据'  
122 - },  
123 - transfer: {  
124 - noMatch: '无匹配数据',  
125 - noData: '无数据',  
126 - titles: ['列表 1', '列表 2'],  
127 - filterPlaceholder: '请输入搜索内容',  
128 - noCheckedFormat: '共 {total} 项',  
129 - hasCheckedFormat: '已选 {checked}/{total} 项'  
130 - },  
131 - image: {  
132 - error: '加载失败'  
133 - },  
134 - pageHeader: {  
135 - title: '返回'  
136 - },  
137 - popconfirm: {  
138 - confirmButtonText: '确定',  
139 - cancelButtonText: '取消'  
140 - } 9 + var zhCn = {
  10 + name: "zh-cn",
  11 + el: {
  12 + colorpicker: {
  13 + confirm: "\u786E\u5B9A",
  14 + clear: "\u6E05\u7A7A"
  15 + },
  16 + datepicker: {
  17 + now: "\u6B64\u523B",
  18 + today: "\u4ECA\u5929",
  19 + cancel: "\u53D6\u6D88",
  20 + clear: "\u6E05\u7A7A",
  21 + confirm: "\u786E\u5B9A",
  22 + selectDate: "\u9009\u62E9\u65E5\u671F",
  23 + selectTime: "\u9009\u62E9\u65F6\u95F4",
  24 + startDate: "\u5F00\u59CB\u65E5\u671F",
  25 + startTime: "\u5F00\u59CB\u65F6\u95F4",
  26 + endDate: "\u7ED3\u675F\u65E5\u671F",
  27 + endTime: "\u7ED3\u675F\u65F6\u95F4",
  28 + prevYear: "\u524D\u4E00\u5E74",
  29 + nextYear: "\u540E\u4E00\u5E74",
  30 + prevMonth: "\u4E0A\u4E2A\u6708",
  31 + nextMonth: "\u4E0B\u4E2A\u6708",
  32 + year: "\u5E74",
  33 + month1: "1 \u6708",
  34 + month2: "2 \u6708",
  35 + month3: "3 \u6708",
  36 + month4: "4 \u6708",
  37 + month5: "5 \u6708",
  38 + month6: "6 \u6708",
  39 + month7: "7 \u6708",
  40 + month8: "8 \u6708",
  41 + month9: "9 \u6708",
  42 + month10: "10 \u6708",
  43 + month11: "11 \u6708",
  44 + month12: "12 \u6708",
  45 + weeks: {
  46 + sun: "\u65E5",
  47 + mon: "\u4E00",
  48 + tue: "\u4E8C",
  49 + wed: "\u4E09",
  50 + thu: "\u56DB",
  51 + fri: "\u4E94",
  52 + sat: "\u516D"
  53 + },
  54 + months: {
  55 + jan: "\u4E00\u6708",
  56 + feb: "\u4E8C\u6708",
  57 + mar: "\u4E09\u6708",
  58 + apr: "\u56DB\u6708",
  59 + may: "\u4E94\u6708",
  60 + jun: "\u516D\u6708",
  61 + jul: "\u4E03\u6708",
  62 + aug: "\u516B\u6708",
  63 + sep: "\u4E5D\u6708",
  64 + oct: "\u5341\u6708",
  65 + nov: "\u5341\u4E00\u6708",
  66 + dec: "\u5341\u4E8C\u6708"
141 } 67 }
142 - };  
143 - _exports.default = _default;  
144 -}); 68 + },
  69 + select: {
  70 + loading: "\u52A0\u8F7D\u4E2D",
  71 + noMatch: "\u65E0\u5339\u914D\u6570\u636E",
  72 + noData: "\u65E0\u6570\u636E",
  73 + placeholder: "\u8BF7\u9009\u62E9"
  74 + },
  75 + cascader: {
  76 + noMatch: "\u65E0\u5339\u914D\u6570\u636E",
  77 + loading: "\u52A0\u8F7D\u4E2D",
  78 + placeholder: "\u8BF7\u9009\u62E9",
  79 + noData: "\u6682\u65E0\u6570\u636E"
  80 + },
  81 + pagination: {
  82 + goto: "\u524D\u5F80",
  83 + pagesize: "\u6761/\u9875",
  84 + total: "\u5171 {total} \u6761",
  85 + pageClassifier: "\u9875",
  86 + deprecationWarning: "\u4F60\u4F7F\u7528\u4E86\u4E00\u4E9B\u5DF2\u88AB\u5E9F\u5F03\u7684\u7528\u6CD5\uFF0C\u8BF7\u53C2\u8003 el-pagination \u7684\u5B98\u65B9\u6587\u6863"
  87 + },
  88 + messagebox: {
  89 + title: "\u63D0\u793A",
  90 + confirm: "\u786E\u5B9A",
  91 + cancel: "\u53D6\u6D88",
  92 + error: "\u8F93\u5165\u7684\u6570\u636E\u4E0D\u5408\u6CD5!"
  93 + },
  94 + upload: {
  95 + deleteTip: "\u6309 delete \u952E\u53EF\u5220\u9664",
  96 + delete: "\u5220\u9664",
  97 + preview: "\u67E5\u770B\u56FE\u7247",
  98 + continue: "\u7EE7\u7EED\u4E0A\u4F20"
  99 + },
  100 + table: {
  101 + emptyText: "\u6682\u65E0\u6570\u636E",
  102 + confirmFilter: "\u7B5B\u9009",
  103 + resetFilter: "\u91CD\u7F6E",
  104 + clearFilter: "\u5168\u90E8",
  105 + sumText: "\u5408\u8BA1"
  106 + },
  107 + tree: {
  108 + emptyText: "\u6682\u65E0\u6570\u636E"
  109 + },
  110 + transfer: {
  111 + noMatch: "\u65E0\u5339\u914D\u6570\u636E",
  112 + noData: "\u65E0\u6570\u636E",
  113 + titles: ["\u5217\u8868 1", "\u5217\u8868 2"],
  114 + filterPlaceholder: "\u8BF7\u8F93\u5165\u641C\u7D22\u5185\u5BB9",
  115 + noCheckedFormat: "\u5171 {total} \u9879",
  116 + hasCheckedFormat: "\u5DF2\u9009 {checked}/{total} \u9879"
  117 + },
  118 + image: {
  119 + error: "\u52A0\u8F7D\u5931\u8D25"
  120 + },
  121 + pageHeader: {
  122 + title: "\u8FD4\u56DE"
  123 + },
  124 + popconfirm: {
  125 + confirmButtonText: "\u786E\u5B9A",
  126 + cancelButtonText: "\u53D6\u6D88"
  127 + }
  128 + }
  129 + };
  130 +
  131 + return zhCn;
  132 +
  133 +}));
@@ -7,14 +7,15 @@ Promise.all([ @@ -7,14 +7,15 @@ Promise.all([
7 import('./script/global.js' + ver), 7 import('./script/global.js' + ver),
8 import('./script/http.js' + ver), 8 import('./script/http.js' + ver),
9 ]).then((res) => { 9 ]).then((res) => {
10 - 10 + // element plus 切换语言
  11 + // https://element-plus.org/zh-CN/guide/i18n.html#configprovider
11 // 创建vue3的实例 12 // 创建vue3的实例
12 const app = Vue.createApp(res[2].default) 13 const app = Vue.createApp(res[2].default)
13 .use(res[0].default) // 挂载vuex 14 .use(res[0].default) // 挂载vuex
14 .use(res[1].default) // 挂载路由 15 .use(res[1].default) // 挂载路由
15 16
16 .use(ElementPlus, { 17 .use(ElementPlus, {
17 - locale: ElementPlus.lang.zhCn 18 + locale: ElementPlusLocaleZhCn
18 }) 19 })
19 .use(ElementPlus) // 加载ElementPlus 20 .use(ElementPlus) // 加载ElementPlus
20 .use(vant) // 加载vant 21 .use(vant) // 加载vant
@@ -1135,6 +1135,8 @@ layui.define(['table', 'form', 'laydate', 'admin', 'layer', 'laytpl', 'common', @@ -1135,6 +1135,8 @@ layui.define(['table', 'form', 'laydate', 'admin', 'layer', 'laytpl', 'common',
1135 }); 1135 });
1136 //告警级别 1136 //告警级别
1137 form.on('select(alarmLevelSearch)', function (data) { 1137 form.on('select(alarmLevelSearch)', function (data) {
  1138 + //lsq 切换告警级别时,获取统计告警量接口的参数更改 2022-08-08
  1139 + alarmLevel = $("#alarmLevelSearchBox").val()
1138 reloadTable(); 1140 reloadTable();
1139 }); 1141 });
1140 // 告警确认 1142 // 告警确认
@@ -921,6 +921,8 @@ @@ -921,6 +921,8 @@
921 class="layui-btn layui-btn-danger layui-bg-red layui-btn-radius layui-btn-xs p-0-15 cant-click"> 921 class="layui-btn layui-btn-danger layui-bg-red layui-btn-radius layui-btn-xs p-0-15 cant-click">
922 失败 922 失败
923 </button>`; 923 </button>`;
  924 + /*lsq 连接失败时tips显示连接失败 2022-08-08*/
  925 + linkStateTips='连接失败';
924 } 926 }
925 } 927 }
926 }} 928 }}