Commit 9ddb0780 authored by Simon Knox's avatar Simon Knox

move store to ee

parent eaff88b3
/* eslint-disable comma-dangle, space-before-function-paren, one-var, no-shadow, dot-notation, max-len */
/* global List */
import _ from 'underscore';
import Vue from 'vue';
import Cookies from 'js-cookie';
import boardsStoreEE from 'ee/boards/stores/boards_store_ee';
import { getUrlParamsArray } from '../../lib/utils/common_utils';
......@@ -24,16 +23,6 @@ gl.issueBoards.BoardsStore = {
detail: {
issue: {},
},
boardConfig: {
id: false,
name: '',
labels: [],
milestone_id: undefined,
milestone: {},
assignee: {},
assignee_id: '',
weight: null,
},
moving: {
issue: {},
list: {}
......@@ -56,14 +45,6 @@ gl.issueBoards.BoardsStore = {
this.state.reload = false;
this.state.currentPage = page;
},
updateBoardConfig(board = {}) {
this.boardConfig.id = board.id;
this.boardConfig.name = board.name;
this.boardConfig.milestone = board.milestone;
this.boardConfig.labels = board.labels || [];
this.boardConfig.assignee = board.assignee || {};
this.boardConfig.weight = board.weight;
},
addList (listObj, defaultAvatar) {
const list = new List(listObj, defaultAvatar);
this.state.lists.push(list);
......
......@@ -11,6 +11,24 @@ class BoardsStoreEE {
this.store.removePromotionState = () => {
this.removePromotion();
};
this.store.boardConfig = {
id: false,
name: '',
labels: [],
milestone: {},
assignee: {},
weight: null,
};
this.store.updateBoardConfig = this.updateBoardConfig;
}
updateBoardConfig(board = {}) {
this.boardConfig.id = board.id;
this.boardConfig.name = board.name;
this.boardConfig.milestone = board.milestone;
this.boardConfig.labels = board.labels || [];
this.boardConfig.assignee = board.assignee || {};
this.boardConfig.weight = board.weight;
}
shouldAddPromotionState() {
......
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