Last active
November 13, 2017 19:07
-
-
Save jefflau/97dcbeec33591b78c41fcd492915c816 to your computer and use it in GitHub Desktop.
Ticketer.sol
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
contract Ticketer { | |
address owner; | |
uint tickets; | |
uint sellStartDate; | |
uint sellEndDate; | |
uint eventStartDate; | |
uint buffer; | |
uint maxTicketsPerAddress; | |
event LogTicketSold(_address, _amount) | |
function Ticketer( | |
uint _tickets, | |
uint _sellStartDate, | |
uint _sellEndDate, | |
uint _eventStartDate, | |
uint _buffer, | |
uint _maxTicketsPerAddress) | |
{ | |
tickets = _tickets, | |
sellStartDate = _sellStartDate, | |
sellEndDate = _sellEndDate, | |
eventStartDate = _eventStartDate, | |
buffer = _buffer, | |
maxTicketsPerAddress _maxTicketsPerAddress | |
//create ERC20 token | |
} | |
function buyTicket payable(uint _amount){ | |
if(_amount > maxTicketsPerAddress){ | |
revert() | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment