public ActionResult Index(string url, string title) { var list = PermissionClientService.GetViewablePermissionResources("Admin"); this.ViewBag.Permissions = JsonConvert.SerializeObject(list); this.ViewBag.DefaultUrl = ControllerExtensions.GetReturnUrl(url, false); this.ViewBag.DefaultTitle = title; this.ViewBag.DisplayName = (this.User.Identity as PassportIdentity).DisplayName; return(this.View()); }
private ActionResult RedirectTo(string returnUrl) { returnUrl = ControllerExtensions.GetReturnUrl(returnUrl, false); if (string.IsNullOrEmpty(returnUrl)) { var svr = ObjectService.GetObject <IPassportAuthentication>(); returnUrl = svr.Setting.DefaultUrl; } return(this.Redirect(returnUrl)); }