FEATURE: do not restrict categories filtering to only FULL permission type

This commit is contained in:
Joffrey JAFFEUX 2018-01-25 12:03:13 +01:00 committed by GitHub
parent 1fac2ecb56
commit 01f9995956
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 1 deletions

View File

@ -14,6 +14,7 @@ export default ComboBoxComponent.extend({
rowComponent: "category-row",
noneRowComponent: "none-category-row",
allowSubCategories: true,
permissionType: PermissionType.FULL,
init() {
this._super();
@ -94,7 +95,11 @@ export default ComboBoxComponent.extend({
return false;
}
return get(c, "permission") === PermissionType.FULL;
if (this.get("permissionType")) {
return this.get("permissionType") === get(c, "permission");
}
return true;
});
}
});

View File

@ -8,6 +8,7 @@ export default CategoryChooserComponent.extend({
rootNoneLabel: "category.all",
allowUncategorized: true,
clearable: true,
permissionType: null,
init() {
this._super();