Your Name il y a 3 ans
Parent
révision
9c414c37cb
2 fichiers modifiés avec 3 ajouts et 2 suppressions
  1. 2
    1
      src/pages/video/liveDetail/index.jsx
  2. 1
    1
      src/services/activity.js

+ 2
- 1
src/pages/video/liveDetail/index.jsx Voir le fichier

40
     queryLiveDetail(id).then(res=>{
40
     queryLiveDetail(id).then(res=>{
41
         setData(res)
41
         setData(res)
42
         if (res?.liveRoomParam) {
42
         if (res?.liveRoomParam) {
43
-          getLivingCode(res.liveRoomParam).then((liveInfo) => {
43
+          const { livingid } = JSON.parse(res.liveRoomParam)
44
+          getLivingCode(livingid).then((liveInfo) => {
44
             livingRef.current = liveInfo
45
             livingRef.current = liveInfo
45
           })
46
           })
46
         }
47
         }

+ 1
- 1
src/services/activity.js Voir le fichier

112
 export const createGroupActivity = payload => fetch({ url: API_GROUP_CREATE, method: 'POST', payload })
112
 export const createGroupActivity = payload => fetch({ url: API_GROUP_CREATE, method: 'POST', payload })
113
 export const joinGroupBuy = payload => fetch({ url: API_GROUP_JOIN, method: 'POST', payload })
113
 export const joinGroupBuy = payload => fetch({ url: API_GROUP_JOIN, method: 'POST', payload })
114
 
114
 
115
-export const getLivingCode = user => fetch({ url: `${API_LIVING_CODE}?user=${encodeURIComponent(user)}` })
115
+export const getLivingCode = livingId => fetch({ url: `${API_LIVING_CODE}?livingId=${encodeURIComponent(livingId)}` })