File

search/search-grid.component.ts

Metadata

Index

Properties
Methods
Inputs
Outputs
Accessors

Constructor

constructor(coreSearchService: InventorySearchService, searchService: AssetSearchService, bsModalService: BsModalService, smartGroupsService: SmartGroupsService, subAssetsGridService: SubAssetsService)
Parameters :
Name Type Optional
coreSearchService InventorySearchService No
searchService AssetSearchService No
bsModalService BsModalService No
smartGroupsService SmartGroupsService No
subAssetsGridService SubAssetsService No

Inputs

actionControls
Type : []
bulkActionControls
Type : []
columns
Type : []
filteringName
Type : string
loadingItemsLabel
Type : string
Default value : gettext('Loading results…')
pagination
parent-group
Type : IManagedObject
searchText
Type : string
Default value : ''
selectable
Type : boolean
Default value : false
title
Type : string
Default value : ''

Outputs

onColumnsChange
Type : EventEmitter<DeviceGridColumn[]>

Methods

configChange
configChange(config)
Parameters :
Name Optional
config No
Returns : void
ngOnInit
ngOnInit()
Returns : void
Async onDataSourceModifier
onDataSourceModifier(dataSourceModifier: DataSourceModifier)
Parameters :
Name Type Optional
dataSourceModifier DataSourceModifier No
setActionControls
setActionControls()
Returns : void
trackByName
trackByName(_index, column: DeviceGridColumn)
Parameters :
Name Type Optional
_index No
column DeviceGridColumn No
Returns : string
updateFiltering
updateFiltering(columnNames: string[], action: literal type)
Parameters :
Name Type Optional
columnNames string[] No
action literal type No
Returns : void

Properties

actionControls
Type : ActionControl[]
bulkActionControls
Type : BulkActionControl[]
Default value : this.searchService.getDefaultBulkActionControls()
columns
Type : DeviceGridColumn[]
dataGrid
Type : DataGridComponent
Decorators :
@ViewChild(DataGridComponent, {static: true})
pagination
Type : Pagination
Default value : this.searchService.getDefaultPagination()
refresh
Type : EventEmitter<any>
Default value : new EventEmitter()
Public searchService
Type : AssetSearchService
serverSideDataCallback
Type : any

Accessors

_columns
set_columns(value: DeviceGridColumn[])
Parameters :
Name Type Optional
value DeviceGridColumn[] No
Returns : void
_pagination
set_pagination(value: Pagination)
Parameters :
Name Type Optional
value Pagination No
Returns : void
_actionControls
set_actionControls(value: ActionControl[])
Parameters :
Name Type Optional
value ActionControl[] No
Returns : void
_bulkActionControls
set_bulkActionControls(value: BulkActionControl[])
Parameters :
Name Type Optional
value BulkActionControl[] No
Returns : void
<div class="card--grid--fullpage">
  <c8y-data-grid
    [title]="'Search results' | translate"
    [loadingItemsLabel]="loadingItemsLabel"
    [columns]="columns"
    [pagination]="pagination"
    [actionControls]="actionControls"
    [selectable]="selectable"
    [bulkActionControls]="bulkActionControls"
    [serverSideDataCallback]="serverSideDataCallback"
    [infiniteScroll]="'auto'"
    [showSearch]="true"
    [searchText]="searchText"
    [refresh]="refresh"
    (onConfigChange)="configChange($event)"
  >
    <ng-container *ngFor="let column of columns; trackBy: trackByName">
      <c8y-column [name]="column.name"></c8y-column>
    </ng-container>

    <c8y-ui-empty-state
      [icon]="'search'"
      [title]="'No results to display.' | translate"
      [subtitle]="'Refine your search terms or check your spelling.' | translate"
      [horizontal]="true"
    ></c8y-ui-empty-state>
  </c8y-data-grid>
</div>

results matching ""

    No results matching ""