%page args="credit_status" /> <%! import datetime import pytz from django.utils.translation import ugettext as _ from util.date_utils import get_default_time_display %> <%namespace name='static' file='../static_content.html'/> % if credit_status["provider_name"]: <% provider_link='{}'.format(credit_status["provider_status_url"], credit_status["provider_name"]) %> % endif % if credit_status["eligible"]:
${_("An error occurred with this transaction. For help, contact {support_email}.").format( support_email=u'{address}'.format( address=settings.DEFAULT_FEEDBACK_EMAIL ) )}
% if not credit_status["purchased"] and not credit_status["error"] :${_("You are now eligible for credit. Congratulations!")}
% elif credit_status["request_status"] in [None, "pending"] and not credit_status["error"] : % if credit_status["request_status"] == "pending":## Translators: link_to_provider_site is a link to an external webpage. The text of the link will be the name of a ## credit provider, such as 'State University' or 'Happy Fun Company' ${_("Thank you. Your credit is processing. Please see {link_to_provider_site} for more information.").format( link_to_provider_site=provider_link, ) }
% elif credit_status["request_status"] is None:## Translators: link_to_provider_site is a link to an external webpage. The text of the link will be the name of a ## credit provider, such as 'State University' or 'Happy Fun Company' ${_("Thank you for your purchase. Please proceed to {link_to_provider_site} to finalize your credit.").format( link_to_provider_site=provider_link, ) }
% endif % elif credit_status["request_status"] == "approved" and not credit_status["error"] :## Translators: link_to_provider_site is a link to an external webpage. The text of the link will be the name of a ## credit provider, such as 'State University' or 'Happy Fun Company' ${_("Your credit has been processed and approved. Congratulations!. Please see {link_to_provider_site} for more information.").format( link_to_provider_site=provider_link, ) }
${_("Access credit")} % elif credit_status["request_status"] == "rejected" and not credit_status["error"] :## Translators: link_to_provider_site is a link to an external webpage. The text of the link will be the name of a ## credit provider, such as 'State University' or 'Happy Fun Company' ${_("Your credit has been processed but denied. Please contact {link_to_provider_site} for more information.").format( link_to_provider_site=provider_link, ) }
${_("Contact {provider}").format(provider=u'credit_status["provider_name"]') } % endif