From 18e407693a46d8592c0ab549d480bc7c0b8fdcbf Mon Sep 17 00:00:00 2001 From: Martin Edenhofer Date: Wed, 9 Mar 2016 08:05:34 +0100 Subject: [PATCH] Add current user to process text modules. --- .../app/controllers/ticket_zoom/article_new.coffee | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/app/assets/javascripts/app/controllers/ticket_zoom/article_new.coffee b/app/assets/javascripts/app/controllers/ticket_zoom/article_new.coffee index be08b66fa..f557cd23f 100644 --- a/app/assets/javascripts/app/controllers/ticket_zoom/article_new.coffee +++ b/app/assets/javascripts/app/controllers/ticket_zoom/article_new.coffee @@ -248,15 +248,17 @@ class App.TicketZoomArticleNew extends App.Controller # show text module UI if !@isRole('Customer') textModule = new App.WidgetTextModule( - el: @$('.js-textarea').parent() + el: @$('.js-textarea').parent() data: ticket: ticket + user: App.Session.get() ) callback = (ticket) -> textModule.reload( ticket: ticket + user: App.Session.get() ) - @subscribeIdTextModule = ticket.subscribe( callback ) + @subscribeIdTextModule = ticket.subscribe(callback) params: => params = @formParam( @$('.article-add') ) @@ -423,7 +425,7 @@ class App.TicketZoomArticleNew extends App.Controller @$('[data-name=body] [data-signature="true"]').remove() # apply new signature - signatureFinished = App.Utils.replaceTags( signature.body, { user: App.Session.get(), ticket: ticketCurrent } ) + signatureFinished = App.Utils.replaceTags(signature.body, { user: App.Session.get(), ticket: ticketCurrent }) body = @$('[data-name=body]').html() || '' if App.Utils.signatureCheck(body, signatureFinished)