Hello,
As for now use this link
It is not up to date. All the new functions and features are described in the whant is new when you download the licensed version.
Kind Regards,
Will
Guriddo Support Team
Hello,
Using a console to set something is not a prefered way.
The method work for us – this is tested.
Setting the column to width 20 will not work. The min column width is definedĀ in minColWidth and default to 33.
Your example will work if you define two buttons and within document ready do:
|
1 2 3 4 5 6 7 8 9 10 |
$(document).ready(function () { $("#jqGrid").jqGrid({...}); $("#increase").on('click', function() { $("#jqGrid").jqGrid('resizeColumn', 'ProductName', 200 ); }); $("#decrease").on('click', function() { $("#jqGrid").jqGrid('resizeColumn', 'ProductName', 80 ); }); ... |
Kind Regards,
Will
Guriddo Support Team
Hello,
You should execute the method associated with the grid and not to the container.
The expression :
|
1 2 3 |
... $('.demo-jqgrid-container').jqGrid('resizeColumn', 'categoryName', 60); ... |
is not correct.
The correct code is:
|
1 2 3 |
... $('#demo-jqgrid').jqGrid('resizeColumn', 'categoryName', 60); ... |
Please note the difference
Kind Regards
Will
Guriddo Support Team
Hello,
Unfortunately this is not possible at the moment, but we think this is a good feature to included in the code.
We will make the needed changes and let you know. We hope to be ready for Monday 19
Kind Regards,
Will
Guriddo Support Team
Hello,
You can use getGridParam method to get the colModel property.
Loop throught this array in which every object has a width Property to get the actual width and use the method resizeColumn with parameters column name(or index) and the new width.
|
1 2 3 4 5 6 7 |
var colModel = $("#grid").jqGrid('getGridParam', 'colModel'); for( var j = 0; j<colModel.length; j++ ) { if( colModel[j].hasOwnProperty( width ) ) { var width = parseInt(colModel[j].width,10); $("#grid").jqGrid('resizeColumn', colModel[j].name, width*0.8); } } |
Hope this helps
Regards,
Guriddo Support Team
Hello,
Not sure that I understand the question. You can use the GridWidth function to set the new width of the grid based on the new settings. The font-size just change the size of the font and not the width
Maybe you want to know how to change the font-size based on the width(this is done via google search)
Kind Regards,
Will
Guriddo Support Team
Hello,
Unfortunately this is not possible at the moment. Currently when you have the connection object you can writeĀ regular SQL query using the SelectCommand as show in the demo.
We will try to investigate, if we can make such kind of integration, but as you know this will take time.
Instead we will just look into the Zend concepts and willĀ let you know if this will be possible at all.
In the mean time you can just experiment with what we have suggested.
Kind Regards,
Will
Guriddo Support Team
Hello,
We do not have only PDO, but some other drivers like mysqli, sql server, ado db and etc.
Short – you can not use direct the Zend connection adapter, but….
Suppose the Zend connects using PDO, then if you can extract the connection from the addapter you can pass it. Example:
$dbAdapter = Zend_Registry::get(‘dbAdapter’);
If the connection is stored by example in : $dbAdapter->conn
then you can use this to connect to jqGrid using the standard code.
We are not familiar with Zend, but if you need any help you are welcome.
Kind Regards,
Will
Guriddo Support Team
Hello,
setSelect is not only for drop down, but also for presenting a a data in the grid.
In JavaScript PHP setSelect can be considered as formatter : ‘select’ too (see the options here ).
Just try it does not require a lot of work.
Guriddo Support Team
Hello,
If I understand the question right you can use setSelect for these columns.
See the example here . Look at the CustomerID field.
Kind Regards,
Will
Guriddo Support Team
Hello,
Until now without success. Below is the code, which maybe will give you a idea (it is not working)
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 |
&nbsp; var grid = $("#jqGrid").jqGrid({ url: 'data.json', datatype: "json", colModel: [ { label: 'Category Name', name: 'CategoryName', width: 100 }, { label: 'Product Name', name: 'ProductName', width: 110 }, { label: 'Country', name: 'Country', width: 200 }, { label: 'Price', name: 'Price', width: 180, sorttype: 'integer' }, // sorttype is used only if the data is loaded locally or loadonce is set to true { label: 'Quantity', name: 'Quantity', width: 180, sorttype: 'number' } ], loadonce: true, width: 600, height: 200, rowNum: 150, shrinkToFit : false, sortable: { options: { //scrollSensitivity : 5, forcePlaceholderSize : true, forceHelperSize: true, start : function( e, ui) { var sc = $(".ui-jqgrid-hdiv "); sc.css('overflow-x','auto'); }, stop : function( ev, ui) { var sc = $(".ui-jqgrid-hdiv ").scrollLeft(); //console.log(sc); grid[0].grid.bDiv.scrollLeft = sc; //console.log(grid[0].grid.bDiv.scrollLeft); $(".ui-jqgrid-hdiv ").css('overflow-x','hidden'); } } }, pager: "#jqGridPager" }); |
Kind Regards,
Will
Guriddo Support Team
Hello,
Sorry that I initially do not understand the problem in details.
Definitely this is a bug. Thank you.
We have fixed it in GitHub
You can grab the new build from GitHub and test.
Please let us know if the bug is fixed for you.
Kind Regards,
Will
Guriddo Support Team
Hello,
Sorry I missed this.
It important to say, that the data field expanded should be set to true.
In your case it is set to false. When we change this property to true it is working as expected in our environment.
If you have difficulties we can publish your demo online.
Kind Regards
Will
Guriddo Support Team
Perhaps you put a object as data instead of array.
if you do
|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 |
mydata = []; //array //and then mydata.push( { "LGICUS01OperationResponse": { "ca": { "ca_phone_mobile": "123", "ca_request_id": "01ICUS", "ca_return_code": 0, "ca_dob": "30.09.1965", "ca_last_name": "Tracey", "ca_num_policies": 0, "ca_phone_home": "", "ca_email_address": "REFROOM@TBHOLDINGS.COM", "ca_house_name": "Tracey Island", "ca_policy_data": "", "ca_customer_num": 3, "ca_first_name": "Scott1", "ca_house_num": "", "ca_postcode": "TB14TV" } } }); |
then you will have a array and not a object,
In all cases jqGrid does not tuch the source data it is just stored in the grid parameters.
Regards,
Will
Guriddo Support Team
Hello,
|
1 2 3 4 5 |
for( var k=0; k < postdata.length; k++) { var row = postdata[k]; console.log( row.LGICUS01OperationResponse.ca.ca_house_name ); } |
Regards
Will
Guriddo Support Team
Copyright 2014 TriRand LtdAll Rights ReservedRSS
Back to Top