protocol-opcua/opcua-address-space.component.ts
OnInit
OnDestroy
selector | opcua-address-space |
templateUrl | ./opcua-address-space.component.html |
Properties |
Methods |
Outputs |
constructor(addressSpaceService: AddressSpaceService, opcuaService: OpcuaService)
|
|||||||||
Parameters :
|
focusStatus |
Type : EventEmitter<AddressSpaceNode>
|
backHandler | ||||
backHandler(node)
|
||||
Parameters :
Returns :
void
|
clearNodeListAndCheckSearchString |
clearNodeListAndCheckSearchString()
|
Returns :
void
|
clearSearch |
clearSearch()
|
Returns :
void
|
getIcon | ||||||
getIcon(nodeClassName: string)
|
||||||
Parameters :
Returns :
any
|
isNodeSet | ||||||
isNodeSet(node: AddressSpaceNode)
|
||||||
Parameters :
Returns :
boolean
|
ngOnDestroy |
ngOnDestroy()
|
Returns :
void
|
Async ngOnInit |
ngOnInit()
|
Returns :
any
|
Async searchNodes |
searchNodes()
|
Returns :
any
|
Async selectNode | ||||
selectNode(node)
|
||||
Parameters :
Returns :
any
|
toggleCurrentNode | ||||||
toggleCurrentNode(node: AddressSpaceNode)
|
||||||
Parameters :
Returns :
void
|
currentNode |
Type : AddressSpaceNode
|
dataSource |
Type : DynamicDataSource
|
filterLabel |
Type : string
|
isSearch |
Type : boolean
|
loading |
Default value : false
|
nodeList |
searchInProgress |
Default value : false
|
searchKey |
Type : string
|
selectednode |
Default value : false
|
<div class="row split-scroll">
<div class="col-md-5 col-xs-12 scroll-column no-gutter-r">
<div class="card bg-level-2 split-scroll overflow-auto">
<div class="card-block separator-bottom sticky-top">
<div class="input-group input-group-search">
<input
class="form-control"
placeholder="{{ filterLabel | translate }}"
type="search"
(keydown.enter)="searchNodes()"
[(ngModel)]="searchKey"
/>
<span class="input-group-btn">
<button
class="btn btn-dot"
title="{{ 'Search' | translate }}"
type="submit"
*ngIf="!isSearch"
(click)="searchNodes()"
>
<i c8yIcon="search"></i>
</button>
<button
class="btn btn-dot"
title="{{ 'Clear`input`' | translate }}"
type="button"
*ngIf="isSearch"
(click)="clearSearch()"
>
<i c8yIcon="times"></i>
</button>
</span>
</div>
<div
class="p-t-16"
*ngIf="isSearch && !loading"
>
<p *ngIf="!searchInProgress">
<em>{{ nodeList.resultLabel | translate }}</em>
<span class="badge badge-info">{{ nodeList?.length }}</span>
</p>
</div>
</div>
<div
class="p-t-8"
*ngIf="(isSearch && loading) || searchInProgress"
>
<c8y-loading></c8y-loading>
</div>
<div
class="inner-scroll"
*ngIf="isSearch && !loading && !searchInProgress"
>
<div
class="list-group list-group-links"
*ngIf="isSearch && !loading"
>
<button
*ngFor="let nodeItem of nodeList"
(click)="selectNode(nodeItem)"
[ngClass]="{ 'list-group-item d-flex': true }"
>
<div class="list-group-icon m-r-4">
<i
class="m-r-4"
[c8yIcon]="getIcon(nodeItem.nodeClassName)"
></i>
</div>
<div class="list-item-body text-truncate">
<span tile="nodeId">{{ nodeItem.nodeId }}</span>
{{ nodeItem.displayName }}
</div>
</button>
</div>
</div>
<div
class="inner-scroll"
*ngIf="!isSearch"
>
<opcua-address-space-tree
(selectedNode)="toggleCurrentNode($event)"
[focusEmitter]="focusStatus"
></opcua-address-space-tree>
</div>
</div>
</div>
<opcua-address-space-detail
class="col-md-7 col-xs-12 scroll-column no-gutter-l no-pointer"
[node]="currentNode"
(toggleAttrDetail)="backHandler($event)"
></opcua-address-space-detail>
</div>