From 79bf776678d529d5fe08dc6ee9eb9dba275f62d1 Mon Sep 17 00:00:00 2001 From: robvde Date: Tue, 11 Sep 2012 16:45:07 +0400 Subject: [PATCH] Exchange Storage Breakdown extended with average mailbox size --- .../ExchangeStorageUsageBreakdown.ascx.resx | 6 ++++ .../ExchangeStorageUsageBreakdown.ascx | 10 ++++++ .../ExchangeStorageUsageBreakdown.ascx.cs | 5 +++ ...angeStorageUsageBreakdown.ascx.designer.cs | 31 +++++++++++++++++-- 4 files changed, 50 insertions(+), 2 deletions(-) diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/App_LocalResources/ExchangeStorageUsageBreakdown.ascx.resx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/App_LocalResources/ExchangeStorageUsageBreakdown.ascx.resx index 4a2785d0..6688dce6 100644 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/App_LocalResources/ExchangeStorageUsageBreakdown.ascx.resx +++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/App_LocalResources/ExchangeStorageUsageBreakdown.ascx.resx @@ -186,4 +186,10 @@ Storage Usage + + Avg. Mailbox Size (MB): + + + Total Mailboxes: + \ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeStorageUsageBreakdown.ascx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeStorageUsageBreakdown.ascx index 9caf760e..d0fa7656 100644 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeStorageUsageBreakdown.ascx +++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeStorageUsageBreakdown.ascx @@ -42,6 +42,11 @@
+ + + + + @@ -50,6 +55,11 @@ + + + + +
177
177 100
100

diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeStorageUsageBreakdown.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeStorageUsageBreakdown.ascx.cs index 65246294..e1aa9574 100644 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeStorageUsageBreakdown.ascx.cs +++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeStorageUsageBreakdown.ascx.cs @@ -70,8 +70,13 @@ namespace WebsitePanel.Portal.ExchangeServer totalMailboxesSizeMB += item.TotalSizeMB; } + OrganizationStatistics stats = ES.Services.ExchangeServer.GetOrganizationStatisticsByOrganization(PanelRequest.ItemID); + lblTotalMailboxItems.Text = totalMailboxItems.ToString(); lblTotalMailboxSize.Text = totalMailboxesSizeMB.ToString(); + lblTotalMailboxes.Text = stats.CreatedMailboxes.ToString(); + int avgSize = totalMailboxesSizeMB / stats.CreatedMailboxes; + lblAverageMailboxSize.Text = avgSize.ToString("N2"); } } } \ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeStorageUsageBreakdown.ascx.designer.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeStorageUsageBreakdown.ascx.designer.cs index 178be03f..2692cd80 100644 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeStorageUsageBreakdown.ascx.designer.cs +++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/ExchangeServer/ExchangeStorageUsageBreakdown.ascx.designer.cs @@ -84,6 +84,24 @@ namespace WebsitePanel.Portal.ExchangeServer { /// protected global::System.Web.UI.WebControls.GridView gvMailboxes; + /// + /// locTotalMailboxes control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.Localize locTotalMailboxes; + + /// + /// lblTotalMailboxes control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.Label lblTotalMailboxes; + /// /// locTotalMailboxItems control. /// @@ -121,12 +139,21 @@ namespace WebsitePanel.Portal.ExchangeServer { protected global::System.Web.UI.WebControls.Label lblTotalMailboxSize; /// - /// FormComments control. + /// Localize1 control. /// /// /// Auto-generated field. /// To modify move field declaration from designer file to code-behind file. /// - protected global::System.Web.UI.WebControls.Localize FormComments; + protected global::System.Web.UI.WebControls.Localize Localize1; + + /// + /// lblAverageMailboxSize control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.Label lblAverageMailboxSize; } }