mirror of
https://github.com/valitydev/wazuh-kibana-app.git
synced 2024-11-07 02:15:24 +00:00
Added delay before fetch data
This commit is contained in:
parent
64c25610b0
commit
806d6659a5
@ -1,6 +1,6 @@
|
||||
<div layout="row" flex class="wz-margin-bottom-10">
|
||||
<input ng-if="!isdisabled" flex id="query" placeholder="{{ placetext }}" ng-class="height ? height : ''" type="text" ng-model="term" ng-change="data.addFilter('search', term)"
|
||||
<input ng-if="!isdisabled" flex id="query" placeholder="{{ placetext }}" ng-class="height ? height : ''" type="text" ng-model="term" ng-change="applyDelayAndFilter()"
|
||||
class="wz-search-bar-size groupsNoMarginTop input-filter-box wz-width-100" />
|
||||
<input ng-if="isdisabled" disabled flex id="query" placeholder="{{ placetext }}" ng-class="height ? height : ''" type="text" ng-model="term" ng-change="data.addFilter('search', term)"
|
||||
<input ng-if="isdisabled" disabled flex id="query" placeholder="{{ placetext }}" ng-class="height ? height : ''" type="text" ng-model="term" ng-change="applyDelayAndFilter()"
|
||||
class="wz-search-bar-size groupsNoMarginTop input-filter-box wz-width-100" />
|
||||
</div>
|
||||
|
@ -26,7 +26,9 @@ app.directive('wzSearchBar', function() {
|
||||
isdisabled: '=isdisabled'
|
||||
},
|
||||
link: function(scope, ele, attrs) {
|
||||
|
||||
scope.applyDelayAndFilter = () => {
|
||||
setTimeout(() => scope.data.addFilter('search', scope.term),200)
|
||||
}
|
||||
},
|
||||
template: searchBarTemplate
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user