Exemplo n.º 1
0
        public List <BackgroundInfo> GetBackgroundInfo(int?id, Boolean isCurrentPosition)
        {
            BackgroundInfoBusinessLayer bibl             = new BackgroundInfoBusinessLayer();
            List <BackgroundInfo>       BackgroundInfoes = bibl.GetBackgroundInfoByID(id, isCurrentPosition);

            return(BackgroundInfoes);
        }
Exemplo n.º 2
0
        public void AddBackgroundInfo(BackgroundInfo BackgroundInfoClient)
        {
            var            manager     = new UserManager <ApplicationUser>(new UserStore <ApplicationUser>(new ApplicationDbContext()));
            var            currentUser = manager.FindById(User.Identity.GetUserId());
            int            id          = currentUser.UserInfo.Id;
            BackgroundInfo bi          = new BackgroundInfo();

            bi.UserInfoID        = id;
            bi.title             = BackgroundInfoClient.title;
            bi.type              = BackgroundInfoClient.type;
            bi.startDate         = BackgroundInfoClient.startDate;
            bi.endDate           = BackgroundInfoClient.endDate;
            bi.description       = BackgroundInfoClient.description;
            bi.isCurrentPosition = false;
            BackgroundInfoBusinessLayer biBal = new BackgroundInfoBusinessLayer();

            biBal.InsertBackgroundInfo(bi);
        }
Exemplo n.º 3
0
        public void DeleteBackgroundInfo(int?id)
        {
            BackgroundInfoBusinessLayer biBal = new BackgroundInfoBusinessLayer();

            biBal.DeleteBackgroundInfoByID(id);
        }
Exemplo n.º 4
0
        public void UpdateBackgroundInfo(BackgroundInfo BackgroundInfoClient)
        {
            BackgroundInfoBusinessLayer biBal = new BackgroundInfoBusinessLayer();

            biBal.UpdateBackgroundInfo(BackgroundInfoClient);
        }
Exemplo n.º 5
0
        public ActionResult GetBackgroundInfoByInfoID(int?id)
        {
            BackgroundInfoBusinessLayer biBal = new BackgroundInfoBusinessLayer();

            return(Json(biBal.GetBackgroundInfoByInfoID(id), JsonRequestBehavior.AllowGet));
        }