dolibarr 21.0.0-alpha
|
Class to manage ref numbering of takepos cards with rule Simple. More...
Public Member Functions | |
info ($langs) | |
Return description of numbering module. | |
getExample () | |
Return an example of numbering module values. | |
canBeActivated ($object) | |
Test if the numbers already in the database do not cause any conflicts that will prevent this of conflicts that will prevent this numbering from working. | |
getNextValue ($objsoc=null, $invoice=null, $mode='next') | |
Return next value. | |
getNumRef ($objsoc, $objforref) | |
Return next free value. | |
Public Member Functions inherited from CommonNumRefGenerator | |
getNom ($langs) | |
Return model name. | |
getName ($langs) | |
Return model name. | |
isEnabled () | |
Return if a module can be used or not. | |
getVersion () | |
Returns version of numbering module. | |
Class to manage ref numbering of takepos cards with rule Simple.
Definition at line 35 of file mod_takepos_ref_simple.php.
mod_takepos_ref_simple::canBeActivated | ( | $object | ) |
Test if the numbers already in the database do not cause any conflicts that will prevent this of conflicts that will prevent this numbering from working.
CommonObject | $object | Object we need next value for |
Reimplemented from CommonNumRefGenerator.
Definition at line 93 of file mod_takepos_ref_simple.php.
mod_takepos_ref_simple::getExample | ( | ) |
Return an example of numbering module values.
Reimplemented from ModeleNumRefTakepos.
Definition at line 81 of file mod_takepos_ref_simple.php.
mod_takepos_ref_simple::getNextValue | ( | $objsoc = null, | |
$invoice = null, | |||
$mode = 'next' ) |
Return next value.
Note to increase perf of this numbering engine: ALTER TABLE llx_facture ADD COLUMN calculated_numrefonly INTEGER AS (CASE SUBSTRING(ref FROM 1 FOR 2) WHEN 'TC' THEN CAST(SUBSTRING(ref FROM 10) AS SIGNED) ELSE 0 END) PERSISTENT; ALTER TABLE llx_facture ADD INDEX calculated_numrefonly_idx (calculated_numrefonly);
?Societe | $objsoc | Object third party |
?Facture | $invoice | Object invoice |
string | $mode | 'next' for next value or 'last' for last value |
Reimplemented from ModeleNumRefTakepos.
Definition at line 139 of file mod_takepos_ref_simple.php.
References dol_print_date(), dol_print_error(), and dol_syslog().
Referenced by getNumRef().
mod_takepos_ref_simple::getNumRef | ( | $objsoc, | |
$objforref ) |
Return next free value.
Definition at line 217 of file mod_takepos_ref_simple.php.
References getNextValue().
mod_takepos_ref_simple::info | ( | $langs | ) |
Return description of numbering module.
Translate | $langs | Lang object to use for output |
Reimplemented from CommonNumRefGenerator.
Definition at line 66 of file mod_takepos_ref_simple.php.