package domain

import (
	"time"
)

const (
	DeveloperRequestStatusPending   = "pending"
	DeveloperRequestStatusApproved  = "approved"
	DeveloperRequestStatusRejected  = "rejected"
	DeveloperRequestStatusCancelled = "cancelled"
)

// DeveloperRequest represents a user's application to become a developer.
type DeveloperRequest struct {
	ID           uint      `gorm:"primaryKey" json:"id"`
	UserID       string    `gorm:"index;not null" json:"userId"` // Kratos User ID
	TenantID     string    `gorm:"index;not null" json:"tenantId"`
	Name         string    `gorm:"not null" json:"name"`
	Organization string    `json:"organization"`
	Email        string    `json:"email"`
	Phone        string    `json:"phone"`
	Role         string    `json:"role"`
	Reason       string    `json:"reason"`
	Status       string    `gorm:"default:'pending';not null" json:"status"` // pending, approved, rejected, cancelled
	AdminNotes   string    `json:"adminNotes"`
	CreatedAt    time.Time `json:"createdAt"`
	UpdatedAt    time.Time `json:"updatedAt"`
}
