This repository has been archived on 2024-06-26. You can view files and clone it, but cannot push or open issues or pull requests.
sakura/templates/yuuno/premium/index.twig

124 lines
7 KiB
Twig
Raw Normal View History

2016-01-04 20:14:09 +00:00
{% extends 'global/master.twig' %}
2016-03-31 20:03:25 +00:00
{% block title %}Support {{ config('sitename') }}{% endblock %}
2016-03-27 21:18:57 +00:00
{% set persistentPremium = user.permission(constant('Sakura\\Perms\\Site::STATIC_PREMIUM')) %}
{% block content %}
2016-03-27 21:18:57 +00:00
{% if get.fail %}
<div class="headerNotify">
<h1>The payment failed or was cancelled!</h1>
<p>Something went wrong while processing the transaction, your PayPal account wasn't charged.</p>
</div>
2015-07-01 00:16:22 +00:00
{% endif %}
2015-07-01 17:20:20 +00:00
<div class="content support">
2016-03-31 20:03:25 +00:00
<div class="head">Support {{ config('sitename') }}</div>
2015-05-03 16:25:57 +00:00
<div style="font-size: .9em; margin-bottom: 10px;">
2015-07-01 17:20:20 +00:00
<p>In order to keep the site, its services and improvements on it going I need money but I'm not that big of a fan of asking for money without giving anything special in return thus Tenshi exists. Tenshi is the name for our supporter rank which gives you access to an extra set of features (which are listed further down on this page). With your help we can keep adding new stuff, get new hardware and keep the site awesome!</p>
2015-05-03 16:25:57 +00:00
</div>
2016-03-27 21:18:57 +00:00
{% if user.isPremium %}
2015-07-01 17:20:20 +00:00
<div class="sectionHeader">
Your current Tenshi tag
</div>
<div style="margin-bottom: 10px;">
2016-03-31 20:03:25 +00:00
<h3>{% if persistentPremium %}Your rank has persistent Tenshi.{% else %}Your Tenshi tag is valid till {{ user.premiumInfo.expire|date(config('date_format')) }}.{% endif %}</h3>
2016-03-27 22:15:51 +00:00
<progress value="{{ persistentPremium ? 100 : (100 - (((date().timestamp - user.premiumInfo.start) / (user.premiumInfo.expire - user.premiumInfo.start)) * 100)) }}" max="100" style="width: 100%"></progress>
2015-07-01 17:20:20 +00:00
</div>
{% endif %}
2015-05-03 16:25:57 +00:00
<div class="sectionHeader">
Why should I get Tenshi?
</div>
<div class="featureParent">
2015-07-01 17:20:20 +00:00
<div class="featureBox">
<div class="featureBoxIcon fa fa-money"></div>
<div class="featureBoxDesc">Helping us pay for the bills to survive</div>
<div class="clear"></div>
</div>
<div class="featureBox">
<div class="featureBoxIcon fa fa-certificate"></div>
<div class="featureBoxDesc">A <span style="font-weight: bold; color: #EE9400">special</span> name colour to stand out in the crowd</div>
<div class="clear"></div>
</div>
<div class="featureBox">
<div class="featureBoxIcon fa fa-magic"></div>
<div class="featureBoxDesc">The ability to change your username once a month</div>
<div class="clear"></div>
</div>
<div class="featureBox">
<div class="featureBoxIcon fa fa-pencil"></div>
<div class="featureBoxDesc">You can set a custom user title</div>
<div class="clear"></div>
</div>
<div class="featureBox">
<div class="featureBoxIcon fa fa-archive"></div>
<div class="featureBoxDesc">You'll be able to read the chat logs</div>
<div class="clear"></div>
</div>
<div class="featureBox">
<div class="featureBoxIcon fa fa-eye-slash"></div>
<div class="featureBoxDesc">You can create temporary channels in the chat</div>
<div class="clear"></div>
</div>
<div class="featureBox">
<div class="featureBoxIcon fa fa-users"></div>
<div class="featureBoxDesc">You get to create a user group</div>
<div class="clear"></div>
</div>
<div class="featureBox">
<div class="featureBoxIcon fa fa-picture-o"></div>
<div class="featureBoxDesc">You get the ability to set a profile background</div>
<div class="clear"></div>
</div>
<div class="featureBox final">
<div class="featureBoxIcon fa fa-heart"></div>
<div class="featureBoxIcon right fa fa-heart"></div>
<div class="featureBoxDesc">The good feeling of helping the staff of your favourite site keep it up and awesome</div>
<div class="clear"></div>
2015-05-03 16:25:57 +00:00
</div>
</div>
<div class="sectionHeader">
2015-07-01 17:20:20 +00:00
Payment Options
2015-05-03 16:25:57 +00:00
<div style="float: right; font-size: 10px; text-align: right;">
2015-08-19 19:44:01 +00:00
Our transactions are handled through PayPal.
2015-07-01 17:20:20 +00:00
<div class="paymentOptions fa">
<div class="fa-cc-paypal"></div>
<div class="fa-cc-visa"></div>
<div class="fa-cc-mastercard"></div>
<div class="fa-cc-discover"></div>
<div class="fa-cc-amex"></div>
<div class="clear"></div>
</div>
2015-05-03 16:25:57 +00:00
</div>
</div>
2016-04-02 15:59:45 +00:00
{% if user.isActive and user.permission(constant('Sakura\\Perms\\Site::OBTAIN_PREMIUM')) %}
2015-07-01 17:20:20 +00:00
<div class="slider">
2016-03-27 21:18:57 +00:00
<input class="inputStyling" type="range" min="1" max="{{ amountLimit }}" value="1" onchange="document.getElementById('monthsNo').value = this.value; document.getElementById('monthNoBtn').innerHTML = this.value; document.getElementById('monthsTrailingS').innerHTML = (this.value == 1 ? '' : 's'); document.getElementById('totalAmount').innerHTML = (this.value * {{ price }}).formatMoney(2);" />
2015-07-01 17:20:20 +00:00
</div>
<div class="checkout" style="line-height: 28px;">
<div style="float: left;">
<h1 class="stylised">Total: &#8364;<span id="totalAmount"></span></h1>
2015-05-03 16:25:57 +00:00
</div>
2015-07-01 17:20:20 +00:00
<div style="float: right;">
<button class="inputStyling" onclick="ajaxBusyView(true, 'Please wait...');document.getElementById('purchaseForm').submit();">Get <span id="monthNoBtn">1</span> month<span id="monthsTrailingS"></span> of Tenshi</button>
2015-05-03 16:25:57 +00:00
</div>
2015-07-01 17:20:20 +00:00
<div class="clear"></div>
2015-05-03 16:25:57 +00:00
</div>
2016-04-02 15:59:45 +00:00
{% elseif user.isActive %}
2015-07-01 00:16:22 +00:00
<h1 style="text-align: center; margin: 1em auto;" class="stylised">You can't get Tenshi at the current moment!</h1>
2015-05-03 16:25:57 +00:00
{% else %}
2015-07-01 00:16:22 +00:00
<h1 style="text-align: center; margin: 1em auto;" class="stylised">You need to be logged in to get Tenshi!</h1>
2015-05-03 16:25:57 +00:00
{% endif %}
</div>
2016-04-02 15:59:45 +00:00
{% if user.isActive and user.permission(constant('Sakura\\Perms\\Site::OBTAIN_PREMIUM')) %}
2016-03-27 21:18:57 +00:00
<form action="{{ route('premium.purchase') }}" method="post" id="purchaseForm" class="hidden">
2015-07-01 17:20:20 +00:00
<input type="hidden" name="mode" value="purchase" />
2016-03-27 22:15:51 +00:00
<input type="hidden" name="time" value="{{ date().timestamp }}" />
<input type="hidden" name="session" value="{{ session_id() }}" />
2015-07-01 17:20:20 +00:00
<input type="hidden" name="months" id="monthsNo" value="1" />
</form>
<script type="text/javascript">
2016-03-27 21:18:57 +00:00
window.onload = function() { document.getElementById('totalAmount').innerHTML = ({{ price }}).formatMoney(2); };
2015-07-01 17:20:20 +00:00
</script>
{% endif %}
{% endblock %}