Files
Chronos/src/Chronos.Data/Copies/CopyReviewModel.cs
T
Alby96andClaude Opus 5.5 9657c1711d fix(copies): close the owner review 6 second verification findings
Upload again now deletes the gone pair row once the new sequence is linked, so
the pair stops reading "deleted on server" or "kept here". A linked upload the
server refuses into its sequence (403 for an account without Edit that does not
own it) falls back to ordinary uploads instead of failing; an Integrate that
would add photos to such a sequence is blocked in its plan (NoAddRight).
Automatic photo transfers pause on a metered connection whatever the option
says. Integrate trashes server photos only against the manifest version that
checked the winner, and a merge is blocked while the other sequence holds a
damaged photo nothing else holds (DamagedPhotos), so nothing unverified reaches
the trash.

The plan and the confirmations now say what really happens: replaced versions
are no longer counted as kept, a merge lists the kept sequence's replaced
photos, plan lines use the text colour, an integrated pair that left photos out
says new photos move by hand, and a merging pair reads "merging" with its
progress. The Compare dialog gets per-side tooltips, class sizes for both
sides, policy-aware class tooltips, column headings and readable file names;
the sync table shows "deleted there" with Review and warns on skipped rows; the
Edit picker names the server, the Library card shows the match status second,
a deleted server sequence is named instead of "0 photos", and the match
tooltips stop calling a sequence a copy. The capture scenes use the server
name, the link names and consistent sample sizes.

Refs #73

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-17 16:08:49 +01:00

45 lines
3.0 KiB
C#
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
using Chronos.Core.Model;
using Chronos.Data.Sync;
namespace Chronos.Data.Copies;
/// <summary>One difference of title, tags, rating, notes or settings between two copies (a JSON path, both values as shown).</summary>
public sealed record DetailLine(string Path, string? Here, string? There);
/// <summary>A project of one home, as the Projects part lists it.</summary>
public sealed record ProjectLine(Guid Id, string Name, bool IsMain, int Versions, Guid HeadId, string HeadHash, DateTimeOffset UpdatedAt);
/// <summary>
/// Both homes' projects. MainSame: the two Main heads make the same choices; ThereKeepsProjects: the other home keeps
/// projects (a server without the <c>projects</c> capability keeps none).
/// </summary>
public sealed record CopyProjectsView(IReadOnlyList<ProjectLine> Here, IReadOnlyList<ProjectLine> There, bool MainSame, bool ThereKeepsProjects);
/// <summary>Renders of each side, and those both hold (by render id, or by SHA-256 where both record one).</summary>
public sealed record CopyRendersView(int Here, int There, int Shared, long HereBytes, long ThereBytes);
/// <summary>
/// The facts of one side: title, where it lies (archive or server name), photos, bytes, capture range, camera, hashed count,
/// origin, the servers the local copy is linked to, and whether it lies in a server's originals archive.
/// </summary>
public sealed record CopyFacts(string Title, string Where, Guid? ArchiveId, int Photos, long Bytes, DateTime? First, DateTime? Last,
string? Camera, int Hashed, SequenceOrigin? Origin, IReadOnlyList<string> Servers, bool InOriginalsArchive);
/// <summary>What the Compare dialog shows of a pair: both sides, the photos, the details line by line, projects, renders, and what can be done.</summary>
public sealed record CopyReview(FoundCopy Copy, CopyFacts Here, CopyFacts There, CopyComparisonResult Photos,
IReadOnlyList<DetailLine> Details, CopyProjectsView Projects, CopyRendersView Renders, CopyCapabilities Can);
/// <summary>Whether Integrate (or Merge), Link only and Delete on server are possible, and why not (<see cref="CopyBlock"/>s).</summary>
public sealed record CopyCapabilities(bool Integrate, bool LinkOnly, bool DeleteThere, IReadOnlyList<CopyBlock> Blocks);
/// <summary>A row of Server › Matches: the pair with the facts of both sides (the other side's from the server listing or the other archive).</summary>
public sealed record FoundCopyView(FoundCopy Copy, CopyFacts Here, CopyFacts There);
/// <summary>
/// The same time-lapse with workspace projects at two homes (a linked or integrated pair): the Edit picker marks each as the
/// other's twin. LocalHome names the local copy's archive; a project name is null when that home has no workspace project.
/// ServerName is the name shown for Server (the key itself when no name is known).
/// </summary>
public sealed record CopyTwin(Guid CopyId, Guid LocalId, string LocalHome, string? LocalProject, string Server, Guid RemoteId, string? ServerProject,
string ServerName);