From 9d6217558c6af3532af5b62dbc67ea6cda226e00 Mon Sep 17 00:00:00 2001 From: Spencer Ofwiti Date: Wed, 25 Nov 2020 10:17:37 +0300 Subject: [PATCH] Add user and transaction models. --- src/app/_models/index.ts | 1 + src/app/_models/transaction.ts | 5 +++++ src/app/_models/user.ts | 22 ++++++++++++++++++++++ 3 files changed, 28 insertions(+) create mode 100644 src/app/_models/user.ts diff --git a/src/app/_models/index.ts b/src/app/_models/index.ts index 85f5dcc..6f9f9df 100644 --- a/src/app/_models/index.ts +++ b/src/app/_models/index.ts @@ -1,2 +1,3 @@ export * from './transaction'; export * from './settings'; +export * from './user'; diff --git a/src/app/_models/transaction.ts b/src/app/_models/transaction.ts index 891b810..6cc33fa 100644 --- a/src/app/_models/transaction.ts +++ b/src/app/_models/transaction.ts @@ -1,3 +1,5 @@ +import {User} from './user'; + export class BlocksBloom { low: number; blockFilter: string; @@ -22,7 +24,9 @@ export class Tx { export class Transaction { from: string; + sender: User; to: string; + recipient: User; token: Token; tx: Tx; value: number; @@ -34,5 +38,6 @@ export class Conversion { sourceToken: Token; toValue: number; trader: string; + user: User; tx: Tx; } diff --git a/src/app/_models/user.ts b/src/app/_models/user.ts new file mode 100644 index 0000000..957ebc3 --- /dev/null +++ b/src/app/_models/user.ts @@ -0,0 +1,22 @@ +export class User { + dateRegistered: number; + vcard: { + fn: string; + version: string; + tel: [{ + meta: { + TYP: string; + }; + value: string[]; + }]; + }; + key: { + ethereum: string[]; + }; + location: { + latitude: string; + longitude: string; + external: {}; + }; + selling: string[]; +}