Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- pragma solidity ^0.4.22;
- contract Hackathon{
- address public owner;
- enum Status {PENDING,APPROVED,REJECTED}
- string public request_id;
- string public owner_public_key;
- string public requestor_public_key;
- Status public status;
- constructor (string _request_id, string _owner_public_key, string _requestor_public_key) public{
- owner = msg.sender;
- status = Status.PENDING;
- request_id = _request_id;
- owner_public_key = _owner_public_key;
- requestor_public_key = _requestor_public_key;
- }
- modifier onlyOwner() {
- require(msg.sender == owner);
- _;
- }
- function Approve() public onlyOwner{
- status = Status.APPROVED;
- }
- function Reject() public onlyOwner{
- status = Status.REJECTED;
- }
- }
Add Comment
Please, Sign In to add comment