8,923 questions
0
votes
1
answer
32
views
AngularJS-MVVM-Problem with binding the view and the model (scope)
I didn't understand where is the problem, I'm studying a new course in Coursera I'd copied the same code, but it seems that the scope doesn't work! Can u please help me? Thank you in advance.
enter ...
2
votes
2
answers
91
views
Is there a way to discontinue a forEach loop once you reach a certain key:value pair in the array?
I'm still very new to Javascript and software development in general as this is my first job, and right now I am debugging a critical defect related to validation.
I have a scenario where I have an ...
0
votes
1
answer
44
views
AngularJS scope variable value change not reflecting across controllers
In my angularjs, i have two controllers and use the variable which is referred in UI. From UI I am calling method OpenPage of NumTwoController which updates value of variable1 and NumOneController ...
1
vote
1
answer
215
views
Show and hide button when value is true in AngularJS
I got an application which uses the 'oidc-client' module, which redirects and if logged in properly in that website I return the value {{auth?.loggedIn}} in my HTML. This value can either be true or ...
1
vote
1
answer
133
views
how to get html dropdown selected value in ng-repeat div angularjs
On button click need to get the dropdown values of each row dont know where the issue is not success in retrieving,the controller goes here,
$scope.values = [];
$scope.Benifit = [{ 'BenefitType': ""...
0
votes
1
answer
617
views
How to set scope for AngularJS component
Suppose I build an AngularJS component
function FooController($scope, $element, $attrs, $http) {
var ctrl = this;
ctrl.bar = "WIBBLE";
}
angular.module("app").component("foo", {
templateUrl:...
0
votes
1
answer
77
views
AngularJS - Referring to a $scope name/ng-model that has '.' in it
I'm having trouble using an ng-model in a filter function.
The input is currently named "search.anything". I can't change the name as it will effect other filters.
I want to use it as a parameter in ...
2
votes
1
answer
110
views
AngualrJs: do I require $scope in my controller for this?
I am trying to emulate this Plunker, specifically adding a button to each row of an ag-grid.
function ageClicked(age) {
window.alert("Age clicked: " + age);
}
function ageCellRendererFunc(params)...
0
votes
0
answers
108
views
Error in the output of open weather app in AngularJS
Helo everyone, I have a problem with angular js , I'm developing a small app for weather, and I am using open weather map , but i have error when i launch my app
here's the result of the app when ...
-1
votes
2
answers
80
views
AngularJS does not represent the controller variables in the view, they are empty
I have this javascript code in a script called index.js and the html in an index.html, the problem is that the "message" variable is not painting it on the screen.
Does anyone know what I'm doing ...
0
votes
1
answer
100
views
How can I get rid of the curly bracket from angularjs output and to clear the screen after the display
I thought I finally understand ng-repeat but now I do not know why the output include the curly bracket and how do I clear the screen after reading the output.
Here is part of the output
{"title":"...
0
votes
1
answer
37
views
Angularjs directive doesn't seems to be working could not able to resolve ngshow
Hi Guys I am an Entry level programmer for angularJS i tried to use ng-show but i dont know why its not been working. I used latest version of Angular js-1.7.9.
<script src="https://cdnjs....
0
votes
0
answers
261
views
Angular MDB module functionality not available in components
There's a group called MDB (Material Design for Bootstrap) that has released some libraries for Angular. Good stuff. However, when I move their snippets from the parent level of app.component.html ...
2
votes
1
answer
1k
views
async function in $onInit not binding to HTML
async function in OnInit firing after template has loaded
Apologies if this has been asked. I couldn't seem to find something speaking to my specific scenario.
In my controller, I define an $onInit ...
1
vote
2
answers
854
views
AngularJS Why is this controller variable not getting updated in the UI?
I'm having a controller using StompJS to subscribe to a url (back-end is Spring Java) that returns an alternating string "list" and "box" every 5 seconds. I want to update my UI element when StompJS ...
1
vote
2
answers
37
views
Show different UI elements using Angularjs 1.7.x ng-repeat (key, val) in nested array
I'm very new to angularjs and I am trying to figure out ng-repeat with key/value pair. I have attached the following image with the expected result. Here's the code I'm trying but the result I am ...
0
votes
1
answer
149
views
JsonResult method not calling through angular call
JsonResult method not calling through $http call,
I am working on a project that uses ASP.NET MVC, AngularJS I am calling a mvc controller from AngularJS. I am getting an jsonresult as in the call to ...
1
vote
1
answer
368
views
Avoid $rootScope.$on — it risks memory leaks
Angularjs: Subscribing to a Service event in Directive doesn't update
I am trying to $emit/$broadcast an event in a Service and subscribe to it inside a Directive but it is not being fired.
In this ...
0
votes
2
answers
493
views
AngularJS Directive two way binding in isolated scope not reflecting in parent scope
I am trying to pass a scope array element to a directive and changing the value of that element inside the directive but when I print the values of the scope element the changes that made inside the ...
1
vote
1
answer
37
views
AngularJS function inside curly binding triggers for each click
I have a use case where I have to bind value to column in table by triggering a call to function which returns username. The table rows is looped using ng-repeat-start and pagination is used to ...
0
votes
1
answer
236
views
http post with formdata and other field control not going to java
I am new to AngularJs. I am trying to upload a image file (.bmp,.jpg, etc) along with its label through Jax-RS post rest API but my control in not going into java post api from my angularjs controller....
1
vote
2
answers
102
views
How to get put $scope.value name inside $('input:radio[name="optradio"][value="$scope.t_color"]') .attr('checked', true);
I am retrieving a row from a database using Angular JS and putting the data inside an editable form; the form consists of multiple radio buttons. I want to make sure when the data is retrieved; the ...
0
votes
2
answers
284
views
How to use Angular $scope.variable from controller 1 in ng-class of div using controller 2
I have 2 controllers boxController.js and homeController.js. On box.html page I initialize the boxController.js. Now, I need to use ng-class on box.html page but the variable I need to use inside ng-...
0
votes
0
answers
171
views
AngularJS - Multiple Modules/Controllers on different pages - only selecting first controller for both pages
I am extremely new to AngularJS and JavaScript in general so any help would be appreciated!
I have two data sources Users and Pets - both are Array objects and I want them to display in a table on ...
0
votes
0
answers
140
views
scope $watch causing infinite digest loop
In a directive I need to watch the formData to check if it is valid so I can enable the submit button. I've added an attribute to the directive in the view which I've added to the directives isolated ...