diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Client/HostedSharePointServersEntProxy.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Client/HostedSharePointServersEntProxy.cs index f49885a5..ff8492db 100644 --- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Client/HostedSharePointServersEntProxy.cs +++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Client/HostedSharePointServersEntProxy.cs @@ -140,7 +140,7 @@ namespace WebsitePanel.EnterpriseServer { /// [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/Enterprise_GetSiteCollectionsPaged", 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 SharePointSiteCollectionListPaged Enterprise_GetSiteCollectionsPaged(int packageId, int organizationId, string filterColumn, string filterValue, string sortColumn, int startRow, int maximumRows) { + public SharePointEnterpriseSiteCollectionListPaged Enterprise_GetSiteCollectionsPaged(int packageId, int organizationId, string filterColumn, string filterValue, string sortColumn, int startRow, int maximumRows) { object[] results = this.Invoke("Enterprise_GetSiteCollectionsPaged", new object[] { packageId, organizationId, @@ -149,7 +149,7 @@ namespace WebsitePanel.EnterpriseServer { sortColumn, startRow, maximumRows}); - return ((SharePointSiteCollectionListPaged)(results[0])); + return ((SharePointEnterpriseSiteCollectionListPaged)(results[0])); } /// @@ -165,9 +165,9 @@ namespace WebsitePanel.EnterpriseServer { } /// - public SharePointSiteCollectionListPaged EndEnterprise_GetSiteCollectionsPaged(System.IAsyncResult asyncResult) { + public SharePointEnterpriseSiteCollectionListPaged EndEnterprise_GetSiteCollectionsPaged(System.IAsyncResult asyncResult) { object[] results = this.EndInvoke(asyncResult); - return ((SharePointSiteCollectionListPaged)(results[0])); + return ((SharePointEnterpriseSiteCollectionListPaged)(results[0])); } /// @@ -240,11 +240,11 @@ namespace WebsitePanel.EnterpriseServer { /// [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/Enterprise_GetSiteCollections", 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 SharePointSiteCollection[] Enterprise_GetSiteCollections(int packageId, bool recursive) { + public SharePointEnterpriseSiteCollection[] Enterprise_GetSiteCollections(int packageId, bool recursive) { object[] results = this.Invoke("Enterprise_GetSiteCollections", new object[] { packageId, recursive}); - return ((SharePointSiteCollection[])(results[0])); + return ((SharePointEnterpriseSiteCollection[])(results[0])); } /// @@ -255,9 +255,9 @@ namespace WebsitePanel.EnterpriseServer { } /// - public SharePointSiteCollection[] EndEnterprise_GetSiteCollections(System.IAsyncResult asyncResult) { + public SharePointEnterpriseSiteCollection[] EndEnterprise_GetSiteCollections(System.IAsyncResult asyncResult) { object[] results = this.EndInvoke(asyncResult); - return ((SharePointSiteCollection[])(results[0])); + return ((SharePointEnterpriseSiteCollection[])(results[0])); } /// @@ -334,10 +334,10 @@ namespace WebsitePanel.EnterpriseServer { /// [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/Enterprise_GetSiteCollection", 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 SharePointSiteCollection Enterprise_GetSiteCollection(int itemId) { + public SharePointEnterpriseSiteCollection Enterprise_GetSiteCollection(int itemId) { object[] results = this.Invoke("Enterprise_GetSiteCollection", new object[] { itemId}); - return ((SharePointSiteCollection)(results[0])); + return ((SharePointEnterpriseSiteCollection)(results[0])); } /// @@ -347,9 +347,9 @@ namespace WebsitePanel.EnterpriseServer { } /// - public SharePointSiteCollection EndEnterprise_GetSiteCollection(System.IAsyncResult asyncResult) { + public SharePointEnterpriseSiteCollection EndEnterprise_GetSiteCollection(System.IAsyncResult asyncResult) { object[] results = this.EndInvoke(asyncResult); - return ((SharePointSiteCollection)(results[0])); + return ((SharePointEnterpriseSiteCollection)(results[0])); } /// @@ -376,11 +376,11 @@ namespace WebsitePanel.EnterpriseServer { /// [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/Enterprise_GetSiteCollectionByDomain" + "", 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 SharePointSiteCollection Enterprise_GetSiteCollectionByDomain(int organizationId, string domain) { + public SharePointEnterpriseSiteCollection Enterprise_GetSiteCollectionByDomain(int organizationId, string domain) { object[] results = this.Invoke("Enterprise_GetSiteCollectionByDomain", new object[] { organizationId, domain}); - return ((SharePointSiteCollection)(results[0])); + return ((SharePointEnterpriseSiteCollection)(results[0])); } /// @@ -391,9 +391,9 @@ namespace WebsitePanel.EnterpriseServer { } /// - public SharePointSiteCollection EndEnterprise_GetSiteCollectionByDomain(System.IAsyncResult asyncResult) { + public SharePointEnterpriseSiteCollection EndEnterprise_GetSiteCollectionByDomain(System.IAsyncResult asyncResult) { object[] results = this.EndInvoke(asyncResult); - return ((SharePointSiteCollection)(results[0])); + return ((SharePointEnterpriseSiteCollection)(results[0])); } /// @@ -420,14 +420,14 @@ namespace WebsitePanel.EnterpriseServer { /// [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/Enterprise_AddSiteCollection", 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 Enterprise_AddSiteCollection(SharePointSiteCollection item) { + public int Enterprise_AddSiteCollection(SharePointEnterpriseSiteCollection item) { object[] results = this.Invoke("Enterprise_AddSiteCollection", new object[] { item}); return ((int)(results[0])); } /// - public System.IAsyncResult BeginEnterprise_AddSiteCollection(SharePointSiteCollection item, System.AsyncCallback callback, object asyncState) { + public System.IAsyncResult BeginEnterprise_AddSiteCollection(SharePointEnterpriseSiteCollection item, System.AsyncCallback callback, object asyncState) { return this.BeginInvoke("Enterprise_AddSiteCollection", new object[] { item}, callback, asyncState); } @@ -439,12 +439,12 @@ namespace WebsitePanel.EnterpriseServer { } /// - public void Enterprise_AddSiteCollectionAsync(SharePointSiteCollection item) { + public void Enterprise_AddSiteCollectionAsync(SharePointEnterpriseSiteCollection item) { this.Enterprise_AddSiteCollectionAsync(item, null); } /// - public void Enterprise_AddSiteCollectionAsync(SharePointSiteCollection item, object userState) { + public void Enterprise_AddSiteCollectionAsync(SharePointEnterpriseSiteCollection item, object userState) { if ((this.Enterprise_AddSiteCollectionOperationCompleted == null)) { this.Enterprise_AddSiteCollectionOperationCompleted = new System.Threading.SendOrPostCallback(this.OnEnterprise_AddSiteCollectionOperationCompleted); } @@ -745,11 +745,11 @@ namespace WebsitePanel.EnterpriseServer { /// [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/enterpriseserver/Enterprise_CalculateSharePointSitesD" + "iskSpace", 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 SharePointSiteDiskSpace[] Enterprise_CalculateSharePointSitesDiskSpace(int itemId, out int errorCode) { + public SharePointEnterpriseSiteDiskSpace[] Enterprise_CalculateSharePointSitesDiskSpace(int itemId, out int errorCode) { object[] results = this.Invoke("Enterprise_CalculateSharePointSitesDiskSpace", new object[] { itemId}); errorCode = ((int)(results[1])); - return ((SharePointSiteDiskSpace[])(results[0])); + return ((SharePointEnterpriseSiteDiskSpace[])(results[0])); } /// @@ -759,10 +759,10 @@ namespace WebsitePanel.EnterpriseServer { } /// - public SharePointSiteDiskSpace[] EndEnterprise_CalculateSharePointSitesDiskSpace(System.IAsyncResult asyncResult, out int errorCode) { + public SharePointEnterpriseSiteDiskSpace[] EndEnterprise_CalculateSharePointSitesDiskSpace(System.IAsyncResult asyncResult, out int errorCode) { object[] results = this.EndInvoke(asyncResult); errorCode = ((int)(results[1])); - return ((SharePointSiteDiskSpace[])(results[0])); + return ((SharePointEnterpriseSiteDiskSpace[])(results[0])); } /// @@ -858,10 +858,10 @@ namespace WebsitePanel.EnterpriseServer { } /// - public SharePointSiteCollectionListPaged Result { + public SharePointEnterpriseSiteCollectionListPaged Result { get { this.RaiseExceptionIfNecessary(); - return ((SharePointSiteCollectionListPaged)(this.results[0])); + return ((SharePointEnterpriseSiteCollectionListPaged)(this.results[0])); } } } @@ -910,10 +910,10 @@ namespace WebsitePanel.EnterpriseServer { } /// - public SharePointSiteCollection[] Result { + public SharePointEnterpriseSiteCollection[] Result { get { this.RaiseExceptionIfNecessary(); - return ((SharePointSiteCollection[])(this.results[0])); + return ((SharePointEnterpriseSiteCollection[])(this.results[0])); } } } @@ -962,10 +962,10 @@ namespace WebsitePanel.EnterpriseServer { } /// - public SharePointSiteCollection Result { + public SharePointEnterpriseSiteCollection Result { get { this.RaiseExceptionIfNecessary(); - return ((SharePointSiteCollection)(this.results[0])); + return ((SharePointEnterpriseSiteCollection)(this.results[0])); } } } @@ -988,10 +988,10 @@ namespace WebsitePanel.EnterpriseServer { } /// - public SharePointSiteCollection Result { + public SharePointEnterpriseSiteCollection Result { get { this.RaiseExceptionIfNecessary(); - return ((SharePointSiteCollection)(this.results[0])); + return ((SharePointEnterpriseSiteCollection)(this.results[0])); } } } @@ -1196,10 +1196,10 @@ namespace WebsitePanel.EnterpriseServer { } /// - public SharePointSiteDiskSpace[] Result { + public SharePointEnterpriseSiteDiskSpace[] Result { get { this.RaiseExceptionIfNecessary(); - return ((SharePointSiteDiskSpace[])(this.results[0])); + return ((SharePointEnterpriseSiteDiskSpace[])(this.results[0])); } } diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/HostedSolution/OrganizationController.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/HostedSolution/OrganizationController.cs index 8b536f54..5bb15cef 100644 --- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/HostedSolution/OrganizationController.cs +++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/HostedSolution/OrganizationController.cs @@ -990,7 +990,7 @@ namespace WebsitePanel.EnterpriseServer if (cntxTmp.Groups.ContainsKey(ResourceGroups.SharepointEnterpriseServer)) { - SharePointSiteCollectionListPaged sharePointStats = HostedSharePointServerEntController.GetSiteCollectionsPaged(org.PackageId, org.Id, string.Empty, string.Empty, string.Empty, 0, 0); + SharePointEnterpriseSiteCollectionListPaged sharePointStats = HostedSharePointServerEntController.GetSiteCollectionsPaged(org.PackageId, org.Id, string.Empty, string.Empty, string.Empty, 0, 0); stats.CreatedSharePointEnterpriseSiteCollections = sharePointStats.TotalRowCount; } diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/HostedSolution/ReportController.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/HostedSolution/ReportController.cs index 166cc63a..16bf13ef 100644 --- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/HostedSolution/ReportController.cs +++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/HostedSolution/ReportController.cs @@ -464,7 +464,7 @@ namespace WebsitePanel.EnterpriseServer.Code.HostedSolution private static void PopulateSharePointEnterpriseItem(Organization org, EnterpriseSolutionStatisticsReport report, string topReseller) { - List siteCollections; + List siteCollections; try { @@ -491,7 +491,7 @@ namespace WebsitePanel.EnterpriseServer.Code.HostedSolution string.Format("Could not get sharepoint enterprise server. PackageId: {0}", org.PackageId), ex); } - foreach (SharePointSiteCollection siteCollection in siteCollections) + foreach (SharePointEnterpriseSiteCollection siteCollection in siteCollections) { try { diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/SharePoint/HostedSharePointServerEntController.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/SharePoint/HostedSharePointServerEntController.cs index 4ecba88f..94020e38 100644 --- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/SharePoint/HostedSharePointServerEntController.cs +++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer.Code/SharePoint/HostedSharePointServerEntController.cs @@ -58,24 +58,24 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint /// Row index to start from. /// Maximum number of rows to retrieve. /// Site collections that match. - public static SharePointSiteCollectionListPaged GetSiteCollectionsPaged(int packageId, int organizationId, string filterColumn, string filterValue, string sortColumn, int startRow, int maximumRows) + public static SharePointEnterpriseSiteCollectionListPaged GetSiteCollectionsPaged(int packageId, int organizationId, string filterColumn, string filterValue, string sortColumn, int startRow, int maximumRows) { if (IsDemoMode) { - SharePointSiteCollectionListPaged demoResult = new SharePointSiteCollectionListPaged(); + SharePointEnterpriseSiteCollectionListPaged demoResult = new SharePointEnterpriseSiteCollectionListPaged(); demoResult.SiteCollections = GetSiteCollections(1, false); demoResult.TotalRowCount = demoResult.SiteCollections.Count; return demoResult; } - SharePointSiteCollectionListPaged paged = new SharePointSiteCollectionListPaged(); - DataSet result = PackageController.GetRawPackageItemsPaged(packageId, "Sharepoint Enterprise Server", typeof(SharePointSiteCollection), + SharePointEnterpriseSiteCollectionListPaged paged = new SharePointEnterpriseSiteCollectionListPaged(); + DataSet result = PackageController.GetRawPackageItemsPaged(packageId, "Sharepoint Enterprise Server", typeof(SharePointEnterpriseSiteCollection), true, filterColumn, filterValue, sortColumn, startRow, Int32.MaxValue); - List items = PackageController.CreateServiceItemsList(result, 1).ConvertAll(delegate(ServiceProviderItem item) { return (SharePointSiteCollection)item; }); + List items = PackageController.CreateServiceItemsList(result, 1).ConvertAll(delegate(ServiceProviderItem item) { return (SharePointEnterpriseSiteCollection)item; }); if (organizationId > 0) { - items = items.FindAll(delegate(SharePointSiteCollection siteCollection) { return siteCollection.OrganizationId == organizationId; }); + items = items.FindAll(delegate(SharePointEnterpriseSiteCollection siteCollection) { return siteCollection.OrganizationId == organizationId; }); } paged.TotalRowCount = items.Count; @@ -89,16 +89,16 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint return paged; } - public static List GetSiteCollections(int organizationId) + public static List GetSiteCollections(int organizationId) { Organization org = OrganizationController.GetOrganization(organizationId); - List items = PackageController.GetPackageItemsByType(org.PackageId, typeof(SharePointSiteCollection), false); - items.ConvertAll(delegate(ServiceProviderItem item) { return (SharePointSiteCollection)item; }); - List ret = new List(); + List items = PackageController.GetPackageItemsByType(org.PackageId, typeof(SharePointEnterpriseSiteCollection), false); + items.ConvertAll(delegate(ServiceProviderItem item) { return (SharePointEnterpriseSiteCollection)item; }); + List ret = new List(); foreach (ServiceProviderItem item in items) { - SharePointSiteCollection siteCollection = item as SharePointSiteCollection; + SharePointEnterpriseSiteCollection siteCollection = item as SharePointEnterpriseSiteCollection; if (siteCollection != null && siteCollection.OrganizationId == organizationId) { ret.Add(siteCollection); @@ -150,12 +150,12 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint /// Package that owns site collections. /// A value which shows whether nested spaces must be searched as well. /// List of found site collections. - public static List GetSiteCollections(int packageId, bool recursive) + public static List GetSiteCollections(int packageId, bool recursive) { if (IsDemoMode) { - List demoResult = new List(); - SharePointSiteCollection siteCollection1 = new SharePointSiteCollection(); + List demoResult = new List(); + SharePointEnterpriseSiteCollection siteCollection1 = new SharePointEnterpriseSiteCollection(); siteCollection1.Id = 1; siteCollection1.OrganizationId = 1; siteCollection1.LocaleId = 1033; @@ -167,7 +167,7 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint siteCollection1.Title = "John Smith's Team Site"; siteCollection1.Url = "http://john.fabrikam.com"; demoResult.Add(siteCollection1); - SharePointSiteCollection siteCollection2 = new SharePointSiteCollection(); + SharePointEnterpriseSiteCollection siteCollection2 = new SharePointEnterpriseSiteCollection(); siteCollection2.Id = 2; siteCollection1.OrganizationId = 1; siteCollection2.LocaleId = 1033; @@ -183,8 +183,8 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint } - List items = PackageController.GetPackageItemsByType(packageId, typeof(SharePointSiteCollection), recursive); - return items.ConvertAll(delegate(ServiceProviderItem item) { return (SharePointSiteCollection)item; }); + List items = PackageController.GetPackageItemsByType(packageId, typeof(SharePointEnterpriseSiteCollection), recursive); + return items.ConvertAll(delegate(ServiceProviderItem item) { return (SharePointEnterpriseSiteCollection)item; }); } /// @@ -192,14 +192,14 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint /// /// Site collection id within metabase. /// Site collection or null in case no such item exist. - public static SharePointSiteCollection GetSiteCollection(int itemId) + public static SharePointEnterpriseSiteCollection GetSiteCollection(int itemId) { if (IsDemoMode) { return GetSiteCollections(1, false)[itemId - 1]; } - SharePointSiteCollection item = PackageController.GetPackageItem(itemId) as SharePointSiteCollection; + SharePointEnterpriseSiteCollection item = PackageController.GetPackageItem(itemId) as SharePointEnterpriseSiteCollection; return item; } @@ -208,7 +208,7 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint /// /// Site collection description. /// Created site collection id within metabase. - public static int AddSiteCollection(SharePointSiteCollection item) + public static int AddSiteCollection(SharePointEnterpriseSiteCollection item) { // Check account. @@ -274,7 +274,7 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint item.Name = String.Format("{0}://{1}", rootWebApplicationUri.Scheme, hostNameBase + "-" + counter.ToString() + "." + sslRoot); siteName = String.Format("{0}", hostNameBase + "-" + counter.ToString() + "." + sslRoot); - while (DataProvider.CheckServiceItemExists(serviceId, item.Name, "WebsitePanel.Providers.SharePoint.SharePointSiteCollection, WebsitePanel.Providers.Base")) + while (DataProvider.CheckServiceItemExists(serviceId, item.Name, "WebsitePanel.Providers.SharePoint.SharePointEnterpriseSiteCollection, WebsitePanel.Providers.Base")) { counter++; item.Name = String.Format("{0}://{1}", rootWebApplicationUri.Scheme, hostNameBase + "-" + counter.ToString() + "." + sslRoot); @@ -304,7 +304,7 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint // Check package item with given name already exists. - if (PackageController.GetPackageItemByName(item.PackageId, item.Name, typeof(SharePointSiteCollection)) != null) + if (PackageController.GetPackageItemByName(item.PackageId, item.Name, typeof(SharePointEnterpriseSiteCollection)) != null) { return BusinessErrorCodes.ERROR_SHAREPOINT_PACKAGE_ITEM_EXISTS; } @@ -370,7 +370,7 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint } // Load original meta item - SharePointSiteCollection origItem = (SharePointSiteCollection)PackageController.GetPackageItem(itemId); + SharePointEnterpriseSiteCollection origItem = (SharePointEnterpriseSiteCollection)PackageController.GetPackageItem(itemId); if (origItem == null) { return BusinessErrorCodes.ERROR_SHAREPOINT_PACKAGE_ITEM_NOT_FOUND; @@ -427,8 +427,8 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint public static void DeleteSiteCollections(int organizationId) { Organization org = OrganizationController.GetOrganization(organizationId); - SharePointSiteCollectionListPaged existentSiteCollections = GetSiteCollectionsPaged(org.PackageId, org.Id, String.Empty, String.Empty, String.Empty, 0, Int32.MaxValue); - foreach (SharePointSiteCollection existentSiteCollection in existentSiteCollections.SiteCollections) + SharePointEnterpriseSiteCollectionListPaged existentSiteCollections = GetSiteCollectionsPaged(org.PackageId, org.Id, String.Empty, String.Empty, String.Empty, 0, Int32.MaxValue); + foreach (SharePointEnterpriseSiteCollection existentSiteCollection in existentSiteCollections.SiteCollections) { DeleteSiteCollection(existentSiteCollection.Id); } @@ -453,7 +453,7 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint } // Load original meta item - SharePointSiteCollection origItem = (SharePointSiteCollection)PackageController.GetPackageItem(itemId); + SharePointEnterpriseSiteCollection origItem = (SharePointEnterpriseSiteCollection)PackageController.GetPackageItem(itemId); if (origItem == null) { return null; @@ -536,7 +536,7 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint } // Load original meta item. - SharePointSiteCollection origItem = (SharePointSiteCollection)PackageController.GetPackageItem(itemId); + SharePointEnterpriseSiteCollection origItem = (SharePointEnterpriseSiteCollection)PackageController.GetPackageItem(itemId); if (origItem == null) { return BusinessErrorCodes.ERROR_SHAREPOINT_PACKAGE_ITEM_NOT_FOUND; @@ -617,7 +617,7 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint public static byte[] GetBackupBinaryChunk(int itemId, string path, int offset, int length) { // Load original meta item. - SharePointSiteCollection item = (SharePointSiteCollection)PackageController.GetPackageItem(itemId); + SharePointEnterpriseSiteCollection item = (SharePointEnterpriseSiteCollection)PackageController.GetPackageItem(itemId); if (item == null) { return null; @@ -638,7 +638,7 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint public static string AppendBackupBinaryChunk(int itemId, string fileName, string path, byte[] chunk) { // Load original meta item. - SharePointSiteCollection item = (SharePointSiteCollection)PackageController.GetPackageItem(itemId); + SharePointEnterpriseSiteCollection item = (SharePointEnterpriseSiteCollection)PackageController.GetPackageItem(itemId); if (item == null) { return null; @@ -681,9 +681,9 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint } HostedSharePointServerEnt hostedSharePointServer = GetHostedSharePointServer(serviceId); - if (itemType == typeof(SharePointSiteCollection)) + if (itemType == typeof(SharePointEnterpriseSiteCollection)) { - foreach (SharePointSiteCollection siteCollection in hostedSharePointServer.Enterprise_GetSiteCollections()) + foreach (SharePointEnterpriseSiteCollection siteCollection in hostedSharePointServer.Enterprise_GetSiteCollections()) { items.Add(siteCollection.Url); } @@ -710,9 +710,9 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint } HostedSharePointServerEnt hostedSharePointServer = GetHostedSharePointServer(serviceId); - if (itemType == typeof(SharePointSiteCollection)) + if (itemType == typeof(SharePointEnterpriseSiteCollection)) { - SharePointSiteCollection siteCollection = hostedSharePointServer.Enterprise_GetSiteCollection(itemName); + SharePointEnterpriseSiteCollection siteCollection = hostedSharePointServer.Enterprise_GetSiteCollection(itemName); PackageController.AddPackageItem(siteCollection); } } @@ -727,11 +727,11 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint /// Resulting code. public int BackupItem(string tempFolder, XmlWriter writer, ServiceProviderItem item, ResourceGroupInfo group) { - SharePointSiteCollection siteCollection = item as SharePointSiteCollection; + SharePointEnterpriseSiteCollection siteCollection = item as SharePointEnterpriseSiteCollection; if (siteCollection != null) { HostedSharePointServerEnt hostedSharePointServer = GetHostedSharePointServer(siteCollection.ServiceId); - SharePointSiteCollection loadedSiteCollection = hostedSharePointServer.Enterprise_GetSiteCollection(siteCollection.Url); + SharePointEnterpriseSiteCollection loadedSiteCollection = hostedSharePointServer.Enterprise_GetSiteCollection(siteCollection.Url); // Update item siteCollection.Url = loadedSiteCollection.Url; siteCollection.OwnerLogin = loadedSiteCollection.OwnerLogin; @@ -741,7 +741,7 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint siteCollection.Title = loadedSiteCollection.Title; siteCollection.Description = loadedSiteCollection.Description; // Serialize it. - XmlSerializer serializer = new XmlSerializer(typeof(SharePointSiteCollection)); + XmlSerializer serializer = new XmlSerializer(typeof(SharePointEnterpriseSiteCollection)); serializer.Serialize(writer, siteCollection); } @@ -762,12 +762,12 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint /// Resulting code. public int RestoreItem(string tempFolder, XmlNode itemNode, int itemId, Type itemType, string itemName, int packageId, int serviceId, ResourceGroupInfo group) { - if (itemType == typeof(SharePointSiteCollection)) + if (itemType == typeof(SharePointEnterpriseSiteCollection)) { HostedSharePointServerEnt hostedSharePointServer = GetHostedSharePointServer(serviceId); // Deserialize item. - XmlSerializer serializer = new XmlSerializer(typeof(SharePointSiteCollection)); - SharePointSiteCollection siteCollection = (SharePointSiteCollection)serializer.Deserialize(new XmlNodeReader(itemNode.SelectSingleNode("SharePointSiteCollection"))); + XmlSerializer serializer = new XmlSerializer(typeof(SharePointEnterpriseSiteCollection)); + SharePointEnterpriseSiteCollection siteCollection = (SharePointEnterpriseSiteCollection)serializer.Deserialize(new XmlNodeReader(itemNode.SelectSingleNode("SharePointEnterpriseSiteCollection"))); siteCollection.PackageId = packageId; siteCollection.ServiceId = serviceId; @@ -778,7 +778,7 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint } // Add metabase record if needed. - SharePointSiteCollection metaSiteCollection = (SharePointSiteCollection)PackageController.GetPackageItemByName(packageId, itemName, typeof(SharePointSiteCollection)); + SharePointEnterpriseSiteCollection metaSiteCollection = (SharePointEnterpriseSiteCollection)PackageController.GetPackageItemByName(packageId, itemName, typeof(SharePointEnterpriseSiteCollection)); if (metaSiteCollection == null) { PackageController.AddPackageItem(siteCollection); @@ -794,11 +794,11 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint return PackageController.GetPackageServiceId(packageId, ResourceGroups.SharepointEnterpriseServer); } - private static List GetOrganizationSharePointSiteCollections(int orgId) + private static List GetOrganizationSharePointEnterpriseSiteCollections(int orgId) { Organization org = OrganizationController.GetOrganization(orgId); - SharePointSiteCollectionListPaged siteCollections = GetSiteCollectionsPaged(org.PackageId, org.Id, String.Empty, String.Empty, String.Empty, 0, Int32.MaxValue); + SharePointEnterpriseSiteCollectionListPaged siteCollections = GetSiteCollectionsPaged(org.PackageId, org.Id, String.Empty, String.Empty, String.Empty, 0, Int32.MaxValue); return siteCollections.SiteCollections; } @@ -873,15 +873,15 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint HostedSharePointServerEnt hostedSharePointServer = GetHostedSharePointServer(serviceId); - List currentOrgSiteCollection = - GetOrganizationSharePointSiteCollections(org.Id); + List currentOrgSiteCollection = + GetOrganizationSharePointEnterpriseSiteCollections(org.Id); - foreach (SharePointSiteCollection siteCollection in currentOrgSiteCollection) + foreach (SharePointEnterpriseSiteCollection siteCollection in currentOrgSiteCollection) { try { - SharePointSiteCollection sc = GetSiteCollection(siteCollection.Id); + SharePointEnterpriseSiteCollection sc = GetSiteCollection(siteCollection.Id); sc.MaxSiteStorage = realMaxSizeValue; sc.WarningStorage = realMaxSizeValue == -1 ? -1 : warningStorage; PackageController.UpdatePackageItem(sc); @@ -933,11 +933,11 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint HostedSharePointServerEnt hostedSharePointServer = GetHostedSharePointServer(serviceId); - List currentOrgSiteCollection = - GetOrganizationSharePointSiteCollections(org.Id); + List currentOrgSiteCollection = + GetOrganizationSharePointEnterpriseSiteCollections(org.Id); List urls = new List(); - foreach (SharePointSiteCollection siteCollection in currentOrgSiteCollection) + foreach (SharePointEnterpriseSiteCollection siteCollection in currentOrgSiteCollection) { urls.Add(siteCollection.PhysicalAddress); } @@ -981,7 +981,7 @@ namespace WebsitePanel.EnterpriseServer.Code.SharePoint HostedSharePointServerEnt hostedSharePointServer = GetHostedSharePointServer(serviceId); - SharePointSiteCollection sc = GetSiteCollection(siteCollectionId); + SharePointEnterpriseSiteCollection sc = GetSiteCollection(siteCollectionId); int maxSize = RecalculateMaxSize(org.MaxSharePointEnterpriseStorage, maxStorage); int warningSize = warningStorage; diff --git a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/esHostedSharePointServersEnt.asmx.cs b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/esHostedSharePointServersEnt.asmx.cs index 3837ca4c..37c62963 100644 --- a/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/esHostedSharePointServersEnt.asmx.cs +++ b/WebsitePanel/Sources/WebsitePanel.EnterpriseServer/esHostedSharePointServersEnt.asmx.cs @@ -58,7 +58,7 @@ namespace WebsitePanel.EnterpriseServer /// Resource group name. /// Site collections in raw format. [WebMethod] - public SharePointSiteCollectionListPaged Enterprise_GetSiteCollectionsPaged(int packageId, int organizationId, + public SharePointEnterpriseSiteCollectionListPaged Enterprise_GetSiteCollectionsPaged(int packageId, int organizationId, string filterColumn, string filterValue, string sortColumn, int startRow, int maximumRows) { return HostedSharePointServerEntController.GetSiteCollectionsPaged(packageId, organizationId, filterColumn, filterValue, @@ -83,7 +83,7 @@ namespace WebsitePanel.EnterpriseServer /// Resource group name. /// List of found site collections. [WebMethod] - public List Enterprise_GetSiteCollections(int packageId, bool recursive) + public List Enterprise_GetSiteCollections(int packageId, bool recursive) { return HostedSharePointServerEntController.GetSiteCollections(packageId, recursive); } @@ -100,7 +100,7 @@ namespace WebsitePanel.EnterpriseServer /// Site collection id within metabase. /// Site collection. [WebMethod] - public SharePointSiteCollection Enterprise_GetSiteCollection(int itemId) + public SharePointEnterpriseSiteCollection Enterprise_GetSiteCollection(int itemId) { return HostedSharePointServerEntController.GetSiteCollection(itemId); } @@ -113,11 +113,11 @@ namespace WebsitePanel.EnterpriseServer /// Domain name. /// SharePoint site collection or null. [WebMethod] - public SharePointSiteCollection Enterprise_GetSiteCollectionByDomain(int organizationId, string domain) + public SharePointEnterpriseSiteCollection Enterprise_GetSiteCollectionByDomain(int organizationId, string domain) { DomainInfo domainInfo = ServerController.GetDomain(domain); - SharePointSiteCollectionListPaged existentSiteCollections = this.Enterprise_GetSiteCollectionsPaged(domainInfo.PackageId, organizationId, "ItemName", String.Format("%{0}", domain), String.Empty, 0, Int32.MaxValue); - foreach (SharePointSiteCollection existentSiteCollection in existentSiteCollections.SiteCollections) + SharePointEnterpriseSiteCollectionListPaged existentSiteCollections = this.Enterprise_GetSiteCollectionsPaged(domainInfo.PackageId, organizationId, "ItemName", String.Format("%{0}", domain), String.Empty, 0, Int32.MaxValue); + foreach (SharePointEnterpriseSiteCollection existentSiteCollection in existentSiteCollections.SiteCollections) { Uri existentSiteCollectionUri = new Uri(existentSiteCollection.Name); if (existentSiteCollection.Name == String.Format("{0}://{1}", existentSiteCollectionUri.Scheme, domain)) @@ -133,10 +133,9 @@ namespace WebsitePanel.EnterpriseServer /// Adds SharePoint site collection. /// /// Site collection description. - /// Resource group name. /// Created site collection id within metabase. [WebMethod] - public int Enterprise_AddSiteCollection(SharePointSiteCollection item) + public int Enterprise_AddSiteCollection(SharePointEnterpriseSiteCollection item) { return HostedSharePointServerEntController.AddSiteCollection(item); } diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/Organization.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/Organization.cs index f88314b1..23ea8636 100644 --- a/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/Organization.cs +++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/Organization.cs @@ -83,6 +83,7 @@ namespace WebsitePanel.Providers.HostedSolution set { warningSharePointStorage = value; } } + [Persistent] public int MaxSharePointEnterpriseStorage { get { return maxSharePointEnterpriseStorage; } diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/SharePointStatisticsEnterprise.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/SharePointEntetpriseStatistics.cs similarity index 100% rename from WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/SharePointStatisticsEnterprise.cs rename to WebsitePanel/Sources/WebsitePanel.Providers.Base/HostedSolution/SharePointEntetpriseStatistics.cs diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/SharePoint/IHostedSharePointServerEnt.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/SharePoint/IHostedSharePointServerEnt.cs index 4bc6f8ee..55b1d2e9 100644 --- a/WebsitePanel/Sources/WebsitePanel.Providers.Base/SharePoint/IHostedSharePointServerEnt.cs +++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/SharePoint/IHostedSharePointServerEnt.cs @@ -54,26 +54,26 @@ namespace WebsitePanel.Providers.SharePoint /// When implemented gets list of SharePoint collections within root web application. /// /// List of SharePoint collections within root web application. - SharePointSiteCollection[] Enterprise_GetSiteCollections(); + SharePointEnterpriseSiteCollection[] Enterprise_GetSiteCollections(); /// /// When implemented gets SharePoint collection within root web application with given name. /// /// Url that uniquely identifies site collection to be loaded. /// SharePoint collection within root web application with given name. - SharePointSiteCollection Enterprise_GetSiteCollection(string url); + SharePointEnterpriseSiteCollection Enterprise_GetSiteCollection(string url); /// /// When implemented creates site collection within predefined root web application. /// /// Information about site coolection to be created. - void Enterprise_CreateSiteCollection(SharePointSiteCollection siteCollection); + void Enterprise_CreateSiteCollection(SharePointEnterpriseSiteCollection siteCollection); /// /// When implemented deletes site collection under given url. /// /// Url that uniquely identifies site collection to be deleted. - void Enterprise_DeleteSiteCollection(SharePointSiteCollection siteCollection); + void Enterprise_DeleteSiteCollection(SharePointEnterpriseSiteCollection siteCollection); /// /// When implemeneted backups site collection under give url. @@ -89,7 +89,7 @@ namespace WebsitePanel.Providers.SharePoint /// /// Site collection to be restored. /// Backup file name to restore from. - void Enterprise_RestoreSiteCollection(SharePointSiteCollection siteCollection, string filename); + void Enterprise_RestoreSiteCollection(SharePointEnterpriseSiteCollection siteCollection, string filename); /// /// When implemented gets binary data chunk of specified size from specified offset. diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/SharePoint/SharePointEnterpriseSiteCollection.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/SharePoint/SharePointEnterpriseSiteCollection.cs new file mode 100644 index 00000000..7230f123 --- /dev/null +++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/SharePoint/SharePointEnterpriseSiteCollection.cs @@ -0,0 +1,298 @@ +// Copyright (c) 2015, Outercurve Foundation. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without modification, +// are permitted provided that the following conditions are met: +// +// - Redistributions of source code must retain the above copyright notice, this +// list of conditions and the following disclaimer. +// +// - Redistributions in binary form must reproduce the above copyright notice, +// this list of conditions and the following disclaimer in the documentation +// and/or other materials provided with the distribution. +// +// - Neither the name of the Outercurve Foundation nor the names of its +// contributors may be used to endorse or promote products derived from this +// software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR +// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +using System; +using System.Collections.Generic; +using System.Text; + +namespace WebsitePanel.Providers.SharePoint +{ + /// + /// Represents SharePoint site collection information. + /// + [Serializable] + public class SharePointEnterpriseSiteCollection : ServiceProviderItem + { + private int organizationId; + private string url; + private string physicalAddress; + private string ownerLogin; + private string ownerName; + private string ownerEmail; + private int localeId; + private string title; + private string description; + private long bandwidth; + private long diskspace; + private long maxSiteStorage; + private long warningStorage; + private string rootWebApplicationInteralIpAddress; + private string rootWebApplicationFQDN; + + + + [Persistent] + public long MaxSiteStorage + { + get { return maxSiteStorage; } + set { maxSiteStorage = value; } + } + + [Persistent] + public long WarningStorage + { + get { return warningStorage; } + set { warningStorage = value; } + } + + /// + /// Gets or sets service item name. + /// + public override string Name + { + get + { + return this.Url; + } + set + { + this.Url = value; + } + } + + /// + /// Gets or sets id of organization which owns this site collection. + /// + [Persistent] + public int OrganizationId + { + get + { + return this.organizationId; + } + set + { + this.organizationId = value; + } + } + + /// + /// Gets or sets url of the host named site collection to be created. It must not contain port number. + /// + [Persistent] + public string Url + { + get + { + return this.url; + } + set + { + this.url = value; + } + } + + /// + /// Gets or sets physical address of the host named site collection. It contains scheme and port number. + /// + [Persistent] + public string PhysicalAddress + { + get + { + return this.physicalAddress; + } + set + { + this.physicalAddress = value; + } + } + + /// + /// Gets or sets login name of the site collection's owner/primary site administrator. + /// + [Persistent] + public string OwnerLogin + { + get + { + return this.ownerLogin; + } + set + { + this.ownerLogin = value; + } + } + + /// + /// Gets or sets display name of the site collection's owner/primary site administrator. + /// + [Persistent] + public string OwnerName + { + get + { + return this.ownerName; + } + set + { + this.ownerName = value; + } + } + + /// + /// Gets or sets display email of the site collection's owner/primary site administrator. + /// + [Persistent] + public string OwnerEmail + { + get + { + return this.ownerEmail; + } + set + { + this.ownerEmail = value; + } + } + + /// + /// Gets or sets the internal ip address + /// + [Persistent] + public string RootWebApplicationInteralIpAddress + { + get + { + return this.rootWebApplicationInteralIpAddress; + } + set + { + this.rootWebApplicationInteralIpAddress = value; + } + } + + /// + /// Gets or sets the internal ip address + /// + [Persistent] + public string RootWebApplicationFQDN + { + get + { + return this.rootWebApplicationFQDN; + } + set + { + this.rootWebApplicationFQDN = value; + } + } + + + /// + /// Gets or sets locale id of the site collection to be created. + /// + [Persistent] + public int LocaleId + { + get + { + return this.localeId; + } + set + { + this.localeId = value; + } + } + + /// + /// Gets or sets title of the the site collection to be created. + /// + [Persistent] + public string Title + { + get + { + return this.title; + } + set + { + this.title = value; + } + } + + /// + /// Gets or sets description of the the site collection to be created. + /// + [Persistent] + public string Description + { + get + { + return this.description; + } + set + { + this.description = value; + } + } + + /// + /// Gets or sets bandwidth of the the site collection. + /// + [Persistent] + public long Bandwidth + { + get + { + return this.bandwidth; + } + set + { + this.bandwidth = value; + } + } + + /// + /// Gets or sets diskspace of the the site collection. + /// + [Persistent] + public long Diskspace + { + get + { + return this.diskspace; + } + set + { + this.diskspace = value; + } + } + + } +} diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/SharePoint/SharePointEnterpriseSiteCollectionListPaged.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/SharePoint/SharePointEnterpriseSiteCollectionListPaged.cs new file mode 100644 index 00000000..38ee5996 --- /dev/null +++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/SharePoint/SharePointEnterpriseSiteCollectionListPaged.cs @@ -0,0 +1,71 @@ +// Copyright (c) 2015, Outercurve Foundation. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without modification, +// are permitted provided that the following conditions are met: +// +// - Redistributions of source code must retain the above copyright notice, this +// list of conditions and the following disclaimer. +// +// - Redistributions in binary form must reproduce the above copyright notice, +// this list of conditions and the following disclaimer in the documentation +// and/or other materials provided with the distribution. +// +// - Neither the name of the Outercurve Foundation nor the names of its +// contributors may be used to endorse or promote products derived from this +// software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR +// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +using System; +using System.Collections.Generic; +using System.Text; + +namespace WebsitePanel.Providers.SharePoint +{ + [Serializable] + public class SharePointEnterpriseSiteCollectionListPaged + { + private int totalRowCount; + private List siteCollections; + + /// + /// Gets or sets total row count in persistent storage. + /// + public int TotalRowCount + { + get + { + return this.totalRowCount; + } + set + { + this.totalRowCount = value; + } + } + + /// + /// Gets or sets list of site collections on a single page. + /// + public List SiteCollections + { + get + { + return this.siteCollections; + } + set + { + this.siteCollections = value; + } + } + } +} diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/SharePoint/SharePointEnterpriseSiteDiskSpace.cs b/WebsitePanel/Sources/WebsitePanel.Providers.Base/SharePoint/SharePointEnterpriseSiteDiskSpace.cs new file mode 100644 index 00000000..a734327b --- /dev/null +++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/SharePoint/SharePointEnterpriseSiteDiskSpace.cs @@ -0,0 +1,52 @@ +// Copyright (c) 2015, Outercurve Foundation. +// All rights reserved. +// +// Redistribution and use in source and binary forms, with or without modification, +// are permitted provided that the following conditions are met: +// +// - Redistributions of source code must retain the above copyright notice, this +// list of conditions and the following disclaimer. +// +// - Redistributions in binary form must reproduce the above copyright notice, +// this list of conditions and the following disclaimer in the documentation +// and/or other materials provided with the distribution. +// +// - Neither the name of the Outercurve Foundation nor the names of its +// contributors may be used to endorse or promote products derived from this +// software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR +// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +using System; + +namespace WebsitePanel.Providers.SharePoint +{ + [Serializable] + public class SharePointEnterpriseSiteDiskSpace + { + private string url; + private long diskSpace; + + + public string Url + { + get { return url; } + set { url = value; } + } + + public long DiskSpace + { + get { return diskSpace; } + set { diskSpace = value; } + } + } +} diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.Base/WebsitePanel.Providers.Base.csproj b/WebsitePanel/Sources/WebsitePanel.Providers.Base/WebsitePanel.Providers.Base.csproj index 90bec626..7b34bc85 100644 --- a/WebsitePanel/Sources/WebsitePanel.Providers.Base/WebsitePanel.Providers.Base.csproj +++ b/WebsitePanel/Sources/WebsitePanel.Providers.Base/WebsitePanel.Providers.Base.csproj @@ -123,7 +123,7 @@ - + @@ -286,8 +286,11 @@ + + + diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution.SharePoint2013Ent/HostedSharePointServer2013Ent.cs b/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution.SharePoint2013Ent/HostedSharePointServer2013Ent.cs index d9e93497..1bc80759 100644 --- a/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution.SharePoint2013Ent/HostedSharePointServer2013Ent.cs +++ b/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution.SharePoint2013Ent/HostedSharePointServer2013Ent.cs @@ -94,7 +94,7 @@ namespace WebsitePanel.Providers.HostedSolution /// Gets list of SharePoint collections within root web application. /// List of SharePoint collections within root web application. - public SharePointSiteCollection[] Enterprise_GetSiteCollections() + public SharePointEnterpriseSiteCollection[] Enterprise_GetSiteCollections() { return ExecuteSharePointAction(impl => impl.GetSiteCollections(Enterprise_RootWebApplicationUri)); } @@ -102,14 +102,14 @@ namespace WebsitePanel.Providers.HostedSolution /// Gets SharePoint collection within root web application with given name. /// Url that uniquely identifies site collection to be loaded. /// SharePoint collection within root web application with given name. - public SharePointSiteCollection Enterprise_GetSiteCollection(string url) + public SharePointEnterpriseSiteCollection Enterprise_GetSiteCollection(string url) { return ExecuteSharePointAction(impl => impl.GetSiteCollection(Enterprise_RootWebApplicationUri, url)); } /// Creates site collection within predefined root web application. /// Information about site coolection to be created. - public void Enterprise_CreateSiteCollection(SharePointSiteCollection siteCollection) + public void Enterprise_CreateSiteCollection(SharePointEnterpriseSiteCollection siteCollection) { ExecuteSharePointAction(delegate(HostedSharePointServer2013EntImpl impl) { @@ -120,7 +120,7 @@ namespace WebsitePanel.Providers.HostedSolution /// Deletes site collection under given url. /// The site collection to be deleted. - public void Enterprise_DeleteSiteCollection(SharePointSiteCollection siteCollection) + public void Enterprise_DeleteSiteCollection(SharePointEnterpriseSiteCollection siteCollection) { ExecuteSharePointAction(delegate(HostedSharePointServer2013EntImpl impl) { @@ -142,7 +142,7 @@ namespace WebsitePanel.Providers.HostedSolution /// Restores site collection under given url from backup. /// Site collection to be restored. /// Backup file name to restore from. - public void Enterprise_RestoreSiteCollection(SharePointSiteCollection siteCollection, string filename) + public void Enterprise_RestoreSiteCollection(SharePointEnterpriseSiteCollection siteCollection, string filename) { ExecuteSharePointAction(delegate(HostedSharePointServer2013EntImpl impl) { @@ -229,13 +229,13 @@ namespace WebsitePanel.Providers.HostedSolution { foreach (ServiceProviderItem item in items) { - var sharePointSiteCollection = item as SharePointSiteCollection; + var SharePointEnterpriseSiteCollection = item as SharePointEnterpriseSiteCollection; - if (sharePointSiteCollection != null) + if (SharePointEnterpriseSiteCollection != null) { try { - Enterprise_DeleteSiteCollection(sharePointSiteCollection); + Enterprise_DeleteSiteCollection(SharePointEnterpriseSiteCollection); } catch (Exception ex) { @@ -254,13 +254,13 @@ namespace WebsitePanel.Providers.HostedSolution foreach (ServiceProviderItem item in items) { - if (item is SharePointSiteCollection) + if (item is SharePointEnterpriseSiteCollection) { try { Log.WriteStart(String.Format("Calculating '{0}' site logs size", item.Name)); - SharePointSiteCollection site = Enterprise_GetSiteCollection(item.Name); + SharePointEnterpriseSiteCollection site = Enterprise_GetSiteCollection(item.Name); var diskspace = new ServiceProviderItemDiskSpace { ItemId = item.Id, DiskSpace = site.Diskspace }; itemsDiskspace.Add(diskspace); diff --git a/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution.SharePoint2013Ent/HostedSharePointServer2013EntImpl.cs b/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution.SharePoint2013Ent/HostedSharePointServer2013EntImpl.cs index ce92d7b2..04e39834 100644 --- a/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution.SharePoint2013Ent/HostedSharePointServer2013EntImpl.cs +++ b/WebsitePanel/Sources/WebsitePanel.Providers.HostedSolution.SharePoint2013Ent/HostedSharePointServer2013EntImpl.cs @@ -63,7 +63,7 @@ namespace WebsitePanel.Providers.HostedSolution /// Gets list of SharePoint collections within root web application. /// The root web application Uri. /// List of SharePoint collections within root web application. - public SharePointSiteCollection[] GetSiteCollections(Uri rootWebApplicationUri) + public SharePointEnterpriseSiteCollection[] GetSiteCollections(Uri rootWebApplicationUri) { return GetSPSiteCollections(rootWebApplicationUri).Select(pair => NewSiteCollection(pair.Value)).ToArray(); } @@ -185,7 +185,7 @@ namespace WebsitePanel.Providers.HostedSolution /// Root web application uri. /// Url that uniquely identifies site collection to be loaded. /// SharePoint collection within root web application with given name. - public SharePointSiteCollection GetSiteCollection(Uri rootWebApplicationUri, string url) + public SharePointEnterpriseSiteCollection GetSiteCollection(Uri rootWebApplicationUri, string url) { return NewSiteCollection(GetSPSiteCollection(rootWebApplicationUri, url)); } @@ -269,7 +269,7 @@ namespace WebsitePanel.Providers.HostedSolution /// Root web application uri. /// Information about site coolection to be created. /// Is thrown in case requested operation fails for any reason. - public void CreateSiteCollection(Uri rootWebApplicationUri, SharePointSiteCollection siteCollection) + public void CreateSiteCollection(Uri rootWebApplicationUri, SharePointEnterpriseSiteCollection siteCollection) { HostedSolutionLog.LogStart("CreateSiteCollection"); WindowsImpersonationContext wic = null; @@ -298,7 +298,7 @@ namespace WebsitePanel.Providers.HostedSolution /// Root web application uri. /// Information about site coolection to be created. /// Is thrown in case requested operation fails for any reason. - private void CreateCollection(Runspace runspace, Uri rootWebApplicationUri, SharePointSiteCollection siteCollection) + private void CreateCollection(Runspace runspace, Uri rootWebApplicationUri, SharePointEnterpriseSiteCollection siteCollection) { string siteCollectionUrl = String.Format("{0}:{1}", siteCollection.Url, rootWebApplicationUri.Port); HostedSolutionLog.DebugInfo("siteCollectionUrl: {0}", siteCollectionUrl); @@ -347,7 +347,7 @@ namespace WebsitePanel.Providers.HostedSolution /// Root web application uri. /// The site collection to be deleted. /// Is thrown in case requested operation fails for any reason. - public void DeleteSiteCollection(Uri rootWebApplicationUri, SharePointSiteCollection siteCollection) + public void DeleteSiteCollection(Uri rootWebApplicationUri, SharePointEnterpriseSiteCollection siteCollection) { HostedSolutionLog.LogStart("DeleteSiteCollection"); Runspace runspace = null; @@ -434,7 +434,7 @@ namespace WebsitePanel.Providers.HostedSolution /// Site collection to be restored. /// Backup file name to restore from. /// Is thrown in case requested operation fails for any reason. - public void RestoreSiteCollection(Uri rootWebApplicationUri, SharePointSiteCollection siteCollection, string filename) + public void RestoreSiteCollection(Uri rootWebApplicationUri, SharePointEnterpriseSiteCollection siteCollection, string filename) { string url = siteCollection.Url; @@ -494,12 +494,12 @@ namespace WebsitePanel.Providers.HostedSolution /// Creates new site collection with information from administration object. /// Administration object. - private static SharePointSiteCollection NewSiteCollection(SPSite site) + private static SharePointEnterpriseSiteCollection NewSiteCollection(SPSite site) { var siteUri = new Uri(site.Url); string url = (siteUri.Port > 0) ? site.Url.Replace(String.Format(":{0}", siteUri.Port), String.Empty) : site.Url; - return new SharePointSiteCollection {Url = url, OwnerLogin = site.Owner.LoginName, OwnerName = site.Owner.Name, OwnerEmail = site.Owner.Email, LocaleId = site.RootWeb.Locale.LCID, Title = site.RootWeb.Title, Description = site.RootWeb.Description, Bandwidth = site.Usage.Bandwidth, Diskspace = site.Usage.Storage, MaxSiteStorage = site.Quota.StorageMaximumLevel, WarningStorage = site.Quota.StorageWarningLevel}; + return new SharePointEnterpriseSiteCollection {Url = url, OwnerLogin = site.Owner.LoginName, OwnerName = site.Owner.Name, OwnerEmail = site.Owner.Email, LocaleId = site.RootWeb.Locale.LCID, Title = site.RootWeb.Title, Description = site.RootWeb.Description, Bandwidth = site.Usage.Bandwidth, Diskspace = site.Usage.Storage, MaxSiteStorage = site.Quota.StorageMaximumLevel, WarningStorage = site.Quota.StorageWarningLevel}; } /// Gets SharePoint sites collection. @@ -716,7 +716,7 @@ namespace WebsitePanel.Providers.HostedSolution /// Adds record to hosts file. /// The site collection object. - public void AddHostsRecord(SharePointSiteCollection siteCollection) + public void AddHostsRecord(SharePointEnterpriseSiteCollection siteCollection) { try { @@ -783,7 +783,7 @@ namespace WebsitePanel.Providers.HostedSolution /// Removes record from hosts file. /// The site collection object. - private void RemoveHostsRecord(SharePointSiteCollection siteCollection) + private void RemoveHostsRecord(SharePointEnterpriseSiteCollection siteCollection) { try { diff --git a/WebsitePanel/Sources/WebsitePanel.Server.Client/HostedSharePointServerEntProxy.cs b/WebsitePanel/Sources/WebsitePanel.Server.Client/HostedSharePointServerEntProxy.cs index bec63849..3b465943 100644 --- a/WebsitePanel/Sources/WebsitePanel.Server.Client/HostedSharePointServerEntProxy.cs +++ b/WebsitePanel/Sources/WebsitePanel.Server.Client/HostedSharePointServerEntProxy.cs @@ -26,7 +26,6 @@ // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS // SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - //------------------------------------------------------------------------------ // // This code was generated by a tool. @@ -48,7 +47,6 @@ namespace WebsitePanel.Providers.HostedSolution { using System; using System.Diagnostics; using WebsitePanel.Providers.SharePoint; - /// @@ -173,9 +171,9 @@ namespace WebsitePanel.Providers.HostedSolution { /// [System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")] [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/server/Enterprise_GetSiteCollections", RequestNamespace="http://smbsaas/websitepanel/server/", ResponseNamespace="http://smbsaas/websitepanel/server/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)] - public SharePointSiteCollection[] Enterprise_GetSiteCollections() { + public SharePointEnterpriseSiteCollection[] Enterprise_GetSiteCollections() { object[] results = this.Invoke("Enterprise_GetSiteCollections", new object[0]); - return ((SharePointSiteCollection[])(results[0])); + return ((SharePointEnterpriseSiteCollection[])(results[0])); } /// @@ -184,9 +182,9 @@ namespace WebsitePanel.Providers.HostedSolution { } /// - public SharePointSiteCollection[] EndEnterprise_GetSiteCollections(System.IAsyncResult asyncResult) { + public SharePointEnterpriseSiteCollection[] EndEnterprise_GetSiteCollections(System.IAsyncResult asyncResult) { object[] results = this.EndInvoke(asyncResult); - return ((SharePointSiteCollection[])(results[0])); + return ((SharePointEnterpriseSiteCollection[])(results[0])); } /// @@ -212,10 +210,10 @@ namespace WebsitePanel.Providers.HostedSolution { /// [System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")] [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/server/Enterprise_GetSiteCollection", RequestNamespace="http://smbsaas/websitepanel/server/", ResponseNamespace="http://smbsaas/websitepanel/server/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)] - public SharePointSiteCollection Enterprise_GetSiteCollection(string url) { + public SharePointEnterpriseSiteCollection Enterprise_GetSiteCollection(string url) { object[] results = this.Invoke("Enterprise_GetSiteCollection", new object[] { url}); - return ((SharePointSiteCollection)(results[0])); + return ((SharePointEnterpriseSiteCollection)(results[0])); } /// @@ -225,9 +223,9 @@ namespace WebsitePanel.Providers.HostedSolution { } /// - public SharePointSiteCollection EndEnterprise_GetSiteCollection(System.IAsyncResult asyncResult) { + public SharePointEnterpriseSiteCollection EndEnterprise_GetSiteCollection(System.IAsyncResult asyncResult) { object[] results = this.EndInvoke(asyncResult); - return ((SharePointSiteCollection)(results[0])); + return ((SharePointEnterpriseSiteCollection)(results[0])); } /// @@ -254,13 +252,13 @@ namespace WebsitePanel.Providers.HostedSolution { /// [System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")] [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/server/Enterprise_CreateSiteCollection", RequestNamespace="http://smbsaas/websitepanel/server/", ResponseNamespace="http://smbsaas/websitepanel/server/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)] - public void Enterprise_CreateSiteCollection(SharePointSiteCollection siteCollection) { + public void Enterprise_CreateSiteCollection(SharePointEnterpriseSiteCollection siteCollection) { this.Invoke("Enterprise_CreateSiteCollection", new object[] { siteCollection}); } /// - public System.IAsyncResult BeginEnterprise_CreateSiteCollection(SharePointSiteCollection siteCollection, System.AsyncCallback callback, object asyncState) { + public System.IAsyncResult BeginEnterprise_CreateSiteCollection(SharePointEnterpriseSiteCollection siteCollection, System.AsyncCallback callback, object asyncState) { return this.BeginInvoke("Enterprise_CreateSiteCollection", new object[] { siteCollection}, callback, asyncState); } @@ -271,12 +269,12 @@ namespace WebsitePanel.Providers.HostedSolution { } /// - public void Enterprise_CreateSiteCollectionAsync(SharePointSiteCollection siteCollection) { + public void Enterprise_CreateSiteCollectionAsync(SharePointEnterpriseSiteCollection siteCollection) { this.Enterprise_CreateSiteCollectionAsync(siteCollection, null); } /// - public void Enterprise_CreateSiteCollectionAsync(SharePointSiteCollection siteCollection, object userState) { + public void Enterprise_CreateSiteCollectionAsync(SharePointEnterpriseSiteCollection siteCollection, object userState) { if ((this.Enterprise_CreateSiteCollectionOperationCompleted == null)) { this.Enterprise_CreateSiteCollectionOperationCompleted = new System.Threading.SendOrPostCallback(this.OnEnterprise_CreateSiteCollectionOperationCompleted); } @@ -382,13 +380,13 @@ namespace WebsitePanel.Providers.HostedSolution { /// [System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")] [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/server/Enterprise_DeleteSiteCollection", RequestNamespace="http://smbsaas/websitepanel/server/", ResponseNamespace="http://smbsaas/websitepanel/server/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)] - public void Enterprise_DeleteSiteCollection(SharePointSiteCollection siteCollection) { + public void Enterprise_DeleteSiteCollection(SharePointEnterpriseSiteCollection siteCollection) { this.Invoke("Enterprise_DeleteSiteCollection", new object[] { siteCollection}); } /// - public System.IAsyncResult BeginEnterprise_DeleteSiteCollection(SharePointSiteCollection siteCollection, System.AsyncCallback callback, object asyncState) { + public System.IAsyncResult BeginEnterprise_DeleteSiteCollection(SharePointEnterpriseSiteCollection siteCollection, System.AsyncCallback callback, object asyncState) { return this.BeginInvoke("Enterprise_DeleteSiteCollection", new object[] { siteCollection}, callback, asyncState); } @@ -399,12 +397,12 @@ namespace WebsitePanel.Providers.HostedSolution { } /// - public void Enterprise_DeleteSiteCollectionAsync(SharePointSiteCollection siteCollection) { + public void Enterprise_DeleteSiteCollectionAsync(SharePointEnterpriseSiteCollection siteCollection) { this.Enterprise_DeleteSiteCollectionAsync(siteCollection, null); } /// - public void Enterprise_DeleteSiteCollectionAsync(SharePointSiteCollection siteCollection, object userState) { + public void Enterprise_DeleteSiteCollectionAsync(SharePointEnterpriseSiteCollection siteCollection, object userState) { if ((this.Enterprise_DeleteSiteCollectionOperationCompleted == null)) { this.Enterprise_DeleteSiteCollectionOperationCompleted = new System.Threading.SendOrPostCallback(this.OnEnterprise_DeleteSiteCollectionOperationCompleted); } @@ -470,14 +468,14 @@ namespace WebsitePanel.Providers.HostedSolution { /// [System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")] [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/server/Enterprise_RestoreSiteCollection", RequestNamespace="http://smbsaas/websitepanel/server/", ResponseNamespace="http://smbsaas/websitepanel/server/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)] - public void Enterprise_RestoreSiteCollection(SharePointSiteCollection siteCollection, string filename) { + public void Enterprise_RestoreSiteCollection(SharePointEnterpriseSiteCollection siteCollection, string filename) { this.Invoke("Enterprise_RestoreSiteCollection", new object[] { siteCollection, filename}); } /// - public System.IAsyncResult BeginEnterprise_RestoreSiteCollection(SharePointSiteCollection siteCollection, string filename, System.AsyncCallback callback, object asyncState) { + public System.IAsyncResult BeginEnterprise_RestoreSiteCollection(SharePointEnterpriseSiteCollection siteCollection, string filename, System.AsyncCallback callback, object asyncState) { return this.BeginInvoke("Enterprise_RestoreSiteCollection", new object[] { siteCollection, filename}, callback, asyncState); @@ -489,12 +487,12 @@ namespace WebsitePanel.Providers.HostedSolution { } /// - public void Enterprise_RestoreSiteCollectionAsync(SharePointSiteCollection siteCollection, string filename) { + public void Enterprise_RestoreSiteCollectionAsync(SharePointEnterpriseSiteCollection siteCollection, string filename) { this.Enterprise_RestoreSiteCollectionAsync(siteCollection, filename, null); } /// - public void Enterprise_RestoreSiteCollectionAsync(SharePointSiteCollection siteCollection, string filename, object userState) { + public void Enterprise_RestoreSiteCollectionAsync(SharePointEnterpriseSiteCollection siteCollection, string filename, object userState) { if ((this.Enterprise_RestoreSiteCollectionOperationCompleted == null)) { this.Enterprise_RestoreSiteCollectionOperationCompleted = new System.Threading.SendOrPostCallback(this.OnEnterprise_RestoreSiteCollectionOperationCompleted); } @@ -742,10 +740,10 @@ namespace WebsitePanel.Providers.HostedSolution { } /// - public SharePointSiteCollection[] Result { + public SharePointEnterpriseSiteCollection[] Result { get { this.RaiseExceptionIfNecessary(); - return ((SharePointSiteCollection[])(this.results[0])); + return ((SharePointEnterpriseSiteCollection[])(this.results[0])); } } } @@ -768,10 +766,10 @@ namespace WebsitePanel.Providers.HostedSolution { } /// - public SharePointSiteCollection Result { + public SharePointEnterpriseSiteCollection Result { get { this.RaiseExceptionIfNecessary(); - return ((SharePointSiteCollection)(this.results[0])); + return ((SharePointEnterpriseSiteCollection)(this.results[0])); } } } diff --git a/WebsitePanel/Sources/WebsitePanel.Server/HostedSharePointServerEnt.asmx.cs b/WebsitePanel/Sources/WebsitePanel.Server/HostedSharePointServerEnt.asmx.cs index 778e17c0..732ddf55 100644 --- a/WebsitePanel/Sources/WebsitePanel.Server/HostedSharePointServerEnt.asmx.cs +++ b/WebsitePanel/Sources/WebsitePanel.Server/HostedSharePointServerEnt.asmx.cs @@ -76,9 +76,9 @@ namespace WebsitePanel.Server /// /// List of SharePoint collections within root web application. [WebMethod, SoapHeader("settings")] - public SharePointSiteCollection[] Enterprise_GetSiteCollections() + public SharePointEnterpriseSiteCollection[] Enterprise_GetSiteCollections() { - return ExecuteAction(delegate + return ExecuteAction(delegate { return HostedSharePointServerEntProvider.Enterprise_GetSiteCollections(); }, "GetSiteCollections"); @@ -90,9 +90,9 @@ namespace WebsitePanel.Server /// Url that uniquely identifies site collection to be loaded. /// SharePoint collection within root web application with given name. [WebMethod, SoapHeader("settings")] - public SharePointSiteCollection Enterprise_GetSiteCollection(string url) + public SharePointEnterpriseSiteCollection Enterprise_GetSiteCollection(string url) { - return ExecuteAction(delegate + return ExecuteAction(delegate { return HostedSharePointServerEntProvider.Enterprise_GetSiteCollection(url); }, "GetSiteCollection"); @@ -103,7 +103,7 @@ namespace WebsitePanel.Server /// /// Information about site coolection to be created. [WebMethod, SoapHeader("settings")] - public void Enterprise_CreateSiteCollection(SharePointSiteCollection siteCollection) + public void Enterprise_CreateSiteCollection(SharePointEnterpriseSiteCollection siteCollection) { siteCollection.OwnerLogin = AttachNetbiosDomainName(siteCollection.OwnerLogin); ExecuteAction(delegate @@ -143,7 +143,7 @@ namespace WebsitePanel.Server /// /// Url that uniquely identifies site collection to be deleted. [WebMethod, SoapHeader("settings")] - public void Enterprise_DeleteSiteCollection(SharePointSiteCollection siteCollection) + public void Enterprise_DeleteSiteCollection(SharePointEnterpriseSiteCollection siteCollection) { ExecuteAction(delegate { @@ -174,7 +174,7 @@ namespace WebsitePanel.Server /// Site collection to be restored. /// Backup file name to restore from. [WebMethod, SoapHeader("settings")] - public void Enterprise_RestoreSiteCollection(SharePointSiteCollection siteCollection, string filename) + public void Enterprise_RestoreSiteCollection(SharePointEnterpriseSiteCollection siteCollection, string filename) { siteCollection.OwnerLogin = AttachNetbiosDomainName(siteCollection.OwnerLogin); ExecuteAction(delegate diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/App_Data/WebsitePanel_Modules.config b/WebsitePanel/Sources/WebsitePanel.WebPortal/App_Data/WebsitePanel_Modules.config index 1bd0de2e..7734d3d6 100644 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/App_Data/WebsitePanel_Modules.config +++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/App_Data/WebsitePanel_Modules.config @@ -542,20 +542,20 @@ - - - - - - + + + + + + - - - - - - + + + + + + diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEditSiteCollection.ascx.resx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEditSiteCollection.ascx.resx deleted file mode 100644 index 856828c3..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEditSiteCollection.ascx.resx +++ /dev/null @@ -1,207 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - Backup Site Collection - - - Cancel - - - ShowProgressDialog('Deleting SharePoint site collection...'); - - - Delete - - - Restore Site Collection - - - ShowProgressDialog('Updating SharePoint site collection...'); - - - Update - - - <p>Here you can create new SharePoint site collection. Choose URL from the list of domains you already own. Site URL like team.yourcompany.com should be added as domain in “Domain names” organization’s menu before SharePoint site collection creation.</p> - -<p><b>Site owner</b> is member of your organization who will be responsible for this SharePoint site collection administration: choosing site templates, adding other users, creating sub-sites.</p> - -<p><b>Locale ID</b> defines your site language and can not be changed after site creation. However child sub sites can use another Locale IDs.</p> - -<p>Title will be visible in site header.</p> - -<p><b>Description</b> will be visible when you open site on the top of the main site page.</p> - -<p>After you create this site open it using owner login, and do at least 2 main steps: -1. Choose site template -2. Define who will be able to access this site. To add user from your hosted organization to SharePoint site, please copy/paste his or her e-mail from user's properties in WebsitePanel to SharePoint site collection’s Users/Groups field.</p> - - - Email - - - User Name - - - Description: - - - Locale ID: - - - Owner: - - - Url: - - - Title: - - - Send warning E-mail when site storage reaches (MB): - - - Full list of locales - - - SharePoint Site Collection - - - SharePoint Site Collection Tools - - - Add Site Collection - - - Edit SharePoint Site Collection - - - Update - - - Maximum site storage size (MB): - - - Do not send - - - ShowProgressDialog('Creating SharePoint site collection...'); - - \ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEnterpriseBackupSiteCollection.ascx.resx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEnterpriseBackupSiteCollection.ascx.resx deleted file mode 100644 index c931ca06..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEnterpriseBackupSiteCollection.ascx.resx +++ /dev/null @@ -1,153 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - Backup - - - Cancel - - - ZIP Backup - - - <p>The backup file that you create includes list or library content, security settings, user information, navigation, customizations, and personalizations (such as views, site templates, and content types). The backup file does not include workflows, alerts, and properties stored at the site collection level.</p> - - - Backup Destination: - - - Backup File Name: - - - Backup Options: - - - Backup SharePoint Site Collection - - - Copy to Folder - - - Download via HTTP - - - Backup SharePoint Site Collection - - \ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEnterpriseEditSiteCollection.ascx.resx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEnterpriseEditSiteCollection.ascx.resx deleted file mode 100644 index 856828c3..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEnterpriseEditSiteCollection.ascx.resx +++ /dev/null @@ -1,207 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - Backup Site Collection - - - Cancel - - - ShowProgressDialog('Deleting SharePoint site collection...'); - - - Delete - - - Restore Site Collection - - - ShowProgressDialog('Updating SharePoint site collection...'); - - - Update - - - <p>Here you can create new SharePoint site collection. Choose URL from the list of domains you already own. Site URL like team.yourcompany.com should be added as domain in “Domain names” organization’s menu before SharePoint site collection creation.</p> - -<p><b>Site owner</b> is member of your organization who will be responsible for this SharePoint site collection administration: choosing site templates, adding other users, creating sub-sites.</p> - -<p><b>Locale ID</b> defines your site language and can not be changed after site creation. However child sub sites can use another Locale IDs.</p> - -<p>Title will be visible in site header.</p> - -<p><b>Description</b> will be visible when you open site on the top of the main site page.</p> - -<p>After you create this site open it using owner login, and do at least 2 main steps: -1. Choose site template -2. Define who will be able to access this site. To add user from your hosted organization to SharePoint site, please copy/paste his or her e-mail from user's properties in WebsitePanel to SharePoint site collection’s Users/Groups field.</p> - - - Email - - - User Name - - - Description: - - - Locale ID: - - - Owner: - - - Url: - - - Title: - - - Send warning E-mail when site storage reaches (MB): - - - Full list of locales - - - SharePoint Site Collection - - - SharePoint Site Collection Tools - - - Add Site Collection - - - Edit SharePoint Site Collection - - - Update - - - Maximum site storage size (MB): - - - Do not send - - - ShowProgressDialog('Creating SharePoint site collection...'); - - \ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEnterpriseRestoreSiteCollection.ascx.resx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEnterpriseRestoreSiteCollection.ascx.resx deleted file mode 100644 index 06164c47..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEnterpriseRestoreSiteCollection.ascx.resx +++ /dev/null @@ -1,150 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - Cancel - - - ShowProgressDialog('Restoring SharePoint site collection...'); - - - Restore - - - <p>After site collection is restored it will have primary administrator assigned to it as it was before restoration (primary administrator record from backup is ignored).</p> - - - .ZIP, .BAK files are allowed - - - Restore From: - - - Restore SharePoint Site Collection - - - Hosting Space File - - - Uploaded File - - - Restore SharePoint Site Collection - - \ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEnterpriseSiteCollections.ascx.resx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEnterpriseSiteCollections.ascx.resx deleted file mode 100644 index 224fd542..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEnterpriseSiteCollections.ascx.resx +++ /dev/null @@ -1,153 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - Add SharePoint Enterprise Site Collection - - - Create New Site Collection - - - Delete - - - Url - - - <p><b>SharePoint site collection</b> is a group of sites built on Microsoft Windows SharePoint Services that all exist under a top-level site. To make managing the sites and their content more convenient, you can assign users to be site collection administrators or site collection owners. These are permission levels to give to users who you want to have full administrative rights to all sites and content within a site collection.</p> - - - Owner - - - No SharePoint site collections have been created. To create a SharePoint site collection click "Create New Site Collection" button. - - - Site Collection Url - - - Total Site Collections Created: - - - SharePoint Enterprise Site Collections - - - SharePoint Enterprise Site Collections - - \ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEnterpriseStorageSettings.ascx.resx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEnterpriseStorageSettings.ascx.resx deleted file mode 100644 index 062e04df..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEnterpriseStorageSettings.ascx.resx +++ /dev/null @@ -1,154 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - Save - - - Save and Apply to All Site Collections - - - <p>Storage settings are used to limit the amount of storage available on a SharePoint site collection, and they are used to send e-mail alerts to the site administrator when a specified value of space is used.</p> - -<p>These settings will be applied to the new site collections only. By clicking "Save and Apply to All Site Collections" button you can override these settings for all existing site collections.</p> - -<p>Please note, that you cannot specify storage settings higher than defined in the space hosting plan.</p> - - - Maximum site storage size (MB): - - - Send warning E-mail when site storage reaches (MB): - - - Storage Settings - - - Storage Settings - - - Storage Settings - - - Don't use - - - Do not send - - \ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEnterpriseStorageUsage.ascx.resx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEnterpriseStorageUsage.ascx.resx deleted file mode 100644 index b945ab03..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointEnterpriseStorageUsage.ascx.resx +++ /dev/null @@ -1,150 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - Recalculate Disk Space - - - <p>SharePoint disk space usage is calculated on timely basis (usually once a day). You can recalculate it right now by clicking "Recalculate Disk Space" button.</p> - - - Site Collection - - - Total Size, MB - - - There are no site collections - - - Storage Usage - - - Site Collections - - - Storage Usage - - - Total Size (MB): - - - Total Items: - - \ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointRestoreSiteCollection.ascx.resx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointRestoreSiteCollection.ascx.resx deleted file mode 100644 index 06164c47..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointRestoreSiteCollection.ascx.resx +++ /dev/null @@ -1,150 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - Cancel - - - ShowProgressDialog('Restoring SharePoint site collection...'); - - - Restore - - - <p>After site collection is restored it will have primary administrator assigned to it as it was before restoration (primary administrator record from backup is ignored).</p> - - - .ZIP, .BAK files are allowed - - - Restore From: - - - Restore SharePoint Site Collection - - - Hosting Space File - - - Uploaded File - - - Restore SharePoint Site Collection - - \ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointSiteCollections.ascx.resx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointSiteCollections.ascx.resx deleted file mode 100644 index 44c0004a..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointSiteCollections.ascx.resx +++ /dev/null @@ -1,153 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - Add SharePoint Site Collection - - - Create New Site Collection - - - Delete - - - Url - - - <p><b>SharePoint site collection</b> is a group of sites built on Microsoft Windows SharePoint Services that all exist under a top-level site. To make managing the sites and their content more convenient, you can assign users to be site collection administrators or site collection owners. These are permission levels to give to users who you want to have full administrative rights to all sites and content within a site collection.</p> - - - Owner - - - No SharePoint site collections have been created. To create a SharePoint site collection click "Create New Site Collection" button. - - - Site Collection Url - - - Total Site Collections Created: - - - SharePoint Site Collections - - - SharePoint Site Collections - - \ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointStorageSettings.ascx.resx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointStorageSettings.ascx.resx deleted file mode 100644 index 062e04df..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointStorageSettings.ascx.resx +++ /dev/null @@ -1,154 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - Save - - - Save and Apply to All Site Collections - - - <p>Storage settings are used to limit the amount of storage available on a SharePoint site collection, and they are used to send e-mail alerts to the site administrator when a specified value of space is used.</p> - -<p>These settings will be applied to the new site collections only. By clicking "Save and Apply to All Site Collections" button you can override these settings for all existing site collections.</p> - -<p>Please note, that you cannot specify storage settings higher than defined in the space hosting plan.</p> - - - Maximum site storage size (MB): - - - Send warning E-mail when site storage reaches (MB): - - - Storage Settings - - - Storage Settings - - - Storage Settings - - - Don't use - - - Do not send - - \ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointStorageUsage.ascx.resx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointStorageUsage.ascx.resx deleted file mode 100644 index b945ab03..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointStorageUsage.ascx.resx +++ /dev/null @@ -1,150 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - Recalculate Disk Space - - - <p>SharePoint disk space usage is calculated on timely basis (usually once a day). You can recalculate it right now by clicking "Recalculate Disk Space" button.</p> - - - Site Collection - - - Total Size, MB - - - There are no site collections - - - Storage Usage - - - Site Collections - - - Storage Usage - - - Total Size (MB): - - - Total Items: - - \ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/SpaceQuotas.ascx.resx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/SpaceQuotas.ascx.resx index fc627511..a03b66d5 100644 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/SpaceQuotas.ascx.resx +++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/SpaceQuotas.ascx.resx @@ -181,7 +181,7 @@ OCS Users: - Sharepoint Sites: + SharePoint Foundation Sites: User Accounts: @@ -210,4 +210,7 @@ Deleted Users: + + SharePoint Enterprise Sites: + \ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/Code/Helpers/HostedSharePointEnterpriseSiteCollectionsHelper.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/Code/Helpers/HostedSharePointEnterpriseSiteCollectionsHelper.cs index cd46de49..5ed1105a 100644 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/Code/Helpers/HostedSharePointEnterpriseSiteCollectionsHelper.cs +++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/Code/Helpers/HostedSharePointEnterpriseSiteCollectionsHelper.cs @@ -42,14 +42,16 @@ namespace WebsitePanel.Portal { public class HostedSharePointEnterpriseSiteCollectionsHelper { - SharePointSiteCollectionListPaged result; + SharePointEnterpriseSiteCollectionListPaged result; - public int GetSharePointSiteCollectionPagedCount(int packageId, int organizationId, string filterColumn, string filterValue) + public int GetSharePointEnterpriseSiteCollectionPagedCount(int packageId, int organizationId, string filterColumn, string filterValue) { return result.TotalRowCount; } - public List GetSharePointSiteCollectionPaged(int packageId, int organizationId, string filterColumn, string filterValue, int maximumRows, int startRowIndex, string sortColumn) + + + public List GetSharePointEnterpriseSiteCollectionPaged(int packageId, int organizationId, string filterColumn, string filterValue, int maximumRows, int startRowIndex, string sortColumn) { if (!String.IsNullOrEmpty(filterValue)) { diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointBackupSiteCollection.ascx.resx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePoint/App_LocalResources/HostedSharePointBackupSiteCollection.ascx.resx similarity index 100% rename from WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/App_LocalResources/HostedSharePointBackupSiteCollection.ascx.resx rename to WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePoint/App_LocalResources/HostedSharePointBackupSiteCollection.ascx.resx diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointBackupSiteCollection.ascx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointBackupSiteCollection.ascx deleted file mode 100644 index 6ee199ec..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointBackupSiteCollection.ascx +++ /dev/null @@ -1,80 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" Codebehind="HostedSharePointBackupSiteCollection.ascx.cs" - Inherits="WebsitePanel.Portal.HostedSharePointBackupSiteCollection" %> -<%@ Register Src="UserControls/FileLookup.ascx" TagName="FileLookup" TagPrefix="uc1" %> -<%@ Register Src="UserControls/SimpleMessageBox.ascx" TagName="SimpleMessageBox" - TagPrefix="wsp" %> - -<%@ Register Src="ExchangeServer/UserControls/Menu.ascx" TagName="Menu" TagPrefix="wsp" %> -<%@ Register Src="UserControls/EnableAsyncTasksSupport.ascx" TagName="EnableAsyncTasksSupport" - TagPrefix="wsp" %> - - - - -
-
-
-
-
-
-
- - -
-
- - - - - - - - - - - - - - - - - - - - -
-
-  
- -
- - -
-
-
- - -
- -
-      -
-
- - -
-
-
-
-
-
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointBackupSiteCollection.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointBackupSiteCollection.ascx.cs deleted file mode 100644 index 5e1afb37..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointBackupSiteCollection.ascx.cs +++ /dev/null @@ -1,189 +0,0 @@ -// Copyright (c) 2015, Outercurve Foundation. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without modification, -// are permitted provided that the following conditions are met: -// -// - Redistributions of source code must retain the above copyright notice, this -// list of conditions and the following disclaimer. -// -// - Redistributions in binary form must reproduce the above copyright notice, -// this list of conditions and the following disclaimer in the documentation -// and/or other materials provided with the distribution. -// -// - Neither the name of the Outercurve Foundation nor the names of its -// contributors may be used to endorse or promote products derived from this -// software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR -// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -using System; -using System.Data; -using System.Configuration; -using System.Collections; -using System.IO; -using System.Web; -using System.Web.Security; -using System.Web.UI; -using System.Web.UI.WebControls; -using System.Web.UI.WebControls.WebParts; -using System.Web.UI.HtmlControls; -using WebsitePanel.Providers.SharePoint; - -namespace WebsitePanel.Portal -{ - public partial class HostedSharePointBackupSiteCollection : WebsitePanelModuleBase - { - private const string BACKUP_EXTENSION = ".bsh"; - - private int OrganizationId - { - get - { - return PanelRequest.GetInt("ItemID"); - } - } - - private int SiteCollectionId - { - get - { - return PanelRequest.GetInt("SiteCollectionID"); - } - } - - protected void Page_Load(object sender, EventArgs e) - { - if (!IsPostBack) - { - BindSite(); - } - } - - private void BindSite() - { - try - { - SharePointSiteCollection siteCollection = ES.Services.HostedSharePointServers.GetSiteCollection(this.SiteCollectionId); - litSiteCollectionName.Text = siteCollection.PhysicalAddress; - txtBackupName.Text = siteCollection.Url + BACKUP_EXTENSION; - fileLookup.SelectedFile = "\\"; - fileLookup.PackageId = siteCollection.PackageId; - - BindBackupName(); - ToggleControls(); - } - catch (Exception ex) - { - ShowErrorMessage("SHAREPOINT_GET_SITE", ex); - return; - } - } - - private void BindBackupName() - { - string backupName = Path.GetFileNameWithoutExtension(txtBackupName.Text); - txtBackupName.Text = backupName + (chkZipBackup.Checked ? ".zip" : BACKUP_EXTENSION); - } - - private void ToggleControls() - { - fileLookup.Visible = rbCopy.Checked; - } - - private void BackupSiteCollection() - { - try - { - string bakFile = ES.Services.HostedSharePointServers.BackupSiteCollection(this.SiteCollectionId, - txtBackupName.Text, chkZipBackup.Checked, rbDownload.Checked, fileLookup.SelectedFile); - - if (rbDownload.Checked && !String.IsNullOrEmpty(bakFile)) - { - - string fileName = bakFile; - - //Response.Clear(); - Response.AddHeader("Content-Disposition", "attachment; filename=" + Path.GetFileName(fileName)); - Response.ContentType = "application/octet-stream"; - - int FILE_BUFFER_LENGTH = 5000000; - byte[] buffer = null; - int offset = 0; - do - { - // Read remote content. - buffer = ES.Services.HostedSharePointServers.GetBackupBinaryChunk(this.SiteCollectionId, fileName, offset, FILE_BUFFER_LENGTH); - - // Write to stream. - //Response.BinaryWrite(buffer); - Response.OutputStream.Write(buffer, 0, buffer.Length); - offset += FILE_BUFFER_LENGTH; - } - while (buffer.Length == FILE_BUFFER_LENGTH); - - Response.Flush(); - Response.End(); - //Response.Close(); - //HttpContext.Current.ApplicationInstance.CompleteRequest(); - //Response.End(); - - } - } - catch (Exception ex) - { - ShowErrorMessage("SHAREPOINT_BACKUP_SITE", ex); - return; - } - //Response.ClearContent(); - Context.Response.Clear(); - if (!rbDownload.Checked) - RedirectBack(); - - } - - protected void btnBackup_Click(object sender, EventArgs e) - { - BackupSiteCollection(); - } - protected void btnCancel_Click(object sender, EventArgs e) - { - RedirectBack(); - } - - private void RedirectBack() - { - HttpContext.Current.Response.Redirect(EditUrl("SpaceID", PanelSecurity.PackageId.ToString(), "sharepoint_edit_sitecollection", "SiteCollectionID=" + this.SiteCollectionId, "ItemID=" + PanelRequest.ItemID.ToString())); - } - - protected void chkZipBackup_CheckedChanged(object sender, EventArgs e) - { - BindBackupName(); - } - - protected void rbDownload_CheckedChanged(object sender, EventArgs e) - { - ToggleControls(); - } - - protected override void OnPreRender(EventArgs e) - { - string str = string.Format("var rb = document.getElementById('{0}'); if (!rb.checked) ShowProgressDialog('Backing up site collection...');", rbDownload.ClientID); - - - - btnBackup.Attributes.Add("onclick", str); - base.OnPreRender(e); - } - - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointBackupSiteCollection.ascx.designer.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointBackupSiteCollection.ascx.designer.cs deleted file mode 100644 index 6bd4aa9e..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointBackupSiteCollection.ascx.designer.cs +++ /dev/null @@ -1,159 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace WebsitePanel.Portal { - - - public partial class HostedSharePointBackupSiteCollection { - - /// - /// asyncTasks control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.EnableAsyncTasksSupport asyncTasks; - - /// - /// Image1 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Image Image1; - - /// - /// locTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locTitle; - - /// - /// messageBox control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.UserControls.SimpleMessageBox messageBox; - - /// - /// litSiteCollectionName control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Literal litSiteCollectionName; - - /// - /// lblBackupFileName control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblBackupFileName; - - /// - /// txtBackupName control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.TextBox txtBackupName; - - /// - /// validatorUserName control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.RequiredFieldValidator validatorUserName; - - /// - /// lblBackupOptions control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblBackupOptions; - - /// - /// chkZipBackup control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.CheckBox chkZipBackup; - - /// - /// lblBackupDestination control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblBackupDestination; - - /// - /// rbDownload control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.RadioButton rbDownload; - - /// - /// rbCopy control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.RadioButton rbCopy; - - /// - /// fileLookup control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.FileLookup fileLookup; - - /// - /// btnBackup control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnBackup; - - /// - /// btnCancel control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnCancel; - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEditSiteCollection.ascx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEditSiteCollection.ascx deleted file mode 100644 index 5a219436..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEditSiteCollection.ascx +++ /dev/null @@ -1,209 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" Codebehind="HostedSharePointEditSiteCollection.ascx.cs" Inherits="WebsitePanel.Portal.HostedSharePointEditSiteCollection" %> -<%@ Register Src="ExchangeServer/UserControls/SizeBox.ascx" TagName="SizeBox" TagPrefix="wsp" %> -<%@ Register Src="UserControls/SimpleMessageBox.ascx" TagName="SimpleMessageBox" TagPrefix="wsp" %> -<%@ Register Src="UserControls/CollapsiblePanel.ascx" TagName="CollapsiblePanel" TagPrefix="wsp" %> -<%@ Register Src="UserControls/PopupHeader.ascx" TagName="PopupHeader" TagPrefix="wsp" %> -<%@ Register Src="ExchangeServer/UserControls/Menu.ascx" TagName="Menu" TagPrefix="wsp" %> -<%@ Register Src="UserControls/AllocatePackageIPAddresses.ascx" TagName="SiteUrlBuilder" TagPrefix="wsp" %> -<%@ Register Src="ExchangeServer/UserControls/UserSelector.ascx" TagName="UserSelector" TagPrefix="wsp" %> -<%@ Register Src="UserControls/EnableAsyncTasksSupport.ascx" TagName="EnableAsyncTasksSupport" TagPrefix="wsp" %> -<%@ Register src="UserControls/QuotaEditor.ascx" tagname="QuotaEditor" tagprefix="uc1" %> -<%@ Register Src="DomainsSelectDomainControl.ascx" TagName="DomainsSelectDomainControl" TagPrefix="uc1" %> - - - -
-
-
-
-
-
-
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - . - - -
- - - -
- - - -
- - - - -
- - - -
- - - - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - -
- - - -
- - - - -
- - - -
- - - -
- - - -
- - - - -
- - - - - - - - - - -
- -
- -
-
-
-
- - - -
-
-
-
-
-
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEditSiteCollection.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEditSiteCollection.ascx.cs deleted file mode 100644 index 1c150ca9..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEditSiteCollection.ascx.cs +++ /dev/null @@ -1,450 +0,0 @@ -// Copyright (c) 2015, Outercurve Foundation. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without modification, -// are permitted provided that the following conditions are met: -// -// - Redistributions of source code must retain the above copyright notice, this -// list of conditions and the following disclaimer. -// -// - Redistributions in binary form must reproduce the above copyright notice, -// this list of conditions and the following disclaimer in the documentation -// and/or other materials provided with the distribution. -// -// - Neither the name of the Outercurve Foundation nor the names of its -// contributors may be used to endorse or promote products derived from this -// software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR -// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -using System; -using System.Collections.Generic; -using System.Globalization; -using System.Linq; -using System.Web; -using System.Web.UI.WebControls; -using WebsitePanel.EnterpriseServer; -using WebsitePanel.Providers.DNS; -using WebsitePanel.Providers.HostedSolution; -using WebsitePanel.Providers.SharePoint; - - -namespace WebsitePanel.Portal -{ - public partial class HostedSharePointEditSiteCollection : WebsitePanelModuleBase - { - SharePointSiteCollection item = null; - - private int OrganizationId - { - get - { - return PanelRequest.GetInt("ItemID"); - } - } - - private int SiteCollectionId - { - get - { - return PanelRequest.GetInt("SiteCollectionID"); - } - } - - protected void Page_Load(object sender, EventArgs e) - { - domain.PackageId = PanelSecurity.PackageId; - - warningStorage.UnlimitedText = GetLocalizedString("WarningUnlimitedValue"); - editWarningStorage.UnlimitedText = GetLocalizedString("WarningUnlimitedValue"); - - bool newItem = (this.SiteCollectionId == 0); - - tblEditItem.Visible = newItem; - tblViewItem.Visible = !newItem; - - //btnUpdate.Visible = newItem; - btnDelete.Visible = !newItem; - btnUpdate.Text = newItem ? GetLocalizedString("Text.Add") : GetLocalizedString("Text.Update"); - btnUpdate.OnClientClick = newItem ? GetLocalizedString("btnCreate.OnClientClick") : GetLocalizedString("btnUpdate.OnClientClick"); - - btnBackup.Enabled = btnRestore.Enabled = !newItem; - - // bind item - BindItem(); - - } - - private void BindItem() - { - try - { - if (!IsPostBack) - { - if (!this.IsDnsServiceAvailable()) - { - localMessageBox.ShowWarningMessage("HOSTEDSHAREPOINT_NO_DNS"); - } - - // load item if required - if (this.SiteCollectionId > 0) - { - // existing item - item = ES.Services.HostedSharePointServers.GetSiteCollection(this.SiteCollectionId); - if (item != null) - { - // save package info - ViewState["PackageId"] = item.PackageId; - } - else - RedirectToBrowsePage(); - } - else - { - // new item - ViewState["PackageId"] = PanelSecurity.PackageId; - if (UseSharedSLL(PanelSecurity.PackageId)) - { - - rowUrl.Visible = false; - valRequireHostName.Enabled = false; - valRequireCorrectHostName.Enabled = false; - } - } - - //this.gvUsers.DataBind(); - - List cultures = new List(); - foreach (int localeId in ES.Services.HostedSharePointServers.GetSupportedLanguages(PanelSecurity.PackageId)) - { - cultures.Add(new CultureInfo(localeId, false)); - } - - this.ddlLocaleID.DataSource = cultures; - this.ddlLocaleID.DataBind(); - } - - if (!IsPostBack) - { - // bind item to controls - if (item != null) - { - // bind item to controls - lnkUrl.Text = item.PhysicalAddress; - lnkUrl.NavigateUrl = item.PhysicalAddress; - litSiteCollectionOwner.Text = String.Format("{0} ({1})", item.OwnerName, item.OwnerEmail); - litLocaleID.Text = new CultureInfo(item.LocaleId, false).DisplayName; - litTitle.Text = item.Title; - litDescription.Text = item.Description; - editWarningStorage.QuotaValue = (int)item.WarningStorage; - editMaxStorage.QuotaValue = (int)item.MaxSiteStorage; - } - - Organization org = ES.Services.Organizations.GetOrganization(OrganizationId); - - if (org != null) - { - SetStorageQuotas(org, item); - } - } - //OrganizationDomainName[] domains = ES.Services.Organizations.GetOrganizationDomains(PanelRequest.ItemID); - - //DomainInfo[] domains = ES.Services.Servers.GetMyDomains(PanelSecurity.PackageId); - - EnterpriseServer.DomainInfo[] domains = ES.Services.Servers.GetDomains(PanelSecurity.PackageId); - - if (domains.Length == 0) - { - localMessageBox.ShowWarningMessage("HOSTEDSHAREPOINT_NO_DOMAINS"); - DisableFormControls(this, btnCancel); - return; - } - //if (this.gvUsers.Rows.Count == 0) - //{ - // localMessageBox.ShowWarningMessage("HOSTEDSHAREPOINT_NO_USERS"); - // DisableFormControls(this, btnCancel); - // return; - //} - } - catch - { - - localMessageBox.ShowWarningMessage("INIT_SERVICE_ITEM_FORM"); - - DisableFormControls(this, btnCancel); - return; - } - } - - /// Checks and sets disk quotas values. - /// The organization. - /// The site collection. - private void SetStorageQuotas(Organization organization, SharePointSiteCollection collection) - { - var quotaValue = organization.MaxSharePointStorage; - - if (quotaValue != -1) - { - var spaceResrved = GetReservedDiskStorageSpace(); - - if (spaceResrved > quotaValue) - { - quotaValue = 0; - } - else - { - quotaValue -= spaceResrved; - } - - if (collection != null) - { - quotaValue += (int)collection.MaxSiteStorage; - } - } - - maxStorage.ParentQuotaValue = quotaValue; - maxStorage.QuotaValue = quotaValue; - editMaxStorage.ParentQuotaValue = quotaValue; - warningStorage.ParentQuotaValue = quotaValue; - warningStorage.QuotaValue = quotaValue; - editWarningStorage.ParentQuotaValue = quotaValue; - - btnUpdate.Enabled = quotaValue != 0; - } - - /// Gets disk space reserved by existing site collections. - /// Reserved disk space vallue. - private int GetReservedDiskStorageSpace() - { - var existingCollections = ES.Services.HostedSharePointServers.GetSiteCollections(PanelSecurity.PackageId, false); - - return (int)existingCollections.Sum(siteCollection => siteCollection.MaxSiteStorage); - } - - private void SaveItem() - { - if (!Page.IsValid) - { - return; - } - - - if (this.SiteCollectionId == 0) - { - if (this.userSelector.GetAccount() == null) - { - localMessageBox.ShowWarningMessage("HOSTEDSHAREPOINT_NO_USERS"); - return; - } - - - // new item - try - { - item = new SharePointSiteCollection(); - - if (!UseSharedSLL(PanelSecurity.PackageId)) - { - SharePointSiteCollectionListPaged existentSiteCollections = ES.Services.HostedSharePointServers.GetSiteCollectionsPaged(PanelSecurity.PackageId, this.OrganizationId, "ItemName", String.Format("%{0}", this.domain.DomainName), String.Empty, 0, Int32.MaxValue); - foreach (SharePointSiteCollection existentSiteCollection in existentSiteCollections.SiteCollections) - { - Uri existentSiteCollectionUri = new Uri(existentSiteCollection.Name); - if (existentSiteCollection.Name == String.Format("{0}://{1}", existentSiteCollectionUri.Scheme, this.txtHostName.Text.ToLower() + "." + this.domain.DomainName)) - { - localMessageBox.ShowWarningMessage("HOSTEDSHAREPOINT_DOMAIN_IN_USE"); - return; - } - } - - item.Name = this.txtHostName.Text.ToLower() + "." + this.domain.DomainName; - } - else - item.Name = string.Empty; - - // get form data - - item.OrganizationId = this.OrganizationId; - item.Id = this.SiteCollectionId; - item.PackageId = PanelSecurity.PackageId; - - item.LocaleId = Int32.Parse(this.ddlLocaleID.SelectedValue); - item.OwnerLogin = this.userSelector.GetSAMAccountName(); - item.OwnerEmail = this.userSelector.GetPrimaryEmailAddress(); - item.OwnerName = this.userSelector.GetDisplayName(); - item.Title = txtTitle.Text; - item.Description = txtDescription.Text; - - - item.MaxSiteStorage = maxStorage.QuotaValue; - item.WarningStorage = warningStorage.QuotaValue; - - int result = ES.Services.HostedSharePointServers.AddSiteCollection(item); - if (result < 0) - { - localMessageBox.ShowResultMessage(result); - return; - } - } - catch (Exception ex) - { - localMessageBox.ShowErrorMessage("HOSTEDSHAREPOINT_ADD_SITECOLLECTION", ex); - return; - } - } - else - { - ES.Services.HostedSharePointServers.UpdateQuota(PanelRequest.ItemID, SiteCollectionId, editMaxStorage.QuotaValue, editWarningStorage.QuotaValue); - } - - // return - RedirectToSiteCollectionsList(); - } - - private void AddDnsRecord(int domainId, string recordName, string recordData) - { - int result = ES.Services.Servers.AddDnsZoneRecord(domainId, recordName, DnsRecordType.A, recordData, 0, 0, 0, 0); - if (result < 0) - { - ShowResultMessage(result); - } - } - - private bool IsDnsServiceAvailable() - { - ProviderInfo dnsProvider = ES.Services.Servers.GetPackageServiceProvider(PanelSecurity.PackageId, ResourceGroups.Dns); - return dnsProvider != null; - } - - private void DeleteItem() - { - // delete - try - { - int result = ES.Services.HostedSharePointServers.DeleteSiteCollection(this.SiteCollectionId); - if (result < 0) - { - ShowResultMessage(result); - return; - } - } - catch (Exception ex) - { - localMessageBox.ShowErrorMessage("HOSTEDSHAREPOINT_DELETE_SITECOLLECTION", ex); - return; - } - - // return - RedirectToSiteCollectionsList(); - } - - protected void odsAccountsPaged_Selected(object sender, ObjectDataSourceStatusEventArgs e) - { - if (e.Exception != null) - { - localMessageBox.ShowErrorMessage("ORGANIZATION_GET_USERS", e.Exception); - e.ExceptionHandled = true; - } - } - - - protected void btnCancel_Click(object sender, EventArgs e) - { - // return - RedirectToSiteCollectionsList(); - } - - protected void btnDelete_Click(object sender, EventArgs e) - { - DeleteItem(); - } - - protected void btnUpdate_Click(object sender, EventArgs e) - { - SaveItem(); - } - - protected void btnBackup_Click(object sender, EventArgs e) - { - Response.Redirect(EditUrl("SpaceID", PanelSecurity.PackageId.ToString(), "sharepoint_backup_sitecollection", "SiteCollectionID=" + this.SiteCollectionId, "ItemID=" + PanelRequest.ItemID.ToString())); - } - - protected void btnRestore_Click(object sender, EventArgs e) - { - Response.Redirect(EditUrl("SpaceID", PanelSecurity.PackageId.ToString(), "sharepoint_restore_sitecollection", "SiteCollectionID=" + this.SiteCollectionId, "ItemID=" + PanelRequest.ItemID.ToString())); - } - - - - private void RedirectToSiteCollectionsList() - { - Response.Redirect(EditUrl("SpaceID", PanelSecurity.PackageId.ToString(), "sharepoint_sitecollections", "ItemID=" + PanelRequest.ItemID.ToString())); - } - - private bool UseSharedSLL(int packageID) - { - PackageContext cntx = ES.Services.Packages.GetPackageContext(PanelSecurity.PackageId); - if (cntx != null) - { - foreach (QuotaValueInfo quota in cntx.QuotasArray) - { - switch (quota.QuotaId) - { - case 400: - if (Convert.ToBoolean(quota.QuotaAllocatedValue)) - { - return true; - } - - break; - } - } - } - - return false; - } - - - //private void RegisterOwnerSelector() - //{ - // // Define the name and type of the client scripts on the page. - // String csname = "OwnerSelectorScript"; - // Type cstype = this.GetType(); - - // // Get a ClientScriptManager reference from the Page class. - // ClientScriptManager cs = Page.ClientScript; - - // // Check to see if the client script is already registered. - // if (!cs.IsClientScriptBlockRegistered(cstype, csname)) - // { - // StringBuilder ownerSelector = new StringBuilder(); - // ownerSelector.Append(""); - // cs.RegisterClientScriptBlock(cstype, csname, ownerSelector.ToString(), false); - // } - - //} - - //private StringDictionary ConvertArrayToDictionary(string[] settings) - //{ - // StringDictionary r = new StringDictionary(); - // foreach (string setting in settings) - // { - // int idx = setting.IndexOf('='); - // r.Add(setting.Substring(0, idx), setting.Substring(idx + 1)); - // } - // return r; - //} - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEditSiteCollection.ascx.designer.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEditSiteCollection.ascx.designer.cs deleted file mode 100644 index 6801e4b1..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEditSiteCollection.ascx.designer.cs +++ /dev/null @@ -1,447 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace WebsitePanel.Portal { - - - public partial class HostedSharePointEditSiteCollection { - - /// - /// asyncTasks control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.EnableAsyncTasksSupport asyncTasks; - - /// - /// Image1 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Image Image1; - - /// - /// locTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locTitle; - - /// - /// localMessageBox control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.UserControls.SimpleMessageBox localMessageBox; - - /// - /// tblEditItem control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.HtmlControls.HtmlTable tblEditItem; - - /// - /// rowUrl control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.HtmlControls.HtmlTableRow rowUrl; - - /// - /// lblSiteCollectionUrl control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblSiteCollectionUrl; - - /// - /// txtHostName control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.TextBox txtHostName; - - /// - /// domain control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.DomainsSelectDomainControl domain; - - /// - /// valRequireHostName control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.RequiredFieldValidator valRequireHostName; - - /// - /// valRequireCorrectHostName control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.RegularExpressionValidator valRequireCorrectHostName; - - /// - /// lblSiteCollectionOwner control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblSiteCollectionOwner; - - /// - /// userSelector control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.ExchangeServer.UserControls.UserSelector userSelector; - - /// - /// lblSiteCollectionLocaleID control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblSiteCollectionLocaleID; - - /// - /// ddlLocaleID control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.DropDownList ddlLocaleID; - - /// - /// lblMaxStorage control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblMaxStorage; - - /// - /// maxStorage control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.QuotaEditor maxStorage; - - /// - /// lblWarningStorage control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblWarningStorage; - - /// - /// warningStorage control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.QuotaEditor warningStorage; - - /// - /// lblTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblTitle; - - /// - /// txtTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.TextBox txtTitle; - - /// - /// valRequireTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.RequiredFieldValidator valRequireTitle; - - /// - /// lblDescription control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblDescription; - - /// - /// txtDescription control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.TextBox txtDescription; - - /// - /// RequiredFieldValidator1 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.RequiredFieldValidator RequiredFieldValidator1; - - /// - /// tblViewItem control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.HtmlControls.HtmlTable tblViewItem; - - /// - /// lblSiteCollectionUrl2 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblSiteCollectionUrl2; - - /// - /// lnkUrl control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.HyperLink lnkUrl; - - /// - /// lblSiteCollectionOwner2 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblSiteCollectionOwner2; - - /// - /// litSiteCollectionOwner control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Literal litSiteCollectionOwner; - - /// - /// lblSiteCollectionLocaleID2 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblSiteCollectionLocaleID2; - - /// - /// litLocaleID control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Literal litLocaleID; - - /// - /// lblMaxStorageView control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblMaxStorageView; - - /// - /// editMaxStorage control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.QuotaEditor editMaxStorage; - - /// - /// lblWarningStorageView control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblWarningStorageView; - - /// - /// editWarningStorage control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.QuotaEditor editWarningStorage; - - /// - /// lblTitle2 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblTitle2; - - /// - /// litTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Literal litTitle; - - /// - /// lblDescription2 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblDescription2; - - /// - /// litDescription control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Literal litDescription; - - /// - /// secMainTools control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.CollapsiblePanel secMainTools; - - /// - /// ToolsPanel control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Panel ToolsPanel; - - /// - /// tblMaintenance control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.HtmlControls.HtmlTable tblMaintenance; - - /// - /// btnBackup control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnBackup; - - /// - /// btnRestore control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnRestore; - - /// - /// btnUpdate control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnUpdate; - - /// - /// btnCancel control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnCancel; - - /// - /// btnDelete control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnDelete; - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseBackupSiteCollection.ascx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseBackupSiteCollection.ascx deleted file mode 100644 index 4b315bc8..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseBackupSiteCollection.ascx +++ /dev/null @@ -1,80 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" Codebehind="HostedSharePointEnterpriseBackupSiteCollection.ascx.cs" - Inherits="WebsitePanel.Portal.HostedSharePointEnterpriseBackupSiteCollection" %> -<%@ Register Src="UserControls/FileLookup.ascx" TagName="FileLookup" TagPrefix="uc1" %> -<%@ Register Src="UserControls/SimpleMessageBox.ascx" TagName="SimpleMessageBox" - TagPrefix="wsp" %> - -<%@ Register Src="ExchangeServer/UserControls/Menu.ascx" TagName="Menu" TagPrefix="wsp" %> -<%@ Register Src="UserControls/EnableAsyncTasksSupport.ascx" TagName="EnableAsyncTasksSupport" - TagPrefix="wsp" %> - - - - -
-
-
-
-
-
-
- - -
-
- - - - - - - - - - - - - - - - - - - - -
-
-  
- -
- - -
-
-
- - -
- -
-      -
-
- - -
-
-
-
-
-
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseBackupSiteCollection.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseBackupSiteCollection.ascx.cs deleted file mode 100644 index e5a59c73..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseBackupSiteCollection.ascx.cs +++ /dev/null @@ -1,189 +0,0 @@ -// Copyright (c) 2015, Outercurve Foundation. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without modification, -// are permitted provided that the following conditions are met: -// -// - Redistributions of source code must retain the above copyright notice, this -// list of conditions and the following disclaimer. -// -// - Redistributions in binary form must reproduce the above copyright notice, -// this list of conditions and the following disclaimer in the documentation -// and/or other materials provided with the distribution. -// -// - Neither the name of the Outercurve Foundation nor the names of its -// contributors may be used to endorse or promote products derived from this -// software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR -// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -using System; -using System.Data; -using System.Configuration; -using System.Collections; -using System.IO; -using System.Web; -using System.Web.Security; -using System.Web.UI; -using System.Web.UI.WebControls; -using System.Web.UI.WebControls.WebParts; -using System.Web.UI.HtmlControls; -using WebsitePanel.Providers.SharePoint; - -namespace WebsitePanel.Portal -{ - public partial class HostedSharePointEnterpriseBackupSiteCollection : WebsitePanelModuleBase - { - private const string BACKUP_EXTENSION = ".bsh"; - - private int OrganizationId - { - get - { - return PanelRequest.GetInt("ItemID"); - } - } - - private int SiteCollectionId - { - get - { - return PanelRequest.GetInt("SiteCollectionID"); - } - } - - protected void Page_Load(object sender, EventArgs e) - { - if (!IsPostBack) - { - BindSite(); - } - } - - private void BindSite() - { - try - { - SharePointSiteCollection siteCollection = ES.Services.HostedSharePointServersEnt.Enterprise_GetSiteCollection(this.SiteCollectionId); - litSiteCollectionName.Text = siteCollection.PhysicalAddress; - txtBackupName.Text = siteCollection.Url + BACKUP_EXTENSION; - fileLookup.SelectedFile = "\\"; - fileLookup.PackageId = siteCollection.PackageId; - - BindBackupName(); - ToggleControls(); - } - catch (Exception ex) - { - ShowErrorMessage("SHAREPOINT_GET_SITE", ex); - return; - } - } - - private void BindBackupName() - { - string backupName = Path.GetFileNameWithoutExtension(txtBackupName.Text); - txtBackupName.Text = backupName + (chkZipBackup.Checked ? ".zip" : BACKUP_EXTENSION); - } - - private void ToggleControls() - { - fileLookup.Visible = rbCopy.Checked; - } - - private void BackupSiteCollection() - { - try - { - string bakFile = ES.Services.HostedSharePointServersEnt.Enterprise_BackupSiteCollection(this.SiteCollectionId, - txtBackupName.Text, chkZipBackup.Checked, rbDownload.Checked, fileLookup.SelectedFile); - - if (rbDownload.Checked && !String.IsNullOrEmpty(bakFile)) - { - - string fileName = bakFile; - - //Response.Clear(); - Response.AddHeader("Content-Disposition", "attachment; filename=" + Path.GetFileName(fileName)); - Response.ContentType = "application/octet-stream"; - - int FILE_BUFFER_LENGTH = 5000000; - byte[] buffer = null; - int offset = 0; - do - { - // Read remote content. - buffer = ES.Services.HostedSharePointServersEnt.Enterprise_GetBackupBinaryChunk(this.SiteCollectionId, fileName, offset, FILE_BUFFER_LENGTH); - - // Write to stream. - //Response.BinaryWrite(buffer); - Response.OutputStream.Write(buffer, 0, buffer.Length); - offset += FILE_BUFFER_LENGTH; - } - while (buffer.Length == FILE_BUFFER_LENGTH); - - Response.Flush(); - Response.End(); - //Response.Close(); - //HttpContext.Current.ApplicationInstance.CompleteRequest(); - //Response.End(); - - } - } - catch (Exception ex) - { - ShowErrorMessage("SHAREPOINT_BACKUP_SITE", ex); - return; - } - //Response.ClearContent(); - Context.Response.Clear(); - if (!rbDownload.Checked) - RedirectBack(); - - } - - protected void btnBackup_Click(object sender, EventArgs e) - { - BackupSiteCollection(); - } - protected void btnCancel_Click(object sender, EventArgs e) - { - RedirectBack(); - } - - private void RedirectBack() - { - HttpContext.Current.Response.Redirect(EditUrl("SpaceID", PanelSecurity.PackageId.ToString(), "sharepoint_enterprise_edit_sitecollection", "SiteCollectionID=" + this.SiteCollectionId, "ItemID=" + PanelRequest.ItemID.ToString())); - } - - protected void chkZipBackup_CheckedChanged(object sender, EventArgs e) - { - BindBackupName(); - } - - protected void rbDownload_CheckedChanged(object sender, EventArgs e) - { - ToggleControls(); - } - - protected override void OnPreRender(EventArgs e) - { - string str = string.Format("var rb = document.getElementById('{0}'); if (!rb.checked) ShowProgressDialog('Backing up site collection...');", rbDownload.ClientID); - - - - btnBackup.Attributes.Add("onclick", str); - base.OnPreRender(e); - } - - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseBackupSiteCollection.ascx.designer.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseBackupSiteCollection.ascx.designer.cs deleted file mode 100644 index b74025b4..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseBackupSiteCollection.ascx.designer.cs +++ /dev/null @@ -1,159 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace WebsitePanel.Portal { - - - public partial class HostedSharePointEnterpriseBackupSiteCollection { - - /// - /// asyncTasks control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.EnableAsyncTasksSupport asyncTasks; - - /// - /// Image1 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Image Image1; - - /// - /// locTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locTitle; - - /// - /// messageBox control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.UserControls.SimpleMessageBox messageBox; - - /// - /// litSiteCollectionName control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Literal litSiteCollectionName; - - /// - /// lblBackupFileName control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblBackupFileName; - - /// - /// txtBackupName control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.TextBox txtBackupName; - - /// - /// validatorUserName control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.RequiredFieldValidator validatorUserName; - - /// - /// lblBackupOptions control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblBackupOptions; - - /// - /// chkZipBackup control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.CheckBox chkZipBackup; - - /// - /// lblBackupDestination control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblBackupDestination; - - /// - /// rbDownload control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.RadioButton rbDownload; - - /// - /// rbCopy control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.RadioButton rbCopy; - - /// - /// fileLookup control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.FileLookup fileLookup; - - /// - /// btnBackup control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnBackup; - - /// - /// btnCancel control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnCancel; - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseEditSiteCollection.ascx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseEditSiteCollection.ascx deleted file mode 100644 index cd1a07f8..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseEditSiteCollection.ascx +++ /dev/null @@ -1,209 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" Codebehind="HostedSharePointEnterpriseEditSiteCollection.ascx.cs" Inherits="WebsitePanel.Portal.HostedSharePointEnterpriseEditSiteCollection" %> -<%@ Register Src="ExchangeServer/UserControls/SizeBox.ascx" TagName="SizeBox" TagPrefix="wsp" %> -<%@ Register Src="UserControls/SimpleMessageBox.ascx" TagName="SimpleMessageBox" TagPrefix="wsp" %> -<%@ Register Src="UserControls/CollapsiblePanel.ascx" TagName="CollapsiblePanel" TagPrefix="wsp" %> -<%@ Register Src="UserControls/PopupHeader.ascx" TagName="PopupHeader" TagPrefix="wsp" %> -<%@ Register Src="ExchangeServer/UserControls/Menu.ascx" TagName="Menu" TagPrefix="wsp" %> -<%@ Register Src="UserControls/AllocatePackageIPAddresses.ascx" TagName="SiteUrlBuilder" TagPrefix="wsp" %> -<%@ Register Src="ExchangeServer/UserControls/UserSelector.ascx" TagName="UserSelector" TagPrefix="wsp" %> -<%@ Register Src="UserControls/EnableAsyncTasksSupport.ascx" TagName="EnableAsyncTasksSupport" TagPrefix="wsp" %> -<%@ Register src="UserControls/QuotaEditor.ascx" tagname="QuotaEditor" tagprefix="uc1" %> -<%@ Register Src="DomainsSelectDomainControl.ascx" TagName="DomainsSelectDomainControl" TagPrefix="uc1" %> - - - -
-
-
-
-
-
-
- - -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - . - - -
- - - -
- - - -
- - - - -
- - - -
- - - - -
- - - - -
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- - - - -
- - - -
- - - -
- - - - -
- - - -
- - - -
- - - -
- - - - -
- - - - - - - - - - -
- -
- -
-
-
-
- - - -
-
-
-
-
-
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseEditSiteCollection.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseEditSiteCollection.ascx.cs deleted file mode 100644 index eae4b2ab..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseEditSiteCollection.ascx.cs +++ /dev/null @@ -1,450 +0,0 @@ -// Copyright (c) 2015, Outercurve Foundation. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without modification, -// are permitted provided that the following conditions are met: -// -// - Redistributions of source code must retain the above copyright notice, this -// list of conditions and the following disclaimer. -// -// - Redistributions in binary form must reproduce the above copyright notice, -// this list of conditions and the following disclaimer in the documentation -// and/or other materials provided with the distribution. -// -// - Neither the name of the Outercurve Foundation nor the names of its -// contributors may be used to endorse or promote products derived from this -// software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR -// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -using System; -using System.Collections.Generic; -using System.Globalization; -using System.Linq; -using System.Web; -using System.Web.UI.WebControls; -using WebsitePanel.EnterpriseServer; -using WebsitePanel.Providers.DNS; -using WebsitePanel.Providers.HostedSolution; -using WebsitePanel.Providers.SharePoint; - - -namespace WebsitePanel.Portal -{ - public partial class HostedSharePointEnterpriseEditSiteCollection : WebsitePanelModuleBase - { - SharePointSiteCollection item = null; - - private int OrganizationId - { - get - { - return PanelRequest.GetInt("ItemID"); - } - } - - private int SiteCollectionId - { - get - { - return PanelRequest.GetInt("SiteCollectionID"); - } - } - - protected void Page_Load(object sender, EventArgs e) - { - domain.PackageId = PanelSecurity.PackageId; - - warningStorage.UnlimitedText = GetLocalizedString("WarningUnlimitedValue"); - editWarningStorage.UnlimitedText = GetLocalizedString("WarningUnlimitedValue"); - - bool newItem = (this.SiteCollectionId == 0); - - tblEditItem.Visible = newItem; - tblViewItem.Visible = !newItem; - - //btnUpdate.Visible = newItem; - btnDelete.Visible = !newItem; - btnUpdate.Text = newItem ? GetLocalizedString("Text.Add") : GetLocalizedString("Text.Update"); - btnUpdate.OnClientClick = newItem ? GetLocalizedString("btnCreate.OnClientClick") : GetLocalizedString("btnUpdate.OnClientClick"); - - btnBackup.Enabled = btnRestore.Enabled = !newItem; - - // bind item - BindItem(); - - } - - private void BindItem() - { - try - { - if (!IsPostBack) - { - if (!this.IsDnsServiceAvailable()) - { - localMessageBox.ShowWarningMessage("HOSTEDSHAREPOINT_NO_DNS"); - } - - // load item if required - if (this.SiteCollectionId > 0) - { - // existing item - item = ES.Services.HostedSharePointServersEnt.Enterprise_GetSiteCollection(this.SiteCollectionId); - if (item != null) - { - // save package info - ViewState["PackageId"] = item.PackageId; - } - else - RedirectToBrowsePage(); - } - else - { - // new item - ViewState["PackageId"] = PanelSecurity.PackageId; - if (UseSharedSLL(PanelSecurity.PackageId)) - { - - rowUrl.Visible = false; - valRequireHostName.Enabled = false; - valRequireCorrectHostName.Enabled = false; - } - } - - //this.gvUsers.DataBind(); - - List cultures = new List(); - foreach (int localeId in ES.Services.HostedSharePointServersEnt.Enterprise_GetSupportedLanguages(PanelSecurity.PackageId)) - { - cultures.Add(new CultureInfo(localeId, false)); - } - - this.ddlLocaleID.DataSource = cultures; - this.ddlLocaleID.DataBind(); - } - - if (!IsPostBack) - { - // bind item to controls - if (item != null) - { - // bind item to controls - lnkUrl.Text = item.PhysicalAddress; - lnkUrl.NavigateUrl = item.PhysicalAddress; - litSiteCollectionOwner.Text = String.Format("{0} ({1})", item.OwnerName, item.OwnerEmail); - litLocaleID.Text = new CultureInfo(item.LocaleId, false).DisplayName; - litTitle.Text = item.Title; - litDescription.Text = item.Description; - editWarningStorage.QuotaValue = (int)item.WarningStorage; - editMaxStorage.QuotaValue = (int)item.MaxSiteStorage; - } - - Organization org = ES.Services.Organizations.GetOrganization(OrganizationId); - - if (org != null) - { - SetStorageQuotas(org, item); - } - } - //OrganizationDomainName[] domains = ES.Services.Organizations.GetOrganizationDomains(PanelRequest.ItemID); - - //DomainInfo[] domains = ES.Services.Servers.GetMyDomains(PanelSecurity.PackageId); - - EnterpriseServer.DomainInfo[] domains = ES.Services.Servers.GetDomains(PanelSecurity.PackageId); - - if (domains.Length == 0) - { - localMessageBox.ShowWarningMessage("HOSTEDSHAREPOINT_NO_DOMAINS"); - DisableFormControls(this, btnCancel); - return; - } - //if (this.gvUsers.Rows.Count == 0) - //{ - // localMessageBox.ShowWarningMessage("HOSTEDSHAREPOINT_NO_USERS"); - // DisableFormControls(this, btnCancel); - // return; - //} - } - catch - { - - localMessageBox.ShowWarningMessage("INIT_SERVICE_ITEM_FORM"); - - DisableFormControls(this, btnCancel); - return; - } - } - - /// Checks and sets disk quotas values. - /// The organization. - /// The site collection. - private void SetStorageQuotas(Organization organization, SharePointSiteCollection collection) - { - var quotaValue = organization.MaxSharePointEnterpriseStorage; - - if (quotaValue != -1) - { - var spaceResrved = GetReservedDiskStorageSpace(); - - if (spaceResrved > quotaValue) - { - quotaValue = 0; - } - else - { - quotaValue -= spaceResrved; - } - - if (collection != null) - { - quotaValue += (int)collection.MaxSiteStorage; - } - } - - maxStorage.ParentQuotaValue = quotaValue; - maxStorage.QuotaValue = quotaValue; - editMaxStorage.ParentQuotaValue = quotaValue; - warningStorage.ParentQuotaValue = quotaValue; - warningStorage.QuotaValue = quotaValue; - editWarningStorage.ParentQuotaValue = quotaValue; - - btnUpdate.Enabled = quotaValue != 0; - } - - /// Gets disk space reserved by existing site collections. - /// Reserved disk space vallue. - private int GetReservedDiskStorageSpace() - { - var existingCollections = ES.Services.HostedSharePointServersEnt.Enterprise_GetSiteCollections(PanelSecurity.PackageId, false); - - return (int)existingCollections.Sum(siteCollection => siteCollection.MaxSiteStorage); - } - - private void SaveItem() - { - if (!Page.IsValid) - { - return; - } - - - if (this.SiteCollectionId == 0) - { - if (this.userSelector.GetAccount() == null) - { - localMessageBox.ShowWarningMessage("HOSTEDSHAREPOINT_NO_USERS"); - return; - } - - - // new item - try - { - item = new SharePointSiteCollection(); - - if (!UseSharedSLL(PanelSecurity.PackageId)) - { - SharePointSiteCollectionListPaged existentSiteCollections = ES.Services.HostedSharePointServersEnt.Enterprise_GetSiteCollectionsPaged(PanelSecurity.PackageId, this.OrganizationId, "ItemName", String.Format("%{0}", this.domain.DomainName), String.Empty, 0, Int32.MaxValue); - foreach (SharePointSiteCollection existentSiteCollection in existentSiteCollections.SiteCollections) - { - Uri existentSiteCollectionUri = new Uri(existentSiteCollection.Name); - if (existentSiteCollection.Name == String.Format("{0}://{1}", existentSiteCollectionUri.Scheme, this.txtHostName.Text.ToLower() + "." + this.domain.DomainName)) - { - localMessageBox.ShowWarningMessage("HOSTEDSHAREPOINT_DOMAIN_IN_USE"); - return; - } - } - - item.Name = this.txtHostName.Text.ToLower() + "." + this.domain.DomainName; - } - else - item.Name = string.Empty; - - // get form data - - item.OrganizationId = this.OrganizationId; - item.Id = this.SiteCollectionId; - item.PackageId = PanelSecurity.PackageId; - - item.LocaleId = Int32.Parse(this.ddlLocaleID.SelectedValue); - item.OwnerLogin = this.userSelector.GetSAMAccountName(); - item.OwnerEmail = this.userSelector.GetPrimaryEmailAddress(); - item.OwnerName = this.userSelector.GetDisplayName(); - item.Title = txtTitle.Text; - item.Description = txtDescription.Text; - - - item.MaxSiteStorage = maxStorage.QuotaValue; - item.WarningStorage = warningStorage.QuotaValue; - - int result = ES.Services.HostedSharePointServersEnt.Enterprise_AddSiteCollection(item); - if (result < 0) - { - localMessageBox.ShowResultMessage(result); - return; - } - } - catch (Exception ex) - { - localMessageBox.ShowErrorMessage("HOSTEDSHAREPOINT_ADD_SITECOLLECTION", ex); - return; - } - } - else - { - ES.Services.HostedSharePointServersEnt.Enterprise_UpdateQuota(PanelRequest.ItemID, SiteCollectionId, editMaxStorage.QuotaValue, editWarningStorage.QuotaValue); - } - - // return - RedirectToSiteCollectionsList(); - } - - private void AddDnsRecord(int domainId, string recordName, string recordData) - { - int result = ES.Services.Servers.AddDnsZoneRecord(domainId, recordName, DnsRecordType.A, recordData, 0, 0, 0, 0); - if (result < 0) - { - ShowResultMessage(result); - } - } - - private bool IsDnsServiceAvailable() - { - ProviderInfo dnsProvider = ES.Services.Servers.GetPackageServiceProvider(PanelSecurity.PackageId, ResourceGroups.Dns); - return dnsProvider != null; - } - - private void DeleteItem() - { - // delete - try - { - int result = ES.Services.HostedSharePointServersEnt.Enterprise_DeleteSiteCollection(this.SiteCollectionId); - if (result < 0) - { - ShowResultMessage(result); - return; - } - } - catch (Exception ex) - { - localMessageBox.ShowErrorMessage("HOSTEDSHAREPOINT_DELETE_SITECOLLECTION", ex); - return; - } - - // return - RedirectToSiteCollectionsList(); - } - - protected void odsAccountsPaged_Selected(object sender, ObjectDataSourceStatusEventArgs e) - { - if (e.Exception != null) - { - localMessageBox.ShowErrorMessage("ORGANIZATION_GET_USERS", e.Exception); - e.ExceptionHandled = true; - } - } - - - protected void btnCancel_Click(object sender, EventArgs e) - { - // return - RedirectToSiteCollectionsList(); - } - - protected void btnDelete_Click(object sender, EventArgs e) - { - DeleteItem(); - } - - protected void btnUpdate_Click(object sender, EventArgs e) - { - SaveItem(); - } - - protected void btnBackup_Click(object sender, EventArgs e) - { - Response.Redirect(EditUrl("SpaceID", PanelSecurity.PackageId.ToString(), "sharepoint_enterprise_backup_sitecollection", "SiteCollectionID=" + this.SiteCollectionId, "ItemID=" + PanelRequest.ItemID.ToString())); - } - - protected void btnRestore_Click(object sender, EventArgs e) - { - Response.Redirect(EditUrl("SpaceID", PanelSecurity.PackageId.ToString(), "sharepoint_enterprise_restore_sitecollection", "SiteCollectionID=" + this.SiteCollectionId, "ItemID=" + PanelRequest.ItemID.ToString())); - } - - - - private void RedirectToSiteCollectionsList() - { - Response.Redirect(EditUrl("SpaceID", PanelSecurity.PackageId.ToString(), "sharepoint_enterprise_sitecollections", "ItemID=" + PanelRequest.ItemID.ToString())); - } - - private bool UseSharedSLL(int packageID) - { - PackageContext cntx = ES.Services.Packages.GetPackageContext(PanelSecurity.PackageId); - if (cntx != null) - { - foreach (QuotaValueInfo quota in cntx.QuotasArray) - { - switch (quota.QuotaId) - { - case 552: - if (Convert.ToBoolean(quota.QuotaAllocatedValue)) - { - return true; - } - - break; - } - } - } - - return false; - } - - - //private void RegisterOwnerSelector() - //{ - // // Define the name and type of the client scripts on the page. - // String csname = "OwnerSelectorScript"; - // Type cstype = this.GetType(); - - // // Get a ClientScriptManager reference from the Page class. - // ClientScriptManager cs = Page.ClientScript; - - // // Check to see if the client script is already registered. - // if (!cs.IsClientScriptBlockRegistered(cstype, csname)) - // { - // StringBuilder ownerSelector = new StringBuilder(); - // ownerSelector.Append(""); - // cs.RegisterClientScriptBlock(cstype, csname, ownerSelector.ToString(), false); - // } - - //} - - //private StringDictionary ConvertArrayToDictionary(string[] settings) - //{ - // StringDictionary r = new StringDictionary(); - // foreach (string setting in settings) - // { - // int idx = setting.IndexOf('='); - // r.Add(setting.Substring(0, idx), setting.Substring(idx + 1)); - // } - // return r; - //} - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseEditSiteCollection.ascx.designer.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseEditSiteCollection.ascx.designer.cs deleted file mode 100644 index 37f5fdf5..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseEditSiteCollection.ascx.designer.cs +++ /dev/null @@ -1,447 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace WebsitePanel.Portal { - - - public partial class HostedSharePointEnterpriseEditSiteCollection { - - /// - /// asyncTasks control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.EnableAsyncTasksSupport asyncTasks; - - /// - /// Image1 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Image Image1; - - /// - /// locTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locTitle; - - /// - /// localMessageBox control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.UserControls.SimpleMessageBox localMessageBox; - - /// - /// tblEditItem control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.HtmlControls.HtmlTable tblEditItem; - - /// - /// rowUrl control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.HtmlControls.HtmlTableRow rowUrl; - - /// - /// lblSiteCollectionUrl control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblSiteCollectionUrl; - - /// - /// txtHostName control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.TextBox txtHostName; - - /// - /// domain control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.DomainsSelectDomainControl domain; - - /// - /// valRequireHostName control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.RequiredFieldValidator valRequireHostName; - - /// - /// valRequireCorrectHostName control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.RegularExpressionValidator valRequireCorrectHostName; - - /// - /// lblSiteCollectionOwner control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblSiteCollectionOwner; - - /// - /// userSelector control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.ExchangeServer.UserControls.UserSelector userSelector; - - /// - /// lblSiteCollectionLocaleID control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblSiteCollectionLocaleID; - - /// - /// ddlLocaleID control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.DropDownList ddlLocaleID; - - /// - /// lblMaxStorage control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblMaxStorage; - - /// - /// maxStorage control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.QuotaEditor maxStorage; - - /// - /// lblWarningStorage control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblWarningStorage; - - /// - /// warningStorage control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.QuotaEditor warningStorage; - - /// - /// lblTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblTitle; - - /// - /// txtTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.TextBox txtTitle; - - /// - /// valRequireTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.RequiredFieldValidator valRequireTitle; - - /// - /// lblDescription control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblDescription; - - /// - /// txtDescription control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.TextBox txtDescription; - - /// - /// RequiredFieldValidator1 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.RequiredFieldValidator RequiredFieldValidator1; - - /// - /// tblViewItem control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.HtmlControls.HtmlTable tblViewItem; - - /// - /// lblSiteCollectionUrl2 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblSiteCollectionUrl2; - - /// - /// lnkUrl control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.HyperLink lnkUrl; - - /// - /// lblSiteCollectionOwner2 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblSiteCollectionOwner2; - - /// - /// litSiteCollectionOwner control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Literal litSiteCollectionOwner; - - /// - /// lblSiteCollectionLocaleID2 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblSiteCollectionLocaleID2; - - /// - /// litLocaleID control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Literal litLocaleID; - - /// - /// lblMaxStorageView control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblMaxStorageView; - - /// - /// editMaxStorage control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.QuotaEditor editMaxStorage; - - /// - /// lblWarningStorageView control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblWarningStorageView; - - /// - /// editWarningStorage control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.QuotaEditor editWarningStorage; - - /// - /// lblTitle2 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblTitle2; - - /// - /// litTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Literal litTitle; - - /// - /// lblDescription2 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblDescription2; - - /// - /// litDescription control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Literal litDescription; - - /// - /// secMainTools control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.CollapsiblePanel secMainTools; - - /// - /// ToolsPanel control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Panel ToolsPanel; - - /// - /// tblMaintenance control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.HtmlControls.HtmlTable tblMaintenance; - - /// - /// btnBackup control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnBackup; - - /// - /// btnRestore control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnRestore; - - /// - /// btnUpdate control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnUpdate; - - /// - /// btnCancel control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnCancel; - - /// - /// btnDelete control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnDelete; - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseRestoreSiteCollection.ascx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseRestoreSiteCollection.ascx deleted file mode 100644 index cb599a87..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseRestoreSiteCollection.ascx +++ /dev/null @@ -1,101 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" Codebehind="HostedSharePointEnterpriseRestoreSiteCollection.ascx.cs" - Inherits="WebsitePanel.Portal.HostedSharePointEnterpriseRestoreSiteCollection" %> -<%@ Register Src="UserControls/FileLookup.ascx" TagName="FileLookup" TagPrefix="uc1" %> -<%@ Register Src="UserControls/SimpleMessageBox.ascx" TagName="SimpleMessageBox" - TagPrefix="wsp" %> -6 -<%@ Register Src="ExchangeServer/UserControls/Menu.ascx" TagName="Menu" TagPrefix="wsp" %> - - -<%@ Register Src="UserControls/EnableAsyncTasksSupport.ascx" TagName="EnableAsyncTasksSupport" - TagPrefix="wsp" %> - - - - - -
-
-
-
-
-
-
- - -
-
- - - - - - - - - - - - -
-
-  
- - - - - - - - - - - - - - -
- -
- -
- - - - - - - -
-
-
-
- - - - - - - -
- -
-
-
-
-
-
- - -
-
-
-
-
-
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseRestoreSiteCollection.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseRestoreSiteCollection.ascx.cs deleted file mode 100644 index 7523e6d7..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseRestoreSiteCollection.ascx.cs +++ /dev/null @@ -1,176 +0,0 @@ -// Copyright (c) 2015, Outercurve Foundation. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without modification, -// are permitted provided that the following conditions are met: -// -// - Redistributions of source code must retain the above copyright notice, this -// list of conditions and the following disclaimer. -// -// - Redistributions in binary form must reproduce the above copyright notice, -// this list of conditions and the following disclaimer in the documentation -// and/or other materials provided with the distribution. -// -// - Neither the name of the Outercurve Foundation nor the names of its -// contributors may be used to endorse or promote products derived from this -// software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR -// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -using System; -using System.Data; -using System.Configuration; -using System.Collections; -using System.IO; -using System.Web; -using System.Web.Security; -using System.Web.UI; -using System.Web.UI.WebControls; -using System.Web.UI.WebControls.WebParts; -using System.Web.UI.HtmlControls; -using WebsitePanel.Providers.SharePoint; - -namespace WebsitePanel.Portal -{ - public partial class HostedSharePointEnterpriseRestoreSiteCollection : WebsitePanelModuleBase - { - private int OrganizationId - { - get - { - return PanelRequest.GetInt("ItemID"); - } - } - - private int SiteCollectionId - { - get - { - return PanelRequest.GetInt("SiteCollectionID"); - } - } - - protected void Page_Load(object sender, EventArgs e) - { - if (!IsPostBack) - { - BindSite(); - } - } - - private void BindSite() - { - try - { - SharePointSiteCollection siteCollection = ES.Services.HostedSharePointServersEnt.Enterprise_GetSiteCollection(this.SiteCollectionId); - litSiteCollectionName.Text = siteCollection.PhysicalAddress; - fileLookup.SelectedFile = String.Empty; - fileLookup.PackageId = siteCollection.PackageId; - - ToggleControls(); - } - catch (Exception ex) - { - ShowErrorMessage("SHAREPOINT_GET_SITE", ex); - return; - } - } - - private void ToggleControls() - { - cellFile.Visible = radioFile.Checked; - cellUploadFile.Visible = radioUpload.Checked; - } - - private void RestoreSiteCollection() - { - try - { - string uploadedFile = null; - string packageFile = null; - - if (radioUpload.Checked) - { - if (uploadFile.PostedFile.FileName != "") - { - Stream stream = uploadFile.PostedFile.InputStream; - - // save uploaded file - int FILE_BUFFER_LENGTH = 5000000; - string path = null; - int readBytes = 0; - string fileName = Path.GetFileName(uploadFile.PostedFile.FileName); - - int offset = 0; - do - { - // read input stream - byte[] buffer = new byte[FILE_BUFFER_LENGTH]; - readBytes = stream.Read(buffer, 0, FILE_BUFFER_LENGTH); - - if (readBytes < FILE_BUFFER_LENGTH) - Array.Resize(ref buffer, readBytes); - - // write remote backup file - string tempPath = ES.Services.HostedSharePointServersEnt.Enterprise_AppendBackupBinaryChunk(this.SiteCollectionId, fileName, path, buffer); - if (path == null) - path = tempPath; - - offset += FILE_BUFFER_LENGTH; - } - while (readBytes == FILE_BUFFER_LENGTH); - - uploadedFile = path; - } - } - else - { - // package files - packageFile = fileLookup.SelectedFile; - } - - int result = ES.Services.HostedSharePointServersEnt.Enterprise_RestoreSiteCollection(this.SiteCollectionId, uploadedFile, packageFile); - if (result < 0) - { - ShowResultMessage(result); - return; - } - } - catch (Exception ex) - { - ShowErrorMessage("SHAREPOINT_RESTORE_SITE", ex); - return; - } - - RedirectBack(); - } - - protected void btnRestore_Click(object sender, EventArgs e) - { - RestoreSiteCollection(); - } - - protected void btnCancel_Click(object sender, EventArgs e) - { - RedirectBack(); - } - - private void RedirectBack() - { - Response.Redirect(EditUrl("SpaceID", PanelSecurity.PackageId.ToString(), "sharepoint_enterprise_edit_sitecollection", "SiteCollectionID=" + this.SiteCollectionId, "ItemID=" + PanelRequest.ItemID.ToString())); - } - protected void radioUpload_CheckedChanged(object sender, EventArgs e) - { - ToggleControls(); - } - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseRestoreSiteCollection.ascx.designer.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseRestoreSiteCollection.ascx.designer.cs deleted file mode 100644 index 444b7e6c..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseRestoreSiteCollection.ascx.designer.cs +++ /dev/null @@ -1,159 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace WebsitePanel.Portal { - - - public partial class HostedSharePointEnterpriseRestoreSiteCollection { - - /// - /// asyncTasks control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.EnableAsyncTasksSupport asyncTasks; - - /// - /// Image1 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Image Image1; - - /// - /// locTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locTitle; - - /// - /// messageBox control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.UserControls.SimpleMessageBox messageBox; - - /// - /// litSiteCollectionName control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Literal litSiteCollectionName; - - /// - /// lblRestoreFrom control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblRestoreFrom; - - /// - /// radioUpload control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.RadioButton radioUpload; - - /// - /// radioFile control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.RadioButton radioFile; - - /// - /// cellUploadFile control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.HtmlControls.HtmlTableCell cellUploadFile; - - /// - /// uploadFile control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.FileUpload uploadFile; - - /// - /// lblAllowedFiles1 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblAllowedFiles1; - - /// - /// cellFile control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.HtmlControls.HtmlTableCell cellFile; - - /// - /// fileLookup control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.FileLookup fileLookup; - - /// - /// lblAllowedFiles2 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblAllowedFiles2; - - /// - /// btnRestore control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnRestore; - - /// - /// btnCancel control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnCancel; - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseSiteCollections.ascx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseSiteCollections.ascx deleted file mode 100644 index 56d0e786..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseSiteCollections.ascx +++ /dev/null @@ -1,92 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" Codebehind="HostedSharePointEnterpriseSiteCollections.ascx.cs" - Inherits="WebsitePanel.Portal.HostedSharePointEnterpriseSiteCollections" %> -<%@ Register Src="UserControls/SpaceServiceItems.ascx" TagName="SpaceServiceItems" - TagPrefix="wsp" %> -<%@ Register Src="UserControls/SimpleMessageBox.ascx" TagName="SimpleMessageBox" - TagPrefix="wsp" %> -<%@ Register Src="UserControls/QuotaViewer.ascx" TagName="QuotaViewer" TagPrefix="wsp" %> -<%@ Register Src="UserControls/Quota.ascx" TagName="Quota" TagPrefix="wsp" %> - -<%@ Register Src="UserControls/EnableAsyncTasksSupport.ascx" TagName="EnableAsyncTasksSupport" - TagPrefix="wsp" %> - - - - - -
-
-
-
-
-
-
- - -
-
- -
-
- -
-
- - - - Url - - -
-
- - - - - - - <%# Eval("PhysicalAddress") %> - - - - - - - - - - - - - - - - - - - -
- -     - <%----%> - -
-
-
-
-
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseSiteCollections.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseSiteCollections.ascx.cs deleted file mode 100644 index 0573f900..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseSiteCollections.ascx.cs +++ /dev/null @@ -1,110 +0,0 @@ -// Copyright (c) 2015, Outercurve Foundation. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without modification, -// are permitted provided that the following conditions are met: -// -// - Redistributions of source code must retain the above copyright notice, this -// list of conditions and the following disclaimer. -// -// - Redistributions in binary form must reproduce the above copyright notice, -// this list of conditions and the following disclaimer in the documentation -// and/or other materials provided with the distribution. -// -// - Neither the name of the Outercurve Foundation nor the names of its -// contributors may be used to endorse or promote products derived from this -// software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR -// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -using System; -using System.Data; -using System.Configuration; -using System.Collections; -using System.Web; -using System.Web.Security; -using System.Web.UI; -using System.Web.UI.WebControls; -using System.Web.UI.WebControls.WebParts; -using System.Web.UI.HtmlControls; -using System.Collections.Generic; -using WebsitePanel.Providers.SharePoint; -using WebsitePanel.Providers.HostedSolution; - -namespace WebsitePanel.Portal -{ - public partial class HostedSharePointEnterpriseSiteCollections : WebsitePanelModuleBase - { - - protected void Page_Load(object sender, EventArgs e) - { - this.BindStats(); - } - - private void BindStats() - { - // quota values - OrganizationStatistics stats = ES.Services.Organizations.GetOrganizationStatisticsByOrganization(PanelRequest.ItemID); - OrganizationStatistics tenantStats = ES.Services.Organizations.GetOrganizationStatistics(PanelRequest.ItemID); - - siteCollectionsQuota.QuotaUsedValue = stats.CreatedSharePointEnterpriseSiteCollections; - siteCollectionsQuota.QuotaValue = stats.AllocatedSharePointEnterpriseSiteCollections; - if (stats.AllocatedSharePointEnterpriseSiteCollections != -1) siteCollectionsQuota.QuotaAvailable = tenantStats.AllocatedSharePointEnterpriseSiteCollections - tenantStats.CreatedSharePointEnterpriseSiteCollections; - } - - protected void btnCreateSiteCollection_Click(object sender, EventArgs e) - { - Response.Redirect(EditUrl("ItemID", PanelRequest.ItemID.ToString(), "sharepoint_enterprise_edit_sitecollection", "SpaceID=" + PanelSecurity.PackageId.ToString())); - } - - public string GetSiteCollectionEditUrl(string siteCollectionId) - { - return EditUrl("SpaceID", PanelSecurity.PackageId.ToString(), "sharepoint_enterprise_edit_sitecollection", - "SiteCollectionID=" + siteCollectionId, - "ItemID=" + PanelRequest.ItemID.ToString()); - } - - protected void odsSharePointSiteCollectionPaged_Selected(object sender, ObjectDataSourceStatusEventArgs e) - { - if (e.Exception != null) - { - messageBox.ShowErrorMessage("HOSTEDSHAREPOINT_GET_SITECOLLECTIONS", e.Exception); - e.ExceptionHandled = true; - } - } - - protected void gvSiteCollections_RowCommand(object sender, GridViewCommandEventArgs e) - { - if (e.CommandName == "DeleteItem") - { - int siteCollectionId = Utils.ParseInt(e.CommandArgument.ToString(), 0); - - try - { - int result = ES.Services.HostedSharePointServersEnt.Enterprise_DeleteSiteCollection(siteCollectionId); - if (result < 0) - { - messageBox.ShowResultMessage(result); - return; - } - - gvSiteCollections.DataBind(); - this.BindStats(); - } - catch (Exception ex) - { - messageBox.ShowErrorMessage("HOSTEDSHAREPOINT_DELETE_SITECOLLECTION", ex); - } - } - } - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseSiteCollections.ascx.designer.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseSiteCollections.ascx.designer.cs deleted file mode 100644 index 7c4bf6b7..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseSiteCollections.ascx.designer.cs +++ /dev/null @@ -1,141 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace WebsitePanel.Portal { - - - public partial class HostedSharePointEnterpriseSiteCollections { - - /// - /// asyncTasks control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.EnableAsyncTasksSupport asyncTasks; - - /// - /// Image1 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Image Image1; - - /// - /// locTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locTitle; - - /// - /// messageBox control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.UserControls.SimpleMessageBox messageBox; - - /// - /// btnCreateSiteCollection control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnCreateSiteCollection; - - /// - /// SearchPanel control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Panel SearchPanel; - - /// - /// locSearch control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locSearch; - - /// - /// ddlSearchColumn control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.DropDownList ddlSearchColumn; - - /// - /// txtSearchValue control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.TextBox txtSearchValue; - - /// - /// cmdSearch control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.ImageButton cmdSearch; - - /// - /// gvSiteCollections control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.GridView gvSiteCollections; - - /// - /// odsSiteCollectionsPaged control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.ObjectDataSource odsSiteCollectionsPaged; - - /// - /// locQuota control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locQuota; - - /// - /// siteCollectionsQuota control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.QuotaViewer siteCollectionsQuota; - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseStorageSettings.ascx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseStorageSettings.ascx deleted file mode 100644 index 21d2d979..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseStorageSettings.ascx +++ /dev/null @@ -1,62 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="HostedSharePointEnterpriseStorageSettings.ascx.cs" Inherits="WebsitePanel.Portal.HostedSharePointEnterpriseStorageSettings" %> -<%@ Register Src="UserControls/EnableAsyncTasksSupport.ascx" TagName="EnableAsyncTasksSupport" - TagPrefix="wsp" %> -<%@ Register Src="UserControls/CollapsiblePanel.ascx" TagName="CollapsiblePanel" - TagPrefix="wsp" %> -<%@ Register Src="ExchangeServer/UserControls/SizeBox.ascx" TagName="SizeBox" TagPrefix="wsp" %> -<%@ Register Src="UserControls/SimpleMessageBox.ascx" TagName="SimpleMessageBox" - TagPrefix="wsp" %> -<%@ Register Src="ExchangeServer/UserControls/Menu.ascx" TagName="Menu" TagPrefix="wsp" %> -<%@ Register src="UserControls/QuotaEditor.ascx" tagname="QuotaEditor" tagprefix="uc1" %> - - - -
-
-
-
-
-
-
- - -
-
- - - - - - - - - - - - - - - -
- -
- - -
-
-
- -
- - - -
- -
-
-
-
-
\ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseStorageSettings.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseStorageSettings.ascx.cs deleted file mode 100644 index d2b2547b..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseStorageSettings.ascx.cs +++ /dev/null @@ -1,93 +0,0 @@ -// Copyright (c) 2015, Outercurve Foundation. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without modification, -// are permitted provided that the following conditions are met: -// -// - Redistributions of source code must retain the above copyright notice, this -// list of conditions and the following disclaimer. -// -// - Redistributions in binary form must reproduce the above copyright notice, -// this list of conditions and the following disclaimer in the documentation -// and/or other materials provided with the distribution. -// -// - Neither the name of the Outercurve Foundation nor the names of its -// contributors may be used to endorse or promote products derived from this -// software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR -// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -using System; -using WebsitePanel.EnterpriseServer; -using WebsitePanel.Providers.HostedSolution; - -namespace WebsitePanel.Portal -{ - public partial class HostedSharePointEnterpriseStorageSettings : WebsitePanelModuleBase - { - protected void Page_Load(object sender, EventArgs e) - { - warningValue.UnlimitedText = GetLocalizedString("WarningUnlimitedValue"); - - - if (!IsPostBack) - { - Organization org = ES.Services.Organizations.GetOrganization(PanelRequest.ItemID); - - PackageContext cntx = ES.Services.Packages.GetPackageContext(PanelSecurity.PackageId); - foreach(QuotaValueInfo quota in cntx.QuotasArray) - { - if (quota.QuotaId == 551 /*Max storage quota*/) - { - maxStorageSettingsValue.ParentQuotaValue = quota.QuotaAllocatedValue; - warningValue.ParentQuotaValue = quota.QuotaAllocatedValue; - } - } - - maxStorageSettingsValue.QuotaValue = org.MaxSharePointEnterpriseStorage; - warningValue.QuotaValue = org.WarningSharePointEnterpriseStorage; - - } - } - - private void Save(bool apply) - { - try - { - int res = ES.Services.HostedSharePointServersEnt.Enterprise_SetStorageSettings(PanelRequest.ItemID, maxStorageSettingsValue.QuotaValue, - warningValue.QuotaValue, - apply); - if (res < 0) - { - messageBox.ShowResultMessage(res); - return; - } - messageBox.ShowSuccessMessage("HOSTED_SHAREPOINT_UPDATE_QUOTAS"); - } - catch (Exception) - { - messageBox.ShowErrorMessage("HOSTED_SHAREPOINT_UPDATE_QUOTAS"); - } - - } - - protected void btnSave_Click(object sender, EventArgs e) - { - Save(false); - } - - protected void btnSaveApply_Click(object sender, EventArgs e) - { - Save(true); - } - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseStorageSettings.ascx.designer.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseStorageSettings.ascx.designer.cs deleted file mode 100644 index 26170885..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseStorageSettings.ascx.designer.cs +++ /dev/null @@ -1,114 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace WebsitePanel.Portal { - - - public partial class HostedSharePointEnterpriseStorageSettings { - - /// - /// Image1 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Image Image1; - - /// - /// locTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locTitle; - - /// - /// messageBox control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.UserControls.SimpleMessageBox messageBox; - - /// - /// secStorageLimits control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.CollapsiblePanel secStorageLimits; - - /// - /// StorageLimits control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Panel StorageLimits; - - /// - /// locMaxStorage control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locMaxStorage; - - /// - /// maxStorageSettingsValue control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.QuotaEditor maxStorageSettingsValue; - - /// - /// locWarningStorage control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locWarningStorage; - - /// - /// warningValue control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.QuotaEditor warningValue; - - /// - /// btnSave control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnSave; - - /// - /// btnSaveApply control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnSaveApply; - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseStorageUsage.ascx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseStorageUsage.ascx deleted file mode 100644 index d4fcf361..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseStorageUsage.ascx +++ /dev/null @@ -1,57 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="HostedSharePointEnterpriseStorageUsage.ascx.cs" Inherits="WebsitePanel.Portal.HostedSharePointEnterpriseStorageUsage" %> -<%@ Register Src="UserControls/EnableAsyncTasksSupport.ascx" TagName="EnableAsyncTasksSupport" - TagPrefix="wsp" %> -<%@ Register Src="UserControls/CollapsiblePanel.ascx" TagName="CollapsiblePanel" - TagPrefix="wsp" %> -<%@ Register Src="ExchangeServer/UserControls/SizeBox.ascx" TagName="SizeBox" TagPrefix="wsp" %> -<%@ Register Src="UserControls/SimpleMessageBox.ascx" TagName="SimpleMessageBox" - TagPrefix="wsp" %> -<%@ Register Src="ExchangeServer/UserControls/Menu.ascx" TagName="Menu" TagPrefix="wsp" %> - -
-
-
-
-
-
-
- - -
-
- - - - - - - - - - - -
- - - - - - - - - -
177
100
-
-
- - -
- -
-
-
-
-
-
\ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseStorageUsage.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseStorageUsage.ascx.cs deleted file mode 100644 index efb65e5f..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseStorageUsage.ascx.cs +++ /dev/null @@ -1,94 +0,0 @@ -// Copyright (c) 2015, Outercurve Foundation. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without modification, -// are permitted provided that the following conditions are met: -// -// - Redistributions of source code must retain the above copyright notice, this -// list of conditions and the following disclaimer. -// -// - Redistributions in binary form must reproduce the above copyright notice, -// this list of conditions and the following disclaimer in the documentation -// and/or other materials provided with the distribution. -// -// - Neither the name of the Outercurve Foundation nor the names of its -// contributors may be used to endorse or promote products derived from this -// software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR -// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -using System; -using WebsitePanel.Providers.SharePoint; - -namespace WebsitePanel.Portal -{ - public partial class HostedSharePointEnterpriseStorageUsage : WebsitePanelModuleBase - { - protected void Page_Load(object sender, EventArgs e) - { - if (!IsPostBack) - BindGrid(); - } - - protected void btnRecalculateDiscSpace_Click(object sender, EventArgs e) - { - BindGrid(); - } - - private void BindGrid() - { - int errorCode; - try - { - SharePointSiteDiskSpace[] sharePointSiteDiskSpace = - ES.Services.HostedSharePointServersEnt.Enterprise_CalculateSharePointSitesDiskSpace(PanelRequest.ItemID, - out errorCode); - - - if (errorCode < 0) - { - messageBox.ShowResultMessage(errorCode); - return; - } - - if (sharePointSiteDiskSpace != null && sharePointSiteDiskSpace.Length == 1 && string.IsNullOrEmpty(sharePointSiteDiskSpace[0].Url)) - { - gvStorageUsage.DataSource = null; - gvStorageUsage.DataBind(); - lblTotalItems.Text = "0"; - lblTotalSize.Text = "0"; - return; - } - - gvStorageUsage.DataSource = sharePointSiteDiskSpace; - gvStorageUsage.DataBind(); - - if (sharePointSiteDiskSpace != null) - { - lblTotalItems.Text = sharePointSiteDiskSpace.Length.ToString(); - - long total = 0; - foreach (SharePointSiteDiskSpace current in sharePointSiteDiskSpace) - { - total += current.DiskSpace; - } - - lblTotalSize.Text = total.ToString(); - } - } - catch(Exception ex) - { - messageBox.ShowErrorMessage("HOSTED_SHAREPOINT_RECALCULATE_SIZE", ex); - } - } - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseStorageUsage.ascx.designer.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseStorageUsage.ascx.designer.cs deleted file mode 100644 index a91f43f8..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointEnterpriseStorageUsage.ascx.designer.cs +++ /dev/null @@ -1,114 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace WebsitePanel.Portal { - - - public partial class HostedSharePointEnterpriseStorageUsage { - - /// - /// Image1 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Image Image1; - - /// - /// locTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locTitle; - - /// - /// messageBox control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.UserControls.SimpleMessageBox messageBox; - - /// - /// secSiteCollectionsReport control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.CollapsiblePanel secSiteCollectionsReport; - - /// - /// siteCollectionsReport control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Panel siteCollectionsReport; - - /// - /// gvStorageUsage control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.GridView gvStorageUsage; - - /// - /// locTotalboxItems control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locTotalboxItems; - - /// - /// lblTotalItems control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblTotalItems; - - /// - /// locTotalMailboxesSize control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locTotalMailboxesSize; - - /// - /// lblTotalSize control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblTotalSize; - - /// - /// btnRecalculateDiscSpace control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnRecalculateDiscSpace; - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointRestoreSiteCollection.ascx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointRestoreSiteCollection.ascx deleted file mode 100644 index 5f3f1771..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointRestoreSiteCollection.ascx +++ /dev/null @@ -1,101 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" Codebehind="HostedSharePointRestoreSiteCollection.ascx.cs" - Inherits="WebsitePanel.Portal.HostedSharePointRestoreSiteCollection" %> -<%@ Register Src="UserControls/FileLookup.ascx" TagName="FileLookup" TagPrefix="uc1" %> -<%@ Register Src="UserControls/SimpleMessageBox.ascx" TagName="SimpleMessageBox" - TagPrefix="wsp" %> -6 -<%@ Register Src="ExchangeServer/UserControls/Menu.ascx" TagName="Menu" TagPrefix="wsp" %> - - -<%@ Register Src="UserControls/EnableAsyncTasksSupport.ascx" TagName="EnableAsyncTasksSupport" - TagPrefix="wsp" %> - - - - - -
-
-
-
-
-
-
- - -
-
- - - - - - - - - - - - -
-
-  
- - - - - - - - - - - - - - -
- -
- -
- - - - - - - -
-
-
-
- - - - - - - -
- -
-
-
-
-
-
- - -
-
-
-
-
-
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointRestoreSiteCollection.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointRestoreSiteCollection.ascx.cs deleted file mode 100644 index de33f161..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointRestoreSiteCollection.ascx.cs +++ /dev/null @@ -1,176 +0,0 @@ -// Copyright (c) 2015, Outercurve Foundation. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without modification, -// are permitted provided that the following conditions are met: -// -// - Redistributions of source code must retain the above copyright notice, this -// list of conditions and the following disclaimer. -// -// - Redistributions in binary form must reproduce the above copyright notice, -// this list of conditions and the following disclaimer in the documentation -// and/or other materials provided with the distribution. -// -// - Neither the name of the Outercurve Foundation nor the names of its -// contributors may be used to endorse or promote products derived from this -// software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR -// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -using System; -using System.Data; -using System.Configuration; -using System.Collections; -using System.IO; -using System.Web; -using System.Web.Security; -using System.Web.UI; -using System.Web.UI.WebControls; -using System.Web.UI.WebControls.WebParts; -using System.Web.UI.HtmlControls; -using WebsitePanel.Providers.SharePoint; - -namespace WebsitePanel.Portal -{ - public partial class HostedSharePointRestoreSiteCollection : WebsitePanelModuleBase - { - private int OrganizationId - { - get - { - return PanelRequest.GetInt("ItemID"); - } - } - - private int SiteCollectionId - { - get - { - return PanelRequest.GetInt("SiteCollectionID"); - } - } - - protected void Page_Load(object sender, EventArgs e) - { - if (!IsPostBack) - { - BindSite(); - } - } - - private void BindSite() - { - try - { - SharePointSiteCollection siteCollection = ES.Services.HostedSharePointServers.GetSiteCollection(this.SiteCollectionId); - litSiteCollectionName.Text = siteCollection.PhysicalAddress; - fileLookup.SelectedFile = String.Empty; - fileLookup.PackageId = siteCollection.PackageId; - - ToggleControls(); - } - catch (Exception ex) - { - ShowErrorMessage("SHAREPOINT_GET_SITE", ex); - return; - } - } - - private void ToggleControls() - { - cellFile.Visible = radioFile.Checked; - cellUploadFile.Visible = radioUpload.Checked; - } - - private void RestoreSiteCollection() - { - try - { - string uploadedFile = null; - string packageFile = null; - - if (radioUpload.Checked) - { - if (uploadFile.PostedFile.FileName != "") - { - Stream stream = uploadFile.PostedFile.InputStream; - - // save uploaded file - int FILE_BUFFER_LENGTH = 5000000; - string path = null; - int readBytes = 0; - string fileName = Path.GetFileName(uploadFile.PostedFile.FileName); - - int offset = 0; - do - { - // read input stream - byte[] buffer = new byte[FILE_BUFFER_LENGTH]; - readBytes = stream.Read(buffer, 0, FILE_BUFFER_LENGTH); - - if (readBytes < FILE_BUFFER_LENGTH) - Array.Resize(ref buffer, readBytes); - - // write remote backup file - string tempPath = ES.Services.HostedSharePointServers.AppendBackupBinaryChunk(this.SiteCollectionId, fileName, path, buffer); - if (path == null) - path = tempPath; - - offset += FILE_BUFFER_LENGTH; - } - while (readBytes == FILE_BUFFER_LENGTH); - - uploadedFile = path; - } - } - else - { - // package files - packageFile = fileLookup.SelectedFile; - } - - int result = ES.Services.HostedSharePointServers.RestoreSiteCollection(this.SiteCollectionId, uploadedFile, packageFile); - if (result < 0) - { - ShowResultMessage(result); - return; - } - } - catch (Exception ex) - { - ShowErrorMessage("SHAREPOINT_RESTORE_SITE", ex); - return; - } - - RedirectBack(); - } - - protected void btnRestore_Click(object sender, EventArgs e) - { - RestoreSiteCollection(); - } - - protected void btnCancel_Click(object sender, EventArgs e) - { - RedirectBack(); - } - - private void RedirectBack() - { - Response.Redirect(EditUrl("SpaceID", PanelSecurity.PackageId.ToString(), "sharepoint_edit_sitecollection", "SiteCollectionID=" + this.SiteCollectionId, "ItemID=" + PanelRequest.ItemID.ToString())); - } - protected void radioUpload_CheckedChanged(object sender, EventArgs e) - { - ToggleControls(); - } - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointRestoreSiteCollection.ascx.designer.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointRestoreSiteCollection.ascx.designer.cs deleted file mode 100644 index c59bec70..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointRestoreSiteCollection.ascx.designer.cs +++ /dev/null @@ -1,159 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace WebsitePanel.Portal { - - - public partial class HostedSharePointRestoreSiteCollection { - - /// - /// asyncTasks control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.EnableAsyncTasksSupport asyncTasks; - - /// - /// Image1 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Image Image1; - - /// - /// locTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locTitle; - - /// - /// messageBox control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.UserControls.SimpleMessageBox messageBox; - - /// - /// litSiteCollectionName control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Literal litSiteCollectionName; - - /// - /// lblRestoreFrom control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblRestoreFrom; - - /// - /// radioUpload control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.RadioButton radioUpload; - - /// - /// radioFile control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.RadioButton radioFile; - - /// - /// cellUploadFile control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.HtmlControls.HtmlTableCell cellUploadFile; - - /// - /// uploadFile control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.FileUpload uploadFile; - - /// - /// lblAllowedFiles1 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblAllowedFiles1; - - /// - /// cellFile control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.HtmlControls.HtmlTableCell cellFile; - - /// - /// fileLookup control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.FileLookup fileLookup; - - /// - /// lblAllowedFiles2 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblAllowedFiles2; - - /// - /// btnRestore control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnRestore; - - /// - /// btnCancel control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnCancel; - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointSiteCollections.ascx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointSiteCollections.ascx deleted file mode 100644 index 2e6b6269..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointSiteCollections.ascx +++ /dev/null @@ -1,92 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" Codebehind="HostedSharePointSiteCollections.ascx.cs" - Inherits="WebsitePanel.Portal.HostedSharePointSiteCollections" %> -<%@ Register Src="UserControls/SpaceServiceItems.ascx" TagName="SpaceServiceItems" - TagPrefix="wsp" %> -<%@ Register Src="UserControls/SimpleMessageBox.ascx" TagName="SimpleMessageBox" - TagPrefix="wsp" %> -<%@ Register Src="UserControls/QuotaViewer.ascx" TagName="QuotaViewer" TagPrefix="wsp" %> -<%@ Register Src="UserControls/Quota.ascx" TagName="Quota" TagPrefix="wsp" %> - -<%@ Register Src="UserControls/EnableAsyncTasksSupport.ascx" TagName="EnableAsyncTasksSupport" - TagPrefix="wsp" %> - - - - - -
-
-
-
-
-
-
- - -
-
- -
-
- -
-
- - - - Url - - -
-
- - - - - - - <%# Eval("PhysicalAddress") %> - - - - - - - - - - - - - - - - - - - -
- -     - <%----%> - -
-
-
-
-
diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointSiteCollections.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointSiteCollections.ascx.cs deleted file mode 100644 index b03fd0f0..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointSiteCollections.ascx.cs +++ /dev/null @@ -1,110 +0,0 @@ -// Copyright (c) 2015, Outercurve Foundation. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without modification, -// are permitted provided that the following conditions are met: -// -// - Redistributions of source code must retain the above copyright notice, this -// list of conditions and the following disclaimer. -// -// - Redistributions in binary form must reproduce the above copyright notice, -// this list of conditions and the following disclaimer in the documentation -// and/or other materials provided with the distribution. -// -// - Neither the name of the Outercurve Foundation nor the names of its -// contributors may be used to endorse or promote products derived from this -// software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR -// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -using System; -using System.Data; -using System.Configuration; -using System.Collections; -using System.Web; -using System.Web.Security; -using System.Web.UI; -using System.Web.UI.WebControls; -using System.Web.UI.WebControls.WebParts; -using System.Web.UI.HtmlControls; -using System.Collections.Generic; -using WebsitePanel.Providers.SharePoint; -using WebsitePanel.Providers.HostedSolution; - -namespace WebsitePanel.Portal -{ - public partial class HostedSharePointSiteCollections : WebsitePanelModuleBase - { - - protected void Page_Load(object sender, EventArgs e) - { - this.BindStats(); - } - - private void BindStats() - { - // quota values - OrganizationStatistics stats = ES.Services.Organizations.GetOrganizationStatisticsByOrganization(PanelRequest.ItemID); - OrganizationStatistics tenantStats = ES.Services.Organizations.GetOrganizationStatistics(PanelRequest.ItemID); - - siteCollectionsQuota.QuotaUsedValue = stats.CreatedSharePointSiteCollections; - siteCollectionsQuota.QuotaValue = stats.AllocatedSharePointSiteCollections; - if (stats.AllocatedSharePointSiteCollections != -1) siteCollectionsQuota.QuotaAvailable = tenantStats.AllocatedSharePointSiteCollections - tenantStats.CreatedSharePointSiteCollections; - } - - protected void btnCreateSiteCollection_Click(object sender, EventArgs e) - { - Response.Redirect(EditUrl("ItemID", PanelRequest.ItemID.ToString(), "sharepoint_edit_sitecollection", "SpaceID=" + PanelSecurity.PackageId.ToString())); - } - - public string GetSiteCollectionEditUrl(string siteCollectionId) - { - return EditUrl("SpaceID", PanelSecurity.PackageId.ToString(), "sharepoint_edit_sitecollection", - "SiteCollectionID=" + siteCollectionId, - "ItemID=" + PanelRequest.ItemID.ToString()); - } - - protected void odsSharePointSiteCollectionPaged_Selected(object sender, ObjectDataSourceStatusEventArgs e) - { - if (e.Exception != null) - { - messageBox.ShowErrorMessage("HOSTEDSHAREPOINT_GET_SITECOLLECTIONS", e.Exception); - e.ExceptionHandled = true; - } - } - - protected void gvSiteCollections_RowCommand(object sender, GridViewCommandEventArgs e) - { - if (e.CommandName == "DeleteItem") - { - int siteCollectionId = Utils.ParseInt(e.CommandArgument.ToString(), 0); - - try - { - int result = ES.Services.HostedSharePointServers.DeleteSiteCollection(siteCollectionId); - if (result < 0) - { - messageBox.ShowResultMessage(result); - return; - } - - gvSiteCollections.DataBind(); - this.BindStats(); - } - catch (Exception ex) - { - messageBox.ShowErrorMessage("HOSTEDSHAREPOINT_DELETE_SITECOLLECTION", ex); - } - } - } - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointSiteCollections.ascx.designer.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointSiteCollections.ascx.designer.cs deleted file mode 100644 index 2e8763e8..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointSiteCollections.ascx.designer.cs +++ /dev/null @@ -1,141 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace WebsitePanel.Portal { - - - public partial class HostedSharePointSiteCollections { - - /// - /// asyncTasks control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.EnableAsyncTasksSupport asyncTasks; - - /// - /// Image1 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Image Image1; - - /// - /// locTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locTitle; - - /// - /// messageBox control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.UserControls.SimpleMessageBox messageBox; - - /// - /// btnCreateSiteCollection control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnCreateSiteCollection; - - /// - /// SearchPanel control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Panel SearchPanel; - - /// - /// locSearch control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locSearch; - - /// - /// ddlSearchColumn control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.DropDownList ddlSearchColumn; - - /// - /// txtSearchValue control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.TextBox txtSearchValue; - - /// - /// cmdSearch control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.ImageButton cmdSearch; - - /// - /// gvSiteCollections control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.GridView gvSiteCollections; - - /// - /// odsSiteCollectionsPaged control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.ObjectDataSource odsSiteCollectionsPaged; - - /// - /// locQuota control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locQuota; - - /// - /// siteCollectionsQuota control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.QuotaViewer siteCollectionsQuota; - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointStorageSettings.ascx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointStorageSettings.ascx deleted file mode 100644 index f11df6ad..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointStorageSettings.ascx +++ /dev/null @@ -1,62 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="HostedSharePointStorageSettings.ascx.cs" Inherits="WebsitePanel.Portal.HostedSharePointStorageSettings" %> -<%@ Register Src="UserControls/EnableAsyncTasksSupport.ascx" TagName="EnableAsyncTasksSupport" - TagPrefix="wsp" %> -<%@ Register Src="UserControls/CollapsiblePanel.ascx" TagName="CollapsiblePanel" - TagPrefix="wsp" %> -<%@ Register Src="ExchangeServer/UserControls/SizeBox.ascx" TagName="SizeBox" TagPrefix="wsp" %> -<%@ Register Src="UserControls/SimpleMessageBox.ascx" TagName="SimpleMessageBox" - TagPrefix="wsp" %> -<%@ Register Src="ExchangeServer/UserControls/Menu.ascx" TagName="Menu" TagPrefix="wsp" %> -<%@ Register src="UserControls/QuotaEditor.ascx" tagname="QuotaEditor" tagprefix="uc1" %> - - - -
-
-
-
-
-
-
- - -
-
- - - - - - - - - - - - - - - -
- -
- - -
-
-
- -
- - - -
- -
-
-
-
-
\ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointStorageSettings.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointStorageSettings.ascx.cs deleted file mode 100644 index 52e86521..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointStorageSettings.ascx.cs +++ /dev/null @@ -1,93 +0,0 @@ -// Copyright (c) 2015, Outercurve Foundation. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without modification, -// are permitted provided that the following conditions are met: -// -// - Redistributions of source code must retain the above copyright notice, this -// list of conditions and the following disclaimer. -// -// - Redistributions in binary form must reproduce the above copyright notice, -// this list of conditions and the following disclaimer in the documentation -// and/or other materials provided with the distribution. -// -// - Neither the name of the Outercurve Foundation nor the names of its -// contributors may be used to endorse or promote products derived from this -// software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR -// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -using System; -using WebsitePanel.EnterpriseServer; -using WebsitePanel.Providers.HostedSolution; - -namespace WebsitePanel.Portal -{ - public partial class HostedSharePointStorageSettings : WebsitePanelModuleBase - { - protected void Page_Load(object sender, EventArgs e) - { - warningValue.UnlimitedText = GetLocalizedString("WarningUnlimitedValue"); - - - if (!IsPostBack) - { - Organization org = ES.Services.Organizations.GetOrganization(PanelRequest.ItemID); - - PackageContext cntx = ES.Services.Packages.GetPackageContext(PanelSecurity.PackageId); - foreach(QuotaValueInfo quota in cntx.QuotasArray) - { - if (quota.QuotaId == 208 /*Max storage quota*/) - { - maxStorageSettingsValue.ParentQuotaValue = quota.QuotaAllocatedValue; - warningValue.ParentQuotaValue = quota.QuotaAllocatedValue; - } - } - - maxStorageSettingsValue.QuotaValue = org.MaxSharePointStorage; - warningValue.QuotaValue = org.WarningSharePointStorage; - - } - } - - private void Save(bool apply) - { - try - { - int res = ES.Services.HostedSharePointServers.SetStorageSettings(PanelRequest.ItemID, maxStorageSettingsValue.QuotaValue, - warningValue.QuotaValue, - apply); - if (res < 0) - { - messageBox.ShowResultMessage(res); - return; - } - messageBox.ShowSuccessMessage("HOSTED_SHAREPOINT_UPDATE_QUOTAS"); - } - catch (Exception) - { - messageBox.ShowErrorMessage("HOSTED_SHAREPOINT_UPDATE_QUOTAS"); - } - - } - - protected void btnSave_Click(object sender, EventArgs e) - { - Save(false); - } - - protected void btnSaveApply_Click(object sender, EventArgs e) - { - Save(true); - } - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointStorageSettings.ascx.designer.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointStorageSettings.ascx.designer.cs deleted file mode 100644 index 04b5be91..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointStorageSettings.ascx.designer.cs +++ /dev/null @@ -1,114 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace WebsitePanel.Portal { - - - public partial class HostedSharePointStorageSettings { - - /// - /// Image1 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Image Image1; - - /// - /// locTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locTitle; - - /// - /// messageBox control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.UserControls.SimpleMessageBox messageBox; - - /// - /// secStorageLimits control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.CollapsiblePanel secStorageLimits; - - /// - /// StorageLimits control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Panel StorageLimits; - - /// - /// locMaxStorage control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locMaxStorage; - - /// - /// maxStorageSettingsValue control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.QuotaEditor maxStorageSettingsValue; - - /// - /// locWarningStorage control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locWarningStorage; - - /// - /// warningValue control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.QuotaEditor warningValue; - - /// - /// btnSave control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnSave; - - /// - /// btnSaveApply control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnSaveApply; - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointStorageUsage.ascx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointStorageUsage.ascx deleted file mode 100644 index 317c2138..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointStorageUsage.ascx +++ /dev/null @@ -1,57 +0,0 @@ -<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="HostedSharePointStorageUsage.ascx.cs" Inherits="WebsitePanel.Portal.HostedSharePointStorageUsage" %> -<%@ Register Src="UserControls/EnableAsyncTasksSupport.ascx" TagName="EnableAsyncTasksSupport" - TagPrefix="wsp" %> -<%@ Register Src="UserControls/CollapsiblePanel.ascx" TagName="CollapsiblePanel" - TagPrefix="wsp" %> -<%@ Register Src="ExchangeServer/UserControls/SizeBox.ascx" TagName="SizeBox" TagPrefix="wsp" %> -<%@ Register Src="UserControls/SimpleMessageBox.ascx" TagName="SimpleMessageBox" - TagPrefix="wsp" %> -<%@ Register Src="ExchangeServer/UserControls/Menu.ascx" TagName="Menu" TagPrefix="wsp" %> - -
-
-
-
-
-
-
- - -
-
- - - - - - - - - - - -
- - - - - - - - - -
177
100
-
-
- - -
- -
-
-
-
-
-
\ No newline at end of file diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointStorageUsage.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointStorageUsage.ascx.cs deleted file mode 100644 index c18a2e4f..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointStorageUsage.ascx.cs +++ /dev/null @@ -1,94 +0,0 @@ -// Copyright (c) 2015, Outercurve Foundation. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without modification, -// are permitted provided that the following conditions are met: -// -// - Redistributions of source code must retain the above copyright notice, this -// list of conditions and the following disclaimer. -// -// - Redistributions in binary form must reproduce the above copyright notice, -// this list of conditions and the following disclaimer in the documentation -// and/or other materials provided with the distribution. -// -// - Neither the name of the Outercurve Foundation nor the names of its -// contributors may be used to endorse or promote products derived from this -// software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR -// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - -using System; -using WebsitePanel.Providers.SharePoint; - -namespace WebsitePanel.Portal -{ - public partial class HostedSharePointStorageUsage : WebsitePanelModuleBase - { - protected void Page_Load(object sender, EventArgs e) - { - if (!IsPostBack) - BindGrid(); - } - - protected void btnRecalculateDiscSpace_Click(object sender, EventArgs e) - { - BindGrid(); - } - - private void BindGrid() - { - int errorCode; - try - { - SharePointSiteDiskSpace[] sharePointSiteDiskSpace = - ES.Services.HostedSharePointServers.CalculateSharePointSitesDiskSpace(PanelRequest.ItemID, - out errorCode); - - - if (errorCode < 0) - { - messageBox.ShowResultMessage(errorCode); - return; - } - - if (sharePointSiteDiskSpace != null && sharePointSiteDiskSpace.Length == 1 && string.IsNullOrEmpty(sharePointSiteDiskSpace[0].Url)) - { - gvStorageUsage.DataSource = null; - gvStorageUsage.DataBind(); - lblTotalItems.Text = "0"; - lblTotalSize.Text = "0"; - return; - } - - gvStorageUsage.DataSource = sharePointSiteDiskSpace; - gvStorageUsage.DataBind(); - - if (sharePointSiteDiskSpace != null) - { - lblTotalItems.Text = sharePointSiteDiskSpace.Length.ToString(); - - long total = 0; - foreach (SharePointSiteDiskSpace current in sharePointSiteDiskSpace) - { - total += current.DiskSpace; - } - - lblTotalSize.Text = total.ToString(); - } - } - catch(Exception ex) - { - messageBox.ShowErrorMessage("HOSTED_SHAREPOINT_RECALCULATE_SIZE", ex); - } - } - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointStorageUsage.ascx.designer.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointStorageUsage.ascx.designer.cs deleted file mode 100644 index 4c003393..00000000 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/HostedSharePointStorageUsage.ascx.designer.cs +++ /dev/null @@ -1,114 +0,0 @@ -//------------------------------------------------------------------------------ -// -// This code was generated by a tool. -// -// Changes to this file may cause incorrect behavior and will be lost if -// the code is regenerated. -// -//------------------------------------------------------------------------------ - -namespace WebsitePanel.Portal { - - - public partial class HostedSharePointStorageUsage { - - /// - /// Image1 control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Image Image1; - - /// - /// locTitle control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locTitle; - - /// - /// messageBox control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.UserControls.SimpleMessageBox messageBox; - - /// - /// secSiteCollectionsReport control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::WebsitePanel.Portal.CollapsiblePanel secSiteCollectionsReport; - - /// - /// siteCollectionsReport control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Panel siteCollectionsReport; - - /// - /// gvStorageUsage control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.GridView gvStorageUsage; - - /// - /// locTotalboxItems control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locTotalboxItems; - - /// - /// lblTotalItems control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblTotalItems; - - /// - /// locTotalMailboxesSize control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Localize locTotalMailboxesSize; - - /// - /// lblTotalSize control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Label lblTotalSize; - - /// - /// btnRecalculateDiscSpace control. - /// - /// - /// Auto-generated field. - /// To modify move field declaration from designer file to code-behind file. - /// - protected global::System.Web.UI.WebControls.Button btnRecalculateDiscSpace; - } -} diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SpaceQuotas.ascx b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SpaceQuotas.ascx index b52a64b4..dcd883a4 100644 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SpaceQuotas.ascx +++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SpaceQuotas.ascx @@ -74,6 +74,11 @@ + + + + + diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SpaceQuotas.ascx.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SpaceQuotas.ascx.cs index 0f4cd791..76eb4338 100644 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SpaceQuotas.ascx.cs +++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SpaceQuotas.ascx.cs @@ -67,6 +67,7 @@ namespace WebsitePanel.Portal { "quotaLyncUsers", "pnlLyncUsers" }, { "quotaBlackBerryUsers", "pnlBlackBerryUsers" }, { "quotaSharepointSites", "pnlSharepointSites" }, + { "quotaSharepointEnterpriseSites", "pnlSharepointEnterpriseSites" }, { "quotaWebSites", "pnlWebSites" }, { "quotaDatabases", "pnlDatabases" }, { "quotaNumberOfVm", "pnlHyperVForPC" }, diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SpaceQuotas.ascx.designer.cs b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SpaceQuotas.ascx.designer.cs index fbb13a74..4c46ce4f 100644 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SpaceQuotas.ascx.designer.cs +++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/SpaceQuotas.ascx.designer.cs @@ -1,31 +1,3 @@ -// Copyright (c) 2015, Outercurve Foundation. -// All rights reserved. -// -// Redistribution and use in source and binary forms, with or without modification, -// are permitted provided that the following conditions are met: -// -// - Redistributions of source code must retain the above copyright notice, this -// list of conditions and the following disclaimer. -// -// - Redistributions in binary form must reproduce the above copyright notice, -// this list of conditions and the following disclaimer in the documentation -// and/or other materials provided with the distribution. -// -// - Neither the name of the Outercurve Foundation nor the names of its -// contributors may be used to endorse or promote products derived from this -// software without specific prior written permission. -// -// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND -// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR -// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; -// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - //------------------------------------------------------------------------------ // // This code was generated by a tool. @@ -454,6 +426,33 @@ namespace WebsitePanel.Portal { /// protected global::WebsitePanel.Portal.Quota quotaSharepointSites; + /// + /// pnlSharepointEnterpriseSites control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.HtmlControls.HtmlTableRow pnlSharepointEnterpriseSites; + + /// + /// Label2 control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.Label Label2; + + /// + /// quotaSharepointEnterpriseSites control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::WebsitePanel.Portal.Quota quotaSharepointEnterpriseSites; + /// /// pnlWebSites control. /// diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/WebsitePanel.Portal.Modules.csproj b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/WebsitePanel.Portal.Modules.csproj index 6d782e5d..87046bd1 100644 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/WebsitePanel.Portal.Modules.csproj +++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/DesktopModules/WebsitePanel/WebsitePanel.Portal.Modules.csproj @@ -259,46 +259,46 @@ EnterpriseStorageOwaUsersList.ascx - + HostedSharePointEnterpriseBackupSiteCollection.ascx ASPXCodeBehind - + HostedSharePointEnterpriseBackupSiteCollection.ascx - + HostedSharePointEnterpriseEditSiteCollection.ascx ASPXCodeBehind - + HostedSharePointEnterpriseEditSiteCollection.ascx - + HostedSharePointEnterpriseSiteCollections.ascx ASPXCodeBehind - + HostedSharePointEnterpriseSiteCollections.ascx - + HostedSharePointEnterpriseRestoreSiteCollection.ascx ASPXCodeBehind - + HostedSharePointEnterpriseRestoreSiteCollection.ascx - + HostedSharePointEnterpriseStorageSettings.ascx ASPXCodeBehind - + HostedSharePointEnterpriseStorageSettings.ascx - + HostedSharePointEnterpriseStorageUsage.ascx ASPXCodeBehind - + HostedSharePointEnterpriseStorageUsage.ascx @@ -1521,46 +1521,46 @@ UserSelector.ascx - + HostedSharePointBackupSiteCollection.ascx ASPXCodeBehind - + HostedSharePointBackupSiteCollection.ascx - + HostedSharePointEditSiteCollection.ascx ASPXCodeBehind - + HostedSharePointEditSiteCollection.ascx - + HostedSharePointRestoreSiteCollection.ascx ASPXCodeBehind - + HostedSharePointRestoreSiteCollection.ascx - + HostedSharePointSiteCollections.ascx ASPXCodeBehind - + HostedSharePointSiteCollections.ascx - + HostedSharePointStorageSettings.ascx ASPXCodeBehind - + HostedSharePointStorageSettings.ascx - + HostedSharePointStorageUsage.ascx ASPXCodeBehind - + HostedSharePointStorageUsage.ascx @@ -4581,12 +4581,12 @@ - - - - - - + + + + + + @@ -4645,22 +4645,22 @@ Designer - + Designer - + Designer - + Designer - + Designer - + Designer - + Designer @@ -6206,12 +6206,12 @@ - - - - - - + + + + + + @@ -6245,7 +6245,7 @@ - + Designer @@ -6253,7 +6253,7 @@ - + Designer @@ -6679,16 +6679,16 @@ Designer - + Designer - + Designer - + Designer - + Designer diff --git a/WebsitePanel/Sources/WebsitePanel.WebPortal/WebsitePanel.WebPortal.csproj b/WebsitePanel/Sources/WebsitePanel.WebPortal/WebsitePanel.WebPortal.csproj index 4b3119cd..eb62f9b5 100644 --- a/WebsitePanel/Sources/WebsitePanel.WebPortal/WebsitePanel.WebPortal.csproj +++ b/WebsitePanel/Sources/WebsitePanel.WebPortal/WebsitePanel.WebPortal.csproj @@ -313,7 +313,9 @@ Designer - + + Designer +