source: trunk/grails-app/domain/AssetSubItem.groovy @ 771

Last change on this file since 771 was 456, checked in by gav, 15 years ago

Set batchSize:1000 on asset tree domain classes.

File size: 772 bytes
RevLine 
[268]1class AssetSubItem {
[121]2
[268]3    AssetSubItem parentItem
4
[118]5    String name
6    String description = ""
[330]7    String comment = ""
[118]8    boolean isActive = true
9
[276]10    static hasMany = [assets: Asset,
11                                subItems: AssetSubItem,
[268]12                                maintenanceActions: MaintenanceAction,
13                                assetSubItemExtendedAttributes: AssetSubItemExtendedAttribute]
[121]14
[268]15    static belongsTo = [Asset, AssetSubItem]
[121]16
[268]17    static constraints = {
[341]18        name(maxSize:50, unique:true, blank:false)
[330]19        description(maxSize:75)
20        comment(maxSize:500)
[268]21        isActive()
22        parentItem(nullable:true)
23    }
[118]24
[456]25    static mapping = {
26        subItems(batchSize:1000)
27    }
28
[118]29    String toString() {
30        "${this.name}"
31    }
32}
33
Note: See TracBrowser for help on using the repository browser.