index.ts 359 B

123456789101112131415
  1. import request from '@/config/axios/request'
  2. // 获得地区树
  3. export const getAreaTree = async (content?: any) => {
  4. return await request.get({
  5. url: '/system/area/tree',
  6. params: content
  7. })
  8. }
  9. // 获得 IP 对应的地区名
  10. export const getAreaByIp = async (ip) => {
  11. return await request.get({
  12. url: '/system/area/get-by-ip?ip=' + ip
  13. })
  14. }