|
|
@ -3,7 +3,6 @@ package cokr.xit.fims.cmmn.hwp;
|
|
|
|
import java.io.File;
|
|
|
|
import java.io.File;
|
|
|
|
import java.io.InputStream;
|
|
|
|
import java.io.InputStream;
|
|
|
|
import java.text.SimpleDateFormat;
|
|
|
|
import java.text.SimpleDateFormat;
|
|
|
|
import java.util.ArrayList;
|
|
|
|
|
|
|
|
import java.util.Date;
|
|
|
|
import java.util.Date;
|
|
|
|
import java.util.List;
|
|
|
|
import java.util.List;
|
|
|
|
|
|
|
|
|
|
|
@ -16,9 +15,7 @@ import cokr.xit.foundation.UserInfo;
|
|
|
|
import cokr.xit.foundation.data.DataFormat;
|
|
|
|
import cokr.xit.foundation.data.DataFormat;
|
|
|
|
import cokr.xit.foundation.data.DataObject;
|
|
|
|
import cokr.xit.foundation.data.DataObject;
|
|
|
|
import kr.dogfoot.hwplib.object.HWPFile;
|
|
|
|
import kr.dogfoot.hwplib.object.HWPFile;
|
|
|
|
import kr.dogfoot.hwplib.object.bodytext.control.table.Cell;
|
|
|
|
|
|
|
|
import kr.dogfoot.hwplib.reader.HWPReader;
|
|
|
|
import kr.dogfoot.hwplib.reader.HWPReader;
|
|
|
|
import kr.dogfoot.hwplib.tool.objectfinder.CellFinder;
|
|
|
|
|
|
|
|
import kr.dogfoot.hwplib.writer.HWPWriter;
|
|
|
|
import kr.dogfoot.hwplib.writer.HWPWriter;
|
|
|
|
|
|
|
|
|
|
|
|
public class PrintUtil {
|
|
|
|
public class PrintUtil {
|
|
|
@ -113,7 +110,14 @@ public class PrintUtil {
|
|
|
|
this.recordPerPartFile = 6;
|
|
|
|
this.recordPerPartFile = 6;
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
case "requestForDelivery": {
|
|
|
|
|
|
|
|
this.recordPerPartFile = 7;
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
case "reportOnClaims": {
|
|
|
|
|
|
|
|
this.recordPerPartFile = 7;
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
@ -130,7 +134,18 @@ public class PrintUtil {
|
|
|
|
this.attachFormatFilePath = "format/crdnList_inner.hwp";
|
|
|
|
this.attachFormatFilePath = "format/crdnList_inner.hwp";
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
case "requestForDelivery": {
|
|
|
|
|
|
|
|
this.formatKorName = "교부청구서";
|
|
|
|
|
|
|
|
this.baseFormatFilePath = "format/requestForDelivery_root.hwp";
|
|
|
|
|
|
|
|
this.attachFormatFilePath = "format/requestForDelivery_inner.hwp";
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
case "reportOnClaims": {
|
|
|
|
|
|
|
|
this.formatKorName = "채권신고서";
|
|
|
|
|
|
|
|
this.baseFormatFilePath = "format/reportOnClaims_root.hwp";
|
|
|
|
|
|
|
|
this.attachFormatFilePath = "format/reportOnClaims_inner.hwp";
|
|
|
|
|
|
|
|
break;
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -210,6 +225,15 @@ public class PrintUtil {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
baseFileEditor.set("발신", instNm);
|
|
|
|
baseFileEditor.set("발신", instNm);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
else if(this.formatName.equals("requestForDelivery")){
|
|
|
|
|
|
|
|
//TODO :
|
|
|
|
|
|
|
|
//파라미터 : 문서번호,사건번호
|
|
|
|
|
|
|
|
//체납자성명,체납자번호,차량번호,주소,교부청구금액,교부청구금액한글,
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
else if(this.formatName.equals("reportOnClaims")){
|
|
|
|
|
|
|
|
//TODO :
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/**한글파일 서식에 대해 데이터 건별로 처리한다.
|
|
|
|
/**한글파일 서식에 대해 데이터 건별로 처리한다.
|
|
|
@ -244,13 +268,16 @@ public class PrintUtil {
|
|
|
|
attachFileEditor.set("납부기한", DataFormat.yyyy_mm_dd(dataObject.string("DUDT_YMD")));
|
|
|
|
attachFileEditor.set("납부기한", DataFormat.yyyy_mm_dd(dataObject.string("DUDT_YMD")));
|
|
|
|
attachFileEditor.set("수납일자", DataFormat.yyyy_mm_dd(dataObject.string("RCVMT_YMD")));
|
|
|
|
attachFileEditor.set("수납일자", DataFormat.yyyy_mm_dd(dataObject.string("RCVMT_YMD")));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
else if(this.formatName.equals("requestForDelivery")){
|
|
|
|
|
|
|
|
//TODO :
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
ArrayList<Cell> cellList = CellFinder.findAll(baseFile, "내부");
|
|
|
|
else if(this.formatName.equals("reportOnClaims")){
|
|
|
|
Cell cell = cellList.get(0);
|
|
|
|
//TODO :
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
AddUtil.insertTableInCell(attachFormatFile, baseFile, cell);
|
|
|
|
AddUtil.insertTableInCell(attachFormatFile, baseFile, "내부");
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
} else {
|
|
|
|