Example #1
0
        public Icsga BuildFromRow(DataRow row)
        {
            var returnRecord = Icsga.BuildIcsgaFromRow(row);

            returnRecord = this.BuildExtraFromRow <Icsga>(returnRecord, row);
            return(returnRecord);
        }
Example #2
0
        public Icsga Insert(Icsga record)
        {
            DataRow row = this.dataSet.ttblicsga.NewttblicsgaRow();

            this.UpdateToRow(ref row, record);
            this.ExtraUpdateToRow(ref row, record);
            this.dataSet.ttblicsga.AddttblicsgaRow((pdsicsgaDataSet.ttblicsgaRow)row);
            this.SaveChanges();
            return(this.dataSet.ttblicsga.Rows.Count > 0 ? this.BuildFromRow(this.dataSet.ttblicsga.Rows[0]) : null);
        }
Example #3
0
        public Icsga GetByRowId(string rowId, string fldList)
        {
            var   row   = this.GetRowByRowId(rowId, fldList);
            Icsga icsga = null;

            if (row != null)
            {
                icsga = this.BuildFromRow(row);
            }
            return(icsga);
        }
Example #4
0
        protected Icsga Fetch(string where, int batchsize, string fldList)
        {
            this.FetchWhere(where, batchsize, fldList);
            var   row   = this.dataSet.ttblicsga.AsEnumerable().SingleOrDefault();
            Icsga icsga = null;

            if (row != null)
            {
                icsga = this.BuildFromRow(row);
            }
            return(icsga);
        }
Example #5
0
        public void Delete(Icsga record)
        {
            var row = this.GetRowByRowId(record.rowID, string.Empty);

            if (row == null)
            {
                row = this.dataSet.ttblicsga.NewttblicsgaRow();
                Icsga.BuildMinimalRow(ref row, record);
                this.dataSet.ttblicsga.AddttblicsgaRow((pdsicsgaDataSet.ttblicsgaRow)row);
            }
            row.Delete();
            this.SaveChanges();
        }
Example #6
0
        public Icsga Update(Icsga 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.ttblicsga.Rows.Count > 0 ? this.BuildFromRow(this.dataSet.ttblicsga.Rows[0]) : null);
            }
            ErrorReportingHelper.ReportErrors("global.update.doesnotexist", 421);
            return(null);
        }
Example #7
0
 public void Delete(Icsga record)
 {
     this.repository.Delete(record);
 }
Example #8
0
 public Icsga Update(Icsga record)
 {
     return(this.repository.Update(record));
 }
Example #9
0
 public Icsga Insert(Icsga record)
 {
     return(this.repository.Insert(record));
 }
Example #10
0
 public void Delete(Icsga record)
 {
     this.adapter.Delete(record);
 }
Example #11
0
 public Icsga Update(Icsga record)
 {
     return(this.adapter.Update(record));
 }
Example #12
0
 public Icsga Insert(Icsga record)
 {
     return(this.adapter.Insert(record));
 }
Example #13
0
 public void UpdateToRow(ref DataRow row, Icsga record)
 {
     Icsga.UpdateRowFromIcsga(ref row, record);
     this.ExtraUpdateToRow(ref row, record);
 }