mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-01-14 08:59:50 -05:00
Add Clear Button on WebUI for BroadCast.
This commit is contained in:
parent
cb6c2c9199
commit
4dd0f591f4
@ -876,7 +876,12 @@ void ChatHandler::handleClearLobby(Request &req, Response &resp)
|
||||
{
|
||||
ChatLobbyId id = 0;
|
||||
req.mStream << makeKeyValueReference("id", id);
|
||||
notifyChatCleared(ChatId(id));
|
||||
if (id !=0) {
|
||||
notifyChatCleared(ChatId(id));
|
||||
} else {
|
||||
//Is BroadCast
|
||||
notifyChatCleared(ChatId("B"));
|
||||
}
|
||||
resp.setOk();
|
||||
}
|
||||
|
||||
|
@ -211,6 +211,26 @@ function lobby(lobbyid){
|
||||
}
|
||||
)
|
||||
]
|
||||
} else {
|
||||
if (lobdt.subscribed != undefined
|
||||
&& lobdt.subscribed
|
||||
&& lobdt.is_broadcast
|
||||
) {
|
||||
//set participants
|
||||
particips = [
|
||||
m("div.btn", {
|
||||
style: {
|
||||
"text-align":"center"
|
||||
},
|
||||
onclick: function (){
|
||||
rs.request("chat/clear_lobby",{
|
||||
lobbyid,
|
||||
});
|
||||
m.route("/chat?lobby=" + lobbyid);
|
||||
}
|
||||
},"clear"),
|
||||
]
|
||||
}
|
||||
}
|
||||
return [
|
||||
intro,
|
||||
|
Loading…
Reference in New Issue
Block a user