jaypreet
Forum Replies Created
-
Forum: Plugins
In reply to: [WooCommerce] Preventing author from buying the products he has postedplease provide support.
Forum: Plugins
In reply to: [PDF Invoices & Packing Slips for WooCommerce] Support for WC Vendors ProHello,
Where to ass below code in which file and line. I am weak in coding and need guidance. I am using pro, and free version of your plugin.
Thanks
add_filter(‘wcv_orders_add_new_row’, function($new_row){
if ( !class_exists( ‘WooCommerce_PDF_Invoices’ ) ) {
return false;
}
$order_id = $new_row->order_number;
$order = new WC_Order ( $order_id );$vendor_pdf_actions = array(
‘invoice’ => array (
‘class’ => ‘button tips wpo_wcpdf invoice’,
‘url’ => wp_nonce_url( admin_url( ‘admin-ajax.php?action=generate_wpo_wcpdf&template_type=invoice&order_ids=’ . $order->id ), ‘generate_wpo_wcpdf’ ),
‘label’ => sprintf( ‘‘, WooCommerce_PDF_Invoices::$plugin_url . ‘images/invoice.png’),
‘target’ => ‘_blank’
),
‘packing-slip’ => array (
‘class’ => ‘button tips wpo_wcpdf packing-slip’,
‘url’ => wp_nonce_url( admin_url( ‘admin-ajax.php?action=generate_wpo_wcpdf&template_type=packing-slip&order_ids=’ . $order->id ), ‘generate_wpo_wcpdf’ ),
‘label’ => sprintf( ‘‘, WooCommerce_PDF_Invoices::$plugin_url . ‘images/packing-slip.png’),
‘target’ => ‘_blank’
),
);$new_row->row_actions = array_merge($new_row->row_actions, $vendor_pdf_actions);
return $new_row;
}, 10, 1);Hello Flash UK,
I am weak in coding and cannot do anything without guidance. Please tell me where to enter this code which file and line.
Also I have WC pro and do i need to have Woocommerce pdf invoices packaginf free version or premium version .
Thanks for your guidance in advance.
thanks