初始化项目:添加后端代码、ThinkPHP框架、前端资源

This commit is contained in:
amb
2026-09-03 12:42:39 +08:00
commit 482bece22e
3726 changed files with 416708 additions and 0 deletions
+47
View File
@@ -0,0 +1,47 @@
<?php
namespace app\callback\controller;
/**
* 自动任务
*/
class Auto
{
public function handle(){
$token = input('token');
$data = \app\common\model\app\Config::getConfig('crontab');
if($data['token'] != $token){
exit("token错误");
}
//公众号 - 消息推送
(new \app\admin\library\app\msgpush\Msg)->handle();
//订单超时关闭
(new \app\callback\controller\Order)->ordertimeoutclose();
//实物商品自动确认收货
(new \app\callback\controller\app\physical\Physical)->autoConfirmReceive();
if(\app\admin\library\project\App::isInstall('test')){
//发布考试
(new \app\admin\model\app\test\Test)->timePush();
//自动交卷
(new \app\admin\model\app\test\Worklog)->timeSubmitWorklog();
}
//同步学习数据缓存到数据库
(new \app\common\model\user\Study())->batchSyncStudyCache();
//同步流量数据到数据库
(new \app\api\model\data\Traffic)->cacheToDatabses();
//清理已删除课程对应的阿里云互动消息群组
\app\common\library\live\message\Manager::cleanupOrphanGroups(50, false);
echo "执行完毕";
}
}