UNPKG

@daostack/infra

Version:

Base layer DAO's components

271 lines (270 loc) 16.5 kB
{ "contractName": "Reputation", "abi": [ { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "address", "name": "_from", "type": "address" }, { "indexed": false, "internalType": "uint256", "name": "_amount", "type": "uint256" } ], "name": "Burn", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "address", "name": "_to", "type": "address" }, { "indexed": false, "internalType": "uint256", "name": "_amount", "type": "uint256" } ], "name": "Mint", "type": "event" }, { "anonymous": false, "inputs": [ { "indexed": true, "internalType": "address", "name": "previousOwner", "type": "address" }, { "indexed": true, "internalType": "address", "name": "newOwner", "type": "address" } ], "name": "OwnershipTransferred", "type": "event" }, { "constant": true, "inputs": [ { "internalType": "address", "name": "_owner", "type": "address" } ], "name": "balanceOf", "outputs": [ { "internalType": "uint256", "name": "balance", "type": "uint256" } ], "payable": false, "stateMutability": "view", "type": "function" }, { "constant": true, "inputs": [ { "internalType": "address", "name": "_owner", "type": "address" }, { "internalType": "uint256", "name": "_blockNumber", "type": "uint256" } ], "name": "balanceOfAt", "outputs": [ { "internalType": "uint256", "name": "", "type": "uint256" } ], "payable": false, "stateMutability": "view", "type": "function" }, { "constant": false, "inputs": [ { "internalType": "address", "name": "_user", "type": "address" }, { "internalType": "uint256", "name": "_amount", "type": "uint256" } ], "name": "burn", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "payable": false, "stateMutability": "nonpayable", "type": "function" }, { "constant": true, "inputs": [], "name": "decimals", "outputs": [ { "internalType": "uint8", "name": "", "type": "uint8" } ], "payable": false, "stateMutability": "view", "type": "function" }, { "constant": true, "inputs": [], "name": "isOwner", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "payable": false, "stateMutability": "view", "type": "function" }, { "constant": false, "inputs": [ { "internalType": "address", "name": "_user", "type": "address" }, { "internalType": "uint256", "name": "_amount", "type": "uint256" } ], "name": "mint", "outputs": [ { "internalType": "bool", "name": "", "type": "bool" } ], "payable": false, "stateMutability": "nonpayable", "type": "function" }, { "constant": true, "inputs": [], "name": "owner", "outputs": [ { "internalType": "address", "name": "", "type": "address" } ], "payable": false, "stateMutability": "view", "type": "function" }, { "constant": false, "inputs": [], "name": "renounceOwnership", "outputs": [], "payable": false, "stateMutability": "nonpayable", "type": "function" }, { "constant": true, "inputs": [], "name": "totalSupply", "outputs": [ { "internalType": "uint256", "name": "", "type": "uint256" } ], "payable": false, "stateMutability": "view", "type": "function" }, { "constant": true, "inputs": [ { "internalType": "uint256", "name": "_blockNumber", "type": "uint256" } ], "name": "totalSupplyAt", "outputs": [ { "internalType": "uint256", "name": "", "type": "uint256" } ], "payable": false, "stateMutability": "view", "type": "function" }, { "constant": false, "inputs": [ { "internalType": "address", "name": "newOwner", "type": "address" } ], "name": "transferOwnership", "outputs": [], "payable": false, "stateMutability": "nonpayable", "type": "function" } ], "bytecode": "0x60806040526000805460ff60a01b1916600960a11b17815561001f61006e565b600080546001600160a01b0319166001600160a01b0383169081178255604051929350917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908290a350610072565b3390565b610a6f806100816000396000f3fe608060405234801561001057600080fd5b50600436106100a95760003560e01c8063715018a611610071578063715018a6146101785780638da5cb5b146101825780638f32d59b146101a6578063981b24d0146101ae5780639dc29fac146101cb578063f2fde38b146101f7576100a9565b806318160ddd146100ae578063313ce567146100c857806340c10f19146100e65780634ee2cd7e1461012657806370a0823114610152575b600080fd5b6100b661021d565b60408051918252519081900360200190f35b6100d061022e565b6040805160ff9092168252519081900360200190f35b610112600480360360408110156100fc57600080fd5b506001600160a01b03813516906020013561023e565b604080519115158252519081900360200190f35b6100b66004803603604081101561013c57600080fd5b506001600160a01b0381351690602001356103b5565b6100b66004803603602081101561016857600080fd5b50356001600160a01b0316610445565b610180610459565b005b61018a6104ea565b604080516001600160a01b039092168252519081900360200190f35b6101126104f9565b6100b6600480360360208110156101c457600080fd5b503561051d565b610112600480360360408110156101e157600080fd5b506001600160a01b03813516906020013561056f565b6101806004803603602081101561020d57600080fd5b50356001600160a01b031661065a565b60006102284361051d565b90505b90565b600054600160a01b900460ff1681565b60006102486104f9565b610287576040805162461bcd60e51b81526020600482018190526024820152600080516020610a1b833981519152604482015290519081900360640190fd5b600061029161021d565b90508083820110156102e2576040805162461bcd60e51b8152602060048201526015602482015274746f74616c20737570706c79206f766572666c6f7760581b604482015290519081900360640190fd5b60006102ed85610445565b9050808482011015610338576040805162461bcd60e51b815260206004820152600f60248201526e62616c616365206f766572666c6f7760881b604482015290519081900360640190fd5b61034560028584016106ad565b6001600160a01b0385166000908152600160205260409020610369908286016106ad565b6040805185815290516001600160a01b038716917f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d4121396885919081900360200190a26001925050505b92915050565b6001600160a01b038216600090815260016020526040812054158061040f57506001600160a01b038316600090815260016020526040812080548492906103f857fe5b6000918252602090912001546001600160801b0316115b1561041c575060006103af565b6001600160a01b038316600090815260016020526040902061043e90836107d9565b90506103af565b600061045182436103b5565b90505b919050565b6104616104f9565b6104a0576040805162461bcd60e51b81526020600482018190526024820152600080516020610a1b833981519152604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b6000546001600160a01b031690565b600080546001600160a01b031661050e610909565b6001600160a01b031614905090565b6002546000901580610550575081600260008154811061053957fe5b6000918252602090912001546001600160801b0316115b1561055d57506000610454565b6105686002836107d9565b9050610454565b60006105796104f9565b6105b8576040805162461bcd60e51b81526020600482018190526024820152600080516020610a1b833981519152604482015290519081900360640190fd5b60006105c261021d565b90508260006105d086610445565b9050818110156105de578091505b6105eb60028385036106ad565b6001600160a01b038616600090815260016020526040902061060f908383036106ad565b6040805183815290516001600160a01b038816917fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca5919081900360200190a250600195945050505050565b6106626104f9565b6106a1576040805162461bcd60e51b81526020600482018190526024820152600080516020610a1b833981519152604482015290519081900360640190fd5b6106aa8161090d565b50565b80816001600160801b031614610700576040805162461bcd60e51b815260206004820152601360248201527272657075746174696f6e206f766572666c6f7760681b604482015290519081900360640190fd5b815415806107345750815443908390600019810190811061071d57fe5b6000918252602090912001546001600160801b0316105b1561079b578154600090839061074d82600183016109ad565b8154811061075757fe5b600091825260209091200180546001600160801b03848116600160801b024382166fffffffffffffffffffffffffffffffff199093169290921716179055506107d5565b8154600090839060001981019081106107b057fe5b600091825260209091200180546001600160801b03808516600160801b029116179055505b5050565b81546000906107ea575060006103af565b8254839060001981019081106107fc57fe5b6000918252602090912001546001600160801b0316821061084c5782548390600019810190811061082957fe5b600091825260209091200154600160801b90046001600160801b031690506103af565b8260008154811061085957fe5b6000918252602090912001546001600160801b031682101561087d575060006103af565b8254600090600019015b818111156108d85760006002600183850101049050848682815481106108a957fe5b6000918252602090912001546001600160801b0316116108cb578092506108d2565b6001810391505b50610887565b8482815481106108e457fe5b600091825260209091200154600160801b90046001600160801b031695945050505050565b3390565b6001600160a01b0381166109525760405162461bcd60e51b81526004018080602001828103825260268152602001806109f56026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b8154818355818111156109d1576000838152602090206109d19181019083016109d6565b505050565b61022b91905b808211156109f057600081556001016109dc565b509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573734f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572a265627a7a72315820e44b358a8655857b697f0b3f3586d577dc891a18a32636e3bf8ee49466d45c0764736f6c63430005110032", "deployedBytecode": "0x608060405234801561001057600080fd5b50600436106100a95760003560e01c8063715018a611610071578063715018a6146101785780638da5cb5b146101825780638f32d59b146101a6578063981b24d0146101ae5780639dc29fac146101cb578063f2fde38b146101f7576100a9565b806318160ddd146100ae578063313ce567146100c857806340c10f19146100e65780634ee2cd7e1461012657806370a0823114610152575b600080fd5b6100b661021d565b60408051918252519081900360200190f35b6100d061022e565b6040805160ff9092168252519081900360200190f35b610112600480360360408110156100fc57600080fd5b506001600160a01b03813516906020013561023e565b604080519115158252519081900360200190f35b6100b66004803603604081101561013c57600080fd5b506001600160a01b0381351690602001356103b5565b6100b66004803603602081101561016857600080fd5b50356001600160a01b0316610445565b610180610459565b005b61018a6104ea565b604080516001600160a01b039092168252519081900360200190f35b6101126104f9565b6100b6600480360360208110156101c457600080fd5b503561051d565b610112600480360360408110156101e157600080fd5b506001600160a01b03813516906020013561056f565b6101806004803603602081101561020d57600080fd5b50356001600160a01b031661065a565b60006102284361051d565b90505b90565b600054600160a01b900460ff1681565b60006102486104f9565b610287576040805162461bcd60e51b81526020600482018190526024820152600080516020610a1b833981519152604482015290519081900360640190fd5b600061029161021d565b90508083820110156102e2576040805162461bcd60e51b8152602060048201526015602482015274746f74616c20737570706c79206f766572666c6f7760581b604482015290519081900360640190fd5b60006102ed85610445565b9050808482011015610338576040805162461bcd60e51b815260206004820152600f60248201526e62616c616365206f766572666c6f7760881b604482015290519081900360640190fd5b61034560028584016106ad565b6001600160a01b0385166000908152600160205260409020610369908286016106ad565b6040805185815290516001600160a01b038716917f0f6798a560793a54c3bcfe86a93cde1e73087d944c0ea20544137d4121396885919081900360200190a26001925050505b92915050565b6001600160a01b038216600090815260016020526040812054158061040f57506001600160a01b038316600090815260016020526040812080548492906103f857fe5b6000918252602090912001546001600160801b0316115b1561041c575060006103af565b6001600160a01b038316600090815260016020526040902061043e90836107d9565b90506103af565b600061045182436103b5565b90505b919050565b6104616104f9565b6104a0576040805162461bcd60e51b81526020600482018190526024820152600080516020610a1b833981519152604482015290519081900360640190fd5b600080546040516001600160a01b03909116907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0908390a3600080546001600160a01b0319169055565b6000546001600160a01b031690565b600080546001600160a01b031661050e610909565b6001600160a01b031614905090565b6002546000901580610550575081600260008154811061053957fe5b6000918252602090912001546001600160801b0316115b1561055d57506000610454565b6105686002836107d9565b9050610454565b60006105796104f9565b6105b8576040805162461bcd60e51b81526020600482018190526024820152600080516020610a1b833981519152604482015290519081900360640190fd5b60006105c261021d565b90508260006105d086610445565b9050818110156105de578091505b6105eb60028385036106ad565b6001600160a01b038616600090815260016020526040902061060f908383036106ad565b6040805183815290516001600160a01b038816917fcc16f5dbb4873280815c1ee09dbd06736cffcc184412cf7a71a0fdb75d397ca5919081900360200190a250600195945050505050565b6106626104f9565b6106a1576040805162461bcd60e51b81526020600482018190526024820152600080516020610a1b833981519152604482015290519081900360640190fd5b6106aa8161090d565b50565b80816001600160801b031614610700576040805162461bcd60e51b815260206004820152601360248201527272657075746174696f6e206f766572666c6f7760681b604482015290519081900360640190fd5b815415806107345750815443908390600019810190811061071d57fe5b6000918252602090912001546001600160801b0316105b1561079b578154600090839061074d82600183016109ad565b8154811061075757fe5b600091825260209091200180546001600160801b03848116600160801b024382166fffffffffffffffffffffffffffffffff199093169290921716179055506107d5565b8154600090839060001981019081106107b057fe5b600091825260209091200180546001600160801b03808516600160801b029116179055505b5050565b81546000906107ea575060006103af565b8254839060001981019081106107fc57fe5b6000918252602090912001546001600160801b0316821061084c5782548390600019810190811061082957fe5b600091825260209091200154600160801b90046001600160801b031690506103af565b8260008154811061085957fe5b6000918252602090912001546001600160801b031682101561087d575060006103af565b8254600090600019015b818111156108d85760006002600183850101049050848682815481106108a957fe5b6000918252602090912001546001600160801b0316116108cb578092506108d2565b6001810391505b50610887565b8482815481106108e457fe5b600091825260209091200154600160801b90046001600160801b031695945050505050565b3390565b6001600160a01b0381166109525760405162461bcd60e51b81526004018080602001828103825260268152602001806109f56026913960400191505060405180910390fd5b600080546040516001600160a01b03808516939216917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a3600080546001600160a01b0319166001600160a01b0392909216919091179055565b8154818355818111156109d1576000838152602090206109d19181019083016109d6565b505050565b61022b91905b808211156109f057600081556001016109dc565b509056fe4f776e61626c653a206e6577206f776e657220697320746865207a65726f20616464726573734f776e61626c653a2063616c6c6572206973206e6f7420746865206f776e6572a265627a7a72315820e44b358a8655857b697f0b3f3586d577dc891a18a32636e3bf8ee49466d45c0764736f6c63430005110032", "linkReferences": {}, "deployedLinkReferences": {} }