可视化框架折线图不显示在对象页面部分中



我的sapui5应用程序中有一个折线图,我想把它放在对象页面小节中。当我把它放在页面的正常布局中时,它正在工作。但是当我将其分成一个片段并从对象页面小节调用时,什么也没显示。

这是我的片段:

<core:FragmentDefinition xmlns:m="sap.m" xmlns:core="sap.ui.core" xmlns:viz="sap.viz.ui5.controls" xmlns:layout="sap.ui.layout"
    xmlns:mvc="sap.ui.core.mvc" xmlns:viz.feeds="sap.viz.ui5.controls.common.feeds" xmlns:viz.data="sap.viz.ui5.data" height="100%" xmlns:common="sap.suite.ui.commons">
    <layout:FixFlex>
        <layout:flexContent>
            <viz:Popover id="idPopOver"></viz:Popover>
            <viz:VizFrame id="idLineGraph" uiConfig="{applicationSet:'fiori'}" height='100%' width="100%" vizType='line'></viz:VizFrame>
        </layout:flexContent>
    </layout:FixFlex>
</core:FragmentDefinition>

这是我的小节:

<ux:ObjectPageSection id="idChart" title="{i18n>chartSection}" titleUppercase="false">
                            <ux:subSections>
                                <ux:ObjectPageSubSection>
                                    <ux:blocks>
                                        <core:Fragment id="idChartFragment" fragmentName="mynamespace.zmm_stok_list.fragments.grafik" type="XML"/>
                                    </ux:blocks>
                                </ux:ObjectPageSubSection>
                            </ux:subSections>
                        </ux:ObjectPageSection>

我也看到了那个问题Q,但看起来OP更愿意保留自己找到的答案。

最后,有一个关于几乎相同事物的博客,但使用CD views.blog

但是你知道 cds 视图不像 xml 视图,我想它们是自动生成的,我们看不到使用了哪些组件。

所以我仍然找不到这样做的方法。但是,如果我直接将 vizframe 放在对象布局部分(而不是在片段中分隔(,并给出带有像素的 vizframe 的高度,它就可以了。不多,但我对此没意见。

Ps:当 vizframe 在片段中分离时,用像素给出其高度也不起作用。

最新更新