File

protocol-opcua/opcua-address-space.component.ts

Implements

OnInit OnDestroy

Metadata

Index

Properties
Methods
Outputs

Constructor

constructor(addressSpaceService: AddressSpaceService, opcuaService: OpcuaService)
Parameters :
Name Type Optional
addressSpaceService AddressSpaceService No
opcuaService OpcuaService No

Outputs

focusStatus
Type : EventEmitter<AddressSpaceNode>

Methods

backHandler
backHandler(node)
Parameters :
Name Optional
node No
Returns : void
clearNodeListAndCheckSearchString
clearNodeListAndCheckSearchString()
Returns : void
clearSearch
clearSearch()
Returns : void
getIcon
getIcon(nodeClassName: string)
Parameters :
Name Type Optional
nodeClassName string No
Returns : any
isNodeSet
isNodeSet(node: AddressSpaceNode)
Parameters :
Name Type Optional
node AddressSpaceNode No
Returns : boolean
ngOnDestroy
ngOnDestroy()
Returns : void
Async ngOnInit
ngOnInit()
Returns : any
Async searchNodes
searchNodes()
Returns : any
Async selectNode
selectNode(node)
Parameters :
Name Optional
node No
Returns : any
toggleCurrentNode
toggleCurrentNode(node: AddressSpaceNode)
Parameters :
Name Type Optional
node AddressSpaceNode No
Returns : void

Properties

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>
            &nbsp;
            <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>

results matching ""

    No results matching ""