列表 第页
我试图创建一个使用茉莉花正在通过茶匙运行角一些单元测试。测试运行的,但是我有一个简单的测试只是为了测试失败控制器的存在。我有以下的测试设置。I'm trying to create some unit tests in Angular using Jasmine being run through Teaspoon....阅读全文
我一直在试图用承诺一定的时间后结束用户会话。问题是,每当服务定义的函数是由$超时触发函数调用,功能似乎是不确定的。我认为这是某种范围的问题,但我还没有设法解决这个问题对我自己的。 app.service('sessionService',函数($超时){ VAR closeSession =功能(){...阅读全文
所以,我有这个code一个问题,我不`吨知道为什么我得到这个错误So, I have a problem with this code and I don`t know why I get that error$scope.veilingen = {};$http.get('./helpers/get/Veili...阅读全文
我想实现一个简单的$ HTTP POST具有角这个控制器中。I am trying to implement a simple $http post with angular within this controller.app.controller('LoginCtrl',['$scope','admin','$...阅读全文
也许我缺少一些种类的财产,但我按照这个项目,我让我的控制器此错误。Maybe I'm missing some kind of property, but I'm follow this project and I'm getting this error in my controller.TypeError: l...阅读全文
我试图从显示的数据火力点,我有以下code。我已经宣布火力依赖我的应用程序。i am trying to display data from firebase and i have below code. I already declared firebase dependency for my app..cont...阅读全文
这两项工作,但什么是每个实现之间的实际差异?我敢肯定有每种方法背后的逻辑推理,我希望得到启发。Both of these work, but what is the actual difference between each implementation? I'm sure there is a logical r...阅读全文
我想建立采用了棱角分明的JS多选名单。我得到一个奇怪的类型错误:a.foreach不是一个功能,我似乎无法弄清楚的时候。 I am trying to build a multiselect list using angular js. I am getting a weird TypeError: a.foreac...阅读全文
确定这是从学习的角度三部曲今天的最后一个问题:ok this is the last question from todays trilogy of learning Angular: part1part2我收到以下面的错误(试图选择用户视图时:I am getting to following error(wh...阅读全文
我想开始使用卡玛 - 茉莉,我不知道为什么这个测试失败:I'm trying to get started with karma-jasmine and I'm wondering why this test fails:it("should call fakeFunction", function() {spyO...阅读全文
在运行咕噜测试在约曼(1.0RC1)脚手架角(1.0.7)的应用程序,我得到了以下错误:While running grunt test on a Yeoman (1.0RC1) scaffolded Angular (1.0.7) app, I'm getting the following error:Type...阅读全文
我是新来Angularjs,我是跟随教程,但我得到了标题中的错误。 I am new to Angularjs and I was following a tutorial but I got the error in the title. HTML code:HTML code:
尝试一个简单的HTML打字稿应用程序,并不能让过去试图Angularjs集成到解决方案时在主题指出这个错误。基本上,我有一个简单的index.html页面如下: <!DOCTYPE HTML>< HTML LANG =ENNG-应用>< HEAD> <间的charset...阅读全文
我有一些问题,把角谷歌,地图在我的网站工作。I'm having some issues to put angular-google-maps working on my website.有需要的库之后(googleapis / lodash.js /角谷歌-maps.min.js),我无法配置的应用程序。Aft...阅读全文
我有一个 angularjs 服务,让我的 JSON 数据。I have an angularjs service to get my json data.// Controller.js file$scope.data=Events.query();$scope.getEventtypes = function...阅读全文
我新的角度和我有一个问题。I'm new to angular and i have a question.即时通讯使用1.3.11版本的棱角分明。Im using 1.3.11 version of angular.香港专业教育学院写了一个简单的HTML code,它是使用简单的角度和即时得到以下错误:Iv...阅读全文
是否与下面的代码片段的任何表面上的问题:Is there any ostensible issue with the following snippet:
由于Chrome API函数的异步和我不能得到它的返回值我有一个问题。请看下面的code。的我使用angularjs 的I am having a problem because chrome api functions are async and I cant get its return value. Consi...阅读全文
我建立一个应用程序来动态地从数据库中AngularJS加载和显示数据,但是当我尝试访问我的API(使用HTTP $()或$ http.get()),我收到errrors。$ http.get()错误:类型错误:未定义不是一个函数,$ HTTP()错误:类型错误:对象不是一个函数 I'm building an app...阅读全文
我试图使该会影响元素的宽度/高度指令。翻翻例子我已经看到了你可以参考相应的功能获得/设置宽度/高度。例如,在指令链接功能我尝试做:I am trying to make a directive that would influence element width/height. Looking through exa...阅读全文
目前,我通过这本书的工作我的方式教自己的Android应用程序开发的24小时,由萨姆斯出版。我是比较新的的Java,Android或其他方式。我在ActionScript 3,具有足够的相似与Java的语言本身并不难把握一个非常坚实的背景,但我仍对背后的一些书中的code样本的基本原理的一些问题。例如,这里有随...阅读全文
我想一个函数来计算numerology.For例如,如果我输入XYZ,那么我的输出应为3。I want a function to calculate numerology.For example if i enter "XYZ" then my output should be 3 .下面是如何变成了3:X =...阅读全文
我需要找到不同的维度一个数组的最大值和最小值(将1-D,2-D和多至N维数组)在我的计划。I need to find max and min value of a array in different dimensions(will be 1-d, 2-d and up to N dimension array)...阅读全文
我想创建一个类似于在iOS警报视图弹出,使用jQuery Mobile 1.4.3。我需要我的警告消息从JavaScript事件触发,像一个OK按钮显示Ajax响应调用Web服务的确认消息。我的第一个问题是通过数据直通弹出一个小窗口,其中大部分搜索我发现那位是不可能的。我发现,code和平,这几乎是我所需要的:$('...阅读全文
就像在PHP中有 func_num_args 和 func_get_args ?推荐答案使用参数。您可以访问它像一个数组。使用与arguments.length 为参数的个数。Use arguments. You can access it like an array. Use arguments.length...阅读全文
由于 [1,2,3,4,5] ,我怎么可以这样做Given [1,2,3,4,5], how can I do something like 1/1, 1/2, 1/3,1/4,1/5, ...., 3/1,3/2,3/3,3/4,3/5,.... 5/1,5/2,5/3,5/4,5/5我想存储所有结果,找到最小,...阅读全文
如ccddcc中的字符串abaccddccefee.g "ccddcc" in the string "abaccddccefe" 我想到了一个解决方案,但它为O(N ^ 2)时间I thought of a solution but it runs in O(n^2) time算法中1:步骤:它是一种强制...阅读全文
我想知道怎么才能隐藏的JavaScript控制台功能,使其不能从它调用。I want to know how can we hide a function from the javascript console so that it can't be called from it.为了让你更好地理解这个问题,假设我...阅读全文
我得到的消息未捕获的类型错误:undefined是不是一个函数当我尝试在我家的控制器调用一个方法建议也许是为什么我得到这个消息?findIdpActivities =功能(PERNR,回调){restEndPoint = ServiceBase的+'主页/ FindIdpActivities;数据={'PERNR':'...阅读全文
我无法与一些Ajax功能。我有一个需要更新记录的选项更改时,一个下拉列表。下面是JavaScript的一个片段:函数changeResponsibleParty(selectObj,targetDiv){VAR IDX = selectObj.selectedIndex;VAR其中= selectObj.optio...阅读全文
function test(){var distance=null;first();second();third();alert(distance);//it shows null always because it take 2 second to complete.}function first(tolat,...阅读全文
我使用的跨域Ajax请求外部API。几乎每隔一段时间失败,与控制台消息:I'm using a cross-domain Ajax request to an external API. Every so often it fails, with the console message:Uncaught TypeE...阅读全文
我有拥有另一个类的对象的类。当我要调用这个类中的一些功能,我得到了上面的错误...查看code,以获得更好的主意!I have a class that holds an object from another class. When I want to call some function from this cl...阅读全文
我遇到以下错误:错误1006:%函数名%不是一个函数Error 1006: %function_name% is not a function我们在命名为 ArrayUtils 出项目2 UTIL类。在他们的所有功能的公共静态。另一名开发者加入功能%函数名%到 ArrayUtils 之一。我在code使用此方法。我...阅读全文
这个问题很简单:我需要实际的变量传递给函数。The problem is simple:I need to pass actual variable to a function.private var test:String = "KKK";trace (" Before --->>> " + test);...阅读全文
我得到了一张code:跟踪((数组[0] [0]));跟踪((数组[0] [0]日期));跟踪((数组[0] [0]为日期)。时间());这是我的输出:周五8月9日12点10分零零秒GMT + 0200 2013真正类型错误:错误#1006:值不是一个函数。...我很困惑。我该如何解决这个问题?//编辑:的哦...阅读全文
是否有可能使用一个字符串值作为函数名称,例如调用在AS3功能VAR函数名:字符串=getDetails;VAR实例1:为MyObject =新的MyObject();instance1.functionName(); //我知道这是错的,但它得到的地步翻过:)更新 从@Taskinoor上访问功能的答案是正确的:实例1...阅读全文
我想将的启用的基于一个函数,有一个或多个参数的返回值的按钮属性。我怎样才能做到这一点?私有函数isUserAllowed(用户名:布尔):布尔{如果(用户名=='汤姆')返回true;如果(用户名=='法案')返回false;}< MX:按钮标签=创建采购订单ID =createPOButton启用=<...阅读全文