News:

Support the VirtueMart project and become a member

Main Menu

User without country

Started by peli, October 24, 2008, 19:22:17 PM

Previous topic - Next topic

peli

Description:
When the field for country is unpublish no payment info will be displayed at the first step in the checkout.

Turning on debugging showes querys like this:
SELECT *
  FROM jos_vm_user_info i
  INNER JOIN jos_vm_country c
  ON (i.country=c.country_3_code OR i.country=c.country_2_code)
  LEFT JOIN jos_vm_state s
  ON (i.state=s.state_2_code
  AND s.country_id=c.country_id)
  WHERE user_id='67'
  AND address_type='BT'

Query will return an empty result when country are NULL

VirtueMart Version:
1.1.2

Joomla/Mambo Version:
1.5.7

Steps to replicate:
Unpublish the country field from user fields.
Create a new user.
Go to checkout with the new user.

Proposed fix(es):
Change inner join to left join.

Bugtracker task #:
Enter the bugtracker task #/url when submitted.

System info:
Debian 2.6.16.5
MySQL 5.0.32-Debian_7etch6-log
PHP 5.2.0-8+etch11
Apache/2.2.3 (Debian) PHP/5.2.0-8+etch11 mod_ssl/2.2.3 OpenSSL/0.9.8c