Closed kongweibo-yy closed 1 week ago
你的调用本身就不对! 设置 你的布局emptyLayout 是否显示错误页面 showEmptyLayout
`
@BuilderParam
emptyLayout?: () => void;
@BuilderParam
errorLayout?: () => void;
@BuilderParam
loadingLayout?: () => void;
@Prop
showEmptyLayout?: boolean;
@Prop
showErrorLayout?: boolean;
@Prop
showLoadingLayout?: boolean;
原本想要在列表无数据时,设置一个当前页面没有数据的提示,但是无数据,itemLayout无效,里面的布局无法显示,请问怎么解决呀 @Builder itemLayout(item:string, index: number) { if (this.data == undefined || (this.data != undefined && this.data.length <= 0)) { Column() { Text(
${this.tabsTitle}列表没有查询到相关数据
) .fontSize(this.normalSize * this.unFontSize + 'fp') }.width(CommonConstants.FULL_PARENT) .height(CommonConstants.FULL_PARENT) .justifyContent(FlexAlign.Center) } Column() { this.ListItemStyle(item, index) }.padding({ left: 20, right: 20, top: 10, bottom: 5 }) .height(70) .width('100%') }