Merge branch 'akaunting:master' into master
This commit is contained in:
@ -14,7 +14,7 @@
|
||||
<x-documents.show.message type="recurring" background-color="bg-blue-100" text-color="text-blue-600" message="{{ $recurring_message }}" />
|
||||
@endif
|
||||
|
||||
@if (($parent = $document->parent))
|
||||
@if ($parent = $document->parent)
|
||||
@php
|
||||
$recurring_message = trans('recurring.message_parent', [
|
||||
'type' => mb_strtolower(trans_choice($textRecurringType, 1)),
|
||||
|
@ -1,11 +1,11 @@
|
||||
<akaunting-recurring
|
||||
start-text="{!! trans('recurring.limit_date', ['type' => \Str::replace('-recurring', '', $type)]) !!}"
|
||||
start-text="{!! trans('recurring.limit_date', ['type' => Str::replace('-recurring', '', $type)]) !!}"
|
||||
:date-range-text="{{ json_encode(trans('general.date_range')) }}"
|
||||
middleText="{!! trans('recurring.limit_middle') !!}"
|
||||
endText="{{ Str::plural($type) }}"
|
||||
end-text="{{ Str::plural(Str::replace('-recurring', '', $type)) }}"
|
||||
|
||||
:frequencies="{{ json_encode($frequencies) }}"
|
||||
frequency-text="{!! trans('recurring.frequency_type', ['type' => \Str::replace('-recurring', '', $type)]) !!}"
|
||||
frequency-text="{!! trans('recurring.frequency_type', ['type' => Str::replace('-recurring', '', $type)]) !!}"
|
||||
frequency-every-text="{!! trans('recurring.every') !!}"
|
||||
frequency-value="{{ $frequency }}"
|
||||
:frequency-error="form.errors.get('recurring_frequency')"
|
||||
|
@ -8,4 +8,16 @@
|
||||
@endcan
|
||||
@endif
|
||||
|
||||
@stack('add_new_button_end')
|
||||
@stack('edit_button_start')
|
||||
|
||||
@if (! $transaction->hasTransferRelation)
|
||||
@if (! $hideButtonEdit)
|
||||
@can($permissionUpdate)
|
||||
<x-link href="{{ route($routeButtonEdit, [$transaction->id, 'type' => $type]) }}">
|
||||
{{ trans('general.edit') }}
|
||||
</x-link>
|
||||
@endcan
|
||||
@endif
|
||||
@endif
|
||||
|
||||
@stack('edit_button_end')
|
||||
|
@ -14,11 +14,11 @@
|
||||
<x-documents.show.message type="recurring" background-color="bg-blue-100" text-color="text-blue-600" message="{{ $recurring_message }}" />
|
||||
@endif
|
||||
|
||||
@if (($parent = $transaction->parent))
|
||||
@if ($parent = $transaction->parent)
|
||||
@php
|
||||
$recurring_message = trans('recurring.message_parent', [
|
||||
'type' => mb_strtolower(trans_choice($textRecurringType, 1)),
|
||||
'link' => '<a href="' . route(mb_strtolower(trans_choice($textRecurringType, 2)) . '.show', $parent->id) . '"><u>' . $parent->document_number . '</u></a>'
|
||||
'link' => '<a href="' . route(config('type.transaction.' . $transaction->parent->type . '.route.prefix') . '.show', $parent->id) . '"><u>' . $parent->number . '</u></a>'
|
||||
]);
|
||||
@endphp
|
||||
|
||||
|
@ -6,20 +6,6 @@
|
||||
<span class="material-icons">more_horiz</span>
|
||||
</x-slot>
|
||||
|
||||
@stack('edit_button_start')
|
||||
|
||||
@if (! $transaction->hasTransferRelation)
|
||||
@if (! $hideButtonEdit)
|
||||
@can($permissionUpdate)
|
||||
<x-dropdown.link href="{{ route($routeButtonEdit, [$transaction->id, 'type' => $type]) }}">
|
||||
{{ trans('general.edit') }}
|
||||
</x-dropdown.link>
|
||||
@endcan
|
||||
@endif
|
||||
@endif
|
||||
|
||||
@stack('edit_button_end')
|
||||
|
||||
@stack('duplicate_button_start')
|
||||
|
||||
@if (! $transaction->hasTransferRelation)
|
||||
@ -36,18 +22,16 @@
|
||||
|
||||
@stack('connect_button_start')
|
||||
|
||||
@if ($transaction->is_splittable && empty($transaction->document_id))
|
||||
@if ($transaction->is_splittable && empty($transaction->document_id) && empty($transaction->recurring))
|
||||
@if (! $hideButtonConnect)
|
||||
@can($permissionCreate)
|
||||
@if ($type == 'income' && $transaction->contact->exists)
|
||||
<button type="button" class="w-full flex items-center text-purple px-2 h-9 leading-9 whitespace-nowrap" title="{{ trans('general.connect') }}" @click="onConnect({{ $transaction->load('account')->toJson() }}, {{ $transaction->currency->toJson() }}, {{ $transaction->contact->invoices()->notPaid()->where('currency_code', $transaction->currency_code)->with(['media', 'totals', 'transactions'])->get()->toJson() }})"><span class="w-full h-full flex items-center rounded-md px-2 text-sm hover:bg-lilac-100">{{ trans('general.connect') }}</span></button>
|
||||
@elseif ($type == 'income' && ! $transaction->contact->exists)
|
||||
<button type="button" class="w-full flex items-center text-purple px-2 h-9 leading-9 whitespace-nowrap" title="{{ trans('general.connect') }}" @click="onConnect({{ $transaction->load('account')->toJson() }}, {{ $transaction->currency->toJson() }}, {{ App\Models\Document\Document::invoice()->notPaid()->where('currency_code', $transaction->currency_code)->with(['media', 'totals', 'transactions'])->get()->toJson() }})"><span class="w-full h-full flex items-center rounded-md px-2 text-sm hover:bg-lilac-100">{{ trans('general.connect') }}</span></button>
|
||||
@elseif ($type == 'expense' && $transaction->contact->exists)
|
||||
<button type="button" class="w-full flex items-center text-purple px-2 h-9 leading-9 whitespace-nowrap" title="{{ trans('general.connect') }}" @click="onConnect({{ $transaction->load('account')->toJson() }}, {{ $transaction->currency->toJson() }}, {{ $transaction->contact->bills()->notPaid()->where('currency_code', $transaction->currency_code)->with(['media', 'totals', 'transactions'])->get()->toJson() }})"><span class="w-full h-full flex items-center rounded-md px-2 text-sm hover:bg-lilac-100">{{ trans('general.connect') }}</span></button>
|
||||
@elseif ($type == 'expense' && ! $transaction->contact->exists)
|
||||
<button type="button" class="w-full flex items-center text-purple px-2 h-9 leading-9 whitespace-nowrap" title="{{ trans('general.connect') }}" @click="onConnect({{ $transaction->load('account')->toJson() }}, {{ $transaction->currency->toJson() }}, {{ App\Models\Document\Document::bill()->notPaid()->where('currency_code', $transaction->currency_code)->with(['media', 'totals', 'transactions'])->get()->toJson() }})"><span class="w-full h-full flex items-center rounded-md px-2 text-sm hover:bg-lilac-100">{{ trans('general.connect') }}</span></button>
|
||||
@endif
|
||||
<button
|
||||
type="button"
|
||||
class="w-full flex items-center text-purple px-2 h-9 leading-9 whitespace-nowrap"
|
||||
title="{{ trans('general.connect') }}"
|
||||
@click="onConnect('{{ route('transactions.dial', $transaction->id) }}')">
|
||||
<span class="w-full h-full flex items-center rounded-md px-2 text-sm hover:bg-lilac-100">{{ trans('general.connect') }}</span>
|
||||
</button>
|
||||
@endcan
|
||||
@endif
|
||||
@endif
|
||||
|
Reference in New Issue
Block a user