protected boolean validateKey(SimReceiveData t) { Assert.notNull(t, "bean is null."); Assert.notNull(t.getPlayname(), "playname is null."); Assert.notNull(t.getValidtermcode(), "termcode is null."); Assert.notNull(t.getLogiccode(), "logiccode is null."); Assert.notNull(t.getTicketcode(), "ticketcode is null."); return true; }
/** * This method was generated by MyBatis Generator. This method corresponds to the database table * T_SIM_RECEIVE_DATA * * @mbggenerated Tue Aug 21 10:23:40 CST 2012 */ public void insertOrUpdate(SimReceiveData record) { String key = record.getPlayname() + splitter + record.getValidtermcode() + splitter + record.getLogiccode() + splitter + record.getTicketcode(); record.setKey(key); super.insert(record); }
/** * This method was generated by MyBatis Generator. This method corresponds to the database table * T_SIM_RECEIVE_DATA * * @mbggenerated Tue Aug 34 10:23:40 CST 2012 */ public void batchInsertOrUpdat(final List<SimReceiveData> list) { for (SimReceiveData record : list) { String key = record.getPlayname() + splitter + record.getValidtermcode() + splitter + record.getLogiccode() + splitter + record.getTicketcode(); record.setKey(key); } super.batchInsert(list); }
public List<SimReceiveData> getWinDataFileData(SimReceiveData example) { Assert.noneNull(example, example.getPlayname(), example.getValidtermcode(), example.getIswin()); String cql = "select * from " + this.columnFamilyName + " where PLAYNAME = '" + example.getPlayname() + "' and VALIDTERMCODE = '" + example.getValidtermcode() + "' and ISWIN = " + example.getIswin(); log.info(this.columnFamilyName + ":cql[" + cql + "]"); return selectByCQL(cql); }
@Override public List<SimReceiveData> checkTick(SimReceiveData example) { Assert.noneNull( example, example.getPlayname(), example.getValidtermcode(), example.getLogiccode(), example.getRuncode()); String cql = "select * from " + this.columnFamilyName + " where PLAYNAME = '" + example.getPlayname() + "' and VALIDTERMCODE = '" + example.getValidtermcode() + "' and LOGICCODE = '" + example.getLogiccode() + "' and RUNCODE = '" + example.getRuncode() + "'"; return selectByCQL(cql); }
@Override public List<SimReceiveData> getEncashData(SimReceiveData example) { Assert.noneNull( example, example.getPlayname(), example.getLogiccode(), example.getTicketcode()); String cql = "select * from " + this.columnFamilyName + " where PLAYNAME = '" + example.getPlayname() + "' and LOGICCODE = '" + example.getLogiccode() + "' and TICKETCODE = '" + example.getTicketcode() + "'"; log.info(this.columnFamilyName + ":cql[" + cql + "]"); return selectByCQL(cql); }