customers API
This commit is contained in:
@@ -34,6 +34,7 @@ $routes->patch('/digibko/v1/employers/signatory', 'BkoReports::sign
|
||||
$routes->post('/digibko/v1/employers/verify', 'Employers::verifyEmployer');
|
||||
|
||||
$routes->get('/digibko/v1/users', 'BkoReports::listUsers');
|
||||
$routes->get('/digibko/v1/customers', 'BkoReports::listCustomers');
|
||||
|
||||
|
||||
$routes->post('/digibko/v1/employer', 'BkoReports::employerAdd');
|
||||
|
||||
@@ -308,4 +308,15 @@ public function signatoryUpdate():ResponseInterface{
|
||||
];
|
||||
return $this->respond($data, 200);
|
||||
}
|
||||
|
||||
public function listCustomers():ResponseInterface{
|
||||
|
||||
$query = $this->db->query("select * from customers order by id desc");
|
||||
$row = $query->getResult('array');
|
||||
$data = [
|
||||
'call_return' => '100',
|
||||
'records' => $row
|
||||
];
|
||||
return $this->respond($data, 200);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user