@polyvharmony/live-scenes-sdk 1.3.1 → 1.3.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/BuildProfile.d.ets +2 -2
- package/BuildProfile.js +1 -1
- package/CHANGELOG.md +12 -0
- package/ResourceTable.txt +72 -72
- package/oh-package.json5 +1 -1
- package/package.json +1 -1
- package/src/main/ets/modules/chatroom/PLVChatroomManager.d.ets +32 -17
- package/src/main/ets/modules/chatroom/PLVChatroomManager.js +229 -198
- package/src/main/ets/modules/chatroom/handler/PLVChatroomBaseHandler.d.ets +1 -1
- package/src/main/ets/modules/chatroom/playback/PLVChatPlaybackManager.js +1 -4
- package/src/main/ets/modules/chatroom/playback/model/PLVChatPlaybackDataVO.d.ets +1 -0
- package/src/main/ets/modules/chatroom/playback/model/PLVChatPlaybackDataVO.js +3 -0
- package/src/main/ets/modules/i18n/PLVI18NDataMapper.d.ets +5 -5
- package/src/main/ets/modules/i18n/PLVI18NDataMapper.js +20 -20
- package/src/main/ets/modules/i18n/PLVLanguageManager.js +8 -8
- package/src/main/ets/modules/interact/PLVInteractManager.d.ets +6 -6
- package/src/main/ets/modules/interact/PLVInteractManager.js +12 -12
- package/src/main/ets/modules/interact/PLVInteractWeb.d.ets +13 -13
- package/src/main/ets/modules/interact/PLVInteractWeb.js +148 -148
- package/src/main/ets/modules/interact/invitePoster/PLVInteractInvitePoster.d.ets +1 -1
- package/src/main/ets/modules/interact/invitePoster/PLVInteractInvitePoster.js +34 -34
- package/src/main/ets/modules/interact/model/PLVFunctionSwitchBean.d.ets +1 -1
- package/src/main/ets/modules/interact/model/PLVFunctionSwitchBean.js +6 -6
- package/src/main/ets/modules/interact/pushcard/PLVPushCardManager.d.ets +2 -2
- package/src/main/ets/modules/interact/pushcard/PLVPushCardManager.js +21 -21
- package/src/main/ets/modules/interact/pushcard/model/PLVShowPushCardEvent.d.ets +1 -1
- package/src/main/ets/modules/interact/pushcard/model/PLVShowPushCardEvent.js +2 -2
- package/src/main/ets/modules/interact/pushcard/repo/PLVCardLookTimeLocalRepository.d.ets +3 -3
- package/src/main/ets/modules/interact/pushcard/repo/PLVCardLookTimeLocalRepository.js +6 -6
- package/src/main/ets/modules/interact/redpack/model/PLVHistoryRedPaperEvent.js +7 -7
- package/src/main/ets/modules/interact/redpack/model/PLVRedPaperEvent.js +7 -7
- package/src/main/ets/modules/linkmic/PLVLinkMicManager.d.ets +14 -14
- package/src/main/ets/modules/linkmic/PLVLinkMicManager.js +37 -37
- package/src/main/ets/modules/linkmic/di/PLVLinkMicModule.js +11 -11
- package/src/main/ets/modules/linkmic/mediator/PLVLinkMicMediator.d.ets +4 -4
- package/src/main/ets/modules/linkmic/mediator/PLVLinkMicMediator.js +14 -14
- package/src/main/ets/modules/linkmic/mediator/PLVLinkMicRTCEventCallback.d.ets +8 -8
- package/src/main/ets/modules/linkmic/mediator/PLVLinkMicRTCEventCallback.js +39 -39
- package/src/main/ets/modules/linkmic/model/PLVLinkMicRepo.d.ets +10 -10
- package/src/main/ets/modules/linkmic/model/PLVLinkMicRepo.js +69 -69
- package/src/main/ets/modules/linkmic/model/datasource/PLVLinkMicNetworkDataSource.d.ets +4 -4
- package/src/main/ets/modules/linkmic/model/datasource/PLVLinkMicNetworkDataSource.js +70 -70
- package/src/main/ets/modules/linkmic/model/vo/PLVLinkMicBitRate.d.ets +1 -1
- package/src/main/ets/modules/linkmic/model/vo/PLVLinkMicBitRate.js +3 -3
- package/src/main/ets/modules/linkmic/model/vo/PLVLinkMicBitRateEncodeParam.d.ets +1 -1
- package/src/main/ets/modules/linkmic/model/vo/PLVLinkMicBitRateEncodeParam.js +12 -12
- package/src/main/ets/modules/linkmic/model/vo/PLVLinkMicErrorEvent.d.ets +1 -1
- package/src/main/ets/modules/linkmic/model/vo/PLVLinkMicErrorEvent.js +3 -3
- package/src/main/ets/modules/linkmic/model/vo/PLVLinkMicInteractEvent.d.ets +1 -1
- package/src/main/ets/modules/linkmic/model/vo/PLVLinkMicInteractEvent.js +3 -3
- package/src/main/ets/modules/linkmic/model/vo/PLVLinkMicMode.js +3 -3
- package/src/main/ets/modules/linkmic/model/vo/PLVLinkMicPushResolutionRatio.d.ets +1 -1
- package/src/main/ets/modules/linkmic/model/vo/PLVLinkMicPushResolutionRatio.js +4 -4
- package/src/main/ets/modules/linkmic/model/vo/PLVLinkMicRTCType.js +3 -3
- package/src/main/ets/modules/linkmic/model/vo/PLVLinkMicState.js +6 -6
- package/src/main/ets/modules/linkmic/model/vo/PLVLinkMicVideoRenderParam.d.ets +1 -1
- package/src/main/ets/modules/linkmic/model/vo/PLVLinkMicVideoRenderParam.js +3 -3
- package/src/main/ets/modules/linkmic/model/vo/PLVLinkMicViewer.d.ets +1 -1
- package/src/main/ets/modules/linkmic/model/vo/PLVLinkMicViewer.js +5 -5
- package/src/main/ets/modules/linkmic/viewmodel/PLVLinkMicViewModel.d.ets +15 -15
- package/src/main/ets/modules/linkmic/viewmodel/PLVLinkMicViewModel.js +40 -40
- package/src/main/ets/modules/linkmic/viewmodel/usecase/LinkMicEncodeParamUseCase.d.ets +6 -6
- package/src/main/ets/modules/linkmic/viewmodel/usecase/LinkMicEncodeParamUseCase.js +15 -15
- package/src/main/ets/modules/linkmic/viewmodel/usecase/LinkMicHandleQueueOrderUseCase.d.ets +4 -4
- package/src/main/ets/modules/linkmic/viewmodel/usecase/LinkMicHandleQueueOrderUseCase.js +25 -25
- package/src/main/ets/modules/linkmic/viewmodel/usecase/LinkMicHandleRTCUseCase.d.ets +7 -7
- package/src/main/ets/modules/linkmic/viewmodel/usecase/LinkMicHandleRTCUseCase.js +19 -19
- package/src/main/ets/modules/linkmic/viewmodel/usecase/LinkMicHandleStateUseCase.d.ets +10 -10
- package/src/main/ets/modules/linkmic/viewmodel/usecase/LinkMicHandleStateUseCase.js +26 -26
- package/src/main/ets/modules/linkmic/viewmodel/usecase/LinkMicUpdateChannelViewerUseCase.d.ets +6 -6
- package/src/main/ets/modules/linkmic/viewmodel/usecase/LinkMicUpdateChannelViewerUseCase.js +135 -135
- package/src/main/ets/modules/linkmic/viewmodel/usecase/LinkMicViewLogUseCase.d.ets +1 -1
- package/src/main/ets/modules/linkmic/viewmodel/usecase/LinkMicViewLogUseCase.js +27 -27
- package/src/main/ets/modules/linkmic/viewmodel/usecase/PLVLinkMicUseCases.d.ets +1 -1
- package/src/main/ets/modules/linkmic/viewmodel/usecase/PLVLinkMicUseCases.js +7 -7
- package/src/main/ets/modules/linkmic/viewmodel/usecase/roles/guest/LinkMicGuestEncodeParamUseCase.d.ets +6 -6
- package/src/main/ets/modules/linkmic/viewmodel/usecase/roles/guest/LinkMicGuestEncodeParamUseCase.js +83 -83
- package/src/main/ets/modules/linkmic/viewmodel/usecase/roles/guest/LinkMicGuestHandleRTCUseCase.d.ets +7 -7
- package/src/main/ets/modules/linkmic/viewmodel/usecase/roles/guest/LinkMicGuestHandleRTCUseCase.js +42 -42
- package/src/main/ets/modules/linkmic/viewmodel/usecase/roles/guest/LinkMicGuestHandleStateUseCase.d.ets +10 -10
- package/src/main/ets/modules/linkmic/viewmodel/usecase/roles/guest/LinkMicGuestHandleStateUseCase.js +188 -188
- package/src/main/ets/modules/linkmic/viewmodel/usecase/roles/teacher/LinkMicTeacherEncodeParamUseCase.d.ets +6 -6
- package/src/main/ets/modules/linkmic/viewmodel/usecase/roles/teacher/LinkMicTeacherEncodeParamUseCase.js +83 -83
- package/src/main/ets/modules/linkmic/viewmodel/usecase/roles/teacher/LinkMicTeacherHandleRTCUseCase.d.ets +7 -7
- package/src/main/ets/modules/linkmic/viewmodel/usecase/roles/teacher/LinkMicTeacherHandleRTCUseCase.js +37 -37
- package/src/main/ets/modules/linkmic/viewmodel/usecase/roles/teacher/LinkMicTeacherHandleStateUseCase.d.ets +10 -10
- package/src/main/ets/modules/linkmic/viewmodel/usecase/roles/teacher/LinkMicTeacherHandleStateUseCase.js +128 -128
- package/src/main/ets/modules/linkmic/viewmodel/usecase/roles/viewer/LinkMicViewerEncodeParamUseCase.d.ets +6 -6
- package/src/main/ets/modules/linkmic/viewmodel/usecase/roles/viewer/LinkMicViewerEncodeParamUseCase.js +13 -13
- package/src/main/ets/modules/linkmic/viewmodel/usecase/roles/viewer/LinkMicViewerHandleRTCUseCase.d.ets +7 -7
- package/src/main/ets/modules/linkmic/viewmodel/usecase/roles/viewer/LinkMicViewerHandleRTCUseCase.js +53 -53
- package/src/main/ets/modules/linkmic/viewmodel/usecase/roles/viewer/LinkMicViewerHandleStateUseCase.d.ets +10 -10
- package/src/main/ets/modules/linkmic/viewmodel/usecase/roles/viewer/LinkMicViewerHandleStateUseCase.js +163 -163
- package/src/main/ets/modules/log/elog/PLVELogSender.d.ets +4 -4
- package/src/main/ets/modules/log/elog/PLVELogSender.js +17 -17
- package/src/main/ets/modules/log/elog/model/PLVELogDataBean.d.ets +1 -1
- package/src/main/ets/modules/log/elog/model/PLVELogDataBean.js +12 -12
- package/src/main/ets/modules/log/elog/model/PLVELogModuleConstants.js +8 -8
- package/src/main/ets/modules/login/PLVSceneLoginManager.d.ets +3 -3
- package/src/main/ets/modules/login/PLVSceneLoginManager.js +102 -102
- package/src/main/ets/modules/login/model/PLVChatDomainVO.d.ets +2 -2
- package/src/main/ets/modules/login/model/PLVChatDomainVO.js +4 -4
- package/src/main/ets/modules/login/model/PLVLiveChannelType.d.ets +1 -1
- package/src/main/ets/modules/login/model/PLVLiveChannelType.js +14 -14
- package/src/main/ets/modules/login/model/PLVLiveDetailVO.d.ets +2 -1
- package/src/main/ets/modules/login/model/PLVLiveDetailVO.js +14 -14
- package/src/main/ets/modules/login/model/PLVLiveStatus.d.ets +1 -1
- package/src/main/ets/modules/login/model/PLVLiveStatus.js +14 -14
- package/src/main/ets/modules/login/model/PLVLiveStatusVO.d.ets +2 -2
- package/src/main/ets/modules/login/model/PLVLiveStatusVO.js +10 -10
- package/src/main/ets/modules/login/model/PLVLoginLiveResult.d.ets +1 -1
- package/src/main/ets/modules/login/model/PLVLoginLiveResult.js +4 -4
- package/src/main/ets/modules/login/model/PLVLoginPlaybackResult.d.ets +1 -1
- package/src/main/ets/modules/login/model/PLVLoginPlaybackResult.js +5 -5
- package/src/main/ets/modules/login/model/PLVLoginType.d.ets +2 -2
- package/src/main/ets/modules/login/model/PLVLoginType.js +16 -16
- package/src/main/ets/modules/member/PLVMemberManager.d.ets +3 -3
- package/src/main/ets/modules/member/PLVMemberManager.js +10 -10
- package/src/main/ets/modules/member/di/PLVMemberModule.js +8 -8
- package/src/main/ets/modules/member/mediator/PLVMemberMediator.d.ets +3 -3
- package/src/main/ets/modules/member/mediator/PLVMemberMediator.js +9 -9
- package/src/main/ets/modules/member/model/PLVMemberRepo.d.ets +2 -2
- package/src/main/ets/modules/member/model/PLVMemberRepo.js +7 -7
- package/src/main/ets/modules/member/model/datasource/PLVMemberNetworkDataSource.d.ets +2 -2
- package/src/main/ets/modules/member/model/datasource/PLVMemberNetworkDataSource.js +11 -11
- package/src/main/ets/modules/member/model/vo/PLVMemberChannelViewer.d.ets +1 -1
- package/src/main/ets/modules/member/model/vo/PLVMemberChannelViewer.js +3 -3
- package/src/main/ets/modules/member/model/vo/PLVMemberErrorEvent.d.ets +1 -1
- package/src/main/ets/modules/member/model/vo/PLVMemberErrorEvent.js +3 -3
- package/src/main/ets/modules/member/viewmodel/PLVMemberViewModel.d.ets +3 -3
- package/src/main/ets/modules/member/viewmodel/PLVMemberViewModel.js +15 -15
- package/src/main/ets/modules/member/viewmodel/usecase/MemberHandleStateUseCase.d.ets +6 -6
- package/src/main/ets/modules/member/viewmodel/usecase/MemberHandleStateUseCase.js +16 -16
- package/src/main/ets/modules/member/viewmodel/usecase/MemberUpdateViewerUseCase.d.ets +9 -9
- package/src/main/ets/modules/member/viewmodel/usecase/MemberUpdateViewerUseCase.js +21 -21
- package/src/main/ets/modules/member/viewmodel/usecase/PLVMemberUseCases.d.ets +1 -1
- package/src/main/ets/modules/member/viewmodel/usecase/PLVMemberUseCases.js +3 -3
- package/src/main/ets/modules/member/viewmodel/usecase/roles/guest/MemberGuestHandleStateUseCase.d.ets +6 -6
- package/src/main/ets/modules/member/viewmodel/usecase/roles/guest/MemberGuestHandleStateUseCase.js +82 -82
- package/src/main/ets/modules/member/viewmodel/usecase/roles/guest/MemberGuestUpdateViewerUseCase.d.ets +9 -9
- package/src/main/ets/modules/member/viewmodel/usecase/roles/guest/MemberGuestUpdateViewerUseCase.js +219 -219
- package/src/main/ets/modules/member/viewmodel/usecase/roles/teacher/MemberTeacherHandleStateUseCase.d.ets +6 -6
- package/src/main/ets/modules/member/viewmodel/usecase/roles/teacher/MemberTeacherHandleStateUseCase.js +153 -153
- package/src/main/ets/modules/member/viewmodel/usecase/roles/teacher/MemberTeacherUpdateViewerUseCase.d.ets +9 -9
- package/src/main/ets/modules/member/viewmodel/usecase/roles/teacher/MemberTeacherUpdateViewerUseCase.js +219 -219
- package/src/main/ets/modules/net/PLVApiChatPlvNetApi.d.ets +10 -9
- package/src/main/ets/modules/net/PLVApiChatPlvNetApi.js +65 -53
- package/src/main/ets/modules/net/PLVApiPlvNetApi.d.ets +30 -30
- package/src/main/ets/modules/net/PLVApiPlvNetApi.js +164 -164
- package/src/main/ets/modules/net/PLVELogPlvNetApi.d.ets +2 -2
- package/src/main/ets/modules/net/PLVELogPlvNetApi.js +5 -5
- package/src/main/ets/modules/net/PLVLiveImagesVideoNetApi.d.ets +3 -3
- package/src/main/ets/modules/net/PLVLiveImagesVideoNetApi.js +19 -19
- package/src/main/ets/modules/net/PLVNGBPushApi.d.ets +2 -2
- package/src/main/ets/modules/net/PLVNGBPushApi.js +4 -4
- package/src/main/ets/modules/net/PLVRtasVideoNetApi.d.ets +2 -2
- package/src/main/ets/modules/net/PLVRtasVideoNetApi.js +4 -4
- package/src/main/ets/modules/net/vo/PLVNetworkQuality.js +8 -8
- package/src/main/ets/modules/player/PLVPlayerManager.d.ets +3 -3
- package/src/main/ets/modules/player/PLVPlayerManager.js +8 -8
- package/src/main/ets/modules/player/PLVPlayerMediator.d.ets +1 -1
- package/src/main/ets/modules/player/PLVPlayerMediator.js +8 -8
- package/src/main/ets/modules/player/playback/PLVPlaybackListType.js +4 -4
- package/src/main/ets/modules/player/playback/PLVPreviousListVO.js +8 -8
- package/src/main/ets/modules/player/playback/PLVPreviousManager.d.ets +5 -5
- package/src/main/ets/modules/player/playback/PLVPreviousManager.js +69 -69
- package/src/main/ets/modules/ppt/PLVPPTWeb.js +28 -28
- package/src/main/ets/modules/ppt/PLVPPTWebController.d.ets +6 -6
- package/src/main/ets/modules/ppt/PLVPPTWebController.js +94 -94
- package/src/main/ets/modules/product/PLVProductManager.d.ets +5 -5
- package/src/main/ets/modules/product/PLVProductManager.js +61 -61
- package/src/main/ets/modules/product/components/PLVProductControlWeb.d.ets +1 -1
- package/src/main/ets/modules/product/components/PLVProductControlWeb.js +34 -34
- package/src/main/ets/modules/product/components/PLVProductWeb.d.ets +1 -1
- package/src/main/ets/modules/product/components/PLVProductWeb.js +50 -50
- package/src/main/ets/modules/product/model/PLVProductContentBean.d.ets +1 -1
- package/src/main/ets/modules/product/model/PLVProductContentBean.js +17 -17
- package/src/main/ets/modules/product/model/PLVProductControlEvent.js +7 -7
- package/src/main/ets/modules/product/model/PLVProductDataBean.d.ets +1 -1
- package/src/main/ets/modules/product/model/PLVProductDataBean.js +16 -16
- package/src/main/ets/modules/redpack/PLVRedpackManager.d.ets +9 -9
- package/src/main/ets/modules/redpack/PLVRedpackManager.js +70 -70
- package/src/main/ets/modules/redpack/database/PLVRedpackCacheVO.d.ets +1 -1
- package/src/main/ets/modules/redpack/database/PLVRedpackCacheVO.js +14 -14
- package/src/main/ets/modules/redpack/database/PLVRedpackLocalDataSource.d.ets +4 -4
- package/src/main/ets/modules/redpack/database/PLVRedpackLocalDataSource.js +28 -28
- package/src/main/ets/modules/redpack/database/PLVRedpackOpenHelper.d.ets +4 -4
- package/src/main/ets/modules/redpack/database/PLVRedpackOpenHelper.js +6 -6
- package/src/main/ets/modules/reward/PLVRewardManager.d.ets +2 -2
- package/src/main/ets/modules/reward/PLVRewardManager.js +22 -22
- package/src/main/ets/modules/reward/model/PLVRewardPointVO.d.ets +1 -1
- package/src/main/ets/modules/reward/model/PLVRewardPointVO.js +3 -3
- package/src/main/ets/modules/reward/model/PLVRewardSettingVO.js +24 -24
- package/src/main/ets/modules/socket/PLVSocketManager.d.ets +8 -8
- package/src/main/ets/modules/socket/PLVSocketManager.js +101 -101
- package/src/main/ets/modules/socket/PLVSocketMediator.d.ets +7 -7
- package/src/main/ets/modules/socket/PLVSocketMediator.js +14 -14
- package/src/main/ets/modules/socket/model/PLVSocketUserBean.d.ets +5 -5
- package/src/main/ets/modules/socket/model/PLVSocketUserBean.js +27 -27
- package/src/main/ets/modules/socket/model/PLVUserType.js +15 -15
- package/src/main/ets/modules/socket/model/interact/PLVCallAppEvent.js +6 -6
- package/src/main/ets/modules/socket/model/redpack/RedPaperReceiveType.d.ets +4 -4
- package/src/main/ets/modules/socket/model/redpack/RedPaperReceiveType.js +20 -20
- package/src/main/ets/modules/streamer/PLVStreamerManager.d.ets +8 -8
- package/src/main/ets/modules/streamer/PLVStreamerManager.js +24 -24
- package/src/main/ets/modules/streamer/di/PLVStreamerModule.js +8 -8
- package/src/main/ets/modules/streamer/mediator/PLVStreamerMediator.d.ets +2 -2
- package/src/main/ets/modules/streamer/mediator/PLVStreamerMediator.js +5 -5
- package/src/main/ets/modules/streamer/model/PLVStreamerRepo.d.ets +8 -8
- package/src/main/ets/modules/streamer/model/PLVStreamerRepo.js +41 -41
- package/src/main/ets/modules/streamer/model/datasource/PLVStreamerLocalDataSource.d.ets +2 -2
- package/src/main/ets/modules/streamer/model/datasource/PLVStreamerLocalDataSource.js +10 -10
- package/src/main/ets/modules/streamer/model/datasource/PLVStreamerNetworkDataSource.d.ets +7 -7
- package/src/main/ets/modules/streamer/model/datasource/PLVStreamerNetworkDataSource.js +48 -48
- package/src/main/ets/modules/streamer/model/vo/PLVStreamerErrorEvent.d.ets +1 -1
- package/src/main/ets/modules/streamer/model/vo/PLVStreamerErrorEvent.js +3 -3
- package/src/main/ets/modules/streamer/model/vo/PLVStreamerMixActionVO.js +15 -15
- package/src/main/ets/modules/streamer/model/vo/PLVStreamerMixLayoutType.js +4 -4
- package/src/main/ets/modules/streamer/model/vo/PLVStreamerState.js +4 -4
- package/src/main/ets/modules/streamer/viewmodel/PLVStreamerViewModel.d.ets +8 -8
- package/src/main/ets/modules/streamer/viewmodel/PLVStreamerViewModel.js +25 -25
- package/src/main/ets/modules/streamer/viewmodel/usecase/PLVStreamerUseCases.d.ets +1 -1
- package/src/main/ets/modules/streamer/viewmodel/usecase/PLVStreamerUseCases.js +3 -3
- package/src/main/ets/modules/streamer/viewmodel/usecase/StreamerHandleStateUseCase.d.ets +2 -2
- package/src/main/ets/modules/streamer/viewmodel/usecase/StreamerHandleStateUseCase.js +8 -8
- package/src/main/ets/modules/streamer/viewmodel/usecase/StreamerMixStreamUseCase.d.ets +2 -2
- package/src/main/ets/modules/streamer/viewmodel/usecase/StreamerMixStreamUseCase.js +7 -7
- package/src/main/ets/modules/streamer/viewmodel/usecase/roles/guest/StreamerGuestHandleStateUseCase.d.ets +2 -2
- package/src/main/ets/modules/streamer/viewmodel/usecase/roles/guest/StreamerGuestHandleStateUseCase.js +42 -42
- package/src/main/ets/modules/streamer/viewmodel/usecase/roles/guest/StreamerGuestMixStreamUseCase.d.ets +2 -2
- package/src/main/ets/modules/streamer/viewmodel/usecase/roles/guest/StreamerGuestMixStreamUseCase.js +3 -3
- package/src/main/ets/modules/streamer/viewmodel/usecase/roles/teacher/StreamerTeacherHandleStateUseCase.d.ets +2 -2
- package/src/main/ets/modules/streamer/viewmodel/usecase/roles/teacher/StreamerTeacherHandleStateUseCase.js +42 -42
- package/src/main/ets/modules/streamer/viewmodel/usecase/roles/teacher/StreamerTeacherMixStreamUseCase.d.ets +2 -2
- package/src/main/ets/modules/streamer/viewmodel/usecase/roles/teacher/StreamerTeacherMixStreamUseCase.js +51 -51
- package/src/main/ets/modules/web/PLVSocketWebController.d.ets +2 -2
- package/src/main/ets/modules/web/PLVSocketWebController.js +66 -66
- package/src/main/ets/modules/web/PLVWebControllerManager.d.ets +2 -2
- package/src/main/ets/modules/web/PLVWebControllerManager.js +6 -6
- package/src/main/ets/modules/web/PLVWebParams.d.ets +1 -1
- package/src/main/ets/modules/web/PLVWebParams.js +22 -22
- package/src/main/ets/modules/web/qa/PLVQAWeb.d.ets +1 -1
- package/src/main/ets/modules/web/qa/PLVQAWeb.js +34 -34
- package/src/main/ets/modules/web/tuwen/PLVTuwenWeb.d.ets +1 -1
- package/src/main/ets/modules/web/tuwen/PLVTuwenWeb.js +37 -37
- package/src/main/module.json +1 -1
|
@@ -6,10 +6,10 @@ import { lateInit } from '@polyvharmony/media-player-sdk';
|
|
|
6
6
|
const TAG = '[PLVPPTWeb]';
|
|
7
7
|
const URL = 'https://player.polyv.net/resp/ppt-h5/latest/page/pptForMobile.html';
|
|
8
8
|
export class PLVPPTWeb extends ViewPU {
|
|
9
|
-
constructor(
|
|
10
|
-
super(
|
|
11
|
-
if (typeof
|
|
12
|
-
this.paramsGenerator_ =
|
|
9
|
+
constructor(l81, m81, n81, o81 = -1, p81 = undefined, q81) {
|
|
10
|
+
super(l81, n81, o81, q81);
|
|
11
|
+
if (typeof p81 === "function") {
|
|
12
|
+
this.paramsGenerator_ = p81;
|
|
13
13
|
}
|
|
14
14
|
this.controller = lateInit();
|
|
15
15
|
this.customUrl = URL;
|
|
@@ -17,32 +17,32 @@ export class PLVPPTWeb extends ViewPU {
|
|
|
17
17
|
this.pptBackgroundImg = '';
|
|
18
18
|
this.pptBackgroundImgWidth = '';
|
|
19
19
|
this.pptBackgroundColor = '';
|
|
20
|
-
this.setInitiallyProvidedValue(
|
|
20
|
+
this.setInitiallyProvidedValue(m81);
|
|
21
21
|
this.finalizeConstruction();
|
|
22
22
|
}
|
|
23
|
-
setInitiallyProvidedValue(
|
|
24
|
-
if (
|
|
25
|
-
this.controller =
|
|
23
|
+
setInitiallyProvidedValue(k81) {
|
|
24
|
+
if (k81.controller !== undefined) {
|
|
25
|
+
this.controller = k81.controller;
|
|
26
26
|
}
|
|
27
|
-
if (
|
|
28
|
-
this.customUrl =
|
|
27
|
+
if (k81.customUrl !== undefined) {
|
|
28
|
+
this.customUrl = k81.customUrl;
|
|
29
29
|
}
|
|
30
|
-
if (
|
|
31
|
-
this.url =
|
|
30
|
+
if (k81.url !== undefined) {
|
|
31
|
+
this.url = k81.url;
|
|
32
32
|
}
|
|
33
|
-
if (
|
|
34
|
-
this.pptBackgroundImg =
|
|
33
|
+
if (k81.pptBackgroundImg !== undefined) {
|
|
34
|
+
this.pptBackgroundImg = k81.pptBackgroundImg;
|
|
35
35
|
}
|
|
36
|
-
if (
|
|
37
|
-
this.pptBackgroundImgWidth =
|
|
36
|
+
if (k81.pptBackgroundImgWidth !== undefined) {
|
|
37
|
+
this.pptBackgroundImgWidth = k81.pptBackgroundImgWidth;
|
|
38
38
|
}
|
|
39
|
-
if (
|
|
40
|
-
this.pptBackgroundColor =
|
|
39
|
+
if (k81.pptBackgroundColor !== undefined) {
|
|
40
|
+
this.pptBackgroundColor = k81.pptBackgroundColor;
|
|
41
41
|
}
|
|
42
42
|
}
|
|
43
|
-
updateStateVars(
|
|
43
|
+
updateStateVars(j81) {
|
|
44
44
|
}
|
|
45
|
-
purgeVariableDependenciesOnElmtId(
|
|
45
|
+
purgeVariableDependenciesOnElmtId(i81) {
|
|
46
46
|
}
|
|
47
47
|
aboutToBeDeleted() {
|
|
48
48
|
SubscriberManager.Get().delete(this.id__());
|
|
@@ -56,23 +56,23 @@ export class PLVPPTWeb extends ViewPU {
|
|
|
56
56
|
}
|
|
57
57
|
initialRender() {
|
|
58
58
|
{
|
|
59
|
-
this.observeComponentCreation2((
|
|
60
|
-
if (
|
|
61
|
-
let
|
|
59
|
+
this.observeComponentCreation2((e81, f81) => {
|
|
60
|
+
if (f81) {
|
|
61
|
+
let g81 = new PLVSimpleWeb(this, {
|
|
62
62
|
controller: this.controller,
|
|
63
63
|
src: this.url
|
|
64
|
-
}, undefined,
|
|
65
|
-
ViewPU.create(
|
|
66
|
-
let
|
|
64
|
+
}, undefined, e81, () => { }, { page: "sdk/src/main/ets/modules/ppt/PLVPPTWeb.ets", line: 28, col: 5 });
|
|
65
|
+
ViewPU.create(g81);
|
|
66
|
+
let h81 = () => {
|
|
67
67
|
return {
|
|
68
68
|
controller: this.controller,
|
|
69
69
|
src: this.url
|
|
70
70
|
};
|
|
71
71
|
};
|
|
72
|
-
|
|
72
|
+
g81.paramsGenerator_ = h81;
|
|
73
73
|
}
|
|
74
74
|
else {
|
|
75
|
-
this.updateStateVarsOfChildByElmtId(
|
|
75
|
+
this.updateStateVarsOfChildByElmtId(e81, {});
|
|
76
76
|
}
|
|
77
77
|
}, { name: "PLVSimpleWeb" });
|
|
78
78
|
}
|
|
@@ -12,14 +12,14 @@ export declare class PLVPPTWebController extends PLVWebController {
|
|
|
12
12
|
private callbacks;
|
|
13
13
|
eventNotify: PLVEventNotify<EventType>;
|
|
14
14
|
private observers;
|
|
15
|
-
constructor(
|
|
16
|
-
updateDelayTime(
|
|
17
|
-
setSEIData(
|
|
18
|
-
changePPTPage(
|
|
19
|
-
videoStart(
|
|
15
|
+
constructor(m83: PLVChannelData, n83: PLVSocketMediator, o83: PLVPlayerMediator, p83?: string);
|
|
16
|
+
updateDelayTime(l83: boolean): void;
|
|
17
|
+
setSEIData(j83: number): void;
|
|
18
|
+
changePPTPage(h83: ChangePPTType): void;
|
|
19
|
+
videoStart(e83?: string, f83?: string): void;
|
|
20
20
|
pptPlay(): void;
|
|
21
21
|
pptPause(): void;
|
|
22
|
-
pptSeek(
|
|
22
|
+
pptSeek(a83: number): void;
|
|
23
23
|
destroy(): void;
|
|
24
24
|
private init;
|
|
25
25
|
private onPlayerData;
|
|
@@ -23,61 +23,61 @@ const EVENT_PPT_PAUSE = 'pptPause';
|
|
|
23
23
|
const EVENT_PPT_SEEK = 'pptSeek';
|
|
24
24
|
const EVENT_PPT_PREPARE = 'pptPrepare';
|
|
25
25
|
export class PLVPPTWebController extends PLVWebController {
|
|
26
|
-
constructor(
|
|
27
|
-
super(
|
|
26
|
+
constructor(m83, n83, o83, p83) {
|
|
27
|
+
super(p83);
|
|
28
28
|
this.delayTime = 5000;
|
|
29
29
|
this.eventNotify = new PLVEventNotify(this);
|
|
30
30
|
this.observers = [];
|
|
31
|
-
this.channelData =
|
|
32
|
-
this.socketMediator =
|
|
33
|
-
this.playerMediator =
|
|
31
|
+
this.channelData = m83;
|
|
32
|
+
this.socketMediator = n83;
|
|
33
|
+
this.playerMediator = o83;
|
|
34
34
|
this.callbacks = new HashMap();
|
|
35
35
|
this.init();
|
|
36
36
|
}
|
|
37
|
-
updateDelayTime(
|
|
38
|
-
this.delayTime =
|
|
37
|
+
updateDelayTime(l83) {
|
|
38
|
+
this.delayTime = l83 ? 500 : 5000;
|
|
39
39
|
}
|
|
40
|
-
setSEIData(
|
|
41
|
-
const
|
|
42
|
-
this.callHandle(EVENT_SET_SEI_DATA,
|
|
40
|
+
setSEIData(j83) {
|
|
41
|
+
const k83 = "{\"time\":" + j83 + "}";
|
|
42
|
+
this.callHandle(EVENT_SET_SEI_DATA, k83, () => {
|
|
43
43
|
});
|
|
44
44
|
}
|
|
45
|
-
changePPTPage(
|
|
46
|
-
const
|
|
47
|
-
PLVLogger.info(TAG, 'changePPTPage, data=' +
|
|
48
|
-
this.callHandle(EVENT_CHANGE_PPT_PAGE,
|
|
45
|
+
changePPTPage(h83) {
|
|
46
|
+
const i83 = "{\"type\":\"" + h83 + "\"}";
|
|
47
|
+
PLVLogger.info(TAG, 'changePPTPage, data=' + i83);
|
|
48
|
+
this.callHandle(EVENT_CHANGE_PPT_PAGE, i83, () => {
|
|
49
49
|
});
|
|
50
50
|
}
|
|
51
|
-
videoStart(
|
|
52
|
-
const
|
|
53
|
-
"type":
|
|
51
|
+
videoStart(e83, f83) {
|
|
52
|
+
const g83 = PLVJSONUtils.safeStringify({
|
|
53
|
+
"type": e83 ?? this.playerMediator.pptPlayType,
|
|
54
54
|
"roomId": this.channelData.loginChannelId,
|
|
55
|
-
"id":
|
|
55
|
+
"id": f83 ?? this.playerMediator.pptPlayId
|
|
56
56
|
});
|
|
57
|
-
this.callHandle(EVENT_VIDEO_START,
|
|
57
|
+
this.callHandle(EVENT_VIDEO_START, g83, () => {
|
|
58
58
|
});
|
|
59
59
|
}
|
|
60
60
|
pptPlay() {
|
|
61
|
-
const
|
|
62
|
-
this.callHandle(EVENT_PPT_PLAY,
|
|
61
|
+
const d83 = "{\"time\":" + this.playerMediator.videoCurrentPosition + "}";
|
|
62
|
+
this.callHandle(EVENT_PPT_PLAY, d83, () => {
|
|
63
63
|
});
|
|
64
64
|
}
|
|
65
65
|
pptPause() {
|
|
66
|
-
const
|
|
67
|
-
this.callHandle(EVENT_PPT_PAUSE,
|
|
66
|
+
const c83 = "{\"time\":" + this.playerMediator.videoCurrentPosition + "}";
|
|
67
|
+
this.callHandle(EVENT_PPT_PAUSE, c83, () => {
|
|
68
68
|
});
|
|
69
69
|
}
|
|
70
|
-
pptSeek(
|
|
71
|
-
const
|
|
72
|
-
this.callHandle(EVENT_PPT_SEEK,
|
|
70
|
+
pptSeek(a83) {
|
|
71
|
+
const b83 = "{\"time\":" + a83 + "}";
|
|
72
|
+
this.callHandle(EVENT_PPT_SEEK, b83, () => {
|
|
73
73
|
});
|
|
74
74
|
}
|
|
75
75
|
destroy() {
|
|
76
76
|
this.eventNotify.clear();
|
|
77
77
|
MutableObserver.disposeAll(this.observers);
|
|
78
|
-
this.callbacks.forEach((
|
|
79
|
-
if (
|
|
80
|
-
this.socketMediator.offData(
|
|
78
|
+
this.callbacks.forEach((y82, z82) => {
|
|
79
|
+
if (z82 && y82) {
|
|
80
|
+
this.socketMediator.offData(z82, y82, this);
|
|
81
81
|
}
|
|
82
82
|
});
|
|
83
83
|
}
|
|
@@ -89,23 +89,23 @@ export class PLVPPTWebController extends PLVWebController {
|
|
|
89
89
|
this.registerLiveHandlerIfNeed();
|
|
90
90
|
this.registerPlaybackHandlerIfNeed();
|
|
91
91
|
})
|
|
92
|
-
.registerHandler(V2_GET_NATIVE_APP_PARAMS_INFO, async (
|
|
93
|
-
const
|
|
94
|
-
|
|
92
|
+
.registerHandler(V2_GET_NATIVE_APP_PARAMS_INFO, async (v82, w82) => {
|
|
93
|
+
const x82 = await toWebParams(this.channelData);
|
|
94
|
+
w82(x82);
|
|
95
95
|
});
|
|
96
96
|
}
|
|
97
97
|
onPlayerData() {
|
|
98
98
|
if (PLVLoginType.PLAYBACK === this.channelData.loginType) {
|
|
99
|
-
this.playerMediator.seekStartEvent.observe((
|
|
100
|
-
if (
|
|
101
|
-
PLVLogger.info(TAG, 'send ppt message: seekStartEvent=' +
|
|
99
|
+
this.playerMediator.seekStartEvent.observe((u82) => {
|
|
100
|
+
if (u82) {
|
|
101
|
+
PLVLogger.info(TAG, 'send ppt message: seekStartEvent=' + u82 + ', seekTo=' + u82.seekTo);
|
|
102
102
|
this.pptSeek(this.playerMediator.videoCurrentPosition);
|
|
103
103
|
}
|
|
104
104
|
}).pushTo(this.observers);
|
|
105
105
|
watchStates(() => {
|
|
106
|
-
const
|
|
107
|
-
PLVLogger.info(TAG, 'send ppt message: playerState=' +
|
|
108
|
-
switch (
|
|
106
|
+
const t82 = this.playerMediator.playerState.value;
|
|
107
|
+
PLVLogger.info(TAG, 'send ppt message: playerState=' + t82 + ", pptPlayType=" + this.playerMediator.pptPlayType + ", pptPlayId=" + this.playerMediator.pptPlayId);
|
|
108
|
+
switch (t82) {
|
|
109
109
|
case PLVMediaPlayerState.STATE_PREPARING:
|
|
110
110
|
this.videoStart(this.playerMediator.pptPlayType, this.playerMediator.pptPlayId);
|
|
111
111
|
break;
|
|
@@ -123,81 +123,81 @@ export class PLVPPTWebController extends PLVWebController {
|
|
|
123
123
|
if (PLVLoginType.PLAYBACK === this.channelData.loginType) {
|
|
124
124
|
return;
|
|
125
125
|
}
|
|
126
|
-
const
|
|
127
|
-
const
|
|
128
|
-
|| PLVSocketMessageEvent.ON_SLICE_START ===
|
|
129
|
-
|| PLVSocketMessageEvent.ON_SLICE_OPEN ===
|
|
130
|
-
|| PLVSocketMessageEvent.ON_SLICE_DRAW ===
|
|
131
|
-
|| PLVSocketMessageEvent.ON_SLICE_CONTROL ===
|
|
132
|
-
if (
|
|
126
|
+
const d82 = (j82, k82) => {
|
|
127
|
+
const l82 = PLVSocketMessageEvent.ON_SLICE_ID === k82
|
|
128
|
+
|| PLVSocketMessageEvent.ON_SLICE_START === k82
|
|
129
|
+
|| PLVSocketMessageEvent.ON_SLICE_OPEN === k82
|
|
130
|
+
|| PLVSocketMessageEvent.ON_SLICE_DRAW === k82
|
|
131
|
+
|| PLVSocketMessageEvent.ON_SLICE_CONTROL === k82;
|
|
132
|
+
if (l82) {
|
|
133
133
|
if (this.delayTime > 0) {
|
|
134
|
-
const
|
|
135
|
-
|
|
134
|
+
const s82 = j82.lastIndexOf('}');
|
|
135
|
+
j82 = j82.substring(0, s82) + `,"delayTime":${this.delayTime}}`;
|
|
136
136
|
}
|
|
137
|
-
PLVLogger.info(TAG, 'receive ppt message: delay=' +
|
|
138
|
-
this.callHandle(EVENT_REFRESH_PPT,
|
|
139
|
-
PLVLogger.info(TAG, 'send ppt message: result=' +
|
|
137
|
+
PLVLogger.info(TAG, 'receive ppt message: delay=' + j82);
|
|
138
|
+
this.callHandle(EVENT_REFRESH_PPT, j82, (r82) => {
|
|
139
|
+
PLVLogger.info(TAG, 'send ppt message: result=' + r82);
|
|
140
140
|
});
|
|
141
|
-
if (PLVSocketMessageEvent.ON_SLICE_ID ===
|
|
142
|
-
const
|
|
143
|
-
if (!
|
|
141
|
+
if (PLVSocketMessageEvent.ON_SLICE_ID === k82) {
|
|
142
|
+
const p82 = PLVJSONUtils.json2Bean(PLVOnSliceIDEvent, j82);
|
|
143
|
+
if (!p82 || !p82.inClass) {
|
|
144
144
|
return;
|
|
145
145
|
}
|
|
146
|
-
const
|
|
147
|
-
?
|
|
146
|
+
const q82 = this.channelData.liveDetail?.isFollowTeacherWatchLayout()
|
|
147
|
+
? p82.pptAndVedioPosition === 0
|
|
148
148
|
: (this.channelData.liveDetail?.isPPTWatchLayout() ? true : false);
|
|
149
|
-
this.eventNotify.emit('switchPPTLocation',
|
|
149
|
+
this.eventNotify.emit('switchPPTLocation', q82);
|
|
150
150
|
}
|
|
151
|
-
else if (PLVSocketMessageEvent.ON_SLICE_START ===
|
|
152
|
-
const
|
|
153
|
-
if (
|
|
154
|
-
const
|
|
155
|
-
?
|
|
151
|
+
else if (PLVSocketMessageEvent.ON_SLICE_START === k82) {
|
|
152
|
+
const n82 = PLVJSONUtils.json2Bean(PLVPPTOnSliceStartEvent, j82);
|
|
153
|
+
if (n82) {
|
|
154
|
+
const o82 = this.channelData.liveDetail?.isFollowTeacherWatchLayout()
|
|
155
|
+
? n82.isPptOnMainScreen()
|
|
156
156
|
: (this.channelData.liveDetail?.isPPTWatchLayout() ? true : false);
|
|
157
|
-
this.eventNotify.emit('switchPPTLocation',
|
|
157
|
+
this.eventNotify.emit('switchPPTLocation', o82);
|
|
158
158
|
}
|
|
159
159
|
}
|
|
160
160
|
}
|
|
161
|
-
else if (PLVSocketMessageEvent.CHANGE_VIDEO_AND_PPT_POSITION ===
|
|
162
|
-
const
|
|
163
|
-
if (
|
|
164
|
-
this.eventNotify.emit('switchPPTLocation', '1' !=
|
|
161
|
+
else if (PLVSocketMessageEvent.CHANGE_VIDEO_AND_PPT_POSITION === k82) {
|
|
162
|
+
const m82 = PLVJSONUtils.safeParse(j82);
|
|
163
|
+
if (m82) {
|
|
164
|
+
this.eventNotify.emit('switchPPTLocation', '1' != m82['status']);
|
|
165
165
|
}
|
|
166
166
|
}
|
|
167
167
|
};
|
|
168
|
-
const
|
|
169
|
-
if (PLVSocketTransmitEvent.CHANGE_DOUBLE_MODE ===
|
|
170
|
-
const
|
|
171
|
-
if (
|
|
172
|
-
const
|
|
173
|
-
'autoId':
|
|
174
|
-
'pageId':
|
|
168
|
+
const e82 = (f82, g82) => {
|
|
169
|
+
if (PLVSocketTransmitEvent.CHANGE_DOUBLE_MODE === g82) {
|
|
170
|
+
const h82 = PLVJSONUtils.safeParse(f82);
|
|
171
|
+
if (h82 && h82['autoId'] !== undefined && h82['pageId'] !== undefined) {
|
|
172
|
+
const i82 = PLVJSONUtils.safeStringify({
|
|
173
|
+
'autoId': h82['autoId'],
|
|
174
|
+
'pageId': h82['pageId'],
|
|
175
175
|
'docType': 1,
|
|
176
176
|
'isCamClosed': 0
|
|
177
177
|
});
|
|
178
|
-
this.callHandle(EVENT_CHANGE_PPT,
|
|
178
|
+
this.callHandle(EVENT_CHANGE_PPT, i82, () => {
|
|
179
179
|
});
|
|
180
180
|
}
|
|
181
181
|
}
|
|
182
182
|
};
|
|
183
|
-
this.socketMediator.onData(PLVSocketOnEvent.MESSAGE,
|
|
184
|
-
this.socketMediator.onData(PLVSocketOnEvent.TRANSMIT,
|
|
185
|
-
this.callbacks.set(PLVSocketOnEvent.MESSAGE,
|
|
186
|
-
this.callbacks.set(PLVSocketOnEvent.TRANSMIT,
|
|
183
|
+
this.socketMediator.onData(PLVSocketOnEvent.MESSAGE, d82, this);
|
|
184
|
+
this.socketMediator.onData(PLVSocketOnEvent.TRANSMIT, e82, this);
|
|
185
|
+
this.callbacks.set(PLVSocketOnEvent.MESSAGE, d82);
|
|
186
|
+
this.callbacks.set(PLVSocketOnEvent.TRANSMIT, e82);
|
|
187
187
|
}
|
|
188
188
|
registerLiveHandlerIfNeed() {
|
|
189
189
|
if (PLVLoginType.LIVE !== this.channelData.loginType) {
|
|
190
190
|
return;
|
|
191
191
|
}
|
|
192
|
-
this.registerHandler(EVENT_SEND_SOCKET, (
|
|
193
|
-
PLVLogger.info(TAG, 'send socket message: ' +
|
|
194
|
-
this.socketMediator.emit(PLVSocketOnEvent.MESSAGE,
|
|
192
|
+
this.registerHandler(EVENT_SEND_SOCKET, (b82, c82) => {
|
|
193
|
+
PLVLogger.info(TAG, 'send socket message: ' + b82);
|
|
194
|
+
this.socketMediator.emit(PLVSocketOnEvent.MESSAGE, b82);
|
|
195
195
|
});
|
|
196
|
-
this.registerHandler(EVENT_PPT_STATUS_CHANGE, (
|
|
197
|
-
PLVLogger.info(TAG, 'receive ppt status change: ' +
|
|
198
|
-
const
|
|
199
|
-
if (
|
|
200
|
-
this.eventNotify.emit('onPPTStatusChange',
|
|
196
|
+
this.registerHandler(EVENT_PPT_STATUS_CHANGE, (y81, z81) => {
|
|
197
|
+
PLVLogger.info(TAG, 'receive ppt status change: ' + y81);
|
|
198
|
+
const a82 = PLVJSONUtils.json2Bean(PLVPPTStatus, y81);
|
|
199
|
+
if (a82 && a82.maxTeacherOp) {
|
|
200
|
+
this.eventNotify.emit('onPPTStatusChange', a82);
|
|
201
201
|
}
|
|
202
202
|
});
|
|
203
203
|
}
|
|
@@ -205,16 +205,16 @@ export class PLVPPTWebController extends PLVWebController {
|
|
|
205
205
|
if (PLVLoginType.PLAYBACK !== this.channelData.loginType) {
|
|
206
206
|
return;
|
|
207
207
|
}
|
|
208
|
-
this.registerHandler(EVENT_PPT_PREPARE, (
|
|
209
|
-
PLVLogger.info(TAG, 'receive ppt prepare: ' +
|
|
210
|
-
|
|
208
|
+
this.registerHandler(EVENT_PPT_PREPARE, (w81, x81) => {
|
|
209
|
+
PLVLogger.info(TAG, 'receive ppt prepare: ' + w81);
|
|
210
|
+
x81('function is success');
|
|
211
211
|
});
|
|
212
|
-
this.registerHandler(EVENT_VIDEO_DURATION, (
|
|
213
|
-
const
|
|
214
|
-
|
|
212
|
+
this.registerHandler(EVENT_VIDEO_DURATION, (t81, u81) => {
|
|
213
|
+
const v81 = "{\"time\":" + this.playerMediator.videoCurrentPosition + "}";
|
|
214
|
+
u81(v81);
|
|
215
215
|
});
|
|
216
|
-
this.registerHandler(EVENT_CHANGE_PPT_POSITION, (
|
|
217
|
-
this.eventNotify.emit('switchPPTLocation', 'true' ===
|
|
216
|
+
this.registerHandler(EVENT_CHANGE_PPT_POSITION, (r81, s81) => {
|
|
217
|
+
this.eventNotify.emit('switchPPTLocation', 'true' === r81);
|
|
218
218
|
});
|
|
219
219
|
}
|
|
220
220
|
}
|
|
@@ -19,27 +19,27 @@ export declare class PLVProductManager extends PLVBaseModule {
|
|
|
19
19
|
* 事件通知
|
|
20
20
|
*/
|
|
21
21
|
eventNotify: IPLVEventNotify<EventType>;
|
|
22
|
-
constructor(
|
|
22
|
+
constructor(k87: PLVChannelData, l87: PLVSocketMediator);
|
|
23
23
|
/**
|
|
24
24
|
* 通知是否有商品推送
|
|
25
25
|
* @param pushContentBean 不为undefined即为有商品推送
|
|
26
26
|
*/
|
|
27
|
-
notifyPush(
|
|
27
|
+
notifyPush(j87?: PLVProductContentBean): void;
|
|
28
28
|
/**
|
|
29
29
|
* 通知商品库开关
|
|
30
30
|
* @param isOpen
|
|
31
31
|
*/
|
|
32
|
-
notifyOpen(
|
|
32
|
+
notifyOpen(i87: boolean): void;
|
|
33
33
|
/**
|
|
34
34
|
* 通知商品推送的点击次数
|
|
35
35
|
* @param clickTimes
|
|
36
36
|
*/
|
|
37
|
-
notifyClickTimes(
|
|
37
|
+
notifyClickTimes(h87: number): void;
|
|
38
38
|
/**
|
|
39
39
|
* 通知商品推送被移动
|
|
40
40
|
* @param showId
|
|
41
41
|
*/
|
|
42
|
-
notifyMove(
|
|
42
|
+
notifyMove(g87?: number): void;
|
|
43
43
|
/**
|
|
44
44
|
* 通知商品推送被点击
|
|
45
45
|
*/
|
|
@@ -11,34 +11,34 @@ import { PLVProductMoveEvent } from './model/PLVProductMoveEvent';
|
|
|
11
11
|
import { PLVProductRemoveEvent } from './model/PLVProductRemoveEvent';
|
|
12
12
|
const TAG = '[PLVProductManager]';
|
|
13
13
|
export class PLVProductManager extends PLVBaseModule {
|
|
14
|
-
constructor(
|
|
15
|
-
super(
|
|
14
|
+
constructor(k87, l87) {
|
|
15
|
+
super(k87);
|
|
16
16
|
this.productDataBean = new PLVProductDataBean();
|
|
17
17
|
this.eventNotify = new PLVEventNotify(this);
|
|
18
|
-
this.socketMediator =
|
|
18
|
+
this.socketMediator = l87;
|
|
19
19
|
this.init();
|
|
20
20
|
}
|
|
21
|
-
notifyPush(
|
|
22
|
-
if (
|
|
21
|
+
notifyPush(j87) {
|
|
22
|
+
if (j87?.productId != this.productDataBean.pushContentBean?.productId) {
|
|
23
23
|
this.productDataBean.hotEffectClickTimes = 0;
|
|
24
24
|
}
|
|
25
|
-
this.productDataBean.hotEffectTips = this.getHotEffectTips(
|
|
26
|
-
this.productDataBean.pushContentBean =
|
|
25
|
+
this.productDataBean.hotEffectTips = this.getHotEffectTips(j87);
|
|
26
|
+
this.productDataBean.pushContentBean = j87;
|
|
27
27
|
this.eventNotify.emit('product_data', this.productDataBean.copy());
|
|
28
28
|
}
|
|
29
|
-
notifyOpen(
|
|
29
|
+
notifyOpen(i87) {
|
|
30
30
|
this.productDataBean.hotEffectClickTimes = 0;
|
|
31
31
|
this.productDataBean.pushContentBean = undefined;
|
|
32
|
-
this.productDataBean.isOpenProduct =
|
|
32
|
+
this.productDataBean.isOpenProduct = i87;
|
|
33
33
|
this.eventNotify.emit('product_data', this.productDataBean.copy());
|
|
34
34
|
}
|
|
35
|
-
notifyClickTimes(
|
|
36
|
-
this.productDataBean.hotEffectClickTimes =
|
|
35
|
+
notifyClickTimes(h87) {
|
|
36
|
+
this.productDataBean.hotEffectClickTimes = h87;
|
|
37
37
|
this.eventNotify.emit('product_data', this.productDataBean.copy());
|
|
38
38
|
}
|
|
39
|
-
notifyMove(
|
|
39
|
+
notifyMove(g87) {
|
|
40
40
|
if (this.productDataBean.pushContentBean) {
|
|
41
|
-
this.productDataBean.pushContentBean.showId =
|
|
41
|
+
this.productDataBean.pushContentBean.showId = g87;
|
|
42
42
|
}
|
|
43
43
|
this.eventNotify.emit('product_data', this.productDataBean.copy());
|
|
44
44
|
}
|
|
@@ -47,16 +47,16 @@ export class PLVProductManager extends PLVBaseModule {
|
|
|
47
47
|
return;
|
|
48
48
|
}
|
|
49
49
|
PLVLogger.info(TAG, 'notifyClick');
|
|
50
|
-
const
|
|
51
|
-
|
|
50
|
+
const e87 = new PLVLocalProductClickEvent();
|
|
51
|
+
e87.data = {
|
|
52
52
|
type: this.productDataBean.pushContentBean.productType,
|
|
53
53
|
positionName: this.productDataBean.pushContentBean.name,
|
|
54
54
|
productId: this.productDataBean.pushContentBean.productId,
|
|
55
55
|
nickName: this.channelData.viewerName
|
|
56
56
|
};
|
|
57
|
-
|
|
58
|
-
const
|
|
59
|
-
this.socketMediator.emit(PLVSocketOnEvent.PRODUCT,
|
|
57
|
+
e87.roomId = await this.channelData.loginRoomIdPromise.get();
|
|
58
|
+
const f87 = PLVJSONUtils.safeStringify(e87);
|
|
59
|
+
this.socketMediator.emit(PLVSocketOnEvent.PRODUCT, f87, () => {
|
|
60
60
|
PLVLogger.info(TAG, 'notifyClick success');
|
|
61
61
|
});
|
|
62
62
|
}
|
|
@@ -70,92 +70,92 @@ export class PLVProductManager extends PLVBaseModule {
|
|
|
70
70
|
this.productDataBean.isOpenProduct = (await this.channelData.initializedPromise.get()).getMenuBuyBean() != undefined;
|
|
71
71
|
this.productDataBean.hotEffectEnable = (await this.channelData.initializedPromise.get()).liveDetail?.isProductHotEffectEnabled();
|
|
72
72
|
this.productHotEffectBean = (await this.channelData.initializedPromise.get()).liveDetail?.productHotEffectTips;
|
|
73
|
-
this.socketMediator.onData(PLVSocketOnEvent.MESSAGE, (
|
|
74
|
-
if (PLVProductEvent.EVENT ===
|
|
75
|
-
this.handleProductEvent(
|
|
73
|
+
this.socketMediator.onData(PLVSocketOnEvent.MESSAGE, (c87, d87) => {
|
|
74
|
+
if (PLVProductEvent.EVENT === d87) {
|
|
75
|
+
this.handleProductEvent(c87);
|
|
76
76
|
}
|
|
77
77
|
}, this);
|
|
78
|
-
this.socketMediator.onData(PLVSocketOnEvent.PRODUCT, (
|
|
79
|
-
if (PLVProductClickTimesEvent.EVENT ===
|
|
78
|
+
this.socketMediator.onData(PLVSocketOnEvent.PRODUCT, (a87, b87) => {
|
|
79
|
+
if (PLVProductClickTimesEvent.EVENT === b87) {
|
|
80
80
|
if (this.productDataBean.hotEffectEnable) {
|
|
81
|
-
this.handleClickTimesEvent(
|
|
81
|
+
this.handleClickTimesEvent(a87);
|
|
82
82
|
}
|
|
83
83
|
}
|
|
84
84
|
}, this);
|
|
85
85
|
}
|
|
86
|
-
handleProductEvent(
|
|
87
|
-
const
|
|
88
|
-
if (!
|
|
86
|
+
handleProductEvent(t86) {
|
|
87
|
+
const u86 = PLVJSONUtils.json2Bean(PLVProductEvent, t86);
|
|
88
|
+
if (!u86) {
|
|
89
89
|
return;
|
|
90
90
|
}
|
|
91
|
-
if (
|
|
92
|
-
const
|
|
93
|
-
if (!
|
|
91
|
+
if (u86.isProductControlEvent()) {
|
|
92
|
+
const z86 = PLVJSONUtils.toFillData(PLVProductControlEvent, t86);
|
|
93
|
+
if (!z86 || !z86.content) {
|
|
94
94
|
return;
|
|
95
95
|
}
|
|
96
|
-
if (
|
|
97
|
-
if (!
|
|
98
|
-
|
|
96
|
+
if (z86.isRedact() && this.productDataBean.pushContentBean?.productId === z86.content.productId) {
|
|
97
|
+
if (!z86.content.productPushRule) {
|
|
98
|
+
z86.content.productPushRule = this.productDataBean.pushContentBean?.productPushRule;
|
|
99
99
|
}
|
|
100
|
-
this.notifyPush(
|
|
100
|
+
this.notifyPush(z86.content);
|
|
101
101
|
}
|
|
102
|
-
if (
|
|
103
|
-
this.notifyPush(
|
|
102
|
+
if (z86.isPush()) {
|
|
103
|
+
this.notifyPush(z86.content);
|
|
104
104
|
}
|
|
105
105
|
}
|
|
106
|
-
else if (
|
|
107
|
-
const
|
|
108
|
-
if (!
|
|
106
|
+
else if (u86.isProductRemoveEvent()) {
|
|
107
|
+
const y86 = PLVJSONUtils.json2Bean(PLVProductRemoveEvent, t86);
|
|
108
|
+
if (!y86 || !y86.content || !this.productDataBean.pushContentBean) {
|
|
109
109
|
return;
|
|
110
110
|
}
|
|
111
|
-
if (this.productDataBean.pushContentBean.productId ===
|
|
111
|
+
if (this.productDataBean.pushContentBean.productId === y86.content.productId) {
|
|
112
112
|
this.notifyPush(undefined);
|
|
113
113
|
}
|
|
114
114
|
}
|
|
115
|
-
else if (
|
|
116
|
-
const
|
|
117
|
-
if (!
|
|
115
|
+
else if (u86.isProductMoveEvent()) {
|
|
116
|
+
const w86 = PLVJSONUtils.json2Bean(PLVProductMoveEvent, t86);
|
|
117
|
+
if (!w86 || !w86.content) {
|
|
118
118
|
return;
|
|
119
119
|
}
|
|
120
|
-
|
|
121
|
-
if (this.productDataBean.pushContentBean?.productId ===
|
|
122
|
-
this.notifyMove(
|
|
120
|
+
w86.content.some((x86) => {
|
|
121
|
+
if (this.productDataBean.pushContentBean?.productId === x86.productId) {
|
|
122
|
+
this.notifyMove(x86.showId);
|
|
123
123
|
return true;
|
|
124
124
|
}
|
|
125
125
|
return false;
|
|
126
126
|
});
|
|
127
127
|
}
|
|
128
|
-
else if (
|
|
129
|
-
const
|
|
130
|
-
if (!
|
|
128
|
+
else if (u86.isProductMenuSwitchEvent()) {
|
|
129
|
+
const v86 = PLVJSONUtils.json2Bean(PLVProductMenuSwitchEvent, t86);
|
|
130
|
+
if (!v86) {
|
|
131
131
|
return;
|
|
132
132
|
}
|
|
133
|
-
if (('Y' ===
|
|
133
|
+
if (('Y' === v86.content?.enabled) === this.productDataBean.isOpenProduct) {
|
|
134
134
|
return;
|
|
135
135
|
}
|
|
136
136
|
this.notifyOpen(!this.productDataBean.isOpenProduct);
|
|
137
137
|
}
|
|
138
|
-
else if (
|
|
138
|
+
else if (u86.isCancelPush()) {
|
|
139
139
|
this.notifyPush(undefined);
|
|
140
140
|
}
|
|
141
141
|
}
|
|
142
|
-
handleClickTimesEvent(
|
|
143
|
-
const
|
|
144
|
-
if (
|
|
145
|
-
if (
|
|
146
|
-
this.notifyClickTimes(
|
|
142
|
+
handleClickTimesEvent(r86) {
|
|
143
|
+
const s86 = PLVJSONUtils.json2Bean(PLVProductClickTimesEvent, r86);
|
|
144
|
+
if (s86 && s86.times) {
|
|
145
|
+
if (s86.productId === this.productDataBean.pushContentBean?.productId) {
|
|
146
|
+
this.notifyClickTimes(s86.times);
|
|
147
147
|
}
|
|
148
148
|
}
|
|
149
149
|
}
|
|
150
|
-
getHotEffectTips(
|
|
151
|
-
if (
|
|
152
|
-
if (
|
|
150
|
+
getHotEffectTips(q86) {
|
|
151
|
+
if (q86 && this.productHotEffectBean) {
|
|
152
|
+
if (q86.isNormalProduct()) {
|
|
153
153
|
return this.productHotEffectBean.normalProductTips;
|
|
154
154
|
}
|
|
155
|
-
else if (
|
|
155
|
+
else if (q86.isFinanceProduct()) {
|
|
156
156
|
return this.productHotEffectBean.financeProductTips;
|
|
157
157
|
}
|
|
158
|
-
else if (
|
|
158
|
+
else if (q86.isPositionProduct()) {
|
|
159
159
|
return this.productHotEffectBean.jobProductTips;
|
|
160
160
|
}
|
|
161
161
|
}
|