ConfigController.php 553 B

1234567891011121314151617181920212223242526
  1. <?php
  2. declare(strict_types=1);
  3. namespace App\Controller\Api;
  4. use App\Controller\AbstractController;
  5. use App\Library\Redis;
  6. class ConfigController extends AbstractController
  7. {
  8. // 清除定时任务缓存
  9. public function clearTiming()
  10. {
  11. $data = Redis::keys('framework/crontab*');
  12. if(!empty($data)){
  13. Redis::del($data);
  14. }
  15. return $this->responseApi(200,'success');
  16. }
  17. // 检查是否启动
  18. public function checkStatus()
  19. {
  20. return $this->responseApi(200,'success');
  21. }
  22. }