123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207 |
- import axios from '../http'
- import axiosForm from '../httpForm'
- export default {
- /**
- * 获取随机数
- */
- getRandom (params) {
- return axios.get('user/random', { params })
- },
- /**
- * 获取随机数 针对内嵌版本
- */
- getRandom2 (params) {
- return axios.get('user/random2', { params })
- },
- /**
- * EOS登录
- */
- eosLogin (params) {
- return axios.post('user/eosLogin', params)
- },
- /**
- * EOS登录 针对内嵌版本
- */
- eosLogin2 (params) {
- return axios.post('user/eosLogin2', params)
- },
- /**
- * EOS账号绑定
- */
- eosBind (data) {
- return axios.request({
- url: 'user/eosBind',
- method: 'post',
- needLogin: true,
- data
- })
- },
- /**
- * EOS账号绑定-最新
- */
- eosBind2 (data) {
- return axios.request({
- url: 'user/eosBind2',
- method: 'post',
- needLogin: true,
- data
- })
- },
- /**
- * ETH登录
- */
- ethLogin (params) {
- return axios.post('user/ethLogin', params)
- },
- simplewalletCheck (params) {
- return axios.get('user/simplewalletCheck', { params, noErrorMsg: true })
- },
- /**
- * ETH绑定
- */
- ethBind (data) {
- return axios.request({
- url: 'user/ethBind',
- method: 'post',
- needLogin: true,
- data
- })
- },
- /**
- * Tron登录
- */
- tronLogin (params) {
- return axios.post('user/tronLogin', params)
- },
- /**
- * Tron绑定
- */
- tronBind (data) {
- return axios.request({
- url: 'user/tronBind',
- method: 'post',
- needLogin: true,
- data
- })
- },
- /**
- * 解绑账号
- */
- unBind (data) {
- return axios.request({
- url: 'user/unbind',
- method: 'post',
- needLogin: true,
- data
- })
- },
- /**
- * Telegram登录token
- */
- tgCSRF (data) {
- return axios.request({
- url: 'user/tgCSRF',
- method: 'post',
- data
- })
- },
- /**
- * Telegram登录
- */
- tgLogin2 (data) {
- return axios.request({
- url: 'user/tgLogin2',
- method: 'post',
- data
- })
- },
- /**
- * Telegram绑定
- */
- tgBind2 (data) {
- return axios.request({
- url: 'user/tgBind2',
- method: 'post',
- needLogin: true,
- data
- })
- },
- /**
- * @des 校验本地登录态
- * @param {String} params.user_id
- * @param {String} params.token
- */
- checkLocalLogin (data) {
- return axios.request({
- url: 'user/checkLogin',
- method: 'post',
- data
- })
- },
- /**
- * 修改用户名
- */
- changeUserName (data) {
- return axios.request({
- url: 'user/changeUserName',
- method: 'post',
- needLogin: true,
- data
- })
- },
- /**
- * 修改昵称
- */
- changeNickName (data) {
- return axios.request({
- url: 'user/changeNickName',
- method: 'post',
- needLogin: true,
- data
- })
- },
- /**
- * 修改头像
- */
- changePhoto (data) {
- return axiosForm.request({
- url: 'user/changePhoto',
- method: 'post',
- data
- })
- },
- /**
- * 第三方账号是否可见
- */
- setVisible (data) {
- return axios.request({
- url: 'user/setVisible',
- method: 'post',
- needLogin: true,
- data
- })
- },
- /**
- * 账户个人信息
- */
- getInfo (params) {
- return axios.request({
- url: 'user/info',
- method: 'get',
- needLogin: true,
- params
- })
- },
- /**
- * 他人信息
- */
- getOtherInfo (params) {
- return axios.request({
- url: 'user/info',
- method: 'get',
- needLogin: false,
- params
- })
- }
- }
|