Add the publiees scope on Procedure
This commit is contained in:
parent
ab9cf1c351
commit
fc2540649f
9 changed files with 13 additions and 12 deletions
|
@ -6,7 +6,7 @@ class Admin::ProceduresController < AdminController
|
|||
|
||||
def index
|
||||
@procedures = smart_listing_create :procedures,
|
||||
current_administrateur.procedures.published.not_archived.order(created_at: :desc),
|
||||
current_administrateur.procedures.publiees.order(created_at: :desc),
|
||||
partial: "admin/procedures/list",
|
||||
array: true
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@ class DemoController < ApplicationController
|
|||
return redirect_to root_path if Rails.env.production?
|
||||
|
||||
smart_listing_create :procedures,
|
||||
Procedure.published.not_archived.order("id DESC"),
|
||||
Procedure.publiees.order("id DESC"),
|
||||
partial: "demo/list",
|
||||
array: true
|
||||
end
|
||||
|
|
|
@ -60,7 +60,7 @@ class Users::DossiersController < UsersController
|
|||
end
|
||||
|
||||
def new
|
||||
procedure = Procedure.not_archived.published.find(params[:procedure_id])
|
||||
procedure = Procedure.publiees.find(params[:procedure_id])
|
||||
|
||||
dossier = Dossier.create(procedure: procedure, user: current_user, state: 'draft')
|
||||
siret = params[:siret] || current_user.siret
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue