Fixes for notifications (#3561)

This commit is contained in:
David Bomba 2020-03-29 23:47:41 +11:00 committed by GitHub
parent 8b0fe63eb5
commit 9d6da3e37b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 7 deletions

View File

@ -114,9 +114,10 @@ class EmailController extends BaseController
}
});
$data = [];
return response()->json($data, 200);
$entity->service()->markSent()->save();
return $this->itemResponse($entity);
}
}

View File

@ -58,8 +58,8 @@ class SendGenericNotification extends Notification implements ShouldQueue
* @return array
*/
public function via($notifiable)
{\Log::error("via");
return ['slack','mail'];
{
return ['mail'];
}
/**
@ -70,7 +70,7 @@ class SendGenericNotification extends Notification implements ShouldQueue
*/
public function toMail($notifiable)
{
\Log::error("to mail");
$subject = $this->generateEmailEntityHtml($this->entity, $this->subject, $this->contact);
$body = $this->generateEmailEntityHtml($this->entity, $this->body, $this->contact);
@ -114,7 +114,7 @@ class SendGenericNotification extends Notification implements ShouldQueue
public function toSlack($notifiable)
{
\Log::error("slack");
return '';
// $logo = $this->company->present()->logo();
// $amount = Number::formatMoney($this->invoice->amount, $this->invoice->client);