This commit is contained in:
Sevan Nerse 2021-01-18 14:47:17 +03:00
commit 5e25ae8a2f
5 changed files with 79 additions and 37 deletions

View File

@ -156,7 +156,7 @@ return [
'clear_cache' => 'Clear Cache', 'clear_cache' => 'Clear Cache',
'go_to_dashboard' => 'Go to dashboard', 'go_to_dashboard' => 'Go to dashboard',
'is' => 'is', 'is' => 'is',
'isnot' => 'is not', 'isnot' => 'is not',
'recurring_and_more' => 'Recurring and more..', 'recurring_and_more' => 'Recurring and more..',
'due_on' => 'Due on', 'due_on' => 'Due on',
'amount_due' => 'Amount due', 'amount_due' => 'Amount due',
@ -166,7 +166,7 @@ return [
'number' => 'Card Number', 'number' => 'Card Number',
'expiration_date' => 'Expiration Date', 'expiration_date' => 'Expiration Date',
'cvv' => 'Card CVV', 'cvv' => 'Card CVV',
'store' => 'Store Card', 'save' => 'Save Card',
], ],
'title' => [ 'title' => [

View File

@ -4,7 +4,7 @@
<table class="table" id="totals"> <table class="table" id="totals">
<colgroup> <colgroup>
<col style="width: 50%;"> <col style="width: 50%;">
<col style="width: 35%;"> <col style="width: 30%;">
<col style="width: 25%;"> <col style="width: 25%;">
<col style="width: 40px;"> <col style="width: 40px;">
</colgroup> </colgroup>
@ -12,7 +12,7 @@
@stack('sub_total_td_start') @stack('sub_total_td_start')
<tr id="tr-subtotal"> <tr id="tr-subtotal">
<td class="border-bottom-0 pb-0"></td> <td class="border-bottom-0 pb-0"></td>
<td class="text-right border-right-0 border-bottom-0 align-middle pb-0"> <td class="text-right border-right-0 border-bottom-0 align-middle pb-0 pr-0">
<strong>{{ trans('invoices.sub_total') }}</strong> <strong>{{ trans('invoices.sub_total') }}</strong>
</td> </td>
<td class="text-right border-bottom-0 long-texts pb-0 pr-3"> <td class="text-right border-bottom-0 long-texts pb-0 pr-3">
@ -28,7 +28,7 @@
@stack('item_discount_td_start') @stack('item_discount_td_start')
<tr id="tr-line-discount" v-if="totals.item_discount"> <tr id="tr-line-discount" v-if="totals.item_discount">
<td class="border-top-0 pt-0 pb-0"></td> <td class="border-top-0 pt-0 pb-0"></td>
<td class="text-right border-top-0 border-right-0 border-bottom-0 align-middle pt-0 pb-0"> <td class="text-right border-top-0 border-right-0 border-bottom-0 align-middle pt-0 pb-0 pr-0">
<strong>{{ trans('invoices.item_discount') }}</strong> <strong>{{ trans('invoices.item_discount') }}</strong>
</td> </td>
<td class="text-right border-top-0 border-bottom-0 long-texts pt-0 pb-0 pr-3"> <td class="text-right border-top-0 border-bottom-0 long-texts pt-0 pb-0 pr-3">
@ -45,7 +45,7 @@
@stack('add_discount_td_start') @stack('add_discount_td_start')
<tr id="tr-discount"> <tr id="tr-discount">
<td class="border-top-0 pt-0 pb-0"></td> <td class="border-top-0 pt-0 pb-0"></td>
<td class="text-right border-top-0 border-right-0 border-bottom-0 align-middle pt-0 pb-0"> <td class="text-right border-top-0 border-right-0 border-bottom-0 align-middle pt-0 pb-0 pr-0">
<el-popover <el-popover
popper-class="p-0 h-0" popper-class="p-0 h-0"
placement="bottom" placement="bottom"
@ -101,7 +101,7 @@
<tr v-for="(tax, tax_index) in totals.taxes" <tr v-for="(tax, tax_index) in totals.taxes"
:index="tax_index"> :index="tax_index">
<td class="border-top-0 pt-0 pb-0"></td> <td class="border-top-0 pt-0 pb-0"></td>
<td class="text-right border-top-0 border-right-0 border-bottom-0 align-middle pt-0 pb-0"> <td class="text-right border-top-0 border-right-0 border-bottom-0 align-middle pt-0 pb-0 pr-0">
<strong v-html="tax.name"></strong> <strong v-html="tax.name"></strong>
</td> </td>
<td class="text-right border-top-0 border-bottom-0 long-texts pb-0 pr-3"> <td class="text-right border-top-0 border-bottom-0 long-texts pb-0 pr-3">
@ -116,7 +116,7 @@
@stack('grand_total_td_start') @stack('grand_total_td_start')
<tr id="tr-total"> <tr id="tr-total">
<td class="border-top-0 pt-0 pb-0"></td> <td class="border-top-0 pt-0 pb-0"></td>
<td class="text-right border-top-0 border-right-0 align-middle pt-0 pb-0"> <td class="text-right border-top-0 border-right-0 align-middle pt-0 pb-0 pr-0">
<strong class="document-total-span">{{ trans('invoices.total') }}</strong> <strong class="document-total-span">{{ trans('invoices.total') }}</strong>
{{ Form::selectGroup('currency_code', '', 'exchange-alt', $currencies, setting('default.currency'), ['required' => 'required', 'model' => 'form.currency_code', 'change' => 'onChangeCurrency'], 'document-total-currency') }} {{ Form::selectGroup('currency_code', '', 'exchange-alt', $currencies, setting('default.currency'), ['required' => 'required', 'model' => 'form.currency_code', 'change' => 'onChangeCurrency'], 'document-total-currency') }}
</td> </td>
@ -132,7 +132,7 @@
@stack('currency_conversion_td_start') @stack('currency_conversion_td_start')
<tr id="tr-currency-conversion" class="d-none" :class="[{'d-table-row': (('{{ setting('default.currency') }}' != form.currency_code) && totals.total)}]"> <tr id="tr-currency-conversion" class="d-none" :class="[{'d-table-row': (('{{ setting('default.currency') }}' != form.currency_code) && totals.total)}]">
<td class="border-top-0 pb-0"></td> <td class="border-top-0 pb-0"></td>
<td class="text-right border-top-0 border-right-0 align-middle pb-0 pr-3" colspan="2"> <td class="text-right border-top-0 border-right-0 align-middle pb-0 pr-3 pr-0" colspan="2">
<akaunting-currency-conversion <akaunting-currency-conversion
currency-conversion-text="{{ trans('currencies.conversion') }}" currency-conversion-text="{{ trans('currencies.conversion') }}"
:price="(totals.total / form.currency_rate).toFixed(2)" :price="(totals.total / form.currency_rate).toFixed(2)"

View File

@ -79,7 +79,7 @@
</a> </a>
@else @else
<button type="button" class="btn btn-secondary btn-sm" disabled="disabled"> <button type="button" class="btn btn-secondary btn-sm" disabled="disabled">
<span class="text-disabled">{{ trans($textTimelineSentStatusMarkSent) }}</span> {{ trans($textTimelineSentStatusMarkSent) }}
</button> </button>
@endif @endif
@endcan @endcan
@ -118,9 +118,11 @@
{{ trans($textTimelineSendStatusMail) }} {{ trans($textTimelineSendStatusMail) }}
</a> </a>
@else @else
<button type="button" class="btn btn-white btn-sm green-tooltip" disabled="disabled" data-toggle="tooltip" data-placement="right" title="{{ trans('invoices.messages.email_required') }}"> <el-tooltip content="{{ trans('invoices.messages.email_required') }}" placement="top" effect="danger">
<span class="text-disabled">{{ trans($textTimelineSendStatusMail) }}</span> <button type="button" class="btn btn-danger btn-sm" disabled="disabled">
</button> {{ trans($textTimelineSendStatusMail) }}
</button>
</el-tooltip>
@endif @endif
@endif @endif
@stack('timeline_sent_body_button_email_end') @stack('timeline_sent_body_button_email_end')

View File

@ -7,6 +7,18 @@
<div class="dropdown-menu" role="menu"> <div class="dropdown-menu" role="menu">
@stack('button_dropdown_start') @stack('button_dropdown_start')
@if (in_array($document->status, $hideTimelineStatuses))
@stack('edit_button_start')
@if (!$hideButtonEdit)
@can($permissionUpdate)
<a class="dropdown-item" href="{{ route($routeButtonEdit, $document->id) }}">
{{ trans('general.edit') }}
</a>
@endcan
@endif
@stack('edit_button_end')
@endif
@stack('duplicate_button_start') @stack('duplicate_button_start')
@if (!$hideButtonDuplicate) @if (!$hideButtonDuplicate)
@can($permissionCreate) @can($permissionCreate)
@ -18,9 +30,9 @@
@stack('duplicate_button_end') @stack('duplicate_button_end')
@stack('button_dropdown_divider_1_start') @stack('button_dropdown_divider_1_start')
@if (!$hideButtonGroupDivider1) @if (!$hideButtonGroupDivider1)
<div class="dropdown-divider"></div> <div class="dropdown-divider"></div>
@endif @endif
@stack('button_dropdown_divider_1_end') @stack('button_dropdown_divider_1_end')
@if (!$hideButtonPrint) @if (!$hideButtonPrint)
@ -41,12 +53,40 @@
@endif @endif
@endif @endif
@stack('button_pdf_start') @if (in_array($document->status, $hideTimelineStatuses))
@if (!$hideButtonPdf) @stack('share_button_start')
<a class="dropdown-item" href="{{ route($routeButtonPdf, $document->id) }}"> @if (!$hideButtonShare)
{{ trans('general.download_pdf') }} @if ($document->status != 'cancelled')
</a> <a class="dropdown-item" href="{{ $signedUrl }}" target="_blank">
{{ trans('general.share') }}
</a>
@endif
@endif
@stack('share_button_end')
@stack('edit_button_start')
@if (!$hideButtonEmail)
@if($document->contact_email)
<a class="dropdown-item" href="{{ route($routeButtonEmail, $document->id) }}">
{{ trans($textTimelineSendStatusMail) }}
</a>
@else
<el-tooltip content="{{ trans('invoices.messages.email_required') }}" placement="right" effect="danger">
<button type="button" class="dropdown-item" disabled="disabled">
<span class="text-disabled">{{ trans($textTimelineSendStatusMail) }}</span>
</button>
</el-tooltip>
@endif
@endif
@stack('edit_button_end')
@endif @endif
@stack('button_pdf_start')
@if (!$hideButtonPdf)
<a class="dropdown-item" href="{{ route($routeButtonPdf, $document->id) }}">
{{ trans('general.download_pdf') }}
</a>
@endif
@stack('button_pdf_end') @stack('button_pdf_end')
@if (!$hideButtonCancel) @if (!$hideButtonCancel)
@ -70,9 +110,9 @@
@endif @endif
@stack('button_dropdown_divider_2_start') @stack('button_dropdown_divider_2_start')
@if (!$hideButtonGroupDivider2) @if (!$hideButtonGroupDivider2)
<div class="dropdown-divider"></div> <div class="dropdown-divider"></div>
@endif @endif
@stack('button_dropdown_divider_2_end') @stack('button_dropdown_divider_2_end')
@if (!$hideButtonCustomize) @if (!$hideButtonCustomize)
@ -86,23 +126,23 @@
@endif @endif
@stack('button_dropdown_divider_3_start') @stack('button_dropdown_divider_3_start')
@if (!$hideButtonGroupDivider3) @if (!$hideButtonGroupDivider3)
<div class="dropdown-divider"></div> <div class="dropdown-divider"></div>
@endif @endif
@stack('button_dropdown_divider_3_end') @stack('button_dropdown_divider_3_end')
@stack('delete_button_start') @stack('delete_button_start')
@if (!$hideButtonDelete) @if (!$hideButtonDelete)
@can($permissionDelete) @can($permissionDelete)
@if ($checkButtonReconciled) @if ($checkButtonReconciled)
@if (!$document->reconciled) @if (!$document->reconciled)
{!! Form::deleteLink($document, $routeButtonDelete, $textDeleteModal, 'document_number') !!}
@endif
@else
{!! Form::deleteLink($document, $routeButtonDelete, $textDeleteModal, 'document_number') !!} {!! Form::deleteLink($document, $routeButtonDelete, $textDeleteModal, 'document_number') !!}
@endif @endif
@else @endcan
{!! Form::deleteLink($document, $routeButtonDelete, $textDeleteModal, 'document_number') !!} @endif
@endif
@endcan
@endif
@stack('delete_button_end') @stack('delete_button_end')
@stack('button_dropdown_end') @stack('button_dropdown_end')
</div> </div>

View File

@ -10,7 +10,7 @@
text-year="{{ trans('general.year') }}" text-year="{{ trans('general.year') }}"
text-cvv="{{ trans('general.card.cvv') }}" text-cvv="{{ trans('general.card.cvv') }}"
textButton="{{ trans('general.confirm') }}" textButton="{{ trans('general.confirm') }}"
textStoreCard="{{ trans('general.card.store') }} " textStoreCard="{{ trans('general.card.save') }} "
:store-card="{{ !empty($store_card) ? 'true' : 'false' }}" :store-card="{{ !empty($store_card) ? 'true' : 'false' }}"
:cards="{{ !empty($cards) ? json_encode($cards) : json_encode([]) }}" :cards="{{ !empty($cards) ? json_encode($cards) : json_encode([]) }}"
:form-data="formData" :form-data="formData"