resume short list style abstraction for accourse-work and activities (wip)

This commit is contained in:
2021-10-04 17:22:08 +02:00
parent 369a29af48
commit 3a07fa4faf
11 changed files with 160 additions and 128 deletions

View File

@@ -21,9 +21,9 @@ div.new-activity-select-type {
}
}
// exceptions for flex-table in list-records
// exceptions for flex-table
div.activity-list {
div.flex-table {
&.flex-table {
div.item-bloc {
div.item-row.main {
div.item-col {
@@ -86,7 +86,6 @@ div.activity-list {
}
}
}
}
ul.list-content {
list-style-type: none;
@@ -103,6 +102,32 @@ div.activity-list {
margin-top: 1em;
}
}
/// Activities on resume page
h2.badge-title {
span.title_label {
background-color: #668821;
div.duration {
font-size: 70%;
font-weight: 500;
p {
margin-bottom: 0;
text-align: right;
}
}
}
span.title_action {
//text-transform: capitalize !important;
font-weight: 500 !important;
border-left: 20px groove yellowgreen;
&:before {
content: '\f04b';
font-family: ForkAwesome;
color: yellowgreen;
margin: 0 0 0 -1.05em;
}
}
}
}
// exceptions for flex-bloc in concerned-groups
@@ -130,7 +155,6 @@ div.flex-bloc.concerned-groups {
}
}
/// CHILL ENTITY RENDER BOX
.chill-entity {

View File

@@ -1,4 +1,4 @@
<div class="activity-list context-{{ context }}">
<div class="context-{{ context }}">
{% if activities|length == 0 %}
<p class="chill-no-data-statement">
@@ -7,7 +7,7 @@
</p>
{% else %}
<div class="flex-table">
<div class="flex-table activity-list">
{% for activity in activities %}
{% set t = activity.type %}
<div class="item-bloc">
@@ -102,12 +102,8 @@
</li>
<li>
<b>{{ 'location'|trans ~ ': ' }}</b>
Domicile de l'usager
{# TODO {% if activity.location %}{{ activity.location }}{% endif %}
#}
<b>{{ 'location'|trans ~ ': ' }}</b> Domicile de l'usager
{# TODO {% if activity.location %}{{ activity.location }}{% endif %} #}
</li>
{%- if t.reasonsVisible -%}

View File

@@ -0,0 +1,46 @@
<div class="activity-list">
{% for activity in activities | slice(0,5) %}
{% set t = activity.type %}
<a href="{{ path('chill_activity_activity_show', { 'id': activity.id, 'person_id': person_id, 'accompanying_period_id': accompanying_course_id }) }}"></a>
<h2 class="badge-title">
<span class="title_label">
{% if activity.date %}
<h3>{{ activity.date|format_date('short') }}</h3>
{% endif %}
<div class="duration">
{% if activity.durationTime and t.durationTimeVisible %}
<p>
<abbr class="fa fa-fw fa-hourglass-end" title="{{ 'Duration Time'|trans }}"></abbr>
{{ activity.durationTime|date('H:i') }}
</p>
{% endif %}
{% if activity.travelTime and t.travelTimeVisible %}
<p>
<abbr class="fa fa-fw fa-car" title="{{ 'Travel time'|trans }}"></abbr>
{{ activity.travelTime|date('H:i') }}
</p>
{% endif %}
</div>
</span>
<span class="title_action">
{{ activity.type.name | localize_translatable_string }}
<ul class="small_in_title">
<li>
<abbr title="{{ 'location'|trans }}">{{ 'location'|trans ~ ': ' }}</abbr>
{# TODO {% if activity.location %}{{ activity.location }}{% endif %} #}
Domicile de l'usager
</li>
{% if activity.user and t.userVisible %}
<li>
<abbr title="{{ 'Referrer'|trans }}">{{ 'Referrer'|trans ~ ': ' }}</abbr>
{{ activity.user.usernameCanonical }}
</li>
{% endif %}
</ul>
</span>
</h2>
{% endfor %}
</div>

View File

@@ -73,7 +73,7 @@
{% endif %}
{% if t.travelTimeVisible %}
<dt class="inline">{{ 'Travel Time'|trans }}</dt>
<dt class="inline">{{ 'Travel time'|trans }}</dt>
<dd>{% if entity.travelTime is not null %}
{{ entity.travelTime|date('H:i') }}
{% else %}