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-30 18:18:08 +0800
Browse Files
Options
Browse Files
Download
Plain Diff
Commit
51109bdb056ca0cd0b63fe0fa0ee8e50457267a7
51109bdb
2 parents
93891756
e4ea9c4c
Merge remote-tracking branch 'origin/main'
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
54 additions
and
30 deletions
sight_harmony/commons/wdRouter/src/main/ets/utils/ProcessUtils.ets
sight_harmony/features/wdComponent/src/main/ets/components/compview/ZhCarouselLayout01.ets
sight_harmony/features/wdComponent/src/main/ets/components/page/PageComponent.ets
sight_harmony/features/wdDetailPlayLive/src/main/ets/pages/DetailPlayLiveCommon.ets
sight_harmony/features/wdDetailPlayLive/src/main/ets/viewModel/LiveViewModel.ets
sight_harmony/features/wdDetailPlayLive/src/main/ets/widgets/details/video/PlayUIComponent.ets
sight_harmony/commons/wdRouter/src/main/ets/utils/ProcessUtils.ets
View file @
51109bd
...
...
@@ -166,6 +166,25 @@ export class ProcessUtils {
* @param content
* */
public static gotoMultiPictureListPage(photoList: PhotoListBean[], swiperIndex?: number) {
let tempP = [] as PhotoListBean[]
let relIndex = 0;
for (let index = 0; index < photoList.length; index++) {
const element = photoList[index];
if(!StringUtils.isEmpty(element.picPath)){
relIndex = relIndex+1
}
}
tempP.length = relIndex
relIndex = 0
for (let index = 0; index < photoList.length; index++) {
const element = photoList[index];
if(!StringUtils.isEmpty(element.picPath)){
tempP[relIndex] = element
relIndex = relIndex+1
}
}
photoList.length = tempP.length
photoList = tempP
let taskAction: Action = {
type: 'JUMP_DETAIL_PAGE',
params: {
...
...
sight_harmony/features/wdComponent/src/main/ets/components/compview/ZhCarouselLayout01.ets
View file @
51109bd
...
...
@@ -289,9 +289,9 @@ struct indicatorAnimations {
build() {
Flex({ alignItems: ItemAlign.End }) {
Stack() {
Image($r('app.media.swiper_indicator_gray'))
.width('100%')
.height(2)
// Image($r('app.media.swiper_indicator_gray'))
// .width('100%')
// .height(2)
Image($r('app.media.swiper_indicator_white'))
.width(this.leftW)
.height(2)
...
...
@@ -312,6 +312,7 @@ struct indicatorAnimations {
.margin({
bottom: -2
})
.fontFamily('BebasNeue')
.flexShrink(0)
.animation({
duration: 300,
...
...
@@ -319,9 +320,9 @@ struct indicatorAnimations {
playMode: PlayMode.Normal
})
Stack() {
Image($r('app.media.swiper_indicator_gray'))
.width('100%')
.height(2)
// Image($r('app.media.swiper_indicator_gray'))
// .width('100%')
// .height(2)
Image($r('app.media.swiper_indicator_white'))
.width(this.rightW)
.height(2)
...
...
sight_harmony/features/wdComponent/src/main/ets/components/page/PageComponent.ets
View file @
51109bd
...
...
@@ -88,7 +88,7 @@ export struct PageComponent {
LazyForEach(this.pageModel.compList, (compDTO: CompDTO, compIndex: number) => {
ListItem() {
Column() {
CompParser({ pageModel: this.pageModel, compDTO: compDTO, compIndex: compIndex });
CompParser({ pageModel: this.pageModel, compDTO: compDTO, compIndex: compIndex
, pageId: this.pageId
});
}
}
},
...
...
sight_harmony/features/wdDetailPlayLive/src/main/ets/pages/DetailPlayLiveCommon.ets
View file @
51109bd
...
...
@@ -50,11 +50,6 @@ export struct DetailPlayLiveCommon {
}
aboutToDisappear(): void {
console.error("XXXXZZZZ", '---aboutToDisappear------------')
}
build() {
Column() {
// 直播预约或横屏直播统一进横屏直播
...
...
@@ -84,20 +79,16 @@ export struct DetailPlayLiveCommon {
if (data) {
let detailData = data[0]
//人民号类型单独获取直播地址
if (detailData.rmhPlatform === 1 && detailData.liveInfo?.liveState === 'running') {
if (detailData.rmhPlatform === 1 && detailData.liveInfo?.liveState === 'running') { //
let vliveId = detailData.liveInfo.vlive[0].vliveId as string
console.error(TAG, 'vliveId==' + vliveId)
let pullStreamAddressData = await this.liveViewModel.getLiveRoomPullAddress(vliveId) as GetPullAddressBean
console.error(TAG, 'vliveId==' + vliveId)
if (pullStreamAddressData) {
console.log(TAG, ' GetPullAddressBean:', JSON.stringify(pullStreamAddressData))
//
console.log(TAG, ' GetPullAddressBean:', JSON.stringify(pullStreamAddressData))
let m3u8uUrl = pullStreamAddressData.transCode[0].m3u8Url
detailData.liveInfo.vlive[0].liveUrl = m3u8uUrl
this.playUrl = m3u8uUrl
console.log(TAG, ' GetPullAddressBean:', m3u8uUrl)
//
console.log(TAG, ' GetPullAddressBean:', m3u8uUrl)
}
}
this.liveLandscape =
...
...
sight_harmony/features/wdDetailPlayLive/src/main/ets/viewModel/LiveViewModel.ets
View file @
51109bd
import { ContentDetailDTO,
import {
ContentDetailDTO,
GetPullAddressBean,
LiveDetailsBean, LiveRoomBean, LiveRoomDataBean,
LiveDetailsBean,
LiveRoomBean,
LiveRoomDataBean,
LiveRoomItemBean,
ValueType } from 'wdBean/Index'
ValueType
} from 'wdBean/Index'
import { ContentDetailRequest } from 'wdDetailPlayApi/Index'
import { Logger } from 'wdKit/Index'
import { ToastUtils } from 'wdKit/src/main/ets/utils/ToastUtils'
...
...
@@ -32,18 +36,25 @@ export class LiveViewModel {
}
async getLiveRoomPullAddress(vliveId:string) : Promise<GetPullAddressBean>{
/**
* 获取直播间的拉流地址
* @param vliveId
* @returns
*/
async getLiveRoomPullAddress(vliveId: string): Promise<GetPullAddressBean | null> {
return new Promise<GetPullAddressBean>((success, fail) => {
ContentDetailRequest.getLiveRoomPullStream(vliveId).then(async (resDTO: ResponseDTO<GetPullAddressBean>) => {
return new Promise<GetPullAddressBean | null>((success, fail) => {
ContentDetailRequest.getLiveRoomPullStream(vliveId)
.then(async (resDTO: ResponseDTO<GetPullAddressBean>) => {
console.log(TAG, 'getContentDetail:', JSON.stringify(resDTO.data))
if (resDTO.data) {
success(resDTO.data)
}else {
fail("数据为空")
} else {
success(null)
}
}).catch(() => {
fail("数据为空")
})
.catch(() => {
success(null)
})
})
...
...
@@ -104,6 +115,7 @@ export class LiveViewModel {
})
})
}
// 直播详情-C端点赞接口
getLiveRoomNumberLike(liveId: string, number: number, deviceId: string | number) {
return new Promise<number>((success, fail) => {
...
...
@@ -114,6 +126,7 @@ export class LiveViewModel {
})
})
}
// 直播详情-查询是否点赞接口
getLiveLike(liveId: string, userId: ValueType, deviceId: string | number) {
return new Promise<boolean>((success, fail) => {
...
...
sight_harmony/features/wdDetailPlayLive/src/main/ets/widgets/details/video/PlayUIComponent.ets
View file @
51109bd
...
...
@@ -279,10 +279,10 @@ export struct PlayUIComponent {
})
}
// 进度条
if (this.contentDetailData.liveInfo?.liveState == 'running') {
Blank()
} else {
// 进度条
this.playProgressView()
}
...
...
Please
register
or
login
to post a comment