李志伟 3 years ago
parent
commit
af99cf56fc
2 changed files with 1 additions and 20 deletions
  1. 0
    7
      src/pages/details/NoteDetails/index.jsx
  2. 1
    13
      src/pages/index/tabs/Recommend.jsx

+ 0
- 7
src/pages/details/NoteDetails/index.jsx View File

23
 import ImageList from "../components/ImageList";
23
 import ImageList from "../components/ImageList";
24
 import './index.less'
24
 import './index.less'
25
 
25
 
26
-
27
-
28
 export default withLayout((props) => {
26
 export default withLayout((props) => {
29
   const { router, person } = props
27
   const { router, person } = props
30
   const { id } = props.router.params
28
   const { id } = props.router.params
92
       const videoHeights = proportion * getVideoWidth;
90
       const videoHeights = proportion * getVideoWidth;
93
       setVideoHeight(videoHeights)
91
       setVideoHeight(videoHeights)
94
     }
92
     }
95
-
96
   }, [getVideoWidth, proportion])
93
   }, [getVideoWidth, proportion])
97
 
94
 
98
   const hanleLoade = (e) => {
95
   const hanleLoade = (e) => {
115
         setDetail(res)
112
         setDetail(res)
116
         setimglist(res.imageList || [])
113
         setimglist(res.imageList || [])
117
         setRecommend(res.wxResourceList || [])
114
         setRecommend(res.wxResourceList || [])
118
-
119
         setLoading(false)
115
         setLoading(false)
120
-
121
       }).catch(e => {
116
       }).catch(e => {
122
         console.error("getNoteID错误", e)
117
         console.error("getNoteID错误", e)
123
         setLoading(false)
118
         setLoading(false)
124
-
125
       })
119
       })
126
       getExtendContent('note', id, { pageSize: 500 }).then((res) => {
120
       getExtendContent('note', id, { pageSize: 500 }).then((res) => {
127
         setExtend(res.records || [])
121
         setExtend(res.records || [])
128
         setLoading(false)
122
         setLoading(false)
129
-
130
       })
123
       })
131
     }
124
     }
132
   }, [id])
125
   }, [id])

+ 1
- 13
src/pages/index/tabs/Recommend.jsx View File

32
   //分类标签
32
   //分类标签
33
   const tabs = [{ title: '地点' }, { title: '笔记' }]
33
   const tabs = [{ title: '地点' }, { title: '笔记' }]
34
 
34
 
35
-  const details = (index, tab) => {
36
-
37
-
38
-
39
-  }
40
   //切换上面的标签
35
   //切换上面的标签
41
   const handleTabChange = (e) => {
36
   const handleTabChange = (e) => {
42
     const { index } = e.detail
37
     const { index } = e.detail
43
     setActiveTab(index)
38
     setActiveTab(index)
44
     setQueryParams({ ...queryParams })
39
     setQueryParams({ ...queryParams })
45
-
46
-    details(index, tabs[index].typeId || '')
47
   }
40
   }
48
 
41
 
49
   const handleDataChange = (value, e) => {
42
   const handleDataChange = (value, e) => {
117
             </List>
110
             </List>
118
             :
111
             :
119
             <RecommendNote />
112
             <RecommendNote />
120
-
121
-
122
         }
113
         }
123
-
124
       </view>
114
       </view>
125
-
126
-
127
     </view>
115
     </view>
128
   )
116
   )
129
-}
117
+}