Merge branch 'develop' of github.com:martini/zammad into develop
This commit is contained in:
commit
2921ca663f
3 changed files with 33 additions and 16 deletions
|
@ -43,6 +43,11 @@ class App.OnlineNotificationWidget extends App.Controller
|
||||||
else
|
else
|
||||||
@el.find('.logo').append('<div class="activity-counter">' + count.toString() + '</div>')
|
@el.find('.logo').append('<div class="activity-counter">' + count.toString() + '</div>')
|
||||||
|
|
||||||
|
markAllAsSeen: (items) =>
|
||||||
|
for item in items
|
||||||
|
if !item.seen
|
||||||
|
App.OnlineNotification.seen( 'Ticket', item.id )
|
||||||
|
|
||||||
stop: =>
|
stop: =>
|
||||||
@counterUpdate(0)
|
@counterUpdate(0)
|
||||||
@el.find('.logo').popover('destroy')
|
@el.find('.logo').popover('destroy')
|
||||||
|
@ -68,10 +73,14 @@ class App.OnlineNotificationWidget extends App.Controller
|
||||||
placement: 'right'
|
placement: 'right'
|
||||||
title: ->
|
title: ->
|
||||||
App.i18n.translateInline( 'Notifications' ) + " <span>#{counter}</span>"
|
App.i18n.translateInline( 'Notifications' ) + " <span>#{counter}</span>"
|
||||||
content: ->
|
content: =>
|
||||||
# insert data
|
# insert data
|
||||||
App.view('widget/online_notification')(
|
html = $( App.view('widget/online_notification')(
|
||||||
items: items
|
items: items
|
||||||
|
))
|
||||||
|
html.on('click', (e) =>
|
||||||
|
e.preventDefault()
|
||||||
|
@markAllAsSeen(items)
|
||||||
)
|
)
|
||||||
).on('shown.bs.popover', =>
|
).on('shown.bs.popover', =>
|
||||||
# show frontend times
|
# show frontend times
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
<% if @items.length: %>
|
||||||
|
<a href="#"><%- @T( 'Mark all as seen.' ) %></a>
|
||||||
<% for item in @items: %>
|
<% for item in @items: %>
|
||||||
<div class="activity-entry horizontal">
|
<div class="activity-entry horizontal">
|
||||||
<a class="activity-avatar user-popover" data-id="<%= item.created_by_id %>" href="<%- item.created_by.uiUrl() %>">
|
<a class="activity-avatar user-popover" data-id="<%= item.created_by_id %>" href="<%- item.created_by.uiUrl() %>">
|
||||||
|
@ -13,3 +15,8 @@
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
<% else: %>
|
||||||
|
<h3 class="u-textTruncate" title="<%- @Ti( 'Name') %>">
|
||||||
|
<%- @T("No unread Notifications for you. :) ") %>
|
||||||
|
</h3>
|
||||||
|
<% end %>
|
|
@ -1914,6 +1914,7 @@ Translation.create_if_not_exists( :locale => 'de', :source => "from", :target =>
|
||||||
Translation.create_if_not_exists( :locale => 'de', :source => "to", :target => "nach" )
|
Translation.create_if_not_exists( :locale => 'de', :source => "to", :target => "nach" )
|
||||||
Translation.create_if_not_exists( :locale => 'de', :source => "%s ago", :target => "vor %s" )
|
Translation.create_if_not_exists( :locale => 'de', :source => "%s ago", :target => "vor %s" )
|
||||||
Translation.create_if_not_exists( :locale => 'de', :source => "in %s", :target => "in %s" )
|
Translation.create_if_not_exists( :locale => 'de', :source => "in %s", :target => "in %s" )
|
||||||
|
Translation.create_if_not_exists( :locale => 'de', :source => "Mark all as seen.", :target => "Alle als gelesen markieren." )
|
||||||
#Translation.create_if_not_exists( :locale => 'de', :source => "", :target => "" )
|
#Translation.create_if_not_exists( :locale => 'de', :source => "", :target => "" )
|
||||||
|
|
||||||
# install all packages in auto_install
|
# install all packages in auto_install
|
||||||
|
|
Loading…
Reference in a new issue