Sha256: 0f57f731e46543d74a6b00c7b045ac6e974b8aba793d3a533f98c849dabf79fa

Contents?: true

Size: 362 Bytes

Versions: 4

Compression:

Stored size: 362 Bytes

Contents

$ ->
  $("button.reset").click ->
    form = $(this).parents("form")

    form.find("option").map ->
      this.selected = true if this.value == ""

    form.find("input").map ->
      this.value = "" unless this.type.match(/submit|hidden|button/)

    form.find("textarea").val("")

    form.find("select").map ->
      this.selectize.clear() if this.selectize

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
dorsale-1.2.3 app/assets/javascripts/dorsale/forms.coffee
dorsale-1.2.2 app/assets/javascripts/dorsale/forms.coffee
dorsale-1.2.1 app/assets/javascripts/dorsale/forms.coffee
dorsale-1.2.0 app/assets/javascripts/dorsale/forms.coffee