Author Topic: Is Manufacturer inherited in child products?  (Read 627 times)

EvanGR

  • Jr. Member
  • **
  • Posts: 298
Is Manufacturer inherited in child products?
« on: October 25, 2019, 14:13:43 pm »
My child products (batch created via a script), do not seem to inherit the Manufacturer field set in the Parent (other properties like images, descriptions etc, work as expected).
Is it supposed to work this way, or have I done something wrong?

Thanks

Jörgen

  • Global Moderator
  • Sr. Member
  • *
  • Posts: 2530
    • Kreativ Fotografi
  • VirtueMart Version: 3.4.x
Re: Is Manufacturer inherited in child products?
« Reply #1 on: October 25, 2019, 15:01:15 pm »
It should inherit the manufacturer field in almost the same way. But this is not visible in the product editing view, but it should show in the details page in FE.

Jörgen @ Kreativ Fotografi
Joomla 3.9.8
Virtuemart 3.4.x
Olympiantheme Hera (customized)

EvanGR

  • Jr. Member
  • **
  • Posts: 298
Re: Is Manufacturer inherited in child products?
« Reply #2 on: October 25, 2019, 16:10:46 pm »
Unfortunately, manufacturer doesn't seem to be inherited here... (see attached image for back-end, also similar in the front-end)

Other fields, such as price, are inherited properly.

Virtuemart 3.6.3 10177

Jörgen

  • Global Moderator
  • Sr. Member
  • *
  • Posts: 2530
    • Kreativ Fotografi
  • VirtueMart Version: 3.4.x
Re: Is Manufacturer inherited in child products?
« Reply #3 on: October 25, 2019, 16:52:55 pm »
Quote
But this is not visible in the product editing view, but it should show in the details page in FE.
Have You checked the FE ?

Jörgen @ Kreativ Fotografi
Joomla 3.9.8
Virtuemart 3.4.x
Olympiantheme Hera (customized)

EvanGR

  • Jr. Member
  • **
  • Posts: 298
Re: Is Manufacturer inherited in child products?
« Reply #4 on: December 23, 2019, 15:03:15 pm »
After some tweaking, I got it to work, at least partially...

Child products DO show the (inherited) manufacturer in the frontend.

However, when I click to go to the manufacturer page, it does not show any of those products.

In other words, the child products which inherited the Manufacturer from their parent, are not listed in the Manufacturer page.


Jörgen

  • Global Moderator
  • Sr. Member
  • *
  • Posts: 2530
    • Kreativ Fotografi
  • VirtueMart Version: 3.4.x
Re: Is Manufacturer inherited in child products?
« Reply #5 on: December 24, 2019, 09:59:37 am »
I think You have a setting for also showing child products in search, but of course this also reflects how search is shown in other places. You could try this in configuration.

Jörgen @ Kreativ Fotografi
Joomla 3.9.8
Virtuemart 3.4.x
Olympiantheme Hera (customized)

Studio 42

  • Contributing Developer
  • Sr. Member
  • *
  • Posts: 4179
  • Joomla & Virtuemart developper
    • Studio 42 - Virtuemart & Joomla extentions
  • VirtueMart Version: 2.6 & 3
Re: Is Manufacturer inherited in child products?
« Reply #6 on: December 24, 2019, 10:00:04 am »
The logic is same as categories.
You can get the parent products category and manufacturer; but this is only an information.
If you search by category you dont see the childs products too.

EvanGR

  • Jr. Member
  • **
  • Posts: 298
Re: Is Manufacturer inherited in child products?
« Reply #7 on: December 24, 2019, 10:45:12 am »
This sounds like a bad logic for child products. At least the way I use them...

A parent product is just a 'template' for the child products. The parent is unpublished, only the child products exist for the user.
Therefore this hierarchy is only for convenience, not for organizational purposes.

Studio 42

  • Contributing Developer
  • Sr. Member
  • *
  • Posts: 4179
  • Joomla & Virtuemart developper
    • Studio 42 - Virtuemart & Joomla extentions
  • VirtueMart Version: 2.6 & 3
Re: Is Manufacturer inherited in child products?
« Reply #8 on: December 24, 2019, 10:50:58 am »
I know that in some case it's not the best solution, but now suppose you have 4 levels of children, imagine the query to get the manufacturer for search ?
If you really need it, then add the manufacturer in child.

EvanGR

  • Jr. Member
  • **
  • Posts: 298
Re: Is Manufacturer inherited in child products?
« Reply #9 on: December 24, 2019, 11:00:22 am »
Correct... The performance hit would be significant.
But (I would assume that) anything beyond a 2-level hierarchy is an uncommon scenario in real world?

A great way to work with this is to inherit manufacturer (and other missing fields) from the direct parent only.
That should be a good compromise between real world usage and performance.