VirtueMart Forum

VirtueMart 2 + 3 + 4 => Virtuemart Development and bug reports => Development & Testing => Topic started by: SnakeFFM on November 01, 2015, 22:00:40 PM

Title: From 3.0.9 to 3.0.10 Custom Fields dont show up
Post by: SnakeFFM on November 01, 2015, 22:00:40 PM
Hi!

just tried 3.0.10 and everything was working pretty fine except of the 'custom fields" function.

I use custom fields especially to show typical attributes above products, for instance '1. edition', but I then dont use any values or something. For instance: http://www.tradingcards4you.de/de/yugioh/premium-gold-2/Absoluter%20K%C3%B6nig%20D%C3%BCsen-Jack-detail.html (page is in German, therfore 1. edition is equal to '1. Auflage')

In custom field options I've typed in the following parameters: "string" - Show title? 'yes' public? 'yes' layout position 'ontop'

Once I ve updated to 3.0.10 all custom fields were wiped away. I've noticed that once I've stated something in the value field of a certain product, then the certain custom field showed up again.

I now changed back to 3.0.9 and the custom fields are there again - Did i miss something in regarding my custom field options which needs to be changed when using 3.0.10?

I hope this feedback is kind of helpful for you guys.

Best,
Snake
Title: Re: From 3.0.9 to 3.0.10 Custom Fields dont show up
Post by: Milbo on November 01, 2015, 23:05:52 PM
Please use our latest vm3.0.11.2
http://dev.virtuemart.net/attachments/download/975/com_virtuemart.3.0.11.2_extract_first.zip
Title: Re: From 3.0.9 to 3.0.10 Custom Fields dont show up
Post by: SnakeFFM on November 02, 2015, 14:28:21 PM
Hi Milbo,

is this a known issue?

I ll have a try and let you know the results.

Thanks for your swift response.
Title: Re: From 3.0.9 to 3.0.10 Custom Fields dont show up
Post by: Milbo on November 02, 2015, 18:14:51 PM
Directly try http://dev.virtuemart.net/attachments/download/976/com_virtuemart.3.0.11.4_extract_first.zip
Title: Re: From 3.0.9 to 3.0.10 Custom Fields dont show up
Post by: SnakeFFM on November 02, 2015, 19:36:07 PM
Just installed it locally and installed it, result now:

- Custom fields still dont show up and additional error in cart: 'Programmer used an unknown userfield agreed' which only shows up when I use the virtueplanet plugin 'onepage checkout'
Title: Re: From 3.0.9 to 3.0.10 Custom Fields dont show up
Post by: Milbo on November 02, 2015, 20:41:04 PM
then you should create the userfield agreed. Sounds like it is missing.
Title: Re: From 3.0.9 to 3.0.10 Custom Fields dont show up
Post by: SnakeFFM on November 02, 2015, 21:44:15 PM
Custom Field

Well, regarding custom fields it's still the same. They are only shown when I add any value. For instance I have the following custom field:

- String
- Title: 'Gold Secret Rare'

If I type in as value '1' then you see it. If the field is empty then it's gone again. In 3.0.9 it was not necessary to enter any value to see the customfields.

Checkout

I am using the plugin as I am not so much into the code of virtuemart (quick solution). Was also working without any alerts on 3.0.9 - Normal checkout works perfectly. I know you guys dont support 3rd party extensions, I ve just noticed that there is also something different than before.
Title: Re: From 3.0.9 to 3.0.10 Custom Fields dont show up
Post by: Milbo on November 02, 2015, 23:19:59 PM
It is only a small thing, i am sure there will be an update by the 3rd party.

"If I type in as value '1' then you see it. If the field is empty then it's gone again. In 3.0.9 it was not necessary to enter any value to see the customfields."

in the category browse view?
Yes we removed showing of the title, when the value is empty, usually it is not wanted. Hmmm, I fear I have to create an option for, but you could also just override the function. It is overrideable!
Title: Re: From 3.0.9 to 3.0.10 Custom Fields dont show up
Post by: SnakeFFM on November 03, 2015, 00:34:55 AM
Havent seen any post in the forum yet, maybe I ll tell the 3rd party guys.

Category Browse view is the view that appear after you ve clicked on a product right? http://www.tradingcards4you.de/de/yugioh/premium-gold-2/ger%C3%BCmpelriese-detail.html

In my "live" version I have still 3.0.9 running thats why you can still see the product fields.

Well, I wouldnt mind to do an override (just a normal override in the html folder of the template, right?). Would you mind to tell me how the override would have to look like?

Have a good night.
Title: Re: From 3.0.9 to 3.0.10 Custom Fields dont show up
Post by: SnakeFFM on November 03, 2015, 20:02:01 PM
well, the reason for the error in the cart was related to the shopper field 'agreed' not published...

and for the custom fields I made an override in custofields as stated (sublayouts > customfields.php):

/*|| empty($field->display)*/

foreach ($product->customfieldsSorted[$position] as $field) {
if ( $field->is_hidden /*|| empty($field->display)*/) continue; //OSP http://forum.virtuemart.net/index.php?topic=99320.0
?><div class="product-field product-field-type-<?php echo $field->field_type ?>">
<?php if (!$customTitle and $field->custom_title != $custom_title and $field->show_title) { ?>
<span class="product-fields-title-wrapper"><span class="product-fields-title"><strong><?php echo vmText::($field->custom_title?></strong></span>
<?php if ($field->custom_tip) {
echo JHtml::tooltip (vmText::_($field->custom_tip), vmText::($field->custom_title), 'tooltip.png');
?>
</span>
<?php }
if (!empty($field->display)){
?>
<div class="product-field-display"><?php echo $field->display ?></div><?php
}
if (!empty($field->custom_desc)){
?>
<div class="product-field-desc"><?php echo vmText::_($field->custom_desc?></div> <?php
}
?>

</div>
<?php
$custom_title $field->custom_title;
?>


Title: Re: From 3.0.9 to 3.0.10 Custom Fields dont show up
Post by: Milbo on November 03, 2015, 22:13:15 PM
yeh, you made it yourself, looks good.
Title: Re: From 3.0.9 to 3.0.10 Custom Fields dont show up
Post by: SnakeFFM on November 04, 2015, 09:52:22 AM
I am not sure how other people use custom fields, but I liked your idea to add an option to show the custom field yet it has no value. However, I dont know how much work that would cause for you, but I was quite happy to use the fields tough they had 'no value'.

Thanks for ur support mate.
Title: Re: From 3.0.9 to 3.0.10 Custom Fields dont show up
Post by: jooomlaa on November 17, 2015, 17:22:01 PM
Have installed VM Version 3.0.12 (J!3.4.5). The error is still displayed. :-(
Title: Re: From 3.0.9 to 3.0.10 Custom Fields dont show up
Post by: GJC Web Design on November 17, 2015, 19:26:56 PM
Crystal ball broke... which error?
Title: Re: From 3.0.9 to 3.0.10 Custom Fields dont show up
Post by: jooomlaa on November 18, 2015, 08:09:54 AM
The Cart-Message: "Error: Programmer used an unknown userfield agreed".
The Error exists since i have update vm from 3.0.9 to 3.0.12
Title: Re: From 3.0.9 to 3.0.10 Custom Fields dont show up
Post by: Milbo on November 18, 2015, 15:45:13 PM
Jooomlaa it is not a general error, it is an error in your setup.