예제 #1
0
 private static HtmlBuilder Breadcrumb(
     HtmlBuilder hb,
     Context context,
     SiteSettings ss,
     string controller,
     string display = null,
     string action  = null)
 {
     return(display != null
         ? hb.Breadcrumb(context : context, ss : ss, data : new Dictionary <string, string>
     {
         {
             Locations.Admins(context: context),
             Displays.Admin(context: context)
         },
         {
             (action == "Edit")
                     ? Locations.Edit(
                 context: context,
                 controller: controller)
                     : Locations.Index(
                 context: context,
                 controller: controller),
             display
         }
     })
         : hb.Breadcrumb(context: context, ss: ss, data: new Dictionary <string, string>
     {
         {
             Locations.Admins(context: context),
             Displays.Admin(context: context)
         }
     }));
 }
예제 #2
0
 private static string AdminsOrTop(Context context)
 {
     return(Permissions.CanManageTenant(context: context)
         ? Locations.Admins(context: context)
         : Locations.Top(context: context));
 }