From 03728ff399f8bd53f0a645ba9c7b1879a628d0fd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=B5=B5=E9=92=8A?= Date: Tue, 20 Jan 2026 21:51:24 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E9=9C=80=E6=B1=82=EF=BC=9APK=E4=BB=BB?= =?UTF-8?q?=E5=8A=A1=20=E6=8F=90=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/api/model/Tasks.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/application/api/model/Tasks.php b/application/api/model/Tasks.php index 97da9db5..9910b2c9 100644 --- a/application/api/model/Tasks.php +++ b/application/api/model/Tasks.php @@ -501,13 +501,19 @@ class Tasks extends Model $ext = $user_daily_tasks['ext']; } $current_progress = $user_daily_tasks['current_progress'] + 1; - if($current_progress >= $task_info['target_quantity'] && $user_daily_tasks['ext'] >= 1){ + if($current_progress >= $task_info['target_quantity'] && $ext >= 1){ $is_completed = 1; $completion_time = time(); }else{ $is_completed = 0; $completion_time = null; } + if($current_progress > $task_info['target_quantity']){ + $current_progress = $task_info['target_quantity']; + } + if($ext > 1){ + $ext = 1; + } $reslut = Db::name('vs_tasks_user_daily')->where('id',$user_daily_tasks['id'])->update([ 'current_progress' => $current_progress, 'is_completed'=> $is_completed,