address: add a new address to a person

This commit is contained in:
nobohan
2021-06-15 07:49:35 +02:00
parent c378f59f5a
commit 7c26f0a56c
9 changed files with 181 additions and 50 deletions

View File

@@ -22,36 +22,6 @@
{% block personcontent %}
<h1>{{ 'New address for %name%'|trans({ '%name%': person.firstName ~ ' ' ~ person.lastName } ) }}</h1>
{{ form_start(form) }}
{{ form_row(form.isNoAddress) }}
{{ form_row(form.street) }}
{{ form_errors(form.street) }}
{{ form_row(form.streetNumber) }}
{{ form_errors(form.streetNumber) }}
{{ form_row(form.postCode) }}
{{ form_errors(form.postCode) }}
{{ form_row(form.validFrom) }}
{{ form_errors(form.validFrom) }}
<ul class="record_actions sticky-form-buttons">
<li class="cancel">
<a href="{{ path('chill_person_address_list', { 'person_id' : person.id } ) }}" class="sc-button bt-cancel">
{{ 'Back to the list'|trans }}
</a>
</li>
<li>
{{ form_row(form.submit, { 'attr' : { 'class': 'sc-button bt-create' }, 'label': 'Create' } ) }}
</li>
</ul>
{{ form_end(form) }}
NEW FORM
{% block content %}
<h1>{{ block('title') }}</h1>
<div id="address"></div>
@@ -62,6 +32,10 @@
{% endblock %}
{% block js %}
<script type="text/javascript">
window.personId = {{ person.id|e('js') }};
window.vueRootComponent = 'app';
</script>
{{ encore_entry_script_tags('address') }}
{% endblock %}