private function makeSyncEntry($billNo, $userId, $restaurantId) { $newBillDetailsEntryList = $this->getTableObj()->getNewDetails($billNo); if (!is_null($newBillDetailsEntryList)) { $syncController = new SyncController(); foreach ($newBillDetailsEntryList as $newBillDetails) { $syncResult = $syncController->billDetailsEntry($userId, json_encode($newBillDetails), INSERT_OPERATION, $restaurantId); if (!$syncResult) { return $syncResult; } } Log::debug(' New bill Details entry successfully place in sync table'); return $syncResult; } Log::error('Error occured in sync entry of new bill Details '); return; }