简体   繁体   English

如何从 Fiori 概览页面 (OVP) 导航?

[英]How to navigate from Fiori Overview Page (OVP)?

Trying to make a POC on Overview Page Cards with navigation.尝试在带有导航的概览页面卡上制作 POC。 I have followed a few tutorials in setting up the cards and annotations using the Northwind OData service.我遵循了一些使用 Northwind OData 服务设置卡片和注释的教程。

I want to navigate to another app by clicking on the cards.我想通过点击卡片导航到另一个应用程序。 The docs say this is done using intent-based navigation . 文档说这是使用intent-based navigation This app I am trying to navigate to is registered in Fiori Launchpad with semantic object of "Northwind" and action as "Display"我试图导航到的这个应用程序在 Fiori Launchpad 中注册,语义对象为“Northwind”,动作为“Display”

I have the Employees card setup in the manifest.json and it displays the records fine.我在 manifest.json 中设置了员工卡,它可以很好地显示记录。

However, when I add the navigation parameters in the annotationPath and identificationAnnotationPath , the data is not displayed and the navigation doesn't work.但是,当我在annotationPathidentificationAnnotationPath添加导航参数时,不显示数据并且导航不起作用。

Manifest.json card snippet Manifest.json 卡片片段

            "card00": {
                "model": "NorthwindModel",
                "template": "sap.ovp.cards.table",
                "settings": {
                    "title": "{{card00_title}}",
                    "category": "{{card00_category}}",
                    "subTitle": "{{card00_subTitle}}",
                    "entitySet": "Employees",
                    "annotationPath": "com.sap.vocabularies.UI.v1.LineItem#Northwind-Display",
                    "identificationAnnotationPath": "com.sap.vocabularies.UI.v1.Identification#Northwind-Display"
                }
            }

I've also tried leaving out the action, but I get the same results.我也试过省略这个动作,但我得到了相同的结果。

What am I doing wrong and what is the proper way to navigate to apps from Overview Page Cards?我做错了什么,从概览页面卡片导航到应用程序的正确方法是什么? I'm unable to find any resources on this topic.我找不到有关此主题的任何资源。

I happened to come across your question and see that you have found the documentation about card navigation.我碰巧遇到了你的问题,看到你找到了关于卡片导航的文档。 Although you might already have found a solution, I thought I would mention that there is also documentation about annonotations for intent-based navigation - Annotations Used in Overview Pages (com.sap.vocabularies.UI.v1.DataFieldForIntentBasedNavigation).尽管您可能已经找到了解决方案,但我想我会提到还有关于基于意图的导航的注释的文档 - 概览页面中使用的注释(com.sap.vocabularies.UI.v1.DataFieldForIntentBasedNavigation)。 Perhaps this document might be helpful or a possible future reference.也许这份文件可能会有所帮助或将来可能的参考。

 <Record Type="com.sap.vocabularies.UI.v1.DataFieldForIntentBasedNavigation">
        <PropertyValue Property="SemanticObject" String="Action"/>
        <PropertyValue Property="Action" String="display"/>
        <PropertyValue Property="Label" String="northwinddemo"/>
        <Annotation Term="com.sap.vocabularies.UI.v1.Importance" EnumMember="com.sap.vocabularies.UI.v1.ImportanceType/Medium"/>
    </Record>

try this.试试这个。 maybe it should work.也许它应该工作。

You can try using the below annotation.您可以尝试使用以下注释。

<Record Type="com.sap.vocabularies.UI.v1.DataFieldForIntentBasedNavigation">
                            <PropertyValue Property="SemanticObject" String="Action"/>
                            <PropertyValue Property="Action" String="toappnavsample"/>
                            <PropertyValue Property="Label" String="Navigation from line item"/>
                            <Annotation Term="com.sap.vocabularies.UI.v1.Importance" EnumMember="com.sap.vocabularies.UI.v1.ImportanceType/Medium"/>
                        </Record>

Here toappnavsample is the name of the application you want to navigate to on the Fiori launchpad.这里的 toappnavsample 是您要在 Fiori 启动板上导航到的应用程序的名称。

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

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