Commit 2566f156 by 王召彬

添加预约模块

parent 585caa1b
<?php
namespace Hdll\Services\Reservation\Enum;
class ReservationError
{
const E3001 = ['code'=>400, 'errCode'=>3001, 'msg'=>'客户端传参错误'];
const E3002 = ['code'=>404, 'errCode'=>3002, 'msg'=>'查询不到用户数据'];
const E3003 = ['code'=>401, 'errCode'=>3003, 'msg'=>'无权限操作'];
const E3004 = ['code'=>404, 'errCode'=>3004, 'msg'=>'数据不存在'];
const E3102 = ['code'=>400, 'errCode'=>3102, 'msg'=>'手机号不正确'];
const E3201 = ['code'=>400, 'errCode'=>3201, 'msg'=>'xxxx'];
const E3202 = ['code'=>400, 'errCode'=>3202, 'msg'=>'短信发送失败:'];
const E3203 = ['code'=>400, 'errCode'=>3203, 'msg'=>'验证码不正确'];
const E3204 = ['code'=>400, 'errCode'=>3204, 'msg'=>'xxxx'];
const E3205 = ['code'=>400, 'errCode'=>3205, 'msg'=>'xxxx'];
const E3206 = ['code'=>400, 'errCode'=>3206, 'msg'=>'xxxx'];
const E3207 = ['code'=>400, 'errCode'=>3207, 'msg'=>'xxxx'];
const E3208 = ['code'=>400, 'errCode'=>3208, 'msg'=>'xxxx'];
const E3209 = ['code'=>400, 'errCode'=>3209, 'msg'=>'xxxx'];
const E3210 = ['code'=>400, 'errCode'=>3210, 'msg'=>'xxxx'];
public static function getError($code) {
$reflect = new \ReflectionClass(__CLASS__);
return $reflect->getConstant('E'.$code);
}
}
\ No newline at end of file
<?php
/**
* This file is part of Swoft.
*
* @link https://swoft.org
* @document https://doc.swoft.org
* @contact group@swoft.org
* @license https://github.com/swoft-cloud/swoft/blob/master/LICENSE
*/
namespace Hdll\Services\Reservation\Lib;
use Swoft\Core\ResultInterface;
/**
* The interface of Schedule service
*
* @method ResultInterface deferGetScheduleList(int $storeId, int $month=null)
* @method ResultInterface deferGetScheduleByDateId(int $storeId, int $dateId)
* @method ResultInterface deferUpdateSchedule(int $storeId, int $dateId, array $data)
* @method ResultInterface deferAddSchedule(int $storeId, int $dateId, array $data)
*/
interface ReservationInterface
{
}
\ No newline at end of file
...@@ -23,7 +23,7 @@ class ScheduleError ...@@ -23,7 +23,7 @@ class ScheduleError
const E8210 = ['code'=>400, 'errCode'=>8210, 'msg'=>'xxxx']; const E8210 = ['code'=>400, 'errCode'=>8210, 'msg'=>'xxxx'];
public static function getError($code) { public static function getError($code) {
$reflect = new \ReflectionClass(StoreError::class); $reflect = new \ReflectionClass(__CLASS__);
return $reflect->getConstant('E'.$code); return $reflect->getConstant('E'.$code);
} }
} }
\ No newline at end of file
...@@ -23,7 +23,7 @@ class StoreError ...@@ -23,7 +23,7 @@ class StoreError
const E5210 = ['code'=>400, 'errCode'=>5210, 'msg'=>'xxxx']; const E5210 = ['code'=>400, 'errCode'=>5210, 'msg'=>'xxxx'];
public static function getError($code) { public static function getError($code) {
$reflect = new \ReflectionClass(StoreError::class); $reflect = new \ReflectionClass(__CLASS__);
return $reflect->getConstant('E'.$code); return $reflect->getConstant('E'.$code);
} }
} }
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment