Tagged Questions
0
votes
3answers
27 views
how to bind 3 arrays simultaniously using angularjs
I tried using ng-repeat value,group1,group2
i'm getting
grp1
grp2
abc
def
value1
value2
I need
grp1
abc
valu1
grp2
def
valu1
Html:
...
0
votes
1answer
36 views
Dynamically reloading ng-repeat data in the DOM
I have the following code in my view:
<li ng-repeat="i in items">{{i.id}}</li>
I would like the ng-repeat to be trigged dynamically when new values are added/removed from items. As in, ...
0
votes
1answer
16 views
angularjs option list becoms empty when i select an option
I am working on a django-tastypie api application where i am using angularjs as JavaScript framework.what I am doing is i have a list of curriculum objects where each curriculum object contains a list ...
0
votes
2answers
33 views
Javascript convert three arrays to one for use with AngularJS directive
I have a $http call with which I retrieve an array of objects. I make three calls to this endpoint and end up with three arrays like the following:
[
{type: Dog, count: 3}
{type: Cat, count: 4}
...
0
votes
0answers
32 views
Applying filters in AngularJS
I have a table which should show a resultset, filtering the result against the value of a user input:
<input type="search" ng-model="search">
<table>
<tr ng-repeat="person in ...
0
votes
1answer
21 views
Angularjs JavaScript runtime error: 10 $digest() iterations reached. Aborting
I am trying to use bootstrap 2.3.x with angularjs to create a menu bar for my webpage as shown below.
<div class="container" >
<div class="navbar">
<div class="nav-collapse ...
0
votes
0answers
23 views
ng-repeat IE8, parentNode is null or not an object
I'm using AngularJS 1.2.0-rc3, I also tried AngularJS 1.0.8 and the other release candidates, but this problem keeps popping up.
I have an ng-repeat in my template that gets it's array asynchronously ...
0
votes
0answers
25 views
AngularJS - Range slider doesn't work in ng-repeat (plugin)
I am trying to use this plugin in my project to have multiple range slider within ng-repeat. http://prajwalkman.github.io/angular-slider/
The plugin works fine when there is single slider , but when ...
2
votes
1answer
32 views
autoscroll angularjs doesn't seem to work
Hi I'm building a chatapp in angularjs and I want the chatbox to scroll down automatically. I'm using this example that I put in a directive: http://jsfiddle.net/atRkJ/
It works as it is but when I ...
0
votes
3answers
50 views
How to render HTML in a partial with ng-bind-html and $sce inside ng-repeat -> ng-switch -> ng-include?
As mentioned in the title, i can't figure out how to render html inside a partial with ng-bind-html.
Here is a plunker to illustrate.
http://plnkr.co/edit/YFfHsahcum7XA8GcH6b2?p=preview
I tried ...
0
votes
1answer
13 views
Angular orderBy Date
I have an array which I want to order by date in Angular.js:
<tr ng-repeat="er in vm.readerFeeds | orderBy:'-publishedDate'">
<td>{{er.publishedDate}}</td>
</tr>
The ...
0
votes
1answer
30 views
AngularJS multiple selection model data binding
I am using AngularJS v1.2.0-rc.3.
I have a model y with a 1 to many relationship with model x.
Initially, I had a form for model y with a multiple select for xs, something like this:
...
0
votes
3answers
57 views
AngularJS event for when model binding or ng-repeat is complete?
We have a large model and it takes a couple seconds for ng-repeat to bind all the items in the model to the form. We would like to show a spinner while it this is happening. Is there some event that ...
1
vote
2answers
57 views
Angularjs isolates scope directive with ng-repeat
I'm trying to use directive on ng-repeat items each with an isolate scope but it isn't working. I'm looping through each item and coloring it red with the inboxuser-select directive. However, when I ...
0
votes
1answer
31 views
Unable to print scope variable inside ng-repeat
I am trying to associate id inside an ng-repeat loop. Can someone suggest how can i do this?
here is the code
<li ng-repeat="agent in agents">
<chart ...
0
votes
1answer
19 views
AngularJS Filter in rails
I'm trying to make a searchable list of posts on a ruby on rails application that I made. I have AngularJS working on the application. All of the posts are saved on rails in @posts. How would I make ...
1
vote
1answer
15 views
Repeating an object or arrays within an Repeated object in AngularJS
Is there a way to repeat an object or array of items within an object already repeated? As an example if I have this set up:
items = [
{name: 'title', person: [ person1, person2, person3, etc. ]},
...
1
vote
1answer
58 views
AngularJS nested ng-repeat with grouped lists does not loop
My object model is a list of ItemLines, which each contain a number("quantity") of "part". Here is the data structure:
ordersItemLines = [{
"quantity": 1,
"part": {
...
0
votes
3answers
27 views
Angularjs: nested ng-repeat with key reference from one to the another
I want reference the key value from one repeat value to the other. Its a bit hard to explain but here is the jsfiddle http://jsfiddle.net/u75us/163/
I want to get the f_column value from key_var ...
0
votes
1answer
18 views
Ng-options dropdown concat fields if the second one is not empty
I have a table users, every user has a username, but there is also a nullable displayname in the table. I want to show al users in a dropdown with their username, and if available also their ...
0
votes
0answers
27 views
How to get a callback when element will be completely builded
I have custom directive which moves DOM element on every ngShow which returns true. This directive requires dimensions of dom element.
HTML
<div class="span5 search-results__mentions-block" ...
1
vote
1answer
27 views
Angular JS: $index like parameter of a filter
i want to pass the variable $index like parameter of a filter. The code is the next:
HTML:
<div ng-app='myApp' ng-controller="Main" >
<div ng-repeat="i in (filtered = (elements | ...
3
votes
1answer
73 views
Simple One way binding for ng-repeat?
I have read some articles that said ng-repeat would led to poor performance if there is over 2000 items, because there are too many two way binding to watch. I am new to angularjs and have trouble ...
0
votes
1answer
34 views
Avoid duplicates in a repeater are not allowed
Is there any built-in feature on AngularJS to avoid ng-repeater to receive duplicated entries?
Right now I'm using the following code to prevent it:
$scope.tags = ...
0
votes
1answer
22 views
order item in ngrepeat follow property of item
How can I order the post to top-down structure (the post which has highest likes number will be first and the last is the post which lowest likes number). To do that I set oderBy:likes.length but it ...
3
votes
2answers
49 views
angular ng-repeat skip an item if it matches expression
I'm looking for a way to basically tell angular to skip an item in an ng-repeat if it matches an expression, basically continue;
In controller:
$scope.players = [{
name_key:'FirstPerson', ...
1
vote
1answer
31 views
Input field blurs when inline editing in ng-repeat
I am trying to do inline editing on a table of data (See the plunkr)
<table class="table table-bordered">
<tr ng-repeat="data in dataset" >
<td ng-repeat="(key, value) in data" >
...
3
votes
2answers
75 views
ng-repeat not loading data after html has been compiled
I have a directive that copies a bit of html that includes a controller and an ng-repeat. I compile the html and stick it into the dom. I can see that the new html is picking up the scope of the ...
0
votes
1answer
40 views
ng-repeat without duplicates
Is there any "angular way" to avoid displaying duplicates in ng-repeat?
If we add duplicates in the array it will pop-up [ngRepeat:dupes] and this can be solved with ng-repeat="item in items track by ...
0
votes
1answer
43 views
Filtering with multiple checkboxes in angularJS
I'm new to AngularJS. I wrote a program to filter the Item list when i check related check boxes. But here my CheckBoxes are behaving like "Radio" buttons. Anyway, program is working but it is not ...
0
votes
1answer
28 views
angularJS: Why does binding to scope inside a directive result in lost content of ng-repeat?
I have this fairly simple HTML structure:
<div ng-controller="MyCtrl">
<div dir1="xy"><div>dir1static</div><div ng-repeat="item in ...
0
votes
0answers
33 views
$index of ng-repeat inside the attribute (AngularJS)
That's must be very simple,but: have this HTML
<li ng-repeat="title in mainTree">
<a href="#cable{{$index}}">{{title.title}}</a>
</li>
JS tells me, that caught Error: ...
0
votes
1answer
34 views
Angular.js // Getting element by attribute value
Having the following in a json response :
[
"alt_sizes":[
{"width":500,"height":333,"url":"http://..."},
{"width":400,"height":266,"url":"http://..."},
...
0
votes
1answer
26 views
Split for ng repeat item?
Simple question- if I have this in my controller:
$scope.somedata = 'Item 1, Item 2'; // set from something else
is there a way to split somedata for my view in a ngRepeat expression? Something ...
0
votes
0answers
36 views
Angularjs and bindonce - Is this a proper way of using bindonce and how to check that it is working correctly?
So here is my question:
I have the following:
<li bindonce ng-repeat="value in Types" ng-include="'views/repeaters/types.html'"></li>
and I was wondering if this is the correct way to ...
0
votes
1answer
48 views
ngClick not firing in nested ngRepeat filled with data from $http.post()
I have an AngularJS app to search for journeys. In the part of the problem I am trying to show all available countries per region. The idea is that when you click a country, a function has to be ...
0
votes
1answer
36 views
is there a way to detect when the repeated items have finished loading in angular 1.0.8 stable?
Between the ng-repeat div tags,
I've div.cover_container.fetched elements that display data fetched using $http.get
I want to attach event handlers on these elements, but I cannot do so because ...
0
votes
3answers
48 views
Preserve line breaks in angularjs
I have seen this SO question.
My code instead of ng-bind="item.desc" uses {{item.desc}} because I have a ng-repeat before.
So my code:
<div ng-repeat="item in items">
{{item.description}}
...
1
vote
3answers
47 views
Angular ng-repeat not loading
I have had this working in the past, I have moved the site about on localhost and now I can't seem to get ng-repeat to display results. Any ideas?
App:
var app = angular.module('Search', ...
0
votes
0answers
66 views
angularjs select list dynamic id
I have a select list bound to a property, the list items are created via a function on the $root scope and accessed in the ng-options attribute. For some reason I am unable to set the select list ID ...
0
votes
0answers
56 views
AngularJS: binding ng-model to input[type=file] raises 'no longer usable' exception
Using this code:
<!doctype html>
<html lang="en" ng-app="app">
<head>
<meta charset="UTF-8">
<title>ngTest</title>
<script ...
0
votes
0answers
51 views
AngularJS NanoScroller after ng-repeat doesn't show
I've been trough many posts on stackoverflow but I didn't manage to find the answer yet. I have a jQuery scrollbar plugin (nanoscroll), and I want it to update after a ng-repeat.
As many posts here ...
0
votes
2answers
48 views
How to fetch data from Angular JS forms
I have created a plunker here: http://plnkr.co/qbWBFo that shows a form that I am auto filling based on some json (keys). When the user hits submit, I need to access all data that was filled in and ...
1
vote
1answer
47 views
ng-show / hide with 'track by $index' not hiding by index
I am getting, what I believe to be, an odd behaviour when adding arrays to an object in an ng-repeat.
Due to the "Duplicates in a repeater are not allowed" error I am using track by $index but when ...
0
votes
0answers
37 views
Paginated slides in Angular
I have an array of items which I want to filter on different kinds of filters. Because I have more than 2000 items I want to paginate between pages so I've created a startFrom directive and used ...
0
votes
3answers
60 views
Angular JS Date filter not working
I have an ng-repeat element which will loop through $http.get() result.
<tr ng-repeat="blog in posts">
<td style="text-align:center">{{ $index+1 }}</td>
<td>{{ ...
0
votes
0answers
58 views
ngIf inside a ng-repeat gives error
This is a simplified idea of my code. $scope.events is an multi-dimentional array and my HTML is:
<div ng-repeat="event in events" >
{{event.owner_id.$oid}} //renders the $oid
<div ...
0
votes
2answers
46 views
$first in ngRepeat
I have an array $scope.items.
I want if the item is the $first one of the ngRepeat to add the css class in.
Is it something that can be done with angular? Generally how can I handle the booleans in ...
0
votes
2answers
45 views
Make an option selected in select field during form edit in angularjs
I have a form with data which is to edit by user. I am getting form data using $http service of angularJS. I have done all, but I cannot make a select field's option selected (I am new in angularJS). ...
0
votes
0answers
37 views
what are $$hashkey objects in Angularjs? How can I read multiple file inputs?
I am trying to get multiple file attachments from file inputs using the following directive:
var app = angular.module('app',['ui.bootstrap']).config(function($interpolateProvider){
...