import { defineStore } from "pinia";
export const useAppraovalStore = defineStore("appraoval", {
  state: () => {
    return {
      settingList: [],
      initiator: "",
      branchType: null,
    };
  },
  actions: {
    setSettingList(list) {
      this.settingList = list;
    },
    getInitiator(initiator) {
      console.log(initiator);
      this.initiator =
        initiator === 1
          ? "全公司人员"
          : initiator === 2
          ? "指定岗位"
          : "指定人员";
    },
    getBranchType(type) {
      this.branchType = type;
    },
  },
});
