1
0
mirror of https://github.com/pocketbase/pocketbase.git synced 2025-11-30 00:58:30 +02:00

[#2602] added common int types support when scanning types.DateTime

This commit is contained in:
Gani Georgiev
2023-05-30 20:43:20 +03:00
parent dbbc1e25ca
commit 3122223a71
3 changed files with 8 additions and 1 deletions

View File

@@ -78,7 +78,7 @@ func (d *DateTime) Scan(value any) error {
d.t = v.Time()
case time.Time:
d.t = v
case int:
case int, int64, int32, uint, uint64, uint32:
d.t = cast.ToTime(v)
case string:
if v == "" {