feat: add properties to models

This commit is contained in:
Dominik Pschenitschni 2022-06-23 03:22:21 +02:00
parent 74ad6e65e8
commit 797de0c543
No known key found for this signature in database
GPG key ID: B257AC0149F43A77
33 changed files with 367 additions and 186 deletions

View file

@ -1,10 +1,18 @@
import AbstractModel from './abstractModel'
import type TeamModel from './team'
import type {Right} from '@/models/constants/rights'
/**
* This class is a base class for common team sharing model.
* It is extended in a way so it can be used for namespaces as well for lists.
*/
export default class TeamShareBaseModel extends AbstractModel {
teamId: TeamModel['id']
right: Right
created: Date
updated: Date
constructor(data) {
super(data)
this.created = new Date(this.created)