The source of this bug can be found
file: ./core/modules/taxonomy.admin.inc
line: 515
function: taxonomy_overview_terms_submit

The local task/form "list" found at the url admin/structure/taxonomy/spo does not correctly call hook_taxonomy_term_save. Raw updates to the database should not be made for terms as they do not fire the proper hooks. The full term object should be retrieved by id then passed to taxonomy_term_save.

Attached is a patch that will solve this small but annoying error. The solution is simply to retrieve the term object by tid and update the term by calling taxonomy_term_save() which correctly fires the hook_taxonomy_term_save on update of the term.

Fancy language aside this is a silly bug and something I have heard complained about. With the simple fix of rolling by the Drupal convention I hope I can start to contribute some real help to this project =)

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

ibrokenjames’s picture

PATCH

ibrokenjames’s picture

That was silly of me. I saved the post to get the post number to properly name the patch! I am glad I am learning to contribute small first x.X

The last submitted patch, term_update_hooks_admin_section-1350154-1.patch, failed testing.

jibran’s picture

Title: Taxonomy Drag Drop UI bug » Taxonomy Drag Drop UI bug
Assigned: ibrokenjames » Unassigned
Issue summary: View changes
Status: Needs work » Fixed
Issue tags: -taxonomy, -term

This is fixed see Drupal\taxonomy\Form\OverviewTerms::submitForm:453

 // Save all updated terms.
  foreach ($changed_terms as $term) {
    $term->save();
  }

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.