Standardize and update code

This commit is contained in:
Philippe GRAND 2018-08-23 18:35:45 +02:00
parent 215677c972
commit 87067b2bc9
21 changed files with 92 additions and 11 deletions

View File

@ -34,7 +34,10 @@ require_once DOL_DOCUMENT_ROOT .'/core/class/commonobject.class.php';
*/
class Don extends CommonObject
{
public $element='don'; // Id that identify managed objects
/**
* @var string ID to identify managed object
*/
public $element='don';
/**
* @var string Name of table without prefix where object is stored

View File

@ -29,7 +29,10 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/commonobject.class.php';
*/
class PaymentDonation extends CommonObject
{
public $element='payment_donation'; //!< Id that identify managed objects
/**
* @var string ID to identify managed object
*/
public $element='payment_donation';
/**
* @var string Name of table without prefix where object is stored

View File

@ -27,7 +27,10 @@
*/
class EcmDirectory // extends CommonObject
{
public $element='ecm_directories'; //!< Id that identify managed objects
/**
* @var string ID to identify managed object
*/
public $element='ecm_directories';
/**
* @var string Name of table without prefix where object is stored

View File

@ -44,7 +44,11 @@ if (! empty($conf->productbatch->enabled)) require_once DOL_DOCUMENT_ROOT.'/expe
*/
class Expedition extends CommonObject
{
/**
* @var string ID to identify managed object
*/
public $element="shipping";
public $fk_element="fk_expedition";
/**
@ -2272,6 +2276,9 @@ class Expedition extends CommonObject
*/
class ExpeditionLigne extends CommonObjectLine
{
/**
* @var string ID to identify managed object
*/
public $element='expeditiondet';
/**

View File

@ -29,6 +29,9 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/coreobject.class.php';
*/
class ExpenseReportIk extends CoreObject
{
/**
* @var string ID to identify managed object
*/
public $element='expenseik';
/**

View File

@ -29,6 +29,9 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/coreobject.class.php';
*/
class ExpenseReportRule extends CoreObject
{
/**
* @var string ID to identify managed object
*/
public $element='expenserule';
/**

View File

@ -30,7 +30,10 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/commonobject.class.php';
*/
class PaymentExpenseReport extends CommonObject
{
public $element='payment_expensereport'; //!< Id that identify managed objects
/**
* @var string ID to identify managed object
*/
public $element='payment_expensereport';
/**
* @var string Name of table without prefix where object is stored

View File

@ -35,6 +35,9 @@ require_once DOL_DOCUMENT_ROOT .'/core/class/commonobjectline.class.php';
*/
class Fichinter extends CommonObject
{
/**
* @var string ID to identify managed object
*/
public $element='fichinter';
/**
@ -1331,6 +1334,9 @@ class FichinterLigne extends CommonObjectLine
var $duration; // Duree de l'intervention
var $rang = 0;
/**
* @var string ID to identify managed object
*/
public $element='fichinterdet';
/**

View File

@ -40,7 +40,10 @@ require_once DOL_DOCUMENT_ROOT.'/multicurrency/class/multicurrency.class.php';
*/
class CommandeFournisseur extends CommonOrder
{
public $element='order_supplier';
/**
* @var string ID to identify managed object
*/
public $element='order_supplier';
/**
* @var string Name of table without prefix where object is stored
@ -3092,7 +3095,10 @@ class CommandeFournisseur extends CommonOrder
*/
class CommandeFournisseurLigne extends CommonOrderLine
{
public $element='commande_fournisseurdet';
/**
* @var string ID to identify managed object
*/
public $element='commande_fournisseurdet';
/**
* @var string Name of table without prefix where object is stored

View File

@ -49,7 +49,10 @@ class CommandeFournisseurDispatch extends CommonObject
*/
public $errors = array();
public $element='commandefournisseurdispatch'; //!< Id that identify managed objects
/**
* @var string ID to identify managed object
*/
public $element='commandefournisseurdispatch';
/**
* @var string Name of table without prefix where object is stored

View File

@ -41,7 +41,10 @@ require_once DOL_DOCUMENT_ROOT.'/multicurrency/class/multicurrency.class.php';
*/
class FactureFournisseur extends CommonInvoice
{
public $element='invoice_supplier';
/**
* @var string ID to identify managed object
*/
public $element='invoice_supplier';
/**
* @var string Name of table without prefix where object is stored
@ -2565,6 +2568,9 @@ class FactureFournisseur extends CommonInvoice
*/
class SupplierInvoiceLine extends CommonObjectLine
{
/**
* @var string ID to identify managed object
*/
public $element='facture_fourn_det';
/**

View File

@ -35,6 +35,9 @@ require_once DOL_DOCUMENT_ROOT.'/multicurrency/class/multicurrency.class.php';
*/
class PaiementFourn extends Paiement
{
/**
* @var string ID to identify managed object
*/
public $element='payment_supplier';
/**

View File

@ -32,6 +32,9 @@ require_once DOL_DOCUMENT_ROOT .'/core/class/commonobject.class.php';
*/
class Holiday extends CommonObject
{
/**
* @var string ID to identify managed object
*/
public $element='holiday';
/**

View File

@ -28,6 +28,9 @@ require_once DOL_DOCUMENT_ROOT .'/core/class/commonobject.class.php';
*/
class Establishment extends CommonObject
{
/**
* @var string ID to identify managed object
*/
public $element='establishment';
/**

View File

@ -39,7 +39,11 @@ if (! empty($conf->commande->enabled)) require_once DOL_DOCUMENT_ROOT.'/commande
*/
class Livraison extends CommonObject
{
/**
* @var string ID to identify managed object
*/
public $element="delivery";
public $fk_element="fk_livraison";
/**
@ -1095,6 +1099,9 @@ class LivraisonLigne extends CommonObjectLine
public $product_ref;
public $product_label;
/**
* @var string ID to identify managed object
*/
public $element='livraisondet';
/**

View File

@ -29,7 +29,11 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/commonobject.class.php';
*/
class Loan extends CommonObject
{
/**
* @var string ID to identify managed object
*/
public $element='loan';
public $table='loan';
/**

View File

@ -29,7 +29,10 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/commonobject.class.php';
*/
class LoanSchedule extends CommonObject
{
public $element='loan_schedule'; //!< Id that identify managed objects
/**
* @var string ID to identify managed object
*/
public $element='loan_schedule';
/**
* @var string Name of table without prefix where object is stored

View File

@ -30,7 +30,10 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/commonobject.class.php';
*/
class PaymentLoan extends CommonObject
{
public $element='payment_loan'; //!< Id that identify managed objects
/**
* @var string ID to identify managed object
*/
public $element='payment_loan';
/**
* @var string Name of table without prefix where object is stored

View File

@ -34,7 +34,10 @@ require_once DOL_DOCUMENT_ROOT."/core/class/commonobject.class.php";
*/
class Opensurveysondage extends CommonObject
{
public $element='opensurvey_sondage'; //!< Id that identify managed objects
/**
* @var string ID to identify managed object
*/
public $element='opensurvey_sondage';
/**
* @var string Name of table without prefix where object is stored

View File

@ -43,6 +43,9 @@ require_once DOL_DOCUMENT_ROOT.'/product/stock/class/entrepot.class.php';
*/
class Product extends CommonObject
{
/**
* @var string ID to identify managed object
*/
public $element='product';
/**

View File

@ -33,6 +33,9 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/commonobject.class.php';
*/
class Entrepot extends CommonObject
{
/**
* @var string ID to identify managed object
*/
public $element='stock';
/**