1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
| <template>
| <el-dialog v-dialogDrag
| :title="title"
| :visible.sync="centerDialogVisible"
| :modal="false"
| :close-on-click-modal="false"
| @close='closeDialog'
| center>
| <slot></slot>
| </el-dialog>
| </template>
| <script>
|
| export default {
| name: 'Dialog',
| props: {
| title: {
| type: String,
| default: '标题'
| }
| },
| data () {
| return {
| centerDialogVisible: false
| }
| },
| methods: {
| show () {
| this.centerDialogVisible = true
| },
| closeDialog () {
| this.$emit('closeDialog')
| }
| }
| }
|
| </script>
| <style lang="less">
|
| </style>
|
|