FIX: in create/edit category modal, don't prompt to choose a parent category when allow_uncategorized_topics is false

This commit is contained in:
Neil Lalonde 2016-10-05 12:06:37 -04:00
parent 843c7a21c9
commit a061c025f1
2 changed files with 2 additions and 2 deletions

View File

@ -38,7 +38,7 @@ export default ComboboxView.extend({
@computed("rootNone") @computed("rootNone")
none(rootNone) { none(rootNone) {
if (Discourse.SiteSettings.allow_uncategorized_topics) { if (Discourse.SiteSettings.allow_uncategorized_topics || this.get('allowUncategorized')) {
if (rootNone) { if (rootNone) {
return "category.none"; return "category.none";
} else { } else {

View File

@ -19,7 +19,7 @@
{{/each}} {{/each}}
{{else}} {{else}}
<label>{{i18n 'category.parent'}}</label> <label>{{i18n 'category.parent'}}</label>
{{category-chooser valueAttribute="id" value=category.parent_category_id categories=parentCategories rootNone=true}} {{category-chooser valueAttribute="id" value=category.parent_category_id categories=parentCategories rootNone=true allowUncategorized="true"}}
{{/if}} {{/if}}
</section> </section>
{{/if}} {{/if}}