Commit 71ccf41f authored by Natalia Tepluhina's avatar Natalia Tepluhina

Merge branch 'ss/mv-maxissue-update-to-store' into 'master'

Update maxIssueCount in boards store

See merge request gitlab-org/gitlab!22540
parents d1a519b6 3f6406e0
......@@ -81,14 +81,10 @@ export default {
this.updateListWipLimit({ maxIssueCount: this.currentWipLimit, id: this.activeListId })
.then(({ config }) => {
/*
Move to BoardsStore bc we are consolidating all List
Model code and then moving it from BoardsStore to Vuex.
*/
boardsStoreEE.store.findList('id', this.activeListId).maxIssueCount = JSON.parse(
config.data,
).list.max_issue_count;
boardsStoreEE.setMaxIssueCountOnList(
this.activeListId,
JSON.parse(config.data).list.max_issue_count,
);
this.resetStateAfterUpdate();
})
.catch(() => {
......
......@@ -172,6 +172,10 @@ class BoardsStoreEE {
return parseBoolean(Cookies.get('promotion_issue_board_hidden'));
}
setMaxIssueCountOnList(id, maxIssueCount) {
this.store.findList('id', id).maxIssueCount = maxIssueCount;
}
updateWeight(newWeight, id) {
const { issue } = this.store.detail;
if (issue.id === id && issue.sidebarInfoEndpoint) {
......
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