Files
medicaltracker/CHANGELOG.md
T
Ty Clifford c1cb93083e - Fixed. Medicines now show “what it is used for” from official label data when available, with curated/common-use text as the fallback.
Changed:
Added official_use, source name, and source URL fields to the medicine 
schema in [app/bootstrap.php (line 
200)](/Users/tyemeclifford/Documents/GH/workout/app/bootstrap.php:200).
Added shared display helpers and API used_for output in 
[app/bootstrap.php (line 
1848)](/Users/tyemeclifford/Documents/GH/workout/app/bootstrap.php:1848).
Updated openFDA imports to pull indications_and_usage first, then 
purpose, and store source links in [app/bootstrap.php (line 
3060)](/Users/tyemeclifford/Documents/GH/workout/app/bootstrap.php:3060).
Updated the medicine detail page to show “What It Is Used For” plus the 
openFDA label link in [public/medicine.php (line 
72)](/Users/tyemeclifford/Documents/GH/workout/public/medicine.php:72).
Updated catalog/list contexts to use the same helper, including 
[public/nutrition.php (line 
66)](/Users/tyemeclifford/Documents/GH/workout/public/nutrition.php:66).
Updated docs/counts in [README.md (line 
45)](/Users/tyemeclifford/Documents/GH/workout/README.md:45) and 
[CHANGELOG.md (line 
15)](/Users/tyemeclifford/Documents/GH/workout/CHANGELOG.md:15).
Database is updated to 7,646 medicines, with 200 openFDA label-derived 
use summaries, 8,077 medicine-condition links, and 10,590 
medicine-symptom links.
Verified:
Refreshed openFDA label-use data with 
scripts/update_medicine_catalog.php 200 openFDA.
/medicine.php?id=7644, /medicine.php?id=6, 
/nutrition.php?q=serdexmethylphenidate, 
/api.php?action=library_search&q=ADHD&limit=5, and / all returned 200.
Confirmed the page shows “What It Is Used For”, “Used for: ...”, and an 
openFDA label source link.
Stock php -l was not available in this workspace, but the FrankenPHP 
bootstrap and route/API smoke tests executed successfully.
Sources used: openFDA drug label fields and openFDA query parameters.
2026-07-03 16:34:31 -04:00

116 lines
8.5 KiB
Markdown

# Changelog
All notable changes to Neon Medical Tracker are documented here.
## [Unreleased] - 2026-07-03
### Added
- Added generated medicine-to-condition and medicine-to-symptom relationship tables.
- Added dynamic medicine detail sections for linked conditions and linked symptom contexts.
- Added dynamic condition and symptom sections for commonly linked medicines.
- Added therapeutic-use enrichment rules so imported medicine rows can show practical common-use context when a clear category match exists.
- Added expanded condition and symptom seed coverage across cardiovascular, respiratory, endocrine, GI, kidney, neurologic, mental health, dermatology, infectious disease, immune, ENT, reproductive, and general medical topics.
- Added openFDA brand-name and substance-name buckets to the medicine source updater.
- Added official medicine-use fields and source links populated from openFDA drug label `indications_and_usage` or `purpose` text.
- Added computed `used_for` values to medicine API payloads so clients can display official label use text when available.
### Changed
- Increased the current SQLite snapshot to 7,646 medicines, 283 conditions, and 308 symptoms, including 200 openFDA label-derived use summaries.
- Rebuilt generated relationship data to 8,077 medicine-to-condition links and 10,590 medicine-to-symptom links.
- Updated medical library search so medicine searches can match linked conditions/symptoms, and condition/symptom searches can match linked medicines.
- Updated medicine catalog, medicine detail, condition, symptom, terminology, and combined-library pages to show "what it is used for" text through one shared helper.
- Updated relationship generation so official medicine-use label text participates in condition and symptom linking.
- Updated openFDA refreshes to fetch label documents first, then fall back to generic, brand, and substance buckets for broader coverage.
- Batched imported medicine upserts inside a SQLite transaction for faster source refreshes.
- Increased SQLite busy timeout for safer first-run migrations and source refreshes.
- Updated `README.md` with current counts, relationship data, and source-refresh behavior.
### Fixed
- Cleaned generated search terms when therapeutic relationship rules change so removed links do not linger in search.
- Tightened relationship rules to avoid broad steroid and chemistry keyword false positives.
- Fixed medicine pages that previously depended on `common_use` only, so medicines now show official "used for" text whenever it exists.
### Verified
- Refreshed public medicine sources with a 500-row-per-source run across RxNorm, DailyMed, and openFDA.
- Refreshed openFDA label-use data with a 200-row run and verified 200 medicine rows have official use summaries.
- Verified `/medicine.php?name=albuterol`, `/condition.php?name=Asthma`, `/symptom.php?name=Wheezing`, and `api.php?action=library_search&q=asthma&limit=10` return `200`.
- Verified official-use medicine pages expose "What It Is Used For", `Used for:` label text, and an openFDA drug label source link.
- Verified albuterol medicine pages show linked Asthma/Wheezing records and Asthma/Wheezing pages show linked albuterol medicines.
- Verified stale adalimumab-to-asthma and celecoxib-to-UTI false positives are removed.
## [Unreleased] - 2026-06-30
### Added
- Added a public medical reference hub at `/` focused on medicines, symptoms, terminology, conditions, research, tracker access, and admin access.
- Added a searchable medicine catalog with thousands of records and dynamic medicine detail pages at `/medicine.php?id=...`.
- Added medicine detail fields for active ingredient, chemical name, common brand names, generic/alternate names, class, family, tracking notes, and external reference links.
- Added public medicine-source refresh support through the admin dashboard and `scripts/update_medicine_catalog.php`.
- Added data import/update support for RxNorm, DailyMed, and openFDA.
- Added a searchable symptom reference database at `/symptoms.php`.
- Added dynamic symptom detail pages at `/symptom.php?id=...`.
- Added 242 seeded symptom records grouped by body system/category, with tracking notes, urgency-context notes, search terms, and MedlinePlus links.
- Added a searchable condition reference database at `/workouts.php`.
- Added dynamic condition detail pages at `/condition.php?id=...`.
- Added 203 seeded condition records grouped by clinical category, with overviews, tracking notes, and MedlinePlus links.
- Added dynamic medical terminology detail pages at `/term.php?id=...`.
- Added combined medical library search across symptoms, terminology, conditions, medicines, and research-study links.
- Added search-result ordering so direct symptom and condition name matches rank above broad category/overview matches.
- Added related-record sections on dynamic detail pages, linking conditions, symptoms, terms, medicines, and research records where available.
- Added admin dashboard support for managing profiles and refreshing medication sources.
- Added profile-scoped medical tracker data for medication logs, vitals, labs, symptoms, allergies, appointments, immunizations, and notes.
- Added route documentation for all dynamic medicine, symptom, condition, and terminology endpoints.
- Added responsive overflow protections for long chemical names, brand names, reference URLs, symptoms, conditions, and directory rows.
### Changed
- Renamed the project focus from a workout/nutrition tracker to a medical tracker and medical reference database.
- Reworked the homepage from a marketing-style landing page into a direct medical reference hub.
- Reworked `/nutrition.php` from nutrition tracking content into the medicine catalog route.
- Reworked `/workouts.php` from workout planning content into the condition database route while keeping the legacy URL for compatibility.
- Reworked `/medical.php` into a combined searchable library for symptoms, terms, conditions, medicines, and study links.
- Reworked medicine and terminology list views from dense cards into compact searchable directory rows with dynamic detail links.
- Updated profile management so public profile creation is no longer part of the site flow; profile creation is handled through admin/tracker tools.
- Updated `README.md` to match the current medical-reference app, current routes, current data counts, source update process, and API actions.
- Preserved legacy fitness, nutrition, supplement, routine, workout, and body-metric data structures as optional wellness context inside the tracker.
### Removed
- Removed the public signup form and public signup JavaScript.
- Removed the `public_signup` API action.
- Removed signup links from the public header, footer, homepage, and condition pages.
- Removed unused signup/showcase CSS from the public stylesheet.
- Replaced `/signup.php` with a simple redirect to `/tracker.php` for legacy links.
### Fixed
- Fixed text overflow on long medicine names, chemical names, brand lists, source URLs, and compact database rows.
- Fixed searchable medicine and terminology pages so entries have shareable dynamic pages instead of only inline catalog cards.
- Fixed condition and symptom search behavior so relevant name matches appear first.
- Reduced one-time SQLite seeding lock risk by wrapping symptom catalog seeding in a short transaction and skipping once populated.
### Verified
- Verified dynamic medicine, symptom, condition, and terminology routes return `200` for representative records.
- Verified legacy `/signup.php` returns `302` to `/tracker.php`.
- Verified `api.php?action=public_signup` returns `404`.
- Verified then-current SQLite snapshot counts: 6,002 medicines, 242 symptoms, 203 conditions, 23 terms, and 9 research-link categories.
- Verified browser layout checks for medicine, symptom, and terminology pages at desktop and mobile widths with no horizontal overflow.
## Earlier Scope
### Added
- Added the original multi-user tracker foundation with SQLite storage.
- Added user profiles with role, status, contact details, care focus, height, theme mode, and accent color.
- Added first-user-is-admin behavior.
- Added admin user-management dashboard.
- Added daily, weekly, and monthly planning views.
- Added workout, routine, exercise, nutrition goal, nutrition log, supplement, supplement log, body metric, medication log, vital log, lab result, symptom log, allergy, appointment, and immunization tables.
- Added built-in exercise and supplement libraries.
- Added neon theme styling with dark mode default, light mode support, and green, blue, red, pink, and orange accents.