Refactor subscriber statistics to doctrine

[MAILPOET-3168]
This commit is contained in:
Pavel Dohnal
2021-01-06 11:12:30 +01:00
committed by Veljko V
parent de6e0e5adb
commit 1d6cf56fd9
5 changed files with 55 additions and 20 deletions

View File

@@ -82,6 +82,10 @@ class Segment extends Model {
->delete();
}
/**
* @deprecated Use the version in \MailPoet\Segments\SegmentSubscribersRepository::getSubscribersStatisticsCount
* @return $this
*/
public function withSubscribersCount() {
$query = SubscriberSegment::tableAlias('relation')
->where('relation.segment_id', $this->id)