/
Agreement.sol
33 lines (26 loc) 路 1.11 KB
/
Agreement.sol
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
pragma solidity ^0.4.15;
import "./standards/arbitration/Arbitrable.sol";
contract Agreement is Arbitrable /* AragonApp/Trigger */ {
address[] parties;
// TODO: Probably needs to be moved into an 'initialize()' function at some point
constructor(address _court, address[] _parties)
public
Arbitrable(_court) {
parties = _parties;
}
function canSubmitEvidence(uint256 _disputeId, address _submitter) public view returns (bool) {
// TODO: should check court to see whether evidence can be submitted for this particular dispute at this point
uint256 partiesLength = parties.length;
for (uint256 i = 0; i < partiesLength; i++) {
if (parties[i] == msg.sender) {
return true;
}
}
}
/**
* @dev Execute a ruling of a dispute.
* @param _disputeId Id of the dispute in the Court contract.
* @param _ruling Ruling given by the arbitrator. Note that 0 is reserved for "Not able/wanting to make a decision".
*/
function _executeRuling(uint256 _disputeId, uint256 _ruling) internal;
}