Update perbaikan migration specimen, dummy seeder dan indentasi model patisit
This commit is contained in:
parent
70de4fcfc6
commit
341db47380
@ -63,7 +63,7 @@ class CreateSpecimenTable extends Migration {
|
|||||||
'EndDate' => ['type' => 'DATETIME', 'null' => true],
|
'EndDate' => ['type' => 'DATETIME', 'null' => true],
|
||||||
'ArchiveDate' => ['type' => 'DATETIME', 'null' => true]
|
'ArchiveDate' => ['type' => 'DATETIME', 'null' => true]
|
||||||
]);
|
]);
|
||||||
$this->forge->addKey('SpcStaSID', true);
|
$this->forge->addKey('SpcStaID', true);
|
||||||
$this->forge->createTable('specimenstatus');
|
$this->forge->createTable('specimenstatus');
|
||||||
|
|
||||||
$this->forge->addField([
|
$this->forge->addField([
|
||||||
|
|||||||
@ -5,6 +5,7 @@ namespace App\Database\Seeds;
|
|||||||
use CodeIgniter\Database\Seeder;
|
use CodeIgniter\Database\Seeder;
|
||||||
|
|
||||||
class DummySeeder extends Seeder {
|
class DummySeeder extends Seeder {
|
||||||
|
|
||||||
public function run() {
|
public function run() {
|
||||||
// location
|
// location
|
||||||
$data = [
|
$data = [
|
||||||
@ -18,6 +19,13 @@ class DummySeeder extends Seeder {
|
|||||||
];
|
];
|
||||||
$this->db->table('locationaddress')->insertBatch($data);
|
$this->db->table('locationaddress')->insertBatch($data);
|
||||||
|
|
||||||
|
// users
|
||||||
|
$data = [
|
||||||
|
['id'=>1, 'role_id'=>1, 'username'=>'zaka', 'password'=>'$2y$12$vSB7PpKOUKEyFKbeExiGkuujRfQbR.yl6YVudDpfy24FemZopBG0m'],
|
||||||
|
['id'=>2, 'role_id'=>1, 'username'=>'tes' , 'password'=>'$2y$12$KwPedIPb7K/0IR/8/FcwdOMG4eBNNAXSjXnbkB26SwjH4Nf7PaYBe']
|
||||||
|
];
|
||||||
|
$this->db->table('users')->insertBatch($data);
|
||||||
|
|
||||||
// contact
|
// contact
|
||||||
$data = [
|
$data = [
|
||||||
['ContactID'=>1, 'NameFirst'=>'Default', 'NameLast'=>'Doctor', 'Title'=>'', 'Initial'=>'DEFDOC',
|
['ContactID'=>1, 'NameFirst'=>'Default', 'NameLast'=>'Doctor', 'Title'=>'', 'Initial'=>'DEFDOC',
|
||||||
|
|||||||
@ -6,9 +6,9 @@ use CodeIgniter\Model;
|
|||||||
use App\Models\CounterModel;
|
use App\Models\CounterModel;
|
||||||
|
|
||||||
class PatVisitModel extends Model {
|
class PatVisitModel extends Model {
|
||||||
protected $table = 'patvisit';
|
protected $table = 'patvisit';
|
||||||
protected $primaryKey = 'InternalPVID';
|
protected $primaryKey = 'InternalPVID';
|
||||||
protected $allowedFields = ['PVID', 'InternalPID', 'EpisodeID', 'EndDate'];
|
protected $allowedFields = ['PVID', 'InternalPID', 'EpisodeID', 'EndDate'];
|
||||||
protected $db;
|
protected $db;
|
||||||
protected $visnum_prefix;
|
protected $visnum_prefix;
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user