storj/web/marketing/pages/partner-offers.html
Yingrong Zhao 10a896bf73
web/marketing: static asset path (#2872)
* use relative path instead of absolute path

* add template func baseURL

* add a method

* update storj-sim

* add comment
2019-08-30 18:43:53 -04:00

58 lines
2.1 KiB
HTML

<!-- Copyright (C) 2019 Storj Labs, Inc.
See LICENSE for copying information. -->
{{define "partnerOffers"}}
<div class="row mt-4 mb-4 d-flex justify-content-between pr-4 modal-btn">
<h3 class="mt-4">{{.Name}} Offers</h3>
<button type="button" class="btn btn-primary mt-4" data-toggle="modal" data-target="#partner-offers-modal-{{.Name}}">+ Create Partner Offer</button>
</div>
{{template "partnerOffersModal" .}}
<div class="offers-table mt-2 mb-5 container">
<div class="row header-row">
<div class="col col-heading">Name</div>
<div class="col col-heading">Give Credit</div>
<div class="col col-heading">Duration</div>
<div class="col col-heading">Status</div>
<div class="col col-heading">Link</div>
</div><hr>
<div class="row offer-heading ">
<p class="offer-type">Current&nbsp;Offer</p>
</div>
{{$currentOffer := .PartnerOffers.Active}}
{{if not $currentOffer.IsEmpty}}
<div class="row data-row">
<div class="col-2">{{$currentOffer.Name}}</div>
<div class="col-2">${{$currentOffer.InviteeCredit}}</div>
<div class="col-3">{{$currentOffer.InviteeCreditDurationDays}}</div>
<div class="col-2 col-offset-1 stop-offer">
<span data-toggle="modal" data-target=".stop-partner-offer-modal-{{.Name}}">
<strong>Live &#183;</strong>
</span>
</div>
<div class="col-3">
{{range ReferralLink $currentOffer.Name}}
<span class="d-block">{{.}}</span>
{{end}}
</div>
</div><hr>
{{end}}
{{template "stopPartnerOffer" .}}
<div class="row offer-heading ">
<p class="offer-type">Discontinued&nbsp;Offers</p>
</div>
{{range .PartnerOffers.Done}}
<div class="row data-row">
<div class="col-2">{{.Name}}</div>
<div class="col-2">${{.InviteeCredit}}</div>
<div class="col-3">{{.InviteeCreditDurationDays}}</div>
<div class="col-2 col-offset-1">off</div>
<div class="col-3"></div>
</div><hr>
{{end}}
</div>
{{end}}