Initial commit

This commit is contained in:
Porawit Dongwang
2026-09-16 23:20:08 +07:00
commit 0041668dbb
32577 changed files with 3687927 additions and 0 deletions
@@ -0,0 +1,23 @@
<?php
// models/Patient.php
// Mock class to simulate HIS Integration
class Patient {
// In a real application, this would connect to the HIS Database (e.g., HOSxP)
// using a separate PDO connection in Read-Only mode.
public static function searchByHN($hn) {
// Mock data
$mock_patients = [
'123456' => ['hn' => '123456', 'name' => 'นายใจดี รักสงบ', 'age' => 45, 'gender' => 'ชาย'],
'654321' => ['hn' => '654321', 'name' => 'ด.ญ.มานี มีตา', 'age' => 8, 'gender' => 'หญิง'],
'987654' => ['hn' => '987654', 'name' => 'นายสมหมาย สบายใจ', 'age' => 60, 'gender' => 'ชาย']
];
if (isset($mock_patients[$hn])) {
return $mock_patients[$hn];
}
return null;
}
}