18 lines
596 B
JavaScript
18 lines
596 B
JavaScript
|
|
// Migration: Add dismissed_at column to ivanti_fp_submissions table
|
||
|
|
const pool = require('../db');
|
||
|
|
|
||
|
|
async function run() {
|
||
|
|
console.log('Starting FP submissions dismissed migration...');
|
||
|
|
try {
|
||
|
|
await pool.query(`ALTER TABLE ivanti_fp_submissions ADD COLUMN IF NOT EXISTS dismissed_at TIMESTAMPTZ DEFAULT NULL`);
|
||
|
|
console.log('✓ dismissed_at column added (or already exists)');
|
||
|
|
} catch (err) {
|
||
|
|
console.error('Error adding dismissed_at column:', err.message);
|
||
|
|
process.exit(1);
|
||
|
|
}
|
||
|
|
console.log('Migration complete.');
|
||
|
|
process.exit(0);
|
||
|
|
}
|
||
|
|
|
||
|
|
run();
|