Files @ ae5ac36cdf83
Branch filter:

Location: kallithea/rhodecode/templates/admin/notifications/notifications.html

Mads Kiilerich
pull request: use unionrepo instead of outgoing

This makes it possible to look the 'moving target' symbols up in the right repo.

Using a revset with the right revisions also removes the need for pruning
changesets that are outside the requested range.

It will also not be confused by changesets that for some reason has been pulled
to the repo but haven't been merged yet. They are going to be 'merged' by the
'pull' request and should thus be a part of what is reviewed.
## -*- coding: utf-8 -*-
<%inherit file="/base/base.html"/>

<%def name="title()">
    ${_('My Notifications')} ${c.rhodecode_user.username} - ${c.rhodecode_name}
</%def>

<%def name="breadcrumbs_links()">
    ${_('My Notifications')}
</%def>

<%def name="page_nav()">
    ${self.menu('admin')}
</%def>

<%def name="main()">
<div class="box">
    <!-- box / title -->
    <div class="title">
        ${self.breadcrumbs()}
        ##<ul class="links">
        ##    <li>
        ##      <span style="text-transform: uppercase;"><a href="#">${_('Compose message')}</a></span>
        ##    </li>
        ##</ul>
    </div>

      <div style="padding:14px 18px;text-align: right;float:left">
      <span id='all' class="ui-btn"><a href="${h.url.current()}">${_('All')}</a></span>
      <span id='comment' class="ui-btn"><a href="${h.url.current(type=c.comment_type)}">${_('Comments')}</a></span>
      <span id='pull_request' class="ui-btn"><a href="${h.url.current(type=c.pull_request_type)}">${_('Pull requests')}</a></span>
      </div>
      %if c.notifications:
      <div style="padding:14px 18px;text-align: right;float:right">
      <span id='mark_all_read' class="ui-btn">${_('Mark all read')}</span>
      </div>
      %endif
  <div id='notification_data'>
    <%include file='notifications_data.html'/>
  </div>
</div>
<script type="text/javascript">
var url_action = "${url('notification', notification_id='__NOTIFICATION_ID__')}";
var run = function(){
  YUE.on(YUQ('.delete-notification'),'click',function(e){
   var notification_id = e.currentTarget.id;
   deleteNotification(url_action,notification_id)
  })
  YUE.on(YUQ('.read-notification'),'click',function(e){
     var notification_id = e.currentTarget.id;
     readNotification(url_action,notification_id)
  })
}
run()
YUE.on('mark_all_read','click',function(e){
    var url = "${h.url('notifications_mark_all_read', **request.GET.mixed())}";
    ypjax(url,'notification_data',function(){run()});
})

var current_filter = "${c.current_filter}";
if (YUD.get(current_filter)){
    YUD.addClass(current_filter, 'active');
}
</script>
</%def>