mirror of
https://github.com/plankanban/planka.git
synced 2025-07-19 13:19:44 +02:00
15 lines
396 B
JavaScript
15 lines
396 B
JavaScript
module.exports = {
|
|
inputs: {
|
|
idOrIds: {
|
|
type: 'json',
|
|
custom: (value) => _.isString(value) || _.every(value, _.isString),
|
|
required: true,
|
|
},
|
|
},
|
|
|
|
async fn(inputs) {
|
|
const boardMemberships = await sails.helpers.users.getBoardMemberships(inputs.idOrIds);
|
|
|
|
return sails.helpers.utils.mapRecords(boardMemberships, 'boardId', _.isArray(inputs.idOrIds));
|
|
},
|
|
};
|