import axios from 'axios'
import ax from '../http'

export default {
  getCode ({ phone }) {
    return ax.get('/login/getCode', {
      params: { phone }
    })
  },
  checkCode ({ phone, code }) {
    return ax.get('/login/checkCode', {
      params: { phone, code }
    })
  },
  // 管理员权限校验
  checkAdmin ({ nodeId, userId }) {
    return axios.post('//test.admin.duowan.com/open/checkRight2', {
      params: { nodeId, userId }
    })
  }
}
