aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlex Browne <stephenalexbrowne@gmail.com>2018-11-14 07:33:43 +0800
committerFred Carlsen <fred@sjelfull.no>2018-12-13 01:16:08 +0800
commitd842078997c743aa838f723da05ed405c42e834f (patch)
treecdeb34681d05468f1da9e4c8941a2dba2340941a
parent7f574949a45bac4630d53dca36c745406570c2b6 (diff)
downloaddexon-sol-tools-d842078997c743aa838f723da05ed405c42e834f.tar
dexon-sol-tools-d842078997c743aa838f723da05ed405c42e834f.tar.gz
dexon-sol-tools-d842078997c743aa838f723da05ed405c42e834f.tar.bz2
dexon-sol-tools-d842078997c743aa838f723da05ed405c42e834f.tar.lz
dexon-sol-tools-d842078997c743aa838f723da05ed405c42e834f.tar.xz
dexon-sol-tools-d842078997c743aa838f723da05ed405c42e834f.tar.zst
dexon-sol-tools-d842078997c743aa838f723da05ed405c42e834f.zip
Implement scraping sra orders from radar relay
-rw-r--r--packages/pipeline/src/entities/sra_order.ts4
-rw-r--r--packages/pipeline/src/parsers/sra_orders/index.ts4
-rw-r--r--packages/pipeline/test/parsers/sra_orders/index_test.ts2
3 files changed, 2 insertions, 8 deletions
diff --git a/packages/pipeline/src/entities/sra_order.ts b/packages/pipeline/src/entities/sra_order.ts
index 4b7f652d3..2bdb1ba2e 100644
--- a/packages/pipeline/src/entities/sra_order.ts
+++ b/packages/pipeline/src/entities/sra_order.ts
@@ -19,9 +19,9 @@ export class SraOrder {
public feeRecipientAddress!: string;
@Column({ name: 'sender_address' })
public senderAddress!: string;
- @Column({ name: 'maker_asset_amount' })
+ @Column({ name: 'maker_asset_filled_amount' })
public makerAssetAmount!: string;
- @Column({ name: 'taker_asset_amount' })
+ @Column({ name: 'taker_asset_filled_amount' })
public takerAssetAmount!: string;
@Column({ name: 'maker_fee' })
public makerFee!: string;
diff --git a/packages/pipeline/src/parsers/sra_orders/index.ts b/packages/pipeline/src/parsers/sra_orders/index.ts
index 3d7f73fca..800521955 100644
--- a/packages/pipeline/src/parsers/sra_orders/index.ts
+++ b/packages/pipeline/src/parsers/sra_orders/index.ts
@@ -30,10 +30,6 @@ export function _convertToEntity(apiOrder: APIOrder): SraOrder {
sraOrder.exchangeAddress = apiOrder.order.exchangeAddress;
sraOrder.orderHashHex = orderHashUtils.getOrderHashHex(apiOrder.order);
- // TODO(albrow): Set these fields to the correct values upstack.
- sraOrder.lastUpdatedTimestamp = 0;
- sraOrder.firstSeenTimestamp = 0;
-
sraOrder.makerAddress = apiOrder.order.makerAddress;
sraOrder.takerAddress = apiOrder.order.takerAddress;
sraOrder.feeRecipientAddress = apiOrder.order.feeRecipientAddress;
diff --git a/packages/pipeline/test/parsers/sra_orders/index_test.ts b/packages/pipeline/test/parsers/sra_orders/index_test.ts
index 4b2e7c2d0..534d84ab3 100644
--- a/packages/pipeline/test/parsers/sra_orders/index_test.ts
+++ b/packages/pipeline/test/parsers/sra_orders/index_test.ts
@@ -37,8 +37,6 @@ describe('sra_orders', () => {
const expected = new SraOrder();
expected.exchangeAddress = '0x4f833a24e1f95d70f028921e27040ca56e09ab0b';
expected.orderHashHex = '0x1bdbeb0d088a33da28b9ee6d94e8771452f90f4a69107da2fa75195d61b9a1c9';
- expected.lastUpdatedTimestamp = 0;
- expected.firstSeenTimestamp = 0;
expected.makerAddress = '0xb45df06e38540a675fdb5b598abf2c0dbe9d6b81';
expected.takerAddress = '0x0000000000000000000000000000000000000000';
expected.feeRecipientAddress = '0xa258b39954cef5cb142fd567a46cddb31a670124';