mirror of
https://github.com/photoprism/photoprism.git
synced 2025-12-12 00:34:13 +01:00
Database column types are now UPPERCASE so that developers can easily recognize them. After upgrading to GORM 2.0, we can use generic types instead. Signed-off-by: Michael Mayer <michael@liquidbytes.net>
This commit is contained in:
@@ -11,9 +11,9 @@ type DuplicatesMap map[string]Duplicate
|
||||
|
||||
// Duplicate represents an exact file duplicate.
|
||||
type Duplicate struct {
|
||||
FileName string `gorm:"type:varbinary(768);primary_key;" json:"Name" yaml:"Name"`
|
||||
FileRoot string `gorm:"type:varbinary(16);primary_key;default:'/';" json:"Root" yaml:"Root,omitempty"`
|
||||
FileHash string `gorm:"type:varbinary(128);default:'';index" json:"Hash" yaml:"Hash,omitempty"`
|
||||
FileName string `gorm:"type:VARBINARY(768);primary_key;" json:"Name" yaml:"Name"`
|
||||
FileRoot string `gorm:"type:VARBINARY(16);primary_key;default:'/';" json:"Root" yaml:"Root,omitempty"`
|
||||
FileHash string `gorm:"type:VARBINARY(128);default:'';index" json:"Hash" yaml:"Hash,omitempty"`
|
||||
FileSize int64 `json:"Size" yaml:"Size,omitempty"`
|
||||
ModTime int64 `json:"ModTime" yaml:"-"`
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user