mirror of
https://github.com/plankanban/planka.git
synced 2025-07-19 13:19:44 +02:00
Code formatting with prettier, change eslint config for the server
This commit is contained in:
parent
b7f37f0f96
commit
a11f6260c0
191 changed files with 4321 additions and 2880 deletions
|
@ -14,29 +14,29 @@ module.exports = {
|
|||
email: {
|
||||
type: 'string',
|
||||
isEmail: true,
|
||||
required: true
|
||||
required: true,
|
||||
},
|
||||
password: {
|
||||
type: 'string',
|
||||
required: true
|
||||
required: true,
|
||||
},
|
||||
isAdmin: {
|
||||
type: 'boolean',
|
||||
defaultsTo: false,
|
||||
columnName: 'is_admin'
|
||||
columnName: 'is_admin',
|
||||
},
|
||||
name: {
|
||||
type: 'string',
|
||||
required: true
|
||||
required: true,
|
||||
},
|
||||
avatar: {
|
||||
type: 'string',
|
||||
isNotEmptyString: true,
|
||||
allowNull: true
|
||||
allowNull: true,
|
||||
},
|
||||
deletedAt: {
|
||||
type: 'ref',
|
||||
columnName: 'deleted_at'
|
||||
columnName: 'deleted_at',
|
||||
},
|
||||
|
||||
// ╔═╗╔╦╗╔╗ ╔═╗╔╦╗╔═╗
|
||||
|
@ -50,24 +50,24 @@ module.exports = {
|
|||
membershipProjects: {
|
||||
collection: 'Project',
|
||||
via: 'userId',
|
||||
through: 'ProjectMembership'
|
||||
through: 'ProjectMembership',
|
||||
},
|
||||
subscriptionCards: {
|
||||
collection: 'Card',
|
||||
via: 'userId',
|
||||
through: 'CardSubscription'
|
||||
through: 'CardSubscription',
|
||||
},
|
||||
membershipCards: {
|
||||
collection: 'Card',
|
||||
via: 'userId',
|
||||
through: 'CardMembership'
|
||||
}
|
||||
through: 'CardMembership',
|
||||
},
|
||||
},
|
||||
|
||||
customToJSON: function() {
|
||||
customToJSON() {
|
||||
return {
|
||||
..._.omit(this, 'password'),
|
||||
avatar: this.avatar && `${sails.config.custom.uploadsUrl}/${this.avatar}`
|
||||
avatar: this.avatar && `${sails.config.custom.uploadsUrl}/${this.avatar}`,
|
||||
};
|
||||
}
|
||||
},
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue