hecha una implementacion que no puede tener coinsidencias
This commit is contained in:
1 parent
1b3ae43d61
commit
389f858369
2 files changed
+16
-16
No files matched your search
+1
-2
@@ -3,8 +3,7 @@ package models
|
||||
import "time"
|
||||
|
||||
type Url struct {
|
||||
Shorturl string `gorm:"primaryKey"`
|
||||
// Id uint64 `gorm: "primaryKey;autoIncrement"`
|
||||
Shorturl int64 `gorm:"primaryKey;autoIncrement:true"`
|
||||
Longurl string `gorm:"uniqueIndex:idx_lurl"`
|
||||
Time time.Time `gorm:"autoCreateTime"`
|
||||
}
|
||||
Reference in new issue
Block a user