1
0

Migrate all timestamps to real iso dates (#594)

Fix query param name

Add option to include null results when filtering

Always set db time to gmt

Fix null filter

Fix timezone setting for todoist parsing

Fix timezone setting for wunderlist parsing

Fix import

Fix caldav reminder parsing

Use timezone from config

Add error and test for invalid filter values

Fix integration tests

Remove task collection date hack

Fix task filter

Fix lint

Fix tests and fixtures for date timezone stuff

Properly set timezone

Change fixtures time zone to gmt

Set db timezone

Set created and updated timestamps for all fixtures

Fix lint

Fix test fixtures

Fix misspell

Fix test fixtures

Partially fix tests

Remove timeutil package

Remove adding _unix suffix hack

Remove _unix suffix

Move all timeutil.TimeStamp to time.Time

Remove all Unix suffixes in field names

Add better error messages when running migrations

Make sure to not migrate 0 unix timestamps to 1970 iso dates

Add migration script for sqlite

Add converting sqlite values

Convert 0 unix timestamps to null in postgres

Convert 0 to null in timestamps

Automatically rename _unix suffix

Add all tables and columns for migration

Fix sql migration query for mysql

Fail with an error if trying to use an unsupported dbms

Co-authored-by: kolaente <k@knt.li>
Reviewed-on: https://kolaente.dev/vikunja/api/pulls/594
This commit is contained in:
konrad
2020-06-27 17:04:01 +00:00
parent e17cac854a
commit 08205008e7
83 changed files with 2208 additions and 1257 deletions

View File

@ -5,8 +5,8 @@
identifier: test1
owner_id: 1
namespace_id: 1
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 2
title: Test2
@ -14,8 +14,8 @@
identifier: test2
owner_id: 3
namespace_id: 1
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 3
title: Test3
@ -23,8 +23,8 @@
identifier: test3
owner_id: 3
namespace_id: 2
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 4
title: Test4
@ -32,8 +32,8 @@
identifier: test4
owner_id: 3
namespace_id: 3
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 5
title: Test5
@ -41,8 +41,8 @@
identifier: test5
owner_id: 5
namespace_id: 5
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 6
title: Test6
@ -50,8 +50,8 @@
identifier: test6
owner_id: 6
namespace_id: 6
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 7
title: Test7
@ -59,8 +59,8 @@
identifier: test7
owner_id: 6
namespace_id: 6
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 8
title: Test8
@ -68,8 +68,8 @@
identifier: test8
owner_id: 6
namespace_id: 6
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 9
title: Test9
@ -77,8 +77,8 @@
identifier: test9
owner_id: 6
namespace_id: 6
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 10
title: Test10
@ -86,8 +86,8 @@
identifier: test10
owner_id: 6
namespace_id: 6
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 11
title: Test11
@ -95,8 +95,8 @@
identifier: test11
owner_id: 6
namespace_id: 6
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 12
title: Test12
@ -104,8 +104,8 @@
identifier: test12
owner_id: 6
namespace_id: 7
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 13
title: Test13
@ -113,8 +113,8 @@
identifier: test13
owner_id: 6
namespace_id: 8
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 14
title: Test14
@ -122,8 +122,8 @@
identifier: test14
owner_id: 6
namespace_id: 9
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 15
title: Test15
@ -131,8 +131,8 @@
identifier: test15
owner_id: 6
namespace_id: 10
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 16
title: Test16
@ -140,8 +140,8 @@
identifier: test16
owner_id: 6
namespace_id: 11
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 17
title: Test17
@ -149,8 +149,8 @@
identifier: test17
owner_id: 6
namespace_id: 12
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
# This list is owned by user 7, and several other users have access to it via different methods.
# It is used to test the listUsers method.
-
@ -160,8 +160,8 @@
identifier: test18
owner_id: 7
namespace_id: 13
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 19
title: Test19
@ -169,8 +169,8 @@
identifier: test19
owner_id: 7
namespace_id: 14
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 20
title: Test20
@ -178,8 +178,8 @@
identifier: test20
owner_id: 13
namespace_id: 15
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 21
title: Test21 archived through namespace
@ -187,8 +187,8 @@
identifier: test21
owner_id: 1
namespace_id: 16
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12
-
id: 22
title: Test22 archived individually
@ -197,5 +197,5 @@
owner_id: 1
namespace_id: 1
is_archived: 1
updated: 0
created: 0
updated: 2018-12-02 15:13:12
created: 2018-12-01 15:13:12