remove codeigniter

This commit is contained in:
root
2026-06-04 02:41:08 -04:00
parent 4e33882ac7
commit b4e6ac03c5
180 changed files with 457 additions and 2186 deletions
+3 -4
View File
@@ -5,7 +5,7 @@
- **Purpose**: shared API conveniences:
- Standard success/error JSON envelope helpers
- Request payload normalization (JSON body vs query/form)
- Validation helper compatible with legacy CodeIgniter-like rules
- Validation helper compatible with legacy-style rules
- Lightweight pagination helper for arrays/query builders
- Current-user resolution helpers (id + role list)
@@ -18,14 +18,14 @@
### Request normalization
- Stores the underlying Laravel request as `laravelRequest`.
- Wraps it in `CiRequestAdapter` as `$this->request` for compatibility patterns.
- Wraps it in `request adapter` as `$this->request` for compatibility patterns.
- `payloadData()`:
- Uses JSON-decoded body when present and valid
- Falls back to merged query + form data
### Validation
- `validateRequest($data, $rules)`:
- Normalizes CodeIgniter-like rule strings into Laravel rules via `normalizeRules()`.
- Normalizes legacy-like rule strings into Laravel rules via `normalizeRules()`.
- Saves validator to `$this->validator`.
- Returns `[]` on success, or `errors()->toArray()` on failure.
- `validate($rules)` validates against `payloadData()` and returns boolean.
@@ -63,4 +63,3 @@
- `getCurrentUser()`:
- No auth → `null`
- Role query failure → returns user with empty roles and logs error