Files
ember-panda/app/templates/components/user-main-statistics1.emblem
T

42 lines
1.5 KiB
Plaintext

if user.email
/.ui.horizontal.divider= user.nickname
span.ui.segment.pull-right= user.nickname
if statistics
ui-checkbox class='toggle' label=(t 'user.statistics1.project_specific.label') checked=project_specific onChange=(action (mut project_specific))
'
if project_specific
each-in statistics as |project_id stats|
if (can 'read' 'model' 'panda/project-instance')
.ui.header
= link-to 'project.show' project_id
= stats.project.name
else
.ui.header= stats.project.name
= each stats.states as |stat|
if (can 'read' 'model' 'panda/project-instance')
= link-to 'project.show.project-instance-action' project_id (query-params state=stat.state)
= state-badge stat.state
'
span.between-brackets= stat.count
else
= state-badge stat.state
'
span.between-brackets= stat.count
else
/.ui.header= t 'user.statistics1.global.title'
each-in statistics as |state count|
if (can 'read' 'model' 'panda/project-instance')
= link-to 'action-list' (query-params state=state)
= state-badge state
'
span.between-brackets= count
else
= state-badge state
'
span.between-brackets= count
= yield
else
.ui.active.inline.centered.loader
else
.ui.active.inline.centered.loader