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-05-21 18:25:24 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
fe75415c0992d8a43b35d2768cd87f52f9596602
fe75415c
1 parent
a1bea7c5
进入人民号“赣州消防”中的图集详情页,点击进入任意图集内容“底部互动入口进行收藏,点击收藏icon无反应
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
6 deletions
sight_harmony/features/wdComponent/src/main/ets/components/view/LikeComponent.ets
sight_harmony/features/wdComponent/src/main/ets/components/view/OperRowListView.ets
sight_harmony/features/wdComponent/src/main/ets/components/view/LikeComponent.ets
View file @
fe75415
...
...
@@ -20,7 +20,7 @@ export struct LikeComponent {
@State likesStyle: number = this.contentDetailData.likesStyle // 赞样式 1红心(点赞) 2大拇指(祈福) 3蜡烛(默哀) 4置空
@State likeStatus: boolean = false
viewModel: LikeViewModel = new LikeViewModel()
@Prop data: Record<string, string>
@Prop
@Watch('onDataUpdated')
data: Record<string, string>
enableBtn = true
componentType: number = 1 //1: 底部栏目样式 2: 新闻页中间位置样式 3:动态Tab内容下的互动入口
styleType: number = 1 //1: 白色背景(图文底部栏) 2: 黑色背景(图集底部栏) 3 透明背景
...
...
@@ -35,12 +35,18 @@ export struct LikeComponent {
// this.data['channelId'] = "2059" //必须
// this.data['status'] = "1"
aboutToAppear(): void {
aboutToAppear() {
this.onDataUpdated()
}
onDataUpdated() {
if (this.data) {
//获取点赞状态
this.getLikeStatus()
//获取点赞数
this.getLikeCount()
if (this.data['channelId'] !== 'undefined') {
//获取点赞状态
this.getLikeStatus()
//获取点赞数
this.getLikeCount()
}
}
}
...
...
sight_harmony/features/wdComponent/src/main/ets/components/view/OperRowListView.ets
View file @
fe75415
...
...
@@ -40,6 +40,7 @@ const TAG = 'OperRowListView';
operationButtonList: ['comment', 'like', 'collect', 'listen', 'share']
})
*/
@Preview
@Component
export struct OperRowListView {
...
...
Please
register
or
login
to post a comment