Lync Module fixes
This commit is contained in:
parent
f500906c68
commit
323e085b15
8 changed files with 229 additions and 73 deletions
|
@ -2745,3 +2745,38 @@ BEGIN
|
|||
INSERT [dbo].[Quotas] ([QuotaID], [GroupID],[QuotaOrder], [QuotaName], [QuotaDescription], [QuotaTypeID], [ServiceQuota], [ItemTypeID]) VALUES (462, 21, 4, N'HostedCRM.ESSUsers', N'ESS licenses per organization',3, 0 , NULL)
|
||||
END
|
||||
GO
|
||||
|
||||
|
||||
-- Lync
|
||||
|
||||
IF EXISTS (SELECT * FROM SYS.OBJECTS WHERE type = 'P' AND name = 'GetPackageIPAddressesCount')
|
||||
DROP PROCEDURE GetPackageIPAddressesCount
|
||||
GO
|
||||
|
||||
PROCEDURE [dbo].[GetPackageIPAddressesCount]
|
||||
(
|
||||
@PackageID int,
|
||||
@OrgID int,
|
||||
@PoolID int = 0
|
||||
)
|
||||
AS
|
||||
BEGIN
|
||||
|
||||
SELECT
|
||||
COUNT(PA.PackageAddressID)
|
||||
FROM
|
||||
dbo.PackageIPAddresses PA
|
||||
INNER JOIN
|
||||
dbo.IPAddresses AS IP ON PA.AddressID = IP.AddressID
|
||||
INNER JOIN
|
||||
dbo.Packages P ON PA.PackageID = P.PackageID
|
||||
INNER JOIN
|
||||
dbo.Users U ON U.UserID = P.UserID
|
||||
LEFT JOIN
|
||||
ServiceItems SI ON PA.ItemId = SI.ItemID
|
||||
WHERE
|
||||
(@PoolID = 0 OR @PoolID <> 0 AND IP.PoolID = @PoolID)
|
||||
AND (@OrgID = 0 OR @OrgID <> 0 AND PA.OrgID = @OrgID)
|
||||
|
||||
END
|
||||
|
||||
|
|
|
@ -52,8 +52,8 @@ using WebsitePanel.Server;
|
|||
using WebsitePanel.Providers.DNS;
|
||||
using WebsitePanel.Providers.ResultObjects;
|
||||
|
||||
namespace WebsitePanel.EnterpriseServer {
|
||||
|
||||
namespace WebsitePanel.EnterpriseServer
|
||||
{
|
||||
/// <remarks/>
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
|
||||
[System.Diagnostics.DebuggerStepThroughAttribute()]
|
||||
|
@ -61,6 +61,8 @@ namespace WebsitePanel.EnterpriseServer {
|
|||
[System.Web.Services.WebServiceBindingAttribute(Name="esServersSoap", Namespace="http://smbsaas/websitepanel/enterpriseserver")]
|
||||
public partial class esServers : Microsoft.Web.Services3.WebServicesClientProtocol {
|
||||
|
||||
private System.Threading.SendOrPostCallback GetDnsRecordsByServiceOperationCompleted;
|
||||
|
||||
private System.Threading.SendOrPostCallback GetDnsRecordsByServerOperationCompleted;
|
||||
|
||||
private System.Threading.SendOrPostCallback GetDnsRecordsByPackageOperationCompleted;
|
||||
|
@ -269,6 +271,8 @@ namespace WebsitePanel.EnterpriseServer {
|
|||
|
||||
private System.Threading.SendOrPostCallback GetPackageIPAddressesOperationCompleted;
|
||||
|
||||
private System.Threading.SendOrPostCallback GetPackageIPAddressesCountOperationCompleted;
|
||||
|
||||
private System.Threading.SendOrPostCallback GetPackageUnassignedIPAddressesOperationCompleted;
|
||||
|
||||
private System.Threading.SendOrPostCallback AllocatePackageIPAddressesOperationCompleted;
|
||||
|
@ -291,13 +295,14 @@ namespace WebsitePanel.EnterpriseServer {
|
|||
|
||||
private System.Threading.SendOrPostCallback GetRawDnsRecordsByGroupOperationCompleted;
|
||||
|
||||
private System.Threading.SendOrPostCallback GetDnsRecordsByServiceOperationCompleted;
|
||||
|
||||
/// <remarks/>
|
||||
public esServers() {
|
||||
this.Url = "http://localhost:9002/esServers.asmx";
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public event GetDnsRecordsByServiceCompletedEventHandler GetDnsRecordsByServiceCompleted;
|
||||
|
||||
/// <remarks/>
|
||||
public event GetDnsRecordsByServerCompletedEventHandler GetDnsRecordsByServerCompleted;
|
||||
|
||||
|
@ -610,6 +615,9 @@ namespace WebsitePanel.EnterpriseServer {
|
|||
/// <remarks/>
|
||||
public event GetPackageIPAddressesCompletedEventHandler GetPackageIPAddressesCompleted;
|
||||
|
||||
/// <remarks/>
|
||||
public event GetPackageIPAddressesCountCompletedEventHandler GetPackageIPAddressesCountCompleted;
|
||||
|
||||
/// <remarks/>
|
||||
public event GetPackageUnassignedIPAddressesCompletedEventHandler GetPackageUnassignedIPAddressesCompleted;
|
||||
|
||||
|
@ -644,7 +652,45 @@ namespace WebsitePanel.EnterpriseServer {
|
|||
public event GetRawDnsRecordsByGroupCompletedEventHandler GetRawDnsRecordsByGroupCompleted;
|
||||
|
||||
/// <remarks/>
|
||||
public event GetDnsRecordsByServiceCompletedEventHandler GetDnsRecordsByServiceCompleted;
|
||||
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/GetDnsRecordsByService", RequestNamespace="http://smbsaas/websitepanel/enterpriseserver", ResponseNamespace="http://smbsaas/websitepanel/enterpriseserver", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
|
||||
public GlobalDnsRecord[] GetDnsRecordsByService(int serviceId) {
|
||||
object[] results = this.Invoke("GetDnsRecordsByService", new object[] {
|
||||
serviceId});
|
||||
return ((GlobalDnsRecord[])(results[0]));
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public System.IAsyncResult BeginGetDnsRecordsByService(int serviceId, System.AsyncCallback callback, object asyncState) {
|
||||
return this.BeginInvoke("GetDnsRecordsByService", new object[] {
|
||||
serviceId}, callback, asyncState);
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public GlobalDnsRecord[] EndGetDnsRecordsByService(System.IAsyncResult asyncResult) {
|
||||
object[] results = this.EndInvoke(asyncResult);
|
||||
return ((GlobalDnsRecord[])(results[0]));
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public void GetDnsRecordsByServiceAsync(int serviceId) {
|
||||
this.GetDnsRecordsByServiceAsync(serviceId, null);
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public void GetDnsRecordsByServiceAsync(int serviceId, object userState) {
|
||||
if ((this.GetDnsRecordsByServiceOperationCompleted == null)) {
|
||||
this.GetDnsRecordsByServiceOperationCompleted = new System.Threading.SendOrPostCallback(this.OnGetDnsRecordsByServiceOperationCompleted);
|
||||
}
|
||||
this.InvokeAsync("GetDnsRecordsByService", new object[] {
|
||||
serviceId}, this.GetDnsRecordsByServiceOperationCompleted, userState);
|
||||
}
|
||||
|
||||
private void OnGetDnsRecordsByServiceOperationCompleted(object arg) {
|
||||
if ((this.GetDnsRecordsByServiceCompleted != null)) {
|
||||
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
|
||||
this.GetDnsRecordsByServiceCompleted(this, new GetDnsRecordsByServiceCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
|
||||
}
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/GetDnsRecordsByServer", RequestNamespace="http://smbsaas/websitepanel/enterpriseserver", ResponseNamespace="http://smbsaas/websitepanel/enterpriseserver", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
|
||||
|
@ -5196,6 +5242,53 @@ namespace WebsitePanel.EnterpriseServer {
|
|||
}
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/GetPackageIPAddressesCount", RequestNamespace="http://smbsaas/websitepanel/enterpriseserver", ResponseNamespace="http://smbsaas/websitepanel/enterpriseserver", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
|
||||
public int GetPackageIPAddressesCount(int packageId, int orgId, IPAddressPool pool) {
|
||||
object[] results = this.Invoke("GetPackageIPAddressesCount", new object[] {
|
||||
packageId,
|
||||
orgId,
|
||||
pool});
|
||||
return ((int)(results[0]));
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public System.IAsyncResult BeginGetPackageIPAddressesCount(int packageId, int orgId, IPAddressPool pool, System.AsyncCallback callback, object asyncState) {
|
||||
return this.BeginInvoke("GetPackageIPAddressesCount", new object[] {
|
||||
packageId,
|
||||
orgId,
|
||||
pool}, callback, asyncState);
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public int EndGetPackageIPAddressesCount(System.IAsyncResult asyncResult) {
|
||||
object[] results = this.EndInvoke(asyncResult);
|
||||
return ((int)(results[0]));
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public void GetPackageIPAddressesCountAsync(int packageId, int orgId, IPAddressPool pool) {
|
||||
this.GetPackageIPAddressesCountAsync(packageId, orgId, pool, null);
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public void GetPackageIPAddressesCountAsync(int packageId, int orgId, IPAddressPool pool, object userState) {
|
||||
if ((this.GetPackageIPAddressesCountOperationCompleted == null)) {
|
||||
this.GetPackageIPAddressesCountOperationCompleted = new System.Threading.SendOrPostCallback(this.OnGetPackageIPAddressesCountOperationCompleted);
|
||||
}
|
||||
this.InvokeAsync("GetPackageIPAddressesCount", new object[] {
|
||||
packageId,
|
||||
orgId,
|
||||
pool}, this.GetPackageIPAddressesCountOperationCompleted, userState);
|
||||
}
|
||||
|
||||
private void OnGetPackageIPAddressesCountOperationCompleted(object arg) {
|
||||
if ((this.GetPackageIPAddressesCountCompleted != null)) {
|
||||
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
|
||||
this.GetPackageIPAddressesCountCompleted(this, new GetPackageIPAddressesCountCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
|
||||
}
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/GetPackageUnassignedIPAddresses", RequestNamespace="http://smbsaas/websitepanel/enterpriseserver", ResponseNamespace="http://smbsaas/websitepanel/enterpriseserver", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
|
||||
public PackageIPAddress[] GetPackageUnassignedIPAddresses(int packageId, int orgId, IPAddressPool pool) {
|
||||
|
@ -5677,53 +5770,38 @@ namespace WebsitePanel.EnterpriseServer {
|
|||
}
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/GetDnsRecordsByService", RequestNamespace="http://smbsaas/websitepanel/enterpriseserver", ResponseNamespace="http://smbsaas/websitepanel/enterpriseserver", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
|
||||
public GlobalDnsRecord[] GetDnsRecordsByService(int serviceId) {
|
||||
object[] results = this.Invoke("GetDnsRecordsByService", new object[] {
|
||||
serviceId});
|
||||
return ((GlobalDnsRecord[])(results[0]));
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public System.IAsyncResult BeginGetDnsRecordsByService(int serviceId, System.AsyncCallback callback, object asyncState) {
|
||||
return this.BeginInvoke("GetDnsRecordsByService", new object[] {
|
||||
serviceId}, callback, asyncState);
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public GlobalDnsRecord[] EndGetDnsRecordsByService(System.IAsyncResult asyncResult) {
|
||||
object[] results = this.EndInvoke(asyncResult);
|
||||
return ((GlobalDnsRecord[])(results[0]));
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public void GetDnsRecordsByServiceAsync(int serviceId) {
|
||||
this.GetDnsRecordsByServiceAsync(serviceId, null);
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public void GetDnsRecordsByServiceAsync(int serviceId, object userState) {
|
||||
if ((this.GetDnsRecordsByServiceOperationCompleted == null)) {
|
||||
this.GetDnsRecordsByServiceOperationCompleted = new System.Threading.SendOrPostCallback(this.OnGetDnsRecordsByServiceOperationCompleted);
|
||||
}
|
||||
this.InvokeAsync("GetDnsRecordsByService", new object[] {
|
||||
serviceId}, this.GetDnsRecordsByServiceOperationCompleted, userState);
|
||||
}
|
||||
|
||||
private void OnGetDnsRecordsByServiceOperationCompleted(object arg) {
|
||||
if ((this.GetDnsRecordsByServiceCompleted != null)) {
|
||||
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
|
||||
this.GetDnsRecordsByServiceCompleted(this, new GetDnsRecordsByServiceCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
|
||||
}
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public new void CancelAsync(object userState) {
|
||||
base.CancelAsync(userState);
|
||||
}
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
|
||||
public delegate void GetDnsRecordsByServiceCompletedEventHandler(object sender, GetDnsRecordsByServiceCompletedEventArgs e);
|
||||
|
||||
/// <remarks/>
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
|
||||
[System.Diagnostics.DebuggerStepThroughAttribute()]
|
||||
[System.ComponentModel.DesignerCategoryAttribute("code")]
|
||||
public partial class GetDnsRecordsByServiceCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
|
||||
|
||||
private object[] results;
|
||||
|
||||
internal GetDnsRecordsByServiceCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
|
||||
base(exception, cancelled, userState) {
|
||||
this.results = results;
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public GlobalDnsRecord[] Result {
|
||||
get {
|
||||
this.RaiseExceptionIfNecessary();
|
||||
return ((GlobalDnsRecord[])(this.results[0]));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
|
||||
public delegate void GetDnsRecordsByServerCompletedEventHandler(object sender, GetDnsRecordsByServerCompletedEventArgs e);
|
||||
|
@ -8340,6 +8418,32 @@ namespace WebsitePanel.EnterpriseServer {
|
|||
}
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
|
||||
public delegate void GetPackageIPAddressesCountCompletedEventHandler(object sender, GetPackageIPAddressesCountCompletedEventArgs e);
|
||||
|
||||
/// <remarks/>
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
|
||||
[System.Diagnostics.DebuggerStepThroughAttribute()]
|
||||
[System.ComponentModel.DesignerCategoryAttribute("code")]
|
||||
public partial class GetPackageIPAddressesCountCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
|
||||
|
||||
private object[] results;
|
||||
|
||||
internal GetPackageIPAddressesCountCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
|
||||
base(exception, cancelled, userState) {
|
||||
this.results = results;
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public int Result {
|
||||
get {
|
||||
this.RaiseExceptionIfNecessary();
|
||||
return ((int)(this.results[0]));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
|
||||
public delegate void GetPackageUnassignedIPAddressesCompletedEventHandler(object sender, GetPackageUnassignedIPAddressesCompletedEventArgs e);
|
||||
|
@ -8625,30 +8729,4 @@ namespace WebsitePanel.EnterpriseServer {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
|
||||
public delegate void GetDnsRecordsByServiceCompletedEventHandler(object sender, GetDnsRecordsByServiceCompletedEventArgs e);
|
||||
|
||||
/// <remarks/>
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.42")]
|
||||
[System.Diagnostics.DebuggerStepThroughAttribute()]
|
||||
[System.ComponentModel.DesignerCategoryAttribute("code")]
|
||||
public partial class GetDnsRecordsByServiceCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
|
||||
|
||||
private object[] results;
|
||||
|
||||
internal GetDnsRecordsByServiceCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
|
||||
base(exception, cancelled, userState) {
|
||||
this.results = results;
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public GlobalDnsRecord[] Result {
|
||||
get {
|
||||
this.RaiseExceptionIfNecessary();
|
||||
return ((GlobalDnsRecord[])(this.results[0]));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -3286,6 +3286,17 @@ namespace WebsitePanel.EnterpriseServer
|
|||
return reader;
|
||||
}
|
||||
|
||||
public static int GetPackageIPAddressesCount(int packageId, int orgId, int poolId)
|
||||
{
|
||||
object obj = SqlHelper.ExecuteScalar(ConnectionString, CommandType.StoredProcedure,
|
||||
"GetPackageIPAddressesCount",
|
||||
new SqlParameter("@PackageID", packageId),
|
||||
new SqlParameter("@OrgID", orgId),
|
||||
new SqlParameter("@PoolId", poolId));
|
||||
int res = 0;
|
||||
int.TryParse(obj.ToString(), out res);
|
||||
return res;
|
||||
}
|
||||
|
||||
public static void DeallocatePackageIPAddress(int id)
|
||||
{
|
||||
|
|
|
@ -1186,6 +1186,11 @@ namespace WebsitePanel.EnterpriseServer
|
|||
return result;
|
||||
}
|
||||
|
||||
public static int GetPackageIPAddressesCount(int packageId, int orgId, IPAddressPool pool)
|
||||
{
|
||||
return DataProvider.GetPackageIPAddressesCount(packageId, orgId, (int)pool);
|
||||
}
|
||||
|
||||
public static List<IPAddressInfo> GetUnallottedIPAddresses(int packageId, string groupName, IPAddressPool pool)
|
||||
{
|
||||
// get service ID
|
||||
|
@ -1259,6 +1264,9 @@ namespace WebsitePanel.EnterpriseServer
|
|||
int quotaAllocated = cntx.Quotas[quotaName].QuotaAllocatedValue;
|
||||
int quotaUsed = cntx.Quotas[quotaName].QuotaUsedValue;
|
||||
|
||||
if (pool == IPAddressPool.PhoneNumbers)
|
||||
quotaUsed = ServerController.GetPackageIPAddressesCount(packageId, orgId, pool);
|
||||
|
||||
// check the maximum allowed number
|
||||
if (quotaAllocated != -1) // check only if not unlimited
|
||||
{
|
||||
|
|
|
@ -393,6 +393,12 @@ namespace WebsitePanel.EnterpriseServer
|
|||
filterColumn, filterValue, sortColumn, startRow, maximumRows, recursive);
|
||||
}
|
||||
|
||||
[WebMethod]
|
||||
public int GetPackageIPAddressesCount(int packageId, int orgId, IPAddressPool pool)
|
||||
{
|
||||
return ServerController.GetPackageIPAddressesCount(packageId, orgId, pool);
|
||||
}
|
||||
|
||||
[WebMethod]
|
||||
public List<PackageIPAddress> GetPackageUnassignedIPAddresses(int packageId, int orgId, IPAddressPool pool)
|
||||
{
|
||||
|
|
|
@ -31,6 +31,8 @@ using System.Collections.Generic;
|
|||
using System.Web;
|
||||
using System.Web.UI;
|
||||
using System.Web.UI.WebControls;
|
||||
using WebsitePanel.EnterpriseServer;
|
||||
using WebsitePanel.Providers.Common;
|
||||
|
||||
namespace WebsitePanel.Portal.Lync
|
||||
{
|
||||
|
@ -38,6 +40,15 @@ namespace WebsitePanel.Portal.Lync
|
|||
{
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
protected void Page_PreRender(object sender, EventArgs e)
|
||||
{
|
||||
if (!IsPostBack)
|
||||
{
|
||||
phoneQuota.Viewer.QuotaUsedValue = ES.Services.Servers.GetPackageIPAddressesCount(PanelSecurity.PackageId, PanelRequest.ItemID, IPAddressPool.PhoneNumbers);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -95,7 +95,9 @@ namespace WebsitePanel.Portal.UserControls
|
|||
if (cntx.Quotas.ContainsKey(quotaName))
|
||||
{
|
||||
int quotaAllocated = cntx.Quotas[quotaName].QuotaAllocatedValue;
|
||||
int quotaUsed = cntx.Quotas[quotaName].QuotaUsedValue;
|
||||
//int quotaUsed = cntx.Quotas[quotaName].QuotaUsedValue;
|
||||
|
||||
int quotaUsed = ES.Services.Servers.GetPackageIPAddressesCount(PanelSecurity.PackageId, PanelRequest.ItemID, IPAddressPool.PhoneNumbers);
|
||||
|
||||
if (quotaAllocated != -1)
|
||||
quotaAllowed = quotaAllocated - quotaUsed;
|
||||
|
|
|
@ -55,6 +55,11 @@ namespace WebsitePanel.Portal
|
|||
set { quotaViewer.DisplayGauge = value; }
|
||||
}
|
||||
|
||||
public QuotaViewer Viewer
|
||||
{
|
||||
get { return quotaViewer; }
|
||||
}
|
||||
|
||||
protected void Page_Load(object sender, EventArgs e)
|
||||
{
|
||||
if (!IsPostBack)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue