aboutsummaryrefslogtreecommitdiff
path: root/src/db/model/UserGroup.ts
blob: 89f234dd910d8adc5e215458b411a1d0301382e3 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
import * from 'sequelize-typescript';
import { default as User } from './User';

export default class UserGroup extends Model<UserGroup> {
  @Column
  name: string;

  @HasMany(() => User)
  users: User[];

  @Column
  canCreateUsers: boolean;

  @Column
  canDeleteUsers: boolean;

  @Column
  canEditUsers: boolean;

  @Column
  canCreateProjects: boolean;

  @Column
  canDeleteProjects: boolean;

  @Column
  canEditProjects: boolean;
}