Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Chill-project
Chill-Report
Commits
7d19b4d8
Commit
7d19b4d8
authored
Dec 09, 2016
by
Julien Fastré
Browse files
improve layout of list when no report
parent
8ebacb22
Pipeline
#10044
failed with stages
in 3 minutes and 38 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Resources/translations/messages.fr.yml
View file @
7d19b4d8
...
...
@@ -18,6 +18,7 @@ User: Utilisateur
Report data
:
Données du rapport
'
Report
view
:
%name%'
:
'
Rapport
:
%name%'
Report
:
Rapport
No report registered for this person.
:
Aucun rapport pour cette personne.
#Flash messages
'
Success
:
report
created!'
:
"
Succès
:
le
rapport
a
bien
été
créé
!"
...
...
Resources/views/Report/list.html.twig
View file @
7d19b4d8
...
...
@@ -21,27 +21,35 @@
{%
block
title
%}{{
'Report list'
|
trans
}}{%
endblock
title
%}
{%
block
personcontent
%}
<h1>
{{
'Report list'
|
trans
}}
</h1>
{%
if
reports
|
length
==
0
%}
<p
style=
"text-align:center;"
>
<span
class=
"chill-no-data-statement"
>
{{
"No report registered for this person."
|
trans
}}
</span>
<a
href=
"
{{
path
(
'report_select_type'
,
{
'person_id'
:
person.id
}
)
}}
"
>
{{
'Create a new report'
|
trans
}}
</a>
</p>
{%
else
%}
<table
class=
""
style=
"width:100%"
>
<thead>
<tr>
<th
class=
"chill-red"
>
{{
'Date'
|
trans
}}
</th>
<th
class=
"chill-green"
>
{{
'Report type'
|
trans
}}
</th>
<th
class=
"chill-orange"
>
{{
'Circle'
|
trans
}}
</th>
<th></th>
<th></th>
<th>
{{
'Actions'
|
trans
}}
</th>
</tr>
</thead>
<tbody>
{%
for
report
in
reports
%}
<tr>
<td>
{%
if
report.date
%}{{
report.date
|
localizeddate
(
'long'
,
'none'
)
}}{%
endif
%}
</td>
<td>
{{
report.cFGroup.getName
(
app.request.locale
)
}}
</td>
<td>
{{
report.cFGroup.getName
|
localize_translatable_string
}}
</td>
<td>
{{
report.scope.name
|
localize_translatable_string
}}
</td>
<td>
<ul
class=
"record_actions"
>
{%
if
is_granted
(
'CHILL_REPORT_SEE'
,
report
)
%}
<li>
<a
href=
"
{{
path
(
'report_view'
,
{
'person_id'
:
report.person.id
,
'report_id'
:
report.id
}
)
}}
"
class=
"sc-button b
lack
"
>
{{
'View the report'
|
trans
|
capitalize
}}
</a>
<a
href=
"
{{
path
(
'report_view'
,
{
'person_id'
:
report.person.id
,
'report_id'
:
report.id
}
)
}}
"
class=
"sc-button b
t-view
"
>
{{
'View the report'
|
trans
|
capitalize
}}
</a>
</li>
{%
endif
%}
{%
if
is_granted
(
'CHILL_REPORT_UPDATE'
,
report
)
%}
...
...
@@ -55,4 +63,16 @@
{%
endfor
%}
</tbody>
</table>
{%
endif
%}
<ul
class=
"record_actions"
>
<li>
<a
href=
"
{{
path
(
'report_select_type'
,
{
'person_id'
:
person.id
}
)
}}
"
class=
"sc-button bt-new"
>
<i
class=
"fa fa-plus"
></i>
{{
'Create a new report'
|
trans
}}
</a>
</li>
</ul>
{%
endblock
%}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment