Skip to content

Commit

Permalink
Disputes: Add transaction hash (#9)
Browse files Browse the repository at this point in the history
  • Loading branch information
facuspagnuolo committed Dec 19, 2019
1 parent 7ac6032 commit e6502ba
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions schema.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ type Dispute @entity {
state: DisputeState!
metadata: String!
rounds: [AdjudicationRound!] @derivedFrom(field: "dispute")
txHash: String!
createdAt: BigInt!
}

Expand Down
1 change: 1 addition & 0 deletions src/DisputeManager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ export function handleNewDispute(event: NewDispute): void {
dispute.lastRoundId = disputeResult.value4
dispute.createTermId = disputeResult.value5
dispute.createdAt = event.block.timestamp
dispute.txHash = event.transaction.hash.toString()
dispute.save()

updateRound(event.params.disputeId, dispute.lastRoundId, event)
Expand Down

0 comments on commit e6502ba

Please sign in to comment.