title: Remote and local OData service
body: <p>How can I configure manifest.json file so when I run mockserver(mockserver.html) then it goes to the local json data and when I run index.html (main entry to application) then it goes to the remote service. I have a sample manifest.json file from the documentation but not very clear how remote and local service come into play.</p>
  
  <pre><code>{
  "_version": "1.1.0",
  "sap.app": {
      "_version": "1.1.0",
      "id": "xxx",
      "type": "application",
      "title": "{{appTitle}}",
      "description": "{{appDescription}}",
      "applicationVersion": {
          "version": "1.0.0"
      },
      "dataSources": {
                  "mainService": {
                      "uri": "https://services.odata.org/V2/Northwind/Northwind.svc/",
                      "type": "OData",
                      "settings": {
                          "odataVersion": "2.0",
                          "localUri": "localService/metadata.xml"
                      }
                  }
              }
  },
  
  "sap.ui": {
      "_version": "1.1.0",
      "technology": "UI5",
      "icons": {
          "icon": "",
          "favIcon": "",
          "phone": "",
          "phone@2": "",
          "tablet": "",
          "tablet@2": ""
      },
      "deviceTypes": {
          "desktop": true,
          "tablet": true,
          "phone": true
      },
      "supportedThemes": [
          "sap_hcb",
          "sap_bluecrystal"
      ]
  },
  
  "sap.ui5": {
      "_version": "1.1.0",
      "rootView": {
          "viewName": "xxx.view.Main",
          "type": "XML"
      },
      "dependencies": {
          "minUI5Version": "1.30.0",
          "libs": {
              "sap.ui.core": {},
              "sap.m": {},
              "sap.ui.layout": {}
          }
      },
      "contentDensities": {
          "compact": true,
          "cozy": true
      },
      "config": {
            "productLocal": "localService/mockdata/products.json",
            "productRemote": "/some remote end point"
          },
  
      "products": {
              "dataSource": "mainService"
          }
  }
  </code></pre>
  
  <p>}</p>
  
  <p>Controller code</p>
  
  <pre><code>var oModel = new sap.ui.model.odata.ODataModel("/", true);
  
                  //var data = oModel;
                  //console.log(data);
                  var inputModel = new JSONModel("../model/inputs.json");
                  var productsModel = new JSONModel();
  
                  oModel.read("/ProductSet",
                      null,
                      null,
                      false,
                      function _OnSuccess(oData, response) {
                          console.log(oData);
                          console.log(response);
                          var data = {"ProductCollection" : oData.results};
                          productsModel.setData(data);
  
  
                      },
                      function _OnError(error) {
                          console.log(error);
                      });
  
                  //set model(s) to current xml view
                  this.getView().setModel(inputModel, "inputModel");
                  this.getView().setModel(productsModel);
  </code></pre>
  
  <p>Thanks for the help.</p>