import request from "@/utils/request";
// const Login = (params:any)=>{
//     request({
//         url: "/log",
//         params
//     });

// }
 
export const getRouters = async () => {
 return  await request({
    url: "/init/list-menus",
    method:'post',
  });
};

export const createRegister = async(params: any)=>{
  return  await request({
    url: "/user/register",
    method:'post',
    params,
  });
}

export const onLogin = async(data: any)=>{
  return  await request({
    url: "/pub/login",
    method:'post',
    data,
  });
}
// /aaa/tt
export const onTest = async(data: any)=>{
  return  await request({
    url: "/aaa/tt",
    method:'post',
    data,
  });
}
export const payConfigGetSearch = async(id:number)=>{
  return  await request({
    url: `/pay/select?uid=${id}`,
    method:'post',
  });
} 

export const onZfbPay = async(data:any)=>{
  return  await request({
    url: `/pay/createali`,
    method:'post',
    data
  });
} 

export const onWxPay = async(data:any)=>{
  return  await request({
    url: `/pay/createwx`,
    method:'post',
    data
  });
} 

export const getPaySelect = async(uid:any)=>{
  return  await request({
    url: `/pay/select?uid=${uid}`,
    method:'post',
  });
} 
export const onUpdate = async(data:any)=>{
  return  await request({
    url: `/pay/updateali`,
    method:'post',
    data
  });
}

export const onUpdateWX = async(data:any)=>{
  return  await request({
    url: `/pay/updatewx`,
    method:'post',
    data
  });
} 
export const onSearchSelectrealmName = async(uid:any)=>{
  return  await request({
    url: `/pay/selectrealmname?uid=${uid}`,
    method:'post',
  });
} 

export const onCreaterealmName = async(data:any)=>{
  return  await request({
    url: `/pay/createrealmname`,
    method:'post',
    data
  });
} 

export const onUpdaterealmName = async(data:any)=>{
  return  await request({
    url: `/pay/updaterealmname`,
    method:'post',
    data
  });
} 

export const onCreateGoods = async(data:any)=>{
  return  await request({
    url: `/goods/creategoods`,
    method:'post',
    data
  });
} 

export const onfindAli = async(uid:any)=>{
  return  await request({
    url: `/pay/findAli?uid=${uid}`,
    method:'post',
  });
} 

export const onfindWX = async(uid:any)=>{
  return  await request({
    url: `/pay/findWX?uid=${uid}`,
    method:'post',
  });
} 
export const onSelectGoods = async(uid:any)=>{
  return  await request({
    url: `/goods/select?uid=${uid}`,
    method:'post',
  });
} 


export const onfindbylikename = async(uid:any)=>{
  return  await request({
    url: `/goods/findbylikename?uid=${uid}`,
    method:'post',
  });
} 


// /goods/select
// /pay/findAli

// /goods/creategoods


// /pay/createrealmname

// /user/register