RDS Tabs changes
This commit is contained in:
parent
13ca6e30ca
commit
a02cdd87fe
10 changed files with 106 additions and 9 deletions
|
@ -836,6 +836,7 @@ namespace WebsitePanel.EnterpriseServer
|
|||
}
|
||||
|
||||
rds.AddSessionHostServersToCollection(org.OrganizationId, collection.Name, newServers.ToArray());
|
||||
rds.MoveSessionHostsToCollectionOU(collection.Servers.ToArray(), collection.Name, org.OrganizationId);
|
||||
|
||||
foreach (var server in newServers)
|
||||
{
|
||||
|
|
|
@ -83,5 +83,6 @@ namespace WebsitePanel.Providers.RemoteDesktopServices
|
|||
void MoveSessionHostToRdsOU(string hostName);
|
||||
void ApplyGPO(string organizationId, string collectionName, RdsServerSettings serverSettings);
|
||||
void ShadowSession(string sessionId, bool control);
|
||||
void MoveSessionHostsToCollectionOU(List<RdsServer> servers, string collectionName, string organizationId);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -637,6 +637,14 @@ namespace WebsitePanel.Providers.RemoteDesktopServices
|
|||
}
|
||||
}
|
||||
|
||||
public void MoveSessionHostsToCollectionOU(List<RdsServer> servers, string collectionName, string organizationId)
|
||||
{
|
||||
foreach(var server in servers)
|
||||
{
|
||||
MoveSessionHostToCollectionOU(server.Name, collectionName, organizationId);
|
||||
}
|
||||
}
|
||||
|
||||
public void RemoveSessionHostServerFromCollection(string organizationId, string collectionName, RdsServer server)
|
||||
{
|
||||
Runspace runSpace = null;
|
||||
|
|
|
@ -106,6 +106,8 @@ namespace WebsitePanel.Providers.RemoteDesktopServices {
|
|||
|
||||
private System.Threading.SendOrPostCallback ShadowSessionOperationCompleted;
|
||||
|
||||
private System.Threading.SendOrPostCallback MoveSessionHostsToCollectionOUOperationCompleted;
|
||||
|
||||
/// <remarks/>
|
||||
public RemoteDesktopServices() {
|
||||
this.Url = "http://localhost:9003/RemoteDesktopServices.asmx";
|
||||
|
@ -225,6 +227,9 @@ namespace WebsitePanel.Providers.RemoteDesktopServices {
|
|||
/// <remarks/>
|
||||
public event ShadowSessionCompletedEventHandler ShadowSessionCompleted;
|
||||
|
||||
/// <remarks/>
|
||||
public event MoveSessionHostsToCollectionOUCompletedEventHandler MoveSessionHostsToCollectionOUCompleted;
|
||||
|
||||
/// <remarks/>
|
||||
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
|
||||
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/server/CreateCollection", RequestNamespace="http://smbsaas/websitepanel/server/", ResponseNamespace="http://smbsaas/websitepanel/server/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
|
||||
|
@ -1882,6 +1887,52 @@ namespace WebsitePanel.Providers.RemoteDesktopServices {
|
|||
}
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
[System.Web.Services.Protocols.SoapHeaderAttribute("ServiceProviderSettingsSoapHeaderValue")]
|
||||
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://smbsaas/websitepanel/server/MoveSessionHostsToCollectionOU", 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 MoveSessionHostsToCollectionOU(RdsServer[] servers, string collectionName, string organizationId) {
|
||||
this.Invoke("MoveSessionHostsToCollectionOU", new object[] {
|
||||
servers,
|
||||
collectionName,
|
||||
organizationId});
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public System.IAsyncResult BeginMoveSessionHostsToCollectionOU(RdsServer[] servers, string collectionName, string organizationId, System.AsyncCallback callback, object asyncState) {
|
||||
return this.BeginInvoke("MoveSessionHostsToCollectionOU", new object[] {
|
||||
servers,
|
||||
collectionName,
|
||||
organizationId}, callback, asyncState);
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public void EndMoveSessionHostsToCollectionOU(System.IAsyncResult asyncResult) {
|
||||
this.EndInvoke(asyncResult);
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public void MoveSessionHostsToCollectionOUAsync(RdsServer[] servers, string collectionName, string organizationId) {
|
||||
this.MoveSessionHostsToCollectionOUAsync(servers, collectionName, organizationId, null);
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public void MoveSessionHostsToCollectionOUAsync(RdsServer[] servers, string collectionName, string organizationId, object userState) {
|
||||
if ((this.MoveSessionHostsToCollectionOUOperationCompleted == null)) {
|
||||
this.MoveSessionHostsToCollectionOUOperationCompleted = new System.Threading.SendOrPostCallback(this.OnMoveSessionHostsToCollectionOUOperationCompleted);
|
||||
}
|
||||
this.InvokeAsync("MoveSessionHostsToCollectionOU", new object[] {
|
||||
servers,
|
||||
collectionName,
|
||||
organizationId}, this.MoveSessionHostsToCollectionOUOperationCompleted, userState);
|
||||
}
|
||||
|
||||
private void OnMoveSessionHostsToCollectionOUOperationCompleted(object arg) {
|
||||
if ((this.MoveSessionHostsToCollectionOUCompleted != null)) {
|
||||
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
|
||||
this.MoveSessionHostsToCollectionOUCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
|
||||
}
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public new void CancelAsync(object userState) {
|
||||
base.CancelAsync(userState);
|
||||
|
@ -2523,4 +2574,8 @@ namespace WebsitePanel.Providers.RemoteDesktopServices {
|
|||
/// <remarks/>
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
|
||||
public delegate void ShadowSessionCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
|
||||
|
||||
/// <remarks/>
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("wsdl", "2.0.50727.3038")]
|
||||
public delegate void MoveSessionHostsToCollectionOUCompletedEventHandler(object sender, System.ComponentModel.AsyncCompletedEventArgs e);
|
||||
}
|
||||
|
|
|
@ -695,5 +695,21 @@ namespace WebsitePanel.Server
|
|||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
[WebMethod, SoapHeader("settings")]
|
||||
public void MoveSessionHostsToCollectionOU(List<RdsServer> servers, string collectionName, string organizationId)
|
||||
{
|
||||
try
|
||||
{
|
||||
Log.WriteStart("'{0}' MoveSessionHostsToCollectionOU", ProviderSettings.ProviderName);
|
||||
RDSProvider.MoveSessionHostsToCollectionOU(servers, collectionName, organizationId);
|
||||
Log.WriteEnd("'{0}' MoveSessionHostsToCollectionOU", ProviderSettings.ProviderName);
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Log.WriteError(String.Format("'{0}' MoveSessionHostsToCollectionOU", ProviderSettings.ProviderName), ex);
|
||||
throw;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -138,4 +138,7 @@
|
|||
<data name="valRequireEmail.Text" xml:space="preserve">
|
||||
<value>* Enter E-Mail</value>
|
||||
</data>
|
||||
<data name="btnExit.Text" xml:space="preserve">
|
||||
<value>Back to Users List</value>
|
||||
</data>
|
||||
</root>
|
|
@ -18,7 +18,7 @@
|
|||
</div>
|
||||
<div class="FormBody">
|
||||
<wsp:SimpleMessageBox id="messageBox" runat="server" />
|
||||
<wsp:CollectionTabs id="tabs" runat="server" SelectedTab="rds_setup_letter" />
|
||||
<wsp:CollectionTabs id="tabs" runat="server" SelectedTab="rds_collection_edit_users" />
|
||||
|
||||
<wsp:CollapsiblePanel id="secEmail" runat="server" IsCollapsed="true"
|
||||
TargetControlID="EmailPanel" meta:resourcekey="secEmail" Text="Send via E-Mail">
|
||||
|
@ -41,13 +41,13 @@
|
|||
</td>
|
||||
<td class="Normal">
|
||||
<asp:TextBox ID="txtCC" runat="server" CssClass="NormalTextBox" Width="300px"></asp:TextBox></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td></td>
|
||||
<td>
|
||||
<asp:Button ID="btnSend" runat="server" CssClass="Button2" meta:resourcekey="btnSend" Text="Send" OnClick="btnSend_Click" ValidationGroup="SendEmail" /></td>
|
||||
</tr>
|
||||
</tr>
|
||||
</table>
|
||||
<div class="FormFooterClean">
|
||||
<asp:Button id="btnExit" runat="server" Text="Back to Users List" CssClass="Button1" meta:resourcekey="btnExit"
|
||||
OnClick="btnExit_Click" OnClientClick="ShowProgressDialog('Loading ...');"/>
|
||||
<asp:Button ID="btnSend" runat="server" CssClass="Button2" meta:resourcekey="btnSend" Text="Send" OnClick="btnSend_Click" ValidationGroup="SendEmail" />
|
||||
</div>
|
||||
</asp:Panel>
|
||||
|
||||
<div class="PreviewArea">
|
||||
|
|
|
@ -59,5 +59,10 @@ namespace WebsitePanel.Portal.RDS
|
|||
return;
|
||||
}
|
||||
}
|
||||
|
||||
protected void btnExit_Click(object sender, EventArgs e)
|
||||
{
|
||||
Response.Redirect(EditUrl("SpaceID", PanelSecurity.PackageId.ToString(), "rds_collection_edit_users", "CollectionId=" + PanelRequest.CollectionID, "ItemID=" + PanelRequest.ItemID));
|
||||
}
|
||||
}
|
||||
}
|
|
@ -129,6 +129,15 @@ namespace WebsitePanel.Portal.RDS {
|
|||
/// </remarks>
|
||||
protected global::System.Web.UI.WebControls.TextBox txtCC;
|
||||
|
||||
/// <summary>
|
||||
/// btnExit 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.Button btnExit;
|
||||
|
||||
/// <summary>
|
||||
/// btnSend control.
|
||||
/// </summary>
|
||||
|
|
|
@ -26,8 +26,7 @@ namespace WebsitePanel.Portal.RDS.UserControls
|
|||
tabsList.Add(CreateTab("rds_collection_edit_apps", "Tab.RdsApplications"));
|
||||
tabsList.Add(CreateTab("rds_collection_edit_users", "Tab.RdsUsers"));
|
||||
tabsList.Add(CreateTab("rds_collection_user_sessions", "Tab.UserSessions"));
|
||||
tabsList.Add(CreateTab("rds_collection_local_admins", "Tab.LocalAdmins"));
|
||||
tabsList.Add(CreateTab("rds_setup_letter", "Tab.RdsSetupLetter"));
|
||||
tabsList.Add(CreateTab("rds_collection_local_admins", "Tab.LocalAdmins"));
|
||||
|
||||
int idx = 0;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue