FIX_GMC_PARANTS_E_CARD_MAIL_ISSUE
This commit is contained in:
parent
c0cb14228f
commit
95f22ec8e6
@ -5022,7 +5022,7 @@ class EmpDataServiceController extends BaseController
|
|||||||
$processedCount++;
|
$processedCount++;
|
||||||
|
|
||||||
// Send batch emails or handle single email
|
// Send batch emails or handle single email
|
||||||
if ($count == 20 || $processedCount == count($ids)) {
|
if ($count == 20 || $processedCount == count($emp_details)) {
|
||||||
if (!empty($wholeData)) {
|
if (!empty($wholeData)) {
|
||||||
if ($single_mail == 1) {
|
if ($single_mail == 1) {
|
||||||
$this->myLogger->logme('error', 'sendMailForDownloadingECard - Sending single mail');
|
$this->myLogger->logme('error', 'sendMailForDownloadingECard - Sending single mail');
|
||||||
@ -5035,7 +5035,12 @@ class EmpDataServiceController extends BaseController
|
|||||||
$wholeData = [];
|
$wholeData = [];
|
||||||
$count = 0;
|
$count = 0;
|
||||||
}
|
}
|
||||||
|
}else{
|
||||||
|
$this->myLogger->logme('error', 'sendMailForDownloadingECard - Whole mail data is empty');
|
||||||
}
|
}
|
||||||
|
}else{
|
||||||
|
$idscount = count($ids);
|
||||||
|
$this->myLogger->logme('error', "sendMailForDownloadingECard - processedCount not equal to ids count, processedCount : {$processedCount} and ids count : {$idscount}");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -5048,9 +5053,19 @@ class EmpDataServiceController extends BaseController
|
|||||||
return ['status' => false , 'message' => 'Employee Data not found'];
|
return ['status' => false , 'message' => 'Employee Data not found'];
|
||||||
}
|
}
|
||||||
|
|
||||||
} catch (\Exception $e) {
|
} catch (\Exception $th) {
|
||||||
$this->myLogger->logme('error', 'sendMailForDownloadingECard - Exception occurred: {message}', ['message' => $e->getMessage()]);
|
$errorData = [
|
||||||
return ['status' => false , 'message' => 'Exception occurred' . $e->getMessage()];
|
'message' => $th->getMessage(),
|
||||||
|
'file' => $th->getFile(),
|
||||||
|
'line' => $th->getLine(),
|
||||||
|
'code' => $th->getCode(),
|
||||||
|
'trace' => $th->getTraceAsString(),
|
||||||
|
'trace_array' => $th->getTrace(), // full array version (optional)
|
||||||
|
'function' => $th->getTrace()[0]['function'] ?? null,
|
||||||
|
'class' => $th->getTrace()[0]['class'] ?? null,
|
||||||
|
];
|
||||||
|
$this->myLogger->logme('error', 'sendMailForDownloadingECard - Exception occurred: {message}', ['message' => $th->getMessage()]);
|
||||||
|
return ['status' => false , 'message' => 'Exception occurred' . $th->getMessage(), 'error_data' => $errorData];
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user