fix(import): make sure importing works if parent / child projects are created in a different order

Resolves https://community.vikunja.io/t/migrating-from-self-hosted-instance/1805
This commit is contained in:
kolaente 2023-12-03 14:14:27 +01:00
parent 66b44da85b
commit d35c30dd0c
Signed by untrusted user: konrad
GPG Key ID: F40E70337AB24C9B
1 changed files with 1 additions and 0 deletions

View File

@ -60,6 +60,7 @@ func insertFromStructure(s *xorm.Session, str []*models.ProjectWithTasksAndBucke
if p.ParentProjectID != 0 {
childRelations[p.ParentProjectID] = append(childRelations[p.ParentProjectID], oldID)
p.ParentProjectID = 0
}
p.ID = 0