pcmt/ent/migrate/schema.go
surtur d83cda7332
All checks were successful
continuous-integration/drone/push Build is passing
go(ent(user)): add last_login field+gen
2023-08-10 19:27:14 +02:00

75 lines
2.5 KiB
Go

// Code generated by ent, DO NOT EDIT.
package migrate
import (
"entgo.io/ent/dialect/sql/schema"
"entgo.io/ent/schema/field"
)
var (
// HibPsColumns holds the columns for the "hib_ps" table.
HibPsColumns = []*schema.Column{
{Name: "id", Type: field.TypeUUID, Unique: true},
{Name: "name", Type: field.TypeString, Unique: true},
{Name: "domain", Type: field.TypeString},
{Name: "breach_date", Type: field.TypeTime},
{Name: "added_date", Type: field.TypeTime},
{Name: "modified_date", Type: field.TypeTime},
{Name: "pwn_count", Type: field.TypeInt},
{Name: "description", Type: field.TypeString},
{Name: "dataclasses", Type: field.TypeJSON},
{Name: "is_verified", Type: field.TypeBool, Default: false},
{Name: "is_fabricated", Type: field.TypeBool, Default: false},
{Name: "is_sensitive", Type: field.TypeBool, Default: false},
{Name: "is_retired", Type: field.TypeBool, Default: false},
{Name: "is_spam_list", Type: field.TypeBool, Default: false},
{Name: "is_malware", Type: field.TypeBool, Default: false},
{Name: "logo", Type: field.TypeString},
}
// HibPsTable holds the schema information for the "hib_ps" table.
HibPsTable = &schema.Table{
Name: "hib_ps",
Columns: HibPsColumns,
PrimaryKey: []*schema.Column{HibPsColumns[0]},
}
// SetupsColumns holds the columns for the "setups" table.
SetupsColumns = []*schema.Column{
{Name: "id", Type: field.TypeUUID, Unique: true},
{Name: "set_up_at", Type: field.TypeTime},
}
// SetupsTable holds the schema information for the "setups" table.
SetupsTable = &schema.Table{
Name: "setups",
Columns: SetupsColumns,
PrimaryKey: []*schema.Column{SetupsColumns[0]},
}
// UsersColumns holds the columns for the "users" table.
UsersColumns = []*schema.Column{
{Name: "id", Type: field.TypeUUID, Unique: true},
{Name: "username", Type: field.TypeString, Unique: true},
{Name: "email", Type: field.TypeString, Unique: true},
{Name: "password", Type: field.TypeBytes},
{Name: "is_admin", Type: field.TypeBool, Default: false},
{Name: "is_active", Type: field.TypeBool, Default: true},
{Name: "created_at", Type: field.TypeTime},
{Name: "updated_at", Type: field.TypeTime},
{Name: "last_login", Type: field.TypeTime},
}
// UsersTable holds the schema information for the "users" table.
UsersTable = &schema.Table{
Name: "users",
Columns: UsersColumns,
PrimaryKey: []*schema.Column{UsersColumns[0]},
}
// Tables holds all the tables in the schema.
Tables = []*schema.Table{
HibPsTable,
SetupsTable,
UsersTable,
}
)
func init() {
}