Show More
@@ -24,22 +24,30 b'' | |||||
24 | </li> |
|
24 | </li> | |
25 | </ul> |
|
25 | </ul> | |
26 | </div> |
|
26 | </div> | |
|
27 | %if c.notifications: | |||
27 | <div style="padding:10px 15px;text-align: right"> |
|
28 | <div style="padding:10px 15px;text-align: right"> | |
28 | <span id='mark_all_read' class="ui-btn">${_('Mark all read')}</span> |
|
29 | <span id='mark_all_read' class="ui-btn">${_('Mark all read')}</span> | |
29 | </div> |
|
30 | </div> | |
|
31 | %endif | |||
30 | <div id='notification_data'> |
|
32 | <div id='notification_data'> | |
31 | <%include file='notifications_data.html'/> |
|
33 | <%include file='notifications_data.html'/> | |
32 | </div> |
|
34 | </div> | |
33 | </div> |
|
35 | </div> | |
34 | <script type="text/javascript"> |
|
36 | <script type="text/javascript"> | |
35 | var url = "${url('notification', notification_id='__NOTIFICATION_ID__')}"; |
|
37 | var url_del = "${url('notification', notification_id='__NOTIFICATION_ID__')}"; | |
36 | YUE.on(YUQ('.delete-notification'),'click',function(e){ |
|
38 | YUE.on(YUQ('.delete-notification'),'click',function(e){ | |
37 | var notification_id = e.currentTarget.id; |
|
39 | var notification_id = e.currentTarget.id; | |
38 | deleteNotification(url,notification_id) |
|
40 | deleteNotification(url_del,notification_id) | |
39 | }) |
|
41 | }) | |
40 | YUE.on('mark_all_read','click',function(e){ |
|
42 | YUE.on('mark_all_read','click',function(e){ | |
41 | var url = "${h.url('notifications_mark_all_read')}"; |
|
43 | var url = "${h.url('notifications_mark_all_read')}"; | |
42 |
ypjax(url,'notification_data',function(){ |
|
44 | ypjax(url,'notification_data',function(){ | |
|
45 | YUD.get('notification_counter').innerHTML=0; | |||
|
46 | YUE.on(YUQ('.delete-notification'),'click',function(e){ | |||
|
47 | var notification_id = e.currentTarget.id; | |||
|
48 | deleteNotification(url_del,notification_id) | |||
|
49 | }) | |||
|
50 | }); | |||
43 | }) |
|
51 | }) | |
44 | </script> |
|
52 | </script> | |
45 | </%def> |
|
53 | </%def> |
General Comments 0
You need to be logged in to leave comments.
Login now