简体   繁体   English

如何使用 SAPUI5 访问 SAP 后端表?

[英]How to access SAP backend tables using SAPUI5?

I'm totally new to SAPUI5 and after learning the classic Dynpro and developing on the SAP GUI I got a few questions about how SAPUI5 works.我对 SAPUI5 完全陌生,在学习了经典的 Dynpro 并在 SAP GUI 上进行开发后,我对 SAPUI5 的工作方式有一些疑问。

As SAPUI5 is developed in Eclipse I'm interested how it could get data from a SAP NetWeaver table.由于 SAPUI5 是在 Eclipse 中开发的,我对它如何从 SAP NetWeaver 表中获取数据很感兴趣。

Do I need a remote call for that?我需要远程调用吗? And how does the Eclipse program connect and communicate with NetWeaver? Eclipse 程序如何与 NetWeaver 连接和通信?

I didn't find an answer to that, maybe it's just too simple.我没有找到答案,也许这太简单了。

Maybe someone have some tips or best practice to share?也许有人有一些技巧或最佳实践可以分享?

Thank you.谢谢你。

SAPUI5 apps are running inside the user's browser and connect to any server with HTTP. SAPUI5 应用程序在用户的浏览器中运行,并通过 HTTP 连接到任何服务器。 This is actually the very standard way of creating client-side web applications.这实际上是创建客户端 Web 应用程序的非常标准的方式。 You can use any kind of HTTP server as long as they offer the data at a URL and offer the data in a well-known format like JSON or XML, but when you have a Netweaver server, Gateway and using OData would be the recommended way to go.您可以使用任何类型的 HTTP 服务器,只要它们在 URL 处提供数据并以众所周知的格式(如 JSON 或 XML)提供数据,但是当您拥有 Netweaver 服务器时,推荐使用网关和使用 OData 的方式去。

Don't think too much about Eclipse.不要对 Eclipse 考虑太多。 It is not at all required to develop SAPUI5 applications, it just used to be a well-supported editor with additional plugins in the past.开发 SAPUI5 应用程序根本不需要它,它过去只是一个支持良好的编辑器,带有附加插件。 Actually SAP WebIDE would be the best-integrated editor now, but you can still use anything from vim to Notepad.实际上,SAP WebIDE 现在是最好的集成编辑器,但您仍然可以使用从 vim 到记事本的任何东西。

There are plenty of Gateway/SAPUI5 guides on the web, also the official UI5 documentation contains chapters about getting data from the server with OData.网络上有很多 Gateway/SAPUI5 指南,官方 UI5 文档也包含有关使用 OData 从服务器获取数据的章节 I'd recommend doing the entire walkthrough to any beginner!我建议对任何初学者进行整个演练!

您必须编写一个服务(据我所知最好使用 SAP NetWeaver Gateway)来公开您希望从后端系统访问的任何数据和操作。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM