Showing
6 changed files
with
40 additions
and
10 deletions
| @@ -93,10 +93,8 @@ export class HttpBizUtil { | @@ -93,10 +93,8 @@ export class HttpBizUtil { | ||
| 93 | */ | 93 | */ |
| 94 | static refreshToken(): Promise<string> { | 94 | static refreshToken(): Promise<string> { |
| 95 | let url = HttpUrlUtils.getRefreshTokenUrl(); | 95 | let url = HttpUrlUtils.getRefreshTokenUrl(); |
| 96 | - let params: HashMap<string, string> = new HashMap<string, string>() | ||
| 97 | - params.set('refreshToken', HttpUtils.getRefreshToken()) | ||
| 98 | - params.set('deviceId', HttpUtils.getDeviceId()) | ||
| 99 | - // Logger.debug(TAG, 'refreshToken getRefreshToken: ' + HttpUrlUtils.getRefreshToken()) | 96 | + let params: RefreshTokenParam = |
| 97 | + new RefreshTokenParam(HttpUtils.getRefreshToken(), HttpUtils.getDeviceId()) | ||
| 100 | // 请求刷新token接口 | 98 | // 请求刷新token接口 |
| 101 | return new Promise<string>((success, error) => { | 99 | return new Promise<string>((success, error) => { |
| 102 | WDHttp.post<ResponseDTO<RefreshTokenRes>>(url, params).then((resDTO: ResponseDTO<RefreshTokenRes>) => { | 100 | WDHttp.post<ResponseDTO<RefreshTokenRes>>(url, params).then((resDTO: ResponseDTO<RefreshTokenRes>) => { |
| @@ -124,3 +122,13 @@ export class HttpBizUtil { | @@ -124,3 +122,13 @@ export class HttpBizUtil { | ||
| 124 | }) | 122 | }) |
| 125 | } | 123 | } |
| 126 | } | 124 | } |
| 125 | + | ||
| 126 | +export class RefreshTokenParam { | ||
| 127 | + refreshToken: string = '' | ||
| 128 | + deviceId: string = '' | ||
| 129 | + | ||
| 130 | + constructor(refreshToken: string, deviceId: string) { | ||
| 131 | + this.refreshToken = refreshToken | ||
| 132 | + this.deviceId = deviceId | ||
| 133 | + } | ||
| 134 | +} |
| @@ -9,6 +9,8 @@ import { ContentDetailDTO } from 'wdBean/Index' | @@ -9,6 +9,8 @@ import { ContentDetailDTO } from 'wdBean/Index' | ||
| 9 | export struct CommentTabComponent { | 9 | export struct CommentTabComponent { |
| 10 | private onCommentFocus: () => void = () => { | 10 | private onCommentFocus: () => void = () => { |
| 11 | } | 11 | } |
| 12 | + private onLoad: (dialogController: CustomDialogController) => void = () => { | ||
| 13 | + } | ||
| 12 | @ObjectLink publishCommentModel: publishCommentModel | 14 | @ObjectLink publishCommentModel: publishCommentModel |
| 13 | @Prop contentDetail: ContentDetailDTO | 15 | @Prop contentDetail: ContentDetailDTO |
| 14 | @Prop pageComponentType: number = -1 //1:视频详情页 2:竖屏直播页 | 16 | @Prop pageComponentType: number = -1 //1:视频详情页 2:竖屏直播页 |
| @@ -41,6 +43,8 @@ export struct CommentTabComponent { | @@ -41,6 +43,8 @@ export struct CommentTabComponent { | ||
| 41 | backgroundColor: "#50000000", | 43 | backgroundColor: "#50000000", |
| 42 | }) | 44 | }) |
| 43 | 45 | ||
| 46 | + this.onLoad(this.dialogController) | ||
| 47 | + | ||
| 44 | } | 48 | } |
| 45 | 49 | ||
| 46 | getCommentInputBackImg() { | 50 | getCommentInputBackImg() { |
| @@ -119,7 +123,6 @@ export struct CommentTabComponent { | @@ -119,7 +123,6 @@ export struct CommentTabComponent { | ||
| 119 | if (this.contentDetail.bestNoticer === 1) { | 123 | if (this.contentDetail.bestNoticer === 1) { |
| 120 | this.publishCommentModel.placeHolderText = "优质评论会获得最佳评论人的称号" | 124 | this.publishCommentModel.placeHolderText = "优质评论会获得最佳评论人的称号" |
| 121 | } | 125 | } |
| 122 | - | ||
| 123 | this.dialogController?.open(); | 126 | this.dialogController?.open(); |
| 124 | }) | 127 | }) |
| 125 | } | 128 | } |
| @@ -156,7 +159,7 @@ export struct CommentIconComponent { | @@ -156,7 +159,7 @@ export struct CommentIconComponent { | ||
| 156 | // Stack({alignContent:Alignment.Start}) { | 159 | // Stack({alignContent:Alignment.Start}) { |
| 157 | if (Number.parseInt(this.publishCommentModel.totalCommentNumer) != 0) { | 160 | if (Number.parseInt(this.publishCommentModel.totalCommentNumer) != 0) { |
| 158 | RelativeContainer() { | 161 | RelativeContainer() { |
| 159 | - Image(this.styleType == 1 ? $r('app.media.comment_icon_number_bg'):$r('app.media.ic_like_back_Select')) | 162 | + Image(this.styleType == 1 ? $r('app.media.comment_icon_number_bg') : $r('app.media.ic_like_back_Select')) |
| 160 | .objectFit(ImageFit.Fill) | 163 | .objectFit(ImageFit.Fill) |
| 161 | .resizable({ | 164 | .resizable({ |
| 162 | slice: { | 165 | slice: { |
| @@ -78,9 +78,12 @@ export struct PeopleShipHomeArticleListComponent { | @@ -78,9 +78,12 @@ export struct PeopleShipHomeArticleListComponent { | ||
| 78 | 78 | ||
| 79 | List({scroller: this.scroller}) { | 79 | List({scroller: this.scroller}) { |
| 80 | // 下拉刷新 | 80 | // 下拉刷新 |
| 81 | - ForEach(this.arr, (item: ContentDTO) => { | 81 | + ForEach(this.arr, (item: ContentDTO, index: number) => { |
| 82 | ListItem() { | 82 | ListItem() { |
| 83 | + Column() { | ||
| 83 | CardParser({compDTO:new CompDTO, contentDTO: item }) | 84 | CardParser({compDTO:new CompDTO, contentDTO: item }) |
| 85 | + Divider().strokeWidth(1).color('#f5f5f5').padding({ left: 16, right: 16 }) | ||
| 86 | + } | ||
| 84 | }.width("100%") | 87 | }.width("100%") |
| 85 | .backgroundColor(Color.Transparent) | 88 | .backgroundColor(Color.Transparent) |
| 86 | }, (item: ContentDTO, index: number) => item.objectId + index.toString()) | 89 | }, (item: ContentDTO, index: number) => item.objectId + index.toString()) |
| @@ -83,6 +83,7 @@ export struct OperRowListView { | @@ -83,6 +83,7 @@ export struct OperRowListView { | ||
| 83 | private AudioSuspension = new AudioSuspensionModel() | 83 | private AudioSuspension = new AudioSuspensionModel() |
| 84 | @State currentStatus: number | string | undefined = 0; | 84 | @State currentStatus: number | string | undefined = 0; |
| 85 | @State name: string = 'audio_recommend_status_wait' | 85 | @State name: string = 'audio_recommend_status_wait' |
| 86 | + @State dialogController: CustomDialogController | null = null; | ||
| 86 | 87 | ||
| 87 | async aboutToAppear() { | 88 | async aboutToAppear() { |
| 88 | console.info(TAG, '22222----', this.styleType) | 89 | console.info(TAG, '22222----', this.styleType) |
| @@ -207,6 +208,9 @@ export struct OperRowListView { | @@ -207,6 +208,9 @@ export struct OperRowListView { | ||
| 207 | contentDetail: this.contentDetailData, | 208 | contentDetail: this.contentDetailData, |
| 208 | onCommentFocus: this.onCommentFocus, | 209 | onCommentFocus: this.onCommentFocus, |
| 209 | pageComponentType: this.pageComponentType, | 210 | pageComponentType: this.pageComponentType, |
| 211 | + onLoad: (dialogController: CustomDialogController) => { | ||
| 212 | + this.dialogController = dialogController | ||
| 213 | + } | ||
| 210 | }) | 214 | }) |
| 211 | } | 215 | } |
| 212 | } | 216 | } |
| @@ -222,6 +226,11 @@ export struct OperRowListView { | @@ -222,6 +226,11 @@ export struct OperRowListView { | ||
| 222 | CommentIconComponent({ publishCommentModel: this.publishCommentModel, styleType: this.styleType }) | 226 | CommentIconComponent({ publishCommentModel: this.publishCommentModel, styleType: this.styleType }) |
| 223 | .onClick(() => { | 227 | .onClick(() => { |
| 224 | this.onCommentIconClick() | 228 | this.onCommentIconClick() |
| 229 | + | ||
| 230 | + console.log(JSON.stringify(this.dialogController?.open)) | ||
| 231 | + | ||
| 232 | + // 评论弹框内部嵌入 | ||
| 233 | + !this.showBackIcon && this.dialogController?.open() | ||
| 225 | }) | 234 | }) |
| 226 | } | 235 | } |
| 227 | } | 236 | } |
| @@ -290,7 +299,8 @@ export struct OperRowListView { | @@ -290,7 +299,8 @@ export struct OperRowListView { | ||
| 290 | @Builder | 299 | @Builder |
| 291 | builderListen() { | 300 | builderListen() { |
| 292 | Column() { | 301 | Column() { |
| 293 | - Image(this.currentStatus === PlayerConstants.STATUS_START ? $r("app.media.icon_voice_playing") : $r("app.media.icon_listen")) | 302 | + Image(this.currentStatus === PlayerConstants.STATUS_START ? $r("app.media.icon_voice_playing") : |
| 303 | + $r("app.media.icon_listen")) | ||
| 294 | .width(24) | 304 | .width(24) |
| 295 | .height(24) | 305 | .height(24) |
| 296 | .aspectRatio(1) | 306 | .aspectRatio(1) |
sight_harmony/features/wdDetailPlayShortVideo/src/main/resources/base/media/icon_voice_playing.gif
0 → 100644
36.6 KB
| @@ -44,7 +44,7 @@ export default struct CustomDialogComponent { | @@ -44,7 +44,7 @@ export default struct CustomDialogComponent { | ||
| 44 | .fontSize(14) | 44 | .fontSize(14) |
| 45 | .fontColor($r('app.color.dialog_private_text_color')) | 45 | .fontColor($r('app.color.dialog_private_text_color')) |
| 46 | } | 46 | } |
| 47 | - .width('90%') | 47 | + .width('90%').lineHeight(22) |
| 48 | Row(){ | 48 | Row(){ |
| 49 | 49 | ||
| 50 | // Button(){ | 50 | // Button(){ |
| @@ -135,6 +135,12 @@ export default struct CustomDialogComponent { | @@ -135,6 +135,12 @@ export default struct CustomDialogComponent { | ||
| 135 | .width('90%') | 135 | .width('90%') |
| 136 | .fontColor($r('app.color.dialog_text_color')) | 136 | .fontColor($r('app.color.dialog_text_color')) |
| 137 | .fontSize(14).margin({top:20}) | 137 | .fontSize(14).margin({top:20}) |
| 138 | + | ||
| 139 | + Divider() | ||
| 140 | + .color('#f5f5f5') | ||
| 141 | + .width('100%') | ||
| 142 | + .strokeWidth(1) | ||
| 143 | + .padding({left:16,right:16,top:22}) | ||
| 138 | Row() { | 144 | Row() { |
| 139 | Text($r('app.string.dialog_button_disagree')) | 145 | Text($r('app.string.dialog_button_disagree')) |
| 140 | .fancy() | 146 | .fancy() |
| @@ -154,7 +160,7 @@ export default struct CustomDialogComponent { | @@ -154,7 +160,7 @@ export default struct CustomDialogComponent { | ||
| 154 | }) | 160 | }) |
| 155 | 161 | ||
| 156 | } | 162 | } |
| 157 | - .margin({ bottom: '21lpx',top:'42lpx' }) | 163 | + .margin({ bottom: '21lpx',top:'22lpx' }) |
| 158 | 164 | ||
| 159 | } | 165 | } |
| 160 | .width('528lpx') | 166 | .width('528lpx') |
-
Please register or login to post a comment