diff options
Diffstat (limited to 'app/assets/javascripts/boards/components/board_settings_sidebar.vue')
-rw-r--r-- | app/assets/javascripts/boards/components/board_settings_sidebar.vue | 18 |
1 files changed, 14 insertions, 4 deletions
diff --git a/app/assets/javascripts/boards/components/board_settings_sidebar.vue b/app/assets/javascripts/boards/components/board_settings_sidebar.vue index 392e056dcbf..80070b25bd0 100644 --- a/app/assets/javascripts/boards/components/board_settings_sidebar.vue +++ b/app/assets/javascripts/boards/components/board_settings_sidebar.vue @@ -36,6 +36,9 @@ export default { computed: { ...mapGetters(['isSidebarOpen', 'shouldUseGraphQL']), ...mapState(['activeId', 'sidebarType', 'boardLists']), + isWipLimitsOn() { + return this.glFeatures.wipLimits; + }, activeList() { /* Warning: Though a computed property it is not reactive because we are @@ -66,14 +69,18 @@ export default { eventHub.$off('sidebar.closeAll', this.unsetActiveId); }, methods: { - ...mapActions(['unsetActiveId']), + ...mapActions(['unsetActiveId', 'removeList']), showScopedLabels(label) { return boardsStore.scopedLabels.enabled && isScopedLabel(label); }, deleteBoard() { // eslint-disable-next-line no-alert - if (window.confirm(__('Are you sure you want to delete this list?'))) { - this.activeList.destroy(); + if (window.confirm(__('Are you sure you want to remove this list?'))) { + if (this.shouldUseGraphQL) { + this.removeList(this.activeId); + } else { + this.activeList.destroy(); + } this.unsetActiveId(); } }, @@ -105,7 +112,10 @@ export default { :active-list="activeList" :board-list-type="boardListType" /> - <board-settings-sidebar-wip-limit :max-issue-count="activeList.maxIssueCount" /> + <board-settings-sidebar-wip-limit + v-if="isWipLimitsOn" + :max-issue-count="activeList.maxIssueCount" + /> <div v-if="canAdminList && !activeList.preset && activeList.id" class="gl-m-4"> <gl-button variant="danger" |