Пример #1
0
        public Icsep BuildFromRow(DataRow row)
        {
            var returnRecord = Icsep.BuildIcsepFromRow(row);

            returnRecord = this.BuildExtraFromRow <Icsep>(returnRecord, row);
            return(returnRecord);
        }
Пример #2
0
        public Icsep Insert(Icsep record)
        {
            DataRow row = this.dataSet.ttblicsep.NewttblicsepRow();

            this.UpdateToRow(ref row, record);
            this.ExtraUpdateToRow(ref row, record);
            this.dataSet.ttblicsep.AddttblicsepRow((pdsicsepDataSet.ttblicsepRow)row);
            this.SaveChanges();
            return(this.dataSet.ttblicsep.Rows.Count > 0 ? this.BuildFromRow(this.dataSet.ttblicsep.Rows[0]) : null);
        }
Пример #3
0
        public Icsep GetByRowId(string rowId, bool fillMode, string fldList)
        {
            var   row   = this.GetRowByRowId(rowId, fillMode, fldList);
            Icsep icsep = null;

            if (row != null)
            {
                icsep = this.BuildFromRow(row);
            }
            return(icsep);
        }
Пример #4
0
        protected Icsep Fetch(string where, bool fillMode, int batchsize, string fldList)
        {
            this.FetchWhere(where, fillMode, batchsize, fldList);
            var   row   = this.dataSet.ttblicsep.AsEnumerable().SingleOrDefault();
            Icsep icsep = null;

            if (row != null)
            {
                icsep = this.BuildFromRow(row);
            }
            return(icsep);
        }
Пример #5
0
        public void Delete(Icsep record)
        {
            var row = this.GetRowByRowId(record.rowID, false, string.Empty);

            if (row == null)
            {
                row = this.dataSet.ttblicsep.NewttblicsepRow();
                Icsep.BuildMinimalRow(ref row, record);
                this.dataSet.ttblicsep.AddttblicsepRow((pdsicsepDataSet.ttblicsepRow)row);
            }
            row.Delete();
            this.SaveChanges();
        }
Пример #6
0
        public Icsep Update(Icsep record)
        {
            var row = this.GetRowByRowId(record.rowID, false, string.Empty);

            if (row != null)
            {
                this.UpdateToRow(ref row, record);
                this.ExtraUpdateToRow(ref row, record);
                this.SaveChanges();
                return(this.dataSet.ttblicsep.Rows.Count > 0 ? this.BuildFromRow(this.dataSet.ttblicsep.Rows[0]) : null);
            }
            ErrorReportingHelper.ReportErrors("global.update.doesnotexist", 421);
            return(null);
        }
Пример #7
0
 public void UpdateToRow(ref DataRow row, Icsep record)
 {
     Icsep.UpdateRowFromIcsep(ref row, record);
     this.ExtraUpdateToRow(ref row, record);
 }
Пример #8
0
 public void Delete(Icsep record)
 {
     this.repository.Delete(record);
 }
Пример #9
0
 public Icsep Update(Icsep record)
 {
     return(this.repository.Update(record));
 }
Пример #10
0
 public Icsep Insert(Icsep record)
 {
     return(this.repository.Insert(record));
 }
Пример #11
0
 public void Delete(Icsep record)
 {
     this.adapter.Delete(record);
 }
Пример #12
0
 public Icsep Update(Icsep record)
 {
     return(this.adapter.Update(record));
 }
Пример #13
0
 public Icsep Insert(Icsep record)
 {
     return(this.adapter.Insert(record));
 }