<template>
  <dee-add-model-case-dialog
    :show-sub-type="false"
    :width="width"
    :title="title"
    :show-dialog="dialogShow"
    :need-pre-view="true"
    :default-data="defaultData"
    @close="$emit('close')"
    @selection="selection"
  />
</template>

<script>
export default {
  name: 'ChangeObjectAdd',
  props: {
    width: {
      type: String,
      default: () => '70%'
    },
    title: {
      type: String,
      default: () => ''
    },
    dialogShow: {
      type: Boolean,
      default: false
    }
  },
  data() {
    return {
      defaultData: {
        latest: 'LATEST',
        modelName: 'DxDocument'
      }
    }
  },
  computed: {},
  watch: {},
  // 生命周期 - 创建完成(访问当前this实例)
  created() {},
  // 生命周期 - 挂载完成(访问DOM元素)
  mounted() {},
  methods: {
    selection(rows) {
      this.$emit('submit', { type: 'ADD', rows: rows })
    }
  }
}
</script>
<style lang="scss">
/* @import url(); 引入css类 */

</style>