为什么我的code创建剑道小部件? [英] Why isn't my code creating a Kendo widget?

查看:155
本文介绍了为什么我的code创建剑道小部件?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我只是复制演示code这是可以对剑道的网站,但它仍然是不给在输出的任何部件,它是给下面的错误 -

i am just copying the demo code which is available on kendo's site but still it is not giving any widget in output, and it is giving the following error -

类型错误:未定义是不是一个函数的角度JS

"TypeError: undefined is not a function" in angular JS.

我也创建了一个新的jsfiddle它这里是链接 -
http://jsfiddle.net/akki166786/MYe2T/

i have also created a new jsfiddle for it here is the link- http://jsfiddle.net/akki166786/MYe2T/

不要任何人有任何想法是什么在这里错了吗?
 这里是我的code

Do anybody has any idea what is wrong in here? here is my code

<script src="~/Scripts/jquery-1.7.1.min.js"></script>
<script src="~/Scripts/angular/angularjs.js"></script>
<script src="~/Scripts/angular/underscore.js"></script>
<script src="~/Scripts/Kendo/kendo.all.min.js"></script>
<script src="~/Scripts/angular/angular-kendo.js"></script>

<script>
    var myModule = angular.module('myApp', ["kendo.directives"]);
</script>

<div ng-app="myApp">
    <div data-kendo data-role="calendar"></div>
    <ul data-kendo data-role="dropdownlist" ng-transclude>
        <li>element 1</li>
        <li>element 2</li>
    </ul>

</div>

该错误与NG-transclude因为如果我删除DropDownList的部分,然后我没有得到任何错误的一些事情,但仍然没有得到控制caledar也。

The error is some thing related to "ng-transclude" because if i remove the dropdownlist portion then i didnt get any error, but still dont get the caledar control also.

推荐答案

我有同样的问题。

看起来你已经根据您code下页:
http://kendo-labs.github.io/angular-kendo/

It looks like you have based your code on the following page: http://kendo-labs.github.io/angular-kendo/

有不同版本的库(角kendo.js文件):

There are different versions of that library ("angular-kendo.js" file):


  1. 从一个例子(它看起来是一个旧版本)

  2. 另一个从GitHub的根文件夹 https://github.com/kendo-labs/angular-剑道

  3. ,并从GitHub的JS文件夹

一些功能指向不同的/旧版本时起作用。

Some of the functionality works when pointing to the different/older version.

编辑:
解决办法是从浏览器源获取的HTML例子。因此,只要查看页面的来源和使用的例子。这对我的作品。在页面上是古老的。

Solution is to get html example from the browser source. So just view the source of the page and use that example. It works for me. Examples on the page are old.

这篇关于为什么我的code创建剑道小部件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆