陈剑华

feat: 20748 搜索-“钱江视频”,搜索结果切换到人民号tab,动态和单图卡视频未展示文本信息

... ... @@ -22,6 +22,8 @@ export class ContentShareInfoDTO {
@Observed
export class ContentDTO implements BaseDTO {
introduction: string = '';
zhDescription: string = '';
seoTags: string = '';
cornerMark:string = '';
liveType?: string; // 直播新闻-直播状态
... ... @@ -153,6 +155,7 @@ export class ContentDTO implements BaseDTO {
static clone(old: ContentDTO): ContentDTO {
let content = new ContentDTO();
content.zhDescription = old.zhDescription;
content.liveType = old.liveType;
content.seoTags = old.seoTags;
content.appStyle = old.appStyle;
... ...
... ... @@ -81,7 +81,7 @@ export struct CardParser {
@Builder
contentBuilder(contentDTO: ContentDTO) {
// Card6Component({ compDTO: this.compDTO, contentDTO: this.contentDTO })
if (!!contentDTO.contentText) {
if (!!contentDTO.contentText || !!contentDTO.zhDescription || !!contentDTO.introduction) {
SearchContentComponent({
contentDTO,
compDTO: this.compDTO,
... ...
... ... @@ -33,7 +33,7 @@ export struct Card11Component {
}
titleInit() {
const titleInitRes:titleInitRes = SearchShowRed.titleInit(this.contentDTO.title);
const titleInitRes:titleInitRes = SearchShowRed.titleInit(this.contentDTO.title || this.contentDTO.newsTitle);
this.titleMarked = titleInitRes.titleMarked;
this.textArr = titleInitRes.textArr;
}
... ...
... ... @@ -36,7 +36,7 @@ export struct Card20Component {
}
titleInit() {
const titleInitRes:titleInitRes = SearchShowRed.titleInit(this.contentDTO.title);
const titleInitRes:titleInitRes = SearchShowRed.titleInit(this.contentDTO.title || this.contentDTO.newsTitle);
this.titleMarked = titleInitRes.titleMarked;
this.textArr = titleInitRes.textArr;
}
... ... @@ -55,7 +55,7 @@ export struct Card20Component {
isPeopleShipHome:this.isPeopleShipHome, loadImg: this.loadImg
}
) // 标题
if (this.contentDTO.newsTitle) {
if (this.contentDTO.title || this.contentDTO.newsTitle) {
Stack() {
if(this.contentDTO.objectType == '5'){
Notes({ objectType: this.contentDTO.objectType,objectLevel:this.contentDTO.objectLevel }).height(29).align(Alignment.Center)
... ...
... ... @@ -36,7 +36,7 @@ export struct Card6Component {
}
titleInit() {
const titleInitRes:titleInitRes = SearchShowRed.titleInit(this.contentDTO.title);
const titleInitRes:titleInitRes = SearchShowRed.titleInit(this.contentDTO.title || this.contentDTO.newsTitle);
this.titleMarked = titleInitRes.titleMarked;
this.textArr = titleInitRes.textArr;
}
... ... @@ -80,7 +80,7 @@ export struct Card6Component {
}
})
} else {
Span(this.contentDTO.newsTitle)
Span(this.contentDTO.newsTitle || this.contentDTO.title)
}
}
.fontColor(this.clicked ? 0x848484 : 0x222222)
... ...
... ... @@ -34,7 +34,7 @@ export struct SearchContentComponent {
}
titleInit() {
const titleInitRes:titleInitRes = SearchShowRed.titleInit(this.contentDTO.contentText || '');
const titleInitRes:titleInitRes = SearchShowRed.titleInit(this.contentDTO.contentText || this.contentDTO.zhDescription || this.contentDTO.introduction);
// this.titleMarked = titleInitRes.titleMarked;
this.textArr = titleInitRes.textArr;
}
... ...
... ... @@ -457,6 +457,8 @@ export struct SearchResultContentComponent {
let seoTags = value.data?.seoTags
let cornerMark = value.data?.cornerMark
let contentDTO = new ContentDTO();
contentDTO.introduction = value.data.introduction
contentDTO.zhDescription = value.data.zhDescription
contentDTO.liveType = liveType ? liveType : ""
contentDTO.seoTags = seoTags ? seoTags : ""
contentDTO.cornerMark = cornerMark ? cornerMark : ""
... ...
... ... @@ -6,6 +6,8 @@ export class SearchResultContentItem{
}
export class SearchDescription{
introduction: string = ''
zhDescription: string = ''
likeEnable: string = ""
previewUri: string = ""
firstFrameImageBucket: string = ""
... ... @@ -151,7 +153,6 @@ export class SearchDescription{
liveEndTime: string = ""
topicTemplate: string = ""
barrageEnable: string = ""
introduction: string = ""
notice: string = ""
shareTitleLiteral: string = ""
coverHImageUri: string = ""
... ...