diff --git a/src/Bundle/ChillPersonBundle/Resources/public/sass/chillperson.scss b/src/Bundle/ChillPersonBundle/Resources/public/sass/chillperson.scss index 4876f248e..862ddef91 100644 --- a/src/Bundle/ChillPersonBundle/Resources/public/sass/chillperson.scss +++ b/src/Bundle/ChillPersonBundle/Resources/public/sass/chillperson.scss @@ -130,89 +130,87 @@ div#header-household-details { } } -div.household__address, -div.person__address { - div.row { - height: 100px; - width: 100%; +/* +* ADDRESS HISTORY +* context person / household +*/ +div.timeline.grid { + display: grid; + grid-template-rows: auto auto auto; + grid-template-columns: auto 120px auto; + + @media only screen and (max-width: 750px) { + grid-template-columns: auto 1em auto; + } + + div.top { + grid-column: 2; + text-align: center; + color: lightgrey; + margin-bottom: -20px; + } + div.col-a { + grid-column: 1; + text-align: right; + } + div.col-b, + div.date { + grid-column: 2; position: relative; - - & > div { + &:after { position: absolute; - display: table; + content: ''; + top: 0; bottom: 0; + left: 50%; + margin: auto -5px; + width: 10px; height: 100%; - border: 1px dotted #c3c3c3; + background-color: lightgrey; + z-index: -5; } + } + div.col-c { + grid-column: 3; + } - div.household__address--date, - div.person__address--date { - width: 30%; - background-color: #c3c3c3; - height: 100%; - - div.cell { - box-sizing: border-box; - position: relative; - height: 100%; - width: 100%; - margin-left: 50%; - - div.pill { - position: absolute; - box-sizing: border-box; - width: 120px; - height: 40px; - bottom: -20px; - background-color: white; - padding: 10px; - border-radius: 30px; - left: -60px; - text-align: center; - z-index: 10; - } - } + div.col-b, + div.action, + div.content { + min-height: 30px; + padding: 1em; + } + div.content { + box-shadow: + 1px 0 0 0 #000, + 0 1px 0 0 #000, + 1px 1px 0 0 #000, + 1px 0 0 0 #000 inset, + 0 1px 0 0 #000 inset; + + div.address { + font-variant: small-caps; } - - div.household__address--content, - div.person__address--content { - width: 70%; - left: 30%; - text-align: left; - background-color: #ececec; - border: 1px solid #888; - - div.cell { - display: table-cell; - padding: 5px 30px; - vertical-align: middle; - - & > div { - display: flex; - justify-content: space-between; - } - - i.dot::after, - i.dot::before { - position: absolute; - width: 20px; - height: 20px; - content: ''; - border: 0; - background-color: white; - border-radius: 50%; - border: 5px solid #c3c3c3; - z-index: 10; - left: -15px; - bottom: -15px; - } - } + } + div.date { + text-align: center; + background-color: lightgrey; + padding: 0.5em; + border-radius: 0.3em; + } + + div.span2 { grid-row: span 3; } + div.span3 { grid-row: span 5; } + div.span4 { grid-row: span 7; } + div.span5 { grid-row: span 9; } + + ul.record_actions { + margin: 0; + } + .fake { + &:after { + content: 'fake, just to test.. '; + color: lightgrey; + font-style: italic; } } } - -div.household__address-move { - div.household__address-move__create { - display: flex; - flex-direction: column; - } -} diff --git a/src/Bundle/ChillPersonBundle/Resources/views/Address/list.html.twig b/src/Bundle/ChillPersonBundle/Resources/views/Address/list.html.twig index 698f1e9d0..18fd85e86 100644 --- a/src/Bundle/ChillPersonBundle/Resources/views/Address/list.html.twig +++ b/src/Bundle/ChillPersonBundle/Resources/views/Address/list.html.twig @@ -25,68 +25,84 @@ {% block personcontent %}

{{ 'Addresses\'history for %name%'|trans({ '%name%': person.firstName ~ ' ' ~ person.lastName } ) }}

- -
- -
-
-
-
-
- {% if person.addresses|length == 0 %} - {{ 'No address given'|trans }} - {% endif %} - - {{ 'Add an address'|trans }} - -
-
-
-
- + +
+ + {% if person.addresses|length == 0 %} + {{ 'No address given'|trans }} + {% else %} +
+ {% endif %} + {% for address in person.addresses %} -
-
-
-
- {% if address.validFrom is not empty %} - {{ address.validFrom|format_date('long') }} - {% endif %} -
-
-
-
-
- -
- {% if address.isNoAddress == true %} + + {# if person address #} +
+
+ {% if address.isNoAddress == true %}
{{ 'address.consider homeless'|trans }}
- {% else %} -
- {% if address.street is not empty %} -
- - {{ address.street }} - {% if address.streetNumber is not empty %} - , {{ address.streetNumber }} - {% endif %} -
- {% endif %} - {% if address.postCode is not empty %} -
- {{ address.postCode.code }} {{ address.postCode.name }} - ({{ address.postCode.country.name|localize_translatable_string }}) -
+ {% else %} + + {% if address.street is not empty %} +
+ {{ address.street }} + {% if address.streetNumber is not empty %} + , {{ address.streetNumber }} {% endif %}
{% endif %} - -
+ + {% if address.postCode is not empty %} +
+ {{ address.postCode.code }} {{ address.postCode.name }} + ({{ address.postCode.country.name|localize_translatable_string }}) +
+ {% endif %} + + {% endif %} + +
    +
  • + +
  • +
-
+ {# endif #} + +
+ + {# if household address #}{# +
+
+
+ #}{# endif #} + +
+ {% if address.validFrom is not empty %} + {{ address.validFrom|format_date('long') }} + {% endif %} +
+ {% endfor %} + + {# TEST HOUSEHOLD POSITION + #} +
+
+
+
+ 549, chemin De Sousa + , 45, boulevard Aurore Roux +
+
+ 10850 Nanterre (France) +
+
+
+
+
01 janvier 1970
+
- {% endblock personcontent %} diff --git a/src/Bundle/ChillPersonBundle/Resources/views/Household/addresses.html.twig b/src/Bundle/ChillPersonBundle/Resources/views/Household/addresses.html.twig index fcc21765b..ee05b70f0 100644 --- a/src/Bundle/ChillPersonBundle/Resources/views/Household/addresses.html.twig +++ b/src/Bundle/ChillPersonBundle/Resources/views/Household/addresses.html.twig @@ -4,67 +4,64 @@ {% block content %}

{{ block('title') }}

-
-
+
-
-
-
- +
+
+ - - {% for address in household.addresses %} -
-
-
-
- {% if address.validFrom is not empty %} - {{ address.validFrom|format_date('long') }} - {% endif %} -
-
-
-
-
- -
- {% if address.isNoAddress == true %} -
{{ 'address.consider homeless'|trans }}
- {% else %} -
- {% if address.street is not empty %} -
- - {{ address.street }} - {% if address.streetNumber is not empty %} - , {{ address.streetNumber }} - {% endif %} -
- {% endif %} - {% if address.postCode is not empty %} -
- {{ address.postCode.code }} {{ address.postCode.name }} - ({{ address.postCode.country.name|localize_translatable_string }}) -
- {% endif %} - -
- {% endif %} - -
-
-
-
- {% endfor %}
-
+ {% for address in household.addresses %} +
+
+
+
+ {% if address.validFrom is not empty %} + {{ address.validFrom|format_date('long') }} + {% endif %} +
+
+
+
+
+ +
+ {% if address.isNoAddress == true %} +
{{ 'address.consider homeless'|trans }}
+ {% else %} +
+ {% if address.street is not empty %} +
+ + {{ address.street }} + {% if address.streetNumber is not empty %} + , {{ address.streetNumber }} + {% endif %} +
+ {% endif %} + {% if address.postCode is not empty %} +
+ {{ address.postCode.code }} {{ address.postCode.name }} + ({{ address.postCode.country.name|localize_translatable_string }}) +
+ {% endif %} +
+ {% endif %} + +
+
+
+
+ + {% endfor %} +
{% endblock %}