diff --git a/templates/profile/header.html.twig b/templates/profile/header.html.twig index 46bba95524..a2fc02eb49 100644 --- a/templates/profile/header.html.twig +++ b/templates/profile/header.html.twig @@ -24,70 +24,72 @@
-
-
- {% if use_lightbox is defined %} - - {{ 'profile.picture.title'| trans }} - - {% else %} - - {{ 'profile.picture.title'| trans }} - - {% endif %} +
+
+
+ {% if use_lightbox is defined %} + + {{ 'profile.picture.title'| trans }} + + {% else %} + + {{ 'profile.picture.title'| trans }} + + {% endif %} +
+ + {% if member.Name != ''%}

{{ member.Name }}

{% endif %} + {% set city = member.city %} +
{{ member.city.name }} + {%- if city.admin1 != null -%} + , {{ city.admin1.name }} + {%- endif -%} + , {{ city.country.name }} +
+ {% if status_form is defined and not status_form is null %} + {{ form_start(status_form, {'attr': {'class': 'u-grid u-grid-cols-2 u-gap-8'}}) }} + {{ form_widget(status_form.status) }} + + {{ form_end(status_form) }} + {% endif %}
+
+
+ {% if memberfields.Occupation is defined and memberfields.Occupation != null %} +

{{ memberfields.Occupation }}

+ {% endif %} - {% if member.Name != ''%}

{{ member.Name }}

{% endif %} - {% set city = member.city %} -
{{ member.city.name }} - {%- if city.admin1 != null -%} - , {{ city.admin1.name }} +

+ {%- if member.HideBirthDate == 'No' -%} + {{ 'profile.age'|trans }} {{ member.age }} {%- endif -%} - , {{ city.country.name }} -

- {% if status_form is defined and not status_form is null %} - {{ form_start(status_form, {'attr': {'class': 'u-grid u-grid-cols-2 u-gap-8'}}) }} - {{ form_widget(status_form.status) }} - - {{ form_end(status_form) }} - {% endif %} + {%- if member.HideBirthDate == 'No' and member.HideGender == 'No' -%}, {%- endif %} + {%- if member.HideBirthDate == 'Yes' and member.HideGender == 'No' -%}{{ 'profile.gender'|trans }} {%- endif %} + {% if member.HideGender == 'No' %} + {{ member.gender|trans }} + {%- endif -%} +
{{ 'profile.joined'|trans }} + {% set difference = date(member.created).diff(date()) %} + {% if difference.days <= 7 %} + {{ 'lastloginprivacy'| trans }} + {% else %} + {{ member.created.diffForHumans }} + {% endif %} + {% if member.hasRight('SafetyTeam') %} ({{ member.created|format_datetime() }}){% endif %} +
{{ 'profile.last.activity'|trans }} + {% set lastLogin = (member.lastLogin == null) ? member.created : member.lastLogin %} + {% set difference = date(lastLogin).diff(date()) %} + {% if difference.days <= 7 %} + {{ 'lastloginprivacy'| trans }} + {% else %} + {{ lastLogin.diffForHumans }} + {% endif %} + {% if member.hasRight('SafetyTeam') %} ({{ lastLogin|format_datetime() }}){% endif %} +

-
- {% if memberfields.Occupation is defined and memberfields.Occupation != null %} -

{{ memberfields.Occupation }}

- {% endif %} - -

- {%- if member.HideBirthDate == 'No' -%} - {{ 'profile.age'|trans }} {{ member.age }} - {%- endif -%} - {%- if member.HideBirthDate == 'No' and member.HideGender == 'No' -%}, {%- endif %} - {%- if member.HideBirthDate == 'Yes' and member.HideGender == 'No' -%}{{ 'profile.gender'|trans }} {%- endif %} - {% if member.HideGender == 'No' %} - {{ member.gender|trans }} - {%- endif -%} -
{{ 'profile.joined'|trans }} - {% set difference = date(member.created).diff(date()) %} - {% if difference.days <= 7 %} - {{ 'lastloginprivacy'| trans }} - {% else %} - {{ member.created.diffForHumans }} - {% endif %} - {% if member.hasRight('SafetyTeam') %} ({{ member.created|format_datetime() }}){% endif %} -
{{ 'profile.last.activity'|trans }} - {% set lastLogin = (member.lastLogin == null) ? member.created : member.lastLogin %} - {% set difference = date(lastLogin).diff(date()) %} - {% if difference.days <= 7 %} - {{ 'lastloginprivacy'| trans }} - {% else %} - {{ lastLogin.diffForHumans }} - {% endif %} - {% if member.hasRight('SafetyTeam') %} ({{ lastLogin|format_datetime() }}){% endif %} -

-