diff options
| author | Andrew Lee <andrew@alee14.me> | 2025-03-30 17:05:51 -0400 |
|---|---|---|
| committer | Andrew Lee <andrew@alee14.me> | 2025-03-30 17:07:09 -0400 |
| commit | 1662608835099ee3176d07d67c6a3c69f716f938 (patch) | |
| tree | 6a891bdc439c32e0c10369d91e55c9b4e444c65f /bot/src/db/migrations/20250330202144-command-usages.js | |
| parent | 3c61c156137984cf61d3517d4d9633ca6de072f6 (diff) | |
| download | AleeBot-1662608835099ee3176d07d67c6a3c69f716f938.tar.gz AleeBot-1662608835099ee3176d07d67c6a3c69f716f938.tar.bz2 AleeBot-1662608835099ee3176d07d67c6a3c69f716f938.zip | |
Fixed issues; Generate bot invite; Added database migrations
Diffstat (limited to 'bot/src/db/migrations/20250330202144-command-usages.js')
| -rw-r--r-- | bot/src/db/migrations/20250330202144-command-usages.js | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/bot/src/db/migrations/20250330202144-command-usages.js b/bot/src/db/migrations/20250330202144-command-usages.js new file mode 100644 index 0000000..095f817 --- /dev/null +++ b/bot/src/db/migrations/20250330202144-command-usages.js @@ -0,0 +1,31 @@ +'use strict'; + +/** @type {import('sequelize-cli').Migration} */ +export const up = async (queryInterface, Sequelize) => { + return await queryInterface.createTable('command-usages', { + id: { + type: Sequelize.INTEGER, + autoIncrement: true, + primaryKey: true + }, + command: { + type: Sequelize.STRING, + allowNull: false + }, + userID: { + type: Sequelize.STRING, + allowNull: false + }, + guildID: { + type: Sequelize.STRING, + allowNull: true + }, + createdAt: { + type: Sequelize.DATE + } + }); +}; + +export const down = async (queryInterface) => { + return await queryInterface.dropTable('command-usages'); +}; |
