Commit 3a310484 by Huang Linyu

业务提交数据 - 更新功能优化

parent ba4dbec7
......@@ -128,7 +128,12 @@ public class ActiveCustomerDao extends GenericHibernateDao<ActiveCustomer, Integ
public Integer updateAuditState(ActiveCustomerQuery param){
String hql = "update ActiveCustomer set auditState="+param.getAuditState()+", auditUser = '"+param.getAuditUser()+"' where id="+param.getId();
String hql = "update ActiveCustomer set auditState="+param.getAuditState()+", auditUser = '"+param.getAuditUser()+"'";
if(org.apache.commons.lang.StringUtils.isNotBlank( param.getAuditRemark())){
hql +=",auditRemark='"+param.getAuditRemark()+"' ";
}
hql +=" where id="+param.getId();
// String hql = "update ActiveCustomer set auditState="+param.getAuditState()+", auditUser = '"+param.getAuditUser()+" where id="+param.getId();
Query query = this.getSession().createQuery(hql);
Integer rlt = query.executeUpdate();
return rlt;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment