From d228103a89185f2e53c4cf5e901d50f5d866cb03 Mon Sep 17 00:00:00 2001 From: Duidev Software House Date: Sat, 29 Nov 2025 21:54:46 +0700 Subject: [PATCH] update --- .../app/Http/Controllers/DokterController.php | 1 + .../Http/Controllers/FrontpageController.php | 5 +- .../app/Http/Controllers/ListController.php | 57 +++++++++ .../2024_12_28_142050_create_sirab_table.php | 1 + ...05_140423_create_rekapantibiotik_table.php | 3 + htdocs/database/seeders/DatabaseSeeder.php | 43 ++++--- htdocs/database/seeders/JawabanSeeder.php | 3 +- htdocs/resources/views/admin/sirab.blade.php | 19 ++- .../base/partials/header-plain.blade.php | 44 +++---- htdocs/resources/views/dokter/ppds.blade.php | 2 +- .../views/dokter/ppdsdeveloper.blade.php | 109 +++++++----------- 11 files changed, 169 insertions(+), 118 deletions(-) diff --git a/htdocs/app/Http/Controllers/DokterController.php b/htdocs/app/Http/Controllers/DokterController.php index d7bad610..721af67f 100644 --- a/htdocs/app/Http/Controllers/DokterController.php +++ b/htdocs/app/Http/Controllers/DokterController.php @@ -2020,6 +2020,7 @@ class DokterController extends Controller 'kodedok' => $row->kodedok, 'atu' => $row->atu, 'kelompok' => $row->kelompok, + 'setmanual' => $row->setmanual, 'antibiotikall' => $row->subantibiotik !== null && $row->subantibiotik !== '' ? $row->subantibiotik : $row->antibiotik, diff --git a/htdocs/app/Http/Controllers/FrontpageController.php b/htdocs/app/Http/Controllers/FrontpageController.php index 5b2ba909..df7f4c57 100644 --- a/htdocs/app/Http/Controllers/FrontpageController.php +++ b/htdocs/app/Http/Controllers/FrontpageController.php @@ -28,6 +28,7 @@ use App\PendaftaranOnListiner; use App\Subjawaban; use App\Organisms; use App\Dokter; +use App\SiraB; use Validator; use Session; use DateTime; @@ -193,6 +194,7 @@ class FrontpageController extends Controller 'antrkrmsitu' => 0, ]; $allOrganisms = Organisms::orderBy('name', 'ASC')->get(); + $allASTManual = SiraB::whereNotNull('setmanual')->select('setmanual')->orderBy('setmanual', 'ASC')->get(); $groupOrganisms = function ($kelompok) use ($allOrganisms) { $organisms = $allOrganisms->where('kelompok', $kelompok); if ($organisms->isEmpty()) { @@ -251,7 +253,8 @@ class FrontpageController extends Controller ]; foreach ($kelompokMapping as $key => $kelompok) { $data[$key] = $allOrganisms->where('kelompok', $kelompok)->values(); - } + } + $data['antibiotics'] = $allASTManual; if (Session::get('previlage') == 'developer'){ return view('dokter.ppdsdeveloper', $data); } else { diff --git a/htdocs/app/Http/Controllers/ListController.php b/htdocs/app/Http/Controllers/ListController.php index 9c4f1cd5..0d9587cf 100644 --- a/htdocs/app/Http/Controllers/ListController.php +++ b/htdocs/app/Http/Controllers/ListController.php @@ -231,6 +231,35 @@ class ListController extends Controller } $arraylist = $arraylist->get(); } else { + $cairansteril = [15,16,43,47,48,66,96,205,209,210,211,212,213,214,215,216,217,218,219,220,221,222,223]; + $cci = 20; + $darah = [7,8,13,17,29,33,44,107,114,115,199,200,201,202]; + $feces = [37,38,148,149,204]; + $hiv = 30; + $kukukulit = [165,179,180,181,183,184,185,187,188,189,190,192,194,195,196,198]; + $kulturtb = [26,40,45,52,53,56,60,61,68,69,75,92,102,122,123,136,137,144,145,152,153,233]; + $pusdanjaringan = [18,19,32,35,46,49,50,54,57,58,59,72,160,182,186,191,193,197,206,207,208,224,225,226,227,228,234,235,236,237]; + $sputum = [1,12,23,24,36,39,229,230,231,232]; + $swab = [2,4,5,9,10,11,12,21,22,27,34,41,42,51,63,64,65,85,86,87,88,93,97,118,120,121,125,126,127,128,129,130,132,133,134,135,140,147,158,159,161,162,163,164,166,167,168,169,170,171,172,173,174,175,176,177,178]; + $tcmnontb = [79,80,81,82,83,84,203]; + $tcmtb = [14,28,55,62,94,104,105,124,138,146]; + $urine = [3,6,25,31,154,155,156,157]; + //jikabukan_array_tambahkan_kurung + $mapped = array_merge( + $cairansteril, + [$cci], + $darah, + $feces, + [$hiv], + $kukukulit, + $kulturtb, + $pusdanjaringan, + $sputum, + $swab, + $tcmnontb, + $tcmtb, + $urine + ); $arraylist = Periksa::select( 'id', 'mulai', 'akhir', 'orderid', 'noloket', 'nofoto', 'noregister', 'asalpasien', 'nmrs', 'pasien_id', 'nmpasien', @@ -355,6 +384,34 @@ class ListController extends Controller $arraylist = $arraylist->where('nm_spesimen', 'SWAB TENGGOROKAN'); } else if ($master == 'TUBO'){ $arraylist = $arraylist->where('nm_spesimen', 'TUBO O'); + } else if ($master == 'buku01'){ + $arraylist = $arraylist->whereIn('poli_id', $cairansteril); + } else if ($master == 'buku02') { + $arraylist = $arraylist->where('poli_id', $cci); + } else if ($master == 'buku03') { + $arraylist = $arraylist->whereIn('poli_id', $darah); + } else if ($master == 'buku04') { + $arraylist = $arraylist->where('poli_id', $hiv); + } else if ($master == 'buku05') { + $arraylist = $arraylist->whereIn('poli_id', $kukukulit); + } else if ($master == 'buku06') { + $arraylist = $arraylist->whereIn('poli_id', $kulturtb); + } else if ($master == 'buku07') { + $arraylist = $arraylist->whereIn('poli_id', $pusdanjaringan); + } else if ($master == 'buku08') { + $arraylist = $arraylist->whereIn('poli_id', $sputum); + } else if ($master == 'buku09') { + $arraylist = $arraylist->whereIn('poli_id', $swab); + } else if ($master == 'buku10') { + $arraylist = $arraylist->whereIn('poli_id', $tcmtb); + } else if ($master == 'buku11') { + $arraylist = $arraylist->whereIn('poli_id', $tcmnontb); + } else if ($master == 'buku12') { + $arraylist = $arraylist->whereIn('poli_id', $urine); + } else if ($master == 'buku13') { + $arraylist = $arraylist->whereIn('poli_id', $feces); + } else if ($master == 'buku0') { + $arraylist = $arraylist->whereNotIn('poli_id', $mapped); } else if ($master == '' OR $master == 'all'){ // no filter } else { diff --git a/htdocs/database/migrations/2024_12_28_142050_create_sirab_table.php b/htdocs/database/migrations/2024_12_28_142050_create_sirab_table.php index c5315792..e24e3ecc 100644 --- a/htdocs/database/migrations/2024_12_28_142050_create_sirab_table.php +++ b/htdocs/database/migrations/2024_12_28_142050_create_sirab_table.php @@ -26,6 +26,7 @@ return new class extends Migration $table->string('atu', 50)->nullable(); $table->string('kelompok', 50)->nullable(); $table->integer('cek')->nullable(); + $table->string('setmanual', 255)->nullable(); $table->timestamp('created_at')->useCurrent(); $table->timestamp('updated_at')->useCurrent(); }); diff --git a/htdocs/database/migrations/2025_01_05_140423_create_rekapantibiotik_table.php b/htdocs/database/migrations/2025_01_05_140423_create_rekapantibiotik_table.php index 027a384c..a76d8137 100644 --- a/htdocs/database/migrations/2025_01_05_140423_create_rekapantibiotik_table.php +++ b/htdocs/database/migrations/2025_01_05_140423_create_rekapantibiotik_table.php @@ -22,6 +22,9 @@ return new class extends Migration $table->integer('orderid')->nullable(); $table->boolean('printrow')->nullable(); $table->boolean('printcol')->nullable(); + $table->string('batasatas', 150)->nullable(); + $table->string('midrange', 150)->nullable(); + $table->string('batasbawah', 150)->nullable(); $table->timestamp('created_at')->useCurrent(); $table->timestamp('updated_at')->useCurrent(); }); diff --git a/htdocs/database/seeders/DatabaseSeeder.php b/htdocs/database/seeders/DatabaseSeeder.php index e50c618f..5b6cfa75 100644 --- a/htdocs/database/seeders/DatabaseSeeder.php +++ b/htdocs/database/seeders/DatabaseSeeder.php @@ -26,26 +26,39 @@ class DatabaseSeeder extends Seeder 'previlage' => 'developer', ]); } + $ceksudah = User::where('username', 'doktestes')->count(); + if ($ceksudah == 0){ + User::create([ + 'nama' => 'doktestes', + 'username' => 'doktestes', + 'password' => bcrypt('doktestes'), + 'previlage' => 'supervisor', + ]); + } + $ceksudah = User::where('username', 'ppdstes')->count(); + if ($ceksudah == 0){ + User::create([ + 'nama' => 'ppdstes', + 'username' => 'ppdstes', + 'password' => bcrypt('ppdstes'), + 'previlage' => 'ppds', + ]); + } + $ceksudah = User::where('username', 'analistes')->count(); + if ($ceksudah == 0){ + User::create([ + 'nama' => 'analistes', + 'username' => 'analistes', + 'password' => bcrypt('analistes'), + 'previlage' => 'analis', + ]); + } $json1 = file_get_contents(database_path('seeders/data/ruangan.json')); $data1 = json_decode($json1, true); DB::table('ruangan')->insert($data1); $this->call(JawabanSeeder::class); $this->call(OrganismSeeder::class); $this->call(SirabSeeder::class); - DB::table('poli')->insert([ - ['poli' => 'Mikrobiologi', 'subpoli' => '10 SPUTUM - 10 3 4 KULTUR AEROB SPUTUM DAN UJI KEPEKAAN AB', 'subsubpoli' => '', 'modaliti' => '', 'modaliti2' => ''], - ['poli' => 'Mikrobiologi', 'subpoli' => '2.3.5 KULTUR AEROB SEKRET DAN UJI KEPEKAAN AB', 'subsubpoli' => '', 'modaliti' => '', 'modaliti2' => ''], - ['poli' => 'Mikrobiologi', 'subpoli' => '1.3.1 PEWARNAAN GRAM URINE', 'subsubpoli' => '', 'modaliti' => '', 'modaliti2' => ''], - ['poli' => 'Mikrobiologi', 'subpoli' => '7.3.1 PEWARNAAN GRAM SWAB TELINGA', 'subsubpoli' => '', 'modaliti' => '', 'modaliti2' => ''], - ['poli' => 'Mikrobiologi', 'subpoli' => '8.3.1 PEWARNAAN GRAM SPESIMEN MATA', 'subsubpoli' => '', 'modaliti' => '', 'modaliti2' => ''], - ['poli' => 'Mikrobiologi', 'subpoli' => '1.3.4 KULTUR AEROP URINE DAN UJI KEPEKAAN AB', 'subsubpoli' => '', 'modaliti' => '', 'modaliti2' => ''], - ['poli' => 'Mikrobiologi', 'subpoli' => '4.3.3 KULTUR DARAH AEROB DEWASA 1 BOTOL DAN UJI KEPEKAAN AB', 'subsubpoli' => '', 'modaliti' => '', 'modaliti2' => ''], - ['poli' => 'Mikrobiologi', 'subpoli' => '4.3.7 KULTUR JAMUR DARAH', 'subsubpoli' => '', 'modaliti' => '', 'modaliti2' => ''], - ['poli' => 'Mikrobiologi', 'subpoli' => '5.3.1 PEWARNAAN GRAM SWAB TENGGOROK', 'subsubpoli' => '', 'modaliti' => '', 'modaliti2' => ''], - ['poli' => 'Mikrobiologi', 'subpoli' => '5.3.2 PEWARNAAN NEISSER SWAB TENGGOROK', 'subsubpoli' => '', 'modaliti' => '', 'modaliti2' => ''], - ['poli' => 'Mikrobiologi', 'subpoli' => '5.3.4 KULTUR AEROB SWAB TENGGOROK DAN UJI KEPEKAAN AB', 'subsubpoli' => '', 'modaliti' => '', 'modaliti2' => ''], - ['poli' => 'Mikrobiologi', 'subpoli' => '10.3.4 KULTUR AEROB SPUTUM DAN UJI KEPEKAAN AB', 'subsubpoli' => '', 'modaliti' => '', 'modaliti2' => ''], - ['poli' => 'Mikrobiologi', 'subpoli' => '4.3.5 KULTUR DARAH AEROB PEDIATRI 1 BOTOL DAN UJI KEPEKAAN AB', 'subsubpoli' => '', 'modaliti' => '', 'modaliti2' => ''], - ]); + $this->call(PoliSeeder::class); } } diff --git a/htdocs/database/seeders/JawabanSeeder.php b/htdocs/database/seeders/JawabanSeeder.php index 496043e3..e68e5c66 100644 --- a/htdocs/database/seeders/JawabanSeeder.php +++ b/htdocs/database/seeders/JawabanSeeder.php @@ -22,7 +22,8 @@ class JawabanSeeder extends Seeder ['kategori' => '1', 'judul' => 'Pewarna Langsung', 'subjawaban' => '', 'kesimpulan' => ''], ['kategori' => '1', 'judul' => 'TBC', 'subjawaban' => '', 'kesimpulan' => ''], ['kategori' => '1', 'judul' => 'Viral Load', 'subjawaban' => '', 'kesimpulan' => ''], - ['kategori' => '1', 'judul' => 'PCR COVID', 'subjawaban' => '', 'kesimpulan' => ''] + ['kategori' => '1', 'judul' => 'PCR COVID', 'subjawaban' => '', 'kesimpulan' => ''], + ['kategori' => '1', 'judul' => 'IgM/IgG Leptospira', 'subjawaban' => '', 'kesimpulan' => ''] ]); DB::table('dokter')->insert([ [ 'id' => 2, 'nama' => 'NON DOKTER', 'jk' => '', 'tgl_lahir' => null, 'kota' => 'ND', 'alamat' => 'UMUM', 'created_at' => '2025-08-02 07:14:51', 'updated_at' => '2025-08-02 07:14:51'], diff --git a/htdocs/resources/views/admin/sirab.blade.php b/htdocs/resources/views/admin/sirab.blade.php index ac406cfd..93babab3 100644 --- a/htdocs/resources/views/admin/sirab.blade.php +++ b/htdocs/resources/views/admin/sirab.blade.php @@ -75,6 +75,10 @@ +
+ + +
@@ -110,6 +114,7 @@ { name: 'kodedok',type: 'text'}, { name: 'atu',type: 'text'}, { name: 'kelompok',type: 'text'}, + { name: 'setmanual',type: 'text'}, ], type: 'POST', data: { val01:'sirab', _token: token }, @@ -146,20 +151,22 @@ $("#sumber").val(dataRecord.sumber); $("#atu").val(dataRecord.atu); $("#kelompok").val(dataRecord.kelompok); + $("#setmanual").val(dataRecord.setmanual); $('#modalsirab').modal('show'); } }, - { text: 'Family', datafield: 'family', width: '10%', cellsalign: 'left', align: 'center' }, - { text: 'Spesies', datafield: 'spesies', width: '20%', cellsalign: 'left', align: 'center' }, - { text: 'Antibiotik', datafield: 'antibiotik', width: '13%', cellsalign: 'left', align: 'center' }, + { text: 'Family', filtertype: 'checkedlist', datafield: 'family', width: '10%', cellsalign: 'left', align: 'center' }, + { text: 'Spesies', datafield: 'spesies', width: '13%', cellsalign: 'left', align: 'center' }, + { text: 'Antibiotik', datafield: 'antibiotik', width: '10%', cellsalign: 'left', align: 'center' }, { text: 'Sub', datafield: 'subantibiotik', width: '11%', cellsalign: 'left', align: 'center' }, { text: 'Disk Content', datafield: 'diskcontent', width: '7%', cellsalign: 'left', align: 'center' }, { text: 'S', datafield: 'batasatas', width: '5%', cellsalign: 'center', align: 'center' }, { text: 'I', datafield: 'midrange', width: '5%', cellsalign: 'center', align: 'center' }, { text: 'R', datafield: 'batasbawah', width: '5%', cellsalign: 'center', align: 'center' }, - { text: 'Contributor', datafield: 'kodedok', width: '6%', cellsalign: 'center', align: 'center' }, + { text: 'Contributor', filtertype: 'checkedlist', datafield: 'kodedok', width: '6%', cellsalign: 'center', align: 'center' }, { text: 'ATU', datafield: 'atu', width: '5%', cellsalign: 'center', align: 'center' }, - { text: 'Groub', datafield: 'kelompok', width: '5%', cellsalign: 'center', align: 'center' }, + { text: 'Group', datafield: 'kelompok', width: '5%', cellsalign: 'center', align: 'center' }, + { text: 'AST Manual', datafield: 'setmanual', filtertype: 'checkedlist', width: '10%', cellsalign: 'left', align: 'center' }, { text: 'Del', editable: false, sortable: false, filterable: false, columntype: 'button', width: '4%', cellsrenderer: function () { return "Del"; }, buttonclick: function (row) { @@ -216,6 +223,7 @@ var set10 = document.getElementById('atu').value; var set11 = document.getElementById('kelompok').value; var set12 = document.getElementById('id').value; + var set13 = document.getElementById('setmanual').value; if (set01 == '' || set02 == '' || set03 == ''){ swal({ title : 'Mohon diLengkapi', @@ -237,6 +245,7 @@ form_data.append('atu', set10); form_data.append('kelompok', set11); form_data.append('id', set12); + form_data.append('setmanual', set13); form_data.append('tabel', 'SIRAB'); form_data.append('_token', '{{csrf_token()}}'); $.ajax({ diff --git a/htdocs/resources/views/base/partials/header-plain.blade.php b/htdocs/resources/views/base/partials/header-plain.blade.php index 46989aef..acbd4378 100644 --- a/htdocs/resources/views/base/partials/header-plain.blade.php +++ b/htdocs/resources/views/base/partials/header-plain.blade.php @@ -71,36 +71,20 @@
  • Specimen
  • Patient
  • diff --git a/htdocs/resources/views/dokter/ppds.blade.php b/htdocs/resources/views/dokter/ppds.blade.php index f306ef63..253483cb 100644 --- a/htdocs/resources/views/dokter/ppds.blade.php +++ b/htdocs/resources/views/dokter/ppds.blade.php @@ -4458,7 +4458,7 @@ hideAfter : 5000, stack : 1 }); - window.location.href = "{{ url('/mikro') }}"; + //window.location.href = "{{ url('/mikro/all') }}"; return false; }, error: function (xhr, status, error) { diff --git a/htdocs/resources/views/dokter/ppdsdeveloper.blade.php b/htdocs/resources/views/dokter/ppdsdeveloper.blade.php index 268d8dae..fd34ebe6 100644 --- a/htdocs/resources/views/dokter/ppdsdeveloper.blade.php +++ b/htdocs/resources/views/dokter/ppdsdeveloper.blade.php @@ -1724,6 +1724,28 @@
    +
    +
    + + +
    +
    + + +
    +
    + + +
    +
    @@ -1998,6 +2035,7 @@
    +
    @@ -4001,6 +4039,7 @@ CKEDITOR.replace( 'lsg_ditemukanmorfologi'); CKEDITOR.replace( 'lsg_pewarnaanlain'); CKEDITOR.replace( 'viralload'); + CKEDITOR.replace( 'iggigm_interpretasi'); $("#mulai").datepicker({format: 'yyyy-mm-dd', autoclose: true}); $("#akhir").datepicker({format: 'yyyy-mm-dd', autoclose: true}); $("#id_tanggalpengambilancontohuji").datepicker({format: 'yyyy-mm-dd', autoclose: true}); @@ -4458,7 +4497,7 @@ hideAfter : 5000, stack : 1 }); - window.location.href = "{{ url('/mikro') }}"; + //window.location.href = "{{ url('/mikro') }}"; return false; }, error: function (xhr, status, error) { @@ -4963,66 +5002,6 @@ } }); - $("#id_bakteri01").on('change', function() { - var komponen = $(this).attr('id'); - var isi = document.getElementById('id_bakteri01').value; - var jenis = document.getElementById('dlp').value; - var idne = document.getElementById('periksa_id').value; - var form_data = new FormData(); - form_data.append('nofoto', document.getElementById('nofoto').value); - form_data.append('val10', jenis); - form_data.append('komponen', komponen); - form_data.append('isi', isi); - form_data.append('periksa_id', idne); - form_data.append('keterangan', 'kumanmanual'); - form_data.append('_token', '{{csrf_token()}}'); - $.ajax({ - url : '{{ route("getResult") }}', - data : form_data, - type : 'POST', - contentType : false, - processData : false, - success : function (response) { - console.log(response); - btncreateantibiotikkumanmanual1(); - }, - error: function (xhr, status, error) { - var response = xhr.responseJSON || {}; - var traceText = response.trace ? JSON.stringify(response.trace) : null; - console.log(traceText); - } - }); - }); - $("#id_bakteri02").on('change', function() { - var komponen = $(this).attr('id'); - var isi = document.getElementById('id_bakteri02').value; - var jenis = document.getElementById('dlp').value; - var idne = document.getElementById('periksa_id').value; - var form_data = new FormData(); - form_data.append('nofoto', document.getElementById('nofoto').value); - form_data.append('val10', jenis); - form_data.append('komponen', komponen); - form_data.append('isi', isi); - form_data.append('periksa_id', idne); - form_data.append('keterangan', 'kumanmanual'); - form_data.append('_token', '{{csrf_token()}}'); - $.ajax({ - url : '{{ route("getResult") }}', - data : form_data, - type : 'POST', - contentType : false, - processData : false, - success : function (response) { - console.log(response); - btncreateantibiotikkumanmanual2(); - }, - error: function (xhr, status, error) { - var response = xhr.responseJSON || {}; - var traceText = response.trace ? JSON.stringify(response.trace) : null; - console.log(traceText); - } - }); - }); $(".pilihankirby").on('change', function() { var komponen = $(this).attr('id'); var isi = $(this).val();