- Public display

This commit is contained in:
Ty Clifford
2026-07-03 18:00:34 -04:00
parent c5ec4f4c7e
commit 90b1194b65
16 changed files with 237 additions and 49 deletions
+27 -6
View File
@@ -18,7 +18,7 @@ http://127.0.0.1:8080
## Public Routes
- `/` - medical reference hub with search, database totals, and links to tracker/admin tools.
- `/` - medical reference hub with search, database totals, and optional tracker/admin links when enabled.
- `/nutrition.php` - searchable medicine catalog.
- `/medicine.php?id=46` - dynamic medicine detail page backed by SQLite.
- `/symptoms.php` - searchable symptom reference database.
@@ -28,9 +28,28 @@ http://127.0.0.1:8080
- `/medical.php` - combined search for symptoms, terminology, conditions, medicines, and study links.
- `/term.php?id=1` - dynamic medical terminology detail page backed by SQLite.
- `/recovery.php` - NIH/NLM research and study-link categories.
- `/tracker.php` - profile-scoped medical tracker dashboard.
- `/admin.php` - admin user-management dashboard and medicine-source updater.
- `/signup.php` - legacy route that redirects to `/tracker.php`; public signup has been removed.
- `/tracker.php` - profile-scoped medical tracker dashboard when enabled.
- `/admin.php` - admin user-management dashboard and medicine-source updater when enabled.
- `/signup.php` - legacy route that redirects to `/tracker.php` when tracker is enabled, otherwise `/`; public signup has been removed.
## Public Access Toggle
Private profile tools are controlled by:
```text
config/public-access.json
```
The default public-safe configuration is:
```json
{
"admin_area_enabled": false,
"tracker_area_enabled": false
}
```
When an area is disabled, its navigation links are hidden, direct page visits return a disabled public page, and related API write endpoints return `403`. Set either value to `true` to re-enable that area.
## Current Data
@@ -96,13 +115,15 @@ public/api.php
Useful actions:
- `GET api.php?action=state` - tracker/admin state payload.
- `GET api.php?action=state` - tracker/admin state payload when at least one private area is enabled.
- `GET api.php?action=library_search&q=chest&limit=20` - combined reference search.
- `POST api.php?action=create_user` - create a user profile from admin/tracker tools.
- `POST api.php?action=update_user` - update a user profile.
- `POST api.php?action=delete_user` - delete a user profile.
- `POST api.php?action=refresh_medication_sources` - refresh the medicine catalog from configured public sources.
Private-area API actions return `403` when the matching Admin or Tracker toggle is disabled.
The old `public_signup` action has been removed.
## Reference Sources
@@ -118,6 +139,6 @@ The old `public_signup` action has been removed.
## Notes
- This project intentionally avoids a public signup funnel. Profiles are managed through `/admin.php` and `/tracker.php`.
- This project intentionally avoids a public signup funnel. Profiles are managed through `/admin.php` and `/tracker.php` only when those private areas are enabled.
- Dynamic detail pages use shared PHP endpoints and pull records from SQLite; individual medicine, symptom, condition, and term pages do not need to exist as separate files.
- Legacy workout, nutrition, and supplement tracker data remains in the schema as wellness context, but the public app focus is now medical tracking and reference lookup.