mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-16 12:50:38 +00:00
feat: Currencies CRUD.
This commit is contained in:
@@ -243,6 +243,13 @@ factory.define('option', 'options', async () => {
|
||||
};
|
||||
});
|
||||
|
||||
factory.define('currency', 'currencies', async () => {
|
||||
return {
|
||||
currency_name: faker.lorem.slug(),
|
||||
currency_code: 'USD',
|
||||
};
|
||||
});
|
||||
|
||||
factory.define('budget', 'budgets', async () => {
|
||||
return {
|
||||
name: faker.lorem.slug(),
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
|
||||
exports.up = function(knex) {
|
||||
return knex.schema.createTable('currencies', table => {
|
||||
table.increments();
|
||||
table.string('currency_name');
|
||||
table.string('currency_code', 4);
|
||||
})
|
||||
};
|
||||
|
||||
exports.down = function(knex) {
|
||||
return knex.schema.dropTableIfExists('currencies');
|
||||
};
|
||||
Reference in New Issue
Block a user