Пример #1
0
 /* (non-Javadoc)
  * @see com.jlj.service.imp.IPublickeyService#getTotalCount(int, java.lang.String, int, java.lang.String)
  */
 public int getTotalCount(int con, String convalue, int status, String publicaccount) {
   String queryString = "select count(*) from Publickey mo where mo.publicaccount=? ";
   Object[] p = null;
   if (con != 0 && convalue != null && !convalue.equals("")) {
     // 大类别名称
     if (con == 1) {
       queryString += "and mo.title like ? ";
     }
     p = new Object[] {publicaccount, '%' + convalue + '%'};
   } else {
     p = new Object[] {publicaccount};
   }
   return publickeyDao.getUniqueResult(queryString, p);
 }
Пример #2
0
 /* (non-Javadoc)
  * @see com.jlj.service.imp.IPublickeyService#queryList(int, java.lang.String, int, java.lang.String, int, int)
  */
 public List<Publickey> queryList(
     int con, String convalue, int status, String publicaccount, int page, int size) {
   String queryString = "from Publickey mo where mo.publicaccount=? ";
   Object[] p = null;
   if (con != 0 && convalue != null && !convalue.equals("")) {
     // 大类别名称
     if (con == 1) {
       queryString += "and mo.title like ? ";
     }
     p = new Object[] {publicaccount, '%' + convalue + '%'};
   } else {
     p = new Object[] {publicaccount};
   }
   queryString += " order by mo.id desc ";
   return publickeyDao.pageList(queryString, p, page, size);
 }
Пример #3
0
 /* (non-Javadoc)
  * @see com.jlj.service.imp.IPublickeyService#getPublickeys()
  */
 public List<Publickey> getPublickeys() {
   return publickeyDao.getPublickeys();
 }
Пример #4
0
 /* (non-Javadoc)
  * @see com.jlj.service.imp.IPublickeyService#loadById(int)
  */
 public Publickey loadById(int id) {
   return publickeyDao.loadById(id);
 }
Пример #5
0
 /* (non-Javadoc)
  * @see com.jlj.service.imp.IPublickeyService#update(com.jlj.model.Publickey)
  */
 public void update(Publickey publickey) {
   publickeyDao.update(publickey);
 }
Пример #6
0
 /* (non-Javadoc)
  * @see com.jlj.service.imp.IPublickeyService#deleteById(int)
  */
 public void deleteById(int id) {
   publickeyDao.deleteById(id);
 }
Пример #7
0
 /* (non-Javadoc)
  * @see com.jlj.service.imp.IPublickeyService#delete(com.jlj.model.Publickey)
  */
 public void delete(Publickey publickey) {
   publickeyDao.delete(publickey);
 }
Пример #8
0
 /* (non-Javadoc)
  * @see com.jlj.service.imp.IPublickeyService#add(com.jlj.model.Publickey)
  */
 public void add(Publickey publickey) throws Exception {
   publickeyDao.save(publickey);
 }
Пример #9
0
 public List<Publickey> queryListByPublicAccount(String publicaccount) {
   String queryString = "from Publickey mo where mo.publicaccount = ?";
   Object[] p = new Object[] {publicaccount};
   return publickeyDao.getObjectsByCondition(queryString, p);
 }