alert.vue 552 B

1234567891011121314151617181920212223242526272829303132
  1. <template>
  2. <div>
  3. <mu-dialog title="警告" width="360" :open.sync="openSimple">
  4. {{text}}
  5. <mu-button slot="actions" flat color="primary" @click="closeSimpleDialog">关闭</mu-button>
  6. </mu-dialog>
  7. </div>
  8. </template>
  9. <script>
  10. export default {
  11. data() {
  12. return {
  13. openSimple: false,
  14. text:'1111'
  15. };
  16. },
  17. methods: {
  18. openSimpleDialog(info) {
  19. this.openSimple = true;
  20. this.text = info;
  21. },
  22. closeSimpleDialog() {
  23. this.openSimple = false;
  24. }
  25. }
  26. }
  27. </script>
  28. <style scoped>
  29. </style>