Fix exporting tasks from archived lists
This commit is contained in:
parent
9000f2c3cd
commit
f019ae42bb
1 changed files with 5 additions and 5 deletions
|
@ -123,7 +123,7 @@ func ExportUserData(s *xorm.Session, u *user.User) (err error) {
|
||||||
|
|
||||||
func exportListsAndTasks(s *xorm.Session, u *user.User, wr *zip.Writer) (err error) {
|
func exportListsAndTasks(s *xorm.Session, u *user.User, wr *zip.Writer) (err error) {
|
||||||
|
|
||||||
namspaces, _, _, err := (&Namespace{}).ReadAll(s, u, "", -1, 0)
|
namspaces, _, _, err := (&Namespace{IsArchived: true}).ReadAll(s, u, "", -1, 0)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
@ -173,11 +173,11 @@ func exportListsAndTasks(s *xorm.Session, u *user.User, wr *zip.Writer) (err err
|
||||||
|
|
||||||
listMap := make(map[int64]*ListWithTasksAndBuckets)
|
listMap := make(map[int64]*ListWithTasksAndBuckets)
|
||||||
listIDs := []int64{}
|
listIDs := []int64{}
|
||||||
for _, n := range namespaces {
|
for _, l := range lists {
|
||||||
for _, l := range n.Lists {
|
listMap[l.ID] = &ListWithTasksAndBuckets{
|
||||||
listMap[l.ID] = l
|
List: *l,
|
||||||
listIDs = append(listIDs, l.ID)
|
|
||||||
}
|
}
|
||||||
|
listIDs = append(listIDs, l.ID)
|
||||||
}
|
}
|
||||||
|
|
||||||
taskMap := make(map[int64]*TaskWithComments, len(tasks))
|
taskMap := make(map[int64]*TaskWithComments, len(tasks))
|
||||||
|
|
Loading…
Reference in a new issue