add mailto to reports
This commit is contained in:
@@ -4,7 +4,10 @@ namespace App\Entity;
|
||||
|
||||
use App\Enum\ReportStatus;
|
||||
use App\Enum\ReportTodoEnum;
|
||||
use App\Helper\MonthHelper;
|
||||
use App\Repository\ReportsRepository;
|
||||
use App\Services\AddReports;
|
||||
use App\Services\MailtoServices;
|
||||
use Doctrine\Common\Collections\ArrayCollection;
|
||||
use Doctrine\Common\Collections\Collection;
|
||||
use Doctrine\DBAL\Types\Types;
|
||||
@@ -127,6 +130,11 @@ class Reports
|
||||
return $this->isReportsTodo(ReportTodoEnum::COMPLETE);
|
||||
}
|
||||
|
||||
public function isEmailSend(): bool
|
||||
{
|
||||
return $this->isReportsTodo(ReportTodoEnum::SENT_EMAIL);
|
||||
}
|
||||
|
||||
public function countTodoReports(): int
|
||||
{
|
||||
$count = 0;
|
||||
@@ -197,4 +205,11 @@ class Reports
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function takeMailToUrl(): string
|
||||
{
|
||||
$service = new MailtoServices();
|
||||
|
||||
return $service->takeUrl($this);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user