作者 lyh

列表页聚合页模式

... ... @@ -25,7 +25,7 @@ class AiVideoController extends BaseController
* @time :2025/8/2 11:19
*/
public function ImageCallBack(){
@file_put_contents(storage_path('logs/lyh_error.log'), var_export($this->param, true) . PHP_EOL, FILE_APPEND);
$this->saveLog('数据详情:'.json_encode($this->param,true));
Log::channel('ai_video')->info('数据详情:'.json_encode($this->param,true));
$count = Redis::decr('ai_video_image');
if ($count < 0) {
... ... @@ -39,11 +39,13 @@ class AiVideoController extends BaseController
//获取当前数据详情
$info = $aiVideoAutoLogModel->read(['trigger_id'=>$this->param['id']]);
if($info === false){
@file_put_contents(storage_path('logs/ai_video.log'), var_export($info, true) . PHP_EOL, FILE_APPEND);
Log::channel('ai_video')->info('当前数据不存在或已被删除'.$this->param['id']);
}
//上传图片 返回cdn链接
$cosService = new CosService();
$imagePath = $cosService->uploadRemote($info['project_id'],'video',$data['url']);
@file_put_contents(storage_path('logs/ai_video.log'), var_export($imagePath, true) . PHP_EOL, FILE_APPEND);
try {
if($imagePath){
$cos = config('filesystems.disks.cos');
... ... @@ -66,4 +68,16 @@ class AiVideoController extends BaseController
}
$this->response('success');
}
/**
* @remark :保存日志
* @name :saveLog
* @author :lyh
* @method :post
* @time :2025/8/4 11:54
*/
public function saveLog($message){
@file_put_contents(storage_path('logs/ai_video.log'), var_export($message, true) . PHP_EOL, FILE_APPEND);
return true;
}
}
... ...
... ... @@ -32,7 +32,11 @@ class DomainInfoController extends BaseController
if(isset($this->map['domain']) && !empty($this->map['domain'])){
$this->map['domain'] = ['like','%'.$this->map['domain'].'%'];
}
$lists = $domainModel->lists($this->map,$this->page,$this->row,$this->order);
if(isset($this->map['sort']) && !empty($this->map['sort'])){
$sort = $this->map['sort'];
unset($this->map['sort']);
}
$lists = $domainModel->lists($this->map,$this->page,$this->row,$this->order,['*'],$sort = 'desc');
if(!empty($lists)){
$project_model = new Project();
$serverIpModel = new ServersIp();
... ...