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

Use review creation date for display and sorting #1169

Merged
merged 2 commits into from
Dec 1, 2024

Conversation

salty-horse
Copy link
Collaborator

Fixes #565, and addresses #1117.

For reviews where the edit date is a different day than the creation date, there's an "(edited: Mon, DD, YYYY)" addition. It's long, so if you have better ideas on how to display it, please share.

The personal page didn't display the date, so I removed it from the query.

Not shown, but I also checked that the RSS of game reviews is correct.

Game page:
game_page

Game page &ratings view:
gamepage_ratings_view

User page:
showuser

Copy link
Collaborator

@dfabulich dfabulich left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There as many as three dates for each review: its creation date, its embargo date, and the edit date (if any). #947

In newitems.php we order by greatest(reviews.createdate, ifnull(reviews.embargodate, '0000-00-00')) as d which feels like the right thing to do.

For reviews where the edit date is a different day than the creation date, there's an "(edited: Mon, DD, YYYY)" addition. It's long, so if you have better ideas on how to display it, please share.

I like the suggestion in #565 to add a note in a smaller font to the bottom of the review, giving us room to make the note as long/complicated as needed, and to display the computed sorting date at the top of the review.

This review was originally created on XXX, and was embargoed until YYY. It was last edited on ZZZ.

This review was originally created on XXX, and was last edited on YYY.

@salty-horse
Copy link
Collaborator Author

Your suggestion includes creation date twice, at the top and bottom. Isn't that redundant?

I still think there should be an indication something was edited. Maybe an asterisk next to the top date?

Should the embargo date be public knowledge?

@dfabulich
Copy link
Collaborator

dfabulich commented Nov 23, 2024

I still think there should be an indication something was edited. Maybe an asterisk next to the top date?

Sure, an asterisk would be fine.

Should the embargo date be public knowledge?

I don't see why not. It's certainly publicly available in the IF Archive export.

Your suggestion includes creation date twice, at the top and bottom. Isn't that redundant?

Kinda? I think the explanation would be confusing unless it juxtaposes the dates, which inherently requires repeating whichever date happens to be at the top.

For example, suppose we have three reviews:

  1. Created Jan 1, embargoed until Jan 2, edited Jan 3
    • At the top: "Jan 2*"
    • At the bottom: "* This review was originally created on Jan 1, and it was embargoed until Jan 2. It was last edited on Jan 3."
  2. Created Feb 1, embargoed until Feb 2
    • At the top: "Feb 2*"
    • At the bottom: "* This review was originally created on Feb 1, and it was embargoed until Feb 2."
  3. Created Mar 1, edited Mar 3
    • At the top: "Mar 1*"
    • At the bottom: "* This review was originally created on Mar 1. It was last edited on Mar 3."

@dfabulich
Copy link
Collaborator

dfabulich commented Nov 29, 2024

OK, I think the consensus from the forum thread is to handle it like this:

  • The main date at the top should be the "publication date," which is the greater of either the creation date or the embargo date. We should use the publication date for sorting, as well.
  • If the review was edited, show the date with an asterisk, and then, at the end, show "* This review was last edited on [DATE]." (We don't need to repeat the publication date, or separately specify the creation date or the embargo date.)

@salty-horse
Copy link
Collaborator Author

What about "rating only" reviews, that are just a rating, username, and date? (Shown in a screenshot in the first post)

@salty-horse
Copy link
Collaborator Author

salty-horse commented Nov 30, 2024

Pushed a new commit.

The query now takes the embargo date into account with

greatest(createdate, ifnull(embargodate, cast(0 as datetime))) as createdate

For big reviews, I used a footnote (with <small> element rather than <div class="details">), and added a title to the asterisk with the same text.

For ratings-only reviews, I left it on the same line as the creation date.
edited

@dfabulich dfabulich merged commit 531a12c into iftechfoundation:main Dec 1, 2024
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

Successfully merging this pull request may close these issues.

Review Dates Change Upon Editing
2 participants