cancel
Showing results for 
Search instead for 
Did you mean: 

Access a view from Fiori Tile

0 Kudos
189

Hi everyone.

I have a project that I want to access one view from one tile and other view from another tile, without extra code, only with Tile configuration. Is that possible?

This is my routing:

"routing": {
          "config": {
            "routerClass": "sap.m.routing.Router",
            "viewType": "XML",
            "viewPath": "***********",
            "controlId": "App",
            "clearTarget": false,
            "controlAggregation": "pages"
          },
          "targets": {
            
            "CockpitAcoes": {
            "viewName": "CockpitAcoes",
            "viewId": "CockpitAcoes",
            "transition": "slide"
            },
            
            "TesteDEX": {
            "viewName": "TesteDEX",
            "viewId": "TesteDEX",
            "transition": "slide"
            },
            
            "TesteDefault": {
            "controlAggregation": "pages",
            "viewName": "TesteDefault",
            "viewId": "TesteDefault",
            "viewLevel": 1,
            "transition": "slide"
            }
            
          },
         "routes": [
              
              {
                "pattern": "CockpitAcoes",
                "name": "CockpitAcoes",
                "target": [
                  "CockpitAcoes"
                  ]
              },
              
              {
                "pattern": "TesteDEX",
                "name": "TesteDEX",
                "target": [
                  "TesteDEX"
                  ]
              },
              
              {
                "pattern": "",
                "name": "TesteDefault",
                "target": [
                  "TesteDefault"
                  ]
              }
              
          ]
      }

I have tried this configuration but when I click in the tile the "&/TesteDEX" does not appear in the URL, so the app routes to the "" pattern which is the TesteDefault view (blank page).

If I manually type "&/TesteDEX" in the URL the view TesteDEX is show so I know everything works, but how to achieve this via Tile configuration? Is it possible?

And should both tiles use the same target mapping? They're going to the same project, but accessing different views.

Thanks for any response.

Accepted Solutions (0)

Answers (0)