-InternalLinkFormView = OrchestraView.extend(
+###*
+ * @namespace OpenOrchestra:InternalLinkFormView
+###
+window.OpenOrchestra or= {}
+
+###*
+ * @class InternalLinkFormView
+###
+class OpenOrchestra.InternalLinkFormView extends OrchestraModalView
+
   events:
     'click .modalClose': 'closeModal'
     'hidden.bs.modal': 'closedModal'
     'click button[data-clone]': 'sendToTiny'
 
+  ###*
+   * @param {object} options
+  ###
   initialize: (options) ->
     @options = @reduceOption(options, [
       'selector'

        activateForm(@, $('form', @$el))
    return

  closeModal: (event) ->
    @$el.modal 'hide'

  closedModal: (event) ->
    @$el.remove()

  sendToTiny: (event) ->
    if $('.label-tinyMce', this.$el).val() != ''
      @closeModal()

    ]
    return

  ###*
   * Spin and render ajax call
  ###
  render: ->
    @setElement @renderTemplate('OpenOrchestraBackofficeBundle:BackOffice:Underscore/internalLinkModalView',
      body: '<h1 class="spin"><i class=\"fa fa-cog fa-spin\"></i> Loading...</h1>'
