mirror of
https://github.com/getnamingo/registry.git
synced 2025-07-25 20:08:23 +02:00
Translations and fixes for financials
Correct currency and Stripe publishable key now shown.
This commit is contained in:
parent
0aeeec272c
commit
7096058c55
9 changed files with 57 additions and 136 deletions
|
@ -105,9 +105,13 @@ class FinancialsController extends Controller
|
||||||
$balance = $db->selectRow('SELECT name, accountBalance, creditLimit FROM registrar WHERE id = ?',
|
$balance = $db->selectRow('SELECT name, accountBalance, creditLimit FROM registrar WHERE id = ?',
|
||||||
[ $_SESSION["auth_registrar_id"] ]
|
[ $_SESSION["auth_registrar_id"] ]
|
||||||
);
|
);
|
||||||
|
$currency = $_SESSION['_currency'];
|
||||||
|
$stripe_key = envi('STRIPE_PUBLISHABLE_KEY');
|
||||||
|
|
||||||
return view($response,'admin/financials/deposit-registrar.twig', [
|
return view($response,'admin/financials/deposit-registrar.twig', [
|
||||||
'balance' => $balance
|
'balance' => $balance,
|
||||||
|
'currency' => $currency,
|
||||||
|
'stripe_key' => $stripe_key
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -183,9 +187,11 @@ class FinancialsController extends Controller
|
||||||
|
|
||||||
$db = $this->container->get('db');
|
$db = $this->container->get('db');
|
||||||
$registrars = $db->select("SELECT id, clid, name FROM registrar");
|
$registrars = $db->select("SELECT id, clid, name FROM registrar");
|
||||||
|
$currency = $_SESSION['_currency'];
|
||||||
|
|
||||||
return view($response,'admin/financials/deposit.twig', [
|
return view($response,'admin/financials/deposit.twig', [
|
||||||
'registrars' => $registrars
|
'registrars' => $registrars,
|
||||||
|
'currency' => $currency
|
||||||
]);
|
]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -25,5 +25,6 @@ MAIL_API_KEY='test-api-key'
|
||||||
MAIL_API_PROVIDER='sendgrid'
|
MAIL_API_PROVIDER='sendgrid'
|
||||||
|
|
||||||
STRIPE_SECRET_KEY='stripe-secret-key'
|
STRIPE_SECRET_KEY='stripe-secret-key'
|
||||||
|
STRIPE_PUBLISHABLE_KEY='stripe-publishable-key'
|
||||||
|
|
||||||
TEST_TLDS=.test,.com.test
|
TEST_TLDS=.test,.com.test
|
|
@ -26,26 +26,14 @@
|
||||||
<div class="col-12">
|
<div class="col-12">
|
||||||
<div class="card bg-orange-lt">
|
<div class="card bg-orange-lt">
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<p class="text-secondary">We've noticed that your deposit payment process was not completed. It appears that the payment was either cancelled or failed during the transaction. If this was an error, or if you have any questions, please don't hesitate to contact us. We're here to help ensure your transaction is smooth and secure.</p>
|
<p class="text-secondary">{{ __('We\'ve noticed that your deposit payment process was not completed. It appears that the payment was either cancelled or failed during the transaction. If this was an error, or if you have any questions, please don\'t hesitate to contact us. We're here to help ensure your transaction is smooth and secure.') }}</p>
|
||||||
<p class="text-secondary">Ready to try again? When you're set to proceed with your deposit, simply return to the <a href="{{route('deposit')}}">Deposit Page</a> to initiate a new payment. We value your partnership and are committed to assisting you every step of the way.</p>
|
<p class="text-secondary">{{ __('Ready to try again? When you\'re set to proceed with your deposit, simply return to the') }} <a href="{{route('deposit')}}">{{ __('Deposit Page') }}</a> {{ __('to initiate a new payment. We value your partnership and are committed to assisting you every step of the way.') }}</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<footer class="footer footer-transparent d-print-none">
|
{% include 'partials/footer.twig' %}
|
||||||
<div class="container-xl">
|
|
||||||
<div class="col-12 col-lg-auto mt-3 mt-lg-0">
|
|
||||||
<ul class="list-inline list-inline-dots mb-0">
|
|
||||||
<li class="list-inline-item">
|
|
||||||
Copyright © 2023
|
|
||||||
<a href="https://namingo.org" target="_blank" class="link-secondary">Namingo</a>.
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</footer>
|
|
||||||
</div>
|
</div>
|
||||||
{% endblock %}
|
{% endblock %}
|
|
@ -54,24 +54,24 @@
|
||||||
<form id="depositForm" action="/deposit" method="post">
|
<form id="depositForm" action="/deposit" method="post">
|
||||||
{{ csrf.field | raw }}
|
{{ csrf.field | raw }}
|
||||||
<div class="deposit-info">
|
<div class="deposit-info">
|
||||||
<h5>Current Balance for {{ balance.name }}</h5>
|
<h5>{{ __('Current Balance for') }} {{ balance.name }}</h5>
|
||||||
<p class="fs-4">${{ balance.accountBalance }}</p>
|
<p class="fs-4">{{ currency }} {{ balance.accountBalance }}</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mb-3">
|
<div class="mb-3">
|
||||||
<label for="amount" class="form-label">Amount</label>
|
<label for="amount" class="form-label">{{ __('Amount') }}</label>
|
||||||
<input type="number" step="0.01" class="form-control" id="amount" name="amount" placeholder="Enter deposit amount" required>
|
<input type="number" step="0.01" class="form-control" id="amount" name="amount" placeholder="{{ __('Enter deposit amount') }}" required>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mb-3">
|
<div class="mb-3">
|
||||||
<label for="description" class="form-label">Description</label>
|
<label for="description" class="form-label">{{ __('Description') }}</label>
|
||||||
<textarea class="form-control" id="description" name="description" rows="3" placeholder="Optional deposit description"></textarea>
|
<textarea class="form-control" id="description" name="description" rows="3" placeholder="{{ __('Optional deposit description') }}"></textarea>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="card-footer">
|
<div class="card-footer">
|
||||||
<div class="row align-items-center">
|
<div class="row align-items-center">
|
||||||
<div class="col-auto">
|
<div class="col-auto">
|
||||||
<button type="submit" class="btn btn-primary"><svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-brand-stripe" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M11.453 8.056c0 -.623 .518 -.979 1.442 -.979c1.69 0 3.41 .343 4.605 .923l.5 -4c-.948 -.449 -2.82 -1 -5.5 -1c-1.895 0 -3.373 .087 -4.5 1c-1.172 .956 -2 2.33 -2 4c0 3.03 1.958 4.906 5 6c1.961 .69 3 .743 3 1.5c0 .735 -.851 1.5 -2 1.5c-1.423 0 -3.963 -.609 -5.5 -1.5l-.5 4c1.321 .734 3.474 1.5 6 1.5c2 0 3.957 -.468 5.084 -1.36c1.263 -.979 1.916 -2.268 1.916 -4.14c0 -3.096 -1.915 -4.547 -5 -5.637c-1.646 -.605 -2.544 -1.07 -2.544 -1.807z" /></svg> Deposit with Stripe</button>
|
<button type="submit" class="btn btn-primary"><svg xmlns="http://www.w3.org/2000/svg" class="icon icon-tabler icon-tabler-brand-stripe" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M11.453 8.056c0 -.623 .518 -.979 1.442 -.979c1.69 0 3.41 .343 4.605 .923l.5 -4c-.948 -.449 -2.82 -1 -5.5 -1c-1.895 0 -3.373 .087 -4.5 1c-1.172 .956 -2 2.33 -2 4c0 3.03 1.958 4.906 5 6c1.961 .69 3 .743 3 1.5c0 .735 -.851 1.5 -2 1.5c-1.423 0 -3.963 -.609 -5.5 -1.5l-.5 4c1.321 .734 3.474 1.5 6 1.5c2 0 3.957 -.468 5.084 -1.36c1.263 -.979 1.916 -2.268 1.916 -4.14c0 -3.096 -1.915 -4.547 -5 -5.637c-1.646 -.605 -2.544 -1.07 -2.544 -1.807z" /></svg> {{ __('Deposit with Stripe') }}</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -81,23 +81,11 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<footer class="footer footer-transparent d-print-none">
|
{% include 'partials/footer.twig' %}
|
||||||
<div class="container-xl">
|
|
||||||
<div class="col-12 col-lg-auto mt-3 mt-lg-0">
|
|
||||||
<ul class="list-inline list-inline-dots mb-0">
|
|
||||||
<li class="list-inline-item">
|
|
||||||
Copyright © 2023
|
|
||||||
<a href="https://namingo.org" target="_blank" class="link-secondary">Namingo</a>.
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</footer>
|
|
||||||
</div>
|
</div>
|
||||||
<script src="https://js.stripe.com/v3/"></script>
|
<script src="https://js.stripe.com/v3/"></script>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
var stripe = Stripe('YOUR_PUBLISHABLE_KEY'); // Replace with your publishable key
|
var stripe = Stripe('{{ stripe_key }}');
|
||||||
|
|
||||||
document.getElementById('depositForm').addEventListener('submit', function (e) {
|
document.getElementById('depositForm').addEventListener('submit', function (e) {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
|
|
|
@ -54,9 +54,9 @@
|
||||||
<form id="depositForm" action="/deposit" method="post">
|
<form id="depositForm" action="/deposit" method="post">
|
||||||
{{ csrf.field | raw }}
|
{{ csrf.field | raw }}
|
||||||
<div class="mb-3">
|
<div class="mb-3">
|
||||||
<label for="registrarSelect" class="form-label">Registrar</label>
|
<label for="registrarSelect" class="form-label">{{ __('Registrar') }}</label>
|
||||||
<select class="form-select" id="registrarSelect" name="registrar" required>
|
<select class="form-select" id="registrarSelect" name="registrar" required>
|
||||||
<option selected disabled value="">Choose Registrar...</option>
|
<option selected disabled value="">{{ __('Choose Registrar...') }}</option>
|
||||||
{% for registrar in registrars %}
|
{% for registrar in registrars %}
|
||||||
<option value="{{ registrar.id }}">{{ registrar.name }}</option>
|
<option value="{{ registrar.id }}">{{ registrar.name }}</option>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
@ -64,24 +64,24 @@
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="deposit-info">
|
<div class="deposit-info">
|
||||||
<h5>Current Balance for <span id="registrarName"></span></h5>
|
<h5>{{ __('Current Balance for') }} <span id="registrarName"></span></h5>
|
||||||
<p class="fs-4">$<span id="currentFunds">0.00</span></p>
|
<p class="fs-4">{{ currency }} <span id="currentFunds">0.00</span></p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mb-3">
|
<div class="mb-3">
|
||||||
<label for="amount" class="form-label">Amount</label>
|
<label for="amount" class="form-label">{{ __('Amount') }}</label>
|
||||||
<input type="number" step="0.01" class="form-control" id="amount" name="amount" placeholder="Enter deposit amount" required>
|
<input type="number" step="0.01" class="form-control" id="amount" name="amount" placeholder="{{ __('Enter deposit amount') }}" required>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="mb-3">
|
<div class="mb-3">
|
||||||
<label for="description" class="form-label">Description</label>
|
<label for="description" class="form-label">{{ __('Description') }}</label>
|
||||||
<textarea class="form-control" id="description" name="description" rows="3" placeholder="Optional deposit description"></textarea>
|
<textarea class="form-control" id="description" name="description" rows="3" placeholder="{{ __('Optional deposit description') }}"></textarea>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="card-footer">
|
<div class="card-footer">
|
||||||
<div class="row align-items-center">
|
<div class="row align-items-center">
|
||||||
<div class="col-auto">
|
<div class="col-auto">
|
||||||
<button type="submit" class="btn btn-primary">Add Deposit</button>
|
<button type="submit" class="btn btn-primary">{{ __('Add Deposit') }}</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -113,18 +113,6 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<footer class="footer footer-transparent d-print-none">
|
{% include 'partials/footer.twig' %}
|
||||||
<div class="container-xl">
|
|
||||||
<div class="col-12 col-lg-auto mt-3 mt-lg-0">
|
|
||||||
<ul class="list-inline list-inline-dots mb-0">
|
|
||||||
<li class="list-inline-item">
|
|
||||||
Copyright © 2023
|
|
||||||
<a href="https://namingo.org" target="_blank" class="link-secondary">Namingo</a>.
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</footer>
|
|
||||||
</div>
|
</div>
|
||||||
{% endblock %}
|
{% endblock %}
|
|
@ -35,9 +35,9 @@
|
||||||
<button class="btn btn-red btn-icon" onclick="downloadPDF()"><svg xmlns="http://www.w3.org/2000/svg" class="icon" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M10 8v8h2a2 2 0 0 0 2 -2v-4a2 2 0 0 0 -2 -2h-2z"></path><path d="M3 12h2a2 2 0 1 0 0 -4h-2v8"></path><path d="M17 12h3"></path><path d="M21 8h-4v8"></path></svg></button>
|
<button class="btn btn-red btn-icon" onclick="downloadPDF()"><svg xmlns="http://www.w3.org/2000/svg" class="icon" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M10 8v8h2a2 2 0 0 0 2 -2v-4a2 2 0 0 0 -2 -2h-2z"></path><path d="M3 12h2a2 2 0 1 0 0 -4h-2v8"></path><path d="M17 12h3"></path><path d="M21 8h-4v8"></path></svg></button>
|
||||||
</div>
|
</div>
|
||||||
<div class="ms-auto text-secondary">
|
<div class="ms-auto text-secondary">
|
||||||
Search:
|
{{ __('Search') }}:
|
||||||
<div class="ms-2 d-inline-block">
|
<div class="ms-2 d-inline-block">
|
||||||
<input id="search-input" type="text" class="form-control" aria-label="Search invoices">
|
<input id="search-input" type="text" class="form-control" aria-label="{{ __('Search invoices') }}">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -49,18 +49,6 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<footer class="footer footer-transparent d-print-none">
|
{% include 'partials/footer.twig' %}
|
||||||
<div class="container-xl">
|
|
||||||
<div class="col-12 col-lg-auto mt-3 mt-lg-0">
|
|
||||||
<ul class="list-inline list-inline-dots mb-0">
|
|
||||||
<li class="list-inline-item">
|
|
||||||
Copyright © 2023
|
|
||||||
<a href="https://namingo.org" target="_blank" class="link-secondary">Namingo</a>.
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</footer>
|
|
||||||
</div>
|
</div>
|
||||||
{% endblock %}
|
{% endblock %}
|
|
@ -34,9 +34,9 @@
|
||||||
<button class="btn btn-red btn-icon" onclick="downloadPDF()"><svg xmlns="http://www.w3.org/2000/svg" class="icon" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M10 8v8h2a2 2 0 0 0 2 -2v-4a2 2 0 0 0 -2 -2h-2z"></path><path d="M3 12h2a2 2 0 1 0 0 -4h-2v8"></path><path d="M17 12h3"></path><path d="M21 8h-4v8"></path></svg></button>
|
<button class="btn btn-red btn-icon" onclick="downloadPDF()"><svg xmlns="http://www.w3.org/2000/svg" class="icon" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M10 8v8h2a2 2 0 0 0 2 -2v-4a2 2 0 0 0 -2 -2h-2z"></path><path d="M3 12h2a2 2 0 1 0 0 -4h-2v8"></path><path d="M17 12h3"></path><path d="M21 8h-4v8"></path></svg></button>
|
||||||
</div>
|
</div>
|
||||||
<div class="ms-auto text-secondary">
|
<div class="ms-auto text-secondary">
|
||||||
Search:
|
{{ __('Search') }}:
|
||||||
<div class="ms-2 d-inline-block">
|
<div class="ms-2 d-inline-block">
|
||||||
<input id="search-input" type="text" class="form-control" aria-label="Search account">
|
<input id="search-input" type="text" class="form-control" aria-label="{{ __('Search account') }}">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -48,18 +48,6 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<footer class="footer footer-transparent d-print-none">
|
{% include 'partials/footer.twig' %}
|
||||||
<div class="container-xl">
|
|
||||||
<div class="col-12 col-lg-auto mt-3 mt-lg-0">
|
|
||||||
<ul class="list-inline list-inline-dots mb-0">
|
|
||||||
<li class="list-inline-item">
|
|
||||||
Copyright © 2023
|
|
||||||
<a href="https://namingo.org" target="_blank" class="link-secondary">Namingo</a>.
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</footer>
|
|
||||||
</div>
|
</div>
|
||||||
{% endblock %}
|
{% endblock %}
|
|
@ -34,9 +34,9 @@
|
||||||
<button class="btn btn-red btn-icon" onclick="downloadPDF()"><svg xmlns="http://www.w3.org/2000/svg" class="icon" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M10 8v8h2a2 2 0 0 0 2 -2v-4a2 2 0 0 0 -2 -2h-2z"></path><path d="M3 12h2a2 2 0 1 0 0 -4h-2v8"></path><path d="M17 12h3"></path><path d="M21 8h-4v8"></path></svg></button>
|
<button class="btn btn-red btn-icon" onclick="downloadPDF()"><svg xmlns="http://www.w3.org/2000/svg" class="icon" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"></path><path d="M10 8v8h2a2 2 0 0 0 2 -2v-4a2 2 0 0 0 -2 -2h-2z"></path><path d="M3 12h2a2 2 0 1 0 0 -4h-2v8"></path><path d="M17 12h3"></path><path d="M21 8h-4v8"></path></svg></button>
|
||||||
</div>
|
</div>
|
||||||
<div class="ms-auto text-secondary">
|
<div class="ms-auto text-secondary">
|
||||||
Search:
|
{{ __('Search') }}:
|
||||||
<div class="ms-2 d-inline-block">
|
<div class="ms-2 d-inline-block">
|
||||||
<input id="search-input" type="text" class="form-control" aria-label="Search transactions">
|
<input id="search-input" type="text" class="form-control" aria-label="{{ __('Search transactions') }}">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -48,18 +48,6 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<footer class="footer footer-transparent d-print-none">
|
{% include 'partials/footer.twig' %}
|
||||||
<div class="container-xl">
|
|
||||||
<div class="col-12 col-lg-auto mt-3 mt-lg-0">
|
|
||||||
<ul class="list-inline list-inline-dots mb-0">
|
|
||||||
<li class="list-inline-item">
|
|
||||||
Copyright © 2023
|
|
||||||
<a href="https://namingo.org" target="_blank" class="link-secondary">Namingo</a>.
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</footer>
|
|
||||||
</div>
|
</div>
|
||||||
{% endblock %}
|
{% endblock %}
|
|
@ -10,15 +10,14 @@
|
||||||
<div class="row g-2 align-items-center">
|
<div class="row g-2 align-items-center">
|
||||||
<div class="col">
|
<div class="col">
|
||||||
<h2 class="page-title">
|
<h2 class="page-title">
|
||||||
Invoice {{ invoice_details.invoice_number }}
|
{{ __('Invoice') }} {{ invoice_details.invoice_number }}
|
||||||
</h2>
|
</h2>
|
||||||
</div>
|
</div>
|
||||||
<!-- Page title actions -->
|
<!-- Page title actions -->
|
||||||
<div class="col-auto ms-auto d-print-none">
|
<div class="col-auto ms-auto d-print-none">
|
||||||
<button type="button" class="btn btn-primary" onclick="javascript:window.print();">
|
<button type="button" class="btn btn-primary" onclick="javascript:window.print();">
|
||||||
<!-- Download SVG icon from http://tabler-icons.io/i/printer -->
|
|
||||||
<svg xmlns="http://www.w3.org/2000/svg" class="icon" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M17 17h2a2 2 0 0 0 2 -2v-4a2 2 0 0 0 -2 -2h-14a2 2 0 0 0 -2 2v4a2 2 0 0 0 2 2h2" /><path d="M17 9v-4a2 2 0 0 0 -2 -2h-6a2 2 0 0 0 -2 2v4" /><path d="M7 13m0 2a2 2 0 0 1 2 -2h6a2 2 0 0 1 2 2v4a2 2 0 0 1 -2 2h-6a2 2 0 0 1 -2 -2z" /></svg>
|
<svg xmlns="http://www.w3.org/2000/svg" class="icon" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M17 17h2a2 2 0 0 0 2 -2v-4a2 2 0 0 0 -2 -2h-14a2 2 0 0 0 -2 2v4a2 2 0 0 0 2 2h2" /><path d="M17 9v-4a2 2 0 0 0 -2 -2h-6a2 2 0 0 0 -2 2v4" /><path d="M7 13m0 2a2 2 0 0 1 2 -2h6a2 2 0 0 1 2 2v4a2 2 0 0 1 -2 2h-6a2 2 0 0 1 -2 -2z" /></svg>
|
||||||
Print Invoice
|
{{ __('Print Invoice') }}
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -31,7 +30,7 @@
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-6">
|
<div class="col-6">
|
||||||
<p class="h3">Provider / Registry</p>
|
<p class="h3">{{ __('Provider') }} / {{ __('Registry') }}</p>
|
||||||
<address>
|
<address>
|
||||||
{{ company_name }}<br>
|
{{ company_name }}<br>
|
||||||
{{ vat_number }}<br>
|
{{ vat_number }}<br>
|
||||||
|
@ -42,7 +41,7 @@
|
||||||
</address>
|
</address>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-6 text-end">
|
<div class="col-6 text-end">
|
||||||
<p class="h3">Client / Registrar</p>
|
<p class="h3">{{ __('Client') }} / {{ __('Registrar') }}</p>
|
||||||
<address>
|
<address>
|
||||||
{{ billing.org }}<br>
|
{{ billing.org }}<br>
|
||||||
{{ billing_vat }} {% if validVAT %}<svg xmlns="http://www.w3.org/2000/svg" class="icon text-success" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M5 12l5 5l10 -10" /></svg>{% endif %}<br>
|
{{ billing_vat }} {% if validVAT %}<svg xmlns="http://www.w3.org/2000/svg" class="icon text-success" width="24" height="24" viewBox="0 0 24 24" stroke-width="2" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M5 12l5 5l10 -10" /></svg>{% endif %}<br>
|
||||||
|
@ -53,13 +52,13 @@
|
||||||
</address>
|
</address>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-6">
|
<div class="col-6">
|
||||||
<p class="h3">Invoice Issued On: {{ invoice_details.issue_date|date("Y-m-d") }}</p>
|
<p class="h3">{{ __('Invoice Issued On') }}: {{ invoice_details.issue_date|date("Y-m-d") }}</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-6 text-end">
|
<div class="col-6 text-end">
|
||||||
<p class="h3">Due Date: {{ invoice_details.due_date|date("Y-m-d") }}</p>
|
<p class="h3">{{ __('Due Date') }}: {{ invoice_details.due_date|date("Y-m-d") }}</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-12 my-5">
|
<div class="col-12 my-5">
|
||||||
<h1>Invoice {{ invoice_details.invoice_number }} {% set status = invoice_details.payment_status %}
|
<h1>{{ __('Invoice') }} {{ invoice_details.invoice_number }} {% set status = invoice_details.payment_status %}
|
||||||
<span class="badge
|
<span class="badge
|
||||||
{% if status == 'unpaid' %}bg-red text-red-fg
|
{% if status == 'unpaid' %}bg-red text-red-fg
|
||||||
{% elseif status == 'paid' %}bg-green text-green-fg
|
{% elseif status == 'paid' %}bg-green text-green-fg
|
||||||
|
@ -76,8 +75,8 @@
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th class="text-center" style="width: 1%"></th>
|
<th class="text-center" style="width: 1%"></th>
|
||||||
<th>Product</th>
|
<th>{{ __('Product') }}</th>
|
||||||
<th class="text-end" style="width: 1%">Amount</th>
|
<th class="text-end" style="width: 1%">{{ __('Amount') }}</th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
{% if statement is not empty %}
|
{% if statement is not empty %}
|
||||||
|
@ -94,45 +93,32 @@
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
{% else %}
|
{% else %}
|
||||||
<tr>
|
<tr>
|
||||||
<td colspan="2" class="text-center">No items found.</td>
|
<td colspan="2" class="text-center">{{ __('No items found.') }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
<tr>
|
<tr>
|
||||||
<td colspan="2" class="strong text-end">Subtotal</td>
|
<td colspan="2" class="strong text-end">{{ __('Subtotal') }}</td>
|
||||||
<td class="text-end">{{ netPrice }}</td>
|
<td class="text-end">{{ netPrice }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td colspan="2" class="strong text-end">Vat Rate</td>
|
<td colspan="2" class="strong text-end">{{ __('Vat Rate') }}</td>
|
||||||
<td class="text-end">{{ vatRate }}</td>
|
<td class="text-end">{{ vatRate }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td colspan="2" class="strong text-end">Vat Due</td>
|
<td colspan="2" class="strong text-end">{{ __('Vat Due') }}</td>
|
||||||
<td class="text-end">{{ vatAmount }}</td>
|
<td class="text-end">{{ vatAmount }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td colspan="2" class="font-weight-bold text-uppercase text-end">Total Due</td>
|
<td colspan="2" class="font-weight-bold text-uppercase text-end">{{ __('Total Due') }}</td>
|
||||||
<td class="font-weight-bold text-end">{{ total }}</td>
|
<td class="font-weight-bold text-end">{{ total }}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
<p class="text-secondary text-center mt-5">Notes: {{ invoice_details.notes }}</p>
|
<p class="text-secondary text-center mt-5">{{ __('Notes') }}: {{ invoice_details.notes }}</p>
|
||||||
<p class="text-secondary text-center mt-5">Thank you very much for doing business with us. We look forward to working with
|
<p class="text-secondary text-center mt-5">{{ __('Thank you very much for doing business with us. We look forward to working with you again!') }}</p>
|
||||||
you again!</p>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<footer class="footer footer-transparent d-print-none">
|
{% include 'partials/footer.twig' %}
|
||||||
<div class="container-xl">
|
|
||||||
<div class="col-12 col-lg-auto mt-3 mt-lg-0">
|
|
||||||
<ul class="list-inline list-inline-dots mb-0">
|
|
||||||
<li class="list-inline-item">
|
|
||||||
Copyright © 2023
|
|
||||||
<a href="https://namingo.org" target="_blank" class="link-secondary">Namingo</a>.
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</footer>
|
|
||||||
</div>
|
</div>
|
||||||
{% endblock %}
|
{% endblock %}
|
Loading…
Add table
Add a link
Reference in a new issue