aboutsummaryrefslogtreecommitdiffstats
path: root/app
diff options
context:
space:
mode:
authorjpl2017-02-08 18:51:12 +0100
committerjpl2017-02-08 18:51:12 +0100
commitf0c0e1434215b92b9c829a305bcea1a53b856e70 (patch)
tree9832b1ce95260506e8eed12a08b48385b80fd1a0 /app
parentd43717db535e0e8999963e0f96004ae1f2cd459b (diff)
downloadchouette-core-f0c0e1434215b92b9c829a305bcea1a53b856e70.tar.bz2
Refs #2482: fix tests
Diffstat (limited to 'app')
-rw-r--r--app/assets/stylesheets/components/_page_header.sass9
-rw-r--r--app/controllers/referentials_controller.rb4
-rw-r--r--app/views/referentials/show.html.slim5
3 files changed, 5 insertions, 13 deletions
diff --git a/app/assets/stylesheets/components/_page_header.sass b/app/assets/stylesheets/components/_page_header.sass
index 2431e5d4d..f94d886ca 100644
--- a/app/assets/stylesheets/components/_page_header.sass
+++ b/app/assets/stylesheets/components/_page_header.sass
@@ -56,12 +56,3 @@
&:first-child
margin-top: 0
-
- &::before
- content: '\f054'
- font: normal normal normal 14px/1 FontAwesome
- font-size: inherit
- text-rendering: auto
- -webkit-font-smoothing: antialiased
- display: inline
- margin-right: 0.5em
diff --git a/app/controllers/referentials_controller.rb b/app/controllers/referentials_controller.rb
index 83a56b6e0..6dbfc423d 100644
--- a/app/controllers/referentials_controller.rb
+++ b/app/controllers/referentials_controller.rb
@@ -32,8 +32,8 @@ class ReferentialsController < BreadcrumbController
}
format.html { build_breadcrumb :show}
end
- @q = lines_collection.ransack(params[:q])
- @reflines = @q.result(distinct: true).paginate(page: params[:page], per_page: 10)
+ p "test"
+ @reflines = lines_collection.paginate(page: params[:page], per_page: 10)
end
def edit
diff --git a/app/views/referentials/show.html.slim b/app/views/referentials/show.html.slim
index 270cbd4d1..91dc6103b 100644
--- a/app/views/referentials/show.html.slim
+++ b/app/views/referentials/show.html.slim
@@ -24,7 +24,8 @@
.pm-col
.pm-item
strong = "#{@referential.human_attribute_name(:validity_period)} : "
- = t('validity_range', debut: l(@referential.try(:validity_period).try(:begin), format: :short), end: l(@referential.try(:validity_period).try(:end), format: :short))
+ - if @referential.validity_period
+ = t('validity_range', debut: l(@referential.try(:validity_period).try(:begin), format: :short), end: l(@referential.try(:validity_period).try(:end), format: :short))
.pm-item
strong = "Organisation : "
@@ -41,7 +42,7 @@
.row.mt-xs
.col-lg-5.col-md-6.col-sm-6.col-xs-8
- = search_form_for @q, url: referential_path(@referential.id), html: { method: :get, class: 'form'} do |f|
+ = search_form_for @q, url: referential_path(@referential.id) do |f|
.input-group.search_bar
= f.search_field :name_cont, class: 'form-control', placeholder: 'Indiquez un nom de ligne'