import request from '@/config/axios'

export interface EnterpriseAuthPageVO {
  id: number // id
  reason: string // 审核原因
}

// 门墩儿-企业实名认证申请 API
export const EnterpriseAuthApi = {

  // 查询门墩儿-企业实名认证申请分页
  getEnterpriseAuthPage: async (params: any) => {
    return await request.get({ url: `/menduner/system/enterprise-auth/page`, params })
  },

  // 查询门墩儿-企业实名认证申请详情
  getEnterpriseAuth: async (id: number) => {
    return await request.get({ url: `/menduner/system/enterprise-auth/get?id=` + id })
  },

  // 门墩儿-企业实名认证申请 通过
  passEnterpriseAuth: async (data: EnterpriseAuthPageVO) => {
    return await request.put({ url: `/menduner/system/enterprise-auth/approved`, data })
  },

  // 门墩儿-企业实名认证申请 拒绝
  rejectEnterpriseAuth: async (data: EnterpriseAuthPageVO) => {
    return await request.put({ url: `/menduner/system/enterprise-auth/reject`, data })
  }
}