예제 #1
0
        public ActionResult Update(mgt_UserProfile model, string UserMail = "")
        {
            var result = service.UpdateChild(model, UserMail);

            if (result.IsSuccess)
            {
            }

            return(Json(result));
        }
예제 #2
0
        public ActionResult ItemUserProfile(Guid itemID, string subject)
        {
            ViewBag.Subject = subject;

            var model = service.GetUserProfileByItem(itemID);

            if (model == null)
            {
                model = new mgt_UserProfile
                {
                    ItemID = itemID
                };
            }

            return(PartialView("_UserProfile", model));
        }
예제 #3
0
        public ActionResult UpdateMyChild(mgt_UserProfile model, bool IsCreate)
        {
            var result = new CiResult();

            model.CreateUser = SessionManager.UserID;
            if (IsCreate)
            {
                result = service.CreateMyChild(model);
            }
            else
            {
                result = service.UpdateMyChild(model);
            }

            return(Json(result));
        }
예제 #4
0
        private UserProfileWebModel TransModel(mgt_UserProfile model)
        {
            if (model == null)
            {
                return(null);
            }

            var result = new UserProfileWebModel
            {
                LastName    = model.LastName,
                FirstName   = model.FirstName,
                EngName     = model.EngName,
                NickName    = model.NickName,
                AvatarPath  = model.AvatarPath,
                Description = model.Description,
                // IdentityCard
                Birthday = model.Birthday,
                Gender   = model.Gender,
                Marriage = model.Marriage,
                // HomePhone
                // CompanyPhone
                SecondaryEmail = model.SecondaryEmail,
                // EmergencyContact
                // EmergencyPhone
                Unit          = model.Unit,
                UnitAddress   = model.UnitAddress,
                Occupation    = model.Occupation,
                Education     = model.Education,
                School        = model.School,
                Skill         = model.Skill,
                Language      = model.Language,
                SocialNetwork = model.SocialNetwork,
                // Sports
                Height     = model.Height,
                Weight     = model.Weight,
                Referrer   = model.Referrer,
                CreateTime = model.CreateTime,
                UpdateTime = model.UpdateTime
            };


            return(result);
        }
예제 #5
0
        public ActionResult ItemUserProfile(mgt_UserProfile model)
        {
            var result = service.UpdateItemUserProfile(model);

            return(Json(result));
        }