Files
dolibarr/htdocs/core/modules/accountancy/modules_accountancy.php
Jyhere e35c59a4d8 GIFF-Accountancy-2025 - Automatic numbering of accounting entries (#33551)
* NEW: ref with configurable numbering models for Bookkeeping

* FIX: bookkeeping tooltip empty ref depending the list

* FIX: bookkeeping ref numbering missing translations and typo

* NEW: free ref num model for bookkeeping

* Update mod_bookkeeping_argon.php

* FIX: ci

* FIX: replace mistake, removed not necessary ternary

* FIX: phan error and prefix check

* FIX: phan error

* FIX: missing ref column in llx_accounting_bookkeeping_tmp.sql

* CHANGE: use default function getDolGlobalInt(,  = 0)
() param instead of ternary

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2025-03-31 11:35:18 +02:00

57 lines
2.1 KiB
PHP

<?php
/* Copyright (C) 2003-2004 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2004 Eric Seigne <eric.seigne@ryxeo.com>
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@inodbox.com>
* Copyright (C) 2006 Andre Cianfarani <acianfa@free.fr>
* Copyright (C) 2012 Juanjo Menent <jmenent@2byte.es>
* Copyright (C) 2014 Marcos García <marcosgdf@gmail.com>
* Copyright (C) 2024-2025 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2025 Jean-Rémi TAPONIER <jean-remi@netlogic.fr>
*
* This program 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 3 of the License, or
* (at your option) any later version.
*
* This program 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 this program. If not, see <https://www.gnu.org/licenses/>.
* or see https://www.gnu.org/
*/
/**
* \file htdocs/core/modules/accountancy/modules_accountancy.php
* \ingroup accountancy
* \brief File that contains parent class for orders models
* and parent class for accountancy numbering models
*/
require_once DOL_DOCUMENT_ROOT.'/core/class/commonnumrefgenerator.class.php';
/**
* Parent class to manage numbering of Sale Orders
*/
abstract class ModeleNumRefBookkeeping extends CommonNumRefGenerator
{
/**
* Return next free value
*
* @param BookKeeping $object Object we need next value for
* @return string|int<-1,0> Value if OK, -1 if KO
*/
abstract public function getNextValue(BookKeeping $object);
/**
* Return an example of numbering
*
* @return string Example
*/
abstract public function getExample();
}