Skip to content

Add edit and delete controls to all holding lot cards #70

@heyitsStylez

Description

@heyitsStylez

Parent

#68

What to build

Two holding card UI changes in the render-table module, both targeting lot.tradeIds[0] (the source trade of the lot):

  1. Edit button — currently only rendered when the source trade is type === 'HOLDING'. Remove this gate so the edit button appears on every holding card, including ASSIGNED-derived lots. The existing edit modal already handles all relevant fields.

  2. Delete button — no holding card currently has one. Add a delete button alongside the edit button on every card. Clicking it calls the existing delete function on the source trade ID. A toast should fire on success (the existing delete function already does this).

Both buttons must appear for all lot types — manually-entered HOLDING trades and ASSIGNED-derived lots alike.

Run python3 build.py --check and npm test after changes.

Acceptance criteria

  • Every holding lot card has an edit button, regardless of whether the lot was opened by a HOLDING trade or an ASSIGNED PUT
  • Every holding lot card has a delete button
  • Clicking edit on an ASSIGNED-derived lot card opens the edit modal on the underlying PUT trade
  • Clicking delete removes the trade and triggers a toast confirmation
  • The deleted trade's txHash is NOT removed from hw_synced_v1 (existing deleteTrade behaviour — must not be broken)
  • python3 build.py --check passes
  • npm test passes

Blocked by

None — can start immediately

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions