public ReasonsModel(ReasonsModel source) { Id = source.Id; TransactionType = source.TransactionType; ReasonCode = source.ReasonCode; Description = source.Description; }
public List <ReasonsModel> FetchAll() { List <CloneableDictionary <string, string> > table = db.SelectMultiple("select * from reason_code"); foreach (var row in table) { var temp = new ReasonsModel(); var clone = row.Clone(); temp.Id = Int32.Parse(row["reasoncode_id"]); temp.TransactionType = row["transaction_type"]; temp.ReasonCode = row["reason_code"]; temp.Description = row["reason_description"]; _reasons.Add(temp); } return(_reasons); }
public List<ReasonsModel> FetchAll() { List<CloneableDictionary<string, string>> table = db.SelectMultiple("select * from reason_code"); foreach (var row in table) { var temp = new ReasonsModel(); var clone = row.Clone(); temp.Id = Int32.Parse(row["reasoncode_id"]); temp.TransactionType = row["transaction_type"]; temp.ReasonCode = row["reason_code"]; temp.Description = row["reason_description"]; _reasons.Add(temp); } return _reasons; }