From 5b21435f045fbd77a6c50d2c482e332602aa2437 Mon Sep 17 00:00:00 2001 From: Martin Edenhofer Date: Fri, 20 Sep 2013 16:56:45 +0200 Subject: [PATCH] Renamed popover classes. --- .../_application_controller.js.coffee | 20 +++++++++---------- .../_application_controller_table.js.coffee | 4 ++-- .../controllers/agent_ticket_merge.js.coffee | 10 +++++----- .../app/controllers/navigation.js.coffee | 6 +++--- .../app/views/agent_ticket_history.jst.eco | 2 +- .../views/agent_ticket_view/detail.jst.eco | 2 +- .../views/dashboard/activity_stream.jst.eco | 2 +- .../views/ticket_zoom/article_view.jst.eco | 2 +- .../app/views/ticket_zoom/edit.jst.eco | 2 +- app/assets/stylesheets/zzz.css | 3 +++ 10 files changed, 28 insertions(+), 25 deletions(-) diff --git a/app/assets/javascripts/app/controllers/_application_controller.js.coffee b/app/assets/javascripts/app/controllers/_application_controller.js.coffee index f166911c8..340cc38c8 100644 --- a/app/assets/javascripts/app/controllers/_application_controller.js.coffee +++ b/app/assets/javascripts/app/controllers/_application_controller.js.coffee @@ -145,11 +145,11 @@ class App.Controller extends Spine.Controller all_attributes = [ { name: 'number', link: true, title: 'title' }, { name: 'title', link: true, title: 'title' }, - { name: 'customer', class: 'user-data', data: { id: true } }, + { name: 'customer', class: 'user-popover', data: { id: true } }, { name: 'ticket_state', translate: true, title: true }, { name: 'ticket_priority', translate: true, title: true }, { name: 'group', title: 'group' }, - { name: 'owner', class: 'user-data', data: { id: true } }, + { name: 'owner', class: 'user-popover', data: { id: true } }, { name: 'created_at', callback: @frontendTime }, { name: 'last_contact', callback: @frontendTime }, { name: 'last_contact_agent', callback: @frontendTime }, @@ -282,11 +282,11 @@ class App.Controller extends Spine.Controller ticketPopups: (position = 'right') -> # remove old popovers - $('.popover-inner').parent().remove() + $('.popover').remove() # show ticket popup ui = @ - $('.ticket-data').popover( + @el.find('.ticket-popover').popover( trigger: 'hover' container: 'body' html: true @@ -309,10 +309,10 @@ class App.Controller extends Spine.Controller userPopups: (position = 'right') -> # remove old popovers - $('.popover-inner').parent().remove() + $('.popover').remove() # show user popup - $('.user-data').popover( + @el.find('.user-popover').popover( trigger: 'hover' container: 'body' html: true @@ -355,10 +355,10 @@ class App.Controller extends Spine.Controller organizationPopups: (position = 'right') -> # remove old popovers - $('.popover-inner').parent().remove() + $('.popover').remove() # show organization popup - $('.organization-data').popover( + @el.find('.organization-popover').popover( trigger: 'hover' container: 'body' html: true @@ -380,7 +380,7 @@ class App.Controller extends Spine.Controller userTicketPopups: (data) -> # remove old popovers - $('.popover-inner').parent().remove() + $('.popover').remove() # get data tickets = {} @@ -400,7 +400,7 @@ class App.Controller extends Spine.Controller # show user popup controller = @ - $(data.selector).popover( + @el.find(data.selector).popover( trigger: 'hover' container: 'body' html: true diff --git a/app/assets/javascripts/app/controllers/_application_controller_table.js.coffee b/app/assets/javascripts/app/controllers/_application_controller_table.js.coffee index 278218aa0..3c1c9ff48 100644 --- a/app/assets/javascripts/app/controllers/_application_controller_table.js.coffee +++ b/app/assets/javascripts/app/controllers/_application_controller_table.js.coffee @@ -22,11 +22,11 @@ class App.ControllerTable extends App.Controller overview_extended: [ { name: 'number', link: true }, { name: 'title', link: true }, - { name: 'customer', class: 'user-data', data: { id: true } }, + { name: 'customer', class: 'user-popover', data: { id: true } }, { name: 'ticket_state', translate: true }, { name: 'ticket_priority', translate: true }, { name: 'group' }, - { name: 'owner', class: 'user-data', data: { id: true } }, + { name: 'owner', class: 'user-popover', data: { id: true } }, { name: 'created_at', callback: @frontendTime }, { name: 'last_contact', callback: @frontendTime }, { name: 'last_contact_agent', callback: @frontendTime }, diff --git a/app/assets/javascripts/app/controllers/agent_ticket_merge.js.coffee b/app/assets/javascripts/app/controllers/agent_ticket_merge.js.coffee index 8c5c4fee7..be19bd974 100644 --- a/app/assets/javascripts/app/controllers/agent_ticket_merge.js.coffee +++ b/app/assets/javascripts/app/controllers/agent_ticket_merge.js.coffee @@ -1,4 +1,4 @@ -class App.TicketMerge extends App.ControllerModal + class App.TicketMerge extends App.ControllerModal constructor: -> super @fetch() @@ -39,11 +39,11 @@ class App.TicketMerge extends App.ControllerModal overview_extended: [ { name: 'number', link: true }, { name: 'title', link: true }, -# { name: 'customer', class: 'user-data', data: { id: true } }, +# { name: 'customer', class: 'user-popover', data: { id: true } }, { name: 'ticket_state', translate: true }, # { name: 'ticket_priority', translate: true }, { name: 'group' }, -# { name: 'owner', class: 'user-data', data: { id: true } }, +# { name: 'owner', class: 'user-popover', data: { id: true } }, { name: 'created_at', callback: @humanTime }, # { name: 'last_contact', callback: @frontendTime }, # { name: 'last_contact_agent', callback: @frontendTime }, @@ -66,11 +66,11 @@ class App.TicketMerge extends App.ControllerModal overview_extended: [ { name: 'number', link: true }, { name: 'title', link: true }, -# { name: 'customer', class: 'user-data', data: { id: true } }, +# { name: 'customer', class: 'user-popover', data: { id: true } }, { name: 'ticket_state', translate: true }, # { name: 'ticket_priority', translate: true }, { name: 'group' }, -# { name: 'owner', class: 'user-data', data: { id: true } }, +# { name: 'owner', class: 'user-popover', data: { id: true } }, { name: 'created_at', callback: @humanTime }, # { name: 'last_contact', callback: @frontendTime }, # { name: 'last_contact_agent', callback: @frontendTime }, diff --git a/app/assets/javascripts/app/controllers/navigation.js.coffee b/app/assets/javascripts/app/controllers/navigation.js.coffee index eee67fc03..38f84c4e7 100644 --- a/app/assets/javascripts/app/controllers/navigation.js.coffee +++ b/app/assets/javascripts/app/controllers/navigation.js.coffee @@ -112,7 +112,7 @@ class App.Navigation extends App.Controller data = display: "##{ticket.number} - #{ticket.title} - #{ticket.humanTime}" id: ticket.id - class: "ticket-data" + class: "ticket-popover" url: "#ticket/zoom/#{ticket.id}" area.result.push data else if area.name is 'User' @@ -122,7 +122,7 @@ class App.Navigation extends App.Controller data = display: "#{user.displayName()}" id: user.id - class: "user-data" + class: "user-popover" url: "#users/#{user.id}" area.result.push data else if area.name is 'Organization' @@ -132,7 +132,7 @@ class App.Navigation extends App.Controller data = display: "#{organization.displayName()}" id: organization.id - class: "organization-data" + class: "organization-popover" url: "#organizations/#{ticket.id}" area.result.push data diff --git a/app/assets/javascripts/app/views/agent_ticket_history.jst.eco b/app/assets/javascripts/app/views/agent_ticket_history.jst.eco index 04c8dd2eb..e7348868d 100644 --- a/app/assets/javascripts/app/views/agent_ticket_history.jst.eco +++ b/app/assets/javascripts/app/views/agent_ticket_history.jst.eco @@ -21,7 +21,7 @@ <% open = true %> <% last_user = object['created_by_id'] %> <% lasttime = object['created_at'] %> - <%= object.created_by.displayName() %> - + <%= object.created_by.displayName() %> - ?