Skip to content

Commit

Permalink
Merge pull request #214 from basoro/mlite
Browse files Browse the repository at this point in the history
Update
  • Loading branch information
basoro authored Sep 27, 2024
2 parents 4c1f6a5 + ceaa367 commit f753595
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
6 changes: 6 additions & 0 deletions plugins/pasien/Admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -283,6 +283,12 @@ public function anyForm()
exit();
}

public function postMaxid()
{
echo $this->core->setNoRM();
exit();
}

public function postSave()
{
$_POST['tgl_daftar'] = date('Y-m-d H:i', strtotime($_POST['tgl_daftar']));
Expand Down
9 changes: 7 additions & 2 deletions plugins/pasien/js/admin/pasien.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,13 @@ $("#index").on('click', '#tutupform', function(){

// ketika inputbox no_rm_medis diklik
$("#form").on("click","#no_rkm_medis", function(event){
var no_rkm_medis_baru = $("#no_rkm_medis_baru").val();
$("#no_rkm_medis").val(no_rkm_medis_baru);
var baseURL = mlite.url + '/' + mlite.admin;
event.preventDefault();
var url = baseURL + '/pasien/maxid?t=' + mlite.token;
$.post(url, {
} ,function(data) {
$("#no_rkm_medis").val(data);
});
});

// tombol batal diklik
Expand Down
1 change: 0 additions & 1 deletion plugins/pasien/view/admin/form.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
<div class="col-sm-4">
<div class="input-group" style="width: 100%">
<input type="text" id="no_rkm_medis" name="no_rkm_medis" class="form-control" value="{$pasien.no_rkm_medis}" {if: !empty($pasien.no_rkm_medis)}disabled{/if}>
<input name="no_rkm_medis_baru" class="form-control" type="hidden" value="{$no_rkm_medis_baru}" id="no_rkm_medis_baru" >
<span class="input-group-addon"><input type="checkbox" name="manual" id="norm_manual"></span>
</div>
</div>
Expand Down

0 comments on commit f753595

Please sign in to comment.