Commit d15521c7 authored by Alfredo Sumaran's avatar Alfredo Sumaran

Do not allow to expand a row if group doesn’t have subgroups

parent fb1e7eae
......@@ -14,7 +14,7 @@ export default {
},
methods: {
toggleSubGroups(e) {
if (e.target.tagName === 'A' || !this.hasSubgroups) {
if (e.target.tagName === 'A' || !this.group.hasSubgroups) {
return false;
}
......@@ -39,14 +39,10 @@ export default {
return {
'group-row': true,
'is-open': this.group.isOpen,
'has-subgroups': this.hasSubgroups,
'has-subgroups': this.group.hasSubgroups,
'no-description': !this.group.description,
};
},
hasSubgroups() {
// TODO: Server should send a flag to indicate group will have subgroups
return true;
},
fullPath() {
let fullPath = '';
......
......@@ -117,6 +117,7 @@ export default class GroupsStore {
fullName: rawGroup.full_name,
fullPath: rawGroup.full_path,
name: rawGroup.name,
hasSubgroups: rawGroup.has_subgroups,
canEdit: rawGroup.can_edit,
description: rawGroup.description,
webUrl: rawGroup.web_url,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment