FIX_ISSUE
This commit is contained in:
parent
db12c95730
commit
44b8e2164e
@ -18,6 +18,7 @@ class Acl
|
|||||||
'#^/swagger#' => ['roles' => [ADMIN_ROLE_ID]],
|
'#^/swagger#' => ['roles' => [ADMIN_ROLE_ID]],
|
||||||
'#^/getEmployeeActiveOrInactivePolicy#' => ['roles' => [ADMIN_ROLE_ID, HEAD_ROLE_ID]],
|
'#^/getEmployeeActiveOrInactivePolicy#' => ['roles' => [ADMIN_ROLE_ID, HEAD_ROLE_ID]],
|
||||||
'#^/test/testingquerys#' => ['roles' => [ADMIN_ROLE_ID, HEAD_ROLE_ID]],
|
'#^/test/testingquerys#' => ['roles' => [ADMIN_ROLE_ID, HEAD_ROLE_ID]],
|
||||||
|
'#^/test/viewrfq#' => ['roles' => [ADMIN_ROLE_ID, HEAD_ROLE_ID]],
|
||||||
'#^/fedeploy#' => ['roles' => [ADMIN_ROLE_ID]],
|
'#^/fedeploy#' => ['roles' => [ADMIN_ROLE_ID]],
|
||||||
'#^/visitOffBoardCheck#' => ['roles' => [ADMIN_ROLE_ID]],
|
'#^/visitOffBoardCheck#' => ['roles' => [ADMIN_ROLE_ID]],
|
||||||
'#^/logs#' => ['roles' => [ADMIN_ROLE_ID]],
|
'#^/logs#' => ['roles' => [ADMIN_ROLE_ID]],
|
||||||
|
|||||||
@ -1673,10 +1673,16 @@ class EmployeeRestController extends AdminController
|
|||||||
{
|
{
|
||||||
try {
|
try {
|
||||||
|
|
||||||
$client = $this->clientModel->where('md5(id)', $this->request->getGet('client_id'))->first();
|
$client_id = $this->request->getGet('client_id');
|
||||||
|
if (is_string($client_id) && preg_match('/^[a-f0-9]{32}$/i', $client_id)) {
|
||||||
|
$client = $this->clientModel->where('MD5(id)', $client_id)->first();
|
||||||
|
}else{
|
||||||
|
$client = $this->clientModel->where('id', $client_id)->first();
|
||||||
|
}
|
||||||
|
|
||||||
if (!empty($client)) {
|
if (!empty($client)) {
|
||||||
$client['client_logo'] = base_url() . 'public/uploads/logo/' . $client['client_logo'];
|
$client['client_logo'] = base_url() . 'public/uploads/logo/' . $client['client_logo'];
|
||||||
$clientPolicy = $this->clientPolicyModel->where('md5(client_id)', $this->request->getGet('client_id'))
|
$clientPolicy = $this->clientPolicyModel->where('client_id', $client['id'])
|
||||||
->where('client_branch_id', $this->request->getGet('client_branch_id'))->findAll();
|
->where('client_branch_id', $this->request->getGet('client_branch_id'))->findAll();
|
||||||
return $this->respond(['status' => 'success', 'code' => 200, 'data' => ['client' => $client, 'client_policy' => $clientPolicy]], 200);
|
return $this->respond(['status' => 'success', 'code' => 200, 'data' => ['client' => $client, 'client_policy' => $clientPolicy]], 200);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user