Sha256: 681761cfc21ae1901fe8e0d8ce1b7429f002158f8292f7ea262a09eee155c1f2

Contents?: true

Size: 1 KB

Versions: 33

Compression:

Stored size: 1 KB

Contents

-# frozen_string_literal: true
- available_width = question.presentation == :horizontal ? 100 : 66
- classes = [os_cycle]
- classes << question.question_group if question.question_group
- itemkey = "item_#{question.key}"
%td.item{:id => itemkey, :class => classes, :style => "width:#{available_width/(table.columns)}%", :rowspan => question.row_span, :data => question.extra_data}
  .fields{:class => question.type, :id => question.html_id}
    %select{:name => "answer[#{question.key}]", :onchange => "$(\"#answer_#{question.key}_\"+this.value).trigger(\"click\")", :data => {'field-key' => question.key}}
      -question.options.each do |opt|
        - checked = @answer.send(question.key) == opt.key.to_s
        - next if (opt.hidden and not checked)
        - cls = [question.type]
        - cls << 'placeholder' if opt.placeholder
        - hash = {:value => opt.key, :class => cls, :id => opt.view_id }
        - hash[:selected] = 'selected' if checked
        %option{hash}
          =opt.description
    = validations

Version data entries

33 entries across 33 versions & 1 rubygems

Version Path
quby-5.6.5 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.6.3 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.6.2 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.6.1 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.6.0 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.5.0 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.4.0 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.3.1 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.3.0 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.2.0 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.1.3 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.1.2 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.1.1 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.1.0 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.0.5 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.0.4 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.0.3 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.0.2 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.0.1 app/views/quby/v1/table/_item_question_select.html.haml
quby-5.0.0 app/views/quby/v1/table/_item_question_select.html.haml