Localize non components for user profile pages
This commit is contained in:
		@ -2,7 +2,8 @@
 | 
			
		||||
@inherits ModuleBase
 | 
			
		||||
@inject NavigationManager NavigationManager
 | 
			
		||||
@inject IUserService UserService
 | 
			
		||||
@inject INotificationService NotificationService
 | 
			
		||||
@inject INotificationService NotificationService
 | 
			
		||||
@inject IStringLocalizer<Add> Localizer
 | 
			
		||||
 | 
			
		||||
@if (PageState.User != null)
 | 
			
		||||
{
 | 
			
		||||
@ -32,8 +33,8 @@
 | 
			
		||||
            </td>
 | 
			
		||||
        </tr>
 | 
			
		||||
    </table>
 | 
			
		||||
    <button type="button" class="btn btn-primary" @onclick="Send">Send</button>
 | 
			
		||||
    <NavLink class="btn btn-secondary" href="@NavigateUrl()">Cancel</NavLink>
 | 
			
		||||
    <button type="button" class="btn btn-primary" @onclick="Send">@Localizer["Send"]</button>
 | 
			
		||||
    <NavLink class="btn btn-secondary" href="@NavigateUrl()">@Localizer["Cancel"]</NavLink>
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
@code {
 | 
			
		||||
 | 
			
		||||
@ -5,6 +5,7 @@
 | 
			
		||||
@inject IProfileService ProfileService
 | 
			
		||||
@inject ISettingService SettingService
 | 
			
		||||
@inject INotificationService NotificationService
 | 
			
		||||
@inject IStringLocalizer<Index> Localizer
 | 
			
		||||
 | 
			
		||||
@if (PageState.User != null && photofileid != -1)
 | 
			
		||||
{
 | 
			
		||||
@ -21,7 +22,7 @@ else
 | 
			
		||||
            <table class="table table-borderless">
 | 
			
		||||
                <tr>
 | 
			
		||||
                    <td>
 | 
			
		||||
                        <label for="Name" class="control-label">Username: </label>
 | 
			
		||||
                        <label for="Name" class="control-label">@Localizer["Username:"] </label>
 | 
			
		||||
                    </td>
 | 
			
		||||
                    <td>
 | 
			
		||||
                        <input class="form-control" @bind="@username" readonly />
 | 
			
		||||
@ -29,7 +30,7 @@ else
 | 
			
		||||
                </tr>
 | 
			
		||||
                <tr>
 | 
			
		||||
                    <td>
 | 
			
		||||
                        <label for="Name" class="control-label">Password: </label>
 | 
			
		||||
                        <label for="Name" class="control-label">@Localizer["Password:"] </label>
 | 
			
		||||
                    </td>
 | 
			
		||||
                    <td>
 | 
			
		||||
                        <input type="password" class="form-control" @bind="@password" autocomplete="new-password" />
 | 
			
		||||
@ -37,7 +38,7 @@ else
 | 
			
		||||
                </tr>
 | 
			
		||||
                <tr>
 | 
			
		||||
                    <td>
 | 
			
		||||
                        <label for="Name" class="control-label">Confirm Password: </label>
 | 
			
		||||
                        <label for="Name" class="control-label">@Localizer["Confirm Password:"] </label>
 | 
			
		||||
                    </td>
 | 
			
		||||
                    <td>
 | 
			
		||||
                        <input type="password" class="form-control" @bind="@confirm" autocomplete="new-password" />
 | 
			
		||||
@ -45,7 +46,7 @@ else
 | 
			
		||||
                </tr>
 | 
			
		||||
                <tr>
 | 
			
		||||
                    <td>
 | 
			
		||||
                        <label for="Name" class="control-label">Email: </label>
 | 
			
		||||
                        <label for="Name" class="control-label">@Localizer["Email:"] </label>
 | 
			
		||||
                    </td>
 | 
			
		||||
                    <td>
 | 
			
		||||
                        <input class="form-control" @bind="@email" />
 | 
			
		||||
@ -53,7 +54,7 @@ else
 | 
			
		||||
                </tr>
 | 
			
		||||
                <tr>
 | 
			
		||||
                    <td>
 | 
			
		||||
                        <label for="Name" class="control-label">Full Name: </label>
 | 
			
		||||
                        <label for="Name" class="control-label">@Localizer["Full Name:"] </label>
 | 
			
		||||
                    </td>
 | 
			
		||||
                    <td>
 | 
			
		||||
                        <input class="form-control" @bind="@displayname" />
 | 
			
		||||
@ -61,15 +62,15 @@ else
 | 
			
		||||
                </tr>
 | 
			
		||||
                <tr>
 | 
			
		||||
                    <td>
 | 
			
		||||
                        <label for="Name" class="control-label">Photo: </label>
 | 
			
		||||
                        <label for="Name" class="control-label">@Localizer["Photo:"] </label>
 | 
			
		||||
                    </td>
 | 
			
		||||
                    <td>
 | 
			
		||||
                        <FileManager FileId="@photofileid" @ref="filemanager" />
 | 
			
		||||
                    </td>
 | 
			
		||||
                </tr>
 | 
			
		||||
            </table>
 | 
			
		||||
            <button type="button" class="btn btn-primary" @onclick="Save">Save</button>
 | 
			
		||||
            <button type="button" class="btn btn-secondary" @onclick="Cancel">Cancel</button>
 | 
			
		||||
            <button type="button" class="btn btn-primary" @onclick="Save">@Localizer["Save"]</button>
 | 
			
		||||
            <button type="button" class="btn btn-secondary" @onclick="Cancel">@Localizer["Cancel"]</button>
 | 
			
		||||
        }
 | 
			
		||||
    </TabPanel>
 | 
			
		||||
    <TabPanel Name="Profile" ResourceKey="Profile">
 | 
			
		||||
@ -127,8 +128,8 @@ else
 | 
			
		||||
                }
 | 
			
		||||
            }
 | 
			
		||||
        </table>
 | 
			
		||||
            <button type="button" class="btn btn-primary" @onclick="Save">Save</button>
 | 
			
		||||
            <button type="button" class="btn btn-secondary" @onclick="Cancel">Cancel</button>
 | 
			
		||||
            <button type="button" class="btn btn-primary" @onclick="Save">@Localizer["Save"]</button>
 | 
			
		||||
            <button type="button" class="btn btn-secondary" @onclick="Cancel">@Localizer["Cancel"]</button>
 | 
			
		||||
        }
 | 
			
		||||
    </TabPanel>
 | 
			
		||||
    <TabPanel Name="Notifications" ResourceKey="Notifications">
 | 
			
		||||
@ -142,9 +143,9 @@ else
 | 
			
		||||
                    <Header>
 | 
			
		||||
                        <th style="width: 1px;"> </th>
 | 
			
		||||
                        <th style="width: 1px;"> </th>
 | 
			
		||||
                        <th>From</th>
 | 
			
		||||
                        <th>Subject</th>
 | 
			
		||||
                        <th>Received</th>
 | 
			
		||||
                        <th>@Localizer["From"]</th>
 | 
			
		||||
                        <th>@Localizer["Subject"]</th>
 | 
			
		||||
                        <th>@Localizer["Received"]</th>
 | 
			
		||||
                    </Header>
 | 
			
		||||
                    <Row>
 | 
			
		||||
                        <td><ActionLink Action="View" Parameters="@($"id=" + context.NotificationId.ToString())" Security="SecurityAccessLevel.View" EditMode="false" ResourceKey="ViewNotification" /></td>
 | 
			
		||||
@ -174,9 +175,9 @@ else
 | 
			
		||||
                    <Header>
 | 
			
		||||
                        <th> </th>
 | 
			
		||||
                        <th> </th>
 | 
			
		||||
                        <th>To</th>
 | 
			
		||||
                        <th>Subject</th>
 | 
			
		||||
                        <th>Sent</th>
 | 
			
		||||
                        <th>@Localizer["To"]</th>
 | 
			
		||||
                        <th>@Localizer["Subject"]</th>
 | 
			
		||||
                        <th>@Localizer["Sent"]</th>
 | 
			
		||||
                    </Header>
 | 
			
		||||
                    <Row>
 | 
			
		||||
                        <td><ActionLink Action="View" Parameters="@($"id=" + context.NotificationId.ToString())" Security="SecurityAccessLevel.View" EditMode="false" ResourceKey="ViewNotification" /></td>
 | 
			
		||||
@ -202,8 +203,8 @@ else
 | 
			
		||||
            }
 | 
			
		||||
            <br /><hr />
 | 
			
		||||
            <select class="form-control" @onchange="(e => FilterChanged(e))">
 | 
			
		||||
                <option value="to">Inbox</option>
 | 
			
		||||
                <option value="from">Sent Items</option>
 | 
			
		||||
                <option value="to">@Localizer["Inbox"]</option>
 | 
			
		||||
                <option value="from">@Localizer["Sent Items"]</option>
 | 
			
		||||
            </select>
 | 
			
		||||
        }
 | 
			
		||||
    </TabPanel>
 | 
			
		||||
 | 
			
		||||
@ -1,8 +1,9 @@
 | 
			
		||||
@namespace Oqtane.Modules.Admin.UserProfile
 | 
			
		||||
@namespace Oqtane.Modules.Admin.UserProfile
 | 
			
		||||
@inherits ModuleBase
 | 
			
		||||
@inject NavigationManager NavigationManager
 | 
			
		||||
@inject IUserService UserService
 | 
			
		||||
@inject INotificationService NotificationService
 | 
			
		||||
@inject INotificationService NotificationService
 | 
			
		||||
@inject IStringLocalizer<View> Localizer
 | 
			
		||||
 | 
			
		||||
@if (PageState.User != null)
 | 
			
		||||
{
 | 
			
		||||
@ -26,7 +27,7 @@
 | 
			
		||||
        </tr>
 | 
			
		||||
        <tr>
 | 
			
		||||
            <td>
 | 
			
		||||
                <label class="control-label">Subject: </label>
 | 
			
		||||
                <label class="control-label">@Localizer["Subject:"] </label>
 | 
			
		||||
            </td>
 | 
			
		||||
            @if (title == "From")
 | 
			
		||||
            {
 | 
			
		||||
@ -45,7 +46,7 @@
 | 
			
		||||
        {
 | 
			
		||||
            <tr>
 | 
			
		||||
                <td>
 | 
			
		||||
                    <label class="control-label">Date: </label>
 | 
			
		||||
                    <label class="control-label">@Localizer["Date:"] </label>
 | 
			
		||||
                </td>
 | 
			
		||||
                <td>
 | 
			
		||||
                    <input class="form-control" @bind="@createdon" readonly />
 | 
			
		||||
@ -56,7 +57,7 @@
 | 
			
		||||
        {
 | 
			
		||||
            <tr>
 | 
			
		||||
                <td>
 | 
			
		||||
                    <label class="control-label">Message: </label>
 | 
			
		||||
                    <label class="control-label">@Localizer["Message:"] </label>
 | 
			
		||||
                </td>
 | 
			
		||||
                <td>
 | 
			
		||||
                    <textarea class="form-control" @bind="@body" rows="5" readonly />
 | 
			
		||||
@ -67,7 +68,7 @@
 | 
			
		||||
        {
 | 
			
		||||
            <tr>
 | 
			
		||||
                <td>
 | 
			
		||||
                    <label class="control-label">Message: </label>
 | 
			
		||||
                    <label class="control-label">@Localizer["Message:"] </label>
 | 
			
		||||
                </td>
 | 
			
		||||
                <td>
 | 
			
		||||
                    <textarea class="form-control" @bind="@body" rows="5" />
 | 
			
		||||
@ -79,24 +80,26 @@
 | 
			
		||||
 | 
			
		||||
    @if (reply != string.Empty)
 | 
			
		||||
    {
 | 
			
		||||
        <button type="button" class="btn btn-primary" @onclick="Send">Send</button> }
 | 
			
		||||
        <button type="button" class="btn btn-primary" @onclick="Send">@Localizer["Send"]</button>
 | 
			
		||||
    }
 | 
			
		||||
    else
 | 
			
		||||
    {
 | 
			
		||||
        if (title == "From")
 | 
			
		||||
        {
 | 
			
		||||
            <button type="button" class="btn btn-primary" @onclick="Reply">Reply</button>}
 | 
			
		||||
            <button type="button" class="btn btn-primary" @onclick="Reply">@Localizer["Reply"]</button>
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
    <NavLink class="btn btn-secondary" href="@NavigateUrl()">Cancel</NavLink>
 | 
			
		||||
    <NavLink class="btn btn-secondary" href="@NavigateUrl()">@Localizer["Cancel"]</NavLink>
 | 
			
		||||
    <br />
 | 
			
		||||
    <br />
 | 
			
		||||
    @if (title == "To")
 | 
			
		||||
    {
 | 
			
		||||
        <div class="control-group">
 | 
			
		||||
            <label class="control-label">Original Message </label>
 | 
			
		||||
            <label class="control-label">@Localizer["Original Message"] </label>
 | 
			
		||||
            <textarea class="form-control" @bind="@reply" rows="5" readonly />
 | 
			
		||||
        </div>
 | 
			
		||||
        }
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
@code {
 | 
			
		||||
    private int notificationid;
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user