Skip to content

Instantly share code, notes, and snippets.

@sloppylopez
Last active March 17, 2018 22:15
Show Gist options
  • Save sloppylopez/4eae97bad2a686c0cddace675f8267ec to your computer and use it in GitHub Desktop.
Save sloppylopez/4eae97bad2a686c0cddace675f8267ec to your computer and use it in GitHub Desktop.
pragma solidity ^0.4.21;
contract TimesheetContract {
string timesheetHash = '';
address owner;
function TimesheetContract() {
owner = msg.sender;
}
function getTimesheetHash() constant returns(string){
return timesheetHash;
}
function setTimesheetHash(string newTimeSheetHash) returns(string){
if(owner != msg.sender) {
return "You shall not pass, you need to be the owner";
}
timesheetHash = newTimeSheetHash;
return "Sucessfull change of timesheetHash";
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment