Chapter 3. Base Finance Module

3.1. Requirements

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

3.1.6. Business Object Definition

					
# base_acct.gcd - base accounting transaction definitions.
#                  
# 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:27 $ $Author: psu_gnue $
#

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

module base_acct
{
  # -------------------------------------------------------------------------
  # transaction definition for transactions that can be generated from
  # the various subsystems.
  # -------------------------------------------------------------------------
  class trans_def
  {
    char    name<25>      not null;  # long name
    char    abbrv<8>      not null;  # abbreviation used in place of code
                                     # for lookup by the subsystems.
    int16   code          not null;  # code using in transaction file to save
                                     # space
    char    account<15>   not null;  # General Ledger account number
    char    debit_credit  not null;  # C = credit, D = debit
    boolean active = true not null;  # is this transaction code usable
  };
  
  # -------------------------------------------------------------------------
  # standard transaction data for all subsystems.
  # -------------------------------------------------------------------------
  type trans
  {
    int             code;         # the transaction code from base_acct::trans
    date            date;         # the transaction date
    char            account<10>;  # the general ledger account number
    boolean         exported;     # has this transaction been exported from sub-system
    currency::money amount;       # value of this transaction
    char            debit_credit; # is this a debit or credit transaction
    char            who<15>;      # login name creating this transaction
    char            extra1<15>;   # defined by the subsystem
    char            extra2<15>;   # defined by the subsystem
  };
};