using System;
using System.Data;
using System.Collections;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using CMS.PortalControls;
using CMS.GlobalHelper;
using CMS.CMSHelper;
public partial class CMSWebParts_Membership_Users_UnlockUserAccount : CMSAbstractWebPart
{
#region "Properties"
///
/// Information text
///
public string InformationText
{
get
{
return ValidationHelper.GetString(this.GetValue("InformationText"), "");
}
set
{
this.SetValue("InformationText", value);
}
}
///
/// Successful unlock text
///
public string SuccessfulUnlockText
{
get
{
return ValidationHelper.GetString(this.GetValue("SuccessfulUnlockText"), "");
}
set
{
this.SetValue("SuccessfulUnlockText", value);
}
}
///
/// Unsuccessful unlock text
///
public string UnsuccessfulUnlockText
{
get
{
return ValidationHelper.GetString(this.GetValue("UnsuccessfulUnlockText"), "");
}
set
{
this.SetValue("UnsuccessfulUnlockText", value);
}
}
///
/// Redirection URL
///
public string RedirectionUrl
{
get
{
return ValidationHelper.GetString(this.GetValue("RedirectionUrl"), "");
}
set
{
this.SetValue("RedirectionUrl", value);
}
}
#endregion
#region "Methods"
///
/// Content loaded event handler
///
public override void OnContentLoaded()
{
base.OnContentLoaded();
SetupControl();
}
///
/// Initializes the control properties
///
protected void SetupControl()
{
if (this.StopProcessing)
{
// Do not process
unlockAccount.StopProcessing = true;
}
else
{
if (!string.IsNullOrEmpty(QueryHelper.GetString("unlockaccounthash", string.Empty)))
{
unlockAccount.SuccessfulUnlockText = SuccessfulUnlockText;
unlockAccount.UnsuccessfulUnlockText = UnsuccessfulUnlockText;
unlockAccount.UnlockInfoText = InformationText;
unlockAccount.RedirectionURL = RedirectionUrl;
}
else
{
unlockAccount.StopProcessing = true;
}
}
}
///
/// Reloads the control data
///
public override void ReloadData()
{
base.ReloadData();
SetupControl();
}
#endregion
}