개인정보 로그현황 페이지네이션 관련 소스 수정
parent
4d4cb60413
commit
5cd1c3148d
|
|
@ -36,7 +36,7 @@ function EgovPaging({pagination, moveToPage}) {
|
|||
}
|
||||
if(pagination.endNum!=pagination.maxNum){
|
||||
// 다음 페이지 이동
|
||||
const nextPageIndex = pagination.pageIndex+10 < pagination.maxNum?pagination.maxNum:(pagination.pageIndex-10)
|
||||
const nextPageIndex = pagination.pageIndex+10 > pagination.maxNum?pagination.maxNum:(pagination.pageIndex+10)
|
||||
paginationTag.push(<li key="np" className="btn">
|
||||
<button onClick={e => {moveToPage(nextPageIndex)}} className="next">다음</button>
|
||||
</li>);
|
||||
|
|
|
|||
|
|
@ -49,25 +49,12 @@ public class AdminLogsController extends BaseController {
|
|||
throws Exception {
|
||||
|
||||
ResultVO resultVO = new ResultVO();
|
||||
thPrivacyLog.setQueryInfo();
|
||||
Map<String, Object> resultMap = adminLogsService.selectPrivacyList();
|
||||
|
||||
PaginationInfo paginationInfo = new PaginationInfo();
|
||||
|
||||
paginationInfo.setCurrentPageNo(thPrivacyLog.getPageIndex());
|
||||
paginationInfo.setRecordCountPerPage(propertyService.getInt("Globals.pageUnit"));
|
||||
paginationInfo.setPageSize(propertyService.getInt("Globals.pageSize"));
|
||||
|
||||
thPrivacyLog.setFirstIndex(paginationInfo.getFirstRecordIndex());
|
||||
thPrivacyLog.setLastIndex(paginationInfo.getLastRecordIndex());
|
||||
thPrivacyLog.setRecordCountPerPage(paginationInfo.getRecordCountPerPage());
|
||||
|
||||
int totCnt = Integer.parseInt((String)resultMap.get("resultCnt"));
|
||||
paginationInfo.setTotalRecordCount(totCnt);
|
||||
|
||||
// resultMap.put("resultList", adminLogsService.selectPrivacyList());
|
||||
// resultMap.put("resultList", resultMap.get("resultList"));
|
||||
// resultMap.put("resultCnt", totCnt);
|
||||
resultMap.put("paginationInfo", paginationInfo);
|
||||
thPrivacyLog.setContentCnt(totCnt);
|
||||
thPrivacyLog.setPaginationInfo();
|
||||
resultMap.put("paginationInfo", thPrivacyLog);
|
||||
|
||||
resultVO.setResultCode(ResponseCode.SUCCESS.getCode());
|
||||
resultVO.setResultMessage(ResponseCode.SUCCESS.getMessage());
|
||||
|
|
|
|||
|
|
@ -1,6 +1,8 @@
|
|||
package com.dbnt.kcscbackend.admin.logs.entity;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
import com.dbnt.kcscbackend.config.common.BoardParams;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Getter;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
|
@ -22,61 +24,9 @@ import java.time.LocalDateTime;
|
|||
@DynamicInsert
|
||||
@DynamicUpdate
|
||||
@Table(name = "th_user_privacy_log")
|
||||
public class ThPrivacyLog implements Serializable {
|
||||
public class ThPrivacyLog extends BoardParams implements Serializable {
|
||||
private static final long serialVersionUID = -3779821913760046011L;
|
||||
|
||||
@Transient
|
||||
@Schema(description = "검색시작일")
|
||||
private String searchBgnDe = "";
|
||||
|
||||
@Transient
|
||||
@Schema(description = "검색조건")
|
||||
private String searchCnd = "";
|
||||
|
||||
@Transient
|
||||
@Schema(description = "검색종료일")
|
||||
private String searchEndDe = "";
|
||||
|
||||
@Transient
|
||||
@Schema(description = "검색단어")
|
||||
private String searchWrd = "";
|
||||
|
||||
@Transient
|
||||
@Schema(description = "정렬순서(DESC,ASC)")
|
||||
private long sortOrdr = 0L;
|
||||
|
||||
@Transient
|
||||
@Schema(description = "검색사용여부")
|
||||
private String searchUseYn = "";
|
||||
|
||||
@Transient
|
||||
@Schema(description = "현재페이지")
|
||||
private int pageIndex = 1;
|
||||
|
||||
@Transient
|
||||
@Schema(description = "페이지갯수")
|
||||
private int pageUnit = 10;
|
||||
|
||||
@Transient
|
||||
@Schema(description = "페이지사이즈")
|
||||
private int pageSize = 10;
|
||||
|
||||
@Transient
|
||||
@Schema(description = "첫페이지 인덱스")
|
||||
private int firstIndex = 1;
|
||||
|
||||
@Transient
|
||||
@Schema(description = "마지막페이지 인덱스")
|
||||
private int lastIndex = 1;
|
||||
|
||||
@Transient
|
||||
@Schema(description = "페이지당 레코드 개수")
|
||||
private int recordCountPerPage = 10;
|
||||
|
||||
@Transient
|
||||
@Schema(description = "레코드 번호")
|
||||
private int rowNo = 0;
|
||||
|
||||
@Id
|
||||
@Column(name = "upl_seq")
|
||||
private Long uplSeq;
|
||||
|
|
|
|||
|
|
@ -1,5 +1,6 @@
|
|||
package com.dbnt.kcscbackend.config.common;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
|
|
@ -28,6 +29,16 @@ public class BoardParams implements Serializable {
|
|||
@Transient
|
||||
private Integer contentCnt=0;
|
||||
|
||||
@Transient
|
||||
@Schema(description = "검색시작일")
|
||||
private String searchBgnDe = "";
|
||||
@Transient
|
||||
@Schema(description = "검색종료일")
|
||||
private String searchEndDe = "";
|
||||
@Transient
|
||||
@Schema(description = "정렬순서(DESC,ASC)")
|
||||
private long sortOrdr = 0L;
|
||||
|
||||
public void setQueryInfo(){
|
||||
setFirstIndex((getPageIndex()-1)*getRowCnt());
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue