Baozhangchao 3 years ago
parent
commit
d7fb5418db
1 changed files with 9 additions and 11 deletions
  1. 9
    11
      src/components/BottomMoadl/index.jsx

+ 9
- 11
src/components/BottomMoadl/index.jsx View File

43
 
43
 
44
     getRecommendList({ location: location, pageNum: textNextSum, pageSize: 3 }).then(e => {
44
     getRecommendList({ location: location, pageNum: textNextSum, pageSize: 3 }).then(e => {
45
       setRecommendContent(e.records)
45
       setRecommendContent(e.records)
46
-
47
     })
46
     })
48
-  }, [])
47
+  }, [location, textNextSum])
49
 
48
 
50
 
49
 
51
   //换一批
50
   //换一批
52
   const handleTextNext = (e) => {
51
   const handleTextNext = (e) => {
53
-    setLoading(true)
54
-    console.log("🚀 ~ file: index.jsx ~ line 61 ~ handleTextNext ~ e", e)
52
+    // setLoading(true)
53
+    setTextNext(textNextSum + 1)
55
 
54
 
56
     e.stopPropagation()
55
     e.stopPropagation()
57
 
56
 
58
-    setTextNext(textNextSum + 1)
59
-    getRecommendList({ location: location, pageNum: textNextSum, pageSize: 3 }).then(e => {
60
-      setRecommendContent(e.records)
61
-      setLoading(false)
57
+    // getRecommendList({ location: location, pageNum: textNextSum, pageSize: 3 }).then(e => {
58
+    //   setRecommendContent(e.records)
59
+    //   setLoading(false)
62
 
60
 
63
-    }).catch(s => {
64
-      setLoading(false)
61
+    // }).catch(s => {
62
+    //   setLoading(false)
65
 
63
 
66
-    })
64
+    // })
67
 
65
 
68
   }
66
   }
69
 
67