     # get params
     params = @formParam(e.target)
 
+    # check if template is selected
+    return if !params['template_id']
+
+    # remember template (to select it after rerender)
     @template_id = params['template_id']
+
     template = App.Template.find( params['template_id'] )
     App.Event.trigger 'ticket_create_rerender', template.attributes()
 


    # get params
    params = @formParam(e.target)
    template = App.Template.find( params['template_id'] )
    if confirm('Sure?')
      @template_id = false

      ui = @
      template.save(
        done: ->
          ui.template_id = @id

        fail: =>
          @log 'error', 'save failed!'
