worldcubeassociation.org icon indicating copy to clipboard operation
worldcubeassociation.org copied to clipboard

Confusing notice: "This competition's results are visible but haven't been posted yet."

Open timreyn opened this issue 1 year ago • 3 comments

image

I'm not sure what stage of the results posting process this competition is, but it's a little confusing -- what does it mean that results are visible? I can't see them.

This isn't just visible to staff / listed organizers -- it also shows when I'm logged-out.

timreyn avatar Apr 16 '24 14:04 timreyn

You caught the roughly 5 minutes window where the results are here but not posted yet because CAD is running.

The results are visible to admins I think, I can't remember if they show up directly on the main competition's page, but we (WRT) definitely check how they look publicly by going to the individual event's results page.

The notice is confusing enough, I'm not too sure why it's visible to non-admin?

Related issue: #772.

viroulep avatar Apr 16 '24 14:04 viroulep

There are two options here:

  1. Don't show the notice to non-admins
  2. Change the wording to something like "We are busy processing this competition's results - they should be available shortly."

Both are pretty straightforward, let us know if there is any preference. (I tend towards not showing it to non-admins - or perhaps, non-organizers/delegates as they will know that the results have been posted but aren't showing up yet?)

dunkOnIT avatar Apr 17 '24 06:04 dunkOnIT

Suggestion based on Duncan's reply: Keep the notice as-is for admins but display the updated wording (what is labeled (2) in his response) for non-admins

gregorbg avatar Apr 17 '24 06:04 gregorbg

I am new to Ruby, but I'd like to give it a try.

darshanvss avatar Jul 16 '24 16:07 darshanvss

@darshanvss you're welcome to pick this issue up! Roughly speaking, you'll want to:

  1. Find where in the code the existing message is currently displayed
  2. In en.yml,Find the i18n key that is being called to display the existing text
  3. Create a new key in the same section which will be displayed to non-admin users
  4. Add an if branch in the section of code you found in (1) which displays the key you defined in (3) to non-admin users

There is a function that will check whether the user can admin the competition - if you look around in the code near (1) you should be able to find it pretty quickly

Don't forget to check our docs for how to get up and running, as well as a basic guide on Rails.

If any of the steps I listed don't make sense, ChatGPT should be able to point you in the right direction (eg, explaining what en.yml is and where to find it). We're happy to help with questions if you don't right with those resources, though!

dunkOnIT avatar Jul 18 '24 07:07 dunkOnIT

@timreyn the pr has been approved and merged. You can close this now ;)

lnzainn avatar Aug 07 '24 13:08 lnzainn