Hello. Sorry about late reply. Yes, it's similar to custom dropbox plugin. Until this will be presented in newest version, you can add support by this code:
Its in administrator/components/com_vminvoice/helpers/invoicehtml.php around line 855
(I included whole "attributes" part, you can replace it from 855 - 904 (where case 'price': starts)
case 'attributes':
if ($this->params->get('show_attributes')==1){
if (($decoded = json_decode($item->product_attribute, true))==null) //string attributes (VM1)
$replacement = preg_replace('#(\s*<\s*p\s[^>]*>\s*|\s*<\s*\/\s*p\s*>\s*|<\s*br\s*\/?\s*>\s*$|^\s*<\s*br\s*\/?\s*>)#i','',$item->product_attribute); //remove all <p>s and enclosing <br>s
else{ //JSON atrributes (VM2)
$attributes = array();
$db = JFactory::getDBO();
foreach ($decoded as $key => $val){
if (is_array($val) OR is_object($val)){
foreach ((array)$val as $key2 => $val2){
if (is_array($val2) OR is_object($val2)){ //another nested object :)
foreach ((array)$val2 as $key3 => $val3){
$title = false;
//support for VMCustom - textinput plugin
//{"48":{"textinput":{"comment":"10"}}}
if (COM_VMINVOICE_ISVM2){
$db->setQuery('SELECT C.custom_title FROM #__virtuemart_product_customfields AS CF
JOIN #__virtuemart_customs AS C ON (CF.virtuemart_custom_id = C.virtuemart_custom_id)
WHERE CF.custom_value = '.$db->Quote($key2).' AND CF.virtuemart_customfield_id = '.(int)$key);
$title = $db->loadResult();
}
//support for Custom Field Dropbox Plugin (or more) - replace title from custom field title
if (!$title AND COM_VMINVOICE_ISVM2 AND !is_numeric($key3)){
$db = JFactory::getDBO();
$db->setQuery('SELECT custom_param FROM #__virtuemart_product_customfields WHERE custom_value = '.$db->Quote($key2).' AND virtuemart_customfield_id = '.(int)$key);
if (($param = $db->loadResult()) AND ($params = json_decode($param, true)))
foreach ($params as $key4 => $val4)
if (substr($key4, -5)=='_name' AND is_string($val4))
$title = $val4;
}
if (!$title)
$title = $key3;
if ($title AND !empty($val3))
$attributes[] = $this->_($title, 'com_virtuemart').': '.$this->_($val3, 'com_virtuemart');
}
}
elseif (!empty($key2) AND !empty($val2)){
$title = false;
if (COM_VMINVOICE_ISVM2){ //try to find custom field title
$db->setQuery('SELECT C.custom_title FROM #__virtuemart_product_customfields AS CF
JOIN #__virtuemart_customsAS C ON (CF.virtuemart_custom_id = C.virtuemart_custom_id)
WHERE CF.custom_value = '.$db->Quote($key2).' AND CF.virtuemart_customfield_id = '.(int)$key);
$title = $db->loadResult();
}
$attributes[] = $this->_($title ? $title : $key2, 'com_virtuemart').': '.$this->_($val2, 'com_virtuemart');
}
}
}
else{
if (preg_match('#^\s*<\s*span.*>(.*)<\s*\\/\s*span\s*>\s*<\s*span.*>(.*)<\s*\\/\s*span\s*>\s*$#iU', (string)$val, $matches)) //two spans
//if (preg_match('#^\s*<\s*span\s+class\s*=\s*\\"costumTitle\\"\s*>(.*)<\s*\\?\s*/\s*span\s*>\s*<\s*span\s+class\s*=\s*\\"costumValue\\"\s*>(.*)<\s*\\?\s*/\s*span\s*>\s*$#iU', $val, $matches))
$attributes[] = $matches[1].': '.$matches[2];
elseif (($val = trim((string)$val)) AND !preg_match('#^\d+$#',$val)) //http://www.artio.net/support-forums/vm-invoice/customer-support/custom-plugin-attribute-title ?
$attributes[] = $this->_((string)$val, 'com_virtuemart'); //only when not empty and not integer
}
}
$replacement = implode("<br>\r\n", $attributes);
}
}
else
$replacement = '-remove-';
break;