[통합로그API No.8] FeaturedBrands Series content 클릭 시 로그 정보 수집

This commit is contained in:
dongyoungKo
2025-05-20 14:12:28 +09:00
parent 8350d4a9fa
commit 9286cd0fcd
4 changed files with 68 additions and 4 deletions

View File

@@ -26,6 +26,7 @@ const Series = ({
handleItemFocus,
order,
shelfOrder,
shelfTitle,
spotlightId,
selectedPatncNm,
selectedPatnrId,
@@ -117,6 +118,9 @@ const Series = ({
seriesImgUrl={seriesImgUrl}
seriesNm={seriesNm}
spotlightId={spotlightId}
shelfOrder={shelfOrder}
shelfTitle={shelfTitle}
selectedPatncNm={selectedPatncNm}
/>
)
)}

View File

@@ -21,9 +21,12 @@ const SeriesContents = ({
isCarousel = false,
patnrId,
selectedPatnrId,
selectedPatnrNm,
selectedSeriesId,
seriesImgUrl,
seriesNm,
shelfOrder,
shelfTitle,
spotlightId,
}) => {
const rankOrd = contentsIndex * 1 + 1;
@@ -64,9 +67,13 @@ const SeriesContents = ({
contentsIndex={contentsIndex}
handleFocus={handleFocus}
patnrId={patnrId}
selectedPatnrNm={selectedPatnrNm}
selectedSeriesId={selectedSeriesId}
selectedPatnrId={selectedPatnrId}
seriesNm={seriesNm}
shelfOrder={shelfOrder}
shelfTitle={shelfTitle}
spotlightId={spotlightId}
/>
</div>
) : (
@@ -77,6 +84,9 @@ const SeriesContents = ({
seriesImgUrl={seriesImgUrl}
seriesNm={seriesNm}
spotlightId={spotlightId}
shelfOrder={shelfOrder}
shelfTitle={shelfTitle}
selectedPatnrNm={selectedPatnrNm}
/>
)}
</Container>

View File

@@ -6,7 +6,11 @@ import Spotlight from "@enact/spotlight";
import { pushPanel, updatePanel } from "../../../../../actions/panelActions";
import TItemCard from "../../../../../components/TItemCard/TItemCard";
import { panel_names } from "../../../../../utils/Config";
import {
LOG_CONTEXT_NAME,
LOG_MESSAGE_ID,
panel_names,
} from "../../../../../utils/Config";
import SeriesImageCard from "../SeriesImageCard/SeriesImageCard";
import css from "./SeriesProductGrid.module.less";
@@ -17,6 +21,9 @@ const SeriesProductGrid = ({
seriesImgUrl,
seriesNm,
spotlightId,
shelfOrder,
shelfTitle,
selectedPatnrNm,
}) => {
const dispatch = useDispatch();
@@ -65,11 +72,29 @@ const SeriesProductGrid = ({
</li>
{brandSeriesProductInfo.map(
(
{ offerInfo, prdtId, prdtImgUrl, prdtNm, priceInfo, soldoutFlag },
{
offerInfo,
prdtId,
prdtImgUrl,
prdtNm,
priceInfo,
soldoutFlag,
catNm,
brndNm,
},
itemIndex
) => (
<li key={`${spotlightId}-${itemIndex}`}>
<TItemCard
contextName={LOG_CONTEXT_NAME.FEATURED_BRANDS}
messageId={LOG_MESSAGE_ID.SHELF_CLICK}
shelfLocation={shelfOrder}
shelfTitle={shelfTitle}
shelfId={spotlightId}
patnerName={selectedPatnrNm}
order={itemIndex + 1}
catNm={catNm}
brndNm={brndNm}
data-wheel-point={itemIndex >= 3}
imageAlt={prdtNm}
imageSource={prdtImgUrl}

View File

@@ -11,7 +11,11 @@ import TItemCard, {
} from "../../../../../components/TItemCard/TItemCard";
import TVirtualGridList from "../../../../../components/TVirtualGridList/TVirtualGridList";
import useScrollTo from "../../../../../hooks/useScrollTo";
import { panel_names } from "../../../../../utils/Config";
import {
LOG_CONTEXT_NAME,
LOG_MESSAGE_ID,
panel_names,
} from "../../../../../utils/Config";
import { getTranslate3dValueByDirection } from "../../../../../utils/helperMethods";
import css from "./SeriesProductList.module.less";
@@ -22,6 +26,10 @@ export default function SeriesProductList({
patnrId,
selectedPatnrId,
selectedSeriesId,
selectedPatnrNm,
shelfOrder,
shelfTitle,
spotlightId,
}) {
const { getScrollTo, scrollLeft } = useScrollTo();
@@ -102,10 +110,21 @@ export default function SeriesProductList({
prdtNm,
priceInfo,
soldoutFlag,
catNm,
brndNm,
} = brandSeriesProductInfo[index];
return (
<TItemCard
contextName={LOG_CONTEXT_NAME.FEATURED_BRANDS}
messageId={LOG_MESSAGE_ID.SHELF_CLICK}
shelfLocation={shelfOrder}
shelfTitle={shelfTitle}
shelfId={spotlightId}
patnerName={selectedPatnrNm}
order={contentsIndex + 1}
catNm={catNm}
brandName={brndNm}
data-exposure-order={contentsIndex + 1}
imageAlt={prdtNm}
imageSource={prdtImgUrl}
@@ -123,7 +142,13 @@ export default function SeriesProductList({
/>
);
},
[brandSeriesProductInfo, contentsIndex, handleClick, handleFocus]
[
brandSeriesProductInfo,
contentsIndex,
handleClick,
selectedPatnrNm,
handleFocus,
]
);
return (