Skip to content
This repository has been archived by the owner on Jun 5, 2024. It is now read-only.

Commit

Permalink
Merge pull request #4 from 3ev/INT-1858
Browse files Browse the repository at this point in the history
INT-1858 | Added findByMcListId function
  • Loading branch information
chris-3ev committed Sep 14, 2020
2 parents a5ca354 + fa29480 commit 50e4610
Showing 1 changed file with 16 additions and 1 deletion.
17 changes: 16 additions & 1 deletion Classes/Domain/Repository/MlistRepository.php
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ public function findAllNotSubscribedToBy(FrontendUser $user)
}

/**
* Find list item by my_list_id even if it is hidden.
* Find list item by mc_list_id even if it is hidden.
*
* @param string $mcListId
* @return \TYPO3\CMS\Extbase\Persistence\QueryResultInterface
Expand All @@ -129,4 +129,19 @@ public function findHiddenOneByMcListId($mcListId)

return $query->execute()->getFirst();
}

/**
* Find a list item by mc_list_id
*
* @param string $mcListId
*
* @return mixed
*/
public function findByMcListId($mcListId)
{
$query = $this->createQuery();
$query->matching($query->equals('mc_list_id', $mcListId));

return $query->execute()->getFirst();
}
}

0 comments on commit 50e4610

Please sign in to comment.