|
|
|
@ -6,9 +6,14 @@ |
|
|
|
|
<div class="well"> |
|
|
|
|
<div class="container"> |
|
|
|
|
<p class="pull-right"> |
|
|
|
|
<a class="btn btn-default" href="logout">Log Out</a> |
|
|
|
|
<a class="btn btn-primary" href="#" data-toggle="modal" data-target="#donation-button-modal"> |
|
|
|
|
Get donation button |
|
|
|
|
</a> |
|
|
|
|
<a class="btn btn-default" href="logout">Log out</a> |
|
|
|
|
</p> |
|
|
|
|
<h1>Donation Admin</h1> |
|
|
|
|
<p>Combine this with your <a href="https://dashboard.stripe.com">Stripe |
|
|
|
|
dashboard</a> for the full effect.</p> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
<div class="container"> |
|
|
|
@ -52,7 +57,6 @@ |
|
|
|
|
<th>Project Name</th> |
|
|
|
|
<th>One-time</th> |
|
|
|
|
<th>Recurring</th> |
|
|
|
|
<th>README Button</th> |
|
|
|
|
</tr> |
|
|
|
|
</thead> |
|
|
|
|
<tbody> |
|
|
|
@ -62,7 +66,6 @@ |
|
|
|
|
<td>{{ project.name }}</td> |
|
|
|
|
<td>${{ "{:.2f}".format(one_times(project) / 100) }}</td> |
|
|
|
|
<td>${{ "{:.2f}".format(recurring(project) / 100) }}</td> |
|
|
|
|
<td><a href="#" class="btn btn-primary btn-sm">Get Markdown</a></td> |
|
|
|
|
</tr> |
|
|
|
|
{% endfor %} |
|
|
|
|
<tr> |
|
|
|
@ -70,7 +73,6 @@ |
|
|
|
|
<td>(not specified)</td> |
|
|
|
|
<td>${{ "{:.2f}".format(unspecified_one_times / 100) }}</td> |
|
|
|
|
<td>${{ "{:.2f}".format(unspecified_recurring / 100) }}</td> |
|
|
|
|
<td></td> |
|
|
|
|
</tr> |
|
|
|
|
</tbody> |
|
|
|
|
</table> |
|
|
|
@ -86,7 +88,7 @@ |
|
|
|
|
</form> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
<h2>Donation History</h2> |
|
|
|
|
<h2>Recent Donations <small>50 most recent</small></h2> |
|
|
|
|
<table class="table"> |
|
|
|
|
<thead> |
|
|
|
|
<tr> |
|
|
|
@ -94,9 +96,53 @@ |
|
|
|
|
<th>Project</th> |
|
|
|
|
<th>Comment</th> |
|
|
|
|
<th>Amount</th> |
|
|
|
|
<th style="width: 10%">Recurring</th> |
|
|
|
|
<th>Type</th> |
|
|
|
|
</tr> |
|
|
|
|
</thead> |
|
|
|
|
<tbody> |
|
|
|
|
{% for donation in donations %} |
|
|
|
|
<tr> |
|
|
|
|
<td><a href="mailto:{{ donation.user.email }}">{{ donation.user.email }}</a></td> |
|
|
|
|
<td>{{ donation.project.name if donation.project else "" }}</td> |
|
|
|
|
<td title="{{ donation.comment }}">{{ donation.comment if donation.comment else "" }}</td> |
|
|
|
|
<td>${{ "{:.2f}".format(donation.amount / 100) }}</td> |
|
|
|
|
<td>{{ "Once" if str(donation.type) == "DonationType.one_time" else "Monthly" }}</td> |
|
|
|
|
</tr> |
|
|
|
|
{% endfor %} |
|
|
|
|
</tbody> |
|
|
|
|
</table> |
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
<div class="modal fade" id="donation-button-modal" tabindex="-1" role="dialog" aria-labelledby="donation-modal-label"> |
|
|
|
|
<div class="modal-dialog" role="document"> |
|
|
|
|
<div class="modal-content"> |
|
|
|
|
<div class="modal-header"> |
|
|
|
|
<button type="button" class="close" data-dismiss="modal" aria-label="Close"> |
|
|
|
|
<span aria-hidden="true">×</span> |
|
|
|
|
</button> |
|
|
|
|
<h4 class="modal-title" id="donation-modal-label">Donation buttons</h4> |
|
|
|
|
</div> |
|
|
|
|
<div class="modal-body"> |
|
|
|
|
<p> |
|
|
|
|
You can include a donation button in various places to |
|
|
|
|
drive people to your donation page. Here's how it looks: |
|
|
|
|
<a href=".."> |
|
|
|
|
<img src="../static/donate-with-fosspay.png" /> |
|
|
|
|
</a> |
|
|
|
|
</p> |
|
|
|
|
<p>If you add <code>?project=1</code> to your URL, it will pre-select that project |
|
|
|
|
(where 1 is the 1st project you have listed on this page) when users arrive to donate.</p> |
|
|
|
|
<p><strong>Markdown</strong></p> |
|
|
|
|
<pre>[![Donate with fosspay]({{root}}/static/donate-with-fosspay.png)]({{root}})</pre> |
|
|
|
|
<p><strong>HTML</strong></p> |
|
|
|
|
<pre><a href="{{root}}"><img src="{{root}}/static/donate-with-fosspay.png" alt="Donate with fosspay" /></a></pre> |
|
|
|
|
</div> |
|
|
|
|
<div class="modal-footer"> |
|
|
|
|
<button type="button" class="btn btn-default" data-dismiss="modal"> |
|
|
|
|
Dismiss |
|
|
|
|
</button> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
{% endblock %} |
|
|
|
|