Fix IpdModel method call in toggleStatus endpoint
- Change getById() to find() - IpdBillingModel doesn't have getById method - Use ipdEditModel (IpdModel extends Model) which has standard find() method - Fixes 500 error: Call to undefined method IpdBillingModel::getById
This commit is contained in:
parent
54d120e2bb
commit
a4e6f69728
|
|
@ -909,7 +909,7 @@ class Ipd extends BaseController
|
|||
}
|
||||
|
||||
// Get current status
|
||||
$currentIpd = $this->ipdModel->getById($ipdId);
|
||||
$currentIpd = $this->ipdEditModel->find($ipdId);
|
||||
if (! $currentIpd) {
|
||||
return $this->response->setStatusCode(404)->setJSON(['update' => 0, 'message' => 'IPD not found']);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user