Showing
1 changed file
with
7 additions
and
10 deletions
| @@ -88,8 +88,7 @@ export struct OperRowListView { | @@ -88,8 +88,7 @@ export struct OperRowListView { | ||
| 88 | @State dialogController: CustomDialogController | null = null; | 88 | @State dialogController: CustomDialogController | null = null; |
| 89 | 89 | ||
| 90 | async aboutToAppear() { | 90 | async aboutToAppear() { |
| 91 | - console.info(TAG, '22222----', this.styleType) | ||
| 92 | - console.info(TAG, '3333----', this.needLike) | 91 | + console.info(TAG, 'this.needLike', this.needLike) |
| 93 | this.handleStyle() | 92 | this.handleStyle() |
| 94 | this.onDetailUpdated() | 93 | this.onDetailUpdated() |
| 95 | EmitterUtils.receiveEvent(EmitterEventId.AUDIO_CHANGE_STATUS, (val: number | string | undefined) => { | 94 | EmitterUtils.receiveEvent(EmitterEventId.AUDIO_CHANGE_STATUS, (val: number | string | undefined) => { |
| @@ -108,7 +107,7 @@ export struct OperRowListView { | @@ -108,7 +107,7 @@ export struct OperRowListView { | ||
| 108 | } | 107 | } |
| 109 | 108 | ||
| 110 | async onDetailUpdated() { | 109 | async onDetailUpdated() { |
| 111 | - console.info(TAG, '111111----', this.styleType) | 110 | + console.info(TAG, 'this.styleType', this.styleType) |
| 112 | this.handleStyle() | 111 | this.handleStyle() |
| 113 | if (!this.contentDetailData) { | 112 | if (!this.contentDetailData) { |
| 114 | return | 113 | return |
| @@ -380,7 +379,7 @@ export struct OperRowListView { | @@ -380,7 +379,7 @@ export struct OperRowListView { | ||
| 380 | { | 379 | { |
| 381 | contentId: this.contentDetailData?.newsId + '', | 380 | contentId: this.contentDetailData?.newsId + '', |
| 382 | contentType: this.contentDetailData?.newsType + '', | 381 | contentType: this.contentDetailData?.newsType + '', |
| 383 | - contentRelId: this.contentDetailData?.reLInfo?.relId + '', | 382 | + contentRelId: this.contentDetailData?.reLInfo?.relId || '' + '', |
| 384 | } | 383 | } |
| 385 | ] | 384 | ] |
| 386 | } | 385 | } |
| @@ -397,7 +396,6 @@ export struct OperRowListView { | @@ -397,7 +396,6 @@ export struct OperRowListView { | ||
| 397 | * 收藏、取消收藏 | 396 | * 收藏、取消收藏 |
| 398 | */ | 397 | */ |
| 399 | async toggleCollectStatus() { | 398 | async toggleCollectStatus() { |
| 400 | - console.log(TAG, '收藏点击') | ||
| 401 | // 未登录,跳转登录 | 399 | // 未登录,跳转登录 |
| 402 | const user_id = await SPHelper.default.get(SpConstants.USER_ID, '') | 400 | const user_id = await SPHelper.default.get(SpConstants.USER_ID, '') |
| 403 | console.log(TAG, '收藏点击,登录', user_id) | 401 | console.log(TAG, '收藏点击,登录', user_id) |
| @@ -411,15 +409,13 @@ export struct OperRowListView { | @@ -411,15 +409,13 @@ export struct OperRowListView { | ||
| 411 | contentList: [{ | 409 | contentList: [{ |
| 412 | contentId: this.contentDetailData?.newsId + '', | 410 | contentId: this.contentDetailData?.newsId + '', |
| 413 | contentType: this.contentDetailData?.newsType + '', | 411 | contentType: this.contentDetailData?.newsType + '', |
| 414 | - relType: this.contentDetailData?.reLInfo?.relType + '', | ||
| 415 | - contentRelId: this.contentDetailData?.reLInfo?.relId + '', | 412 | + relType: this.contentDetailData?.reLInfo?.relType || '' + '', |
| 413 | + contentRelId: this.contentDetailData?.reLInfo?.relId || '' + '', | ||
| 416 | }], | 414 | }], |
| 417 | 415 | ||
| 418 | } | 416 | } |
| 419 | - // console.log(TAG, '收藏点击', JSON.stringify(params)) | 417 | + console.log(TAG, '收藏点击', JSON.stringify(params)) |
| 420 | PageRepository.postExecuteCollectRecord(params).then(res => { | 418 | PageRepository.postExecuteCollectRecord(params).then(res => { |
| 421 | - console.log(TAG, '收藏点击 res', JSON.stringify(res)) | ||
| 422 | - console.log(TAG, '收藏点击 this.newsStatusOfUser', JSON.stringify(this.newsStatusOfUser)) | ||
| 423 | if (this.newsStatusOfUser) { | 419 | if (this.newsStatusOfUser) { |
| 424 | this.newsStatusOfUser.collectStatus = this.newsStatusOfUser?.collectStatus === 1 ? 0 : 1 | 420 | this.newsStatusOfUser.collectStatus = this.newsStatusOfUser?.collectStatus === 1 ? 0 : 1 |
| 425 | if (this.newsStatusOfUser.collectStatus === 1) { | 421 | if (this.newsStatusOfUser.collectStatus === 1) { |
| @@ -427,6 +423,7 @@ export struct OperRowListView { | @@ -427,6 +423,7 @@ export struct OperRowListView { | ||
| 427 | } | 423 | } |
| 428 | this.queryContentInteractCount() | 424 | this.queryContentInteractCount() |
| 429 | } | 425 | } |
| 426 | + console.log(TAG, '收藏点击 this.newsStatusOfUser', JSON.stringify(this.newsStatusOfUser)) | ||
| 430 | }) | 427 | }) |
| 431 | 428 | ||
| 432 | } | 429 | } |
-
Please register or login to post a comment