From 4b20ffba85b88c4dd691bcad3f5cd50cb65f0731 Mon Sep 17 00:00:00 2001 From: wangjinlei <751475802@qq.com> Date: Thu, 11 Jun 2026 15:12:48 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8E=A8=E5=B9=BF=E9=A2=91=E7=8E=87=E6=9B=B4?= =?UTF-8?q?=E6=94=B9=EF=BC=8C=E5=8D=8A=E4=B8=AA=E6=9C=88=E5=8F=91=E4=B8=80?= =?UTF-8?q?=E5=B0=81=E6=98=AF=E5=8F=AF=E8=A1=8C=E7=9A=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/common/PromotionService.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/application/common/PromotionService.php b/application/common/PromotionService.php index c5b1ad2e..9e0b3bb0 100644 --- a/application/common/PromotionService.php +++ b/application/common/PromotionService.php @@ -253,9 +253,13 @@ class PromotionService 'send_time' => $now, ]); Db::name('journal_email')->where('j_email_id', $account['j_email_id'])->setInc('today_sent'); - // 仅外部 expert 库回写最近一次推广时间;内部 user 用 promotion_email_log.send_time 计频次 + // 仅外部 expert 库回写最近一次推广时间与累计推广次数;内部 user 用 promotion_email_log.send_time 计频次 if ($audienceKind === 'expert' && intval($expert['expert_id']) > 0) { - Db::name('expert')->where('expert_id', $expert['expert_id'])->update(['state' => 1, 'ltime' => $now]); + Db::name('expert')->where('expert_id', $expert['expert_id'])->update([ + 'state' => 1, + 'ltime' => $now, + 'times' => Db::raw('times+1'), + ]); } Db::name('promotion_task')->where('task_id', $taskId)->setInc('sent_count'); } else {