VirtueMart Forum

VirtueMart 2 + 3 + 4 => General Questions => Topic started by: marcodelpercio on March 19, 2012, 20:45:39 PM

Title: [FIXED MYSELF YET VERY BUGGY BEHAVIOUR]Userfields are not being stored
Post by: marcodelpercio on March 19, 2012, 20:45:39 PM
What's wrong with this??? I thought it was a very basic feature! I just created a new custom userfield of type text.
It's published
It's not mandatory
It has to show in registration form
It has to show in account maintainance form
It's not required in shipping address form.

I gave it a name "partita_iva" and a label/title "Partita IVA"

Well the user field is actually showing both in backend and frontend as cofigured and if I enter a value during account registration, I can clearly see that value in the review emails sent to the shop administrator/customer so everything seems fine but then... the value I have entered is NOT stored, it really has not been stored, if I check the #__virtuemart_userfield_values table in the database it is completely empty, it doesn't matter if registration seems ok and also if I try to save a value from backend it says saved but then nothing it really stored!!

What's wrong? I am on Joomla 2.5.3 and Virtuemart 2.0.2 stable
Title: [SOLVED] Userfields are not being stored
Post by: marcodelpercio on March 20, 2012, 11:15:57 AM
I believe this thing has a seriously buggy behaviour somewhere. I found the problem by myself installing a parallel new empty Virtuemart 2.0.2 stable. When I created the userfield "partita_iva" then the database table #__virtuemart_userinfos got automatically added a new extra column named "partita_iva", on the other hand in my live Virtuemart installation (which is always 2.0.2 stable) such extra column was NOT created automatically!
And what's worst is that Virtuemart wasn't triggering any error message even with a missing column. So at the beginning I thought everything was ok. I had to manually add the required column on the #__virtuemart_userinfos table to make it work as expected...but I was forced to restore missing data directly from customers since actually those data were not stored.... that's so bad for a "stable" version :-(

How can the custom "partita_iva" field figure out correctly in the Shopper/User fields view with all its activation flags and then not be added as column in the userinfos table?
And why the hell is Virtuemart not triggering any error for the missing column when it should be storing an extra value in that column??

I'm afraid something is not coded properly somewhere.
Title: Re: [FIXED MYSELF YET VERY BUGGY BEHAVIOUR]Userfields are not being stored
Post by: jack19 on March 21, 2012, 17:15:11 PM
Stesso problema che ho segnalato sul forum italiano. [http://forum.vmitalia.net/index.php?topic=9471.0 (http://forum.vmitalia.net/index.php?topic=9471.0)
Title: Re: [FIXED MYSELF YET VERY BUGGY BEHAVIOUR]Userfields are not being stored
Post by: ivus on July 18, 2012, 06:40:09 AM
Quote from: marcodelpercio on March 20, 2012, 11:15:57 AM
I had to manually add the required column on the #__virtuemart_userinfos table to make it work as expected...

Hi marcodelpercio,

perhaps you could tell me what you did to the table as I'm having the exact same issues.
Title: Re: [FIXED MYSELF YET VERY BUGGY BEHAVIOUR]Userfields are not being stored
Post by: ivus on July 18, 2012, 07:21:03 AM
for the life of me I can't find where these fields get stored to the DB???

I even took the step of deleting the DB table and waiting for something to break in the saving process.... but guess what? nothing happened? VM still plodded along as if nothing was wrong.

I think this is a massive bug. VM team could you look into this please.