Exemple #1
0
        public IActionResult Index()
        {
            var viewModel = new AboutIndexVm();

            viewModel.ContactEmail    = "*****@*****.**";
            viewModel.CompanyFullName = "Spy Shop Incorperated";
            viewModel.AboutTitle      = "Welcome to Spy Shop";
            viewModel.AboutContent    = "<p>We deliver premium gadgets to help all Clouseaus and Bonds out there.<br />To start, have a loot at the <a href=\"/\">homepage</a>!</p>";

            return(View(viewModel));
        }
        public IActionResult Index()
        {
            //Create the View Model
            var viewModel = new AboutIndexVm();

            //Populate View Model
            viewModel.ContactEmail    = spyShopConfig.MailSettings.PublicInfoAddress;
            viewModel.CompanyFullName = spyShopConfig.FullCompanyName;
            viewModel.AboutTitle      = "Welcome to Spy Shop";
            viewModel.AboutContent    = "<p>We deliver premium gadgets to help all Clouseaus and Bonds out there.<br />To start, have a look at the <a href=\"/\">homepage</a>!</p>";

            //return View Model to the Index.cshtml view, by using the overloaded View() method
            return(View(viewModel));
        }