import httpRequest from '@/module/request/http-request.js'
import ipConfig from '@/config/ip.config.js'

const api = {
	getUserInfo: ipConfig.api_app + '/user/getUserInfo',
	reportOnline: ipConfig.api_app+ '/user/reportOnline',
	userAdid: ipConfig.api_app + '/user/adid'
}

/**
 * 登录获取用户信息
 */
export const requestUserInfo = (params) => {
	return httpRequest.post({
		url: api.getUserInfo,
		data: params
	})
}

/**
 * 上报在线 { placeId }  大厅：1   游戏内：gameid
 */
export const requestReportOnline = (params) => {
	return httpRequest.post({
		url: api.reportOnline,
		data: params
	})
}

// adid
export const requestUserAdid = (params) => {
	return httpRequest.post({
		url: api.userAdid,
		data: params
	})
}
