Module ordering improvements

This commit is contained in:
Shaun Walker 2019-09-10 09:56:42 -04:00
parent f60898dbc7
commit 2a691dbceb
12 changed files with 229 additions and 152 deletions

View File

@ -1,5 +1,6 @@
@using Microsoft.AspNetCore.Components.Routing
@using Oqtane.Modules
@using Oqtane.Client.Modules.Controls
@using Oqtane.Client.Modules.HtmlText.Services
@using Oqtane.Shared.Modules.HtmlText.Models
@using System.Net.Http;
@ -9,54 +10,79 @@
@inject HttpClient http
@inject SiteState sitestate
<form>
<table class="form-group">
<tr>
<td>
<label for="Name" class="control-label">Content: </label>
</td>
<td>
<textarea class="form-control" @bind="@content" rows="5" style="width:400px;" />
</td>
</tr>
</table>
<button type="button" class="btn btn-success" @onclick="@SaveContent">Save</button>
<NavLink class="btn btn-secondary" href="@NavigateUrl()">Cancel</NavLink>
</form>
<ModuleMessage Message="@message" />
<table class="form-group">
<tr>
<td>
<label for="Name" class="control-label">Content: </label>
</td>
<td>
<textarea class="form-control" @bind="@content" rows="5" style="width:400px;" />
</td>
</tr>
</table>
<button type="button" class="btn btn-success" @onclick="@SaveContent">Save</button>
<NavLink class="btn btn-secondary" href="@NavigateUrl()">Cancel</NavLink>
<br /><br />
<AuditInfo CreatedBy="@createdby" CreatedOn="@createdon" ModifiedBy="@modifiedby" ModifiedOn="@modifiedon"></AuditInfo>
@code {
public override SecurityAccessLevel SecurityAccessLevel { get { return SecurityAccessLevel.Edit; } }
public override string Title { get { return "Edit Html/Text"; } }
string message = "";
string content;
string createdby;
DateTime createdon;
string modifiedby;
DateTime modifiedon;
protected override async Task OnInitializedAsync()
{
HtmlTextService htmltextservice = new HtmlTextService(http, sitestate, UriHelper);
HtmlTextInfo htmltext = await htmltextservice.GetHtmlTextAsync(ModuleState.ModuleId);
if (htmltext != null)
try
{
content = htmltext.Content;
HtmlTextService htmltextservice = new HtmlTextService(http, sitestate, UriHelper);
HtmlTextInfo htmltext = await htmltextservice.GetHtmlTextAsync(ModuleState.ModuleId);
if (htmltext != null)
{
content = htmltext.Content;
createdby = htmltext.CreatedBy;
createdon = htmltext.CreatedOn;
modifiedby = htmltext.ModifiedBy;
modifiedon = htmltext.ModifiedOn;
}
}
catch (Exception ex)
{
message = ex.Message;
}
}
private async Task SaveContent()
{
HtmlTextService htmltextservice = new HtmlTextService(http, sitestate, UriHelper);
HtmlTextInfo htmltext = await htmltextservice.GetHtmlTextAsync(ModuleState.ModuleId);
if (htmltext != null)
try
{
htmltext.Content = content;
await htmltextservice.UpdateHtmlTextAsync(htmltext);
HtmlTextService htmltextservice = new HtmlTextService(http, sitestate, UriHelper);
HtmlTextInfo htmltext = await htmltextservice.GetHtmlTextAsync(ModuleState.ModuleId);
if (htmltext != null)
{
htmltext.Content = content;
await htmltextservice.UpdateHtmlTextAsync(htmltext);
}
else
{
htmltext = new HtmlTextInfo();
htmltext.ModuleId = ModuleState.ModuleId;
htmltext.Content = content;
await htmltextservice.AddHtmlTextAsync(htmltext);
}
PageState.Reload = Constants.ReloadPage;
UriHelper.NavigateTo(NavigateUrl());
}
else
catch (Exception ex)
{
htmltext = new HtmlTextInfo();
htmltext.ModuleId = ModuleState.ModuleId;
htmltext.Content = content;
await htmltextservice.AddHtmlTextAsync(htmltext);
message = ex.Message;
}
PageState.Reload = Constants.ReloadPage;
UriHelper.NavigateTo(NavigateUrl());
}
}

View File

@ -9,20 +9,30 @@
@inject HttpClient http
@inject SiteState sitestate
<ModuleMessage Message="@message" />
@((MarkupString)content)
<br /><ActionLink Action="Edit" /><br /><br />
@code {
string message = "";
string content;
protected override async Task OnParametersSetAsync()
{
HtmlTextService htmltextservice = new HtmlTextService(http, sitestate, UriHelper);
HtmlTextInfo htmltext = await htmltextservice.GetHtmlTextAsync(ModuleState.ModuleId);
if (htmltext != null)
try
{
content = htmltext.Content;
HtmlTextService htmltextservice = new HtmlTextService(http, sitestate, UriHelper);
HtmlTextInfo htmltext = await htmltextservice.GetHtmlTextAsync(ModuleState.ModuleId);
if (htmltext != null)
{
content = htmltext.Content;
}
}
catch (Exception ex)
{
message = ex.Message;
}
}
}

View File

@ -10,6 +10,7 @@ namespace Oqtane.Services
Task<PageModule> GetPageModuleAsync(int PageModuleId);
Task<PageModule> AddPageModuleAsync(PageModule PageModule);
Task<PageModule> UpdatePageModuleAsync(PageModule PageModule);
Task UpdatePageModuleOrderAsync(int PageId, string Pane);
Task DeletePageModuleAsync(int PageModuleId);
}
}

View File

@ -46,6 +46,11 @@ namespace Oqtane.Services
return await http.PutJsonAsync<PageModule>(apiurl + "/" + PageModule.PageModuleId.ToString(), PageModule);
}
public async Task UpdatePageModuleOrderAsync(int PageId, string Pane)
{
await http.PutJsonAsync(apiurl + "/?pageid=" + PageId.ToString() + "&pane=" + Pane, null);
}
public async Task DeletePageModuleAsync(int PageModuleId)
{
await http.DeleteAsync(apiurl + "/" + PageModuleId.ToString());

View File

@ -13,45 +13,34 @@
[Parameter]
public Module Module { get; set; }
Module ModuleState;
string container;
RenderFragment DynamicComponent { get; set; }
Module ModuleState;
protected override void OnParametersSet()
{
ModuleState = Module; // passed in from Pane component
string container = ModuleState.ContainerType;
if (PageState.ModuleId != -1 && PageState.Control != "" && ModuleState.UseAdminContainer)
{
container = Constants.DefaultAdminContainer;
}
DynamicComponent = builder =>
{
if (ModuleState != null)
Type containerType = Type.GetType(container);
if (containerType != null)
{
Type containerType = Type.GetType(container);
if (containerType != null)
{
builder.OpenComponent(0, containerType);
builder.CloseComponent();
}
else
{
// container does not exist with type specified
builder.OpenComponent(0, Type.GetType(Constants.ModuleMessageControl));
builder.AddAttribute(1, "Message", "Error Loading Module Container " + container);
builder.CloseComponent();
}
builder.OpenComponent(0, containerType);
builder.CloseComponent();
}
else
{
// container does not exist with type specified
builder.OpenComponent(0, Type.GetType(Constants.ModuleMessageControl));
builder.AddAttribute(1, "Message", "Error Loading Module Container " + container);
builder.CloseComponent();
}
};
}
protected override Task OnParametersSetAsync()
{
if (PageState.Page.PageId == Module.PageId)
{
ModuleState = Module; // passed in from Pane component
container = ModuleState.ContainerType;
if (PageState.ModuleId != -1 && PageState.Control != "" && ModuleState.UseAdminContainer)
{
container = Constants.DefaultAdminContainer;
}
}
return Task.CompletedTask;
}
}

View File

@ -1,5 +1,6 @@
@using Oqtane.Services
@using Oqtane.Models
@using Oqtane.Shared
@inject IUriHelper UriHelper
@inject IInstallationService InstallationService
@inject IUserService UserService
@ -167,8 +168,8 @@
user.Username = Email;
user.DisplayName = Email;
user.Email = Email;
user.Password = HostPassword;
user.IsHost = true;
user.Password = HostPassword;
user = await UserService.AddUserAsync(user);
UriHelper.NavigateTo("", true);

View File

@ -9,13 +9,13 @@
@inject IModuleService ModuleService
@inject IModuleDefinitionService ModuleDefinitionService
<div class="@paneadminborder">
@if (panetitle != "")
{
@((MarkupString)panetitle)
}
@DynamicComponent
</div>
<div class="@paneadminborder">
@if (panetitle != "")
{
@((MarkupString)panetitle)
}
@DynamicComponent
</div>
@code {
[CascadingParameter]
@ -129,6 +129,7 @@
{
builder.OpenComponent(0, Type.GetType(Constants.DefaultContainer));
builder.AddAttribute(1, "Module", module);
builder.SetKey(module.PageModuleId);
builder.CloseComponent();
}
}

View File

@ -31,11 +31,19 @@
actions = new List<ActionViewModel>();
if (ModuleState.PaneModuleIndex > 0)
{
actions.Add(new ActionViewModel { Action = "up", Name = "Move Up" });
actions.Add(new ActionViewModel { Action = "<<", Name = "Move To Top" });
}
if (ModuleState.PaneModuleIndex > 0)
{
actions.Add(new ActionViewModel { Action = "<", Name = "Move Up" });
}
if (ModuleState.PaneModuleIndex < (ModuleState.PaneModuleCount - 1))
{
actions.Add(new ActionViewModel { Action = "down", Name = "Move Down" });
actions.Add(new ActionViewModel { Action = ">", Name = "Move Down" });
}
if (ModuleState.PaneModuleIndex < (ModuleState.PaneModuleCount - 1))
{
actions.Add(new ActionViewModel { Action = ">>", Name = "Move To Bottom" });
}
foreach (string pane in PageState.Page.Panes.Split(new[] { ';' }, StringSplitOptions.RemoveEmptyEntries))
{
@ -58,23 +66,40 @@
string url = NavigateUrl();
switch (action)
{
case "up":
pagemodule.Order += -1;
case "<<":
pagemodule.Order = 0;
await PageModuleService.UpdatePageModuleAsync(pagemodule);
await PageModuleService.UpdatePageModuleOrderAsync(pagemodule.PageId, pagemodule.Pane);
break;
case "down":
pagemodule.Order += 1;
case "<":
pagemodule.Order -= 3;
await PageModuleService.UpdatePageModuleAsync(pagemodule);
await PageModuleService.UpdatePageModuleOrderAsync(pagemodule.PageId, pagemodule.Pane);
break;
case ">":
pagemodule.Order += 3;
await PageModuleService.UpdatePageModuleAsync(pagemodule);
await PageModuleService.UpdatePageModuleOrderAsync(pagemodule.PageId, pagemodule.Pane);
break;
case ">>":
pagemodule.Order = ModuleState.PaneModuleCount * 2;
await PageModuleService.UpdatePageModuleAsync(pagemodule);
await PageModuleService.UpdatePageModuleOrderAsync(pagemodule.PageId, pagemodule.Pane);
break;
case "settings":
url = EditUrl(pagemodule.ModuleId, "Settings");
break;
case "delete":
await PageModuleService.DeletePageModuleAsync(pagemodule.PageModuleId);
await PageModuleService.UpdatePageModuleOrderAsync(pagemodule.PageId, pagemodule.Pane);
break;
default: // move to pane
string pane = pagemodule.Pane;
pagemodule.Pane = action;
pagemodule.Order = int.MaxValue; // add to bottom of pane
await PageModuleService.UpdatePageModuleAsync(pagemodule);
await PageModuleService.UpdatePageModuleOrderAsync(pagemodule.PageId, pagemodule.Pane);
await PageModuleService.UpdatePageModuleOrderAsync(pagemodule.PageId, pane);
break;
}
PageState.Reload = Constants.ReloadPage;

View File

@ -4,6 +4,7 @@ using Microsoft.AspNetCore.Authorization;
using Oqtane.Repository;
using Oqtane.Models;
using Oqtane.Shared;
using System.Linq;
namespace Oqtane.Controllers
{
@ -11,10 +12,12 @@ namespace Oqtane.Controllers
public class PageModuleController : Controller
{
private readonly IPageModuleRepository PageModules;
private readonly IModuleRepository Modules;
public PageModuleController(IPageModuleRepository PageModules)
public PageModuleController(IPageModuleRepository PageModules, IModuleRepository Modules)
{
this.PageModules = PageModules;
this.Modules = Modules;
}
// GET: api/<controller>
@ -55,6 +58,24 @@ namespace Oqtane.Controllers
return PageModule;
}
// PUT api/<controller>/?pageid=x&pane=y
[HttpPut]
[Authorize(Roles = Constants.AdminRole)]
public void Put(int pageid, string pane)
{
int order = 1;
List<PageModule> pagemodules = PageModules.GetPageModules(pageid).ToList();
foreach (PageModule pagemodule in pagemodules.Where(item => item.Pane == pane).OrderBy(item => item.Order))
{
if (pagemodule.Order != order)
{
pagemodule.Order = order;
PageModules.UpdatePageModule(pagemodule);
}
order += 2;
}
}
// DELETE api/<controller>/5
[HttpDelete("{id}")]
[Authorize(Roles = Constants.AdminRole)]

View File

@ -107,66 +107,64 @@ namespace Oqtane.Controllers
if (ModelState.IsValid)
{
bool authorized = HttpContext.User.IsInRole(Constants.AdminRole);
if (!authorized && !Users.GetUsers().Any())
bool installed = true;
if (!Users.GetUsers().Any())
{
authorized = true; // during initial installation we need to be able to create the host user
installed = false; // during initial installation we need to be able to create the host user
}
if (authorized)
{
IdentityUser identityuser = await IdentityUserManager.FindByNameAsync(User.Username);
if (identityuser == null)
{
identityuser = new IdentityUser();
identityuser.UserName = User.Username;
identityuser.Email = User.Username;
var result = await IdentityUserManager.CreateAsync(identityuser, User.Password);
if (result.Succeeded)
{
user = Users.AddUser(User);
if (!user.IsHost) // host users are part of every site by default
{
SiteUser siteuser = new SiteUser();
siteuser.SiteId = User.SiteId;
siteuser.UserId = user.UserId;
SiteUsers.AddSiteUser(siteuser);
List<Role> roles = Roles.GetRoles(user.SiteId).Where(item => item.IsAutoAssigned == true).ToList();
foreach (Role role in roles)
{
UserRole userrole = new UserRole();
userrole.UserId = user.UserId;
userrole.RoleId = role.RoleId;
userrole.EffectiveDate = null;
userrole.ExpiryDate = null;
UserRoles.AddUserRole(userrole);
}
IdentityUser identityuser = await IdentityUserManager.FindByNameAsync(User.Username);
if (identityuser == null)
{
identityuser = new IdentityUser();
identityuser.UserName = User.Username;
identityuser.Email = User.Username;
var result = await IdentityUserManager.CreateAsync(identityuser, User.Password);
if (result.Succeeded)
{
user = Users.AddUser(User);
if (!user.IsHost) // host users are part of every site by default
{
SiteUser siteuser = new SiteUser();
siteuser.SiteId = User.SiteId;
siteuser.UserId = user.UserId;
SiteUsers.AddSiteUser(siteuser);
List<Role> roles = Roles.GetRoles(user.SiteId).Where(item => item.IsAutoAssigned == true).ToList();
foreach (Role role in roles)
{
UserRole userrole = new UserRole();
userrole.UserId = user.UserId;
userrole.RoleId = role.RoleId;
userrole.EffectiveDate = null;
userrole.ExpiryDate = null;
UserRoles.AddUserRole(userrole);
}
}
}
else
}
else
{
user = Users.GetUser(User.Username);
SiteUser siteuser = SiteUsers.GetSiteUser(User.SiteId, user.UserId);
if (siteuser == null)
{
user = Users.GetUser(User.Username);
SiteUser siteuser = SiteUsers.GetSiteUser(User.SiteId, user.UserId);
if (siteuser == null)
if (!user.IsHost) // host users are part of every site by default
{
if (!user.IsHost) // host users are part of every site by default
{
siteuser = new SiteUser();
siteuser.SiteId = User.SiteId;
siteuser.UserId = user.UserId;
SiteUsers.AddSiteUser(siteuser);
siteuser = new SiteUser();
siteuser.SiteId = User.SiteId;
siteuser.UserId = user.UserId;
SiteUsers.AddSiteUser(siteuser);
List<Role> roles = Roles.GetRoles(User.SiteId).Where(item => item.IsAutoAssigned == true).ToList();
foreach (Role role in roles)
{
UserRole userrole = new UserRole();
userrole.UserId = user.UserId;
userrole.RoleId = role.RoleId;
userrole.EffectiveDate = null;
userrole.ExpiryDate = null;
UserRoles.AddUserRole(userrole);
}
List<Role> roles = Roles.GetRoles(User.SiteId).Where(item => item.IsAutoAssigned == true).ToList();
foreach (Role role in roles)
{
UserRole userrole = new UserRole();
userrole.UserId = user.UserId;
userrole.RoleId = role.RoleId;
userrole.EffectiveDate = null;
userrole.ExpiryDate = null;
UserRoles.AddUserRole(userrole);
}
}
}
@ -178,7 +176,7 @@ namespace Oqtane.Controllers
// PUT api/<controller>/5
[HttpPut("{id}")]
[Authorize(Roles = Constants.AdminRole)]
[Authorize]
public User Put(int id, [FromBody] User User)
{
if (ModelState.IsValid)

View File

@ -364,7 +364,7 @@ INSERT [dbo].[Role] ([RoleId], [SiteId], [Name], [Description], [IsAutoAssigned]
VALUES (-1, null, N'All Users', N'All Users', 0, '', getdate(), '', getdate())
GO
INSERT [dbo].[Role] ([RoleId], [SiteId], [Name], [Description], [IsAutoAssigned], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (0, null, N'Super Users', N'Super Users', 0, '', getdate(), '', getdate())
VALUES (0, null, N'Host Users', N'Host Users', 0, '', getdate(), '', getdate())
GO
INSERT [dbo].[Role] ([RoleId], [SiteId], [Name], [Description], [IsAutoAssigned], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (1, 1, N'Administrators', N'Site Administrators', 0, '', getdate(), '', getdate())
@ -733,49 +733,49 @@ GO
SET IDENTITY_INSERT [dbo].[PageModule] ON
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (1, 1, 1, N'Weather', N'Right', 0, N'Oqtane.Client.Themes.Theme1.Container1, Oqtane.Client', '', getdate(), '', getdate())
VALUES (1, 1, 1, N'Weather', N'Right', 1, N'Oqtane.Client.Themes.Theme1.Container1, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (2, 1, 2, N'Counter', N'Left', 1, N'Oqtane.Client.Themes.Theme1.Container1, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (3, 1, 3, N'Lorem ipsum', N'Left', 0, N'Oqtane.Client.Themes.Theme1.Container1, Oqtane.Client', '', getdate(), '', getdate())
VALUES (3, 1, 3, N'Lorem ipsum', N'Left', 3, N'Oqtane.Client.Themes.Theme1.Container1, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (4, 2, 4, N'Weather', N'Top', 0, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
VALUES (4, 2, 4, N'Weather', N'Top', 1, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (5, 2, 5, N'Enim sed', N'Top', 1, N'Oqtane.Client.Themes.Theme1.Container1, Oqtane.Client', '', getdate(), '', getdate())
VALUES (5, 2, 5, N'Enim sed', N'Top', 3, N'Oqtane.Client.Themes.Theme1.Container1, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (6, 3, 6, N'Id consectetur', N'Left', 0, N'Oqtane.Client.Themes.Theme1.Container1, Oqtane.Client', '', getdate(), '', getdate())
VALUES (6, 3, 6, N'Id consectetur', N'Left', 1, N'Oqtane.Client.Themes.Theme1.Container1, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (7, 3, 7, N'Ornare arcu', N'Right', 0, N'Oqtane.Client.Themes.Theme1.Container1, Oqtane.Client', '', getdate(), '', getdate())
VALUES (7, 3, 7, N'Ornare arcu', N'Right', 1, N'Oqtane.Client.Themes.Theme1.Container1, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (8, 5, 8, N'Page Management', N'Top', 0, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
VALUES (8, 5, 8, N'Page Management', N'Top', 1, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (9, 6, 9, N'Login', N'Top', 0, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
VALUES (9, 6, 9, N'Login', N'Top', 1, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (10, 7, 10, N'Register', N'Top', 0, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
VALUES (10, 7, 10, N'Register', N'Top', 1, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (11, 4, 11, N'Administration', N'Top', 0, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
VALUES (11, 4, 11, N'Administration', N'Top', 1, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (12, 8, 12, N'Site Management', N'Top', 0, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
VALUES (12, 8, 12, N'Site Management', N'Top', 1, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (13, 9, 13, N'User Management', N'Top', 0, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
VALUES (13, 9, 13, N'User Management', N'Top', 1, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (14, 10, 14, N'Module Management', N'Top', 0, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
VALUES (14, 10, 14, N'Module Management', N'Top', 1, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (15, 11, 15, N'Theme Management', N'Top', 0, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
VALUES (15, 11, 15, N'Theme Management', N'Top', 1, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (16, 12, 16, N'Id consectetur', N'Top', 1, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
@ -784,16 +784,16 @@ INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane]
VALUES (17, 13, 17, N'Lorem ipsum', N'Top', 1, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (18, 14, 18, N'Login', N'Top', 0, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
VALUES (18, 14, 18, N'Login', N'Top', 1, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (19, 15, 19, N'Register', N'Top', 0, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
VALUES (19, 15, 19, N'Register', N'Top', 1, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (20, 16, 20, N'Role Management', N'Top', 0, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
VALUES (20, 16, 20, N'Role Management', N'Top', 1, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
GO
INSERT [dbo].[PageModule] ([PageModuleId], [PageId], [ModuleId], [Title], [Pane], [Order], [ContainerType], [CreatedBy], [CreatedOn], [ModifiedBy], [ModifiedOn])
VALUES (21, 17, 21, N'User Profile', N'Top', 0, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
VALUES (21, 17, 21, N'User Profile', N'Top', 1, N'Oqtane.Client.Themes.Theme2.Container2, Oqtane.Client', '', getdate(), '', getdate())
GO
SET IDENTITY_INSERT [dbo].[PageModule] OFF
GO

View File

@ -13,8 +13,8 @@
public const string AdminPane = "Admin";
public const string AllUsersRole = "All Users";
public const string HostRole = "Host Users";
public const string AdminRole = "Administrators";
public const string HostRole = "Hosts";
public const int ReloadApplication = 3;
public const int ReloadSite = 2;