add block to dt orders (#62)

This commit is contained in:
Alex Coseru 2021-03-25 10:44:50 +02:00 committed by GitHub
parent 69ec3ec209
commit 59800e7992
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 0 deletions

View File

@ -167,6 +167,7 @@ type TokenOrder @entity {
timestamp: Int! timestamp: Int!
tx: Bytes tx: Bytes
block: Int!
} }
type TokenBalance @entity { type TokenBalance @entity {

View File

@ -121,6 +121,7 @@ export function handleOrderStarted(event: OrderStarted): void {
} }
order.marketFee = tokenToDecimal(event.params.marketFee.toBigDecimal(), 18) order.marketFee = tokenToDecimal(event.params.marketFee.toBigDecimal(), 18)
order.tx = tx order.tx = tx
order.block = event.block.number.toI32()
order.save() order.save()