Merge
This commit is contained in:
commit
e2d14ea312
2 changed files with 35 additions and 1 deletions
|
@ -62,6 +62,13 @@ namespace WebsitePanel.Portal
|
|||
set { ViewState["HideMailDomains"] = value; }
|
||||
}
|
||||
|
||||
public bool HideMailDomainPointers
|
||||
{
|
||||
get { return (ViewState["HideMailDomainPointers"] != null) ? (bool)ViewState["HideMailDomainPointers"] : false; }
|
||||
set { ViewState["HideMailDomainPointers"] = value; }
|
||||
}
|
||||
|
||||
|
||||
public bool HideDomainPointers
|
||||
{
|
||||
get { return (ViewState["HideDomainPointers"] != null) ? (bool)ViewState["HideDomainPointers"] : false; }
|
||||
|
@ -111,6 +118,7 @@ namespace WebsitePanel.Portal
|
|||
|
||||
WebSite[] sites = null;
|
||||
Hashtable htSites = new Hashtable();
|
||||
Hashtable htMailDomainPointers = new Hashtable();
|
||||
if (HideWebSites)
|
||||
{
|
||||
sites = ES.Services.WebServers.GetWebSites(PackageId, false);
|
||||
|
@ -127,6 +135,25 @@ namespace WebsitePanel.Portal
|
|||
}
|
||||
}
|
||||
|
||||
if (HideMailDomainPointers)
|
||||
{
|
||||
Providers.Mail.MailDomain[] mailDomains = ES.Services.MailServers.GetMailDomains(PackageId, false);
|
||||
|
||||
foreach (Providers.Mail.MailDomain mailDomain in mailDomains)
|
||||
{
|
||||
DomainInfo[] pointers = ES.Services.MailServers.GetMailDomainPointers(mailDomain.Id);
|
||||
if (pointers != null)
|
||||
{
|
||||
foreach (DomainInfo p in pointers)
|
||||
{
|
||||
if (htMailDomainPointers[p.DomainName.ToLower()] == null) htMailDomainPointers.Add(p.DomainName.ToLower(), 1);
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
ddlDomains.Items.Clear();
|
||||
|
||||
// add "select" item
|
||||
|
@ -149,6 +176,13 @@ namespace WebsitePanel.Portal
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
if (HideMailDomainPointers)
|
||||
{
|
||||
if (htMailDomainPointers[domain.DomainName.ToLower()] != null) continue;
|
||||
}
|
||||
|
||||
|
||||
if (HideInstantAlias && domain.IsInstantAlias)
|
||||
continue;
|
||||
else if (HideMailDomains && domain.MailDomainId > 0)
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
<td id="EditEmailPanel" runat="server">
|
||||
<uc2:UsernameControl ID="txtName" runat="server" width="120px" />
|
||||
@
|
||||
<dnc:SelectDomain id="domainsSelectDomainControl" runat="server" HideDomainPointers="true" HideInstantAlias="false"></dnc:SelectDomain>
|
||||
<dnc:SelectDomain id="domainsSelectDomainControl" runat="server" HideDomainPointers="true" HideInstantAlias="false" HideMailDomainPointers="true"></dnc:SelectDomain>
|
||||
</td>
|
||||
<td id="DisplayEmailPanel" runat="server">
|
||||
<asp:Label ID="litName" Runat="server" Visible="False" CssClass="Huge"></asp:Label>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue