add service dir

This commit is contained in:
cano
2024-03-26 20:07:19 +08:00
parent 6ce37d789f
commit 01e93acdd8
20 changed files with 24 additions and 30 deletions

View File

@ -0,0 +1,21 @@
<?php
namespace App\Service\Api;
use App\Thrid\Sms\Movider\Movider;
use App\Thrid\Sms\SmsInterface;
class SmsService
{
function sendSmsCode($phone, $code): bool
{
return $this->getChannel()->sendSmsCode($phone, $code);
}
function getChannel(): SmsInterface
{
return new Movider();
}
}