Exemple #1
0
        public async Task <ActionResult> Index(Contact contact, string lang)
        {
            var model = new HomePageModel();

            try
            {
                if (ModelState.IsValid)
                {
                    int b = await DbAdaptor.CreateContactAsync(contact);

                    if (b > 0)
                    {
                        //ToDo check int
                        ViewBag.SendMessage = Resources.Resource.Message_sent;
                        ModelState.Clear();
                    }
                }
                model.TeamMembers = await DbAdaptor.GetTeamMembersAsync(cultureName);

                model.Projects = await DbAdaptor.GetProjectsFullAsync(cultureName);
            }
            catch (Exception)
            {
                ViewBag.SendMessage = Resources.Resource.Message_not_sent;
            }
            return(View(model));
        }
Exemple #2
0
        public async Task <ActionResult> Index()
        {
            var model = new HomePageModel();

            model.TeamMembers = await DbAdaptor.GetTeamMembersAsync(cultureName);

            model.Projects = await DbAdaptor.GetProjectsFullAsync(cultureName);

            ViewBag.SendMessage = "";
            return(View(model));
        }
Exemple #3
0
        public async Task <ActionResult> Index()
        {
            var team = await DbAdaptor.GetTeamMembersAsync(cultureName);

            return(View(team));
        }
        public async Task <ActionResult> Index()
        {
            IList <TeamMember> list = await DbAdaptor.GetTeamMembersAsync();

            return(View(list));
        }