feat: ✨ you can now edit the sent accounting date even when the date is present if you are admin

This commit is contained in:
Nicolas Demangeat 2025-04-23 11:12:41 +02:00
parent 770cb043c4
commit e595c7e145

View file

@ -74,6 +74,19 @@
'helper' => __('Doît être une date réelle et existante.'),
])
@elseif ($invoiceModel->sent_accounting_date)
@can('isAdmin')
@include('bo.partials.inputs.date', [
'id' => 'invoiceSentaccountingdate',
'label' => __('Date d\'envoi du :model à la comptabilité', [
'model' => __('models.classes.invoices'),
]),
'name' => 'sent_accounting_date',
'defaultValue' => false,
'required' => true,
'model' => $invoiceModel ?? null,
'helper' => __('Doît être une date réelle et existante.'),
])
@endcan
<p class="fw-bold m-0 text-center">
{{ __('Envoyé à la comptabilité le :date', ['date' => \Carbon\Carbon::parse($invoiceModel->sent_accounting_date)->format('d/m/Y') ?? 'xxx']) }}
</p>