Search Posts

Category: table

How to add a manual cell in each table row after an ng-repeat?

I’m building a table that is populated by ng-repeat going through a list that comes from the database. This part works fine, but I want to have a checkbox that lets the user select which rows are deleted. I’d also like to have a checkbox on the table header that works as a select all button. The problem is that, as I understand it, the ng-repeat loop includes everything inside the row in question leaving […]

angularJS Filter on dynamic attribute

I face a difficulty trying to filter on column of a a dynamic table and put the problem here if someone have already face the same problem and find a solution. Context : In an angularJS Application (1.5.8) I have custom generic table used in all my application.Each table have a specific parameter injected which create columns. Today I would like to add to this custom table a generic filter function on each column to […]

Show nested data from json in table angular

Hi I am trying to show nested data from JSON in a table but not getting succeeded. My json data:- $scope.data = [ { “$id”: “1”, “Folder”: [ { “Name”: “Windows-Desktop”, “CPU”: “2”, “RAM”: 2, “FolderName”: “Folder-28” }, { “Name”: “Desktop”, “CPU”: “1”, “RAM”: 1, “FolderName”: “Folder-11″ } ] } ] I tried this in controller:- $scope.Folder = []; angular.forEach($scope.data.Folder, function(choose) { $scope.Folder.push(choose); } In view i did this <tbody> <tr role=”row” class=”odd”> <td class=”sorting_1″ […]

Show json array list in table row angular

I am trying to show json array data in table row. But I am doing it wrong through ng-repeat. I have a text input field with read only feature inside the table row. I have to show inside the text input field. JSON data : $scope.list=[ { “ID”: “1”, “Source”: [ “AA”, “AVV”, “WEB”, “DEB” ] } ] My View:- <tbody> <tr role=”row” class=””> <td class=”sorting_1″ ng-repeat=”row in list.Source”> <input readonly=”readonly” id=”reg_input” class=”form-control” type=”text”/> </td> […]

how to use the loop with $index

when i use the code above in html i cant get the result that i want because i have problem in because i want to show data of all.Options0 and 1 by looping all.Options0 = { data: all.myData, }; all.Options1 = { data: all.myDataTwo, }; <div ng-repeat=”n in [].constructor(2) track by $index”> {{$index}} <br> <my-grid options=”{{‘all.Options’+$index}}” class=”grid”></my-grid> <br> <br> <br> <br> </div> Source: AngularJS

AngularJS moveuprow of table and post changes to DB

Hello everyone I have kept awake for a week learning angularjs and reached a point where I managed to reach the next code which makes each row of a table generated by a ng-repeat have two buttons one to raise the row and another to lower it Every time you do an edit the position of the row you should see the change in the page and save the changes in the database (please know […]

Filter table after click data AngularJS

I need to filter table – after click name in the list: <ul ng-repeat=”f in filter”> <li ng-model=”search.name”> <a class=”left-menu-link”> {{f}} </a> </li> </ul> The table should list only that name which I chose. My plunker: http://plnkr.co/edit/g1t4pludTTIAJYKTToCK?p=preview // Code goes here var app = angular.module(‘app’, []); app.controller(‘FirstCtrl’, function($scope) { $scope.data = [{ “name”: “afdfg Nixon”, “system”: “System Architect” }, { “name”: “sdfasdfas”, “system”: “System Architect” }, { “name”: “ggg Nigadfgxon”, “system”: “System Architect” }, { […]