summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoramoyaux <arm@odoo.com>2017-02-17 12:15:59 +0100
committerNicolas Lempereur <nle@odoo.com>2017-03-03 15:38:11 +0100
commitc0dffa343345ef49df2726adbd32bfbab2dd31a3 (patch)
tree6f33b0059ae0c4105aee9b81b92872b1537fd6d2
parent3513151e572d765f5749ad579696f3e2885ff8a4 (diff)
[FIX] Website_Sale: State / Province doesn't appear when needed.
Use case when it happens: * Go to billing for a product in website * Modify or create an address * Select a country without state * State field disappear * Select a country with states * State field doesn't appear -> Bug If you confirm, it raises an error asking you to fill the state field and this one reappear. The bug come from this forward port 1ef4061e68 This fix removes :visible from the jquery selector on state tag selector since the logic is different in version 10. opw-707402
-rw-r--r--addons/website_sale/static/src/js/website_sale.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/addons/website_sale/static/src/js/website_sale.js b/addons/website_sale/static/src/js/website_sale.js
index 11e26de4f6b..51029495c36 100644
--- a/addons/website_sale/static/src/js/website_sale.js
+++ b/addons/website_sale/static/src/js/website_sale.js
@@ -395,7 +395,7 @@ odoo.define('website_sale.website_sale', function (require) {
//$("input[name='phone']").attr('placeholder', data.phone_code !== 0 ? '+'+ data.phone_code : '');
// populate states and display
- var selectStates = $("select[name='state_id']:visible");
+ var selectStates = $("select[name='state_id']");
// dont reload state at first loading (done in qweb)
if (selectStates.data('init')===0 || selectStates.find('option').length===1) {
if (data.states.length) {