<template>
  <GenericManager
    :uri="resource_uri"
    object_name="租户"
    :list_fields="['id', 'username', 'display_name', 'mobile']"
    :visible_fields="['id', 'username', 'display_name', 'mobile']"
    :editable_fields="['username', 'display_name', 'mobile', 'password', 'service_qr_file']"
    :default_values="default_values"
    delete_confirm_field_name="username"
    show_search=1
  />
</template>

<script>
export default {
  name: 'Tenants',
  props: [],
  components: {
  },
  data: function () {
    return {
      resource_uri: "/api/v1/tenant/",
      default_values: {
        password: () => {
          return this.gen_random_string(10);
        }
      },
    };
  },
  computed: {
  },
  methods: {
  },
  mounted() {
  },
}
</script>

<style scoped>
button.show-tenant {
  display: block;
  margin-bottom: 1rem;
}
</style>
