Пример #1
0
        public ActionResult AllProfiles(ProfileList model)
        {
            var profiles = _usersProvider.GetAllProfilesOderBy();

            foreach (var profile in profiles)
            {
                var profileViewModel = new ProfileViewModel
                {
                    Surname     = profile.Surname,
                    Name        = profile.Name,
                    Middle_name = profile.MiddleName,
                    Email       = profile.Email,
                    Comments    = profile.Comments,
                    Phone       = profile.Phone,
                    Password    = profile.Password,
                    Upload      = profile.PhotoURL
                };
                model.ProfilesList.Add(profileViewModel);
            }
            return(View(model));
        }