Last change
on this file since 176 was
175,
checked in by gav, 15 years ago
|
Substantial refactor of the Inventory domain.
InventoryItems can now be added to tasks, no quantity adjustments done yet.
Removed StoredItem and with it the ability to store an inventoryItem in multiple places, just too complex right now.
Svn move StoreLocation to InventoryLocation.
|
File size:
1.4 KB
|
Line | |
---|
1 | class InventoryItem { |
---|
2 | InventoryGroup inventoryGroup |
---|
3 | InventoryType inventoryType |
---|
4 | UnitOfMeasure unitOfMeasure |
---|
5 | InventoryLocation inventoryLocation |
---|
6 | Period averageDeliveryPeriod |
---|
7 | String name |
---|
8 | String description = "" |
---|
9 | String manufacturersPartNumber |
---|
10 | String suppliersPartNumber |
---|
11 | Integer unitsInStock = 0 |
---|
12 | Integer reorderPoint |
---|
13 | Integer recommendedReorderPoint |
---|
14 | Integer averageDeliveryTime |
---|
15 | boolean isActive = true |
---|
16 | boolean isObsolete = false |
---|
17 | boolean enableReorder = true |
---|
18 | |
---|
19 | static hasMany = [alternateItems: InventoryItem, |
---|
20 | spareFor: Asset, |
---|
21 | inventoryMovements: InventoryMovement, |
---|
22 | manufacturers: Manufacturer, |
---|
23 | suppliers: Supplier] |
---|
24 | |
---|
25 | // static belongsTo = [] |
---|
26 | |
---|
27 | static constraints = { |
---|
28 | name(unique:true, blank:false, maxSize:50) |
---|
29 | description() |
---|
30 | unitsInStock(min:0) |
---|
31 | unitOfMeasure() |
---|
32 | reorderPoint() |
---|
33 | enableReorder() |
---|
34 | recommendedReorderPoint(nullable:true) |
---|
35 | isActive() |
---|
36 | isObsolete() |
---|
37 | inventoryGroup() |
---|
38 | inventoryType() |
---|
39 | manufacturersPartNumber(blank:true, nullable:true) |
---|
40 | suppliersPartNumber(blank:true, nullable:true) |
---|
41 | averageDeliveryTime(nullable:true) |
---|
42 | averageDeliveryPeriod(nullable:true) |
---|
43 | } |
---|
44 | |
---|
45 | String toString() {"${this.name}"} |
---|
46 | } |
---|
47 | |
---|
Note: See
TracBrowser
for help on using the repository browser.