fix(AddressEdit): check addressDetail only when showDetail is true (#5803)

This commit is contained in:
rex
2020-03-11 16:42:07 +08:00
committed by GitHub
parent e89baa12ae
commit 3ff8eee270

View File

@@ -168,7 +168,15 @@ export default createComponent({
},
onSave() {
const items = ['name', 'tel', 'areaCode', 'addressDetail'];
const items = ['name', 'tel'];
if (this.showArea) {
items.push('areaCode');
}
if (this.showDetail) {
items.push('addressDetail');
}
if (this.showPostal) {
items.push('postalCode');