...
|
...
|
@@ -224,7 +224,7 @@ |
|
|
this.province.showList = this.city.showList = this.area.showList = false;
|
|
|
this.province.titleActive = this.city.titleActive = this.street.titleActive = false;
|
|
|
break;
|
|
|
case 9: // 一定要返回结果了
|
|
|
case 9:
|
|
|
this.street.id = id;
|
|
|
if (caption.length > 5) {
|
|
|
this.street.title = caption.substring(0, 2) + '...' + caption.substring(caption.length - 2);
|
...
|
...
|
@@ -253,6 +253,8 @@ |
|
|
$.get('/home/getaddress.json', {
|
|
|
id: id
|
|
|
}, resultData => {
|
|
|
|
|
|
/* 结果返回 */
|
|
|
if (resultData.length < 1) {
|
|
|
areaCode.val(id);
|
|
|
area.val(this.province.title + ' '
|
...
|
...
|
@@ -286,12 +288,15 @@ |
|
|
|
|
|
/* 关闭地址选择组件 */
|
|
|
closeAddBox() {
|
|
|
this.show = false;
|
|
|
if (areaCode.val().length > 5) {
|
|
|
return;
|
|
|
}
|
|
|
areaCode.val(this.street.id || this.area.id || this.city.id || this.province.id);
|
|
|
area.val(this.province.title + ' '
|
|
|
+ this.city.title + ' '
|
|
|
+ this.area.title + ' '
|
|
|
+ this.street.title);
|
|
|
this.show = false;
|
|
|
},
|
|
|
|
|
|
/* 点击地址标题时的处理 */
|
...
|
...
|
|