• Resolved hamudi

    (@hamudi)


    Hello dear Plugin-developer,

    Thank you very much for your useful plugin!

    I have tried to add the “short cart description” to the invoices but unfortunately I have only found the way you described to add the product short description:
    https://docs.wpovernight.com/woocommerce-pdf-invoices-packing-slips/displaying-product-description/

    There is an additional field in the product attributes which is shown in the cart of the customer called “short cart description”. Do you have an idea how to add this instead of the normal short description?

    Thank you very much for your answer in advance!

Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Contributor alexmigf

    (@alexmigf)

    Hello @hamudi

    Can you show me where, inside WooCommerce, you fill that ‘short cart description’ and also where is shows in the cart?

    Let me know.

    Thread Starter hamudi

    (@hamudi)

    Hi @alexmigf
    Thank you very much for your quick reply.

    The “short cart description” is within the creation and edit of a product in woocommerce.

    I have attached you a screenshot of the field. Can you work with this information?

    Here is the link:
    https://ibb.co/ydb9Y4R

    Thank you for your reply in advance!

    Plugin Contributor Ewout

    (@pomegranate)

    This is not a standard WooCommerce field for products. Do you by any chance use a plugin like Germanized or German Market?

    Thread Starter hamudi

    (@hamudi)

    Hi @pomegranate

    Thank you for your reply. Yes, I am using Germanized.

    Could you help me with using this description as short description within your PDF-invoices? It would be really helpful, since that is important.

    Kind regards

    Plugin Contributor kluver

    (@kluver)

    Hi @hamudi,

    Could you try the following code snippet:

    add_action( 'wpo_wcpdf_after_item_meta', 'wpo_wcpdf_show_product_description', 10, 3 );
    function wpo_wcpdf_show_product_description ( $template_type, $item, $order ) {
    	if ( !empty( $item['product'] ) && !empty( $item['product']->get_meta( '_mini_desc' ) ) ) {
    		printf('<div class="cart-description">%s</div>', $item['product']->get_meta( '_mini_desc' ) );
    	}
    }
    Thread Starter hamudi

    (@hamudi)

    You are amazing! This code worked… thank you very much for your appreciated time!!

    Plugin Contributor Ewout

    (@pomegranate)

    Very glad to hear that! If you can spare a minute, we always appreciate a plugin review here on ww.wp.xz.cn 🙂
    https://ww.wp.xz.cn/support/plugin/woocommerce-pdf-invoices-packing-slips/reviews/#new-post

    Thanks in advance and all the best with your store!

    Hi there,

    I need to do the exact same thing where I would like to take the content of Short Product Description and add it after the product name.

    I am very new to this so how exactly would I do this? Which file do I modify here ? The functions.php related to the Theme that I am using or body.php under uploads/woocommerce-pdf-invoices/templates/invoice/simple/minimal?

    Thank you in advance for your help! Love this plugin!

Viewing 8 replies - 1 through 8 (of 8 total)

The topic ‘Adding cart description into the invoice’ is closed to new replies.