FAQ Database Discussion Community

Passing data to newly created directive in angularjs when ajax call is over

I am trying to create custom directive out of slick grid. This is what I have done so far. angular.module('app') .directive('myGrid',function () { return { restrict: 'E', link: function (scope, el, attrs) { var data = []; var columns = [ {id: "title", name: "Title", field: "title", width: 160, cssClass:...

How to make setItems working properly in SlickGrid?

I have this simple code: var columnsTest = [ {id: "testId", name: "ID", field: "id", width: 50}, {id: "field1", name: "field1", field: "field1", width: 200}, {id: "field2", name: "field2", field: "field2", width: 200} ] function saveTest() { var itemFields = []; itemFields = dataViewTest.getItemById( dataViewTest.getItem(gridTest.getSelectedRows()).id ); itemFields['field1'] = $('#field1').val(); itemFields['field2']...

slickgrid text selection not working in cells

I've researched this question a bit. 3-4 months ago, the fix to use "enableTextSelectionOnCells" worked, but has broken again. I'm using v2.1 and implemented the following solutions: Text selection in slickgrid Slickgrid cell text selection does not work properly in Chrome or Firefox however, the issue persists. What happens is,...

Assigning CSS Style to SlickGrid Row

I have a slickgrid that displays a limited amount of data to the user. If there is data in a hidden column, I want the row to be bolded. I am not using a dataview, thus the getItemMetadata function is not available. I've tried this from another SO post: var...

SlickGrid custom CSS issue

I am using the latest version of slickgrid and am encountering an issue when implementing the latest jquery and jquery ui along with the custom ui css. I have tried using the jquery ui css with worse results. First image is with custom CSS and the second is with jquery...

Slickgrid onClick… How to update dataView without global dataView?

Short version: Is it possible to access the dataView within the scope of this subscription method? grid.onClick.subscribe(function(e, args) { var rowData= args.grid.getDataItem(args.row); //want to update data in dataView for this row }); (Elsewhere in my module i have) dataView.onRowsChanged.subscribe(function(e, args){ grid.invalidateRows(args.rows); grid.render(); }); Long Version: I've created a generic JavaScript...

Add a class to “selected” column headers in SlickGrid

When a cell is selected in SlickGrid, how can I apply a class to it's column header? If you look at Excel or Google docs, both apply an effect to the header cell to give a visual indication of which cell is selected. I want to add this effect to...

Drag and drop from one slickgrid to another on same page

I am new to SlickGrid, but loving how it looks and feels. I have two SlickGrids on a page, both are being fed by JSON from a back end MVC controller. This is working fine (though I have a slight formatting issue, but I'm sure I will figure that bit...

Slickgrid - Resizing columns triggers onHeaderClick event

I have subscribed to the onHeaderClickEvent and it works fine. My problem is that when a column gets re-sized, the onHeaderClickEvent also gets triggered which causes my header click handler to run. Is there a way to prevent, or disable, the header click event when columns are re-sized? Thanks.

Slickgrid inside jquery accordion columns not displaying properly

I am using slickgrid inside a jquery accordion and whenever the page refreshes and the accordion is expanded the columns inside the grid are all out of order and destroyed. I tried using grid.resizeCanvas(); inside my accordion to no avail. Here is my code. var grid = (grid1, grid2,...