CGDevTools Forum

Welcome to the Official CGDevTools Support Community Forums.

Grids: setSelect SQL-Statement

General discussion

by wieczy » 07 Jun 2012 13:48

Hello,

I'm testing the JQuery-Components. They are very nice and usefull. :-) Thank you!

I've two problems:

- How can the dropdow-list fill at runtime (i.e. with data from a SQL-statement)? The demo says the function "setSelect" is to be used. Where can I find more information about this?

- How can the grid reloaded? (like press the "Reload-Button"). If the datasource is a detail-table the grid ist not automatical reload if the master-table is changed.

Thank you

Frank
wieczy
 
Posts: 4
Joined: 07 Jun 2012 07:29

by Pedro » 07 Jun 2012 16:33

Hi Frank

While we are finishing our own documentation, you can take a look at plugins documentation. For the jqgrid is in

http://www.trirand.com/jqgridwiki/doku.php?id=wiki:jqgriddocs

We are going to release a version tomorrow, where right clicking a CGJQControl at design-time will send you to the respective plugn documentation.

About you questions:

"- How can the dropdow-list fill at runtime (i.e. with data from a SQL-statement)? The demo says the function "setSelect" is to be used. Where can I find more information about this?"

We're checking this, but I believe that the name of the function should be "OnBuildSelect", and that is an error in demo documentation. OnBuildSelect can be found in IWCGJQGrid.Columns[i].EditOptions.OnBuildSelect

However, If you're going to use a SQL Select to fill a select, we advise to use AutoComplete integration, because using select, all its HTML values are going to be rendered, and this is not a good practise. With these components, with intend to have only not only a nice browser presentation controls, but also and above all a light weight rendering,

"- How can the grid reloaded? (like press the "Reload-Button")"
use the method IWCGJQGrid.JQGridOptions,AjaxReloadGrid. For the next version, we changed the name of the method to ReloadGrid, to be able to execute the reaload either in Ajax (async) or Submit events.

Best Regards

cgdevtools
Pedro
 
Posts: 14
Joined: 24 May 2012 19:38

by Pedro » 08 Jun 2012 01:30

Hello Frank

I've further developments on this:

For next version, if Col.EditType = gcetSelect

You can either specify Col.EditOptions.Value, according to jqGrid plugin documentation, which is not advisiable.

Or define event Col.OnGetEditSelectData where the select values and text can be set.

The demo has been changed to show how to apply this method.

There is a similar procedure for Searching.

Best Regards

cgdevtools
Pedro
 
Posts: 14
Joined: 24 May 2012 19:38


Return to General - Archive

cron

Who is online

Users browsing this forum: No registered users and 3 guests

Contact Us.