{{define "freeOffers"}}
Name
Award Credit
Referrals Used
Redeemable Capacity
Created
Expiration
Status

Default Offer

{{$defaultOffer := .FreeCredits.Default}} {{if not $defaultOffer.IsEmpty}}
{{$defaultOffer.Name}}
${{$defaultOffer.AwardCredit}}
{{$defaultOffer.NumRedeemed}}
{{$defaultOffer.RedeemableCap}}
{{printf "%.10s" $defaultOffer.CreatedAt}}
{{printf "%.10s" $defaultOffer.ExpiresAt}}

{{end}}

Current Offer

{{$currentOffer := .FreeCredits.Active}} {{if not $currentOffer.IsEmpty}}
{{$currentOffer.Name}}
${{$currentOffer.AwardCredit}}
{{$currentOffer.NumRedeemed}}
{{$currentOffer.RedeemableCap}}
{{printf "%.10s" $currentOffer.CreatedAt}}
{{printf "%.10s" $currentOffer.ExpiresAt}}
Live ·

{{end}} {{template "stopFreeCredit" .}}

Other Offers

{{range .FreeCredits.Done}}
{{.Name}}
${{.AwardCredit}}
{{.NumRedeemed}}
{{.RedeemableCap}}
{{printf "%.10s" .CreatedAt}}
{{printf "%.10s" .ExpiresAt}}
off

{{end}}
{{end}}