App.ModalController = Ember.ObjectController.extend
  modal_options: {}
  actions:
    close: ->
      if close = @get('modal_options.close')
        close.apply(@)
      @send 'closeModal' unless @preventClose
    ok: ->
      if ok = @get('modal_options.ok')
        ok.apply(@)
      @send 'closeModal' unless @preventClose
