23 lines
456 B
PHP
23 lines
456 B
PHP
<?php
|
|
|
|
namespace App\Repositories\Api\Client;
|
|
|
|
use App\Models\Customer;
|
|
use App\Repositories\Api\BaseApiRepository;
|
|
|
|
class ClientRepository extends BaseApiRepository implements ClientRepositoryInterface
|
|
{
|
|
public function getModel()
|
|
{
|
|
return Customer::class;
|
|
}
|
|
|
|
/**
|
|
* Tìm khách hàng theo email
|
|
*/
|
|
public function findByEmail(string $email)
|
|
{
|
|
return $this->model->where('email', $email)->first();
|
|
}
|
|
}
|