OWL ITS + 탐지시스템(인터넷 진흥원)
이민희
2022-01-06 6211b73ad7750a62652bacf5bcf05002c62fb907
src/main/java/kr/wisestone/owl/web/condition/IssueCondition.java
@@ -1,10 +1,9 @@
package kr.wisestone.owl.web.condition;
import com.google.common.collect.Lists;
import kr.wisestone.owl.util.CommonUtil;
import kr.wisestone.owl.util.ConvertUtil;
import kr.wisestone.owl.util.DateUtil;
import kr.wisestone.owl.util.MapUtil;
import kr.wisestone.owl.util.*;
import kr.wisestone.owl.vo.PageVo;
import org.springframework.data.domain.Pageable;
import org.springframework.util.StringUtils;
import java.util.Date;
@@ -56,6 +55,8 @@
    private Boolean hideDownIssue;
    private Boolean hideCompleteIssue;
    private Boolean isTree; // 트리구조 모드 일때
    private Pageable relPageable;
    private Pageable downPageable;
    public IssueCondition(){}
@@ -70,6 +71,20 @@
    public static IssueCondition make(Map<String, Object> conditions) {
        IssueCondition condition = ConvertUtil.convertMapToClass(conditions, IssueCondition.class);
        Map<String, Object> pageContents = (Map<String, Object>) conditions.get("pageContent");
        if (pageContents != null) {
            PageVo downPageVo = new PageVo();
            downPageVo.setPage(MapUtil.getInteger(pageContents, "downPage"));
            downPageVo.setPageSize(MapUtil.getInteger(pageContents, "downPageSize"));
            PageVo relPageVo = new PageVo();
            relPageVo.setPage(MapUtil.getInteger(pageContents, "relPage"));
            relPageVo.setPageSize(MapUtil.getInteger(pageContents, "relPageSize"));
            PageUtil pageUtil = new PageUtil();
            condition.setRelPageable(pageUtil.convertPageable(relPageVo));
            condition.setDownPageable(pageUtil.convertPageable(downPageVo));
        }
        if (!StringUtils.isEmpty(condition.getCombinationIssueNumber())) {
            if (condition.getCombinationIssueNumber().contains("-")) {
@@ -542,4 +557,20 @@
    public void setTree(Boolean tree) {
        isTree = tree;
    }
    public Pageable getRelPageable() {
        return relPageable;
    }
    public void setRelPageable(Pageable relPageable) {
        this.relPageable = relPageable;
    }
    public Pageable getDownPageable() {
        return downPageable;
    }
    public void setDownPageable(Pageable downPageable) {
        this.downPageable = downPageable;
    }
}