[통합로그] contextName , messageId add Config.js
This commit is contained in:
@@ -581,3 +581,12 @@ export const ERROR_MESSAGES_GROUPS = [
|
|||||||
message: $L("The order request has failed."),
|
message: $L("The order request has failed."),
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
|
export const LOG_CONTEXT_NAME = {
|
||||||
|
HOME: "shoptime.home",
|
||||||
|
};
|
||||||
|
|
||||||
|
export const LOG_MESSAGE_ID = {
|
||||||
|
HOME: "AL_HOME_SHOWN",
|
||||||
|
BANNER: "AL_BANNER_SHOWN",
|
||||||
|
};
|
||||||
|
|||||||
@@ -4,36 +4,56 @@ import React, {
|
|||||||
useMemo,
|
useMemo,
|
||||||
useRef,
|
useRef,
|
||||||
useState,
|
useState,
|
||||||
} from "react";
|
} from 'react';
|
||||||
|
|
||||||
import classNames from "classnames";
|
import classNames from 'classnames';
|
||||||
import { useDispatch, useSelector } from "react-redux";
|
import {
|
||||||
|
useDispatch,
|
||||||
|
useSelector,
|
||||||
|
} from 'react-redux';
|
||||||
|
|
||||||
import Spotlight from "@enact/spotlight";
|
import Spotlight from '@enact/spotlight';
|
||||||
import SpotlightContainerDecorator from "@enact/spotlight/SpotlightContainerDecorator";
|
import SpotlightContainerDecorator
|
||||||
import Spottable from "@enact/spotlight/Spottable";
|
from '@enact/spotlight/SpotlightContainerDecorator';
|
||||||
import { getContainerId } from "@enact/spotlight/src/container";
|
import Spottable from '@enact/spotlight/Spottable';
|
||||||
|
import { getContainerId } from '@enact/spotlight/src/container';
|
||||||
|
|
||||||
import btnPlay from "../../../../assets/images/btn/btn-play-thumb-nor.png";
|
import btnPlay from '../../../../assets/images/btn/btn-play-thumb-nor.png';
|
||||||
import defaultLogoImg from "../../../../assets/images/ic-tab-partners-default@3x.png";
|
import defaultLogoImg
|
||||||
import emptyHorImage from "../../../../assets/images/img-home-banner-empty-hor.png";
|
from '../../../../assets/images/ic-tab-partners-default@3x.png';
|
||||||
import emptyVerImage from "../../../../assets/images/img-home-banner-empty-ver.png";
|
import emptyHorImage
|
||||||
import defaultImageItem from "../../../../assets/images/img-thumb-empty-product@3x.png";
|
from '../../../../assets/images/img-home-banner-empty-hor.png';
|
||||||
import liveShow from "../../../../assets/images/tag-liveshow.png";
|
import emptyVerImage
|
||||||
import { changeAppStatus } from "../../../actions/commonActions";
|
from '../../../../assets/images/img-home-banner-empty-ver.png';
|
||||||
import { updateHomeInfo } from "../../../actions/homeActions";
|
import defaultImageItem
|
||||||
import { sendLogTopContents } from "../../../actions/logActions";
|
from '../../../../assets/images/img-thumb-empty-product@3x.png';
|
||||||
import { pushPanel } from "../../../actions/panelActions";
|
import liveShow from '../../../../assets/images/tag-liveshow.png';
|
||||||
|
import { changeAppStatus } from '../../../actions/commonActions';
|
||||||
|
import { updateHomeInfo } from '../../../actions/homeActions';
|
||||||
|
import {
|
||||||
|
sendLogTopContents,
|
||||||
|
sendLogTotalRecommend,
|
||||||
|
} from '../../../actions/logActions';
|
||||||
|
import { pushPanel } from '../../../actions/panelActions';
|
||||||
import {
|
import {
|
||||||
finishVideoPreview,
|
finishVideoPreview,
|
||||||
startVideoPlayer,
|
startVideoPlayer,
|
||||||
} from "../../../actions/playActions";
|
} from '../../../actions/playActions';
|
||||||
import CustomImage from "../../../components/CustomImage/CustomImage";
|
import CustomImage from '../../../components/CustomImage/CustomImage';
|
||||||
import usePriceInfo from "../../../hooks/usePriceInfo";
|
import usePriceInfo from '../../../hooks/usePriceInfo';
|
||||||
import { LOG_MENU, LOG_TP_NO, panel_names } from "../../../utils/Config";
|
import {
|
||||||
import { $L, formatGMTString } from "../../../utils/helperMethods";
|
LOG_CONTEXT_NAME,
|
||||||
import { TEMPLATE_CODE_CONF } from "../HomePanel";
|
LOG_MENU,
|
||||||
import css from "./RandomUnit.module.less";
|
LOG_MESSAGE_ID,
|
||||||
|
LOG_TP_NO,
|
||||||
|
panel_names,
|
||||||
|
} from '../../../utils/Config';
|
||||||
|
import {
|
||||||
|
$L,
|
||||||
|
formatGMTString,
|
||||||
|
} from '../../../utils/helperMethods';
|
||||||
|
import { TEMPLATE_CODE_CONF } from '../HomePanel';
|
||||||
|
import css from './RandomUnit.module.less';
|
||||||
|
|
||||||
const SpottableComponent = Spottable("div");
|
const SpottableComponent = Spottable("div");
|
||||||
|
|
||||||
@@ -416,6 +436,16 @@ export default function RandomUnit({
|
|||||||
}
|
}
|
||||||
}, [dispatch, entryMenu, nowMenu, topContentsLogInfo]);
|
}, [dispatch, entryMenu, nowMenu, topContentsLogInfo]);
|
||||||
|
|
||||||
|
//통합로그
|
||||||
|
useEffect(() => {
|
||||||
|
dispatch(
|
||||||
|
sendLogTotalRecommend({
|
||||||
|
contextName: LOG_CONTEXT_NAME.HOME,
|
||||||
|
messageId: LOG_MESSAGE_ID.BANNER,
|
||||||
|
})
|
||||||
|
);
|
||||||
|
}, []);
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (bannerData) {
|
if (bannerData) {
|
||||||
setRandomData(bannerDetailInfos[randomNumber]);
|
setRandomData(bannerDetailInfos[randomNumber]);
|
||||||
|
|||||||
@@ -53,7 +53,9 @@ import useDebugKey from '../../hooks/useDebugKey';
|
|||||||
import usePrevious from '../../hooks/usePrevious';
|
import usePrevious from '../../hooks/usePrevious';
|
||||||
import {
|
import {
|
||||||
ACTIVE_POPUP,
|
ACTIVE_POPUP,
|
||||||
|
LOG_CONTEXT_NAME,
|
||||||
LOG_MENU,
|
LOG_MENU,
|
||||||
|
LOG_MESSAGE_ID,
|
||||||
panel_names,
|
panel_names,
|
||||||
} from '../../utils/Config';
|
} from '../../utils/Config';
|
||||||
import { $L } from '../../utils/helperMethods';
|
import { $L } from '../../utils/helperMethods';
|
||||||
@@ -144,8 +146,8 @@ const HomePanel = ({ isOnTop }) => {
|
|||||||
if (nowMenu === "Home/Top") {
|
if (nowMenu === "Home/Top") {
|
||||||
dispatch(
|
dispatch(
|
||||||
sendLogTotalRecommend({
|
sendLogTotalRecommend({
|
||||||
messageId: "AL_HOME_SHOWN",
|
messageId: LOG_MESSAGE_ID.HOME,
|
||||||
contextName: "shoptime.home",
|
contextName: LOG_CONTEXT_NAME.HOME,
|
||||||
})
|
})
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user