fix(review): Share with Client in the player shares the shot
Deploy / deploy (push) Successful in 4m14s

The review player's button only made the viewed version client-visible. It
never set shot.sharedWithClient, and the client portal lists only shared
shots (and only each task's latest version), so the button reported
"Shared with Client" while the client saw nothing. It also skipped the
internal approval the shot page requires.

For a version that belongs to a shot (directly or through its task), the
button now runs the shot page's shareWithClient: shot marked shared, latest
version of each task visible, status to Client Review. It is disabled with
an explanation until the shot is internally approved, and the player's
Approve Internally button now appears for task versions too, only while the
shot awaits approval. Asset versions keep the per-version share.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
twotalesanimation
2026-09-18 09:24:42 +02:00
parent 2b373737d8
commit 45459e4b12
3 changed files with 51 additions and 13 deletions
+1 -1
View File
@@ -45,7 +45,7 @@ async function getReviewData(versionId: string) {
task: {
include: {
project: { select: { id: true, name: true, code: true } },
shot: { select: { id: true, shotCode: true } },
shot: { select: { id: true, shotCode: true, shotApprovalStatus: true, sharedWithClient: true } },
asset: { select: { id: true, assetCode: true, name: true } },
versions: {
orderBy: { versionNumber: "desc" },