diff --git a/COPYRIGHT b/COPYRIGHT index d43f4d506f1..adf7d38c04b 100644 --- a/COPYRIGHT +++ b/COPYRIGHT @@ -39,7 +39,7 @@ TCPDI 1.0.0 LGPL-3+ / Apache 2.0 Yes JS libraries: Ace 1.4.8 BSD Yes JS library to get code syntaxique coloration in a textarea. -ChartJS 2.9.3 MIT License Yes JS library for graph +ChartJS 2.9.4 MIT License Yes JS library for graph jQuery 3.5.1 MIT License Yes JS library jQuery UI 1.12.1 GPL and MIT License Yes JS library plugin UI jQuery select2 4.0.13 GPL and Apache License Yes JS library plugin for sexier multiselect. Warning: 4.0.6+ create troubles without patching css diff --git a/ChangeLog b/ChangeLog index 7b685eb3381..782528daae8 100644 --- a/ChangeLog +++ b/ChangeLog @@ -31,7 +31,7 @@ NEW: add column payment term into list of supplier invoices NEW: add column quantity in product margin page NEW: add column vat rate in page to define accounting account on product/service NEW: add costprice in fields of products list -NEW: added an import profile for CUSTOMER ORDER, PO, PROPOSAL MODULE, SUPPLIER INVOICE +NEW: add an import profile for CUSTOMER ORDER, PO, PROPOSAL MODULE, SUPPLIER INVOICE NEW: add employee link in expense report binding page NEW: add EORI No. as ProfID5 NEW: add export for various payments @@ -181,10 +181,9 @@ NEW: #15065 Add option to put the product label in bold in the PDF templates if For developers: --------------- NEW: add __MEMBER_TYPE__ substitution key +NEW: add __TYPE__ substitution key NEW: add function dolButtonToOpenUrlInDialogPopup() to be able to open page into a popup NEW: show line number on intervention card (via MAIN_VIEW_LINE_NUMBER) -NEW: API get contacts list of a given order -NEW: API endpoint getContacts and Clean results NEW: Add some fields to link website page to an other object NEW: fill ECM src object fields in dol_add_file_process NEW: conf to allow to show the full tree in warehouse popup @@ -194,10 +193,6 @@ NEW: can add event to log into blockedlog module with a constant NEW: add property cssview when declaring fields of an object NEW: Can use dynamic code into the 'enabled' property of DAO fields NEW: allow to edit "demand reason" field though API -NEW: API can update a payment -NEW: API get member by thirdparty -NEW: API get thirdparty by barcode -NEW: API get users by email / login NEW: fetch contact by email with REST API NEW: field ref_ext in llx_commandedet NEW: fields ref_ext for Attributes and Combinations @@ -213,10 +208,17 @@ NEW: Triggers Attributes and Attributes values NEW: added incoterms data into the substitution array NEW: add send context for ticket NEW: add a message in error_log after detection of SQL or script injection -NEW: add __TYPE__ substitution key NEW: add validation of MX domain for emails NEW: calculate the virtual stock in transverse mode ( not on getEntity('commande'), ... but on getEntity('stock') ) -NEW: Graphics can be horizontal bars. +NEW: Graphics can be horizontal bars + +APIs +NEW: API get contacts list of a given order +NEW: API endpoint getContacts and Clean results +NEW: API can update a payment +NEW: API get member by thirdparty +NEW: API get thirdparty by barcode +NEW: API get users by email / login HOOKs NEW: Hook on propal card @@ -243,7 +245,7 @@ Following changes may create regressions for some external modules, but were nec * The API addPayment for api_invoice has evolved to accept amount into a foreign currency. You must provide array(amount=>X,mutlicurrency_ammount=>Y) instead of simple amount. * The method select_thirdparty(), deprecated since 3.8, into html.form.class.php has been removed. * Depreciate all methods with name ->valide(). Use instead methods ->validate(). - +* Function showStripePaymentUrl, getStripePaymentUrl, showPaypalPaymentUrl and getPaypalPaymentUrl has been removed. The generic one showOnlinePaymentUrl and getOnlinePaymentUrl are always used. ***** ChangeLog for 12.0.3 compared to 12.0.2 ***** @@ -380,8 +382,8 @@ FIX: SQL Problem in customer invoice list FIX: SQL Problem in social contribution list FIX: SQL Problem in supplier invoice list FIX: SQL syntax error when editing extrafields -FIX: Sql type -FIX: takepos 12 hook +FIX: SQL type +FIX: TakePOS 12 hook FIX: Update form erased extrafields that were hidden FIX: Update of extrafields date FIX: Update of extrafiels on draft object @@ -395,7 +397,7 @@ For users: NEW: Module MO (Manufacturing Order) is available as stable module. NEW: Receipt printer module moved from 'development' to 'experimental' -NEW: Add option MAIN_VIEW_LINE_NUMBER_IN_LIST for some lists. +NEW: add option MAIN_VIEW_LINE_NUMBER_IN_LIST for some lists NEW: add numbering module for TakePOS module NEW: 2 new options when creating an invoice from time spent on a project : by period or by task NEW: Accountancy add column thirdparty on binding page @@ -406,19 +408,19 @@ NEW: Accountancy - Add possibility to manage a short alternative label for accou NEW: Accountancy - General ledger - Add an option to search not reconciled lines NEW: Add accountancy code of thirdparty in contact and supplier export NEW: support webp image format -NEW: Add checkbox "overwrite if exists" into ECM/DMS module +NEW: add checkbox "overwrite if exists" into ECM/DMS module NEW: add a link to notes in members list NEW: add a parameter to group same products in TakePOS NEW: add a parameter to sort product by label in TakePOS -NEW: Add a profil to import contact categories -NEW: Add company extrafields into order export +NEW: add a profil to import contact categories +NEW: add company extrafields into order export NEW: add const CASHDESK_FORCE_DECREASE_STOCK to force batch decrementation NEW: add const TAKEPOS_NUMPAD_USE_PAYMENT_ICON to use icons on payment buttons NEW: add csv separator setup in module admin NEW: add dedicated substitutions keys for extrafields of type date and datetime NEW: add default warehouse for dispatch -NEW: Add due date in feature "Export accounting documents" -NEW: Add duration information for fichinter +NEW: add due date in feature "Export accounting documents" +NEW: add duration information for fichinter NEW: Start support of Dark theme into ELDY theme NEW: Add field author public alias for blog post on website module NEW: Add "finished" field on product list diff --git a/SECURITY.md b/SECURITY.md index 56e1da679ed..77307516f73 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -12,8 +12,7 @@ This file contains some policies about the security reports on Dolibarr ERP CRM ## Reporting a Vulnerability -To report a vulnerability, please send an email to security@dolibarr.org -In most cases, after fixing the security, we make an answer by email to say the issue has been fixed. +To report a vulnerability, please use GitHub security advisory (alternatively send an email to security@dolibarr.org) ## Hunting vulnerabilities on Dolibarr diff --git a/build/makepack-dolibarr.pl b/build/makepack-dolibarr.pl index 314aaff7177..17a935f6234 100755 --- a/build/makepack-dolibarr.pl +++ b/build/makepack-dolibarr.pl @@ -581,23 +581,36 @@ if ($nboftargetok) { $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/workstation*`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/themes/oblyon*`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/themes/allscreen*`; + $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/theme/common/octicons/LICENSE`; + # Removed other test files $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/public/test`; $ret=`rm -fr $BUILDROOT/$PROJECT/test`; $ret=`rm -fr $BUILDROOT/$PROJECT/Thumbs.db $BUILDROOT/$PROJECT/*/Thumbs.db $BUILDROOT/$PROJECT/*/*/Thumbs.db $BUILDROOT/$PROJECT/*/*/*/Thumbs.db $BUILDROOT/$PROJECT/*/*/*/*/Thumbs.db`; $ret=`rm -f $BUILDROOT/$PROJECT/.cvsignore $BUILDROOT/$PROJECT/*/.cvsignore $BUILDROOT/$PROJECT/*/*/.cvsignore $BUILDROOT/$PROJECT/*/*/*/.cvsignore $BUILDROOT/$PROJECT/*/*/*/*/.cvsignore $BUILDROOT/$PROJECT/*/*/*/*/*/.cvsignore $BUILDROOT/$PROJECT/*/*/*/*/*/*/.cvsignore`; $ret=`rm -f $BUILDROOT/$PROJECT/.gitignore $BUILDROOT/$PROJECT/*/.gitignore $BUILDROOT/$PROJECT/*/*/.gitignore $BUILDROOT/$PROJECT/*/*/*/.gitignore $BUILDROOT/$PROJECT/*/*/*/*/.gitignore $BUILDROOT/$PROJECT/*/*/*/*/*/.gitignore $BUILDROOT/$PROJECT/*/*/*/*/*/*/.gitignore`; + + # Removed files installed by the awful composer $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/geoip/sample*.*`; + $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/bin`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/ckeditor/ckeditor/adapters`; # Keep this removal in case we embed libraries $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/ckeditor/ckeditor/samples`; # Keep this removal in case we embed libraries $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/ckeditor/_source`; # _source must be kept into tarball for official debian, not for the rest - + $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/composer`; + $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/doctrine`; $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/jquery/plugins/multiselect/MIT-LICENSE.txt`; $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/jquery/plugins/select2/release.sh`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/mike42/escpos-php/doc`; - $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/mike42/escpos-php/example`; - $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/mike42/escpos-php/test`; + $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/mike42/escpos-php/example`; + $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/mike42/escpos-php/test`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/mobiledetect/mobiledetectlib/.gitmodules`; + $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/mobiledetect/mobiledetectlib/docs`; + $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/nnnick/chartjs/.github`; + $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/nnnick/chartjs/docs`; + $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/nnnick/chartjs/samples`; + $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/nnnick/chartjs/scripts`; + $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/nnnick/chartjs/src`; + $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/nnnick/chartjs/test`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/nusoap/lib/Mail`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/nusoap/samples`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/parsedown/LICENSE.txt`; @@ -612,21 +625,17 @@ if ($nboftargetok) { $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/sabre/sabre/*/tests`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/stripe/tests`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/stripe/LICENSE`; - $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/tcpdf/fonts/dejavu-fonts-ttf-*`; - $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/tcpdf/fonts/freefont-*`; - $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/tcpdf/fonts/ae_fonts_*`; - $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/tcpdf/fonts/utils`; - $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/tcpdf/LICENSE.TXT`; + $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/tecnickcom/examples`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/tecnickcom/tcpdf/fonts/dejavu-fonts-ttf-*`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/tecnickcom/tcpdf/fonts/freefont-*`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/tecnickcom/tcpdf/fonts/ae_fonts_*`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/tecnickcom/tcpdf/fonts/utils`; $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/tecnickcom/tcpdf/tools`; $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/tecnickcom/tcpdf/LICENSE.TXT`; - + $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/tecnickcom/tcpdf/tools`; + $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/vendor`; + $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/webmozart`; $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/autoload.php`; - - $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/theme/common/octicons/LICENSE`; } # Build package for each target diff --git a/composer.json b/composer.json index 9fede994525..a943fbe0aa3 100644 --- a/composer.json +++ b/composer.json @@ -35,7 +35,7 @@ "nnnick/chartjs" : "^2.9", "stripe/stripe-php" : "6.43.1", "maximebf/debugbar" : "1.15.1", - "symfony/var-dumper": "3" + "symfony/var-dumper" : "3" }, "require-dev" : { "php-parallel-lint/php-parallel-lint" : "^0", diff --git a/composer.lock b/composer.lock index 5afe0ca34f2..e0462435f5e 100644 --- a/composer.lock +++ b/composer.lock @@ -6,6 +6,53 @@ ], "content-hash": "1dbd2d05cc0836acfca5988f29005cf2", "packages": [ + { + "name": "Psr/log", + "version": "1.1.3", + "source": { + "type": "git", + "url": "https://github.com/php-fig/log.git", + "reference": "0f73288fd15629204f9d42b7055f72dacbe811fc" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/php-fig/log/zipball/0f73288fd15629204f9d42b7055f72dacbe811fc", + "reference": "0f73288fd15629204f9d42b7055f72dacbe811fc", + "shasum": "" + }, + "require": { + "php": ">=5.3.0" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.1.x-dev" + } + }, + "autoload": { + "psr-4": { + "Psr\\Log\\": "Psr/Log/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" + } + ], + "description": "Common interface for logging libraries", + "homepage": "https://github.com/php-fig/log", + "keywords": [ + "log", + "psr", + "psr-3" + ], + "time": "2020-03-23T09:12:05+00:00" + }, { "name": "ckeditor/ckeditor", "version": "4.12.1", @@ -217,16 +264,16 @@ }, { "name": "nnnick/chartjs", - "version": "v2.9.3", + "version": "v2.9.4", "source": { "type": "git", "url": "https://github.com/chartjs/Chart.js.git", - "reference": "06f73dc3590084b2c464bf08189c7aee2b6b92d2" + "reference": "9bd4cf82fda9f50a5fb50b72843e06ab88124278" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/chartjs/Chart.js/zipball/06f73dc3590084b2c464bf08189c7aee2b6b92d2", - "reference": "06f73dc3590084b2c464bf08189c7aee2b6b92d2", + "url": "https://api.github.com/repos/chartjs/Chart.js/zipball/9bd4cf82fda9f50a5fb50b72843e06ab88124278", + "reference": "9bd4cf82fda9f50a5fb50b72843e06ab88124278", "shasum": "" }, "require": { @@ -254,7 +301,11 @@ "JS", "chart" ], - "time": "2019-11-14T18:37:30+00:00" + "support": { + "issues": "https://github.com/chartjs/Chart.js/issues", + "source": "https://github.com/chartjs/Chart.js/tree/v2.9.4" + }, + "time": "2020-10-19T12:22:11+00:00" }, { "name": "phpoffice/phpexcel", @@ -314,53 +365,6 @@ "abandoned": "phpoffice/phpspreadsheet", "time": "2015-05-01T07:00:55+00:00" }, - { - "name": "psr/log", - "version": "1.1.3", - "source": { - "type": "git", - "url": "https://github.com/php-fig/log.git", - "reference": "0f73288fd15629204f9d42b7055f72dacbe811fc" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/php-fig/log/zipball/0f73288fd15629204f9d42b7055f72dacbe811fc", - "reference": "0f73288fd15629204f9d42b7055f72dacbe811fc", - "shasum": "" - }, - "require": { - "php": ">=5.3.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.1.x-dev" - } - }, - "autoload": { - "psr-4": { - "Psr\\Log\\": "Psr/Log/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" - } - ], - "description": "Common interface for logging libraries", - "homepage": "https://github.com/php-fig/log", - "keywords": [ - "log", - "psr", - "psr-3" - ], - "time": "2020-03-23T09:12:05+00:00" - }, { "name": "restler/framework", "version": "3.0.0-RC6", @@ -2037,159 +2041,6 @@ ], "time": "2019-08-06T08:03:45+00:00" }, - { - "name": "symfony/polyfill-php72", - "version": "v1.18.1", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-php72.git", - "reference": "639447d008615574653fb3bc60d1986d7172eaae" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php72/zipball/639447d008615574653fb3bc60d1986d7172eaae", - "reference": "639447d008615574653fb3bc60d1986d7172eaae", - "shasum": "" - }, - "require": { - "php": ">=5.3.3" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.18-dev" - }, - "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Php72\\": "" - }, - "files": [ - "bootstrap.php" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill backporting some PHP 7.2+ features to lower PHP versions", - "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "polyfill", - "portable", - "shim" - ], - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], - "time": "2020-07-14T12:35:20+00:00" - }, - { - "name": "symfony/polyfill-php80", - "version": "v1.18.1", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-php80.git", - "reference": "d87d5766cbf48d72388a9f6b85f280c8ad51f981" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/d87d5766cbf48d72388a9f6b85f280c8ad51f981", - "reference": "d87d5766cbf48d72388a9f6b85f280c8ad51f981", - "shasum": "" - }, - "require": { - "php": ">=7.0.8" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.18-dev" - }, - "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" - } - }, - "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Php80\\": "" - }, - "files": [ - "bootstrap.php" - ], - "classmap": [ - "Resources/stubs" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Ion Bazan", - "email": "ion.bazan@gmail.com" - }, - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill backporting some PHP 8.0+ features to lower PHP versions", - "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "polyfill", - "portable", - "shim" - ], - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], - "time": "2020-07-14T12:35:20+00:00" - }, { "name": "symfony/yaml", "version": "v3.4.32", @@ -2312,5 +2163,5 @@ "ext-curl": "*" }, "platform-dev": [], - "plugin-api-version": "1.1.0" + "plugin-api-version": "2.0.0" } diff --git a/htdocs/accountancy/bookkeeping/card.php b/htdocs/accountancy/bookkeeping/card.php index b250459bdce..d0f43cfe3dd 100644 --- a/htdocs/accountancy/bookkeeping/card.php +++ b/htdocs/accountancy/bookkeeping/card.php @@ -3,7 +3,7 @@ * Copyright (C) 2013-2017 Florian Henry * Copyright (C) 2013-2018 Alexandre Spangaro * Copyright (C) 2017 Laurent Destailleur - * Copyright (C) 2018 Frédéric France + * Copyright (C) 2018-2020 Frédéric France * * 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 @@ -128,8 +128,7 @@ if ($action == "confirm_update") { if ($result < 0) { setEventMessages($object->error, $object->errors, 'errors'); } else { - if ($mode != '_tmp') - { + if ($mode != '_tmp') { setEventMessages($langs->trans('RecordSaved'), null, 'mesgs'); } @@ -165,14 +164,14 @@ if ($action == "confirm_update") { $object->label_operation = $label_operation; $object->debit = $debit; $object->credit = $credit; - $object->doc_date = GETPOST('doc_date', 'alpha'); - $object->doc_type = GETPOST('doc_type', 'alpha'); + $object->doc_date = (string) GETPOST('doc_date', 'alpha'); + $object->doc_type = (string) GETPOST('doc_type', 'alpha'); $object->piece_num = $piece_num; - $object->doc_ref = GETPOST('doc_ref', 'alpha'); + $object->doc_ref = (string) GETPOST('doc_ref', 'alpha'); $object->code_journal = $journal_code; $object->journal_label = $journal_label; - $object->fk_doc = (int) GETPOST('fk_doc', 'int'); - $object->fk_docdet = (int) GETPOST('fk_docdet', 'int'); + $object->fk_doc = GETPOSTINT('fk_doc'); + $object->fk_docdet = GETPOSTINT('fk_docdet'); if (floatval($debit) != 0.0) { $object->montant = $debit; // deprecated @@ -190,8 +189,7 @@ if ($action == "confirm_update") { if ($result < 0) { setEventMessages($object->error, $object->errors, 'errors'); } else { - if ($mode != '_tmp') - { + if ($mode != '_tmp') { setEventMessages($langs->trans('RecordSaved'), null, 'mesgs'); } diff --git a/htdocs/accountancy/class/accountingjournal.class.php b/htdocs/accountancy/class/accountingjournal.class.php index c002abf2a89..a76be081471 100644 --- a/htdocs/accountancy/class/accountingjournal.class.php +++ b/htdocs/accountancy/class/accountingjournal.class.php @@ -37,7 +37,7 @@ class AccountingJournal extends CommonObject public $table_element = 'accounting_journal'; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Fieldname with ID of parent key if this field has a parent */ public $fk_element = ''; diff --git a/htdocs/accountancy/journal/bankjournal.php b/htdocs/accountancy/journal/bankjournal.php index 0acb4e0bedd..d353041234f 100644 --- a/htdocs/accountancy/journal/bankjournal.php +++ b/htdocs/accountancy/journal/bankjournal.php @@ -7,7 +7,7 @@ * Copyright (C) 2013-2019 Alexandre Spangaro * Copyright (C) 2013-2014 Florian Henry * Copyright (C) 2013-2014 Olivier Geffroy - * Copyright (C) 2017-2018 Frédéric France + * Copyright (C) 2017-2020 Frédéric France * Copyright (C) 2018 Ferran Marcet * Copyright (C) 2018 Eric Seigne * @@ -73,15 +73,18 @@ $date_endmonth = GETPOST('date_endmonth', 'int'); $date_endday = GETPOST('date_endday', 'int'); $date_endyear = GETPOST('date_endyear', 'int'); $in_bookkeeping = GETPOST('in_bookkeeping', 'aZ09'); -if ($in_bookkeeping == '') $in_bookkeeping = 'notyet'; +if ($in_bookkeeping == '') { + $in_bookkeeping = 'notyet'; +} $now = dol_now(); $action = GETPOST('action', 'aZ09'); // Security check -if ($user->socid > 0 && empty($id_journal)) +if ($user->socid > 0 && empty($id_journal)) { accessforbidden(); +} /* @@ -93,8 +96,7 @@ $error = 0; $date_start = dol_mktime(0, 0, 0, $date_startmonth, $date_startday, $date_startyear); $date_end = dol_mktime(23, 59, 59, $date_endmonth, $date_endday, $date_endyear); -if (empty($date_startmonth) || empty($date_endmonth)) -{ +if (empty($date_startmonth) || empty($date_endmonth)) { // Period by default on transfer $dates = getDefaultDatesForTransfer(); $date_start = $dates['date_start']; @@ -103,8 +105,7 @@ if (empty($date_startmonth) || empty($date_endmonth)) $pastmonth = $dates['pastmonth']; } -if (!GETPOSTISSET('date_startmonth') && (empty($date_start) || empty($date_end))) // We define date_start and date_end, only if we did not submit the form -{ +if (!GETPOSTISSET('date_startmonth') && (empty($date_start) || empty($date_end))) { // We define date_start and date_end, only if we did not submit the form $date_start = dol_get_first_day($pastmonthyear, $pastmonth, false); $date_end = dol_get_last_day($pastmonthyear, $pastmonth, false); } @@ -124,19 +125,18 @@ $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."societe as soc on bu1.url_id=soc.rowid"; $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."user as u on bu2.url_id=u.rowid"; $sql .= " WHERE ba.fk_accountancy_journal=".$id_journal; $sql .= ' AND b.amount != 0 AND ba.entity IN ('.getEntity('bank_account', 0).')'; // We don't share object for accountancy -if ($date_start && $date_end) +if ($date_start && $date_end) { $sql .= " AND b.dateo >= '".$db->idate($date_start)."' AND b.dateo <= '".$db->idate($date_end)."'"; +} // Define begin binding date if (!empty($conf->global->ACCOUNTING_DATE_START_BINDING)) { $sql .= " AND b.dateo >= '".$db->idate($conf->global->ACCOUNTING_DATE_START_BINDING)."'"; } // Already in bookkeeping or not -if ($in_bookkeeping == 'already') -{ +if ($in_bookkeeping == 'already') { $sql .= " AND (b.rowid IN (SELECT fk_doc FROM ".MAIN_DB_PREFIX."accounting_bookkeeping as ab WHERE ab.doc_type='bank') )"; } -if ($in_bookkeeping == 'notyet') -{ +if ($in_bookkeeping == 'notyet') { $sql .= " AND (b.rowid NOT IN (SELECT fk_doc FROM ".MAIN_DB_PREFIX."accounting_bookkeeping as ab WHERE ab.doc_type='bank') )"; } $sql .= " ORDER BY b.datev"; @@ -177,9 +177,9 @@ if ($result) { //print $sql; // Variables - $account_supplier = (($conf->global->ACCOUNTING_ACCOUNT_SUPPLIER != "") ? $conf->global->ACCOUNTING_ACCOUNT_SUPPLIER : 'NotDefined'); // NotDefined is a reserved word - $account_customer = (($conf->global->ACCOUNTING_ACCOUNT_CUSTOMER != "") ? $conf->global->ACCOUNTING_ACCOUNT_CUSTOMER : 'NotDefined'); // NotDefined is a reserved word - $account_employee = (!empty($conf->global->SALARIES_ACCOUNTING_ACCOUNT_PAYMENT) ? $conf->global->SALARIES_ACCOUNTING_ACCOUNT_PAYMENT : 'NotDefined'); // NotDefined is a reserved word + $account_supplier = (($conf->global->ACCOUNTING_ACCOUNT_SUPPLIER != "") ? $conf->global->ACCOUNTING_ACCOUNT_SUPPLIER : 'NotDefined'); // NotDefined is a reserved word + $account_customer = (($conf->global->ACCOUNTING_ACCOUNT_CUSTOMER != "") ? $conf->global->ACCOUNTING_ACCOUNT_CUSTOMER : 'NotDefined'); // NotDefined is a reserved word + $account_employee = (!empty($conf->global->SALARIES_ACCOUNTING_ACCOUNT_PAYMENT) ? $conf->global->SALARIES_ACCOUNTING_ACCOUNT_PAYMENT : 'NotDefined'); // NotDefined is a reserved word $account_pay_vat = (!empty($conf->global->ACCOUNTING_VAT_PAY_ACCOUNT) ? $conf->global->ACCOUNTING_VAT_PAY_ACCOUNT : 'NotDefined'); // NotDefined is a reserved word $account_pay_donation = (!empty($conf->global->DONATION_ACCOUNTINGACCOUNT) ? $conf->global->DONATION_ACCOUNTINGACCOUNT : 'NotDefined'); // NotDefined is a reserved word $account_pay_subscription = (!empty($conf->global->ADHERENT_SUBSCRIPTION_ACCOUNTINGACCOUNT) ? $conf->global->ADHERENT_SUBSCRIPTION_ACCOUNTINGACCOUNT : 'NotDefined'); // NotDefined is a reserved word @@ -198,23 +198,28 @@ if ($result) { // one line for bank record = tabbq // one line for thirdparty record = tabtp $i = 0; - while ($i < $num) - { + while ($i < $num) { $obj = $db->fetch_object($result); $lineisapurchase = -1; $lineisasale = -1; // Old method to detect if it's a sale or purchase - if ($obj->label == '(SupplierInvoicePayment)' || $obj->label == '(SupplierInvoicePaymentBack)') $lineisapurchase = 1; - if ($obj->label == '(CustomerInvoicePayment)' || $obj->label == '(CustomerInvoicePaymentBack)') $lineisasale = 1; - // Try a more reliable method to detect if record is a supplier payment or a customer payment - if ($lineisapurchase < 0) - { - if ($obj->typeop_payment_supplier == 'payment_supplier') $lineisapurchase = 1; + if ($obj->label == '(SupplierInvoicePayment)' || $obj->label == '(SupplierInvoicePaymentBack)') { + $lineisapurchase = 1; } - if ($lineisasale < 0) - { - if ($obj->typeop_payment == 'payment') $lineisasale = 1; + if ($obj->label == '(CustomerInvoicePayment)' || $obj->label == '(CustomerInvoicePaymentBack)') { + $lineisasale = 1; + } + // Try a more reliable method to detect if record is a supplier payment or a customer payment + if ($lineisapurchase < 0) { + if ($obj->typeop_payment_supplier == 'payment_supplier') { + $lineisapurchase = 1; + } + } + if ($lineisasale < 0) { + if ($obj->typeop_payment == 'payment') { + $lineisasale = 1; + } } //var_dump($obj->type_payment); var_dump($obj->type_payment_supplier); //var_dump($lineisapurchase); //var_dump($lineisasale); @@ -224,28 +229,30 @@ if ($result) { // Set accountancy code for thirdparty (example: '411CU...' or '411' if no subledger account defined on customer) $compta_soc = 'NotDefined'; - if ($lineisapurchase > 0) + if ($lineisapurchase > 0) { $compta_soc = (($obj->code_compta_fournisseur != "") ? $obj->code_compta_fournisseur : $account_supplier); - if ($lineisasale > 0) + } + if ($lineisasale > 0) { $compta_soc = (!empty($obj->code_compta) ? $obj->code_compta : $account_customer); + } $tabcompany[$obj->rowid] = array( - 'id' => $obj->socid, - 'name' => $obj->name, - 'code_compta' => $compta_soc, - 'email' => $obj->email + 'id' => $obj->socid, + 'name' => $obj->name, + 'code_compta' => $compta_soc, + 'email' => $obj->email ); // Set accountancy code for user $compta_user = (!empty($obj->accountancy_code) ? $obj->accountancy_code : ''); $tabuser[$obj->rowid] = array( - 'id' => $obj->userid, - 'name' => dolGetFirstLastname($obj->firstname, $obj->lastname), - 'lastname' => $obj->lastname, - 'firstname' => $obj->firstname, - 'email' => $obj->useremail, - 'accountancy_code' => $compta_user + 'id' => $obj->userid, + 'name' => dolGetFirstLastname($obj->firstname, $obj->lastname), + 'lastname' => $obj->lastname, + 'firstname' => $obj->firstname, + 'email' => $obj->useremail, + 'accountancy_code' => $compta_user ); // Variable bookkeeping ($obj->rowid is Bank Id) @@ -264,10 +271,6 @@ if ($result) { // Load of url links to the line into llx_bank $links = $object->get_url($obj->rowid); // Get an array('url'=>, 'url_id'=>, 'label'=>, 'type'=> 'fk_bank'=> ) - //var_dump($i); - //var_dump($tabpay); - //var_dump($tabcompany); - // By default $tabpay[$obj->rowid]['type'] = 'unknown'; // Can be SOLD, miscellaneous entry, payment of patient, or any old record with no links in bank_url. $tabtype[$obj->rowid] = 'unknown'; @@ -277,17 +280,14 @@ if ($result) { if (is_array($links) && count($links) > 0) { // Now loop on each link of record in bank. foreach ($links as $key => $val) { - if (in_array($links[$key]['type'], array('sc', 'payment_sc', 'payment', 'payment_supplier', 'payment_vat', 'payment_expensereport', 'banktransfert', 'payment_donation', 'member', 'payment_loan', 'payment_salary', 'payment_various'))) - { + if (in_array($links[$key]['type'], array('sc', 'payment_sc', 'payment', 'payment_supplier', 'payment_vat', 'payment_expensereport', 'banktransfert', 'payment_donation', 'member', 'payment_loan', 'payment_salary', 'payment_various'))) { // So we excluded 'company' and 'user' here. We want only payment lines // We save tabtype for a future use, to remember what kind of payment it is $tabpay[$obj->rowid]['type'] = $links[$key]['type']; $tabtype[$obj->rowid] = $links[$key]['type']; - } elseif (in_array($links[$key]['type'], array('company', 'user'))) - { - if ($tabpay[$obj->rowid]['type'] == 'unknown') - { + } elseif (in_array($links[$key]['type'], array('company', 'user'))) { + if ($tabpay[$obj->rowid]['type'] == 'unknown') { // We can guess here it is a bank record for a thirdparty company or a user. // But we won't be able to record somewhere else than into a waiting account, because there is no other journal to record the contreparty. } @@ -312,16 +312,23 @@ if ($result) { $societestatic->name = $links[$key]['label']; $societestatic->email = $tabcompany[$obj->rowid]['email']; $tabpay[$obj->rowid]["soclib"] = $societestatic->getNomUrl(1, '', 30); - if ($compta_soc) $tabtp[$obj->rowid][$compta_soc] += $obj->amount; + if ($compta_soc) { + $tabtp[$obj->rowid][$compta_soc] += $obj->amount; + } } elseif ($links[$key]['type'] == 'user') { $userstatic->id = $links[$key]['url_id']; $userstatic->name = $links[$key]['label']; $userstatic->email = $tabuser[$obj->rowid]['email']; $userstatic->firstname = $tabuser[$obj->rowid]['firstname']; $userstatic->lastname = $tabuser[$obj->rowid]['lastname']; - if ($userstatic->id > 0) $tabpay[$obj->rowid]["soclib"] = $userstatic->getNomUrl(1, '', 30); - else $tabpay[$obj->rowid]["soclib"] = '???'; // Should not happen, but happens with old data when id of user was not saved on expense report payment. - if ($compta_user) $tabtp[$obj->rowid][$compta_user] += $obj->amount; + if ($userstatic->id > 0) { + $tabpay[$obj->rowid]["soclib"] = $userstatic->getNomUrl(1, '', 30); + } else { + $tabpay[$obj->rowid]["soclib"] = '???'; // Should not happen, but happens with old data when id of user was not saved on expense report payment. + } + if ($compta_user) { + $tabtp[$obj->rowid][$compta_user] += $obj->amount; + } } elseif ($links[$key]['type'] == 'sc') { $chargestatic->id = $links[$key]['url_id']; $chargestatic->ref = $links[$key]['url_id']; @@ -329,8 +336,9 @@ if ($result) { $tabpay[$obj->rowid]["lib"] .= ' '.$chargestatic->getNomUrl(2); $reg = array(); if (preg_match('/^\((.*)\)$/i', $links[$key]['label'], $reg)) { - if ($reg[1] == 'socialcontribution') + if ($reg[1] == 'socialcontribution') { $reg[1] = 'SocialContribution'; + } $chargestatic->label = $langs->trans($reg[1]); } else { $chargestatic->label = $links[$key]['label']; @@ -430,20 +438,17 @@ if ($result) { // If no links were found to know the amount on thirdparty, we try to guess it. // This may happens on bank entries without the links lines to 'company'. - if (empty($tabtp[$obj->rowid]) && !empty($tabmoreinfo[$obj->rowid]['withdraw'])) // If we dont find 'company' link because it is an old 'withdraw' record - { + if (empty($tabtp[$obj->rowid]) && !empty($tabmoreinfo[$obj->rowid]['withdraw'])) { // If we dont find 'company' link because it is an old 'withdraw' record foreach ($links as $key => $val) { if ($links[$key]['type'] == 'payment') { // Get thirdparty $tmppayment->fetch($links[$key]['url_id']); $arrayofamounts = $tmppayment->getAmountsArray(); if (is_array($arrayofamounts)) { - foreach ($arrayofamounts as $invoiceid => $amount) - { + foreach ($arrayofamounts as $invoiceid => $amount) { $tmpinvoice->fetch($invoiceid); $tmpinvoice->fetch_thirdparty(); - if ($tmpinvoice->thirdparty->code_compta) - { + if ($tmpinvoice->thirdparty->code_compta) { $tabtp[$obj->rowid][$tmpinvoice->thirdparty->code_compta] += $amount; } } @@ -453,7 +458,9 @@ if ($result) { } // If no links were found to know the amount on thirdparty, we init it to account 'NotDefined'. - if (empty($tabtp[$obj->rowid])) $tabtp[$obj->rowid]['NotDefined'] = $tabbq[$obj->rowid][$compta_bank]; + if (empty($tabtp[$obj->rowid])) { + $tabtp[$obj->rowid]['NotDefined'] = $tabbq[$obj->rowid][$compta_bank]; + } // Check account number is ok /*if ($action == 'writebookkeeping') // Make test now in such a case @@ -494,8 +501,7 @@ if (!$error && $action == 'writebookkeeping') { $now = dol_now(); $error = 0; - foreach ($tabpay as $key => $val) // $key is rowid into llx_bank - { + foreach ($tabpay as $key => $val) { // $key is rowid into llx_bank $date = dol_print_date($db->jdate($val["date"]), 'day'); $ref = getSourceDocRef($val, $tabtype[$key]); @@ -513,17 +519,18 @@ if (!$error && $action == 'writebookkeeping') { var_dump($tabbq);exit;*/ // Bank - if (!$errorforline && is_array($tabbq[$key])) - { + if (!$errorforline && is_array($tabbq[$key])) { // Line into bank account - foreach ($tabbq[$key] as $k => $mt) - { - if ($mt) - { + foreach ($tabbq[$key] as $k => $mt) { + if ($mt) { $reflabel = ''; - if (!empty($val['lib'])) $reflabel .= dol_string_nohtmltag($val['lib'])." - "; + if (!empty($val['lib'])) { + $reflabel .= dol_string_nohtmltag($val['lib'])." - "; + } $reflabel .= $langs->trans("Bank").' '.dol_string_nohtmltag($val['bank_account_ref']); - if (!empty($val['soclib'])) $reflabel .= " - ".dol_string_nohtmltag($val['soclib']); + if (!empty($val['soclib'])) { + $reflabel .= " - ".dol_string_nohtmltag($val['soclib']); + } $bookkeeping = new BookKeeping($db); $bookkeeping->doc_date = $val["date"]; @@ -556,8 +563,7 @@ if (!$error && $action == 'writebookkeeping') { $result = $bookkeeping->create($user); if ($result < 0) { - if ($bookkeeping->error == 'BookkeepingRecordAlreadyExists') // Already exists - { + if ($bookkeeping->error == 'BookkeepingRecordAlreadyExists') { // Already exists $error++; $errorforline++; setEventMessages('Transaction for ('.$bookkeeping->doc_type.', '.$bookkeeping->fk_doc.', '.$bookkeeping->fk_docdet.') were already recorded', null, 'warnings'); @@ -572,18 +578,16 @@ if (!$error && $action == 'writebookkeeping') { } // Third party - if (!$errorforline) - { - if (is_array($tabtp[$key])) - { + if (!$errorforline) { + if (is_array($tabtp[$key])) { // Line into thirdparty account foreach ($tabtp[$key] as $k => $mt) { - if ($mt) - { + if ($mt) { $reflabel = ''; - if (!empty($val['lib'])) $reflabel .= dol_string_nohtmltag($val['lib']).($val['soclib'] ? " - " : ""); - if ($tabtype[$key] == 'banktransfert') - { + if (!empty($val['lib'])) { + $reflabel .= dol_string_nohtmltag($val['lib']).($val['soclib'] ? " - " : ""); + } + if ($tabtype[$key] == 'banktransfert') { $reflabel .= dol_string_nohtmltag($langs->transnoentitiesnoconv('TransitionalAccount').' '.$account_transfer); } else { $reflabel .= dol_string_nohtmltag($val['soclib']); @@ -683,8 +687,7 @@ if (!$error && $action == 'writebookkeeping') { $accountingaccount->fetch(null, $k, true); $bookkeeping->label_compte = $accountingaccount->label; } else { - if ($tabtype[$key] == 'unknown') // Unknown transaction, we will use a waiting account for thirdparty. - { + if ($tabtype[$key] == 'unknown') { // Unknown transaction, we will use a waiting account for thirdparty. // Temporary account $bookkeeping->subledger_account = ''; $bookkeeping->subledger_label = ''; @@ -702,8 +705,7 @@ if (!$error && $action == 'writebookkeeping') { $result = $bookkeeping->create($user); if ($result < 0) { - if ($bookkeeping->error == 'BookkeepingRecordAlreadyExists') // Already exists - { + if ($bookkeeping->error == 'BookkeepingRecordAlreadyExists') { // Already exists $error++; $errorforline++; setEventMessages('Transaction for ('.$bookkeeping->doc_type.', '.$bookkeeping->fk_doc.', '.$bookkeeping->fk_docdet.') were already recorded', null, 'warnings'); @@ -717,10 +719,11 @@ if (!$error && $action == 'writebookkeeping') { } } else { // If thirdparty unknown, output the waiting account foreach ($tabbq[$key] as $k => $mt) { - if ($mt) - { + if ($mt) { $reflabel = ''; - if (!empty($val['lib'])) $reflabel .= dol_string_nohtmltag($val['lib'])." - "; + if (!empty($val['lib'])) { + $reflabel .= dol_string_nohtmltag($val['lib'])." - "; + } $reflabel .= dol_string_nohtmltag('WaitingAccount'); $bookkeeping = new BookKeeping($db); @@ -747,8 +750,7 @@ if (!$error && $action == 'writebookkeeping') { $result = $bookkeeping->create($user); if ($result < 0) { - if ($bookkeeping->error == 'BookkeepingRecordAlreadyExists') // Already exists - { + if ($bookkeeping->error == 'BookkeepingRecordAlreadyExists') { // Already exists $error++; $errorforline++; setEventMessages('Transaction for ('.$bookkeeping->doc_type.', '.$bookkeeping->fk_doc.', '.$bookkeeping->fk_docdet.') were already recorded', null, 'warnings'); @@ -763,23 +765,20 @@ if (!$error && $action == 'writebookkeeping') { } } - if (price2num($totaldebit, 'MT') != price2num($totalcredit, 'MT')) - { + if (price2num($totaldebit, 'MT') != price2num($totalcredit, 'MT')) { $error++; $errorforline++; setEventMessages('Try to insert a non balanced transaction in book for '.$ref.'. Canceled. Surely a bug.', null, 'errors'); } - if (!$errorforline) - { + if (!$errorforline) { $db->commit(); } else { //print 'KO for line '.$key.' '.$error.'
'; $db->rollback(); $MAXNBERRORS = 5; - if ($error >= $MAXNBERRORS) - { + if ($error >= $MAXNBERRORS) { setEventMessages($langs->trans("ErrorTooManyErrorsProcessStopped").' (>'.$MAXNBERRORS.')', null, 'errors'); break; // Break in the foreach } @@ -788,8 +787,7 @@ if (!$error && $action == 'writebookkeeping') { if (empty($error) && count($tabpay) > 0) { setEventMessages($langs->trans("GeneralLedgerIsWritten"), null, 'mesgs'); - } elseif (count($tabpay) == $error) - { + } elseif (count($tabpay) == $error) { setEventMessages($langs->trans("NoNewRecordSaved"), null, 'warnings'); } else { setEventMessages($langs->trans("GeneralLedgerSomeRecordWasNotRecorded"), null, 'warnings'); @@ -798,8 +796,7 @@ if (!$error && $action == 'writebookkeeping') { $action = ''; // Must reload data, so we make a redirect - if (count($tabpay) != $error) - { + if (count($tabpay) != $error) { $param = 'id_journal='.$id_journal; $param .= '&date_startday='.$date_startday; $param .= '&date_startmonth='.$date_startmonth; @@ -837,20 +834,22 @@ if ($action == 'exportcsv') { // ISO and not UTF8 ! print '"'.$langs->transnoentitiesnoconv("Note").'"'.$sep; print "\n"; - foreach ($tabpay as $key => $val) - { + foreach ($tabpay as $key => $val) { $date = dol_print_date($db->jdate($val["date"]), 'day'); $ref = getSourceDocRef($val, $tabtype[$key]); // Bank foreach ($tabbq[$key] as $k => $mt) { - if ($mt) - { + if ($mt) { $reflabel = ''; - if (!empty($val['lib'])) $reflabel .= dol_string_nohtmltag($val['lib'])." - "; + if (!empty($val['lib'])) { + $reflabel .= dol_string_nohtmltag($val['lib'])." - "; + } $reflabel .= $langs->trans("Bank").' '.dol_string_nohtmltag($val['bank_account_ref']); - if (!empty($val['soclib'])) $reflabel .= " - ".dol_string_nohtmltag($val['soclib']); + if (!empty($val['soclib'])) { + $reflabel .= " - ".dol_string_nohtmltag($val['soclib']); + } print '"'.$key.'"'.$sep; print '"'.$date.'"'.$sep; @@ -870,12 +869,12 @@ if ($action == 'exportcsv') { // ISO and not UTF8 ! // Third party if (is_array($tabtp[$key])) { foreach ($tabtp[$key] as $k => $mt) { - if ($mt) - { + if ($mt) { $reflabel = ''; - if (!empty($val['lib'])) $reflabel .= dol_string_nohtmltag($val['lib']).($val['soclib'] ? " - " : ""); - if ($tabtype[$key] == 'banktransfert') - { + if (!empty($val['lib'])) { + $reflabel .= dol_string_nohtmltag($val['lib']).($val['soclib'] ? " - " : ""); + } + if ($tabtype[$key] == 'banktransfert') { $reflabel .= dol_string_nohtmltag($langs->transnoentitiesnoconv('TransitionalAccount').' '.$account_transfer); } else { $reflabel .= dol_string_nohtmltag($val['soclib']); @@ -907,10 +906,11 @@ if ($action == 'exportcsv') { // ISO and not UTF8 ! } } else { // If thirdparty unkown, output the waiting account foreach ($tabbq[$key] as $k => $mt) { - if ($mt) - { + if ($mt) { $reflabel = ''; - if (!empty($val['lib'])) $reflabel .= dol_string_nohtmltag($val['lib'])." - "; + if (!empty($val['lib'])) { + $reflabel .= dol_string_nohtmltag($val['lib'])." - "; + } $reflabel .= dol_string_nohtmltag('WaitingAccount'); print '"'.$key.'"'.$sep; @@ -967,16 +967,18 @@ if (empty($action) || $action == 'view') { // Test that setup is complete (we are in accounting, so test on entity is always on $conf->entity only, no sharing allowed) $sql = 'SELECT COUNT(rowid) as nb FROM '.MAIN_DB_PREFIX.'bank_account WHERE entity = '.$conf->entity.' AND fk_accountancy_journal IS NULL AND clos=0'; $resql = $db->query($sql); - if ($resql) - { + if ($resql) { $obj = $db->fetch_object($resql); - if ($obj->nb > 0) - { + if ($obj->nb > 0) { print '
'.img_warning().' '.$langs->trans("TheJournalCodeIsNotDefinedOnSomeBankAccount"); - print ' : '.$langs->trans("AccountancyAreaDescBank", 9, ''.$langs->transnoentitiesnoconv("MenuAccountancy").'-'.$langs->transnoentitiesnoconv("Setup")."-".$langs->transnoentitiesnoconv("BankAccounts").''); + $desc = ' : '.$langs->trans("AccountancyAreaDescBank", 9, '{link}'); + $desc = str_replace('{link}', ''.$langs->transnoentitiesnoconv("MenuAccountancy").'-'.$langs->transnoentitiesnoconv("Setup")."-".$langs->transnoentitiesnoconv("BankAccounts").'', $desc); + print $desc; print '
'; } - } else dol_print_error($db); + } else { + dol_print_error($db); + } // Button to write into Ledger @@ -990,14 +992,19 @@ if (empty($action) || $action == 'view') { print '
'; - if (!empty($conf->global->ACCOUNTING_ENABLE_EXPORT_DRAFT_JOURNAL) && $in_bookkeeping == 'notyet') print ''; + if (!empty($conf->global->ACCOUNTING_ENABLE_EXPORT_DRAFT_JOURNAL) && $in_bookkeeping == 'notyet') { + print ''; + } if (($conf->global->ACCOUNTING_ACCOUNT_CUSTOMER == "") || $conf->global->ACCOUNTING_ACCOUNT_CUSTOMER == '-1' || ($conf->global->ACCOUNTING_ACCOUNT_SUPPLIER == "") || $conf->global->ACCOUNTING_ACCOUNT_SUPPLIER == '-1') { print ''; } else { - if ($in_bookkeeping == 'notyet') print ''; - else print ''.$langs->trans("WriteBookKeeping").''; + if ($in_bookkeeping == 'notyet') { + print ''; + } else { + print ''.$langs->trans("WriteBookKeeping").''; + } } print '
'; @@ -1040,21 +1047,22 @@ if (empty($action) || $action == 'view') { $r = ''; - foreach ($tabpay as $key => $val) // $key is rowid in llx_bank - { + foreach ($tabpay as $key => $val) { // $key is rowid in llx_bank $date = dol_print_date($db->jdate($val["date"]), 'day'); $ref = getSourceDocRef($val, $tabtype[$key]); // Bank - foreach ($tabbq[$key] as $k => $mt) - { - if ($mt) - { + foreach ($tabbq[$key] as $k => $mt) { + if ($mt) { $reflabel = ''; - if (!empty($val['lib'])) $reflabel .= $val['lib']." - "; + if (!empty($val['lib'])) { + $reflabel .= $val['lib']." - "; + } $reflabel .= $langs->trans("Bank").' '.$val['bank_account_ref']; - if (!empty($val['soclib'])) $reflabel .= " - ".$val['soclib']; + if (!empty($val['soclib'])) { + $reflabel .= " - ".$val['soclib']; + } //var_dump($tabpay[$key]); print ''; @@ -1064,10 +1072,11 @@ if (empty($action) || $action == 'view') { // Ledger account print ""; $accounttoshow = length_accountg($k); - if (empty($accounttoshow) || $accounttoshow == 'NotDefined') - { + if (empty($accounttoshow) || $accounttoshow == 'NotDefined') { print ''.$langs->trans("BankAccountNotDefined").''; - } else print $accounttoshow; + } else { + print $accounttoshow; + } print ""; // Subledger account print ""; @@ -1091,12 +1100,12 @@ if (empty($action) || $action == 'view') { // Third party if (is_array($tabtp[$key])) { foreach ($tabtp[$key] as $k => $mt) { - if ($mt) - { + if ($mt) { $reflabel = ''; - if (!empty($val['lib'])) $reflabel .= $val['lib'].($val['soclib'] ? " - " : ""); - if ($tabtype[$key] == 'banktransfert') - { + if (!empty($val['lib'])) { + $reflabel .= $val['lib'].($val['soclib'] ? " - " : ""); + } + if ($tabtype[$key] == 'banktransfert') { $reflabel .= $langs->trans('TransitionalAccount').' '.$account_transfer; } else { $reflabel .= $val['soclib']; @@ -1110,21 +1119,32 @@ if (empty($action) || $action == 'view') { print ""; $account_ledger = $k; // Try to force general ledger account depending on type - if ($tabtype[$key] == 'payment') $account_ledger = $conf->global->ACCOUNTING_ACCOUNT_CUSTOMER; - if ($tabtype[$key] == 'payment_supplier') $account_ledger = $conf->global->ACCOUNTING_ACCOUNT_SUPPLIER; - if ($tabtype[$key] == 'payment_expensereport') $account_ledger = $conf->global->SALARIES_ACCOUNTING_ACCOUNT_PAYMENT; - if ($tabtype[$key] == 'payment_salary') $account_ledger = $conf->global->SALARIES_ACCOUNTING_ACCOUNT_PAYMENT; - if ($tabtype[$key] == 'payment_vat') $account_ledger = $conf->global->ACCOUNTING_VAT_PAY_ACCOUNT; - if ($tabtype[$key] == 'member') $account_ledger = $conf->global->ADHERENT_SUBSCRIPTION_ACCOUNTINGACCOUNT; - if ($tabtype[$key] == 'payment_various') $account_ledger = $tabpay[$key]["account_various"]; + if ($tabtype[$key] == 'payment') { + $account_ledger = $conf->global->ACCOUNTING_ACCOUNT_CUSTOMER; + } + if ($tabtype[$key] == 'payment_supplier') { + $account_ledger = $conf->global->ACCOUNTING_ACCOUNT_SUPPLIER; + } + if ($tabtype[$key] == 'payment_expensereport') { + $account_ledger = $conf->global->SALARIES_ACCOUNTING_ACCOUNT_PAYMENT; + } + if ($tabtype[$key] == 'payment_salary') { + $account_ledger = $conf->global->SALARIES_ACCOUNTING_ACCOUNT_PAYMENT; + } + if ($tabtype[$key] == 'payment_vat') { + $account_ledger = $conf->global->ACCOUNTING_VAT_PAY_ACCOUNT; + } + if ($tabtype[$key] == 'member') { + $account_ledger = $conf->global->ADHERENT_SUBSCRIPTION_ACCOUNTINGACCOUNT; + } + if ($tabtype[$key] == 'payment_various') { + $account_ledger = $tabpay[$key]["account_various"]; + } $accounttoshow = length_accountg($account_ledger); - if (empty($accounttoshow) || $accounttoshow == 'NotDefined') - { - if ($tabtype[$key] == 'unknown') - { + if (empty($accounttoshow) || $accounttoshow == 'NotDefined') { + if ($tabtype[$key] == 'unknown') { // We will accept writing, but into a waiting account - if (empty($conf->global->ACCOUNTING_ACCOUNT_SUSPENSE) || $conf->global->ACCOUNTING_ACCOUNT_SUSPENSE == '-1') - { + if (empty($conf->global->ACCOUNTING_ACCOUNT_SUSPENSE) || $conf->global->ACCOUNTING_ACCOUNT_SUSPENSE == '-1') { print ''.$langs->trans('UnknownAccountForThirdpartyAndWaitingAccountNotDefinedBlocking').''; } else { print ''.$langs->trans('UnknownAccountForThirdparty', length_accountg($conf->global->ACCOUNTING_ACCOUNT_SUSPENSE)).''; // We will use a waiting account @@ -1132,32 +1152,42 @@ if (empty($action) || $action == 'view') { } else { // We will refuse writing $errorstring = 'UnknownAccountForThirdpartyBlocking'; - if ($tabtype[$key] == 'payment') $errorstring = 'MainAccountForCustomersNotDefined'; - if ($tabtype[$key] == 'payment_supplier') $errorstring = 'MainAccountForSuppliersNotDefined'; - if ($tabtype[$key] == 'payment_expensereport') $errorstring = 'MainAccountForUsersNotDefined'; - if ($tabtype[$key] == 'payment_salary') $errorstring = 'MainAccountForUsersNotDefined'; - if ($tabtype[$key] == 'payment_vat') $errorstring = 'MainAccountForVatPaymentNotDefined'; - if ($tabtype[$key] == 'member') $errorstring = 'MainAccountForSubscriptionPaymentNotDefined'; + if ($tabtype[$key] == 'payment') { + $errorstring = 'MainAccountForCustomersNotDefined'; + } + if ($tabtype[$key] == 'payment_supplier') { + $errorstring = 'MainAccountForSuppliersNotDefined'; + } + if ($tabtype[$key] == 'payment_expensereport') { + $errorstring = 'MainAccountForUsersNotDefined'; + } + if ($tabtype[$key] == 'payment_salary') { + $errorstring = 'MainAccountForUsersNotDefined'; + } + if ($tabtype[$key] == 'payment_vat') { + $errorstring = 'MainAccountForVatPaymentNotDefined'; + } + if ($tabtype[$key] == 'member') { + $errorstring = 'MainAccountForSubscriptionPaymentNotDefined'; + } print ''.$langs->trans($errorstring).''; } - } else print $accounttoshow; + } else { + print $accounttoshow; + } print ""; // Subledger account print ""; - if (in_array($tabtype[$key], array('payment', 'payment_supplier', 'payment_expensereport', 'payment_salary', 'payment_various'))) // Type of payment with subledger - { + if (in_array($tabtype[$key], array('payment', 'payment_supplier', 'payment_expensereport', 'payment_salary', 'payment_various'))) { // Type of payment with subledger $accounttoshowsubledger = length_accounta($k); - if ($accounttoshow != $accounttoshowsubledger) - { - if (empty($accounttoshowsubledger) || $accounttoshowsubledger == 'NotDefined') - { + if ($accounttoshow != $accounttoshowsubledger) { + if (empty($accounttoshowsubledger) || $accounttoshowsubledger == 'NotDefined') { /*var_dump($tabpay[$key]); var_dump($tabtype[$key]); var_dump($tabbq[$key]);*/ //print ''.$langs->trans("ThirdpartyAccountNotDefined").''; - if (!empty($tabcompany[$key]['code_compta'])) - { + if (!empty($tabcompany[$key]['code_compta'])) { if (in_array($tabtype[$key], array('payment_various'))) { // For such case, if subledger is not defined, we won't use subledger accounts. print ''.$langs->trans("ThirdpartyAccountNotDefinedOrThirdPartyUnknownSubledgerIgnored").''; @@ -1167,7 +1197,9 @@ if (empty($action) || $action == 'view') { } else { print ''.$langs->trans("ThirdpartyAccountNotDefinedOrThirdPartyUnknownBlocking").''; } - } else print $accounttoshowsubledger; + } else { + print $accounttoshowsubledger; + } } } print ""; @@ -1180,10 +1212,11 @@ if (empty($action) || $action == 'view') { } } else { // Waiting account foreach ($tabbq[$key] as $k => $mt) { - if ($mt) - { + if ($mt) { $reflabel = ''; - if (!empty($val['lib'])) $reflabel .= $val['lib']." - "; + if (!empty($val['lib'])) { + $reflabel .= $val['lib']." - "; + } $reflabel .= 'WaitingAccount'; print ''; @@ -1267,78 +1300,67 @@ function getSourceDocRef($val, $typerecord) } $sqlmid = ''; - if ($typerecord == 'payment') - { + if ($typerecord == 'payment') { $sqlmid = 'SELECT payfac.fk_facture as id, f.ref as ref'; $sqlmid .= " FROM ".MAIN_DB_PREFIX."paiement_facture as payfac, ".MAIN_DB_PREFIX."facture as f"; $sqlmid .= " WHERE payfac.fk_facture = f.rowid AND payfac.fk_paiement=".$val["paymentid"]; $ref = $langs->transnoentitiesnoconv("Invoice"); - } elseif ($typerecord == 'payment_supplier') - { + } elseif ($typerecord == 'payment_supplier') { $sqlmid = 'SELECT payfac.fk_facturefourn as id, f.ref'; $sqlmid .= " FROM ".MAIN_DB_PREFIX."paiementfourn_facturefourn as payfac, ".MAIN_DB_PREFIX."facture_fourn as f"; $sqlmid .= " WHERE payfac.fk_facturefourn = f.rowid AND payfac.fk_paiementfourn=".$val["paymentsupplierid"]; $ref = $langs->transnoentitiesnoconv("SupplierInvoice"); - } elseif ($typerecord == 'payment_expensereport') - { + } elseif ($typerecord == 'payment_expensereport') { $sqlmid = 'SELECT e.rowid as id, e.ref'; $sqlmid .= " FROM ".MAIN_DB_PREFIX."payment_expensereport as pe, ".MAIN_DB_PREFIX."expensereport as e"; $sqlmid .= " WHERE pe.rowid=".$val["paymentexpensereport"]." AND pe.fk_expensereport = e.rowid"; $ref = $langs->transnoentitiesnoconv("ExpenseReport"); - } elseif ($typerecord == 'payment_salary') - { + } elseif ($typerecord == 'payment_salary') { $sqlmid = 'SELECT s.rowid as ref'; $sqlmid .= " FROM ".MAIN_DB_PREFIX."payment_salary as s"; $sqlmid .= " WHERE s.rowid=".$val["paymentsalid"]; $ref = $langs->transnoentitiesnoconv("SalaryPayment"); - } elseif ($typerecord == 'sc') - { + } elseif ($typerecord == 'sc') { $sqlmid = 'SELECT sc.rowid as ref'; $sqlmid .= " FROM ".MAIN_DB_PREFIX."paiementcharge as sc"; $sqlmid .= " WHERE sc.rowid=".$val["paymentscid"]; $ref = $langs->transnoentitiesnoconv("SocialContribution"); - } elseif ($typerecord == 'payment_vat') - { + } elseif ($typerecord == 'payment_vat') { $sqlmid = 'SELECT v.rowid as ref'; $sqlmid .= " FROM ".MAIN_DB_PREFIX."tva as v"; $sqlmid .= " WHERE v.rowid=".$val["paymentvatid"]; $ref = $langs->transnoentitiesnoconv("PaymentVat"); - } elseif ($typerecord == 'payment_donation') - { + } elseif ($typerecord == 'payment_donation') { $sqlmid = 'SELECT payd.fk_donation as ref'; $sqlmid .= " FROM ".MAIN_DB_PREFIX."payment_donation as payd"; $sqlmid .= " WHERE payd.fk_donation=".$val["paymentdonationid"]; $ref = $langs->transnoentitiesnoconv("Donation"); - } elseif ($typerecord == 'payment_loan') - { + } elseif ($typerecord == 'payment_loan') { $sqlmid = 'SELECT l.rowid as ref'; $sqlmid .= " FROM ".MAIN_DB_PREFIX."payment_loan as l"; $sqlmid .= " WHERE l.rowid=".$val["paymentloanid"]; $ref = $langs->transnoentitiesnoconv("LoanPayment"); - } elseif ($typerecord == 'payment_various') - { + } elseif ($typerecord == 'payment_various') { $sqlmid = 'SELECT v.rowid as ref'; $sqlmid .= " FROM ".MAIN_DB_PREFIX."payment_various as v"; $sqlmid .= " WHERE v.rowid=".$val["paymentvariousid"]; $ref = $langs->transnoentitiesnoconv("VariousPayment"); } // Add warning - if (empty($sqlmid)) - { + if (empty($sqlmid)) { dol_syslog("Found a typerecord=".$typerecord." not supported", LOG_WARNING); } - if ($sqlmid) - { + if ($sqlmid) { dol_syslog("accountancy/journal/bankjournal.php::sqlmid=".$sqlmid, LOG_DEBUG); $resultmid = $db->query($sqlmid); - if ($resultmid) - { - while ($objmid = $db->fetch_object($resultmid)) - { + if ($resultmid) { + while ($objmid = $db->fetch_object($resultmid)) { $ref .= ' '.$objmid->ref; } - } else dol_print_error($db); + } else { + dol_print_error($db); + } } $ref = dol_trunc($langs->transnoentitiesnoconv("BankId").' '.$val['fk_bank'].' - '.$ref, 295); // 295 + 3 dots (...) is < than max size of 300 diff --git a/htdocs/admin/boxes.php b/htdocs/admin/boxes.php index 4fc1ad28da7..63c3350fd9d 100644 --- a/htdocs/admin/boxes.php +++ b/htdocs/admin/boxes.php @@ -31,7 +31,9 @@ include_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php'; // Load translation files required by the page $langs->loadLangs(array('admin', 'boxes', 'accountancy')); -if (!$user->admin) accessforbidden(); +if (!$user->admin) { + accessforbidden(); +} $rowid = GETPOST('rowid', 'int'); $action = GETPOST('action', 'aZ09'); @@ -46,8 +48,7 @@ $boxes = array(); * Actions */ -if ($action == 'addconst') -{ +if ($action == 'addconst') { dolibarr_set_const($db, "MAIN_BOXES_MAXLINES", $_POST["MAIN_BOXES_MAXLINES"], '', 0, '', $conf->entity); dolibarr_set_const($db, "MAIN_ACTIVATE_FILECACHE", $_POST["MAIN_ACTIVATE_FILECACHE"], 'chaine', 0, '', $conf->entity); } @@ -59,8 +60,7 @@ if ($action == 'add') { $db->begin(); if (is_array($boxids)) { foreach ($boxids as $boxid) { - if (is_numeric($boxid['pos']) && $boxid['pos'] >= 0) // 0=Home, 1=... - { + if (is_numeric($boxid['pos']) && $boxid['pos'] >= 0) { // 0=Home, 1=... $pos = $boxid['pos']; // Initialize distinct fk_user with all already existing values of fk_user (user that use a personalized view of boxes for page "pos") @@ -72,12 +72,10 @@ if ($action == 'add') { $sql .= " AND entity = ".$conf->entity; dol_syslog("boxes.php search fk_user to activate box for", LOG_DEBUG); $resql = $db->query($sql); - if ($resql) - { + if ($resql) { $num = $db->num_rows($resql); $i = 0; - while ($i < $num) - { + while ($i < $num) { $obj = $db->fetch_object($resql); $distinctfkuser[$obj->fk_user] = $obj->fk_user; $i++; @@ -90,26 +88,28 @@ if ($action == 'add') { $distinctfkuser['0'] = '0'; // Add entry for fk_user = 0. We must use string as key and val - foreach ($distinctfkuser as $fk_user) - { - if (!$error && $fk_user != '') - { + foreach ($distinctfkuser as $fk_user) { + if (!$error && $fk_user != '') { $arrayofexistingboxid = array(); $nbboxonleft = $nbboxonright = 0; $sql = "SELECT box_id, box_order FROM ".MAIN_DB_PREFIX."boxes"; $sql .= " WHERE position = ".$pos." AND fk_user = ".$fk_user." AND entity = ".$conf->entity; dol_syslog("boxes.php activate box", LOG_DEBUG); $resql = $db->query($sql); - if ($resql) - { - while ($obj = $db->fetch_object($resql)) - { + if ($resql) { + while ($obj = $db->fetch_object($resql)) { $boxorder = $obj->box_order; - if (preg_match('/A/', $boxorder)) $nbboxonleft++; - if (preg_match('/B/', $boxorder)) $nbboxonright++; + if (preg_match('/A/', $boxorder)) { + $nbboxonleft++; + } + if (preg_match('/B/', $boxorder)) { + $nbboxonright++; + } $arrayofexistingboxid[$obj->box_id] = 1; } - } else dol_print_error($db); + } else { + dol_print_error($db); + } if (empty($arrayofexistingboxid[$boxid['value']])) { $sql = "INSERT INTO ".MAIN_DB_PREFIX."boxes ("; @@ -120,8 +120,7 @@ if ($action == 'add') { dol_syslog("boxes.php activate box", LOG_DEBUG); $resql = $db->query($sql); - if (!$resql) - { + if (!$resql) { setEventMessages($db->lasterror(), null, 'errors'); $error++; } @@ -133,8 +132,7 @@ if ($action == 'add') { } } } - if (!$error) - { + if (!$error) { $db->commit(); $action = ''; } else { @@ -142,15 +140,13 @@ if ($action == 'add') { } } -if ($action == 'delete') -{ +if ($action == 'delete') { $sql = "SELECT box_id FROM ".MAIN_DB_PREFIX."boxes"; $sql .= " WHERE rowid=".((int) $rowid); $resql = $db->query($sql); $obj = $db->fetch_object($resql); - if (!empty($obj->box_id)) - { + if (!empty($obj->box_id)) { $db->begin(); // Remove all personalized setup when a box is activated or disabled (why removing all ? We removed only removed boxes) @@ -168,8 +164,7 @@ if ($action == 'delete') } } -if ($action == 'switch') -{ +if ($action == 'switch') { // We switch values of field box_order for the 2 lines of table boxes $db->begin(); @@ -181,12 +176,10 @@ if ($action == 'switch') $resultupdatefrom = 0; $resultupdateto = 0; - if (is_object($objfrom) && is_object($objto)) - { + if (is_object($objfrom) && is_object($objto)) { $newfirst = $objto->box_order; $newsecond = $objfrom->box_order; - if ($newfirst == $newsecond) - { + if ($newfirst == $newsecond) { $newsecondchar = preg_replace('/[0-9]+/', '', $newsecond); $newsecondnum = preg_replace('/[a-zA-Z]+/', '', $newsecond); $newsecond = sprintf("%s%02d", $newsecondchar ? $newsecondchar : 'A', $newsecondnum + 1); @@ -194,16 +187,19 @@ if ($action == 'switch') $sql = "UPDATE ".MAIN_DB_PREFIX."boxes SET box_order='".$db->escape($newfirst)."' WHERE rowid=".((int) $objfrom->rowid); dol_syslog($sql); $resultupdatefrom = $db->query($sql); - if (!$resultupdatefrom) { dol_print_error($db); } + if (!$resultupdatefrom) { + dol_print_error($db); + } $sql = "UPDATE ".MAIN_DB_PREFIX."boxes SET box_order='".$db->escape($newsecond)."' WHERE rowid=".((int) $objto->rowid); dol_syslog($sql); $resultupdateto = $db->query($sql); - if (!$resultupdateto) { dol_print_error($db); } + if (!$resultupdateto) { + dol_print_error($db); + } } - if ($resultupdatefrom && $resultupdateto) - { + if ($resultupdatefrom && $resultupdateto) { $db->commit(); } else { $db->rollback(); @@ -240,33 +236,31 @@ $sql .= " ORDER by b.position, b.box_order"; dol_syslog("Search available boxes", LOG_DEBUG); $resql = $db->query($sql); -if ($resql) -{ +if ($resql) { $num = $db->num_rows($resql); // Check record to know if we must recalculate sort order $i = 0; $decalage = 0; - while ($i < $num) - { + while ($i < $num) { $obj = $db->fetch_object($resql); $boxes[$obj->position][$obj->box_id] = 1; $i++; array_push($actives, $obj->box_id); - if ($obj->box_order == '' || $obj->box_order == '0' || $decalage) $decalage++; + if ($obj->box_order == '' || $obj->box_order == '0' || $decalage) { + $decalage++; + } // We renumber the order of the boxes if one of them is in '' // This occurs just after an insert. - if ($decalage) - { + if ($decalage) { $sql = "UPDATE ".MAIN_DB_PREFIX."boxes SET box_order='".$db->escape($decalage)."' WHERE rowid=".$obj->rowid; $db->query($sql); } } - if ($decalage) - { + if ($decalage) { // If we have renumbered, we correct the field box_order // This occurs just after an insert. $sql = "SELECT box_order"; @@ -276,32 +270,24 @@ if ($resql) dol_syslog("Execute requests to renumber box order", LOG_DEBUG); $result = $db->query($sql); - if ($result) - { - while ($record = $db->fetch_array($result)) - { - if (dol_strlen($record['box_order']) == 1) - { - if (preg_match("/[13579]{1}/", substr($record['box_order'], -1))) - { + if ($result) { + while ($record = $db->fetch_array($result)) { + if (dol_strlen($record['box_order']) == 1) { + if (preg_match("/[13579]{1}/", substr($record['box_order'], -1))) { $box_order = "A0".$record['box_order']; $sql = "UPDATE ".MAIN_DB_PREFIX."boxes SET box_order = '".$db->escape($box_order)."' WHERE entity = ".$conf->entity." AND box_order = '".$db->escape($record['box_order'])."'"; $resql = $db->query($sql); - } elseif (preg_match("/[02468]{1}/", substr($record['box_order'], -1))) - { + } elseif (preg_match("/[02468]{1}/", substr($record['box_order'], -1))) { $box_order = "B0".$record['box_order']; $sql = "UPDATE ".MAIN_DB_PREFIX."boxes SET box_order = '".$db->escape($box_order)."' WHERE entity = ".$conf->entity." AND box_order = '".$db->escape($record['box_order'])."'"; $resql = $db->query($sql); } - } elseif (dol_strlen($record['box_order']) == 2) - { - if (preg_match("/[13579]{1}/", substr($record['box_order'], -1))) - { + } elseif (dol_strlen($record['box_order']) == 2) { + if (preg_match("/[13579]{1}/", substr($record['box_order'], -1))) { $box_order = "A".$record['box_order']; $sql = "UPDATE ".MAIN_DB_PREFIX."boxes SET box_order = '".$db->escape($box_order)."' WHERE entity = ".$conf->entity." AND box_order = '".$db->escape($record['box_order'])."'"; $resql = $db->query($sql); - } elseif (preg_match("/[02468]{1}/", substr($record['box_order'], -1))) - { + } elseif (preg_match("/[02468]{1}/", substr($record['box_order'], -1))) { $box_order = "B".$record['box_order']; $sql = "UPDATE ".MAIN_DB_PREFIX."boxes SET box_order = '".$db->escape($box_order)."' WHERE entity = ".$conf->entity." AND box_order = '".$db->escape($record['box_order'])."'"; $resql = $db->query($sql); @@ -336,10 +322,8 @@ print ''.$langs->trans("SourceFile").''; print ''.$langs->trans("ActivateOn").''; print "\n"; -foreach ($boxtoadd as $box) -{ - if (preg_match('/^([^@]+)@([^@]+)$/i', $box->boximg)) - { +foreach ($boxtoadd as $box) { + if (preg_match('/^([^@]+)@([^@]+)$/i', $box->boximg)) { $logo = $box->boximg; } else { $logo = preg_replace("/^object_/i", "", $box->boximg); @@ -348,14 +332,17 @@ foreach ($boxtoadd as $box) print "\n".''."\n"; print ''."\n"; print ''.img_object("", $logo, 'height="14px"').' '.$langs->transnoentitiesnoconv($box->boxlabel); - if (!empty($box->class) && preg_match('/graph_/', $box->class)) print ' ('.$langs->trans("Graph").')'; + if (!empty($box->class) && preg_match('/graph_/', $box->class)) { + print ' ('.$langs->trans("Graph").')'; + } print ''."\n"; print ''; - if ($box->note == '(WarningUsingThisBoxSlowDown)') - { + if ($box->note == '(WarningUsingThisBoxSlowDown)') { $langs->load("errors"); print $langs->trans("WarningUsingThisBoxSlowDown"); - } else print ($box->note ? $box->note : ' '); + } else { + print ($box->note ? $box->note : ' '); + } print ''."\n"; print ''.$box->sourcefile.''."\n"; @@ -367,8 +354,7 @@ foreach ($boxtoadd as $box) print ''."\n"; } -if (!count($boxtoadd) && count($boxactivated)) -{ +if (!count($boxtoadd) && count($boxactivated)) { print ''.$langs->trans("AllWidgetsWereEnabled").''; } print ''."\n"; @@ -398,10 +384,8 @@ print ''."\n"; $box_order = 1; $foundrupture = 1; -foreach ($boxactivated as $key => $box) -{ - if (preg_match('/^([^@]+)@([^@]+)$/i', $box->boximg)) - { +foreach ($boxactivated as $key => $box) { + if (preg_match('/^([^@]+)@([^@]+)$/i', $box->boximg)) { $logo = $box->boximg; } else { $logo = preg_replace("/^object_/i", "", $box->boximg); @@ -410,14 +394,17 @@ foreach ($boxactivated as $key => $box) print "\n".''."\n"; print ''; print ''.img_object("", $logo, 'height="14px"').' '.$langs->transnoentitiesnoconv($box->boxlabel); - if (!empty($box->class) && preg_match('/graph_/', $box->class)) print ' ('.$langs->trans("Graph").')'; + if (!empty($box->class) && preg_match('/graph_/', $box->class)) { + print ' ('.$langs->trans("Graph").')'; + } print ''; print ''; - if ($box->note == '(WarningUsingThisBoxSlowDown)') - { + if ($box->note == '(WarningUsingThisBoxSlowDown)') { $langs->load("errors"); print img_warning('', 0).' '.$langs->trans("WarningUsingThisBoxSlowDown"); - } else print ($box->note ? $box->note : ' '); + } else { + print ($box->note ? $box->note : ' '); + } print ''; print ''.(empty($pos_name[$box->position]) ? '' : $langs->trans($pos_name[$box->position])).''; $hasnext = ($key < (count($boxactivated) - 1)); @@ -446,6 +433,7 @@ print load_fiche_titre($langs->trans("Other"), '', ''); print '
'; print ''; print ''; +print '
'; print ''; print ''; @@ -471,6 +459,7 @@ if ($conf->global->MAIN_FEATURES_LEVEL == 2 || !empty($conf->global->MAIN_ACTIVA } print '
'; +print '
'; print '
'; print '
'; diff --git a/htdocs/admin/limits.php b/htdocs/admin/limits.php index 43c4cc84776..34da6f7d34e 100644 --- a/htdocs/admin/limits.php +++ b/htdocs/admin/limits.php @@ -100,9 +100,12 @@ if ($action == 'update') $form = new Form($db); -llxHeader(); +$title = $langs->trans("LimitsSetup"); +$help_url = ''; -print load_fiche_titre($langs->trans("LimitsSetup"), '', 'title_setup'); +llxHeader('', $title, $help_url); + +print load_fiche_titre($title, '', 'title_setup'); $aCurrencies = array($conf->currency); // Default currency always first position @@ -125,7 +128,8 @@ if (!empty($conf->multicurrency->enabled) && !empty($conf->global->MULTICURRENCY if (!empty($aCurrencies) && count($aCurrencies) > 1) { $head = multicurrencyLimitPrepareHead($aCurrencies); - print dol_get_fiche_head($head, $currencycode, '', -1, "multicurrency"); + + print dol_get_fiche_head($head, $currencycode, '', -1, ''); } } @@ -172,6 +176,7 @@ if ($action == 'edit') print '
'; print '
'; } else { + print '
'; print ''; print ''; @@ -191,6 +196,7 @@ if ($action == 'edit') print ''; print '
'.$langs->trans("Parameter").''.$langs->trans("Value").'
'.(isset($conf->global->$mainroundingruletot) ? $conf->global->$mainroundingruletot : $conf->global->MAIN_ROUNDING_RULE_TOT).'
'; + print '
'; print '
'; print ''.$langs->trans("Modify").''; diff --git a/htdocs/admin/mails_templates.php b/htdocs/admin/mails_templates.php index de98c42b35a..6538d5c3011 100644 --- a/htdocs/admin/mails_templates.php +++ b/htdocs/admin/mails_templates.php @@ -1074,7 +1074,7 @@ function fieldList($fieldlist, $obj = '', $tabname = '', $context = '') print ''; if ($context == 'edit' && !empty($obj->{$fieldlist[$field]}) && !in_array($obj->{$fieldlist[$field]}, array_keys($elementList))) { - // Current tempalte type is an unknown type, so we must keep it as it is. + // Current template type is an unknown type, so we must keep it as it is. print ''; print $obj->{$fieldlist[$field]}; } else { diff --git a/htdocs/admin/sms.php b/htdocs/admin/sms.php index 823d4804121..fd1bcb69bdb 100644 --- a/htdocs/admin/sms.php +++ b/htdocs/admin/sms.php @@ -2,6 +2,7 @@ /* Copyright (C) 2007-2011 Laurent Destailleur * Copyright (C) 2009 Regis Houssin * Copyright (C) 2013 Juanjo Menent + * Copyright (C) 2020 Frédéric France * * 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,15 +31,16 @@ $langs->loadLangs(array("companies", "admin", "products", "sms", "other", "error $cancel = GETPOST('cancel', 'alpha'); // We click on a Cancel button -if (!$user->admin) -accessforbidden(); +if (!$user->admin) { + accessforbidden(); +} $substitutionarrayfortest = array( -'__ID__' => 'TESTIdRecord', -'__PHONEFROM__' => 'TESTPhoneFrom', -'__PHONETO__' => 'TESTPhoneTo', -'__LASTNAME__' => 'TESTLastname', -'__FIRSTNAME__' => 'TESTFirstname' + '__ID__' => 'TESTIdRecord', + '__PHONEFROM__' => 'TESTPhoneFrom', + '__PHONETO__' => 'TESTPhoneTo', + '__LASTNAME__' => 'TESTLastname', + '__FIRSTNAME__' => 'TESTFirstname' ); $action = GETPOST('action', 'aZ09'); @@ -48,8 +50,7 @@ $action = GETPOST('action', 'aZ09'); * Actions */ -if ($action == 'update' && !$cancel) -{ +if ($action == 'update' && !$cancel) { dolibarr_set_const($db, "MAIN_DISABLE_ALL_SMS", GETPOST("MAIN_DISABLE_ALL_SMS", 'alphanohtml'), 'chaine', 0, '', $conf->entity); dolibarr_set_const($db, "MAIN_SMS_SENDMODE", GETPOST("MAIN_SMS_SENDMODE", 'alphanohtml'), 'chaine', 0, '', $conf->entity); @@ -64,13 +65,16 @@ if ($action == 'update' && !$cancel) /* * Send sms */ -if ($action == 'send' && !$_POST['cancel']) -{ +if ($action == 'send' && !$_POST['cancel']) { $error = 0; $smsfrom = ''; - if (!empty($_POST["fromsms"])) $smsfrom = GETPOST("fromsms", 'alphanohtml'); - if (empty($smsfrom)) $smsfrom = GETPOST("fromname", 'alphanohtml'); + if (!empty($_POST["fromsms"])) { + $smsfrom = GETPOST("fromsms", 'alphanohtml'); + } + if (empty($smsfrom)) { + $smsfrom = GETPOST("fromname", 'alphanohtml'); + } $sendto = GETPOST("sendto", 'alphanohtml'); $body = GETPOST('message', 'alphanohtml'); $deliveryreceipt = GETPOST("deliveryreceipt", 'alphanohtml'); @@ -83,32 +87,27 @@ if ($action == 'send' && !$_POST['cancel']) include_once DOL_DOCUMENT_ROOT.'/core/class/html.formsms.class.php'; $formsms = new FormSms($db); - if (!empty($formsms->error)) - { + if (!empty($formsms->error)) { setEventMessages($formsms->error, $formsms->errors, 'errors'); $action = 'test'; $error++; } - if (empty($body)) - { + if (empty($body)) { setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentities("Message")), null, 'errors'); $action = 'test'; $error++; } - if (empty($smsfrom) || !str_replace('+', '', $smsfrom)) - { + if (empty($smsfrom) || !str_replace('+', '', $smsfrom)) { setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentities("SmsFrom")), null, 'errors'); $action = 'test'; $error++; } - if (empty($sendto) || !str_replace('+', '', $sendto)) - { + if (empty($sendto) || !str_replace('+', '', $sendto)) { setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentities("SmsTo")), null, 'errors'); $action = 'test'; $error++; } - if (!$error) - { + if (!$error) { // Make substitutions into message complete_substitutions_array($substitutionarrayfortest, $langs); $body = make_substitutions($body, $substitutionarrayfortest); @@ -118,8 +117,7 @@ if ($action == 'send' && !$_POST['cancel']) $smsfile = new CSMSFile($sendto, $smsfrom, $body, $deliveryreceipt, $deferred, $priority, $class); // This define OvhSms->login, pass, session and account $result = $smsfile->sendfile(); // This send SMS - if ($result) - { + if ($result) { setEventMessages($langs->trans("SmsSuccessfulySent", $smsfrom, $sendto), null, 'mesgs'); setEventMessages($smsfile->error, $smsfile->errors, 'mesgs'); } else { @@ -138,8 +136,12 @@ if ($action == 'send' && !$_POST['cancel']) */ $linuxlike = 1; -if (preg_match('/^win/i', PHP_OS)) $linuxlike = 0; -if (preg_match('/^mac/i', PHP_OS)) $linuxlike = 0; +if (preg_match('/^win/i', PHP_OS)) { + $linuxlike = 0; +} +if (preg_match('/^mac/i', PHP_OS)) { + $linuxlike = 0; +} $wikihelp = 'EN:Setup Sms|FR:Paramétrage Sms|ES:Configuración Sms'; llxHeader('', $langs->trans("Setup"), $wikihelp); @@ -153,11 +155,14 @@ print "
\n"; $listofmethods = (is_array($conf->modules_parts['sms']) ? $conf->modules_parts['sms'] : array()); asort($listofmethods); -if ($action == 'edit') -{ - $form = new Form($db); +if (!count($listofmethods)) { + $descnosms = $langs->trans("NoSmsEngine", '{Dolistore}'); + $descnosms = str_replace('{Dolistore}', 'DoliStore', $descnosms); + print '
'.$descnosms.'
'; +} - if (!count($listofmethods)) print '
'.$langs->trans("NoSmsEngine", 'DoliStore').'
'; +if ($action == 'edit') { + $form = new Form($db); print '
'; print ''; @@ -178,8 +183,11 @@ if ($action == 'edit') // Method print ''.$langs->trans("MAIN_SMS_SENDMODE").''; - if (count($listofmethods)) print $form->selectarray('MAIN_SMS_SENDMODE', $listofmethods, $conf->global->MAIN_SMS_SENDMODE, 1); - else print ''.$langs->trans("None").''; + if (count($listofmethods)) { + print $form->selectarray('MAIN_SMS_SENDMODE', $listofmethods, $conf->global->MAIN_SMS_SENDMODE, 1); + } else { + print ''.$langs->trans("None").''; + } print ''; // From @@ -204,8 +212,6 @@ if ($action == 'edit') print '
'; print '
'; } else { - if (!count($listofmethods)) print '
'.$langs->trans("NoSmsEngine", 'DoliStore').'
'; - print ''; print ''; @@ -218,14 +224,18 @@ if ($action == 'edit') // Method print ''; // From print ''; print ''; // Autocopy to @@ -234,7 +244,7 @@ if ($action == 'edit') print ''; - */ + */ print '
'.$langs->trans("Parameter").''.$langs->trans("Value").'
'.$langs->trans("MAIN_SMS_SENDMODE").''; $text = $listofmethods[$conf->global->MAIN_SMS_SENDMODE]; - if (empty($text)) $text = $langs->trans("Undefined").' '.img_warning(); + if (empty($text)) { + $text = $langs->trans("Undefined").' '.img_warning(); + } print $text; print '
'.$langs->trans("MAIN_MAIL_SMS_FROM", $langs->transnoentities("Undefined")).''.$conf->global->MAIN_MAIL_SMS_FROM; - if (!empty($conf->global->MAIN_MAIL_SMS_FROM) && !isValidPhone($conf->global->MAIN_MAIL_SMS_FROM)) print ' '.img_warning($langs->trans("ErrorBadPhone")); + if (!empty($conf->global->MAIN_MAIL_SMS_FROM) && !isValidPhone($conf->global->MAIN_MAIL_SMS_FROM)) { + print ' '.img_warning($langs->trans("ErrorBadPhone")); + } print '
'.$conf->global->MAIN_MAIL_AUTOCOPY_TO; if (!empty($conf->global->MAIN_MAIL_AUTOCOPY_TO) && ! isValidEmail($conf->global->MAIN_MAIL_AUTOCOPY_TO)) print img_warning($langs->trans("ErrorBadEMail")); print '
'; @@ -257,8 +267,7 @@ if ($action == 'edit') print ''.$langs->trans("DoTestServerAvailability").''; }*/ - if (count($listofmethods) && !empty($conf->global->MAIN_SMS_SENDMODE)) - { + if (count($listofmethods) && !empty($conf->global->MAIN_SMS_SENDMODE)) { print ''.$langs->trans("DoTestSend").''; } else { print ''.$langs->trans("DoTestSend").''; @@ -290,8 +299,7 @@ if ($action == 'edit') }*/ // Affichage formulaire de TEST simple - if ($action == 'test') - { + if ($action == 'test') { print '
'; print load_fiche_titre($langs->trans("DoTestSend")); diff --git a/htdocs/api/admin/index.php b/htdocs/api/admin/index.php index b4ebb6cb30e..1d15d5b9e75 100644 --- a/htdocs/api/admin/index.php +++ b/htdocs/api/admin/index.php @@ -160,7 +160,8 @@ if (dol_is_dir(DOL_DOCUMENT_ROOT.'/includes/restler/framework/Luracast/Restler/e $url = DOL_MAIN_URL_ROOT.'/api/index.php/explorer'; print img_picto('', 'globe').' '.$url."
\n"; } else { - print $langs->trans("NotAvailableWithThisDistribution"); + $langs->load("errors"); + print info_admin($langs->trans("ErrorNotAvailableWithThisDistribution"), 0, 0, 'error'); } llxFooter(); diff --git a/htdocs/asset/class/asset.class.php b/htdocs/asset/class/asset.class.php index 25cac778264..ae866ff24ba 100644 --- a/htdocs/asset/class/asset.class.php +++ b/htdocs/asset/class/asset.class.php @@ -158,28 +158,6 @@ class Asset extends CommonObject */ public $status; - // If this object has a subtable with lines - - /** - * @var int Name of subtable line - */ - //public $table_element_line = 'assetdet'; - /** - * @var int Field with ID of parent key if this field has a parent - */ - //public $fk_element = 'fk_asset'; - /** - * @var int Name of subtable class that manage subtable lines - */ - //public $class_element_line = 'Assetline'; - /** - * @var array List of child tables. To test if we can delete object. - */ - //protected $childtables=array(); - /** - * @var AssetLine[] Array of subtable lines - */ - //public $lines = array(); /** * Constructor diff --git a/htdocs/bom/class/bom.class.php b/htdocs/bom/class/bom.class.php index 868abac9e54..8444c4e1812 100644 --- a/htdocs/bom/class/bom.class.php +++ b/htdocs/bom/class/bom.class.php @@ -183,19 +183,19 @@ class BOM extends CommonObject public $table_element_line = 'bom_bomline'; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Fieldname with ID of parent key if this field has a parent */ public $fk_element = 'fk_bom'; /** - * @var int Name of subtable class that manage subtable lines + * @var string Name of subtable class that manage subtable lines */ public $class_element_line = 'BOMLine'; - /** - * @var array List of child tables. To test if we can delete object. - */ - //protected $childtables=array(); + // /** + // * @var array List of child tables. To test if we can delete object. + // */ + // protected $childtables=array(); /** * @var array List of child tables. To know object to delete on cascade. diff --git a/htdocs/comm/mailing/class/advtargetemailing.class.php b/htdocs/comm/mailing/class/advtargetemailing.class.php index 8a4ebfa90c9..b7f20319229 100644 --- a/htdocs/comm/mailing/class/advtargetemailing.class.php +++ b/htdocs/comm/mailing/class/advtargetemailing.class.php @@ -54,7 +54,7 @@ class AdvanceTargetingMailing extends CommonObject public $name; /** - * @var int element id + * @var int element id (it's not the name of a field) */ public $fk_element; diff --git a/htdocs/comm/propal/class/propal.class.php b/htdocs/comm/propal/class/propal.class.php index c761f8b3321..5c4ed9e2edf 100644 --- a/htdocs/comm/propal/class/propal.class.php +++ b/htdocs/comm/propal/class/propal.class.php @@ -66,7 +66,7 @@ class Propal extends CommonObject public $table_element_line = 'propaldet'; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Fieldname with ID of parent key if this field has a parent */ public $fk_element = 'fk_propal'; @@ -1099,7 +1099,7 @@ class Propal extends CommonObject if ($this->id) { $this->ref = '(PROV'.$this->id.')'; - $sql = 'UPDATE '.MAIN_DB_PREFIX."propal SET ref='".$this->db->escape($this->ref)."' WHERE rowid=".$this->id; + $sql = 'UPDATE '.MAIN_DB_PREFIX."propal SET ref='".$this->db->escape($this->ref)."' WHERE rowid=".((int) $this->id); dol_syslog(get_class($this)."::create", LOG_DEBUG); $resql = $this->db->query($sql); @@ -1111,7 +1111,7 @@ class Propal extends CommonObject } // Add object linked - if (!$error && $this->id && is_array($this->linked_objects) && !empty($this->linked_objects)) + if (!$error && $this->id && !empty($this->linked_objects) && is_array($this->linked_objects)) { foreach ($this->linked_objects as $origin => $tmp_origin_id) { @@ -3753,7 +3753,10 @@ class PropaleLigne extends CommonObjectLine public $product_type = Product::TYPE_PRODUCT; public $qty; + public $tva_tx; + public $vat_src_code; + public $subprice; public $remise_percent; public $fk_remise_except; @@ -3805,6 +3808,11 @@ class PropaleLigne extends CommonObjectLine * @see $product_label */ public $libelle; + /** + * @deprecated + * @see $product_label + */ + public $label; /** * Product label * @var string diff --git a/htdocs/compta/deplacement/class/deplacement.class.php b/htdocs/compta/deplacement/class/deplacement.class.php index 1a1fd42d21b..75d2f71284c 100644 --- a/htdocs/compta/deplacement/class/deplacement.class.php +++ b/htdocs/compta/deplacement/class/deplacement.class.php @@ -43,12 +43,12 @@ class Deplacement extends CommonObject public $table_element = 'deplacement'; /** - * @var int Name of subtable line + * @var string Name of subtable line */ public $table_element_line = ''; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Fieldname with ID of parent key if this field has a parent */ public $fk_element = ''; diff --git a/htdocs/compta/facture/card.php b/htdocs/compta/facture/card.php index 110db6d8166..4451f13bd77 100644 --- a/htdocs/compta/facture/card.php +++ b/htdocs/compta/facture/card.php @@ -3551,7 +3551,7 @@ if ($action == 'create') print ''; } - // Lines from source (TODO Show them also when creating invoice from tempalte invoice) + // Lines from source (TODO Show them also when creating invoice from template invoice) if (!empty($origin) && !empty($originid) && is_object($objectsrc)) { // TODO for compatibility diff --git a/htdocs/compta/facture/class/facture-rec.class.php b/htdocs/compta/facture/class/facture-rec.class.php index e4187a4e906..48e2ad574ed 100644 --- a/htdocs/compta/facture/class/facture-rec.class.php +++ b/htdocs/compta/facture/class/facture-rec.class.php @@ -50,12 +50,12 @@ class FactureRec extends CommonInvoice public $table_element = 'facture_rec'; /** - * @var int Name of subtable line + * @var string Name of subtable line */ public $table_element_line = 'facturedet_rec'; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Field with ID of parent key if this field has a parent */ public $fk_element = 'fk_facture'; diff --git a/htdocs/compta/facture/class/facture.class.php b/htdocs/compta/facture/class/facture.class.php index 456a18d8e2c..77266718b75 100644 --- a/htdocs/compta/facture/class/facture.class.php +++ b/htdocs/compta/facture/class/facture.class.php @@ -64,12 +64,12 @@ class Facture extends CommonInvoice public $table_element = 'facture'; /** - * @var int Name of subtable line + * @var string Name of subtable line */ public $table_element_line = 'facturedet'; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Fieldname with ID of parent key if this field has a parent */ public $fk_element = 'fk_facture'; diff --git a/htdocs/compta/stats/index.php b/htdocs/compta/stats/index.php index 1a1de43709d..93f91b25449 100644 --- a/htdocs/compta/stats/index.php +++ b/htdocs/compta/stats/index.php @@ -3,7 +3,7 @@ * Copyright (C) 2004-2012 Laurent Destailleur * Copyright (C) 2005-2009 Regis Houssin * Copyright (C) 2017 Olivier Geffroy - * Copyright (C) 2018 Frédéric France + * Copyright (C) 2018-2020 Frédéric France * * 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 @@ -122,7 +122,9 @@ if ($modecompta == "CREANCES-DETTES") $name = $langs->trans("Turnover"); $calcmode = $langs->trans("CalcModeDebt"); //$calcmode.='
('.$langs->trans("SeeReportInInputOutputMode",'','').')'; - $calcmode .= '
('.$langs->trans("SeeReportInBookkeepingMode", '', '').')'; + $calcmode .= '
('.$langs->trans("SeeReportInBookkeepingMode", '{links1}', '{link2}').')'; + $calcmode = str_replace('{link1}', '', $calcmode); + $calcmode = str_replace('{link2}', '', $calcmode); $period = $form->selectDate($date_start, 'date_start', 0, 0, 0, '', 1, 0).' - '.$form->selectDate($date_end, 'date_end', 0, 0, 0, '', 1, 0); $periodlink = ($year_start ? "".img_previous()." ".img_next()."" : ""); $description = $langs->trans("RulesCADue"); @@ -146,7 +148,9 @@ if ($modecompta == "CREANCES-DETTES") { $name = $langs->trans("Turnover"); $calcmode = $langs->trans("CalcModeBookkeeping"); - $calcmode .= '
('.$langs->trans("SeeReportInDueDebtMode", '', '').')'; + $calcmode .= '
('.$langs->trans("SeeReportInDueDebtMode", '{link1}', '{link2}').')'; + $calcmode = str_replace('{link1}', '', $calcmode); + $calcmode = str_replace('{link2}', '', $calcmode); //$calcmode.='
('.$langs->trans("SeeReportInInputOutputMode",'','').')'; $period = $form->selectDate($date_start, 'date_start', 0, 0, 0, '', 1, 0).' - '.$form->selectDate($date_end, 'date_end', 0, 0, 0, '', 1, 0); $periodlink = ($year_start ? "".img_previous()." ".img_next()."" : ""); diff --git a/htdocs/contrat/class/contrat.class.php b/htdocs/contrat/class/contrat.class.php index aa146aebf10..a3d0b82d2b7 100644 --- a/htdocs/contrat/class/contrat.class.php +++ b/htdocs/contrat/class/contrat.class.php @@ -53,12 +53,12 @@ class Contrat extends CommonObject public $table_element = 'contrat'; /** - * @var int Name of subtable line + * @var string Name of subtable line */ public $table_element_line = 'contratdet'; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Fieldname with ID of parent key if this field has a parent */ public $fk_element = 'fk_contrat'; diff --git a/htdocs/core/boxes/box_produits.php b/htdocs/core/boxes/box_produits.php index dc7f79721d1..f36b0500655 100644 --- a/htdocs/core/boxes/box_produits.php +++ b/htdocs/core/boxes/box_produits.php @@ -84,21 +84,25 @@ class box_produits extends ModeleBoxes $this->info_box_head = array('text' => $langs->trans("BoxTitleLastProducts", $max)); - if ($user->rights->produit->lire || $user->rights->service->lire) - { + if ($user->rights->produit->lire || $user->rights->service->lire) { $sql = "SELECT p.rowid, p.label, p.ref, p.price, p.price_base_type, p.price_ttc, p.fk_product_type, p.tms, p.tosell, p.tobuy, p.fk_price_expression, p.entity"; $sql .= ", p.accountancy_code_sell"; $sql .= ", p.accountancy_code_sell_intra"; $sql .= ", p.accountancy_code_sell_export"; $sql .= ", p.accountancy_code_buy"; + $sql .= ", p.accountancy_code_buy_intra"; + $sql .= ", p.accountancy_code_buy_export"; $sql .= ', p.barcode'; $sql .= " FROM ".MAIN_DB_PREFIX."product as p"; $sql .= ' WHERE p.entity IN ('.getEntity($productstatic->element).')'; - if (empty($user->rights->produit->lire)) $sql .= ' AND p.fk_product_type != 0'; - if (empty($user->rights->service->lire)) $sql .= ' AND p.fk_product_type != 1'; + if (empty($user->rights->produit->lire)) { + $sql .= ' AND p.fk_product_type != 0'; + } + if (empty($user->rights->service->lire)) { + $sql .= ' AND p.fk_product_type != 1'; + } // Add where from hooks - if (is_object($hookmanager)) - { + if (is_object($hookmanager)) { $parameters = array('boxproductlist'=>1); $reshook = $hookmanager->executeHooks('printFieldListWhere', $parameters); // Note that $action and $object may have been modified by hook $sql .= $hookmanager->resPrint; @@ -107,18 +111,15 @@ class box_produits extends ModeleBoxes $sql .= $this->db->plimit($max, 0); $result = $this->db->query($sql); - if ($result) - { + if ($result) { $num = $this->db->num_rows($result); $line = 0; - while ($line < $num) - { + while ($line < $num) { $objp = $this->db->fetch_object($result); $datem = $this->db->jdate($objp->tms); // Multilangs - if (!empty($conf->global->MAIN_MULTILANGS)) // si l'option est active - { + if (!empty($conf->global->MAIN_MULTILANGS)) { // si l'option est active $sqld = "SELECT label"; $sqld .= " FROM ".MAIN_DB_PREFIX."product_lang"; $sqld .= " WHERE fk_product=".$objp->rowid; @@ -126,11 +127,11 @@ class box_produits extends ModeleBoxes $sqld .= " LIMIT 1"; $resultd = $this->db->query($sqld); - if ($resultd) - { + if ($resultd) { $objtp = $this->db->fetch_object($resultd); - if (isset($objtp->label) && $objtp->label != '') + if (isset($objtp->label) && $objtp->label != '') { $objp->label = $objtp->label; + } } } $productstatic->id = $objp->rowid; @@ -145,6 +146,8 @@ class box_produits extends ModeleBoxes $productstatic->accountancy_code_sell_intra = $objp->accountancy_code_sell_intra; $productstatic->accountancy_code_sell_export = $objp->accountancy_code_sell_export; $productstatic->accountancy_code_buy = $objp->accountancy_code_buy; + $productstatic->accountancy_code_buy_intra = $objp->accountancy_code_buy_intra; + $productstatic->accountancy_code_buy_export = $objp->accountancy_code_buy_export; $this->info_box_contents[$line][] = array( 'td' => 'class="tdoverflowmax100 maxwidth100onsmartphone"', @@ -161,14 +164,13 @@ class box_produits extends ModeleBoxes if (empty($conf->dynamicprices->enabled) || empty($objp->fk_price_expression)) { $price_base_type = $langs->trans($objp->price_base_type); $price = ($objp->price_base_type == 'HT') ?price($objp->price) : $price = price($objp->price_ttc); - } else //Parse the dynamic price - { + } else { + //Parse the dynamic price $productstatic->fetch($objp->rowid, '', '', 1); $priceparser = new PriceParser($this->db); $price_result = $priceparser->parseProduct($productstatic); if ($price_result >= 0) { - if ($objp->price_base_type == 'HT') - { + if ($objp->price_base_type == 'HT') { $price_base_type = $langs->trans("HT"); } else { $price_result = $price_result * (1 + ($productstatic->tva_tx / 100)); @@ -176,7 +178,7 @@ class box_produits extends ModeleBoxes } $price = price($price_result); } - } + } $this->info_box_contents[$line][] = array( 'td' => 'class="right"', 'text' => $price, @@ -206,11 +208,12 @@ class box_produits extends ModeleBoxes $line++; } - if ($num == 0) + if ($num == 0) { $this->info_box_contents[$line][0] = array( 'td' => 'class="center"', 'text'=>$langs->trans("NoRecordedProducts"), ); + } $this->db->free($result); } else { diff --git a/htdocs/core/class/CMailFile.class.php b/htdocs/core/class/CMailFile.class.php index b2149cd187f..faf0a294dfe 100644 --- a/htdocs/core/class/CMailFile.class.php +++ b/htdocs/core/class/CMailFile.class.php @@ -242,6 +242,7 @@ class CMailFile { $this->html = $msg; + $findimg = 0; if (!empty($conf->global->MAIN_MAIL_ADD_INLINE_IMAGES_IF_IN_MEDIAS)) { $findimg = $this->findHtmlImages($dolibarr_main_data_root.'/medias'); diff --git a/htdocs/core/class/comment.class.php b/htdocs/core/class/comment.class.php index d2c6221a598..3f9ca42e136 100644 --- a/htdocs/core/class/comment.class.php +++ b/htdocs/core/class/comment.class.php @@ -32,10 +32,13 @@ class Comment extends CommonObject public $table_element = 'comment'; /** - * @var int Field with ID of parent key if this field has a parent + * @var int ID of parent key (it's not the name of a field) */ - public $fk_element = ''; + public $fk_element; + /** + * @var string element type + */ public $element_type; /** @@ -72,10 +75,16 @@ class Comment extends CommonObject */ public $entity; + /** + * @var string import key + */ public $import_key; public $comments = array(); + /** + * @var Comment Object oldcopy + */ public $oldcopy; @@ -131,26 +140,26 @@ class Comment extends CommonObject dol_syslog(get_class($this)."::create", LOG_DEBUG); $resql = $this->db->query($sql); - if (!$resql) { $error++; $this->errors[] = "Error ".$this->db->lasterror(); } + if (!$resql) { + $error++; $this->errors[] = "Error ".$this->db->lasterror(); + } - if (!$error) - { + if (!$error) { $this->id = $this->db->last_insert_id(MAIN_DB_PREFIX.$this->table_element); - if (!$notrigger) - { + if (!$notrigger) { // Call trigger $result = $this->call_trigger('TASK_COMMENT_CREATE', $user); - if ($result < 0) { $error++; } + if ($result < 0) { + $error++; + } // End call triggers } } // Commit or rollback - if ($error) - { - foreach ($this->errors as $errmsg) - { + if ($error) { + foreach ($this->errors as $errmsg) { dol_syslog(get_class($this)."::create ".$errmsg, LOG_ERR); $this->error .= ($this->error ? ', '.$errmsg : $errmsg); } @@ -190,12 +199,10 @@ class Comment extends CommonObject dol_syslog(get_class($this)."::fetch", LOG_DEBUG); $resql = $this->db->query($sql); - if ($resql) - { + if ($resql) { $num_rows = $this->db->num_rows($resql); - if ($num_rows) - { + if ($num_rows) { $obj = $this->db->fetch_object($resql); $this->id = $obj->rowid; @@ -212,8 +219,11 @@ class Comment extends CommonObject $this->db->free($resql); - if ($num_rows) return 1; - else return 0; + if ($num_rows) { + return 1; + } else { + return 0; + } } else { $this->error = "Error ".$this->db->lasterror(); return -1; @@ -234,8 +244,12 @@ class Comment extends CommonObject $error = 0; // Clean parameters - if (isset($this->fk_element)) $this->fk_project = (int) trim($this->fk_element); - if (isset($this->description)) $this->description = trim($this->description); + if (isset($this->fk_element)) { + $this->fk_project = (int) trim($this->fk_element); + } + if (isset($this->description)) { + $this->description = trim($this->description); + } // Update request @@ -253,24 +267,24 @@ class Comment extends CommonObject dol_syslog(get_class($this)."::update", LOG_DEBUG); $resql = $this->db->query($sql); - if (!$resql) { $error++; $this->errors[] = "Error ".$this->db->lasterror(); } + if (!$resql) { + $error++; $this->errors[] = "Error ".$this->db->lasterror(); + } - if (!$error) - { - if (!$notrigger) - { + if (!$error) { + if (!$notrigger) { // Call trigger $result = $this->call_trigger('TASK_COMMENT_MODIFY', $user); - if ($result < 0) { $error++; } + if ($result < 0) { + $error++; + } // End call triggers } } // Commit or rollback - if ($error) - { - foreach ($this->errors as $errmsg) - { + if ($error) { + foreach ($this->errors as $errmsg) { dol_syslog(get_class($this)."::update ".$errmsg, LOG_ERR); $this->error .= ($this->error ? ', '.$errmsg : $errmsg); } @@ -303,24 +317,24 @@ class Comment extends CommonObject $sql .= " WHERE rowid=".$this->id; $resql = $this->db->query($sql); - if (!$resql) { $error++; $this->errors[] = "Error ".$this->db->lasterror(); } + if (!$resql) { + $error++; $this->errors[] = "Error ".$this->db->lasterror(); + } - if (!$error) - { - if (!$notrigger) - { + if (!$error) { + if (!$notrigger) { // Call trigger $result = $this->call_trigger('TASK_COMMENT_DELETE', $user); - if ($result < 0) { $error++; } + if ($result < 0) { + $error++; + } // End call triggers } } // Commit or rollback - if ($error) - { - foreach ($this->errors as $errmsg) - { + if ($error) { + foreach ($this->errors as $errmsg) { dol_syslog(get_class($this)."::delete ".$errmsg, LOG_ERR); $this->error .= ($this->error ? ', '.$errmsg : $errmsg); } @@ -355,13 +369,10 @@ class Comment extends CommonObject dol_syslog(get_class($this).'::'.__METHOD__, LOG_DEBUG); $resql = $this->db->query($sql); - if ($resql) - { + if ($resql) { $num_rows = $this->db->num_rows($resql); - if ($num_rows > 0) - { - while ($obj = $this->db->fetch_object($resql)) - { + if ($num_rows > 0) { + while ($obj = $this->db->fetch_object($resql)) { $comment = new self($db); $comment->fetch($obj->rowid); $this->comments[] = $comment; diff --git a/htdocs/core/class/commonobject.class.php b/htdocs/core/class/commonobject.class.php index 33ac1aba696..6ecdfb93bb5 100644 --- a/htdocs/core/class/commonobject.class.php +++ b/htdocs/core/class/commonobject.class.php @@ -3161,7 +3161,7 @@ abstract class CommonObject $this->multicurrency_total_ttc += isset($this->revenuestamp) ? ($this->revenuestamp * $multicurrency_tx) : 0; // Situations totals - if ($this->situation_cycle_ref && $this->situation_counter > 1 && method_exists($this, 'get_prev_sits') && $this->type != $this::TYPE_CREDIT_NOTE) + if (!empty($this->situation_cycle_ref) && $this->situation_counter > 1 && method_exists($this, 'get_prev_sits') && $this->type != $this::TYPE_CREDIT_NOTE) { $prev_sits = $this->get_prev_sits(); diff --git a/htdocs/core/class/emailsenderprofile.class.php b/htdocs/core/class/emailsenderprofile.class.php index efb2e554da9..0d9ddd72e24 100644 --- a/htdocs/core/class/emailsenderprofile.class.php +++ b/htdocs/core/class/emailsenderprofile.class.php @@ -125,7 +125,6 @@ class EmailSenderProfile extends CommonObject */ public $date_creation; - public $tms; public $private; public $signature; @@ -134,32 +133,6 @@ class EmailSenderProfile extends CommonObject // END MODULEBUILDER PROPERTIES - - // If this object has a subtable with lines - - /** - * @var int Name of subtable line - */ - //public $table_element_line = 'emailsenderprofiledet'; - /** - * @var int Field with ID of parent key if this field has a parent - */ - //public $fk_element = 'fk_emailsenderprofile'; - /** - * @var int Name of subtable class that manage subtable lines - */ - //public $class_element_line = 'EmailSenderProfileline'; - /** - * @var array List of child tables. To test if we can delete object. - */ - //protected $childtables=array(); - /** - * @var EmailSenderProfileLine[] Array of subtable lines - */ - //public $lines = array(); - - - /** * Constructor * diff --git a/htdocs/core/class/fiscalyear.class.php b/htdocs/core/class/fiscalyear.class.php index 0e822076641..ebbdb2c3274 100644 --- a/htdocs/core/class/fiscalyear.class.php +++ b/htdocs/core/class/fiscalyear.class.php @@ -35,6 +35,9 @@ class Fiscalyear extends CommonObject */ public $element = 'fiscalyear'; + /** + * @var string picto + */ public $picto = 'technic'; /** @@ -43,12 +46,12 @@ class Fiscalyear extends CommonObject public $table_element = 'accounting_fiscalyear'; /** - * @var int Name of subtable line + * @var string Name of subtable line */ public $table_element_line = ''; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Field with ID of parent key if this field has a parent */ public $fk_element = ''; diff --git a/htdocs/core/lib/admin.lib.php b/htdocs/core/lib/admin.lib.php index b8cdf8cd085..704a4496d03 100644 --- a/htdocs/core/lib/admin.lib.php +++ b/htdocs/core/lib/admin.lib.php @@ -924,30 +924,33 @@ function purgeSessions($mysessionid) dol_syslog('admin.lib:purgeSessions mysessionid='.$mysessionid.' sessPath='.$sessPath); $error = 0; - $dh = @opendir(dol_osencode($sessPath)); - while (($file = @readdir($dh)) !== false) { - if ($file != "." && $file != "..") { - $fullpath = $sessPath.$file; - if (!@is_dir($fullpath)) { - $sessValues = file_get_contents($fullpath); // get raw session data - if (preg_match('/dol_login/i', $sessValues) && // limit to dolibarr session - preg_match('/dol_entity\|s:([0-9]+):"('.$conf->entity.')"/i', $sessValues) && // limit to current entity - preg_match('/dol_company\|s:([0-9]+):"('.$conf->global->MAIN_INFO_SOCIETE_NOM.')"/i', $sessValues)) { // limit to company name - $tmp = explode('_', $file); - $idsess = $tmp[1]; - // We remove session if it's not ourself - if ($idsess != $mysessionid) { - $res = @unlink($fullpath); - if (!$res) { - $error++; + $dh = @opendir(dol_osencode($sessPath)); + if ($dh) { + while (($file = @readdir($dh)) !== false) { + if ($file != "." && $file != "..") { + $fullpath = $sessPath.$file; + if (!@is_dir($fullpath)) { + $sessValues = file_get_contents($fullpath); // get raw session data + + if (preg_match('/dol_login/i', $sessValues) && // limit to dolibarr session + preg_match('/dol_entity\|s:([0-9]+):"('.$conf->entity.')"/i', $sessValues) && // limit to current entity + preg_match('/dol_company\|s:([0-9]+):"('.$conf->global->MAIN_INFO_SOCIETE_NOM.')"/i', $sessValues)) { // limit to company name + $tmp = explode('_', $file); + $idsess = $tmp[1]; + // We remove session if it's not ourself + if ($idsess != $mysessionid) { + $res = @unlink($fullpath); + if (!$res) { + $error++; + } } } } } } + @closedir($dh); } - @closedir($dh); if (!$error) { return 1; diff --git a/htdocs/core/lib/functions.lib.php b/htdocs/core/lib/functions.lib.php index d38cdc69104..ab3a6dc45a8 100644 --- a/htdocs/core/lib/functions.lib.php +++ b/htdocs/core/lib/functions.lib.php @@ -3186,9 +3186,8 @@ function img_picto($titlealt, $picto, $moreatt = '', $pictoisfullpath = false, $ // We forge fullpathpicto for image to $path/img/$picto. By default, we take DOL_URL_ROOT/theme/$conf->theme/img/$picto $url = DOL_URL_ROOT; - $theme = $conf->theme; + $theme = isset($conf->theme) ? $conf->theme : null; $path = 'theme/'.$theme; - // Define fullpathpicto to use into src if ($pictoisfullpath) { // Clean parameters diff --git a/htdocs/core/lib/website2.lib.php b/htdocs/core/lib/website2.lib.php index 673b904b743..1ed80ece372 100644 --- a/htdocs/core/lib/website2.lib.php +++ b/htdocs/core/lib/website2.lib.php @@ -442,7 +442,7 @@ function dolSaveReadme($file, $content) /** * Show list of themes. Show all thumbs of themes/skins * - * @param Website $website Object website to load the tempalte into + * @param Website $website Object website to load the template into * @return void */ function showWebsiteTemplates(Website $website) diff --git a/htdocs/core/menus/standard/eldy.lib.php b/htdocs/core/menus/standard/eldy.lib.php index b103a309f59..4e339c4880e 100644 --- a/htdocs/core/menus/standard/eldy.lib.php +++ b/htdocs/core/menus/standard/eldy.lib.php @@ -360,10 +360,11 @@ function print_eldy_menu($db, $atarget, $type_user, &$tabMenu, &$menu, $noout = // HRM $tmpentry = array( - 'enabled'=>(!empty($conf->hrm->enabled) || !empty($conf->holiday->enabled) || !empty($conf->deplacement->enabled) || !empty($conf->expensereport->enabled) || !empty($conf->recruitment->enabled)), + 'enabled'=>(!empty($conf->hrm->enabled) || (!empty($conf->holiday->enabled)) || !empty($conf->deplacement->enabled) || !empty($conf->expensereport->enabled) || !empty($conf->recruitment->enabled)), 'perms'=>(!empty($user->rights->hrm->employee->read) || !empty($user->rights->holiday->write) || !empty($user->rights->deplacement->lire) || !empty($user->rights->expensereport->lire) || !empty($user->rights->recruitment->recruitmentjobposition->read)), 'module'=>'hrm|holiday|deplacement|expensereport|recruitment' ); + $menu_arr[] = array( 'name' => 'HRM', 'link' => '/hrm/index.php?mainmenu=hrm&leftmenu=', @@ -1592,7 +1593,7 @@ function print_left_eldy_menu($db, $menu_array_before, $menu_array_after, &$tabM if ($conf->supplier_order->enabled) { $newmenu->add("/product/stock/replenish.php", $langs->trans("Replenishment"), 1, $user->rights->stock->mouvement->creer && $user->rights->fournisseur->lire); } - $newmenu->add("/product/stock/stockatdate.php", $langs->trans("StockAtDate"), 1, $user->rights->produit->lire && $user->rights->stock->lire && $conf->global->MAIN_FEATURES_LEVEL >= 2); + $newmenu->add("/product/stock/stockatdate.php", $langs->trans("StockAtDate"), 1, $user->rights->produit->lire && $user->rights->stock->lire); // Categories for warehouses if (!empty($conf->categorie->enabled)) { diff --git a/htdocs/core/menus/standard/empty.php b/htdocs/core/menus/standard/empty.php index b3151e15748..1ab7778bb01 100644 --- a/htdocs/core/menus/standard/empty.php +++ b/htdocs/core/menus/standard/empty.php @@ -32,10 +32,13 @@ class MenuManager public $type_user = 0; // Put 0 for internal users, 1 for external users public $atarget = ""; // To store default target to use onto links + public $name = "empty"; public $menu; public $menu_array_after; + public $tabMenu; + /** * Constructor @@ -60,6 +63,7 @@ class MenuManager public function loadMenu($forcemainmenu = '', $forceleftmenu = '') { // Do nothing + $this->tabMenu = array(); } @@ -348,14 +352,29 @@ class MenuManager // ***** END ***** + $menu_array_before = array(); + $menu_array_after = array(); + // do not change code after this + $menu_array = $this->menu->liste; + if (is_array($menu_array_before)) { + $menu_array = array_merge($menu_array_before, $menu_array); + } + if (is_array($menu_array_after)) { + $menu_array = array_merge($menu_array, $menu_array_after); + } + //var_dump($menu_array);exit; + if (!is_array($menu_array)) { + return 0; + } + if (empty($noout)) { $alt = 0; $altok = 0; $blockvmenuopened = false; - $num = count($this->menu->liste); + $num = count($menu_array); for ($i = 0; $i < $num; $i++) { $alt++; - if (empty($this->menu->liste[$i]['level'])) { + if (empty($menu_array[$i]['level'])) { $altok++; $blockvmenuopened = true; $lastopened = true; @@ -375,55 +394,55 @@ class MenuManager // Add tabulation $tabstring = ''; - $tabul = ($this->menu->liste[$i]['level'] - 1); + $tabul = ($menu_array[$i]['level'] - 1); if ($tabul > 0) { for ($j = 0; $j < $tabul; $j++) { $tabstring .= '   '; } } - if ($this->menu->liste[$i]['level'] == 0) { - if ($this->menu->liste[$i]['enabled']) { - print ''."\n"; + if ($menu_array[$i]['level'] == 0) { + if ($menu_array[$i]['enabled']) { + print ''."\n"; } else { - print ''."\n"; + print ''."\n"; } print ''."\n"; } - if ($this->menu->liste[$i]['level'] > 0) { + if ($menu_array[$i]['level'] > 0) { $cssmenu = ''; - if ($this->menu->liste[$i]['url']) { - $cssmenu = ' menu_contenu'.dol_string_nospecial(preg_replace('/\.php.*$/', '', $this->menu->liste[$i]['url'])); + if ($menu_array[$i]['url']) { + $cssmenu = ' menu_contenu'.dol_string_nospecial(preg_replace('/\.php.*$/', '', $menu_array[$i]['url'])); } print ''."\n"; } // If next is a new block or end - if (empty($this->menu->liste[$i + 1]['level'])) { + if (empty($menu_array[$i + 1]['level'])) { print ''."\n"; print "
\n"; } @@ -436,66 +455,9 @@ class MenuManager if ($mode == 'jmobile') { $this->leftmenu = clone $this->menu; - unset($this->menu->liste); + unset($menu_array); } } - /* - if ($mode == 'jmobile') - { - $substitarray = getCommonSubstitutionArray($langs, 0, null, null); - - foreach($this->menu->liste as $key => $val) // $val['url','titre','level','enabled'=0|1|2,'target','mainmenu','leftmenu' - { - print '
    '; - print '
  • '; - - $val['url'] = make_substitutions($val['url'], $substitarray); - - if ($val['enabled'] == 1) - { - $relurl=dol_buildpath($val['url'],1); - - print ''.$val['titre'].''."\n"; - // Search submenu fot this entry - $tmpmainmenu=$val['mainmenu']; - $tmpleftmenu='all'; - //$submenu=new Menu(); - //$res=print_left_eldy_menu($this->db,$this->menu_array,$this->menu_array_after,$this->tabMenu,$submenu,1,$tmpmainmenu,$tmpleftmenu, null, $this->type_user); - //$nexturl=dol_buildpath($submenu->liste[0]['url'],1); - $submenu=$this->leftmenu; - - $canonrelurl=preg_replace('/\?.*$/','',$relurl); - $canonnexturl=preg_replace('/\?.*$/','',$nexturl); - //var_dump($canonrelurl); - //var_dump($canonnexturl); - print '
      '; - if ($canonrelurl != $canonnexturl && ! in_array($val['mainmenu'],array('home','tools'))) - { - // We add sub entry - print '
    • '.$langs->trans("MainArea").'-'.$val['titre'].'
    • '."\n"; - } - foreach($submenu->liste as $key2 => $val2) // $val['url','titre','level','enabled'=0|1|2,'target','mainmenu','leftmenu' - { - $val2['url'] = make_substitutions($val2['url'], $substitarray); - - $relurl2=dol_buildpath($val2['url'],1); - //var_dump($val2); - print '
    • '.$val2['titre'].'
    • '."\n"; - } - //var_dump($submenu); - print '
    '; - } - if ($val['enabled'] == 2) - { - print ''.$val['titre'].''; - } - print '
  • '; - print '
'."\n"; - - break; // Only first menu entry (so home) - } - } - */ unset($this->menu); return $res; diff --git a/htdocs/core/modules/DolibarrModules.class.php b/htdocs/core/modules/DolibarrModules.class.php index 794cfd0cef4..510ec8ef55a 100644 --- a/htdocs/core/modules/DolibarrModules.class.php +++ b/htdocs/core/modules/DolibarrModules.class.php @@ -1250,12 +1250,13 @@ class DolibarrModules // Can not be abstract, because we need to instantiate it //print "Remove box ".$file.'
'; if ($file == 'box_graph_product_distribution.php') { if (!empty($conf->product->enabled) || !empty($conf->service->enabled)) { - dol_syslog("We discard disabling of module ".$file." because another module still active require it."); + dol_syslog("We discard deleting module ".$file." because another module still active requires it."); continue; } } - if (empty($file)) { $file = isset($this->boxes[$key][1]) ? $this->boxes[$key][1] : ''; // For backward compatibility + if (empty($file)) { + $file = isset($this->boxes[$key][1]) ? $this->boxes[$key][1] : ''; // For backward compatibility } if ($this->db->type == 'sqlite3') { @@ -1284,7 +1285,7 @@ class DolibarrModules // Can not be abstract, because we need to instantiate it $sql = "DELETE FROM ".MAIN_DB_PREFIX."boxes_def"; $sql .= " WHERE file = '".$this->db->escape($file)."'"; - $sql .= " AND entity = ".$conf->entity; + $sql .= " AND entity = ".$conf->entity; // Do not use getEntity here, we want to delete only in current company dol_syslog(get_class($this)."::delete_boxes", LOG_DEBUG); $resql = $this->db->query($sql); diff --git a/htdocs/core/modules/modBookmark.class.php b/htdocs/core/modules/modBookmark.class.php index 0a3d9ccd11b..e6ac76f0178 100644 --- a/htdocs/core/modules/modBookmark.class.php +++ b/htdocs/core/modules/modBookmark.class.php @@ -69,7 +69,9 @@ class modBookmark extends DolibarrModules $this->const = array(); // Boxes - $this->boxes = array(0=>array('file'=>'box_bookmarks.php', 'enabledbydefaulton'=>'Home')); + $this->boxes = array( + 0=>array('file'=>'box_bookmarks.php', 'enabledbydefaulton'=>'Home') + ); // Permissions $this->rights = array(); diff --git a/htdocs/core/modules/modCategorie.class.php b/htdocs/core/modules/modCategorie.class.php index a70593a5e1e..bb6c36b353c 100644 --- a/htdocs/core/modules/modCategorie.class.php +++ b/htdocs/core/modules/modCategorie.class.php @@ -386,10 +386,10 @@ class modCategorie extends DolibarrModules ) ); $typeexample = ""; - if ($conf->product->enabled) { $typeexample .= ($typeexample ? "/" : "")."0=Product"; } + if (!empty($conf->product->enabled)) { $typeexample .= ($typeexample ? "/" : "")."0=Product"; } if (!empty($conf->fournisseur->enabled) && empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD) || !empty($conf->supplier_order->enabled) || !empty($conf->supplier_invoice->enabled)) { $typeexample .= ($typeexample ? "/" : "")."1=Supplier"; } - if ($conf->societe->enabled) { $typeexample .= ($typeexample ? "/" : "")."2=Customer-Prospect"; } - if ($conf->adherent->enabled) { $typeexample .= ($typeexample ? "/" : "")."3=Member"; } + if (!empty($conf->societe->enabled)) { $typeexample .= ($typeexample ? "/" : "")."2=Customer-Prospect"; } + if (!empty($conf->adherent->enabled)) { $typeexample .= ($typeexample ? "/" : "")."3=Member"; } $this->import_examplevalues_array[$r] = array( 'ca.label'=>"Supplier Category", 'ca.type'=>$typeexample, 'ca.description'=>"My Category description", 'ca.fk_parent' => '0' diff --git a/htdocs/core/modules/modExpedition.class.php b/htdocs/core/modules/modExpedition.class.php index 8d11989f02a..54fecd1a5af 100644 --- a/htdocs/core/modules/modExpedition.class.php +++ b/htdocs/core/modules/modExpedition.class.php @@ -291,7 +291,7 @@ class modExpedition extends DolibarrModules $this->export_sql_end[$r] = ' FROM '.MAIN_DB_PREFIX.'expedition as c'; $this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'expedition_extrafields as extra ON c.rowid = extra.fk_object,'; $this->export_sql_end[$r] .= ' '.MAIN_DB_PREFIX.'societe as s'; - if (!$user->rights->societe->client->voir) $this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'societe_commerciaux as sc ON sc.fk_soc = s.rowid'; + if (empty($user->rights->societe->client->voir)) $this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'societe_commerciaux as sc ON sc.fk_soc = s.rowid'; $this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_departements as d ON s.fk_departement = d.rowid'; $this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_country as co ON s.fk_pays = co.rowid,'; $this->export_sql_end[$r] .= ' '.MAIN_DB_PREFIX.'expeditiondet as ed'; @@ -306,7 +306,7 @@ class modExpedition extends DolibarrModules } $this->export_sql_end[$r] .= ' WHERE c.fk_soc = s.rowid AND c.rowid = ed.fk_expedition AND ed.fk_origin_line = cd.rowid'; $this->export_sql_end[$r] .= ' AND c.entity IN ('.getEntity('expedition').')'; - if (!$user->rights->societe->client->voir) $this->export_sql_end[$r] .= ' AND sc.fk_user = '.$user->id; + if (empty($user->rights->societe->client->voir)) $this->export_sql_end[$r] .= ' AND sc.fk_user = '.$user->id; } diff --git a/htdocs/core/modules/modProjet.class.php b/htdocs/core/modules/modProjet.class.php index fcd3e2e1e22..ff2edd3c787 100644 --- a/htdocs/core/modules/modProjet.class.php +++ b/htdocs/core/modules/modProjet.class.php @@ -138,16 +138,12 @@ class modProjet extends DolibarrModules $r++; // Boxes - $this->boxes = array(); - $r = 0; - $this->boxes[$r][1] = "box_project.php"; - $r++; - $this->boxes[$r][1] = "box_task.php"; - $r++; - $this->boxes[$r][1] = "box_validated_projects.php"; - $r++; - $this->boxes[$r][1] = "box_funnel_of_prospection.php"; - $r++; + $this->boxes = array( + 0=>array('file'=>'box_project.php', 'enabledbydefaulton'=>'Home'), + 1=>array('file'=>'box_task.php', 'enabledbydefaulton'=>'Home'), + 2=>array('file'=>'box_validated_projects.php', 'enabledbydefaulton'=>'Home'), + 3=>array('file'=>'box_funnel_of_prospection.php', 'enabledbydefaulton'=>'Home'), + ); // Permissions $this->rights = array(); diff --git a/htdocs/core/modules/modPropale.class.php b/htdocs/core/modules/modPropale.class.php index f06496e781a..f1de32bd1a9 100644 --- a/htdocs/core/modules/modPropale.class.php +++ b/htdocs/core/modules/modPropale.class.php @@ -241,7 +241,7 @@ class modPropale extends DolibarrModules $this->export_sql_end[$r] = ' FROM '.MAIN_DB_PREFIX.'societe as s '; $this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'societe_extrafields as extra4 ON s.rowid = extra4.fk_object'; - if (!$user->rights->societe->client->voir) $this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'societe_commerciaux as sc ON sc.fk_soc = s.rowid'; + if (empty($user->rights->societe->client->voir)) $this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'societe_commerciaux as sc ON sc.fk_soc = s.rowid'; $this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_country as co ON s.fk_pays = co.rowid,'; $this->export_sql_end[$r] .= ' '.MAIN_DB_PREFIX.'propal as c'; $this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'projet as pj ON c.fk_projet = pj.rowid'; @@ -254,7 +254,7 @@ class modPropale extends DolibarrModules $this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'product_extrafields as extra3 on p.rowid = extra3.fk_object'; $this->export_sql_end[$r] .= ' WHERE c.fk_soc = s.rowid AND c.rowid = cd.fk_propal'; $this->export_sql_end[$r] .= ' AND c.entity IN ('.getEntity('propal').')'; - if (!$user->rights->societe->client->voir) $this->export_sql_end[$r] .= ' AND sc.fk_user = '.$user->id; + if (empty($user->rights->societe->client->voir)) $this->export_sql_end[$r] .= ' AND sc.fk_user = '.$user->id; // Imports //-------- diff --git a/htdocs/core/modules/modSociete.class.php b/htdocs/core/modules/modSociete.class.php index c8bbc50e490..9c82306b641 100644 --- a/htdocs/core/modules/modSociete.class.php +++ b/htdocs/core/modules/modSociete.class.php @@ -122,20 +122,14 @@ class modSociete extends DolibarrModules $r++; // Boxes - $this->boxes = array(); - $r = 0; - $this->boxes[$r][1] = "box_clients.php"; - $r++; - $this->boxes[$r][1] = "box_prospect.php"; - $r++; - $this->boxes[$r][1] = "box_contacts.php"; - $r++; - $this->boxes[$r][1] = "box_activity.php"; - $this->boxes[$r][2] = '(WarningUsingThisBoxSlowDown)'; - $r++; - $this->boxes[$r][1] = "box_goodcustomers.php"; - $this->boxes[$r][2] = '(WarningUsingThisBoxSlowDown)'; - $r++; + $this->boxes = array( + 0=>array('file'=>'box_clients.php', 'enabledbydefaulton'=>'Home'), + 1=>array('file'=>'box_prospect.php', 'enabledbydefaulton'=>'Home'), + 2=>array('file'=>'box_contacts.php', 'enabledbydefaulton'=>'Home'), + 3=>array('file'=>'box_activity.php', 'enabledbydefaulton'=>'Home', 'note'=>'(WarningUsingThisBoxSlowDown)'), + 4=>array('file'=>'box_goodcustomers.php', 'enabledbydefaulton'=>'Home', 'note'=>'(WarningUsingThisBoxSlowDown)'), + ); + // Permissions $this->rights = array(); $this->rights_class = 'societe'; diff --git a/htdocs/core/modules/modTicket.class.php b/htdocs/core/modules/modTicket.class.php index d19327bcea7..def2a7f7e69 100644 --- a/htdocs/core/modules/modTicket.class.php +++ b/htdocs/core/modules/modTicket.class.php @@ -139,15 +139,10 @@ class modTicket extends DolibarrModules // Boxes // Add here list of php file(s) stored in core/boxes that contains class to show a box. - $this->boxes = array(); // Boxes list - $r = 0; - // Example: - - $this->boxes[$r][1] = "box_last_ticket"; - $r++; - - $this->boxes[$r][1] = "box_last_modified_ticket"; - $r++; + $this->boxes = array( + 0=>array('file'=>'box_last_ticket.php', 'enabledbydefaulton'=>'Home'), + 1=>array('file'=>'box_last_modified_ticket.php', 'enabledbydefaulton'=>'Home') + ); // Boxes list // Permissions $this->rights = array(); // Permission array used by this module diff --git a/htdocs/core/triggers/interface_50_modTicket_TicketEmail.class.php b/htdocs/core/triggers/interface_50_modTicket_TicketEmail.class.php index 3743d044e44..7bb8988e18e 100644 --- a/htdocs/core/triggers/interface_50_modTicket_TicketEmail.class.php +++ b/htdocs/core/triggers/interface_50_modTicket_TicketEmail.class.php @@ -132,8 +132,9 @@ class InterfaceTicketEmail extends DolibarrTriggers $langs->load('ticket'); // Send email to notification email - $sendto = $conf->global->TICKET_NOTIFICATION_EMAIL_TO; if (!empty($conf->global->TICKET_NOTIFICATION_EMAIL_TO) && empty($object->context['disableticketemail'])) { + $sendto = empty($conf->global->TICKET_NOTIFICATION_EMAIL_TO) ? '' : $conf->global->TICKET_NOTIFICATION_EMAIL_TO; + if ($sendto) { // Init to avoid errors $filepath = array(); @@ -246,7 +247,7 @@ class InterfaceTicketEmail extends DolibarrTriggers $message_customer .= '

'.$langs->trans('TicketNewEmailBodyInfosTrackUrlCustomer').' : '.$url_public_ticket.'

'; $message_customer .= '

'.$langs->trans('TicketEmailPleaseDoNotReplyToThisEmail').'

'; - $from = $conf->global->MAIN_INFO_SOCIETE_NOM.'<'.$conf->global->TICKET_NOTIFICATION_EMAIL_FROM.'>'; + $from = (empty($conf->global->MAIN_INFO_SOCIETE_NOM) ? '' : $conf->global->MAIN_INFO_SOCIETE_NOM.' ').'<'.$conf->global->TICKET_NOTIFICATION_EMAIL_FROM.'>'; $replyto = $from; $trackid = 'tic'.$object->id; diff --git a/htdocs/delivery/class/delivery.class.php b/htdocs/delivery/class/delivery.class.php index 394e86fdd78..9c1e9682a10 100644 --- a/htdocs/delivery/class/delivery.class.php +++ b/htdocs/delivery/class/delivery.class.php @@ -48,7 +48,7 @@ class Delivery extends CommonObject public $element = "delivery"; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Field with ID of parent key if this field has a parent */ public $fk_element = "fk_delivery"; @@ -58,7 +58,7 @@ class Delivery extends CommonObject public $table_element = "delivery"; /** - * @var int Name of subtable line + * @var string Name of subtable line */ public $table_element_line = "deliverydet"; diff --git a/htdocs/don/class/don.class.php b/htdocs/don/class/don.class.php index 042b22b3a1c..be9426415fe 100644 --- a/htdocs/don/class/don.class.php +++ b/htdocs/don/class/don.class.php @@ -47,7 +47,7 @@ class Don extends CommonObject public $table_element = 'don'; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Field with ID of parent key if this field has a parent */ public $fk_element = 'fk_donation'; diff --git a/htdocs/emailcollector/class/emailcollector.class.php b/htdocs/emailcollector/class/emailcollector.class.php index 1776e9855d5..2c55b11f8d2 100644 --- a/htdocs/emailcollector/class/emailcollector.class.php +++ b/htdocs/emailcollector/class/emailcollector.class.php @@ -52,13 +52,14 @@ class EmailCollector extends CommonObject * @var int Does emailcollector support extrafields ? 0=No, 1=Yes */ public $isextrafieldmanaged = 0; + /** * @var string String with name of icon for emailcollector. Must be the part after the 'object_' into object_emailcollector.png */ public $picto = 'generic'; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Field with ID of parent key if this field has a parent */ public $fk_element = 'fk_emailcollector'; @@ -158,7 +159,9 @@ class EmailCollector extends CommonObject */ public $date_creation; - + /** + * @var int timestamp + */ public $tms; /** @@ -171,6 +174,9 @@ class EmailCollector extends CommonObject */ public $fk_user_modif; + /** + * @var string import key + */ public $import_key; diff --git a/htdocs/emailcollector/class/emailcollectoraction.class.php b/htdocs/emailcollector/class/emailcollectoraction.class.php index 9b7c8bbca49..58aaf9efdb7 100644 --- a/htdocs/emailcollector/class/emailcollectoraction.class.php +++ b/htdocs/emailcollector/class/emailcollectoraction.class.php @@ -118,17 +118,17 @@ class EmailCollectorAction extends CommonObject // If this object has a subtable with lines // /** - // * @var int Name of subtable line + // * @var string Name of subtable line // */ //public $table_element_line = 'emailcollectoractiondet'; // /** - // * @var int Field with ID of parent key if this field has a parent + // * @var string Field with ID of parent key if this field has a parent // */ //public $fk_element = 'fk_emailcollectoraction'; // /** - // * @var int Name of subtable class that manage subtable lines + // * @var string Name of subtable class that manage subtable lines // */ //public $class_element_line = 'EmailcollectorActionline'; diff --git a/htdocs/expedition/class/expedition.class.php b/htdocs/expedition/class/expedition.class.php index 09a46f94bb8..e652dc5a3c1 100644 --- a/htdocs/expedition/class/expedition.class.php +++ b/htdocs/expedition/class/expedition.class.php @@ -55,7 +55,7 @@ class Expedition extends CommonObject public $element = "shipping"; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Field with ID of parent key if this field has a parent */ public $fk_element = "fk_expedition"; @@ -65,7 +65,7 @@ class Expedition extends CommonObject public $table_element = "expedition"; /** - * @var int Name of subtable line + * @var string Name of subtable line */ public $table_element_line = "expeditiondet"; diff --git a/htdocs/expensereport/class/expensereport.class.php b/htdocs/expensereport/class/expensereport.class.php index ac1d052486f..3ecba5d5286 100644 --- a/htdocs/expensereport/class/expensereport.class.php +++ b/htdocs/expensereport/class/expensereport.class.php @@ -44,7 +44,14 @@ class ExpenseReport extends CommonObject */ public $table_element = 'expensereport'; + /** + * @var string table element line name + */ public $table_element_line = 'expensereport_det'; + + /** + * @var string Fieldname with ID of parent key if this field has a parent + */ public $fk_element = 'fk_expensereport'; /** diff --git a/htdocs/expensereport/class/expensereport_ik.class.php b/htdocs/expensereport/class/expensereport_ik.class.php index 489b2671cf5..55af1eb00ed 100644 --- a/htdocs/expensereport/class/expensereport_ik.class.php +++ b/htdocs/expensereport/class/expensereport_ik.class.php @@ -40,7 +40,7 @@ class ExpenseReportIk extends CoreObject public $table_element = 'expensereport_ik'; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Field with ID of parent key if this field has a parent */ public $fk_element = 'fk_expense_ik'; diff --git a/htdocs/expensereport/class/expensereport_rule.class.php b/htdocs/expensereport/class/expensereport_rule.class.php index 7ed3a5ecb09..9a172cd7563 100644 --- a/htdocs/expensereport/class/expensereport_rule.class.php +++ b/htdocs/expensereport/class/expensereport_rule.class.php @@ -40,7 +40,7 @@ class ExpenseReportRule extends CoreObject public $table_element = 'expensereport_rules'; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Fieldname with ID of parent key if this field has a parent */ public $fk_element = 'fk_expense_rule'; diff --git a/htdocs/exports/class/export.class.php b/htdocs/exports/class/export.class.php index cf63b85879c..3ecece7e886 100644 --- a/htdocs/exports/class/export.class.php +++ b/htdocs/exports/class/export.class.php @@ -35,6 +35,8 @@ class Export */ public $db; + public $error; + public $array_export_code = array(); // Tableau de "idmodule_numlot" public $array_export_module = array(); // Tableau de "nom de modules" public $array_export_label = array(); // Tableau de "libelle de lots" @@ -139,11 +141,10 @@ class Export { $perm = $val; //print_r("$perm[0]-$perm[1]-$perm[2]
"); - if (!empty($perm[2])) - { - $bool = $user->rights->{$perm[0]}->{$perm[1]}->{$perm[2]}; + if (!empty($perm[2])) { + $bool = isset($user->rights->{$perm[0]}->{$perm[1]}->{$perm[2]}) ? $user->rights->{$perm[0]}->{$perm[1]}->{$perm[2]} : false; } else { - $bool = $user->rights->{$perm[0]}->{$perm[1]}; + $bool = isset($user->rights->{$perm[0]}->{$perm[1]}) ? $user->rights->{$perm[0]}->{$perm[1]} : false; } if ($perm[0] == 'user' && $user->admin) $bool = true; if (!$bool) break; @@ -185,14 +186,14 @@ class Export // Tableau des operations speciales sur champ $this->array_export_special[$i] = (!empty($module->export_special_array[$r]) ? $module->export_special_array[$r] : ''); // Array of examples - $this->array_export_examplevalues[$i] = $module->export_examplevalues_array[$r]; + $this->array_export_examplevalues[$i] = (!empty($module->export_examplevalues_array[$r]) ? $module->export_examplevalues_array[$r] : null); // Array of help tooltips $this->array_export_help[$i] = (!empty($module->export_help_array[$r]) ? $module->export_help_array[$r] : ''); // Requete sql du dataset $this->array_export_sql_start[$i] = $module->export_sql_start[$r]; $this->array_export_sql_end[$i] = $module->export_sql_end[$r]; - $this->array_export_sql_order[$i] = $module->export_sql_order[$r]; + $this->array_export_sql_order[$i] = (!empty($module->export_sql_order[$r]) ? $module->export_sql_order[$r] : null); //$this->array_export_sql[$i]=$module->export_sql[$r]; dol_syslog(get_class($this)."::load_arrays loaded for module ".$modulename." with index ".$i.", dataset=".$module->export_code[$r].", nb of fields=".(!empty($module->export_fields_code[$r]) ?count($module->export_fields_code[$r]) : '')); @@ -580,9 +581,12 @@ class Export if ($resql) { //$this->array_export_label[$indice] - if ($conf->global->EXPORT_PREFIX_SPEC) + if (!empty($conf->global->EXPORT_PREFIX_SPEC)) { $filename = $conf->global->EXPORT_PREFIX_SPEC."_".$datatoexport; - else $filename = "export_".$datatoexport; + } + else { + $filename = "export_".$datatoexport; + } $filename .= '.'.$objmodel->getDriverExtension(); $dirname = $conf->export->dir_temp.'/'.$user->id; @@ -598,7 +602,7 @@ class Export $objmodel->write_header($outputlangs); // Genere ligne de titre - $objmodel->write_title($this->array_export_fields[$indice], $array_selected, $outputlangs, $this->array_export_TypeFields[$indice]); + $objmodel->write_title($this->array_export_fields[$indice], $array_selected, $outputlangs, isset($this->array_export_TypeFields[$indice]) ? $this->array_export_TypeFields[$indice] : null); while ($obj = $this->db->fetch_object($resql)) { @@ -651,18 +655,20 @@ class Export } $obj->$alias = $remaintopay; } else { - // TODO FIXME Export of compute field does not work. $obj containt $obj->alias_field and formulat will contains $obj->field + // TODO FIXME + // Export of compute field does not work. $obj contains $obj->alias_field and formula may contains $obj->field + // Also the formula may contains objects of class that are not loaded. $computestring = $this->array_export_special[$indice][$key]; - $tmp = dol_eval($computestring, 1, 0); - $obj->$alias = $tmp; + //$tmp = dol_eval($computestring, 1, 0); + //$obj->$alias = $tmp; - $this->error = "ERROPNOTSUPPORTED. Operation ".$this->array_export_special[$indice][$key]." not supported. Export of 'computed' extrafields is not yet supported, please remove field."; + $this->error = "ERROPNOTSUPPORTED. Operation ".$computestring." not supported. Export of 'computed' extrafields is not yet supported, please remove field."; return -1; } } } // end of special operation processing - $objmodel->write_record($array_selected, $obj, $outputlangs, $this->array_export_TypeFields[$indice]); + $objmodel->write_record($array_selected, $obj, $outputlangs, isset($this->array_export_TypeFields[$indice]) ? $this->array_export_TypeFields[$indice] : null); } // Genere en-tete diff --git a/htdocs/fichinter/class/fichinter.class.php b/htdocs/fichinter/class/fichinter.class.php index 617da1963b8..7145605cb85 100644 --- a/htdocs/fichinter/class/fichinter.class.php +++ b/htdocs/fichinter/class/fichinter.class.php @@ -76,7 +76,7 @@ class Fichinter extends CommonObject public $table_element = 'fichinter'; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Field with ID of parent key if this field has a parent */ public $fk_element = 'fk_fichinter'; @@ -1435,7 +1435,7 @@ class FichinterLigne extends CommonObjectLine public $table_element = 'fichinterdet'; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Field with ID of parent key if this field has a parent */ public $fk_element = 'fk_fichinter'; diff --git a/htdocs/fichinter/class/fichinterrec.class.php b/htdocs/fichinter/class/fichinterrec.class.php index 377b97b2abb..046d35b62ce 100644 --- a/htdocs/fichinter/class/fichinterrec.class.php +++ b/htdocs/fichinter/class/fichinterrec.class.php @@ -41,6 +41,10 @@ class FichinterRec extends Fichinter public $element = 'fichinterrec'; public $table_element = 'fichinter_rec'; public $table_element_line = 'fichinter_rec'; + + /** + * @var string Fieldname with ID of parent key if this field has a parent + */ public $fk_element = 'fk_fichinter'; /** diff --git a/htdocs/fourn/class/fournisseur.commande.class.php b/htdocs/fourn/class/fournisseur.commande.class.php index b03faf7f629..c1be4db7be3 100644 --- a/htdocs/fourn/class/fournisseur.commande.class.php +++ b/htdocs/fourn/class/fournisseur.commande.class.php @@ -53,12 +53,12 @@ class CommandeFournisseur extends CommonOrder public $table_element = 'commande_fournisseur'; /** - * @var int Name of subtable line + * @var string Name of subtable line */ public $table_element_line = 'commande_fournisseurdet'; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Field with ID of parent key if this field has a parent */ public $fk_element = 'fk_commande'; diff --git a/htdocs/fourn/class/fournisseur.facture.class.php b/htdocs/fourn/class/fournisseur.facture.class.php index 09c74dd5d92..57bb5f4c822 100644 --- a/htdocs/fourn/class/fournisseur.facture.class.php +++ b/htdocs/fourn/class/fournisseur.facture.class.php @@ -57,12 +57,12 @@ class FactureFournisseur extends CommonInvoice public $table_element = 'facture_fourn'; /** - * @var int Name of subtable line + * @var string Name of subtable line */ public $table_element_line = 'facture_fourn_det'; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Field with ID of parent key if this field has a parent */ public $fk_element = 'fk_facture_fourn'; @@ -336,7 +336,7 @@ class FactureFournisseur extends CommonInvoice /** * Create supplier invoice into database * - * @param User $user object utilisateur qui cree + * @param User $user user object that creates * @return int Id invoice created if OK, < 0 if KO */ public function create($user) @@ -1251,8 +1251,8 @@ class FactureFournisseur extends CommonInvoice * Tag invoice as a payed invoice * * @param User $user Object user - * @param string $close_code Code renseigne si on classe a payee completement alors que paiement incomplet. Not implementd yet. - * @param string $close_note Commentaire renseigne si on classe a payee alors que paiement incomplet. Not implementd yet. + * @param string $close_code Code indicates whether the class has paid in full while payment is incomplete. Not implementd yet. + * @param string $close_note Comment informs if the class has been paid while payment is incomplete. Not implementd yet. * @return int <0 si ko, >0 si ok */ public function set_paid($user, $close_code = '', $close_note = '') @@ -1294,9 +1294,9 @@ class FactureFournisseur extends CommonInvoice // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps /** - * Tag la facture comme non payee completement + appel trigger BILL_UNPAYED - * Fonction utilisee quand un paiement prelevement est refuse, - * ou quand une facture annulee et reouverte. + * Tag the invoice as not fully paid + trigger call BILL_UNPAYED + * Function used when a direct debit payment is refused, + * or when the invoice was canceled and reopened. * * @param User $user Object user that change status * @return int <0 si ok, >0 si ok @@ -1579,25 +1579,25 @@ class FactureFournisseur extends CommonInvoice /** - * Ajoute une ligne de facture (associe a aucun produit/service predefini) - * Les parametres sont deja cense etre juste et avec valeurs finales a l'appel - * de cette methode. Aussi, pour le taux tva, il doit deja avoir ete defini - * par l'appelant par la methode get_default_tva(societe_vendeuse,societe_acheteuse,idprod) - * et le desc doit deja avoir la bonne valeur (a l'appelant de gerer le multilangue). + * Adds an invoice line (associated with no predefined product/service) + * The parameters are already supposed to be correct and with final values when calling + * this method. Also, for the VAT rate, it must already have been defined by the caller by + * by the get_default_tva method(vendor_company, buying company, idprod) and the desc must + * already have the right value (the caller has to manage the multilanguage). * - * @param string $desc Description de la ligne - * @param double $pu Prix unitaire (HT ou TTC selon price_base_type, > 0 even for credit note) + * @param string $desc Description of the line + * @param double $pu Unit price (HT or TTC according to price_base_type, > 0 even for credit note) * @param double $txtva Force Vat rate to use, -1 for auto. * @param double $txlocaltax1 LocalTax1 Rate * @param double $txlocaltax2 LocalTax2 Rate - * @param double $qty Quantite + * @param double $qty Quantity * @param int $fk_product Product/Service ID predefined * @param double $remise_percent Percentage discount of the line - * @param integer $date_start Date de debut de validite du service - * @param integer $date_end Date de fin de validite du service - * @param string $ventil Code de ventilation comptable - * @param int $info_bits Bits de type de lines - * @param string $price_base_type HT ou TTC + * @param integer $date_start Service start date + * @param integer $date_end Service expiry date + * @param string $ventil Accounting breakdown code + * @param int $info_bits Line type bits + * @param string $price_base_type HT or TTC * @param int $type Type of line (0=product, 1=service) * @param int $rang Position of line * @param int $notrigger Disable triggers @@ -2046,9 +2046,9 @@ class FactureFournisseur extends CommonInvoice /** - * Charge les informations d'ordre info dans l'objet facture + * Loads the info order information into the invoice object * - * @param int $id Id de la facture a charger + * @param int $id Id of the invoice to load * @return void */ public function info($id) @@ -2095,11 +2095,11 @@ class FactureFournisseur extends CommonInvoice // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps /** - * Renvoi liste des factures remplacables - * Statut validee ou abandonnee pour raison autre + non payee + aucun paiement + pas deja remplacee + * Return list of replaceable invoices + * Status valid or abandoned for other reason + not paid + no payment + not already replaced * - * @param int $socid Id societe - * @return array|int Tableau des factures ('id'=>id, 'ref'=>ref, 'status'=>status, 'paymentornot'=>0/1) + * @param int $socid Thirdparty id + * @return array|int Table of invoices ('id'=>id, 'ref'=>ref, 'status'=>status, 'paymentornot'=>0/1) * <0 if error */ public function list_replacable_supplier_invoices($socid = 0) @@ -2144,12 +2144,12 @@ class FactureFournisseur extends CommonInvoice // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps /** - * Renvoi liste des factures qualifiables pour correction par avoir - * Les factures qui respectent les regles suivantes sont retournees: - * (validee + paiement en cours) ou classee (payee completement ou payee partiellement) + pas deja remplacee + pas deja avoir + * Return list of qualifying invoices for correction by credit note + * Invoices that respect the following rules are returned: + * (validated + payment in progress) or classified (paid in full or paid in part) + not already replaced + not already having * - * @param int $socid Id societe - * @return array|int Tableau des factures ($id => array('ref'=>,'paymentornot'=>,'status'=>,'paye'=>) + * @param int $socid Thirdparty id + * @return array|int Table of invoices ($id => array('ref'=>,'paymentornot'=>,'status'=>,'paye'=>) * <0 if error */ public function list_qualified_avoir_supplier_invoices($socid = 0) diff --git a/htdocs/holiday/card.php b/htdocs/holiday/card.php index 11d3c70c4a8..4c88cdf53b3 100644 --- a/htdocs/holiday/card.php +++ b/htdocs/holiday/card.php @@ -148,11 +148,11 @@ if (empty($reshook)) $description = trim(GETPOST('description', 'restricthtml')); // Check that leave is for a user inside the hierarchy or advanced permission for all is set - if ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && empty($user->rights->expensereport->creer)) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && empty($user->rights->expensereport->writeall_advance))) { + if ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && empty($user->rights->holiday->write)) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && empty($user->rights->holiday->writeall_advance))) { $error++; setEventMessages($langs->trans("NotEnoughPermission"), null, 'errors'); } else { - if (empty($conf->global->MAIN_USE_ADVANCED_PERMS) || empty($user->rights->expensereport->writeall_advance)) { + if (empty($conf->global->MAIN_USE_ADVANCED_PERMS) || empty($user->rights->holiday->writeall_advance)) { if (!in_array($fuserid, $childids)) { $error++; setEventMessages($langs->trans("UserNotInHierachy"), null, 'errors'); @@ -403,7 +403,7 @@ if (empty($reshook)) { $object->fetch($id); - // Si brouillon et créateur + // If draft and owner of leave if ($object->statut == Holiday::STATUS_DRAFT && $cancreate) { $object->oldcopy = dol_clone($object); @@ -430,7 +430,8 @@ if (empty($reshook)) // From $expediteur = new User($db); $expediteur->fetch($object->fk_user); - $emailFrom = $expediteur->email; + //$emailFrom = $expediteur->email; Email of user can be an email into another company. Sending will fails, we must use the generic email. + $emailFrom = $conf->global->MAIN_MAIL_EMAIL_FROM; // Subject $societeName = $conf->global->MAIN_INFO_SOCIETE_NOM; @@ -441,6 +442,7 @@ if (empty($reshook)) // Content $message = $langs->transnoentitiesnoconv("Hello")." ".$destinataire->firstname.",\n"; $message .= "\n"; + $message .= $langs->transnoentities("HolidaysToValidateBody")."\n"; $delayForRequest = $object->getConfCP('delayForRequest'); @@ -525,7 +527,7 @@ if (empty($reshook)) { $object->fetch($id); - // Si statut en attente de validation et valideur = utilisateur + // If status is waiting approval and approver is also user if ($object->statut == Holiday::STATUS_VALIDATED && $user->id == $object->fk_validator) { $object->oldcopy = dol_clone($object); @@ -582,7 +584,8 @@ if (empty($reshook)) // From $expediteur = new User($db); $expediteur->fetch($object->fk_validator); - $emailFrom = $expediteur->email; + //$emailFrom = $expediteur->email; Email of user can be an email into another company. Sending will fails, we must use the generic email. + $emailFrom = $conf->global->MAIN_MAIL_EMAIL_FROM; // Subject $societeName = $conf->global->MAIN_INFO_SOCIETE_NOM; @@ -593,6 +596,7 @@ if (empty($reshook)) // Content $message = $langs->transnoentitiesnoconv("Hello")." ".$destinataire->firstname.",\n"; $message .= "\n"; + $message .= $langs->transnoentities("HolidaysValidatedBody", dol_print_date($object->date_debut, 'day'), dol_print_date($object->date_fin, 'day'))."\n"; $message .= "- ".$langs->transnoentitiesnoconv("ValidatedBy")." : ".dolGetFirstLastname($expediteur->firstname, $expediteur->lastname)."\n"; @@ -666,7 +670,8 @@ if (empty($reshook)) // From $expediteur = new User($db); $expediteur->fetch($object->fk_validator); - $emailFrom = $expediteur->email; + //$emailFrom = $expediteur->email; Email of user can be an email into another company. Sending will fails, we must use the generic email. + $emailFrom = $conf->global->MAIN_MAIL_EMAIL_FROM; // Subject $societeName = $conf->global->MAIN_INFO_SOCIETE_NOM; @@ -677,6 +682,7 @@ if (empty($reshook)) // Content $message = $langs->transnoentitiesnoconv("Hello")." ".$destinataire->firstname.",\n"; $message .= "\n"; + $message .= $langs->transnoentities("HolidaysRefusedBody", dol_print_date($object->date_debut, 'day'), dol_print_date($object->date_fin, 'day'))."\n"; $message .= GETPOST('detail_refuse', 'alpha')."\n\n"; @@ -813,7 +819,8 @@ if (empty($reshook)) // From $expediteur = new User($db); $expediteur->fetch($object->fk_user_cancel); - $emailFrom = $expediteur->email; + //$emailFrom = $expediteur->email; Email of user can be an email into another company. Sending will fails, we must use the generic email. + $emailFrom = $conf->global->MAIN_MAIL_EMAIL_FROM; // Subject $societeName = $conf->global->MAIN_INFO_SOCIETE_NOM; @@ -962,8 +969,7 @@ if ((empty($id) && empty($ref)) || $action == 'create' || $action == 'add') print ''."\n"; print ''."\n"; - if (empty($conf->global->HOLIDAY_HIDE_BALANCE)) - { + if (empty($conf->global->HOLIDAY_HIDE_BALANCE)) { print dol_get_fiche_head('', '', '', -1); $out = ''; @@ -973,15 +979,14 @@ if ((empty($id) && empty($ref)) || $action == 'create' || $action == 'add') $nb_type = $object->getCPforUser($user->id, $val['rowid']); $nb_holiday += $nb_type; - $out .= ' - '.($langs->trans($val['code']) != $val['code'] ? $langs->trans($val['code']) : $val['label']).': '.($nb_type ?price2num($nb_type) : 0).'
'; + $out .= ' - '.($langs->trans($val['code']) != $val['code'] ? $langs->trans($val['code']) : $val['label']).': '.($nb_type ? price2num($nb_type) : 0).'
'; //$out .= ' - '.$val['label'].': '.($nb_type ?price2num($nb_type) : 0).'
'; } print $langs->trans('SoldeCPUser', round($nb_holiday, 5)).'
'; print $out; print dol_get_fiche_end(); - } elseif (!is_numeric($conf->global->HOLIDAY_HIDE_BALANCE)) - { + } elseif (!is_numeric($conf->global->HOLIDAY_HIDE_BALANCE)) { print $langs->trans($conf->global->HOLIDAY_HIDE_BALANCE).'
'; } diff --git a/htdocs/holiday/class/holiday.class.php b/htdocs/holiday/class/holiday.class.php index 4e1272a8f69..2030ab1d636 100644 --- a/htdocs/holiday/class/holiday.class.php +++ b/htdocs/holiday/class/holiday.class.php @@ -50,7 +50,7 @@ class Holiday extends CommonObject public $ismultientitymanaged = 0; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Field with ID of parent key if this field has a parent */ public $fk_element = 'fk_holiday'; diff --git a/htdocs/hrm/class/establishment.class.php b/htdocs/hrm/class/establishment.class.php index 02083ccd819..dc97787ae6e 100644 --- a/htdocs/hrm/class/establishment.class.php +++ b/htdocs/hrm/class/establishment.class.php @@ -40,12 +40,12 @@ class Establishment extends CommonObject public $table_element = 'establishment'; /** - * @var int Name of subtable line + * @var string Name of subtable line */ public $table_element_line = ''; /** - * @var int Field with ID of parent key if this field has a parent + * @var string Field with ID of parent key if this field has a parent */ public $fk_element = 'fk_establishment'; diff --git a/htdocs/hrm/index.php b/htdocs/hrm/index.php index 3ec2a3b898f..f0bbb442acc 100644 --- a/htdocs/hrm/index.php +++ b/htdocs/hrm/index.php @@ -153,7 +153,7 @@ if (!empty($conf->holiday->enabled)) { $nb_type = $holiday->getCPforUser($user->id, $val['rowid']); $nb_holiday += $nb_type; - $out .= ' - '.$val['label'].': '.($nb_type ?price2num($nb_type) : 0).'
'; + $out .= ' - '.($langs->trans($val['code']) != $val['code'] ? $langs->trans($val['code']) : $val['label']).': '.($nb_type ? price2num($nb_type) : 0).'
'; } print $langs->trans('SoldeCPUser', round($nb_holiday, 5)).'
'; print $out; diff --git a/htdocs/includes/mike42/escpos-php/.gitignore b/htdocs/includes/mike42/escpos-php/.gitignore index 8632f891ad4..2b6e1a8d17c 100644 --- a/htdocs/includes/mike42/escpos-php/.gitignore +++ b/htdocs/includes/mike42/escpos-php/.gitignore @@ -4,9 +4,7 @@ .buildpath # doxygen files -doc/html -doc/latex -doc/doxygen_sqlite3.db +doc # composer files vendor/ diff --git a/htdocs/includes/mike42/escpos-php/autoload.php b/htdocs/includes/mike42/escpos-php/autoload.php index 47ed7d9e9c3..7779486b824 100644 --- a/htdocs/includes/mike42/escpos-php/autoload.php +++ b/htdocs/includes/mike42/escpos-php/autoload.php @@ -1,26 +1,26 @@ all.xml - -clean: - rm --preserve-root -Rf html latex xml doxygen_sqlite3.db all.xml warnings.log - diff --git a/htdocs/includes/mike42/escpos-php/doc/escpos.doxyfile b/htdocs/includes/mike42/escpos-php/doc/escpos.doxyfile deleted file mode 100644 index 0c48656e15b..00000000000 --- a/htdocs/includes/mike42/escpos-php/doc/escpos.doxyfile +++ /dev/null @@ -1,2352 +0,0 @@ -# Doxyfile 1.8.8 - -# This file describes the settings to be used by the documentation system -# doxygen (www.doxygen.org) for a project. -# -# All text after a double hash (##) is considered a comment and is placed in -# front of the TAG it is preceding. -# -# All text after a single hash (#) is considered a comment and will be ignored. -# The format is: -# TAG = value [value, ...] -# For lists, items can also be appended using: -# TAG += value [value, ...] -# Values that contain spaces should be placed between quotes (\" \"). - -#--------------------------------------------------------------------------- -# Project related configuration options -#--------------------------------------------------------------------------- - -# This tag specifies the encoding used for all characters in the config file -# that follow. The default is UTF-8 which is also the encoding used for all text -# before the first occurrence of this tag. Doxygen uses libiconv (or the iconv -# built into libc) for the transcoding. See http://www.gnu.org/software/libiconv -# for the list of possible encodings. -# The default value is: UTF-8. - -DOXYFILE_ENCODING = UTF-8 - -# The PROJECT_NAME tag is a single word (or a sequence of words surrounded by -# double-quotes, unless you are using Doxywizard) that should identify the -# project for which the documentation is generated. This name is used in the -# title of most generated pages and in a few other places. -# The default value is: My Project. - -PROJECT_NAME = "escpos-php" - -# The PROJECT_NUMBER tag can be used to enter a project or revision number. This -# could be handy for archiving the generated documentation or if some version -# control system is used. - -PROJECT_NUMBER = - -# Using the PROJECT_BRIEF tag one can provide an optional one line description -# for a project that appears at the top of each page and should give viewer a -# quick idea about the purpose of the project. Keep the description short. - -PROJECT_BRIEF = - -# With the PROJECT_LOGO tag one can specify an logo or icon that is included in -# the documentation. The maximum height of the logo should not exceed 55 pixels -# and the maximum width should not exceed 200 pixels. Doxygen will copy the logo -# to the output directory. - -PROJECT_LOGO = ../example/resources/escpos-php-small.png - -# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) path -# into which the generated documentation will be written. If a relative path is -# entered, it will be relative to the location where doxygen was started. If -# left blank the current directory will be used. - -OUTPUT_DIRECTORY = - -# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create 4096 sub- -# directories (in 2 levels) under the output directory of each output format and -# will distribute the generated files over these directories. Enabling this -# option can be useful when feeding doxygen a huge amount of source files, where -# putting all generated files in the same directory would otherwise causes -# performance problems for the file system. -# The default value is: NO. - -CREATE_SUBDIRS = NO - -# If the ALLOW_UNICODE_NAMES tag is set to YES, doxygen will allow non-ASCII -# characters to appear in the names of generated files. If set to NO, non-ASCII -# characters will be escaped, for example _xE3_x81_x84 will be used for Unicode -# U+3044. -# The default value is: NO. - -ALLOW_UNICODE_NAMES = NO - -# The OUTPUT_LANGUAGE tag is used to specify the language in which all -# documentation generated by doxygen is written. Doxygen will use this -# information to generate all constant output in the proper language. -# Possible values are: Afrikaans, Arabic, Armenian, Brazilian, Catalan, Chinese, -# Chinese-Traditional, Croatian, Czech, Danish, Dutch, English (United States), -# Esperanto, Farsi (Persian), Finnish, French, German, Greek, Hungarian, -# Indonesian, Italian, Japanese, Japanese-en (Japanese with English messages), -# Korean, Korean-en (Korean with English messages), Latvian, Lithuanian, -# Macedonian, Norwegian, Persian (Farsi), Polish, Portuguese, Romanian, Russian, -# Serbian, Serbian-Cyrillic, Slovak, Slovene, Spanish, Swedish, Turkish, -# Ukrainian and Vietnamese. -# The default value is: English. - -OUTPUT_LANGUAGE = English - -# If the BRIEF_MEMBER_DESC tag is set to YES doxygen will include brief member -# descriptions after the members that are listed in the file and class -# documentation (similar to Javadoc). Set to NO to disable this. -# The default value is: YES. - -BRIEF_MEMBER_DESC = YES - -# If the REPEAT_BRIEF tag is set to YES doxygen will prepend the brief -# description of a member or function before the detailed description -# -# Note: If both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the -# brief descriptions will be completely suppressed. -# The default value is: YES. - -REPEAT_BRIEF = YES - -# This tag implements a quasi-intelligent brief description abbreviator that is -# used to form the text in various listings. Each string in this list, if found -# as the leading text of the brief description, will be stripped from the text -# and the result, after processing the whole list, is used as the annotated -# text. Otherwise, the brief description is used as-is. If left blank, the -# following values are used ($name is automatically replaced with the name of -# the entity):The $name class, The $name widget, The $name file, is, provides, -# specifies, contains, represents, a, an and the. - -ABBREVIATE_BRIEF = - -# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then -# doxygen will generate a detailed section even if there is only a brief -# description. -# The default value is: NO. - -ALWAYS_DETAILED_SEC = NO - -# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all -# inherited members of a class in the documentation of that class as if those -# members were ordinary class members. Constructors, destructors and assignment -# operators of the base classes will not be shown. -# The default value is: NO. - -INLINE_INHERITED_MEMB = NO - -# If the FULL_PATH_NAMES tag is set to YES doxygen will prepend the full path -# before files name in the file list and in the header files. If set to NO the -# shortest path that makes the file name unique will be used -# The default value is: YES. - -FULL_PATH_NAMES = YES - -# The STRIP_FROM_PATH tag can be used to strip a user-defined part of the path. -# Stripping is only done if one of the specified strings matches the left-hand -# part of the path. The tag can be used to show relative paths in the file list. -# If left blank the directory from which doxygen is run is used as the path to -# strip. -# -# Note that you can specify absolute paths here, but also relative paths, which -# will be relative from the directory where doxygen is started. -# This tag requires that the tag FULL_PATH_NAMES is set to YES. - -STRIP_FROM_PATH = - -# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of the -# path mentioned in the documentation of a class, which tells the reader which -# header file to include in order to use a class. If left blank only the name of -# the header file containing the class definition is used. Otherwise one should -# specify the list of include paths that are normally passed to the compiler -# using the -I flag. - -STRIP_FROM_INC_PATH = - -# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter (but -# less readable) file names. This can be useful is your file systems doesn't -# support long names like on DOS, Mac, or CD-ROM. -# The default value is: NO. - -SHORT_NAMES = NO - -# If the JAVADOC_AUTOBRIEF tag is set to YES then doxygen will interpret the -# first line (until the first dot) of a Javadoc-style comment as the brief -# description. If set to NO, the Javadoc-style will behave just like regular Qt- -# style comments (thus requiring an explicit @brief command for a brief -# description.) -# The default value is: NO. - -JAVADOC_AUTOBRIEF = NO - -# If the QT_AUTOBRIEF tag is set to YES then doxygen will interpret the first -# line (until the first dot) of a Qt-style comment as the brief description. If -# set to NO, the Qt-style will behave just like regular Qt-style comments (thus -# requiring an explicit \brief command for a brief description.) -# The default value is: NO. - -QT_AUTOBRIEF = NO - -# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make doxygen treat a -# multi-line C++ special comment block (i.e. a block of //! or /// comments) as -# a brief description. This used to be the default behavior. The new default is -# to treat a multi-line C++ comment block as a detailed description. Set this -# tag to YES if you prefer the old behavior instead. -# -# Note that setting this tag to YES also means that rational rose comments are -# not recognized any more. -# The default value is: NO. - -MULTILINE_CPP_IS_BRIEF = NO - -# If the INHERIT_DOCS tag is set to YES then an undocumented member inherits the -# documentation from any documented member that it re-implements. -# The default value is: YES. - -INHERIT_DOCS = YES - -# If the SEPARATE_MEMBER_PAGES tag is set to YES, then doxygen will produce a -# new page for each member. If set to NO, the documentation of a member will be -# part of the file/class/namespace that contains it. -# The default value is: NO. - -SEPARATE_MEMBER_PAGES = NO - -# The TAB_SIZE tag can be used to set the number of spaces in a tab. Doxygen -# uses this value to replace tabs by spaces in code fragments. -# Minimum value: 1, maximum value: 16, default value: 4. - -TAB_SIZE = 4 - -# This tag can be used to specify a number of aliases that act as commands in -# the documentation. An alias has the form: -# name=value -# For example adding -# "sideeffect=@par Side Effects:\n" -# will allow you to put the command \sideeffect (or @sideeffect) in the -# documentation, which will result in a user-defined paragraph with heading -# "Side Effects:". You can put \n's in the value part of an alias to insert -# newlines. - -ALIASES = - -# This tag can be used to specify a number of word-keyword mappings (TCL only). -# A mapping has the form "name=value". For example adding "class=itcl::class" -# will allow you to use the command class in the itcl::class meaning. - -TCL_SUBST = - -# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C sources -# only. Doxygen will then generate output that is more tailored for C. For -# instance, some of the names that are used will be different. The list of all -# members will be omitted, etc. -# The default value is: NO. - -OPTIMIZE_OUTPUT_FOR_C = NO - -# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java or -# Python sources only. Doxygen will then generate output that is more tailored -# for that language. For instance, namespaces will be presented as packages, -# qualified scopes will look different, etc. -# The default value is: NO. - -OPTIMIZE_OUTPUT_JAVA = NO - -# Set the OPTIMIZE_FOR_FORTRAN tag to YES if your project consists of Fortran -# sources. Doxygen will then generate output that is tailored for Fortran. -# The default value is: NO. - -OPTIMIZE_FOR_FORTRAN = NO - -# Set the OPTIMIZE_OUTPUT_VHDL tag to YES if your project consists of VHDL -# sources. Doxygen will then generate output that is tailored for VHDL. -# The default value is: NO. - -OPTIMIZE_OUTPUT_VHDL = NO - -# Doxygen selects the parser to use depending on the extension of the files it -# parses. With this tag you can assign which parser to use for a given -# extension. Doxygen has a built-in mapping, but you can override or extend it -# using this tag. The format is ext=language, where ext is a file extension, and -# language is one of the parsers supported by doxygen: IDL, Java, Javascript, -# C#, C, C++, D, PHP, Objective-C, Python, Fortran (fixed format Fortran: -# FortranFixed, free formatted Fortran: FortranFree, unknown formatted Fortran: -# Fortran. In the later case the parser tries to guess whether the code is fixed -# or free formatted code, this is the default for Fortran type files), VHDL. For -# instance to make doxygen treat .inc files as Fortran files (default is PHP), -# and .f files as C (default is Fortran), use: inc=Fortran f=C. -# -# Note For files without extension you can use no_extension as a placeholder. -# -# Note that for custom extensions you also need to set FILE_PATTERNS otherwise -# the files are not read by doxygen. - -EXTENSION_MAPPING = - -# If the MARKDOWN_SUPPORT tag is enabled then doxygen pre-processes all comments -# according to the Markdown format, which allows for more readable -# documentation. See http://daringfireball.net/projects/markdown/ for details. -# The output of markdown processing is further processed by doxygen, so you can -# mix doxygen, HTML, and XML commands with Markdown formatting. Disable only in -# case of backward compatibilities issues. -# The default value is: YES. - -MARKDOWN_SUPPORT = YES - -# When enabled doxygen tries to link words that correspond to documented -# classes, or namespaces to their corresponding documentation. Such a link can -# be prevented in individual cases by by putting a % sign in front of the word -# or globally by setting AUTOLINK_SUPPORT to NO. -# The default value is: YES. - -AUTOLINK_SUPPORT = YES - -# If you use STL classes (i.e. std::string, std::vector, etc.) but do not want -# to include (a tag file for) the STL sources as input, then you should set this -# tag to YES in order to let doxygen match functions declarations and -# definitions whose arguments contain STL classes (e.g. func(std::string); -# versus func(std::string) {}). This also make the inheritance and collaboration -# diagrams that involve STL classes more complete and accurate. -# The default value is: NO. - -BUILTIN_STL_SUPPORT = NO - -# If you use Microsoft's C++/CLI language, you should set this option to YES to -# enable parsing support. -# The default value is: NO. - -CPP_CLI_SUPPORT = NO - -# Set the SIP_SUPPORT tag to YES if your project consists of sip (see: -# http://www.riverbankcomputing.co.uk/software/sip/intro) sources only. Doxygen -# will parse them like normal C++ but will assume all classes use public instead -# of private inheritance when no explicit protection keyword is present. -# The default value is: NO. - -SIP_SUPPORT = NO - -# For Microsoft's IDL there are propget and propput attributes to indicate -# getter and setter methods for a property. Setting this option to YES will make -# doxygen to replace the get and set methods by a property in the documentation. -# This will only work if the methods are indeed getting or setting a simple -# type. If this is not the case, or you want to show the methods anyway, you -# should set this option to NO. -# The default value is: YES. - -IDL_PROPERTY_SUPPORT = YES - -# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC -# tag is set to YES, then doxygen will reuse the documentation of the first -# member in the group (if any) for the other members of the group. By default -# all members of a group must be documented explicitly. -# The default value is: NO. - -DISTRIBUTE_GROUP_DOC = NO - -# Set the SUBGROUPING tag to YES to allow class member groups of the same type -# (for instance a group of public functions) to be put as a subgroup of that -# type (e.g. under the Public Functions section). Set it to NO to prevent -# subgrouping. Alternatively, this can be done per class using the -# \nosubgrouping command. -# The default value is: YES. - -SUBGROUPING = YES - -# When the INLINE_GROUPED_CLASSES tag is set to YES, classes, structs and unions -# are shown inside the group in which they are included (e.g. using \ingroup) -# instead of on a separate page (for HTML and Man pages) or section (for LaTeX -# and RTF). -# -# Note that this feature does not work in combination with -# SEPARATE_MEMBER_PAGES. -# The default value is: NO. - -INLINE_GROUPED_CLASSES = NO - -# When the INLINE_SIMPLE_STRUCTS tag is set to YES, structs, classes, and unions -# with only public data fields or simple typedef fields will be shown inline in -# the documentation of the scope in which they are defined (i.e. file, -# namespace, or group documentation), provided this scope is documented. If set -# to NO, structs, classes, and unions are shown on a separate page (for HTML and -# Man pages) or section (for LaTeX and RTF). -# The default value is: NO. - -INLINE_SIMPLE_STRUCTS = NO - -# When TYPEDEF_HIDES_STRUCT tag is enabled, a typedef of a struct, union, or -# enum is documented as struct, union, or enum with the name of the typedef. So -# typedef struct TypeS {} TypeT, will appear in the documentation as a struct -# with name TypeT. When disabled the typedef will appear as a member of a file, -# namespace, or class. And the struct will be named TypeS. This can typically be -# useful for C code in case the coding convention dictates that all compound -# types are typedef'ed and only the typedef is referenced, never the tag name. -# The default value is: NO. - -TYPEDEF_HIDES_STRUCT = NO - -# The size of the symbol lookup cache can be set using LOOKUP_CACHE_SIZE. This -# cache is used to resolve symbols given their name and scope. Since this can be -# an expensive process and often the same symbol appears multiple times in the -# code, doxygen keeps a cache of pre-resolved symbols. If the cache is too small -# doxygen will become slower. If the cache is too large, memory is wasted. The -# cache size is given by this formula: 2^(16+LOOKUP_CACHE_SIZE). The valid range -# is 0..9, the default is 0, corresponding to a cache size of 2^16=65536 -# symbols. At the end of a run doxygen will report the cache usage and suggest -# the optimal cache size from a speed point of view. -# Minimum value: 0, maximum value: 9, default value: 0. - -LOOKUP_CACHE_SIZE = 0 - -#--------------------------------------------------------------------------- -# Build related configuration options -#--------------------------------------------------------------------------- - -# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in -# documentation are documented, even if no documentation was available. Private -# class members and static file members will be hidden unless the -# EXTRACT_PRIVATE respectively EXTRACT_STATIC tags are set to YES. -# Note: This will also disable the warnings about undocumented members that are -# normally produced when WARNINGS is set to YES. -# The default value is: NO. - -EXTRACT_ALL = NO - -# If the EXTRACT_PRIVATE tag is set to YES all private members of a class will -# be included in the documentation. -# The default value is: NO. - -EXTRACT_PRIVATE = NO - -# If the EXTRACT_PACKAGE tag is set to YES all members with package or internal -# scope will be included in the documentation. -# The default value is: NO. - -EXTRACT_PACKAGE = NO - -# If the EXTRACT_STATIC tag is set to YES all static members of a file will be -# included in the documentation. -# The default value is: NO. - -EXTRACT_STATIC = NO - -# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) defined -# locally in source files will be included in the documentation. If set to NO -# only classes defined in header files are included. Does not have any effect -# for Java sources. -# The default value is: YES. - -EXTRACT_LOCAL_CLASSES = YES - -# This flag is only useful for Objective-C code. When set to YES local methods, -# which are defined in the implementation section but not in the interface are -# included in the documentation. If set to NO only methods in the interface are -# included. -# The default value is: NO. - -EXTRACT_LOCAL_METHODS = NO - -# If this flag is set to YES, the members of anonymous namespaces will be -# extracted and appear in the documentation as a namespace called -# 'anonymous_namespace{file}', where file will be replaced with the base name of -# the file that contains the anonymous namespace. By default anonymous namespace -# are hidden. -# The default value is: NO. - -EXTRACT_ANON_NSPACES = NO - -# If the HIDE_UNDOC_MEMBERS tag is set to YES, doxygen will hide all -# undocumented members inside documented classes or files. If set to NO these -# members will be included in the various overviews, but no documentation -# section is generated. This option has no effect if EXTRACT_ALL is enabled. -# The default value is: NO. - -HIDE_UNDOC_MEMBERS = NO - -# If the HIDE_UNDOC_CLASSES tag is set to YES, doxygen will hide all -# undocumented classes that are normally visible in the class hierarchy. If set -# to NO these classes will be included in the various overviews. This option has -# no effect if EXTRACT_ALL is enabled. -# The default value is: NO. - -HIDE_UNDOC_CLASSES = NO - -# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, doxygen will hide all friend -# (class|struct|union) declarations. If set to NO these declarations will be -# included in the documentation. -# The default value is: NO. - -HIDE_FRIEND_COMPOUNDS = NO - -# If the HIDE_IN_BODY_DOCS tag is set to YES, doxygen will hide any -# documentation blocks found inside the body of a function. If set to NO these -# blocks will be appended to the function's detailed documentation block. -# The default value is: NO. - -HIDE_IN_BODY_DOCS = NO - -# The INTERNAL_DOCS tag determines if documentation that is typed after a -# \internal command is included. If the tag is set to NO then the documentation -# will be excluded. Set it to YES to include the internal documentation. -# The default value is: NO. - -INTERNAL_DOCS = NO - -# If the CASE_SENSE_NAMES tag is set to NO then doxygen will only generate file -# names in lower-case letters. If set to YES upper-case letters are also -# allowed. This is useful if you have classes or files whose names only differ -# in case and if your file system supports case sensitive file names. Windows -# and Mac users are advised to set this option to NO. -# The default value is: system dependent. - -CASE_SENSE_NAMES = YES - -# If the HIDE_SCOPE_NAMES tag is set to NO then doxygen will show members with -# their full class and namespace scopes in the documentation. If set to YES the -# scope will be hidden. -# The default value is: NO. - -HIDE_SCOPE_NAMES = NO - -# If the SHOW_INCLUDE_FILES tag is set to YES then doxygen will put a list of -# the files that are included by a file in the documentation of that file. -# The default value is: YES. - -SHOW_INCLUDE_FILES = YES - -# If the SHOW_GROUPED_MEMB_INC tag is set to YES then Doxygen will add for each -# grouped member an include statement to the documentation, telling the reader -# which file to include in order to use the member. -# The default value is: NO. - -SHOW_GROUPED_MEMB_INC = NO - -# If the FORCE_LOCAL_INCLUDES tag is set to YES then doxygen will list include -# files with double quotes in the documentation rather than with sharp brackets. -# The default value is: NO. - -FORCE_LOCAL_INCLUDES = NO - -# If the INLINE_INFO tag is set to YES then a tag [inline] is inserted in the -# documentation for inline members. -# The default value is: YES. - -INLINE_INFO = YES - -# If the SORT_MEMBER_DOCS tag is set to YES then doxygen will sort the -# (detailed) documentation of file and class members alphabetically by member -# name. If set to NO the members will appear in declaration order. -# The default value is: YES. - -SORT_MEMBER_DOCS = YES - -# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the brief -# descriptions of file, namespace and class members alphabetically by member -# name. If set to NO the members will appear in declaration order. Note that -# this will also influence the order of the classes in the class list. -# The default value is: NO. - -SORT_BRIEF_DOCS = NO - -# If the SORT_MEMBERS_CTORS_1ST tag is set to YES then doxygen will sort the -# (brief and detailed) documentation of class members so that constructors and -# destructors are listed first. If set to NO the constructors will appear in the -# respective orders defined by SORT_BRIEF_DOCS and SORT_MEMBER_DOCS. -# Note: If SORT_BRIEF_DOCS is set to NO this option is ignored for sorting brief -# member documentation. -# Note: If SORT_MEMBER_DOCS is set to NO this option is ignored for sorting -# detailed member documentation. -# The default value is: NO. - -SORT_MEMBERS_CTORS_1ST = NO - -# If the SORT_GROUP_NAMES tag is set to YES then doxygen will sort the hierarchy -# of group names into alphabetical order. If set to NO the group names will -# appear in their defined order. -# The default value is: NO. - -SORT_GROUP_NAMES = NO - -# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be sorted by -# fully-qualified names, including namespaces. If set to NO, the class list will -# be sorted only by class name, not including the namespace part. -# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES. -# Note: This option applies only to the class list, not to the alphabetical -# list. -# The default value is: NO. - -SORT_BY_SCOPE_NAME = NO - -# If the STRICT_PROTO_MATCHING option is enabled and doxygen fails to do proper -# type resolution of all parameters of a function it will reject a match between -# the prototype and the implementation of a member function even if there is -# only one candidate or it is obvious which candidate to choose by doing a -# simple string match. By disabling STRICT_PROTO_MATCHING doxygen will still -# accept a match between prototype and implementation in such cases. -# The default value is: NO. - -STRICT_PROTO_MATCHING = NO - -# The GENERATE_TODOLIST tag can be used to enable ( YES) or disable ( NO) the -# todo list. This list is created by putting \todo commands in the -# documentation. -# The default value is: YES. - -GENERATE_TODOLIST = YES - -# The GENERATE_TESTLIST tag can be used to enable ( YES) or disable ( NO) the -# test list. This list is created by putting \test commands in the -# documentation. -# The default value is: YES. - -GENERATE_TESTLIST = YES - -# The GENERATE_BUGLIST tag can be used to enable ( YES) or disable ( NO) the bug -# list. This list is created by putting \bug commands in the documentation. -# The default value is: YES. - -GENERATE_BUGLIST = YES - -# The GENERATE_DEPRECATEDLIST tag can be used to enable ( YES) or disable ( NO) -# the deprecated list. This list is created by putting \deprecated commands in -# the documentation. -# The default value is: YES. - -GENERATE_DEPRECATEDLIST= YES - -# The ENABLED_SECTIONS tag can be used to enable conditional documentation -# sections, marked by \if ... \endif and \cond -# ... \endcond blocks. - -ENABLED_SECTIONS = - -# The MAX_INITIALIZER_LINES tag determines the maximum number of lines that the -# initial value of a variable or macro / define can have for it to appear in the -# documentation. If the initializer consists of more lines than specified here -# it will be hidden. Use a value of 0 to hide initializers completely. The -# appearance of the value of individual variables and macros / defines can be -# controlled using \showinitializer or \hideinitializer command in the -# documentation regardless of this setting. -# Minimum value: 0, maximum value: 10000, default value: 30. - -MAX_INITIALIZER_LINES = 30 - -# Set the SHOW_USED_FILES tag to NO to disable the list of files generated at -# the bottom of the documentation of classes and structs. If set to YES the list -# will mention the files that were used to generate the documentation. -# The default value is: YES. - -SHOW_USED_FILES = YES - -# Set the SHOW_FILES tag to NO to disable the generation of the Files page. This -# will remove the Files entry from the Quick Index and from the Folder Tree View -# (if specified). -# The default value is: YES. - -SHOW_FILES = YES - -# Set the SHOW_NAMESPACES tag to NO to disable the generation of the Namespaces -# page. This will remove the Namespaces entry from the Quick Index and from the -# Folder Tree View (if specified). -# The default value is: YES. - -SHOW_NAMESPACES = YES - -# The FILE_VERSION_FILTER tag can be used to specify a program or script that -# doxygen should invoke to get the current version for each file (typically from -# the version control system). Doxygen will invoke the program by executing (via -# popen()) the command command input-file, where command is the value of the -# FILE_VERSION_FILTER tag, and input-file is the name of an input file provided -# by doxygen. Whatever the program writes to standard output is used as the file -# version. For an example see the documentation. - -FILE_VERSION_FILTER = - -# The LAYOUT_FILE tag can be used to specify a layout file which will be parsed -# by doxygen. The layout file controls the global structure of the generated -# output files in an output format independent way. To create the layout file -# that represents doxygen's defaults, run doxygen with the -l option. You can -# optionally specify a file name after the option, if omitted DoxygenLayout.xml -# will be used as the name of the layout file. -# -# Note that if you run doxygen from a directory containing a file called -# DoxygenLayout.xml, doxygen will parse it automatically even if the LAYOUT_FILE -# tag is left empty. - -LAYOUT_FILE = - -# The CITE_BIB_FILES tag can be used to specify one or more bib files containing -# the reference definitions. This must be a list of .bib files. The .bib -# extension is automatically appended if omitted. This requires the bibtex tool -# to be installed. See also http://en.wikipedia.org/wiki/BibTeX for more info. -# For LaTeX the style of the bibliography can be controlled using -# LATEX_BIB_STYLE. To use this feature you need bibtex and perl available in the -# search path. See also \cite for info how to create references. - -CITE_BIB_FILES = - -#--------------------------------------------------------------------------- -# Configuration options related to warning and progress messages -#--------------------------------------------------------------------------- - -# The QUIET tag can be used to turn on/off the messages that are generated to -# standard output by doxygen. If QUIET is set to YES this implies that the -# messages are off. -# The default value is: NO. - -QUIET = NO - -# The WARNINGS tag can be used to turn on/off the warning messages that are -# generated to standard error ( stderr) by doxygen. If WARNINGS is set to YES -# this implies that the warnings are on. -# -# Tip: Turn warnings on while writing the documentation. -# The default value is: YES. - -WARNINGS = YES - -# If the WARN_IF_UNDOCUMENTED tag is set to YES, then doxygen will generate -# warnings for undocumented members. If EXTRACT_ALL is set to YES then this flag -# will automatically be disabled. -# The default value is: YES. - -WARN_IF_UNDOCUMENTED = YES - -# If the WARN_IF_DOC_ERROR tag is set to YES, doxygen will generate warnings for -# potential errors in the documentation, such as not documenting some parameters -# in a documented function, or documenting parameters that don't exist or using -# markup commands wrongly. -# The default value is: YES. - -WARN_IF_DOC_ERROR = YES - -# This WARN_NO_PARAMDOC option can be enabled to get warnings for functions that -# are documented, but have no documentation for their parameters or return -# value. If set to NO doxygen will only warn about wrong or incomplete parameter -# documentation, but not about the absence of documentation. -# The default value is: NO. - -WARN_NO_PARAMDOC = NO - -# The WARN_FORMAT tag determines the format of the warning messages that doxygen -# can produce. The string should contain the $file, $line, and $text tags, which -# will be replaced by the file and line number from which the warning originated -# and the warning text. Optionally the format may contain $version, which will -# be replaced by the version of the file (if it could be obtained via -# FILE_VERSION_FILTER) -# The default value is: $file:$line: $text. - -WARN_FORMAT = "$file:$line: $text" - -# The WARN_LOGFILE tag can be used to specify a file to which warning and error -# messages should be written. If left blank the output is written to standard -# error (stderr). - -WARN_LOGFILE = warnings.log - -#--------------------------------------------------------------------------- -# Configuration options related to the input files -#--------------------------------------------------------------------------- - -# The INPUT tag is used to specify the files and/or directories that contain -# documented source files. You may enter file names like myfile.cpp or -# directories like /usr/src/myproject. Separate the files or directories with -# spaces. -# Note: If this tag is empty the current directory is searched. - -INPUT = ../src ../README.md ./ - -# This tag can be used to specify the character encoding of the source files -# that doxygen parses. Internally doxygen uses the UTF-8 encoding. Doxygen uses -# libiconv (or the iconv built into libc) for the transcoding. See the libiconv -# documentation (see: http://www.gnu.org/software/libiconv) for the list of -# possible encodings. -# The default value is: UTF-8. - -INPUT_ENCODING = UTF-8 - -# If the value of the INPUT tag contains directories, you can use the -# FILE_PATTERNS tag to specify one or more wildcard patterns (like *.cpp and -# *.h) to filter out the source-files in the directories. If left blank the -# following patterns are tested:*.c, *.cc, *.cxx, *.cpp, *.c++, *.java, *.ii, -# *.ixx, *.ipp, *.i++, *.inl, *.idl, *.ddl, *.odl, *.h, *.hh, *.hxx, *.hpp, -# *.h++, *.cs, *.d, *.php, *.php4, *.php5, *.phtml, *.inc, *.m, *.markdown, -# *.md, *.mm, *.dox, *.py, *.f90, *.f, *.for, *.tcl, *.vhd, *.vhdl, *.ucf, -# *.qsf, *.as and *.js. - -FILE_PATTERNS = *.php *.md - -# The RECURSIVE tag can be used to specify whether or not subdirectories should -# be searched for input files as well. -# The default value is: NO. - -RECURSIVE = YES - -# The EXCLUDE tag can be used to specify files and/or directories that should be -# excluded from the INPUT source files. This way you can easily exclude a -# subdirectory from a directory tree whose root is specified with the INPUT tag. -# -# Note that relative paths are relative to the directory from which doxygen is -# run. - -EXCLUDE = - -# The EXCLUDE_SYMLINKS tag can be used to select whether or not files or -# directories that are symbolic links (a Unix file system feature) are excluded -# from the input. -# The default value is: NO. - -EXCLUDE_SYMLINKS = NO - -# If the value of the INPUT tag contains directories, you can use the -# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude -# certain files from those directories. -# -# Note that the wildcards are matched against the file with absolute path, so to -# exclude all test directories for example use the pattern */test/* - -EXCLUDE_PATTERNS = - -# The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names -# (namespaces, classes, functions, etc.) that should be excluded from the -# output. The symbol name can be a fully qualified name, a word, or if the -# wildcard * is used, a substring. Examples: ANamespace, AClass, -# AClass::ANamespace, ANamespace::*Test -# -# Note that the wildcards are matched against the file with absolute path, so to -# exclude all test directories use the pattern */test/* - -EXCLUDE_SYMBOLS = - -# The EXAMPLE_PATH tag can be used to specify one or more files or directories -# that contain example code fragments that are included (see the \include -# command). - -EXAMPLE_PATH = - -# If the value of the EXAMPLE_PATH tag contains directories, you can use the -# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp and -# *.h) to filter out the source-files in the directories. If left blank all -# files are included. - -EXAMPLE_PATTERNS = - -# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be -# searched for input files to be used with the \include or \dontinclude commands -# irrespective of the value of the RECURSIVE tag. -# The default value is: NO. - -EXAMPLE_RECURSIVE = NO - -# The IMAGE_PATH tag can be used to specify one or more files or directories -# that contain images that are to be included in the documentation (see the -# \image command). - -IMAGE_PATH = - -# The INPUT_FILTER tag can be used to specify a program that doxygen should -# invoke to filter for each input file. Doxygen will invoke the filter program -# by executing (via popen()) the command: -# -# -# -# where is the value of the INPUT_FILTER tag, and is the -# name of an input file. Doxygen will then use the output that the filter -# program writes to standard output. If FILTER_PATTERNS is specified, this tag -# will be ignored. -# -# Note that the filter must not add or remove lines; it is applied before the -# code is scanned, but not when the output code is generated. If lines are added -# or removed, the anchors will not be placed correctly. - -INPUT_FILTER = - -# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern -# basis. Doxygen will compare the file name with each pattern and apply the -# filter if there is a match. The filters are a list of the form: pattern=filter -# (like *.cpp=my_cpp_filter). See INPUT_FILTER for further information on how -# filters are used. If the FILTER_PATTERNS tag is empty or if none of the -# patterns match the file name, INPUT_FILTER is applied. - -FILTER_PATTERNS = - -# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using -# INPUT_FILTER ) will also be used to filter the input files that are used for -# producing the source files to browse (i.e. when SOURCE_BROWSER is set to YES). -# The default value is: NO. - -FILTER_SOURCE_FILES = NO - -# The FILTER_SOURCE_PATTERNS tag can be used to specify source filters per file -# pattern. A pattern will override the setting for FILTER_PATTERN (if any) and -# it is also possible to disable source filtering for a specific pattern using -# *.ext= (so without naming a filter). -# This tag requires that the tag FILTER_SOURCE_FILES is set to YES. - -FILTER_SOURCE_PATTERNS = - -# If the USE_MDFILE_AS_MAINPAGE tag refers to the name of a markdown file that -# is part of the input, its contents will be placed on the main page -# (index.html). This can be useful if you have a project on for instance GitHub -# and want to reuse the introduction page also for the doxygen output. - -USE_MDFILE_AS_MAINPAGE = ../README.md - -#--------------------------------------------------------------------------- -# Configuration options related to source browsing -#--------------------------------------------------------------------------- - -# If the SOURCE_BROWSER tag is set to YES then a list of source files will be -# generated. Documented entities will be cross-referenced with these sources. -# -# Note: To get rid of all source code in the generated output, make sure that -# also VERBATIM_HEADERS is set to NO. -# The default value is: NO. - -SOURCE_BROWSER = NO - -# Setting the INLINE_SOURCES tag to YES will include the body of functions, -# classes and enums directly into the documentation. -# The default value is: NO. - -INLINE_SOURCES = NO - -# Setting the STRIP_CODE_COMMENTS tag to YES will instruct doxygen to hide any -# special comment blocks from generated source code fragments. Normal C, C++ and -# Fortran comments will always remain visible. -# The default value is: YES. - -STRIP_CODE_COMMENTS = YES - -# If the REFERENCED_BY_RELATION tag is set to YES then for each documented -# function all documented functions referencing it will be listed. -# The default value is: NO. - -REFERENCED_BY_RELATION = NO - -# If the REFERENCES_RELATION tag is set to YES then for each documented function -# all documented entities called/used by that function will be listed. -# The default value is: NO. - -REFERENCES_RELATION = NO - -# If the REFERENCES_LINK_SOURCE tag is set to YES and SOURCE_BROWSER tag is set -# to YES, then the hyperlinks from functions in REFERENCES_RELATION and -# REFERENCED_BY_RELATION lists will link to the source code. Otherwise they will -# link to the documentation. -# The default value is: YES. - -REFERENCES_LINK_SOURCE = YES - -# If SOURCE_TOOLTIPS is enabled (the default) then hovering a hyperlink in the -# source code will show a tooltip with additional information such as prototype, -# brief description and links to the definition and documentation. Since this -# will make the HTML file larger and loading of large files a bit slower, you -# can opt to disable this feature. -# The default value is: YES. -# This tag requires that the tag SOURCE_BROWSER is set to YES. - -SOURCE_TOOLTIPS = YES - -# If the USE_HTAGS tag is set to YES then the references to source code will -# point to the HTML generated by the htags(1) tool instead of doxygen built-in -# source browser. The htags tool is part of GNU's global source tagging system -# (see http://www.gnu.org/software/global/global.html). You will need version -# 4.8.6 or higher. -# -# To use it do the following: -# - Install the latest version of global -# - Enable SOURCE_BROWSER and USE_HTAGS in the config file -# - Make sure the INPUT points to the root of the source tree -# - Run doxygen as normal -# -# Doxygen will invoke htags (and that will in turn invoke gtags), so these -# tools must be available from the command line (i.e. in the search path). -# -# The result: instead of the source browser generated by doxygen, the links to -# source code will now point to the output of htags. -# The default value is: NO. -# This tag requires that the tag SOURCE_BROWSER is set to YES. - -USE_HTAGS = NO - -# If the VERBATIM_HEADERS tag is set the YES then doxygen will generate a -# verbatim copy of the header file for each class for which an include is -# specified. Set to NO to disable this. -# See also: Section \class. -# The default value is: YES. - -VERBATIM_HEADERS = YES - -# If the CLANG_ASSISTED_PARSING tag is set to YES, then doxygen will use the -# clang parser (see: http://clang.llvm.org/) for more accurate parsing at the -# cost of reduced performance. This can be particularly helpful with template -# rich C++ code for which doxygen's built-in parser lacks the necessary type -# information. -# Note: The availability of this option depends on whether or not doxygen was -# compiled with the --with-libclang option. -# The default value is: NO. - -CLANG_ASSISTED_PARSING = NO - -# If clang assisted parsing is enabled you can provide the compiler with command -# line options that you would normally use when invoking the compiler. Note that -# the include paths will already be set by doxygen for the files and directories -# specified with INPUT and INCLUDE_PATH. -# This tag requires that the tag CLANG_ASSISTED_PARSING is set to YES. - -CLANG_OPTIONS = - -#--------------------------------------------------------------------------- -# Configuration options related to the alphabetical class index -#--------------------------------------------------------------------------- - -# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index of all -# compounds will be generated. Enable this if the project contains a lot of -# classes, structs, unions or interfaces. -# The default value is: YES. - -ALPHABETICAL_INDEX = YES - -# The COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns in -# which the alphabetical index list will be split. -# Minimum value: 1, maximum value: 20, default value: 5. -# This tag requires that the tag ALPHABETICAL_INDEX is set to YES. - -COLS_IN_ALPHA_INDEX = 5 - -# In case all classes in a project start with a common prefix, all classes will -# be put under the same header in the alphabetical index. The IGNORE_PREFIX tag -# can be used to specify a prefix (or a list of prefixes) that should be ignored -# while generating the index headers. -# This tag requires that the tag ALPHABETICAL_INDEX is set to YES. - -IGNORE_PREFIX = - -#--------------------------------------------------------------------------- -# Configuration options related to the HTML output -#--------------------------------------------------------------------------- - -# If the GENERATE_HTML tag is set to YES doxygen will generate HTML output -# The default value is: YES. - -GENERATE_HTML = YES - -# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. If a -# relative path is entered the value of OUTPUT_DIRECTORY will be put in front of -# it. -# The default directory is: html. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_OUTPUT = html - -# The HTML_FILE_EXTENSION tag can be used to specify the file extension for each -# generated HTML page (for example: .htm, .php, .asp). -# The default value is: .html. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_FILE_EXTENSION = .html - -# The HTML_HEADER tag can be used to specify a user-defined HTML header file for -# each generated HTML page. If the tag is left blank doxygen will generate a -# standard header. -# -# To get valid HTML the header file that includes any scripts and style sheets -# that doxygen needs, which is dependent on the configuration options used (e.g. -# the setting GENERATE_TREEVIEW). It is highly recommended to start with a -# default header using -# doxygen -w html new_header.html new_footer.html new_stylesheet.css -# YourConfigFile -# and then modify the file new_header.html. See also section "Doxygen usage" -# for information on how to generate the default header that doxygen normally -# uses. -# Note: The header is subject to change so you typically have to regenerate the -# default header when upgrading to a newer version of doxygen. For a description -# of the possible markers and block names see the documentation. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_HEADER = - -# The HTML_FOOTER tag can be used to specify a user-defined HTML footer for each -# generated HTML page. If the tag is left blank doxygen will generate a standard -# footer. See HTML_HEADER for more information on how to generate a default -# footer and what special commands can be used inside the footer. See also -# section "Doxygen usage" for information on how to generate the default footer -# that doxygen normally uses. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_FOOTER = - -# The HTML_STYLESHEET tag can be used to specify a user-defined cascading style -# sheet that is used by each HTML page. It can be used to fine-tune the look of -# the HTML output. If left blank doxygen will generate a default style sheet. -# See also section "Doxygen usage" for information on how to generate the style -# sheet that doxygen normally uses. -# Note: It is recommended to use HTML_EXTRA_STYLESHEET instead of this tag, as -# it is more robust and this tag (HTML_STYLESHEET) will in the future become -# obsolete. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_STYLESHEET = - -# The HTML_EXTRA_STYLESHEET tag can be used to specify additional user-defined -# cascading style sheets that are included after the standard style sheets -# created by doxygen. Using this option one can overrule certain style aspects. -# This is preferred over using HTML_STYLESHEET since it does not replace the -# standard style sheet and is therefor more robust against future updates. -# Doxygen will copy the style sheet files to the output directory. -# Note: The order of the extra stylesheet files is of importance (e.g. the last -# stylesheet in the list overrules the setting of the previous ones in the -# list). For an example see the documentation. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_EXTRA_STYLESHEET = - -# The HTML_EXTRA_FILES tag can be used to specify one or more extra images or -# other source files which should be copied to the HTML output directory. Note -# that these files will be copied to the base HTML output directory. Use the -# $relpath^ marker in the HTML_HEADER and/or HTML_FOOTER files to load these -# files. In the HTML_STYLESHEET file, use the file name only. Also note that the -# files will be copied as-is; there are no commands or markers available. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_EXTRA_FILES = - -# The HTML_COLORSTYLE_HUE tag controls the color of the HTML output. Doxygen -# will adjust the colors in the stylesheet and background images according to -# this color. Hue is specified as an angle on a colorwheel, see -# http://en.wikipedia.org/wiki/Hue for more information. For instance the value -# 0 represents red, 60 is yellow, 120 is green, 180 is cyan, 240 is blue, 300 -# purple, and 360 is red again. -# Minimum value: 0, maximum value: 359, default value: 220. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_COLORSTYLE_HUE = 220 - -# The HTML_COLORSTYLE_SAT tag controls the purity (or saturation) of the colors -# in the HTML output. For a value of 0 the output will use grayscales only. A -# value of 255 will produce the most vivid colors. -# Minimum value: 0, maximum value: 255, default value: 100. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_COLORSTYLE_SAT = 100 - -# The HTML_COLORSTYLE_GAMMA tag controls the gamma correction applied to the -# luminance component of the colors in the HTML output. Values below 100 -# gradually make the output lighter, whereas values above 100 make the output -# darker. The value divided by 100 is the actual gamma applied, so 80 represents -# a gamma of 0.8, The value 220 represents a gamma of 2.2, and 100 does not -# change the gamma. -# Minimum value: 40, maximum value: 240, default value: 80. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_COLORSTYLE_GAMMA = 80 - -# If the HTML_TIMESTAMP tag is set to YES then the footer of each generated HTML -# page will contain the date and time when the page was generated. Setting this -# to NO can help when comparing the output of multiple runs. -# The default value is: YES. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_TIMESTAMP = YES - -# If the HTML_DYNAMIC_SECTIONS tag is set to YES then the generated HTML -# documentation will contain sections that can be hidden and shown after the -# page has loaded. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_DYNAMIC_SECTIONS = NO - -# With HTML_INDEX_NUM_ENTRIES one can control the preferred number of entries -# shown in the various tree structured indices initially; the user can expand -# and collapse entries dynamically later on. Doxygen will expand the tree to -# such a level that at most the specified number of entries are visible (unless -# a fully collapsed tree already exceeds this amount). So setting the number of -# entries 1 will produce a full collapsed tree by default. 0 is a special value -# representing an infinite number of entries and will result in a full expanded -# tree by default. -# Minimum value: 0, maximum value: 9999, default value: 100. -# This tag requires that the tag GENERATE_HTML is set to YES. - -HTML_INDEX_NUM_ENTRIES = 100 - -# If the GENERATE_DOCSET tag is set to YES, additional index files will be -# generated that can be used as input for Apple's Xcode 3 integrated development -# environment (see: http://developer.apple.com/tools/xcode/), introduced with -# OSX 10.5 (Leopard). To create a documentation set, doxygen will generate a -# Makefile in the HTML output directory. Running make will produce the docset in -# that directory and running make install will install the docset in -# ~/Library/Developer/Shared/Documentation/DocSets so that Xcode will find it at -# startup. See http://developer.apple.com/tools/creatingdocsetswithdoxygen.html -# for more information. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTML is set to YES. - -GENERATE_DOCSET = NO - -# This tag determines the name of the docset feed. A documentation feed provides -# an umbrella under which multiple documentation sets from a single provider -# (such as a company or product suite) can be grouped. -# The default value is: Doxygen generated docs. -# This tag requires that the tag GENERATE_DOCSET is set to YES. - -DOCSET_FEEDNAME = "Doxygen generated docs" - -# This tag specifies a string that should uniquely identify the documentation -# set bundle. This should be a reverse domain-name style string, e.g. -# com.mycompany.MyDocSet. Doxygen will append .docset to the name. -# The default value is: org.doxygen.Project. -# This tag requires that the tag GENERATE_DOCSET is set to YES. - -DOCSET_BUNDLE_ID = org.doxygen.Project - -# The DOCSET_PUBLISHER_ID tag specifies a string that should uniquely identify -# the documentation publisher. This should be a reverse domain-name style -# string, e.g. com.mycompany.MyDocSet.documentation. -# The default value is: org.doxygen.Publisher. -# This tag requires that the tag GENERATE_DOCSET is set to YES. - -DOCSET_PUBLISHER_ID = org.doxygen.Publisher - -# The DOCSET_PUBLISHER_NAME tag identifies the documentation publisher. -# The default value is: Publisher. -# This tag requires that the tag GENERATE_DOCSET is set to YES. - -DOCSET_PUBLISHER_NAME = Publisher - -# If the GENERATE_HTMLHELP tag is set to YES then doxygen generates three -# additional HTML index files: index.hhp, index.hhc, and index.hhk. The -# index.hhp is a project file that can be read by Microsoft's HTML Help Workshop -# (see: http://www.microsoft.com/en-us/download/details.aspx?id=21138) on -# Windows. -# -# The HTML Help Workshop contains a compiler that can convert all HTML output -# generated by doxygen into a single compiled HTML file (.chm). Compiled HTML -# files are now used as the Windows 98 help format, and will replace the old -# Windows help format (.hlp) on all Windows platforms in the future. Compressed -# HTML files also contain an index, a table of contents, and you can search for -# words in the documentation. The HTML workshop also contains a viewer for -# compressed HTML files. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTML is set to YES. - -GENERATE_HTMLHELP = NO - -# The CHM_FILE tag can be used to specify the file name of the resulting .chm -# file. You can add a path in front of the file if the result should not be -# written to the html output directory. -# This tag requires that the tag GENERATE_HTMLHELP is set to YES. - -CHM_FILE = - -# The HHC_LOCATION tag can be used to specify the location (absolute path -# including file name) of the HTML help compiler ( hhc.exe). If non-empty -# doxygen will try to run the HTML help compiler on the generated index.hhp. -# The file has to be specified with full path. -# This tag requires that the tag GENERATE_HTMLHELP is set to YES. - -HHC_LOCATION = - -# The GENERATE_CHI flag controls if a separate .chi index file is generated ( -# YES) or that it should be included in the master .chm file ( NO). -# The default value is: NO. -# This tag requires that the tag GENERATE_HTMLHELP is set to YES. - -GENERATE_CHI = NO - -# The CHM_INDEX_ENCODING is used to encode HtmlHelp index ( hhk), content ( hhc) -# and project file content. -# This tag requires that the tag GENERATE_HTMLHELP is set to YES. - -CHM_INDEX_ENCODING = - -# The BINARY_TOC flag controls whether a binary table of contents is generated ( -# YES) or a normal table of contents ( NO) in the .chm file. Furthermore it -# enables the Previous and Next buttons. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTMLHELP is set to YES. - -BINARY_TOC = NO - -# The TOC_EXPAND flag can be set to YES to add extra items for group members to -# the table of contents of the HTML help documentation and to the tree view. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTMLHELP is set to YES. - -TOC_EXPAND = NO - -# If the GENERATE_QHP tag is set to YES and both QHP_NAMESPACE and -# QHP_VIRTUAL_FOLDER are set, an additional index file will be generated that -# can be used as input for Qt's qhelpgenerator to generate a Qt Compressed Help -# (.qch) of the generated HTML documentation. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTML is set to YES. - -GENERATE_QHP = NO - -# If the QHG_LOCATION tag is specified, the QCH_FILE tag can be used to specify -# the file name of the resulting .qch file. The path specified is relative to -# the HTML output folder. -# This tag requires that the tag GENERATE_QHP is set to YES. - -QCH_FILE = - -# The QHP_NAMESPACE tag specifies the namespace to use when generating Qt Help -# Project output. For more information please see Qt Help Project / Namespace -# (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#namespace). -# The default value is: org.doxygen.Project. -# This tag requires that the tag GENERATE_QHP is set to YES. - -QHP_NAMESPACE = org.doxygen.Project - -# The QHP_VIRTUAL_FOLDER tag specifies the namespace to use when generating Qt -# Help Project output. For more information please see Qt Help Project / Virtual -# Folders (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#virtual- -# folders). -# The default value is: doc. -# This tag requires that the tag GENERATE_QHP is set to YES. - -QHP_VIRTUAL_FOLDER = doc - -# If the QHP_CUST_FILTER_NAME tag is set, it specifies the name of a custom -# filter to add. For more information please see Qt Help Project / Custom -# Filters (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#custom- -# filters). -# This tag requires that the tag GENERATE_QHP is set to YES. - -QHP_CUST_FILTER_NAME = - -# The QHP_CUST_FILTER_ATTRS tag specifies the list of the attributes of the -# custom filter to add. For more information please see Qt Help Project / Custom -# Filters (see: http://qt-project.org/doc/qt-4.8/qthelpproject.html#custom- -# filters). -# This tag requires that the tag GENERATE_QHP is set to YES. - -QHP_CUST_FILTER_ATTRS = - -# The QHP_SECT_FILTER_ATTRS tag specifies the list of the attributes this -# project's filter section matches. Qt Help Project / Filter Attributes (see: -# http://qt-project.org/doc/qt-4.8/qthelpproject.html#filter-attributes). -# This tag requires that the tag GENERATE_QHP is set to YES. - -QHP_SECT_FILTER_ATTRS = - -# The QHG_LOCATION tag can be used to specify the location of Qt's -# qhelpgenerator. If non-empty doxygen will try to run qhelpgenerator on the -# generated .qhp file. -# This tag requires that the tag GENERATE_QHP is set to YES. - -QHG_LOCATION = - -# If the GENERATE_ECLIPSEHELP tag is set to YES, additional index files will be -# generated, together with the HTML files, they form an Eclipse help plugin. To -# install this plugin and make it available under the help contents menu in -# Eclipse, the contents of the directory containing the HTML and XML files needs -# to be copied into the plugins directory of eclipse. The name of the directory -# within the plugins directory should be the same as the ECLIPSE_DOC_ID value. -# After copying Eclipse needs to be restarted before the help appears. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTML is set to YES. - -GENERATE_ECLIPSEHELP = NO - -# A unique identifier for the Eclipse help plugin. When installing the plugin -# the directory name containing the HTML and XML files should also have this -# name. Each documentation set should have its own identifier. -# The default value is: org.doxygen.Project. -# This tag requires that the tag GENERATE_ECLIPSEHELP is set to YES. - -ECLIPSE_DOC_ID = org.doxygen.Project - -# If you want full control over the layout of the generated HTML pages it might -# be necessary to disable the index and replace it with your own. The -# DISABLE_INDEX tag can be used to turn on/off the condensed index (tabs) at top -# of each HTML page. A value of NO enables the index and the value YES disables -# it. Since the tabs in the index contain the same information as the navigation -# tree, you can set this option to YES if you also set GENERATE_TREEVIEW to YES. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTML is set to YES. - -DISABLE_INDEX = NO - -# The GENERATE_TREEVIEW tag is used to specify whether a tree-like index -# structure should be generated to display hierarchical information. If the tag -# value is set to YES, a side panel will be generated containing a tree-like -# index structure (just like the one that is generated for HTML Help). For this -# to work a browser that supports JavaScript, DHTML, CSS and frames is required -# (i.e. any modern browser). Windows users are probably better off using the -# HTML help feature. Via custom stylesheets (see HTML_EXTRA_STYLESHEET) one can -# further fine-tune the look of the index. As an example, the default style -# sheet generated by doxygen has an example that shows how to put an image at -# the root of the tree instead of the PROJECT_NAME. Since the tree basically has -# the same information as the tab index, you could consider setting -# DISABLE_INDEX to YES when enabling this option. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTML is set to YES. - -GENERATE_TREEVIEW = NO - -# The ENUM_VALUES_PER_LINE tag can be used to set the number of enum values that -# doxygen will group on one line in the generated HTML documentation. -# -# Note that a value of 0 will completely suppress the enum values from appearing -# in the overview section. -# Minimum value: 0, maximum value: 20, default value: 4. -# This tag requires that the tag GENERATE_HTML is set to YES. - -ENUM_VALUES_PER_LINE = 4 - -# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be used -# to set the initial width (in pixels) of the frame in which the tree is shown. -# Minimum value: 0, maximum value: 1500, default value: 250. -# This tag requires that the tag GENERATE_HTML is set to YES. - -TREEVIEW_WIDTH = 250 - -# When the EXT_LINKS_IN_WINDOW option is set to YES doxygen will open links to -# external symbols imported via tag files in a separate window. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTML is set to YES. - -EXT_LINKS_IN_WINDOW = NO - -# Use this tag to change the font size of LaTeX formulas included as images in -# the HTML documentation. When you change the font size after a successful -# doxygen run you need to manually remove any form_*.png images from the HTML -# output directory to force them to be regenerated. -# Minimum value: 8, maximum value: 50, default value: 10. -# This tag requires that the tag GENERATE_HTML is set to YES. - -FORMULA_FONTSIZE = 10 - -# Use the FORMULA_TRANPARENT tag to determine whether or not the images -# generated for formulas are transparent PNGs. Transparent PNGs are not -# supported properly for IE 6.0, but are supported on all modern browsers. -# -# Note that when changing this option you need to delete any form_*.png files in -# the HTML output directory before the changes have effect. -# The default value is: YES. -# This tag requires that the tag GENERATE_HTML is set to YES. - -FORMULA_TRANSPARENT = YES - -# Enable the USE_MATHJAX option to render LaTeX formulas using MathJax (see -# http://www.mathjax.org) which uses client side Javascript for the rendering -# instead of using prerendered bitmaps. Use this if you do not have LaTeX -# installed or if you want to formulas look prettier in the HTML output. When -# enabled you may also need to install MathJax separately and configure the path -# to it using the MATHJAX_RELPATH option. -# The default value is: NO. -# This tag requires that the tag GENERATE_HTML is set to YES. - -USE_MATHJAX = NO - -# When MathJax is enabled you can set the default output format to be used for -# the MathJax output. See the MathJax site (see: -# http://docs.mathjax.org/en/latest/output.html) for more details. -# Possible values are: HTML-CSS (which is slower, but has the best -# compatibility), NativeMML (i.e. MathML) and SVG. -# The default value is: HTML-CSS. -# This tag requires that the tag USE_MATHJAX is set to YES. - -MATHJAX_FORMAT = HTML-CSS - -# When MathJax is enabled you need to specify the location relative to the HTML -# output directory using the MATHJAX_RELPATH option. The destination directory -# should contain the MathJax.js script. For instance, if the mathjax directory -# is located at the same level as the HTML output directory, then -# MATHJAX_RELPATH should be ../mathjax. The default value points to the MathJax -# Content Delivery Network so you can quickly see the result without installing -# MathJax. However, it is strongly recommended to install a local copy of -# MathJax from http://www.mathjax.org before deployment. -# The default value is: http://cdn.mathjax.org/mathjax/latest. -# This tag requires that the tag USE_MATHJAX is set to YES. - -MATHJAX_RELPATH = http://cdn.mathjax.org/mathjax/latest - -# The MATHJAX_EXTENSIONS tag can be used to specify one or more MathJax -# extension names that should be enabled during MathJax rendering. For example -# MATHJAX_EXTENSIONS = TeX/AMSmath TeX/AMSsymbols -# This tag requires that the tag USE_MATHJAX is set to YES. - -MATHJAX_EXTENSIONS = - -# The MATHJAX_CODEFILE tag can be used to specify a file with javascript pieces -# of code that will be used on startup of the MathJax code. See the MathJax site -# (see: http://docs.mathjax.org/en/latest/output.html) for more details. For an -# example see the documentation. -# This tag requires that the tag USE_MATHJAX is set to YES. - -MATHJAX_CODEFILE = - -# When the SEARCHENGINE tag is enabled doxygen will generate a search box for -# the HTML output. The underlying search engine uses javascript and DHTML and -# should work on any modern browser. Note that when using HTML help -# (GENERATE_HTMLHELP), Qt help (GENERATE_QHP), or docsets (GENERATE_DOCSET) -# there is already a search function so this one should typically be disabled. -# For large projects the javascript based search engine can be slow, then -# enabling SERVER_BASED_SEARCH may provide a better solution. It is possible to -# search using the keyboard; to jump to the search box use + S -# (what the is depends on the OS and browser, but it is typically -# , /