Created
June 5, 2017 18:14
-
-
Save ianrodrigues/607d40ad8e3ca178896bd84592667b0f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Funceme\PCD\Persistence; | |
use Doctrine\ORM\EntityRepository; | |
use Illuminate\Support\Collection; | |
class EstacaoRepository extends EntityRepository | |
{ | |
/** | |
* @param string $cityId | |
* @return Illuminate\Support\Collection | |
*/ | |
public function findByCity($cityId) | |
{ | |
return new Collection($this->findBy(['city' => $cityId])); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment