Author Topic: bug : unpublished related product  (Read 842 times)

Studio 42

  • Contributing Developer
  • Sr. Member
  • *
  • Posts: 4345
  • Joomla & Virtuemart developper
    • Studio 42 - Virtuemart & Joomla extentions
  • VirtueMart Version: 2.6 & 3
bug : unpublished related product
« on: June 10, 2015, 02:28:54 am »
hi,
When you unpublish a related product, the related customfield is set but $customfield->display is empty because
Code: [Select]
$related = $pModel->getProduct((int)$customfield->customfield_value,TRUE,$customfield->wPrice,TRUE,1);return nothing in customfields model line 1156 in vm 3.0.9.
I think this must be unset when the related product is not published.
changing line 1158
Code: [Select]
if(!$related) {
break;
}
to
Code: [Select]
if(!$related) {
unset($customfields[$k]);
break;
}
work for me.

see attached for bug screenshot
Greets,
Patrick

Milbo

  • Virtuemart Projectleader
  • Administrator
  • Super Hero
  • *
  • Posts: 10070
  • VM3.2 Cached and Optimized
    • VM3 Extensions
  • VirtueMart Version: VirtueMart 3 on joomla 3
Re: bug : unpublished related product
« Reply #1 on: June 11, 2015, 23:27:44 pm »
thx,

fix is now included here http://dev.virtuemart.net/projects/virtuemart/files vm3.0.9.4
I should fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/