'use strict';

var vue = require('vue');
var pinia = require('pinia');
var core = require('@vueuse/core');
require('../../../../api/guardBasic/controller/index.js');
var usePostBasicV1SystemListAll = require('../../../../api/guardBasic/controller/JiChuFuWu/XiTongGuanLi/usePostBasicV1SystemListAll.js');

const useSystemListStore = pinia.defineStore("gmSystemList", () => {
  const { isLoading, exec, data } = usePostBasicV1SystemListAll.usePostBasicV1SystemListAll();
  const systemList = vue.computed(() => data.value?.data || []);
  const getSystemList = async () => {
    if (systemList.value.length !== 0 || isLoading.value) {
      return;
    }
    return exec();
  };
  core.tryOnMounted(() => {
    getSystemList();
  });
  return {
    systemList,
    isLoading,
    getSystemList
  };
});

exports.useSystemListStore = useSystemListStore;
//# sourceMappingURL=index.js.map
