import axios from '@/common/services/axios-instance'

class CommonService {
  //  根据字典key获取字典项
  getDictValues(keyId) {
    return axios({
      url: 'api/xcoa-mobile/v1/iam-common/dict?keyId=' + keyId,
      method: 'get',
    }).then((res) => {
      return res.data
    })
  }

  //  获取当前用户所属单位
  getCurrentUserCompany() {
    return axios({
      url: 'api/xcoa-mobile/v1/iamorg/getCurrentUserGroup',
      method: 'get',
    }).then((res) => {
      return res.data
    })
  }
}

export default new CommonService()
