邮件分配

This commit is contained in:
2025-12-26 14:04:42 +08:00
parent 05096bc5ed
commit 927f1d9c28
6 changed files with 1137 additions and 0 deletions
+23
View File
@@ -2,6 +2,7 @@
namespace app\process;
use app\common\utils\email\Mailbox;
use Workerman\Crontab\Crontab;
use app\common\utils\email\Emails as EmailsUtils;
@@ -52,6 +53,28 @@ class Emails
$email = new EmailsUtils();
$email->fenpai();
});
//-----------多邮箱处理
// 拉取新邮件uid - 每小时的第40分钟0秒执行
new Crontab('0 */40 * * * *', function(){
$email = new Mailbox();
$email->mailbox();
});
// 拉取邮件详情 - 每小时的第35分钟0秒执行
new Crontab('0 */45 * * * *', function(){
$email = new Mailbox();
$email->pullDetails();
});
// 清洗数据 - 每小时的第55分钟0秒执行
new Crontab('0 */55 * * * *', function(){
$email = new Mailbox();
$email->processMailbox();
});
// 邮件分派 - 每小时的第10分钟0秒执行
new Crontab('0 */10 * * * *', function(){
$email = new Mailbox();
$email->fenpaiMailbox();
});
}
}