Skip to content

Commit

Permalink
feat: feedback table (#5721)
Browse files Browse the repository at this point in the history
  • Loading branch information
sjaanus authored Dec 21, 2023
1 parent 12100b3 commit d57e26b
Showing 1 changed file with 28 additions and 0 deletions.
28 changes: 28 additions & 0 deletions src/migrations/20231221143955-feedback-table.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
'use strict';

exports.up = function (db, callback) {
db.runSql(
`
CREATE TABLE IF NOT EXISTS feedback
(
id SERIAL PRIMARY KEY NOT NULL,
category TEXT NOT NULL,
user_type TEXT,
difficulty_score INTEGER,
positive TEXT,
areas_for_improvement TEXT,
created_at TIMESTAMP WITH TIME ZONE DEFAULT now()
);
`,
callback,
);
};

exports.down = function (db, callback) {
db.runSql(
`
DROP TABLE IF EXISTS feedback;
`,
callback,
);
};

0 comments on commit d57e26b

Please sign in to comment.