diff --git a/app/assets/javascripts/app/controllers/_application_controller.js.coffee b/app/assets/javascripts/app/controllers/_application_controller.js.coffee index 97ff553b0..cde03a690 100644 --- a/app/assets/javascripts/app/controllers/_application_controller.js.coffee +++ b/app/assets/javascripts/app/controllers/_application_controller.js.coffee @@ -601,8 +601,20 @@ class App.Controller extends Spine.Controller # users if params.type == 'User' for user of params.data + + # set image url if params.data[user] && !params.data[user]['image'] params.data[user]['image'] = 'http://placehold.it/48x48' + + # set realname + params.data[user]['realname'] = '' + if params.data[user]['firstname'] + params.data[user]['realname'] = params.data[user]['firstname'] + if params.data[user]['lastname'] + if params.data[user]['realname'] isnt '' + params.data[user]['realname'] = params.data[user]['realname'] + ' ' + params.data[user]['realname'] = params.data[user]['realname'] + params.data[user]['lastname'] + App.User.refresh( params.data[user], options: { clear: true } ) # tickets @@ -671,7 +683,6 @@ class App.Controller extends Spine.Controller for object in params.data App[params.type].refresh( object, options: { clear: true } ) - class App.ControllerModal extends App.Controller className: 'modal hide fade', tag: 'div', diff --git a/app/assets/javascripts/app/views/agent_ticket_view/detail.jst.eco b/app/assets/javascripts/app/views/agent_ticket_view/detail.jst.eco index 6b6498f16..7ca68e149 100644 --- a/app/assets/javascripts/app/views/agent_ticket_view/detail.jst.eco +++ b/app/assets/javascripts/app/views/agent_ticket_view/detail.jst.eco @@ -19,7 +19,7 @@ State: <%= ticket.ticket_state.name %> Priority: <%= ticket.ticket_priority.name %> Group: <%= ticket.group.name %> - Owner: <%= ticket.owner.firstname + ' ' + ticket.owner.lastname %> + Owner: <%= ticket.owner.realname %>
diff --git a/app/assets/javascripts/app/views/dashboard/activity_stream.jst.eco b/app/assets/javascripts/app/views/dashboard/activity_stream.jst.eco index ea118b818..c6a2ba3d3 100644 --- a/app/assets/javascripts/app/views/dashboard/activity_stream.jst.eco +++ b/app/assets/javascripts/app/views/dashboard/activity_stream.jst.eco @@ -1,10 +1,11 @@

<%= @head %>

- +
\ No newline at end of file diff --git a/app/assets/javascripts/app/views/user_info.jst.eco b/app/assets/javascripts/app/views/user_info.jst.eco index d42f3857e..04e3e6c1b 100644 --- a/app/assets/javascripts/app/views/user_info.jst.eco +++ b/app/assets/javascripts/app/views/user_info.jst.eco @@ -4,7 +4,7 @@ <% end %>
-
<%= @user['firstname'] %> <%= @user['lastname'] %>
+
<%= @user['firstname'] %>
<% for row in @data: %> <% if @user[row.name]: %>