package cn.hmsoft.mr.data.dao.cf; import org.springframework.stereotype.Repository; import cn.hmsoft.jdbc.core.PlatformDaoSupport; import cn.hmsoft.jdbc.entity.Pager; import cn.hmsoft.jdbc.entity.QueryOrder; import cn.hmsoft.mr.data.model.cf.CfPromiseInfo; @Repository public class CfPromiseInfoDao extends PlatformDaoSupport { public Pager pagePromise(Integer school_id, Integer start, Integer limit, String query, QueryOrder queryOrder) { StringBuilder sql = new StringBuilder(); sql.append("select * from cf_promise_info a where 1=1 "); if (school_id != null) { sql.append(" and a.school_id=").append(school_id); } return super.pageMapBySql(queryOrder, start, limit, sql.toString()); } }