SAPUI5 - 实施智能变体管理

时间:2018-04-03 10:12:13

标签: sapui5 sap-fiori

我已经实现了智能表与TablePersonalisation& VariantManagement。我已将我的应用程序部署在ABAB存储库&测试。当我保存一个新变种时,它会被保存。但它没有被检索。

XML

我没有为控制器中的变体管理编写任何代码。下面是传递的json数据的屏幕截图。保存在后端。

Request Sent

This is the error in console.

domain:8010 / sap / bc / lrep / flex / data / tracking.Component not found。

请建议。

1 个答案:

答案 0 :(得分:0)

我遇到了同样的问题,要解决该问题,我必须如下修改neo-app.json中的路由。就我而言,我有一个ABAP后端系统,而我现在的理解方式是,这些路由可以帮助确定变体的持久化位置。看:

"path": "/sap/bc/lrep/changes", "path": "/sap/bc/lrep/variants", "path": "/sap/bc/lrep/flex/settings", "path": "/sap/bc/lrep/flex/data"

neo-app.json内容:

{
  "welcomeFile": "/webapp/index.html",
  "routes": [
    {
      "path": "/resources",
      "target": {
        "type": "service",
        "name": "sapui5",
        "entryPath": "/resources"
      },
      "description": "SAPUI5 Resources"
    },
    {
      "path": "/test-resources",
      "target": {
        "type": "service",
        "name": "sapui5",
        "entryPath": "/test-resources"
      },
      "description": "SAPUI5 Resources"
    },
    {
      "path": "/webapp/resources",
      "target": {
        "type": "service",
        "name": "sapui5",
        "entryPath": "/resources"
      },
      "description": "SAPUI5 Resources"
    },
    {
      "path": "/webapp/test-resources",
      "target": {
        "type": "service",
        "name": "sapui5",
        "entryPath": "/test-resources"
      },
      "description": "SAPUI5 Test Resources"
    },
    {
      "path": "/sap/opu/odata",
      "target": {
        "type": "destination",
        "name": "S4H",
        "entryPath": "/sap/opu/odata"
      },
      "description": "S4H"
    },
    {
      "path": "/sap/bc/lrep/flex/data",
      "target": {
        "type": "destination",
        "name": "S4H",
        "entryPath": "/sap/bc/lrep/flex/data"
      },
      "description": "S4H_data"
    },
    {
      "path": "/sap/bc/lrep/flex/settings",
      "target": {
        "type": "destination",
        "name": "S4H",
        "entryPath": "/sap/bc/lrep/flex/settings"
      },
      "description": "S4H_settings"
    }      
 ,
    {
      "path": "/sap/bc/lrep/changes",
      "target": {
        "type": "destination",
        "name": "S4H",
        "entryPath": "/sap/bc/lrep/changes"
      },
      "description": "S4H_changes"
    }  
 ,
    {
      "path": "/sap/bc/lrep/variants",
      "target": {
        "type": "destination",
        "name": "S4H",
        "entryPath": "/sap/bc/lrep/variants"
      },
      "description": "S4H_variants"
    }  
  ],
  "sendWelcomeFileRedirect": true
}