Skip to content

Commit

Permalink
Merge pull request #311 from GregKass/select-all-instructions
Browse files Browse the repository at this point in the history
Select all instructions
  • Loading branch information
softsimon authored Oct 26, 2017
2 parents 11dce58 + 7f7a1bf commit aa47c1d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/dropdown/dropdown.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -202,10 +202,10 @@ export class MultiselectDropdown implements OnInit, OnChanges, DoCheck, OnDestro
.map(option => option.parentId);
this.updateRenderItems();

if (this.isLazyLoad && this.settings.selectAddedValues && this.loadedValueIds.length === 0) {
if (this.settings.isLazyLoad && this.settings.selectAddedValues && this.loadedValueIds.length === 0) {
this.loadedValueIds = this.loadedValueIds.concat(changes.options.currentValue.map(value => value.id));
}
if (this.isLazyLoad && this.settings.selectAddedValues && changes.options.previousValue) {
if (this.settings.isLazyLoad && this.settings.selectAddedValues && changes.options.previousValue) {
let addedValues = changes.options.currentValue.filter(
value => this.loadedValueIds.indexOf(value.id) === -1
);
Expand Down Expand Up @@ -425,7 +425,7 @@ export class MultiselectDropdown implements OnInit, OnChanges, DoCheck, OnDestro
checkAll() {
if (!this.disabledSelection) {
this.addChecks(!this.searchFilterApplied() ? this.options : this.filteredOptions);
if (this.isLazyLoad && this.settings.selectAddedValues) {
if (this.settings.isLazyLoad && this.settings.selectAddedValues) {
if (this.searchFilterApplied() && !this.checkAllStatus) {
this.checkAllSearchRegister.add(this.filterControl.value);
} else {
Expand Down Expand Up @@ -454,7 +454,7 @@ export class MultiselectDropdown implements OnInit, OnChanges, DoCheck, OnDestro
return false;
}
});
if (this.isLazyLoad && this.settings.selectAddedValues) {
if (this.settings.isLazyLoad && this.settings.selectAddedValues) {
if (this.searchFilterApplied()) {
if (this.checkAllSearchRegister.has(this.filterControl.value)) {
this.checkAllSearchRegister.delete(this.filterControl.value);
Expand Down

0 comments on commit aa47c1d

Please sign in to comment.