Method | Description | |
---|---|---|
child_has_dimensions ( $product ) : boolean | Does a child have dimensions set? | |
child_has_weight ( $product ) : boolean | Does a child have a weight set? | |
child_is_in_stock ( $product ) : boolean | Is a child in stock? | |
read_children ( &$product, boolean $force_read = false ) : WC_Product | Loads variation child IDs. | |
sync_managed_variation_stock_status ( &$product ) | Stock managed at the parent level - update children being managed by this product. | |
sync_price ( WC_Product | integer &$product ) | Sync variable product prices with children. | |
sync_stock_status ( WC_Product | integer &$product ) | Sync variable product stock status with children. |
Method | Description | |
---|---|---|
read_product_data ( &$product ) | Read product data. |
Method | Description | |
---|---|---|
read_price_data ( &$product, boolean $include_taxes = false ) | Get an array of all sale and regular prices from all variations. This is used for example when displaying the price range at variable product level or seeing if the variable product is on sale. | |
read_variation_attributes ( &$product ) | Loads an array of attributes used for variations, as well as their possible values. |
public child_has_dimensions ( $product ) : boolean | ||
return | boolean |
public child_has_weight ( $product ) : boolean | ||
return | boolean |
public child_is_in_stock ( $product ) : boolean | ||
return | boolean |
public read_children ( &$product, boolean $force_read = false ) : WC_Product | ||
$force_read | boolean | True to bypass the transient. |
return | WC_Product |
public sync_managed_variation_stock_status ( &$product ) |
public sync_price ( WC_Product | integer &$product ) | ||
$product | WC_Product | integer |
public sync_stock_status ( WC_Product | integer &$product ) | ||
$product | WC_Product | integer |