forked from Wavyzz/dolibarr
FIX 17.0 API endpoints "PUT": prevent overwriting all extrafields if only some are supplied in the request cf. PR #29237
+ security for Tickets API: disable updating rowid
This commit is contained in:
@@ -447,6 +447,12 @@ class Receptions extends DolibarrApi
|
||||
if ($field == 'id') {
|
||||
continue;
|
||||
}
|
||||
if ($field == 'array_options' && is_array($value)) {
|
||||
foreach ($value as $index => $val) {
|
||||
$this->reception->array_options[$index] = $this->_checkValForAPI($field, $val, $this->reception);
|
||||
}
|
||||
continue;
|
||||
}
|
||||
$this->reception->$field = $value;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user