Skip to main content

Posts

Showing posts with the label jquery

jqgrid grails : editing rows with drop-downs/combo boxes

Jqgrid is a jquery plugin that allows formatting data as table and has number of options - paging, sorting, filtering, inline editing etc. There are few good tutorials explaining the process to integrated jqgrid in your grails application. http://pramodnepal.com.np/?p=119 http://www.grails.org/plugin/jqgrid Following is a typical jquery script that can be used in a grails application. The property 'editable=true' make any of the field in grid as editable.

Partial form submit with Grails and JQuery

At times you would want process a part of the form and refresh the page with the results obtained from the partial form submission. Given below is a screen shot of the typical use case. It is a form used in a sales application. Take a look at the section "Particulars" in the screen. The fields - Item, Unit Price, Quantity, Discount%, Tax% are editable and fields - Total Discount, Total Tax and Grand Total are calculated as the result of clicking "Calculate" link in this section. There is on option to add multiple rows to this table by selecting "Add" in the first cell of this table. The section of the code used for the table "Particulars" is given below.