Sha256: 2d28ceae161b4f97b2221086eeb2b77ee8b35052a4d236ea09be13a5b2d2def9

Contents?: true

Size: 858 Bytes

Versions: 42

Compression:

Stored size: 858 Bytes

Contents

.form-group.task_term_fields class=("has-error" if f.object.errors.key?(:term))
  = f.label :term, class: "control-label col-sm-3"

  .col-sm-9
    .form-sub-group-container
      .form-sub-group.task_term_type
        = f.select :term, task_term_values_for_select, {include_blank: true}, {class: "form-control"}

      .form-sub-group.task_term_custom
        = f.date_field :term, class: "form-control", id: "task_term_custom"

    - if errors = f.object.errors[:term].join(", ").presence
      span.help-block = errors

coffee:
  $("#task_term")
    .change ->
      if $(this).val() == "custom" || $(this).val() == ""
        $("#task_term_custom").prop(disabled: false)
        $(".form-sub-group.task_term_custom").show()
      else
        $("#task_term_custom").prop(disabled: true)
        $(".form-sub-group.task_term_custom").hide()
    .change()

Version data entries

42 entries across 42 versions & 1 rubygems

Version Path
dorsale-4.0.0 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.20.0 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.19.1 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.19.0 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.18.0 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.17.0 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.16.0 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.15.0 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.14.11 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.14.10 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.14.9 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.14.8 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.14.7 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.14.6 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.14.5 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.14.4 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.14.3 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.14.2 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.14.1 app/views/dorsale/flyboy/tasks/_term_fields.html.slim
dorsale-3.14.0 app/views/dorsale/flyboy/tasks/_term_fields.html.slim