$('#subscription_id").on "change", ->
console.log "Hello"
outputs = $(this).val()
if outputs
$('#subscription_id').prop "disable", "false"
else
$('##subscription_id').prop "disable", "true"
答案 0 :(得分:11)
颜色表明问题:
$('#subscription_id").on "change"
应该是
$('#subscription_id').on "change"