2011-12-20 22:42:06 +00:00
|
|
|
{% extends "basedocumentation.html" %}
|
|
|
|
{% block base_js %}{% endblock %}
|
|
|
|
{% block extra_extra_head %}
|
|
|
|
<link rel="stylesheet" href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.13/themes/ui-lightness/jquery-ui.css" type="text/css" media="screen">
|
|
|
|
{{ form.media.css }}
|
2012-02-06 18:53:25 +00:00
|
|
|
<script type="text/javascript" src={{ jquery_ui_home }}></script>
|
2011-12-20 22:42:06 +00:00
|
|
|
{{ form.media.js }}
|
|
|
|
{% endblock %}
|
|
|
|
|
|
|
|
{% block doccontent %}
|
|
|
|
|
|
|
|
<h2>Campaign Admin</h2>
|
|
|
|
|
2011-12-21 22:32:08 +00:00
|
|
|
{% if command_status %}
|
|
|
|
<p style="font-weight:bold; color:red">{{command_status}}</p>
|
|
|
|
{% endif %}
|
|
|
|
|
2011-12-21 01:36:27 +00:00
|
|
|
<!-- Active transactions -->
|
2011-12-23 14:59:07 +00:00
|
|
|
|
2011-12-23 16:46:09 +00:00
|
|
|
<p style="font-weight:bold">A) Campaigns with active transactions</p>
|
2011-12-21 01:36:27 +00:00
|
|
|
{% if campaigns_with_active_transactions %}
|
2011-12-23 14:59:07 +00:00
|
|
|
<form method="post" action="#">
|
|
|
|
{% csrf_token %}
|
2011-12-21 01:36:27 +00:00
|
|
|
<ul>
|
|
|
|
{% for campaign in campaigns_with_active_transactions %}
|
2011-12-23 14:59:07 +00:00
|
|
|
<li><input type="radio" name="active_campaign" value="{{campaign.id}}" />{{campaign.id}} | {{campaign.name}} </li>
|
2011-12-21 01:36:27 +00:00
|
|
|
{% endfor %}
|
|
|
|
</ul>
|
2011-12-23 14:59:07 +00:00
|
|
|
|
2011-12-21 22:32:08 +00:00
|
|
|
<input type="submit" name="execute_campaigns" value="Execute Payment to Gluejar" id="submit">
|
|
|
|
<input type="submit" name="cancel_campaigns" value="Cancel Active Transactions" id="submit">
|
|
|
|
</form>
|
2011-12-21 01:36:27 +00:00
|
|
|
{% else %}
|
|
|
|
<p>No campaigns with active transactions</p>
|
|
|
|
{% endif %}
|
|
|
|
|
|
|
|
<!-- incomplete transactions -->
|
2011-12-23 16:46:09 +00:00
|
|
|
<p style="font-weight:bold">B) Campaigns with incomplete transactions</p>
|
2011-12-21 01:36:27 +00:00
|
|
|
{% if campaigns_with_incomplete_transactions %}
|
2011-12-23 14:59:07 +00:00
|
|
|
<form method="post" action="#">
|
|
|
|
{% csrf_token %}
|
2011-12-21 01:36:27 +00:00
|
|
|
<ul>
|
|
|
|
{% for campaign in campaigns_with_incomplete_transactions %}
|
2011-12-23 14:59:07 +00:00
|
|
|
<li><input type="radio" name="incomplete_campaign" value="{{campaign.id}}" />{{campaign.id}} | {{campaign.name}} </li>
|
2011-12-21 01:36:27 +00:00
|
|
|
{% endfor %}
|
|
|
|
</ul>
|
2011-12-21 22:32:08 +00:00
|
|
|
<input type="submit" name="finish_campaigns" value="Pay Rights Holders" id="submit">
|
|
|
|
</form>
|
2011-12-21 01:36:27 +00:00
|
|
|
{% else %}
|
|
|
|
<p>No campaigns with incomplete transactions</p>
|
|
|
|
{% endif %}
|
|
|
|
|
|
|
|
<!-- completed transactions -->
|
2011-12-23 16:46:09 +00:00
|
|
|
<p style="font-weight:bold">C) Campaigns with completed transactions</p>
|
2011-12-21 01:36:27 +00:00
|
|
|
{% if campaigns_with_completed_transactions %}
|
|
|
|
<ul>
|
|
|
|
{% for campaign in campaigns_with_completed_transactions %}
|
|
|
|
<li>{{campaign.id}} | {{campaign.name}} </li>
|
|
|
|
{% endfor %}
|
|
|
|
</ul>
|
|
|
|
{% else %}
|
|
|
|
<p>No campaigns with completed transactions</p>
|
|
|
|
{% endif %}
|
|
|
|
|
|
|
|
|
2011-12-21 22:32:08 +00:00
|
|
|
<!-- canceled transactions -->
|
2011-12-23 16:46:09 +00:00
|
|
|
<p style="font-weight:bold">D) Campaigns with canceled transactions</p>
|
2011-12-21 22:32:08 +00:00
|
|
|
{% if campaigns_with_canceled_transactions %}
|
|
|
|
<ul>
|
|
|
|
{% for campaign in campaigns_with_canceled_transactions %}
|
|
|
|
<li>{{campaign.id}} | {{campaign.name}} </li>
|
|
|
|
{% endfor %}
|
|
|
|
</ul>
|
|
|
|
{% else %}
|
|
|
|
<p>No campaigns with canceled transactions</p>
|
|
|
|
{% endif %}
|
|
|
|
|
2011-12-23 16:46:09 +00:00
|
|
|
<form method="post" action="#">
|
|
|
|
{% csrf_token %}
|
|
|
|
{{ form.as_p }}
|
|
|
|
<input type="submit" name="campaign_checkstatus" value="Update Transaction Statuses" id="submit">
|
|
|
|
</form>
|
|
|
|
|
|
|
|
{% if check_status_results %}
|
|
|
|
<p style="font-weight:bold">E) Campaign checkstatus output</p>
|
|
|
|
{% autoescape off %}
|
|
|
|
{{check_status_results}}
|
|
|
|
{% endautoescape %}
|
|
|
|
{% endif %}
|
|
|
|
|
2011-12-20 22:42:06 +00:00
|
|
|
{% endblock %}
|