import {defineStore} from "pinia";
import {WorkBench} from "/@/api/admin/workbench/workBench";
import {workBenchDto} from "/@/api/admin/workbench/workBenchDto";

export const useChartDataStore = defineStore('chartDataStore', {
  state: () => ({
    chartStore:{} as workBenchDto
  }),
  actions: {
    /**获取所有字典缓存*/
    async requestChartStore  ()  {
      const { data } = await new WorkBench().getInitData()
      this.setChartStore(data)
    },

    getChartStore(){
      return this.chartStore
    },

    setChartStore(val:any) {
      this.chartStore = val
    }
  }
})
