aboutsummaryrefslogtreecommitdiffstats
path: root/packages/pipeline/src/models/transaction.ts
diff options
context:
space:
mode:
authorAlex Browne <stephenalexbrowne@gmail.com>2018-09-18 02:27:38 +0800
committerFred Carlsen <fred@sjelfull.no>2018-12-06 19:01:16 +0800
commitdda44500c52a4b72f6a27fb2384a3f43100a1b26 (patch)
tree49de937e27a2e0bfbc925493c881f411366df513 /packages/pipeline/src/models/transaction.ts
parent7b81bd831fb4b43380ba4bc256d154ab0b5f8fca (diff)
downloaddexon-sol-tools-dda44500c52a4b72f6a27fb2384a3f43100a1b26.tar
dexon-sol-tools-dda44500c52a4b72f6a27fb2384a3f43100a1b26.tar.gz
dexon-sol-tools-dda44500c52a4b72f6a27fb2384a3f43100a1b26.tar.bz2
dexon-sol-tools-dda44500c52a4b72f6a27fb2384a3f43100a1b26.tar.lz
dexon-sol-tools-dda44500c52a4b72f6a27fb2384a3f43100a1b26.tar.xz
dexon-sol-tools-dda44500c52a4b72f6a27fb2384a3f43100a1b26.tar.zst
dexon-sol-tools-dda44500c52a4b72f6a27fb2384a3f43100a1b26.zip
Rebase pipeline branch off development
Diffstat (limited to 'packages/pipeline/src/models/transaction.ts')
-rw-r--r--packages/pipeline/src/models/transaction.ts36
1 files changed, 36 insertions, 0 deletions
diff --git a/packages/pipeline/src/models/transaction.ts b/packages/pipeline/src/models/transaction.ts
new file mode 100644
index 000000000..715cc9480
--- /dev/null
+++ b/packages/pipeline/src/models/transaction.ts
@@ -0,0 +1,36 @@
+const transaction = {
+ tableName: 'transactions',
+ tableProperties: {
+ txn_hash: {
+ type: 'char(66)',
+ },
+ block_hash: {
+ type: 'char(66)',
+ },
+ block_number: {
+ type: 'bigint',
+ },
+ gas_used: {
+ type: 'varchar',
+ },
+ gas_price: {
+ type: 'varchar',
+ },
+ method_id: {
+ type: 'char(10)',
+ },
+ salt: {
+ type: 'varchar',
+ },
+ },
+};
+const logToTransactionSchemaMapping: any = {
+ hash: 'txn_hash',
+ gas: 'gas_used',
+ gasPrice: 'gas_price',
+ blockHash: 'block_hash',
+ blockNumber: 'block_number',
+ method_id: 'method_id',
+ salt: 'salt',
+};
+export { transaction, logToTransactionSchemaMapping };