Files
moteva/server/internal/infrastructure/postgres/db/models.go
T

197 lines
7.9 KiB
Go
Raw Normal View History

// Code generated by sqlc. DO NOT EDIT.
// versions:
// sqlc v1.30.0
package db
import (
"github.com/jackc/pgx/v5/pgtype"
)
type AgentMessage struct {
ID string `json:"id"`
ProjectID string `json:"project_id"`
UserID pgtype.UUID `json:"user_id"`
Role string `json:"role"`
MessageType string `json:"message_type"`
Title string `json:"title"`
Content string `json:"content"`
ThreadID string `json:"thread_id"`
ActionID string `json:"action_id"`
StepID string `json:"step_id"`
ToolCallID string `json:"tool_call_id"`
Name string `json:"name"`
ToolHint string `json:"tool_hint"`
Status string `json:"status"`
CreatedAt pgtype.Timestamptz `json:"created_at"`
}
type AuthVerificationCode struct {
ID string `json:"id"`
Region string `json:"region"`
Channel string `json:"channel"`
Target string `json:"target"`
Purpose string `json:"purpose"`
CodeHash string `json:"code_hash"`
Attempts int32 `json:"attempts"`
ExpiresAt pgtype.Timestamptz `json:"expires_at"`
ConsumedAt pgtype.Timestamptz `json:"consumed_at"`
CreatedAt pgtype.Timestamptz `json:"created_at"`
}
type BrandKit struct {
ID string `json:"id"`
UserID pgtype.UUID `json:"user_id"`
Name string `json:"name"`
Document []byte `json:"document"`
IsDefault bool `json:"is_default"`
CreatedAt pgtype.Timestamptz `json:"created_at"`
UpdatedAt pgtype.Timestamptz `json:"updated_at"`
}
type CanvasConnection struct {
ID string `json:"id"`
ProjectID string `json:"project_id"`
UserID pgtype.UUID `json:"user_id"`
FromNodeID string `json:"from_node_id"`
ToNodeID string `json:"to_node_id"`
}
type CanvasNode struct {
ID string `json:"id"`
ProjectID string `json:"project_id"`
UserID pgtype.UUID `json:"user_id"`
NodeType string `json:"node_type"`
Title string `json:"title"`
X float64 `json:"x"`
Y float64 `json:"y"`
Width float64 `json:"width"`
Height float64 `json:"height"`
Content string `json:"content"`
Tone string `json:"tone"`
Status string `json:"status"`
SortOrder int32 `json:"sort_order"`
ParentID string `json:"parent_id"`
LayerRole string `json:"layer_role"`
FontSize float64 `json:"font_size"`
FontFamily string `json:"font_family"`
FontWeight string `json:"font_weight"`
Color string `json:"color"`
TextAlign string `json:"text_align"`
LineHeight float64 `json:"line_height"`
LetterSpacing float64 `json:"letter_spacing"`
TextDecoration string `json:"text_decoration"`
TextTransform string `json:"text_transform"`
Opacity float64 `json:"opacity"`
FillColor string `json:"fill_color"`
StrokeColor string `json:"stroke_color"`
StrokeWidth float64 `json:"stroke_width"`
StrokeStyle string `json:"stroke_style"`
FlipX bool `json:"flip_x"`
FlipY bool `json:"flip_y"`
Rotation float64 `json:"rotation"`
}
type CanvasSnapshot struct {
ID string `json:"id"`
ProjectID string `json:"project_id"`
UserID pgtype.UUID `json:"user_id"`
Version string `json:"version"`
Canvas string `json:"canvas"`
ViewportJson []byte `json:"viewport_json"`
NodesJson []byte `json:"nodes_json"`
ConnectionsJson []byte `json:"connections_json"`
CreatedAt pgtype.Timestamptz `json:"created_at"`
}
type MockupBlob struct {
DataID string `json:"data_id"`
Width int32 `json:"width"`
Height int32 `json:"height"`
Data []byte `json:"data"`
CreatedAt pgtype.Timestamptz `json:"created_at"`
}
type OutboxEvent struct {
ID string `json:"id"`
UserID pgtype.UUID `json:"user_id"`
AggregateType string `json:"aggregate_type"`
AggregateID string `json:"aggregate_id"`
EventType string `json:"event_type"`
ThreadID string `json:"thread_id"`
PayloadJson []byte `json:"payload_json"`
Status string `json:"status"`
PublishedAt pgtype.Timestamptz `json:"published_at"`
CreatedAt pgtype.Timestamptz `json:"created_at"`
}
type Project struct {
ID string `json:"id"`
UserID pgtype.UUID `json:"user_id"`
Title string `json:"title"`
Brief string `json:"brief"`
Status string `json:"status"`
Thumbnail string `json:"thumbnail"`
Canvas string `json:"canvas"`
Version string `json:"version"`
SnapshotID string `json:"snapshot_id"`
LastThreadID string `json:"last_thread_id"`
BrandKitID pgtype.Text `json:"brand_kit_id"`
ViewportX float64 `json:"viewport_x"`
ViewportY float64 `json:"viewport_y"`
ViewportK float64 `json:"viewport_k"`
UpdatedAt pgtype.Timestamptz `json:"updated_at"`
}
type ProjectShareMember struct {
ID pgtype.UUID `json:"id"`
ProjectID string `json:"project_id"`
IdentifierType string `json:"identifier_type"`
IdentifierHash []byte `json:"identifier_hash"`
IdentifierCiphertext []byte `json:"identifier_ciphertext"`
Permission string `json:"permission"`
CreatedAt pgtype.Timestamptz `json:"created_at"`
UpdatedAt pgtype.Timestamptz `json:"updated_at"`
}
type ProjectSharePolicy struct {
ProjectID string `json:"project_id"`
OwnerID pgtype.UUID `json:"owner_id"`
TokenHash []byte `json:"token_hash"`
TokenCiphertext []byte `json:"token_ciphertext"`
LinkPermission string `json:"link_permission"`
PolicyVersion int64 `json:"policy_version"`
CreatedAt pgtype.Timestamptz `json:"created_at"`
UpdatedAt pgtype.Timestamptz `json:"updated_at"`
}
type ProjectShareVisit struct {
ID string `json:"id"`
ProjectID string `json:"project_id"`
VisitorHash []byte `json:"visitor_hash"`
UserID pgtype.UUID `json:"user_id"`
VisitCount int64 `json:"visit_count"`
FirstSeenAt pgtype.Timestamptz `json:"first_seen_at"`
LastSeenAt pgtype.Timestamptz `json:"last_seen_at"`
}
type User struct {
ID pgtype.UUID `json:"id"`
Email string `json:"email"`
Name string `json:"name"`
Status string `json:"status"`
CreatedAt pgtype.Timestamptz `json:"created_at"`
UpdatedAt pgtype.Timestamptz `json:"updated_at"`
Region string `json:"region"`
PhoneCountryCode string `json:"phone_country_code"`
Phone string `json:"phone"`
AvatarUrl string `json:"avatar_url"`
PasswordHash string `json:"password_hash"`
WechatOpenID string `json:"wechat_open_id"`
WechatUnionID string `json:"wechat_union_id"`
GoogleSubject string `json:"google_subject"`
PhoneVerifiedAt pgtype.Timestamptz `json:"phone_verified_at"`
EmailVerifiedAt pgtype.Timestamptz `json:"email_verified_at"`
LastLoginAt pgtype.Timestamptz `json:"last_login_at"`
}