chore(legacy): relocate v1 dataconnect source
This commit is contained in:
@@ -1,5 +1,9 @@
|
||||
# Data Connect Connectors Pattern
|
||||
|
||||
> [!WARNING]
|
||||
> This document describes the legacy V1 Data Connect connector pattern.
|
||||
> For current backend work, use the V2 unified API docs under `docs/BACKEND/API_GUIDES/V2/`.
|
||||
|
||||
## Overview
|
||||
|
||||
This document describes the **Data Connect Connectors** pattern implemented in the KROW mobile app. This pattern centralizes all backend query logic by mirroring backend connector structure in the mobile data layer.
|
||||
@@ -45,9 +49,9 @@ apps/mobile/packages/data_connect/lib/src/connectors/
|
||||
└── ...
|
||||
```
|
||||
|
||||
**Maps to backend structure:**
|
||||
**Maps to legacy backend structure:**
|
||||
```
|
||||
backend/dataconnect/connector/
|
||||
legacy/dataconnect-v1/connector/
|
||||
├── staff/
|
||||
├── order/
|
||||
├── user/
|
||||
@@ -260,7 +264,7 @@ When backend adds new connector (e.g., `order`):
|
||||
- `staff_main` - Guards bottom nav items requiring profile completion
|
||||
|
||||
**Backend Queries Used**:
|
||||
- `backend/dataconnect/connector/staff/queries/profile_completion.gql`
|
||||
- `legacy/dataconnect-v1/connector/staff/queries/profile_completion.gql`
|
||||
|
||||
### Shifts Connector
|
||||
|
||||
@@ -271,15 +275,15 @@ When backend adds new connector (e.g., `order`):
|
||||
- `applyForShifts()` - Handles shift application with error tracking
|
||||
|
||||
**Backend Queries Used**:
|
||||
- `backend/dataconnect/connector/shifts/queries/list_shift_roles_by_vendor.gql`
|
||||
- `backend/dataconnect/connector/shifts/mutations/apply_for_shifts.gql`
|
||||
- `legacy/dataconnect-v1/connector/shifts/queries/list_shift_roles_by_vendor.gql`
|
||||
- `legacy/dataconnect-v1/connector/shifts/mutations/apply_for_shifts.gql`
|
||||
|
||||
## Future Expansion
|
||||
|
||||
As the app grows, additional connectors will be added:
|
||||
- `order_connector_repository` (queries from `backend/dataconnect/connector/order/`)
|
||||
- `user_connector_repository` (queries from `backend/dataconnect/connector/user/`)
|
||||
- `emergency_contact_connector_repository` (queries from `backend/dataconnect/connector/emergencyContact/`)
|
||||
- `order_connector_repository` (queries from `legacy/dataconnect-v1/connector/order/`)
|
||||
- `user_connector_repository` (queries from `legacy/dataconnect-v1/connector/user/`)
|
||||
- `emergency_contact_connector_repository` (queries from `legacy/dataconnect-v1/connector/emergencyContact/`)
|
||||
- etc.
|
||||
|
||||
Each following the same Clean Architecture pattern implemented for Staff Connector.
|
||||
|
||||
Reference in New Issue
Block a user