@tomei/finance
Version:
NestJS package for finance module
60 lines (57 loc) • 1.4 kB
JavaScript
'use strict';
module.exports = {
async up(queryInterface, Sequelize) {
await queryInterface.createTable('finance_JournalEntry', {
CompanyId: {
type: Sequelize.STRING(30),
allowNull: false,
references: {
model: 'finance_Company',
key: 'CompanyId',
},
onUpdate: 'CASCADE',
onDelete: 'CASCADE',
},
JournalEntryId: {
type: Sequelize.STRING(30),
primaryKey: true,
allowNull: false,
},
JournalBatchNo: {
type: Sequelize.STRING(30),
allowNull: true,
},
Date: {
type: Sequelize.DATE,
allowNull: true,
},
Name: {
type: Sequelize.STRING(200),
allowNull: false,
},
Description: {
type: Sequelize.STRING(1000),
allowNull: true,
},
AccSystemRefId: {
type: Sequelize.STRING(30),
allowNull: true,
},
PostedToAccSystemYN: {
type: Sequelize.ENUM(['Y', 'N']),
allowNull: false,
},
PostedById: {
type: Sequelize.STRING(30),
allowNull: true,
},
PostedDateTime: {
type: Sequelize.DATE,
allowNull: true,
},
});
},
async down(queryInterface) {
await queryInterface.dropTable('finance_JournalEntry');
},
};