dgf-prototype/backend/contractArtifacts/Proposals.json

345 lines
58 KiB
JSON
Raw Permalink Normal View History

{
"_format": "hh-sol-artifact-1",
"contractName": "Proposals",
"sourceName": "contracts/Proposals.sol",
"abi": [
{
"inputs": [
{
"internalType": "contract DAO",
"name": "dao",
"type": "address"
}
],
"stateMutability": "nonpayable",
"type": "constructor"
},
2024-03-29 18:08:30 -05:00
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "uint256",
"name": "proposalIndex",
"type": "uint256"
}
],
"name": "Attestation",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "uint256",
"name": "proposalIndex",
"type": "uint256"
}
],
"name": "NewProposal",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "uint256",
"name": "proposalIndex",
"type": "uint256"
}
],
"name": "ProposalAccepted",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "uint256",
"name": "proposalIndex",
"type": "uint256"
},
{
"indexed": false,
"internalType": "string",
"name": "reason",
"type": "string"
}
],
"name": "ProposalFailed",
"type": "event"
},
{
"anonymous": false,
"inputs": [
{
"indexed": false,
"internalType": "uint256",
"name": "proposalIndex",
"type": "uint256"
},
{
"indexed": false,
"internalType": "uint256",
"name": "poolIndex",
"type": "uint256"
}
],
"name": "ReferendumStarted",
"type": "event"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "proposalIndex",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "amount",
"type": "uint256"
}
],
"name": "attest",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "proposalIndex",
"type": "uint256"
}
],
"name": "evaluateAttestation",
"outputs": [
{
"internalType": "bool",
"name": "",
"type": "bool"
}
],
"stateMutability": "nonpayable",
"type": "function"
},
2024-03-29 18:08:30 -05:00
{
"inputs": [
{
"internalType": "uint256",
"name": "proposalIndex",
"type": "uint256"
}
],
"name": "getPools",
"outputs": [
{
"components": [
{
"internalType": "uint256",
"name": "poolIndex",
"type": "uint256"
},
{
"internalType": "bool",
"name": "started",
"type": "bool"
},
{
"internalType": "bool",
"name": "completed",
"type": "bool"
},
{
"internalType": "uint256",
"name": "stakedFor",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "stakedAgainst",
"type": "uint256"
},
{
"internalType": "bool",
"name": "votePasses",
"type": "bool"
},
{
"internalType": "bool",
"name": "quorumMet",
"type": "bool"
}
],
"internalType": "struct Proposals.Pool[3][3]",
"name": "pools",
"type": "tuple[3][3]"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "bool",
"name": "votePasses",
"type": "bool"
},
{
"internalType": "bool",
"name": "quorumMet",
"type": "bool"
},
{
"internalType": "uint256",
"name": "stakedFor",
"type": "uint256"
},
{
"internalType": "uint256",
"name": "stakedAgainst",
"type": "uint256"
},
{
"internalType": "bytes",
"name": "callbackData",
"type": "bytes"
}
],
"name": "onValidate",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
},
{
"inputs": [],
"name": "proposalCount",
"outputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "uint256",
"name": "",
"type": "uint256"
}
],
"name": "proposals",
"outputs": [
{
"internalType": "address",
"name": "sender",
"type": "address"
},
{
"internalType": "uint256",
"name": "fee",
"type": "uint256"
},
2024-03-29 10:59:29 -05:00
{
"internalType": "uint256",
"name": "remainingFee",
"type": "uint256"
},
{
"internalType": "string",
"name": "postId",
"type": "string"
},
{
"internalType": "uint256",
"name": "startTime",
"type": "uint256"
},
{
"internalType": "enum Proposals.Stage",
"name": "stage",
"type": "uint8"
},
{
"internalType": "uint256",
"name": "attestationTotal",
"type": "uint256"
},
{
"internalType": "bool",
"name": "callbackOnAccepted",
"type": "bool"
},
{
"internalType": "bytes",
"name": "callbackData",
"type": "bytes"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [
{
"internalType": "string",
"name": "postId",
"type": "string"
},
{
"internalType": "uint256[3]",
"name": "durations",
"type": "uint256[3]"
},
{
"internalType": "bool",
"name": "callbackOnAccepted",
"type": "bool"
},
{
"internalType": "bytes",
"name": "callbackData",
"type": "bytes"
}
],
"name": "propose",
"outputs": [
{
"internalType": "uint256",
"name": "proposalIndex",
"type": "uint256"
}
],
"stateMutability": "payable",
"type": "function"
2024-03-29 18:08:30 -05:00
},
{
"inputs": [
{
"internalType": "uint256",
"name": "proposalIndex",
"type": "uint256"
}
],
"name": "reclaimRemainingFee",
"outputs": [],
"stateMutability": "nonpayable",
"type": "function"
}
],
2024-05-02 19:08:53 -05:00
"bytecode": "0x60a06040526040518060600160405280600060ff168152602001600160ff168152602001606460ff1681525060029060036200003d929190620001ef565b5060405180606001604052806000151515158152602001600015151515815260200160011515151581525060059060036200007a92919062000239565b5060405180606001604052806040518060400160405280600160ff168152602001600a60ff1681525081526020016040518060400160405280600160ff168152602001600a60ff1681525081526020016040518060400160405280600160ff168152602001600a60ff168152508152506006906003620000fc929190620002d9565b5060405180606001604052806040518060400160405280600260ff168152602001600360ff1681525081526020016040518060400160405280600260ff168152602001600360ff1681525081526020016040518060400160405280600260ff168152602001600360ff16815250815250600c9060036200017e929190620002d9565b503480156200018c57600080fd5b5060405162003524380380620035248339818101604052810190620001b291906200044e565b808073ffffffffffffffffffffffffffffffffffffffff1660808173ffffffffffffffffffffffffffffffffffffffff1681525050505062000480565b826003810192821562000226579160200282015b8281111562000225578251829060ff1690559160200191906001019062000203565b5b50905062000235919062000331565b5090565b826003601f01602090048101928215620002c65791602002820160005b838211156200029557835183826101000a81548160ff021916908315150217905550926020019260010160208160000104928301926001030262000256565b8015620002c45782816101000a81549060ff021916905560010160208160000104928301926001030262000295565b505b509050620002d5919062000331565b5090565b82600360020281019282156200031e579160200282015b828111156200031d578251829060026200030c92919062000350565b5091602001919060020190620002f0565b5b5090506200032d91906200039a565b5090565b5b808211156200034c57600081600090555060010162000332565b5090565b826002810192821562000387579160200282015b8281111562000386578251829060ff1690559160200191906001019062000364565b5b50905062000396919062000331565b5090565b5b80821115620003be5760008181620003b49190620003c2565b506002016200039b565b5090565b506000815560010160009055565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b60006200040282620003d5565b9050919050565b60006200041682620003f5565b9050919050565b620004288162000409565b81146200043457600080fd5b50565b60008151905062000448816200041d565b92915050565b600060208284031215620004675762000466620003d0565b5b6000620004778482850162000437565b91505092915050565b60805161306c620004b8600039600081816106e9015281816108d301528181610ac90152818161152901526116f7015261306c6000f3fe60806040526004361061007b5760003560e01c8063c019faab1161004e578063c019faab14610154578063cac152a41461017d578063da35c664146101ad578063ea923e63146101d85761007b565b8063013cf08b1461008057806362d26ed7146100c5578063a3bb24cc14610102578063b4e6a1d51461012b575b600080fd5b34801561008c57600080fd5b506100a760048036038101906100a291906119d9565b610215565b6040516100bc99989796959493929190611bcd565b60405180910390f35b3480156100d157600080fd5b506100ec60048036038101906100e791906119d9565b6103ad565b6040516100f99190611e4d565b60405180910390f35b34801561010e57600080fd5b5061012960048036038101906101249190611e69565b6106e6565b005b34801561013757600080fd5b50610152600480360381019061014d9190611f3a565b6108d1565b005b34801561016057600080fd5b5061017b600480360381019061017691906119d9565b61119a565b005b6101976004803603810190610192919061204c565b6112c6565b6040516101a491906120f3565b60405180910390f35b3480156101b957600080fd5b506101c2611490565b6040516101cf91906120f3565b60405180910390f35b3480156101e457600080fd5b506101ff60048036038101906101fa91906119d9565b611496565b60405161020c919061210e565b60405180910390f35b60006020528060005260406000206000915090508060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169080600101549080600201549080600301805461026a90612158565b80601f016020809104026020016040519081016040528092919081815260200182805461029690612158565b80156102e35780601f106102b8576101008083540402835291602001916102e3565b820191906000526020600020905b8154815290600101906020018083116102c657829003601f168201915b5050505050908060040154908060050160009054906101000a900460ff169080600701549080603b0160009054906101000a900460ff169080603c01805461032a90612158565b80601f0160208091040260200160405190810160
"deployedBytecode": "0x60806040526004361061007b5760003560e01c8063c019faab1161004e578063c019faab14610154578063cac152a41461017d578063da35c664146101ad578063ea923e63146101d85761007b565b8063013cf08b1461008057806362d26ed7146100c5578063a3bb24cc14610102578063b4e6a1d51461012b575b600080fd5b34801561008c57600080fd5b506100a760048036038101906100a291906119d9565b610215565b6040516100bc99989796959493929190611bcd565b60405180910390f35b3480156100d157600080fd5b506100ec60048036038101906100e791906119d9565b6103ad565b6040516100f99190611e4d565b60405180910390f35b34801561010e57600080fd5b5061012960048036038101906101249190611e69565b6106e6565b005b34801561013757600080fd5b50610152600480360381019061014d9190611f3a565b6108d1565b005b34801561016057600080fd5b5061017b600480360381019061017691906119d9565b61119a565b005b6101976004803603810190610192919061204c565b6112c6565b6040516101a491906120f3565b60405180910390f35b3480156101b957600080fd5b506101c2611490565b6040516101cf91906120f3565b60405180910390f35b3480156101e457600080fd5b506101ff60048036038101906101fa91906119d9565b611496565b60405161020c919061210e565b60405180910390f35b60006020528060005260406000206000915090508060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169080600101549080600201549080600301805461026a90612158565b80601f016020809104026020016040519081016040528092919081815260200182805461029690612158565b80156102e35780601f106102b8576101008083540402835291602001916102e3565b820191906000526020600020905b8154815290600101906020018083116102c657829003601f168201915b5050505050908060040154908060050160009054906101000a900460ff169080600701549080603b0160009054906101000a900460ff169080603c01805461032a90612158565b80601f016020809104026020016040519081016040528092919081815260200182805461035690612158565b80156103a35780601f10610378576101008083540402835291602001916103a3565b820191906000526020600020905b81548152906001019060200180831161038657829003601f168201915b5050505050905089565b6103b56118fa565b60008060008481526020019081526020016000209050806008016000600381106103e2576103e1612189565b5b60110201600101600380602002604051908101604052809291906000905b828210156104b2578382600502016040518060e0016040529081600082015481526020016001820160009054906101000a900460ff161515151581526020016001820160019054906101000a900460ff1615151515815260200160028201548152602001600382015481526020016004820160009054906101000a900460ff161515151581526020016004820160019054906101000a900460ff16151515158152505081526020019060010190610400565b50505050826000600381106104ca576104c9612189565b5b6020020181905250806008016001600381106104e9576104e8612189565b5b60110201600101600380602002604051908101604052809291906000905b828210156105b9578382600502016040518060e0016040529081600082015481526020016001820160009054906101000a900460ff161515151581526020016001820160019054906101000a900460ff1615151515815260200160028201548152602001600382015481526020016004820160009054906101000a900460ff161515151581526020016004820160019054906101000a900460ff16151515158152505081526020019060010190610507565b50505050826001600381106105d1576105d0612189565b5b6020020181905250806008016002600381106105f0576105ef612189565b5b60110201600101600380602002604051908101604052809291906000905b828210156106c0578382600502016040518060e0016040529081600082015481526020016001820160009054906101000a900460ff161515151581526020016001820160019054906101000a900460ff1615151515815260200160028201548152602001600382015481526020016004820160009054906101000a900460ff161515151581526020016004820160019054906101000a900460ff1615151515815250508152602001906001019061060e565b50505050826002600381106106d8576106d7612189565b5b602002018190525050919050565b807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166370a08231336040518263ffffffff1660e01b815260040161074091906121b8565b602060405180830381865afa15801561075d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061078191906121e8565b10156107c2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107b990612287565b60405180910390fd5b600080600084815260200190815260200160002090508060060160003373ffffffffffffffffffffffffffffffffffff
"linkReferences": {},
"deployedLinkReferences": {}
}