Example #1
0
        protected void Application_Start()
        {
            AreaRegistration.RegisterAllAreas();
            GlobalConfiguration.Configure(WebApiConfig.Register);
            FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
            RouteConfig.RegisterRoutes(RouteTable.Routes);
            BundleConfig.RegisterBundles(BundleTable.Bundles);

            // WebApiConfig.Register(GlobalConfiguration.Configuration);

            // Configure the MVC view Engine as the core one
            System.Web.Mvc.ViewEngines.Engines.Clear();
            System.Web.Mvc.ViewEngines.Engines.Add(new MulitTenantRazorViewEngine());
            var documentService = new DocumentQueryService <Tenant>();

            TenantService.Tenants = documentService.GetAll();
        }
        // GET: Tenant
        public ActionResult Index()
        {
            var model = DocumentQueryService.GetAll();

            return(View(model));
        }