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-29 11:00:42 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
36de50cc00693122c36a0568d72bfd95c4662cf5
36de50cc
1 parent
c328c349
feat(动态):评论model重新创建
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
14 deletions
sight_harmony/features/wdComponent/src/main/ets/components/DynamicDetailComponent.ets
sight_harmony/features/wdComponent/src/main/ets/components/DynamicDetailComponent.ets
View file @
36de50c
...
...
@@ -53,7 +53,7 @@ export struct DynamicDetailComponent {
//跳转
private mJumpInfo: ContentDTO = {} as ContentDTO;
@State publishCommentModel: publishCommentModel = new publishCommentModel()
async aboutToAppear() {
await this.getContentDetailData()
...
...
@@ -364,7 +364,15 @@ export struct DynamicDetailComponent {
if (this.contentDetailData?.openComment) {
Divider().strokeWidth(6).color('#f5f5f5')
CommentComponent({
publishCommentModel: this.publishCommentModel
publishCommentModel: {
targetId: String(this.contentDetailData?.newsId || ''),
targetRelId: this.contentDetailData?.reLInfo?.relId,
targetTitle: this.contentDetailData?.newsTitle,
targetRelType: this.contentDetailData?.reLInfo?.relType,
targetRelObjectId: String(this.contentDetailData?.reLInfo?.relObjectId),
keyArticle: String(this.contentDetailData?.keyArticle),
targetType: String(this.contentDetailData?.newsType),
} as publishCommentModel
})
}
Blank().layoutWeight(1)
...
...
@@ -379,7 +387,15 @@ export struct DynamicDetailComponent {
OperRowListView({ contentDetailData: this.contentDetailData
,interactData:this.interactDataDTO
,newsStatusOfUser:this.newsStatusOfUser
,publishCommentModel: this.publishCommentModel
,publishCommentModel: {
targetId: String(this.contentDetailData?.newsId || ''),
targetRelId: this.contentDetailData?.reLInfo?.relId,
targetTitle: this.contentDetailData?.newsTitle,
targetRelType: this.contentDetailData?.reLInfo?.relType,
targetRelObjectId: String(this.contentDetailData?.reLInfo?.relObjectId),
keyArticle: String(this.contentDetailData?.keyArticle),
targetType: String(this.contentDetailData?.newsType),
} as publishCommentModel
,needLike:false})
}
}
...
...
@@ -399,17 +415,6 @@ export struct DynamicDetailComponent {
} catch (exception) {
console.log('请求失败',JSON.stringify(exception))
}
if (this.contentDetailData.openComment) {
this.publishCommentModel = {
targetId: String(this.contentDetailData?.newsId || ''),
targetRelId: this.contentDetailData?.reLInfo?.relId,
targetTitle: this.contentDetailData?.newsTitle,
targetRelType: this.contentDetailData?.reLInfo?.relType,
targetRelObjectId: String(this.contentDetailData?.reLInfo?.relObjectId),
keyArticle: String(this.contentDetailData?.keyArticle),
targetType: String(this.contentDetailData?.newsType),
} as publishCommentModel
}
this.getBatchAttentionStatus()
this.getInteractDataStatus()
this.makeJumpInfo()
...
...
Please
register
or
login
to post a comment