mirror of
https://github.com/discourse/discourse.git
synced 2024-11-23 16:46:12 +08:00
FEATURE: do not restrict categories filtering to only FULL permission type
This commit is contained in:
parent
1fac2ecb56
commit
01f9995956
|
@ -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;
|
||||
});
|
||||
}
|
||||
});
|
||||
|
|
|
@ -8,6 +8,7 @@ export default CategoryChooserComponent.extend({
|
|||
rootNoneLabel: "category.all",
|
||||
allowUncategorized: true,
|
||||
clearable: true,
|
||||
permissionType: null,
|
||||
|
||||
init() {
|
||||
this._super();
|
||||
|
|
Loading…
Reference in New Issue
Block a user