<?php

class Migration_20250821020054_payment_proofs
{
    public static function up(PDO $pdo)
    {
        $pdo->exec("
            CREATE TABLE payment_proofs (
                id INT AUTO_INCREMENT PRIMARY KEY,
                property_id INT NOT NULL,
                user_id INT NOT NULL,
                user_role VARCHAR(20) NOT NULL,
                payment_image VARCHAR(255) NOT NULL,
                is_pending Boolean DEFAULT 1,
                created_at DATETIME DEFAULT CURRENT_TIMESTAMP
            )
        ");
    }

    public static function down(PDO $pdo)
    {
        $pdo->exec("DROP TABLE IF EXISTS payment_proofs");
    }
}