1
|
<!DOCTYPE html>
|
2
|
<html>
|
3
|
<head lang="en">
|
4
|
<meta charset="GB2312">
|
5
|
<title></title>
|
6
|
<link href="css/style.css" title="style" rel="stylesheet" type="text/css" />
|
7
|
<link rel="stylesheet" type="text/css" href="css/jquery-ui.css" />
|
8
|
<script src="js/jquery-1.6.3.min.js"></script>
|
9
|
<script type="text/javascript" src="js/jquery-ui-datepicker.js"></script>
|
10
|
|
11
|
</head>
|
12
|
<body class="you_bd" style="width:95%">
|
13
|
<div >
|
14
|
<div style="margin: 10px;margin-top: 15px; width:100%">
|
15
|
<span>ѡ???ѯ????:</span> <span>??ʼ <input type="text" id="date_3" value="" /></span>
|
16
|
<span>???? <input type="text" id="date_4" value="" /></span>
|
17
|
<span> ???
|
18
|
<select id="lsKind">
|
19
|
<option value="all">ȫ??</option>
|
20
|
<option value="1">?е?</option>
|
21
|
<option value="2">???</option>
|
22
|
<option value="3">UPS</option>
|
23
|
<option value="4">????</option>
|
24
|
<option value="5">??ʪ??</option>
|
25
|
<option value="6">©ˮ</option>
|
26
|
<option value="7">?յ?</option>
|
27
|
<option value="8">???ܿյ?</option>
|
28
|
<option value="13">IC?Ž?</option>
|
29
|
</select></span>
|
30
|
<span><input type="button" id="btn_qry" class="dateBtn2" value="??ѯ"></span>
|
31
|
<span> <input type="button" id="btn_save" value="???浽excel" onclick="saveToExcel('almList')"></span>
|
32
|
</div>
|
33
|
<span class="hide" style="text-align: center;margin-left: 200px;" ><img src="img/loding.gif" ><span>???ڲ?ѯ???ݿ?....</span></span>
|
34
|
<div id="container3" style="width:100%;min-height: 500px;overflow: auto"></div>
|
35
|
<div style="position: fixed;left: 30px;top: 50px;" class="hide">
|
36
|
<img src="img/ico_guanbi.png" class="btn_img_guanbi" style="position: absolute;right: 5px;top: 5px;cursor:pointer">
|
37
|
<img id="AlmImg" src="img/loginBG.jpg" width="640" height="480" style="box-shadow: 8px 5px 5px #888888;">
|
38
|
</div>
|
39
|
</div>
|
40
|
<a href='javascript:history.back()' class='back' style='color: #fff'>????</a>
|
41
|
<script>
|
42
|
function saveToExcel(tableid){
|
43
|
var curTbl = document.getElementById(tableid);
|
44
|
var oXL= new ActiveXObject("Excel.Application");
|
45
|
var oWB= oXL.Workbooks.Add();
|
46
|
var oSheet = oWB.ActiveSheet;
|
47
|
var sel= document.body.createTextRange();
|
48
|
sel.moveToElementText(curTbl);
|
49
|
sel.select();
|
50
|
sel.execCommand("Copy");
|
51
|
oSheet.Paste();
|
52
|
oXL.Visible = true;
|
53
|
}
|
54
|
$(".almbtn").live("click",function(){
|
55
|
var src=$(this).attr("op");
|
56
|
$("#AlmImg").attr("src",src);
|
57
|
$(".Almimg").fadeToggle();
|
58
|
});
|
59
|
$(".btn_img_guanbi").click(function(){
|
60
|
$(".Almimg").fadeOut()
|
61
|
});
|
62
|
$("#date_3").datepicker();
|
63
|
$("#date_3").focus();
|
64
|
$("#date_4").datepicker();
|
65
|
$(".dateBtn2").click(function(){
|
66
|
index=1;
|
67
|
dataarr=[];
|
68
|
dataarr2=[];
|
69
|
datatime=[];
|
70
|
var sDate=$("#date_3").val();
|
71
|
var eDate=$("#date_4").val();
|
72
|
var sArr = sDate.split("-");
|
73
|
var eArr = eDate.split("-");
|
74
|
var sRDate = new Date(sArr[0], sArr[1], sArr[2]);
|
75
|
var eRDate = new Date(eArr[0], eArr[1], eArr[2]);
|
76
|
var result = (eRDate-sRDate)/(24*60*60*1000);
|
77
|
if(result>10){
|
78
|
alert("???ֻ?ܲ?ѯ10?????ڵ????ݣ?");
|
79
|
return false
|
80
|
}
|
81
|
if(sDate==""||eDate==""||sDate>eDate){
|
82
|
alert("????????ȷ?IJ?ѯʱ?䣡");
|
83
|
return false
|
84
|
}
|
85
|
var usel=document.getElementById('lsKind');
|
86
|
var uselidx=usel.selectedIndex;
|
87
|
var skind = usel.options[uselidx].value;
|
88
|
$.ajax({
|
89
|
type: "POST",
|
90
|
url: "../omdev/smalarm.asp",
|
91
|
data: "starttime="+sDate+"&endtime="+eDate+"&kind="+skind,
|
92
|
dataType: "json",
|
93
|
beforeSend: function() {
|
94
|
$(".dateBtn").attr('disabled', 'disabled');
|
95
|
$(".lond").show();
|
96
|
},
|
97
|
complete: function() {
|
98
|
$(".lond").hide();
|
99
|
$(".dateBtn").removeAttr("disabled");
|
100
|
},
|
101
|
success: function(msg){
|
102
|
var data=msg;
|
103
|
var q='';
|
104
|
$.each(data.recs,function(i,n){
|
105
|
var name='δ֪';var note='?澯';var mask='';var recv='';
|
106
|
var kind=(n.Type>>8);
|
107
|
if(kind==0x01) name="?е?";
|
108
|
else if(kind==0x02) name="???";
|
109
|
else if(kind==0x03) name="UPS";
|
110
|
else if(kind==0x04) name="????";
|
111
|
else if(kind==0x05) name="??ʪ??";
|
112
|
else if(kind==0x06) name="©ˮ";
|
113
|
else if(kind==0x07) name="?յ?";
|
114
|
else if(kind==0x08) name="???ܿյ?";
|
115
|
else if(kind==0x09) name="??????";
|
116
|
else if(kind==0x0a) name="??????";
|
117
|
else if(kind==0x0b) name="??ʾ??";
|
118
|
else if(kind==0x0c) name="?????Ƶ";
|
119
|
else if(kind==0x0d) name="IC?Ž?";
|
120
|
else if(n.Type<16){
|
121
|
if(n.Type==6) name="©ˮ???";
|
122
|
else if(n.Type==5) name="??ʪ??";
|
123
|
else if(n.Type==9) name="?̸?";
|
124
|
else if(n.Type==10) name="????";
|
125
|
}
|
126
|
if(n.Alm&4){note+=" ???"}
|
127
|
if(n.Alm&8){note+=" ?ط?"}
|
128
|
if(n.Alm&16){note+=" ????"}
|
129
|
if(n.Alm&0xf00){note+=" δ????"}
|
130
|
if(n.AlmMask&1){mask+=" ????"}
|
131
|
if(n.AlmMask&2){mask+=" ????"}
|
132
|
if(n.AlmMask&4){mask+=" ????"}
|
133
|
if(n.AlmMask&8){mask+=" ????"}
|
134
|
if(n.AlmMask&0x10){mask+=" ?绰"}
|
135
|
if(n.AlmMask&0x20){mask+=" ?ʼ?"}
|
136
|
if(n.AlmMask&0x40){mask+=" POST"}
|
137
|
if(n.AlmMask&0x100){mask+=" ????1"}
|
138
|
if(n.AlmMask&0x200){mask+=" ????2"}
|
139
|
for (var x=0; x<16; x++)
|
140
|
if ((n.AlmRecv & (1 << x))>0) recv+=" #"+(x+1);
|
141
|
if(n.AlmMask&0x40){mask+=" POST"}
|
142
|
if(i==0){
|
143
|
q+="<div style='overflow: auto;height: 500px;'>";
|
144
|
q+="<table id='almList' width='100%' style='border: #B0B7BF 1px solid'>";
|
145
|
q+="<tr><td style='width: 200px;'>????ʱ??</td><td>????ԭ??</td><td>??????ʽ</td><td>????????</td><td style='width: 100px;'>???</td><td style='width: 200px;'>????????</td><td style='width: 50px;'>SID</td><td style='width: 50px;'>AID</td><td style='width: 40px;'>??ͼ</td></tr>";
|
146
|
}
|
147
|
q+="<tr><td>"+n.LastUpd+"</td><td>"+note+"</td><td>"+mask+"</td><td>"+recv+"</td><td>"+name+"</td><td>"+n.AlmBrief+"</td><td>"+n.SID+"</td><td>"+n.AID+"</td><td>";
|
148
|
if( n.AlmImg!=undefined && n.AlmImg.length>2 ){
|
149
|
var istart=n.AlmImg.indexOf('wwwpub');
|
150
|
if (istart>=0) n.AlmImg=n.AlmImg.substring(istart+7);
|
151
|
q+="<span><img src='img/ico_img.png' op='"+ n.AlmImg+"' class='almbtn'></span>";
|
152
|
}
|
153
|
q+="</td></tr>";
|
154
|
});
|
155
|
$("#container3").html(q);
|
156
|
}
|
157
|
});
|
158
|
});
|
159
|
|
160
|
</script>
|
161
|
</body>
|
162
|
</html>
|