I want to generate all rows , all cells with unique ids of gridview
Thank you for contacting Syncfusion support.
Query: I want to generate all rows , all cells with unique ids
If you want to generate the cells (td) with unique ids, use the customAttributes in the Grid columns. By using this property you can modify the styles and appearance of a particular column.
Please refer to the sample and help document in the following link:
Sample: sample120271
Document: http://help.syncfusion.com/js/grid/columns#custom-attribute
http://help.syncfusion.com/js/api/ejgrid#members:columns-customattributes
|
angular.module('listCtrl', ['ejangular']) .controller("PhoneListCtrl", function ($scope) { $scope.columns = [ { field: "EmployeeID", headerText: 'Employee ID', textAlign: ej.TextAlign.Right, width: 75 }, { field: "FirstName", headerText: 'First Name', textAlign: ej.TextAlign.Left, width: 100 }, { field: "City", headerText: 'City', textAlign: ej.TextAlign.Left, width: 100,customAttributes: { "id": "{{:EmployeeID}}" } }, // jsrender syntax usage in custom Attribute
. . . . ] $scope.groupedcol = ["EmployeeID"];
$scope.onLoadClick = function () { var data = window.employeeView; var targetsGrid = $("#targetsGrid").data("ejGrid"); $scope.data = data; } |
Before proceeding further, could you please share the following details?
Regards,
Balaji Marimuthu
- 1 Reply
- 2 Participants
-
RA Rakesh Advani
- Sep 16, 2015 09:32 AM UTC
- Sep 17, 2015 11:14 AM UTC