VirtueMart Forum

VirtueMart 2 + 3 + 4 => Virtuemart Development and bug reports => Topic started by: serapol on April 24, 2012, 14:15:06 PM

Title: BUG. Not Added new shipto address in Virtuemart 2.0.6 (fixed)
Post by: serapol on April 24, 2012, 14:15:06 PM
I noticed that after updating to 2.0.6 and Virtuemart make changes to the template no longer add additional shipping addresses.

The problem occurred in the edit_address.php catch pattern
<? php if (! empty ($ this-> virtuemart_userinfo_id)) {
echo '<input type="hidden" name="shipto_virtuemart_userinfo_id" value="'.(int)$this-> virtuemart_userinfo_id.' "/> ';
}
echo JHTML :: _ ('form.token');
?>


If the parameter $ new = 1 virtuemart_userinfo_id variable is set to 0. Since "! Empty ()" responds to this as an empty string is respectively in the model user.php not be carrying out the condition if (isset (shipto_virtuemart_userinfo_id)) and there are no records in the database.

Solving problems delete an additional condition in the template file, or to correct model user.php on line 865
if (isset ($ data ['shipto_virtuemart_userinfo_id'])) {
changed to:
if ($ data ['address_type'] == 'ST' | | isset ($ data ['shipto_virtuemart_userinfo_id'])) {

Please correct this in the next version, and I apologize for bad English

P.S. From the administrative part of the site as an additional shipping address is not added. On the solution of this problem, I have not understood
Title: Re: BUG. Not Added new shipto address in Virtuemart 2.0.6 (fixed)
Post by: Milbo on April 25, 2012, 00:03:21 AM
I added your idea to the model and a fix to the layout, thx.
Title: Re: BUG. Not Added new shipto address in Virtuemart 2.0.6 (fixed)
Post by: woop on June 28, 2012, 12:25:15 PM
THANK YOU SO MUCH!! I just was struggling with this problem of being unable to save new shipping addresses :-)

But i´m still facing the unposibility of selecting my desired shipping address between the shipping address I have already saved.
Do you know any solution??

[attachment cleanup by admin]
Title: Re: BUG. Not Added new shipto address in Virtuemart 2.0.6 (fixed)
Post by: serapol on July 03, 2012, 09:53:36 AM
This problem is a template, this checkbox is out of form. That is, data is not transferred to the script. The form actually starts after the pricelist. I solved this problem by the transfer of contact information and shipping address down.

Like this


[attachment cleanup by admin]
Title: Re: BUG. Not Added new shipto address in Virtuemart 2.0.6 (fixed)
Post by: woop on July 03, 2012, 10:05:09 AM
Hi Serapol,

You are right it´s an issue of template. I´ve solved it just by changing the text of the button of "save" for "change delivery address" so it´s more clear for the user what to do if he wants to change between his delivery addresses.
Definetly I think that the option of picking the delivery address in radio fields from VM1 was a more logic solution from the user´s point of view.
Title: Re: BUG. Not Added new shipto address in Virtuemart 2.0.6 (fixed)
Post by: ivus on July 17, 2012, 17:19:18 PM
Could someone please test this on their install.

I have the latest Joomla 2.5.6 and VM 2.0.8c, and I can see the above code changes in place within my model. However, I am now getting this rather odd bug and am not sure if it's just me?

I do have a few template overrides in place, but have disabled them during my fault finding expedition and found the bug to possibly exist in the core code. I have not hacked the core... anyway, please try to replicate this bug:


If anyone has experienced the same problem and has a solution, I'd muchly appreciate it.

Ta

Title: Re: BUG. Not Added new shipto address in Virtuemart 2.0.6 (fixed)
Post by: resorter on December 04, 2014, 13:33:03 PM
Quote from: ivus on July 17, 2012, 17:19:18 PM
Could someone please test this on their install.

I have the latest Joomla 2.5.6 and VM 2.0.8c, and I can see the above code changes in place within my model. However, I am now getting this rather odd bug and am not sure if it's just me?

I do have a few template overrides in place, but have disabled them during my fault finding expedition and found the bug to possibly exist in the core code. I have not hacked the core... anyway, please try to replicate this bug:


  • log is as a user
  • in your SHOPPER INFORMATION TAB, create a new shipping address (NEW) - what you should see is a page with entirely blank fields.
  • fill in the form and click on save - you should then get redirected back to the previous screen and the new address item should appear
  • THE BUGGY PART - try and create another new shipping address -> what I'm getting is a page prefilled with my previous form? where I was expect another blank form page?

If anyone has experienced the same problem and has a solution, I'd muchly appreciate it.

Ta


Hi, i have got the same bug and also even i delete additional address and return to ckeckout i see delted address again
Thanks
Title: Re: BUG. Not Added new shipto address in Virtuemart 2.0.6 (fixed)
Post by: jenkinhill on December 04, 2014, 15:40:52 PM
And you are using those very old VM versions as well? This thread is over 2 years old.