U4-7009 Changing passwords design oversight

This commit is contained in:
Sebastiaan Janssen
2017-04-11 20:53:34 +02:00
parent 376c78381d
commit b1c6276a67
5 changed files with 18 additions and 12 deletions

View File

@@ -4,6 +4,9 @@ using System.Configuration.Provider;
using System.Linq;
using System.Web;
using System.Web.Security;
using Umbraco.Core;
using Umbraco.Core.Models;
using Umbraco.Core.Security;
namespace Umbraco.Web.UI.Umbraco.Controls
{
@@ -20,9 +23,11 @@ namespace Umbraco.Web.UI.Umbraco.Controls
umbPasswordChanger_passwordNewConfirm.Text = null;
//reset the flag always
IsChangingPasswordField.Value = "false";
this.DataBind();
}
var auth = new HttpContextWrapper(HttpContext.Current).GetUmbracoAuthTicket();
ResetPlaceHolder.Visible = ApplicationContext.Current.Services.UserService.GetByUsername(auth.Name).IsAdmin();
this.DataBind();
}
}
}

View File

@@ -67,7 +67,7 @@
<asp:HiddenField runat="server" ID="IsChangingPasswordField" Value="false" />
<asp:PlaceHolder runat="server" ID="ResetPlaceHolder" Visible="<%#Provider.EnablePasswordReset %>">
<asp:PlaceHolder runat="server" ID="ResetPlaceHolder">
<div class="umb-el-wrap">
<label class="control-label" for="<%=ResetPasswordCheckBox.ClientID %>"><%=umbraco.ui.GetText("user", "resetPassword")%></label>
<div class="controls controls-row">