mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Add ‘approve’ button/link to email variables
This commit is contained in:
parent
07a2b3d7f9
commit
b4e2329076
@ -85,11 +85,11 @@ class AppServiceProvider extends ServiceProvider
|
|||||||
->render();
|
->render();
|
||||||
});
|
});
|
||||||
|
|
||||||
Form::macro('emailPaymentButton', function ($link = '#') {
|
Form::macro('emailPaymentButton', function ($link = '#', $label = 'pay_now') {
|
||||||
return view('partials.email_button')
|
return view('partials.email_button')
|
||||||
->with([
|
->with([
|
||||||
'link' => $link,
|
'link' => $link,
|
||||||
'field' => 'pay_now',
|
'field' => $label,
|
||||||
'color' => '#36c157',
|
'color' => '#36c157',
|
||||||
])
|
])
|
||||||
->render();
|
->render();
|
||||||
|
@ -74,6 +74,8 @@ class TemplateService
|
|||||||
'$viewButton' => Form::emailViewButton($invitation->getLink(), $entityType).'$password',
|
'$viewButton' => Form::emailViewButton($invitation->getLink(), $entityType).'$password',
|
||||||
'$paymentLink' => $invitation->getLink('payment').'$password',
|
'$paymentLink' => $invitation->getLink('payment').'$password',
|
||||||
'$paymentButton' => Form::emailPaymentButton($invitation->getLink('payment')).'$password',
|
'$paymentButton' => Form::emailPaymentButton($invitation->getLink('payment')).'$password',
|
||||||
|
'$approveLink' => $invitation->getLink('approve').'$password',
|
||||||
|
'$approveButton' => Form::emailPaymentButton($invitation->getLink('approve'), 'approve').'$password',
|
||||||
'$customClient1' => $client->custom_value1,
|
'$customClient1' => $client->custom_value1,
|
||||||
'$customClient2' => $client->custom_value2,
|
'$customClient2' => $client->custom_value2,
|
||||||
'$customContact1' => $contact->custom_value1,
|
'$customContact1' => $contact->custom_value1,
|
||||||
|
@ -45,6 +45,8 @@
|
|||||||
'viewButton': viewButton,
|
'viewButton': viewButton,
|
||||||
'paymentLink': '{{ link_to('#', auth()->user()->account->getBaseUrl() . '/...') }}$password',
|
'paymentLink': '{{ link_to('#', auth()->user()->account->getBaseUrl() . '/...') }}$password',
|
||||||
'paymentButton': {!! json_encode(Form::flatButton('pay_now', '#36c157')) !!} + '$password',
|
'paymentButton': {!! json_encode(Form::flatButton('pay_now', '#36c157')) !!} + '$password',
|
||||||
|
'approveLink': '{{ link_to('#', auth()->user()->account->getBaseUrl() . '/...') }}$password',
|
||||||
|
'approveButton': {!! json_encode(Form::flatButton('approve', '#36c157')) !!} + '$password',
|
||||||
'autoBill': '{{ trans('texts.auto_bill_notification_placeholder') }}',
|
'autoBill': '{{ trans('texts.auto_bill_notification_placeholder') }}',
|
||||||
'portalLink': "{{ auth()->user()->account->getBaseUrl() . '/...' }}",
|
'portalLink': "{{ auth()->user()->account->getBaseUrl() . '/...' }}",
|
||||||
'portalButton': {!! json_encode(Form::flatButton('view_portal', '#36c157')) !!},
|
'portalButton': {!! json_encode(Form::flatButton('view_portal', '#36c157')) !!},
|
||||||
@ -96,11 +98,14 @@
|
|||||||
<div class="panel-body">
|
<div class="panel-body">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-md-6">
|
<div class="col-md-6">
|
||||||
<p>{{ trans('texts.company_variables') }}</p>
|
<p>{{ trans('texts.client_variables') }}</p>
|
||||||
<ul>
|
<ul>
|
||||||
@foreach([
|
@foreach([
|
||||||
'account',
|
'client',
|
||||||
'emailSignature',
|
'contact',
|
||||||
|
'firstName',
|
||||||
|
'password',
|
||||||
|
'autoBill',
|
||||||
] as $field)
|
] as $field)
|
||||||
<li>${{ $field }}</li>
|
<li>${{ $field }}</li>
|
||||||
@endforeach
|
@endforeach
|
||||||
@ -122,14 +127,11 @@
|
|||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-md-6">
|
<div class="col-md-6">
|
||||||
<p>{{ trans('texts.client_variables') }}</p>
|
<p>{{ trans('texts.company_variables') }}</p>
|
||||||
<ul>
|
<ul>
|
||||||
@foreach([
|
@foreach([
|
||||||
'client',
|
'account',
|
||||||
'contact',
|
'emailSignature',
|
||||||
'firstName',
|
|
||||||
'password',
|
|
||||||
'autoBill',
|
|
||||||
] as $field)
|
] as $field)
|
||||||
<li>${{ $field }}</li>
|
<li>${{ $field }}</li>
|
||||||
@endforeach
|
@endforeach
|
||||||
@ -141,6 +143,8 @@
|
|||||||
'viewButton',
|
'viewButton',
|
||||||
'paymentLink',
|
'paymentLink',
|
||||||
'paymentButton',
|
'paymentButton',
|
||||||
|
'approveLink',
|
||||||
|
'approveButton',
|
||||||
'portalLink',
|
'portalLink',
|
||||||
'portalButton',
|
'portalButton',
|
||||||
] as $field)
|
] as $field)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user