Commit 26f0413d authored by Axel García's avatar Axel García Committed by Miguel Rincon

Use map state on epic header

parent 492dbdf3
...@@ -32,6 +32,7 @@ export default { ...@@ -32,6 +32,7 @@ export default {
'epicStatusChangeInProgress', 'epicStatusChangeInProgress',
'author', 'author',
'created', 'created',
'canCreate',
'canUpdate', 'canUpdate',
'confidential', 'confidential',
'newEpicWebUrl', 'newEpicWebUrl',
...@@ -54,10 +55,8 @@ export default { ...@@ -54,10 +55,8 @@ export default {
actionButtonText() { actionButtonText() {
return this.isEpicOpen ? __('Close epic') : __('Reopen epic'); return this.isEpicOpen ? __('Close epic') : __('Reopen epic');
}, },
canCreate() { userCanCreate() {
const { canCreate } = this.$store.state; return this.canCreate && this.glFeatures.createEpicForm;
return canCreate && this.glFeatures.createEpicForm;
}, },
}, },
mounted() { mounted() {
...@@ -126,7 +125,7 @@ export default { ...@@ -126,7 +125,7 @@ export default {
> >
<gl-deprecated-button <gl-deprecated-button
v-if="canCreate" v-if="userCanCreate"
class="btn btn-grouped btn-success btn-inverted js-new-epic-button" class="btn btn-grouped btn-success btn-inverted js-new-epic-button"
:href="newEpicWebUrl" :href="newEpicWebUrl"
> >
......
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