- 添加获取默认地址

This commit is contained in:
sin
2019-04-10 22:27:03 +08:00
parent 90416d5431
commit efe80aeeec
3 changed files with 59 additions and 42 deletions

View File

@@ -57,6 +57,7 @@
<script>
import {createOrder} from '../../api/order';
import {GetDefaultAddress} from '../../api/user';
import orderStore from '../../store/order'
import eventBus from '../eventBus';
@@ -132,8 +133,13 @@
}
this.addressData = this.$store.state.addressData;
},
activated() {
created() {
GetDefaultAddress().then((result) => {
if (result) {
this.type = 'add1'
this.addressData = result
}
})
},
store: orderStore,
};