public Cartonmst BuildFromRow(DataRow row) { var returnRecord = Cartonmst.BuildCartonmstFromRow(row); returnRecord = this.BuildExtraFromRow <Cartonmst>(returnRecord, row); return(returnRecord); }
public Cartonmst Insert(Cartonmst record) { DataRow row = this.dataSet.ttblcartonmst.NewttblcartonmstRow(); this.UpdateToRow(ref row, record); this.ExtraUpdateToRow(ref row, record); this.dataSet.ttblcartonmst.AddttblcartonmstRow((pdscartonmstDataSet.ttblcartonmstRow)row); this.SaveChanges(); return(this.dataSet.ttblcartonmst.Rows.Count > 0 ? this.BuildFromRow(this.dataSet.ttblcartonmst.Rows[0]) : null); }
public Cartonmst GetByRowId(string rowId, string fldList) { var row = this.GetRowByRowId(rowId, fldList); Cartonmst cartonmst = null; if (row != null) { cartonmst = this.BuildFromRow(row); } return(cartonmst); }
protected Cartonmst Fetch(string where, int batchsize, string fldList) { this.FetchWhere(where, batchsize, fldList); var row = this.dataSet.ttblcartonmst.AsEnumerable().SingleOrDefault(); Cartonmst cartonmst = null; if (row != null) { cartonmst = this.BuildFromRow(row); } return(cartonmst); }
public void Delete(Cartonmst record) { var row = this.GetRowByRowId(record.rowID, string.Empty); if (row == null) { row = this.dataSet.ttblcartonmst.NewttblcartonmstRow(); Cartonmst.BuildMinimalRow(ref row, record); this.dataSet.ttblcartonmst.AddttblcartonmstRow((pdscartonmstDataSet.ttblcartonmstRow)row); } row.Delete(); this.SaveChanges(); }
public Cartonmst Update(Cartonmst 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.ttblcartonmst.Rows.Count > 0 ? this.BuildFromRow(this.dataSet.ttblcartonmst.Rows[0]) : null); } ErrorReportingHelper.ReportErrors("global.update.doesnotexist", 421); return(null); }
public void Delete(Cartonmst record) { this.adapter.Delete(record); }
public Cartonmst Update(Cartonmst record) { return(this.adapter.Update(record)); }
public Cartonmst Insert(Cartonmst record) { return(this.adapter.Insert(record)); }
public void UpdateToRow(ref DataRow row, Cartonmst record) { Cartonmst.UpdateRowFromCartonmst(ref row, record); this.ExtraUpdateToRow(ref row, record); }
public void Delete(Cartonmst record) { this.repository.Delete(record); }
public Cartonmst Update(Cartonmst record) { return(this.repository.Update(record)); }
public Cartonmst Insert(Cartonmst record) { return(this.repository.Insert(record)); }