The SKU is missing when PayPal payment is used. The resulting order only has the first item in it.
The SKU appears all throughout the checkout process until information is sent to PayPal. Then the SKU information is lost once arriving at PayPal payment webform.
I am using the PayPal API because the old legacy paypal payment methos started to 500 my website.
Any help anyone from the grand virtuemart community to help?
Here is what I did to pass sku to paypal on VM 1.1.8 using paypal api, it involves modification of 2 files:
1)Modify file \administrator\components\com_virtuemart\classes\ps_cart.php
around line 250, function add(), add the following 2 lines:
$product_sku = ps_product::get_field( $product_id, 'product_sku');
$_SESSION['cart'][$k]["product_sku"] = $product_sku;
2)Modify file \administrator\components\com_virtuemart\classes\payment\ps_paypal_api.php
around line 1430, function getCartnvpstr(), add
$ret_str.="&L_NUMBER".$i."=".$cart[$i]["product_sku"];
It will pass sku to paypal NVP variable L_NUMBERn, Hope that helps.