Toggle navigation
Toggle navigation
This project
Loading...
Sign in
developOne
/
harmonyPool
Go to a project
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
zhanglun_wd
2024-06-12 17:31:32 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
212cd79936f2c3a4cdac69ef2aa1b825ae5b2d2f
212cd799
1 parent
5772a57f
埋点bug修复
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
3 deletions
sight_harmony/features/wdComponent/src/main/ets/components/page/TopNavigationComponentNew.ets
sight_harmony/features/wdComponent/src/main/ets/components/search/FirstTabTopSearchComponent.ets
sight_harmony/features/wdTracking/src/main/ets/tracking/TrackingButton.ets
sight_harmony/features/wdComponent/src/main/ets/components/page/TopNavigationComponentNew.ets
View file @
212cd79
...
...
@@ -256,6 +256,7 @@ export struct TopNavigationComponentNew {
'right': { 'anchor': '__container__', 'align': HorizontalAlign.End }
})
.onClick(() => {
Logger.info(TAG, `搜索按钮点击: 人民号`);
TrackingButton.searchClick(TrackConstants.PageName.Search, "PEOPLE")
let params = { 'tabName': "PEOPLE" } as Record<string, string>
WDRouterRule.jumpWithPage(WDRouterPage.searchPage, params)
...
...
@@ -487,9 +488,10 @@ export struct TopNavigationComponentNew {
}
updateCurrentTopNavSelectedIndex() {
Logger.info(TAG, `this.navItem 埋点参数topStyle: ${this.navItem.topStyle}`);
// 顶部tab埋点
if (CompUtils.is
Video
(this.navItem)) {
if (CompUtils.is
News
(this.navItem)) {
const tab = this.myChannelList[this.currentTopNavSelectedIndex]
Logger.info(TAG, `新闻tab埋点: ${JSON.stringify(tab)}`);
...
...
@@ -498,7 +500,7 @@ export struct TopNavigationComponentNew {
"tabName": tab.name,
"pageId": tab.pageId,
}
Tracking.event("home_page_tab_click
", params)
Tracking.event("home_page_tab_click", params)
} else if (CompUtils.isRMH(this.navItem)) {
const tab = this.topNavList[this.currentTopNavSelectedIndex]
Logger.info(TAG, `人民号tab埋点: ${JSON.stringify(tab)}`);
...
...
sight_harmony/features/wdComponent/src/main/ets/components/search/FirstTabTopSearchComponent.ets
View file @
212cd79
...
...
@@ -8,6 +8,7 @@ import { SPHelper } from 'wdKit/Index'
import { WDRouterPage, WDRouterRule } from 'wdRouter'
import { TrackingButton, TrackConstants } from 'wdTracking/Index'
import SearcherAboutDataModel from '../../model/SearcherAboutDataModel'
import { Logger } from 'wdKit';
const TAG = "FirstTabTopSearchComponent"
...
...
@@ -73,6 +74,7 @@ export struct FirstTabTopSearchComponent {
.backgroundImage($r('app.media.background_search'))
.backgroundImageSize(ImageSize.Cover)
.onClick(() => {
Logger.info(TAG, `搜索按钮点击: 新闻`);
TrackingButton.searchClick( TrackConstants.PageName.Search, "NEWS")
let params = { 'tabName': "NEWS" } as Record<string, string>
WDRouterRule.jumpWithPage(WDRouterPage.searchPage,params)
...
...
sight_harmony/features/wdTracking/src/main/ets/tracking/TrackingButton.ets
View file @
212cd79
...
...
@@ -22,7 +22,7 @@ export class TrackingButton {
params["pageId"] = pageId
params["pageName"] = pageName
Tracking.event("search_button_click
", params)
Tracking.event("search_button_click", params)
}
}
\ No newline at end of file
...
...
Please
register
or
login
to post a comment