1
0

feat: don't handle child projects and instead only save the ids

This commit is contained in:
kolaente
2023-03-29 16:09:18 +02:00
parent 26bec05174
commit 760efa854d
5 changed files with 36 additions and 20 deletions

View File

@ -22,7 +22,7 @@ export default class ProjectModel extends AbstractModel<IProject> implements IPr
subscription: ISubscription = null
position = 0
backgroundBlurHash = ''
childProjects = []
childProjectIds = []
parentProjectId = 0
created: Date = null
@ -47,7 +47,7 @@ export default class ProjectModel extends AbstractModel<IProject> implements IPr
this.subscription = new SubscriptionModel(this.subscription)
}
this.childProjects = this.childProjects.map(p => new ProjectModel(p))
this.childProjectIds = this.childProjects?.map(p => p.id) || []
this.created = new Date(this.created)
this.updated = new Date(this.updated)