1
0
Fork 0
mirror of https://github.com/plankanban/planka.git synced 2025-07-20 21:59:43 +02:00

Prepare for collection board type, refactoring, update dependencies

This commit is contained in:
Maksim Eltyshev 2020-08-04 01:32:46 +05:00
parent 2d92ade8dc
commit c6ee7d54bb
190 changed files with 2144 additions and 1817 deletions

View file

@ -11,6 +11,11 @@ module.exports = {
regex: /^[0-9]+$/,
required: true,
},
type: {
type: 'string',
isIn: Board.TYPES,
required: true,
},
position: {
type: 'number',
required: true,
@ -39,8 +44,7 @@ module.exports = {
throw Errors.PROJECT_NOT_FOUND;
}
const values = _.pick(inputs, ['position', 'name']);
const values = _.pick(inputs, ['type', 'position', 'name']);
const board = await sails.helpers.createBoard(project, values, this.req);
sails.sockets.join(this.req, `board:${board.id}`); // TODO: only when subscription needed