// 获取客户端的id public PageList getClientAdvList() { GezitechDBHelper<Adv> advDB = new GezitechDBHelper<Adv>(Adv.class); ArrayList<Adv> advList = advDB.query("", 0, "sort desc,id desc"); PageList pl = new PageList(); if (advList != null) { pl.addAll(advList); } return pl; }
// 获取客户端缓存的配置信息 public Configuration getConfiguration(int system_id) { GezitechDBHelper<Configuration> db = new GezitechDBHelper<Configuration>(Configuration.class); ArrayList<Configuration> list = db.query("system_id=" + system_id, 1, ""); if (list == null || list.size() <= 0) { return null; } else { return list.get(0); } }