TItemCard log test
This commit is contained in:
@@ -1599,7 +1599,7 @@ export const sendLogTotalRecommend = (params) => (dispatch, getState) => {
|
||||
|
||||
const logCreateTime = new Date().toISOString();
|
||||
|
||||
console.log("#params", params);
|
||||
// console.log("#params", params);
|
||||
|
||||
const newParams = {
|
||||
...params,
|
||||
|
||||
@@ -7,7 +7,7 @@ import React, {
|
||||
} from 'react';
|
||||
|
||||
import classNames from 'classnames';
|
||||
import { useSelector } from 'react-redux';
|
||||
import { useDispatch, useSelector } from 'react-redux';
|
||||
|
||||
import Spottable from '@enact/spotlight/Spottable';
|
||||
|
||||
@@ -27,6 +27,7 @@ import {
|
||||
} from '../../utils/helperMethods';
|
||||
import CustomImage from '../CustomImage/CustomImage';
|
||||
import css from './TItemCard.module.less';
|
||||
import { sendLogTotalRecommend } from "../../actions/logActions";
|
||||
|
||||
const SpottableComponent = Spottable("div");
|
||||
|
||||
@@ -79,6 +80,7 @@ export default memo(function TItemCard({
|
||||
lastLabel,
|
||||
...rest
|
||||
}) {
|
||||
const dispatch = useDispatch();
|
||||
const [defaultImage, setDefaultImage] = useState(null);
|
||||
const countryCode = useSelector((state) => state.common.httpHeader.cntry_cd);
|
||||
|
||||
@@ -115,6 +117,32 @@ export default memo(function TItemCard({
|
||||
if (onClick) {
|
||||
onClick(e);
|
||||
}
|
||||
|
||||
|
||||
|
||||
const params = {
|
||||
contextName: "",
|
||||
messageId: "",
|
||||
shelfLocation: "",
|
||||
shelfId: "",
|
||||
shelfTitle: "",
|
||||
productId: productId,
|
||||
productTitle: productName,
|
||||
partner: "",
|
||||
brand: "",
|
||||
price: originalPrice,
|
||||
discount: discountRate,
|
||||
locaiton: "",
|
||||
category: catNm,
|
||||
}
|
||||
|
||||
dispatch(sendLogTotalRecommend(
|
||||
...params
|
||||
))
|
||||
|
||||
|
||||
|
||||
|
||||
},
|
||||
[onClick, disabled]
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user