a2n-seattle / a2n-seattle/rms-app

Add a UI flow for creating batches

Open
#364 2 comments 0 reactions 0 assignees View on GitHub
idea priority-low
Dominant language
TypeScript
Stars
1
Forks
1
Avg merge
27m
Merged PRs (30d)
4

Description

# Why?

**As a** user managing inventory
**I want** a way to create a batch from the web frontend
**So that** batches don't need to be created out-of-band (e.g. directly against DynamoDB or only via the old Retool app).

# What?

The backend already supports batches (`BatchSchema`, `CreateBatch`/`DeleteBatch`/`GetBatch`/`ListBatches` APIs all exist per `ts-code/src/api/` and `ts-code/src/db/Schemas.ts`), and the Batches tab/view already exists as a read view (Phase 5/#337). Add a **create batch** flow to that Batches page:
- A form/modal to create a new batch, wired to the existing `CreateBatch` API.
- Likely also a delete-batch action per row, wired to the existing `DeleteBatch` API, since "add" without any way to remove a mistaken batch is a partial feature.

Clarify during triage the exact fields `CreateBatch` needs from the user (check `ts-code/src/api/CreateBatch.ts`'s input shape) and whether batch creation should let the user assign items to it at creation time or only afterward (via the item edit flow from #363, once that exists).

# Testing

Jest/RTL for the create-batch form. Playwright e2e: create a batch, confirm it appears in the Batches list; delete it, confirm it's removed.

# Additional context

Depends on the Batches view (#337, merged). May overlap with #363 if batch-assignment is done through item editing — worth sequencing after #363 during implementation if so.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.