-
Notifications
You must be signed in to change notification settings - Fork 6
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
get current token and the next 2 tokens in join activity #14
Comments
@Jasmeet1709 can you do this ? |
@vaibhavchellani yup I will do it by tomorrow sorry for late |
@vaibhavchellani is authentication part is done or I will do it temporary for token purpose if it is already done then please ignore it |
@Jasmeet1709 we dont need auth to be working as of now , we already have token system working you just need to fetch tokens from DB for this issue . |
@vaibhavchellani okay |
@Jasmeet1709 let me know of you have any doubts regarding this or anything else on the slack group |
@Jasmeet1709 updates ? |
@vaibhavchellani just give me time for today as I am busy in another work |
@vaibhavchellani Is latest token in db is a current token |
@vaibhavchellani or it is queue status(Current token) |
@Jasmeet1709 the latest token is the latest token given to a user aka the newest token , the queue status field depicts the status of queue ie active or inactive |
@vaibhavchellani if no_of_tokens is a total token then current token will be no_of_tokens - no_of_users having queue status 1 i.e active |
@Jasmeet1709 current token is the first token in the queue at that instant , its not equal to no_of_tokens - no_of_users . queue status depicts if the whole queue is active or not ,it tells nothing about a particular user |
@vaibhavchellani bro sorry token status of a user instead of queue status |
@vaibhavchellani and I think latest token is the no of total tokens in the queue |
@Jasmeet1709 i think it would be hard to traverse each user and check if they are active and not , i think a better way would be to have a child called "current_index" under queue node , where we can store the index of current token from the beginning , then we can directly go to that index number in the queue to do further operations . Let me know if you find this approach doable . |
@vaibhavchellani it is also fine or even better I am just suggesting solution from the given structure |
@Jasmeet1709 okay , lets get this done then ! |
@vaibhavchellani done man check it out by doing queue first id current token = 0 |
@Jasmeet1709 please reference the issue in the comment while making a PR . |
@vaibhavchellani yeah I forgot to add |
get current token and the next 2 tokens in join activity for the selected queue from the database
The text was updated successfully, but these errors were encountered: