Skip to content

654 — Recalculate approved records (approval does not block recalculation)

Description

Recalculate's filter (findRecalculableTimeRecordIds) excludes only billed/deleted records — not approved ones. So unlike bulk edit (which a single approved record blocks entirely), recalculate applies to approved records too.

Preconditions

  • Signed in to a freshly seeded test organization.
  • Three time records seeded via the GraphQL API (no hourly rate), all owned by the owner.
  • A user-scoped billable rate exists (created after seeding).
  • One of the records is approved via the API.
  • Time Records page open in the Reports view.

Steps

  1. Confirm each record's Hourly Rate is "€ 0.00".
  2. Tick the selection checkbox on all three rows. Expected: the floating bar shows "3 selected".
  3. Click the recalculate-rates action and confirm the modal with Recalculate. Expected: "Success" popup appears.
  4. Inspect the rows. Expected: every record — including the approved one — now has a non-zero hourly rate.
  • Spec: playwright/tests/integration/timerecord.spec.ts (describe "Timerecord - Bulk edit")
  • Contrast: bulk edit blocks approved records (TIME_RECORD_APPROVED); recalculate does not.