Difference between revisions of "CG Grid's height"

From Catglobe Wiki
Jump to: navigation, search
(New page: These days i have fixed some bugs related to LnF in FF. Most of them came from the CGGrid which overlapped other below content. For example, in Data Import wizard or Access Dialog. When i ...)
 
 
(3 intermediate revisions by 2 users not shown)
Line 1: Line 1:
These days i have fixed some bugs related to LnF in FF. Most of them came from the CGGrid which overlapped other below content. For example, in Data Import wizard or Access Dialog. When i looked at the code, it had code to set the grid's height as we normally does in catglobe.<br>  
+
<accesscontrol>Main:MyGroup</accesscontrol>
 +
Hi,
  
But why did not it work? In reality, sometime it did, sometime not. What did we do was, i mentioned here was a jQuery structure:<br>
+
To simplify this, I have attached new funtion to grid object. Therefore, from now on, you can reset grid height as
  
$("#" + grid.Id + "_mr").height(h);<br> $("#" + grid.Id + "_mc").height(h);<br>
+
grid.resizeHeight( value&nbsp;);
  
What it did was to set height for the row and cell containing the main content of grid. HOWEVER, the outer parts of them are tbody and table, they were still 100% height.&nbsp; That is the point.<br>
+
------------------------------------------
  
How to fix it? Simple, make sure you also set height for tbody and table as well.<br>  
+
These days i have fixed some bugs related to LnF in FF. Most of them came from the CGGrid which overlapped other below content. For example, in Data Import wizard or Access Dialog. When i looked at the code, it had code to set the grid's height as we normally does in catglobe.<br>
  
Code snippest:<br>  
+
But why did not it work? In reality, sometime it did, sometime not. What did we do was, i mentioned here was a [[JQuery]] structure:<br>
 +
 
 +
$("#" + grid.Id + "_mr").height(h);<br>$("#" + grid.Id + "_mc").height(h);<br>
 +
 
 +
What it did was to set height for the row and cell containing the main content of grid. HOWEVER, the outer parts of them are tbody and table, they were still 100% height.&nbsp; That is the point.<br>
 +
 
 +
How to fix it? Simple, make sure you also set height for tbody and table as well.<br>
 +
 
 +
Code snippest:<br>
  
 
$("#" + grid.Id + "_mtb").height(h);<br>$("#" + grid.Id + "_main").height(h);<br>
 
$("#" + grid.Id + "_mtb").height(h);<br>$("#" + grid.Id + "_main").height(h);<br>
 +
 +
[[Category:Technical_guidelines]]

Latest revision as of 05:39, 18 October 2013

<accesscontrol>Main:MyGroup</accesscontrol> Hi,

To simplify this, I have attached new funtion to grid object. Therefore, from now on, you can reset grid height as

grid.resizeHeight( value );


These days i have fixed some bugs related to LnF in FF. Most of them came from the CGGrid which overlapped other below content. For example, in Data Import wizard or Access Dialog. When i looked at the code, it had code to set the grid's height as we normally does in catglobe.

But why did not it work? In reality, sometime it did, sometime not. What did we do was, i mentioned here was a JQuery structure:

$("#" + grid.Id + "_mr").height(h);
$("#" + grid.Id + "_mc").height(h);

What it did was to set height for the row and cell containing the main content of grid. HOWEVER, the outer parts of them are tbody and table, they were still 100% height.  That is the point.

How to fix it? Simple, make sure you also set height for tbody and table as well.

Code snippest:

$("#" + grid.Id + "_mtb").height(h);
$("#" + grid.Id + "_main").height(h);