Skip to content

310 — should add and edit linked time records on an item

Description

Verifies that an invoice item can have one time record linked, then be reopened to link a second one, and the item's price and final price track the sum of the linked time records' billable amounts.

Preconditions

  • Signed-in tenant with Client 01, two billable time records (Private 01 €480.00 and Private 04 €2,880.00), and the user on the new invoice form past the client step.

Steps

  1. Click Add item, type the item name, then open the Time records link picker. Expected: 2 unselected and 0 selected time records.
  2. Check Private 04. Expected: the selection bar reads 1 selected | €2,880.00. Click Add selected. Expected: 1 selected, 1 unselected. Save the picker.
  3. Expected: the item shows the time-records link count 1, the time-records total 2,880.00, item price 2880, and final price 2880.
  4. Reopen the Time records link picker. Expected: 1 unselected and 1 selected. Check Private 01. Expected: the selection bar reads 1 selected | €480.00. Click Add selected. Expected: 2 selected, 0 unselected. Save the picker.
  5. Expected: the time-records link count is 2, time-records total reads 3,360.00, item price 3360, and final price 3360.
  • Spec: playwright/tests/integration/invoice.spec.ts (line 336)