Posts

angularjs - Getting data from a web service with Angular.js -

im trying data in json format remote ws using angular , im having trouble. data comes web service correctly cant use inside controller. why that? angular code: var booksjson; var app = angular.module('booksinventoryapp',[]); // data ws app.run(function ($http) { $http.get("https://some_api_path").success(function (data) { booksjson = data; console.log(data); //working }); }); app.controller('booksctrl', function ($scope) { $scope.data = booksjson; console.log($scope.data); //not working }); html: <section ng-controller="booksctrl"> <h2 ng-repeat="book in data">{{book.name}}</h2> </section> you should put $http.get inside controller. also, web service returns object not array. ng-repeat should this: book in data.books here working example: var app = angular.module('booksinventoryapp', []); app.controller('booksctrl', function($scope, $...

Missing JS files in WorkExecution app of Maximo Anywhere 7.5.2.1 4Q release -

i have updated maximoanywhere 7.5.2.1 latest release 4q ism library. after building apps , deployed workexecution app, see blank screen. console log complains 2 missing js files 1.copyplanstoactualshandler.js 2.crewutil.js make framework happy, copied on copyplanstoactualhandler.js issuesandreturns app, , created dummy crewutil.js file. after this, presented login screen , able workexecution app. http://10.1.152.114:10080/maximoanywhere/apps/services/preview/workexecution/common/1.0/default/js/application/handlers/copyplanstoactualshandler.js failed load resource: server responded status of 404 (not found) dojo.js:2 error: scripterror(…)(anonymous function) @ dojo.js:2 http://10.1.152.114:10080/maximoanywhere/apps/services/preview/workexecution/common/1.0/default/js/application/business/util/crewutil.js failed load resource: server responded status of 404 (not found) dojo.js:2 error: scripterror(…) these files should exist...

javascript - How to pass 'this' into a Promise without caching outside? -

i have variable called langdataservice.isdataready promise wawiting resolved. upon resolve logic happen. how can pass promise? langdataservice.isdataready.then(function () { this.modalon() }); i know can cache var self_ = this; i'm curious of other alternatives? langdataservice.isdataready.then(function () { this.modalon() }.bind(this));

c++ - How to create a dll for one class that reference other dlls in c# asp.net? -

i have following class trying make dll from using system; using system.collections.generic; using system.linq; using system.web; using nrules.fluent.dsl; using nrule.site.model; using nrule.site.utilities; namespace nrule.site.rules { public class allowatleastonecountryrule : rule { public override void define() { fundprofile productprofile = null; string str = ruletexts.allowatleastonecountryrule; bool enabled = allrules.getdict()[str]; when() .match<fundprofile>(() => productprofile) .exists<fundprofile>( p => enabled, p => ruleviolation(p)); then() .do(_ => productprofile.displayerror(str)); } bool ruleviolation(fundprofile pp) { if (pp.countrieslistp.count==0) return true; if (pp.countrieslistp.any(c => c.allowed)) return false; ...

Logging SOAP message on http gateway spring integration -

i using spring integration (4.0.6) make soap calls rest service using int-http:outbound-gateway , int-ws:outbound-gateway. there way log soap request message in case of exception. <int:gateway id="mygateway" service-interface="myservice"> <int:method name="getdata" request-channel="reqchannel" reply-channel="repchannel"> </int-gateway> my outbound-gateway configured below <int-http:outbound-gateway id="og1" request-channel="reqchannel" url="xxx" http-method="post" reply-channel="repchannel" reply-timeout="10000" message-converters="converter" request-factory="reqfactory"> <bean id="reqfactory" class="org.springframework.http.client.simpleclienthttprequestfactory"> <property name="ctimeout" value="20000"/> <property name="rtimeout" value=...

java - Error:Gradle: Execution failed for task ':core:compileJava'. > Compilation failed -

Image
i make simple game educational purposes got weird gradle error when i'm trying launch game. my source code: build errors i of course googled error because lack of experience didn't found solved problem. in advance naomi, i think problem package name com.mlgfappy.420 , numbers possible causing problem. create new project without numbers in package , try same code.

c# - Simulating real key strokes on an inactive webrowser control -

i have c# winforms app webbrowser control embedded website automation. need send programatically keyboard strokes within app embedded webbrowser control even when app hidden or not focused . setting text html text boxes works not (i.e. html form angularjs validation ignores it's not real typing suppose). i've spent 2 weeks searching , trying different approches: sendinput or sendkeys: works fine when app foregrounded (not good). raising onkeydown , onkeypress events: not working me @ form level , @ webbrowser control level. raising keydown,keypress, keyup events jquery in dom: no success. is there @ solution this? thanks after lot of trial , error found solution. angularjs form validation mechanism waits "change" event happen (and not keydown,keyup,keypress). trigger event wasn't easy (jquery.trigger didn't job). injected following function in webbrowser control , invoked it. setinputtext = function (id, str, x) { var el = $...