Skip to content

Commit

Permalink
feat: sync data from simulator
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelTaylor3D committed Jan 24, 2022
1 parent e6d3d53 commit 3aa019e
Show file tree
Hide file tree
Showing 32 changed files with 361 additions and 607 deletions.
17 changes: 6 additions & 11 deletions seeders/20211209205139-add-units.cjs
Original file line number Diff line number Diff line change
@@ -1,20 +1,15 @@
'use strict';
const UnitStub = require('../src/models/units/units.stub.json');
const JunctionStub = [
{
warehouseUnitId: '5c960ac1-a180-45a4-9850-be177e26d2fb',
qualificationId: '702cafbb-c624-4273-9cdc-c617ad5675df',
},
{
warehouseUnitId: '5c960ac1-a180-45a4-9850-be177e26d2fb',
qualificationId: '76903895-840e-406c-b2a0-f90244acf02d',
},
];
const QualificationUnitStub = require('../src/models/qualificationUnits/qualificationUnits.stub.json');

module.exports = {
up: async (queryInterface) => {
await queryInterface.bulkInsert('units', UnitStub, {});
await queryInterface.bulkInsert('qualification_unit', JunctionStub, {});
await queryInterface.bulkInsert(
'qualification_unit',
QualificationUnitStub,
{},
);
},

down: async (queryInterface) => {
Expand Down
2 changes: 1 addition & 1 deletion src/controllers/vintage.controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export const findAll = async (req, res) => {
try {
await assertHomeOrgExists();
const homeOrg = await Organization.getHomeOrg();
console.log({ orgUid: Object.keys(homeOrg)[0] });

return res.json(
await Vintage.findAll({
where: { orgUid: Object.keys(homeOrg)[0] },
Expand Down
28 changes: 0 additions & 28 deletions src/fullnode/data-layer-utils.js

This file was deleted.

69 changes: 0 additions & 69 deletions src/fullnode/dataLayerReadService.js

This file was deleted.

114 changes: 0 additions & 114 deletions src/fullnode/dataLayerWriteServiceOld.js

This file was deleted.

39 changes: 0 additions & 39 deletions src/fullnode/dispatcher.js

This file was deleted.

4 changes: 2 additions & 2 deletions src/fullnode/index.js
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
export * from './dataLayerWriteService';
export * from './dataLayerReadService';
export * from './writeService';
export * from './syncService';
Loading

0 comments on commit 3aa019e

Please sign in to comment.