Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Group List not showing after closing the group chat window #3547

Open
avinash-ghadshi opened this issue Nov 20, 2024 · 8 comments
Open

Group List not showing after closing the group chat window #3547

avinash-ghadshi opened this issue Nov 20, 2024 · 8 comments

Comments

@avinash-ghadshi
Copy link

avinash-ghadshi commented Nov 20, 2024

Hi Team,

i have below configuration in my converse.js file.

const ChatRoomMixin = {
defaults() {
return {
'bookmarked': false,
'chat_state': undefined,
'has_activity': true,
// XEP-437
'hidden': isUniView() && !shared_api.settings.get('singleton'),
'hidden_occupants': !!shared_api.settings.get('hide_muc_participants'),
'message_type': 'groupchat',
'name': '',
// For group chats, we distinguish between generally unread
// messages and those ones that specifically mention the
// user.
//
// To keep things simple, we reusenum_unread from
// _converse.ChatBox to indicate unread messages which
// mention the user andnum_unread_general to indicate
// generally unread messages (which *includes* mentions!).
'num_unread_general': 0,
'num_unread': 0,
'auto_configure': true,
'roomconfig': {
// 'persistentroom': true,
// 'allow_invites': false,
// 'membersonly': true,
// 'auto_join_on_request': true,
'muc#roomconfig_persistentroom': true,
'muc#roomconfig_allowinvites': false,
'muc#roomconfig_membersonly': true,
'muc#roomconfig_publicroom' : true,
'muc#roomconfig_auto_join_on_request' : true,
'muc#roomconfig_auto_bookmark' : true
},
'time_opened': this.get('time_opened') || new Date().getTime(),
'time_sent': new Date(0).toISOString(),
'type': shared_converse.CHATROOMS_TYPE
};
}

I am getting below error in console.
converse.js:20525 ERROR:

BEFORE ADDING ANY GROUP
Screenshot 2024-11-20 at 6 21 19 PM

AFTER ADDING GROUP
Screenshot 2024-11-20 at 6 24 43 PM

After closing the chat window group name also get remove from GROUPCHATS section.
I want groups list should be persist even after logging out and login again.
What changes needs to be added to achieve this?

@jcbrand
Copy link
Member

jcbrand commented Nov 21, 2024

I am getting below error in console.
converse.js:20525 ERROR:

This doesn't show any error.

After closing the chat window group name also get remove from GROUPCHATS section.

This is probably related to the MUC's configuration. MUCs are often by default configured to be destroyed once the last person leaves.

Go to the MUC's configuration form (via the dropdown in the MUC header) and check if it's set to be persistent (what the setting is called depends on the XMPP server you're using).

I see you've added 'muc#roomconfig_persistentroom': true, to roomconfig, but I'm not sure that automatically means the room will be set to persistent.

@avinash-ghadshi
Copy link
Author

avinash-ghadshi commented Nov 25, 2024

Thanks @jcbrand for your response.

This is probably related to the MUC's configuration. MUCs are often by default configured to be destroyed once the last person leaves.

I added two more members in group and then left the group. Still it is not showing in the list.
I have tried in both the cases mentioned below, not worked for any.

  1. Group where i was moderator.
  2. Group where i was just a member.

Go to the MUC's configuration form (via the dropdown in the MUC header) and check if it's set to be persistent (what the setting is called depends on the XMPP server you're using).

Screenshot from 2024-11-25 15-15-55

I have added group persistent configuration in prosody conf also.
Screenshot from 2024-11-25 16-11-36

@jcbrand
Copy link
Member

jcbrand commented Nov 25, 2024

I want groups list should be persist even after logging out and login again.

Make sure that you bookmark the room.

@avinash-ghadshi
Copy link
Author

Hi @jcbrand,

Make sure that you bookmark the room.

I don't want to bookmark the room.

On bookmarking, it is opening a popup where i can see the bookmarked room list.

I want easy access to the room list.

@avinash-ghadshi
Copy link
Author

Or else can i show bookmark below GROUPCHATS section, instead of opening new popup?

@jcbrand
Copy link
Member

jcbrand commented Nov 25, 2024

I'm not sure what the issue is here. If the MUC is set to persistent, then it should stay in the GROUPCHATS section even when you log out and in again, unless you're doing something like checking the checkbox when you log in to say that it's not a trusted website or using incognito mode.

@avinash-ghadshi
Copy link
Author

avinash-ghadshi commented Nov 26, 2024

i am not using incognito mode.

unless you're doing something like checking the checkbox when you log in to say that it's not a trusted website

As per below screenshot, i have checked the checkbox saying This is a trusted device
Screenshot from 2024-11-26 10-19-25

@avinash-ghadshi
Copy link
Author

converse.initialize({
bosh_service_url: '/http-bind', // or WebSocket URL
timeout: 30000,
file_transfer: true,
clear_cache_on_logout: false,
max_file_size: 5242880,
i18n: 'en',
auto_list_rooms: true,
allow_logout: true,
show_controlbox_by_default: true, // Show login box on page load
authentication: 'login', // Supports 'login', 'anonymous', or 'prebind'
auto_login: true, // Set to true if you want auto-login for authenticated users
jid: response.username, // XMPP username (optional, depends on auth method)
password: response.password, // XMPP password (optional, depends on auth method)
allow_muc: false, // Enable multi-user chat (group chat)
muc_enable_public_rooms: false,
updateOccupantsOnPresence: true,
auto_join_on_invite: true,
allow_message_carbons: true, // For message syncing across devices
play_sounds: true,
allow_otr: true, // Enable end-to-end encryption (OTR)
whitelisted_plugins: ['converse-muc','delete-group','remove-participant','converse-roomslist'],
debug: true, // Set to false in production
auto_bookmark: true,
roster_groups: false,
allow_registration: false,
});

This is my converse initialization code.
I have also tried with auto_login: false

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants