Hi,
I don't really know what can be wrong but it has something to do with the code:
\components\com_virtuemart\sublayouts products.php
echo shopFunctionsF::renderVmSubLayout('addtocart',array('product'=>$product,'rowHeights'=>$rowsHeight[$row], 'position' => array('ontop', 'addtocart'))); ?>
Now I have strange situation when in comes to the products listing in the category view - some of them have all the custom fields assigned to them in that view, some don't. .. I really can't figure out why...
What I can say more that using old VM.3.0.8 code
echo shopFunctionsF::renderVmSubLayout('addtocart',array('product'=>$product,'rowHeights'=>$rowsHeight[$row])); ?>
I see no problem with that...
It is the position, the first line has array('ontop', 'addtocart'), so all customfields with pos ontop, addtocart are added.
echo shopFunctionsF::renderVmSubLayout('addtocart',array('product'=>$product,'rowHeights'=>$rowsHeight[$row], 'position' => array('ontop', 'addtocart')));
will only show add to cart/custom fields assigned to the ontop posistion
Quote from: GJC Web Design on October 21, 2015, 14:38:39 PM
echo shopFunctionsF::renderVmSubLayout('addtocart',array('product'=>$product,'rowHeights'=>$rowsHeight[$row], 'position' => array('ontop', 'addtocart')));
will only show add to cart/custom fields assigned to the ontop posistion
Yep, that's obvious but how would you explain the fact that the same custom fields are visible in some of the products, and in some aren't... (layout2.jpg)
Moreover - when we have a lot of those fields the category layout looks terrible....(layout.jpg)
QuoteYep, that's obvious but how would you explain the fact that the same custom fields are visible in some of the products, and some aren't...
no idea... check, check and double check
if some do and some don't then there is a difference..
QuoteMoreover - when we have a lot of those fields the category layout looks terrible....(attachment 2)
well that is what templating is .. if the stock template doesn't suit you, you redesign an over ride
Do u think the stock template has to suit every single users possibility?
I have built many many VM sites but have yet to have a client that required so many customs on a cat layout.. personally I would get rid of them and only have on the details
Who buys a subwoofer just from an over view page?
Quote from: GJC Web Design on October 21, 2015, 14:38:39 PM
echo shopFunctionsF::renderVmSubLayout('addtocart',array('product'=>$product,'rowHeights'=>$rowsHeight[$row], 'position' => array('ontop', 'addtocart')));
will only show add to cart/custom fields assigned to the ontop posistion
array('ontop', 'addtocart')
both, else just use 'ontop', for example
Quote from: GJC Web Design on October 21, 2015, 15:24:58 PM
Do u think the stock template has to suit every single users possibility?
Of course not - it's impossible. I think it shouldn't change proven, goods things above all. If users wanted that kind of solution - it's ok - I'm just one of millions... :) It's different than was - mainly that's why I have reported it, by the way it doesn't look good for me...
Quote from: GJC Web Design on October 21, 2015, 15:24:58 PM
I have built many many VM sites but have yet to have a client that required so many customs on a cat layout.. personally I would get rid of them and only have on the details
I can't get rid of them - they are very useful :) I use them to comparison tables for example...
Quote from: GJC Web Design on October 21, 2015, 15:24:58 PM
no idea... check, check and double check
I'll definitely do that - because there's very strange behaviour.
No matter how strange it sound but it looks that either there's some bug in the code or it's an intentional acting albeit very confusing for me...
For me it looks as follow:
1. When a product has assigned 'addtocart' type of custom fields then also 'ontop' types are appearing in category view.
2. When a product has assigned only 'ontop' type of custom fields they're not showing up in the category view.
3. (very strange) When only one of the products in a particular category has assigned 'addtocart' type of custom fields then all the products visible in the same row as that one are displayed with custom fields what is a denial of the 2 point.
That's the reason why in one category I have products with and without custom fields... I think so..
Can be that way???
In our case the template didnt have other optional positions so the only one that currently works is "addtocart" position.
The rest as in yout case they don't apper.
So just make sure first your template is actually showing positions..
Regards
I thought they should appear both - if I want just 'on top' I remove 'add to cart' and vice versa :
Quote from: Milbo on October 21, 2015, 15:46:34 PM
array('ontop', 'addtocart')
both, else just use 'ontop', for example
For me it works that way:
Quote from: MarioP on October 22, 2015, 15:46:21 PM
1. When a product has assigned 'addtocart' type of custom fields then also 'ontop' types are appearing in category view.
2. When a product has assigned only 'ontop' type of custom fields they're not showing up in the category view.
3. (very strange) When only one of the products in a particular category has assigned 'addtocart' type of custom fields then all the products visible in the same row as that one are displayed with custom fields what is a denial of the 2 point.
That's the reason why in one category I have products with and without custom fields... I think so..