Merge pull request #82 from sbwalker/master
Hierarchical page management improvements
This commit is contained in:
commit
c79f77b28e
|
@ -12,7 +12,7 @@
|
||||||
<ul class="list-group">
|
<ul class="list-group">
|
||||||
@foreach (var p in pages)
|
@foreach (var p in pages)
|
||||||
{
|
{
|
||||||
if (p.IsNavigation && UserSecurity.IsAuthorized(PageState.User, "View", p.Permissions))
|
if (UserSecurity.IsAuthorized(PageState.User, "View", p.Permissions))
|
||||||
{
|
{
|
||||||
string url = NavigateUrl(p.Path);
|
string url = NavigateUrl(p.Path);
|
||||||
<li class="list-group-item">
|
<li class="list-group-item">
|
||||||
|
|
|
@ -44,7 +44,7 @@
|
||||||
<label for="Name" class="control-label">Permissions: </label>
|
<label for="Name" class="control-label">Permissions: </label>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<PermissionGrid EntityName="Module" Permissions="@permissions" @ref="permissiongrid" @ref:suppressField />
|
<PermissionGrid EntityName="Module" Permissions="@permissions" @ref="permissiongrid" />
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
|
|
|
@ -23,6 +23,14 @@
|
||||||
<input class="form-control" @bind="@name" />
|
<input class="form-control" @bind="@name" />
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
<label for="Name" class="control-label">Path: </label>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<input class="form-control" @bind="@path" />
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
<label for="Name" class="control-label">Parent: </label>
|
<label for="Name" class="control-label">Parent: </label>
|
||||||
|
@ -126,7 +134,7 @@
|
||||||
<label for="Name" class="control-label">Permissions: </label>
|
<label for="Name" class="control-label">Permissions: </label>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<PermissionGrid EntityName="Page" Permissions="@permissions" @ref="permissiongrid" @ref:suppressField />
|
<PermissionGrid EntityName="Page" Permissions="@permissions" @ref="permissiongrid" />
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
@ -142,7 +150,8 @@
|
||||||
Dictionary<string, string> panelayouts = new Dictionary<string, string>();
|
Dictionary<string, string> panelayouts = new Dictionary<string, string>();
|
||||||
|
|
||||||
List<Page> pages;
|
List<Page> pages;
|
||||||
string name = "";
|
string name;
|
||||||
|
string path = "";
|
||||||
string parentid;
|
string parentid;
|
||||||
string insert = ">>";
|
string insert = ">>";
|
||||||
List<Page> children;
|
List<Page> children;
|
||||||
|
@ -160,8 +169,8 @@
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
pages = PageState.Pages.Where(item => item.IsNavigation).ToList();
|
pages = PageState.Pages;
|
||||||
children = PageState.Pages.Where(item => item.ParentId == null && item.IsNavigation).OrderBy(item => item.Order).ToList();
|
children = PageState.Pages.Where(item => item.ParentId == null).ToList();
|
||||||
|
|
||||||
themes = ThemeService.GetThemeTypes(PageState.Themes);
|
themes = ThemeService.GetThemeTypes(PageState.Themes);
|
||||||
panelayouts = ThemeService.GetPaneLayoutTypes(PageState.Themes);
|
panelayouts = ThemeService.GetPaneLayoutTypes(PageState.Themes);
|
||||||
|
@ -184,11 +193,11 @@
|
||||||
parentid = (string)e.Value;
|
parentid = (string)e.Value;
|
||||||
if (string.IsNullOrEmpty(parentid))
|
if (string.IsNullOrEmpty(parentid))
|
||||||
{
|
{
|
||||||
children = PageState.Pages.Where(item => item.ParentId == null && item.IsNavigation).OrderBy(item => item.Order).ToList();
|
children = PageState.Pages.Where(item => item.ParentId == null).ToList();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
children = PageState.Pages.Where(item => item.ParentId == int.Parse(parentid) && item.IsNavigation).OrderBy(item => item.Order).ToList();
|
children = PageState.Pages.Where(item => item.ParentId == int.Parse(parentid)).ToList();
|
||||||
}
|
}
|
||||||
StateHasChanged();
|
StateHasChanged();
|
||||||
}
|
}
|
||||||
|
@ -205,16 +214,31 @@
|
||||||
Page page = new Page();
|
Page page = new Page();
|
||||||
page.SiteId = PageState.Page.SiteId;
|
page.SiteId = PageState.Page.SiteId;
|
||||||
page.Name = name;
|
page.Name = name;
|
||||||
|
if (path == "")
|
||||||
|
{
|
||||||
|
path = name;
|
||||||
|
}
|
||||||
|
if (path.Contains("/"))
|
||||||
|
{
|
||||||
|
path = path.Substring(path.LastIndexOf("/") + 1);
|
||||||
|
}
|
||||||
if (string.IsNullOrEmpty(parentid))
|
if (string.IsNullOrEmpty(parentid))
|
||||||
{
|
{
|
||||||
page.ParentId = null;
|
page.ParentId = null;
|
||||||
page.Path = page.Name.ToLower();
|
page.Path = Utilities.GetFriendlyUrl(path);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
page.ParentId = Int32.Parse(parentid);
|
page.ParentId = Int32.Parse(parentid);
|
||||||
Page parent = PageState.Pages.Where(item => item.ParentId == page.ParentId).FirstOrDefault();
|
Page parent = PageState.Pages.Where(item => item.PageId == page.ParentId).FirstOrDefault();
|
||||||
page.Path = parent.Path + "/" + page.Name.ToLower();
|
if (parent.Path == "")
|
||||||
|
{
|
||||||
|
page.Path = Utilities.GetFriendlyUrl(parent.Name) + "/" + Utilities.GetFriendlyUrl(path);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
page.Path = parent.Path + "/" + Utilities.GetFriendlyUrl(path);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
Page child;
|
Page child;
|
||||||
switch (insert)
|
switch (insert)
|
||||||
|
@ -255,7 +279,7 @@
|
||||||
await PageService.UpdatePageOrderAsync(page.SiteId, page.ParentId);
|
await PageService.UpdatePageOrderAsync(page.SiteId, page.ParentId);
|
||||||
|
|
||||||
PageState.Reload = Constants.ReloadSite;
|
PageState.Reload = Constants.ReloadSite;
|
||||||
NavigationManager.NavigateTo(NavigateUrl());
|
NavigationManager.NavigateTo(NavigateUrl(page.Path));
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
|
|
|
@ -108,7 +108,7 @@
|
||||||
<label for="Name" class="control-label">Permissions: </label>
|
<label for="Name" class="control-label">Permissions: </label>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<PermissionGrid EntityName="Page" Permissions="@permissions" @ref="permissiongrid" @ref:suppressField />
|
<PermissionGrid EntityName="Page" Permissions="@permissions" @ref="permissiongrid" />
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
<label for="Name" class="control-label">Path: </label>
|
<label for="Name" class="control-label">Path: </label>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<input class="form-control" @bind="@path" readonly />
|
<input class="form-control" @bind="@path" />
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
|
@ -39,9 +39,16 @@
|
||||||
<select class="form-control" @onchange="(e => ParentChanged(e))">
|
<select class="form-control" @onchange="(e => ParentChanged(e))">
|
||||||
<option value=""><Site Root></option>
|
<option value=""><Site Root></option>
|
||||||
@foreach (Page page in pages)
|
@foreach (Page page in pages)
|
||||||
|
{
|
||||||
|
if (page.PageId.ToString() == parentid)
|
||||||
|
{
|
||||||
|
<option value="@(page.PageId)" selected>@(new string('-', page.Level * 2))@(page.Name)</option>
|
||||||
|
}
|
||||||
|
else
|
||||||
{
|
{
|
||||||
<option value="@(page.PageId)">@(new string('-', page.Level * 2))@(page.Name)</option>
|
<option value="@(page.PageId)">@(new string('-', page.Level * 2))@(page.Name)</option>
|
||||||
}
|
}
|
||||||
|
}
|
||||||
</select>
|
</select>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
@ -51,7 +58,10 @@
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<select class="form-control" @bind="@insert">
|
<select class="form-control" @bind="@insert">
|
||||||
|
@if (parentid == currentparentid)
|
||||||
|
{
|
||||||
<option value=""><Maintain Current Location></option>
|
<option value=""><Maintain Current Location></option>
|
||||||
|
}
|
||||||
<option value="<<">To Beginning</option>
|
<option value="<<">To Beginning</option>
|
||||||
@if (children != null && children.Count > 0)
|
@if (children != null && children.Count > 0)
|
||||||
{
|
{
|
||||||
|
@ -135,7 +145,7 @@
|
||||||
<label for="Name" class="control-label">Permissions: </label>
|
<label for="Name" class="control-label">Permissions: </label>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<PermissionGrid EntityName="Page" Permissions="@permissions" @ref="permissiongrid" @ref:suppressField />
|
<PermissionGrid EntityName="Page" Permissions="@permissions" @ref="permissiongrid" />
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
|
@ -157,6 +167,7 @@
|
||||||
int PageId;
|
int PageId;
|
||||||
string name;
|
string name;
|
||||||
string path;
|
string path;
|
||||||
|
string currentparentid;
|
||||||
string parentid;
|
string parentid;
|
||||||
string insert = "";
|
string insert = "";
|
||||||
List<Page> children;
|
List<Page> children;
|
||||||
|
@ -178,8 +189,8 @@
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
pages = PageState.Pages.Where(item => item.IsNavigation).ToList();
|
pages = PageState.Pages;
|
||||||
children = PageState.Pages.Where(item => item.ParentId == null && item.IsNavigation).OrderBy(item => item.Order).ToList();
|
children = PageState.Pages.Where(item => item.ParentId == null).ToList();
|
||||||
|
|
||||||
themes = ThemeService.GetThemeTypes(PageState.Themes);
|
themes = ThemeService.GetThemeTypes(PageState.Themes);
|
||||||
panelayouts = ThemeService.GetPaneLayoutTypes(PageState.Themes);
|
panelayouts = ThemeService.GetPaneLayoutTypes(PageState.Themes);
|
||||||
|
@ -190,6 +201,10 @@
|
||||||
{
|
{
|
||||||
name = page.Name;
|
name = page.Name;
|
||||||
path = page.Path;
|
path = page.Path;
|
||||||
|
if (path.Contains("/"))
|
||||||
|
{
|
||||||
|
path = path.Substring(path.LastIndexOf("/") + 1);
|
||||||
|
}
|
||||||
if (page.ParentId == null)
|
if (page.ParentId == null)
|
||||||
{
|
{
|
||||||
parentid = "";
|
parentid = "";
|
||||||
|
@ -198,6 +213,7 @@
|
||||||
{
|
{
|
||||||
parentid = page.ParentId.ToString();
|
parentid = page.ParentId.ToString();
|
||||||
}
|
}
|
||||||
|
currentparentid = parentid;
|
||||||
isnavigation = page.IsNavigation.ToString();
|
isnavigation = page.IsNavigation.ToString();
|
||||||
editmode = page.EditMode.ToString();
|
editmode = page.EditMode.ToString();
|
||||||
themetype = page.ThemeType;
|
themetype = page.ThemeType;
|
||||||
|
@ -223,11 +239,19 @@
|
||||||
parentid = (string)e.Value;
|
parentid = (string)e.Value;
|
||||||
if (string.IsNullOrEmpty(parentid))
|
if (string.IsNullOrEmpty(parentid))
|
||||||
{
|
{
|
||||||
children = PageState.Pages.Where(item => item.ParentId == null && item.IsNavigation).OrderBy(item => item.Order).ToList();
|
children = PageState.Pages.Where(item => item.ParentId == null).ToList();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
children = PageState.Pages.Where(item => item.ParentId == int.Parse(parentid) && item.IsNavigation).OrderBy(item => item.Order).ToList();
|
children = PageState.Pages.Where(item => item.ParentId == int.Parse(parentid)).ToList();
|
||||||
|
}
|
||||||
|
if (parentid == currentparentid)
|
||||||
|
{
|
||||||
|
insert = "";
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
insert = ">>";
|
||||||
}
|
}
|
||||||
StateHasChanged();
|
StateHasChanged();
|
||||||
}
|
}
|
||||||
|
@ -241,20 +265,35 @@
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
Page page = PageState.Page;
|
Page page = PageState.Pages.Where(item => item.PageId == PageId).FirstOrDefault();
|
||||||
int? currentparentid = page.ParentId;
|
string currentpath = page.Path;
|
||||||
page.PageId = Int32.Parse(PageState.QueryString["id"]);
|
|
||||||
page.Name = name;
|
page.Name = name;
|
||||||
|
if (path == "")
|
||||||
|
{
|
||||||
|
path = name;
|
||||||
|
}
|
||||||
|
if (path.Contains("/"))
|
||||||
|
{
|
||||||
|
path = path.Substring(path.LastIndexOf("/") + 1);
|
||||||
|
}
|
||||||
if (string.IsNullOrEmpty(parentid))
|
if (string.IsNullOrEmpty(parentid))
|
||||||
{
|
{
|
||||||
page.ParentId = null;
|
page.ParentId = null;
|
||||||
page.Path = page.Name.ToLower();
|
page.Path = Utilities.GetFriendlyUrl(path);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
page.ParentId = Int32.Parse(parentid);
|
page.ParentId = Int32.Parse(parentid);
|
||||||
Page parent = PageState.Pages.Where(item => item.ParentId == page.ParentId).FirstOrDefault();
|
Page parent = PageState.Pages.Where(item => item.PageId == page.ParentId).FirstOrDefault();
|
||||||
page.Path = parent.Path + "/" + page.Name.ToLower();
|
if (parent.Path == "")
|
||||||
|
{
|
||||||
|
page.Path = Utilities.GetFriendlyUrl(parent.Name) + "/" + Utilities.GetFriendlyUrl(path);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
page.Path = parent.Path + "/" + Utilities.GetFriendlyUrl(path);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (insert != "")
|
if (insert != "")
|
||||||
{
|
{
|
||||||
|
@ -296,10 +335,27 @@
|
||||||
page.Permissions = permissiongrid.GetPermissions();
|
page.Permissions = permissiongrid.GetPermissions();
|
||||||
await PageService.UpdatePageAsync(page);
|
await PageService.UpdatePageAsync(page);
|
||||||
await PageService.UpdatePageOrderAsync(page.SiteId, page.ParentId);
|
await PageService.UpdatePageOrderAsync(page.SiteId, page.ParentId);
|
||||||
await PageService.UpdatePageOrderAsync(page.SiteId, currentparentid);
|
if (currentparentid == "")
|
||||||
|
{
|
||||||
|
await PageService.UpdatePageOrderAsync(page.SiteId, null);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
await PageService.UpdatePageOrderAsync(page.SiteId, int.Parse(currentparentid));
|
||||||
|
}
|
||||||
|
|
||||||
|
// update child paths
|
||||||
|
if (parentid != currentparentid)
|
||||||
|
{
|
||||||
|
foreach (Page p in PageState.Pages.Where(item => item.Path.StartsWith(currentpath)))
|
||||||
|
{
|
||||||
|
p.Path = p.Path.Replace(currentpath, page.Path);
|
||||||
|
await PageService.UpdatePageAsync(p);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
PageState.Reload = Constants.ReloadSite;
|
PageState.Reload = Constants.ReloadSite;
|
||||||
NavigationManager.NavigateTo(NavigateUrl());
|
NavigationManager.NavigateTo(NavigateUrl(page.Path));
|
||||||
}
|
}
|
||||||
catch (Exception ex)
|
catch (Exception ex)
|
||||||
{
|
{
|
||||||
|
|
|
@ -140,8 +140,12 @@
|
||||||
pages = PageState.Pages;
|
pages = PageState.Pages;
|
||||||
}
|
}
|
||||||
|
|
||||||
// get Url path and querystring
|
// get Url path and querystring ( and remove anchors )
|
||||||
string path = new Uri(_absoluteUri).PathAndQuery.Substring(1);
|
string path = new Uri(_absoluteUri).PathAndQuery.Substring(1);
|
||||||
|
if (path.IndexOf("#") != -1)
|
||||||
|
{
|
||||||
|
path = path.Substring(0, path.IndexOf("#"));
|
||||||
|
}
|
||||||
|
|
||||||
// parse querystring and remove
|
// parse querystring and remove
|
||||||
Dictionary<string, string> querystring = new Dictionary<string, string>();
|
Dictionary<string, string> querystring = new Dictionary<string, string>();
|
||||||
|
@ -189,6 +193,13 @@
|
||||||
{
|
{
|
||||||
page = PageState.Page;
|
page = PageState.Page;
|
||||||
}
|
}
|
||||||
|
// failsafe in case router cannot locate the home page for the site
|
||||||
|
if (page == null && path == "")
|
||||||
|
{
|
||||||
|
page = pages.FirstOrDefault();
|
||||||
|
path = page.Path;
|
||||||
|
}
|
||||||
|
|
||||||
// check if page has changed
|
// check if page has changed
|
||||||
if (page.Path != path)
|
if (page.Path != path)
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
using Oqtane.Models;
|
using System.Globalization;
|
||||||
using System;
|
using System.Text;
|
||||||
using System.Collections.Generic;
|
|
||||||
using System.Linq;
|
|
||||||
|
|
||||||
namespace Oqtane.Shared
|
namespace Oqtane.Shared
|
||||||
{
|
{
|
||||||
|
@ -66,5 +64,128 @@ namespace Oqtane.Shared
|
||||||
string[] fragments = typename.Split('.');
|
string[] fragments = typename.Split('.');
|
||||||
return fragments[fragments.Length - 1];
|
return fragments[fragments.Length - 1];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static string GetFriendlyUrl(string text)
|
||||||
|
{
|
||||||
|
string result = "";
|
||||||
|
if (text != null)
|
||||||
|
{
|
||||||
|
var normalizedString = text.ToLowerInvariant().Normalize(NormalizationForm.FormD);
|
||||||
|
var stringBuilder = new StringBuilder();
|
||||||
|
var stringLength = normalizedString.Length;
|
||||||
|
var prevdash = false;
|
||||||
|
char c;
|
||||||
|
for (int i = 0; i < stringLength; i++)
|
||||||
|
{
|
||||||
|
c = normalizedString[i];
|
||||||
|
switch (CharUnicodeInfo.GetUnicodeCategory(c))
|
||||||
|
{
|
||||||
|
case UnicodeCategory.LowercaseLetter:
|
||||||
|
case UnicodeCategory.UppercaseLetter:
|
||||||
|
case UnicodeCategory.DecimalDigitNumber:
|
||||||
|
if (c < 128)
|
||||||
|
stringBuilder.Append(c);
|
||||||
|
else
|
||||||
|
stringBuilder.Append(RemapInternationalCharToAscii(c));
|
||||||
|
prevdash = false;
|
||||||
|
break;
|
||||||
|
case UnicodeCategory.SpaceSeparator:
|
||||||
|
case UnicodeCategory.ConnectorPunctuation:
|
||||||
|
case UnicodeCategory.DashPunctuation:
|
||||||
|
case UnicodeCategory.OtherPunctuation:
|
||||||
|
case UnicodeCategory.MathSymbol:
|
||||||
|
if (!prevdash)
|
||||||
|
{
|
||||||
|
stringBuilder.Append('-');
|
||||||
|
prevdash = true;
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
result = stringBuilder.ToString().Trim('-');
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static string RemapInternationalCharToAscii(char c)
|
||||||
|
{
|
||||||
|
string s = c.ToString().ToLowerInvariant();
|
||||||
|
if ("àåáâäãåą".Contains(s))
|
||||||
|
{
|
||||||
|
return "a";
|
||||||
|
}
|
||||||
|
else if ("èéêëę".Contains(s))
|
||||||
|
{
|
||||||
|
return "e";
|
||||||
|
}
|
||||||
|
else if ("ìíîïı".Contains(s))
|
||||||
|
{
|
||||||
|
return "i";
|
||||||
|
}
|
||||||
|
else if ("òóôõöøőð".Contains(s))
|
||||||
|
{
|
||||||
|
return "o";
|
||||||
|
}
|
||||||
|
else if ("ùúûüŭů".Contains(s))
|
||||||
|
{
|
||||||
|
return "u";
|
||||||
|
}
|
||||||
|
else if ("çćčĉ".Contains(s))
|
||||||
|
{
|
||||||
|
return "c";
|
||||||
|
}
|
||||||
|
else if ("żźž".Contains(s))
|
||||||
|
{
|
||||||
|
return "z";
|
||||||
|
}
|
||||||
|
else if ("śşšŝ".Contains(s))
|
||||||
|
{
|
||||||
|
return "s";
|
||||||
|
}
|
||||||
|
else if ("ñń".Contains(s))
|
||||||
|
{
|
||||||
|
return "n";
|
||||||
|
}
|
||||||
|
else if ("ýÿ".Contains(s))
|
||||||
|
{
|
||||||
|
return "y";
|
||||||
|
}
|
||||||
|
else if ("ğĝ".Contains(s))
|
||||||
|
{
|
||||||
|
return "g";
|
||||||
|
}
|
||||||
|
else if (c == 'ř')
|
||||||
|
{
|
||||||
|
return "r";
|
||||||
|
}
|
||||||
|
else if (c == 'ł')
|
||||||
|
{
|
||||||
|
return "l";
|
||||||
|
}
|
||||||
|
else if (c == 'đ')
|
||||||
|
{
|
||||||
|
return "d";
|
||||||
|
}
|
||||||
|
else if (c == 'ß')
|
||||||
|
{
|
||||||
|
return "ss";
|
||||||
|
}
|
||||||
|
else if (c == 'þ')
|
||||||
|
{
|
||||||
|
return "th";
|
||||||
|
}
|
||||||
|
else if (c == 'ĥ')
|
||||||
|
{
|
||||||
|
return "h";
|
||||||
|
}
|
||||||
|
else if (c == 'ĵ')
|
||||||
|
{
|
||||||
|
return "j";
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return "";
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -21,19 +21,23 @@
|
||||||
<div class="overlay-content">
|
<div class="overlay-content">
|
||||||
<ul class="nav flex-column">
|
<ul class="nav flex-column">
|
||||||
<li class="nav-item px-3">
|
<li class="nav-item px-3">
|
||||||
<NavLink class="btn btn-primary" href="@PageUrl("Add")" Match="NavLinkMatch.All">Add Page</NavLink>
|
<NavLink class="btn btn-primary mx-auto" href="@PageUrl("Add")">Add Page</NavLink>
|
||||||
</li>
|
</li>
|
||||||
<li class="nav-item px-3">
|
<li class="nav-item px-3">
|
||||||
<NavLink class="btn btn-primary" href="@PageUrl("Edit")" Match="NavLinkMatch.All">Edit Page</NavLink>
|
<NavLink class="btn btn-primary mx-auto" href="@PageUrl("Edit")">Edit Page</NavLink>
|
||||||
</li>
|
</li>
|
||||||
<li class="nav-item px-3">
|
<li class="nav-item px-3">
|
||||||
<NavLink class="btn btn-primary" href="@PageUrl("Delete")" Match="NavLinkMatch.All">Delete Page</NavLink>
|
<NavLink class="btn btn-primary mx-auto" href="@PageUrl("Delete")">Delete Page</NavLink>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
<hr style="width: 100%; color: white; height: 1px; background-color:white;" />
|
<hr style="width: 100%; color: white; height: 1px; background-color:white;" />
|
||||||
<div class="container">
|
<div class="container">
|
||||||
<div class="form-group">
|
<table class="table table-borderless">
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
<label for="Module" class="control-label" style="color: white !important;">Module: </label>
|
<label for="Module" class="control-label" style="color: white !important;">Module: </label>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
@if (moduledefinitions != null)
|
@if (moduledefinitions != null)
|
||||||
{
|
{
|
||||||
<select class="form-control" @bind="@moduledefinitionname">
|
<select class="form-control" @bind="@moduledefinitionname">
|
||||||
|
@ -44,9 +48,13 @@
|
||||||
}
|
}
|
||||||
</select>
|
</select>
|
||||||
}
|
}
|
||||||
</div>
|
</td>
|
||||||
<div class="form-group">
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
<label for="Pane" class="control-label" style="color: white !important;">Pane: </label>
|
<label for="Pane" class="control-label" style="color: white !important;">Pane: </label>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
<select class="form-control" @bind="@pane">
|
<select class="form-control" @bind="@pane">
|
||||||
<option value=""><Select Pane></option>
|
<option value=""><Select Pane></option>
|
||||||
@foreach (string pane in PageState.Page.Panes.Split(new[] { ';' }, StringSplitOptions.RemoveEmptyEntries))
|
@foreach (string pane in PageState.Page.Panes.Split(new[] { ';' }, StringSplitOptions.RemoveEmptyEntries))
|
||||||
|
@ -54,13 +62,21 @@
|
||||||
<option value="@pane">@pane Pane</option>
|
<option value="@pane">@pane Pane</option>
|
||||||
}
|
}
|
||||||
</select>
|
</select>
|
||||||
</div>
|
</td>
|
||||||
<div class="form-group">
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
<label for="Title" class="control-label" style="color: white !important;">Title: </label>
|
<label for="Title" class="control-label" style="color: white !important;">Title: </label>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
<input type="text" name="Title" class="form-control" @bind="@title" />
|
<input type="text" name="Title" class="form-control" @bind="@title" />
|
||||||
</div>
|
</td>
|
||||||
<div class="form-group">
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
<label for="Container" class="control-label" style="color: white !important;">Container: </label>
|
<label for="Container" class="control-label" style="color: white !important;">Container: </label>
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
<select class="form-control" @bind="@containertype">
|
<select class="form-control" @bind="@containertype">
|
||||||
<option value=""><Select Container></option>
|
<option value=""><Select Container></option>
|
||||||
@foreach (KeyValuePair<string, string> container in containers)
|
@foreach (KeyValuePair<string, string> container in containers)
|
||||||
|
@ -68,9 +84,17 @@
|
||||||
<option value="@container.Key">@container.Value</option>
|
<option value="@container.Key">@container.Value</option>
|
||||||
}
|
}
|
||||||
</select>
|
</select>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
<button type="button" class="btn btn-primary mx-auto" style="width: 100%;" @onclick="@AddModule">Add Module To Page</button>
|
||||||
</div>
|
</div>
|
||||||
<button type="button" class="btn btn-primary" @onclick="AddModule">Add Module To Page</button>
|
<hr style="width: 100%; color: white; height: 1px; background-color:white;" />
|
||||||
</div>
|
<ul class="nav flex-column">
|
||||||
|
<li class="nav-item px-3">
|
||||||
|
<NavLink class="btn btn-primary mx-auto" href="@NavigateUrl("admin")">Admin Dashboard</NavLink>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
|
@ -6,57 +6,53 @@
|
||||||
@using Oqtane.Security
|
@using Oqtane.Security
|
||||||
@namespace Oqtane.Themes.Controls
|
@namespace Oqtane.Themes.Controls
|
||||||
@inherits ThemeObjectBase
|
@inherits ThemeObjectBase
|
||||||
@inject IPageService PageService
|
|
||||||
@inject IUserService UserService
|
@inject IUserService UserService
|
||||||
|
|
||||||
<ul class="nav flex-column">
|
@if (menu != "")
|
||||||
@if (parent != null)
|
{
|
||||||
{
|
@((MarkupString)menu)
|
||||||
string url = NavigateUrl();
|
}
|
||||||
<li class="nav-item px-3">
|
|
||||||
<NavLink class="nav-link" href="@parent.Path" Match="NavLinkMatch.All">
|
|
||||||
<span class="oi oi-media-skip-backward" aria-hidden="true"></span> Back
|
|
||||||
</NavLink>
|
|
||||||
</li>
|
|
||||||
}
|
|
||||||
@foreach (var p in pages)
|
|
||||||
{
|
|
||||||
if (p.IsNavigation && UserSecurity.IsAuthorized(PageState.User, "View", p.Permissions))
|
|
||||||
{
|
|
||||||
string url = NavigateUrl(p.Path);
|
|
||||||
<li class="nav-item px-3">
|
|
||||||
<NavLink @key="@p.PageId" class="nav-link" href="@url" Match="NavLinkMatch.All">
|
|
||||||
<span class="oi @p.Icon" aria-hidden="true"></span> @p.Name
|
|
||||||
</NavLink>
|
|
||||||
</li>
|
|
||||||
}
|
|
||||||
}
|
|
||||||
</ul>
|
|
||||||
|
|
||||||
@code {
|
@code {
|
||||||
List<Page> pages;
|
string menu = "";
|
||||||
Page parent = null;
|
|
||||||
|
|
||||||
protected override Task OnParametersSetAsync()
|
protected override void OnInitialized()
|
||||||
{
|
{
|
||||||
// if current page has no children
|
int level = -1;
|
||||||
if (PageState.Pages.Where(item => item.ParentId == PageState.Page.PageId).FirstOrDefault() == null)
|
int securitylevel = int.MaxValue;
|
||||||
|
|
||||||
|
menu = "<ul class=\"nav flex-column\">\n";
|
||||||
|
|
||||||
|
foreach (Page p in PageState.Pages.Where(item => item.IsNavigation))
|
||||||
{
|
{
|
||||||
// display list of pages which have same parent as current page
|
if (UserSecurity.IsAuthorized(PageState.User, "View", p.Permissions) && p.Level <= securitylevel)
|
||||||
pages = PageState.Pages.Where(item => item.ParentId == PageState.Page.ParentId).OrderBy(item => item.Order).ToList();
|
|
||||||
// if current page has parent
|
|
||||||
if (PageState.Page.ParentId != null)
|
|
||||||
{
|
{
|
||||||
parent = PageState.Pages.Where(item => item.PageId == PageState.Page.ParentId).FirstOrDefault();
|
securitylevel = int.MaxValue;
|
||||||
|
|
||||||
|
menu += "<li class=\"nav-item px-3\">";
|
||||||
|
menu += "<a href=\"" + NavigateUrl(p.Path) + "\" class=\"nav-link\" style=\"padding-left: " + ((p.Level + 1) * 15).ToString() + "px !important;\">";
|
||||||
|
if (p.HasChildren)
|
||||||
|
{
|
||||||
|
menu += "<i class=\"oi oi-chevron-right\"></i>";
|
||||||
}
|
}
|
||||||
|
if (p.Icon != "")
|
||||||
|
{
|
||||||
|
menu += "<span class=\"oi " + p.Icon + "\" aria-hidden=\"true\"></span>";
|
||||||
|
}
|
||||||
|
menu += p.Name;
|
||||||
|
menu += "</a>\n";
|
||||||
|
menu += "</li>\n";
|
||||||
|
|
||||||
|
level = p.Level;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// display list of pages which are children of current page
|
if (securitylevel == int.MaxValue)
|
||||||
pages = PageState.Pages.Where(item => item.ParentId == PageState.Page.PageId).OrderBy(item => item.Order).ToList();
|
{
|
||||||
// current page is parent
|
securitylevel = p.Level;
|
||||||
parent = PageState.Pages.Where(item => item.ParentId == PageState.Page.ParentId).FirstOrDefault();
|
|
||||||
}
|
}
|
||||||
return Task.CompletedTask;
|
}
|
||||||
|
}
|
||||||
|
menu += "</ul>";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,69 +0,0 @@
|
||||||
@using Microsoft.AspNetCore.Components.Routing
|
|
||||||
@using Microsoft.AspNetCore.Components.Web
|
|
||||||
@using Oqtane.Themes
|
|
||||||
@using Oqtane.Services
|
|
||||||
@using Oqtane.Models;
|
|
||||||
@using Oqtane.Security
|
|
||||||
@namespace Oqtane.Themes.Controls
|
|
||||||
@inherits ThemeObjectBase
|
|
||||||
@inject IUserService UserService
|
|
||||||
|
|
||||||
@if (menu != "")
|
|
||||||
{
|
|
||||||
@((MarkupString)menu)
|
|
||||||
}
|
|
||||||
|
|
||||||
@code {
|
|
||||||
string menu = "";
|
|
||||||
|
|
||||||
protected override void OnInitialized()
|
|
||||||
{
|
|
||||||
int level = -1;
|
|
||||||
int securitylevel = int.MaxValue;
|
|
||||||
|
|
||||||
menu = "<ul class=\"nav flex-column\">\n";
|
|
||||||
foreach (Page p in PageState.Pages.Where(item => item.IsNavigation))
|
|
||||||
{
|
|
||||||
for (int l = p.Level; l < level; l++)
|
|
||||||
{
|
|
||||||
menu += "</ul>\n";
|
|
||||||
menu += "</div>\n";
|
|
||||||
}
|
|
||||||
if (UserSecurity.IsAuthorized(PageState.User, "View", p.Permissions) && p.Level <= securitylevel)
|
|
||||||
{
|
|
||||||
securitylevel = int.MaxValue;
|
|
||||||
if (p.HasChildren)
|
|
||||||
{
|
|
||||||
menu += "<li class=\"nav-item px-3\">\n";
|
|
||||||
menu += "<a class=\"nav-link collapsed\" href=\"#submenu" + p.PageId.ToString() + "\" data-toggle=\"collapse\" data-target=\"#submenu" + p.PageId.ToString() + "\">";
|
|
||||||
menu += "<span class=\"oi " + p.Icon + "\" aria-hidden=\"true\"></span>" + p.Name;
|
|
||||||
menu += "</a>\n";
|
|
||||||
menu += "<div class=\"collapse\" id=\"submenu" + p.PageId.ToString() + "\" aria-expanded=\"false\">\n";
|
|
||||||
menu += "<ul class=\"nav flex-column\">\n";
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
menu += "<li class=\"nav-item px-3\">\n";
|
|
||||||
menu += "<a class=\"nav-link\" href=\"" + NavigateUrl(p.Path) + "\">";
|
|
||||||
menu += "<span class=\"oi " + p.Icon + "\" aria-hidden=\"true\"></span>" + p.Name;
|
|
||||||
menu += "</a>\n";
|
|
||||||
menu += "</li>\n";
|
|
||||||
}
|
|
||||||
level = p.Level;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
if (securitylevel == int.MaxValue)
|
|
||||||
{
|
|
||||||
securitylevel = p.Level;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
for (int l = 0; l < level; l++)
|
|
||||||
{
|
|
||||||
menu += "</ul>\n";
|
|
||||||
menu += "</div>\n";
|
|
||||||
}
|
|
||||||
menu += "</ul>";
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -439,49 +439,49 @@ GO
|
||||||
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 3, 'Edit', 1, null, 1, '', getdate(), '', getdate())
|
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 3, 'Edit', 1, null, 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Page] ([PageId], [SiteId], [Name], [Path], [ThemeType], [Icon], [Panes], [ParentId], [Order], [IsNavigation], [LayoutType], [EditMode], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
|
INSERT [dbo].[Page] ([PageId], [SiteId], [Name], [Path], [ThemeType], [Icon], [Panes], [ParentId], [Order], [IsNavigation], [LayoutType], [EditMode], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
|
||||||
VALUES (4, 1, N'Admin', N'admin', N'Oqtane.Themes.Theme2.Theme2, Oqtane.Client', N'oi-home', N'Top;Bottom', NULL, 7, 1, N'', '', 1, getdate(), '', getdate())
|
VALUES (4, 1, N'Admin', N'admin', N'Oqtane.Themes.Theme2.Theme2, Oqtane.Client', N'oi-home', N'Top;Bottom', NULL, 7, 0, N'', '', 1, getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 4, 'View', 1, null, 1, '', getdate(), '', getdate())
|
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 4, 'View', 1, null, 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 4, 'Edit', 1, null, 1, '', getdate(), '', getdate())
|
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 4, 'Edit', 1, null, 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Page] ([PageId], [SiteId], [Name], [Path], [ThemeType], [Icon], [Panes], [ParentId], [Order], [IsNavigation], [LayoutType], [EditMode], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
|
INSERT [dbo].[Page] ([PageId], [SiteId], [Name], [Path], [ThemeType], [Icon], [Panes], [ParentId], [Order], [IsNavigation], [LayoutType], [EditMode], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
|
||||||
VALUES (8, 1, N'Site Management', N'admin/sites', N'Oqtane.Themes.Theme2.Theme2, Oqtane.Client', N'', N'Top;Bottom', 4, 1, 1, N'', 1, '', getdate(), '', getdate())
|
VALUES (8, 1, N'Site Management', N'admin/sites', N'Oqtane.Themes.Theme2.Theme2, Oqtane.Client', N'', N'Top;Bottom', 4, 1, 0, N'', 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 8, 'View', 1, null, 1, '', getdate(), '', getdate())
|
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 8, 'View', 1, null, 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 8, 'Edit', 1, null, 1, '', getdate(), '', getdate())
|
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 8, 'Edit', 1, null, 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Page] ([PageId], [SiteId], [Name], [Path], [ThemeType], [Icon], [Panes], [ParentId], [Order], [IsNavigation], [LayoutType], [EditMode], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
|
INSERT [dbo].[Page] ([PageId], [SiteId], [Name], [Path], [ThemeType], [Icon], [Panes], [ParentId], [Order], [IsNavigation], [LayoutType], [EditMode], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
|
||||||
VALUES (5, 1, N'Page Management', N'admin/pages', N'Oqtane.Themes.Theme2.Theme2, Oqtane.Client', N'', N'Top;Bottom', 4, 3, 1, N'', 1, '', getdate(), '', getdate())
|
VALUES (5, 1, N'Page Management', N'admin/pages', N'Oqtane.Themes.Theme2.Theme2, Oqtane.Client', N'', N'Top;Bottom', 4, 3, 0, N'', 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 5, 'View', 1, null, 1, '', getdate(), '', getdate())
|
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 5, 'View', 1, null, 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 5, 'Edit', 1, null, 1, '', getdate(), '', getdate())
|
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 5, 'Edit', 1, null, 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Page] ([PageId], [SiteId], [Name], [Path], [ThemeType], [Icon], [Panes], [ParentId], [Order], [IsNavigation], [LayoutType], [EditMode], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
|
INSERT [dbo].[Page] ([PageId], [SiteId], [Name], [Path], [ThemeType], [Icon], [Panes], [ParentId], [Order], [IsNavigation], [LayoutType], [EditMode], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
|
||||||
VALUES (10, 1, N'Module Management', N'admin/modules', N'Oqtane.Themes.Theme2.Theme2, Oqtane.Client', N'', N'Top;Bottom', 4, 5, 1, N'', 1, '', getdate(), '', getdate())
|
VALUES (10, 1, N'Module Management', N'admin/modules', N'Oqtane.Themes.Theme2.Theme2, Oqtane.Client', N'', N'Top;Bottom', 4, 5, 0, N'', 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 10, 'View', 1, null, 1, '', getdate(), '', getdate())
|
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 10, 'View', 1, null, 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 10, 'Edit', 1, null, 1, '', getdate(), '', getdate())
|
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 10, 'Edit', 1, null, 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Page] ([PageId], [SiteId], [Name], [Path], [ThemeType], [Icon], [Panes], [ParentId], [Order], [IsNavigation], [LayoutType], [EditMode], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
|
INSERT [dbo].[Page] ([PageId], [SiteId], [Name], [Path], [ThemeType], [Icon], [Panes], [ParentId], [Order], [IsNavigation], [LayoutType], [EditMode], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
|
||||||
VALUES (11, 1, N'Theme Management', N'admin/themes', N'Oqtane.Themes.Theme2.Theme2, Oqtane.Client', N'', N'Top;Bottom', 4, 7, 1, N'', 1, '', getdate(), '', getdate())
|
VALUES (11, 1, N'Theme Management', N'admin/themes', N'Oqtane.Themes.Theme2.Theme2, Oqtane.Client', N'', N'Top;Bottom', 4, 7, 0, N'', 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 11, 'View', 1, null, 1, '', getdate(), '', getdate())
|
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 11, 'View', 1, null, 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 11, 'Edit', 1, null, 1, '', getdate(), '', getdate())
|
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 11, 'Edit', 1, null, 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Page] ([PageId], [SiteId], [Name], [Path], [ThemeType], [Icon], [Panes], [ParentId], [Order], [IsNavigation], [LayoutType], [EditMode], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
|
INSERT [dbo].[Page] ([PageId], [SiteId], [Name], [Path], [ThemeType], [Icon], [Panes], [ParentId], [Order], [IsNavigation], [LayoutType], [EditMode], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
|
||||||
VALUES (9, 1, N'User Management', N'admin/users', N'Oqtane.Themes.Theme2.Theme2, Oqtane.Client', N'', N'Top;Bottom', 4, 9, 1, N'', 1, '', getdate(), '', getdate())
|
VALUES (9, 1, N'User Management', N'admin/users', N'Oqtane.Themes.Theme2.Theme2, Oqtane.Client', N'', N'Top;Bottom', 4, 9, 0, N'', 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 9, 'View', 1, null, 1, '', getdate(), '', getdate())
|
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 9, 'View', 1, null, 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 9, 'Edit', 1, null, 1, '', getdate(), '', getdate())
|
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 9, 'Edit', 1, null, 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Page] ([PageId], [SiteId], [Name], [Path], [ThemeType], [Icon], [Panes], [ParentId], [Order], [IsNavigation], [LayoutType], [EditMode], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
|
INSERT [dbo].[Page] ([PageId], [SiteId], [Name], [Path], [ThemeType], [Icon], [Panes], [ParentId], [Order], [IsNavigation], [LayoutType], [EditMode], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
|
||||||
VALUES (16, 1, N'Role Management', N'admin/roles', N'Oqtane.Themes.Theme2.Theme2, Oqtane.Client', N'', N'Top;Bottom', 4, 11, 1, N'', 1, '', getdate(), '', getdate())
|
VALUES (16, 1, N'Role Management', N'admin/roles', N'Oqtane.Themes.Theme2.Theme2, Oqtane.Client', N'', N'Top;Bottom', 4, 11, 0, N'', 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 16, 'View', 1, null, 1, '', getdate(), '', getdate())
|
INSERT [dbo].[Permission] ([SiteId], [EntityName], [EntityId], [PermissionName], [RoleId], [UserId], [IsAuthorized], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn]) VALUES (1, 'Page', 16, 'View', 1, null, 1, '', getdate(), '', getdate())
|
||||||
GO
|
GO
|
||||||
|
|
|
@ -76,14 +76,6 @@ app {
|
||||||
color: white;
|
color: white;
|
||||||
}
|
}
|
||||||
|
|
||||||
.nav-link[data-toggle].collapsed:after {
|
|
||||||
content: "▾";
|
|
||||||
}
|
|
||||||
|
|
||||||
.nav-link[data-toggle]:not(.collapsed):after {
|
|
||||||
content: "▴";
|
|
||||||
}
|
|
||||||
|
|
||||||
.content {
|
.content {
|
||||||
padding-top: 1.1rem;
|
padding-top: 1.1rem;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user