Files
PowderCoatingLogix/src/PowderCoating.Web/Views/BankReconciliations/Report.cshtml
T
spouliot a0bdd2b5b4 Sweep all .cshtml files for encoding corruption; add pre-commit guard
Replace all corruption variants with HTML entities across 226 view files:
- 3-char UTF-8-as-Win1252 sequences (ae-corruption)
- Standalone smart/curly quotes that break C# Razor expressions
- Partially re-corrupted variants where the 3rd byte was normalised to ASCII

tools/Fix-Encoding.ps1: re-runnable sweep; uses [char] code points so the
script itself never contains a literal non-ASCII character; supports -DryRun

.githooks/pre-commit: blocks commits containing the ae-corruption byte
signature (xc3xa2xe2x82xac); git core.hooksPath = .githooks so the
hook is repo-committed and active for all future work on this machine.

Build clean; 225 unit tests pass.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-20 21:37:10 -04:00

110 lines
5.0 KiB
Plaintext

@model PowderCoating.Core.Entities.BankReconciliation
@using PowderCoating.Web.Controllers
@{
ViewData["Title"] = $"Reconciliation Report &ndash; {Model.Account?.Name}";
var clearedDeposits = ViewBag.ClearedDeposits as IEnumerable<PowderCoating.Core.Entities.Payment> ?? Enumerable.Empty<PowderCoating.Core.Entities.Payment>();
var clearedPayments = ViewBag.ClearedPayments as List<ReconciliationItem> ?? new();
}
<div class="d-flex align-items-center mb-3 gap-2 no-print">
<a asp-action="Index" class="btn btn-sm btn-outline-secondary">
<i class="bi bi-arrow-left me-1"></i>Back
</a>
<h4 class="mb-0 fw-semibold ms-2">Reconciliation Report</h4>
<button class="btn btn-sm btn-outline-secondary ms-auto" onclick="window.print()">
<i class="bi bi-printer me-1"></i>Print
</button>
</div>
<div class="card shadow-sm mb-3">
<div class="card-body">
<div class="row">
<div class="col-md-6">
<h5 class="fw-semibold">@Model.Account?.Name</h5>
<p class="text-muted mb-0">Statement Date: @Model.StatementDate.ToString("MMMM d, yyyy")</p>
@if (Model.CompletedAt.HasValue)
{
<p class="text-muted small">Completed by @Model.CompletedBy on @Model.CompletedAt.Value.ToLocalTime().ToString("MMM d, yyyy")</p>
}
</div>
<div class="col-md-6 text-md-end">
<table class="table table-sm table-borderless mb-0 ms-auto" style="width:auto">
<tr>
<td class="text-muted">Beginning Balance:</td>
<td class="fw-semibold text-end">@Model.BeginningBalance.ToString("C")</td>
</tr>
<tr>
<td class="text-muted">+ Cleared Deposits:</td>
<td class="fw-semibold text-end text-success">@clearedDeposits.Sum(p => p.Amount).ToString("C")</td>
</tr>
<tr>
<td class="text-muted">&ndash; Cleared Payments:</td>
<td class="fw-semibold text-end text-danger">@clearedPayments.Sum(p => p.Amount).ToString("C")</td>
</tr>
<tr class="border-top">
<td class="fw-semibold">Statement Ending Balance:</td>
<td class="fw-bold text-end">@Model.EndingBalance.ToString("C")</td>
</tr>
</table>
</div>
</div>
</div>
</div>
<div class="row g-3">
<div class="col-md-6">
<div class="card shadow-sm">
<div class="card-header fw-semibold">Cleared Deposits (@clearedDeposits.Count())</div>
<div class="card-body p-0">
<table class="table table-sm mb-0">
<thead class="table-light"><tr><th>Date</th><th>Reference</th><th class="text-end">Amount</th></tr></thead>
<tbody>
@foreach (var p in clearedDeposits.OrderBy(p => p.PaymentDate))
{
<tr>
<td class="small">@p.PaymentDate.ToString("MMM d")</td>
<td class="small">@p.Reference</td>
<td class="text-end">@p.Amount.ToString("C")</td>
</tr>
}
</tbody>
<tfoot class="table-light fw-semibold">
<tr><td colspan="2" class="text-end">Total</td><td class="text-end">@clearedDeposits.Sum(p=>p.Amount).ToString("C")</td></tr>
</tfoot>
</table>
</div>
</div>
</div>
<div class="col-md-6">
<div class="card shadow-sm">
<div class="card-header fw-semibold">Cleared Payments (@clearedPayments.Count)</div>
<div class="card-body p-0">
<table class="table table-sm mb-0">
<thead class="table-light"><tr><th>Date</th><th>Reference</th><th class="text-end">Amount</th></tr></thead>
<tbody>
@foreach (var p in clearedPayments)
{
<tr>
<td class="small">@p.Date.ToString("MMM d")</td>
<td class="small">@p.Reference</td>
<td class="text-end">@p.Amount.ToString("C")</td>
</tr>
}
</tbody>
<tfoot class="table-light fw-semibold">
<tr><td colspan="2" class="text-end">Total</td><td class="text-end">@clearedPayments.Sum(p=>p.Amount).ToString("C")</td></tr>
</tfoot>
</table>
</div>
</div>
</div>
</div>
@if (!string.IsNullOrWhiteSpace(Model.Notes))
{
<div class="card shadow-sm mt-3">
<div class="card-header fw-semibold">Notes</div>
<div class="card-body">@Model.Notes</div>
</div>
}