initial commit
This commit is contained in:
20
internal/repository/postgres/skill/model.go
Normal file
20
internal/repository/postgres/skill/model.go
Normal file
@@ -0,0 +1,20 @@
|
||||
package skill
|
||||
|
||||
import (
|
||||
"time"
|
||||
|
||||
"github.com/google/uuid"
|
||||
"gorm.io/gorm"
|
||||
)
|
||||
|
||||
type SkillModel struct {
|
||||
ID uuid.UUID `gorm:"type:uuid;primaryKey;default:gen_random_uuid()"`
|
||||
Name string `gorm:"column:name;type:text;not null"`
|
||||
CreatedAt time.Time `gorm:"column:created_at;type:timestamptz;not null"`
|
||||
UpdatedAt time.Time `gorm:"column:updated_at;type:timestamptz;not null"`
|
||||
DeletedAt gorm.DeletedAt `gorm:"column:deleted_at;type:timestamptz;index"`
|
||||
}
|
||||
|
||||
func (SkillModel) TableName() string {
|
||||
return "skills"
|
||||
}
|
||||
Reference in New Issue
Block a user