This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| add_action( 'init', function() { | |
| $light_product = wc_get_product( 3890 ); | |
| $bulk_product = wc_get_product( 6695 ); | |
| $light_cart_item = new CartItem( array( | |
| 'data' => $light_product, | |
| 'quantity' => 1, | |
| ) ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| add_filter( 'eu_owb_woocommerce_order_item_is_withdrawable', function( $is_withdrawable, $order_item ) { | |
| $product = $order_item->get_product(); | |
| if ( $product ) { | |
| // Decide based on the original product | |
| } | |
| return $is_withdrawable; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| add_filter( 'eu_owb_get_contact_support_email', function() { | |
| return 'test@shop.de'; | |
| } ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| add_filter( 'eu_owb_woocommerce_is_shop_request', '__return_true' ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| add_filter( 'storeabill_mpdf_convert_to_inline_styles', '__return_false' ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| add_filter( 'woocommerce_gzd_product_tax_info', function( $notice ) { | |
| if ( ! empty( $notice ) ) { | |
| $notice = 'inkl. Umsatzsteuer'; | |
| } | |
| return $notice; | |
| }, 10 ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| add_filter( 'storeabill_invoice_get_template', function( $template, $invoice ) { | |
| $template_id = false; | |
| if ( ! empty( $invoice->get_company() ) ) { | |
| $template_id = 320; // Post id of the template to be used | |
| } | |
| if ( $template_id ) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| add_filter( 'woocommerce_gzd_disable_gateways_paid_order_email', function( $gateways ) { | |
| $gateways = array_diff( $gateways, array( 'invoice' ) ); | |
| return $gateways; | |
| } ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| add_action( 'woocommerce_order_status_pending_to_processing_notification', function( $order_id ) { | |
| if ( $order = sab_get_order( $order_id ) ) { | |
| if ( $invoice = $order->get_latest_finalized_invoice() ) { | |
| $invoice->send_to_admin(); | |
| } | |
| } | |
| }, 10 ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| add_filter( 'storeabill_woo_order_email', function( $billing_email, $invoice_order ) { | |
| $wc_order = $invoice_order->get_order(); | |
| return $billing_email; | |
| }, 10, 2 ); |
NewerOlder