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

for online status i have added this code. but if i want status for all the users in my list there is not easy way, can u add method for the same in sdk ? #290

Open
richanshah opened this issue Aug 22, 2023 · 11 comments
Labels
enhancement New feature or request

Comments

@richanshah
Copy link

for isOnline status, i have added this code. but if i want status for all the users in my list there is not easy way, can u add method for the same in sdk ?
CubeChatConnection.instance.lastActivityManager
?.subscribeToUserLastActivityStatus(cubeUser.id!, callback: (seconds) {
log("lastActivity: userId = ${cubeUser.id}, seconds = ${seconds}");
});

@TatankaConCube
Copy link
Contributor

unfortunately, we don't have other alternatives for now. initially, the subscribeToUserLastActivityStatus listener was developed to display user status in opened private chat, and in other places (dialogs list, contacts list, etc.) planned to use the Future<int> getLastActivity(int userId) method.

@richanshah
Copy link
Author

even after listening to this subscribeToUserLastActivityStatus , i am not getting this status continuously. have u keep any interval when it will get updated?

@TatankaConCube
Copy link
Contributor

do you mean that you don't receive events in the callback?

@richanshah
Copy link
Author

I am getting online status when another user logins but whby hen i pause the app or destory the session i am not getting offline status or any callbacks by which i can identify

@richanshah
Copy link
Author

it stills give me last online status data only

@richanshah
Copy link
Author

on the base of what u r giving last activity call back?

@TatankaConCube
Copy link
Contributor

pause the app or destory the session

this callback should work on the user's chat login/logout action. when the user you subscribed to makes the chat login/logout action the subscribed user should receive these events

on the base of what u r giving last activity call back?

when the user makes the chat login/logout actions our chat server sends the special stanzas for subscribed users

@TatankaConCube
Copy link
Contributor

TatankaConCube commented Aug 24, 2023

I requested from the back-end team the modification for this feature for subscription on multiple users and triggering the active/inactive user's events too, but they don't have the end date of the implementation of it.

@richanshah
Copy link
Author

pause the app or destory the session

this callback should work on the user's chat login/logout action. when the user you subscribed to makes the chat login/logout action the subscribed user should receive these events

on the base of what u r giving last activity call back?

when the user makes the chat login/logout actions our chat server sends the special stanzas for subscribed users

okay

@richanshah
Copy link
Author

I requested from the back-end team the modification for this feature for subscription on multiple users and triggering the active/inactive user's events too, but they don't have the end date of the implementation of it.

no problem, please update me once its done.

@TatankaConCube
Copy link
Contributor

please update me once its done.

ok, sure

@TatankaConCube TatankaConCube added the enhancement New feature or request label Dec 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants