Initial import
This commit is contained in:
42
application/controllers/regonline/Report.php
Normal file
42
application/controllers/regonline/Report.php
Normal file
@@ -0,0 +1,42 @@
|
||||
<?php
|
||||
class Report extends MY_Controller
|
||||
{
|
||||
var $db_onedev;
|
||||
public function index()
|
||||
{
|
||||
echo "Patient API";
|
||||
}
|
||||
public function __construct()
|
||||
{
|
||||
parent::__construct();
|
||||
$this->db_onedev = $this->load->database("onedev", true);
|
||||
}
|
||||
|
||||
public function add_notes($orderid){
|
||||
}
|
||||
|
||||
function getdataselect(){
|
||||
if (! $this->isLogin) {
|
||||
$this->sys_error("Invalid Token");
|
||||
exit;
|
||||
}
|
||||
$rows = [];
|
||||
|
||||
$query ="
|
||||
SELECT 0 as M_BranchID, 'Semua' as M_BranchName
|
||||
UNION
|
||||
SELECT M_BranchID, M_BranchName
|
||||
FROM m_branch
|
||||
WHERE
|
||||
M_BranchIsActive = 'Y'";
|
||||
//echo $query;
|
||||
$rows['branchs'] = $this->db_onedev->query($query)->result_array();
|
||||
$result = array(
|
||||
"total" => count($rows) ,
|
||||
"records" => $rows,
|
||||
);
|
||||
$this->sys_ok($result);
|
||||
exit;
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user