mirror of
https://github.com/plankanban/planka.git
synced 2025-07-19 05:09:43 +02:00
Add preferences tab to user settings, add subscribe to own cards option
This commit is contained in:
parent
f3e0cadca6
commit
6a82448dc7
13 changed files with 96 additions and 2 deletions
|
@ -40,6 +40,9 @@ module.exports = {
|
|||
isNotEmptyString: true,
|
||||
allowNull: true,
|
||||
},
|
||||
subscribeToOwnCards: {
|
||||
type: 'boolean',
|
||||
},
|
||||
},
|
||||
|
||||
exits: {
|
||||
|
@ -59,6 +62,7 @@ module.exports = {
|
|||
'username',
|
||||
'phone',
|
||||
'organization',
|
||||
'subscribeToOwnCards',
|
||||
]);
|
||||
|
||||
const user = await sails.helpers
|
||||
|
|
|
@ -32,6 +32,9 @@ module.exports = {
|
|||
isNotEmptyString: true,
|
||||
allowNull: true,
|
||||
},
|
||||
subscribeToOwnCards: {
|
||||
type: 'boolean',
|
||||
},
|
||||
},
|
||||
|
||||
exits: {
|
||||
|
@ -57,7 +60,14 @@ module.exports = {
|
|||
throw Errors.USER_NOT_FOUND;
|
||||
}
|
||||
|
||||
const values = _.pick(inputs, ['isAdmin', 'name', 'avatar', 'phone', 'organization']);
|
||||
const values = _.pick(inputs, [
|
||||
'isAdmin',
|
||||
'name',
|
||||
'avatar',
|
||||
'phone',
|
||||
'organization',
|
||||
'subscribeToOwnCards',
|
||||
]);
|
||||
|
||||
user = await sails.helpers.updateUser(user, values, this.req);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue