suite
This commit is contained in:
parent
99dbfb9c55
commit
2f146e9980
@ -73,6 +73,8 @@ class Admin::MOdrFilesController < ApplicationController
|
||||
if @m_odr_file.update_attributes(params.require(:m_odr_file).permit!)
|
||||
|
||||
@m_odr_file.m_odr_rep.change_state("En cours de traitement")
|
||||
|
||||
redirect_to [:admin, @m_odr_rep]
|
||||
|
||||
else
|
||||
render action: "edit"
|
||||
|
@ -1,8 +1,10 @@
|
||||
=semantic_form_for [:admin, @m_odr_file], :remote => true do |f|
|
||||
=semantic_form_for [:admin, @m_odr_file], :remote => false, :multipart => true do |f|
|
||||
-if current_admin.id == 1
|
||||
=debug f.object.errors.messages
|
||||
.content
|
||||
=f.inputs do
|
||||
= f.input :file, :label => "Fichier :"
|
||||
|
||||
= f.input :admin_ok, :label => "Décision :", :collection => [["Validé",true], ["Refusé", false]], :as => :select
|
||||
= f.input :reject_reason, :label => "Motif du rejet :", :collection => ["Mauvais document","Mauvaise qualité rendant le fichier illisible"]
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user