통합로그 : home banner 클릭시 해당값 로그 호출
This commit is contained in:
@@ -172,8 +172,7 @@ export default function RandomUnit({
|
|||||||
};
|
};
|
||||||
|
|
||||||
if (data && nowMenu === LOG_MENU.HOME_TOP) {
|
if (data && nowMenu === LOG_MENU.HOME_TOP) {
|
||||||
dispatch(
|
const logParams = {
|
||||||
sendLogTotalRecommend({
|
|
||||||
contextName: LOG_CONTEXT_NAME.HOME,
|
contextName: LOG_CONTEXT_NAME.HOME,
|
||||||
messageId: bannerClick
|
messageId: bannerClick
|
||||||
? LOG_MESSAGE_ID.BANNER_CLICK
|
? LOG_MESSAGE_ID.BANNER_CLICK
|
||||||
@@ -187,8 +186,13 @@ export default function RandomUnit({
|
|||||||
partner: data.patncNm,
|
partner: data.patncNm,
|
||||||
brand: data.brndNm, // <- 'brnad' 확인
|
brand: data.brndNm, // <- 'brnad' 확인
|
||||||
location: bannerData.banrLctnNo,
|
location: bannerData.banrLctnNo,
|
||||||
})
|
};
|
||||||
);
|
dispatch(sendLogTotalRecommend(logParams));
|
||||||
|
if (bannerClick) {
|
||||||
|
console.log("###bannerClick", logParams);
|
||||||
|
} else {
|
||||||
|
console.log("###bannerShow", logParams);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
[dispatch, nowMenu, curationId, curationTitle]
|
[dispatch, nowMenu, curationId, curationTitle]
|
||||||
@@ -440,7 +444,6 @@ export default function RandomUnit({
|
|||||||
const videoClick = useCallback(() => {
|
const videoClick = useCallback(() => {
|
||||||
const lastFocusedTargetId = getContainerId(Spotlight.getCurrent());
|
const lastFocusedTargetId = getContainerId(Spotlight.getCurrent());
|
||||||
const currentSpot = Spotlight.getCurrent();
|
const currentSpot = Spotlight.getCurrent();
|
||||||
|
|
||||||
if (lastFocusedTargetId) {
|
if (lastFocusedTargetId) {
|
||||||
dispatch(
|
dispatch(
|
||||||
updateHomeInfo({
|
updateHomeInfo({
|
||||||
@@ -468,8 +471,6 @@ export default function RandomUnit({
|
|||||||
})
|
})
|
||||||
);
|
);
|
||||||
|
|
||||||
sendBannerLog(true);
|
|
||||||
|
|
||||||
dispatch(
|
dispatch(
|
||||||
sendLogTopContents({
|
sendLogTopContents({
|
||||||
...topContentsLogInfo,
|
...topContentsLogInfo,
|
||||||
@@ -478,6 +479,7 @@ export default function RandomUnit({
|
|||||||
})
|
})
|
||||||
);
|
);
|
||||||
|
|
||||||
|
sendBannerLog(true);
|
||||||
onBlur();
|
onBlur();
|
||||||
}, [
|
}, [
|
||||||
randomData,
|
randomData,
|
||||||
@@ -513,7 +515,7 @@ export default function RandomUnit({
|
|||||||
|
|
||||||
//통합로그
|
//통합로그
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
sendBannerLog(false);
|
sendBannerLog();
|
||||||
}, [sendBannerLog]);
|
}, [sendBannerLog]);
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
|
|||||||
@@ -171,7 +171,6 @@ export default function RollingUnit({
|
|||||||
|
|
||||||
return {};
|
return {};
|
||||||
}, [shptmTmplCd, startIndex]);
|
}, [shptmTmplCd, startIndex]);
|
||||||
|
|
||||||
const sendBannerLog = useCallback(
|
const sendBannerLog = useCallback(
|
||||||
(bannerClick) => {
|
(bannerClick) => {
|
||||||
const data = rollingDataRef.current[startIndex];
|
const data = rollingDataRef.current[startIndex];
|
||||||
@@ -184,8 +183,7 @@ export default function RollingUnit({
|
|||||||
bannerType: "Vertical",
|
bannerType: "Vertical",
|
||||||
};
|
};
|
||||||
if (rollingDataRef.current && nowMenu === LOG_MENU.HOME_TOP) {
|
if (rollingDataRef.current && nowMenu === LOG_MENU.HOME_TOP) {
|
||||||
dispatch(
|
const logParams = {
|
||||||
sendLogTotalRecommend({
|
|
||||||
contextName: LOG_CONTEXT_NAME.HOME,
|
contextName: LOG_CONTEXT_NAME.HOME,
|
||||||
messageId: bannerClick
|
messageId: bannerClick
|
||||||
? LOG_MESSAGE_ID.BANNER_CLICK
|
? LOG_MESSAGE_ID.BANNER_CLICK
|
||||||
@@ -202,11 +200,16 @@ export default function RollingUnit({
|
|||||||
brand: data.brndNm,
|
brand: data.brndNm,
|
||||||
location: bannerData.banrLctnNo,
|
location: bannerData.banrLctnNo,
|
||||||
...newParams,
|
...newParams,
|
||||||
})
|
};
|
||||||
);
|
dispatch(sendLogTotalRecommend(logParams));
|
||||||
|
if (bannerClick) {
|
||||||
|
console.log("###bannerClick", logParams);
|
||||||
|
} else {
|
||||||
|
console.log("###bannerShow", logParams);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
[nowMenu, rollingDataRef]
|
[nowMenu, rollingDataRef, imageBannerClick]
|
||||||
);
|
);
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
@@ -355,7 +358,7 @@ export default function RollingUnit({
|
|||||||
|
|
||||||
if (bannerType === "Today's Deals") {
|
if (bannerType === "Today's Deals") {
|
||||||
handlePushPanel(panel_names.DETAIL_PANEL, createPanelInfo(currentData));
|
handlePushPanel(panel_names.DETAIL_PANEL, createPanelInfo(currentData));
|
||||||
sendBannerLog();
|
sendBannerLog(true);
|
||||||
dispatch(
|
dispatch(
|
||||||
sendLogTopContents({
|
sendLogTopContents({
|
||||||
...topContentsLogInfo,
|
...topContentsLogInfo,
|
||||||
|
|||||||
@@ -361,6 +361,8 @@ const PlayerPanel = ({
|
|||||||
prevNowMenuRef.current = nowMenuRef.current;
|
prevNowMenuRef.current = nowMenuRef.current;
|
||||||
|
|
||||||
return () => dispatch(sendLogGNB(prevNowMenuRef.current));
|
return () => dispatch(sendLogGNB(prevNowMenuRef.current));
|
||||||
|
} else if (panelInfo?.modal) {
|
||||||
|
dispatch(sendLogGNB(entryMenu));
|
||||||
}
|
}
|
||||||
}, [panelInfo?.modal, panelInfo?.shptmBanrTpNm]);
|
}, [panelInfo?.modal, panelInfo?.shptmBanrTpNm]);
|
||||||
|
|
||||||
@@ -400,7 +402,6 @@ const PlayerPanel = ({
|
|||||||
logTemplateNo = Config.LOG_TP_NO.LIVE.ITEM_DETAIL;
|
logTemplateNo = Config.LOG_TP_NO.LIVE.ITEM_DETAIL;
|
||||||
setLogStatus((status) => ({ ...status, isDetailLiveLogReady: true }));
|
setLogStatus((status) => ({ ...status, isDetailLiveLogReady: true }));
|
||||||
}
|
}
|
||||||
|
|
||||||
liveLogParamsRef.current = {
|
liveLogParamsRef.current = {
|
||||||
entryMenu: entryMenuRef.current,
|
entryMenu: entryMenuRef.current,
|
||||||
lgCatCd: currentLiveShowInfo.catCd ?? "",
|
lgCatCd: currentLiveShowInfo.catCd ?? "",
|
||||||
@@ -855,7 +856,6 @@ const PlayerPanel = ({
|
|||||||
// ev?.preventDefault();
|
// ev?.preventDefault();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (panelInfo.modalContainerId && !panelInfo.modal) {
|
if (panelInfo.modalContainerId && !panelInfo.modal) {
|
||||||
dispatch(
|
dispatch(
|
||||||
startVideoPlayer({
|
startVideoPlayer({
|
||||||
@@ -899,6 +899,7 @@ const PlayerPanel = ({
|
|||||||
[
|
[
|
||||||
dispatch,
|
dispatch,
|
||||||
panelInfo,
|
panelInfo,
|
||||||
|
nowMenu,
|
||||||
videoPlayer,
|
videoPlayer,
|
||||||
sideContentsVisible,
|
sideContentsVisible,
|
||||||
videoVerticalVisible,
|
videoVerticalVisible,
|
||||||
|
|||||||
Reference in New Issue
Block a user