From e7cde54890127b1cc24cf03408111908e43851c6 Mon Sep 17 00:00:00 2001 From: Felix Niklas Date: Wed, 27 May 2015 16:55:08 +0200 Subject: [PATCH] fix priority icons and text color --- .../_application_controller_table.js.coffee | 2 ++ .../app/controllers/navigation.js.coffee | 2 +- .../app/models/organization.js.coffee | 4 ++-- .../javascripts/app/models/ticket.js.coffee | 10 +++++----- .../javascripts/app/models/user.js.coffee | 4 ++-- .../app/views/generic/table.jst.eco | 18 +++++++++++++----- app/assets/stylesheets/bootstrap.css | 10 ---------- app/assets/stylesheets/zammad.css.scss | 16 +++++++++++++--- 8 files changed, 38 insertions(+), 28 deletions(-) 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 824bf7ebc..17fa6bd97 100644 --- a/app/assets/javascripts/app/controllers/_application_controller_table.js.coffee +++ b/app/assets/javascripts/app/controllers/_application_controller_table.js.coffee @@ -158,6 +158,8 @@ class App.ControllerTable extends App.Controller headerFound = true header.push attribute + console.log(header) + # execute header callback if data.callbackHeader header = data.callbackHeader(header) diff --git a/app/assets/javascripts/app/controllers/navigation.js.coffee b/app/assets/javascripts/app/controllers/navigation.js.coffee index 73221a1f7..9fed5ecce 100644 --- a/app/assets/javascripts/app/controllers/navigation.js.coffee +++ b/app/assets/javascripts/app/controllers/navigation.js.coffee @@ -169,7 +169,7 @@ class App.Navigation extends App.Controller id: ticket.id class: "level-1 ticket-popover" url: ticket.uiUrl() - iconClass: ticket.icon() + iconClass: "priority" area.result.push data else if area.name is 'User' area.result = [] diff --git a/app/assets/javascripts/app/models/organization.js.coffee b/app/assets/javascripts/app/models/organization.js.coffee index ac3f4141e..39defff0c 100644 --- a/app/assets/javascripts/app/models/organization.js.coffee +++ b/app/assets/javascripts/app/models/organization.js.coffee @@ -17,8 +17,8 @@ class App.Organization extends App.Model uiUrl: -> '#organization/profile/' + @id - icon: (user) -> - "organization" + icon: -> + '' @_fillUp: (data) -> diff --git a/app/assets/javascripts/app/models/ticket.js.coffee b/app/assets/javascripts/app/models/ticket.js.coffee index b2c38fcac..c941a3963 100644 --- a/app/assets/javascripts/app/models/ticket.js.coffee +++ b/app/assets/javascripts/app/models/ticket.js.coffee @@ -28,7 +28,7 @@ class App.Ticket extends App.Model uiUrl: -> '#ticket/zoom/' + @id - level: (user) -> + level: -> state = App.TicketState.find( @state_id ) stateType = App.TicketStateType.find( state.state_type_id ) level = 1 @@ -38,13 +38,13 @@ class App.Ticket extends App.Model level = 3 level - icon: (user) -> - "priority" + icon: -> + "icon-priority level-#{ @level() }" - iconTitle: (user) -> + iconTitle: -> App.TicketState.find( @state_id ).displayName() - iconTextClass: (user) -> + iconTextClass: -> "level-#{ @level() }" iconActivity: (user) -> diff --git a/app/assets/javascripts/app/models/user.js.coffee b/app/assets/javascripts/app/models/user.js.coffee index cde4b5096..4ad77ca1d 100644 --- a/app/assets/javascripts/app/models/user.js.coffee +++ b/app/assets/javascripts/app/models/user.js.coffee @@ -33,8 +33,8 @@ class App.User extends App.Model uiUrl: -> '#user/profile/' + @id - icon: (user) -> - "user" + icon: -> + '' initials: -> if @firstname && @lastname && @firstname[0] && @lastname[0] diff --git a/app/assets/javascripts/app/views/generic/table.jst.eco b/app/assets/javascripts/app/views/generic/table.jst.eco index ed6d1a6f9..d66f9b65a 100644 --- a/app/assets/javascripts/app/views/generic/table.jst.eco +++ b/app/assets/javascripts/app/views/generic/table.jst.eco @@ -37,7 +37,7 @@ <% end %> <% end %> <% position++ %> - + <% if @checkbox: %>