同步 ejGrid 不显示(未捕获的引用和未捕获的类型错误)

Syncfusion ejGrid not displaying (uncaught reference and uncaught type error)

本文关键字:类型 错误 引用 ejGrid 显示 同步      更新时间:2023-09-26

我最近被介绍给syncfusion,我正在尝试使用他们的基本网格功能。

我有小提琴中显示的html代码和一个名为orders的单独js文件,其中包含:

        $("#Grid").ejGrid({           
        columns: [
            { field: "Order", headerText: "Order ID", width: 75, textAlign: ej.TextAlign.Right },
            { field: "CustomerID", headerText: "Customer ID", width: 80 },
            { field: "ShipName", headerText: "Ship Name", width: 100 },
            { field: "ShipCity", headerText: "Ship City", width: 100 },
            { field: "Freight", width: 80, format: "{0:C3}", textAlign: ej.TextAlign.Right }
        ]
    });

基本上,我正在尝试在第 3 节中显示一个表格,但不断收到此错误:

jquery.easing.min.js:44 uncatch ReferenceError: jQuery 未定义 jquery.easing.min.js:44(匿名函数)

ej.web.all-latest.min.js:10 未捕获的类型错误:无法读取属性 'extend' of undefined ej.web.all-latest.min.js:10(匿名函数) ej.web.all-latest.min.js:10(匿名函数)

订单.js:30 未捕获类型错误:未定义不是函数 订单.js:30(匿名功能)

我尝试直接使用 js 作为 html 中的脚本标签,但这不起作用。我也尝试将其包装在document.ready函数中,但无济于事。

JsFiddle 示例 http://jsfiddle.net/Ld6mn6xb/

在小提琴中,您在jquery之前引用了jquery easing,因此发生了问题,并且还删除了多个jquery文件。

请在此处找到工作小提琴

JSFiddle

另请参阅以下帮助链接以开始使用Syncfusion ejGrid

ej网格帮助

现在在上面的小提琴中,我已经向网格提供了空数据order.js因为在小提琴中找不到该文件。