DivCtItm ctItm = conditionMntService.findByDivCtItmNo(divCtNo);
if ("A".equals(type)) {
if (ctItm != null) {
// conditionMnt.0001 條件代碼重覆!
throw new CapMessageException(
CapAppContext.getMessage("condition.0001"), getClass());
}
ctItm = new DivCtItm();
} else {
if (ctItm != null && !ctItm.getOid().equals(request.get("oid"))) {
// conditionMnt.0001 條件代碼重覆!
throw new CapMessageException(
CapAppContext.getMessage("condition.0001"), getClass());
} else if (ctItm == null && !CapString.isEmpty(request.get("oid"))) {
ctItm = conditionMntService.getById(request.get("oid"));
} else if (ctItm == null){
ctItm = new DivCtItm();