Flatten application into repository root

This commit is contained in:
Hermes Agent
2026-09-20 13:46:43 +00:00
parent 2e20e5472f
commit ab6aff2d84
20 changed files with 0 additions and 428 deletions
@@ -0,0 +1,20 @@
-- Run once against an existing PnPaaS database.
-- Existing active/suspended accounts remain unchanged.
ALTER TABLE users
MODIFY status ENUM('pending', 'active', 'suspended') NOT NULL DEFAULT 'pending';
CREATE TABLE IF NOT EXISTS account_activation_tokens (
id BIGINT UNSIGNED NOT NULL AUTO_INCREMENT,
user_id BIGINT UNSIGNED NOT NULL,
token_hash CHAR(64) NOT NULL,
expires_at DATETIME NOT NULL,
used_at DATETIME NULL,
requested_ip VARCHAR(45) NULL,
created_at TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
PRIMARY KEY (id),
UNIQUE KEY uq_account_activation_token_hash (token_hash),
KEY idx_account_activation_user (user_id),
KEY idx_account_activation_expiry (expires_at),
CONSTRAINT fk_account_activation_user FOREIGN KEY (user_id) REFERENCES users (id)
ON UPDATE CASCADE ON DELETE CASCADE
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;