You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Closed as I assume it is fixed. I'm not using these fields because they don't show up on the card in the UI.
I made my own extrafields to add public and private notea as needed 😀
Bug
Dolibarr simply discards the note_private and note_public in the json and create the product with all other fields.
Environment
Expected and actual behavior
expected Dolibarr to insert the data in the database.
Steps to reproduce the behavior
insert a product with rest explorer
curl -X POST --header 'Content-Type: application/json' --header 'Accept: application/json' --header 'DOLAPIKEY: ' -d '{"ref": "test3",
"label": "test",
"note": "test",
"note_private": "test",
"note_public": "test"}' 'http://dolibarr.localhost/api/index.php/products'
-> this inserts note and note_private
curl -X POST --header 'Content-Type: application/json' --header 'Accept: application/json' --header 'DOLAPIKEY: ' -d '{"ref": "test3",
"label": "test",
"note_private": "test",
"note_public": "test"}' 'http://dolibarr.localhost/api/index.php/products'
-> this inserts none of them
curl -X POST --header 'Content-Type: application/json' --header 'Accept: application/json' --header 'DOLAPIKEY: ' -d '{"ref": "test3",
"label": "test",
"note_public": "test"}' 'http://dolibarr.localhost/api/index.php/products'
-> this inserts "test" into note and note_private
So note_public and note_private never works. note works and duplicates into note_private.
Suggestion: remove the confusing note-field and fix note_public and note_private.
Related issue: #11447
The text was updated successfully, but these errors were encountered: