dolibarr 19.0.4
mod_lot_free.php
Go to the documentation of this file.
1<?php
2/* Copyright (C) 2004 Rodolphe Quiedeville <rodolphe@quiedeville.org>
3 * Copyright (C) 2006-2009 Laurent Destailleur <eldy@users.sourceforge.net>
4 * Copyright (C) 2022-2023 Frédéric France <frederic.france@netlogic.fr>
5 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 3 of the License, or
9 * (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program. If not, see <https://www.gnu.org/licenses/>.
18 * or see https://www.gnu.org/
19 */
20
27require_once DOL_DOCUMENT_ROOT.'/core/modules/product_batch/modules_product_batch.class.php';
28
34{
35 /*
36 * Please note this module is used by default if no module has been defined in the configuration
37 *
38 * Its operation must therefore remain as open as possible
39 */
40
41
45 public $name = 'lot_free';
46
50 public $code_modifiable;
51
52 public $code_modifiable_invalide; // Code modifiable si il est invalide
53
54 public $code_modifiable_null; // Code modifiables si il est null
55
56 public $code_null; // Code facultatif
57
62 public $version = 'dolibarr'; // 'development', 'experimental', 'dolibarr'
63
67 public $code_auto;
68
69
73 public function __construct()
74 {
75 $this->code_null = 1;
76 $this->code_modifiable = 1;
77 $this->code_modifiable_invalide = 1;
78 $this->code_modifiable_null = 1;
79 $this->code_auto = 0;
80 }
81
82
89 public function info($langs)
90 {
91 global $langs;
92 $langs->load("companies");
93 return $langs->trans("LeopardNumRefModelDesc");
94 }
95
101 public function getExample()
102 {
103 return $this->getNextValue(null, null);
104 }
105
113 public function getNextValue($objsoc, $object)
114 {
115 return '';
116 }
117}
Parent class to manage numbering of batch products.
Class allowing lot_free management of batch numbers.
__construct()
Constructor.
getExample()
Return an example of numbering.
info($langs)
Return description of module.
getNextValue($objsoc, $object)
Return an example of result returned by getNextValue.