Move EE differences for `app/assets/javascripts/notes/components/note_actions.vue`
The file app/assets/javascripts/notes/components/note_actions.vue has differences between CE and EE.
Diferences
diff --git a/home/yorickpeterse/Projects/gitlab/gdk-ce/gitlab/app/assets/javascripts/notes/components/note_actions.vue b/home/yorickpeterse/Projects/gitlab/gdk-ee/gitlab/app/assets/javascripts/notes/components/note_actions.vue
index d99694b06e9..da78e4605d4 100644
--- a/home/yorickpeterse/Projects/gitlab/gdk-ce/gitlab/app/assets/javascripts/notes/components/note_actions.vue
+++ b/home/yorickpeterse/Projects/gitlab/gdk-ee/gitlab/app/assets/javascripts/notes/components/note_actions.vue
@@ -2,6 +2,7 @@
import { mapGetters } from 'vuex';
import Icon from '~/vue_shared/components/icon.vue';
import { GlLoadingIcon, GlTooltipDirective } from '@gitlab/ui';
+import resolvedStatusMixin from 'ee/batch_comments/mixins/resolved_status';
export default {
name: 'NoteActions',
@@ -12,6 +13,7 @@ export default {
directives: {
GlTooltip: GlTooltipDirective,
},
+ mixins: [resolvedStatusMixin],
props: {
authorId: {
type: Number,
@@ -93,6 +95,8 @@ export default {
return this.getUserDataByProp('id');
},
resolveButtonTitle() {
+ if (this.discussionId) return this.resolvedStatusMessage;
+
let title = 'Mark as resolved';
if (this.resolvedBy) {
@@ -113,6 +117,7 @@ export default {
this.$emit('handleResolve');
},
},
+ showStaysResolved: true,
};
</script>
What needs to be done
- Create an empty CE counterpart for
resolvedStatusMixin - Use
ee_else_ceto import the mixin into this file. - Create a computedProp for
resolveButtonTitlein the EE mixin and move the extra code there. - Delete
showStaysResolved, it's not being used - Guarantee that specs exist or are added