分类计数
This commit is contained in:
parent
e6bcecd72b
commit
793e798701
105
pmcalendar.php
105
pmcalendar.php
@ -103,6 +103,15 @@ if ($act == 'newevent') {
|
|||||||
|
|
||||||
$sql = "select * from calendar where ((start>='{$startDate}' and start<='{$endDate}') or (end>='{$startDate}' and end<='{$endDate}')) {$where}";
|
$sql = "select * from calendar where ((start>='{$startDate}' and start<='{$endDate}') or (end>='{$startDate}' and end<='{$endDate}')) {$where}";
|
||||||
$rss = DB::getArray($sql);
|
$rss = DB::getArray($sql);
|
||||||
|
$eventTypeCnt = array(
|
||||||
|
'节点' => 0,
|
||||||
|
'打包' => 0,
|
||||||
|
'版本更新' => 0,
|
||||||
|
'上线' => 0,
|
||||||
|
'修复外网' => 0
|
||||||
|
|
||||||
|
|
||||||
|
);
|
||||||
$eventCount = array(
|
$eventCount = array(
|
||||||
'总更新&总修复' => array(
|
'总更新&总修复' => array(
|
||||||
'dangerCount' => 0,
|
'dangerCount' => 0,
|
||||||
@ -118,6 +127,9 @@ if ($act == 'newevent') {
|
|||||||
'purpleCount' => 0
|
'purpleCount' => 0
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
if (strstr($rs['end'], $month)) {
|
||||||
|
$eventTypeCnt[$rs['event']] += 1;
|
||||||
|
}
|
||||||
$class = "light";
|
$class = "light";
|
||||||
if ($rs['event'] == '节点') {
|
if ($rs['event'] == '节点') {
|
||||||
$class = "success";
|
$class = "success";
|
||||||
@ -191,6 +203,10 @@ if ($act == 'newevent') {
|
|||||||
if ($type == 'charts')
|
if ($type == 'charts')
|
||||||
// we(json_encode($eventCharts));
|
// we(json_encode($eventCharts));
|
||||||
we(json_encode(array('charts' => $eventCharts, 'table' => $eventTable)));
|
we(json_encode(array('charts' => $eventCharts, 'table' => $eventTable)));
|
||||||
|
elseif ($type == 'count')
|
||||||
|
{
|
||||||
|
we(json_encode($eventTypeCnt));
|
||||||
|
}
|
||||||
else
|
else
|
||||||
we(json_encode($json));
|
we(json_encode($json));
|
||||||
}
|
}
|
||||||
@ -382,6 +398,7 @@ if ($act == 'newevent') {
|
|||||||
.data_box {
|
.data_box {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
.data_tab {
|
.data_tab {
|
||||||
width: 240px;
|
width: 240px;
|
||||||
display: flex;
|
display: flex;
|
||||||
@ -392,10 +409,29 @@ if ($act == 'newevent') {
|
|||||||
z-index: 1000;
|
z-index: 1000;
|
||||||
float: right;
|
float: right;
|
||||||
}
|
}
|
||||||
.data-box { width: 50px; text-align:center; }
|
|
||||||
.data-box img { width:28px; height: 28px; margin: 0 auto; }
|
.data-box {
|
||||||
.data-box .data-name { font-size: 15px; color:#5fadff; text-align:center; }
|
width: 50px;
|
||||||
.data-box .data-num { font-size: 14px; color:#a0a0a0; text-align:center; }
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-box img {
|
||||||
|
width: 28px;
|
||||||
|
height: 28px;
|
||||||
|
margin: 0 auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-box .data-name {
|
||||||
|
font-size: 15px;
|
||||||
|
color: #5fadff;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.data-box .data-num {
|
||||||
|
font-size: 14px;
|
||||||
|
color: #a0a0a0;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
<div class='datarepair' id="datarepair" onclick="datarepair()">
|
<div class='datarepair' id="datarepair" onclick="datarepair()">
|
||||||
<img src='assets/images/xiazai.png'/> 修复数据
|
<img src='assets/images/xiazai.png'/> 修复数据
|
||||||
@ -590,14 +626,30 @@ if ($act == 'newevent') {
|
|||||||
.fujian a {
|
.fujian a {
|
||||||
color: #61adfe;
|
color: #61adfe;
|
||||||
}
|
}
|
||||||
input[type="file"] { padding: 0 14px; }
|
|
||||||
|
input[type="file"] {
|
||||||
|
padding: 0 14px;
|
||||||
|
}
|
||||||
|
|
||||||
.tijaioanniu {
|
.tijaioanniu {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
/* padding: 10px 0; */
|
/* padding: 10px 0; */
|
||||||
}
|
}
|
||||||
.tijiao { width: 60px; height: 25px; background-color:#5fadff; font-size: 14px; text-align: center; line-height: 25px; color:#fff; border-radius: 4px; float: right; cursor:pointer;}
|
|
||||||
|
.tijiao {
|
||||||
|
width: 60px;
|
||||||
|
height: 25px;
|
||||||
|
background-color: #5fadff;
|
||||||
|
font-size: 14px;
|
||||||
|
text-align: center;
|
||||||
|
line-height: 25px;
|
||||||
|
color: #fff;
|
||||||
|
border-radius: 4px;
|
||||||
|
float: right;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
<div class='popup-bg' id='popup-bg'>
|
<div class='popup-bg' id='popup-bg'>
|
||||||
<div class="yiny" id='yiny'></div>
|
<div class="yiny" id='yiny'></div>
|
||||||
@ -624,9 +676,11 @@ if ($act == 'newevent') {
|
|||||||
<div class="tijaioanniu">
|
<div class="tijaioanniu">
|
||||||
<div style=" position: relative; display: none" class="upfujian" id="upfujian_cp">
|
<div style=" position: relative; display: none" class="upfujian" id="upfujian_cp">
|
||||||
<iframe id="_hideiframe" name="_hideiframe" style="display: none;"></iframe>
|
<iframe id="_hideiframe" name="_hideiframe" style="display: none;"></iframe>
|
||||||
<form method="post" id="uploader" style="display: block; clear: both; margin-top: 10px;;" target="_hideiframe" action="" enctype="multipart/form-data">
|
<form method="post" id="uploader" style="display: block; clear: both; margin-top: 10px;;"
|
||||||
|
target="_hideiframe" action="" enctype="multipart/form-data">
|
||||||
<input name="cid" type="hidden" value="<%=DATA.lastShowCardID%>"/>
|
<input name="cid" type="hidden" value="<%=DATA.lastShowCardID%>"/>
|
||||||
<input type="file" id="fujian" name="fujian[]" multiple onchange="document.getElementById('uploader').submit()">
|
<input type="file" id="fujian" name="fujian[]" multiple
|
||||||
|
onchange="document.getElementById('uploader').submit()">
|
||||||
</form>
|
</form>
|
||||||
<div class='tijiao' id="cptijiao">提交</div>
|
<div class='tijiao' id="cptijiao">提交</div>
|
||||||
|
|
||||||
@ -659,9 +713,11 @@ if ($act == 'newevent') {
|
|||||||
<div class="tijaioanniu">
|
<div class="tijaioanniu">
|
||||||
<div style=" position: relative;display: none;" class="upfujian" id="upfujian_yy">
|
<div style=" position: relative;display: none;" class="upfujian" id="upfujian_yy">
|
||||||
<iframe id="_hideiframe2" name="_hideiframe" style="display: none;"></iframe>
|
<iframe id="_hideiframe2" name="_hideiframe" style="display: none;"></iframe>
|
||||||
<form method="post" id="uploader_yy" style="display: block; clear: both; margin-top: 10px;;" target="_hideiframe" action="" enctype="multipart/form-data">
|
<form method="post" id="uploader_yy" style="display: block; clear: both; margin-top: 10px;;"
|
||||||
|
target="_hideiframe" action="" enctype="multipart/form-data">
|
||||||
<input name="cid" type="hidden" value="<%=DATA.lastShowCardID%>"/>
|
<input name="cid" type="hidden" value="<%=DATA.lastShowCardID%>"/>
|
||||||
<input type="file" id="fujian_yy" name="fujian[]" multiple onchange="document.getElementById('uploader_yy').submit()">
|
<input type="file" id="fujian_yy" name="fujian[]" multiple
|
||||||
|
onchange="document.getElementById('uploader_yy').submit()">
|
||||||
</form>
|
</form>
|
||||||
<div class='tijiao' id="yytijiao">提交</div>
|
<div class='tijiao' id="yytijiao">提交</div>
|
||||||
</div>
|
</div>
|
||||||
@ -689,9 +745,11 @@ if ($act == 'newevent') {
|
|||||||
<div class="tijaioanniu">
|
<div class="tijaioanniu">
|
||||||
<div style=" position: relative;display: none;" class="upfujian" id="upfujian_yf">
|
<div style=" position: relative;display: none;" class="upfujian" id="upfujian_yf">
|
||||||
<iframe id="_hideiframe3" name="_hideiframe" style="display: none;"></iframe>
|
<iframe id="_hideiframe3" name="_hideiframe" style="display: none;"></iframe>
|
||||||
<form method="post" id="uploader_yf" style="display: block; clear: both; margin-top: 10px;;" target="_hideiframe" action="" enctype="multipart/form-data">
|
<form method="post" id="uploader_yf" style="display: block; clear: both; margin-top: 10px;;"
|
||||||
|
target="_hideiframe" action="" enctype="multipart/form-data">
|
||||||
<input name="cid" type="hidden" value="<%=DATA.lastShowCardID%>"/>
|
<input name="cid" type="hidden" value="<%=DATA.lastShowCardID%>"/>
|
||||||
<input type="file" id="fujian_yf" name="fujian[]" multiple onchange="document.getElementById('uploader_yf').submit()">
|
<input type="file" id="fujian_yf" name="fujian[]" multiple
|
||||||
|
onchange="document.getElementById('uploader_yf').submit()">
|
||||||
</form>
|
</form>
|
||||||
<div class='tijiao' id="yftijiao">提交</div>
|
<div class='tijiao' id="yftijiao">提交</div>
|
||||||
</div>
|
</div>
|
||||||
@ -902,6 +960,7 @@ if ($act == 'newevent') {
|
|||||||
})
|
})
|
||||||
|
|
||||||
var i = 0;
|
var i = 0;
|
||||||
|
|
||||||
function bianji() {
|
function bianji() {
|
||||||
|
|
||||||
if ("<?=$isgxyyerole?>" == "1") {
|
if ("<?=$isgxyyerole?>" == "1") {
|
||||||
@ -914,7 +973,8 @@ if ($act == 'newevent') {
|
|||||||
$("#upfujian_yy").hide();
|
$("#upfujian_yy").hide();
|
||||||
i = 0;
|
i = 0;
|
||||||
}
|
}
|
||||||
};
|
}
|
||||||
|
;
|
||||||
if ("<?=$isgxcperole?>" == "1") {
|
if ("<?=$isgxcperole?>" == "1") {
|
||||||
if (i == 0) {
|
if (i == 0) {
|
||||||
$('#cptext').attr('disabled', false)
|
$('#cptext').attr('disabled', false)
|
||||||
@ -925,7 +985,8 @@ if ($act == 'newevent') {
|
|||||||
$("#upfujian_cp").hide();
|
$("#upfujian_cp").hide();
|
||||||
i = 0;
|
i = 0;
|
||||||
}
|
}
|
||||||
};
|
}
|
||||||
|
;
|
||||||
console.log("<?=$isgxyferole?>")
|
console.log("<?=$isgxyferole?>")
|
||||||
if ("<?=$isgxyferole?>" == "1") {
|
if ("<?=$isgxyferole?>" == "1") {
|
||||||
if (i == 0) {
|
if (i == 0) {
|
||||||
@ -938,7 +999,8 @@ if ($act == 'newevent') {
|
|||||||
$("#upfujian_yf").hide();
|
$("#upfujian_yf").hide();
|
||||||
i = 0;
|
i = 0;
|
||||||
}
|
}
|
||||||
};
|
}
|
||||||
|
;
|
||||||
|
|
||||||
if ("<?=$isxfyyerole?>" == "1") {
|
if ("<?=$isxfyyerole?>" == "1") {
|
||||||
if (i == 0) {
|
if (i == 0) {
|
||||||
@ -950,7 +1012,8 @@ if ($act == 'newevent') {
|
|||||||
$("#upfujian_yy").hide();
|
$("#upfujian_yy").hide();
|
||||||
i = 0;
|
i = 0;
|
||||||
}
|
}
|
||||||
};
|
}
|
||||||
|
;
|
||||||
|
|
||||||
if ("<?=$canEdit?>" == "1") {
|
if ("<?=$canEdit?>" == "1") {
|
||||||
if (i == 0) {
|
if (i == 0) {
|
||||||
@ -966,7 +1029,8 @@ if ($act == 'newevent') {
|
|||||||
$(".upfujian").hide();
|
$(".upfujian").hide();
|
||||||
i = 0;
|
i = 0;
|
||||||
}
|
}
|
||||||
};
|
}
|
||||||
|
;
|
||||||
|
|
||||||
// $canEdit = in_array($user['name'], $ROLES);
|
// $canEdit = in_array($user['name'], $ROLES);
|
||||||
// $isgxvrole = in_array($user['name'], $GXVROLES); //更新信息查看区浏览权限
|
// $isgxvrole = in_array($user['name'], $GXVROLES); //更新信息查看区浏览权限
|
||||||
@ -1162,7 +1226,8 @@ if ($act == 'newevent') {
|
|||||||
});
|
});
|
||||||
dstr = $.fullCalendar.formatDate(calEvent.start, 'yyyy-MM-dd');
|
dstr = $.fullCalendar.formatDate(calEvent.start, 'yyyy-MM-dd');
|
||||||
showEventData(calEvent.id);
|
showEventData(calEvent.id);
|
||||||
};
|
}
|
||||||
|
;
|
||||||
} else if (calEvent.className[0] == 'label-purple') {
|
} else if (calEvent.className[0] == 'label-purple') {
|
||||||
if ("<?=$isxfvrole?>" != "1" && "<?=$isxfyyerole?>" != "1") {
|
if ("<?=$isxfvrole?>" != "1" && "<?=$isxfyyerole?>" != "1") {
|
||||||
return
|
return
|
||||||
@ -1188,14 +1253,14 @@ if ($act == 'newevent') {
|
|||||||
});
|
});
|
||||||
dstr = $.fullCalendar.formatDate(calEvent.start, 'yyyy-MM-dd');
|
dstr = $.fullCalendar.formatDate(calEvent.start, 'yyyy-MM-dd');
|
||||||
showEventData(calEvent.id);
|
showEventData(calEvent.id);
|
||||||
};
|
}
|
||||||
|
;
|
||||||
} else {
|
} else {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
$('#uploader').attr('action', './?app=uploader&id=' + calEvent.id + '&bumen=chanpin&act=add');
|
$('#uploader').attr('action', './?app=uploader&id=' + calEvent.id + '&bumen=chanpin&act=add');
|
||||||
$('#uploader_yy').attr('action', './?app=uploader&id=' + calEvent.id + '&bumen=yunyig&act=add')
|
$('#uploader_yy').attr('action', './?app=uploader&id=' + calEvent.id + '&bumen=yunyig&act=add')
|
||||||
$("#uploader_yf").attr('action', './?app=uploader&id=' + calEvent.id + '&bumen=yanfa&act=add')
|
$("#uploader_yf").attr('action', './?app=uploader&id=' + calEvent.id + '&bumen=yanfa&act=add')
|
||||||
|
Loading…
Reference in New Issue
Block a user