From f873f9aa6504fd0f17e863e302faaeae611f38e2 Mon Sep 17 00:00:00 2001 From: Jon Bendtsen Date: Mon, 1 Apr 2024 11:35:57 +0200 Subject: [PATCH] will allow updating 1 task single Complementary Attribute without specifying complementary attributes that we don't want to change. Similar to # 29115 but just for a task --- htdocs/projet/class/api_tasks.class.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/htdocs/projet/class/api_tasks.class.php b/htdocs/projet/class/api_tasks.class.php index 89907456672..2e4557a44a7 100644 --- a/htdocs/projet/class/api_tasks.class.php +++ b/htdocs/projet/class/api_tasks.class.php @@ -462,7 +462,12 @@ class Tasks extends DolibarrApi $this->task->context['caller'] = $request_data['caller']; continue; } - + if ($field == 'array_options' && is_array($value)) { + foreach ($value as $index => $val) { + $this->task->array_options[$index] = $val; + } + continue; + } $this->task->$field = $value; }