| | |
| | | import com.ld.igds.util.DateUtil; |
| | | import org.apache.commons.lang3.StringUtils; |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | import java.util.*; |
| | | |
| | | @Component |
| | |
| | | |
| | | String hql = " from " + InoutRecord.class.getName() |
| | | + " where companyId=:companyId "; |
| | | Map<String, Object> args = new HashMap<String, Object>(); |
| | | Map<String, Object> args = new HashMap<>(); |
| | | args.put("companyId", ContextUtil.getCompanyId()); |
| | | |
| | | if (null != param) { |
| | |
| | | if (StringUtils.isNotEmpty(str)) { |
| | | hql += " and type=:type "; |
| | | args.put("type", str); |
| | | } |
| | | |
| | | str = (String) param.get("type"); |
| | | if (StringUtils.isEmpty(str)) { |
| | | hql += " and type <> 'LOSS' and type <> 'OVER'"; |
| | | } else { |
| | | hql += " and type=:type "; |
| | | args.put("type", str); |
| | | hql += " and type <> 'LOSS' and type <> 'OVER'"; |
| | | } |
| | | |
| | | str = (String) param.get("customerId"); |
| | | str = (String) param.get("noticeId"); |
| | | if (StringUtils.isNotEmpty(str)) { |
| | | hql += " and customerId=:customerId "; |
| | | args.put("customerId", str); |
| | | hql += " and noticeId=:noticeId "; |
| | | args.put("noticeId", str); |
| | | } |
| | | |
| | | str = (String) param.get("progress"); |