<template>
  <div>{{ showValue }}</div>
</template>

<script>
import { getUserModuleApi } from "@/api/integrationOption/integrationOption.js";
export default {
  props: {
    id: {
      type: [String, Number],
    },
  },
  data() {
    return {
      showValue: "",
    };
  },
  methods: {
    async initSysSelect() {
      const res = await getUserModuleApi({
        tl: "sysAppService",
        as: "app",
        dj: "queryList",
      });
      if (res.status == 200) {
        res.attribute.some((item) => {
          if (this.id == item.id) {
            this.showValue = item.name;
          }
        });
      }
    },
    async searchApi() {
      const res = await getUserModuleApi(
        {
          tl: "appApiService",
          as: "appApi",
          dj: "queryEntity",
        },
        {
          id: "19fd5110767b46d2853d359a97303bb6",
        }
      );
    },
  },
  created() {
    if (this.id) {
      this.initSysSelect();
    }
    this.searchApi();
  },
};
</script>

<style>
</style>