Reopen estimate: carry signature strokes on the estimate payload
Reopening an already-validated estimate showed an empty pad: the
strokes were stored server-side but never sent back. Embed them in the
estimate payload and load them straight into the pad, in the same wire
format PostIt captured — no separate fetch.
- Server: Signature inverse navs get STJ [JsonIgnore] (cycle-safe
under System.Text.Json, matching ApplicationUser); the four estimate
read endpoints Include(e => e.Signatures) so strokes ride the payload
- Client: EstimateDto.Signatures with EstimateSignatureDto (Strokes,
Type=Pro/0|Client/1, CoordinateMax, CapturedAtUtc)
- PostIt: SignaturePadControl.Load(int[]) replaces the buffer and
raises RedrawRequested; EstimateValidationPageViewModel.LoadExisting
Signature() picks the perspective's side off the estimate and loads
it on Attach
- Tests: server asserts GET estimate/{id} carries the strokes; PostIt
VM tests cover load + side-by-perspective
Co-Authored-By: Claude Code <noreply@anthropic.com>
This commit is contained in:
parent
827fe6b41f
commit
adc27a006b
7 changed files with 177 additions and 7 deletions
|
|
@ -31,7 +31,7 @@ public class Signature
|
|||
|
||||
public long EstimateId { get; set; }
|
||||
|
||||
[ForeignKey(nameof(EstimateId)), JsonIgnore]
|
||||
[ForeignKey(nameof(EstimateId)), JsonIgnore, System.Text.Json.Serialization.JsonIgnore]
|
||||
public virtual Estimate Estimate { get; set; }
|
||||
|
||||
/// <summary>
|
||||
|
|
@ -48,7 +48,7 @@ public class Signature
|
|||
[Required]
|
||||
public string SignerId { get; set; }
|
||||
|
||||
[ForeignKey(nameof(SignerId)), JsonIgnore]
|
||||
[ForeignKey(nameof(SignerId)), JsonIgnore, System.Text.Json.Serialization.JsonIgnore]
|
||||
public virtual ApplicationUser Signer { get; set; }
|
||||
|
||||
public SignatureType Type { get; set; }
|
||||
|
|
|
|||
Loading…
Reference in a new issue