[#10799] Add warning badges when token is expiring
This commit is contained in:
parent
ec2c913ab4
commit
2bf773b0b7
4 changed files with 11 additions and 0 deletions
|
@ -28,6 +28,11 @@
|
|||
- elsif @procedure.locked?
|
||||
= link_to commencer_url(@procedure.path), commencer_url(@procedure.path), class: "fr-link"
|
||||
.flex.fr-mt-1w
|
||||
|
||||
- if @procedure.api_entreprise_token_expired_or_expires_soon?
|
||||
%span.fr-badge.fr-badge--warning.fr-mr-1w
|
||||
= t('to_modify', scope: [:layouts, :breadcrumb])
|
||||
|
||||
%span.fr-badge.fr-badge--success.fr-mr-1w
|
||||
= t('published', scope: [:layouts, :breadcrumb])
|
||||
= t('since', scope: [:layouts, :breadcrumb], number: @procedure.id, date: l(@procedure.published_at.to_date))
|
||||
|
|
|
@ -54,11 +54,15 @@
|
|||
|
||||
.text-right
|
||||
%p.fr-mb-0.width-max-content N° #{number_with_html_delimiter(procedure.id)}
|
||||
|
||||
- if procedure.close? || procedure.depubliee?
|
||||
%span.fr-badge.fr-badge--sm.fr-badge--warning
|
||||
= t('closed', scope: [:layouts, :breadcrumb])
|
||||
|
||||
- elsif procedure.publiee?
|
||||
- if procedure.api_entreprise_token_expired_or_expires_soon?
|
||||
%span.fr-badge.fr-badge--sm.fr-badge--warning
|
||||
= t('to_modify', scope: [:layouts, :breadcrumb])
|
||||
%span.fr-badge.fr-badge--sm.fr-badge--success
|
||||
= t('published', scope: [:layouts, :breadcrumb])
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue