<% import grails.persistence.Event %> <% excludedProps = Event.allEvents.toList() << 'id' << 'version' allowedNames = domainClass.persistentProperties*.name << 'dateCreated' << 'lastUpdated' props = domainClass.properties.findAll { allowedNames.contains(it.name) && !excludedProps.contains(it.name) && it.type != null && !Collection.isAssignableFrom(it.type) } Collections.sort(props, comparator.constructors[0].newInstance([domainClass] as Object[])) props.eachWithIndex { p, i -> if (i < 6) { if (p.isAssociation()) { %> <% } else { %> <% } } } %> <% props.eachWithIndex { p, i -> %> <% } %>
${p.naturalName}${p.naturalName}
{{item.${p.name}}}