public virtual (List <M>, bool) GetAll <M>(params string[] column) where M : class, new() { string cmtext = query.GetAll <M>(column); using (CommanderBase commander = DBContext.CreateCommander()) return(commander.Reader <M>(cmtext)); }
public virtual List <T> GetAll(params string[] column) { string cmtext = query.GetAll(column); using (CommanderBase commander = DBContext.CreateCommander()) return(commander.Reader <T>(cmtext)); }
public virtual List <T> getFromTo(int from, int to) { string cmtext = query.getFromTo(from, to); using (CommanderBase commander = DBContext.CreateCommander()) return(commander.Reader <T>(cmtext)); }
public virtual (List <M>, bool) GetWithCondition <M>(string condition, params string[] selectColumn) where M : class, new() { string cmtext = query.Condition <M>(condition, selectColumn); using (CommanderBase commander = DBContext.CreateCommander()) { return(commander.Reader <M>(cmtext)); } }
public virtual List <T> getFromToWithSrc(int from, int to, string srcClm, string srcValue) { string cmtext = query.getFromToWithSrc(from, to, srcClm); using (CommanderBase commander = DBContext.CreateCommander()) return(commander.Reader <T>(cmtext, new List <DbParameter> { commander.SetParametr(srcClm, srcValue) })); }
public virtual List <T> GetByColumName(string columName, object value) { string cmtext = query.GetByColumName(columName); using (CommanderBase commander = DBContext.CreateCommander()) return(commander.Reader <T>(cmtext, new List <DbParameter>() { commander.SetParametr(columName, value) })); }
public virtual (List <M>, bool) GetByColumName <M>(string columName, object value, params string[] selectColumn) where M : class, new() { string cmtext = query.GetByColumName <M>(columName, selectColumn); using (CommanderBase commander = DBContext.CreateCommander()) { return(commander.Reader <M>(cmtext, new List <DbParameter>() { commander.SetParametr(columName, value) })); } }