Saturday, 15 September 2012

jquery - cells function on handsontable -


This is my first question, I decided to write because I'm getting mad with it.

I am working on the jQuery handset and am trying to set the color of the specific column. The problem with this is that this column does not have the same index, because the data is loaded from the database. Well, I suppose that when I start the Handscentable, I can do it with a cell function

  cell: function (line, cola, prop) {var CellProperties = {}; If (Prop === "Matsyueview") {cellProperties.renderer = totalresenderer; // uses straightforward function} Return cell receptors; }  

The question is. If I have a column defined with the data: can "matsvalue" refer to it with prop parameter?

The renderer is working on this if I do this,

  cells: function (row, col, prop) {var cellProperties = {}; If (line === 5) {cellProperties.renderer = totalresenderer; // uses straightforward function} Return cell receptors; }  

Row number 5 takes the renderer

I get the database by pushing the column into a JS object and pushing it into handy columns.

  var col2 = new object (); Col2.data = "matsvalue"; Col2.title = "matte value"; Col2.width = "200"; Col2.readOnly = "true"; Col2.renderer = Presenter to Total;  

This takes the data and title, but the width is read-only and the renderer option is not working.

Look at the documentation because you have almost it, instead of cells, you have columns Should be used because you want to add color to the whole column, in that case, you can give each column a renderer so that you can check on the creation of this column object only once.

I think what you should do is note that on the green renderer where "top level" heading "matsvalue" appears, so if it is provided in some other place, then it Always sets the green renderer in the column with the title "matsvalue".


No comments:

Post a Comment