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

Project managers, board members, auto-update after reconnection, refactoring

This commit is contained in:
Maksim Eltyshev 2021-06-24 01:05:22 +05:00
parent 7956503a46
commit fe91b5241e
478 changed files with 21226 additions and 19495 deletions

View file

@ -6,25 +6,22 @@ module.exports = {
},
},
async fn(inputs, exits) {
async fn(inputs) {
const { currentUser } = this.req;
const values = _.pick(inputs, ['name']);
const { project, projectMembership } = await sails.helpers.createProject(
currentUser,
const { project, projectManager } = await sails.helpers.projects.createOne(
values,
currentUser,
this.req,
true,
);
return exits.success({
return {
item: project,
included: {
users: [currentUser],
projectMemberships: [projectMembership],
boards: [],
projectManagers: [projectManager],
},
});
};
},
};