优化接口请求

This commit is contained in:
谢思 2023-04-27 15:17:18 +08:00
parent 34f00361c0
commit ef84ea8529
2 changed files with 4 additions and 4 deletions

View File

@ -52,7 +52,7 @@ function Apply(props) {
useEffect(()=>{
//
current_user && getUserApplyInfo({userId: current_user.user_id, round}).then(response=>{
current_user && round && getUserApplyInfo({userId: current_user.user_id, round}).then(response=>{
if(response && response.message === "success"){
setUserApplyInfo(response.data);
if(!response.data){
@ -81,7 +81,7 @@ function Apply(props) {
})
}
})
}, [reload])
}, [])
//
function verify(dataIndex){

View File

@ -133,8 +133,8 @@ const Glcc = (propsF) => {
}, [])
useEffect(()=>{
//
current_user && current_user.login && getStudentApplyInfo({userId: current_user.user_id}).then(response=>{
// (todo)
false && current_user && current_user.login && getStudentApplyInfo({userId: current_user.user_id}).then(response=>{
if(response && response.message === "success"){
// setData(response.data.rows);
const data = {};