@@ -70,8 +65,7 @@
-
+
|
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeRetentionPolicyTag.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeRetentionPolicyTag.ascx.cs
index f408cb91..cd947f14 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeRetentionPolicyTag.ascx.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeRetentionPolicyTag.ascx.cs
@@ -193,6 +193,10 @@ namespace WebsitePanel.Portal.ExchangeServer
protected void btnUpdatePolicy_Click(object sender, EventArgs e)
{
+ Page.Validate("CreatePolicy");
+
+ if (!Page.IsValid)
+ return;
if (ViewState["PolicyID"] == null)
return;
@@ -230,11 +234,6 @@ namespace WebsitePanel.Portal.ExchangeServer
}
- protected void txtPolicy_TextChanged(object sender, EventArgs e)
- {
- btnUpdatePolicy.Enabled = (string.IsNullOrEmpty(txtPolicy.Text)) ? false : true;
- }
-
public string GetTagType(int ItemID)
{
string imgName = string.Empty;
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeRetentionPolicyTag.ascx.designer.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeRetentionPolicyTag.ascx.designer.cs
index d062e890..edf7a9ed 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeRetentionPolicyTag.ascx.designer.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeRetentionPolicyTag.ascx.designer.cs
@@ -12,24 +12,6 @@ namespace WebsitePanel.Portal.ExchangeServer {
public partial class ExchangeRetentionPolicyTag {
- ///
- /// breadcrumb control.
- ///
- ///
- /// Auto-generated field.
- /// To modify move field declaration from designer file to code-behind file.
- ///
- protected global::WebsitePanel.Portal.ExchangeServer.UserControls.Breadcrumb breadcrumb;
-
- ///
- /// menu control.
- ///
- ///
- /// Auto-generated field.
- /// To modify move field declaration from designer file to code-behind file.
- ///
- protected global::WebsitePanel.Portal.ExchangeServer.UserControls.Menu menu;
-
///
/// Image1 control.
///
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SettingsExchangeMailboxPlansPolicy.ascx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SettingsExchangeMailboxPlansPolicy.ascx
index 855b6a24..9bab5526 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SettingsExchangeMailboxPlansPolicy.ascx
+++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SettingsExchangeMailboxPlansPolicy.ascx
@@ -32,7 +32,7 @@
+ meta:resourcekey="cmdDelete" OnClientClick="return confirm('Are you sure you want to delete selected plan?')">
@@ -66,7 +66,7 @@
+ ErrorMessage="Enter name" ValidationGroup="CreateMailboxPlan" Display="Dynamic" Text="*" SetFocusOnError="True">
@@ -317,7 +317,7 @@
-
+
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SettingsExchangeMailboxPlansPolicy.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SettingsExchangeMailboxPlansPolicy.ascx.cs
index 7bee29dc..c5d8956e 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SettingsExchangeMailboxPlansPolicy.ascx.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SettingsExchangeMailboxPlansPolicy.ascx.cs
@@ -63,6 +63,11 @@ namespace WebsitePanel.Portal
}
}
+ private string MainValidationGroup
+ {
+ get { return RetentionPolicy ? "CreateRetentionPolicy" : "CreateMailboxPlan"; }
+ }
+
public void BindSettings(UserSettings settings)
{
@@ -84,8 +89,9 @@ namespace WebsitePanel.Portal
gvMailboxPlans.Columns[4].Visible = !RetentionPolicy;
gvMailboxPlans.Columns[5].Visible = !RetentionPolicy;
- btnAddMailboxPlan.CausesValidation = RetentionPolicy;
- btnUpdateMailboxPlan.CausesValidation = RetentionPolicy;
+ btnAddMailboxPlan.ValidationGroup = MainValidationGroup;
+ btnUpdateMailboxPlan.ValidationGroup = MainValidationGroup;
+ valRequireMailboxPlan.ValidationGroup = MainValidationGroup;
UpdateTags();
@@ -125,7 +131,7 @@ namespace WebsitePanel.Portal
public void btnAddMailboxPlan_Click(object sender, EventArgs e)
{
if (!RetentionPolicy)
- Page.Validate("CreateMailboxPlan");
+ Page.Validate(MainValidationGroup);
if (!Page.IsValid)
return;
@@ -404,6 +410,10 @@ namespace WebsitePanel.Portal
protected void btnUpdateMailboxPlan_Click(object sender, EventArgs e)
{
+ Page.Validate(MainValidationGroup);
+
+ if (!Page.IsValid)
+ return;
if (ViewState["MailboxPlanID"] == null)
return;
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SettingsExchangeRetentionPolicyTag.ascx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SettingsExchangeRetentionPolicyTag.ascx
index 988cdb78..51caa706 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SettingsExchangeRetentionPolicyTag.ascx
+++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SettingsExchangeRetentionPolicyTag.ascx
@@ -43,8 +43,7 @@
-
+
|
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SettingsExchangeRetentionPolicyTag.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SettingsExchangeRetentionPolicyTag.ascx.cs
index 916b793e..43a6ac7a 100644
--- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SettingsExchangeRetentionPolicyTag.ascx.cs
+++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SettingsExchangeRetentionPolicyTag.ascx.cs
@@ -258,6 +258,10 @@ namespace WebsitePanel.Portal
protected void btnUpdatePolicy_Click(object sender, EventArgs e)
{
+ Page.Validate("CreatePolicy");
+
+ if (!Page.IsValid)
+ return;
if (ViewState["PolicyID"] == null)
return;
@@ -313,12 +317,5 @@ namespace WebsitePanel.Portal
BindRetentionPolicy();
}
-
- protected void txtPolicy_TextChanged(object sender, EventArgs e)
- {
- btnUpdatePolicy.Enabled = (string.IsNullOrEmpty(txtPolicy.Text)) ? false : true;
- }
-
-
}
}
\ No newline at end of file