dropDown error corregido cuando el servidor tarda en responder
This commit is contained in:
parent
628c77a440
commit
dd1b8655a5
|
@ -86,9 +86,17 @@ export default class DropDown {
|
|||
});
|
||||
}
|
||||
|
||||
_eventScroll(add) {
|
||||
_eventScroll(add, num) {
|
||||
let count = num || 0;
|
||||
if (add) {
|
||||
this.container.addEventListener('scroll', e => this.loadFromScroll(e));
|
||||
if (this.container)
|
||||
this.container.addEventListener('scroll', e => this.loadFromScroll(e));
|
||||
else if (count < 4) {
|
||||
count++;
|
||||
this.$timeout(() => { // wait angular ngIf
|
||||
this._eventScroll(add, count);
|
||||
}, 250);
|
||||
}
|
||||
} else {
|
||||
this.container.removeEventListener('scroll', e => this.loadFromScroll(e));
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue