2.2 KiB
2.2 KiB
title, status, owner, created_at, related
| title | status | owner | created_at | related | ||
|---|---|---|---|---|---|---|
| Task: Frontend Refactoring for Schema v1.7.0 | IN_PROGRESS | Frontend Team | 2025-12-23 |
|
Objective
Update frontend application to align with the refactored backend (v1.7.0 schema). This includes supporting new field mappings, new As Built drawing type, and updated document numbering logic.
Scope of Work
1. Type Definitions & API Client
- Types: Update
Drawing,ContractDrawing,ShopDrawinginterfaces to match new backend entities (e.g.mapCatId,projectIdin categories). - API: Update
drawing.service.tsto support new filter parameters (mapCatId) and new endpoints for As Built drawings.
2. Drawing Upload Form (DrawingUploadForm)
- General: Refactor to support dynamic fields based on Drawing Type.
- Contract Drawings:
- Replace
subCategoryIdwithmapCatId(fetch fromcontract-drawing-categories?). - Add
volumePageinput.
- Replace
- Shop Drawings:
- Remove
sheetNumber(if not applicable) or map tolegacyDrawingNumber. - Add
legacyDrawingNumberinput. - Handle
titleinput (sent as revision title). - Use Project-specific categories.
- Remove
- As Built Drawings (New):
- Add "AS_BUILT" option.
- Implement form fields similar to Shop Drawings (or Contract depending on spec).
3. Drawing List & Views (DrawingList)
- Contract Drawings: Show
volumePage. - Shop Drawings:
- Display
legacyDrawingNumber. - Display Title from Current Revision.
- Remove direct title column from sort/filter if backend doesn't support it anymore on master.
- Display
- As Built Drawings:
- Add new Tab/Page for As Built.
- Implement List View.
4. Logic & Hooks
- Update
useDrawings,useCreateDrawinghooks to handle new types. - Ensure validation schemas (
zod) match backend constraints.
Definition of Done
- Contract Drawing Upload works with
mapCatIdandvolumePage - Shop Drawing Upload works with
legacyDrawingNumberand Revision Title - As Built Drawing Upload and List implemented
- Drawing List displays correct columns for all types
- No TypeScript errors