File

src/smart-developer-tools/appserver-manager/appserver-manager.component.ts

Extends

AbstractFormChild

Implements

OnInit AfterViewInit

Metadata

Index

Properties
Methods
Inputs

Constructor

constructor(serviceAdapter: SmartServiceAdapter, smartHttp: SmartHttpService, errorHandler: SmartErrorHandlerService, injector: Injector)
Parameters :
Name Type Optional
serviceAdapter SmartServiceAdapter No
smartHttp SmartHttpService No
errorHandler SmartErrorHandlerService No
injector Injector No

Inputs

ignoreFlexboxLayout
Type : boolean
smart-help-text
Type : string | undefined

Sets the HelpText value for this form child.

smart-instance-name
Type : string

The instance name of the component

smart-object-name
Type : string

The object name of the component

Methods

fetchApplications
fetchApplications()
Returns : void
fetchServers
fetchServers()
Returns : any
Public handleLayoutChange
handleLayoutChange(newLayout: any)
Parameters :
Name Type Optional
newLayout any No
Returns : void
trimServers
trimServers()
Returns : void
Public notifyLoadingFinished
notifyLoadingFinished(objectName: string)

Notifies the parent Smart Form that this form child has finished loading

Parameters :
Name Type Optional
objectName string No
Returns : void

void

Properties

applications
Type : string[]
Default value : []
container
Type : ElementRef<HTMLElement>
Decorators :
@ViewChild('container', {read: ElementRef})
fetchApplicationResult
Type : AppServerResponse
password
Type : string
Default value : 'tomcat'
selectedApplication
Type : string
Default value : ''
servers
Type : AppServerInfo[]
Default value : []
Public serviceAdapter
Type : SmartServiceAdapter
sessions
Type : AppServerSession[]
Default value : []
userName
Type : string
Default value : 'tomcat'
Public injector
Type : Injector
<!--
**************************************************************************
* Copyright © 2006-2026 by Consultingwerk Ltd. ("CW") -                  *
* www.consultingwerk.com and other contributors as listed                *
* below. All Rights Reserved.                                            *
*                                                                        *
*  Software is distributed on an "AS IS", WITHOUT WARRANTY OF ANY        *
*   KIND, either express or implied.                                     *
*                                                                        *
*  Contributors:                                                         *
*                                                                        *
**************************************************************************

--------------------------------------------------------------------------
    File        : appserver-manager.component.html
    Purpose     : Template for appserver manager.
    Author(s)   : Oana Sucigan
    Created     : Nov 27, 2020
--------------------------------------------------------------------------
-->
<div
	class="container-fluid h-100 d-flex flex-column overflow-y-auto"
	#container
>
	<div
		class="d-flex flex-row me-0 w-100 px-0 gap-3 w-100 flex-wrap"
		id="credentials"
	>
		<div class="d-flex flex-row me-0 gap-2 flex-grow-1">
			<kendo-formfield orientation="horizontal" class="flex-grow-1">
				<kendo-label
					text="User Name"
					[style.whiteSpace]="'nowrap'"
					[style.overflow]="'hidden'"
					[style.textOverflow]="'ellipsis'"
				></kendo-label>
				<input
					class="app-input w-100"
					kendoTextBox
					type="text"
					name="inputUsername"
					[(ngModel)]="userName"
				/>
			</kendo-formfield>
			<kendo-formfield orientation="horizontal" class="flex-grow-1">
				<kendo-label text="Password"></kendo-label>
				<input
					class="app-input w-100"
					kendoTextBox
					type="password"
					name="inputPassword"
					[(ngModel)]="password"
				/>
			</kendo-formfield>
		</div>
		<div class="d-flex flex-row me-0 gap-2 flex-grow-1">
			<kendo-formfield orientation="horizontal">
				<kendo-label text="Application"></kendo-label>
				<kendo-combobox
					class="app-input"
					[data]="applications"
					[style.minWidth]="'250px'"
					[(ngModel)]="selectedApplication"
					[fillMode]="'flat'"
					[popupSettings]="{ appendTo: popupAppendTarget }"
				></kendo-combobox>
			</kendo-formfield>
			<kendo-formfield orientation="horizontal">
				<kendo-label text=""></kendo-label>
				<button
					(click)="fetchApplications()"
					kendoButton
					iconClass="fa-solid fa-arrows-rotate"
				>
					Fetch Applications
				</button>
			</kendo-formfield>
		</div>
	</div>

	<kendo-grid
		[data]="servers"
		scrollable="scrollable"
		class="w-100 flex-grow-1"
	>
		<kendo-grid-column field="agentId">
			<ng-template kendoGridHeaderTemplate>
				<p style="font-weight: bold">agentId</p>
			</ng-template>
		</kendo-grid-column>
		<kendo-grid-column field="pid">
			<ng-template kendoGridHeaderTemplate>
				<p style="font-weight: bold">pid</p>
			</ng-template>
		</kendo-grid-column>
		<kendo-grid-column field="state">
			<ng-template kendoGridHeaderTemplate>
				<p style="font-weight: bold">state</p>
			</ng-template>
		</kendo-grid-column>
	</kendo-grid>

	<div class="d-flex flex-row me-0" id="buttons-container">
		<button
			kendoButton
			iconClass="fa-solid fa-arrows-rotate"
			(click)="fetchServers()"
		>
			&nbsp;Fetch Servers
		</button>
		<button kendoButton iconClass="fa-solid fa-ban" (click)="trimServers()">
			&nbsp;Trim Servers
		</button>
	</div>

	@if (!!fetchApplicationResult) {
	<div class="row" id="application-result">
		<pre class="col-12">{{ fetchApplicationResult | json }}</pre>
	</div>
	}
</div>

./appserver-manager.component.css

/**********************************************************************
 * Copyright © 2006-2026 by Consultingwerk Ltd. ("CW") -              *
 * www.consultingwerk.com and other contributors as listed            *
 * below. All Rights Reserved.                                        *
 *                                                                    *
 *  Software is distributed on an "AS IS", WITHOUT WARRANTY OF ANY    *
 *   KIND, either express or implied.                                 *
 *                                                                    *
 *  Contributors:                                                     *
 *                                                                    *
 **********************************************************************/
/*------------------------------------------------------------------------
    File        : appserver-manager.component.css
    Purpose     : Styles for appserver manager.
    Author(s)   : Oana Sucigan
    Created     : Nov 27, 2020
  ----------------------------------------------------------------------*/

.app-input {
    width: 150px;
    margin: 0px 10px 5px 0px;
}

.margin {
    padding-top: 10px;
    padding-bottom: 5px;
}

::ng-deep label {
    font-weight: unset;
}

#credentials, #application {
    padding: 10px 15px;
    justify-content: flex-start;
    flex: 0;
}
#application button.app-input {
    margin-top: 20px;
}
#servers {
    flex: 0;
}

#buttons-container button {
    margin: 10px 10px 5px 0px;
}

#application-result {
    padding: 0px;
    margin: 10px 0px 0px 0px;
    flex: 1;
    min-height: 100px;
    overflow: auto;
    border: 1px solid #ccc;
    border-radius: 4px;
}
#application-result pre {
    border: none;
    margin-bottom: 0px;
}
Legend
Html element
Component
Html element with directive

results matching ""

    No results matching ""