mirror of
https://github.com/documize/community.git
synced 2025-07-24 15:49:44 +02:00
Only show space dropdown when label has 2+ spaces
This commit is contained in:
parent
acd3dd63b5
commit
99a5418dba
2 changed files with 14 additions and 11 deletions
|
@ -44,11 +44,14 @@ export default Route.extend(AuthenticatedRouteMixin, {
|
|||
d.set('selected', false);
|
||||
});
|
||||
|
||||
let labelId = this.modelFor('folder').folder.get('labelId');
|
||||
|
||||
return hash({
|
||||
folder: this.modelFor('folder').folder,
|
||||
permissions: this.modelFor('folder').permissions,
|
||||
label: _.find(this.modelFor('folder').labels, {id: this.modelFor('folder').folder.get('labelId')}),
|
||||
label: _.find(this.modelFor('folder').labels, {id: labelId}),
|
||||
labels: this.modelFor('folder').labels,
|
||||
labelSpaces: _.filter(folders, function(s) { return s.get('labelId') === labelId; }),
|
||||
folders: folders,
|
||||
documents: documents,
|
||||
documentsDraft: _.filter(documents, function(d) { return d.get('lifecycle') === constants.Lifecycle.Draft; }),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue