public Sweh BuildFromRow(DataRow row) { var returnRecord = Sweh.BuildSwehFromRow(row); returnRecord = this.BuildExtraFromRow <Sweh>(returnRecord, row); return(returnRecord); }
public Sweh Insert(Sweh record) { DataRow row = this.dataSet.ttblsweh.NewttblswehRow(); this.UpdateToRow(ref row, record); this.ExtraUpdateToRow(ref row, record); this.dataSet.ttblsweh.AddttblswehRow((pdsswehDataSet.ttblswehRow)row); this.SaveChanges(); return(this.dataSet.ttblsweh.Rows.Count > 0 ? this.BuildFromRow(this.dataSet.ttblsweh.Rows[0]) : null); }
public Sweh GetByRowId(string rowId, string fldList) { var row = this.GetRowByRowId(rowId, fldList); Sweh sweh = null; if (row != null) { sweh = this.BuildFromRow(row); } return(sweh); }
protected Sweh Fetch(string where, int batchsize, string fldList) { this.FetchWhere(where, batchsize, fldList); var row = this.dataSet.ttblsweh.AsEnumerable().SingleOrDefault(); Sweh sweh = null; if (row != null) { sweh = this.BuildFromRow(row); } return(sweh); }
public void Delete(Sweh record) { var row = this.GetRowByRowId(record.rowID, string.Empty); if (row == null) { row = this.dataSet.ttblsweh.NewttblswehRow(); Sweh.BuildMinimalRow(ref row, record); this.dataSet.ttblsweh.AddttblswehRow((pdsswehDataSet.ttblswehRow)row); } row.Delete(); this.SaveChanges(); }
public Sweh Update(Sweh record) { var row = this.GetRowByRowId(record.rowID, string.Empty); if (row != null) { this.UpdateToRow(ref row, record); this.ExtraUpdateToRow(ref row, record); this.SaveChanges(); return(this.dataSet.ttblsweh.Rows.Count > 0 ? this.BuildFromRow(this.dataSet.ttblsweh.Rows[0]) : null); } ErrorReportingHelper.ReportErrors("global.update.doesnotexist", 421); return(null); }
public void Delete(Sweh record) { this.repository.Delete(record); }
public Sweh Update(Sweh record) { return(this.repository.Update(record)); }
public Sweh Insert(Sweh record) { return(this.repository.Insert(record)); }
public void UpdateToRow(ref DataRow row, Sweh record) { Sweh.UpdateRowFromSweh(ref row, record); this.ExtraUpdateToRow(ref row, record); }
public Sweh Insert(Sweh record) { return(this.adapter.Insert(record)); }
public void Delete(Sweh record) { this.adapter.Delete(record); }
public Sweh Update(Sweh record) { return(this.adapter.Update(record)); }