Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

upgrade to Boostrap 5 #1529

Merged
merged 1 commit into from
Jul 2, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Oqtane.Client/Modules/Admin/Files/Add.razor
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
<Label For="folder" HelpText="Select the folder to save the file in" ResourceKey="Folder">Folder: </Label>
</td>
<td>
<select id="folder" class="form-control" @bind="@_folderId">
<select id="folder" class="form-select" @bind="@_folderId">
<option value="-1">&lt;@Localizer["Folder.Select"]&gt;</option>
@foreach (Folder folder in _folders)
{
Expand Down
4 changes: 2 additions & 2 deletions Oqtane.Client/Modules/Admin/Files/Details.razor
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
{
<table class="table table-borderless">
<tr>
<td>
<td width="30%">
<Label for="name" HelpText="The name of the file" ResourceKey="Name">Name: </Label>
</td>
<td>
Expand All @@ -22,7 +22,7 @@
<Label For="parent" HelpText="The folder where the file is located" ResourceKey="Folder">Folder: </Label>
</td>
<td>
<select id="parent" class="form-control" @bind="@_folderId">
<select id="parent" class="form-select" @bind="@_folderId">
@foreach (Folder folder in _folders)
{
<option value="@(folder.FolderId)">@(new string('-', folder.Level * 2))@(folder.Name)</option>
Expand Down
6 changes: 3 additions & 3 deletions Oqtane.Client/Modules/Admin/Files/Edit.razor
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@
{
<table class="table table-borderless">
<tr>
<td>
<td width="30%">
<Label For="parent" HelpText="Select the parent folder" ResourceKey="Parent">Parent: </Label>
</td>
<td>
<select id="parent" class="form-control" @bind="@_parentId">
<select id="parent" class="form-select" @bind="@_parentId">
@if (PageState.QueryString.ContainsKey("id"))
{
<option value="-1">&lt;@Localizer["NoParent"]&gt;</option>
Expand Down Expand Up @@ -45,7 +45,7 @@
}
else
{
<select id="type" class="form-control" @bind="@_type">
<select id="type" class="form-select" @bind="@_type">
<option value="@FolderTypes.Private">@Localizer[FolderTypes.Private]</option>
<option value="@FolderTypes.Public">@Localizer[FolderTypes.Public]</option>
</select>
Expand Down
2 changes: 1 addition & 1 deletion Oqtane.Client/Modules/Admin/Files/Index.razor
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
<label class="control-label">@Localizer["Folder"] </label>
</td>
<td>
<select class="form-control" @onchange="(e => FolderChanged(e))">
<select class="form-select" @onchange="(e => FolderChanged(e))">
@foreach (Folder folder in _folders)
{
<option value="@(folder.FolderId)">@(new string('-', folder.Level * 2))@(folder.Name)</option>
Expand Down
17 changes: 14 additions & 3 deletions Oqtane.Client/Modules/Admin/Jobs/Edit.razor
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

<table class="table table-borderless">
<tr>
<td>
<td width="30%">
<Label For="name" HelpText="Enter the job name" ResourceKey="Name">Name: </Label>
</td>
<td>
Expand All @@ -27,7 +27,7 @@
<Label For="enabled" HelpText="Select whether you want the job enabled or not" ResourceKey="Enabled">Enabled? </Label>
</td>
<td>
<select id="enabled" class="form-control" @bind="@_isEnabled">
<select id="enabled" class="form-select" @bind="@_isEnabled">
<option value="True">@SharedLocalizer["Yes"]</option>
<option value="False">@SharedLocalizer["No"]</option>
</select>
Expand All @@ -39,7 +39,7 @@
</td>
<td>
<input id="runs-every" class="form-control" @bind="@_interval" />
<select id="runs-every" class="form-control" @bind="@_frequency">
<select id="runs-every" class="form-select" @bind="@_frequency">
<option value="m">@Localizer["Minute(s)"]</option>
<option value="H">@Localizer["Hour(s)"]</option>
<option value="d">@Localizer["Day(s)"]</option>
Expand Down Expand Up @@ -82,6 +82,9 @@
</table>
<button type="button" class="btn btn-success" @onclick="SaveJob">@SharedLocalizer["Save"]</button>
<NavLink class="btn btn-secondary" href="@NavigateUrl()">@SharedLocalizer["Cancel"]</NavLink>
<br />
<br />
<AuditInfo CreatedBy="@createdby" CreatedOn="@createdon" ModifiedBy="@modifiedby" ModifiedOn="@modifiedon"></AuditInfo>

@code {
private int _jobId;
Expand All @@ -94,6 +97,10 @@
private string _endDate = string.Empty;
private string _retentionHistory = string.Empty;
private string _nextExecution = string.Empty;
private string createdby;
private DateTime createdon;
private string modifiedby;
private DateTime modifiedon;

public override SecurityAccessLevel SecurityAccessLevel => SecurityAccessLevel.Host;

Expand All @@ -114,6 +121,10 @@
_endDate = (job.EndDate != null) ? job.EndDate.ToString() : string.Empty;
_retentionHistory = job.RetentionHistory.ToString();
_nextExecution = job.NextExecution.ToString();
createdby = job.CreatedBy;
createdon = job.CreatedOn;
modifiedby = job.ModifiedBy;
modifiedon = job.ModifiedOn;
}
}
catch (Exception ex)
Expand Down
6 changes: 3 additions & 3 deletions Oqtane.Client/Modules/Admin/Languages/Add.razor
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,11 @@ else
{
<table class="table table-borderless">
<tr>
<td>
<td width="30%">
<Label For="name" HelpText="Name Of The Language" ResourceKey="Name">Name:</Label>
</td>
<td>
<select id="_code" class="form-control" @bind="@_code">
<select id="_code" class="form-select" @bind="@_code">
@foreach (var culture in _availableCultures)
{
<option value="@culture.Name">@culture.DisplayName</option>
Expand All @@ -42,7 +42,7 @@ else
<Label For="default" HelpText="Indicates Whether Or Not This Language Is The Default For The Site" ResourceKey="IsDefault">Default?</Label>
</td>
<td>
<select id="default" class="form-control" @bind="@_isDefault">
<select id="default" class="form-select" @bind="@_isDefault">
<option value="True">@SharedLocalizer["Yes"]</option>
<option value="False">@SharedLocalizer["No"]</option>
</select>
Expand Down
2 changes: 1 addition & 1 deletion Oqtane.Client/Modules/Admin/Logs/Detail.razor
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

<table class="table table-borderless">
<tr>
<td>
<td width="30%">
<Label For="dateTime" HelpText="The date and time of this log" ResourceKey="DateTime">Date/Time: </Label>
</td>
<td>
Expand Down
6 changes: 3 additions & 3 deletions Oqtane.Client/Modules/Admin/Logs/Index.razor
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ else
<tr>
<td>
<Label For="level" HelpText="Select the log level for event log items" ResourceKey="Level">Level: </Label><br /><br />
<select id="level" class="form-control" @onchange="(e => LevelChanged(e))">
<select id="level" class="form-select" @onchange="(e => LevelChanged(e))">
<option value="-">&lt;@Localizer["AllLevels"]&gt;</option>
<option value="Trace">@Localizer["Trace"]</option>
<option value="Debug">@Localizer["Debug"]</option>
Expand All @@ -26,7 +26,7 @@ else
</td>
<td>
<Label For="function" HelpText="Select the function for event log items" ResourceKey="Function">Function: </Label><br /><br />
<select id="function" class="form-control" @onchange="(e => FunctionChanged(e))">
<select id="function" class="form-select" @onchange="(e => FunctionChanged(e))">
<option value="-">&lt;@Localizer["AllFunctions"]&gt;</option>
<option value="Create">@Localizer["Create"]</option>
<option value="Read">@Localizer["Read"]</option>
Expand All @@ -38,7 +38,7 @@ else
</td>
<td>
<Label For="rows" HelpText="Select the maximum number of event log items to review. Please note that if you choose more than 10 items the information will be split into pages." ResourceKey="Rows">Maximum Items: </Label><br /><br />
<select id="rows" class="form-control" @onchange="(e => RowsChanged(e))">
<select id="rows" class="form-select" @onchange="(e => RowsChanged(e))">
<option value="10">10</option>
<option value="50">50</option>
<option value="100">100</option>
Expand Down
6 changes: 3 additions & 3 deletions Oqtane.Client/Modules/Admin/ModuleCreator/Index.razor
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
{
<table class="table table-borderless">
<tr>
<td>
<td width="30%">
<Label For="owner" HelpText="Enter the name of the organization who is developing this module. It should not contain spaces or punctuation." ResourceKey="OwnerName">Owner Name: </Label>
</td>
<td>
Expand Down Expand Up @@ -40,7 +40,7 @@
<Label For="template" HelpText="Select a module template. Templates are located in the wwwroot/Modules/Templates folder on the server." ResourceKey="Template">Template: </Label>
</td>
<td>
<select id="template" class="form-control" @onchange="(e => TemplateChanged(e))">
<select id="template" class="form-select" @onchange="(e => TemplateChanged(e))">
<option value="-">&lt;@Localizer["Template.Select"]&gt;</option>
@foreach (Template template in _templates)
{
Expand All @@ -54,7 +54,7 @@
<Label For="reference" HelpText="Select a framework reference version" ResourceKey="FrameworkReference">Framework Reference: </Label>
</td>
<td>
<select id="reference" class="form-control" @bind="@_reference">
<select id="reference" class="form-select" @bind="@_reference">
@foreach (string version in _versions)
{
if (Version.Parse(version).CompareTo(Version.Parse(_minversion)) >= 0)
Expand Down
2 changes: 1 addition & 1 deletion Oqtane.Client/Modules/Admin/ModuleDefinitions/Add.razor
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<TabPanel Name="Download" ResourceKey="Download">
<ModuleMessage Type="MessageType.Info" Message="Download one or more modules from the list below. Once you are ready click Install to complete the installation."></ModuleMessage>

<table class="table table-borderless" style=" margin: auto; width: 50% !important;">
<table class="table table-borderless" style="margin: auto; width: 50% !important;">
<tr>
<td>
<input id="search" class="form-control" placeholder="@SharedLocalizer["Search.Hint"]" @bind="@_search" />
Expand Down
6 changes: 3 additions & 3 deletions Oqtane.Client/Modules/Admin/ModuleDefinitions/Create.razor
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
{
<table class="table table-borderless">
<tr>
<td>
<td width="30%">
<Label For="owner" HelpText="Enter the name of the organization who is developing this module. It should not contain spaces or punctuation." ResourceKey="OwnerName">Owner Name: </Label>
</td>
<td>
Expand Down Expand Up @@ -40,7 +40,7 @@
<Label For="template" HelpText="Select a module template. Templates are located in the wwwroot/Modules/Templates folder on the server." ResourceKey="Template">Template: </Label>
</td>
<td>
<select id="template" class="form-control" @onchange="(e => TemplateChanged(e))">
<select id="template" class="form-select" @onchange="(e => TemplateChanged(e))">
<option value="-">&lt;@Localizer["Template.Select"]&gt;</option>
@foreach (Template template in _templates)
{
Expand All @@ -54,7 +54,7 @@
<Label For="reference" HelpText="Select a framework reference version" ResourceKey="FrameworkReference">Framework Reference: </Label>
</td>
<td>
<select id="reference" class="form-control" @bind="@_reference">
<select id="reference" class="form-select" @bind="@_reference">
@foreach (string version in _versions)
{
if (Version.Parse(version).CompareTo(Version.Parse(_minversion)) >= 0)
Expand Down
4 changes: 2 additions & 2 deletions Oqtane.Client/Modules/Admin/ModuleDefinitions/Edit.razor
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<TabPanel Name="Definition" ResourceKey="Definition">
<table class="table table-borderless">
<tr>
<td>
<td width="30%">
<Label For="name" HelpText="The name of the module" ResourceKey="Name">Name: </Label>
</td>
<td>
Expand All @@ -36,7 +36,7 @@
<Section Name="Information" ResourceKey="Information">
<table class="table table-borderless">
<tr>
<td>
<td width="30%">
<Label For="moduledefinitionname" HelpText="The internal name of the module" ResourceKey="InternalName">Internal Name: </Label>
</td>
<td>
Expand Down
2 changes: 1 addition & 1 deletion Oqtane.Client/Modules/Admin/Modules/Export.razor
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<table class="table table-borderless">
<tbody>
<tr>
<td>
<td width="30%">
<Label For="content" HelpText="Enter the module content" ResourceKey="Content">Content: </Label>
</td>
<td>
Expand Down
2 changes: 1 addition & 1 deletion Oqtane.Client/Modules/Admin/Modules/Import.razor
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<table class="table table-borderless">
<tbody>
<tr>
<td>
<td width="30%">
<Label For="content" HelpText="Enter the module content" ResourceKey="Content">Content: </Label>
</td>
<td>
Expand Down
19 changes: 15 additions & 4 deletions Oqtane.Client/Modules/Admin/Modules/Settings.razor
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
{
<table class="table table-borderless">
<tr>
<td>
<td width="30%">
<Label For="title" HelpText="Enter the title of the module" ResourceKey="Title">Title: </Label>
</td>
<td>
Expand All @@ -26,7 +26,7 @@
<Label For="container" HelpText="Select the module's container" ResourceKey="Container">Container: </Label>
</td>
<td>
<select id="container" class="form-control" @bind="@_containerType">
<select id="container" class="form-select" @bind="@_containerType">
@foreach (var container in _containers)
{
<option value="@container.TypeName">@container.Name</option>
Expand All @@ -39,7 +39,7 @@
<Label For="allpages" HelpText="Indicate if this module should be displayed on all pages" ResourceKey="DisplayOnAllPages">Display On All Pages? </Label>
</td>
<td>
<select id="allpages" class="form-control" @bind="@_allPages">
<select id="allpages" class="form-select" @bind="@_allPages">
<option value="True">@SharedLocalizer["Yes"]</option>
<option value="False">@SharedLocalizer["No"]</option>
</select>
Expand All @@ -50,7 +50,7 @@
<Label For="page" HelpText="The page that the module is located on" ResourceKey="Page">Page: </Label>
</td>
<td>
<select id="page" class="form-control" @bind="@_pageId">
<select id="page" class="form-select" @bind="@_pageId">
@foreach (Page p in PageState.Pages)
{
if (UserSecurity.IsAuthorized(PageState.User, PermissionNames.View, p.Permissions))
Expand Down Expand Up @@ -91,6 +91,9 @@
</TabStrip>
<button type="button" class="btn btn-success" @onclick="SaveModule">@SharedLocalizer["Save"]</button>
<NavLink class="btn btn-secondary" href="@NavigateUrl()">@SharedLocalizer["Cancel"]</NavLink>
<br />
<br />
<AuditInfo CreatedBy="@createdby" CreatedOn="@createdon" ModifiedBy="@modifiedby" ModifiedOn="@modifiedon"></AuditInfo>

@code {
public override SecurityAccessLevel SecurityAccessLevel => SecurityAccessLevel.Edit;
Expand All @@ -112,6 +115,10 @@
private Type _containerSettingsType;
private object _containerSettings;
private RenderFragment ContainerSettingsComponent { get; set; }
private string createdby;
private DateTime createdon;
private string modifiedby;
private DateTime modifiedon;

protected override async Task OnInitializedAsync()
{
Expand All @@ -123,6 +130,10 @@
_permissions = ModuleState.Permissions;
_permissionNames = ModuleState.ModuleDefinition.PermissionNames;
_pageId = ModuleState.PageId.ToString();
createdby = ModuleState.CreatedBy;
createdon = ModuleState.CreatedOn;
modifiedby = ModuleState.ModifiedBy;
modifiedon = ModuleState.ModifiedOn;

if (!string.IsNullOrEmpty(ModuleState.ModuleDefinition.SettingsType))
{
Expand Down
Loading