This commit is contained in:
Virtuworks 2013-11-05 18:40:19 -05:00
commit cf889bd90c
65 changed files with 15351 additions and 8460 deletions

View file

@ -29,6 +29,7 @@
using System;
using System.Collections;
using WebsitePanel.Providers.OS;
using WebsitePanel.Providers.Web;
namespace WebsitePanel.Providers.EnterpriseStorage
{
@ -38,10 +39,13 @@ namespace WebsitePanel.Providers.EnterpriseStorage
public interface IEnterpriseStorage
{
SystemFile[] GetFolders(string organizationId);
SystemFile GetFolder(string organizationId, string folder);
SystemFile GetFolder(string organizationId, string folderName);
void CreateFolder(string organizationId, string folder);
SystemFile RenameFolder(string organizationId, string originalFolder, string newFolder);
void DeleteFolder(string organizationId, string folder);
void SetFolderQuota(string organizationId, string folder, long quota);
bool SetFolderWebDavRules(string organizationId, string folder, WebDavFolderRule[] rules);
WebDavFolderRule[] GetFolderWebDavRules(string organizationId, string folder);
bool CheckFileServicesInstallation();
}
}

View file

@ -27,7 +27,7 @@
// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
using System;
using WebsitePanel.Providers.Web;
namespace WebsitePanel.Providers.OS
{
/// <summary>
@ -44,6 +44,8 @@ namespace WebsitePanel.Providers.OS
private long quota;
private bool isEmpty;
private bool isPublished;
private WebDavFolderRule[] rules;
private string url;
public SystemFile()
{
@ -108,5 +110,16 @@ namespace WebsitePanel.Providers.OS
set { this.isPublished = value; }
}
public WebDavFolderRule[] Rules
{
get { return this.rules; }
set { this.rules = value; }
}
public string Url
{
get { return this.url; }
set { this.url = value; }
}
}
}

View file

@ -0,0 +1,20 @@
namespace WebsitePanel.Providers.OS
{
public class SystemFilesPaged
{
int recordsCount;
SystemFile[] pageItems;
public int RecordsCount
{
get { return this.recordsCount; }
set { this.recordsCount = value; }
}
public SystemFile[] PageItems
{
get { return this.pageItems; }
set { this.pageItems = value; }
}
}
}

View file

@ -0,0 +1,17 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using WebsitePanel.Providers.HostedSolution;
namespace WebsitePanel.Providers.Web
{
public interface IWebDav
{
void CreateWebDavRule(string organizationId, string folder, WebDavFolderRule rule);
bool DeleteWebDavRule(string organizationId, string folder, WebDavFolderRule rule);
bool DeleteAllWebDavRules(string organizationId, string folder);
bool SetFolderWebDavRules(string organizationId, string folder, WebDavFolderRule[] newRules);
WebDavFolderRule[] GetFolderWebDavRules(string organizationId, string folder);
}
}

View file

@ -32,6 +32,8 @@ using WebsitePanel.Providers.HostedSolution;
using WebsitePanel.Providers.ResultObjects;
using WebsitePanel.Providers.WebAppGallery;
using WebsitePanel.Providers.Common;
using Microsoft.Web.Administration;
using Microsoft.Web.Management.Server;
namespace WebsitePanel.Providers.Web
{
@ -166,6 +168,8 @@ namespace WebsitePanel.Providers.Web
SSLCertificate ImportCertificate(WebSite website);
bool CheckCertificate(WebSite webSite);
//Directory Browseing
bool GetDirectoryBrowseEnabled(string siteId);
void SetDirectoryBrowseEnabled(string siteId, bool enabled);
}
}

View file

@ -0,0 +1,60 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using WebsitePanel.Providers.HostedSolution;
namespace WebsitePanel.Providers.Web
{
public enum WebDavAccess
{
Read = 1,
Source = 16,
Write = 2
}
[Serializable]
public class WebDavFolderRule
{
public List<string> Pathes { get; set; }
public List<string> Users { get; set; }
public List<string> Roles { get; set; }
public int AccessRights
{
get
{
int result = 0;
if (Read)
{
result |= (int)WebDavAccess.Read;
}
if (Write)
{
result |= (int)WebDavAccess.Write;
}
if (Source)
{
result |= (int)WebDavAccess.Source;
}
return result;
}
}
public bool Read { get; set; }
public bool Write { get; set; }
public bool Source { get; set; }
public WebDavFolderRule()
{
Pathes = new List<string>();
Users = new List<string>();
Roles = new List<string>();
}
}
}

View file

@ -57,6 +57,14 @@
<WarningsAsErrors>618</WarningsAsErrors>
</PropertyGroup>
<ItemGroup>
<Reference Include="Microsoft.Web.Administration, Version=7.9.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\Lib\References\Microsoft\Microsoft.Web.Administration.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Web.Management, Version=7.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\Lib\References\Microsoft\Microsoft.Web.Management.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Data" />
<Reference Include="System.DirectoryServices" />
@ -105,6 +113,7 @@
<Compile Include="HostedSolution\LyncVoicePolicyType.cs" />
<Compile Include="HostedSolution\OrganizationSecurityGroup.cs" />
<Compile Include="HostedSolution\TransactionAction.cs" />
<Compile Include="OS\SystemFilesPaged.cs" />
<Compile Include="RemoteDesktopServices\IRemoteDesktopServices.cs" />
<Compile Include="ResultObjects\HeliconApe.cs" />
<Compile Include="HostedSolution\ExchangeMobileDevice.cs" />
@ -315,10 +324,12 @@
<Compile Include="Web\HtaccessFolder.cs" />
<Compile Include="Web\HttpError.cs" />
<Compile Include="Web\HttpHeader.cs" />
<Compile Include="Web\IWebDav.cs" />
<Compile Include="Web\IWebServer.cs" />
<Compile Include="Web\MimeMap.cs" />
<Compile Include="Web\SharedSSLFolder.cs" />
<Compile Include="Web\SSLCertificate.cs" />
<Compile Include="Web\WebDavFolderRule.cs" />
<Compile Include="Web\WebFolder.cs" />
<Compile Include="Web\WebGroup.cs" />
<Compile Include="Web\WebSite.cs" />