Sapui5 sap.m.ObjectListItem:需要在标题中保留空格(制表符)
我正在使用Sapui5 sap.m.ObjectListItem:需要在标题中保留空格(制表符),sapui5,Sapui5,我正在使用sap.m.ObjectListItem。绑定时,我需要{Item}&{ComponentDesc}之间的制表符空间 例如,like\tObjectListItem仅用于一个值。在您的情况下,最好使用CustomListItem <CustomListItem> <HBox width="100%"> <VBox> <Label emphasized="true" text="{i18n>uBOMItem}: {I
sap.m.ObjectListItem
。绑定时,我需要{Item}
&{ComponentDesc}
之间的制表符空间
例如,like
\t
ObjectListItem
仅用于一个值。在您的情况下,最好使用CustomListItem
<CustomListItem>
<HBox width="100%">
<VBox>
<Label emphasized="true" text="{i18n>uBOMItem}: {Item}" />
</VBox>
<VBox class="sapUiSmallMarginBegin">
<Label emphasized="true" text="Component: {ComponentDesc}" />
</VBox>
<VBox width="50%" justifyContent="End">
<ObjectNumber number="{ComponentNo}" />
</VBox>
</HBox>
</CustomListItem>
在一个标签、文本或类似内容中输出模型中的两个数据绑定是不干净的。你应该分割输出。如果一个控件中有i18n标签和数据绑定,我会例外。目前,
sap.m.ObjectListItem
不支持呈现标题空白。
我同意将多个标签(“{i18n>uBOMItem}:”
和“组件:”
)合并为一个标签是不干净的。话虽如此,但是,如果确实需要这样做,则需要扩展ObjectListItem 例如: 在内部,ObjectListItem从
sap.m.Text
呈现其标题。文本控件有一个名为renderWhiteSpace
的公共属性,我们可以使用它来呈现选项卡