feat(admin): card link to sva/svr configuration
This commit is contained in:
parent
bb4a6e22ce
commit
7a8b83cfc9
6 changed files with 34 additions and 0 deletions
7
app/components/procedure/card/sva_svr_component.rb
Normal file
7
app/components/procedure/card/sva_svr_component.rb
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
# frozen_string_literal: true
|
||||||
|
|
||||||
|
class Procedure::Card::SVASVRComponent < ApplicationComponent
|
||||||
|
def initialize(procedure:)
|
||||||
|
@procedure = procedure
|
||||||
|
end
|
||||||
|
end
|
|
@ -0,0 +1,4 @@
|
||||||
|
---
|
||||||
|
en:
|
||||||
|
ready: "Configuré"
|
||||||
|
needs_configuration: "À configurer"
|
|
@ -0,0 +1,6 @@
|
||||||
|
---
|
||||||
|
fr:
|
||||||
|
title: "Silence Vaut Accord"
|
||||||
|
subtitle: "Accepter ou Refuser un dossier après un délai"
|
||||||
|
ready: "Configuré"
|
||||||
|
needs_configuration: "À configurer"
|
|
@ -0,0 +1,14 @@
|
||||||
|
.fr-col-6.fr-col-md-4.fr-col-lg-3
|
||||||
|
= link_to edit_admin_procedure_sva_svr_path(@procedure), class: 'fr-tile fr-enlarge-link', id: 'sva' do
|
||||||
|
.fr-tile__body.flex.justify-between
|
||||||
|
- if @procedure.sva_svr_enabled?
|
||||||
|
%div
|
||||||
|
%span.icon.accept
|
||||||
|
%p.fr-tile-status-accept= t('.ready')
|
||||||
|
- else
|
||||||
|
%div
|
||||||
|
%span.icon.clock
|
||||||
|
%p.fr-tile-status-todo= t('.needs_configuration')
|
||||||
|
%h3.fr-h6.fr-mt-10v= t('.title')
|
||||||
|
%p.fr-tile-subtitle= t('.subtitle')
|
||||||
|
%p.fr-btn.fr-btn--tertiary= t('views.shared.actions.edit')
|
|
@ -63,5 +63,6 @@
|
||||||
= render Procedure::Card::AnnotationsComponent.new(procedure: @procedure)
|
= render Procedure::Card::AnnotationsComponent.new(procedure: @procedure)
|
||||||
= render Procedure::Card::APIEntrepriseComponent.new(procedure: @procedure)
|
= render Procedure::Card::APIEntrepriseComponent.new(procedure: @procedure)
|
||||||
= render Procedure::Card::APIParticulierComponent.new(procedure: @procedure)
|
= render Procedure::Card::APIParticulierComponent.new(procedure: @procedure)
|
||||||
|
= render Procedure::Card::SVASVRComponent.new(procedure: @procedure)
|
||||||
= render Procedure::Card::MonAvisComponent.new(procedure: @procedure)
|
= render Procedure::Card::MonAvisComponent.new(procedure: @procedure)
|
||||||
= render Procedure::Card::DossierSubmittedMessageComponent.new(procedure: @procedure)
|
= render Procedure::Card::DossierSubmittedMessageComponent.new(procedure: @procedure)
|
||||||
|
|
|
@ -573,6 +573,8 @@ Rails.application.routes.draw do
|
||||||
resource :dossier_submitted_message, only: [:edit, :update, :create]
|
resource :dossier_submitted_message, only: [:edit, :update, :create]
|
||||||
# ADDED TO ACCESS IT FROM THE IFRAME
|
# ADDED TO ACCESS IT FROM THE IFRAME
|
||||||
get 'attestation_template/preview' => 'attestation_templates#preview'
|
get 'attestation_template/preview' => 'attestation_templates#preview'
|
||||||
|
|
||||||
|
resource :sva_svr, only: [:show, :edit, :update], controller: 'sva_svr'
|
||||||
end
|
end
|
||||||
|
|
||||||
resources :services, except: [:show] do
|
resources :services, except: [:show] do
|
||||||
|
|
Loading…
Reference in a new issue