mirror of
https://github.com/pierre42100/ComunicWeb
synced 2024-11-26 13:59:23 +00:00
Created new shorcut to open groups quickly
This commit is contained in:
parent
500633862e
commit
2032017b0c
@ -54,6 +54,20 @@ function openUserPageFromID(user){
|
||||
return openPage("user/" + user);
|
||||
}
|
||||
|
||||
/**
|
||||
* Open a group age
|
||||
*
|
||||
* @param {Object} info Information about the target group
|
||||
*/
|
||||
function openGroupPage(info){
|
||||
|
||||
if(info.virtual_directory != "null")
|
||||
openPage(info.virtual_directory);
|
||||
else
|
||||
openPage("groups/" + info.id);
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if user is signed in or not
|
||||
*
|
||||
|
@ -92,7 +92,7 @@ ComunicWeb.pages.groups.pages.main = {
|
||||
});
|
||||
|
||||
groupName.addEventListener("click", function(e){
|
||||
openPage("groups/" + group.id);
|
||||
openGroupPage(group);
|
||||
});
|
||||
|
||||
//Offer the user to delete its membership
|
||||
|
Loading…
Reference in New Issue
Block a user