|
|
@@ -97,12 +97,18 @@ if($action) {
|
|
|
throw new RuntimeException("Target user not found.");
|
|
|
}
|
|
|
|
|
|
+ $dt_deadline = $project->getDateTimeDeadline();
|
|
|
+ $dt_default_due = CarbonImmutable::now(TIMEZONE)->addDays(7);
|
|
|
+
|
|
|
+ /** @var CarbonImmutable $dt_due */
|
|
|
+ $dt_due = min($dt_deadline, $dt_default_due);
|
|
|
+
|
|
|
$tests = Test::query(["id" => $test_ids, "project_id" => $id, "status" => [
|
|
|
Test::STATUS_UNASSIGNED,
|
|
|
Test::STATUS_ASSIGNED,
|
|
|
]]);
|
|
|
foreach($tests as $test) {
|
|
|
- $test->assignTester($tester);
|
|
|
+ $test->assignTester($tester, $dt_due);
|
|
|
}
|
|
|
|
|
|
break;
|