public List<CustomerHoldQty> getList(QueryConditions conditions, PageInfo pageInfo) { String hql = "select new CustomerHoldQty(primary.commodityId,commodity.name,primary.customerNo,customer.memberNo,primary.oneMaxOrderQty,primary.oneMinOrderQty,primary.maxCleanQty,primary.maxHoldQty,customer.name) from CustomerHoldQty as primary,Commodity as commodity,Customer as customer where primary.commodityId=commodity.id and customer.customerNo=primary.customerNo"; Object[] values = (Object[]) null; String[] names = (String[]) null; if ((conditions != null) && (conditions.getFieldsSqlClause() != null)) { values = conditions.getValueArray(); names = conditions.getNameArray(); hql = hql + " and " + conditions.getFieldsSqlClause(); } return queryByHQL(hql, names, values, pageInfo, null); }
public List<Margin> getList(QueryConditions conditions, PageInfo pageInfo) { String hql = "select new Margin(primary.commodityId,commodity.name,primary.firmId,customerinfo.firmId,primary.marginAlgr,primary.tradeMargin) from Margin as primary,Commodity as commodity,FirmVO as customerinfo where primary.commodityId=commodity.id and primary.firmId=customerinfo.firmId and customerinfo.firmType='C'"; Object[] values = (Object[]) null; String[] names = (String[]) null; if ((conditions != null) && (conditions.getFieldsSqlClause() != null)) { values = conditions.getValueArray(); names = conditions.getNameArray(); hql = hql + " and " + conditions.getFieldsSqlClause(); } return queryByHQL(hql, names, values, pageInfo, null); }
public List<NetCustomer> getList(QueryConditions conditions, PageInfo pageInfo) { String hql = "select new NetCustomer(primary.customerNo,primary.name,primary.memberNo,memberInfo.name,primary.papersType,primary.papersName,primary.address,primary.phone,primary.fax,primary.postCode,primary.email,primary.extendData,primary.phonePWD,primary.customerStatus.status,primary.brokerageNo,primary.brokerageName,primary.managerNo,primary.managerName,primary.organizationNo,primary.organizationName,primary.createTime,primary.signTime,primary.activateTime,primary.freezeTime,primary.demiseTime,primary.useFunds) from NetCustomer as primary,MemberInfo as memberInfo,NetCount netCount where primary.memberNo=memberInfo.id and primary.customerNo=netCount.monicustomno"; Object[] values = (Object[]) null; String[] names = (String[]) null; if ((conditions != null) && (conditions.getFieldsSqlClause() != null)) { values = conditions.getValueArray(); names = conditions.getNameArray(); hql = hql + " and " + conditions.getFieldsSqlClause(); } return queryByHQL(hql, names, values, pageInfo, null); }
public List<DelayTrade> getList(QueryConditions conditions, PageInfo pageInfo) { String hql = "select new DelayTrade(primary.commodityId,primary.f_FirmId,commodity.name,customer.name,primary.delayTradeType,primary.delayTradeTime,primary.isslipPoint ) from DelayTrade as primary,Customer as customer,Commodity as commodity where primary.commodityId=commodity.id and primary.f_FirmId=customer.customerNo"; Object[] values = (Object[]) null; String[] names = (String[]) null; if ((conditions != null) && (conditions.getFieldsSqlClause() != null)) { values = conditions.getValueArray(); names = conditions.getNameArray(); hql = hql + " and " + conditions.getFieldsSqlClause(); } this.logger.debug("hql:" + hql); return queryByHQL(hql, names, values, pageInfo, null); }
public List<Trade> getList(QueryConditions conditions, PageInfo pageInfo) { String hql = "select new Trade(primary.tradeNo, primary.orderNo, primary.holdNo, primary.bs_flag, primary.firmId, primary.commodityId, primary.o_firmId, commodity.name, firm.firmName, primary.o_bs_flag, primary.oc_flag, primary.quantity) from Trade as primary, Commodity as commodity, Firm as firm where primary.firmId = firm.firmId and primary.commodityId = commodity.id "; Object[] values = (Object[]) null; String[] names = (String[]) null; if ((conditions != null) && (conditions.getFieldsSqlClause() != null) && (!"".equals(conditions.getFieldsSqlClause()))) { values = conditions.getValueArray(); names = conditions.getNameArray(); hql = hql + " and " + conditions.getFieldsSqlClause(); } CacheSet cacheSet = new CacheSet(); cacheSet.setRegion("queryCache"); List<Trade> list = queryByHQL(hql, names, values, pageInfo, cacheSet); return list; }