feat(manage/media): let some roles wipe all game screenshots#4848
feat(manage/media): let some roles wipe all game screenshots#4848wescopeland wants to merge 3 commits intoRetroAchievements:masterfrom
Conversation
| ->label('Deleted screenshots') | ||
| ->placeholder('Current screenshots') | ||
| ->trueLabel('All screenshots') | ||
| ->falseLabel('Deleted screenshots'), |
There was a problem hiding this comment.
There was a problem hiding this comment.
I wrestled with this too when figuring out what solution I wanted to build for this functionality. My original idea was to have an "Archived" status, but that felt awfully ambiguous with "Rejected" also in the mix.
A deleted screenshot having a status of published means, on restore, the screenshot will be published again. That makes cleanly undoing the delete possible.
Here's where I've landed in latest - no more trashed entity filter. It's disguised as a Status to hopefully be more intuitive even though the underlying model is unchanged:

There was a problem hiding this comment.
You're right. This is intentional, especially through the player-facing UI. Reasoning: if some back office action deleted the image, it shouldn't be reuploaded by a player again for back office review.
| ->modalDescription(fn (GameScreenshot $record): string => $record->is_primary | ||
| ? 'This is a primary screenshot. The next published screenshot of this type will be promoted automatically, or the placeholder will be restored.' | ||
| : 'Are you sure you want to delete this screenshot?') | ||
| : 'Are you sure you want to permanently delete this screenshot?') |
There was a problem hiding this comment.
In the previous diff, it authorized implicitly against the deletion policy (original uploader + still Pending). I think we should remove it altogether TBH, which I've done in latest.




http://localhost:64000/manage/games/44/media
This PR lets admins, game editors, and media editors invoke an action to clear/reset all screenshots for a game. This effectively soft-deletes all the
game_screenshotentities associated with the game and restores the original placeholder images.This is a destructive action buried in a new header menu: