wip: implement invoice generator for teamers
This commit is contained in:
1 parent
6c608063ad
commit
bbdd887dc2
25 files changed
+1584
-21
No files matched your search
@@ -95,28 +95,36 @@
|
||||
|
||||
{# New invoice #}
|
||||
{% if workflow_can(disposition, 'upload_invoice') %}
|
||||
{% set formAttr = stimulus_controller('form-upload-guard')|stimulus_action('form-upload-guard', 'guard', 'submit') %}
|
||||
{{ form_start(form, { 'attr': formAttr.toArray() }) }}
|
||||
<div class="flex flex-col space-y-4">
|
||||
<a href="{{ path('app_teamer_disposition_invoicepdf', { 'uuid': disposition.uuid }) }}" target="_blank" class="inline-block">
|
||||
<img src="{{ asset('build/images/invoice_thumb.jpg') }}" alt="Honorarnote" class="block w-32 h-auto shadow-md">
|
||||
</a>
|
||||
<div>
|
||||
Bitte lade sie ausgefüllt und unterschrieben hier wieder hoch:
|
||||
{% if invoice_editor_enabled %}
|
||||
<div
|
||||
hx-get="{{ path('app_teamer_disposition_invoice_editor', { 'uuid': disposition.uuid }) }}"
|
||||
hx-trigger="load"
|
||||
hx-target="this"
|
||||
hx-swap="innerHTML"
|
||||
>
|
||||
{% include '_partials/_spinner.html.twig' with { 'class': 'w-8 h-8' } %}
|
||||
</div>
|
||||
{% include '_partials/_upload_collection_form.html.twig' with {
|
||||
'endpoint_upload': path('_uploader_upload_invoice'),
|
||||
'accepted_files': 'image/jpg,image/jpeg,application/pdf',
|
||||
} %}
|
||||
{% if form.confirmInvoiceData is defined %}
|
||||
{{ form_row(form.confirmInvoiceData) }}
|
||||
{% endif %}
|
||||
<button type="submit" class="btn" {{ stimulus_target('form-upload-guard', 'submit') }}>
|
||||
Aktualisieren
|
||||
</button>
|
||||
</div>
|
||||
{{ form_rest(form) }}
|
||||
{{ form_end(form) }}
|
||||
{% else %}
|
||||
{% set formAttr = stimulus_controller('form-upload-guard')|stimulus_action('form-upload-guard', 'guard', 'submit') %}
|
||||
{{ form_start(form, { 'attr': formAttr.toArray() }) }}
|
||||
<div class="flex flex-col space-y-4">
|
||||
<a href="{{ path('app_teamer_disposition_invoicepdf', { 'uuid': disposition.uuid }) }}" target="_blank" class="inline-block">
|
||||
<img src="{{ asset('build/images/invoice_thumb.jpg') }}" alt="Honorarnote" class="block w-32 h-auto shadow-md">
|
||||
</a>
|
||||
<div>
|
||||
Bitte lade sie ausgefüllt und unterschrieben hier wieder hoch:
|
||||
</div>
|
||||
{% include '_partials/_upload_collection_form.html.twig' with {
|
||||
'endpoint_upload': path('_uploader_upload_invoice'),
|
||||
'accepted_files': 'image/jpg,image/jpeg,application/pdf',
|
||||
} %}
|
||||
<button type="submit" class="btn" {{ stimulus_target('form-upload-guard', 'submit') }}>
|
||||
Aktualisieren
|
||||
</button>
|
||||
</div>
|
||||
{{ form_rest(form) }}
|
||||
{{ form_end(form) }}
|
||||
{% endif %}
|
||||
{% else %}
|
||||
{% for blocker in workflow_transition_blockers(disposition, 'upload_invoice') %}
|
||||
<twig:MessageBox message="{{ blocker.message }}"/>
|
||||
|
||||
Reference in new issue
Block a user