Merged in feat/SW-2340-aa-tracking-my-stay-pageview- (pull request #2133)
feat: SW-2340 Implemented tracking on my-stay, webview my-stay and receipt page * feat: SW-2340 Implemented tracking on my-stay, webview my-stay and receipt page * feat: SW-2340 Updated webview tracking * feat: SW-2340 Updated receipt tracking Approved-by: Linus Flood
This commit is contained in:
@@ -39,6 +39,8 @@ import { parseRefId } from "@/utils/refId"
|
|||||||
import { isValidSession } from "@/utils/session"
|
import { isValidSession } from "@/utils/session"
|
||||||
import { getCurrentWebUrl } from "@/utils/url"
|
import { getCurrentWebUrl } from "@/utils/url"
|
||||||
|
|
||||||
|
import Tracking from "./tracking"
|
||||||
|
|
||||||
import styles from "./page.module.css"
|
import styles from "./page.module.css"
|
||||||
|
|
||||||
import { BreakfastPackageEnum } from "@/types/enums/breakfast"
|
import { BreakfastPackageEnum } from "@/types/enums/breakfast"
|
||||||
@@ -256,6 +258,7 @@ export default async function MyStay({
|
|||||||
</div>
|
</div>
|
||||||
</main>
|
</main>
|
||||||
<SidePeek />
|
<SidePeek />
|
||||||
|
<Tracking />
|
||||||
</MyStayProvider>
|
</MyStayProvider>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,23 @@
|
|||||||
|
import TrackingSDK from "@/components/TrackingSDK"
|
||||||
|
import { getLang } from "@/i18n/serverContext"
|
||||||
|
|
||||||
|
import {
|
||||||
|
TrackingChannelEnum,
|
||||||
|
type TrackingSDKPageData,
|
||||||
|
} from "@/types/components/tracking"
|
||||||
|
|
||||||
|
export default function Tracking() {
|
||||||
|
const lang = getLang()
|
||||||
|
|
||||||
|
const pageTrackingData: TrackingSDKPageData = {
|
||||||
|
channel: TrackingChannelEnum.hotels,
|
||||||
|
domainLanguage: lang,
|
||||||
|
pageId: "my-stay",
|
||||||
|
pageName: `hotelreservation|my-stay`,
|
||||||
|
pageType: "bookingmystaypage",
|
||||||
|
siteSections: `hotelreservation|my-stay`,
|
||||||
|
siteVersion: "new-web",
|
||||||
|
}
|
||||||
|
|
||||||
|
return <TrackingSDK pageData={pageTrackingData} />
|
||||||
|
}
|
||||||
@@ -39,6 +39,8 @@ import { parseRefId } from "@/utils/refId"
|
|||||||
import { isValidSession } from "@/utils/session"
|
import { isValidSession } from "@/utils/session"
|
||||||
import { getCurrentWebUrl } from "@/utils/url"
|
import { getCurrentWebUrl } from "@/utils/url"
|
||||||
|
|
||||||
|
import Tracking from "./tracking"
|
||||||
|
|
||||||
import styles from "./page.module.css"
|
import styles from "./page.module.css"
|
||||||
|
|
||||||
import { BreakfastPackageEnum } from "@/types/enums/breakfast"
|
import { BreakfastPackageEnum } from "@/types/enums/breakfast"
|
||||||
@@ -259,6 +261,7 @@ export default async function MyStay({
|
|||||||
</div>
|
</div>
|
||||||
</main>
|
</main>
|
||||||
<SidePeek />
|
<SidePeek />
|
||||||
|
<Tracking />
|
||||||
</MyStayProvider>
|
</MyStayProvider>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,23 @@
|
|||||||
|
import TrackingSDK from "@/components/TrackingSDK"
|
||||||
|
import { getLang } from "@/i18n/serverContext"
|
||||||
|
|
||||||
|
import {
|
||||||
|
TrackingChannelEnum,
|
||||||
|
type TrackingSDKPageData,
|
||||||
|
} from "@/types/components/tracking"
|
||||||
|
|
||||||
|
export default function Tracking() {
|
||||||
|
const lang = getLang()
|
||||||
|
|
||||||
|
const pageTrackingData: TrackingSDKPageData = {
|
||||||
|
channel: TrackingChannelEnum.hotels,
|
||||||
|
domainLanguage: lang,
|
||||||
|
pageId: "my-stay",
|
||||||
|
pageName: `webview|hotelreservation|my-stay`,
|
||||||
|
pageType: "bookingmystaypage",
|
||||||
|
siteSections: `webview|hotelreservation|my-stay`,
|
||||||
|
siteVersion: "new-web",
|
||||||
|
}
|
||||||
|
|
||||||
|
return <TrackingSDK pageData={pageTrackingData} />
|
||||||
|
}
|
||||||
@@ -27,6 +27,7 @@ import accessBooking, {
|
|||||||
import Footer from "./Footer"
|
import Footer from "./Footer"
|
||||||
import Specification from "./Specification"
|
import Specification from "./Specification"
|
||||||
import Total from "./Total"
|
import Total from "./Total"
|
||||||
|
import Tracking from "./tracking"
|
||||||
|
|
||||||
import styles from "./receipt.module.css"
|
import styles from "./receipt.module.css"
|
||||||
|
|
||||||
@@ -178,6 +179,7 @@ export async function Receipt({ refId }: { refId: string }) {
|
|||||||
<hr className={styles.divider} />
|
<hr className={styles.divider} />
|
||||||
|
|
||||||
<Footer booking={maskedBooking} room={room} />
|
<Footer booking={maskedBooking} room={room} />
|
||||||
|
<Tracking />
|
||||||
</main>
|
</main>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,23 @@
|
|||||||
|
import TrackingSDK from "@/components/TrackingSDK"
|
||||||
|
import { getLang } from "@/i18n/serverContext"
|
||||||
|
|
||||||
|
import {
|
||||||
|
TrackingChannelEnum,
|
||||||
|
type TrackingSDKPageData,
|
||||||
|
} from "@/types/components/tracking"
|
||||||
|
|
||||||
|
export default function Tracking() {
|
||||||
|
const lang = getLang()
|
||||||
|
|
||||||
|
const pageTrackingData: TrackingSDKPageData = {
|
||||||
|
channel: TrackingChannelEnum.hotels,
|
||||||
|
domainLanguage: lang,
|
||||||
|
pageId: "receipt",
|
||||||
|
pageName: `hotelreservation|my-stay|receipt`,
|
||||||
|
pageType: "bookingreceiptpage",
|
||||||
|
siteSections: `hotelreservation|my-stay|receipt`,
|
||||||
|
siteVersion: "new-web",
|
||||||
|
}
|
||||||
|
|
||||||
|
return <TrackingSDK pageData={pageTrackingData} />
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user