Fixed saving of templates.

This commit is contained in:
Martin Edenhofer 2012-07-16 16:04:38 +02:00
parent e58f6c3734
commit 5598ff8ba8

View file

@ -87,10 +87,11 @@ class App.TemplateUI extends App.Controller
if errors
@log 'error new', errors
else
ui = @
template.save(
success: (r) =>
@template_id = r.id
@render()
success: ->
ui.template_id = @.id
ui.render()
error: =>
@log 'save failed!'