Example #1
0
        public void CopyFrom(ViewDocs ev, Model.ApplicationDbContext db)
        {
            this.CreatedByLogin = ev.CreatedByLogin;

            //var EvTime = new System.TimeSpan(ev.DocsInsertTime.Hour, ev.DocsInsertTime.Minute, 0);
            this.DocsName            = ev.DocsName;
            this.DocYear             = ev.DocYear;
            this.DocMonth            = ev.DocMonth;
            this.StausChangeDateTime = ev.StausChangeTime;
            this.DocType             = (int)ev.DocType;
            this.StausChangeDateTime = ev.StausChangeTime;
            this.DocWeek             = ev.DocWeek;
            this.InvoiceNo           = ev.InvoiceNo;
            this.IsForeign           = ev.IsForeign;
            this.Status = (int)ev.Status;

            this.ExternalLinkBig = ev.ExternalLinkBig;
            this.Description     = ev.Description;

            if (ev.OrganizerEvent != null && ev.OrganizerEvent != "")
            {
                this.OrganizerEvent = ev.OrganizerEvent;
            }

            this.OrganizerName = ev.OrganizerName;
            using (db)
            {
                var org = db.Organizers.Find(ev.OrganizerEvent);

                //this.OrganizerName = org.OrganizerName;
            }
        }
Example #2
0
 public BaseRepository()
 {
     context = Model.ApplicationDbContext.Create();
 }
Example #3
0
 public BookController(Model.ApplicationDbContext db)
 {
     _db = db;
 }