Upgrades and fixes, maintenance
This commit is contained in:
@@ -18,20 +18,20 @@
|
||||
.form-label
|
||||
= label_tag nil, ProductCategory.human_attribute_name(:week_days), class: 'control-label'
|
||||
.form-field.full
|
||||
#week_days-group.btn-group data-toggle="buttons-checkbox"
|
||||
ul#week_days-group.button-group
|
||||
- day_names = week_days.dup; day_names << day_names.shift if current_supplier.week_starts_on_monday?
|
||||
- day_names.each do |day_name|
|
||||
button.week-day-toggle.tiny type="button" data-day=day_name data-t="product_category.week_days.abbreviation.#{day_name}"
|
||||
li: button.week-day-toggle.tiny type="button" data-day=day_name data-t="product_category.week_days.abbreviation.#{day_name}"
|
||||
|
||||
|
||||
span#full_day-controller
|
||||
span#full_day-controller: span
|
||||
#sub-day-container.hide
|
||||
/= f.input_field :start_from, as: :select, collection: (1..24).map{|h| ["#{h}:00", h*60]}
|
||||
/= f.input_field :end_on, as: :select, collection: (1..24).map{|h| ["#{h}:00", h*60]}
|
||||
= f.select :start_from, (1..24).map{|h| ["#{h}:00", h*60]}
|
||||
= f.select :end_on, (1..24).map{|h| ["#{h}:00", h*60]}
|
||||
.hidden
|
||||
- @product_category.week_days.each.with_index do |day, i|
|
||||
= select_tag 'product_category[week_days][]', options_for_select([0,1], day), class: 'week-day-select', id: "week-day-select-#{week_days[i]}", data: {day: week_days[i] }
|
||||
/= f.input :full_day, as: :select, collection: [true, false], label: false, include_blank: false
|
||||
/= f.input_field :full_day, as: :boolean, label: false, wrapper: false
|
||||
/= f.check_box :full_day
|
||||
= f.check_box :full_day
|
||||
= f.supplier_form_actions
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
- model_class = ProductCategory
|
||||
.page-header
|
||||
= title :edit, model_class
|
||||
= render 'form'
|
||||
= render 'form'
|
||||
|
||||
Reference in New Issue
Block a user