[Log] IF-LGSP-LOG-100, adjust params (RollingUnit.jsx, RandomUnit.jsx)
This commit is contained in:
@@ -102,8 +102,27 @@ export default function RollingUnit({
|
||||
const rollingDataRef = useRef(rollingData);
|
||||
|
||||
const topContentsLogInfo = useMemo(() => {
|
||||
if (curationId && curtNm) {
|
||||
if (rollingDataRef.current) {
|
||||
const currentRollingData = rollingDataRef.current[startIndex];
|
||||
|
||||
let contId, contNm;
|
||||
|
||||
switch (currentRollingData?.shptmBanrTpCd) {
|
||||
case "DSP00301":
|
||||
case "DSP00302":
|
||||
contId = currentRollingData?.showId;
|
||||
contNm = currentRollingData?.showNm;
|
||||
break;
|
||||
case "DSP00303":
|
||||
contId = currentRollingData?.shptmLnkTpCd;
|
||||
contNm = currentRollingData?.shptmLnkTpNm;
|
||||
break;
|
||||
default:
|
||||
contId = currentRollingData?.prdtId;
|
||||
contNm = currentRollingData?.prdtNm;
|
||||
break;
|
||||
}
|
||||
|
||||
return {
|
||||
banrNo: `${currentRollingData?.banrDpOrd}`,
|
||||
banrTpNm: currentRollingData?.vtctpYn
|
||||
@@ -111,8 +130,8 @@ export default function RollingUnit({
|
||||
? "Vertical"
|
||||
: "Horizontal"
|
||||
: "",
|
||||
contId: curationId,
|
||||
contNm: curtNm,
|
||||
contId,
|
||||
contNm,
|
||||
contTpNm: currentRollingData?.shptmBanrTpNm ?? "",
|
||||
dspyTpNm: bannerDataRef.current?.shptmDspyTpNm ?? "",
|
||||
expsOrd: bannerDataRef.current?.banrLctnNo ?? "",
|
||||
@@ -124,7 +143,7 @@ export default function RollingUnit({
|
||||
}
|
||||
|
||||
return {};
|
||||
}, [curationId, curtNm, shptmTmplCd, startIndex]);
|
||||
}, [shptmTmplCd, startIndex]);
|
||||
|
||||
useEffect(() => {
|
||||
if (savedIndex !== undefined) {
|
||||
|
||||
Reference in New Issue
Block a user