dolibarr  13.0.2
Functions
accounting.lib.php File Reference

( ) More...

Go to the source code of this file.

Functions

 is_empty ($var, $allow_false=false, $allow_ws=false)
 Check if a value is empty with some options. More...
 
 accounting_prepare_head (AccountingAccount $object)
 Prepare array with list of tabs. More...
 
 clean_account ($account)
 Return accounting account without zero on the right. More...
 
 length_accountg ($account)
 Return General accounting account with defined length (used for product and miscellaneous) More...
 
 length_accounta ($accounta)
 Return Auxiliary accounting account of thirdparties with defined length. More...
 
 journalHead ($nom, $variante, $period, $periodlink, $description, $builddate, $exportlink= '', $moreparam=array(), $calcmode= '', $varlink= '')
 Show header of a page used to transfer/dispatch data in accounting. More...
 
 getDefaultDatesForTransfer ()
 Return Default dates for transfer based on periodicity option in accountancy setup. More...
 

Detailed Description

( )

Library of accountancy functions

Definition in file accounting.lib.php.

Function Documentation

accounting_prepare_head ( AccountingAccount  $object)

Prepare array with list of tabs.

Parameters
AccountingAccount$objectAccounting account
Returns
array Array of tabs to show

Definition at line 51 of file accounting.lib.php.

References complete_head_from_modules().

clean_account (   $account)

Return accounting account without zero on the right.

Parameters
string$accountAccounting account
Returns
string String without zero on the right

Definition at line 80 of file accounting.lib.php.

getDefaultDatesForTransfer ( )

Return Default dates for transfer based on periodicity option in accountancy setup.

Returns
array Dates of periodicity by default

Definition at line 252 of file accounting.lib.php.

References dol_get_last_day(), dol_mktime(), dol_now(), and dol_print_date().

is_empty (   $var,
  $allow_false = false,
  $allow_ws = false 
)

Check if a value is empty with some options.

Author
Michael - https://www.php.net/manual/fr/function.empty.php#90767
Parameters
mixed$varValue to test
int | null$allow_falseSetting this to true will make the function consider a boolean value of false as NOT empty. This parameter is false by default.
int | null$allow_wsSetting this to true will make the function consider a string with nothing but white space as NOT empty. This parameter is false by default.
Returns
boolean True of False

Definition at line 37 of file accounting.lib.php.

Referenced by journalHead(), length_accounta(), and length_accountg().

journalHead (   $nom,
  $variante,
  $period,
  $periodlink,
  $description,
  $builddate,
  $exportlink = '',
  $moreparam = array(),
  $calcmode = '',
  $varlink = '' 
)

Show header of a page used to transfer/dispatch data in accounting.

Parameters
string$nomName of report
string$varianteLink for alternate report
string$periodPeriod of report
string$periodlinkLink to switch period
string$descriptionDescription
integer$builddateDate of generation
string$exportlinkLink for export or ''
array$moreparamArray with list of params to add into form
string$calcmodeCalculation mode
string$varlinkAdd a variable into the address of the page
Returns
void

Definition at line 174 of file accounting.lib.php.

References $_SERVER, dol_get_fiche_end(), dol_get_fiche_head(), is_empty(), and print.

length_accounta (   $accounta)

Return Auxiliary accounting account of thirdparties with defined length.

Parameters
string$accountaAuxiliary accounting account
Returns
string String with defined length

Definition at line 128 of file accounting.lib.php.

References is_empty().

Referenced by AccountancyExport\exportAgiris(), AccountancyExport\exportBob50(), AccountancyExport\exportCegid(), AccountancyExport\exportCoala(), AccountancyExport\exportConfigurable(), AccountancyExport\exportLDCompta(), AccountancyExport\exportLDCompta10(), AccountancyExport\exportOpenConcerto(), and AccountancyExport\exportSAGE50SWISS().

length_accountg (   $account)