func Claim
crossing ActionClaim lets the creator take the funds if the goal was met after the deadline.
Package crowdfund is an accounting-only port of the classic Solidity Kickstarter-style crowdfunding contract to a gno...
Package crowdfund is an accounting-only port of the classic Solidity Kickstarter-style crowdfunding contract to a gno.land realm.
A creator Launches a campaign with a funding goal and a duration (in blocks). Backers Pledge (and may Unpledge before the deadline). After the deadline the creator can Claim if the goal was met, otherwise backers can Refund.
No real coin moves: pledges are tracked as plain uint64 accounting, exactly like the mapping(address => uint) balances of the Solidity original.
Claim lets the creator take the funds if the goal was met after the deadline.
Launch creates a new campaign owned by the caller and returns its id.
Pledge backs campaign id with amount (before the deadline).
Refund returns the caller's pledge if the campaign failed after the deadline.
Render shows all campaigns with a progress bar, goal, pledged and state.
Unpledge withdraws amount from the caller's pledge (before the deadline).
Campaign holds the state of a single crowdfunding campaign.