<template>
    <div>
        添加用户按钮
        <a-button type="primary" @click="AddModal">添加用户</a-button>
        <a-modal v-model="Add" width="80%" title="添加用户" @ok="AddhandleOk">

        </a-modal>

        <!-- 用户列表 -->

        <!-- 编辑用户按钮 -->
        <a-button type="primary" @click="UpdateModel">编辑用户</a-button>
        <a-modal v-model="Update" width="80%" title="编辑用户" @ok="UpdatehandleOk">

        </a-modal>

    </div>
</template>

<script>
  export default {
    name: 'AdminUserList',
    i18n: require('./i18n'),
    data () {
      return {
        value: 1
      }
    },
    computed: {
      desc() {
        return this.$t('pageDesc')
      }
    }
  }
</script>
<script>
import { defineComponent, ref } from 'vue';
export default defineComponent({
    setup() {
        const Add = ref(false);
        const Update = ref(false);

        const AddModal = () => {
            Add.value = true;
        };
        const UpdateModel = () => {
            Update.value = true;
        };

        const AddhandleOk = e => {
            console.log(e);
            Add.value = false;
        };
        const UpdatehandleOk = e => {
            console.log(e);
            Update.value = false;
        };

        return {
            Add,
            AddModal,
            AddhandleOk,
            Update,
            UpdateModel,
            UpdatehandleOk,
        };
    },

});
</script>

  <style scoped>
  
  </style>