- $this->initVar('id',XOBJ_DTYPE_INT,0,TRUE); //account id
- $this->initVar('ac_prnt_id',XOBJ_DTYPE_INT,0,TRUE); //account parent id
- $this->initVar('org_id',XOBJ_DTYPE_INT,0,TRUE); //organisation to which account belongs
- $this->initVar('ac_tp',XOBJ_DTYPE_TXTBOX,null,TRUE,6); //account type
- $this->initVar('ac_nm',XOBJ_DTYPE_TXTBOX,null,TRUE,20); //account name
- $this->initVar('ac_prps',XOBJ_DTYPE_TXTAREA,null,FALSE,255); //account purpose
- $this->initVar('ac_note',XOBJ_DTYPE_TXTAREA,null,FALSE,255); //account notes
- $this->initVar('ac_curr',XOBJ_DTYPE_TXTBOX,null,TRUE,3); //currency of account
- $this->initVar('ac_dr',XOBJ_DTYPE_INT,0,FALSE); //debit balance
- $this->initVar('ac_cr',XOBJ_DTYPE_INT,0,FALSE); //credit balance
- $this->initVar('ac_level',XOBJ_DTYPE_INT,0,FALSE);//display level
- $this->initVar('has_kids',XOBJ_DTYPE_INT,0,FALSE);//this account has child accounts
- $this->initVar('disp_order',XOBJ_DTYPE_INT,0,FALSE);//display order
- /* following are not held on database but computed by the object */
- $this->initVar('ac_net_bal',XOBJ_DTYPE_INT,0,FALSE); //account balance
- $this->initVar('ac_cr_altnm',XOBJ_DTYPE_OTHER,_MD_SACC_CR,FALSE); //alt name for CR value
- $this->initVar('ac_dr_altnm',XOBJ_DTYPE_OTHER,_MD_SACC_DR,FALSE); //alt name for DR value
- $entry = array();
- $this->initVar('entries',XOBJ_DTYPE_OTHER,$entry,FALSE); //account entries