OWL ITS + 탐지시스템(인터넷 진흥원)
jhjang
2022-02-08 00d836c9a224c78fb0cf89d3f2b69ab05c28cff8
src/main/java/kr/wisestone/owl/util/CommonUtil.java
@@ -12,6 +12,7 @@
import org.apache.commons.codec.binary.Base64;
import org.apache.commons.lang3.RandomStringUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.poi.hssf.usermodel.HSSFDateUtil;
import org.apache.poi.ss.usermodel.Cell;
import org.jsoup.Jsoup;
import org.slf4j.Logger;
@@ -960,17 +961,22 @@
        switch (cell.getCellType()) {
            case Cell.CELL_TYPE_NUMERIC :
                double doubleValue = cell.getNumericCellValue();
                int intValue;
                if (HSSFDateUtil.isCellDateFormatted(cell)) {
                    Date date = cell.getDateCellValue();
                    cellValue = DateUtil.convertDateToStr(date, "yyyy-MM-dd hh:mm:ss");
                if (doubleValue % 1 == 0) {
                    intValue = (int)doubleValue;
                    cellValue = intValue + "";
                }
                else {
                    cellValue = doubleValue + "";
                }
                } else {
                    double doubleValue = cell.getNumericCellValue();
                    int intValue;
                    if (doubleValue % 1 == 0) {
                        intValue = (int)doubleValue;
                        cellValue = intValue + "";
                    }
                    else {
                        cellValue = doubleValue + "";
                    }
                }
                break;
            case Cell.CELL_TYPE_STRING :