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

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

            this.UpdateToRow(ref row, record);
            this.ExtraUpdateToRow(ref row, record);
            this.dataSet.ttblevent_trans_sub.Addttblevent_trans_subRow((pdsevent_trans_subDataSet.ttblevent_trans_subRow)row);
            this.SaveChanges();
            return(this.dataSet.ttblevent_trans_sub.Rows.Count > 0 ? this.BuildFromRow(this.dataSet.ttblevent_trans_sub.Rows[0]) : null);
        }
Пример #3
0
        public EventTransSub GetByRowId(string rowId, string fldList)
        {
            var           row           = this.GetRowByRowId(rowId, fldList);
            EventTransSub eventTransSub = null;

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

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

            if (row == null)
            {
                row = this.dataSet.ttblevent_trans_sub.Newttblevent_trans_subRow();
                EventTransSub.BuildMinimalRow(ref row, record);
                this.dataSet.ttblevent_trans_sub.Addttblevent_trans_subRow((pdsevent_trans_subDataSet.ttblevent_trans_subRow)row);
            }
            row.Delete();
            this.SaveChanges();
        }
Пример #6
0
        public EventTransSub Update(EventTransSub 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.ttblevent_trans_sub.Rows.Count > 0 ? this.BuildFromRow(this.dataSet.ttblevent_trans_sub.Rows[0]) : null);
            }
            ErrorReportingHelper.ReportErrors("global.update.doesnotexist", 421);
            return(null);
        }
Пример #7
0
 public void Delete(EventTransSub record)
 {
     this.adapter.Delete(record);
 }
Пример #8
0
 public EventTransSub Update(EventTransSub record)
 {
     return(this.adapter.Update(record));
 }
Пример #9
0
 public EventTransSub Insert(EventTransSub record)
 {
     return(this.adapter.Insert(record));
 }
Пример #10
0
 public EventTransSub Insert(EventTransSub record)
 {
     return(this.repository.Insert(record));
 }
Пример #11
0
 public void Delete(EventTransSub record)
 {
     this.repository.Delete(record);
 }
Пример #12
0
 public EventTransSub Update(EventTransSub record)
 {
     return(this.repository.Update(record));
 }
Пример #13
0
 public void UpdateToRow(ref DataRow row, EventTransSub record)
 {
     EventTransSub.UpdateRowFromEventTransSub(ref row, record);
     this.ExtraUpdateToRow(ref row, record);
 }