refactor: save
This commit is contained in:
parent
e3e09ebdd3
commit
c3b544503d
@ -89,7 +89,6 @@ onMounted(() => {
|
|||||||
width: 100%;
|
width: 100%;
|
||||||
position: relative;
|
position: relative;
|
||||||
font-size: 14rem;
|
font-size: 14rem;
|
||||||
color: white;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.guide {
|
.guide {
|
||||||
|
|||||||
@ -355,6 +355,7 @@ export default {
|
|||||||
z-index: 9;
|
z-index: 9;
|
||||||
|
|
||||||
svg {
|
svg {
|
||||||
|
color: #000;
|
||||||
background: rgb(242, 242, 242);
|
background: rgb(242, 242, 242);
|
||||||
padding: 4rem;
|
padding: 4rem;
|
||||||
font-size: 16rem;
|
font-size: 16rem;
|
||||||
@ -368,6 +369,7 @@ export default {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.comment {
|
.comment {
|
||||||
|
color: #000;
|
||||||
width: 100vw;
|
width: 100vw;
|
||||||
height: v-bind(height);
|
height: v-bind(height);
|
||||||
background: #fff;
|
background: #fff;
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
import { defineStore } from 'pinia'
|
import { defineStore } from 'pinia'
|
||||||
import { friends, panel } from '@/api/user.js'
|
import { friends, panel } from '@/api/user.ts'
|
||||||
import enums from '@/utils/enums'
|
import enums from '@/utils/enums'
|
||||||
import resource from '@/assets/data/resource'
|
import resource from '@/assets/data/resource'
|
||||||
|
|
||||||
|
|||||||
@ -31,7 +31,7 @@ axiosInstance.interceptors.response.use(
|
|||||||
/*
|
/*
|
||||||
* 响应成功的拦截器,主要是对data作处理,如果没有返回data,那么会添加一个data字段,并把response.data的内容合并到data里面,然后返回
|
* 响应成功的拦截器,主要是对data作处理,如果没有返回data,那么会添加一个data字段,并把response.data的内容合并到data里面,然后返回
|
||||||
* */
|
* */
|
||||||
let { data } = response
|
const { data } = response
|
||||||
// console.log(response)
|
// console.log(response)
|
||||||
if (data === undefined || data === null || data === '') {
|
if (data === undefined || data === null || data === '') {
|
||||||
globalMethods.$notice('请求失败,请稍后重试!')
|
globalMethods.$notice('请求失败,请稍后重试!')
|
||||||
@ -89,12 +89,12 @@ axiosInstance.interceptors.response.use(
|
|||||||
if (error.response.status === 401) {
|
if (error.response.status === 401) {
|
||||||
return { success: false, code: 401, msg: '用户名或密码不正确', data: [] }
|
return { success: false, code: 401, msg: '用户名或密码不正确', data: [] }
|
||||||
} else {
|
} else {
|
||||||
let { data } = error.response
|
const { data } = error.response
|
||||||
if (data === null || data === undefined) {
|
if (data === null || data === undefined) {
|
||||||
globalMethods.$notice('请求失败,请稍后重试!')
|
globalMethods.$notice('请求失败,请稍后重试!')
|
||||||
return { success: true, code: 200, data: [] }
|
return { success: true, code: 200, data: [] }
|
||||||
} else {
|
} else {
|
||||||
let resCode = data.code
|
const resCode = data.code
|
||||||
if (data.data === undefined || data.data === null) {
|
if (data.data === undefined || data.data === null) {
|
||||||
data.data = { ...data }
|
data.data = { ...data }
|
||||||
}
|
}
|
||||||
Loading…
Reference in New Issue
Block a user