Fixed outgoing mails disabled issue
Fixed language Fixed languag and email create/edit issue v1.10.2 build updates Fixed codacy issues
This commit is contained in:

committed by
Manish Verma

parent
ac4e053c2d
commit
6a3d093b4c
@@ -339,7 +339,9 @@ class TemplateController extends Controller
|
||||
|
||||
$this->PhpMailController->sendmail($from, $to_address, $message, [], []);
|
||||
|
||||
return redirect()->back()->with('success', 'Mail has send successfully');
|
||||
return redirect()->back()->with(
|
||||
'success',
|
||||
trans('lang.mail-sent-to-job-for-process'));
|
||||
} catch (Exception $e) {
|
||||
return redirect()->back()->with('fails', $e->getMessage());
|
||||
}
|
||||
|
@@ -26,7 +26,10 @@ class PhpMailController extends Controller
|
||||
|
||||
public function fetch_smtp_details($id)
|
||||
{
|
||||
$emails = Emails::where('id', '=', $id)->first();
|
||||
$emails = Emails::where(
|
||||
[['id', '=', $id],
|
||||
['sending_status', '=', 1]])
|
||||
->first();
|
||||
|
||||
return $emails;
|
||||
}
|
||||
|
@@ -36,8 +36,13 @@ class SendEmail extends Job implements ShouldQueue
|
||||
*/
|
||||
public function handle(PhpMailController $PhpMailController)
|
||||
{
|
||||
$p = $PhpMailController->sendEmail($this->from, $this->to, $this->message, $this->template);
|
||||
try {
|
||||
$p = $PhpMailController->sendEmail($this->from, $this->to, $this->message, $this->template);
|
||||
|
||||
return $p;
|
||||
return $p;
|
||||
} catch (\Exception $e) {
|
||||
logger()->warning($e->getMessage());
|
||||
session()->flash('fails', $e->getMessage());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user