diff --git a/app/Cache/Redis/Common/CommonRedisKey.php b/app/Cache/Redis/Common/CommonRedisKey.php index 7ea318f..f0323a4 100644 --- a/app/Cache/Redis/Common/CommonRedisKey.php +++ b/app/Cache/Redis/Common/CommonRedisKey.php @@ -5,6 +5,17 @@ namespace App\Cache\Redis\Common; class CommonRedisKey { /** + * 获取系统配置列表 + * @param $pid + * @return string + */ + public static function getSystemConfigList($pid): string + { + return '__system:config:list:' . $pid; + } + + /** + * 获取系统配置 * @return string *@var string $type */ diff --git a/app/Cache/Redis/Common/ConfigCache.php b/app/Cache/Redis/Common/ConfigCache.php new file mode 100644 index 0000000..86e2ac9 --- /dev/null +++ b/app/Cache/Redis/Common/ConfigCache.php @@ -0,0 +1,31 @@ +redis->exists($key,'system')) return json_decode($this->redis->get($key),true); + + return []; + } +} \ No newline at end of file diff --git a/app/Request/Admin/ChefRequest.php b/app/Request/Admin/ChefRequest.php index 2108e36..d985e32 100644 --- a/app/Request/Admin/ChefRequest.php +++ b/app/Request/Admin/ChefRequest.php @@ -29,7 +29,7 @@ class ChefRequest extends FormRequest 'user_id' =>'required|integer|exists:chef,user_id', 'profile' =>'sometimes', 'specialties' =>'sometimes', - 'query_city_id' => 'sometimes|integer|exists:city,id', + 'query_city_id' => 'sometimes|integer|exists:system_city,id', ]; } diff --git a/app/Service/ServiceTrait/Common/CycleTrait.php b/app/Service/ServiceTrait/Common/CycleTrait.php new file mode 100644 index 0000000..a1fe75c --- /dev/null +++ b/app/Service/ServiceTrait/Common/CycleTrait.php @@ -0,0 +1,22 @@ +