Initial commit

This commit is contained in:
2021-03-10 21:59:38 -07:00
parent 4e533f5e7b
commit fd54a8e4dd
16 changed files with 8096 additions and 0 deletions

View File

@ -0,0 +1,25 @@
import { Knex } from "knex";
export async function up(knex: Knex) {
await knex.schema.createTable("voicemails", (table) => {
table.bigInteger("messageId").primary().notNullable();
table.bigInteger("extensionId").notNullable();
table.dateTime("received").notNullable();
table.string("toNumber", 32).notNullable();
table.string("extensionNumber", 16).notNullable();
table.string("extensionName", 64).notNullable();
table.string("fromNumber", 32).notNullable();
table.string("fromName", 64).notNullable();
table.integer("duration").notNullable();
table.string("transcriptionStatus", 32).notNullable();
table.text("transcription");
table.integer("ticketId");
table.integer("contactId");
table.string("contactableType", 32);
table.integer("contactableId");
});
}
export async function down(knex: Knex) {
await knex.schema.dropTableIfExists("voicemails");
}