public Swelj BuildFromRow(DataRow row) { var returnRecord = Swelj.BuildSweljFromRow(row); returnRecord = this.BuildExtraFromRow <Swelj>(returnRecord, row); return(returnRecord); }
public Swelj Insert(Swelj record) { DataRow row = this.dataSet.ttblswelj.NewttblsweljRow(); this.UpdateToRow(ref row, record); this.ExtraUpdateToRow(ref row, record); this.dataSet.ttblswelj.AddttblsweljRow((pdssweljDataSet.ttblsweljRow)row); this.SaveChanges(); return(this.dataSet.ttblswelj.Rows.Count > 0 ? this.BuildFromRow(this.dataSet.ttblswelj.Rows[0]) : null); }
public Swelj GetByRowId(string rowId, string fldList) { var row = this.GetRowByRowId(rowId, fldList); Swelj swelj = null; if (row != null) { swelj = this.BuildFromRow(row); } return(swelj); }
protected Swelj Fetch(string where, int batchsize, string fldList) { this.FetchWhere(where, batchsize, fldList); var row = this.dataSet.ttblswelj.AsEnumerable().SingleOrDefault(); Swelj swelj = null; if (row != null) { swelj = this.BuildFromRow(row); } return(swelj); }
public void Delete(Swelj record) { var row = this.GetRowByRowId(record.rowID, string.Empty); if (row == null) { row = this.dataSet.ttblswelj.NewttblsweljRow(); Swelj.BuildMinimalRow(ref row, record); this.dataSet.ttblswelj.AddttblsweljRow((pdssweljDataSet.ttblsweljRow)row); } row.Delete(); this.SaveChanges(); }
public Swelj Update(Swelj 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.ttblswelj.Rows.Count > 0 ? this.BuildFromRow(this.dataSet.ttblswelj.Rows[0]) : null); } ErrorReportingHelper.ReportErrors("global.update.doesnotexist", 421); return(null); }
public void UpdateToRow(ref DataRow row, Swelj record) { Swelj.UpdateRowFromSwelj(ref row, record); this.ExtraUpdateToRow(ref row, record); }
public void Delete(Swelj record) { this.repository.Delete(record); }
public Swelj Update(Swelj record) { return(this.repository.Update(record)); }
public Swelj Insert(Swelj record) { return(this.repository.Insert(record)); }
public void Delete(Swelj record) { this.adapter.Delete(record); }
public Swelj Update(Swelj record) { return(this.adapter.Update(record)); }
public Swelj Insert(Swelj record) { return(this.adapter.Insert(record)); }