为访客提交头像添加新的单独接口,不允许直接上传到设备。

This commit is contained in:
2025-04-25 11:19:55 +08:00
parent d9dbaa313e
commit c897d0c32e
3 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -4,7 +4,7 @@ import { useStore } from "vuex";
import { Toast, Dialog } from "vant";
// import { getItem, setItem, removeItem, dalert } from '@/com/index'
const errorCode = {
401: "登录状态已过期,即将返回首页重新登录。",
401: "登录已过期,即将返回首页重新登录。",
403: "当前操作没有权限",
404: "访问资源不存在",
default: "系统未知错误,请反馈给管理员",
-1
View File
@@ -244,7 +244,6 @@ import { uploadGuestFaceApi } from '@/api/upload'
formData.append('file', res.file)
formData.append('userId', form.phone)
formData.append('name', form.name)
formData.append('userType', 'visitor')
Toast.loading({ duration: 0, forbidClick: true, message: '上传中', });
uploadGuestFaceApi(formData).then(res =>{
Toast.success(res.msg);
+1
View File
@@ -160,6 +160,7 @@
getToken(code).then(data =>{
localStorage.setItem('user', data.data)
localStorage.setItem('token', data.data.authorization)
alert("登录成功:"+data.data.authorization)
Toast.clear()
Toast.success('登录成功')
deptList()