Merge branch 'develop' of github.com:Dolibarr/dolibarr into develop
This commit is contained in:
commit
bd994cbead
@ -2,7 +2,7 @@
|
||||
# from Dolibarr GitHub repository.
|
||||
# For syntax, see http://about.travis-ci.org/docs/user/languages/php/
|
||||
|
||||
# We use dist: trusty to have php 5.4+ available
|
||||
# We use dist: trusty to have php 5.4+ available
|
||||
dist: trusty
|
||||
sudo: required
|
||||
|
||||
|
||||
@ -4,6 +4,7 @@
|
||||
* Copyright (C) 2013-2014 Florian Henry <florian.henry@open-concept.pro>
|
||||
* Copyright (C) 2014 Juanjo Menent <jmenent@2byte.es>
|
||||
* Copyright (C) 2015 Ari Elbaz (elarifr) <github@accedinfo.com>
|
||||
* Copyright (C) 2018 Frédéric France <frederic.france@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
|
||||
@ -30,6 +31,9 @@
|
||||
*/
|
||||
class AccountingAccount extends CommonObject
|
||||
{
|
||||
/**
|
||||
* @var string Name of element
|
||||
*/
|
||||
public $element='accounting_account';
|
||||
|
||||
/**
|
||||
@ -59,16 +63,6 @@ class AccountingAccount extends CommonObject
|
||||
*/
|
||||
public $db;
|
||||
|
||||
/**
|
||||
* @var string Error code (or message)
|
||||
*/
|
||||
public $error='';
|
||||
|
||||
/**
|
||||
* @var string[] Error codes (or messages)
|
||||
*/
|
||||
public $errors = array();
|
||||
|
||||
/**
|
||||
* @var int ID
|
||||
*/
|
||||
@ -79,17 +73,39 @@ class AccountingAccount extends CommonObject
|
||||
*/
|
||||
public $rowid;
|
||||
|
||||
public $datec; // Creation date
|
||||
/**
|
||||
* @var string Creation date
|
||||
*/
|
||||
public $datec;
|
||||
|
||||
/**
|
||||
* @var int ID
|
||||
* @var string pcg version
|
||||
*/
|
||||
public $fk_pcg_version;
|
||||
|
||||
/**
|
||||
* @var string pcg type
|
||||
*/
|
||||
public $pcg_type;
|
||||
|
||||
/**
|
||||
* @var string pcg subtype
|
||||
*/
|
||||
public $pcg_subtype;
|
||||
|
||||
/**
|
||||
* @var string account number
|
||||
*/
|
||||
public $account_number;
|
||||
|
||||
/**
|
||||
* @var int ID parent account
|
||||
*/
|
||||
public $account_parent;
|
||||
|
||||
/**
|
||||
* @var int ID category account
|
||||
*/
|
||||
public $account_category;
|
||||
|
||||
/**
|
||||
@ -112,8 +128,10 @@ class AccountingAccount extends CommonObject
|
||||
*/
|
||||
public $fk_user_modif;
|
||||
|
||||
public $active; // duplicate with status
|
||||
|
||||
/**
|
||||
* @var int active (duplicate with status)
|
||||
*/
|
||||
public $active;
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
|
||||
@ -76,6 +76,10 @@ class Categorie extends CommonObject
|
||||
'user' => 7,
|
||||
'bank_line' => 8,
|
||||
);
|
||||
|
||||
/**
|
||||
* @var array Code mapping from ID
|
||||
*/
|
||||
public static $MAP_ID_TO_CODE = array(
|
||||
0 => 'product',
|
||||
1 => 'supplier',
|
||||
@ -104,7 +108,8 @@ class Categorie extends CommonObject
|
||||
'bank_account' => 'account',
|
||||
'project' => 'project',
|
||||
);
|
||||
/**
|
||||
|
||||
/**
|
||||
* @var array Category tables mapping from type string
|
||||
*
|
||||
* @note Move to const array when PHP 5.6 will be our minimum target
|
||||
@ -120,7 +125,8 @@ class Categorie extends CommonObject
|
||||
'bank_account'=> 'account',
|
||||
'project' => 'project',
|
||||
);
|
||||
/**
|
||||
|
||||
/**
|
||||
* @var array Object class mapping from type string
|
||||
*
|
||||
* @note Move to const array when PHP 5.6 will be our minimum target
|
||||
@ -136,7 +142,8 @@ class Categorie extends CommonObject
|
||||
'bank_account' => 'Account',
|
||||
'project' => 'Project',
|
||||
);
|
||||
/**
|
||||
|
||||
/**
|
||||
* @var array Object table mapping from type string
|
||||
*
|
||||
* @note Move to const array when PHP 5.6 will be our minimum target
|
||||
@ -199,7 +206,14 @@ class Categorie extends CommonObject
|
||||
*/
|
||||
public $type;
|
||||
|
||||
public $cats = array(); // Categories table in memory
|
||||
/**
|
||||
* @var array Categories table in memory
|
||||
*/
|
||||
public $cats = array();
|
||||
|
||||
/**
|
||||
* @var array Mother of table
|
||||
*/
|
||||
public $motherof = array();
|
||||
|
||||
/**
|
||||
@ -1360,7 +1374,7 @@ class Categorie extends CommonObject
|
||||
* @param string|int $type Type of category ('customer', 'supplier', 'contact', 'product', 'member') or (0, 1, 2, ...)
|
||||
* @param string $mode 'id'=Get array of category ids, 'object'=Get array of fetched category instances, 'label'=Get array of category
|
||||
* labels, 'id'= Get array of category IDs
|
||||
* @return mixed Array of category objects or < 0 if KO
|
||||
* @return array|int Array of category objects or < 0 if KO
|
||||
*/
|
||||
function containing($id, $type, $mode='object')
|
||||
{
|
||||
|
||||
@ -990,6 +990,7 @@ class Facture extends CommonInvoice
|
||||
$this->user_valid = '';
|
||||
$this->fk_facture_source = 0;
|
||||
$this->date_creation = '';
|
||||
$this->date_modification = '';
|
||||
$this->date_validation = '';
|
||||
$this->ref_client = '';
|
||||
$this->close_code = '';
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
<?php
|
||||
/* Copyright (C) 2007-2012 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
/* Copyright (C) 2007-2018 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2018 Frédéric France <frederic.france@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
|
||||
@ -74,7 +75,7 @@ if ($modulepart == 'ecm')
|
||||
$fullpathselecteddir=$conf->ecm->dir_output.'/'.($selecteddir != '/' ? $selecteddir : '');
|
||||
$fullpathpreopened=$conf->ecm->dir_output.'/'.($preopened != '/' ? $preopened : '');
|
||||
}
|
||||
if ($modulepart == 'medias')
|
||||
elseif ($modulepart == 'medias')
|
||||
{
|
||||
$fullpathselecteddir=$dolibarr_main_data_root.'/medias/'.($selecteddir != '/' ? $selecteddir : '');
|
||||
$fullpathpreopened=$dolibarr_main_data_root.'/medias/'.($preopened != '/' ? $preopened : '');
|
||||
@ -96,7 +97,7 @@ if ($modulepart == 'ecm')
|
||||
{
|
||||
if (! $user->rights->ecm->read) accessforbidden();
|
||||
}
|
||||
if ($modulepart == 'medias')
|
||||
elseif ($modulepart == 'medias')
|
||||
{
|
||||
// Always allowed
|
||||
}
|
||||
@ -349,7 +350,7 @@ function treeOutputForAbsoluteDir($sqltree, $selecteddir, $fullpathselecteddir,
|
||||
{
|
||||
$files = @scandir($fullpathselecteddir);
|
||||
|
||||
if ($files)
|
||||
if (! empty($files))
|
||||
{
|
||||
natcasesort($files);
|
||||
if (count($files) > 2) /* The 2 accounts for . and .. */
|
||||
|
||||
@ -484,7 +484,7 @@ class tcpdi_parser {
|
||||
$v = $sarr[$key];
|
||||
if (($key == '/Type') AND ($v[0] == PDF_TYPE_TOKEN AND ($v[1] == 'XRef'))) {
|
||||
$valid_crs = true;
|
||||
} elseif (($key == '/Index') AND ($v[0] == PDF_TYPE_ARRAY AND count($v[1] >= 2))) {
|
||||
} elseif (($key == '/Index') AND ($v[0] == PDF_TYPE_ARRAY AND count($v[1]) >= 2)) {
|
||||
// first object number in the subsection
|
||||
$index_first = intval($v[1][0][1]);
|
||||
// number of entries in the subsection
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
<?php
|
||||
/* Copyright (C) 2010 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
/* Copyright (C) 2010 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2018 Frédéric France <frederic.france@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
|
||||
@ -228,7 +229,7 @@ class FactureTest extends PHPUnit_Framework_TestCase
|
||||
$newlocalobject,
|
||||
true,
|
||||
array(
|
||||
'newref','oldref','id','lines','client','thirdparty','brouillon','user_author','date_creation','date_validation','datem',
|
||||
'newref','oldref','id','lines','client','thirdparty','brouillon','user_author','date_creation','date_validation','datem','date_modification',
|
||||
'ref','statut','paye','specimen','facnumber','actiontypecode','actionmsg2','actionmsg','mode_reglement','cond_reglement',
|
||||
'cond_reglement_doc','situation_cycle_ref','situation_counter','situation_final','multicurrency_total_ht','multicurrency_total_tva',
|
||||
'multicurrency_total_ttc','fk_multicurrency','multicurrency_code','multicurrency_tx'
|
||||
|
||||
Loading…
Reference in New Issue
Block a user