Skip to content

Commit

Permalink
payments page intro (bug 595319)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jeff Balogh committed Oct 7, 2010
1 parent ec18407 commit eb2bb1e
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 1 deletion.
22 changes: 22 additions & 0 deletions apps/devhub/templates/devhub/addons/payments.html
@@ -0,0 +1,22 @@
{% extends "devhub/base.html" %}

{% set title = _('Manage Payments') %}
{% block title %}{{ dev_page_title(title, addon) }}{% endblock %}

{% block content %}
<header>
{{ dev_breadcrumbs(addon) }}
<h2>{{ title }}</h2>
</header>
<section class="primary" role="main">
<h3>{{ _('Contributions') }}</h3>
<p>{{ _('Voluntary contributions provide a way for users to support your add-on financially. With contributions, you can:') }}</p>
<ul>
<li>{{ _('Ask for donations in most places your add-on appears') }}</li>
<li>{{ _('Allow users to make payments with a credit card or PayPal account') }}</li>
<li>{{ _('Receive contributions in your PayPal account or send them to a charity') }}</li>
</ul>
<a href="#setup" class="button">{{ _('Set Up Contributions') }}</a>
</section>
{% include "devhub/includes/addons_edit_nav.html" %}
{% endblock %}
2 changes: 1 addition & 1 deletion apps/devhub/templates/devhub/includes/addons_edit_nav.html
Expand Up @@ -2,7 +2,7 @@
(url('devhub.addons.edit', addon.id), _('Edit Add-on Listing')),
(url('devhub.addons.owner', addon.id), _('Manage Authors & License')),
('#', _('Manage Developer Profile')),
('#', _('Manage Payments')),
(url('devhub.addons.payments', addon.id), _('Manage Payments')),
('#', _('Manage Status & Versions')),
) %}

Expand Down
1 change: 1 addition & 0 deletions apps/devhub/urls.py
Expand Up @@ -12,6 +12,7 @@
url('^$', lambda r: redirect('devhub.addons.edit', permanent=True)),
url('^edit$', views.addons_edit, name='devhub.addons.edit'),
url('^ownership$', views.addons_owner, name='devhub.addons.owner'),
url('^payments$', views.addons_payments, name='devhub.addons.payments'),
)

urlpatterns = decorate(write, patterns('',
Expand Down
6 changes: 6 additions & 0 deletions apps/devhub/views.py
Expand Up @@ -155,6 +155,12 @@ def addons_owner(request, addon_id, addon):
policy_form=policy_form))


@dev_required
def addons_payments(request, addon_id, addon):
return jingo.render(request, 'devhub/addons/payments.html',
dict(addon=addon))


def upload(request):
if request.method == 'POST' and 'upload' in request.FILES:
upload = request.FILES['upload']
Expand Down

0 comments on commit eb2bb1e

Please sign in to comment.