Authored by 郭成尧

'address-select-bug'

... ... @@ -189,12 +189,12 @@ function bindAddressListEvent(html) {
}
// 读取省市区列表缓存
if (window.localStorage && window.localStorage.getItem) {
chinaAddressList = window.localStorage.getItem('chinaAddressList');
}
if (chinaAddressList) {
bindAddressListEvent(chinaAddressList);
} else {
// if (window.localStorage && window.localStorage.getItem) {
// chinaAddressList = window.localStorage.getItem('chinaAddressList');
// }
// if (chinaAddressList) {
// bindAddressListEvent(chinaAddressList);
// } else {
// 省市区列表异步加载
$.ajax({
... ... @@ -203,10 +203,10 @@ if (chinaAddressList) {
timeout: 60000
}).then(function(html) {
bindAddressListEvent(html);
if (window.localStorage && window.localStorage.setItem) {
window.localStorage.setItem('chinaAddressList', html);
}
// if (window.localStorage && window.localStorage.setItem) {
// window.localStorage.setItem('chinaAddressList', html);
// }
}).fail(function() {
tip.show('获取省市区列表失败');
});
}
// }
... ...
... ... @@ -11,7 +11,7 @@
<ul class="address-list">
{{# sub}}
<li class="address-last" data-id="{{code}}">
<span class="caption">{{caption}}</span>
<span class="caption" data-id="{{code}}">{{caption}}</span>
</li>
{{/ sub}}
</ul>
... ...