コード例 #1
0
        public ActionResult personal()
        {
            PersonalDescription f = new PersonalDescription();

            f.Get();

            return(View("personal", f));
        }
コード例 #2
0
        public ActionResult personal(PersonalDescription f)
        {
            try
            {
                f.Set();
            }
            catch (RuleException e)
            {
                f.Errors.CopyToModelState(ModelState);
            }

            return(View("personal", f));
        }
コード例 #3
0
        public void Get()
        {
            Basic               basicGet      = new Basic(this.userId);
            Appearance          appearanceGet = new Appearance(this.userId);
            Interests           interestsGet  = new Interests(this.userId);
            Lifestyle           lifestyleGet  = new Lifestyle(this.userId);
            Values              valuesGet     = new Values(this.userId);
            Username            usernameGet   = new Username(this.userId);
            WelcomeMessage      welcomeGet    = new WelcomeMessage(this.userId);
            PersonalDescription personalGet   = new PersonalDescription(this.userId);

            basicGet.Get();
            this.BasicProperties = basicGet;


            appearanceGet.Get();
            this.AppearanceProperties = appearanceGet;


            interestsGet.Get();
            this.InterestsProperties = interestsGet;


            lifestyleGet.Get();
            this.LifestyleProperties = lifestyleGet;


            valuesGet.Get();
            this.ValuesProperties = valuesGet;


            usernameGet.Get();
            this.UsernameValue = usernameGet;


            welcomeGet.Get();
            this.WelcomeMessageProperties = welcomeGet;

            personalGet.Get();
            if (personalGet.About.Length < 246)
            {
                this.DescriptionLowResolution = personalGet.About + "&nbsp;...";
            }
            else
            {
                this.DescriptionLowResolution = personalGet.About.Substring(0, 245) + "&nbsp;...";
            }
        }