/home/techb158/balacoffee.com/wp-content/plugins/woocommerce/includes
NameSizeModeActions
abstracts/-0755rm
admin/-0755rm
blocks/-0755rm
cli/-0755rm
customizer/-0755rm
data-stores/-0755rm
emails/-0755rm
export/-0755rm
gateways/-0755rm
import/-0755rm
integrations/-0755rm
interfaces/-0755rm
legacy/-0755rm
libraries/-0755rm
log-handlers/-0755rm
payment-tokens/-0755rm
product-usage/-0755rm
queue/-0755rm
react-admin/-0755rm
rest-api/-0755rm
shipping/-0755rm
shortcodes/-0755rm
theme-support/-0755rm
tracks/-0755rm
traits/-0755rm
walkers/-0755rm
wccom-site/-0755rm
widgets/-0755rm
class-wc-ajax.php1345980644editdlrm
class-wc-auth.php129950644editdlrm
class-wc-autoloader.php53940644editdlrm
class-wc-background-emailer.php46850644editdlrm
class-wc-background-updater.php35350644editdlrm
class-wc-brands-brand-settings-manager.php18260644editdlrm
class-wc-brands-coupons.php70590644editdlrm
class-wc-brands.php356350644editdlrm
class-wc-breadcrumb.php106600644editdlrm
class-wc-cache-helper.php129980644editdlrm
class-wc-cart-fees.php34480644editdlrm
class-wc-cart-session.php259750644editdlrm
class-wc-cart-totals.php291630644editdlrm
class-wc-cart.php773860644editdlrm
class-wc-checkout.php513490644editdlrm
class-wc-cli.php34190644editdlrm
class-wc-comments.php236310644editdlrm
class-wc-countries.php518810644editdlrm
class-wc-coupon.php449200644editdlrm
class-wc-customer-download-log.php34520644editdlrm
class-wc-customer-download.php105870644editdlrm
class-wc-customer.php340000644editdlrm
class-wc-data-exception.php13210644editdlrm
class-wc-data-store.php67520644editdlrm
class-wc-datetime.php23100644editdlrm
class-wc-deprecated-action-hooks.php67460644editdlrm
class-wc-deprecated-filter-hooks.php75180644editdlrm
class-wc-discounts.php375230644editdlrm
class-wc-download-handler.php290530644editdlrm
class-wc-emails.php402440644editdlrm
class-wc-embed.php43420644editdlrm
class-wc-form-handler.php493270644editdlrm
class-wc-frontend-scripts.php351850644editdlrm
class-wc-geo-ip.php311590644editdlrm
class-wc-geolite-integration.php20360644editdlrm
class-wc-geolocation.php116150644editdlrm
class-wc-https.php44390644editdlrm
class-wc-install.php1190170644editdlrm
class-wc-integrations.php13080644editdlrm
class-wc-log-levels.php39920644editdlrm
class-wc-logger.php96390644editdlrm
class-wc-meta-data.php22600644editdlrm
class-wc-order-factory.php89510644editdlrm
class-wc-order-item-coupon.php41750644editdlrm
class-wc-order-item-fee.php102280644editdlrm
class-wc-order-item-meta.php59420644editdlrm
class-wc-order-item-product.php179620644editdlrm
class-wc-order-item-shipping.php98150644editdlrm
class-wc-order-item-tax.php66440644editdlrm
class-wc-order-item.php219070644editdlrm
class-wc-order-query.php26130644editdlrm
class-wc-order-refund.php61350644editdlrm
class-wc-order.php794230644editdlrm
class-wc-payment-gateways.php146010644editdlrm
class-wc-payment-tokens.php63900644editdlrm
class-wc-post-data.php396170644editdlrm
class-wc-post-types.php336800644editdlrm
class-wc-privacy-background-process.php18330644editdlrm
class-wc-privacy-erasers.php139410644editdlrm
class-wc-privacy-exporters.php150440644editdlrm
class-wc-privacy.php176290644editdlrm
class-wc-product-attribute.php80570644editdlrm
class-wc-product-download.php134940644editdlrm
class-wc-product-external.php51040644editdlrm
class-wc-product-factory.php46980644editdlrm
class-wc-product-grouped.php69740644editdlrm
class-wc-product-query.php23280644editdlrm
class-wc-product-simple.php27650644editdlrm
class-wc-product-variable.php243340644editdlrm
class-wc-product-variation.php206610644editdlrm
class-wc-query.php342990644editdlrm
class-wc-rate-limiter.php41000644editdlrm
class-wc-regenerate-images-request.php79230644editdlrm
class-wc-regenerate-images.php158060644editdlrm
class-wc-register-wp-admin-settings.php51710644editdlrm
class-wc-rest-authentication.php220680644editdlrm
class-wc-rest-exception.php2760644editdlrm
class-wc-session-handler.php251620644editdlrm
class-wc-shipping-rate.php95660644editdlrm
class-wc-shipping-zone.php133920644editdlrm
class-wc-shipping-zones.php51150644editdlrm
class-wc-shipping.php133710644editdlrm
class-wc-shortcodes.php192740644editdlrm
class-wc-structured-data.php250110644editdlrm
class-wc-tax.php406940644editdlrm
class-wc-template-loader.php209110644editdlrm
class-wc-tracker.php527310644editdlrm
class-wc-validation.php59290644editdlrm
class-wc-webhook.php308070644editdlrm
class-woocommerce.php638140644editdlrm
wc-account-functions.php144850644editdlrm
wc-attribute-functions.php223770644editdlrm
wc-brands-functions.php42700644editdlrm
wc-cart-functions.php213080644editdlrm
wc-conditional-functions.php159020644editdlrm
wc-core-functions.php806030644editdlrm
wc-coupon-functions.php56980644editdlrm
wc-deprecated-functions.php407310644editdlrm
wc-formatting-functions.php510930644editdlrm
wc-interactivity-api-functions.php22190644editdlrm
wc-notice-functions.php86960644editdlrm
wc-order-functions.php450650644editdlrm
wc-order-item-functions.php51530644editdlrm
wc-order-step-logger-functions.php61140644editdlrm
wc-page-functions.php96570644editdlrm
wc-product-functions.php689920644editdlrm
wc-rest-functions.php142680644editdlrm
wc-stock-functions.php178510644editdlrm
wc-template-functions.php1454760644editdlrm
wc-template-hooks.php131510644editdlrm
wc-term-functions.php251580644editdlrm
wc-update-functions.php1048370644editdlrm
wc-user-functions.php361970644editdlrm
wc-webhook-functions.php59050644editdlrm
wc-widget-functions.php20630644editdlrm
Edit: /home/techb158/balacoffee.com/wp-content/plugins/woocommerce/includes/class-wc-order-item-tax.php (6644B)
'', 'rate_id' => 0, 'label' => '', 'compound' => false, 'tax_total' => 0, 'shipping_tax_total' => 0, 'rate_percent' => null, ); /* |-------------------------------------------------------------------------- | Setters |-------------------------------------------------------------------------- */ /** * Set order item name. * * @param string $value Name. */ public function set_name( $value ) { $this->set_rate_code( $value ); } /** * Set item name. * * @param string $value Rate code. */ public function set_rate_code( $value ) { $this->set_prop( 'rate_code', wc_clean( $value ) ); } /** * Set item name. * * @param string $value Label. */ public function set_label( $value ) { $this->set_prop( 'label', wc_clean( $value ) ); } /** * Set tax rate id. * * @param int $value Rate ID. */ public function set_rate_id( $value ) { $this->set_prop( 'rate_id', absint( $value ) ); } /** * Set tax total. * * @param string $value Tax total. */ public function set_tax_total( $value ) { $this->set_prop( 'tax_total', $value ? wc_format_decimal( $value ) : 0 ); } /** * Set shipping tax total. * * @param string $value Shipping tax total. */ public function set_shipping_tax_total( $value ) { $this->set_prop( 'shipping_tax_total', $value ? wc_format_decimal( $value ) : 0 ); } /** * Set compound. * * @param bool $value If tax is compound. */ public function set_compound( $value ) { $this->set_prop( 'compound', (bool) $value ); } /** * Set rate value. * * @param float $value tax rate value. */ public function set_rate_percent( $value ) { $this->set_prop( 'rate_percent', (float) $value ); } /** * Set properties based on passed in tax rate by ID. * * @param int $tax_rate_id Tax rate ID. */ public function set_rate( $tax_rate_id ) { $tax_rate = WC_Tax::_get_tax_rate( $tax_rate_id, OBJECT ); $this->set_rate_id( $tax_rate_id ); $this->set_rate_code( WC_Tax::get_rate_code( $tax_rate ) ); $this->set_label( WC_Tax::get_rate_label( $tax_rate ) ); $this->set_compound( WC_Tax::is_compound( $tax_rate ) ); $this->set_rate_percent( WC_Tax::get_rate_percent_value( $tax_rate ) ); } /* |-------------------------------------------------------------------------- | Getters |-------------------------------------------------------------------------- */ /** * Get order item type. * * @return string */ public function get_type() { return 'tax'; } /** * Get rate code/name. * * @param string $context What the value is for. Valid values are 'view' and 'edit'. * @return string */ public function get_name( $context = 'view' ) { return $this->get_rate_code( $context ); } /** * Get rate code/name. * * @param string $context What the value is for. Valid values are 'view' and 'edit'. * @return string */ public function get_rate_code( $context = 'view' ) { return $this->get_prop( 'rate_code', $context ); } /** * Get label. * * @param string $context What the value is for. Valid values are 'view' and 'edit'. * @return string */ public function get_label( $context = 'view' ) { $label = $this->get_prop( 'label', $context ); if ( 'view' === $context ) { return $label ? $label : __( 'Tax', 'woocommerce' ); } else { return $label; } } /** * Get tax rate ID. * * @param string $context What the value is for. Valid values are 'view' and 'edit'. * @return int */ public function get_rate_id( $context = 'view' ) { return $this->get_prop( 'rate_id', $context ); } /** * Get tax_total * * @param string $context What the value is for. Valid values are 'view' and 'edit'. * @return string */ public function get_tax_total( $context = 'view' ) { return $this->get_prop( 'tax_total', $context ); } /** * Get shipping_tax_total * * @param string $context What the value is for. Valid values are 'view' and 'edit'. * @return string */ public function get_shipping_tax_total( $context = 'view' ) { return $this->get_prop( 'shipping_tax_total', $context ); } /** * Get compound. * * @param string $context What the value is for. Valid values are 'view' and 'edit'. * @return bool */ public function get_compound( $context = 'view' ) { return $this->get_prop( 'compound', $context ); } /** * Is this a compound tax rate? * * @return boolean */ public function is_compound() { return $this->get_compound(); } /** * Get rate value * * @param string $context What the value is for. Valid values are 'view' and 'edit'. * @return float */ public function get_rate_percent( $context = 'view' ) { return $this->get_prop( 'rate_percent', $context ); } /* |-------------------------------------------------------------------------- | Array Access Methods |-------------------------------------------------------------------------- | | For backwards compatibility with legacy arrays. | */ /** * O for ArrayAccess/Backwards compatibility. * * @param string $offset Offset. * @return mixed */ #[\ReturnTypeWillChange] public function offsetGet( $offset ) { if ( 'tax_amount' === $offset ) { $offset = 'tax_total'; } elseif ( 'shipping_tax_amount' === $offset ) { $offset = 'shipping_tax_total'; } return parent::offsetGet( $offset ); } /** * OffsetSet for ArrayAccess/Backwards compatibility. * * @deprecated 4.4.0 * @param string $offset Offset. * @param mixed $value Value. */ #[\ReturnTypeWillChange] public function offsetSet( $offset, $value ) { wc_deprecated_function( 'WC_Order_Item_Tax::offsetSet', '4.4.0', '' ); if ( 'tax_amount' === $offset ) { $offset = 'tax_total'; } elseif ( 'shipping_tax_amount' === $offset ) { $offset = 'shipping_tax_total'; } parent::offsetSet( $offset, $value ); } /** * OffsetExists for ArrayAccess. * * @param string $offset Offset. * @return bool */ #[\ReturnTypeWillChange] public function offsetExists( $offset ) { if ( in_array( $offset, array( 'tax_amount', 'shipping_tax_amount' ), true ) ) { return true; } return parent::offsetExists( $offset ); } }