<template>
  <el-container>
    <el-aside>
      <MenuView></MenuView>
    </el-aside>
    <el-container>
      <!-- <el-header>Header</el-header> -->
      <!-- <el-main> -->
        <RouterView></RouterView>
      <!-- </el-main> -->
      <!-- <el-footer>Footer</el-footer> -->
    </el-container>
  </el-container>
</template>

<script setup lang="ts">
import MenuView from "@/MenuView.vue";
import { onMounted } from "vue";
import { GetVersion } from './api/api'
import { storeToRefs } from 'pinia'
import { useVersionStore } from './store/Version';
import { useServerStore } from './store/Server';

const vr = useVersionStore();
const { version } = storeToRefs(vr);

const si = useServerStore();
const { api_version } = storeToRefs(si);


onMounted(async () => {
  GetVersion(api_version.value).then(res => {
    version.value = res;
  })
});
</script>

<style scoped lang="less">
.el-container {
  height: 100%;
  width: 100%;
}
</style>