Fix calendar_for

pull/6827/head
Oliver Günther 6 years ago
parent cbca9db542
commit 8593cff18b
No known key found for this signature in database
GPG Key ID: A3A8BDAD7C0C552C
  1. 8
      lib/widget/filters/date.rb

@ -35,7 +35,7 @@ class Widget::Filters::Date < Widget::Filters::Base
arg1 = content_tag :span, id: "#{id_prefix}arg_1" do arg1 = content_tag :span, id: "#{id_prefix}arg_1" do
text1 = text_field_tag name, @filter.values.first.to_s, text1 = text_field_tag name, @filter.values.first.to_s,
size: 10, size: 10,
class: 'advanced-filters--text-field', class: 'advanced-filters--text-field -augmented-datepicker',
id: "#{id_prefix}arg_1_val", id: "#{id_prefix}arg_1_val",
:'data-type' => 'date' :'data-type' => 'date'
label1 + text1 label1 + text1
@ -48,15 +48,13 @@ class Widget::Filters::Date < Widget::Filters::Base
arg2 = content_tag :span, id: "#{id_prefix}arg_2", class: 'advanced-filters--filter-value2' do arg2 = content_tag :span, id: "#{id_prefix}arg_2", class: 'advanced-filters--filter-value2' do
text2 = text_field_tag "#{name}", @filter.values.second.to_s, text2 = text_field_tag "#{name}", @filter.values.second.to_s,
size: 10, size: 10,
class: 'advanced-filters--text-field', class: 'advanced-filters--text-field -augmented-datepicker',
id: "#{id_prefix}arg_2_val", id: "#{id_prefix}arg_2_val",
:'data-type' => 'date' :'data-type' => 'date'
label2 + text2 label2 + text2
end end
cal1 = calendar_for("#{id_prefix}arg_1_val") arg1 + arg2
cal2 = calendar_for("#{id_prefix}arg_2_val")
arg1 + arg2 + cal1 + cal2
end) end)
end end
end end

Loading…
Cancel
Save