From c1d4d3926545aac5be6be5c378a558f387fef7ac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?lemon=E6=A9=AA?= <17633066053@163.com> Date: Mon, 20 Dec 2021 17:34:45 +0800 Subject: [PATCH] =?UTF-8?q?udesk=20=E6=8A=80=E6=9C=AF=E5=82=A8=E5=A4=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- api/common.js | 58 ++++++++++++++++++++++++++++----------------------- 1 file changed, 32 insertions(+), 26 deletions(-) diff --git a/api/common.js b/api/common.js index ae5e2dc..030e5e2 100644 --- a/api/common.js +++ b/api/common.js @@ -1,26 +1,32 @@ -/** - * 公共API - */ -import {http, Method} from '@/utils/request.js'; -import api from '@/config/api.js'; - - - -/** - * 获取地区数据 - * @param id - */ -export function getRegionsById(id = 0) { - return http.request({ - url: `${api.common}/region/item/${id}`, - method: Method.GET, - message: false, - }); -} - -/** - * 文件上传地址 - * @type {string} - */ -export const upload =api.common+'/upload/file'; - +/** + * 公共API + */ +import { http, Method } from "@/utils/request.js"; +import api from "@/config/api.js"; + +/** + * 获取地区数据 + * @param id + */ +export function getRegionsById(id = 0) { + return http.request({ + url: `${api.common}/region/item/${id}`, + method: Method.GET, + message: false, + }); +} + +// 获取IM接口前缀 +export function getIMDetail() { + return http.request({ + url: `${api.common}/IM`, + method: Method.GET, + message: false, + }); +} + +/** + * 文件上传地址 + * @type {string} + */ +export const upload = api.common + "/upload/file";