perform test

test to courses

Signed-off-by: Kenneth Obsequio <k80308392@gmail.com>
This commit is contained in:
2026-06-24 12:48:51 +08:00
parent 358fecb510
commit 9b8577b79b
27 changed files with 1122 additions and 221 deletions
@@ -0,0 +1,17 @@
'use strict';
// quiz_attempts.started_at and quiz_attempts.status were added via raw SQL
// during an earlier development session. The assessment_sessions table now owns
// session lifecycle; quiz_attempts are always-graded completed records only.
module.exports = {
async up(queryInterface, Sequelize) {
const tableDesc = await queryInterface.describeTable('quiz_attempts');
if (tableDesc.started_at) await queryInterface.removeColumn('quiz_attempts', 'started_at');
if (tableDesc.status) await queryInterface.removeColumn('quiz_attempts', 'status');
},
async down(queryInterface, Sequelize) {
await queryInterface.addColumn('quiz_attempts', 'started_at', { type: Sequelize.DATE, allowNull: true });
await queryInterface.addColumn('quiz_attempts', 'status', { type: Sequelize.STRING(20), allowNull: true });
},
};