Localize non components for the pages
This commit is contained in:
parent
917caab7a1
commit
9a3fd94c11
|
@ -3,6 +3,7 @@
|
||||||
@inject NavigationManager NavigationManager
|
@inject NavigationManager NavigationManager
|
||||||
@inject IPageService PageService
|
@inject IPageService PageService
|
||||||
@inject IThemeService ThemeService
|
@inject IThemeService ThemeService
|
||||||
|
@inject IStringLocalizer<Add> Localizer
|
||||||
|
|
||||||
<TabStrip>
|
<TabStrip>
|
||||||
<TabPanel Name="Settings" ResourceKey="Settings">
|
<TabPanel Name="Settings" ResourceKey="Settings">
|
||||||
|
@ -23,7 +24,7 @@
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<select id="Parent" class="form-control" @onchange="(e => ParentChanged(e))">
|
<select id="Parent" class="form-control" @onchange="(e => ParentChanged(e))">
|
||||||
<option value="-1"><Site Root></option>
|
<option value="-1"><@Localizer["Site Root"]></option>
|
||||||
@foreach (Page page in _pageList)
|
@foreach (Page page in _pageList)
|
||||||
{
|
{
|
||||||
<option value="@(page.PageId)">@(new string('-', page.Level * 2))@(page.Name)</option>
|
<option value="@(page.PageId)">@(new string('-', page.Level * 2))@(page.Name)</option>
|
||||||
|
@ -37,18 +38,18 @@
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<select id="Insert" class="form-control" @bind="@_insert">
|
<select id="Insert" class="form-control" @bind="@_insert">
|
||||||
<option value="<<">At Beginning</option>
|
<option value="<<">@Localizer["At Beginning"]</option>
|
||||||
@if (_children != null && _children.Count > 0)
|
@if (_children != null && _children.Count > 0)
|
||||||
{
|
{
|
||||||
<option value="<">Before</option>
|
<option value="<">@Localizer["Before"]</option>
|
||||||
<option value=">">After</option>
|
<option value=">">@Localizer["After"]</option>
|
||||||
}
|
}
|
||||||
<option value=">>">At End</option>
|
<option value=">>">@Localizer["At End"]</option>
|
||||||
</select>
|
</select>
|
||||||
@if (_children != null && _children.Count > 0 && (_insert == "<" || _insert == ">"))
|
@if (_children != null && _children.Count > 0 && (_insert == "<" || _insert == ">"))
|
||||||
{
|
{
|
||||||
<select class="form-control" @bind="@_childid">
|
<select class="form-control" @bind="@_childid">
|
||||||
<option value="-1"><Select Page></option>
|
<option value="-1"><@Localizer["Select Page"]></option>
|
||||||
@foreach (Page page in _children)
|
@foreach (Page page in _children)
|
||||||
{
|
{
|
||||||
<option value="@(page.PageId)">@(page.Name)</option>
|
<option value="@(page.PageId)">@(page.Name)</option>
|
||||||
|
@ -63,8 +64,8 @@
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<select id="Navigation" class="form-control" @bind="@_isnavigation">
|
<select id="Navigation" class="form-control" @bind="@_isnavigation">
|
||||||
<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>
|
||||||
|
@ -101,7 +102,7 @@
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<select id="Theme" class="form-control" @onchange="(e => ThemeChanged(e))">
|
<select id="Theme" class="form-control" @onchange="(e => ThemeChanged(e))">
|
||||||
<option value="-"><Inherit From Site></option>
|
<option value="-"><@Localizer["Inherit From Site"]></option>
|
||||||
@foreach (var theme in _themes)
|
@foreach (var theme in _themes)
|
||||||
{
|
{
|
||||||
if (theme.TypeName == _themetype)
|
if (theme.TypeName == _themetype)
|
||||||
|
@ -124,7 +125,7 @@
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<select id="Layout" class="form-control" @bind="@_layouttype">
|
<select id="Layout" class="form-control" @bind="@_layouttype">
|
||||||
<option value="-"><Inherit From Site></option>
|
<option value="-"><@Localizer["Inherit From Site"]></option>
|
||||||
@foreach (var layout in _layouts)
|
@foreach (var layout in _layouts)
|
||||||
{
|
{
|
||||||
if (layout.TypeName == _layouttype)
|
if (layout.TypeName == _layouttype)
|
||||||
|
@ -146,7 +147,7 @@
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<select id="defaultContainer" class="form-control" @bind="@_containertype">
|
<select id="defaultContainer" class="form-control" @bind="@_containertype">
|
||||||
<option value="-"><Inherit From Site></option>
|
<option value="-"><@Localizer["Inherit From Site"]></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>
|
||||||
|
@ -168,8 +169,8 @@
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<select id="Personalizable" class="form-control" @bind="@_ispersonalizable">
|
<select id="Personalizable" class="form-control" @bind="@_ispersonalizable">
|
||||||
<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>
|
||||||
|
@ -187,8 +188,8 @@
|
||||||
</table>
|
</table>
|
||||||
</TabPanel>
|
</TabPanel>
|
||||||
</TabStrip>
|
</TabStrip>
|
||||||
<button type="button" class="btn btn-success" @onclick="SavePage">Save</button>
|
<button type="button" class="btn btn-success" @onclick="SavePage">@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<Theme> _themeList;
|
private List<Theme> _themeList;
|
||||||
|
|
|
@ -3,6 +3,7 @@
|
||||||
@inject NavigationManager NavigationManager
|
@inject NavigationManager NavigationManager
|
||||||
@inject IPageService PageService
|
@inject IPageService PageService
|
||||||
@inject IThemeService ThemeService
|
@inject IThemeService ThemeService
|
||||||
|
@inject IStringLocalizer<Edit> Localizer
|
||||||
|
|
||||||
<TabStrip>
|
<TabStrip>
|
||||||
<TabPanel Name="Settings" ResourceKey="Settings">
|
<TabPanel Name="Settings" ResourceKey="Settings">
|
||||||
|
@ -23,7 +24,7 @@
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<select id="Parent" class="form-control" @onchange="(e => ParentChanged(e))">
|
<select id="Parent" class="form-control" @onchange="(e => ParentChanged(e))">
|
||||||
<option value="-1"><Site Root></option>
|
<option value="-1"><@Localizer["Site Root"]></option>
|
||||||
@foreach (Page page in _pageList)
|
@foreach (Page page in _pageList)
|
||||||
{
|
{
|
||||||
if (page.PageId.ToString() == _parentid)
|
if (page.PageId.ToString() == _parentid)
|
||||||
|
@ -46,20 +47,20 @@
|
||||||
<select id="Move" class="form-control" @bind="@_insert">
|
<select id="Move" class="form-control" @bind="@_insert">
|
||||||
@if (_parentid == _currentparentid)
|
@if (_parentid == _currentparentid)
|
||||||
{
|
{
|
||||||
<option value="="><Maintain Current Location></option>
|
<option value="="><@Localizer["Maintain Current Location"]></option>
|
||||||
}
|
}
|
||||||
<option value="<<">To Beginning</option>
|
<option value="<<">@Localizer["To Beginning"]</option>
|
||||||
@if (_children != null && _children.Count > 0)
|
@if (_children != null && _children.Count > 0)
|
||||||
{
|
{
|
||||||
<option value="<">Before</option>
|
<option value="<">@Localizer["Before"]</option>
|
||||||
<option value=">">After</option>
|
<option value=">">@Localizer["After"]</option>
|
||||||
}
|
}
|
||||||
<option value=">>">To End</option>
|
<option value=">>">@Localizer["To End"]</option>
|
||||||
</select>
|
</select>
|
||||||
@if (_children != null && _children.Count > 0 && (_insert == "<" || _insert == ">"))
|
@if (_children != null && _children.Count > 0 && (_insert == "<" || _insert == ">"))
|
||||||
{
|
{
|
||||||
<select class="form-control" @bind="@_childid">
|
<select class="form-control" @bind="@_childid">
|
||||||
<option value="-1"><Select Page></option>
|
<option value="-1"><@Localizer["Select Page"]></option>
|
||||||
@foreach (Page page in _children)
|
@foreach (Page page in _children)
|
||||||
{
|
{
|
||||||
<option value="@(page.PageId)">@(page.Name)</option>
|
<option value="@(page.PageId)">@(page.Name)</option>
|
||||||
|
@ -74,8 +75,8 @@
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<select id="Navigation" class="form-control" @bind="@_isnavigation">
|
<select id="Navigation" class="form-control" @bind="@_isnavigation">
|
||||||
<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>
|
||||||
|
@ -135,7 +136,7 @@
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<select id="Layout" class="form-control" @bind="@_layouttype">
|
<select id="Layout" class="form-control" @bind="@_layouttype">
|
||||||
<option value="-"><Inherit From Site></option>
|
<option value="-"><@Localizer["Inherit From Site"]></option>
|
||||||
@foreach (var layout in _layouts)
|
@foreach (var layout in _layouts)
|
||||||
{
|
{
|
||||||
if (layout.TypeName == _layouttype)
|
if (layout.TypeName == _layouttype)
|
||||||
|
@ -157,7 +158,7 @@
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<select id="defaultContainer" class="form-control" @bind="@_containertype">
|
<select id="defaultContainer" class="form-control" @bind="@_containertype">
|
||||||
<option value="-"><Inherit From Site></option>
|
<option value="-"><@Localizer["Inherit From Site"]></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>
|
||||||
|
@ -179,8 +180,8 @@
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<select id="Personalizable" class="form-control" @bind="@_ispersonalizable">
|
<select id="Personalizable" class="form-control" @bind="@_ispersonalizable">
|
||||||
<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>
|
||||||
|
@ -203,8 +204,8 @@
|
||||||
}
|
}
|
||||||
</TabPanel>
|
</TabPanel>
|
||||||
</TabStrip>
|
</TabStrip>
|
||||||
<button type="button" class="btn btn-success" @onclick="SavePage">Save</button>
|
<button type="button" class="btn btn-success" @onclick="SavePage">@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<Theme> _themeList;
|
private List<Theme> _themeList;
|
||||||
|
|
|
@ -2,6 +2,7 @@
|
||||||
@inherits ModuleBase
|
@inherits ModuleBase
|
||||||
@inject NavigationManager NavigationManager
|
@inject NavigationManager NavigationManager
|
||||||
@inject IPageService PageService
|
@inject IPageService PageService
|
||||||
|
@inject IStringLocalizer<Index> Localizer
|
||||||
|
|
||||||
@if (PageState.Pages != null)
|
@if (PageState.Pages != null)
|
||||||
{
|
{
|
||||||
|
@ -11,7 +12,7 @@
|
||||||
<Header>
|
<Header>
|
||||||
<th style="width: 1px;"> </th>
|
<th style="width: 1px;"> </th>
|
||||||
<th style="width: 1px;"> </th>
|
<th style="width: 1px;"> </th>
|
||||||
<th>Name</th>
|
<th>@Localizer["Name"]</th>
|
||||||
</Header>
|
</Header>
|
||||||
<Row>
|
<Row>
|
||||||
<td><ActionLink Action="Edit" Parameters="@($"id=" + context.PageId.ToString())" ResourceKey="EditPage" /></td>
|
<td><ActionLink Action="Edit" Parameters="@($"id=" + context.PageId.ToString())" ResourceKey="EditPage" /></td>
|
||||||
|
|
Loading…
Reference in New Issue
Block a user