20240205
e 3 years ago
parent 6729797457
commit 25d2bde53f
  1. 8
      src/api/api.js
  2. 6
      src/pages/lobbyManager/list/index.vue

@ -27,8 +27,6 @@ service.interceptors.response.use(
if(error.response && error.response.status == 404){
router.push('/blank.vue')
}
return Promise.reject(error.response)
}
)
@ -48,8 +46,6 @@ if(tokens){
}else{
token = sessionStorage.getItem('token')
}
console.log(token)
// let token = sessionStorage.getItem('token')
export function get(url, params = {}) {
// params.t = new Date().getTime(); //get方法加一个时间参数,解决ie下可能缓存问题.
return service({
@ -61,8 +57,6 @@ export function get(url, params = {}) {
params
})
}
//封装post请求
export function post(url, data = {}) {
//默认配置
@ -78,7 +72,6 @@ export function post(url, data = {}) {
sendObject.data=JSON.stringify(data);
return service(sendObject)
}
//封装put方法 (resfulAPI常用)
export function put(url,data = {}){
return service({
@ -101,7 +94,6 @@ export function deletes(url){
}
})
}
//不要忘记export
export {
service

@ -1,7 +1,7 @@
<template>
<div class="wrap">
<img class="sth manager" src="@/assets/img/manager.png" alt="">
<img class="sth guide" src="@/assets/img/guide.png" alt="">
<img class="sth guide" @click="toPart('../index/list')" src="@/assets/img/guide.png" alt="">
<div class="actions">
<ul class="btns">
@ -170,7 +170,9 @@ export default {
this.takeVisible = false
this.takeResultVisible = true
},
toPart(path){
this.$router.push(path)
},
showData(){
this.dataVisible = true
},

Loading…
Cancel
Save