Commit dda6fcb9 authored by 1486327116's avatar 1486327116

添加查询用户交易系统配置接口 可以用户判断用户是不是代理

parent f29b644a
...@@ -236,8 +236,8 @@ export const removeAgent = async (user_id) => { ...@@ -236,8 +236,8 @@ export const removeAgent = async (user_id) => {
// exp:1110,lpc,BTC_USDT_USDT,0.6 // exp:1110,lpc,BTC_USDT_USDT,0.6
export const addAgentSetting = async (user_id,market,symbol,ratio) => { export const addAgentSetting = async (user_id,market,symbol,ratio) => {
let body = { let body = {
user_id,market,symbol,ratio user_id, market, symbol, ratio
} };
let res = { let res = {
is_success: true, is_success: true,
err_msg: "" err_msg: ""
...@@ -251,3 +251,16 @@ export const addAgentSetting = async (user_id,market,symbol,ratio) => { ...@@ -251,3 +251,16 @@ export const addAgentSetting = async (user_id,market,symbol,ratio) => {
} }
return res; return res;
} }
// {"agentId":0,"takerFee":"1","makerFee":"1","id":12321321}
// agentId=0 表示不是代理 agentId = userId(id) 目前agentid 只有这2种情况 表示是代理商
// 所以这个接口的返回里的agentId 可以判断是不是代理商
export const getUserDetail = async (user_id) => {
const url = `${webadmin_endpoint}/user/detail?user_id=${user_id}`
let { data } = await axios.get(url);
if (data.state != 0) {
logger.error("getUserDetail", data.msg);
return null
}
return data.result;
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment