| | |
| | | import com.bstek.bdf2.core.orm.hibernate.HibernateDao; |
| | | import com.ld.igds.inout.InoutConstant; |
| | | import com.ld.igds.models.*; |
| | | import com.ld.igds.util.DateUtil; |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.hibernate.Session; |
| | | import org.springframework.stereotype.Component; |
| | |
| | | args.put("companyId", companyId); |
| | | args.put("progress", InoutConstant.PROGRESS_RECORD); |
| | | args.put("recordStatus1", InoutConstant.RECORD_STATUS_DEL); |
| | | args.put("recordStatus2", InoutConstant.RECORD_STATUS_ERROR); |
| | | |
| | | if(StringUtils.isNotEmpty(depotId)){ |
| | | hql += " and depotId =:depotId"; |
| | |
| | | * @param endTime |
| | | * @return |
| | | */ |
| | | public List<MStockChange> listStockChange(String companyId, String depotId, Date startTime, Date endTime) { |
| | | String hql = " from " + MStockChange.class.getName() + " where companyId =:companyId"; |
| | | public List<InoutStockChange> listStockChange(String companyId, String depotId, Date startTime, Date endTime) { |
| | | String hql = " from " + InoutStockChange.class.getName() + " where companyId =:companyId"; |
| | | |
| | | Map<String, Object> args = new HashMap<String, Object>(); |
| | | args.put("companyId", companyId); |
| | |
| | | * @param endTime |
| | | * @return |
| | | */ |
| | | public List<MLossOver> listLossOver(String companyId, String depotId, Date startTime, Date endTime) { |
| | | String hql = " from " + MLossOver.class.getName() + " where companyId =:companyId"; |
| | | public List<InoutLossOver> listLossOver(String companyId, String depotId, Date startTime, Date endTime) { |
| | | String hql = " from " + InoutLossOver.class.getName() + " where companyId =:companyId"; |
| | | |
| | | Map<String, Object> args = new HashMap<String, Object>(); |
| | | args.put("companyId", companyId); |
| | |
| | | * @param endTime |
| | | * @return |
| | | */ |
| | | public List<MVarietyChange> listFoodVarietyChange(String companyId, String depotId, Date startTime, Date endTime) { |
| | | String hql = " from " + MVarietyChange.class.getName() + " where companyId =:companyId"; |
| | | public List<InoutVarietyChange> listFoodVarietyChange(String companyId, String depotId, Date startTime, Date endTime) { |
| | | String hql = " from " + InoutVarietyChange.class.getName() + " where companyId =:companyId"; |
| | | |
| | | Map<String, Object> args = new HashMap<String, Object>(); |
| | | args.put("companyId", companyId); |
| | |
| | | * @param endTime |
| | | * @return |
| | | */ |
| | | public List<MPlan> listPlan(String companyId, String type, Date startTime, Date endTime) { |
| | | String hql = " from " + MPlan.class.getName() + " where companyId =:companyId"; |
| | | public List<InoutPlan> listPlan(String companyId, String type, Date startTime, Date endTime) { |
| | | String hql = " from " + InoutPlan.class.getName() + " where companyId =:companyId"; |
| | | |
| | | Map<String, Object> args = new HashMap<String, Object>(); |
| | | args.put("companyId", companyId); |
| | |
| | | * @param planId |
| | | * @return |
| | | */ |
| | | public List<MPlanDetail> getPlanDetail(String planId) { |
| | | public List<InoutPlanDetail> getPlanDetail(String planId) { |
| | | |
| | | String hql = " from " + MPlanDetail.class.getName() + " where planId =:planId"; |
| | | String hql = " from " + InoutPlanDetail.class.getName() + " where planId =:planId"; |
| | | |
| | | Map<String, Object> args = new HashMap<String, Object>(); |
| | | args.put("planId", planId); |
| | |
| | | * @param endTime |
| | | * @return |
| | | */ |
| | | public List<MContract> listContract(String companyId, Date startTime, Date endTime){ |
| | | String hql = " from " + MContract.class.getName() + " where companyId =:companyId"; |
| | | public List<InoutContract> listContract(String companyId, Date startTime, Date endTime){ |
| | | String hql = " from " + InoutContract.class.getName() + " where companyId =:companyId"; |
| | | |
| | | Map<String, Object> args = new HashMap<String, Object>(); |
| | | args.put("companyId", companyId); |
| | |
| | | args.put("companyId", companyId); |
| | | args.put("progress", InoutConstant.PROGRESS_RECORD); |
| | | args.put("recordStatus1", InoutConstant.RECORD_STATUS_DEL); |
| | | args.put("recordStatus2", InoutConstant.RECORD_STATUS_ERROR); |
| | | |
| | | if(null != startTime){ |
| | | hql += " and registerTime >:startTime"; |