Merge pull request #60 from Gluejar/manage_user_cc

tweak error page, other nits
pull/1/head
thatandromeda 2012-10-15 07:50:45 -07:00
commit 80fae98b88
5 changed files with 28 additions and 25 deletions

View File

@ -2,7 +2,7 @@
{# raw url references raise test errors in tests for django registration; this is a workaround #}
{% url privacy as privacyurl %}
{% url terms as termsurl %}
{% url regluit.frontend.views.edit_user as editurl %}
{% url manage_account as editurl %}
{% url rightsholders as rhtoolsurl %}
{% url faq as faqurl %}
{% url about as abouturl %}
@ -128,21 +128,21 @@
<span>Your account</span>
<ul>
{% if user.is_authenticated %}
<li><a href="{{editurl}}">Account Settings</a></li>
<li><a href="{{ editurl }}">Account Settings</a></li>
{% endif %}
<li><a href="{{rhtoolsurl}}">Rights Holder Tools</a></li>
<li><a href="{{privacyurl}}">Privacy</a></li>
<li><a href="{{termsurl}}">Terms of Use</a></li>
<li><a href="{{ rhtoolsurl }}">Rights Holder Tools</a></li>
<li><a href="{{ privacyurl }}">Privacy</a></li>
<li><a href="{{ termsurl }}">Terms of Use</a></li>
{% if user.is_staff %}
<li><a href="{{adminurl}}">Unglue.it Administration</a></li>
<li><a href="{{editionurl}}">Create New Editions</a></li>
<li><a href="{{ adminurl }}">Unglue.it Administration</a></li>
<li><a href="{{ editionurl }}">Create New Editions</a></li>
{% endif %}
</ul>
</div>
<div class="column">
<span>Help</span>
<ul>
<li><a href="{{faqurl}}">General FAQ</a></li>
<li><a href="{{ faqurl }}">General FAQ</a></li>
<li><a href="/faq/rightsholders/">Rights Holder FAQ</a></li>
<li><a href="{% url api_help %}">API</a></li>
<li><a href="mailto:support@gluejar.com">support@gluejar.com</a>

View File

@ -131,11 +131,11 @@ $j(document).ready(function() {
</div>
<div class="form-row clearfix">
<label>Card Number:</label>
<input id="card_Number" type="text" class="card-number"/>
<input id="card_Number" type="text" class="card-number" />
</div>
<div class="form-row clearfix cvc">
<label>CVC:</label>
<input id="card_CVC" type="text" size="4" autocomplete="off" class="card-cvc"/> <span id="cvc_help">(what is this?)</span>
<input id="card_CVC" type="text" size="4" autocomplete="off" class="card-cvc" /> <span id="cvc_help">(what is this?)</span>
<div id="cvc_answer"><img src="/static/images/cvcimage.jpeg">For most cards, this is a 3-digit number at the end of the signature strip on the back. For American Express, it's a four-digit number in small print on the front.</div>
</div>
<div class="form-row clearfix initial_values">

View File

@ -24,19 +24,22 @@ $j(document).ready(function(){
</dl>
<h2 id="your_payment_info">Your Payment Info</h2>
{% if request.user.profile.account %}
<p>Unglue.it has a {{ request.user.profile.account.card_type }} credit card on file for you (we use <a href="https://stripe.com/">Stripe</a> to keep your information secure).
The last four digits of the card are {{ request.user.profile.account.card_last4 }}, and the expiration date is {{ request.user.profile.account.card_exp_month }}/{{ request.user.profile.account.card_exp_year }}.
</p>
<p>If you'd like to update your card info, or use a different card to fund your pledges, <a id="show_cc_form">click here</a>.
</p>
<p>Unglue.it has a credit card on file for you. We'll use this to fund your pledges.</p>
<b>Card type:</b> {{ request.user.profile.account.card_type }}<br />
<b>Number:</b> ************{{ request.user.profile.account.card_last4 }}<br />
<b>Expiration date:</b> {{ request.user.profile.account.card_exp_month }}/{{ request.user.profile.account.card_exp_year }}.<br />
<p>We use <a href="https://stripe.com/">Stripe</a> to keep your information secure.</p><br />
<p><a class="fakeinput" id="show_cc_form">Update Card</a></p>
{% else %}
<p>Unglue.it has no active credit card on file for you (we use <a href="https://stripe.com/">Stripe</a> to keep your information secure).
</p>
{% if request.user.profile.old_account %}
<p>The card you previously gave us has become inactive, perhaps because of the expiration date, or because it was declined when we attempted to charge a pledge.
<p>The card you previously gave us has become inactive; for example, because of its expiration date. You'll need to provide a current one before you can support ungluing campaigns.</p>
<p>We use <a href="https://stripe.com/">Stripe</a> to keep your information secure.</p><br />
<p><a class="fakeinput" id="show_cc_form">Update Card</a></p>
{% else %}
<p>Unglue.it has no active credit card on file for you. You'll need to provide one before you can support ungluing campaigns.</p>
<p>We use <a href="https://stripe.com/">Stripe</a> to keep your information secure.</p><br />
<p><a class="fakeinput" id="show_cc_form">Add A Card</a></p>
{% endif %}
<p>If you'd like to enter or update a card, <a id="show_cc_form">click here</a>.
</p>
{% endif %}
<div id="cc_pledge" style="display: none;">
<div id="authorize" class="clearfix">

View File

@ -17,7 +17,7 @@
<div><h2>Error: Card authorization for a pledge transaction</h2>
<div>
<p>Unglue.it would like to process your pledge, but there's some problem with our credit card processing. (<b>{{exception.message}}</b>) We'd appreciate it if you'd contact <a href="mailto:support@gluejar.com?subject={{ request.get_full_path|urlencode }}">unglue.it support</a>.
<p>Unglue.it would like to process your pledge, but there's been some problem processing your credit card (<b>{{exception.message}}</b>). Please <a href="{{ request.get_full_path }}">try again</a>, or contact <a href="mailto:support@gluejar.com?subject={{ request.get_full_path|urlencode }}">unglue.it support</a>.
</p>
</div>
</div>

View File

@ -66,17 +66,17 @@ Stripe Test:
{% csrf_token %}
<div class="form-row">
<label>Card Number</label>
<input type="text" size="20" autocomplete="off" class="card-number"/>
<input type="text" size="20" autocomplete="off" class="card-number" />
</div>
<div class="form-row">
<label>CVC</label>
<input type="text" size="4" autocomplete="off" class="card-cvc"/>
<input type="text" size="4" autocomplete="off" class="card-cvc" />
</div>
<div class="form-row">
<label>Expiration (MM/YYYY)</label>
<input type="text" size="2" class="card-expiry-month"/>
<input type="text" size="2" class="card-expiry-month" />
<span> / </span>
<input type="text" size="4" class="card-expiry-year"/>
<input type="text" size="4" class="card-expiry-year" />
</div>
<button type="submit" class="submit-button">Submit Payment</button>
</form>