addressDialog.vue 766 Bytes
<template>
  <el-dialog v-model="showDialog" align-center destroy-on-close title="选择地址" width="640px">
    <div class="height">
      <addressView ref="addressViewRef" :type="type" select="1" @handel-select="handelSelect" />
    </div>
  </el-dialog>
</template>
<script setup>
import { ref } from 'vue'
import addressView from '@/views/system/user/profile/addressView.vue'


const emit = defineEmits(['handelSelect'])
const type = ref('0')
const showDialog = ref(false)

function open(row) {
  showDialog.value = true
  type.value = row ?? '0'
}


function handelSelect(row) {
  emit('handelSelect', row)
  showDialog.value = false
}

defineExpose({
  open
})
</script>


<style lang="scss" scoped>
.height {
  height: 520px;
  overflow-y: auto;
}
</style>