File tree Expand file tree Collapse file tree 4 files changed +17
-3
lines changed
Expand file tree Collapse file tree 4 files changed +17
-3
lines changed Original file line number Diff line number Diff line change @@ -813,7 +813,7 @@ input[type="checkbox"] {
813813 background-color : # c4da5e ;
814814}
815815.l-profile__notifications .updates {
816- background-position : -202px -157 px ;
816+ background-position : -202px -135 px ;
817817}
818818
819819.notification-container {
Original file line number Diff line number Diff line change 2121} else {
2222 $ v_username = escapeshellarg ($ user );
2323 $ v_id = escapeshellarg ((int )$ _GET ['notification_id ' ]);
24- echo VESTA_CMD ."v-acknowledge-user-notification " .$ v_username ." " .$ v_id ;
2524 exec (VESTA_CMD ."v-acknowledge-user-notification " .$ v_username ." " .$ v_id , $ output , $ return_var );
2625 check_return_code ($ return_var ,$ output );
2726 unset($ output );
Original file line number Diff line number Diff line change @@ -105,6 +105,21 @@ function top_panel($user, $TAB) {
105105 }
106106 $ panel = json_decode (implode ('' , $ output ), true );
107107 unset($ output );
108+
109+
110+ // getting notifications
111+ $ command = VESTA_CMD ."v-list-user-notifications ' " .$ user ."' 'json' " ;
112+ exec ($ command , $ output , $ return_var );
113+ $ notifications = json_decode (implode ('' , $ output ), true );
114+ foreach ($ notifications as $ message ){
115+ if ($ message ['ACK ' ] == 'no ' ){
116+ $ panel [$ user ]['NOTIFICATIONS ' ] = 'yes ' ;
117+ break ;
118+ }
119+ }
120+ unset($ output );
121+
122+
108123 if ( $ user == 'admin ' ) {
109124 include (dirname (__FILE__ ).'/../templates/admin/panel.html ' );
110125 } else {
Original file line number Diff line number Diff line change 2323 </ div >
2424 <!-- /.l-menu -->
2525 < div class ="l-profile noselect ">
26- < a class ="l-profile__notifications <? if($panel[$user]['NOTIFICATIONS'] == 'yes') echo "updates "; ?> "> </ a >
26+ < a class ="l-profile__notifications <? if($panel[$user]['NOTIFICATIONS'] == 'yes') echo " updates "; ?> "> </ a >
2727 < a class ="l-profile__username " href ="/edit/user/?user=<?php echo $user; ?> "> < ?=$user?> </ a >
2828 < a class ="l-profile__logout " href ="/logout/ "> < ?=__('Log out')?> </ a >
2929 </ div >
You can’t perform that action at this time.
0 commit comments