sysIndex.jsp
19.9 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<%@page import="java.util.*"%>
<html>
<head>
<style type="text/css">
#winpop { width:180px; height:0px; position:absolute; right:0;bottom:0; border:1px solid grey; margin:0; padding:0px; overflow:hidden; display:none; background:#FFFFFF}
#winpop .title { width:100%; height:30px; line-height:200%; background:#436EEE ; font-weight:bold; text-align:center; font-size:14px;color:white}
#winpop .con { width:100px;; height:360px; line-height:80px; font-weight:bold; font-size:12px; color:#FF0000; text-decoration:underline; text-align:center}.close { position:absolute; right:2px; top:3px; color:white; font-size:14px;cursor:pointer}
</style>
<%
//未读消息unreadList根据实际情况取
List<Map> unreadList = new ArrayList<Map>();
Map<String,String> map1=new HashMap<String,String>();
map1.put("msgId","1");
map1.put("msgContent"," 您有新的已审核或未通过的消息,请注意查收!!!");
unreadList.add(map1);
int num=1;
%>
<title>${fns:getConfig('productName')}</title>
<meta name="decorator" content="blank"/><c:set var="tabmode" value="${empty cookie.tabmode.value ? '1' : cookie.tabmode.value}"/>
<c:if test="${tabmode eq '1'}"><link rel="Stylesheet" href="${ctxStatic}/jerichotab/css/jquery.jerichotab.css" />
<script type="text/javascript" src="${ctxStatic}/jerichotab/js/jquery.jerichotab.js"></script></c:if>
<style type="text/css">
.helptb{position:fixed;width:30px;height:30px;}
.helptb img {opacity:0.3;filter:alpha(opacity=30);width:100%;height:100%;}
.helptb img:hover{opacity:1.0;filter:alpha(opacity=100);}
#main {padding:0;margin:0;} #main .container-fluid{padding:0 4px 0 6px;}
#header {margin:0 0 8px;position:static;} #header li {font-size:14px;_font-size:12px;}
#header .brand {font-family:Helvetica, Georgia, Arial, sans-serif, 黑体;font-size:26px;padding-left:33px;}
#footer {margin:8px 0 0 0;padding:3px 0 0 0;font-size:11px;text-align:center;border-top:2px solid #0663A2;}
#footer, #footer a {color:#999;} #left{overflow-x:hidden;overflow-y:auto;} #left .collapse{position:static;}
#userControl>li>a{/*color:#fff;*/text-shadow:none;} #userControl>li>a:hover, #user #userControl>li.open>a{background:transparent;}
</style>
<script type="text/javascript">
$(document).ready(function() {
// <c:if test="${tabmode eq '1'}"> 初始化页签
$.fn.initJerichoTab({
renderTo: '#right', uniqueId: 'jerichotab',
contentCss: { 'height': $('#right').height() - tabTitleHeight },
tabs: [], loadOnce: true, tabWidth: 110, titleHeight: tabTitleHeight
});//</c:if>
// 绑定菜单单击事件
$("#menu a.menu").click(function(){
// 一级菜单焦点
$("#menu li.menu").removeClass("active");
$(this).parent().addClass("active");
// 左侧区域隐藏
if ($(this).attr("target") == "mainFrame"){
$("#left,#openClose").hide();
wSizeWidth();
// <c:if test="${tabmode eq '1'}"> 隐藏页签
$(".jericho_tab").hide();
$("#mainFrame").show();//</c:if>
return true;
}
// 左侧区域显示
$("#left,#openClose").show();
if(!$("#openClose").hasClass("close")){
$("#openClose").click();
}
// 显示二级菜单
var menuId = "#menu-" + $(this).attr("data-id");
if ($(menuId).length > 0){
$("#left .accordion").hide();
$(menuId).show();
// 初始化点击第一个二级菜单
if (!$(menuId + " .accordion-body:first").hasClass('in')){
$(menuId + " .accordion-heading:first a").click();
}
if (!$(menuId + " .accordion-body li:first ul:first").is(":visible")){
$(menuId + " .accordion-body a:first i").click();
}
// 初始化点击第一个三级菜单
$(menuId + " .accordion-body li:first li:first a:first i").click();
}else{
// 获取二级菜单数据
$.get($(this).attr("data-href"), function(data){
if (data.indexOf("id=\"loginForm\"") != -1){
alert('账号已在其它地方登录或登录超时。请重新登录,谢谢!');
top.location = "${ctx}";
return false;
}
$("#left .accordion").hide();
$("#left").append(data);
// 链接去掉虚框
$(menuId + " a").bind("focus",function() {
if(this.blur) {this.blur()};
});
// 二级标题
$(menuId + " .accordion-heading a").click(function(){
$(menuId + " .accordion-toggle i").removeClass('icon-chevron-down').addClass('icon-chevron-right');
if(!$($(this).attr('data-href')).hasClass('in')){
$(this).children("i").removeClass('icon-chevron-right').addClass('icon-chevron-down');
}
});
// 二级内容
$(menuId + " .accordion-body a").click(function(){
$(menuId + " li").removeClass("active");
$(menuId + " li i").removeClass("icon-white");
$(this).parent().addClass("active");
$(this).children("i").addClass("icon-white");
});
// 展现三级
$(menuId + " .accordion-inner a").click(function(){
var href = $(this).attr("data-href");
if($(href).length > 0){
$(href).toggle().parent().toggle();
return false;
}
// <c:if test="${tabmode eq '1'}"> 打开显示页签
return addTab($(this)); // </c:if>
});
// 默认选中第一个菜单
$(menuId + " .accordion-body a:first i").click();
$(menuId + " .accordion-body li:first li:first a:first i").click();
});
}
// 大小宽度调整
wSizeWidth();
return false;
});
// 初始化点击第一个一级菜单
$("#menu a.menu:first span").click();
// <c:if test="${tabmode eq '1'}"> 下拉菜单以选项卡方式打开
$("#userInfo .dropdown-menu a").mouseup(function(){
return addTab($(this), true);
});// </c:if>
// 鼠标移动到边界自动弹出左侧菜单
$("#openClose").mouseover(function(){
if($(this).hasClass("open")){
$(this).click();
}
});
// 获取通知数目 <c:set var="oaNotifyRemindInterval" value="${fns:getConfig('oa.notify.remind.interval')}"/>
function getNotifyNum(){
$.get("${ctx}/oa/oaNotify/self/count?updateSession=0&t="+new Date().getTime(),function(data){
var num = parseFloat(data);
if (num > 0){
$("#notifyNum,#notifyNum2").show().html("("+num+")");
}else{
$("#notifyNum,#notifyNum2").hide()
}
});
}
getNotifyNum(); //<c:if test="${oaNotifyRemindInterval ne '' && oaNotifyRemindInterval ne '0'}">
setInterval(getNotifyNum, ${oaNotifyRemindInterval}); //</c:if>
document.getElementById('winpop').style.height = '0px';//要初始化这个高度,虽然CSS里已经初始化了
var qxdm = "${qxdm}";
if(qxdm == "610702"){
setTimeout("queryperson();",10000);
}
});
// <c:if test="${tabmode eq '1'}"> 添加一个页签
function addTab($this, refresh){
$(".jericho_tab").show();
$("#mainFrame").hide();
$.fn.jerichoTab.addTab({
tabFirer: $this,
title: $this.text(),
closeable: true,
data: {
dataType: 'iframe',
dataLink: $this.attr('href')
}
}).loadData(refresh);
return false;
}// </c:if>
function queryperson() {
var qxdm = "${qxdm}";
if(qxdm == "610702"){
setInterval("queryinfozy()",580000);
}
}
function queryinfozy() {
var qxdm = "${qxdm}";
if(qxdm == "610702"){
$.ajax({
type:"POST",
url:"${ctx}/reg/bus/kc01/queryinfory",
cache: false,
data:"",
async:false,
success:function(modelmap){
success = modelmap.success;
if(success == 0){
tips_pop();
}
}
});
}
}
function querykc01list(dj) {
//弹出窗口的宽度;
var iWidth=1000;
//弹出窗口的高度;
var iHeight=400;
//获得窗口的垂直位置
var iTop = (window.screen.height - 30 - iHeight) / 2;
//获得窗口的水平位置
var iLeft = (window.screen.width - 10 - iWidth) / 2;
var url = "${ctx}/reg/bus/kc01/list?dj="+dj;
window.open(url, "查询信息", "width=" + iWidth + ", height=" + iHeight + ",top=" + iTop + ",left=" + iLeft + ",toolbar=no, menubar=no, scrollbars=yes, resizable=no,location=no, status=no,alwaysRaised=yes,depended=yes");
setInterval("changeH('down')", 10);
}
//弹出提示框
function tips_pop() {
var MsgPop = document.getElementById("winpop");//获取窗口这个对象,即ID为winpop的对象
var popH = parseInt(MsgPop.style.height);//用parseInt将对象的高度转化为数字,以方便下面比较
if (popH == 0) { //如果窗口的高度是0
MsgPop.style.display = "block";//那么将隐藏的窗口显示出来
show = setInterval("changeH('up')", 40);//开始以每0.030秒调用函数changeH("up"),即每0.030秒向上移动一次
} else { //否则
hide = setInterval("changeH('down')", 10);//开始以每0.030秒调用函数changeH("down"),即每0.030秒向下移动一次
}
}
//变化高度
function changeH(str) {
var MsgPop = document.getElementById("winpop");
var popH = parseInt(MsgPop.style.height);
if (str == "up") { //如果这个参数是UP
if (popH <= 100) { //如果转化为数值的高度小于等于100、这里调整窗口高度
MsgPop.style.height = (popH + 4).toString() + "px";//高度增加4个象素
} else {
clearInterval(show);//否则就取消这个函数调用,意思就是如果高度超过100象度了,就不再增长了
}
}
if (str == "down") {
if (popH >= 4) { //如果这个参数是down
MsgPop.style.height = (popH - 4).toString() + "px";//那么窗口的高度减少4个象素
} else { //否则
clearInterval(hide); //否则就取消这个函数调用,意思就是如果高度小于4个象度的时候,就不再减了
MsgPop.style.display = "none"; //因为窗口有边框,所以还是可以看见1~2象素没缩进去,这时候就把DIV隐藏掉
}
}
}
</script>
</head>
<body>
<script type="text/javascript">
history.pushState(null, null, document.URL);
window.addEventListener('popstate', function () {
history.pushState(null, null, document.URL);
});
</script>
<div id="main">
<div id="header" class="navbar navbar-fixed-top">
<div class="navbar-inner">
<div class="brand"><span id="productName"><font size="5" face="Arial, Helvetica">数驰不动产登记管理平台</font></span></div>
<ul id="userControl" class="nav pull-right">
<!-- <li><a href="www.baidu.com" target="_blank" title="访问网站主页"><i class="icon-home"></i></a></li> -->
<li id="themeSwitch" class="dropdown">
<a class="dropdown-toggle" data-toggle="dropdown" href="#" title="主题切换"><i class="icon-th-large"></i></a>
<ul class="dropdown-menu">
<c:forEach items="${fns:getDictList('theme')}" var="dict"><li><a href="#" onclick="location='${pageContext.request.contextPath}/theme/${dict.value}?url='+location.href">${dict.label}</a></li></c:forEach>
<li><a href="javascript:cookie('tabmode','${tabmode eq '1' ? '0' : '1'}');location=location.href">${tabmode eq '1' ? '关闭' : '开启'}页签模式</a></li>
</ul>
<!--[if lte IE 6]><script type="text/javascript">$('#themeSwitch').hide();</script><![endif]-->
</li>
<li id="userInfo" class="dropdown">
<a class="dropdown-toggle" data-toggle="dropdown" href="#" title="个人信息">您好,${userType}:${fns:getUser().loginName} <span style="color:yellow;font-size: 13px;" id="notifyNum" class="label label-info hide"></span>
</a>
<ul class="dropdown-menu">
<li><a href="${ctx}/sys/user/info" target="mainFrame"><i class="icon-user"></i> 个人信息</a></li>
<li><a href="${ctx}/sys/user/modifyPwd" target="mainFame"><i class="icon-lock"></i> 修改密码</a></li>
<li><a href="${ctx}/oa/oaNotify/self" target="mainFrame"><i class="icon-bell"></i> 我的通知 <span span style="color:yellow;font-size: 13px;" id="notifyNum2" class="label label-info hide"></span></a></li>
<li><a href="${ctx}/reg/helpFileDownload" target="mainFrame"><i class="icon-bell"></i> 帮助手册</a></li>
</ul>
</li>
<li><a href="${ctx}/logout" title="退出登录">退出</a></li>
<li> </li>
</ul>
<%-- <c:if test="${cookie.theme.value eq 'cerulean'}">
<div id="user" style="position:absolute;top:0;right:0;"></div>
<div id="logo" style="background:url(${ctxStatic}/images/logo_bg.jpg) right repeat-x;width:100%;">
<div style="background:url(${ctxStatic}/images/logo.jpg) left no-repeat;width:100%;height:70px;"></div>
</div>
<script type="text/javascript">
$("#productName").hide();$("#user").html($("#userControl"));$("#header").prepend($("#user, #logo"));
</script>
</c:if> --%>
<div class="nav-collapse">
<ul id="menu" class="nav" style="*white-space:nowrap;float:none;">
<c:set var="firstMenu" value="true"/>
<c:forEach items="${fns:getMenuList()}" var="menu" varStatus="idxStatus">
<c:if test="${menu.parent.id eq '1'&&menu.isShow eq '1'}">
<li class="menu ${not empty firstMenu && firstMenu ? ' active' : ''}">
<c:if test="${empty menu.href}">
<a class="menu" href="javascript:" data-href="${ctx}/sys/menu/tree?parentId=${menu.id}" data-id="${menu.id}"><span>${menu.name}</span></a>
</c:if>
<c:if test="${not empty menu.href}">
<a class="menu" href="${fn:indexOf(menu.href, '://') eq -1 ? ctx : ''}${menu.href}" data-id="${menu.id}" target="mainFrame"><span>${menu.name}</span></a>
</c:if>
</li>
<c:if test="${firstMenu}">
<c:set var="firstMenuId" value="${menu.id}"/>
</c:if>
<c:set var="firstMenu" value="false"/>
</c:if>
</c:forEach><%--
<shiro:hasPermission name="cms:site:select">
<li class="dropdown">
<a class="dropdown-toggle" data-toggle="dropdown" href="#">${fnc:getSite(fnc:getCurrentSiteId()).name}<b class="caret"></b></a>
<ul class="dropdown-menu">
<c:forEach items="${fnc:getSiteList()}" var="site"><li><a href="${ctx}/cms/site/select?id=${site.id}&flag=1">${site.name}</a></li></c:forEach>
</ul>
</li>
</shiro:hasPermission> --%>
</ul>
</div><!--/.nav-collapse -->
</div>
</div>
<!-- <div id="helpbj" class="helptb"> -->
<%-- <a href="#"><img src="${ctxStatic}/images/helptb.png"/></a> --%>
<!-- </div> -->
<div class="container-fluid">
<div id="content" class="row-fluid">
<div id="left"><%--
<iframe id="menuFrame" name="menuFrame" src="" style="overflow:visible;" scrolling="yes" frameborder="no" width="100%" height="650"></iframe> --%>
</div>
<div id="openClose" class="close"> </div>
<div id="right">
<iframe id="mainFrame" name="mainFrame" src="" style="overflow:visible;" scrolling="yes" frameborder="no" width="100%" height="650"></iframe>
</div>
</div>
<div id="footer" class="row-fluid">
Copyright © 2015-${fns:getConfig('copyrightYear')} 西安数驰信息科技有限公司 - Powered By <a href="#" target="_blank">ODM</a> ${fns:getConfig('version')}
</div>
</div>
</div>
<script type="text/javascript">
var leftWidth = 160; // 左侧窗口大小
var tabTitleHeight = 33; // 页签的高度
var htmlObj = $("html"), mainObj = $("#main");
var headerObj = $("#header"), footerObj = $("#footer");
var frameObj = $("#left, #openClose, #right, #right iframe");
function wSize(){
var minHeight = 500, minWidth = 980;
var strs = getWindowSize().toString().split(",");
htmlObj.css({"overflow-x":strs[1] < minWidth ? "auto" : "hidden", "overflow-y":strs[0] < minHeight ? "auto" : "hidden"});
mainObj.css("width",strs[1] < minWidth ? minWidth - 10 : "auto");
frameObj.height((strs[0] < minHeight ? minHeight : strs[0]) - headerObj.height() - footerObj.height() - (strs[1] < minWidth ? 42 : 28));
$("#openClose").height($("#openClose").height() - 5);// <c:if test="${tabmode eq '1'}">
$(".jericho_tab iframe").height($("#right").height() - tabTitleHeight); // </c:if>
wSizeWidth();
}
function wSizeWidth(){
if (!$("#openClose").is(":hidden")){
var leftWidth = ($("#left").width() < 0 ? 0 : $("#left").width());
$("#right").width($("#content").width()- leftWidth - $("#openClose").width() -5);
}else{
$("#right").width("100%");
}
}// <c:if test="${tabmode eq '1'}">
function openCloseClickCallBack(b){
$.fn.jerichoTab.resize();
} // </c:if>
//可拖动功能
// //以下属性先不用管,等我们在下面定义方法的时候,需要用到什么属性,在来定义全局变量(属性)就可以了
// var startX;
// var startY;
// var moveSwitch = false;
// var currentLeft;
// var currentTop;
// var loginTag = document.getElementById("helpbj");
// function move(e){ //定义一个方法,用来捕捉鼠标的坐标位置
// if(moveSwitch){ //类似于if(true);
// var x = e.clientX; //e.clientX是一个触摸事件,即是鼠标点击时的X轴上的坐标
// var y = e.clientY; //e.clientY是一个触摸事件,即是鼠标点击时的Y轴上的坐标
// var distanceX = x-startX; //X轴上获得移动的实际距离
// var distanceY = y-startY; //Y轴上获得移动的实际距离
// loginTag.style.left = (distanceX+currentLeft)+"px"; //currentLeft下面的方法会有解释,需要注意最后要添加PX单位,如果给left赋值会破坏文档流,不加单位就会无效
// loginTag.style.top = (distanceY+currentTop)+"px"; //
// }
// }
// function mouseDown(e){ //鼠标按下事件
// e = e?e:window.event; //因为兼容问题,event可能在隐藏参数中,如果隐藏参数没有event事件,则可以使用全局的事件window.event(大家记住写法就可以了)
// moveSwitch = true;
// startX = e.clientX;
// startY = e.clientY;
// currentLeft = loginTag.offsetLeft; //通过对象获取对象的坐标
// currentTop = loginTag.offsetTop;
// }
// function mouseUp(){
// moveSwitch = false;
// }
// document.addEventListener('mousedown',mouseDown);
// document.addEventListener('mousemove',move);
// document.addEventListener('mouseup',mouseUp);
</script>
<script src="${ctxStatic}/common/wsize.min.js" type="text/javascript"></script>
<%if(num>0){ %>
<div id="winpop">
<div class="title" > 系 统 信 息 <br>
<span class="close" onclick="tips_pop()">关闭</span></div>
<%for(int i=0;i<num;i++) { %>
<!-- 点击信息标题链接到信息明细,传递信息编号参数 -->
<a href="#" onclick="querykc01list('1');" >
<%if(String.valueOf(unreadList.get(0).get("msgContent")).length()>16) {%>
<%=String.valueOf(unreadList.get(0).get("msgContent")) %>
<%} else{ %>
<%=String.valueOf(unreadList.get(0).get("msgContent")) %>
<%} %>
</a><br>
<%
if(i>=1){//最多显示两条
break;
}
} %>
</div>
<%} %>
</body>
</html>