Localize non components for the modules pages

This commit is contained in:
hishamco
2020-11-20 01:45:09 +03:00
parent 867c8f84ad
commit d108cc3990
3 changed files with 12 additions and 9 deletions

View File

@ -2,6 +2,7 @@
@inherits ModuleBase @inherits ModuleBase
@inject NavigationManager NavigationManager @inject NavigationManager NavigationManager
@inject IModuleService ModuleService @inject IModuleService ModuleService
@inject IStringLocalizer<Export> Localizer
<table class="table table-borderless"> <table class="table table-borderless">
<tbody> <tbody>
@ -15,8 +16,8 @@
</tr> </tr>
</tbody> </tbody>
</table> </table>
<button type="button" class="btn btn-success" @onclick="ExportModule">Export</button> <button type="button" class="btn btn-success" @onclick="ExportModule">@Localizer["Export"]</button>
<NavLink class="btn btn-secondary" href="@NavigateUrl()">Cancel</NavLink> <NavLink class="btn btn-secondary" href="@NavigateUrl()">@Localizer["Cancel"]</NavLink>
@code { @code {

View File

@ -2,6 +2,7 @@
@inherits ModuleBase @inherits ModuleBase
@inject NavigationManager NavigationManager @inject NavigationManager NavigationManager
@inject IModuleService ModuleService @inject IModuleService ModuleService
@inject IStringLocalizer<Import> Localizer
<table class="table table-borderless"> <table class="table table-borderless">
<tbody> <tbody>
@ -15,8 +16,8 @@
</tr> </tr>
</tbody> </tbody>
</table> </table>
<button type="button" class="btn btn-success" @onclick="ImportModule">Import</button> <button type="button" class="btn btn-success" @onclick="ImportModule">@Localizer["Import"]</button>
<NavLink class="btn btn-secondary" href="@NavigateUrl()">Cancel</NavLink> <NavLink class="btn btn-secondary" href="@NavigateUrl()">@Localizer["Cancel"]</NavLink>
@code { @code {

View File

@ -4,6 +4,7 @@
@inject IThemeService ThemeService @inject IThemeService ThemeService
@inject IModuleService ModuleService @inject IModuleService ModuleService
@inject IPageModuleService PageModuleService @inject IPageModuleService PageModuleService
@inject IStringLocalizer<Settings> Localizer
<TabStrip> <TabStrip>
<TabPanel Name="Settings" Heading="Module Settings" ResourceKey="ModuleSettings"> <TabPanel Name="Settings" Heading="Module Settings" ResourceKey="ModuleSettings">
@ -24,7 +25,7 @@
</td> </td>
<td> <td>
<select id="container" class="form-control" @bind="@_containerType"> <select id="container" class="form-control" @bind="@_containerType">
<option value="-">&lt;Inherit From Page Or Site&gt;</option> <option value="-">&lt;@Localizer["Inherit From Page Or Site"]&gt;</option>
@foreach (var container in _containers) @foreach (var container in _containers)
{ {
<option value="@container.TypeName">@container.Name</option> <option value="@container.TypeName">@container.Name</option>
@ -38,8 +39,8 @@
</td> </td>
<td> <td>
<select id="allpages" class="form-control" @bind="@_allPages"> <select id="allpages" class="form-control" @bind="@_allPages">
<option value="True">Yes</option> <option value="True">@Localizer["Yes"]</option>
<option value="False">No</option> <option value="False">@Localizer["No"]</option>
</select> </select>
</td> </td>
</tr> </tr>
@ -81,8 +82,8 @@
</TabPanel> </TabPanel>
} }
</TabStrip> </TabStrip>
<button type="button" class="btn btn-success" @onclick="SaveModule">Save</button> <button type="button" class="btn btn-success" @onclick="SaveModule">@Localizer["Save"]</button>
<NavLink class="btn btn-secondary" href="@NavigateUrl()">Cancel</NavLink> <NavLink class="btn btn-secondary" href="@NavigateUrl()">@Localizer["Cancel"]</NavLink>
@code { @code {
private List<ThemeControl> _containers = new List<ThemeControl>(); private List<ThemeControl> _containers = new List<ThemeControl>();