Some fix
This commit is contained in:
parent
2e0c9a793f
commit
7f29387a16
@ -262,6 +262,3 @@ DEPENDENCIES
|
||||
wicked_pdf
|
||||
wkhtmltopdf-binary
|
||||
workflow (~> 1.2.0)
|
||||
|
||||
BUNDLED WITH
|
||||
1.10.6
|
||||
|
24
app/views/admin/need_categories/index.html.haml
Normal file → Executable file
24
app/views/admin/need_categories/index.html.haml
Normal file → Executable file
@ -1,16 +1,18 @@
|
||||
%h1 Gestion des catégories
|
||||
-if @tree.length < 1
|
||||
Aucune catégorie
|
||||
-else
|
||||
%table.table.admin_table.table-hover.table-striped
|
||||
%thead.rows_header
|
||||
|
||||
%table.table.admin_table.table-hover.table-striped
|
||||
%thead.rows_header
|
||||
%tr
|
||||
%th
|
||||
Nom
|
||||
%th{:style => "width:100px"}
|
||||
|
||||
|
||||
%tr
|
||||
%th
|
||||
Nom
|
||||
%th{:style => "width:100px"}
|
||||
|
||||
|
||||
%tbody.rows
|
||||
|
||||
=render @tree
|
||||
%tbody.rows
|
||||
=render @tree
|
||||
|
||||
%br
|
||||
= link_to "Créer une nouvelle catégorie", new_admin_need_category_path, class:"btn btn-primary"
|
||||
|
86
app/views/admin/needs/index.html.haml
Normal file → Executable file
86
app/views/admin/needs/index.html.haml
Normal file → Executable file
@ -1,8 +1,10 @@
|
||||
%h1 Gestion des besoins
|
||||
|
||||
%h2 Proposition de besoin
|
||||
-if @needs_to_validate.length < 1
|
||||
Aucune proposition de besoin
|
||||
-else
|
||||
|
||||
-if @needs_to_validate.length > 0
|
||||
%h2 Modération des besoins
|
||||
%div.alert.alert-info
|
||||
Avant qu'un besoin soit visible par l'ensemble des clients, vous devez le valider en cliquant sur le bouton <i class="fa fa-check"></i>
|
||||
%br
|
||||
@ -28,51 +30,53 @@
|
||||
|
||||
=render collection: @needs_to_validate, partial: 'need_to_validate', as: :need
|
||||
%br
|
||||
|
||||
|
||||
%h2 Liste des besoins
|
||||
.row
|
||||
.col-md-2
|
||||
= semantic_form_for :search, :html => {id: :search_form, :method => :get } do |f|
|
||||
= f.inputs do
|
||||
=f.input :q, :as => :search, label: "Recherche", input_html: {value: params[:q], :name => 'q' }, placeholder: "Rechercher un besoin"
|
||||
.clear
|
||||
= f.inputs do
|
||||
= f.input :o, as: :order, selected: params[:o], input_html: {:name => 'o' }, label: "Ordre d'affichage", :include_blank => false , :as => :select, :collection => @orders
|
||||
.clear
|
||||
= f.inputs do
|
||||
= f.input :r, as: :result, selected: params[:r], input_html: {:name => 'r' }, label: 'Résultats par page', :include_blank => false , :as => :select, :collection => [10,20,50,100]
|
||||
.clear
|
||||
= f.inputs do
|
||||
= f.input :c, as: :category, selected: params[:c], input_html: {:name => 'c' }, label: 'Filtrer par catégorie', :include_blank => "Toute catégorie" , :as => :select, :collection => @tree.map{|c| [(c.level > 0 ? (' ' * (c.level - 1)) + "|- ": "").html_safe + c.name, c.id]}
|
||||
.clear
|
||||
= link_to "Créer un besoin", new_admin_need_path, class:"btn btn-primary"
|
||||
-if @needs.length < 1
|
||||
Aucun besoin
|
||||
-else
|
||||
.row
|
||||
.col-md-2
|
||||
= semantic_form_for :search, :html => {id: :search_form, :method => :get } do |f|
|
||||
= f.inputs do
|
||||
=f.input :q, :as => :search, label: "Recherche", input_html: {value: params[:q], :name => 'q' }, placeholder: "Rechercher un besoin"
|
||||
.clear
|
||||
= f.inputs do
|
||||
= f.input :o, as: :order, selected: params[:o], input_html: {:name => 'o' }, label: "Ordre d'affichage", :include_blank => false , :as => :select, :collection => @orders
|
||||
.clear
|
||||
= f.inputs do
|
||||
= f.input :r, as: :result, selected: params[:r], input_html: {:name => 'r' }, label: 'Résultats par page', :include_blank => false , :as => :select, :collection => [10,20,50,100]
|
||||
.clear
|
||||
= f.inputs do
|
||||
= f.input :c, as: :category, selected: params[:c], input_html: {:name => 'c' }, label: 'Filtrer par catégorie', :include_blank => "Toute catégorie" , :as => :select, :collection => @tree.map{|c| [(c.level > 0 ? (' ' * (c.level - 1)) + "|- ": "").html_safe + c.name, c.id]}
|
||||
.clear
|
||||
|
||||
.col-md-10
|
||||
%table.table.admin_table.table-hover.table-striped
|
||||
%thead.rows_header
|
||||
.col-md-10
|
||||
%table.table.admin_table.table-hover.table-striped
|
||||
%thead.rows_header
|
||||
|
||||
%tr
|
||||
%th
|
||||
Titre
|
||||
%th
|
||||
Catégorie
|
||||
%th
|
||||
Émetteur
|
||||
%th{style: 'text-align:center' }
|
||||
Commentaires/Intérêts
|
||||
%th{style: 'text-align:center' }
|
||||
Offres
|
||||
%th
|
||||
Statut
|
||||
%th{:style => "width:100px"}
|
||||
|
||||
%tr
|
||||
%th
|
||||
Titre
|
||||
%th
|
||||
Catégorie
|
||||
%th
|
||||
Émetteur
|
||||
%th{style: 'text-align:center' }
|
||||
Commentaires/Intérêts
|
||||
%th{style: 'text-align:center' }
|
||||
Offres
|
||||
%th
|
||||
Statut
|
||||
%th{:style => "width:100px"}
|
||||
|
||||
|
||||
%tbody.rows
|
||||
%tbody.rows
|
||||
|
||||
=render @needs
|
||||
=render @needs
|
||||
|
||||
.pagination.pull-right= paginate @needs
|
||||
.pagination.pull-right= paginate @needs
|
||||
%br
|
||||
= link_to "Créer un besoin", new_admin_need_path, class:"btn btn-primary"
|
||||
|
||||
|
||||
|
||||
|
2
app/views/public/my_account/index.html.haml
Normal file → Executable file
2
app/views/public/my_account/index.html.haml
Normal file → Executable file
@ -68,5 +68,5 @@
|
||||
=render "public/needs/index", needs: @needs
|
||||
-else
|
||||
%p
|
||||
Vous n'avez pas encore proposer de besoin
|
||||
Vous n'avez pas encore proposé de besoin
|
||||
=link_to "Proposer un besoin", new_public_need_path, :class => "btn btn-primary"
|
||||
|
@ -415,7 +415,7 @@ ActiveRecord::Schema.define(version: 20151209125427) do
|
||||
add_index "needs", ["author_id"], name: "index_needs_on_author_id", using: :btree
|
||||
add_index "needs", ["category_id"], name: "index_needs_on_category_id", using: :btree
|
||||
add_index "needs", ["deleted_at"], name: "index_needs_on_deleted_at", using: :btree
|
||||
add_index "needs", ["title"], name: "index_needs_on_title", using: :btree
|
||||
add_index "needs", ["title"], name: "index_needs_on_title", length: {"title"=>191}, using: :btree
|
||||
|
||||
create_table "newsgroups", force: :cascade do |t|
|
||||
t.string "name", limit: 255
|
||||
|
Loading…
x
Reference in New Issue
Block a user