pushuo 2022-08-12 16:00:57 +08:00
parent 59eb050d11
commit 2bb83153a9
2 changed files with 11 additions and 11 deletions

View File

@ -239,16 +239,16 @@
},
deleteAddress(id, index) {
const self = this;
$.ajax({
url: `/admin/customers/{{ $customer['id'] }}/addresses/${id}`,
type: 'delete',
success: function(res) {
self.$message.success(res.message);
self.addresses.splice(index, 1)
}
})
this.$confirm('确定要删除地址吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
$http.delete(`customers/{{ $customer['id'] }}/addresses/${id}`).then((res) => {
this.$message.success(res.message);
this.addresses.splice(index, 1)
})
}).catch(()=>{})
},
addressFormSubmit(form) {

View File

@ -166,7 +166,7 @@
this.editIndex = null;
Object.keys(this.form).forEach(key => this.form[key] = '')
this.form.country_id = @json((int)setting('base.country_id'))
this.form.country_id = @json((int)system_setting('base.country_id'))
},
countryChange(e) {