2016-10-16 15:38:04 +02:00
|
|
|
<style>
|
|
|
|
|
|
|
|
#upgrade-modal {
|
|
|
|
display: none;
|
|
|
|
position: absolute;
|
|
|
|
z-index: 999999;
|
|
|
|
#background-color: rgba(76,76,76,.99);
|
|
|
|
background-color: rgba(0,0,0,.9);
|
|
|
|
text-align: center;
|
|
|
|
width: 100%;
|
|
|
|
height: 100%;
|
2016-10-18 15:13:12 +02:00
|
|
|
min-height: 1500px;
|
2016-10-16 15:38:04 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
#upgrade-modal h1 {
|
|
|
|
font-family: 'roboto-thin', 'roboto', Helvetica, arial, sans-serif;
|
|
|
|
font-size: 28px!important;
|
|
|
|
padding: 0 0 25px 0;
|
|
|
|
margin: 0!important;
|
|
|
|
color: #fff;
|
2016-10-18 15:13:12 +02:00
|
|
|
padding-top: 0px;
|
|
|
|
padding-bottom: 20px;
|
2016-10-16 15:38:04 +02:00
|
|
|
font-weight: 800;
|
|
|
|
}
|
|
|
|
|
|
|
|
#upgrade-modal h2 {
|
|
|
|
font-family: 'roboto-thin', 'roboto', Helvetica, arial, sans-serif;
|
|
|
|
color: #36c157;
|
|
|
|
font-size: 34px;
|
|
|
|
line-height: 15px;
|
|
|
|
padding-bottom: 4px;
|
|
|
|
margin: 0;
|
|
|
|
font-weight: 100;
|
|
|
|
}
|
|
|
|
|
|
|
|
#upgrade-modal h3 {
|
|
|
|
font-family: 'roboto-thin', 'roboto', Helvetica, arial, sans-serif;
|
|
|
|
margin: 20px 0 25px 0;
|
|
|
|
font-size: 75px;
|
|
|
|
padding: 0 0 8px 0;
|
|
|
|
color: #fff;
|
|
|
|
font-weight: 100;
|
|
|
|
}
|
|
|
|
|
|
|
|
#upgrade-modal h3 span.upgrade_frequency {
|
|
|
|
font-size: 17px;
|
|
|
|
text-transform: uppercase;
|
|
|
|
letter-spacing: 2px;
|
|
|
|
vertical-align: super;
|
|
|
|
}
|
|
|
|
|
|
|
|
#upgrade-modal ul {
|
|
|
|
list-style: none;
|
|
|
|
color: #fff;
|
|
|
|
padding: 20px 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
#upgrade-modal .col-md-4 {
|
|
|
|
padding:75px 20px;
|
|
|
|
border-right: 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
#upgrade-modal .col-md-offset-2 {
|
|
|
|
border-top: 1px solid #343333;
|
|
|
|
border-right: 1px solid #343333;
|
|
|
|
}
|
|
|
|
|
|
|
|
#upgrade-modal .columns {
|
|
|
|
border-top: 1px solid #343333;
|
|
|
|
}
|
|
|
|
|
|
|
|
#upgrade-modal ul {
|
|
|
|
border-top: 1px solid #343333;
|
|
|
|
}
|
|
|
|
|
|
|
|
#upgrade-modal ul li {
|
|
|
|
font-size: 17px;
|
|
|
|
line-height: 35px;
|
|
|
|
font-weight: 400;
|
|
|
|
}
|
|
|
|
|
|
|
|
#upgrade-modal p.subhead {
|
|
|
|
font-size: 15px;
|
|
|
|
margin: 5px 0 5px 0;
|
|
|
|
padding-top: 10px;
|
|
|
|
padding-bottom: 10px;
|
|
|
|
font-weight: 400;
|
|
|
|
color: #fff;
|
|
|
|
}
|
|
|
|
|
|
|
|
#upgrade-modal .btn {
|
|
|
|
width: 260px;
|
|
|
|
padding: 16px 0 16px 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
#upgrade-modal i.fa-close {
|
|
|
|
cursor: pointer;
|
|
|
|
color: #fff;
|
|
|
|
font-size: 26px !important;
|
|
|
|
padding-top: 30px;
|
|
|
|
}
|
|
|
|
|
|
|
|
#upgrade-modal label.radio-inline {
|
|
|
|
padding: 0px 30px 30px 30px;
|
|
|
|
font-size: 22px;
|
|
|
|
color: #fff;
|
|
|
|
vertical-align: middle;
|
|
|
|
}
|
|
|
|
|
|
|
|
#upgrade-modal select {
|
|
|
|
vertical-align: top;
|
|
|
|
width: 140px;
|
|
|
|
}
|
|
|
|
|
|
|
|
</style>
|
|
|
|
|
|
|
|
{!! Former::open('settings/change_plan')->addClass('upgrade-form') !!}
|
|
|
|
|
|
|
|
<span style="display:none">
|
|
|
|
{!! Former::text('plan') !!}
|
|
|
|
</span>
|
|
|
|
|
|
|
|
<div id="upgrade-modal" class="container" style="">
|
|
|
|
<div class="row">
|
|
|
|
<div class="col-md-10 text-right">
|
2016-10-18 16:55:07 +02:00
|
|
|
<a href="#"><i class="fa fa-close" onclick="hideUpgradeModal()" title="{{ trans('texts.close') }}"></i></a>
|
2016-10-16 15:38:04 +02:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="row">
|
|
|
|
<div class="col-md-12 text-center">
|
|
|
|
<h1>{{ trans('texts.upgrade_for_features') }}</h1>
|
|
|
|
<h4 onclick="updateUpgradePrices()">
|
|
|
|
<label for="plan_term_month" class="radio-inline">
|
|
|
|
<input value="month" id="plan_term_month" type="radio" name="plan_term" checked>Monthly</label>
|
|
|
|
<label for="plan_term_year" class="radio-inline">
|
|
|
|
<input value="year" id="plan_term_year" type="radio" name="plan_term">Annually</label>
|
|
|
|
</h4>
|
|
|
|
</div>
|
|
|
|
<div class="col-md-4 col-md-offset-2 text-center">
|
|
|
|
<h2>{{ trans('texts.pro_upgrade_title') }}</h2>
|
|
|
|
<p class="subhead">{{ trans('texts.pay_annually_discount') }}</p>
|
|
|
|
<img width="65" src="{{ asset('images/pro_plan/border.png') }}"/>
|
|
|
|
<h3>$<span id="upgrade_pro_price">8</span> <span class="upgrade_frequency">/ {{ trans('texts.plan_term_month') }}</span></h3>
|
|
|
|
<select style="visibility:hidden">
|
|
|
|
</select>
|
2016-12-01 08:05:26 +01:00
|
|
|
<p> </p>
|
2016-10-16 15:38:04 +02:00
|
|
|
<ul>
|
|
|
|
<li>{{ trans('texts.pro_upgrade_feature1') }}</li>
|
|
|
|
<li>{{ trans('texts.pro_upgrade_feature2') }}</li>
|
|
|
|
<li>{{ trans('texts.much_more') }}</li>
|
|
|
|
</ul>
|
|
|
|
{!! Button::success(trans('texts.go_ninja_pro'))->withAttributes(['onclick' => 'submitUpgradeForm("pro")'])->large() !!}
|
|
|
|
</div>
|
|
|
|
<div class="col-md-4 columns text-center">
|
|
|
|
<h2>{{ trans('texts.plan_enterprise') }}</h2>
|
|
|
|
<p class="subhead">{{ trans('texts.pay_annually_discount') }}</p>
|
|
|
|
<img width="65" src="{{ asset('images/pro_plan/border.png') }}"/>
|
|
|
|
<h3>$<span id="upgrade_enterprise_price">12</span> <span class="upgrade_frequency">/ {{ trans('texts.plan_term_month') }}</span></h3>
|
|
|
|
<select name="num_users" id="upgrade_num_users" onchange="updateUpgradePrices()">
|
|
|
|
<option value="2">1 to 2 {{ trans('texts.users') }}</option>
|
|
|
|
<option value="5">3 to 5 {{ trans('texts.users') }}</option>
|
|
|
|
<option value="10">6 to 10 {{ trans('texts.users') }}</option>
|
|
|
|
</select>
|
2016-12-01 08:05:26 +01:00
|
|
|
<p> </p>
|
2016-10-16 15:38:04 +02:00
|
|
|
<ul>
|
|
|
|
<li>{{ trans('texts.enterprise_upgrade_feature1') }}</li>
|
|
|
|
<li>{{ trans('texts.enterprise_upgrade_feature2') }}</li>
|
|
|
|
<li>{{ trans('texts.much_more') }}</li>
|
|
|
|
</ul>
|
|
|
|
{!! Button::success(trans('texts.go_enterprise'))->withAttributes(['onclick' => 'submitUpgradeForm("enterprise")'])->large() !!}
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
{!! Former::close() !!}
|
|
|
|
|
|
|
|
<script type="text/javascript">
|
|
|
|
|
|
|
|
function showUpgradeModal() {
|
2016-11-02 07:49:02 +01:00
|
|
|
@if ( ! Auth::check() || ! Auth::user()->confirmed)
|
|
|
|
swal("{{ trans('texts.confirmation_required') }}");
|
|
|
|
return;
|
|
|
|
@endif
|
|
|
|
|
2016-10-18 17:01:33 +02:00
|
|
|
$(window).scrollTop(0);
|
|
|
|
$('#upgrade-modal').fadeIn();
|
2016-10-16 15:38:04 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
function hideUpgradeModal() {
|
|
|
|
$('#upgrade-modal').fadeOut();
|
|
|
|
}
|
|
|
|
|
|
|
|
function updateUpgradePrices() {
|
|
|
|
var planTerm = $('input[name=plan_term]:checked').val();
|
|
|
|
var numUsers = $('#upgrade_num_users').val();
|
|
|
|
if (planTerm == 'month') {
|
|
|
|
var proPrice = {{ PLAN_PRICE_PRO_MONTHLY }};
|
|
|
|
if (numUsers == 2) {
|
|
|
|
var enterprisePrice = {{ PLAN_PRICE_ENTERPRISE_MONTHLY_2 }};
|
|
|
|
} else if (numUsers == 5) {
|
|
|
|
var enterprisePrice = {{ PLAN_PRICE_ENTERPRISE_MONTHLY_5 }};
|
|
|
|
} else if (numUsers == 10) {
|
|
|
|
var enterprisePrice = {{ PLAN_PRICE_ENTERPRISE_MONTHLY_10 }};
|
|
|
|
}
|
|
|
|
var label = "{{ trans('texts.freq_monthly') }}";
|
|
|
|
} else {
|
|
|
|
var proPrice = {{ PLAN_PRICE_PRO_MONTHLY * 10 }};
|
|
|
|
if (numUsers == 2) {
|
|
|
|
var enterprisePrice = {{ PLAN_PRICE_ENTERPRISE_MONTHLY_2 * 10 }};
|
|
|
|
} else if (numUsers == 5) {
|
|
|
|
var enterprisePrice = {{ PLAN_PRICE_ENTERPRISE_MONTHLY_5 * 10 }};
|
|
|
|
} else if (numUsers == 10) {
|
|
|
|
var enterprisePrice = {{ PLAN_PRICE_ENTERPRISE_MONTHLY_10 * 10 }};
|
|
|
|
}
|
|
|
|
var label = "{{ trans('texts.freq_annually') }}";
|
|
|
|
}
|
|
|
|
$('#upgrade_pro_price').text(proPrice);
|
|
|
|
$('#upgrade_enterprise_price').text(enterprisePrice);
|
|
|
|
$('span.upgrade_frequency').text(label);
|
|
|
|
}
|
|
|
|
|
|
|
|
function submitUpgradeForm(plan) {
|
|
|
|
$('#plan').val(plan);
|
|
|
|
$('.upgrade-form').submit();
|
|
|
|
}
|
|
|
|
|
|
|
|
$(function() {
|
|
|
|
$(document).keyup(function(e) {
|
|
|
|
if (e.keyCode == 27) { // escape key maps to keycode `27`
|
|
|
|
hideUpgradeModal();
|
|
|
|
}
|
|
|
|
});
|
|
|
|
})
|
|
|
|
|
|
|
|
</script>
|