Changeset 892 for branches


Ignore:
Timestamp:
Apr 21, 2011, 5:57:17 PM (8 years ago)
Author:
gav
Message:

Formatting only, no domain change.

Location:
branches/features/purchaseOrders/grails-app/domain
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • branches/features/purchaseOrders/grails-app/domain/InventoryItem.groovy

    r726 r892  
    11class  InventoryItem {
     2
    23    InventoryGroup inventoryGroup
    34    InventoryType inventoryType
     
    67    Picture picture
    78    Supplier preferredSupplier
     9
    810    String name
    911    String description = ""
  • branches/features/purchaseOrders/grails-app/domain/InventoryItemPurchase.groovy

    r891 r892  
    11class InventoryItemPurchase {
    22
     3    PurchaseOrder purchaseOrder
    34    Person enteredBy
    45    Person lastUpdatedBy
     
    1415
    1516    Integer quantity
    16     PurchaseOrder purchaseOrder
    1717    BigDecimal orderValueAmount
    1818    Currency orderValueCurrency
     
    2929    static constraints = {
    3030        quantity(min:0)
     31        /// @todo: check constraints.
    3132//        purchaseOrderNumber(blank:false, maxSize:50, validator: {val, obj ->
    3233//            // For orders the purchaseOrderNumber must be unique for an inventoryItem.
  • branches/features/purchaseOrders/grails-app/domain/PurchaseOrder.groovy

    r891 r892  
     1class PurchaseOrder {
    12
    2 class PurchaseOrder {
     3    Supplier supplier
     4
    35    String comments
    4     Supplier supplier
    56    Date ordered
     7
    68    static hasMany = [inventoryItemPurchases: InventoryItemPurchase]
    79
    810    static belongsTo = [purchaseOrderNumber: PurchaseOrderNumber]
    9 
    1011
    1112    static constraints = {
  • branches/features/purchaseOrders/grails-app/domain/PurchaseOrderNumber.groovy

    r891 r892  
     1class PurchaseOrderNumber {
    12
    2 /**
    3  * Created by IntelliJ IDEA.
    4  * User: John
    5  * Date: 18/04/2011
    6  * Time: 3:01:53 PM
    7  * To change this template use File | Settings | File Templates.
    8  */
    9 class PurchaseOrderNumber {
     3    PurchaseOrder purchaseOrder
     4
    105    String value
    11     PurchaseOrder purchaseOrder
    126
    137    static transients = ['description']
     
    1812
    1913    String getDescription() {
    20         if (!purchaseOrder) {
    21         return value + " - new"
    22         } else {
     14        if (!purchaseOrder)
     15            return "${value} - new"
     16        else
    2317            return "${value} for ${purchaseOrder.supplier}"
    24         }
    2518    }
    2619}
Note: See TracChangeset for help on using the changeset viewer.