in fact , the problem was the $oeuvre variable, for it is an array
i had to write :
$term_taxonomy_ids = wp_set_object_terms( $oeuvre->ID, $term_id, ‘statut_oeuvre’);
$term_taxonomy_ids = wp_set_object_terms( $oeuvre, $term_id, ‘statut_oeuvre’);
Thanks for help
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users