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
张善主
2024-04-15 14:25:08 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
21d5b5c1089a938ce32d31fecb4f07e9a6b9b728
21d5b5c1
1 parent
a7ea0cd7
feat(图集/动态):跳转逻辑
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
75 additions
and
0 deletions
sight_harmony/commons/wdRouter/src/main/ets/router/Action2Page.ets
sight_harmony/commons/wdRouter/src/main/ets/router/WDRouterPage.ets
sight_harmony/features/wdComponent/src/main/ets/constants/ContentConstants.ets
sight_harmony/features/wdComponent/src/main/ets/utils/ProcessUtils.ets
sight_harmony/commons/wdRouter/src/main/ets/router/Action2Page.ets
View file @
21d5b5c
...
...
@@ -53,6 +53,12 @@ export function registerRouter() {
return WDRouterPage.detailPlayLivePage
} else if (action.params?.detailPageType == 7 || action.params?.detailPageType == 8) {
return WDRouterPage.detailVideoListPage
}else if(action.params?.detailPageType == 9){
//图集详情页
return WDRouterPage.detailVideoListPage
}else if(action.params?.detailPageType == 14 || action.params?.detailPageType == 15){
//动态详情页
return WDRouterPage.dynamicDetailPage
} else if (action.params?.detailPageType == 17) {
return WDRouterPage.multiPictureDetailPage
} else if (action.params?.detailPageType == 13) {
...
...
sight_harmony/commons/wdRouter/src/main/ets/router/WDRouterPage.ets
View file @
21d5b5c
...
...
@@ -45,6 +45,8 @@ export class WDRouterPage {
static multiPictureDetailPage = new WDRouterPage("phone", "ets/pages/detail/MultiPictureDetailPage");
// 音乐详情页
static audioDetail = new WDRouterPage("phone", "ets/pages/detail/AudioDetail");
// 动态详情页
static dynamicDetailPage = new WDRouterPage("phone", "ets/pages/detail/DynamicDetailPage");
static loginPage = new WDRouterPage("wdLogin", "ets/pages/login/LoginPage");
static forgetPasswordPage = new WDRouterPage("wdLogin", "ets/pages/login/ForgetPasswordPage");
//我的 预约
...
...
sight_harmony/features/wdComponent/src/main/ets/constants/ContentConstants.ets
View file @
21d5b5c
...
...
@@ -21,7 +21,23 @@ export class ContentConstants {
*/
static readonly TYPE_TELETEXT: string = "8";
/**
* 9:图集
*/
static readonly TYPE_NINE: string = "9";
/**
* 13:音频详情
*/
static readonly TYPE_AUDIO: string = "13";
/**
* 14:动态图文
*/
static readonly TYPE_FOURTEEN: string = "14";
/**
* 15:动态视频
*/
static readonly TYPE_FIFTEEN: string = "15";
}
\ No newline at end of file
...
...
sight_harmony/features/wdComponent/src/main/ets/utils/ProcessUtils.ets
View file @
21d5b5c
...
...
@@ -42,14 +42,65 @@ export class ProcessUtils {
// 图文详情,跳转h5
ProcessUtils.gotoWeb(content);
break;
//图集详情页
case ContentConstants.TYPE_NINE:
ProcessUtils.gotoAtlasDetailPage(content);
break;
case ContentConstants.TYPE_SPECIAL_TOPIC:
// 专题详情,跳转h5
ProcessUtils.gotoSpecialTopic(content);
break;
//动态详情页(动态图文)
case ContentConstants.TYPE_FOURTEEN:
//动态详情页(动态视频)
case ContentConstants.TYPE_FIFTEEN:
ProcessUtils.gotoDynamicDetailPage(content);
break;
default:
break;
}
}
/**
* 动态详情页(动态视频/动态图片)
* @param content
* */
private static gotoDynamicDetailPage(content: ContentDTO) {
let taskAction: Action = {
type: 'JUMP_DETAIL_PAGE',
params: {
detailPageType: 14,
contentID: content?.objectId,
extra:{
relType: content?.relType,
relId: content?.relId,
} as ExtraDTO
} as Params,
};
WDRouterRule.jumpWithAction(taskAction)
Logger.debug(TAG, `gotoDynamicDetailPage, ${content.objectId}`);
}
/**
* 图集详情页
* @param content
* */
private static gotoAtlasDetailPage(content: ContentDTO) {
let taskAction: Action = {
type: 'JUMP_DETAIL_PAGE',
params: {
detailPageType: 17,
contentID: content?.objectId,
extra:{
relType: content?.relType,
relId: content?.relId,
} as ExtraDTO
} as Params,
};
WDRouterRule.jumpWithAction(taskAction)
Logger.debug(TAG, `gotoAtlasDetailPage, ${content.objectId}`);
}
private static gotoSpecialTopic(content: ContentDTO) {
let taskAction: Action = {
type: 'JUMP_H5_BY_WEB_VIEW',
...
...
Please
register
or
login
to post a comment