CategoryLookup
\Automattic\WooCommerce\Admin\CategoryLookup class.
Description Description
Source Source
File: packages/woocommerce-admin/src/CategoryLookup.php
Methods Methods
- __construct — Constructor
- before_edit — Store edits so we know when the parent ID changes.
- delete — Delete lookup table data from a tree.
- get_ancestors — Return all ancestor category ids for a category.
- get_descendants — Get category descendants.
- get_insert_sql — Get category lookup table values to insert.
- get_term_insert_values — Used to construct insert query recursively.
- init — Init hooks.
- instance — Get class instance.
- on_edit — When a product category gets edited, see if we need to sync the table.
- regenerate — Regenerate all lookup table data.
- unflatten_terms — Convert flat terms array into nested array.
- update — Updates lookup table data for a category by ID.