registering user works

This commit is contained in:
Florian Hoss 2022-03-30 15:11:58 +02:00
parent faf460470e
commit acdee880e4
4 changed files with 48 additions and 32 deletions

View file

@ -1,6 +1,8 @@
package database
import "gorm.io/gorm"
import (
"gorm.io/gorm"
)
type Database struct {
ORM *gorm.DB
@ -8,7 +10,7 @@ type Database struct {
}
type User struct {
ID int
Username string
Password string
Username string `gorm:"primaryKey"`
Password string
CreatedAt int64 `gorm:"autoCreateTime"`
}