Paradaux

PAR-10

0

Ability to add a memo for /firm deposit

DoneNormalrianBusinessFeature

Allow an optional memo/note when using /firm deposit, so the deposit shows a reason in transaction history.

Technical notes — The TransferRequest ledger-message field already exists and is rendered in history (MiscCommands.transactions shows the message column), but FirmTransactionServiceImpl.deposit hardcodes "Business deposit". Add an optional greedy memo arg to the deposit route (@Route("deposit <firm> <amount> <memo>")), thread it through deposit(…, String memo) into the TransferRequest message (fallback to "Business deposit"). Small and self-contained.

Resources

Comments

tesks · Jun 4, 2026, 9:56 AM

Code context — The TransferRequest ledger-message field already exists and is rendered in history (MiscCommands.transactions shows the message column), but FirmTransactionServiceImpl.deposit hardcodes "Business deposit".

Approach: add an optional greedy memo arg to the deposit route (@Route("deposit <firm> <amount> <memo>")), thread it through deposit(…, String memo) into the TransferRequest message (fallback to "Business deposit" when absent). Small, self-contained.

tesks · Jun 5, 2026, 7:33 AM

Implemented on develop (commit ba188aa).

/firm deposit <firm> <amount> [memo…] — added a greedy-<memo> route alongside the existing two-arg form. The note is recorded as the Treasury transfer reason, so deposits show up in transaction history annotated (e.g. "Business deposit: payroll top-up").

  • FirmTransactionService.deposit(firmId, player, amount, memo) overload added; the old three-arg method delegates with null.
  • Memo is whitespace-collapsed + trimmed; the composed reason is capped to the VARCHAR(255) reason column. Blank/null memo → unchanged "Business deposit".
  • Command refactored to a shared doDeposit(...) helper so both routes share one body.

Tests: added 3 cases to FirmTransactionServiceImplTest (memo recorded + sanitized, blank-memo fallback, overlong-memo cap). Coverage gate (≥95%) green.

Activity

  • ParadauxIO linked a commit — Commit ba188aa — Allow an optional memo on /firm deposit (PAR-10)
  • ParadauxIO changed status to Status → Done
  • ParadauxIO linked a pull request — PR #6 merged — Release: develop → main
  • ParadauxIO linked a pull request — PR #6 open — Release: develop → main
  • ParadauxIO linked a pull request — PR #6 open — Release: develop → main
  • ParadauxIO linked a pull request — PR #6 open — Release: develop → main
  • ParadauxIO linked a pull request — PR #6 open — Release: develop → main
  • ParadauxIO linked a pull request — PR #6 open — Release: develop → main
  • ParadauxIO linked a pull request — PR #6 open — Release: develop → main
  • tesks commented
  • tesks changed status to Status → Pending Release
  • ParadauxIO linked a commit — Commit ba188aa — Allow an optional memo on /firm deposit (PAR-10)
  • tesks description: Description updated
  • tesks commented
  • tesks assigned Assigned to rian