make sure the user really wants to delete something…
This commit is contained in:
parent
c486c293ef
commit
2d8305095b
|
@ -1,4 +1,5 @@
|
||||||
$(document).on "click", "button[name=ab-destroy]", ->
|
$(document).on "click", "button[name=ab-destroy]", ->
|
||||||
|
if confirm 'Are you sure?'
|
||||||
btn = $(this)
|
btn = $(this)
|
||||||
btn.button "loading"
|
btn.button "loading"
|
||||||
aid = btn[0].dataset.aId
|
aid = btn[0].dataset.aId
|
||||||
|
|
|
@ -27,6 +27,7 @@ $(document).on "click", "button[name=ib-answer]", ->
|
||||||
$("textarea[name=ib-answer][data-id=#{iid}]").removeAttr "readonly"
|
$("textarea[name=ib-answer][data-id=#{iid}]").removeAttr "readonly"
|
||||||
|
|
||||||
$(document).on "click", "button[name=ib-destroy]", ->
|
$(document).on "click", "button[name=ib-destroy]", ->
|
||||||
|
if confirm 'Are you sure?'
|
||||||
btn = $(this)
|
btn = $(this)
|
||||||
btn.button "loading"
|
btn.button "loading"
|
||||||
iid = btn[0].dataset.ibId
|
iid = btn[0].dataset.ibId
|
||||||
|
|
Loading…
Reference in New Issue