title: Uncaught TypeError:this.getRouter is not a function
body: <p>Tring to add an <code>object</code> route to the main route(table page), but return <code>this.getRouter is not a function</code> error. </p>
  
  <p>In main Controller: </p>
  
  <pre><code>    onPress : function(oEvent) {
          this._showObject(oEvent.getSource());
      },
  
      _showObject : function (oItem) {
          this.getRouter().navTo("object", {
              objectId: oItem.getBindingContext().getProperty("task_id")
          });
      },
  </code></pre>
  
  <p>In Component.js(I've checked , it's already loaded, no error produced)</p>
  
  <pre><code>sap.ui.define(["sap/ui/core/UIComponent"],
  function (UIComponent) {
      "use strict";
  
      return UIComponent.extend("cts.mobile.Component", {
          metadata : {
              rootView : "cts.mobile.view.TaskTest",
              routing : {
                  "config": {
                      "routerClass": "sap.m.routing.Router",
                      "viewType": "XML",
                      "viewPath": "cts.mobile.view",
                      "controlId": "taskapp", //in task.view.xml
                      "controlAggregation": "pages",
                      "async": true
                  },
                  "routes": [
                      {
                          "pattern": "",
                          "name": "task",
                          "target": "task"
                      },
                      {
                          "pattern": "ProductCollection/{objectId}",
                          "name": "object",
                          "target": "object"
                      }
                  ],
                  "targets": {
                      "worklist": {
                          "viewName": "TaskTest",
                          "viewId": "TaskTest",
                          "viewLevel": 1
                      },
                      "object": {
                          "viewName": "Object",
                          "viewId": "object",
                          "viewLevel": 2
                      }
                  }
              }
          },
  
          init : function () {
              UIComponent.prototype.init.apply(this, arguments);
  
              // Parse the current url and display the targets of the route that matches the hash
              this.getRouter().initialize();
          }
  
      });
  }
  </code></pre>
  
  <p>);</p>
  
  <p>this value in _showObject: </p>
  
  <p><code>f {mEventRegistry: Object, oView: f}</code></p>
  
  <p>How to fix this error? </p>