Commit 35b7fd7c authored by Ezekiel Kigbo's avatar Ezekiel Kigbo

Fix move data to $options

parent 9c907069
...@@ -43,20 +43,6 @@ export default { ...@@ -43,20 +43,6 @@ export default {
required: true, required: true,
}, },
}, },
data() {
return {
multiProjectSelect: true,
dateOptions: [7, 30, 90],
groupsQueryParams: {
min_access_level: featureAccessLevel.EVERYONE,
},
projectsQueryParams: {
per_page: PROJECTS_PER_PAGE,
with_shared: false,
order_by: 'last_activity_at',
},
};
},
computed: { computed: {
...mapState([ ...mapState([
'featureFlags', 'featureFlags',
...@@ -200,6 +186,8 @@ export default { ...@@ -200,6 +186,8 @@ export default {
this.updateSelectedDurationChartStages(stages); this.updateSelectedDurationChartStages(stages);
}, },
}, },
multiProjectSelect: true,
dateOptions: [7, 30, 90],
groupsQueryParams: { groupsQueryParams: {
min_access_level: featureAccessLevel.EVERYONE, min_access_level: featureAccessLevel.EVERYONE,
}, },
...@@ -231,7 +219,7 @@ export default { ...@@ -231,7 +219,7 @@ export default {
class="js-projects-dropdown-filter ml-md-1 mt-1 mt-md-0 dropdown-select" class="js-projects-dropdown-filter ml-md-1 mt-1 mt-md-0 dropdown-select"
:group-id="selectedGroup.id" :group-id="selectedGroup.id"
:query-params="$options.projectsQueryParams" :query-params="$options.projectsQueryParams"
:multi-select="multiProjectSelect" :multi-select="$options.multiProjectSelect"
@selected="onProjectsSelect" @selected="onProjectsSelect"
/> />
<div <div
......
...@@ -189,7 +189,7 @@ describe('Cycle Analytics component', () => { ...@@ -189,7 +189,7 @@ describe('Cycle Analytics component', () => {
expect.objectContaining({ expect.objectContaining({
queryParams: wrapper.vm.$options.projectsQueryParams, queryParams: wrapper.vm.$options.projectsQueryParams,
groupId: mockData.group.id, groupId: mockData.group.id,
multiSelect: wrapper.vm.multiProjectSelect, multiSelect: wrapper.vm.$options.multiProjectSelect,
}), }),
); );
}); });
......
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