|
|
|
@ -483,6 +483,31 @@ public class CmmnUtil {
|
|
|
|
|
return band6;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public static void setOcrInfo(DataObject dataObject) {
|
|
|
|
|
|
|
|
|
|
String deptCode = dataObject.string("DEPT_CD");
|
|
|
|
|
String fyr = dataObject.string("FYR");
|
|
|
|
|
String acntgSeCd = dataObject.string("ACNTG_SE_CD");
|
|
|
|
|
String txitmCd = dataObject.string("TXITM_CD");
|
|
|
|
|
String levyNo = dataObject.string("LEVY_NO");
|
|
|
|
|
String inspyNo = dataObject.string("INSPY_NO");
|
|
|
|
|
String ocr0 = CmmnUtil.getOcrband1(deptCode,fyr, acntgSeCd, txitmCd, levyNo, inspyNo);
|
|
|
|
|
dataObject.set("OCR0", ocr0);
|
|
|
|
|
dataObject.set("OCR0_1", ocr0.substring(0, 17));
|
|
|
|
|
dataObject.set("OCR0_2", ocr0.substring(17));
|
|
|
|
|
|
|
|
|
|
String levySeCd = dataObject.string("LEVY_SE_CD");
|
|
|
|
|
int sumAmt = dataObject.number("SUM_AMT").intValue(); // 합계 금액
|
|
|
|
|
String dudtYmd = dataObject.string("DUDT_YMD");
|
|
|
|
|
String ocr1 = CmmnUtil.getOcrband2(ocr0, levySeCd, sumAmt, dudtYmd);
|
|
|
|
|
dataObject.set("OCR1", ocr1);
|
|
|
|
|
|
|
|
|
|
int afterSumAmt = dataObject.number("DUDT_AFTR_AMT").intValue(); // 납기후 금액
|
|
|
|
|
String ocr2 = CmmnUtil.getOcrband3(ocr1, sumAmt, dudtYmd, afterSumAmt);
|
|
|
|
|
dataObject.set("OCR2", ocr2);
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/** 엑셀파일 공통 헤더 스타일 생성
|
|
|
|
|
* @param xlsx
|
|
|
|
|
* @return XLSWriter.Styler
|
|
|
|
@ -555,4 +580,6 @@ public class CmmnUtil {
|
|
|
|
|
CellDecorator decorator = new CellDecorator(valueDeco, memoDeco);
|
|
|
|
|
return decorator;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|