Chapter 7. Vendor Module

7.1. Requirements

This chapter is $Revision: 1.1 $ $Date: 2003/01/05 00:00:30 $.

7.1.8. Business Object Definition

					
# vendor.gcd
#                   
# Copyright (C) 2001 Free Software Foundation, Inc.
#
# This file is part of GNU Enterprise.
#
# GNU Enterprise is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2, or (at your option)
# any later version.
# 
# GNU Enterprise is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
# General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with GNU Enterprise; see the file COPYING.  If not, write to the
# Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
# 02111-1307 USA.
#
# This file originally written by Neil Tiffin (neilt@gnue.org).
#
# $Revision: 1.1 $ $Date: 2003/01/05 00:00:30 $ $Author: psu_gnue $
#

include "../../../base/org/classes/org.gcd"
include "../../../base/currency/classes/currency.gcd"

module vendor
{
  # -------------------------------------------------------------------------
  # vendor status i.e. approved, dont use, special purchase only
  # -------------------------------------------------------------------------
  class status
  {
    char         code<8>;
    char         description<25>;
    
    INDEX (code);
  };
    
    
  # -------------------------------------------------------------------------
  # type of vendor.  service, raw material, labor.
  # -------------------------------------------------------------------------
  class v_type
  {
    char       code<8>;            # vendor type
    char       description<25>;
        
    INDEX (code);
  };
    
    
  # -------------------------------------------------------------------------
  # vendor specific information
  # -------------------------------------------------------------------------
  class vendor : org::organization
  {
    text            ven_notes;    # notes specific to vendors
    
    vendor::status *status;   # Approved, dont use etc.
    vendor::v_type   *v_type;     # Service, manufacturer, office supplies etc.
    
    char            std_terms; # TODO should be pointer
    
    currency::money year_0;  # this year to date
    currency::money year_1;  # last year
    currency::money year_2;  # year before
    
    date            last_receipt;
  };

};