import httpInstance from '@/utils/request.js'

//登录
const getLoginAPI = (username, password) => {
  return httpInstance({
    baseURL: '/user',
    url: '/auth/loginByPwd',
    method: 'POST',
    data: {
      username,
      password
    }
  })
}

//退出登录
const getLogoutAPI = () => {
  return httpInstance({
    baseURL: '/user',
    url: '/auth/logout',
    method: 'POST'
  })
}

export { getLoginAPI, getLogoutAPI }
