import { User } from '@root/src/models/user' ; import request from '@/utils/request' ; export const getUserInfo = ( params ? ) => { return request . get < ResponseData < User > > ( '/user/info/token' , params ) ; } ; export const login = ( params ) => { return request . post < ResponseData < User > > ( '/user/login' , params ) ; } ; export const logout = ( ) => { return request . post < ResponseData < any > > ( '/user/logout' ) ; } ; export const updateUser = ( id , params ) => { return request . put < ResponseData < User > > ( `/user/${ id }` , params ) ; } ;