대시보드 관리자 로그관리 성능개선
This commit is contained in:
parent
aadc3c1420
commit
3ce5a0890b
@ -286,6 +286,7 @@ public class EgovMainController {
|
||||
model.addAttribute("adminMainYdaBoardCnt", adminMainYdaBoardCnt);
|
||||
}
|
||||
{// 관리자 로그관리 리스트
|
||||
/*
|
||||
LoginLog loginLog = new LoginLog();
|
||||
//0번째 부터 6개의 항목만 조회
|
||||
loginLog.setFirstIndex(0);
|
||||
@ -295,6 +296,7 @@ public class EgovMainController {
|
||||
loginLog.setSearchSortOrd("desc");
|
||||
List<LoginLog> adminLogList = loginLogService.selectAmdinLog(loginLog);
|
||||
model.addAttribute("adminLogList", adminLogList);
|
||||
*/
|
||||
}
|
||||
|
||||
// 2023.01.11 JSPark => 사용안하는 데이터로 판단되어 주석처리
|
||||
@ -836,6 +838,41 @@ public class EgovMainController {
|
||||
return modelAndView;
|
||||
}
|
||||
|
||||
// 관리자 로그관리 리스트
|
||||
@RequestMapping(value = "/cmm/main/selectDashBoardAdminLogAjax.do")
|
||||
public ModelAndView DashBoardAdminLogAjax(
|
||||
@ModelAttribute("statsVO") StatsVO statsVO) throws Exception {
|
||||
|
||||
ModelAndView modelAndView = new ModelAndView();
|
||||
modelAndView.setViewName("jsonView");
|
||||
|
||||
boolean isSuccess = true;
|
||||
String msg = "";
|
||||
List<LoginLog> adminLogList = null;
|
||||
|
||||
try {
|
||||
|
||||
LoginLog loginLog = new LoginLog();
|
||||
//0번째 부터 6개의 항목만 조회
|
||||
loginLog.setFirstIndex(0);
|
||||
loginLog.setRecordCountPerPage(5);
|
||||
// 최신날짜 우선순위 조회
|
||||
loginLog.setSearchSortCnd("creatDt");
|
||||
loginLog.setSearchSortOrd("desc");
|
||||
adminLogList = loginLogService.selectAmdinLog(loginLog);
|
||||
}
|
||||
catch(Exception e) {
|
||||
isSuccess = false;
|
||||
msg = e.getMessage();
|
||||
}
|
||||
|
||||
modelAndView.addObject("adminLogList", adminLogList);
|
||||
modelAndView.addObject("isSuccess", isSuccess);
|
||||
modelAndView.addObject("msg", msg);
|
||||
|
||||
return modelAndView;
|
||||
}
|
||||
|
||||
/**
|
||||
* Head메뉴를 조회한다.
|
||||
* @param menuManageVO MenuManageVO
|
||||
|
||||
@ -84,11 +84,15 @@
|
||||
$(".listType1").children(":first").remove(); //헤더 회원정보변경 삭제
|
||||
}
|
||||
|
||||
// 대시보드 회원통계 Info
|
||||
getDashBoardMemStatInfo();
|
||||
|
||||
// 관리자 로그관리
|
||||
getDashBoardAdminLog();
|
||||
|
||||
// 당월 회원전환률
|
||||
getMemLoginThisMonthRate();
|
||||
|
||||
// 대시보드 회원통계 Info
|
||||
getDashBoardMemStatInfo();
|
||||
});
|
||||
|
||||
// 모바일에서 회원 차트 Heigth 변경
|
||||
@ -233,8 +237,6 @@
|
||||
|
||||
// 대시보드 회원통계 Info
|
||||
function getDashBoardMemStatInfo() {
|
||||
$("#memLoginThisMonth").html("");
|
||||
|
||||
$.ajax({
|
||||
type: "POST",
|
||||
url: "/cmm/main/selectDashBoardMemStatInfoAjax.do",
|
||||
@ -267,6 +269,45 @@
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
// 관리자 로그관리
|
||||
function getDashBoardAdminLog() {
|
||||
$("#adminLogList").html("");
|
||||
|
||||
$.ajax({
|
||||
type: "POST",
|
||||
url: "/cmm/main/selectDashBoardAdminLogAjax.do",
|
||||
data: {},
|
||||
dataType:'json',
|
||||
async: true,
|
||||
success: function (data) {
|
||||
var jsonList = data.adminLogList;
|
||||
if (data.isSuccess) {
|
||||
try {
|
||||
var sHtml = "";
|
||||
jsonList.forEach (function (item, idx) {
|
||||
sHtml += "<tr>";
|
||||
sHtml += " <td title='" + item.creatDt + "'>" + item.creatDt.substr(5, 11) + "</td>";
|
||||
sHtml += " <td title='" + item.loginIp + "'>" + item.loginIp + "</td>";
|
||||
sHtml += " <td title='" + item.menuNm + "'>" + item.menuNm + "</td>";
|
||||
sHtml += " <td title='" + item.loginId + "'>" + item.loginId + "</td>";
|
||||
sHtml += "</tr>";
|
||||
});
|
||||
|
||||
$("#adminLogList").html(sHtml);
|
||||
} catch (error) {
|
||||
console.error(error);
|
||||
}
|
||||
}
|
||||
else {
|
||||
//alert("Msg : " + data.msg);
|
||||
}
|
||||
},
|
||||
error: function (e) {
|
||||
//alert("ERROR : " + JSON.stringify(e));
|
||||
}
|
||||
});
|
||||
}
|
||||
</script>
|
||||
<style type="text/css">
|
||||
.inline .tType6 {line-height:18px;}
|
||||
@ -794,26 +835,11 @@
|
||||
<colgroup>
|
||||
<col style="width: *%">
|
||||
<col style="width: 27%">
|
||||
<col style="width: 29%">
|
||||
<col style="width: 28%">
|
||||
<col style="width: 15%">
|
||||
</colgroup>
|
||||
<c:forEach items="${adminLogList}" var="adminLogInfo">
|
||||
<tr>
|
||||
<td title="<c:out value="${adminLogInfo.creatDt}"/>">
|
||||
<fmt:parseDate value="${adminLogInfo.creatDt}" var="creatDateValue" pattern="yyyy-MM-dd HH:mm"/>
|
||||
<fmt:formatDate value="${creatDateValue}" pattern="MM-dd HH:mm"/>
|
||||
</td>
|
||||
<td title="<c:out value="${adminLogInfo.loginIp}"/>">
|
||||
<c:out value="${adminLogInfo.loginIp}"/>
|
||||
</td>
|
||||
<td title="<c:out value="${adminLogInfo.menuNm}"/>">
|
||||
<c:out value="${adminLogInfo.menuNm}"/>
|
||||
</td>
|
||||
<td title="<c:out value="${adminLogInfo.loginId}"/>">
|
||||
<c:out value="${adminLogInfo.loginId}"/>
|
||||
</td>
|
||||
</tr>
|
||||
</c:forEach>
|
||||
<tbody id="adminLogList">
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user