fixed bugs
This commit is contained in:
parent
8784e493d5
commit
ff9e257362
14 changed files with 55 additions and 118 deletions
|
@ -120,11 +120,8 @@
|
|||
<data name="chkEnableHardQuota.Text" xml:space="preserve">
|
||||
<value>Enable Hard Quota:</value>
|
||||
</data>
|
||||
<data name="lblLocationDrive.Text" xml:space="preserve">
|
||||
<value>Location Drive:</value>
|
||||
</data>
|
||||
<data name="lblSpacesFolder.Text" xml:space="preserve">
|
||||
<value>Enterprise Storage Folder:</value>
|
||||
<value>Enterprise Storage Path:</value>
|
||||
</data>
|
||||
<data name="lblDomain.Text" xml:space="preserve">
|
||||
<value>Enterprise Storage Domain:</value>
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
<table cellpadding="1" cellspacing="0" width="100%">
|
||||
<tr>
|
||||
<td class="SubHead" width="200" nowrap>
|
||||
<asp:Label ID="lblSpacesFolder" runat="server" meta:resourcekey="lblSpacesFolder" Text="User Packages Folder:"></asp:Label>
|
||||
<asp:Label ID="lblSpacesFolder" runat="server" meta:resourcekey="lblSpacesFolder" Text="User Packages Path:"></asp:Label>
|
||||
</td>
|
||||
<td width="100%">
|
||||
<asp:TextBox runat="server" ID="txtFolder" Width="300px" CssClass="NormalTextBox"></asp:TextBox></td>
|
||||
|
@ -17,17 +17,6 @@
|
|||
ErrorMessage="*"></asp:RequiredFieldValidator>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="SubHead" width="200" nowrap>
|
||||
<asp:Label ID="lblLocationDrive" runat="server" meta:resourcekey="lblLocationDrive" Text="Location Drive:"></asp:Label>
|
||||
</td>
|
||||
<td width="100%">
|
||||
<asp:TextBox runat="server" ID="txtLocationDrive" Width="50px" MaxLength="1" CssClass="NormalTextBox"></asp:TextBox>
|
||||
<asp:RequiredFieldValidator ID="valLocationDrive" runat="server" ControlToValidate="txtLocationDrive"
|
||||
ErrorMessage="*"></asp:RequiredFieldValidator>
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="SubHead" width="200" nowrap></td>
|
||||
<td width="100%">
|
||||
|
|
|
@ -49,8 +49,7 @@ namespace WebsitePanel.Portal.ProviderControls
|
|||
try
|
||||
{
|
||||
chkEnableHardQuota.Enabled = ES.Services.EnterpriseStorage.CheckFileServicesInstallation(PanelRequest.ServiceId);
|
||||
txtLocationDrive.Enabled = chkEnableHardQuota.Enabled;
|
||||
valLocationDrive.Enabled = chkEnableHardQuota.Enabled;
|
||||
txtFolder.Enabled = chkEnableHardQuota.Enabled;
|
||||
if (!chkEnableHardQuota.Enabled)
|
||||
lblFileServiceInfo.Visible = true;
|
||||
}
|
||||
|
@ -62,18 +61,25 @@ namespace WebsitePanel.Portal.ProviderControls
|
|||
|
||||
public void BindSettings(StringDictionary settings)
|
||||
{
|
||||
txtFolder.Text = settings["UsersHome"];
|
||||
txtLocationDrive.Text = settings["LocationDrive"];
|
||||
string path = string.Format("{0}:\\{1}", settings["LocationDrive"], settings["UsersHome"]);
|
||||
|
||||
txtFolder.Text = path;
|
||||
txtDomain.Text = settings["UsersDomain"];
|
||||
chkEnableHardQuota.Checked = settings["EnableHardQuota"] == "true" ? true : false;
|
||||
}
|
||||
|
||||
public void SaveSettings(StringDictionary settings)
|
||||
{
|
||||
settings["UsersHome"] = txtFolder.Text;
|
||||
settings["LocationDrive"] = txtLocationDrive.Text;
|
||||
settings["UsersDomain"] = txtDomain.Text;
|
||||
settings["EnableHardQuota"] = chkEnableHardQuota.Checked.ToString().ToLower();
|
||||
var drive = System.IO.Path.GetPathRoot(txtFolder.Text);
|
||||
var folder = txtFolder.Text.Replace(drive, string.Empty);
|
||||
|
||||
if (!string.IsNullOrEmpty(drive) && !string.IsNullOrEmpty(folder))
|
||||
{
|
||||
settings["LocationDrive"] = drive.Split(':')[0];
|
||||
settings["UsersHome"] = folder;
|
||||
settings["UsersDomain"] = txtDomain.Text;
|
||||
settings["EnableHardQuota"] = chkEnableHardQuota.Checked.ToString().ToLower();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
|
@ -57,33 +57,6 @@ namespace WebsitePanel.Portal.ProviderControls {
|
|||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator valDomain;
|
||||
|
||||
/// <summary>
|
||||
/// lblLocationDrive control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.Label lblLocationDrive;
|
||||
|
||||
/// <summary>
|
||||
/// txtLocationDrive control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txtLocationDrive;
|
||||
|
||||
/// <summary>
|
||||
/// valLocationDrive control.
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// Auto-generated field.
|
||||
/// To modify move field declaration from designer file to code-behind file.
|
||||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.RequiredFieldValidator valLocationDrive;
|
||||
|
||||
/// <summary>
|
||||
/// chkEnableHardQuota control.
|
||||
/// </summary>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue