We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Angularjs

Hi,

I am trying to run examples that use AngularJs with ejGrid that are on the web but i am getting error:

angular.js:12416 DataManager - executeLocal() : Json data is required to execute
Error: DataManager - executeLocal() : Json data is required to execute
    at u (http://localhost:1480/Scripts/ej/ej.web.all.min.js:10:79674)
    at Object.t.DataManager.executeLocal (http://localhost:1480/Scripts/ej/ej.web.all.min.js:10:26506)
    at Object.t.widget._ensureDataSource (http://localhost:1480/Scripts/ej/ej.web.all.min.js:10:1780571)
    at Object.t.widget._checkDataBinding (http://localhost:1480/Scripts/ej/ej.web.all.min.js:10:1765373)
    at Object.t.widget._init (http://localhost:1480/Scripts/ej/ej.web.all.min.js:10:1761716)
    at Object.<anonymous> (http://localhost:1480/Scripts/ej/ej.web.all.min.js:10:16166)
    at t.widget.n.fn.(anonymous function) [as ejGrid] (http://localhost:1480/Scripts/ej/ej.web.all.min.js:10:17252)
    at c.directive.n.extend.link (http://localhost:1480/Scripts/ej/ej.widget.angular.min.js:10:7092)
    at invokeLinkFn (http://localhost:1480/Scripts/angular.js:8746:9)
    at nodeLinkFn (http://localhost:1480/Scripts/angular.js:8246:11) <div id="Grid" ej-grid="" e-datasource="data" e-allowpaging="true" class="e-grid e-js e-waitingpopup" tabindex="">

3 Replies

IR Isuriya Rajan Syncfusion Team September 11, 2015 08:31 AM UTC

Hi Tomasz,

Thanks for contacting Syncfusion support.

We checked your script error screenshot and suspect that the $scope.data is not referred in your application. Please ensure this in your project,
  


<script>  

       //JSON grid data

var obj = [

                { "EmployeeID": 1, "LastName": "Davolio", "FirstName": "Nancy", "Title":"Sales Representative", "City": "Seattle", "Country": "USA" },

                { "EmployeeID": 2, "LastName": "Fuller", "FirstName": "Andrew", "Title":"Vice President, Sales", "City": "Tacoma", "Country": "USA" },

                

       ];

       

    angular.module('listCtrl', ['ejangular'])

    .controller('PhoneListCtrl', function ($scope) {

        $scope.data = obj; //Grid data bound

    });
    </script>



We have created a sample in jsPlayground,  

Sample

Regards,
Isuriya R



TP Tomasz Pietryka September 11, 2015 04:06 PM UTC

Hi,

 I did copy/paste from that example and still getting same error.

Tom


IR Isuriya Rajan Syncfusion Team September 14, 2015 09:57 AM UTC

Hi Tomasz,

We regret for the inconvenience caused.



We have analysed the reported issue with our sample. We are unable to reproduce the issue. Please share the following details to find the cause of the issue

1.      Please provide your grid rendering code snippet or modify our sample to reproduce your issue.

2.     Could you ensure that your given dataSource is same as in the provided sample dataSource?


We have created a sample in jsPlayground,  
Sample
Regards,
Isuriya R


Loader.
Live Chat Icon For mobile
Up arrow icon