124 Commits

Author SHA1 Message Date
bb7df6b70c feat(valueset): refactor from ID-based to name-based lookups
Complete overhaul of the valueset system to use human-readable names
instead of numeric IDs for improved maintainability and API consistency.
- PatientController: Renamed 'Gender' field to 'Sex' in validation rules
- ValuesetController: Changed API endpoints from ID-based (/:num) to name-based (/:any)
- TestsController: Refactored to use ValueSet library instead of direct valueset queries
- Added ValueSet library (app/Libraries/ValueSet.php) with static lookup methods:
  - getOptions() - returns dropdown format [{value, label}]
  - getLabel(, ) - returns label for a value
  - transformLabels(, ) - batch transform records
  - get() and getRaw() for Lookups compatibility
- Added ValueSetApiController for public valueset API endpoints
- Added ValueSet refresh endpoint (POST /api/valueset/refresh)
- Added DemoOrderController for testing order creation without auth
- 2026-01-12-000001: Convert valueset references from VID to VValue
- 2026-01-12-000002: Rename patient.Gender column to Sex
- OrderTestController: Now uses OrderTestModel with proper model pattern
- TestsController: Uses ValueSet library for all lookup operations
- ValueSetController: Simplified to use name-based lookups
- Updated all organization (account/site/workstation) dialogs and index views
- Updated specimen container dialogs and index views
- Updated tests_index.php with ValueSet integration
- Updated patient dialog form and index views
- Removed .factory/config.json and CLAUDE.md (replaced by AGENTS.md)
- Consolidated lookups in Lookups.php (removed inline valueset constants)
- Updated all test files to match new field names
- 32 modified files, 17 new files, 2 deleted files
- Net: +661 insertions, -1443 deletions (significant cleanup)
2026-01-12 16:53:41 +07:00
f11bde4d30 refactor(valueset): simplify API response by removing pagination
- Remove pagination from ValueSetController::index() and ValueSetModel::getValueSets()
     - Delete duplicate AGENTS.md documentation (consolidated into CLAUDE.md)
     - Update .gitignore to exclude .claude folder
     - Add CLAUDE.md with comprehensive agent instructions for Valueset queries
     - Document new Lookups static library in README.md
2026-01-09 16:58:43 +07:00
a47db49f81 feat: improve Location API error handling
- Add Phone/Email fields to LocationAddressModel allowedFields
- Fix saveLocation() to throw exceptions instead of returning error arrays
- Update controller to properly handle model responses
- Include actual database error message in transaction failures
2026-01-06 17:00:33 +07:00
cd65e91db1 refactor: Rename controllers to follow CodeIgniter 4 naming convention
- Rename all controllers from X.php to XController.php format
- Add new RefTxtModel for text-based reference ranges
- Rename group_dialog.php to grp_dialog.php and remove title_dialog.php
- Add comprehensive test suite for v2/master/TestDef module
- Update Routes.php to reflect controller renames
- Remove obsolete data files (clqms_v2.sql, lab.dbml)
2026-01-05 16:55:34 +07:00
97edfe50a8 feat: enhance Test Management module with improved UI and tests
- Refactor Tests.php controller with updated logic and error handling
- Update Test migration with schema improvements
- Enhance TestDefCalModel, TestDefGrpModel, TestDefTechModel with CRUD operations
- Improve TestMapModel with better test mapping relationships
- Redesign test dialog views (calc, group, param) with improved UX
- Update tests_index view with better data presentation
- Add CSS styles for test management UI components
- Add TestDefSiteTest feature test for site-based test definitions
- Add TestDefModelsTest unit test for model validation
- Remove obsolete Test Management.docx documentation
2026-01-02 08:33:22 +07:00
97451496c3 feat(tests): enhance Test Management module with v2 UI dialogs
- Add new dialog forms for test calc, group, param, and title management
- Refactor test_dialog.php to new location (master/tests/)
- Update TestDefCalModel, TestDefSiteModel, TestDefTechModel, TestMapModel
- Modify Tests controller and Routes for new dialog handlers
- Update migration schema for test definitions
- Add new styles for v2 test management interface
- Include Test Management documentation files
2025-12-30 16:54:33 +07:00
a94df3b5f7 **feat: migrate to v2 frontend with Alpine.js pattern**
- Introduce v2 views directory with Alpine.js-based UI components
- Add AuthV2 controller for v2 authentication flow
- Update PagesController for v2 routing
- Refactor ValueSet module with v2 dialogs and nested CRUD views
- Add organization management views (accounts, departments, disciplines, sites, workstations)
- Add specimen management views (containers, preparations)
- Add master views for tests and valuesets
- Migrate patient views to v2 pattern
- Update Routes and Exceptions config for v2 support
- Enhance CORS configuration
- Clean up legacy files (check_db.php, llms.txt, sanity.php, old views)
- Update agent workflow patterns for PHP Alpine.js
2025-12-30 14:30:35 +07:00
cb4181dbff refactor: restructure application architecture and consolidate controllers
- Consolidate page controllers into unified PagesController
- Remove deprecated V2 pages, layouts, and controllers (AuthPage, DashboardPage, V2Page)
- Add Edge resource with migration and model (EdgeResModel)
- Implement new main_layout.php for consistent page structure
- Reorganize patient views into dedicated module with dialog form
- Update routing configuration in Routes.php
- Enhance AuthFilter for improved authentication handling
- Clean up unused V2 assets (CSS, JS) and legacy images
- Update README.md with latest project information

This refactoring improves code organization, removes technical debt, and
establishes a cleaner foundation for future development.
2025-12-29 16:57:46 +07:00
118d490bbd refactor: update TestSeeder to use dynamic ValueSet lookups
- Implemented dynamic VID retrieval from ValueSetModel for all test definitions
- Aligned ResultType, RefType, and SpcType with the valueset table
- Updated sample data for Hematology, Chemistry, and Urinalysis tests
- Ensured consistency between ValueSetSeeder and TestSeeder data
2025-12-29 12:55:31 +07:00
9f83199ddf adding crud test, and some dummy data for all test 2025-12-17 10:06:05 +07:00
600f672831 add crud for test 2025-12-17 07:03:16 +07:00
6b83f332ea fix test seeder 2025-12-16 13:48:33 +07:00
d9f9768074 add parent to discipline 2025-12-08 11:21:48 +07:00
2b9a30a073 yes 2025-12-03 15:45:24 +07:00
b52726b694 fix location show 2025-12-02 14:48:30 +07:00
72002bd437 fix getcities by parent 2025-12-02 13:19:42 +07:00
8767b823ca fix getcities showing province 2025-12-02 13:14:23 +07:00
d4f5e8b16a fix areageo 2025-12-02 12:52:23 +07:00
d5fd300b6a new feature for suhu kuda 2025-12-02 09:29:42 +07:00
1755105af1 till discipline 2025-12-02 07:09:24 +07:00
09717bb081 gogogo 2025-12-01 16:47:52 +07:00
61f6c337ee fix db, and tests index show 2025-11-27 14:15:10 +07:00
mikael-zakaria
e342df68f6 Update Rules Patient Index menampilkan Gender 2025-11-24 15:38:12 +07:00
mikael-zakaria
5a3eb5a63d Update Rules Patient Identity Fix Version 2025-11-24 15:17:33 +07:00
mikael-zakaria
eae096a37c Merge branch 'main' of https://github.com/mahdahar/clqms-be 2025-11-20 09:35:46 +07:00
a0dee0f351 remove seq 2025-11-14 08:30:35 +07:00
mikael-zakaria
49a4d5b11f Merge branch 'main' of https://github.com/mahdahar/clqms-be 2025-11-13 15:05:49 +07:00
8af8fea0ba preworking pvadt 2025-11-13 13:49:24 +07:00
21abee1831 fix patvisit InternalPID 2025-11-12 16:02:31 +07:00
2096ede1e5 update patvisit 2025-11-12 15:58:01 +07:00
bfee374eef fix patvisit 2025-11-12 15:26:18 +07:00
a450392cfc standard crud for specimen and test 2025-11-10 16:02:52 +07:00
mikael-zakaria
97d92f7d59 Merge branch 'main' of https://github.com/mahdahar/clqms-be 2025-11-10 13:57:45 +07:00
0e4b9824f7 tod 2025-11-07 16:41:42 +07:00
a907fb675e add workstation enable text 2025-11-07 08:49:01 +07:00
687b853599 fix workstation show 2025-11-07 08:39:01 +07:00
5b3b2f6cff fix site index 2025-11-06 12:55:36 +07:00
8b41bfc6f1 update org, valueset 2025-11-06 12:28:42 +07:00
3e2db6a25c change accounts index 2025-11-05 15:14:30 +07:00
mikael-zakaria
c3189e45ff Merge branch 'main' of https://github.com/mahdahar/clqms-be 2025-11-05 15:04:49 +07:00
56b8012e4a update join account 2025-11-05 15:03:55 +07:00
8680454db3 fix account zip and parent 2025-11-05 10:35:15 +07:00
1cab4d6578 fix organization 2025-11-04 12:22:29 +07:00
mikael-zakaria
ff1b3e0e9b Merge branch 'main' of https://github.com/mahdahar/clqms-be 2025-11-04 09:42:15 +07:00
mikael-zakaria
f41fcad526 Update Zones (Skipped) 2025-11-04 09:42:03 +07:00
112e6ec311 add organization endpoint 2025-10-29 11:08:38 +07:00
4fea4e1385 fix pv showByPatient show latest id 2025-10-27 11:13:12 +07:00
d4c92af9e4 fix pvadt 2025-10-27 10:37:44 +07:00
d5c8cac5ec prework 2025-10-24 16:41:31 +07:00
a71a587573 add pva cr 2025-10-23 12:16:52 +07:00