Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
F
frontend
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Antrian
frontend
Commits
cd87a10e
Commit
cd87a10e
authored
Oct 15, 2020
by
Azy Mushofy Anwary
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
pemabnahan dan memperbaiki fitur
parent
95e7301f
Changes
31
Hide whitespace changes
Inline
Side-by-side
Showing
31 changed files
with
1967 additions
and
487 deletions
+1967
-487
module/Application/src/Controller/AdminController.php
module/Application/src/Controller/AdminController.php
+38
-18
module/Application/src/Controller/ApiController.php
module/Application/src/Controller/ApiController.php
+390
-13
module/Application/src/Controller/QueueController.php
module/Application/src/Controller/QueueController.php
+25
-11
module/Application/src/Model/Param.php
module/Application/src/Model/Param.php
+44
-6
module/Application/src/Model/Param/Storage/Mysql.php
module/Application/src/Model/Param/Storage/Mysql.php
+435
-7
module/Application/view/application/admin/dasboard.phtml
module/Application/view/application/admin/dasboard.phtml
+134
-0
module/Application/view/application/admin/keloladokter.phtml
module/Application/view/application/admin/keloladokter.phtml
+6
-11
module/Application/view/application/admin/kelolapasien.phtml
module/Application/view/application/admin/kelolapasien.phtml
+70
-20
module/Application/view/application/admin/kelolapoli.phtml
module/Application/view/application/admin/kelolapoli.phtml
+16
-19
module/Application/view/application/admin/kelolaruangan.phtml
...le/Application/view/application/admin/kelolaruangan.phtml
+12
-3
module/Application/view/application/admin/registrasidokter.phtml
...Application/view/application/admin/registrasidokter.phtml
+1
-1
module/Application/view/application/queue/cekdatapasien.phtml
...le/Application/view/application/queue/cekdatapasien.phtml
+6
-1
module/Application/view/application/queue/daftarpasien.phtml
module/Application/view/application/queue/daftarpasien.phtml
+13
-2
module/Application/view/application/queue/datapasien.phtml
module/Application/view/application/queue/datapasien.phtml
+0
-3
module/Application/view/application/queue/dokter.phtml
module/Application/view/application/queue/dokter.phtml
+1
-22
module/Application/view/application/queue/poli.phtml
module/Application/view/application/queue/poli.phtml
+5
-33
module/Application/view/layout/layoutAdmin.phtml
module/Application/view/layout/layoutAdmin.phtml
+15
-4
module/Application/view/layout/layoutQueue.phtml
module/Application/view/layout/layoutQueue.phtml
+26
-26
public/action-js/antrian-js/action-cekdatapasien.js
public/action-js/antrian-js/action-cekdatapasien.js
+112
-36
public/action-js/antrian-js/action-cetak.js
public/action-js/antrian-js/action-cetak.js
+6
-4
public/action-js/antrian-js/action-daftarpasien.js
public/action-js/antrian-js/action-daftarpasien.js
+82
-35
public/action-js/antrian-js/action-datapasien.js
public/action-js/antrian-js/action-datapasien.js
+2
-2
public/action-js/antrian-js/action-dokter.js
public/action-js/antrian-js/action-dokter.js
+3
-2
public/action-js/antrian-js/action-keloladokter.js
public/action-js/antrian-js/action-keloladokter.js
+106
-61
public/action-js/antrian-js/action-kelolapasien.js
public/action-js/antrian-js/action-kelolapasien.js
+242
-114
public/action-js/antrian-js/action-kelolapoli.js
public/action-js/antrian-js/action-kelolapoli.js
+60
-12
public/action-js/antrian-js/action-kelolaruang.js
public/action-js/antrian-js/action-kelolaruang.js
+116
-20
public/tamplate/css/demo.css
public/tamplate/css/demo.css
+1
-1
public/tamplate/img/icon/gigi.png
public/tamplate/img/icon/gigi.png
+0
-0
public/tamplate/img/icon/mata.png
public/tamplate/img/icon/mata.png
+0
-0
public/tamplate/img/icon/umum.png
public/tamplate/img/icon/umum.png
+0
-0
No files found.
module/Application/src/Controller/AdminController.php
View file @
cd87a10e
...
...
@@ -33,7 +33,10 @@ class AdminController extends \Application\Master\GlobalActionController
$baseurl
=
sprintf
(
'//%s'
,
$uri
->
getHost
());
$this
->
headScript
->
appendScript
(
' var baseURL = "'
.
$baseurl
.
'"'
);
$this
->
headScript
->
appendFile
(
'/action-js/antrian-js/action-panggil.js'
);
$this
->
headScript
->
appendFile
(
'/action-js/antrian-js/action-dasboaard.js'
);
// $this->headScript->appendFile('/tamplateadmin/js/demo/chart-bar-demo.js');
// $this->headScript->appendFile('/tamplateadmin/js/demo/chart-area-demo.js');
$this
->
headScript
->
appendFile
(
'/tamplateadmin/js/demo/chart-pie-demo.js'
);
$this
->
layout
(
"layout/layoutAdmin"
);
return
$view
;
...
...
@@ -70,7 +73,7 @@ class AdminController extends \Application\Master\GlobalActionController
$this
->
layout
(
"layout/layoutAdmin"
);
return
$view
;
}
public
function
kelolapasien
Action
()
public
function
antrianterlewat
Action
()
{
$this
->
isLoggedIn
();
$view
=
new
ViewModel
();
...
...
@@ -81,7 +84,23 @@ class AdminController extends \Application\Master\GlobalActionController
$baseurl
=
sprintf
(
'//%s'
,
$uri
->
getHost
());
$this
->
headScript
->
appendScript
(
' var baseURL = "'
.
$baseurl
.
'"'
);
$this
->
headScript
->
appendFile
(
'/action-js/antrian-js/action-kelolapasien.js'
);
$this
->
headScript
->
appendFile
(
'/action-js/antrian-js/action-kelolaantrian.js'
);
$this
->
layout
(
"layout/layoutAdmin"
);
return
$view
;
}
public
function
antrianunregisterAction
()
{
$this
->
isLoggedIn
();
$view
=
new
ViewModel
();
$result
=
new
Result
();
/* get url */
$uri
=
$this
->
getRequest
()
->
getUri
();
$baseurl
=
sprintf
(
'//%s'
,
$uri
->
getHost
());
$this
->
headScript
->
appendScript
(
' var baseURL = "'
.
$baseurl
.
'"'
);
$this
->
headScript
->
appendFile
(
'/action-js/antrian-js/action-kelolaantrianunreg.js'
);
$this
->
layout
(
"layout/layoutAdmin"
);
return
$view
;
...
...
@@ -118,6 +137,22 @@ class AdminController extends \Application\Master\GlobalActionController
$this
->
layout
(
"layout/layoutAdmin"
);
return
$view
;
}
public
function
kelolapasienAction
()
{
$this
->
isLoggedIn
();
$view
=
new
ViewModel
();
$result
=
new
Result
();
/* get url */
$uri
=
$this
->
getRequest
()
->
getUri
();
$baseurl
=
sprintf
(
'//%s'
,
$uri
->
getHost
());
$this
->
headScript
->
appendScript
(
' var baseURL = "'
.
$baseurl
.
'"'
);
$this
->
headScript
->
appendFile
(
'/action-js/antrian-js/action-kelolapasien.js'
);
$this
->
layout
(
"layout/layoutAdmin"
);
return
$view
;
}
public
function
kelolaruanganAction
()
{
$this
->
isLoggedIn
();
...
...
@@ -150,22 +185,7 @@ class AdminController extends \Application\Master\GlobalActionController
$this
->
layout
(
"layout/layoutAdmin"
);
return
$view
;
}
public
function
cobainAction
()
{
//$this->isLoggedIn();
// $view = new ViewModel();
$result
=
new
Result
();
/* get url */
$uri
=
$this
->
getRequest
()
->
getUri
();
$baseurl
=
sprintf
(
'//%s'
,
$uri
->
getHost
());
// $this->headScript->appendScript(' var baseURL = "' . $baseurl . '"');
// $this->headScript->appendFile('/action-js/index-js/action-listdata.js');
$this
->
layout
(
"layout/layoutAdmin"
);
return
$view
;
}
public
function
tampilanumumAction
()
{
$this
->
isLoggedIn
();
...
...
module/Application/src/Controller/ApiController.php
View file @
cd87a10e
...
...
@@ -137,19 +137,24 @@ class ApiController extends \Application\Master\GlobalActionController {
$storage
=
\Application\Model\Param\Storage
::
factory
(
$this
->
getDb
(),
$this
->
getConfig
());
$test
=
new
\Application\Model\Param
(
$storage
);
$no_rekam_medis
=
$post
->
ino_rekam_medis
;
$ktp
=
$post
->
iktp
;
$cekpasien
=
$test
->
cekpasien
(
$no_rekam_medis
);
$cekpasien
=
$test
->
cekpasien
(
$no_rekam_medis
);
$validasi
=
$test
->
cekktp
(
$no_rekam_medis
,
$ktp
);
$array
=
array
(
'validasiinput'
=>
$validasi
->
code
,
'datapasien'
=>
$cekpasien
->
data
);
// print_r($
cekpasien
) ;die;
// print_r($
no_rekam_medis
) ;die;
if
(
$cekpasien
->
code
==
0
){
$result
->
code
=
$result
::
CODE_SUCCESS
;
$result
->
info
=
$result
::
INFO_SUCCESS
;
$result
->
data
=
$
cekpasien
->
data
;
$result
->
data
=
$
array
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'Not Found'
;
...
...
@@ -604,11 +609,14 @@ class ApiController extends \Application\Master\GlobalActionController {
return
$this
->
getOutput
(
$result
->
toJson
());
}
public
function
savekelolapoliAction
(){
if
(
$this
->
isLoggedIn
()){
$result
=
new
Result
();
$request
=
$this
->
getRequest
();
$post
=
$request
->
getPost
();
$table_poli
=
'poli'
;
...
...
@@ -618,8 +626,10 @@ class ApiController extends \Application\Master\GlobalActionController {
$storage
=
\Application\Model\Param\Storage
::
factory
(
$this
->
getDb
(),
$this
->
getConfig
());
$param
=
new
\Application\Model\Param
(
$storage
);
try
{
try
{
$nama_poli
=
$post
->
inama_poli
;
$kode_poli
=
$post
->
ikode_poli
;
$deskripsi_poli
=
$post
->
ideskripsi_poli
;
...
...
@@ -772,6 +782,7 @@ class ApiController extends \Application\Master\GlobalActionController {
$storage
=
\Application\Model\Param\Storage
::
factory
(
$this
->
getDb
(),
$this
->
getConfig
());
$param
=
new
\Application\Model\Param
(
$storage
);
try
{
$nama_dokter
=
$post
->
inama_dokter
;
...
...
@@ -800,13 +811,13 @@ class ApiController extends \Application\Master\GlobalActionController {
// print_r($dataArraydokter);die;
$param
->
saveGlobal
(
$DokterPoli
,
$table_dokter_to_poli
);
$param
->
saveGlobal
(
$Dokter
,
$table_dokter
);
$param
->
saveGlobal
(
$DokterPoli
,
$table_dokter_to_poli
);
$result
->
code
=
0
;
$result
->
info
=
'ok'
;
$result
->
data
=
$
dataArraydokter
->
data
;
$result
->
data
=
$
DokterPoli
->
data
;
}
catch
(
\Exception
$exc
)
{
...
...
@@ -955,11 +966,13 @@ class ApiController extends \Application\Master\GlobalActionController {
try
{
$nama_ruang
=
$post
->
inama_ruang
;
$lantai
=
$post
->
ilantai
;
$poli
=
$post
->
ipoli
;
//print_r($poli);die;
$dataArrayruang
=
array
(
'nama_ruang'
=>
'R '
.
$nama_ruang
,
'nama_ruang'
=>
$nama_ruang
,
'lantai'
=>
$lantai
,
'id_poli'
=>
$poli
,
'id_condition'
=>
1
);
...
...
@@ -1000,6 +1013,7 @@ class ApiController extends \Application\Master\GlobalActionController {
$id_ruang
=
$post
->
id
;
$nama_ruang
=
$post
->
inama_ruang
;
$poli
=
$post
->
ipoli
;
$lantai
=
$post
->
ilantai
;
$condition
=
$post
->
icondition
;
...
...
@@ -1008,6 +1022,7 @@ class ApiController extends \Application\Master\GlobalActionController {
'nama_ruang'
=>
$nama_ruang
,
'id_poli'
=>
$poli
,
'lantai'
=>
$lantai
,
'id_condition'
=>
$condition
,
);
...
...
@@ -1061,18 +1076,182 @@ class ApiController extends \Application\Master\GlobalActionController {
return
$this
->
getOutput
(
$result
->
toJson
());
}
public
function
load
kelolaantrian
Action
(){
public
function
load
antrianmiss
Action
(){
$result
=
new
Result
();
$request
=
$this
->
getRequest
();
$post
=
$request
->
getPost
();
//$n
ame = $this->isFieldMandatory(@$data['name'], 'name');
//$n
$storage
=
\Application\Model\Param\Storage
::
factory
(
$this
->
getDb
(),
$this
->
getConfig
());
$test
=
new
\Application\Model\Param
(
$storage
);
$load
=
$test
->
loadantrianmiss
(
$post
->
id
);
// print_r($load);die;
if
(
$load
->
code
==
0
){
$result
->
code
=
$result
::
CODE_SUCCESS
;
$result
->
info
=
$result
::
INFO_SUCCESS
;
$result
->
data
=
$load
->
data
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'Not Found'
;
}
return
$this
->
getOutput
(
$result
->
toJson
());
}
public
function
loadantrianunregisAction
(){
$result
=
new
Result
();
$request
=
$this
->
getRequest
();
$post
=
$request
->
getPost
();
//$n
$storage
=
\Application\Model\Param\Storage
::
factory
(
$this
->
getDb
(),
$this
->
getConfig
());
$test
=
new
\Application\Model\Param
(
$storage
);
$load
=
$test
->
loadantrianunregis
(
$post
->
id
);
// print_r($load);die;
if
(
$load
->
code
==
0
){
$result
->
code
=
$result
::
CODE_SUCCESS
;
$result
->
info
=
$result
::
INFO_SUCCESS
;
$result
->
data
=
$load
->
data
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'Not Found'
;
}
return
$this
->
getOutput
(
$result
->
toJson
());
}
public
function
loadkelolapasienAction
(){
$result
=
new
Result
();
$request
=
$this
->
getRequest
();
$post
=
$request
->
getPost
();
$storage
=
\Application\Model\Param\Storage
::
factory
(
$this
->
getDb
(),
$this
->
getConfig
());
$test
=
new
\Application\Model\Param
(
$storage
);
$load
=
$test
->
loadkelolapasien
(
$post
->
id_pasien
);
// print_r($load);die;
$load
=
$test
->
loadkelolaantrian
(
$post
->
id
);
if
(
$load
->
code
==
0
){
$result
->
code
=
$result
::
CODE_SUCCESS
;
$result
->
info
=
$result
::
INFO_SUCCESS
;
$result
->
data
=
$load
->
data
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'Not Found'
;
}
return
$this
->
getOutput
(
$result
->
toJson
());
}
public
function
editkelolapasienAction
(){
if
(
$this
->
isLoggedIn
()){
$result
=
new
Result
();
$request
=
$this
->
getRequest
();
$post
=
$request
->
getPost
();
if
(
$request
->
isPost
())
{
$storage
=
\Application\Model\Param\Storage
::
factory
(
$this
->
getDb
(),
$this
->
getConfig
());
$param
=
new
\Application\Model\Param
(
$storage
);
try
{
$id_pasien
=
$post
->
id_pasien
;
$nama_pasien
=
$post
->
inama
;
$ktp
=
$post
->
iktp
;
$tanggal_lahir
=
$post
->
itanggal_lahir
;
$tempat_lahir
=
$post
->
itempat_lahir
;
$alamat
=
$post
->
ialamat
;
$no_hp
=
$post
->
ino_hp
;
$dataarraypasien
=
array
(
'ktp'
=>
$ktp
,
'nama'
=>
$nama_pasien
,
'tanggal_lahir'
=>
$tanggal_lahir
,
'tempat_lahir'
=>
$tempat_lahir
,
'alamat'
=>
$alamat
,
'no_hp'
=>
$no_hp
,
);
$load
=
$param
->
loadkelolapasien
(
$post
->
id_pasien
);
$table
=
'pasien'
;
$where
=
'id_pasien='
.
$id_pasien
;
// print_r($where);die;
$param
->
updateGlobal
(
$table
,
$dataarraypasien
,
$where
);
$result
->
code
=
0
;
$result
->
info
=
'ok'
;
$result
->
data
=
$load
->
data
;
}
catch
(
\Exception
$exc
)
{
$result
=
new
Result
(
0
,
1
,
$exc
->
getMessage
()
.
'-'
.
$exc
->
getTraceAsString
());
}
}
else
{
$result
=
new
Result
(
0
,
401
,
'Silahkan masuk untuk melanjutkan'
);
}
}
return
$this
->
getOutput
(
$result
->
toJson
());
}
public
function
deletekelolapasienAction
(){
$result
=
new
Result
();
$request
=
$this
->
getRequest
();
$post
=
$request
->
getPost
();
//$name = $this->isFieldMandatory(@$data['name'], 'name');
$storage
=
\Application\Model\Param\Storage
::
factory
(
$this
->
getDb
(),
$this
->
getConfig
());
$test
=
new
\Application\Model\Param
(
$storage
);
$tabel
=
'pasien'
;
$where
=
'id_pasien='
.
$post
->
id_pasien
;
// print_r($where);die;
$res
=
$test
->
deleteGlobal
(
$tabel
,
$where
);
if
(
$load
->
code
==
0
){
$result
->
code
=
$result
::
CODE_SUCCESS
;
$result
->
info
=
$result
::
INFO_SUCCESS
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'Not Found'
;
}
return
$this
->
getOutput
(
$result
->
toJson
());
}
public
function
loadpasienAction
(){
$result
=
new
Result
();
$request
=
$this
->
getRequest
();
$post
=
$request
->
getPost
();
//$name = $this->isFieldMandatory(@$data['name'], 'name');
$storage
=
\Application\Model\Param\Storage
::
factory
(
$this
->
getDb
(),
$this
->
getConfig
());
$test
=
new
\Application\Model\Param
(
$storage
);
// print_r($post->id);die;
$load
=
$test
->
loadpasien
(
$post
->
id
);
if
(
$load
->
code
==
0
){
$result
->
code
=
$result
::
CODE_SUCCESS
;
...
...
@@ -1461,6 +1640,52 @@ class ApiController extends \Application\Master\GlobalActionController {
return
$this
->
getOutput
(
$result
->
toJson
());
}
public
function
updateunregisterAction
(){
$result
=
new
Result
();
$request
=
$this
->
getRequest
();
$post
=
$request
->
getPost
();
$storage
=
\Application\Model\Param\Storage
::
factory
(
$this
->
getDb
(),
$this
->
getConfig
());
$test
=
new
\Application\Model\Param
(
$storage
);
$id_pasien
=
$post
->
id_pasien
;
$dataarray
=
array
(
'id_pasien'
=>
null
,
'create_date'
=>
null
,
'nama'
=>
null
,
'tempat_lahir'
=>
null
,
'tanggal_lahir'
=>
null
,
'alamat'
=>
null
,
'no_rekam_medis'
=>
null
,
'no_hp'
=>
null
,
'ktp'
=>
null
,
'status_code'
=>
null
,
);
// $loadunreg = $test->loadantrianunregis($id_pasien);
$table
=
'antrian_pasien'
;
$where
=
'id_pasien='
.
$id_pasien
;
$test
->
updateGlobal
(
$table
,
$dataarray
,
$where
);
// print_r($where);
if
(
$loaddokter
->
code
==
0
){
$result
->
code
=
$result
::
CODE_SUCCESS
;
$result
->
info
=
$result
::
INFO_SUCCESS
;
$result
->
data
=
$dataarray
->
data
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'Not Found'
;
}
return
$this
->
getOutput
(
$result
->
toJson
());
}
public
function
tampildokterAction
(){
$result
=
new
Result
();
...
...
@@ -1489,4 +1714,156 @@ class ApiController extends \Application\Master\GlobalActionController {
return
$this
->
getOutput
(
$result
->
toJson
());
}
public
function
tampilpoliAction
(){
$result
=
new
Result
();
$request
=
$this
->
getRequest
();
$post
=
$request
->
getPost
();
//$name = $this->isFieldMandatory(@$data['name'], 'name');
$storage
=
\Application\Model\Param\Storage
::
factory
(
$this
->
getDb
(),
$this
->
getConfig
());
$test
=
new
\Application\Model\Param
(
$storage
);
$loadpoli
=
$test
->
tampilpoli
(
$post
->
id
);
if
(
$loaddokter
->
code
==
0
){
$result
->
code
=
$result
::
CODE_SUCCESS
;
$result
->
info
=
$result
::
INFO_SUCCESS
;
$result
->
data
=
$loadpoli
->
data
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'Not Found'
;
}
return
$this
->
getOutput
(
$result
->
toJson
());
}
public
function
tampildatapoliAction
(){
$result
=
new
Result
();
$request
=
$this
->
getRequest
();
$post
=
$request
->
getPost
();
//$name = $this->isFieldMandatory(@$data['name'], 'name');
$storage
=
\Application\Model\Param\Storage
::
factory
(
$this
->
getDb
(),
$this
->
getConfig
());
$test
=
new
\Application\Model\Param
(
$storage
);
$loaddatapoli
=
$test
->
tampildatapoli
(
$post
->
id
);
// print_r($loaddatapoli);die;
if
(
$loaddokter
->
code
==
0
){
$result
->
code
=
$result
::
CODE_SUCCESS
;
$result
->
info
=
$result
::
INFO_SUCCESS
;
$result
->
data
=
$loaddatapoli
->
data
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'Not Found'
;
}
return
$this
->
getOutput
(
$result
->
toJson
());
}
public
function
loadjumlahpasienAction
(){
$result
=
new
Result
();
$request
=
$this
->
getRequest
();
$post
=
$request
->
getPost
();
//$name = $this->isFieldMandatory(@$data['name'], 'name');
$storage
=
\Application\Model\Param\Storage
::
factory
(
$this
->
getDb
(),
$this
->
getConfig
());
$test
=
new
\Application\Model\Param
(
$storage
);
$load
=
$test
->
loadjumlahpasien
();
if
(
$load
->
code
==
0
){
$result
->
code
=
$result
::
CODE_SUCCESS
;
$result
->
info
=
$result
::
INFO_SUCCESS
;
$result
->
data
=
$load
->
data
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'Not Found'
;
}
return
$this
->
getOutput
(
$result
->
toJson
());
}
public
function
loadpasiendalamantrianAction
(){
$result
=
new
Result
();
$request
=
$this
->
getRequest
();
$post
=
$request
->
getPost
();
$storage
=
\Application\Model\Param\Storage
::
factory
(
$this
->
getDb
(),
$this
->
getConfig
());
$test
=
new
\Application\Model\Param
(
$storage
);
$load
=
$test
->
loadpasiendalamantrian
();
if
(
$load
->
code
==
0
){
$result
->
code
=
$result
::
CODE_SUCCESS
;
$result
->
info
=
$result
::
INFO_SUCCESS
;
$result
->
data
=
$load
->
data
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'Not Found'
;
}
return
$this
->
getOutput
(
$result
->
toJson
());
}
public
function
loadpasienterlewatAction
(){
$result
=
new
Result
();
$request
=
$this
->
getRequest
();
$post
=
$request
->
getPost
();
$storage
=
\Application\Model\Param\Storage
::
factory
(
$this
->
getDb
(),
$this
->
getConfig
());
$test
=
new
\Application\Model\Param
(
$storage
);
$load
=
$test
->
loadpasienterlewat
();
// print_r($load);die;
if
(
$load
->
code
==
0
){
$result
->
code
=
$result
::
CODE_SUCCESS
;
$result
->
info
=
$result
::
INFO_SUCCESS
;
$result
->
data
=
$load
->
data
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'Not Found'
;
}
return
$this
->
getOutput
(
$result
->
toJson
());
}
public
function
loadterlayaniAction
(){
$result
=
new
Result
();
$request
=
$this
->
getRequest
();
$post
=
$request
->
getPost
();
$storage
=
\Application\Model\Param\Storage
::
factory
(
$this
->
getDb
(),
$this
->
getConfig
());
$test
=
new
\Application\Model\Param
(
$storage
);
$load
=
$test
->
loadterlayani
();
// print_r($load);die;
if
(
$load
->
code
==
0
){
$result
->
code
=
$result
::
CODE_SUCCESS
;
$result
->
info
=
$result
::
INFO_SUCCESS
;
$result
->
data
=
$load
->
data
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'Not Found'
;
}
return
$this
->
getOutput
(
$result
->
toJson
());
}
}
\ No newline at end of file
module/Application/src/Controller/QueueController.php
View file @
cd87a10e
...
...
@@ -116,7 +116,7 @@ class QueueController extends \Application\Master\GlobalActionController
}
public
function
poliAction
()
{
$this
->
isLoggedIn
();
$view
=
new
ViewModel
();
$result
=
new
Result
();
...
...
@@ -124,8 +124,30 @@ class QueueController extends \Application\Master\GlobalActionController
$uri
=
$this
->
getRequest
()
->
getUri
();
$baseurl
=
sprintf
(
'//%s'
,
$uri
->
getHost
());
$this
->
headScript
->
appendScript
(
' var baseURL = "'
.
$baseurl
.
'"'
);
$this
->
headScript
->
appendScript
(
' var id = null'
);
$this
->
headScript
->
appendFile
(
'/action-js/antrian-js/action-poli.js'
);
$this
->
layout
(
"layout/layoutQueue"
);
return
$view
;
}
public
function
datapoliAction
()
{
$view
=
new
ViewModel
();
$result
=
new
Result
();
$id
=
$_GET
[
"id"
];
// print_r($id);die;
/* get url */
$uri
=
$this
->
getRequest
()
->
getUri
();
$baseurl
=
sprintf
(
'//%s'
,
$uri
->
getHost
());
$this
->
headScript
->
appendScript
(
' var baseURL = "'
.
$baseurl
.
'"'
);
$this
->
headScript
->
appendFile
(
'/action-js/index-js/action-listdata.js'
);
$this
->
headScript
->
appendScript
(
' var id = "'
.
$id
.
'"'
);
$this
->
headScript
->
appendFile
(
'/action-js/antrian-js/action-poli.js'
);
$this
->
layout
(
"layout/layoutQueue"
);
return
$view
;
...
...
@@ -159,15 +181,7 @@ class QueueController extends \Application\Master\GlobalActionController
$baseurl
=
sprintf
(
'//%s'
,
$uri
->
getHost
());
$getpath
=
explode
(
"/"
,
$uri
->
getPath
());
$decodeid
=
base64_decode
(
$getpath
[
3
]);
// $a = $getpath[3];
$decodeiddok
=
base64_decode
(
$getpath
[
4
]);
// $decodeidpol = base64_decode($getpath[5]);
// $decodeidant = base64_decode($getpath[6]);
// print_r($decodeiddok );die;
$storage
=
\Application\Model\Param\Storage
::
factory
(
$this
->
getDb
(),
$this
->
getConfig
());
$param
=
new
\Application\Model\Param
(
$storage
);
...
...
module/Application/src/Model/Param.php
View file @
cd87a10e
...
...
@@ -61,12 +61,20 @@ class Param extends Mapper {
$data
=
$this
->
_storage
->
loadUserData
(
$id
,
$iddok
);
return
$data
;
}
public
function
loadpasien
(
$id
=
null
){
$data
=
$this
->
_storage
->
loadpasien
(
$id
);
return
$data
;
}
public
function
loaddatapasien
(
$id
){
$data
=
$this
->
_storage
->
loaddatapasien
(
$id
);
return
$data
;
}
public
function
cekpasien
(
$no_rekam_medis
=
null
){
$data
=
$this
->
_storage
->
cekpasien
(
$no_rekam_medis
);
public
function
cekpasien
(
$no_rekam_medis
=
null
,
$ktp
=
null
){
$data
=
$this
->
_storage
->
cekpasien
(
$no_rekam_medis
,
$ktp
);
return
$data
;
}
public
function
cekktp
(
$no_rekam_medis
,
$ktp
){
$data
=
$this
->
_storage
->
cekktp
(
$no_rekam_medis
,
$ktp
);
return
$data
;
}
...
...
@@ -98,6 +106,10 @@ class Param extends Mapper {
$data
=
$this
->
_storage
->
loadkelolapoli
(
$id
);
return
$data
;
}
public
function
loadkelolapasien
(
$id
=
null
){
$data
=
$this
->
_storage
->
loadkelolapasien
(
$id
);
return
$data
;
}
public
function
loadkeloladokter
(
$id
=
null
){
$data
=
$this
->
_storage
->
loadkeloladokter
(
$id
);
return
$data
;
...
...
@@ -110,8 +122,12 @@ class Param extends Mapper {
$data
=
$this
->
_storage
->
updatekelolaantrian
(
$idpasien
,
$iddok
);
return
$data
;
}
public
function
loadkelolaantrian
(
$id
){
$data
=
$this
->
_storage
->
loadkelolaantrian
(
$id
);
public
function
loadantrianmiss
(
$id
){
$data
=
$this
->
_storage
->
loadantrianmiss
(
$id
);
return
$data
;
}
public
function
loadantrianunregis
(
$id
){
$data
=
$this
->
_storage
->
loadantrianunregis
(
$id
);
return
$data
;
}
public
function
loadPoli
(
$id
=
null
){
...
...
@@ -143,8 +159,30 @@ class Param extends Mapper {
$data
=
$this
->
_storage
->
loadAntrian
(
$id
);
return
$data
;
}
public
function
loadjumlahpasien
(){
$data
=
$this
->
_storage
->
loadjumlahpasien
();
return
$data
;
}
public
function
loadpasiendalamantrian
(){
$data
=
$this
->
_storage
->
loadpasiendalamantrian
();
return
$data
;
}
public
function
loadpasienterlewat
(){
$data
=
$this
->
_storage
->
loadpasienterlewat
();
return
$data
;
}
public
function
loadterlayani
(){
$data
=
$this
->
_storage
->
loadterlayani
();
return
$data
;
}
public
function
tampilpoli
(
$id
=
null
){
$data
=
$this
->
_storage
->
tampilpoli
(
$id
);
return
$data
;
}
public
function
tampildatapoli
(
$id
=
null
){
$data
=
$this
->
_storage
->
tampildatapoli
(
$id
);
return
$data
;
}
public
function
tampildokter
(){
$data
=
$this
->
_storage
->
tampildokter
();
return
$data
;
...
...
module/Application/src/Model/Param/Storage/Mysql.php
View file @
cd87a10e
...
...
@@ -359,6 +359,47 @@ class Mysql extends \Khansia\Db\Storage implements Skeleton {
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
return
$result
;
}
public
function
loadpasien
(
$id
){
$result
=
new
Result
();
try
{
$sql
=
" SELECT * FROM pasien"
;
if
(
$id
){
$sql
.=
" WHERE id_pasien =
$id
"
;
}
$sql
.=
" ORDER BY no_rekam_medis ASC"
;
$stmt
=
$this
->
_db
->
query
(
$sql
);
$resdata
=
$stmt
->
execute
();
$listdata
=
array
();
foreach
(
$resdata
as
$val
){
// print_r($val);die;
array_push
(
$listdata
,
$val
);
}
// print_r($listdata);die;
if
(
$listdata
)
{
$result
->
code
=
0
;
$result
->
info
=
'OK'
;
$result
->
data
=
$listdata
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'nok'
;
}
}
catch
(
\Zend\Db\Adapter\Exception\RuntimeException
$ex
)
{
$result
->
code
=
3
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
catch
(
\Exception
$ex
)
{
$result
->
code
=
4
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
return
$result
;
}
public
function
loadMaxCounter
(){
...
...
@@ -431,6 +472,155 @@ class Mysql extends \Khansia\Db\Storage implements Skeleton {
}
return
$result
;
}
public
function
loadjumlahpasien
(){
$result
=
new
Result
();
try
{
$sql
=
" SELECT count(id_pasien) FROM pasien "
;
// print_r($sql);die;
$stmt
=
$this
->
_db
->
query
(
$sql
);
$resdata
=
$stmt
->
execute
();
$listdata
=
array
();
foreach
(
$resdata
as
$val
){
// print_r($val);die;
array_push
(
$listdata
,
$val
);
}
if
(
$listdata
)
{
$result
->
code
=
0
;
$result
->
info
=
'OK'
;
$result
->
data
=
$listdata
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'nok'
;
}
}
catch
(
\Zend\Db\Adapter\Exception\RuntimeException
$ex
)
{
$result
->
code
=
3
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
catch
(
\Exception
$ex
)
{
$result
->
code
=
4
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
return
$result
;
}
public
function
loadpasiendalamantrian
(){
$result
=
new
Result
();
try
{
$sql
=
" SELECT count(id_pasien) FROM antrian_pasien "
;
// print_r($sql);die;
$stmt
=
$this
->
_db
->
query
(
$sql
);
$resdata
=
$stmt
->
execute
();
$listdata
=
array
();
foreach
(
$resdata
as
$val
){
// print_r($val);die;
array_push
(
$listdata
,
$val
);
}
if
(
$listdata
)
{
$result
->
code
=
0
;
$result
->
info
=
'OK'
;
$result
->
data
=
$listdata
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'nok'
;
}
}
catch
(
\Zend\Db\Adapter\Exception\RuntimeException
$ex
)
{
$result
->
code
=
3
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
catch
(
\Exception
$ex
)
{
$result
->
code
=
4
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
return
$result
;
}
public
function
loadpasienterlewat
(){
$result
=
new
Result
();
try
{
$sql
=
" SELECT count(status_code) FROM antrian_pasien WHERE status_code= 60 "
;
// print_r($sql);die;
$stmt
=
$this
->
_db
->
query
(
$sql
);
$resdata
=
$stmt
->
execute
();
$listdata
=
array
();
foreach
(
$resdata
as
$val
){
// print_r($val);die;
array_push
(
$listdata
,
$val
);
}
if
(
$listdata
)
{
$result
->
code
=
0
;
$result
->
info
=
'OK'
;
$result
->
data
=
$listdata
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'nok'
;
}
}
catch
(
\Zend\Db\Adapter\Exception\RuntimeException
$ex
)
{
$result
->
code
=
3
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
catch
(
\Exception
$ex
)
{
$result
->
code
=
4
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
return
$result
;
}
public
function
loadterlayani
(){
$result
=
new
Result
();
try
{
$sql
=
" SELECT count(status_code) FROM antrian_pasien
WHERE status_code = 50 "
;
// print_r($sql);die;
$stmt
=
$this
->
_db
->
query
(
$sql
);
$resdata
=
$stmt
->
execute
();
$listdata
=
array
();
foreach
(
$resdata
as
$val
){
// print_r($val);die;
array_push
(
$listdata
,
$val
);
}
if
(
$listdata
)
{
$result
->
code
=
0
;
$result
->
info
=
'OK'
;
$result
->
data
=
$listdata
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'nok'
;
}
}
catch
(
\Zend\Db\Adapter\Exception\RuntimeException
$ex
)
{
$result
->
code
=
3
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
catch
(
\Exception
$ex
)
{
$result
->
code
=
4
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
return
$result
;
}
public
function
getRegister
(
$where
){
$result
=
new
Result
();
try
{
...
...
@@ -471,7 +661,7 @@ class Mysql extends \Khansia\Db\Storage implements Skeleton {
public
function
cekpasien
(
$no_rekam_medis
){
$result
=
new
Result
();
try
{
try
{
$sql
=
" SELECT p.id_pasien, ap.no_rekam_medis, ap.status_code,ap.no_antrian ,ap.no_antrian, ap.id_antrian,ap.nama FROM pasien p
LEFT JOIN antrian_pasien ap
...
...
@@ -506,6 +696,57 @@ class Mysql extends \Khansia\Db\Storage implements Skeleton {
}
return
$result
;
}
public
function
cekktp
(
$no_rekam_medis
,
$ktp
){
$result
=
new
Result
();
try
{
$sql
=
"SELECT no_rekam_medis FROM pasien WHERE no_rekam_medis = '
$no_rekam_medis
' "
;
$stmt
=
$this
->
_db
->
query
(
$sql
);
$resdata
=
$stmt
->
execute
();
$listdata
=
array
();
foreach
(
$resdata
as
$val
){
array_push
(
$listdata
,
$val
);
}
if
(
$listdata
)
{
$sqlktp
=
"SELECT ktp, no_rekam_medis FROM pasien WHERE no_rekam_medis = '
$no_rekam_medis
' AND ktp = '
$ktp
'"
;
$stmtktp
=
$this
->
_db
->
query
(
$sqlktp
);
$resdataktp
=
$stmtktp
->
execute
();
$listdataktp
=
array
();
foreach
(
$resdataktp
as
$val
){
array_push
(
$listdataktp
,
$val
);
}
if
(
$listdataktp
){
$result
->
code
=
0
;
$result
->
info
=
'OK'
;
$result
->
data
=
$listdataktp
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'your ktp wrong'
;
$result
->
data
=
$listdata
;
}
}
else
{
$result
->
code
=
2
;
$result
->
info
=
'Your no_rekam_medis wrong'
;
}
}
catch
(
\Zend\Db\Adapter\Exception\RuntimeException
$ex
)
{
$result
->
code
=
3
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
catch
(
\Exception
$ex
)
{
$result
->
code
=
4
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
return
$result
;
}
public
function
loadRegisterPoli
(
$id
=
null
){
$result
=
new
Result
();
...
...
@@ -685,6 +926,49 @@ class Mysql extends \Khansia\Db\Storage implements Skeleton {
$sql
.=
" ORDER BY poli.nama_poli asc , register_dokter.create_date"
;
// print_r($sql);die;
$stmt
=
$this
->
_db
->
query
(
$sql
);
$resdata
=
$stmt
->
execute
();
$listdata
=
array
();
foreach
(
$resdata
as
$val
){
// print_r($val);die;
array_push
(
$listdata
,
$val
);
}
if
(
$listdata
)
{
$result
->
code
=
0
;
$result
->
info
=
'OK'
;
$result
->
data
=
$listdata
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'nok'
;
}
}
catch
(
\Zend\Db\Adapter\Exception\RuntimeException
$ex
)
{
$result
->
code
=
3
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
catch
(
\Exception
$ex
)
{
$result
->
code
=
4
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
return
$result
;
}
public
function
loadkelolapasien
(
$id
=
null
){
$result
=
new
Result
();
try
{
$sql
=
" SELECT * FROM pasien"
;
if
(
$id
){
$sql
.=
" WHERE id_pasien =
$id
"
;
}
$sql
.=
" ORDER BY no_rekam_medis ASC"
;
// print_r($sql);die;
$stmt
=
$this
->
_db
->
query
(
$sql
);
$resdata
=
$stmt
->
execute
();
...
...
@@ -813,7 +1097,7 @@ class Mysql extends \Khansia\Db\Storage implements Skeleton {
$result
=
new
Result
();
try
{
$sql
=
"SELECT ruang.id_ruang, ruang.nama_ruang, poli.nama_poli,poli.id_poli, condition.condition,condition.id_condition
$sql
=
"SELECT ruang.id_ruang, ruang.nama_ruang, poli.nama_poli,poli.id_poli, condition.condition,condition.id_condition
, ruang.lantai
FROM RUANG
INNER JOIN poli
ON ruang.id_poli = poli.id_poli
...
...
@@ -857,7 +1141,7 @@ class Mysql extends \Khansia\Db\Storage implements Skeleton {
}
return
$result
;
}
public
function
load
kelolaantrian
(
$id
){
public
function
load
antrianmiss
(
$id
){
$result
=
new
Result
();
try
{
...
...
@@ -877,6 +1161,53 @@ class Mysql extends \Khansia\Db\Storage implements Skeleton {
// print_r($sql);die;
$stmt
=
$this
->
_db
->
query
(
$sql
);
$resdata
=
$stmt
->
execute
();
$listdata
=
array
();
foreach
(
$resdata
as
$val
){
// print_r($val);die;
array_push
(
$listdata
,
$val
);
}
if
(
$listdata
)
{
$result
->
code
=
0
;
$result
->
info
=
'OK'
;
$result
->
data
=
$listdata
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'nok'
;
}
}
catch
(
\Zend\Db\Adapter\Exception\RuntimeException
$ex
)
{
$result
->
code
=
3
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
catch
(
\Exception
$ex
)
{
$result
->
code
=
4
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
return
$result
;
}
public
function
loadantrianunregis
(
$id
){
$result
=
new
Result
();
try
{
$sql
=
"SELECT antrian_pasien.id_pasien, antrian_pasien.nama, antrian_pasien.no_antrian,antrian_pasien.ktp,antrian_pasien.no_rekam_medis,poli.nama_poli,dokter_to_poli.nama_dokter,dokter_to_poli.id_dokter FROM antrian_pasien
INNER JOIN poli
on poli.id_poli = antrian_pasien.id_poli
INNER JOIN dokter_to_poli
on dokter_to_poli.id_dokter = antrian_pasien.id_dokter
WHERE id_pasien IS NOT NULL
ORDER BY poli.nama_poli asc
"
;
// print_r($sql);die;
$stmt
=
$this
->
_db
->
query
(
$sql
);
$resdata
=
$stmt
->
execute
();
...
...
@@ -966,7 +1297,8 @@ class Mysql extends \Khansia\Db\Storage implements Skeleton {
FROM antrian_pasien
INNER JOIN poli
ON antrian_pasien.id_poli = poli.id_poli
GROUP BY poli.id_poli"
;
GROUP BY poli.id_poli
ORDER BY nama_poli asc"
;
...
...
@@ -1046,11 +1378,52 @@ class Mysql extends \Khansia\Db\Storage implements Skeleton {
$result
=
new
Result
();
try
{
$sql
=
"SELECT dokter_to_poli.id_dokter,dokter_to_poli.image
, dokter_to_poli.nama_dokter , poli.nama_poli
$sql
=
"SELECT dokter_to_poli.id_dokter,dokter_to_poli.image
_dokter, dokter_to_poli.nama_dokter , poli.nama_poli , dokter_to_poli.kode_dokter
FROM dokter_to_poli
INNER JOIN poli
ON dokter.id_poli = poli.id_poli
ORDER BY nama_poli ASC "
;
ON dokter_to_poli.id_poli = poli.id_poli
ORDER BY nama_poli ASC "
;
// $sql .= " ORDER BY jumlah DESC";
//print_r($sql);die;
$stmt
=
$this
->
_db
->
query
(
$sql
);
$resdata
=
$stmt
->
execute
();
$listdata
=
array
();
foreach
(
$resdata
as
$val
){
// print_r($val);die;
array_push
(
$listdata
,
$val
);
}
// print_r($listdata);die;
if
(
$listdata
)
{
$result
->
code
=
0
;
$result
->
info
=
'OK'
;
$result
->
data
=
$listdata
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'nok'
;
}
}
catch
(
\Zend\Db\Adapter\Exception\RuntimeException
$ex
)
{
$result
->
code
=
3
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
catch
(
\Exception
$ex
)
{
$result
->
code
=
4
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
return
$result
;
}
public
function
tampildatapoli
(
$id
){
$result
=
new
Result
();
try
{
$sql
=
"SELECT * FROM poli
where id_poli=
$id
"
;
// $sql .= " ORDER BY jumlah DESC";
...
...
@@ -1086,6 +1459,61 @@ class Mysql extends \Khansia\Db\Storage implements Skeleton {
}
return
$result
;
}
public
function
tampilpoli
(
$id
=
null
){
$result
=
new
Result
();
try
{
if
(
$id
){
$sql
=
"SELECT poli.nama_poli, poli.kode_poli, poli.deskripsi_poli ,poli.id_poli, poli.image_poli, dokter_to_poli.nama_dokter, dokter_to_poli.id_dokter, dokter_to_poli.kode_dokter, dokter_to_poli.image_dokter
FROM poli
INNER JOIN dokter_to_poli
ON dokter_to_poli.id_poli = poli.id_poli"
;
$sql
.=
" where poli.id_poli =
$id
"
;
$sql
.=
" ORDER BY poli.nama_poli ASC"
;
}
else
{
$sql
=
"SELECT * FROM poli"
;
}
// print_r($sql);die;
$stmt
=
$this
->
_db
->
query
(
$sql
);
$resdata
=
$stmt
->
execute
();
$listdata
=
array
();
foreach
(
$resdata
as
$val
){
// print_r($val);die;
array_push
(
$listdata
,
$val
);
}
// print_r($listdata);die;
if
(
$listdata
)
{
$result
->
code
=
0
;
$result
->
info
=
'OK'
;
$result
->
data
=
$listdata
;
}
else
{
$result
->
code
=
1
;
$result
->
info
=
'nok'
;
}
}
catch
(
\Zend\Db\Adapter\Exception\RuntimeException
$ex
)
{
$result
->
code
=
3
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
catch
(
\Exception
$ex
)
{
$result
->
code
=
4
;
$result
->
info
=
'ERROR : '
.
$ex
->
getMessage
();
}
return
$result
;
}
public
function
loadPilihAntrian
(
$iddok
){
$result
=
new
Result
();
...
...
module/Application/view/application/admin/dasboard.phtml
View file @
cd87a10e
<!-- Begin Page Content -->
<div
class=
"container-fluid"
>
<!-- Content Row -->
<div
class=
"row"
>
<!-- Earnings (Monthly) Card Example -->
<div
class=
"col-xl-3 col-md-6 mb-4"
>
<div
class=
"card border-left-primary shadow h-100 py-2"
>
<div
class=
"card-body"
>
<div
class=
"row no-gutters align-items-center"
>
<div
class=
"col mr-2"
>
<div
class=
"text-xs font-weight-bold text-primary text-uppercase mb-1"
>
Jumlah Pasien
</div>
<div
id=
"jumlah_pasien"
class=
"h5 mb-0 font-weight-bold text-gray-800"
>
</div>
</div>
<div
class=
"col-auto"
>
<i
class=
"fas fa-clipboard-list fa-2x text-gray-300"
></i>
</div>
</div>
</div>
</div>
</div>
<!-- Earnings (Monthly) Card Example -->
<div
class=
"col-xl-3 col-md-6 mb-4"
>
<div
class=
"card border-left-success shadow h-100 py-2"
>
<div
class=
"card-body"
>
<div
class=
"row no-gutters align-items-center"
>
<div
class=
"col mr-2"
>
<div
class=
"text-xs font-weight-bold text-success text-uppercase mb-1"
>
Pasien Dalam Antrian
</div>
<div
id=
"pasien_antrian"
class=
"h5 mb-0 font-weight-bold text-gray-800"
></div>
</div>
<div
class=
"col-auto"
>
<i
class=
"fas fa-clipboard-list fa-2x text-gray-300"
></i>
</div>
</div>
</div>
</div>
</div>
<!-- Earnings (Monthly) Card Example -->
<div
class=
"col-xl-3 col-md-6 mb-4"
>
<div
class=
"card border-left-info shadow h-100 py-2"
>
<div
class=
"card-body"
>
<div
class=
"row no-gutters align-items-center"
>
<div
class=
"col mr-2"
>
<div
class=
"text-xs font-weight-bold text-info text-uppercase mb-1"
>
Pasien Terlewat
</div>
<div
class=
"row no-gutters align-items-center"
>
<div
class=
"col-auto"
>
<div
id=
"pasien_terlewat"
class=
"h5 mb-0 mr-3 font-weight-bold text-gray-800"
></div>
</div>
</div>
</div>
<div
class=
"col-auto"
>
<i
class=
"fas fa-clipboard-list fa-2x text-gray-300"
></i>
</div>
</div>
</div>
</div>
</div>
<!-- Pending Requests Card Example -->
<div
class=
"col-xl-3 col-md-6 mb-4"
>
<div
class=
"card border-left-warning shadow h-100 py-2"
>
<div
class=
"card-body"
>
<div
class=
"row no-gutters align-items-center"
>
<div
class=
"col mr-2"
>
<div
class=
"text-xs font-weight-bold text-warning text-uppercase mb-1"
>
Pasien Terlayani
</div>
<div
id=
"jumlah_terlayani"
class=
"h5 mb-0 font-weight-bold text-gray-800"
></div>
</div>
<div
class=
"col-auto"
>
<i
class=
"fas fa-clipboard-list fa-2x text-gray-300"
></i>
</div>
</div>
</div>
</div>
</div>
</div>
<!-- Content Row -->
<div
class=
"row"
>
<!-- Pie Chart -->
<div
class=
"col-xl-4 col-lg-5"
>
<div
class=
"card shadow mb-4"
>
<!-- Card Header - Dropdown -->
<div
class=
"card-header py-3 d-flex flex-row align-items-center justify-content-between"
>
<h6
class=
"m-0 font-weight-bold text-primary"
>
Revenue Sources
</h6>
<div
class=
"dropdown no-arrow"
>
<a
class=
"dropdown-toggle"
href=
"#"
role=
"button"
id=
"dropdownMenuLink"
data-toggle=
"dropdown"
aria-haspopup=
"true"
aria-expanded=
"false"
>
<i
class=
"fas fa-ellipsis-v fa-sm fa-fw text-gray-400"
></i>
</a>
<div
class=
"dropdown-menu dropdown-menu-right shadow animated--fade-in"
aria-labelledby=
"dropdownMenuLink"
>
<div
class=
"dropdown-header"
>
Dropdown Header:
</div>
<a
class=
"dropdown-item"
href=
"#"
>
Action
</a>
<a
class=
"dropdown-item"
href=
"#"
>
Another action
</a>
<div
class=
"dropdown-divider"
></div>
<a
class=
"dropdown-item"
href=
"#"
>
Something else here
</a>
</div>
</div>
</div>
<!-- Card Body -->
<div
class=
"card-body"
>
<div
class=
"chart-pie pt-4 pb-2"
>
<canvas
id=
"myPieChart"
></canvas>
</div>
<div
class=
"mt-4 text-center small"
>
<span
class=
"mr-2"
>
<i
class=
"fas fa-circle text-primary"
></i>
Direct
</span>
<span
class=
"mr-2"
>
<i
class=
"fas fa-circle text-success"
></i>
Social
</span>
<span
class=
"mr-2"
>
<i
class=
"fas fa-circle text-info"
></i>
Referral
</span>
</div>
</div>
</div>
</div>
</div>
<!-- Content Row -->
<div
class=
"row"
>
>
</div>
</div>
<!-- /.container-fluid -->
\ No newline at end of file
module/Application/view/application/admin/keloladokter.phtml
View file @
cd87a10e
<!DOCTYPE html>
<html>
<head>
</head>
<body>
<div
class=
"container-fluid"
>
<div
class=
"col-xl-12 col-lg-12 col-md-12"
>
<div
class=
"card o-hidden border-0 shadow-lg my-5"
>
...
...
@@ -12,11 +6,15 @@
<button
type=
"button"
class=
"btn btn-primary fa fa-plus btn-lg"
data-toggle=
"modal"
data-target=
"#addData"
id=
"tambahmodal"
>
Tambah
</button>
<br>
<br>
<table
class=
"table table-bordered"
id=
"dataTable"
>
<thead>
<tr>
<tr
class=
"table-infos"
>
<th
style=
"width: 70px"
>
NO
</>
<th
style=
"width: 70px"
>
NO
</
th
>
<!-- <th colspan="" class=" thLeftText">Id Poli</th> -->
<th
colspan=
""
class=
" thLeftText"
>
Nama Poli
</th>
<th
colspan=
""
class=
" thLeftText"
>
Nama Dokter
</th>
...
...
@@ -53,7 +51,7 @@
<div
class=
"form-group"
>
<label>
Nama Poli
</label>
<select
name=
"
nama_
poli"
id=
"poli"
class=
"form-control"
>
<select
name=
"poli"
id=
"poli"
class=
"form-control"
>
<option
disable
selected
>
Pilih
</option>
</select>
...
...
@@ -138,6 +136,3 @@
</div>
</div>
</body>
</html>
module/Application/view/application/admin/kelolapasien.phtml
View file @
cd87a10e
...
...
@@ -3,31 +3,19 @@
<div
class=
"col-xl-12 col-lg-12 col-md-12"
>
<div
class=
"card o-hidden border-0 shadow-lg my-5"
>
<div
class=
"card-body "
>
<h1
class=
"h4 text-center text-gray-900 mb-4"
style=
"font-size: 50px;font-weight: bold"
>
Kelola Antrian Pasien
</h1>
<!-- <form class="form-inline">
<div class="form-group form-control-lg ">
<label >Pilih poli </label>
<select name="nama_poli" id="poli" class="form-control" >
<option disabled selected>Pilih </option>
</select>
</div>
<div class="form-group form-control-lg">
<label>Pilih dokter</label> <br>
<select id="dokter" name="nama_dokter" class="form-control">
<option disabled selected> Pilih </option>
</select>
</div>
</form> -->
<br>
<h1
class=
"h4 text-center text-gray-900 mb-4"
style=
"font-size: 50px;font-weight: bold"
>
Kelola Pasien
</h1>
<table
class=
"table table-bordered"
id=
"dataTable"
>
<thead
>
<tr>
<th
style=
"width: 70px"
>
NO
</th>
<th
colspan=
""
class=
" thLeftText"
>
NO Antrian Pasien
</th>
<th
colspan=
""
class=
" thLeftText"
>
NO Rekam Medis
</th>
<th
colspan=
""
class=
" thLeftText"
>
No Induk Kependudukan (NIK)
</th>
<th
colspan=
""
class=
" thLeftText"
>
Nama Pasien
</th>
<th
colspan=
""
class=
" thLeftText"
>
Nama Dokter
</th>
<th
colspan=
""
class=
" thLeftText"
>
Nama Poli
</th>
<th
colspan=
""
class=
" thLeftText"
>
Status
</th>
<th
colspan=
""
class=
" thLeftText"
>
Tempat Lahir
</th>
<th
colspan=
""
class=
" thLeftText"
>
Tanggal Lahir
</th>
<th
colspan=
""
class=
" thLeftText"
>
Alamat
</th>
<th
colspan=
""
class=
" thLeftText"
>
No Hp
</th>
<th
colspan=
""
class=
" thLeftText"
>
Tanggal Pendaftaran
</th>
<th
colspan=
""
class=
" thLeftText"
>
Action
</th>
</tr>
</thead>
...
...
@@ -40,3 +28,65 @@
</div>
</div>
<div
id=
"Editdata"
class=
"modal fade"
role=
"dialog"
>
<div
class=
"modal-dialog"
>
<!-- Modal content-->
<div
class=
"modal-content"
>
<div
class=
"modal-header"
>
<h4
class=
"modal-title"
>
Edit Data Dokter
</h4>
<button
type=
"button"
class=
"close"
data-dismiss=
"modal"
>
×
</button>
</div>
<div
class=
"modal-body"
>
<form
id=
"myForm"
>
<input
type=
"text"
id=
"id_pasien"
class=
"form-control"
/></input>
<div
class=
"form-group"
>
<label>
No Rekam Medis
</label><br>
<input
type=
"number"
id=
"no_rekam_medis"
placeholder=
"No Rekam Medis"
class=
"form-control"
max=
"999999999999999"
maxlength=
"8"
disabled
></input>
</div>
<div
class=
"form-group"
>
<label>
No Induk Kependudukan (NIK)
</label>
<input
type=
"number"
id=
"ktp"
class=
"form-control"
placeholder=
"No Induk Kependudukan (NIK)"
max=
"9999999999999999"
maxlength=
"16"
></input>
</div>
<div
class=
"form-group"
>
<label>
Nama Pasien
</label>
<input
type=
"text"
id=
"nama"
class=
"form-control"
placeholder=
"Nama Lengkap"
></input>
</div>
<div
class=
"form-group "
>
<label>
Tempat Lahir
</label>
<textarea
type=
"text"
id=
"tempat_lahir"
class=
"form-control "
placeholder=
"Tempat Lahir"
></textarea
>
</div>
<div
class=
"form-group"
>
<label>
Tanggal Lahir
</label>
<input
type=
"date"
id=
"tanggal_lahir"
class=
"form-control"
/></input>
</div>
<div
class=
"form-group"
>
<label>
Alamat
</label>
<textarea
type=
"text"
id=
"alamat"
rows=
"3"
class=
"form-control"
placeholder=
"Alamat"
/></textarea
>
</div>
<div
class=
"form-group"
>
<label>
No HP
</label>
<input
type=
"number"
id=
"no_hp"
class=
"form-control "
placeholder=
"No Handphone"
maxlength=
"13"
/></input>
</div>
<div
class=
"modal-footer"
>
<button
button
type=
"button"
class=
"btn btn-primary"
id=
"edit"
>
Edit
</button>
<button
button
type=
"button"
class=
"btn btn-danger"
onclick=
"reset()"
>
Reset
</button>
<button
type=
"submit"
class=
"btn btn-default"
data-dismiss=
"modal"
>
Close
</button>
</div>
</form>
</div>
</div>
</div>
</div>
module/Application/view/application/admin/kelolapoli.phtml
View file @
cd87a10e
...
...
@@ -53,32 +53,28 @@
<button
type=
"button"
class=
"close"
data-dismiss=
"modal"
>
×
</button>
</div>
<div
class=
"modal-body"
>
<form
id=
"myForm"
>
<form
id=
"myForm"
>
<div
class=
"form-group"
>
<label>
Nama Poli
</label>
<input
type=
"input"
id=
"nama_poli"
name=
"nama_poli"
class=
"form-control"
placeholder=
"Nama Poli"
required
/
></input>
<input
type=
"input"
id=
"nama_poli"
name=
"nama_poli"
class=
"form-control"
placeholder=
"Nama Poli"
required
></input>
</select>
</div>
<div
class=
"form-group"
>
<label>
Kode Poli
</label>
<input
type=
"input"
id=
"kode_poli"
name=
"kode_poli"
class=
"form-control"
placeholder=
"Kode Poli"
required
/
></input>
<input
type=
"input"
id=
"kode_poli"
name=
"kode_poli"
class=
"form-control"
placeholder=
"Kode Poli"
required
></input>
</div>
<div
class=
"form-group"
>
<label>
Deskripsi Poli
</label>
<textarea
type=
"
type
"
id=
"deskripsi_poli"
name=
"deskripsi_poli"
class=
"form-control"
placeholder=
"Deskripsi Poli"
required
></textarea>
<textarea
type=
"
input"
style=
"height:100px;
"
id=
"deskripsi_poli"
name=
"deskripsi_poli"
class=
"form-control"
placeholder=
"Deskripsi Poli"
required
></textarea>
</div>
<!-- <div class="form-group ">
<div
class=
"form-group "
>
<label>
Gambar Poli
</label>
<input type="file" name="
uploadimage" id="uploadimage" class="form-control
">
</div>
-->
<input
type=
"file"
name=
"
image_poli"
id=
"image_poli"
class=
"form-control-file
"
>
</div>
<div
class=
"modal-footer"
>
<button
button
type=
"button"
class=
"btn btn-primary"
id=
"tambah"
>
Add
</button>
<button
button
type=
"button"
class=
"btn btn-danger"
onclick=
"reset()"
>
Reset
</button>
<button
type=
"button"
class=
"btn btn-primary"
id=
"tambah"
>
Add
</button>
<button
type=
"button"
class=
"btn btn-danger"
onclick=
"reset()"
>
Reset
</button>
<button
type=
"submit"
class=
"btn btn-default"
data-dismiss=
"modal"
>
Close
</button>
</div>
</form>
...
...
@@ -106,23 +102,23 @@
<div
class=
"form-group"
>
<label>
Nama Poli
</label>
<input
type=
"input"
id=
"nama_poliEdt"
name=
"nama_poli"
class=
"form-control"
placeholder=
"Nama Poli"
required
/
></input>
<input
type=
"input"
id=
"nama_poliEdt"
name=
"nama_poli"
class=
"form-control"
placeholder=
"Nama Poli"
required
></input>
</select>
</div>
<div
class=
"form-group"
>
<label>
Kode Poli
</label>
<input
type=
"input"
id=
"kode_poliEdt"
name=
"kode_poli"
class=
"form-control"
placeholder=
"Kode Poli"
required
/
></input>
<input
type=
"input"
id=
"kode_poliEdt"
name=
"kode_poli"
class=
"form-control"
placeholder=
"Kode Poli"
required
></input>
</div>
<div
class=
"form-group"
>
<label>
Deskripsi Poli
</label>
<textarea
type=
"
type
"
id=
"deskripsi_poliEdt"
name=
"deskripsi_poli"
class=
"form-control"
placeholder=
"Deskripsi Poli"
required
></textarea>
<textarea
type=
"
input"
style=
"height:100px;
"
id=
"deskripsi_poliEdt"
name=
"deskripsi_poli"
class=
"form-control"
placeholder=
"Deskripsi Poli"
required
></textarea>
</div>
<
!-- <
div class="form-group ">
<div
class=
"form-group "
>
<label>
Gambar Poli
</label>
<input type="file" name="
uploadimage" id="uploadimage" class="form-control"
>
</div>
-->
<input
type=
"file"
name=
"
image_poli"
id=
"image_poliedt"
class=
"form-control-file"
></input
>
</div>
<div
class=
"modal-footer"
>
<button
button
type=
"button"
class=
"btn btn-primary"
id=
"edit"
>
Edit
</button>
<button
button
type=
"button"
class=
"btn btn-danger"
onclick=
"reset()"
>
Reset
</button>
...
...
@@ -136,3 +132,4 @@
</div>
module/Application/view/application/admin/kelolaruangan.phtml
View file @
cd87a10e
...
...
@@ -26,6 +26,7 @@
<th
style=
"width: 70px"
>
NO
</th>
<!-- <th colspan="" class=" thLeftText">Id Poli</th> -->
<th
colspan=
""
class=
" thLeftText"
>
Nama Poli
</th>
<th
colspan=
""
class=
" thLeftText"
>
Lantai
</th>
<th
colspan=
""
class=
" thLeftText"
>
Ruangan
</th>
<th
colspan=
""
class=
" thLeftText"
>
Kondisi Ruang
</th>
<th
colspan=
""
class=
" thLeftText"
>
Action
</th>
...
...
@@ -62,13 +63,17 @@
<option
disable
selected
>
Pilih
</option>
</select>
</div>
<div
class=
"form-group"
>
<label>
Lantai
</label>
<input
type=
"input"
id=
"lantai"
name=
"nama_ruang"
class=
"form-control"
placeholder=
"Lantai Ruangan"
required
/></input>
</div>
<div
class=
"form-group"
>
<label>
Ruangan
</label>
<input
type=
"input"
id=
"nama_ruang"
name=
"nama_ruang"
class=
"form-control"
placeholder=
"
Lantai Ruangan &
Nama Ruangan"
required
/></input>
<input
type=
"input"
id=
"nama_ruang"
name=
"nama_ruang"
class=
"form-control"
placeholder=
"Nama Ruangan"
required
/></input>
</div>
<div
class=
"modal-footer"
>
<button
button
type=
"button"
class=
"btn btn-primary"
id=
"tambah"
>
Add
</button>
<button
button
type=
"button"
class=
"btn btn-danger"
onclick=
"reset()"
>
Reset
</button>
<button
type=
"button"
class=
"btn btn-primary"
id=
"tambah"
>
Add
</button>
<button
type=
"button"
class=
"btn btn-danger"
onclick=
"reset()"
>
Reset
</button>
<button
type=
"submit"
class=
"btn btn-default"
data-dismiss=
"modal"
>
Close
</button>
</div>
</form>
...
...
@@ -96,6 +101,10 @@
</select>
</div
>
<div
class=
"form-group"
>
<label>
Lantai
</label>
<input
type=
"input"
id=
"lantaiedt"
name=
"lantai"
class=
"form-control"
placeholder=
"Lantai Ruangan & Nama Ruangan"
required
/></input>
</div>
<div
class=
"form-group"
>
<label>
Ruangan
</label>
<input
type=
"input"
id=
"nama_ruangedt"
name=
"nama_ruang"
class=
"form-control"
placeholder=
"Lantai Ruangan & Nama Ruangan"
required
/></input>
...
...
module/Application/view/application/admin/registrasidokter.phtml
View file @
cd87a10e
...
...
@@ -12,7 +12,7 @@
<thead>
<tr
class=
"table-infos"
>
<th
style=
""
>
NO
</th>
<th
colspan=
""
class=
" thLeftText"
>
Jenis Layanan (Poli)
</th>
<th
colspan=
""
class=
" thLeftText"
>
Nama Poli
</th>
<th
colspan=
""
class=
" thLeftText"
>
Nama Dokter
</th>
<th
colspan=
""
class=
" thLeftText"
>
Ruangan
</th>
<th
colspan=
""
class=
" thLeftText"
>
Antrian Seluruh
</th>
...
...
module/Application/view/application/queue/cekdatapasien.phtml
View file @
cd87a10e
...
...
@@ -42,7 +42,12 @@ input::-webkit-inner-spin-button {
<div
class=
"form-group"
>
<label>
<h5>
No Rekam Medis
</h5></label><br>
<input
type=
"number"
id=
"no_rekam_medis"
placeholder=
"No Rekam Medis"
class=
"form-control"
max=
"999999999999999"
maxlength=
"8"
style=
"width: 950px;display:inline;"
></input>
<input
type=
"number"
id=
"no_rekam_medis"
placeholder=
"No Rekam Medis"
class=
"form-control"
max=
"999999999999999"
maxlength=
"8"
></input>
</div>
<div
class=
"form-group"
>
<label>
<h5>
No Induk Kependudukan (NIK)
</h5></label><br>
<input
type=
"number"
id=
"ktp"
placeholder=
"No Induk Kependudukan (NIK)"
class=
"form-control"
max=
"9999999999999999"
maxlength=
"16"
></input>
</div>
<p
class=
"card-text"
style=
"display:inline"
>
Jika belum mempunyai no rekam medis,
</p>
<a
class=
"card-text"
href=
"
<?php
echo
$this
->
basePath
(
'queue/daftarpasien'
)
?>
"
style=
"display:inline"
>
Klik disini !
</a>
...
...
module/Application/view/application/queue/daftarpasien.phtml
View file @
cd87a10e
...
...
@@ -5,6 +5,7 @@ input::-webkit-inner-spin-button {
margin
:
0
;
}
</style>
...
...
@@ -41,14 +42,22 @@ input::-webkit-inner-spin-button {
<input
type=
"hidden"
id=
"iInput"
class=
"form-control"
/></input>
<div
class=
"form-group"
>
<label><h5>
No Induk K
TP
</h5></label>
<input
type=
"number"
id=
"ktp"
class=
"form-control"
placeholder=
"No Induk K
TP
"
max=
"9999999999999999"
maxlength=
"16"
></input>
<label><h5>
No Induk K
ependudukan (NIK)
</h5></label>
<input
type=
"number"
id=
"ktp"
class=
"form-control"
placeholder=
"No Induk K
ependudukan (NIK)
"
max=
"9999999999999999"
maxlength=
"16"
></input>
</div>
<div
class=
"form-group"
>
<label><h5>
Nama Pasien
</h5></label>
<input
type=
"text"
id=
"nama"
class=
"form-control"
placeholder=
"Nama Lengkap"
></input>
</div>
<!-- <div class="form-group">
<label><h5>Jenis Kelamin</h5></label> <br>
<input type="radio" id="male" name="gender" value="male">
<label for="male"><h5>Laki-laki </h5></label>
<input type="radio" id="female" name="gender" value="female">
<label for="female"><h5>Perempuan </h5></label>
</div> -->
<div
class=
"form-group "
>
<label><h5>
Tempat Lahir
</h5></label>
...
...
@@ -68,6 +77,8 @@ input::-webkit-inner-spin-button {
<label><h5>
No HP
</h5></label>
<input
type=
"number"
id=
"no_hp"
class=
"form-control "
placeholder=
"No Handphone"
maxlength=
"13"
/></input>
</div>
</form>
...
...
module/Application/view/application/queue/datapasien.phtml
View file @
cd87a10e
...
...
@@ -63,9 +63,6 @@ input[type="picked"] + label {
width
:
55px
;
cursor
:
not-allowed
;
text-align
:
center
;
}
...
...
module/Application/view/application/queue/dokter.phtml
View file @
cd87a10e
...
...
@@ -20,7 +20,7 @@
<!-- breadcrumb start-->
<!--::doctor_part start::-->
<section
class=
"doctor_part single_page_doctor_part"
>
<section
class=
"doctor_part single_page_doctor_part"
style=
"padding:20px;"
>
<div
class=
"container"
>
<div
class=
"row justify-content-center"
>
<div
class=
"col-xl-8"
>
...
...
@@ -34,26 +34,5 @@
<div
class=
"row dokter"
>
</div>
<!-- <div class="row">
<div class="col-sm-6 col-lg-3">
<div class="single_blog_item">
<div class="single_blog_img">
<img src="
<?php
$this
->
basePath
(
'samss/'
)
?>
/tamplate/img/doctor/doctor_1.png" alt="doctor">
</div>
<div class="single_text">
<div class="single_blog_text">
<h3>DR Adam Billiard</h3>
<p> Spesialis Umum</p>
</div>
</div>
</div>
</div>
</div> -->
</div>
</section>
<!--::doctor_part end::-->
\ No newline at end of file
module/Application/view/application/queue/poli.phtml
View file @
cd87a10e
...
...
@@ -20,46 +20,18 @@
<!-- breadcrumb start-->
<!-- feature_part start-->
<section
class=
"
feature_part
"
>
<section
class=
"
doctor_part single_page_doctor_part"
style=
"padding:0px;
"
>
<div
class=
"container"
>
<div
class=
"row justify-content-center"
>
<div
class=
"col-xl-8"
>
<div
class=
"section_tittle text-center"
>
<h2>
Poli Kami
</h2>
<h2>
Poli Kami
</h2>
</div>
</div>
</div>
<div
class=
"row justify-content-between align-items-center"
>
<div
class=
"col-lg-3 col-md-4 col-xs-6 thumb"
>
<div
class=
"single_feature"
>
<div
class=
"single_feature_part"
>
<span
class=
"single_feature_icon"
><img
src=
"
<?php
$this
->
basePath
(
''
)
?>
/tamplate/img/icon/gigi.png"
alt=
""
></span>
<h4>
Poli Gigi
</h4>
<p>
Poli gigi adalah...
</p>
</div>
</div>
<div
class=
"single_feature"
>
<div
class=
"single_feature_part"
>
<span
class=
"single_feature_icon"
><img
src=
"
<?php
$this
->
basePath
(
''
)
?>
/tamplate/img/icon/mata.png"
alt=
""
></span>
<h4>
Poli Mata
</h4>
<p>
Poli mata adalah...
</p>
</div>
</div>
</div>
<div
class=
"col-lg-4 col-sm-12"
>
<div
class=
"single_feature_img"
>
<img
src=
"
<?php
$this
->
basePath
(
''
)
?>
/tamplate/img/service.png"
alt=
""
>
</div>
</div>
<div
class=
"col-lg-3 col-sm-12"
>
<div
class=
"single_feature"
>
<div
class=
"single_feature_part"
>
<span
class=
"single_feature_icon"
><img
src=
"
<?php
$this
->
basePath
(
''
)
?>
/tamplate/img/icon/umum.png"
alt=
""
></span>
<h4>
Poli Umum
</h4>
<p>
Poli umum adalah...
</p>
</div>
</div>
</div>
<div
class=
"row poli"
>
</div>
</div>
</section>
...
...
module/Application/view/layout/layoutAdmin.phtml
View file @
cd87a10e
...
...
@@ -57,7 +57,7 @@
<script
src=
"
<?php
$this
->
basePath
();
?>
/tamplateadmin/assets/js/plugins/notifications/sweet_alert.min.js"
></script>
<script
src=
"
<?php
$this
->
basePath
();
?>
/tamplate/js/bootbox.all.min.js"
></script>
<!-- Page level custom scripts -->
<!-- <script src="
<?php
$this
->
basePath
();
?>
/tamplateadmin/js/demo/datatables-demo.js"></script> --
>
<script
src=
"
<?php
$this
->
basePath
();
?>
/tamplateadmin/vendor/chart.js/Chart.min.js"
></script
>
<body
id=
"page-top"
>
...
...
@@ -120,13 +120,24 @@
<div
class=
"sidebar-heading"
>
Feature
</div>
<li
class=
"nav-item"
>
<a
class=
"nav-link collapsed"
href=
"#"
data-toggle=
"collapse"
data-target=
"#collapsePages"
aria-expanded=
"true"
aria-controls=
"collapsePages"
>
<i
class=
"fas fa-fw fa-table"
></i>
<span>
Kelola Antrian Pasien
</span>
</a>
<div
id=
"collapsePages"
class=
"collapse"
aria-labelledby=
"headingPages"
data-parent=
"#accordionSidebar"
>
<div
class=
"bg-white py-2 collapse-inner rounded"
>
<a
class=
"collapse-item"
href=
"
<?php
echo
$this
->
basePath
(
'admin/antrianterlewat'
)
?>
"
>
Antrian Terlewat
</a>
<a
class=
"collapse-item"
href=
"
<?php
echo
$this
->
basePath
(
'admin/antrianunregister'
)
?>
"
>
Antrian Unregister
</a>
</div>
</div>
</li>
<li
class=
"nav-item"
>
<a
class=
"nav-link collapsed"
href=
"
<?php
echo
$this
->
basePath
(
'admin/kelolapasien'
)
?>
"
>
<i
class=
"fas fa-fw fa-table"
></i>
<span>
Kelola
Antria
n
</span>
<span>
Kelola
Pasie
n
</span>
</a>
</li>
...
...
module/Application/view/layout/layoutQueue.phtml
View file @
cd87a10e
...
...
@@ -43,6 +43,15 @@
float
:
left
;
margin
:
5px
;
margin-bottom
:
1px
;
}
#h6a
{
display
:
block
;
margin-block-start
:
0em
;
margin-block-end
:
0em
;
margin-inline-start
:
0px
;
margin-inline-end
:
0px
;
font-weight
:
bold
;
}
</style>
<body>
...
...
@@ -54,9 +63,7 @@
<div
class=
"col-lg-12"
>
<nav
class=
"navbar navbar-expand-lg navbar-light"
>
<a
class=
"navbar-brand"
href=
"
<?php
echo
$this
->
basePath
(
'queue/beranda'
);
?>
"
>
<img
src=
"
<?php
echo
$this
->
basePath
();
?>
/tamplate/img/logo.png"
alt=
"logo"
>
</a>
<button
class=
"navbar-toggler"
type=
"button"
data-toggle=
"collapse"
data-target=
"#navbarSupportedContent"
aria-controls=
"navbarSupportedContent"
aria-expanded=
"false"
aria-label=
"Toggle navigation"
>
<button
class=
"navbar-toggler"
type=
"button"
data-toggle=
"collapse"
data-target=
"#navbarSupportedContent"
aria-controls=
"navbarSupportedContent"
aria-expanded=
"false"
aria-label=
"Toggle navigation"
>
<span
class=
"navbar-toggler-icon"
></span>
</button>
<div
class=
"collapse navbar-collapse main-menu-item justify-content-center"
...
...
@@ -66,18 +73,20 @@
<a
class=
"nav-link"
href=
"
<?php
echo
$this
->
basePath
(
'queue/beranda'
)
?>
"
>
Beranda
</a>
</li>
<li
class=
"nav-item"
>
<a
class=
"nav-link"
href=
"
<?php
echo
$this
->
basePath
(
'queue/cekdatapasien'
)
?>
"
>
Registrasi
</a>
<a
class=
"nav-link"
href=
"
<?php
echo
$this
->
basePath
(
'queue/cekdatapasien'
)
?>
"
>
Registrasi
Antrian
</a>
</li>
<!-- <li class="nav-item">
<a class="nav-link" href="
<?php
echo
$this
->
basePath
(
'queue/'
)
?>
">Pilih Antrian</a>
</li> -->
<li
class=
"nav-item"
>
<a
class=
"nav-link"
href=
"
<?php
echo
$this
->
basePath
(
'queue/dokter'
)
?>
"
>
Doctors
</a>
</li>
<li
class=
"nav-item"
>
<a
class=
"nav-link"
href=
"
<?php
echo
$this
->
basePath
(
'queue/poli'
)
?>
"
>
Poli
</a>
</li>
<!-- <li class="nav-item">
<a class="nav-link " href="
<?php
echo
$this
->
basePath
(
'user/login'
)
?>
">Login</a>
</li>
-->
</ul>
</div>
</nav>
...
...
@@ -106,21 +115,17 @@
<div
class=
"col-xl-2 col-md-4 col-sm-6 single-footer-widget"
>
<a
href=
"#"
class=
"footer_logo"
>
<img
src=
"
<?php
$this
->
basePath
(
'queue/beranda'
)
?>
/tamplate/img/logo.png"
alt=
"#"
>
</a>
<p>
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor
</p>
<div
class=
"social_logo"
>
<a
href=
"#"
><i
class=
"ti-facebook"
></i></a>
<a
href=
"#"
>
<i
class=
"ti-twitter"
></i>
</a>
<a
href=
"#"
><i
class=
"ti-instagram"
></i></a>
<a
href=
"#"
><i
class=
"ti-skype"
></i></a>
</div>
</div>
<div
class=
"col-xl-9 col-sm-6 col-md-4 single-footer-widget"
>
<h4>
Quick Links
</h4>
<ul>
<li><a
href=
"#"
>
Beranda
</a></li>
<li><a
href=
"#"
>
Registrasi Antrian
</a></li>
<li><a
href=
"#"
>
Dokter
</a></li>
<li><a
href=
"#"
>
Poli
</a></li>
<li><a
href=
"#"
>
Tentang Kami
</a></li>
<li><a
href=
"
<?php
echo
$this
->
basePath
(
'queue/beranda'
)
?>
"
>
Beranda
</a></li>
<li><a
href=
"
<?php
echo
$this
->
basePath
(
'queue/pocekdatapasienli'
)
?>
"
>
Registrasi Antrian
</a></li>
<li><a
href=
"
<?php
echo
$this
->
basePath
(
'queue/dokter'
)
?>
"
>
Dokter
</a></li>
<li><a
href=
"
<?php
echo
$this
->
basePath
(
'queue/poli'
)
?>
"
>
Poli
</a></li>
<li><a
href=
"
<?php
echo
$this
->
basePath
(
'user/login'
)
?>
"
>
Login
</a></li>
</ul>
</div>
...
...
@@ -143,13 +148,8 @@
is made with
<i
class=
"ti-heart"
aria-hidden=
"true"
></i>
by
<a
href=
"https://colorlib.com"
target=
"_blank"
>
Colorlib
</a>
<!-- Link back to Colorlib can't be removed. Template is licensed under CC BY 3.0. -->
</p>
<div
class=
"col-lg-4 col-md-12 text-center text-lg-right footer-social"
>
<a
href=
"#"
><i
class=
"ti-facebook"
></i></a>
<a
href=
"#"
>
<i
class=
"ti-twitter"
></i>
</a>
<a
href=
"#"
><i
class=
"ti-instagram"
></i></a>
<a
href=
"#"
><i
class=
"ti-skype"
></i></a>
</div>
</div>
</div>
</div>
...
...
public/action-js/antrian-js/action-cekdatapasien.js
View file @
cd87a10e
$
(
'
#cekdata
'
).
on
(
'
click
'
,
function
()
{
let
no_rekam_medis
=
$
(
'
#no_rekam_medis
'
).
val
();
cekpasien
(
no_rekam_medis
);
let
ktp
=
$
(
'
#ktp
'
).
val
();
cekpasien
(
no_rekam_medis
,
ktp
);
})
function
cekpasien
()
{
let
no_rekam_medis
=
$
(
'
#no_rekam_medis
'
).
val
();
// alert(no_rekam_medis);
function
cekpasien
(
no_rekam_medis
,
ktp
)
{
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/cekpasien
'
,
data
:
{
ino_rekam_medis
:
no_rekam_medis
,
iktp
:
ktp
,
},
success
:
function
(
result
)
{
// let data = result.data['datapasien'][0]['no_rekam_medis'];
// let validasi = result.data['validasiinput'];
console
.
log
(
result
);
if
(
result
.
code
!=
0
)
{
if
(
result
.
code
==
0
)
{
console
.
log
(
result
.
data
);
if
(
result
.
data
[
0
][
'
no_rekam_medis
'
]
==
null
)
{
let
$id
=
result
.
data
[
0
][
'
id_pasien
'
];
bootbox
.
alert
({
message
:
"
No rekam medis atau NIK tidak sesuai!
"
,
centerVertical
:
true
});
}
else
if
(
result
.
data
[
'
validasiinput
'
]
==
0
)
{
console
.
log
(
result
.
data
[
'
datapasien
'
][
0
][
'
no_rekam_medis
'
]
);
// alert('berhasil');
if
(
result
.
data
[
'
datapasien
'
][
0
][
'
no_rekam_medis
'
]
==
null
)
{
let
$id
=
result
.
data
[
'
datapasien
'
][
0
][
'
id_pasien
'
];
let
$encodedId
=
btoa
(
$id
);
window
.
location
.
href
=
(
"
datapasien/
"
+
$encodedId
);
}
if
(
result
.
data
[
0
][
'
no_rekam_medis
'
]
!=
null
&&
(
result
.
data
[
0
][
'
status_code
'
]
==
10
))
{
let
$idantrian
=
result
.
data
[
0
][
'
id_antrian
'
];
if
(
result
.
data
[
'
datapasien
'
][
0
][
'
no_rekam_medis
'
]
!=
null
&&
(
result
.
data
[
'
datapasien
'
]
[
0
][
'
status_code
'
]
==
10
))
{
let
$idantrian
=
result
.
data
[
'
datapasien
'
][
0
][
'
id_antrian
'
];
let
$encodedIdantrian
=
btoa
(
$idantrian
)
let
no_rekam_medis
=
result
.
data
[
0
][
'
no_rekam_medis
'
];
let
nama
=
result
.
data
[
0
][
'
nama
'
];
let
no_rekam_medis
=
result
.
data
[
'
datapasien
'
][
0
][
'
no_rekam_medis
'
];
let
nama
=
result
.
data
[
'
datapasien
'
][
0
][
'
nama
'
];
swal
({
title
:
"
Nama pasien '
"
+
nama
+
"
' sedang dalam antrian.
\n
Apakah anda ingin mencetak no antrian lagi ?
"
,
type
:
"
error
"
,
...
...
@@ -41,40 +50,27 @@ function cekpasien() {
window
.
location
=
(
baseURL
+
"
/queue/cetakantrian/
"
+
$encodedIdantrian
);
});
}
else
if
(
result
.
data
[
0
][
'
status_code
'
]
==
20
)
{
}
else
if
(
result
.
data
[
'
datapasien
'
][
0
][
'
status_code
'
]
==
20
)
{
bootbox
.
alert
({
message
:
"
Pasien Sedang Dalam Antrian
"
,
centerVertical
:
true
});
}
else
if
(
result
.
data
[
0
][
'
status_code
'
]
==
30
)
{
}
else
if
(
result
.
data
[
'
datapasien
'
][
0
][
'
status_code
'
]
==
30
)
{
bootbox
.
alert
({
message
:
"
Pasien Sedang Dalam Panggilan Antrian
"
,
centerVertical
:
true
});
}
else
if
(
result
.
data
[
0
][
'
status_code
'
]
==
40
)
{
}
else
if
(
result
.
data
[
'
datapasien
'
][
0
][
'
status_code
'
]
==
40
)
{
bootbox
.
alert
({
message
:
"
Pasien Sedang Diperika Dokter
"
,
centerVertical
:
true
});
}
else
if
(
result
.
data
[
0
][
'
status_code
'
]
==
50
)
{
}
else
if
(
result
.
data
[
'
datapasien
'
][
0
][
'
status_code
'
]
==
50
)
{
bootbox
.
alert
({
message
:
"
Pasien Telah Selesai Diperiksa
"
,
centerVertical
:
true
});
}
else
if
(
result
.
data
[
0
][
'
status_code
'
]
==
60
)
{
}
else
if
(
result
.
data
[
'
datapasien
'
][
0
][
'
status_code
'
]
==
60
)
{
bootbox
.
alert
({
message
:
"
Pasien Sedang Telah Terlewat Silahkan Hubungi Petugas
"
,
centerVertical
:
true
});
}
// $('#id_pasien').val(data[0].id_pasien);
// $('#no_rekam_medis').val(data[0].no_rekam_medis);
// $('#ktp').val(data[0].ktp);
// $('#nama').val(data[0].nama);
// $('#tempat_lahir').val(data[0].tempat_lahir);
// $('#tanggal_lahir').val(data[0].tanggal_lahir);
// $('#alamat').val(data[0].alamat);
// $('#no_hp').val(data[0].no_hp);
}
else
if
(
result
.
data
[
'
validasiinput
'
]
==
1
)
{
bootbox
.
alert
({
message
:
"
No Induk Kependudukan tidak sesuai
"
,
centerVertical
:
true
});
}
else
{
bootbox
.
alert
({
message
:
"
Pasien Tidak Terdaftar <br> Silahkan Daftar Terlebih Dahulu
"
,
centerVertical
:
true
});
// bootbox.alert({ message: "Pasien Tidak Terdaftar <br> Silahkan Daftar Terlebih Dahulu", centerVertical: true });
}
},
...
...
@@ -85,6 +81,86 @@ function cekpasien() {
}
function
validasidokter
(
no_rekam_medis
,
ktp
)
{
var
exist
=
0
;
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/loadpasien
'
,
async
:
false
,
data
:
{
id
:
null
,
},
success
:
function
(
result
)
{
// console.log(result)
var
data
=
result
.
data
;
for
(
x
in
data
)
{
if
(
no_rekam_medis
==
data
[
x
][
'
no_rekam_medis
'
])
{
exist
=
1
;
}
if
(
ktp
==
data
[
x
][
'
ktp
'
])
{
exist
=
2
;
}
}
},
error
:
function
(
xhr
)
{
//alert(xhr.status+'-'+xhr.statusText);
}
});
return
exist
;
}
var
inputQuantity
=
[];
$
(
function
()
{
$
(
"
#ktp
"
).
each
(
function
(
i
)
{
inputQuantity
[
i
]
=
this
.
defaultValue
;
$
(
this
).
data
(
"
idx
"
,
i
);
// save this field's index to access later
});
$
(
"
#ktp
"
).
on
(
"
keyup
"
,
function
(
e
)
{
var
$field
=
$
(
this
),
val
=
this
.
value
,
$thisIndex
=
parseInt
(
$field
.
data
(
"
idx
"
),
10
);
// retrieve the index
// window.console && console.log($field.is(":invalid"));
// $field.is(":invalid") is for Safari, it must be the last to not error in IE8
if
(
this
.
validity
&&
this
.
validity
.
badInput
||
isNaN
(
val
)
||
$field
.
is
(
"
:invalid
"
))
{
this
.
value
=
inputQuantity
[
$thisIndex
];
return
;
}
if
(
val
.
length
>
Number
(
$field
.
attr
(
"
maxlength
"
)))
{
val
=
val
.
slice
(
0
,
16
);
$field
.
val
(
val
);
}
inputQuantity
[
$thisIndex
]
=
val
;
});
})
var
inputQuantity
=
[];
$
(
function
()
{
$
(
"
#no_rekam_medis
"
).
each
(
function
(
i
)
{
inputQuantity
[
i
]
=
this
.
defaultValue
;
$
(
this
).
data
(
"
idx
"
,
i
);
// save this field's index to access later
});
$
(
"
#no_rekam_medis
"
).
on
(
"
keyup
"
,
function
(
e
)
{
var
$field
=
$
(
this
),
val
=
this
.
value
,
$thisIndex
=
parseInt
(
$field
.
data
(
"
idx
"
),
10
);
// retrieve the index
// window.console && console.log($field.is(":invalid"));
// $field.is(":invalid") is for Safari, it must be the last to not error in IE8
if
(
this
.
validity
&&
this
.
validity
.
badInput
||
isNaN
(
val
)
||
$field
.
is
(
"
:invalid
"
))
{
this
.
value
=
inputQuantity
[
$thisIndex
];
return
;
}
if
(
val
.
length
>
Number
(
$field
.
attr
(
"
maxlength
"
)))
{
val
=
val
.
slice
(
0
,
8
);
$field
.
val
(
val
);
}
inputQuantity
[
$thisIndex
]
=
val
;
});
})
public/action-js/antrian-js/action-cetak.js
View file @
cd87a10e
...
...
@@ -6,11 +6,13 @@ $('#cetak').on('click', function (e) {
w
.
document
.
write
(
'
<html><body><table border="" >
'
+
'
<tr><th><h1>SELAMAT DATANG</h1><h2> Di Rumah Sakit</h2></th></tr></thead>
'
+
'
<tbody><tr>
'
+
'
<th><h2>ANTRIAN</h2>
'
+
'
<th><h3>No Rekam Medis :
'
+
no_rekam_medis_cetak
+
'
</h3>
'
+
'
<h2>ANTRIAN</h2>
'
+
'
<h1>
'
+
kode_dokter_cetak
+
+
no_antrian_cetak
+
'
</h1>
'
+
'
<h3>Nama Pasien :
'
+
nama_pasien_cetak
+
'
</h3>
'
+
'
<h3>Poli :
'
+
kode_poli_cetak
+
'
</h3>
'
+
'
<h3>Nama Dokter :
'
+
nama_dokter_cetak
+
'
</h3>
'
+
'
<h4>Nama Pasien :
'
+
nama_pasien_cetak
+
'
</h4>
'
+
'
<h4>Poli :
'
+
kode_poli_cetak
+
'
</h4>
'
+
'
<h5>Nama Dokter :
'
+
nama_dokter_cetak
+
'
</h5>
'
+
'
<div class="h6a" style="text-align:right;font-size: 11px;";>No rekam medis tidak boleh hilang</div>
'
+
'
</th></tr></tbody></table></body></html>
'
);
w
.
window
.
print
();
w
.
document
.
close
();
...
...
public/action-js/antrian-js/action-daftarpasien.js
View file @
cd87a10e
...
...
@@ -24,12 +24,52 @@ $(document).ready(function () {
$
(
'
#tambahdata
'
).
on
(
'
click
'
,
function
()
{
SaveDataAja
();
let
nama
=
$
(
'
#nama
'
).
val
();
let
tempat_lahir
=
$
(
'
#tempat_lahir
'
).
val
();
let
tanggal_lahir
=
$
(
'
#tanggal_lahir
'
).
val
();
let
alamat
=
$
(
'
#alamat
'
).
val
();
let
no_hp
=
$
(
'
#no_hp
'
).
val
();
let
KTP
=
$
(
'
#ktp
'
).
val
();
if
(
KTP
==
null
||
KTP
==
""
)
{
bootbox
.
alert
({
message
:
'
No Induk Kependudukan (NIK) tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
nama
==
null
||
nama
==
""
)
{
bootbox
.
alert
({
message
:
'
Nama tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
tempat_lahir
==
null
||
tempat_lahir
==
""
)
{
bootbox
.
alert
({
message
:
'
Tempat lahir tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
tanggal_lahir
==
null
||
tanggal_lahir
==
""
)
{
bootbox
.
alert
({
message
:
'
Tanggal lahir tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
alamat
==
null
||
alamat
==
""
)
{
bootbox
.
alert
({
message
:
'
Alamat tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
no_hp
==
null
||
no_hp
==
""
)
{
bootbox
.
alert
({
message
:
'
No hp tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
KTP
.
toString
().
length
>
16
)
{
bootbox
.
alert
({
message
:
'
No Induk Kependudukan (NIK) tidak boleh lebih dari 16 angka
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
KTP
.
toString
().
length
<
16
)
{
bootbox
.
alert
({
message
:
'
No Induk Kependudukan (NIK) tidak boleh kurang dari 16 angka
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
no_hp
.
toString
().
length
>
13
)
{
bootbox
.
alert
({
message
:
'
No HP tidak boleh lebih dari 13 angka
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
validasipoli
(
KTP
)
==
1
)
{
bootbox
.
alert
({
message
:
'
KTP Sudah Digunakan!
'
,
centerVertical
:
true
});
}
else
{
SaveDataAja
();
}
})
function
SaveDataAja
()
{
let
id_pasien
=
$
(
'
#nama
'
).
val
();
let
no_rekam_medis
=
$
(
'
#nama
'
).
val
();
let
id_pasien
=
$
(
'
#id_pasien
'
).
val
();
let
nama
=
$
(
'
#nama
'
).
val
();
let
tempat_lahir
=
$
(
'
#tempat_lahir
'
).
val
();
let
tanggal_lahir
=
$
(
'
#tanggal_lahir
'
).
val
();
...
...
@@ -47,7 +87,6 @@ function SaveDataAja() {
url
:
baseURL
+
'
/api/savedatapasien
'
,
data
:
{
id_pasien
:
id_pasien
,
ino_rekam_medis
:
no_rekam_medis
,
iktp
:
ktp
,
inama
:
nama
,
itempat_lahir
:
tempat_lahir
,
...
...
@@ -60,35 +99,7 @@ function SaveDataAja() {
// alert("success");
// response[data];
// if (ktp == null || ktp == "") {
// bootbox.alert({ message: 'Ktp tidak boleh kosong', centerVertical: true });
// return false;
// }
// else if (nama == null || nama == "") {
// bootbox.alert({ message: 'Nama tidak boleh kosong', centerVertical: true });
// return false;
// } else if (tempat_lahir == null || tempat_lahir == "") {
// bootbox.alert({ message: 'Tempat lahir tidak boleh kosong', centerVertical: true });
// return false;
// } else if (tanggal_lahir == null || tanggal_lahir == "") {
// bootbox.alert({ message: 'Tanggal lahir tidak boleh kosong', centerVertical: true });
// return false;
// } else if (alamat == null || alamat == "") {
// bootbox.alert({ message: 'Alamat tidak boleh kosong', centerVertical: true });
// return false;
// } else if (no_hp == null || no_hp == "") {
// bootbox.alert({ message: 'No hp tidak boleh kosong', centerVertical: true });
// return false;
// } else if (ktp.toString().length > 16) {
// bootbox.alert({ message: 'KTP tidak boleh lebih dari 16 angka', centerVertical: true });
// return false;
// } else if (ktp.toString().length < 16) {
// bootbox.alert({ message: 'KTP tidak boleh kurang dari 16 angka', centerVertical: true });
// return false;
// } else if (no_hp.toString().length > 13) {
// bootbox.alert({ message: 'No HP tidak boleh lebih dari 13 angka', centerVertical: true });
// return false;
// }
if
(
response
[
'
code
'
]
==
0
)
{
console
.
log
(
response
);
let
$id
=
response
.
data
[
'
id_pasien
'
];
...
...
@@ -97,7 +108,7 @@ function SaveDataAja() {
window
.
location
.
href
=
(
"
datapasien/
"
+
$encodedId
);
}
else
{
bootbox
.
alert
({
message
:
'
gagal
'
,
centerVertical
:
true
});
bootbox
.
alert
({
message
:
'
Gagal Ditambahkan
'
,
centerVertical
:
true
});
}
},
error
:
function
(
xhr
)
{
...
...
@@ -111,7 +122,43 @@ function SaveDataAja() {
});
}
// alert('this');
function
validasipoli
(
KTP
)
{
var
exist
=
0
;
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/loadpasien
'
,
async
:
false
,
data
:
{
id
:
null
,
},
success
:
function
(
result
)
{
console
.
log
(
result
)
var
data
=
result
.
data
;
for
(
x
in
data
)
{
if
(
KTP
==
data
[
x
][
'
ktp
'
])
{
exist
=
1
;
}
}
},
error
:
function
(
xhr
)
{
//alert(xhr.status+'-'+xhr.statusText);
}
});
return
exist
;
}
var
inputQuantity
=
[];
$
(
function
()
{
$
(
"
#ktp
"
).
each
(
function
(
i
)
{
...
...
public/action-js/antrian-js/action-datapasien.js
View file @
cd87a10e
...
...
@@ -30,7 +30,7 @@ function loaddatapasien(param) {
}
else
{
alert
(
result
.
info
);
bootbox
.
alert
({
message
:
'
Data Kosong
'
,
centerVertical
:
true
}
);
}
},
error
:
function
(
xhr
)
{
...
...
@@ -349,7 +349,7 @@ function pilihAntrian() {
if
(
xhr
.
status
!=
200
)
{
//bootbox.alert(xhr.status + "-" + xhr.statusText + " <br>Silahkan coba kembali :) ");
}
else
{
alert
(
'
Cannot load queue
'
);
bootbox
.
alert
({
message
:
'
Cannot load queue
'
,
centerVertical
:
true
}
);
}
}
});
...
...
public/action-js/antrian-js/action-dokter.js
View file @
cd87a10e
...
...
@@ -20,9 +20,10 @@ function loaddokter() {
y
+=
` <div class="col">
<div class="card-hide" style="height:330px;width:200px; " >
<div class="card-body text-center " >
<h5 class="card-title "> <img style="width:180px; height:200px;" src="/tamplate/img/doctor/`
+
data
[
counter
][
'
image
'
]
+
`" ></h5>
<h5 class="card-title "> <img style="width:180px; height:200px;" src="/tamplate/img/doctor/`
+
data
[
counter
][
'
image
_dokter
'
]
+
`" ></h5>
<h4 class="card-text font-weight-bold">`
+
data
[
counter
][
'
nama_dokter
'
]
+
`</h4>
<h5 class="card-text">`
+
data
[
counter
][
'
nama_poli
'
]
+
`</h5>
<h6 class="card-text">`
+
`Kode Dokter : `
+
data
[
counter
][
'
kode_dokter
'
]
+
`</h6>
<h5 class="card-text">`
+
`Poli `
+
data
[
counter
][
'
nama_poli
'
]
+
`</h5>
</div>
...
...
public/action-js/antrian-js/action-keloladokter.js
View file @
cd87a10e
...
...
@@ -112,35 +112,105 @@ function Loaddokter() {
}
});
}
function
validasidokter
(
poli
,
nama_dokter
,
kode_dokter
)
{
var
exist
=
0
;
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/loadkeloladokter
'
,
async
:
false
,
data
:
{
id
:
null
,
},
success
:
function
(
result
)
{
var
data
=
result
.
data
;
var
namacounter
=
0
;
var
kodecounter
=
0
;
for
(
x
in
data
)
{
if
(
poli
==
data
[
x
][
'
id_poli
'
])
{
// console.log(data[x]['id_poli'])
if
(
nama_dokter
==
data
[
x
][
'
nama_dokter
'
])
{
exist
=
1
;
}
}
if
(
poli
==
data
[
x
][
'
id_poli
'
])
{
if
(
kode_dokter
==
data
[
x
][
'
kode_dokter
'
])
{
exist
=
2
;
}
}
if
(
poli
==
data
[
x
][
'
id_poli
'
])
{
if
(
nama_dokter
==
data
[
x
][
'
nama_dokter
'
])
{
namacounter
+=
1
;
if
(
namacounter
>
1
)
{
exist
=
3
;
}
}
}
if
(
poli
==
data
[
x
][
'
id_poli
'
])
{
if
(
kode_dokter
==
data
[
x
][
'
kode_dokter
'
])
{
kodecounter
+=
1
;
if
(
kodecounter
>
1
)
{
exist
=
4
;
}
}
}
}
},
error
:
function
(
xhr
)
{
//alert(xhr.status+'-'+xhr.statusText);
}
});
return
exist
;
}
$
(
'
#tambahmodal
'
).
on
(
'
click
'
,
function
()
{
loadpoli
()
})
$
(
'
#tambah
'
).
on
(
'
click
'
,
function
()
{
var
nama_dokter
=
document
.
getElementById
(
"
nama_dokter
"
).
value
;
var
kode_dokter
=
document
.
getElementById
(
"
kode_dokter
"
).
value
;
let
nama_dokter
=
$
(
'
#nama_dokter
'
).
val
();
let
kode_dokter
=
$
(
'
#kode_dokter
'
).
val
();
let
poli
=
$
(
"
#poli option:selected
"
).
attr
(
"
value
"
);
console
.
log
(
poli
)
if
(
validasidokter
(
nama_dokter
,
kode_dokter
)
==
1
)
{
bootbox
.
alert
({
message
:
'
Nama Dokter Sudah Ada!
'
,
centerVertical
:
true
});
if
(
nama_dokter
==
null
||
nama_dokter
==
""
)
{
bootbox
.
alert
({
message
:
'
Nama dokter tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
validasidokter
(
nama_dokter
,
kode_dokter
)
==
2
)
{
bootbox
.
alert
({
message
:
'
Kode Dokter Sudah Ada!
'
,
centerVertical
:
true
});
else
if
(
kode_dokter
==
null
||
kode_dokter
==
""
)
{
bootbox
.
alert
({
message
:
'
Kode dokter tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
validasidokter
(
poli
,
nama_dokter
,
kode_dokter
)
==
1
)
{
bootbox
.
alert
({
message
:
'
Nama dokter sudah ada!
'
,
centerVertical
:
true
});
}
else
if
(
validasidokter
(
poli
,
nama_dokter
,
kode_dokter
)
==
2
)
{
bootbox
.
alert
({
message
:
'
Kode dokter sudah ada!
'
,
centerVertical
:
true
});
}
else
{
savedokter
()
}
console
.
log
(
validasidokter
(
poli
,
nama_dokter
,
kode_dokter
));
})
function
savedokter
()
{
let
nama_dokter
=
$
(
'
#nama_dokter
'
).
val
();
let
kode_dokter
=
$
(
'
#kode_dokter
'
).
val
();
let
poli
=
$
(
"
#poli option:selected
"
).
attr
(
"
value
"
);
// let image = $('#kode_poli').val();
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
...
...
@@ -186,54 +256,30 @@ function savedokter() {
});
}
function
validasidokter
(
nama_dokter
,
kode_dokter
)
{
var
exist
=
0
;
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/loadkeloladokter
'
,
async
:
false
,
data
:
{
id
:
null
,
},
success
:
function
(
result
)
{
console
.
log
(
result
)
var
data
=
result
.
data
;
for
(
x
in
data
)
{
if
(
nama_dokter
==
data
[
x
][
'
nama_dokter
'
])
{
exist
=
1
;
}
if
(
kode_dokter
==
data
[
x
][
'
kode_dokter
'
])
{
exist
=
2
;
}
}
},
error
:
function
(
xhr
)
{
//alert(xhr.status+'-'+xhr.statusText);
}
});
return
exist
;
}
$
(
'
#edit
'
).
on
(
'
click
'
,
function
()
{
let
id_dokter
=
$
(
'
#id_dokter
'
).
val
();
var
nama_dokter
=
document
.
getElementById
(
"
nama_dokteredt
"
).
value
;
var
kode_dokter
=
document
.
getElementById
(
"
kode_dokteredt
"
).
value
;
let
nama_dokter
=
$
(
'
#nama_dokteredt
'
).
val
();
let
kode_dokter
=
$
(
'
#kode_dokteredt
'
).
val
();
let
poli
=
$
(
"
#poliedt option:selected
"
).
attr
(
"
value
"
);
if
(
nama_dokter
==
null
||
nama_dokter
==
""
)
{
bootbox
.
alert
({
message
:
'
Nama dokter tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
kode_dokter
==
null
||
kode_dokter
==
""
)
{
bootbox
.
alert
({
message
:
'
Kode dokter tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
validasidokter
(
poli
,
nama_dokter
,
kode_dokter
)
==
3
)
{
bootbox
.
alert
({
message
:
'
Nama dokter harus berbeda!
'
,
centerVertical
:
true
});
if
(
validasidokter
(
nama_dokter
,
kode_dokter
)
==
1
)
{
bootbox
.
alert
({
message
:
'
Nama Dokter Harus Berbeda!
'
,
centerVertical
:
true
});
}
else
if
(
validasidokter
(
nama_dokter
,
kode_dokter
)
==
2
)
{
bootbox
.
alert
({
message
:
'
Kode
Dokter Harus B
erbeda!
'
,
centerVertical
:
true
});
else
if
(
validasidokter
(
poli
,
nama_dokter
,
kode_dokter
)
==
4
)
{
bootbox
.
alert
({
message
:
'
Kode
dokter harus b
erbeda!
'
,
centerVertical
:
true
});
}
else
{
editdatadokter
(
id_dokter
)
}
...
...
@@ -251,7 +297,7 @@ function editdatadokter(id_dokter) {
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/
load
keloladokter
'
,
url
:
baseURL
+
'
/api/
edit
keloladokter
'
,
data
:
{
id
:
id_dokter
,
inama_dokter
:
nama_dokter
,
...
...
@@ -262,7 +308,7 @@ function editdatadokter(id_dokter) {
},
success
:
function
(
response
)
{
console
.
log
(
response
);
//
console.log(response);
if
(
response
[
'
code
'
]
==
0
)
{
swal
({
title
:
""
,
...
...
@@ -357,18 +403,12 @@ function loadedit(id_dokter) {
}
}
});
// for (var i = 0; i < data.length; i++) {
// optionseg = '<option value="' + data[i].id_poli + '">' + data[i].nama_poli + '</option>';
// }
// $("select#poliedt").html(optionseg);
$
(
'
#id_dokter
'
).
val
(
data
[
0
].
id_dokter
);
$
(
'
#nama_dokteredt
'
).
val
(
data
[
0
].
nama_dokter
);
$
(
'
#kode_dokteredt
'
).
val
(
data
[
0
].
kode_dokter
);
// $('#condition').val(data[0].condition);
}
else
{
bootbox
.
alert
({
message
:
'
Data Kosong
'
,
centerVertical
:
true
});
...
...
@@ -391,7 +431,7 @@ function Delete(param) {
id
:
param
,
},
success
:
function
(
result
)
{
console
.
log
(
result
);
// console.log(result.data[0].nama_dokter
);
let
nama_dokter
=
result
.
data
[
0
].
nama_dokter
;
swal
({
title
:
"
Apakah yakin mengahapus dokter '
"
+
nama_dokter
+
"
'?
"
,
...
...
@@ -422,7 +462,12 @@ function Delete(param) {
}
else
{
alert
(
'
gagal
'
);
swal
({
title
:
""
,
text
:
"
Data Gagal Dihapus!
"
,
icon
:
"
succes
"
,
button
:
"
ok
"
,
});
}
},
error
:
function
(
xhr
)
{
...
...
public/action-js/antrian-js/action-kelolapasien.js
View file @
cd87a10e
// loadpoli();
// $('#poli').on('change', function () {
// var idpoli = $('#poli').val();
// // console.log(idpoli);
// $.ajax({
// type: 'POST',
// dataType: 'json',
// url: baseURL + '/api/loaddokter',
// data: {
// id_poli: idpoli
// },
// success: function (result) {
// if (result['code'] == 0) {
// var res = result['data'];
// optionseg = '';
// optionseg += '<option value="Pilih" disabled selected>Pilih</option>';
// for (var i = 0; i < res.length; i++) {
// optionseg += '<option value="' + res[i].id_dokter + '">' + res[i].nama_dokter + '</option>';
// }
// $("select#dokter").removeAttr('disabled');
// $("select#dokter").html(optionseg);
// } else {
// bootbox.dialog({
// message: "<span class='bigger-110'>" + result['info'] + "</span>",
// buttons:
// {
// "OK":
// {
// "label": "<i class='icon-ok'></i> OK ",
// "className": "btn-sm btn-danger",
// "callback": function () {
// notifyCancel('ERROR: ' + result['info'] + '. Bila ada kesulitan dimohon untuk menghubungi Admin terkait');
// }
// }
// }
// });
// }
// }
// });
// });
// function loadpoli() {
// $.ajax({
// type: 'POST',
// dataType: 'json',
// url: baseURL + '/api/loadpoli',
// success: function (result) {
// if (result['code'] == 0) {
// //console.log (result);
// var res = result['data'];
// optionseg = '';
// optionseg += '<option value="Pilih" disabled selected>Pilih</option>';
// for (var i = 0; i < res.length; i++) {
// optionseg += '<option value="' + res[i].id_poli + '">' + res[i].nama_poli + '</option>';
// }
// $("select#poli").html(optionseg);
// } else {
// bootbox.dialog({
// message: "<span class='bigger-110'>" + result['info'] + "</span>",
// buttons:
// {
// "OK":
// {
// "label": "<i class='icon-ok'></i> OK ",
// "className": "btn-sm btn-danger",
// "callback": function () {
// notifyCancel('ERROR: ' + result['info'] + '. Bila ada kesulitan dimohon untuk menghubungi Admin terkait');
// }
// }
// }
// });
// }
// }
// });
// }
// $('#dokter').on('change', function () {
Loadpasien
();
// });
Loadpasien
()
function
Loadpasien
()
{
// var iddokter = $('#dokter').val();
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/loadkelola
antria
n
'
,
url
:
baseURL
+
'
/api/loadkelola
pasie
n
'
,
data
:
{
// id: iddokter
},
success
:
function
(
result
)
{
// console.log(result
.data
);
// console.log(result);
$
(
'
table.table-bordered > tbody
'
).
empty
();
// console.log(result);
...
...
@@ -119,14 +26,17 @@ function Loadpasien() {
var
cols
=
""
;
// onClick="openmyprofile('+reg[x].userid+',\''+reg[x].named+'\')">
cols
+=
'
<td class="">
'
+
counter
+
'
</td>
'
;
cols
+=
'
<td class="tdCenterText bgtd1 tdBorder-left">
'
+
data
[
x
].
no_antrian
+
'
</td>
'
;
cols
+=
'
<td class="tdCenterText ">
'
+
data
[
x
].
no_rekam_medis
+
'
</td>
'
;
cols
+=
'
<td class="tdCenterText">
'
+
data
[
x
].
ktp
+
'
</td>
'
;
cols
+=
'
<td class="tdCenterText bgtd1 tdBorder-left">
'
+
data
[
x
].
nama
+
'
</td>
'
;
cols
+=
'
<td class="tdCenterText bgtd1 tdBorder-left">
'
+
data
[
x
].
nama_dokter
+
'
</td>
'
;
cols
+=
'
<td class="tdCenterText bgtd1 tdBorder-left">
'
+
data
[
x
].
nama_poli
+
'
</td>
'
;
cols
+=
'
<td class="tdCenterText bgtd1 tdBorder-left">
'
+
data
[
x
].
status_name
+
'
</td>
'
;
cols
+=
'
<td class="tdCenterText bgtd1 "> <div class="text-center"> <span class="btn btn-primary btn-xs" onClick="actionqueue(
'
+
data
[
x
].
id_pasien
+
"
,
"
+
data
[
x
].
id_dokter
+
'
)">Update</span></div> </td>
'
;
cols
+=
'
<td class="tdCenterText bgtd1 tdBorder-left">
'
+
data
[
x
].
tempat_lahir
+
'
</td>
'
;
cols
+=
'
<td class="tdCenterText bgtd1 tdBorder-left">
'
+
data
[
x
].
tanggal_lahir
+
'
</td>
'
;
cols
+=
'
<td class="tdCenterText bgtd1 tdBorder-left">
'
+
data
[
x
].
alamat
+
'
</td>
'
;
cols
+=
'
<td class="tdCenterText bgtd1 tdBorder-left">
'
+
data
[
x
].
no_hp
+
'
</td>
'
;
cols
+=
'
<td class="tdCenterText bgtd1 tdBorder-left">
'
+
data
[
x
].
create_date
+
'
</td>
'
;
cols
+=
'
<td class="tdCenterText bgtd1 "> <div class="text-center" ><span style="padding: 7px;" class="btn btn-success btn-xs" data-toggle="modal" data-target="#Editdata" onClick="loadedit(
'
+
data
[
x
].
id_pasien
+
'
)">Edit</span> <span style="padding: 7px;"class="btn btn-danger btn-xs" onclick="Delete(
'
+
data
[
x
].
id_pasien
+
'
)">Delete</span></div></td>
'
;
console
.
log
(
data
[
x
].
id_pasien
);
//
console.log(data[x].id_pasien);
newRow
.
append
(
cols
);
$
(
"
table.table-bordered
"
).
append
(
newRow
);
counter
++
;
...
...
@@ -145,12 +55,15 @@ function Loadpasien() {
paging
:
true
,
columnDefs
:
[
{
width
:
30
,
targets
:
0
},
{
width
:
5
0
,
targets
:
1
},
{
width
:
8
0
,
targets
:
1
},
{
width
:
130
,
targets
:
2
},
{
width
:
130
,
targets
:
3
},
{
width
:
130
,
targets
:
4
},
{
width
:
130
,
targets
:
5
},
{
width
:
100
,
targets
:
6
},
{
width
:
130
,
targets
:
6
},
{
width
:
130
,
targets
:
7
},
{
width
:
110
,
targets
:
8
},
{
width
:
100
,
targets
:
9
},
],
});
...
...
@@ -161,21 +74,89 @@ function Loadpasien() {
});
}
function
actionqueue
(
idpasien
,
iddokter
)
{
$
(
'
#edit
'
).
on
(
'
click
'
,
function
()
{
let
id_pasien
=
$
(
'
#id_pasien
'
).
val
();
let
ktp
=
$
(
'
#ktp
'
).
val
();
let
nama
=
$
(
'
#nama
'
).
val
();
let
tempat_lahir
=
$
(
'
#tempat_lahir
'
).
val
();
let
tanggal_lahir
=
$
(
'
#tanggal_lahir
'
).
val
();
let
alamat
=
$
(
'
#alamat
'
).
val
();
let
no_hp
=
$
(
'
#no_hp
'
).
val
();
if
(
nama
==
null
||
nama
==
""
)
{
bootbox
.
alert
({
message
:
'
Nama tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
ktp
==
null
||
ktp
==
""
)
{
bootbox
.
alert
({
message
:
'
No Induk Kependudukan (NIK) tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
tempat_lahir
==
null
||
tempat_lahir
==
""
)
{
bootbox
.
alert
({
message
:
'
Tempat Lahir tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
tanggal_lahir
==
null
||
tanggal_lahir
==
""
)
{
bootbox
.
alert
({
message
:
'
Tanggal Lahir tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
alamat
==
null
||
alamat
==
""
)
{
bootbox
.
alert
({
message
:
'
Alamat tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
no_hp
==
null
||
no_hp
==
""
)
{
bootbox
.
alert
({
message
:
'
No HP tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
ktp
.
toString
().
length
>
16
)
{
bootbox
.
alert
({
message
:
'
No Induk Kependudukan (NIK) tidak boleh lebih dari 16 angka
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
ktp
.
toString
().
length
<
16
)
{
bootbox
.
alert
({
message
:
'
No Induk Kependudukan (NIK) tidak boleh kurang dari 16 angka
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
no_hp
.
toString
().
length
>
13
)
{
bootbox
.
alert
({
message
:
'
No Induk Kependudukan (NIK) HP tidak boleh lebih dari 13 angka
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
validasipasien
(
ktp
)
==
1
)
{
bootbox
.
alert
({
message
:
'
No Induk Kependudukan (NIK) Sudah Ada!
'
,
centerVertical
:
true
});
}
else
{
editdatapasien
(
id_pasien
)
}
})
function
editdatapasien
(
id_pasien
)
{
let
ktp
=
$
(
'
#ktp
'
).
val
();
let
nama
=
$
(
'
#nama
'
).
val
();
let
tempat_lahir
=
$
(
'
#tempat_lahir
'
).
val
();
let
tanggal_lahir
=
$
(
'
#tanggal_lahir
'
).
val
();
let
alamat
=
$
(
'
#alamat
'
).
val
();
let
no_hp
=
$
(
'
#no_hp
'
).
val
();
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/
updateantrianmiss
'
,
url
:
baseURL
+
'
/api/
editkelolapasien
'
,
data
:
{
iddok
:
iddokter
,
iidpasien
:
idpasien
,
id_pasien
:
id_pasien
,
iktp
:
ktp
,
inama
:
nama
,
itempat_lahir
:
tempat_lahir
,
itanggal_lahir
:
tanggal_lahir
,
ialamat
:
alamat
,
ino_hp
:
no_hp
,
},
success
:
function
(
result
)
{
console
.
log
()
if
(
result
.
code
==
0
)
{
success
:
function
(
response
)
{
console
.
log
(
response
);
if
(
response
[
'
code
'
]
==
0
)
{
swal
({
title
:
""
,
text
:
"
Data Berhasil Di
update
!
"
,
text
:
"
Data Berhasil Di
Ubah
!
"
,
icon
:
"
succes
"
,
button
:
"
ok
"
,
},
function
()
{
...
...
@@ -183,10 +164,157 @@ function actionqueue(idpasien, iddokter) {
});
}
else
{
alert
(
'
gagal
'
);
swal
({
title
:
""
,
text
:
"
Data Gagal Ditambahkan!
"
,
icon
:
"
succes
"
,
button
:
"
ok
"
,
});
}
},
error
:
function
(
xhr
)
{
if
(
xhr
.
status
!=
200
)
{
//bootbox.alert(xhr.status + "-" + xhr.statusText + " <br>Silahkan coba kembali :) ");
}
else
{
alert
(
'
gagal error
'
);
}
}
});
}
function
validasipasien
(
ktp
)
{
var
exist
=
0
;
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/loadkelolapasien
'
,
async
:
false
,
data
:
{
id
:
null
,
},
success
:
function
(
result
)
{
console
.
log
(
result
)
var
data
=
result
.
data
;
var
ktpcounter
=
0
;
for
(
x
in
data
)
{
if
(
ktp
==
data
[
x
][
'
ktp
'
])
{
ktpcounter
+=
1
;
if
(
ktpcounter
>
1
)
{
exist
=
1
;
}
}
}
},
error
:
function
(
xhr
)
{
//alert(xhr.status+'-'+xhr.statusText);
}
});
return
exist
;
}
function
loadedit
(
id_pasien
)
{
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/loadkelolapasien
'
,
data
:
{
id_pasien
:
id_pasien
,
},
success
:
function
(
result
)
{
// console.log(result);
// $('.loaddata').empty();
// console.log(result);
if
(
result
.
code
==
0
)
{
let
data
=
result
.
data
;
$
(
'
#id_pasien
'
).
val
(
data
[
0
].
id_pasien
);
$
(
'
#no_rekam_medis
'
).
val
(
data
[
0
].
no_rekam_medis
);
$
(
'
#ktp
'
).
val
(
data
[
0
].
ktp
);
$
(
'
#nama
'
).
val
(
data
[
0
].
nama
);
$
(
'
#tempat_lahir
'
).
val
(
data
[
0
].
tempat_lahir
);
$
(
'
#tanggal_lahir
'
).
val
(
data
[
0
].
tanggal_lahir
);
$
(
'
#alamat
'
).
val
(
data
[
0
].
alamat
);
$
(
'
#no_hp
'
).
val
(
data
[
0
].
no_hp
);
}
else
{
alert
(
result
.
info
);
}
},
error
:
function
(
xhr
)
{
alert
(
xhr
.
status
+
'
-
'
+
xhr
.
statusText
);
}
});
}
function
Delete
(
id_pasien
)
{
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/loadkelolapasien
'
,
data
:
{
id_pasien
:
id_pasien
,
},
success
:
function
(
result
)
{
console
.
log
(
result
);
let
nama_pasien
=
result
.
data
[
0
].
nama
;
swal
({
title
:
"
Apakah yakin mengahapus pasien '
"
+
nama_pasien
+
"
'?
"
,
type
:
"
error
"
,
confirmButtonClass
:
"
btn-danger
"
,
confirmButtonText
:
"
Yes!
"
,
showCancelButton
:
true
,
},
function
()
{
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/deletekelolapasien
'
,
data
:
{
id_pasien
:
id_pasien
,
},
success
:
function
(
result
)
{
// console.log(result)
if
(
result
.
code
==
0
)
{
swal
({
title
:
""
,
text
:
"
Data Berhasil Dihapus!
"
,
icon
:
"
succes
"
,
button
:
"
ok
"
,
},
function
()
{
location
.
reload
();
});
}
else
{
alert
(
'
gagal
'
);
}
},
error
:
function
(
xhr
)
{
alert
(
xhr
.
status
+
'
-
'
+
xhr
.
statusText
);
}
});
}
);
}
});
}
public/action-js/antrian-js/action-kelolapoli.js
View file @
cd87a10e
...
...
@@ -70,26 +70,55 @@ function Loadpoli() {
$
(
'
#tambah
'
).
on
(
'
click
'
,
function
()
{
var
nama_poli
=
document
.
getElementById
(
"
nama_poli
"
).
value
;
var
kode_poli
=
document
.
getElementById
(
"
kode_poli
"
).
value
;
let
nama_poli
=
$
(
'
#nama_poli
'
).
val
();
let
kode_poli
=
$
(
'
#kode_poli
'
).
val
();
let
deskripsi_poli
=
$
(
'
#deskripsi_poli
'
).
val
();
if
(
validasipoli
(
nama_poli
,
kode_poli
)
==
1
)
{
bootbox
.
alert
({
message
:
'
Nama Poli Sudah Ada!
'
,
centerVertical
:
true
});
if
(
nama_poli
==
null
||
nama_poli
==
""
)
{
bootbox
.
alert
({
message
:
'
Nama poli tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
kode_poli
==
null
||
kode_poli
==
""
)
{
bootbox
.
alert
({
message
:
'
Kode poli tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
deskripsi_poli
==
null
||
deskripsi_poli
==
""
)
{
bootbox
.
alert
({
message
:
'
Deskripsi poli tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
validasipoli
(
nama_poli
,
kode_poli
)
==
1
)
{
bootbox
.
alert
({
message
:
'
Nama poli sudah ada!
'
,
centerVertical
:
true
});
}
else
if
(
validasipoli
(
nama_poli
,
kode_poli
)
==
2
)
{
bootbox
.
alert
({
message
:
'
Kode
Poli Sudah A
da
'
,
centerVertical
:
true
});
bootbox
.
alert
({
message
:
'
Kode
poli sudah a
da
'
,
centerVertical
:
true
});
}
else
{
savedatapoli
();
}
})
function
saveTheoryOfDespair
()
{
}
function
savedatapoli
()
{
let
nama_poli
=
$
(
'
#nama_poli
'
).
val
();
let
kode_poli
=
$
(
'
#kode_poli
'
).
val
();
let
deskripsi_poli
=
$
(
'
#deskripsi_poli
'
).
val
();
const
fileupload
=
$
(
'
#image_poli
'
).
prop
(
'
files
'
)[
0
];
// let image = $('#kode_poli').val();
let
formData
=
new
FormData
();
formData
.
append
(
'
fileupload
'
,
fileupload
);
// set file ke tipe data binary
console
.
log
(
fileupload
);
let
image
=
$
(
'
#kode_poli
'
).
val
();
$
.
ajax
({
type
:
'
POST
'
,
...
...
@@ -103,6 +132,7 @@ function savedatapoli() {
success
:
function
(
response
)
{
if
(
response
[
'
code
'
]
==
0
)
{
swal
({
title
:
""
,
...
...
@@ -176,14 +206,27 @@ function validasipoli(nama_poli, kode_poli) {
$
(
'
#edit
'
).
on
(
'
click
'
,
function
()
{
let
id_poli
=
$
(
'
#id_poli
'
).
val
();
var
nama_poli
=
document
.
getElementById
(
"
nama_poliEdt
"
).
value
;
var
kode_poli
=
document
.
getElementById
(
"
kode_poliEdt
"
).
value
;
let
nama_poli
=
$
(
'
#nama_poliEdt
'
).
val
();
let
kode_poli
=
$
(
'
#kode_poliEdt
'
).
val
();
let
deskripsi_poli
=
$
(
'
#deskripsi_poliEdt
'
).
val
();
if
(
validasipoli
(
nama_poli
,
kode_poli
)
==
1
)
{
bootbox
.
alert
({
message
:
'
Nama Poli Harus Berbeda!
'
,
centerVertical
:
true
});
if
(
nama_poli
==
null
||
nama_poli
==
""
)
{
bootbox
.
alert
({
message
:
'
Nama poli tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
kode_poli
==
null
||
kode_poli
==
""
)
{
bootbox
.
alert
({
message
:
'
Kode poli tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
deskripsi_poli
==
null
||
deskripsi_poli
==
""
)
{
bootbox
.
alert
({
message
:
'
Deskripsi poli tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
validasipoli
(
nama_poli
,
kode_poli
)
==
1
)
{
bootbox
.
alert
({
message
:
'
Nama poli harus berbeda!
'
,
centerVertical
:
true
});
}
else
if
(
validasipoli
(
nama_poli
,
kode_poli
)
==
2
)
{
bootbox
.
alert
({
message
:
'
Kode
Poli Harus B
erbeda!
'
,
centerVertical
:
true
});
bootbox
.
alert
({
message
:
'
Kode
poli harus b
erbeda!
'
,
centerVertical
:
true
});
}
else
{
editdatapoli
(
id_poli
)
}
...
...
@@ -320,7 +363,12 @@ function Delete(param) {
location
.
reload
();
});
}
else
{
alert
(
'
gagal
'
);
swal
({
title
:
""
,
text
:
"
Data Gagal Dihapus!
"
,
icon
:
"
succes
"
,
button
:
"
ok
"
,
});
}
},
error
:
function
(
xhr
)
{
...
...
public/action-js/antrian-js/action-kelolaruang.js
View file @
cd87a10e
...
...
@@ -8,9 +8,9 @@ function reset() {
}
function
closeWin
()
{
myWindow
.
close
();
}
//
function closeWin() {
//
myWindow.close();
//
}
function
loadpoli
()
{
...
...
@@ -51,7 +51,7 @@ function loadpoli() {
});
}
Loadruang
(
null
);
Loadruang
();
function
Loadruang
()
{
/* save data */
...
...
@@ -77,9 +77,10 @@ function Loadruang() {
cols
+=
'
<td class="">
'
+
counter
+
'
</td>
'
;
// cols += '<td class="tdCenterText bgtd1 tdBorder-left">' + data[x].id_poli + '</td>'
cols
+=
'
<td class="tdCenterText bgtd1 tdBorder-left">
'
+
data
[
x
].
nama_poli
+
'
</td>
'
;
cols
+=
'
<td class="tdCenterText bgtd1 tdBorder-left">
'
+
data
[
x
].
lantai
+
'
</td>
'
;
cols
+=
'
<td class="tdCenterText bgtd1 tdBorder-left">
'
+
data
[
x
].
nama_ruang
+
'
</td>
'
;
cols
+=
'
<td class="tdCenterText bgtd1 tdBorder-left">
'
+
data
[
x
].
condition
+
'
</td>
'
;
// cols += '<td class="tdCenterText bgtd1 tdBorder-left">' + data[x].image + '</td>';
cols
+=
'
<td class="tdCenterText bgtd1 "> <div class="text-center" ><span style="padding: 7px;" class="btn btn-success btn-xs" data-toggle="modal" data-target="#Editdata" onClick="loadedit(
'
+
data
[
x
].
id_ruang
+
'
)">Edit</span> <span style="padding: 7px;"class="btn btn-danger btn-xs" onclick="Delete(
'
+
data
[
x
].
id_ruang
+
'
)">Delete</span></div></td>
'
;
...
...
@@ -100,10 +101,11 @@ function Loadruang() {
paging
:
true
,
columnDefs
:
[
{
width
:
30
,
targets
:
0
},
{
width
:
215
,
targets
:
1
},
{
width
:
215
,
targets
:
2
},
{
width
:
215
,
targets
:
3
},
{
width
:
107
,
targets
:
4
},
{
width
:
180
,
targets
:
1
},
{
width
:
140
,
targets
:
2
},
{
width
:
140
,
targets
:
3
},
{
width
:
140
,
targets
:
4
},
{
width
:
100
,
targets
:
5
},
],
});
...
...
@@ -122,12 +124,30 @@ $('#tambahmodal').on('click', function () {
})
$
(
'
#tambah
'
).
on
(
'
click
'
,
function
()
{
saveruang
()
let
nama_ruang
=
$
(
'
#nama_ruang
'
).
val
();
let
lantai
=
$
(
'
#lantai
'
).
val
();
if
(
nama_ruang
==
null
||
nama_ruang
==
""
)
{
bootbox
.
alert
({
message
:
'
Nama Ruang tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
lantai
==
null
||
lantai
==
""
)
{
bootbox
.
alert
({
message
:
'
Lantai tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
validasiruang
(
lantai
,
nama_ruang
)
==
1
)
{
bootbox
.
alert
({
message
:
'
Nama ruang dan lantai sudah ada!
'
,
centerVertical
:
true
});
}
else
{
saveruang
()
}
})
function
saveruang
()
{
let
nama_ruang
=
$
(
'
#nama_ruang
'
).
val
();
let
lantai
=
$
(
'
#lantai
'
).
val
();
let
poli
=
$
(
"
#poli option:selected
"
).
attr
(
"
value
"
);
...
...
@@ -139,12 +159,16 @@ function saveruang() {
url
:
baseURL
+
'
/api/savekelolaruang
'
,
data
:
{
inama_ruang
:
nama_ruang
,
ilantai
:
lantai
,
ipoli
:
poli
,
},
success
:
function
(
result
)
{
// console.log(result)
if
(
result
[
'
code
'
]
==
0
)
{
swal
({
title
:
""
,
...
...
@@ -177,19 +201,83 @@ function saveruang() {
});
}
function
validasiruang
(
lantai
,
nama_ruang
)
{
var
exist
=
0
;
$
.
ajax
({
type
:
'
POST
'
,
dataType
:
'
json
'
,
url
:
baseURL
+
'
/api/loadkelolaruang
'
,
async
:
false
,
data
:
{
id
:
null
,
},
success
:
function
(
result
)
{
var
data
=
result
.
data
;
console
.
log
(
data
[
0
])
var
ruangcounter
=
0
for
(
x
in
data
)
{
if
(
lantai
==
data
[
x
][
'
lantai
'
])
{
if
(
lantai
==
data
[
x
][
'
lantai
'
])
{
if
(
nama_ruang
==
data
[
x
][
'
nama_ruang
'
])
{
exist
=
1
;
}
}
}
if
(
lantai
==
data
[
x
][
'
lantai
'
])
{
if
(
nama_ruang
==
data
[
x
][
'
nama_ruang
'
])
{
ruangcounter
+=
1
;
if
(
ruangcounter
>
1
)
{
exist
=
2
;
}
}
}
}
},
error
:
function
(
xhr
)
{
//alert(xhr.status+'-'+xhr.statusText);
}
});
return
exist
;
}
$
(
'
#edit
'
).
on
(
'
click
'
,
function
()
{
let
id_ruang
=
$
(
'
#id_ruang
'
).
val
();
// if (validasieditnama() == true) {
// alert("Nama Poli Harus Berbeda!")
// } else {
editdataruang
(
id_ruang
)
// }
let
nama_ruang
=
$
(
'
#nama_ruangedt
'
).
val
();
let
lantai
=
$
(
'
#lantaiedt
'
).
val
();
let
poli
=
$
(
"
#poliedt option:selected
"
).
attr
(
"
value
"
);
// console.log(poli)
if
(
nama_ruang
==
null
||
nama_ruang
==
""
)
{
bootbox
.
alert
({
message
:
'
Nama Ruang tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
lantai
==
null
||
lantai
==
""
)
{
bootbox
.
alert
({
message
:
'
Lantai tidak boleh kosong
'
,
centerVertical
:
true
});
return
false
;
}
else
if
(
validasiruang
(
lantai
,
nama_ruang
)
==
2
)
{
bootbox
.
alert
({
message
:
'
Nama ruang dan lantai harus berbeda!
'
,
centerVertical
:
true
});
}
else
{
editdataruang
(
id_ruang
)
}
})
function
editdataruang
(
id_ruang
)
{
let
poli
=
$
(
"
#poliedt option:selected
"
).
attr
(
"
value
"
);
let
nama_ruang
=
$
(
'
#nama_ruangedt
'
).
val
();
let
lantai
=
$
(
'
#lantaiedt
'
).
val
();
let
condition
=
$
(
"
#condition option:selected
"
).
attr
(
"
value
"
);
$
.
ajax
({
...
...
@@ -200,12 +288,14 @@ function editdataruang(id_ruang) {
id
:
id_ruang
,
inama_ruang
:
nama_ruang
,
ipoli
:
poli
,
ilantai
:
lantai
,
icondition
:
condition
,
},
success
:
function
(
response
)
{
//console.log(respoonse);
if
(
response
[
'
code
'
]
==
0
)
{
swal
({
title
:
""
,
...
...
@@ -272,7 +362,7 @@ function loadedit(id_ruang) {
if
(
result
[
'
code
'
]
==
0
)
{
console
.
log
(
result
);
//
console.log(result);
var
res
=
result
[
'
data
'
];
optionseg
=
''
;
...
...
@@ -303,6 +393,7 @@ function loadedit(id_ruang) {
});
$
(
'
#id_ruang
'
).
val
(
data
[
0
].
id_ruang
);
$
(
'
#nama_ruangedt
'
).
val
(
data
[
0
].
nama_ruang
);
$
(
'
#lantaiedt
'
).
val
(
data
[
0
].
lantai
);
}
else
{
bootbox
.
alert
({
message
:
'
Data Kosong
'
,
centerVertical
:
true
});
...
...
@@ -326,7 +417,7 @@ function Delete(param) {
id
:
param
,
},
success
:
function
(
result
)
{
console
.
log
(
result
);
//
console.log(result);
let
nama_ruang
=
result
.
data
[
0
].
nama_ruang
;
swal
({
title
:
"
Apakah yakin mengahapus ruang '
"
+
nama_ruang
+
"
'?
"
,
...
...
@@ -355,7 +446,12 @@ function Delete(param) {
location
.
reload
();
});
}
else
{
alert
(
'
gagal
'
);
swal
({
title
:
""
,
text
:
"
Data Gagal Dihapus!
"
,
icon
:
"
succes
"
,
button
:
"
ok
"
,
});
}
},
error
:
function
(
xhr
)
{
...
...
public/tamplate/css/demo.css
View file @
cd87a10e
...
...
@@ -36,7 +36,7 @@ input, button {
input
,
select
{
border
:
1px
solid
#CCC
;
width
:
2
5
0px
;
}
width
:
20px
;
}
::-webkit-input-placeholder
{
color
:
#BBB
;
}
...
...
public/tamplate/img/icon/gigi.png
deleted
100644 → 0
View file @
95e7301f
97.1 KB
public/tamplate/img/icon/mata.png
deleted
100644 → 0
View file @
95e7301f
176 KB
public/tamplate/img/icon/umum.png
deleted
100644 → 0
View file @
95e7301f
202 KB
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment