Kernel.php 3.3 KB
<?php

namespace App\Console;

use Illuminate\Console\Scheduling\Schedule;
use Illuminate\Foundation\Console\Kernel as ConsoleKernel;

class Kernel extends ConsoleKernel
{
    /**
     * Define the application's command schedule.
     *
     * @param  \Illuminate\Console\Scheduling\Schedule  $schedule
     * @return void
     */
    protected function schedule(Schedule $schedule)
    {
        // 每日更新最新模块
        $schedule->command('template_label')->dailyAt('01:00')->withoutOverlapping(1);//最新模块
        $schedule->command('popular_template_label')->dailyAt('01:30')->withoutOverlapping(1);//热门模块
        // $schedule->command('inspire')->hourly();
        $schedule->command('remain_day')->dailyAt('09:00')->withoutOverlapping(1); // 项目剩余服务时长
        $schedule->command('rank_data_task')->everyMinute()->withoutOverlapping(1); // 排名数据更新任务
        $schedule->command('service_count')->dailyAt('01:00')->withoutOverlapping(1); //服务器使用情况,每天凌晨1点执行一次
        $schedule->command('web_traffic_special')->everyMinute()->withoutOverlapping(1); // 特殊引流
        $schedule->command('web_traffic_russia_special')->everyMinute()->withoutOverlapping(1); // 特殊引流
        $schedule->command('sync_channel')->dailyAt('06:00')->withoutOverlapping(1); // 渠道信息,每天执行一次
        $schedule->command('forward_count')->monthlyOn(1,'01:00')->withoutOverlapping(1);//没月月初1号执行月统计转发询盘记录
        $schedule->command('inquiry_delay')->everyMinute()->withoutOverlapping(1);//TODO::上线放开,转发询盘,每分钟执行一次
        $schedule->command('inquiry_count')->dailyAt('01:00')->withoutOverlapping(1); // 询盘统计数据,每天凌晨执行一次
//        $schedule->command('domain_info')->dailyAt('01:20')->withoutOverlapping(1);// 更新域名|证书结束时间,每天凌晨1点执行一次
                $schedule->command('share_user')->dailyAt('01:20')->withoutOverlapping(1);// 每天凌晨1点执行一次
        $schedule->command('last_inquiry')->dailyAt('04:00')->withoutOverlapping(1);// 最近一次询盘信息
        $schedule->command('update_seo_tdk_crontab')->dailyAt('20:00')->withoutOverlapping(1); //更新上线项目TDK
        $schedule->command('sync_manager')->dailyAt('01:00')->withoutOverlapping(1); //TODO::手机号码同步  每天执行一次
        $schedule->command('update_keyword_route')->dailyAt('01:00')->withoutOverlapping(1); //升级项目--清除路由相同的关键字
        $schedule->command('recommended_suppliers')->dailyAt('03:00')->withoutOverlapping(1); //每天凌晨1点执行一次生成推荐商
        $schedule->command('update_keyword_content')->hourly()->withoutOverlapping(1);
        // 每月15号执行任务
        $schedule->command('delete_template_log')->monthlyOn(15, '00:01')->withoutOverlapping();
        // 每日推送已完成视频任务项目生成对应界面
        $schedule->command('notice_c')->dailyAt('04:00')->withoutOverlapping(1);
    }

    /**
     * Register the commands for the application.
     *
     * @return void
     */
    protected function commands()
    {
        $this->load(__DIR__.'/Commands');

        require base_path('routes/console.php');
    }
}