Closed nugerhard closed 11 months ago
Apologies, added some small last-minute stuff: when the timer ran out, page did not reflect changes until it was reloaded. So, when the update function is now called, the page is refreshed. Also, did a bit of shuffling of the html on the lobby details page to make it look nicer.
Closing Statement: This PR was definitely down to the wire, apologies. But the placeholder game and the lobby_details page are now connected. And, the timer is as robust as it can be (so long as it can only exist on one page, say lobby_details).
Here's a bit more color on the sqlite issue, from a conversation on Slack between me, Elizabeth, and Chloe: The database can't calculate the values independently. So, the script at the bottom of our lobbies page has to run in order for the match_status to update. I figured, rather than adding a script at the bottom of the lobby list page which runs a timer check for each of the lobbies on the page (and reloads the when any one runs out), it would be better to have the non-updated lobby status displayed on the page.
Issue Score: Excellent
Comments: Very large PR that provided much more functionality to matches - great work!
This is a 2 (probably 3) issue pr: Essentially, what I've done is I have made the placeholder game accessible from any particular lobby page. But, it only becomes accessible once the lobby conditions have been met. To this end, I've integrated a timer related to the lobby model onto the lobby detail page using an AJAX function: once this timer has expired, and sufficient users are in the lobby, the lobby allows the user to play the game. More notes to come, likely on the relevant issues.