| | |
| | | OpeApplyOrderDao opeApplyOrderDao; |
| | | |
| | | @Transactional(propagation = Propagation.REQUIRED) |
| | | public List<OpeApplyOrder> getOpeApplyOrderList(String opeOrderId, String opeApplyId) { |
| | | public List<OpeApplyOrder> getOpeApplyOrderList(Long opeOrderId, Long opeApplyId) { |
| | | try { |
| | | Map<String, Object> params = new HashMap<String, Object>(); |
| | | params.put("opeOrderId", opeOrderId); |
| | |
| | | } |
| | | |
| | | @Transactional(propagation = Propagation.REQUIRED) |
| | | public int getOpeApplyOrderTotalCount(String opeOrderId, String opeApplyId) { |
| | | public int getOpeApplyOrderTotalCount(Long opeOrderId, Long opeApplyId) { |
| | | try { |
| | | Map<String, Object> params = new HashMap<String, Object>(); |
| | | params.put("opeOrderId", opeOrderId); |
| | |
| | | @Transactional(propagation = Propagation.REQUIRED) |
| | | public OpeApplyOrder insertOpeApplyOrder(OpeApplyOrder opeApplyOrder) { |
| | | try { |
| | | opeApplyOrder.setId(IDUtils.uuid()); |
| | | this.opeApplyOrderDao.insertOpeApplyOrder(opeApplyOrder); |
| | | return opeApplyOrder; |
| | | } catch (DuplicateKeyException ex) { |
| | |
| | | throw new BusinessException(ExceptionEnumCode.DB_ERR, MessageUtil.getMessageByCode(ExceptionEnumCode.DB_ERR.getCode()), ex); |
| | | } |
| | | } |
| | | |
| | | |
| | | |
| | | public int batchInsertOpeApplyOrder(List<OpeApplyOrder> opeApplyOrderList) { |
| | | try { |
| | | return this.opeApplyOrderDao.batchInsertOpeApplyOrder(opeApplyOrderList); |
| | | } catch (DuplicateKeyException ex) { |
| | | logger.warn(ex.getMessage(), ex); |
| | | throw new AlarmException(AlarmCode.DATA_DUPLICATE, MessageUtil.getMessage(AlarmCode.DATA_DUPLICATE.getCode())); |
| | | } catch (DataIntegrityViolationException ex) { |
| | | logger.warn(ex.getMessage(), ex); |
| | | throw new AlarmException(AlarmCode.DATA_CONFICT, MessageUtil.getMessage(AlarmCode.DATA_CONFICT.getCode())); |
| | | } catch (DataAccessException ex) { |
| | | logger.error(ex.getMessage(), ex); |
| | | throw new BusinessException(ExceptionEnumCode.DB_ERR, MessageUtil.getMessageByCode(ExceptionEnumCode.DB_ERR.getCode()), ex); |
| | | } |
| | | } |
| | | } |