update Modal demo

This commit is contained in:
梁灏 2018-06-26 21:01:56 +08:00
parent 8750244d8c
commit 9edded4931

View file

@ -1,6 +1,7 @@
<template> <template>
<div> <div>
<Button type="primary" @click="modal1 = true">Display dialog box</Button> <Button type="primary" @click="modal1 = true">Display dialog box</Button>
<Button type="primary" @click="modal2 = true">Display dialog box</Button>
<Button @click="hc">Click Me</Button> <Button @click="hc">Click Me</Button>
<Modal <Modal
v-model="modal1" v-model="modal1"
@ -12,13 +13,24 @@
<p>Content of dialog</p> <p>Content of dialog</p>
<p>Content of dialog</p> <p>Content of dialog</p>
</Modal> </Modal>
<Modal
v-model="modal2"
title="Common Modal dialog box title2"
dragable
@on-ok="ok"
@on-cancel="cancel">
<p>Content of dialog</p>
<p>Content of dialog</p>
<p>Content of dialog</p>
</Modal>
</div> </div>
</template> </template>
<script> <script>
export default { export default {
data () { data () {
return { return {
modal1: false modal1: false,
modal2: false
} }
}, },
methods: { methods: {