I guess I'm missing something. I can't get the inline edit to work, much less the inline add. is there a working example of inline edit and add? Here is one of my grid examples, building number should be editable.
def buildingGrid = {
domainClass Building
inlineEdit true
edit true
globalFilterClosure { params ->
eq('project.id', session.project.id?:1 )
}
columns {
id {
type 'id'
enableFilter false
jqgrid {
hidden = true
}
}
buildingNumber
nrFloors {
enableFilter false
value { Building building ->
building.floors.size()
}
}
}
}
grid:grid name="building" addFunction="addBuilding">
grid:set caption="Buildings" width="700"/>
grid:set inlineNav="${[addParams:[position:'last'],editParams:'f:editOptions']}"/>
/grid:grid>
class Building {
Integer buildingNumber
static belongsTo = [project:Project]
static hasMany = [floors:Floor]
static constraints = {
buildingNumber(nullable:false)
}
static mapping = {
floors sort: 'floorNumber', order: 'asc'
}
def numberOfFloors() {
return floors?.size()?:0
}
}
I guess I'm missing something. I can't get the inline edit to work, much less the inline add. is there a working example of inline edit and add? Here is one of my grid examples, building number should be editable.
grid:grid name="building" addFunction="addBuilding">
grid:set caption="Buildings" width="700"/>
grid:set inlineNav="${[addParams:[position:'last'],editParams:'f:editOptions']}"/>
/grid:grid>
class Building {
Integer buildingNumber
}