Akaunting/resources/views/components/documents/show/send.blade.php

97 lines
3.9 KiB
PHP
Raw Normal View History

2022-06-01 07:15:55 +00:00
<x-show.accordion type="send" :open="($accordionActive == 'send')">
<x-slot name="head">
<x-show.accordion.head
title="{{ trans('general.send') }}"
description="{!! trans($description, [
2023-10-03 08:06:08 +00:00
'user' => $user_name,
'type' => $type_lowercase,
'date' => $last_sent_date,
2022-06-01 07:15:55 +00:00
]) !!}"
/>
</x-slot>
<x-slot name="body">
2025-01-10 09:58:13 +00:00
@stack('timeline_send_body_start')
2022-06-01 07:15:55 +00:00
<div class="flex flex-wrap space-x-3 rtl:space-x-reverse">
2025-01-10 09:58:13 +00:00
@stack('timeline_send_body_button_email_start')
2022-06-01 07:15:55 +00:00
@if (! $hideEmail)
2023-10-09 12:59:28 +00:00
@if ($document->contact->has_email)
2023-10-03 08:06:08 +00:00
@if ($document->status != 'cancelled')
<x-button id="show-slider-actions-send-email-{{ $document->type }}" kind="secondary" @click="onSendEmail('{{ route($emailRoute, $document->id) }}')">
{{ trans($textEmail) }}
</x-button>
@else
<x-button kind="disabled" disabled="disabled">
{{ trans($textEmail) }}
</x-button>
@endif
2022-06-01 07:15:55 +00:00
@else
<x-tooltip message="{{ trans('invoices.messages.email_required') }}" placement="top">
<x-dropdown.button disabled="disabled">
{{ trans($textEmail) }}
</x-dropdown.button>
</x-tooltip>
@endif
@endif
2025-01-10 09:58:13 +00:00
@stack('timeline_send_body_button_mark_sent_start')
2022-06-01 07:15:55 +00:00
@if (! $hideMarkSent)
@can($permissionUpdate)
@if ($document->status == 'draft')
<x-link id="show-slider-actions-mark-sent-{{ $document->type }}" href="{{ route($markSentRoute, $document->id) }}" @click="e => e.target.classList.add('disabled')">
<x-link.loading>
{{ trans($textMarkSent) }}
</x-link.loading>
2022-06-01 07:15:55 +00:00
</x-link>
@else
2023-10-03 08:06:08 +00:00
<x-button kind="disabled" disabled="disabled">
2022-06-01 07:15:55 +00:00
{{ trans($textMarkSent) }}
</x-button>
@endif
@endcan
@endif
2025-01-10 09:58:13 +00:00
@stack('timeline_send_body_button_cancelled_start')
2022-06-01 07:15:55 +00:00
@if (! $hideShare)
@if ($document->status != 'cancelled')
2022-09-06 10:54:56 +00:00
<x-button id="show-slider-actions-share-link-{{ $document->type }}" @click="onShareLink('{{ route($shareRoute, $document->id) }}')">
2022-06-01 07:15:55 +00:00
{{ trans('general.share_link') }}
</x-button>
@endif
@endif
2023-10-03 08:06:08 +00:00
2025-01-10 09:58:13 +00:00
@stack('timeline_send_body_button_cancelled_end')
@stack('timeline_send_body_history_start')
2023-10-03 08:06:08 +00:00
@if ($histories->count())
<div class="text-xs mt-6" style="margin-left: 0 !important;">
<span class="font-medium">
{{ trans_choice('general.histories', 1) }}:
</span>
@foreach ($histories as $history)
<div class="my-4">
<span>
{{ trans('documents.slider.send', [
'user' => $history->owner->name,
'type' => $type_lowercase,
'date' => company_date($history->created_at),
]) }}
</span>
</div>
@endforeach
</div>
@endif
2025-01-10 09:58:13 +00:00
@stack('timeline_send_body_history_end')
2022-06-01 07:15:55 +00:00
</div>
2025-01-10 09:58:13 +00:00
@stack('timeline_get_paid_body_end')
2022-06-01 07:15:55 +00:00
</x-slot>
</x-show.accordion>