| | |
| | | import com.nanometer.smartlab.util.MessageUtil; |
| | | import org.apache.commons.lang.StringUtils; |
| | | import org.apache.log4j.Logger; |
| | | import org.springframework.context.annotation.Lazy; |
| | | import org.springframework.dao.DataAccessException; |
| | | import org.springframework.dao.DataIntegrityViolationException; |
| | | import org.springframework.dao.DuplicateKeyException; |
| | |
| | | |
| | | @Resource(name = "opeApplyDao") |
| | | OpeApplyDao opeApplyDao; |
| | | @Lazy |
| | | @Resource |
| | | OpeOrderService opeOrderService; |
| | | @Lazy |
| | | @Resource |
| | | OpeReagentStatusService opeReagentStatusService; |
| | | @Lazy |
| | | @Resource |
| | | OpeWarehouseReserveService opeWarehouseReserveService; |
| | | |
| | |
| | | } |
| | | |
| | | @Override |
| | | public int getOpeApplyReserveTotalCountByNameFor(String id,String reagentName, String personName,String productSn,String applyCode,Integer status,Integer isAllApply) { |
| | | public int getOpeApplyReserveTotalCountByNameFor(String id,String reagentName, String personName,String productSn,String applyCode,Integer status,Integer isAllApply,boolean isExpired) { |
| | | try { |
| | | Map<String, Object> params = new HashMap<String, Object>(); |
| | | params.put("reagentName", reagentName); |
| | |
| | | params.put("userId",id); |
| | | params.put("productSn",productSn); |
| | | params.put("applyCode",applyCode); |
| | | params.put("status",status); |
| | | if (isExpired) { |
| | | params.put("status",ApplyStatus.EXPIRED); |
| | | }else{ |
| | | params.put("status", status); |
| | | } |
| | | params.put("isAllApply",isAllApply); |
| | | return this.opeApplyDao.getOpeApplyReserveTotalCountFor(params); |
| | | } catch (DataAccessException e) { |
| | |
| | | } |
| | | @Override |
| | | public List<OpeApplyReserve> getOpeApplyReserveListByNameFor(String id,String reagentName, String personName, Integer first, |
| | | Integer pageSize,String productSn,String applyCode,Integer status,Integer isAllApply) { |
| | | Integer pageSize,String productSn,String applyCode,Integer status,Integer isAllApply,boolean isExpired) { |
| | | try { |
| | | Map<String, Object> params = new HashMap<String, Object>(); |
| | | params.put("reagentName", reagentName); |
| | |
| | | params.put("pageSize", pageSize); |
| | | params.put("productSn",productSn); |
| | | params.put("applyCode",applyCode); |
| | | params.put("status",status); |
| | | if (isExpired) { |
| | | params.put("status",ApplyStatus.EXPIRED); |
| | | }else{ |
| | | params.put("status", status); |
| | | } |
| | | params.put("isAllApply",isAllApply); |
| | | return this.opeApplyDao.getOpeApplyReserveListFor(params); |
| | | } catch (DataAccessException e) { |