Sapui5 未显示页面内容
我正在尝试制作一个简单的SAPUI5页面,内容中包含文本。但只显示页眉和页脚,而不显示内容。无法理解为什么。此外,当我试图在谷歌Chrome中将其模拟为手机时,甚至页脚中的按钮都不会显示出来 代码(index.html):Sapui5 未显示页面内容,sapui5,Sapui5,我正在尝试制作一个简单的SAPUI5页面,内容中包含文本。但只显示页眉和页脚,而不显示内容。无法理解为什么。此外,当我试图在谷歌Chrome中将其模拟为手机时,甚至页脚中的按钮都不会显示出来 代码(index.html): sap.ui.controller(“my.controller”{ onInit:function(){ } }); var myView=sap.ui.xmlview(“myView”{viewContent:jQuery('#view1').html()});// m
sap.ui.controller(“my.controller”{
onInit:function(){
}
});
var myView=sap.ui.xmlview(“myView”{viewContent:jQuery('#view1').html()});//
myView.placeAt(“内容”);
请帮忙。谢谢如果您将
sap.m.Page
控件包装在sap.m.App
控件中,它将为您提供所需的内容
<mvc:View
xmlns:mvc="sap.ui.core.mvc"
controllerName="my.controller"
xmlns="sap.m">
<App>
<Page
title="Centered Title"
class="marginBoxContent"
showNavButton="true">
...
</Page>
</App>
</mvc:View>
...
您也不需要
height=“100%”
属性。如果将sap.m.Page
控件包装在sap.m.App
控件中,它将为您提供所需的内容
<mvc:View
xmlns:mvc="sap.ui.core.mvc"
controllerName="my.controller"
xmlns="sap.m">
<App>
<Page
title="Centered Title"
class="marginBoxContent"
showNavButton="true">
...
</Page>
</App>
</mvc:View>
...
您也不需要
height=“100%”
属性。我也遇到了同样的问题,应用程序运行良好。。。但我很好奇…因为页面是一个控件,它有自己的“createContent”方法,难道它不能呈现它的内容吗?我也有同样的问题,应用程序运行得很好。。。但我很好奇……因为页面是一个控件,它有自己的“createContent”方法,难道它不能呈现它的内容吗?