diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md index 68fe9de68d6..d7463d62172 100644 --- a/.github/CONTRIBUTING.md +++ b/.github/CONTRIBUTING.md @@ -26,8 +26,9 @@ Default **language here is english**. So please prepare your contributions in en 1. [Fork](https://help.github.com/articles/fork-a-repo) the [GitHub repository](https://github.com/Dolibarr/dolibarr). 2. Clone your fork. 3. Choose a branch(See the [Branches](#branches) section below). -4. Commit and push your changes. -5. [Make a pull request](https://help.github.com/articles/creating-a-pull-request). +4. Read our developer documentation on the [Dolibarr Wiki](https://wiki.dolibarr.org/index.php?title=Developer_documentation). +5. Commit and push your changes. +6. [Make a pull request](https://help.github.com/articles/creating-a-pull-request). ### Branches diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md deleted file mode 100644 index 432f30f2332..00000000000 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ /dev/null @@ -1,35 +0,0 @@ ---- -name: Bug report -about: Create a report to help us fix something that is broken -title: '' -labels: Bug -assignees: '' - ---- - -# Instructions -*This is a template to help you report good issues. You may use [Github Markdown](https://help.github.com/articles/getting-started-with-writing-and-formatting-on-github/) syntax to format your issue report.* -*Please:* -- *replace the bracket enclosed texts with meaningful information* -- *remove any unused sub-section* - - -# Bug -[*Short description*] - -## Environment -- **Version**: [*Affected Dolibarr version(s)*] -- **OS**: [*Server OS type and version*] -- **Web server**: [*Webserver type and version*] -- **PHP**: [*PHP version*] -- **Database**: [*Database type and version*] -- **URL(s)**: [*Affected URL(s)*] - -## Expected and actual behavior -[*Verbose description*] - -## Steps to reproduce the behavior -[*Verbose description*] - -## [Attached files](https://help.github.com/articles/issue-attachments) (Screenshots, screencasts, dolibarr.log, debugging informations…) -[*Files*] diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml new file mode 100644 index 00000000000..d7dc3d584e3 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -0,0 +1,71 @@ +name: Bug report +description: Create a report to help us fix something that is broken +labels: ["Bug"] + +body: + - type: markdown + attributes: + value: | + This is a template to help you report good issues. You may use [Github Markdown](https://help.github.com/articles/getting-started-with-writing-and-formatting-on-github/) syntax to format your issue report. + + - type: textarea + id: bug + attributes: + label: Bug + description: Please give a short description of the bug + validations: + required: true + + - type: input + id: environment-version + attributes: + label: Environment Version + description: Affected Dolibarr version(s) + + - type: input + id: environment-os + attributes: + label: Environment OS + description: Server OS type and version + + - type: input + id: environment-webserver + attributes: + label: Environment Web server + description: Webserver type and version + + - type: input + id: environment-php + attributes: + label: Environment PHP + description: PHP version + + - type: input + id: environment-database + attributes: + label: Environment Database + description: Database type and version + + - type: input + id: environment-urls + attributes: + label: Environment URL(s) + description: Affected URL(s) + + - type: textarea + id: expected-behaviour + attributes: + label: Expected and actual behavior + description: Verbose description + + - type: textarea + id: reproduce + attributes: + label: Steps to reproduce the behavior + description: Verbose description + + - type: textarea + id: files + attributes: + label: Attached files + description: Screenshots, screencasts, dolibarr.log, debugging informations diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md deleted file mode 100644 index 32e2deff2c1..00000000000 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ /dev/null @@ -1,27 +0,0 @@ ---- -name: Feature request -about: Suggest a new idea for this project -title: '' -labels: Feature request -assignees: '' - ---- - -# Instructions -*This is a template to help you report good issues. You may use [Github Markdown](https://help.github.com/articles/getting-started-with-writing-and-formatting-on-github/) syntax to format your issue report.* -*Please:* -- *replace the bracket enclosed texts with meaningful information* -- *remove any unused sub-section* - - -# Feature Request -[*Short description*] - -## Use case -[*Verbose description*] - -## Suggested implementation -[*Verbose description*] - -## Suggested steps -[*List of tasks to achieve goal*] diff --git a/.github/ISSUE_TEMPLATE/feature_request.yml b/.github/ISSUE_TEMPLATE/feature_request.yml new file mode 100644 index 00000000000..885f3472d18 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_request.yml @@ -0,0 +1,35 @@ +name: Feature request +description: Suggest a new idea for this project +labels: ["Feature request"] + +body: + - type: markdown + attributes: + value: | + This is a template to help you report good issues. You may use [Github Markdown](https://help.github.com/articles/getting-started-with-writing-and-formatting-on-github/) syntax to format your issue report. + + - type: textarea + id: feature-request + attributes: + label: Feature Request + description: Short description + validations: + required: true + + - type: textarea + id: use-case + attributes: + label: Use case + description: Verbose description + + - type: textarea + id: suggested-implementation + attributes: + label: Suggested implementation + description: Verbose description + + - type: textarea + id: suggested-steps + attributes: + label: Suggested steps + description: List of tasks to achieve goal diff --git a/.gitignore b/.gitignore index 371c8be2f5e..e4790fe7b4e 100644 --- a/.gitignore +++ b/.gitignore @@ -55,3 +55,4 @@ yarn.lock package-lock.json doc/install.lock +/factory/ diff --git a/.travis.yml b/.travis.yml index b48a3667bb0..5d7eb7a1678 100644 --- a/.travis.yml +++ b/.travis.yml @@ -57,7 +57,7 @@ jobs: php: nightly env: DB=mysql - stage: PHP Dev - if: type = push AND branch = 14.0 + if: type = push AND branch = 15.0 php: nightly env: DB=mysql @@ -411,6 +411,12 @@ script: php upgrade.php 13.0.0 14.0.0 ignoredbversion > $TRAVIS_BUILD_DIR/upgrade13001400.log php upgrade2.php 13.0.0 14.0.0 > $TRAVIS_BUILD_DIR/upgrade13001400-2.log php step5.php 13.0.0 14.0.0 > $TRAVIS_BUILD_DIR/upgrade13001400-3.log + php upgrade.php 14.0.0 15.0.0 ignoredbversion > $TRAVIS_BUILD_DIR/upgrade14001500.log + php upgrade2.php 14.0.0 15.0.0 > $TRAVIS_BUILD_DIR/upgrade14001500-2.log + php step5.php 14.0.0 15.0.0 > $TRAVIS_BUILD_DIR/upgrade14001500-3.log + php upgrade.php 15.0.0 16.0.0 ignoredbversion > $TRAVIS_BUILD_DIR/upgrade15001600.log + php upgrade2.php 15.0.0 16.0.0 > $TRAVIS_BUILD_DIR/upgrade15001600-2.log + php step5.php 15.0.0 16.0.0 > $TRAVIS_BUILD_DIR/upgrade15001600-3.log ls -alrt $TRAVIS_BUILD_DIR/ - | diff --git a/ChangeLog b/ChangeLog index 1c0e96fc27c..08d445cdfc7 100644 --- a/ChangeLog +++ b/ChangeLog @@ -3,6 +3,32 @@ English Dolibarr ChangeLog -------------------------------------------------------------- +***** ChangeLog for 16.0.0 compared to 15.0.0 ***** + +For users: +--------------- + +NEW: ... + + + Modules +NEW: Experimental module Event Organization Management +NEW: Experimental module Workstations Management +NEW: Experimental module Partnership Management + + +For developers: +--------------- + +NEW: + +Following changes may create regressions for some external modules, but were necessary to make Dolibarr better: +* verifCond('stringtoevaluate') now return false when string contains a bad syntax content instead of true. + + + + + ***** ChangeLog for 15.0.0 compared to 14.0.0 ***** For users: @@ -12,10 +38,9 @@ NEW: Online proposal signature NEW: Can define some max limit on expense report (per period, per type or expense, ...) NEW: Allow the use of __NEWREF__ to get for example the new reference a draft order will get after validation. NEW: Add option to disable globaly some notifications emails. -NEW: #18326 Workflow: Close order on shipment closing. NEW: #18401 Add __NEWREF__ subtitute to get new object reference. NEW: #18403 Add __URL_SHIPMENT__ substitute to get the URL of a shipment -NEW: #18689 REST API module: add api key generate / modify right. +NEW: #18689 REST API module: add api key generate / modify permission. NEW: #18663 Make "L'Annuaire des Entreprises" the default provider for SIREN verification for French thirdparties. NEW: #18046 Add tags on ticket/categories NEW: #18326 Workflow: Close order on shipment closing. @@ -105,6 +130,15 @@ NEW: Use an ajax call for the clicktodial feature instead of href link. NEW: when multiple order linked to facture, show list into note. NEW: when we delete several objects with massaction, if somes object has child we must see which objects are concerned and nevertheless delete objects which can be deleted NEW: Editing a page in website module keep old page with name .back +NEW: External backups can be downloaded from the "About info page". +NEW: Add massaction to switch status on sale / on purchase of a product. + + + Modules +NEW: Stable module Knowledge Management +NEW: Experimental module Event Organization Management +NEW: Experimental module Workstations Management +NEW: Development of module Partnership Management For developers: @@ -114,6 +148,7 @@ NEW: Introduce method hasRight NEW: Can use textarea field into a confirm popup. NEW: Can use the result_mode of mysqli driver. Save memory for list count NEW: #18319 REST API - Shipment: Add 'close' action / endpoint / POST method. +NEW: Add API /approve and /makeOrder for purchase orders. NEW: add action trigger for member excluded NEW: add option MAIN_IBAN_IS_NEVER_MANDATORY, MAIN_IBAN_NOT_MANDATORY, PROPAL_NOT_BILLABLE, PROPAL_REOPEN_UNSIGNED_ONLY, PROPOSAL_ARE_NOT_BILLABLE, TICKETS_MESSAGE_FORCE_MAIL NEW: Add code codebar column on serial/lot structure @@ -131,17 +166,179 @@ NEW: printFieldListFrom hook call on several lists NEW: Use lang selector when using a field key 'lang' in modulebuilder NEW: we need to be able to put more filters on deleteByParentField() function NEW: make it easier to set the `keyword`, `keywords` and `description` attributes of an ecm file object - - +NEW: Experimental feature to manage user sessions in database +NEW: Hidden option API_DISABLE_COMPRESSION is now visible in API setup page. +NEW: Add hook printUnderHeaderPDFline on invoice PDF templates (can be used for example to add a barcode or more information on header of invoices). Following changes may create regressions for some external modules, but were necessary to make Dolibarr better: +* ALL EXTERNAL MODULES THAT WERE NOT CORRECTLY DEVELOPPED WILL NOT WORK ON V15 (All modules that forgot to manage the security token field + into forms will be broken. The security token field is expected since Dolibarr v9 but a lot of external modules did not implement it). * Update hook 'printOriginObjectLine', removed check on product type and special code. Need now reshook. * Old deprecated module "SimplePOS" has been completely removed. Use module "TakePOS" is you need a Point Of Sale. * The method static ActionComm::getActions($db, ...) is no more static. Use $actioncomm->getActions(...) instead (without $db param). * The 'action=delete&file=...' has been replaced with 'action=deletefile&file=...' to avoid confusion with deletion of object lines. * Method getDictvalue has been renamed into getDictionaryValue to match camel case rule. +* To execute shell or command line command, your code must never use method like exec, shell_exec, popen, .. but must use the built-in + method executeCLI() available into core/class/utils.class.php +* Class file expeditionbatch.class.php renamed to expeditionlinebatch.class.php +* ExpeditionLineBatch::fetchAll is not static anymore and first parameter $db is removed +* ExtraFields->showOutputField parameter 4 'extrafieldsobjectkey' is now required +* CommonObject method add_object_linked now sets targettype to 'mymodule_myobject' instead of 'myobject', + you can use hook 'setLinkedObjectSourceTargetType' to set your usual targettype +***** ChangeLog for 14.0.5 compared to 14.0.4 ***** + +FIX: 13.0: printFieldListWhere called twice on same query +FIX: 14.0.4 fatal error on cron list. +FIX: #19476 +FIX: #19564 +FIX: #19651 +FIX: Accountancy - SQL error on subledger account search in journal +FIX: apply eldy's suggestion to not overwrite existing extrafields of $line +FIX: Can't close a down payment if paid with credit notes. +FIX: better compatibility with multicompany +FIX: contact card: bad colspan value for separator extrafield in creation/modification form +FIX: discounts are applied both when fetching the best supplier price and when displaying it +FIX: double display for contact categorie on societe create card +FIX: fatal error on cron list. +FIX: holiday list: only mass delete if leave request is not in draft, canceled or refused, like in card +FIX: holiday mass deletion: correct return of record deleted +FIX: Holiday month report +FIX: info tab on customer invoice record not found +FIX: line extrafields are inoperative in dispatch cards even when they exist +FIX: list of categories in stats of supplier invoices +FIX: missing default value for more comprehensive +FIX: multicurrency: fields in discount unitialized when creating deposit +FIX: Navigation on bank transaction list +FIX: Can't edit a bank transaction due to bad permission check. +FIX: Option MAIN_DIRECT_STATUS_UPDATE broken. Ajax on/off not saving value in DB after updating to version >=12 +FIX: postgresql compatibility, "" as is not authorized +FIX: printFieldListWhere called twice (at different locations) for the same SQL query, can result in syntax errors +FIX: select too large into addrights (pb of missing parenthesis) +FIX: set optional from post, we can't untick boolean field on product card +FIX: Take into consideration work leave over serveral months +FIX: test if method exist on wrong object +FIX: title for nature of third party in company list +FIX: Urgent onglet contact inaccessible depuis une facture +FIX: wrong syntax of sql request + +***** ChangeLog for 14.0.4 compared to 14.0.3 ***** + +FIX: $totalarray is overwritten, totals were lost +FIX: 13.0 - due to a typo in the 'mode' parameter, the "first name" column of the list of members displays the full name +FIX: 13.0: end date required to edit a ticket message +FIX: 13.0 feedback of PR #18993: make ticket messages punctual events with attr percentage = -1 +FIX: 13.0 PR #18993: add comment on modified part +FIX: 13.0: sometimes firstname was mistyped as fistname +FIX: 14.0 - civility field of private third party creation form has inadequate width +FIX: 14.0 - civility field width inadequate due to select2 calculating the width while the field has no width (display: none) +FIX: 14.0 - due to a typo in the 'mode' parameter, the "first name" co… +FIX: #18634 : Problem of virtual stock with reception module enabled +FIX: #18695 Added ref_ext to supplier invoice +FIX: #18698 Supplier invoice list - "alert" checkbox not working +FIX: #18735 +FIX: #18767 : Adherent delete +FIX: #18797 +FIX: #18854 +FIX: #18875 in v14 +FIX: #18910 +FIX: #18910 : MRP List SQL query syntax error with more than one extrafileds. +FIX: #18912 Accountancy - SQL error when custom group is added without country defined +FIX: #18934 on-registration in the extrafieldsline database for deliveries +FIX: #18968 +FIX: #19008 +FIX: #19014 - the properties of some fields are not updated when you submit the form +FIX: #19210 +FIX: #19214 : PostgreSQL error on admin/limits.php +FIX: #19241 Project - Fix display salary in overview +FIX: #19305 +FIX: 2 columns for total labels +FIX: Accountancy - Format Quadra export - Missing line type C to create automaticly a subledger account with label +FIX: Accountancy - If deposit invoice is used, force binding in deposit accounting account to solve transaction +FIX: Accountancy - Missing specific filename for export on format FEC2, Ciel & repare it +FIX: Accountancy - Option of export popup are inverted +FIX: Accountancy - PHP8 +FIX: Accountancy - Product admin - SQL error when we affect accounting account with product_perentity activated +FIX: Accountancy simplified - Salaries are not present in report +FIX: Accountancy - Some correction on export name +FIX: Accountancy - Trunc code_journal to 2 in format XIMPORT (Ciel, Sage50) +FIX: add warehouse in projects' overview count +FIX: also on customer index for automatic binding +FIX: Attachment of pdf into shipment when sending email +FIX: autocalculation of the supplier price in main currency. +FIX: avoid warning if $categories is an id +FIX: bad sign of amount stored for multicurrency columns on credit notes +FIX: Bad use of a forced contact of another company on PDF/ODT documents +FIX: Bad use of dol_concatdesc() +FIX: Button text on proposal card for create a invoice +FIX: calculateCosts of BOM must not be included into fetch +FIX: calculation of balance in conciliation page on desc sorting. +FIX: card.php +FIX: Change date format of the inventorycode to be equal as mass stock transfert +FIX: check if greater 0 +FIX: close cash with some terminals in TakePOS +FIX: compatibility with Multicompany +FIX: consistent UX when calling a tab from the invoice card with empty ref/id +FIX: default language defined for IN country +FIX: Expense report - In edit mode, field qty doesn't accept decimal unlike the create mode +FIX: fetch of product with modulebuilder load too much data +FIX: filter for export of accounting documents +FIX: Filter on categories +FIX: generate documents with PDF options +FIX: indentation +FIX: init hookmanager after loading $conf values +FIX: invoice: inpossible to create an invoice because of very bad check + warnings when trying to print tabs for invoice with no ID +FIX: legal issue on expense report pdf (must also show price without tax) +FIX: list of categories in stats of supplier invoices +FIX: load tranlate array after setting lang +FIX: lost superadmin grade after edit user card +FIX: missing filter status=1 on rss feeds +FIX: missing permission check reported by me@lainwir3d.net on product api +FIX: missing return status +FIX: missing sql filter by entity +FIX: move fetch_optionnal into $ac_static->fetch() +FIX: only a superadmin can modify entity +FIX: only ones value is return for dictionaries +FIX: optional visibility on create card +FIX: payment style and html5 tags +FIX: payment using wrong type in takepos when too many payment mode +FIX: PR#18931 Remove useless explicit call to dol_shutdown +FIX: Product accountancy affectation with product_perentity activated (PR #18620) +FIX: products/services card: hidden extrafields were overridden +FIX: project task list: extrafields could not be displayed +FIX: Propal list - Problem of pagination on date +FIX: reload user lang +FIX: Remove not complete order from the virtual stock +FIX: Replenish: SQL error when no warehouse has been created + Warning when there are no warehouses +FIX: resource list : Use standard code to handle list filters +FIX: restrictedArea for payment delete +FIX: Ret PR +FIX: second approval back in stable feature as is the setting for minimum amount (last part from PR#14286) +FIX: selected lines on supplier invoice create +FIX: Selection of type "people" for membership must hide the company +FIX: select list of orders not complete when field type of company is on +FIX: show end hours in events linked to objects +FIX: support of localtax on expense report +FIX: task time: can't filter by user with pgsql + show error message +FIX: task time: keep on using natural_search +FIX: tcpdf vulnerability to roman numeral bomb, cf. tecnickom/TCPDF issue #315 +FIX: Test when date of invoie is in future (pb with TZ and offset) +FIX: Ticket - Card - Wrong font awesome library +FIX: Ticket - Duplicate field project when we create ticket from project +FIX: translation into email for member at membership validation. +FIX: Travis Sanitize SQL +FIX: unprivileged user can see task associated with a not allowed project +FIX: URGENT: impossible to create an invoice +FIX: Use of accent into filename of GED +FIX: user date timezone offset +FIX: User salary card - translation problem +FIX: user without permission can set ticket subject +FIX: We need a default price base type in variant creation case with multiprices when parent has been created with only one level price +FIX: wrong array key value +FIX: wrong check +FIX: wrong position of error message +Sync transifex. ***** ChangeLog for 14.0.3 compared to 14.0.2 ***** @@ -497,7 +694,8 @@ Following changes may create regressions for some external modules, but were nec * Removed deprecated substitution key __REFCLIENT__ (replaced with __REF_CLIENT__) * Removed constant MAIN_COUNTRIES_IN_EEC. You can now set if country is in Europe or not from the dictionary of countries. * v14 seems to work correctly on PHP v8 but it generates a lot of verbose warnings. Currently, v14 i snot yet officialy supported with PHP 8. - +* To execute shell or command line command, your code must never use method like exec, shell_exec, popen, .. but must use the built-in + method executeCLI() available into core/class/utils.class.php ***** ChangeLog for 13.0.5 compared to 13.0.4 ***** diff --git a/README-FR.md b/README-FR.md index 81fdff13047..a67bf204076 100644 --- a/README-FR.md +++ b/README-FR.md @@ -8,12 +8,10 @@ Il est simple d'utilisation et modulaire, vous permettant de n'activez que les f ![ScreenShot](https://www.dolibarr.org/medias/dolibarr_screenshot1_1920x1080.jpg) - ## LICENCE Dolibarr est distribué sous les termes de la licence GNU General Public License v3+ ou supérieure. - ## INSTALLER DOLIBARR ### Configuration simple @@ -54,7 +52,6 @@ Vous pouvez aussi utiliser un serveur Web et une base de données prise en charg - Suivez les instructions de l'installateur - ## METTRE A JOUR DOLIBARR Pour mettre à jour Dolibarr depuis une vieille version vers celle ci: @@ -65,14 +62,12 @@ Pour mettre à jour Dolibarr depuis une vieille version vers celle ci: - Au prochain accès, Dolibarr proposera la page de "mise à jour" des données (si nécessaire). Si un fichier install.lock existe pour verrouiller le processus de mise à jour, il sera demandé de le supprimer manuellement (vous devriez trouver le fichier install.lock dans le répertoire utilisé pour stocker les documents générés ou transférés sur le serveur. Dans la plupart des cas, c'est le répertoire appelé "documents") -*Note: Le processus de migration peut être lancé manuellement et plusieurs fois, sans risque, en appelant la page /install/* - +Note: *Le processus de migration peut être lancé manuellement et plusieurs fois, sans risque, en appelant la page /install/* ## CE QUI EST NOUVEAU See the [ChangeLog](https://github.com/Dolibarr/dolibarr/blob/develop/ChangeLog) file. - ## CE QUE DOLIBARR PEUT FAIRE ### Modules principaux (tous optionnels) @@ -122,7 +117,7 @@ See the [ChangeLog](https://github.com/Dolibarr/dolibarr/blob/develop/ChangeLog) - Peux être multi-société par ajout du module externe multi-société. - Plusieurs thèmes visuels. - Application simple à utiliser. -- Requiert PHP et MariaDb, Mysql ou Postgresql (Voir versions exactes sur https://wiki.dolibarr.org/index.php/Prérequis). +- Requiert PHP et MariaDb, Mysql ou Postgresql (Voir versions exactes sur [https://wiki.dolibarr.org/index.php/Prérequis](https://wiki.dolibarr.org/index.php/Prérequis)). - Compatible avec toutes les offres Cloud du marché respectant les prérequis de base de données et PHP. - APIs. - Génération PDF et ODT des éléments (factures, propositions commerciales, commandes, bons expéditions, etc...) @@ -142,7 +137,6 @@ See the [ChangeLog](https://github.com/Dolibarr/dolibarr/blob/develop/ChangeLog) Dolibarr peut aussi être étendu à volonté avec l'ajout de module/applications externes développées par des développeus tiers, disponible sur [DoliStore](https://www.dolistore.com). - ## CE QUE DOLIBARR NE PEUT PAS (ENCORE) FAIRE Voici un liste de fonctionnalités pas encore gérées par Dolibarr: @@ -152,18 +146,15 @@ Voici un liste de fonctionnalités pas encore gérées par Dolibarr: - Dolibarr n'embarque pas de Webmail intégré nativement. - Dolibarr ne fait pas le café (pas encore). - ## DOCUMENTATION La documentation utilisateur, développeur et traducteur est disponible sous forme de ressources de la communauté via le site [Wiki](https://wiki.dolibarr.org). - ## CONTRIBUER Ce projet existe grâce à ses nombreux contributeurs [[Contribuer](https://github.com/Dolibarr/dolibarr/blob/develop/.github/CONTRIBUTING.md)]. - - +[![Dolibarr](https://opencollective.com/dolibarr/contributors.svg?width=890&button=false)](https://github.com/Dolibarr/dolibarr/graphs/contributors) ## CREDITS @@ -171,7 +162,6 @@ Dolibarr est le résultat du travail de nombreux contributeurs depuis des année Voir le fichier [COPYRIGHT](https://github.com/Dolibarr/dolibarr/blob/develop/COPYRIGHT) - ## ACTUALITES ET RESEAUX SOCIAUX Suivez le projet Dolibarr project sur les réseaux francophones diff --git a/README.md b/README.md index 54fdf1e958b..4e120a4cb91 100644 --- a/README.md +++ b/README.md @@ -4,6 +4,7 @@ ![Build status](https://img.shields.io/travis/Dolibarr/dolibarr/develop.svg) [![Minimum PHP Version](https://img.shields.io/badge/php-%3E%3D%205.6-8892BF.svg?style=flat-square)](https://php.net/) [![GitHub release](https://img.shields.io/github/v/release/Dolibarr/dolibarr)](https://github.com/Dolibarr/dolibarr) +[![CII Best Practices](https://bestpractices.coreinfrastructure.org/projects/5521/badge)](https://bestpractices.coreinfrastructure.org/projects/5521) Dolibarr ERP & CRM is a modern software package that helps manage your organization's activity (contacts, suppliers, invoices, orders, stocks, agenda…). @@ -43,7 +44,7 @@ You can use a web server and a supported database (MariaDB, MySQL or PostgreSQL) On GNU/Linux, first check if your distribution has already packaged Dolibarr. -#### Generic install steps: +#### Generic install steps - Check that your installed PHP version is supported [see PHP support](https://wiki.dolibarr.org/index.php/Releases). @@ -71,86 +72,87 @@ On GNU/Linux, first check if your distribution has already packaged Dolibarr. - Follow the installer instructions - ### Saas/Cloud setup -If you don't have time to install it yourself, you can try some commercial 'ready to use' Cloud offers (See https://saas.dolibarr.org). However, this third solution is not free. - +If you don't have time to install it yourself, you can try some commercial 'ready to use' Cloud offers (See [https://saas.dolibarr.org](https://saas.dolibarr.org)). However, this third solution is not free. ## UPGRADING Dolibarr supports upgrading, usually without the need for any (commercial) support (depending on if you use any commercial extensions). It supports upgrading all the way from any version after 2.8 without breakage. This is unique in the ERP ecosystem and a benefit our users highly appreciate! - + - At first make a backup of your Dolibarr files & then [see](https://wiki.dolibarr.org/index.php/Installation_-_Upgrade#Upgrade_Dolibarr) - Check that your installed PHP version is supported by the new version [see PHP support](./doc/phpmatrix.md). - Overwrite all old files from 'dolibarr' directory with files provided into the new version's package. - At first next access, Dolibarr will redirect you to the "install/" page to follow the upgrade process.  If an `install.lock` file exists to lock any other upgrade process, the application will ask you to remove the file manually (you should find the `install.lock` file in the directory used to store generated and uploaded documents, in most cases, it is the directory called "*documents*"). - ## WHAT'S NEW See the [ChangeLog](https://github.com/Dolibarr/dolibarr/blob/develop/ChangeLog) file. - ## FEATURES ### Main application/modules (all optional) -- Third-Parties Management: Customers, Prospects (Leads) and/or Suppliers + Contacts -- Members/Membership/Foundation management +- Third-Parties Management: Customers, Prospects (Leads) and/or Suppliers + Contacts +- Members/Membership/Foundation management - Product Management -- Products and/or Services catalog -- Stock / Warehouse management + Inventory -- Barcodes -- Batches / Lots / Serials -- Product Variants + Product Management + +- Products and/or Services catalog +- Stock / Warehouse management + Inventory +- Barcodes +- Batches / Lots / Serials +- Product Variants - Bill of Materials (BOM) -- Manufacturing Orders +- Manufacturing Orders - Customer/Sales Management -- Customers/Prospects + Contacts management -- Opportunities or Leads management -- Commercial proposals management -- Customer Orders management -- Contracts/Subscription management -- Interventions management -- Ticket System -- Shipping management -- Customer Invoices/Credit notes and payment management -- Point of Sale (POS) + Customer/Sales Management - Supplier/Purchase Management -- Suppliers/Vendors + Contacts -- Supplier (price) requests -- Purchase Orders management -- Delivery/Receiption -- Supplier Invoices/credit notes and payment management -- INCOTERMS +- Customers/Prospects + Contacts management +- Opportunities or Leads management +- Commercial proposals management +- Customer Orders management +- Contracts/Subscription management +- Interventions management +- Ticket System +- Shipping management +- Customer Invoices/Credit notes and payment management +- Point of Sale (POS) - Finance / Accounting -- Invoices / Payments -- Bank accounts management -- Direct debit orders management (European SEPA) -- Accounting management -- Donations management -- Loan management -- Margins -- Reports + Supplier/Purchase Management - Collaboration -- Shared calendar/agenda (with ical and vcal export for third party tools integration) -- Projects & Tasks management -- Ticket System +- Suppliers/Vendors + Contacts +- Supplier (price) requests +- Purchase Orders management +- Delivery/Receiption +- Supplier Invoices/credit notes and payment management +- INCOTERMS + + Finance / Accounting + +- Invoices / Payments +- Bank accounts management +- Direct debit orders management (European SEPA) +- Accounting management +- Donations management +- Loan management +- Margins +- Reports + + Collaboration + +- Shared calendar/agenda (with ical and vcal export for third party tools integration) +- Projects & Tasks management +- Ticket System - Surveys - HR -- Employee's leave requests management -- Expense reports -- Recruitment management -- Timesheets + HR +- Employee's leave requests management +- Expense reports +- Recruitment management +- Timesheets ### Other application/modules @@ -171,7 +173,6 @@ See the [ChangeLog](https://github.com/Dolibarr/dolibarr/blob/develop/ChangeLog) (around 100 modules available by default, 1000+ on the addon market place) - ### Other general features - Localization in most major languages @@ -190,27 +191,24 @@ See the [ChangeLog](https://github.com/Dolibarr/dolibarr/blob/develop/ChangeLog) - Canadian double taxes (federal/province) and other countries using cumulative VAT - Tunisian tax stamp - Argentina invoice numbering using A,B,C... - - Compatible with [European directives] (https://europa.eu/legislation_summaries/taxation/l31057_en.htm) (2006/112/CE ... 2010/45/UE) + - Compatible with [European directives](https://europa.eu/legislation_summaries/taxation/l31057_en.htm) (2006/112/CE ... 2010/45/UE) - Compatible with European GDPR rules - ... - Flexible PDF & ODT generation for invoices, proposals, orders... - ... - ### System Environment / Requirements - PHP -- MariaDB, MySQL or PostgreSQL +- MariaDB, MySQL or PostgreSQL - Compatible with all Cloud solutions that match PHP & MySQL or PostgreSQL prerequisites. See exact requirements on the [Wiki](https://wiki.dolibarr.org/index.php/Prerequisite) - ### Extending Dolibarr can be extended with a lot of other external application or modules from third party developers available at the [DoliStore](https://www.dolistore.com). - ## WHAT DOLIBARR CAN'T DO YET These are features that Dolibarr does **not** yet fully support: @@ -220,21 +218,18 @@ These are features that Dolibarr does **not** yet fully support: - No native embedded Webmail, but you can send email to contacts in Dolibarr with e.g. offers, invoices, etc. - Dolibarr can't do coffee (yet) - ## DOCUMENTATION Administrator, user, developer and translator's documentations are available along with other community resources in the [Wiki](https://wiki.dolibarr.org). - ## CONTRIBUTING -This project exists thanks to all the people who contribute. +This project exists thanks to all the people who contribute. Please read the instructions how to contribute (report a bug/error, a feature request, send code ...) [[Contribute](https://github.com/Dolibarr/dolibarr/blob/develop/.github/CONTRIBUTING.md)] A view on Contributors: - - +[![Dolibarr](https://opencollective.com/dolibarr/contributors.svg?width=890&button=false)](https://github.com/Dolibarr/dolibarr/graphs/contributors) ## CREDITS @@ -242,7 +237,6 @@ Dolibarr is the work of many contributors over the years and uses some fine PHP See [COPYRIGHT](https://github.com/Dolibarr/dolibarr/blob/develop/COPYRIGHT) file. - ## NEWS AND SOCIAL NETWORKS Follow Dolibarr project on: @@ -253,8 +247,6 @@ Follow Dolibarr project on: - [YouTube](https://www.youtube.com/user/DolibarrERPCRM) - [GitHub](https://github.com/Dolibarr/dolibarr) - ### Sponsors Support this project by becoming a sponsor. Your logo will show up here. 🙏 [[Become a sponsor/backer](https://opencollective.com/dolibarr#backer)] - diff --git a/SECURITY.md b/SECURITY.md index 427b1cc7ae2..cadd4a23791 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -6,14 +6,14 @@ This file contains some policies about the security reports on Dolibarr ERP CRM | Version | Supported | | ---------- | ---------------------- | -| <= 14.0.1 | :x: | -| >= 14.0.2+ | :white_check_mark: except CSRF attacks| +| <= 14.0.4 | :x: | +| >= 14.0.5+ | :white_check_mark: except CSRF attacks| | >= develop | :white_check_mark: | ## Reporting a Vulnerability -To report a vulnerability, please use GitHub security advisory at https://github.com/Dolibarr/dolibarr/security/advisories/new (if you have permissions) or alternatively send an email to security@dolibarr.org (for everybody) - +To report a vulnerability, for a private report, please use GitHub security advisory at [https://github.com/Dolibarr/dolibarr/security/advisories/new](https://github.com/Dolibarr/dolibarr/security/advisories/new) (if you have permissions). +Alternatively send an email to security@dolibarr.org (for everybody) ## Hunting vulnerabilities on Dolibarr @@ -23,7 +23,7 @@ If you believe you've found a security bug in our service, we are happy to work Any type of denial of service attacks is strictly forbidden, as well as any interference with network equipment and Dolibarr infrastructure. -We recommand to install Dolibarr ERP CRM on your own server (as most Open Source software, download and use is free: https://www.dolibarr.org/download) to get access on every side of application. +We recommand to install Dolibarr ERP CRM on your own server (as most Open Source software, download and use is free: [https://www.dolibarr.org/download](https://www.dolibarr.org/download)) to get access on every side of application. ### User Agent @@ -31,8 +31,7 @@ If you try to find bug on Dolibarr, we recommend to append to your user-agent he ### Account access -You can install the web application yourself on your own platform/server so you get full access to application and sources. Download the zip of the files to put into your own web server virtual host from https://www.dolibarr.org/download - +You can install the web application yourself on your own platform/server so you get full access to application and sources. Download the zip of the files to put into your own web server virtual host from [https://www.dolibarr.org/download](https://www.dolibarr.org/download) ## Eligibility and Responsible Disclosure @@ -46,7 +45,6 @@ You must avoid tests that could cause degradation or interruption of our service You must not leak, manipulate, or destroy any user data of third parties to find your vulnerability. - ## Scope for qualified vulnerabilities ONLY vulnerabilities discovered, when the following setup on test platform is used, are "valid": @@ -64,13 +62,12 @@ ONLY vulnerabilities discovered, when the following setup on test platform is us Scope is the web application (back office) and the APIs. - ## Qualifying vulnerabilities for reporting * Remote code execution (RCE) * Local files access and manipulation (LFI, RFI, XXE, SSRF, XSPA) * Code injections (HTML, JS, SQL, PHP, ...) -* Cross-Site Scripting (XSS), except from setup page of module "External web site" (allowing any content here, editable by admin user only, is accepted on purpose or into module "Web site" when permission to edit website content is allowed). +* Cross-Site Scripting (XSS), except from setup page of module "External web site" (allowing any content here, editable by admin user only, is accepted on purpose) and except into module "Web site" when permission to edit website content is allowed (injecting any data in this case is allowed too). * Cross-Site Requests Forgery (CSRF) with real security impact (when using GET URLs, CSRF are qualified only for creating, updating or deleting data from pages restricted to admin users) * Open redirect * Broken authentication & session management @@ -81,7 +78,6 @@ Scope is the web application (back office) and the APIs. * Software version disclosure (for non admin users only) * Stack traces or path disclosure (for non admin users only) - ## Non-qualifying vulnerabilities for reporting * "Self" XSS @@ -99,4 +95,3 @@ Scope is the web application (back office) and the APIs. * Software version or private IP disclosure when logged user is admin * Stack traces or path disclosure when logged user is admin * Any vulnerabilities due to a configuration different than the one defined into chapter "Scope for qualified vulnerabilities". - diff --git a/build/docker/Dockerfile b/build/docker/Dockerfile index eb8e3ade6dc..ead2a8af1c5 100644 --- a/build/docker/Dockerfile +++ b/build/docker/Dockerfile @@ -39,15 +39,13 @@ RUN chmod +x /usr/local/bin/docker-run.sh RUN pecl install xdebug && docker-php-ext-enable xdebug RUN echo 'zend_extension="/usr/local/lib/php/extensions/no-debug-non-zts-20180731/xdebug.so"' >> ${PHP_INI_DIR}/php.ini -RUN echo 'xdebug.remote_autostart=1' >> ${PHP_INI_DIR}/php.ini -RUN echo 'xdebug.remote_enable=1' >> ${PHP_INI_DIR}/php.ini -RUN echo 'xdebug.default_enable=1' >> ${PHP_INI_DIR}/php.ini -#RUN echo 'xdebug.remote_host=docker.host' >> ${PHP_INI_DIR}/php.ini -RUN echo 'xdebug.remote_port=9000' >> ${PHP_INI_DIR}/php.ini -RUN echo 'xdebug.remote_connect_back=1' >> ${PHP_INI_DIR}/php.ini -RUN echo 'xdebug.profiler_enable=0' >> ${PHP_INI_DIR}/php.ini -RUN echo 'xdebug.remote_log="/tmp/xdebug.log"' >> ${PHP_INI_DIR}/php.ini -#RUN echo 'localhost docker.host' >> /etc/hosts +RUN echo 'xdebug.mode=debug' >> ${PHP_INI_DIR}/php.ini +RUN echo 'xdebug.start_with_request=yes' >> ${PHP_INI_DIR}/php.ini +RUN echo 'xdebug.client_host=host.docker.internal' >> ${PHP_INI_DIR}/php.ini +RUN echo 'xdebug.client_port=9003' >> ${PHP_INI_DIR}/php.ini +RUN echo 'xdebug.discover_client_host=true' >> ${PHP_INI_DIR}/php.ini +#RUN echo 'xdebug.log="/tmp/xdebug.log"' >> ${PHP_INI_DIR}/php.ini +RUN echo 'xdebug.idekey="netbeans-xdebug"' >> ${PHP_INI_DIR}/php.ini # set up sendmail config, to use maildev RUN echo "account default" > /etc/msmtprc diff --git a/build/docker/docker-compose.yml b/build/docker/docker-compose.yml index b72118de5fb..8994043cd8a 100644 --- a/build/docker/docker-compose.yml +++ b/build/docker/docker-compose.yml @@ -48,6 +48,7 @@ services: - external-pod extra_hosts: - "localhost.localdomain:127.0.0.1" + - "host.docker.internal:host-gateway" mail: image: maildev/maildev diff --git a/build/pad/README b/build/pad/README index 3cbc171686c..241d27d01c2 100644 --- a/build/pad/README +++ b/build/pad/README @@ -1,6 +1,7 @@ README (English) ################################################## Building PAD files +http://pad.asp-software.org/padgen.php ################################################## This directory contains files and docs used to build diff --git a/build/perl/virtualmin/dolibarr.pl b/build/perl/virtualmin/dolibarr.pl index 8b6a9888db0..b5bacf59356 100644 --- a/build/perl/virtualmin/dolibarr.pl +++ b/build/perl/virtualmin/dolibarr.pl @@ -30,7 +30,7 @@ return "Regis Houssin"; # script_dolibarr_versions() sub script_dolibarr_versions { -return ( "12.0.3", "11.0.5", "10.0.7", "9.0.4", "8.0.6", "7.0.5" ); +return ( "14.0.5", "13.0.5", "12.0.5", "11.0.5", "10.0.7", "9.0.4", "8.0.6", "7.0.5" ); } sub script_dolibarr_release @@ -400,6 +400,8 @@ sub script_dolibarr_check_latest { local ($ver) = @_; local @vers = &osdn_package_versions("dolibarr", + $ver >= 14.0 ? "dolibarr\\-(12\\.0\\.[0-9\\.]+)\\.tgz" : + $ver >= 13.0 ? "dolibarr\\-(12\\.0\\.[0-9\\.]+)\\.tgz" : $ver >= 12.0 ? "dolibarr\\-(12\\.0\\.[0-9\\.]+)\\.tgz" : $ver >= 11.0 ? "dolibarr\\-(11\\.0\\.[0-9\\.]+)\\.tgz" : $ver >= 10.0 ? "dolibarr\\-(10\\.0\\.[0-9\\.]+)\\.tgz" : diff --git a/build/rpm/dolibarr_fedora.spec b/build/rpm/dolibarr_fedora.spec index dc23cff5486..27130244d00 100755 --- a/build/rpm/dolibarr_fedora.spec +++ b/build/rpm/dolibarr_fedora.spec @@ -166,7 +166,6 @@ done >>%{name}.lang %_datadir/dolibarr/htdocs/blockedlog %_datadir/dolibarr/htdocs/bookmarks %_datadir/dolibarr/htdocs/bom -%_datadir/dolibarr/htdocs/cashdesk %_datadir/dolibarr/htdocs/categories %_datadir/dolibarr/htdocs/collab %_datadir/dolibarr/htdocs/comm diff --git a/build/rpm/dolibarr_generic.spec b/build/rpm/dolibarr_generic.spec index a446a7bd5d6..aeddd5526f8 100755 --- a/build/rpm/dolibarr_generic.spec +++ b/build/rpm/dolibarr_generic.spec @@ -247,7 +247,6 @@ done >>%{name}.lang %_datadir/dolibarr/htdocs/blockedlog %_datadir/dolibarr/htdocs/bookmarks %_datadir/dolibarr/htdocs/bom -%_datadir/dolibarr/htdocs/cashdesk %_datadir/dolibarr/htdocs/categories %_datadir/dolibarr/htdocs/collab %_datadir/dolibarr/htdocs/comm diff --git a/build/rpm/dolibarr_mandriva.spec b/build/rpm/dolibarr_mandriva.spec index 78d90080258..a1e4dffc781 100755 --- a/build/rpm/dolibarr_mandriva.spec +++ b/build/rpm/dolibarr_mandriva.spec @@ -163,7 +163,6 @@ done >>%{name}.lang %_datadir/dolibarr/htdocs/blockedlog %_datadir/dolibarr/htdocs/bookmarks %_datadir/dolibarr/htdocs/bom -%_datadir/dolibarr/htdocs/cashdesk %_datadir/dolibarr/htdocs/categories %_datadir/dolibarr/htdocs/collab %_datadir/dolibarr/htdocs/comm diff --git a/build/rpm/dolibarr_opensuse.spec b/build/rpm/dolibarr_opensuse.spec index edae0126653..aed2d76ed29 100755 --- a/build/rpm/dolibarr_opensuse.spec +++ b/build/rpm/dolibarr_opensuse.spec @@ -174,7 +174,6 @@ done >>%{name}.lang %_datadir/dolibarr/htdocs/blockedlog %_datadir/dolibarr/htdocs/bookmarks %_datadir/dolibarr/htdocs/bom -%_datadir/dolibarr/htdocs/cashdesk %_datadir/dolibarr/htdocs/categories %_datadir/dolibarr/htdocs/collab %_datadir/dolibarr/htdocs/comm diff --git a/dev/dolibarr_changes.txt b/dev/dolibarr_changes.txt index 7ce22e790c3..204988c5442 100644 --- a/dev/dolibarr_changes.txt +++ b/dev/dolibarr_changes.txt @@ -111,6 +111,10 @@ with // DOL CHANGE If we keep this, the image is not visible on pages after the first one. //var_dump($file.' '.(!@TCPDF_STATIC::file_exists($file))); //return false; + $tfile = str_replace(' ', '%20', $file); + if (@TCPDF_STATIC::file_exists($tfile)) { + $file = $tfile; + } } * Replace in tcpdf.php @@ -205,6 +209,8 @@ with with foreach ($value[1] as $k => $v) { + + JSGANTT: -------- * Replace in function JSGantt.taskLink @@ -233,11 +239,13 @@ JCROP: * Remove analytics tag into file index.html + JQUERYFILETREE: --------------- * Remove directory htdocs/includes/jquery/plugins/jqueryFileTree/connectors + RESTLER: -------- diff --git a/dev/examples/code/README b/dev/examples/code/README index b7c31558de5..bf3dd3f4969 100644 --- a/dev/examples/code/README +++ b/dev/examples/code/README @@ -5,4 +5,4 @@ This directory contains samples of code to use Dolibarr business classes to buil external interfaces that need to read/update data from/into Dolibarr. You can also have a look at the Dolibarr doxygen doc that describes all files and classes: -http://www.dolibarr.org/html_doxygen/index.html +https://doxygen.dolibarr.org/ diff --git a/dev/examples/zapier/package.json b/dev/examples/zapier/package.json index a9d519dec69..8852928771f 100644 --- a/dev/examples/zapier/package.json +++ b/dev/examples/zapier/package.json @@ -15,7 +15,7 @@ "npm": ">=5.6.0" }, "dependencies": { - "zapier-platform-core": "11.0.1" + "zapier-platform-core": "11.3.1" }, "devDependencies": { "mocha": "^5.2.0", diff --git a/dev/initdemo/initdemo.sh b/dev/initdemo/initdemo.sh index 258eeaf646a..7e38e837e0f 100755 --- a/dev/initdemo/initdemo.sh +++ b/dev/initdemo/initdemo.sh @@ -132,7 +132,7 @@ then fichtemp=`tempfile 2>/dev/null` || fichtemp=/tmp/test$$ trap "rm -f $fichtemp" 0 1 2 5 15 $DIALOG --title "Init Dolibarr with demo values" --clear \ - --inputbox "Password for Mysql user login :" 16 55 2> $fichtemp + --passwordbox "Password for Mysql user login :" 16 55 2> $fichtemp valret=$? @@ -153,7 +153,7 @@ then # ---------------------------- confirmation DIALOG=${DIALOG=dialog} $DIALOG --title "Init Dolibarr with demo values" --clear \ - --yesno "Do you confirm ? \n Dump file : '$dumpfile' \n Dump dir : '$mydir' \n Document dir : '$documentdir' \n Mysql database : '$base' \n Mysql port : '$port' \n Mysql login: '$admin' \n Mysql password : '$passwd'" 15 55 + --yesno "Do you confirm ? \n Dump file : '$dumpfile' \n Dump dir : '$mydir' \n Document dir : '$documentdir' \n Mysql database : '$base' \n Mysql port : '$port' \n Mysql login: '$admin' \n Mysql password : --hidden--" 15 55 case $? in 0) echo "Ok, start process...";; diff --git a/dev/initdemo/mysqldump_dolibarr_14.0.0.sql b/dev/initdemo/mysqldump_dolibarr_15.0.0.sql similarity index 93% rename from dev/initdemo/mysqldump_dolibarr_14.0.0.sql rename to dev/initdemo/mysqldump_dolibarr_15.0.0.sql index e619c2c8fda..8b17c34203f 100644 --- a/dev/initdemo/mysqldump_dolibarr_14.0.0.sql +++ b/dev/initdemo/mysqldump_dolibarr_15.0.0.sql @@ -1,8 +1,8 @@ --- MySQL dump 10.19 Distrib 10.3.29-MariaDB, for debian-linux-gnu (x86_64) +-- MySQL dump 10.19 Distrib 10.3.31-MariaDB, for debian-linux-gnu (x86_64) -- --- Host: localhost Database: dolibarr_14 +-- Host: localhost Database: dolibarr_15 -- ------------------------------------------------------ --- Server version 10.3.29-MariaDB-0ubuntu0.20.04.1 +-- Server version 10.3.31-MariaDB-0ubuntu0.20.04.1 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; @@ -359,7 +359,7 @@ CREATE TABLE `llx_actioncomm` ( KEY `idx_actioncomm_datep2` (`datep2`), KEY `idx_actioncomm_recurid` (`recurid`), KEY `idx_actioncomm_ref_ext` (`ref_ext`) -) ENGINE=InnoDB AUTO_INCREMENT=607 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=608 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -368,7 +368,7 @@ CREATE TABLE `llx_actioncomm` ( LOCK TABLES `llx_actioncomm` WRITE; /*!40000 ALTER TABLE `llx_actioncomm` DISABLE KEYS */; -INSERT INTO `llx_actioncomm` VALUES (1,'1',NULL,1,'2012-07-08 14:21:44','2012-07-08 14:21:44',50,NULL,'Company AAA and Co added into Dolibarr','2012-07-08 14:21:44','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Company AAA and Co added into Dolibarr\nAuthor: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(2,'2',NULL,1,'2012-07-08 14:23:48','2012-07-08 14:23:48',50,NULL,'Company Belin SARL added into Dolibarr','2012-07-08 14:23:48','2021-04-15 10:22:55',1,NULL,NULL,2,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Company Belin SARL added into Dolibarr\nAuthor: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(3,'3',NULL,1,'2012-07-08 22:42:12','2012-07-08 22:42:12',50,NULL,'Company Spanish Comp added into Dolibarr','2012-07-08 22:42:12','2021-04-15 10:22:55',1,NULL,NULL,3,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Company Spanish Comp added into Dolibarr\nAuthor: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(4,'4',NULL,1,'2012-07-08 22:48:18','2012-07-08 22:48:18',50,NULL,'Company Prospector Vaalen added into Dolibarr','2012-07-08 22:48:18','2021-04-15 10:22:55',1,NULL,NULL,4,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Company Prospector Vaalen added into Dolibarr\nAuthor: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(5,'5',NULL,1,'2012-07-08 23:22:57','2012-07-08 23:22:57',50,NULL,'Company NoCountry Co added into Dolibarr','2012-07-08 23:22:57','2021-04-15 10:22:55',1,NULL,NULL,5,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Company NoCountry Co added into Dolibarr\nAuthor: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(6,'6',NULL,1,'2012-07-09 00:15:09','2012-07-09 00:15:09',50,NULL,'Company Swiss customer added into Dolibarr','2012-07-09 00:15:09','2021-04-15 10:22:55',1,NULL,NULL,6,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Company Swiss customer added into Dolibarr\nAuthor: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(7,'7',NULL,1,'2012-07-09 01:24:26','2012-07-09 01:24:26',50,NULL,'Company Generic customer added into Dolibarr','2012-07-09 01:24:26','2021-04-15 10:22:55',1,NULL,NULL,7,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Company Generic customer added into Dolibarr\nAuthor: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(8,'8',NULL,1,'2012-07-10 14:54:27','2012-07-10 14:54:27',50,NULL,'Société Client salon ajoutée dans Dolibarr','2012-07-10 14:54:27','2021-04-15 10:22:55',1,NULL,NULL,8,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Société Client salon ajoutée dans Dolibarr\nAuteur: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(9,'9',NULL,1,'2012-07-10 14:54:44','2012-07-10 14:54:44',50,NULL,'Société Client salon invidivdu ajoutée dans Doliba','2012-07-10 14:54:44','2021-04-15 10:22:55',1,NULL,NULL,9,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Société Client salon invidivdu ajoutée dans Dolibarr\nAuteur: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(10,'10',NULL,1,'2012-07-10 14:56:10','2012-07-10 14:56:10',50,NULL,'Facture FA1007-0001 validée dans Dolibarr','2012-07-10 14:56:10','2021-04-15 10:22:55',1,NULL,NULL,9,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Facture FA1007-0001 validée dans Dolibarr\nAuteur: admin',1,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(11,'11',NULL,1,'2012-07-10 14:58:53','2012-07-10 14:58:53',50,NULL,'Facture FA1007-0001 validée dans Dolibarr','2012-07-10 14:58:53','2021-04-15 10:22:55',1,NULL,NULL,9,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Facture FA1007-0001 validée dans Dolibarr\nAuteur: admin',1,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(12,'12',NULL,1,'2012-07-10 15:00:55','2012-07-10 15:00:55',50,NULL,'Facture FA1007-0001 passée à payée dans Dolibarr','2012-07-10 15:00:55','2021-04-15 10:22:55',1,NULL,NULL,9,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Facture FA1007-0001 passée à payée dans Dolibarr\nAuteur: admin',1,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(13,'13',NULL,1,'2012-07-10 15:13:08','2012-07-10 15:13:08',50,NULL,'Société Smith Vick ajoutée dans Dolibarr','2012-07-10 15:13:08','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Société Smith Vick ajoutée dans Dolibarr\nAuteur: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(14,'14',NULL,1,'2012-07-10 15:21:00','2012-07-10 16:21:00',5,NULL,'RDV avec mon chef','2012-07-10 15:21:48','2021-04-15 10:22:55',1,NULL,NULL,NULL,NULL,0,1,NULL,NULL,0,0,0,'',3600,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(15,'15',NULL,1,'2012-07-10 18:18:16','2012-07-10 18:18:16',50,NULL,'Contrat CONTRAT1 validé dans Dolibarr','2012-07-10 18:18:16','2021-04-15 10:22:55',1,NULL,NULL,2,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Contrat CONTRAT1 validé dans Dolibarr\nAuteur: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(16,'16',NULL,1,'2012-07-10 18:35:57','2012-07-10 18:35:57',50,NULL,'Société Mon client ajoutée dans Dolibarr','2012-07-10 18:35:57','2021-04-15 10:22:55',1,NULL,NULL,11,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Société Mon client ajoutée dans Dolibarr\nAuteur: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(17,'17',NULL,1,'2012-07-11 16:18:08','2012-07-11 16:18:08',50,NULL,'Société Dupont Alain ajoutée dans Dolibarr','2012-07-11 16:18:08','2021-04-15 10:22:55',1,NULL,NULL,12,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Société Dupont Alain ajoutée dans Dolibarr\nAuteur: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(18,'18',NULL,1,'2012-07-11 17:11:00','2012-07-11 17:17:00',5,NULL,'Rendez-vous','2012-07-11 17:11:22','2021-04-15 10:22:55',1,NULL,NULL,NULL,NULL,0,1,NULL,NULL,0,0,0,'gfgdfgdf',360,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(19,'19',NULL,1,'2012-07-11 17:13:20','2012-07-11 17:13:20',50,NULL,'Société Vendeur de chips ajoutée dans Dolibarr','2012-07-11 17:13:20','2021-04-15 10:22:55',1,NULL,NULL,13,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Société Vendeur de chips ajoutée dans Dolibarr\nAuteur: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(20,'20',NULL,1,'2012-07-11 17:15:42','2012-07-11 17:15:42',50,NULL,'Commande CF1007-0001 validée','2012-07-11 17:15:42','2021-04-15 10:22:55',1,NULL,NULL,13,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Commande CF1007-0001 validée\nAuteur: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(21,'21',NULL,1,'2012-07-11 18:47:33','2012-07-11 18:47:33',50,NULL,'Commande CF1007-0002 validée','2012-07-11 18:47:33','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Commande CF1007-0002 validée\nAuteur: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(22,'22',NULL,1,'2012-07-18 11:36:18','2012-07-18 11:36:18',50,NULL,'Proposition PR1007-0003 validée','2012-07-18 11:36:18','2021-04-15 10:22:55',1,NULL,NULL,4,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Proposition PR1007-0003 validée\nAuteur: admin',3,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(23,'23',NULL,1,'2013-07-18 20:49:58','2013-07-18 20:49:58',50,NULL,'Invoice FA1007-0002 validated in Dolibarr','2013-07-18 20:49:58','2021-04-15 10:22:55',1,NULL,NULL,2,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1007-0002 validated in Dolibarr\nAuthor: admin',2,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(24,'24',NULL,1,'2013-07-28 01:37:00',NULL,1,NULL,'Phone call','2013-07-28 01:37:48','2021-04-15 10:22:55',1,NULL,NULL,NULL,2,0,1,NULL,NULL,0,0,-1,'',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(25,'25',NULL,1,'2013-08-01 02:31:24','2013-08-01 02:31:24',50,NULL,'Company mmm added into Dolibarr','2013-08-01 02:31:24','2021-04-15 10:22:55',1,NULL,NULL,15,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Company mmm added into Dolibarr\nAuthor: admin',15,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(26,'26',NULL,1,'2013-08-01 02:31:43','2013-08-01 02:31:43',50,NULL,'Company ppp added into Dolibarr','2013-08-01 02:31:43','2021-04-15 10:22:55',1,NULL,NULL,16,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Company ppp added into Dolibarr\nAuthor: admin',16,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(27,'27',NULL,1,'2013-08-01 02:41:26','2013-08-01 02:41:26',50,NULL,'Company aaa added into Dolibarr','2013-08-01 02:41:26','2021-04-15 10:22:55',1,NULL,NULL,17,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Company aaa added into Dolibarr\nAuthor: admin',17,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(28,'28',NULL,1,'2013-08-01 03:34:11','2013-08-01 03:34:11',50,NULL,'Invoice FA1108-0003 validated in Dolibarr','2013-08-01 03:34:11','2021-04-15 10:22:55',1,NULL,NULL,7,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1108-0003 validated in Dolibarr\nAuthor: admin',5,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(29,'29',NULL,1,'2013-08-01 03:34:11','2013-08-01 03:34:11',50,NULL,'Invoice FA1108-0003 validated in Dolibarr','2013-08-01 03:34:11','2021-04-15 10:22:55',1,NULL,NULL,7,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1108-0003 changed to paid in Dolibarr\nAuthor: admin',5,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(30,'30',NULL,1,'2013-08-06 20:33:54','2013-08-06 20:33:54',50,NULL,'Invoice FA1108-0004 validated in Dolibarr','2013-08-06 20:33:54','2021-04-15 10:22:55',1,NULL,NULL,7,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1108-0004 validated in Dolibarr\nAuthor: admin',6,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(31,'31',NULL,1,'2013-08-06 20:33:54','2013-08-06 20:33:54',50,NULL,'Invoice FA1108-0004 validated in Dolibarr','2013-08-06 20:33:54','2021-04-15 10:22:55',1,NULL,NULL,7,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1108-0004 changed to paid in Dolibarr\nAuthor: admin',6,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(38,'38',NULL,1,'2013-08-08 02:41:55','2013-08-08 02:41:55',50,NULL,'Invoice FA1108-0005 validated in Dolibarr','2013-08-08 02:41:55','2021-04-15 10:22:55',1,NULL,NULL,2,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1108-0005 validated in Dolibarr\nAuthor: admin',8,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(40,'40',NULL,1,'2013-08-08 02:53:40','2013-08-08 02:53:40',50,NULL,'Invoice FA1108-0005 changed to paid in Dolibarr','2013-08-08 02:53:40','2021-04-15 10:22:55',1,NULL,NULL,2,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1108-0005 changed to paid in Dolibarr\nAuthor: admin',8,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(41,'41',NULL,1,'2013-08-08 02:54:05','2013-08-08 02:54:05',50,NULL,'Invoice FA1007-0002 changed to paid in Dolibarr','2013-08-08 02:54:05','2021-04-15 10:22:55',1,NULL,NULL,2,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1007-0002 changed to paid in Dolibarr\nAuthor: admin',2,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(42,'42',NULL,1,'2013-08-08 02:55:04','2013-08-08 02:55:04',50,NULL,'Invoice FA1107-0006 validated in Dolibarr','2013-08-08 02:55:04','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1107-0006 validated in Dolibarr\nAuthor: admin',3,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(43,'43',NULL,1,'2013-08-08 02:55:26','2013-08-08 02:55:26',50,NULL,'Invoice FA1108-0007 validated in Dolibarr','2013-08-08 02:55:26','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1108-0007 validated in Dolibarr\nAuthor: admin',9,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(44,'44',NULL,1,'2013-08-08 02:55:58','2013-08-08 02:55:58',50,NULL,'Invoice FA1107-0006 changed to paid in Dolibarr','2013-08-08 02:55:58','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1107-0006 changed to paid in Dolibarr\nAuthor: admin',3,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(45,'45',NULL,1,'2013-08-08 03:04:22','2013-08-08 03:04:22',50,NULL,'Order CO1108-0001 validated','2013-08-08 03:04:22','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Order CO1108-0001 validated\nAuthor: admin',5,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(46,'46',NULL,1,'2013-08-08 13:59:09','2013-08-08 13:59:09',50,NULL,'Order CO1107-0002 validated','2013-08-08 13:59:10','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Order CO1107-0002 validated\nAuthor: admin',1,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(47,'47',NULL,1,'2013-08-08 14:24:18','2013-08-08 14:24:18',50,NULL,'Proposal PR1007-0001 validated','2013-08-08 14:24:18','2021-04-15 10:22:55',1,NULL,NULL,2,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Proposal PR1007-0001 validated\nAuthor: admin',1,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(48,'48',NULL,1,'2013-08-08 14:24:24','2013-08-08 14:24:24',50,NULL,'Proposal PR1108-0004 validated','2013-08-08 14:24:24','2021-04-15 10:22:55',1,NULL,NULL,17,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Proposal PR1108-0004 validated\nAuthor: admin',4,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(49,'49',NULL,1,'2013-08-08 15:04:37','2013-08-08 15:04:37',50,NULL,'Order CF1108-0003 validated','2013-08-08 15:04:37','2021-04-15 10:22:55',1,NULL,NULL,17,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Order CF1108-0003 validated\nAuthor: admin',6,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(50,'50',NULL,1,'2014-12-08 17:56:47','2014-12-08 17:56:47',40,NULL,'Facture AV1212-0001 validée dans Dolibarr','2014-12-08 17:56:47','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture AV1212-0001 validée dans Dolibarr\nAuteur: admin',10,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(51,'51',NULL,1,'2014-12-08 17:57:11','2014-12-08 17:57:11',40,NULL,'Facture AV1212-0001 validée dans Dolibarr','2014-12-08 17:57:11','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture AV1212-0001 validée dans Dolibarr\nAuteur: admin',10,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(52,'52',NULL,1,'2014-12-08 17:58:27','2014-12-08 17:58:27',40,NULL,'Facture FA1212-0008 validée dans Dolibarr','2014-12-08 17:58:27','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1212-0008 validée dans Dolibarr\nAuteur: admin',11,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(53,'53',NULL,1,'2014-12-08 18:20:49','2014-12-08 18:20:49',40,NULL,'Facture AV1212-0002 validée dans Dolibarr','2014-12-08 18:20:49','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture AV1212-0002 validée dans Dolibarr\nAuteur: admin',12,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(54,'54',NULL,1,'2014-12-09 18:35:07','2014-12-09 18:35:07',40,NULL,'Facture AV1212-0002 passée à payée dans Dolibarr','2014-12-09 18:35:07','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture AV1212-0002 passée à payée dans Dolibarr\nAuteur: admin',12,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(55,'55',NULL,1,'2014-12-09 20:14:42','2014-12-09 20:14:42',40,NULL,'Société doe john ajoutée dans Dolibarr','2014-12-09 20:14:42','2021-04-15 10:22:55',1,NULL,NULL,18,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Société doe john ajoutée dans Dolibarr\nAuteur: admin',18,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(56,'56',NULL,1,'2014-12-12 18:54:19','2014-12-12 18:54:19',40,NULL,'Facture FA1212-0009 validée dans Dolibarr','2014-12-12 18:54:19','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1212-0009 validée dans Dolibarr\nAuteur: admin',55,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(121,'121',NULL,1,'2014-12-06 10:00:00',NULL,50,NULL,'aaab','2014-12-21 17:48:08','2021-04-15 10:22:55',3,1,NULL,NULL,NULL,0,3,NULL,NULL,1,0,-1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(122,'122',NULL,1,'2014-12-21 18:09:52','2014-12-21 18:09:52',40,NULL,'Facture client FA1007-0001 envoyée par EMail','2014-12-21 18:09:52','2021-04-15 10:22:55',1,NULL,NULL,9,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Mail envoyé par Firstname SuperAdminName à laurent@mycompany.fr.\nSujet du mail: Envoi facture FA1007-0001\nCorps du mail:\nVeuillez trouver ci-joint la facture FA1007-0001\r\n\r\nVous pouvez cliquer sur le lien sécurisé ci-dessous pour effectuer votre paiement via Paypal\r\n\r\nhttp://localhost/dolibarrnew/public/paypal/newpayment.php?source=invoice&ref=FA1007-0001&securekey=50c82fab36bb3b6aa83e2a50691803b2\r\n\r\nCordialement',1,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(123,'123',NULL,1,'2015-01-06 13:13:57','2015-01-06 13:13:57',40,NULL,'Facture 16 validée dans Dolibarr','2015-01-06 13:13:57','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture 16 validée dans Dolibarr\nAuteur: admin',16,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(124,'124',NULL,1,'2015-01-12 12:23:05','2015-01-12 12:23:05',40,NULL,'Patient aaa ajouté','2015-01-12 12:23:05','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Patient aaa ajouté\nAuteur: admin',19,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(125,'125',NULL,1,'2015-01-12 12:52:20','2015-01-12 12:52:20',40,NULL,'Patient pppoo ajouté','2015-01-12 12:52:20','2021-04-15 10:22:55',1,NULL,NULL,20,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Patient pppoo ajouté\nAuteur: admin',20,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(127,'127',NULL,1,'2015-01-19 18:22:48','2015-01-19 18:22:48',40,NULL,'Facture FS1301-0001 validée dans Dolibarr','2015-01-19 18:22:48','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FS1301-0001 validée dans Dolibarr\nAuteur: admin',148,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(128,'128',NULL,1,'2015-01-19 18:31:10','2015-01-19 18:31:10',40,NULL,'Facture FA6801-0010 validée dans Dolibarr','2015-01-19 18:31:10','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA6801-0010 validée dans Dolibarr\nAuteur: admin',150,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(129,'129',NULL,1,'2015-01-19 18:31:10','2015-01-19 18:31:10',40,NULL,'Facture FA6801-0010 passée à payée dans Dolibarr','2015-01-19 18:31:10','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA6801-0010 passée à payée dans Dolibarr\nAuteur: admin',150,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(130,'130',NULL,1,'2015-01-19 18:31:58','2015-01-19 18:31:58',40,NULL,'Facture FS1301-0002 validée dans Dolibarr','2015-01-19 18:31:58','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FS1301-0002 validée dans Dolibarr\nAuteur: admin',151,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(131,'131',NULL,1,'2015-01-19 18:31:58','2015-01-19 18:31:58',40,NULL,'Facture FS1301-0002 passée à payée dans Dolibarr','2015-01-19 18:31:58','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FS1301-0002 passée à payée dans Dolibarr\nAuteur: admin',151,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(132,'132',NULL,1,'2015-01-23 15:07:54','2015-01-23 15:07:54',50,NULL,'Consultation 24 saisie (aaa)','2015-01-23 15:07:54','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Consultation 24 saisie (aaa)\nAuteur: admin',24,'cabinetmed_cons',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(133,'133',NULL,1,'2015-01-23 16:56:58','2015-01-23 16:56:58',40,NULL,'Patient pa ajouté','2015-01-23 16:56:58','2021-04-15 10:22:55',1,NULL,NULL,21,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Patient pa ajouté\nAuteur: admin',21,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(134,'134',NULL,1,'2015-01-23 17:34:00',NULL,50,NULL,'bbcv','2015-01-23 17:35:21','2021-04-15 10:22:55',1,NULL,1,2,NULL,0,1,NULL,NULL,0,0,-1,'',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(135,'135',NULL,1,'2015-02-12 15:54:00','2015-02-12 15:54:00',40,NULL,'Facture FA1212-0011 validée dans Dolibarr','2015-02-12 15:54:37','2021-04-15 10:22:55',1,1,NULL,7,NULL,0,1,NULL,1,0,0,50,NULL,NULL,NULL,'Facture FA1212-0011 validée dans Dolibarr
\r\nAuteur: admin',13,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(136,'136',NULL,1,'2015-02-12 17:06:51','2015-02-12 17:06:51',40,NULL,'Commande CO1107-0003 validée','2015-02-12 17:06:51','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Commande CO1107-0003 validée\nAuteur: admin',2,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(137,'137',NULL,1,'2015-02-17 16:22:10','2015-02-17 16:22:10',40,NULL,'Proposition PR1302-0009 validée','2015-02-17 16:22:10','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Proposition PR1302-0009 validée\nAuteur: admin',9,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(138,'138',NULL,1,'2015-02-17 16:27:00','2015-02-17 16:27:00',40,NULL,'Facture FA1302-0012 validée dans Dolibarr','2015-02-17 16:27:00','2021-04-15 10:22:55',1,NULL,NULL,18,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1302-0012 validée dans Dolibarr\nAuteur: admin',152,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(139,'139',NULL,1,'2015-02-17 16:27:29','2015-02-17 16:27:29',40,NULL,'Proposition PR1302-0010 validée','2015-02-17 16:27:29','2021-04-15 10:22:55',1,NULL,NULL,18,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Proposition PR1302-0010 validée\nAuteur: admin',11,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(140,'140',NULL,1,'2015-02-17 18:27:56','2015-02-17 18:27:56',40,NULL,'Commande CO1107-0004 validée','2015-02-17 18:27:56','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Commande CO1107-0004 validée\nAuteur: admin',3,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(141,'141',NULL,1,'2015-02-17 18:38:14','2015-02-17 18:38:14',40,NULL,'Commande CO1302-0005 validée','2015-02-17 18:38:14','2021-04-15 10:22:55',1,NULL,NULL,18,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Commande CO1302-0005 validée\nAuteur: admin',7,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(142,'142',NULL,1,'2015-02-26 22:57:50','2015-02-26 22:57:50',40,NULL,'Company pppp added into Dolibarr','2015-02-26 22:57:50','2021-04-15 10:22:55',1,NULL,NULL,22,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Company pppp added into Dolibarr\nAuthor: admin',22,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(143,'143',NULL,1,'2015-02-26 22:58:13','2015-02-26 22:58:13',40,NULL,'Company ttttt added into Dolibarr','2015-02-26 22:58:13','2021-04-15 10:22:55',1,NULL,NULL,23,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Company ttttt added into Dolibarr\nAuthor: admin',23,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(144,'144',NULL,1,'2015-02-27 10:00:00','2015-02-27 19:20:00',5,NULL,'Rendez-vous','2015-02-27 19:20:53','2021-04-15 10:22:55',1,NULL,NULL,NULL,NULL,0,1,NULL,1,0,0,-1,'',33600,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(145,'145',NULL,1,'2015-02-27 19:28:00',NULL,2,NULL,'fdsfsd','2015-02-27 19:28:48','2021-04-15 10:22:55',1,1,NULL,NULL,NULL,0,1,NULL,1,0,0,-1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(146,'146',NULL,1,'2015-03-06 10:05:07','2015-03-06 10:05:07',40,NULL,'Contrat (PROV3) validé dans Dolibarr','2015-03-06 10:05:07','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Contrat (PROV3) validé dans Dolibarr\nAuteur: admin',3,'contract',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(147,'147',NULL,1,'2015-03-06 16:43:37','2015-03-06 16:43:37',40,NULL,'Facture FA1307-0013 validée dans Dolibarr','2015-03-06 16:43:37','2021-04-15 10:22:55',1,NULL,NULL,12,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1307-0013 validée dans Dolibarr\nAuteur: admin',158,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(148,'148',NULL,1,'2015-03-06 16:44:12','2015-03-06 16:44:12',40,NULL,'Facture FA1407-0014 validée dans Dolibarr','2015-03-06 16:44:12','2021-04-15 10:22:55',1,NULL,NULL,12,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1407-0014 validée dans Dolibarr\nAuteur: admin',159,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(149,'149',NULL,1,'2015-03-06 16:47:48','2015-03-06 16:47:48',40,NULL,'Facture FA1507-0015 validée dans Dolibarr','2015-03-06 16:47:48','2021-04-15 10:22:55',1,NULL,NULL,12,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1507-0015 validée dans Dolibarr\nAuteur: admin',160,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(150,'150',NULL,1,'2015-03-06 16:48:16','2015-03-06 16:48:16',40,NULL,'Facture FA1607-0016 validée dans Dolibarr','2015-03-06 16:48:16','2021-04-15 10:22:55',1,NULL,NULL,12,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1607-0016 validée dans Dolibarr\nAuteur: admin',161,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(151,'151',NULL,1,'2015-03-06 17:13:59','2015-03-06 17:13:59',40,NULL,'Société smith smith ajoutée dans Dolibarr','2015-03-06 17:13:59','2021-04-15 10:22:55',1,NULL,NULL,24,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Société smith smith ajoutée dans Dolibarr\nAuteur: admin',24,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(152,'152',NULL,1,'2015-03-08 10:02:22','2015-03-08 10:02:22',40,NULL,'Proposition (PROV12) validée dans Dolibarr','2015-03-08 10:02:22','2021-04-15 10:22:55',1,NULL,NULL,23,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Proposition (PROV12) validée dans Dolibarr\nAuteur: admin',12,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(203,'203',NULL,1,'2015-03-09 19:39:27','2015-03-09 19:39:27',40,'AC_ORDER_SUPPLIER_VALIDATE','Commande CF1303-0004 validée','2015-03-09 19:39:27','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Commande CF1303-0004 validée\nAuteur: admin',13,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(204,'204',NULL,1,'2015-03-10 15:47:37','2015-03-10 15:47:37',40,'AC_COMPANY_CREATE','Patient créé','2015-03-10 15:47:37','2021-04-15 10:22:55',1,NULL,NULL,25,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Patient créé\nAuteur: admin',25,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(205,'205',NULL,1,'2015-03-10 15:57:32','2015-03-10 15:57:32',40,'AC_COMPANY_CREATE','Tiers créé','2015-03-10 15:57:32','2021-04-15 10:22:55',1,NULL,NULL,26,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Tiers créé\nAuteur: admin',26,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(206,'206',NULL,1,'2015-03-10 15:58:28','2015-03-10 15:58:28',40,'AC_BILL_VALIDATE','Facture FA1303-0017 validée','2015-03-10 15:58:28','2021-04-15 10:22:55',1,NULL,NULL,26,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1303-0017 validée\nAuteur: admin',208,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(207,'207',NULL,1,'2015-03-19 09:38:10','2015-03-19 09:38:10',40,'AC_BILL_VALIDATE','Facture FA1303-0018 validée','2015-03-19 09:38:10','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1303-0018 validée\nAuteur: admin',209,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(208,'208',NULL,1,'2015-03-20 14:30:11','2015-03-20 14:30:11',40,'AC_BILL_VALIDATE','Facture FA1107-0019 validée','2015-03-20 14:30:11','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1107-0019 validée\nAuteur: admin',210,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(209,'209',NULL,1,'2015-03-22 09:40:25','2015-03-22 09:40:25',40,'AC_BILL_VALIDATE','Facture FA1303-0020 validée','2015-03-22 09:40:25','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1303-0020 validée\nAuteur: admin',211,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(210,'210',NULL,1,'2015-03-23 17:16:25','2015-03-23 17:16:25',40,'AC_BILL_VALIDATE','Facture FA1303-0020 validée','2015-03-23 17:16:25','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1303-0020 validée\nAuteur: admin',211,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(211,'211',NULL,1,'2015-03-23 18:08:27','2015-03-23 18:08:27',40,'AC_BILL_VALIDATE','Facture FA1307-0013 validée','2015-03-23 18:08:27','2021-04-15 10:22:55',1,NULL,NULL,12,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1307-0013 validée\nAuteur: admin',158,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(212,'212',NULL,1,'2015-03-24 15:54:00','2015-03-24 15:54:00',40,'AC_BILL_VALIDATE','Facture FA1212-0021 validée','2015-03-24 15:54:00','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1212-0021 validée\nAuteur: admin',32,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(213,'213',NULL,1,'2015-11-07 01:02:39','2015-11-07 01:02:39',40,'AC_COMPANY_CREATE','Third party created','2015-11-07 01:02:39','2021-04-15 10:22:55',1,NULL,NULL,27,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Third party created\nAuthor: admin',27,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(214,'214',NULL,1,'2015-11-07 01:05:22','2015-11-07 01:05:22',40,'AC_COMPANY_CREATE','Third party created','2015-11-07 01:05:22','2021-04-15 10:22:55',1,NULL,NULL,28,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Third party created\nAuthor: admin',28,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(215,'215',NULL,1,'2015-11-07 01:07:07','2015-11-07 01:07:07',40,'AC_COMPANY_CREATE','Third party created','2015-11-07 01:07:07','2021-04-15 10:22:55',1,NULL,NULL,29,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Third party created\nAuthor: admin',29,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(216,'216',NULL,1,'2015-11-07 01:07:58','2015-11-07 01:07:58',40,'AC_COMPANY_CREATE','Third party created','2015-11-07 01:07:58','2021-04-15 10:22:55',1,NULL,NULL,30,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Third party created\nAuthor: admin',30,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(217,'217',NULL,1,'2015-11-07 01:10:09','2015-11-07 01:10:09',40,'AC_COMPANY_CREATE','Third party created','2015-11-07 01:10:09','2021-04-15 10:22:55',1,NULL,NULL,31,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Third party created\nAuthor: admin',31,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(218,'218',NULL,1,'2015-11-07 01:15:57','2015-11-07 01:15:57',40,'AC_COMPANY_CREATE','Third party created','2015-11-07 01:15:57','2021-04-15 10:22:55',1,NULL,NULL,32,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Third party created\nAuthor: admin',32,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(219,'219',NULL,1,'2015-11-07 01:16:51','2015-11-07 01:16:51',40,'AC_COMPANY_CREATE','Third party created','2015-11-07 01:16:51','2021-04-15 10:22:55',1,NULL,NULL,33,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Third party created\nAuthor: admin',33,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(220,'220',NULL,1,'2016-03-02 17:24:04','2016-03-02 17:24:04',40,'AC_BILL_VALIDATE','Invoice FA1302-0022 validated','2016-03-02 17:24:04','2021-04-15 10:22:55',1,NULL,NULL,18,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Invoice FA1302-0022 validated\nAuthor: admin',157,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(221,'221',NULL,1,'2016-03-02 17:24:28','2016-03-02 17:24:28',40,'AC_BILL_VALIDATE','Invoice FA1303-0020 validated','2016-03-02 17:24:28','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Invoice FA1303-0020 validated\nAuthor: admin',211,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(222,'222',NULL,1,'2016-03-05 10:00:00','2016-03-05 10:00:00',5,NULL,'RDV John','2016-03-02 19:54:48','2021-04-15 10:22:55',1,1,NULL,NULL,NULL,0,1,0,NULL,0,0,-1,NULL,NULL,NULL,'gfdgdfgdf',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(223,'223',NULL,1,'2016-03-13 10:00:00','2016-03-17 00:00:00',50,NULL,'Congress','2016-03-02 19:55:11','2021-04-15 10:22:55',1,NULL,NULL,NULL,NULL,0,1,0,NULL,0,0,-1,'',309600,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(224,'224',NULL,1,'2016-03-14 10:00:00',NULL,1,NULL,'Call john','2016-03-02 19:55:56','2021-04-15 10:22:55',1,NULL,NULL,NULL,NULL,0,1,0,NULL,0,0,0,'',NULL,NULL,'tttt',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(225,'225',NULL,1,'2016-03-02 20:11:31','2016-03-02 20:11:31',40,'AC_BILL_UNVALIDATE','Invoice FA1303-0020 go back to draft status','2016-03-02 20:11:31','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Invoice FA1303-0020 go back to draft status\nAuthor: admin',211,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(226,'226',NULL,1,'2016-03-02 20:13:39','2016-03-02 20:13:39',40,'AC_BILL_VALIDATE','Invoice FA1303-0020 validated','2016-03-02 20:13:39','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Invoice FA1303-0020 validated\nAuthor: admin',211,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(227,'227',NULL,1,'2016-03-03 19:20:10','2016-03-03 19:20:10',40,'AC_BILL_VALIDATE','Invoice FA1212-0023 validated','2016-03-03 19:20:10','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Invoice FA1212-0023 validated\nAuthor: admin',33,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(228,'228',NULL,1,'2016-03-03 19:20:25','2016-03-03 19:20:25',40,'AC_BILL_CANCEL','Invoice FA1212-0023 canceled in Dolibarr','2016-03-03 19:20:25','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Invoice FA1212-0023 canceled in Dolibarr\nAuthor: admin',33,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(229,'229',NULL,1,'2016-03-03 19:20:56','2016-03-03 19:20:56',40,'AC_BILL_VALIDATE','Invoice AV1403-0003 validated','2016-03-03 19:20:56','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Invoice AV1403-0003 validated\nAuthor: admin',212,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(230,'230',NULL,1,'2016-03-03 19:21:29','2016-03-03 19:21:29',40,'AC_BILL_UNVALIDATE','Invoice AV1403-0003 go back to draft status','2016-03-03 19:21:29','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Invoice AV1403-0003 go back to draft status\nAuthor: admin',212,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(231,'231',NULL,1,'2016-03-03 19:22:16','2016-03-03 19:22:16',40,'AC_BILL_VALIDATE','Invoice AV1303-0003 validated','2016-03-03 19:22:16','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Invoice AV1303-0003 validated\nAuthor: admin',213,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(232,'232',NULL,1,'2018-01-22 18:54:39','2018-01-22 18:54:39',40,'AC_OTH_AUTO','Invoice 16 validated','2018-01-22 18:54:39','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Invoice 16 validated\nAuthor: admin',16,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(233,'233',NULL,1,'2018-01-22 18:54:46','2018-01-22 18:54:46',40,'AC_OTH_AUTO','Invoice 16 validated','2018-01-22 18:54:46','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Invoice 16 validated\nAuthor: admin',16,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(234,'234',NULL,1,'2018-07-05 10:00:00','2018-07-05 11:19:00',5,'AC_RDV','Meeting with my boss','2018-07-31 18:19:48','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,1,NULL,0,0,-1,'',4740,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(235,'235',NULL,1,'2018-07-13 00:00:00','2018-07-14 23:59:59',50,'AC_OTH','Trip at Las Vegas','2018-07-31 18:20:36','2021-04-15 10:22:55',12,NULL,4,NULL,2,0,12,1,NULL,0,1,-1,'',172799,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(236,'236',NULL,1,'2018-07-29 10:00:00',NULL,4,'AC_EMAIL','Remind to send an email','2018-07-31 18:21:04','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,4,0,NULL,0,0,-1,'',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(237,'237',NULL,1,'2018-07-01 10:00:00',NULL,1,'AC_TEL','Phone call with Mr Vaalen','2018-07-31 18:22:04','2021-04-15 10:22:55',12,NULL,6,4,NULL,0,13,0,NULL,0,0,-1,'',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(238,'238',NULL,1,'2018-08-02 10:00:00','2018-08-02 12:00:00',5,'AC_RDV','Meeting on radium','2018-08-01 01:15:50','2021-04-15 10:22:55',12,NULL,8,10,10,0,12,1,NULL,0,0,-1,'',7200,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(239,'239',NULL,1,'2017-01-29 21:49:33','2017-01-29 21:49:33',40,'AC_OTH_AUTO','Proposal PR1302-0007 validated','2017-01-29 21:49:33','2021-04-15 10:22:55',12,NULL,NULL,19,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1302-0007 validated\nAuthor: admin',7,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(240,'240',NULL,1,'2017-01-31 20:52:00',NULL,1,'AC_TEL','Call the boss','2017-01-31 20:52:10','2021-04-15 10:22:55',12,12,6,NULL,NULL,0,12,1,NULL,0,0,-1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(242,'242',NULL,1,'2017-02-01 18:52:04','2017-02-01 18:52:04',40,'AC_OTH_AUTO','Order CF1007-0001 validated','2017-02-01 18:52:04','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CF1007-0001 validated\nAuthor: admin',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(243,'243',NULL,1,'2017-02-01 18:52:04','2017-02-01 18:52:04',40,'AC_OTH_AUTO','Order CF1007-0001 approved','2017-02-01 18:52:04','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CF1007-0001 approved\nAuthor: admin',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(245,'245',NULL,1,'2017-02-01 18:52:32','2017-02-01 18:52:32',40,'AC_OTH_AUTO','Supplier order CF1007-0001 submited','2017-02-01 18:52:32','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Supplier order CF1007-0001 submited\nAuthor: admin',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(249,'249',NULL,1,'2017-02-01 18:54:01','2017-02-01 18:54:01',40,'AC_OTH_AUTO','Supplier order CF1007-0001 received','2017-02-01 18:54:01','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Supplier order CF1007-0001 received \nAuthor: admin',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(250,'250',NULL,1,'2017-02-01 18:54:42','2017-02-01 18:54:42',40,'AC_OTH_AUTO','Email sent by MyBigCompany To mycustomer@example.com','2017-02-01 18:54:42','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Sender: MyBigCompany <myemail@mybigcompany.com>
\nReceiver(s): mycustomer@example.com
\nEMail topic: Submission of order CF1007-0001
\nEmail body:
\nYou will find here our order CF1007-0001
\r\n
\r\nSincerely
\n
\nAttached files and documents: CF1007-0001.pdf',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(251,'251',NULL,1,'2017-02-01 19:02:21','2017-02-01 19:02:21',40,'AC_OTH_AUTO','Invoice SI1702-0001 validated','2017-02-01 19:02:21','2021-04-15 10:22:55',12,NULL,5,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Invoice SI1702-0001 validated\nAuthor: admin',20,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(252,'252',NULL,1,'2017-02-12 23:17:04','2017-02-12 23:17:04',40,'AC_OTH_AUTO','Patient créé','2017-02-12 23:17:04','2021-04-15 10:22:55',12,NULL,NULL,26,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Patient créé\nAuthor: admin',26,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(253,'253',NULL,1,'2017-02-12 23:18:33','2017-02-12 23:18:33',40,'AC_OTH_AUTO','Consultation 2 recorded (aaa)','2017-02-12 23:18:33','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Consultation 2 recorded (aaa)\nAuthor: admin',2,'cabinetmed_cons',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(254,'254',NULL,1,'2017-02-15 23:28:41','2017-02-15 23:28:41',40,'AC_OTH_AUTO','Order CO7001-0005 validated','2017-02-15 23:28:41','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0005 validated\nAuthor: admin',7,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(255,'255',NULL,1,'2017-02-15 23:28:56','2017-02-15 23:28:56',40,'AC_OTH_AUTO','Order CO7001-0006 validated','2017-02-15 23:28:56','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0006 validated\nAuthor: admin',8,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(256,'256',NULL,1,'2017-02-15 23:34:33','2017-02-15 23:34:33',40,'AC_OTH_AUTO','Order CO7001-0007 validated','2017-02-15 23:34:33','2021-04-15 10:22:55',12,NULL,NULL,3,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0007 validated\nAuthor: admin',9,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(257,'257',NULL,1,'2017-02-15 23:35:03','2017-02-15 23:35:03',40,'AC_OTH_AUTO','Order CO7001-0008 validated','2017-02-15 23:35:03','2021-04-15 10:22:55',12,NULL,NULL,3,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0008 validated\nAuthor: admin',10,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(263,'263',NULL,1,'2017-02-15 23:50:34','2017-02-15 23:50:34',40,'AC_OTH_AUTO','Order CO7001-0005 validated','2017-02-15 23:50:34','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0005 validated\nAuthor: admin',17,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(264,'264',NULL,1,'2017-02-15 23:51:23','2017-02-15 23:51:23',40,'AC_OTH_AUTO','Order CO7001-0006 validated','2017-02-15 23:51:23','2021-04-15 10:22:55',12,NULL,NULL,7,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0006 validated\nAuthor: admin',18,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(265,'265',NULL,1,'2017-02-15 23:54:51','2017-02-15 23:54:51',40,'AC_OTH_AUTO','Order CO7001-0007 validated','2017-02-15 23:54:51','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0007 validated\nAuthor: admin',19,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(266,'266',NULL,1,'2017-02-15 23:55:52','2017-02-15 23:55:52',40,'AC_OTH_AUTO','Order CO7001-0007 validated','2017-02-15 23:55:52','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0007 validated\nAuthor: admin',20,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(267,'267',NULL,1,'2017-02-16 00:03:44','2017-02-16 00:03:44',40,'AC_OTH_AUTO','Order CO7001-0008 validated','2017-02-16 00:03:44','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0008 validated\nAuthor: admin',29,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(268,'268',NULL,1,'2017-02-16 00:05:01','2017-02-16 00:05:01',40,'AC_OTH_AUTO','Order CO7001-0009 validated','2017-02-16 00:05:01','2021-04-15 10:22:55',12,NULL,NULL,11,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0009 validated\nAuthor: admin',34,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(269,'269',NULL,1,'2017-02-16 00:05:01','2017-02-16 00:05:01',40,'AC_OTH_AUTO','Order CO7001-0010 validated','2017-02-16 00:05:01','2021-04-15 10:22:55',12,NULL,NULL,3,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0010 validated\nAuthor: admin',38,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(270,'270',NULL,1,'2017-02-16 00:05:11','2017-02-16 00:05:11',40,'AC_OTH_AUTO','Order CO7001-0011 validated','2017-02-16 00:05:11','2021-04-15 10:22:55',12,NULL,NULL,11,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0011 validated\nAuthor: admin',40,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(271,'271',NULL,1,'2017-02-16 00:05:11','2017-02-16 00:05:11',40,'AC_OTH_AUTO','Order CO7001-0012 validated','2017-02-16 00:05:11','2021-04-15 10:22:55',12,NULL,NULL,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0012 validated\nAuthor: admin',43,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(272,'272',NULL,1,'2017-02-16 00:05:11','2017-02-16 00:05:11',40,'AC_OTH_AUTO','Order CO7001-0013 validated','2017-02-16 00:05:11','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0013 validated\nAuthor: admin',47,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(273,'273',NULL,1,'2017-02-16 00:05:11','2017-02-16 00:05:11',40,'AC_OTH_AUTO','Order CO7001-0014 validated','2017-02-16 00:05:11','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0014 validated\nAuthor: admin',48,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(274,'274',NULL,1,'2017-02-16 00:05:26','2017-02-16 00:05:26',40,'AC_OTH_AUTO','Order CO7001-0015 validated','2017-02-16 00:05:26','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0015 validated\nAuthor: admin',50,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(275,'275',NULL,1,'2017-02-16 00:05:26','2017-02-16 00:05:26',40,'AC_OTH_AUTO','Order CO7001-0016 validated','2017-02-16 00:05:26','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0016 validated\nAuthor: admin',54,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(277,'277',NULL,1,'2017-02-16 00:05:35','2017-02-16 00:05:35',40,'AC_OTH_AUTO','Order CO7001-0018 validated','2017-02-16 00:05:35','2021-04-15 10:22:55',12,NULL,NULL,19,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0018 validated\nAuthor: admin',62,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(278,'278',NULL,1,'2017-02-16 00:05:35','2017-02-16 00:05:35',40,'AC_OTH_AUTO','Order CO7001-0019 validated','2017-02-16 00:05:35','2021-04-15 10:22:55',12,NULL,NULL,3,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0019 validated\nAuthor: admin',68,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(279,'279',NULL,1,'2017-02-16 00:05:36','2017-02-16 00:05:36',40,'AC_OTH_AUTO','Order CO7001-0020 validated','2017-02-16 00:05:36','2021-04-15 10:22:55',12,NULL,NULL,6,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0020 validated\nAuthor: admin',72,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(281,'281',NULL,1,'2017-02-16 00:05:37','2017-02-16 00:05:37',40,'AC_OTH_AUTO','Order CO7001-0022 validated','2017-02-16 00:05:37','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0022 validated\nAuthor: admin',78,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(282,'282',NULL,1,'2017-02-16 00:05:38','2017-02-16 00:05:38',40,'AC_OTH_AUTO','Order CO7001-0023 validated','2017-02-16 00:05:38','2021-04-15 10:22:55',12,NULL,NULL,11,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0023 validated\nAuthor: admin',81,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(283,'283',NULL,1,'2017-02-16 00:05:38','2017-02-16 00:05:38',40,'AC_OTH_AUTO','Order CO7001-0024 validated','2017-02-16 00:05:38','2021-04-15 10:22:55',12,NULL,NULL,26,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0024 validated\nAuthor: admin',83,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(284,'284',NULL,1,'2017-02-16 00:05:38','2017-02-16 00:05:38',40,'AC_OTH_AUTO','Order CO7001-0025 validated','2017-02-16 00:05:38','2021-04-15 10:22:55',12,NULL,NULL,2,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0025 validated\nAuthor: admin',84,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(285,'285',NULL,1,'2017-02-16 00:05:38','2017-02-16 00:05:38',40,'AC_OTH_AUTO','Order CO7001-0026 validated','2017-02-16 00:05:38','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0026 validated\nAuthor: admin',85,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(286,'286',NULL,1,'2017-02-16 00:05:38','2017-02-16 00:05:38',40,'AC_OTH_AUTO','Order CO7001-0027 validated','2017-02-16 00:05:38','2021-04-15 10:22:55',12,NULL,NULL,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0027 validated\nAuthor: admin',88,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(287,'287',NULL,1,'2017-02-16 03:05:56','2017-02-16 03:05:56',40,'AC_OTH_AUTO','Commande CO7001-0016 classée Livrée','2017-02-16 03:05:56','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Commande CO7001-0016 classée Livrée\nAuteur: admin',54,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(288,'288',NULL,1,'2017-02-16 03:06:01','2017-02-16 03:06:01',40,'AC_OTH_AUTO','Commande CO7001-0016 classée Facturée','2017-02-16 03:06:01','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Commande CO7001-0016 classée Facturée\nAuteur: admin',54,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(294,'294',NULL,1,'2017-02-16 03:53:04','2017-02-16 03:53:04',40,'AC_OTH_AUTO','Commande CO7001-0021 validée','2017-02-16 03:53:04','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Commande CO7001-0021 validée\nAuteur: admin',75,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(295,'295',NULL,1,'2017-02-16 03:58:08','2017-02-16 03:58:08',40,'AC_OTH_AUTO','Expédition SH1702-0002 validée','2017-02-16 03:58:08','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Expédition SH1702-0002 validée\nAuteur: admin',3,'shipping',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(296,'296',NULL,1,'2017-02-16 04:12:29','2017-02-16 04:12:29',40,'AC_OTH_AUTO','Commande CO7001-0021 validée','2017-02-16 04:12:29','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Commande CO7001-0021 validée\nAuteur: admin',75,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(297,'297',NULL,1,'2017-02-16 04:14:20','2017-02-16 04:14:20',40,'AC_OTH_AUTO','Commande CO7001-0021 validée','2017-02-16 04:14:20','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Commande CO7001-0021 validée\nAuteur: admin',75,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(298,'298',NULL,1,'2017-02-16 01:44:58','2017-02-16 01:44:58',40,'AC_OTH_AUTO','Proposal PR1702-0009 validated','2017-02-16 01:44:58','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0009 validated\nAuthor: aeinstein',11,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(299,'299',NULL,1,'2017-02-16 01:45:44','2017-02-16 01:45:44',40,'AC_OTH_AUTO','Proposal PR1702-0010 validated','2017-02-16 01:45:44','2021-04-15 10:22:55',2,NULL,NULL,7,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0010 validated\nAuthor: demo',12,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(300,'300',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0011 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',1,NULL,NULL,26,NULL,0,1,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0011 validated\nAuthor: aeinstein',13,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(301,'301',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0012 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',2,NULL,NULL,3,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0012 validated\nAuthor: demo',14,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(302,'302',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0013 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',2,NULL,NULL,26,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0013 validated\nAuthor: demo',15,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(303,'303',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0014 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',2,NULL,NULL,1,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0014 validated\nAuthor: demo',16,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(304,'304',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0015 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0015 validated\nAuthor: aeinstein',17,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(305,'305',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0016 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',2,NULL,NULL,26,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0016 validated\nAuthor: demo',18,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(306,'306',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0017 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',2,NULL,NULL,12,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0017 validated\nAuthor: demo',19,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(307,'307',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0018 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',1,NULL,NULL,26,NULL,0,1,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0018 validated\nAuthor: aeinstein',20,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(308,'308',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0019 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0019 validated\nAuthor: aeinstein',21,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(309,'309',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0020 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',1,NULL,NULL,26,NULL,0,1,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0020 validated\nAuthor: aeinstein',22,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(310,'310',NULL,1,'2017-02-16 01:46:17','2017-02-16 01:46:17',40,'AC_OTH_AUTO','Proposal PR1702-0021 validated','2017-02-16 01:46:17','2021-04-15 10:22:55',2,NULL,NULL,12,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0021 validated\nAuthor: demo',23,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(311,'311',NULL,1,'2017-02-16 01:46:17','2017-02-16 01:46:17',40,'AC_OTH_AUTO','Proposal PR1702-0022 validated','2017-02-16 01:46:17','2021-04-15 10:22:55',2,NULL,NULL,7,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0022 validated\nAuthor: demo',24,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(312,'312',NULL,1,'2017-02-16 01:46:17','2017-02-16 01:46:17',40,'AC_OTH_AUTO','Proposal PR1702-0023 validated','2017-02-16 01:46:17','2021-04-15 10:22:55',1,NULL,NULL,3,NULL,0,1,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0023 validated\nAuthor: aeinstein',25,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(313,'313',NULL,1,'2017-02-16 01:46:18','2017-02-16 01:46:18',40,'AC_OTH_AUTO','Proposal PR1702-0024 validated','2017-02-16 01:46:18','2021-04-15 10:22:55',2,NULL,NULL,1,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0024 validated\nAuthor: demo',26,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(314,'314',NULL,1,'2017-02-16 01:46:18','2017-02-16 01:46:18',40,'AC_OTH_AUTO','Proposal PR1702-0025 validated','2017-02-16 01:46:18','2021-04-15 10:22:55',1,NULL,NULL,6,NULL,0,1,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0025 validated\nAuthor: aeinstein',27,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(315,'315',NULL,1,'2017-02-16 01:46:18','2017-02-16 01:46:18',40,'AC_OTH_AUTO','Proposal PR1702-0026 validated','2017-02-16 01:46:18','2021-04-15 10:22:55',2,NULL,NULL,19,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0026 validated\nAuthor: demo',28,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(316,'316',NULL,1,'2017-02-16 01:46:18','2017-02-16 01:46:18',40,'AC_OTH_AUTO','Proposal PR1702-0027 validated','2017-02-16 01:46:18','2021-04-15 10:22:55',2,NULL,NULL,1,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0027 validated\nAuthor: demo',29,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(317,'317',NULL,1,'2017-02-16 01:46:18','2017-02-16 01:46:18',40,'AC_OTH_AUTO','Proposal PR1702-0028 validated','2017-02-16 01:46:18','2021-04-15 10:22:55',2,NULL,NULL,1,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0028 validated\nAuthor: demo',30,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(318,'318',NULL,1,'2017-02-16 01:46:18','2017-02-16 01:46:18',40,'AC_OTH_AUTO','Proposal PR1702-0029 validated','2017-02-16 01:46:18','2021-04-15 10:22:55',1,NULL,NULL,11,NULL,0,1,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0029 validated\nAuthor: aeinstein',31,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(319,'319',NULL,1,'2017-02-16 01:46:18','2017-02-16 01:46:18',40,'AC_OTH_AUTO','Proposal PR1702-0030 validated','2017-02-16 01:46:18','2021-04-15 10:22:55',2,NULL,NULL,19,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0030 validated\nAuthor: demo',32,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(320,'320',NULL,1,'2017-02-16 04:46:31','2017-02-16 04:46:31',40,'AC_OTH_AUTO','Proposition PR1702-0026 signée','2017-02-16 04:46:31','2021-04-15 10:22:55',12,NULL,NULL,19,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Proposition PR1702-0026 signée\nAuteur: admin',28,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(321,'321',NULL,1,'2017-02-16 04:46:37','2017-02-16 04:46:37',40,'AC_OTH_AUTO','Proposition PR1702-0027 signée','2017-02-16 04:46:37','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Proposition PR1702-0027 signée\nAuteur: admin',29,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(322,'322',NULL,1,'2017-02-16 04:46:42','2017-02-16 04:46:42',40,'AC_OTH_AUTO','Proposition PR1702-0028 refusée','2017-02-16 04:46:42','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Proposition PR1702-0028 refusée\nAuteur: admin',30,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(323,'323',NULL,1,'2017-02-16 04:47:09','2017-02-16 04:47:09',40,'AC_OTH_AUTO','Proposition PR1702-0019 validée','2017-02-16 04:47:09','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Proposition PR1702-0019 validée\nAuteur: admin',21,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(324,'324',NULL,1,'2017-02-16 04:47:25','2017-02-16 04:47:25',40,'AC_OTH_AUTO','Proposition PR1702-0023 signée','2017-02-16 04:47:25','2021-04-15 10:22:55',12,NULL,NULL,3,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Proposition PR1702-0023 signée\nAuteur: admin',25,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(325,'325',NULL,1,'2017-02-16 04:47:29','2017-02-16 04:47:29',40,'AC_OTH_AUTO','Proposition PR1702-0023 classée payée','2017-02-16 04:47:29','2021-04-15 10:22:55',12,NULL,NULL,3,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Proposition PR1702-0023 classée payée\nAuteur: admin',25,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(326,'326',NULL,1,'2017-02-17 16:07:18','2017-02-17 16:07:18',40,'AC_OTH_AUTO','Proposition PR1702-0021 validée','2017-02-17 16:07:18','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Proposition PR1702-0021 validée\nAuteur: admin',23,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(327,'327',NULL,1,'2017-05-12 13:53:44','2017-05-12 13:53:44',40,'AC_OTH_AUTO','Email sent by MyBigCompany To Einstein','2017-05-12 13:53:44','2021-04-15 10:22:55',12,NULL,NULL,11,12,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Sender: MyBigCompany <myemail@mybigcompany.com>
\nReceiver(s): Einstein <genius@example.com>
\nBcc: Einstein <genius@example.com>
\nEMail topic: Test
\nEmail body:
\nTest\nAuthor: admin',11,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(328,'328',NULL,1,'2017-08-29 22:39:09','2017-08-29 22:39:09',40,'AC_OTH_AUTO','Invoice FA1601-0024 validated','2017-08-29 22:39:09','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Invoice FA1601-0024 validated\nAuthor: admin',149,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(329,'329',NULL,1,'2019-09-26 13:38:11','2019-09-26 13:38:11',40,'AC_MEMBER_MODIFY','Member Pierre Curie modified','2019-09-26 13:38:11','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember Pierre Curie modified\nMember: Pierre Curie\nType: Standard members',2,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(330,'330',NULL,1,'2019-09-26 13:49:21','2019-09-26 13:49:21',40,'AC_MEMBER_MODIFY','Member Pierre Curie modified','2019-09-26 13:49:21','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember Pierre Curie modified\nMember: Pierre Curie\nType: Standard members',2,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(331,'331',NULL,1,'2019-09-26 17:33:37','2019-09-26 17:33:37',40,'AC_BILL_VALIDATE','Invoice FA1909-0025 validated','2019-09-26 17:33:37','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1909-0025 validated',218,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(333,'333',NULL,1,'2019-09-27 16:54:30','2019-09-27 16:54:30',40,'AC_PROPAL_VALIDATE','Proposal PR1909-0031 validated','2019-09-27 16:54:30','2021-04-15 10:22:55',12,NULL,4,7,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR1909-0031 validated',10,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(335,'335',NULL,1,'2019-09-27 17:08:59','2019-09-27 17:08:59',40,'AC_PROPAL_VALIDATE','Proposal PR1909-0032 validated','2019-09-27 17:08:59','2021-04-15 10:22:55',12,NULL,6,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR1909-0032 validated',33,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(337,'337',NULL,1,'2019-09-27 17:13:13','2019-09-27 17:13:13',40,'AC_PROPAL_VALIDATE','Proposal PR1909-0033 validated','2019-09-27 17:13:13','2021-04-15 10:22:55',12,NULL,6,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR1909-0033 validated',34,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(338,'338',NULL,1,'2019-09-27 17:53:31','2019-09-27 17:53:31',40,'AC_PRODUCT_MODIFY','Product ROLLUPABC modified','2019-09-27 17:53:31','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ROLLUPABC modified',11,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(339,'339',NULL,1,'2019-09-27 18:15:00','2019-09-27 18:15:00',40,'AC_PRODUCT_MODIFY','Product ROLLUPABC modified','2019-09-27 18:15:00','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ROLLUPABC modified',11,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(340,'340',NULL,1,'2019-09-27 18:40:32','2019-09-27 18:40:32',40,'AC_PRODUCT_MODIFY','Product ROLLUPABC modified','2019-09-27 18:40:32','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ROLLUPABC modified',11,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(341,'341',NULL,1,'2019-09-27 19:16:07','2019-09-27 19:16:07',40,'AC_PRODUCT_CREATE','Product ppp created','2019-09-27 19:16:07','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ppp created',14,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(342,'342',NULL,1,'2019-09-27 19:18:01','2019-09-27 19:18:01',40,'AC_PRODUCT_MODIFY','Product ppp modified','2019-09-27 19:18:01','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ppp modified',14,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(343,'343',NULL,1,'2019-09-27 19:31:45','2019-09-27 19:31:45',40,'AC_PRODUCT_MODIFY','Product ROLLUPABC modified','2019-09-27 19:31:45','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ROLLUPABC modified',11,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(344,'344',NULL,1,'2019-09-27 19:32:12','2019-09-27 19:32:12',40,'AC_PRODUCT_MODIFY','Product ROLLUPABC modified','2019-09-27 19:32:12','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ROLLUPABC modified',11,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(345,'345',NULL,1,'2019-09-27 19:38:30','2019-09-27 19:38:30',40,'AC_PRODUCT_MODIFY','Product ROLLUPABC modified','2019-09-27 19:38:30','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ROLLUPABC modified',11,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(346,'346',NULL,1,'2019-09-27 19:38:37','2019-09-27 19:38:37',40,'AC_PRODUCT_MODIFY','Product ROLLUPABC modified','2019-09-27 19:38:37','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ROLLUPABC modified',11,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(347,'347',NULL,1,'2019-09-30 15:49:52',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #15ff11cay39skiaa] New message','2019-09-30 15:49:52','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'dfsdfds',2,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(348,'348',NULL,1,'2019-10-01 13:48:36','2019-10-01 13:48:36',40,'AC_PROJECT_MODIFY','Project PJ1607-0001 modified','2019-10-01 13:48:36','2021-04-15 10:22:55',12,NULL,6,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1607-0001 modified\nTask: PJ1607-0001',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(349,'349',NULL,1,'2019-10-04 10:10:25','2019-10-04 10:10:25',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SI1601-0002 validated','2019-10-04 10:10:25','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI1601-0002 validated',17,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(350,'350',NULL,1,'2019-10-04 10:10:47','2019-10-04 10:10:47',40,'AC_BILL_SUPPLIER_PAYED','Invoice SI1601-0002 changed to paid','2019-10-04 10:10:47','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI1601-0002 changed to paid',17,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(351,'351',NULL,1,'2019-10-04 10:26:49','2019-10-04 10:26:49',40,'AC_BILL_UNVALIDATE','Invoice FA6801-0010 go back to draft status','2019-10-04 10:26:49','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA6801-0010 go back to draft status',150,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(352,'352',NULL,1,'2019-10-04 10:27:00','2019-10-04 10:27:00',40,'AC_BILL_VALIDATE','Invoice FA6801-0010 validated','2019-10-04 10:27:00','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA6801-0010 validated',150,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(353,'353',NULL,1,'2019-10-04 10:28:14','2019-10-04 10:28:14',40,'AC_BILL_PAYED','Invoice FA6801-0010 changed to paid','2019-10-04 10:28:14','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA6801-0010 changed to paid',150,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(354,'354',NULL,1,'2019-10-04 10:29:22','2019-10-04 10:29:22',40,'AC_BILL_SUPPLIER_PAYED','Invoice SI1601-0002 changed to paid','2019-10-04 10:29:22','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI1601-0002 changed to paid',17,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(355,'355',NULL,1,'2019-10-04 10:29:41','2019-10-04 10:29:41',40,'AC_BILL_SUPPLIER_UNVALIDATE','Invoice SI1601-0002 go back to draft status','2019-10-04 10:29:41','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI1601-0002 go back to draft status',17,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(356,'356',NULL,1,'2019-10-04 10:31:30','2019-10-04 10:31:30',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SI1601-0002 validated','2019-10-04 10:31:30','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI1601-0002 validated',17,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(357,'357',NULL,1,'2019-10-04 16:56:21',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 16:56:21','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'aaaa',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(358,'358',NULL,1,'2019-10-04 17:08:04',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:08:04','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'ddddd',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(359,'359',NULL,1,'2019-10-04 17:25:05',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:25:05','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'aaa',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(360,'360',NULL,1,'2019-10-04 17:26:14',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:26:14','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'aaa',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(361,'361',NULL,1,'2019-10-04 17:30:10',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:30:10','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(362,'362',NULL,1,'2019-10-04 17:51:43',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:51:43','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(363,'363',NULL,1,'2019-10-04 17:52:02',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:52:02','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(364,'364',NULL,1,'2019-10-04 17:52:17',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:52:17','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(365,'365',NULL,1,'2019-10-04 17:52:39',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:52:39','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(366,'366',NULL,1,'2019-10-04 17:52:53',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:52:53','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(367,'367',NULL,1,'2019-10-04 17:53:13',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:53:13','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(368,'368',NULL,1,'2019-10-04 17:53:26',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:53:26','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(369,'369',NULL,1,'2019-10-04 17:53:48',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:53:48','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(370,'370',NULL,1,'2019-10-04 17:54:09',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:54:09','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(371,'371',NULL,1,'2019-10-04 17:54:28',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:54:28','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(372,'372',NULL,1,'2019-10-04 17:55:43',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:55:43','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(373,'373',NULL,1,'2019-10-04 17:56:01',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:56:01','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(374,'374',NULL,1,'2019-10-04 18:00:32',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 18:00:32','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(375,'375',NULL,1,'2019-10-04 18:00:58',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 18:00:58','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(376,'376',NULL,1,'2019-10-04 18:11:30',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 18:11:30','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(377,'377',NULL,1,'2019-10-04 18:12:02',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 18:12:02','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fffffff',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(378,'378',NULL,1,'2019-10-04 18:49:30',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 18:49:30','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'aaa',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(379,'379',NULL,1,'2019-10-04 19:00:22',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 19:00:22','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fff',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(380,'380',NULL,1,'2019-10-04 19:24:20','2019-10-04 19:24:20',40,'AC_PROPAL_SENTBYMAIL','Email sent by Alice Adminson To NLTechno','2019-10-04 19:24:20','2021-04-15 10:22:55',12,NULL,6,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nSender: Alice Adminson <aadminson@example.com>
\nReceiver(s): NLTechno <notanemail@nltechno.com>
\nEmail topic: Envoi de la proposition commerciale PR1909-0032
\nEmail body:
\nHello
\r\n
\r\nVeuillez trouver, ci-joint, la proposition commerciale PR1909-0032
\r\n
\r\n
\r\nSincerely
\r\n
\r\nAlice - 123
\n
\nAttached files and documents: PR1909-0032.pdf',33,'propal',NULL,'Envoi de la proposition commerciale PR1909-0032','Alice Adminson ',NULL,'NLTechno ',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(381,'381',NULL,1,'2019-10-04 19:30:13',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 19:30:13','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(382,'382',NULL,1,'2019-10-04 19:32:55',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 19:32:55','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'uuuuuu\n\nAttached files and documents: Array',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(383,'383',NULL,1,'2019-10-04 19:37:16',NULL,50,'TICKET_MSG','','2019-10-04 19:37:16','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,100,'',NULL,NULL,'f\n\nFichiers et documents joints: dolihelp.ico',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(384,'384',NULL,1,'2019-10-04 19:39:07',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 19:39:07','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'aaafff\n\nAttached files and documents: dolibarr.gif;doliadmin.ico',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(385,'385',NULL,1,'2019-10-07 12:17:07','2019-10-07 12:17:07',40,'AC_PRODUCT_DELETE','Product PREF123456 deleted','2019-10-07 12:17:07','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PREF123456 deleted',17,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(386,'386',NULL,1,'2019-10-07 12:17:32','2019-10-07 12:17:32',40,'AC_PRODUCT_DELETE','Product PREF123456 deleted','2019-10-07 12:17:32','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PREF123456 deleted',18,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(387,'387',NULL,1,'2019-10-08 19:21:07','2019-10-08 19:21:07',40,'AC_PRODUCT_MODIFY','Product ROLLUPABC modified','2019-10-08 19:21:07','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ROLLUPABC modified',11,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(388,'388',NULL,1,'2019-10-08 21:01:07','2019-10-08 21:01:07',40,'AC_MEMBER_MODIFY','Member Pierre Curie modified','2019-10-08 21:01:07','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember Pierre Curie modified\nMember: Pierre Curie\nType: Standard members',2,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(389,'389',NULL,1,'2019-10-08 21:01:22','2019-10-08 21:01:22',40,'AC_MEMBER_MODIFY','Member doe john modified','2019-10-08 21:01:22','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember doe john modified\nMember: doe john\nType: Standard members',3,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(390,'390',NULL,1,'2019-10-08 21:01:45','2019-10-08 21:01:45',40,'AC_MEMBER_MODIFY','Member smith smith modified','2019-10-08 21:01:45','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember smith smith modified\nMember: smith smith\nType: Standard members',4,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(391,'391',NULL,1,'2019-10-08 21:02:18','2019-10-08 21:02:18',40,'AC_MEMBER_MODIFY','Member Vick Smith modified','2019-10-08 21:02:18','2021-04-15 10:22:55',12,NULL,NULL,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember Vick Smith modified\nMember: Vick Smith\nType: Standard members',1,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(392,'392',NULL,1,'2019-11-28 15:54:46','2019-11-28 15:54:46',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SI1911-0005 validated','2019-11-28 15:54:47','2021-04-15 10:22:55',12,NULL,NULL,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI1911-0005 validated',21,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(393,'393',NULL,1,'2019-11-28 16:33:35','2019-11-28 16:33:35',40,'AC_PRODUCT_CREATE','Product FR-CAR created','2019-11-28 16:33:35','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct FR-CAR created',24,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(394,'394',NULL,1,'2019-11-28 16:34:08','2019-11-28 16:34:08',40,'AC_PRODUCT_DELETE','Product ppp deleted','2019-11-28 16:34:08','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ppp deleted',14,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(395,'395',NULL,1,'2019-11-28 16:34:33','2019-11-28 16:34:33',40,'AC_PRODUCT_MODIFY','Product FR-CAR modified','2019-11-28 16:34:33','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct FR-CAR modified',24,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(396,'396',NULL,1,'2019-11-28 16:34:46','2019-11-28 16:34:46',40,'AC_PRODUCT_MODIFY','Product FR-CAR modified','2019-11-28 16:34:46','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct FR-CAR modified',24,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(397,'397',NULL,1,'2019-11-28 16:36:56','2019-11-28 16:36:56',40,'AC_PRODUCT_MODIFY','Product POS-CAR modified','2019-11-28 16:36:56','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-CAR modified',24,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(398,'398',NULL,1,'2019-11-28 16:37:36','2019-11-28 16:37:36',40,'AC_PRODUCT_CREATE','Product POS-APPLE created','2019-11-28 16:37:36','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-APPLE created',25,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(399,'399',NULL,1,'2019-11-28 16:37:58','2019-11-28 16:37:58',40,'AC_PRODUCT_MODIFY','Product POS-APPLE modified','2019-11-28 16:37:58','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-APPLE modified',25,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(400,'400',NULL,1,'2019-11-28 16:38:44','2019-11-28 16:38:44',40,'AC_PRODUCT_CREATE','Product POS-KIWI created','2019-11-28 16:38:44','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-KIWI created',26,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(401,'401',NULL,1,'2019-11-28 16:39:21','2019-11-28 16:39:21',40,'AC_PRODUCT_CREATE','Product POS-PEACH created','2019-11-28 16:39:21','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-PEACH created',27,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(402,'402',NULL,1,'2019-11-28 16:39:58','2019-11-28 16:39:58',40,'AC_PRODUCT_CREATE','Product POS-ORANGE created','2019-11-28 16:39:58','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-ORANGE created',28,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(403,'403',NULL,1,'2019-11-28 17:00:28','2019-11-28 17:00:28',40,'AC_PRODUCT_MODIFY','Product APPLEPIE modified','2019-11-28 17:00:28','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct APPLEPIE modified',4,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(404,'404',NULL,1,'2019-11-28 17:00:46','2019-11-28 17:00:46',40,'AC_PRODUCT_MODIFY','Product PEARPIE modified','2019-11-28 17:00:46','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PEARPIE modified',2,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(405,'405',NULL,1,'2019-11-28 17:01:57','2019-11-28 17:01:57',40,'AC_PRODUCT_MODIFY','Product POS-APPLE modified','2019-11-28 17:01:57','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-APPLE modified',25,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(406,'406',NULL,1,'2019-11-28 17:03:14','2019-11-28 17:03:14',40,'AC_PRODUCT_CREATE','Product POS-Eggs created','2019-11-28 17:03:14','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-Eggs created',29,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(407,'407',NULL,1,'2019-11-28 17:04:17','2019-11-28 17:04:17',40,'AC_PRODUCT_MODIFY','Product POS-Eggs modified','2019-11-28 17:04:17','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-Eggs modified',29,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(408,'408',NULL,1,'2019-11-28 17:09:14','2019-11-28 17:09:14',40,'AC_PRODUCT_CREATE','Product POS-Chips created','2019-11-28 17:09:14','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-Chips created',30,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(409,'409',NULL,1,'2019-11-28 17:09:54','2019-11-28 17:09:54',40,'AC_PRODUCT_MODIFY','Product POS-Chips modified','2019-11-28 17:09:54','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-Chips modified',30,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(410,'410',NULL,1,'2019-11-28 18:46:20','2019-11-28 18:46:20',40,'AC_PRODUCT_MODIFY','Product POS-APPLE modified','2019-11-28 18:46:20','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-APPLE modified',25,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(411,'411',NULL,1,'2019-11-28 18:59:29','2019-11-28 18:59:29',40,'AC_PRODUCT_MODIFY','Product PEARPIE modified','2019-11-28 18:59:29','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PEARPIE modified',2,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(412,'412',NULL,1,'2019-11-28 19:02:01','2019-11-28 19:02:01',40,'AC_PRODUCT_MODIFY','Product POS-CARROT modified','2019-11-28 19:02:01','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-CARROT modified',24,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(413,'413',NULL,1,'2019-11-28 19:09:50','2019-11-28 19:09:50',40,'AC_PRODUCT_MODIFY','Product PEARPIE modified','2019-11-28 19:09:50','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PEARPIE modified',2,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(414,'414',NULL,1,'2019-11-28 19:12:50','2019-11-28 19:12:50',40,'AC_PRODUCT_MODIFY','Product PEARPIE modified','2019-11-28 19:12:50','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PEARPIE modified',2,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(415,'415',NULL,1,'2019-11-29 12:46:29','2019-11-29 12:46:29',40,'AC_TICKET_CREATE','Ticket TS1911-0004 created','2019-11-29 12:46:29','2021-04-15 10:22:55',12,NULL,4,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nTicket TS1911-0004 created',6,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(416,'416',NULL,1,'2019-11-29 12:46:34','2019-11-29 12:46:34',40,'AC_TICKET_MODIFY','Ticket TS1911-0004 read by Alice Adminson','2019-11-29 12:46:34','2021-04-15 10:22:55',12,NULL,4,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nTicket TS1911-0004 read by Alice Adminson',6,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(417,'417',NULL,1,'2019-11-29 12:46:47','2019-11-29 12:46:47',40,'AC_TICKET_ASSIGNED','Ticket TS1911-0004 assigned','2019-11-29 12:46:47','2021-04-15 10:22:55',12,NULL,4,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nTicket TS1911-0004 assigned\nOld user: None\nNew user: Commerson Charle1',6,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(418,'418',NULL,1,'2019-11-29 12:47:13',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #5gvo9bsjri55zef9] New message','2019-11-29 12:47:13','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'Where do you want to install Dolibarr ?
\r\nOn-Premise or on the Cloud ?',6,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(419,'419',NULL,1,'2019-11-29 12:50:45','2019-11-29 12:50:45',40,'AC_TICKET_CREATE','Ticket TS1911-0005 créé','2019-11-29 12:50:45','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,-1,'',NULL,NULL,'Auteur: \nTicket TS1911-0005 créé',7,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(420,'420',NULL,1,'2019-11-29 12:52:32','2019-11-29 12:52:32',40,'AC_TICKET_MODIFY','Ticket TS1911-0005 read by Alice Adminson','2019-11-29 12:52:32','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nTicket TS1911-0005 read by Alice Adminson',7,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(421,'421',NULL,1,'2019-11-29 12:52:53','2019-11-29 12:52:53',40,'AC_TICKET_ASSIGNED','Ticket TS1911-0005 assigned','2019-11-29 12:52:53','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nTicket TS1911-0005 assigned\nOld user: None\nNew user: Commerson Charle1',7,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(422,'422',NULL,1,'2019-11-29 12:54:04',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #d51wjy4nym7wltg7] New message','2019-11-29 12:54:04','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'Hi.
\r\nThanks for your interest in using Dolibarr ERP CRM.
\r\nI need more information to give you the correct answer : Where do you want to install Dolibarr. On premise or on Cloud',7,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(423,'423',NULL,1,'2019-11-29 12:54:46',NULL,50,'TICKET_MSG','','2019-11-29 12:54:46','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,100,'',NULL,NULL,'I need it On-Premise.',7,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(424,'424',NULL,1,'2019-11-29 12:55:42',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #d51wjy4nym7wltg7] New message','2019-11-29 12:55:42','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'When used on-premise, you can download and install Dolibarr yourself from ou web portal: https://www.dolibarr.org
\r\nIt is completely free.',7,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(425,'425',NULL,1,'2019-11-29 12:55:48','2019-11-29 12:55:48',40,'AC_TICKET_CLOSE','Ticket TS1911-0005 closed','2019-11-29 12:55:48','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nTicket TS1911-0005 closed',7,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(426,'426',NULL,1,'2019-11-29 12:56:47','2019-11-29 12:56:47',40,'AC_BOM_UNVALIDATE','BOM unvalidated','2019-11-29 12:56:47','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM unvalidated',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(427,'427',NULL,1,'2019-11-29 12:57:14','2019-11-29 12:57:14',40,'AC_BOM_VALIDATE','BOM validated','2019-11-29 12:57:14','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM validated',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(428,'428',NULL,1,'2019-12-20 16:40:14','2019-12-20 16:40:14',40,'AC_MO_DELETE','MO deleted','2019-12-20 16:40:14','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO deleted',3,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(429,'429',NULL,1,'2019-12-20 17:00:43','2019-12-20 17:00:43',40,'AC_MO_DELETE','MO deleted','2019-12-20 17:00:43','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO deleted',7,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(430,'430',NULL,1,'2019-12-20 17:00:56','2019-12-20 17:00:56',40,'AC_MO_DELETE','MO deleted','2019-12-20 17:00:56','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO deleted',6,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(431,'431',NULL,1,'2019-12-20 20:00:03','2019-12-20 20:00:03',40,'AC_MO_DELETE','MO deleted','2019-12-20 20:00:03','2021-04-15 10:22:55',12,NULL,6,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO deleted',1,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(432,'432',NULL,1,'2019-12-20 20:22:11','2019-12-20 20:22:11',40,'AC_MO_DELETE','MO deleted','2019-12-20 20:22:11','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO deleted',10,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(433,'433',NULL,1,'2019-12-20 20:22:11','2019-12-20 20:22:11',40,'AC_MO_DELETE','MO deleted','2019-12-20 20:22:11','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO deleted',12,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(434,'434',NULL,1,'2019-12-20 20:22:20','2019-12-20 20:22:20',40,'AC_MO_DELETE','MO deleted','2019-12-20 20:22:20','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO deleted',9,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(435,'435',NULL,1,'2019-12-20 20:27:07','2019-12-20 20:27:07',40,'AC_MO_DELETE','MO deleted','2019-12-20 20:27:07','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO deleted',13,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(436,'436',NULL,1,'2019-12-20 20:42:42','2019-12-20 20:42:42',40,'AC_ORDER_VALIDATE','Order CO7001-0027 validated','2019-12-20 20:42:42','2021-04-15 10:22:55',12,NULL,NULL,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nOrder CO7001-0027 validated',88,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(437,'437',NULL,1,'2019-12-20 20:46:25','2019-12-20 20:46:25',40,'AC_ORDER_SUPPLIER_RECEIVE','Purchase Order CF1007-0001 received','2019-12-20 20:46:25','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nPurchase Order CF1007-0001 received ',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(438,'438',NULL,1,'2019-12-20 20:46:45','2019-12-20 20:46:45',40,'AC_ORDER_SUPPLIER_CLASSIFY_BILLED','Purchase Order CF1007-0001 set billed','2019-12-20 20:46:45','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nPurchase Order CF1007-0001 set billed',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(439,'439',NULL,1,'2019-12-20 20:47:02','2019-12-20 20:47:02',40,'AC_ORDER_SUPPLIER_RECEIVE','Purchase Order CF1007-0001 received','2019-12-20 20:47:02','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nPurchase Order CF1007-0001 received ',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(440,'440',NULL,1,'2019-12-20 20:47:44','2019-12-20 20:47:44',40,'AC_ORDER_SUPPLIER_RECEIVE','Purchase Order CF1007-0001 received','2019-12-20 20:47:44','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nPurchase Order CF1007-0001 received ',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(441,'441',NULL,1,'2019-12-20 20:47:53','2019-12-20 20:47:53',40,'AC_ORDER_SUPPLIER_RECEIVE','Purchase Order CF1007-0001 received','2019-12-20 20:47:53','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nPurchase Order CF1007-0001 received ',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(442,'442',NULL,1,'2019-12-20 20:48:05','2019-12-20 20:48:05',40,'AC_ORDER_SUPPLIER_RECEIVE','Purchase Order CF1007-0001 received','2019-12-20 20:48:05','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nPurchase Order CF1007-0001 received ',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(443,'443',NULL,1,'2019-12-20 20:48:45','2019-12-20 20:48:45',40,'AC_ORDER_CLASSIFY_BILLED','Order CO7001-0016 classified billed','2019-12-20 20:48:45','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nOrder CO7001-0016 classified billed',54,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(444,'444',NULL,1,'2019-12-20 20:48:55','2019-12-20 20:48:55',40,'AC_ORDER_CLOSE','Order CO7001-0018 classified delivered','2019-12-20 20:48:55','2021-04-15 10:22:55',12,NULL,NULL,19,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nOrder CO7001-0018 classified delivered',62,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(445,'445',NULL,1,'2019-12-20 20:49:43','2019-12-20 20:49:43',40,'AC_PROPAL_CLASSIFY_BILLED','Proposal PR1702-0027 classified billed','2019-12-20 20:49:43','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR1702-0027 classified billed',29,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(446,'446',NULL,1,'2019-12-20 20:49:54','2019-12-20 20:49:54',40,'AC_PROPAL_CLOSE_SIGNED','Proposal PR1702-0027 signed','2019-12-20 20:49:54','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR1702-0027 signed',29,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(447,'447',NULL,1,'2019-12-20 20:50:14','2019-12-20 20:50:14',40,'AC_PROPAL_CLOSE_REFUSED','Proposal PR1702-0027 refused','2019-12-20 20:50:14','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR1702-0027 refused',29,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(448,'448',NULL,1,'2019-12-20 20:50:23','2019-12-20 20:50:23',40,'AC_PROPAL_CLOSE_SIGNED','Proposal PR1702-0027 signed','2019-12-20 20:50:23','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR1702-0027 signed',29,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(449,'449',NULL,1,'2019-12-21 17:18:22','2019-12-21 17:18:22',40,'AC_BOM_CLOSE','BOM disabled','2019-12-21 17:18:22','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM disabled',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(450,'450',NULL,1,'2019-12-21 17:18:38','2019-12-21 17:18:38',40,'AC_MEMBER_RESILIATE','Member Vick Smith terminated','2019-12-21 17:18:38','2021-04-15 10:22:55',12,NULL,NULL,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember Vick Smith terminated\nMember: Vick Smith\nType: Standard members',1,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(451,'451',NULL,1,'2019-12-21 19:46:33','2019-12-21 19:46:33',40,'AC_PROJECT_CREATE','Project PJ1912-0005 created','2019-12-21 19:46:33','2021-04-15 10:22:55',12,NULL,10,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0005 created\nProject: PJ1912-0005',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(452,'452',NULL,1,'2019-12-21 19:47:03','2019-12-21 19:47:03',40,'AC_PROJECT_MODIFY','Project PJ1912-0005 modified','2019-12-21 19:47:03','2021-04-15 10:22:55',12,NULL,10,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0005 modified\nTask: PJ1912-0005',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(453,'453',NULL,1,'2019-12-21 19:47:24','2019-12-21 19:47:24',40,'AC_PROJECT_MODIFY','Project PJ1912-0005 modified','2019-12-21 19:47:24','2021-04-15 10:22:55',12,NULL,10,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0005 modified\nTask: PJ1912-0005',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(454,'454',NULL,1,'2019-12-21 19:47:52','2019-12-21 19:47:52',40,'AC_PROJECT_MODIFY','Project PJ1912-0005 modified','2019-12-21 19:47:52','2021-04-15 10:22:55',12,NULL,10,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0005 modified\nTask: PJ1912-0005',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(455,'455',NULL,1,'2019-12-21 19:48:06','2019-12-21 19:48:06',40,'AC_PROJECT_MODIFY','Project PJ1912-0005 modified','2019-12-21 19:48:06','2021-04-15 10:22:55',12,NULL,10,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0005 modified\nTask: PJ1912-0005',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(456,'456',NULL,1,'2019-12-21 19:49:28','2019-12-21 19:49:28',40,'AC_PROJECT_CREATE','Project PJ1912-0006 created','2019-12-21 19:49:28','2021-04-15 10:22:55',12,NULL,11,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0006 created\nProject: PJ1912-0006',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(457,'457',NULL,1,'2019-12-21 19:52:12','2019-12-21 19:52:12',40,'AC_PROJECT_CREATE','Project PJ1912-0007 created','2019-12-21 19:52:12','2021-04-15 10:22:55',12,NULL,12,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0007 created\nProject: PJ1912-0007',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(458,'458',NULL,1,'2019-12-21 19:53:21','2019-12-21 19:53:21',40,'AC_PROJECT_CREATE','Project PJ1912-0008 created','2019-12-21 19:53:21','2021-04-15 10:22:55',12,NULL,13,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0008 created\nProject: PJ1912-0008',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(459,'459',NULL,1,'2019-12-21 19:53:42','2019-12-21 19:53:42',40,'AC_PROJECT_MODIFY','Project PJ1912-0008 modified','2019-12-21 19:53:42','2021-04-15 10:22:55',12,NULL,13,26,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0008 modified\nTask: PJ1912-0008',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(460,'460',NULL,1,'2019-12-21 19:55:23','2019-12-21 19:55:23',40,'AC_PROJECT_MODIFY','Project PJ1912-0006 modified','2019-12-21 19:55:23','2021-04-15 10:22:55',12,NULL,11,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0006 modified\nTask: PJ1912-0006',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(461,'461',NULL,1,'2019-12-21 20:10:21','2019-12-21 20:10:21',40,'AC_PROJECT_MODIFY','Project PJ1912-0006 modified','2019-12-21 20:10:21','2021-04-15 10:22:55',12,NULL,11,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0006 modified\nTask: PJ1912-0006',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(462,'462',NULL,1,'2019-12-11 10:00:00','2019-12-11 10:00:00',5,'AC_RDV','Meeting with all employees','2019-12-21 20:29:32','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,1,NULL,0,0,-1,'',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(463,'463',NULL,1,'2019-12-06 00:00:00',NULL,11,'AC_INT','Intervention on customer site','2019-12-21 20:30:11','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,1,NULL,0,1,-1,'',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(464,'464',NULL,1,'2019-12-23 14:16:59','2019-12-23 14:16:59',40,'AC_BILL_PAYED','Invoice FA1601-0024 changed to paid','2019-12-23 14:16:59','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1601-0024 changed to paid',149,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(465,'465',NULL,1,'2019-12-23 14:17:18','2019-12-23 14:17:18',40,'AC_BILL_PAYED','Invoice FA1601-0024 changed to paid','2019-12-23 14:17:18','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1601-0024 changed to paid',149,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(466,'466',NULL,1,'2019-11-23 14:25:00',NULL,50,'AC_OTH','Test','2019-12-23 17:25:14','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,1,NULL,0,0,-1,'',NULL,NULL,'18/11 17h06 : Message laissé. Me rappeler pour m'en dire plus. 
\r\n
\r\n20/11 10h17 "A rappeler suite au msg laissé le 14/11, dit que c'est urgent"
\r\n12h22 : message laissé. Je lui envoie un sms
\r\n
\r\n"Déclaration de sinistre originale" : constat de ce qui s'est passé.
\r\nElle envoie le chèque de solde dès demain.
\r\n
\r\n3/12 : Elle préfère avoir plus d'infos sur le sinistre pour l'assurance.
\r\nCourrier envoyé le 4/12/19 par mail et par courrier postal
\r\n
\r\n6/12 15h02 : ont obtenu le feu vert de l'assurance.
\r\nOn bloque 16/12 PM à partir de 14h30. ',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(467,'467',NULL,1,'2020-01-01 14:35:47','2020-01-01 14:35:47',40,'AC_MEMBER_VALIDATE','Adhérent aze aze validé','2020-01-01 14:35:47','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,-1,'',NULL,NULL,'Auteur: \nAdhérent aze aze validé\nAdhérent: aze aze\nType: Board members',5,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(468,'468',NULL,1,'2020-01-01 14:50:59','2020-01-01 14:50:59',40,'AC_MEMBER_VALIDATE','Adhérent azr azr validé','2020-01-01 14:50:59','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,-1,'',NULL,NULL,'Auteur: \nAdhérent azr azr validé\nAdhérent: azr azr\nType: Board members',6,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(469,'469',NULL,1,'2020-01-01 15:00:16','2020-01-01 15:00:16',40,'AC_MEMBER_VALIDATE','Adhérent azt azt validé','2020-01-01 15:00:16','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,-1,'',NULL,NULL,'Auteur: \nAdhérent azt azt validé\nAdhérent: azt azt\nType: Board members',7,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(470,'470',NULL,1,'2020-01-01 15:08:20','2020-01-01 15:08:20',40,'AC_MEMBER_VALIDATE','Adhérent azu azu validé','2020-01-01 15:08:20','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,-1,'',NULL,NULL,'Auteur: \nAdhérent azu azu validé\nAdhérent: azu azu\nType: Board members',8,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(471,'471',NULL,1,'2020-01-01 15:27:24','2020-01-01 15:27:24',40,'AC_MEMBER_VALIDATE','Adhérent azi azi validé','2020-01-01 15:27:24','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,-1,'',NULL,NULL,'Auteur: \nAdhérent azi azi validé\nAdhérent: azi azi\nType: Board members',9,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(472,'472',NULL,1,'2020-01-01 15:36:29','2020-01-01 15:36:29',40,'AC_MEMBER_VALIDATE','Adhérent azo azo validé','2020-01-01 15:36:29','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,-1,'',NULL,NULL,'Auteur: \nAdhérent azo azo validé\nAdhérent: azo azo\nType: Board members',10,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(473,'473',NULL,1,'2020-01-01 15:44:25','2020-01-01 15:44:25',40,'AC_MEMBER_VALIDATE','Adhérent azp azp validé','2020-01-01 15:44:25','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,-1,'',NULL,NULL,'Auteur: \nAdhérent azp azp validé\nAdhérent: azp azp\nType: Board members',11,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(478,'478',NULL,1,'2020-01-01 16:52:32','2020-01-01 16:52:32',40,'AC_MEMBER_VALIDATE','Adhérent azq azq validé','2020-01-01 16:52:32','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,-1,'',NULL,NULL,'Auteur: \nAdhérent azq azq validé\nAdhérent: azq azq\nType: Board members',12,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(483,'483',NULL,1,'2020-01-01 17:49:05','2020-01-01 17:49:05',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SI2001-0006 validated','2020-01-01 17:49:05','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0006 validated',22,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(484,'484',NULL,1,'2020-01-01 17:50:41','2020-01-01 17:50:41',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SA2001-0001 validated','2020-01-01 17:50:41','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 validated',23,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(485,'485',NULL,1,'2020-01-01 17:50:44','2020-01-01 17:50:44',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0001 changed to paid','2020-01-01 17:50:44','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 changed to paid',23,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(486,'486',NULL,1,'2020-01-01 17:51:22','2020-01-01 17:51:22',40,'AC_BILL_SUPPLIER_UNVALIDATE','Invoice SI2001-0006 go back to draft status','2020-01-01 17:51:22','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0006 go back to draft status',22,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(487,'487',NULL,1,'2020-01-01 20:17:00','2020-01-01 20:17:00',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SI2001-0006 validated','2020-01-01 20:17:00','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0006 validated',22,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(488,'488',NULL,1,'2020-01-01 20:17:46','2020-01-01 20:17:46',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SA2001-0001 validated','2020-01-01 20:17:46','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 validated',24,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(489,'489',NULL,1,'2020-01-01 20:17:51','2020-01-01 20:17:51',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0001 changed to paid','2020-01-01 20:17:51','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 changed to paid',24,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(490,'490',NULL,1,'2020-01-01 20:20:22','2020-01-01 20:20:22',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SA2001-0001 validated','2020-01-01 20:20:22','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 validated',26,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(491,'491',NULL,1,'2020-01-01 20:20:31','2020-01-01 20:20:31',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0001 changed to paid','2020-01-01 20:20:31','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 changed to paid',26,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(492,'492',NULL,1,'2020-01-01 20:21:35','2020-01-01 20:21:35',40,'AC_BILL_SUPPLIER_UNVALIDATE','Invoice SI2001-0006 go back to draft status','2020-01-01 20:21:35','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0006 go back to draft status',22,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(493,'493',NULL,1,'2020-01-01 20:21:42','2020-01-01 20:21:42',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SI2001-0006 validated','2020-01-01 20:21:42','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0006 validated',22,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(494,'494',NULL,1,'2020-01-01 20:21:55','2020-01-01 20:21:55',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SA2001-0001 validated','2020-01-01 20:21:55','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 validated',27,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(495,'495',NULL,1,'2020-01-01 20:23:02','2020-01-01 20:23:02',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SI2001-0007 validated','2020-01-01 20:23:02','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0007 validated',28,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(496,'496',NULL,1,'2020-01-01 20:23:17','2020-01-01 20:23:17',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0001 changed to paid','2020-01-01 20:23:17','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 changed to paid',27,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(497,'497',NULL,1,'2020-01-01 20:25:36','2020-01-01 20:25:36',40,'AC_BILL_SUPPLIER_PAYED','Invoice SI2001-0007 changed to paid','2020-01-01 20:25:36','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0007 changed to paid',28,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(498,'498',NULL,1,'2020-01-01 20:51:37','2020-01-01 20:51:37',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SA2001-0002 validated','2020-01-01 20:51:37','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0002 validated',30,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(499,'499',NULL,1,'2020-01-01 20:51:48','2020-01-01 20:51:48',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0002 changed to paid','2020-01-01 20:51:48','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0002 changed to paid',30,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(500,'500',NULL,1,'2020-01-01 21:02:39','2020-01-01 21:02:39',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0001 changed to paid','2020-01-01 21:02:39','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 changed to paid',27,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(501,'501',NULL,1,'2020-01-01 21:03:01','2020-01-01 21:03:01',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0001 changed to paid','2020-01-01 21:03:01','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 changed to paid',27,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(502,'502',NULL,1,'2020-01-01 21:11:10','2020-01-01 21:11:10',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0001 changed to paid','2020-01-01 21:11:10','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 changed to paid',27,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(503,'503',NULL,1,'2020-01-01 21:20:07','2020-01-01 21:20:07',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0001 changed to paid','2020-01-01 21:20:07','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 changed to paid',27,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(504,'504',NULL,1,'2020-01-01 21:21:28','2020-01-01 21:21:28',40,'AC_BILL_SUPPLIER_PAYED','Invoice SI2001-0007 changed to paid','2020-01-01 21:21:28','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0007 changed to paid',28,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(505,'505',NULL,1,'2020-01-01 22:06:30','2020-01-01 22:06:30',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0001 changed to paid','2020-01-01 22:06:31','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 changed to paid',27,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(506,'506',NULL,1,'2020-01-01 23:54:16','2020-01-01 23:54:16',40,'AC_PRODUCT_MODIFY','Product APPLEPIE modified','2020-01-01 23:54:16','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct APPLEPIE modified',4,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(507,'507',NULL,1,'2020-01-02 20:49:34','2020-01-02 20:49:34',40,'AC_BILL_PAYED','Invoice FA1601-0024 changed to paid','2020-01-02 20:49:34','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1601-0024 changed to paid',149,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(508,'508',NULL,1,'2020-01-02 23:02:35','2020-01-02 23:02:35',40,'AC_PRODUCT_MODIFY','Product APPLEPIE modified','2020-01-02 23:02:35','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct APPLEPIE modified',4,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(509,'509',NULL,1,'2020-01-02 23:45:01','2020-01-02 23:45:01',40,'AC_BOM_REOPEN','BOM reopen','2020-01-02 23:45:01','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM reopen',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(511,'511',NULL,1,'2020-01-02 23:57:42','2020-01-02 23:57:42',40,'AC_MRP_MO_VALIDATE','MO validated','2020-01-02 23:57:42','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO validated',14,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(512,'512',NULL,1,'2020-01-03 13:33:54','2020-01-03 13:33:54',40,'AC_BOM_UNVALIDATE','BOM unvalidated','2020-01-03 13:33:54','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM unvalidated',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(513,'513',NULL,1,'2020-01-03 13:34:11','2020-01-03 13:34:11',40,'AC_BOM_VALIDATE','BOM validated','2020-01-03 13:34:11','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM validated',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(514,'514',NULL,1,'2020-01-03 13:35:45','2020-01-03 13:35:45',40,'AC_MRP_MO_VALIDATE','MO validated','2020-01-03 13:35:45','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO validated',18,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(515,'515',NULL,1,'2020-01-03 14:10:41','2020-01-03 14:10:41',40,'AC_MRP_MO_VALIDATE','MO validated','2020-01-03 14:10:41','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO validated',18,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(516,'516',NULL,1,'2020-01-06 00:39:58','2020-01-06 00:39:58',40,'AC_COMPANY_CREATE','Patient créé','2020-01-06 00:39:58','2021-04-15 10:22:55',12,NULL,NULL,29,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nPatient créé',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(517,'517',NULL,1,'2020-01-06 00:49:06','2020-01-06 00:49:06',40,'AC_BILL_SUPPLIER_UNVALIDATE','Invoice SI2001-0006 go back to draft status','2020-01-06 00:49:06','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0006 go back to draft status',22,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(518,'518',NULL,1,'2020-01-06 06:50:05','2020-01-06 06:50:05',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-06 06:50:05','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',14,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(519,'519',NULL,1,'2020-01-06 20:52:28','2020-01-06 20:52:28',40,'AC_OTH_AUTO','Consultation 2 recorded (Patient)','2020-01-06 20:52:28','2021-04-15 10:22:55',12,NULL,NULL,29,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Consultation 2 recorded (Patient)\nAuthor: admin',2,'cabinetmed_cons',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(520,'520',NULL,1,'2020-01-07 20:25:02','2020-01-07 20:25:02',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 20:25:02','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(521,'521',NULL,1,'2020-01-07 21:12:37','2020-01-07 21:12:37',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 21:12:37','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(522,'522',NULL,1,'2020-01-07 21:13:00','2020-01-07 21:13:00',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 21:13:00','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(523,'523',NULL,1,'2020-01-07 21:13:49','2020-01-07 21:13:49',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 21:13:49','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(524,'524',NULL,1,'2020-01-07 21:46:58','2020-01-07 21:46:58',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 21:46:58','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(525,'525',NULL,1,'2020-01-07 21:52:34','2020-01-07 21:52:34',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 21:52:34','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(526,'526',NULL,1,'2020-01-07 21:53:44','2020-01-07 21:53:44',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 21:53:44','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(527,'527',NULL,1,'2020-01-07 21:53:58','2020-01-07 21:53:58',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 21:53:58','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(528,'528',NULL,1,'2020-01-07 21:54:12','2020-01-07 21:54:12',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 21:54:12','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(529,'529',NULL,1,'2020-01-07 22:00:55','2020-01-07 22:00:55',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 22:00:55','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(530,'530',NULL,1,'2020-01-07 22:39:52','2020-01-07 22:39:52',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 22:39:52','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',14,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(531,'531',NULL,1,'2020-01-07 23:09:04','2020-01-07 23:09:04',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 23:09:04','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',14,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(532,'532',NULL,1,'2020-01-07 23:39:09','2020-01-07 23:39:09',40,'AC_PROPAL_CLOSE_SIGNED','Proposal PR1909-0033 signed','2020-01-07 23:39:09','2021-04-15 10:22:55',12,NULL,6,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR1909-0033 signed',34,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(533,'533',NULL,1,'2020-01-07 23:43:06','2020-01-07 23:43:06',40,'AC_PROPAL_CLOSE_SIGNED','Proposal PR1909-0033 signed','2020-01-07 23:43:06','2021-04-15 10:22:55',12,NULL,6,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR1909-0033 signed',34,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(534,'534',NULL,1,'2020-01-07 23:50:40','2020-01-07 23:50:40',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 23:50:40','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(535,'535',NULL,1,'2020-01-07 23:51:27','2020-01-07 23:51:27',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 23:51:27','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(536,'536',NULL,1,'2020-01-08 00:25:23','2020-01-08 00:25:23',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 00:25:23','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(537,'537',NULL,1,'2020-01-08 00:25:43','2020-01-08 00:25:43',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 00:25:43','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(538,'538',NULL,1,'2020-01-08 00:29:24','2020-01-08 00:29:24',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 00:29:24','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(539,'539',NULL,1,'2020-01-08 00:29:43','2020-01-08 00:29:43',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 00:29:43','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(540,'540',NULL,1,'2020-01-08 01:09:15','2020-01-08 01:09:15',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 01:09:15','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(541,'541',NULL,1,'2020-01-08 01:15:02','2020-01-08 01:15:02',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 01:15:02','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(542,'542',NULL,1,'2020-01-08 01:17:16','2020-01-08 01:17:16',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 01:17:16','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(543,'543',NULL,1,'2020-01-08 05:31:44','2020-01-08 05:31:44',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 05:31:44','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(544,'544',NULL,1,'2020-01-08 05:39:46','2020-01-08 05:39:46',40,'AC_BOM_CLOSE','BOM disabled','2020-01-08 05:39:46','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM disabled',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(545,'545',NULL,1,'2020-01-08 05:39:50','2020-01-08 05:39:50',40,'AC_BOM_REOPEN','BOM reopen','2020-01-08 05:39:50','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM reopen',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(546,'546',NULL,1,'2020-01-08 06:06:50','2020-01-08 06:06:50',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 06:06:50','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',14,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(547,'547',NULL,1,'2020-01-08 19:34:53','2020-01-08 19:34:53',40,'AC_BOM_UNVALIDATE','BOM unvalidated','2020-01-08 19:34:53','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM unvalidated',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(548,'548',NULL,1,'2020-01-08 19:40:27','2020-01-08 19:40:27',40,'AC_PRODUCT_MODIFY','Product APPLEPIE modified','2020-01-08 19:40:27','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct APPLEPIE modified',4,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(549,'549',NULL,1,'2020-01-08 19:40:46','2020-01-08 19:40:46',40,'AC_PRODUCT_MODIFY','Product PINKDRESS modified','2020-01-08 19:40:46','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PINKDRESS modified',1,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(550,'550',NULL,1,'2020-01-08 19:40:59','2020-01-08 19:40:59',40,'AC_BOM_VALIDATE','BOM validated','2020-01-08 19:40:59','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM validated',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(551,'551',NULL,1,'2020-01-08 19:41:11','2020-01-08 19:41:11',40,'AC_BOM_UNVALIDATE','BOM unvalidated','2020-01-08 19:41:11','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM unvalidated',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(552,'552',NULL,1,'2020-01-08 19:41:49','2020-01-08 19:41:49',40,'AC_BOM_VALIDATE','BOM validated','2020-01-08 19:41:49','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM validated',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(553,'553',NULL,1,'2020-01-08 20:12:55','2020-01-08 20:12:55',40,'AC_MRP_MO_VALIDATE','MO validated','2020-01-08 20:12:55','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO validated',28,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(554,'554',NULL,1,'2020-01-08 20:21:22','2020-01-08 20:21:22',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 20:21:22','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',28,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(555,'555',NULL,1,'2020-01-08 20:41:19','2020-01-08 20:41:19',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 20:41:19','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',28,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(556,'556',NULL,1,'2020-01-08 22:25:19','2020-01-08 22:25:19',40,'AC_BOM_DELETE','BOM deleted','2020-01-08 22:25:19','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM deleted',7,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(557,'557',NULL,1,'2020-01-13 15:11:07','2020-01-13 15:11:07',40,'AC_MO_DELETE','MO_DELETEInDolibarr','2020-01-13 15:11:07','2021-04-15 10:22:55',12,NULL,6,26,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO_DELETEInDolibarr',25,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(558,'558',NULL,1,'2020-01-13 15:11:54','2020-01-13 15:11:54',40,'AC_MRP_MO_VALIDATE','MO validated','2020-01-13 15:11:54','2021-04-15 10:22:55',12,NULL,6,26,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO validated',24,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(559,'559',NULL,1,'2020-01-13 15:13:19','2020-01-13 15:13:19',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-13 15:13:19','2021-04-15 10:22:55',12,NULL,6,26,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',24,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(560,'560',NULL,1,'2020-01-13 15:14:15','2020-01-13 15:14:15',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-13 15:14:15','2021-04-15 10:22:55',12,NULL,6,26,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',24,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(561,'561',NULL,1,'2020-01-13 15:29:30','2020-01-13 15:29:30',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-13 15:29:30','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(562,'562',NULL,1,'2020-01-13 17:19:24','2020-01-13 17:19:24',40,'AC_COMPANY_CREATE','Third party Italo created','2020-01-13 17:19:24','2021-04-15 10:22:55',12,NULL,NULL,30,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nThird party Italo created',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(563,'563',NULL,1,'2020-01-15 16:27:15','2020-01-15 16:27:15',40,'AC_PROJECT_MODIFY','Project RMLL modified','2020-01-15 16:27:15','2021-04-15 10:22:55',12,NULL,5,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject RMLL modified\nTask: RMLL',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(564,'564',NULL,1,'2020-01-15 16:40:50','2020-01-15 16:40:50',40,'AC_PROJECT_MODIFY','Project PROJINDIAN modified','2020-01-15 16:40:50','2021-04-15 10:22:55',12,NULL,3,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PROJINDIAN modified\nTask: PROJINDIAN',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(565,'565',NULL,1,'2020-01-16 02:22:16','2020-01-16 02:22:16',40,'AC_BILL_VALIDATE','Invoice AC2001-0001 validated','2020-01-16 02:22:16','2021-04-15 10:22:55',12,NULL,NULL,19,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0001 validated',221,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(566,'566',NULL,1,'2020-01-16 02:22:24','2020-01-16 02:22:24',40,'AC_BILL_UNVALIDATE','Invoice AC2001-0001 go back to draft status','2020-01-16 02:22:24','2021-04-15 10:22:55',12,NULL,NULL,19,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0001 go back to draft status',221,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(567,'567',NULL,1,'2020-01-16 02:33:27','2020-01-16 02:33:27',40,'AC_BILL_VALIDATE','Invoice AC2001-0002 validated','2020-01-16 02:33:27','2021-04-15 10:22:55',12,NULL,NULL,19,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0002 validated',224,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(568,'568',NULL,1,'2020-01-16 02:36:48','2020-01-16 02:36:48',40,'AC_BILL_PAYED','Invoice AC2001-0002 changed to paid','2020-01-16 02:36:48','2021-04-15 10:22:55',12,NULL,NULL,19,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0002 changed to paid',224,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(569,'569',NULL,1,'2020-01-16 02:42:12','2020-01-16 02:42:12',40,'AC_ORDER_CLASSIFY_BILLED','Order CO7001-0020 classified billed','2020-01-16 02:42:12','2021-04-15 10:22:55',12,NULL,NULL,6,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nOrder CO7001-0020 classified billed',72,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(570,'570',NULL,1,'2020-01-16 02:42:17','2020-01-16 02:42:17',40,'AC_ORDER_CLOSE','Order CO7001-0020 classified delivered','2020-01-16 02:42:17','2021-04-15 10:22:55',12,NULL,NULL,6,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nOrder CO7001-0020 classified delivered',72,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(571,'571',NULL,1,'2020-01-16 02:42:56','2020-01-16 02:42:56',40,'AC_ORDER_CLOSE','Order CO7001-0020 classified delivered','2020-01-16 02:42:56','2021-04-15 10:22:55',12,NULL,NULL,6,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nOrder CO7001-0020 classified delivered',72,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(572,'572',NULL,1,'2020-01-16 18:05:43','2020-01-16 18:05:43',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SI2001-0006 validated','2020-01-16 18:05:43','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0006 validated',22,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(573,'573',NULL,1,'2020-01-17 14:54:18','2020-01-17 14:54:18',40,'AC_PRODUCT_MODIFY','Product PINKDRESS modified','2020-01-17 14:54:18','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PINKDRESS modified',1,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(574,'574',NULL,1,'2020-01-17 15:22:28','2020-01-17 15:22:28',40,'AC_PRODUCT_MODIFY','Product PINKDRESS modified','2020-01-17 15:22:28','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PINKDRESS modified',1,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(575,'575',NULL,1,'2020-01-19 14:22:27','2020-01-19 14:22:27',40,'AC_PROPAL_VALIDATE','Proposal PR2001-0034 validated','2020-01-19 14:22:27','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR2001-0034 validated',36,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(576,'576',NULL,1,'2020-01-19 14:22:34','2020-01-19 14:22:34',40,'AC_PROPAL_CLOSE_SIGNED','Proposal PR2001-0034 signed','2020-01-19 14:22:34','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR2001-0034 signed',36,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(577,'577',NULL,1,'2020-01-19 14:24:22','2020-01-19 14:24:22',40,'AC_PROPAL_VALIDATE','Proposal PR2001-0034 validated','2020-01-19 14:24:22','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR2001-0034 validated',36,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(578,'578',NULL,1,'2020-01-19 14:24:27','2020-01-19 14:24:27',40,'AC_PROPAL_CLOSE_SIGNED','Proposal PR2001-0034 signed','2020-01-19 14:24:27','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR2001-0034 signed',36,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(579,'579',NULL,1,'2020-01-19 14:51:43','2020-01-19 14:51:43',40,'AC_BILL_VALIDATE','Invoice AC2001-0003 validated','2020-01-19 14:51:43','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0003 validated',227,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(580,'580',NULL,1,'2020-01-19 14:51:48','2020-01-19 14:51:48',40,'AC_BILL_UNVALIDATE','Invoice AC2001-0003 go back to draft status','2020-01-19 14:51:48','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0003 go back to draft status',227,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(581,'581',NULL,1,'2020-01-19 15:01:26','2020-01-19 15:01:26',40,'AC_BILL_VALIDATE','Invoice AC2001-0004 validated','2020-01-19 15:01:26','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0004 validated',228,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(582,'582',NULL,1,'2020-01-19 15:04:37','2020-01-19 15:04:37',40,'AC_BILL_UNVALIDATE','Invoice AC2001-0004 go back to draft status','2020-01-19 15:04:37','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0004 go back to draft status',228,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(583,'583',NULL,1,'2020-01-19 15:04:53','2020-01-19 15:04:53',40,'AC_BILL_VALIDATE','Invoice AC2001-0004 validated','2020-01-19 15:04:53','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0004 validated',228,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(584,'584',NULL,1,'2020-01-19 15:09:14','2020-01-19 15:09:14',40,'AC_BILL_UNVALIDATE','Invoice AC2001-0004 go back to draft status','2020-01-19 15:09:14','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0004 go back to draft status',228,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(585,'585',NULL,1,'2020-01-19 15:13:07','2020-01-19 15:13:07',40,'AC_BILL_VALIDATE','Invoice AC2001-0004 validated','2020-01-19 15:13:07','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0004 validated',228,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(586,'586',NULL,1,'2020-01-20 12:20:11','2020-01-20 12:20:11',40,'AC_ORDER_SUPPLIER_CREATE','Order (PROV14) created','2020-01-20 12:20:11','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nOrder (PROV14) created',14,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(588,'588',NULL,1,'2020-01-21 01:02:14','2020-01-21 01:02:14',40,'AC_MEMBER_SUBSCRIPTION_CREATE','Subscription 2 for member Vick Smith added','2020-01-21 01:02:14','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nSubscription 2 for member Vick Smith added\nMember: Vick Smith\nType: 2\nAmount: 50\nPeriod: 07/18/2013 - 07/17/2014',3,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(589,'589',NULL,1,'2020-01-21 10:22:37','2020-01-21 10:22:37',40,'AC_MEMBER_SUBSCRIPTION_CREATE','Subscription 3 for member Vick Smith added','2020-01-21 10:22:37','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nSubscription 3 for member Vick Smith added\nMember: Vick Smith\nType: 2\nAmount: 50\nPeriod: 07/18/2017 - 07/17/2018',4,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(590,'590',NULL,1,'2020-01-21 10:23:17','2020-01-21 10:23:17',40,'AC_MEMBER_SUBSCRIPTION_CREATE','Subscription 4 for member Vick Smith added','2020-01-21 10:23:17','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nSubscription 4 for member Vick Smith added\nMember: Vick Smith\nType: 2\nAmount: 50\nPeriod: 07/18/2017 - 07/17/2018',2,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(591,'591',NULL,1,'2020-01-21 10:23:17','2020-01-21 10:23:17',40,'AC_BILL_VALIDATE','Invoice FA1707-0026 validated','2020-01-21 10:23:17','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1707-0026 validated',229,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(592,'592',NULL,1,'2020-01-21 10:23:17','2020-01-21 10:23:17',40,'AC_BILL_PAYED','Invoice FA1707-0026 changed to paid','2020-01-21 10:23:17','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1707-0026 changed to paid',229,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(593,'593',NULL,1,'2020-01-21 10:23:28','2020-01-21 10:23:28',40,'AC_MEMBER_SUBSCRIPTION_CREATE','Subscription 5 for member Vick Smith added','2020-01-21 10:23:28','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nSubscription 5 for member Vick Smith added\nMember: Vick Smith\nType: 2\nAmount: 50\nPeriod: 07/18/2018 - 07/17/2019',2,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(594,'594',NULL,1,'2020-01-21 10:23:28','2020-01-21 10:23:28',40,'AC_BILL_VALIDATE','Invoice FA1807-0027 validated','2020-01-21 10:23:28','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1807-0027 validated',230,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(595,'595',NULL,1,'2020-01-21 10:23:28','2020-01-21 10:23:28',40,'AC_BILL_PAYED','Invoice FA1807-0027 changed to paid','2020-01-21 10:23:28','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1807-0027 changed to paid',230,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(596,'596',NULL,1,'2020-01-21 10:23:49','2020-01-21 10:23:49',40,'AC_MEMBER_SUBSCRIPTION_CREATE','Subscription 6 for member Vick Smith added','2020-01-21 10:23:49','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nSubscription 6 for member Vick Smith added\nMember: Vick Smith\nType: 2\nAmount: 50\nPeriod: 07/18/2019 - 07/17/2020',2,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(597,'597',NULL,1,'2020-01-21 10:23:49','2020-01-21 10:23:49',40,'AC_BILL_VALIDATE','Invoice FA1907-0028 validated','2020-01-21 10:23:49','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1907-0028 validated',231,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(598,'598',NULL,1,'2020-01-21 10:23:49','2020-01-21 10:23:49',40,'AC_BILL_PAYED','Invoice FA1907-0028 changed to paid','2020-01-21 10:23:49','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1907-0028 changed to paid',231,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(599,'599',NULL,1,'2020-01-21 10:30:27','2020-01-21 10:30:27',40,'AC_MEMBER_MODIFY','Member Pierre Curie modified','2020-01-21 10:30:27','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember Pierre Curie modified\nMember: Pierre Curie\nType: Standard members',2,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(600,'600',NULL,1,'2020-01-21 10:30:36','2020-01-21 10:30:36',40,'AC_MEMBER_MODIFY','Member doe john modified','2020-01-21 10:30:36','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember doe john modified\nMember: doe john\nType: Standard members',3,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(601,'601',NULL,1,'2020-01-21 10:30:42','2020-01-21 10:30:42',40,'AC_MEMBER_MODIFY','Member smith smith modified','2020-01-21 10:30:42','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember smith smith modified\nMember: smith smith\nType: Standard members',4,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(602,'602',NULL,1,'2020-01-21 10:30:57','2020-01-21 10:30:57',40,'AC_MEMBER_MODIFY','Member Vick Smith modified','2020-01-21 10:30:57','2021-04-15 10:22:55',12,NULL,NULL,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember Vick Smith modified\nMember: Vick Smith\nType: Standard members',1,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(603,'603',NULL,1,'2020-06-12 10:00:00','2020-06-12 11:30:00',5,'AC_RDV','Meetings','2020-06-12 19:26:44','2021-04-15 10:22:55',12,NULL,3,NULL,NULL,0,12,1,NULL,0,0,-1,'Room 24',5400,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(604,'604',NULL,1,'2020-06-01 10:00:00','2020-06-01 10:27:00',1,'AC_TEL','Called Mr X','2020-06-12 19:28:13','2021-04-15 10:22:55',12,12,3,NULL,NULL,0,12,1,NULL,0,0,100,NULL,1620,NULL,'Customer ask another call.',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(605,'605',NULL,1,'2020-04-15 05:00:00','2020-04-15 06:00:00',5,'AC_RDV','Meet A2','2021-04-15 07:36:31','2021-04-15 10:36:31',12,NULL,NULL,NULL,NULL,0,12,1,NULL,0,0,0,'',3600,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(606,'606',NULL,1,'2021-04-15 08:38:02','2021-04-15 08:38:02',40,'AC_PRODUCT_CREATE','Product PRODSER created','2021-04-15 08:38:02','2021-04-15 11:38:02',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PRODSER created',31,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0); +INSERT INTO `llx_actioncomm` VALUES (1,'1',NULL,1,'2012-07-08 14:21:44','2012-07-08 14:21:44',50,NULL,'Company AAA and Co added into Dolibarr','2012-07-08 14:21:44','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Company AAA and Co added into Dolibarr\nAuthor: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(2,'2',NULL,1,'2012-07-08 14:23:48','2012-07-08 14:23:48',50,NULL,'Company Belin SARL added into Dolibarr','2012-07-08 14:23:48','2021-04-15 10:22:55',1,NULL,NULL,2,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Company Belin SARL added into Dolibarr\nAuthor: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(3,'3',NULL,1,'2012-07-08 22:42:12','2012-07-08 22:42:12',50,NULL,'Company Spanish Comp added into Dolibarr','2012-07-08 22:42:12','2021-04-15 10:22:55',1,NULL,NULL,3,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Company Spanish Comp added into Dolibarr\nAuthor: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(4,'4',NULL,1,'2012-07-08 22:48:18','2012-07-08 22:48:18',50,NULL,'Company Prospector Vaalen added into Dolibarr','2012-07-08 22:48:18','2021-04-15 10:22:55',1,NULL,NULL,4,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Company Prospector Vaalen added into Dolibarr\nAuthor: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(5,'5',NULL,1,'2012-07-08 23:22:57','2012-07-08 23:22:57',50,NULL,'Company NoCountry Co added into Dolibarr','2012-07-08 23:22:57','2021-04-15 10:22:55',1,NULL,NULL,5,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Company NoCountry Co added into Dolibarr\nAuthor: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(6,'6',NULL,1,'2012-07-09 00:15:09','2012-07-09 00:15:09',50,NULL,'Company Swiss customer added into Dolibarr','2012-07-09 00:15:09','2021-04-15 10:22:55',1,NULL,NULL,6,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Company Swiss customer added into Dolibarr\nAuthor: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(7,'7',NULL,1,'2012-07-09 01:24:26','2012-07-09 01:24:26',50,NULL,'Company Generic customer added into Dolibarr','2012-07-09 01:24:26','2021-04-15 10:22:55',1,NULL,NULL,7,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Company Generic customer added into Dolibarr\nAuthor: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(8,'8',NULL,1,'2012-07-10 14:54:27','2012-07-10 14:54:27',50,NULL,'Société Client salon ajoutée dans Dolibarr','2012-07-10 14:54:27','2021-04-15 10:22:55',1,NULL,NULL,8,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Société Client salon ajoutée dans Dolibarr\nAuteur: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(9,'9',NULL,1,'2012-07-10 14:54:44','2012-07-10 14:54:44',50,NULL,'Société Client salon invidivdu ajoutée dans Doliba','2012-07-10 14:54:44','2021-04-15 10:22:55',1,NULL,NULL,9,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Société Client salon invidivdu ajoutée dans Dolibarr\nAuteur: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(10,'10',NULL,1,'2012-07-10 14:56:10','2012-07-10 14:56:10',50,NULL,'Facture FA1007-0001 validée dans Dolibarr','2012-07-10 14:56:10','2021-04-15 10:22:55',1,NULL,NULL,9,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Facture FA1007-0001 validée dans Dolibarr\nAuteur: admin',1,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(11,'11',NULL,1,'2012-07-10 14:58:53','2012-07-10 14:58:53',50,NULL,'Facture FA1007-0001 validée dans Dolibarr','2012-07-10 14:58:53','2021-04-15 10:22:55',1,NULL,NULL,9,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Facture FA1007-0001 validée dans Dolibarr\nAuteur: admin',1,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(12,'12',NULL,1,'2012-07-10 15:00:55','2012-07-10 15:00:55',50,NULL,'Facture FA1007-0001 passée à payée dans Dolibarr','2012-07-10 15:00:55','2021-04-15 10:22:55',1,NULL,NULL,9,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Facture FA1007-0001 passée à payée dans Dolibarr\nAuteur: admin',1,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(13,'13',NULL,1,'2012-07-10 15:13:08','2012-07-10 15:13:08',50,NULL,'Société Smith Vick ajoutée dans Dolibarr','2012-07-10 15:13:08','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Société Smith Vick ajoutée dans Dolibarr\nAuteur: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(14,'14',NULL,1,'2012-07-10 15:21:00','2012-07-10 16:21:00',5,NULL,'RDV avec mon chef','2012-07-10 15:21:48','2021-04-15 10:22:55',1,NULL,NULL,NULL,NULL,0,1,NULL,NULL,0,0,0,'',3600,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(15,'15',NULL,1,'2012-07-10 18:18:16','2012-07-10 18:18:16',50,NULL,'Contrat CONTRAT1 validé dans Dolibarr','2012-07-10 18:18:16','2021-04-15 10:22:55',1,NULL,NULL,2,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Contrat CONTRAT1 validé dans Dolibarr\nAuteur: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(16,'16',NULL,1,'2012-07-10 18:35:57','2012-07-10 18:35:57',50,NULL,'Société Mon client ajoutée dans Dolibarr','2012-07-10 18:35:57','2021-04-15 10:22:55',1,NULL,NULL,11,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Société Mon client ajoutée dans Dolibarr\nAuteur: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(17,'17',NULL,1,'2012-07-11 16:18:08','2012-07-11 16:18:08',50,NULL,'Société Dupont Alain ajoutée dans Dolibarr','2012-07-11 16:18:08','2021-04-15 10:22:55',1,NULL,NULL,12,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Société Dupont Alain ajoutée dans Dolibarr\nAuteur: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(18,'18',NULL,1,'2012-07-11 17:11:00','2012-07-11 17:17:00',5,NULL,'Rendez-vous','2012-07-11 17:11:22','2021-04-15 10:22:55',1,NULL,NULL,NULL,NULL,0,1,NULL,NULL,0,0,0,'gfgdfgdf',360,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(19,'19',NULL,1,'2012-07-11 17:13:20','2012-07-11 17:13:20',50,NULL,'Société Vendeur de chips ajoutée dans Dolibarr','2012-07-11 17:13:20','2021-04-15 10:22:55',1,NULL,NULL,13,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Société Vendeur de chips ajoutée dans Dolibarr\nAuteur: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(20,'20',NULL,1,'2012-07-11 17:15:42','2012-07-11 17:15:42',50,NULL,'Commande CF1007-0001 validée','2012-07-11 17:15:42','2021-04-15 10:22:55',1,NULL,NULL,13,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Commande CF1007-0001 validée\nAuteur: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(21,'21',NULL,1,'2012-07-11 18:47:33','2012-07-11 18:47:33',50,NULL,'Commande CF1007-0002 validée','2012-07-11 18:47:33','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Commande CF1007-0002 validée\nAuteur: admin',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(22,'22',NULL,1,'2012-07-18 11:36:18','2012-07-18 11:36:18',50,NULL,'Proposition PR1007-0003 validée','2012-07-18 11:36:18','2021-04-15 10:22:55',1,NULL,NULL,4,NULL,0,1,NULL,1,0,0,100,'',NULL,NULL,'Proposition PR1007-0003 validée\nAuteur: admin',3,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(23,'23',NULL,1,'2013-07-18 20:49:58','2013-07-18 20:49:58',50,NULL,'Invoice FA1007-0002 validated in Dolibarr','2013-07-18 20:49:58','2021-04-15 10:22:55',1,NULL,NULL,2,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1007-0002 validated in Dolibarr\nAuthor: admin',2,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(24,'24',NULL,1,'2013-07-28 01:37:00',NULL,1,NULL,'Phone call','2013-07-28 01:37:48','2021-04-15 10:22:55',1,NULL,NULL,NULL,2,0,1,NULL,NULL,0,0,-1,'',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(25,'25',NULL,1,'2013-08-01 02:31:24','2013-08-01 02:31:24',50,NULL,'Company mmm added into Dolibarr','2013-08-01 02:31:24','2021-04-15 10:22:55',1,NULL,NULL,15,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Company mmm added into Dolibarr\nAuthor: admin',15,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(26,'26',NULL,1,'2013-08-01 02:31:43','2013-08-01 02:31:43',50,NULL,'Company ppp added into Dolibarr','2013-08-01 02:31:43','2021-04-15 10:22:55',1,NULL,NULL,16,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Company ppp added into Dolibarr\nAuthor: admin',16,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(27,'27',NULL,1,'2013-08-01 02:41:26','2013-08-01 02:41:26',50,NULL,'Company aaa added into Dolibarr','2013-08-01 02:41:26','2021-04-15 10:22:55',1,NULL,NULL,17,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Company aaa added into Dolibarr\nAuthor: admin',17,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(28,'28',NULL,1,'2013-08-01 03:34:11','2013-08-01 03:34:11',50,NULL,'Invoice FA1108-0003 validated in Dolibarr','2013-08-01 03:34:11','2021-04-15 10:22:55',1,NULL,NULL,7,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1108-0003 validated in Dolibarr\nAuthor: admin',5,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(29,'29',NULL,1,'2013-08-01 03:34:11','2013-08-01 03:34:11',50,NULL,'Invoice FA1108-0003 validated in Dolibarr','2013-08-01 03:34:11','2021-04-15 10:22:55',1,NULL,NULL,7,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1108-0003 changed to paid in Dolibarr\nAuthor: admin',5,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(30,'30',NULL,1,'2013-08-06 20:33:54','2013-08-06 20:33:54',50,NULL,'Invoice FA1108-0004 validated in Dolibarr','2013-08-06 20:33:54','2021-04-15 10:22:55',1,NULL,NULL,7,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1108-0004 validated in Dolibarr\nAuthor: admin',6,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(31,'31',NULL,1,'2013-08-06 20:33:54','2013-08-06 20:33:54',50,NULL,'Invoice FA1108-0004 validated in Dolibarr','2013-08-06 20:33:54','2021-04-15 10:22:55',1,NULL,NULL,7,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1108-0004 changed to paid in Dolibarr\nAuthor: admin',6,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(38,'38',NULL,1,'2013-08-08 02:41:55','2013-08-08 02:41:55',50,NULL,'Invoice FA1108-0005 validated in Dolibarr','2013-08-08 02:41:55','2021-04-15 10:22:55',1,NULL,NULL,2,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1108-0005 validated in Dolibarr\nAuthor: admin',8,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(40,'40',NULL,1,'2013-08-08 02:53:40','2013-08-08 02:53:40',50,NULL,'Invoice FA1108-0005 changed to paid in Dolibarr','2013-08-08 02:53:40','2021-04-15 10:22:55',1,NULL,NULL,2,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1108-0005 changed to paid in Dolibarr\nAuthor: admin',8,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(41,'41',NULL,1,'2013-08-08 02:54:05','2013-08-08 02:54:05',50,NULL,'Invoice FA1007-0002 changed to paid in Dolibarr','2013-08-08 02:54:05','2021-04-15 10:22:55',1,NULL,NULL,2,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1007-0002 changed to paid in Dolibarr\nAuthor: admin',2,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(42,'42',NULL,1,'2013-08-08 02:55:04','2013-08-08 02:55:04',50,NULL,'Invoice FA1107-0006 validated in Dolibarr','2013-08-08 02:55:04','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1107-0006 validated in Dolibarr\nAuthor: admin',3,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(43,'43',NULL,1,'2013-08-08 02:55:26','2013-08-08 02:55:26',50,NULL,'Invoice FA1108-0007 validated in Dolibarr','2013-08-08 02:55:26','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1108-0007 validated in Dolibarr\nAuthor: admin',9,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(44,'44',NULL,1,'2013-08-08 02:55:58','2013-08-08 02:55:58',50,NULL,'Invoice FA1107-0006 changed to paid in Dolibarr','2013-08-08 02:55:58','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Invoice FA1107-0006 changed to paid in Dolibarr\nAuthor: admin',3,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(45,'45',NULL,1,'2013-08-08 03:04:22','2013-08-08 03:04:22',50,NULL,'Order CO1108-0001 validated','2013-08-08 03:04:22','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Order CO1108-0001 validated\nAuthor: admin',5,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(46,'46',NULL,1,'2013-08-08 13:59:09','2013-08-08 13:59:09',50,NULL,'Order CO1107-0002 validated','2013-08-08 13:59:10','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Order CO1107-0002 validated\nAuthor: admin',1,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(47,'47',NULL,1,'2013-08-08 14:24:18','2013-08-08 14:24:18',50,NULL,'Proposal PR1007-0001 validated','2013-08-08 14:24:18','2021-04-15 10:22:55',1,NULL,NULL,2,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Proposal PR1007-0001 validated\nAuthor: admin',1,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(48,'48',NULL,1,'2013-08-08 14:24:24','2013-08-08 14:24:24',50,NULL,'Proposal PR1108-0004 validated','2013-08-08 14:24:24','2021-04-15 10:22:55',1,NULL,NULL,17,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Proposal PR1108-0004 validated\nAuthor: admin',4,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(49,'49',NULL,1,'2013-08-08 15:04:37','2013-08-08 15:04:37',50,NULL,'Order CF1108-0003 validated','2013-08-08 15:04:37','2021-04-15 10:22:55',1,NULL,NULL,17,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Order CF1108-0003 validated\nAuthor: admin',6,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(50,'50',NULL,1,'2014-12-08 17:56:47','2014-12-08 17:56:47',40,NULL,'Facture AV1212-0001 validée dans Dolibarr','2014-12-08 17:56:47','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture AV1212-0001 validée dans Dolibarr\nAuteur: admin',10,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(51,'51',NULL,1,'2014-12-08 17:57:11','2014-12-08 17:57:11',40,NULL,'Facture AV1212-0001 validée dans Dolibarr','2014-12-08 17:57:11','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture AV1212-0001 validée dans Dolibarr\nAuteur: admin',10,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(52,'52',NULL,1,'2014-12-08 17:58:27','2014-12-08 17:58:27',40,NULL,'Facture FA1212-0008 validée dans Dolibarr','2014-12-08 17:58:27','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1212-0008 validée dans Dolibarr\nAuteur: admin',11,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(53,'53',NULL,1,'2014-12-08 18:20:49','2014-12-08 18:20:49',40,NULL,'Facture AV1212-0002 validée dans Dolibarr','2014-12-08 18:20:49','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture AV1212-0002 validée dans Dolibarr\nAuteur: admin',12,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(54,'54',NULL,1,'2014-12-09 18:35:07','2014-12-09 18:35:07',40,NULL,'Facture AV1212-0002 passée à payée dans Dolibarr','2014-12-09 18:35:07','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture AV1212-0002 passée à payée dans Dolibarr\nAuteur: admin',12,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(55,'55',NULL,1,'2014-12-09 20:14:42','2014-12-09 20:14:42',40,NULL,'Société doe john ajoutée dans Dolibarr','2014-12-09 20:14:42','2021-04-15 10:22:55',1,NULL,NULL,18,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Société doe john ajoutée dans Dolibarr\nAuteur: admin',18,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(56,'56',NULL,1,'2014-12-12 18:54:19','2014-12-12 18:54:19',40,NULL,'Facture FA1212-0009 validée dans Dolibarr','2014-12-12 18:54:19','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1212-0009 validée dans Dolibarr\nAuteur: admin',55,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(121,'121',NULL,1,'2014-12-06 10:00:00',NULL,50,NULL,'aaab','2014-12-21 17:48:08','2021-04-15 10:22:55',3,1,NULL,NULL,NULL,0,3,NULL,NULL,1,0,-1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(122,'122',NULL,1,'2014-12-21 18:09:52','2014-12-21 18:09:52',40,NULL,'Facture client FA1007-0001 envoyée par EMail','2014-12-21 18:09:52','2021-04-15 10:22:55',1,NULL,NULL,9,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Mail envoyé par Firstname SuperAdminName à laurent@mycompany.fr.\nSujet du mail: Envoi facture FA1007-0001\nCorps du mail:\nVeuillez trouver ci-joint la facture FA1007-0001\r\n\r\nVous pouvez cliquer sur le lien sécurisé ci-dessous pour effectuer votre paiement via Paypal\r\n\r\nhttp://localhost/dolibarrnew/public/paypal/newpayment.php?source=invoice&ref=FA1007-0001&securekey=50c82fab36bb3b6aa83e2a50691803b2\r\n\r\nCordialement',1,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(123,'123',NULL,1,'2015-01-06 13:13:57','2015-01-06 13:13:57',40,NULL,'Facture 16 validée dans Dolibarr','2015-01-06 13:13:57','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture 16 validée dans Dolibarr\nAuteur: admin',16,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(124,'124',NULL,1,'2015-01-12 12:23:05','2015-01-12 12:23:05',40,NULL,'Patient aaa ajouté','2015-01-12 12:23:05','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Patient aaa ajouté\nAuteur: admin',19,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(125,'125',NULL,1,'2015-01-12 12:52:20','2015-01-12 12:52:20',40,NULL,'Patient pppoo ajouté','2015-01-12 12:52:20','2021-04-15 10:22:55',1,NULL,NULL,20,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Patient pppoo ajouté\nAuteur: admin',20,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(127,'127',NULL,1,'2015-01-19 18:22:48','2015-01-19 18:22:48',40,NULL,'Facture FS1301-0001 validée dans Dolibarr','2015-01-19 18:22:48','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FS1301-0001 validée dans Dolibarr\nAuteur: admin',148,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(128,'128',NULL,1,'2015-01-19 18:31:10','2015-01-19 18:31:10',40,NULL,'Facture FA6801-0010 validée dans Dolibarr','2015-01-19 18:31:10','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA6801-0010 validée dans Dolibarr\nAuteur: admin',150,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(129,'129',NULL,1,'2015-01-19 18:31:10','2015-01-19 18:31:10',40,NULL,'Facture FA6801-0010 passée à payée dans Dolibarr','2015-01-19 18:31:10','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA6801-0010 passée à payée dans Dolibarr\nAuteur: admin',150,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(130,'130',NULL,1,'2015-01-19 18:31:58','2015-01-19 18:31:58',40,NULL,'Facture FS1301-0002 validée dans Dolibarr','2015-01-19 18:31:58','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FS1301-0002 validée dans Dolibarr\nAuteur: admin',151,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(131,'131',NULL,1,'2015-01-19 18:31:58','2015-01-19 18:31:58',40,NULL,'Facture FS1301-0002 passée à payée dans Dolibarr','2015-01-19 18:31:58','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FS1301-0002 passée à payée dans Dolibarr\nAuteur: admin',151,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(132,'132',NULL,1,'2015-01-23 15:07:54','2015-01-23 15:07:54',50,NULL,'Consultation 24 saisie (aaa)','2015-01-23 15:07:54','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Consultation 24 saisie (aaa)\nAuteur: admin',24,'cabinetmed_cons',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(133,'133',NULL,1,'2015-01-23 16:56:58','2015-01-23 16:56:58',40,NULL,'Patient pa ajouté','2015-01-23 16:56:58','2021-04-15 10:22:55',1,NULL,NULL,21,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Patient pa ajouté\nAuteur: admin',21,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(134,'134',NULL,1,'2015-01-23 17:34:00',NULL,50,NULL,'bbcv','2015-01-23 17:35:21','2021-04-15 10:22:55',1,NULL,1,2,NULL,0,1,NULL,NULL,0,0,-1,'',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(135,'135',NULL,1,'2015-02-12 15:54:00','2015-02-12 15:54:00',40,NULL,'Facture FA1212-0011 validée dans Dolibarr','2015-02-12 15:54:37','2021-04-15 10:22:55',1,1,NULL,7,NULL,0,1,NULL,1,0,0,50,NULL,NULL,NULL,'Facture FA1212-0011 validée dans Dolibarr
\r\nAuteur: admin',13,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(136,'136',NULL,1,'2015-02-12 17:06:51','2015-02-12 17:06:51',40,NULL,'Commande CO1107-0003 validée','2015-02-12 17:06:51','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Commande CO1107-0003 validée\nAuteur: admin',2,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(137,'137',NULL,1,'2015-02-17 16:22:10','2015-02-17 16:22:10',40,NULL,'Proposition PR1302-0009 validée','2015-02-17 16:22:10','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Proposition PR1302-0009 validée\nAuteur: admin',9,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(138,'138',NULL,1,'2015-02-17 16:27:00','2015-02-17 16:27:00',40,NULL,'Facture FA1302-0012 validée dans Dolibarr','2015-02-17 16:27:00','2021-04-15 10:22:55',1,NULL,NULL,18,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1302-0012 validée dans Dolibarr\nAuteur: admin',152,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(139,'139',NULL,1,'2015-02-17 16:27:29','2015-02-17 16:27:29',40,NULL,'Proposition PR1302-0010 validée','2015-02-17 16:27:29','2021-04-15 10:22:55',1,NULL,NULL,18,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Proposition PR1302-0010 validée\nAuteur: admin',11,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(140,'140',NULL,1,'2015-02-17 18:27:56','2015-02-17 18:27:56',40,NULL,'Commande CO1107-0004 validée','2015-02-17 18:27:56','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Commande CO1107-0004 validée\nAuteur: admin',3,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(141,'141',NULL,1,'2015-02-17 18:38:14','2015-02-17 18:38:14',40,NULL,'Commande CO1302-0005 validée','2015-02-17 18:38:14','2021-04-15 10:22:55',1,NULL,NULL,18,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Commande CO1302-0005 validée\nAuteur: admin',7,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(142,'142',NULL,1,'2015-02-26 22:57:50','2015-02-26 22:57:50',40,NULL,'Company pppp added into Dolibarr','2015-02-26 22:57:50','2021-04-15 10:22:55',1,NULL,NULL,22,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Company pppp added into Dolibarr\nAuthor: admin',22,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(143,'143',NULL,1,'2015-02-26 22:58:13','2015-02-26 22:58:13',40,NULL,'Company ttttt added into Dolibarr','2015-02-26 22:58:13','2021-04-15 10:22:55',1,NULL,NULL,23,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Company ttttt added into Dolibarr\nAuthor: admin',23,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(144,'144',NULL,1,'2015-02-27 10:00:00','2015-02-27 19:20:00',5,NULL,'Rendez-vous','2015-02-27 19:20:53','2021-04-15 10:22:55',1,NULL,NULL,NULL,NULL,0,1,NULL,1,0,0,-1,'',33600,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(145,'145',NULL,1,'2015-02-27 19:28:00',NULL,2,NULL,'fdsfsd','2015-02-27 19:28:48','2021-04-15 10:22:55',1,1,NULL,NULL,NULL,0,1,NULL,1,0,0,-1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(146,'146',NULL,1,'2015-03-06 10:05:07','2015-03-06 10:05:07',40,NULL,'Contrat (PROV3) validé dans Dolibarr','2015-03-06 10:05:07','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Contrat (PROV3) validé dans Dolibarr\nAuteur: admin',3,'contract',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(147,'147',NULL,1,'2015-03-06 16:43:37','2015-03-06 16:43:37',40,NULL,'Facture FA1307-0013 validée dans Dolibarr','2015-03-06 16:43:37','2021-04-15 10:22:55',1,NULL,NULL,12,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1307-0013 validée dans Dolibarr\nAuteur: admin',158,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(148,'148',NULL,1,'2015-03-06 16:44:12','2015-03-06 16:44:12',40,NULL,'Facture FA1407-0014 validée dans Dolibarr','2015-03-06 16:44:12','2021-04-15 10:22:55',1,NULL,NULL,12,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1407-0014 validée dans Dolibarr\nAuteur: admin',159,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(149,'149',NULL,1,'2015-03-06 16:47:48','2015-03-06 16:47:48',40,NULL,'Facture FA1507-0015 validée dans Dolibarr','2015-03-06 16:47:48','2021-04-15 10:22:55',1,NULL,NULL,12,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1507-0015 validée dans Dolibarr\nAuteur: admin',160,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(150,'150',NULL,1,'2015-03-06 16:48:16','2015-03-06 16:48:16',40,NULL,'Facture FA1607-0016 validée dans Dolibarr','2015-03-06 16:48:16','2021-04-15 10:22:55',1,NULL,NULL,12,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1607-0016 validée dans Dolibarr\nAuteur: admin',161,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(151,'151',NULL,1,'2015-03-06 17:13:59','2015-03-06 17:13:59',40,NULL,'Société smith smith ajoutée dans Dolibarr','2015-03-06 17:13:59','2021-04-15 10:22:55',1,NULL,NULL,24,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Société smith smith ajoutée dans Dolibarr\nAuteur: admin',24,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(152,'152',NULL,1,'2015-03-08 10:02:22','2015-03-08 10:02:22',40,NULL,'Proposition (PROV12) validée dans Dolibarr','2015-03-08 10:02:22','2021-04-15 10:22:55',1,NULL,NULL,23,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Proposition (PROV12) validée dans Dolibarr\nAuteur: admin',12,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(203,'203',NULL,1,'2015-03-09 19:39:27','2015-03-09 19:39:27',40,'AC_ORDER_SUPPLIER_VALIDATE','Commande CF1303-0004 validée','2015-03-09 19:39:27','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Commande CF1303-0004 validée\nAuteur: admin',13,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(204,'204',NULL,1,'2015-03-10 15:47:37','2015-03-10 15:47:37',40,'AC_COMPANY_CREATE','Patient créé','2015-03-10 15:47:37','2021-04-15 10:22:55',1,NULL,NULL,25,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Patient créé\nAuteur: admin',25,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(205,'205',NULL,1,'2015-03-10 15:57:32','2015-03-10 15:57:32',40,'AC_COMPANY_CREATE','Tiers créé','2015-03-10 15:57:32','2021-04-15 10:22:55',1,NULL,NULL,26,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Tiers créé\nAuteur: admin',26,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(206,'206',NULL,1,'2015-03-10 15:58:28','2015-03-10 15:58:28',40,'AC_BILL_VALIDATE','Facture FA1303-0017 validée','2015-03-10 15:58:28','2021-04-15 10:22:55',1,NULL,NULL,26,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1303-0017 validée\nAuteur: admin',208,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(207,'207',NULL,1,'2015-03-19 09:38:10','2015-03-19 09:38:10',40,'AC_BILL_VALIDATE','Facture FA1303-0018 validée','2015-03-19 09:38:10','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1303-0018 validée\nAuteur: admin',209,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(208,'208',NULL,1,'2015-03-20 14:30:11','2015-03-20 14:30:11',40,'AC_BILL_VALIDATE','Facture FA1107-0019 validée','2015-03-20 14:30:11','2021-04-15 10:22:55',1,NULL,NULL,10,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1107-0019 validée\nAuteur: admin',210,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(209,'209',NULL,1,'2015-03-22 09:40:25','2015-03-22 09:40:25',40,'AC_BILL_VALIDATE','Facture FA1303-0020 validée','2015-03-22 09:40:25','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1303-0020 validée\nAuteur: admin',211,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(210,'210',NULL,1,'2015-03-23 17:16:25','2015-03-23 17:16:25',40,'AC_BILL_VALIDATE','Facture FA1303-0020 validée','2015-03-23 17:16:25','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1303-0020 validée\nAuteur: admin',211,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(211,'211',NULL,1,'2015-03-23 18:08:27','2015-03-23 18:08:27',40,'AC_BILL_VALIDATE','Facture FA1307-0013 validée','2015-03-23 18:08:27','2021-04-15 10:22:55',1,NULL,NULL,12,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1307-0013 validée\nAuteur: admin',158,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(212,'212',NULL,1,'2015-03-24 15:54:00','2015-03-24 15:54:00',40,'AC_BILL_VALIDATE','Facture FA1212-0021 validée','2015-03-24 15:54:00','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,NULL,1,0,0,-1,'',NULL,NULL,'Facture FA1212-0021 validée\nAuteur: admin',32,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(213,'213',NULL,1,'2015-11-07 01:02:39','2015-11-07 01:02:39',40,'AC_COMPANY_CREATE','Third party created','2015-11-07 01:02:39','2021-04-15 10:22:55',1,NULL,NULL,27,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Third party created\nAuthor: admin',27,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(214,'214',NULL,1,'2015-11-07 01:05:22','2015-11-07 01:05:22',40,'AC_COMPANY_CREATE','Third party created','2015-11-07 01:05:22','2021-04-15 10:22:55',1,NULL,NULL,28,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Third party created\nAuthor: admin',28,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(215,'215',NULL,1,'2015-11-07 01:07:07','2015-11-07 01:07:07',40,'AC_COMPANY_CREATE','Third party created','2015-11-07 01:07:07','2021-04-15 10:22:55',1,NULL,NULL,29,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Third party created\nAuthor: admin',29,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(216,'216',NULL,1,'2015-11-07 01:07:58','2015-11-07 01:07:58',40,'AC_COMPANY_CREATE','Third party created','2015-11-07 01:07:58','2021-04-15 10:22:55',1,NULL,NULL,30,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Third party created\nAuthor: admin',30,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(217,'217',NULL,1,'2015-11-07 01:10:09','2015-11-07 01:10:09',40,'AC_COMPANY_CREATE','Third party created','2015-11-07 01:10:09','2021-04-15 10:22:55',1,NULL,NULL,31,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Third party created\nAuthor: admin',31,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(218,'218',NULL,1,'2015-11-07 01:15:57','2015-11-07 01:15:57',40,'AC_COMPANY_CREATE','Third party created','2015-11-07 01:15:57','2021-04-15 10:22:55',1,NULL,NULL,32,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Third party created\nAuthor: admin',32,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(219,'219',NULL,1,'2015-11-07 01:16:51','2015-11-07 01:16:51',40,'AC_COMPANY_CREATE','Third party created','2015-11-07 01:16:51','2021-04-15 10:22:55',1,NULL,NULL,33,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Third party created\nAuthor: admin',33,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(220,'220',NULL,1,'2016-03-02 17:24:04','2016-03-02 17:24:04',40,'AC_BILL_VALIDATE','Invoice FA1302-0022 validated','2016-03-02 17:24:04','2021-04-15 10:22:55',1,NULL,NULL,18,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Invoice FA1302-0022 validated\nAuthor: admin',157,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(221,'221',NULL,1,'2016-03-02 17:24:28','2016-03-02 17:24:28',40,'AC_BILL_VALIDATE','Invoice FA1303-0020 validated','2016-03-02 17:24:28','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Invoice FA1303-0020 validated\nAuthor: admin',211,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(222,'222',NULL,1,'2016-03-05 10:00:00','2016-03-05 10:00:00',5,NULL,'RDV John','2016-03-02 19:54:48','2021-04-15 10:22:55',1,1,NULL,NULL,NULL,0,1,0,NULL,0,0,-1,NULL,NULL,NULL,'gfdgdfgdf',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(223,'223',NULL,1,'2016-03-13 10:00:00','2016-03-17 00:00:00',50,NULL,'Congress','2016-03-02 19:55:11','2021-04-15 10:22:55',1,NULL,NULL,NULL,NULL,0,1,0,NULL,0,0,-1,'',309600,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(224,'224',NULL,1,'2016-03-14 10:00:00',NULL,1,NULL,'Call john','2016-03-02 19:55:56','2021-04-15 10:22:55',1,NULL,NULL,NULL,NULL,0,1,0,NULL,0,0,0,'',NULL,NULL,'tttt',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(225,'225',NULL,1,'2016-03-02 20:11:31','2016-03-02 20:11:31',40,'AC_BILL_UNVALIDATE','Invoice FA1303-0020 go back to draft status','2016-03-02 20:11:31','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Invoice FA1303-0020 go back to draft status\nAuthor: admin',211,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(226,'226',NULL,1,'2016-03-02 20:13:39','2016-03-02 20:13:39',40,'AC_BILL_VALIDATE','Invoice FA1303-0020 validated','2016-03-02 20:13:39','2021-04-15 10:22:55',1,NULL,NULL,19,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Invoice FA1303-0020 validated\nAuthor: admin',211,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(227,'227',NULL,1,'2016-03-03 19:20:10','2016-03-03 19:20:10',40,'AC_BILL_VALIDATE','Invoice FA1212-0023 validated','2016-03-03 19:20:10','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Invoice FA1212-0023 validated\nAuthor: admin',33,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(228,'228',NULL,1,'2016-03-03 19:20:25','2016-03-03 19:20:25',40,'AC_BILL_CANCEL','Invoice FA1212-0023 canceled in Dolibarr','2016-03-03 19:20:25','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Invoice FA1212-0023 canceled in Dolibarr\nAuthor: admin',33,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(229,'229',NULL,1,'2016-03-03 19:20:56','2016-03-03 19:20:56',40,'AC_BILL_VALIDATE','Invoice AV1403-0003 validated','2016-03-03 19:20:56','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Invoice AV1403-0003 validated\nAuthor: admin',212,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(230,'230',NULL,1,'2016-03-03 19:21:29','2016-03-03 19:21:29',40,'AC_BILL_UNVALIDATE','Invoice AV1403-0003 go back to draft status','2016-03-03 19:21:29','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Invoice AV1403-0003 go back to draft status\nAuthor: admin',212,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(231,'231',NULL,1,'2016-03-03 19:22:16','2016-03-03 19:22:16',40,'AC_BILL_VALIDATE','Invoice AV1303-0003 validated','2016-03-03 19:22:16','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,0,1,0,0,-1,'',NULL,NULL,'Invoice AV1303-0003 validated\nAuthor: admin',213,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(232,'232',NULL,1,'2018-01-22 18:54:39','2018-01-22 18:54:39',40,'AC_OTH_AUTO','Invoice 16 validated','2018-01-22 18:54:39','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Invoice 16 validated\nAuthor: admin',16,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(233,'233',NULL,1,'2018-01-22 18:54:46','2018-01-22 18:54:46',40,'AC_OTH_AUTO','Invoice 16 validated','2018-01-22 18:54:46','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Invoice 16 validated\nAuthor: admin',16,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(234,'234',NULL,1,'2018-07-05 10:00:00','2018-07-05 11:19:00',5,'AC_RDV','Meeting with my boss','2018-07-31 18:19:48','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,1,NULL,0,0,-1,'',4740,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(235,'235',NULL,1,'2018-07-13 00:00:00','2018-07-14 23:59:59',50,'AC_OTH','Trip at Las Vegas','2018-07-31 18:20:36','2021-04-15 10:22:55',12,NULL,4,NULL,2,0,12,1,NULL,0,1,-1,'',172799,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(236,'236',NULL,1,'2018-07-29 10:00:00',NULL,4,'AC_EMAIL','Remind to send an email','2018-07-31 18:21:04','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,4,0,NULL,0,0,-1,'',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(237,'237',NULL,1,'2018-07-01 10:00:00',NULL,1,'AC_TEL','Phone call with Mr Vaalen','2018-07-31 18:22:04','2021-04-15 10:22:55',12,NULL,6,4,NULL,0,13,0,NULL,0,0,-1,'',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(238,'238',NULL,1,'2018-08-02 10:00:00','2018-08-02 12:00:00',5,'AC_RDV','Meeting on radium','2018-08-01 01:15:50','2021-04-15 10:22:55',12,NULL,8,10,10,0,12,1,NULL,0,0,-1,'',7200,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(239,'239',NULL,1,'2017-01-29 21:49:33','2017-01-29 21:49:33',40,'AC_OTH_AUTO','Proposal PR1302-0007 validated','2017-01-29 21:49:33','2021-04-15 10:22:55',12,NULL,NULL,19,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1302-0007 validated\nAuthor: admin',7,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(240,'240',NULL,1,'2017-01-31 20:52:00',NULL,1,'AC_TEL','Call the boss','2017-01-31 20:52:10','2021-04-15 10:22:55',12,12,6,NULL,NULL,0,12,1,NULL,0,0,-1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(242,'242',NULL,1,'2017-02-01 18:52:04','2017-02-01 18:52:04',40,'AC_OTH_AUTO','Order CF1007-0001 validated','2017-02-01 18:52:04','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CF1007-0001 validated\nAuthor: admin',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(243,'243',NULL,1,'2017-02-01 18:52:04','2017-02-01 18:52:04',40,'AC_OTH_AUTO','Order CF1007-0001 approved','2017-02-01 18:52:04','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CF1007-0001 approved\nAuthor: admin',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(245,'245',NULL,1,'2017-02-01 18:52:32','2017-02-01 18:52:32',40,'AC_OTH_AUTO','Supplier order CF1007-0001 submited','2017-02-01 18:52:32','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Supplier order CF1007-0001 submited\nAuthor: admin',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(249,'249',NULL,1,'2017-02-01 18:54:01','2017-02-01 18:54:01',40,'AC_OTH_AUTO','Supplier order CF1007-0001 received','2017-02-01 18:54:01','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Supplier order CF1007-0001 received \nAuthor: admin',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(250,'250',NULL,1,'2017-02-01 18:54:42','2017-02-01 18:54:42',40,'AC_OTH_AUTO','Email sent by MyBigCompany To mycustomer@example.com','2017-02-01 18:54:42','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Sender: MyBigCompany <myemail@mybigcompany.com>
\nReceiver(s): mycustomer@example.com
\nEMail topic: Submission of order CF1007-0001
\nEmail body:
\nYou will find here our order CF1007-0001
\r\n
\r\nSincerely
\n
\nAttached files and documents: CF1007-0001.pdf',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(251,'251',NULL,1,'2017-02-01 19:02:21','2017-02-01 19:02:21',40,'AC_OTH_AUTO','Invoice SI1702-0001 validated','2017-02-01 19:02:21','2021-04-15 10:22:55',12,NULL,5,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Invoice SI1702-0001 validated\nAuthor: admin',20,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(252,'252',NULL,1,'2017-02-12 23:17:04','2017-02-12 23:17:04',40,'AC_OTH_AUTO','Patient créé','2017-02-12 23:17:04','2021-04-15 10:22:55',12,NULL,NULL,26,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Patient créé\nAuthor: admin',26,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(253,'253',NULL,1,'2017-02-12 23:18:33','2017-02-12 23:18:33',40,'AC_OTH_AUTO','Consultation 2 recorded (aaa)','2017-02-12 23:18:33','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Consultation 2 recorded (aaa)\nAuthor: admin',2,'cabinetmed_cons',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(254,'254',NULL,1,'2017-02-15 23:28:41','2017-02-15 23:28:41',40,'AC_OTH_AUTO','Order CO7001-0005 validated','2017-02-15 23:28:41','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0005 validated\nAuthor: admin',7,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(255,'255',NULL,1,'2017-02-15 23:28:56','2017-02-15 23:28:56',40,'AC_OTH_AUTO','Order CO7001-0006 validated','2017-02-15 23:28:56','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0006 validated\nAuthor: admin',8,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(256,'256',NULL,1,'2017-02-15 23:34:33','2017-02-15 23:34:33',40,'AC_OTH_AUTO','Order CO7001-0007 validated','2017-02-15 23:34:33','2021-04-15 10:22:55',12,NULL,NULL,3,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0007 validated\nAuthor: admin',9,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(257,'257',NULL,1,'2017-02-15 23:35:03','2017-02-15 23:35:03',40,'AC_OTH_AUTO','Order CO7001-0008 validated','2017-02-15 23:35:03','2021-04-15 10:22:55',12,NULL,NULL,3,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0008 validated\nAuthor: admin',10,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(263,'263',NULL,1,'2017-02-15 23:50:34','2017-02-15 23:50:34',40,'AC_OTH_AUTO','Order CO7001-0005 validated','2017-02-15 23:50:34','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0005 validated\nAuthor: admin',17,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(264,'264',NULL,1,'2017-02-15 23:51:23','2017-02-15 23:51:23',40,'AC_OTH_AUTO','Order CO7001-0006 validated','2017-02-15 23:51:23','2021-04-15 10:22:55',12,NULL,NULL,7,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0006 validated\nAuthor: admin',18,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(265,'265',NULL,1,'2017-02-15 23:54:51','2017-02-15 23:54:51',40,'AC_OTH_AUTO','Order CO7001-0007 validated','2017-02-15 23:54:51','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0007 validated\nAuthor: admin',19,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(266,'266',NULL,1,'2017-02-15 23:55:52','2017-02-15 23:55:52',40,'AC_OTH_AUTO','Order CO7001-0007 validated','2017-02-15 23:55:52','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0007 validated\nAuthor: admin',20,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(267,'267',NULL,1,'2017-02-16 00:03:44','2017-02-16 00:03:44',40,'AC_OTH_AUTO','Order CO7001-0008 validated','2017-02-16 00:03:44','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0008 validated\nAuthor: admin',29,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(268,'268',NULL,1,'2017-02-16 00:05:01','2017-02-16 00:05:01',40,'AC_OTH_AUTO','Order CO7001-0009 validated','2017-02-16 00:05:01','2021-04-15 10:22:55',12,NULL,NULL,11,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0009 validated\nAuthor: admin',34,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(269,'269',NULL,1,'2017-02-16 00:05:01','2017-02-16 00:05:01',40,'AC_OTH_AUTO','Order CO7001-0010 validated','2017-02-16 00:05:01','2021-04-15 10:22:55',12,NULL,NULL,3,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0010 validated\nAuthor: admin',38,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(270,'270',NULL,1,'2017-02-16 00:05:11','2017-02-16 00:05:11',40,'AC_OTH_AUTO','Order CO7001-0011 validated','2017-02-16 00:05:11','2021-04-15 10:22:55',12,NULL,NULL,11,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0011 validated\nAuthor: admin',40,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(271,'271',NULL,1,'2017-02-16 00:05:11','2017-02-16 00:05:11',40,'AC_OTH_AUTO','Order CO7001-0012 validated','2017-02-16 00:05:11','2021-04-15 10:22:55',12,NULL,NULL,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0012 validated\nAuthor: admin',43,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(272,'272',NULL,1,'2017-02-16 00:05:11','2017-02-16 00:05:11',40,'AC_OTH_AUTO','Order CO7001-0013 validated','2017-02-16 00:05:11','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0013 validated\nAuthor: admin',47,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(273,'273',NULL,1,'2017-02-16 00:05:11','2017-02-16 00:05:11',40,'AC_OTH_AUTO','Order CO7001-0014 validated','2017-02-16 00:05:11','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0014 validated\nAuthor: admin',48,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(274,'274',NULL,1,'2017-02-16 00:05:26','2017-02-16 00:05:26',40,'AC_OTH_AUTO','Order CO7001-0015 validated','2017-02-16 00:05:26','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0015 validated\nAuthor: admin',50,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(275,'275',NULL,1,'2017-02-16 00:05:26','2017-02-16 00:05:26',40,'AC_OTH_AUTO','Order CO7001-0016 validated','2017-02-16 00:05:26','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0016 validated\nAuthor: admin',54,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(277,'277',NULL,1,'2017-02-16 00:05:35','2017-02-16 00:05:35',40,'AC_OTH_AUTO','Order CO7001-0018 validated','2017-02-16 00:05:35','2021-04-15 10:22:55',12,NULL,NULL,19,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0018 validated\nAuthor: admin',62,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(278,'278',NULL,1,'2017-02-16 00:05:35','2017-02-16 00:05:35',40,'AC_OTH_AUTO','Order CO7001-0019 validated','2017-02-16 00:05:35','2021-04-15 10:22:55',12,NULL,NULL,3,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0019 validated\nAuthor: admin',68,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(279,'279',NULL,1,'2017-02-16 00:05:36','2017-02-16 00:05:36',40,'AC_OTH_AUTO','Order CO7001-0020 validated','2017-02-16 00:05:36','2021-04-15 10:22:55',12,NULL,NULL,6,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0020 validated\nAuthor: admin',72,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(281,'281',NULL,1,'2017-02-16 00:05:37','2017-02-16 00:05:37',40,'AC_OTH_AUTO','Order CO7001-0022 validated','2017-02-16 00:05:37','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0022 validated\nAuthor: admin',78,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(282,'282',NULL,1,'2017-02-16 00:05:38','2017-02-16 00:05:38',40,'AC_OTH_AUTO','Order CO7001-0023 validated','2017-02-16 00:05:38','2021-04-15 10:22:55',12,NULL,NULL,11,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0023 validated\nAuthor: admin',81,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(283,'283',NULL,1,'2017-02-16 00:05:38','2017-02-16 00:05:38',40,'AC_OTH_AUTO','Order CO7001-0024 validated','2017-02-16 00:05:38','2021-04-15 10:22:55',12,NULL,NULL,26,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0024 validated\nAuthor: admin',83,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(284,'284',NULL,1,'2017-02-16 00:05:38','2017-02-16 00:05:38',40,'AC_OTH_AUTO','Order CO7001-0025 validated','2017-02-16 00:05:38','2021-04-15 10:22:55',12,NULL,NULL,2,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0025 validated\nAuthor: admin',84,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(285,'285',NULL,1,'2017-02-16 00:05:38','2017-02-16 00:05:38',40,'AC_OTH_AUTO','Order CO7001-0026 validated','2017-02-16 00:05:38','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0026 validated\nAuthor: admin',85,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(286,'286',NULL,1,'2017-02-16 00:05:38','2017-02-16 00:05:38',40,'AC_OTH_AUTO','Order CO7001-0027 validated','2017-02-16 00:05:38','2021-04-15 10:22:55',12,NULL,NULL,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Order CO7001-0027 validated\nAuthor: admin',88,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(287,'287',NULL,1,'2017-02-16 03:05:56','2017-02-16 03:05:56',40,'AC_OTH_AUTO','Commande CO7001-0016 classée Livrée','2017-02-16 03:05:56','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Commande CO7001-0016 classée Livrée\nAuteur: admin',54,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(288,'288',NULL,1,'2017-02-16 03:06:01','2017-02-16 03:06:01',40,'AC_OTH_AUTO','Commande CO7001-0016 classée Facturée','2017-02-16 03:06:01','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Commande CO7001-0016 classée Facturée\nAuteur: admin',54,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(294,'294',NULL,1,'2017-02-16 03:53:04','2017-02-16 03:53:04',40,'AC_OTH_AUTO','Commande CO7001-0021 validée','2017-02-16 03:53:04','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Commande CO7001-0021 validée\nAuteur: admin',75,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(295,'295',NULL,1,'2017-02-16 03:58:08','2017-02-16 03:58:08',40,'AC_OTH_AUTO','Expédition SH1702-0002 validée','2017-02-16 03:58:08','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Expédition SH1702-0002 validée\nAuteur: admin',3,'shipping',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(296,'296',NULL,1,'2017-02-16 04:12:29','2017-02-16 04:12:29',40,'AC_OTH_AUTO','Commande CO7001-0021 validée','2017-02-16 04:12:29','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Commande CO7001-0021 validée\nAuteur: admin',75,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(297,'297',NULL,1,'2017-02-16 04:14:20','2017-02-16 04:14:20',40,'AC_OTH_AUTO','Commande CO7001-0021 validée','2017-02-16 04:14:20','2021-04-15 10:22:55',12,NULL,NULL,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Commande CO7001-0021 validée\nAuteur: admin',75,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(298,'298',NULL,1,'2017-02-16 01:44:58','2017-02-16 01:44:58',40,'AC_OTH_AUTO','Proposal PR1702-0009 validated','2017-02-16 01:44:58','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0009 validated\nAuthor: aeinstein',11,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(299,'299',NULL,1,'2017-02-16 01:45:44','2017-02-16 01:45:44',40,'AC_OTH_AUTO','Proposal PR1702-0010 validated','2017-02-16 01:45:44','2021-04-15 10:22:55',2,NULL,NULL,7,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0010 validated\nAuthor: demo',12,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(300,'300',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0011 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',1,NULL,NULL,26,NULL,0,1,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0011 validated\nAuthor: aeinstein',13,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(301,'301',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0012 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',2,NULL,NULL,3,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0012 validated\nAuthor: demo',14,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(302,'302',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0013 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',2,NULL,NULL,26,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0013 validated\nAuthor: demo',15,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(303,'303',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0014 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',2,NULL,NULL,1,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0014 validated\nAuthor: demo',16,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(304,'304',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0015 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0015 validated\nAuthor: aeinstein',17,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(305,'305',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0016 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',2,NULL,NULL,26,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0016 validated\nAuthor: demo',18,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(306,'306',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0017 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',2,NULL,NULL,12,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0017 validated\nAuthor: demo',19,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(307,'307',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0018 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',1,NULL,NULL,26,NULL,0,1,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0018 validated\nAuthor: aeinstein',20,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(308,'308',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0019 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',1,NULL,NULL,1,NULL,0,1,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0019 validated\nAuthor: aeinstein',21,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(309,'309',NULL,1,'2017-02-16 01:46:15','2017-02-16 01:46:15',40,'AC_OTH_AUTO','Proposal PR1702-0020 validated','2017-02-16 01:46:15','2021-04-15 10:22:55',1,NULL,NULL,26,NULL,0,1,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0020 validated\nAuthor: aeinstein',22,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(310,'310',NULL,1,'2017-02-16 01:46:17','2017-02-16 01:46:17',40,'AC_OTH_AUTO','Proposal PR1702-0021 validated','2017-02-16 01:46:17','2021-04-15 10:22:55',2,NULL,NULL,12,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0021 validated\nAuthor: demo',23,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(311,'311',NULL,1,'2017-02-16 01:46:17','2017-02-16 01:46:17',40,'AC_OTH_AUTO','Proposal PR1702-0022 validated','2017-02-16 01:46:17','2021-04-15 10:22:55',2,NULL,NULL,7,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0022 validated\nAuthor: demo',24,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(312,'312',NULL,1,'2017-02-16 01:46:17','2017-02-16 01:46:17',40,'AC_OTH_AUTO','Proposal PR1702-0023 validated','2017-02-16 01:46:17','2021-04-15 10:22:55',1,NULL,NULL,3,NULL,0,1,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0023 validated\nAuthor: aeinstein',25,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(313,'313',NULL,1,'2017-02-16 01:46:18','2017-02-16 01:46:18',40,'AC_OTH_AUTO','Proposal PR1702-0024 validated','2017-02-16 01:46:18','2021-04-15 10:22:55',2,NULL,NULL,1,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0024 validated\nAuthor: demo',26,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(314,'314',NULL,1,'2017-02-16 01:46:18','2017-02-16 01:46:18',40,'AC_OTH_AUTO','Proposal PR1702-0025 validated','2017-02-16 01:46:18','2021-04-15 10:22:55',1,NULL,NULL,6,NULL,0,1,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0025 validated\nAuthor: aeinstein',27,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(315,'315',NULL,1,'2017-02-16 01:46:18','2017-02-16 01:46:18',40,'AC_OTH_AUTO','Proposal PR1702-0026 validated','2017-02-16 01:46:18','2021-04-15 10:22:55',2,NULL,NULL,19,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0026 validated\nAuthor: demo',28,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(316,'316',NULL,1,'2017-02-16 01:46:18','2017-02-16 01:46:18',40,'AC_OTH_AUTO','Proposal PR1702-0027 validated','2017-02-16 01:46:18','2021-04-15 10:22:55',2,NULL,NULL,1,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0027 validated\nAuthor: demo',29,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(317,'317',NULL,1,'2017-02-16 01:46:18','2017-02-16 01:46:18',40,'AC_OTH_AUTO','Proposal PR1702-0028 validated','2017-02-16 01:46:18','2021-04-15 10:22:55',2,NULL,NULL,1,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0028 validated\nAuthor: demo',30,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(318,'318',NULL,1,'2017-02-16 01:46:18','2017-02-16 01:46:18',40,'AC_OTH_AUTO','Proposal PR1702-0029 validated','2017-02-16 01:46:18','2021-04-15 10:22:55',1,NULL,NULL,11,NULL,0,1,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0029 validated\nAuthor: aeinstein',31,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(319,'319',NULL,1,'2017-02-16 01:46:18','2017-02-16 01:46:18',40,'AC_OTH_AUTO','Proposal PR1702-0030 validated','2017-02-16 01:46:18','2021-04-15 10:22:55',2,NULL,NULL,19,NULL,0,2,0,NULL,0,0,-1,'',NULL,NULL,'Proposal PR1702-0030 validated\nAuthor: demo',32,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(320,'320',NULL,1,'2017-02-16 04:46:31','2017-02-16 04:46:31',40,'AC_OTH_AUTO','Proposition PR1702-0026 signée','2017-02-16 04:46:31','2021-04-15 10:22:55',12,NULL,NULL,19,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Proposition PR1702-0026 signée\nAuteur: admin',28,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(321,'321',NULL,1,'2017-02-16 04:46:37','2017-02-16 04:46:37',40,'AC_OTH_AUTO','Proposition PR1702-0027 signée','2017-02-16 04:46:37','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Proposition PR1702-0027 signée\nAuteur: admin',29,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(322,'322',NULL,1,'2017-02-16 04:46:42','2017-02-16 04:46:42',40,'AC_OTH_AUTO','Proposition PR1702-0028 refusée','2017-02-16 04:46:42','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Proposition PR1702-0028 refusée\nAuteur: admin',30,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(323,'323',NULL,1,'2017-02-16 04:47:09','2017-02-16 04:47:09',40,'AC_OTH_AUTO','Proposition PR1702-0019 validée','2017-02-16 04:47:09','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Proposition PR1702-0019 validée\nAuteur: admin',21,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(324,'324',NULL,1,'2017-02-16 04:47:25','2017-02-16 04:47:25',40,'AC_OTH_AUTO','Proposition PR1702-0023 signée','2017-02-16 04:47:25','2021-04-15 10:22:55',12,NULL,NULL,3,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Proposition PR1702-0023 signée\nAuteur: admin',25,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(325,'325',NULL,1,'2017-02-16 04:47:29','2017-02-16 04:47:29',40,'AC_OTH_AUTO','Proposition PR1702-0023 classée payée','2017-02-16 04:47:29','2021-04-15 10:22:55',12,NULL,NULL,3,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Proposition PR1702-0023 classée payée\nAuteur: admin',25,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(326,'326',NULL,1,'2017-02-17 16:07:18','2017-02-17 16:07:18',40,'AC_OTH_AUTO','Proposition PR1702-0021 validée','2017-02-17 16:07:18','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Proposition PR1702-0021 validée\nAuteur: admin',23,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(327,'327',NULL,1,'2017-05-12 13:53:44','2017-05-12 13:53:44',40,'AC_OTH_AUTO','Email sent by MyBigCompany To Einstein','2017-05-12 13:53:44','2021-04-15 10:22:55',12,NULL,NULL,11,12,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Sender: MyBigCompany <myemail@mybigcompany.com>
\nReceiver(s): Einstein <genius@example.com>
\nBcc: Einstein <genius@example.com>
\nEMail topic: Test
\nEmail body:
\nTest\nAuthor: admin',11,'societe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(328,'328',NULL,1,'2017-08-29 22:39:09','2017-08-29 22:39:09',40,'AC_OTH_AUTO','Invoice FA1601-0024 validated','2017-08-29 22:39:09','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Invoice FA1601-0024 validated\nAuthor: admin',149,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(329,'329',NULL,1,'2019-09-26 13:38:11','2019-09-26 13:38:11',40,'AC_MEMBER_MODIFY','Member Pierre Curie modified','2019-09-26 13:38:11','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember Pierre Curie modified\nMember: Pierre Curie\nType: Standard members',2,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(330,'330',NULL,1,'2019-09-26 13:49:21','2019-09-26 13:49:21',40,'AC_MEMBER_MODIFY','Member Pierre Curie modified','2019-09-26 13:49:21','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember Pierre Curie modified\nMember: Pierre Curie\nType: Standard members',2,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(331,'331',NULL,1,'2019-09-26 17:33:37','2019-09-26 17:33:37',40,'AC_BILL_VALIDATE','Invoice FA1909-0025 validated','2019-09-26 17:33:37','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1909-0025 validated',218,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(333,'333',NULL,1,'2019-09-27 16:54:30','2019-09-27 16:54:30',40,'AC_PROPAL_VALIDATE','Proposal PR1909-0031 validated','2019-09-27 16:54:30','2021-04-15 10:22:55',12,NULL,4,7,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR1909-0031 validated',10,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(335,'335',NULL,1,'2019-09-27 17:08:59','2019-09-27 17:08:59',40,'AC_PROPAL_VALIDATE','Proposal PR1909-0032 validated','2019-09-27 17:08:59','2021-04-15 10:22:55',12,NULL,6,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR1909-0032 validated',33,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(337,'337',NULL,1,'2019-09-27 17:13:13','2019-09-27 17:13:13',40,'AC_PROPAL_VALIDATE','Proposal PR1909-0033 validated','2019-09-27 17:13:13','2021-04-15 10:22:55',12,NULL,6,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR1909-0033 validated',34,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(338,'338',NULL,1,'2019-09-27 17:53:31','2019-09-27 17:53:31',40,'AC_PRODUCT_MODIFY','Product ROLLUPABC modified','2019-09-27 17:53:31','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ROLLUPABC modified',11,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(339,'339',NULL,1,'2019-09-27 18:15:00','2019-09-27 18:15:00',40,'AC_PRODUCT_MODIFY','Product ROLLUPABC modified','2019-09-27 18:15:00','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ROLLUPABC modified',11,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(340,'340',NULL,1,'2019-09-27 18:40:32','2019-09-27 18:40:32',40,'AC_PRODUCT_MODIFY','Product ROLLUPABC modified','2019-09-27 18:40:32','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ROLLUPABC modified',11,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(341,'341',NULL,1,'2019-09-27 19:16:07','2019-09-27 19:16:07',40,'AC_PRODUCT_CREATE','Product ppp created','2019-09-27 19:16:07','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ppp created',14,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(342,'342',NULL,1,'2019-09-27 19:18:01','2019-09-27 19:18:01',40,'AC_PRODUCT_MODIFY','Product ppp modified','2019-09-27 19:18:01','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ppp modified',14,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(343,'343',NULL,1,'2019-09-27 19:31:45','2019-09-27 19:31:45',40,'AC_PRODUCT_MODIFY','Product ROLLUPABC modified','2019-09-27 19:31:45','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ROLLUPABC modified',11,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(344,'344',NULL,1,'2019-09-27 19:32:12','2019-09-27 19:32:12',40,'AC_PRODUCT_MODIFY','Product ROLLUPABC modified','2019-09-27 19:32:12','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ROLLUPABC modified',11,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(345,'345',NULL,1,'2019-09-27 19:38:30','2019-09-27 19:38:30',40,'AC_PRODUCT_MODIFY','Product ROLLUPABC modified','2019-09-27 19:38:30','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ROLLUPABC modified',11,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(346,'346',NULL,1,'2019-09-27 19:38:37','2019-09-27 19:38:37',40,'AC_PRODUCT_MODIFY','Product ROLLUPABC modified','2019-09-27 19:38:37','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ROLLUPABC modified',11,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(347,'347',NULL,1,'2019-09-30 15:49:52',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #15ff11cay39skiaa] New message','2019-09-30 15:49:52','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'dfsdfds',2,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(348,'348',NULL,1,'2019-10-01 13:48:36','2019-10-01 13:48:36',40,'AC_PROJECT_MODIFY','Project PJ1607-0001 modified','2019-10-01 13:48:36','2021-04-15 10:22:55',12,NULL,6,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1607-0001 modified\nTask: PJ1607-0001',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(349,'349',NULL,1,'2019-10-04 10:10:25','2019-10-04 10:10:25',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SI1601-0002 validated','2019-10-04 10:10:25','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI1601-0002 validated',17,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(350,'350',NULL,1,'2019-10-04 10:10:47','2019-10-04 10:10:47',40,'AC_BILL_SUPPLIER_PAYED','Invoice SI1601-0002 changed to paid','2019-10-04 10:10:47','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI1601-0002 changed to paid',17,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(351,'351',NULL,1,'2019-10-04 10:26:49','2019-10-04 10:26:49',40,'AC_BILL_UNVALIDATE','Invoice FA6801-0010 go back to draft status','2019-10-04 10:26:49','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA6801-0010 go back to draft status',150,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(352,'352',NULL,1,'2019-10-04 10:27:00','2019-10-04 10:27:00',40,'AC_BILL_VALIDATE','Invoice FA6801-0010 validated','2019-10-04 10:27:00','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA6801-0010 validated',150,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(353,'353',NULL,1,'2019-10-04 10:28:14','2019-10-04 10:28:14',40,'AC_BILL_PAYED','Invoice FA6801-0010 changed to paid','2019-10-04 10:28:14','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA6801-0010 changed to paid',150,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(354,'354',NULL,1,'2019-10-04 10:29:22','2019-10-04 10:29:22',40,'AC_BILL_SUPPLIER_PAYED','Invoice SI1601-0002 changed to paid','2019-10-04 10:29:22','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI1601-0002 changed to paid',17,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(355,'355',NULL,1,'2019-10-04 10:29:41','2019-10-04 10:29:41',40,'AC_BILL_SUPPLIER_UNVALIDATE','Invoice SI1601-0002 go back to draft status','2019-10-04 10:29:41','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI1601-0002 go back to draft status',17,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(356,'356',NULL,1,'2019-10-04 10:31:30','2019-10-04 10:31:30',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SI1601-0002 validated','2019-10-04 10:31:30','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI1601-0002 validated',17,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(357,'357',NULL,1,'2019-10-04 16:56:21',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 16:56:21','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'aaaa',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(358,'358',NULL,1,'2019-10-04 17:08:04',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:08:04','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'ddddd',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(359,'359',NULL,1,'2019-10-04 17:25:05',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:25:05','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'aaa',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(360,'360',NULL,1,'2019-10-04 17:26:14',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:26:14','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'aaa',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(361,'361',NULL,1,'2019-10-04 17:30:10',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:30:10','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(362,'362',NULL,1,'2019-10-04 17:51:43',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:51:43','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(363,'363',NULL,1,'2019-10-04 17:52:02',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:52:02','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(364,'364',NULL,1,'2019-10-04 17:52:17',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:52:17','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(365,'365',NULL,1,'2019-10-04 17:52:39',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:52:39','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(366,'366',NULL,1,'2019-10-04 17:52:53',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:52:53','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(367,'367',NULL,1,'2019-10-04 17:53:13',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:53:13','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(368,'368',NULL,1,'2019-10-04 17:53:26',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:53:26','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(369,'369',NULL,1,'2019-10-04 17:53:48',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:53:48','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(370,'370',NULL,1,'2019-10-04 17:54:09',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:54:09','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(371,'371',NULL,1,'2019-10-04 17:54:28',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:54:28','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(372,'372',NULL,1,'2019-10-04 17:55:43',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:55:43','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(373,'373',NULL,1,'2019-10-04 17:56:01',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 17:56:01','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(374,'374',NULL,1,'2019-10-04 18:00:32',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 18:00:32','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(375,'375',NULL,1,'2019-10-04 18:00:58',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 18:00:58','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(376,'376',NULL,1,'2019-10-04 18:11:30',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 18:11:30','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fdsfs',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(377,'377',NULL,1,'2019-10-04 18:12:02',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 18:12:02','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fffffff',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(378,'378',NULL,1,'2019-10-04 18:49:30',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 18:49:30','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'aaa',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(379,'379',NULL,1,'2019-10-04 19:00:22',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 19:00:22','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'fff',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(380,'380',NULL,1,'2019-10-04 19:24:20','2019-10-04 19:24:20',40,'AC_PROPAL_SENTBYMAIL','Email sent by Alice Adminson To NLTechno','2019-10-04 19:24:20','2021-04-15 10:22:55',12,NULL,6,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nSender: Alice Adminson <aadminson@example.com>
\nReceiver(s): NLTechno <notanemail@nltechno.com>
\nEmail topic: Envoi de la proposition commerciale PR1909-0032
\nEmail body:
\nHello
\r\n
\r\nVeuillez trouver, ci-joint, la proposition commerciale PR1909-0032
\r\n
\r\n
\r\nSincerely
\r\n
\r\nAlice - 123
\n
\nAttached files and documents: PR1909-0032.pdf',33,'propal',NULL,'Envoi de la proposition commerciale PR1909-0032','Alice Adminson ',NULL,'NLTechno ',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(381,'381',NULL,1,'2019-10-04 19:30:13',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 19:30:13','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(382,'382',NULL,1,'2019-10-04 19:32:55',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 19:32:55','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'uuuuuu\n\nAttached files and documents: Array',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(383,'383',NULL,1,'2019-10-04 19:37:16',NULL,50,'TICKET_MSG','','2019-10-04 19:37:16','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,100,'',NULL,NULL,'f\n\nFichiers et documents joints: dolihelp.ico',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(384,'384',NULL,1,'2019-10-04 19:39:07',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #9d85cko5qmmo7qxs] New message','2019-10-04 19:39:07','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'aaafff\n\nAttached files and documents: dolibarr.gif;doliadmin.ico',5,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(385,'385',NULL,1,'2019-10-07 12:17:07','2019-10-07 12:17:07',40,'AC_PRODUCT_DELETE','Product PREF123456 deleted','2019-10-07 12:17:07','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PREF123456 deleted',17,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(386,'386',NULL,1,'2019-10-07 12:17:32','2019-10-07 12:17:32',40,'AC_PRODUCT_DELETE','Product PREF123456 deleted','2019-10-07 12:17:32','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PREF123456 deleted',18,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(387,'387',NULL,1,'2019-10-08 19:21:07','2019-10-08 19:21:07',40,'AC_PRODUCT_MODIFY','Product ROLLUPABC modified','2019-10-08 19:21:07','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ROLLUPABC modified',11,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(388,'388',NULL,1,'2019-10-08 21:01:07','2019-10-08 21:01:07',40,'AC_MEMBER_MODIFY','Member Pierre Curie modified','2019-10-08 21:01:07','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember Pierre Curie modified\nMember: Pierre Curie\nType: Standard members',2,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(389,'389',NULL,1,'2019-10-08 21:01:22','2019-10-08 21:01:22',40,'AC_MEMBER_MODIFY','Member doe john modified','2019-10-08 21:01:22','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember doe john modified\nMember: doe john\nType: Standard members',3,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(390,'390',NULL,1,'2019-10-08 21:01:45','2019-10-08 21:01:45',40,'AC_MEMBER_MODIFY','Member smith smith modified','2019-10-08 21:01:45','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember smith smith modified\nMember: smith smith\nType: Standard members',4,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(391,'391',NULL,1,'2019-10-08 21:02:18','2019-10-08 21:02:18',40,'AC_MEMBER_MODIFY','Member Vick Smith modified','2019-10-08 21:02:18','2021-04-15 10:22:55',12,NULL,NULL,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember Vick Smith modified\nMember: Vick Smith\nType: Standard members',1,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(392,'392',NULL,1,'2019-11-28 15:54:46','2019-11-28 15:54:46',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SI1911-0005 validated','2019-11-28 15:54:47','2021-04-15 10:22:55',12,NULL,NULL,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI1911-0005 validated',21,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(393,'393',NULL,1,'2019-11-28 16:33:35','2019-11-28 16:33:35',40,'AC_PRODUCT_CREATE','Product FR-CAR created','2019-11-28 16:33:35','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct FR-CAR created',24,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(394,'394',NULL,1,'2019-11-28 16:34:08','2019-11-28 16:34:08',40,'AC_PRODUCT_DELETE','Product ppp deleted','2019-11-28 16:34:08','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct ppp deleted',14,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(395,'395',NULL,1,'2019-11-28 16:34:33','2019-11-28 16:34:33',40,'AC_PRODUCT_MODIFY','Product FR-CAR modified','2019-11-28 16:34:33','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct FR-CAR modified',24,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(396,'396',NULL,1,'2019-11-28 16:34:46','2019-11-28 16:34:46',40,'AC_PRODUCT_MODIFY','Product FR-CAR modified','2019-11-28 16:34:46','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct FR-CAR modified',24,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(397,'397',NULL,1,'2019-11-28 16:36:56','2019-11-28 16:36:56',40,'AC_PRODUCT_MODIFY','Product POS-CAR modified','2019-11-28 16:36:56','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-CAR modified',24,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(398,'398',NULL,1,'2019-11-28 16:37:36','2019-11-28 16:37:36',40,'AC_PRODUCT_CREATE','Product POS-APPLE created','2019-11-28 16:37:36','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-APPLE created',25,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(399,'399',NULL,1,'2019-11-28 16:37:58','2019-11-28 16:37:58',40,'AC_PRODUCT_MODIFY','Product POS-APPLE modified','2019-11-28 16:37:58','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-APPLE modified',25,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(400,'400',NULL,1,'2019-11-28 16:38:44','2019-11-28 16:38:44',40,'AC_PRODUCT_CREATE','Product POS-KIWI created','2019-11-28 16:38:44','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-KIWI created',26,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(401,'401',NULL,1,'2019-11-28 16:39:21','2019-11-28 16:39:21',40,'AC_PRODUCT_CREATE','Product POS-PEACH created','2019-11-28 16:39:21','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-PEACH created',27,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(402,'402',NULL,1,'2019-11-28 16:39:58','2019-11-28 16:39:58',40,'AC_PRODUCT_CREATE','Product POS-ORANGE created','2019-11-28 16:39:58','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-ORANGE created',28,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(403,'403',NULL,1,'2019-11-28 17:00:28','2019-11-28 17:00:28',40,'AC_PRODUCT_MODIFY','Product APPLEPIE modified','2019-11-28 17:00:28','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct APPLEPIE modified',4,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(404,'404',NULL,1,'2019-11-28 17:00:46','2019-11-28 17:00:46',40,'AC_PRODUCT_MODIFY','Product PEARPIE modified','2019-11-28 17:00:46','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PEARPIE modified',2,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(405,'405',NULL,1,'2019-11-28 17:01:57','2019-11-28 17:01:57',40,'AC_PRODUCT_MODIFY','Product POS-APPLE modified','2019-11-28 17:01:57','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-APPLE modified',25,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(406,'406',NULL,1,'2019-11-28 17:03:14','2019-11-28 17:03:14',40,'AC_PRODUCT_CREATE','Product POS-Eggs created','2019-11-28 17:03:14','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-Eggs created',29,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(407,'407',NULL,1,'2019-11-28 17:04:17','2019-11-28 17:04:17',40,'AC_PRODUCT_MODIFY','Product POS-Eggs modified','2019-11-28 17:04:17','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-Eggs modified',29,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(408,'408',NULL,1,'2019-11-28 17:09:14','2019-11-28 17:09:14',40,'AC_PRODUCT_CREATE','Product POS-Chips created','2019-11-28 17:09:14','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-Chips created',30,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(409,'409',NULL,1,'2019-11-28 17:09:54','2019-11-28 17:09:54',40,'AC_PRODUCT_MODIFY','Product POS-Chips modified','2019-11-28 17:09:54','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-Chips modified',30,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(410,'410',NULL,1,'2019-11-28 18:46:20','2019-11-28 18:46:20',40,'AC_PRODUCT_MODIFY','Product POS-APPLE modified','2019-11-28 18:46:20','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-APPLE modified',25,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(411,'411',NULL,1,'2019-11-28 18:59:29','2019-11-28 18:59:29',40,'AC_PRODUCT_MODIFY','Product PEARPIE modified','2019-11-28 18:59:29','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PEARPIE modified',2,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(412,'412',NULL,1,'2019-11-28 19:02:01','2019-11-28 19:02:01',40,'AC_PRODUCT_MODIFY','Product POS-CARROT modified','2019-11-28 19:02:01','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct POS-CARROT modified',24,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(413,'413',NULL,1,'2019-11-28 19:09:50','2019-11-28 19:09:50',40,'AC_PRODUCT_MODIFY','Product PEARPIE modified','2019-11-28 19:09:50','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PEARPIE modified',2,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(414,'414',NULL,1,'2019-11-28 19:12:50','2019-11-28 19:12:50',40,'AC_PRODUCT_MODIFY','Product PEARPIE modified','2019-11-28 19:12:50','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PEARPIE modified',2,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(415,'415',NULL,1,'2019-11-29 12:46:29','2019-11-29 12:46:29',40,'AC_TICKET_CREATE','Ticket TS1911-0004 created','2019-11-29 12:46:29','2021-04-15 10:22:55',12,NULL,4,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nTicket TS1911-0004 created',6,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(416,'416',NULL,1,'2019-11-29 12:46:34','2019-11-29 12:46:34',40,'AC_TICKET_MODIFY','Ticket TS1911-0004 read by Alice Adminson','2019-11-29 12:46:34','2021-04-15 10:22:55',12,NULL,4,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nTicket TS1911-0004 read by Alice Adminson',6,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(417,'417',NULL,1,'2019-11-29 12:46:47','2019-11-29 12:46:47',40,'AC_TICKET_ASSIGNED','Ticket TS1911-0004 assigned','2019-11-29 12:46:47','2021-04-15 10:22:55',12,NULL,4,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nTicket TS1911-0004 assigned\nOld user: None\nNew user: Commerson Charle1',6,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(418,'418',NULL,1,'2019-11-29 12:47:13',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #5gvo9bsjri55zef9] New message','2019-11-29 12:47:13','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'Where do you want to install Dolibarr ?
\r\nOn-Premise or on the Cloud ?',6,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(419,'419',NULL,1,'2019-11-29 12:50:45','2019-11-29 12:50:45',40,'AC_TICKET_CREATE','Ticket TS1911-0005 créé','2019-11-29 12:50:45','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,-1,'',NULL,NULL,'Auteur: \nTicket TS1911-0005 créé',7,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(420,'420',NULL,1,'2019-11-29 12:52:32','2019-11-29 12:52:32',40,'AC_TICKET_MODIFY','Ticket TS1911-0005 read by Alice Adminson','2019-11-29 12:52:32','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nTicket TS1911-0005 read by Alice Adminson',7,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(421,'421',NULL,1,'2019-11-29 12:52:53','2019-11-29 12:52:53',40,'AC_TICKET_ASSIGNED','Ticket TS1911-0005 assigned','2019-11-29 12:52:53','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nTicket TS1911-0005 assigned\nOld user: None\nNew user: Commerson Charle1',7,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(422,'422',NULL,1,'2019-11-29 12:54:04',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #d51wjy4nym7wltg7] New message','2019-11-29 12:54:04','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'Hi.
\r\nThanks for your interest in using Dolibarr ERP CRM.
\r\nI need more information to give you the correct answer : Where do you want to install Dolibarr. On premise or on Cloud',7,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(423,'423',NULL,1,'2019-11-29 12:54:46',NULL,50,'TICKET_MSG','','2019-11-29 12:54:46','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,100,'',NULL,NULL,'I need it On-Premise.',7,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(424,'424',NULL,1,'2019-11-29 12:55:42',NULL,50,'TICKET_MSG','[MyBigCompany - ticket #d51wjy4nym7wltg7] New message','2019-11-29 12:55:42','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,100,'',NULL,NULL,'When used on-premise, you can download and install Dolibarr yourself from ou web portal: https://www.dolibarr.org
\r\nIt is completely free.',7,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(425,'425',NULL,1,'2019-11-29 12:55:48','2019-11-29 12:55:48',40,'AC_TICKET_CLOSE','Ticket TS1911-0005 closed','2019-11-29 12:55:48','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nTicket TS1911-0005 closed',7,'ticket',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(426,'426',NULL,1,'2019-11-29 12:56:47','2019-11-29 12:56:47',40,'AC_BOM_UNVALIDATE','BOM unvalidated','2019-11-29 12:56:47','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM unvalidated',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(427,'427',NULL,1,'2019-11-29 12:57:14','2019-11-29 12:57:14',40,'AC_BOM_VALIDATE','BOM validated','2019-11-29 12:57:14','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM validated',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(428,'428',NULL,1,'2019-12-20 16:40:14','2019-12-20 16:40:14',40,'AC_MO_DELETE','MO deleted','2019-12-20 16:40:14','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO deleted',3,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(429,'429',NULL,1,'2019-12-20 17:00:43','2019-12-20 17:00:43',40,'AC_MO_DELETE','MO deleted','2019-12-20 17:00:43','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO deleted',7,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(430,'430',NULL,1,'2019-12-20 17:00:56','2019-12-20 17:00:56',40,'AC_MO_DELETE','MO deleted','2019-12-20 17:00:56','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO deleted',6,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(431,'431',NULL,1,'2019-12-20 20:00:03','2019-12-20 20:00:03',40,'AC_MO_DELETE','MO deleted','2019-12-20 20:00:03','2021-04-15 10:22:55',12,NULL,6,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO deleted',1,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(432,'432',NULL,1,'2019-12-20 20:22:11','2019-12-20 20:22:11',40,'AC_MO_DELETE','MO deleted','2019-12-20 20:22:11','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO deleted',10,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(433,'433',NULL,1,'2019-12-20 20:22:11','2019-12-20 20:22:11',40,'AC_MO_DELETE','MO deleted','2019-12-20 20:22:11','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO deleted',12,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(434,'434',NULL,1,'2019-12-20 20:22:20','2019-12-20 20:22:20',40,'AC_MO_DELETE','MO deleted','2019-12-20 20:22:20','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO deleted',9,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(435,'435',NULL,1,'2019-12-20 20:27:07','2019-12-20 20:27:07',40,'AC_MO_DELETE','MO deleted','2019-12-20 20:27:07','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO deleted',13,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(436,'436',NULL,1,'2019-12-20 20:42:42','2019-12-20 20:42:42',40,'AC_ORDER_VALIDATE','Order CO7001-0027 validated','2019-12-20 20:42:42','2021-04-15 10:22:55',12,NULL,NULL,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nOrder CO7001-0027 validated',88,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(437,'437',NULL,1,'2019-12-20 20:46:25','2019-12-20 20:46:25',40,'AC_ORDER_SUPPLIER_RECEIVE','Purchase Order CF1007-0001 received','2019-12-20 20:46:25','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nPurchase Order CF1007-0001 received ',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(438,'438',NULL,1,'2019-12-20 20:46:45','2019-12-20 20:46:45',40,'AC_ORDER_SUPPLIER_CLASSIFY_BILLED','Purchase Order CF1007-0001 set billed','2019-12-20 20:46:45','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nPurchase Order CF1007-0001 set billed',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(439,'439',NULL,1,'2019-12-20 20:47:02','2019-12-20 20:47:02',40,'AC_ORDER_SUPPLIER_RECEIVE','Purchase Order CF1007-0001 received','2019-12-20 20:47:02','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nPurchase Order CF1007-0001 received ',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(440,'440',NULL,1,'2019-12-20 20:47:44','2019-12-20 20:47:44',40,'AC_ORDER_SUPPLIER_RECEIVE','Purchase Order CF1007-0001 received','2019-12-20 20:47:44','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nPurchase Order CF1007-0001 received ',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(441,'441',NULL,1,'2019-12-20 20:47:53','2019-12-20 20:47:53',40,'AC_ORDER_SUPPLIER_RECEIVE','Purchase Order CF1007-0001 received','2019-12-20 20:47:53','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nPurchase Order CF1007-0001 received ',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(442,'442',NULL,1,'2019-12-20 20:48:05','2019-12-20 20:48:05',40,'AC_ORDER_SUPPLIER_RECEIVE','Purchase Order CF1007-0001 received','2019-12-20 20:48:05','2021-04-15 10:22:55',12,NULL,NULL,13,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nPurchase Order CF1007-0001 received ',1,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(443,'443',NULL,1,'2019-12-20 20:48:45','2019-12-20 20:48:45',40,'AC_ORDER_CLASSIFY_BILLED','Order CO7001-0016 classified billed','2019-12-20 20:48:45','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nOrder CO7001-0016 classified billed',54,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(444,'444',NULL,1,'2019-12-20 20:48:55','2019-12-20 20:48:55',40,'AC_ORDER_CLOSE','Order CO7001-0018 classified delivered','2019-12-20 20:48:55','2021-04-15 10:22:55',12,NULL,NULL,19,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nOrder CO7001-0018 classified delivered',62,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(445,'445',NULL,1,'2019-12-20 20:49:43','2019-12-20 20:49:43',40,'AC_PROPAL_CLASSIFY_BILLED','Proposal PR1702-0027 classified billed','2019-12-20 20:49:43','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR1702-0027 classified billed',29,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(446,'446',NULL,1,'2019-12-20 20:49:54','2019-12-20 20:49:54',40,'AC_PROPAL_CLOSE_SIGNED','Proposal PR1702-0027 signed','2019-12-20 20:49:54','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR1702-0027 signed',29,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(447,'447',NULL,1,'2019-12-20 20:50:14','2019-12-20 20:50:14',40,'AC_PROPAL_CLOSE_REFUSED','Proposal PR1702-0027 refused','2019-12-20 20:50:14','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR1702-0027 refused',29,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(448,'448',NULL,1,'2019-12-20 20:50:23','2019-12-20 20:50:23',40,'AC_PROPAL_CLOSE_SIGNED','Proposal PR1702-0027 signed','2019-12-20 20:50:23','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR1702-0027 signed',29,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(449,'449',NULL,1,'2019-12-21 17:18:22','2019-12-21 17:18:22',40,'AC_BOM_CLOSE','BOM disabled','2019-12-21 17:18:22','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM disabled',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(450,'450',NULL,1,'2019-12-21 17:18:38','2019-12-21 17:18:38',40,'AC_MEMBER_RESILIATE','Member Vick Smith terminated','2019-12-21 17:18:38','2021-04-15 10:22:55',12,NULL,NULL,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember Vick Smith terminated\nMember: Vick Smith\nType: Standard members',1,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(451,'451',NULL,1,'2019-12-21 19:46:33','2019-12-21 19:46:33',40,'AC_PROJECT_CREATE','Project PJ1912-0005 created','2019-12-21 19:46:33','2021-04-15 10:22:55',12,NULL,10,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0005 created\nProject: PJ1912-0005',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(452,'452',NULL,1,'2019-12-21 19:47:03','2019-12-21 19:47:03',40,'AC_PROJECT_MODIFY','Project PJ1912-0005 modified','2019-12-21 19:47:03','2021-04-15 10:22:55',12,NULL,10,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0005 modified\nTask: PJ1912-0005',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(453,'453',NULL,1,'2019-12-21 19:47:24','2019-12-21 19:47:24',40,'AC_PROJECT_MODIFY','Project PJ1912-0005 modified','2019-12-21 19:47:24','2021-04-15 10:22:55',12,NULL,10,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0005 modified\nTask: PJ1912-0005',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(454,'454',NULL,1,'2019-12-21 19:47:52','2019-12-21 19:47:52',40,'AC_PROJECT_MODIFY','Project PJ1912-0005 modified','2019-12-21 19:47:52','2021-04-15 10:22:55',12,NULL,10,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0005 modified\nTask: PJ1912-0005',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(455,'455',NULL,1,'2019-12-21 19:48:06','2019-12-21 19:48:06',40,'AC_PROJECT_MODIFY','Project PJ1912-0005 modified','2019-12-21 19:48:06','2021-04-15 10:22:55',12,NULL,10,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0005 modified\nTask: PJ1912-0005',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(456,'456',NULL,1,'2019-12-21 19:49:28','2019-12-21 19:49:28',40,'AC_PROJECT_CREATE','Project PJ1912-0006 created','2019-12-21 19:49:28','2021-04-15 10:22:55',12,NULL,11,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0006 created\nProject: PJ1912-0006',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(457,'457',NULL,1,'2019-12-21 19:52:12','2019-12-21 19:52:12',40,'AC_PROJECT_CREATE','Project PJ1912-0007 created','2019-12-21 19:52:12','2021-04-15 10:22:55',12,NULL,12,4,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0007 created\nProject: PJ1912-0007',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(458,'458',NULL,1,'2019-12-21 19:53:21','2019-12-21 19:53:21',40,'AC_PROJECT_CREATE','Project PJ1912-0008 created','2019-12-21 19:53:21','2021-04-15 10:22:55',12,NULL,13,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0008 created\nProject: PJ1912-0008',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(459,'459',NULL,1,'2019-12-21 19:53:42','2019-12-21 19:53:42',40,'AC_PROJECT_MODIFY','Project PJ1912-0008 modified','2019-12-21 19:53:42','2021-04-15 10:22:55',12,NULL,13,26,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0008 modified\nTask: PJ1912-0008',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(460,'460',NULL,1,'2019-12-21 19:55:23','2019-12-21 19:55:23',40,'AC_PROJECT_MODIFY','Project PJ1912-0006 modified','2019-12-21 19:55:23','2021-04-15 10:22:55',12,NULL,11,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0006 modified\nTask: PJ1912-0006',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(461,'461',NULL,1,'2019-12-21 20:10:21','2019-12-21 20:10:21',40,'AC_PROJECT_MODIFY','Project PJ1912-0006 modified','2019-12-21 20:10:21','2021-04-15 10:22:55',12,NULL,11,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PJ1912-0006 modified\nTask: PJ1912-0006',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(462,'462',NULL,1,'2019-12-11 10:00:00','2019-12-11 10:00:00',5,'AC_RDV','Meeting with all employees','2019-12-21 20:29:32','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,1,NULL,0,0,-1,'',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(463,'463',NULL,1,'2019-12-06 00:00:00',NULL,11,'AC_INT','Intervention on customer site','2019-12-21 20:30:11','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,1,NULL,0,1,-1,'',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(464,'464',NULL,1,'2019-12-23 14:16:59','2019-12-23 14:16:59',40,'AC_BILL_PAYED','Invoice FA1601-0024 changed to paid','2019-12-23 14:16:59','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1601-0024 changed to paid',149,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(465,'465',NULL,1,'2019-12-23 14:17:18','2019-12-23 14:17:18',40,'AC_BILL_PAYED','Invoice FA1601-0024 changed to paid','2019-12-23 14:17:18','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1601-0024 changed to paid',149,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(466,'466',NULL,1,'2019-11-23 14:25:00',NULL,50,'AC_OTH','Test','2019-12-23 17:25:14','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,1,NULL,0,0,-1,'',NULL,NULL,'18/11 17h06 : Message laissé. Me rappeler pour m'en dire plus. 
\r\n
\r\n20/11 10h17 "A rappeler suite au msg laissé le 14/11, dit que c'est urgent"
\r\n12h22 : message laissé. Je lui envoie un sms
\r\n
\r\n"Déclaration de sinistre originale" : constat de ce qui s'est passé.
\r\nElle envoie le chèque de solde dès demain.
\r\n
\r\n3/12 : Elle préfère avoir plus d'infos sur le sinistre pour l'assurance.
\r\nCourrier envoyé le 4/12/19 par mail et par courrier postal
\r\n
\r\n6/12 15h02 : ont obtenu le feu vert de l'assurance.
\r\nOn bloque 16/12 PM à partir de 14h30. ',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(467,'467',NULL,1,'2020-01-01 14:35:47','2020-01-01 14:35:47',40,'AC_MEMBER_VALIDATE','Adhérent aze aze validé','2020-01-01 14:35:47','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,-1,'',NULL,NULL,'Auteur: \nAdhérent aze aze validé\nAdhérent: aze aze\nType: Board members',5,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(468,'468',NULL,1,'2020-01-01 14:50:59','2020-01-01 14:50:59',40,'AC_MEMBER_VALIDATE','Adhérent azr azr validé','2020-01-01 14:50:59','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,-1,'',NULL,NULL,'Auteur: \nAdhérent azr azr validé\nAdhérent: azr azr\nType: Board members',6,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(469,'469',NULL,1,'2020-01-01 15:00:16','2020-01-01 15:00:16',40,'AC_MEMBER_VALIDATE','Adhérent azt azt validé','2020-01-01 15:00:16','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,-1,'',NULL,NULL,'Auteur: \nAdhérent azt azt validé\nAdhérent: azt azt\nType: Board members',7,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(470,'470',NULL,1,'2020-01-01 15:08:20','2020-01-01 15:08:20',40,'AC_MEMBER_VALIDATE','Adhérent azu azu validé','2020-01-01 15:08:20','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,-1,'',NULL,NULL,'Auteur: \nAdhérent azu azu validé\nAdhérent: azu azu\nType: Board members',8,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(471,'471',NULL,1,'2020-01-01 15:27:24','2020-01-01 15:27:24',40,'AC_MEMBER_VALIDATE','Adhérent azi azi validé','2020-01-01 15:27:24','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,-1,'',NULL,NULL,'Auteur: \nAdhérent azi azi validé\nAdhérent: azi azi\nType: Board members',9,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(472,'472',NULL,1,'2020-01-01 15:36:29','2020-01-01 15:36:29',40,'AC_MEMBER_VALIDATE','Adhérent azo azo validé','2020-01-01 15:36:29','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,-1,'',NULL,NULL,'Auteur: \nAdhérent azo azo validé\nAdhérent: azo azo\nType: Board members',10,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(473,'473',NULL,1,'2020-01-01 15:44:25','2020-01-01 15:44:25',40,'AC_MEMBER_VALIDATE','Adhérent azp azp validé','2020-01-01 15:44:25','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,-1,'',NULL,NULL,'Auteur: \nAdhérent azp azp validé\nAdhérent: azp azp\nType: Board members',11,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(478,'478',NULL,1,'2020-01-01 16:52:32','2020-01-01 16:52:32',40,'AC_MEMBER_VALIDATE','Adhérent azq azq validé','2020-01-01 16:52:32','2021-04-15 10:22:55',NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0,-1,'',NULL,NULL,'Auteur: \nAdhérent azq azq validé\nAdhérent: azq azq\nType: Board members',12,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(483,'483',NULL,1,'2020-01-01 17:49:05','2020-01-01 17:49:05',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SI2001-0006 validated','2020-01-01 17:49:05','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0006 validated',22,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(484,'484',NULL,1,'2020-01-01 17:50:41','2020-01-01 17:50:41',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SA2001-0001 validated','2020-01-01 17:50:41','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 validated',23,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(485,'485',NULL,1,'2020-01-01 17:50:44','2020-01-01 17:50:44',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0001 changed to paid','2020-01-01 17:50:44','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 changed to paid',23,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(486,'486',NULL,1,'2020-01-01 17:51:22','2020-01-01 17:51:22',40,'AC_BILL_SUPPLIER_UNVALIDATE','Invoice SI2001-0006 go back to draft status','2020-01-01 17:51:22','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0006 go back to draft status',22,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(487,'487',NULL,1,'2020-01-01 20:17:00','2020-01-01 20:17:00',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SI2001-0006 validated','2020-01-01 20:17:00','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0006 validated',22,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(488,'488',NULL,1,'2020-01-01 20:17:46','2020-01-01 20:17:46',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SA2001-0001 validated','2020-01-01 20:17:46','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 validated',24,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(489,'489',NULL,1,'2020-01-01 20:17:51','2020-01-01 20:17:51',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0001 changed to paid','2020-01-01 20:17:51','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 changed to paid',24,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(490,'490',NULL,1,'2020-01-01 20:20:22','2020-01-01 20:20:22',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SA2001-0001 validated','2020-01-01 20:20:22','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 validated',26,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(491,'491',NULL,1,'2020-01-01 20:20:31','2020-01-01 20:20:31',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0001 changed to paid','2020-01-01 20:20:31','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 changed to paid',26,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(492,'492',NULL,1,'2020-01-01 20:21:35','2020-01-01 20:21:35',40,'AC_BILL_SUPPLIER_UNVALIDATE','Invoice SI2001-0006 go back to draft status','2020-01-01 20:21:35','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0006 go back to draft status',22,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(493,'493',NULL,1,'2020-01-01 20:21:42','2020-01-01 20:21:42',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SI2001-0006 validated','2020-01-01 20:21:42','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0006 validated',22,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(494,'494',NULL,1,'2020-01-01 20:21:55','2020-01-01 20:21:55',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SA2001-0001 validated','2020-01-01 20:21:55','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 validated',27,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(495,'495',NULL,1,'2020-01-01 20:23:02','2020-01-01 20:23:02',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SI2001-0007 validated','2020-01-01 20:23:02','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0007 validated',28,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(496,'496',NULL,1,'2020-01-01 20:23:17','2020-01-01 20:23:17',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0001 changed to paid','2020-01-01 20:23:17','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 changed to paid',27,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(497,'497',NULL,1,'2020-01-01 20:25:36','2020-01-01 20:25:36',40,'AC_BILL_SUPPLIER_PAYED','Invoice SI2001-0007 changed to paid','2020-01-01 20:25:36','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0007 changed to paid',28,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(498,'498',NULL,1,'2020-01-01 20:51:37','2020-01-01 20:51:37',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SA2001-0002 validated','2020-01-01 20:51:37','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0002 validated',30,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(499,'499',NULL,1,'2020-01-01 20:51:48','2020-01-01 20:51:48',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0002 changed to paid','2020-01-01 20:51:48','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0002 changed to paid',30,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(500,'500',NULL,1,'2020-01-01 21:02:39','2020-01-01 21:02:39',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0001 changed to paid','2020-01-01 21:02:39','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 changed to paid',27,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(501,'501',NULL,1,'2020-01-01 21:03:01','2020-01-01 21:03:01',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0001 changed to paid','2020-01-01 21:03:01','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 changed to paid',27,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(502,'502',NULL,1,'2020-01-01 21:11:10','2020-01-01 21:11:10',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0001 changed to paid','2020-01-01 21:11:10','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 changed to paid',27,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(503,'503',NULL,1,'2020-01-01 21:20:07','2020-01-01 21:20:07',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0001 changed to paid','2020-01-01 21:20:07','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 changed to paid',27,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(504,'504',NULL,1,'2020-01-01 21:21:28','2020-01-01 21:21:28',40,'AC_BILL_SUPPLIER_PAYED','Invoice SI2001-0007 changed to paid','2020-01-01 21:21:28','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0007 changed to paid',28,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(505,'505',NULL,1,'2020-01-01 22:06:30','2020-01-01 22:06:30',40,'AC_BILL_SUPPLIER_PAYED','Invoice SA2001-0001 changed to paid','2020-01-01 22:06:31','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SA2001-0001 changed to paid',27,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(506,'506',NULL,1,'2020-01-01 23:54:16','2020-01-01 23:54:16',40,'AC_PRODUCT_MODIFY','Product APPLEPIE modified','2020-01-01 23:54:16','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct APPLEPIE modified',4,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(507,'507',NULL,1,'2020-01-02 20:49:34','2020-01-02 20:49:34',40,'AC_BILL_PAYED','Invoice FA1601-0024 changed to paid','2020-01-02 20:49:34','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1601-0024 changed to paid',149,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(508,'508',NULL,1,'2020-01-02 23:02:35','2020-01-02 23:02:35',40,'AC_PRODUCT_MODIFY','Product APPLEPIE modified','2020-01-02 23:02:35','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct APPLEPIE modified',4,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(509,'509',NULL,1,'2020-01-02 23:45:01','2020-01-02 23:45:01',40,'AC_BOM_REOPEN','BOM reopen','2020-01-02 23:45:01','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM reopen',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(511,'511',NULL,1,'2020-01-02 23:57:42','2020-01-02 23:57:42',40,'AC_MRP_MO_VALIDATE','MO validated','2020-01-02 23:57:42','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO validated',14,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(512,'512',NULL,1,'2020-01-03 13:33:54','2020-01-03 13:33:54',40,'AC_BOM_UNVALIDATE','BOM unvalidated','2020-01-03 13:33:54','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM unvalidated',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(513,'513',NULL,1,'2020-01-03 13:34:11','2020-01-03 13:34:11',40,'AC_BOM_VALIDATE','BOM validated','2020-01-03 13:34:11','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM validated',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(514,'514',NULL,1,'2020-01-03 13:35:45','2020-01-03 13:35:45',40,'AC_MRP_MO_VALIDATE','MO validated','2020-01-03 13:35:45','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO validated',18,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(515,'515',NULL,1,'2020-01-03 14:10:41','2020-01-03 14:10:41',40,'AC_MRP_MO_VALIDATE','MO validated','2020-01-03 14:10:41','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO validated',18,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(516,'516',NULL,1,'2020-01-06 00:39:58','2020-01-06 00:39:58',40,'AC_COMPANY_CREATE','Patient créé','2020-01-06 00:39:58','2021-04-15 10:22:55',12,NULL,NULL,29,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nPatient créé',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(517,'517',NULL,1,'2020-01-06 00:49:06','2020-01-06 00:49:06',40,'AC_BILL_SUPPLIER_UNVALIDATE','Invoice SI2001-0006 go back to draft status','2020-01-06 00:49:06','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0006 go back to draft status',22,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(518,'518',NULL,1,'2020-01-06 06:50:05','2020-01-06 06:50:05',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-06 06:50:05','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',14,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(519,'519',NULL,1,'2020-01-06 20:52:28','2020-01-06 20:52:28',40,'AC_OTH_AUTO','Consultation 2 recorded (Patient)','2020-01-06 20:52:28','2021-04-15 10:22:55',12,NULL,NULL,29,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Consultation 2 recorded (Patient)\nAuthor: admin',2,'cabinetmed_cons',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(520,'520',NULL,1,'2020-01-07 20:25:02','2020-01-07 20:25:02',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 20:25:02','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(521,'521',NULL,1,'2020-01-07 21:12:37','2020-01-07 21:12:37',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 21:12:37','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(522,'522',NULL,1,'2020-01-07 21:13:00','2020-01-07 21:13:00',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 21:13:00','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(523,'523',NULL,1,'2020-01-07 21:13:49','2020-01-07 21:13:49',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 21:13:49','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(524,'524',NULL,1,'2020-01-07 21:46:58','2020-01-07 21:46:58',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 21:46:58','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(525,'525',NULL,1,'2020-01-07 21:52:34','2020-01-07 21:52:34',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 21:52:34','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(526,'526',NULL,1,'2020-01-07 21:53:44','2020-01-07 21:53:44',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 21:53:44','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(527,'527',NULL,1,'2020-01-07 21:53:58','2020-01-07 21:53:58',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 21:53:58','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(528,'528',NULL,1,'2020-01-07 21:54:12','2020-01-07 21:54:12',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 21:54:12','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(529,'529',NULL,1,'2020-01-07 22:00:55','2020-01-07 22:00:55',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 22:00:55','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(530,'530',NULL,1,'2020-01-07 22:39:52','2020-01-07 22:39:52',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 22:39:52','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',14,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(531,'531',NULL,1,'2020-01-07 23:09:04','2020-01-07 23:09:04',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 23:09:04','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',14,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(532,'532',NULL,1,'2020-01-07 23:39:09','2020-01-07 23:39:09',40,'AC_PROPAL_CLOSE_SIGNED','Proposal PR1909-0033 signed','2020-01-07 23:39:09','2021-04-15 10:22:55',12,NULL,6,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR1909-0033 signed',34,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(533,'533',NULL,1,'2020-01-07 23:43:06','2020-01-07 23:43:06',40,'AC_PROPAL_CLOSE_SIGNED','Proposal PR1909-0033 signed','2020-01-07 23:43:06','2021-04-15 10:22:55',12,NULL,6,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR1909-0033 signed',34,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(534,'534',NULL,1,'2020-01-07 23:50:40','2020-01-07 23:50:40',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 23:50:40','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(535,'535',NULL,1,'2020-01-07 23:51:27','2020-01-07 23:51:27',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-07 23:51:27','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(536,'536',NULL,1,'2020-01-08 00:25:23','2020-01-08 00:25:23',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 00:25:23','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(537,'537',NULL,1,'2020-01-08 00:25:43','2020-01-08 00:25:43',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 00:25:43','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(538,'538',NULL,1,'2020-01-08 00:29:24','2020-01-08 00:29:24',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 00:29:24','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(539,'539',NULL,1,'2020-01-08 00:29:43','2020-01-08 00:29:43',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 00:29:43','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(540,'540',NULL,1,'2020-01-08 01:09:15','2020-01-08 01:09:15',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 01:09:15','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(541,'541',NULL,1,'2020-01-08 01:15:02','2020-01-08 01:15:02',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 01:15:02','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(542,'542',NULL,1,'2020-01-08 01:17:16','2020-01-08 01:17:16',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 01:17:16','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(543,'543',NULL,1,'2020-01-08 05:31:44','2020-01-08 05:31:44',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 05:31:44','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(544,'544',NULL,1,'2020-01-08 05:39:46','2020-01-08 05:39:46',40,'AC_BOM_CLOSE','BOM disabled','2020-01-08 05:39:46','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM disabled',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(545,'545',NULL,1,'2020-01-08 05:39:50','2020-01-08 05:39:50',40,'AC_BOM_REOPEN','BOM reopen','2020-01-08 05:39:50','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM reopen',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(546,'546',NULL,1,'2020-01-08 06:06:50','2020-01-08 06:06:50',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 06:06:50','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',14,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(547,'547',NULL,1,'2020-01-08 19:34:53','2020-01-08 19:34:53',40,'AC_BOM_UNVALIDATE','BOM unvalidated','2020-01-08 19:34:53','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM unvalidated',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(548,'548',NULL,1,'2020-01-08 19:40:27','2020-01-08 19:40:27',40,'AC_PRODUCT_MODIFY','Product APPLEPIE modified','2020-01-08 19:40:27','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct APPLEPIE modified',4,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(549,'549',NULL,1,'2020-01-08 19:40:46','2020-01-08 19:40:46',40,'AC_PRODUCT_MODIFY','Product PINKDRESS modified','2020-01-08 19:40:46','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PINKDRESS modified',1,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(550,'550',NULL,1,'2020-01-08 19:40:59','2020-01-08 19:40:59',40,'AC_BOM_VALIDATE','BOM validated','2020-01-08 19:40:59','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM validated',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(551,'551',NULL,1,'2020-01-08 19:41:11','2020-01-08 19:41:11',40,'AC_BOM_UNVALIDATE','BOM unvalidated','2020-01-08 19:41:11','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM unvalidated',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(552,'552',NULL,1,'2020-01-08 19:41:49','2020-01-08 19:41:49',40,'AC_BOM_VALIDATE','BOM validated','2020-01-08 19:41:49','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM validated',6,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(553,'553',NULL,1,'2020-01-08 20:12:55','2020-01-08 20:12:55',40,'AC_MRP_MO_VALIDATE','MO validated','2020-01-08 20:12:55','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO validated',28,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(554,'554',NULL,1,'2020-01-08 20:21:22','2020-01-08 20:21:22',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 20:21:22','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',28,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(555,'555',NULL,1,'2020-01-08 20:41:19','2020-01-08 20:41:19',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-08 20:41:19','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',28,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(556,'556',NULL,1,'2020-01-08 22:25:19','2020-01-08 22:25:19',40,'AC_BOM_DELETE','BOM deleted','2020-01-08 22:25:19','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM deleted',7,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(557,'557',NULL,1,'2020-01-13 15:11:07','2020-01-13 15:11:07',40,'AC_MO_DELETE','MO_DELETEInDolibarr','2020-01-13 15:11:07','2021-04-15 10:22:55',12,NULL,6,26,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO_DELETEInDolibarr',25,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(558,'558',NULL,1,'2020-01-13 15:11:54','2020-01-13 15:11:54',40,'AC_MRP_MO_VALIDATE','MO validated','2020-01-13 15:11:54','2021-04-15 10:22:55',12,NULL,6,26,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO validated',24,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(559,'559',NULL,1,'2020-01-13 15:13:19','2020-01-13 15:13:19',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-13 15:13:19','2021-04-15 10:22:55',12,NULL,6,26,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',24,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(560,'560',NULL,1,'2020-01-13 15:14:15','2020-01-13 15:14:15',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-13 15:14:15','2021-04-15 10:22:55',12,NULL,6,26,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',24,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(561,'561',NULL,1,'2020-01-13 15:29:30','2020-01-13 15:29:30',40,'AC_MRP_MO_PRODUCED','MO produced','2020-01-13 15:29:30','2021-04-15 10:22:55',12,NULL,7,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMO produced',5,'mo',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(562,'562',NULL,1,'2020-01-13 17:19:24','2020-01-13 17:19:24',40,'AC_COMPANY_CREATE','Third party Italo created','2020-01-13 17:19:24','2021-04-15 10:22:55',12,NULL,NULL,30,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nThird party Italo created',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(563,'563',NULL,1,'2020-01-15 16:27:15','2020-01-15 16:27:15',40,'AC_PROJECT_MODIFY','Project RMLL modified','2020-01-15 16:27:15','2021-04-15 10:22:55',12,NULL,5,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject RMLL modified\nTask: RMLL',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(564,'564',NULL,1,'2020-01-15 16:40:50','2020-01-15 16:40:50',40,'AC_PROJECT_MODIFY','Project PROJINDIAN modified','2020-01-15 16:40:50','2021-04-15 10:22:55',12,NULL,3,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProject PROJINDIAN modified\nTask: PROJINDIAN',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(565,'565',NULL,1,'2020-01-16 02:22:16','2020-01-16 02:22:16',40,'AC_BILL_VALIDATE','Invoice AC2001-0001 validated','2020-01-16 02:22:16','2021-04-15 10:22:55',12,NULL,NULL,19,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0001 validated',221,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(566,'566',NULL,1,'2020-01-16 02:22:24','2020-01-16 02:22:24',40,'AC_BILL_UNVALIDATE','Invoice AC2001-0001 go back to draft status','2020-01-16 02:22:24','2021-04-15 10:22:55',12,NULL,NULL,19,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0001 go back to draft status',221,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(567,'567',NULL,1,'2020-01-16 02:33:27','2020-01-16 02:33:27',40,'AC_BILL_VALIDATE','Invoice AC2001-0002 validated','2020-01-16 02:33:27','2021-04-15 10:22:55',12,NULL,NULL,19,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0002 validated',224,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(568,'568',NULL,1,'2020-01-16 02:36:48','2020-01-16 02:36:48',40,'AC_BILL_PAYED','Invoice AC2001-0002 changed to paid','2020-01-16 02:36:48','2021-04-15 10:22:55',12,NULL,NULL,19,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0002 changed to paid',224,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(569,'569',NULL,1,'2020-01-16 02:42:12','2020-01-16 02:42:12',40,'AC_ORDER_CLASSIFY_BILLED','Order CO7001-0020 classified billed','2020-01-16 02:42:12','2021-04-15 10:22:55',12,NULL,NULL,6,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nOrder CO7001-0020 classified billed',72,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(570,'570',NULL,1,'2020-01-16 02:42:17','2020-01-16 02:42:17',40,'AC_ORDER_CLOSE','Order CO7001-0020 classified delivered','2020-01-16 02:42:17','2021-04-15 10:22:55',12,NULL,NULL,6,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nOrder CO7001-0020 classified delivered',72,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(571,'571',NULL,1,'2020-01-16 02:42:56','2020-01-16 02:42:56',40,'AC_ORDER_CLOSE','Order CO7001-0020 classified delivered','2020-01-16 02:42:56','2021-04-15 10:22:55',12,NULL,NULL,6,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nOrder CO7001-0020 classified delivered',72,'order',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(572,'572',NULL,1,'2020-01-16 18:05:43','2020-01-16 18:05:43',40,'AC_BILL_SUPPLIER_VALIDATE','Invoice SI2001-0006 validated','2020-01-16 18:05:43','2021-04-15 10:22:55',12,NULL,NULL,17,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice SI2001-0006 validated',22,'invoice_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(573,'573',NULL,1,'2020-01-17 14:54:18','2020-01-17 14:54:18',40,'AC_PRODUCT_MODIFY','Product PINKDRESS modified','2020-01-17 14:54:18','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PINKDRESS modified',1,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(574,'574',NULL,1,'2020-01-17 15:22:28','2020-01-17 15:22:28',40,'AC_PRODUCT_MODIFY','Product PINKDRESS modified','2020-01-17 15:22:28','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PINKDRESS modified',1,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(575,'575',NULL,1,'2020-01-19 14:22:27','2020-01-19 14:22:27',40,'AC_PROPAL_VALIDATE','Proposal PR2001-0034 validated','2020-01-19 14:22:27','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR2001-0034 validated',36,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(576,'576',NULL,1,'2020-01-19 14:22:34','2020-01-19 14:22:34',40,'AC_PROPAL_CLOSE_SIGNED','Proposal PR2001-0034 signed','2020-01-19 14:22:34','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR2001-0034 signed',36,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(577,'577',NULL,1,'2020-01-19 14:24:22','2020-01-19 14:24:22',40,'AC_PROPAL_VALIDATE','Proposal PR2001-0034 validated','2020-01-19 14:24:22','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR2001-0034 validated',36,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(578,'578',NULL,1,'2020-01-19 14:24:27','2020-01-19 14:24:27',40,'AC_PROPAL_CLOSE_SIGNED','Proposal PR2001-0034 signed','2020-01-19 14:24:27','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProposal PR2001-0034 signed',36,'propal',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(579,'579',NULL,1,'2020-01-19 14:51:43','2020-01-19 14:51:43',40,'AC_BILL_VALIDATE','Invoice AC2001-0003 validated','2020-01-19 14:51:43','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0003 validated',227,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(580,'580',NULL,1,'2020-01-19 14:51:48','2020-01-19 14:51:48',40,'AC_BILL_UNVALIDATE','Invoice AC2001-0003 go back to draft status','2020-01-19 14:51:48','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0003 go back to draft status',227,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(581,'581',NULL,1,'2020-01-19 15:01:26','2020-01-19 15:01:26',40,'AC_BILL_VALIDATE','Invoice AC2001-0004 validated','2020-01-19 15:01:26','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0004 validated',228,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(582,'582',NULL,1,'2020-01-19 15:04:37','2020-01-19 15:04:37',40,'AC_BILL_UNVALIDATE','Invoice AC2001-0004 go back to draft status','2020-01-19 15:04:37','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0004 go back to draft status',228,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(583,'583',NULL,1,'2020-01-19 15:04:53','2020-01-19 15:04:53',40,'AC_BILL_VALIDATE','Invoice AC2001-0004 validated','2020-01-19 15:04:53','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0004 validated',228,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(584,'584',NULL,1,'2020-01-19 15:09:14','2020-01-19 15:09:14',40,'AC_BILL_UNVALIDATE','Invoice AC2001-0004 go back to draft status','2020-01-19 15:09:14','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0004 go back to draft status',228,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(585,'585',NULL,1,'2020-01-19 15:13:07','2020-01-19 15:13:07',40,'AC_BILL_VALIDATE','Invoice AC2001-0004 validated','2020-01-19 15:13:07','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice AC2001-0004 validated',228,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(586,'586',NULL,1,'2020-01-20 12:20:11','2020-01-20 12:20:11',40,'AC_ORDER_SUPPLIER_CREATE','Order (PROV14) created','2020-01-20 12:20:11','2021-04-15 10:22:55',12,NULL,NULL,1,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nOrder (PROV14) created',14,'order_supplier',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(588,'588',NULL,1,'2020-01-21 01:02:14','2020-01-21 01:02:14',40,'AC_MEMBER_SUBSCRIPTION_CREATE','Subscription 2 for member Vick Smith added','2020-01-21 01:02:14','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nSubscription 2 for member Vick Smith added\nMember: Vick Smith\nType: 2\nAmount: 50\nPeriod: 07/18/2013 - 07/17/2014',3,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(589,'589',NULL,1,'2020-01-21 10:22:37','2020-01-21 10:22:37',40,'AC_MEMBER_SUBSCRIPTION_CREATE','Subscription 3 for member Vick Smith added','2020-01-21 10:22:37','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nSubscription 3 for member Vick Smith added\nMember: Vick Smith\nType: 2\nAmount: 50\nPeriod: 07/18/2017 - 07/17/2018',4,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(590,'590',NULL,1,'2020-01-21 10:23:17','2020-01-21 10:23:17',40,'AC_MEMBER_SUBSCRIPTION_CREATE','Subscription 4 for member Vick Smith added','2020-01-21 10:23:17','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nSubscription 4 for member Vick Smith added\nMember: Vick Smith\nType: 2\nAmount: 50\nPeriod: 07/18/2017 - 07/17/2018',2,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(591,'591',NULL,1,'2020-01-21 10:23:17','2020-01-21 10:23:17',40,'AC_BILL_VALIDATE','Invoice FA1707-0026 validated','2020-01-21 10:23:17','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1707-0026 validated',229,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(592,'592',NULL,1,'2020-01-21 10:23:17','2020-01-21 10:23:17',40,'AC_BILL_PAYED','Invoice FA1707-0026 changed to paid','2020-01-21 10:23:17','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1707-0026 changed to paid',229,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(593,'593',NULL,1,'2020-01-21 10:23:28','2020-01-21 10:23:28',40,'AC_MEMBER_SUBSCRIPTION_CREATE','Subscription 5 for member Vick Smith added','2020-01-21 10:23:28','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nSubscription 5 for member Vick Smith added\nMember: Vick Smith\nType: 2\nAmount: 50\nPeriod: 07/18/2018 - 07/17/2019',2,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(594,'594',NULL,1,'2020-01-21 10:23:28','2020-01-21 10:23:28',40,'AC_BILL_VALIDATE','Invoice FA1807-0027 validated','2020-01-21 10:23:28','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1807-0027 validated',230,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(595,'595',NULL,1,'2020-01-21 10:23:28','2020-01-21 10:23:28',40,'AC_BILL_PAYED','Invoice FA1807-0027 changed to paid','2020-01-21 10:23:28','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1807-0027 changed to paid',230,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(596,'596',NULL,1,'2020-01-21 10:23:49','2020-01-21 10:23:49',40,'AC_MEMBER_SUBSCRIPTION_CREATE','Subscription 6 for member Vick Smith added','2020-01-21 10:23:49','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nSubscription 6 for member Vick Smith added\nMember: Vick Smith\nType: 2\nAmount: 50\nPeriod: 07/18/2019 - 07/17/2020',2,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(597,'597',NULL,1,'2020-01-21 10:23:49','2020-01-21 10:23:49',40,'AC_BILL_VALIDATE','Invoice FA1907-0028 validated','2020-01-21 10:23:49','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1907-0028 validated',231,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(598,'598',NULL,1,'2020-01-21 10:23:49','2020-01-21 10:23:49',40,'AC_BILL_PAYED','Invoice FA1907-0028 changed to paid','2020-01-21 10:23:49','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nInvoice FA1907-0028 changed to paid',231,'invoice',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(599,'599',NULL,1,'2020-01-21 10:30:27','2020-01-21 10:30:27',40,'AC_MEMBER_MODIFY','Member Pierre Curie modified','2020-01-21 10:30:27','2021-04-15 10:22:55',12,NULL,NULL,12,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember Pierre Curie modified\nMember: Pierre Curie\nType: Standard members',2,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(600,'600',NULL,1,'2020-01-21 10:30:36','2020-01-21 10:30:36',40,'AC_MEMBER_MODIFY','Member doe john modified','2020-01-21 10:30:36','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember doe john modified\nMember: doe john\nType: Standard members',3,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(601,'601',NULL,1,'2020-01-21 10:30:42','2020-01-21 10:30:42',40,'AC_MEMBER_MODIFY','Member smith smith modified','2020-01-21 10:30:42','2021-04-15 10:22:55',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember smith smith modified\nMember: smith smith\nType: Standard members',4,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(602,'602',NULL,1,'2020-01-21 10:30:57','2020-01-21 10:30:57',40,'AC_MEMBER_MODIFY','Member Vick Smith modified','2020-01-21 10:30:57','2021-04-15 10:22:55',12,NULL,NULL,10,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nMember Vick Smith modified\nMember: Vick Smith\nType: Standard members',1,'member',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(603,'603',NULL,1,'2020-06-12 10:00:00','2020-06-12 11:30:00',5,'AC_RDV','Meetings','2020-06-12 19:26:44','2021-04-15 10:22:55',12,NULL,3,NULL,NULL,0,12,1,NULL,0,0,-1,'Room 24',5400,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(604,'604',NULL,1,'2020-06-01 10:00:00','2020-06-01 10:27:00',1,'AC_TEL','Called Mr X','2020-06-12 19:28:13','2021-04-15 10:22:55',12,12,3,NULL,NULL,0,12,1,NULL,0,0,100,NULL,1620,NULL,'Customer ask another call.',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(605,'605',NULL,1,'2020-04-15 05:00:00','2020-04-15 06:00:00',5,'AC_RDV','Meet A2','2021-04-15 07:36:31','2021-04-15 10:36:31',12,NULL,NULL,NULL,NULL,0,12,1,NULL,0,0,0,'',3600,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(606,'606',NULL,1,'2021-04-15 08:38:02','2021-04-15 08:38:02',40,'AC_PRODUCT_CREATE','Product PRODSER created','2021-04-15 08:38:02','2021-04-15 11:38:02',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nProduct PRODSER created',31,'product',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0),(607,'607',NULL,1,'2022-02-07 13:54:11','2022-02-07 13:54:11',40,'AC_BOM_VALIDATE','BOM validated','2022-02-07 13:54:11','2022-02-07 13:54:11',12,NULL,NULL,NULL,NULL,0,12,0,NULL,0,0,-1,'',NULL,NULL,'Author: admin\nBOM validated',7,'bom',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'default',NULL,NULL,0,0); /*!40000 ALTER TABLE `llx_actioncomm` ENABLE KEYS */; UNLOCK TABLES; @@ -453,7 +453,7 @@ CREATE TABLE `llx_actioncomm_resources` ( PRIMARY KEY (`rowid`), UNIQUE KEY `uk_actioncomm_resources` (`fk_actioncomm`,`element_type`,`fk_element`), KEY `idx_actioncomm_resources_fk_element` (`fk_element`) -) ENGINE=InnoDB AUTO_INCREMENT=487 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=488 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -462,7 +462,7 @@ CREATE TABLE `llx_actioncomm_resources` ( LOCK TABLES `llx_actioncomm_resources` WRITE; /*!40000 ALTER TABLE `llx_actioncomm_resources` DISABLE KEYS */; -INSERT INTO `llx_actioncomm_resources` VALUES (1,1,'user',1,NULL,NULL,1),(2,2,'user',1,NULL,NULL,1),(3,3,'user',1,NULL,NULL,1),(4,4,'user',1,NULL,NULL,1),(5,5,'user',1,NULL,NULL,1),(6,6,'user',1,NULL,NULL,1),(7,7,'user',1,NULL,NULL,1),(8,8,'user',1,NULL,NULL,1),(9,9,'user',1,NULL,NULL,1),(10,10,'user',1,NULL,NULL,1),(11,11,'user',1,NULL,NULL,1),(12,12,'user',1,NULL,NULL,1),(13,13,'user',1,NULL,NULL,1),(14,14,'user',1,NULL,NULL,1),(15,15,'user',1,NULL,NULL,1),(16,16,'user',1,NULL,NULL,1),(17,17,'user',1,NULL,NULL,1),(18,18,'user',1,NULL,NULL,1),(19,19,'user',1,NULL,NULL,1),(20,20,'user',1,NULL,NULL,1),(21,21,'user',1,NULL,NULL,1),(22,22,'user',1,NULL,NULL,1),(23,23,'user',1,NULL,NULL,1),(24,24,'user',1,NULL,NULL,1),(25,25,'user',1,NULL,NULL,1),(26,26,'user',1,NULL,NULL,1),(27,27,'user',1,NULL,NULL,1),(28,28,'user',1,NULL,NULL,1),(29,29,'user',1,NULL,NULL,1),(30,30,'user',1,NULL,NULL,1),(31,31,'user',1,NULL,NULL,1),(32,38,'user',1,NULL,NULL,1),(33,40,'user',1,NULL,NULL,1),(34,41,'user',1,NULL,NULL,1),(35,42,'user',1,NULL,NULL,1),(36,43,'user',1,NULL,NULL,1),(37,44,'user',1,NULL,NULL,1),(38,45,'user',1,NULL,NULL,1),(39,46,'user',1,NULL,NULL,1),(40,47,'user',1,NULL,NULL,1),(41,48,'user',1,NULL,NULL,1),(42,49,'user',1,NULL,NULL,1),(43,50,'user',1,NULL,NULL,1),(44,51,'user',1,NULL,NULL,1),(45,52,'user',1,NULL,NULL,1),(46,53,'user',1,NULL,NULL,1),(47,54,'user',1,NULL,NULL,1),(48,55,'user',1,NULL,NULL,1),(49,56,'user',1,NULL,NULL,1),(50,121,'user',3,NULL,NULL,1),(51,122,'user',1,NULL,NULL,1),(52,123,'user',1,NULL,NULL,1),(53,124,'user',1,NULL,NULL,1),(54,125,'user',1,NULL,NULL,1),(55,127,'user',1,NULL,NULL,1),(56,128,'user',1,NULL,NULL,1),(57,129,'user',1,NULL,NULL,1),(58,130,'user',1,NULL,NULL,1),(59,131,'user',1,NULL,NULL,1),(60,132,'user',1,NULL,NULL,1),(61,133,'user',1,NULL,NULL,1),(62,134,'user',1,NULL,NULL,1),(63,135,'user',1,NULL,NULL,1),(64,136,'user',1,NULL,NULL,1),(65,137,'user',1,NULL,NULL,1),(66,138,'user',1,NULL,NULL,1),(67,139,'user',1,NULL,NULL,1),(68,140,'user',1,NULL,NULL,1),(69,141,'user',1,NULL,NULL,1),(70,142,'user',1,NULL,NULL,1),(71,143,'user',1,NULL,NULL,1),(72,144,'user',1,NULL,NULL,1),(73,145,'user',1,NULL,NULL,1),(74,146,'user',1,NULL,NULL,1),(75,147,'user',1,NULL,NULL,1),(76,148,'user',1,NULL,NULL,1),(77,149,'user',1,NULL,NULL,1),(78,150,'user',1,NULL,NULL,1),(79,151,'user',1,NULL,NULL,1),(80,152,'user',1,NULL,NULL,1),(81,203,'user',1,NULL,NULL,1),(82,204,'user',1,NULL,NULL,1),(83,205,'user',1,NULL,NULL,1),(84,206,'user',1,NULL,NULL,1),(85,207,'user',1,NULL,NULL,1),(86,208,'user',1,NULL,NULL,1),(87,209,'user',1,NULL,NULL,1),(88,210,'user',1,NULL,NULL,1),(89,211,'user',1,NULL,NULL,1),(90,212,'user',1,NULL,NULL,1),(91,213,'user',1,NULL,NULL,1),(92,214,'user',1,NULL,NULL,1),(93,215,'user',1,NULL,NULL,1),(94,216,'user',1,NULL,NULL,1),(95,217,'user',1,NULL,NULL,1),(96,218,'user',1,NULL,NULL,1),(97,219,'user',1,NULL,NULL,1),(98,220,'user',1,NULL,NULL,1),(99,221,'user',1,NULL,NULL,1),(100,222,'user',1,NULL,NULL,1),(101,223,'user',1,NULL,NULL,1),(102,224,'user',1,NULL,NULL,1),(103,225,'user',1,NULL,NULL,1),(104,226,'user',1,NULL,NULL,1),(105,227,'user',1,NULL,NULL,1),(106,228,'user',1,NULL,NULL,1),(107,229,'user',1,NULL,NULL,1),(108,230,'user',1,NULL,NULL,1),(109,231,'user',1,NULL,NULL,1),(110,232,'user',12,'0',0,0),(111,233,'user',12,'0',0,0),(112,234,'user',12,'0',0,1),(113,235,'user',12,'0',0,1),(114,236,'user',4,'0',0,0),(115,237,'user',13,'0',0,0),(116,237,'user',16,'0',0,0),(117,237,'user',18,'0',0,0),(118,238,'user',12,'0',0,1),(119,238,'user',3,'0',0,1),(120,238,'user',10,'0',0,1),(121,239,'user',12,'0',0,0),(123,240,'user',12,'0',0,1),(125,242,'user',12,'0',0,0),(126,243,'user',12,'0',0,0),(128,245,'user',12,'0',0,0),(132,249,'user',12,'0',0,0),(133,250,'user',12,'0',0,0),(134,251,'user',12,'0',0,0),(135,252,'user',12,'0',0,0),(136,253,'user',12,'0',0,0),(137,254,'user',12,'0',0,0),(138,255,'user',12,'0',0,0),(139,256,'user',12,'0',0,0),(140,257,'user',12,'0',0,0),(146,263,'user',12,'0',0,0),(147,264,'user',12,'0',0,0),(148,265,'user',12,'0',0,0),(149,266,'user',12,'0',0,0),(150,267,'user',12,'0',0,0),(151,268,'user',12,'0',0,0),(152,269,'user',12,'0',0,0),(153,270,'user',12,'0',0,0),(154,271,'user',12,'0',0,0),(155,272,'user',12,'0',0,0),(156,273,'user',12,'0',0,0),(157,274,'user',12,'0',0,0),(158,275,'user',12,'0',0,0),(160,277,'user',12,'0',0,0),(161,278,'user',12,'0',0,0),(162,279,'user',12,'0',0,0),(164,281,'user',12,'0',0,0),(165,282,'user',12,'0',0,0),(166,283,'user',12,'0',0,0),(167,284,'user',12,'0',0,0),(168,285,'user',12,'0',0,0),(169,286,'user',12,'0',0,0),(170,287,'user',12,'0',0,0),(171,288,'user',12,'0',0,0),(177,294,'user',12,'0',0,0),(178,295,'user',12,'0',0,0),(179,296,'user',12,'0',0,0),(180,297,'user',12,'0',0,0),(181,298,'user',1,'0',0,0),(182,299,'user',2,'0',0,0),(183,300,'user',1,'0',0,0),(184,301,'user',2,'0',0,0),(185,302,'user',2,'0',0,0),(186,303,'user',2,'0',0,0),(187,304,'user',1,'0',0,0),(188,305,'user',2,'0',0,0),(189,306,'user',2,'0',0,0),(190,307,'user',1,'0',0,0),(191,308,'user',1,'0',0,0),(192,309,'user',1,'0',0,0),(193,310,'user',2,'0',0,0),(194,311,'user',2,'0',0,0),(195,312,'user',1,'0',0,0),(196,313,'user',2,'0',0,0),(197,314,'user',1,'0',0,0),(198,315,'user',2,'0',0,0),(199,316,'user',2,'0',0,0),(200,317,'user',2,'0',0,0),(201,318,'user',1,'0',0,0),(202,319,'user',2,'0',0,0),(203,320,'user',12,'0',0,0),(204,321,'user',12,'0',0,0),(205,322,'user',12,'0',0,0),(206,323,'user',12,'0',0,0),(207,324,'user',12,'0',0,0),(208,325,'user',12,'0',0,0),(209,326,'user',12,'0',0,0),(210,327,'user',12,'0',0,0),(211,328,'user',12,'0',0,0),(212,24,'socpeople',2,NULL,NULL,1),(213,235,'socpeople',2,NULL,NULL,1),(214,238,'socpeople',10,NULL,NULL,1),(215,327,'socpeople',12,NULL,NULL,1),(216,329,'user',12,'0',0,0),(217,330,'user',12,'0',0,0),(218,331,'user',12,'0',0,0),(220,333,'user',12,'0',0,0),(222,335,'user',12,'0',0,0),(224,337,'user',12,'0',0,0),(225,338,'user',12,'0',0,0),(226,339,'user',12,'0',0,0),(227,340,'user',12,'0',0,0),(228,341,'user',12,'0',0,0),(229,342,'user',12,'0',0,0),(230,343,'user',12,'0',0,0),(231,344,'user',12,'0',0,0),(232,345,'user',12,'0',0,0),(233,346,'user',12,'0',0,0),(234,347,'user',12,'0',0,0),(235,348,'user',12,'0',0,0),(236,349,'user',12,'0',0,0),(237,350,'user',12,'0',0,0),(238,351,'user',12,'0',0,0),(239,352,'user',12,'0',0,0),(240,353,'user',12,'0',0,0),(241,354,'user',12,'0',0,0),(242,355,'user',12,'0',0,0),(243,356,'user',12,'0',0,0),(244,357,'user',12,'0',0,0),(245,358,'user',12,'0',0,0),(246,359,'user',12,'0',0,0),(247,360,'user',12,'0',0,0),(248,361,'user',12,'0',0,0),(249,362,'user',12,'0',0,0),(250,363,'user',12,'0',0,0),(251,364,'user',12,'0',0,0),(252,365,'user',12,'0',0,0),(253,366,'user',12,'0',0,0),(254,367,'user',12,'0',0,0),(255,368,'user',12,'0',0,0),(256,369,'user',12,'0',0,0),(257,370,'user',12,'0',0,0),(258,371,'user',12,'0',0,0),(259,372,'user',12,'0',0,0),(260,373,'user',12,'0',0,0),(261,374,'user',12,'0',0,0),(262,375,'user',12,'0',0,0),(263,376,'user',12,'0',0,0),(264,377,'user',12,'0',0,0),(265,378,'user',12,'0',0,0),(266,379,'user',12,'0',0,0),(267,380,'user',12,'0',0,0),(268,381,'user',12,'0',0,0),(269,382,'user',12,'0',0,0),(270,383,'user',0,'0',0,0),(271,384,'user',12,'0',0,0),(272,385,'user',12,'0',0,0),(273,386,'user',12,'0',0,0),(274,387,'user',12,'0',0,0),(275,388,'user',12,'0',0,0),(276,389,'user',12,'0',0,0),(277,390,'user',12,'0',0,0),(278,391,'user',12,'0',0,0),(279,392,'user',12,'0',0,0),(280,393,'user',12,'0',0,0),(281,394,'user',12,'0',0,0),(282,395,'user',12,'0',0,0),(283,396,'user',12,'0',0,0),(284,397,'user',12,'0',0,0),(285,398,'user',12,'0',0,0),(286,399,'user',12,'0',0,0),(287,400,'user',12,'0',0,0),(288,401,'user',12,'0',0,0),(289,402,'user',12,'0',0,0),(290,403,'user',12,'0',0,0),(291,404,'user',12,'0',0,0),(292,405,'user',12,'0',0,0),(293,406,'user',12,'0',0,0),(294,407,'user',12,'0',0,0),(295,408,'user',12,'0',0,0),(296,409,'user',12,'0',0,0),(297,410,'user',12,'0',0,0),(298,411,'user',12,'0',0,0),(299,412,'user',12,'0',0,0),(300,413,'user',12,'0',0,0),(301,414,'user',12,'0',0,0),(302,415,'user',12,'0',0,0),(303,416,'user',12,'0',0,0),(304,417,'user',12,'0',0,0),(305,418,'user',12,'0',0,0),(306,419,'user',0,'0',0,0),(307,420,'user',12,'0',0,0),(308,421,'user',12,'0',0,0),(309,422,'user',12,'0',0,0),(310,423,'user',0,'0',0,0),(311,424,'user',12,'0',0,0),(312,425,'user',12,'0',0,0),(313,426,'user',12,'0',0,0),(314,427,'user',12,'0',0,0),(315,428,'user',12,'0',0,0),(316,429,'user',12,'0',0,0),(317,430,'user',12,'0',0,0),(318,431,'user',12,'0',0,0),(319,432,'user',12,'0',0,0),(320,433,'user',12,'0',0,0),(321,434,'user',12,'0',0,0),(322,435,'user',12,'0',0,0),(323,436,'user',12,'0',0,0),(324,437,'user',12,'0',0,0),(325,438,'user',12,'0',0,0),(326,439,'user',12,'0',0,0),(327,440,'user',12,'0',0,0),(328,441,'user',12,'0',0,0),(329,442,'user',12,'0',0,0),(330,443,'user',12,'0',0,0),(331,444,'user',12,'0',0,0),(332,445,'user',12,'0',0,0),(333,446,'user',12,'0',0,0),(334,447,'user',12,'0',0,0),(335,448,'user',12,'0',0,0),(336,449,'user',12,'0',0,0),(337,450,'user',12,'0',0,0),(338,451,'user',12,'0',0,0),(339,452,'user',12,'0',0,0),(340,453,'user',12,'0',0,0),(341,454,'user',12,'0',0,0),(342,455,'user',12,'0',0,0),(343,456,'user',12,'0',0,0),(344,457,'user',12,'0',0,0),(345,458,'user',12,'0',0,0),(346,459,'user',12,'0',0,0),(347,460,'user',12,'0',0,0),(348,461,'user',12,'0',0,0),(349,462,'user',12,'0',0,1),(350,463,'user',12,'0',0,1),(351,463,'user',4,'0',0,1),(352,463,'user',13,'0',0,1),(353,463,'user',2,'0',0,1),(354,464,'user',12,'0',0,0),(355,465,'user',12,'0',0,0),(356,466,'user',12,'0',0,1),(357,467,'user',0,'0',0,0),(358,468,'user',0,'0',0,0),(359,469,'user',0,'0',0,0),(360,470,'user',0,'0',0,0),(361,471,'user',0,'0',0,0),(362,483,'user',12,'0',0,0),(363,484,'user',12,'0',0,0),(364,485,'user',12,'0',0,0),(365,486,'user',12,'0',0,0),(366,487,'user',12,'0',0,0),(367,488,'user',12,'0',0,0),(368,489,'user',12,'0',0,0),(369,490,'user',12,'0',0,0),(370,491,'user',12,'0',0,0),(371,492,'user',12,'0',0,0),(372,493,'user',12,'0',0,0),(373,494,'user',12,'0',0,0),(374,495,'user',12,'0',0,0),(375,496,'user',12,'0',0,0),(376,497,'user',12,'0',0,0),(377,498,'user',12,'0',0,0),(378,499,'user',12,'0',0,0),(379,500,'user',12,'0',0,0),(380,501,'user',12,'0',0,0),(381,502,'user',12,'0',0,0),(382,503,'user',12,'0',0,0),(383,504,'user',12,'0',0,0),(384,505,'user',12,'0',0,0),(385,506,'user',12,'0',0,0),(386,507,'user',12,'0',0,0),(387,508,'user',12,'0',0,0),(388,509,'user',12,'0',0,0),(390,511,'user',12,'0',0,0),(391,512,'user',12,'0',0,0),(392,513,'user',12,'0',0,0),(393,514,'user',12,'0',0,0),(394,515,'user',12,'0',0,0),(395,516,'user',12,'0',0,0),(396,517,'user',12,'0',0,0),(397,518,'user',12,'0',0,0),(398,519,'user',12,'0',0,0),(399,520,'user',12,'0',0,0),(400,521,'user',12,'0',0,0),(401,522,'user',12,'0',0,0),(402,523,'user',12,'0',0,0),(403,524,'user',12,'0',0,0),(404,525,'user',12,'0',0,0),(405,526,'user',12,'0',0,0),(406,527,'user',12,'0',0,0),(407,528,'user',12,'0',0,0),(408,529,'user',12,'0',0,0),(409,530,'user',12,'0',0,0),(410,531,'user',12,'0',0,0),(411,532,'user',12,'0',0,0),(412,533,'user',12,'0',0,0),(413,534,'user',12,'0',0,0),(414,535,'user',12,'0',0,0),(415,536,'user',12,'0',0,0),(416,537,'user',12,'0',0,0),(417,538,'user',12,'0',0,0),(418,539,'user',12,'0',0,0),(419,540,'user',12,'0',0,0),(420,541,'user',12,'0',0,0),(421,542,'user',12,'0',0,0),(422,543,'user',12,'0',0,0),(423,544,'user',12,'0',0,0),(424,545,'user',12,'0',0,0),(425,546,'user',12,'0',0,0),(426,547,'user',12,'0',0,0),(427,548,'user',12,'0',0,0),(428,549,'user',12,'0',0,0),(429,550,'user',12,'0',0,0),(430,551,'user',12,'0',0,0),(431,552,'user',12,'0',0,0),(432,553,'user',12,'0',0,0),(433,554,'user',12,'0',0,0),(434,555,'user',12,'0',0,0),(435,556,'user',12,'0',0,0),(436,557,'user',12,'0',0,0),(437,558,'user',12,'0',0,0),(438,559,'user',12,'0',0,0),(439,560,'user',12,'0',0,0),(440,561,'user',12,'0',0,0),(441,562,'user',12,'0',0,0),(442,563,'user',12,'0',0,0),(443,564,'user',12,'0',0,0),(444,565,'user',12,'0',0,0),(445,566,'user',12,'0',0,0),(446,567,'user',12,'0',0,0),(447,568,'user',12,'0',0,0),(448,569,'user',12,'0',0,0),(449,570,'user',12,'0',0,0),(450,571,'user',12,'0',0,0),(451,572,'user',12,'0',0,0),(452,573,'user',12,'0',0,0),(453,574,'user',12,'0',0,0),(454,575,'user',12,'0',0,0),(455,576,'user',12,'0',0,0),(456,577,'user',12,'0',0,0),(457,578,'user',12,'0',0,0),(458,579,'user',12,'0',0,0),(459,580,'user',12,'0',0,0),(460,581,'user',12,'0',0,0),(461,582,'user',12,'0',0,0),(462,583,'user',12,'0',0,0),(463,584,'user',12,'0',0,0),(464,585,'user',12,'0',0,0),(465,586,'user',12,'0',0,0),(467,588,'user',12,'0',0,0),(468,589,'user',12,'0',0,0),(469,590,'user',12,'0',0,0),(470,591,'user',12,'0',0,0),(471,592,'user',12,'0',0,0),(472,593,'user',12,'0',0,0),(473,594,'user',12,'0',0,0),(474,595,'user',12,'0',0,0),(475,596,'user',12,'0',0,0),(476,597,'user',12,'0',0,0),(477,598,'user',12,'0',0,0),(478,599,'user',12,'0',0,0),(479,600,'user',12,'0',0,0),(480,601,'user',12,'0',0,0),(481,602,'user',12,'0',0,0),(482,603,'user',12,'0',0,1),(484,604,'user',12,'0',0,1),(485,605,'user',12,'0',0,1),(486,606,'user',12,'0',0,0); +INSERT INTO `llx_actioncomm_resources` VALUES (1,1,'user',1,NULL,NULL,1),(2,2,'user',1,NULL,NULL,1),(3,3,'user',1,NULL,NULL,1),(4,4,'user',1,NULL,NULL,1),(5,5,'user',1,NULL,NULL,1),(6,6,'user',1,NULL,NULL,1),(7,7,'user',1,NULL,NULL,1),(8,8,'user',1,NULL,NULL,1),(9,9,'user',1,NULL,NULL,1),(10,10,'user',1,NULL,NULL,1),(11,11,'user',1,NULL,NULL,1),(12,12,'user',1,NULL,NULL,1),(13,13,'user',1,NULL,NULL,1),(14,14,'user',1,NULL,NULL,1),(15,15,'user',1,NULL,NULL,1),(16,16,'user',1,NULL,NULL,1),(17,17,'user',1,NULL,NULL,1),(18,18,'user',1,NULL,NULL,1),(19,19,'user',1,NULL,NULL,1),(20,20,'user',1,NULL,NULL,1),(21,21,'user',1,NULL,NULL,1),(22,22,'user',1,NULL,NULL,1),(23,23,'user',1,NULL,NULL,1),(24,24,'user',1,NULL,NULL,1),(25,25,'user',1,NULL,NULL,1),(26,26,'user',1,NULL,NULL,1),(27,27,'user',1,NULL,NULL,1),(28,28,'user',1,NULL,NULL,1),(29,29,'user',1,NULL,NULL,1),(30,30,'user',1,NULL,NULL,1),(31,31,'user',1,NULL,NULL,1),(32,38,'user',1,NULL,NULL,1),(33,40,'user',1,NULL,NULL,1),(34,41,'user',1,NULL,NULL,1),(35,42,'user',1,NULL,NULL,1),(36,43,'user',1,NULL,NULL,1),(37,44,'user',1,NULL,NULL,1),(38,45,'user',1,NULL,NULL,1),(39,46,'user',1,NULL,NULL,1),(40,47,'user',1,NULL,NULL,1),(41,48,'user',1,NULL,NULL,1),(42,49,'user',1,NULL,NULL,1),(43,50,'user',1,NULL,NULL,1),(44,51,'user',1,NULL,NULL,1),(45,52,'user',1,NULL,NULL,1),(46,53,'user',1,NULL,NULL,1),(47,54,'user',1,NULL,NULL,1),(48,55,'user',1,NULL,NULL,1),(49,56,'user',1,NULL,NULL,1),(50,121,'user',3,NULL,NULL,1),(51,122,'user',1,NULL,NULL,1),(52,123,'user',1,NULL,NULL,1),(53,124,'user',1,NULL,NULL,1),(54,125,'user',1,NULL,NULL,1),(55,127,'user',1,NULL,NULL,1),(56,128,'user',1,NULL,NULL,1),(57,129,'user',1,NULL,NULL,1),(58,130,'user',1,NULL,NULL,1),(59,131,'user',1,NULL,NULL,1),(60,132,'user',1,NULL,NULL,1),(61,133,'user',1,NULL,NULL,1),(62,134,'user',1,NULL,NULL,1),(63,135,'user',1,NULL,NULL,1),(64,136,'user',1,NULL,NULL,1),(65,137,'user',1,NULL,NULL,1),(66,138,'user',1,NULL,NULL,1),(67,139,'user',1,NULL,NULL,1),(68,140,'user',1,NULL,NULL,1),(69,141,'user',1,NULL,NULL,1),(70,142,'user',1,NULL,NULL,1),(71,143,'user',1,NULL,NULL,1),(72,144,'user',1,NULL,NULL,1),(73,145,'user',1,NULL,NULL,1),(74,146,'user',1,NULL,NULL,1),(75,147,'user',1,NULL,NULL,1),(76,148,'user',1,NULL,NULL,1),(77,149,'user',1,NULL,NULL,1),(78,150,'user',1,NULL,NULL,1),(79,151,'user',1,NULL,NULL,1),(80,152,'user',1,NULL,NULL,1),(81,203,'user',1,NULL,NULL,1),(82,204,'user',1,NULL,NULL,1),(83,205,'user',1,NULL,NULL,1),(84,206,'user',1,NULL,NULL,1),(85,207,'user',1,NULL,NULL,1),(86,208,'user',1,NULL,NULL,1),(87,209,'user',1,NULL,NULL,1),(88,210,'user',1,NULL,NULL,1),(89,211,'user',1,NULL,NULL,1),(90,212,'user',1,NULL,NULL,1),(91,213,'user',1,NULL,NULL,1),(92,214,'user',1,NULL,NULL,1),(93,215,'user',1,NULL,NULL,1),(94,216,'user',1,NULL,NULL,1),(95,217,'user',1,NULL,NULL,1),(96,218,'user',1,NULL,NULL,1),(97,219,'user',1,NULL,NULL,1),(98,220,'user',1,NULL,NULL,1),(99,221,'user',1,NULL,NULL,1),(100,222,'user',1,NULL,NULL,1),(101,223,'user',1,NULL,NULL,1),(102,224,'user',1,NULL,NULL,1),(103,225,'user',1,NULL,NULL,1),(104,226,'user',1,NULL,NULL,1),(105,227,'user',1,NULL,NULL,1),(106,228,'user',1,NULL,NULL,1),(107,229,'user',1,NULL,NULL,1),(108,230,'user',1,NULL,NULL,1),(109,231,'user',1,NULL,NULL,1),(110,232,'user',12,'0',0,0),(111,233,'user',12,'0',0,0),(112,234,'user',12,'0',0,1),(113,235,'user',12,'0',0,1),(114,236,'user',4,'0',0,0),(115,237,'user',13,'0',0,0),(116,237,'user',16,'0',0,0),(117,237,'user',18,'0',0,0),(118,238,'user',12,'0',0,1),(119,238,'user',3,'0',0,1),(120,238,'user',10,'0',0,1),(121,239,'user',12,'0',0,0),(123,240,'user',12,'0',0,1),(125,242,'user',12,'0',0,0),(126,243,'user',12,'0',0,0),(128,245,'user',12,'0',0,0),(132,249,'user',12,'0',0,0),(133,250,'user',12,'0',0,0),(134,251,'user',12,'0',0,0),(135,252,'user',12,'0',0,0),(136,253,'user',12,'0',0,0),(137,254,'user',12,'0',0,0),(138,255,'user',12,'0',0,0),(139,256,'user',12,'0',0,0),(140,257,'user',12,'0',0,0),(146,263,'user',12,'0',0,0),(147,264,'user',12,'0',0,0),(148,265,'user',12,'0',0,0),(149,266,'user',12,'0',0,0),(150,267,'user',12,'0',0,0),(151,268,'user',12,'0',0,0),(152,269,'user',12,'0',0,0),(153,270,'user',12,'0',0,0),(154,271,'user',12,'0',0,0),(155,272,'user',12,'0',0,0),(156,273,'user',12,'0',0,0),(157,274,'user',12,'0',0,0),(158,275,'user',12,'0',0,0),(160,277,'user',12,'0',0,0),(161,278,'user',12,'0',0,0),(162,279,'user',12,'0',0,0),(164,281,'user',12,'0',0,0),(165,282,'user',12,'0',0,0),(166,283,'user',12,'0',0,0),(167,284,'user',12,'0',0,0),(168,285,'user',12,'0',0,0),(169,286,'user',12,'0',0,0),(170,287,'user',12,'0',0,0),(171,288,'user',12,'0',0,0),(177,294,'user',12,'0',0,0),(178,295,'user',12,'0',0,0),(179,296,'user',12,'0',0,0),(180,297,'user',12,'0',0,0),(181,298,'user',1,'0',0,0),(182,299,'user',2,'0',0,0),(183,300,'user',1,'0',0,0),(184,301,'user',2,'0',0,0),(185,302,'user',2,'0',0,0),(186,303,'user',2,'0',0,0),(187,304,'user',1,'0',0,0),(188,305,'user',2,'0',0,0),(189,306,'user',2,'0',0,0),(190,307,'user',1,'0',0,0),(191,308,'user',1,'0',0,0),(192,309,'user',1,'0',0,0),(193,310,'user',2,'0',0,0),(194,311,'user',2,'0',0,0),(195,312,'user',1,'0',0,0),(196,313,'user',2,'0',0,0),(197,314,'user',1,'0',0,0),(198,315,'user',2,'0',0,0),(199,316,'user',2,'0',0,0),(200,317,'user',2,'0',0,0),(201,318,'user',1,'0',0,0),(202,319,'user',2,'0',0,0),(203,320,'user',12,'0',0,0),(204,321,'user',12,'0',0,0),(205,322,'user',12,'0',0,0),(206,323,'user',12,'0',0,0),(207,324,'user',12,'0',0,0),(208,325,'user',12,'0',0,0),(209,326,'user',12,'0',0,0),(210,327,'user',12,'0',0,0),(211,328,'user',12,'0',0,0),(212,24,'socpeople',2,NULL,NULL,1),(213,235,'socpeople',2,NULL,NULL,1),(214,238,'socpeople',10,NULL,NULL,1),(215,327,'socpeople',12,NULL,NULL,1),(216,329,'user',12,'0',0,0),(217,330,'user',12,'0',0,0),(218,331,'user',12,'0',0,0),(220,333,'user',12,'0',0,0),(222,335,'user',12,'0',0,0),(224,337,'user',12,'0',0,0),(225,338,'user',12,'0',0,0),(226,339,'user',12,'0',0,0),(227,340,'user',12,'0',0,0),(228,341,'user',12,'0',0,0),(229,342,'user',12,'0',0,0),(230,343,'user',12,'0',0,0),(231,344,'user',12,'0',0,0),(232,345,'user',12,'0',0,0),(233,346,'user',12,'0',0,0),(234,347,'user',12,'0',0,0),(235,348,'user',12,'0',0,0),(236,349,'user',12,'0',0,0),(237,350,'user',12,'0',0,0),(238,351,'user',12,'0',0,0),(239,352,'user',12,'0',0,0),(240,353,'user',12,'0',0,0),(241,354,'user',12,'0',0,0),(242,355,'user',12,'0',0,0),(243,356,'user',12,'0',0,0),(244,357,'user',12,'0',0,0),(245,358,'user',12,'0',0,0),(246,359,'user',12,'0',0,0),(247,360,'user',12,'0',0,0),(248,361,'user',12,'0',0,0),(249,362,'user',12,'0',0,0),(250,363,'user',12,'0',0,0),(251,364,'user',12,'0',0,0),(252,365,'user',12,'0',0,0),(253,366,'user',12,'0',0,0),(254,367,'user',12,'0',0,0),(255,368,'user',12,'0',0,0),(256,369,'user',12,'0',0,0),(257,370,'user',12,'0',0,0),(258,371,'user',12,'0',0,0),(259,372,'user',12,'0',0,0),(260,373,'user',12,'0',0,0),(261,374,'user',12,'0',0,0),(262,375,'user',12,'0',0,0),(263,376,'user',12,'0',0,0),(264,377,'user',12,'0',0,0),(265,378,'user',12,'0',0,0),(266,379,'user',12,'0',0,0),(267,380,'user',12,'0',0,0),(268,381,'user',12,'0',0,0),(269,382,'user',12,'0',0,0),(270,383,'user',0,'0',0,0),(271,384,'user',12,'0',0,0),(272,385,'user',12,'0',0,0),(273,386,'user',12,'0',0,0),(274,387,'user',12,'0',0,0),(275,388,'user',12,'0',0,0),(276,389,'user',12,'0',0,0),(277,390,'user',12,'0',0,0),(278,391,'user',12,'0',0,0),(279,392,'user',12,'0',0,0),(280,393,'user',12,'0',0,0),(281,394,'user',12,'0',0,0),(282,395,'user',12,'0',0,0),(283,396,'user',12,'0',0,0),(284,397,'user',12,'0',0,0),(285,398,'user',12,'0',0,0),(286,399,'user',12,'0',0,0),(287,400,'user',12,'0',0,0),(288,401,'user',12,'0',0,0),(289,402,'user',12,'0',0,0),(290,403,'user',12,'0',0,0),(291,404,'user',12,'0',0,0),(292,405,'user',12,'0',0,0),(293,406,'user',12,'0',0,0),(294,407,'user',12,'0',0,0),(295,408,'user',12,'0',0,0),(296,409,'user',12,'0',0,0),(297,410,'user',12,'0',0,0),(298,411,'user',12,'0',0,0),(299,412,'user',12,'0',0,0),(300,413,'user',12,'0',0,0),(301,414,'user',12,'0',0,0),(302,415,'user',12,'0',0,0),(303,416,'user',12,'0',0,0),(304,417,'user',12,'0',0,0),(305,418,'user',12,'0',0,0),(306,419,'user',0,'0',0,0),(307,420,'user',12,'0',0,0),(308,421,'user',12,'0',0,0),(309,422,'user',12,'0',0,0),(310,423,'user',0,'0',0,0),(311,424,'user',12,'0',0,0),(312,425,'user',12,'0',0,0),(313,426,'user',12,'0',0,0),(314,427,'user',12,'0',0,0),(315,428,'user',12,'0',0,0),(316,429,'user',12,'0',0,0),(317,430,'user',12,'0',0,0),(318,431,'user',12,'0',0,0),(319,432,'user',12,'0',0,0),(320,433,'user',12,'0',0,0),(321,434,'user',12,'0',0,0),(322,435,'user',12,'0',0,0),(323,436,'user',12,'0',0,0),(324,437,'user',12,'0',0,0),(325,438,'user',12,'0',0,0),(326,439,'user',12,'0',0,0),(327,440,'user',12,'0',0,0),(328,441,'user',12,'0',0,0),(329,442,'user',12,'0',0,0),(330,443,'user',12,'0',0,0),(331,444,'user',12,'0',0,0),(332,445,'user',12,'0',0,0),(333,446,'user',12,'0',0,0),(334,447,'user',12,'0',0,0),(335,448,'user',12,'0',0,0),(336,449,'user',12,'0',0,0),(337,450,'user',12,'0',0,0),(338,451,'user',12,'0',0,0),(339,452,'user',12,'0',0,0),(340,453,'user',12,'0',0,0),(341,454,'user',12,'0',0,0),(342,455,'user',12,'0',0,0),(343,456,'user',12,'0',0,0),(344,457,'user',12,'0',0,0),(345,458,'user',12,'0',0,0),(346,459,'user',12,'0',0,0),(347,460,'user',12,'0',0,0),(348,461,'user',12,'0',0,0),(349,462,'user',12,'0',0,1),(350,463,'user',12,'0',0,1),(351,463,'user',4,'0',0,1),(352,463,'user',13,'0',0,1),(353,463,'user',2,'0',0,1),(354,464,'user',12,'0',0,0),(355,465,'user',12,'0',0,0),(356,466,'user',12,'0',0,1),(357,467,'user',0,'0',0,0),(358,468,'user',0,'0',0,0),(359,469,'user',0,'0',0,0),(360,470,'user',0,'0',0,0),(361,471,'user',0,'0',0,0),(362,483,'user',12,'0',0,0),(363,484,'user',12,'0',0,0),(364,485,'user',12,'0',0,0),(365,486,'user',12,'0',0,0),(366,487,'user',12,'0',0,0),(367,488,'user',12,'0',0,0),(368,489,'user',12,'0',0,0),(369,490,'user',12,'0',0,0),(370,491,'user',12,'0',0,0),(371,492,'user',12,'0',0,0),(372,493,'user',12,'0',0,0),(373,494,'user',12,'0',0,0),(374,495,'user',12,'0',0,0),(375,496,'user',12,'0',0,0),(376,497,'user',12,'0',0,0),(377,498,'user',12,'0',0,0),(378,499,'user',12,'0',0,0),(379,500,'user',12,'0',0,0),(380,501,'user',12,'0',0,0),(381,502,'user',12,'0',0,0),(382,503,'user',12,'0',0,0),(383,504,'user',12,'0',0,0),(384,505,'user',12,'0',0,0),(385,506,'user',12,'0',0,0),(386,507,'user',12,'0',0,0),(387,508,'user',12,'0',0,0),(388,509,'user',12,'0',0,0),(390,511,'user',12,'0',0,0),(391,512,'user',12,'0',0,0),(392,513,'user',12,'0',0,0),(393,514,'user',12,'0',0,0),(394,515,'user',12,'0',0,0),(395,516,'user',12,'0',0,0),(396,517,'user',12,'0',0,0),(397,518,'user',12,'0',0,0),(398,519,'user',12,'0',0,0),(399,520,'user',12,'0',0,0),(400,521,'user',12,'0',0,0),(401,522,'user',12,'0',0,0),(402,523,'user',12,'0',0,0),(403,524,'user',12,'0',0,0),(404,525,'user',12,'0',0,0),(405,526,'user',12,'0',0,0),(406,527,'user',12,'0',0,0),(407,528,'user',12,'0',0,0),(408,529,'user',12,'0',0,0),(409,530,'user',12,'0',0,0),(410,531,'user',12,'0',0,0),(411,532,'user',12,'0',0,0),(412,533,'user',12,'0',0,0),(413,534,'user',12,'0',0,0),(414,535,'user',12,'0',0,0),(415,536,'user',12,'0',0,0),(416,537,'user',12,'0',0,0),(417,538,'user',12,'0',0,0),(418,539,'user',12,'0',0,0),(419,540,'user',12,'0',0,0),(420,541,'user',12,'0',0,0),(421,542,'user',12,'0',0,0),(422,543,'user',12,'0',0,0),(423,544,'user',12,'0',0,0),(424,545,'user',12,'0',0,0),(425,546,'user',12,'0',0,0),(426,547,'user',12,'0',0,0),(427,548,'user',12,'0',0,0),(428,549,'user',12,'0',0,0),(429,550,'user',12,'0',0,0),(430,551,'user',12,'0',0,0),(431,552,'user',12,'0',0,0),(432,553,'user',12,'0',0,0),(433,554,'user',12,'0',0,0),(434,555,'user',12,'0',0,0),(435,556,'user',12,'0',0,0),(436,557,'user',12,'0',0,0),(437,558,'user',12,'0',0,0),(438,559,'user',12,'0',0,0),(439,560,'user',12,'0',0,0),(440,561,'user',12,'0',0,0),(441,562,'user',12,'0',0,0),(442,563,'user',12,'0',0,0),(443,564,'user',12,'0',0,0),(444,565,'user',12,'0',0,0),(445,566,'user',12,'0',0,0),(446,567,'user',12,'0',0,0),(447,568,'user',12,'0',0,0),(448,569,'user',12,'0',0,0),(449,570,'user',12,'0',0,0),(450,571,'user',12,'0',0,0),(451,572,'user',12,'0',0,0),(452,573,'user',12,'0',0,0),(453,574,'user',12,'0',0,0),(454,575,'user',12,'0',0,0),(455,576,'user',12,'0',0,0),(456,577,'user',12,'0',0,0),(457,578,'user',12,'0',0,0),(458,579,'user',12,'0',0,0),(459,580,'user',12,'0',0,0),(460,581,'user',12,'0',0,0),(461,582,'user',12,'0',0,0),(462,583,'user',12,'0',0,0),(463,584,'user',12,'0',0,0),(464,585,'user',12,'0',0,0),(465,586,'user',12,'0',0,0),(467,588,'user',12,'0',0,0),(468,589,'user',12,'0',0,0),(469,590,'user',12,'0',0,0),(470,591,'user',12,'0',0,0),(471,592,'user',12,'0',0,0),(472,593,'user',12,'0',0,0),(473,594,'user',12,'0',0,0),(474,595,'user',12,'0',0,0),(475,596,'user',12,'0',0,0),(476,597,'user',12,'0',0,0),(477,598,'user',12,'0',0,0),(478,599,'user',12,'0',0,0),(479,600,'user',12,'0',0,0),(480,601,'user',12,'0',0,0),(481,602,'user',12,'0',0,0),(482,603,'user',12,'0',0,1),(484,604,'user',12,'0',0,1),(485,605,'user',12,'0',0,1),(486,606,'user',12,'0',0,0),(487,607,'user',12,'0',0,0); /*!40000 ALTER TABLE `llx_actioncomm_resources` ENABLE KEYS */; UNLOCK TABLES; @@ -496,7 +496,6 @@ CREATE TABLE `llx_adherent` ( `email` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `url` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `socialnetworks` text COLLATE utf8_unicode_ci DEFAULT NULL, - `skype` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `phone` varchar(30) COLLATE utf8_unicode_ci DEFAULT NULL, `phone_perso` varchar(30) COLLATE utf8_unicode_ci DEFAULT NULL, `phone_mobile` varchar(30) COLLATE utf8_unicode_ci DEFAULT NULL, @@ -516,14 +515,6 @@ CREATE TABLE `llx_adherent` ( `canvas` varchar(32) COLLATE utf8_unicode_ci DEFAULT NULL, `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, `model_pdf` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `twitter` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `facebook` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `instagram` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `snapchat` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `googleplus` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `youtube` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `whatsapp` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `linkedin` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `gender` varchar(10) COLLATE utf8_unicode_ci DEFAULT NULL, PRIMARY KEY (`rowid`), UNIQUE KEY `uk_adherent_ref` (`ref`,`entity`), @@ -541,7 +532,7 @@ CREATE TABLE `llx_adherent` ( LOCK TABLES `llx_adherent` WRITE; /*!40000 ALTER TABLE `llx_adherent` DISABLE KEYS */; -INSERT INTO `llx_adherent` VALUES (1,'1',1,NULL,NULL,'Smith','Vick','vsmith','vsx1n8tf',NULL,2,'phy',NULL,10,NULL,NULL,NULL,NULL,102,'vsmith@email.com',NULL,'[]',NULL,NULL,NULL,NULL,'1960-07-07','person5.jpeg',0,0,'2014-07-09 00:00:00',NULL,NULL,'2012-07-10 15:12:56','2012-07-08 23:50:00','2021-04-15 10:22:54',1,12,12,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'woman'),(2,'2',1,NULL,NULL,'Curie','Pierre','pcurie','pcuriedolibarr',NULL,2,'phy',NULL,12,NULL,NULL,NULL,NULL,NULL,'pcurie@example.com',NULL,'[]',NULL,NULL,NULL,NULL,NULL,'pierrecurie.jpg',1,1,'2020-07-17 00:00:00',NULL,NULL,'2012-07-10 15:03:32','2012-07-10 15:03:09','2021-04-15 10:22:54',1,12,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(3,'3',1,NULL,NULL,'john','doe','john','8bs6gty5',NULL,2,'phy',NULL,NULL,NULL,NULL,NULL,NULL,1,'johndoe@email.com',NULL,'[]',NULL,NULL,NULL,NULL,NULL,'person9.jpeg',1,0,'2014-07-17 00:00:00',NULL,NULL,'2013-07-18 21:28:00','2013-07-18 21:10:09','2021-04-15 10:22:54',1,12,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(4,'4',1,NULL,NULL,'smith','smith','Smith','s6hjp10f',NULL,2,'phy',NULL,NULL,NULL,NULL,NULL,NULL,11,'smith@email.com',NULL,'[]',NULL,NULL,NULL,NULL,NULL,'person2.jpeg',1,0,'2018-07-17 00:00:00',NULL,NULL,'2013-07-18 21:27:52','2013-07-18 21:27:44','2021-04-15 10:22:54',1,12,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL); +INSERT INTO `llx_adherent` VALUES (1,'1',1,NULL,NULL,'Smith','Vick','vsmith','vsx1n8tf',NULL,2,'phy',NULL,10,NULL,NULL,NULL,NULL,102,'vsmith@email.com',NULL,'[]',NULL,NULL,NULL,'1960-07-07','person5.jpeg',0,0,'2014-07-09 00:00:00',NULL,NULL,'2012-07-10 15:12:56','2012-07-08 23:50:00','2021-04-15 10:22:54',1,12,12,NULL,NULL,NULL,'woman'),(2,'2',1,NULL,NULL,'Curie','Pierre','pcurie','pcuriedolibarr',NULL,2,'phy',NULL,12,NULL,NULL,NULL,NULL,NULL,'pcurie@example.com',NULL,'[]',NULL,NULL,NULL,NULL,'pierrecurie.jpg',1,1,'2020-07-17 00:00:00',NULL,NULL,'2012-07-10 15:03:32','2012-07-10 15:03:09','2021-04-15 10:22:54',1,12,1,NULL,NULL,NULL,NULL),(3,'3',1,NULL,NULL,'john','doe','john','8bs6gty5',NULL,2,'phy',NULL,NULL,NULL,NULL,NULL,NULL,1,'johndoe@email.com',NULL,'[]',NULL,NULL,NULL,NULL,'person9.jpeg',1,0,'2014-07-17 00:00:00',NULL,NULL,'2013-07-18 21:28:00','2013-07-18 21:10:09','2021-04-15 10:22:54',1,12,1,NULL,NULL,NULL,NULL),(4,'4',1,NULL,NULL,'smith','smith','Smith','s6hjp10f',NULL,2,'phy',NULL,NULL,NULL,NULL,NULL,NULL,11,'smith@email.com',NULL,'[]',NULL,NULL,NULL,NULL,'person2.jpeg',1,0,'2018-07-17 00:00:00',NULL,NULL,'2013-07-18 21:27:52','2013-07-18 21:27:44','2021-04-15 10:22:54',1,12,1,NULL,NULL,NULL,NULL); /*!40000 ALTER TABLE `llx_adherent` ENABLE KEYS */; UNLOCK TABLES; @@ -872,7 +863,7 @@ CREATE TABLE `llx_bank` ( LOCK TABLES `llx_bank` WRITE; /*!40000 ALTER TABLE `llx_bank` DISABLE KEYS */; -INSERT INTO `llx_bank` VALUES (1,'2012-07-08 23:56:14','2021-07-11 17:49:28','2021-07-08','2021-07-08',2000.00000000,'(Initial balance)',1,NULL,1,'SOLD','201210',NULL,1,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(2,'2012-07-09 00:00:24','2021-07-11 17:49:28','2021-07-09','2021-07-09',500.00000000,'(Initial balance)',2,NULL,NULL,'SOLD',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(3,'2012-07-10 13:33:42','2021-07-11 17:49:28','2021-07-10','2021-07-10',0.00000000,'(Solde initial)',3,NULL,NULL,'SOLD',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(5,'2013-07-18 20:50:24','2021-07-11 17:49:28','2021-07-08','2021-07-08',20.00000000,'(CustomerInvoicePayment)',1,1,NULL,'CB','201107',NULL,1,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(6,'2013-07-18 20:50:47','2021-07-11 17:49:28','2021-07-08','2021-07-08',10.00000000,'(CustomerInvoicePayment)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(8,'2013-08-01 03:34:11','2020-12-10 12:24:23','2020-08-15','2020-08-01',5.63000000,'(CustomerInvoicePayment)',1,1,1,'CB','201210',NULL,1,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(12,'2013-08-05 23:11:37','2020-12-10 12:24:23','2020-08-12','2020-08-05',-10.00000000,'(SocialContributionPayment)',1,1,1,'VIR','201210',NULL,1,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(13,'2013-08-06 20:33:54','2020-12-10 12:24:23','2020-08-06','2020-08-06',5.98000000,'(CustomerInvoicePayment)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(14,'2013-08-08 02:53:40','2020-12-10 12:24:23','2020-08-08','2020-08-08',26.10000000,'(CustomerInvoicePayment)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(15,'2013-08-08 02:55:58','2020-12-10 12:24:23','2020-08-08','2020-08-08',26.96000000,'(CustomerInvoicePayment)',1,1,1,'TIP','201211',NULL,1,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(16,'2014-12-09 15:28:44','2020-12-10 12:24:23','2020-12-09','2020-12-09',2.00000000,'(CustomerInvoicePayment)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(17,'2014-12-09 15:28:53','2020-12-10 12:24:23','2020-12-09','2020-12-09',-2.00000000,'(CustomerInvoicePaymentBack)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(18,'2014-12-09 17:35:55','2020-12-10 12:24:23','2020-12-09','2020-12-09',-2.00000000,'(CustomerInvoicePaymentBack)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(19,'2014-12-09 17:37:02','2020-12-10 12:24:23','2020-12-09','2020-12-09',2.00000000,'(CustomerInvoicePayment)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(20,'2014-12-09 18:35:07','2020-12-10 12:24:23','2020-12-09','2020-12-09',-2.00000000,'(CustomerInvoicePaymentBack)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(21,'2014-12-12 18:54:33','2021-04-15 10:22:31','2020-12-12','2020-12-12',1.00000000,'(CustomerInvoicePayment)',1,1,1,'TIP','201210',NULL,1,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(22,'2015-03-06 16:48:16','2021-04-15 10:22:31','2021-03-06','2021-03-06',20.00000000,'(SubscriptionPayment)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(23,'2015-03-20 14:30:11','2021-04-15 10:22:31','2021-03-20','2021-03-20',10.00000000,'(SubscriptionPayment)',1,1,NULL,'VIR',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(24,'2016-03-02 19:57:58','2021-07-11 17:49:28','2021-07-09','2021-07-09',605.00000000,'(CustomerInvoicePayment)',1,1,NULL,'VIR',NULL,NULL,0,NULL,0,NULL,'111',NULL,NULL,NULL,NULL,NULL),(26,'2016-03-02 20:01:39','2021-04-15 10:22:31','2021-03-19','2021-03-19',500.00000000,'(CustomerInvoicePayment)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(27,'2016-03-02 20:02:06','2021-04-15 10:22:31','2021-03-21','2021-03-21',400.00000000,'(CustomerInvoicePayment)',1,1,NULL,'VIR',NULL,NULL,0,NULL,0,NULL,'ABC and Co',NULL,NULL,NULL,NULL,NULL),(28,'2016-03-03 19:22:32','2020-12-10 12:24:23','2020-10-03','2020-10-03',-400.00000000,'(CustomerInvoicePaymentBack)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(29,'2016-03-03 19:23:16','2021-04-15 10:22:31','2021-03-10','2021-03-10',-300.00000000,'(CustomerInvoicePaymentBack)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(30,'2018-01-22 18:56:34','2021-04-15 10:22:31','2021-01-22','2021-01-22',-900.00000000,'(SupplierInvoicePayment)',1,12,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(31,'2018-07-30 22:42:14','2020-12-10 12:24:23','2020-07-30','2020-07-30',0.00000000,'(Initial balance)',4,0,NULL,'SOLD',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(32,'2017-02-01 19:02:44','2021-04-15 10:22:31','2021-02-01','2021-02-01',-200.00000000,'(SupplierInvoicePayment)',3,12,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(33,'2017-02-06 08:10:24','2021-04-15 10:22:31','2021-03-22','2021-03-22',150.00000000,'(CustomerInvoicePayment)',1,12,NULL,'CHQ',NULL,NULL,0,NULL,2,NULL,'Magic Food Store',NULL,NULL,NULL,NULL,NULL),(34,'2017-02-06 08:10:50','2021-04-15 10:22:31','2021-03-25','2021-03-25',140.00000000,'(CustomerInvoicePayment)',1,12,NULL,'PRE',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(36,'2017-02-16 02:22:09','2021-04-15 10:22:31','2021-02-16','2021-02-16',-1.00000000,'(ExpenseReportPayment)',4,12,NULL,'CHQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(37,'2017-02-21 16:07:43','2021-04-15 10:22:31','2021-02-21','2021-02-21',50.00000000,'(WithdrawalPayment)',1,12,NULL,'PRE',NULL,'T170201',0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(38,'2017-09-06 20:08:36','2020-12-10 12:24:23','2020-09-06','2020-09-06',10.00000000,'(DonationPayment)',3,12,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,'',NULL,NULL,NULL),(39,'2018-03-16 13:59:31','2021-04-15 10:22:31','2021-03-16','2021-03-16',10.00000000,'(CustomerInvoicePayment)',4,12,NULL,'CHQ',NULL,NULL,0,NULL,0,NULL,'Indian SAS',NULL,'',NULL,NULL,NULL),(41,'2019-10-04 10:28:14','2021-04-15 10:22:31','2021-01-19','2021-01-19',5.63000000,'(CustomerInvoicePayment)',3,12,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,'',NULL,NULL,NULL),(42,'2019-10-08 13:18:50','2020-12-10 12:24:23','2020-10-08','2020-10-08',-1000.00000000,'Salary payment',4,12,NULL,'VIR',NULL,NULL,0,NULL,0,NULL,NULL,NULL,'',NULL,NULL,NULL),(43,'2019-12-26 01:48:30','2021-04-15 10:22:31','2020-12-25','2020-12-25',-5.00000000,'(SocialContributionPayment)',4,12,NULL,'VIR',NULL,NULL,0,NULL,0,NULL,NULL,NULL,'',NULL,NULL,NULL),(44,'2019-12-26 01:48:46','2021-04-15 10:22:31','2020-12-25','2020-12-25',-5.00000000,'(SocialContributionPayment)',3,12,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,'',NULL,NULL,NULL),(47,'2020-01-01 20:28:49','2021-04-15 10:22:31','2021-01-01','2021-01-01',304.69000000,'(SupplierInvoicePayment)',4,12,NULL,'VIR',NULL,NULL,0,NULL,0,NULL,NULL,NULL,'',NULL,NULL,NULL),(48,'2020-01-06 20:52:28','2021-04-15 10:22:31','2021-01-06','2021-01-06',10.00000000,'Patient payment',1,12,NULL,'CB',NULL,NULL,0,NULL,0,NULL,'Patient',NULL,'',NULL,NULL,NULL),(49,'2020-01-10 04:42:47','2021-04-15 10:22:31','2021-01-10','2021-01-10',-10.00000000,'Miscellaneous payment',4,12,NULL,'VIR',NULL,NULL,0,NULL,0,NULL,NULL,NULL,'',NULL,NULL,NULL),(50,'2020-01-16 02:36:48','2021-04-15 10:22:31','2021-01-16','2021-01-16',20.50000000,'(CustomerInvoicePayment)',4,12,NULL,'VIR',NULL,NULL,0,NULL,0,NULL,'Magic Food Store',NULL,'',NULL,NULL,NULL),(51,'2020-01-21 01:02:14','2020-12-10 12:24:23','2020-07-18','2020-07-18',50.00000000,'Subscription 2013',4,12,NULL,'CB',NULL,'12345',0,NULL,0,'Bank CBN',NULL,NULL,'',NULL,NULL,NULL),(52,'2020-01-21 10:22:37','2021-04-15 10:22:31','2021-01-21','2021-01-21',50.00000000,'Subscription 2017',4,12,NULL,'CHQ',NULL,NULL,0,NULL,0,NULL,'smith smith',NULL,'',NULL,NULL,NULL),(53,'2020-01-21 10:23:17','2021-04-15 10:22:31','2021-01-21','2021-01-21',50.00000000,'(SubscriptionPayment)',4,12,NULL,'CHQ',NULL,NULL,0,NULL,0,NULL,'Pierre Curie',NULL,'',NULL,NULL,NULL),(54,'2020-01-21 10:23:28','2021-04-15 10:22:31','2021-01-21','2021-01-21',50.00000000,'(SubscriptionPayment)',4,12,NULL,'CHQ',NULL,NULL,0,NULL,0,NULL,'Pierre Curie',NULL,'',NULL,NULL,NULL),(55,'2020-01-21 10:23:49','2021-04-15 10:22:31','2021-01-21','2021-01-21',50.00000000,'(SubscriptionPayment)',4,12,NULL,'CB',NULL,NULL,0,NULL,0,NULL,NULL,NULL,'',NULL,NULL,NULL); +INSERT INTO `llx_bank` VALUES (1,'2012-07-08 23:56:14','2021-07-11 17:49:28','2021-07-08','2021-07-08',2000.00000000,'(Initial balance)',1,NULL,1,'SOLD','201210',NULL,1,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(2,'2012-07-09 00:00:24','2021-07-11 17:49:28','2021-07-09','2021-07-09',500.00000000,'(Initial balance)',2,NULL,NULL,'SOLD',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(3,'2012-07-10 13:33:42','2021-07-11 17:49:28','2021-07-10','2021-07-10',0.00000000,'(Solde initial)',3,NULL,NULL,'SOLD',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(5,'2013-07-18 20:50:24','2021-07-11 17:49:28','2021-07-08','2021-07-08',20.00000000,'(CustomerInvoicePayment)',1,1,NULL,'CB','201107',NULL,1,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(6,'2013-07-18 20:50:47','2021-07-11 17:49:28','2021-07-08','2021-07-08',10.00000000,'(CustomerInvoicePayment)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(8,'2013-08-01 03:34:11','2022-02-07 13:37:54','2021-08-15','2021-08-01',5.63000000,'(CustomerInvoicePayment)',1,1,1,'CB','201210',NULL,1,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(12,'2013-08-05 23:11:37','2022-02-07 13:37:54','2021-08-12','2021-08-05',-10.00000000,'(SocialContributionPayment)',1,1,1,'VIR','201210',NULL,1,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(13,'2013-08-06 20:33:54','2022-02-07 13:37:54','2021-08-06','2021-08-06',5.98000000,'(CustomerInvoicePayment)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(14,'2013-08-08 02:53:40','2022-02-07 13:37:54','2021-08-08','2021-08-08',26.10000000,'(CustomerInvoicePayment)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(15,'2013-08-08 02:55:58','2022-02-07 13:37:54','2021-08-08','2021-08-08',26.96000000,'(CustomerInvoicePayment)',1,1,1,'TIP','201211',NULL,1,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(16,'2014-12-09 15:28:44','2022-02-07 13:37:54','2021-12-09','2021-12-09',2.00000000,'(CustomerInvoicePayment)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(17,'2014-12-09 15:28:53','2022-02-07 13:37:54','2021-12-09','2021-12-09',-2.00000000,'(CustomerInvoicePaymentBack)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(18,'2014-12-09 17:35:55','2022-02-07 13:37:54','2021-12-09','2021-12-09',-2.00000000,'(CustomerInvoicePaymentBack)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(19,'2014-12-09 17:37:02','2022-02-07 13:37:54','2021-12-09','2021-12-09',2.00000000,'(CustomerInvoicePayment)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(20,'2014-12-09 18:35:07','2022-02-07 13:37:54','2021-12-09','2021-12-09',-2.00000000,'(CustomerInvoicePaymentBack)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(21,'2014-12-12 18:54:33','2022-02-07 13:37:54','2021-12-12','2021-12-12',1.00000000,'(CustomerInvoicePayment)',1,1,1,'TIP','201210',NULL,1,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(22,'2015-03-06 16:48:16','2021-04-15 10:22:31','2021-03-06','2021-03-06',20.00000000,'(SubscriptionPayment)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(23,'2015-03-20 14:30:11','2021-04-15 10:22:31','2021-03-20','2021-03-20',10.00000000,'(SubscriptionPayment)',1,1,NULL,'VIR',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(24,'2016-03-02 19:57:58','2021-07-11 17:49:28','2021-07-09','2021-07-09',605.00000000,'(CustomerInvoicePayment)',1,1,NULL,'VIR',NULL,NULL,0,NULL,0,NULL,'111',NULL,NULL,NULL,NULL,NULL),(26,'2016-03-02 20:01:39','2021-04-15 10:22:31','2021-03-19','2021-03-19',500.00000000,'(CustomerInvoicePayment)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(27,'2016-03-02 20:02:06','2021-04-15 10:22:31','2021-03-21','2021-03-21',400.00000000,'(CustomerInvoicePayment)',1,1,NULL,'VIR',NULL,NULL,0,NULL,0,NULL,'ABC and Co',NULL,NULL,NULL,NULL,NULL),(28,'2016-03-03 19:22:32','2022-02-07 13:37:54','2021-10-03','2021-10-03',-400.00000000,'(CustomerInvoicePaymentBack)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(29,'2016-03-03 19:23:16','2021-04-15 10:22:31','2021-03-10','2021-03-10',-300.00000000,'(CustomerInvoicePaymentBack)',3,1,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(30,'2018-01-22 18:56:34','2022-02-07 13:37:54','2022-01-22','2022-01-22',-900.00000000,'(SupplierInvoicePayment)',1,12,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(31,'2018-07-30 22:42:14','2022-02-07 13:37:54','2021-07-30','2021-07-30',0.00000000,'(Initial balance)',4,0,NULL,'SOLD',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(32,'2017-02-01 19:02:44','2022-02-07 13:37:54','2022-02-01','2022-02-01',-200.00000000,'(SupplierInvoicePayment)',3,12,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(33,'2017-02-06 08:10:24','2021-04-15 10:22:31','2021-03-22','2021-03-22',150.00000000,'(CustomerInvoicePayment)',1,12,NULL,'CHQ',NULL,NULL,0,NULL,2,NULL,'Magic Food Store',NULL,NULL,NULL,NULL,NULL),(34,'2017-02-06 08:10:50','2021-04-15 10:22:31','2021-03-25','2021-03-25',140.00000000,'(CustomerInvoicePayment)',1,12,NULL,'PRE',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(36,'2017-02-16 02:22:09','2021-04-15 10:22:31','2021-02-16','2021-02-16',-1.00000000,'(ExpenseReportPayment)',4,12,NULL,'CHQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(37,'2017-02-21 16:07:43','2021-04-15 10:22:31','2021-02-21','2021-02-21',50.00000000,'(WithdrawalPayment)',1,12,NULL,'PRE',NULL,'T170201',0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(38,'2017-09-06 20:08:36','2022-02-07 13:37:54','2021-09-06','2021-09-06',10.00000000,'(DonationPayment)',3,12,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,'',NULL,NULL,NULL),(39,'2018-03-16 13:59:31','2021-04-15 10:22:31','2021-03-16','2021-03-16',10.00000000,'(CustomerInvoicePayment)',4,12,NULL,'CHQ',NULL,NULL,0,NULL,0,NULL,'Indian SAS',NULL,'',NULL,NULL,NULL),(41,'2019-10-04 10:28:14','2022-02-07 13:37:54','2022-01-19','2022-01-19',5.63000000,'(CustomerInvoicePayment)',3,12,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,'',NULL,NULL,NULL),(42,'2019-10-08 13:18:50','2022-02-07 13:37:54','2021-10-08','2021-10-08',-1000.00000000,'Salary payment',4,12,NULL,'VIR',NULL,NULL,0,NULL,0,NULL,NULL,NULL,'',NULL,NULL,NULL),(43,'2019-12-26 01:48:30','2022-02-07 13:37:54','2021-12-25','2021-12-25',-5.00000000,'(SocialContributionPayment)',4,12,NULL,'VIR',NULL,NULL,0,NULL,0,NULL,NULL,NULL,'',NULL,NULL,NULL),(44,'2019-12-26 01:48:46','2022-02-07 13:37:54','2021-12-25','2021-12-25',-5.00000000,'(SocialContributionPayment)',3,12,NULL,'LIQ',NULL,NULL,0,NULL,0,NULL,NULL,NULL,'',NULL,NULL,NULL),(47,'2020-01-01 20:28:49','2022-02-07 13:37:54','2022-01-01','2022-01-01',304.69000000,'(SupplierInvoicePayment)',4,12,NULL,'VIR',NULL,NULL,0,NULL,0,NULL,NULL,NULL,'',NULL,NULL,NULL),(48,'2020-01-06 20:52:28','2022-02-07 13:37:54','2022-01-06','2022-01-06',10.00000000,'Patient payment',1,12,NULL,'CB',NULL,NULL,0,NULL,0,NULL,'Patient',NULL,'',NULL,NULL,NULL),(49,'2020-01-10 04:42:47','2022-02-07 13:37:54','2022-01-10','2022-01-10',-10.00000000,'Miscellaneous payment',4,12,NULL,'VIR',NULL,NULL,0,NULL,0,NULL,NULL,NULL,'',NULL,NULL,NULL),(50,'2020-01-16 02:36:48','2022-02-07 13:37:54','2022-01-16','2022-01-16',20.50000000,'(CustomerInvoicePayment)',4,12,NULL,'VIR',NULL,NULL,0,NULL,0,NULL,'Magic Food Store',NULL,'',NULL,NULL,NULL),(51,'2020-01-21 01:02:14','2022-02-07 13:37:54','2021-07-18','2021-07-18',50.00000000,'Subscription 2013',4,12,NULL,'CB',NULL,'12345',0,NULL,0,'Bank CBN',NULL,NULL,'',NULL,NULL,NULL),(52,'2020-01-21 10:22:37','2022-02-07 13:37:54','2022-01-21','2022-01-21',50.00000000,'Subscription 2017',4,12,NULL,'CHQ',NULL,NULL,0,NULL,0,NULL,'smith smith',NULL,'',NULL,NULL,NULL),(53,'2020-01-21 10:23:17','2022-02-07 13:37:54','2022-01-21','2022-01-21',50.00000000,'(SubscriptionPayment)',4,12,NULL,'CHQ',NULL,NULL,0,NULL,0,NULL,'Pierre Curie',NULL,'',NULL,NULL,NULL),(54,'2020-01-21 10:23:28','2022-02-07 13:37:54','2022-01-21','2022-01-21',50.00000000,'(SubscriptionPayment)',4,12,NULL,'CHQ',NULL,NULL,0,NULL,0,NULL,'Pierre Curie',NULL,'',NULL,NULL,NULL),(55,'2020-01-21 10:23:49','2022-02-07 13:37:54','2022-01-21','2022-01-21',50.00000000,'(SubscriptionPayment)',4,12,NULL,'CB',NULL,NULL,0,NULL,0,NULL,NULL,NULL,'',NULL,NULL,NULL); /*!40000 ALTER TABLE `llx_bank` ENABLE KEYS */; UNLOCK TABLES; @@ -1075,7 +1066,7 @@ CREATE TABLE `llx_blockedlog` ( KEY `fk_user` (`fk_user`), KEY `entity_action` (`entity`,`action`), KEY `entity_action_certified` (`entity`,`action`,`certified`) -) ENGINE=InnoDB AUTO_INCREMENT=59 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=61 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -1084,7 +1075,7 @@ CREATE TABLE `llx_blockedlog` ( LOCK TABLES `llx_blockedlog` WRITE; /*!40000 ALTER TABLE `llx_blockedlog` DISABLE KEYS */; -INSERT INTO `llx_blockedlog` VALUES (20,'2018-03-16 09:57:22','MODULE_RESET',0.00000000,'d6dd5fe6c2eec2de6368f3b6da30188566f0a1a7be4b1589ccd8352d2c827ad5','fbc11d0396d9b76ea48f892bd5f0fe652e5bdf7d44873acb4bf1e1b70352bd30','module',1,'systemevent','2018-03-16 13:57:22','O:8:\"stdClass\":6:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:10:\"name_alias\";N;s:7:\"address\";s:24:\"21 Jump street..ll..ee \"\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";N;s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:1:\"1\";s:7:\"idprof3\";s:1:\"1\";s:7:\"idprof4\";s:1:\"1\";s:7:\"idprof5\";s:1:\"1\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:9:\"FR1234567\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";s:4:\"name\";s:12:\"MyBigCompany\";}s:2:\"id\";i:1;s:7:\"element\";s:6:\"module\";s:3:\"ref\";s:11:\"systemevent\";s:6:\"entity\";i:1;s:4:\"date\";i:1521194242;}',12,1,0,'2018-03-16 13:57:22','Alice Adminson',''),(21,'2018-03-16 09:57:24','MODULE_SET',0.00000000,'d6b66df837d8d33bd8b9744e2afa46ab8c65ae8ca462246c406de19f8254e146','0a3aae975056417705f4eb7b4a4926384075cc2b6c899603715643c8f1d6ff9b','module',1,'systemevent','2018-03-16 13:57:24','O:8:\"stdClass\":6:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:10:\"name_alias\";N;s:7:\"address\";s:24:\"21 Jump street..ll..ee \"\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";N;s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:1:\"1\";s:7:\"idprof3\";s:1:\"1\";s:7:\"idprof4\";s:1:\"1\";s:7:\"idprof5\";s:1:\"1\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:9:\"FR1234567\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";s:4:\"name\";s:12:\"MyBigCompany\";}s:2:\"id\";i:1;s:7:\"element\";s:6:\"module\";s:3:\"ref\";s:11:\"systemevent\";s:6:\"entity\";i:1;s:4:\"date\";i:1521194244;}',12,1,0,'2018-03-16 13:57:24','Alice Adminson',''),(22,'2018-03-16 09:59:31','PAYMENT_CUSTOMER_CREATE',10.00000000,'9beb9e3ba04582d441b49f176f995900c16572c789bcf48a1c9f285a74be76c8','86813eb2563252c0e270baaf1fffade82475fe51af5f88d14613005fd0e07783','payment',38,'PAY1803-0004','2018-03-16 12:00:00','O:8:\"stdClass\":8:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:10:\"name_alias\";N;s:7:\"address\";s:24:\"21 Jump street..ll..ee \"\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";N;s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:1:\"1\";s:7:\"idprof3\";s:1:\"1\";s:7:\"idprof4\";s:1:\"1\";s:7:\"idprof5\";s:1:\"1\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:9:\"FR1234567\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";s:4:\"name\";s:12:\"MyBigCompany\";}s:3:\"ref\";s:12:\"PAY1803-0004\";s:4:\"date\";i:1521187200;s:9:\"type_code\";s:3:\"CHQ\";s:11:\"payment_num\";N;s:4:\"note\";s:0:\"\";s:12:\"payment_part\";a:1:{i:1;O:8:\"stdClass\":3:{s:6:\"amount\";s:2:\"10\";s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:13:\"1 alalah road\";s:3:\"zip\";N;s:4:\"town\";s:5:\"Delhi\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";N;s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:13:\"5000.00000000\";s:11:\"typent_code\";s:8:\"TE_SMALL\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1212-0007\";s:16:\"code_fournisseur\";s:11:\"SU1212-0005\";s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";s:4:\"name\";s:10:\"Indian SAS\";}s:7:\"invoice\";O:8:\"stdClass\":9:{s:4:\"date\";i:1453147200;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"0\";s:8:\"total_ht\";s:11:\"20.00000000\";s:9:\"total_tva\";s:10:\"1.80000000\";s:9:\"total_ttc\";s:11:\"23.60000000\";s:12:\"revenuestamp\";s:10:\"0.00000000\";s:3:\"ref\";s:11:\"FA1601-0024\";s:11:\"note_public\";N;}}}s:6:\"amount\";i:10;}',12,1,0,'2018-03-16 13:59:31','Alice Adminson',''),(23,'2019-09-26 15:33:37','BILL_VALIDATE',43.58000000,'6a1e049c00f51afa6eaca799e6281bd8abfdaa12bdf42ee2a002b0bec588a2a5','451b12ea66d25259c9c1df9993a902affe124c9f27c97093613cf7184fe388aa','facture',218,'FA1909-0025','2019-09-26 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"Dupont Alain\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:0:\"\";s:3:\"zip\";N;s:4:\"town\";N;s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";s:18:\"pcurie@example.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1601-0019\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:0:\"\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:24:\"21 Jump street..ll..ee \"\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";N;s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1569448800;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"0\";s:8:\"total_ht\";d:42.5;s:9:\"total_tva\";d:1.08;s:9:\"total_ttc\";d:43.58;s:12:\"revenuestamp\";s:10:\"0.00000000\";s:11:\"invoiceline\";a:5:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";s:9:\"DOLICLOUD\";s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:10:\"9.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.00000000\";s:23:\"multicurrency_total_ttc\";s:10:\"9.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"1\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"0.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:10:\"9.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:10:\"9.00000000\";s:9:\"info_bits\";s:1:\"0\";}i:2;O:8:\"stdClass\":17:{s:3:\"ref\";s:9:\"DOLIDROID\";s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:10:\"5.50000000\";s:23:\"multicurrency_total_tva\";s:10:\"1.08000000\";s:23:\"multicurrency_total_ttc\";s:10:\"6.58000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:6:\"19.600\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:10:\"5.50000000\";s:9:\"total_tva\";s:10:\"1.08000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:10:\"6.58000000\";s:9:\"info_bits\";s:1:\"0\";}i:3;O:8:\"stdClass\":17:{s:3:\"ref\";s:9:\"DOLICLOUD\";s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:10:\"9.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.00000000\";s:23:\"multicurrency_total_ttc\";s:10:\"9.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"1\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"0.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:10:\"9.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:10:\"9.00000000\";s:9:\"info_bits\";s:1:\"0\";}i:4;O:8:\"stdClass\":17:{s:3:\"ref\";s:9:\"DOLICLOUD\";s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:10:\"9.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.00000000\";s:23:\"multicurrency_total_ttc\";s:10:\"9.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"1\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"0.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:10:\"9.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:10:\"9.00000000\";s:9:\"info_bits\";s:1:\"0\";}i:5;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"10.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.00000000\";s:23:\"multicurrency_total_ttc\";s:11:\"10.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"0.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"10.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"10.00000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"FA1909-0025\";s:11:\"note_public\";N;}',12,1,0,'2019-09-26 17:33:37','Alice Adminson',''),(24,'2019-10-04 08:27:00','BILL_VALIDATE',5.63000000,'aa16d46e6ea7376fe0f91a4aeb7b1d534ed351fae071ded64c393e61269c4c35','316e03ffb8327d837c8601e7dbafc91509581b0be9449a89827a14e6cfa2688a','facture',150,'FA6801-0010','2018-01-19 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:10:\"Indian SAS\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:13:\"1 alalah road\";s:3:\"zip\";N;s:4:\"town\";s:5:\"Delhi\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";N;s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:13:\"5000.00000000\";s:11:\"typent_code\";s:8:\"TE_SMALL\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1212-0007\";s:16:\"code_fournisseur\";s:11:\"SU1212-0005\";s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:24:\"21 Jump street..ll..ee \"\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";N;s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1516316400;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"0\";s:8:\"total_ht\";d:5;s:9:\"total_tva\";d:0.63;s:9:\"total_ttc\";d:5.63;s:12:\"revenuestamp\";s:10:\"0.00000000\";s:11:\"invoiceline\";a:1:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";s:7:\"PEARPIE\";s:18:\"multicurrency_code\";N;s:22:\"multicurrency_total_ht\";s:10:\"5.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.63000000\";s:23:\"multicurrency_total_ttc\";s:10:\"5.63000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:6:\"12.500\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:10:\"5.00000000\";s:9:\"total_tva\";s:10:\"0.63000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:10:\"5.63000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"FA6801-0010\";s:11:\"note_public\";N;}',12,1,0,'2019-10-04 10:27:00','Alice Adminson',''),(25,'2019-10-04 08:28:14','PAYMENT_CUSTOMER_CREATE',5.63000000,'fa5c9b4bb975af8401744390d47e62218a7ec47a2e96c60f5e58d7f6be38dc44','9bfe069dc130dd71c31f914ff0afa7835fd40932790ac88be0005638342ccb87','payment',39,'PAY1801-0005','2018-01-19 12:00:00','O:8:\"stdClass\":8:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:24:\"21 Jump street..ll..ee \"\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";N;s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:3:\"ref\";s:12:\"PAY1801-0005\";s:4:\"date\";i:1516359600;s:9:\"type_code\";s:3:\"LIQ\";s:11:\"payment_num\";N;s:4:\"note\";s:0:\"\";s:12:\"payment_part\";a:1:{i:1;O:8:\"stdClass\":3:{s:6:\"amount\";s:4:\"5.63\";s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:10:\"Indian SAS\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:13:\"1 alalah road\";s:3:\"zip\";N;s:4:\"town\";s:5:\"Delhi\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";N;s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:13:\"5000.00000000\";s:11:\"typent_code\";s:8:\"TE_SMALL\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1212-0007\";s:16:\"code_fournisseur\";s:11:\"SU1212-0005\";s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:7:\"invoice\";O:8:\"stdClass\":9:{s:4:\"date\";i:1516316400;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"0\";s:8:\"total_ht\";s:10:\"5.00000000\";s:9:\"total_tva\";s:10:\"0.63000000\";s:9:\"total_ttc\";s:10:\"5.63000000\";s:12:\"revenuestamp\";s:10:\"0.00000000\";s:3:\"ref\";s:11:\"FA6801-0010\";s:11:\"note_public\";N;}}}s:6:\"amount\";d:5.63;}',12,1,0,'2019-10-04 10:28:14','Alice Adminson',''),(26,'2019-12-22 19:01:48','CASHCONTROL_VALIDATE',400.00000000,'bb14150a5ea65d97f9d22f6bc3d3d357ccfb2aa681f2ecbcc81a9d870260c58c','7b03131558731b2e7b4000189214b132f4323621c596d4418cfeba233a085e83','cashcontrol',1,'1','2019-12-22 23:01:02','O:8:\"stdClass\":37:{s:9:\"mycompany\";O:8:\"stdClass\":26:{s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:0;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:0;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;}s:7:\"element\";s:11:\"cashcontrol\";s:2:\"id\";i:1;s:7:\"opening\";d:-324.29;s:6:\"status\";i:1;s:10:\"year_close\";i:2019;s:11:\"month_close\";i:11;s:9:\"day_close\";N;s:9:\"posmodule\";s:7:\"takepos\";s:9:\"posnumber\";s:1:\"1\";s:4:\"cash\";d:400;s:6:\"cheque\";d:0;s:4:\"card\";d:0;s:10:\"date_valid\";i:1577041308;s:13:\"date_creation\";i:1577041262;s:17:\"date_modification\";N;s:10:\"import_key\";N;s:13:\"array_options\";a:0:{}s:6:\"canvas\";N;s:7:\"project\";N;s:10:\"fk_project\";N;s:10:\"thirdparty\";N;s:4:\"user\";N;s:3:\"ref\";s:1:\"1\";s:7:\"ref_ext\";N;s:6:\"statut\";N;s:10:\"fk_account\";N;s:11:\"note_public\";N;s:12:\"note_private\";N;s:4:\"note\";N;s:8:\"comments\";a:0:{}s:15:\"date_validation\";N;s:16:\"next_prev_filter\";N;s:6:\"entity\";i:1;s:5:\"label\";N;s:3:\"tms\";i:1577030462;s:13:\"fk_user_valid\";s:2:\"12\";}',12,1,0,'2019-12-22 23:01:48','Alice Adminson',''),(34,'2020-01-10 00:42:47','PAYMENT_VARIOUS_CREATE',10.00000000,'e20ec32652d7564cdca915e95528b68bd3b770b82defe64ead1af3f6dc6bc150','25514deeca716e41c02699d9466fc640f4b7da0a0c953637b542c555f9634f9b','payment_various',4,'4','2020-01-10 12:00:00','O:8:\"stdClass\":7:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:3:\"ref\";i:4;s:4:\"date\";i:1578643200;s:9:\"type_code\";s:3:\"VIR\";s:11:\"payment_num\";s:0:\"\";s:4:\"note\";s:0:\"\";s:6:\"amount\";i:10;}',12,1,0,'2020-01-10 04:42:47','Alice Adminson',''),(35,'2020-01-10 01:08:37','PAYMENT_VARIOUS_MODIFY',10.00000000,'94bd3491e8e553e6e633cd4a40c8c0ef3a6af0bd60df1d8e768d3c8c2a37b79b','eeadf2ffc7bd611e3b739e8825307f9e9cb2d9dddbd9e16b1f092fa5d881a5ca','payment_various',4,'4','2020-01-10 00:00:00','O:8:\"stdClass\":7:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:3:\"ref\";s:1:\"4\";s:4:\"date\";i:1578600000;s:9:\"type_code\";s:3:\"VIR\";s:11:\"payment_num\";s:0:\"\";s:4:\"note\";s:0:\"\";s:6:\"amount\";d:10;}',12,1,0,'2020-01-10 05:08:37','Alice Adminson',''),(36,'2020-01-10 01:08:43','PAYMENT_VARIOUS_MODIFY',10.00000000,'02ecc274221832fcbf8f525ed64f1391415a29dded01022a5a4c51cfb2c5ad49','c274f2f609af56bd40b74000eaa2f6866a734feb0fc262ce3431ac9f91a754e2','payment_various',4,'4','2020-01-10 00:00:00','O:8:\"stdClass\":7:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:3:\"ref\";s:1:\"4\";s:4:\"date\";i:1578600000;s:9:\"type_code\";s:0:\"\";s:11:\"payment_num\";s:0:\"\";s:4:\"note\";s:0:\"\";s:6:\"amount\";d:10;}',12,1,0,'2020-01-10 05:08:43','Alice Adminson',''),(37,'2020-01-10 01:17:51','PAYMENT_VARIOUS_MODIFY',10.00000000,'214ad5673f893c2da41a8c87ccbcae92dccf17c9d4a13b3d04a9497d21bf68b8','ffbebb278eaa1c75f0cf5afdd05c8367887615a7329f2b3ab628b8f0da10f9d8','payment_various',4,'4','2020-01-10 00:00:00','O:8:\"stdClass\":7:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:3:\"ref\";s:1:\"4\";s:4:\"date\";i:1578600000;s:9:\"type_code\";s:0:\"\";s:11:\"payment_num\";s:0:\"\";s:4:\"note\";s:0:\"\";s:6:\"amount\";d:10;}',12,1,0,'2020-01-10 05:17:51','Alice Adminson',''),(38,'2020-01-16 01:22:16','BILL_VALIDATE',123.00000000,'aae0a1eb8b3da6686020252194f47ce82301fb604ee213ae120a2885197735d5','b414061da9abbd2dec7153a7d53978c177c5c5f55ed8ace177a02e46e7a74312','facture',221,'AC2001-0001','2020-01-16 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:16:\"Magic Food Store\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:22:\"65 holdywood boulevard\";s:3:\"zip\";s:6:\"123456\";s:4:\"town\";s:7:\"BigTown\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";s:4:\"0101\";s:5:\"email\";s:18:\"myemail@domain.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:10:\"10/10/2010\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1301-0008\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"ES\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1579129200;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"3\";s:8:\"total_ht\";d:123;s:9:\"total_tva\";d:0;s:9:\"total_ttc\";d:123;s:12:\"revenuestamp\";s:10:\"0.00000000\";s:11:\"invoiceline\";a:1:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:12:\"123.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.00000000\";s:23:\"multicurrency_total_ttc\";s:12:\"123.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"0.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:12:\"123.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:12:\"123.00000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"AC2001-0001\";s:11:\"note_public\";N;}',12,1,0,'2020-01-16 02:22:16','Alice Adminson',''),(39,'2020-01-16 01:33:27','BILL_VALIDATE',20.50000000,'777eb88a0b91c6d376881534a7c84a9b9ee5a6d7efedbae3b0c00d7e36bacba9','b78e5b5909c49c575142b429f2d09abb2d19c5545f815a1cabe0f2ed80ded6e4','facture',224,'AC2001-0002','2020-01-16 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:16:\"Magic Food Store\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:22:\"65 holdywood boulevard\";s:3:\"zip\";s:6:\"123456\";s:4:\"town\";s:7:\"BigTown\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";s:4:\"0101\";s:5:\"email\";s:18:\"myemail@domain.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:10:\"10/10/2010\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1301-0008\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"ES\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1579129200;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"3\";s:8:\"total_ht\";d:20.5;s:9:\"total_tva\";d:0;s:9:\"total_ttc\";d:20.5;s:12:\"revenuestamp\";s:10:\"0.00000000\";s:11:\"invoiceline\";a:1:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"20.50000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.00000000\";s:23:\"multicurrency_total_ttc\";s:11:\"20.50000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"0.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"20.50000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"20.50000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"AC2001-0002\";s:11:\"note_public\";N;}',12,1,0,'2020-01-16 02:33:27','Alice Adminson',''),(40,'2020-01-16 01:36:48','PAYMENT_CUSTOMER_CREATE',20.50000000,'cb03ceef89e1630e5a3ba8b3b1ca6c77e42b97fc2884a661c04e9e5c8b3afa1e','18bed0f0566b20ffa32c49c901cfc8b46485ef2172b22c676cef07ce8bd2d90b','payment',40,'PAY2001-0006','2020-01-16 12:00:00','O:8:\"stdClass\":8:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:3:\"ref\";s:12:\"PAY2001-0006\";s:4:\"date\";i:1579172400;s:9:\"type_code\";s:3:\"VIR\";s:11:\"payment_num\";N;s:4:\"note\";s:0:\"\";s:12:\"payment_part\";a:1:{i:1;O:8:\"stdClass\":3:{s:6:\"amount\";s:4:\"20.5\";s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:16:\"Magic Food Store\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:22:\"65 holdywood boulevard\";s:3:\"zip\";s:6:\"123456\";s:4:\"town\";s:7:\"BigTown\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";s:4:\"0101\";s:5:\"email\";s:18:\"myemail@domain.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:10:\"10/10/2010\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1301-0008\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"ES\";}s:7:\"invoice\";O:8:\"stdClass\":9:{s:4:\"date\";i:1579129200;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"3\";s:8:\"total_ht\";s:11:\"20.50000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"20.50000000\";s:12:\"revenuestamp\";s:10:\"0.00000000\";s:3:\"ref\";s:11:\"AC2001-0002\";s:11:\"note_public\";N;}}}s:6:\"amount\";d:20.5;}',12,1,0,'2020-01-16 02:36:48','Alice Adminson',''),(41,'2020-01-19 13:51:43','BILL_VALIDATE',239.20000000,'7f38eaf315003f652b72fd27e55e71010a5ed0339086aa100b9a91a6045bb06f','26d074106c5f096ea1795ce7ed399cda6c2b2d5ac78dd9c2e152a0a0aa6ef47b','facture',227,'AC2001-0003','2020-01-19 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:10:\"Indian SAS\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:13:\"1 alalah road\";s:3:\"zip\";N;s:4:\"town\";s:5:\"Delhi\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";N;s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:13:\"5000.00000000\";s:11:\"typent_code\";s:8:\"TE_SMALL\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1212-0007\";s:16:\"code_fournisseur\";s:11:\"SU1212-0005\";s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1579388400;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"3\";s:8:\"total_ht\";d:200;s:9:\"total_tva\";d:39.2;s:9:\"total_ttc\";d:239.2;s:12:\"revenuestamp\";s:10:\"0.00000000\";s:11:\"invoiceline\";a:1:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:12:\"200.00000000\";s:23:\"multicurrency_total_tva\";s:11:\"39.20000000\";s:23:\"multicurrency_total_ttc\";s:12:\"239.20000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:6:\"19.600\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:12:\"200.00000000\";s:9:\"total_tva\";s:11:\"39.20000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:12:\"239.20000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"AC2001-0003\";s:11:\"note_public\";N;}',12,1,0,'2020-01-19 14:51:43','Alice Adminson',''),(42,'2020-01-19 14:01:26','BILL_VALIDATE',50.54000000,'107572ffe2f1ccf1ee4fe7b39c5a4ed40a485c1d37c926fbff8a0e420396d641','352ac5e380c996d7bff798c1369f8a85e86cc98a2864e278cbe0cb6b309c12a5','facture',228,'AC2001-0004','2020-01-19 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:10:\"Indian SAS\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:13:\"1 alalah road\";s:3:\"zip\";N;s:4:\"town\";s:5:\"Delhi\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";N;s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:13:\"5000.00000000\";s:11:\"typent_code\";s:8:\"TE_SMALL\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1212-0007\";s:16:\"code_fournisseur\";s:11:\"SU1212-0005\";s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1579388400;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"3\";s:8:\"total_ht\";d:48.6;s:9:\"total_tva\";d:1.94;s:9:\"total_ttc\";d:50.54;s:12:\"revenuestamp\";s:10:\"0.00000000\";s:11:\"invoiceline\";a:2:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"50.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"2.00000000\";s:23:\"multicurrency_total_ttc\";s:11:\"52.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"4.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"50.00000000\";s:9:\"total_tva\";s:10:\"2.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"52.00000000\";s:9:\"info_bits\";s:1:\"0\";}i:2;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"-1.40000000\";s:23:\"multicurrency_total_tva\";s:11:\"-0.06000000\";s:23:\"multicurrency_total_ttc\";s:11:\"-1.46000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"4.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"-1.40000000\";s:9:\"total_tva\";s:11:\"-0.06000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"-1.46000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"AC2001-0004\";s:11:\"note_public\";N;}',12,1,0,'2020-01-19 15:01:26','Alice Adminson',''),(43,'2020-01-19 14:04:53','BILL_VALIDATE',50.54000000,'795f9c5b741f360e3194ac8b3bb163c244b2761125f7507935baa44b319c624a','8cbb81e210f60d71b33a7fdcae0202721c2b4a8cdd59fe77ff2a8942839159b4','facture',228,'AC2001-0004','2020-01-19 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:10:\"Indian SAS\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:13:\"1 alalah road\";s:3:\"zip\";N;s:4:\"town\";s:5:\"Delhi\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";N;s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:13:\"5000.00000000\";s:11:\"typent_code\";s:8:\"TE_SMALL\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1212-0007\";s:16:\"code_fournisseur\";s:11:\"SU1212-0005\";s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1579388400;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"3\";s:8:\"total_ht\";d:48.6;s:9:\"total_tva\";d:1.94;s:9:\"total_ttc\";d:50.54;s:12:\"revenuestamp\";s:10:\"0.00000000\";s:11:\"invoiceline\";a:2:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"50.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"2.00000000\";s:23:\"multicurrency_total_ttc\";s:11:\"52.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"4.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"50.00000000\";s:9:\"total_tva\";s:10:\"2.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"52.00000000\";s:9:\"info_bits\";s:1:\"0\";}i:2;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"-1.40000000\";s:23:\"multicurrency_total_tva\";s:11:\"-0.06000000\";s:23:\"multicurrency_total_ttc\";s:11:\"-1.46000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"4.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"-1.40000000\";s:9:\"total_tva\";s:11:\"-0.06000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"-1.46000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"AC2001-0004\";s:11:\"note_public\";N;}',12,1,0,'2020-01-19 15:04:53','Alice Adminson',''),(44,'2020-01-19 14:13:07','BILL_VALIDATE',50.54000000,'0c5b79703d1db88579a1fdb74053596defebddb7a1e6d4c5c8b065729be10201','41669e482d1e5e7a58c132c2bf85bc75372cadb4d9b97047a98cc74a9d1fd767','facture',228,'AC2001-0004','2020-01-19 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:10:\"Indian SAS\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:13:\"1 alalah road\";s:3:\"zip\";N;s:4:\"town\";s:5:\"Delhi\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";N;s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:13:\"5000.00000000\";s:11:\"typent_code\";s:8:\"TE_SMALL\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1212-0007\";s:16:\"code_fournisseur\";s:11:\"SU1212-0005\";s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1579388400;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"3\";s:8:\"total_ht\";d:48.6;s:9:\"total_tva\";d:1.94;s:9:\"total_ttc\";d:50.54;s:12:\"revenuestamp\";s:10:\"0.00000000\";s:11:\"invoiceline\";a:2:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"50.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"2.00000000\";s:23:\"multicurrency_total_ttc\";s:11:\"52.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"4.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"50.00000000\";s:9:\"total_tva\";s:10:\"2.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"52.00000000\";s:9:\"info_bits\";s:1:\"0\";}i:2;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"-1.40000000\";s:23:\"multicurrency_total_tva\";s:11:\"-0.06000000\";s:23:\"multicurrency_total_ttc\";s:11:\"-1.46000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"4.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"-1.40000000\";s:9:\"total_tva\";s:11:\"-0.06000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"-1.46000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"AC2001-0004\";s:11:\"note_public\";N;}',12,1,0,'2020-01-19 15:13:07','Alice Adminson',''),(46,'2020-01-21 00:02:14','MEMBER_SUBSCRIPTION_CREATE',50.00000000,'aacdc952cc25b2d4f90222cea6f684320c76477e55b87687397d82e70694c517','ce99e3278ebb1f5f2540a0d7205a4b1230e2e23c4bed48b567433b34786b88e4','subscription',2,'','2013-07-18 00:00:00','O:8:\"stdClass\":10:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:5:\"datec\";i:1579564934;s:5:\"dateh\";i:1374098400;s:5:\"datef\";i:1405548000;s:11:\"fk_adherent\";s:1:\"3\";s:6:\"amount\";s:2:\"50\";s:2:\"id\";i:2;s:10:\"import_key\";N;s:6:\"statut\";N;s:4:\"note\";s:17:\"Subscription 2013\";}',12,1,0,'2020-01-21 01:02:14','Alice Adminson',''),(47,'2020-01-21 09:22:37','MEMBER_SUBSCRIPTION_CREATE',50.00000000,'43a9804c627e78b20c7842a563099892a2d464b207f96bb393886f0b0ea52b4a','c6befc858191e428330c0054328f84d09f7be0f5603fb5b15e3a59980bb8e6eb','subscription',3,'','2017-07-18 00:00:00','O:8:\"stdClass\":10:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:5:\"datec\";i:1579598557;s:5:\"dateh\";i:1500328800;s:5:\"datef\";i:1531778400;s:11:\"fk_adherent\";s:1:\"4\";s:6:\"amount\";s:2:\"50\";s:2:\"id\";i:3;s:10:\"import_key\";N;s:6:\"statut\";N;s:4:\"note\";s:17:\"Subscription 2017\";}',12,1,0,'2020-01-21 10:22:37','Alice Adminson',''),(48,'2020-01-21 09:23:17','MEMBER_SUBSCRIPTION_CREATE',50.00000000,'d44357a1d55ffedd8f24690cd3c8aa43f9bfd33aa362ad558fd486b3b7f62a50','7c32d13e68bb245ab06b8e11efa5ed9e5fdb15650265dc80d5cb00d4674c134d','subscription',4,'','2017-07-18 00:00:00','O:8:\"stdClass\":10:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:5:\"datec\";i:1579598597;s:5:\"dateh\";i:1500328800;s:5:\"datef\";i:1531778400;s:11:\"fk_adherent\";s:1:\"2\";s:6:\"amount\";s:2:\"50\";s:2:\"id\";i:4;s:10:\"import_key\";N;s:6:\"statut\";N;s:4:\"note\";s:17:\"Subscription 2017\";}',12,1,0,'2020-01-21 10:23:17','Alice Adminson',''),(49,'2020-01-21 09:23:17','BILL_VALIDATE',50.00000000,'30d0b37723f3cd2fce6afefd56cbdeb90f7cdee0e898e6ebaa411d84d3123ca0','e0301b9c4da11aa095a90cd9989b9fb6d0c635263cb2a8998b4ba57b60751d11','facture',229,'FA1707-0026','2017-07-18 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"Dupont Alain\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:0:\"\";s:3:\"zip\";N;s:4:\"town\";N;s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";s:18:\"pcurie@example.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1601-0019\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:0:\"\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1500328800;s:10:\"ref_client\";s:0:\"\";s:4:\"type\";i:0;s:8:\"total_ht\";d:50;s:9:\"total_tva\";d:0;s:9:\"total_ttc\";d:50;s:12:\"revenuestamp\";N;s:11:\"invoiceline\";a:1:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"50.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.00000000\";s:23:\"multicurrency_total_ttc\";s:11:\"50.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"1\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"0.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"50.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"50.00000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"FA1707-0026\";s:11:\"note_public\";s:0:\"\";}',12,1,0,'2020-01-21 10:23:17','Alice Adminson',''),(50,'2020-01-21 09:23:17','PAYMENT_CUSTOMER_CREATE',50.00000000,'41e6e00dfd2b96c3d9056489f22241959407ad0282405d37ada32da919e2d744','625ed1ef1ab9edddabc0b1588542eb6eac30ac9224e75812dabcbdfa0211b918','payment',41,'PAY2001-0007','2020-01-21 00:00:00','O:8:\"stdClass\":8:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:3:\"ref\";s:12:\"PAY2001-0007\";s:4:\"date\";i:1579561200;s:9:\"type_code\";s:3:\"CHQ\";s:11:\"payment_num\";s:0:\"\";s:4:\"note\";N;s:12:\"payment_part\";a:1:{i:1;O:8:\"stdClass\":3:{s:6:\"amount\";s:2:\"50\";s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"Dupont Alain\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:0:\"\";s:3:\"zip\";N;s:4:\"town\";N;s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";s:18:\"pcurie@example.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1601-0019\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:0:\"\";}s:7:\"invoice\";O:8:\"stdClass\":9:{s:4:\"date\";i:1500328800;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"0\";s:8:\"total_ht\";s:11:\"50.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"50.00000000\";s:12:\"revenuestamp\";s:10:\"0.00000000\";s:3:\"ref\";s:11:\"FA1707-0026\";s:11:\"note_public\";N;}}}s:6:\"amount\";i:50;}',12,1,0,'2020-01-21 10:23:17','Alice Adminson',''),(51,'2020-01-21 09:23:28','MEMBER_SUBSCRIPTION_CREATE',50.00000000,'b24dfe36f8a3e5971898dd4fcfc61d775d4f0937169f44986bc9478d189e8e60','6160f4fb0fe73ce769a03f9d5460db7051602796090b9e44b51c6eadbd63c309','subscription',5,'','2018-07-18 00:00:00','O:8:\"stdClass\":10:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:5:\"datec\";i:1579598608;s:5:\"dateh\";i:1531864800;s:5:\"datef\";i:1563314400;s:11:\"fk_adherent\";s:1:\"2\";s:6:\"amount\";s:2:\"50\";s:2:\"id\";i:5;s:10:\"import_key\";N;s:6:\"statut\";N;s:4:\"note\";s:17:\"Subscription 2018\";}',12,1,0,'2020-01-21 10:23:28','Alice Adminson',''),(52,'2020-01-21 09:23:28','BILL_VALIDATE',50.00000000,'a6ba6c4518b94977daa8a65b6e9063e81b37563037455ee4608724674c53ea01','3724c09a72bbaab46bdde59c79ffd5d439ffb43f2a509c49ebe05aa9acdcda7a','facture',230,'FA1807-0027','2018-07-18 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"Dupont Alain\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:0:\"\";s:3:\"zip\";N;s:4:\"town\";N;s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";s:18:\"pcurie@example.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1601-0019\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:0:\"\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1531864800;s:10:\"ref_client\";s:0:\"\";s:4:\"type\";i:0;s:8:\"total_ht\";d:50;s:9:\"total_tva\";d:0;s:9:\"total_ttc\";d:50;s:12:\"revenuestamp\";N;s:11:\"invoiceline\";a:1:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"50.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.00000000\";s:23:\"multicurrency_total_ttc\";s:11:\"50.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"1\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"0.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"50.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"50.00000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"FA1807-0027\";s:11:\"note_public\";s:0:\"\";}',12,1,0,'2020-01-21 10:23:28','Alice Adminson',''),(53,'2020-01-21 09:23:28','PAYMENT_CUSTOMER_CREATE',50.00000000,'54bbe038c35a0b1f63cccfbd89ce3232fc5dff8a56e7ff33bffebb9f412827bc','444449d4566c78f70a64b92d0008e9ddc933be75326cebdf5d41c4a94acdddc4','payment',42,'PAY2001-0008','2020-01-21 00:00:00','O:8:\"stdClass\":8:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:3:\"ref\";s:12:\"PAY2001-0008\";s:4:\"date\";i:1579561200;s:9:\"type_code\";s:3:\"CHQ\";s:11:\"payment_num\";s:0:\"\";s:4:\"note\";N;s:12:\"payment_part\";a:1:{i:1;O:8:\"stdClass\":3:{s:6:\"amount\";s:2:\"50\";s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"Dupont Alain\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:0:\"\";s:3:\"zip\";N;s:4:\"town\";N;s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";s:18:\"pcurie@example.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1601-0019\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:0:\"\";}s:7:\"invoice\";O:8:\"stdClass\":9:{s:4:\"date\";i:1531864800;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"0\";s:8:\"total_ht\";s:11:\"50.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"50.00000000\";s:12:\"revenuestamp\";s:10:\"0.00000000\";s:3:\"ref\";s:11:\"FA1807-0027\";s:11:\"note_public\";N;}}}s:6:\"amount\";i:50;}',12,1,0,'2020-01-21 10:23:28','Alice Adminson',''),(54,'2020-01-21 09:23:49','MEMBER_SUBSCRIPTION_CREATE',50.00000000,'c4b9d402ebf74ae10353550d9ef1ce08c899b6533bdc5434fa105599da3e28ce','4642f26ec597360d7616ed0d925080970614232397fc17022922eecad2e727c9','subscription',6,'','2019-07-18 00:00:00','O:8:\"stdClass\":10:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:5:\"datec\";i:1579598629;s:5:\"dateh\";i:1563400800;s:5:\"datef\";i:1594936800;s:11:\"fk_adherent\";s:1:\"2\";s:6:\"amount\";s:2:\"50\";s:2:\"id\";i:6;s:10:\"import_key\";N;s:6:\"statut\";N;s:4:\"note\";s:17:\"Subscription 2019\";}',12,1,0,'2020-01-21 10:23:49','Alice Adminson',''),(55,'2020-01-21 09:23:49','BILL_VALIDATE',50.00000000,'3e7b2c3b0b26c1982a3f8205b48a68756d81cd5bb673e1d2c7c09ce12c2086b9','ca332254195c3a59ee8c2ed0c60aec16a4229e83f5138f69747e65136ad370fa','facture',231,'FA1907-0028','2019-07-18 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"Dupont Alain\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:0:\"\";s:3:\"zip\";N;s:4:\"town\";N;s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";s:18:\"pcurie@example.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1601-0019\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:0:\"\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1563400800;s:10:\"ref_client\";s:0:\"\";s:4:\"type\";i:0;s:8:\"total_ht\";d:50;s:9:\"total_tva\";d:0;s:9:\"total_ttc\";d:50;s:12:\"revenuestamp\";N;s:11:\"invoiceline\";a:1:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"50.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.00000000\";s:23:\"multicurrency_total_ttc\";s:11:\"50.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"1\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"0.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"50.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"50.00000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"FA1907-0028\";s:11:\"note_public\";s:0:\"\";}',12,1,0,'2020-01-21 10:23:49','Alice Adminson',''),(56,'2020-01-21 09:23:49','PAYMENT_CUSTOMER_CREATE',50.00000000,'87cab3c0d2443145bb01b7364b78917756b2bf9b7908355b1a3258c28ecf1400','966571aa0fe244a6e762172fff34c03610ba4066f6f95369f514076c97975b6b','payment',43,'PAY2001-0009','2020-01-21 00:00:00','O:8:\"stdClass\":8:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:3:\"ref\";s:12:\"PAY2001-0009\";s:4:\"date\";i:1579561200;s:9:\"type_code\";s:2:\"CB\";s:11:\"payment_num\";s:0:\"\";s:4:\"note\";N;s:12:\"payment_part\";a:1:{i:1;O:8:\"stdClass\":3:{s:6:\"amount\";s:2:\"50\";s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"Dupont Alain\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:0:\"\";s:3:\"zip\";N;s:4:\"town\";N;s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";s:18:\"pcurie@example.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1601-0019\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:0:\"\";}s:7:\"invoice\";O:8:\"stdClass\":9:{s:4:\"date\";i:1563400800;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"0\";s:8:\"total_ht\";s:11:\"50.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"50.00000000\";s:12:\"revenuestamp\";s:10:\"0.00000000\";s:3:\"ref\";s:11:\"FA1907-0028\";s:11:\"note_public\";N;}}}s:6:\"amount\";i:50;}',12,1,0,'2020-01-21 10:23:49','Alice Adminson',''),(57,'2020-01-21 09:33:28','MODULE_RESET',0.00000000,'0000000000','d8134616ec977d8204a6856269ccfc799ea7eccc80074ac62350a5cdee3b070b','module',1,'systemevent','2020-01-21 10:33:28','O:8:\"stdClass\":6:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:2:\"id\";i:1;s:7:\"element\";s:6:\"module\";s:3:\"ref\";s:11:\"systemevent\";s:6:\"entity\";i:1;s:4:\"date\";i:1579599208;}',12,1,0,'2020-01-21 10:33:28','Alice Adminson',''),(58,'2020-12-10 12:31:17','MODULE_SET',0.00000000,'1f651fa26c45e58ae8303d336a35eddef44c398d225744ad49f803355cdadb43','dce54650a53002c6dc3dbffad2600c13ce08d19b5fa23811b8d2a31d75ac6a60','module',1,'systemevent','2020-12-10 13:31:17','O:8:\"stdClass\":6:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:2:\"id\";i:1;s:7:\"element\";s:6:\"module\";s:3:\"ref\";s:11:\"systemevent\";s:6:\"entity\";s:1:\"1\";s:4:\"date\";i:1607603477;}',12,1,0,'2020-12-10 13:31:17','Alice Adminson',''); +INSERT INTO `llx_blockedlog` VALUES (20,'2018-03-16 09:57:22','MODULE_RESET',0.00000000,'d6dd5fe6c2eec2de6368f3b6da30188566f0a1a7be4b1589ccd8352d2c827ad5','fbc11d0396d9b76ea48f892bd5f0fe652e5bdf7d44873acb4bf1e1b70352bd30','module',1,'systemevent','2018-03-16 13:57:22','O:8:\"stdClass\":6:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:10:\"name_alias\";N;s:7:\"address\";s:24:\"21 Jump street..ll..ee \"\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";N;s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:1:\"1\";s:7:\"idprof3\";s:1:\"1\";s:7:\"idprof4\";s:1:\"1\";s:7:\"idprof5\";s:1:\"1\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:9:\"FR1234567\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";s:4:\"name\";s:12:\"MyBigCompany\";}s:2:\"id\";i:1;s:7:\"element\";s:6:\"module\";s:3:\"ref\";s:11:\"systemevent\";s:6:\"entity\";i:1;s:4:\"date\";i:1521194242;}',12,1,0,'2018-03-16 13:57:22','Alice Adminson',''),(21,'2018-03-16 09:57:24','MODULE_SET',0.00000000,'d6b66df837d8d33bd8b9744e2afa46ab8c65ae8ca462246c406de19f8254e146','0a3aae975056417705f4eb7b4a4926384075cc2b6c899603715643c8f1d6ff9b','module',1,'systemevent','2018-03-16 13:57:24','O:8:\"stdClass\":6:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:10:\"name_alias\";N;s:7:\"address\";s:24:\"21 Jump street..ll..ee \"\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";N;s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:1:\"1\";s:7:\"idprof3\";s:1:\"1\";s:7:\"idprof4\";s:1:\"1\";s:7:\"idprof5\";s:1:\"1\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:9:\"FR1234567\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";s:4:\"name\";s:12:\"MyBigCompany\";}s:2:\"id\";i:1;s:7:\"element\";s:6:\"module\";s:3:\"ref\";s:11:\"systemevent\";s:6:\"entity\";i:1;s:4:\"date\";i:1521194244;}',12,1,0,'2018-03-16 13:57:24','Alice Adminson',''),(22,'2018-03-16 09:59:31','PAYMENT_CUSTOMER_CREATE',10.00000000,'9beb9e3ba04582d441b49f176f995900c16572c789bcf48a1c9f285a74be76c8','86813eb2563252c0e270baaf1fffade82475fe51af5f88d14613005fd0e07783','payment',38,'PAY1803-0004','2018-03-16 12:00:00','O:8:\"stdClass\":8:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:10:\"name_alias\";N;s:7:\"address\";s:24:\"21 Jump street..ll..ee \"\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";N;s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:1:\"1\";s:7:\"idprof3\";s:1:\"1\";s:7:\"idprof4\";s:1:\"1\";s:7:\"idprof5\";s:1:\"1\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:9:\"FR1234567\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";s:4:\"name\";s:12:\"MyBigCompany\";}s:3:\"ref\";s:12:\"PAY1803-0004\";s:4:\"date\";i:1521187200;s:9:\"type_code\";s:3:\"CHQ\";s:11:\"payment_num\";N;s:4:\"note\";s:0:\"\";s:12:\"payment_part\";a:1:{i:1;O:8:\"stdClass\":3:{s:6:\"amount\";s:2:\"10\";s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:13:\"1 alalah road\";s:3:\"zip\";N;s:4:\"town\";s:5:\"Delhi\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";N;s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:13:\"5000.00000000\";s:11:\"typent_code\";s:8:\"TE_SMALL\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1212-0007\";s:16:\"code_fournisseur\";s:11:\"SU1212-0005\";s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";s:4:\"name\";s:10:\"Indian SAS\";}s:7:\"invoice\";O:8:\"stdClass\":9:{s:4:\"date\";i:1453147200;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"0\";s:8:\"total_ht\";s:11:\"20.00000000\";s:9:\"total_tva\";s:10:\"1.80000000\";s:9:\"total_ttc\";s:11:\"23.60000000\";s:12:\"revenuestamp\";s:10:\"0.00000000\";s:3:\"ref\";s:11:\"FA1601-0024\";s:11:\"note_public\";N;}}}s:6:\"amount\";i:10;}',12,1,0,'2018-03-16 13:59:31','Alice Adminson',''),(23,'2019-09-26 15:33:37','BILL_VALIDATE',43.58000000,'6a1e049c00f51afa6eaca799e6281bd8abfdaa12bdf42ee2a002b0bec588a2a5','451b12ea66d25259c9c1df9993a902affe124c9f27c97093613cf7184fe388aa','facture',218,'FA1909-0025','2019-09-26 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"Dupont Alain\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:0:\"\";s:3:\"zip\";N;s:4:\"town\";N;s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";s:18:\"pcurie@example.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1601-0019\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:0:\"\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:24:\"21 Jump street..ll..ee \"\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";N;s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1569448800;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"0\";s:8:\"total_ht\";d:42.5;s:9:\"total_tva\";d:1.08;s:9:\"total_ttc\";d:43.58;s:12:\"revenuestamp\";s:10:\"0.00000000\";s:11:\"invoiceline\";a:5:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";s:9:\"DOLICLOUD\";s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:10:\"9.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.00000000\";s:23:\"multicurrency_total_ttc\";s:10:\"9.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"1\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"0.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:10:\"9.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:10:\"9.00000000\";s:9:\"info_bits\";s:1:\"0\";}i:2;O:8:\"stdClass\":17:{s:3:\"ref\";s:9:\"DOLIDROID\";s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:10:\"5.50000000\";s:23:\"multicurrency_total_tva\";s:10:\"1.08000000\";s:23:\"multicurrency_total_ttc\";s:10:\"6.58000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:6:\"19.600\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:10:\"5.50000000\";s:9:\"total_tva\";s:10:\"1.08000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:10:\"6.58000000\";s:9:\"info_bits\";s:1:\"0\";}i:3;O:8:\"stdClass\":17:{s:3:\"ref\";s:9:\"DOLICLOUD\";s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:10:\"9.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.00000000\";s:23:\"multicurrency_total_ttc\";s:10:\"9.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"1\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"0.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:10:\"9.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:10:\"9.00000000\";s:9:\"info_bits\";s:1:\"0\";}i:4;O:8:\"stdClass\":17:{s:3:\"ref\";s:9:\"DOLICLOUD\";s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:10:\"9.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.00000000\";s:23:\"multicurrency_total_ttc\";s:10:\"9.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"1\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"0.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:10:\"9.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:10:\"9.00000000\";s:9:\"info_bits\";s:1:\"0\";}i:5;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"10.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.00000000\";s:23:\"multicurrency_total_ttc\";s:11:\"10.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"0.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"10.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"10.00000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"FA1909-0025\";s:11:\"note_public\";N;}',12,1,0,'2019-09-26 17:33:37','Alice Adminson',''),(24,'2019-10-04 08:27:00','BILL_VALIDATE',5.63000000,'aa16d46e6ea7376fe0f91a4aeb7b1d534ed351fae071ded64c393e61269c4c35','316e03ffb8327d837c8601e7dbafc91509581b0be9449a89827a14e6cfa2688a','facture',150,'FA6801-0010','2018-01-19 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:10:\"Indian SAS\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:13:\"1 alalah road\";s:3:\"zip\";N;s:4:\"town\";s:5:\"Delhi\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";N;s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:13:\"5000.00000000\";s:11:\"typent_code\";s:8:\"TE_SMALL\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1212-0007\";s:16:\"code_fournisseur\";s:11:\"SU1212-0005\";s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:24:\"21 Jump street..ll..ee \"\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";N;s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1516316400;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"0\";s:8:\"total_ht\";d:5;s:9:\"total_tva\";d:0.63;s:9:\"total_ttc\";d:5.63;s:12:\"revenuestamp\";s:10:\"0.00000000\";s:11:\"invoiceline\";a:1:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";s:7:\"PEARPIE\";s:18:\"multicurrency_code\";N;s:22:\"multicurrency_total_ht\";s:10:\"5.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.63000000\";s:23:\"multicurrency_total_ttc\";s:10:\"5.63000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:6:\"12.500\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:10:\"5.00000000\";s:9:\"total_tva\";s:10:\"0.63000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:10:\"5.63000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"FA6801-0010\";s:11:\"note_public\";N;}',12,1,0,'2019-10-04 10:27:00','Alice Adminson',''),(25,'2019-10-04 08:28:14','PAYMENT_CUSTOMER_CREATE',5.63000000,'fa5c9b4bb975af8401744390d47e62218a7ec47a2e96c60f5e58d7f6be38dc44','9bfe069dc130dd71c31f914ff0afa7835fd40932790ac88be0005638342ccb87','payment',39,'PAY1801-0005','2018-01-19 12:00:00','O:8:\"stdClass\":8:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:24:\"21 Jump street..ll..ee \"\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";N;s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:3:\"ref\";s:12:\"PAY1801-0005\";s:4:\"date\";i:1516359600;s:9:\"type_code\";s:3:\"LIQ\";s:11:\"payment_num\";N;s:4:\"note\";s:0:\"\";s:12:\"payment_part\";a:1:{i:1;O:8:\"stdClass\":3:{s:6:\"amount\";s:4:\"5.63\";s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:10:\"Indian SAS\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:13:\"1 alalah road\";s:3:\"zip\";N;s:4:\"town\";s:5:\"Delhi\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";N;s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:13:\"5000.00000000\";s:11:\"typent_code\";s:8:\"TE_SMALL\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1212-0007\";s:16:\"code_fournisseur\";s:11:\"SU1212-0005\";s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:7:\"invoice\";O:8:\"stdClass\":9:{s:4:\"date\";i:1516316400;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"0\";s:8:\"total_ht\";s:10:\"5.00000000\";s:9:\"total_tva\";s:10:\"0.63000000\";s:9:\"total_ttc\";s:10:\"5.63000000\";s:12:\"revenuestamp\";s:10:\"0.00000000\";s:3:\"ref\";s:11:\"FA6801-0010\";s:11:\"note_public\";N;}}}s:6:\"amount\";d:5.63;}',12,1,0,'2019-10-04 10:28:14','Alice Adminson',''),(26,'2019-12-22 19:01:48','CASHCONTROL_VALIDATE',400.00000000,'bb14150a5ea65d97f9d22f6bc3d3d357ccfb2aa681f2ecbcc81a9d870260c58c','7b03131558731b2e7b4000189214b132f4323621c596d4418cfeba233a085e83','cashcontrol',1,'1','2019-12-22 23:01:02','O:8:\"stdClass\":37:{s:9:\"mycompany\";O:8:\"stdClass\":26:{s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:0;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:0;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;}s:7:\"element\";s:11:\"cashcontrol\";s:2:\"id\";i:1;s:7:\"opening\";d:-324.29;s:6:\"status\";i:1;s:10:\"year_close\";i:2019;s:11:\"month_close\";i:11;s:9:\"day_close\";N;s:9:\"posmodule\";s:7:\"takepos\";s:9:\"posnumber\";s:1:\"1\";s:4:\"cash\";d:400;s:6:\"cheque\";d:0;s:4:\"card\";d:0;s:10:\"date_valid\";i:1577041308;s:13:\"date_creation\";i:1577041262;s:17:\"date_modification\";N;s:10:\"import_key\";N;s:13:\"array_options\";a:0:{}s:6:\"canvas\";N;s:7:\"project\";N;s:10:\"fk_project\";N;s:10:\"thirdparty\";N;s:4:\"user\";N;s:3:\"ref\";s:1:\"1\";s:7:\"ref_ext\";N;s:6:\"statut\";N;s:10:\"fk_account\";N;s:11:\"note_public\";N;s:12:\"note_private\";N;s:4:\"note\";N;s:8:\"comments\";a:0:{}s:15:\"date_validation\";N;s:16:\"next_prev_filter\";N;s:6:\"entity\";i:1;s:5:\"label\";N;s:3:\"tms\";i:1577030462;s:13:\"fk_user_valid\";s:2:\"12\";}',12,1,0,'2019-12-22 23:01:48','Alice Adminson',''),(34,'2020-01-10 00:42:47','PAYMENT_VARIOUS_CREATE',10.00000000,'e20ec32652d7564cdca915e95528b68bd3b770b82defe64ead1af3f6dc6bc150','25514deeca716e41c02699d9466fc640f4b7da0a0c953637b542c555f9634f9b','payment_various',4,'4','2020-01-10 12:00:00','O:8:\"stdClass\":7:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:3:\"ref\";i:4;s:4:\"date\";i:1578643200;s:9:\"type_code\";s:3:\"VIR\";s:11:\"payment_num\";s:0:\"\";s:4:\"note\";s:0:\"\";s:6:\"amount\";i:10;}',12,1,0,'2020-01-10 04:42:47','Alice Adminson',''),(35,'2020-01-10 01:08:37','PAYMENT_VARIOUS_MODIFY',10.00000000,'94bd3491e8e553e6e633cd4a40c8c0ef3a6af0bd60df1d8e768d3c8c2a37b79b','eeadf2ffc7bd611e3b739e8825307f9e9cb2d9dddbd9e16b1f092fa5d881a5ca','payment_various',4,'4','2020-01-10 00:00:00','O:8:\"stdClass\":7:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:3:\"ref\";s:1:\"4\";s:4:\"date\";i:1578600000;s:9:\"type_code\";s:3:\"VIR\";s:11:\"payment_num\";s:0:\"\";s:4:\"note\";s:0:\"\";s:6:\"amount\";d:10;}',12,1,0,'2020-01-10 05:08:37','Alice Adminson',''),(36,'2020-01-10 01:08:43','PAYMENT_VARIOUS_MODIFY',10.00000000,'02ecc274221832fcbf8f525ed64f1391415a29dded01022a5a4c51cfb2c5ad49','c274f2f609af56bd40b74000eaa2f6866a734feb0fc262ce3431ac9f91a754e2','payment_various',4,'4','2020-01-10 00:00:00','O:8:\"stdClass\":7:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:3:\"ref\";s:1:\"4\";s:4:\"date\";i:1578600000;s:9:\"type_code\";s:0:\"\";s:11:\"payment_num\";s:0:\"\";s:4:\"note\";s:0:\"\";s:6:\"amount\";d:10;}',12,1,0,'2020-01-10 05:08:43','Alice Adminson',''),(37,'2020-01-10 01:17:51','PAYMENT_VARIOUS_MODIFY',10.00000000,'214ad5673f893c2da41a8c87ccbcae92dccf17c9d4a13b3d04a9497d21bf68b8','ffbebb278eaa1c75f0cf5afdd05c8367887615a7329f2b3ab628b8f0da10f9d8','payment_various',4,'4','2020-01-10 00:00:00','O:8:\"stdClass\":7:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:3:\"ref\";s:1:\"4\";s:4:\"date\";i:1578600000;s:9:\"type_code\";s:0:\"\";s:11:\"payment_num\";s:0:\"\";s:4:\"note\";s:0:\"\";s:6:\"amount\";d:10;}',12,1,0,'2020-01-10 05:17:51','Alice Adminson',''),(38,'2020-01-16 01:22:16','BILL_VALIDATE',123.00000000,'aae0a1eb8b3da6686020252194f47ce82301fb604ee213ae120a2885197735d5','b414061da9abbd2dec7153a7d53978c177c5c5f55ed8ace177a02e46e7a74312','facture',221,'AC2001-0001','2020-01-16 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:16:\"Magic Food Store\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:22:\"65 holdywood boulevard\";s:3:\"zip\";s:6:\"123456\";s:4:\"town\";s:7:\"BigTown\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";s:4:\"0101\";s:5:\"email\";s:18:\"myemail@domain.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:10:\"10/10/2010\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1301-0008\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"ES\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1579129200;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"3\";s:8:\"total_ht\";d:123;s:9:\"total_tva\";d:0;s:9:\"total_ttc\";d:123;s:12:\"revenuestamp\";s:10:\"0.00000000\";s:11:\"invoiceline\";a:1:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:12:\"123.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.00000000\";s:23:\"multicurrency_total_ttc\";s:12:\"123.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"0.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:12:\"123.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:12:\"123.00000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"AC2001-0001\";s:11:\"note_public\";N;}',12,1,0,'2020-01-16 02:22:16','Alice Adminson',''),(39,'2020-01-16 01:33:27','BILL_VALIDATE',20.50000000,'777eb88a0b91c6d376881534a7c84a9b9ee5a6d7efedbae3b0c00d7e36bacba9','b78e5b5909c49c575142b429f2d09abb2d19c5545f815a1cabe0f2ed80ded6e4','facture',224,'AC2001-0002','2020-01-16 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:16:\"Magic Food Store\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:22:\"65 holdywood boulevard\";s:3:\"zip\";s:6:\"123456\";s:4:\"town\";s:7:\"BigTown\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";s:4:\"0101\";s:5:\"email\";s:18:\"myemail@domain.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:10:\"10/10/2010\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1301-0008\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"ES\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1579129200;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"3\";s:8:\"total_ht\";d:20.5;s:9:\"total_tva\";d:0;s:9:\"total_ttc\";d:20.5;s:12:\"revenuestamp\";s:10:\"0.00000000\";s:11:\"invoiceline\";a:1:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"20.50000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.00000000\";s:23:\"multicurrency_total_ttc\";s:11:\"20.50000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"0.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"20.50000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"20.50000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"AC2001-0002\";s:11:\"note_public\";N;}',12,1,0,'2020-01-16 02:33:27','Alice Adminson',''),(40,'2020-01-16 01:36:48','PAYMENT_CUSTOMER_CREATE',20.50000000,'cb03ceef89e1630e5a3ba8b3b1ca6c77e42b97fc2884a661c04e9e5c8b3afa1e','18bed0f0566b20ffa32c49c901cfc8b46485ef2172b22c676cef07ce8bd2d90b','payment',40,'PAY2001-0006','2020-01-16 12:00:00','O:8:\"stdClass\":8:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:3:\"ref\";s:12:\"PAY2001-0006\";s:4:\"date\";i:1579172400;s:9:\"type_code\";s:3:\"VIR\";s:11:\"payment_num\";N;s:4:\"note\";s:0:\"\";s:12:\"payment_part\";a:1:{i:1;O:8:\"stdClass\":3:{s:6:\"amount\";s:4:\"20.5\";s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:16:\"Magic Food Store\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:22:\"65 holdywood boulevard\";s:3:\"zip\";s:6:\"123456\";s:4:\"town\";s:7:\"BigTown\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";s:4:\"0101\";s:5:\"email\";s:18:\"myemail@domain.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:10:\"10/10/2010\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1301-0008\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"ES\";}s:7:\"invoice\";O:8:\"stdClass\":9:{s:4:\"date\";i:1579129200;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"3\";s:8:\"total_ht\";s:11:\"20.50000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"20.50000000\";s:12:\"revenuestamp\";s:10:\"0.00000000\";s:3:\"ref\";s:11:\"AC2001-0002\";s:11:\"note_public\";N;}}}s:6:\"amount\";d:20.5;}',12,1,0,'2020-01-16 02:36:48','Alice Adminson',''),(41,'2020-01-19 13:51:43','BILL_VALIDATE',239.20000000,'7f38eaf315003f652b72fd27e55e71010a5ed0339086aa100b9a91a6045bb06f','26d074106c5f096ea1795ce7ed399cda6c2b2d5ac78dd9c2e152a0a0aa6ef47b','facture',227,'AC2001-0003','2020-01-19 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:10:\"Indian SAS\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:13:\"1 alalah road\";s:3:\"zip\";N;s:4:\"town\";s:5:\"Delhi\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";N;s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:13:\"5000.00000000\";s:11:\"typent_code\";s:8:\"TE_SMALL\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1212-0007\";s:16:\"code_fournisseur\";s:11:\"SU1212-0005\";s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1579388400;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"3\";s:8:\"total_ht\";d:200;s:9:\"total_tva\";d:39.2;s:9:\"total_ttc\";d:239.2;s:12:\"revenuestamp\";s:10:\"0.00000000\";s:11:\"invoiceline\";a:1:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:12:\"200.00000000\";s:23:\"multicurrency_total_tva\";s:11:\"39.20000000\";s:23:\"multicurrency_total_ttc\";s:12:\"239.20000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:6:\"19.600\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:12:\"200.00000000\";s:9:\"total_tva\";s:11:\"39.20000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:12:\"239.20000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"AC2001-0003\";s:11:\"note_public\";N;}',12,1,0,'2020-01-19 14:51:43','Alice Adminson',''),(42,'2020-01-19 14:01:26','BILL_VALIDATE',50.54000000,'107572ffe2f1ccf1ee4fe7b39c5a4ed40a485c1d37c926fbff8a0e420396d641','352ac5e380c996d7bff798c1369f8a85e86cc98a2864e278cbe0cb6b309c12a5','facture',228,'AC2001-0004','2020-01-19 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:10:\"Indian SAS\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:13:\"1 alalah road\";s:3:\"zip\";N;s:4:\"town\";s:5:\"Delhi\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";N;s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:13:\"5000.00000000\";s:11:\"typent_code\";s:8:\"TE_SMALL\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1212-0007\";s:16:\"code_fournisseur\";s:11:\"SU1212-0005\";s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1579388400;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"3\";s:8:\"total_ht\";d:48.6;s:9:\"total_tva\";d:1.94;s:9:\"total_ttc\";d:50.54;s:12:\"revenuestamp\";s:10:\"0.00000000\";s:11:\"invoiceline\";a:2:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"50.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"2.00000000\";s:23:\"multicurrency_total_ttc\";s:11:\"52.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"4.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"50.00000000\";s:9:\"total_tva\";s:10:\"2.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"52.00000000\";s:9:\"info_bits\";s:1:\"0\";}i:2;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"-1.40000000\";s:23:\"multicurrency_total_tva\";s:11:\"-0.06000000\";s:23:\"multicurrency_total_ttc\";s:11:\"-1.46000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"4.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"-1.40000000\";s:9:\"total_tva\";s:11:\"-0.06000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"-1.46000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"AC2001-0004\";s:11:\"note_public\";N;}',12,1,0,'2020-01-19 15:01:26','Alice Adminson',''),(43,'2020-01-19 14:04:53','BILL_VALIDATE',50.54000000,'795f9c5b741f360e3194ac8b3bb163c244b2761125f7507935baa44b319c624a','8cbb81e210f60d71b33a7fdcae0202721c2b4a8cdd59fe77ff2a8942839159b4','facture',228,'AC2001-0004','2020-01-19 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:10:\"Indian SAS\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:13:\"1 alalah road\";s:3:\"zip\";N;s:4:\"town\";s:5:\"Delhi\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";N;s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:13:\"5000.00000000\";s:11:\"typent_code\";s:8:\"TE_SMALL\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1212-0007\";s:16:\"code_fournisseur\";s:11:\"SU1212-0005\";s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1579388400;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"3\";s:8:\"total_ht\";d:48.6;s:9:\"total_tva\";d:1.94;s:9:\"total_ttc\";d:50.54;s:12:\"revenuestamp\";s:10:\"0.00000000\";s:11:\"invoiceline\";a:2:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"50.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"2.00000000\";s:23:\"multicurrency_total_ttc\";s:11:\"52.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"4.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"50.00000000\";s:9:\"total_tva\";s:10:\"2.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"52.00000000\";s:9:\"info_bits\";s:1:\"0\";}i:2;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"-1.40000000\";s:23:\"multicurrency_total_tva\";s:11:\"-0.06000000\";s:23:\"multicurrency_total_ttc\";s:11:\"-1.46000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"4.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"-1.40000000\";s:9:\"total_tva\";s:11:\"-0.06000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"-1.46000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"AC2001-0004\";s:11:\"note_public\";N;}',12,1,0,'2020-01-19 15:04:53','Alice Adminson',''),(44,'2020-01-19 14:13:07','BILL_VALIDATE',50.54000000,'0c5b79703d1db88579a1fdb74053596defebddb7a1e6d4c5c8b065729be10201','41669e482d1e5e7a58c132c2bf85bc75372cadb4d9b97047a98cc74a9d1fd767','facture',228,'AC2001-0004','2020-01-19 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:10:\"Indian SAS\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:13:\"1 alalah road\";s:3:\"zip\";N;s:4:\"town\";s:5:\"Delhi\";s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";N;s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:13:\"5000.00000000\";s:11:\"typent_code\";s:8:\"TE_SMALL\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1212-0007\";s:16:\"code_fournisseur\";s:11:\"SU1212-0005\";s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1579388400;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"3\";s:8:\"total_ht\";d:48.6;s:9:\"total_tva\";d:1.94;s:9:\"total_ttc\";d:50.54;s:12:\"revenuestamp\";s:10:\"0.00000000\";s:11:\"invoiceline\";a:2:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"50.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"2.00000000\";s:23:\"multicurrency_total_ttc\";s:11:\"52.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"4.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"50.00000000\";s:9:\"total_tva\";s:10:\"2.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"52.00000000\";s:9:\"info_bits\";s:1:\"0\";}i:2;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"-1.40000000\";s:23:\"multicurrency_total_tva\";s:11:\"-0.06000000\";s:23:\"multicurrency_total_ttc\";s:11:\"-1.46000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"0\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"4.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"-1.40000000\";s:9:\"total_tva\";s:11:\"-0.06000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"-1.46000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"AC2001-0004\";s:11:\"note_public\";N;}',12,1,0,'2020-01-19 15:13:07','Alice Adminson',''),(46,'2020-01-21 00:02:14','MEMBER_SUBSCRIPTION_CREATE',50.00000000,'aacdc952cc25b2d4f90222cea6f684320c76477e55b87687397d82e70694c517','ce99e3278ebb1f5f2540a0d7205a4b1230e2e23c4bed48b567433b34786b88e4','subscription',2,'','2013-07-18 00:00:00','O:8:\"stdClass\":10:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:5:\"datec\";i:1579564934;s:5:\"dateh\";i:1374098400;s:5:\"datef\";i:1405548000;s:11:\"fk_adherent\";s:1:\"3\";s:6:\"amount\";s:2:\"50\";s:2:\"id\";i:2;s:10:\"import_key\";N;s:6:\"statut\";N;s:4:\"note\";s:17:\"Subscription 2013\";}',12,1,0,'2020-01-21 01:02:14','Alice Adminson',''),(47,'2020-01-21 09:22:37','MEMBER_SUBSCRIPTION_CREATE',50.00000000,'43a9804c627e78b20c7842a563099892a2d464b207f96bb393886f0b0ea52b4a','c6befc858191e428330c0054328f84d09f7be0f5603fb5b15e3a59980bb8e6eb','subscription',3,'','2017-07-18 00:00:00','O:8:\"stdClass\":10:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:5:\"datec\";i:1579598557;s:5:\"dateh\";i:1500328800;s:5:\"datef\";i:1531778400;s:11:\"fk_adherent\";s:1:\"4\";s:6:\"amount\";s:2:\"50\";s:2:\"id\";i:3;s:10:\"import_key\";N;s:6:\"statut\";N;s:4:\"note\";s:17:\"Subscription 2017\";}',12,1,0,'2020-01-21 10:22:37','Alice Adminson',''),(48,'2020-01-21 09:23:17','MEMBER_SUBSCRIPTION_CREATE',50.00000000,'d44357a1d55ffedd8f24690cd3c8aa43f9bfd33aa362ad558fd486b3b7f62a50','7c32d13e68bb245ab06b8e11efa5ed9e5fdb15650265dc80d5cb00d4674c134d','subscription',4,'','2017-07-18 00:00:00','O:8:\"stdClass\":10:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:5:\"datec\";i:1579598597;s:5:\"dateh\";i:1500328800;s:5:\"datef\";i:1531778400;s:11:\"fk_adherent\";s:1:\"2\";s:6:\"amount\";s:2:\"50\";s:2:\"id\";i:4;s:10:\"import_key\";N;s:6:\"statut\";N;s:4:\"note\";s:17:\"Subscription 2017\";}',12,1,0,'2020-01-21 10:23:17','Alice Adminson',''),(49,'2020-01-21 09:23:17','BILL_VALIDATE',50.00000000,'30d0b37723f3cd2fce6afefd56cbdeb90f7cdee0e898e6ebaa411d84d3123ca0','e0301b9c4da11aa095a90cd9989b9fb6d0c635263cb2a8998b4ba57b60751d11','facture',229,'FA1707-0026','2017-07-18 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"Dupont Alain\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:0:\"\";s:3:\"zip\";N;s:4:\"town\";N;s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";s:18:\"pcurie@example.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1601-0019\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:0:\"\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1500328800;s:10:\"ref_client\";s:0:\"\";s:4:\"type\";i:0;s:8:\"total_ht\";d:50;s:9:\"total_tva\";d:0;s:9:\"total_ttc\";d:50;s:12:\"revenuestamp\";N;s:11:\"invoiceline\";a:1:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"50.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.00000000\";s:23:\"multicurrency_total_ttc\";s:11:\"50.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"1\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"0.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"50.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"50.00000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"FA1707-0026\";s:11:\"note_public\";s:0:\"\";}',12,1,0,'2020-01-21 10:23:17','Alice Adminson',''),(50,'2020-01-21 09:23:17','PAYMENT_CUSTOMER_CREATE',50.00000000,'41e6e00dfd2b96c3d9056489f22241959407ad0282405d37ada32da919e2d744','625ed1ef1ab9edddabc0b1588542eb6eac30ac9224e75812dabcbdfa0211b918','payment',41,'PAY2001-0007','2020-01-21 00:00:00','O:8:\"stdClass\":8:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:3:\"ref\";s:12:\"PAY2001-0007\";s:4:\"date\";i:1579561200;s:9:\"type_code\";s:3:\"CHQ\";s:11:\"payment_num\";s:0:\"\";s:4:\"note\";N;s:12:\"payment_part\";a:1:{i:1;O:8:\"stdClass\":3:{s:6:\"amount\";s:2:\"50\";s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"Dupont Alain\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:0:\"\";s:3:\"zip\";N;s:4:\"town\";N;s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";s:18:\"pcurie@example.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1601-0019\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:0:\"\";}s:7:\"invoice\";O:8:\"stdClass\":9:{s:4:\"date\";i:1500328800;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"0\";s:8:\"total_ht\";s:11:\"50.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"50.00000000\";s:12:\"revenuestamp\";s:10:\"0.00000000\";s:3:\"ref\";s:11:\"FA1707-0026\";s:11:\"note_public\";N;}}}s:6:\"amount\";i:50;}',12,1,0,'2020-01-21 10:23:17','Alice Adminson',''),(51,'2020-01-21 09:23:28','MEMBER_SUBSCRIPTION_CREATE',50.00000000,'b24dfe36f8a3e5971898dd4fcfc61d775d4f0937169f44986bc9478d189e8e60','6160f4fb0fe73ce769a03f9d5460db7051602796090b9e44b51c6eadbd63c309','subscription',5,'','2018-07-18 00:00:00','O:8:\"stdClass\":10:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:5:\"datec\";i:1579598608;s:5:\"dateh\";i:1531864800;s:5:\"datef\";i:1563314400;s:11:\"fk_adherent\";s:1:\"2\";s:6:\"amount\";s:2:\"50\";s:2:\"id\";i:5;s:10:\"import_key\";N;s:6:\"statut\";N;s:4:\"note\";s:17:\"Subscription 2018\";}',12,1,0,'2020-01-21 10:23:28','Alice Adminson',''),(52,'2020-01-21 09:23:28','BILL_VALIDATE',50.00000000,'a6ba6c4518b94977daa8a65b6e9063e81b37563037455ee4608724674c53ea01','3724c09a72bbaab46bdde59c79ffd5d439ffb43f2a509c49ebe05aa9acdcda7a','facture',230,'FA1807-0027','2018-07-18 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"Dupont Alain\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:0:\"\";s:3:\"zip\";N;s:4:\"town\";N;s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";s:18:\"pcurie@example.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1601-0019\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:0:\"\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1531864800;s:10:\"ref_client\";s:0:\"\";s:4:\"type\";i:0;s:8:\"total_ht\";d:50;s:9:\"total_tva\";d:0;s:9:\"total_ttc\";d:50;s:12:\"revenuestamp\";N;s:11:\"invoiceline\";a:1:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"50.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.00000000\";s:23:\"multicurrency_total_ttc\";s:11:\"50.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"1\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"0.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"50.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"50.00000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"FA1807-0027\";s:11:\"note_public\";s:0:\"\";}',12,1,0,'2020-01-21 10:23:28','Alice Adminson',''),(53,'2020-01-21 09:23:28','PAYMENT_CUSTOMER_CREATE',50.00000000,'54bbe038c35a0b1f63cccfbd89ce3232fc5dff8a56e7ff33bffebb9f412827bc','444449d4566c78f70a64b92d0008e9ddc933be75326cebdf5d41c4a94acdddc4','payment',42,'PAY2001-0008','2020-01-21 00:00:00','O:8:\"stdClass\":8:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:3:\"ref\";s:12:\"PAY2001-0008\";s:4:\"date\";i:1579561200;s:9:\"type_code\";s:3:\"CHQ\";s:11:\"payment_num\";s:0:\"\";s:4:\"note\";N;s:12:\"payment_part\";a:1:{i:1;O:8:\"stdClass\":3:{s:6:\"amount\";s:2:\"50\";s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"Dupont Alain\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:0:\"\";s:3:\"zip\";N;s:4:\"town\";N;s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";s:18:\"pcurie@example.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1601-0019\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:0:\"\";}s:7:\"invoice\";O:8:\"stdClass\":9:{s:4:\"date\";i:1531864800;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"0\";s:8:\"total_ht\";s:11:\"50.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"50.00000000\";s:12:\"revenuestamp\";s:10:\"0.00000000\";s:3:\"ref\";s:11:\"FA1807-0027\";s:11:\"note_public\";N;}}}s:6:\"amount\";i:50;}',12,1,0,'2020-01-21 10:23:28','Alice Adminson',''),(54,'2020-01-21 09:23:49','MEMBER_SUBSCRIPTION_CREATE',50.00000000,'c4b9d402ebf74ae10353550d9ef1ce08c899b6533bdc5434fa105599da3e28ce','4642f26ec597360d7616ed0d925080970614232397fc17022922eecad2e727c9','subscription',6,'','2019-07-18 00:00:00','O:8:\"stdClass\":10:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:5:\"datec\";i:1579598629;s:5:\"dateh\";i:1563400800;s:5:\"datef\";i:1594936800;s:11:\"fk_adherent\";s:1:\"2\";s:6:\"amount\";s:2:\"50\";s:2:\"id\";i:6;s:10:\"import_key\";N;s:6:\"statut\";N;s:4:\"note\";s:17:\"Subscription 2019\";}',12,1,0,'2020-01-21 10:23:49','Alice Adminson',''),(55,'2020-01-21 09:23:49','BILL_VALIDATE',50.00000000,'3e7b2c3b0b26c1982a3f8205b48a68756d81cd5bb673e1d2c7c09ce12c2086b9','ca332254195c3a59ee8c2ed0c60aec16a4229e83f5138f69747e65136ad370fa','facture',231,'FA1907-0028','2019-07-18 00:00:00','O:8:\"stdClass\":12:{s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"Dupont Alain\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:0:\"\";s:3:\"zip\";N;s:4:\"town\";N;s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";s:18:\"pcurie@example.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1601-0019\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:0:\"\";}s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:4:\"date\";i:1563400800;s:10:\"ref_client\";s:0:\"\";s:4:\"type\";i:0;s:8:\"total_ht\";d:50;s:9:\"total_tva\";d:0;s:9:\"total_ttc\";d:50;s:12:\"revenuestamp\";N;s:11:\"invoiceline\";a:1:{i:1;O:8:\"stdClass\":17:{s:3:\"ref\";N;s:18:\"multicurrency_code\";s:3:\"EUR\";s:22:\"multicurrency_total_ht\";s:11:\"50.00000000\";s:23:\"multicurrency_total_tva\";s:10:\"0.00000000\";s:23:\"multicurrency_total_ttc\";s:11:\"50.00000000\";s:3:\"qty\";s:1:\"1\";s:12:\"product_type\";s:1:\"1\";s:12:\"vat_src_code\";s:0:\"\";s:6:\"tva_tx\";s:5:\"0.000\";s:12:\"localtax1_tx\";s:5:\"0.000\";s:12:\"localtax2_tx\";s:5:\"0.000\";s:8:\"total_ht\";s:11:\"50.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:15:\"total_localtax1\";s:10:\"0.00000000\";s:15:\"total_localtax2\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"50.00000000\";s:9:\"info_bits\";s:1:\"0\";}}s:3:\"ref\";s:11:\"FA1907-0028\";s:11:\"note_public\";s:0:\"\";}',12,1,0,'2020-01-21 10:23:49','Alice Adminson',''),(56,'2020-01-21 09:23:49','PAYMENT_CUSTOMER_CREATE',50.00000000,'87cab3c0d2443145bb01b7364b78917756b2bf9b7908355b1a3258c28ecf1400','966571aa0fe244a6e762172fff34c03610ba4066f6f95369f514076c97975b6b','payment',43,'PAY2001-0009','2020-01-21 00:00:00','O:8:\"stdClass\":8:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:3:\"ref\";s:12:\"PAY2001-0009\";s:4:\"date\";i:1579561200;s:9:\"type_code\";s:2:\"CB\";s:11:\"payment_num\";s:0:\"\";s:4:\"note\";N;s:12:\"payment_part\";a:1:{i:1;O:8:\"stdClass\":3:{s:6:\"amount\";s:2:\"50\";s:10:\"thirdparty\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"Dupont Alain\";s:10:\"name_alias\";s:0:\"\";s:7:\"address\";s:0:\"\";s:3:\"zip\";N;s:4:\"town\";N;s:10:\"state_code\";N;s:5:\"phone\";N;s:3:\"fax\";N;s:5:\"email\";s:18:\"pcurie@example.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:0:\"\";s:7:\"idprof2\";s:0:\"\";s:7:\"idprof3\";s:0:\"\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:0:\"\";s:15:\"localtax1_assuj\";N;s:15:\"localtax1_value\";s:5:\"0.000\";s:15:\"localtax2_assuj\";N;s:15:\"localtax2_value\";s:5:\"0.000\";s:8:\"managers\";N;s:7:\"capital\";s:10:\"0.00000000\";s:11:\"typent_code\";s:10:\"TE_UNKNOWN\";s:20:\"forme_juridique_code\";N;s:11:\"code_client\";s:11:\"CU1601-0019\";s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:0:\"\";}s:7:\"invoice\";O:8:\"stdClass\":9:{s:4:\"date\";i:1563400800;s:10:\"ref_client\";N;s:4:\"type\";s:1:\"0\";s:8:\"total_ht\";s:11:\"50.00000000\";s:9:\"total_tva\";s:10:\"0.00000000\";s:9:\"total_ttc\";s:11:\"50.00000000\";s:12:\"revenuestamp\";s:10:\"0.00000000\";s:3:\"ref\";s:11:\"FA1907-0028\";s:11:\"note_public\";N;}}}s:6:\"amount\";i:50;}',12,1,0,'2020-01-21 10:23:49','Alice Adminson',''),(57,'2020-01-21 09:33:28','MODULE_RESET',0.00000000,'0000000000','d8134616ec977d8204a6856269ccfc799ea7eccc80074ac62350a5cdee3b070b','module',1,'systemevent','2020-01-21 10:33:28','O:8:\"stdClass\":6:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:2:\"id\";i:1;s:7:\"element\";s:6:\"module\";s:3:\"ref\";s:11:\"systemevent\";s:6:\"entity\";i:1;s:4:\"date\";i:1579599208;}',12,1,0,'2020-01-21 10:33:28','Alice Adminson',''),(58,'2020-12-10 12:31:17','MODULE_SET',0.00000000,'1f651fa26c45e58ae8303d336a35eddef44c398d225744ad49f803355cdadb43','dce54650a53002c6dc3dbffad2600c13ce08d19b5fa23811b8d2a31d75ac6a60','module',1,'systemevent','2020-12-10 13:31:17','O:8:\"stdClass\":6:{s:9:\"mycompany\";O:8:\"stdClass\":29:{s:4:\"name\";s:12:\"MyBigCompany\";s:10:\"name_alias\";N;s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:10:\"state_code\";s:0:\"\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"barcode\";N;s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:7:\"idprof4\";s:0:\"\";s:7:\"idprof5\";s:0:\"\";s:7:\"idprof6\";s:0:\"\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax1_value\";N;s:15:\"localtax2_assuj\";i:1;s:15:\"localtax2_value\";N;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:11:\"typent_code\";N;s:20:\"forme_juridique_code\";s:0:\"\";s:11:\"code_client\";N;s:16:\"code_fournisseur\";N;s:7:\"ref_ext\";N;s:12:\"country_code\";s:2:\"IN\";}s:2:\"id\";i:1;s:7:\"element\";s:6:\"module\";s:3:\"ref\";s:11:\"systemevent\";s:6:\"entity\";s:1:\"1\";s:4:\"date\";i:1607603477;}',12,1,0,'2020-12-10 13:31:17','Alice Adminson',''),(59,'2022-02-07 14:32:49','MODULE_RESET',0.00000000,'0000000000','db6f3715c6f5a84d8f492e5cde34c3055d08ad8a0427229d66190c1de3700c1f','module',1,'systemevent','2022-02-07 14:32:49','O:8:\"stdClass\":6:{s:9:\"mycompany\";O:8:\"stdClass\":16:{s:4:\"name\";s:12:\"MyBigCompany\";s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax2_assuj\";i:1;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:12:\"country_code\";s:2:\"IN\";}s:2:\"id\";i:1;s:7:\"element\";s:6:\"module\";s:3:\"ref\";s:11:\"systemevent\";s:6:\"entity\";i:1;s:4:\"date\";i:1644244369;}',12,1,0,'2022-02-07 14:32:49','Alice Adminson',''),(60,'2022-02-07 14:32:50','MODULE_SET',0.00000000,'3821e87f5e665f473ae8043688893856375f41c0d7c5190c209e45299f4cc4b9','85d0333c46688c956bfe71052640ea882bbef2ad767a6a6b1fcd97dbabdb0539','module',1,'systemevent','2022-02-07 14:32:50','O:8:\"stdClass\":6:{s:9:\"mycompany\";O:8:\"stdClass\":16:{s:4:\"name\";s:12:\"MyBigCompany\";s:7:\"address\";s:15:\"21 Jump street.\";s:3:\"zip\";s:5:\"75500\";s:4:\"town\";s:6:\"MyTown\";s:5:\"phone\";s:8:\"09123123\";s:3:\"fax\";s:8:\"09123124\";s:5:\"email\";s:24:\"myemail@mybigcompany.com\";s:7:\"idprof1\";s:6:\"123456\";s:7:\"idprof2\";s:7:\"ABC-DEF\";s:7:\"idprof3\";s:9:\"15E-45-8D\";s:9:\"tva_intra\";s:10:\"FR12345678\";s:15:\"localtax1_assuj\";i:1;s:15:\"localtax2_assuj\";i:1;s:8:\"managers\";s:10:\"Zack Zeceo\";s:7:\"capital\";s:5:\"10000\";s:12:\"country_code\";s:2:\"IN\";}s:2:\"id\";i:1;s:7:\"element\";s:6:\"module\";s:3:\"ref\";s:11:\"systemevent\";s:6:\"entity\";i:1;s:4:\"date\";i:1644244370;}',12,1,0,'2022-02-07 14:32:50','Alice Adminson',''); /*!40000 ALTER TABLE `llx_blockedlog` ENABLE KEYS */; UNLOCK TABLES; @@ -1152,7 +1143,7 @@ CREATE TABLE `llx_bom_bom` ( KEY `idx_bom_bom_status` (`status`), KEY `idx_bom_bom_fk_product` (`fk_product`), CONSTRAINT `llx_bom_bom_fk_user_creat` FOREIGN KEY (`fk_user_creat`) REFERENCES `llx_user` (`rowid`) -) ENGINE=InnoDB AUTO_INCREMENT=7 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=8 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -1161,7 +1152,7 @@ CREATE TABLE `llx_bom_bom` ( LOCK TABLES `llx_bom_bom` WRITE; /*!40000 ALTER TABLE `llx_bom_bom` DISABLE KEYS */; -INSERT INTO `llx_bom_bom` VALUES (6,1,'BOM1911-0001','BOM For the Home Apple Pie',NULL,NULL,NULL,4,1.00000000,1.0000,'2019-11-28 18:17:12','2020-01-08 15:41:49','2020-01-08 19:41:49',12,12,12,NULL,1,NULL,NULL,'generic_bom_odt:/home/ldestailleur/git/dolibarr_11.0/documents/doctemplates/boms/template_bom.odt',0); +INSERT INTO `llx_bom_bom` VALUES (6,1,'BOM1911-0001','BOM For the Home Apple Pie',NULL,NULL,NULL,4,1.00000000,1.0000,'2019-11-28 18:17:12','2020-01-08 15:41:49','2020-01-08 19:41:49',12,12,12,NULL,1,NULL,NULL,'generic_bom_odt:/home/ldestailleur/git/dolibarr_11.0/documents/doctemplates/boms/template_bom.odt',0),(7,1,'BOM2202-0002','Recycling ABC',NULL,NULL,NULL,11,1.00000000,1.0000,'2022-02-07 13:53:32','2022-02-07 13:54:11','2022-02-07 13:54:11',12,NULL,12,NULL,1,NULL,NULL,NULL,1); /*!40000 ALTER TABLE `llx_bom_bom` ENABLE KEYS */; UNLOCK TABLES; @@ -1215,7 +1206,7 @@ CREATE TABLE `llx_bom_bomline` ( KEY `idx_bom_bomline_fk_product` (`fk_product`), KEY `idx_bom_bomline_fk_bom` (`fk_bom`), CONSTRAINT `llx_bom_bomline_fk_bom` FOREIGN KEY (`fk_bom`) REFERENCES `llx_bom_bom` (`rowid`) -) ENGINE=InnoDB AUTO_INCREMENT=10 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=12 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -1224,7 +1215,7 @@ CREATE TABLE `llx_bom_bomline` ( LOCK TABLES `llx_bom_bomline` WRITE; /*!40000 ALTER TABLE `llx_bom_bomline` DISABLE KEYS */; -INSERT INTO `llx_bom_bomline` VALUES (4,6,25,NULL,NULL,NULL,4.00000000,1.0000,1,0,0),(5,6,3,NULL,NULL,NULL,1.00000000,1.0000,3,0,1),(6,6,2,NULL,NULL,NULL,1.00000000,1.0000,2,1,0),(9,6,1,NULL,NULL,NULL,3.00000000,1.0000,0,0,0); +INSERT INTO `llx_bom_bomline` VALUES (4,6,25,NULL,NULL,NULL,4.00000000,1.0000,1,0,0),(5,6,3,NULL,NULL,NULL,1.00000000,1.0000,3,0,1),(6,6,2,NULL,NULL,NULL,1.00000000,1.0000,2,1,0),(9,6,1,NULL,NULL,NULL,3.00000000,1.0000,0,0,0),(10,7,30,NULL,NULL,NULL,1.00000000,1.0000,2,0,0),(11,7,29,NULL,NULL,NULL,1.00000000,1.0000,4,0,0); /*!40000 ALTER TABLE `llx_bom_bomline` ENABLE KEYS */; UNLOCK TABLES; @@ -1281,7 +1272,7 @@ CREATE TABLE `llx_bookmark` ( LOCK TABLES `llx_bookmark` WRITE; /*!40000 ALTER TABLE `llx_bookmark` DISABLE KEYS */; -INSERT INTO `llx_bookmark` VALUES (1,0,'2012-07-09 01:29:03','http://wiki.dolibarr.org','1','Online documentation','none',1,1),(2,0,'2012-07-09 01:30:15','http://www.dolibarr.org','1','Official portal','none',2,1),(3,0,'2012-07-09 01:30:53','http://www.dolistore.com','1','DoliStore','none',10,1),(4,0,'2012-07-09 01:31:35','http://asso.dolibarr.org/index.php/Main_Page','1','The foundation','none',0,1),(5,0,'2016-03-02 16:40:41','http://www.facebook.com/dolibarr','1','Facebook page','none',50,1),(6,0,'2016-03-02 16:41:12','http://www.twitter.com/dolibarr','1','Twitter channel','none',60,1),(7,0,'2016-03-02 16:42:08','http://plus.google.com/+DolibarrOrg','1','Google+ page','none',55,1); +INSERT INTO `llx_bookmark` VALUES (1,0,'2012-07-09 01:29:03','https://wiki.dolibarr.org','1','Online documentation','none',1,1),(2,0,'2012-07-09 01:30:15','https://www.dolibarr.org','1','Official portal','none',2,1),(3,0,'2012-07-09 01:30:53','https://www.dolistore.com','1','DoliStore','none',10,1),(4,0,'2012-07-09 01:31:35','https://asso.dolibarr.org/index.php/Main_Page','1','The foundation','none',0,1),(5,0,'2016-03-02 16:40:41','https://www.facebook.com/dolibarr','1','Facebook page','none',50,1),(6,0,'2016-03-02 16:41:12','https://www.twitter.com/dolibarr','1','Twitter channel','none',60,1); /*!40000 ALTER TABLE `llx_bookmark` ENABLE KEYS */; UNLOCK TABLES; @@ -1342,7 +1333,7 @@ CREATE TABLE `llx_boxes` ( KEY `idx_boxes_boxid` (`box_id`), KEY `idx_boxes_fk_user` (`fk_user`), CONSTRAINT `fk_boxes_box_id` FOREIGN KEY (`box_id`) REFERENCES `llx_boxes_def` (`rowid`) -) ENGINE=InnoDB AUTO_INCREMENT=1456 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=1459 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -1351,7 +1342,7 @@ CREATE TABLE `llx_boxes` ( LOCK TABLES `llx_boxes` WRITE; /*!40000 ALTER TABLE `llx_boxes` DISABLE KEYS */; -INSERT INTO `llx_boxes` VALUES (253,2,323,0,'0',0,NULL,NULL),(304,2,324,0,'0',0,NULL,NULL),(305,2,325,0,'0',0,NULL,NULL),(306,2,326,0,'0',0,NULL,NULL),(307,2,327,0,'0',0,NULL,NULL),(308,2,328,0,'0',0,NULL,NULL),(309,2,329,0,'0',0,NULL,NULL),(310,2,330,0,'0',0,NULL,NULL),(311,2,331,0,'0',0,NULL,NULL),(312,2,332,0,'0',0,NULL,NULL),(313,2,333,0,'0',0,NULL,NULL),(314,1,347,0,'A27',0,NULL,NULL),(315,1,348,0,'B20',0,NULL,NULL),(316,1,349,0,'B10',0,NULL,NULL),(317,1,350,0,'B18',0,NULL,NULL),(344,1,374,0,'B08',0,NULL,NULL),(347,1,377,0,'B16',0,NULL,NULL),(348,1,378,0,'B06',0,NULL,NULL),(358,1,388,0,'B38',0,NULL,NULL),(359,1,389,0,'A13',0,NULL,NULL),(360,1,390,0,'B36',0,NULL,NULL),(362,1,392,0,'A35',0,NULL,NULL),(363,1,393,0,'A11',0,NULL,NULL),(366,1,396,0,'B12',0,NULL,NULL),(387,1,403,0,'B22',0,NULL,NULL),(392,1,409,0,'A15',0,NULL,NULL),(393,1,410,0,'A33',0,NULL,NULL),(394,1,411,0,'A25',0,NULL,NULL),(395,1,412,0,'B30',0,NULL,NULL),(396,1,413,0,'A23',0,NULL,NULL),(397,1,414,0,'B28',0,NULL,NULL),(398,1,415,0,'A21',0,NULL,NULL),(399,1,416,0,'B26',0,NULL,NULL),(400,1,417,0,'A19',0,NULL,NULL),(401,1,418,0,'B24',0,NULL,NULL),(501,1,419,0,'A17',0,NULL,NULL),(1019,1,392,0,'A01',2,NULL,NULL),(1021,1,412,0,'A03',2,NULL,NULL),(1022,1,347,0,'A04',2,NULL,NULL),(1023,1,393,0,'A05',2,NULL,NULL),(1025,1,389,0,'A07',2,NULL,NULL),(1026,1,416,0,'A08',2,NULL,NULL),(1027,1,396,0,'B01',2,NULL,NULL),(1028,1,377,0,'B02',2,NULL,NULL),(1031,1,419,0,'B05',2,NULL,NULL),(1036,1,424,0,'A29',0,NULL,NULL),(1037,1,425,0,'B32',0,NULL,NULL),(1038,1,426,0,'B34',0,NULL,NULL),(1150,1,430,0,'A37',0,NULL,NULL),(1151,1,431,0,'A05',0,NULL,NULL),(1152,1,429,0,'A01',1,NULL,NULL),(1153,1,429,0,'B01',2,NULL,NULL),(1154,1,429,0,'A01',11,NULL,NULL),(1156,1,429,0,'A07',0,NULL,NULL),(1183,1,433,0,'A09',0,NULL,NULL),(1184,1,434,0,'B14',0,NULL,NULL),(1235,1,404,0,'B01',1,NULL,NULL),(1236,1,404,0,'B01',2,NULL,NULL),(1237,1,404,0,'B01',11,NULL,NULL),(1239,1,404,0,'A31',0,NULL,NULL),(1407,1,412,0,'A01',12,NULL,NULL),(1408,1,378,0,'A02',12,NULL,NULL),(1409,1,404,0,'A03',12,NULL,NULL),(1410,1,377,0,'A04',12,NULL,NULL),(1411,1,392,0,'B01',12,NULL,NULL),(1412,1,429,0,'B02',12,NULL,NULL),(1414,1,414,0,'B04',12,NULL,NULL),(1415,1,413,0,'B05',12,NULL,NULL),(1416,1,426,0,'B06',12,NULL,NULL),(1418,1,445,0,'B02',0,NULL,NULL),(1426,1,450,2,'A01',0,NULL,NULL),(1427,1,451,2,'B01',0,NULL,NULL),(1428,1,452,2,'A01',0,NULL,NULL),(1429,1,453,2,'B01',0,NULL,NULL),(1430,1,454,11,'A01',0,NULL,NULL),(1431,1,455,11,'B01',0,NULL,NULL),(1432,1,456,11,'A01',0,NULL,NULL),(1433,1,457,11,'B01',0,NULL,NULL),(1434,1,461,11,'A01',0,NULL,NULL),(1435,1,462,11,'B01',0,NULL,NULL),(1436,1,448,0,'A01',1,NULL,NULL),(1437,1,448,0,'B01',2,NULL,NULL),(1438,1,448,0,'A01',11,NULL,NULL),(1439,1,448,0,'A01',12,NULL,NULL),(1440,1,448,0,'A01',0,NULL,NULL),(1441,1,449,0,'B01',1,NULL,NULL),(1442,1,449,0,'A01',2,NULL,NULL),(1443,1,449,0,'B01',11,NULL,NULL),(1444,1,449,0,'A01',12,NULL,NULL),(1445,1,449,0,'B01',0,NULL,NULL),(1449,1,452,2,'A01',12,NULL,NULL),(1450,1,451,2,'B01',12,NULL,NULL),(1451,1,450,2,'B02',12,NULL,NULL),(1452,1,453,2,'B03',12,NULL,NULL),(1453,1,467,0,'0',0,NULL,NULL),(1454,1,468,0,'0',0,NULL,NULL),(1455,1,469,0,'0',0,NULL,NULL); +INSERT INTO `llx_boxes` VALUES (253,2,323,0,'0',0,NULL,NULL),(304,2,324,0,'0',0,NULL,NULL),(305,2,325,0,'0',0,NULL,NULL),(306,2,326,0,'0',0,NULL,NULL),(307,2,327,0,'0',0,NULL,NULL),(308,2,328,0,'0',0,NULL,NULL),(309,2,329,0,'0',0,NULL,NULL),(310,2,330,0,'0',0,NULL,NULL),(311,2,331,0,'0',0,NULL,NULL),(312,2,332,0,'0',0,NULL,NULL),(313,2,333,0,'0',0,NULL,NULL),(314,1,347,0,'A27',0,NULL,NULL),(315,1,348,0,'B20',0,NULL,NULL),(316,1,349,0,'B10',0,NULL,NULL),(317,1,350,0,'B18',0,NULL,NULL),(344,1,374,0,'B08',0,NULL,NULL),(347,1,377,0,'B16',0,NULL,NULL),(348,1,378,0,'B06',0,NULL,NULL),(358,1,388,0,'B38',0,NULL,NULL),(359,1,389,0,'A13',0,NULL,NULL),(360,1,390,0,'B36',0,NULL,NULL),(362,1,392,0,'A35',0,NULL,NULL),(363,1,393,0,'A11',0,NULL,NULL),(366,1,396,0,'B12',0,NULL,NULL),(387,1,403,0,'B22',0,NULL,NULL),(392,1,409,0,'A15',0,NULL,NULL),(393,1,410,0,'A33',0,NULL,NULL),(394,1,411,0,'A25',0,NULL,NULL),(395,1,412,0,'B30',0,NULL,NULL),(396,1,413,0,'A23',0,NULL,NULL),(397,1,414,0,'B28',0,NULL,NULL),(398,1,415,0,'A21',0,NULL,NULL),(399,1,416,0,'B26',0,NULL,NULL),(400,1,417,0,'A19',0,NULL,NULL),(401,1,418,0,'B24',0,NULL,NULL),(501,1,419,0,'A17',0,NULL,NULL),(1019,1,392,0,'A01',2,NULL,NULL),(1021,1,412,0,'A03',2,NULL,NULL),(1022,1,347,0,'A04',2,NULL,NULL),(1023,1,393,0,'A05',2,NULL,NULL),(1025,1,389,0,'A07',2,NULL,NULL),(1026,1,416,0,'A08',2,NULL,NULL),(1027,1,396,0,'B01',2,NULL,NULL),(1028,1,377,0,'B02',2,NULL,NULL),(1031,1,419,0,'B05',2,NULL,NULL),(1036,1,424,0,'A29',0,NULL,NULL),(1037,1,425,0,'B32',0,NULL,NULL),(1038,1,426,0,'B34',0,NULL,NULL),(1150,1,430,0,'A37',0,NULL,NULL),(1151,1,431,0,'A05',0,NULL,NULL),(1152,1,429,0,'A01',1,NULL,NULL),(1153,1,429,0,'B01',2,NULL,NULL),(1154,1,429,0,'A01',11,NULL,NULL),(1156,1,429,0,'A07',0,NULL,NULL),(1183,1,433,0,'A09',0,NULL,NULL),(1184,1,434,0,'B14',0,NULL,NULL),(1235,1,404,0,'B01',1,NULL,NULL),(1236,1,404,0,'B01',2,NULL,NULL),(1237,1,404,0,'B01',11,NULL,NULL),(1239,1,404,0,'A31',0,NULL,NULL),(1407,1,412,0,'A01',12,NULL,NULL),(1408,1,378,0,'A02',12,NULL,NULL),(1409,1,404,0,'A03',12,NULL,NULL),(1410,1,377,0,'A04',12,NULL,NULL),(1411,1,392,0,'B01',12,NULL,NULL),(1412,1,429,0,'B02',12,NULL,NULL),(1414,1,414,0,'B04',12,NULL,NULL),(1415,1,413,0,'B05',12,NULL,NULL),(1416,1,426,0,'B06',12,NULL,NULL),(1418,1,445,0,'B02',0,NULL,NULL),(1426,1,450,2,'A01',0,NULL,NULL),(1427,1,451,2,'B01',0,NULL,NULL),(1428,1,452,2,'A01',0,NULL,NULL),(1429,1,453,2,'B01',0,NULL,NULL),(1430,1,454,11,'A01',0,NULL,NULL),(1431,1,455,11,'B01',0,NULL,NULL),(1432,1,456,11,'A01',0,NULL,NULL),(1433,1,457,11,'B01',0,NULL,NULL),(1434,1,461,11,'A01',0,NULL,NULL),(1435,1,462,11,'B01',0,NULL,NULL),(1436,1,448,0,'A01',1,NULL,NULL),(1437,1,448,0,'B01',2,NULL,NULL),(1438,1,448,0,'A01',11,NULL,NULL),(1439,1,448,0,'A01',12,NULL,NULL),(1440,1,448,0,'A01',0,NULL,NULL),(1441,1,449,0,'B01',1,NULL,NULL),(1442,1,449,0,'A01',2,NULL,NULL),(1443,1,449,0,'B01',11,NULL,NULL),(1444,1,449,0,'A01',12,NULL,NULL),(1445,1,449,0,'B01',0,NULL,NULL),(1449,1,452,2,'A01',12,NULL,NULL),(1450,1,451,2,'B01',12,NULL,NULL),(1451,1,450,2,'B02',12,NULL,NULL),(1452,1,453,2,'B03',12,NULL,NULL),(1456,1,474,0,'0',0,NULL,NULL),(1457,1,475,0,'0',0,NULL,NULL),(1458,1,476,0,'0',0,NULL,NULL); /*!40000 ALTER TABLE `llx_boxes` ENABLE KEYS */; UNLOCK TABLES; @@ -1370,7 +1361,7 @@ CREATE TABLE `llx_boxes_def` ( `note` varchar(130) COLLATE utf8_unicode_ci DEFAULT NULL, PRIMARY KEY (`rowid`), UNIQUE KEY `uk_boxes_def` (`file`,`entity`,`note`) -) ENGINE=InnoDB AUTO_INCREMENT=474 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=477 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -1379,7 +1370,7 @@ CREATE TABLE `llx_boxes_def` ( LOCK TABLES `llx_boxes_def` WRITE; /*!40000 ALTER TABLE `llx_boxes_def` DISABLE KEYS */; -INSERT INTO `llx_boxes_def` VALUES (323,'box_actions.php',2,'2015-03-13 15:29:19',NULL),(324,'box_clients.php',2,'2015-03-13 20:21:35',NULL),(325,'box_prospect.php',2,'2015-03-13 20:21:35',NULL),(326,'box_contacts.php',2,'2015-03-13 20:21:35',NULL),(327,'box_activity.php',2,'2015-03-13 20:21:35','(WarningUsingThisBoxSlowDown)'),(328,'box_propales.php',2,'2015-03-13 20:32:38',NULL),(329,'box_comptes.php',2,'2015-03-13 20:33:09',NULL),(330,'box_factures_imp.php',2,'2015-03-13 20:33:09',NULL),(331,'box_factures.php',2,'2015-03-13 20:33:09',NULL),(332,'box_produits.php',2,'2015-03-13 20:33:09',NULL),(333,'box_produits_alerte_stock.php',2,'2015-03-13 20:33:09',NULL),(347,'box_clients.php',1,'2017-11-15 22:05:57',NULL),(348,'box_prospect.php',1,'2017-11-15 22:05:57',NULL),(349,'box_contacts.php',1,'2017-11-15 22:05:57',NULL),(350,'box_activity.php',1,'2017-11-15 22:05:57','(WarningUsingThisBoxSlowDown)'),(374,'box_services_contracts.php',1,'2017-11-15 22:38:37',NULL),(377,'box_project.php',1,'2017-11-15 22:38:44',NULL),(378,'box_task.php',1,'2017-11-15 22:38:44',NULL),(388,'box_contracts.php',1,'2017-11-15 22:39:52',NULL),(389,'box_services_expired.php',1,'2017-11-15 22:39:52',NULL),(390,'box_ficheinter.php',1,'2017-11-15 22:39:56',NULL),(392,'box_graph_propales_permonth.php',1,'2017-11-15 22:41:47',NULL),(393,'box_propales.php',1,'2017-11-15 22:41:47',NULL),(396,'box_graph_product_distribution.php',1,'2017-11-15 22:41:47',NULL),(403,'box_goodcustomers.php',1,'2018-07-30 11:13:20','(WarningUsingThisBoxSlowDown)'),(404,'box_external_rss.php',1,'2018-07-30 11:15:25','1 (Dolibarr.org News)'),(409,'box_produits.php',1,'2018-07-30 13:38:11',NULL),(410,'box_produits_alerte_stock.php',1,'2018-07-30 13:38:11',NULL),(411,'box_commandes.php',1,'2018-07-30 13:38:11',NULL),(412,'box_graph_orders_permonth.php',1,'2018-07-30 13:38:11',NULL),(413,'box_graph_invoices_supplier_permonth.php',1,'2018-07-30 13:38:11',NULL),(414,'box_graph_orders_supplier_permonth.php',1,'2018-07-30 13:38:11',NULL),(415,'box_fournisseurs.php',1,'2018-07-30 13:38:11',NULL),(416,'box_factures_fourn_imp.php',1,'2018-07-30 13:38:11',NULL),(417,'box_factures_fourn.php',1,'2018-07-30 13:38:11',NULL),(418,'box_supplier_orders.php',1,'2018-07-30 13:38:11',NULL),(419,'box_actions.php',1,'2018-07-30 15:42:32',NULL),(424,'box_factures_imp.php',1,'2017-02-07 18:56:12',NULL),(425,'box_factures.php',1,'2017-02-07 18:56:12',NULL),(426,'box_graph_invoices_permonth.php',1,'2017-02-07 18:56:12',NULL),(429,'box_lastlogin.php',1,'2017-08-27 13:29:14',NULL),(430,'box_bookmarks.php',1,'2018-01-19 11:27:34',NULL),(431,'box_members.php',1,'2018-01-19 11:27:56',NULL),(432,'box_birthdays.php',1,'2019-06-05 08:45:40',NULL),(433,'box_last_ticket',1,'2019-06-05 09:15:29',NULL),(434,'box_last_modified_ticket',1,'2019-06-05 09:15:29',NULL),(436,'box_accountancy_last_manual_entries.php',1,'2019-11-28 11:52:58',NULL),(437,'box_accountancy_suspense_account.php',1,'2019-11-28 11:52:58',NULL),(438,'box_supplier_orders_awaiting_reception.php',1,'2019-11-28 11:52:59',NULL),(445,'box_shipments.php',1,'2020-01-13 14:38:20',NULL),(446,'box_funnel_of_prospection.php',1,'2020-12-10 12:24:40',NULL),(447,'box_customers_outstanding_bill_reached.php',1,'2020-12-10 12:24:40',NULL),(448,'box_scheduled_jobs.php',1,'2021-04-15 10:22:49',NULL),(449,'box_dolibarr_state_board.php',1,'2021-04-15 10:22:54',NULL),(450,'box_members_last_modified.php',1,'2021-04-15 10:22:54',NULL),(451,'box_members_last_subscriptions.php',1,'2021-04-15 10:22:54',NULL),(452,'box_members_subscriptions_by_year.php',1,'2021-04-15 10:22:54',NULL),(453,'box_members_by_type.php',1,'2021-04-15 10:22:54',NULL),(454,'box_graph_ticket_by_severity.php',1,'2021-04-15 10:22:55',NULL),(455,'box_graph_nb_ticket_last_x_days.php',1,'2021-04-15 10:22:55',NULL),(456,'box_graph_nb_tickets_type.php',1,'2021-04-15 10:22:55',NULL),(457,'box_graph_new_vs_close_ticket.php',1,'2021-04-15 10:22:55',NULL),(461,'box_last_ticket.php',1,'2021-04-15 10:23:01',NULL),(462,'box_last_modified_ticket.php',1,'2021-04-15 10:23:01',NULL),(467,'box_boms.php',1,'2021-07-11 17:49:46',NULL),(468,'box_comptes.php',1,'2021-07-11 17:49:46',NULL),(469,'box_mos.php',1,'2021-07-11 17:49:47',NULL),(470,'box_ticket_by_severity.php',1,'2021-07-11 17:49:47',NULL),(471,'box_nb_ticket_last_x_days.php',1,'2021-07-11 17:49:47',NULL),(472,'box_nb_tickets_type.php',1,'2021-07-11 17:49:47',NULL),(473,'box_new_vs_close_ticket.php',1,'2021-07-11 17:49:47',NULL); +INSERT INTO `llx_boxes_def` VALUES (323,'box_actions.php',2,'2015-03-13 15:29:19',NULL),(324,'box_clients.php',2,'2015-03-13 20:21:35',NULL),(325,'box_prospect.php',2,'2015-03-13 20:21:35',NULL),(326,'box_contacts.php',2,'2015-03-13 20:21:35',NULL),(327,'box_activity.php',2,'2015-03-13 20:21:35','(WarningUsingThisBoxSlowDown)'),(328,'box_propales.php',2,'2015-03-13 20:32:38',NULL),(329,'box_comptes.php',2,'2015-03-13 20:33:09',NULL),(330,'box_factures_imp.php',2,'2015-03-13 20:33:09',NULL),(331,'box_factures.php',2,'2015-03-13 20:33:09',NULL),(332,'box_produits.php',2,'2015-03-13 20:33:09',NULL),(333,'box_produits_alerte_stock.php',2,'2015-03-13 20:33:09',NULL),(347,'box_clients.php',1,'2017-11-15 22:05:57',NULL),(348,'box_prospect.php',1,'2017-11-15 22:05:57',NULL),(349,'box_contacts.php',1,'2017-11-15 22:05:57',NULL),(350,'box_activity.php',1,'2017-11-15 22:05:57','(WarningUsingThisBoxSlowDown)'),(374,'box_services_contracts.php',1,'2017-11-15 22:38:37',NULL),(377,'box_project.php',1,'2017-11-15 22:38:44',NULL),(378,'box_task.php',1,'2017-11-15 22:38:44',NULL),(388,'box_contracts.php',1,'2017-11-15 22:39:52',NULL),(389,'box_services_expired.php',1,'2017-11-15 22:39:52',NULL),(390,'box_ficheinter.php',1,'2017-11-15 22:39:56',NULL),(392,'box_graph_propales_permonth.php',1,'2017-11-15 22:41:47',NULL),(393,'box_propales.php',1,'2017-11-15 22:41:47',NULL),(396,'box_graph_product_distribution.php',1,'2017-11-15 22:41:47',NULL),(403,'box_goodcustomers.php',1,'2018-07-30 11:13:20','(WarningUsingThisBoxSlowDown)'),(404,'box_external_rss.php',1,'2018-07-30 11:15:25','1 (Dolibarr.org News)'),(409,'box_produits.php',1,'2018-07-30 13:38:11',NULL),(410,'box_produits_alerte_stock.php',1,'2018-07-30 13:38:11',NULL),(411,'box_commandes.php',1,'2018-07-30 13:38:11',NULL),(412,'box_graph_orders_permonth.php',1,'2018-07-30 13:38:11',NULL),(413,'box_graph_invoices_supplier_permonth.php',1,'2018-07-30 13:38:11',NULL),(414,'box_graph_orders_supplier_permonth.php',1,'2018-07-30 13:38:11',NULL),(415,'box_fournisseurs.php',1,'2018-07-30 13:38:11',NULL),(416,'box_factures_fourn_imp.php',1,'2018-07-30 13:38:11',NULL),(417,'box_factures_fourn.php',1,'2018-07-30 13:38:11',NULL),(418,'box_supplier_orders.php',1,'2018-07-30 13:38:11',NULL),(419,'box_actions.php',1,'2018-07-30 15:42:32',NULL),(424,'box_factures_imp.php',1,'2017-02-07 18:56:12',NULL),(425,'box_factures.php',1,'2017-02-07 18:56:12',NULL),(426,'box_graph_invoices_permonth.php',1,'2017-02-07 18:56:12',NULL),(429,'box_lastlogin.php',1,'2017-08-27 13:29:14',NULL),(430,'box_bookmarks.php',1,'2018-01-19 11:27:34',NULL),(431,'box_members.php',1,'2018-01-19 11:27:56',NULL),(432,'box_birthdays.php',1,'2019-06-05 08:45:40',NULL),(433,'box_last_ticket',1,'2019-06-05 09:15:29',NULL),(434,'box_last_modified_ticket',1,'2019-06-05 09:15:29',NULL),(436,'box_accountancy_last_manual_entries.php',1,'2019-11-28 11:52:58',NULL),(437,'box_accountancy_suspense_account.php',1,'2019-11-28 11:52:58',NULL),(438,'box_supplier_orders_awaiting_reception.php',1,'2019-11-28 11:52:59',NULL),(445,'box_shipments.php',1,'2020-01-13 14:38:20',NULL),(446,'box_funnel_of_prospection.php',1,'2020-12-10 12:24:40',NULL),(447,'box_customers_outstanding_bill_reached.php',1,'2020-12-10 12:24:40',NULL),(448,'box_scheduled_jobs.php',1,'2021-04-15 10:22:49',NULL),(449,'box_dolibarr_state_board.php',1,'2021-04-15 10:22:54',NULL),(450,'box_members_last_modified.php',1,'2021-04-15 10:22:54',NULL),(451,'box_members_last_subscriptions.php',1,'2021-04-15 10:22:54',NULL),(452,'box_members_subscriptions_by_year.php',1,'2021-04-15 10:22:54',NULL),(453,'box_members_by_type.php',1,'2021-04-15 10:22:54',NULL),(454,'box_graph_ticket_by_severity.php',1,'2021-04-15 10:22:55',NULL),(455,'box_graph_nb_ticket_last_x_days.php',1,'2021-04-15 10:22:55',NULL),(456,'box_graph_nb_tickets_type.php',1,'2021-04-15 10:22:55',NULL),(457,'box_graph_new_vs_close_ticket.php',1,'2021-04-15 10:22:55',NULL),(461,'box_last_ticket.php',1,'2021-04-15 10:23:01',NULL),(462,'box_last_modified_ticket.php',1,'2021-04-15 10:23:01',NULL),(470,'box_ticket_by_severity.php',1,'2021-07-11 17:49:47',NULL),(471,'box_nb_ticket_last_x_days.php',1,'2021-07-11 17:49:47',NULL),(472,'box_nb_tickets_type.php',1,'2021-07-11 17:49:47',NULL),(473,'box_new_vs_close_ticket.php',1,'2021-07-11 17:49:47',NULL),(474,'box_boms.php',1,'2022-02-07 13:38:16',NULL),(475,'box_comptes.php',1,'2022-02-07 13:38:16',NULL),(476,'box_mos.php',1,'2022-02-07 13:38:17',NULL); /*!40000 ALTER TABLE `llx_boxes_def` ENABLE KEYS */; UNLOCK TABLES; @@ -1499,7 +1490,7 @@ CREATE TABLE `llx_c_action_trigger` ( PRIMARY KEY (`rowid`), UNIQUE KEY `uk_action_trigger_code` (`code`), KEY `idx_action_trigger_rang` (`rang`) -) ENGINE=InnoDB AUTO_INCREMENT=394 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=407 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -1508,7 +1499,7 @@ CREATE TABLE `llx_c_action_trigger` ( LOCK TABLES `llx_c_action_trigger` WRITE; /*!40000 ALTER TABLE `llx_c_action_trigger` DISABLE KEYS */; -INSERT INTO `llx_c_action_trigger` VALUES (131,'COMPANY_SENTBYMAIL','Mails sent from third party card','Executed when you send email from third party card','societe',1),(132,'COMPANY_CREATE','Third party created','Executed when a third party is created','societe',1),(133,'PROPAL_VALIDATE','Customer proposal validated','Executed when a commercial proposal is validated','propal',2),(134,'PROPAL_SENTBYMAIL','Commercial proposal sent by mail','Executed when a commercial proposal is sent by mail','propal',3),(135,'ORDER_VALIDATE','Customer order validate','Executed when a customer order is validated','commande',4),(136,'ORDER_CLOSE','Customer order classify delivered','Executed when a customer order is set delivered','commande',5),(137,'ORDER_CLASSIFY_BILLED','Customer order classify billed','Executed when a customer order is set to billed','commande',5),(138,'ORDER_CANCEL','Customer order canceled','Executed when a customer order is canceled','commande',5),(139,'ORDER_SENTBYMAIL','Customer order sent by mail','Executed when a customer order is sent by mail ','commande',5),(140,'BILL_VALIDATE','Customer invoice validated','Executed when a customer invoice is approved','facture',6),(141,'BILL_PAYED','Customer invoice payed','Executed when a customer invoice is payed','facture',7),(142,'BILL_CANCEL','Customer invoice canceled','Executed when a customer invoice is conceled','facture',8),(143,'BILL_SENTBYMAIL','Customer invoice sent by mail','Executed when a customer invoice is sent by mail','facture',9),(144,'BILL_UNVALIDATE','Customer invoice unvalidated','Executed when a customer invoice status set back to draft','facture',10),(145,'ORDER_SUPPLIER_VALIDATE','Supplier order validated','Executed when a supplier order is validated','order_supplier',11),(146,'ORDER_SUPPLIER_APPROVE','Supplier order request approved','Executed when a supplier order is approved','order_supplier',12),(147,'ORDER_SUPPLIER_REFUSE','Supplier order request refused','Executed when a supplier order is refused','order_supplier',13),(148,'ORDER_SUPPLIER_SENTBYMAIL','Supplier order sent by mail','Executed when a supplier order is sent by mail','order_supplier',14),(149,'BILL_SUPPLIER_VALIDATE','Supplier invoice validated','Executed when a supplier invoice is validated','invoice_supplier',15),(150,'BILL_SUPPLIER_PAYED','Supplier invoice payed','Executed when a supplier invoice is payed','invoice_supplier',16),(151,'BILL_SUPPLIER_SENTBYMAIL','Supplier invoice sent by mail','Executed when a supplier invoice is sent by mail','invoice_supplier',17),(152,'BILL_SUPPLIER_CANCELED','Supplier invoice cancelled','Executed when a supplier invoice is cancelled','invoice_supplier',17),(153,'CONTRACT_VALIDATE','Contract validated','Executed when a contract is validated','contrat',18),(154,'SHIPPING_VALIDATE','Shipping validated','Executed when a shipping is validated','shipping',20),(155,'SHIPPING_SENTBYMAIL','Shipping sent by mail','Executed when a shipping is sent by mail','shipping',21),(156,'MEMBER_VALIDATE','Member validated','Executed when a member is validated','member',22),(158,'MEMBER_RESILIATE','Member resiliated','Executed when a member is resiliated','member',24),(159,'MEMBER_MODIFY','Member modified','Executed when a member is modified','member',24),(160,'MEMBER_DELETE','Member deleted','Executed when a member is deleted','member',25),(161,'FICHINTER_VALIDATE','Intervention validated','Executed when a intervention is validated','ficheinter',19),(162,'FICHINTER_CLASSIFY_BILLED','Intervention set billed','Executed when a intervention is set to billed (when option FICHINTER_CLASSIFY_BILLED is set)','ficheinter',19),(163,'FICHINTER_CLASSIFY_UNBILLED','Intervention set unbilled','Executed when a intervention is set to unbilled (when option FICHINTER_CLASSIFY_BILLED is set)','ficheinter',19),(164,'FICHINTER_REOPEN','Intervention opened','Executed when a intervention is re-opened','ficheinter',19),(165,'FICHINTER_SENTBYMAIL','Intervention sent by mail','Executed when a intervention is sent by mail','ficheinter',19),(166,'PROJECT_CREATE','Project creation','Executed when a project is created','project',140),(167,'PROPAL_CLOSE_SIGNED','Customer proposal closed signed','Executed when a customer proposal is closed signed','propal',2),(168,'PROPAL_CLOSE_REFUSED','Customer proposal closed refused','Executed when a customer proposal is closed refused','propal',2),(169,'PROPAL_CLASSIFY_BILLED','Customer proposal set billed','Executed when a customer proposal is set to billed','propal',2),(170,'TASK_CREATE','Task created','Executed when a project task is created','project',35),(171,'TASK_MODIFY','Task modified','Executed when a project task is modified','project',36),(172,'TASK_DELETE','Task deleted','Executed when a project task is deleted','project',37),(173,'BILL_SUPPLIER_UNVALIDATE','Supplier invoice unvalidated','Executed when a supplier invoice status is set back to draft','invoice_supplier',15),(174,'PROJECT_MODIFY','Project modified','Executed when a project is modified','project',141),(175,'PROJECT_DELETE','Project deleted','Executed when a project is deleted','project',142),(176,'ORDER_SUPPLIER_CREATE','Supplier order validated','Executed when a supplier order is validated','order_supplier',11),(177,'ORDER_SUPPLIER_SUBMIT','Supplier order request submited','Executed when a supplier order is approved','order_supplier',12),(178,'ORDER_SUPPLIER_RECEIVE','Supplier order request received','Executed when a supplier order is received','order_supplier',12),(179,'ORDER_SUPPLIER_CLASSIFY_BILLED','Supplier order set billed','Executed when a supplier order is set as billed','order_supplier',14),(180,'PRODUCT_CREATE','Product or service created','Executed when a product or sevice is created','product',30),(181,'PRODUCT_MODIFY','Product or service modified','Executed when a product or sevice is modified','product',30),(182,'PRODUCT_DELETE','Product or service deleted','Executed when a product or sevice is deleted','product',30),(183,'EXPENSE_REPORT_CREATE','Expense report created','Executed when an expense report is created','expensereport',201),(185,'EXPENSE_REPORT_VALIDATE','Expense report validated','Executed when an expense report is validated','expensereport',202),(186,'EXPENSE_REPORT_APPROVE','Expense report approved','Executed when an expense report is approved','expensereport',203),(187,'EXPENSE_REPORT_PAID','Expense report billed','Executed when an expense report is set as billed','expensereport',204),(192,'HOLIDAY_CREATE','Leave request created','Executed when a leave request is created','holiday',221),(193,'HOLIDAY_VALIDATE','Leave request validated','Executed when a leave request is validated','holiday',222),(194,'HOLIDAY_APPROVE','Leave request approved','Executed when a leave request is approved','holiday',223),(210,'MEMBER_SENTBYMAIL','Mails sent from member card','Executed when you send email from member card','member',23),(211,'CONTRACT_SENTBYMAIL','Contract sent by mail','Executed when a contract is sent by mail','contrat',18),(212,'PROPOSAL_SUPPLIER_VALIDATE','Price request validated','Executed when a commercial proposal is validated','proposal_supplier',10),(213,'PROPOSAL_SUPPLIER_SENTBYMAIL','Price request sent by mail','Executed when a commercial proposal is sent by mail','proposal_supplier',10),(214,'PROPOSAL_SUPPLIER_CLOSE_SIGNED','Price request closed signed','Executed when a customer proposal is closed signed','proposal_supplier',10),(215,'PROPOSAL_SUPPLIER_CLOSE_REFUSED','Price request closed refused','Executed when a customer proposal is closed refused','proposal_supplier',10),(216,'MEMBER_SUBSCRIPTION_CREATE','Member subscribtion recorded','Executed when a member subscribtion is deleted','member',24),(217,'MEMBER_SUBSCRIPTION_MODIFY','Member subscribtion modified','Executed when a member subscribtion is modified','member',24),(218,'MEMBER_SUBSCRIPTION_DELETE','Member subscribtion deleted','Executed when a member subscribtion is deleted','member',24),(225,'COMPANY_DELETE','Third party deleted','Executed when you delete third party','societe',1),(226,'PROPAL_DELETE','Customer proposal deleted','Executed when a customer proposal is deleted','propal',2),(227,'ORDER_DELETE','Customer order deleted','Executed when a customer order is deleted','commande',5),(228,'BILL_DELETE','Customer invoice deleted','Executed when a customer invoice is deleted','facture',9),(229,'PROPOSAL_SUPPLIER_DELETE','Price request deleted','Executed when a customer proposal delete','proposal_supplier',10),(230,'ORDER_SUPPLIER_DELETE','Supplier order deleted','Executed when a supplier order is deleted','order_supplier',14),(231,'BILL_SUPPLIER_DELETE','Supplier invoice deleted','Executed when a supplier invoice is deleted','invoice_supplier',17),(232,'CONTRACT_DELETE','Contract deleted','Executed when a contract is deleted','contrat',18),(233,'FICHINTER_DELETE','Intervention is deleted','Executed when a intervention is deleted','ficheinter',35),(234,'EXPENSE_REPORT_DELETE','Expense report deleted','Executed when an expense report is deleted','expensereport',204),(249,'TICKET_CREATE','Ticket created','Executed when a ticket is created','ticket',161),(250,'TICKET_MODIFY','Ticket modified','Executed when a ticket is modified','ticket',163),(251,'TICKET_ASSIGNED','Ticket assigned','Executed when a ticket is assigned to another user','ticket',164),(252,'TICKET_CLOSE','Ticket closed','Executed when a ticket is closed','ticket',165),(253,'TICKET_SENTBYMAIL','Ticket message sent by email','Executed when a message is sent from the ticket record','ticket',166),(254,'TICKET_DELETE','Ticket deleted','Executed when a ticket is deleted','ticket',167),(261,'USER_SENTBYMAIL','Email sent','Executed when an email is sent from user card','user',300),(262,'BOM_VALIDATE','BOM validated','Executed when a BOM is validated','bom',650),(263,'BOM_UNVALIDATE','BOM unvalidated','Executed when a BOM is unvalidated','bom',651),(264,'BOM_CLOSE','BOM disabled','Executed when a BOM is disabled','bom',652),(265,'BOM_REOPEN','BOM reopen','Executed when a BOM is re-open','bom',653),(266,'BOM_DELETE','BOM deleted','Executed when a BOM deleted','bom',654),(351,'MRP_MO_VALIDATE','MO validated','Executed when a MO is validated','bom',660),(352,'MRP_MO_PRODUCED','MO produced','Executed when a MO is produced','bom',661),(353,'MRP_MO_DELETE','MO deleted','Executed when a MO is deleted','bom',662),(354,'MRP_MO_CANCEL','MO canceled','Executed when a MO is canceled','bom',663),(365,'CONTACT_CREATE','Contact address created','Executed when a contact is created','contact',50),(366,'CONTACT_SENTBYMAIL','Mails sent from third party card','Executed when you send email from contact adress card','contact',51),(367,'CONTACT_DELETE','Contact address deleted','Executed when a contact is deleted','contact',52),(368,'RECRUITMENTJOBPOSITION_CREATE','Job created','Executed when a job is created','recruitment',7500),(369,'RECRUITMENTJOBPOSITION_MODIFY','Job modified','Executed when a job is modified','recruitment',7502),(370,'RECRUITMENTJOBPOSITION_SENTBYMAIL','Mails sent from job record','Executed when you send email from job record','recruitment',7504),(371,'RECRUITMENTJOBPOSITION_DELETE','Job deleted','Executed when a job is deleted','recruitment',7506),(372,'RECRUITMENTCANDIDATURE_CREATE','Candidature created','Executed when a candidature is created','recruitment',7510),(373,'RECRUITMENTCANDIDATURE_MODIFY','Candidature modified','Executed when a candidature is modified','recruitment',7512),(374,'RECRUITMENTCANDIDATURE_SENTBYMAIL','Mails sent from candidature record','Executed when you send email from candidature record','recruitment',7514),(375,'RECRUITMENTCANDIDATURE_DELETE','Candidature deleted','Executed when a candidature is deleted','recruitment',7516),(392,'COMPANY_MODIFY','Third party update','Executed when you update third party','societe',1),(393,'CONTACT_MODIFY','Contact address update','Executed when a contact is updated','contact',51); +INSERT INTO `llx_c_action_trigger` VALUES (131,'COMPANY_SENTBYMAIL','Mails sent from third party card','Executed when you send email from third party card','societe',1),(132,'COMPANY_CREATE','Third party created','Executed when a third party is created','societe',1),(133,'PROPAL_VALIDATE','Customer proposal validated','Executed when a commercial proposal is validated','propal',2),(134,'PROPAL_SENTBYMAIL','Commercial proposal sent by mail','Executed when a commercial proposal is sent by mail','propal',3),(135,'ORDER_VALIDATE','Customer order validate','Executed when a customer order is validated','commande',4),(136,'ORDER_CLOSE','Customer order classify delivered','Executed when a customer order is set delivered','commande',5),(137,'ORDER_CLASSIFY_BILLED','Customer order classify billed','Executed when a customer order is set to billed','commande',5),(138,'ORDER_CANCEL','Customer order canceled','Executed when a customer order is canceled','commande',5),(139,'ORDER_SENTBYMAIL','Customer order sent by mail','Executed when a customer order is sent by mail ','commande',5),(140,'BILL_VALIDATE','Customer invoice validated','Executed when a customer invoice is approved','facture',6),(141,'BILL_PAYED','Customer invoice payed','Executed when a customer invoice is payed','facture',7),(142,'BILL_CANCEL','Customer invoice canceled','Executed when a customer invoice is conceled','facture',8),(143,'BILL_SENTBYMAIL','Customer invoice sent by mail','Executed when a customer invoice is sent by mail','facture',9),(144,'BILL_UNVALIDATE','Customer invoice unvalidated','Executed when a customer invoice status set back to draft','facture',10),(145,'ORDER_SUPPLIER_VALIDATE','Supplier order validated','Executed when a supplier order is validated','order_supplier',11),(146,'ORDER_SUPPLIER_APPROVE','Supplier order request approved','Executed when a supplier order is approved','order_supplier',12),(147,'ORDER_SUPPLIER_REFUSE','Supplier order request refused','Executed when a supplier order is refused','order_supplier',13),(148,'ORDER_SUPPLIER_SENTBYMAIL','Supplier order sent by mail','Executed when a supplier order is sent by mail','order_supplier',14),(149,'BILL_SUPPLIER_VALIDATE','Supplier invoice validated','Executed when a supplier invoice is validated','invoice_supplier',15),(150,'BILL_SUPPLIER_PAYED','Supplier invoice payed','Executed when a supplier invoice is payed','invoice_supplier',16),(151,'BILL_SUPPLIER_SENTBYMAIL','Supplier invoice sent by mail','Executed when a supplier invoice is sent by mail','invoice_supplier',17),(152,'BILL_SUPPLIER_CANCELED','Supplier invoice cancelled','Executed when a supplier invoice is cancelled','invoice_supplier',17),(153,'CONTRACT_VALIDATE','Contract validated','Executed when a contract is validated','contrat',18),(154,'SHIPPING_VALIDATE','Shipping validated','Executed when a shipping is validated','shipping',20),(155,'SHIPPING_SENTBYMAIL','Shipping sent by mail','Executed when a shipping is sent by mail','shipping',21),(156,'MEMBER_VALIDATE','Member validated','Executed when a member is validated','member',22),(158,'MEMBER_RESILIATE','Member resiliated','Executed when a member is resiliated','member',24),(159,'MEMBER_MODIFY','Member modified','Executed when a member is modified','member',24),(160,'MEMBER_DELETE','Member deleted','Executed when a member is deleted','member',25),(161,'FICHINTER_VALIDATE','Intervention validated','Executed when a intervention is validated','ficheinter',19),(162,'FICHINTER_CLASSIFY_BILLED','Intervention set billed','Executed when a intervention is set to billed (when option FICHINTER_CLASSIFY_BILLED is set)','ficheinter',19),(163,'FICHINTER_CLASSIFY_UNBILLED','Intervention set unbilled','Executed when a intervention is set to unbilled (when option FICHINTER_CLASSIFY_BILLED is set)','ficheinter',19),(164,'FICHINTER_REOPEN','Intervention opened','Executed when a intervention is re-opened','ficheinter',19),(165,'FICHINTER_SENTBYMAIL','Intervention sent by mail','Executed when a intervention is sent by mail','ficheinter',19),(166,'PROJECT_CREATE','Project creation','Executed when a project is created','project',140),(167,'PROPAL_CLOSE_SIGNED','Customer proposal closed signed','Executed when a customer proposal is closed signed','propal',2),(168,'PROPAL_CLOSE_REFUSED','Customer proposal closed refused','Executed when a customer proposal is closed refused','propal',2),(169,'PROPAL_CLASSIFY_BILLED','Customer proposal set billed','Executed when a customer proposal is set to billed','propal',2),(170,'TASK_CREATE','Task created','Executed when a project task is created','project',35),(171,'TASK_MODIFY','Task modified','Executed when a project task is modified','project',36),(172,'TASK_DELETE','Task deleted','Executed when a project task is deleted','project',37),(173,'BILL_SUPPLIER_UNVALIDATE','Supplier invoice unvalidated','Executed when a supplier invoice status is set back to draft','invoice_supplier',15),(174,'PROJECT_MODIFY','Project modified','Executed when a project is modified','project',141),(175,'PROJECT_DELETE','Project deleted','Executed when a project is deleted','project',142),(176,'ORDER_SUPPLIER_CREATE','Supplier order validated','Executed when a supplier order is validated','order_supplier',11),(177,'ORDER_SUPPLIER_SUBMIT','Supplier order request submited','Executed when a supplier order is approved','order_supplier',12),(178,'ORDER_SUPPLIER_RECEIVE','Supplier order request received','Executed when a supplier order is received','order_supplier',12),(179,'ORDER_SUPPLIER_CLASSIFY_BILLED','Supplier order set billed','Executed when a supplier order is set as billed','order_supplier',14),(180,'PRODUCT_CREATE','Product or service created','Executed when a product or sevice is created','product',30),(181,'PRODUCT_MODIFY','Product or service modified','Executed when a product or sevice is modified','product',30),(182,'PRODUCT_DELETE','Product or service deleted','Executed when a product or sevice is deleted','product',30),(183,'EXPENSE_REPORT_CREATE','Expense report created','Executed when an expense report is created','expensereport',201),(185,'EXPENSE_REPORT_VALIDATE','Expense report validated','Executed when an expense report is validated','expensereport',202),(186,'EXPENSE_REPORT_APPROVE','Expense report approved','Executed when an expense report is approved','expensereport',203),(187,'EXPENSE_REPORT_PAID','Expense report billed','Executed when an expense report is set as billed','expensereport',204),(192,'HOLIDAY_CREATE','Leave request created','Executed when a leave request is created','holiday',221),(193,'HOLIDAY_VALIDATE','Leave request validated','Executed when a leave request is validated','holiday',222),(194,'HOLIDAY_APPROVE','Leave request approved','Executed when a leave request is approved','holiday',223),(210,'MEMBER_SENTBYMAIL','Mails sent from member card','Executed when you send email from member card','member',23),(211,'CONTRACT_SENTBYMAIL','Contract sent by mail','Executed when a contract is sent by mail','contrat',18),(212,'PROPOSAL_SUPPLIER_VALIDATE','Price request validated','Executed when a commercial proposal is validated','proposal_supplier',10),(213,'PROPOSAL_SUPPLIER_SENTBYMAIL','Price request sent by mail','Executed when a commercial proposal is sent by mail','proposal_supplier',10),(214,'PROPOSAL_SUPPLIER_CLOSE_SIGNED','Price request closed signed','Executed when a customer proposal is closed signed','proposal_supplier',10),(215,'PROPOSAL_SUPPLIER_CLOSE_REFUSED','Price request closed refused','Executed when a customer proposal is closed refused','proposal_supplier',10),(216,'MEMBER_SUBSCRIPTION_CREATE','Member subscribtion recorded','Executed when a member subscribtion is deleted','member',24),(217,'MEMBER_SUBSCRIPTION_MODIFY','Member subscribtion modified','Executed when a member subscribtion is modified','member',24),(218,'MEMBER_SUBSCRIPTION_DELETE','Member subscribtion deleted','Executed when a member subscribtion is deleted','member',24),(225,'COMPANY_DELETE','Third party deleted','Executed when you delete third party','societe',1),(226,'PROPAL_DELETE','Customer proposal deleted','Executed when a customer proposal is deleted','propal',2),(227,'ORDER_DELETE','Customer order deleted','Executed when a customer order is deleted','commande',5),(228,'BILL_DELETE','Customer invoice deleted','Executed when a customer invoice is deleted','facture',9),(229,'PROPOSAL_SUPPLIER_DELETE','Price request deleted','Executed when a customer proposal delete','proposal_supplier',10),(230,'ORDER_SUPPLIER_DELETE','Supplier order deleted','Executed when a supplier order is deleted','order_supplier',14),(231,'BILL_SUPPLIER_DELETE','Supplier invoice deleted','Executed when a supplier invoice is deleted','invoice_supplier',17),(232,'CONTRACT_DELETE','Contract deleted','Executed when a contract is deleted','contrat',18),(233,'FICHINTER_DELETE','Intervention is deleted','Executed when a intervention is deleted','ficheinter',35),(234,'EXPENSE_REPORT_DELETE','Expense report deleted','Executed when an expense report is deleted','expensereport',204),(249,'TICKET_CREATE','Ticket created','Executed when a ticket is created','ticket',161),(250,'TICKET_MODIFY','Ticket modified','Executed when a ticket is modified','ticket',163),(251,'TICKET_ASSIGNED','Ticket assigned','Executed when a ticket is assigned to another user','ticket',164),(252,'TICKET_CLOSE','Ticket closed','Executed when a ticket is closed','ticket',165),(253,'TICKET_SENTBYMAIL','Ticket message sent by email','Executed when a message is sent from the ticket record','ticket',166),(254,'TICKET_DELETE','Ticket deleted','Executed when a ticket is deleted','ticket',167),(261,'USER_SENTBYMAIL','Email sent','Executed when an email is sent from user card','user',300),(262,'BOM_VALIDATE','BOM validated','Executed when a BOM is validated','bom',650),(263,'BOM_UNVALIDATE','BOM unvalidated','Executed when a BOM is unvalidated','bom',651),(264,'BOM_CLOSE','BOM disabled','Executed when a BOM is disabled','bom',652),(265,'BOM_REOPEN','BOM reopen','Executed when a BOM is re-open','bom',653),(266,'BOM_DELETE','BOM deleted','Executed when a BOM deleted','bom',654),(351,'MRP_MO_VALIDATE','MO validated','Executed when a MO is validated','bom',660),(352,'MRP_MO_PRODUCED','MO produced','Executed when a MO is produced','bom',661),(353,'MRP_MO_DELETE','MO deleted','Executed when a MO is deleted','bom',662),(354,'MRP_MO_CANCEL','MO canceled','Executed when a MO is canceled','bom',663),(365,'CONTACT_CREATE','Contact address created','Executed when a contact is created','contact',50),(366,'CONTACT_SENTBYMAIL','Mails sent from third party card','Executed when you send email from contact adress card','contact',51),(367,'CONTACT_DELETE','Contact address deleted','Executed when a contact is deleted','contact',52),(368,'RECRUITMENTJOBPOSITION_CREATE','Job created','Executed when a job is created','recruitment',7500),(369,'RECRUITMENTJOBPOSITION_MODIFY','Job modified','Executed when a job is modified','recruitment',7502),(370,'RECRUITMENTJOBPOSITION_SENTBYMAIL','Mails sent from job record','Executed when you send email from job record','recruitment',7504),(371,'RECRUITMENTJOBPOSITION_DELETE','Job deleted','Executed when a job is deleted','recruitment',7506),(372,'RECRUITMENTCANDIDATURE_CREATE','Candidature created','Executed when a candidature is created','recruitment',7510),(373,'RECRUITMENTCANDIDATURE_MODIFY','Candidature modified','Executed when a candidature is modified','recruitment',7512),(374,'RECRUITMENTCANDIDATURE_SENTBYMAIL','Mails sent from candidature record','Executed when you send email from candidature record','recruitment',7514),(375,'RECRUITMENTCANDIDATURE_DELETE','Candidature deleted','Executed when a candidature is deleted','recruitment',7516),(392,'COMPANY_MODIFY','Third party update','Executed when you update third party','societe',1),(393,'CONTACT_MODIFY','Contact address update','Executed when a contact is updated','contact',51),(394,'ORDER_SUPPLIER_CANCEL','Supplier order request canceled','Executed when a supplier order is canceled','order_supplier',13),(395,'MEMBER_EXCLUDE','Member excluded','Executed when a member is excluded','member',27),(396,'USER_CREATE','User created','Executed when a user is created','user',301),(397,'USER_MODIFY','User update','Executed when a user is updated','user',302),(398,'USER_DELETE','User update','Executed when a user is deleted','user',303),(399,'USER_NEW_PASSWORD','User update','Executed when a user is change password','user',304),(400,'USER_ENABLEDISABLE','User update','Executed when a user is enable or disable','user',305),(402,'HOLIDAY_MODIFY','Holiday modified','Executed when a holiday is modified','holiday',801),(405,'HOLIDAY_CANCEL','Holiday canceled','Executed when a holiday is canceled','holiday',802),(406,'HOLIDAY_DELETE','Holiday deleted','Executed when a holiday is deleted','holiday',804); /*!40000 ALTER TABLE `llx_c_action_trigger` ENABLE KEYS */; UNLOCK TABLES; @@ -1589,7 +1580,7 @@ CREATE TABLE `llx_c_barcode_type` ( `example` varchar(16) COLLATE utf8_unicode_ci NOT NULL, PRIMARY KEY (`rowid`), UNIQUE KEY `uk_c_barcode_type` (`code`,`entity`) -) ENGINE=InnoDB AUTO_INCREMENT=63 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=71 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -1871,7 +1862,7 @@ CREATE TABLE `llx_c_email_templates` ( PRIMARY KEY (`rowid`), UNIQUE KEY `uk_c_email_templates` (`entity`,`label`,`lang`), KEY `idx_type` (`type_template`) -) ENGINE=InnoDB AUTO_INCREMENT=31 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=37 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -1880,7 +1871,7 @@ CREATE TABLE `llx_c_email_templates` ( LOCK TABLES `llx_c_email_templates` WRITE; /*!40000 ALTER TABLE `llx_c_email_templates` DISABLE KEYS */; -INSERT INTO `llx_c_email_templates` VALUES (1,1,NULL,'propal_send','',1,NULL,NULL,'2018-01-19 11:17:48','My Private email template for proposals',1,1,'Hello __FIRSTNAME__','We wish you a happy new year
__USER_SIGNATURE__',NULL,'1','1'),(2,0,'adherent','member','',0,NULL,NULL,'2018-01-19 11:17:48','(SendAnEMailToMember)',1,1,'__(CardContent)__','__(Hello)__,

\n\n__(ThisIsContentOfYourCard)__
\n__(ID)__ : __ID__
\n__(Civiliyty)__ : __MEMBER_CIVILITY__
\n__(Firstname)__ : __MEMBER_FIRSTNAME__
\n__(Lastname)__ : __MEMBER_LASTNAME__
\n__(Fullname)__ : __MEMBER_FULLNAME__
\n__(Company)__ : __MEMBER_COMPANY__
\n__(Address)__ : __MEMBER_ADDRESS__
\n__(Zip)__ : __MEMBER_ZIP__
\n__(Town)__ : __MEMBER_TOWN__
\n__(Country)__ : __MEMBER_COUNTRY__
\n__(Email)__ : __MEMBER_EMAIL__
\n__(Birthday)__ : __MEMBER_BIRTH__
\n__(Photo)__ : __MEMBER_PHOTO__
\n__(Login)__ : __MEMBER_LOGIN__
\n__(Password)__ : __MEMBER_PASSWORD__
\n__(Phone)__ : __MEMBER_PHONE__
\n__(PhonePerso)__ : __MEMBER_PHONEPRO__
\n__(PhoneMobile)__ : __MEMBER_PHONEMOBILE__

\n__(Sincerely)__
__USER_SIGNATURE__',NULL,'1','1'),(3,0,'banque','thirdparty','',0,NULL,NULL,'2018-01-19 11:17:48','(YourSEPAMandate)',1,0,'__(YourSEPAMandate)__','__(Hello)__,

\n\n__(FindYourSEPAMandate)__ :
\n__MYCOMPANY_NAME__
\n__MYCOMPANY_FULLADDRESS__

\n__(Sincerely)__
\n__USER_SIGNATURE__',NULL,'1','1'),(6,0,'adherent','member','',0,NULL,NULL,'2018-11-23 11:56:08','(SendingEmailOnAutoSubscription)',10,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(YourMembershipRequestWasReceived)__','__(Hello)__ __MEMBER_FULLNAME__,

\n\n__(ThisIsContentOfYourMembershipRequestWasReceived)__
\n
__ONLINE_PAYMENT_TEXT_AND_URL__
\n

\n__(Sincerely)__
__USER_SIGNATURE__',NULL,'1','0'),(7,0,'adherent','member','',0,NULL,NULL,'2018-11-23 11:56:08','(SendingEmailOnMemberValidation)',20,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(YourMembershipWasValidated)__','__(Hello)__ __MEMBER_FULLNAME__,

\n\n__(ThisIsContentOfYourMembershipWasValidated)__
\n
__ONLINE_PAYMENT_TEXT_AND_URL__
\n

\n__(Sincerely)__
__USER_SIGNATURE__',NULL,'1','0'),(8,0,'adherent','member','',0,NULL,NULL,'2018-11-23 11:56:08','(SendingEmailOnNewSubscription)',30,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(YourSubscriptionWasRecorded)__','__(Hello)__ __MEMBER_FULLNAME__,

\n\n__(ThisIsContentOfYourSubscriptionWasRecorded)__
\n\n

\n__(Sincerely)__
__USER_SIGNATURE__',NULL,'1','1'),(9,0,'adherent','member','',0,NULL,NULL,'2018-11-23 11:56:08','(SendingReminderForExpiredSubscription)',40,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(SubscriptionReminderEmail)__','__(Hello)__ __MEMBER_FULLNAME__,

\n\n__(ThisIsContentOfSubscriptionReminderEmail)__
\n
__ONLINE_PAYMENT_TEXT_AND_URL__
\n

\n__(Sincerely)__
__USER_SIGNATURE__',NULL,'1','0'),(10,0,'adherent','member','',0,NULL,NULL,'2018-11-23 11:56:08','(SendingEmailOnCancelation)',50,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(YourMembershipWasCanceled)__','__(Hello)__ __MEMBER_FULLNAME__,

\n\n__(YourMembershipWasCanceled)__
\n

\n__(Sincerely)__
__USER_SIGNATURE__',NULL,'1','0'),(11,0,'adherent','member','',0,NULL,NULL,'2018-11-23 11:56:08','(SendingAnEMailToMember)',60,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(CardContent)__','__(Hello)__,

\n\n__(ThisIsContentOfYourCard)__
\n__(ID)__ : __ID__
\n__(Civiliyty)__ : __MEMBER_CIVILITY__
\n__(Firstname)__ : __MEMBER_FIRSTNAME__
\n__(Lastname)__ : __MEMBER_LASTNAME__
\n__(Fullname)__ : __MEMBER_FULLNAME__
\n__(Company)__ : __MEMBER_COMPANY__
\n__(Address)__ : __MEMBER_ADDRESS__
\n__(Zip)__ : __MEMBER_ZIP__
\n__(Town)__ : __MEMBER_TOWN__
\n__(Country)__ : __MEMBER_COUNTRY__
\n__(Email)__ : __MEMBER_EMAIL__
\n__(Birthday)__ : __MEMBER_BIRTH__
\n__(Photo)__ : __MEMBER_PHOTO__
\n__(Login)__ : __MEMBER_LOGIN__
\n__(Password)__ : __MEMBER_PASSWORD__
\n__(Phone)__ : __MEMBER_PHONE__
\n__(PhonePerso)__ : __MEMBER_PHONEPRO__
\n__(PhoneMobile)__ : __MEMBER_PHONEMOBILE__

\n__(Sincerely)__
__USER_SIGNATURE__',NULL,'1','0'),(12,0,'recruitment','recruitmentcandidature_send','',0,NULL,NULL,'2020-12-10 12:24:39','(AnswerCandidature)',100,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(YourCandidature)__','__(Hello)__ __CANDIDATE_FULLNAME__,

\n\n__(YourCandidatureAnswer)__
\n

\n__(Sincerely)__
__USER_SIGNATURE__',NULL,'$conf->recruitment->enabled','0'),(14,0,'','eventorganization_send','',0,NULL,NULL,'2021-02-14 13:42:41','EventOrganizationEmailAskConf',10,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(EventOrganizationEmailAskConf)__','__(Hello)__ __THIRDPARTY_NAME__,

__(ThisIsContentOfYourOrganizationEventConfRequestWasReceived)__

__ONLINE_PAYMENT_TEXT_AND_URL__


__(Sincerely)__
__USER_SIGNATURE__',NULL,'1',NULL),(15,0,'','eventorganization_send','',0,NULL,NULL,'2021-02-14 13:42:41','EventOrganizationEmailAskBooth',20,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(EventOrganizationEmailAskBooth)__','__(Hello)__ __THIRDPARTY_NAME__,

__(ThisIsContentOfYourOrganizationEventBoothRequestWasReceived)__

__ONLINE_PAYMENT_TEXT_AND_URL__


__(Sincerely)__
__USER_SIGNATURE__',NULL,'1',NULL),(16,0,'','eventorganization_send','',0,NULL,NULL,'2021-02-14 13:42:41','EventOrganizationEmailSubsBooth',30,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(EventOrganizationEmailSubsBooth)__','__(Hello)__ __THIRDPARTY_NAME__,

__(ThisIsContentOfYourOrganizationEventBoothSubscriptionWasReceived)__

__ONLINE_PAYMENT_TEXT_AND_URL__


__(Sincerely)__
__USER_SIGNATURE__',NULL,'1',NULL),(17,0,'','eventorganization_send','',0,NULL,NULL,'2021-02-14 13:42:41','EventOrganizationEmailSubsEvent',40,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(EventOrganizationEmailSubsEvent)__','__(Hello)__ __THIRDPARTY_NAME__,

__(ThisIsContentOfYourOrganizationEventEventSubscriptionWasReceived)__

__ONLINE_PAYMENT_TEXT_AND_URL__


__(Sincerely)__
__USER_SIGNATURE__',NULL,'1',NULL),(18,0,'','eventorganization_send','',0,NULL,NULL,'2021-02-14 13:42:41','EventOrganizationMassEmailAttendees',50,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(EventOrganizationMassEmailAttendees)__','__(Hello)__ __THIRDPARTY_NAME__,

__(ThisIsContentOfYourOrganizationEventBulkMailToAttendees)__

__(Sincerely)__
__USER_SIGNATURE__',NULL,'1',NULL),(19,0,'','eventorganization_send','',0,NULL,NULL,'2021-02-14 13:42:41','EventOrganizationMassEmailSpeakers',60,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(EventOrganizationMassEmailSpeakers)__','__(Hello)__ __THIRDPARTY_NAME__,

__(ThisIsContentOfYourOrganizationEventBulkMailToSpeakers)__

__(Sincerely)__
__USER_SIGNATURE__',NULL,'1',NULL),(20,0,'partnership','member',NULL,0,NULL,NULL,'2021-04-15 10:22:55','(AlertStatusPartnershipExpiration)',100,1,'[__[MAIN_INFO_SOCIETE_NOM]__] - __(YourMembershipWillSoonExpireTopic)__','\n

Dear __MEMBER_FULLNAME__,

\n__(YourMembershipWillSoonExpireContent)__

\n
\n\n __(Sincerely)__
\n __[PARTNERSHIP_SOCIETE_NOM]__
\n \n',NULL,'1','0'),(27,0,'partnership','partnership_send','',0,NULL,NULL,'2021-07-11 17:49:44','(SendingEmailOnPartnershipWillSoonBeCanceled)',100,1,'[__[MAIN_INFO_SOCIETE_NOM]__] - __(YourPartnershipWillSoonBeCanceledTopic)__','\n

Hello,

\n__(YourPartnershipWillSoonBeCanceledContent)__

\n
\n\n
\n\n __(Sincerely)__
\n __[MAIN_INFO_SOCIETE_NOM]__
\n \n',NULL,'1','0'),(28,0,'partnership','partnership_send','',0,NULL,NULL,'2021-07-11 17:49:44','(SendingEmailOnPartnershipCanceled)',100,1,'[__[MAIN_INFO_SOCIETE_NOM]__] - __(YourPartnershipCanceledTopic)__','\n

Hello,

\n__(YourPartnershipCanceledContent)__

\n
\n\n
\n\n __(Sincerely)__
\n __[MAIN_INFO_SOCIETE_NOM]__
\n \n',NULL,'1','0'),(29,0,'partnership','partnership_send','',0,NULL,NULL,'2021-07-11 17:49:44','(SendingEmailOnPartnershipRefused)',100,1,'[__[MAIN_INFO_SOCIETE_NOM]__] - __(YourPartnershipRefusedTopic)__','\n

Hello,

\n__(YourPartnershipRefusedContent)__

\n
\n\n
\n\n __(Sincerely)__
\n __[MAIN_INFO_SOCIETE_NOM]__
\n \n',NULL,'1','0'),(30,0,'partnership','partnership_send','',0,NULL,NULL,'2021-07-11 17:49:44','(SendingEmailOnPartnershipAccepted)',100,1,'[__[MAIN_INFO_SOCIETE_NOM]__] - __(YourPartnershipAcceptedTopic)__','\n

Hello,

\n__(YourPartnershipAcceptedContent)__

\n
\n\n
\n\n __(Sincerely)__
\n __[MAIN_INFO_SOCIETE_NOM]__
\n \n',NULL,'1','0'); +INSERT INTO `llx_c_email_templates` VALUES (1,1,NULL,'propal_send','',1,NULL,NULL,'2018-01-19 11:17:48','My Private email template for proposals',1,1,'Hello __FIRSTNAME__','We wish you a happy new year
__USER_SIGNATURE__',NULL,'1','1'),(2,0,'adherent','member','',0,NULL,NULL,'2018-01-19 11:17:48','(SendAnEMailToMember)',1,1,'__(CardContent)__','__(Hello)__,

\n\n__(ThisIsContentOfYourCard)__
\n__(ID)__ : __ID__
\n__(Civiliyty)__ : __MEMBER_CIVILITY__
\n__(Firstname)__ : __MEMBER_FIRSTNAME__
\n__(Lastname)__ : __MEMBER_LASTNAME__
\n__(Fullname)__ : __MEMBER_FULLNAME__
\n__(Company)__ : __MEMBER_COMPANY__
\n__(Address)__ : __MEMBER_ADDRESS__
\n__(Zip)__ : __MEMBER_ZIP__
\n__(Town)__ : __MEMBER_TOWN__
\n__(Country)__ : __MEMBER_COUNTRY__
\n__(Email)__ : __MEMBER_EMAIL__
\n__(Birthday)__ : __MEMBER_BIRTH__
\n__(Photo)__ : __MEMBER_PHOTO__
\n__(Login)__ : __MEMBER_LOGIN__
\n__(Password)__ : __MEMBER_PASSWORD__
\n__(Phone)__ : __MEMBER_PHONE__
\n__(PhonePerso)__ : __MEMBER_PHONEPRO__
\n__(PhoneMobile)__ : __MEMBER_PHONEMOBILE__

\n__(Sincerely)__
__USER_SIGNATURE__',NULL,'1','1'),(3,0,'banque','thirdparty','',0,NULL,NULL,'2018-01-19 11:17:48','(YourSEPAMandate)',1,0,'__(YourSEPAMandate)__','__(Hello)__,

\n\n__(FindYourSEPAMandate)__ :
\n__MYCOMPANY_NAME__
\n__MYCOMPANY_FULLADDRESS__

\n__(Sincerely)__
\n__USER_SIGNATURE__',NULL,'1','1'),(6,0,'adherent','member','',0,NULL,NULL,'2018-11-23 11:56:08','(SendingEmailOnAutoSubscription)',10,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(YourMembershipRequestWasReceived)__','__(Hello)__ __MEMBER_FULLNAME__,

\n\n__(ThisIsContentOfYourMembershipRequestWasReceived)__
\n
__ONLINE_PAYMENT_TEXT_AND_URL__
\n

\n__(Sincerely)__
__USER_SIGNATURE__',NULL,'1','0'),(7,0,'adherent','member','',0,NULL,NULL,'2018-11-23 11:56:08','(SendingEmailOnMemberValidation)',20,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(YourMembershipWasValidated)__','__(Hello)__ __MEMBER_FULLNAME__,

\n\n__(ThisIsContentOfYourMembershipWasValidated)__
\n
__ONLINE_PAYMENT_TEXT_AND_URL__
\n

\n__(Sincerely)__
__USER_SIGNATURE__',NULL,'1','0'),(8,0,'adherent','member','',0,NULL,NULL,'2018-11-23 11:56:08','(SendingEmailOnNewSubscription)',30,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(YourSubscriptionWasRecorded)__','__(Hello)__ __MEMBER_FULLNAME__,

\n\n__(ThisIsContentOfYourSubscriptionWasRecorded)__
\n\n

\n__(Sincerely)__
__USER_SIGNATURE__',NULL,'1','1'),(9,0,'adherent','member','',0,NULL,NULL,'2018-11-23 11:56:08','(SendingReminderForExpiredSubscription)',40,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(SubscriptionReminderEmail)__','__(Hello)__ __MEMBER_FULLNAME__,

\n\n__(ThisIsContentOfSubscriptionReminderEmail)__
\n
__ONLINE_PAYMENT_TEXT_AND_URL__
\n

\n__(Sincerely)__
__USER_SIGNATURE__',NULL,'1','0'),(10,0,'adherent','member','',0,NULL,NULL,'2018-11-23 11:56:08','(SendingEmailOnCancelation)',50,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(YourMembershipWasCanceled)__','__(Hello)__ __MEMBER_FULLNAME__,

\n\n__(YourMembershipWasCanceled)__
\n

\n__(Sincerely)__
__USER_SIGNATURE__',NULL,'1','0'),(11,0,'adherent','member','',0,NULL,NULL,'2018-11-23 11:56:08','(SendingAnEMailToMember)',60,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(CardContent)__','__(Hello)__,

\n\n__(ThisIsContentOfYourCard)__
\n__(ID)__ : __ID__
\n__(Civiliyty)__ : __MEMBER_CIVILITY__
\n__(Firstname)__ : __MEMBER_FIRSTNAME__
\n__(Lastname)__ : __MEMBER_LASTNAME__
\n__(Fullname)__ : __MEMBER_FULLNAME__
\n__(Company)__ : __MEMBER_COMPANY__
\n__(Address)__ : __MEMBER_ADDRESS__
\n__(Zip)__ : __MEMBER_ZIP__
\n__(Town)__ : __MEMBER_TOWN__
\n__(Country)__ : __MEMBER_COUNTRY__
\n__(Email)__ : __MEMBER_EMAIL__
\n__(Birthday)__ : __MEMBER_BIRTH__
\n__(Photo)__ : __MEMBER_PHOTO__
\n__(Login)__ : __MEMBER_LOGIN__
\n__(Password)__ : __MEMBER_PASSWORD__
\n__(Phone)__ : __MEMBER_PHONE__
\n__(PhonePerso)__ : __MEMBER_PHONEPRO__
\n__(PhoneMobile)__ : __MEMBER_PHONEMOBILE__

\n__(Sincerely)__
__USER_SIGNATURE__',NULL,'1','0'),(12,0,'recruitment','recruitmentcandidature_send','',0,NULL,NULL,'2020-12-10 12:24:39','(AnswerCandidature)',100,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(YourCandidature)__','__(Hello)__ __CANDIDATE_FULLNAME__,

\n\n__(YourCandidatureAnswer)__
\n

\n__(Sincerely)__
__USER_SIGNATURE__',NULL,'$conf->recruitment->enabled','0'),(14,0,'','eventorganization_send','',0,NULL,NULL,'2021-02-14 13:42:41','EventOrganizationEmailAskConf',10,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(EventOrganizationEmailAskConf)__','__(Hello)__ __THIRDPARTY_NAME__,

__(ThisIsContentOfYourOrganizationEventConfRequestWasReceived)__

__ONLINE_PAYMENT_TEXT_AND_URL__


__(Sincerely)__
__USER_SIGNATURE__',NULL,'1',NULL),(15,0,'','eventorganization_send','',0,NULL,NULL,'2021-02-14 13:42:41','EventOrganizationEmailAskBooth',20,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(EventOrganizationEmailAskBooth)__','__(Hello)__ __THIRDPARTY_NAME__,

__(ThisIsContentOfYourOrganizationEventBoothRequestWasReceived)__

__ONLINE_PAYMENT_TEXT_AND_URL__


__(Sincerely)__
__USER_SIGNATURE__',NULL,'1',NULL),(16,0,'','eventorganization_send','',0,NULL,NULL,'2021-02-14 13:42:41','EventOrganizationEmailSubsBooth',30,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(EventOrganizationEmailSubsBooth)__','__(Hello)__ __THIRDPARTY_NAME__,

__(ThisIsContentOfYourOrganizationEventBoothSubscriptionWasReceived)__

__ONLINE_PAYMENT_TEXT_AND_URL__


__(Sincerely)__
__USER_SIGNATURE__',NULL,'1',NULL),(17,0,'','eventorganization_send','',0,NULL,NULL,'2021-02-14 13:42:41','EventOrganizationEmailSubsEvent',40,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(EventOrganizationEmailSubsEvent)__','__(Hello)__ __THIRDPARTY_NAME__,

__(ThisIsContentOfYourOrganizationEventEventSubscriptionWasReceived)__

__ONLINE_PAYMENT_TEXT_AND_URL__


__(Sincerely)__
__USER_SIGNATURE__',NULL,'1',NULL),(18,0,'','eventorganization_send','',0,NULL,NULL,'2021-02-14 13:42:41','EventOrganizationMassEmailAttendees',50,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(EventOrganizationMassEmailAttendees)__','__(Hello)__ __THIRDPARTY_NAME__,

__(ThisIsContentOfYourOrganizationEventBulkMailToAttendees)__

__(Sincerely)__
__USER_SIGNATURE__',NULL,'1',NULL),(19,0,'','eventorganization_send','',0,NULL,NULL,'2021-02-14 13:42:41','EventOrganizationMassEmailSpeakers',60,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(EventOrganizationMassEmailSpeakers)__','__(Hello)__ __THIRDPARTY_NAME__,

__(ThisIsContentOfYourOrganizationEventBulkMailToSpeakers)__

__(Sincerely)__
__USER_SIGNATURE__',NULL,'1',NULL),(20,0,'partnership','member',NULL,0,NULL,NULL,'2021-04-15 10:22:55','(AlertStatusPartnershipExpiration)',100,1,'[__[MAIN_INFO_SOCIETE_NOM]__] - __(YourMembershipWillSoonExpireTopic)__','\n

Dear __MEMBER_FULLNAME__,

\n__(YourMembershipWillSoonExpireContent)__

\n
\n\n __(Sincerely)__
\n __[PARTNERSHIP_SOCIETE_NOM]__
\n \n',NULL,'1','0'),(27,0,'partnership','partnership_send','',0,NULL,NULL,'2021-07-11 17:49:44','(SendingEmailOnPartnershipWillSoonBeCanceled)',100,1,'[__[MAIN_INFO_SOCIETE_NOM]__] - __(YourPartnershipWillSoonBeCanceledTopic)__','\n

Hello,

\n__(YourPartnershipWillSoonBeCanceledContent)__

\n
\n\n
\n\n __(Sincerely)__
\n __[MAIN_INFO_SOCIETE_NOM]__
\n \n',NULL,'1','0'),(28,0,'partnership','partnership_send','',0,NULL,NULL,'2021-07-11 17:49:44','(SendingEmailOnPartnershipCanceled)',100,1,'[__[MAIN_INFO_SOCIETE_NOM]__] - __(YourPartnershipCanceledTopic)__','\n

Hello,

\n__(YourPartnershipCanceledContent)__

\n
\n\n
\n\n __(Sincerely)__
\n __[MAIN_INFO_SOCIETE_NOM]__
\n \n',NULL,'1','0'),(29,0,'partnership','partnership_send','',0,NULL,NULL,'2021-07-11 17:49:44','(SendingEmailOnPartnershipRefused)',100,1,'[__[MAIN_INFO_SOCIETE_NOM]__] - __(YourPartnershipRefusedTopic)__','\n

Hello,

\n__(YourPartnershipRefusedContent)__

\n
\n\n
\n\n __(Sincerely)__
\n __[MAIN_INFO_SOCIETE_NOM]__
\n \n',NULL,'1','0'),(30,0,'partnership','partnership_send','',0,NULL,NULL,'2021-07-11 17:49:44','(SendingEmailOnPartnershipAccepted)',100,1,'[__[MAIN_INFO_SOCIETE_NOM]__] - __(YourPartnershipAcceptedTopic)__','\n

Hello,

\n__(YourPartnershipAcceptedContent)__

\n
\n\n
\n\n __(Sincerely)__
\n __[MAIN_INFO_SOCIETE_NOM]__
\n \n',NULL,'1','0'),(31,0,'','conferenceorbooth','',0,NULL,NULL,'2022-02-07 13:38:10','(EventOrganizationEmailAskConf)',10,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(EventOrganizationEmailAskConf)__','__(Hello)__,

__(OrganizationEventConfRequestWasReceived)__


__(Sincerely)__
__USER_SIGNATURE__',NULL,'1',NULL),(32,0,'','conferenceorbooth','',0,NULL,NULL,'2022-02-07 13:38:10','(EventOrganizationEmailAskBooth)',20,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(EventOrganizationEmailAskBooth)__','__(Hello)__,

__(OrganizationEventBoothRequestWasReceived)__


__(Sincerely)__
__USER_SIGNATURE__',NULL,'1',NULL),(33,0,'','conferenceorbooth','',0,NULL,NULL,'2022-02-07 13:38:10','(EventOrganizationEmailBoothPayment)',30,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(EventOrganizationEmailBoothPayment)__','__(Hello)__,

__(OrganizationEventPaymentOfBoothWasReceived)__


__(Sincerely)__
__USER_SIGNATURE__',NULL,'1',NULL),(34,0,'','conferenceorbooth','',0,NULL,NULL,'2022-02-07 13:38:10','(EventOrganizationEmailRegistrationPayment)',40,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(EventOrganizationEmailRegistrationPayment)__','__(Hello)__,

__(OrganizationEventPaymentOfRegistrationWasReceived)__

__(Sincerely)__
__USER_SIGNATURE__',NULL,'1',NULL),(35,0,'','conferenceorbooth','',0,NULL,NULL,'2022-02-07 13:38:10','(EventOrganizationMassEmailAttendees)',50,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(EventOrganizationMassEmailAttendees)__','__(Hello)__,

__(OrganizationEventBulkMailToAttendees)__

__(Sincerely)__
__USER_SIGNATURE__',NULL,'1',NULL),(36,0,'','conferenceorbooth','',0,NULL,NULL,'2022-02-07 13:38:10','(EventOrganizationMassEmailSpeakers)',60,1,'[__[MAIN_INFO_SOCIETE_NOM]__] __(EventOrganizationMassEmailSpeakers)__','__(Hello)__,

__(OrganizationEventBulkMailToSpeakers)__

__(Sincerely)__
__USER_SIGNATURE__',NULL,'1',NULL); /*!40000 ALTER TABLE `llx_c_email_templates` ENABLE KEYS */; UNLOCK TABLES; @@ -2030,7 +2021,7 @@ CREATE TABLE `llx_c_forme_juridique` ( `position` int(11) NOT NULL DEFAULT 0, PRIMARY KEY (`rowid`), UNIQUE KEY `uk_c_forme_juridique` (`code`) -) ENGINE=InnoDB AUTO_INCREMENT=100230 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=100242 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -2039,7 +2030,7 @@ CREATE TABLE `llx_c_forme_juridique` ( LOCK TABLES `llx_c_forme_juridique` WRITE; /*!40000 ALTER TABLE `llx_c_forme_juridique` DISABLE KEYS */; -INSERT INTO `llx_c_forme_juridique` VALUES (100001,100001,1,'Etudiant',0,0,'cabinetmed',0),(100002,100002,1,'Retraité',0,0,'cabinetmed',0),(100003,100003,1,'Artisan',0,0,'cabinetmed',0),(100004,100004,1,'Femme de ménage',0,0,'cabinetmed',0),(100005,100005,1,'Professeur',0,0,'cabinetmed',0),(100006,100006,1,'Profession libérale',0,0,'cabinetmed',0),(100007,100007,1,'Informaticien',0,0,'cabinetmed',0),(100009,0,0,'-',0,1,NULL,0),(100010,2301,23,'Monotributista',0,1,NULL,0),(100011,2302,23,'Sociedad Civil',0,1,NULL,0),(100012,2303,23,'Sociedades Comerciales',0,1,NULL,0),(100013,2304,23,'Sociedades de Hecho',0,1,NULL,0),(100014,2305,23,'Sociedades Irregulares',0,1,NULL,0),(100015,2306,23,'Sociedad Colectiva',0,1,NULL,0),(100016,2307,23,'Sociedad en Comandita Simple',0,1,NULL,0),(100017,2308,23,'Sociedad de Capital e Industria',0,1,NULL,0),(100018,2309,23,'Sociedad Accidental o en participación',0,1,NULL,0),(100019,2310,23,'Sociedad de Responsabilidad Limitada',0,1,NULL,0),(100020,2311,23,'Sociedad Anónima',0,1,NULL,0),(100021,2312,23,'Sociedad Anónima con Participación Estatal Mayoritaria',0,1,NULL,0),(100022,2313,23,'Sociedad en Comandita por Acciones (arts. 315 a 324, LSC)',0,1,NULL,0),(100023,11,1,'Artisan Commerçant (EI)',0,1,NULL,0),(100024,12,1,'Commerçant (EI)',0,1,NULL,0),(100025,13,1,'Artisan (EI)',0,1,NULL,0),(100026,14,1,'Officier public ou ministériel',0,1,NULL,0),(100027,15,1,'Profession libérale (EI)',0,1,NULL,0),(100028,16,1,'Exploitant agricole',0,1,NULL,0),(100029,17,1,'Agent commercial',0,1,NULL,0),(100030,18,1,'Associé Gérant de société',0,1,NULL,0),(100031,19,1,'Personne physique',0,1,NULL,0),(100032,21,1,'Indivision',0,1,NULL,0),(100033,22,1,'Société créée de fait',0,1,NULL,0),(100034,23,1,'Société en participation',0,1,NULL,0),(100035,27,1,'Paroisse hors zone concordataire',0,1,NULL,0),(100036,29,1,'Groupement de droit privé non doté de la personnalité morale',0,1,NULL,0),(100037,31,1,'Personne morale de droit étranger, immatriculée au RCS',0,1,NULL,0),(100038,32,1,'Personne morale de droit étranger, non immatriculée au RCS',0,1,NULL,0),(100039,35,1,'Régime auto-entrepreneur',0,1,NULL,0),(100040,41,1,'Etablissement public ou régie à caractère industriel ou commercial',0,1,NULL,0),(100041,51,1,'Société coopérative commerciale particulière',0,1,NULL,0),(100042,52,1,'Société en nom collectif',0,1,NULL,0),(100043,53,1,'Société en commandite',0,1,NULL,0),(100044,54,1,'Société à responsabilité limitée (SARL)',0,1,NULL,0),(100045,55,1,'Société anonyme à conseil d administration',0,1,NULL,0),(100046,56,1,'Société anonyme à directoire',0,1,NULL,0),(100047,57,1,'Société par actions simplifiée (SAS)',0,1,NULL,0),(100048,58,1,'Entreprise Unipersonnelle à Responsabilité Limitée (EURL)',0,1,NULL,0),(100049,59,1,'Société par actions simplifiée unipersonnelle (SASU)',0,1,NULL,0),(100050,60,1,'Entreprise Individuelle à Responsabilité Limitée (EIRL)',0,1,NULL,0),(100051,61,1,'Caisse d\'épargne et de prévoyance',0,1,NULL,0),(100052,62,1,'Groupement d\'intérêt économique (GIE)',0,1,NULL,0),(100053,63,1,'Société coopérative agricole',0,1,NULL,0),(100054,64,1,'Société non commerciale d assurances',0,1,NULL,0),(100055,65,1,'Société civile',0,1,NULL,0),(100056,69,1,'Personnes de droit privé inscrites au RCS',0,1,NULL,0),(100057,71,1,'Administration de l état',0,1,NULL,0),(100058,72,1,'Collectivité territoriale',0,1,NULL,0),(100059,73,1,'Etablissement public administratif',0,1,NULL,0),(100060,74,1,'Personne morale de droit public administratif',0,1,NULL,0),(100061,81,1,'Organisme gérant régime de protection social à adhésion obligatoire',0,1,NULL,0),(100062,82,1,'Organisme mutualiste',0,1,NULL,0),(100063,83,1,'Comité d entreprise',0,1,NULL,0),(100064,84,1,'Organisme professionnel',0,1,NULL,0),(100065,85,1,'Organisme de retraite à adhésion non obligatoire',0,1,NULL,0),(100066,91,1,'Syndicat de propriétaires',0,1,NULL,0),(100067,92,1,'Association loi 1901 ou assimilé',0,1,NULL,0),(100068,93,1,'Fondation',0,1,NULL,0),(100069,99,1,'Personne morale de droit privé',0,1,NULL,0),(100070,200,2,'Indépendant',0,1,NULL,0),(100071,201,2,'SRL - Société à responsabilité limitée',0,1,NULL,0),(100072,202,2,'SA - Société Anonyme',0,1,NULL,0),(100073,203,2,'SCRL - Société coopérative à responsabilité limitée',0,1,NULL,0),(100074,204,2,'ASBL - Association sans but Lucratif',0,1,NULL,0),(100075,205,2,'SCRI - Société coopérative à responsabilité illimitée',0,1,NULL,0),(100076,206,2,'SCS - Société en commandite simple',0,1,NULL,0),(100077,207,2,'SCA - Société en commandite par action',0,1,NULL,0),(100078,208,2,'SNC - Société en nom collectif',0,1,NULL,0),(100079,209,2,'GIE - Groupement d intérêt économique',0,1,NULL,0),(100080,210,2,'GEIE - Groupement européen d intérêt économique',0,1,NULL,0),(100081,220,2,'Eenmanszaak',0,1,NULL,0),(100082,221,2,'BVBA - Besloten vennootschap met beperkte aansprakelijkheid',0,1,NULL,0),(100083,222,2,'NV - Naamloze Vennootschap',0,1,NULL,0),(100084,223,2,'CVBA - Coöperatieve vennootschap met beperkte aansprakelijkheid',0,1,NULL,0),(100085,224,2,'VZW - Vereniging zonder winstoogmerk',0,1,NULL,0),(100086,225,2,'CVOA - Coöperatieve vennootschap met onbeperkte aansprakelijkheid ',0,1,NULL,0),(100087,226,2,'GCV - Gewone commanditaire vennootschap',0,1,NULL,0),(100088,227,2,'Comm.VA - Commanditaire vennootschap op aandelen',0,1,NULL,0),(100089,228,2,'VOF - Vennootschap onder firma',0,1,NULL,0),(100090,229,2,'VS0 - Vennootschap met sociaal oogmerk',0,1,NULL,0),(100091,500,5,'GmbH - Gesellschaft mit beschränkter Haftung',0,1,NULL,0),(100092,501,5,'AG - Aktiengesellschaft ',0,1,NULL,0),(100093,502,5,'GmbH&Co. KG - Gesellschaft mit beschränkter Haftung & Compagnie Kommanditgesellschaft',0,1,NULL,0),(100094,503,5,'Gewerbe - Personengesellschaft',0,1,NULL,0),(100095,504,5,'UG - Unternehmergesellschaft -haftungsbeschränkt-',0,1,NULL,0),(100096,505,5,'GbR - Gesellschaft des bürgerlichen Rechts',0,1,NULL,0),(100097,506,5,'KG - Kommanditgesellschaft',0,1,NULL,0),(100098,507,5,'Ltd. - Limited Company',0,1,NULL,0),(100099,508,5,'OHG - Offene Handelsgesellschaft',0,1,NULL,0),(100100,10201,102,'Ατομική επιχείρηση',0,1,NULL,0),(100101,10202,102,'Εταιρική επιχείρηση',0,1,NULL,0),(100102,10203,102,'Ομόρρυθμη Εταιρεία Ο.Ε',0,1,NULL,0),(100103,10204,102,'Ετερόρρυθμη Εταιρεία Ε.Ε',0,1,NULL,0),(100104,10205,102,'Εταιρεία Περιορισμένης Ευθύνης Ε.Π.Ε',0,1,NULL,0),(100105,10206,102,'Ανώνυμη Εταιρεία Α.Ε',0,1,NULL,0),(100106,10207,102,'Ανώνυμη ναυτιλιακή εταιρεία Α.Ν.Ε',0,1,NULL,0),(100107,10208,102,'Συνεταιρισμός',0,1,NULL,0),(100108,10209,102,'Συμπλοιοκτησία',0,1,NULL,0),(100109,301,3,'Società semplice',0,1,NULL,0),(100110,302,3,'Società in nome collettivo s.n.c.',0,1,NULL,0),(100111,303,3,'Società in accomandita semplice s.a.s.',0,1,NULL,0),(100112,304,3,'Società per azioni s.p.a.',0,1,NULL,0),(100113,305,3,'Società a responsabilità limitata s.r.l.',0,1,NULL,0),(100114,306,3,'Società in accomandita per azioni s.a.p.a.',0,1,NULL,0),(100115,307,3,'Società cooperativa a r.l.',0,1,NULL,0),(100116,308,3,'Società consortile',0,1,NULL,0),(100117,309,3,'Società europea',0,1,NULL,0),(100118,310,3,'Società cooperativa europea',0,1,NULL,0),(100119,311,3,'Società unipersonale',0,1,NULL,0),(100120,312,3,'Società di professionisti',0,1,NULL,0),(100121,313,3,'Società di fatto',0,1,NULL,0),(100122,315,3,'Società apparente',0,1,NULL,0),(100123,316,3,'Impresa individuale ',0,1,NULL,0),(100124,317,3,'Impresa coniugale',0,1,NULL,0),(100125,318,3,'Impresa familiare',0,1,NULL,0),(100126,319,3,'Consorzio cooperativo',0,1,NULL,0),(100127,320,3,'Società cooperativa sociale',0,1,NULL,0),(100128,321,3,'Società cooperativa di consumo',0,1,NULL,0),(100129,322,3,'Società cooperativa agricola',0,1,NULL,0),(100130,323,3,'A.T.I. Associazione temporanea di imprese',0,1,NULL,0),(100131,324,3,'R.T.I. Raggruppamento temporaneo di imprese',0,1,NULL,0),(100132,325,3,'Studio associato',0,1,NULL,0),(100133,600,6,'Raison Individuelle',0,1,NULL,0),(100134,601,6,'Société Simple',0,1,NULL,0),(100135,602,6,'Société en nom collectif',0,1,NULL,0),(100136,603,6,'Société en commandite',0,1,NULL,0),(100137,604,6,'Société anonyme (SA)',0,1,NULL,0),(100138,605,6,'Société en commandite par actions',0,1,NULL,0),(100139,606,6,'Société à responsabilité limitée (SARL)',0,1,NULL,0),(100140,607,6,'Société coopérative',0,1,NULL,0),(100141,608,6,'Association',0,1,NULL,0),(100142,609,6,'Fondation',0,1,NULL,0),(100143,700,7,'Sole Trader',0,1,NULL,0),(100144,701,7,'Partnership',0,1,NULL,0),(100145,702,7,'Private Limited Company by shares (LTD)',0,1,NULL,0),(100146,703,7,'Public Limited Company',0,1,NULL,0),(100147,704,7,'Workers Cooperative',0,1,NULL,0),(100148,705,7,'Limited Liability Partnership',0,1,NULL,0),(100149,706,7,'Franchise',0,1,NULL,0),(100150,1000,10,'Société à responsabilité limitée (SARL)',0,1,NULL,0),(100151,1001,10,'Société en Nom Collectif (SNC)',0,1,NULL,0),(100152,1002,10,'Société en Commandite Simple (SCS)',0,1,NULL,0),(100153,1003,10,'société en participation',0,1,NULL,0),(100154,1004,10,'Société Anonyme (SA)',0,1,NULL,0),(100155,1005,10,'Société Unipersonnelle à Responsabilité Limitée (SUARL)',0,1,NULL,0),(100156,1006,10,'Groupement d\'intérêt économique (GEI)',0,1,NULL,0),(100157,1007,10,'Groupe de sociétés',0,1,NULL,0),(100158,1701,17,'Eenmanszaak',0,1,NULL,0),(100159,1702,17,'Maatschap',0,1,NULL,0),(100160,1703,17,'Vennootschap onder firma',0,1,NULL,0),(100161,1704,17,'Commanditaire vennootschap',0,1,NULL,0),(100162,1705,17,'Besloten vennootschap (BV)',0,1,NULL,0),(100163,1706,17,'Naamloze Vennootschap (NV)',0,1,NULL,0),(100164,1707,17,'Vereniging',0,1,NULL,0),(100165,1708,17,'Stichting',0,1,NULL,0),(100166,1709,17,'Coöperatie met beperkte aansprakelijkheid (BA)',0,1,NULL,0),(100167,1710,17,'Coöperatie met uitgesloten aansprakelijkheid (UA)',0,1,NULL,0),(100168,1711,17,'Coöperatie met wettelijke aansprakelijkheid (WA)',0,1,NULL,0),(100169,1712,17,'Onderlinge waarborgmaatschappij',0,1,NULL,0),(100170,401,4,'Empresario Individual',0,1,NULL,0),(100171,402,4,'Comunidad de Bienes',0,1,NULL,0),(100172,403,4,'Sociedad Civil',0,1,NULL,0),(100173,404,4,'Sociedad Colectiva',0,1,NULL,0),(100174,405,4,'Sociedad Limitada',0,1,NULL,0),(100175,406,4,'Sociedad Anónima',0,1,NULL,0),(100176,407,4,'Sociedad Comanditaria por Acciones',0,1,NULL,0),(100177,408,4,'Sociedad Comanditaria Simple',0,1,NULL,0),(100178,409,4,'Sociedad Laboral',0,1,NULL,0),(100179,410,4,'Sociedad Cooperativa',0,1,NULL,0),(100180,411,4,'Sociedad de Garantía Recíproca',0,1,NULL,0),(100181,412,4,'Entidad de Capital-Riesgo',0,1,NULL,0),(100182,413,4,'Agrupación de Interés Económico',0,1,NULL,0),(100183,414,4,'Sociedad de Inversión Mobiliaria',0,1,NULL,0),(100184,415,4,'Agrupación sin Ánimo de Lucro',0,1,NULL,0),(100185,15201,152,'Mauritius Private Company Limited By Shares',0,1,NULL,0),(100186,15202,152,'Mauritius Company Limited By Guarantee',0,1,NULL,0),(100187,15203,152,'Mauritius Public Company Limited By Shares',0,1,NULL,0),(100188,15204,152,'Mauritius Foreign Company',0,1,NULL,0),(100189,15205,152,'Mauritius GBC1 (Offshore Company)',0,1,NULL,0),(100190,15206,152,'Mauritius GBC2 (International Company)',0,1,NULL,0),(100191,15207,152,'Mauritius General Partnership',0,1,NULL,0),(100192,15208,152,'Mauritius Limited Partnership',0,1,NULL,0),(100193,15209,152,'Mauritius Sole Proprietorship',0,1,NULL,0),(100194,15210,152,'Mauritius Trusts',0,1,NULL,0),(100195,15401,154,'Sociedad en nombre colectivo',0,1,NULL,0),(100196,15402,154,'Sociedad en comandita simple',0,1,NULL,0),(100197,15403,154,'Sociedad de responsabilidad limitada',0,1,NULL,0),(100198,15404,154,'Sociedad anónima',0,1,NULL,0),(100199,15405,154,'Sociedad en comandita por acciones',0,1,NULL,0),(100200,15406,154,'Sociedad cooperativa',0,1,NULL,0),(100201,4100,41,'GmbH - Gesellschaft mit beschränkter Haftung',0,1,NULL,0),(100202,4101,41,'GesmbH - Gesellschaft mit beschränkter Haftung',0,1,NULL,0),(100203,4102,41,'AG - Aktiengesellschaft',0,1,NULL,0),(100204,4103,41,'EWIV - Europäische wirtschaftliche Interessenvereinigung',0,1,NULL,0),(100205,4104,41,'KEG - Kommanditerwerbsgesellschaft',0,1,NULL,0),(100206,4105,41,'OEG - Offene Erwerbsgesellschaft',0,1,NULL,0),(100207,4106,41,'OHG - Offene Handelsgesellschaft',0,1,NULL,0),(100208,4107,41,'AG & Co KG - Kommanditgesellschaft',0,1,NULL,0),(100209,4108,41,'GmbH & Co KG - Kommanditgesellschaft',0,1,NULL,0),(100210,4109,41,'KG - Kommanditgesellschaft',0,1,NULL,0),(100211,4110,41,'OG - Offene Gesellschaft',0,1,NULL,0),(100212,4111,41,'GbR - Gesellschaft nach bürgerlichem Recht',0,1,NULL,0),(100213,4112,41,'GesbR - Gesellschaft nach bürgerlichem Recht',0,1,NULL,0),(100214,4113,41,'GesnbR - Gesellschaft nach bürgerlichem Recht',0,1,NULL,0),(100215,4114,41,'e.U. - eingetragener Einzelunternehmer',0,1,NULL,0),(100216,17801,178,'Empresa individual',0,1,NULL,0),(100217,17802,178,'Asociación General',0,1,NULL,0),(100218,17803,178,'Sociedad de Responsabilidad Limitada',0,1,NULL,0),(100219,17804,178,'Sociedad Civil',0,1,NULL,0),(100220,17805,178,'Sociedad Anónima',0,1,NULL,0),(100221,8001,80,'Aktieselvskab A/S',0,1,NULL,0),(100222,8002,80,'Anparts Selvskab ApS',0,1,NULL,0),(100223,8003,80,'Personlig ejet selvskab',0,1,NULL,0),(100224,8004,80,'Iværksætterselvskab IVS',0,1,NULL,0),(100225,8005,80,'Interessentskab I/S',0,1,NULL,0),(100226,8006,80,'Holdingselskab',0,1,NULL,0),(100227,8007,80,'Selskab Med Begrænset Hæftelse SMBA',0,1,NULL,0),(100228,8008,80,'Kommanditselskab K/S',0,1,NULL,0),(100229,8009,80,'SPE-selskab',0,1,NULL,0); +INSERT INTO `llx_c_forme_juridique` VALUES (100001,100001,1,'Etudiant',0,0,'cabinetmed',0),(100002,100002,1,'Retraité',0,0,'cabinetmed',0),(100003,100003,1,'Artisan',0,0,'cabinetmed',0),(100004,100004,1,'Femme de ménage',0,0,'cabinetmed',0),(100005,100005,1,'Professeur',0,0,'cabinetmed',0),(100006,100006,1,'Profession libérale',0,0,'cabinetmed',0),(100007,100007,1,'Informaticien',0,0,'cabinetmed',0),(100009,0,0,'-',0,1,NULL,0),(100010,2301,23,'Monotributista',0,1,NULL,0),(100011,2302,23,'Sociedad Civil',0,1,NULL,0),(100012,2303,23,'Sociedades Comerciales',0,1,NULL,0),(100013,2304,23,'Sociedades de Hecho',0,1,NULL,0),(100014,2305,23,'Sociedades Irregulares',0,1,NULL,0),(100015,2306,23,'Sociedad Colectiva',0,1,NULL,0),(100016,2307,23,'Sociedad en Comandita Simple',0,1,NULL,0),(100017,2308,23,'Sociedad de Capital e Industria',0,1,NULL,0),(100018,2309,23,'Sociedad Accidental o en participación',0,1,NULL,0),(100019,2310,23,'Sociedad de Responsabilidad Limitada',0,1,NULL,0),(100020,2311,23,'Sociedad Anónima',0,1,NULL,0),(100021,2312,23,'Sociedad Anónima con Participación Estatal Mayoritaria',0,1,NULL,0),(100022,2313,23,'Sociedad en Comandita por Acciones (arts. 315 a 324, LSC)',0,1,NULL,0),(100023,11,1,'Artisan Commerçant (EI)',0,1,NULL,0),(100024,12,1,'Commerçant (EI)',0,1,NULL,0),(100025,13,1,'Artisan (EI)',0,1,NULL,0),(100026,14,1,'Officier public ou ministériel',0,1,NULL,0),(100027,15,1,'Profession libérale (EI)',0,1,NULL,0),(100028,16,1,'Exploitant agricole',0,1,NULL,0),(100029,17,1,'Agent commercial',0,1,NULL,0),(100030,18,1,'Associé Gérant de société',0,1,NULL,0),(100031,19,1,'Personne physique',0,1,NULL,0),(100032,21,1,'Indivision',0,1,NULL,0),(100033,22,1,'Société créée de fait',0,1,NULL,0),(100034,23,1,'Société en participation',0,1,NULL,0),(100035,27,1,'Paroisse hors zone concordataire',0,1,NULL,0),(100036,29,1,'Groupement de droit privé non doté de la personnalité morale',0,1,NULL,0),(100037,31,1,'Personne morale de droit étranger, immatriculée au RCS',0,1,NULL,0),(100038,32,1,'Personne morale de droit étranger, non immatriculée au RCS',0,1,NULL,0),(100039,35,1,'Régime auto-entrepreneur',0,1,NULL,0),(100040,41,1,'Etablissement public ou régie à caractère industriel ou commercial',0,1,NULL,0),(100041,51,1,'Société coopérative commerciale particulière',0,1,NULL,0),(100042,52,1,'Société en nom collectif',0,1,NULL,0),(100043,53,1,'Société en commandite',0,1,NULL,0),(100044,54,1,'Société à responsabilité limitée (SARL)',0,1,NULL,0),(100045,55,1,'Société anonyme à conseil d administration',0,1,NULL,0),(100046,56,1,'Société anonyme à directoire',0,1,NULL,0),(100047,57,1,'Société par actions simplifiée (SAS)',0,1,NULL,0),(100048,58,1,'Entreprise Unipersonnelle à Responsabilité Limitée (EURL)',0,1,NULL,0),(100049,59,1,'Société par actions simplifiée unipersonnelle (SASU)',0,1,NULL,0),(100050,60,1,'Entreprise Individuelle à Responsabilité Limitée (EIRL)',0,1,NULL,0),(100051,61,1,'Caisse d\'épargne et de prévoyance',0,1,NULL,0),(100052,62,1,'Groupement d\'intérêt économique (GIE)',0,1,NULL,0),(100053,63,1,'Société coopérative agricole',0,1,NULL,0),(100054,64,1,'Société non commerciale d assurances',0,1,NULL,0),(100055,65,1,'Société civile',0,1,NULL,0),(100056,69,1,'Personnes de droit privé inscrites au RCS',0,1,NULL,0),(100057,71,1,'Administration de l état',0,1,NULL,0),(100058,72,1,'Collectivité territoriale',0,1,NULL,0),(100059,73,1,'Etablissement public administratif',0,1,NULL,0),(100060,74,1,'Personne morale de droit public administratif',0,1,NULL,0),(100061,81,1,'Organisme gérant régime de protection social à adhésion obligatoire',0,1,NULL,0),(100062,82,1,'Organisme mutualiste',0,1,NULL,0),(100063,83,1,'Comité d entreprise',0,1,NULL,0),(100064,84,1,'Organisme professionnel',0,1,NULL,0),(100065,85,1,'Organisme de retraite à adhésion non obligatoire',0,1,NULL,0),(100066,91,1,'Syndicat de propriétaires',0,1,NULL,0),(100067,92,1,'Association loi 1901 ou assimilé',0,1,NULL,0),(100068,93,1,'Fondation',0,1,NULL,0),(100069,99,1,'Personne morale de droit privé',0,1,NULL,0),(100070,200,2,'Indépendant',0,1,NULL,0),(100071,201,2,'SRL - Société à responsabilité limitée',0,1,NULL,0),(100072,202,2,'SA - Société Anonyme',0,1,NULL,0),(100073,203,2,'SCRL - Société coopérative à responsabilité limitée',0,1,NULL,0),(100074,204,2,'ASBL - Association sans but Lucratif',0,1,NULL,0),(100075,205,2,'SCRI - Société coopérative à responsabilité illimitée',0,1,NULL,0),(100076,206,2,'SCS - Société en commandite simple',0,1,NULL,0),(100077,207,2,'SCA - Société en commandite par action',0,1,NULL,0),(100078,208,2,'SNC - Société en nom collectif',0,1,NULL,0),(100079,209,2,'GIE - Groupement d intérêt économique',0,1,NULL,0),(100080,210,2,'GEIE - Groupement européen d intérêt économique',0,1,NULL,0),(100081,220,2,'Eenmanszaak',0,1,NULL,0),(100082,221,2,'BVBA - Besloten vennootschap met beperkte aansprakelijkheid',0,1,NULL,0),(100083,222,2,'NV - Naamloze Vennootschap',0,1,NULL,0),(100084,223,2,'CVBA - Coöperatieve vennootschap met beperkte aansprakelijkheid',0,1,NULL,0),(100085,224,2,'VZW - Vereniging zonder winstoogmerk',0,1,NULL,0),(100086,225,2,'CVOA - Coöperatieve vennootschap met onbeperkte aansprakelijkheid ',0,1,NULL,0),(100087,226,2,'GCV - Gewone commanditaire vennootschap',0,1,NULL,0),(100088,227,2,'Comm.VA - Commanditaire vennootschap op aandelen',0,1,NULL,0),(100089,228,2,'VOF - Vennootschap onder firma',0,1,NULL,0),(100090,229,2,'VS0 - Vennootschap met sociaal oogmerk',0,1,NULL,0),(100091,500,5,'GmbH - Gesellschaft mit beschränkter Haftung',0,1,NULL,0),(100092,501,5,'AG - Aktiengesellschaft ',0,1,NULL,0),(100093,502,5,'GmbH&Co. KG - Gesellschaft mit beschränkter Haftung & Compagnie Kommanditgesellschaft',0,1,NULL,0),(100094,503,5,'Gewerbe - Personengesellschaft',0,1,NULL,0),(100095,504,5,'UG - Unternehmergesellschaft -haftungsbeschränkt-',0,1,NULL,0),(100096,505,5,'GbR - Gesellschaft des bürgerlichen Rechts',0,1,NULL,0),(100097,506,5,'KG - Kommanditgesellschaft',0,1,NULL,0),(100098,507,5,'Ltd. - Limited Company',0,1,NULL,0),(100099,508,5,'OHG - Offene Handelsgesellschaft',0,1,NULL,0),(100100,10201,102,'Ατομική επιχείρηση',0,1,NULL,0),(100101,10202,102,'Εταιρική επιχείρηση',0,1,NULL,0),(100102,10203,102,'Ομόρρυθμη Εταιρεία Ο.Ε',0,1,NULL,0),(100103,10204,102,'Ετερόρρυθμη Εταιρεία Ε.Ε',0,1,NULL,0),(100104,10205,102,'Εταιρεία Περιορισμένης Ευθύνης Ε.Π.Ε',0,1,NULL,0),(100105,10206,102,'Ανώνυμη Εταιρεία Α.Ε',0,1,NULL,0),(100106,10207,102,'Ανώνυμη ναυτιλιακή εταιρεία Α.Ν.Ε',0,1,NULL,0),(100107,10208,102,'Συνεταιρισμός',0,1,NULL,0),(100108,10209,102,'Συμπλοιοκτησία',0,1,NULL,0),(100109,301,3,'Società semplice',0,1,NULL,0),(100110,302,3,'Società in nome collettivo s.n.c.',0,1,NULL,0),(100111,303,3,'Società in accomandita semplice s.a.s.',0,1,NULL,0),(100112,304,3,'Società per azioni s.p.a.',0,1,NULL,0),(100113,305,3,'Società a responsabilità limitata s.r.l.',0,1,NULL,0),(100114,306,3,'Società in accomandita per azioni s.a.p.a.',0,1,NULL,0),(100115,307,3,'Società cooperativa a r.l.',0,1,NULL,0),(100116,308,3,'Società consortile',0,1,NULL,0),(100117,309,3,'Società europea',0,1,NULL,0),(100118,310,3,'Società cooperativa europea',0,1,NULL,0),(100119,311,3,'Società unipersonale',0,1,NULL,0),(100120,312,3,'Società di professionisti',0,1,NULL,0),(100121,313,3,'Società di fatto',0,1,NULL,0),(100122,315,3,'Società apparente',0,1,NULL,0),(100123,316,3,'Impresa individuale ',0,1,NULL,0),(100124,317,3,'Impresa coniugale',0,1,NULL,0),(100125,318,3,'Impresa familiare',0,1,NULL,0),(100126,319,3,'Consorzio cooperativo',0,1,NULL,0),(100127,320,3,'Società cooperativa sociale',0,1,NULL,0),(100128,321,3,'Società cooperativa di consumo',0,1,NULL,0),(100129,322,3,'Società cooperativa agricola',0,1,NULL,0),(100130,323,3,'A.T.I. Associazione temporanea di imprese',0,1,NULL,0),(100131,324,3,'R.T.I. Raggruppamento temporaneo di imprese',0,1,NULL,0),(100132,325,3,'Studio associato',0,1,NULL,0),(100133,600,6,'Raison Individuelle',0,1,NULL,0),(100134,601,6,'Société Simple',0,1,NULL,0),(100135,602,6,'Société en nom collectif',0,1,NULL,0),(100136,603,6,'Société en commandite',0,1,NULL,0),(100137,604,6,'Société anonyme (SA)',0,1,NULL,0),(100138,605,6,'Société en commandite par actions',0,1,NULL,0),(100139,606,6,'Société à responsabilité limitée (SARL)',0,1,NULL,0),(100140,607,6,'Société coopérative',0,1,NULL,0),(100141,608,6,'Association',0,1,NULL,0),(100142,609,6,'Fondation',0,1,NULL,0),(100143,700,7,'Sole Trader',0,1,NULL,0),(100144,701,7,'Partnership',0,1,NULL,0),(100145,702,7,'Private Limited Company by shares (LTD)',0,1,NULL,0),(100146,703,7,'Public Limited Company',0,1,NULL,0),(100147,704,7,'Workers Cooperative',0,1,NULL,0),(100148,705,7,'Limited Liability Partnership',0,1,NULL,0),(100149,706,7,'Franchise',0,1,NULL,0),(100150,1000,10,'Société à responsabilité limitée (SARL)',0,1,NULL,0),(100151,1001,10,'Société en Nom Collectif (SNC)',0,1,NULL,0),(100152,1002,10,'Société en Commandite Simple (SCS)',0,1,NULL,0),(100153,1003,10,'société en participation',0,1,NULL,0),(100154,1004,10,'Société Anonyme (SA)',0,1,NULL,0),(100155,1005,10,'Société Unipersonnelle à Responsabilité Limitée (SUARL)',0,1,NULL,0),(100156,1006,10,'Groupement d\'intérêt économique (GEI)',0,1,NULL,0),(100157,1007,10,'Groupe de sociétés',0,1,NULL,0),(100158,1701,17,'Eenmanszaak',0,1,NULL,0),(100159,1702,17,'Maatschap',0,1,NULL,0),(100160,1703,17,'Vennootschap onder firma',0,1,NULL,0),(100161,1704,17,'Commanditaire vennootschap',0,1,NULL,0),(100162,1705,17,'Besloten vennootschap (BV)',0,1,NULL,0),(100163,1706,17,'Naamloze Vennootschap (NV)',0,1,NULL,0),(100164,1707,17,'Vereniging',0,1,NULL,0),(100165,1708,17,'Stichting',0,1,NULL,0),(100166,1709,17,'Coöperatie met beperkte aansprakelijkheid (BA)',0,1,NULL,0),(100167,1710,17,'Coöperatie met uitgesloten aansprakelijkheid (UA)',0,1,NULL,0),(100168,1711,17,'Coöperatie met wettelijke aansprakelijkheid (WA)',0,1,NULL,0),(100169,1712,17,'Onderlinge waarborgmaatschappij',0,1,NULL,0),(100170,401,4,'Empresario Individual',0,1,NULL,0),(100171,402,4,'Comunidad de Bienes',0,1,NULL,0),(100172,403,4,'Sociedad Civil',0,1,NULL,0),(100173,404,4,'Sociedad Colectiva',0,1,NULL,0),(100174,405,4,'Sociedad Limitada',0,1,NULL,0),(100175,406,4,'Sociedad Anónima',0,1,NULL,0),(100176,407,4,'Sociedad Comanditaria por Acciones',0,1,NULL,0),(100177,408,4,'Sociedad Comanditaria Simple',0,1,NULL,0),(100178,409,4,'Sociedad Laboral',0,1,NULL,0),(100179,410,4,'Sociedad Cooperativa',0,1,NULL,0),(100180,411,4,'Sociedad de Garantía Recíproca',0,1,NULL,0),(100181,412,4,'Entidad de Capital-Riesgo',0,1,NULL,0),(100182,413,4,'Agrupación de Interés Económico',0,1,NULL,0),(100183,414,4,'Sociedad de Inversión Mobiliaria',0,1,NULL,0),(100184,415,4,'Agrupación sin Ánimo de Lucro',0,1,NULL,0),(100185,15201,152,'Mauritius Private Company Limited By Shares',0,1,NULL,0),(100186,15202,152,'Mauritius Company Limited By Guarantee',0,1,NULL,0),(100187,15203,152,'Mauritius Public Company Limited By Shares',0,1,NULL,0),(100188,15204,152,'Mauritius Foreign Company',0,1,NULL,0),(100189,15205,152,'Mauritius GBC1 (Offshore Company)',0,1,NULL,0),(100190,15206,152,'Mauritius GBC2 (International Company)',0,1,NULL,0),(100191,15207,152,'Mauritius General Partnership',0,1,NULL,0),(100192,15208,152,'Mauritius Limited Partnership',0,1,NULL,0),(100193,15209,152,'Mauritius Sole Proprietorship',0,1,NULL,0),(100194,15210,152,'Mauritius Trusts',0,1,NULL,0),(100195,15401,154,'Sociedad en nombre colectivo',0,1,NULL,0),(100196,15402,154,'Sociedad en comandita simple',0,1,NULL,0),(100197,15403,154,'Sociedad de responsabilidad limitada',0,1,NULL,0),(100198,15404,154,'Sociedad anónima',0,1,NULL,0),(100199,15405,154,'Sociedad en comandita por acciones',0,1,NULL,0),(100200,15406,154,'Sociedad cooperativa',0,1,NULL,0),(100201,4100,41,'GmbH - Gesellschaft mit beschränkter Haftung',0,1,NULL,0),(100202,4101,41,'GesmbH - Gesellschaft mit beschränkter Haftung',0,1,NULL,0),(100203,4102,41,'AG - Aktiengesellschaft',0,1,NULL,0),(100204,4103,41,'EWIV - Europäische wirtschaftliche Interessenvereinigung',0,1,NULL,0),(100205,4104,41,'KEG - Kommanditerwerbsgesellschaft',0,1,NULL,0),(100206,4105,41,'OEG - Offene Erwerbsgesellschaft',0,1,NULL,0),(100207,4106,41,'OHG - Offene Handelsgesellschaft',0,1,NULL,0),(100208,4107,41,'AG & Co KG - Kommanditgesellschaft',0,1,NULL,0),(100209,4108,41,'GmbH & Co KG - Kommanditgesellschaft',0,1,NULL,0),(100210,4109,41,'KG - Kommanditgesellschaft',0,1,NULL,0),(100211,4110,41,'OG - Offene Gesellschaft',0,1,NULL,0),(100212,4111,41,'GbR - Gesellschaft nach bürgerlichem Recht',0,1,NULL,0),(100213,4112,41,'GesbR - Gesellschaft nach bürgerlichem Recht',0,1,NULL,0),(100214,4113,41,'GesnbR - Gesellschaft nach bürgerlichem Recht',0,1,NULL,0),(100215,4114,41,'e.U. - eingetragener Einzelunternehmer',0,1,NULL,0),(100216,17801,178,'Empresa individual',0,1,NULL,0),(100217,17802,178,'Asociación General',0,1,NULL,0),(100218,17803,178,'Sociedad de Responsabilidad Limitada',0,1,NULL,0),(100219,17804,178,'Sociedad Civil',0,1,NULL,0),(100220,17805,178,'Sociedad Anónima',0,1,NULL,0),(100221,8001,80,'Aktieselvskab A/S',0,1,NULL,0),(100222,8002,80,'Anparts Selvskab ApS',0,1,NULL,0),(100223,8003,80,'Personlig ejet selvskab',0,1,NULL,0),(100224,8004,80,'Iværksætterselvskab IVS',0,1,NULL,0),(100225,8005,80,'Interessentskab I/S',0,1,NULL,0),(100226,8006,80,'Holdingselskab',0,1,NULL,0),(100227,8007,80,'Selskab Med Begrænset Hæftelse SMBA',0,1,NULL,0),(100228,8008,80,'Kommanditselskab K/S',0,1,NULL,0),(100229,8009,80,'SPE-selskab',0,1,NULL,0),(100230,2001,20,'Aktiebolag',0,1,NULL,0),(100231,2002,20,'Publikt aktiebolag (AB publ)',0,1,NULL,0),(100232,2003,20,'Ekonomisk förening (ek. för.)',0,1,NULL,0),(100233,2004,20,'Bostadsrättsförening (BRF)',0,1,NULL,0),(100234,2005,20,'Hyresrättsförening (HRF)',0,1,NULL,0),(100235,2006,20,'Kooperativ',0,1,NULL,0),(100236,2007,20,'Enskild firma (EF)',0,1,NULL,0),(100237,2008,20,'Handelsbolag (HB)',0,1,NULL,0),(100238,2009,20,'Kommanditbolag (KB)',0,1,NULL,0),(100239,2010,20,'Enkelt bolag',0,1,NULL,0),(100240,2011,20,'Ideell förening',0,1,NULL,0),(100241,2012,20,'Stiftelse',0,1,NULL,0); /*!40000 ALTER TABLE `llx_c_forme_juridique` ENABLE KEYS */; UNLOCK TABLES; @@ -2296,7 +2287,7 @@ CREATE TABLE `llx_c_paiement` ( `position` int(11) NOT NULL DEFAULT 0, PRIMARY KEY (`id`), UNIQUE KEY `uk_c_paiement_code` (`entity`,`code`) -) ENGINE=InnoDB AUTO_INCREMENT=54 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=105 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -2305,7 +2296,7 @@ CREATE TABLE `llx_c_paiement` ( LOCK TABLES `llx_c_paiement` WRITE; /*!40000 ALTER TABLE `llx_c_paiement` DISABLE KEYS */; -INSERT INTO `llx_c_paiement` VALUES (1,1,'TIP','TIP',2,0,NULL,NULL,0),(2,1,'VIR','Virement',2,1,NULL,NULL,0),(3,1,'PRE','Prélèvement',2,1,NULL,NULL,0),(4,1,'LIQ','Espèces',2,1,NULL,NULL,0),(6,1,'CB','Carte Bancaire',2,1,NULL,NULL,0),(7,1,'CHQ','Chèque',2,1,NULL,NULL,0),(50,1,'VAD','Paiement en ligne',2,0,NULL,NULL,0),(51,1,'TRA','Traite',2,0,NULL,NULL,0),(52,1,'LCR','LCR',2,0,NULL,NULL,0),(53,1,'FAC','Factor',2,0,NULL,NULL,0); +INSERT INTO `llx_c_paiement` VALUES (1,1,'TIP','TIP',2,0,NULL,NULL,0),(2,1,'VIR','Virement',2,1,NULL,NULL,0),(3,1,'PRE','Prélèvement',2,1,NULL,NULL,0),(4,1,'LIQ','Espèces',2,1,NULL,NULL,0),(6,1,'CB','Carte Bancaire',2,1,NULL,NULL,0),(7,1,'CHQ','Chèque',2,1,NULL,NULL,0),(50,1,'VAD','Paiement en ligne',2,0,NULL,NULL,0),(51,1,'TRA','Traite',2,0,NULL,NULL,0),(52,1,'LCR','LCR',2,0,NULL,NULL,0),(53,1,'FAC','Factor',2,0,NULL,NULL,0),(100,1,'KLA','Klarna',1,0,NULL,NULL,0),(101,1,'SOF','Sofort',1,0,NULL,NULL,0),(102,1,'BAN','Bancontact',1,0,NULL,NULL,0),(103,1,'IDE','iDeal',1,0,NULL,NULL,0),(104,1,'GIR','Giropay',1,0,NULL,NULL,0); /*!40000 ALTER TABLE `llx_c_paiement` ENABLE KEYS */; UNLOCK TABLES; @@ -2352,7 +2343,8 @@ CREATE TABLE `llx_c_partnership_type` ( `code` varchar(32) COLLATE utf8_unicode_ci NOT NULL, `label` varchar(64) COLLATE utf8_unicode_ci NOT NULL, `active` tinyint(4) NOT NULL DEFAULT 1, - PRIMARY KEY (`rowid`) + PRIMARY KEY (`rowid`), + UNIQUE KEY `uk_c_partnership_type` (`entity`,`code`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; @@ -3194,6 +3186,7 @@ DROP TABLE IF EXISTS `llx_c_units`; CREATE TABLE `llx_c_units` ( `rowid` int(11) NOT NULL AUTO_INCREMENT, `code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, + `sortorder` smallint(6) DEFAULT NULL, `label` varchar(50) COLLATE utf8_unicode_ci DEFAULT NULL, `short_label` varchar(5) COLLATE utf8_unicode_ci DEFAULT NULL, `active` tinyint(4) NOT NULL DEFAULT 1, @@ -3210,7 +3203,7 @@ CREATE TABLE `llx_c_units` ( LOCK TABLES `llx_c_units` WRITE; /*!40000 ALTER TABLE `llx_c_units` DISABLE KEYS */; -INSERT INTO `llx_c_units` VALUES (1,'P','piece','p',1,NULL,NULL),(2,'SET','set','se',1,NULL,NULL),(3,'S','second','s',1,NULL,'time'),(4,'H','hour','h',1,3600,'time'),(5,'D','day','d',1,86400,'time'),(6,'KG','kilogram','kg',1,0,'weight'),(7,'G','gram','g',1,-3,'weight'),(8,'M','SizeUnitm','m',1,0,'size'),(9,'LM','linear meter','lm',0,0,'size'),(10,'M2','SurfaceUnitm2','m2',1,0,'surface'),(11,'M3','VolumeUnitm3','m3',1,0,'volume'),(12,'L','liter','l',0,-3,'volume'),(13,'T','WeightUnitton','T',1,3,'weight'),(16,'MG','WeightUnitmg','mg',1,-6,'weight'),(17,'OZ','WeightUnitounce','Oz',1,98,'weight'),(18,'LB','WeightUnitpound','lb',1,99,'weight'),(20,'DM','SizeUnitdm','dm',1,-1,'size'),(21,'CM','SizeUnitcm','cm',1,-2,'size'),(22,'MM','SizeUnitmm','mm',1,-3,'size'),(23,'FT','SizeUnitfoot','ft',1,98,'size'),(24,'IN','SizeUnitinch','in',1,99,'size'),(26,'DM2','SurfaceUnitdm2','dm2',1,-2,'surface'),(27,'CM2','SurfaceUnitcm2','cm2',1,-4,'surface'),(28,'MM2','SurfaceUnitmm2','mm2',1,-6,'surface'),(29,'FT2','SurfaceUnitfoot2','ft2',1,98,'surface'),(30,'IN2','SurfaceUnitinch2','in2',1,99,'surface'),(32,'DM3','VolumeUnitdm3','dm3',1,-3,'volume'),(33,'CM3','VolumeUnitcm3','cm3',1,-6,'volume'),(34,'MM3','VolumeUnitmm3','mm3',1,-9,'volume'),(35,'FT3','VolumeUnitfoot3','ft3',1,88,'volume'),(36,'IN3','VolumeUnitinch3','in3',1,89,'volume'),(37,'OZ3','VolumeUnitounce','Oz',1,97,'volume'),(39,'GAL','VolumeUnitgallon','gal',1,99,'volume'),(43,'MI','minute','i',1,60,'time'),(46,'W','week','w',1,604800,'time'),(47,'MO','month','m',1,2629800,'time'),(48,'Y','year','y',1,31557600,'time'); +INSERT INTO `llx_c_units` VALUES (1,'P',NULL,'piece','p',1,NULL,NULL),(2,'SET',NULL,'set','se',1,NULL,NULL),(3,'S',NULL,'second','s',1,NULL,'time'),(4,'H',NULL,'hour','h',1,3600,'time'),(5,'D',NULL,'day','d',1,86400,'time'),(6,'KG',NULL,'kilogram','kg',1,0,'weight'),(7,'G',NULL,'gram','g',1,-3,'weight'),(8,'M',NULL,'SizeUnitm','m',1,0,'size'),(9,'LM',NULL,'linear meter','lm',0,0,'size'),(10,'M2',NULL,'SurfaceUnitm2','m2',1,0,'surface'),(11,'M3',NULL,'VolumeUnitm3','m3',1,0,'volume'),(12,'L',NULL,'liter','l',0,-3,'volume'),(13,'T',NULL,'WeightUnitton','T',1,3,'weight'),(16,'MG',NULL,'WeightUnitmg','mg',1,-6,'weight'),(17,'OZ',NULL,'WeightUnitounce','Oz',1,98,'weight'),(18,'LB',NULL,'WeightUnitpound','lb',1,99,'weight'),(20,'DM',NULL,'SizeUnitdm','dm',1,-1,'size'),(21,'CM',NULL,'SizeUnitcm','cm',1,-2,'size'),(22,'MM',NULL,'SizeUnitmm','mm',1,-3,'size'),(23,'FT',NULL,'SizeUnitfoot','ft',1,98,'size'),(24,'IN',NULL,'SizeUnitinch','in',1,99,'size'),(26,'DM2',NULL,'SurfaceUnitdm2','dm2',1,-2,'surface'),(27,'CM2',NULL,'SurfaceUnitcm2','cm2',1,-4,'surface'),(28,'MM2',NULL,'SurfaceUnitmm2','mm2',1,-6,'surface'),(29,'FT2',NULL,'SurfaceUnitfoot2','ft2',1,98,'surface'),(30,'IN2',NULL,'SurfaceUnitinch2','in2',1,99,'surface'),(32,'DM3',NULL,'VolumeUnitdm3','dm3',1,-3,'volume'),(33,'CM3',NULL,'VolumeUnitcm3','cm3',1,-6,'volume'),(34,'MM3',NULL,'VolumeUnitmm3','mm3',1,-9,'volume'),(35,'FT3',NULL,'VolumeUnitfoot3','ft3',1,88,'volume'),(36,'IN3',NULL,'VolumeUnitinch3','in3',1,89,'volume'),(37,'OZ3',NULL,'VolumeUnitounce','Oz',1,97,'volume'),(39,'GAL',NULL,'VolumeUnitgallon','gal',1,99,'volume'),(43,'MI',NULL,'minute','i',1,60,'time'),(46,'W',NULL,'week','w',1,604800,'time'),(47,'MO',NULL,'month','m',1,2629800,'time'),(48,'Y',NULL,'year','y',1,31557600,'time'); /*!40000 ALTER TABLE `llx_c_units` ENABLE KEYS */; UNLOCK TABLES; @@ -3819,6 +3812,34 @@ INSERT INTO `llx_categorie_fournisseur` VALUES (1,2,NULL),(1,10,NULL),(1,13,NULL /*!40000 ALTER TABLE `llx_categorie_fournisseur` ENABLE KEYS */; UNLOCK TABLES; +-- +-- Table structure for table `llx_categorie_knowledgemanagement` +-- + +DROP TABLE IF EXISTS `llx_categorie_knowledgemanagement`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `llx_categorie_knowledgemanagement` ( + `fk_categorie` int(11) NOT NULL, + `fk_knowledgemanagement` int(11) NOT NULL, + `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, + PRIMARY KEY (`fk_categorie`,`fk_knowledgemanagement`), + KEY `idx_categorie_knowledgemanagement_fk_categorie` (`fk_categorie`), + KEY `idx_categorie_knowledgemanagement_fk_knowledgemanagement` (`fk_knowledgemanagement`), + CONSTRAINT `fk_categorie_knowledgemanagement_categorie_rowid` FOREIGN KEY (`fk_categorie`) REFERENCES `llx_categorie` (`rowid`), + CONSTRAINT `fk_categorie_knowledgemanagement_knowledgemanagement_rowid` FOREIGN KEY (`fk_knowledgemanagement`) REFERENCES `llx_knowledgemanagement_knowledgerecord` (`rowid`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `llx_categorie_knowledgemanagement` +-- + +LOCK TABLES `llx_categorie_knowledgemanagement` WRITE; +/*!40000 ALTER TABLE `llx_categorie_knowledgemanagement` DISABLE KEYS */; +/*!40000 ALTER TABLE `llx_categorie_knowledgemanagement` ENABLE KEYS */; +UNLOCK TABLES; + -- -- Table structure for table `llx_categorie_lang` -- @@ -3963,6 +3984,34 @@ INSERT INTO `llx_categorie_societe` VALUES (12,10,NULL),(12,11,NULL),(14,11,NULL /*!40000 ALTER TABLE `llx_categorie_societe` ENABLE KEYS */; UNLOCK TABLES; +-- +-- Table structure for table `llx_categorie_ticket` +-- + +DROP TABLE IF EXISTS `llx_categorie_ticket`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `llx_categorie_ticket` ( + `fk_categorie` int(11) NOT NULL, + `fk_ticket` int(11) NOT NULL, + `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, + PRIMARY KEY (`fk_categorie`,`fk_ticket`), + KEY `idx_categorie_ticket_fk_categorie` (`fk_categorie`), + KEY `idx_categorie_ticket_fk_ticket` (`fk_ticket`), + CONSTRAINT `fk_categorie_ticket_categorie_rowid` FOREIGN KEY (`fk_categorie`) REFERENCES `llx_categorie` (`rowid`), + CONSTRAINT `fk_categorie_ticket_ticket_rowid` FOREIGN KEY (`fk_ticket`) REFERENCES `llx_ticket` (`rowid`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `llx_categorie_ticket` +-- + +LOCK TABLES `llx_categorie_ticket` WRITE; +/*!40000 ALTER TABLE `llx_categorie_ticket` DISABLE KEYS */; +/*!40000 ALTER TABLE `llx_categorie_ticket` ENABLE KEYS */; +UNLOCK TABLES; + -- -- Table structure for table `llx_categorie_user` -- @@ -4173,7 +4222,7 @@ CREATE TABLE `llx_commande` ( `fk_incoterms` int(11) DEFAULT NULL, `location_incoterms` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_tx` double(24,8) DEFAULT 1.00000000, `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000, `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000, @@ -4204,7 +4253,7 @@ CREATE TABLE `llx_commande` ( LOCK TABLES `llx_commande` WRITE; /*!40000 ALTER TABLE `llx_commande` DISABLE KEYS */; -INSERT INTO `llx_commande` VALUES (1,'2020-12-10 12:24:22',1,NULL,'CO1107-0002',1,NULL,NULL,'','2013-07-20 15:23:12','2020-08-08 13:59:09',NULL,'2020-07-20',1,NULL,1,NULL,NULL,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,10.00000000,10.00000000,'','','einstein',0,NULL,NULL,1,1,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL),(2,'2020-12-10 12:24:22',1,NULL,'CO1107-0003',1,NULL,NULL,'','2013-07-20 23:20:12','2020-02-12 17:06:51',NULL,'2020-07-21',1,NULL,1,NULL,NULL,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,10.00000000,10.00000000,'','','einstein',0,NULL,NULL,0,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL),(3,'2020-12-10 12:24:22',1,NULL,'CO1107-0004',1,NULL,NULL,'','2013-07-20 23:22:53','2020-02-17 18:27:56',NULL,'2020-07-21',1,NULL,1,NULL,NULL,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,30.00000000,30.00000000,'','','einstein',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL),(5,'2020-12-10 12:24:22',1,NULL,'CO1108-0001',1,NULL,NULL,'','2013-08-08 03:04:11','2020-08-08 03:04:21',NULL,'2020-08-08',1,NULL,1,NULL,NULL,2,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,10.00000000,10.00000000,'','','einstein',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL),(6,'2021-04-15 10:22:31',19,NULL,'(PROV6)',1,NULL,NULL,'','2015-02-17 16:22:14',NULL,NULL,'2021-02-17',1,NULL,NULL,NULL,NULL,0,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,'','','einstein',0,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,'commande/(PROV6)/(PROV6).pdf',NULL,NULL),(17,'2021-07-11 17:49:28',4,NULL,'CO7001-0005',1,NULL,NULL,NULL,'2017-02-15 23:50:34','2020-02-15 23:50:34',NULL,'2021-05-13',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,509.00000000,509.00000000,'','','',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,509.00000000,0.00000000,509.00000000,NULL,NULL,NULL),(18,'2021-04-15 10:22:31',7,4,'CO7001-0006',1,NULL,NULL,NULL,'2017-02-15 23:51:23','2021-02-15 23:51:23',NULL,'2021-02-03',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,900.00000000,900.00000000,'','','',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,900.00000000,0.00000000,900.00000000,NULL,NULL,NULL),(20,'2021-04-15 10:22:31',4,NULL,'CO7001-0007',1,NULL,NULL,NULL,'2017-02-15 23:55:52','2020-02-15 23:55:52',NULL,'2021-04-03',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,330.00000000,330.00000000,'','','',0,NULL,NULL,2,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,330.00000000,0.00000000,330.00000000,NULL,NULL,NULL),(29,'2021-04-15 10:22:31',4,NULL,'CO7001-0008',1,NULL,NULL,NULL,'2017-02-16 00:03:44','2021-02-16 00:03:44',NULL,'2021-02-12',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,457.00000000,457.00000000,'','','',0,NULL,NULL,1,NULL,NULL,2,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,457.00000000,0.00000000,457.00000000,NULL,NULL,NULL),(34,'2021-04-15 10:22:31',11,NULL,'CO7001-0009',1,NULL,NULL,NULL,'2017-02-16 00:05:01','2021-02-16 00:05:01',NULL,'2021-01-03',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,124.00000000,124.00000000,'','','',0,NULL,NULL,2,NULL,NULL,2,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,124.00000000,0.00000000,124.00000000,NULL,NULL,NULL),(38,'2021-04-15 10:22:31',3,NULL,'CO7001-0010',1,NULL,NULL,NULL,'2017-02-16 00:05:01','2021-02-16 00:05:01',NULL,'2021-02-03',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,200.00000000,200.00000000,'','','',0,NULL,NULL,1,NULL,NULL,2,NULL,1,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,200.00000000,0.00000000,200.00000000,NULL,NULL,NULL),(40,'2021-04-15 10:22:31',11,NULL,'CO7001-0011',1,NULL,NULL,NULL,'2017-02-16 00:05:10','2021-02-16 00:05:11',NULL,'2021-01-23',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,1210.00000000,1210.00000000,'','','',0,NULL,NULL,1,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,1210.00000000,0.00000000,1210.00000000,NULL,NULL,NULL),(43,'2021-04-15 10:22:31',10,NULL,'CO7001-0012',1,NULL,NULL,NULL,'2017-02-16 00:05:11','2021-02-16 00:05:11',NULL,'2021-02-13',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,478.00000000,478.00000000,'','','',0,NULL,NULL,2,NULL,NULL,2,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,478.00000000,0.00000000,478.00000000,NULL,NULL,NULL),(47,'2020-12-10 12:24:22',1,NULL,'CO7001-0013',1,NULL,NULL,NULL,'2017-02-16 00:05:11','2020-02-16 00:05:11',NULL,'2020-11-13',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,55.00000000,55.00000000,'','','',0,NULL,NULL,2,NULL,NULL,1,NULL,1,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,55.00000000,0.00000000,55.00000000,NULL,NULL,NULL),(48,'2020-12-10 12:24:22',4,NULL,'CO7001-0014',1,NULL,NULL,NULL,'2017-02-16 00:05:11','2020-02-16 00:05:11',NULL,'2020-07-30',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,540.00000000,540.00000000,'','','',0,NULL,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,540.00000000,0.00000000,540.00000000,NULL,NULL,NULL),(50,'2021-04-15 10:22:31',1,NULL,'CO7001-0015',1,NULL,NULL,NULL,'2017-02-16 00:05:26','2021-02-16 00:05:26',NULL,'2020-12-12',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,118.00000000,118.00000000,'','','',0,NULL,NULL,1,NULL,NULL,1,NULL,1,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,118.00000000,0.00000000,118.00000000,NULL,NULL,NULL),(54,'2021-07-11 17:49:28',12,NULL,'CO7001-0016',1,NULL,NULL,NULL,'2017-02-16 00:05:26','2020-02-16 00:05:26','2020-02-16 03:05:56','2021-06-03',12,NULL,12,12,1,3,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,220.00000000,220.00000000,'','','',1,NULL,NULL,NULL,NULL,NULL,1,NULL,1,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,220.00000000,0.00000000,220.00000000,NULL,NULL,NULL),(58,'2020-12-10 12:24:22',1,NULL,'CO7001-0017',1,NULL,NULL,NULL,'2017-02-16 00:05:26','2020-02-16 00:05:26',NULL,'2020-07-23',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,436.00000000,436.00000000,'','','',0,NULL,NULL,1,NULL,NULL,2,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,436.00000000,0.00000000,436.00000000,NULL,NULL,NULL),(62,'2021-04-15 10:22:31',19,NULL,'CO7001-0018',1,NULL,NULL,NULL,'2017-02-16 00:05:35','2020-02-16 00:05:35','2020-12-20 20:48:55','2021-02-23',12,NULL,12,12,1,3,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,410.00000000,410.00000000,'','','',0,NULL,NULL,2,NULL,NULL,1,NULL,1,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,410.00000000,0.00000000,410.00000000,NULL,NULL,NULL),(68,'2021-07-11 17:49:28',3,NULL,'CO7001-0019',1,NULL,NULL,NULL,'2017-02-16 00:05:35','2020-02-16 00:05:35',NULL,'2021-05-19',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,45.00000000,45.00000000,'','','',0,NULL,NULL,NULL,NULL,NULL,1,NULL,1,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,45.00000000,0.00000000,45.00000000,NULL,NULL,NULL),(72,'2020-12-10 12:24:22',6,NULL,'CO7001-0020',1,NULL,NULL,NULL,'2017-02-16 00:05:36','2020-02-16 00:05:36','2021-01-16 02:42:56','2020-11-13',12,NULL,12,12,1,3,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,610.00000000,610.00000000,'','','',1,NULL,NULL,NULL,NULL,NULL,2,NULL,1,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,610.00000000,0.00000000,610.00000000,NULL,NULL,NULL),(75,'2021-04-15 10:22:31',4,NULL,'CO7001-0021',1,NULL,NULL,NULL,'2017-02-16 00:05:37','2020-02-16 04:14:20',NULL,'2021-02-13',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,25.00000000,49.88000000,0.00000000,1200.00000000,1274.88000000,'','','',0,NULL,NULL,2,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,1200.00000000,25.00000000,1274.88000000,NULL,NULL,NULL),(78,'2020-12-10 12:24:22',12,NULL,'CO7001-0022',1,NULL,NULL,NULL,'2017-02-16 00:05:37','2020-02-16 00:05:37',NULL,'2020-10-03',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,928.00000000,928.00000000,'','','',0,NULL,NULL,2,NULL,NULL,2,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,928.00000000,0.00000000,928.00000000,NULL,NULL,NULL),(81,'2021-07-11 17:49:28',11,NULL,'CO7001-0023',1,NULL,NULL,NULL,'2017-02-16 00:05:38','2021-02-16 00:05:38',NULL,'2021-07-03',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,725.00000000,725.00000000,'','','',0,NULL,NULL,2,NULL,NULL,1,NULL,1,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,725.00000000,0.00000000,725.00000000,NULL,NULL,NULL),(83,'2021-04-15 10:22:31',26,NULL,'CO7001-0024',1,NULL,NULL,NULL,'2017-02-16 00:05:38','2020-02-16 00:05:38',NULL,'2021-04-03',12,NULL,12,NULL,1,-1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,105.00000000,105.00000000,'','','',0,NULL,NULL,1,NULL,NULL,1,NULL,1,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,105.00000000,0.00000000,105.00000000,NULL,NULL,NULL),(84,'2021-07-11 17:49:28',2,NULL,'CO7001-0025',1,NULL,NULL,NULL,'2017-02-16 00:05:38','2021-02-16 00:05:38',NULL,'2021-06-19',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,510.00000000,510.00000000,'','','',0,NULL,NULL,1,NULL,NULL,2,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,510.00000000,0.00000000,510.00000000,NULL,NULL,NULL),(85,'2021-04-15 10:22:31',1,NULL,'CO7001-0026',1,NULL,NULL,NULL,'2017-02-16 00:05:38','2020-02-16 00:05:38',NULL,'2021-01-03',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,47.00000000,47.00000000,'','','',0,NULL,NULL,1,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,47.00000000,0.00000000,47.00000000,NULL,NULL,NULL),(88,'2021-04-15 10:22:31',10,NULL,'CO7001-0027',1,NULL,NULL,NULL,'2017-02-16 00:05:38','2020-12-20 20:42:42',NULL,'2020-12-23',12,12,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,50.00000000,50.00000000,'This is a private note','This is a public note','',0,NULL,NULL,1,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,50.00000000,0.00000000,50.00000000,'commande/CO7001-0027/CO7001-0027.pdf',NULL,NULL),(90,'2021-04-15 10:22:31',19,NULL,'(PROV90)',1,NULL,NULL,NULL,'2017-02-16 04:46:31',NULL,NULL,'2021-02-16',12,NULL,NULL,NULL,NULL,0,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,440.00000000,440.00000000,'','','',0,NULL,NULL,3,3,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,440.00000000,0.00000000,440.00000000,NULL,NULL,NULL),(91,'2021-04-15 10:22:31',1,NULL,'(PROV91)',1,NULL,NULL,NULL,'2017-02-16 04:46:37',NULL,NULL,'2021-02-16',12,NULL,NULL,NULL,NULL,0,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,1000.00000000,1000.00000000,'','','',0,NULL,NULL,3,3,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,1000.00000000,0.00000000,1000.00000000,NULL,NULL,NULL),(92,'2021-04-15 10:22:31',3,NULL,'(PROV92)',1,NULL,NULL,NULL,'2017-02-16 04:47:25',NULL,NULL,'2021-02-16',12,NULL,NULL,NULL,NULL,0,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,1018.00000000,1018.00000000,'','','',0,NULL,NULL,3,3,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,1018.00000000,0.00000000,1018.00000000,NULL,NULL,NULL),(93,'2020-12-10 12:24:22',10,NULL,'(PROV93)',1,NULL,NULL,NULL,'2019-09-27 19:32:53',NULL,NULL,'2020-09-27',12,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,'','','einstein',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',1,'EUR',1.00000000,0.00000000,0.00000000,0.00000000,'commande/(PROV93)/(PROV93).pdf',NULL,NULL),(94,'2021-04-15 10:22:31',1,NULL,'(PROV94)',1,NULL,NULL,NULL,'2019-12-20 20:49:54',NULL,NULL,'2020-12-20',12,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0.00000000,0.00000000,0.00000000,1000.00000000,1000.00000000,'','','',0,NULL,NULL,3,3,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,1000.00000000,0.00000000,1000.00000000,NULL,NULL,NULL),(95,'2021-04-15 10:22:31',1,NULL,'(PROV95)',1,NULL,NULL,NULL,'2019-12-20 20:50:23',NULL,NULL,'2020-12-20',12,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0.00000000,0.00000000,0.00000000,1000.00000000,1000.00000000,'','','',0,NULL,NULL,3,3,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,1000.00000000,0.00000000,1000.00000000,NULL,NULL,NULL),(96,'2021-04-15 10:22:31',10,6,'(PROV96)',1,NULL,NULL,NULL,'2020-01-07 23:39:09',NULL,NULL,'2021-01-07',12,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0.00000000,0.00000000,0.00000000,10.00000000,10.00000000,'aaa','','',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,10.00000000,0.00000000,10.00000000,NULL,NULL,NULL),(97,'2021-04-15 10:22:31',10,6,'(PROV97)',1,NULL,NULL,NULL,'2020-01-07 23:43:06',NULL,NULL,'2021-01-07',12,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0.00000000,0.00000000,0.00000000,10.00000000,10.00000000,'aaa','','',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,10.00000000,0.00000000,10.00000000,NULL,NULL,NULL),(98,'2021-04-15 10:22:31',1,NULL,'(PROV98)',1,NULL,NULL,NULL,'2020-01-19 14:22:34',NULL,NULL,'2021-01-19',12,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0.00000000,0.45000000,0.45000000,3.00000000,3.90000000,'','','',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,3.00000000,0.00000000,3.90000000,NULL,NULL,NULL),(99,'2021-04-15 10:22:31',1,NULL,'(PROV99)',1,NULL,NULL,NULL,'2020-01-19 14:24:27',NULL,NULL,'2021-01-19',12,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0.24000000,0.00000000,0.00000000,4.00000000,4.24000000,'','','',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,4.00000000,0.24000000,4.24000000,NULL,NULL,NULL); +INSERT INTO `llx_commande` VALUES (1,'2022-02-07 13:37:54',1,NULL,'CO1107-0002',1,NULL,NULL,'','2013-07-20 15:23:12','2021-08-08 13:59:09',NULL,'2021-07-20',1,NULL,1,NULL,NULL,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,10.00000000,10.00000000,'','','einstein',0,NULL,NULL,1,1,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL),(2,'2022-02-07 13:37:54',1,NULL,'CO1107-0003',1,NULL,NULL,'','2013-07-20 23:20:12','2021-02-12 17:06:51',NULL,'2021-07-21',1,NULL,1,NULL,NULL,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,10.00000000,10.00000000,'','','einstein',0,NULL,NULL,0,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL),(3,'2022-02-07 13:37:54',1,NULL,'CO1107-0004',1,NULL,NULL,'','2013-07-20 23:22:53','2021-02-17 18:27:56',NULL,'2021-07-21',1,NULL,1,NULL,NULL,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,30.00000000,30.00000000,'','','einstein',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL),(5,'2022-02-07 13:37:54',1,NULL,'CO1108-0001',1,NULL,NULL,'','2013-08-08 03:04:11','2021-08-08 03:04:21',NULL,'2021-08-08',1,NULL,1,NULL,NULL,2,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,10.00000000,10.00000000,'','','einstein',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL),(6,'2021-04-15 10:22:31',19,NULL,'(PROV6)',1,NULL,NULL,'','2015-02-17 16:22:14',NULL,NULL,'2021-02-17',1,NULL,NULL,NULL,NULL,0,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,'','','einstein',0,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,'commande/(PROV6)/(PROV6).pdf',NULL,NULL),(17,'2021-07-11 17:49:28',4,NULL,'CO7001-0005',1,NULL,NULL,NULL,'2017-02-15 23:50:34','2020-02-15 23:50:34',NULL,'2021-05-13',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,509.00000000,509.00000000,'','','',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,509.00000000,0.00000000,509.00000000,NULL,NULL,NULL),(18,'2022-02-07 13:37:54',7,4,'CO7001-0006',1,NULL,NULL,NULL,'2017-02-15 23:51:23','2021-02-15 23:51:23',NULL,'2022-02-03',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,900.00000000,900.00000000,'','','',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,900.00000000,0.00000000,900.00000000,NULL,NULL,NULL),(20,'2021-04-15 10:22:31',4,NULL,'CO7001-0007',1,NULL,NULL,NULL,'2017-02-15 23:55:52','2020-02-15 23:55:52',NULL,'2021-04-03',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,330.00000000,330.00000000,'','','',0,NULL,NULL,2,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,330.00000000,0.00000000,330.00000000,NULL,NULL,NULL),(29,'2021-04-15 10:22:31',4,NULL,'CO7001-0008',1,NULL,NULL,NULL,'2017-02-16 00:03:44','2021-02-16 00:03:44',NULL,'2021-02-12',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,457.00000000,457.00000000,'','','',0,NULL,NULL,1,NULL,NULL,2,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,457.00000000,0.00000000,457.00000000,NULL,NULL,NULL),(34,'2022-02-07 13:37:54',11,NULL,'CO7001-0009',1,NULL,NULL,NULL,'2017-02-16 00:05:01','2021-02-16 00:05:01',NULL,'2022-01-03',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,124.00000000,124.00000000,'','','',0,NULL,NULL,2,NULL,NULL,2,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,124.00000000,0.00000000,124.00000000,NULL,NULL,NULL),(38,'2022-02-07 13:37:54',3,NULL,'CO7001-0010',1,NULL,NULL,NULL,'2017-02-16 00:05:01','2021-02-16 00:05:01',NULL,'2022-02-03',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,200.00000000,200.00000000,'','','',0,NULL,NULL,1,NULL,NULL,2,NULL,1,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,200.00000000,0.00000000,200.00000000,NULL,NULL,NULL),(40,'2022-02-07 13:37:54',11,NULL,'CO7001-0011',1,NULL,NULL,NULL,'2017-02-16 00:05:10','2021-02-16 00:05:11',NULL,'2022-01-23',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,1210.00000000,1210.00000000,'','','',0,NULL,NULL,1,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,1210.00000000,0.00000000,1210.00000000,NULL,NULL,NULL),(43,'2021-04-15 10:22:31',10,NULL,'CO7001-0012',1,NULL,NULL,NULL,'2017-02-16 00:05:11','2021-02-16 00:05:11',NULL,'2021-02-13',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,478.00000000,478.00000000,'','','',0,NULL,NULL,2,NULL,NULL,2,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,478.00000000,0.00000000,478.00000000,NULL,NULL,NULL),(47,'2022-02-07 13:37:54',1,NULL,'CO7001-0013',1,NULL,NULL,NULL,'2017-02-16 00:05:11','2021-02-16 00:05:11',NULL,'2021-11-13',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,55.00000000,55.00000000,'','','',0,NULL,NULL,2,NULL,NULL,1,NULL,1,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,55.00000000,0.00000000,55.00000000,NULL,NULL,NULL),(48,'2022-02-07 13:37:54',4,NULL,'CO7001-0014',1,NULL,NULL,NULL,'2017-02-16 00:05:11','2021-02-16 00:05:11',NULL,'2021-07-30',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,540.00000000,540.00000000,'','','',0,NULL,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,540.00000000,0.00000000,540.00000000,NULL,NULL,NULL),(50,'2022-02-07 13:37:54',1,NULL,'CO7001-0015',1,NULL,NULL,NULL,'2017-02-16 00:05:26','2022-02-16 00:05:26',NULL,'2021-12-12',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,118.00000000,118.00000000,'','','',0,NULL,NULL,1,NULL,NULL,1,NULL,1,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,118.00000000,0.00000000,118.00000000,NULL,NULL,NULL),(54,'2021-07-11 17:49:28',12,NULL,'CO7001-0016',1,NULL,NULL,NULL,'2017-02-16 00:05:26','2020-02-16 00:05:26','2020-02-16 03:05:56','2021-06-03',12,NULL,12,12,1,3,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,220.00000000,220.00000000,'','','',1,NULL,NULL,NULL,NULL,NULL,1,NULL,1,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,220.00000000,0.00000000,220.00000000,NULL,NULL,NULL),(58,'2022-02-07 13:37:54',1,NULL,'CO7001-0017',1,NULL,NULL,NULL,'2017-02-16 00:05:26','2021-02-16 00:05:26',NULL,'2021-07-23',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,436.00000000,436.00000000,'','','',0,NULL,NULL,1,NULL,NULL,2,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,436.00000000,0.00000000,436.00000000,NULL,NULL,NULL),(62,'2021-04-15 10:22:31',19,NULL,'CO7001-0018',1,NULL,NULL,NULL,'2017-02-16 00:05:35','2020-02-16 00:05:35','2020-12-20 20:48:55','2021-02-23',12,NULL,12,12,1,3,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,410.00000000,410.00000000,'','','',0,NULL,NULL,2,NULL,NULL,1,NULL,1,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,410.00000000,0.00000000,410.00000000,NULL,NULL,NULL),(68,'2021-07-11 17:49:28',3,NULL,'CO7001-0019',1,NULL,NULL,NULL,'2017-02-16 00:05:35','2020-02-16 00:05:35',NULL,'2021-05-19',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,45.00000000,45.00000000,'','','',0,NULL,NULL,NULL,NULL,NULL,1,NULL,1,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,45.00000000,0.00000000,45.00000000,NULL,NULL,NULL),(72,'2022-02-07 13:37:54',6,NULL,'CO7001-0020',1,NULL,NULL,NULL,'2017-02-16 00:05:36','2021-02-16 00:05:36','2022-01-16 02:42:56','2021-11-13',12,NULL,12,12,1,3,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,610.00000000,610.00000000,'','','',1,NULL,NULL,NULL,NULL,NULL,2,NULL,1,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,610.00000000,0.00000000,610.00000000,NULL,NULL,NULL),(75,'2021-04-15 10:22:31',4,NULL,'CO7001-0021',1,NULL,NULL,NULL,'2017-02-16 00:05:37','2020-02-16 04:14:20',NULL,'2021-02-13',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,25.00000000,49.88000000,0.00000000,1200.00000000,1274.88000000,'','','',0,NULL,NULL,2,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,1200.00000000,25.00000000,1274.88000000,NULL,NULL,NULL),(78,'2022-02-07 13:37:54',12,NULL,'CO7001-0022',1,NULL,NULL,NULL,'2017-02-16 00:05:37','2021-02-16 00:05:37',NULL,'2021-10-03',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,928.00000000,928.00000000,'','','',0,NULL,NULL,2,NULL,NULL,2,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,928.00000000,0.00000000,928.00000000,NULL,NULL,NULL),(81,'2021-07-11 17:49:28',11,NULL,'CO7001-0023',1,NULL,NULL,NULL,'2017-02-16 00:05:38','2021-02-16 00:05:38',NULL,'2021-07-03',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,725.00000000,725.00000000,'','','',0,NULL,NULL,2,NULL,NULL,1,NULL,1,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,725.00000000,0.00000000,725.00000000,NULL,NULL,NULL),(83,'2021-04-15 10:22:31',26,NULL,'CO7001-0024',1,NULL,NULL,NULL,'2017-02-16 00:05:38','2020-02-16 00:05:38',NULL,'2021-04-03',12,NULL,12,NULL,1,-1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,105.00000000,105.00000000,'','','',0,NULL,NULL,1,NULL,NULL,1,NULL,1,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,105.00000000,0.00000000,105.00000000,NULL,NULL,NULL),(84,'2021-07-11 17:49:28',2,NULL,'CO7001-0025',1,NULL,NULL,NULL,'2017-02-16 00:05:38','2021-02-16 00:05:38',NULL,'2021-06-19',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,510.00000000,510.00000000,'','','',0,NULL,NULL,1,NULL,NULL,2,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,510.00000000,0.00000000,510.00000000,NULL,NULL,NULL),(85,'2022-02-07 13:37:54',1,NULL,'CO7001-0026',1,NULL,NULL,NULL,'2017-02-16 00:05:38','2021-02-16 00:05:38',NULL,'2022-01-03',12,NULL,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,47.00000000,47.00000000,'','','',0,NULL,NULL,1,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,47.00000000,0.00000000,47.00000000,NULL,NULL,NULL),(88,'2022-02-07 13:37:54',10,NULL,'CO7001-0027',1,NULL,NULL,NULL,'2017-02-16 00:05:38','2021-12-20 20:42:42',NULL,'2021-12-23',12,12,12,NULL,1,1,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,50.00000000,50.00000000,'This is a private note','This is a public note','',0,NULL,NULL,1,NULL,NULL,1,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,50.00000000,0.00000000,50.00000000,'commande/CO7001-0027/CO7001-0027.pdf',NULL,NULL),(90,'2021-04-15 10:22:31',19,NULL,'(PROV90)',1,NULL,NULL,NULL,'2017-02-16 04:46:31',NULL,NULL,'2021-02-16',12,NULL,NULL,NULL,NULL,0,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,440.00000000,440.00000000,'','','',0,NULL,NULL,3,3,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,440.00000000,0.00000000,440.00000000,NULL,NULL,NULL),(91,'2021-04-15 10:22:31',1,NULL,'(PROV91)',1,NULL,NULL,NULL,'2017-02-16 04:46:37',NULL,NULL,'2021-02-16',12,NULL,NULL,NULL,NULL,0,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,1000.00000000,1000.00000000,'','','',0,NULL,NULL,3,3,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,1000.00000000,0.00000000,1000.00000000,NULL,NULL,NULL),(92,'2021-04-15 10:22:31',3,NULL,'(PROV92)',1,NULL,NULL,NULL,'2017-02-16 04:47:25',NULL,NULL,'2021-02-16',12,NULL,NULL,NULL,NULL,0,0.00000000,0,NULL,0,0.00000000,0.00000000,0.00000000,1018.00000000,1018.00000000,'','','',0,NULL,NULL,3,3,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,1018.00000000,0.00000000,1018.00000000,NULL,NULL,NULL),(93,'2022-02-07 13:37:54',10,NULL,'(PROV93)',1,NULL,NULL,NULL,'2019-09-27 19:32:53',NULL,NULL,'2021-09-27',12,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,'','','einstein',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',1,'EUR',1.00000000,0.00000000,0.00000000,0.00000000,'commande/(PROV93)/(PROV93).pdf',NULL,NULL),(94,'2022-02-07 13:37:54',1,NULL,'(PROV94)',1,NULL,NULL,NULL,'2019-12-20 20:49:54',NULL,NULL,'2021-12-20',12,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0.00000000,0.00000000,0.00000000,1000.00000000,1000.00000000,'','','',0,NULL,NULL,3,3,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,1000.00000000,0.00000000,1000.00000000,NULL,NULL,NULL),(95,'2022-02-07 13:37:54',1,NULL,'(PROV95)',1,NULL,NULL,NULL,'2019-12-20 20:50:23',NULL,NULL,'2021-12-20',12,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0.00000000,0.00000000,0.00000000,1000.00000000,1000.00000000,'','','',0,NULL,NULL,3,3,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,1000.00000000,0.00000000,1000.00000000,NULL,NULL,NULL),(96,'2022-02-07 13:37:54',10,6,'(PROV96)',1,NULL,NULL,NULL,'2020-01-07 23:39:09',NULL,NULL,'2022-01-07',12,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0.00000000,0.00000000,0.00000000,10.00000000,10.00000000,'aaa','','',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,10.00000000,0.00000000,10.00000000,NULL,NULL,NULL),(97,'2022-02-07 13:37:54',10,6,'(PROV97)',1,NULL,NULL,NULL,'2020-01-07 23:43:06',NULL,NULL,'2022-01-07',12,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0.00000000,0.00000000,0.00000000,10.00000000,10.00000000,'aaa','','',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,10.00000000,0.00000000,10.00000000,NULL,NULL,NULL),(98,'2022-02-07 13:37:54',1,NULL,'(PROV98)',1,NULL,NULL,NULL,'2020-01-19 14:22:34',NULL,NULL,'2022-01-19',12,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0.00000000,0.45000000,0.45000000,3.00000000,3.90000000,'','','',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,3.00000000,0.00000000,3.90000000,NULL,NULL,NULL),(99,'2022-02-07 13:37:54',1,NULL,'(PROV99)',1,NULL,NULL,NULL,'2020-01-19 14:24:27',NULL,NULL,'2022-01-19',12,NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,0.24000000,0.00000000,0.00000000,4.00000000,4.24000000,'','','',0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,'',0,'EUR',1.00000000,4.00000000,0.24000000,4.24000000,NULL,NULL,NULL); /*!40000 ALTER TABLE `llx_commande` ENABLE KEYS */; UNLOCK TABLES; @@ -4285,7 +4334,7 @@ CREATE TABLE `llx_commande_fournisseur` ( `fk_incoterms` int(11) DEFAULT NULL, `location_incoterms` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_tx` double(24,8) DEFAULT 1.00000000, `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000, `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000, @@ -4305,7 +4354,7 @@ CREATE TABLE `llx_commande_fournisseur` ( LOCK TABLES `llx_commande_fournisseur` WRITE; /*!40000 ALTER TABLE `llx_commande_fournisseur` DISABLE KEYS */; -INSERT INTO `llx_commande_fournisseur` VALUES (1,'2021-04-15 10:22:31',13,'CF1007-0001',1,NULL,NULL,NULL,'2020-07-11 17:13:40','2021-02-01 18:51:42','2021-02-01 18:52:04',NULL,'2021-02-01',1,NULL,12,12,NULL,0,5,0,0.00000000,0,0,39.20000000,0.00000000,0.00000000,200.00000000,239.20000000,NULL,NULL,'muscadet',2,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL),(2,'2021-07-11 17:49:28',1,'CF1007-0002',1,NULL,NULL,NULL,'2021-07-11 18:46:28','2021-07-11 18:47:33',NULL,NULL,'2021-07-11',1,NULL,1,NULL,NULL,0,4,0,0.00000000,0,0,0.00000000,0.00000000,0.00000000,200.00000000,200.00000000,NULL,NULL,'muscadet',4,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL),(3,'2020-01-20 11:22:53',17,'(PROV3)',1,NULL,NULL,NULL,'2013-08-04 23:00:52',NULL,NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,0,0,0,0.00000000,0,0,0.00000000,0.00000000,0.00000000,1079.17000000,1079.17000000,NULL,NULL,'muscadet',0,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'USD',1.20000000,1295.00000000,0.00000000,1295.00000000,NULL),(4,'2020-01-20 11:19:49',17,'(PROV4)',1,NULL,NULL,NULL,'2013-08-04 23:19:32',NULL,NULL,NULL,NULL,1,12,NULL,NULL,NULL,0,0,0,0.00000000,0,0,11.88000000,0.00000000,0.00000000,174.17000000,186.05000000,'Private note','Public note','muscadet',0,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'EUR',1.00000000,174.17000000,11.88000000,186.05000000,NULL),(13,'2021-04-15 10:22:31',1,'CF1303-0004',1,NULL,NULL,NULL,'2021-03-09 19:39:18','2021-03-09 19:39:27','2021-03-09 19:39:32',NULL,'2021-03-09',1,NULL,1,1,NULL,0,2,0,0.00000000,0,0,0.00000000,0.00000000,0.00000000,10.00000000,10.00000000,NULL,NULL,'muscadet',1,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL),(14,'2020-01-20 11:20:11',1,'(PROV14)',1,NULL,'',NULL,'2020-01-20 12:20:11',NULL,NULL,NULL,NULL,12,NULL,NULL,NULL,NULL,0,0,0,NULL,0,0,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,'','','muscadet',0,1,NULL,NULL,NULL,NULL,NULL,0,'',1,'EUR',1.00000000,0.00000000,0.00000000,0.00000000,NULL); +INSERT INTO `llx_commande_fournisseur` VALUES (1,'2022-02-07 13:37:54',13,'CF1007-0001',1,NULL,NULL,NULL,'2021-07-11 17:13:40','2022-02-01 18:51:42','2022-02-01 18:52:04',NULL,'2022-02-01',1,NULL,12,12,NULL,0,5,0,0.00000000,0,0,39.20000000,0.00000000,0.00000000,200.00000000,239.20000000,NULL,NULL,'muscadet',2,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL),(2,'2021-07-11 17:49:28',1,'CF1007-0002',1,NULL,NULL,NULL,'2021-07-11 18:46:28','2021-07-11 18:47:33',NULL,NULL,'2021-07-11',1,NULL,1,NULL,NULL,0,4,0,0.00000000,0,0,0.00000000,0.00000000,0.00000000,200.00000000,200.00000000,NULL,NULL,'muscadet',4,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL),(3,'2020-01-20 11:22:53',17,'(PROV3)',1,NULL,NULL,NULL,'2013-08-04 23:00:52',NULL,NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,0,0,0,0.00000000,0,0,0.00000000,0.00000000,0.00000000,1079.17000000,1079.17000000,NULL,NULL,'muscadet',0,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'USD',1.20000000,1295.00000000,0.00000000,1295.00000000,NULL),(4,'2020-01-20 11:19:49',17,'(PROV4)',1,NULL,NULL,NULL,'2013-08-04 23:19:32',NULL,NULL,NULL,NULL,1,12,NULL,NULL,NULL,0,0,0,0.00000000,0,0,11.88000000,0.00000000,0.00000000,174.17000000,186.05000000,'Private note','Public note','muscadet',0,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'EUR',1.00000000,174.17000000,11.88000000,186.05000000,NULL),(13,'2021-04-15 10:22:31',1,'CF1303-0004',1,NULL,NULL,NULL,'2021-03-09 19:39:18','2021-03-09 19:39:27','2021-03-09 19:39:32',NULL,'2021-03-09',1,NULL,1,1,NULL,0,2,0,0.00000000,0,0,0.00000000,0.00000000,0.00000000,10.00000000,10.00000000,NULL,NULL,'muscadet',1,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL),(14,'2020-01-20 11:20:11',1,'(PROV14)',1,NULL,'',NULL,'2020-01-20 12:20:11',NULL,NULL,NULL,NULL,12,NULL,NULL,NULL,NULL,0,0,0,NULL,0,0,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,'','','muscadet',0,1,NULL,NULL,NULL,NULL,NULL,0,'',1,'EUR',1.00000000,0.00000000,0.00000000,0.00000000,NULL); /*!40000 ALTER TABLE `llx_commande_fournisseur` ENABLE KEYS */; UNLOCK TABLES; @@ -4333,6 +4382,7 @@ CREATE TABLE `llx_commande_fournisseur_dispatch` ( `sellby` date DEFAULT NULL, `fk_projet` int(11) DEFAULT NULL, `fk_reception` int(11) DEFAULT NULL, + `cost_price` double(24,8) DEFAULT 0.00000000, PRIMARY KEY (`rowid`), KEY `idx_commande_fournisseur_dispatch_fk_commande` (`fk_commande`) ) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; @@ -4344,7 +4394,7 @@ CREATE TABLE `llx_commande_fournisseur_dispatch` ( LOCK TABLES `llx_commande_fournisseur_dispatch` WRITE; /*!40000 ALTER TABLE `llx_commande_fournisseur_dispatch` DISABLE KEYS */; -INSERT INTO `llx_commande_fournisseur_dispatch` VALUES (1,2,4,2,1,20,12,'2021-04-15 08:40:04','',1,'2021-04-15 11:40:04','Lot 2021-02',NULL,NULL,NULL,1); +INSERT INTO `llx_commande_fournisseur_dispatch` VALUES (1,2,4,2,1,20,12,'2021-04-15 08:40:04','',1,'2021-04-15 11:40:04','Lot 2021-02',NULL,NULL,NULL,1,0.00000000); /*!40000 ALTER TABLE `llx_commande_fournisseur_dispatch` ENABLE KEYS */; UNLOCK TABLES; @@ -4468,7 +4518,7 @@ CREATE TABLE `llx_commande_fournisseurdet` ( `rang` int(11) DEFAULT 0, `fk_unit` int(11) DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_subprice` double(24,8) DEFAULT 0.00000000, `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000, `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000, @@ -4561,7 +4611,7 @@ CREATE TABLE `llx_commandedet` ( `fk_commandefourndet` int(11) DEFAULT NULL, `fk_unit` int(11) DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_subprice` double(24,8) DEFAULT 0.00000000, `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000, `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000, @@ -4662,7 +4712,7 @@ CREATE TABLE `llx_const` ( `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(), PRIMARY KEY (`rowid`), UNIQUE KEY `uk_const` (`name`,`entity`) -) ENGINE=InnoDB AUTO_INCREMENT=8943 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=9255 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -4671,7 +4721,7 @@ CREATE TABLE `llx_const` ( LOCK TABLES `llx_const` WRITE; /*!40000 ALTER TABLE `llx_const` DISABLE KEYS */; -INSERT INTO `llx_const` VALUES (8,'MAIN_UPLOAD_DOC',0,'2048','chaine',0,'Max size for file upload (0 means no upload allowed)','2012-07-08 11:17:57'),(9,'MAIN_SEARCHFORM_SOCIETE',0,'1','yesno',0,'Show form for quick company search','2012-07-08 11:17:57'),(10,'MAIN_SEARCHFORM_CONTACT',0,'1','yesno',0,'Show form for quick contact search','2012-07-08 11:17:57'),(11,'MAIN_SEARCHFORM_PRODUITSERVICE',0,'1','yesno',0,'Show form for quick product search','2012-07-08 11:17:58'),(12,'MAIN_SEARCHFORM_ADHERENT',0,'1','yesno',0,'Show form for quick member search','2012-07-08 11:17:58'),(16,'MAIN_SIZE_LISTE_LIMIT',0,'25','chaine',0,'Longueur maximum des listes','2012-07-08 11:17:58'),(29,'MAIN_DELAY_NOT_ACTIVATED_SERVICES',1,'0','chaine',0,'Tolérance de retard avant alerte (en jours) sur services à activer','2012-07-08 11:17:58'),(33,'SOCIETE_NOLIST_COURRIER',0,'1','yesno',0,'Liste les fichiers du repertoire courrier','2012-07-08 11:17:58'),(36,'ADHERENT_MAIL_REQUIRED',1,'1','yesno',0,'EMail required to create a new member','2012-07-08 11:17:58'),(37,'ADHERENT_MAIL_FROM',1,'adherents@domain.com','chaine',0,'Sender EMail for automatic emails','2012-07-08 11:17:58'),(38,'ADHERENT_MAIL_RESIL',1,'Your subscription has been resiliated.\r\nWe hope to see you soon again','html',0,'Mail resiliation','2018-11-23 11:56:07'),(39,'ADHERENT_MAIL_VALID',1,'Your subscription has been validated.\r\nThis is a remind of your personal information :\r\n\r\n%INFOS%\r\n\r\n','html',0,'Mail de validation','2018-11-23 11:56:07'),(40,'ADHERENT_MAIL_COTIS',1,'Hello %PRENOM%,\r\nThanks for your subscription.\r\nThis email confirms that your subscription has been received and processed.\r\n\r\n','html',0,'Mail de validation de cotisation','2018-11-23 11:56:07'),(41,'ADHERENT_MAIL_VALID_SUBJECT',1,'Your subscription has been validated','chaine',0,'Sujet du mail de validation','2012-07-08 11:17:59'),(42,'ADHERENT_MAIL_RESIL_SUBJECT',1,'Resiliating your subscription','chaine',0,'Sujet du mail de resiliation','2012-07-08 11:17:59'),(43,'ADHERENT_MAIL_COTIS_SUBJECT',1,'Receipt of your subscription','chaine',0,'Sujet du mail de validation de cotisation','2012-07-08 11:17:59'),(44,'MAILING_EMAIL_FROM',1,'dolibarr@domain.com','chaine',0,'EMail emmetteur pour les envois d emailings','2012-07-08 11:17:59'),(45,'ADHERENT_USE_MAILMAN',1,'0','yesno',0,'Utilisation de Mailman','2012-07-08 11:17:59'),(46,'ADHERENT_MAILMAN_UNSUB_URL',1,'http://lists.domain.com/cgi-bin/mailman/admin/%LISTE%/members?adminpw=%MAILMAN_ADMINPW%&user=%EMAIL%','chaine',0,'Url de desinscription aux listes mailman','2012-07-08 11:17:59'),(47,'ADHERENT_MAILMAN_URL',1,'http://lists.domain.com/cgi-bin/mailman/admin/%LISTE%/members?adminpw=%MAILMAN_ADMINPW%&send_welcome_msg_to_this_batch=1&subscribees=%EMAIL%','chaine',0,'Url pour les inscriptions mailman','2012-07-08 11:17:59'),(48,'ADHERENT_MAILMAN_LISTS',1,'test-test,test-test2','chaine',0,'Listes auxquelles inscrire les nouveaux adherents','2012-07-08 11:17:59'),(49,'ADHERENT_MAILMAN_ADMINPW',1,'','chaine',0,'Mot de passe Admin des liste mailman','2012-07-08 11:17:59'),(50,'ADHERENT_MAILMAN_SERVER',1,'lists.domain.com','chaine',0,'Serveur hebergeant les interfaces d Admin des listes mailman','2012-07-08 11:17:59'),(51,'ADHERENT_MAILMAN_LISTS_COTISANT',1,'','chaine',0,'Liste(s) auxquelles les nouveaux cotisants sont inscris automatiquement','2012-07-08 11:17:59'),(52,'ADHERENT_USE_SPIP',1,'0','yesno',0,'Utilisation de SPIP ?','2012-07-08 11:17:59'),(53,'ADHERENT_USE_SPIP_AUTO',1,'0','yesno',0,'Utilisation de SPIP automatiquement','2012-07-08 11:17:59'),(54,'ADHERENT_SPIP_USER',1,'user','chaine',0,'user spip','2012-07-08 11:17:59'),(55,'ADHERENT_SPIP_PASS',1,'pass','chaine',0,'Pass de connection','2012-07-08 11:17:59'),(56,'ADHERENT_SPIP_SERVEUR',1,'localhost','chaine',0,'serveur spip','2012-07-08 11:17:59'),(57,'ADHERENT_SPIP_DB',1,'spip','chaine',0,'db spip','2012-07-08 11:17:59'),(58,'ADHERENT_CARD_HEADER_TEXT',1,'%ANNEE%','chaine',0,'Texte imprime sur le haut de la carte adherent','2012-07-08 11:17:59'),(59,'ADHERENT_CARD_FOOTER_TEXT',1,'Association AZERTY','chaine',0,'Texte imprime sur le bas de la carte adherent','2012-07-08 11:17:59'),(61,'FCKEDITOR_ENABLE_USER',1,'1','yesno',0,'Activation fckeditor sur notes utilisateurs','2012-07-08 11:17:59'),(62,'FCKEDITOR_ENABLE_SOCIETE',1,'1','yesno',0,'Activation fckeditor sur notes societe','2012-07-08 11:17:59'),(63,'FCKEDITOR_ENABLE_PRODUCTDESC',1,'1','yesno',0,'Activation fckeditor sur notes produits','2012-07-08 11:17:59'),(64,'FCKEDITOR_ENABLE_MEMBER',1,'1','yesno',0,'Activation fckeditor sur notes adherent','2012-07-08 11:17:59'),(65,'FCKEDITOR_ENABLE_MAILING',1,'1','yesno',0,'Activation fckeditor sur emailing','2012-07-08 11:17:59'),(67,'DON_ADDON_MODEL',1,'html_cerfafr','chaine',0,'','2012-07-08 11:18:00'),(68,'PROPALE_ADDON',1,'mod_propale_marbre','chaine',0,'','2012-07-08 11:18:00'),(69,'PROPALE_ADDON_PDF',1,'azur','chaine',0,'','2012-07-08 11:18:00'),(70,'COMMANDE_ADDON',1,'mod_commande_marbre','chaine',0,'','2012-07-08 11:18:00'),(71,'COMMANDE_ADDON_PDF',1,'einstein','chaine',0,'','2012-07-08 11:18:00'),(72,'COMMANDE_SUPPLIER_ADDON',1,'mod_commande_fournisseur_muguet','chaine',0,'','2012-07-08 11:18:00'),(73,'COMMANDE_SUPPLIER_ADDON_PDF',1,'muscadet','chaine',0,'','2012-07-08 11:18:00'),(74,'EXPEDITION_ADDON',1,'enlevement','chaine',0,'','2012-07-08 11:18:00'),(76,'FICHEINTER_ADDON',1,'pacific','chaine',0,'','2012-07-08 11:18:00'),(77,'FICHEINTER_ADDON_PDF',1,'soleil','chaine',0,'','2012-07-08 11:18:00'),(79,'FACTURE_ADDON_PDF',1,'crabe','chaine',0,'','2012-07-08 11:18:00'),(80,'PROPALE_VALIDITY_DURATION',1,'15','chaine',0,'Durée de validitée des propales','2012-07-08 11:18:00'),(230,'COMPANY_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/thirdparties','chaine',0,NULL,'2012-07-08 11:26:20'),(238,'LIVRAISON_ADDON_PDF',1,'typhon','chaine',0,'Nom du gestionnaire de generation des commandes en PDF','2012-07-08 11:26:27'),(239,'DELIVERY_ADDON_NUMBER',1,'mod_delivery_jade','chaine',0,'Nom du gestionnaire de numerotation des bons de livraison','2020-12-10 12:24:40'),(245,'FACTURE_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/invoices','chaine',0,NULL,'2012-07-08 11:28:53'),(249,'DON_FORM',1,'html_cerfafr','chaine',0,'Nom du gestionnaire de formulaire de dons','2017-09-06 16:12:22'),(254,'ADHERENT_BANK_ACCOUNT',1,'','chaine',0,'ID du Compte banquaire utilise','2012-07-08 11:29:05'),(255,'ADHERENT_BANK_CATEGORIE',1,'','chaine',0,'ID de la categorie banquaire des cotisations','2012-07-08 11:29:05'),(256,'ADHERENT_ETIQUETTE_TYPE',1,'L7163','chaine',0,'Type d etiquette (pour impression de planche d etiquette)','2012-07-08 11:29:05'),(269,'PROJECT_ADDON_PDF',1,'baleine','chaine',0,'Nom du gestionnaire de generation des projets en PDF','2012-07-08 11:29:33'),(270,'PROJECT_ADDON',1,'mod_project_simple','chaine',0,'Nom du gestionnaire de numerotation des projets','2012-07-08 11:29:33'),(369,'EXPEDITION_ADDON_PDF',1,'merou','chaine',0,'','2012-07-08 22:58:07'),(377,'FACTURE_ADDON',1,'mod_facture_terre','chaine',0,'','2012-07-08 23:08:12'),(380,'ADHERENT_CARD_TEXT',1,'%TYPE% n° %ID%\r\n%PRENOM% %NOM%\r\n<%EMAIL%>\r\n%ADRESSE%\r\n%CP% %VILLE%\r\n%PAYS%','',0,'Texte imprime sur la carte adherent','2012-07-08 23:14:46'),(381,'ADHERENT_CARD_TEXT_RIGHT',1,'aaa','',0,'','2012-07-08 23:14:55'),(386,'STOCK_CALCULATE_ON_SHIPMENT',1,'1','chaine',0,'','2012-07-08 23:23:21'),(387,'STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER',1,'1','chaine',0,'','2012-07-08 23:23:26'),(392,'MAIN_AGENDA_XCAL_EXPORTKEY',1,'dolibarr','chaine',0,'','2012-07-08 23:27:50'),(393,'MAIN_AGENDA_EXPORT_PAST_DELAY',1,'100','chaine',0,'','2012-07-08 23:27:50'),(610,'CASHDESK_ID_THIRDPARTY',1,'7','chaine',0,'','2012-07-11 17:08:18'),(611,'CASHDESK_ID_BANKACCOUNT_CASH',1,'3','chaine',0,'','2012-07-11 17:08:18'),(612,'CASHDESK_ID_BANKACCOUNT_CHEQUE',1,'1','chaine',0,'','2012-07-11 17:08:18'),(613,'CASHDESK_ID_BANKACCOUNT_CB',1,'1','chaine',0,'','2012-07-11 17:08:18'),(614,'CASHDESK_ID_WAREHOUSE',1,'2','chaine',0,'','2012-07-11 17:08:18'),(660,'LDAP_USER_DN',1,'ou=users,dc=my-domain,dc=com','chaine',0,NULL,'2012-07-18 10:25:27'),(661,'LDAP_GROUP_DN',1,'ou=groups,dc=my-domain,dc=com','chaine',0,NULL,'2012-07-18 10:25:27'),(662,'LDAP_FILTER_CONNECTION',1,'&(objectClass=user)(objectCategory=person)','chaine',0,NULL,'2012-07-18 10:25:27'),(663,'LDAP_FIELD_LOGIN',1,'uid','chaine',0,NULL,'2012-07-18 10:25:27'),(664,'LDAP_FIELD_FULLNAME',1,'cn','chaine',0,NULL,'2012-07-18 10:25:27'),(665,'LDAP_FIELD_NAME',1,'sn','chaine',0,NULL,'2012-07-18 10:25:27'),(666,'LDAP_FIELD_FIRSTNAME',1,'givenname','chaine',0,NULL,'2012-07-18 10:25:27'),(667,'LDAP_FIELD_MAIL',1,'mail','chaine',0,NULL,'2012-07-18 10:25:27'),(668,'LDAP_FIELD_PHONE',1,'telephonenumber','chaine',0,NULL,'2012-07-18 10:25:27'),(669,'LDAP_FIELD_FAX',1,'facsimiletelephonenumber','chaine',0,NULL,'2012-07-18 10:25:27'),(670,'LDAP_FIELD_MOBILE',1,'mobile','chaine',0,NULL,'2012-07-18 10:25:27'),(671,'LDAP_SERVER_TYPE',1,'openldap','chaine',0,'','2012-07-18 10:25:46'),(672,'LDAP_SERVER_PROTOCOLVERSION',1,'3','chaine',0,'','2012-07-18 10:25:47'),(673,'LDAP_SERVER_HOST',1,'localhost','chaine',0,'','2012-07-18 10:25:47'),(674,'LDAP_SERVER_PORT',1,'389','chaine',0,'','2012-07-18 10:25:47'),(675,'LDAP_SERVER_USE_TLS',1,'0','chaine',0,'','2012-07-18 10:25:47'),(676,'LDAP_SYNCHRO_ACTIVE',1,'dolibarr2ldap','chaine',0,'','2012-07-18 10:25:47'),(677,'LDAP_CONTACT_ACTIVE',1,'1','chaine',0,'','2012-07-18 10:25:47'),(678,'LDAP_MEMBER_ACTIVE',1,'1','chaine',0,'','2012-07-18 10:25:47'),(974,'MAIN_MODULE_WORKFLOW_TRIGGERS',1,'1','chaine',0,NULL,'2013-07-18 18:02:20'),(975,'WORKFLOW_PROPAL_AUTOCREATE_ORDER',1,'1','chaine',0,'','2013-07-18 18:02:24'),(980,'PRELEVEMENT_NUMERO_NATIONAL_EMETTEUR',1,'1234567','chaine',0,'','2013-07-18 18:05:50'),(983,'FACTURE_RIB_NUMBER',1,'1','chaine',0,'','2013-07-18 18:35:14'),(984,'FACTURE_CHQ_NUMBER',1,'1','chaine',0,'','2013-07-18 18:35:14'),(1016,'GOOGLE_DUPLICATE_INTO_GCAL',1,'1','chaine',0,'','2013-07-18 21:40:20'),(1152,'SOCIETE_CODECLIENT_ADDON',1,'mod_codeclient_monkey','chaine',0,'','2013-07-29 20:50:02'),(1240,'MAIN_LOGEVENTS_USER_LOGIN',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1241,'MAIN_LOGEVENTS_USER_LOGIN_FAILED',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1242,'MAIN_LOGEVENTS_USER_LOGOUT',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1243,'MAIN_LOGEVENTS_USER_CREATE',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1244,'MAIN_LOGEVENTS_USER_MODIFY',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1245,'MAIN_LOGEVENTS_USER_NEW_PASSWORD',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1246,'MAIN_LOGEVENTS_USER_ENABLEDISABLE',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1247,'MAIN_LOGEVENTS_USER_DELETE',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1248,'MAIN_LOGEVENTS_GROUP_CREATE',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1249,'MAIN_LOGEVENTS_GROUP_MODIFY',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1250,'MAIN_LOGEVENTS_GROUP_DELETE',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1251,'MAIN_BOXES_MAXLINES',1,'5','',0,'','2013-07-29 21:05:42'),(1482,'EXPEDITION_ADDON_NUMBER',1,'mod_expedition_safor','chaine',0,'Nom du gestionnaire de numerotation des expeditions','2013-08-05 17:53:11'),(1490,'CONTRACT_ADDON',1,'mod_contract_serpis','chaine',0,'Nom du gestionnaire de numerotation des contrats','2013-08-05 18:11:58'),(1677,'COMMANDE_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/orders','chaine',0,NULL,'2014-12-08 13:11:02'),(1724,'PROPALE_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/proposals','chaine',0,NULL,'2014-12-08 13:17:14'),(1730,'OPENSTREETMAP_ENABLE_MAPS',1,'1','chaine',0,'','2014-12-08 13:22:47'),(1731,'OPENSTREETMAP_ENABLE_MAPS_CONTACTS',1,'1','chaine',0,'','2014-12-08 13:22:47'),(1732,'OPENSTREETMAP_ENABLE_MAPS_MEMBERS',1,'1','chaine',0,'','2014-12-08 13:22:47'),(1733,'OPENSTREETMAP_MAPS_ZOOM_LEVEL',1,'15','chaine',0,'','2014-12-08 13:22:47'),(1742,'MAIN_MAIL_EMAIL_FROM',2,'dolibarr-robot@domain.com','chaine',0,'EMail emetteur pour les emails automatiques Dolibarr','2014-12-08 14:08:14'),(1743,'MAIN_MENU_STANDARD',2,'eldy_menu.php','chaine',0,'Module de gestion de la barre de menu du haut pour utilisateurs internes','2015-02-11 19:43:54'),(1744,'MAIN_MENUFRONT_STANDARD',2,'eldy_menu.php','chaine',0,'Module de gestion de la barre de menu du haut pour utilisateurs externes','2015-02-11 19:43:54'),(1745,'MAIN_MENU_SMARTPHONE',2,'iphone_backoffice.php','chaine',0,'Module de gestion de la barre de menu smartphone pour utilisateurs internes','2014-12-08 14:08:14'),(1746,'MAIN_MENUFRONT_SMARTPHONE',2,'iphone_frontoffice.php','chaine',0,'Module de gestion de la barre de menu smartphone pour utilisateurs externes','2014-12-08 14:08:14'),(1747,'MAIN_THEME',2,'eldy','chaine',0,'Default theme','2014-12-08 14:08:14'),(1748,'MAIN_DELAY_ACTIONS_TODO',2,'7','chaine',0,'Tolérance de retard avant alerte (en jours) sur actions planifiées non réalisées','2014-12-08 14:08:14'),(1749,'MAIN_DELAY_ORDERS_TO_PROCESS',2,'2','chaine',0,'Tolérance de retard avant alerte (en jours) sur commandes clients non traitées','2014-12-08 14:08:14'),(1750,'MAIN_DELAY_SUPPLIER_ORDERS_TO_PROCESS',2,'7','chaine',0,'Tolérance de retard avant alerte (en jours) sur commandes fournisseurs non traitées','2014-12-08 14:08:14'),(1751,'MAIN_DELAY_PROPALS_TO_CLOSE',2,'31','chaine',0,'Tolérance de retard avant alerte (en jours) sur propales à cloturer','2014-12-08 14:08:14'),(1752,'MAIN_DELAY_PROPALS_TO_BILL',2,'7','chaine',0,'Tolérance de retard avant alerte (en jours) sur propales non facturées','2014-12-08 14:08:14'),(1753,'MAIN_DELAY_CUSTOMER_BILLS_UNPAYED',2,'31','chaine',0,'Tolérance de retard avant alerte (en jours) sur factures client impayées','2014-12-08 14:08:14'),(1754,'MAIN_DELAY_SUPPLIER_BILLS_TO_PAY',2,'2','chaine',0,'Tolérance de retard avant alerte (en jours) sur factures fournisseur impayées','2014-12-08 14:08:14'),(1755,'MAIN_DELAY_NOT_ACTIVATED_SERVICES',2,'0','chaine',0,'Tolérance de retard avant alerte (en jours) sur services à activer','2014-12-08 14:08:14'),(1756,'MAIN_DELAY_RUNNING_SERVICES',2,'0','chaine',0,'Tolérance de retard avant alerte (en jours) sur services expirés','2014-12-08 14:08:14'),(1757,'MAIN_DELAY_MEMBERS',2,'31','chaine',0,'Tolérance de retard avant alerte (en jours) sur cotisations adhérent en retard','2014-12-08 14:08:14'),(1758,'MAIN_DELAY_TRANSACTIONS_TO_CONCILIATE',2,'62','chaine',0,'Tolérance de retard avant alerte (en jours) sur rapprochements bancaires à faire','2014-12-08 14:08:14'),(1759,'MAILING_EMAIL_FROM',2,'dolibarr@domain.com','chaine',0,'EMail emmetteur pour les envois d emailings','2014-12-08 14:08:14'),(1760,'MAIN_INFO_SOCIETE_COUNTRY',3,'1:FR:France','chaine',0,'','2015-02-26 21:56:28'),(1761,'MAIN_INFO_SOCIETE_NOM',3,'bbb','chaine',0,'','2014-12-08 14:08:20'),(1762,'MAIN_INFO_SOCIETE_STATE',3,'0','chaine',0,'','2015-02-27 14:20:27'),(1763,'MAIN_MONNAIE',3,'EUR','chaine',0,'','2014-12-08 14:08:20'),(1764,'MAIN_LANG_DEFAULT',3,'auto','chaine',0,'','2014-12-08 14:08:20'),(1765,'MAIN_MAIL_EMAIL_FROM',3,'dolibarr-robot@domain.com','chaine',0,'EMail emetteur pour les emails automatiques Dolibarr','2014-12-08 14:08:20'),(1766,'MAIN_MENU_STANDARD',3,'eldy_menu.php','chaine',0,'Module de gestion de la barre de menu du haut pour utilisateurs internes','2015-02-11 19:43:54'),(1767,'MAIN_MENUFRONT_STANDARD',3,'eldy_menu.php','chaine',0,'Module de gestion de la barre de menu du haut pour utilisateurs externes','2015-02-11 19:43:54'),(1768,'MAIN_MENU_SMARTPHONE',3,'iphone_backoffice.php','chaine',0,'Module de gestion de la barre de menu smartphone pour utilisateurs internes','2014-12-08 14:08:20'),(1769,'MAIN_MENUFRONT_SMARTPHONE',3,'iphone_frontoffice.php','chaine',0,'Module de gestion de la barre de menu smartphone pour utilisateurs externes','2014-12-08 14:08:20'),(1770,'MAIN_THEME',3,'eldy','chaine',0,'Default theme','2014-12-08 14:08:20'),(1771,'MAIN_DELAY_ACTIONS_TODO',3,'7','chaine',0,'Tolérance de retard avant alerte (en jours) sur actions planifiées non réalisées','2014-12-08 14:08:20'),(1772,'MAIN_DELAY_ORDERS_TO_PROCESS',3,'2','chaine',0,'Tolérance de retard avant alerte (en jours) sur commandes clients non traitées','2014-12-08 14:08:20'),(1773,'MAIN_DELAY_SUPPLIER_ORDERS_TO_PROCESS',3,'7','chaine',0,'Tolérance de retard avant alerte (en jours) sur commandes fournisseurs non traitées','2014-12-08 14:08:20'),(1774,'MAIN_DELAY_PROPALS_TO_CLOSE',3,'31','chaine',0,'Tolérance de retard avant alerte (en jours) sur propales à cloturer','2014-12-08 14:08:20'),(1775,'MAIN_DELAY_PROPALS_TO_BILL',3,'7','chaine',0,'Tolérance de retard avant alerte (en jours) sur propales non facturées','2014-12-08 14:08:20'),(1776,'MAIN_DELAY_CUSTOMER_BILLS_UNPAYED',3,'31','chaine',0,'Tolérance de retard avant alerte (en jours) sur factures client impayées','2014-12-08 14:08:20'),(1777,'MAIN_DELAY_SUPPLIER_BILLS_TO_PAY',3,'2','chaine',0,'Tolérance de retard avant alerte (en jours) sur factures fournisseur impayées','2014-12-08 14:08:20'),(1778,'MAIN_DELAY_NOT_ACTIVATED_SERVICES',3,'0','chaine',0,'Tolérance de retard avant alerte (en jours) sur services à activer','2014-12-08 14:08:20'),(1779,'MAIN_DELAY_RUNNING_SERVICES',3,'0','chaine',0,'Tolérance de retard avant alerte (en jours) sur services expirés','2014-12-08 14:08:20'),(1780,'MAIN_DELAY_MEMBERS',3,'31','chaine',0,'Tolérance de retard avant alerte (en jours) sur cotisations adhérent en retard','2014-12-08 14:08:20'),(1781,'MAIN_DELAY_TRANSACTIONS_TO_CONCILIATE',3,'62','chaine',0,'Tolérance de retard avant alerte (en jours) sur rapprochements bancaires à faire','2014-12-08 14:08:20'),(1782,'MAILING_EMAIL_FROM',3,'dolibarr@domain.com','chaine',0,'EMail emmetteur pour les envois d emailings','2014-12-08 14:08:20'),(1803,'SYSLOG_FILE',1,'DOL_DATA_ROOT/dolibarr.log','chaine',0,'','2014-12-08 14:15:08'),(1804,'SYSLOG_HANDLERS',1,'[\"mod_syslog_file\"]','chaine',0,'','2014-12-08 14:15:08'),(1805,'MAIN_MODULE_SKINCOLOREDITOR',3,'1',NULL,0,NULL,'2014-12-08 14:35:40'),(1922,'PAYPAL_API_SANDBOX',1,'1','chaine',0,'','2014-12-12 12:11:05'),(1923,'PAYPAL_API_USER',1,'seller_1355312017_biz_api1.mydomain.com','chaine',0,'','2014-12-12 12:11:05'),(1924,'PAYPAL_API_PASSWORD',1,'1355312040','chaine',0,'','2014-12-12 12:11:05'),(1925,'PAYPAL_API_SIGNATURE',1,'ABCDEFWBzvfn0q5iNmbuiDv1y.3EAXIMWyl4C5KvDReR9HDwwAd6dQ4Q','chaine',0,'','2014-12-12 12:11:05'),(1926,'PAYPAL_API_INTEGRAL_OR_PAYPALONLY',1,'integral','chaine',0,'','2014-12-12 12:11:05'),(1927,'PAYPAL_SECURITY_TOKEN',1,'50c82fab36bb3b6aa83e2a50691803b2','chaine',0,'','2014-12-12 12:11:05'),(1928,'PAYPAL_SECURITY_TOKEN_UNIQUE',1,'0','chaine',0,'','2014-12-12 12:11:05'),(1929,'PAYPAL_ADD_PAYMENT_URL',1,'1','chaine',0,'','2014-12-12 12:11:05'),(1980,'MAIN_PDF_FORMAT',1,'EUA4','chaine',0,'','2014-12-12 19:58:05'),(1981,'MAIN_PROFID1_IN_ADDRESS',1,'0','chaine',0,'','2014-12-12 19:58:05'),(1982,'MAIN_PROFID2_IN_ADDRESS',1,'0','chaine',0,'','2014-12-12 19:58:05'),(1983,'MAIN_PROFID3_IN_ADDRESS',1,'0','chaine',0,'','2014-12-12 19:58:05'),(1984,'MAIN_PROFID4_IN_ADDRESS',1,'0','chaine',0,'','2014-12-12 19:58:05'),(1985,'MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT',1,'0','chaine',0,'','2014-12-12 19:58:05'),(2835,'MAIN_USE_CONNECT_TIMEOUT',1,'10','chaine',0,'','2015-01-16 19:28:50'),(2836,'MAIN_USE_RESPONSE_TIMEOUT',1,'30','chaine',0,'','2015-01-16 19:28:50'),(2837,'MAIN_PROXY_USE',1,'0','chaine',0,'','2015-01-16 19:28:50'),(2838,'MAIN_PROXY_HOST',1,'localhost','chaine',0,'','2015-01-16 19:28:50'),(2839,'MAIN_PROXY_PORT',1,'8080','chaine',0,'','2015-01-16 19:28:50'),(2840,'MAIN_PROXY_USER',1,'aaa','chaine',0,'','2015-01-16 19:28:50'),(2841,'MAIN_PROXY_PASS',1,'bbb','chaine',0,'','2015-01-16 19:28:50'),(2848,'OVHSMS_NICK',1,'BN196-OVH','chaine',0,'','2015-01-16 19:32:36'),(2849,'OVHSMS_PASS',1,'bigone-10','chaine',0,'','2015-01-16 19:32:36'),(2850,'OVHSMS_SOAPURL',1,'https://www.ovh.com/soapi/soapi-re-1.55.wsdl','chaine',0,'','2015-01-16 19:32:36'),(2854,'THEME_ELDY_RGB',1,'bfbf00','chaine',0,'','2015-01-18 10:02:53'),(2855,'THEME_ELDY_ENABLE_PERSONALIZED',1,'0','chaine',0,'','2015-01-18 10:02:55'),(2858,'MAIN_SESSION_TIMEOUT',1,'2000','chaine',0,'','2015-01-19 17:01:53'),(2867,'FACSIM_ADDON',1,'mod_facsim_alcoy','chaine',0,'','2015-01-19 17:16:25'),(2868,'POS_SERVICES',1,'0','chaine',0,'','2015-01-19 17:16:51'),(2869,'POS_USE_TICKETS',1,'1','chaine',0,'','2015-01-19 17:16:51'),(2870,'POS_MAX_TTC',1,'100','chaine',0,'','2015-01-19 17:16:51'),(3190,'MAIN_MODULE_HOLIDAY',2,'1',NULL,0,NULL,'2015-02-01 08:52:34'),(3195,'INVOICE_SUPPLIER_ADDON_PDF',1,'canelle','chaine',0,'','2015-02-10 19:50:27'),(3199,'MAIN_FORCE_RELOAD_PAGE',1,'1','chaine',0,NULL,'2015-02-12 16:22:55'),(3223,'OVH_THIRDPARTY_IMPORT',1,'2','chaine',0,'','2015-02-13 16:20:18'),(3409,'AGENDA_USE_EVENT_TYPE',1,'1','chaine',0,'','2015-02-27 18:12:24'),(3886,'MAIN_REMOVE_INSTALL_WARNING',1,'1','chaine',1,'','2015-03-02 18:32:50'),(4013,'MAIN_DELAY_ACTIONS_TODO',1,'7','chaine',0,'','2015-03-06 08:59:12'),(4014,'MAIN_DELAY_PROPALS_TO_CLOSE',1,'31','chaine',0,'','2015-03-06 08:59:12'),(4015,'MAIN_DELAY_PROPALS_TO_BILL',1,'7','chaine',0,'','2015-03-06 08:59:12'),(4016,'MAIN_DELAY_ORDERS_TO_PROCESS',1,'2','chaine',0,'','2015-03-06 08:59:12'),(4017,'MAIN_DELAY_CUSTOMER_BILLS_UNPAYED',1,'31','chaine',0,'','2015-03-06 08:59:12'),(4018,'MAIN_DELAY_SUPPLIER_ORDERS_TO_PROCESS',1,'7','chaine',0,'','2015-03-06 08:59:12'),(4019,'MAIN_DELAY_SUPPLIER_BILLS_TO_PAY',1,'2','chaine',0,'','2015-03-06 08:59:12'),(4020,'MAIN_DELAY_RUNNING_SERVICES',1,'-15','chaine',0,'','2015-03-06 08:59:12'),(4021,'MAIN_DELAY_TRANSACTIONS_TO_CONCILIATE',1,'62','chaine',0,'','2015-03-06 08:59:13'),(4022,'MAIN_DELAY_MEMBERS',1,'31','chaine',0,'','2015-03-06 08:59:13'),(4023,'MAIN_DISABLE_METEO',1,'0','chaine',0,'','2015-03-06 08:59:13'),(4044,'ADHERENT_VAT_FOR_SUBSCRIPTIONS',1,'0','',0,'','2015-03-06 16:06:38'),(4047,'ADHERENT_BANK_USE',1,'bankviainvoice','',0,'','2015-03-06 16:12:30'),(4049,'PHPSANE_SCANIMAGE',1,'/usr/bin/scanimage','chaine',0,'','2015-03-06 21:54:13'),(4050,'PHPSANE_PNMTOJPEG',1,'/usr/bin/pnmtojpeg','chaine',0,'','2015-03-06 21:54:13'),(4051,'PHPSANE_PNMTOTIFF',1,'/usr/bin/pnmtotiff','chaine',0,'','2015-03-06 21:54:13'),(4052,'PHPSANE_OCR',1,'/usr/bin/gocr','chaine',0,'','2015-03-06 21:54:13'),(4548,'ECM_AUTO_TREE_ENABLED',1,'1','chaine',0,'','2015-03-10 15:57:21'),(4579,'MAIN_MODULE_AGENDA',2,'1',NULL,0,NULL,'2015-03-13 15:29:19'),(4580,'MAIN_AGENDA_ACTIONAUTO_COMPANY_CREATE',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4581,'MAIN_AGENDA_ACTIONAUTO_CONTRACT_VALIDATE',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4582,'MAIN_AGENDA_ACTIONAUTO_PROPAL_VALIDATE',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4583,'MAIN_AGENDA_ACTIONAUTO_PROPAL_SENTBYMAIL',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4584,'MAIN_AGENDA_ACTIONAUTO_ORDER_VALIDATE',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4585,'MAIN_AGENDA_ACTIONAUTO_ORDER_SENTBYMAIL',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4586,'MAIN_AGENDA_ACTIONAUTO_BILL_VALIDATE',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4587,'MAIN_AGENDA_ACTIONAUTO_BILL_PAYED',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4588,'MAIN_AGENDA_ACTIONAUTO_BILL_CANCEL',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4589,'MAIN_AGENDA_ACTIONAUTO_BILL_SENTBYMAIL',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4590,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_VALIDATE',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4591,'MAIN_AGENDA_ACTIONAUTO_BILL_SUPPLIER_VALIDATE',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4592,'MAIN_AGENDA_ACTIONAUTO_SHIPPING_VALIDATE',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4593,'MAIN_AGENDA_ACTIONAUTO_SHIPPING_SENTBYMAIL',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4594,'MAIN_AGENDA_ACTIONAUTO_BILL_UNVALIDATE',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4688,'GOOGLE_ENABLE_AGENDA',2,'1','chaine',0,'','2015-03-13 15:36:29'),(4689,'GOOGLE_AGENDA_NAME1',2,'eldy','chaine',0,'','2015-03-13 15:36:29'),(4690,'GOOGLE_AGENDA_SRC1',2,'eldy10@mail.com','chaine',0,'','2015-03-13 15:36:29'),(4691,'GOOGLE_AGENDA_COLOR1',2,'BE6D00','chaine',0,'','2015-03-13 15:36:29'),(4692,'GOOGLE_AGENDA_COLOR2',2,'7A367A','chaine',0,'','2015-03-13 15:36:29'),(4693,'GOOGLE_AGENDA_COLOR3',2,'7A367A','chaine',0,'','2015-03-13 15:36:29'),(4694,'GOOGLE_AGENDA_COLOR4',2,'7A367A','chaine',0,'','2015-03-13 15:36:29'),(4695,'GOOGLE_AGENDA_COLOR5',2,'7A367A','chaine',0,'','2015-03-13 15:36:29'),(4696,'GOOGLE_AGENDA_TIMEZONE',2,'Europe/Paris','chaine',0,'','2015-03-13 15:36:29'),(4697,'GOOGLE_AGENDA_NB',2,'5','chaine',0,'','2015-03-13 15:36:29'),(4725,'SOCIETE_CODECLIENT_ADDON',2,'mod_codeclient_leopard','chaine',0,'Module to control third parties codes','2015-03-13 20:21:35'),(4726,'SOCIETE_CODECOMPTA_ADDON',2,'mod_codecompta_panicum','chaine',0,'Module to control third parties codes','2015-03-13 20:21:35'),(4727,'SOCIETE_FISCAL_MONTH_START',2,'','chaine',0,'Mettre le numero du mois du debut d\\\'annee fiscale, ex: 9 pour septembre','2015-03-13 20:21:35'),(4728,'MAIN_SEARCHFORM_SOCIETE',2,'1','yesno',0,'Show form for quick company search','2015-03-13 20:21:35'),(4729,'MAIN_SEARCHFORM_CONTACT',2,'1','yesno',0,'Show form for quick contact search','2015-03-13 20:21:35'),(4730,'COMPANY_ADDON_PDF_ODT_PATH',2,'DOL_DATA_ROOT/doctemplates/thirdparties','chaine',0,NULL,'2015-03-13 20:21:35'),(4743,'MAIN_MODULE_CLICKTODIAL',2,'1',NULL,0,NULL,'2015-03-13 20:30:28'),(4744,'MAIN_MODULE_NOTIFICATION',2,'1',NULL,0,NULL,'2015-03-13 20:30:34'),(4745,'MAIN_MODULE_WEBSERVICES',2,'1',NULL,0,NULL,'2015-03-13 20:30:41'),(4746,'MAIN_MODULE_PROPALE',2,'1',NULL,0,NULL,'2015-03-13 20:32:38'),(4747,'PROPALE_ADDON_PDF',2,'azur','chaine',0,'Nom du gestionnaire de generation des propales en PDF','2015-03-13 20:32:38'),(4748,'PROPALE_ADDON',2,'mod_propale_marbre','chaine',0,'Nom du gestionnaire de numerotation des propales','2015-03-13 20:32:38'),(4749,'PROPALE_VALIDITY_DURATION',2,'15','chaine',0,'Duration of validity of business proposals','2015-03-13 20:32:38'),(4750,'PROPALE_ADDON_PDF_ODT_PATH',2,'DOL_DATA_ROOT/doctemplates/proposals','chaine',0,NULL,'2015-03-13 20:32:38'),(4752,'MAIN_MODULE_TAX',2,'1',NULL,0,NULL,'2015-03-13 20:32:47'),(4753,'MAIN_MODULE_DON',2,'1',NULL,0,NULL,'2015-03-13 20:32:54'),(4754,'DON_ADDON_MODEL',2,'html_cerfafr','chaine',0,'Nom du gestionnaire de generation de recu de dons','2015-03-13 20:32:54'),(4755,'POS_USE_TICKETS',2,'1','chaine',0,'','2015-03-13 20:33:09'),(4756,'POS_MAX_TTC',2,'100','chaine',0,'','2015-03-13 20:33:09'),(4757,'MAIN_MODULE_POS',2,'1',NULL,0,NULL,'2015-03-13 20:33:09'),(4758,'TICKET_ADDON',2,'mod_ticket_avenc','chaine',0,'Nom du gestionnaire de numerotation des tickets','2015-03-13 20:33:09'),(4759,'MAIN_MODULE_BANQUE',2,'1',NULL,0,NULL,'2015-03-13 20:33:09'),(4760,'MAIN_MODULE_FACTURE',2,'1',NULL,0,NULL,'2015-03-13 20:33:09'),(4761,'FACTURE_ADDON_PDF',2,'crabe','chaine',0,'Name of PDF model of invoice','2015-03-13 20:33:09'),(4762,'FACTURE_ADDON',2,'mod_facture_terre','chaine',0,'Name of numbering numerotation rules of invoice','2015-03-13 20:33:09'),(4763,'FACTURE_ADDON_PDF_ODT_PATH',2,'DOL_DATA_ROOT/doctemplates/invoices','chaine',0,NULL,'2015-03-13 20:33:09'),(4764,'MAIN_MODULE_SOCIETE',2,'1',NULL,0,NULL,'2015-03-13 20:33:09'),(4765,'MAIN_MODULE_PRODUCT',2,'1',NULL,0,NULL,'2015-03-13 20:33:09'),(4766,'PRODUCT_CODEPRODUCT_ADDON',2,'mod_codeproduct_leopard','chaine',0,'Module to control product codes','2015-03-13 20:33:09'),(4767,'MAIN_SEARCHFORM_PRODUITSERVICE',2,'1','yesno',0,'Show form for quick product search','2015-03-13 20:33:09'),(4772,'FACSIM_ADDON',2,'mod_facsim_alcoy','chaine',0,'','2015-03-13 20:33:32'),(4773,'MAIN_MODULE_MAILING',2,'1',NULL,0,NULL,'2015-03-13 20:33:37'),(4774,'MAIN_MODULE_OPENSURVEY',2,'1',NULL,0,NULL,'2015-03-13 20:33:42'),(4782,'AGENDA_USE_EVENT_TYPE',2,'1','chaine',0,'','2015-03-13 20:53:36'),(4884,'AGENDA_DISABLE_EXT',2,'1','chaine',0,'','2015-03-13 22:03:40'),(4928,'COMMANDE_SUPPLIER_ADDON_NUMBER',1,'mod_commande_fournisseur_muguet','chaine',0,'Nom du gestionnaire de numerotation des commandes fournisseur','2015-03-22 09:24:29'),(4929,'INVOICE_SUPPLIER_ADDON_NUMBER',1,'mod_facture_fournisseur_cactus','chaine',0,'Nom du gestionnaire de numerotation des factures fournisseur','2015-03-22 09:24:29'),(5001,'MAIN_CRON_KEY',0,'bc54582fe30d5d4a830c6f582ec28810','chaine',0,'','2015-03-23 17:54:53'),(5009,'CRON_KEY',0,'2c2e755c20be2014098f629865598006','chaine',0,'','2015-03-23 18:06:24'),(5139,'SOCIETE_ADD_REF_IN_LIST',1,'','yesno',0,'Display customer ref into select list','2015-09-08 23:06:08'),(5150,'PROJECT_TASK_ADDON_PDF',1,'','chaine',0,'Name of PDF/ODT tasks manager class','2015-09-08 23:06:14'),(5151,'PROJECT_TASK_ADDON',1,'mod_task_simple','chaine',0,'Name of Numbering Rule task manager class','2015-09-08 23:06:14'),(5152,'PROJECT_TASK_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/tasks','chaine',0,'','2015-09-08 23:06:14'),(5239,'BOOKMARKS_SHOW_IN_MENU',1,'10','chaine',0,'','2016-03-02 15:42:26'),(5271,'DONATION_ART200',1,'','yesno',0,'Option Française - Eligibilité Art200 du CGI','2016-12-21 12:51:28'),(5272,'DONATION_ART238',1,'','yesno',0,'Option Française - Eligibilité Art238 bis du CGI','2016-12-21 12:51:28'),(5274,'DONATION_MESSAGE',1,'Thank you','chaine',0,'Message affiché sur le récépissé de versements ou dons','2016-12-21 12:51:28'),(5349,'MAIN_SEARCHFORM_CONTACT',1,'1','chaine',0,'','2017-10-03 10:11:33'),(5351,'MAIN_SEARCHFORM_PRODUITSERVICE',1,'1','chaine',0,'','2017-10-03 10:11:33'),(5352,'MAIN_SEARCHFORM_PRODUITSERVICE_SUPPLIER',1,'0','chaine',0,'','2017-10-03 10:11:33'),(5353,'MAIN_SEARCHFORM_ADHERENT',1,'1','chaine',0,'','2017-10-03 10:11:33'),(5354,'MAIN_SEARCHFORM_PROJECT',1,'0','chaine',0,'','2017-10-03 10:11:33'),(5394,'FCKEDITOR_ENABLE_DETAILS',1,'1','yesno',0,'WYSIWIG for products details lines for all entities','2017-11-04 15:27:44'),(5395,'FCKEDITOR_ENABLE_USERSIGN',1,'1','yesno',0,'WYSIWIG for user signature','2017-11-04 15:27:44'),(5396,'FCKEDITOR_ENABLE_MAIL',1,'1','yesno',0,'WYSIWIG for products details lines for all entities','2017-11-04 15:27:44'),(5398,'CATEGORIE_RECURSIV_ADD',1,'','yesno',0,'Affect parent categories','2017-11-04 15:27:46'),(5404,'MAIN_MODULE_CATEGORIE',1,'1',NULL,0,NULL,'2017-11-04 15:41:43'),(5415,'EXPEDITION_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/shipment','chaine',0,NULL,'2017-11-15 22:38:28'),(5416,'LIVRAISON_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/delivery','chaine',0,NULL,'2017-11-15 22:38:28'),(5426,'MAIN_MODULE_PROJET',1,'1',NULL,0,NULL,'2017-11-15 22:38:44'),(5427,'PROJECT_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/projects','chaine',0,NULL,'2017-11-15 22:38:44'),(5428,'PROJECT_USE_OPPORTUNIES',1,'1','chaine',0,NULL,'2017-11-15 22:38:44'),(5430,'MAIN_MODULE_EXPORT',1,'1',NULL,0,NULL,'2017-11-15 22:38:56'),(5431,'MAIN_MODULE_IMPORT',1,'1',NULL,0,NULL,'2017-11-15 22:38:58'),(5432,'MAIN_MODULE_MAILING',1,'1',NULL,0,NULL,'2017-11-15 22:39:00'),(5434,'EXPENSEREPORT_ADDON_PDF',1,'standard','chaine',0,'Name of manager to build PDF expense reports documents','2017-11-15 22:39:05'),(5437,'SALARIES_ACCOUNTING_ACCOUNT_CHARGE',1,'641','chaine',0,NULL,'2017-11-15 22:39:08'),(5441,'ADHERENT_ETIQUETTE_TEXT',1,'%FULLNAME%\n%ADDRESS%\n%ZIP% %TOWN%\n%COUNTRY%','text',0,'Text to print on member address sheets','2018-11-23 11:56:07'),(5443,'MAIN_MODULE_PRELEVEMENT',1,'1',NULL,0,NULL,'2017-11-15 22:39:33'),(5453,'MAIN_MODULE_CONTRAT',1,'1',NULL,0,NULL,'2017-11-15 22:39:52'),(5455,'MAIN_MODULE_FICHEINTER',1,'1',NULL,0,NULL,'2017-11-15 22:39:56'),(5459,'MAIN_MODULE_PAYPAL',1,'1',NULL,0,NULL,'2017-11-15 22:41:02'),(5463,'MAIN_MODULE_PROPALE',1,'1',NULL,0,NULL,'2017-11-15 22:41:47'),(5483,'GENBARCODE_BARCODETYPE_THIRDPARTY',1,'6','chaine',0,'','2018-01-16 15:49:43'),(5484,'PRODUIT_DEFAULT_BARCODE_TYPE',1,'2','chaine',0,'','2018-01-16 15:49:46'),(5586,'MAIN_DELAY_EXPENSEREPORTS_TO_PAY',1,'31','chaine',0,'Tolérance de retard avant alerte (en jours) sur les notes de frais impayées','2018-01-22 17:28:18'),(5587,'MAIN_FIX_FOR_BUGGED_MTA',1,'1','chaine',1,'Set constant to fix email ending from PHP with some linux ike system','2018-01-22 17:28:18'),(5590,'MAIN_VERSION_LAST_INSTALL',0,'3.8.3','chaine',0,'Dolibarr version when install','2018-01-22 17:28:42'),(5604,'MAIN_INFO_SOCIETE_LOGO',1,'mybigcompany.png','chaine',0,'','2018-01-22 17:33:49'),(5605,'MAIN_INFO_SOCIETE_LOGO_SMALL',1,'mybigcompany_small.png','chaine',0,'','2018-01-22 17:33:49'),(5606,'MAIN_INFO_SOCIETE_LOGO_MINI',1,'mybigcompany_mini.png','chaine',0,'','2018-01-22 17:33:49'),(5614,'MAIN_SIZE_SHORTLISTE_LIMIT',1,'4','chaine',0,'Longueur maximum des listes courtes (fiche client)','2018-03-13 10:54:46'),(5627,'SUPPLIER_PROPOSAL_ADDON_PDF',1,'aurore','chaine',0,'Name of submodule to generate PDF for supplier quotation request','2018-07-30 11:13:20'),(5628,'SUPPLIER_PROPOSAL_ADDON',1,'mod_supplier_proposal_marbre','chaine',0,'Name of submodule to number supplier quotation request','2018-07-30 11:13:20'),(5629,'SUPPLIER_PROPOSAL_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/supplier_proposal','chaine',0,NULL,'2018-07-30 11:13:20'),(5633,'MAIN_MODULE_API',1,'1',NULL,0,NULL,'2018-07-30 11:13:54'),(5634,'MAIN_MODULE_WEBSERVICES',1,'1',NULL,0,NULL,'2018-07-30 11:13:56'),(5635,'WEBSERVICES_KEY',1,'dolibarrkey','chaine',0,'','2018-07-30 11:14:04'),(5638,'MAIN_MODULE_EXTERNALRSS',1,'1',NULL,0,NULL,'2018-07-30 11:15:04'),(5642,'SOCIETE_CODECOMPTA_ADDON',1,'mod_codecompta_aquarium','chaine',0,'','2018-07-30 11:16:42'),(5707,'CASHDESK_NO_DECREASE_STOCK',1,'1','chaine',0,'','2018-07-30 13:38:11'),(5708,'MAIN_MODULE_PRODUCTBATCH',1,'1',NULL,0,NULL,'2018-07-30 13:38:11'),(5710,'MAIN_MODULE_STOCK',1,'1',NULL,0,NULL,'2018-07-30 13:38:11'),(5711,'MAIN_MODULE_PRODUCT',1,'1',NULL,0,NULL,'2018-07-30 13:38:11'),(5808,'MARGIN_TYPE',1,'costprice','chaine',0,'','2018-07-30 16:32:18'),(5809,'DISPLAY_MARGIN_RATES',1,'1','chaine',0,'','2018-07-30 16:32:20'),(5833,'ACCOUNTING_EXPORT_SEPARATORCSV',1,',','string',0,NULL,'2017-01-29 15:11:56'),(5840,'CHARTOFACCOUNTS',1,'2','chaine',0,NULL,'2017-01-29 15:11:56'),(5841,'ACCOUNTING_EXPORT_MODELCSV',1,'1','chaine',0,NULL,'2017-01-29 15:11:56'),(5842,'ACCOUNTING_LENGTH_GACCOUNT',1,'','chaine',0,NULL,'2017-01-29 15:11:56'),(5843,'ACCOUNTING_LENGTH_AACCOUNT',1,'','chaine',0,NULL,'2017-01-29 15:11:56'),(5844,'ACCOUNTING_LIST_SORT_VENTILATION_TODO',1,'1','yesno',0,NULL,'2017-01-29 15:11:56'),(5845,'ACCOUNTING_LIST_SORT_VENTILATION_DONE',1,'1','yesno',0,NULL,'2017-01-29 15:11:56'),(5846,'ACCOUNTING_EXPORT_DATE',1,'%d%m%Y','chaine',0,NULL,'2017-01-29 15:11:56'),(5848,'ACCOUNTING_EXPORT_FORMAT',1,'csv','chaine',0,NULL,'2017-01-29 15:11:56'),(5853,'MAIN_MODULE_WORKFLOW',1,'1',NULL,0,NULL,'2017-01-29 15:12:12'),(5854,'MAIN_MODULE_NOTIFICATION',1,'1',NULL,0,NULL,'2017-01-29 15:12:35'),(5855,'MAIN_MODULE_OAUTH',1,'1',NULL,0,NULL,'2017-01-29 15:12:41'),(5883,'MAILING_LIMIT_SENDBYWEB',0,'15','chaine',1,'Number of targets to defined packet size when sending mass email','2017-01-29 17:36:33'),(5884,'MAIN_MAIL_DEBUG',1,'0','chaine',1,'','2017-01-29 18:53:02'),(5885,'MAIN_SOAP_DEBUG',1,'0','chaine',1,'','2017-01-29 18:53:02'),(5925,'MAIN_AGENDA_ACTIONAUTO_MEMBER_SUBSCRIPTION',1,'1','chaine',0,'','2017-02-01 14:48:55'),(5931,'DATABASE_PWD_ENCRYPTED',1,'1','chaine',0,'','2017-02-01 15:06:04'),(5932,'MAIN_DISABLE_ALL_MAILS',1,'0','chaine',0,'','2017-02-01 15:09:09'),(5933,'MAIN_MAIL_SENDMODE',1,'mail','chaine',0,'','2017-02-01 15:09:09'),(5934,'MAIN_MAIL_SMTP_PORT',1,'465','chaine',0,'','2017-02-01 15:09:09'),(5935,'MAIN_MAIL_SMTP_SERVER',1,'smtp.mail.com','chaine',0,'','2017-02-01 15:09:09'),(5936,'MAIN_MAIL_SMTPS_ID',1,'eldy10@mail.com','chaine',0,'','2017-02-01 15:09:09'),(5937,'MAIN_MAIL_SMTPS_PW',1,'bidonge','chaine',0,'','2017-02-01 15:09:09'),(5938,'MAIN_MAIL_EMAIL_FROM',1,'robot@example.com','chaine',0,'','2017-02-01 15:09:09'),(5939,'MAIN_MAIL_DEFAULT_FROMTYPE',1,'user','chaine',0,'','2017-02-01 15:09:09'),(5940,'PRELEVEMENT_ID_BANKACCOUNT',1,'1','chaine',0,'','2017-02-06 04:04:47'),(5941,'PRELEVEMENT_ICS',1,'ICS123456','chaine',0,'','2017-02-06 04:04:47'),(5942,'PRELEVEMENT_USER',1,'1','chaine',0,'','2017-02-06 04:04:47'),(5943,'BANKADDON_PDF',1,'sepamandate','chaine',0,'','2017-02-06 04:13:52'),(5947,'CHEQUERECEIPTS_THYME_MASK',1,'CHK{yy}{mm}-{0000@1}','chaine',0,'','2017-02-06 04:16:27'),(5948,'MAIN_MODULE_LOAN',1,'1',NULL,0,NULL,'2017-02-06 19:19:05'),(5954,'MAIN_SUBMODULE_EXPEDITION',1,'1','chaine',0,'','2017-02-06 23:57:37'),(5964,'MAIN_MODULE_TAX',1,'1',NULL,0,NULL,'2017-02-07 18:56:12'),(6019,'MAIN_INFO_SOCIETE_COUNTRY',2,'1:FR:France','chaine',0,'','2017-02-15 17:18:22'),(6020,'MAIN_INFO_SOCIETE_NOM',2,'MySecondCompany','chaine',0,'','2017-02-15 17:18:22'),(6021,'MAIN_INFO_SOCIETE_STATE',2,'0','chaine',0,'','2017-02-15 17:18:22'),(6022,'MAIN_MONNAIE',2,'EUR','chaine',0,'','2017-02-15 17:18:22'),(6023,'MAIN_LANG_DEFAULT',2,'auto','chaine',0,'','2017-02-15 17:18:22'),(6032,'MAIN_MODULE_MULTICURRENCY',1,'1',NULL,0,NULL,'2017-02-15 17:29:59'),(6048,'SYSLOG_FACILITY',0,'LOG_USER','chaine',0,'','2017-02-15 22:37:01'),(6049,'SYSLOG_FIREPHP_INCLUDEPATH',0,'/home/ldestailleur/git/dolibarr_5.0/htdocs/includes/firephp/firephp-core/lib/','chaine',0,'','2017-02-15 22:37:01'),(6050,'SYSLOG_FILE',0,'DOL_DATA_ROOT/dolibarr.log','chaine',0,'','2017-02-15 22:37:01'),(6051,'SYSLOG_CHROMEPHP_INCLUDEPATH',0,'/home/ldestailleur/git/dolibarr_5.0/htdocs/includes/ccampbell/chromephp/','chaine',0,'','2017-02-15 22:37:01'),(6052,'SYSLOG_HANDLERS',0,'[\"mod_syslog_file\"]','chaine',0,'','2017-02-15 22:37:01'),(6092,'MAIN_SIZE_SHORTLIST_LIMIT',0,'3','chaine',0,'Max length for small lists (tabs)','2017-05-12 09:02:38'),(6099,'MAIN_MODULE_SKYPE',1,'1',NULL,0,NULL,'2017-05-12 09:03:51'),(6100,'MAIN_MODULE_GRAVATAR',1,'1',NULL,0,NULL,'2017-05-12 09:03:54'),(6102,'PRODUCT_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/products','chaine',0,'','2017-08-27 13:29:07'),(6103,'CONTRACT_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/contracts','chaine',0,'','2017-08-27 13:29:07'),(6104,'USERGROUP_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/usergroups','chaine',0,'','2017-08-27 13:29:07'),(6105,'USER_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/users','chaine',0,'','2017-08-27 13:29:07'),(6106,'MAIN_ENABLE_OVERWRITE_TRANSLATION',1,'1','chaine',0,'Enable overwrote of translation','2017-08-27 13:29:07'),(6377,'COMMANDE_SAPHIR_MASK',1,'{yy}{mm}{000}{ttt}','chaine',0,'','2017-09-06 07:56:25'),(6518,'GOOGLE_DUPLICATE_INTO_THIRDPARTIES',1,'1','chaine',0,'','2017-09-06 19:43:57'),(6519,'GOOGLE_DUPLICATE_INTO_CONTACTS',1,'0','chaine',0,'','2017-09-06 19:43:57'),(6520,'GOOGLE_TAG_PREFIX',1,'Dolibarr (Thirdparties)','chaine',0,'','2017-09-06 19:43:57'),(6521,'GOOGLE_TAG_PREFIX_CONTACTS',1,'Dolibarr (Contacts/Addresses)','chaine',0,'','2017-09-06 19:43:57'),(6522,'GOOGLE_ENABLE_AGENDA',1,'1','chaine',0,'','2017-09-06 19:44:12'),(6523,'GOOGLE_AGENDA_COLOR1',1,'1B887A','chaine',0,'','2017-09-06 19:44:12'),(6524,'GOOGLE_AGENDA_COLOR2',1,'7A367A','chaine',0,'','2017-09-06 19:44:12'),(6525,'GOOGLE_AGENDA_COLOR3',1,'7A367A','chaine',0,'','2017-09-06 19:44:12'),(6526,'GOOGLE_AGENDA_COLOR4',1,'7A367A','chaine',0,'','2017-09-06 19:44:12'),(6527,'GOOGLE_AGENDA_COLOR5',1,'7A367A','chaine',0,'','2017-09-06 19:44:12'),(6528,'GOOGLE_AGENDA_TIMEZONE',1,'Europe/Paris','chaine',0,'','2017-09-06 19:44:12'),(6529,'GOOGLE_AGENDA_NB',1,'5','chaine',0,'','2017-09-06 19:44:12'),(6543,'MAIN_SMS_DEBUG',0,'1','chaine',1,'This is to enable OVH SMS debug','2017-09-06 19:44:34'),(6562,'BLOCKEDLOG_ENTITY_FINGERPRINT',1,'b63e359ffca54d5c2bab869916eaf23d4a736703028ccbf77ce1167c5f830e7b','chaine',0,'Numeric Unique Fingerprint','2018-01-19 11:27:15'),(6564,'BLOCKEDLOG_DISABLE_NOT_ALLOWED_FOR_COUNTRY',1,'FR','chaine',0,'This is list of country code where the module may be mandatory','2018-01-19 11:27:15'),(6565,'MAIN_MODULE_BOOKMARK',1,'1',NULL,0,'{\"authorid\":\"12\",\"ip\":\"82.240.38.230\"}','2018-01-19 11:27:34'),(6566,'MAIN_MODULE_ADHERENT',1,'1',NULL,0,'{\"authorid\":\"12\",\"ip\":\"82.240.38.230\"}','2018-01-19 11:27:56'),(6567,'ADHERENT_ADDON_PDF',1,'standard','chaine',0,'Name of PDF model of member','2018-01-19 11:27:56'),(6636,'MAIN_MODULE_TICKET_MODELS',1,'1','chaine',0,NULL,'2019-06-05 09:15:29'),(6647,'MAIN_MODULE_SOCIALNETWORKS',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2019-06-05 09:16:49'),(6795,'TICKET_ADDON',1,'mod_ticket_simple','chaine',0,'','2019-09-26 12:07:59'),(6796,'PRODUCT_CODEPRODUCT_ADDON',1,'mod_codeproduct_elephant','chaine',0,'','2019-09-26 12:59:00'),(6800,'CASHDESK_ID_THIRDPARTY1',1,'7','chaine',0,'','2019-09-26 15:30:09'),(6801,'CASHDESK_ID_BANKACCOUNT_CASH1',1,'3','chaine',0,'','2019-09-26 15:30:09'),(6802,'CASHDESK_ID_BANKACCOUNT_CHEQUE1',1,'4','chaine',0,'','2019-09-26 15:30:09'),(6803,'CASHDESK_ID_BANKACCOUNT_CB1',1,'4','chaine',0,'','2019-09-26 15:30:09'),(6804,'CASHDESK_ID_BANKACCOUNT_PRE1',1,'4','chaine',0,'','2019-09-26 15:30:09'),(6805,'CASHDESK_ID_BANKACCOUNT_VIR1',1,'1','chaine',0,'','2019-09-26 15:30:09'),(6806,'CASHDESK_NO_DECREASE_STOCK1',1,'1','chaine',0,'','2019-09-26 15:30:09'),(6811,'FORCEPROJECT_ON_PROPOSAL',1,'1','chaine',0,'','2019-09-27 14:52:57'),(6813,'PROJECT_USE_OPPORTUNITIES',1,'1','chaine',0,'','2019-10-01 11:48:09'),(6814,'PACKTHEMEACTIVATEDTHEME',0,'modOwnTheme','chaine',0,'','2019-10-02 11:41:58'),(6815,'OWNTHEME_COL1',0,'#6a89cc','chaine',0,'','2019-10-02 11:41:58'),(6816,'OWNTHEME_COL2',0,'#60a3bc','chaine',0,'','2019-10-02 11:41:58'),(6817,'DOL_VERSION',0,'10.0.2','chaine',0,'Dolibarr version','2019-10-02 11:41:58'),(6823,'OWNTHEME_COL_BODY_BCKGRD',0,'#E9E9E9','chaine',0,'','2019-10-02 11:41:58'),(6824,'OWNTHEME_COL_LOGO_BCKGRD',0,'#474c80','chaine',0,'','2019-10-02 11:41:58'),(6825,'OWNTHEME_COL_TXT_MENU',0,'#b8c6e5','chaine',0,'','2019-10-02 11:41:58'),(6826,'OWNTHEME_COL_HEADER_BCKGRD',0,'#474c80','chaine',0,'','2019-10-02 11:41:58'),(6827,'OWNTHEME_CUSTOM_CSS',0,'0','yesno',0,'','2019-10-02 11:41:58'),(6828,'OWNTHEME_CUSTOM_JS',0,'0','yesno',0,'','2019-10-02 11:41:58'),(6829,'OWNTHEME_FIXED_MENU',0,'0','yesno',0,'','2019-10-02 11:41:58'),(6830,'OWNTHEME_D_HEADER_FONT_SIZE',0,'1.7rem','chaine',0,'','2019-10-02 11:41:58'),(6831,'OWNTHEME_S_HEADER_FONT_SIZE',0,'1.6rem','chaine',0,'','2019-10-02 11:41:58'),(6832,'OWNTHEME_D_VMENU_FONT_SIZE',0,'1.2rem','chaine',0,'','2019-10-02 11:41:58'),(6833,'OWNTHEME_S_VMENU_FONT_SIZE',0,'1.2rem','chaine',0,'','2019-10-02 11:41:58'),(6844,'MAIN_THEME',0,'eldy','chaine',0,'','2019-10-02 11:46:02'),(6845,'MAIN_MENU_STANDARD',0,'eldy_menu.php','chaine',0,'','2019-10-02 11:46:02'),(6846,'MAIN_MENUFRONT_STANDARD',0,'eldy_menu.php','chaine',0,'','2019-10-02 11:46:02'),(6847,'MAIN_MENU_SMARTPHONE',0,'eldy_menu.php','chaine',0,'','2019-10-02 11:46:02'),(6848,'MAIN_MENUFRONT_SMARTPHONE',0,'eldy_menu.php','chaine',0,'','2019-10-02 11:46:02'),(6851,'BECREATIVE_COL1',1,'#1e88e5','chaine',0,'','2019-10-02 11:47:10'),(6852,'BECREATIVE_COL2',1,'#1e88e5','chaine',0,'','2019-10-02 11:47:10'),(6853,'DOL_VERSION',1,'10.0.2','chaine',0,'Dolibarr version','2019-10-02 11:47:10'),(6859,'BECREATIVE_COL_BODY_BCKGRD',1,'#e6eaef','chaine',0,'','2019-10-02 11:47:10'),(6860,'BECREATIVE_COL_LOGO_BCKGRD',1,'#1e88e5','chaine',0,'','2019-10-02 11:47:10'),(6861,'BECREATIVE_COL_TXT_MENU',1,'#b8c6e5','chaine',0,'','2019-10-02 11:47:10'),(6862,'BECREATIVE_COL_HEADER_BCKGRD',1,'#26a69a','chaine',0,'','2019-10-02 11:47:10'),(6863,'BECREATIVE_CUSTOM_CSS',1,'0','yesno',0,'','2019-10-02 11:47:10'),(6864,'BECREATIVE_CUSTOM_JS',1,'0','yesno',0,'','2019-10-02 11:47:10'),(6865,'BECREATIVE_FIXED_MENU',1,'0','yesno',0,'','2019-10-02 11:47:10'),(6866,'BECREATIVE_D_HEADER_FONT_SIZE',1,'1.7rem','chaine',0,'','2019-10-02 11:47:10'),(6867,'BECREATIVE_S_HEADER_FONT_SIZE',1,'1.6rem','chaine',0,'','2019-10-02 11:47:10'),(6868,'BECREATIVE_D_VMENU_FONT_SIZE',1,'1.2rem','chaine',0,'','2019-10-02 11:47:10'),(6869,'BECREATIVE_S_VMENU_FONT_SIZE',1,'1.2rem','chaine',0,'','2019-10-02 11:47:10'),(6881,'MAIN_MENU_STANDARD',1,'eldy_menu.php','chaine',0,'','2019-10-02 11:48:49'),(6882,'MAIN_MENUFRONT_STANDARD',1,'eldy_menu.php','chaine',0,'','2019-10-02 11:48:49'),(6883,'MAIN_MENU_SMARTPHONE',1,'eldy_menu.php','chaine',0,'','2019-10-02 11:48:49'),(6884,'MAIN_MENUFRONT_SMARTPHONE',1,'eldy_menu.php','chaine',0,'','2019-10-02 11:48:49'),(6885,'ACCOUNTING_ACCOUNT_CUSTOMER',1,'411','chaine',0,'','2019-10-04 08:15:44'),(6886,'ACCOUNTING_ACCOUNT_SUPPLIER',1,'401','chaine',0,'','2019-10-04 08:15:44'),(6887,'SALARIES_ACCOUNTING_ACCOUNT_PAYMENT',1,'421','chaine',0,'','2019-10-04 08:15:44'),(6888,'ACCOUNTING_PRODUCT_BUY_ACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6889,'ACCOUNTING_PRODUCT_SOLD_ACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6890,'ACCOUNTING_PRODUCT_SOLD_INTRA_ACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6891,'ACCOUNTING_PRODUCT_SOLD_EXPORT_ACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6892,'ACCOUNTING_SERVICE_BUY_ACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6893,'ACCOUNTING_SERVICE_SOLD_ACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6894,'ACCOUNTING_VAT_BUY_ACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6895,'ACCOUNTING_VAT_SOLD_ACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6896,'ACCOUNTING_VAT_PAY_ACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6897,'ACCOUNTING_ACCOUNT_SUSPENSE',1,'471','chaine',0,'','2019-10-04 08:15:44'),(6898,'ACCOUNTING_ACCOUNT_TRANSFER_CASH',1,'58','chaine',0,'','2019-10-04 08:15:44'),(6899,'DONATION_ACCOUNTINGACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6900,'ADHERENT_SUBSCRIPTION_ACCOUNTINGACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6901,'LOAN_ACCOUNTING_ACCOUNT_CAPITAL',1,'164','chaine',0,'','2019-10-04 08:15:44'),(6902,'LOAN_ACCOUNTING_ACCOUNT_INTEREST',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6903,'LOAN_ACCOUNTING_ACCOUNT_INSURANCE',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6912,'TICKET_ENABLE_PUBLIC_INTERFACE',1,'1','chaine',0,'','2019-10-04 11:44:33'),(6934,'TICKET_NOTIFICATION_EMAIL_FROM',1,'fff','chaine',0,'','2019-10-04 12:03:51'),(6935,'TICKET_NOTIFICATION_EMAIL_TO',1,'ff','chaine',0,'','2019-10-04 12:03:51'),(6936,'TICKET_MESSAGE_MAIL_INTRO',1,'Hello,
\r\nA new response was sent on a ticket that you contact. Here is the message:\"\"','chaine',0,'','2019-10-04 12:03:51'),(6937,'TICKET_MESSAGE_MAIL_SIGNATURE',1,'

Sincerely,

\r\n\r\n

--\"\"

\r\n','chaine',0,'','2019-10-04 12:03:51'),(7027,'USER_PASSWORD_GENERATED',1,'Perso','chaine',0,'','2019-10-07 10:52:46'),(7028,'USER_PASSWORD_PATTERN',1,'12;1;0;1;0;1','chaine',0,'','2019-10-07 10:57:03'),(7034,'BOM_ADDON',1,'mod_bom_standard','chaine',0,'Name of numbering rules of BOM','2019-10-08 18:49:41'),(7035,'BOM_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/boms','chaine',0,NULL,'2019-10-08 18:49:41'),(7036,'MAIN_MODULE_GEOIPMAXMIND',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2019-10-08 18:51:54'),(7037,'MAIN_MODULE_DAV',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2019-10-08 18:54:07'),(7122,'BOM_ADDON_PDF',1,'generic_bom_odt','chaine',0,'','2019-11-28 14:00:58'),(7195,'MAIN_AGENDA_ACTIONAUTO_MO_VALIDATE',1,'1','chaine',0,'','2019-11-29 08:44:37'),(7196,'MAIN_AGENDA_ACTIONAUTO_MO_PRODUCED',1,'1','chaine',0,'','2019-11-29 08:44:37'),(7197,'MAIN_AGENDA_ACTIONAUTO_MO_DELETE',1,'1','chaine',0,'','2019-11-29 08:44:37'),(7198,'MAIN_AGENDA_ACTIONAUTO_MO_CANCEL',1,'1','chaine',0,'','2019-11-29 08:44:37'),(7201,'TICKET_PUBLIC_INTERFACE_TOPIC',1,'MyBigCompany public interface for Ticket','chaine',0,'','2019-11-29 08:49:36'),(7202,'TICKET_PUBLIC_TEXT_HOME',1,'You can create a support ticket or view existing from its identifier tracking ticket.','chaine',0,'','2019-11-29 08:49:36'),(7203,'TICKET_PUBLIC_TEXT_HELP_MESSAGE',1,'Please accurately describe the problem. Provide the most information possible to allow us to correctly identify your request.','chaine',0,'','2019-11-29 08:49:36'),(7204,'TICKET_MESSAGE_MAIL_NEW',1,'TicketMessageMailNewText','chaine',0,'','2019-11-29 08:49:36'),(7220,'MRP_MO_ADDON',1,'mod_mo_standard','chaine',0,'Name of numbering rules of MO','2019-11-29 08:57:42'),(7221,'MRP_MO_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/mrps','chaine',0,NULL,'2019-11-29 08:57:42'),(7222,'MRP_MO_ADDON_PDF',1,'generic_mo_odt','chaine',0,'','2019-11-29 08:57:47'),(7254,'MAIN_INFO_OPENINGHOURS_MONDAY',1,'8-12 13-18','chaine',0,'','2019-12-19 11:14:21'),(7255,'MAIN_INFO_OPENINGHOURS_TUESDAY',1,'8-12 13-18','chaine',0,'','2019-12-19 11:14:21'),(7256,'MAIN_INFO_OPENINGHOURS_WEDNESDAY',1,'8-13','chaine',0,'','2019-12-19 11:14:21'),(7257,'MAIN_INFO_OPENINGHOURS_THURSDAY',1,'8-12 13-18','chaine',0,'','2019-12-19 11:14:21'),(7258,'MAIN_INFO_OPENINGHOURS_FRIDAY',1,'8-12 13-18','chaine',0,'','2019-12-19 11:14:21'),(7264,'MAIN_INFO_ACCOUNTANT_NAME',1,'Bob Bookkeeper','chaine',0,'','2019-12-19 11:14:54'),(7265,'MAIN_INFO_ACCOUNTANT_TOWN',1,'Berlin','chaine',0,'','2019-12-19 11:14:54'),(7266,'MAIN_INFO_ACCOUNTANT_STATE',1,'0','chaine',0,'','2019-12-19 11:14:54'),(7267,'MAIN_INFO_ACCOUNTANT_COUNTRY',1,'5','chaine',0,'','2019-12-19 11:14:54'),(7268,'MAIN_INFO_ACCOUNTANT_MAIL',1,'mybookkeeper@example.com','chaine',0,'','2019-12-19 11:14:54'),(7313,'MODULEBUILDER_ASCIIDOCTOR',1,'asciidoctor','chaine',0,'','2019-12-20 10:57:21'),(7314,'MODULEBUILDER_ASCIIDOCTORPDF',1,'asciidoctor-pdf','chaine',0,'','2019-12-20 10:57:21'),(7337,'EXTERNAL_RSS_TITLE_1',1,'Dolibarr.org News','chaine',0,'','2019-12-20 12:10:38'),(7338,'EXTERNAL_RSS_URLRSS_1',1,'https://www.dolibarr.org/rss','chaine',0,'','2019-12-20 12:10:38'),(7339,'EXPENSEREPORT_ADDON',1,'mod_expensereport_jade','chaine',0,'','2019-12-20 16:33:46'),(7378,'COMPANY_USE_SEARCH_TO_SELECT',1,'0','chaine',0,'','2019-12-21 15:54:22'),(7420,'CASHDESK_SERVICES',1,'0','chaine',0,'','2019-12-23 12:15:06'),(7421,'TAKEPOS_ROOT_CATEGORY_ID',1,'31','chaine',0,'','2019-12-23 12:15:06'),(7422,'TAKEPOSCONNECTOR',1,'0','chaine',0,'','2019-12-23 12:15:06'),(7423,'TAKEPOS_BAR_RESTAURANT',1,'0','chaine',0,'','2019-12-23 12:15:06'),(7424,'TAKEPOS_TICKET_VAT_GROUPPED',1,'0','chaine',0,'','2019-12-23 12:15:06'),(7425,'TAKEPOS_AUTO_PRINT_TICKETS',1,'0','int',0,'','2019-12-23 12:15:06'),(7426,'TAKEPOS_NUMPAD',1,'0','chaine',0,'','2019-12-23 12:15:06'),(7427,'TAKEPOS_NUM_TERMINALS',1,'1','chaine',0,'','2019-12-23 12:15:06'),(7428,'TAKEPOS_DIRECT_PAYMENT',1,'0','int',0,'','2019-12-23 12:15:06'),(7429,'TAKEPOS_CUSTOM_RECEIPT',1,'0','int',0,'','2019-12-23 12:15:06'),(7430,'TAKEPOS_EMAIL_TEMPLATE_INVOICE',1,'-1','chaine',0,'','2019-12-23 12:15:06'),(7452,'MEMBER_ENABLE_PUBLIC',1,'1','chaine',0,'','2020-01-01 10:31:46'),(7453,'MEMBER_NEWFORM_AMOUNT',1,'20','chaine',0,'','2020-01-01 10:31:46'),(7454,'MEMBER_NEWFORM_EDITAMOUNT',1,'0','chaine',0,'','2020-01-01 10:31:46'),(7455,'MEMBER_NEWFORM_PAYONLINE',1,'all','chaine',0,'','2020-01-01 10:31:46'),(7456,'MEMBER_NEWFORM_FORCETYPE',1,'1','chaine',0,'','2020-01-01 10:31:46'),(7470,'STRIPE_TEST_PUBLISHABLE_KEY',1,'pk_test_123456789','chaine',0,'','2020-01-01 11:43:44'),(7471,'STRIPE_TEST_SECRET_KEY',1,'sk_test_123456','chaine',0,'','2020-01-01 11:43:44'),(7472,'STRIPE_BANK_ACCOUNT_FOR_PAYMENTS',1,'4','chaine',0,'','2020-01-01 11:43:44'),(7473,'STRIPE_USER_ACCOUNT_FOR_ACTIONS',1,'1','chaine',0,'','2020-01-01 11:43:44'),(7489,'CAPTURESERVER_SECURITY_KEY',1,'securitykey123','chaine',0,'','2020-01-01 12:00:49'),(8136,'MAIN_AGENDA_ACTIONAUTO_EXPENSE_DELETE',1,'1','chaine',0,'','2020-01-02 19:56:28'),(8190,'ACCOUNTING_PRODUCT_MODE',1,'ACCOUNTANCY_SELL_EXPORT','chaine',0,'','2020-01-06 01:23:30'),(8191,'MAIN_ENABLE_DEFAULT_VALUES',1,'1','chaine',0,'','2020-01-06 16:09:52'),(8210,'CABINETMED_RHEUMATOLOGY_ON',1,'0','texte',0,'','2020-01-06 16:51:43'),(8213,'MAIN_SEARCHFORM_SOCIETE',1,'1','texte',0,'','2020-01-06 16:51:43'),(8214,'CABINETMED_BANK_PATIENT_REQUIRED',1,'0','texte',0,'','2020-01-06 16:51:43'),(8215,'DIAGNOSTIC_IS_NOT_MANDATORY',1,'1','texte',0,'','2020-01-06 16:51:43'),(8216,'USER_ADDON_PDF_ODT',1,'generic_user_odt','chaine',0,'','2020-01-07 13:45:19'),(8217,'USERGROUP_ADDON_PDF_ODT',1,'generic_usergroup_odt','chaine',0,'','2020-01-07 13:45:23'),(8230,'MAIN_MODULE_EMAILCOLLECTOR',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2020-01-12 20:13:55'),(8232,'MAIN_MODULE_SUPPLIERPROPOSAL',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2020-01-13 14:37:09'),(8233,'MAIN_MODULE_EXPEDITION',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2020-01-13 14:38:20'),(8252,'SYSTEMTOOLS_MYSQLDUMP',1,'/usr/bin/mysqldump','chaine',0,'','2020-01-15 15:42:41'),(8259,'ACCOUNTING_REEXPORT',1,'1','yesno',0,'','2020-01-17 13:42:56'),(8291,'PRODUIT_MULTIPRICES_LIMIT',1,'5','chaine',0,'','2020-01-17 14:21:46'),(8293,'PRODUIT_CUSTOMER_PRICES_BY_QTY',1,'0','chaine',0,'','2020-01-17 14:21:46'),(8303,'PRODUCT_PRICE_UNIQ',1,'0','chaine',0,'','2020-01-17 14:25:30'),(8304,'PRODUIT_MULTIPRICES',1,'0','chaine',0,'','2020-01-17 14:25:30'),(8305,'PRODUIT_CUSTOMER_PRICES',1,'1','chaine',0,'','2020-01-17 14:25:30'),(8306,'PRODUIT_SOUSPRODUITS',1,'0','chaine',0,'','2020-01-17 14:25:30'),(8307,'PRODUIT_DESC_IN_FORM',1,'0','chaine',0,'','2020-01-17 14:25:30'),(8308,'PRODUIT_TEXTS_IN_THIRDPARTY_LANGUAGE',1,'0','chaine',0,'','2020-01-17 14:25:30'),(8309,'PRODUIT_USE_SEARCH_TO_SELECT',1,'1','chaine',0,'','2020-01-17 14:25:30'),(8310,'PRODUIT_FOURN_TEXTS',1,'0','chaine',0,'','2020-01-17 14:25:30'),(8313,'MAIN_MODULE_FCKEDITOR',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2020-01-18 17:13:27'),(8314,'FCKEDITOR_ENABLE_TICKET',1,'1','chaine',0,'','2020-01-18 19:39:54'),(8321,'FCKEDITOR_SKIN',1,'moono-lisa','chaine',0,'','2020-01-18 19:41:15'),(8322,'FCKEDITOR_TEST',1,'Test < aaa
\r\n
\r\n\"\"','chaine',0,'','2020-01-18 19:41:15'),(8486,'MAIN_MULTILANGS',1,'1','chaine',0,'','2020-01-21 09:40:00'),(8491,'MAIN_DISABLE_JAVASCRIPT',1,'0','chaine',0,'','2020-01-21 09:40:00'),(8492,'MAIN_BUTTON_HIDE_UNAUTHORIZED',1,'0','chaine',0,'','2020-01-21 09:40:00'),(8496,'MAIN_SHOW_LOGO',1,'1','chaine',0,'','2020-01-21 09:40:00'),(8498,'MAIN_HELPCENTER_DISABLELINK',0,'0','chaine',0,'','2020-01-21 09:40:00'),(8501,'MAIN_BUGTRACK_ENABLELINK',1,'0','chaine',0,'','2020-01-21 09:40:00'),(8554,'MAIN_INFO_SOCIETE_FACEBOOK_URL',1,'dolibarr','chaine',0,'','2020-06-12 17:24:42'),(8555,'MAIN_INFO_SOCIETE_TWITTER_URL',1,'dolibarr','chaine',0,'','2020-06-12 17:24:42'),(8556,'MAIN_INFO_SOCIETE_LINKEDIN_URL',1,'https://www.linkedin.com/company/9400559/admin/','chaine',0,'','2020-06-12 17:24:42'),(8557,'MAIN_INFO_SOCIETE_INSTAGRAM_URL',1,'dolibarr','chaine',0,'','2020-06-12 17:24:42'),(8558,'MAIN_INFO_SOCIETE_YOUTUBE_URL',1,'DolibarrERPCRM','chaine',0,'','2020-06-12 17:24:42'),(8559,'MAIN_INFO_SOCIETE_GITHUB_URL',1,'dolibarr','chaine',0,'','2020-06-12 17:24:42'),(8577,'PRODUCT_PRICE_BASE_TYPE',0,'HT','string',0,NULL,'2020-12-10 12:24:38'),(8612,'MAIN_UPLOAD_DOC',1,'50000','chaine',0,'','2020-12-10 12:26:31'),(8613,'MAIN_UMASK',1,'0664','chaine',0,'','2020-12-10 12:26:31'),(8614,'MAIN_ANTIVIRUS_PARAM',1,'--fdpass','chaine',0,'','2020-12-10 12:26:31'),(8619,'WEBSITE_EDITINLINE',1,'0','chaine',0,'','2020-12-10 12:27:05'),(8620,'WEBSITE_SUBCONTAINERSINLINE',1,'1','chaine',0,'','2020-12-10 12:27:17'),(8633,'MAIN_MODULE_RECEPTION',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2020-12-10 12:30:13'),(8634,'RECEPTION_ADDON_PDF',1,'squille','chaine',0,'Nom du gestionnaire de generation des bons receptions en PDF','2020-12-10 12:30:13'),(8635,'RECEPTION_ADDON_NUMBER',1,'mod_reception_beryl','chaine',0,'Name for numbering manager for receptions','2020-12-10 12:30:13'),(8636,'RECEPTION_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/receptions','chaine',0,NULL,'2020-12-10 12:30:13'),(8637,'MAIN_SUBMODULE_RECEPTION',1,'1','chaine',0,'Enable receptions','2020-12-10 12:30:13'),(8638,'MAIN_MODULE_PAYMENTBYBANKTRANSFER',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2020-12-10 12:30:17'),(8640,'MAIN_MODULE_MARGIN_TABS_0',1,'product:+margin:Margins:margins:$user->rights->margins->liretous:/margin/tabs/productMargins.php?id=__ID__','chaine',0,NULL,'2020-12-10 12:30:20'),(8641,'MAIN_MODULE_MARGIN_TABS_1',1,'thirdparty:+margin:Margins:margins:empty($user->socid) && $user->rights->margins->liretous && ($object->client > 0):/margin/tabs/thirdpartyMargins.php?socid=__ID__','chaine',0,NULL,'2020-12-10 12:30:20'),(8643,'MAIN_MODULE_BLOCKEDLOG',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2020-12-10 12:31:17'),(8644,'MAIN_MODULE_INCOTERM',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2020-12-10 12:31:36'),(8645,'INCOTERM_ACTIVATE',1,'','chaine',0,'Description de INCOTERM_ACTIVATE','2020-12-10 12:31:36'),(8715,'SYSLOG_LEVEL',0,'5','chaine',0,'','2021-04-15 10:34:05'),(8716,'MAIN_SECURITY_HASH_ALGO',1,'password_hash','chaine',1,'','2021-04-15 10:38:33'),(8717,'MAIN_INFO_SOCIETE_COUNTRY',1,'117:IN:India','chaine',0,'','2021-04-15 10:46:30'),(8718,'MAIN_INFO_SOCIETE_NOM',1,'MyBigCompany','chaine',0,'','2021-04-15 10:46:30'),(8719,'MAIN_INFO_SOCIETE_ADDRESS',1,'21 Jump street.','chaine',0,'','2021-04-15 10:46:30'),(8720,'MAIN_INFO_SOCIETE_TOWN',1,'MyTown','chaine',0,'','2021-04-15 10:46:30'),(8721,'MAIN_INFO_SOCIETE_ZIP',1,'75500','chaine',0,'','2021-04-15 10:46:30'),(8722,'MAIN_MONNAIE',1,'EUR','chaine',0,'','2021-04-15 10:46:30'),(8723,'MAIN_INFO_SOCIETE_TEL',1,'09123123','chaine',0,'','2021-04-15 10:46:30'),(8724,'MAIN_INFO_SOCIETE_FAX',1,'09123124','chaine',0,'','2021-04-15 10:46:30'),(8725,'MAIN_INFO_SOCIETE_MAIL',1,'myemail@mybigcompany.com','chaine',0,'','2021-04-15 10:46:30'),(8726,'MAIN_INFO_SOCIETE_WEB',1,'https://www.dolibarr.org','chaine',0,'','2021-04-15 10:46:30'),(8727,'MAIN_INFO_SOCIETE_NOTE',1,'This is note about my company','chaine',0,'','2021-04-15 10:46:30'),(8728,'MAIN_INFO_SOCIETE_LOGO_SQUARRED',1,'mybigcompany_squarred.png','chaine',0,'','2021-04-15 10:46:30'),(8729,'MAIN_INFO_SOCIETE_LOGO_SQUARRED_SMALL',1,'mybigcompany_squarred_small.png','chaine',0,'','2021-04-15 10:46:30'),(8730,'MAIN_INFO_SOCIETE_LOGO_SQUARRED_MINI',1,'mybigcompany_squarred_mini.png','chaine',0,'','2021-04-15 10:46:30'),(8731,'MAIN_INFO_SOCIETE_MANAGERS',1,'Zack Zeceo','chaine',0,'','2021-04-15 10:46:30'),(8732,'MAIN_INFO_GDPR',1,'Zack Zeceo','chaine',0,'','2021-04-15 10:46:30'),(8733,'MAIN_INFO_CAPITAL',1,'10000','chaine',0,'','2021-04-15 10:46:30'),(8734,'MAIN_INFO_SOCIETE_FORME_JURIDIQUE',1,'0','chaine',0,'','2021-04-15 10:46:30'),(8735,'MAIN_INFO_SIREN',1,'123456','chaine',0,'','2021-04-15 10:46:30'),(8736,'MAIN_INFO_SIRET',1,'ABC-DEF','chaine',0,'','2021-04-15 10:46:30'),(8737,'MAIN_INFO_APE',1,'15E-45-8D','chaine',0,'','2021-04-15 10:46:30'),(8738,'MAIN_INFO_TVAINTRA',1,'FR12345678','chaine',0,'','2021-04-15 10:46:30'),(8739,'MAIN_INFO_SOCIETE_OBJECT',1,'A company demo to show how Dolibarr ERP CRM is wonderfull','chaine',0,'','2021-04-15 10:46:30'),(8740,'SOCIETE_FISCAL_MONTH_START',1,'4','chaine',0,'','2021-04-15 10:46:30'),(8741,'FACTURE_TVAOPTION',1,'1','chaine',0,'','2021-04-15 10:46:30'),(8742,'FACTURE_LOCAL_TAX1_OPTION',1,'localtax1on','chaine',0,'','2021-04-15 10:46:30'),(8743,'FACTURE_LOCAL_TAX2_OPTION',1,'localtax2on','chaine',0,'','2021-04-15 10:46:30'),(8744,'MAIN_INFO_VALUE_LOCALTAX1',1,'0','chaine',0,'','2021-04-15 10:46:30'),(8745,'MAIN_INFO_LOCALTAX_CALC1',1,'0','chaine',0,'','2021-04-15 10:46:30'),(8746,'MAIN_INFO_VALUE_LOCALTAX2',1,'0','chaine',0,'','2021-04-15 10:46:30'),(8747,'MAIN_INFO_LOCALTAX_CALC2',1,'0','chaine',0,'','2021-04-15 10:46:30'),(8759,'MAIN_LOGIN_BACKGROUND',1,'background_dolibarr.jpg','chaine',0,'','2021-04-15 10:54:37'),(8760,'MAIN_LANG_DEFAULT',1,'auto','chaine',0,'','2021-04-15 10:56:30'),(8761,'MAIN_IHM_PARAMS_REV',1,'13','chaine',0,'','2021-04-15 10:56:30'),(8762,'MAIN_THEME',1,'eldy','chaine',0,'','2021-04-15 10:56:30'),(8763,'THEME_ELDY_USE_HOVER',1,'237,244,251','chaine',0,'','2021-04-15 10:56:30'),(8764,'MAIN_SIZE_LISTE_LIMIT',1,'25','chaine',0,'','2021-04-15 10:56:30'),(8765,'MAIN_SIZE_SHORTLIST_LIMIT',1,'3','chaine',0,'','2021-04-15 10:56:30'),(8766,'MAIN_START_WEEK',1,'1','chaine',0,'','2021-04-15 10:56:30'),(8767,'MAIN_DEFAULT_WORKING_DAYS',1,'1-5','chaine',0,'','2021-04-15 10:56:30'),(8768,'MAIN_DEFAULT_WORKING_HOURS',1,'9-18','chaine',0,'','2021-04-15 10:56:30'),(8769,'MAIN_FIRSTNAME_NAME_POSITION',1,'0','chaine',0,'','2021-04-15 10:56:30'),(8770,'MAIN_HOME',1,'__(NoteSomeFeaturesAreDisabled)__
\r\n__(SomeTranslationAreUncomplete)__','chaine',0,'','2021-04-15 10:56:30'),(8771,'MAIN_FEATURES_LEVEL',0,'0','chaine',1,'Level of features to show (0=stable only, 1=stable+experimental, 2=stable+experimental+development','2021-04-15 11:46:30'),(8775,'MAIN_AGENDA_ACTIONAUTO_COMPANY_SENTBYMAIL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8776,'MAIN_AGENDA_ACTIONAUTO_COMPANY_CREATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8777,'MAIN_AGENDA_ACTIONAUTO_COMPANY_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8778,'MAIN_AGENDA_ACTIONAUTO_PROPAL_CLOSE_REFUSED',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8779,'MAIN_AGENDA_ACTIONAUTO_PROPAL_CLASSIFY_BILLED',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8780,'MAIN_AGENDA_ACTIONAUTO_PROPAL_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8781,'MAIN_AGENDA_ACTIONAUTO_PROPAL_VALIDATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8782,'MAIN_AGENDA_ACTIONAUTO_PROPAL_CLOSE_SIGNED',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8783,'MAIN_AGENDA_ACTIONAUTO_PROPAL_SENTBYMAIL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8784,'MAIN_AGENDA_ACTIONAUTO_ORDER_VALIDATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8785,'MAIN_AGENDA_ACTIONAUTO_ORDER_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8786,'MAIN_AGENDA_ACTIONAUTO_ORDER_SENTBYMAIL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8787,'MAIN_AGENDA_ACTIONAUTO_ORDER_CANCEL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8788,'MAIN_AGENDA_ACTIONAUTO_ORDER_CLASSIFY_BILLED',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8789,'MAIN_AGENDA_ACTIONAUTO_ORDER_CLOSE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8790,'MAIN_AGENDA_ACTIONAUTO_BILL_VALIDATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8791,'MAIN_AGENDA_ACTIONAUTO_BILL_PAYED',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8792,'MAIN_AGENDA_ACTIONAUTO_BILL_CANCEL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8793,'MAIN_AGENDA_ACTIONAUTO_BILL_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8794,'MAIN_AGENDA_ACTIONAUTO_BILL_SENTBYMAIL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8795,'MAIN_AGENDA_ACTIONAUTO_PROPOSAL_SUPPLIER_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8796,'MAIN_AGENDA_ACTIONAUTO_PROPOSAL_SUPPLIER_VALIDATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8797,'MAIN_AGENDA_ACTIONAUTO_PROPOSAL_SUPPLIER_SENTBYMAIL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8798,'MAIN_AGENDA_ACTIONAUTO_PROPOSAL_SUPPLIER_CLOSE_SIGNED',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8799,'MAIN_AGENDA_ACTIONAUTO_PROPOSAL_SUPPLIER_CLOSE_REFUSED',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8800,'MAIN_AGENDA_ACTIONAUTO_BILL_UNVALIDATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8801,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_CREATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8802,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_VALIDATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8803,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_APPROVE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8804,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_RECEIVE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8805,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_SUBMIT',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8806,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_REFUSE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8807,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_CLASSIFY_BILLED',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8808,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_SENTBYMAIL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8809,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8810,'MAIN_AGENDA_ACTIONAUTO_BILL_SUPPLIER_VALIDATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8811,'MAIN_AGENDA_ACTIONAUTO_BILL_SUPPLIER_UNVALIDATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8812,'MAIN_AGENDA_ACTIONAUTO_BILL_SUPPLIER_PAYED',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8813,'MAIN_AGENDA_ACTIONAUTO_BILL_SUPPLIER_SENTBYMAIL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8814,'MAIN_AGENDA_ACTIONAUTO_BILL_SUPPLIER_CANCELED',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8815,'MAIN_AGENDA_ACTIONAUTO_BILL_SUPPLIER_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8816,'MAIN_AGENDA_ACTIONAUTO_CONTRACT_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8817,'MAIN_AGENDA_ACTIONAUTO_CONTRACT_SENTBYMAIL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8818,'MAIN_AGENDA_ACTIONAUTO_CONTRACT_VALIDATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8819,'MAIN_AGENDA_ACTIONAUTO_FICHINTER_SENTBYMAIL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8820,'MAIN_AGENDA_ACTIONAUTO_FICHINTER_VALIDATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8821,'MAIN_AGENDA_ACTIONAUTO_FICHINTER_REOPEN',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8822,'MAIN_AGENDA_ACTIONAUTO_SHIPPING_VALIDATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8823,'MAIN_AGENDA_ACTIONAUTO_SHIPPING_SENTBYMAIL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8824,'MAIN_AGENDA_ACTIONAUTO_MEMBER_VALIDATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8825,'MAIN_AGENDA_ACTIONAUTO_MEMBER_SENTBYMAIL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8826,'MAIN_AGENDA_ACTIONAUTO_MEMBER_SUBSCRIPTION_CREATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8827,'MAIN_AGENDA_ACTIONAUTO_MEMBER_RESILIATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8828,'MAIN_AGENDA_ACTIONAUTO_MEMBER_MODIFY',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8829,'MAIN_AGENDA_ACTIONAUTO_MEMBER_SUBSCRIPTION_MODIFY',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8830,'MAIN_AGENDA_ACTIONAUTO_MEMBER_SUBSCRIPTION_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8831,'MAIN_AGENDA_ACTIONAUTO_MEMBER_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8832,'MAIN_AGENDA_ACTIONAUTO_PRODUCT_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8833,'MAIN_AGENDA_ACTIONAUTO_PRODUCT_CREATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8834,'MAIN_AGENDA_ACTIONAUTO_PRODUCT_MODIFY',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8835,'MAIN_AGENDA_ACTIONAUTO_TASK_CREATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8836,'MAIN_AGENDA_ACTIONAUTO_FICHINTER_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8837,'MAIN_AGENDA_ACTIONAUTO_TASK_MODIFY',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8838,'MAIN_AGENDA_ACTIONAUTO_TASK_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8839,'MAIN_AGENDA_ACTIONAUTO_CONTACT_CREATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8840,'MAIN_AGENDA_ACTIONAUTO_CONTACT_SENTBYMAIL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8841,'MAIN_AGENDA_ACTIONAUTO_CONTACT_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8842,'MAIN_AGENDA_ACTIONAUTO_PROJECT_CREATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8843,'MAIN_AGENDA_ACTIONAUTO_PROJECT_MODIFY',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8844,'MAIN_AGENDA_ACTIONAUTO_PROJECT_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8845,'MAIN_AGENDA_ACTIONAUTO_TICKET_CREATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8846,'MAIN_AGENDA_ACTIONAUTO_TICKET_MODIFY',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8847,'MAIN_AGENDA_ACTIONAUTO_TICKET_ASSIGNED',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8848,'MAIN_AGENDA_ACTIONAUTO_TICKET_CLOSE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8849,'MAIN_AGENDA_ACTIONAUTO_TICKET_SENTBYMAIL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8850,'MAIN_AGENDA_ACTIONAUTO_TICKET_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8851,'MAIN_AGENDA_ACTIONAUTO_EXPENSE_REPORT_CREATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8852,'MAIN_AGENDA_ACTIONAUTO_EXPENSE_REPORT_VALIDATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8853,'MAIN_AGENDA_ACTIONAUTO_EXPENSE_REPORT_APPROVE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8854,'MAIN_AGENDA_ACTIONAUTO_EXPENSE_REPORT_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8855,'MAIN_AGENDA_ACTIONAUTO_EXPENSE_REPORT_PAID',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8856,'MAIN_AGENDA_ACTIONAUTO_HOLIDAY_CREATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8857,'MAIN_AGENDA_ACTIONAUTO_HOLIDAY_VALIDATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8858,'MAIN_AGENDA_ACTIONAUTO_HOLIDAY_APPROVE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8859,'MAIN_AGENDA_ACTIONAUTO_USER_SENTBYMAIL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8860,'MAIN_AGENDA_ACTIONAUTO_BOM_VALIDATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8861,'MAIN_AGENDA_ACTIONAUTO_BOM_UNVALIDATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8862,'MAIN_AGENDA_ACTIONAUTO_BOM_CLOSE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8863,'MAIN_AGENDA_ACTIONAUTO_BOM_REOPEN',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8864,'MAIN_AGENDA_ACTIONAUTO_BOM_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8865,'MAIN_AGENDA_ACTIONAUTO_MRP_MO_VALIDATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8866,'MAIN_AGENDA_ACTIONAUTO_MRP_MO_PRODUCED',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8867,'MAIN_AGENDA_ACTIONAUTO_MRP_MO_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8868,'MAIN_AGENDA_ACTIONAUTO_MRP_MO_CANCEL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8869,'MAIN_AGENDA_ACTIONAUTO_RECRUITMENTJOBPOSITION_CREATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8870,'MAIN_AGENDA_ACTIONAUTO_RECRUITMENTJOBPOSITION_MODIFY',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8871,'MAIN_AGENDA_ACTIONAUTO_RECRUITMENTJOBPOSITION_SENTBYMAIL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8872,'MAIN_AGENDA_ACTIONAUTO_RECRUITMENTJOBPOSITION_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8873,'MAIN_AGENDA_ACTIONAUTO_RECRUITMENTCANDIDATURE_CREATE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8874,'MAIN_AGENDA_ACTIONAUTO_RECRUITMENTCANDIDATURE_MODIFY',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8875,'MAIN_AGENDA_ACTIONAUTO_RECRUITMENTCANDIDATURE_SENTBYMAIL',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8876,'MAIN_AGENDA_ACTIONAUTO_RECRUITMENTCANDIDATURE_DELETE',1,'1','chaine',0,'','2021-04-15 13:32:12'),(8877,'AGENDA_REMINDER_BROWSER',1,'1','chaine',0,'','2021-04-15 13:32:29'),(8878,'MAIN_MODULE_ACCOUNTING',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:45'),(8879,'MAIN_MODULE_AGENDA',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:45'),(8880,'MAIN_MODULE_BOM',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:46'),(8881,'MAIN_MODULE_BANQUE',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:46'),(8882,'MAIN_MODULE_BARCODE',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:46'),(8883,'MAIN_MODULE_CRON',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:46'),(8884,'MAIN_MODULE_COMMANDE',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:46'),(8885,'MAIN_MODULE_DON',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:46'),(8886,'MAIN_MODULE_ECM',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:46'),(8887,'MAIN_MODULE_EXPENSEREPORT',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:46'),(8888,'MAIN_MODULE_FACTURE',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:46'),(8889,'MAIN_MODULE_FOURNISSEUR',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:46'),(8890,'MAIN_MODULE_HOLIDAY',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:46'),(8891,'MAIN_MODULE_MARGIN',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:47'),(8894,'MAIN_MODULE_MRP',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:47'),(8895,'MAIN_MODULE_MRP_TRIGGERS',1,'0','chaine',0,NULL,'2021-07-11 17:49:47'),(8896,'MAIN_MODULE_MRP_LOGIN',1,'0','chaine',0,NULL,'2021-07-11 17:49:47'),(8897,'MAIN_MODULE_MRP_SUBSTITUTIONS',1,'0','chaine',0,NULL,'2021-07-11 17:49:47'),(8898,'MAIN_MODULE_MRP_MENUS',1,'0','chaine',0,NULL,'2021-07-11 17:49:47'),(8899,'MAIN_MODULE_MRP_TPL',1,'0','chaine',0,NULL,'2021-07-11 17:49:47'),(8900,'MAIN_MODULE_MRP_BARCODE',1,'0','chaine',0,NULL,'2021-07-11 17:49:47'),(8901,'MAIN_MODULE_MRP_MODELS',1,'0','chaine',0,NULL,'2021-07-11 17:49:47'),(8902,'MAIN_MODULE_MRP_THEME',1,'0','chaine',0,NULL,'2021-07-11 17:49:47'),(8903,'MAIN_MODULE_MRP_MODULEFOREXTERNAL',1,'0','chaine',0,NULL,'2021-07-11 17:49:47'),(8904,'MAIN_MODULE_OPENSURVEY',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:47'),(8905,'MAIN_MODULE_PRINTING',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:47'),(8906,'MAIN_MODULE_RECRUITMENT',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:47'),(8907,'MAIN_MODULE_RECRUITMENT_TRIGGERS',1,'0','chaine',0,NULL,'2021-07-11 17:49:47'),(8908,'MAIN_MODULE_RECRUITMENT_LOGIN',1,'0','chaine',0,NULL,'2021-07-11 17:49:47'),(8909,'MAIN_MODULE_RECRUITMENT_SUBSTITUTIONS',1,'0','chaine',0,NULL,'2021-07-11 17:49:47'),(8910,'MAIN_MODULE_RECRUITMENT_MENUS',1,'0','chaine',0,NULL,'2021-07-11 17:49:47'),(8911,'MAIN_MODULE_RECRUITMENT_TPL',1,'0','chaine',0,NULL,'2021-07-11 17:49:47'),(8912,'MAIN_MODULE_RECRUITMENT_BARCODE',1,'0','chaine',0,NULL,'2021-07-11 17:49:47'),(8913,'MAIN_MODULE_RECRUITMENT_MODELS',1,'1','chaine',0,NULL,'2021-07-11 17:49:47'),(8914,'MAIN_MODULE_RECRUITMENT_THEME',1,'0','chaine',0,NULL,'2021-07-11 17:49:47'),(8915,'MAIN_MODULE_RECRUITMENT_MODULEFOREXTERNAL',1,'0','chaine',0,NULL,'2021-07-11 17:49:47'),(8916,'MAIN_MODULE_RESOURCE',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:47'),(8917,'MAIN_MODULE_SALARIES',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:47'),(8918,'MAIN_MODULE_SERVICE',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:47'),(8919,'MAIN_MODULE_SYSLOG',0,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:47'),(8920,'MAIN_MODULE_SOCIETE',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:47'),(8921,'MAIN_MODULE_STRIPE',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:47'),(8922,'MAIN_MODULE_TICKET',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:47'),(8923,'MAIN_MODULE_TICKET_TABS_0',1,'thirdparty:+ticket:Tickets:@ticket:$user->rights->ticket->read:/ticket/list.php?socid=__ID__','chaine',0,NULL,'2021-07-11 17:49:47'),(8924,'MAIN_MODULE_TICKET_TABS_1',1,'project:+ticket:Tickets:@ticket:$user->rights->ticket->read:/ticket/list.php?projectid=__ID__','chaine',0,NULL,'2021-07-11 17:49:47'),(8925,'MAIN_MODULE_TICKET_TRIGGERS',1,'1','chaine',0,NULL,'2021-07-11 17:49:47'),(8926,'TAKEPOS_PRINT_METHOD',1,'browser','chaine',0,'','2021-07-11 17:49:47'),(8927,'MAIN_MODULE_TAKEPOS',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:48'),(8928,'MAIN_MODULE_TAKEPOS_TRIGGERS',1,'0','chaine',0,NULL,'2021-07-11 17:49:48'),(8929,'MAIN_MODULE_TAKEPOS_LOGIN',1,'0','chaine',0,NULL,'2021-07-11 17:49:48'),(8930,'MAIN_MODULE_TAKEPOS_SUBSTITUTIONS',1,'1','chaine',0,NULL,'2021-07-11 17:49:48'),(8931,'MAIN_MODULE_TAKEPOS_MENUS',1,'0','chaine',0,NULL,'2021-07-11 17:49:48'),(8932,'MAIN_MODULE_TAKEPOS_THEME',1,'0','chaine',0,NULL,'2021-07-11 17:49:48'),(8933,'MAIN_MODULE_TAKEPOS_TPL',1,'0','chaine',0,NULL,'2021-07-11 17:49:48'),(8934,'MAIN_MODULE_TAKEPOS_BARCODE',1,'0','chaine',0,NULL,'2021-07-11 17:49:48'),(8935,'MAIN_MODULE_TAKEPOS_MODELS',1,'0','chaine',0,NULL,'2021-07-11 17:49:48'),(8936,'MAIN_MODULE_USER',0,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:48'),(8937,'MAIN_MODULE_VARIANTS',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:48'),(8938,'MAIN_MODULE_WEBSITE',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\"}','2021-07-11 17:49:48'),(8939,'MAIN_VERSION_LAST_UPGRADE',0,'14.0.0','chaine',0,'Dolibarr version for last upgrade','2021-07-11 17:49:49'),(8941,'MAIN_FIRST_PING_OK_DATE',1,'20210711174950','chaine',0,'','2021-07-11 17:49:50'),(8942,'MAIN_FIRST_PING_OK_ID',1,'9646d6c55a34bca208868c98dac4678b','chaine',0,'','2021-07-11 17:49:50'); +INSERT INTO `llx_const` VALUES (8,'MAIN_UPLOAD_DOC',0,'2048','chaine',0,'Max size for file upload (0 means no upload allowed)','2012-07-08 11:17:57'),(9,'MAIN_SEARCHFORM_SOCIETE',0,'1','yesno',0,'Show form for quick company search','2012-07-08 11:17:57'),(10,'MAIN_SEARCHFORM_CONTACT',0,'1','yesno',0,'Show form for quick contact search','2012-07-08 11:17:57'),(11,'MAIN_SEARCHFORM_PRODUITSERVICE',0,'1','yesno',0,'Show form for quick product search','2012-07-08 11:17:58'),(12,'MAIN_SEARCHFORM_ADHERENT',0,'1','yesno',0,'Show form for quick member search','2012-07-08 11:17:58'),(16,'MAIN_SIZE_LISTE_LIMIT',0,'25','chaine',0,'Longueur maximum des listes','2012-07-08 11:17:58'),(29,'MAIN_DELAY_NOT_ACTIVATED_SERVICES',1,'0','chaine',0,'Tolérance de retard avant alerte (en jours) sur services à activer','2012-07-08 11:17:58'),(33,'SOCIETE_NOLIST_COURRIER',0,'1','yesno',0,'Liste les fichiers du repertoire courrier','2012-07-08 11:17:58'),(36,'ADHERENT_MAIL_REQUIRED',1,'1','yesno',0,'EMail required to create a new member','2012-07-08 11:17:58'),(37,'ADHERENT_MAIL_FROM',1,'adherents@domain.com','chaine',0,'Sender EMail for automatic emails','2012-07-08 11:17:58'),(38,'ADHERENT_MAIL_RESIL',1,'Your subscription has been resiliated.\r\nWe hope to see you soon again','html',0,'Mail resiliation','2018-11-23 11:56:07'),(39,'ADHERENT_MAIL_VALID',1,'Your subscription has been validated.\r\nThis is a remind of your personal information :\r\n\r\n%INFOS%\r\n\r\n','html',0,'Mail de validation','2018-11-23 11:56:07'),(40,'ADHERENT_MAIL_COTIS',1,'Hello %PRENOM%,\r\nThanks for your subscription.\r\nThis email confirms that your subscription has been received and processed.\r\n\r\n','html',0,'Mail de validation de cotisation','2018-11-23 11:56:07'),(41,'ADHERENT_MAIL_VALID_SUBJECT',1,'Your subscription has been validated','chaine',0,'Sujet du mail de validation','2012-07-08 11:17:59'),(42,'ADHERENT_MAIL_RESIL_SUBJECT',1,'Resiliating your subscription','chaine',0,'Sujet du mail de resiliation','2012-07-08 11:17:59'),(43,'ADHERENT_MAIL_COTIS_SUBJECT',1,'Receipt of your subscription','chaine',0,'Sujet du mail de validation de cotisation','2012-07-08 11:17:59'),(44,'MAILING_EMAIL_FROM',1,'dolibarr@domain.com','chaine',0,'EMail emmetteur pour les envois d emailings','2012-07-08 11:17:59'),(45,'ADHERENT_USE_MAILMAN',1,'0','yesno',0,'Utilisation de Mailman','2012-07-08 11:17:59'),(46,'ADHERENT_MAILMAN_UNSUB_URL',1,'http://lists.domain.com/cgi-bin/mailman/admin/%LISTE%/members?adminpw=%MAILMAN_ADMINPW%&user=%EMAIL%','chaine',0,'Url de desinscription aux listes mailman','2012-07-08 11:17:59'),(47,'ADHERENT_MAILMAN_URL',1,'http://lists.domain.com/cgi-bin/mailman/admin/%LISTE%/members?adminpw=%MAILMAN_ADMINPW%&send_welcome_msg_to_this_batch=1&subscribees=%EMAIL%','chaine',0,'Url pour les inscriptions mailman','2012-07-08 11:17:59'),(48,'ADHERENT_MAILMAN_LISTS',1,'test-test,test-test2','chaine',0,'Listes auxquelles inscrire les nouveaux adherents','2012-07-08 11:17:59'),(49,'ADHERENT_MAILMAN_ADMINPW',1,'','chaine',0,'Mot de passe Admin des liste mailman','2012-07-08 11:17:59'),(50,'ADHERENT_MAILMAN_SERVER',1,'lists.domain.com','chaine',0,'Serveur hebergeant les interfaces d Admin des listes mailman','2012-07-08 11:17:59'),(51,'ADHERENT_MAILMAN_LISTS_COTISANT',1,'','chaine',0,'Liste(s) auxquelles les nouveaux cotisants sont inscris automatiquement','2012-07-08 11:17:59'),(52,'ADHERENT_USE_SPIP',1,'0','yesno',0,'Utilisation de SPIP ?','2012-07-08 11:17:59'),(53,'ADHERENT_USE_SPIP_AUTO',1,'0','yesno',0,'Utilisation de SPIP automatiquement','2012-07-08 11:17:59'),(54,'ADHERENT_SPIP_USER',1,'user','chaine',0,'user spip','2012-07-08 11:17:59'),(55,'ADHERENT_SPIP_PASS',1,'pass','chaine',0,'Pass de connection','2012-07-08 11:17:59'),(56,'ADHERENT_SPIP_SERVEUR',1,'localhost','chaine',0,'serveur spip','2012-07-08 11:17:59'),(57,'ADHERENT_SPIP_DB',1,'spip','chaine',0,'db spip','2012-07-08 11:17:59'),(58,'ADHERENT_CARD_HEADER_TEXT',1,'%ANNEE%','chaine',0,'Texte imprime sur le haut de la carte adherent','2012-07-08 11:17:59'),(59,'ADHERENT_CARD_FOOTER_TEXT',1,'Association AZERTY','chaine',0,'Texte imprime sur le bas de la carte adherent','2012-07-08 11:17:59'),(61,'FCKEDITOR_ENABLE_USER',1,'1','yesno',0,'Activation fckeditor sur notes utilisateurs','2012-07-08 11:17:59'),(62,'FCKEDITOR_ENABLE_SOCIETE',1,'1','yesno',0,'Activation fckeditor sur notes societe','2012-07-08 11:17:59'),(63,'FCKEDITOR_ENABLE_PRODUCTDESC',1,'1','yesno',0,'Activation fckeditor sur notes produits','2012-07-08 11:17:59'),(64,'FCKEDITOR_ENABLE_MEMBER',1,'1','yesno',0,'Activation fckeditor sur notes adherent','2012-07-08 11:17:59'),(65,'FCKEDITOR_ENABLE_MAILING',1,'1','yesno',0,'Activation fckeditor sur emailing','2012-07-08 11:17:59'),(67,'DON_ADDON_MODEL',1,'html_cerfafr','chaine',0,'','2012-07-08 11:18:00'),(68,'PROPALE_ADDON',1,'mod_propale_marbre','chaine',0,'','2012-07-08 11:18:00'),(69,'PROPALE_ADDON_PDF',1,'azur','chaine',0,'','2012-07-08 11:18:00'),(70,'COMMANDE_ADDON',1,'mod_commande_marbre','chaine',0,'','2012-07-08 11:18:00'),(71,'COMMANDE_ADDON_PDF',1,'einstein','chaine',0,'','2012-07-08 11:18:00'),(72,'COMMANDE_SUPPLIER_ADDON',1,'mod_commande_fournisseur_muguet','chaine',0,'','2012-07-08 11:18:00'),(73,'COMMANDE_SUPPLIER_ADDON_PDF',1,'muscadet','chaine',0,'','2012-07-08 11:18:00'),(74,'EXPEDITION_ADDON',1,'enlevement','chaine',0,'','2012-07-08 11:18:00'),(76,'FICHEINTER_ADDON',1,'pacific','chaine',0,'','2012-07-08 11:18:00'),(77,'FICHEINTER_ADDON_PDF',1,'soleil','chaine',0,'','2012-07-08 11:18:00'),(79,'FACTURE_ADDON_PDF',1,'crabe','chaine',0,'','2012-07-08 11:18:00'),(80,'PROPALE_VALIDITY_DURATION',1,'15','chaine',0,'Durée de validitée des propales','2012-07-08 11:18:00'),(230,'COMPANY_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/thirdparties','chaine',0,NULL,'2012-07-08 11:26:20'),(238,'LIVRAISON_ADDON_PDF',1,'typhon','chaine',0,'Nom du gestionnaire de generation des commandes en PDF','2012-07-08 11:26:27'),(239,'DELIVERY_ADDON_NUMBER',1,'mod_delivery_jade','chaine',0,'Nom du gestionnaire de numerotation des bons de livraison','2020-12-10 12:24:40'),(245,'FACTURE_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/invoices','chaine',0,NULL,'2012-07-08 11:28:53'),(249,'DON_FORM',1,'html_cerfafr','chaine',0,'Nom du gestionnaire de formulaire de dons','2017-09-06 16:12:22'),(254,'ADHERENT_BANK_ACCOUNT',1,'','chaine',0,'ID du Compte banquaire utilise','2012-07-08 11:29:05'),(255,'ADHERENT_BANK_CATEGORIE',1,'','chaine',0,'ID de la categorie banquaire des cotisations','2012-07-08 11:29:05'),(256,'ADHERENT_ETIQUETTE_TYPE',1,'L7163','chaine',0,'Type d etiquette (pour impression de planche d etiquette)','2012-07-08 11:29:05'),(269,'PROJECT_ADDON_PDF',1,'baleine','chaine',0,'Nom du gestionnaire de generation des projets en PDF','2012-07-08 11:29:33'),(270,'PROJECT_ADDON',1,'mod_project_simple','chaine',0,'Nom du gestionnaire de numerotation des projets','2012-07-08 11:29:33'),(369,'EXPEDITION_ADDON_PDF',1,'merou','chaine',0,'','2012-07-08 22:58:07'),(377,'FACTURE_ADDON',1,'mod_facture_terre','chaine',0,'','2012-07-08 23:08:12'),(380,'ADHERENT_CARD_TEXT',1,'%TYPE% n° %ID%\r\n%PRENOM% %NOM%\r\n<%EMAIL%>\r\n%ADRESSE%\r\n%CP% %VILLE%\r\n%PAYS%','',0,'Texte imprime sur la carte adherent','2012-07-08 23:14:46'),(381,'ADHERENT_CARD_TEXT_RIGHT',1,'aaa','',0,'','2012-07-08 23:14:55'),(386,'STOCK_CALCULATE_ON_SHIPMENT',1,'1','chaine',0,'','2012-07-08 23:23:21'),(387,'STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER',1,'1','chaine',0,'','2012-07-08 23:23:26'),(392,'MAIN_AGENDA_XCAL_EXPORTKEY',1,'dolibarr','chaine',0,'','2012-07-08 23:27:50'),(393,'MAIN_AGENDA_EXPORT_PAST_DELAY',1,'100','chaine',0,'','2012-07-08 23:27:50'),(610,'CASHDESK_ID_THIRDPARTY',1,'7','chaine',0,'','2012-07-11 17:08:18'),(611,'CASHDESK_ID_BANKACCOUNT_CASH',1,'3','chaine',0,'','2012-07-11 17:08:18'),(612,'CASHDESK_ID_BANKACCOUNT_CHEQUE',1,'1','chaine',0,'','2012-07-11 17:08:18'),(613,'CASHDESK_ID_BANKACCOUNT_CB',1,'1','chaine',0,'','2012-07-11 17:08:18'),(614,'CASHDESK_ID_WAREHOUSE',1,'2','chaine',0,'','2012-07-11 17:08:18'),(660,'LDAP_USER_DN',1,'ou=users,dc=my-domain,dc=com','chaine',0,NULL,'2012-07-18 10:25:27'),(661,'LDAP_GROUP_DN',1,'ou=groups,dc=my-domain,dc=com','chaine',0,NULL,'2012-07-18 10:25:27'),(662,'LDAP_FILTER_CONNECTION',1,'&(objectClass=user)(objectCategory=person)','chaine',0,NULL,'2012-07-18 10:25:27'),(663,'LDAP_FIELD_LOGIN',1,'uid','chaine',0,NULL,'2012-07-18 10:25:27'),(664,'LDAP_FIELD_FULLNAME',1,'cn','chaine',0,NULL,'2012-07-18 10:25:27'),(665,'LDAP_FIELD_NAME',1,'sn','chaine',0,NULL,'2012-07-18 10:25:27'),(666,'LDAP_FIELD_FIRSTNAME',1,'givenname','chaine',0,NULL,'2012-07-18 10:25:27'),(667,'LDAP_FIELD_MAIL',1,'mail','chaine',0,NULL,'2012-07-18 10:25:27'),(668,'LDAP_FIELD_PHONE',1,'telephonenumber','chaine',0,NULL,'2012-07-18 10:25:27'),(669,'LDAP_FIELD_FAX',1,'facsimiletelephonenumber','chaine',0,NULL,'2012-07-18 10:25:27'),(670,'LDAP_FIELD_MOBILE',1,'mobile','chaine',0,NULL,'2012-07-18 10:25:27'),(671,'LDAP_SERVER_TYPE',1,'openldap','chaine',0,'','2012-07-18 10:25:46'),(672,'LDAP_SERVER_PROTOCOLVERSION',1,'3','chaine',0,'','2012-07-18 10:25:47'),(673,'LDAP_SERVER_HOST',1,'localhost','chaine',0,'','2012-07-18 10:25:47'),(674,'LDAP_SERVER_PORT',1,'389','chaine',0,'','2012-07-18 10:25:47'),(675,'LDAP_SERVER_USE_TLS',1,'0','chaine',0,'','2012-07-18 10:25:47'),(676,'LDAP_SYNCHRO_ACTIVE',1,'dolibarr2ldap','chaine',0,'','2012-07-18 10:25:47'),(677,'LDAP_CONTACT_ACTIVE',1,'1','chaine',0,'','2012-07-18 10:25:47'),(678,'LDAP_MEMBER_ACTIVE',1,'1','chaine',0,'','2012-07-18 10:25:47'),(974,'MAIN_MODULE_WORKFLOW_TRIGGERS',1,'1','chaine',0,NULL,'2013-07-18 18:02:20'),(975,'WORKFLOW_PROPAL_AUTOCREATE_ORDER',1,'1','chaine',0,'','2013-07-18 18:02:24'),(980,'PRELEVEMENT_NUMERO_NATIONAL_EMETTEUR',1,'1234567','chaine',0,'','2013-07-18 18:05:50'),(983,'FACTURE_RIB_NUMBER',1,'1','chaine',0,'','2013-07-18 18:35:14'),(984,'FACTURE_CHQ_NUMBER',1,'1','chaine',0,'','2013-07-18 18:35:14'),(1016,'GOOGLE_DUPLICATE_INTO_GCAL',1,'1','chaine',0,'','2013-07-18 21:40:20'),(1152,'SOCIETE_CODECLIENT_ADDON',1,'mod_codeclient_monkey','chaine',0,'','2013-07-29 20:50:02'),(1240,'MAIN_LOGEVENTS_USER_LOGIN',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1241,'MAIN_LOGEVENTS_USER_LOGIN_FAILED',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1242,'MAIN_LOGEVENTS_USER_LOGOUT',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1243,'MAIN_LOGEVENTS_USER_CREATE',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1244,'MAIN_LOGEVENTS_USER_MODIFY',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1245,'MAIN_LOGEVENTS_USER_NEW_PASSWORD',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1246,'MAIN_LOGEVENTS_USER_ENABLEDISABLE',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1247,'MAIN_LOGEVENTS_USER_DELETE',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1248,'MAIN_LOGEVENTS_GROUP_CREATE',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1249,'MAIN_LOGEVENTS_GROUP_MODIFY',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1250,'MAIN_LOGEVENTS_GROUP_DELETE',1,'1','chaine',0,'','2013-07-29 21:05:01'),(1251,'MAIN_BOXES_MAXLINES',1,'5','',0,'','2013-07-29 21:05:42'),(1482,'EXPEDITION_ADDON_NUMBER',1,'mod_expedition_safor','chaine',0,'Nom du gestionnaire de numerotation des expeditions','2013-08-05 17:53:11'),(1490,'CONTRACT_ADDON',1,'mod_contract_serpis','chaine',0,'Nom du gestionnaire de numerotation des contrats','2013-08-05 18:11:58'),(1677,'COMMANDE_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/orders','chaine',0,NULL,'2014-12-08 13:11:02'),(1724,'PROPALE_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/proposals','chaine',0,NULL,'2014-12-08 13:17:14'),(1730,'OPENSTREETMAP_ENABLE_MAPS',1,'1','chaine',0,'','2014-12-08 13:22:47'),(1731,'OPENSTREETMAP_ENABLE_MAPS_CONTACTS',1,'1','chaine',0,'','2014-12-08 13:22:47'),(1732,'OPENSTREETMAP_ENABLE_MAPS_MEMBERS',1,'1','chaine',0,'','2014-12-08 13:22:47'),(1733,'OPENSTREETMAP_MAPS_ZOOM_LEVEL',1,'15','chaine',0,'','2014-12-08 13:22:47'),(1742,'MAIN_MAIL_EMAIL_FROM',2,'dolibarr-robot@domain.com','chaine',0,'EMail emetteur pour les emails automatiques Dolibarr','2014-12-08 14:08:14'),(1743,'MAIN_MENU_STANDARD',2,'eldy_menu.php','chaine',0,'Module de gestion de la barre de menu du haut pour utilisateurs internes','2015-02-11 19:43:54'),(1744,'MAIN_MENUFRONT_STANDARD',2,'eldy_menu.php','chaine',0,'Module de gestion de la barre de menu du haut pour utilisateurs externes','2015-02-11 19:43:54'),(1745,'MAIN_MENU_SMARTPHONE',2,'iphone_backoffice.php','chaine',0,'Module de gestion de la barre de menu smartphone pour utilisateurs internes','2014-12-08 14:08:14'),(1746,'MAIN_MENUFRONT_SMARTPHONE',2,'iphone_frontoffice.php','chaine',0,'Module de gestion de la barre de menu smartphone pour utilisateurs externes','2014-12-08 14:08:14'),(1747,'MAIN_THEME',2,'eldy','chaine',0,'Default theme','2014-12-08 14:08:14'),(1748,'MAIN_DELAY_ACTIONS_TODO',2,'7','chaine',0,'Tolérance de retard avant alerte (en jours) sur actions planifiées non réalisées','2014-12-08 14:08:14'),(1749,'MAIN_DELAY_ORDERS_TO_PROCESS',2,'2','chaine',0,'Tolérance de retard avant alerte (en jours) sur commandes clients non traitées','2014-12-08 14:08:14'),(1750,'MAIN_DELAY_SUPPLIER_ORDERS_TO_PROCESS',2,'7','chaine',0,'Tolérance de retard avant alerte (en jours) sur commandes fournisseurs non traitées','2014-12-08 14:08:14'),(1751,'MAIN_DELAY_PROPALS_TO_CLOSE',2,'31','chaine',0,'Tolérance de retard avant alerte (en jours) sur propales à cloturer','2014-12-08 14:08:14'),(1752,'MAIN_DELAY_PROPALS_TO_BILL',2,'7','chaine',0,'Tolérance de retard avant alerte (en jours) sur propales non facturées','2014-12-08 14:08:14'),(1753,'MAIN_DELAY_CUSTOMER_BILLS_UNPAYED',2,'31','chaine',0,'Tolérance de retard avant alerte (en jours) sur factures client impayées','2014-12-08 14:08:14'),(1754,'MAIN_DELAY_SUPPLIER_BILLS_TO_PAY',2,'2','chaine',0,'Tolérance de retard avant alerte (en jours) sur factures fournisseur impayées','2014-12-08 14:08:14'),(1755,'MAIN_DELAY_NOT_ACTIVATED_SERVICES',2,'0','chaine',0,'Tolérance de retard avant alerte (en jours) sur services à activer','2014-12-08 14:08:14'),(1756,'MAIN_DELAY_RUNNING_SERVICES',2,'0','chaine',0,'Tolérance de retard avant alerte (en jours) sur services expirés','2014-12-08 14:08:14'),(1757,'MAIN_DELAY_MEMBERS',2,'31','chaine',0,'Tolérance de retard avant alerte (en jours) sur cotisations adhérent en retard','2014-12-08 14:08:14'),(1758,'MAIN_DELAY_TRANSACTIONS_TO_CONCILIATE',2,'62','chaine',0,'Tolérance de retard avant alerte (en jours) sur rapprochements bancaires à faire','2014-12-08 14:08:14'),(1759,'MAILING_EMAIL_FROM',2,'dolibarr@domain.com','chaine',0,'EMail emmetteur pour les envois d emailings','2014-12-08 14:08:14'),(1760,'MAIN_INFO_SOCIETE_COUNTRY',3,'1:FR:France','chaine',0,'','2015-02-26 21:56:28'),(1761,'MAIN_INFO_SOCIETE_NOM',3,'bbb','chaine',0,'','2014-12-08 14:08:20'),(1762,'MAIN_INFO_SOCIETE_STATE',3,'0','chaine',0,'','2015-02-27 14:20:27'),(1763,'MAIN_MONNAIE',3,'EUR','chaine',0,'','2014-12-08 14:08:20'),(1764,'MAIN_LANG_DEFAULT',3,'auto','chaine',0,'','2014-12-08 14:08:20'),(1765,'MAIN_MAIL_EMAIL_FROM',3,'dolibarr-robot@domain.com','chaine',0,'EMail emetteur pour les emails automatiques Dolibarr','2014-12-08 14:08:20'),(1766,'MAIN_MENU_STANDARD',3,'eldy_menu.php','chaine',0,'Module de gestion de la barre de menu du haut pour utilisateurs internes','2015-02-11 19:43:54'),(1767,'MAIN_MENUFRONT_STANDARD',3,'eldy_menu.php','chaine',0,'Module de gestion de la barre de menu du haut pour utilisateurs externes','2015-02-11 19:43:54'),(1768,'MAIN_MENU_SMARTPHONE',3,'iphone_backoffice.php','chaine',0,'Module de gestion de la barre de menu smartphone pour utilisateurs internes','2014-12-08 14:08:20'),(1769,'MAIN_MENUFRONT_SMARTPHONE',3,'iphone_frontoffice.php','chaine',0,'Module de gestion de la barre de menu smartphone pour utilisateurs externes','2014-12-08 14:08:20'),(1770,'MAIN_THEME',3,'eldy','chaine',0,'Default theme','2014-12-08 14:08:20'),(1771,'MAIN_DELAY_ACTIONS_TODO',3,'7','chaine',0,'Tolérance de retard avant alerte (en jours) sur actions planifiées non réalisées','2014-12-08 14:08:20'),(1772,'MAIN_DELAY_ORDERS_TO_PROCESS',3,'2','chaine',0,'Tolérance de retard avant alerte (en jours) sur commandes clients non traitées','2014-12-08 14:08:20'),(1773,'MAIN_DELAY_SUPPLIER_ORDERS_TO_PROCESS',3,'7','chaine',0,'Tolérance de retard avant alerte (en jours) sur commandes fournisseurs non traitées','2014-12-08 14:08:20'),(1774,'MAIN_DELAY_PROPALS_TO_CLOSE',3,'31','chaine',0,'Tolérance de retard avant alerte (en jours) sur propales à cloturer','2014-12-08 14:08:20'),(1775,'MAIN_DELAY_PROPALS_TO_BILL',3,'7','chaine',0,'Tolérance de retard avant alerte (en jours) sur propales non facturées','2014-12-08 14:08:20'),(1776,'MAIN_DELAY_CUSTOMER_BILLS_UNPAYED',3,'31','chaine',0,'Tolérance de retard avant alerte (en jours) sur factures client impayées','2014-12-08 14:08:20'),(1777,'MAIN_DELAY_SUPPLIER_BILLS_TO_PAY',3,'2','chaine',0,'Tolérance de retard avant alerte (en jours) sur factures fournisseur impayées','2014-12-08 14:08:20'),(1778,'MAIN_DELAY_NOT_ACTIVATED_SERVICES',3,'0','chaine',0,'Tolérance de retard avant alerte (en jours) sur services à activer','2014-12-08 14:08:20'),(1779,'MAIN_DELAY_RUNNING_SERVICES',3,'0','chaine',0,'Tolérance de retard avant alerte (en jours) sur services expirés','2014-12-08 14:08:20'),(1780,'MAIN_DELAY_MEMBERS',3,'31','chaine',0,'Tolérance de retard avant alerte (en jours) sur cotisations adhérent en retard','2014-12-08 14:08:20'),(1781,'MAIN_DELAY_TRANSACTIONS_TO_CONCILIATE',3,'62','chaine',0,'Tolérance de retard avant alerte (en jours) sur rapprochements bancaires à faire','2014-12-08 14:08:20'),(1782,'MAILING_EMAIL_FROM',3,'dolibarr@domain.com','chaine',0,'EMail emmetteur pour les envois d emailings','2014-12-08 14:08:20'),(1803,'SYSLOG_FILE',1,'DOL_DATA_ROOT/dolibarr.log','chaine',0,'','2014-12-08 14:15:08'),(1804,'SYSLOG_HANDLERS',1,'[\"mod_syslog_file\"]','chaine',0,'','2014-12-08 14:15:08'),(1805,'MAIN_MODULE_SKINCOLOREDITOR',3,'1',NULL,0,NULL,'2014-12-08 14:35:40'),(1922,'PAYPAL_API_SANDBOX',1,'1','chaine',0,'','2014-12-12 12:11:05'),(1923,'PAYPAL_API_USER',1,'seller_1355312017_biz_api1.mydomain.com','chaine',0,'','2014-12-12 12:11:05'),(1924,'PAYPAL_API_PASSWORD',1,'1355312040','chaine',0,'','2014-12-12 12:11:05'),(1925,'PAYPAL_API_SIGNATURE',1,'ABCDEFWBzvfn0q5iNmbuiDv1y.3EAXIMWyl4C5KvDReR9HDwwAd6dQ4Q','chaine',0,'','2014-12-12 12:11:05'),(1926,'PAYPAL_API_INTEGRAL_OR_PAYPALONLY',1,'integral','chaine',0,'','2014-12-12 12:11:05'),(1927,'PAYPAL_SECURITY_TOKEN',1,'50c82fab36bb3b6aa83e2a50691803b2','chaine',0,'','2014-12-12 12:11:05'),(1928,'PAYPAL_SECURITY_TOKEN_UNIQUE',1,'0','chaine',0,'','2014-12-12 12:11:05'),(1929,'PAYPAL_ADD_PAYMENT_URL',1,'1','chaine',0,'','2014-12-12 12:11:05'),(1980,'MAIN_PDF_FORMAT',1,'EUA4','chaine',0,'','2014-12-12 19:58:05'),(1981,'MAIN_PROFID1_IN_ADDRESS',1,'0','chaine',0,'','2014-12-12 19:58:05'),(1982,'MAIN_PROFID2_IN_ADDRESS',1,'0','chaine',0,'','2014-12-12 19:58:05'),(1983,'MAIN_PROFID3_IN_ADDRESS',1,'0','chaine',0,'','2014-12-12 19:58:05'),(1984,'MAIN_PROFID4_IN_ADDRESS',1,'0','chaine',0,'','2014-12-12 19:58:05'),(1985,'MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT',1,'0','chaine',0,'','2014-12-12 19:58:05'),(2835,'MAIN_USE_CONNECT_TIMEOUT',1,'10','chaine',0,'','2015-01-16 19:28:50'),(2836,'MAIN_USE_RESPONSE_TIMEOUT',1,'30','chaine',0,'','2015-01-16 19:28:50'),(2837,'MAIN_PROXY_USE',1,'0','chaine',0,'','2015-01-16 19:28:50'),(2838,'MAIN_PROXY_HOST',1,'localhost','chaine',0,'','2015-01-16 19:28:50'),(2839,'MAIN_PROXY_PORT',1,'8080','chaine',0,'','2015-01-16 19:28:50'),(2840,'MAIN_PROXY_USER',1,'aaa','chaine',0,'','2015-01-16 19:28:50'),(2841,'MAIN_PROXY_PASS',1,'bbb','chaine',0,'','2015-01-16 19:28:50'),(2848,'OVHSMS_NICK',1,'BN196-OVH','chaine',0,'','2015-01-16 19:32:36'),(2849,'OVHSMS_PASS',1,'bigone-10','chaine',0,'','2015-01-16 19:32:36'),(2850,'OVHSMS_SOAPURL',1,'https://www.ovh.com/soapi/soapi-re-1.55.wsdl','chaine',0,'','2015-01-16 19:32:36'),(2854,'THEME_ELDY_RGB',1,'bfbf00','chaine',0,'','2015-01-18 10:02:53'),(2855,'THEME_ELDY_ENABLE_PERSONALIZED',1,'0','chaine',0,'','2015-01-18 10:02:55'),(2858,'MAIN_SESSION_TIMEOUT',1,'2000','chaine',0,'','2015-01-19 17:01:53'),(2867,'FACSIM_ADDON',1,'mod_facsim_alcoy','chaine',0,'','2015-01-19 17:16:25'),(2868,'POS_SERVICES',1,'0','chaine',0,'','2015-01-19 17:16:51'),(2869,'POS_USE_TICKETS',1,'1','chaine',0,'','2015-01-19 17:16:51'),(2870,'POS_MAX_TTC',1,'100','chaine',0,'','2015-01-19 17:16:51'),(3190,'MAIN_MODULE_HOLIDAY',2,'1',NULL,0,NULL,'2015-02-01 08:52:34'),(3195,'INVOICE_SUPPLIER_ADDON_PDF',1,'canelle','chaine',0,'','2015-02-10 19:50:27'),(3199,'MAIN_FORCE_RELOAD_PAGE',1,'1','chaine',0,NULL,'2015-02-12 16:22:55'),(3223,'OVH_THIRDPARTY_IMPORT',1,'2','chaine',0,'','2015-02-13 16:20:18'),(3409,'AGENDA_USE_EVENT_TYPE',1,'1','chaine',0,'','2015-02-27 18:12:24'),(3886,'MAIN_REMOVE_INSTALL_WARNING',1,'1','chaine',1,'','2015-03-02 18:32:50'),(4013,'MAIN_DELAY_ACTIONS_TODO',1,'7','chaine',0,'','2015-03-06 08:59:12'),(4014,'MAIN_DELAY_PROPALS_TO_CLOSE',1,'31','chaine',0,'','2015-03-06 08:59:12'),(4015,'MAIN_DELAY_PROPALS_TO_BILL',1,'7','chaine',0,'','2015-03-06 08:59:12'),(4016,'MAIN_DELAY_ORDERS_TO_PROCESS',1,'2','chaine',0,'','2015-03-06 08:59:12'),(4017,'MAIN_DELAY_CUSTOMER_BILLS_UNPAYED',1,'31','chaine',0,'','2015-03-06 08:59:12'),(4018,'MAIN_DELAY_SUPPLIER_ORDERS_TO_PROCESS',1,'7','chaine',0,'','2015-03-06 08:59:12'),(4019,'MAIN_DELAY_SUPPLIER_BILLS_TO_PAY',1,'2','chaine',0,'','2015-03-06 08:59:12'),(4020,'MAIN_DELAY_RUNNING_SERVICES',1,'-15','chaine',0,'','2015-03-06 08:59:12'),(4021,'MAIN_DELAY_TRANSACTIONS_TO_CONCILIATE',1,'62','chaine',0,'','2015-03-06 08:59:13'),(4022,'MAIN_DELAY_MEMBERS',1,'31','chaine',0,'','2015-03-06 08:59:13'),(4023,'MAIN_DISABLE_METEO',1,'0','chaine',0,'','2015-03-06 08:59:13'),(4044,'ADHERENT_VAT_FOR_SUBSCRIPTIONS',1,'0','',0,'','2015-03-06 16:06:38'),(4047,'ADHERENT_BANK_USE',1,'bankviainvoice','',0,'','2015-03-06 16:12:30'),(4049,'PHPSANE_SCANIMAGE',1,'/usr/bin/scanimage','chaine',0,'','2015-03-06 21:54:13'),(4050,'PHPSANE_PNMTOJPEG',1,'/usr/bin/pnmtojpeg','chaine',0,'','2015-03-06 21:54:13'),(4051,'PHPSANE_PNMTOTIFF',1,'/usr/bin/pnmtotiff','chaine',0,'','2015-03-06 21:54:13'),(4052,'PHPSANE_OCR',1,'/usr/bin/gocr','chaine',0,'','2015-03-06 21:54:13'),(4548,'ECM_AUTO_TREE_ENABLED',1,'1','chaine',0,'','2015-03-10 15:57:21'),(4579,'MAIN_MODULE_AGENDA',2,'1',NULL,0,NULL,'2015-03-13 15:29:19'),(4580,'MAIN_AGENDA_ACTIONAUTO_COMPANY_CREATE',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4581,'MAIN_AGENDA_ACTIONAUTO_CONTRACT_VALIDATE',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4582,'MAIN_AGENDA_ACTIONAUTO_PROPAL_VALIDATE',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4583,'MAIN_AGENDA_ACTIONAUTO_PROPAL_SENTBYMAIL',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4584,'MAIN_AGENDA_ACTIONAUTO_ORDER_VALIDATE',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4585,'MAIN_AGENDA_ACTIONAUTO_ORDER_SENTBYMAIL',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4586,'MAIN_AGENDA_ACTIONAUTO_BILL_VALIDATE',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4587,'MAIN_AGENDA_ACTIONAUTO_BILL_PAYED',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4588,'MAIN_AGENDA_ACTIONAUTO_BILL_CANCEL',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4589,'MAIN_AGENDA_ACTIONAUTO_BILL_SENTBYMAIL',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4590,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_VALIDATE',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4591,'MAIN_AGENDA_ACTIONAUTO_BILL_SUPPLIER_VALIDATE',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4592,'MAIN_AGENDA_ACTIONAUTO_SHIPPING_VALIDATE',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4593,'MAIN_AGENDA_ACTIONAUTO_SHIPPING_SENTBYMAIL',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4594,'MAIN_AGENDA_ACTIONAUTO_BILL_UNVALIDATE',2,'1','chaine',0,NULL,'2015-03-13 15:29:19'),(4688,'GOOGLE_ENABLE_AGENDA',2,'1','chaine',0,'','2015-03-13 15:36:29'),(4689,'GOOGLE_AGENDA_NAME1',2,'eldy','chaine',0,'','2015-03-13 15:36:29'),(4690,'GOOGLE_AGENDA_SRC1',2,'eldy10@mail.com','chaine',0,'','2015-03-13 15:36:29'),(4691,'GOOGLE_AGENDA_COLOR1',2,'BE6D00','chaine',0,'','2015-03-13 15:36:29'),(4692,'GOOGLE_AGENDA_COLOR2',2,'7A367A','chaine',0,'','2015-03-13 15:36:29'),(4693,'GOOGLE_AGENDA_COLOR3',2,'7A367A','chaine',0,'','2015-03-13 15:36:29'),(4694,'GOOGLE_AGENDA_COLOR4',2,'7A367A','chaine',0,'','2015-03-13 15:36:29'),(4695,'GOOGLE_AGENDA_COLOR5',2,'7A367A','chaine',0,'','2015-03-13 15:36:29'),(4696,'GOOGLE_AGENDA_TIMEZONE',2,'Europe/Paris','chaine',0,'','2015-03-13 15:36:29'),(4697,'GOOGLE_AGENDA_NB',2,'5','chaine',0,'','2015-03-13 15:36:29'),(4725,'SOCIETE_CODECLIENT_ADDON',2,'mod_codeclient_leopard','chaine',0,'Module to control third parties codes','2015-03-13 20:21:35'),(4726,'SOCIETE_CODECOMPTA_ADDON',2,'mod_codecompta_panicum','chaine',0,'Module to control third parties codes','2015-03-13 20:21:35'),(4727,'SOCIETE_FISCAL_MONTH_START',2,'','chaine',0,'Mettre le numero du mois du debut d\\\'annee fiscale, ex: 9 pour septembre','2015-03-13 20:21:35'),(4728,'MAIN_SEARCHFORM_SOCIETE',2,'1','yesno',0,'Show form for quick company search','2015-03-13 20:21:35'),(4729,'MAIN_SEARCHFORM_CONTACT',2,'1','yesno',0,'Show form for quick contact search','2015-03-13 20:21:35'),(4730,'COMPANY_ADDON_PDF_ODT_PATH',2,'DOL_DATA_ROOT/doctemplates/thirdparties','chaine',0,NULL,'2015-03-13 20:21:35'),(4743,'MAIN_MODULE_CLICKTODIAL',2,'1',NULL,0,NULL,'2015-03-13 20:30:28'),(4744,'MAIN_MODULE_NOTIFICATION',2,'1',NULL,0,NULL,'2015-03-13 20:30:34'),(4745,'MAIN_MODULE_WEBSERVICES',2,'1',NULL,0,NULL,'2015-03-13 20:30:41'),(4746,'MAIN_MODULE_PROPALE',2,'1',NULL,0,NULL,'2015-03-13 20:32:38'),(4747,'PROPALE_ADDON_PDF',2,'azur','chaine',0,'Nom du gestionnaire de generation des propales en PDF','2015-03-13 20:32:38'),(4748,'PROPALE_ADDON',2,'mod_propale_marbre','chaine',0,'Nom du gestionnaire de numerotation des propales','2015-03-13 20:32:38'),(4749,'PROPALE_VALIDITY_DURATION',2,'15','chaine',0,'Duration of validity of business proposals','2015-03-13 20:32:38'),(4750,'PROPALE_ADDON_PDF_ODT_PATH',2,'DOL_DATA_ROOT/doctemplates/proposals','chaine',0,NULL,'2015-03-13 20:32:38'),(4752,'MAIN_MODULE_TAX',2,'1',NULL,0,NULL,'2015-03-13 20:32:47'),(4753,'MAIN_MODULE_DON',2,'1',NULL,0,NULL,'2015-03-13 20:32:54'),(4754,'DON_ADDON_MODEL',2,'html_cerfafr','chaine',0,'Nom du gestionnaire de generation de recu de dons','2015-03-13 20:32:54'),(4755,'POS_USE_TICKETS',2,'1','chaine',0,'','2015-03-13 20:33:09'),(4756,'POS_MAX_TTC',2,'100','chaine',0,'','2015-03-13 20:33:09'),(4757,'MAIN_MODULE_POS',2,'1',NULL,0,NULL,'2015-03-13 20:33:09'),(4758,'TICKET_ADDON',2,'mod_ticket_avenc','chaine',0,'Nom du gestionnaire de numerotation des tickets','2015-03-13 20:33:09'),(4759,'MAIN_MODULE_BANQUE',2,'1',NULL,0,NULL,'2015-03-13 20:33:09'),(4760,'MAIN_MODULE_FACTURE',2,'1',NULL,0,NULL,'2015-03-13 20:33:09'),(4761,'FACTURE_ADDON_PDF',2,'crabe','chaine',0,'Name of PDF model of invoice','2015-03-13 20:33:09'),(4762,'FACTURE_ADDON',2,'mod_facture_terre','chaine',0,'Name of numbering numerotation rules of invoice','2015-03-13 20:33:09'),(4763,'FACTURE_ADDON_PDF_ODT_PATH',2,'DOL_DATA_ROOT/doctemplates/invoices','chaine',0,NULL,'2015-03-13 20:33:09'),(4764,'MAIN_MODULE_SOCIETE',2,'1',NULL,0,NULL,'2015-03-13 20:33:09'),(4765,'MAIN_MODULE_PRODUCT',2,'1',NULL,0,NULL,'2015-03-13 20:33:09'),(4766,'PRODUCT_CODEPRODUCT_ADDON',2,'mod_codeproduct_leopard','chaine',0,'Module to control product codes','2015-03-13 20:33:09'),(4767,'MAIN_SEARCHFORM_PRODUITSERVICE',2,'1','yesno',0,'Show form for quick product search','2015-03-13 20:33:09'),(4772,'FACSIM_ADDON',2,'mod_facsim_alcoy','chaine',0,'','2015-03-13 20:33:32'),(4773,'MAIN_MODULE_MAILING',2,'1',NULL,0,NULL,'2015-03-13 20:33:37'),(4774,'MAIN_MODULE_OPENSURVEY',2,'1',NULL,0,NULL,'2015-03-13 20:33:42'),(4782,'AGENDA_USE_EVENT_TYPE',2,'1','chaine',0,'','2015-03-13 20:53:36'),(4884,'AGENDA_DISABLE_EXT',2,'1','chaine',0,'','2015-03-13 22:03:40'),(4928,'COMMANDE_SUPPLIER_ADDON_NUMBER',1,'mod_commande_fournisseur_muguet','chaine',0,'Nom du gestionnaire de numerotation des commandes fournisseur','2015-03-22 09:24:29'),(4929,'INVOICE_SUPPLIER_ADDON_NUMBER',1,'mod_facture_fournisseur_cactus','chaine',0,'Nom du gestionnaire de numerotation des factures fournisseur','2015-03-22 09:24:29'),(5001,'MAIN_CRON_KEY',0,'bc54582fe30d5d4a830c6f582ec28810','chaine',0,'','2015-03-23 17:54:53'),(5009,'CRON_KEY',0,'2c2e755c20be2014098f629865598006','chaine',0,'','2015-03-23 18:06:24'),(5139,'SOCIETE_ADD_REF_IN_LIST',1,'','yesno',0,'Display customer ref into select list','2015-09-08 23:06:08'),(5150,'PROJECT_TASK_ADDON_PDF',1,'','chaine',0,'Name of PDF/ODT tasks manager class','2015-09-08 23:06:14'),(5151,'PROJECT_TASK_ADDON',1,'mod_task_simple','chaine',0,'Name of Numbering Rule task manager class','2015-09-08 23:06:14'),(5152,'PROJECT_TASK_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/tasks','chaine',0,'','2015-09-08 23:06:14'),(5239,'BOOKMARKS_SHOW_IN_MENU',1,'10','chaine',0,'','2016-03-02 15:42:26'),(5271,'DONATION_ART200',1,'','yesno',0,'Option Française - Eligibilité Art200 du CGI','2016-12-21 12:51:28'),(5272,'DONATION_ART238',1,'','yesno',0,'Option Française - Eligibilité Art238 bis du CGI','2016-12-21 12:51:28'),(5274,'DONATION_MESSAGE',1,'Thank you','chaine',0,'Message affiché sur le récépissé de versements ou dons','2016-12-21 12:51:28'),(5349,'MAIN_SEARCHFORM_CONTACT',1,'1','chaine',0,'','2017-10-03 10:11:33'),(5351,'MAIN_SEARCHFORM_PRODUITSERVICE',1,'1','chaine',0,'','2017-10-03 10:11:33'),(5352,'MAIN_SEARCHFORM_PRODUITSERVICE_SUPPLIER',1,'0','chaine',0,'','2017-10-03 10:11:33'),(5353,'MAIN_SEARCHFORM_ADHERENT',1,'1','chaine',0,'','2017-10-03 10:11:33'),(5354,'MAIN_SEARCHFORM_PROJECT',1,'0','chaine',0,'','2017-10-03 10:11:33'),(5394,'FCKEDITOR_ENABLE_DETAILS',1,'1','yesno',0,'WYSIWIG for products details lines for all entities','2017-11-04 15:27:44'),(5395,'FCKEDITOR_ENABLE_USERSIGN',1,'1','yesno',0,'WYSIWIG for user signature','2017-11-04 15:27:44'),(5396,'FCKEDITOR_ENABLE_MAIL',1,'1','yesno',0,'WYSIWIG for products details lines for all entities','2017-11-04 15:27:44'),(5398,'CATEGORIE_RECURSIV_ADD',1,'','yesno',0,'Affect parent categories','2017-11-04 15:27:46'),(5404,'MAIN_MODULE_CATEGORIE',1,'1',NULL,0,NULL,'2017-11-04 15:41:43'),(5415,'EXPEDITION_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/shipment','chaine',0,NULL,'2017-11-15 22:38:28'),(5416,'LIVRAISON_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/delivery','chaine',0,NULL,'2017-11-15 22:38:28'),(5426,'MAIN_MODULE_PROJET',1,'1',NULL,0,NULL,'2017-11-15 22:38:44'),(5427,'PROJECT_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/projects','chaine',0,NULL,'2017-11-15 22:38:44'),(5428,'PROJECT_USE_OPPORTUNIES',1,'1','chaine',0,NULL,'2017-11-15 22:38:44'),(5430,'MAIN_MODULE_EXPORT',1,'1',NULL,0,NULL,'2017-11-15 22:38:56'),(5431,'MAIN_MODULE_IMPORT',1,'1',NULL,0,NULL,'2017-11-15 22:38:58'),(5432,'MAIN_MODULE_MAILING',1,'1',NULL,0,NULL,'2017-11-15 22:39:00'),(5434,'EXPENSEREPORT_ADDON_PDF',1,'standard','chaine',0,'Name of manager to build PDF expense reports documents','2017-11-15 22:39:05'),(5437,'SALARIES_ACCOUNTING_ACCOUNT_CHARGE',1,'641','chaine',0,NULL,'2017-11-15 22:39:08'),(5441,'ADHERENT_ETIQUETTE_TEXT',1,'%FULLNAME%\n%ADDRESS%\n%ZIP% %TOWN%\n%COUNTRY%','text',0,'Text to print on member address sheets','2018-11-23 11:56:07'),(5443,'MAIN_MODULE_PRELEVEMENT',1,'1',NULL,0,NULL,'2017-11-15 22:39:33'),(5453,'MAIN_MODULE_CONTRAT',1,'1',NULL,0,NULL,'2017-11-15 22:39:52'),(5455,'MAIN_MODULE_FICHEINTER',1,'1',NULL,0,NULL,'2017-11-15 22:39:56'),(5459,'MAIN_MODULE_PAYPAL',1,'1',NULL,0,NULL,'2017-11-15 22:41:02'),(5463,'MAIN_MODULE_PROPALE',1,'1',NULL,0,NULL,'2017-11-15 22:41:47'),(5483,'GENBARCODE_BARCODETYPE_THIRDPARTY',1,'6','chaine',0,'','2018-01-16 15:49:43'),(5484,'PRODUIT_DEFAULT_BARCODE_TYPE',1,'2','chaine',0,'','2018-01-16 15:49:46'),(5586,'MAIN_DELAY_EXPENSEREPORTS_TO_PAY',1,'31','chaine',0,'Tolérance de retard avant alerte (en jours) sur les notes de frais impayées','2018-01-22 17:28:18'),(5587,'MAIN_FIX_FOR_BUGGED_MTA',1,'1','chaine',1,'Set constant to fix email ending from PHP with some linux ike system','2018-01-22 17:28:18'),(5590,'MAIN_VERSION_LAST_INSTALL',0,'3.8.3','chaine',0,'Dolibarr version when install','2018-01-22 17:28:42'),(5604,'MAIN_INFO_SOCIETE_LOGO',1,'mybigcompany.png','chaine',0,'','2018-01-22 17:33:49'),(5605,'MAIN_INFO_SOCIETE_LOGO_SMALL',1,'mybigcompany_small.png','chaine',0,'','2018-01-22 17:33:49'),(5606,'MAIN_INFO_SOCIETE_LOGO_MINI',1,'mybigcompany_mini.png','chaine',0,'','2018-01-22 17:33:49'),(5614,'MAIN_SIZE_SHORTLISTE_LIMIT',1,'4','chaine',0,'Longueur maximum des listes courtes (fiche client)','2018-03-13 10:54:46'),(5627,'SUPPLIER_PROPOSAL_ADDON_PDF',1,'aurore','chaine',0,'Name of submodule to generate PDF for supplier quotation request','2018-07-30 11:13:20'),(5628,'SUPPLIER_PROPOSAL_ADDON',1,'mod_supplier_proposal_marbre','chaine',0,'Name of submodule to number supplier quotation request','2018-07-30 11:13:20'),(5629,'SUPPLIER_PROPOSAL_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/supplier_proposal','chaine',0,NULL,'2018-07-30 11:13:20'),(5633,'MAIN_MODULE_API',1,'1',NULL,0,NULL,'2018-07-30 11:13:54'),(5634,'MAIN_MODULE_WEBSERVICES',1,'1',NULL,0,NULL,'2018-07-30 11:13:56'),(5635,'WEBSERVICES_KEY',1,'dolibarrkey','chaine',0,'','2018-07-30 11:14:04'),(5638,'MAIN_MODULE_EXTERNALRSS',1,'1',NULL,0,NULL,'2018-07-30 11:15:04'),(5642,'SOCIETE_CODECOMPTA_ADDON',1,'mod_codecompta_aquarium','chaine',0,'','2018-07-30 11:16:42'),(5707,'CASHDESK_NO_DECREASE_STOCK',1,'1','chaine',0,'','2018-07-30 13:38:11'),(5708,'MAIN_MODULE_PRODUCTBATCH',1,'1',NULL,0,NULL,'2018-07-30 13:38:11'),(5710,'MAIN_MODULE_STOCK',1,'1',NULL,0,NULL,'2018-07-30 13:38:11'),(5711,'MAIN_MODULE_PRODUCT',1,'1',NULL,0,NULL,'2018-07-30 13:38:11'),(5808,'MARGIN_TYPE',1,'costprice','chaine',0,'','2018-07-30 16:32:18'),(5809,'DISPLAY_MARGIN_RATES',1,'1','chaine',0,'','2018-07-30 16:32:20'),(5833,'ACCOUNTING_EXPORT_SEPARATORCSV',1,',','string',0,NULL,'2017-01-29 15:11:56'),(5840,'CHARTOFACCOUNTS',1,'2','chaine',0,NULL,'2017-01-29 15:11:56'),(5841,'ACCOUNTING_EXPORT_MODELCSV',1,'1','chaine',0,NULL,'2017-01-29 15:11:56'),(5842,'ACCOUNTING_LENGTH_GACCOUNT',1,'','chaine',0,NULL,'2017-01-29 15:11:56'),(5843,'ACCOUNTING_LENGTH_AACCOUNT',1,'','chaine',0,NULL,'2017-01-29 15:11:56'),(5844,'ACCOUNTING_LIST_SORT_VENTILATION_TODO',1,'1','yesno',0,NULL,'2017-01-29 15:11:56'),(5845,'ACCOUNTING_LIST_SORT_VENTILATION_DONE',1,'1','yesno',0,NULL,'2017-01-29 15:11:56'),(5846,'ACCOUNTING_EXPORT_DATE',1,'%d%m%Y','chaine',0,NULL,'2017-01-29 15:11:56'),(5848,'ACCOUNTING_EXPORT_FORMAT',1,'csv','chaine',0,NULL,'2017-01-29 15:11:56'),(5853,'MAIN_MODULE_WORKFLOW',1,'1',NULL,0,NULL,'2017-01-29 15:12:12'),(5854,'MAIN_MODULE_NOTIFICATION',1,'1',NULL,0,NULL,'2017-01-29 15:12:35'),(5855,'MAIN_MODULE_OAUTH',1,'1',NULL,0,NULL,'2017-01-29 15:12:41'),(5883,'MAILING_LIMIT_SENDBYWEB',0,'15','chaine',1,'Number of targets to defined packet size when sending mass email','2017-01-29 17:36:33'),(5884,'MAIN_MAIL_DEBUG',1,'0','chaine',1,'','2017-01-29 18:53:02'),(5885,'MAIN_SOAP_DEBUG',1,'0','chaine',1,'','2017-01-29 18:53:02'),(5925,'MAIN_AGENDA_ACTIONAUTO_MEMBER_SUBSCRIPTION',1,'1','chaine',0,'','2017-02-01 14:48:55'),(5931,'DATABASE_PWD_ENCRYPTED',1,'1','chaine',0,'','2017-02-01 15:06:04'),(5932,'MAIN_DISABLE_ALL_MAILS',1,'0','chaine',0,'','2017-02-01 15:09:09'),(5933,'MAIN_MAIL_SENDMODE',1,'mail','chaine',0,'','2017-02-01 15:09:09'),(5934,'MAIN_MAIL_SMTP_PORT',1,'465','chaine',0,'','2017-02-01 15:09:09'),(5935,'MAIN_MAIL_SMTP_SERVER',1,'smtp.mail.com','chaine',0,'','2017-02-01 15:09:09'),(5936,'MAIN_MAIL_SMTPS_ID',1,'eldy10@mail.com','chaine',0,'','2017-02-01 15:09:09'),(5937,'MAIN_MAIL_SMTPS_PW',1,'bidonge','chaine',0,'','2017-02-01 15:09:09'),(5938,'MAIN_MAIL_EMAIL_FROM',1,'robot@example.com','chaine',0,'','2017-02-01 15:09:09'),(5939,'MAIN_MAIL_DEFAULT_FROMTYPE',1,'user','chaine',0,'','2017-02-01 15:09:09'),(5940,'PRELEVEMENT_ID_BANKACCOUNT',1,'1','chaine',0,'','2017-02-06 04:04:47'),(5941,'PRELEVEMENT_ICS',1,'ICS123456','chaine',0,'','2017-02-06 04:04:47'),(5942,'PRELEVEMENT_USER',1,'1','chaine',0,'','2017-02-06 04:04:47'),(5943,'BANKADDON_PDF',1,'sepamandate','chaine',0,'','2017-02-06 04:13:52'),(5947,'CHEQUERECEIPTS_THYME_MASK',1,'CHK{yy}{mm}-{0000@1}','chaine',0,'','2017-02-06 04:16:27'),(5948,'MAIN_MODULE_LOAN',1,'1',NULL,0,NULL,'2017-02-06 19:19:05'),(5954,'MAIN_SUBMODULE_EXPEDITION',1,'1','chaine',0,'','2017-02-06 23:57:37'),(5964,'MAIN_MODULE_TAX',1,'1',NULL,0,NULL,'2017-02-07 18:56:12'),(6019,'MAIN_INFO_SOCIETE_COUNTRY',2,'1:FR:France','chaine',0,'','2017-02-15 17:18:22'),(6020,'MAIN_INFO_SOCIETE_NOM',2,'MySecondCompany','chaine',0,'','2017-02-15 17:18:22'),(6021,'MAIN_INFO_SOCIETE_STATE',2,'0','chaine',0,'','2017-02-15 17:18:22'),(6022,'MAIN_MONNAIE',2,'EUR','chaine',0,'','2017-02-15 17:18:22'),(6023,'MAIN_LANG_DEFAULT',2,'auto','chaine',0,'','2017-02-15 17:18:22'),(6032,'MAIN_MODULE_MULTICURRENCY',1,'1',NULL,0,NULL,'2017-02-15 17:29:59'),(6048,'SYSLOG_FACILITY',0,'LOG_USER','chaine',0,'','2017-02-15 22:37:01'),(6049,'SYSLOG_FIREPHP_INCLUDEPATH',0,'/home/ldestailleur/git/dolibarr_5.0/htdocs/includes/firephp/firephp-core/lib/','chaine',0,'','2017-02-15 22:37:01'),(6050,'SYSLOG_FILE',0,'DOL_DATA_ROOT/dolibarr.log','chaine',0,'','2017-02-15 22:37:01'),(6051,'SYSLOG_CHROMEPHP_INCLUDEPATH',0,'/home/ldestailleur/git/dolibarr_5.0/htdocs/includes/ccampbell/chromephp/','chaine',0,'','2017-02-15 22:37:01'),(6052,'SYSLOG_HANDLERS',0,'[\"mod_syslog_file\"]','chaine',0,'','2017-02-15 22:37:01'),(6092,'MAIN_SIZE_SHORTLIST_LIMIT',0,'3','chaine',0,'Max length for small lists (tabs)','2017-05-12 09:02:38'),(6099,'MAIN_MODULE_SKYPE',1,'1',NULL,0,NULL,'2017-05-12 09:03:51'),(6100,'MAIN_MODULE_GRAVATAR',1,'1',NULL,0,NULL,'2017-05-12 09:03:54'),(6102,'PRODUCT_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/products','chaine',0,'','2017-08-27 13:29:07'),(6103,'CONTRACT_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/contracts','chaine',0,'','2017-08-27 13:29:07'),(6104,'USERGROUP_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/usergroups','chaine',0,'','2017-08-27 13:29:07'),(6105,'USER_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/users','chaine',0,'','2017-08-27 13:29:07'),(6106,'MAIN_ENABLE_OVERWRITE_TRANSLATION',1,'1','chaine',0,'Enable overwrote of translation','2017-08-27 13:29:07'),(6377,'COMMANDE_SAPHIR_MASK',1,'{yy}{mm}{000}{ttt}','chaine',0,'','2017-09-06 07:56:25'),(6518,'GOOGLE_DUPLICATE_INTO_THIRDPARTIES',1,'1','chaine',0,'','2017-09-06 19:43:57'),(6519,'GOOGLE_DUPLICATE_INTO_CONTACTS',1,'0','chaine',0,'','2017-09-06 19:43:57'),(6520,'GOOGLE_TAG_PREFIX',1,'Dolibarr (Thirdparties)','chaine',0,'','2017-09-06 19:43:57'),(6521,'GOOGLE_TAG_PREFIX_CONTACTS',1,'Dolibarr (Contacts/Addresses)','chaine',0,'','2017-09-06 19:43:57'),(6522,'GOOGLE_ENABLE_AGENDA',1,'1','chaine',0,'','2017-09-06 19:44:12'),(6523,'GOOGLE_AGENDA_COLOR1',1,'1B887A','chaine',0,'','2017-09-06 19:44:12'),(6524,'GOOGLE_AGENDA_COLOR2',1,'7A367A','chaine',0,'','2017-09-06 19:44:12'),(6525,'GOOGLE_AGENDA_COLOR3',1,'7A367A','chaine',0,'','2017-09-06 19:44:12'),(6526,'GOOGLE_AGENDA_COLOR4',1,'7A367A','chaine',0,'','2017-09-06 19:44:12'),(6527,'GOOGLE_AGENDA_COLOR5',1,'7A367A','chaine',0,'','2017-09-06 19:44:12'),(6528,'GOOGLE_AGENDA_TIMEZONE',1,'Europe/Paris','chaine',0,'','2017-09-06 19:44:12'),(6529,'GOOGLE_AGENDA_NB',1,'5','chaine',0,'','2017-09-06 19:44:12'),(6543,'MAIN_SMS_DEBUG',0,'1','chaine',1,'This is to enable OVH SMS debug','2017-09-06 19:44:34'),(6562,'BLOCKEDLOG_ENTITY_FINGERPRINT',1,'b63e359ffca54d5c2bab869916eaf23d4a736703028ccbf77ce1167c5f830e7b','chaine',0,'Numeric Unique Fingerprint','2018-01-19 11:27:15'),(6564,'BLOCKEDLOG_DISABLE_NOT_ALLOWED_FOR_COUNTRY',1,'FR','chaine',0,'This is list of country code where the module may be mandatory','2018-01-19 11:27:15'),(6565,'MAIN_MODULE_BOOKMARK',1,'1',NULL,0,'{\"authorid\":\"12\",\"ip\":\"82.240.38.230\"}','2018-01-19 11:27:34'),(6566,'MAIN_MODULE_ADHERENT',1,'1',NULL,0,'{\"authorid\":\"12\",\"ip\":\"82.240.38.230\"}','2018-01-19 11:27:56'),(6567,'ADHERENT_ADDON_PDF',1,'standard','chaine',0,'Name of PDF model of member','2018-01-19 11:27:56'),(6636,'MAIN_MODULE_TICKET_MODELS',1,'1','chaine',0,NULL,'2019-06-05 09:15:29'),(6647,'MAIN_MODULE_SOCIALNETWORKS',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2019-06-05 09:16:49'),(6795,'TICKET_ADDON',1,'mod_ticket_simple','chaine',0,'','2019-09-26 12:07:59'),(6796,'PRODUCT_CODEPRODUCT_ADDON',1,'mod_codeproduct_elephant','chaine',0,'','2019-09-26 12:59:00'),(6800,'CASHDESK_ID_THIRDPARTY1',1,'7','chaine',0,'','2019-09-26 15:30:09'),(6801,'CASHDESK_ID_BANKACCOUNT_CASH1',1,'3','chaine',0,'','2019-09-26 15:30:09'),(6802,'CASHDESK_ID_BANKACCOUNT_CHEQUE1',1,'4','chaine',0,'','2019-09-26 15:30:09'),(6803,'CASHDESK_ID_BANKACCOUNT_CB1',1,'4','chaine',0,'','2019-09-26 15:30:09'),(6804,'CASHDESK_ID_BANKACCOUNT_PRE1',1,'4','chaine',0,'','2019-09-26 15:30:09'),(6805,'CASHDESK_ID_BANKACCOUNT_VIR1',1,'1','chaine',0,'','2019-09-26 15:30:09'),(6806,'CASHDESK_NO_DECREASE_STOCK1',1,'1','chaine',0,'','2019-09-26 15:30:09'),(6811,'FORCEPROJECT_ON_PROPOSAL',1,'1','chaine',0,'','2019-09-27 14:52:57'),(6813,'PROJECT_USE_OPPORTUNITIES',1,'1','chaine',0,'','2019-10-01 11:48:09'),(6814,'PACKTHEMEACTIVATEDTHEME',0,'modOwnTheme','chaine',0,'','2019-10-02 11:41:58'),(6815,'OWNTHEME_COL1',0,'#6a89cc','chaine',0,'','2019-10-02 11:41:58'),(6816,'OWNTHEME_COL2',0,'#60a3bc','chaine',0,'','2019-10-02 11:41:58'),(6817,'DOL_VERSION',0,'10.0.2','chaine',0,'Dolibarr version','2019-10-02 11:41:58'),(6823,'OWNTHEME_COL_BODY_BCKGRD',0,'#E9E9E9','chaine',0,'','2019-10-02 11:41:58'),(6824,'OWNTHEME_COL_LOGO_BCKGRD',0,'#474c80','chaine',0,'','2019-10-02 11:41:58'),(6825,'OWNTHEME_COL_TXT_MENU',0,'#b8c6e5','chaine',0,'','2019-10-02 11:41:58'),(6826,'OWNTHEME_COL_HEADER_BCKGRD',0,'#474c80','chaine',0,'','2019-10-02 11:41:58'),(6827,'OWNTHEME_CUSTOM_CSS',0,'0','yesno',0,'','2019-10-02 11:41:58'),(6828,'OWNTHEME_CUSTOM_JS',0,'0','yesno',0,'','2019-10-02 11:41:58'),(6829,'OWNTHEME_FIXED_MENU',0,'0','yesno',0,'','2019-10-02 11:41:58'),(6830,'OWNTHEME_D_HEADER_FONT_SIZE',0,'1.7rem','chaine',0,'','2019-10-02 11:41:58'),(6831,'OWNTHEME_S_HEADER_FONT_SIZE',0,'1.6rem','chaine',0,'','2019-10-02 11:41:58'),(6832,'OWNTHEME_D_VMENU_FONT_SIZE',0,'1.2rem','chaine',0,'','2019-10-02 11:41:58'),(6833,'OWNTHEME_S_VMENU_FONT_SIZE',0,'1.2rem','chaine',0,'','2019-10-02 11:41:58'),(6844,'MAIN_THEME',0,'eldy','chaine',0,'','2019-10-02 11:46:02'),(6845,'MAIN_MENU_STANDARD',0,'eldy_menu.php','chaine',0,'','2019-10-02 11:46:02'),(6846,'MAIN_MENUFRONT_STANDARD',0,'eldy_menu.php','chaine',0,'','2019-10-02 11:46:02'),(6847,'MAIN_MENU_SMARTPHONE',0,'eldy_menu.php','chaine',0,'','2019-10-02 11:46:02'),(6848,'MAIN_MENUFRONT_SMARTPHONE',0,'eldy_menu.php','chaine',0,'','2019-10-02 11:46:02'),(6851,'BECREATIVE_COL1',1,'#1e88e5','chaine',0,'','2019-10-02 11:47:10'),(6852,'BECREATIVE_COL2',1,'#1e88e5','chaine',0,'','2019-10-02 11:47:10'),(6853,'DOL_VERSION',1,'10.0.2','chaine',0,'Dolibarr version','2019-10-02 11:47:10'),(6859,'BECREATIVE_COL_BODY_BCKGRD',1,'#e6eaef','chaine',0,'','2019-10-02 11:47:10'),(6860,'BECREATIVE_COL_LOGO_BCKGRD',1,'#1e88e5','chaine',0,'','2019-10-02 11:47:10'),(6861,'BECREATIVE_COL_TXT_MENU',1,'#b8c6e5','chaine',0,'','2019-10-02 11:47:10'),(6862,'BECREATIVE_COL_HEADER_BCKGRD',1,'#26a69a','chaine',0,'','2019-10-02 11:47:10'),(6863,'BECREATIVE_CUSTOM_CSS',1,'0','yesno',0,'','2019-10-02 11:47:10'),(6864,'BECREATIVE_CUSTOM_JS',1,'0','yesno',0,'','2019-10-02 11:47:10'),(6865,'BECREATIVE_FIXED_MENU',1,'0','yesno',0,'','2019-10-02 11:47:10'),(6866,'BECREATIVE_D_HEADER_FONT_SIZE',1,'1.7rem','chaine',0,'','2019-10-02 11:47:10'),(6867,'BECREATIVE_S_HEADER_FONT_SIZE',1,'1.6rem','chaine',0,'','2019-10-02 11:47:10'),(6868,'BECREATIVE_D_VMENU_FONT_SIZE',1,'1.2rem','chaine',0,'','2019-10-02 11:47:10'),(6869,'BECREATIVE_S_VMENU_FONT_SIZE',1,'1.2rem','chaine',0,'','2019-10-02 11:47:10'),(6881,'MAIN_MENU_STANDARD',1,'eldy_menu.php','chaine',0,'','2019-10-02 11:48:49'),(6882,'MAIN_MENUFRONT_STANDARD',1,'eldy_menu.php','chaine',0,'','2019-10-02 11:48:49'),(6883,'MAIN_MENU_SMARTPHONE',1,'eldy_menu.php','chaine',0,'','2019-10-02 11:48:49'),(6884,'MAIN_MENUFRONT_SMARTPHONE',1,'eldy_menu.php','chaine',0,'','2019-10-02 11:48:49'),(6885,'ACCOUNTING_ACCOUNT_CUSTOMER',1,'411','chaine',0,'','2019-10-04 08:15:44'),(6886,'ACCOUNTING_ACCOUNT_SUPPLIER',1,'401','chaine',0,'','2019-10-04 08:15:44'),(6887,'SALARIES_ACCOUNTING_ACCOUNT_PAYMENT',1,'421','chaine',0,'','2019-10-04 08:15:44'),(6888,'ACCOUNTING_PRODUCT_BUY_ACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6889,'ACCOUNTING_PRODUCT_SOLD_ACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6890,'ACCOUNTING_PRODUCT_SOLD_INTRA_ACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6891,'ACCOUNTING_PRODUCT_SOLD_EXPORT_ACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6892,'ACCOUNTING_SERVICE_BUY_ACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6893,'ACCOUNTING_SERVICE_SOLD_ACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6894,'ACCOUNTING_VAT_BUY_ACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6895,'ACCOUNTING_VAT_SOLD_ACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6896,'ACCOUNTING_VAT_PAY_ACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6897,'ACCOUNTING_ACCOUNT_SUSPENSE',1,'471','chaine',0,'','2019-10-04 08:15:44'),(6898,'ACCOUNTING_ACCOUNT_TRANSFER_CASH',1,'58','chaine',0,'','2019-10-04 08:15:44'),(6899,'DONATION_ACCOUNTINGACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6900,'ADHERENT_SUBSCRIPTION_ACCOUNTINGACCOUNT',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6901,'LOAN_ACCOUNTING_ACCOUNT_CAPITAL',1,'164','chaine',0,'','2019-10-04 08:15:44'),(6902,'LOAN_ACCOUNTING_ACCOUNT_INTEREST',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6903,'LOAN_ACCOUNTING_ACCOUNT_INSURANCE',1,'-1','chaine',0,'','2019-10-04 08:15:44'),(6912,'TICKET_ENABLE_PUBLIC_INTERFACE',1,'1','chaine',0,'','2019-10-04 11:44:33'),(6934,'TICKET_NOTIFICATION_EMAIL_FROM',1,'fff','chaine',0,'','2019-10-04 12:03:51'),(6935,'TICKET_NOTIFICATION_EMAIL_TO',1,'ff','chaine',0,'','2019-10-04 12:03:51'),(6936,'TICKET_MESSAGE_MAIL_INTRO',1,'Hello,
\r\nA new response was sent on a ticket that you contact. Here is the message:\"\"','chaine',0,'','2019-10-04 12:03:51'),(6937,'TICKET_MESSAGE_MAIL_SIGNATURE',1,'

Sincerely,

\r\n\r\n

--\"\"

\r\n','chaine',0,'','2019-10-04 12:03:51'),(7027,'USER_PASSWORD_GENERATED',1,'Perso','chaine',0,'','2019-10-07 10:52:46'),(7028,'USER_PASSWORD_PATTERN',1,'12;1;0;1;0;1','chaine',0,'','2019-10-07 10:57:03'),(7034,'BOM_ADDON',1,'mod_bom_standard','chaine',0,'Name of numbering rules of BOM','2019-10-08 18:49:41'),(7035,'BOM_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/boms','chaine',0,NULL,'2019-10-08 18:49:41'),(7036,'MAIN_MODULE_GEOIPMAXMIND',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2019-10-08 18:51:54'),(7037,'MAIN_MODULE_DAV',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2019-10-08 18:54:07'),(7122,'BOM_ADDON_PDF',1,'generic_bom_odt','chaine',0,'','2019-11-28 14:00:58'),(7195,'MAIN_AGENDA_ACTIONAUTO_MO_VALIDATE',1,'1','chaine',0,'','2019-11-29 08:44:37'),(7196,'MAIN_AGENDA_ACTIONAUTO_MO_PRODUCED',1,'1','chaine',0,'','2019-11-29 08:44:37'),(7197,'MAIN_AGENDA_ACTIONAUTO_MO_DELETE',1,'1','chaine',0,'','2019-11-29 08:44:37'),(7198,'MAIN_AGENDA_ACTIONAUTO_MO_CANCEL',1,'1','chaine',0,'','2019-11-29 08:44:37'),(7201,'TICKET_PUBLIC_INTERFACE_TOPIC',1,'MyBigCompany public interface for Ticket','chaine',0,'','2019-11-29 08:49:36'),(7202,'TICKET_PUBLIC_TEXT_HOME',1,'You can create a support ticket or view existing from its identifier tracking ticket.','chaine',0,'','2019-11-29 08:49:36'),(7203,'TICKET_PUBLIC_TEXT_HELP_MESSAGE',1,'Please accurately describe the problem. Provide the most information possible to allow us to correctly identify your request.','chaine',0,'','2019-11-29 08:49:36'),(7204,'TICKET_MESSAGE_MAIL_NEW',1,'TicketMessageMailNewText','chaine',0,'','2019-11-29 08:49:36'),(7220,'MRP_MO_ADDON',1,'mod_mo_standard','chaine',0,'Name of numbering rules of MO','2019-11-29 08:57:42'),(7221,'MRP_MO_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/mrps','chaine',0,NULL,'2019-11-29 08:57:42'),(7222,'MRP_MO_ADDON_PDF',1,'generic_mo_odt','chaine',0,'','2019-11-29 08:57:47'),(7254,'MAIN_INFO_OPENINGHOURS_MONDAY',1,'8-12 13-18','chaine',0,'','2019-12-19 11:14:21'),(7255,'MAIN_INFO_OPENINGHOURS_TUESDAY',1,'8-12 13-18','chaine',0,'','2019-12-19 11:14:21'),(7256,'MAIN_INFO_OPENINGHOURS_WEDNESDAY',1,'8-13','chaine',0,'','2019-12-19 11:14:21'),(7257,'MAIN_INFO_OPENINGHOURS_THURSDAY',1,'8-12 13-18','chaine',0,'','2019-12-19 11:14:21'),(7258,'MAIN_INFO_OPENINGHOURS_FRIDAY',1,'8-12 13-18','chaine',0,'','2019-12-19 11:14:21'),(7264,'MAIN_INFO_ACCOUNTANT_NAME',1,'Bob Bookkeeper','chaine',0,'','2019-12-19 11:14:54'),(7265,'MAIN_INFO_ACCOUNTANT_TOWN',1,'Berlin','chaine',0,'','2019-12-19 11:14:54'),(7266,'MAIN_INFO_ACCOUNTANT_STATE',1,'0','chaine',0,'','2019-12-19 11:14:54'),(7267,'MAIN_INFO_ACCOUNTANT_COUNTRY',1,'5','chaine',0,'','2019-12-19 11:14:54'),(7268,'MAIN_INFO_ACCOUNTANT_MAIL',1,'mybookkeeper@example.com','chaine',0,'','2019-12-19 11:14:54'),(7313,'MODULEBUILDER_ASCIIDOCTOR',1,'asciidoctor','chaine',0,'','2019-12-20 10:57:21'),(7314,'MODULEBUILDER_ASCIIDOCTORPDF',1,'asciidoctor-pdf','chaine',0,'','2019-12-20 10:57:21'),(7337,'EXTERNAL_RSS_TITLE_1',1,'Dolibarr.org News','chaine',0,'','2019-12-20 12:10:38'),(7338,'EXTERNAL_RSS_URLRSS_1',1,'https://www.dolibarr.org/rss','chaine',0,'','2019-12-20 12:10:38'),(7339,'EXPENSEREPORT_ADDON',1,'mod_expensereport_jade','chaine',0,'','2019-12-20 16:33:46'),(7378,'COMPANY_USE_SEARCH_TO_SELECT',1,'0','chaine',0,'','2019-12-21 15:54:22'),(7420,'CASHDESK_SERVICES',1,'0','chaine',0,'','2019-12-23 12:15:06'),(7421,'TAKEPOS_ROOT_CATEGORY_ID',1,'31','chaine',0,'','2019-12-23 12:15:06'),(7422,'TAKEPOSCONNECTOR',1,'0','chaine',0,'','2019-12-23 12:15:06'),(7423,'TAKEPOS_BAR_RESTAURANT',1,'0','chaine',0,'','2019-12-23 12:15:06'),(7424,'TAKEPOS_TICKET_VAT_GROUPPED',1,'0','chaine',0,'','2019-12-23 12:15:06'),(7425,'TAKEPOS_AUTO_PRINT_TICKETS',1,'0','int',0,'','2019-12-23 12:15:06'),(7426,'TAKEPOS_NUMPAD',1,'0','chaine',0,'','2019-12-23 12:15:06'),(7427,'TAKEPOS_NUM_TERMINALS',1,'1','chaine',0,'','2019-12-23 12:15:06'),(7428,'TAKEPOS_DIRECT_PAYMENT',1,'0','int',0,'','2019-12-23 12:15:06'),(7429,'TAKEPOS_CUSTOM_RECEIPT',1,'0','int',0,'','2019-12-23 12:15:06'),(7430,'TAKEPOS_EMAIL_TEMPLATE_INVOICE',1,'-1','chaine',0,'','2019-12-23 12:15:06'),(7452,'MEMBER_ENABLE_PUBLIC',1,'1','chaine',0,'','2020-01-01 10:31:46'),(7453,'MEMBER_NEWFORM_AMOUNT',1,'20','chaine',0,'','2020-01-01 10:31:46'),(7454,'MEMBER_NEWFORM_EDITAMOUNT',1,'0','chaine',0,'','2020-01-01 10:31:46'),(7455,'MEMBER_NEWFORM_PAYONLINE',1,'all','chaine',0,'','2020-01-01 10:31:46'),(7456,'MEMBER_NEWFORM_FORCETYPE',1,'1','chaine',0,'','2020-01-01 10:31:46'),(7470,'STRIPE_TEST_PUBLISHABLE_KEY',1,'pk_test_123456789','chaine',0,'','2020-01-01 11:43:44'),(7471,'STRIPE_TEST_SECRET_KEY',1,'sk_test_123456','chaine',0,'','2020-01-01 11:43:44'),(7472,'STRIPE_BANK_ACCOUNT_FOR_PAYMENTS',1,'4','chaine',0,'','2020-01-01 11:43:44'),(7473,'STRIPE_USER_ACCOUNT_FOR_ACTIONS',1,'1','chaine',0,'','2020-01-01 11:43:44'),(7489,'CAPTURESERVER_SECURITY_KEY',1,'securitykey123','chaine',0,'','2020-01-01 12:00:49'),(8136,'MAIN_AGENDA_ACTIONAUTO_EXPENSE_DELETE',1,'1','chaine',0,'','2020-01-02 19:56:28'),(8190,'ACCOUNTING_PRODUCT_MODE',1,'ACCOUNTANCY_SELL_EXPORT','chaine',0,'','2020-01-06 01:23:30'),(8191,'MAIN_ENABLE_DEFAULT_VALUES',1,'1','chaine',0,'','2020-01-06 16:09:52'),(8210,'CABINETMED_RHEUMATOLOGY_ON',1,'0','texte',0,'','2020-01-06 16:51:43'),(8213,'MAIN_SEARCHFORM_SOCIETE',1,'1','texte',0,'','2020-01-06 16:51:43'),(8214,'CABINETMED_BANK_PATIENT_REQUIRED',1,'0','texte',0,'','2020-01-06 16:51:43'),(8215,'DIAGNOSTIC_IS_NOT_MANDATORY',1,'1','texte',0,'','2020-01-06 16:51:43'),(8216,'USER_ADDON_PDF_ODT',1,'generic_user_odt','chaine',0,'','2020-01-07 13:45:19'),(8217,'USERGROUP_ADDON_PDF_ODT',1,'generic_usergroup_odt','chaine',0,'','2020-01-07 13:45:23'),(8230,'MAIN_MODULE_EMAILCOLLECTOR',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2020-01-12 20:13:55'),(8232,'MAIN_MODULE_SUPPLIERPROPOSAL',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2020-01-13 14:37:09'),(8233,'MAIN_MODULE_EXPEDITION',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2020-01-13 14:38:20'),(8252,'SYSTEMTOOLS_MYSQLDUMP',1,'/usr/bin/mysqldump','chaine',0,'','2020-01-15 15:42:41'),(8259,'ACCOUNTING_REEXPORT',1,'1','yesno',0,'','2020-01-17 13:42:56'),(8291,'PRODUIT_MULTIPRICES_LIMIT',1,'5','chaine',0,'','2020-01-17 14:21:46'),(8293,'PRODUIT_CUSTOMER_PRICES_BY_QTY',1,'0','chaine',0,'','2020-01-17 14:21:46'),(8303,'PRODUCT_PRICE_UNIQ',1,'0','chaine',0,'','2020-01-17 14:25:30'),(8304,'PRODUIT_MULTIPRICES',1,'0','chaine',0,'','2020-01-17 14:25:30'),(8305,'PRODUIT_CUSTOMER_PRICES',1,'1','chaine',0,'','2020-01-17 14:25:30'),(8306,'PRODUIT_SOUSPRODUITS',1,'0','chaine',0,'','2020-01-17 14:25:30'),(8307,'PRODUIT_DESC_IN_FORM',1,'0','chaine',0,'','2020-01-17 14:25:30'),(8308,'PRODUIT_TEXTS_IN_THIRDPARTY_LANGUAGE',1,'0','chaine',0,'','2020-01-17 14:25:30'),(8309,'PRODUIT_USE_SEARCH_TO_SELECT',1,'1','chaine',0,'','2020-01-17 14:25:30'),(8310,'PRODUIT_FOURN_TEXTS',1,'0','chaine',0,'','2020-01-17 14:25:30'),(8313,'MAIN_MODULE_FCKEDITOR',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2020-01-18 17:13:27'),(8314,'FCKEDITOR_ENABLE_TICKET',1,'1','chaine',0,'','2020-01-18 19:39:54'),(8321,'FCKEDITOR_SKIN',1,'moono-lisa','chaine',0,'','2020-01-18 19:41:15'),(8322,'FCKEDITOR_TEST',1,'Test < aaa
\r\n
\r\n\"\"','chaine',0,'','2020-01-18 19:41:15'),(8486,'MAIN_MULTILANGS',1,'1','chaine',0,'','2020-01-21 09:40:00'),(8491,'MAIN_DISABLE_JAVASCRIPT',1,'0','chaine',0,'','2020-01-21 09:40:00'),(8492,'MAIN_BUTTON_HIDE_UNAUTHORIZED',1,'0','chaine',0,'','2020-01-21 09:40:00'),(8496,'MAIN_SHOW_LOGO',1,'1','chaine',0,'','2020-01-21 09:40:00'),(8498,'MAIN_HELPCENTER_DISABLELINK',0,'0','chaine',0,'','2020-01-21 09:40:00'),(8501,'MAIN_BUGTRACK_ENABLELINK',1,'0','chaine',0,'','2020-01-21 09:40:00'),(8554,'MAIN_INFO_SOCIETE_FACEBOOK_URL',1,'dolibarr','chaine',0,'','2020-06-12 17:24:42'),(8555,'MAIN_INFO_SOCIETE_TWITTER_URL',1,'dolibarr','chaine',0,'','2020-06-12 17:24:42'),(8556,'MAIN_INFO_SOCIETE_LINKEDIN_URL',1,'https://www.linkedin.com/company/9400559/admin/','chaine',0,'','2020-06-12 17:24:42'),(8557,'MAIN_INFO_SOCIETE_INSTAGRAM_URL',1,'dolibarr','chaine',0,'','2020-06-12 17:24:42'),(8558,'MAIN_INFO_SOCIETE_YOUTUBE_URL',1,'DolibarrERPCRM','chaine',0,'','2020-06-12 17:24:42'),(8559,'MAIN_INFO_SOCIETE_GITHUB_URL',1,'dolibarr','chaine',0,'','2020-06-12 17:24:42'),(8577,'PRODUCT_PRICE_BASE_TYPE',0,'HT','string',0,NULL,'2020-12-10 12:24:38'),(8612,'MAIN_UPLOAD_DOC',1,'50000','chaine',0,'','2020-12-10 12:26:31'),(8613,'MAIN_UMASK',1,'0664','chaine',0,'','2020-12-10 12:26:31'),(8614,'MAIN_ANTIVIRUS_PARAM',1,'--fdpass','chaine',0,'','2020-12-10 12:26:31'),(8619,'WEBSITE_EDITINLINE',1,'0','chaine',0,'','2020-12-10 12:27:05'),(8633,'MAIN_MODULE_RECEPTION',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2020-12-10 12:30:13'),(8634,'RECEPTION_ADDON_PDF',1,'squille','chaine',0,'Nom du gestionnaire de generation des bons receptions en PDF','2020-12-10 12:30:13'),(8635,'RECEPTION_ADDON_NUMBER',1,'mod_reception_beryl','chaine',0,'Name for numbering manager for receptions','2020-12-10 12:30:13'),(8636,'RECEPTION_ADDON_PDF_ODT_PATH',1,'DOL_DATA_ROOT/doctemplates/receptions','chaine',0,NULL,'2020-12-10 12:30:13'),(8637,'MAIN_SUBMODULE_RECEPTION',1,'1','chaine',0,'Enable receptions','2020-12-10 12:30:13'),(8638,'MAIN_MODULE_PAYMENTBYBANKTRANSFER',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2020-12-10 12:30:17'),(8640,'MAIN_MODULE_MARGIN_TABS_0',1,'product:+margin:Margins:margins:$user->rights->margins->liretous:/margin/tabs/productMargins.php?id=__ID__','chaine',0,NULL,'2020-12-10 12:30:20'),(8641,'MAIN_MODULE_MARGIN_TABS_1',1,'thirdparty:+margin:Margins:margins:empty($user->socid) && $user->rights->margins->liretous && ($object->client > 0):/margin/tabs/thirdpartyMargins.php?socid=__ID__','chaine',0,NULL,'2020-12-10 12:30:20'),(8644,'MAIN_MODULE_INCOTERM',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\"}','2020-12-10 12:31:36'),(8645,'INCOTERM_ACTIVATE',1,'','chaine',0,'Description de INCOTERM_ACTIVATE','2020-12-10 12:31:36'),(8715,'SYSLOG_LEVEL',0,'5','chaine',0,'','2021-04-15 10:34:05'),(8716,'MAIN_SECURITY_HASH_ALGO',1,'password_hash','chaine',1,'','2021-04-15 10:38:33'),(8717,'MAIN_INFO_SOCIETE_COUNTRY',1,'117:IN:India','chaine',0,'','2021-04-15 10:46:30'),(8718,'MAIN_INFO_SOCIETE_NOM',1,'MyBigCompany','chaine',0,'','2021-04-15 10:46:30'),(8719,'MAIN_INFO_SOCIETE_ADDRESS',1,'21 Jump street.','chaine',0,'','2021-04-15 10:46:30'),(8720,'MAIN_INFO_SOCIETE_TOWN',1,'MyTown','chaine',0,'','2021-04-15 10:46:30'),(8721,'MAIN_INFO_SOCIETE_ZIP',1,'75500','chaine',0,'','2021-04-15 10:46:30'),(8722,'MAIN_MONNAIE',1,'EUR','chaine',0,'','2021-04-15 10:46:30'),(8723,'MAIN_INFO_SOCIETE_TEL',1,'09123123','chaine',0,'','2021-04-15 10:46:30'),(8724,'MAIN_INFO_SOCIETE_FAX',1,'09123124','chaine',0,'','2021-04-15 10:46:30'),(8725,'MAIN_INFO_SOCIETE_MAIL',1,'myemail@mybigcompany.com','chaine',0,'','2021-04-15 10:46:30'),(8726,'MAIN_INFO_SOCIETE_WEB',1,'https://www.dolibarr.org','chaine',0,'','2021-04-15 10:46:30'),(8727,'MAIN_INFO_SOCIETE_NOTE',1,'This is note about my company','chaine',0,'','2021-04-15 10:46:30'),(8728,'MAIN_INFO_SOCIETE_LOGO_SQUARRED',1,'mybigcompany_squarred.png','chaine',0,'','2021-04-15 10:46:30'),(8729,'MAIN_INFO_SOCIETE_LOGO_SQUARRED_SMALL',1,'mybigcompany_squarred_small.png','chaine',0,'','2021-04-15 10:46:30'),(8730,'MAIN_INFO_SOCIETE_LOGO_SQUARRED_MINI',1,'mybigcompany_squarred_mini.png','chaine',0,'','2021-04-15 10:46:30'),(8731,'MAIN_INFO_SOCIETE_MANAGERS',1,'Zack Zeceo','chaine',0,'','2021-04-15 10:46:30'),(8732,'MAIN_INFO_GDPR',1,'Zack Zeceo','chaine',0,'','2021-04-15 10:46:30'),(8733,'MAIN_INFO_CAPITAL',1,'10000','chaine',0,'','2021-04-15 10:46:30'),(8734,'MAIN_INFO_SOCIETE_FORME_JURIDIQUE',1,'0','chaine',0,'','2021-04-15 10:46:30'),(8735,'MAIN_INFO_SIREN',1,'123456','chaine',0,'','2021-04-15 10:46:30'),(8736,'MAIN_INFO_SIRET',1,'ABC-DEF','chaine',0,'','2021-04-15 10:46:30'),(8737,'MAIN_INFO_APE',1,'15E-45-8D','chaine',0,'','2021-04-15 10:46:30'),(8738,'MAIN_INFO_TVAINTRA',1,'FR12345678','chaine',0,'','2021-04-15 10:46:30'),(8739,'MAIN_INFO_SOCIETE_OBJECT',1,'A company demo to show how Dolibarr ERP CRM is wonderfull','chaine',0,'','2021-04-15 10:46:30'),(8740,'SOCIETE_FISCAL_MONTH_START',1,'4','chaine',0,'','2021-04-15 10:46:30'),(8741,'FACTURE_TVAOPTION',1,'1','chaine',0,'','2021-04-15 10:46:30'),(8742,'FACTURE_LOCAL_TAX1_OPTION',1,'localtax1on','chaine',0,'','2021-04-15 10:46:30'),(8743,'FACTURE_LOCAL_TAX2_OPTION',1,'localtax2on','chaine',0,'','2021-04-15 10:46:30'),(8744,'MAIN_INFO_VALUE_LOCALTAX1',1,'0','chaine',0,'','2021-04-15 10:46:30'),(8745,'MAIN_INFO_LOCALTAX_CALC1',1,'0','chaine',0,'','2021-04-15 10:46:30'),(8746,'MAIN_INFO_VALUE_LOCALTAX2',1,'0','chaine',0,'','2021-04-15 10:46:30'),(8747,'MAIN_INFO_LOCALTAX_CALC2',1,'0','chaine',0,'','2021-04-15 10:46:30'),(8759,'MAIN_LOGIN_BACKGROUND',1,'background_dolibarr.jpg','chaine',0,'','2021-04-15 10:54:37'),(8760,'MAIN_LANG_DEFAULT',1,'auto','chaine',0,'','2021-04-15 10:56:30'),(8762,'MAIN_THEME',1,'eldy','chaine',0,'','2021-04-15 10:56:30'),(8763,'THEME_ELDY_USE_HOVER',1,'237,244,251','chaine',0,'','2021-04-15 10:56:30'),(8764,'MAIN_SIZE_LISTE_LIMIT',1,'25','chaine',0,'','2021-04-15 10:56:30'),(8765,'MAIN_SIZE_SHORTLIST_LIMIT',1,'3','chaine',0,'','2021-04-15 10:56:30'),(8766,'MAIN_START_WEEK',1,'1','chaine',0,'','2021-04-15 10:56:30'),(8767,'MAIN_DEFAULT_WORKING_DAYS',1,'1-5','chaine',0,'','2021-04-15 10:56:30'),(8768,'MAIN_DEFAULT_WORKING_HOURS',1,'9-18','chaine',0,'','2021-04-15 10:56:30'),(8769,'MAIN_FIRSTNAME_NAME_POSITION',1,'0','chaine',0,'','2021-04-15 10:56:30'),(8770,'MAIN_HOME',1,'__(NoteSomeFeaturesAreDisabled)__
\r\n__(SomeTranslationAreUncomplete)__','chaine',0,'','2021-04-15 10:56:30'),(8771,'MAIN_FEATURES_LEVEL',0,'0','chaine',1,'Level of features to show (0=stable only, 1=stable+experimental, 2=stable+experimental+development','2021-04-15 11:46:30'),(8877,'AGENDA_REMINDER_BROWSER',1,'1','chaine',0,'','2021-04-15 13:32:29'),(8943,'MAIN_MODULE_ACCOUNTING',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:16'),(8944,'MAIN_MODULE_AGENDA',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:16'),(8945,'MAIN_MODULE_BOM',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:16'),(8946,'MAIN_MODULE_BANQUE',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:16'),(8947,'MAIN_MODULE_BARCODE',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:17'),(8948,'MAIN_MODULE_CRON',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:17'),(8949,'MAIN_MODULE_COMMANDE',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:17'),(8950,'MAIN_MODULE_DON',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:17'),(8951,'MAIN_MODULE_ECM',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:17'),(8952,'MAIN_MODULE_EXPENSEREPORT',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:17'),(8953,'MAIN_MODULE_FACTURE',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:17'),(8954,'MAIN_MODULE_FOURNISSEUR',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:17'),(8955,'MAIN_MODULE_HOLIDAY',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:17'),(8956,'MAIN_MODULE_MARGIN',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:17'),(8959,'MAIN_MODULE_MRP',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:17'),(8960,'MAIN_MODULE_MRP_TRIGGERS',1,'0','chaine',0,NULL,'2022-02-07 13:38:17'),(8961,'MAIN_MODULE_MRP_LOGIN',1,'0','chaine',0,NULL,'2022-02-07 13:38:17'),(8962,'MAIN_MODULE_MRP_SUBSTITUTIONS',1,'0','chaine',0,NULL,'2022-02-07 13:38:17'),(8963,'MAIN_MODULE_MRP_MENUS',1,'0','chaine',0,NULL,'2022-02-07 13:38:17'),(8964,'MAIN_MODULE_MRP_TPL',1,'0','chaine',0,NULL,'2022-02-07 13:38:17'),(8965,'MAIN_MODULE_MRP_BARCODE',1,'0','chaine',0,NULL,'2022-02-07 13:38:17'),(8966,'MAIN_MODULE_MRP_MODELS',1,'0','chaine',0,NULL,'2022-02-07 13:38:17'),(8967,'MAIN_MODULE_MRP_THEME',1,'0','chaine',0,NULL,'2022-02-07 13:38:17'),(8968,'MAIN_MODULE_MRP_MODULEFOREXTERNAL',1,'0','chaine',0,NULL,'2022-02-07 13:38:17'),(8969,'MAIN_MODULE_OPENSURVEY',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:17'),(8970,'MAIN_MODULE_PRINTING',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:17'),(8971,'MAIN_MODULE_RECRUITMENT',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:18'),(8972,'MAIN_MODULE_RECRUITMENT_TRIGGERS',1,'0','chaine',0,NULL,'2022-02-07 13:38:18'),(8973,'MAIN_MODULE_RECRUITMENT_LOGIN',1,'0','chaine',0,NULL,'2022-02-07 13:38:18'),(8974,'MAIN_MODULE_RECRUITMENT_SUBSTITUTIONS',1,'0','chaine',0,NULL,'2022-02-07 13:38:18'),(8975,'MAIN_MODULE_RECRUITMENT_MENUS',1,'0','chaine',0,NULL,'2022-02-07 13:38:18'),(8976,'MAIN_MODULE_RECRUITMENT_TPL',1,'0','chaine',0,NULL,'2022-02-07 13:38:18'),(8977,'MAIN_MODULE_RECRUITMENT_BARCODE',1,'0','chaine',0,NULL,'2022-02-07 13:38:18'),(8978,'MAIN_MODULE_RECRUITMENT_MODELS',1,'1','chaine',0,NULL,'2022-02-07 13:38:18'),(8979,'MAIN_MODULE_RECRUITMENT_THEME',1,'0','chaine',0,NULL,'2022-02-07 13:38:18'),(8980,'MAIN_MODULE_RECRUITMENT_MODULEFOREXTERNAL',1,'0','chaine',0,NULL,'2022-02-07 13:38:18'),(8981,'MAIN_MODULE_RESOURCE',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:18'),(8982,'MAIN_MODULE_SALARIES',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:18'),(8983,'MAIN_MODULE_SERVICE',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:18'),(8984,'MAIN_MODULE_SYSLOG',0,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:18'),(8985,'MAIN_MODULE_SOCIETE',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:18'),(8986,'MAIN_MODULE_STRIPE',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:18'),(8987,'MAIN_MODULE_TICKET',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:18'),(8988,'MAIN_MODULE_TICKET_TABS_0',1,'thirdparty:+ticket:Tickets:@ticket:$user->rights->ticket->read:/ticket/list.php?socid=__ID__','chaine',0,NULL,'2022-02-07 13:38:18'),(8989,'MAIN_MODULE_TICKET_TABS_1',1,'project:+ticket:Tickets:@ticket:$user->rights->ticket->read:/ticket/list.php?projectid=__ID__','chaine',0,NULL,'2022-02-07 13:38:18'),(8990,'MAIN_MODULE_TICKET_TRIGGERS',1,'1','chaine',0,NULL,'2022-02-07 13:38:18'),(8991,'TAKEPOS_PRINT_METHOD',1,'browser','chaine',0,'','2022-02-07 13:38:18'),(8992,'MAIN_MODULE_TAKEPOS',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:18'),(8993,'MAIN_MODULE_TAKEPOS_TRIGGERS',1,'0','chaine',0,NULL,'2022-02-07 13:38:18'),(8994,'MAIN_MODULE_TAKEPOS_LOGIN',1,'0','chaine',0,NULL,'2022-02-07 13:38:18'),(8995,'MAIN_MODULE_TAKEPOS_SUBSTITUTIONS',1,'1','chaine',0,NULL,'2022-02-07 13:38:18'),(8996,'MAIN_MODULE_TAKEPOS_MENUS',1,'0','chaine',0,NULL,'2022-02-07 13:38:18'),(8997,'MAIN_MODULE_TAKEPOS_THEME',1,'0','chaine',0,NULL,'2022-02-07 13:38:18'),(8998,'MAIN_MODULE_TAKEPOS_TPL',1,'0','chaine',0,NULL,'2022-02-07 13:38:18'),(8999,'MAIN_MODULE_TAKEPOS_BARCODE',1,'0','chaine',0,NULL,'2022-02-07 13:38:18'),(9000,'MAIN_MODULE_TAKEPOS_MODELS',1,'0','chaine',0,NULL,'2022-02-07 13:38:18'),(9001,'MAIN_MODULE_USER',0,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:18'),(9002,'MAIN_MODULE_VARIANTS',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:18'),(9003,'MAIN_MODULE_WEBSITE',1,'1','string',0,'{\"authorid\":0,\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:38:18'),(9004,'MAIN_VERSION_LAST_UPGRADE',0,'15.0.0','chaine',0,'Dolibarr version for last upgrade','2022-02-07 13:38:20'),(9006,'MAIN_FIRST_PING_OK_DATE',1,'20220207133821','chaine',0,'','2022-02-07 13:38:21'),(9007,'MAIN_FIRST_PING_OK_ID',1,'disabled','chaine',0,'','2022-02-07 13:38:21'),(9008,'MAIN_MODULE_KNOWLEDGEMANAGEMENT',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 13:39:27'),(9009,'MAIN_MODULE_KNOWLEDGEMANAGEMENT_TRIGGERS',1,'0','chaine',0,NULL,'2022-02-07 13:39:27'),(9010,'MAIN_MODULE_KNOWLEDGEMANAGEMENT_LOGIN',1,'0','chaine',0,NULL,'2022-02-07 13:39:27'),(9011,'MAIN_MODULE_KNOWLEDGEMANAGEMENT_SUBSTITUTIONS',1,'0','chaine',0,NULL,'2022-02-07 13:39:27'),(9012,'MAIN_MODULE_KNOWLEDGEMANAGEMENT_MENUS',1,'0','chaine',0,NULL,'2022-02-07 13:39:27'),(9013,'MAIN_MODULE_KNOWLEDGEMANAGEMENT_TPL',1,'0','chaine',0,NULL,'2022-02-07 13:39:27'),(9014,'MAIN_MODULE_KNOWLEDGEMANAGEMENT_BARCODE',1,'0','chaine',0,NULL,'2022-02-07 13:39:27'),(9015,'MAIN_MODULE_KNOWLEDGEMANAGEMENT_MODELS',1,'1','chaine',0,NULL,'2022-02-07 13:39:27'),(9016,'MAIN_MODULE_KNOWLEDGEMANAGEMENT_PRINTING',1,'0','chaine',0,NULL,'2022-02-07 13:39:27'),(9017,'MAIN_MODULE_KNOWLEDGEMANAGEMENT_THEME',1,'0','chaine',0,NULL,'2022-02-07 13:39:27'),(9018,'MAIN_MODULE_KNOWLEDGEMANAGEMENT_MODULEFOREXTERNAL',1,'0','chaine',0,NULL,'2022-02-07 13:39:27'),(9021,'WEBSITE_SUBCONTAINERSINLINE',1,'1','chaine',0,'','2022-02-07 13:57:11'),(9022,'PAYMENTBYBANKTRANSFER_ID_BANKACCOUNT',1,'1','chaine',0,'','2022-02-07 14:17:28'),(9023,'PAYMENTBYBANKTRANSFER_USER',1,'13','chaine',0,'','2022-02-07 14:17:28'),(9025,'MAIN_MODULE_BLOCKEDLOG',1,'1','string',0,'{\"authorid\":\"12\",\"ip\":\"127.0.0.1\",\"lastactivationversion\":\"dolibarr\"}','2022-02-07 14:32:50'),(9026,'MAIN_IHM_PARAMS_REV',1,'16','chaine',0,'','2022-02-07 14:32:50'),(9141,'MAIN_AGENDA_ACTIONAUTO_COMPANY_SENTBYMAIL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9142,'MAIN_AGENDA_ACTIONAUTO_COMPANY_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9143,'MAIN_AGENDA_ACTIONAUTO_COMPANY_MODIFY',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9144,'MAIN_AGENDA_ACTIONAUTO_COMPANY_CREATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9145,'MAIN_AGENDA_ACTIONAUTO_PROPAL_CLOSE_SIGNED',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9146,'MAIN_AGENDA_ACTIONAUTO_PROPAL_CLOSE_REFUSED',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9147,'MAIN_AGENDA_ACTIONAUTO_PROPAL_CLASSIFY_BILLED',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9148,'MAIN_AGENDA_ACTIONAUTO_PROPAL_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9149,'MAIN_AGENDA_ACTIONAUTO_PROPAL_VALIDATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9150,'MAIN_AGENDA_ACTIONAUTO_PROPAL_SENTBYMAIL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9151,'MAIN_AGENDA_ACTIONAUTO_ORDER_VALIDATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9152,'MAIN_AGENDA_ACTIONAUTO_ORDER_CLASSIFY_BILLED',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9153,'MAIN_AGENDA_ACTIONAUTO_ORDER_CLOSE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9154,'MAIN_AGENDA_ACTIONAUTO_ORDER_CANCEL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9155,'MAIN_AGENDA_ACTIONAUTO_ORDER_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9156,'MAIN_AGENDA_ACTIONAUTO_ORDER_SENTBYMAIL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9157,'MAIN_AGENDA_ACTIONAUTO_BILL_VALIDATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9158,'MAIN_AGENDA_ACTIONAUTO_BILL_PAYED',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9159,'MAIN_AGENDA_ACTIONAUTO_BILL_CANCEL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9160,'MAIN_AGENDA_ACTIONAUTO_BILL_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9161,'MAIN_AGENDA_ACTIONAUTO_BILL_SENTBYMAIL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9162,'MAIN_AGENDA_ACTIONAUTO_PROPOSAL_SUPPLIER_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9163,'MAIN_AGENDA_ACTIONAUTO_PROPOSAL_SUPPLIER_VALIDATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9164,'MAIN_AGENDA_ACTIONAUTO_PROPOSAL_SUPPLIER_SENTBYMAIL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9165,'MAIN_AGENDA_ACTIONAUTO_PROPOSAL_SUPPLIER_CLOSE_SIGNED',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9166,'MAIN_AGENDA_ACTIONAUTO_PROPOSAL_SUPPLIER_CLOSE_REFUSED',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9167,'MAIN_AGENDA_ACTIONAUTO_BILL_UNVALIDATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9168,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_VALIDATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9169,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_CREATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9170,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_APPROVE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9171,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_SUBMIT',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9172,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_RECEIVE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9173,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_REFUSE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9174,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_CANCEL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9175,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_CLASSIFY_BILLED',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9176,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9177,'MAIN_AGENDA_ACTIONAUTO_ORDER_SUPPLIER_SENTBYMAIL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9178,'MAIN_AGENDA_ACTIONAUTO_BILL_SUPPLIER_VALIDATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9179,'MAIN_AGENDA_ACTIONAUTO_BILL_SUPPLIER_UNVALIDATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9180,'MAIN_AGENDA_ACTIONAUTO_BILL_SUPPLIER_PAYED',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9181,'MAIN_AGENDA_ACTIONAUTO_BILL_SUPPLIER_CANCELED',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9182,'MAIN_AGENDA_ACTIONAUTO_BILL_SUPPLIER_SENTBYMAIL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9183,'MAIN_AGENDA_ACTIONAUTO_BILL_SUPPLIER_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9184,'MAIN_AGENDA_ACTIONAUTO_CONTRACT_VALIDATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9185,'MAIN_AGENDA_ACTIONAUTO_CONTRACT_SENTBYMAIL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9186,'MAIN_AGENDA_ACTIONAUTO_CONTRACT_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9187,'MAIN_AGENDA_ACTIONAUTO_FICHINTER_VALIDATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9188,'MAIN_AGENDA_ACTIONAUTO_FICHINTER_REOPEN',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9189,'MAIN_AGENDA_ACTIONAUTO_FICHINTER_SENTBYMAIL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9190,'MAIN_AGENDA_ACTIONAUTO_SHIPPING_VALIDATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9191,'MAIN_AGENDA_ACTIONAUTO_SHIPPING_SENTBYMAIL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9192,'MAIN_AGENDA_ACTIONAUTO_MEMBER_VALIDATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9193,'MAIN_AGENDA_ACTIONAUTO_MEMBER_SENTBYMAIL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9194,'MAIN_AGENDA_ACTIONAUTO_MEMBER_SUBSCRIPTION_CREATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9195,'MAIN_AGENDA_ACTIONAUTO_MEMBER_SUBSCRIPTION_MODIFY',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9196,'MAIN_AGENDA_ACTIONAUTO_MEMBER_SUBSCRIPTION_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9197,'MAIN_AGENDA_ACTIONAUTO_MEMBER_MODIFY',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9198,'MAIN_AGENDA_ACTIONAUTO_MEMBER_RESILIATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9199,'MAIN_AGENDA_ACTIONAUTO_MEMBER_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9200,'MAIN_AGENDA_ACTIONAUTO_MEMBER_EXCLUDE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9201,'MAIN_AGENDA_ACTIONAUTO_PRODUCT_CREATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9202,'MAIN_AGENDA_ACTIONAUTO_PRODUCT_MODIFY',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9203,'MAIN_AGENDA_ACTIONAUTO_PRODUCT_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9204,'MAIN_AGENDA_ACTIONAUTO_FICHINTER_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9205,'MAIN_AGENDA_ACTIONAUTO_TASK_CREATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9206,'MAIN_AGENDA_ACTIONAUTO_TASK_MODIFY',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9207,'MAIN_AGENDA_ACTIONAUTO_TASK_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9208,'MAIN_AGENDA_ACTIONAUTO_CONTACT_CREATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9209,'MAIN_AGENDA_ACTIONAUTO_CONTACT_MODIFY',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9210,'MAIN_AGENDA_ACTIONAUTO_CONTACT_SENTBYMAIL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9211,'MAIN_AGENDA_ACTIONAUTO_CONTACT_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9212,'MAIN_AGENDA_ACTIONAUTO_PROJECT_CREATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9213,'MAIN_AGENDA_ACTIONAUTO_PROJECT_MODIFY',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9214,'MAIN_AGENDA_ACTIONAUTO_PROJECT_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9215,'MAIN_AGENDA_ACTIONAUTO_TICKET_CREATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9216,'MAIN_AGENDA_ACTIONAUTO_TICKET_MODIFY',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9217,'MAIN_AGENDA_ACTIONAUTO_TICKET_ASSIGNED',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9218,'MAIN_AGENDA_ACTIONAUTO_TICKET_CLOSE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9219,'MAIN_AGENDA_ACTIONAUTO_TICKET_SENTBYMAIL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9220,'MAIN_AGENDA_ACTIONAUTO_TICKET_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9221,'MAIN_AGENDA_ACTIONAUTO_EXPENSE_REPORT_CREATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9222,'MAIN_AGENDA_ACTIONAUTO_EXPENSE_REPORT_VALIDATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9223,'MAIN_AGENDA_ACTIONAUTO_EXPENSE_REPORT_APPROVE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9224,'MAIN_AGENDA_ACTIONAUTO_EXPENSE_REPORT_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9225,'MAIN_AGENDA_ACTIONAUTO_EXPENSE_REPORT_PAID',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9226,'MAIN_AGENDA_ACTIONAUTO_HOLIDAY_CREATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9227,'MAIN_AGENDA_ACTIONAUTO_HOLIDAY_VALIDATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9228,'MAIN_AGENDA_ACTIONAUTO_HOLIDAY_APPROVE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9229,'MAIN_AGENDA_ACTIONAUTO_USER_SENTBYMAIL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9230,'MAIN_AGENDA_ACTIONAUTO_USER_CREATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9231,'MAIN_AGENDA_ACTIONAUTO_USER_MODIFY',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9232,'MAIN_AGENDA_ACTIONAUTO_USER_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9233,'MAIN_AGENDA_ACTIONAUTO_USER_NEW_PASSWORD',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9234,'MAIN_AGENDA_ACTIONAUTO_USER_ENABLEDISABLE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9235,'MAIN_AGENDA_ACTIONAUTO_BOM_VALIDATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9236,'MAIN_AGENDA_ACTIONAUTO_BOM_UNVALIDATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9237,'MAIN_AGENDA_ACTIONAUTO_BOM_CLOSE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9238,'MAIN_AGENDA_ACTIONAUTO_BOM_REOPEN',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9239,'MAIN_AGENDA_ACTIONAUTO_BOM_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9240,'MAIN_AGENDA_ACTIONAUTO_MRP_MO_VALIDATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9241,'MAIN_AGENDA_ACTIONAUTO_MRP_MO_PRODUCED',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9242,'MAIN_AGENDA_ACTIONAUTO_MRP_MO_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9243,'MAIN_AGENDA_ACTIONAUTO_MRP_MO_CANCEL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9244,'MAIN_AGENDA_ACTIONAUTO_HOLIDAY_MODIFY',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9245,'MAIN_AGENDA_ACTIONAUTO_HOLIDAY_CANCEL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9246,'MAIN_AGENDA_ACTIONAUTO_HOLIDAY_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9247,'MAIN_AGENDA_ACTIONAUTO_RECRUITMENTJOBPOSITION_CREATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9248,'MAIN_AGENDA_ACTIONAUTO_RECRUITMENTJOBPOSITION_MODIFY',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9249,'MAIN_AGENDA_ACTIONAUTO_RECRUITMENTJOBPOSITION_SENTBYMAIL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9250,'MAIN_AGENDA_ACTIONAUTO_RECRUITMENTJOBPOSITION_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9251,'MAIN_AGENDA_ACTIONAUTO_RECRUITMENTCANDIDATURE_CREATE',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9252,'MAIN_AGENDA_ACTIONAUTO_RECRUITMENTCANDIDATURE_MODIFY',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9253,'MAIN_AGENDA_ACTIONAUTO_RECRUITMENTCANDIDATURE_SENTBYMAIL',1,'1','chaine',0,'','2022-02-07 14:37:16'),(9254,'MAIN_AGENDA_ACTIONAUTO_RECRUITMENTCANDIDATURE_DELETE',1,'1','chaine',0,'','2022-02-07 14:37:16'); /*!40000 ALTER TABLE `llx_const` ENABLE KEYS */; UNLOCK TABLES; @@ -4802,7 +4852,7 @@ CREATE TABLE `llx_contratdet` ( `commentaire` text COLLATE utf8_unicode_ci DEFAULT NULL, `fk_unit` int(11) DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_subprice` double(24,8) DEFAULT 0.00000000, `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000, `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000, @@ -4930,7 +4980,7 @@ CREATE TABLE `llx_cronjob` ( `test` varchar(255) COLLATE utf8_unicode_ci DEFAULT '1', `processing` int(11) NOT NULL DEFAULT 0, PRIMARY KEY (`rowid`) -) ENGINE=InnoDB AUTO_INCREMENT=49 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=50 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -4939,7 +4989,7 @@ CREATE TABLE `llx_cronjob` ( LOCK TABLES `llx_cronjob` WRITE; /*!40000 ALTER TABLE `llx_cronjob` DISABLE KEYS */; -INSERT INTO `llx_cronjob` VALUES (1,'2015-03-23 18:18:39','2015-03-23 19:18:39','command','aaa','aaaa','','','','','','',0,NULL,NULL,'2015-03-23 19:18:00',NULL,NULL,NULL,NULL,'3600',3600,0,0,1,1,'',NULL,0,0,0,NULL,'1',0),(40,'2018-11-23 11:58:15','2018-11-23 12:58:15','method','SendEmailsReminders',NULL,'comm/action/class/actioncomm.class.php','ActionComm','sendEmailsReminder',NULL,NULL,'agenda',10,NULL,NULL,'2018-11-23 12:58:15',NULL,NULL,NULL,NULL,'60',10,NULL,1,NULL,NULL,'SendEMailsReminder',NULL,1,0,0,NULL,'$conf->agenda->enabled',0),(41,'2018-11-23 11:58:16','2018-11-23 12:58:16','method','PurgeDeleteTemporaryFilesShort',NULL,'core/class/utils.class.php','Utils','purgeFiles',NULL,NULL,'cron',50,NULL,NULL,'2018-11-23 12:58:16',NULL,NULL,NULL,NULL,'604800',2,NULL,1,NULL,NULL,'PurgeDeleteTemporaryFiles',NULL,0,0,0,NULL,'1',0),(42,'2020-01-15 15:43:12','2018-11-23 12:58:16','method','MakeLocalDatabaseDumpShort',NULL,'core/class/utils.class.php','Utils','dumpDatabase','none,auto,1,auto,10',NULL,'cron',90,'2020-01-15 19:43:12','2020-01-17 12:58:16','2018-11-23 12:58:16',NULL,'2020-01-15 19:43:12','-1','Failed to run external command. Check it is available and runnable by your PHP server. If PHP Safe Mode is enabled, check that command is inside a directory defined by parameter safe_mode_exec_dir.\nFailed to run external command. Check it is available and runnable by your PHP server. If PHP Safe Mode is enabled, check that command is inside a directory defined by parameter safe_mode_exec_dir.','604800',1,2,1,NULL,12,'MakeLocalDatabaseDump',NULL,0,0,0,NULL,'1',0),(43,'2018-11-23 11:58:17','2018-11-23 12:58:17','method','RecurringInvoices',NULL,'compta/facture/class/facture-rec.class.php','FactureRec','createRecurringInvoices',NULL,NULL,'facture',50,NULL,NULL,'2018-11-23 23:00:00',NULL,NULL,NULL,NULL,'86400',1,NULL,1,NULL,NULL,'Generate recurring invoices',NULL,1,0,0,NULL,'$conf->facture->enabled',0),(45,'2020-01-01 12:00:34','2020-01-01 16:00:34','method','MyJob label',NULL,'/captureserver/class/myobject.class.php','MyObject','doScheduledJob',NULL,NULL,'captureserver',0,NULL,NULL,'2020-01-01 16:00:34',NULL,NULL,NULL,NULL,'3600',2,NULL,0,NULL,NULL,'Comment',NULL,1,0,0,NULL,'$conf->captureserver->enabled',0),(46,'2020-01-12 20:13:55','2020-01-13 00:13:55','method','Email collector',NULL,'/emailcollector/class/emailcollector.class.php','EmailCollector','doCollect',NULL,NULL,'emailcollector',50,NULL,NULL,'2020-01-13 00:13:55',NULL,NULL,NULL,NULL,'60',5,NULL,1,NULL,NULL,'Comment',NULL,1,0,0,NULL,'$conf->emailcollector->enabled',0),(47,'2021-04-15 10:34:00','2021-04-15 07:34:00','method','CompressSyslogs',NULL,'core/class/utils.class.php','Utils','compressSyslogs',NULL,NULL,'syslog',50,NULL,NULL,'2021-04-15 07:34:00',NULL,NULL,NULL,NULL,'86400',1,NULL,0,NULL,NULL,'Compress and archive log files. The number of versions to keep is defined into the setup of module. Warning: Main application cron script must be run with same account than your web server to avoid to get log files with different owner than required by web server. Another solution is to set web server Operating System group as the group of directory documents and set GROUP permission \"rws\" on this directory so log files will always have the group and permissions of the web server Operating System group.',NULL,1,0,0,NULL,'1',0),(48,'2021-07-11 17:49:46','2021-07-11 19:49:46','method','SendEmailsRemindersOnInvoiceDueDate',NULL,'compta/facture/class/facture.class.php','Facture','sendEmailsRemindersOnInvoiceDueDate','10,all,EmailTemplateCode',NULL,'facture',50,NULL,NULL,'2021-07-11 23:00:00',NULL,NULL,NULL,NULL,'86400',1,NULL,0,NULL,NULL,'Send an emails when the unpaid invoices reach a due date + n days = today. First param is the offset n of days, second parameter is \"all\" or a payment mode code, last paramater is the code of email template to use (an email template with EmailTemplateCode must exists. the version in the language of the thirdparty will be used in priority).',NULL,1,0,0,NULL,'$conf->facture->enabled',0); +INSERT INTO `llx_cronjob` VALUES (1,'2015-03-23 18:18:39','2015-03-23 19:18:39','command','aaa','aaaa','','','','','','',0,NULL,NULL,'2015-03-23 19:18:00',NULL,NULL,NULL,NULL,'3600',3600,0,0,1,1,'',NULL,0,0,0,NULL,'1',0),(40,'2018-11-23 11:58:15','2018-11-23 12:58:15','method','SendEmailsReminders',NULL,'comm/action/class/actioncomm.class.php','ActionComm','sendEmailsReminder',NULL,NULL,'agenda',10,NULL,NULL,'2018-11-23 12:58:15',NULL,NULL,NULL,NULL,'60',10,NULL,1,NULL,NULL,'SendEMailsReminder',NULL,1,0,0,NULL,'$conf->agenda->enabled',0),(41,'2018-11-23 11:58:16','2018-11-23 12:58:16','method','PurgeDeleteTemporaryFilesShort',NULL,'core/class/utils.class.php','Utils','purgeFiles',NULL,NULL,'cron',50,NULL,NULL,'2018-11-23 12:58:16',NULL,NULL,NULL,NULL,'604800',2,NULL,1,NULL,NULL,'PurgeDeleteTemporaryFiles',NULL,0,0,0,NULL,'1',0),(42,'2020-01-15 15:43:12','2018-11-23 12:58:16','method','MakeLocalDatabaseDumpShort',NULL,'core/class/utils.class.php','Utils','dumpDatabase','none,auto,1,auto,10',NULL,'cron',90,'2020-01-15 19:43:12','2020-01-17 12:58:16','2018-11-23 12:58:16',NULL,'2020-01-15 19:43:12','-1','Failed to run external command. Check it is available and runnable by your PHP server. If PHP Safe Mode is enabled, check that command is inside a directory defined by parameter safe_mode_exec_dir.\nFailed to run external command. Check it is available and runnable by your PHP server. If PHP Safe Mode is enabled, check that command is inside a directory defined by parameter safe_mode_exec_dir.','604800',1,2,1,NULL,12,'MakeLocalDatabaseDump',NULL,0,0,0,NULL,'1',0),(43,'2018-11-23 11:58:17','2018-11-23 12:58:17','method','RecurringInvoices',NULL,'compta/facture/class/facture-rec.class.php','FactureRec','createRecurringInvoices',NULL,NULL,'facture',50,NULL,NULL,'2018-11-23 23:00:00',NULL,NULL,NULL,NULL,'86400',1,NULL,1,NULL,NULL,'Generate recurring invoices',NULL,1,0,0,NULL,'$conf->facture->enabled',0),(45,'2020-01-01 12:00:34','2020-01-01 16:00:34','method','MyJob label',NULL,'/captureserver/class/myobject.class.php','MyObject','doScheduledJob',NULL,NULL,'captureserver',0,NULL,NULL,'2020-01-01 16:00:34',NULL,NULL,NULL,NULL,'3600',2,NULL,0,NULL,NULL,'Comment',NULL,1,0,0,NULL,'$conf->captureserver->enabled',0),(46,'2020-01-12 20:13:55','2020-01-13 00:13:55','method','Email collector',NULL,'/emailcollector/class/emailcollector.class.php','EmailCollector','doCollect',NULL,NULL,'emailcollector',50,NULL,NULL,'2020-01-13 00:13:55',NULL,NULL,NULL,NULL,'60',5,NULL,1,NULL,NULL,'Comment',NULL,1,0,0,NULL,'$conf->emailcollector->enabled',0),(47,'2021-04-15 10:34:00','2021-04-15 07:34:00','method','CompressSyslogs',NULL,'core/class/utils.class.php','Utils','compressSyslogs',NULL,NULL,'syslog',50,NULL,NULL,'2021-04-15 07:34:00',NULL,NULL,NULL,NULL,'86400',1,NULL,0,NULL,NULL,'Compress and archive log files. The number of versions to keep is defined into the setup of module. Warning: Main application cron script must be run with same account than your web server to avoid to get log files with different owner than required by web server. Another solution is to set web server Operating System group as the group of directory documents and set GROUP permission \"rws\" on this directory so log files will always have the group and permissions of the web server Operating System group.',NULL,1,0,0,NULL,'1',0),(48,'2021-07-11 17:49:46','2021-07-11 19:49:46','method','SendEmailsRemindersOnInvoiceDueDate',NULL,'compta/facture/class/facture.class.php','Facture','sendEmailsRemindersOnInvoiceDueDate','10,all,EmailTemplateCode',NULL,'facture',50,NULL,NULL,'2021-07-11 23:00:00',NULL,NULL,NULL,NULL,'86400',1,NULL,0,NULL,NULL,'Send an emails when the unpaid invoices reach a due date + n days = today. First param is the offset n of days, second parameter is \"all\" or a payment mode code, last paramater is the code of email template to use (an email template with EmailTemplateCode must exists. the version in the language of the thirdparty will be used in priority).',NULL,1,0,0,NULL,'$conf->facture->enabled',0),(49,'2022-02-07 13:38:17','2022-02-07 13:38:17','method','HolidayBalanceMonthlyUpdate',NULL,'holiday/class/holiday.class.php','Holiday','updateBalance',NULL,NULL,'holiday',50,NULL,NULL,'2022-02-07 04:00:00',NULL,NULL,NULL,NULL,'86400',1,NULL,1,NULL,NULL,'Update holiday balance every month',NULL,1,0,0,NULL,'$conf->holiday->enabled',0); /*!40000 ALTER TABLE `llx_cronjob` ENABLE KEYS */; UNLOCK TABLES; @@ -5165,7 +5215,7 @@ CREATE TABLE `llx_document_model` ( `description` text COLLATE utf8_unicode_ci DEFAULT NULL, PRIMARY KEY (`rowid`), UNIQUE KEY `uk_document_model` (`nom`,`type`,`entity`) -) ENGINE=InnoDB AUTO_INCREMENT=410 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=418 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -5174,7 +5224,7 @@ CREATE TABLE `llx_document_model` ( LOCK TABLES `llx_document_model` WRITE; /*!40000 ALTER TABLE `llx_document_model` DISABLE KEYS */; -INSERT INTO `llx_document_model` VALUES (9,'merou',1,'shipping',NULL,NULL),(181,'generic_invoice_odt',1,'invoice','ODT templates','FACTURE_ADDON_PDF_ODT_PATH'),(193,'canelle2',1,'invoice_supplier','canelle2',NULL),(195,'canelle',1,'invoice_supplier','canelle',NULL),(198,'azur',2,'propal',NULL,NULL),(199,'html_cerfafr',2,'donation',NULL,NULL),(200,'crabe',2,'invoice',NULL,NULL),(201,'generic_odt',1,'company','ODT templates','COMPANY_ADDON_PDF_ODT_PATH'),(250,'baleine',1,'project',NULL,NULL),(255,'soleil',1,'ficheinter',NULL,NULL),(256,'azur',1,'propal',NULL,NULL),(273,'beluga',1,'project','beluga',NULL),(281,'sepamandate',1,'bankaccount','sepamandate',NULL),(299,'standard',1,'member',NULL,NULL),(319,'generic_bom_odt',1,'bom','ODT templates','BOM_ADDON_PDF_ODT_PATH'),(320,'generic_mo_odt',1,'mrp','ODT templates','MRP_MO_ADDON_PDF_ODT_PATH'),(366,'generic_user_odt',1,'user',NULL,NULL),(367,'generic_usergroup_odt',1,'group',NULL,NULL),(370,'aurore',1,'supplier_proposal',NULL,NULL),(371,'rouget',1,'shipping',NULL,NULL),(372,'typhon',1,'delivery',NULL,NULL),(393,'squille',1,'reception',NULL,NULL),(402,'einstein',1,'order',NULL,NULL),(403,'html_cerfafr',1,'donation',NULL,NULL),(404,'standard',1,'expensereport',NULL,NULL),(405,'crabe',1,'invoice',NULL,NULL),(406,'muscadet',1,'order_supplier',NULL,NULL),(407,'standard_recruitmentjobposition',1,'recruitmentjobposition',NULL,NULL),(408,'generic_recruitmentjobposition_odt',1,'recruitmentjobposition',NULL,NULL),(409,'TICKET_ADDON_PDF_ODT_PATH',1,'ticket',NULL,NULL); +INSERT INTO `llx_document_model` VALUES (9,'merou',1,'shipping',NULL,NULL),(181,'generic_invoice_odt',1,'invoice','ODT templates','FACTURE_ADDON_PDF_ODT_PATH'),(193,'canelle2',1,'invoice_supplier','canelle2',NULL),(195,'canelle',1,'invoice_supplier','canelle',NULL),(198,'azur',2,'propal',NULL,NULL),(199,'html_cerfafr',2,'donation',NULL,NULL),(200,'crabe',2,'invoice',NULL,NULL),(201,'generic_odt',1,'company','ODT templates','COMPANY_ADDON_PDF_ODT_PATH'),(250,'baleine',1,'project',NULL,NULL),(255,'soleil',1,'ficheinter',NULL,NULL),(256,'azur',1,'propal',NULL,NULL),(273,'beluga',1,'project','beluga',NULL),(281,'sepamandate',1,'bankaccount','sepamandate',NULL),(299,'standard',1,'member',NULL,NULL),(319,'generic_bom_odt',1,'bom','ODT templates','BOM_ADDON_PDF_ODT_PATH'),(320,'generic_mo_odt',1,'mrp','ODT templates','MRP_MO_ADDON_PDF_ODT_PATH'),(366,'generic_user_odt',1,'user',NULL,NULL),(367,'generic_usergroup_odt',1,'group',NULL,NULL),(370,'aurore',1,'supplier_proposal',NULL,NULL),(371,'rouget',1,'shipping',NULL,NULL),(372,'typhon',1,'delivery',NULL,NULL),(393,'squille',1,'reception',NULL,NULL),(410,'einstein',1,'order',NULL,NULL),(411,'html_cerfafr',1,'donation',NULL,NULL),(412,'standard',1,'expensereport',NULL,NULL),(413,'crabe',1,'invoice',NULL,NULL),(414,'muscadet',1,'order_supplier',NULL,NULL),(415,'standard_recruitmentjobposition',1,'recruitmentjobposition',NULL,NULL),(416,'generic_recruitmentjobposition_odt',1,'recruitmentjobposition',NULL,NULL),(417,'TICKET_ADDON_PDF_ODT_PATH',1,'ticket',NULL,NULL); /*!40000 ALTER TABLE `llx_document_model` ENABLE KEYS */; UNLOCK TABLES; @@ -5362,7 +5412,7 @@ CREATE TABLE `llx_ecm_files` ( PRIMARY KEY (`rowid`), UNIQUE KEY `uk_ecm_files` (`filepath`,`filename`,`entity`), KEY `idx_ecm_files_label` (`label`) -) ENGINE=InnoDB AUTO_INCREMENT=113 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=161 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -5371,7 +5421,7 @@ CREATE TABLE `llx_ecm_files` ( LOCK TABLES `llx_ecm_files` WRITE; /*!40000 ALTER TABLE `llx_ecm_files` DISABLE KEYS */; -INSERT INTO `llx_ecm_files` VALUES (1,NULL,'6ff09d1c53ef83fe622b02a320bcfa52',NULL,1,'FA1107-0019.pdf','facture/FA1107-0019','/home/ldestailleur/git/dolibarr_6.0/documents/facture/FA1107-0019/FA1107-0019.pdf','',NULL,NULL,'unknown',NULL,'2017-08-30 15:53:34','2017-08-30 11:53:34',18,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(2,NULL,'a6c8a0f04af73e4dfc059006d7a5f55a',NULL,1,'FA1107-0019_invoice.odt','facture/FA1107-0019','/home/ldestailleur/git/dolibarr_6.0/documents/facture/FA1107-0019/FA1107-0019_invoice.odt','',NULL,NULL,'unknown',NULL,'2017-08-30 15:53:34','2017-08-30 11:53:34',18,NULL,NULL,NULL,NULL,2,NULL,NULL,NULL),(3,NULL,'24e96a4a0da25d1ac5049ea46d031d3a',NULL,1,'FA1107-0019-depotFacture-1418-INH-N000289-20170720.pdf','facture/FA1107-0019','depotFacture-1418-INH-N000289-20170720.pdf','',NULL,NULL,'uploaded',NULL,'2017-08-30 15:54:45','2017-08-30 11:54:45',18,NULL,NULL,NULL,NULL,3,NULL,NULL,NULL),(4,NULL,'91a42a4e2c77e826562c83fa84f6fccd',NULL,1,'CO7001-0027-acces-coopinfo.txt','commande/CO7001-0027','acces-coopinfo.txt','',NULL,NULL,'uploaded',NULL,'2017-08-30 16:02:33','2017-08-30 12:02:33',18,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(5,'5fe17a68b2f6a73e6326f77fa7b6586c','a60cad66c6da948eb08d5b939f3516ff',NULL,1,'FA1601-0024.pdf','facture/FA1601-0024','','',NULL,NULL,'generated',NULL,'2017-08-30 16:23:01','2018-03-16 09:59:31',12,12,NULL,NULL,NULL,1,NULL,NULL,NULL),(6,NULL,'24e96a4a0da25d1ac5049ea46d031d3a',NULL,1,'FA1601-0024-depotFacture-1418-INH-N000289-20170720.pdf','facture/FA1601-0024','depotFacture-1418-INH-N000289-20170720.pdf','',NULL,NULL,'uploaded',NULL,'2017-08-30 16:23:14','2017-08-30 12:23:14',12,NULL,NULL,NULL,NULL,2,NULL,NULL,NULL),(7,NULL,'d41d8cd98f00b204e9800998ecf8427e',NULL,1,'Exxxqqqw','produit/COMP-XP4523','/home/ldestailleur/git/dolibarr_6.0/documents/produit/COMP-XP4523/Exxxqqqw','',NULL,NULL,'unknown',NULL,'2017-08-30 19:03:15','2017-08-30 15:04:02',12,NULL,NULL,NULL,NULL,2,NULL,NULL,NULL),(8,NULL,'8245ba8e8e345655f06cd904d7d54f73',NULL,1,'compxp4523product.jpg','produit/COMP-XP4523','/home/ldestailleur/git/dolibarr_6.0/documents/produit/COMP-XP4523/compxp4523product.jpg','',NULL,NULL,'unknown',NULL,'2017-08-30 19:03:15','2017-08-30 15:04:02',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(9,NULL,'d32552ee874c82b9f0ccab4f309b4b61',NULL,1,'dolihelp.ico','produit/COMP-XP4523','/home/ldestailleur/git/dolibarr_6.0/documents/produit/COMP-XP4523/dolihelp.ico','',NULL,NULL,'unknown',NULL,'2017-08-30 19:03:15','2017-08-30 15:03:15',12,NULL,NULL,NULL,NULL,3,NULL,NULL,NULL),(10,'afef987559622d6334fdc4a9a134c435','ccd46bbf3ab6c78588a0ba775106258f',NULL,1,'rolluproduct.jpg','produit/ROLLUPABC','/home/dolibarr/demo.dolibarr.org/dolibarr_documents/produit/ROLLUPABC/rolluproduct.jpg','',NULL,NULL,'unknown',NULL,'2018-01-19 11:23:16','2018-01-19 11:23:16',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(11,'a8bbc6c6daea9a4dd58d6fb37a77a030','2f1f2ea4b1b4eb9f25ba440c7870ffcd',NULL,1,'dolicloud_logo.png','produit/DOLICLOUD','/home/dolibarr/demo.dolibarr.org/dolibarr_documents/produit/DOLICLOUD/dolicloud_logo.png','',NULL,NULL,'unknown',NULL,'2018-01-19 11:23:16','2018-01-19 11:23:16',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(12,'bd0951e23023b22ad1cd21fe33ee46bf','03f0be1249e56fd0b3dd02d5545e3675',NULL,1,'applepieproduct.jpg','produit/CAKECONTRIB','/home/dolibarr/demo.dolibarr.org/dolibarr_documents/produit/CAKECONTRIB/applepieproduct.jpg','',NULL,NULL,'unknown',NULL,'2018-01-19 11:23:16','2018-01-19 11:23:16',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(13,'e9e029e2d2bbd014162c0b385ab8739a','b7446fb7b54a3085ff7167e2c5b370fd',NULL,1,'pearpieproduct.jpg','produit/PEARPIE','/home/dolibarr/demo.dolibarr.org/dolibarr_documents/produit/PEARPIE/pearpieproduct.jpg','',NULL,NULL,'unknown',NULL,'2018-01-19 11:23:16','2018-01-19 11:23:16',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(14,'14eea962fb99dc6dd8ca4474c519f837','973b1603b5eb01aac97eb2d911f4c341',NULL,1,'pinkdressproduct.jpg','produit/PINKDRESS','/home/dolibarr/demo.dolibarr.org/dolibarr_documents/produit/PINKDRESS/pinkdressproduct.jpg','',NULL,NULL,'unknown',NULL,'2018-01-19 11:23:16','2018-01-19 11:23:16',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(18,'1972b3da7908b3e08247e6e23bb7bdc3','03f0be1249e56fd0b3dd02d5545e3675',NULL,1,'applepieproduct.jpg','produit/APPLEPIE','/home/dolibarr/demo.dolibarr.org/dolibarr_documents/produit/APPLEPIE/applepieproduct.jpg','',NULL,NULL,'unknown',NULL,'2018-01-19 11:23:16','2018-01-19 11:23:16',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(19,'ff9fad9b5ea886a0812953907e2b790a','3d14c3c12c58dfe06ef3020e712b2b06',NULL,1,'dolibarr_screenshot1_300x188.png','ticket/TS1909-0002','dolibarr_screenshot1_300x188.png','',NULL,NULL,'uploaded',NULL,'2019-09-26 14:12:04','2019-09-26 12:12:04',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(20,'b6a2578c5483bffbead5b290f6ef5286','83c8e9b3b692ebae2f6f3e298dd9f5a2',NULL,1,'(PROV10)-dolibarr_120x90.png','propale/(PROV10)','dolibarr_120x90.png','',NULL,NULL,'uploaded',NULL,'2019-09-27 16:53:51','2019-09-27 14:53:51',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(21,'89809c5b1213137736ded43bdd982f71','5f1af043d9fc7a90e8500a6dc5c4f5ae',NULL,1,'(PROV10).pdf','propale/(PROV10)','','',NULL,NULL,'generated',NULL,'2019-09-27 16:54:09','2019-09-27 14:54:09',12,NULL,NULL,NULL,NULL,2,NULL,'propal',10),(22,'8eb026e33ae1c7892c59a2ac6dda31f4','8827be83628b2f5beb67cf95b4c4cff6',NULL,1,'PR1909-0031.pdf','propale/PR1909-0031','','',NULL,NULL,'generated',NULL,'2019-09-27 16:54:30','2019-09-27 14:54:30',12,NULL,NULL,NULL,NULL,1,NULL,'propal',10),(24,'0d4e663b5c128d288a39231433da966e','3d2bd3daecd0de5078774ad58546d1f4',NULL,1,'PR1909-0032-dolibarr_192x192.png','propale/PR1909-0032','dolibarr_192x192.png','',NULL,NULL,'uploaded',NULL,'2019-09-27 17:08:42','2019-09-27 15:08:59',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(25,'44867f8c62f8538da7724c148af2c227','f4208dc9a3dc83f668ea415244016c00',NULL,1,'PR1909-0032.pdf','propale/PR1909-0032','','',NULL,NULL,'generated',NULL,'2019-09-27 17:08:59','2020-01-15 18:37:15',12,12,NULL,NULL,NULL,2,NULL,'propal',33),(26,'3983de91943fb14f8b137d1929bea5a9','730822c8124123c9c7dcf0d55234e1c6',NULL,1,'PR1909-0033.pdf','propale/PR1909-0033','','',NULL,NULL,'generated',NULL,'2019-09-27 17:11:21','2020-01-18 18:32:33',12,12,NULL,NULL,NULL,1,NULL,'propal',34),(27,'399734120da8f3027508e0772c25e291','83c8e9b3b692ebae2f6f3e298dd9f5a2',NULL,1,'PR1909-0033-dolibarr_120x90.png','propale/PR1909-0033','dolibarr_120x90.png','',NULL,NULL,'uploaded',NULL,'2019-09-27 17:13:07','2019-09-27 15:13:13',12,NULL,NULL,NULL,NULL,2,NULL,NULL,NULL),(28,'c81de886c76ccd2d46fbc5f816047a71','e063b649494c9ededb5710207b8cdb41','kr8LmXlZVAW9Sl0iZ0w8re6Jd23S3X1k',1,'(PROV35).pdf','propale/(PROV35)','','',NULL,NULL,'generated',NULL,'2019-09-27 17:53:44','2020-01-01 19:54:50',12,12,NULL,NULL,NULL,1,NULL,'propal',35),(29,'34fe1f2546e8d1562b904b7bbe79e01a','6e1acd02fdd344b18e38c0cba729f552',NULL,1,'(PROV6).pdf','commande/(PROV6)','','',NULL,NULL,'generated',NULL,'2019-09-27 18:04:35','2019-09-27 16:04:52',12,12,NULL,NULL,NULL,1,NULL,'commande',6),(30,'fd2ad5abe709d7870bcd57743d9a1176','b0ae7dd69244e0c0a9d4c5e6d08bffcb',NULL,1,'(PROV93).pdf','commande/(PROV93)','','',NULL,NULL,'generated',NULL,'2019-09-27 19:33:29','2019-09-27 17:40:49',12,12,NULL,NULL,NULL,1,NULL,'commande',93),(31,'988caa795b4080019180253aac14d729','95b9adcf40828c7e0a164d31e1c84b5c',NULL,1,'(PROV4).pdf','fournisseur/commande/(PROV4)','','',NULL,NULL,'generated',NULL,'2019-09-27 19:46:07','2020-01-20 11:19:49',12,12,NULL,NULL,NULL,1,NULL,'commande_fournisseur',4),(32,'a046e42fcd8d114312eede243fd1850c','467e542bb565cb9379722c6fdcecc3aa',NULL,1,'PR1702-0020.pdf','propale/PR1702-0020','','',NULL,NULL,'generated',NULL,'2019-09-27 19:47:00','2019-09-27 17:47:00',12,NULL,NULL,NULL,NULL,1,NULL,'propal',22),(33,'dc99eacf03a78050da53a2601d0f4b49','88c047d94ab183b015526f936a5c8923',NULL,1,'SI1601-0002.pdf','fournisseur/facture/7/1/SI1601-0002','','',NULL,NULL,'generated',NULL,'2019-10-04 10:10:25','2019-10-04 08:31:30',12,12,NULL,NULL,NULL,1,NULL,'facture_fourn',17),(34,'4ab84fd3e4079aeea831d65dfc2f6891','681578085f18bacd6d40341ef236c0d6',NULL,1,'FA6801-0010.pdf','facture/FA6801-0010','','',NULL,NULL,'generated',NULL,'2019-10-04 10:26:49','2019-10-04 08:28:14',12,12,NULL,NULL,NULL,1,NULL,'facture',150),(38,'b18da4bbfaf907c1f6706b46ae3add3c','0792f280fd9a114fbd432d5442f7445b',NULL,1,'dolibarr_256x256.png','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/12/temp/dolibarr_256x256.png','',NULL,NULL,'unknown',NULL,'2019-10-04 17:25:05','2019-10-04 15:25:05',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(40,'7205fe0a03a5bd79c7d60a0d05f06e25','df4db8f9cc75b79765e7ca11013fa0bc',NULL,1,'dolibarr_512x512.png','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/12/temp/dolibarr_512x512.png','',NULL,NULL,'unknown',NULL,'2019-10-04 17:53:13','2019-10-04 16:47:55',12,12,NULL,NULL,NULL,3,NULL,NULL,NULL),(44,'53f92236476224c177f23ab30e6553aa','3d14c3c12c58dfe06ef3020e712b2b06',NULL,1,'dolibarr_screenshot1_300x188.png','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/12/temp/dolibarr_screenshot1_300x188.png','',NULL,NULL,'unknown',NULL,'2019-10-04 18:49:30','2019-10-04 16:49:30',12,NULL,NULL,NULL,NULL,4,NULL,NULL,NULL),(45,'b33ed6e73b386cac4aab51eb62f3af50','1e71c3a5d4c8247935f89971dab4d9cd',NULL,1,'dolibarr_logo.jpg','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/12/temp/dolibarr_logo.jpg','',NULL,NULL,'unknown',NULL,'2019-10-04 19:00:22','2019-10-04 17:00:22',12,NULL,NULL,NULL,NULL,5,NULL,NULL,NULL),(46,'4573b5a5d66e4598bc98075b33d2470f','3d14c3c12c58dfe06ef3020e712b2b06',NULL,1,'dolibarr_screenshot1_300x188.png.20191004190108','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/12/temp/dolibarr_screenshot1_300x188.png','',NULL,NULL,'unknown',NULL,'2019-10-04 19:01:08','2019-10-04 17:01:08',12,NULL,NULL,NULL,NULL,6,NULL,NULL,NULL),(47,'a9be21b2a984fd57d2ff450bcfb59ef5','1e71c3a5d4c8247935f89971dab4d9cd',NULL,1,'dolibarr_logo.jpg.20191004193013','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/12/temp/dolibarr_logo.jpg','',NULL,NULL,'unknown',NULL,'2019-10-04 19:30:13','2019-10-04 17:30:13',12,NULL,NULL,NULL,NULL,7,NULL,NULL,NULL),(48,'f598ad9040ed50087ae163d9bef3eb7c','fe0b95bda4dc7823739eadedfab7e823',NULL,1,'dolibarr_screenshot9_1680x1050.png','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/12/temp/dolibarr_screenshot9_1680x1050.png','',NULL,NULL,'unknown',NULL,'2019-10-04 19:32:55','2019-10-04 17:32:55',12,NULL,NULL,NULL,NULL,8,NULL,NULL,NULL),(49,'95d0d57347686999f3609897cae8ec22','d32552ee874c82b9f0ccab4f309b4b61',NULL,1,'dolihelp.ico','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/0/temp/dolihelp.ico','',NULL,NULL,'unknown',NULL,'2019-10-04 19:37:16','2019-10-04 17:37:16',0,NULL,NULL,NULL,NULL,9,NULL,NULL,NULL),(50,'1a30c5a296fa61f1d76b4f3c27a15701','8ea43be5bd1fb83a287a95cea7688cc4',NULL,1,'dolibarr.gif','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/12/temp/dolibarr.gif','',NULL,NULL,'unknown',NULL,'2019-10-04 19:39:07','2019-10-04 17:39:07',12,NULL,NULL,NULL,NULL,10,NULL,NULL,NULL),(51,'3ad99f8446832892a610dbadcbd255f0','3dea7d1b511d19f8bd3252683423958a',NULL,1,'doliadmin.ico','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/12/temp/doliadmin.ico','',NULL,NULL,'unknown',NULL,'2019-10-04 19:39:07','2019-10-04 17:39:07',12,NULL,NULL,NULL,NULL,11,NULL,NULL,NULL),(52,'4d147b3a8443635ff19fde49438394d0','ee8eab1acbf409681bcd13b6b210b8a1',NULL,1,'SI1911-0005.pdf','fournisseur/facture/1/2/SI1911-0005','','',NULL,NULL,'generated',NULL,'2019-11-28 15:54:30','2019-11-28 11:54:47',12,12,NULL,NULL,NULL,1,NULL,'facture_fourn',21),(53,'9324bc1030b77ebaef372d0ae40eb62e','db17ee9f430030fb21a6683d433c7457',NULL,1,'FR-CAR-Carrot.jpg','produit/FR-CAR','Carrot.jpg','',NULL,NULL,'uploaded',NULL,'2019-11-28 16:33:50','2019-11-28 15:33:50',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(54,'b1fe7acb0dd8591b04b49ef1cd1743aa','db17ee9f430030fb21a6683d433c7457',NULL,1,'FR-CAR-Carrot.jpg','produit/POS-CAR','/home/ldestailleur/git/dolibarr_11.0/documents/produit/POS-CAR/FR-CAR-Carrot.jpg','',NULL,NULL,'unknown',NULL,'2019-11-28 16:36:56','2019-11-28 15:36:56',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(55,'aba4d9af9dd0b200f44186f2db38b8f0','173299315f304f28081abca75e6ed635',NULL,1,'POS-APPLE-Apple.jpg','produit/POS-APPLE','Apple.jpg','',NULL,NULL,'uploaded',NULL,'2019-11-28 16:37:46','2019-11-28 15:37:46',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(56,'0a07968edb04e24e4caa7945f9308b5b','f25692272dc2e691d90e785660251dea',NULL,1,'POS-KIWI-Kiwi.jpg','produit/POS-KIWI','Kiwi.jpg','',NULL,NULL,'uploaded',NULL,'2019-11-28 16:38:58','2019-11-28 15:38:58',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(57,'da49d3ab86b6cb4f8269a3c1106de5bc','46026e1212b5e256a621559db254ce74',NULL,1,'POS-PEACH-Peach.jpg','produit/POS-PEACH','Peach.jpg','',NULL,NULL,'uploaded',NULL,'2019-11-28 16:39:29','2019-11-28 15:39:29',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(58,'e60f830c84b2808bf05d9751c6f3068c','c6fd1ef0add23afe632d043a9a9174e9',NULL,1,'POS-ORANGE-Orange.jpg','produit/POS-ORANGE','Orange.jpg','',NULL,NULL,'uploaded',NULL,'2019-11-28 16:40:06','2019-11-28 15:40:06',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(59,'b75a9affa8454aa109032ef11578ff55','8245ba8e8e345655f06cd904d7d54f73',NULL,1,'compxp4548product.jpg','produit/COMP-XP4548','compxp4523product.jpg','',NULL,NULL,'uploaded',NULL,'2019-11-28 16:41:23','2019-11-28 12:47:57',12,12,NULL,NULL,NULL,1,NULL,NULL,NULL),(61,'fb93ad6fc19a4b6cb10ea753706d2f82','2adadd910fe97a07bd5be0f1f27f2d28',NULL,1,'DOLIDROID-dolidroid_114x114.png','produit/DOLIDROID','dolidroid_114x114.png','',NULL,NULL,'uploaded',NULL,'2019-11-28 16:49:27','2019-11-28 15:49:27',12,NULL,NULL,NULL,NULL,4,NULL,NULL,NULL),(64,'90bf4a06479f20d6642d398b60e30d76','1cff6b63ce7bdcd6607f9ccbca942810',NULL,1,'DOLIDROID-dolidroid_180x120_en.png','produit/DOLIDROID','dolidroid_180x120_en.png','',NULL,NULL,'uploaded',NULL,'2019-11-28 16:50:33','2019-11-28 15:50:33',12,NULL,NULL,NULL,NULL,5,NULL,NULL,NULL),(65,'7516f3382f24055570c580f3f7a3ca6e','df61e1aca1992b564dc6d80cd6c6ae0b',NULL,1,'DOLIDROID-dolidroid_screenshot_stats_720x1280.png','produit/DOLIDROID','dolidroid_screenshot_stats_720x1280.png','',NULL,NULL,'uploaded',NULL,'2019-11-28 16:51:58','2019-11-28 15:51:58',12,NULL,NULL,NULL,NULL,6,NULL,NULL,NULL),(66,'61ec0d999c2460e0a942be9760b7c1fb','8ef12c42fbada32094a633a60f5c84a7',NULL,1,'POS-Eggs-Eggs.jpg','produit/POS-Eggs','Eggs.jpg','',NULL,NULL,'uploaded',NULL,'2019-11-28 17:04:06','2019-11-28 16:04:06',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(67,'abe8d329cfb52c1ba59867dfb2468047','8a0380cc9887f325e220c0f7503835c7',NULL,1,'POS-Chips-Chips.jpg','produit/POS-Chips','Chips.jpg','',NULL,NULL,'uploaded',NULL,'2019-11-28 17:09:19','2019-11-28 16:09:19',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(71,'1008ec7576e1b970f952044d10245f72','653abb50f7c2cc410dac1fd913ad8769',NULL,1,'BOM1911-0001_bom.odt','bom/BOM1911-0001','','',NULL,NULL,'generated',NULL,'2019-11-28 18:20:01','2020-01-08 15:41:49',12,12,NULL,NULL,NULL,1,NULL,'bom_bom',6),(72,'a0942ded45efc068ca59dd3360cbb0e2','db17ee9f430030fb21a6683d433c7457',NULL,1,'FR-CAR-Carrot.jpg','produit/POS-CARROT','/home/ldestailleur/git/dolibarr_11.0/documents/produit/POS-CARROT/FR-CAR-Carrot.jpg','',NULL,NULL,'unknown',NULL,'2019-11-28 19:02:01','2019-11-28 18:02:01',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(73,'c928f00b0bc1a40061408e63a9c204ee','0221dc3c79e0123b451b5630bf2177b0',NULL,1,'ER1912-0001-IMG_20191219_161331.jpg','expensereport/ER1912-0001','IMG_20191219_161331.jpg','',NULL,NULL,'uploaded',NULL,'2019-12-20 20:04:42','2019-12-20 16:34:05',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(74,'4d710f4f262d3caca82b2c7380e0addc','4ff0ba258dc0f8d3b78d919557ee7996',NULL,1,'ER1912-0001.pdf','expensereport/ER1912-0001','','',NULL,NULL,'generated',NULL,'2019-12-20 20:04:46','2019-12-20 16:34:26',12,12,NULL,NULL,NULL,2,NULL,'expensereport',2),(75,'bcb6930c79f5a3f55f9327561a07daa1','0e81807ac4e0380ddd3d841a20f339c2',NULL,1,'CO7001-0027.pdf','commande/CO7001-0027','','',NULL,NULL,'generated',NULL,'2019-12-20 20:42:23','2020-01-15 18:41:17',12,12,NULL,NULL,NULL,2,NULL,'commande',88),(76,'eabd0e0a63029bf40288c3394dcb984c','96cd89d2ba43d4f9f0f19b49a6d3754a','1Hlh7n01E5KY5i9rtvhiq1TYL16JMToN',1,'PR1702-0027.pdf','propale/PR1702-0027','','',NULL,NULL,'generated',NULL,'2019-12-20 20:49:43','2019-12-20 16:50:23',12,12,NULL,NULL,NULL,1,NULL,'propal',29),(77,'69b67f70d71893409d37bbab8af92b70','f8c94ef0d5146049288aa8042ce63892',NULL,1,'FS1301-0001.pdf','facture/FS1301-0001','','',NULL,NULL,'generated',NULL,'2019-12-21 19:40:22','2019-12-21 18:40:22',12,NULL,NULL,NULL,NULL,1,NULL,'facture',148),(78,'d5a97833baecb8e92c859c755ece9666','e511f26c4964058a24535f8db8324f89',NULL,1,'thirdparty.ods','societe/10','','',NULL,NULL,'generated',NULL,'2019-12-21 20:32:17','2019-12-21 19:32:17',12,NULL,NULL,NULL,NULL,1,NULL,'societe',10),(81,'87209bfcfd010c1b6ef3c7fec33d5249','a40fb5e1465053cff2bbcaafc25818c5',NULL,1,'SI2001-0006.pdf','fournisseur/facture/2/2/SI2001-0006','','',NULL,NULL,'generated',NULL,'2020-01-01 17:48:01','2020-01-16 17:09:02',12,12,NULL,NULL,NULL,1,NULL,'facture_fourn',22),(82,'1dabc11d324fded7042876ef648c2fde','e272a4e34acef46c0d7c21dd0100e0d1',NULL,1,'SA2001-0001.pdf','fournisseur/facture/3/2/SA2001-0001','','',NULL,NULL,'generated',NULL,'2020-01-01 17:49:33','2020-01-01 13:50:41',12,12,NULL,NULL,NULL,1,NULL,'facture_fourn',23),(83,'78b31a74494c6e3fb731c291167e5fac','7664e71072c8b51613f12429e5b10b71',NULL,1,'(PROV3).pdf','fournisseur/commande/(PROV3)','','',NULL,NULL,'generated',NULL,'2020-01-01 20:11:15','2020-01-20 11:22:53',12,12,NULL,NULL,NULL,1,NULL,'commande_fournisseur',3),(84,'dae316f89653eb19b2784c4fb41c9488','3ab1a48c8fcf3c9480243949f4ef685f',NULL,1,'SA2001-0001.pdf','fournisseur/facture/4/2/SA2001-0001','','',NULL,NULL,'generated',NULL,'2020-01-01 20:17:15','2020-01-01 16:17:46',12,12,NULL,NULL,NULL,1,NULL,'facture_fourn',24),(85,'d0f2428e33e2b6244ac4b72fab4f0f14','45ad94c796cf1918e8888bb906cfea30',NULL,1,'(PROV25).pdf','fournisseur/facture/5/2/(PROV25)','','',NULL,NULL,'generated',NULL,'2020-01-01 20:19:51','2020-01-01 19:19:51',12,NULL,NULL,NULL,NULL,1,NULL,'facture_fourn',25),(86,'bb7830bd179da2e9f9ef3579ea2f8208','cd5145fa64d57ee69a572f9cbc67b15c',NULL,1,'SA2001-0001.pdf','fournisseur/facture/6/2/SA2001-0001','','',NULL,NULL,'generated',NULL,'2020-01-01 20:20:13','2020-01-01 16:20:22',12,12,NULL,NULL,NULL,1,NULL,'facture_fourn',26),(87,'66cbad4f05ade84391d4ea3c502fb7a3','872e8072820f9b3014e8250ee7b00f86',NULL,1,'SA2001-0001.pdf','fournisseur/facture/7/2/SA2001-0001','','',NULL,NULL,'generated',NULL,'2020-01-01 20:21:51','2020-01-15 18:23:28',12,12,NULL,NULL,NULL,1,NULL,'facture_fourn',27),(88,'78dedfa0065ebb065040515c8a4fe0f4','116c1b16fb98a36f5a429ebe674a5036',NULL,1,'SI2001-0007.pdf','fournisseur/facture/8/2/SI2001-0007','','',NULL,NULL,'generated',NULL,'2020-01-01 20:22:48','2020-01-01 17:20:36',12,12,NULL,NULL,NULL,1,NULL,'facture_fourn',28),(89,'2650611699dbc2cb0d6db2c93cb8ff9d','e6f96dca09e39bfeb3003e38eecd4b84',NULL,1,'(PROV29).pdf','fournisseur/facture/9/2/(PROV29)','','',NULL,NULL,'generated',NULL,'2020-01-01 20:50:57','2020-01-01 19:50:57',12,NULL,NULL,NULL,NULL,1,NULL,'facture_fourn',29),(90,'d3d6a55beba28be5ce57e806ad037a70','9f3a682f921c24d07722d259574488ed',NULL,1,'SA2001-0002.pdf','fournisseur/facture/0/3/SA2001-0002','','',NULL,NULL,'generated',NULL,'2020-01-01 20:51:32','2020-01-01 16:51:37',12,12,NULL,NULL,NULL,1,NULL,'facture_fourn',30),(91,'4d9767cf70227675ca1e51996970cca4','707f6a5be123159b4ba3ac5bbc55e12f',NULL,1,'PR2001-0034.pdf','propale/PR2001-0034','','',NULL,NULL,'generated',NULL,'2020-01-01 23:55:35','2020-01-19 13:24:27',12,12,NULL,NULL,NULL,1,NULL,'propal',36),(92,'c3a7802251274920507482a72761c511','be7b12881c652a68f0256e00e22acfc9',NULL,1,'(PROV37).pdf','propale/(PROV37)','','',NULL,NULL,'generated',NULL,'2020-01-06 00:44:16','2020-01-05 20:46:07',12,12,NULL,NULL,NULL,1,NULL,'propal',37),(93,'43e9e215d44cbe8854dc64bfe01a7c1a','218b07855dea60994770bf4608757452',NULL,1,'SI1601-0004.pdf','fournisseur/facture/9/1/SI1601-0004','','',NULL,NULL,'generated',NULL,'2020-01-06 00:48:42','2020-01-05 23:48:42',12,NULL,NULL,NULL,NULL,1,NULL,'facture_fourn',19),(94,'29441461d34abe37158ca6bb35938a3a','6b805071f64924fa1309d51fef1ea839',NULL,1,'courrier_consult.odt','societe/29','','',NULL,NULL,'generated',NULL,'2020-01-06 21:23:24','2020-01-06 17:46:52',12,12,NULL,NULL,NULL,1,NULL,'societe',29),(95,'e5b8ef885741a002f6129051b85e5e09','6603225670e52fcb3a5e2f25de806668',NULL,1,'(PROV38).pdf','propale/(PROV38)','','',NULL,NULL,'generated',NULL,'2020-01-13 17:25:28','2020-01-13 16:25:28',12,NULL,NULL,NULL,NULL,1,NULL,'propal',38),(96,'94c2a18a5f7bd023b512e46a1cc1e5c8','1d9edda94d935fe9d75d5478df4f89ac',NULL,1,'(PROV2).pdf','supplier_proposal/(PROV2)','','',NULL,NULL,'generated',NULL,'2020-01-15 22:48:12','2020-01-20 11:19:25',12,12,NULL,NULL,NULL,1,NULL,'supplier_proposal',2),(97,'72e38084f638adb55e3e621dd3f42ab5','d278e84671f7dc4acc4882f047334846',NULL,1,'AC2001-0001.pdf','facture/AC2001-0001','','',NULL,NULL,'generated',NULL,'2020-01-16 02:22:16','2020-01-16 01:23:11',12,12,NULL,NULL,NULL,1,NULL,'facture',221),(98,'d9ceb752bbb85ea0fb29c8cb27d22e1e','0719ac0dccd4a4e1b8fbdc3a8e9fa7c1',NULL,1,'AC2001-0002.pdf','facture/AC2001-0002','','',NULL,NULL,'generated',NULL,'2020-01-16 02:33:27','2020-01-16 01:36:48',12,12,NULL,NULL,NULL,1,NULL,'facture',224),(99,'33d354694658b4697adcd9a50a292113','8abae3ad7ad4a33ad42ab166ddaee54c',NULL,1,'(PROV225).pdf','facture/(PROV225)','','',NULL,NULL,'generated',NULL,'2020-01-16 02:37:55','2020-01-16 01:37:55',12,NULL,NULL,NULL,NULL,1,NULL,'facture',225),(100,'f4fbae718d9c9bc535d56a6638c1cdc2','df8714b30c43b5766ebb8cf64ef85e16',NULL,1,'(PROV226).pdf','facture/(PROV226)','','',NULL,NULL,'generated',NULL,'2020-01-19 14:21:03','2020-01-19 13:21:21',12,12,NULL,NULL,NULL,1,NULL,'facture',226),(101,'b51a925a795e1652820d987266a31658','30a1d7094b174bbc67824a65cbec5db3',NULL,1,'AC2001-0003.pdf','facture/AC2001-0003','','',NULL,NULL,'generated',NULL,'2020-01-19 14:23:39','2020-01-19 13:51:48',12,12,NULL,NULL,NULL,1,NULL,'facture',227),(102,'1b7f8c128060879ec7f78712fa36ecd0','8df02e7604f77bb8dd6cc1ec7d1d3c90',NULL,1,'AC2001-0004.pdf','facture/AC2001-0004','','',NULL,NULL,'generated',NULL,'2020-01-19 14:49:58','2020-01-19 14:13:07',12,12,NULL,NULL,NULL,1,NULL,'facture',228),(103,'ee00344302cff6530168fb9e08083780','230789608ee4a42a05037f934e706fa5',NULL,1,'(PROV217).pdf','facture/(PROV217)','','',NULL,NULL,'generated',NULL,'2020-01-19 14:53:10','2020-01-20 11:25:41',12,12,NULL,NULL,NULL,1,NULL,'facture',217),(104,'faf6da4cf7cf49275da5786e36b3173c','50acdf0099c27348ede81656e5b3ddf2',NULL,1,'(PROV3).pdf','supplier_proposal/(PROV3)','','',NULL,NULL,'generated',NULL,'2020-01-20 12:06:40','2020-01-20 11:19:06',12,12,NULL,NULL,NULL,1,NULL,'supplier_proposal',3),(105,'d82c57a3335bafcc3fb2b35d9573fe47','73d983b4f3018249d27f391bb33ff8f0',NULL,1,'(PROV14).pdf','fournisseur/commande/(PROV14)','','',NULL,NULL,'generated',NULL,'2020-01-20 12:20:17','2020-01-20 11:20:17',12,NULL,NULL,NULL,NULL,1,NULL,'commande_fournisseur',14),(106,'fbcfde0bfdb8e7184f5e1a72527bc53a','5300dd748dffeb292c4a4fe32f9c2ab6',NULL,1,'(PROV4).pdf','supplier_proposal/(PROV4)','','',NULL,NULL,'generated',NULL,'2020-01-20 12:23:22','2020-01-20 11:24:00',12,12,NULL,NULL,NULL,1,NULL,'supplier_proposal',4),(109,'e409be44e925329a41079f1ddacaa8f1','801b126a0db67b4ff32f36641f3b63b0',NULL,1,'FA1707-0026.pdf','facture/FA1707-0026','','',NULL,NULL,'generated',NULL,'2020-01-21 10:23:17','2020-01-21 09:23:17',12,12,NULL,NULL,NULL,1,NULL,'facture',229),(110,'36411c7ab830732de1d07fe824ec9e20','63ba10b5868d702a3d09da900efb0df2',NULL,1,'FA1807-0027.pdf','facture/FA1807-0027','','',NULL,NULL,'generated',NULL,'2020-01-21 10:23:28','2020-01-21 09:23:28',12,12,NULL,NULL,NULL,1,NULL,'facture',230),(111,'bfc5abd0ab78849b7e98839d27175fb4','d03351be391a0491047797e13b39e432',NULL,1,'FA1907-0028.pdf','facture/FA1907-0028','','',NULL,NULL,'generated',NULL,'2020-01-21 10:23:49','2020-01-21 09:23:49',12,12,NULL,NULL,NULL,1,NULL,'facture',231),(112,'4615aa05f2a0e8cf79ea3cb9c91e6434','6aec33a4925b66eaba4902eef6f95507',NULL,1,'APPLEPIE-home-bg.jpg','produit/APPLEPIE','/home/ldestailleur/git/dolibarr_14.0/documents/produit/APPLEPIE/APPLEPIE-home-bg.jpg','',NULL,NULL,'unknown',NULL,'2021-04-15 07:37:21','2021-04-15 05:37:21',12,NULL,NULL,NULL,NULL,2,NULL,NULL,NULL); +INSERT INTO `llx_ecm_files` VALUES (1,NULL,'6ff09d1c53ef83fe622b02a320bcfa52',NULL,1,'FA1107-0019.pdf','facture/FA1107-0019','/home/ldestailleur/git/dolibarr_6.0/documents/facture/FA1107-0019/FA1107-0019.pdf','',NULL,NULL,'unknown',NULL,'2017-08-30 15:53:34','2017-08-30 11:53:34',18,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(2,NULL,'a6c8a0f04af73e4dfc059006d7a5f55a',NULL,1,'FA1107-0019_invoice.odt','facture/FA1107-0019','/home/ldestailleur/git/dolibarr_6.0/documents/facture/FA1107-0019/FA1107-0019_invoice.odt','',NULL,NULL,'unknown',NULL,'2017-08-30 15:53:34','2017-08-30 11:53:34',18,NULL,NULL,NULL,NULL,2,NULL,NULL,NULL),(3,NULL,'24e96a4a0da25d1ac5049ea46d031d3a',NULL,1,'FA1107-0019-depotFacture-1418-INH-N000289-20170720.pdf','facture/FA1107-0019','depotFacture-1418-INH-N000289-20170720.pdf','',NULL,NULL,'uploaded',NULL,'2017-08-30 15:54:45','2017-08-30 11:54:45',18,NULL,NULL,NULL,NULL,3,NULL,NULL,NULL),(4,NULL,'91a42a4e2c77e826562c83fa84f6fccd',NULL,1,'CO7001-0027-acces-coopinfo.txt','commande/CO7001-0027','acces-coopinfo.txt','',NULL,NULL,'uploaded',NULL,'2017-08-30 16:02:33','2017-08-30 12:02:33',18,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(5,'5fe17a68b2f6a73e6326f77fa7b6586c','a60cad66c6da948eb08d5b939f3516ff',NULL,1,'FA1601-0024.pdf','facture/FA1601-0024','','',NULL,NULL,'generated',NULL,'2017-08-30 16:23:01','2018-03-16 09:59:31',12,12,NULL,NULL,NULL,1,NULL,NULL,NULL),(6,NULL,'24e96a4a0da25d1ac5049ea46d031d3a',NULL,1,'FA1601-0024-depotFacture-1418-INH-N000289-20170720.pdf','facture/FA1601-0024','depotFacture-1418-INH-N000289-20170720.pdf','',NULL,NULL,'uploaded',NULL,'2017-08-30 16:23:14','2017-08-30 12:23:14',12,NULL,NULL,NULL,NULL,2,NULL,NULL,NULL),(7,NULL,'d41d8cd98f00b204e9800998ecf8427e',NULL,1,'Exxxqqqw','produit/COMP-XP4523','/home/ldestailleur/git/dolibarr_6.0/documents/produit/COMP-XP4523/Exxxqqqw','',NULL,NULL,'unknown',NULL,'2017-08-30 19:03:15','2017-08-30 15:04:02',12,NULL,NULL,NULL,NULL,2,NULL,NULL,NULL),(8,NULL,'8245ba8e8e345655f06cd904d7d54f73',NULL,1,'compxp4523product.jpg','produit/COMP-XP4523','/home/ldestailleur/git/dolibarr_6.0/documents/produit/COMP-XP4523/compxp4523product.jpg','',NULL,NULL,'unknown',NULL,'2017-08-30 19:03:15','2017-08-30 15:04:02',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(9,NULL,'d32552ee874c82b9f0ccab4f309b4b61',NULL,1,'dolihelp.ico','produit/COMP-XP4523','/home/ldestailleur/git/dolibarr_6.0/documents/produit/COMP-XP4523/dolihelp.ico','',NULL,NULL,'unknown',NULL,'2017-08-30 19:03:15','2017-08-30 15:03:15',12,NULL,NULL,NULL,NULL,3,NULL,NULL,NULL),(10,'afef987559622d6334fdc4a9a134c435','ccd46bbf3ab6c78588a0ba775106258f',NULL,1,'rolluproduct.jpg','produit/ROLLUPABC','/home/dolibarr/demo.dolibarr.org/dolibarr_documents/produit/ROLLUPABC/rolluproduct.jpg','',NULL,NULL,'unknown',NULL,'2018-01-19 11:23:16','2018-01-19 11:23:16',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(11,'a8bbc6c6daea9a4dd58d6fb37a77a030','2f1f2ea4b1b4eb9f25ba440c7870ffcd',NULL,1,'dolicloud_logo.png','produit/DOLICLOUD','/home/dolibarr/demo.dolibarr.org/dolibarr_documents/produit/DOLICLOUD/dolicloud_logo.png','',NULL,NULL,'unknown',NULL,'2018-01-19 11:23:16','2018-01-19 11:23:16',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(12,'bd0951e23023b22ad1cd21fe33ee46bf','03f0be1249e56fd0b3dd02d5545e3675',NULL,1,'applepieproduct.jpg','produit/CAKECONTRIB','/home/dolibarr/demo.dolibarr.org/dolibarr_documents/produit/CAKECONTRIB/applepieproduct.jpg','',NULL,NULL,'unknown',NULL,'2018-01-19 11:23:16','2018-01-19 11:23:16',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(13,'e9e029e2d2bbd014162c0b385ab8739a','b7446fb7b54a3085ff7167e2c5b370fd',NULL,1,'pearpieproduct.jpg','produit/PEARPIE','/home/dolibarr/demo.dolibarr.org/dolibarr_documents/produit/PEARPIE/pearpieproduct.jpg','',NULL,NULL,'unknown',NULL,'2018-01-19 11:23:16','2018-01-19 11:23:16',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(14,'14eea962fb99dc6dd8ca4474c519f837','973b1603b5eb01aac97eb2d911f4c341',NULL,1,'pinkdressproduct.jpg','produit/PINKDRESS','/home/dolibarr/demo.dolibarr.org/dolibarr_documents/produit/PINKDRESS/pinkdressproduct.jpg','',NULL,NULL,'unknown',NULL,'2018-01-19 11:23:16','2018-01-19 11:23:16',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(18,'1972b3da7908b3e08247e6e23bb7bdc3','03f0be1249e56fd0b3dd02d5545e3675',NULL,1,'applepieproduct.jpg','produit/APPLEPIE','/home/dolibarr/demo.dolibarr.org/dolibarr_documents/produit/APPLEPIE/applepieproduct.jpg','',NULL,NULL,'unknown',NULL,'2018-01-19 11:23:16','2018-01-19 11:23:16',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(19,'ff9fad9b5ea886a0812953907e2b790a','3d14c3c12c58dfe06ef3020e712b2b06',NULL,1,'dolibarr_screenshot1_300x188.png','ticket/TS1909-0002','dolibarr_screenshot1_300x188.png','',NULL,NULL,'uploaded',NULL,'2019-09-26 14:12:04','2019-09-26 12:12:04',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(20,'b6a2578c5483bffbead5b290f6ef5286','83c8e9b3b692ebae2f6f3e298dd9f5a2',NULL,1,'(PROV10)-dolibarr_120x90.png','propale/(PROV10)','dolibarr_120x90.png','',NULL,NULL,'uploaded',NULL,'2019-09-27 16:53:51','2019-09-27 14:53:51',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(21,'89809c5b1213137736ded43bdd982f71','5f1af043d9fc7a90e8500a6dc5c4f5ae',NULL,1,'(PROV10).pdf','propale/(PROV10)','','',NULL,NULL,'generated',NULL,'2019-09-27 16:54:09','2019-09-27 14:54:09',12,NULL,NULL,NULL,NULL,2,NULL,'propal',10),(22,'8eb026e33ae1c7892c59a2ac6dda31f4','8827be83628b2f5beb67cf95b4c4cff6',NULL,1,'PR1909-0031.pdf','propale/PR1909-0031','','',NULL,NULL,'generated',NULL,'2019-09-27 16:54:30','2019-09-27 14:54:30',12,NULL,NULL,NULL,NULL,1,NULL,'propal',10),(24,'0d4e663b5c128d288a39231433da966e','3d2bd3daecd0de5078774ad58546d1f4',NULL,1,'PR1909-0032-dolibarr_192x192.png','propale/PR1909-0032','dolibarr_192x192.png','',NULL,NULL,'uploaded',NULL,'2019-09-27 17:08:42','2019-09-27 15:08:59',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(25,'44867f8c62f8538da7724c148af2c227','f4208dc9a3dc83f668ea415244016c00',NULL,1,'PR1909-0032.pdf','propale/PR1909-0032','','',NULL,NULL,'generated',NULL,'2019-09-27 17:08:59','2020-01-15 18:37:15',12,12,NULL,NULL,NULL,2,NULL,'propal',33),(26,'3983de91943fb14f8b137d1929bea5a9','730822c8124123c9c7dcf0d55234e1c6',NULL,1,'PR1909-0033.pdf','propale/PR1909-0033','','',NULL,NULL,'generated',NULL,'2019-09-27 17:11:21','2020-01-18 18:32:33',12,12,NULL,NULL,NULL,1,NULL,'propal',34),(27,'399734120da8f3027508e0772c25e291','83c8e9b3b692ebae2f6f3e298dd9f5a2',NULL,1,'PR1909-0033-dolibarr_120x90.png','propale/PR1909-0033','dolibarr_120x90.png','',NULL,NULL,'uploaded',NULL,'2019-09-27 17:13:07','2019-09-27 15:13:13',12,NULL,NULL,NULL,NULL,2,NULL,NULL,NULL),(28,'c81de886c76ccd2d46fbc5f816047a71','e063b649494c9ededb5710207b8cdb41','kr8LmXlZVAW9Sl0iZ0w8re6Jd23S3X1k',1,'(PROV35).pdf','propale/(PROV35)','','',NULL,NULL,'generated',NULL,'2019-09-27 17:53:44','2020-01-01 19:54:50',12,12,NULL,NULL,NULL,1,NULL,'propal',35),(29,'34fe1f2546e8d1562b904b7bbe79e01a','6e1acd02fdd344b18e38c0cba729f552',NULL,1,'(PROV6).pdf','commande/(PROV6)','','',NULL,NULL,'generated',NULL,'2019-09-27 18:04:35','2019-09-27 16:04:52',12,12,NULL,NULL,NULL,1,NULL,'commande',6),(30,'fd2ad5abe709d7870bcd57743d9a1176','b0ae7dd69244e0c0a9d4c5e6d08bffcb',NULL,1,'(PROV93).pdf','commande/(PROV93)','','',NULL,NULL,'generated',NULL,'2019-09-27 19:33:29','2019-09-27 17:40:49',12,12,NULL,NULL,NULL,1,NULL,'commande',93),(31,'988caa795b4080019180253aac14d729','95b9adcf40828c7e0a164d31e1c84b5c',NULL,1,'(PROV4).pdf','fournisseur/commande/(PROV4)','','',NULL,NULL,'generated',NULL,'2019-09-27 19:46:07','2020-01-20 11:19:49',12,12,NULL,NULL,NULL,1,NULL,'commande_fournisseur',4),(32,'a046e42fcd8d114312eede243fd1850c','467e542bb565cb9379722c6fdcecc3aa',NULL,1,'PR1702-0020.pdf','propale/PR1702-0020','','',NULL,NULL,'generated',NULL,'2019-09-27 19:47:00','2019-09-27 17:47:00',12,NULL,NULL,NULL,NULL,1,NULL,'propal',22),(33,'dc99eacf03a78050da53a2601d0f4b49','88c047d94ab183b015526f936a5c8923',NULL,1,'SI1601-0002.pdf','fournisseur/facture/7/1/SI1601-0002','','',NULL,NULL,'generated',NULL,'2019-10-04 10:10:25','2019-10-04 08:31:30',12,12,NULL,NULL,NULL,1,NULL,'facture_fourn',17),(34,'4ab84fd3e4079aeea831d65dfc2f6891','681578085f18bacd6d40341ef236c0d6',NULL,1,'FA6801-0010.pdf','facture/FA6801-0010','','',NULL,NULL,'generated',NULL,'2019-10-04 10:26:49','2019-10-04 08:28:14',12,12,NULL,NULL,NULL,1,NULL,'facture',150),(38,'b18da4bbfaf907c1f6706b46ae3add3c','0792f280fd9a114fbd432d5442f7445b',NULL,1,'dolibarr_256x256.png','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/12/temp/dolibarr_256x256.png','',NULL,NULL,'unknown',NULL,'2019-10-04 17:25:05','2019-10-04 15:25:05',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(40,'7205fe0a03a5bd79c7d60a0d05f06e25','df4db8f9cc75b79765e7ca11013fa0bc',NULL,1,'dolibarr_512x512.png','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/12/temp/dolibarr_512x512.png','',NULL,NULL,'unknown',NULL,'2019-10-04 17:53:13','2019-10-04 16:47:55',12,12,NULL,NULL,NULL,3,NULL,NULL,NULL),(44,'53f92236476224c177f23ab30e6553aa','3d14c3c12c58dfe06ef3020e712b2b06',NULL,1,'dolibarr_screenshot1_300x188.png','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/12/temp/dolibarr_screenshot1_300x188.png','',NULL,NULL,'unknown',NULL,'2019-10-04 18:49:30','2019-10-04 16:49:30',12,NULL,NULL,NULL,NULL,4,NULL,NULL,NULL),(45,'b33ed6e73b386cac4aab51eb62f3af50','1e71c3a5d4c8247935f89971dab4d9cd',NULL,1,'dolibarr_logo.jpg','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/12/temp/dolibarr_logo.jpg','',NULL,NULL,'unknown',NULL,'2019-10-04 19:00:22','2019-10-04 17:00:22',12,NULL,NULL,NULL,NULL,5,NULL,NULL,NULL),(46,'4573b5a5d66e4598bc98075b33d2470f','3d14c3c12c58dfe06ef3020e712b2b06',NULL,1,'dolibarr_screenshot1_300x188.png.20191004190108','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/12/temp/dolibarr_screenshot1_300x188.png','',NULL,NULL,'unknown',NULL,'2019-10-04 19:01:08','2019-10-04 17:01:08',12,NULL,NULL,NULL,NULL,6,NULL,NULL,NULL),(47,'a9be21b2a984fd57d2ff450bcfb59ef5','1e71c3a5d4c8247935f89971dab4d9cd',NULL,1,'dolibarr_logo.jpg.20191004193013','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/12/temp/dolibarr_logo.jpg','',NULL,NULL,'unknown',NULL,'2019-10-04 19:30:13','2019-10-04 17:30:13',12,NULL,NULL,NULL,NULL,7,NULL,NULL,NULL),(48,'f598ad9040ed50087ae163d9bef3eb7c','fe0b95bda4dc7823739eadedfab7e823',NULL,1,'dolibarr_screenshot9_1680x1050.png','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/12/temp/dolibarr_screenshot9_1680x1050.png','',NULL,NULL,'unknown',NULL,'2019-10-04 19:32:55','2019-10-04 17:32:55',12,NULL,NULL,NULL,NULL,8,NULL,NULL,NULL),(49,'95d0d57347686999f3609897cae8ec22','d32552ee874c82b9f0ccab4f309b4b61',NULL,1,'dolihelp.ico','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/0/temp/dolihelp.ico','',NULL,NULL,'unknown',NULL,'2019-10-04 19:37:16','2019-10-04 17:37:16',0,NULL,NULL,NULL,NULL,9,NULL,NULL,NULL),(50,'1a30c5a296fa61f1d76b4f3c27a15701','8ea43be5bd1fb83a287a95cea7688cc4',NULL,1,'dolibarr.gif','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/12/temp/dolibarr.gif','',NULL,NULL,'unknown',NULL,'2019-10-04 19:39:07','2019-10-04 17:39:07',12,NULL,NULL,NULL,NULL,10,NULL,NULL,NULL),(51,'3ad99f8446832892a610dbadcbd255f0','3dea7d1b511d19f8bd3252683423958a',NULL,1,'doliadmin.ico','ticket/TS1910-0004','/home/ldestailleur/git/dolibarr_10.0/documents/users/12/temp/doliadmin.ico','',NULL,NULL,'unknown',NULL,'2019-10-04 19:39:07','2019-10-04 17:39:07',12,NULL,NULL,NULL,NULL,11,NULL,NULL,NULL),(52,'4d147b3a8443635ff19fde49438394d0','ee8eab1acbf409681bcd13b6b210b8a1',NULL,1,'SI1911-0005.pdf','fournisseur/facture/1/2/SI1911-0005','','',NULL,NULL,'generated',NULL,'2019-11-28 15:54:30','2019-11-28 11:54:47',12,12,NULL,NULL,NULL,1,NULL,'facture_fourn',21),(53,'9324bc1030b77ebaef372d0ae40eb62e','db17ee9f430030fb21a6683d433c7457',NULL,1,'FR-CAR-Carrot.jpg','produit/FR-CAR','Carrot.jpg','',NULL,NULL,'uploaded',NULL,'2019-11-28 16:33:50','2019-11-28 15:33:50',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(54,'b1fe7acb0dd8591b04b49ef1cd1743aa','db17ee9f430030fb21a6683d433c7457',NULL,1,'FR-CAR-Carrot.jpg','produit/POS-CAR','/home/ldestailleur/git/dolibarr_11.0/documents/produit/POS-CAR/FR-CAR-Carrot.jpg','',NULL,NULL,'unknown',NULL,'2019-11-28 16:36:56','2019-11-28 15:36:56',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(55,'aba4d9af9dd0b200f44186f2db38b8f0','173299315f304f28081abca75e6ed635',NULL,1,'POS-APPLE-Apple.jpg','produit/POS-APPLE','Apple.jpg','',NULL,NULL,'uploaded',NULL,'2019-11-28 16:37:46','2019-11-28 15:37:46',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(56,'0a07968edb04e24e4caa7945f9308b5b','f25692272dc2e691d90e785660251dea',NULL,1,'POS-KIWI-Kiwi.jpg','produit/POS-KIWI','Kiwi.jpg','',NULL,NULL,'uploaded',NULL,'2019-11-28 16:38:58','2019-11-28 15:38:58',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(57,'da49d3ab86b6cb4f8269a3c1106de5bc','46026e1212b5e256a621559db254ce74',NULL,1,'POS-PEACH-Peach.jpg','produit/POS-PEACH','Peach.jpg','',NULL,NULL,'uploaded',NULL,'2019-11-28 16:39:29','2019-11-28 15:39:29',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(58,'e60f830c84b2808bf05d9751c6f3068c','c6fd1ef0add23afe632d043a9a9174e9',NULL,1,'POS-ORANGE-Orange.jpg','produit/POS-ORANGE','Orange.jpg','',NULL,NULL,'uploaded',NULL,'2019-11-28 16:40:06','2019-11-28 15:40:06',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(59,'b75a9affa8454aa109032ef11578ff55','8245ba8e8e345655f06cd904d7d54f73',NULL,1,'compxp4548product.jpg','produit/COMP-XP4548','compxp4523product.jpg','',NULL,NULL,'uploaded',NULL,'2019-11-28 16:41:23','2019-11-28 12:47:57',12,12,NULL,NULL,NULL,1,NULL,NULL,NULL),(61,'fb93ad6fc19a4b6cb10ea753706d2f82','2adadd910fe97a07bd5be0f1f27f2d28',NULL,1,'DOLIDROID-dolidroid_114x114.png','produit/DOLIDROID','dolidroid_114x114.png','',NULL,NULL,'uploaded',NULL,'2019-11-28 16:49:27','2019-11-28 15:49:27',12,NULL,NULL,NULL,NULL,4,NULL,NULL,NULL),(64,'90bf4a06479f20d6642d398b60e30d76','1cff6b63ce7bdcd6607f9ccbca942810',NULL,1,'DOLIDROID-dolidroid_180x120_en.png','produit/DOLIDROID','dolidroid_180x120_en.png','',NULL,NULL,'uploaded',NULL,'2019-11-28 16:50:33','2019-11-28 15:50:33',12,NULL,NULL,NULL,NULL,5,NULL,NULL,NULL),(65,'7516f3382f24055570c580f3f7a3ca6e','df61e1aca1992b564dc6d80cd6c6ae0b',NULL,1,'DOLIDROID-dolidroid_screenshot_stats_720x1280.png','produit/DOLIDROID','dolidroid_screenshot_stats_720x1280.png','',NULL,NULL,'uploaded',NULL,'2019-11-28 16:51:58','2019-11-28 15:51:58',12,NULL,NULL,NULL,NULL,6,NULL,NULL,NULL),(66,'61ec0d999c2460e0a942be9760b7c1fb','8ef12c42fbada32094a633a60f5c84a7',NULL,1,'POS-Eggs-Eggs.jpg','produit/POS-Eggs','Eggs.jpg','',NULL,NULL,'uploaded',NULL,'2019-11-28 17:04:06','2019-11-28 16:04:06',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(67,'abe8d329cfb52c1ba59867dfb2468047','8a0380cc9887f325e220c0f7503835c7',NULL,1,'POS-Chips-Chips.jpg','produit/POS-Chips','Chips.jpg','',NULL,NULL,'uploaded',NULL,'2019-11-28 17:09:19','2019-11-28 16:09:19',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(71,'1008ec7576e1b970f952044d10245f72','653abb50f7c2cc410dac1fd913ad8769',NULL,1,'BOM1911-0001_bom.odt','bom/BOM1911-0001','','',NULL,NULL,'generated',NULL,'2019-11-28 18:20:01','2020-01-08 15:41:49',12,12,NULL,NULL,NULL,1,NULL,'bom_bom',6),(72,'a0942ded45efc068ca59dd3360cbb0e2','db17ee9f430030fb21a6683d433c7457',NULL,1,'FR-CAR-Carrot.jpg','produit/POS-CARROT','/home/ldestailleur/git/dolibarr_11.0/documents/produit/POS-CARROT/FR-CAR-Carrot.jpg','',NULL,NULL,'unknown',NULL,'2019-11-28 19:02:01','2019-11-28 18:02:01',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(73,'c928f00b0bc1a40061408e63a9c204ee','0221dc3c79e0123b451b5630bf2177b0',NULL,1,'ER1912-0001-IMG_20191219_161331.jpg','expensereport/ER1912-0001','IMG_20191219_161331.jpg','',NULL,NULL,'uploaded',NULL,'2019-12-20 20:04:42','2019-12-20 16:34:05',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(74,'4d710f4f262d3caca82b2c7380e0addc','4ff0ba258dc0f8d3b78d919557ee7996',NULL,1,'ER1912-0001.pdf','expensereport/ER1912-0001','','',NULL,NULL,'generated',NULL,'2019-12-20 20:04:46','2019-12-20 16:34:26',12,12,NULL,NULL,NULL,2,NULL,'expensereport',2),(75,'bcb6930c79f5a3f55f9327561a07daa1','0e81807ac4e0380ddd3d841a20f339c2',NULL,1,'CO7001-0027.pdf','commande/CO7001-0027','','',NULL,NULL,'generated',NULL,'2019-12-20 20:42:23','2020-01-15 18:41:17',12,12,NULL,NULL,NULL,2,NULL,'commande',88),(76,'eabd0e0a63029bf40288c3394dcb984c','96cd89d2ba43d4f9f0f19b49a6d3754a','1Hlh7n01E5KY5i9rtvhiq1TYL16JMToN',1,'PR1702-0027.pdf','propale/PR1702-0027','','',NULL,NULL,'generated',NULL,'2019-12-20 20:49:43','2019-12-20 16:50:23',12,12,NULL,NULL,NULL,1,NULL,'propal',29),(77,'69b67f70d71893409d37bbab8af92b70','f8c94ef0d5146049288aa8042ce63892',NULL,1,'FS1301-0001.pdf','facture/FS1301-0001','','',NULL,NULL,'generated',NULL,'2019-12-21 19:40:22','2019-12-21 18:40:22',12,NULL,NULL,NULL,NULL,1,NULL,'facture',148),(78,'d5a97833baecb8e92c859c755ece9666','e511f26c4964058a24535f8db8324f89',NULL,1,'thirdparty.ods','societe/10','','',NULL,NULL,'generated',NULL,'2019-12-21 20:32:17','2019-12-21 19:32:17',12,NULL,NULL,NULL,NULL,1,NULL,'societe',10),(81,'87209bfcfd010c1b6ef3c7fec33d5249','a40fb5e1465053cff2bbcaafc25818c5',NULL,1,'SI2001-0006.pdf','fournisseur/facture/2/2/SI2001-0006','','',NULL,NULL,'generated',NULL,'2020-01-01 17:48:01','2020-01-16 17:09:02',12,12,NULL,NULL,NULL,1,NULL,'facture_fourn',22),(82,'1dabc11d324fded7042876ef648c2fde','e272a4e34acef46c0d7c21dd0100e0d1',NULL,1,'SA2001-0001.pdf','fournisseur/facture/3/2/SA2001-0001','','',NULL,NULL,'generated',NULL,'2020-01-01 17:49:33','2020-01-01 13:50:41',12,12,NULL,NULL,NULL,1,NULL,'facture_fourn',23),(83,'78b31a74494c6e3fb731c291167e5fac','7664e71072c8b51613f12429e5b10b71',NULL,1,'(PROV3).pdf','fournisseur/commande/(PROV3)','','',NULL,NULL,'generated',NULL,'2020-01-01 20:11:15','2020-01-20 11:22:53',12,12,NULL,NULL,NULL,1,NULL,'commande_fournisseur',3),(84,'dae316f89653eb19b2784c4fb41c9488','3ab1a48c8fcf3c9480243949f4ef685f',NULL,1,'SA2001-0001.pdf','fournisseur/facture/4/2/SA2001-0001','','',NULL,NULL,'generated',NULL,'2020-01-01 20:17:15','2020-01-01 16:17:46',12,12,NULL,NULL,NULL,1,NULL,'facture_fourn',24),(85,'d0f2428e33e2b6244ac4b72fab4f0f14','45ad94c796cf1918e8888bb906cfea30',NULL,1,'(PROV25).pdf','fournisseur/facture/5/2/(PROV25)','','',NULL,NULL,'generated',NULL,'2020-01-01 20:19:51','2020-01-01 19:19:51',12,NULL,NULL,NULL,NULL,1,NULL,'facture_fourn',25),(86,'bb7830bd179da2e9f9ef3579ea2f8208','cd5145fa64d57ee69a572f9cbc67b15c',NULL,1,'SA2001-0001.pdf','fournisseur/facture/6/2/SA2001-0001','','',NULL,NULL,'generated',NULL,'2020-01-01 20:20:13','2020-01-01 16:20:22',12,12,NULL,NULL,NULL,1,NULL,'facture_fourn',26),(87,'66cbad4f05ade84391d4ea3c502fb7a3','872e8072820f9b3014e8250ee7b00f86',NULL,1,'SA2001-0001.pdf','fournisseur/facture/7/2/SA2001-0001','','',NULL,NULL,'generated',NULL,'2020-01-01 20:21:51','2020-01-15 18:23:28',12,12,NULL,NULL,NULL,1,NULL,'facture_fourn',27),(88,'78dedfa0065ebb065040515c8a4fe0f4','116c1b16fb98a36f5a429ebe674a5036',NULL,1,'SI2001-0007.pdf','fournisseur/facture/8/2/SI2001-0007','','',NULL,NULL,'generated',NULL,'2020-01-01 20:22:48','2020-01-01 17:20:36',12,12,NULL,NULL,NULL,1,NULL,'facture_fourn',28),(89,'2650611699dbc2cb0d6db2c93cb8ff9d','e6f96dca09e39bfeb3003e38eecd4b84',NULL,1,'(PROV29).pdf','fournisseur/facture/9/2/(PROV29)','','',NULL,NULL,'generated',NULL,'2020-01-01 20:50:57','2020-01-01 19:50:57',12,NULL,NULL,NULL,NULL,1,NULL,'facture_fourn',29),(90,'d3d6a55beba28be5ce57e806ad037a70','9f3a682f921c24d07722d259574488ed',NULL,1,'SA2001-0002.pdf','fournisseur/facture/0/3/SA2001-0002','','',NULL,NULL,'generated',NULL,'2020-01-01 20:51:32','2020-01-01 16:51:37',12,12,NULL,NULL,NULL,1,NULL,'facture_fourn',30),(91,'4d9767cf70227675ca1e51996970cca4','707f6a5be123159b4ba3ac5bbc55e12f',NULL,1,'PR2001-0034.pdf','propale/PR2001-0034','','',NULL,NULL,'generated',NULL,'2020-01-01 23:55:35','2020-01-19 13:24:27',12,12,NULL,NULL,NULL,1,NULL,'propal',36),(92,'c3a7802251274920507482a72761c511','be7b12881c652a68f0256e00e22acfc9',NULL,1,'(PROV37).pdf','propale/(PROV37)','','',NULL,NULL,'generated',NULL,'2020-01-06 00:44:16','2020-01-05 20:46:07',12,12,NULL,NULL,NULL,1,NULL,'propal',37),(93,'43e9e215d44cbe8854dc64bfe01a7c1a','218b07855dea60994770bf4608757452',NULL,1,'SI1601-0004.pdf','fournisseur/facture/9/1/SI1601-0004','','',NULL,NULL,'generated',NULL,'2020-01-06 00:48:42','2020-01-05 23:48:42',12,NULL,NULL,NULL,NULL,1,NULL,'facture_fourn',19),(94,'29441461d34abe37158ca6bb35938a3a','6b805071f64924fa1309d51fef1ea839',NULL,1,'courrier_consult.odt','societe/29','','',NULL,NULL,'generated',NULL,'2020-01-06 21:23:24','2020-01-06 17:46:52',12,12,NULL,NULL,NULL,1,NULL,'societe',29),(95,'e5b8ef885741a002f6129051b85e5e09','6603225670e52fcb3a5e2f25de806668',NULL,1,'(PROV38).pdf','propale/(PROV38)','','',NULL,NULL,'generated',NULL,'2020-01-13 17:25:28','2020-01-13 16:25:28',12,NULL,NULL,NULL,NULL,1,NULL,'propal',38),(96,'94c2a18a5f7bd023b512e46a1cc1e5c8','1d9edda94d935fe9d75d5478df4f89ac',NULL,1,'(PROV2).pdf','supplier_proposal/(PROV2)','','',NULL,NULL,'generated',NULL,'2020-01-15 22:48:12','2020-01-20 11:19:25',12,12,NULL,NULL,NULL,1,NULL,'supplier_proposal',2),(97,'72e38084f638adb55e3e621dd3f42ab5','d278e84671f7dc4acc4882f047334846',NULL,1,'AC2001-0001.pdf','facture/AC2001-0001','','',NULL,NULL,'generated',NULL,'2020-01-16 02:22:16','2020-01-16 01:23:11',12,12,NULL,NULL,NULL,1,NULL,'facture',221),(98,'d9ceb752bbb85ea0fb29c8cb27d22e1e','0719ac0dccd4a4e1b8fbdc3a8e9fa7c1',NULL,1,'AC2001-0002.pdf','facture/AC2001-0002','','',NULL,NULL,'generated',NULL,'2020-01-16 02:33:27','2020-01-16 01:36:48',12,12,NULL,NULL,NULL,1,NULL,'facture',224),(99,'33d354694658b4697adcd9a50a292113','8abae3ad7ad4a33ad42ab166ddaee54c',NULL,1,'(PROV225).pdf','facture/(PROV225)','','',NULL,NULL,'generated',NULL,'2020-01-16 02:37:55','2020-01-16 01:37:55',12,NULL,NULL,NULL,NULL,1,NULL,'facture',225),(100,'f4fbae718d9c9bc535d56a6638c1cdc2','df8714b30c43b5766ebb8cf64ef85e16',NULL,1,'(PROV226).pdf','facture/(PROV226)','','',NULL,NULL,'generated',NULL,'2020-01-19 14:21:03','2020-01-19 13:21:21',12,12,NULL,NULL,NULL,1,NULL,'facture',226),(101,'b51a925a795e1652820d987266a31658','30a1d7094b174bbc67824a65cbec5db3',NULL,1,'AC2001-0003.pdf','facture/AC2001-0003','','',NULL,NULL,'generated',NULL,'2020-01-19 14:23:39','2020-01-19 13:51:48',12,12,NULL,NULL,NULL,1,NULL,'facture',227),(102,'1b7f8c128060879ec7f78712fa36ecd0','8df02e7604f77bb8dd6cc1ec7d1d3c90',NULL,1,'AC2001-0004.pdf','facture/AC2001-0004','','',NULL,NULL,'generated',NULL,'2020-01-19 14:49:58','2020-01-19 14:13:07',12,12,NULL,NULL,NULL,1,NULL,'facture',228),(103,'ee00344302cff6530168fb9e08083780','230789608ee4a42a05037f934e706fa5',NULL,1,'(PROV217).pdf','facture/(PROV217)','','',NULL,NULL,'generated',NULL,'2020-01-19 14:53:10','2020-01-20 11:25:41',12,12,NULL,NULL,NULL,1,NULL,'facture',217),(104,'faf6da4cf7cf49275da5786e36b3173c','50acdf0099c27348ede81656e5b3ddf2',NULL,1,'(PROV3).pdf','supplier_proposal/(PROV3)','','',NULL,NULL,'generated',NULL,'2020-01-20 12:06:40','2020-01-20 11:19:06',12,12,NULL,NULL,NULL,1,NULL,'supplier_proposal',3),(105,'d82c57a3335bafcc3fb2b35d9573fe47','73d983b4f3018249d27f391bb33ff8f0',NULL,1,'(PROV14).pdf','fournisseur/commande/(PROV14)','','',NULL,NULL,'generated',NULL,'2020-01-20 12:20:17','2020-01-20 11:20:17',12,NULL,NULL,NULL,NULL,1,NULL,'commande_fournisseur',14),(106,'fbcfde0bfdb8e7184f5e1a72527bc53a','5300dd748dffeb292c4a4fe32f9c2ab6',NULL,1,'(PROV4).pdf','supplier_proposal/(PROV4)','','',NULL,NULL,'generated',NULL,'2020-01-20 12:23:22','2020-01-20 11:24:00',12,12,NULL,NULL,NULL,1,NULL,'supplier_proposal',4),(109,'e409be44e925329a41079f1ddacaa8f1','801b126a0db67b4ff32f36641f3b63b0',NULL,1,'FA1707-0026.pdf','facture/FA1707-0026','','',NULL,NULL,'generated',NULL,'2020-01-21 10:23:17','2020-01-21 09:23:17',12,12,NULL,NULL,NULL,1,NULL,'facture',229),(110,'36411c7ab830732de1d07fe824ec9e20','63ba10b5868d702a3d09da900efb0df2',NULL,1,'FA1807-0027.pdf','facture/FA1807-0027','','',NULL,NULL,'generated',NULL,'2020-01-21 10:23:28','2020-01-21 09:23:28',12,12,NULL,NULL,NULL,1,NULL,'facture',230),(111,'bfc5abd0ab78849b7e98839d27175fb4','d03351be391a0491047797e13b39e432',NULL,1,'FA1907-0028.pdf','facture/FA1907-0028','','',NULL,NULL,'generated',NULL,'2020-01-21 10:23:49','2020-01-21 09:23:49',12,12,NULL,NULL,NULL,1,NULL,'facture',231),(112,'4615aa05f2a0e8cf79ea3cb9c91e6434','6aec33a4925b66eaba4902eef6f95507',NULL,1,'APPLEPIE-home-bg.jpg','produit/APPLEPIE','/home/ldestailleur/git/dolibarr_14.0/documents/produit/APPLEPIE/APPLEPIE-home-bg.jpg','',NULL,NULL,'unknown',NULL,'2021-04-15 07:37:21','2021-04-15 05:37:21',12,NULL,NULL,NULL,NULL,2,NULL,NULL,NULL),(113,'98147caa708e17b81d851255d78136fe','cad7a8c5fb4a6e58cb8fe31d0741efcb',NULL,1,'BOM2202-0002_bom.odt','bom/BOM2202-0002','','','',NULL,'generated',NULL,'2022-02-07 13:54:12','2022-02-07 12:54:12',12,NULL,NULL,NULL,NULL,1,NULL,'bom_bom',7),(114,'b60ce46c6df53d0d2be6b634fd59a0e2','2da69994036589fb6ed5d6447c706f1e',NULL,1,'(PROV2).pdf','expensereport/(PROV2)','/home/ldestailleur/git/dolibarr_15.0/documents/expensereport/(PROV2)/(PROV2).pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:42','2022-02-07 13:27:42',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(115,'720ab60eb30a6bcdc2fde9966bd4d507','4a896290245451eb0aeefca964da0a4c',NULL,1,'ADMIN-ER00001-150101.pdf','expensereport/ADMIN-ER00001-150101','/home/ldestailleur/git/dolibarr_15.0/documents/expensereport/ADMIN-ER00001-150101/ADMIN-ER00001-150101.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:42','2022-02-07 13:27:42',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(116,'9c3cf03e9110bea5773a9a930fabd140','a6b341e26d6a3a845fd076ffb59f67ac',NULL,1,'ADMIN-ER00002-150101.pdf','expensereport/ADMIN-ER00002-150101','/home/ldestailleur/git/dolibarr_15.0/documents/expensereport/ADMIN-ER00002-150101/ADMIN-ER00002-150101.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:42','2022-02-07 13:27:42',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(117,'d4578ab53f6062a3b9e1b639ac263cb2','dcc82dc04e009b3f802b45e89e6a8005',NULL,1,'AV1212-0001.pdf','facture/AV1212-0001','/home/ldestailleur/git/dolibarr_15.0/documents/facture/AV1212-0001/AV1212-0001.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:46','2022-02-07 13:27:46',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(118,'6979efa40f8cd6b7e6190e65a74a1871','2e348700e6ffe06940e5b4664f1e4c00',NULL,1,'AV1212-0002.pdf','facture/AV1212-0002','/home/ldestailleur/git/dolibarr_15.0/documents/facture/AV1212-0002/AV1212-0002.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:46','2022-02-07 13:27:46',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(119,'8a25b6f715af52a124e607a9fb8cf44d','24eaab70810d4dd5a408e8dea2421845',NULL,1,'AV1303-0003.pdf','facture/AV1303-0003','/home/ldestailleur/git/dolibarr_15.0/documents/facture/AV1303-0003/AV1303-0003.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:46','2022-02-07 13:27:46',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(120,'4cc45b89255c7c9c5fac40ad5d00e117','32c3c469f61df969d34b1844168a500f',NULL,1,'FA1007-0002.pdf','facture/FA1007-0002','/home/ldestailleur/git/dolibarr_15.0/documents/facture/FA1007-0002/FA1007-0002.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:46','2022-02-07 13:27:46',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(121,'0fb69e8b0122c99e8a6621c3725c0c99','20d63c662089ba079458f5b5823941ea',NULL,1,'FA1107-0006.pdf','facture/FA1107-0006','/home/ldestailleur/git/dolibarr_15.0/documents/facture/FA1107-0006/FA1107-0006.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:46','2022-02-07 13:27:46',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(122,'9fce585dc7f4ff978f3ea0a661bf236f','7b6d2d3e08e27f88065147a8489bcdad',NULL,1,'FA1108-0003.pdf','facture/FA1108-0003','/home/ldestailleur/git/dolibarr_15.0/documents/facture/FA1108-0003/FA1108-0003.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:46','2022-02-07 13:27:46',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(123,'37f49ada746d85306d3caf00db00dc31','9ec04bd1d260b2f5b834be1ed19270b2',NULL,1,'FA1108-0004.pdf','facture/FA1108-0004','/home/ldestailleur/git/dolibarr_15.0/documents/facture/FA1108-0004/FA1108-0004.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:46','2022-02-07 13:27:46',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(124,'d4a0bbcb3766d837ed6dbc78a14af28d','dfcb5cae33b8f169ff605b7b5772b4b5',NULL,1,'FA1108-0005.pdf','facture/FA1108-0005','/home/ldestailleur/git/dolibarr_15.0/documents/facture/FA1108-0005/FA1108-0005.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:46','2022-02-07 13:27:46',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(125,'ff2407993881ea0529178311eff5b802','76d07fe1d122421c440f9e14cf9c7f86',NULL,1,'FA1108-0007.pdf','facture/FA1108-0007','/home/ldestailleur/git/dolibarr_15.0/documents/facture/FA1108-0007/FA1108-0007.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:46','2022-02-07 13:27:46',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(126,'9245fd14ecc9e3dd6920e65fb84ec932','3ec8dd059a2de25f93b367a7b5abc7f6',NULL,1,'FA1212-0009.pdf','facture/FA1212-0009','/home/ldestailleur/git/dolibarr_15.0/documents/facture/FA1212-0009/FA1212-0009.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:46','2022-02-07 13:27:46',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(127,'39351c10bac1952a9c3e7505b77a3495','f08a3d14a5ae0f288cd117b9815108eb',NULL,1,'FA1212-0009_invoice.odt','facture/FA1212-0009','/home/ldestailleur/git/dolibarr_15.0/documents/facture/FA1212-0009/FA1212-0009_invoice.odt','','',NULL,'unknown',NULL,'2022-02-07 14:27:46','2022-02-07 13:27:46',12,NULL,NULL,NULL,NULL,2,NULL,NULL,NULL),(128,'67f648b8fe1984bcb3ea2620fbc2828a','fe6f8a3b4b1ceecbd0838ce545afc877',NULL,1,'FA1212-0011.pdf','facture/FA1212-0011','/home/ldestailleur/git/dolibarr_15.0/documents/facture/FA1212-0011/FA1212-0011.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:46','2022-02-07 13:27:46',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(129,'5ddfdaeb0c7ca1cd31a385432912c924','d3ed67c68c415bb1ab1fbe70dad86057',NULL,1,'FA1212-0021.pdf','facture/FA1212-0021','/home/ldestailleur/git/dolibarr_15.0/documents/facture/FA1212-0021/FA1212-0021.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:46','2022-02-07 13:27:46',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(130,'175d1934a611fcb705b2f99736c9c4db','05cd7899fe75c0373cccfeb0d4effa35',NULL,1,'FA1212-0023.pdf','facture/FA1212-0023','/home/ldestailleur/git/dolibarr_15.0/documents/facture/FA1212-0023/FA1212-0023.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:46','2022-02-07 13:27:46',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(131,'0a6af0756aaa8297a0d642377b607963','1c951063e26b48eebe54eb92220e78d8',NULL,1,'FA1507-0015.pdf','facture/FA1507-0015','/home/ldestailleur/git/dolibarr_15.0/documents/facture/FA1507-0015/FA1507-0015.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:46','2022-02-07 13:27:46',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(132,'3ae2bd1a22d0f789d48fa5b05c21cca3','1514b9abebb7b9704cda5da4c52b7864',NULL,1,'FA1507-0015_invoice.odt','facture/FA1507-0015','/home/ldestailleur/git/dolibarr_15.0/documents/facture/FA1507-0015/FA1507-0015_invoice.odt','','',NULL,'unknown',NULL,'2022-02-07 14:27:46','2022-02-07 13:27:46',12,NULL,NULL,NULL,NULL,2,NULL,NULL,NULL),(133,'566749a19fbc251dc4ed0e1c67a89932','25f06a8e8dd7d0cfbea72e6b2c109594',NULL,1,'PR1007-0001.pdf','propale/PR1007-0001','/home/ldestailleur/git/dolibarr_15.0/documents/propale/PR1007-0001/PR1007-0001.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:47','2022-02-07 13:27:47',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(134,'2626893a8eba25219aa008f0e3775690','0e6c19224bbdfc90415b00a1bd766e32',NULL,1,'PR1007-0002.pdf','propale/PR1007-0002','/home/ldestailleur/git/dolibarr_15.0/documents/propale/PR1007-0002/PR1007-0002.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:48','2022-02-07 13:27:48',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(135,'22878d01d869b50e51c296f327c8c0af','aaf231d3683671621f82ebb5fc15d096',NULL,1,'PR1302-0005.pdf','propale/PR1302-0005','/home/ldestailleur/git/dolibarr_15.0/documents/propale/PR1302-0005/PR1302-0005.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:48','2022-02-07 13:27:48',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(136,'c566106ea2aad8c887e1e5887e427426','cef4c0c04d87a3e4d2564254489f47b6',NULL,1,'PR1302-0006.pdf','propale/PR1302-0006','/home/ldestailleur/git/dolibarr_15.0/documents/propale/PR1302-0006/PR1302-0006.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:48','2022-02-07 13:27:48',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(137,'f0670e34a50062c94a6ec71f195ffd7a','0dfaaff511fb6e8ffa94d085ac05955c',NULL,1,'PR1302-0007.pdf','propale/PR1302-0007','/home/ldestailleur/git/dolibarr_15.0/documents/propale/PR1302-0007/PR1302-0007.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:48','2022-02-07 13:27:48',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(138,'142509d21a32e9a3eeefffcb391bf2af','407e9fcdc7f001073628958feddbdef6',NULL,1,'CF1007-0001.pdf','fournisseur/commande/CF1007-0001','/home/ldestailleur/git/dolibarr_15.0/documents/fournisseur/commande/CF1007-0001/CF1007-0001.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:53','2022-02-07 13:27:53',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(139,'7a90f8625485a919e9d1fe4b873a769e','67aa4197014ab5792d9fb2fd9fb7ce71',NULL,1,'CF1007-0002.pdf','fournisseur/commande/CF1007-0002','/home/ldestailleur/git/dolibarr_15.0/documents/fournisseur/commande/CF1007-0002/CF1007-0002.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:53','2022-02-07 13:27:53',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(140,'f0203e34a81efc7d710b86295f4a4277','e5ec02a09187711e6d2451e3d174e133',NULL,1,'CF1303-0004.pdf','fournisseur/commande/CF1303-0004','/home/ldestailleur/git/dolibarr_15.0/documents/fournisseur/commande/CF1303-0004/CF1303-0004.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:53','2022-02-07 13:27:53',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(141,'ab2421790a1602da8653b02dc208d731','c4b1825aaf6b3e90ec5c22abb3b251ca',NULL,1,'CO1107-0002.pdf','commande/CO1107-0002','/home/ldestailleur/git/dolibarr_15.0/documents/commande/CO1107-0002/CO1107-0002.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:57','2022-02-07 13:27:57',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(142,'c1907b95156a0964a79a3c4bcaef8498','f558a23ce25e7983d17ce4f567fde4b0',NULL,1,'CO1107-0003.pdf','commande/CO1107-0003','/home/ldestailleur/git/dolibarr_15.0/documents/commande/CO1107-0003/CO1107-0003.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:57','2022-02-07 13:27:57',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(143,'1034b7c11032ba4305509636e44e66c7','b81bf55855474463bb6875e5ade642cc',NULL,1,'CO1107-0004.pdf','commande/CO1107-0004','/home/ldestailleur/git/dolibarr_15.0/documents/commande/CO1107-0004/CO1107-0004.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:57','2022-02-07 13:27:57',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(144,'253b69fed906e64b7f4c2bb33d7917c2','86464c6b7b21087c3310cd15442d6508',NULL,1,'CO1108-0001.pdf','commande/CO1108-0001','/home/ldestailleur/git/dolibarr_15.0/documents/commande/CO1108-0001/CO1108-0001.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:27:57','2022-02-07 13:27:57',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(145,'15f4b675acf2c6fa346c80d82ecaaec5','496cca40073d7b8675e0eebb0ea230b5',NULL,1,'RQ1607-0001.pdf','supplier_proposal/RQ1607-0001','/home/ldestailleur/git/dolibarr_15.0/documents/supplier_proposal/RQ1607-0001/RQ1607-0001.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:28:01','2022-02-07 13:28:01',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(146,'6af0fd1b03e31747a27f2355d6dd57b2','12a1917f8a109e352faa4fbf8f532b1a',NULL,1,'16.pdf','fournisseur/facture/6/1/16','/home/ldestailleur/git/dolibarr_15.0/documents/fournisseur/facture/6/1/16/16.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:28:03','2022-02-07 13:28:03',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(147,'b72722a6b79293f4b9d5534836f754a8','5c9ae7974767ca79f90766e46d1f97f8',NULL,1,'17.pdf','fournisseur/facture/7/1/17','/home/ldestailleur/git/dolibarr_15.0/documents/fournisseur/facture/7/1/17/17.pdf','','',NULL,'unknown',NULL,'2022-02-07 14:28:03','2022-02-07 13:28:03',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(148,'26157b77d37c340836aedb6d78c9ce4b','81b6d23d5c5ac95aabdd4503f6b2bd79',NULL,1,'alberteinstein.jpg','users/1','/home/ldestailleur/git/dolibarr_15.0/documents/users/1/alberteinstein.jpg','','',NULL,'unknown',NULL,'2022-02-07 14:28:05','2022-02-07 13:28:05',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(149,'d10c2a0733366a3011bb9db79bcaec17','ebc9978c671bae5e8e0350900957a9bd',NULL,1,'mariecurie.jpg','users/10','/home/ldestailleur/git/dolibarr_15.0/documents/users/10/mariecurie.jpg','','',NULL,'unknown',NULL,'2022-02-07 14:28:05','2022-02-07 13:28:05',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(150,'f8dafe8a7d427c1f33ce628b63f3660e','ed95d1fb2f54a72cdb2389c029f1271b',NULL,1,'person4.jpeg','users/11','/home/ldestailleur/git/dolibarr_15.0/documents/users/11/person4.jpeg','','',NULL,'unknown',NULL,'2022-02-07 14:28:05','2022-02-07 13:28:05',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(151,'e1606108d2271bfd9e7ec19dece0d1f7','d5f64b15058a4c95ec1fffb39fed360e',NULL,1,'person6.jpeg','users/12','/home/ldestailleur/git/dolibarr_15.0/documents/users/12/person6.jpeg','','',NULL,'unknown',NULL,'2022-02-07 14:28:05','2022-02-07 13:28:05',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(152,'4cf03a580acfb6f91b04e28f5fafb6d8','18a71a131e519d3f2aca255371343e68',NULL,1,'person7.jpeg','users/13','/home/ldestailleur/git/dolibarr_15.0/documents/users/13/person7.jpeg','','',NULL,'unknown',NULL,'2022-02-07 14:28:05','2022-02-07 13:28:05',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(153,'04b3b24d0247aa9e141a92d8c6f4ab57','4689a624f4ff71f1f69aea9385f7744b',NULL,1,'person3.jpeg','users/14','/home/ldestailleur/git/dolibarr_15.0/documents/users/14/person3.jpeg','','',NULL,'unknown',NULL,'2022-02-07 14:28:05','2022-02-07 13:28:05',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(154,'05656c73e27cacf85b8a9d5257f71291','99eec010ef37eda7d9a0a971d9b7d14b',NULL,1,'person1.jpeg','users/16','/home/ldestailleur/git/dolibarr_15.0/documents/users/16/person1.jpeg','','',NULL,'unknown',NULL,'2022-02-07 14:28:05','2022-02-07 13:28:05',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(155,'76b8ee91190429a48f04602e4c2ed12c','e288f7beabf3dbb50ab764ec3dbd2a20',NULL,1,'person5.jpeg','users/17','/home/ldestailleur/git/dolibarr_15.0/documents/users/17/person5.jpeg','','',NULL,'unknown',NULL,'2022-02-07 14:28:05','2022-02-07 13:28:05',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(156,'96e8d498e4507eb0407bdb239d6fc802','71939d1f01d2f1617f5131ee34a19e7b',NULL,1,'ldestailleur_200x200.jpg','users/18','/home/ldestailleur/git/dolibarr_15.0/documents/users/18/ldestailleur_200x200.jpg','','',NULL,'unknown',NULL,'2022-02-07 14:28:05','2022-02-07 13:28:05',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(157,'2fc59dfd4c4aeb1c63a969242ca1d6a8','e96eeee77f39a78a9316c22ea4f2ce86',NULL,1,'person2.jpeg','users/19','/home/ldestailleur/git/dolibarr_15.0/documents/users/19/person2.jpeg','','',NULL,'unknown',NULL,'2022-02-07 14:28:05','2022-02-07 13:28:05',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(158,'a96c060439bf6b1d42d8ff5c2dbb7eb5','bccbed4cf8228c7fd2d22206b5a8f592',NULL,1,'person9.jpeg','users/2','/home/ldestailleur/git/dolibarr_15.0/documents/users/2/person9.jpeg','','',NULL,'unknown',NULL,'2022-02-07 14:28:05','2022-02-07 13:28:05',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(159,'8f3535be740080fe1eeac5d7bdfc23f8','6fb1b02279e72873feb351539b07fff7',NULL,1,'pierrecurie.jpg','users/3','/home/ldestailleur/git/dolibarr_15.0/documents/users/3/pierrecurie.jpg','','',NULL,'unknown',NULL,'2022-02-07 14:28:05','2022-02-07 13:28:05',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL),(160,'737e0b7100ad24a8ff984d1bd9b85936','b9d41201db137d8dd35feaae616effc7',NULL,1,'person8.jpeg','users/4','/home/ldestailleur/git/dolibarr_15.0/documents/users/4/person8.jpeg','','',NULL,'unknown',NULL,'2022-02-07 14:28:05','2022-02-07 13:28:05',12,NULL,NULL,NULL,NULL,1,NULL,NULL,NULL); /*!40000 ALTER TABLE `llx_ecm_files` ENABLE KEYS */; UNLOCK TABLES; @@ -5561,7 +5611,7 @@ CREATE TABLE `llx_emailcollector_emailcollectoraction` ( `rowid` int(11) NOT NULL AUTO_INCREMENT, `fk_emailcollector` int(11) NOT NULL, `type` varchar(128) COLLATE utf8_unicode_ci NOT NULL, - `actionparam` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `actionparam` text COLLATE utf8_unicode_ci DEFAULT NULL, `date_creation` datetime NOT NULL, `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(), `fk_user_creat` int(11) NOT NULL, @@ -5650,6 +5700,7 @@ CREATE TABLE `llx_entrepot` ( `fk_parent` int(11) DEFAULT 0, `fax` varchar(20) COLLATE utf8_unicode_ci DEFAULT NULL, `phone` varchar(20) COLLATE utf8_unicode_ci DEFAULT NULL, + `warehouse_usage` int(11) DEFAULT 1, PRIMARY KEY (`rowid`), UNIQUE KEY `uk_entrepot_label` (`ref`,`entity`) ) ENGINE=InnoDB AUTO_INCREMENT=21 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; @@ -5661,7 +5712,7 @@ CREATE TABLE `llx_entrepot` ( LOCK TABLES `llx_entrepot` WRITE; /*!40000 ALTER TABLE `llx_entrepot` DISABLE KEYS */; -INSERT INTO `llx_entrepot` VALUES (1,'2012-07-09 00:31:22','2020-06-12 17:18:30','WAREHOUSEHOUSTON',1,NULL,'Warehouse located at Houston','Warehouse houston','','','Houston',NULL,11,1,1,NULL,NULL,NULL,'',''),(2,'2012-07-09 00:41:03','2020-06-12 17:18:33','WAREHOUSEPARIS',1,NULL,'','Warehouse Paris','','75000','Paris',NULL,1,1,1,NULL,NULL,NULL,'',''),(3,'2012-07-11 16:18:59','2020-06-12 17:18:25','Stock personnel Dupont',1,NULL,'Cet entrepôt représente le stock personnel de Alain Dupont','','','','',NULL,2,1,1,NULL,NULL,NULL,'',''),(9,'2017-10-03 11:47:41','2017-10-03 09:47:41','Personal stock Marie Curie',1,NULL,'This warehouse represents personal stock of Marie Curie','','','','',NULL,1,1,1,NULL,NULL,0,NULL,NULL),(10,'2017-10-05 09:07:52','2018-07-30 13:52:24','Personal stock Alex Theceo',1,NULL,'This warehouse represents personal stock of Alex Theceo','','','','',NULL,3,1,1,NULL,NULL,0,NULL,NULL),(12,'2017-10-05 21:29:35','2017-10-05 19:29:35','Personal stock Charly Commery',1,NULL,'This warehouse represents personal stock of Charly Commery','','','','',NULL,1,1,11,NULL,NULL,0,NULL,NULL),(13,'2017-10-05 21:33:33','2018-07-30 13:51:38','Personal stock Sam Scientol',1,NULL,'This warehouse represents personal stock of Sam Scientol','','','7500','Paris',NULL,1,0,11,NULL,NULL,0,NULL,NULL),(18,'2018-01-22 17:27:02','2020-06-12 17:18:18','Personal stock Laurent Destailleur',1,NULL,'This warehouse represents personal stock of Laurent Destailleur','','','','',NULL,1,1,12,NULL,NULL,NULL,'',''),(19,'2018-07-30 16:50:23','2020-06-12 17:18:12','Personal stock Eldy',1,NULL,'This warehouse represents personal stock of Eldy','','','','',NULL,14,1,12,NULL,NULL,NULL,'',''),(20,'2017-02-02 03:55:45','2020-06-12 17:18:55','Personal stock Alex Boston',1,NULL,'This warehouse represents personal stock of Alex Boston','PSTOCKALEXB','','','',NULL,14,1,12,NULL,NULL,NULL,'',''); +INSERT INTO `llx_entrepot` VALUES (1,'2012-07-09 00:31:22','2020-06-12 17:18:30','WAREHOUSEHOUSTON',1,NULL,'Warehouse located at Houston','Warehouse houston','','','Houston',NULL,11,1,1,NULL,NULL,NULL,'','',1),(2,'2012-07-09 00:41:03','2020-06-12 17:18:33','WAREHOUSEPARIS',1,NULL,'','Warehouse Paris','','75000','Paris',NULL,1,1,1,NULL,NULL,NULL,'','',1),(3,'2012-07-11 16:18:59','2020-06-12 17:18:25','Stock personnel Dupont',1,NULL,'Cet entrepôt représente le stock personnel de Alain Dupont','','','','',NULL,2,1,1,NULL,NULL,NULL,'','',1),(9,'2017-10-03 11:47:41','2017-10-03 09:47:41','Personal stock Marie Curie',1,NULL,'This warehouse represents personal stock of Marie Curie','','','','',NULL,1,1,1,NULL,NULL,0,NULL,NULL,1),(10,'2017-10-05 09:07:52','2018-07-30 13:52:24','Personal stock Alex Theceo',1,NULL,'This warehouse represents personal stock of Alex Theceo','','','','',NULL,3,1,1,NULL,NULL,0,NULL,NULL,1),(12,'2017-10-05 21:29:35','2017-10-05 19:29:35','Personal stock Charly Commery',1,NULL,'This warehouse represents personal stock of Charly Commery','','','','',NULL,1,1,11,NULL,NULL,0,NULL,NULL,1),(13,'2017-10-05 21:33:33','2018-07-30 13:51:38','Personal stock Sam Scientol',1,NULL,'This warehouse represents personal stock of Sam Scientol','','','7500','Paris',NULL,1,0,11,NULL,NULL,0,NULL,NULL,1),(18,'2018-01-22 17:27:02','2020-06-12 17:18:18','Personal stock Laurent Destailleur',1,NULL,'This warehouse represents personal stock of Laurent Destailleur','','','','',NULL,1,1,12,NULL,NULL,NULL,'','',1),(19,'2018-07-30 16:50:23','2020-06-12 17:18:12','Personal stock Eldy',1,NULL,'This warehouse represents personal stock of Eldy','','','','',NULL,14,1,12,NULL,NULL,NULL,'','',1),(20,'2017-02-02 03:55:45','2020-06-12 17:18:55','Personal stock Alex Boston',1,NULL,'This warehouse represents personal stock of Alex Boston','PSTOCKALEXB','','','',NULL,14,1,12,NULL,NULL,NULL,'','',1); /*!40000 ALTER TABLE `llx_entrepot` ENABLE KEYS */; UNLOCK TABLES; @@ -5767,7 +5818,7 @@ CREATE TABLE `llx_eventorganization_conferenceorboothattendee` ( `rowid` int(11) NOT NULL AUTO_INCREMENT, `ref` varchar(128) COLLATE utf8_unicode_ci NOT NULL, `fk_soc` int(11) DEFAULT NULL, - `fk_actioncomm` int(11) NOT NULL, + `fk_actioncomm` int(11) DEFAULT NULL, `email` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL, `date_subscription` datetime DEFAULT NULL, `amount` double DEFAULT NULL, @@ -5781,16 +5832,16 @@ CREATE TABLE `llx_eventorganization_conferenceorboothattendee` ( `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, `model_pdf` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `status` smallint(6) NOT NULL, + `fk_project` int(11) NOT NULL, + `fk_invoice` int(11) DEFAULT NULL, PRIMARY KEY (`rowid`), - UNIQUE KEY `uk_eventorganization_conferenceorboothattendee` (`fk_soc`,`fk_actioncomm`,`email`), + UNIQUE KEY `uk_eventorganization_conferenceorboothattendee` (`fk_project`,`email`,`fk_actioncomm`), KEY `idx_eventorganization_conferenceorboothattendee_rowid` (`rowid`), KEY `idx_eventorganization_conferenceorboothattendee_ref` (`ref`), KEY `idx_eventorganization_conferenceorboothattendee_fk_soc` (`fk_soc`), KEY `idx_eventorganization_conferenceorboothattendee_fk_actioncomm` (`fk_actioncomm`), KEY `idx_eventorganization_conferenceorboothattendee_email` (`email`), - KEY `idx_eventorganization_conferenceorboothattendee_status` (`status`), - CONSTRAINT `fx_eventorganization_conferenceorboothattendee_fk_actioncomm` FOREIGN KEY (`fk_actioncomm`) REFERENCES `llx_actioncomm` (`id`), - CONSTRAINT `fx_eventorganization_conferenceorboothattendee_fk_soc` FOREIGN KEY (`fk_soc`) REFERENCES `llx_societe` (`rowid`) + KEY `idx_eventorganization_conferenceorboothattendee_status` (`status`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; @@ -6125,7 +6176,7 @@ CREATE TABLE `llx_expensereport` ( `model_pdf` varchar(50) COLLATE utf8_unicode_ci DEFAULT NULL, `last_main_doc` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_tx` double(24,8) DEFAULT 1.00000000, `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000, `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000, @@ -6151,7 +6202,7 @@ CREATE TABLE `llx_expensereport` ( LOCK TABLES `llx_expensereport` WRITE; /*!40000 ALTER TABLE `llx_expensereport` DISABLE KEYS */; -INSERT INTO `llx_expensereport` VALUES (1,'ADMIN-ER00002-150101',1,2,NULL,8.33000000,1.67000000,0.00000000,0.00000000,10.00000000,'2021-01-01','2021-01-03','2021-01-22 19:03:37','2021-01-22 19:06:50','2021-02-16 02:12:40',NULL,NULL,'2021-04-15 10:22:31',12,NULL,12,12,12,NULL,NULL,5,NULL,0,'Holidays',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL),(2,'ER1912-0001',1,NULL,NULL,141.67000000,28.33000000,0.00000000,0.00000000,170.00000000,'2021-02-01','2021-02-28','2021-01-22 19:04:44','2021-12-20 20:34:13','2021-12-20 20:34:19',NULL,'2021-12-21 00:34:26','2021-04-15 10:22:31',12,12,12,12,12,NULL,12,4,NULL,0,'Work on projet X','','','aaaa',NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL),(3,'(PROV3)',1,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,'2021-02-02','2021-02-02','2021-02-02 03:57:03','2021-02-02 00:00:00',NULL,NULL,NULL,'2021-04-15 10:22:31',19,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL); +INSERT INTO `llx_expensereport` VALUES (1,'ADMIN-ER00002-150101',1,2,NULL,8.33000000,1.67000000,0.00000000,0.00000000,10.00000000,'2022-01-01','2022-01-03','2022-01-22 19:03:37','2022-01-22 19:06:50','2021-02-16 02:12:40',NULL,NULL,'2022-02-07 13:37:54',12,NULL,12,12,12,NULL,NULL,5,NULL,0,'Holidays',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL),(2,'ER1912-0001',1,NULL,NULL,141.67000000,28.33000000,0.00000000,0.00000000,170.00000000,'2022-02-01','2021-02-28','2022-01-22 19:04:44','2021-12-20 20:34:13','2021-12-20 20:34:19',NULL,'2021-12-21 00:34:26','2022-02-07 13:37:54',12,12,12,12,12,NULL,12,4,NULL,0,'Work on projet X','','','aaaa',NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL),(3,'(PROV3)',1,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,'2022-02-02','2022-02-02','2022-02-02 03:57:03','2022-02-02 00:00:00',NULL,NULL,NULL,'2022-02-07 13:37:54',19,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL); /*!40000 ALTER TABLE `llx_expensereport` ENABLE KEYS */; UNLOCK TABLES; @@ -6190,7 +6241,7 @@ CREATE TABLE `llx_expensereport_det` ( `rang` int(11) DEFAULT 0, `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_subprice` double(24,8) DEFAULT 0.00000000, `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000, `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000, @@ -6473,7 +6524,7 @@ CREATE TABLE `llx_facture` ( `fk_transport_mode` int(11) DEFAULT NULL, `date_pointoftax` date DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_tx` double(24,8) DEFAULT 1.00000000, `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000, `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000, @@ -6506,7 +6557,7 @@ CREATE TABLE `llx_facture` ( LOCK TABLES `llx_facture` WRITE; /*!40000 ALTER TABLE `llx_facture` DISABLE KEYS */; -INSERT INTO `llx_facture` VALUES (2,'FA1007-0002',1,NULL,NULL,0,NULL,NULL,2,'2012-07-10 18:20:13','2021-07-10',NULL,NULL,'2021-07-11 17:49:28',1,10.00000000,NULL,NULL,0,NULL,NULL,0.10000000,0.00000000,0.00000000,0.00000000,46.00000000,46.10000000,2,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,0,'2021-07-10',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(3,'FA1107-0006',1,NULL,NULL,0,NULL,NULL,10,'2013-07-18 20:33:35','2020-07-18',NULL,NULL,'2020-12-10 12:24:22',1,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,15.00000000,15.00000000,2,1,NULL,1,NULL,NULL,1,NULL,NULL,1,0,'2020-07-18',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(5,'FA1108-0003',1,NULL,NULL,0,NULL,NULL,7,'2013-08-01 03:34:11','2020-08-01',NULL,NULL,'2020-12-10 12:24:22',1,0.00000000,NULL,NULL,0,NULL,NULL,0.63000000,0.00000000,0.00000000,0.00000000,5.00000000,5.63000000,2,1,NULL,1,NULL,NULL,NULL,NULL,NULL,0,6,'2020-08-01',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(6,'FA1108-0004',1,NULL,NULL,0,NULL,NULL,7,'2013-08-06 20:33:53','2020-08-06',NULL,NULL,'2020-12-10 12:24:22',1,0.00000000,NULL,NULL,0,NULL,NULL,0.98000000,0.00000000,0.00000000,0.00000000,5.00000000,5.98000000,2,1,NULL,1,NULL,NULL,NULL,NULL,NULL,0,4,'2020-08-06','Cash\nReceived : 6 EUR\nRendu : 0.02 EUR\n\n--------------------------------------',NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(8,'FA1108-0005',1,NULL,NULL,3,NULL,NULL,2,'2013-08-08 02:41:44','2020-08-08',NULL,NULL,'2020-12-10 12:24:22',1,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,10.00000000,10.00000000,2,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,0,'2020-08-08',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(9,'FA1108-0007',1,NULL,NULL,3,NULL,NULL,10,'2013-08-08 02:55:14','2020-08-08',NULL,NULL,'2020-12-10 12:24:22',0,0.00000000,NULL,NULL,0,NULL,NULL,1.96000000,0.00000000,0.00000000,0.00000000,10.00000000,11.96000000,1,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,0,'2020-08-08',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(10,'AV1212-0001',1,NULL,NULL,2,NULL,NULL,10,'2014-12-08 17:45:20','2020-12-08','2020-12-08 00:00:00',NULL,'2020-12-10 12:24:22',0,0.00000000,NULL,NULL,0,NULL,NULL,-0.63000000,0.00000000,0.00000000,0.00000000,-11.00000000,-11.63000000,1,1,NULL,1,NULL,3,NULL,NULL,NULL,0,0,'2020-12-08',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(12,'AV1212-0002',1,NULL,NULL,2,NULL,NULL,10,'2014-12-08 18:20:14','2020-12-08','2020-12-08 00:00:00',NULL,'2020-12-10 12:24:22',1,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,-5.00000000,-5.00000000,2,1,NULL,1,NULL,3,NULL,NULL,NULL,0,0,'2020-12-08',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(13,'FA1212-0011',1,NULL,NULL,0,NULL,NULL,7,'2014-12-09 20:04:19','2020-12-09','2020-02-12 00:00:00',NULL,'2020-12-10 12:24:22',0,0.00000000,NULL,NULL,0,NULL,NULL,2.74000000,0.00000000,0.00000000,0.00000000,14.00000000,16.74000000,1,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,0,'2020-12-09',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(32,'FA1212-0021',1,NULL,NULL,0,NULL,NULL,1,'2014-12-11 09:34:23','2020-12-11','2021-03-24 00:00:00',NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,NULL,NULL,90.00000000,0.00000000,0.00000000,0.60000000,520.00000000,610.60000000,1,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,0,'2020-12-11','This is a comment (private)','This is a comment (public)','crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(33,'FA1212-0023',1,NULL,NULL,0,NULL,NULL,1,'2014-12-11 09:34:23','2020-12-11','2021-03-03 00:00:00',NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,'abandon',NULL,0.24000000,0.00000000,0.00000000,0.00000000,2.48000000,2.72000000,3,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,0,'2020-12-11','This is a comment (private)','This is a comment (public)','crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(55,'FA1212-0009',1,NULL,NULL,0,NULL,NULL,1,'2014-12-11 09:35:51','2020-12-11','2020-12-12 00:00:00',NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,NULL,NULL,0.24000000,0.00000000,0.00000000,0.00000000,2.48000000,2.72000000,1,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,0,'2020-12-11','This is a comment (private)','This is a comment (public)','generic_invoice_odt:/home/ldestailleur/git/dolibarr_3.8/documents/doctemplates/invoices/template_invoice.odt',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(148,'FS1301-0001',1,NULL,NULL,0,NULL,NULL,1,'2015-01-19 18:22:48','2021-01-19','2021-01-19 00:00:00',NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,NULL,NULL,0.63000000,0.00000000,0.00000000,0.00000000,5.00000000,5.63000000,1,1,NULL,1,NULL,NULL,NULL,NULL,NULL,0,1,'2021-01-19',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,'facture/FS1301-0001/FS1301-0001.pdf',NULL,NULL),(149,'FA1601-0024',1,NULL,NULL,0,NULL,NULL,1,'2015-01-19 18:30:05','2021-01-19','2020-08-29 00:00:00','2020-01-02 20:49:34','2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,'other','test',1.80000000,0.90000000,0.90000000,0.00000000,20.00000000,23.60000000,2,1,NULL,12,12,NULL,NULL,NULL,NULL,0,0,'2021-01-19',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,20.00000000,1.80000000,23.60000000,NULL,'facture/FA1601-0024/FA1601-0024.pdf',NULL,NULL),(150,'FA6801-0010',1,NULL,NULL,0,NULL,NULL,1,'2015-01-19 18:31:10','2021-01-19','2020-10-04 00:00:00',NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,NULL,NULL,0.63000000,0.00000000,0.00000000,0.00000000,5.00000000,5.63000000,1,1,NULL,12,NULL,NULL,NULL,NULL,NULL,0,1,'2021-01-19',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,5.00000000,0.63000000,5.63000000,NULL,'facture/FA6801-0010/FA6801-0010.pdf',NULL,NULL),(151,'FS1301-0002',1,NULL,NULL,0,NULL,NULL,1,'2015-01-19 18:31:58','2021-01-19','2021-01-19 00:00:00',NULL,'2021-04-15 10:22:31',1,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,2,1,NULL,1,NULL,NULL,NULL,NULL,NULL,0,1,'2021-01-19',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(160,'FA1507-0015',1,NULL,NULL,0,NULL,NULL,12,'2015-03-06 16:47:48','2020-07-18','2019-03-06 00:00:00',NULL,'2020-12-10 12:24:22',0,0.00000000,NULL,NULL,0,NULL,NULL,1.11000000,0.00000000,0.00000000,0.00000000,8.89000000,10.00000000,1,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,0,'2020-07-18',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(210,'FA1107-0019',1,NULL,NULL,0,NULL,NULL,10,'2015-03-20 14:30:11','2021-07-10','2021-03-20 00:00:00',NULL,'2021-07-11 17:49:28',0,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,10.00000000,10.00000000,1,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,0,'2021-07-10',NULL,NULL,'generic_invoice_odt:/home/ldestailleur/git/dolibarr_3.8/documents/doctemplates/invoices/template_invoice.odt',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(211,'FA1303-0020',1,NULL,NULL,0,NULL,NULL,19,'2015-03-22 09:40:10','2021-03-22','2020-03-02 00:00:00',NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,NULL,NULL,17.64000000,0.00000000,0.00000000,0.40000000,340.00000000,358.04000000,1,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,3,'2021-03-22',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(213,'AV1303-0003',1,NULL,NULL,2,NULL,NULL,1,'2016-03-03 19:22:03','2021-03-03','2020-03-03 00:00:00',NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,-1000.00000000,-1000.00000000,1,1,NULL,1,NULL,32,NULL,NULL,NULL,0,0,'2021-03-03',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(216,'(PROV216)',1,NULL,NULL,0,NULL,NULL,26,'2017-02-12 23:21:27','2021-02-12',NULL,NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,0,12,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,'2021-02-12',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,0,'',NULL,NULL,0,'EUR',1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(217,'(PROV217)',1,NULL,NULL,0,NULL,NULL,1,'2017-08-31 13:26:17','2020-08-31',NULL,NULL,'2020-12-10 12:24:22',0,0.00000000,NULL,NULL,0,NULL,NULL,1.13000000,0.00000000,0.00000000,0.00000000,21.00000000,22.13000000,0,12,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,'2020-08-31',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,0,'',NULL,NULL,1,'EUR',1.00000000,21.00000000,1.13000000,22.13000000,NULL,'facture/(PROV217)/(PROV217).pdf',NULL,NULL),(218,'FA1909-0025',1,NULL,NULL,0,NULL,NULL,12,'2019-09-26 17:30:14','2020-09-26','2020-09-26 00:00:00',NULL,'2020-12-10 12:24:22',0,0.00000000,NULL,NULL,0,NULL,NULL,1.08000000,0.00000000,0.00000000,0.00000000,42.50000000,43.58000000,1,12,NULL,12,NULL,NULL,NULL,NULL,NULL,0,0,'2020-09-26',NULL,NULL,'',NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,0,'',NULL,NULL,0,'EUR',1.00000000,42.50000000,1.08000000,43.58000000,NULL,NULL,'takepos','1'),(219,'(PROV-POS1-0)',1,NULL,NULL,0,NULL,NULL,1,'2019-11-28 19:04:03','2020-11-28',NULL,NULL,'2020-12-10 12:24:22',0,0.00000000,NULL,NULL,0,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,5.00000000,6.00000000,0,12,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,'2020-11-28',NULL,NULL,'',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,0,'EUR',1.00000000,5.00000000,1.00000000,6.00000000,NULL,NULL,'takepos','1'),(220,'(PROV220)',1,NULL,NULL,3,NULL,NULL,19,'2020-01-16 02:03:17','2021-01-16',NULL,NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,100.00000000,100.00000000,0,12,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,'2021-01-16',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,1,'EUR',1.00000000,100.00000000,0.00000000,100.00000000,NULL,NULL,NULL,NULL),(221,'AC2001-0001',1,NULL,NULL,3,NULL,NULL,19,'2020-01-16 02:21:05','2021-01-16','2021-01-16 00:00:00',NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,123.00000000,123.00000000,0,12,NULL,12,NULL,NULL,NULL,NULL,NULL,1,0,'2021-01-16',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,1,'EUR',1.00000000,123.00000000,0.00000000,123.00000000,NULL,'facture/AC2001-0001/AC2001-0001.pdf',NULL,NULL),(222,'(PROV222)',1,NULL,NULL,3,NULL,NULL,19,'2020-01-16 02:21:28','2021-01-16',NULL,NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,100.00000000,100.00000000,0,12,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,'2021-01-16',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,1,'EUR',1.00000000,100.00000000,0.00000000,100.00000000,NULL,NULL,NULL,NULL),(223,'(PROV223)',1,NULL,NULL,0,NULL,NULL,19,'2020-01-16 02:32:04','2021-01-16',NULL,NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,410.00000000,410.00000000,0,12,NULL,NULL,NULL,NULL,NULL,NULL,NULL,2,0,'2021-02-15',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,1,'EUR',1.00000000,410.00000000,0.00000000,410.00000000,NULL,NULL,NULL,NULL),(224,'AC2001-0002',1,NULL,NULL,3,NULL,NULL,19,'2020-01-16 02:33:19','2021-01-16','2021-01-16 00:00:00','2020-01-16 02:36:48','2021-04-15 10:22:31',1,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,20.50000000,20.50000000,2,12,NULL,12,12,NULL,NULL,NULL,NULL,1,0,'2021-01-16',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,1,'EUR',1.00000000,20.50000000,0.00000000,20.50000000,NULL,'facture/AC2001-0002/AC2001-0002.pdf',NULL,NULL),(225,'(PROV225)',1,NULL,NULL,0,NULL,NULL,19,'2020-01-16 02:37:48','2021-01-16',NULL,NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,389.50000000,389.50000000,0,12,NULL,NULL,NULL,NULL,NULL,NULL,NULL,2,0,'2021-02-15',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,1,'EUR',1.00000000,389.50000000,0.00000000,389.50000000,NULL,'facture/(PROV225)/(PROV225).pdf',NULL,NULL),(226,'(PROV226)',1,NULL,NULL,3,NULL,NULL,11,'2020-01-19 14:20:54','2021-01-19',NULL,NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,NULL,NULL,12.50000000,0.00000000,0.00000000,0.00000000,120.00000000,132.50000000,0,12,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,'2021-01-19',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,1,'EUR',1.00000000,120.00000000,12.50000000,132.50000000,NULL,'facture/(PROV226)/(PROV226).pdf',NULL,NULL),(227,'AC2001-0003',1,NULL,NULL,3,NULL,NULL,1,'2020-01-19 14:22:54','2021-01-19','2021-01-19 00:00:00',NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,NULL,NULL,39.20000000,0.00000000,0.00000000,0.00000000,200.00000000,239.20000000,0,12,NULL,12,NULL,NULL,NULL,NULL,NULL,1,0,'2021-01-19',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,1,'EUR',1.00000000,200.00000000,39.20000000,239.20000000,NULL,'facture/AC2001-0003/AC2001-0003.pdf',NULL,NULL),(228,'AC2001-0004',1,NULL,NULL,3,NULL,NULL,1,'2020-01-19 14:24:49','2021-01-19','2021-01-19 00:00:00',NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,NULL,NULL,1.94000000,0.00000000,0.00000000,0.00000000,48.60000000,50.54000000,1,12,NULL,12,NULL,NULL,NULL,NULL,NULL,1,0,'2021-01-19',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,1,'EUR',1.00000000,48.60000000,1.94000000,50.54000000,NULL,'facture/AC2001-0004/AC2001-0004.pdf',NULL,NULL),(229,'FA1707-0026',1,NULL,NULL,0,NULL,NULL,12,'2020-01-21 10:23:17','2020-07-18','2022-01-21 00:00:00','2020-01-21 10:23:17','2020-12-10 12:24:22',1,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,50.00000000,50.00000000,2,12,NULL,12,12,NULL,NULL,NULL,NULL,1,0,'2020-07-18',NULL,NULL,'',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,0,'EUR',1.00000000,50.00000000,0.00000000,50.00000000,NULL,'facture/FA1707-0026/FA1707-0026.pdf',NULL,NULL),(230,'FA1807-0027',1,NULL,NULL,0,NULL,NULL,12,'2020-01-21 10:23:28','2020-07-18','2021-01-21 00:00:00','2020-01-21 10:23:28','2020-12-10 12:24:22',1,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,50.00000000,50.00000000,2,12,NULL,12,12,NULL,NULL,NULL,NULL,1,0,'2020-07-18',NULL,NULL,'',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,0,'EUR',1.00000000,50.00000000,0.00000000,50.00000000,NULL,'facture/FA1807-0027/FA1807-0027.pdf',NULL,NULL),(231,'FA1907-0028',1,NULL,NULL,0,NULL,NULL,12,'2020-01-21 10:23:49','2020-07-18','2020-01-21 00:00:00','2020-01-21 10:23:49','2020-12-10 12:24:22',1,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,50.00000000,50.00000000,2,12,NULL,12,12,NULL,NULL,NULL,NULL,1,0,'2020-07-18',NULL,NULL,'',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,0,'EUR',1.00000000,50.00000000,0.00000000,50.00000000,NULL,'facture/FA1907-0028/FA1907-0028.pdf',NULL,NULL); +INSERT INTO `llx_facture` VALUES (2,'FA1007-0002',1,NULL,NULL,0,NULL,NULL,2,'2012-07-10 18:20:13','2021-07-10',NULL,NULL,'2021-07-11 17:49:28',1,10.00000000,NULL,NULL,0,NULL,NULL,0.10000000,0.00000000,0.00000000,0.00000000,46.00000000,46.10000000,2,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,0,'2021-07-10',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(3,'FA1107-0006',1,NULL,NULL,0,NULL,NULL,10,'2013-07-18 20:33:35','2021-07-18',NULL,NULL,'2022-02-07 13:37:54',1,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,15.00000000,15.00000000,2,1,NULL,1,NULL,NULL,1,NULL,NULL,1,0,'2021-07-18',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(5,'FA1108-0003',1,NULL,NULL,0,NULL,NULL,7,'2013-08-01 03:34:11','2021-08-01',NULL,NULL,'2022-02-07 13:37:54',1,0.00000000,NULL,NULL,0,NULL,NULL,0.63000000,0.00000000,0.00000000,0.00000000,5.00000000,5.63000000,2,1,NULL,1,NULL,NULL,NULL,NULL,NULL,0,6,'2021-08-01',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(6,'FA1108-0004',1,NULL,NULL,0,NULL,NULL,7,'2013-08-06 20:33:53','2021-08-06',NULL,NULL,'2022-02-07 13:37:54',1,0.00000000,NULL,NULL,0,NULL,NULL,0.98000000,0.00000000,0.00000000,0.00000000,5.00000000,5.98000000,2,1,NULL,1,NULL,NULL,NULL,NULL,NULL,0,4,'2021-08-06','Cash\nReceived : 6 EUR\nRendu : 0.02 EUR\n\n--------------------------------------',NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(8,'FA1108-0005',1,NULL,NULL,3,NULL,NULL,2,'2013-08-08 02:41:44','2021-08-08',NULL,NULL,'2022-02-07 13:37:54',1,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,10.00000000,10.00000000,2,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,0,'2021-08-08',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(9,'FA1108-0007',1,NULL,NULL,3,NULL,NULL,10,'2013-08-08 02:55:14','2021-08-08',NULL,NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,1.96000000,0.00000000,0.00000000,0.00000000,10.00000000,11.96000000,1,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,0,'2021-08-08',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(10,'AV1212-0001',1,NULL,NULL,2,NULL,NULL,10,'2014-12-08 17:45:20','2021-12-08','2021-12-08 00:00:00',NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,-0.63000000,0.00000000,0.00000000,0.00000000,-11.00000000,-11.63000000,1,1,NULL,1,NULL,3,NULL,NULL,NULL,0,0,'2021-12-08',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(12,'AV1212-0002',1,NULL,NULL,2,NULL,NULL,10,'2014-12-08 18:20:14','2021-12-08','2021-12-08 00:00:00',NULL,'2022-02-07 13:37:54',1,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,-5.00000000,-5.00000000,2,1,NULL,1,NULL,3,NULL,NULL,NULL,0,0,'2021-12-08',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(13,'FA1212-0011',1,NULL,NULL,0,NULL,NULL,7,'2014-12-09 20:04:19','2021-12-09','2021-02-12 00:00:00',NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,2.74000000,0.00000000,0.00000000,0.00000000,14.00000000,16.74000000,1,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,0,'2021-12-09',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(32,'FA1212-0021',1,NULL,NULL,0,NULL,NULL,1,'2014-12-11 09:34:23','2021-12-11','2022-03-24 00:00:00',NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,90.00000000,0.00000000,0.00000000,0.60000000,520.00000000,610.60000000,1,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,0,'2021-12-11','This is a comment (private)','This is a comment (public)','crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(33,'FA1212-0023',1,NULL,NULL,0,NULL,NULL,1,'2014-12-11 09:34:23','2021-12-11','2022-03-03 00:00:00',NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,'abandon',NULL,0.24000000,0.00000000,0.00000000,0.00000000,2.48000000,2.72000000,3,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,0,'2021-12-11','This is a comment (private)','This is a comment (public)','crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(55,'FA1212-0009',1,NULL,NULL,0,NULL,NULL,1,'2014-12-11 09:35:51','2021-12-11','2021-12-12 00:00:00',NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,0.24000000,0.00000000,0.00000000,0.00000000,2.48000000,2.72000000,1,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,0,'2021-12-11','This is a comment (private)','This is a comment (public)','generic_invoice_odt:/home/ldestailleur/git/dolibarr_3.8/documents/doctemplates/invoices/template_invoice.odt',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(148,'FS1301-0001',1,NULL,NULL,0,NULL,NULL,1,'2015-01-19 18:22:48','2022-01-19','2022-01-19 00:00:00',NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,0.63000000,0.00000000,0.00000000,0.00000000,5.00000000,5.63000000,1,1,NULL,1,NULL,NULL,NULL,NULL,NULL,0,1,'2022-01-19',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,'facture/FS1301-0001/FS1301-0001.pdf',NULL,NULL),(149,'FA1601-0024',1,NULL,NULL,0,NULL,NULL,1,'2015-01-19 18:30:05','2022-01-19','2021-08-29 00:00:00','2020-01-02 20:49:34','2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,'other','test',1.80000000,0.90000000,0.90000000,0.00000000,20.00000000,23.60000000,2,1,NULL,12,12,NULL,NULL,NULL,NULL,0,0,'2022-01-19',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,20.00000000,1.80000000,23.60000000,NULL,'facture/FA1601-0024/FA1601-0024.pdf',NULL,NULL),(150,'FA6801-0010',1,NULL,NULL,0,NULL,NULL,1,'2015-01-19 18:31:10','2022-01-19','2021-10-04 00:00:00',NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,0.63000000,0.00000000,0.00000000,0.00000000,5.00000000,5.63000000,1,1,NULL,12,NULL,NULL,NULL,NULL,NULL,0,1,'2022-01-19',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,5.00000000,0.63000000,5.63000000,NULL,'facture/FA6801-0010/FA6801-0010.pdf',NULL,NULL),(151,'FS1301-0002',1,NULL,NULL,0,NULL,NULL,1,'2015-01-19 18:31:58','2022-01-19','2022-01-19 00:00:00',NULL,'2022-02-07 13:37:54',1,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,2,1,NULL,1,NULL,NULL,NULL,NULL,NULL,0,1,'2022-01-19',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(160,'FA1507-0015',1,NULL,NULL,0,NULL,NULL,12,'2015-03-06 16:47:48','2021-07-18','2021-03-06 00:00:00',NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,1.11000000,0.00000000,0.00000000,0.00000000,8.89000000,10.00000000,1,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,0,'2021-07-18',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(210,'FA1107-0019',1,NULL,NULL,0,NULL,NULL,10,'2015-03-20 14:30:11','2021-07-10','2021-03-20 00:00:00',NULL,'2021-07-11 17:49:28',0,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,10.00000000,10.00000000,1,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,0,'2021-07-10',NULL,NULL,'generic_invoice_odt:/home/ldestailleur/git/dolibarr_3.8/documents/doctemplates/invoices/template_invoice.odt',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(211,'FA1303-0020',1,NULL,NULL,0,NULL,NULL,19,'2015-03-22 09:40:10','2021-03-22','2020-03-02 00:00:00',NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,NULL,NULL,17.64000000,0.00000000,0.00000000,0.40000000,340.00000000,358.04000000,1,1,NULL,1,NULL,NULL,NULL,NULL,NULL,1,3,'2021-03-22',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(213,'AV1303-0003',1,NULL,NULL,2,NULL,NULL,1,'2016-03-03 19:22:03','2021-03-03','2020-03-03 00:00:00',NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,-1000.00000000,-1000.00000000,1,1,NULL,1,NULL,32,NULL,NULL,NULL,0,0,'2021-03-03',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(216,'(PROV216)',1,NULL,NULL,0,NULL,NULL,26,'2017-02-12 23:21:27','2021-02-12',NULL,NULL,'2021-04-15 10:22:31',0,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,0,12,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,'2021-02-12',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,0,'',NULL,NULL,0,'EUR',1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(217,'(PROV217)',1,NULL,NULL,0,NULL,NULL,1,'2017-08-31 13:26:17','2021-08-31',NULL,NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,1.13000000,0.00000000,0.00000000,0.00000000,21.00000000,22.13000000,0,12,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,'2021-08-31',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,0,'',NULL,NULL,1,'EUR',1.00000000,21.00000000,1.13000000,22.13000000,NULL,'facture/(PROV217)/(PROV217).pdf',NULL,NULL),(218,'FA1909-0025',1,NULL,NULL,0,NULL,NULL,12,'2019-09-26 17:30:14','2021-09-26','2021-09-26 00:00:00',NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,1.08000000,0.00000000,0.00000000,0.00000000,42.50000000,43.58000000,1,12,NULL,12,NULL,NULL,NULL,NULL,NULL,0,0,'2021-09-26',NULL,NULL,'',NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,0,'',NULL,NULL,0,'EUR',1.00000000,42.50000000,1.08000000,43.58000000,NULL,NULL,'takepos','1'),(219,'(PROV-POS1-0)',1,NULL,NULL,0,NULL,NULL,1,'2019-11-28 19:04:03','2021-11-28',NULL,NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,5.00000000,6.00000000,0,12,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,'2021-11-28',NULL,NULL,'',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,0,'EUR',1.00000000,5.00000000,1.00000000,6.00000000,NULL,NULL,'takepos','1'),(220,'(PROV220)',1,NULL,NULL,3,NULL,NULL,19,'2020-01-16 02:03:17','2022-01-16',NULL,NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,100.00000000,100.00000000,0,12,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,'2022-01-16',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,1,'EUR',1.00000000,100.00000000,0.00000000,100.00000000,NULL,NULL,NULL,NULL),(221,'AC2001-0001',1,NULL,NULL,3,NULL,NULL,19,'2020-01-16 02:21:05','2022-01-16','2022-01-16 00:00:00',NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,123.00000000,123.00000000,0,12,NULL,12,NULL,NULL,NULL,NULL,NULL,1,0,'2022-01-16',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,1,'EUR',1.00000000,123.00000000,0.00000000,123.00000000,NULL,'facture/AC2001-0001/AC2001-0001.pdf',NULL,NULL),(222,'(PROV222)',1,NULL,NULL,3,NULL,NULL,19,'2020-01-16 02:21:28','2022-01-16',NULL,NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,100.00000000,100.00000000,0,12,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,'2022-01-16',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,1,'EUR',1.00000000,100.00000000,0.00000000,100.00000000,NULL,NULL,NULL,NULL),(223,'(PROV223)',1,NULL,NULL,0,NULL,NULL,19,'2020-01-16 02:32:04','2022-01-16',NULL,NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,410.00000000,410.00000000,0,12,NULL,NULL,NULL,NULL,NULL,NULL,NULL,2,0,'2021-02-15',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,1,'EUR',1.00000000,410.00000000,0.00000000,410.00000000,NULL,NULL,NULL,NULL),(224,'AC2001-0002',1,NULL,NULL,3,NULL,NULL,19,'2020-01-16 02:33:19','2022-01-16','2022-01-16 00:00:00','2020-01-16 02:36:48','2022-02-07 13:37:54',1,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,20.50000000,20.50000000,2,12,NULL,12,12,NULL,NULL,NULL,NULL,1,0,'2022-01-16',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,1,'EUR',1.00000000,20.50000000,0.00000000,20.50000000,NULL,'facture/AC2001-0002/AC2001-0002.pdf',NULL,NULL),(225,'(PROV225)',1,NULL,NULL,0,NULL,NULL,19,'2020-01-16 02:37:48','2022-01-16',NULL,NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,389.50000000,389.50000000,0,12,NULL,NULL,NULL,NULL,NULL,NULL,NULL,2,0,'2021-02-15',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,1,'EUR',1.00000000,389.50000000,0.00000000,389.50000000,NULL,'facture/(PROV225)/(PROV225).pdf',NULL,NULL),(226,'(PROV226)',1,NULL,NULL,3,NULL,NULL,11,'2020-01-19 14:20:54','2022-01-19',NULL,NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,12.50000000,0.00000000,0.00000000,0.00000000,120.00000000,132.50000000,0,12,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,'2022-01-19',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,1,'EUR',1.00000000,120.00000000,12.50000000,132.50000000,NULL,'facture/(PROV226)/(PROV226).pdf',NULL,NULL),(227,'AC2001-0003',1,NULL,NULL,3,NULL,NULL,1,'2020-01-19 14:22:54','2022-01-19','2022-01-19 00:00:00',NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,39.20000000,0.00000000,0.00000000,0.00000000,200.00000000,239.20000000,0,12,NULL,12,NULL,NULL,NULL,NULL,NULL,1,0,'2022-01-19',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,1,'EUR',1.00000000,200.00000000,39.20000000,239.20000000,NULL,'facture/AC2001-0003/AC2001-0003.pdf',NULL,NULL),(228,'AC2001-0004',1,NULL,NULL,3,NULL,NULL,1,'2020-01-19 14:24:49','2022-01-19','2022-01-19 00:00:00',NULL,'2022-02-07 13:37:54',0,0.00000000,NULL,NULL,0,NULL,NULL,1.94000000,0.00000000,0.00000000,0.00000000,48.60000000,50.54000000,1,12,NULL,12,NULL,NULL,NULL,NULL,NULL,1,0,'2022-01-19',NULL,NULL,'crabe',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,1,'EUR',1.00000000,48.60000000,1.94000000,50.54000000,NULL,'facture/AC2001-0004/AC2001-0004.pdf',NULL,NULL),(229,'FA1707-0026',1,NULL,NULL,0,NULL,NULL,12,'2020-01-21 10:23:17','2021-07-18','2023-01-21 00:00:00','2020-01-21 10:23:17','2022-02-07 13:37:54',1,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,50.00000000,50.00000000,2,12,NULL,12,12,NULL,NULL,NULL,NULL,1,0,'2021-07-18',NULL,NULL,'',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,0,'EUR',1.00000000,50.00000000,0.00000000,50.00000000,NULL,'facture/FA1707-0026/FA1707-0026.pdf',NULL,NULL),(230,'FA1807-0027',1,NULL,NULL,0,NULL,NULL,12,'2020-01-21 10:23:28','2021-07-18','2022-01-21 00:00:00','2020-01-21 10:23:28','2022-02-07 13:37:54',1,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,50.00000000,50.00000000,2,12,NULL,12,12,NULL,NULL,NULL,NULL,1,0,'2021-07-18',NULL,NULL,'',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,0,'EUR',1.00000000,50.00000000,0.00000000,50.00000000,NULL,'facture/FA1807-0027/FA1807-0027.pdf',NULL,NULL),(231,'FA1907-0028',1,NULL,NULL,0,NULL,NULL,12,'2020-01-21 10:23:49','2021-07-18','2022-01-21 00:00:00','2020-01-21 10:23:49','2022-02-07 13:37:54',1,0.00000000,NULL,NULL,0,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000,50.00000000,50.00000000,2,12,NULL,12,12,NULL,NULL,NULL,NULL,1,0,'2021-07-18',NULL,NULL,'',NULL,NULL,NULL,NULL,0,0,NULL,0,0,'',NULL,NULL,0,'EUR',1.00000000,50.00000000,0.00000000,50.00000000,NULL,'facture/FA1907-0028/FA1907-0028.pdf',NULL,NULL); /*!40000 ALTER TABLE `llx_facture` ENABLE KEYS */; UNLOCK TABLES; @@ -6586,7 +6637,7 @@ CREATE TABLE `llx_facture_fourn` ( `location_incoterms` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `fk_transport_mode` int(11) DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_tx` double(24,8) DEFAULT 1.00000000, `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000, `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000, @@ -6616,7 +6667,7 @@ CREATE TABLE `llx_facture_fourn` ( LOCK TABLES `llx_facture_fourn` WRITE; /*!40000 ALTER TABLE `llx_facture_fourn` DISABLE KEYS */; -INSERT INTO `llx_facture_fourn` VALUES (16,'SI1601-0001','FR70813',1,NULL,0,1,'2014-12-19 15:24:11','2003-04-11','2017-02-06 04:08:22','OVH FR70813',0,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,829.00000000,162.48000000,991.48000000,1,1,NULL,12,NULL,NULL,NULL,NULL,1,NULL,'2003-04-11','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(17,'SI1601-0002','FR81385',1,NULL,0,1,'2015-02-13 17:19:35','2003-06-04','2019-10-04 08:31:30','OVH FR81385',0,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,26.00000000,5.10000000,31.10000000,1,1,NULL,12,NULL,NULL,NULL,NULL,1,NULL,'2003-06-04','','','canelle',NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,'2019-10-04',NULL),(18,'SI1601-0003','FR81385',1,NULL,0,2,'2015-02-13 17:20:25','2003-06-04','2017-02-06 04:08:35','OVH FR81385',0,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,26.00000000,5.10000000,31.10000000,0,1,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,'2003-06-04','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(19,'SI1601-0004','FR813852',1,NULL,0,2,'2015-03-16 17:59:02','2015-03-16','2017-02-06 04:08:38','OVH FR81385',0,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,26.00000000,5.10000000,31.10000000,0,1,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,NULL,'','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(20,'SI1702-0001','INV-AE56ER08',1,NULL,0,13,'2017-02-01 19:00:31','2017-02-01','2017-02-01 15:05:28','',0,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,200.00000000,39.20000000,239.20000000,1,12,NULL,12,NULL,NULL,5,NULL,1,0,'2017-02-01','The customer has called us the 24th april. He agree us to not pay the remain of invoice due to default.
\r\nLet\'s see with our book keeper, if we must cancel invoice or ask the supplier a credit note...',NULL,'canelle',NULL,NULL,0,'',NULL,0,'EUR',1.00000000,200.00000000,39.20000000,239.20000000,NULL,NULL,NULL,NULL),(21,'SI1911-0005','NL-123',1,NULL,0,10,'2019-11-28 15:54:30','2019-11-28','2019-11-28 11:54:46','',0,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,450.00000000,0.00000000,450.00000000,1,12,NULL,12,NULL,NULL,NULL,NULL,1,NULL,'2019-11-28','','',NULL,NULL,NULL,0,'',NULL,1,'EUR',1.00000000,450.00000000,0.00000000,450.00000000,NULL,NULL,'2019-11-28',NULL),(22,'SI2001-0006','INV20200101',1,NULL,0,17,'2020-01-01 17:48:01','2020-01-01','2020-01-16 17:05:43','',0,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,357.00000000,43.75000000,400.75000000,1,12,NULL,12,NULL,NULL,NULL,1,1,2,'2020-01-01','','',NULL,NULL,NULL,0,'',NULL,1,'EUR',1.00000000,357.00000000,43.75000000,400.75000000,NULL,NULL,'2020-01-16',NULL),(27,'SA2001-0001','CN01',1,NULL,2,17,'2020-01-01 20:21:51','2020-01-01','2020-01-15 18:20:50','',1,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,-350.00000000,-43.75000000,-393.75000000,2,12,12,12,NULL,22,NULL,NULL,1,NULL,NULL,'','ddd',NULL,NULL,NULL,0,'',NULL,1,'EUR',1.00000000,350.00000000,43.75000000,393.75000000,NULL,NULL,'2020-01-01',NULL),(28,'SI2001-0007','INV02',1,NULL,0,17,'2020-01-01 20:22:48','2020-01-01','2020-01-01 18:06:02','',0,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,79.17000000,9.89000000,89.06000000,1,12,NULL,12,NULL,NULL,NULL,NULL,1,NULL,'2020-01-01','','',NULL,NULL,NULL,0,'',NULL,1,'EUR',1.00000000,79.17000000,9.89000000,89.06000000,NULL,NULL,'2020-01-01',NULL),(30,'SA2001-0002','555',1,NULL,2,1,'2020-01-01 20:51:32','2020-01-01','2020-01-01 17:15:57','',0,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,-26.00000000,-5.10000000,-31.10000000,1,12,NULL,12,NULL,17,NULL,NULL,1,NULL,NULL,'','',NULL,NULL,NULL,0,'',NULL,1,'EUR',1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,'2020-01-01',NULL); +INSERT INTO `llx_facture_fourn` VALUES (16,'SI1601-0001','FR70813',1,NULL,0,1,'2014-12-19 15:24:11','2003-04-11','2017-02-06 04:08:22','OVH FR70813',0,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,829.00000000,162.48000000,991.48000000,1,1,NULL,12,NULL,NULL,NULL,NULL,1,NULL,'2003-04-11','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(17,'SI1601-0002','FR81385',1,NULL,0,1,'2015-02-13 17:19:35','2003-06-04','2019-10-04 08:31:30','OVH FR81385',0,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,26.00000000,5.10000000,31.10000000,1,1,NULL,12,NULL,NULL,NULL,NULL,1,NULL,'2003-06-04','','','canelle',NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,'2019-10-04',NULL),(18,'SI1601-0003','FR81385',1,NULL,0,2,'2015-02-13 17:20:25','2003-06-04','2017-02-06 04:08:35','OVH FR81385',0,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,26.00000000,5.10000000,31.10000000,0,1,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,'2003-06-04','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(19,'SI1601-0004','FR813852',1,NULL,0,2,'2015-03-16 17:59:02','2015-03-16','2017-02-06 04:08:38','OVH FR81385',0,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,26.00000000,5.10000000,31.10000000,0,1,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,NULL,'','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL),(20,'SI1702-0001','INV-AE56ER08',1,NULL,0,13,'2017-02-01 19:00:31','2017-02-01','2017-02-01 15:05:28','',0,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,200.00000000,39.20000000,239.20000000,1,12,NULL,12,NULL,NULL,5,NULL,1,0,'2017-02-01','The customer has called us the 24th april. He agree us to not pay the remain of invoice due to default.
\r\nLet\'s see with our book keeper, if we must cancel invoice or ask the supplier a credit note...',NULL,'canelle',NULL,NULL,0,'',NULL,0,'EUR',1.00000000,200.00000000,39.20000000,239.20000000,NULL,NULL,NULL,NULL),(21,'SI1911-0005','NL-123',1,NULL,0,10,'2019-11-28 15:54:30','2019-11-28','2019-11-28 11:54:46','',0,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,450.00000000,0.00000000,450.00000000,1,12,NULL,12,NULL,NULL,NULL,NULL,1,NULL,'2019-11-28','','',NULL,NULL,NULL,0,'',NULL,1,'EUR',1.00000000,450.00000000,0.00000000,450.00000000,NULL,NULL,'2019-11-28',NULL),(22,'SI2001-0006','INV20200101',1,NULL,0,17,'2020-01-01 17:48:01','2020-01-01','2020-01-16 17:05:43','',0,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,357.00000000,43.75000000,400.75000000,1,12,NULL,12,NULL,NULL,NULL,1,1,2,'2020-01-01','','',NULL,NULL,NULL,0,'',NULL,1,'EUR',1.00000000,357.00000000,43.75000000,400.75000000,NULL,NULL,'2020-01-16',NULL),(27,'SA2001-0001','CN01',1,NULL,2,17,'2020-01-01 20:21:51','2020-01-01','2022-02-07 13:38:10','',1,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,-350.00000000,-43.75000000,-393.75000000,2,12,12,12,NULL,22,NULL,NULL,1,NULL,NULL,'','ddd',NULL,NULL,NULL,0,'',NULL,1,'EUR',1.00000000,-350.00000000,-43.75000000,-393.75000000,NULL,NULL,'2020-01-01',NULL),(28,'SI2001-0007','INV02',1,NULL,0,17,'2020-01-01 20:22:48','2020-01-01','2020-01-01 18:06:02','',0,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,79.17000000,9.89000000,89.06000000,1,12,NULL,12,NULL,NULL,NULL,NULL,1,NULL,'2020-01-01','','',NULL,NULL,NULL,0,'',NULL,1,'EUR',1.00000000,79.17000000,9.89000000,89.06000000,NULL,NULL,'2020-01-01',NULL),(30,'SA2001-0002','555',1,NULL,2,1,'2020-01-01 20:51:32','2020-01-01','2020-01-01 17:15:57','',0,0.00000000,0.00000000,NULL,NULL,0.00000000,0.00000000,0.00000000,-26.00000000,-5.10000000,-31.10000000,1,12,NULL,12,NULL,17,NULL,NULL,1,NULL,NULL,'','',NULL,NULL,NULL,0,'',NULL,1,'EUR',1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,'2020-01-01',NULL); /*!40000 ALTER TABLE `llx_facture_fourn` ENABLE KEYS */; UNLOCK TABLES; @@ -6661,7 +6712,7 @@ CREATE TABLE `llx_facture_fourn_det` ( `rang` int(11) DEFAULT 0, `fk_unit` int(11) DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_subprice` double(24,8) DEFAULT 0.00000000, `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000, `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000, @@ -6683,7 +6734,7 @@ CREATE TABLE `llx_facture_fourn_det` ( LOCK TABLES `llx_facture_fourn_det` WRITE; /*!40000 ALTER TABLE `llx_facture_fourn_det` DISABLE KEYS */; -INSERT INTO `llx_facture_fourn_det` VALUES (44,16,NULL,NULL,NULL,NULL,'ref :sd.loc.sp.512.6
6 mois - Location de SuperPlan avec la connexion 512kbs
Du 11/04/2003 à 11/10/2003',414.00000000,495.14400000,1,0,NULL,19.600,'',0.000,'',0.000,'',414.00000000,81.14000000,0.00000000,0.00000000,495.14000000,0,NULL,NULL,0,NULL,105,0,0,NULL,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000),(45,16,NULL,NULL,NULL,NULL,'ref :sd.loc.sp.512.6
6 mois - Location de SuperPlan avec la connexion 512kbs
Du 11/10/2003 à 11/04/2004',414.00000000,495.14400000,1,0,NULL,19.600,'',0.000,'',0.000,'',414.00000000,81.14000000,0.00000000,0.00000000,495.14000000,0,NULL,NULL,0,NULL,104,0,0,NULL,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000),(46,16,NULL,NULL,NULL,NULL,'ref :sd.installation.annuel
Frais de mise en service d\'un serveur dédié pour un paiement annuel
',1.00000000,1.19600000,1,0,NULL,19.600,'',0.000,'',0.000,'',1.00000000,0.20000000,0.00000000,0.00000000,1.20000000,0,NULL,NULL,0,NULL,105,0,0,NULL,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000),(47,17,NULL,NULL,NULL,NULL,'ref :bk.full250.creation
Création du compte backup ftp 250Mo.
',1.00000000,1.19600000,1,0,NULL,19.600,'',0.000,'',0.000,'',1.00000000,0.20000000,0.00000000,0.00000000,1.20000000,0,NULL,NULL,0,NULL,106,0,0,NULL,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000),(48,17,NULL,NULL,NULL,NULL,'ref :bk.full250.12
Redevance pour un backup de 250Mo sur 12 mois
',25.00000000,29.90000000,1,0,NULL,19.600,'',0.000,'',0.000,'',25.00000000,4.90000000,0.00000000,0.00000000,29.90000000,0,NULL,NULL,0,NULL,103,0,0,NULL,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000),(49,18,NULL,NULL,NULL,NULL,'ref :bk.full250.creation
Création du compte backup ftp 250Mo.
',1.00000000,1.19600000,1,0,NULL,19.600,'',0.000,'',0.000,'',1.00000000,0.20000000,0.00000000,0.00000000,1.20000000,0,NULL,NULL,0,NULL,0,0,0,NULL,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000),(50,18,NULL,NULL,NULL,NULL,'ref :bk.full250.12
Redevance pour un backup de 250Mo sur 12 mois
',25.00000000,29.90000000,1,0,NULL,19.600,'',0.000,'',0.000,'',25.00000000,4.90000000,0.00000000,0.00000000,29.90000000,0,NULL,NULL,0,NULL,0,0,0,NULL,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000),(51,19,NULL,NULL,NULL,NULL,'ref :bk.full250.creation
Création du compte backup ftp 250Mo.
',1.00000000,1.19600000,1,0,NULL,19.600,'',0.000,'0',0.000,'0',1.00000000,0.20000000,0.00000000,0.00000000,1.20000000,0,NULL,NULL,0,NULL,0,0,0,NULL,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000),(52,19,NULL,NULL,NULL,NULL,'ref :bk.full250.12
Redevance pour un backup de 250Mo sur 12 mois
',25.00000000,29.90000000,1,0,NULL,19.600,'',0.000,'0',0.000,'0',25.00000000,4.90000000,0.00000000,0.00000000,29.90000000,0,NULL,NULL,0,NULL,0,0,0,NULL,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000),(53,20,NULL,NULL,NULL,NULL,'Chips',20.00000000,23.92000000,10,0,NULL,19.600,'',0.000,'0',0.000,'0',200.00000000,39.20000000,0.00000000,0.00000000,239.20000000,0,NULL,NULL,0,NULL,0,0,0,NULL,0,'EUR',20.00000000,200.00000000,39.20000000,239.20000000),(54,21,NULL,1,'aaa',NULL,'A beatifull pink dress',100.00000000,90.00000000,5,10,NULL,0.000,'',0.000,'0',0.000,'0',450.00000000,0.00000000,0.00000000,0.00000000,450.00000000,0,NULL,NULL,0,NULL,0,0,1,NULL,1,'EUR',100.00000000,450.00000000,0.00000000,450.00000000),(78,22,NULL,1,'BK01',NULL,'A beatifull pink dress',70.00000000,78.75000000,5,0,NULL,12.500,'',0.000,'0',0.000,'0',350.00000000,43.75000000,0.00000000,0.00000000,393.75000000,0,NULL,NULL,0,NULL,0,0,2,NULL,1,'EUR',70.00000000,350.00000000,43.75000000,393.75000000),(83,27,NULL,1,'BK01','Pink dress','A beatifull pink dress',-70.00000000,-78.75000000,5,0,NULL,12.500,'',0.000,'0',0.000,'0',-350.00000000,-43.75000000,0.00000000,0.00000000,-393.75000000,0,NULL,NULL,0,NULL,0,0,2,NULL,1,'EUR',70.00000000,350.00000000,43.75000000,393.75000000),(84,28,NULL,1,'BK01',NULL,'A beatifull pink dress',79.16667000,89.06000000,1,0,NULL,12.500,'',0.000,'0',0.000,'0',79.17000000,9.89000000,0.00000000,0.00000000,89.06000000,0,NULL,NULL,0,NULL,0,0,1,NULL,1,'EUR',79.16667000,79.17000000,9.89000000,89.06000000),(86,30,NULL,NULL,'',NULL,'ref :bk.full250.creation
Création du compte backup ftp 250Mo.
',-1.00000000,-1.20000000,1,0,NULL,19.600,'',0.000,'0',0.000,'0',-1.00000000,-0.20000000,0.00000000,0.00000000,-1.20000000,0,NULL,NULL,0,NULL,0,0,0,NULL,0,'',0.00000000,0.00000000,0.00000000,0.00000000),(87,30,NULL,NULL,'',NULL,'ref :bk.full250.12
Redevance pour un backup de 250Mo sur 12 mois
',-25.00000000,-29.90000000,1,0,NULL,19.600,'',0.000,'0',0.000,'0',-25.00000000,-4.90000000,0.00000000,0.00000000,-29.90000000,0,NULL,NULL,0,NULL,0,0,0,NULL,0,'',0.00000000,0.00000000,0.00000000,0.00000000),(89,22,NULL,2,'BKPEARPIE',NULL,'',7.00000000,7.00000000,1,0,NULL,0.000,'',0.000,'0',0.000,'0',7.00000000,0.00000000,0.00000000,0.00000000,7.00000000,0,NULL,NULL,0,NULL,0,0,3,NULL,1,'EUR',7.00000000,7.00000000,0.00000000,7.00000000); +INSERT INTO `llx_facture_fourn_det` VALUES (44,16,NULL,NULL,NULL,NULL,'ref :sd.loc.sp.512.6
6 mois - Location de SuperPlan avec la connexion 512kbs
Du 11/04/2003 à 11/10/2003',414.00000000,495.14400000,1,0,NULL,19.600,'',0.000,'',0.000,'',414.00000000,81.14000000,0.00000000,0.00000000,495.14000000,0,NULL,NULL,0,NULL,105,0,0,NULL,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000),(45,16,NULL,NULL,NULL,NULL,'ref :sd.loc.sp.512.6
6 mois - Location de SuperPlan avec la connexion 512kbs
Du 11/10/2003 à 11/04/2004',414.00000000,495.14400000,1,0,NULL,19.600,'',0.000,'',0.000,'',414.00000000,81.14000000,0.00000000,0.00000000,495.14000000,0,NULL,NULL,0,NULL,104,0,0,NULL,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000),(46,16,NULL,NULL,NULL,NULL,'ref :sd.installation.annuel
Frais de mise en service d\'un serveur dédié pour un paiement annuel
',1.00000000,1.19600000,1,0,NULL,19.600,'',0.000,'',0.000,'',1.00000000,0.20000000,0.00000000,0.00000000,1.20000000,0,NULL,NULL,0,NULL,105,0,0,NULL,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000),(47,17,NULL,NULL,NULL,NULL,'ref :bk.full250.creation
Création du compte backup ftp 250Mo.
',1.00000000,1.19600000,1,0,NULL,19.600,'',0.000,'',0.000,'',1.00000000,0.20000000,0.00000000,0.00000000,1.20000000,0,NULL,NULL,0,NULL,106,0,0,NULL,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000),(48,17,NULL,NULL,NULL,NULL,'ref :bk.full250.12
Redevance pour un backup de 250Mo sur 12 mois
',25.00000000,29.90000000,1,0,NULL,19.600,'',0.000,'',0.000,'',25.00000000,4.90000000,0.00000000,0.00000000,29.90000000,0,NULL,NULL,0,NULL,103,0,0,NULL,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000),(49,18,NULL,NULL,NULL,NULL,'ref :bk.full250.creation
Création du compte backup ftp 250Mo.
',1.00000000,1.19600000,1,0,NULL,19.600,'',0.000,'',0.000,'',1.00000000,0.20000000,0.00000000,0.00000000,1.20000000,0,NULL,NULL,0,NULL,0,0,0,NULL,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000),(50,18,NULL,NULL,NULL,NULL,'ref :bk.full250.12
Redevance pour un backup de 250Mo sur 12 mois
',25.00000000,29.90000000,1,0,NULL,19.600,'',0.000,'',0.000,'',25.00000000,4.90000000,0.00000000,0.00000000,29.90000000,0,NULL,NULL,0,NULL,0,0,0,NULL,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000),(51,19,NULL,NULL,NULL,NULL,'ref :bk.full250.creation
Création du compte backup ftp 250Mo.
',1.00000000,1.19600000,1,0,NULL,19.600,'',0.000,'0',0.000,'0',1.00000000,0.20000000,0.00000000,0.00000000,1.20000000,0,NULL,NULL,0,NULL,0,0,0,NULL,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000),(52,19,NULL,NULL,NULL,NULL,'ref :bk.full250.12
Redevance pour un backup de 250Mo sur 12 mois
',25.00000000,29.90000000,1,0,NULL,19.600,'',0.000,'0',0.000,'0',25.00000000,4.90000000,0.00000000,0.00000000,29.90000000,0,NULL,NULL,0,NULL,0,0,0,NULL,NULL,NULL,0.00000000,0.00000000,0.00000000,0.00000000),(53,20,NULL,NULL,NULL,NULL,'Chips',20.00000000,23.92000000,10,0,NULL,19.600,'',0.000,'0',0.000,'0',200.00000000,39.20000000,0.00000000,0.00000000,239.20000000,0,NULL,NULL,0,NULL,0,0,0,NULL,0,'EUR',20.00000000,200.00000000,39.20000000,239.20000000),(54,21,NULL,1,'aaa',NULL,'A beatifull pink dress',100.00000000,90.00000000,5,10,NULL,0.000,'',0.000,'0',0.000,'0',450.00000000,0.00000000,0.00000000,0.00000000,450.00000000,0,NULL,NULL,0,NULL,0,0,1,NULL,1,'EUR',100.00000000,450.00000000,0.00000000,450.00000000),(78,22,NULL,1,'BK01',NULL,'A beatifull pink dress',70.00000000,78.75000000,5,0,NULL,12.500,'',0.000,'0',0.000,'0',350.00000000,43.75000000,0.00000000,0.00000000,393.75000000,0,NULL,NULL,0,NULL,0,0,2,NULL,1,'EUR',70.00000000,350.00000000,43.75000000,393.75000000),(83,27,NULL,1,'BK01','Pink dress','A beatifull pink dress',-70.00000000,-78.75000000,5,0,NULL,12.500,'',0.000,'0',0.000,'0',-350.00000000,-43.75000000,0.00000000,0.00000000,-393.75000000,0,NULL,NULL,0,NULL,0,0,2,NULL,1,'EUR',-70.00000000,-350.00000000,-43.75000000,-393.75000000),(84,28,NULL,1,'BK01',NULL,'A beatifull pink dress',79.16667000,89.06000000,1,0,NULL,12.500,'',0.000,'0',0.000,'0',79.17000000,9.89000000,0.00000000,0.00000000,89.06000000,0,NULL,NULL,0,NULL,0,0,1,NULL,1,'EUR',79.16667000,79.17000000,9.89000000,89.06000000),(86,30,NULL,NULL,'',NULL,'ref :bk.full250.creation
Création du compte backup ftp 250Mo.
',-1.00000000,-1.20000000,1,0,NULL,19.600,'',0.000,'0',0.000,'0',-1.00000000,-0.20000000,0.00000000,0.00000000,-1.20000000,0,NULL,NULL,0,NULL,0,0,0,NULL,0,'',0.00000000,0.00000000,0.00000000,0.00000000),(87,30,NULL,NULL,'',NULL,'ref :bk.full250.12
Redevance pour un backup de 250Mo sur 12 mois
',-25.00000000,-29.90000000,1,0,NULL,19.600,'',0.000,'0',0.000,'0',-25.00000000,-4.90000000,0.00000000,0.00000000,-29.90000000,0,NULL,NULL,0,NULL,0,0,0,NULL,0,'',0.00000000,0.00000000,0.00000000,0.00000000),(89,22,NULL,2,'BKPEARPIE',NULL,'',7.00000000,7.00000000,1,0,NULL,0.000,'',0.000,'0',0.000,'0',7.00000000,0.00000000,0.00000000,0.00000000,7.00000000,0,NULL,NULL,0,NULL,0,0,3,NULL,1,'EUR',7.00000000,7.00000000,0.00000000,7.00000000); /*!40000 ALTER TABLE `llx_facture_fourn_det` ENABLE KEYS */; UNLOCK TABLES; @@ -6782,7 +6833,7 @@ CREATE TABLE `llx_facture_rec` ( `generate_pdf` int(11) DEFAULT 1, `fk_account` int(11) DEFAULT 0, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_tx` double(24,8) DEFAULT 1.00000000, `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000, `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000, @@ -6886,7 +6937,7 @@ CREATE TABLE `llx_facturedet` ( `fk_user_modif` int(11) DEFAULT NULL, `fk_user_author` int(11) DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_subprice` double(24,8) DEFAULT 0.00000000, `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000, `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000, @@ -6977,7 +7028,7 @@ CREATE TABLE `llx_facturedet_rec` ( `fk_unit` int(11) DEFAULT NULL, `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_subprice` double(24,8) DEFAULT 0.00000000, `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000, `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000, @@ -7304,6 +7355,8 @@ CREATE TABLE `llx_holiday` ( `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, `extraparams` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `fk_user_modif` int(11) DEFAULT NULL, + `date_approve` datetime DEFAULT NULL, + `fk_user_approve` int(11) DEFAULT NULL, PRIMARY KEY (`rowid`), KEY `idx_holiday_fk_user` (`fk_user`), KEY `idx_holiday_date_debut` (`date_debut`), @@ -7321,7 +7374,7 @@ CREATE TABLE `llx_holiday` ( LOCK TABLES `llx_holiday` WRITE; /*!40000 ALTER TABLE `llx_holiday` DISABLE KEYS */; -INSERT INTO `llx_holiday` VALUES (1,1,'2021-02-17 19:06:35','gdf','2021-02-10','2021-02-11',0,3,1,'2021-02-17 19:06:57',1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,'2021-04-15 10:22:31',1,'1',NULL,NULL,NULL,NULL),(2,12,'2020-01-22 19:10:01','','2020-12-28','2021-01-03',0,1,11,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,12,5,'2021-04-15 10:22:31',1,'2',NULL,NULL,NULL,NULL),(3,13,'2021-01-22 19:10:29','','2021-01-11','2021-01-13',0,2,11,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,12,5,'2021-04-15 10:22:31',1,'3',NULL,NULL,NULL,NULL); +INSERT INTO `llx_holiday` VALUES (1,1,'2021-02-17 19:06:35','gdf','2021-02-10','2021-02-11',0,3,1,'2021-02-17 19:06:57',1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,'2021-04-15 10:22:31',1,'1',NULL,NULL,NULL,NULL,NULL,NULL),(2,12,'2022-01-22 19:10:01','','2021-12-28','2022-01-03',0,1,11,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,12,5,'2022-02-07 13:37:54',1,'2',NULL,NULL,NULL,NULL,NULL,NULL),(3,13,'2022-01-22 19:10:29','','2022-01-11','2022-01-13',0,2,11,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,12,5,'2022-02-07 13:37:54',1,'3',NULL,NULL,NULL,NULL,NULL,NULL); /*!40000 ALTER TABLE `llx_holiday` ENABLE KEYS */; UNLOCK TABLES; @@ -7348,7 +7401,7 @@ CREATE TABLE `llx_holiday_config` ( LOCK TABLES `llx_holiday_config` WRITE; /*!40000 ALTER TABLE `llx_holiday_config` DISABLE KEYS */; -INSERT INTO `llx_holiday_config` VALUES (1,'userGroup','1'),(2,'lastUpdate','20210415073001'),(3,'nbUser',''),(4,'delayForRequest','31'),(5,'AlertValidatorDelay','0'),(6,'AlertValidatorSolde','0'),(7,'nbHolidayDeducted','1'),(8,'nbHolidayEveryMonth','2.08334'); +INSERT INTO `llx_holiday_config` VALUES (1,'userGroup','1'),(2,'lastUpdate','20220207142959'),(3,'nbUser',''),(4,'delayForRequest','31'),(5,'AlertValidatorDelay','0'),(6,'AlertValidatorSolde','0'),(7,'nbHolidayDeducted','1'),(8,'nbHolidayEveryMonth','2.08334'); /*!40000 ALTER TABLE `llx_holiday_config` ENABLE KEYS */; UNLOCK TABLES; @@ -7433,6 +7486,358 @@ INSERT INTO `llx_holiday_users` VALUES (0,0,1),(1,74.00334000000001,1),(1,25,3), /*!40000 ALTER TABLE `llx_holiday_users` ENABLE KEYS */; UNLOCK TABLES; +-- +-- Table structure for table `llx_hrm_evaluation` +-- + +DROP TABLE IF EXISTS `llx_hrm_evaluation`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `llx_hrm_evaluation` ( + `rowid` int(11) NOT NULL AUTO_INCREMENT, + `ref` varchar(128) COLLATE utf8_unicode_ci NOT NULL DEFAULT '(PROV)', + `label` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `description` text COLLATE utf8_unicode_ci DEFAULT NULL, + `note_public` text COLLATE utf8_unicode_ci DEFAULT NULL, + `note_private` text COLLATE utf8_unicode_ci DEFAULT NULL, + `date_creation` datetime NOT NULL, + `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(), + `fk_user_creat` int(11) NOT NULL, + `fk_user_modif` int(11) DEFAULT NULL, + `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, + `status` smallint(6) NOT NULL, + `date_eval` date DEFAULT NULL, + `fk_user` int(11) NOT NULL, + `fk_job` int(11) NOT NULL, + PRIMARY KEY (`rowid`), + KEY `idx_hrm_evaluation_rowid` (`rowid`), + KEY `idx_hrm_evaluation_ref` (`ref`), + KEY `llx_hrm_evaluation_fk_user_creat` (`fk_user_creat`), + KEY `idx_hrm_evaluation_status` (`status`), + CONSTRAINT `llx_hrm_evaluation_fk_user_creat` FOREIGN KEY (`fk_user_creat`) REFERENCES `llx_user` (`rowid`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `llx_hrm_evaluation` +-- + +LOCK TABLES `llx_hrm_evaluation` WRITE; +/*!40000 ALTER TABLE `llx_hrm_evaluation` DISABLE KEYS */; +/*!40000 ALTER TABLE `llx_hrm_evaluation` ENABLE KEYS */; +UNLOCK TABLES; + +-- +-- Table structure for table `llx_hrm_evaluation_extrafields` +-- + +DROP TABLE IF EXISTS `llx_hrm_evaluation_extrafields`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `llx_hrm_evaluation_extrafields` ( + `rowid` int(11) NOT NULL AUTO_INCREMENT, + `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(), + `fk_object` int(11) NOT NULL, + `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, + PRIMARY KEY (`rowid`), + KEY `idx_evaluation_fk_object` (`fk_object`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `llx_hrm_evaluation_extrafields` +-- + +LOCK TABLES `llx_hrm_evaluation_extrafields` WRITE; +/*!40000 ALTER TABLE `llx_hrm_evaluation_extrafields` DISABLE KEYS */; +/*!40000 ALTER TABLE `llx_hrm_evaluation_extrafields` ENABLE KEYS */; +UNLOCK TABLES; + +-- +-- Table structure for table `llx_hrm_evaluationdet` +-- + +DROP TABLE IF EXISTS `llx_hrm_evaluationdet`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `llx_hrm_evaluationdet` ( + `rowid` int(11) NOT NULL AUTO_INCREMENT, + `date_creation` datetime NOT NULL, + `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(), + `fk_user_creat` int(11) NOT NULL, + `fk_user_modif` int(11) DEFAULT NULL, + `fk_skill` int(11) NOT NULL, + `fk_evaluation` int(11) NOT NULL, + `rankorder` int(11) NOT NULL, + `required_rank` int(11) NOT NULL, + `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, + PRIMARY KEY (`rowid`), + KEY `idx_hrm_evaluationdet_rowid` (`rowid`), + KEY `llx_hrm_evaluationdet_fk_user_creat` (`fk_user_creat`), + KEY `idx_hrm_evaluationdet_fk_skill` (`fk_skill`), + KEY `idx_hrm_evaluationdet_fk_evaluation` (`fk_evaluation`), + CONSTRAINT `llx_hrm_evaluationdet_fk_user_creat` FOREIGN KEY (`fk_user_creat`) REFERENCES `llx_user` (`rowid`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `llx_hrm_evaluationdet` +-- + +LOCK TABLES `llx_hrm_evaluationdet` WRITE; +/*!40000 ALTER TABLE `llx_hrm_evaluationdet` DISABLE KEYS */; +/*!40000 ALTER TABLE `llx_hrm_evaluationdet` ENABLE KEYS */; +UNLOCK TABLES; + +-- +-- Table structure for table `llx_hrm_evaluationdet_extrafields` +-- + +DROP TABLE IF EXISTS `llx_hrm_evaluationdet_extrafields`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `llx_hrm_evaluationdet_extrafields` ( + `rowid` int(11) NOT NULL AUTO_INCREMENT, + `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(), + `fk_object` int(11) NOT NULL, + `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, + PRIMARY KEY (`rowid`), + KEY `idx_evaluationdet_fk_object` (`fk_object`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `llx_hrm_evaluationdet_extrafields` +-- + +LOCK TABLES `llx_hrm_evaluationdet_extrafields` WRITE; +/*!40000 ALTER TABLE `llx_hrm_evaluationdet_extrafields` DISABLE KEYS */; +/*!40000 ALTER TABLE `llx_hrm_evaluationdet_extrafields` ENABLE KEYS */; +UNLOCK TABLES; + +-- +-- Table structure for table `llx_hrm_job` +-- + +DROP TABLE IF EXISTS `llx_hrm_job`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `llx_hrm_job` ( + `rowid` int(11) NOT NULL AUTO_INCREMENT, + `label` varchar(255) COLLATE utf8_unicode_ci NOT NULL, + `description` text COLLATE utf8_unicode_ci DEFAULT NULL, + `date_creation` datetime NOT NULL, + `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(), + `deplacement` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `note_public` text COLLATE utf8_unicode_ci DEFAULT NULL, + `note_private` text COLLATE utf8_unicode_ci DEFAULT NULL, + `fk_user_creat` int(11) DEFAULT NULL, + `fk_user_modif` int(11) DEFAULT NULL, + PRIMARY KEY (`rowid`), + KEY `idx_hrm_job_rowid` (`rowid`), + KEY `idx_hrm_job_label` (`label`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `llx_hrm_job` +-- + +LOCK TABLES `llx_hrm_job` WRITE; +/*!40000 ALTER TABLE `llx_hrm_job` DISABLE KEYS */; +/*!40000 ALTER TABLE `llx_hrm_job` ENABLE KEYS */; +UNLOCK TABLES; + +-- +-- Table structure for table `llx_hrm_job_extrafields` +-- + +DROP TABLE IF EXISTS `llx_hrm_job_extrafields`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `llx_hrm_job_extrafields` ( + `rowid` int(11) NOT NULL AUTO_INCREMENT, + `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(), + `fk_object` int(11) NOT NULL, + `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, + PRIMARY KEY (`rowid`), + KEY `idx_job_fk_object` (`fk_object`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `llx_hrm_job_extrafields` +-- + +LOCK TABLES `llx_hrm_job_extrafields` WRITE; +/*!40000 ALTER TABLE `llx_hrm_job_extrafields` DISABLE KEYS */; +/*!40000 ALTER TABLE `llx_hrm_job_extrafields` ENABLE KEYS */; +UNLOCK TABLES; + +-- +-- Table structure for table `llx_hrm_job_user` +-- + +DROP TABLE IF EXISTS `llx_hrm_job_user`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `llx_hrm_job_user` ( + `rowid` int(11) NOT NULL AUTO_INCREMENT, + `description` text COLLATE utf8_unicode_ci DEFAULT NULL, + `date_creation` datetime NOT NULL, + `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(), + `fk_contrat` int(11) DEFAULT NULL, + `fk_user` int(11) DEFAULT NULL, + `fk_job` int(11) NOT NULL, + `date_start` date DEFAULT NULL, + `date_end` date DEFAULT NULL, + `abort_comment` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `note_public` text COLLATE utf8_unicode_ci DEFAULT NULL, + `note_private` text COLLATE utf8_unicode_ci DEFAULT NULL, + `fk_user_creat` int(11) DEFAULT NULL, + `fk_user_modif` int(11) DEFAULT NULL, + PRIMARY KEY (`rowid`), + KEY `idx_hrm_job_user_rowid` (`rowid`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `llx_hrm_job_user` +-- + +LOCK TABLES `llx_hrm_job_user` WRITE; +/*!40000 ALTER TABLE `llx_hrm_job_user` DISABLE KEYS */; +/*!40000 ALTER TABLE `llx_hrm_job_user` ENABLE KEYS */; +UNLOCK TABLES; + +-- +-- Table structure for table `llx_hrm_skill` +-- + +DROP TABLE IF EXISTS `llx_hrm_skill`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `llx_hrm_skill` ( + `rowid` int(11) NOT NULL AUTO_INCREMENT, + `label` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `description` text COLLATE utf8_unicode_ci DEFAULT NULL, + `date_creation` datetime NOT NULL, + `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(), + `fk_user_creat` int(11) NOT NULL, + `fk_user_modif` int(11) DEFAULT NULL, + `required_level` int(11) NOT NULL, + `date_validite` int(11) NOT NULL, + `temps_theorique` double(24,8) NOT NULL, + `skill_type` int(11) NOT NULL, + `note_public` text COLLATE utf8_unicode_ci DEFAULT NULL, + `note_private` text COLLATE utf8_unicode_ci DEFAULT NULL, + PRIMARY KEY (`rowid`), + KEY `idx_hrm_skill_rowid` (`rowid`), + KEY `llx_hrm_skill_fk_user_creat` (`fk_user_creat`), + KEY `idx_hrm_skill_skill_type` (`skill_type`), + CONSTRAINT `llx_hrm_skill_fk_user_creat` FOREIGN KEY (`fk_user_creat`) REFERENCES `llx_user` (`rowid`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `llx_hrm_skill` +-- + +LOCK TABLES `llx_hrm_skill` WRITE; +/*!40000 ALTER TABLE `llx_hrm_skill` DISABLE KEYS */; +/*!40000 ALTER TABLE `llx_hrm_skill` ENABLE KEYS */; +UNLOCK TABLES; + +-- +-- Table structure for table `llx_hrm_skill_extrafields` +-- + +DROP TABLE IF EXISTS `llx_hrm_skill_extrafields`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `llx_hrm_skill_extrafields` ( + `rowid` int(11) NOT NULL AUTO_INCREMENT, + `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(), + `fk_object` int(11) NOT NULL, + `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, + PRIMARY KEY (`rowid`), + KEY `idx_skill_fk_object` (`fk_object`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `llx_hrm_skill_extrafields` +-- + +LOCK TABLES `llx_hrm_skill_extrafields` WRITE; +/*!40000 ALTER TABLE `llx_hrm_skill_extrafields` DISABLE KEYS */; +/*!40000 ALTER TABLE `llx_hrm_skill_extrafields` ENABLE KEYS */; +UNLOCK TABLES; + +-- +-- Table structure for table `llx_hrm_skilldet` +-- + +DROP TABLE IF EXISTS `llx_hrm_skilldet`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `llx_hrm_skilldet` ( + `rowid` int(11) NOT NULL AUTO_INCREMENT, + `description` text COLLATE utf8_unicode_ci DEFAULT NULL, + `fk_user_creat` int(11) NOT NULL, + `fk_user_modif` int(11) DEFAULT NULL, + `fk_skill` int(11) NOT NULL, + `rankorder` int(11) DEFAULT NULL, + PRIMARY KEY (`rowid`), + KEY `idx_hrm_skilldet_rowid` (`rowid`), + KEY `llx_hrm_skilldet_fk_user_creat` (`fk_user_creat`), + CONSTRAINT `llx_hrm_skilldet_fk_user_creat` FOREIGN KEY (`fk_user_creat`) REFERENCES `llx_user` (`rowid`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `llx_hrm_skilldet` +-- + +LOCK TABLES `llx_hrm_skilldet` WRITE; +/*!40000 ALTER TABLE `llx_hrm_skilldet` DISABLE KEYS */; +/*!40000 ALTER TABLE `llx_hrm_skilldet` ENABLE KEYS */; +UNLOCK TABLES; + +-- +-- Table structure for table `llx_hrm_skillrank` +-- + +DROP TABLE IF EXISTS `llx_hrm_skillrank`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `llx_hrm_skillrank` ( + `rowid` int(11) NOT NULL AUTO_INCREMENT, + `fk_skill` int(11) NOT NULL, + `rankorder` int(11) NOT NULL, + `fk_object` int(11) NOT NULL, + `date_creation` datetime NOT NULL, + `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(), + `fk_user_creat` int(11) NOT NULL, + `fk_user_modif` int(11) DEFAULT NULL, + `objecttype` varchar(128) COLLATE utf8_unicode_ci NOT NULL, + PRIMARY KEY (`rowid`), + KEY `idx_hrm_skillrank_rowid` (`rowid`), + KEY `idx_hrm_skillrank_fk_skill` (`fk_skill`), + KEY `llx_hrm_skillrank_fk_user_creat` (`fk_user_creat`), + CONSTRAINT `llx_hrm_skillrank_fk_user_creat` FOREIGN KEY (`fk_user_creat`) REFERENCES `llx_user` (`rowid`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `llx_hrm_skillrank` +-- + +LOCK TABLES `llx_hrm_skillrank` WRITE; +/*!40000 ALTER TABLE `llx_hrm_skillrank` DISABLE KEYS */; +/*!40000 ALTER TABLE `llx_hrm_skillrank` ENABLE KEYS */; +UNLOCK TABLES; + -- -- Table structure for table `llx_import_model` -- @@ -7474,7 +7879,7 @@ CREATE TABLE `llx_intracommreport` ( `ref` varchar(30) CHARACTER SET utf8mb4 NOT NULL, `entity` int(11) NOT NULL DEFAULT 1, `type_declaration` varchar(32) CHARACTER SET utf8mb4 DEFAULT NULL, - `period` varchar(32) CHARACTER SET utf8mb4 DEFAULT NULL, + `periods` varchar(32) COLLATE utf8_unicode_ci DEFAULT NULL, `mode` varchar(32) CHARACTER SET utf8mb4 DEFAULT NULL, `content_xml` text CHARACTER SET utf8mb4 DEFAULT NULL, `type_export` varchar(10) CHARACTER SET utf8mb4 DEFAULT NULL, @@ -7558,6 +7963,7 @@ CREATE TABLE `llx_inventorydet` ( `qty_view` double DEFAULT NULL, `qty_stock` double DEFAULT NULL, `qty_regulated` double DEFAULT NULL, + `fk_movement` int(11) DEFAULT NULL, PRIMARY KEY (`rowid`), UNIQUE KEY `uk_inventorydet` (`fk_inventory`,`fk_warehouse`,`fk_product`,`batch`), KEY `idx_inventorydet_tms` (`tms`), @@ -7599,8 +8005,10 @@ CREATE TABLE `llx_knowledgemanagement_knowledgerecord` ( `fk_ticket` int(11) DEFAULT NULL, `fk_c_ticket_category` int(11) DEFAULT NULL, `status` int(11) NOT NULL, + `lang` varchar(6) COLLATE utf8_unicode_ci DEFAULT NULL, + `entity` int(11) DEFAULT 1, PRIMARY KEY (`rowid`) -) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -7609,6 +8017,7 @@ CREATE TABLE `llx_knowledgemanagement_knowledgerecord` ( LOCK TABLES `llx_knowledgemanagement_knowledgerecord` WRITE; /*!40000 ALTER TABLE `llx_knowledgemanagement_knowledgerecord` DISABLE KEYS */; +INSERT INTO `llx_knowledgemanagement_knowledgerecord` VALUES (1,'(PROV1)','2022-02-07 13:40:53','2022-02-07 13:40:53',NULL,12,NULL,NULL,NULL,NULL,'This is a FAQ 1','And this is the solution of the FAQ 1',NULL,NULL,NULL,0,'en_US',1),(2,'KM2202-0001','2022-02-07 13:50:46','2022-02-07 13:50:49',NULL,12,NULL,12,NULL,NULL,'This is a FAQ 2','This is solution of FAQ 2',NULL,NULL,NULL,1,'',1); /*!40000 ALTER TABLE `llx_knowledgemanagement_knowledgerecord` ENABLE KEYS */; UNLOCK TABLES; @@ -7933,7 +8342,7 @@ CREATE TABLE `llx_menu` ( PRIMARY KEY (`rowid`), UNIQUE KEY `idx_menu_uk_menu` (`menu_handler`,`fk_menu`,`position`,`url`,`entity`), KEY `idx_menu_menuhandler_type` (`menu_handler`,`type`) -) ENGINE=InnoDB AUTO_INCREMENT=167134 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=167187 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -7942,7 +8351,7 @@ CREATE TABLE `llx_menu` ( LOCK TABLES `llx_menu` WRITE; /*!40000 ALTER TABLE `llx_menu` DISABLE KEYS */; -INSERT INTO `llx_menu` VALUES (103094,'all',2,'agenda','top','agenda',0,NULL,NULL,100,'/comm/action/index.php','','Agenda',NULL,'agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103095,'all',2,'agenda','left','agenda',103094,NULL,NULL,100,'/comm/action/index.php?mainmenu=agenda&leftmenu=agenda','','Actions',NULL,'agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103096,'all',2,'agenda','left','agenda',103095,NULL,NULL,101,'/comm/action/card.php?mainmenu=agenda&leftmenu=agenda&action=create','','NewAction',NULL,'commercial',NULL,NULL,'($user->rights->agenda->myactions->create||$user->rights->agenda->allactions->create)','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103097,'all',2,'agenda','left','agenda',103095,NULL,NULL,102,'/comm/action/index.php?mainmenu=agenda&leftmenu=agenda','','Calendar',NULL,'agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103098,'all',2,'agenda','left','agenda',103097,NULL,NULL,103,'/comm/action/index.php?mainmenu=agenda&leftmenu=agenda&status=todo&filter=mine','','MenuToDoMyActions',NULL,'agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103099,'all',2,'agenda','left','agenda',103097,NULL,NULL,104,'/comm/action/index.php?mainmenu=agenda&leftmenu=agenda&status=done&filter=mine','','MenuDoneMyActions',NULL,'agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103100,'all',2,'agenda','left','agenda',103097,NULL,NULL,105,'/comm/action/index.php?mainmenu=agenda&leftmenu=agenda&status=todo','','MenuToDoActions',NULL,'agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$user->rights->agenda->allactions->read',2,'2015-03-13 15:29:19'),(103101,'all',2,'agenda','left','agenda',103097,NULL,NULL,106,'/comm/action/index.php?mainmenu=agenda&leftmenu=agenda&status=done','','MenuDoneActions',NULL,'agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$user->rights->agenda->allactions->read',2,'2015-03-13 15:29:19'),(103102,'all',2,'agenda','left','agenda',103095,NULL,NULL,112,'/comm/action/listactions.php?mainmenu=agenda&leftmenu=agenda','','List',NULL,'agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103103,'all',2,'agenda','left','agenda',103102,NULL,NULL,113,'/comm/action/listactions.php?mainmenu=agenda&leftmenu=agenda&status=todo&filter=mine','','MenuToDoMyActions',NULL,'agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103104,'all',2,'agenda','left','agenda',103102,NULL,NULL,114,'/comm/action/listactions.php?mainmenu=agenda&leftmenu=agenda&status=done&filter=mine','','MenuDoneMyActions',NULL,'agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103105,'all',2,'agenda','left','agenda',103102,NULL,NULL,115,'/comm/action/listactions.php?mainmenu=agenda&leftmenu=agenda&status=todo','','MenuToDoActions',NULL,'agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$user->rights->agenda->allactions->read',2,'2015-03-13 15:29:19'),(103106,'all',2,'agenda','left','agenda',103102,NULL,NULL,116,'/comm/action/listactions.php?mainmenu=agenda&leftmenu=agenda&status=done','','MenuDoneActions',NULL,'agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$user->rights->agenda->allactions->read',2,'2015-03-13 15:29:19'),(103107,'all',2,'agenda','left','agenda',103095,NULL,NULL,120,'/comm/action/rapport/index.php?mainmenu=agenda&leftmenu=agenda','','Reportings',NULL,'agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103134,'all',2,'opensurvey','top','opensurvey',0,NULL,NULL,200,'/opensurvey/index.php','','Surveys',NULL,'opensurvey',NULL,NULL,'$user->rights->opensurvey->survey->read','$conf->opensurvey->enabled',0,'2015-03-13 20:33:42'),(103135,'all',2,'opensurvey','left','opensurvey',-1,NULL,'opensurvey',200,'/opensurvey/index.php?mainmenu=opensurvey&leftmenu=opensurvey','','Survey',NULL,'opensurvey@opensurvey',NULL,'opensurvey','','$conf->opensurvey->enabled',0,'2015-03-13 20:33:42'),(103136,'all',2,'opensurvey','left','opensurvey',-1,'opensurvey','opensurvey',210,'/opensurvey/public/index.php','_blank','NewSurvey',NULL,'opensurvey@opensurvey',NULL,'opensurvey_new','','$conf->opensurvey->enabled',0,'2015-03-13 20:33:42'),(103137,'all',2,'opensurvey','left','opensurvey',-1,'opensurvey','opensurvey',220,'/opensurvey/list.php','','List',NULL,'opensurvey@opensurvey',NULL,'opensurvey_list','','$conf->opensurvey->enabled',0,'2015-03-13 20:33:42'),(161088,'auguria',1,'','top','home',0,NULL,NULL,10,'/index.php?mainmenu=home&leftmenu=','','Home',NULL,'',-1,'','','1',2,'2017-08-30 15:14:30'),(161089,'auguria',1,'societe|fournisseur','top','companies',0,NULL,NULL,20,'/societe/index.php?mainmenu=companies&leftmenu=','','ThirdParties',NULL,'companies',-1,'','$user->rights->societe->lire || $user->rights->societe->contact->lire','( ! empty($conf->societe->enabled) && (empty($conf->global->SOCIETE_DISABLE_PROSPECTS) || empty($conf->global->SOCIETE_DISABLE_CUSTOMERS))) || ! empty($conf->fournisseur->enabled)',2,'2017-08-30 15:14:30'),(161090,'auguria',1,'product|service','top','products',0,NULL,NULL,30,'/product/index.php?mainmenu=products&leftmenu=','','Products/Services',NULL,'products',-1,'','$user->rights->produit->lire||$user->rights->service->lire','$conf->product->enabled || $conf->service->enabled',0,'2017-08-30 15:14:30'),(161092,'auguria',1,'propal|commande|fournisseur|contrat|ficheinter','top','commercial',0,NULL,NULL,40,'/comm/index.php?mainmenu=commercial&leftmenu=','','Commercial',NULL,'commercial',-1,'','$user->rights->societe->lire || $user->rights->societe->contact->lire','$conf->propal->enabled || $conf->commande->enabled || $conf->supplier_order->enabled || $conf->contrat->enabled || $conf->ficheinter->enabled',2,'2017-08-30 15:14:30'),(161093,'auguria',1,'comptabilite|accounting|facture|don|tax|salaries|loan','top','accountancy',0,NULL,NULL,50,'/compta/index.php?mainmenu=accountancy&leftmenu=','','MenuFinancial',NULL,'compta',-1,'','$user->rights->compta->resultat->lire || $user->rights->accounting->plancompte->lire || $user->rights->facture->lire|| $user->rights->don->lire || $user->rights->tax->charges->lire || $user->rights->salaries->read || $user->rights->loan->read','$conf->comptabilite->enabled || $conf->accounting->enabled || $conf->facture->enabled || $conf->don->enabled || $conf->tax->enabled || $conf->salaries->enabled || $conf->supplier_invoice->enabled || $conf->loan->enabled',2,'2017-08-30 15:14:30'),(161094,'auguria',1,'projet','top','project',0,NULL,NULL,70,'/projet/index.php?mainmenu=project&leftmenu=','','Projects',NULL,'projects',-1,'','$user->rights->projet->lire','$conf->projet->enabled',2,'2017-08-30 15:14:30'),(161095,'auguria',1,'mailing|export|import|opensurvey|resource','top','tools',0,NULL,NULL,90,'/core/tools.php?mainmenu=tools&leftmenu=','','Tools',NULL,'other',-1,'','$user->rights->mailing->lire || $user->rights->export->lire || $user->rights->import->run || $user->rights->opensurvey->read || $user->rights->resource->read','$conf->mailing->enabled || $conf->export->enabled || $conf->import->enabled || $conf->opensurvey->enabled || $conf->resource->enabled',2,'2017-08-30 15:14:30'),(161101,'auguria',1,'banque|prelevement','top','bank',0,NULL,NULL,60,'/compta/bank/index.php?mainmenu=bank&leftmenu=bank','','MenuBankCash',NULL,'banks',-1,'','$user->rights->banque->lire || $user->rights->prelevement->bons->lire','$conf->banque->enabled || $conf->prelevement->enabled',0,'2017-08-30 15:14:30'),(161102,'auguria',1,'hrm|holiday|deplacement|expensereport','top','hrm',0,NULL,NULL,80,'/hrm/index.php?mainmenu=hrm&leftmenu=','','HRM',NULL,'holiday',-1,'','$user->rights->hrm->employee->read || $user->rights->holiday->write || $user->rights->deplacement->lire || $user->rights->expensereport->lire','$conf->hrm->enabled || $conf->holiday->enabled || $conf->deplacement->enabled || $conf->expensereport->enabled',0,'2017-08-30 15:14:30'),(161177,'auguria',1,'','left','home',161088,NULL,NULL,0,'/index.php','','MyDashboard',NULL,'',0,'','','1',2,'2017-08-30 15:14:30'),(161187,'auguria',1,'','left','home',161088,NULL,NULL,1,'/admin/index.php?leftmenu=setup','','Setup',NULL,'admin',0,'setup','','$user->admin',2,'2017-08-30 15:14:30'),(161188,'auguria',1,'','left','home',161187,NULL,NULL,1,'/admin/company.php?leftmenu=setup','','MenuCompanySetup',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161189,'auguria',1,'','left','home',161187,NULL,NULL,4,'/admin/ihm.php?leftmenu=setup','','GUISetup',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161190,'auguria',1,'','left','home',161187,NULL,NULL,2,'/admin/modules.php?leftmenu=setup','','Modules',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161191,'auguria',1,'','left','home',161187,NULL,NULL,6,'/admin/boxes.php?leftmenu=setup','','Boxes',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161192,'auguria',1,'','left','home',161187,NULL,NULL,3,'/admin/menus.php?leftmenu=setup','','Menus',NULL,'admin',1,'','','$leftmenu==\'setup\'',2,'2017-09-06 08:29:47'),(161193,'auguria',1,'','left','home',161187,NULL,NULL,7,'/admin/delais.php?leftmenu=setup','','Alerts',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161194,'auguria',1,'','left','home',161187,NULL,NULL,10,'/admin/pdf.php?leftmenu=setup','','PDF',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161195,'auguria',1,'','left','home',161187,NULL,NULL,8,'/admin/security_other.php?leftmenu=setup','','Security',NULL,'admin',1,'','','$leftmenu==\'setup\'',2,'2017-09-06 08:29:36'),(161196,'auguria',1,'','left','home',161187,NULL,NULL,11,'/admin/mails.php?leftmenu=setup','','Emails',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161197,'auguria',1,'','left','home',161187,NULL,NULL,9,'/admin/limits.php?leftmenu=setup','','MenuLimits',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161198,'auguria',1,'','left','home',161187,NULL,NULL,13,'/admin/dict.php?leftmenu=setup','','Dictionary',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161199,'auguria',1,'','left','home',161187,NULL,NULL,14,'/admin/const.php?leftmenu=setup','','OtherSetup',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161200,'auguria',1,'','left','home',161187,NULL,NULL,12,'/admin/sms.php?leftmenu=setup','','SMS',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161201,'auguria',1,'','left','home',161187,NULL,NULL,4,'/admin/translation.php?leftmenu=setup','','Translation',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161288,'auguria',1,'','left','home',161387,NULL,NULL,0,'/admin/system/dolibarr.php?leftmenu=admintools','','InfoDolibarr',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161289,'auguria',1,'','left','home',161288,NULL,NULL,2,'/admin/system/modules.php?leftmenu=admintools','','Modules',NULL,'admin',2,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161290,'auguria',1,'','left','home',161288,NULL,NULL,3,'/admin/triggers.php?leftmenu=admintools','','Triggers',NULL,'admin',2,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161291,'auguria',1,'','left','home',161288,NULL,NULL,4,'/admin/system/filecheck.php?leftmenu=admintools','','FileCheck',NULL,'admin',2,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161292,'auguria',1,'','left','home',161387,NULL,NULL,1,'/admin/system/browser.php?leftmenu=admintools','','InfoBrowser',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161293,'auguria',1,'','left','home',161387,NULL,NULL,2,'/admin/system/os.php?leftmenu=admintools','','InfoOS',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161294,'auguria',1,'','left','home',161387,NULL,NULL,3,'/admin/system/web.php?leftmenu=admintools','','InfoWebServer',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161295,'auguria',1,'','left','home',161387,NULL,NULL,4,'/admin/system/phpinfo.php?leftmenu=admintools','','InfoPHP',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161297,'auguria',1,'','left','home',161387,NULL,NULL,5,'/admin/system/database.php?leftmenu=admintools','','InfoDatabase',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161387,'auguria',1,'','left','home',161088,NULL,NULL,2,'/admin/tools/index.php?leftmenu=admintools','','AdminTools',NULL,'admin',0,'admintools','','$user->admin',2,'2017-08-30 15:14:30'),(161388,'auguria',1,'','left','home',161387,NULL,NULL,6,'/admin/tools/dolibarr_export.php?leftmenu=admintools','','Backup',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161389,'auguria',1,'','left','home',161387,NULL,NULL,7,'/admin/tools/dolibarr_import.php?leftmenu=admintools','','Restore',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161392,'auguria',1,'','left','home',161387,NULL,NULL,8,'/admin/tools/update.php?leftmenu=admintools','','MenuUpgrade',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161393,'auguria',1,'','left','home',161387,NULL,NULL,9,'/admin/tools/eaccelerator.php?leftmenu=admintools','','EAccelerator',NULL,'admin',1,'','','$leftmenu==\"admintools\" && function_exists(\"eaccelerator_info\")',2,'2017-08-30 15:14:30'),(161394,'auguria',1,'','left','home',161387,NULL,NULL,10,'/admin/tools/listevents.php?leftmenu=admintools','','Audit',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161395,'auguria',1,'','left','home',161387,NULL,NULL,11,'/admin/tools/listsessions.php?leftmenu=admintools','','Sessions',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161396,'auguria',1,'','left','home',161387,NULL,NULL,12,'/admin/tools/purge.php?leftmenu=admintools','','Purge',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161398,'auguria',1,'','left','home',161387,NULL,NULL,14,'/admin/system/about.php?leftmenu=admintools','','ExternalResources',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161407,'auguria',1,'','left','home',161387,NULL,NULL,15,'/product/admin/product_tools.php?mainmenu=home&leftmenu=admintools','','ProductVatMassChange',NULL,'products',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161487,'auguria',1,'','left','home',161088,NULL,NULL,4,'/user/home.php?leftmenu=users','','MenuUsersAndGroups',NULL,'users',0,'users','','1',2,'2017-08-30 15:14:30'),(161488,'auguria',1,'','left','home',161487,NULL,NULL,0,'/user/index.php?leftmenu=users','','Users',NULL,'users',1,'','$user->rights->user->user->lire || $user->admin','$leftmenu==\"users\"',2,'2017-08-30 15:14:30'),(161489,'auguria',1,'','left','home',161488,NULL,NULL,0,'/user/card.php?leftmenu=users&action=create','','NewUser',NULL,'users',2,'','($user->rights->user->user->creer || $user->admin) && !(! empty($conf->multicompany->enabled) && $conf->entity > 1 && $conf->global->MULTICOMPANY_TRANSVERSE_MODE)','$leftmenu==\"users\"',2,'2017-08-30 15:14:30'),(161490,'auguria',1,'','left','home',161487,NULL,NULL,1,'/user/group/index.php?leftmenu=users','','Groups',NULL,'users',1,'','(($conf->global->MAIN_USE_ADVANCED_PERMS?$user->rights->user->group_advance->read:$user->rights->user->user->lire) || $user->admin) && !(! empty($conf->multicompany->enabled) && $conf->entity > 1 && $conf->global->MULTICOMPANY_TRANSVERSE_MODE)','$leftmenu==\"users\"',2,'2017-08-30 15:14:30'),(161491,'auguria',1,'','left','home',161490,NULL,NULL,0,'/user/group/card.php?leftmenu=users&action=create','','NewGroup',NULL,'users',2,'','(($conf->global->MAIN_USE_ADVANCED_PERMS?$user->rights->user->group_advance->write:$user->rights->user->user->creer) || $user->admin) && !(! empty($conf->multicompany->enabled) && $conf->entity > 1 && $conf->global->MULTICOMPANY_TRANSVERSE_MODE)','$leftmenu==\"users\"',2,'2017-08-30 15:14:30'),(161587,'auguria',1,'','left','companies',161089,NULL,NULL,0,'/societe/index.php?leftmenu=thirdparties','','ThirdParty',NULL,'companies',0,'thirdparties','$user->rights->societe->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161588,'auguria',1,'','left','companies',161587,NULL,NULL,0,'/societe/card.php?action=create','','MenuNewThirdParty',NULL,'companies',1,'','$user->rights->societe->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161589,'auguria',1,'','left','companies',161587,NULL,NULL,0,'/societe/list.php?action=create','','List',NULL,'companies',1,'','$user->rights->societe->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161590,'auguria',1,'','left','companies',161587,NULL,NULL,5,'/societe/list.php?type=f&leftmenu=suppliers','','ListSuppliersShort',NULL,'suppliers',1,'','$user->rights->societe->lire && $user->rights->fournisseur->lire','$conf->societe->enabled && $conf->fournisseur->enabled',2,'2017-08-30 15:14:30'),(161591,'auguria',1,'','left','companies',161590,NULL,NULL,0,'/societe/card.php?leftmenu=supplier&action=create&type=f','','NewSupplier',NULL,'suppliers',2,'','$user->rights->societe->creer','$conf->societe->enabled && $conf->fournisseur->enabled',2,'2017-08-30 15:14:30'),(161593,'auguria',1,'','left','companies',161587,NULL,NULL,3,'/societe/list.php?type=p&leftmenu=prospects','','ListProspectsShort',NULL,'companies',1,'','$user->rights->societe->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161594,'auguria',1,'','left','companies',161593,NULL,NULL,0,'/societe/card.php?leftmenu=prospects&action=create&type=p','','MenuNewProspect',NULL,'companies',2,'','$user->rights->societe->creer','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161596,'auguria',1,'','left','companies',161587,NULL,NULL,4,'/societe/list.php?type=c&leftmenu=customers','','ListCustomersShort',NULL,'companies',1,'','$user->rights->societe->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161597,'auguria',1,'','left','companies',161596,NULL,NULL,0,'/societe/card.php?leftmenu=customers&action=create&type=c','','MenuNewCustomer',NULL,'companies',2,'','$user->rights->societe->creer','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161687,'auguria',1,'','left','companies',161089,NULL,NULL,1,'/contact/list.php?leftmenu=contacts','','ContactsAddresses',NULL,'companies',0,'contacts','$user->rights->societe->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161688,'auguria',1,'','left','companies',161687,NULL,NULL,0,'/contact/card.php?leftmenu=contacts&action=create','','NewContactAddress',NULL,'companies',1,'','$user->rights->societe->creer','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161689,'auguria',1,'','left','companies',161687,NULL,NULL,1,'/contact/list.php?leftmenu=contacts','','List',NULL,'companies',1,'','$user->rights->societe->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161691,'auguria',1,'','left','companies',161689,NULL,NULL,1,'/contact/list.php?leftmenu=contacts&type=p','','ThirdPartyProspects',NULL,'companies',2,'','$user->rights->societe->contact->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161692,'auguria',1,'','left','companies',161689,NULL,NULL,2,'/contact/list.php?leftmenu=contacts&type=c','','ThirdPartyCustomers',NULL,'companies',2,'','$user->rights->societe->contact->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161693,'auguria',1,'','left','companies',161689,NULL,NULL,3,'/contact/list.php?leftmenu=contacts&type=f','','ThirdPartySuppliers',NULL,'companies',2,'','$user->rights->societe->contact->lire','$conf->societe->enabled && $conf->fournisseur->enabled',2,'2017-08-30 15:14:30'),(161694,'auguria',1,'','left','companies',161689,NULL,NULL,4,'/contact/list.php?leftmenu=contacts&type=o','','Others',NULL,'companies',2,'','$user->rights->societe->contact->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161737,'auguria',1,'','left','companies',161089,NULL,NULL,3,'/categories/index.php?leftmenu=cat&type=1','','SuppliersCategoriesShort',NULL,'categories',0,'cat','$user->rights->categorie->lire','$conf->societe->enabled && $conf->categorie->enabled',2,'2017-08-30 15:14:30'),(161738,'auguria',1,'','left','companies',161737,NULL,NULL,0,'/categories/card.php?action=create&type=1','','NewCategory',NULL,'categories',1,'','$user->rights->categorie->creer','$conf->societe->enabled && $conf->categorie->enabled',2,'2017-08-30 15:14:30'),(161747,'auguria',1,'','left','companies',161089,NULL,NULL,4,'/categories/index.php?leftmenu=cat&type=2','','CustomersProspectsCategoriesShort',NULL,'categories',0,'cat','$user->rights->categorie->lire','$conf->fournisseur->enabled && $conf->categorie->enabled',2,'2017-08-30 15:14:30'),(161748,'auguria',1,'','left','companies',161747,NULL,NULL,0,'/categories/card.php?action=create&type=2','','NewCategory',NULL,'categories',1,'','$user->rights->categorie->creer','$conf->fournisseur->enabled && $conf->categorie->enabled',2,'2017-08-30 15:14:30'),(161757,'auguria',1,'','left','companies',161089,NULL,NULL,3,'/categories/index.php?leftmenu=cat&type=4','','ContactCategoriesShort',NULL,'categories',0,'cat','$user->rights->categorie->lire','$conf->societe->enabled && $conf->categorie->enabled',2,'2017-08-30 15:14:30'),(161758,'auguria',1,'','left','companies',161757,NULL,NULL,0,'/categories/card.php?action=create&type=4','','NewCategory',NULL,'categories',1,'','$user->rights->categorie->creer','$conf->societe->enabled && $conf->categorie->enabled',2,'2017-08-30 15:14:30'),(162187,'auguria',1,'','left','commercial',161092,NULL,NULL,4,'/comm/propal/index.php?leftmenu=propals','','Prop',NULL,'propal',0,'propals','$user->rights->propale->lire','$conf->propal->enabled',2,'2017-08-30 15:14:30'),(162188,'auguria',1,'','left','commercial',162187,NULL,NULL,0,'/comm/propal/card.php?action=create&leftmenu=propals','','NewPropal',NULL,'propal',1,'','$user->rights->propale->creer','$conf->propal->enabled',2,'2017-08-30 15:14:30'),(162189,'auguria',1,'','left','commercial',162187,NULL,NULL,1,'/comm/propal/list.php?leftmenu=propals','','List',NULL,'propal',1,'','$user->rights->propale->lire','$conf->propal->enabled',2,'2017-08-30 15:14:30'),(162190,'auguria',1,'','left','commercial',162189,NULL,NULL,2,'/comm/propal/list.php?leftmenu=propals&search_status=0','','PropalsDraft',NULL,'propal',1,'','$user->rights->propale->lire','$conf->propal->enabled && $leftmenu==\"propals\"',2,'2017-08-30 15:14:30'),(162191,'auguria',1,'','left','commercial',162189,NULL,NULL,3,'/comm/propal/list.php?leftmenu=propals&search_status=1','','PropalsOpened',NULL,'propal',1,'','$user->rights->propale->lire','$conf->propal->enabled && $leftmenu==\"propals\"',2,'2017-08-30 15:14:30'),(162192,'auguria',1,'','left','commercial',162189,NULL,NULL,4,'/comm/propal/list.php?leftmenu=propals&search_status=2','','PropalStatusSigned',NULL,'propal',1,'','$user->rights->propale->lire','$conf->propal->enabled && $leftmenu==\"propals\"',2,'2017-08-30 15:14:30'),(162193,'auguria',1,'','left','commercial',162189,NULL,NULL,5,'/comm/propal/list.php?leftmenu=propals&search_status=3','','PropalStatusNotSigned',NULL,'propal',1,'','$user->rights->propale->lire','$conf->propal->enabled && $leftmenu==\"propals\"',2,'2017-08-30 15:14:30'),(162194,'auguria',1,'','left','commercial',162189,NULL,NULL,6,'/comm/propal/list.php?leftmenu=propals&search_status=4','','PropalStatusBilled',NULL,'propal',1,'','$user->rights->propale->lire','$conf->propal->enabled && $leftmenu==\"propals\"',2,'2017-08-30 15:14:30'),(162197,'auguria',1,'','left','commercial',162187,NULL,NULL,4,'/comm/propal/stats/index.php?leftmenu=propals','','Statistics',NULL,'propal',1,'','$user->rights->propale->lire','$conf->propal->enabled',2,'2017-08-30 15:14:30'),(162287,'auguria',1,'','left','commercial',161092,NULL,NULL,5,'/commande/index.php?leftmenu=orders','','CustomersOrders',NULL,'orders',0,'orders','$user->rights->commande->lire','$conf->commande->enabled',2,'2017-08-30 15:14:30'),(162288,'auguria',1,'','left','commercial',162287,NULL,NULL,0,'/commande/card.php?action=create&leftmenu=orders','','NewOrder',NULL,'orders',1,'','$user->rights->commande->creer','$conf->commande->enabled',2,'2017-08-30 15:14:30'),(162289,'auguria',1,'','left','commercial',162287,NULL,NULL,1,'/commande/list.php?leftmenu=orders','','List',NULL,'orders',1,'','$user->rights->commande->lire','$conf->commande->enabled',2,'2017-08-30 15:14:30'),(162290,'auguria',1,'','left','commercial',162289,NULL,NULL,2,'/commande/list.php?leftmenu=orders&search_status=0','','StatusOrderDraftShort',NULL,'orders',1,'','$user->rights->commande->lire','$conf->commande->enabled && $leftmenu==\"orders\"',2,'2017-08-30 15:14:30'),(162291,'auguria',1,'','left','commercial',162289,NULL,NULL,3,'/commande/list.php?leftmenu=orders&search_status=1','','StatusOrderValidated',NULL,'orders',1,'','$user->rights->commande->lire','$conf->commande->enabled && $leftmenu==\"orders\"',2,'2017-08-30 15:14:30'),(162292,'auguria',1,'','left','commercial',162289,NULL,NULL,4,'/commande/list.php?leftmenu=orders&search_status=2','','StatusOrderOnProcessShort',NULL,'orders',1,'','$user->rights->commande->lire','$conf->commande->enabled && $leftmenu==\"orders\"',2,'2017-08-30 15:14:30'),(162293,'auguria',1,'','left','commercial',162289,NULL,NULL,5,'/commande/list.php?leftmenu=orders&search_status=3','','StatusOrderToBill',NULL,'orders',1,'','$user->rights->commande->lire','$conf->commande->enabled && $leftmenu==\"orders\"',2,'2017-08-30 15:14:30'),(162294,'auguria',1,'','left','commercial',162289,NULL,NULL,6,'/commande/list.php?leftmenu=orders&search_status=4','','StatusOrderProcessed',NULL,'orders',1,'','$user->rights->commande->lire','$conf->commande->enabled && $leftmenu==\"orders\"',2,'2017-08-30 15:14:30'),(162295,'auguria',1,'','left','commercial',162289,NULL,NULL,7,'/commande/list.php?leftmenu=orders&search_status=-1','','StatusOrderCanceledShort',NULL,'orders',1,'','$user->rights->commande->lire','$conf->commande->enabled && $leftmenu==\"orders\"',2,'2017-08-30 15:14:30'),(162296,'auguria',1,'','left','commercial',162287,NULL,NULL,4,'/commande/stats/index.php?leftmenu=orders','','Statistics',NULL,'orders',1,'','$user->rights->commande->lire','$conf->commande->enabled',2,'2017-08-30 15:14:30'),(162387,'auguria',1,'','left','commercial',161090,NULL,NULL,6,'/expedition/index.php?leftmenu=sendings','','Shipments',NULL,'sendings',0,'sendings','$user->rights->expedition->lire','$conf->expedition->enabled',2,'2017-08-30 15:14:30'),(162388,'auguria',1,'','left','commercial',162387,NULL,NULL,0,'/expedition/card.php?action=create2&leftmenu=sendings','','NewSending',NULL,'sendings',1,'','$user->rights->expedition->creer','$conf->expedition->enabled && $leftmenu==\"sendings\"',2,'2017-08-30 15:14:30'),(162389,'auguria',1,'','left','commercial',162387,NULL,NULL,1,'/expedition/list.php?leftmenu=sendings','','List',NULL,'sendings',1,'','$user->rights->expedition->lire','$conf->expedition->enabled && $leftmenu==\"sendings\"',2,'2017-08-30 15:14:30'),(162390,'auguria',1,'','left','commercial',162387,NULL,NULL,2,'/expedition/stats/index.php?leftmenu=sendings','','Statistics',NULL,'sendings',1,'','$user->rights->expedition->lire','$conf->expedition->enabled && $leftmenu==\"sendings\"',2,'2017-08-30 15:14:30'),(162487,'auguria',1,'','left','commercial',161092,NULL,NULL,7,'/contrat/index.php?leftmenu=contracts','','Contracts',NULL,'contracts',0,'contracts','$user->rights->contrat->lire','$conf->contrat->enabled',2,'2017-08-30 15:14:30'),(162488,'auguria',1,'','left','commercial',162487,NULL,NULL,0,'/contrat/card.php?&action=create&leftmenu=contracts','','NewContract',NULL,'contracts',1,'','$user->rights->contrat->creer','$conf->contrat->enabled',2,'2017-08-30 15:14:30'),(162489,'auguria',1,'','left','commercial',162487,NULL,NULL,1,'/contrat/list.php?leftmenu=contracts','','List',NULL,'contracts',1,'','$user->rights->contrat->lire','$conf->contrat->enabled',2,'2017-08-30 15:14:30'),(162490,'auguria',1,'','left','commercial',162487,NULL,NULL,2,'/contrat/services.php?leftmenu=contracts','','MenuServices',NULL,'contracts',1,'','$user->rights->contrat->lire','$conf->contrat->enabled',2,'2017-08-30 15:14:30'),(162491,'auguria',1,'','left','commercial',162490,NULL,NULL,0,'/contrat/services.php?leftmenu=contracts&mode=0','','MenuInactiveServices',NULL,'contracts',2,'','$user->rights->contrat->lire','$conf->contrat->enabled && $leftmenu==\"contracts\"',2,'2017-08-30 15:14:30'),(162492,'auguria',1,'','left','commercial',162490,NULL,NULL,1,'/contrat/services.php?leftmenu=contracts&mode=4','','MenuRunningServices',NULL,'contracts',2,'','$user->rights->contrat->lire','$conf->contrat->enabled && $leftmenu==\"contracts\"',2,'2017-08-30 15:14:30'),(162493,'auguria',1,'','left','commercial',162490,NULL,NULL,2,'/contrat/services.php?leftmenu=contracts&mode=4&filter=expired','','MenuExpiredServices',NULL,'contracts',2,'','$user->rights->contrat->lire','$conf->contrat->enabled && $leftmenu==\"contracts\"',2,'2017-08-30 15:14:30'),(162494,'auguria',1,'','left','commercial',162490,NULL,NULL,3,'/contrat/services.php?leftmenu=contracts&mode=5','','MenuClosedServices',NULL,'contracts',2,'','$user->rights->contrat->lire','$conf->contrat->enabled && $leftmenu==\"contracts\"',2,'2017-08-30 15:14:30'),(162587,'auguria',1,'','left','commercial',161092,NULL,NULL,8,'/fichinter/list.php?leftmenu=ficheinter','','Interventions',NULL,'interventions',0,'ficheinter','$user->rights->ficheinter->lire','$conf->ficheinter->enabled',2,'2017-08-30 15:14:30'),(162588,'auguria',1,'','left','commercial',162587,NULL,NULL,0,'/fichinter/card.php?action=create&leftmenu=ficheinter','','NewIntervention',NULL,'interventions',1,'','$user->rights->ficheinter->creer','$conf->ficheinter->enabled',2,'2017-08-30 15:14:30'),(162589,'auguria',1,'','left','commercial',162587,NULL,NULL,1,'/fichinter/list.php?leftmenu=ficheinter','','List',NULL,'interventions',1,'','$user->rights->ficheinter->lire','$conf->ficheinter->enabled',2,'2017-08-30 15:14:30'),(162590,'auguria',1,'','left','commercial',162587,NULL,NULL,2,'/fichinter/stats/index.php?leftmenu=ficheinter','','Statistics',NULL,'interventions',1,'','$user->rights->ficheinter->lire','$conf->ficheinter->enabled',2,'2017-08-30 15:14:30'),(162687,'auguria',1,'','left','accountancy',161093,NULL,NULL,3,'/fourn/facture/list.php?leftmenu=suppliers_bills','','BillsSuppliers',NULL,'bills',0,'supplier_bills','$user->rights->fournisseur->facture->lire','$conf->supplier_invoice->enabled',2,'2017-08-30 15:14:30'),(162688,'auguria',1,'','left','accountancy',162687,NULL,NULL,0,'/fourn/facture/card.php?action=create&leftmenu=suppliers_bills','','NewBill',NULL,'bills',1,'','$user->rights->fournisseur->facture->creer','$conf->supplier_invoice->enabled',2,'2017-08-30 15:14:30'),(162689,'auguria',1,'','left','accountancy',162687,NULL,NULL,1,'/fourn/facture/list.php?leftmenu=suppliers_bills','','List',NULL,'bills',1,'','$user->rights->fournisseur->facture->lire','$conf->supplier_invoice->enabled',2,'2017-08-30 15:14:30'),(162690,'auguria',1,'','left','accountancy',162687,NULL,NULL,2,'/fourn/facture/paiement.php?leftmenu=suppliers_bills','','Payments',NULL,'bills',1,'','$user->rights->fournisseur->facture->lire','$conf->supplier_invoice->enabled',2,'2017-08-30 15:14:30'),(162691,'auguria',1,'','left','accountancy',162687,NULL,NULL,8,'/compta/facture/stats/index.php?leftmenu=customers_bills&mode=supplier','','Statistics',NULL,'bills',1,'','$user->rights->fournisseur->facture->lire','$conf->supplier_invoice->enabled',2,'2017-08-30 15:14:30'),(162692,'auguria',1,'','left','accountancy',162690,NULL,NULL,1,'/fourn/facture/rapport.php?leftmenu=suppliers_bills','','Reporting',NULL,'bills',2,'','$user->rights->fournisseur->facture->lire','$conf->supplier_invoice->enabled',2,'2017-08-30 15:14:30'),(162787,'auguria',1,'','left','accountancy',161093,NULL,NULL,3,'/compta/facture/list.php?leftmenu=customers_bills','','BillsCustomers',NULL,'bills',0,'customer_bills','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162788,'auguria',1,'','left','accountancy',162787,NULL,NULL,3,'/compta/facture/card.php?action=create&leftmenu=customers_bills','','NewBill',NULL,'bills',1,'','$user->rights->facture->creer','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162789,'auguria',1,'','left','accountancy',162787,NULL,NULL,5,'/compta/facture/fiche-rec.php?leftmenu=customers_bills','','ListOfTemplates',NULL,'bills',1,'','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162791,'auguria',1,'','left','accountancy',162787,NULL,NULL,6,'/compta/paiement/list.php?leftmenu=customers_bills','','Payments',NULL,'bills',1,'','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162792,'auguria',1,'','left','accountancy',162787,NULL,NULL,4,'/compta/facture/list.php?leftmenu=customers_bills','','List',NULL,'bills',1,'','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162797,'auguria',1,'','left','accountancy',162791,NULL,NULL,1,'/compta/paiement/rapport.php?leftmenu=customers_bills','','Reportings',NULL,'bills',2,'','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162798,'auguria',1,'','left','accountancy',161101,NULL,NULL,9,'/compta/paiement/cheque/index.php?leftmenu=checks&mainmenu=bank','','MenuChequeDeposits',NULL,'bills',0,'checks','$user->rights->banque->lire','empty($conf->global->BANK_DISABLE_CHECK_DEPOSIT) && ! empty($conf->banque->enabled) && (! empty($conf->facture->enabled) || ! empty($conf->global->MAIN_MENU_CHEQUE_DEPOSIT_ON))',2,'2017-08-30 15:14:30'),(162799,'auguria',1,'','left','accountancy',162798,NULL,NULL,0,'/compta/paiement/cheque/card.php?leftmenu=checks&action=new','','NewCheckDeposit',NULL,'compta',1,'','$user->rights->banque->lire','empty($conf->global->BANK_DISABLE_CHECK_DEPOSIT) && ! empty($conf->banque->enabled) && (! empty($conf->facture->enabled) || ! empty($conf->global->MAIN_MENU_CHEQUE_DEPOSIT_ON))',2,'2017-08-30 15:14:30'),(162800,'auguria',1,'','left','accountancy',162798,NULL,NULL,1,'/compta/paiement/cheque/list.php?leftmenu=checks','','List',NULL,'bills',1,'','$user->rights->banque->lire','empty($conf->global->BANK_DISABLE_CHECK_DEPOSIT) && ! empty($conf->banque->enabled) && (! empty($conf->facture->enabled) || ! empty($conf->global->MAIN_MENU_CHEQUE_DEPOSIT_ON))',2,'2017-08-30 15:14:30'),(162801,'auguria',1,'','left','accountancy',162787,NULL,NULL,8,'/compta/facture/stats/index.php?leftmenu=customers_bills','','Statistics',NULL,'bills',1,'','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162807,'auguria',1,'','left','accountancy',162792,NULL,NULL,1,'/compta/facture/list.php?leftmenu=customers_bills&search_status=0','','BillShortStatusDraft',NULL,'bills',2,'','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162808,'auguria',1,'','left','accountancy',162792,NULL,NULL,2,'/compta/facture/list.php?leftmenu=customers_bills&search_status=1','','BillShortStatusNotPaid',NULL,'bills',2,'','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162809,'auguria',1,'','left','accountancy',162792,NULL,NULL,3,'/compta/facture/list.php?leftmenu=customers_bills&search_status=2','','BillShortStatusPaid',NULL,'bills',2,'','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162810,'auguria',1,'','left','accountancy',162792,NULL,NULL,4,'/compta/facture/list.php?leftmenu=customers_bills&search_status=3','','BillShortStatusCanceled',NULL,'bills',2,'','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162987,'auguria',1,'','left','accountancy',161093,NULL,NULL,3,'/commande/list.php?leftmenu=orders&search_status=3','','MenuOrdersToBill',NULL,'orders',0,'orders','$user->rights->commande->lire','$conf->commande->enabled',0,'2017-08-30 15:14:30'),(163087,'auguria',1,'','left','accountancy',161093,NULL,NULL,4,'/don/index.php?leftmenu=donations&mainmenu=accountancy','','Donations',NULL,'donations',0,'donations','$user->rights->don->lire','$conf->don->enabled',2,'2017-08-30 15:14:30'),(163088,'auguria',1,'','left','accountancy',163087,NULL,NULL,0,'/don/card.php?leftmenu=donations&mainmenu=accountancy&action=create','','NewDonation',NULL,'donations',1,'','$user->rights->don->creer','$conf->don->enabled && $leftmenu==\"donations\"',2,'2017-08-30 15:14:30'),(163089,'auguria',1,'','left','accountancy',163087,NULL,NULL,1,'/don/list.php?leftmenu=donations&mainmenu=accountancy','','List',NULL,'donations',1,'','$user->rights->don->lire','$conf->don->enabled && $leftmenu==\"donations\"',2,'2017-08-30 15:14:30'),(163187,'auguria',1,'','left','accountancy',161102,NULL,NULL,5,'/compta/deplacement/index.php?leftmenu=tripsandexpenses','','TripsAndExpenses',NULL,'trips',0,'tripsandexpenses','$user->rights->deplacement->lire','$conf->deplacement->enabled',0,'2017-08-30 15:14:30'),(163188,'auguria',1,'','left','accountancy',163187,NULL,NULL,1,'/compta/deplacement/card.php?action=create&leftmenu=tripsandexpenses','','New',NULL,'trips',1,'','$user->rights->deplacement->creer','$conf->deplacement->enabled',0,'2017-08-30 15:14:30'),(163189,'auguria',1,'','left','accountancy',163187,NULL,NULL,2,'/compta/deplacement/list.php?leftmenu=tripsandexpenses','','List',NULL,'trips',1,'','$user->rights->deplacement->lire','$conf->deplacement->enabled',0,'2017-08-30 15:14:30'),(163190,'auguria',1,'','left','accountancy',163187,NULL,NULL,2,'/compta/deplacement/stats/index.php?leftmenu=tripsandexpenses','','Statistics',NULL,'trips',1,'','$user->rights->deplacement->lire','$conf->deplacement->enabled',0,'2017-08-30 15:14:30'),(163287,'auguria',1,'','left','accountancy',161093,NULL,NULL,6,'/compta/charges/index.php?leftmenu=tax&mainmenu=accountancy','','MenuSpecialExpenses',NULL,'compta',0,'tax','(! empty($conf->tax->enabled) && $user->rights->tax->charges->lire) || (! empty($conf->salaries->enabled) && $user->rights->salaries->read)','$conf->tax->enabled || $conf->salaries->enabled',0,'2017-08-30 15:14:30'),(163297,'auguria',1,'','left','accountancy',163287,NULL,NULL,1,'/compta/salaries/index.php?leftmenu=tax_salary&mainmenu=accountancy','','Salaries',NULL,'salaries',1,'tax_sal','$user->rights->salaries->payment->read','$conf->salaries->enabled',0,'2017-08-30 15:14:30'),(163298,'auguria',1,'','left','accountancy',163297,NULL,NULL,2,'/compta/salaries/card.php?leftmenu=tax_salary&action=create','','NewPayment',NULL,'companies',2,'','$user->rights->salaries->payment->write','$conf->salaries->enabled && $leftmenu==\"tax_salary\"',0,'2017-08-30 15:14:30'),(163299,'auguria',1,'','left','accountancy',163297,NULL,NULL,3,'/compta/salaries/index.php?leftmenu=tax_salary','','Payments',NULL,'companies',2,'','$user->rights->salaries->payment->read','$conf->salaries->enabled && $leftmenu==\"tax_salary\"',0,'2017-08-30 15:14:30'),(163307,'auguria',1,'','left','accountancy',163287,NULL,NULL,1,'/loan/index.php?leftmenu=tax_loan&mainmenu=accountancy','','Loans',NULL,'loan',1,'tax_loan','$user->rights->loan->read','$conf->loan->enabled',0,'2017-08-30 15:14:30'),(163308,'auguria',1,'','left','accountancy',163307,NULL,NULL,2,'/loan/card.php?leftmenu=tax_loan&action=create','','NewLoan',NULL,'loan',2,'','$user->rights->loan->write','$conf->loan->enabled && $leftmenu==\"tax_loan\"',0,'2017-08-30 15:14:30'),(163310,'auguria',1,'','left','accountancy',163307,NULL,NULL,4,'/loan/calc.php?leftmenu=tax_loan','','Calculator',NULL,'companies',2,'','$user->rights->loan->calc','$conf->loan->enabled && $leftmenu==\"tax_loan\" && ! empty($conf->global->LOAN_SHOW_CALCULATOR)',0,'2017-08-30 15:14:30'),(163337,'auguria',1,'','left','accountancy',163287,NULL,NULL,1,'/compta/sociales/index.php?leftmenu=tax_social','','SocialContributions',NULL,'',1,'tax_social','$user->rights->tax->charges->lire','$conf->tax->enabled',0,'2017-08-30 15:14:30'),(163338,'auguria',1,'','left','accountancy',163337,NULL,NULL,2,'/compta/sociales/card.php?leftmenu=tax_social&action=create','','MenuNewSocialContribution',NULL,'',2,'','$user->rights->tax->charges->creer','$conf->tax->enabled && $leftmenu==\"tax_social\"',0,'2017-08-30 15:14:30'),(163339,'auguria',1,'','left','accountancy',163337,NULL,NULL,3,'/compta/sociales/payments.php?leftmenu=tax_social&mainmenu=accountancy&mode=sconly','','Payments',NULL,'',2,'','$user->rights->tax->charges->lire','$conf->tax->enabled && $leftmenu==\"tax_social\"',0,'2017-08-30 15:14:30'),(163387,'auguria',1,'','left','accountancy',163287,NULL,NULL,7,'/compta/tva/index.php?leftmenu=tax_vat&mainmenu=accountancy','','VAT',NULL,'companies',1,'tax_vat','$user->rights->tax->charges->lire','$conf->tax->enabled && empty($conf->global->TAX_DISABLE_VAT_MENUS)',0,'2017-08-30 15:14:30'),(163388,'auguria',1,'','left','accountancy',163387,NULL,NULL,0,'/compta/tva/card.php?leftmenu=tax_vat&action=create','','New',NULL,'companies',2,'','$user->rights->tax->charges->creer','$conf->tax->enabled && empty($conf->global->TAX_DISABLE_VAT_MENUS) && $leftmenu==\"tax_vat\"',0,'2017-08-30 15:14:30'),(163389,'auguria',1,'','left','accountancy',163387,NULL,NULL,1,'/compta/tva/reglement.php?leftmenu=tax_vat','','List',NULL,'companies',2,'','$user->rights->tax->charges->lire','$conf->tax->enabled && empty($conf->global->TAX_DISABLE_VAT_MENUS) && $leftmenu==\"tax_vat\"',0,'2017-08-30 15:14:30'),(163390,'auguria',1,'','left','accountancy',163387,NULL,NULL,2,'/compta/tva/clients.php?leftmenu=tax_vat','','ReportByCustomers',NULL,'companies',2,'','$user->rights->tax->charges->lire','$conf->tax->enabled && empty($conf->global->TAX_DISABLE_VAT_MENUS) && $leftmenu==\"tax_vat\"',0,'2017-08-30 15:14:30'),(163391,'auguria',1,'','left','accountancy',163387,NULL,NULL,3,'/compta/tva/quadri_detail.php?leftmenu=tax_vat','','ReportByQuarter',NULL,'companies',2,'','$user->rights->tax->charges->lire','$conf->tax->enabled && empty($conf->global->TAX_DISABLE_VAT_MENUS) && $leftmenu==\"tax_vat\"',0,'2017-08-30 15:14:30'),(163487,'auguria',1,'','left','accountancy',161093,NULL,NULL,7,'/accountancy/index.php?leftmenu=accountancy','','MenuAccountancy',NULL,'accountancy',0,'accounting','! empty($conf->accounting->enabled) || $user->rights->accounting->bind->write || $user->rights->accounting->bind->write || $user->rights->compta->resultat->lire','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163488,'auguria',1,'','left','accountancy',163487,NULL,NULL,2,'/accountancy/customer/index.php?leftmenu=dispatch_customer','','CustomersVentilation',NULL,'accountancy',1,'dispatch_customer','$user->rights->accounting->bind->write','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163489,'auguria',1,'','left','accountancy',163488,NULL,NULL,3,'/accountancy/customer/list.php','','ToDispatch',NULL,'accountancy',2,'','$user->rights->accounting->bind->write','$conf->accounting->enabled && $leftmenu==\"dispatch_customer\"',0,'2017-08-30 15:14:30'),(163490,'auguria',1,'','left','accountancy',163488,NULL,NULL,4,'/accountancy/customer/lines.php','','Dispatched',NULL,'accountancy',2,'','$user->rights->accounting->bind->write','$conf->accounting->enabled && $leftmenu==\"dispatch_customer\"',0,'2017-08-30 15:14:30'),(163497,'auguria',1,'','left','accountancy',163487,NULL,NULL,5,'/accountancy/supplier/index.php?leftmenu=dispatch_supplier','','SuppliersVentilation',NULL,'accountancy',1,'ventil_supplier','$user->rights->accounting->bind->write','$conf->accounting->enabled && $conf->fournisseur->enabled',0,'2017-08-30 15:14:30'),(163498,'auguria',1,'','left','accountancy',163497,NULL,NULL,6,'/accountancy/supplier/list.php','','ToDispatch',NULL,'accountancy',2,'','$user->rights->accounting->bind->write','$conf->accounting->enabled && $conf->fournisseur->enabled && $leftmenu==\"dispatch_supplier\"',0,'2017-08-30 15:14:30'),(163499,'auguria',1,'','left','accountancy',163497,NULL,NULL,7,'/accountancy/supplier/lines.php','','Dispatched',NULL,'accountancy',2,'','$user->rights->accounting->bind->write','$conf->accounting->enabled && $conf->fournisseur->enabled && $leftmenu==\"dispatch_supplier\"',0,'2017-08-30 15:14:30'),(163507,'auguria',1,'','left','accountancy',163487,NULL,NULL,5,'/accountancy/expensereport/index.php?leftmenu=dispatch_expensereport','','ExpenseReportsVentilation',NULL,'accountancy',1,'ventil_expensereport','$user->rights->accounting->bind->write','$conf->accounting->enabled && $conf->expensereport->enabled',0,'2017-08-30 15:14:30'),(163508,'auguria',1,'','left','accountancy',163507,NULL,NULL,6,'/accountancy/expensereport/list.php','','ToDispatch',NULL,'accountancy',2,'','$user->rights->accounting->bind->write','$conf->accounting->enabled && $conf->expensereport->enabled && $leftmenu==\"dispatch_expensereport\"',0,'2017-08-30 15:14:30'),(163509,'auguria',1,'','left','accountancy',163507,NULL,NULL,7,'/accountancy/expensereport/lines.php','','Dispatched',NULL,'accountancy',2,'','$user->rights->accounting->bind->write','$conf->accounting->enabled && $conf->expensereport->enabled && $leftmenu==\"dispatch_expensereport\"',0,'2017-08-30 15:14:30'),(163517,'auguria',1,'','left','accountancy',163487,NULL,NULL,15,'/accountancy/bookkeeping/list.php','','Bookkeeping',NULL,'accountancy',1,'bookkeeping','$user->rights->accounting->mouvements->lire','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163522,'auguria',1,'','left','accountancy',163487,NULL,NULL,16,'/accountancy/bookkeeping/balance.php','','AccountBalance',NULL,'accountancy',1,'balance','$user->rights->accounting->mouvements->lire','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163527,'auguria',1,'','left','accountancy',163487,NULL,NULL,17,'/accountancy/report/result.php?mainmenu=accountancy&leftmenu=accountancy','','Reportings',NULL,'main',1,'report','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163528,'auguria',1,'','left','accountancy',163527,NULL,NULL,19,'/compta/resultat/index.php?mainmenu=accountancy&leftmenu=accountancy','','ReportInOut',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled && $leftmenu==\"accountancy\"',0,'2017-08-30 15:14:30'),(163529,'auguria',1,'','left','accountancy',163528,NULL,NULL,18,'/accountancy/report/result.php?mainmenu=accountancy&leftmenu=accountancy','','ByAccounts',NULL,'main',3,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled && $leftmenu==\"accountancy\"',0,'2017-08-30 15:14:30'),(163530,'auguria',1,'','left','accountancy',163528,NULL,NULL,20,'/compta/resultat/clientfourn.php?mainmenu=accountancy&leftmenu=accountancy','','ByCompanies',NULL,'main',3,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled && $leftmenu==\"accountancy\"',0,'2017-08-30 15:14:30'),(163531,'auguria',1,'','left','accountancy',163527,NULL,NULL,21,'/compta/stats/index.php?mainmenu=accountancy&leftmenu=accountancy','','ReportTurnover',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled && $leftmenu==\"accountancy\"',0,'2017-08-30 15:14:30'),(163532,'auguria',1,'','left','accountancy',163531,NULL,NULL,22,'/compta/stats/casoc.php?mainmenu=accountancy&leftmenu=accountancy','','ByCompanies',NULL,'main',3,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled && $leftmenu==\"accountancy\"',0,'2017-08-30 15:14:30'),(163533,'auguria',1,'','left','accountancy',163531,NULL,NULL,23,'/compta/stats/cabyuser.php?mainmenu=accountancy&leftmenu=accountancy','','ByUsers',NULL,'main',3,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled && $leftmenu==\"accountancy\"',0,'2017-08-30 15:14:30'),(163534,'auguria',1,'','left','accountancy',163531,NULL,NULL,24,'/compta/stats/cabyprodserv.php?mainmenu=accountancy&leftmenu=accountancy','','ByProductsAndServices',NULL,'main',3,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled && $leftmenu==\"accountancy\"',0,'2017-08-30 15:14:30'),(163537,'auguria',1,'','left','accountancy',163538,NULL,NULL,80,'/accountancy/admin/fiscalyear.php?mainmenu=accountancy&leftmenu=accountancy_admin','','FiscalPeriod',NULL,'admin',1,'accountancy_admin_period','','$conf->accounting->enabled && $leftmenu==\"accountancy_admin\" && $conf->global->MAIN_FEATURES_LEVEL > 0',2,'2017-08-30 15:14:30'),(163538,'auguria',1,'','left','accountancy',163487,NULL,NULL,1,'/accountancy/index.php?mainmenu=accountancy&leftmenu=accountancy_admin','','Setup',NULL,'accountancy',1,'accountancy_admin','$user->rights->accounting->chartofaccount','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163541,'auguria',1,'','left','accountancy',163538,NULL,NULL,10,'/accountancy/admin/journals_list.php?id=35&mainmenu=accountancy&leftmenu=accountancy_admin','','AccountingJournals',NULL,'accountancy',2,'accountancy_admin_journal','$user->rights->accounting->chartofaccount','$conf->accounting->enabled && $leftmenu==\"accountancy_admin\"',0,'2017-08-30 15:14:30'),(163542,'auguria',1,'','left','accountancy',163538,NULL,NULL,20,'/accountancy/admin/account.php?mainmenu=accountancy&leftmenu=accountancy_admin','','Pcg_version',NULL,'accountancy',2,'accountancy_admin_chartmodel','$user->rights->accounting->chartofaccount','$conf->accounting->enabled && $leftmenu==\"accountancy_admin\"',0,'2017-08-30 15:14:30'),(163543,'auguria',1,'','left','accountancy',163538,NULL,NULL,30,'/accountancy/admin/account.php?mainmenu=accountancy&leftmenu=accountancy_admin','','Chartofaccounts',NULL,'accountancy',2,'accountancy_admin_chart','$user->rights->accounting->chartofaccount','$conf->accounting->enabled && $leftmenu==\"accountancy_admin\"',0,'2017-08-30 15:14:30'),(163544,'auguria',1,'','left','accountancy',163538,NULL,NULL,40,'/accountancy/admin/categories_list.php?id=32&mainmenu=accountancy&leftmenu=accountancy_admin','','AccountingCategory',NULL,'accountancy',2,'accountancy_admin_chart_group','$user->rights->accounting->chartofaccount','$conf->accounting->enabled && $leftmenu==\"accountancy_admin\"',0,'2017-08-30 15:14:30'),(163545,'auguria',1,'','left','accountancy',163538,NULL,NULL,50,'/accountancy/admin/defaultaccounts.php?mainmenu=accountancy&leftmenu=accountancy_admin','','MenuDefaultAccounts',NULL,'accountancy',2,'accountancy_admin_default','$user->rights->accounting->chartofaccount','$conf->accounting->enabled && $leftmenu==\"accountancy_admin\"',0,'2017-08-30 15:14:30'),(163546,'auguria',1,'','left','accountancy',163538,NULL,NULL,60,'/admin/dict.php?id=10&from=accountancy&search_country_id=__MYCOUNTRYID__&mainmenu=accountancy&leftmenu=accountancy_admin','','MenuVatAccounts',NULL,'accountancy',2,'accountancy_admin_vat','$user->rights->accounting->chartofaccount','$conf->accounting->enabled && $leftmenu==\"accountancy_admin\"',0,'2017-08-30 15:14:30'),(163547,'auguria',1,'','left','accountancy',163538,NULL,NULL,70,'/admin/dict.php?id=7&from=accountancy&search_country_id=__MYCOUNTRYID__&mainmenu=accountancy&leftmenu=accountancy_admin','','MenuTaxAccounts',NULL,'accountancy',2,'accountancy_admin_tax','$user->rights->accounting->chartofaccount','$conf->accounting->enabled && $leftmenu==\"accountancy_admin\"',0,'2017-08-30 15:14:30'),(163548,'auguria',1,'','left','accountancy',163538,NULL,NULL,80,'/admin/dict.php?id=17&from=accountancy&mainmenu=accountancy&leftmenu=accountancy_admin','','MenuExpenseReportAccounts',NULL,'accountancy',2,'accountancy_admin_expensereport','$user->rights->accounting->chartofaccount','$conf->accounting->enabled && $conf->expensereport->enabled && $leftmenu==\"accountancy_admin\"',0,'2017-08-30 15:14:30'),(163549,'auguria',1,'','left','accountancy',163538,NULL,NULL,90,'/accountancy/admin/productaccount.php?mainmenu=accountancy&leftmenu=accountancy_admin','','MenuProductsAccounts',NULL,'accountancy',2,'accountancy_admin_product','$user->rights->accounting->chartofaccount','$conf->accounting->enabled && $leftmenu==\"accountancy_admin\"',0,'2017-08-30 15:14:30'),(163587,'auguria',1,'','left','accountancy',161101,NULL,NULL,9,'/compta/prelevement/index.php?leftmenu=withdraw&mainmenu=bank','','StandingOrders',NULL,'withdrawals',0,'withdraw','$user->rights->prelevement->bons->lire','$conf->prelevement->enabled',2,'2017-08-30 15:14:30'),(163589,'auguria',1,'','left','accountancy',163587,NULL,NULL,0,'/compta/prelevement/create.php?leftmenu=withdraw','','NewStandingOrder',NULL,'withdrawals',1,'','$user->rights->prelevement->bons->lire','$conf->prelevement->enabled && $leftmenu==\"withdraw\"',2,'2017-08-30 15:14:30'),(163590,'auguria',1,'','left','accountancy',163587,NULL,NULL,2,'/compta/prelevement/bons.php?leftmenu=withdraw','','WithdrawalsReceipts',NULL,'withdrawals',1,'','$user->rights->prelevement->bons->lire','$conf->prelevement->enabled && $leftmenu==\"withdraw\"',2,'2017-08-30 15:14:30'),(163591,'auguria',1,'','left','accountancy',163587,NULL,NULL,3,'/compta/prelevement/list.php?leftmenu=withdraw','','WithdrawalsLines',NULL,'withdrawals',1,'','$user->rights->prelevement->bons->lire','$conf->prelevement->enabled && $leftmenu==\"withdraw\"',2,'2017-08-30 15:14:30'),(163593,'auguria',1,'','left','accountancy',163587,NULL,NULL,5,'/compta/prelevement/rejets.php?leftmenu=withdraw','','Rejects',NULL,'withdrawals',1,'','$user->rights->prelevement->bons->lire','$conf->prelevement->enabled && $leftmenu==\"withdraw\"',2,'2017-08-30 15:14:30'),(163594,'auguria',1,'','left','accountancy',163587,NULL,NULL,6,'/compta/prelevement/stats.php?leftmenu=withdraw','','Statistics',NULL,'withdrawals',1,'','$user->rights->prelevement->bons->lire','$conf->prelevement->enabled && $leftmenu==\"withdraw\"',2,'2017-08-30 15:14:30'),(163687,'auguria',1,'','left','accountancy',161101,NULL,NULL,1,'/compta/bank/index.php?leftmenu=bank&mainmenu=bank','','MenuBankCash',NULL,'banks',0,'bank','$user->rights->banque->lire','$conf->banque->enabled',0,'2017-08-30 15:14:30'),(163688,'auguria',1,'','left','accountancy',163687,NULL,NULL,0,'/compta/bank/card.php?action=create&leftmenu=bank','','MenuNewFinancialAccount',NULL,'banks',1,'','$user->rights->banque->configurer','$conf->banque->enabled && ($leftmenu==\"bank\" || $leftmenu==\"checks\" || $leftmenu==\"withdraw\")',0,'2017-08-30 15:14:30'),(163690,'auguria',1,'','left','accountancy',163687,NULL,NULL,2,'/compta/bank/bankentries.php?leftmenu=bank','','ListTransactions',NULL,'banks',1,'','$user->rights->banque->lire','$conf->banque->enabled && ($leftmenu==\"bank\" || $leftmenu==\"checks\" || $leftmenu==\"withdraw\")',0,'2017-08-30 15:14:30'),(163691,'auguria',1,'','left','accountancy',163687,NULL,NULL,3,'/compta/bank/budget.php?leftmenu=bank','','ListTransactionsByCategory',NULL,'banks',1,'','$user->rights->banque->lire','$conf->banque->enabled && ($leftmenu==\"bank\" || $leftmenu==\"checks\" || $leftmenu==\"withdraw\")',0,'2017-08-30 15:14:30'),(163693,'auguria',1,'','left','accountancy',163687,NULL,NULL,5,'/compta/bank/transfer.php?leftmenu=bank','','BankTransfers',NULL,'banks',1,'','$user->rights->banque->transfer','$conf->banque->enabled && ($leftmenu==\"bank\" || $leftmenu==\"checks\" || $leftmenu==\"withdraw\")',0,'2017-08-30 15:14:30'),(163737,'auguria',1,'','left','accountancy',161101,NULL,NULL,4,'/categories/index.php?leftmenu=bank&type=5','','Categories',NULL,'categories',0,'cat','$user->rights->categorie->lire','$conf->categorie->enabled',2,'2017-08-30 15:14:30'),(163738,'auguria',1,'','left','accountancy',163737,NULL,NULL,0,'/categories/card.php?leftmenu=bank&action=create&type=5','','NewCategory',NULL,'categories',1,'','$user->rights->categorie->creer','$conf->categorie->enabled',2,'2017-08-30 15:14:30'),(163787,'auguria',1,'','left','accountancy',161093,NULL,NULL,11,'/compta/resultat/index.php?leftmenu=ca&mainmenu=accountancy','','Reportings',NULL,'main',0,'ca','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->comptabilite->enabled',0,'2017-08-30 15:14:30'),(163792,'auguria',1,'','left','accountancy',163487,NULL,NULL,1,'','','Journalization',NULL,'main',1,'','$user->rights->accounting->comptarapport->lire','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163793,'auguria',1,'','left','accountancy',163792,NULL,NULL,4,'/accountancy/journal/sellsjournal.php?mainmenu=accountancy&leftmenu=accountancy_journal&id_journal=1','','SellsJournal',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163794,'auguria',1,'','left','accountancy',163792,NULL,NULL,1,'/accountancy/journal/bankjournal.php?mainmenu=accountancy&leftmenu=accountancy_journal&id_journal=3','','BankJournal',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163795,'auguria',1,'','left','accountancy',163792,NULL,NULL,2,'/accountancy/journal/expensereportsjournal.php?mainmenu=accountancy&leftmenu=accountancy_journal&id_journal=6','','ExpenseReportJournal',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163796,'auguria',1,'','left','accountancy',163792,NULL,NULL,3,'/accountancy/journal/purchasesjournal.php?mainmenu=accountancy&leftmenu=accountancy_journal&id_journal=2','','PurchasesJournal',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163798,'auguria',1,'','left','accountancy',163787,NULL,NULL,0,'/compta/resultat/index.php?leftmenu=ca','','ReportInOut',NULL,'main',1,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->comptabilite->enabled && $leftmenu==\"ca\"',0,'2017-08-30 15:14:30'),(163799,'auguria',1,'','left','accountancy',163788,NULL,NULL,0,'/compta/resultat/clientfourn.php?leftmenu=ca','','ByCompanies',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->comptabilite->enabled && $leftmenu==\"ca\"',0,'2017-08-30 15:14:30'),(163800,'auguria',1,'','left','accountancy',163787,NULL,NULL,1,'/compta/stats/index.php?leftmenu=ca','','ReportTurnover',NULL,'main',1,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->comptabilite->enabled && $leftmenu==\"ca\"',0,'2017-08-30 15:14:30'),(163801,'auguria',1,'','left','accountancy',163790,NULL,NULL,0,'/compta/stats/casoc.php?leftmenu=ca','','ByCompanies',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->comptabilite->enabled && $leftmenu==\"ca\"',0,'2017-08-30 15:14:30'),(163802,'auguria',1,'','left','accountancy',163790,NULL,NULL,1,'/compta/stats/cabyuser.php?leftmenu=ca','','ByUsers',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->comptabilite->enabled && $leftmenu==\"ca\"',0,'2017-08-30 15:14:30'),(163803,'auguria',1,'','left','accountancy',163790,NULL,NULL,1,'/compta/stats/cabyprodserv.php?leftmenu=ca','','ByProductsAndServices',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->comptabilite->enabled && $leftmenu==\"ca\"',0,'2017-08-30 15:14:30'),(163887,'auguria',1,'','left','products',161090,NULL,NULL,0,'/product/index.php?leftmenu=product&type=0','','Products',NULL,'products',0,'product','$user->rights->produit->lire','$conf->product->enabled',2,'2017-08-30 15:14:30'),(163888,'auguria',1,'','left','products',163887,NULL,NULL,0,'/product/card.php?leftmenu=product&action=create&type=0','','NewProduct',NULL,'products',1,'','$user->rights->produit->creer','$conf->product->enabled',2,'2017-08-30 15:14:30'),(163889,'auguria',1,'','left','products',163887,NULL,NULL,1,'/product/list.php?leftmenu=product&type=0','','List',NULL,'products',1,'','$user->rights->produit->lire','$conf->product->enabled',2,'2017-08-30 15:14:30'),(163890,'auguria',1,'','left','products',163887,NULL,NULL,4,'/product/reassort.php?type=0','','Stocks',NULL,'products',1,'','$user->rights->produit->lire && $user->rights->stock->lire','$conf->product->enabled',2,'2017-08-30 15:14:30'),(163891,'auguria',1,'','left','products',163887,NULL,NULL,7,'/product/stats/card.php?id=all&leftmenu=stats&type=0','','Statistics',NULL,'main',1,'','$user->rights->produit->lire','$conf->propal->enabled',2,'2017-08-30 15:14:30'),(163892,'auguria',1,'','left','products',163887,NULL,NULL,5,'/product/reassortlot.php?type=0','','StocksByLotSerial',NULL,'products',1,'','$user->rights->produit->lire && $user->rights->stock->lire','$conf->productbatch->enabled',2,'2017-08-30 15:14:30'),(163893,'auguria',1,'','left','products',163887,NULL,NULL,6,'/product/stock/productlot_list.php','','LotSerial',NULL,'products',1,'','$user->rights->produit->lire && $user->rights->stock->lire','$conf->productbatch->enabled',2,'2017-08-30 15:14:30'),(163987,'auguria',1,'','left','products',161090,NULL,NULL,1,'/product/index.php?leftmenu=service&type=1','','Services',NULL,'products',0,'service','$user->rights->service->lire','$conf->service->enabled',2,'2017-08-30 15:14:30'),(163988,'auguria',1,'','left','products',163987,NULL,NULL,0,'/product/card.php?leftmenu=service&action=create&type=1','','NewService',NULL,'products',1,'','$user->rights->service->creer','$conf->service->enabled',2,'2017-08-30 15:14:30'),(163989,'auguria',1,'','left','products',163987,NULL,NULL,1,'/product/list.php?leftmenu=service&type=1','','List',NULL,'products',1,'','$user->rights->service->lire','$conf->service->enabled',2,'2017-08-30 15:14:30'),(163990,'auguria',1,'','left','products',163987,NULL,NULL,5,'/product/stats/card.php?id=all&leftmenu=stats&type=1','','Statistics',NULL,'main',1,'','$user->rights->service->lire','$conf->propal->enabled',2,'2017-08-30 15:14:30'),(164187,'auguria',1,'','left','products',161090,NULL,NULL,3,'/product/stock/index.php?leftmenu=stock','','Stock',NULL,'stocks',0,'stock','$user->rights->stock->lire','$conf->stock->enabled',2,'2017-08-30 15:14:30'),(164188,'auguria',1,'','left','products',164187,NULL,NULL,0,'/product/stock/card.php?action=create','','MenuNewWarehouse',NULL,'stocks',1,'','$user->rights->stock->creer','$conf->stock->enabled',2,'2017-08-30 15:14:30'),(164189,'auguria',1,'','left','products',164187,NULL,NULL,1,'/product/stock/list.php','','List',NULL,'stocks',1,'','$user->rights->stock->lire','$conf->stock->enabled',2,'2017-08-30 15:14:30'),(164191,'auguria',1,'','left','products',164187,NULL,NULL,3,'/product/stock/mouvement.php','','Movements',NULL,'stocks',1,'','$user->rights->stock->mouvement->lire','$conf->stock->enabled',2,'2017-08-30 15:14:30'),(164192,'auguria',1,'','left','products',164187,NULL,NULL,4,'/product/stock/replenish.php','','Replenishments',NULL,'stocks',1,'','$user->rights->stock->mouvement->creer && $user->rights->fournisseur->lire','$conf->stock->enabled && $conf->supplier_order->enabled',2,'2017-08-30 15:14:30'),(164193,'auguria',1,'','left','products',164187,NULL,NULL,5,'/product/stock/massstockmove.php','','MassStockTransferShort',NULL,'stocks',1,'','$user->rights->stock->mouvement->creer','$conf->stock->enabled',2,'2017-08-30 15:14:30'),(164287,'auguria',1,'','left','products',161090,NULL,NULL,4,'/categories/index.php?leftmenu=cat&type=0','','Categories',NULL,'categories',0,'cat','$user->rights->categorie->lire','$conf->categorie->enabled',2,'2017-08-30 15:14:30'),(164288,'auguria',1,'','left','products',164287,NULL,NULL,0,'/categories/card.php?action=create&type=0','','NewCategory',NULL,'categories',1,'','$user->rights->categorie->creer','$conf->categorie->enabled',2,'2017-08-30 15:14:30'),(164487,'auguria',1,'','left','project',161094,NULL,NULL,3,'/projet/activity/perweek.php?leftmenu=projects','','NewTimeSpent',NULL,'projects',0,'','$user->rights->projet->lire','$conf->projet->enabled && $conf->global->PROJECT_USE_TASKS',2,'2017-08-30 15:14:30'),(164687,'auguria',1,'','left','project',161094,NULL,NULL,0,'/projet/index.php?leftmenu=projects','','Projects',NULL,'projects',0,'projects','$user->rights->projet->lire','$conf->projet->enabled',2,'2017-08-30 15:14:30'),(164688,'auguria',1,'','left','project',164687,NULL,NULL,1,'/projet/card.php?leftmenu=projects&action=create','','NewProject',NULL,'projects',1,'','$user->rights->projet->creer','$conf->projet->enabled',2,'2017-08-30 15:14:30'),(164689,'auguria',1,'','left','project',164687,NULL,NULL,2,'/projet/list.php?leftmenu=projects','','List',NULL,'projects',1,'','$user->rights->projet->lire','$conf->projet->enabled',2,'2017-08-30 15:14:30'),(164690,'auguria',1,'','left','project',164687,NULL,NULL,3,'/projet/stats/index.php?leftmenu=projects','','Statistics',NULL,'projects',1,'','$user->rights->projet->lire','$conf->projet->enabled',2,'2017-08-30 15:14:30'),(164787,'auguria',1,'','left','project',161094,NULL,NULL,0,'/projet/activity/index.php?leftmenu=projects','','Activities',NULL,'projects',0,'','$user->rights->projet->lire','$conf->projet->enabled && $conf->global->PROJECT_USE_TASKS',2,'2017-08-30 15:14:30'),(164788,'auguria',1,'','left','project',164787,NULL,NULL,1,'/projet/tasks.php?leftmenu=projects&action=create','','NewTask',NULL,'projects',1,'','$user->rights->projet->creer','$conf->projet->enabled && $conf->global->PROJECT_USE_TASKS',2,'2017-08-30 15:14:30'),(164789,'auguria',1,'','left','project',164787,NULL,NULL,2,'/projet/tasks/list.php?leftmenu=projects','','List',NULL,'projects',1,'','$user->rights->projet->lire','$conf->projet->enabled && $conf->global->PROJECT_USE_TASKS',2,'2017-08-30 15:14:30'),(164791,'auguria',1,'','left','project',164787,NULL,NULL,4,'/projet/tasks/stats/index.php?leftmenu=projects','','Statistics',NULL,'projects',1,'','$user->rights->projet->lire','$conf->projet->enabled && $conf->global->PROJECT_USE_TASKS',2,'2017-08-30 15:14:30'),(164891,'auguria',1,'','left','project',161094,NULL,NULL,4,'/categories/index.php?leftmenu=cat&type=6','','Categories',NULL,'categories',0,'cat','$user->rights->categorie->lire','$conf->categorie->enabled',2,'2017-08-30 15:14:30'),(164892,'auguria',1,'','left','project',164891,NULL,NULL,0,'/categories/card.php?action=create&type=6','','NewCategory',NULL,'categories',1,'','$user->rights->categorie->creer','$conf->categorie->enabled',2,'2017-08-30 15:14:30'),(164987,'auguria',1,'','left','tools',161095,NULL,NULL,0,'/comm/mailing/index.php?leftmenu=mailing','','EMailings',NULL,'mails',0,'mailing','$user->rights->mailing->lire','$conf->mailing->enabled',0,'2017-08-30 15:14:30'),(164988,'auguria',1,'','left','tools',164987,NULL,NULL,0,'/comm/mailing/card.php?leftmenu=mailing&action=create','','NewMailing',NULL,'mails',1,'','$user->rights->mailing->creer','$conf->mailing->enabled',0,'2017-08-30 15:14:30'),(164989,'auguria',1,'','left','tools',164987,NULL,NULL,1,'/comm/mailing/list.php?leftmenu=mailing','','List',NULL,'mails',1,'','$user->rights->mailing->lire','$conf->mailing->enabled',0,'2017-08-30 15:14:30'),(165187,'auguria',1,'','left','tools',161095,NULL,NULL,2,'/exports/index.php?leftmenu=export','','FormatedExport',NULL,'exports',0,'export','$user->rights->export->lire','$conf->export->enabled',2,'2017-08-30 15:14:30'),(165188,'auguria',1,'','left','tools',165187,NULL,NULL,0,'/exports/export.php?leftmenu=export','','NewExport',NULL,'exports',1,'','$user->rights->export->creer','$conf->export->enabled',2,'2017-08-30 15:14:30'),(165217,'auguria',1,'','left','tools',161095,NULL,NULL,2,'/imports/index.php?leftmenu=import','','FormatedImport',NULL,'exports',0,'import','$user->rights->import->run','$conf->import->enabled',2,'2017-08-30 15:14:30'),(165218,'auguria',1,'','left','tools',165217,NULL,NULL,0,'/imports/import.php?leftmenu=import','','NewImport',NULL,'exports',1,'','$user->rights->import->run','$conf->import->enabled',2,'2017-08-30 15:14:30'),(165287,'auguria',1,'','left','members',161100,NULL,NULL,0,'/adherents/index.php?leftmenu=members&mainmenu=members','','Members',NULL,'members',0,'members','$user->rights->adherent->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165288,'auguria',1,'','left','members',165287,NULL,NULL,0,'/adherents/card.php?leftmenu=members&action=create','','NewMember',NULL,'members',1,'','$user->rights->adherent->creer','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165289,'auguria',1,'','left','members',165287,NULL,NULL,1,'/adherents/list.php','','List',NULL,'members',1,'','$user->rights->adherent->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165290,'auguria',1,'','left','members',165289,NULL,NULL,2,'/adherents/list.php?leftmenu=members&statut=-1','','MenuMembersToValidate',NULL,'members',2,'','$user->rights->adherent->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165291,'auguria',1,'','left','members',165289,NULL,NULL,3,'/adherents/list.php?leftmenu=members&statut=1','','MenuMembersValidated',NULL,'members',2,'','$user->rights->adherent->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165292,'auguria',1,'','left','members',165289,NULL,NULL,4,'/adherents/list.php?leftmenu=members&statut=1&filter=outofdate','','MenuMembersNotUpToDate',NULL,'members',2,'','$user->rights->adherent->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165293,'auguria',1,'','left','members',165289,NULL,NULL,5,'/adherents/list.php?leftmenu=members&statut=1&filter=uptodate','','MenuMembersUpToDate',NULL,'members',2,'','$user->rights->adherent->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165294,'auguria',1,'','left','members',165289,NULL,NULL,6,'/adherents/list.php?leftmenu=members&statut=0','','MenuMembersResiliated',NULL,'members',2,'','$user->rights->adherent->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165295,'auguria',1,'','left','members',165287,NULL,NULL,7,'/adherents/stats/geo.php?leftmenu=members&mode=memberbycountry','','MenuMembersStats',NULL,'members',1,'','$user->rights->adherent->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165387,'auguria',1,'','left','members',161100,NULL,NULL,1,'/adherents/index.php?leftmenu=members&mainmenu=members','','Subscriptions',NULL,'compta',0,'','$user->rights->adherent->cotisation->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165388,'auguria',1,'','left','members',165387,NULL,NULL,0,'/adherents/list.php?statut=-1&leftmenu=accountancy&mainmenu=members','','NewSubscription',NULL,'compta',1,'','$user->rights->adherent->cotisation->creer','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165389,'auguria',1,'','left','members',165387,NULL,NULL,1,'/adherents/subscription/list.php?leftmenu=members','','List',NULL,'compta',1,'','$user->rights->adherent->cotisation->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165390,'auguria',1,'','left','members',165387,NULL,NULL,7,'/adherents/stats/index.php?leftmenu=members','','MenuMembersStats',NULL,'members',1,'','$user->rights->adherent->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165589,'auguria',1,'','left','members',165287,NULL,NULL,9,'/adherents/htpasswd.php?leftmenu=export','','Filehtpasswd',NULL,'members',1,'','$user->rights->adherent->export','! empty($conf->global->MEMBER_LINK_TO_HTPASSWDFILE) && $conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165590,'auguria',1,'','left','members',165287,NULL,NULL,10,'/adherents/cartes/carte.php?leftmenu=export','','MembersCards',NULL,'members',1,'','$user->rights->adherent->export','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165687,'auguria',1,'','left','hrm',161102,NULL,NULL,1,'/user/index.php?leftmenu=hrm&mode=employee','','Employees',NULL,'hrm',0,'hrm','$user->rights->hrm->employee->read','$conf->hrm->enabled',0,'2017-08-30 15:14:30'),(165688,'auguria',1,'','left','hrm',165687,NULL,NULL,1,'/user/card.php?action=create&employee=1','','NewEmployee',NULL,'hrm',1,'','$user->rights->hrm->employee->write','$conf->hrm->enabled',0,'2017-08-30 15:14:30'),(165689,'auguria',1,'','left','hrm',165687,NULL,NULL,2,'/user/index.php?$leftmenu=hrm&mode=employee&contextpage=employeelist','','List',NULL,'hrm',1,'','$user->rights->hrm->employee->read','$conf->hrm->enabled',0,'2017-08-30 15:14:30'),(165787,'auguria',1,'','left','members',161100,NULL,NULL,5,'/adherents/type.php?leftmenu=setup&mainmenu=members','','MembersTypes',NULL,'members',0,'setup','$user->rights->adherent->configurer','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165788,'auguria',1,'','left','members',165787,NULL,NULL,0,'/adherents/type.php?leftmenu=setup&mainmenu=members&action=create','','New',NULL,'members',1,'','$user->rights->adherent->configurer','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165789,'auguria',1,'','left','members',165787,NULL,NULL,1,'/adherents/type.php?leftmenu=setup&mainmenu=members','','List',NULL,'members',1,'','$user->rights->adherent->configurer','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(166087,'auguria',1,'','left','hrm',161102,NULL,NULL,1,'/holiday/list.php?&leftmenu=hrm','','CPTitreMenu',NULL,'holiday',0,'hrm','$user->rights->holiday->read','$conf->holiday->enabled',0,'2017-08-30 15:14:30'),(166088,'auguria',1,'','left','hrm',166087,NULL,NULL,1,'/holiday/card.php?&action=request','','MenuAddCP',NULL,'holiday',1,'','$user->rights->holiday->write','$conf->holiday->enabled',0,'2017-08-30 15:14:30'),(166089,'auguria',1,'','left','hrm',166087,NULL,NULL,1,'/holiday/list.php?&leftmenu=hrm','','List',NULL,'holiday',1,'','$user->rights->holiday->read','$conf->holiday->enabled',0,'2017-08-30 15:14:30'),(166090,'auguria',1,'','left','hrm',166089,NULL,NULL,1,'/holiday/list.php?select_statut=2&leftmenu=hrm','','ListToApprove',NULL,'trips',2,'','$user->rights->holiday->read','$conf->holiday->enabled',0,'2017-08-30 15:14:30'),(166091,'auguria',1,'','left','hrm',166087,NULL,NULL,2,'/holiday/define_holiday.php?&action=request','','MenuConfCP',NULL,'holiday',1,'','$user->rights->holiday->define_holiday','$conf->holiday->enabled',0,'2017-08-30 15:14:30'),(166092,'auguria',1,'','left','hrm',166087,NULL,NULL,3,'/holiday/view_log.php?&action=request','','MenuLogCP',NULL,'holiday',1,'','$user->rights->holiday->define_holiday','$conf->holiday->enabled',0,'2017-08-30 15:14:30'),(166187,'auguria',1,'','left','commercial',161092,NULL,NULL,6,'/fourn/commande/index.php?leftmenu=orders_suppliers','','SuppliersOrders',NULL,'orders',0,'orders_suppliers','$user->rights->fournisseur->commande->lire','$conf->supplier_order->enabled',2,'2017-08-30 15:14:30'),(166188,'auguria',1,'','left','commercial',166187,NULL,NULL,0,'/fourn/commande/card.php?action=create&leftmenu=orders_suppliers','','NewOrder',NULL,'orders',1,'','$user->rights->fournisseur->commande->creer','$conf->supplier_order->enabled',2,'2017-08-30 15:14:30'),(166189,'auguria',1,'','left','commercial',166187,NULL,NULL,1,'/fourn/commande/list.php?leftmenu=orders_suppliers&search_status=0','','List',NULL,'orders',1,'','$user->rights->fournisseur->commande->lire','$conf->supplier_order->enabled',2,'2017-08-30 15:14:30'),(166195,'auguria',1,'','left','commercial',166187,NULL,NULL,7,'/commande/stats/index.php?leftmenu=orders_suppliers&mode=supplier','','Statistics',NULL,'orders',1,'','$user->rights->fournisseur->commande->lire','$conf->supplier_order->enabled',2,'2017-08-30 15:14:30'),(166287,'auguria',1,'','left','members',161100,NULL,NULL,3,'/categories/index.php?leftmenu=cat&type=3','','MembersCategoriesShort',NULL,'categories',0,'cat','$user->rights->categorie->lire','$conf->adherent->enabled && $conf->categorie->enabled',2,'2017-08-30 15:14:30'),(166288,'auguria',1,'','left','members',166287,NULL,NULL,0,'/categories/card.php?action=create&type=3','','NewCategory',NULL,'categories',1,'','$user->rights->categorie->creer','$conf->adherent->enabled && $conf->categorie->enabled',2,'2017-08-30 15:14:30'),(166387,'auguria',1,'','left','hrm',161102,NULL,NULL,5,'/expensereport/index.php?leftmenu=expensereport','','TripsAndExpenses',NULL,'trips',0,'expensereport','$user->rights->expensereport->lire','$conf->expensereport->enabled',0,'2017-08-30 15:14:30'),(166388,'auguria',1,'','left','hrm',166387,NULL,NULL,1,'/expensereport/card.php?action=create&leftmenu=expensereport','','New',NULL,'trips',1,'','$user->rights->expensereport->creer','$conf->expensereport->enabled',0,'2017-08-30 15:14:30'),(166389,'auguria',1,'','left','hrm',166387,NULL,NULL,2,'/expensereport/list.php?leftmenu=expensereport','','List',NULL,'trips',1,'','$user->rights->expensereport->lire','$conf->expensereport->enabled',0,'2017-08-30 15:14:30'),(166390,'auguria',1,'','left','hrm',166389,NULL,NULL,2,'/expensereport/list.php?search_status=2&leftmenu=expensereport','','ListToApprove',NULL,'trips',2,'','$user->rights->expensereport->approve','$conf->expensereport->enabled',0,'2017-08-30 15:14:30'),(166391,'auguria',1,'','left','hrm',166387,NULL,NULL,2,'/expensereport/stats/index.php?leftmenu=expensereport','','Statistics',NULL,'trips',1,'','$user->rights->expensereport->lire','$conf->expensereport->enabled',0,'2017-08-30 15:14:30'),(167087,'all',1,'agenda','top','agenda',0,NULL,NULL,86,'/comm/action/index.php','','TMenuAgenda','','agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2021-07-11 17:49:45'),(167088,'all',1,'agenda','left','agenda',167087,NULL,NULL,100,'/comm/action/index.php?mainmenu=agenda&leftmenu=agenda','','Actions','','agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2021-07-11 17:49:45'),(167089,'all',1,'agenda','left','agenda',167088,NULL,NULL,101,'/comm/action/card.php?mainmenu=agenda&leftmenu=agenda&action=create','','NewAction','','commercial',NULL,NULL,'($user->rights->agenda->myactions->create||$user->rights->agenda->allactions->create)','$conf->agenda->enabled',2,'2021-07-11 17:49:45'),(167090,'all',1,'agenda','left','agenda',167088,NULL,NULL,140,'/comm/action/index.php?action=default&mainmenu=agenda&leftmenu=agenda','','Calendar','','agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2021-07-11 17:49:45'),(167091,'all',1,'agenda','left','agenda',167090,NULL,NULL,141,'/comm/action/index.php?action=default&mainmenu=agenda&leftmenu=agenda&status=todo&filter=mine','','MenuToDoMyActions','','agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2021-07-11 17:49:45'),(167092,'all',1,'agenda','left','agenda',167090,NULL,NULL,142,'/comm/action/index.php?action=default&mainmenu=agenda&leftmenu=agenda&status=done&filter=mine','','MenuDoneMyActions','','agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2021-07-11 17:49:45'),(167093,'all',1,'agenda','left','agenda',167090,NULL,NULL,143,'/comm/action/index.php?action=default&mainmenu=agenda&leftmenu=agenda&status=todo&filtert=-1','','MenuToDoActions','','agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$user->rights->agenda->allactions->read',2,'2021-07-11 17:49:45'),(167094,'all',1,'agenda','left','agenda',167090,NULL,NULL,144,'/comm/action/index.php?action=default&mainmenu=agenda&leftmenu=agenda&status=done&filtert=-1','','MenuDoneActions','','agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$user->rights->agenda->allactions->read',2,'2021-07-11 17:49:45'),(167095,'all',1,'agenda','left','agenda',167088,NULL,NULL,110,'/comm/action/list.php?action=show_list&mainmenu=agenda&leftmenu=agenda','','List','','agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2021-07-11 17:49:45'),(167096,'all',1,'agenda','left','agenda',167095,NULL,NULL,111,'/comm/action/list.php?action=show_list&mainmenu=agenda&leftmenu=agenda&status=todo&filter=mine','','MenuToDoMyActions','','agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2021-07-11 17:49:45'),(167097,'all',1,'agenda','left','agenda',167095,NULL,NULL,112,'/comm/action/list.php?action=show_list&mainmenu=agenda&leftmenu=agenda&status=done&filter=mine','','MenuDoneMyActions','','agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2021-07-11 17:49:45'),(167098,'all',1,'agenda','left','agenda',167095,NULL,NULL,113,'/comm/action/list.php?action=show_list&mainmenu=agenda&leftmenu=agenda&status=todo&filtert=-1','','MenuToDoActions','','agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$user->rights->agenda->allactions->read',2,'2021-07-11 17:49:45'),(167099,'all',1,'agenda','left','agenda',167095,NULL,NULL,114,'/comm/action/list.php?action=show_list&mainmenu=agenda&leftmenu=agenda&status=done&filtert=-1','','MenuDoneActions','','agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$user->rights->agenda->allactions->read',2,'2021-07-11 17:49:45'),(167100,'all',1,'agenda','left','agenda',167088,NULL,NULL,160,'/comm/action/rapport/index.php?mainmenu=agenda&leftmenu=agenda','','Reportings','','agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$conf->agenda->enabled',2,'2021-07-11 17:49:45'),(167101,'all',1,'agenda','left','agenda',167088,NULL,NULL,170,'/categories/index.php?mainmenu=agenda&leftmenu=agenda&type=10','','Categories','','agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$conf->categorie->enabled',2,'2021-07-11 17:49:45'),(167102,'all',1,'barcode','left','tools',-1,NULL,'tools',200,'/barcode/printsheet.php?mainmenu=tools&leftmenu=barcodeprint','','BarCodePrintsheet','','products',NULL,'barcodeprint','($conf->global->MAIN_USE_ADVANCED_PERMS && $user->rights->barcode->lire_advance) || (! $conf->global->MAIN_USE_ADVANCED_PERMS)','$conf->barcode->enabled',2,'2021-07-11 17:49:46'),(167103,'all',1,'barcode','left','home',-1,'admintools','home',300,'/barcode/codeinit.php?mainmenu=home&leftmenu=admintools','','MassBarcodeInit','','products',NULL,NULL,'($conf->global->MAIN_USE_ADVANCED_PERMS && $user->rights->barcode->creer_advance) || (! $conf->global->MAIN_USE_ADVANCED_PERMS)','$conf->barcode->enabled && preg_match(\'/^(admintools|all)/\',$leftmenu)',0,'2021-07-11 17:49:46'),(167104,'all',1,'cron','left','home',-1,'admintools','home',200,'/cron/list.php?leftmenu=admintools','','CronList','','cron',NULL,NULL,'$user->rights->cron->read','$conf->cron->enabled && preg_match(\'/^(admintools|all)/\', $leftmenu)',2,'2021-07-11 17:49:46'),(167105,'all',1,'blockedlog','left','tools',-1,NULL,'tools',200,'/blockedlog/admin/blockedlog_list.php?mainmenu=tools&leftmenu=blockedlogbrowser','','BrowseBlockedLog','','blockedlog',NULL,'blockedlogbrowser','$user->rights->blockedlog->read','$conf->blockedlog->enabled',2,'2021-07-11 17:49:46'),(167106,'all',1,'ecm','top','ecm',0,NULL,NULL,82,'/ecm/index.php','','MenuECM','','ecm',NULL,NULL,'$user->rights->ecm->read || $user->rights->ecm->upload || $user->rights->ecm->setup','$conf->ecm->enabled',2,'2021-07-11 17:49:46'),(167107,'all',1,'ecm','left','ecm',-1,NULL,'ecm',101,'/ecm/index.php?mainmenu=ecm&leftmenu=ecm','','ECMArea','','ecm',NULL,'ecm','$user->rights->ecm->read || $user->rights->ecm->upload','$user->rights->ecm->read || $user->rights->ecm->upload',2,'2021-07-11 17:49:46'),(167108,'all',1,'ecm','left','ecm',-1,'ecm','ecm',102,'/ecm/index.php?action=file_manager&mainmenu=ecm&leftmenu=ecm','','ECMSectionsManual','','ecm',NULL,'ecm_manual','$user->rights->ecm->read || $user->rights->ecm->upload','$user->rights->ecm->read || $user->rights->ecm->upload',2,'2021-07-11 17:49:46'),(167109,'all',1,'ecm','left','ecm',-1,'ecm','ecm',103,'/ecm/index_auto.php?action=file_manager&mainmenu=ecm&leftmenu=ecm','','ECMSectionsAuto','','ecm',NULL,NULL,'$user->rights->ecm->read || $user->rights->ecm->upload','($user->rights->ecm->read || $user->rights->ecm->upload) && ! empty($conf->global->ECM_AUTO_TREE_ENABLED)',2,'2021-07-11 17:49:46'),(167110,'all',1,'margins','left','billing',-1,NULL,'billing',100,'/margin/index.php','','Margins','','margins',NULL,'margins','$user->rights->margins->liretous','$conf->margin->enabled',2,'2021-07-11 17:49:47'),(167111,'all',1,'opensurvey','left','tools',-1,NULL,'tools',200,'/opensurvey/index.php?mainmenu=tools&leftmenu=opensurvey','','Survey','','opensurvey',NULL,'opensurvey','$user->rights->opensurvey->read','$conf->opensurvey->enabled',0,'2021-07-11 17:49:47'),(167112,'all',1,'opensurvey','left','tools',-1,'opensurvey','tools',210,'/opensurvey/wizard/index.php','','NewSurvey','','opensurvey',NULL,'opensurvey_new','$user->rights->opensurvey->write','$conf->opensurvey->enabled',0,'2021-07-11 17:49:47'),(167113,'all',1,'opensurvey','left','tools',-1,'opensurvey','tools',220,'/opensurvey/list.php','','List','','opensurvey',NULL,'opensurvey_list','$user->rights->opensurvey->read','$conf->opensurvey->enabled',0,'2021-07-11 17:49:47'),(167114,'all',1,'printing','left','home',-1,'admintools','home',300,'/printing/index.php?mainmenu=home&leftmenu=admintools','','MenuDirectPrinting','','printing',NULL,NULL,'$user->rights->printing->read','$conf->printing->enabled && preg_match(\'/^(admintools|all)/\', $leftmenu)',0,'2021-07-11 17:49:47'),(167115,'all',1,'recruitment','left','hrm',-1,NULL,'hrm',1001,'/recruitment/recruitmentindex.php','','Recruitment','','recruitment',NULL,'recruitmentjobposition','$user->rights->recruitment->recruitmentjobposition->read','$conf->recruitment->enabled',2,'2021-07-11 17:49:47'),(167116,'all',1,'recruitment','left','hrm',-1,'recruitmentjobposition','hrm',1002,'/recruitment/recruitmentjobposition_card.php?action=create','','NewPositionToBeFilled','','recruitment',NULL,'recruitment_recruitmentjobposition_new','$user->rights->recruitment->recruitmentjobposition->write','$conf->recruitment->enabled',2,'2021-07-11 17:49:47'),(167117,'all',1,'recruitment','left','hrm',-1,'recruitmentjobposition','hrm',1003,'/recruitment/recruitmentjobposition_list.php','','ListOfPositionsToBeFilled','','recruitment',NULL,'recruitment_recruitmentjobposition_list','$user->rights->recruitment->recruitmentjobposition->read','$conf->recruitment->enabled',2,'2021-07-11 17:49:47'),(167118,'all',1,'recruitment','left','hrm',-1,'recruitmentjobposition','hrm',1004,'/recruitment/recruitmentcandidature_card.php?action=create','','NewCandidature','','recruitment',NULL,'recruitment_recruitmentcandidature_new','$user->rights->recruitment->recruitmentjobposition->write','$conf->recruitment->enabled',2,'2021-07-11 17:49:47'),(167119,'all',1,'recruitment','left','hrm',-1,'recruitmentjobposition','hrm',1005,'/recruitment/recruitmentcandidature_list.php','','ListOfCandidatures','','recruitment',NULL,'recruitment_recruitmentcandidature_list','$user->rights->recruitment->recruitmentjobposition->read','$conf->recruitment->enabled',2,'2021-07-11 17:49:47'),(167120,'all',1,'resource','left','tools',-1,NULL,'tools',100,'/resource/list.php','','MenuResourceIndex','','resource',NULL,'resource','$user->rights->resource->read','1',0,'2021-07-11 17:49:47'),(167121,'all',1,'resource','left','tools',-1,'resource','tools',101,'/resource/card.php?action=create','','MenuResourceAdd','','resource',NULL,'resource_add','$user->rights->resource->write','1',0,'2021-07-11 17:49:47'),(167122,'all',1,'resource','left','tools',-1,'resource','tools',102,'/resource/list.php','','List','','resource',NULL,'resource_list','$user->rights->resource->read','1',0,'2021-07-11 17:49:47'),(167123,'all',1,'stripe','left','bank',-1,NULL,'bank',100,'','','StripeAccount','','stripe',NULL,'stripe','$user->rights->banque->lire','$conf->stripe->enabled && $conf->banque->enabled && $conf->global->MAIN_FEATURES_LEVEL >= 1',0,'2021-07-11 17:49:47'),(167124,'all',1,'stripe','left','bank',-1,'stripe','bank',102,'/stripe/charge.php','','StripeChargeList','','stripe',NULL,NULL,'$user->rights->banque->lire','$conf->stripe->enabled && $conf->banque->enabled && $conf->global->MAIN_FEATURES_LEVEL >= 1',0,'2021-07-11 17:49:47'),(167125,'all',1,'stripe','left','bank',-1,'stripe','bank',102,'/stripe/transaction.php','','StripeTransactionList','','stripe',NULL,NULL,'$user->rights->banque->lire','$conf->stripe->enabled && $conf->banque->enabled && $conf->global->MAIN_FEATURES_LEVEL >= 1',0,'2021-07-11 17:49:47'),(167126,'all',1,'stripe','left','bank',-1,'stripe','bank',103,'/stripe/payout.php','','StripePayoutList','','stripe',NULL,NULL,'$user->rights->banque->lire','$conf->stripe->enabled && $conf->banque->enabled && $conf->global->MAIN_FEATURES_LEVEL >= 1',0,'2021-07-11 17:49:47'),(167127,'all',1,'ticket','left','ticket',-1,NULL,'ticket',101,'/ticket/index.php','','Ticket','','ticket',NULL,'ticket','$user->rights->ticket->read','$conf->ticket->enabled',2,'2021-07-11 17:49:47'),(167128,'all',1,'ticket','left','ticket',-1,'ticket','ticket',102,'/ticket/card.php?action=create','','NewTicket','','ticket',NULL,NULL,'$user->rights->ticket->write','$conf->ticket->enabled',2,'2021-07-11 17:49:47'),(167129,'all',1,'ticket','left','ticket',-1,'ticket','ticket',103,'/ticket/list.php?search_fk_status=non_closed','','List','','ticket',NULL,'ticketlist','$user->rights->ticket->read','$conf->ticket->enabled',2,'2021-07-11 17:49:47'),(167130,'all',1,'ticket','left','ticket',-1,'ticket','ticket',105,'/ticket/list.php?mode=mine&search_fk_status=non_closed','','MenuTicketMyAssign','','ticket',NULL,'ticketmy','$user->rights->ticket->read','$conf->ticket->enabled',0,'2021-07-11 17:49:47'),(167131,'all',1,'ticket','left','ticket',-1,'ticket','ticket',107,'/ticket/stats/index.php','','Statistics','','ticket',NULL,NULL,'$user->rights->ticket->read','$conf->ticket->enabled',0,'2021-07-11 17:49:47'),(167132,'all',1,'takepos','top','takepos',0,NULL,NULL,1001,'/takepos/index.php','takepos','PointOfSaleShort','','cashdesk',NULL,NULL,'$user->rights->takepos->run','$conf->takepos->enabled',2,'2021-07-11 17:49:48'),(167133,'all',1,'website','top','website',0,NULL,NULL,100,'/website/index.php','','WebSites','','website',NULL,NULL,'$user->rights->website->read','$conf->website->enabled',2,'2021-07-11 17:49:48'); +INSERT INTO `llx_menu` VALUES (103094,'all',2,'agenda','top','agenda',0,NULL,NULL,100,'/comm/action/index.php','','Agenda',NULL,'agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103095,'all',2,'agenda','left','agenda',103094,NULL,NULL,100,'/comm/action/index.php?mainmenu=agenda&leftmenu=agenda','','Actions',NULL,'agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103096,'all',2,'agenda','left','agenda',103095,NULL,NULL,101,'/comm/action/card.php?mainmenu=agenda&leftmenu=agenda&action=create','','NewAction',NULL,'commercial',NULL,NULL,'($user->rights->agenda->myactions->create||$user->rights->agenda->allactions->create)','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103097,'all',2,'agenda','left','agenda',103095,NULL,NULL,102,'/comm/action/index.php?mainmenu=agenda&leftmenu=agenda','','Calendar',NULL,'agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103098,'all',2,'agenda','left','agenda',103097,NULL,NULL,103,'/comm/action/index.php?mainmenu=agenda&leftmenu=agenda&status=todo&filter=mine','','MenuToDoMyActions',NULL,'agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103099,'all',2,'agenda','left','agenda',103097,NULL,NULL,104,'/comm/action/index.php?mainmenu=agenda&leftmenu=agenda&status=done&filter=mine','','MenuDoneMyActions',NULL,'agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103100,'all',2,'agenda','left','agenda',103097,NULL,NULL,105,'/comm/action/index.php?mainmenu=agenda&leftmenu=agenda&status=todo','','MenuToDoActions',NULL,'agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$user->rights->agenda->allactions->read',2,'2015-03-13 15:29:19'),(103101,'all',2,'agenda','left','agenda',103097,NULL,NULL,106,'/comm/action/index.php?mainmenu=agenda&leftmenu=agenda&status=done','','MenuDoneActions',NULL,'agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$user->rights->agenda->allactions->read',2,'2015-03-13 15:29:19'),(103102,'all',2,'agenda','left','agenda',103095,NULL,NULL,112,'/comm/action/listactions.php?mainmenu=agenda&leftmenu=agenda','','List',NULL,'agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103103,'all',2,'agenda','left','agenda',103102,NULL,NULL,113,'/comm/action/listactions.php?mainmenu=agenda&leftmenu=agenda&status=todo&filter=mine','','MenuToDoMyActions',NULL,'agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103104,'all',2,'agenda','left','agenda',103102,NULL,NULL,114,'/comm/action/listactions.php?mainmenu=agenda&leftmenu=agenda&status=done&filter=mine','','MenuDoneMyActions',NULL,'agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103105,'all',2,'agenda','left','agenda',103102,NULL,NULL,115,'/comm/action/listactions.php?mainmenu=agenda&leftmenu=agenda&status=todo','','MenuToDoActions',NULL,'agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$user->rights->agenda->allactions->read',2,'2015-03-13 15:29:19'),(103106,'all',2,'agenda','left','agenda',103102,NULL,NULL,116,'/comm/action/listactions.php?mainmenu=agenda&leftmenu=agenda&status=done','','MenuDoneActions',NULL,'agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$user->rights->agenda->allactions->read',2,'2015-03-13 15:29:19'),(103107,'all',2,'agenda','left','agenda',103095,NULL,NULL,120,'/comm/action/rapport/index.php?mainmenu=agenda&leftmenu=agenda','','Reportings',NULL,'agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$conf->agenda->enabled',2,'2015-03-13 15:29:19'),(103134,'all',2,'opensurvey','top','opensurvey',0,NULL,NULL,200,'/opensurvey/index.php','','Surveys',NULL,'opensurvey',NULL,NULL,'$user->rights->opensurvey->survey->read','$conf->opensurvey->enabled',0,'2015-03-13 20:33:42'),(103135,'all',2,'opensurvey','left','opensurvey',-1,NULL,'opensurvey',200,'/opensurvey/index.php?mainmenu=opensurvey&leftmenu=opensurvey','','Survey',NULL,'opensurvey@opensurvey',NULL,'opensurvey','','$conf->opensurvey->enabled',0,'2015-03-13 20:33:42'),(103136,'all',2,'opensurvey','left','opensurvey',-1,'opensurvey','opensurvey',210,'/opensurvey/public/index.php','_blank','NewSurvey',NULL,'opensurvey@opensurvey',NULL,'opensurvey_new','','$conf->opensurvey->enabled',0,'2015-03-13 20:33:42'),(103137,'all',2,'opensurvey','left','opensurvey',-1,'opensurvey','opensurvey',220,'/opensurvey/list.php','','List',NULL,'opensurvey@opensurvey',NULL,'opensurvey_list','','$conf->opensurvey->enabled',0,'2015-03-13 20:33:42'),(161088,'auguria',1,'','top','home',0,NULL,NULL,10,'/index.php?mainmenu=home&leftmenu=','','Home',NULL,'',-1,'','','1',2,'2017-08-30 15:14:30'),(161089,'auguria',1,'societe|fournisseur','top','companies',0,NULL,NULL,20,'/societe/index.php?mainmenu=companies&leftmenu=','','ThirdParties',NULL,'companies',-1,'','$user->rights->societe->lire || $user->rights->societe->contact->lire','( ! empty($conf->societe->enabled) && (empty($conf->global->SOCIETE_DISABLE_PROSPECTS) || empty($conf->global->SOCIETE_DISABLE_CUSTOMERS))) || ! empty($conf->fournisseur->enabled)',2,'2017-08-30 15:14:30'),(161090,'auguria',1,'product|service','top','products',0,NULL,NULL,30,'/product/index.php?mainmenu=products&leftmenu=','','Products/Services',NULL,'products',-1,'','$user->rights->produit->lire||$user->rights->service->lire','$conf->product->enabled || $conf->service->enabled',0,'2017-08-30 15:14:30'),(161092,'auguria',1,'propal|commande|fournisseur|contrat|ficheinter','top','commercial',0,NULL,NULL,40,'/comm/index.php?mainmenu=commercial&leftmenu=','','Commercial',NULL,'commercial',-1,'','$user->rights->societe->lire || $user->rights->societe->contact->lire','$conf->propal->enabled || $conf->commande->enabled || $conf->supplier_order->enabled || $conf->contrat->enabled || $conf->ficheinter->enabled',2,'2017-08-30 15:14:30'),(161093,'auguria',1,'comptabilite|accounting|facture|don|tax|salaries|loan','top','accountancy',0,NULL,NULL,50,'/compta/index.php?mainmenu=accountancy&leftmenu=','','MenuFinancial',NULL,'compta',-1,'','$user->rights->compta->resultat->lire || $user->rights->accounting->plancompte->lire || $user->rights->facture->lire|| $user->rights->don->lire || $user->rights->tax->charges->lire || $user->rights->salaries->read || $user->rights->loan->read','$conf->comptabilite->enabled || $conf->accounting->enabled || $conf->facture->enabled || $conf->don->enabled || $conf->tax->enabled || $conf->salaries->enabled || $conf->supplier_invoice->enabled || $conf->loan->enabled',2,'2017-08-30 15:14:30'),(161094,'auguria',1,'projet','top','project',0,NULL,NULL,70,'/projet/index.php?mainmenu=project&leftmenu=','','Projects',NULL,'projects',-1,'','$user->rights->projet->lire','$conf->projet->enabled',2,'2017-08-30 15:14:30'),(161095,'auguria',1,'mailing|export|import|opensurvey|resource','top','tools',0,NULL,NULL,90,'/core/tools.php?mainmenu=tools&leftmenu=','','Tools',NULL,'other',-1,'','$user->rights->mailing->lire || $user->rights->export->lire || $user->rights->import->run || $user->rights->opensurvey->read || $user->rights->resource->read','$conf->mailing->enabled || $conf->export->enabled || $conf->import->enabled || $conf->opensurvey->enabled || $conf->resource->enabled',2,'2017-08-30 15:14:30'),(161101,'auguria',1,'banque|prelevement','top','bank',0,NULL,NULL,60,'/compta/bank/index.php?mainmenu=bank&leftmenu=bank','','MenuBankCash',NULL,'banks',-1,'','$user->rights->banque->lire || $user->rights->prelevement->bons->lire','$conf->banque->enabled || $conf->prelevement->enabled',0,'2017-08-30 15:14:30'),(161102,'auguria',1,'hrm|holiday|deplacement|expensereport','top','hrm',0,NULL,NULL,80,'/hrm/index.php?mainmenu=hrm&leftmenu=','','HRM',NULL,'holiday',-1,'','$user->rights->hrm->employee->read || $user->rights->holiday->write || $user->rights->deplacement->lire || $user->rights->expensereport->lire','$conf->hrm->enabled || $conf->holiday->enabled || $conf->deplacement->enabled || $conf->expensereport->enabled',0,'2017-08-30 15:14:30'),(161177,'auguria',1,'','left','home',161088,NULL,NULL,0,'/index.php','','MyDashboard',NULL,'',0,'','','1',2,'2017-08-30 15:14:30'),(161187,'auguria',1,'','left','home',161088,NULL,NULL,1,'/admin/index.php?leftmenu=setup','','Setup',NULL,'admin',0,'setup','','$user->admin',2,'2017-08-30 15:14:30'),(161188,'auguria',1,'','left','home',161187,NULL,NULL,1,'/admin/company.php?leftmenu=setup','','MenuCompanySetup',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161189,'auguria',1,'','left','home',161187,NULL,NULL,4,'/admin/ihm.php?leftmenu=setup','','GUISetup',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161190,'auguria',1,'','left','home',161187,NULL,NULL,2,'/admin/modules.php?leftmenu=setup','','Modules',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161191,'auguria',1,'','left','home',161187,NULL,NULL,6,'/admin/boxes.php?leftmenu=setup','','Boxes',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161192,'auguria',1,'','left','home',161187,NULL,NULL,3,'/admin/menus.php?leftmenu=setup','','Menus',NULL,'admin',1,'','','$leftmenu==\'setup\'',2,'2017-09-06 08:29:47'),(161193,'auguria',1,'','left','home',161187,NULL,NULL,7,'/admin/delais.php?leftmenu=setup','','Alerts',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161194,'auguria',1,'','left','home',161187,NULL,NULL,10,'/admin/pdf.php?leftmenu=setup','','PDF',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161195,'auguria',1,'','left','home',161187,NULL,NULL,8,'/admin/security_other.php?leftmenu=setup','','Security',NULL,'admin',1,'','','$leftmenu==\'setup\'',2,'2017-09-06 08:29:36'),(161196,'auguria',1,'','left','home',161187,NULL,NULL,11,'/admin/mails.php?leftmenu=setup','','Emails',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161197,'auguria',1,'','left','home',161187,NULL,NULL,9,'/admin/limits.php?leftmenu=setup','','MenuLimits',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161198,'auguria',1,'','left','home',161187,NULL,NULL,13,'/admin/dict.php?leftmenu=setup','','Dictionary',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161199,'auguria',1,'','left','home',161187,NULL,NULL,14,'/admin/const.php?leftmenu=setup','','OtherSetup',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161200,'auguria',1,'','left','home',161187,NULL,NULL,12,'/admin/sms.php?leftmenu=setup','','SMS',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161201,'auguria',1,'','left','home',161187,NULL,NULL,4,'/admin/translation.php?leftmenu=setup','','Translation',NULL,'admin',1,'','','$leftmenu==\"setup\"',2,'2017-08-30 15:14:30'),(161288,'auguria',1,'','left','home',161387,NULL,NULL,0,'/admin/system/dolibarr.php?leftmenu=admintools','','InfoDolibarr',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161289,'auguria',1,'','left','home',161288,NULL,NULL,2,'/admin/system/modules.php?leftmenu=admintools','','Modules',NULL,'admin',2,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161290,'auguria',1,'','left','home',161288,NULL,NULL,3,'/admin/triggers.php?leftmenu=admintools','','Triggers',NULL,'admin',2,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161291,'auguria',1,'','left','home',161288,NULL,NULL,4,'/admin/system/filecheck.php?leftmenu=admintools','','FileCheck',NULL,'admin',2,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161292,'auguria',1,'','left','home',161387,NULL,NULL,1,'/admin/system/browser.php?leftmenu=admintools','','InfoBrowser',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161293,'auguria',1,'','left','home',161387,NULL,NULL,2,'/admin/system/os.php?leftmenu=admintools','','InfoOS',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161294,'auguria',1,'','left','home',161387,NULL,NULL,3,'/admin/system/web.php?leftmenu=admintools','','InfoWebServer',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161295,'auguria',1,'','left','home',161387,NULL,NULL,4,'/admin/system/phpinfo.php?leftmenu=admintools','','InfoPHP',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161297,'auguria',1,'','left','home',161387,NULL,NULL,5,'/admin/system/database.php?leftmenu=admintools','','InfoDatabase',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161387,'auguria',1,'','left','home',161088,NULL,NULL,2,'/admin/tools/index.php?leftmenu=admintools','','AdminTools',NULL,'admin',0,'admintools','','$user->admin',2,'2017-08-30 15:14:30'),(161388,'auguria',1,'','left','home',161387,NULL,NULL,6,'/admin/tools/dolibarr_export.php?leftmenu=admintools','','Backup',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161389,'auguria',1,'','left','home',161387,NULL,NULL,7,'/admin/tools/dolibarr_import.php?leftmenu=admintools','','Restore',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161392,'auguria',1,'','left','home',161387,NULL,NULL,8,'/admin/tools/update.php?leftmenu=admintools','','MenuUpgrade',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161393,'auguria',1,'','left','home',161387,NULL,NULL,9,'/admin/tools/eaccelerator.php?leftmenu=admintools','','EAccelerator',NULL,'admin',1,'','','$leftmenu==\"admintools\" && function_exists(\"eaccelerator_info\")',2,'2017-08-30 15:14:30'),(161394,'auguria',1,'','left','home',161387,NULL,NULL,10,'/admin/tools/listevents.php?leftmenu=admintools','','Audit',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161395,'auguria',1,'','left','home',161387,NULL,NULL,11,'/admin/tools/listsessions.php?leftmenu=admintools','','Sessions',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161396,'auguria',1,'','left','home',161387,NULL,NULL,12,'/admin/tools/purge.php?leftmenu=admintools','','Purge',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161398,'auguria',1,'','left','home',161387,NULL,NULL,14,'/admin/system/about.php?leftmenu=admintools','','ExternalResources',NULL,'admin',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161407,'auguria',1,'','left','home',161387,NULL,NULL,15,'/product/admin/product_tools.php?mainmenu=home&leftmenu=admintools','','ProductVatMassChange',NULL,'products',1,'','','$leftmenu==\"admintools\"',2,'2017-08-30 15:14:30'),(161487,'auguria',1,'','left','home',161088,NULL,NULL,4,'/user/home.php?leftmenu=users','','MenuUsersAndGroups',NULL,'users',0,'users','','1',2,'2017-08-30 15:14:30'),(161488,'auguria',1,'','left','home',161487,NULL,NULL,0,'/user/index.php?leftmenu=users','','Users',NULL,'users',1,'','$user->rights->user->user->lire || $user->admin','$leftmenu==\"users\"',2,'2017-08-30 15:14:30'),(161489,'auguria',1,'','left','home',161488,NULL,NULL,0,'/user/card.php?leftmenu=users&action=create','','NewUser',NULL,'users',2,'','($user->rights->user->user->creer || $user->admin) && !(! empty($conf->multicompany->enabled) && $conf->entity > 1 && $conf->global->MULTICOMPANY_TRANSVERSE_MODE)','$leftmenu==\"users\"',2,'2017-08-30 15:14:30'),(161490,'auguria',1,'','left','home',161487,NULL,NULL,1,'/user/group/index.php?leftmenu=users','','Groups',NULL,'users',1,'','(($conf->global->MAIN_USE_ADVANCED_PERMS?$user->rights->user->group_advance->read:$user->rights->user->user->lire) || $user->admin) && !(! empty($conf->multicompany->enabled) && $conf->entity > 1 && $conf->global->MULTICOMPANY_TRANSVERSE_MODE)','$leftmenu==\"users\"',2,'2017-08-30 15:14:30'),(161491,'auguria',1,'','left','home',161490,NULL,NULL,0,'/user/group/card.php?leftmenu=users&action=create','','NewGroup',NULL,'users',2,'','(($conf->global->MAIN_USE_ADVANCED_PERMS?$user->rights->user->group_advance->write:$user->rights->user->user->creer) || $user->admin) && !(! empty($conf->multicompany->enabled) && $conf->entity > 1 && $conf->global->MULTICOMPANY_TRANSVERSE_MODE)','$leftmenu==\"users\"',2,'2017-08-30 15:14:30'),(161587,'auguria',1,'','left','companies',161089,NULL,NULL,0,'/societe/index.php?leftmenu=thirdparties','','ThirdParty',NULL,'companies',0,'thirdparties','$user->rights->societe->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161588,'auguria',1,'','left','companies',161587,NULL,NULL,0,'/societe/card.php?action=create','','MenuNewThirdParty',NULL,'companies',1,'','$user->rights->societe->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161589,'auguria',1,'','left','companies',161587,NULL,NULL,0,'/societe/list.php?action=create','','List',NULL,'companies',1,'','$user->rights->societe->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161590,'auguria',1,'','left','companies',161587,NULL,NULL,5,'/societe/list.php?type=f&leftmenu=suppliers','','ListSuppliersShort',NULL,'suppliers',1,'','$user->rights->societe->lire && $user->rights->fournisseur->lire','$conf->societe->enabled && $conf->fournisseur->enabled',2,'2017-08-30 15:14:30'),(161591,'auguria',1,'','left','companies',161590,NULL,NULL,0,'/societe/card.php?leftmenu=supplier&action=create&type=f','','NewSupplier',NULL,'suppliers',2,'','$user->rights->societe->creer','$conf->societe->enabled && $conf->fournisseur->enabled',2,'2017-08-30 15:14:30'),(161593,'auguria',1,'','left','companies',161587,NULL,NULL,3,'/societe/list.php?type=p&leftmenu=prospects','','ListProspectsShort',NULL,'companies',1,'','$user->rights->societe->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161594,'auguria',1,'','left','companies',161593,NULL,NULL,0,'/societe/card.php?leftmenu=prospects&action=create&type=p','','MenuNewProspect',NULL,'companies',2,'','$user->rights->societe->creer','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161596,'auguria',1,'','left','companies',161587,NULL,NULL,4,'/societe/list.php?type=c&leftmenu=customers','','ListCustomersShort',NULL,'companies',1,'','$user->rights->societe->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161597,'auguria',1,'','left','companies',161596,NULL,NULL,0,'/societe/card.php?leftmenu=customers&action=create&type=c','','MenuNewCustomer',NULL,'companies',2,'','$user->rights->societe->creer','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161687,'auguria',1,'','left','companies',161089,NULL,NULL,1,'/contact/list.php?leftmenu=contacts','','ContactsAddresses',NULL,'companies',0,'contacts','$user->rights->societe->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161688,'auguria',1,'','left','companies',161687,NULL,NULL,0,'/contact/card.php?leftmenu=contacts&action=create','','NewContactAddress',NULL,'companies',1,'','$user->rights->societe->creer','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161689,'auguria',1,'','left','companies',161687,NULL,NULL,1,'/contact/list.php?leftmenu=contacts','','List',NULL,'companies',1,'','$user->rights->societe->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161691,'auguria',1,'','left','companies',161689,NULL,NULL,1,'/contact/list.php?leftmenu=contacts&type=p','','ThirdPartyProspects',NULL,'companies',2,'','$user->rights->societe->contact->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161692,'auguria',1,'','left','companies',161689,NULL,NULL,2,'/contact/list.php?leftmenu=contacts&type=c','','ThirdPartyCustomers',NULL,'companies',2,'','$user->rights->societe->contact->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161693,'auguria',1,'','left','companies',161689,NULL,NULL,3,'/contact/list.php?leftmenu=contacts&type=f','','ThirdPartySuppliers',NULL,'companies',2,'','$user->rights->societe->contact->lire','$conf->societe->enabled && $conf->fournisseur->enabled',2,'2017-08-30 15:14:30'),(161694,'auguria',1,'','left','companies',161689,NULL,NULL,4,'/contact/list.php?leftmenu=contacts&type=o','','Others',NULL,'companies',2,'','$user->rights->societe->contact->lire','$conf->societe->enabled',2,'2017-08-30 15:14:30'),(161737,'auguria',1,'','left','companies',161089,NULL,NULL,3,'/categories/index.php?leftmenu=cat&type=1','','SuppliersCategoriesShort',NULL,'categories',0,'cat','$user->rights->categorie->lire','$conf->societe->enabled && $conf->categorie->enabled',2,'2017-08-30 15:14:30'),(161738,'auguria',1,'','left','companies',161737,NULL,NULL,0,'/categories/card.php?action=create&type=1','','NewCategory',NULL,'categories',1,'','$user->rights->categorie->creer','$conf->societe->enabled && $conf->categorie->enabled',2,'2017-08-30 15:14:30'),(161747,'auguria',1,'','left','companies',161089,NULL,NULL,4,'/categories/index.php?leftmenu=cat&type=2','','CustomersProspectsCategoriesShort',NULL,'categories',0,'cat','$user->rights->categorie->lire','$conf->fournisseur->enabled && $conf->categorie->enabled',2,'2017-08-30 15:14:30'),(161748,'auguria',1,'','left','companies',161747,NULL,NULL,0,'/categories/card.php?action=create&type=2','','NewCategory',NULL,'categories',1,'','$user->rights->categorie->creer','$conf->fournisseur->enabled && $conf->categorie->enabled',2,'2017-08-30 15:14:30'),(161757,'auguria',1,'','left','companies',161089,NULL,NULL,3,'/categories/index.php?leftmenu=cat&type=4','','ContactCategoriesShort',NULL,'categories',0,'cat','$user->rights->categorie->lire','$conf->societe->enabled && $conf->categorie->enabled',2,'2017-08-30 15:14:30'),(161758,'auguria',1,'','left','companies',161757,NULL,NULL,0,'/categories/card.php?action=create&type=4','','NewCategory',NULL,'categories',1,'','$user->rights->categorie->creer','$conf->societe->enabled && $conf->categorie->enabled',2,'2017-08-30 15:14:30'),(162187,'auguria',1,'','left','commercial',161092,NULL,NULL,4,'/comm/propal/index.php?leftmenu=propals','','Prop',NULL,'propal',0,'propals','$user->rights->propale->lire','$conf->propal->enabled',2,'2017-08-30 15:14:30'),(162188,'auguria',1,'','left','commercial',162187,NULL,NULL,0,'/comm/propal/card.php?action=create&leftmenu=propals','','NewPropal',NULL,'propal',1,'','$user->rights->propale->creer','$conf->propal->enabled',2,'2017-08-30 15:14:30'),(162189,'auguria',1,'','left','commercial',162187,NULL,NULL,1,'/comm/propal/list.php?leftmenu=propals','','List',NULL,'propal',1,'','$user->rights->propale->lire','$conf->propal->enabled',2,'2017-08-30 15:14:30'),(162190,'auguria',1,'','left','commercial',162189,NULL,NULL,2,'/comm/propal/list.php?leftmenu=propals&search_status=0','','PropalsDraft',NULL,'propal',1,'','$user->rights->propale->lire','$conf->propal->enabled && $leftmenu==\"propals\"',2,'2017-08-30 15:14:30'),(162191,'auguria',1,'','left','commercial',162189,NULL,NULL,3,'/comm/propal/list.php?leftmenu=propals&search_status=1','','PropalsOpened',NULL,'propal',1,'','$user->rights->propale->lire','$conf->propal->enabled && $leftmenu==\"propals\"',2,'2017-08-30 15:14:30'),(162192,'auguria',1,'','left','commercial',162189,NULL,NULL,4,'/comm/propal/list.php?leftmenu=propals&search_status=2','','PropalStatusSigned',NULL,'propal',1,'','$user->rights->propale->lire','$conf->propal->enabled && $leftmenu==\"propals\"',2,'2017-08-30 15:14:30'),(162193,'auguria',1,'','left','commercial',162189,NULL,NULL,5,'/comm/propal/list.php?leftmenu=propals&search_status=3','','PropalStatusNotSigned',NULL,'propal',1,'','$user->rights->propale->lire','$conf->propal->enabled && $leftmenu==\"propals\"',2,'2017-08-30 15:14:30'),(162194,'auguria',1,'','left','commercial',162189,NULL,NULL,6,'/comm/propal/list.php?leftmenu=propals&search_status=4','','PropalStatusBilled',NULL,'propal',1,'','$user->rights->propale->lire','$conf->propal->enabled && $leftmenu==\"propals\"',2,'2017-08-30 15:14:30'),(162197,'auguria',1,'','left','commercial',162187,NULL,NULL,4,'/comm/propal/stats/index.php?leftmenu=propals','','Statistics',NULL,'propal',1,'','$user->rights->propale->lire','$conf->propal->enabled',2,'2017-08-30 15:14:30'),(162287,'auguria',1,'','left','commercial',161092,NULL,NULL,5,'/commande/index.php?leftmenu=orders','','CustomersOrders',NULL,'orders',0,'orders','$user->rights->commande->lire','$conf->commande->enabled',2,'2017-08-30 15:14:30'),(162288,'auguria',1,'','left','commercial',162287,NULL,NULL,0,'/commande/card.php?action=create&leftmenu=orders','','NewOrder',NULL,'orders',1,'','$user->rights->commande->creer','$conf->commande->enabled',2,'2017-08-30 15:14:30'),(162289,'auguria',1,'','left','commercial',162287,NULL,NULL,1,'/commande/list.php?leftmenu=orders','','List',NULL,'orders',1,'','$user->rights->commande->lire','$conf->commande->enabled',2,'2017-08-30 15:14:30'),(162290,'auguria',1,'','left','commercial',162289,NULL,NULL,2,'/commande/list.php?leftmenu=orders&search_status=0','','StatusOrderDraftShort',NULL,'orders',1,'','$user->rights->commande->lire','$conf->commande->enabled && $leftmenu==\"orders\"',2,'2017-08-30 15:14:30'),(162291,'auguria',1,'','left','commercial',162289,NULL,NULL,3,'/commande/list.php?leftmenu=orders&search_status=1','','StatusOrderValidated',NULL,'orders',1,'','$user->rights->commande->lire','$conf->commande->enabled && $leftmenu==\"orders\"',2,'2017-08-30 15:14:30'),(162292,'auguria',1,'','left','commercial',162289,NULL,NULL,4,'/commande/list.php?leftmenu=orders&search_status=2','','StatusOrderOnProcessShort',NULL,'orders',1,'','$user->rights->commande->lire','$conf->commande->enabled && $leftmenu==\"orders\"',2,'2017-08-30 15:14:30'),(162293,'auguria',1,'','left','commercial',162289,NULL,NULL,5,'/commande/list.php?leftmenu=orders&search_status=3','','StatusOrderToBill',NULL,'orders',1,'','$user->rights->commande->lire','$conf->commande->enabled && $leftmenu==\"orders\"',2,'2017-08-30 15:14:30'),(162294,'auguria',1,'','left','commercial',162289,NULL,NULL,6,'/commande/list.php?leftmenu=orders&search_status=4','','StatusOrderProcessed',NULL,'orders',1,'','$user->rights->commande->lire','$conf->commande->enabled && $leftmenu==\"orders\"',2,'2017-08-30 15:14:30'),(162295,'auguria',1,'','left','commercial',162289,NULL,NULL,7,'/commande/list.php?leftmenu=orders&search_status=-1','','StatusOrderCanceledShort',NULL,'orders',1,'','$user->rights->commande->lire','$conf->commande->enabled && $leftmenu==\"orders\"',2,'2017-08-30 15:14:30'),(162296,'auguria',1,'','left','commercial',162287,NULL,NULL,4,'/commande/stats/index.php?leftmenu=orders','','Statistics',NULL,'orders',1,'','$user->rights->commande->lire','$conf->commande->enabled',2,'2017-08-30 15:14:30'),(162387,'auguria',1,'','left','commercial',161090,NULL,NULL,6,'/expedition/index.php?leftmenu=sendings','','Shipments',NULL,'sendings',0,'sendings','$user->rights->expedition->lire','$conf->expedition->enabled',2,'2017-08-30 15:14:30'),(162388,'auguria',1,'','left','commercial',162387,NULL,NULL,0,'/expedition/card.php?action=create2&leftmenu=sendings','','NewSending',NULL,'sendings',1,'','$user->rights->expedition->creer','$conf->expedition->enabled && $leftmenu==\"sendings\"',2,'2017-08-30 15:14:30'),(162389,'auguria',1,'','left','commercial',162387,NULL,NULL,1,'/expedition/list.php?leftmenu=sendings','','List',NULL,'sendings',1,'','$user->rights->expedition->lire','$conf->expedition->enabled && $leftmenu==\"sendings\"',2,'2017-08-30 15:14:30'),(162390,'auguria',1,'','left','commercial',162387,NULL,NULL,2,'/expedition/stats/index.php?leftmenu=sendings','','Statistics',NULL,'sendings',1,'','$user->rights->expedition->lire','$conf->expedition->enabled && $leftmenu==\"sendings\"',2,'2017-08-30 15:14:30'),(162487,'auguria',1,'','left','commercial',161092,NULL,NULL,7,'/contrat/index.php?leftmenu=contracts','','Contracts',NULL,'contracts',0,'contracts','$user->rights->contrat->lire','$conf->contrat->enabled',2,'2017-08-30 15:14:30'),(162488,'auguria',1,'','left','commercial',162487,NULL,NULL,0,'/contrat/card.php?&action=create&leftmenu=contracts','','NewContract',NULL,'contracts',1,'','$user->rights->contrat->creer','$conf->contrat->enabled',2,'2017-08-30 15:14:30'),(162489,'auguria',1,'','left','commercial',162487,NULL,NULL,1,'/contrat/list.php?leftmenu=contracts','','List',NULL,'contracts',1,'','$user->rights->contrat->lire','$conf->contrat->enabled',2,'2017-08-30 15:14:30'),(162490,'auguria',1,'','left','commercial',162487,NULL,NULL,2,'/contrat/services.php?leftmenu=contracts','','MenuServices',NULL,'contracts',1,'','$user->rights->contrat->lire','$conf->contrat->enabled',2,'2017-08-30 15:14:30'),(162491,'auguria',1,'','left','commercial',162490,NULL,NULL,0,'/contrat/services.php?leftmenu=contracts&mode=0','','MenuInactiveServices',NULL,'contracts',2,'','$user->rights->contrat->lire','$conf->contrat->enabled && $leftmenu==\"contracts\"',2,'2017-08-30 15:14:30'),(162492,'auguria',1,'','left','commercial',162490,NULL,NULL,1,'/contrat/services.php?leftmenu=contracts&mode=4','','MenuRunningServices',NULL,'contracts',2,'','$user->rights->contrat->lire','$conf->contrat->enabled && $leftmenu==\"contracts\"',2,'2017-08-30 15:14:30'),(162493,'auguria',1,'','left','commercial',162490,NULL,NULL,2,'/contrat/services.php?leftmenu=contracts&mode=4&filter=expired','','MenuExpiredServices',NULL,'contracts',2,'','$user->rights->contrat->lire','$conf->contrat->enabled && $leftmenu==\"contracts\"',2,'2017-08-30 15:14:30'),(162494,'auguria',1,'','left','commercial',162490,NULL,NULL,3,'/contrat/services.php?leftmenu=contracts&mode=5','','MenuClosedServices',NULL,'contracts',2,'','$user->rights->contrat->lire','$conf->contrat->enabled && $leftmenu==\"contracts\"',2,'2017-08-30 15:14:30'),(162587,'auguria',1,'','left','commercial',161092,NULL,NULL,8,'/fichinter/list.php?leftmenu=ficheinter','','Interventions',NULL,'interventions',0,'ficheinter','$user->rights->ficheinter->lire','$conf->ficheinter->enabled',2,'2017-08-30 15:14:30'),(162588,'auguria',1,'','left','commercial',162587,NULL,NULL,0,'/fichinter/card.php?action=create&leftmenu=ficheinter','','NewIntervention',NULL,'interventions',1,'','$user->rights->ficheinter->creer','$conf->ficheinter->enabled',2,'2017-08-30 15:14:30'),(162589,'auguria',1,'','left','commercial',162587,NULL,NULL,1,'/fichinter/list.php?leftmenu=ficheinter','','List',NULL,'interventions',1,'','$user->rights->ficheinter->lire','$conf->ficheinter->enabled',2,'2017-08-30 15:14:30'),(162590,'auguria',1,'','left','commercial',162587,NULL,NULL,2,'/fichinter/stats/index.php?leftmenu=ficheinter','','Statistics',NULL,'interventions',1,'','$user->rights->ficheinter->lire','$conf->ficheinter->enabled',2,'2017-08-30 15:14:30'),(162687,'auguria',1,'','left','accountancy',161093,NULL,NULL,3,'/fourn/facture/list.php?leftmenu=suppliers_bills','','BillsSuppliers',NULL,'bills',0,'supplier_bills','$user->rights->fournisseur->facture->lire','$conf->supplier_invoice->enabled',2,'2017-08-30 15:14:30'),(162688,'auguria',1,'','left','accountancy',162687,NULL,NULL,0,'/fourn/facture/card.php?action=create&leftmenu=suppliers_bills','','NewBill',NULL,'bills',1,'','$user->rights->fournisseur->facture->creer','$conf->supplier_invoice->enabled',2,'2017-08-30 15:14:30'),(162689,'auguria',1,'','left','accountancy',162687,NULL,NULL,1,'/fourn/facture/list.php?leftmenu=suppliers_bills','','List',NULL,'bills',1,'','$user->rights->fournisseur->facture->lire','$conf->supplier_invoice->enabled',2,'2017-08-30 15:14:30'),(162690,'auguria',1,'','left','accountancy',162687,NULL,NULL,2,'/fourn/facture/paiement.php?leftmenu=suppliers_bills','','Payments',NULL,'bills',1,'','$user->rights->fournisseur->facture->lire','$conf->supplier_invoice->enabled',2,'2017-08-30 15:14:30'),(162691,'auguria',1,'','left','accountancy',162687,NULL,NULL,8,'/compta/facture/stats/index.php?leftmenu=customers_bills&mode=supplier','','Statistics',NULL,'bills',1,'','$user->rights->fournisseur->facture->lire','$conf->supplier_invoice->enabled',2,'2017-08-30 15:14:30'),(162692,'auguria',1,'','left','accountancy',162690,NULL,NULL,1,'/fourn/facture/rapport.php?leftmenu=suppliers_bills','','Reporting',NULL,'bills',2,'','$user->rights->fournisseur->facture->lire','$conf->supplier_invoice->enabled',2,'2017-08-30 15:14:30'),(162787,'auguria',1,'','left','accountancy',161093,NULL,NULL,3,'/compta/facture/list.php?leftmenu=customers_bills','','BillsCustomers',NULL,'bills',0,'customer_bills','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162788,'auguria',1,'','left','accountancy',162787,NULL,NULL,3,'/compta/facture/card.php?action=create&leftmenu=customers_bills','','NewBill',NULL,'bills',1,'','$user->rights->facture->creer','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162789,'auguria',1,'','left','accountancy',162787,NULL,NULL,5,'/compta/facture/fiche-rec.php?leftmenu=customers_bills','','ListOfTemplates',NULL,'bills',1,'','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162791,'auguria',1,'','left','accountancy',162787,NULL,NULL,6,'/compta/paiement/list.php?leftmenu=customers_bills','','Payments',NULL,'bills',1,'','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162792,'auguria',1,'','left','accountancy',162787,NULL,NULL,4,'/compta/facture/list.php?leftmenu=customers_bills','','List',NULL,'bills',1,'','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162797,'auguria',1,'','left','accountancy',162791,NULL,NULL,1,'/compta/paiement/rapport.php?leftmenu=customers_bills','','Reportings',NULL,'bills',2,'','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162798,'auguria',1,'','left','accountancy',161101,NULL,NULL,9,'/compta/paiement/cheque/index.php?leftmenu=checks&mainmenu=bank','','MenuChequeDeposits',NULL,'bills',0,'checks','$user->rights->banque->lire','empty($conf->global->BANK_DISABLE_CHECK_DEPOSIT) && ! empty($conf->banque->enabled) && (! empty($conf->facture->enabled) || ! empty($conf->global->MAIN_MENU_CHEQUE_DEPOSIT_ON))',2,'2017-08-30 15:14:30'),(162799,'auguria',1,'','left','accountancy',162798,NULL,NULL,0,'/compta/paiement/cheque/card.php?leftmenu=checks&action=new','','NewCheckDeposit',NULL,'compta',1,'','$user->rights->banque->lire','empty($conf->global->BANK_DISABLE_CHECK_DEPOSIT) && ! empty($conf->banque->enabled) && (! empty($conf->facture->enabled) || ! empty($conf->global->MAIN_MENU_CHEQUE_DEPOSIT_ON))',2,'2017-08-30 15:14:30'),(162800,'auguria',1,'','left','accountancy',162798,NULL,NULL,1,'/compta/paiement/cheque/list.php?leftmenu=checks','','List',NULL,'bills',1,'','$user->rights->banque->lire','empty($conf->global->BANK_DISABLE_CHECK_DEPOSIT) && ! empty($conf->banque->enabled) && (! empty($conf->facture->enabled) || ! empty($conf->global->MAIN_MENU_CHEQUE_DEPOSIT_ON))',2,'2017-08-30 15:14:30'),(162801,'auguria',1,'','left','accountancy',162787,NULL,NULL,8,'/compta/facture/stats/index.php?leftmenu=customers_bills','','Statistics',NULL,'bills',1,'','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162807,'auguria',1,'','left','accountancy',162792,NULL,NULL,1,'/compta/facture/list.php?leftmenu=customers_bills&search_status=0','','BillShortStatusDraft',NULL,'bills',2,'','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162808,'auguria',1,'','left','accountancy',162792,NULL,NULL,2,'/compta/facture/list.php?leftmenu=customers_bills&search_status=1','','BillShortStatusNotPaid',NULL,'bills',2,'','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162809,'auguria',1,'','left','accountancy',162792,NULL,NULL,3,'/compta/facture/list.php?leftmenu=customers_bills&search_status=2','','BillShortStatusPaid',NULL,'bills',2,'','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162810,'auguria',1,'','left','accountancy',162792,NULL,NULL,4,'/compta/facture/list.php?leftmenu=customers_bills&search_status=3','','BillShortStatusCanceled',NULL,'bills',2,'','$user->rights->facture->lire','$conf->facture->enabled',2,'2017-08-30 15:14:30'),(162987,'auguria',1,'','left','accountancy',161093,NULL,NULL,3,'/commande/list.php?leftmenu=orders&search_status=3','','MenuOrdersToBill',NULL,'orders',0,'orders','$user->rights->commande->lire','$conf->commande->enabled',0,'2017-08-30 15:14:30'),(163087,'auguria',1,'','left','accountancy',161093,NULL,NULL,4,'/don/index.php?leftmenu=donations&mainmenu=accountancy','','Donations',NULL,'donations',0,'donations','$user->rights->don->lire','$conf->don->enabled',2,'2017-08-30 15:14:30'),(163088,'auguria',1,'','left','accountancy',163087,NULL,NULL,0,'/don/card.php?leftmenu=donations&mainmenu=accountancy&action=create','','NewDonation',NULL,'donations',1,'','$user->rights->don->creer','$conf->don->enabled && $leftmenu==\"donations\"',2,'2017-08-30 15:14:30'),(163089,'auguria',1,'','left','accountancy',163087,NULL,NULL,1,'/don/list.php?leftmenu=donations&mainmenu=accountancy','','List',NULL,'donations',1,'','$user->rights->don->lire','$conf->don->enabled && $leftmenu==\"donations\"',2,'2017-08-30 15:14:30'),(163187,'auguria',1,'','left','accountancy',161102,NULL,NULL,5,'/compta/deplacement/index.php?leftmenu=tripsandexpenses','','TripsAndExpenses',NULL,'trips',0,'tripsandexpenses','$user->rights->deplacement->lire','$conf->deplacement->enabled',0,'2017-08-30 15:14:30'),(163188,'auguria',1,'','left','accountancy',163187,NULL,NULL,1,'/compta/deplacement/card.php?action=create&leftmenu=tripsandexpenses','','New',NULL,'trips',1,'','$user->rights->deplacement->creer','$conf->deplacement->enabled',0,'2017-08-30 15:14:30'),(163189,'auguria',1,'','left','accountancy',163187,NULL,NULL,2,'/compta/deplacement/list.php?leftmenu=tripsandexpenses','','List',NULL,'trips',1,'','$user->rights->deplacement->lire','$conf->deplacement->enabled',0,'2017-08-30 15:14:30'),(163190,'auguria',1,'','left','accountancy',163187,NULL,NULL,2,'/compta/deplacement/stats/index.php?leftmenu=tripsandexpenses','','Statistics',NULL,'trips',1,'','$user->rights->deplacement->lire','$conf->deplacement->enabled',0,'2017-08-30 15:14:30'),(163287,'auguria',1,'','left','accountancy',161093,NULL,NULL,6,'/compta/charges/index.php?leftmenu=tax&mainmenu=accountancy','','MenuSpecialExpenses',NULL,'compta',0,'tax','(! empty($conf->tax->enabled) && $user->rights->tax->charges->lire) || (! empty($conf->salaries->enabled) && $user->rights->salaries->read)','$conf->tax->enabled || $conf->salaries->enabled',0,'2017-08-30 15:14:30'),(163297,'auguria',1,'','left','accountancy',163287,NULL,NULL,1,'/compta/salaries/index.php?leftmenu=tax_salary&mainmenu=accountancy','','Salaries',NULL,'salaries',1,'tax_sal','$user->rights->salaries->payment->read','$conf->salaries->enabled',0,'2017-08-30 15:14:30'),(163298,'auguria',1,'','left','accountancy',163297,NULL,NULL,2,'/compta/salaries/card.php?leftmenu=tax_salary&action=create','','NewPayment',NULL,'companies',2,'','$user->rights->salaries->payment->write','$conf->salaries->enabled && $leftmenu==\"tax_salary\"',0,'2017-08-30 15:14:30'),(163299,'auguria',1,'','left','accountancy',163297,NULL,NULL,3,'/compta/salaries/index.php?leftmenu=tax_salary','','Payments',NULL,'companies',2,'','$user->rights->salaries->payment->read','$conf->salaries->enabled && $leftmenu==\"tax_salary\"',0,'2017-08-30 15:14:30'),(163307,'auguria',1,'','left','accountancy',163287,NULL,NULL,1,'/loan/index.php?leftmenu=tax_loan&mainmenu=accountancy','','Loans',NULL,'loan',1,'tax_loan','$user->rights->loan->read','$conf->loan->enabled',0,'2017-08-30 15:14:30'),(163308,'auguria',1,'','left','accountancy',163307,NULL,NULL,2,'/loan/card.php?leftmenu=tax_loan&action=create','','NewLoan',NULL,'loan',2,'','$user->rights->loan->write','$conf->loan->enabled && $leftmenu==\"tax_loan\"',0,'2017-08-30 15:14:30'),(163310,'auguria',1,'','left','accountancy',163307,NULL,NULL,4,'/loan/calc.php?leftmenu=tax_loan','','Calculator',NULL,'companies',2,'','$user->rights->loan->calc','$conf->loan->enabled && $leftmenu==\"tax_loan\" && ! empty($conf->global->LOAN_SHOW_CALCULATOR)',0,'2017-08-30 15:14:30'),(163337,'auguria',1,'','left','accountancy',163287,NULL,NULL,1,'/compta/sociales/index.php?leftmenu=tax_social','','SocialContributions',NULL,'',1,'tax_social','$user->rights->tax->charges->lire','$conf->tax->enabled',0,'2017-08-30 15:14:30'),(163338,'auguria',1,'','left','accountancy',163337,NULL,NULL,2,'/compta/sociales/card.php?leftmenu=tax_social&action=create','','MenuNewSocialContribution',NULL,'',2,'','$user->rights->tax->charges->creer','$conf->tax->enabled && $leftmenu==\"tax_social\"',0,'2017-08-30 15:14:30'),(163339,'auguria',1,'','left','accountancy',163337,NULL,NULL,3,'/compta/sociales/payments.php?leftmenu=tax_social&mainmenu=accountancy&mode=sconly','','Payments',NULL,'',2,'','$user->rights->tax->charges->lire','$conf->tax->enabled && $leftmenu==\"tax_social\"',0,'2017-08-30 15:14:30'),(163387,'auguria',1,'','left','accountancy',163287,NULL,NULL,7,'/compta/tva/index.php?leftmenu=tax_vat&mainmenu=accountancy','','VAT',NULL,'companies',1,'tax_vat','$user->rights->tax->charges->lire','$conf->tax->enabled && empty($conf->global->TAX_DISABLE_VAT_MENUS)',0,'2017-08-30 15:14:30'),(163388,'auguria',1,'','left','accountancy',163387,NULL,NULL,0,'/compta/tva/card.php?leftmenu=tax_vat&action=create','','New',NULL,'companies',2,'','$user->rights->tax->charges->creer','$conf->tax->enabled && empty($conf->global->TAX_DISABLE_VAT_MENUS) && $leftmenu==\"tax_vat\"',0,'2017-08-30 15:14:30'),(163389,'auguria',1,'','left','accountancy',163387,NULL,NULL,1,'/compta/tva/reglement.php?leftmenu=tax_vat','','List',NULL,'companies',2,'','$user->rights->tax->charges->lire','$conf->tax->enabled && empty($conf->global->TAX_DISABLE_VAT_MENUS) && $leftmenu==\"tax_vat\"',0,'2017-08-30 15:14:30'),(163390,'auguria',1,'','left','accountancy',163387,NULL,NULL,2,'/compta/tva/clients.php?leftmenu=tax_vat','','ReportByCustomers',NULL,'companies',2,'','$user->rights->tax->charges->lire','$conf->tax->enabled && empty($conf->global->TAX_DISABLE_VAT_MENUS) && $leftmenu==\"tax_vat\"',0,'2017-08-30 15:14:30'),(163391,'auguria',1,'','left','accountancy',163387,NULL,NULL,3,'/compta/tva/quadri_detail.php?leftmenu=tax_vat','','ReportByQuarter',NULL,'companies',2,'','$user->rights->tax->charges->lire','$conf->tax->enabled && empty($conf->global->TAX_DISABLE_VAT_MENUS) && $leftmenu==\"tax_vat\"',0,'2017-08-30 15:14:30'),(163487,'auguria',1,'','left','accountancy',161093,NULL,NULL,7,'/accountancy/index.php?leftmenu=accountancy','','MenuAccountancy',NULL,'accountancy',0,'accounting','! empty($conf->accounting->enabled) || $user->rights->accounting->bind->write || $user->rights->accounting->bind->write || $user->rights->compta->resultat->lire','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163488,'auguria',1,'','left','accountancy',163487,NULL,NULL,2,'/accountancy/customer/index.php?leftmenu=dispatch_customer','','CustomersVentilation',NULL,'accountancy',1,'dispatch_customer','$user->rights->accounting->bind->write','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163489,'auguria',1,'','left','accountancy',163488,NULL,NULL,3,'/accountancy/customer/list.php','','ToDispatch',NULL,'accountancy',2,'','$user->rights->accounting->bind->write','$conf->accounting->enabled && $leftmenu==\"dispatch_customer\"',0,'2017-08-30 15:14:30'),(163490,'auguria',1,'','left','accountancy',163488,NULL,NULL,4,'/accountancy/customer/lines.php','','Dispatched',NULL,'accountancy',2,'','$user->rights->accounting->bind->write','$conf->accounting->enabled && $leftmenu==\"dispatch_customer\"',0,'2017-08-30 15:14:30'),(163497,'auguria',1,'','left','accountancy',163487,NULL,NULL,5,'/accountancy/supplier/index.php?leftmenu=dispatch_supplier','','SuppliersVentilation',NULL,'accountancy',1,'ventil_supplier','$user->rights->accounting->bind->write','$conf->accounting->enabled && $conf->fournisseur->enabled',0,'2017-08-30 15:14:30'),(163498,'auguria',1,'','left','accountancy',163497,NULL,NULL,6,'/accountancy/supplier/list.php','','ToDispatch',NULL,'accountancy',2,'','$user->rights->accounting->bind->write','$conf->accounting->enabled && $conf->fournisseur->enabled && $leftmenu==\"dispatch_supplier\"',0,'2017-08-30 15:14:30'),(163499,'auguria',1,'','left','accountancy',163497,NULL,NULL,7,'/accountancy/supplier/lines.php','','Dispatched',NULL,'accountancy',2,'','$user->rights->accounting->bind->write','$conf->accounting->enabled && $conf->fournisseur->enabled && $leftmenu==\"dispatch_supplier\"',0,'2017-08-30 15:14:30'),(163507,'auguria',1,'','left','accountancy',163487,NULL,NULL,5,'/accountancy/expensereport/index.php?leftmenu=dispatch_expensereport','','ExpenseReportsVentilation',NULL,'accountancy',1,'ventil_expensereport','$user->rights->accounting->bind->write','$conf->accounting->enabled && $conf->expensereport->enabled',0,'2017-08-30 15:14:30'),(163508,'auguria',1,'','left','accountancy',163507,NULL,NULL,6,'/accountancy/expensereport/list.php','','ToDispatch',NULL,'accountancy',2,'','$user->rights->accounting->bind->write','$conf->accounting->enabled && $conf->expensereport->enabled && $leftmenu==\"dispatch_expensereport\"',0,'2017-08-30 15:14:30'),(163509,'auguria',1,'','left','accountancy',163507,NULL,NULL,7,'/accountancy/expensereport/lines.php','','Dispatched',NULL,'accountancy',2,'','$user->rights->accounting->bind->write','$conf->accounting->enabled && $conf->expensereport->enabled && $leftmenu==\"dispatch_expensereport\"',0,'2017-08-30 15:14:30'),(163517,'auguria',1,'','left','accountancy',163487,NULL,NULL,15,'/accountancy/bookkeeping/list.php','','Bookkeeping',NULL,'accountancy',1,'bookkeeping','$user->rights->accounting->mouvements->lire','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163522,'auguria',1,'','left','accountancy',163487,NULL,NULL,16,'/accountancy/bookkeeping/balance.php','','AccountBalance',NULL,'accountancy',1,'balance','$user->rights->accounting->mouvements->lire','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163527,'auguria',1,'','left','accountancy',163487,NULL,NULL,17,'/accountancy/report/result.php?mainmenu=accountancy&leftmenu=accountancy','','Reportings',NULL,'main',1,'report','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163528,'auguria',1,'','left','accountancy',163527,NULL,NULL,19,'/compta/resultat/index.php?mainmenu=accountancy&leftmenu=accountancy','','ReportInOut',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled && $leftmenu==\"accountancy\"',0,'2017-08-30 15:14:30'),(163529,'auguria',1,'','left','accountancy',163528,NULL,NULL,18,'/accountancy/report/result.php?mainmenu=accountancy&leftmenu=accountancy','','ByAccounts',NULL,'main',3,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled && $leftmenu==\"accountancy\"',0,'2017-08-30 15:14:30'),(163530,'auguria',1,'','left','accountancy',163528,NULL,NULL,20,'/compta/resultat/clientfourn.php?mainmenu=accountancy&leftmenu=accountancy','','ByCompanies',NULL,'main',3,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled && $leftmenu==\"accountancy\"',0,'2017-08-30 15:14:30'),(163531,'auguria',1,'','left','accountancy',163527,NULL,NULL,21,'/compta/stats/index.php?mainmenu=accountancy&leftmenu=accountancy','','ReportTurnover',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled && $leftmenu==\"accountancy\"',0,'2017-08-30 15:14:30'),(163532,'auguria',1,'','left','accountancy',163531,NULL,NULL,22,'/compta/stats/casoc.php?mainmenu=accountancy&leftmenu=accountancy','','ByCompanies',NULL,'main',3,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled && $leftmenu==\"accountancy\"',0,'2017-08-30 15:14:30'),(163533,'auguria',1,'','left','accountancy',163531,NULL,NULL,23,'/compta/stats/cabyuser.php?mainmenu=accountancy&leftmenu=accountancy','','ByUsers',NULL,'main',3,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled && $leftmenu==\"accountancy\"',0,'2017-08-30 15:14:30'),(163534,'auguria',1,'','left','accountancy',163531,NULL,NULL,24,'/compta/stats/cabyprodserv.php?mainmenu=accountancy&leftmenu=accountancy','','ByProductsAndServices',NULL,'main',3,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled && $leftmenu==\"accountancy\"',0,'2017-08-30 15:14:30'),(163537,'auguria',1,'','left','accountancy',163538,NULL,NULL,80,'/accountancy/admin/fiscalyear.php?mainmenu=accountancy&leftmenu=accountancy_admin','','FiscalPeriod',NULL,'admin',1,'accountancy_admin_period','','$conf->accounting->enabled && $leftmenu==\"accountancy_admin\" && $conf->global->MAIN_FEATURES_LEVEL > 0',2,'2017-08-30 15:14:30'),(163538,'auguria',1,'','left','accountancy',163487,NULL,NULL,1,'/accountancy/index.php?mainmenu=accountancy&leftmenu=accountancy_admin','','Setup',NULL,'accountancy',1,'accountancy_admin','$user->rights->accounting->chartofaccount','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163541,'auguria',1,'','left','accountancy',163538,NULL,NULL,10,'/accountancy/admin/journals_list.php?id=35&mainmenu=accountancy&leftmenu=accountancy_admin','','AccountingJournals',NULL,'accountancy',2,'accountancy_admin_journal','$user->rights->accounting->chartofaccount','$conf->accounting->enabled && $leftmenu==\"accountancy_admin\"',0,'2017-08-30 15:14:30'),(163542,'auguria',1,'','left','accountancy',163538,NULL,NULL,20,'/accountancy/admin/account.php?mainmenu=accountancy&leftmenu=accountancy_admin','','Pcg_version',NULL,'accountancy',2,'accountancy_admin_chartmodel','$user->rights->accounting->chartofaccount','$conf->accounting->enabled && $leftmenu==\"accountancy_admin\"',0,'2017-08-30 15:14:30'),(163543,'auguria',1,'','left','accountancy',163538,NULL,NULL,30,'/accountancy/admin/account.php?mainmenu=accountancy&leftmenu=accountancy_admin','','Chartofaccounts',NULL,'accountancy',2,'accountancy_admin_chart','$user->rights->accounting->chartofaccount','$conf->accounting->enabled && $leftmenu==\"accountancy_admin\"',0,'2017-08-30 15:14:30'),(163544,'auguria',1,'','left','accountancy',163538,NULL,NULL,40,'/accountancy/admin/categories_list.php?id=32&mainmenu=accountancy&leftmenu=accountancy_admin','','AccountingCategory',NULL,'accountancy',2,'accountancy_admin_chart_group','$user->rights->accounting->chartofaccount','$conf->accounting->enabled && $leftmenu==\"accountancy_admin\"',0,'2017-08-30 15:14:30'),(163545,'auguria',1,'','left','accountancy',163538,NULL,NULL,50,'/accountancy/admin/defaultaccounts.php?mainmenu=accountancy&leftmenu=accountancy_admin','','MenuDefaultAccounts',NULL,'accountancy',2,'accountancy_admin_default','$user->rights->accounting->chartofaccount','$conf->accounting->enabled && $leftmenu==\"accountancy_admin\"',0,'2017-08-30 15:14:30'),(163546,'auguria',1,'','left','accountancy',163538,NULL,NULL,60,'/admin/dict.php?id=10&from=accountancy&search_country_id=__MYCOUNTRYID__&mainmenu=accountancy&leftmenu=accountancy_admin','','MenuVatAccounts',NULL,'accountancy',2,'accountancy_admin_vat','$user->rights->accounting->chartofaccount','$conf->accounting->enabled && $leftmenu==\"accountancy_admin\"',0,'2017-08-30 15:14:30'),(163547,'auguria',1,'','left','accountancy',163538,NULL,NULL,70,'/admin/dict.php?id=7&from=accountancy&search_country_id=__MYCOUNTRYID__&mainmenu=accountancy&leftmenu=accountancy_admin','','MenuTaxAccounts',NULL,'accountancy',2,'accountancy_admin_tax','$user->rights->accounting->chartofaccount','$conf->accounting->enabled && $leftmenu==\"accountancy_admin\"',0,'2017-08-30 15:14:30'),(163548,'auguria',1,'','left','accountancy',163538,NULL,NULL,80,'/admin/dict.php?id=17&from=accountancy&mainmenu=accountancy&leftmenu=accountancy_admin','','MenuExpenseReportAccounts',NULL,'accountancy',2,'accountancy_admin_expensereport','$user->rights->accounting->chartofaccount','$conf->accounting->enabled && $conf->expensereport->enabled && $leftmenu==\"accountancy_admin\"',0,'2017-08-30 15:14:30'),(163549,'auguria',1,'','left','accountancy',163538,NULL,NULL,90,'/accountancy/admin/productaccount.php?mainmenu=accountancy&leftmenu=accountancy_admin','','MenuProductsAccounts',NULL,'accountancy',2,'accountancy_admin_product','$user->rights->accounting->chartofaccount','$conf->accounting->enabled && $leftmenu==\"accountancy_admin\"',0,'2017-08-30 15:14:30'),(163587,'auguria',1,'','left','accountancy',161101,NULL,NULL,9,'/compta/prelevement/index.php?leftmenu=withdraw&mainmenu=bank','','StandingOrders',NULL,'withdrawals',0,'withdraw','$user->rights->prelevement->bons->lire','$conf->prelevement->enabled',2,'2017-08-30 15:14:30'),(163589,'auguria',1,'','left','accountancy',163587,NULL,NULL,0,'/compta/prelevement/create.php?leftmenu=withdraw','','NewStandingOrder',NULL,'withdrawals',1,'','$user->rights->prelevement->bons->lire','$conf->prelevement->enabled && $leftmenu==\"withdraw\"',2,'2017-08-30 15:14:30'),(163590,'auguria',1,'','left','accountancy',163587,NULL,NULL,2,'/compta/prelevement/bons.php?leftmenu=withdraw','','WithdrawalsReceipts',NULL,'withdrawals',1,'','$user->rights->prelevement->bons->lire','$conf->prelevement->enabled && $leftmenu==\"withdraw\"',2,'2017-08-30 15:14:30'),(163591,'auguria',1,'','left','accountancy',163587,NULL,NULL,3,'/compta/prelevement/list.php?leftmenu=withdraw','','WithdrawalsLines',NULL,'withdrawals',1,'','$user->rights->prelevement->bons->lire','$conf->prelevement->enabled && $leftmenu==\"withdraw\"',2,'2017-08-30 15:14:30'),(163593,'auguria',1,'','left','accountancy',163587,NULL,NULL,5,'/compta/prelevement/rejets.php?leftmenu=withdraw','','Rejects',NULL,'withdrawals',1,'','$user->rights->prelevement->bons->lire','$conf->prelevement->enabled && $leftmenu==\"withdraw\"',2,'2017-08-30 15:14:30'),(163594,'auguria',1,'','left','accountancy',163587,NULL,NULL,6,'/compta/prelevement/stats.php?leftmenu=withdraw','','Statistics',NULL,'withdrawals',1,'','$user->rights->prelevement->bons->lire','$conf->prelevement->enabled && $leftmenu==\"withdraw\"',2,'2017-08-30 15:14:30'),(163687,'auguria',1,'','left','accountancy',161101,NULL,NULL,1,'/compta/bank/index.php?leftmenu=bank&mainmenu=bank','','MenuBankCash',NULL,'banks',0,'bank','$user->rights->banque->lire','$conf->banque->enabled',0,'2017-08-30 15:14:30'),(163688,'auguria',1,'','left','accountancy',163687,NULL,NULL,0,'/compta/bank/card.php?action=create&leftmenu=bank','','MenuNewFinancialAccount',NULL,'banks',1,'','$user->rights->banque->configurer','$conf->banque->enabled && ($leftmenu==\"bank\" || $leftmenu==\"checks\" || $leftmenu==\"withdraw\")',0,'2017-08-30 15:14:30'),(163690,'auguria',1,'','left','accountancy',163687,NULL,NULL,2,'/compta/bank/bankentries.php?leftmenu=bank','','ListTransactions',NULL,'banks',1,'','$user->rights->banque->lire','$conf->banque->enabled && ($leftmenu==\"bank\" || $leftmenu==\"checks\" || $leftmenu==\"withdraw\")',0,'2017-08-30 15:14:30'),(163691,'auguria',1,'','left','accountancy',163687,NULL,NULL,3,'/compta/bank/budget.php?leftmenu=bank','','ListTransactionsByCategory',NULL,'banks',1,'','$user->rights->banque->lire','$conf->banque->enabled && ($leftmenu==\"bank\" || $leftmenu==\"checks\" || $leftmenu==\"withdraw\")',0,'2017-08-30 15:14:30'),(163693,'auguria',1,'','left','accountancy',163687,NULL,NULL,5,'/compta/bank/transfer.php?leftmenu=bank','','BankTransfers',NULL,'banks',1,'','$user->rights->banque->transfer','$conf->banque->enabled && ($leftmenu==\"bank\" || $leftmenu==\"checks\" || $leftmenu==\"withdraw\")',0,'2017-08-30 15:14:30'),(163737,'auguria',1,'','left','accountancy',161101,NULL,NULL,4,'/categories/index.php?leftmenu=bank&type=5','','Categories',NULL,'categories',0,'cat','$user->rights->categorie->lire','$conf->categorie->enabled',2,'2017-08-30 15:14:30'),(163738,'auguria',1,'','left','accountancy',163737,NULL,NULL,0,'/categories/card.php?leftmenu=bank&action=create&type=5','','NewCategory',NULL,'categories',1,'','$user->rights->categorie->creer','$conf->categorie->enabled',2,'2017-08-30 15:14:30'),(163787,'auguria',1,'','left','accountancy',161093,NULL,NULL,11,'/compta/resultat/index.php?leftmenu=ca&mainmenu=accountancy','','Reportings',NULL,'main',0,'ca','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->comptabilite->enabled',0,'2017-08-30 15:14:30'),(163792,'auguria',1,'','left','accountancy',163487,NULL,NULL,1,'','','Journalization',NULL,'main',1,'','$user->rights->accounting->comptarapport->lire','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163793,'auguria',1,'','left','accountancy',163792,NULL,NULL,4,'/accountancy/journal/sellsjournal.php?mainmenu=accountancy&leftmenu=accountancy_journal&id_journal=1','','SellsJournal',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163794,'auguria',1,'','left','accountancy',163792,NULL,NULL,1,'/accountancy/journal/bankjournal.php?mainmenu=accountancy&leftmenu=accountancy_journal&id_journal=3','','BankJournal',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163795,'auguria',1,'','left','accountancy',163792,NULL,NULL,2,'/accountancy/journal/expensereportsjournal.php?mainmenu=accountancy&leftmenu=accountancy_journal&id_journal=6','','ExpenseReportJournal',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163796,'auguria',1,'','left','accountancy',163792,NULL,NULL,3,'/accountancy/journal/purchasesjournal.php?mainmenu=accountancy&leftmenu=accountancy_journal&id_journal=2','','PurchasesJournal',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->accounting->enabled',0,'2017-08-30 15:14:30'),(163798,'auguria',1,'','left','accountancy',163787,NULL,NULL,0,'/compta/resultat/index.php?leftmenu=ca','','ReportInOut',NULL,'main',1,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->comptabilite->enabled && $leftmenu==\"ca\"',0,'2017-08-30 15:14:30'),(163799,'auguria',1,'','left','accountancy',163788,NULL,NULL,0,'/compta/resultat/clientfourn.php?leftmenu=ca','','ByCompanies',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->comptabilite->enabled && $leftmenu==\"ca\"',0,'2017-08-30 15:14:30'),(163800,'auguria',1,'','left','accountancy',163787,NULL,NULL,1,'/compta/stats/index.php?leftmenu=ca','','ReportTurnover',NULL,'main',1,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->comptabilite->enabled && $leftmenu==\"ca\"',0,'2017-08-30 15:14:30'),(163801,'auguria',1,'','left','accountancy',163790,NULL,NULL,0,'/compta/stats/casoc.php?leftmenu=ca','','ByCompanies',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->comptabilite->enabled && $leftmenu==\"ca\"',0,'2017-08-30 15:14:30'),(163802,'auguria',1,'','left','accountancy',163790,NULL,NULL,1,'/compta/stats/cabyuser.php?leftmenu=ca','','ByUsers',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->comptabilite->enabled && $leftmenu==\"ca\"',0,'2017-08-30 15:14:30'),(163803,'auguria',1,'','left','accountancy',163790,NULL,NULL,1,'/compta/stats/cabyprodserv.php?leftmenu=ca','','ByProductsAndServices',NULL,'main',2,'','$user->rights->compta->resultat->lire || $user->rights->accounting->comptarapport->lire','$conf->comptabilite->enabled && $leftmenu==\"ca\"',0,'2017-08-30 15:14:30'),(163887,'auguria',1,'','left','products',161090,NULL,NULL,0,'/product/index.php?leftmenu=product&type=0','','Products',NULL,'products',0,'product','$user->rights->produit->lire','$conf->product->enabled',2,'2017-08-30 15:14:30'),(163888,'auguria',1,'','left','products',163887,NULL,NULL,0,'/product/card.php?leftmenu=product&action=create&type=0','','NewProduct',NULL,'products',1,'','$user->rights->produit->creer','$conf->product->enabled',2,'2017-08-30 15:14:30'),(163889,'auguria',1,'','left','products',163887,NULL,NULL,1,'/product/list.php?leftmenu=product&type=0','','List',NULL,'products',1,'','$user->rights->produit->lire','$conf->product->enabled',2,'2017-08-30 15:14:30'),(163890,'auguria',1,'','left','products',163887,NULL,NULL,4,'/product/reassort.php?type=0','','Stocks',NULL,'products',1,'','$user->rights->produit->lire && $user->rights->stock->lire','$conf->product->enabled',2,'2017-08-30 15:14:30'),(163891,'auguria',1,'','left','products',163887,NULL,NULL,7,'/product/stats/card.php?id=all&leftmenu=stats&type=0','','Statistics',NULL,'main',1,'','$user->rights->produit->lire','$conf->propal->enabled',2,'2017-08-30 15:14:30'),(163892,'auguria',1,'','left','products',163887,NULL,NULL,5,'/product/reassortlot.php?type=0','','StocksByLotSerial',NULL,'products',1,'','$user->rights->produit->lire && $user->rights->stock->lire','$conf->productbatch->enabled',2,'2017-08-30 15:14:30'),(163893,'auguria',1,'','left','products',163887,NULL,NULL,6,'/product/stock/productlot_list.php','','LotSerial',NULL,'products',1,'','$user->rights->produit->lire && $user->rights->stock->lire','$conf->productbatch->enabled',2,'2017-08-30 15:14:30'),(163987,'auguria',1,'','left','products',161090,NULL,NULL,1,'/product/index.php?leftmenu=service&type=1','','Services',NULL,'products',0,'service','$user->rights->service->lire','$conf->service->enabled',2,'2017-08-30 15:14:30'),(163988,'auguria',1,'','left','products',163987,NULL,NULL,0,'/product/card.php?leftmenu=service&action=create&type=1','','NewService',NULL,'products',1,'','$user->rights->service->creer','$conf->service->enabled',2,'2017-08-30 15:14:30'),(163989,'auguria',1,'','left','products',163987,NULL,NULL,1,'/product/list.php?leftmenu=service&type=1','','List',NULL,'products',1,'','$user->rights->service->lire','$conf->service->enabled',2,'2017-08-30 15:14:30'),(163990,'auguria',1,'','left','products',163987,NULL,NULL,5,'/product/stats/card.php?id=all&leftmenu=stats&type=1','','Statistics',NULL,'main',1,'','$user->rights->service->lire','$conf->propal->enabled',2,'2017-08-30 15:14:30'),(164187,'auguria',1,'','left','products',161090,NULL,NULL,3,'/product/stock/index.php?leftmenu=stock','','Stock',NULL,'stocks',0,'stock','$user->rights->stock->lire','$conf->stock->enabled',2,'2017-08-30 15:14:30'),(164188,'auguria',1,'','left','products',164187,NULL,NULL,0,'/product/stock/card.php?action=create','','MenuNewWarehouse',NULL,'stocks',1,'','$user->rights->stock->creer','$conf->stock->enabled',2,'2017-08-30 15:14:30'),(164189,'auguria',1,'','left','products',164187,NULL,NULL,1,'/product/stock/list.php','','List',NULL,'stocks',1,'','$user->rights->stock->lire','$conf->stock->enabled',2,'2017-08-30 15:14:30'),(164191,'auguria',1,'','left','products',164187,NULL,NULL,3,'/product/stock/mouvement.php','','Movements',NULL,'stocks',1,'','$user->rights->stock->mouvement->lire','$conf->stock->enabled',2,'2017-08-30 15:14:30'),(164192,'auguria',1,'','left','products',164187,NULL,NULL,4,'/product/stock/replenish.php','','Replenishments',NULL,'stocks',1,'','$user->rights->stock->mouvement->creer && $user->rights->fournisseur->lire','$conf->stock->enabled && $conf->supplier_order->enabled',2,'2017-08-30 15:14:30'),(164193,'auguria',1,'','left','products',164187,NULL,NULL,5,'/product/stock/massstockmove.php','','MassStockTransferShort',NULL,'stocks',1,'','$user->rights->stock->mouvement->creer','$conf->stock->enabled',2,'2017-08-30 15:14:30'),(164287,'auguria',1,'','left','products',161090,NULL,NULL,4,'/categories/index.php?leftmenu=cat&type=0','','Categories',NULL,'categories',0,'cat','$user->rights->categorie->lire','$conf->categorie->enabled',2,'2017-08-30 15:14:30'),(164288,'auguria',1,'','left','products',164287,NULL,NULL,0,'/categories/card.php?action=create&type=0','','NewCategory',NULL,'categories',1,'','$user->rights->categorie->creer','$conf->categorie->enabled',2,'2017-08-30 15:14:30'),(164487,'auguria',1,'','left','project',161094,NULL,NULL,3,'/projet/activity/perweek.php?leftmenu=projects','','NewTimeSpent',NULL,'projects',0,'','$user->rights->projet->lire','$conf->projet->enabled && $conf->global->PROJECT_USE_TASKS',2,'2017-08-30 15:14:30'),(164687,'auguria',1,'','left','project',161094,NULL,NULL,0,'/projet/index.php?leftmenu=projects','','Projects',NULL,'projects',0,'projects','$user->rights->projet->lire','$conf->projet->enabled',2,'2017-08-30 15:14:30'),(164688,'auguria',1,'','left','project',164687,NULL,NULL,1,'/projet/card.php?leftmenu=projects&action=create','','NewProject',NULL,'projects',1,'','$user->rights->projet->creer','$conf->projet->enabled',2,'2017-08-30 15:14:30'),(164689,'auguria',1,'','left','project',164687,NULL,NULL,2,'/projet/list.php?leftmenu=projects','','List',NULL,'projects',1,'','$user->rights->projet->lire','$conf->projet->enabled',2,'2017-08-30 15:14:30'),(164690,'auguria',1,'','left','project',164687,NULL,NULL,3,'/projet/stats/index.php?leftmenu=projects','','Statistics',NULL,'projects',1,'','$user->rights->projet->lire','$conf->projet->enabled',2,'2017-08-30 15:14:30'),(164787,'auguria',1,'','left','project',161094,NULL,NULL,0,'/projet/activity/index.php?leftmenu=projects','','Activities',NULL,'projects',0,'','$user->rights->projet->lire','$conf->projet->enabled && $conf->global->PROJECT_USE_TASKS',2,'2017-08-30 15:14:30'),(164788,'auguria',1,'','left','project',164787,NULL,NULL,1,'/projet/tasks.php?leftmenu=projects&action=create','','NewTask',NULL,'projects',1,'','$user->rights->projet->creer','$conf->projet->enabled && $conf->global->PROJECT_USE_TASKS',2,'2017-08-30 15:14:30'),(164789,'auguria',1,'','left','project',164787,NULL,NULL,2,'/projet/tasks/list.php?leftmenu=projects','','List',NULL,'projects',1,'','$user->rights->projet->lire','$conf->projet->enabled && $conf->global->PROJECT_USE_TASKS',2,'2017-08-30 15:14:30'),(164791,'auguria',1,'','left','project',164787,NULL,NULL,4,'/projet/tasks/stats/index.php?leftmenu=projects','','Statistics',NULL,'projects',1,'','$user->rights->projet->lire','$conf->projet->enabled && $conf->global->PROJECT_USE_TASKS',2,'2017-08-30 15:14:30'),(164891,'auguria',1,'','left','project',161094,NULL,NULL,4,'/categories/index.php?leftmenu=cat&type=6','','Categories',NULL,'categories',0,'cat','$user->rights->categorie->lire','$conf->categorie->enabled',2,'2017-08-30 15:14:30'),(164892,'auguria',1,'','left','project',164891,NULL,NULL,0,'/categories/card.php?action=create&type=6','','NewCategory',NULL,'categories',1,'','$user->rights->categorie->creer','$conf->categorie->enabled',2,'2017-08-30 15:14:30'),(164987,'auguria',1,'','left','tools',161095,NULL,NULL,0,'/comm/mailing/index.php?leftmenu=mailing','','EMailings',NULL,'mails',0,'mailing','$user->rights->mailing->lire','$conf->mailing->enabled',0,'2017-08-30 15:14:30'),(164988,'auguria',1,'','left','tools',164987,NULL,NULL,0,'/comm/mailing/card.php?leftmenu=mailing&action=create','','NewMailing',NULL,'mails',1,'','$user->rights->mailing->creer','$conf->mailing->enabled',0,'2017-08-30 15:14:30'),(164989,'auguria',1,'','left','tools',164987,NULL,NULL,1,'/comm/mailing/list.php?leftmenu=mailing','','List',NULL,'mails',1,'','$user->rights->mailing->lire','$conf->mailing->enabled',0,'2017-08-30 15:14:30'),(165187,'auguria',1,'','left','tools',161095,NULL,NULL,2,'/exports/index.php?leftmenu=export','','FormatedExport',NULL,'exports',0,'export','$user->rights->export->lire','$conf->export->enabled',2,'2017-08-30 15:14:30'),(165188,'auguria',1,'','left','tools',165187,NULL,NULL,0,'/exports/export.php?leftmenu=export','','NewExport',NULL,'exports',1,'','$user->rights->export->creer','$conf->export->enabled',2,'2017-08-30 15:14:30'),(165217,'auguria',1,'','left','tools',161095,NULL,NULL,2,'/imports/index.php?leftmenu=import','','FormatedImport',NULL,'exports',0,'import','$user->rights->import->run','$conf->import->enabled',2,'2017-08-30 15:14:30'),(165218,'auguria',1,'','left','tools',165217,NULL,NULL,0,'/imports/import.php?leftmenu=import','','NewImport',NULL,'exports',1,'','$user->rights->import->run','$conf->import->enabled',2,'2017-08-30 15:14:30'),(165287,'auguria',1,'','left','members',161100,NULL,NULL,0,'/adherents/index.php?leftmenu=members&mainmenu=members','','Members',NULL,'members',0,'members','$user->rights->adherent->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165288,'auguria',1,'','left','members',165287,NULL,NULL,0,'/adherents/card.php?leftmenu=members&action=create','','NewMember',NULL,'members',1,'','$user->rights->adherent->creer','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165289,'auguria',1,'','left','members',165287,NULL,NULL,1,'/adherents/list.php','','List',NULL,'members',1,'','$user->rights->adherent->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165290,'auguria',1,'','left','members',165289,NULL,NULL,2,'/adherents/list.php?leftmenu=members&statut=-1','','MenuMembersToValidate',NULL,'members',2,'','$user->rights->adherent->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165291,'auguria',1,'','left','members',165289,NULL,NULL,3,'/adherents/list.php?leftmenu=members&statut=1','','MenuMembersValidated',NULL,'members',2,'','$user->rights->adherent->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165292,'auguria',1,'','left','members',165289,NULL,NULL,4,'/adherents/list.php?leftmenu=members&statut=1&filter=outofdate','','MenuMembersNotUpToDate',NULL,'members',2,'','$user->rights->adherent->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165293,'auguria',1,'','left','members',165289,NULL,NULL,5,'/adherents/list.php?leftmenu=members&statut=1&filter=uptodate','','MenuMembersUpToDate',NULL,'members',2,'','$user->rights->adherent->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165294,'auguria',1,'','left','members',165289,NULL,NULL,6,'/adherents/list.php?leftmenu=members&statut=0','','MenuMembersResiliated',NULL,'members',2,'','$user->rights->adherent->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165295,'auguria',1,'','left','members',165287,NULL,NULL,7,'/adherents/stats/geo.php?leftmenu=members&mode=memberbycountry','','MenuMembersStats',NULL,'members',1,'','$user->rights->adherent->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165387,'auguria',1,'','left','members',161100,NULL,NULL,1,'/adherents/index.php?leftmenu=members&mainmenu=members','','Subscriptions',NULL,'compta',0,'','$user->rights->adherent->cotisation->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165388,'auguria',1,'','left','members',165387,NULL,NULL,0,'/adherents/list.php?statut=-1&leftmenu=accountancy&mainmenu=members','','NewSubscription',NULL,'compta',1,'','$user->rights->adherent->cotisation->creer','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165389,'auguria',1,'','left','members',165387,NULL,NULL,1,'/adherents/subscription/list.php?leftmenu=members','','List',NULL,'compta',1,'','$user->rights->adherent->cotisation->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165390,'auguria',1,'','left','members',165387,NULL,NULL,7,'/adherents/stats/index.php?leftmenu=members','','MenuMembersStats',NULL,'members',1,'','$user->rights->adherent->lire','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165589,'auguria',1,'','left','members',165287,NULL,NULL,9,'/adherents/htpasswd.php?leftmenu=export','','Filehtpasswd',NULL,'members',1,'','$user->rights->adherent->export','! empty($conf->global->MEMBER_LINK_TO_HTPASSWDFILE) && $conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165590,'auguria',1,'','left','members',165287,NULL,NULL,10,'/adherents/cartes/carte.php?leftmenu=export','','MembersCards',NULL,'members',1,'','$user->rights->adherent->export','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165687,'auguria',1,'','left','hrm',161102,NULL,NULL,1,'/user/index.php?leftmenu=hrm&mode=employee','','Employees',NULL,'hrm',0,'hrm','$user->rights->hrm->employee->read','$conf->hrm->enabled',0,'2017-08-30 15:14:30'),(165688,'auguria',1,'','left','hrm',165687,NULL,NULL,1,'/user/card.php?action=create&employee=1','','NewEmployee',NULL,'hrm',1,'','$user->rights->hrm->employee->write','$conf->hrm->enabled',0,'2017-08-30 15:14:30'),(165689,'auguria',1,'','left','hrm',165687,NULL,NULL,2,'/user/index.php?$leftmenu=hrm&mode=employee&contextpage=employeelist','','List',NULL,'hrm',1,'','$user->rights->hrm->employee->read','$conf->hrm->enabled',0,'2017-08-30 15:14:30'),(165787,'auguria',1,'','left','members',161100,NULL,NULL,5,'/adherents/type.php?leftmenu=setup&mainmenu=members','','MembersTypes',NULL,'members',0,'setup','$user->rights->adherent->configurer','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165788,'auguria',1,'','left','members',165787,NULL,NULL,0,'/adherents/type.php?leftmenu=setup&mainmenu=members&action=create','','New',NULL,'members',1,'','$user->rights->adherent->configurer','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(165789,'auguria',1,'','left','members',165787,NULL,NULL,1,'/adherents/type.php?leftmenu=setup&mainmenu=members','','List',NULL,'members',1,'','$user->rights->adherent->configurer','$conf->adherent->enabled',2,'2017-08-30 15:14:30'),(166087,'auguria',1,'','left','hrm',161102,NULL,NULL,1,'/holiday/list.php?&leftmenu=hrm','','CPTitreMenu',NULL,'holiday',0,'hrm','$user->rights->holiday->read','$conf->holiday->enabled',0,'2017-08-30 15:14:30'),(166088,'auguria',1,'','left','hrm',166087,NULL,NULL,1,'/holiday/card.php?&action=request','','MenuAddCP',NULL,'holiday',1,'','$user->rights->holiday->write','$conf->holiday->enabled',0,'2017-08-30 15:14:30'),(166089,'auguria',1,'','left','hrm',166087,NULL,NULL,1,'/holiday/list.php?&leftmenu=hrm','','List',NULL,'holiday',1,'','$user->rights->holiday->read','$conf->holiday->enabled',0,'2017-08-30 15:14:30'),(166090,'auguria',1,'','left','hrm',166089,NULL,NULL,1,'/holiday/list.php?select_statut=2&leftmenu=hrm','','ListToApprove',NULL,'trips',2,'','$user->rights->holiday->read','$conf->holiday->enabled',0,'2017-08-30 15:14:30'),(166091,'auguria',1,'','left','hrm',166087,NULL,NULL,2,'/holiday/define_holiday.php?&action=request','','MenuConfCP',NULL,'holiday',1,'','$user->rights->holiday->define_holiday','$conf->holiday->enabled',0,'2017-08-30 15:14:30'),(166092,'auguria',1,'','left','hrm',166087,NULL,NULL,3,'/holiday/view_log.php?&action=request','','MenuLogCP',NULL,'holiday',1,'','$user->rights->holiday->define_holiday','$conf->holiday->enabled',0,'2017-08-30 15:14:30'),(166187,'auguria',1,'','left','commercial',161092,NULL,NULL,6,'/fourn/commande/index.php?leftmenu=orders_suppliers','','SuppliersOrders',NULL,'orders',0,'orders_suppliers','$user->rights->fournisseur->commande->lire','$conf->supplier_order->enabled',2,'2017-08-30 15:14:30'),(166188,'auguria',1,'','left','commercial',166187,NULL,NULL,0,'/fourn/commande/card.php?action=create&leftmenu=orders_suppliers','','NewOrder',NULL,'orders',1,'','$user->rights->fournisseur->commande->creer','$conf->supplier_order->enabled',2,'2017-08-30 15:14:30'),(166189,'auguria',1,'','left','commercial',166187,NULL,NULL,1,'/fourn/commande/list.php?leftmenu=orders_suppliers&search_status=0','','List',NULL,'orders',1,'','$user->rights->fournisseur->commande->lire','$conf->supplier_order->enabled',2,'2017-08-30 15:14:30'),(166195,'auguria',1,'','left','commercial',166187,NULL,NULL,7,'/commande/stats/index.php?leftmenu=orders_suppliers&mode=supplier','','Statistics',NULL,'orders',1,'','$user->rights->fournisseur->commande->lire','$conf->supplier_order->enabled',2,'2017-08-30 15:14:30'),(166287,'auguria',1,'','left','members',161100,NULL,NULL,3,'/categories/index.php?leftmenu=cat&type=3','','MembersCategoriesShort',NULL,'categories',0,'cat','$user->rights->categorie->lire','$conf->adherent->enabled && $conf->categorie->enabled',2,'2017-08-30 15:14:30'),(166288,'auguria',1,'','left','members',166287,NULL,NULL,0,'/categories/card.php?action=create&type=3','','NewCategory',NULL,'categories',1,'','$user->rights->categorie->creer','$conf->adherent->enabled && $conf->categorie->enabled',2,'2017-08-30 15:14:30'),(166387,'auguria',1,'','left','hrm',161102,NULL,NULL,5,'/expensereport/index.php?leftmenu=expensereport','','TripsAndExpenses',NULL,'trips',0,'expensereport','$user->rights->expensereport->lire','$conf->expensereport->enabled',0,'2017-08-30 15:14:30'),(166388,'auguria',1,'','left','hrm',166387,NULL,NULL,1,'/expensereport/card.php?action=create&leftmenu=expensereport','','New',NULL,'trips',1,'','$user->rights->expensereport->creer','$conf->expensereport->enabled',0,'2017-08-30 15:14:30'),(166389,'auguria',1,'','left','hrm',166387,NULL,NULL,2,'/expensereport/list.php?leftmenu=expensereport','','List',NULL,'trips',1,'','$user->rights->expensereport->lire','$conf->expensereport->enabled',0,'2017-08-30 15:14:30'),(166390,'auguria',1,'','left','hrm',166389,NULL,NULL,2,'/expensereport/list.php?search_status=2&leftmenu=expensereport','','ListToApprove',NULL,'trips',2,'','$user->rights->expensereport->approve','$conf->expensereport->enabled',0,'2017-08-30 15:14:30'),(166391,'auguria',1,'','left','hrm',166387,NULL,NULL,2,'/expensereport/stats/index.php?leftmenu=expensereport','','Statistics',NULL,'trips',1,'','$user->rights->expensereport->lire','$conf->expensereport->enabled',0,'2017-08-30 15:14:30'),(167134,'all',1,'agenda','top','agenda',0,NULL,NULL,86,'/comm/action/index.php','','TMenuAgenda','','agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2022-02-07 13:38:16'),(167135,'all',1,'agenda','left','agenda',167134,NULL,NULL,100,'/comm/action/index.php?mainmenu=agenda&leftmenu=agenda','','Actions','','agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2022-02-07 13:38:16'),(167136,'all',1,'agenda','left','agenda',167135,NULL,NULL,101,'/comm/action/card.php?mainmenu=agenda&leftmenu=agenda&action=create','','NewAction','','commercial',NULL,NULL,'($user->rights->agenda->myactions->create||$user->rights->agenda->allactions->create)','$conf->agenda->enabled',2,'2022-02-07 13:38:16'),(167137,'all',1,'agenda','left','agenda',167135,NULL,NULL,140,'/comm/action/index.php?action=default&mainmenu=agenda&leftmenu=agenda','','Calendar','','agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2022-02-07 13:38:16'),(167138,'all',1,'agenda','left','agenda',167137,NULL,NULL,141,'/comm/action/index.php?action=default&mainmenu=agenda&leftmenu=agenda&status=todo&filter=mine','','MenuToDoMyActions','','agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2022-02-07 13:38:16'),(167139,'all',1,'agenda','left','agenda',167137,NULL,NULL,142,'/comm/action/index.php?action=default&mainmenu=agenda&leftmenu=agenda&status=done&filter=mine','','MenuDoneMyActions','','agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2022-02-07 13:38:16'),(167140,'all',1,'agenda','left','agenda',167137,NULL,NULL,143,'/comm/action/index.php?action=default&mainmenu=agenda&leftmenu=agenda&status=todo&filtert=-1','','MenuToDoActions','','agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$user->rights->agenda->allactions->read',2,'2022-02-07 13:38:16'),(167141,'all',1,'agenda','left','agenda',167137,NULL,NULL,144,'/comm/action/index.php?action=default&mainmenu=agenda&leftmenu=agenda&status=done&filtert=-1','','MenuDoneActions','','agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$user->rights->agenda->allactions->read',2,'2022-02-07 13:38:16'),(167142,'all',1,'agenda','left','agenda',167135,NULL,NULL,110,'/comm/action/list.php?mode=show_list&mainmenu=agenda&leftmenu=agenda','','List','','agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2022-02-07 13:38:16'),(167143,'all',1,'agenda','left','agenda',167142,NULL,NULL,111,'/comm/action/list.php?mode=show_list&mainmenu=agenda&leftmenu=agenda&status=todo&filter=mine','','MenuToDoMyActions','','agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2022-02-07 13:38:16'),(167144,'all',1,'agenda','left','agenda',167142,NULL,NULL,112,'/comm/action/list.php?mode=show_list&mainmenu=agenda&leftmenu=agenda&status=done&filter=mine','','MenuDoneMyActions','','agenda',NULL,NULL,'$user->rights->agenda->myactions->read','$conf->agenda->enabled',2,'2022-02-07 13:38:16'),(167145,'all',1,'agenda','left','agenda',167142,NULL,NULL,113,'/comm/action/list.php?mode=show_list&mainmenu=agenda&leftmenu=agenda&status=todo&filtert=-1','','MenuToDoActions','','agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$user->rights->agenda->allactions->read',2,'2022-02-07 13:38:16'),(167146,'all',1,'agenda','left','agenda',167142,NULL,NULL,114,'/comm/action/list.php?mode=show_list&mainmenu=agenda&leftmenu=agenda&status=done&filtert=-1','','MenuDoneActions','','agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$user->rights->agenda->allactions->read',2,'2022-02-07 13:38:16'),(167147,'all',1,'agenda','left','agenda',167135,NULL,NULL,160,'/comm/action/rapport/index.php?mainmenu=agenda&leftmenu=agenda','','Reportings','','agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$conf->agenda->enabled',2,'2022-02-07 13:38:16'),(167148,'all',1,'agenda','left','agenda',167135,NULL,NULL,170,'/categories/index.php?mainmenu=agenda&leftmenu=agenda&type=10','','Categories','','agenda',NULL,NULL,'$user->rights->agenda->allactions->read','$conf->categorie->enabled',2,'2022-02-07 13:38:16'),(167149,'all',1,'barcode','left','tools',-1,NULL,'tools',200,'/barcode/printsheet.php?mainmenu=tools&leftmenu=barcodeprint','','BarCodePrintsheet','','products',NULL,'barcodeprint','($conf->global->MAIN_USE_ADVANCED_PERMS && $user->rights->barcode->lire_advance) || (! $conf->global->MAIN_USE_ADVANCED_PERMS)','$conf->barcode->enabled',0,'2022-02-07 13:38:17'),(167150,'all',1,'barcode','left','home',-1,'admintools','home',300,'/barcode/codeinit.php?mainmenu=home&leftmenu=admintools','','MassBarcodeInit','','products',NULL,NULL,'($conf->global->MAIN_USE_ADVANCED_PERMS && $user->rights->barcode->creer_advance) || (! $conf->global->MAIN_USE_ADVANCED_PERMS)','$conf->barcode->enabled && preg_match(\'/^(admintools|all)/\',$leftmenu)',0,'2022-02-07 13:38:17'),(167151,'all',1,'cron','left','home',-1,'admintools','home',200,'/cron/list.php?leftmenu=admintools','','CronList','','cron',NULL,NULL,'$user->rights->cron->read','$conf->cron->enabled && preg_match(\'/^(admintools|all)/\', $leftmenu)',2,'2022-02-07 13:38:17'),(167153,'all',1,'ecm','top','ecm',0,NULL,NULL,82,'/ecm/index.php','','MenuECM','','ecm',NULL,NULL,'$user->rights->ecm->read || $user->rights->ecm->upload || $user->rights->ecm->setup','$conf->ecm->enabled',2,'2022-02-07 13:38:17'),(167154,'all',1,'ecm','left','ecm',-1,NULL,'ecm',101,'/ecm/index.php?mainmenu=ecm&leftmenu=ecm','','ECMArea','','ecm',NULL,'ecm','$user->rights->ecm->read || $user->rights->ecm->upload','$user->rights->ecm->read || $user->rights->ecm->upload',2,'2022-02-07 13:38:17'),(167155,'all',1,'ecm','left','ecm',-1,'ecm','ecm',102,'/ecm/index.php?action=file_manager&mainmenu=ecm&leftmenu=ecm','','ECMSectionsManual','','ecm',NULL,'ecm_manual','$user->rights->ecm->read || $user->rights->ecm->upload','$user->rights->ecm->read || $user->rights->ecm->upload',2,'2022-02-07 13:38:17'),(167156,'all',1,'ecm','left','ecm',-1,'ecm','ecm',103,'/ecm/index_auto.php?action=file_manager&mainmenu=ecm&leftmenu=ecm','','ECMSectionsAuto','','ecm',NULL,NULL,'$user->rights->ecm->read || $user->rights->ecm->upload','($user->rights->ecm->read || $user->rights->ecm->upload) && ! empty($conf->global->ECM_AUTO_TREE_ENABLED)',2,'2022-02-07 13:38:17'),(167157,'all',1,'margins','left','billing',-1,NULL,'billing',100,'/margin/index.php','','Margins','','margins',NULL,'margins','$user->rights->margins->liretous','$conf->margin->enabled',2,'2022-02-07 13:38:17'),(167158,'all',1,'opensurvey','left','tools',-1,NULL,'tools',200,'/opensurvey/index.php?mainmenu=tools&leftmenu=opensurvey','','Survey','','opensurvey',NULL,'opensurvey','$user->rights->opensurvey->read','$conf->opensurvey->enabled',0,'2022-02-07 13:38:17'),(167159,'all',1,'opensurvey','left','tools',-1,'opensurvey','tools',210,'/opensurvey/wizard/index.php','','NewSurvey','','opensurvey',NULL,'opensurvey_new','$user->rights->opensurvey->write','$conf->opensurvey->enabled',0,'2022-02-07 13:38:17'),(167160,'all',1,'opensurvey','left','tools',-1,'opensurvey','tools',220,'/opensurvey/list.php','','List','','opensurvey',NULL,'opensurvey_list','$user->rights->opensurvey->read','$conf->opensurvey->enabled',0,'2022-02-07 13:38:17'),(167161,'all',1,'printing','left','home',-1,'admintools','home',300,'/printing/index.php?mainmenu=home&leftmenu=admintools','','MenuDirectPrinting','','printing',NULL,NULL,'$user->rights->printing->read','$conf->printing->enabled && preg_match(\'/^(admintools|all)/\', $leftmenu)',0,'2022-02-07 13:38:17'),(167162,'all',1,'recruitment','left','hrm',-1,NULL,'hrm',1001,'/recruitment/recruitmentindex.php','','Recruitment','','recruitment',NULL,'recruitmentjobposition','$user->rights->recruitment->recruitmentjobposition->read','$conf->recruitment->enabled',2,'2022-02-07 13:38:18'),(167163,'all',1,'recruitment','left','hrm',-1,'recruitmentjobposition','hrm',1002,'/recruitment/recruitmentjobposition_card.php?action=create','','NewPositionToBeFilled','','recruitment',NULL,'recruitment_recruitmentjobposition_new','$user->rights->recruitment->recruitmentjobposition->write','$conf->recruitment->enabled',2,'2022-02-07 13:38:18'),(167164,'all',1,'recruitment','left','hrm',-1,'recruitmentjobposition','hrm',1003,'/recruitment/recruitmentjobposition_list.php','','ListOfPositionsToBeFilled','','recruitment',NULL,'recruitment_recruitmentjobposition_list','$user->rights->recruitment->recruitmentjobposition->read','$conf->recruitment->enabled',2,'2022-02-07 13:38:18'),(167165,'all',1,'recruitment','left','hrm',-1,'recruitmentjobposition','hrm',1004,'/recruitment/recruitmentcandidature_card.php?action=create','','NewCandidature','','recruitment',NULL,'recruitment_recruitmentcandidature_new','$user->rights->recruitment->recruitmentjobposition->write','$conf->recruitment->enabled',2,'2022-02-07 13:38:18'),(167166,'all',1,'recruitment','left','hrm',-1,'recruitmentjobposition','hrm',1005,'/recruitment/recruitmentcandidature_list.php','','ListOfCandidatures','','recruitment',NULL,'recruitment_recruitmentcandidature_list','$user->rights->recruitment->recruitmentjobposition->read','$conf->recruitment->enabled',2,'2022-02-07 13:38:18'),(167167,'all',1,'resource','left','tools',-1,NULL,'tools',100,'/resource/list.php','','MenuResourceIndex','','resource',NULL,'resource','$user->rights->resource->read','1',0,'2022-02-07 13:38:18'),(167168,'all',1,'resource','left','tools',-1,'resource','tools',101,'/resource/card.php?action=create','','MenuResourceAdd','','resource',NULL,'resource_add','$user->rights->resource->write','1',0,'2022-02-07 13:38:18'),(167169,'all',1,'resource','left','tools',-1,'resource','tools',102,'/resource/list.php','','List','','resource',NULL,'resource_list','$user->rights->resource->read','1',0,'2022-02-07 13:38:18'),(167170,'all',1,'stripe','left','bank',-1,NULL,'bank',100,'','','StripeAccount','','stripe',NULL,'stripe','$user->rights->banque->lire','$conf->stripe->enabled && $conf->banque->enabled && $conf->global->MAIN_FEATURES_LEVEL >= 1',0,'2022-02-07 13:38:18'),(167171,'all',1,'stripe','left','bank',-1,'stripe','bank',102,'/stripe/charge.php','','StripeChargeList','','stripe',NULL,NULL,'$user->rights->banque->lire','$conf->stripe->enabled && $conf->banque->enabled && $conf->global->MAIN_FEATURES_LEVEL >= 1',0,'2022-02-07 13:38:18'),(167172,'all',1,'stripe','left','bank',-1,'stripe','bank',102,'/stripe/transaction.php','','StripeTransactionList','','stripe',NULL,NULL,'$user->rights->banque->lire','$conf->stripe->enabled && $conf->banque->enabled && $conf->global->MAIN_FEATURES_LEVEL >= 1',0,'2022-02-07 13:38:18'),(167173,'all',1,'stripe','left','bank',-1,'stripe','bank',103,'/stripe/payout.php','','StripePayoutList','','stripe',NULL,NULL,'$user->rights->banque->lire','$conf->stripe->enabled && $conf->banque->enabled && $conf->global->MAIN_FEATURES_LEVEL >= 1',0,'2022-02-07 13:38:18'),(167174,'all',1,'ticket','left','ticket',-1,NULL,'ticket',101,'/ticket/index.php','','Ticket','','ticket',NULL,'ticket','$user->rights->ticket->read','$conf->ticket->enabled',2,'2022-02-07 13:38:18'),(167175,'all',1,'ticket','left','ticket',-1,'ticket','ticket',102,'/ticket/card.php?action=create','','NewTicket','','ticket',NULL,NULL,'$user->rights->ticket->write','$conf->ticket->enabled',2,'2022-02-07 13:38:18'),(167176,'all',1,'ticket','left','ticket',-1,'ticket','ticket',103,'/ticket/list.php?search_fk_status=non_closed','','List','','ticket',NULL,'ticketlist','$user->rights->ticket->read','$conf->ticket->enabled',2,'2022-02-07 13:38:18'),(167177,'all',1,'ticket','left','ticket',-1,'ticket','ticket',105,'/ticket/list.php?mode=mine&search_fk_status=non_closed','','MenuTicketMyAssign','','ticket',NULL,'ticketmy','$user->rights->ticket->read','$conf->ticket->enabled',0,'2022-02-07 13:38:18'),(167178,'all',1,'ticket','left','ticket',-1,'ticket','ticket',107,'/ticket/stats/index.php','','Statistics','','ticket',NULL,NULL,'$user->rights->ticket->read','$conf->ticket->enabled',0,'2022-02-07 13:38:18'),(167179,'all',1,'ticket','left','ticket',-1,'ticket','ticket',107,'/categories/index.php?type=12','','Categories','','ticket',NULL,NULL,'$user->rights->ticket->read','$conf->categorie->enabled',0,'2022-02-07 13:38:18'),(167180,'all',1,'takepos','top','takepos',0,NULL,NULL,1001,'/takepos/index.php','takepos','PointOfSaleShort','','cashdesk',NULL,NULL,'$user->rights->takepos->run','$conf->takepos->enabled',2,'2022-02-07 13:38:18'),(167181,'all',1,'website','top','website',0,NULL,NULL,100,'/website/index.php','','WebSites','','website',NULL,NULL,'$user->rights->website->read','$conf->website->enabled',2,'2022-02-07 13:38:18'),(167182,'all',1,'knowledgemanagement','left','ticket',-1,NULL,'ticket',101,'/knowledgemanagement/knowledgerecord_list.php','','MenuKnowledgeRecord','','knowledgemanagement',NULL,'knowledgemanagement_knowledgerecord','$user->rights->knowledgemanagement->knowledgerecord->read','$conf->knowledgemanagement->enabled',2,'2022-02-07 13:39:27'),(167183,'all',1,'knowledgemanagement','left','ticket',-1,'knowledgemanagement_knowledgerecord','ticket',111,'/knowledgemanagement/knowledgerecord_list.php','','ListKnowledgeRecord','','knowledgemanagement',NULL,'knowledgemanagement_list','$user->rights->knowledgemanagement->knowledgerecord->read','$conf->knowledgemanagement->enabled',2,'2022-02-07 13:39:27'),(167184,'all',1,'knowledgemanagement','left','ticket',-1,'knowledgemanagement_knowledgerecord','ticket',110,'/knowledgemanagement/knowledgerecord_card.php?action=create','','NewKnowledgeRecord','','knowledgemanagement',NULL,'knowledgemanagement_new','$user->rights->knowledgemanagement->knowledgerecord->write','$conf->knowledgemanagement->enabled',2,'2022-02-07 13:39:27'),(167185,'all',1,'knowledgemanagement','left','ticket',-1,'knowledgemanagement_knowledgerecord','ticket',112,'/categories/index.php?type=13','','Categories','','knowledgemanagement',NULL,NULL,'$user->rights->knowledgemanagement->knowledgerecord->read','$conf->knowledgemanagement->enabled',0,'2022-02-07 13:39:27'),(167186,'all',1,'blockedlog','left','tools',-1,NULL,'tools',200,'/blockedlog/admin/blockedlog_list.php?mainmenu=tools&leftmenu=blockedlogbrowser','','BrowseBlockedLog','','blockedlog',NULL,'blockedlogbrowser','$user->rights->blockedlog->read','$conf->blockedlog->enabled',2,'2022-02-07 14:32:50'); /*!40000 ALTER TABLE `llx_menu` ENABLE KEYS */; UNLOCK TABLES; @@ -7977,6 +8386,8 @@ CREATE TABLE `llx_mrp_mo` ( `fk_project` int(11) DEFAULT NULL, `date_valid` datetime DEFAULT NULL, `fk_user_valid` int(11) DEFAULT NULL, + `last_main_doc` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `mrptype` int(11) DEFAULT 0, PRIMARY KEY (`rowid`), KEY `idx_mrp_mo_ref` (`ref`), KEY `idx_mrp_mo_entity` (`entity`), @@ -7998,7 +8409,7 @@ CREATE TABLE `llx_mrp_mo` ( LOCK TABLES `llx_mrp_mo` WRITE; /*!40000 ALTER TABLE `llx_mrp_mo` DISABLE KEYS */; -INSERT INTO `llx_mrp_mo` VALUES (5,'MO1912-0002',1,'Build 2 apple pies for CIO birthday',3,2,10,NULL,NULL,'2019-12-20 16:42:08','2020-01-13 11:29:30',12,12,NULL,NULL,3,4,NULL,NULL,6,7,'2019-12-20 20:32:09',12),(8,'MO1912-0001',1,NULL,1,NULL,NULL,NULL,NULL,'2019-12-20 17:01:21','2019-12-20 13:25:47',12,NULL,NULL,NULL,1,3,NULL,NULL,6,NULL,'2019-12-20 17:25:47',12),(14,'MO2001-0003',1,NULL,10,NULL,NULL,NULL,'Production very dangerous','2020-01-02 23:46:54','2020-01-06 02:48:22',12,12,NULL,NULL,2,4,NULL,NULL,6,NULL,'2020-01-02 23:57:42',12),(18,'MO2001-0004',1,NULL,2,2,NULL,NULL,NULL,'2020-01-03 13:34:34','2020-01-03 10:10:41',12,12,NULL,NULL,1,4,NULL,NULL,6,NULL,'2020-01-03 14:10:41',12),(22,'(PROV22)',1,'label',1,NULL,26,NULL,NULL,'2020-01-08 19:42:15','2020-01-08 15:42:15',12,NULL,NULL,NULL,0,4,'2020-01-08 16:41:00','2020-01-08 17:41:00',6,6,NULL,NULL),(23,'(PROV23)',1,NULL,1,NULL,26,NULL,NULL,'2020-01-08 19:45:04','2020-01-08 15:45:04',12,NULL,NULL,NULL,0,4,'2020-01-08 16:42:00','2020-01-08 17:42:00',6,6,NULL,NULL),(24,'MO2001-0006',1,NULL,1,NULL,26,NULL,NULL,'2020-01-08 19:46:41','2020-01-13 11:13:19',12,NULL,NULL,NULL,2,4,NULL,NULL,6,6,'2020-01-13 15:11:54',12),(26,'(PROV26)',1,NULL,1,NULL,NULL,NULL,NULL,'2020-01-08 19:49:22','2020-01-08 15:49:22',12,NULL,NULL,NULL,0,4,NULL,NULL,6,NULL,NULL,NULL),(27,'(PROV27)',1,NULL,1,NULL,NULL,NULL,NULL,'2020-01-08 19:49:50','2020-01-08 15:49:50',12,NULL,NULL,NULL,0,4,NULL,NULL,6,NULL,NULL,NULL),(28,'MO2001-0005',1,NULL,1,NULL,NULL,NULL,NULL,'2020-01-08 20:09:40','2020-01-08 16:21:22',12,NULL,NULL,NULL,2,4,NULL,NULL,6,NULL,'2020-01-08 20:12:55',12),(29,'(PROV29)',1,NULL,3,NULL,NULL,NULL,NULL,'2020-01-08 21:00:55','2020-01-08 17:00:55',12,NULL,NULL,NULL,0,4,NULL,NULL,NULL,NULL,NULL,NULL); +INSERT INTO `llx_mrp_mo` VALUES (5,'MO1912-0002',1,'Build 2 apple pies for CIO birthday',3,2,10,NULL,NULL,'2019-12-20 16:42:08','2020-01-13 11:29:30',12,12,NULL,NULL,3,4,NULL,NULL,6,7,'2019-12-20 20:32:09',12,NULL,0),(8,'MO1912-0001',1,NULL,1,NULL,NULL,NULL,NULL,'2019-12-20 17:01:21','2019-12-20 13:25:47',12,NULL,NULL,NULL,1,3,NULL,NULL,6,NULL,'2019-12-20 17:25:47',12,NULL,0),(14,'MO2001-0003',1,NULL,10,NULL,NULL,NULL,'Production very dangerous','2020-01-02 23:46:54','2020-01-06 02:48:22',12,12,NULL,NULL,2,4,NULL,NULL,6,NULL,'2020-01-02 23:57:42',12,NULL,0),(18,'MO2001-0004',1,NULL,2,2,NULL,NULL,NULL,'2020-01-03 13:34:34','2020-01-03 10:10:41',12,12,NULL,NULL,1,4,NULL,NULL,6,NULL,'2020-01-03 14:10:41',12,NULL,0),(22,'(PROV22)',1,'label',1,NULL,26,NULL,NULL,'2020-01-08 19:42:15','2020-01-08 15:42:15',12,NULL,NULL,NULL,0,4,'2020-01-08 16:41:00','2020-01-08 17:41:00',6,6,NULL,NULL,NULL,0),(23,'(PROV23)',1,NULL,1,NULL,26,NULL,NULL,'2020-01-08 19:45:04','2020-01-08 15:45:04',12,NULL,NULL,NULL,0,4,'2020-01-08 16:42:00','2020-01-08 17:42:00',6,6,NULL,NULL,NULL,0),(24,'MO2001-0006',1,NULL,1,NULL,26,NULL,NULL,'2020-01-08 19:46:41','2020-01-13 11:13:19',12,NULL,NULL,NULL,2,4,NULL,NULL,6,6,'2020-01-13 15:11:54',12,NULL,0),(26,'(PROV26)',1,NULL,1,NULL,NULL,NULL,NULL,'2020-01-08 19:49:22','2020-01-08 15:49:22',12,NULL,NULL,NULL,0,4,NULL,NULL,6,NULL,NULL,NULL,NULL,0),(27,'(PROV27)',1,NULL,1,NULL,NULL,NULL,NULL,'2020-01-08 19:49:50','2020-01-08 15:49:50',12,NULL,NULL,NULL,0,4,NULL,NULL,6,NULL,NULL,NULL,NULL,0),(28,'MO2001-0005',1,NULL,1,NULL,NULL,NULL,NULL,'2020-01-08 20:09:40','2020-01-08 16:21:22',12,NULL,NULL,NULL,2,4,NULL,NULL,6,NULL,'2020-01-08 20:12:55',12,NULL,0),(29,'(PROV29)',1,NULL,3,NULL,NULL,NULL,NULL,'2020-01-08 21:00:55','2020-01-08 17:00:55',12,NULL,NULL,NULL,0,4,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0); /*!40000 ALTER TABLE `llx_mrp_mo` ENABLE KEYS */; UNLOCK TABLES; @@ -8575,7 +8986,7 @@ CREATE TABLE `llx_paiement` ( LOCK TABLES `llx_paiement` WRITE; /*!40000 ALTER TABLE `llx_paiement` DISABLE KEYS */; -INSERT INTO `llx_paiement` VALUES (3,'',NULL,1,'2013-07-18 20:50:47','2021-07-11 17:49:28','2021-07-08 12:00:00',10.00000000,4,'','',6,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(5,'',NULL,1,'2013-08-01 03:34:11','2020-12-10 12:24:22','2020-08-01 03:34:11',5.63000000,6,'','Payment Invoice FA1108-0003',8,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(6,'',NULL,1,'2013-08-06 20:33:54','2020-12-10 12:24:22','2020-08-06 20:33:53',5.98000000,4,'','Payment Invoice FA1108-0004',13,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(8,'',NULL,1,'2013-08-08 02:53:40','2020-12-10 12:24:22','2020-08-08 12:00:00',26.10000000,4,'','',14,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(9,'',NULL,1,'2013-08-08 02:55:58','2020-12-10 12:24:23','2020-08-08 12:00:00',26.96000000,1,'','',15,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(17,'',NULL,1,'2014-12-09 15:28:44','2020-12-10 12:24:23','2020-12-09 12:00:00',2.00000000,4,'','',16,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(18,'',NULL,1,'2014-12-09 15:28:53','2020-12-10 12:24:23','2020-12-09 12:00:00',-2.00000000,4,'','',17,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(19,'',NULL,1,'2014-12-09 17:35:55','2020-12-10 12:24:23','2020-12-09 12:00:00',-2.00000000,4,'','',18,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(20,'',NULL,1,'2014-12-09 17:37:02','2020-12-10 12:24:23','2020-12-09 12:00:00',2.00000000,4,'','',19,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(21,'',NULL,1,'2014-12-09 18:35:07','2020-12-10 12:24:23','2020-12-09 12:00:00',-2.00000000,4,'','',20,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(23,'',NULL,1,'2014-12-12 18:54:33','2021-04-15 10:22:31','2020-12-12 12:00:00',1.00000000,1,'','',21,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(24,'',NULL,1,'2015-03-06 16:48:16','2021-04-15 10:22:31','2021-03-06 00:00:00',20.00000000,4,'','Adhésion/cotisation 2016',22,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(25,'',NULL,1,'2015-03-20 14:30:11','2021-04-15 10:22:31','2021-03-20 00:00:00',10.00000000,2,'','Adhésion/cotisation 2011',23,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(26,'',NULL,1,'2016-03-02 19:57:58','2021-07-11 17:49:28','2021-07-09 12:00:00',605.00000000,2,'','',24,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(29,'',NULL,1,'2016-03-02 20:01:39','2021-04-15 10:22:31','2021-03-19 12:00:00',500.00000000,4,'','',26,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(30,'',NULL,1,'2016-03-02 20:02:06','2021-04-15 10:22:31','2021-03-21 12:00:00',400.00000000,2,'','',27,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(32,'',NULL,1,'2016-03-03 19:22:32','2020-12-10 12:24:23','2020-10-03 12:00:00',-400.00000000,4,'','',28,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(33,'',NULL,1,'2016-03-03 19:23:16','2021-04-15 10:22:31','2021-03-10 12:00:00',-300.00000000,4,'','',29,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(34,'PAY1603-0001',NULL,1,'2017-02-06 08:10:24','2021-04-15 10:22:31','2021-03-22 12:00:00',150.00000000,7,'','',33,12,NULL,0,0,0.00000000,150.00000000,NULL,NULL),(35,'PAY1603-0002',NULL,1,'2017-02-06 08:10:50','2021-04-15 10:22:31','2021-03-25 12:00:00',140.00000000,3,'','',34,12,NULL,0,0,0.00000000,140.00000000,NULL,NULL),(36,'PAY1702-0003',NULL,1,'2017-02-21 16:07:43','2021-04-15 10:22:31','2021-02-21 12:00:00',50.00000000,3,'T170201','',37,12,NULL,0,0,0.00000000,50.00000000,NULL,NULL),(38,'PAY1803-0004',NULL,1,'2018-03-16 13:59:31','2021-04-15 10:22:31','2021-03-16 12:00:00',10.00000000,7,'','',39,12,NULL,0,0,0.00000000,10.00000000,NULL,NULL),(39,'PAY1801-0005',NULL,1,'2019-10-04 10:28:14','2021-04-15 10:22:31','2021-01-19 12:00:00',5.63000000,4,'','',41,12,NULL,0,0,0.00000000,5.63000000,NULL,NULL),(40,'PAY2001-0006',NULL,1,'2020-01-16 02:36:48','2021-04-15 10:22:31','2021-01-16 12:00:00',20.50000000,2,'','',50,12,NULL,0,0,0.00000000,20.50000000,NULL,NULL),(41,'PAY2001-0007',NULL,1,'2020-01-21 10:23:17','2021-04-15 10:22:31','2021-01-21 00:00:00',50.00000000,7,'','Subscription 2017',53,12,NULL,0,0,0.00000000,50.00000000,NULL,NULL),(42,'PAY2001-0008',NULL,1,'2020-01-21 10:23:28','2021-04-15 10:22:31','2021-01-21 00:00:00',50.00000000,7,'','Subscription 2018',54,12,NULL,0,0,0.00000000,50.00000000,NULL,NULL),(43,'PAY2001-0009',NULL,1,'2020-01-21 10:23:49','2021-04-15 10:22:31','2021-01-21 00:00:00',50.00000000,6,'','Subscription 2019',55,12,NULL,0,0,0.00000000,50.00000000,NULL,NULL); +INSERT INTO `llx_paiement` VALUES (3,'',NULL,1,'2013-07-18 20:50:47','2021-07-11 17:49:28','2021-07-08 12:00:00',10.00000000,4,'','',6,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(5,'',NULL,1,'2013-08-01 03:34:11','2022-02-07 13:37:54','2021-08-01 03:34:11',5.63000000,6,'','Payment Invoice FA1108-0003',8,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(6,'',NULL,1,'2013-08-06 20:33:54','2022-02-07 13:37:54','2021-08-06 20:33:53',5.98000000,4,'','Payment Invoice FA1108-0004',13,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(8,'',NULL,1,'2013-08-08 02:53:40','2022-02-07 13:37:54','2021-08-08 12:00:00',26.10000000,4,'','',14,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(9,'',NULL,1,'2013-08-08 02:55:58','2022-02-07 13:37:54','2021-08-08 12:00:00',26.96000000,1,'','',15,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(17,'',NULL,1,'2014-12-09 15:28:44','2022-02-07 13:37:54','2021-12-09 12:00:00',2.00000000,4,'','',16,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(18,'',NULL,1,'2014-12-09 15:28:53','2022-02-07 13:37:54','2021-12-09 12:00:00',-2.00000000,4,'','',17,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(19,'',NULL,1,'2014-12-09 17:35:55','2022-02-07 13:37:54','2021-12-09 12:00:00',-2.00000000,4,'','',18,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(20,'',NULL,1,'2014-12-09 17:37:02','2022-02-07 13:37:54','2021-12-09 12:00:00',2.00000000,4,'','',19,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(21,'',NULL,1,'2014-12-09 18:35:07','2022-02-07 13:37:54','2021-12-09 12:00:00',-2.00000000,4,'','',20,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(23,'',NULL,1,'2014-12-12 18:54:33','2022-02-07 13:37:54','2021-12-12 12:00:00',1.00000000,1,'','',21,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(24,'',NULL,1,'2015-03-06 16:48:16','2021-04-15 10:22:31','2021-03-06 00:00:00',20.00000000,4,'','Adhésion/cotisation 2016',22,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(25,'',NULL,1,'2015-03-20 14:30:11','2021-04-15 10:22:31','2021-03-20 00:00:00',10.00000000,2,'','Adhésion/cotisation 2011',23,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(26,'',NULL,1,'2016-03-02 19:57:58','2021-07-11 17:49:28','2021-07-09 12:00:00',605.00000000,2,'','',24,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(29,'',NULL,1,'2016-03-02 20:01:39','2021-04-15 10:22:31','2021-03-19 12:00:00',500.00000000,4,'','',26,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(30,'',NULL,1,'2016-03-02 20:02:06','2021-04-15 10:22:31','2021-03-21 12:00:00',400.00000000,2,'','',27,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(32,'',NULL,1,'2016-03-03 19:22:32','2022-02-07 13:37:54','2021-10-03 12:00:00',-400.00000000,4,'','',28,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(33,'',NULL,1,'2016-03-03 19:23:16','2021-04-15 10:22:31','2021-03-10 12:00:00',-300.00000000,4,'','',29,1,NULL,0,0,0.00000000,0.00000000,NULL,NULL),(34,'PAY1603-0001',NULL,1,'2017-02-06 08:10:24','2021-04-15 10:22:31','2021-03-22 12:00:00',150.00000000,7,'','',33,12,NULL,0,0,0.00000000,150.00000000,NULL,NULL),(35,'PAY1603-0002',NULL,1,'2017-02-06 08:10:50','2021-04-15 10:22:31','2021-03-25 12:00:00',140.00000000,3,'','',34,12,NULL,0,0,0.00000000,140.00000000,NULL,NULL),(36,'PAY1702-0003',NULL,1,'2017-02-21 16:07:43','2021-04-15 10:22:31','2021-02-21 12:00:00',50.00000000,3,'T170201','',37,12,NULL,0,0,0.00000000,50.00000000,NULL,NULL),(38,'PAY1803-0004',NULL,1,'2018-03-16 13:59:31','2021-04-15 10:22:31','2021-03-16 12:00:00',10.00000000,7,'','',39,12,NULL,0,0,0.00000000,10.00000000,NULL,NULL),(39,'PAY1801-0005',NULL,1,'2019-10-04 10:28:14','2022-02-07 13:37:54','2022-01-19 12:00:00',5.63000000,4,'','',41,12,NULL,0,0,0.00000000,5.63000000,NULL,NULL),(40,'PAY2001-0006',NULL,1,'2020-01-16 02:36:48','2022-02-07 13:37:54','2022-01-16 12:00:00',20.50000000,2,'','',50,12,NULL,0,0,0.00000000,20.50000000,NULL,NULL),(41,'PAY2001-0007',NULL,1,'2020-01-21 10:23:17','2022-02-07 13:37:54','2022-01-21 00:00:00',50.00000000,7,'','Subscription 2017',53,12,NULL,0,0,0.00000000,50.00000000,NULL,NULL),(42,'PAY2001-0008',NULL,1,'2020-01-21 10:23:28','2022-02-07 13:37:54','2022-01-21 00:00:00',50.00000000,7,'','Subscription 2018',54,12,NULL,0,0,0.00000000,50.00000000,NULL,NULL),(43,'PAY2001-0009',NULL,1,'2020-01-21 10:23:49','2022-02-07 13:37:54','2022-01-21 00:00:00',50.00000000,6,'','Subscription 2019',55,12,NULL,0,0,0.00000000,50.00000000,NULL,NULL); /*!40000 ALTER TABLE `llx_paiement` ENABLE KEYS */; UNLOCK TABLES; @@ -8592,6 +9003,8 @@ CREATE TABLE `llx_paiement_facture` ( `fk_facture` int(11) DEFAULT NULL, `amount` double(24,8) DEFAULT NULL, `multicurrency_amount` double(24,8) DEFAULT 0.00000000, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_tx` double(24,8) DEFAULT 1.00000000, PRIMARY KEY (`rowid`), UNIQUE KEY `uk_paiement_facture` (`fk_paiement`,`fk_facture`), KEY `idx_paiement_facture_fk_facture` (`fk_facture`), @@ -8607,7 +9020,7 @@ CREATE TABLE `llx_paiement_facture` ( LOCK TABLES `llx_paiement_facture` WRITE; /*!40000 ALTER TABLE `llx_paiement_facture` DISABLE KEYS */; -INSERT INTO `llx_paiement_facture` VALUES (3,3,2,10.00000000,0.00000000),(5,5,5,5.63000000,0.00000000),(6,6,6,5.98000000,0.00000000),(9,8,2,16.10000000,0.00000000),(10,8,8,10.00000000,0.00000000),(11,9,3,15.00000000,0.00000000),(12,9,9,11.96000000,0.00000000),(24,20,9,1.00000000,0.00000000),(31,26,32,600.00000000,0.00000000),(36,29,32,500.00000000,0.00000000),(37,30,32,400.00000000,0.00000000),(38,34,211,150.00000000,150.00000000),(39,35,211,140.00000000,140.00000000),(40,36,211,50.00000000,50.00000000),(42,38,149,10.00000000,10.00000000),(43,39,150,5.63000000,5.63000000),(44,40,224,20.50000000,20.50000000),(45,41,229,50.00000000,50.00000000),(46,42,230,50.00000000,50.00000000),(47,43,231,50.00000000,50.00000000); +INSERT INTO `llx_paiement_facture` VALUES (3,3,2,10.00000000,0.00000000,NULL,1.00000000),(5,5,5,5.63000000,0.00000000,NULL,1.00000000),(6,6,6,5.98000000,0.00000000,NULL,1.00000000),(9,8,2,16.10000000,0.00000000,NULL,1.00000000),(10,8,8,10.00000000,0.00000000,NULL,1.00000000),(11,9,3,15.00000000,0.00000000,NULL,1.00000000),(12,9,9,11.96000000,0.00000000,NULL,1.00000000),(24,20,9,1.00000000,0.00000000,NULL,1.00000000),(31,26,32,600.00000000,0.00000000,NULL,1.00000000),(36,29,32,500.00000000,0.00000000,NULL,1.00000000),(37,30,32,400.00000000,0.00000000,NULL,1.00000000),(38,34,211,150.00000000,150.00000000,NULL,1.00000000),(39,35,211,140.00000000,140.00000000,NULL,1.00000000),(40,36,211,50.00000000,50.00000000,NULL,1.00000000),(42,38,149,10.00000000,10.00000000,NULL,1.00000000),(43,39,150,5.63000000,5.63000000,NULL,1.00000000),(44,40,224,20.50000000,20.50000000,NULL,1.00000000),(45,41,229,50.00000000,50.00000000,NULL,1.00000000),(46,42,230,50.00000000,50.00000000,NULL,1.00000000),(47,43,231,50.00000000,50.00000000,NULL,1.00000000); /*!40000 ALTER TABLE `llx_paiement_facture` ENABLE KEYS */; UNLOCK TABLES; @@ -8696,6 +9109,8 @@ CREATE TABLE `llx_paiementfourn_facturefourn` ( `fk_facturefourn` int(11) DEFAULT NULL, `amount` double DEFAULT 0, `multicurrency_amount` double(24,8) DEFAULT 0.00000000, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_tx` double(24,8) DEFAULT 1.00000000, PRIMARY KEY (`rowid`), UNIQUE KEY `uk_paiementfourn_facturefourn` (`fk_paiementfourn`,`fk_facturefourn`), KEY `idx_paiementfourn_facturefourn_fk_facture` (`fk_facturefourn`), @@ -8709,7 +9124,7 @@ CREATE TABLE `llx_paiementfourn_facturefourn` ( LOCK TABLES `llx_paiementfourn_facturefourn` WRITE; /*!40000 ALTER TABLE `llx_paiementfourn_facturefourn` DISABLE KEYS */; -INSERT INTO `llx_paiementfourn_facturefourn` VALUES (1,1,16,900,0.00000000),(2,2,20,200,200.00000000),(4,4,27,-304.69,-304.69000000); +INSERT INTO `llx_paiementfourn_facturefourn` VALUES (1,1,16,900,0.00000000,NULL,1.00000000),(2,2,20,200,200.00000000,NULL,1.00000000),(4,4,27,-304.69,-304.69000000,NULL,1.00000000); /*!40000 ALTER TABLE `llx_paiementfourn_facturefourn` ENABLE KEYS */; UNLOCK TABLES; @@ -8727,7 +9142,7 @@ CREATE TABLE `llx_partnership` ( `fk_soc` int(11) DEFAULT NULL, `fk_member` int(11) DEFAULT NULL, `date_partnership_start` date NOT NULL, - `date_partnership_end` date NOT NULL, + `date_partnership_end` date DEFAULT NULL, `entity` int(11) NOT NULL DEFAULT 1, `reason_decline_or_cancel` text COLLATE utf8_unicode_ci DEFAULT NULL, `date_creation` datetime NOT NULL, @@ -8741,6 +9156,7 @@ CREATE TABLE `llx_partnership` ( `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, `model_pdf` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `last_check_backlink` datetime DEFAULT NULL, + `fk_type` int(11) NOT NULL DEFAULT 0, PRIMARY KEY (`rowid`), KEY `idx_partnership_rowid` (`rowid`), KEY `idx_partnership_ref` (`ref`), @@ -9373,6 +9789,8 @@ CREATE TABLE `llx_product` ( `batch_mask` varchar(32) COLLATE utf8_unicode_ci DEFAULT NULL, `lifetime` int(11) DEFAULT NULL, `qc_frequency` int(11) DEFAULT NULL, + `mandatory_period` tinyint(4) DEFAULT 0, + `fk_default_bom` int(11) DEFAULT NULL, PRIMARY KEY (`rowid`), UNIQUE KEY `uk_product_ref` (`ref`,`entity`), UNIQUE KEY `uk_product_barcode` (`barcode`,`fk_barcode_type`,`entity`), @@ -9401,7 +9819,7 @@ CREATE TABLE `llx_product` ( LOCK TABLES `llx_product` WRITE; /*!40000 ALTER TABLE `llx_product` DISABLE KEYS */; -INSERT INTO `llx_product` VALUES (1,'2012-07-08 14:33:17','2020-01-18 19:17:03',0,0,'PINKDRESS',1,NULL,'Pink dress','A beatifull pink dress','','',NULL,9.00000000,10.12500000,0.00000000,0.00000000,'HT',12.500,0,0.000,'0',0.000,'0',1,12,1,1,0,1,0,'',NULL,NULL,'123456789066',2,'','','','',NULL,NULL,NULL,670,-3,NULL,0,NULL,0,NULL,0,2.8,0.00000000,NULL,NULL,NULL,1,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(2,'2012-07-09 00:30:01','2019-11-28 15:09:50',0,0,'PEARPIE',1,NULL,'Pear Pie','','','',NULL,10.00000000,12.00000000,8.33333000,10.00000000,'TTC',20.000,0,0.000,'0',0.000,'0',1,12,1,1,0,0,0,'',NULL,NULL,'123456789077',2,'','','','',NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,NULL,0,998,0.00000000,NULL,NULL,NULL,1,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(3,'2012-07-09 00:30:25','2018-01-16 16:40:03',0,0,'CAKECONTRIB',1,NULL,'Cake making contribution','','','',NULL,0.00000000,0.00000000,0.00000000,0.00000000,'HT',12.500,0,0.000,'0',0.000,'0',1,NULL,1,1,0,0,1,'1m',NULL,NULL,'123456789088',2,'701CAKEM',NULL,NULL,'601CAKEM',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0.00000000,NULL,NULL,NULL,0,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(4,'2012-07-10 14:44:06','2021-04-15 11:40:18',0,0,'APPLEPIE',1,NULL,'Apple Pie','Nice Bio Apple Pie.
\r\n ','','',NULL,9.00000000,9.00000000,6.00000000,6.00000000,'HT',0.000,0,9.000,'1',9.000,'1',1,12,1,1,0,1,0,'',NULL,NULL,'123456789034',2,'701','','','601',NULL,NULL,NULL,500,-3,NULL,0,NULL,0,NULL,0,1021.2,10.00000000,NULL,NULL,NULL,1,0,NULL,NULL,NULL,NULL,NULL,'CGST+SGST',0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(5,'2013-07-20 23:11:38','2018-01-16 16:18:24',0,0,'DOLIDROID',1,NULL,'DoliDroid, Android app for Dolibarr','DoliDroid is the Android front-end client for Dolibarr ERP & CRM web software.
\r\nThis application is not a standalone program. It is a front end to use a online hosted Dolibarr ERP & CRM software (an Open-source web software to manage your business).
\r\n

The advantage of DoliDroid are :
\r\n- DoliDroid is not a duplicate code of Dolibarr, but a front-end of a Dolibarr web installation, so all your online existing features are supported by this application. This is also true for external modules features.
\r\n- Upgrading Dolibarr will not break DoliDroid.
\r\n- DoliDroid use embedded image resources to reduce bandwidth usage.
\r\n- DoliDroid use internal cache for pages that should not change (like menu page)
\r\n- Connections parameters are saved. No need to enter them each time you use DoliDroid.
\r\n- Integration with your phone or other applications (Clicking on PDF open PDF reader, clicking onto email or phone launch your email application or launch Android dialer, ...)

\r\n\r\n

WARNING ! 

\r\n\r\n

This application need Android 4.0+ and a hosted Dolibarr ERP & CRM version 3.5 or newer accessible by internet
\r\n(For example, when hosted on any SaaS solution like DoliCloud - http://www.dolicloud.com).

','','',NULL,10.00000000,11.96000000,0.00000000,0.00000000,'HT',19.600,0,0.000,'0',0.000,'0',1,NULL,1,1,0,0,0,'',NULL,'https://play.google.com/store/apps/details?id=com.nltechno.dolidroidpro','123456789023',2,'701',NULL,NULL,'601',NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,NULL,0,NULL,0.00000000,NULL,NULL,'',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(10,'2011-12-31 00:00:00','2017-02-16 00:12:09',0,0,'COMP-XP4523',1,NULL,'Computer XP4523','A powerfull computer XP4523 ','This product is imported.
\r\nWarning: Delay to get it are not reliable.','USXP765',11,100.00000000,110.00000000,0.00000000,0.00000000,'HT',10.000,0,0.000,'0',0.000,'0',NULL,12,1,1,0,1,0,'',150,NULL,'123456789055',2,'701OLDC',NULL,NULL,'601OLDC',NULL,NULL,NULL,1.7,0,NULL,0,NULL,0,NULL,0,110,0.00000000,NULL,NULL,NULL,NULL,0,'20110729232310',200,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(11,'2015-01-13 20:24:42','2019-10-08 17:21:07',0,0,'ROLLUPABC',1,NULL,'Rollup Dolibarr','A nice rollup','','',NULL,0.00000000,0.00000000,0.00000000,0.00000000,'HT',0.000,0,0.000,'0',0.000,'0',1,12,1,1,0,0,0,'',NULL,NULL,'123456789044',2,'','','','',NULL,NULL,NULL,95,-3,NULL,0,2.34,-4,NULL,0,-1,0.00000000,NULL,NULL,'',1,0,NULL,NULL,NULL,NULL,12.00000000,NULL,0,NULL,'',NULL,8,NULL,8,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(12,'2018-07-30 17:31:29','2018-07-30 13:35:02',0,0,'DOLICLOUD',1,NULL,'SaaS service of Dolibarr ERP CRM','Cloud hosting of Dolibarr ERP and CRM software','','',NULL,9.00000000,9.00000000,9.00000000,9.00000000,'HT',0.000,0,0.000,'0',0.000,'0',12,12,1,1,0,0,1,'',NULL,'http://www.dolicloud.com','123456789013',2,'',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0.00000000,NULL,NULL,'',0,0,NULL,NULL,NULL,NULL,8.50000000,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(13,'2017-02-16 03:49:00','2017-02-15 23:49:27',0,0,'COMP-XP4548',1,NULL,'Computer XP4523','A powerfull computer XP4523 ','This product is imported.
\r\nWarning: Delay to get it are not reliable.','USXP765',11,100.00000000,110.00000000,0.00000000,0.00000000,'HT',10.000,0,0.000,'0',0.000,'0',12,12,1,1,0,1,0,'',150,NULL,NULL,2,'',NULL,NULL,'',NULL,NULL,NULL,1.7,0,NULL,0,NULL,0,NULL,0,NULL,0.00000000,NULL,NULL,'',NULL,0,NULL,200,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(23,'2019-10-07 00:00:00','2019-11-28 13:51:35',0,0,'PREF123456',1,NULL,'Product name in default language','Product description in default language','a private note (free text)','customs code',1,100.00000000,110.00000000,100.00000000,110.00000000,'HT',10.000,0,0.000,'0',0.000,'0',12,NULL,0,1,0,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,-3,1,-1,4,-4,5,-3,NULL,0.00000000,NULL,NULL,NULL,0,0,'20191007122224',NULL,NULL,NULL,NULL,NULL,0,'a public note (free text)','',2,-1,3,-1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(24,'2019-11-28 16:33:35','2019-11-28 15:02:01',0,0,'POS-CARROT',1,NULL,'Carrot','','','',NULL,0.83333000,1.00000000,0.00000000,0.00000000,'TTC',20.000,0,0.000,'0',0.000,'0',12,12,1,1,0,0,0,'',NULL,NULL,NULL,2,'','','','',NULL,NULL,NULL,1,0,NULL,0,NULL,0,NULL,0,NULL,0.00000000,NULL,NULL,'',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(25,'2019-11-28 16:37:36','2020-01-13 11:13:19',0,0,'POS-APPLE',1,NULL,'Apple','','','',NULL,1.25000000,1.50000000,0.00000000,0.00000000,'TTC',20.000,0,0.000,'0',0.000,'0',12,12,1,1,0,0,0,'',NULL,NULL,NULL,2,'','','','',NULL,NULL,NULL,1,0,NULL,0,NULL,0,NULL,0,15.599999999999994,0.00000000,NULL,NULL,'',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(26,'2019-11-28 16:38:44','2019-11-28 12:38:44',0,0,'POS-KIWI',1,NULL,'Kiwi','','','',NULL,1.08333000,1.30000000,0.00000000,0.00000000,'TTC',20.000,0,0.000,'0',0.000,'0',12,12,1,1,0,0,0,'',NULL,NULL,NULL,2,'','','','',NULL,NULL,NULL,1,0,NULL,0,NULL,0,NULL,0,NULL,0.00000000,NULL,NULL,'',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(27,'2019-11-28 16:39:21','2019-11-28 14:57:44',0,0,'POS-PEACH',1,NULL,'Peach','','','',NULL,1.08333000,1.30000000,0.00000000,0.00000000,'TTC',20.000,0,0.000,'0',0.000,'0',12,12,1,1,0,0,0,'',NULL,NULL,NULL,2,'','','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0.00000000,NULL,NULL,'',0,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(28,'2019-11-28 16:39:58','2019-11-28 12:39:58',0,0,'POS-ORANGE',1,NULL,'Orange','','','',NULL,2.00000000,2.40000000,0.00000000,0.00000000,'HT',20.000,0,0.000,'0',0.000,'0',12,12,1,1,0,0,0,'',NULL,NULL,NULL,2,'','','','',NULL,NULL,NULL,1,0,NULL,0,NULL,0,NULL,0,NULL,0.00000000,NULL,NULL,'',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(29,'2019-11-28 17:03:14','2019-11-28 13:03:14',0,0,'POS-Eggs',1,NULL,'Eggs','','','',NULL,1.66667000,2.00000000,0.00000000,0.00000000,'TTC',20.000,0,0.000,'0',0.000,'0',12,12,1,1,0,0,0,'',NULL,NULL,NULL,2,'','','','',NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,NULL,0,NULL,0.00000000,NULL,NULL,'',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(30,'2019-11-28 17:09:14','2019-11-28 13:09:14',0,0,'POS-Chips',1,NULL,'Chips','','','',NULL,0.41667000,0.50000000,0.00000000,0.00000000,'TTC',20.000,0,0.000,'0',0.000,'0',12,12,1,1,0,0,0,'',NULL,NULL,NULL,2,'','','','',NULL,NULL,NULL,30,-3,NULL,0,NULL,0,NULL,0,NULL,0.00000000,NULL,NULL,'',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(31,'2021-04-15 08:38:02','2021-04-15 11:38:02',0,0,'PRODSER',1,NULL,'Product NFC - Unique','','','',NULL,0.00000000,0.00000000,0.00000000,0.00000000,'HT',19.600,0,0.000,'0',0.000,'0',12,12,1,1,0,2,0,'',0,NULL,NULL,2,'','','','','','',NULL,NULL,0,NULL,0,NULL,0,NULL,0,NULL,0.00000000,NULL,NULL,'',NULL,0,NULL,0,NULL,NULL,NULL,NULL,0,NULL,'',NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL); +INSERT INTO `llx_product` VALUES (1,'2012-07-08 14:33:17','2020-01-18 19:17:03',0,0,'PINKDRESS',1,NULL,'Pink dress','A beatifull pink dress','','',NULL,9.00000000,10.12500000,0.00000000,0.00000000,'HT',12.500,0,0.000,'0',0.000,'0',1,12,1,1,0,1,0,'',NULL,NULL,'123456789066',2,'','','','',NULL,NULL,NULL,670,-3,NULL,0,NULL,0,NULL,0,2.8,0.00000000,NULL,NULL,NULL,1,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL),(2,'2012-07-09 00:30:01','2019-11-28 15:09:50',0,0,'PEARPIE',1,NULL,'Pear Pie','','','',NULL,10.00000000,12.00000000,8.33333000,10.00000000,'TTC',20.000,0,0.000,'0',0.000,'0',1,12,1,1,0,0,0,'',NULL,NULL,'123456789077',2,'','','','',NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,NULL,0,998,0.00000000,NULL,NULL,NULL,1,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL),(3,'2012-07-09 00:30:25','2018-01-16 16:40:03',0,0,'CAKECONTRIB',1,NULL,'Cake making contribution','','','',NULL,0.00000000,0.00000000,0.00000000,0.00000000,'HT',12.500,0,0.000,'0',0.000,'0',1,NULL,1,1,0,0,1,'1m',NULL,NULL,'123456789088',2,'701CAKEM',NULL,NULL,'601CAKEM',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0.00000000,NULL,NULL,NULL,0,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL),(4,'2012-07-10 14:44:06','2021-04-15 11:40:18',0,0,'APPLEPIE',1,NULL,'Apple Pie','Nice Bio Apple Pie.
\r\n ','','',NULL,9.00000000,9.00000000,6.00000000,6.00000000,'HT',0.000,0,9.000,'1',9.000,'1',1,12,1,1,0,1,0,'',NULL,NULL,'123456789034',2,'701','','','601',NULL,NULL,NULL,500,-3,NULL,0,NULL,0,NULL,0,1021.2,10.00000000,NULL,NULL,NULL,1,0,NULL,NULL,NULL,NULL,NULL,'CGST+SGST',0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL),(5,'2013-07-20 23:11:38','2018-01-16 16:18:24',0,0,'DOLIDROID',1,NULL,'DoliDroid, Android app for Dolibarr','DoliDroid is the Android front-end client for Dolibarr ERP & CRM web software.
\r\nThis application is not a standalone program. It is a front end to use a online hosted Dolibarr ERP & CRM software (an Open-source web software to manage your business).
\r\n

The advantage of DoliDroid are :
\r\n- DoliDroid is not a duplicate code of Dolibarr, but a front-end of a Dolibarr web installation, so all your online existing features are supported by this application. This is also true for external modules features.
\r\n- Upgrading Dolibarr will not break DoliDroid.
\r\n- DoliDroid use embedded image resources to reduce bandwidth usage.
\r\n- DoliDroid use internal cache for pages that should not change (like menu page)
\r\n- Connections parameters are saved. No need to enter them each time you use DoliDroid.
\r\n- Integration with your phone or other applications (Clicking on PDF open PDF reader, clicking onto email or phone launch your email application or launch Android dialer, ...)

\r\n\r\n

WARNING ! 

\r\n\r\n

This application need Android 4.0+ and a hosted Dolibarr ERP & CRM version 3.5 or newer accessible by internet
\r\n(For example, when hosted on any SaaS solution like DoliCloud - http://www.dolicloud.com).

','','',NULL,10.00000000,11.96000000,0.00000000,0.00000000,'HT',19.600,0,0.000,'0',0.000,'0',1,NULL,1,1,0,0,0,'',NULL,'https://play.google.com/store/apps/details?id=com.nltechno.dolidroidpro','123456789023',2,'701',NULL,NULL,'601',NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,NULL,0,NULL,0.00000000,NULL,NULL,'',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL),(10,'2011-12-31 00:00:00','2017-02-16 00:12:09',0,0,'COMP-XP4523',1,NULL,'Computer XP4523','A powerfull computer XP4523 ','This product is imported.
\r\nWarning: Delay to get it are not reliable.','USXP765',11,100.00000000,110.00000000,0.00000000,0.00000000,'HT',10.000,0,0.000,'0',0.000,'0',NULL,12,1,1,0,1,0,'',150,NULL,'123456789055',2,'701OLDC',NULL,NULL,'601OLDC',NULL,NULL,NULL,1.7,0,NULL,0,NULL,0,NULL,0,110,0.00000000,NULL,NULL,NULL,NULL,0,'20110729232310',200,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL),(11,'2015-01-13 20:24:42','2019-10-08 17:21:07',0,0,'ROLLUPABC',1,NULL,'Rollup Dolibarr','A nice rollup','','',NULL,0.00000000,0.00000000,0.00000000,0.00000000,'HT',0.000,0,0.000,'0',0.000,'0',1,12,1,1,0,0,0,'',NULL,NULL,'123456789044',2,'','','','',NULL,NULL,NULL,95,-3,NULL,0,2.34,-4,NULL,0,-1,0.00000000,NULL,NULL,'',1,0,NULL,NULL,NULL,NULL,12.00000000,NULL,0,NULL,'',NULL,8,NULL,8,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL),(12,'2018-07-30 17:31:29','2018-07-30 13:35:02',0,0,'DOLICLOUD',1,NULL,'SaaS service of Dolibarr ERP CRM','Cloud hosting of Dolibarr ERP and CRM software','','',NULL,9.00000000,9.00000000,9.00000000,9.00000000,'HT',0.000,0,0.000,'0',0.000,'0',12,12,1,1,0,0,1,'',NULL,'http://www.dolicloud.com','123456789013',2,'',NULL,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0.00000000,NULL,NULL,'',0,0,NULL,NULL,NULL,NULL,8.50000000,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL),(13,'2017-02-16 03:49:00','2017-02-15 23:49:27',0,0,'COMP-XP4548',1,NULL,'Computer XP4523','A powerfull computer XP4523 ','This product is imported.
\r\nWarning: Delay to get it are not reliable.','USXP765',11,100.00000000,110.00000000,0.00000000,0.00000000,'HT',10.000,0,0.000,'0',0.000,'0',12,12,1,1,0,1,0,'',150,NULL,NULL,2,'',NULL,NULL,'',NULL,NULL,NULL,1.7,0,NULL,0,NULL,0,NULL,0,NULL,0.00000000,NULL,NULL,'',NULL,0,NULL,200,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL),(23,'2019-10-07 00:00:00','2019-11-28 13:51:35',0,0,'PREF123456',1,NULL,'Product name in default language','Product description in default language','a private note (free text)','customs code',1,100.00000000,110.00000000,100.00000000,110.00000000,'HT',10.000,0,0.000,'0',0.000,'0',12,NULL,0,1,0,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,-3,1,-1,4,-4,5,-3,NULL,0.00000000,NULL,NULL,NULL,0,0,'20191007122224',NULL,NULL,NULL,NULL,NULL,0,'a public note (free text)','',2,-1,3,-1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL),(24,'2019-11-28 16:33:35','2019-11-28 15:02:01',0,0,'POS-CARROT',1,NULL,'Carrot','','','',NULL,0.83333000,1.00000000,0.00000000,0.00000000,'TTC',20.000,0,0.000,'0',0.000,'0',12,12,1,1,0,0,0,'',NULL,NULL,NULL,2,'','','','',NULL,NULL,NULL,1,0,NULL,0,NULL,0,NULL,0,NULL,0.00000000,NULL,NULL,'',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL),(25,'2019-11-28 16:37:36','2020-01-13 11:13:19',0,0,'POS-APPLE',1,NULL,'Apple','','','',NULL,1.25000000,1.50000000,0.00000000,0.00000000,'TTC',20.000,0,0.000,'0',0.000,'0',12,12,1,1,0,0,0,'',NULL,NULL,NULL,2,'','','','',NULL,NULL,NULL,1,0,NULL,0,NULL,0,NULL,0,15.599999999999994,0.00000000,NULL,NULL,'',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL),(26,'2019-11-28 16:38:44','2019-11-28 12:38:44',0,0,'POS-KIWI',1,NULL,'Kiwi','','','',NULL,1.08333000,1.30000000,0.00000000,0.00000000,'TTC',20.000,0,0.000,'0',0.000,'0',12,12,1,1,0,0,0,'',NULL,NULL,NULL,2,'','','','',NULL,NULL,NULL,1,0,NULL,0,NULL,0,NULL,0,NULL,0.00000000,NULL,NULL,'',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL),(27,'2019-11-28 16:39:21','2019-11-28 14:57:44',0,0,'POS-PEACH',1,NULL,'Peach','','','',NULL,1.08333000,1.30000000,0.00000000,0.00000000,'TTC',20.000,0,0.000,'0',0.000,'0',12,12,1,1,0,0,0,'',NULL,NULL,NULL,2,'','','','',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0.00000000,NULL,NULL,'',0,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL),(28,'2019-11-28 16:39:58','2019-11-28 12:39:58',0,0,'POS-ORANGE',1,NULL,'Orange','','','',NULL,2.00000000,2.40000000,0.00000000,0.00000000,'HT',20.000,0,0.000,'0',0.000,'0',12,12,1,1,0,0,0,'',NULL,NULL,NULL,2,'','','','',NULL,NULL,NULL,1,0,NULL,0,NULL,0,NULL,0,NULL,0.00000000,NULL,NULL,'',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL),(29,'2019-11-28 17:03:14','2019-11-28 13:03:14',0,0,'POS-Eggs',1,NULL,'Eggs','','','',NULL,1.66667000,2.00000000,0.00000000,0.00000000,'TTC',20.000,0,0.000,'0',0.000,'0',12,12,1,1,0,0,0,'',NULL,NULL,NULL,2,'','','','',NULL,NULL,NULL,NULL,0,NULL,0,NULL,0,NULL,0,NULL,0.00000000,NULL,NULL,'',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL),(30,'2019-11-28 17:09:14','2019-11-28 13:09:14',0,0,'POS-Chips',1,NULL,'Chips','','','',NULL,0.41667000,0.50000000,0.00000000,0.00000000,'TTC',20.000,0,0.000,'0',0.000,'0',12,12,1,1,0,0,0,'',NULL,NULL,NULL,2,'','','','',NULL,NULL,NULL,30,-3,NULL,0,NULL,0,NULL,0,NULL,0.00000000,NULL,NULL,'',NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,'',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL),(31,'2021-04-15 08:38:02','2021-04-15 11:38:02',0,0,'PRODSER',1,NULL,'Product NFC - Unique','','','',NULL,0.00000000,0.00000000,0.00000000,0.00000000,'HT',19.600,0,0.000,'0',0.000,'0',12,12,1,1,0,2,0,'',0,NULL,NULL,2,'','','','','','',NULL,NULL,0,NULL,0,NULL,0,NULL,0,NULL,0.00000000,NULL,NULL,'',NULL,0,NULL,0,NULL,NULL,NULL,NULL,0,NULL,'',NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL); /*!40000 ALTER TABLE `llx_product` ENABLE KEYS */; UNLOCK TABLES; @@ -9418,6 +9836,7 @@ CREATE TABLE `llx_product_association` ( `fk_product_fils` int(11) NOT NULL DEFAULT 0, `qty` double DEFAULT NULL, `incdec` int(11) DEFAULT 1, + `rang` int(11) DEFAULT 0, PRIMARY KEY (`rowid`), UNIQUE KEY `uk_product_association` (`fk_product_pere`,`fk_product_fils`), KEY `idx_product_association` (`fk_product_fils`), @@ -9431,7 +9850,7 @@ CREATE TABLE `llx_product_association` ( LOCK TABLES `llx_product_association` WRITE; /*!40000 ALTER TABLE `llx_product_association` DISABLE KEYS */; -INSERT INTO `llx_product_association` VALUES (2,5,1,1,1),(3,4,3,5,1),(4,4,1,2,1); +INSERT INTO `llx_product_association` VALUES (2,5,1,1,1,0),(3,4,3,5,1,0),(4,4,1,2,1,0); /*!40000 ALTER TABLE `llx_product_association` ENABLE KEYS */; UNLOCK TABLES; @@ -9687,7 +10106,7 @@ CREATE TABLE `llx_product_customer_price` ( `localtax2_type` varchar(10) COLLATE utf8_unicode_ci NOT NULL DEFAULT '0', `fk_user` int(11) DEFAULT NULL, `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, - `ref_customer` varchar(30) COLLATE utf8_unicode_ci DEFAULT NULL, + `ref_customer` varchar(128) COLLATE utf8_unicode_ci DEFAULT NULL, PRIMARY KEY (`rowid`), UNIQUE KEY `uk_customer_price_fk_product_fk_soc` (`fk_product`,`fk_soc`), KEY `idx_product_customer_price_fk_user` (`fk_user`), @@ -9791,7 +10210,7 @@ CREATE TABLE `llx_product_fournisseur_price` ( `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(), `fk_product` int(11) DEFAULT NULL, `fk_soc` int(11) DEFAULT NULL, - `ref_fourn` varchar(30) COLLATE utf8_unicode_ci DEFAULT NULL, + `ref_fourn` varchar(128) COLLATE utf8_unicode_ci DEFAULT NULL, `desc_fourn` text COLLATE utf8_unicode_ci DEFAULT NULL, `fk_availability` int(11) DEFAULT NULL, `price` double(24,8) DEFAULT 0.00000000, @@ -9813,7 +10232,7 @@ CREATE TABLE `llx_product_fournisseur_price` ( `multicurrency_tx` double(24,8) DEFAULT 1.00000000, `multicurrency_unitprice` double(24,8) DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_price` double(24,8) DEFAULT NULL, `localtax1_tx` double(6,3) DEFAULT 0.000, `localtax1_type` varchar(10) COLLATE utf8_unicode_ci NOT NULL DEFAULT '0', @@ -9888,7 +10307,7 @@ CREATE TABLE `llx_product_fournisseur_price_log` ( `quantity` double DEFAULT NULL, `fk_user` int(11) DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_tx` double(24,8) DEFAULT 1.00000000, `multicurrency_price` double(24,8) DEFAULT NULL, `multicurrency_unitprice` double(24,8) DEFAULT NULL, @@ -9959,6 +10378,8 @@ CREATE TABLE `llx_product_lot` ( `eol_date` datetime DEFAULT NULL, `manufacturing_date` datetime DEFAULT NULL, `scrapping_date` datetime DEFAULT NULL, + `barcode` varchar(180) COLLATE utf8_unicode_ci DEFAULT NULL, + `fk_barcode_type` int(11) DEFAULT NULL, PRIMARY KEY (`rowid`), UNIQUE KEY `uk_product_lot` (`fk_product`,`batch`) ) ENGINE=InnoDB AUTO_INCREMENT=51 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; @@ -9970,7 +10391,7 @@ CREATE TABLE `llx_product_lot` ( LOCK TABLES `llx_product_lot` WRITE; /*!40000 ALTER TABLE `llx_product_lot` DISABLE KEYS */; -INSERT INTO `llx_product_lot` VALUES (1,1,2,'123456','2018-07-07',NULL,'2018-07-21 20:55:19','2018-12-12 10:53:58',NULL,NULL,NULL,NULL,NULL,NULL),(2,1,2,'2222','2018-07-08','2018-07-07','2018-07-21 21:00:42','2018-12-12 10:53:58',NULL,NULL,NULL,NULL,NULL,NULL),(3,1,10,'5599887766452',NULL,NULL,'2018-07-30 17:39:31','2018-12-12 10:53:58',NULL,NULL,NULL,NULL,NULL,NULL),(4,1,10,'4494487766452',NULL,NULL,'2018-07-30 17:40:12','2018-12-12 10:53:58',NULL,NULL,NULL,NULL,NULL,NULL),(39,1,1,'000000',NULL,NULL,'2020-01-08 20:41:18','2020-01-08 16:41:18',NULL,NULL,NULL,NULL,NULL,NULL),(40,1,4,'aaa','2020-01-01',NULL,'2020-01-08 20:41:18','2020-01-13 11:28:05',NULL,12,NULL,NULL,NULL,NULL),(46,1,1,'string',NULL,NULL,'2020-01-18 20:16:58','2020-01-18 19:16:58',NULL,NULL,NULL,NULL,NULL,NULL),(47,1,4,'000000',NULL,NULL,'2020-01-08 16:40:27','2020-01-21 10:30:15',1,1,NULL,NULL,NULL,NULL),(50,1,4,'Lot 2021-02',NULL,NULL,'2021-04-15 08:40:18','2021-04-15 11:40:18',NULL,NULL,NULL,NULL,NULL,NULL); +INSERT INTO `llx_product_lot` VALUES (1,1,2,'123456','2018-07-07',NULL,'2018-07-21 20:55:19','2018-12-12 10:53:58',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(2,1,2,'2222','2018-07-08','2018-07-07','2018-07-21 21:00:42','2018-12-12 10:53:58',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(3,1,10,'5599887766452',NULL,NULL,'2018-07-30 17:39:31','2018-12-12 10:53:58',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(4,1,10,'4494487766452',NULL,NULL,'2018-07-30 17:40:12','2018-12-12 10:53:58',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(39,1,1,'000000',NULL,NULL,'2020-01-08 20:41:18','2020-01-08 16:41:18',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(40,1,4,'aaa','2020-01-01',NULL,'2020-01-08 20:41:18','2020-01-13 11:28:05',NULL,12,NULL,NULL,NULL,NULL,NULL,NULL),(46,1,1,'string',NULL,NULL,'2020-01-18 20:16:58','2020-01-18 19:16:58',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL),(47,1,4,'000000',NULL,NULL,'2020-01-08 16:40:27','2020-01-21 10:30:15',1,1,NULL,NULL,NULL,NULL,NULL,NULL),(50,1,4,'Lot 2021-02',NULL,NULL,'2021-04-15 08:40:18','2021-04-15 11:40:18',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL); /*!40000 ALTER TABLE `llx_product_lot` ENABLE KEYS */; UNLOCK TABLES; @@ -10064,7 +10485,7 @@ CREATE TABLE `llx_product_price` ( `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, `fk_price_expression` int(11) DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_price` double(24,8) DEFAULT 0.00000000, `multicurrency_tx` double(24,8) DEFAULT 1.00000000, `multicurrency_price_ttc` double(24,8) DEFAULT NULL, @@ -10109,7 +10530,7 @@ CREATE TABLE `llx_product_price_by_qty` ( `unitprice` double(24,8) DEFAULT 0.00000000, `price_base_type` varchar(3) COLLATE utf8_unicode_ci DEFAULT 'HT', `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_tx` double(24,8) DEFAULT 1.00000000, `multicurrency_price` double(24,8) DEFAULT NULL, `multicurrency_price_ttc` double(24,8) DEFAULT NULL, @@ -10187,6 +10608,34 @@ INSERT INTO `llx_product_stock` VALUES (1,'2012-07-08 22:43:51',2,2,1000,NULL),( /*!40000 ALTER TABLE `llx_product_stock` ENABLE KEYS */; UNLOCK TABLES; +-- +-- Table structure for table `llx_product_warehouse_properties` +-- + +DROP TABLE IF EXISTS `llx_product_warehouse_properties`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `llx_product_warehouse_properties` ( + `rowid` int(11) NOT NULL AUTO_INCREMENT, + `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(), + `fk_product` int(11) NOT NULL, + `fk_entrepot` int(11) NOT NULL, + `seuil_stock_alerte` float DEFAULT 0, + `desiredstock` float DEFAULT 0, + `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, + PRIMARY KEY (`rowid`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `llx_product_warehouse_properties` +-- + +LOCK TABLES `llx_product_warehouse_properties` WRITE; +/*!40000 ALTER TABLE `llx_product_warehouse_properties` DISABLE KEYS */; +/*!40000 ALTER TABLE `llx_product_warehouse_properties` ENABLE KEYS */; +UNLOCK TABLES; + -- -- Table structure for table `llx_projet` -- @@ -10230,6 +10679,7 @@ CREATE TABLE `llx_projet` ( `accept_booth_suggestions` int(11) DEFAULT 0, `price_registration` double(24,8) DEFAULT NULL, `price_booth` double(24,8) DEFAULT NULL, + `max_attendees` int(11) DEFAULT 0, PRIMARY KEY (`rowid`), UNIQUE KEY `uk_projet_ref` (`ref`,`entity`), KEY `idx_projet_fk_soc` (`fk_soc`), @@ -10243,7 +10693,7 @@ CREATE TABLE `llx_projet` ( LOCK TABLES `llx_projet` WRITE; /*!40000 ALTER TABLE `llx_projet` DISABLE KEYS */; -INSERT INTO `llx_projet` VALUES (1,11,'2012-07-09 00:00:00','2017-10-05 20:51:28','2012-07-09',NULL,'PROJ1',1,'Project One','',1,0,1,NULL,NULL,NULL,'gdfgdfg','baleine',NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,1,0,NULL,NULL,0,0,NULL,NULL),(2,13,'2012-07-09 00:00:00','2017-10-05 20:51:51','2012-07-09',NULL,'PROJ2',1,'Project Two','',1,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,1,0,NULL,NULL,0,0,NULL,NULL),(3,1,'2012-07-09 00:00:00','2020-01-15 12:40:50','2012-07-09',NULL,'PROJINDIAN',1,'Project for Indian company move','',1,0,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,12,1,0,1,0,NULL,NULL,0,0,NULL,NULL),(4,NULL,'2012-07-09 00:00:00','2012-07-08 22:50:49','2012-07-09',NULL,'PROJSHARED',1,'The Global project','',1,1,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,1,0,NULL,NULL,0,0,NULL,NULL),(5,NULL,'2012-07-11 00:00:00','2020-01-15 12:27:15','2012-07-11','2013-07-14','RMLL',1,'Project management RMLL','',1,1,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,12,1,0,1,0,NULL,NULL,0,0,NULL,NULL),(6,10,'2018-07-30 00:00:00','2019-11-28 11:52:54','2018-07-30',NULL,'PJ1607-0001',1,'PROJALICE1','The Alice project number 1',12,0,1,2,20.00,NULL,NULL,NULL,NULL,5000.00000000,NULL,NULL,8000.00000000,NULL,12,1,1,1,0,NULL,NULL,0,0,NULL,NULL),(7,10,'2018-07-30 00:00:00','2019-11-28 11:52:54','2018-07-30',NULL,'PJ1607-0002',1,'PROJALICE2','The Alice project number 2',12,0,1,6,100.00,NULL,NULL,NULL,NULL,NULL,'2017-02-01 16:24:31',12,7000.00000000,NULL,NULL,0,1,1,0,NULL,NULL,0,0,NULL,NULL),(8,10,'2018-07-30 00:00:00','2019-11-28 11:52:54','2018-07-30',NULL,'PJ1607-0003',1,'PROJALICE2','The Alice project number 3',12,0,1,6,100.00,NULL,NULL,NULL,NULL,NULL,NULL,NULL,3550.00000000,NULL,NULL,0,1,1,0,NULL,NULL,0,0,NULL,NULL),(9,4,'2018-07-31 00:00:00','2019-12-20 16:33:15','2018-07-31',NULL,'PJ1607-0004',1,'Project Top X','',12,0,2,2,27.00,NULL,NULL,NULL,NULL,NULL,'2019-12-20 20:33:15',12,4000.00000000,NULL,NULL,0,1,1,0,NULL,NULL,0,0,NULL,NULL),(10,1,'2019-12-21 19:46:33','2019-12-21 15:48:06','2019-12-21',NULL,'PJ1912-0005',1,'Contact for a new shop in Delhi','',12,0,1,1,20.00,NULL,NULL,NULL,NULL,NULL,NULL,NULL,18000.00000000,NULL,12,0,1,1,0,NULL,NULL,0,0,NULL,NULL),(11,10,'2019-12-21 19:49:28','2019-12-21 16:10:21','2019-12-02','2019-12-13','PJ1912-0006',1,'Request for new development of logo','Request to redesign a new logo',12,0,1,4,60.00,NULL,NULL,NULL,NULL,NULL,NULL,NULL,6500.00000000,NULL,12,1,1,1,0,NULL,NULL,0,0,NULL,NULL),(12,4,'2019-12-21 19:52:12','2019-12-21 15:52:12','2019-12-21',NULL,'PJ1912-0007',1,'Adding new tool for Customer Relationship Management','',12,1,0,1,0.00,NULL,NULL,NULL,NULL,NULL,NULL,NULL,16000.00000000,NULL,NULL,1,1,1,0,NULL,NULL,0,0,NULL,NULL),(13,26,'2019-12-21 19:53:21','2019-12-21 15:53:59','2019-12-21',NULL,'PJ1912-0008',1,'Cooking 100 apple pie for chrsitmas','',12,0,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,12,1,0,1,0,NULL,NULL,0,0,NULL,NULL); +INSERT INTO `llx_projet` VALUES (1,11,'2012-07-09 00:00:00','2017-10-05 20:51:28','2012-07-09',NULL,'PROJ1',1,'Project One','',1,0,1,NULL,NULL,NULL,'gdfgdfg','baleine',NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,1,0,NULL,NULL,0,0,NULL,NULL,0),(2,13,'2012-07-09 00:00:00','2017-10-05 20:51:51','2012-07-09',NULL,'PROJ2',1,'Project Two','',1,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,1,0,NULL,NULL,0,0,NULL,NULL,0),(3,1,'2012-07-09 00:00:00','2020-01-15 12:40:50','2012-07-09',NULL,'PROJINDIAN',1,'Project for Indian company move','',1,0,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,12,1,0,1,0,NULL,NULL,0,0,NULL,NULL,0),(4,NULL,'2012-07-09 00:00:00','2012-07-08 22:50:49','2012-07-09',NULL,'PROJSHARED',1,'The Global project','',1,1,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,1,0,NULL,NULL,0,0,NULL,NULL,0),(5,NULL,'2012-07-11 00:00:00','2020-01-15 12:27:15','2012-07-11','2013-07-14','RMLL',1,'Project management RMLL','',1,1,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,12,1,0,1,0,NULL,NULL,0,0,NULL,NULL,0),(6,10,'2018-07-30 00:00:00','2019-11-28 11:52:54','2018-07-30',NULL,'PJ1607-0001',1,'PROJALICE1','The Alice project number 1',12,0,1,2,20.00,NULL,NULL,NULL,NULL,5000.00000000,NULL,NULL,8000.00000000,NULL,12,1,1,1,0,NULL,NULL,0,0,NULL,NULL,0),(7,10,'2018-07-30 00:00:00','2019-11-28 11:52:54','2018-07-30',NULL,'PJ1607-0002',1,'PROJALICE2','The Alice project number 2',12,0,1,6,100.00,NULL,NULL,NULL,NULL,NULL,'2017-02-01 16:24:31',12,7000.00000000,NULL,NULL,0,1,1,0,NULL,NULL,0,0,NULL,NULL,0),(8,10,'2018-07-30 00:00:00','2019-11-28 11:52:54','2018-07-30',NULL,'PJ1607-0003',1,'PROJALICE2','The Alice project number 3',12,0,1,6,100.00,NULL,NULL,NULL,NULL,NULL,NULL,NULL,3550.00000000,NULL,NULL,0,1,1,0,NULL,NULL,0,0,NULL,NULL,0),(9,4,'2018-07-31 00:00:00','2019-12-20 16:33:15','2018-07-31',NULL,'PJ1607-0004',1,'Project Top X','',12,0,2,2,27.00,NULL,NULL,NULL,NULL,NULL,'2019-12-20 20:33:15',12,4000.00000000,NULL,NULL,0,1,1,0,NULL,NULL,0,0,NULL,NULL,0),(10,1,'2019-12-21 19:46:33','2019-12-21 15:48:06','2019-12-21',NULL,'PJ1912-0005',1,'Contact for a new shop in Delhi','',12,0,1,1,20.00,NULL,NULL,NULL,NULL,NULL,NULL,NULL,18000.00000000,NULL,12,0,1,1,0,NULL,NULL,0,0,NULL,NULL,0),(11,10,'2019-12-21 19:49:28','2019-12-21 16:10:21','2019-12-02','2019-12-13','PJ1912-0006',1,'Request for new development of logo','Request to redesign a new logo',12,0,1,4,60.00,NULL,NULL,NULL,NULL,NULL,NULL,NULL,6500.00000000,NULL,12,1,1,1,0,NULL,NULL,0,0,NULL,NULL,0),(12,4,'2019-12-21 19:52:12','2019-12-21 15:52:12','2019-12-21',NULL,'PJ1912-0007',1,'Adding new tool for Customer Relationship Management','',12,1,0,1,0.00,NULL,NULL,NULL,NULL,NULL,NULL,NULL,16000.00000000,NULL,NULL,1,1,1,0,NULL,NULL,0,0,NULL,NULL,0),(13,26,'2019-12-21 19:53:21','2019-12-21 15:53:59','2019-12-21',NULL,'PJ1912-0008',1,'Cooking 100 apple pie for chrsitmas','',12,0,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,12,1,0,1,0,NULL,NULL,0,0,NULL,NULL,0); /*!40000 ALTER TABLE `llx_projet` ENABLE KEYS */; UNLOCK TABLES; @@ -10299,6 +10749,7 @@ CREATE TABLE `llx_projet_task` ( `planned_workload` double DEFAULT 0, `progress` int(11) DEFAULT 0, `priority` int(11) DEFAULT 0, + `budget_amount` double(24,8) DEFAULT NULL, `fk_user_creat` int(11) DEFAULT NULL, `fk_user_valid` int(11) DEFAULT NULL, `fk_statut` smallint(6) NOT NULL DEFAULT 0, @@ -10324,7 +10775,7 @@ CREATE TABLE `llx_projet_task` ( LOCK TABLES `llx_projet_task` WRITE; /*!40000 ALTER TABLE `llx_projet_task` DISABLE KEYS */; -INSERT INTO `llx_projet_task` VALUES (2,'2',1,5,0,'2012-07-11 16:23:53','2015-09-08 23:06:14','2012-07-11 12:00:00','2013-07-14 12:00:00',NULL,'Heberger site RMLL','',0,0,0,0,1,NULL,0,NULL,NULL,0,NULL,NULL),(3,'TK1007-0001',1,1,0,'2016-12-21 13:52:41','2018-07-30 11:35:40','2016-12-21 16:52:00',NULL,NULL,'Analyze','',9000,36000,0,0,1,NULL,0,NULL,'gdfgdfgdf',0,NULL,NULL),(4,'TK1007-0002',1,1,0,'2016-12-21 13:55:39','2020-06-12 17:13:30','2016-12-21 16:55:00',NULL,NULL,'Specification','',10800,18000,25,0,1,NULL,0,NULL,NULL,0,NULL,NULL),(5,'TK1007-0003',1,1,0,'2016-12-21 14:16:58','2018-07-30 11:35:59','2016-12-21 17:16:00',NULL,NULL,'Development','',0,0,0,0,1,NULL,0,NULL,NULL,0,NULL,NULL),(6,'TK1607-0004',1,6,0,'2018-07-30 15:33:27','2018-07-30 11:34:47','2018-07-30 02:00:00',NULL,NULL,'Project preparation phase A','',75600,720000,10,0,12,NULL,0,NULL,NULL,0,NULL,NULL),(7,'TK1607-0005',1,6,0,'2018-07-30 15:33:39','2017-01-30 11:23:39','2018-07-30 02:00:00',NULL,NULL,'Project preparation phase B','',40260,1080000,5,0,12,NULL,0,NULL,NULL,0,NULL,NULL),(8,'TK1607-0006',1,6,0,'2018-07-30 15:33:53','2018-07-30 11:33:53','2018-07-30 02:00:00',NULL,NULL,'Project execution phase A','',0,162000,0,0,12,NULL,0,NULL,NULL,0,NULL,NULL),(9,'TK1607-0007',1,6,0,'2018-07-30 15:34:09','2018-07-30 11:34:09','2018-10-27 02:00:00',NULL,NULL,'Project execution phase B','',0,2160000,0,0,12,NULL,0,NULL,NULL,0,NULL,NULL),(10,'TK1007-0008',1,1,0,'2018-07-30 15:36:31','2018-07-30 11:36:31','2018-07-30 02:00:00',NULL,NULL,'Tests','',0,316800,0,0,12,NULL,0,NULL,NULL,0,NULL,NULL); +INSERT INTO `llx_projet_task` VALUES (2,'2',1,5,0,'2012-07-11 16:23:53','2015-09-08 23:06:14','2012-07-11 12:00:00','2013-07-14 12:00:00',NULL,'Heberger site RMLL','',0,0,0,0,NULL,1,NULL,0,NULL,NULL,0,NULL,NULL),(3,'TK1007-0001',1,1,0,'2016-12-21 13:52:41','2018-07-30 11:35:40','2016-12-21 16:52:00',NULL,NULL,'Analyze','',9000,36000,0,0,NULL,1,NULL,0,NULL,'gdfgdfgdf',0,NULL,NULL),(4,'TK1007-0002',1,1,0,'2016-12-21 13:55:39','2020-06-12 17:13:30','2016-12-21 16:55:00',NULL,NULL,'Specification','',10800,18000,25,0,NULL,1,NULL,0,NULL,NULL,0,NULL,NULL),(5,'TK1007-0003',1,1,0,'2016-12-21 14:16:58','2018-07-30 11:35:59','2016-12-21 17:16:00',NULL,NULL,'Development','',0,0,0,0,NULL,1,NULL,0,NULL,NULL,0,NULL,NULL),(6,'TK1607-0004',1,6,0,'2018-07-30 15:33:27','2018-07-30 11:34:47','2018-07-30 02:00:00',NULL,NULL,'Project preparation phase A','',75600,720000,10,0,NULL,12,NULL,0,NULL,NULL,0,NULL,NULL),(7,'TK1607-0005',1,6,0,'2018-07-30 15:33:39','2017-01-30 11:23:39','2018-07-30 02:00:00',NULL,NULL,'Project preparation phase B','',40260,1080000,5,0,NULL,12,NULL,0,NULL,NULL,0,NULL,NULL),(8,'TK1607-0006',1,6,0,'2018-07-30 15:33:53','2018-07-30 11:33:53','2018-07-30 02:00:00',NULL,NULL,'Project execution phase A','',0,162000,0,0,NULL,12,NULL,0,NULL,NULL,0,NULL,NULL),(9,'TK1607-0007',1,6,0,'2018-07-30 15:34:09','2018-07-30 11:34:09','2018-10-27 02:00:00',NULL,NULL,'Project execution phase B','',0,2160000,0,0,NULL,12,NULL,0,NULL,NULL,0,NULL,NULL),(10,'TK1007-0008',1,1,0,'2018-07-30 15:36:31','2018-07-30 11:36:31','2018-07-30 02:00:00',NULL,NULL,'Tests','',0,316800,0,0,NULL,12,NULL,0,NULL,NULL,0,NULL,NULL); /*!40000 ALTER TABLE `llx_projet_task` ENABLE KEYS */; UNLOCK TABLES; @@ -10449,12 +10900,14 @@ CREATE TABLE `llx_propal` ( `fk_incoterms` int(11) DEFAULT NULL, `location_incoterms` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_tx` double(24,8) DEFAULT 1.00000000, `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000, `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000, `multicurrency_total_ttc` double(24,8) DEFAULT 0.00000000, `last_main_doc` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `online_sign_ip` varchar(48) COLLATE utf8_unicode_ci DEFAULT NULL, + `online_sign_name` varchar(64) COLLATE utf8_unicode_ci DEFAULT NULL, PRIMARY KEY (`rowid`), UNIQUE KEY `uk_propal_ref` (`ref`,`entity`), KEY `idx_propal_fk_soc` (`fk_soc`), @@ -10481,7 +10934,7 @@ CREATE TABLE `llx_propal` ( LOCK TABLES `llx_propal` WRITE; /*!40000 ALTER TABLE `llx_propal` DISABLE KEYS */; -INSERT INTO `llx_propal` VALUES (1,2,NULL,'2021-07-11 17:49:28','PR1007-0001',1,NULL,NULL,'','2012-07-09 01:33:49','2021-07-09','2020-07-24 12:00:00','2020-08-08 14:24:18',NULL,NULL,1,NULL,1,NULL,NULL,1,0,NULL,NULL,0,30.00000000,3.84000000,0.00000000,0.00000000,33.84000000,NULL,NULL,1,0,'','','azur',NULL,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL),(2,1,NULL,'2021-07-11 17:49:28','PR1007-0002',1,NULL,NULL,'','2012-07-10 02:11:44','2021-07-10','2020-07-25 12:00:00','2021-07-10 02:12:55','2020-07-20 15:23:12','2020-07-20 15:23:12',1,NULL,1,1,1,2,0,NULL,NULL,0,10.00000000,0.00000000,0.00000000,0.00000000,10.00000000,NULL,NULL,1,1,'','','azur',NULL,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL),(3,4,NULL,'2021-04-15 10:22:55','PR1007-0003',1,NULL,NULL,'','2012-07-18 11:35:11','2020-07-18','2020-08-02 12:00:00','2020-07-18 11:36:18','2020-07-20 15:21:15','2020-07-20 15:21:15',1,NULL,1,1,1,2,0,NULL,NULL,0,10.00000000,0.00000000,0.00000000,0.00000000,10.00000000,NULL,NULL,1,0,'','','azur',NULL,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL),(5,19,NULL,'2021-04-15 10:22:31','PR1302-0005',1,NULL,NULL,'','2015-02-17 15:39:56','2021-02-17','2021-03-04 12:00:00','2020-11-15 23:27:10',NULL,NULL,1,NULL,12,NULL,NULL,1,0,NULL,NULL,0,10.00000000,2.00000000,0.00000000,0.00000000,12.00000000,NULL,NULL,1,0,'','','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL),(6,19,NULL,'2021-04-15 10:22:31','PR1302-0006',1,NULL,NULL,'','2015-02-17 15:40:12','2021-02-17','2021-03-04 12:00:00',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,0,0,NULL,NULL,0,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,1,0,'','','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL),(7,19,NULL,'2021-04-15 10:22:31','PR1302-0007',1,NULL,NULL,'','2015-02-17 15:41:15','2021-02-17','2021-03-04 12:00:00','2020-01-29 21:49:33',NULL,NULL,1,NULL,12,NULL,NULL,1,0,NULL,NULL,0,400.00000000,0.00000000,0.00000000,0.00000000,400.00000000,NULL,NULL,1,0,'','','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,400.00000000,0.00000000,400.00000000,NULL),(8,19,NULL,'2021-04-15 10:22:31','PR1302-0008',1,NULL,NULL,'','2015-02-17 15:43:39','2021-02-17','2021-03-04 12:00:00',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,0,0,NULL,NULL,0,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,1,0,'','','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL),(10,7,4,'2020-12-10 12:24:22','PR1909-0031',1,NULL,NULL,'','2017-11-15 23:37:08','2020-11-15','2020-11-30 12:00:00','2021-09-27 16:54:30',NULL,NULL,12,NULL,12,NULL,NULL,1,0,NULL,NULL,0,10.00000000,0.00000000,0.00000000,0.00000000,10.00000000,NULL,NULL,1,3,'','','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',NULL,NULL,1.00000000,10.00000000,0.00000000,10.00000000,'propale/PR1909-0031/PR1909-0031.pdf'),(11,1,NULL,'2021-07-11 17:49:28','PR1702-0009',1,NULL,NULL,'','2017-02-16 01:44:58','2021-05-13','2021-05-28 12:00:00','2021-02-16 01:44:58',NULL,NULL,1,NULL,1,NULL,NULL,1,0,NULL,NULL,0,60.00000000,0.00000000,0.00000000,0.00000000,60.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,60.00000000,0.00000000,60.00000000,NULL),(12,7,NULL,'2021-07-11 17:49:28','PR1702-0010',1,NULL,NULL,'','2017-02-16 01:45:44','2021-06-24','2021-07-09 12:00:00','2021-02-16 01:45:44',NULL,NULL,2,NULL,2,NULL,NULL,1,0,NULL,NULL,0,832.00000000,0.00000000,0.00000000,0.00000000,832.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,832.00000000,0.00000000,832.00000000,NULL),(13,26,NULL,'2021-04-15 10:22:31','PR1702-0011',1,NULL,NULL,'','2017-02-16 01:46:15','2021-04-03','2020-04-18 12:00:00','2021-02-16 01:46:15',NULL,NULL,1,NULL,1,NULL,NULL,1,0,NULL,NULL,0,242.00000000,0.00000000,0.00000000,0.00000000,242.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,242.00000000,0.00000000,242.00000000,NULL),(14,3,NULL,'2021-07-11 17:49:28','PR1702-0012',1,NULL,NULL,'','2017-02-16 01:46:15','2021-06-19','2021-07-04 12:00:00','2021-02-16 01:46:15',NULL,NULL,2,NULL,2,NULL,NULL,1,0,NULL,NULL,0,245.00000000,0.00000000,0.00000000,0.00000000,245.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,245.00000000,0.00000000,245.00000000,NULL),(15,26,NULL,'2021-07-11 17:49:28','PR1702-0013',1,NULL,NULL,'','2017-02-16 01:46:15','2021-05-01','2021-05-16 12:00:00','2020-02-16 01:46:15',NULL,NULL,2,NULL,2,NULL,NULL,1,0,NULL,NULL,0,940.00000000,0.00000000,0.00000000,0.00000000,940.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,940.00000000,0.00000000,940.00000000,NULL),(16,1,NULL,'2021-07-11 17:49:28','PR1702-0014',1,NULL,NULL,'','2017-02-16 01:46:15','2021-05-13','2021-05-28 12:00:00','2021-02-16 01:46:15',NULL,NULL,2,NULL,2,NULL,NULL,1,0,NULL,NULL,0,125.00000000,0.00000000,0.00000000,0.00000000,125.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,125.00000000,0.00000000,125.00000000,NULL),(17,1,NULL,'2020-12-10 12:24:22','PR1702-0015',1,NULL,NULL,'','2017-02-16 01:46:15','2020-07-23','2020-08-07 12:00:00','2020-02-16 01:46:15',NULL,NULL,1,NULL,1,NULL,NULL,1,0,NULL,NULL,0,163.00000000,0.00000000,0.00000000,0.00000000,163.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,163.00000000,0.00000000,163.00000000,NULL),(18,26,NULL,'2021-04-15 10:22:31','PR1702-0016',1,NULL,NULL,'','2017-02-16 01:46:15','2021-02-13','2021-02-28 12:00:00','2021-02-16 01:46:15',NULL,NULL,2,NULL,2,NULL,NULL,1,0,NULL,NULL,0,900.00000000,0.00000000,0.00000000,0.00000000,900.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,900.00000000,0.00000000,900.00000000,NULL),(19,12,NULL,'2021-04-15 10:22:31','PR1702-0017',1,NULL,NULL,'','2017-02-16 01:46:15','2021-03-30','2021-04-14 12:00:00','2021-02-16 01:46:15',NULL,NULL,2,NULL,2,NULL,NULL,1,0,NULL,NULL,0,200.00000000,0.00000000,0.00000000,0.00000000,200.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,200.00000000,0.00000000,200.00000000,NULL),(20,26,NULL,'2020-12-10 12:24:22','PR1702-0018',1,NULL,NULL,'','2017-02-16 01:46:15','2020-11-13','2020-11-28 12:00:00','2020-02-16 01:46:15',NULL,NULL,1,NULL,1,NULL,NULL,1,0,NULL,NULL,0,830.00000000,0.00000000,0.00000000,0.00000000,830.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,830.00000000,0.00000000,830.00000000,NULL),(21,1,NULL,'2020-12-10 12:24:22','PR1702-0019',1,NULL,NULL,'','2017-02-16 01:46:15','2020-09-23','2020-10-08 12:00:00','2020-02-16 04:47:09',NULL,NULL,1,NULL,12,NULL,NULL,1,0,NULL,NULL,0,89.00000000,0.00000000,0.00000000,0.00000000,89.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,89.00000000,0.00000000,89.00000000,NULL),(22,26,NULL,'2020-12-10 12:24:22','PR1702-0020',1,NULL,NULL,'','2017-02-16 01:46:15','2020-11-13','2020-11-28 12:00:00','2020-02-16 01:46:15',NULL,NULL,1,NULL,1,NULL,NULL,0,0,NULL,NULL,0,70.00000000,0.00000000,0.00000000,0.00000000,70.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,70.00000000,0.00000000,70.00000000,'propale/PR1702-0020/PR1702-0020.pdf'),(23,12,NULL,'2021-04-15 10:22:31','PR1702-0021',1,NULL,NULL,'','2017-02-16 01:46:17','2021-04-03','2020-04-18 12:00:00','2020-02-17 16:07:18',NULL,NULL,2,NULL,12,NULL,NULL,1,0,NULL,NULL,0,715.00000000,0.00000000,0.00000000,0.00000000,715.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,715.00000000,0.00000000,715.00000000,NULL),(24,7,NULL,'2020-12-10 12:24:22','PR1702-0022',1,NULL,NULL,'','2017-02-16 01:46:17','2020-11-13','2020-11-28 12:00:00','2020-02-16 01:46:17',NULL,NULL,2,NULL,2,NULL,NULL,1,0,NULL,NULL,0,250.00000000,0.00000000,0.00000000,0.00000000,250.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,250.00000000,0.00000000,250.00000000,NULL),(25,3,NULL,'2021-07-11 17:49:28','PR1702-0023',1,NULL,NULL,'','2017-02-16 01:46:17','2021-07-09','2020-07-24 12:00:00','2021-02-16 01:46:17','2020-02-16 04:47:29','2021-02-16 04:47:29',1,NULL,1,12,12,4,0,NULL,NULL,0,1018.00000000,0.00000000,0.00000000,0.00000000,1018.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,1018.00000000,0.00000000,1018.00000000,NULL),(26,1,NULL,'2021-04-15 10:22:31','PR1702-0024',1,NULL,NULL,'','2017-02-16 01:46:17','2021-04-03','2020-04-18 12:00:00','2020-02-16 01:46:18',NULL,NULL,2,NULL,2,NULL,NULL,1,0,NULL,NULL,0,710.00000000,0.00000000,0.00000000,0.00000000,710.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,710.00000000,0.00000000,710.00000000,NULL),(27,6,NULL,'2020-12-10 12:24:22','PR1702-0025',1,NULL,NULL,'','2017-02-16 01:46:18','2020-11-12','2020-11-27 12:00:00','2020-02-16 01:46:18',NULL,NULL,1,NULL,1,NULL,NULL,1,0,NULL,NULL,0,300.00000000,0.00000000,0.00000000,0.00000000,300.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,300.00000000,0.00000000,300.00000000,NULL),(28,19,NULL,'2021-04-15 10:22:55','PR1702-0026',1,NULL,NULL,'','2017-02-16 01:46:18','2020-07-30','2020-08-14 12:00:00','2020-02-16 01:46:18','2020-02-16 04:46:31','2020-02-16 04:46:31',2,NULL,2,12,12,2,0,NULL,NULL,0,440.00000000,0.00000000,0.00000000,0.00000000,440.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,440.00000000,0.00000000,440.00000000,NULL),(29,1,NULL,'2021-04-15 10:22:55','PR1702-0027',1,NULL,NULL,'','2017-02-16 01:46:18','2020-07-23','2020-08-07 12:00:00','2020-02-16 01:46:18','2021-12-20 20:50:23','2021-12-20 20:50:23',2,NULL,2,12,12,2,0,NULL,NULL,0,1000.00000000,0.00000000,0.00000000,0.00000000,1000.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,1000.00000000,0.00000000,1000.00000000,'propale/PR1702-0027/PR1702-0027.pdf'),(30,1,NULL,'2021-07-11 17:49:28','PR1702-0028',1,NULL,NULL,'','2017-02-16 01:46:18','2021-05-01','2021-05-16 12:00:00','2020-02-16 01:46:18','2019-02-16 04:46:42','2020-02-16 04:46:42',2,NULL,2,12,12,3,0,NULL,NULL,0,1200.00000000,0.00000000,0.00000000,0.00000000,1200.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,1200.00000000,0.00000000,1200.00000000,NULL),(31,11,NULL,'2021-07-11 17:49:28','PR1702-0029',1,NULL,NULL,'','2017-02-16 01:46:18','2021-06-24','2021-07-09 12:00:00','2021-02-16 01:46:18',NULL,NULL,1,NULL,1,NULL,NULL,1,0,NULL,NULL,0,720.00000000,0.00000000,0.00000000,0.00000000,720.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,720.00000000,0.00000000,720.00000000,NULL),(32,19,NULL,'2020-12-10 12:24:22','PR1702-0030',1,NULL,NULL,'','2017-02-16 01:46:18','2020-11-12','2020-11-27 12:00:00','2020-02-16 01:46:18',NULL,NULL,2,NULL,2,NULL,NULL,1,0,NULL,NULL,0,608.00000000,0.00000000,0.00000000,0.00000000,608.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,608.00000000,0.00000000,608.00000000,NULL),(33,10,6,'2020-12-10 12:24:22','PR1909-0032',1,NULL,NULL,'','2019-09-27 17:07:40','2020-09-27','2020-10-12 12:00:00','2020-09-27 17:08:59',NULL,NULL,12,12,12,NULL,NULL,1,0,NULL,NULL,0,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL,'This is a private note','This is a public note','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',1,'EUR',1.00000000,0.00000000,0.00000000,0.00000000,'propale/PR1909-0032/PR1909-0032.pdf'),(34,10,6,'2021-04-15 10:22:55','PR1909-0033',1,NULL,NULL,'','2019-09-27 17:11:21','2020-09-27','2020-10-12 12:00:00','2020-09-27 17:13:13','2020-01-07 23:43:06','2020-01-07 23:43:06',12,12,12,12,12,2,0,NULL,NULL,0,10.00000000,0.00000000,0.00000000,0.00000000,10.00000000,NULL,NULL,NULL,NULL,NULL,'a & a
\r\nb < r','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',1,'EUR',1.00000000,10.00000000,0.00000000,10.00000000,'propale/PR1909-0033/PR1909-0033.pdf'),(35,10,NULL,'2020-12-10 12:24:22','(PROV35)',1,NULL,NULL,'','2019-09-27 17:53:44','2020-09-27','2020-10-12 12:00:00',NULL,NULL,NULL,12,NULL,NULL,NULL,NULL,0,0,NULL,NULL,0,5.00000000,0.00000000,0.00000000,0.00000000,5.00000000,NULL,NULL,NULL,NULL,'','','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',1,'EUR',1.00000000,5.00000000,0.00000000,5.00000000,'propale/(PROV35)/(PROV35).pdf'),(36,1,NULL,'2021-04-15 10:22:55','PR2001-0034',1,NULL,NULL,'','2020-01-01 23:55:35','2021-01-01','2021-01-16 12:00:00','2021-01-19 14:24:22','2021-01-19 14:24:27','2021-01-19 14:24:27',12,NULL,12,12,12,2,0,NULL,NULL,0,4.00000000,0.24000000,0.00000000,0.00000000,4.24000000,NULL,NULL,NULL,NULL,'','','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',1,'EUR',1.00000000,4.00000000,0.24000000,4.24000000,'propale/PR2001-0034/PR2001-0034.pdf'),(37,10,NULL,'2021-04-15 10:22:31','(PROV37)',1,NULL,NULL,'','2020-01-06 00:44:16','2021-01-05','2021-01-20 12:00:00',NULL,NULL,NULL,12,NULL,NULL,NULL,NULL,0,0,NULL,NULL,0,10.00000000,0.00000000,0.00000000,0.00000000,10.00000000,NULL,NULL,NULL,NULL,'','','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',1,'EUR',1.00000000,10.00000000,0.00000000,10.00000000,'propale/(PROV37)/(PROV37).pdf'),(38,30,NULL,'2021-04-15 10:22:31','(PROV38)',1,NULL,NULL,'','2020-01-13 17:25:28','2021-01-13','2021-01-28 12:00:00',NULL,NULL,NULL,12,NULL,NULL,NULL,NULL,0,0,NULL,NULL,0,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL,'','','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',1,'EUR',1.00000000,0.00000000,0.00000000,0.00000000,'propale/(PROV38)/(PROV38).pdf'); +INSERT INTO `llx_propal` VALUES (1,2,NULL,'2021-07-11 17:49:28','PR1007-0001',1,NULL,NULL,'','2012-07-09 01:33:49','2021-07-09','2020-07-24 12:00:00','2020-08-08 14:24:18',NULL,NULL,1,NULL,1,NULL,NULL,1,0,NULL,NULL,0,30.00000000,3.84000000,0.00000000,0.00000000,33.84000000,NULL,NULL,1,0,'','','azur',NULL,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL),(2,1,NULL,'2021-07-11 17:49:28','PR1007-0002',1,NULL,NULL,'','2012-07-10 02:11:44','2021-07-10','2020-07-25 12:00:00','2021-07-10 02:12:55','2020-07-20 15:23:12','2020-07-20 15:23:12',1,NULL,1,1,1,2,0,NULL,NULL,0,10.00000000,0.00000000,0.00000000,0.00000000,10.00000000,NULL,NULL,1,1,'','','azur',NULL,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL),(3,4,NULL,'2022-02-07 13:37:54','PR1007-0003',1,NULL,NULL,'','2012-07-18 11:35:11','2021-07-18','2021-08-02 12:00:00','2021-07-18 11:36:18','2020-07-20 15:21:15','2021-07-20 15:21:15',1,NULL,1,1,1,2,0,NULL,NULL,0,10.00000000,0.00000000,0.00000000,0.00000000,10.00000000,NULL,NULL,1,0,'','','azur',NULL,NULL,NULL,NULL,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL),(5,19,NULL,'2021-04-15 10:22:31','PR1302-0005',1,NULL,NULL,'','2015-02-17 15:39:56','2021-02-17','2021-03-04 12:00:00','2020-11-15 23:27:10',NULL,NULL,1,NULL,12,NULL,NULL,1,0,NULL,NULL,0,10.00000000,2.00000000,0.00000000,0.00000000,12.00000000,NULL,NULL,1,0,'','','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL),(6,19,NULL,'2021-04-15 10:22:31','PR1302-0006',1,NULL,NULL,'','2015-02-17 15:40:12','2021-02-17','2021-03-04 12:00:00',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,0,0,NULL,NULL,0,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,1,0,'','','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL),(7,19,NULL,'2021-04-15 10:22:31','PR1302-0007',1,NULL,NULL,'','2015-02-17 15:41:15','2021-02-17','2021-03-04 12:00:00','2020-01-29 21:49:33',NULL,NULL,1,NULL,12,NULL,NULL,1,0,NULL,NULL,0,400.00000000,0.00000000,0.00000000,0.00000000,400.00000000,NULL,NULL,1,0,'','','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,400.00000000,0.00000000,400.00000000,NULL,NULL,NULL),(8,19,NULL,'2021-04-15 10:22:31','PR1302-0008',1,NULL,NULL,'','2015-02-17 15:43:39','2021-02-17','2021-03-04 12:00:00',NULL,NULL,NULL,1,NULL,NULL,NULL,NULL,0,0,NULL,NULL,0,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,1,0,'','','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,NULL,NULL,NULL,NULL,1.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL),(10,7,4,'2022-02-07 13:37:54','PR1909-0031',1,NULL,NULL,'','2017-11-15 23:37:08','2021-11-15','2021-11-30 12:00:00','2022-09-27 16:54:30',NULL,NULL,12,NULL,12,NULL,NULL,1,0,NULL,NULL,0,10.00000000,0.00000000,0.00000000,0.00000000,10.00000000,NULL,NULL,1,3,'','','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',NULL,NULL,1.00000000,10.00000000,0.00000000,10.00000000,'propale/PR1909-0031/PR1909-0031.pdf',NULL,NULL),(11,1,NULL,'2021-07-11 17:49:28','PR1702-0009',1,NULL,NULL,'','2017-02-16 01:44:58','2021-05-13','2021-05-28 12:00:00','2021-02-16 01:44:58',NULL,NULL,1,NULL,1,NULL,NULL,1,0,NULL,NULL,0,60.00000000,0.00000000,0.00000000,0.00000000,60.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,60.00000000,0.00000000,60.00000000,NULL,NULL,NULL),(12,7,NULL,'2021-07-11 17:49:28','PR1702-0010',1,NULL,NULL,'','2017-02-16 01:45:44','2021-06-24','2021-07-09 12:00:00','2021-02-16 01:45:44',NULL,NULL,2,NULL,2,NULL,NULL,1,0,NULL,NULL,0,832.00000000,0.00000000,0.00000000,0.00000000,832.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,832.00000000,0.00000000,832.00000000,NULL,NULL,NULL),(13,26,NULL,'2021-04-15 10:22:31','PR1702-0011',1,NULL,NULL,'','2017-02-16 01:46:15','2021-04-03','2020-04-18 12:00:00','2021-02-16 01:46:15',NULL,NULL,1,NULL,1,NULL,NULL,1,0,NULL,NULL,0,242.00000000,0.00000000,0.00000000,0.00000000,242.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,242.00000000,0.00000000,242.00000000,NULL,NULL,NULL),(14,3,NULL,'2021-07-11 17:49:28','PR1702-0012',1,NULL,NULL,'','2017-02-16 01:46:15','2021-06-19','2021-07-04 12:00:00','2021-02-16 01:46:15',NULL,NULL,2,NULL,2,NULL,NULL,1,0,NULL,NULL,0,245.00000000,0.00000000,0.00000000,0.00000000,245.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,245.00000000,0.00000000,245.00000000,NULL,NULL,NULL),(15,26,NULL,'2021-07-11 17:49:28','PR1702-0013',1,NULL,NULL,'','2017-02-16 01:46:15','2021-05-01','2021-05-16 12:00:00','2020-02-16 01:46:15',NULL,NULL,2,NULL,2,NULL,NULL,1,0,NULL,NULL,0,940.00000000,0.00000000,0.00000000,0.00000000,940.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,940.00000000,0.00000000,940.00000000,NULL,NULL,NULL),(16,1,NULL,'2021-07-11 17:49:28','PR1702-0014',1,NULL,NULL,'','2017-02-16 01:46:15','2021-05-13','2021-05-28 12:00:00','2021-02-16 01:46:15',NULL,NULL,2,NULL,2,NULL,NULL,1,0,NULL,NULL,0,125.00000000,0.00000000,0.00000000,0.00000000,125.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,125.00000000,0.00000000,125.00000000,NULL,NULL,NULL),(17,1,NULL,'2022-02-07 13:37:54','PR1702-0015',1,NULL,NULL,'','2017-02-16 01:46:15','2021-07-23','2021-08-07 12:00:00','2021-02-16 01:46:15',NULL,NULL,1,NULL,1,NULL,NULL,1,0,NULL,NULL,0,163.00000000,0.00000000,0.00000000,0.00000000,163.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,163.00000000,0.00000000,163.00000000,NULL,NULL,NULL),(18,26,NULL,'2021-04-15 10:22:31','PR1702-0016',1,NULL,NULL,'','2017-02-16 01:46:15','2021-02-13','2021-02-28 12:00:00','2021-02-16 01:46:15',NULL,NULL,2,NULL,2,NULL,NULL,1,0,NULL,NULL,0,900.00000000,0.00000000,0.00000000,0.00000000,900.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,900.00000000,0.00000000,900.00000000,NULL,NULL,NULL),(19,12,NULL,'2021-04-15 10:22:31','PR1702-0017',1,NULL,NULL,'','2017-02-16 01:46:15','2021-03-30','2021-04-14 12:00:00','2021-02-16 01:46:15',NULL,NULL,2,NULL,2,NULL,NULL,1,0,NULL,NULL,0,200.00000000,0.00000000,0.00000000,0.00000000,200.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,200.00000000,0.00000000,200.00000000,NULL,NULL,NULL),(20,26,NULL,'2022-02-07 13:37:54','PR1702-0018',1,NULL,NULL,'','2017-02-16 01:46:15','2021-11-13','2021-11-28 12:00:00','2021-02-16 01:46:15',NULL,NULL,1,NULL,1,NULL,NULL,1,0,NULL,NULL,0,830.00000000,0.00000000,0.00000000,0.00000000,830.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,830.00000000,0.00000000,830.00000000,NULL,NULL,NULL),(21,1,NULL,'2022-02-07 13:37:54','PR1702-0019',1,NULL,NULL,'','2017-02-16 01:46:15','2021-09-23','2021-10-08 12:00:00','2021-02-16 04:47:09',NULL,NULL,1,NULL,12,NULL,NULL,1,0,NULL,NULL,0,89.00000000,0.00000000,0.00000000,0.00000000,89.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,89.00000000,0.00000000,89.00000000,NULL,NULL,NULL),(22,26,NULL,'2022-02-07 13:37:54','PR1702-0020',1,NULL,NULL,'','2017-02-16 01:46:15','2021-11-13','2021-11-28 12:00:00','2021-02-16 01:46:15',NULL,NULL,1,NULL,1,NULL,NULL,0,0,NULL,NULL,0,70.00000000,0.00000000,0.00000000,0.00000000,70.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,70.00000000,0.00000000,70.00000000,'propale/PR1702-0020/PR1702-0020.pdf',NULL,NULL),(23,12,NULL,'2021-04-15 10:22:31','PR1702-0021',1,NULL,NULL,'','2017-02-16 01:46:17','2021-04-03','2020-04-18 12:00:00','2020-02-17 16:07:18',NULL,NULL,2,NULL,12,NULL,NULL,1,0,NULL,NULL,0,715.00000000,0.00000000,0.00000000,0.00000000,715.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,715.00000000,0.00000000,715.00000000,NULL,NULL,NULL),(24,7,NULL,'2022-02-07 13:37:54','PR1702-0022',1,NULL,NULL,'','2017-02-16 01:46:17','2021-11-13','2021-11-28 12:00:00','2021-02-16 01:46:17',NULL,NULL,2,NULL,2,NULL,NULL,1,0,NULL,NULL,0,250.00000000,0.00000000,0.00000000,0.00000000,250.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,250.00000000,0.00000000,250.00000000,NULL,NULL,NULL),(25,3,NULL,'2021-07-11 17:49:28','PR1702-0023',1,NULL,NULL,'','2017-02-16 01:46:17','2021-07-09','2020-07-24 12:00:00','2021-02-16 01:46:17','2020-02-16 04:47:29','2021-02-16 04:47:29',1,NULL,1,12,12,4,0,NULL,NULL,0,1018.00000000,0.00000000,0.00000000,0.00000000,1018.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,1018.00000000,0.00000000,1018.00000000,NULL,NULL,NULL),(26,1,NULL,'2021-04-15 10:22:31','PR1702-0024',1,NULL,NULL,'','2017-02-16 01:46:17','2021-04-03','2020-04-18 12:00:00','2020-02-16 01:46:18',NULL,NULL,2,NULL,2,NULL,NULL,1,0,NULL,NULL,0,710.00000000,0.00000000,0.00000000,0.00000000,710.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,710.00000000,0.00000000,710.00000000,NULL,NULL,NULL),(27,6,NULL,'2022-02-07 13:37:54','PR1702-0025',1,NULL,NULL,'','2017-02-16 01:46:18','2021-11-12','2021-11-27 12:00:00','2021-02-16 01:46:18',NULL,NULL,1,NULL,1,NULL,NULL,1,0,NULL,NULL,0,300.00000000,0.00000000,0.00000000,0.00000000,300.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,300.00000000,0.00000000,300.00000000,NULL,NULL,NULL),(28,19,NULL,'2022-02-07 13:37:54','PR1702-0026',1,NULL,NULL,'','2017-02-16 01:46:18','2021-07-30','2021-08-14 12:00:00','2021-02-16 01:46:18','2020-02-16 04:46:31','2021-02-16 04:46:31',2,NULL,2,12,12,2,0,NULL,NULL,0,440.00000000,0.00000000,0.00000000,0.00000000,440.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,440.00000000,0.00000000,440.00000000,NULL,NULL,NULL),(29,1,NULL,'2022-02-07 13:37:54','PR1702-0027',1,NULL,NULL,'','2017-02-16 01:46:18','2021-07-23','2021-08-07 12:00:00','2021-02-16 01:46:18','2021-12-20 20:50:23','2022-12-20 20:50:23',2,NULL,2,12,12,2,0,NULL,NULL,0,1000.00000000,0.00000000,0.00000000,0.00000000,1000.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,1000.00000000,0.00000000,1000.00000000,'propale/PR1702-0027/PR1702-0027.pdf',NULL,NULL),(30,1,NULL,'2021-07-11 17:49:28','PR1702-0028',1,NULL,NULL,'','2017-02-16 01:46:18','2021-05-01','2021-05-16 12:00:00','2020-02-16 01:46:18','2019-02-16 04:46:42','2020-02-16 04:46:42',2,NULL,2,12,12,3,0,NULL,NULL,0,1200.00000000,0.00000000,0.00000000,0.00000000,1200.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,1200.00000000,0.00000000,1200.00000000,NULL,NULL,NULL),(31,11,NULL,'2021-07-11 17:49:28','PR1702-0029',1,NULL,NULL,'','2017-02-16 01:46:18','2021-06-24','2021-07-09 12:00:00','2021-02-16 01:46:18',NULL,NULL,1,NULL,1,NULL,NULL,1,0,NULL,NULL,0,720.00000000,0.00000000,0.00000000,0.00000000,720.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,720.00000000,0.00000000,720.00000000,NULL,NULL,NULL),(32,19,NULL,'2022-02-07 13:37:54','PR1702-0030',1,NULL,NULL,'','2017-02-16 01:46:18','2021-11-12','2021-11-27 12:00:00','2021-02-16 01:46:18',NULL,NULL,2,NULL,2,NULL,NULL,1,0,NULL,NULL,0,608.00000000,0.00000000,0.00000000,0.00000000,608.00000000,NULL,NULL,3,3,'','','',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',0,'EUR',1.00000000,608.00000000,0.00000000,608.00000000,NULL,NULL,NULL),(33,10,6,'2022-02-07 13:37:54','PR1909-0032',1,NULL,NULL,'','2019-09-27 17:07:40','2021-09-27','2021-10-12 12:00:00','2021-09-27 17:08:59',NULL,NULL,12,12,12,NULL,NULL,1,0,NULL,NULL,0,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL,'This is a private note','This is a public note','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',1,'EUR',1.00000000,0.00000000,0.00000000,0.00000000,'propale/PR1909-0032/PR1909-0032.pdf',NULL,NULL),(34,10,6,'2022-02-07 13:37:54','PR1909-0033',1,NULL,NULL,'','2019-09-27 17:11:21','2021-09-27','2021-10-12 12:00:00','2021-09-27 17:13:13','2020-01-07 23:43:06','2022-01-07 23:43:06',12,12,12,12,12,2,0,NULL,NULL,0,10.00000000,0.00000000,0.00000000,0.00000000,10.00000000,NULL,NULL,NULL,NULL,NULL,'a & a
\r\nb < r','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',1,'EUR',1.00000000,10.00000000,0.00000000,10.00000000,'propale/PR1909-0033/PR1909-0033.pdf',NULL,NULL),(35,10,NULL,'2022-02-07 13:37:54','(PROV35)',1,NULL,NULL,'','2019-09-27 17:53:44','2021-09-27','2021-10-12 12:00:00',NULL,NULL,NULL,12,NULL,NULL,NULL,NULL,0,0,NULL,NULL,0,5.00000000,0.00000000,0.00000000,0.00000000,5.00000000,NULL,NULL,NULL,NULL,'','','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',1,'EUR',1.00000000,5.00000000,0.00000000,5.00000000,'propale/(PROV35)/(PROV35).pdf',NULL,NULL),(36,1,NULL,'2022-02-07 13:37:54','PR2001-0034',1,NULL,NULL,'','2020-01-01 23:55:35','2022-01-01','2022-01-16 12:00:00','2022-01-19 14:24:22','2021-01-19 14:24:27','2022-01-19 14:24:27',12,NULL,12,12,12,2,0,NULL,NULL,0,4.00000000,0.24000000,0.00000000,0.00000000,4.24000000,NULL,NULL,NULL,NULL,'','','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',1,'EUR',1.00000000,4.00000000,0.24000000,4.24000000,'propale/PR2001-0034/PR2001-0034.pdf',NULL,NULL),(37,10,NULL,'2022-02-07 13:37:54','(PROV37)',1,NULL,NULL,'','2020-01-06 00:44:16','2022-01-05','2022-01-20 12:00:00',NULL,NULL,NULL,12,NULL,NULL,NULL,NULL,0,0,NULL,NULL,0,10.00000000,0.00000000,0.00000000,0.00000000,10.00000000,NULL,NULL,NULL,NULL,'','','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',1,'EUR',1.00000000,10.00000000,0.00000000,10.00000000,'propale/(PROV37)/(PROV37).pdf',NULL,NULL),(38,30,NULL,'2022-02-07 13:37:54','(PROV38)',1,NULL,NULL,'','2020-01-13 17:25:28','2022-01-13','2022-01-28 12:00:00',NULL,NULL,NULL,12,NULL,NULL,NULL,NULL,0,0,NULL,NULL,0,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL,'','','azur',NULL,NULL,NULL,0,NULL,0,NULL,NULL,0,'',1,'EUR',1.00000000,0.00000000,0.00000000,0.00000000,'propale/(PROV38)/(PROV38).pdf',NULL,NULL); /*!40000 ALTER TABLE `llx_propal` ENABLE KEYS */; UNLOCK TABLES; @@ -10582,7 +11035,7 @@ CREATE TABLE `llx_propaldet` ( `rang` int(11) DEFAULT 0, `fk_unit` int(11) DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_subprice` double(24,8) DEFAULT 0.00000000, `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000, `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000, @@ -10989,7 +11442,7 @@ CREATE TABLE `llx_rights_def` ( LOCK TABLES `llx_rights_def` WRITE; /*!40000 ALTER TABLE `llx_rights_def` DISABLE KEYS */; -INSERT INTO `llx_rights_def` VALUES (11,'Read invoices','facture',1,'lire',NULL,'a',0,0,0),(11,'Lire les factures','facture',2,'lire',NULL,'a',1,10,0),(12,'Create and update invoices','facture',1,'creer',NULL,'a',0,0,0),(12,'Creer/modifier les factures','facture',2,'creer',NULL,'a',0,10,0),(13,'Devalidate invoices','facture',1,'invoice_advance','unvalidate','a',0,0,0),(13,'Dévalider les factures','facture',2,'invoice_advance','unvalidate','a',0,10,0),(14,'Validate invoices','facture',1,'invoice_advance','validate','a',0,0,0),(14,'Valider les factures','facture',2,'valider',NULL,'a',0,10,0),(15,'Send invoices by email','facture',1,'invoice_advance','send','a',0,0,0),(15,'Envoyer les factures par mail','facture',2,'invoice_advance','send','a',0,10,0),(16,'Issue payments on invoices','facture',1,'paiement',NULL,'a',0,0,0),(16,'Emettre des paiements sur les factures','facture',2,'paiement',NULL,'a',0,10,0),(19,'Delete invoices','facture',1,'supprimer',NULL,'a',0,0,0),(19,'Supprimer les factures','facture',2,'supprimer',NULL,'a',0,10,0),(21,'Lire les propositions commerciales','propale',1,'lire',NULL,'r',1,22,0),(21,'Lire les propositions commerciales','propale',2,'lire',NULL,'r',1,22,0),(22,'Creer/modifier les propositions commerciales','propale',1,'creer',NULL,'w',0,22,0),(22,'Creer/modifier les propositions commerciales','propale',2,'creer',NULL,'w',0,22,0),(24,'Valider les propositions commerciales','propale',1,'propal_advance','validate','d',0,22,0),(24,'Valider les propositions commerciales','propale',2,'valider',NULL,'d',0,22,0),(25,'Envoyer les propositions commerciales aux clients','propale',1,'propal_advance','send','d',0,22,0),(25,'Envoyer les propositions commerciales aux clients','propale',2,'propal_advance','send','d',0,22,0),(26,'Cloturer les propositions commerciales','propale',1,'propal_advance','close','d',0,22,0),(26,'Cloturer les propositions commerciales','propale',2,'propal_advance','close','d',0,22,0),(27,'Supprimer les propositions commerciales','propale',1,'supprimer',NULL,'d',0,22,0),(27,'Supprimer les propositions commerciales','propale',2,'supprimer',NULL,'d',0,22,0),(28,'Exporter les propositions commerciales et attributs','propale',1,'export',NULL,'r',0,22,0),(28,'Exporter les propositions commerciales et attributs','propale',2,'export',NULL,'r',0,22,0),(31,'Lire les produits','produit',1,'lire',NULL,'r',1,25,0),(31,'Lire les produits','produit',2,'lire',NULL,'r',1,25,0),(32,'Creer/modifier les produits','produit',1,'creer',NULL,'w',0,25,0),(32,'Creer/modifier les produits','produit',2,'creer',NULL,'w',0,25,0),(34,'Supprimer les produits','produit',1,'supprimer',NULL,'d',0,25,0),(34,'Supprimer les produits','produit',2,'supprimer',NULL,'d',0,25,0),(38,'Exporter les produits','produit',1,'export',NULL,'r',0,25,0),(38,'Exporter les produits','produit',2,'export',NULL,'r',0,25,0),(39,'Ignore minimum price','produit',1,'ignore_price_min_advance',NULL,'r',0,25,0),(41,'Read projects and tasks (shared projects or projects I am contact for). Can also enter time consumed on assigned tasks (timesheet)','projet',1,'lire',NULL,'r',1,14,0),(42,'Create/modify projects and tasks (shared projects or projects I am contact for)','projet',1,'creer',NULL,'w',0,14,0),(44,'Delete project and tasks (shared projects or projects I am contact for)','projet',1,'supprimer',NULL,'d',0,14,0),(45,'Export projects','projet',1,'export',NULL,'d',0,14,0),(61,'Lire les fiches d\'intervention','ficheinter',1,'lire',NULL,'r',1,41,0),(62,'Creer/modifier les fiches d\'intervention','ficheinter',1,'creer',NULL,'w',0,41,0),(64,'Supprimer les fiches d\'intervention','ficheinter',1,'supprimer',NULL,'d',0,41,0),(67,'Exporter les fiches interventions','ficheinter',1,'export',NULL,'r',0,41,0),(68,'Envoyer les fiches d\'intervention par courriel','ficheinter',1,'ficheinter_advance','send','r',0,41,0),(69,'Valider les fiches d\'intervention ','ficheinter',1,'ficheinter_advance','validate','a',0,41,0),(70,'Dévalider les fiches d\'intervention','ficheinter',1,'ficheinter_advance','unvalidate','a',0,41,0),(71,'Read members\' card','adherent',1,'lire',NULL,'r',0,55,0),(72,'Create/modify members (need also user module permissions if member linked to a user)','adherent',1,'creer',NULL,'w',0,55,0),(74,'Remove members','adherent',1,'supprimer',NULL,'d',0,55,0),(75,'Setup types of membership','adherent',1,'configurer',NULL,'w',0,55,0),(76,'Export members','adherent',1,'export',NULL,'r',0,55,0),(78,'Read subscriptions','adherent',1,'cotisation','lire','r',0,55,0),(79,'Create/modify/remove subscriptions','adherent',1,'cotisation','creer','w',0,55,0),(81,'Read sales orders','commande',1,'lire',NULL,'r',0,0,0),(82,'Creeat/modify sales orders','commande',1,'creer',NULL,'w',0,0,0),(84,'Validate sales orders','commande',1,'order_advance','validate','d',0,0,0),(86,'Send sale orders by email','commande',1,'order_advance','send','d',0,0,0),(87,'Close sale orders','commande',1,'order_advance','close','d',0,0,0),(88,'Cancel sale orders','commande',1,'order_advance','annuler','d',0,0,0),(89,'Delete sales orders','commande',1,'supprimer',NULL,'d',0,0,0),(91,'Lire les charges','tax',1,'charges','lire','r',0,50,0),(91,'Lire les charges','tax',2,'charges','lire','r',1,50,0),(92,'Creer/modifier les charges','tax',1,'charges','creer','w',0,50,0),(92,'Creer/modifier les charges','tax',2,'charges','creer','w',0,50,0),(93,'Supprimer les charges','tax',1,'charges','supprimer','d',0,50,0),(93,'Supprimer les charges','tax',2,'charges','supprimer','d',0,50,0),(94,'Exporter les charges','tax',1,'charges','export','r',0,50,0),(94,'Exporter les charges','tax',2,'charges','export','r',0,50,0),(101,'Lire les expeditions','expedition',1,'lire',NULL,'r',0,40,0),(102,'Creer modifier les expeditions','expedition',1,'creer',NULL,'w',0,40,0),(104,'Valider les expeditions','expedition',1,'shipping_advance','validate','d',0,40,0),(105,'Envoyer les expeditions aux clients','expedition',1,'shipping_advance','send','d',0,40,0),(106,'Exporter les expeditions','expedition',1,'shipment','export','r',0,40,0),(109,'Supprimer les expeditions','expedition',1,'supprimer',NULL,'d',0,40,0),(111,'Read bank account and transactions','banque',1,'lire',NULL,'r',0,0,0),(111,'Lire les comptes bancaires','banque',2,'lire',NULL,'r',1,51,0),(112,'Creer/modifier montant/supprimer ecriture bancaire','banque',1,'modifier',NULL,'w',0,0,0),(112,'Creer/modifier montant/supprimer ecriture bancaire','banque',2,'modifier',NULL,'w',0,51,0),(113,'Configurer les comptes bancaires (creer, gerer categories)','banque',1,'configurer',NULL,'a',0,0,0),(113,'Configurer les comptes bancaires (creer, gerer categories)','banque',2,'configurer',NULL,'a',0,51,0),(114,'Rapprocher les ecritures bancaires','banque',1,'consolidate',NULL,'w',0,0,0),(114,'Rapprocher les ecritures bancaires','banque',2,'consolidate',NULL,'w',0,51,0),(115,'Exporter transactions et releves','banque',1,'export',NULL,'r',0,0,0),(115,'Exporter transactions et releves','banque',2,'export',NULL,'r',0,51,0),(116,'Virements entre comptes','banque',1,'transfer',NULL,'w',0,0,0),(116,'Virements entre comptes','banque',2,'transfer',NULL,'w',0,51,0),(117,'Gerer les envois de cheques','banque',1,'cheque',NULL,'w',0,0,0),(117,'Gerer les envois de cheques','banque',2,'cheque',NULL,'w',0,51,0),(121,'Read third parties','societe',1,'lire',NULL,'r',0,0,0),(121,'Lire les societes','societe',2,'lire',NULL,'r',1,9,0),(122,'Create and update third parties','societe',1,'creer',NULL,'w',0,0,0),(122,'Creer modifier les societes','societe',2,'creer',NULL,'w',0,9,0),(125,'Delete third parties','societe',1,'supprimer',NULL,'d',0,0,0),(125,'Supprimer les societes','societe',2,'supprimer',NULL,'d',0,9,0),(126,'Export third parties','societe',1,'export',NULL,'r',0,0,0),(126,'Exporter les societes','societe',2,'export',NULL,'r',0,9,0),(141,'Read all projects and tasks (also private projects I am not contact for)','projet',1,'all','lire','r',0,14,0),(142,'Create/modify all projects and tasks (also private projects I am not contact for)','projet',1,'all','creer','w',0,14,0),(144,'Delete all projects and tasks (also private projects I am not contact for)','projet',1,'all','supprimer','d',0,14,0),(151,'Read withdrawals','prelevement',1,'bons','lire','r',1,52,0),(152,'Create/modify a withdrawals','prelevement',1,'bons','creer','w',0,52,0),(153,'Send withdrawals to bank','prelevement',1,'bons','send','a',0,52,0),(154,'credit/refuse withdrawals','prelevement',1,'bons','credit','a',0,52,0),(161,'Lire les contrats','contrat',1,'lire',NULL,'r',1,35,0),(162,'Creer / modifier les contrats','contrat',1,'creer',NULL,'w',0,35,0),(163,'Activer un service d\'un contrat','contrat',1,'activer',NULL,'w',0,35,0),(164,'Desactiver un service d\'un contrat','contrat',1,'desactiver',NULL,'w',0,35,0),(165,'Supprimer un contrat','contrat',1,'supprimer',NULL,'d',0,35,0),(167,'Export contracts','contrat',1,'export',NULL,'r',0,35,0),(221,'Consulter les mailings','mailing',1,'lire',NULL,'r',1,11,0),(221,'Consulter les mailings','mailing',2,'lire',NULL,'r',1,11,0),(222,'Creer/modifier les mailings (sujet, destinataires...)','mailing',1,'creer',NULL,'w',0,11,0),(222,'Creer/modifier les mailings (sujet, destinataires...)','mailing',2,'creer',NULL,'w',0,11,0),(223,'Valider les mailings (permet leur envoi)','mailing',1,'valider',NULL,'w',0,11,0),(223,'Valider les mailings (permet leur envoi)','mailing',2,'valider',NULL,'w',0,11,0),(229,'Supprimer les mailings','mailing',1,'supprimer',NULL,'d',0,11,0),(229,'Supprimer les mailings','mailing',2,'supprimer',NULL,'d',0,11,0),(237,'View recipients and info','mailing',1,'mailing_advance','recipient','r',0,11,0),(237,'View recipients and info','mailing',2,'mailing_advance','recipient','r',0,11,0),(238,'Manually send mailings','mailing',1,'mailing_advance','send','w',0,11,0),(238,'Manually send mailings','mailing',2,'mailing_advance','send','w',0,11,0),(239,'Delete mailings after validation and/or sent','mailing',1,'mailing_advance','delete','d',0,11,0),(239,'Delete mailings after validation and/or sent','mailing',2,'mailing_advance','delete','d',0,11,0),(241,'Lire les categories','categorie',1,'lire',NULL,'r',1,20,0),(242,'Creer/modifier les categories','categorie',1,'creer',NULL,'w',0,20,0),(243,'Supprimer les categories','categorie',1,'supprimer',NULL,'d',0,20,0),(251,'Consulter les autres utilisateurs','user',1,'user','lire','r',0,0,0),(252,'Consulter les permissions des autres utilisateurs','user',1,'user_advance','readperms','r',0,0,0),(253,'Creer/modifier utilisateurs internes et externes','user',1,'user','creer','w',0,0,0),(254,'Creer/modifier utilisateurs externes seulement','user',1,'user_advance','write','w',0,0,0),(255,'Modifier le mot de passe des autres utilisateurs','user',1,'user','password','w',0,0,0),(256,'Supprimer ou desactiver les autres utilisateurs','user',1,'user','supprimer','d',0,0,0),(262,'Read all third parties (and their objects) by internal users (otherwise only if commercial contact). Not effective for external users (limited to themselves).','societe',1,'client','voir','r',0,0,0),(262,'Consulter tous les tiers par utilisateurs internes (sinon uniquement si contact commercial). Non effectif pour utilisateurs externes (tjs limités à eux-meme).','societe',2,'client','voir','r',1,9,0),(281,'Read contacts','societe',1,'contact','lire','r',0,0,0),(281,'Lire les contacts','societe',2,'contact','lire','r',1,9,0),(282,'Create and update contact','societe',1,'contact','creer','w',0,0,0),(282,'Creer modifier les contacts','societe',2,'contact','creer','w',0,9,0),(283,'Delete contacts','societe',1,'contact','supprimer','d',0,0,0),(283,'Supprimer les contacts','societe',2,'contact','supprimer','d',0,9,0),(286,'Export contacts','societe',1,'contact','export','d',0,0,0),(286,'Exporter les contacts','societe',2,'contact','export','d',0,9,0),(301,'Read barcodes','barcode',1,'lire_advance',NULL,'r',1,0,0),(302,'Create/modify barcodes','barcode',1,'creer_advance',NULL,'w',0,0,0),(331,'Lire les bookmarks','bookmark',1,'lire',NULL,'r',0,50,0),(332,'Creer/modifier les bookmarks','bookmark',1,'creer',NULL,'r',0,50,0),(333,'Supprimer les bookmarks','bookmark',1,'supprimer',NULL,'r',0,50,0),(341,'Consulter ses propres permissions','user',1,'self_advance','readperms','r',0,0,0),(342,'Creer/modifier ses propres infos utilisateur','user',1,'self','creer','w',0,0,0),(343,'Modifier son propre mot de passe','user',1,'self','password','w',0,0,0),(344,'Modifier ses propres permissions','user',1,'self_advance','writeperms','w',0,0,0),(351,'Consulter les groupes','user',1,'group_advance','read','r',0,0,0),(352,'Consulter les permissions des groupes','user',1,'group_advance','readperms','r',0,0,0),(353,'Creer/modifier les groupes et leurs permissions','user',1,'group_advance','write','w',0,0,0),(354,'Supprimer ou desactiver les groupes','user',1,'group_advance','delete','d',0,0,0),(358,'Exporter les utilisateurs','user',1,'user','export','r',0,0,0),(511,'Read employee salaries and payments (yours and your subordinates)','salaries',1,'read',NULL,'r',0,0,0),(512,'Create/modify payments of empoyee salaries','salaries',1,'write',NULL,'w',0,0,0),(514,'Delete payments of employee salary','salaries',1,'delete',NULL,'d',0,0,0),(517,'Read salaries and payments of all employees','salaries',1,'readall',NULL,'r',0,0,0),(519,'Export payments of employee salaries','salaries',1,'export',NULL,'r',0,0,0),(520,'Read loans','loan',1,'read',NULL,'r',0,50,0),(521,'Read loans','loan',1,'read',NULL,'r',0,50,0),(522,'Create/modify loans','loan',1,'write',NULL,'w',0,50,0),(524,'Delete loans','loan',1,'delete',NULL,'d',0,50,0),(525,'Access loan calculator','loan',1,'calc',NULL,'r',0,50,0),(527,'Export loans','loan',1,'export',NULL,'r',0,50,0),(531,'Read services','service',1,'lire',NULL,'r',0,0,0),(532,'Create/modify services','service',1,'creer',NULL,'w',0,0,0),(534,'Delete les services','service',1,'supprimer',NULL,'d',0,0,0),(538,'Export services','service',1,'export',NULL,'r',0,0,0),(561,'Read bank transfer payment orders','paymentbybanktransfer',1,'read',NULL,'r',0,52,0),(562,'Create/modify a bank transfer payment order','paymentbybanktransfer',1,'create',NULL,'w',0,52,0),(563,'Send/Transmit bank transfer payment order','paymentbybanktransfer',1,'send',NULL,'a',0,52,0),(564,'Record Debits/Rejects of bank transfer payment order','paymentbybanktransfer',1,'debit',NULL,'a',0,52,0),(651,'Read bom of Bom','bom',1,'read',NULL,'w',0,0,0),(652,'Create/Update bom of Bom','bom',1,'write',NULL,'w',0,0,0),(653,'Delete bom of Bom','bom',1,'delete',NULL,'w',0,0,0),(661,'Read Manufacturing Order','mrp',1,'read',NULL,'w',0,0,0),(662,'Create/Update Manufacturing Order','mrp',1,'write',NULL,'w',0,0,0),(663,'Delete Manufacturing Order','mrp',1,'delete',NULL,'w',0,0,0),(701,'Lire les dons','don',1,'lire',NULL,'r',1,50,0),(701,'Lire les dons','don',2,'lire',NULL,'r',1,50,0),(702,'Creer/modifier les dons','don',1,'creer',NULL,'w',0,50,0),(702,'Creer/modifier les dons','don',2,'creer',NULL,'w',0,50,0),(703,'Supprimer les dons','don',1,'supprimer',NULL,'d',0,50,0),(703,'Supprimer les dons','don',2,'supprimer',NULL,'d',0,50,0),(750,'Read job positions to fill and candidatures','recruitment',1,'recruitmentjobposition','read','w',0,0,0),(751,'Create/Update job positions to fill and candidatures','recruitment',1,'recruitmentjobposition','write','w',0,0,0),(752,'Delete Job positions to fill and candidatures','recruitment',1,'recruitmentjobposition','delete','w',0,0,0),(771,'Read expense reports (yours and your subordinates)','expensereport',1,'lire',NULL,'r',0,0,0),(772,'Create/modify expense reports','expensereport',1,'creer',NULL,'w',0,0,0),(773,'Delete expense reports','expensereport',1,'supprimer',NULL,'d',0,0,0),(775,'Approve expense reports','expensereport',1,'approve',NULL,'w',0,0,0),(776,'Pay expense reports','expensereport',1,'to_paid',NULL,'w',0,0,0),(777,'Read expense reports of everybody','expensereport',1,'readall',NULL,'r',0,0,0),(778,'Create expense reports for everybody','expensereport',1,'writeall_advance',NULL,'w',0,0,0),(779,'Export expense reports','expensereport',1,'export',NULL,'r',0,0,0),(1001,'Lire les stocks','stock',1,'lire',NULL,'r',1,40,0),(1002,'Creer/Modifier les stocks','stock',1,'creer',NULL,'w',0,40,0),(1003,'Supprimer les stocks','stock',1,'supprimer',NULL,'d',0,40,0),(1004,'Lire mouvements de stocks','stock',1,'mouvement','lire','r',1,40,0),(1005,'Creer/modifier mouvements de stocks','stock',1,'mouvement','creer','w',0,40,0),(1101,'Read delivery receipts','expedition',1,'delivery','lire','r',0,40,0),(1102,'Create/modify delivery receipts','expedition',1,'delivery','creer','w',0,40,0),(1104,'Validate delivery receipts','expedition',1,'delivery_advance','validate','d',0,40,0),(1109,'Delete delivery receipts','expedition',1,'delivery','supprimer','d',0,40,0),(1121,'Read supplier proposals','supplier_proposal',1,'lire',NULL,'w',0,35,0),(1122,'Create/modify supplier proposals','supplier_proposal',1,'creer',NULL,'w',0,35,0),(1123,'Validate supplier proposals','supplier_proposal',1,'validate_advance',NULL,'w',0,35,0),(1124,'Envoyer les demandes fournisseurs','supplier_proposal',1,'send_advance',NULL,'w',0,35,0),(1125,'Delete supplier proposals','supplier_proposal',1,'supprimer',NULL,'w',0,35,0),(1126,'Close supplier price requests','supplier_proposal',1,'cloturer',NULL,'w',0,35,0),(1181,'Consulter les fournisseurs','fournisseur',1,'lire',NULL,'r',0,0,0),(1182,'Consulter les commandes fournisseur','fournisseur',1,'commande','lire','r',0,0,0),(1183,'Creer une commande fournisseur','fournisseur',1,'commande','creer','w',0,0,0),(1184,'Valider une commande fournisseur','fournisseur',1,'supplier_order_advance','validate','w',0,0,0),(1185,'Approuver une commande fournisseur','fournisseur',1,'commande','approuver','w',0,0,0),(1186,'Commander une commande fournisseur','fournisseur',1,'commande','commander','w',0,0,0),(1187,'Receptionner une commande fournisseur','fournisseur',1,'commande','receptionner','d',0,0,0),(1188,'Supprimer une commande fournisseur','fournisseur',1,'commande','supprimer','d',0,0,0),(1189,'Check/Uncheck a supplier order reception','fournisseur',1,'commande_advance','check','w',0,0,0),(1191,'Exporter les commande fournisseurs, attributs','fournisseur',1,'commande','export','r',0,0,0),(1201,'Lire les exports','export',1,'lire',NULL,'r',1,72,0),(1202,'Creer/modifier un export','export',1,'creer',NULL,'w',0,72,0),(1231,'Consulter les factures fournisseur','fournisseur',1,'facture','lire','r',0,0,0),(1232,'Creer une facture fournisseur','fournisseur',1,'facture','creer','w',0,0,0),(1233,'Valider une facture fournisseur','fournisseur',1,'supplier_invoice_advance','validate','w',0,0,0),(1234,'Supprimer une facture fournisseur','fournisseur',1,'facture','supprimer','d',0,0,0),(1235,'Envoyer les factures par mail','fournisseur',1,'supplier_invoice_advance','send','a',0,0,0),(1236,'Exporter les factures fournisseurs, attributs et reglements','fournisseur',1,'facture','export','r',0,0,0),(1251,'Run mass imports of external data (data load)','import',1,'run',NULL,'r',0,70,0),(1321,'Export customer invoices, attributes and payments','facture',1,'facture','export','r',0,0,0),(1321,'Exporter les factures clients, attributs et reglements','facture',2,'facture','export','r',0,10,0),(1322,'Re-open a fully paid invoice','facture',1,'invoice_advance','reopen','r',0,0,0),(1421,'Export sales orders and attributes','commande',1,'commande','export','r',0,0,0),(2401,'Read actions/tasks linked to his account','agenda',1,'myactions','read','r',0,0,0),(2401,'Read actions/tasks linked to his account','agenda',2,'myactions','read','r',1,15,0),(2402,'Create/modify actions/tasks linked to his account','agenda',1,'myactions','create','w',0,0,0),(2402,'Create/modify actions/tasks linked to his account','agenda',2,'myactions','create','w',0,15,0),(2403,'Delete actions/tasks linked to his account','agenda',1,'myactions','delete','w',0,0,0),(2403,'Delete actions/tasks linked to his account','agenda',2,'myactions','delete','w',0,15,0),(2411,'Read actions/tasks of others','agenda',1,'allactions','read','r',0,0,0),(2411,'Read actions/tasks of others','agenda',2,'allactions','read','r',0,15,0),(2412,'Create/modify actions/tasks of others','agenda',1,'allactions','create','w',0,0,0),(2412,'Create/modify actions/tasks of others','agenda',2,'allactions','create','w',0,15,0),(2413,'Delete actions/tasks of others','agenda',1,'allactions','delete','w',0,0,0),(2413,'Delete actions/tasks of others','agenda',2,'allactions','delete','w',0,15,0),(2414,'Export actions/tasks of others','agenda',1,'export',NULL,'w',0,0,0),(2501,'Read or download documents','ecm',1,'read',NULL,'r',0,0,0),(2503,'Upload a document','ecm',1,'upload',NULL,'w',0,0,0),(2515,'Administer directories of documents','ecm',1,'setup',NULL,'w',0,0,0),(3200,'Read archived events and fingerprints','blockedlog',1,'read',NULL,'w',0,76,0),(3201,'Read archived events and fingerprints','blockedlog',1,'read',NULL,'w',0,76,0),(10001,'Read website content','website',1,'read',NULL,'w',0,0,0),(10002,'Create/modify website content (html and javascript content)','website',1,'write',NULL,'w',0,0,0),(10003,'Create/modify website content (dynamic php code). Dangerous, must be reserved to restricted developers.','website',1,'writephp',NULL,'w',0,0,0),(10005,'Delete website content','website',1,'delete',NULL,'w',0,0,0),(10008,'Export website content','website',1,'export',NULL,'w',0,0,0),(20001,'Read leave requests (yours and your subordinates)','holiday',1,'read',NULL,'w',0,0,0),(20001,'Créer / Modifier / Lire ses demandes de congés payés','holiday',2,'write',NULL,'w',1,42,0),(20002,'Create/modify leave requests','holiday',1,'write',NULL,'w',0,0,0),(20003,'Delete leave requests','holiday',1,'delete',NULL,'w',0,0,0),(20003,'Supprimer des demandes de congés payés','holiday',2,'delete',NULL,'w',0,42,0),(20004,'Read leave requests for everybody','holiday',1,'readall',NULL,'w',0,0,0),(20004,'Définir les congés payés des utilisateurs','holiday',2,'define_holiday',NULL,'w',0,42,0),(20005,'Create/modify leave requests for everybody','holiday',1,'writeall_advance',NULL,'w',0,0,0),(20005,'Voir les logs de modification des congés payés','holiday',2,'view_log',NULL,'w',0,42,0),(20006,'Setup leave requests of users (setup and update balance)','holiday',1,'define_holiday',NULL,'w',0,0,0),(20006,'Accéder au rapport mensuel des congés payés','holiday',2,'month_report',NULL,'w',0,42,0),(20007,'Approve leave requests','holiday',1,'approve',NULL,'w',0,0,0),(23001,'Read cron jobs','cron',1,'read',NULL,'w',0,0,0),(23002,'Create cron Jobs','cron',1,'create',NULL,'w',0,0,0),(23003,'Delete cron Jobs','cron',1,'delete',NULL,'w',0,0,0),(23004,'Execute cron Jobs','cron',1,'execute',NULL,'w',0,0,0),(50151,'Use Point Of Sale (record a sale, add products, record payment)','takepos',1,'run',NULL,'a',0,0,0),(50152,'Can modify added sales lines (prices, discount)','takepos',1,'editlines',NULL,'a',0,0,0),(50153,'Edit ordered sales lines (useful only when option \"Order printers\" has been enabled). Allow to edit sales lines even after the order has been printed','takepos',1,'editorderedlines',NULL,'a',0,0,0),(50401,'Bind products and invoices with accounting accounts','accounting',1,'bind','write','r',0,61,0),(50411,'Read operations in General Ledger','accounting',1,'mouvements','lire','r',0,61,0),(50412,'Write/Edit operations in General Ledger','accounting',1,'mouvements','creer','w',0,61,0),(50414,'Delete operations in Ledger','accounting',1,'mouvements','supprimer','d',0,61,0),(50415,'Delete all operations by year and journal in Ledger','accounting',1,'mouvements','supprimer_tous','d',0,61,0),(50418,'Export operations of the Ledger','accounting',1,'mouvements','export','r',0,61,0),(50420,'Report and export reports (turnover, balance, journals, general ledger)','accounting',1,'comptarapport','lire','r',0,61,0),(50430,'Define and close a fiscal year','accounting',1,'fiscalyear','write','r',0,61,0),(50440,'Manage chart of accounts, setup of accountancy','accounting',1,'chartofaccount',NULL,'r',0,61,0),(55001,'Read surveys','opensurvey',1,'read',NULL,'r',0,0,0),(55002,'Create/modify surveys','opensurvey',1,'write',NULL,'w',0,0,0),(56001,'Read ticket','ticket',1,'read',NULL,'r',0,0,0),(56002,'Create les tickets','ticket',1,'write',NULL,'w',0,0,0),(56003,'Delete les tickets','ticket',1,'delete',NULL,'d',0,0,0),(56004,'Manage tickets','ticket',1,'manage',NULL,'w',0,0,0),(59001,'Visualiser les marges','margins',1,'liretous',NULL,'r',0,55,0),(59002,'Définir les marges','margins',1,'creer',NULL,'w',0,55,0),(59003,'Read every user margin','margins',1,'read','all','r',0,55,0),(63001,'Read resources','resource',1,'read',NULL,'w',0,16,0),(63002,'Create/Modify resources','resource',1,'write',NULL,'w',0,16,0),(63003,'Delete resources','resource',1,'delete',NULL,'w',0,16,0),(63004,'Link resources to agenda events','resource',1,'link',NULL,'w',0,16,0),(64001,'DirectPrint','printing',1,'read',NULL,'r',0,52,0),(101250,'Read surveys','opensurvey',2,'survey','read','r',0,40,0),(101251,'Create/modify surveys','opensurvey',2,'survey','write','w',0,40,0),(941601,'Lire les receptions','reception',1,'lire',NULL,'r',0,40,0),(941602,'Creer modifier les receptions','reception',1,'creer',NULL,'w',0,40,0),(941603,'Valider les receptions','reception',1,'reception_advance','validate','d',0,40,0),(941604,'Envoyer les receptions aux clients','reception',1,'reception_advance','send','d',0,40,0),(941605,'Exporter les receptions','reception',1,'reception','export','r',0,40,0),(941606,'Supprimer les receptions','reception',1,'supprimer',NULL,'d',0,40,0); +INSERT INTO `llx_rights_def` VALUES (11,'Read invoices','facture',1,'lire',NULL,'a',0,11,0),(11,'Lire les factures','facture',2,'lire',NULL,'a',1,10,0),(12,'Create and update invoices','facture',1,'creer',NULL,'a',0,11,0),(12,'Creer/modifier les factures','facture',2,'creer',NULL,'a',0,10,0),(13,'Devalidate invoices','facture',1,'invoice_advance','unvalidate','a',0,11,0),(13,'Dévalider les factures','facture',2,'invoice_advance','unvalidate','a',0,10,0),(14,'Validate invoices','facture',1,'invoice_advance','validate','a',0,11,0),(14,'Valider les factures','facture',2,'valider',NULL,'a',0,10,0),(15,'Send invoices by email','facture',1,'invoice_advance','send','a',0,11,0),(15,'Envoyer les factures par mail','facture',2,'invoice_advance','send','a',0,10,0),(16,'Issue payments on invoices','facture',1,'paiement',NULL,'a',0,11,0),(16,'Emettre des paiements sur les factures','facture',2,'paiement',NULL,'a',0,10,0),(19,'Delete invoices','facture',1,'supprimer',NULL,'a',0,11,0),(19,'Supprimer les factures','facture',2,'supprimer',NULL,'a',0,10,0),(21,'Lire les propositions commerciales','propale',1,'lire',NULL,'r',1,22,0),(21,'Lire les propositions commerciales','propale',2,'lire',NULL,'r',1,22,0),(22,'Creer/modifier les propositions commerciales','propale',1,'creer',NULL,'w',0,22,0),(22,'Creer/modifier les propositions commerciales','propale',2,'creer',NULL,'w',0,22,0),(24,'Valider les propositions commerciales','propale',1,'propal_advance','validate','d',0,22,0),(24,'Valider les propositions commerciales','propale',2,'valider',NULL,'d',0,22,0),(25,'Envoyer les propositions commerciales aux clients','propale',1,'propal_advance','send','d',0,22,0),(25,'Envoyer les propositions commerciales aux clients','propale',2,'propal_advance','send','d',0,22,0),(26,'Cloturer les propositions commerciales','propale',1,'propal_advance','close','d',0,22,0),(26,'Cloturer les propositions commerciales','propale',2,'propal_advance','close','d',0,22,0),(27,'Supprimer les propositions commerciales','propale',1,'supprimer',NULL,'d',0,22,0),(27,'Supprimer les propositions commerciales','propale',2,'supprimer',NULL,'d',0,22,0),(28,'Exporter les propositions commerciales et attributs','propale',1,'export',NULL,'r',0,22,0),(28,'Exporter les propositions commerciales et attributs','propale',2,'export',NULL,'r',0,22,0),(31,'Lire les produits','produit',1,'lire',NULL,'r',1,25,0),(31,'Lire les produits','produit',2,'lire',NULL,'r',1,25,0),(32,'Creer/modifier les produits','produit',1,'creer',NULL,'w',0,25,0),(32,'Creer/modifier les produits','produit',2,'creer',NULL,'w',0,25,0),(34,'Supprimer les produits','produit',1,'supprimer',NULL,'d',0,25,0),(34,'Supprimer les produits','produit',2,'supprimer',NULL,'d',0,25,0),(38,'Exporter les produits','produit',1,'export',NULL,'r',0,25,0),(38,'Exporter les produits','produit',2,'export',NULL,'r',0,25,0),(39,'Ignore minimum price','produit',1,'ignore_price_min_advance',NULL,'r',0,25,0),(41,'Read projects and tasks (shared projects or projects I am contact for). Can also enter time consumed on assigned tasks (timesheet)','projet',1,'lire',NULL,'r',1,14,0),(42,'Create/modify projects and tasks (shared projects or projects I am contact for)','projet',1,'creer',NULL,'w',0,14,0),(44,'Delete project and tasks (shared projects or projects I am contact for)','projet',1,'supprimer',NULL,'d',0,14,0),(45,'Export projects','projet',1,'export',NULL,'d',0,14,0),(61,'Lire les fiches d\'intervention','ficheinter',1,'lire',NULL,'r',1,41,0),(62,'Creer/modifier les fiches d\'intervention','ficheinter',1,'creer',NULL,'w',0,41,0),(64,'Supprimer les fiches d\'intervention','ficheinter',1,'supprimer',NULL,'d',0,41,0),(67,'Exporter les fiches interventions','ficheinter',1,'export',NULL,'r',0,41,0),(68,'Envoyer les fiches d\'intervention par courriel','ficheinter',1,'ficheinter_advance','send','r',0,41,0),(69,'Valider les fiches d\'intervention ','ficheinter',1,'ficheinter_advance','validate','a',0,41,0),(70,'Dévalider les fiches d\'intervention','ficheinter',1,'ficheinter_advance','unvalidate','a',0,41,0),(71,'Read members\' card','adherent',1,'lire',NULL,'r',0,55,0),(72,'Create/modify members (need also user module permissions if member linked to a user)','adherent',1,'creer',NULL,'w',0,55,0),(74,'Remove members','adherent',1,'supprimer',NULL,'d',0,55,0),(75,'Setup types of membership','adherent',1,'configurer',NULL,'w',0,55,0),(76,'Export members','adherent',1,'export',NULL,'r',0,55,0),(78,'Read subscriptions','adherent',1,'cotisation','lire','r',0,55,0),(79,'Create/modify/remove subscriptions','adherent',1,'cotisation','creer','w',0,55,0),(81,'Read sales orders','commande',1,'lire',NULL,'r',0,11,0),(82,'Creeat/modify sales orders','commande',1,'creer',NULL,'w',0,11,0),(84,'Validate sales orders','commande',1,'order_advance','validate','d',0,11,0),(86,'Send sale orders by email','commande',1,'order_advance','send','d',0,11,0),(87,'Close sale orders','commande',1,'order_advance','close','d',0,11,0),(88,'Cancel sale orders','commande',1,'order_advance','annuler','d',0,11,0),(89,'Delete sales orders','commande',1,'supprimer',NULL,'d',0,11,0),(91,'Lire les charges','tax',1,'charges','lire','r',0,50,0),(91,'Lire les charges','tax',2,'charges','lire','r',1,50,0),(92,'Creer/modifier les charges','tax',1,'charges','creer','w',0,50,0),(92,'Creer/modifier les charges','tax',2,'charges','creer','w',0,50,0),(93,'Supprimer les charges','tax',1,'charges','supprimer','d',0,50,0),(93,'Supprimer les charges','tax',2,'charges','supprimer','d',0,50,0),(94,'Exporter les charges','tax',1,'charges','export','r',0,50,0),(94,'Exporter les charges','tax',2,'charges','export','r',0,50,0),(101,'Lire les expeditions','expedition',1,'lire',NULL,'r',0,40,0),(102,'Creer modifier les expeditions','expedition',1,'creer',NULL,'w',0,40,0),(104,'Valider les expeditions','expedition',1,'shipping_advance','validate','d',0,40,0),(105,'Envoyer les expeditions aux clients','expedition',1,'shipping_advance','send','d',0,40,0),(106,'Exporter les expeditions','expedition',1,'shipment','export','r',0,40,0),(109,'Supprimer les expeditions','expedition',1,'supprimer',NULL,'d',0,40,0),(111,'Read bank account and transactions','banque',1,'lire',NULL,'r',0,51,0),(111,'Lire les comptes bancaires','banque',2,'lire',NULL,'r',1,51,0),(112,'Creer/modifier montant/supprimer ecriture bancaire','banque',1,'modifier',NULL,'w',0,51,0),(112,'Creer/modifier montant/supprimer ecriture bancaire','banque',2,'modifier',NULL,'w',0,51,0),(113,'Configurer les comptes bancaires (creer, gerer categories)','banque',1,'configurer',NULL,'a',0,51,0),(113,'Configurer les comptes bancaires (creer, gerer categories)','banque',2,'configurer',NULL,'a',0,51,0),(114,'Rapprocher les ecritures bancaires','banque',1,'consolidate',NULL,'w',0,51,0),(114,'Rapprocher les ecritures bancaires','banque',2,'consolidate',NULL,'w',0,51,0),(115,'Exporter transactions et releves','banque',1,'export',NULL,'r',0,51,0),(115,'Exporter transactions et releves','banque',2,'export',NULL,'r',0,51,0),(116,'Virements entre comptes','banque',1,'transfer',NULL,'w',0,51,0),(116,'Virements entre comptes','banque',2,'transfer',NULL,'w',0,51,0),(117,'Gerer les envois de cheques','banque',1,'cheque',NULL,'w',0,51,0),(117,'Gerer les envois de cheques','banque',2,'cheque',NULL,'w',0,51,0),(121,'Read third parties','societe',1,'lire',NULL,'r',0,9,0),(121,'Lire les societes','societe',2,'lire',NULL,'r',1,9,0),(122,'Create and update third parties','societe',1,'creer',NULL,'w',0,9,0),(122,'Creer modifier les societes','societe',2,'creer',NULL,'w',0,9,0),(125,'Delete third parties','societe',1,'supprimer',NULL,'d',0,9,0),(125,'Supprimer les societes','societe',2,'supprimer',NULL,'d',0,9,0),(126,'Export third parties','societe',1,'export',NULL,'r',0,9,0),(126,'Exporter les societes','societe',2,'export',NULL,'r',0,9,0),(130,'Modify thirdparty information payment','societe',1,'thirdparty_paymentinformation_advance','write','w',0,9,0),(141,'Read all projects and tasks (also private projects I am not contact for)','projet',1,'all','lire','r',0,14,0),(142,'Create/modify all projects and tasks (also private projects I am not contact for)','projet',1,'all','creer','w',0,14,0),(144,'Delete all projects and tasks (also private projects I am not contact for)','projet',1,'all','supprimer','d',0,14,0),(151,'Read withdrawals','prelevement',1,'bons','lire','r',1,52,0),(152,'Create/modify a withdrawals','prelevement',1,'bons','creer','w',0,52,0),(153,'Send withdrawals to bank','prelevement',1,'bons','send','a',0,52,0),(154,'credit/refuse withdrawals','prelevement',1,'bons','credit','a',0,52,0),(161,'Lire les contrats','contrat',1,'lire',NULL,'r',1,35,0),(162,'Creer / modifier les contrats','contrat',1,'creer',NULL,'w',0,35,0),(163,'Activer un service d\'un contrat','contrat',1,'activer',NULL,'w',0,35,0),(164,'Desactiver un service d\'un contrat','contrat',1,'desactiver',NULL,'w',0,35,0),(165,'Supprimer un contrat','contrat',1,'supprimer',NULL,'d',0,35,0),(167,'Export contracts','contrat',1,'export',NULL,'r',0,35,0),(221,'Consulter les mailings','mailing',1,'lire',NULL,'r',1,11,0),(221,'Consulter les mailings','mailing',2,'lire',NULL,'r',1,11,0),(222,'Creer/modifier les mailings (sujet, destinataires...)','mailing',1,'creer',NULL,'w',0,11,0),(222,'Creer/modifier les mailings (sujet, destinataires...)','mailing',2,'creer',NULL,'w',0,11,0),(223,'Valider les mailings (permet leur envoi)','mailing',1,'valider',NULL,'w',0,11,0),(223,'Valider les mailings (permet leur envoi)','mailing',2,'valider',NULL,'w',0,11,0),(229,'Supprimer les mailings','mailing',1,'supprimer',NULL,'d',0,11,0),(229,'Supprimer les mailings','mailing',2,'supprimer',NULL,'d',0,11,0),(237,'View recipients and info','mailing',1,'mailing_advance','recipient','r',0,11,0),(237,'View recipients and info','mailing',2,'mailing_advance','recipient','r',0,11,0),(238,'Manually send mailings','mailing',1,'mailing_advance','send','w',0,11,0),(238,'Manually send mailings','mailing',2,'mailing_advance','send','w',0,11,0),(239,'Delete mailings after validation and/or sent','mailing',1,'mailing_advance','delete','d',0,11,0),(239,'Delete mailings after validation and/or sent','mailing',2,'mailing_advance','delete','d',0,11,0),(241,'Lire les categories','categorie',1,'lire',NULL,'r',1,20,0),(242,'Creer/modifier les categories','categorie',1,'creer',NULL,'w',0,20,0),(243,'Supprimer les categories','categorie',1,'supprimer',NULL,'d',0,20,0),(251,'Read information of other users, groups and permissions','user',1,'user','lire','r',0,5,0),(252,'Read permissions of other users','user',1,'user_advance','readperms','r',0,5,0),(253,'Create/modify internal and external users, groups and permissions','user',1,'user','creer','w',0,5,0),(254,'Create/modify external users only','user',1,'user_advance','write','w',0,5,0),(255,'Modify the password of other users','user',1,'user','password','w',0,5,0),(256,'Delete or disable other users','user',1,'user','supprimer','d',0,5,0),(262,'Read all third parties (and their objects) by internal users (otherwise only if commercial contact). Not effective for external users (limited to themselves).','societe',1,'client','voir','r',0,9,0),(262,'Consulter tous les tiers par utilisateurs internes (sinon uniquement si contact commercial). Non effectif pour utilisateurs externes (tjs limités à eux-meme).','societe',2,'client','voir','r',1,9,0),(281,'Read contacts','societe',1,'contact','lire','r',0,9,0),(281,'Lire les contacts','societe',2,'contact','lire','r',1,9,0),(282,'Create and update contact','societe',1,'contact','creer','w',0,9,0),(282,'Creer modifier les contacts','societe',2,'contact','creer','w',0,9,0),(283,'Delete contacts','societe',1,'contact','supprimer','d',0,9,0),(283,'Supprimer les contacts','societe',2,'contact','supprimer','d',0,9,0),(286,'Export contacts','societe',1,'contact','export','d',0,9,0),(286,'Exporter les contacts','societe',2,'contact','export','d',0,9,0),(301,'Read barcodes','barcode',1,'lire_advance',NULL,'r',1,50,0),(302,'Create/modify barcodes','barcode',1,'creer_advance',NULL,'w',0,50,0),(331,'Lire les bookmarks','bookmark',1,'lire',NULL,'r',0,50,0),(332,'Creer/modifier les bookmarks','bookmark',1,'creer',NULL,'r',0,50,0),(333,'Supprimer les bookmarks','bookmark',1,'supprimer',NULL,'r',0,50,0),(341,'Read its own permissions','user',1,'self_advance','readperms','r',0,5,0),(342,'Create/modify of its own user','user',1,'self','creer','w',0,5,0),(343,'Modify its own password','user',1,'self','password','w',0,5,0),(344,'Modify its own permissions','user',1,'self_advance','writeperms','w',0,5,0),(351,'Read groups','user',1,'group_advance','read','r',0,5,0),(352,'Read permissions of groups','user',1,'group_advance','readperms','r',0,5,0),(353,'Create/modify groups and permissions','user',1,'group_advance','write','w',0,5,0),(354,'Delete groups','user',1,'group_advance','delete','d',0,5,0),(358,'Export all users','user',1,'user','export','r',0,5,0),(511,'Read employee salaries and payments (yours and your subordinates)','salaries',1,'read',NULL,'r',0,50,0),(512,'Create/modify payments of empoyee salaries','salaries',1,'write',NULL,'w',0,50,0),(514,'Delete payments of employee salary','salaries',1,'delete',NULL,'d',0,50,0),(517,'Read salaries and payments of all employees','salaries',1,'readall',NULL,'r',0,50,0),(519,'Export payments of employee salaries','salaries',1,'export',NULL,'r',0,50,0),(520,'Read loans','loan',1,'read',NULL,'r',0,50,0),(521,'Read loans','loan',1,'read',NULL,'r',0,50,0),(522,'Create/modify loans','loan',1,'write',NULL,'w',0,50,0),(524,'Delete loans','loan',1,'delete',NULL,'d',0,50,0),(525,'Access loan calculator','loan',1,'calc',NULL,'r',0,50,0),(527,'Export loans','loan',1,'export',NULL,'r',0,50,0),(531,'Read services','service',1,'lire',NULL,'r',0,29,0),(532,'Create/modify services','service',1,'creer',NULL,'w',0,29,0),(534,'Delete les services','service',1,'supprimer',NULL,'d',0,29,0),(538,'Export services','service',1,'export',NULL,'r',0,29,0),(561,'Read bank transfer payment orders','paymentbybanktransfer',1,'read',NULL,'r',0,52,0),(562,'Create/modify a bank transfer payment order','paymentbybanktransfer',1,'create',NULL,'w',0,52,0),(563,'Send/Transmit bank transfer payment order','paymentbybanktransfer',1,'send',NULL,'a',0,52,0),(564,'Record Debits/Rejects of bank transfer payment order','paymentbybanktransfer',1,'debit',NULL,'a',0,52,0),(651,'Read bom of Bom','bom',1,'read',NULL,'w',0,65,0),(652,'Create/Update bom of Bom','bom',1,'write',NULL,'w',0,65,0),(653,'Delete bom of Bom','bom',1,'delete',NULL,'w',0,65,0),(661,'Read Manufacturing Order','mrp',1,'read',NULL,'w',0,66,0),(662,'Create/Update Manufacturing Order','mrp',1,'write',NULL,'w',0,66,0),(663,'Delete Manufacturing Order','mrp',1,'delete',NULL,'w',0,66,0),(701,'Lire les dons','don',1,'lire',NULL,'r',1,50,0),(701,'Lire les dons','don',2,'lire',NULL,'r',1,50,0),(702,'Creer/modifier les dons','don',1,'creer',NULL,'w',0,50,0),(702,'Creer/modifier les dons','don',2,'creer',NULL,'w',0,50,0),(703,'Supprimer les dons','don',1,'supprimer',NULL,'d',0,50,0),(703,'Supprimer les dons','don',2,'supprimer',NULL,'d',0,50,0),(750,'Read job positions to fill and candidatures','recruitment',1,'recruitmentjobposition','read','w',0,44,0),(751,'Create/Update job positions to fill and candidatures','recruitment',1,'recruitmentjobposition','write','w',0,44,0),(752,'Delete Job positions to fill and candidatures','recruitment',1,'recruitmentjobposition','delete','w',0,44,0),(771,'Read expense reports (yours and your subordinates)','expensereport',1,'lire',NULL,'r',0,42,0),(772,'Create/modify expense reports','expensereport',1,'creer',NULL,'w',0,42,0),(773,'Delete expense reports','expensereport',1,'supprimer',NULL,'d',0,42,0),(775,'Approve expense reports','expensereport',1,'approve',NULL,'w',0,42,0),(776,'Pay expense reports','expensereport',1,'to_paid',NULL,'w',0,42,0),(777,'Read expense reports of everybody','expensereport',1,'readall',NULL,'r',0,42,0),(778,'Create expense reports for everybody','expensereport',1,'writeall_advance',NULL,'w',0,42,0),(779,'Export expense reports','expensereport',1,'export',NULL,'r',0,42,0),(1001,'Lire les stocks','stock',1,'lire',NULL,'r',1,40,0),(1002,'Creer/Modifier les stocks','stock',1,'creer',NULL,'w',0,40,0),(1003,'Supprimer les stocks','stock',1,'supprimer',NULL,'d',0,40,0),(1004,'Lire mouvements de stocks','stock',1,'mouvement','lire','r',1,40,0),(1005,'Creer/modifier mouvements de stocks','stock',1,'mouvement','creer','w',0,40,0),(1011,'inventoryReadPermission','stock',1,'inventory_advance','read','w',0,39,0),(1012,'inventoryCreatePermission','stock',1,'inventory_advance','write','w',0,39,0),(1101,'Read delivery receipts','expedition',1,'delivery','lire','r',0,40,0),(1102,'Create/modify delivery receipts','expedition',1,'delivery','creer','w',0,40,0),(1104,'Validate delivery receipts','expedition',1,'delivery_advance','validate','d',0,40,0),(1109,'Delete delivery receipts','expedition',1,'delivery','supprimer','d',0,40,0),(1121,'Read supplier proposals','supplier_proposal',1,'lire',NULL,'w',0,35,0),(1122,'Create/modify supplier proposals','supplier_proposal',1,'creer',NULL,'w',0,35,0),(1123,'Validate supplier proposals','supplier_proposal',1,'validate_advance',NULL,'w',0,35,0),(1124,'Envoyer les demandes fournisseurs','supplier_proposal',1,'send_advance',NULL,'w',0,35,0),(1125,'Delete supplier proposals','supplier_proposal',1,'supprimer',NULL,'w',0,35,0),(1126,'Close supplier price requests','supplier_proposal',1,'cloturer',NULL,'w',0,35,0),(1181,'Consulter les fournisseurs','fournisseur',1,'lire',NULL,'r',0,12,0),(1182,'Consulter les commandes fournisseur','fournisseur',1,'commande','lire','r',0,12,0),(1183,'Creer une commande fournisseur','fournisseur',1,'commande','creer','w',0,12,0),(1184,'Valider une commande fournisseur','fournisseur',1,'supplier_order_advance','validate','w',0,12,0),(1185,'Approuver une commande fournisseur','fournisseur',1,'commande','approuver','w',0,12,0),(1186,'Commander une commande fournisseur','fournisseur',1,'commande','commander','w',0,12,0),(1187,'Receptionner une commande fournisseur','fournisseur',1,'commande','receptionner','d',0,12,0),(1188,'Supprimer une commande fournisseur','fournisseur',1,'commande','supprimer','d',0,12,0),(1189,'Check/Uncheck a supplier order reception','fournisseur',1,'commande_advance','check','w',0,12,0),(1191,'Exporter les commande fournisseurs, attributs','fournisseur',1,'commande','export','r',0,12,0),(1201,'Lire les exports','export',1,'lire',NULL,'r',1,72,0),(1202,'Creer/modifier un export','export',1,'creer',NULL,'w',0,72,0),(1231,'Consulter les factures fournisseur','fournisseur',1,'facture','lire','r',0,12,0),(1232,'Creer une facture fournisseur','fournisseur',1,'facture','creer','w',0,12,0),(1233,'Valider une facture fournisseur','fournisseur',1,'supplier_invoice_advance','validate','w',0,12,0),(1234,'Supprimer une facture fournisseur','fournisseur',1,'facture','supprimer','d',0,12,0),(1235,'Envoyer les factures par mail','fournisseur',1,'supplier_invoice_advance','send','a',0,12,0),(1236,'Exporter les factures fournisseurs, attributs et reglements','fournisseur',1,'facture','export','r',0,12,0),(1251,'Run mass imports of external data (data load)','import',1,'run',NULL,'r',0,70,0),(1321,'Export customer invoices, attributes and payments','facture',1,'facture','export','r',0,11,0),(1321,'Exporter les factures clients, attributs et reglements','facture',2,'facture','export','r',0,10,0),(1322,'Re-open a fully paid invoice','facture',1,'invoice_advance','reopen','r',0,11,0),(1421,'Export sales orders and attributes','commande',1,'commande','export','r',0,11,0),(2401,'Read actions/tasks linked to his account','agenda',1,'myactions','read','r',0,15,0),(2401,'Read actions/tasks linked to his account','agenda',2,'myactions','read','r',1,15,0),(2402,'Create/modify actions/tasks linked to his account','agenda',1,'myactions','create','w',0,15,0),(2402,'Create/modify actions/tasks linked to his account','agenda',2,'myactions','create','w',0,15,0),(2403,'Delete actions/tasks linked to his account','agenda',1,'myactions','delete','w',0,15,0),(2403,'Delete actions/tasks linked to his account','agenda',2,'myactions','delete','w',0,15,0),(2411,'Read actions/tasks of others','agenda',1,'allactions','read','r',0,15,0),(2411,'Read actions/tasks of others','agenda',2,'allactions','read','r',0,15,0),(2412,'Create/modify actions/tasks of others','agenda',1,'allactions','create','w',0,15,0),(2412,'Create/modify actions/tasks of others','agenda',2,'allactions','create','w',0,15,0),(2413,'Delete actions/tasks of others','agenda',1,'allactions','delete','w',0,15,0),(2413,'Delete actions/tasks of others','agenda',2,'allactions','delete','w',0,15,0),(2414,'Export actions/tasks of others','agenda',1,'export',NULL,'w',0,15,0),(2501,'Read or download documents','ecm',1,'read',NULL,'r',0,10,0),(2503,'Upload a document','ecm',1,'upload',NULL,'w',0,10,0),(2515,'Administer directories of documents','ecm',1,'setup',NULL,'w',0,10,0),(2610,'Générer / modifier la clé API des utilisateurs','api',1,'apikey','generate','w',0,24,0),(3201,'Read archived events and fingerprints','blockedlog',1,'read',NULL,'w',0,76,0),(10001,'Read website content','website',1,'read',NULL,'w',0,50,0),(10002,'Create/modify website content (html and javascript content)','website',1,'write',NULL,'w',0,50,0),(10003,'Create/modify website content (dynamic php code). Dangerous, must be reserved to restricted developers.','website',1,'writephp',NULL,'w',0,50,0),(10005,'Delete website content','website',1,'delete',NULL,'w',0,50,0),(10008,'Export website content','website',1,'export',NULL,'w',0,50,0),(20001,'Read leave requests (yours and your subordinates)','holiday',1,'read',NULL,'w',0,42,0),(20001,'Créer / Modifier / Lire ses demandes de congés payés','holiday',2,'write',NULL,'w',1,42,0),(20002,'Create/modify leave requests','holiday',1,'write',NULL,'w',0,42,0),(20003,'Delete leave requests','holiday',1,'delete',NULL,'w',0,42,0),(20003,'Supprimer des demandes de congés payés','holiday',2,'delete',NULL,'w',0,42,0),(20004,'Read leave requests for everybody','holiday',1,'readall',NULL,'w',0,42,0),(20004,'Définir les congés payés des utilisateurs','holiday',2,'define_holiday',NULL,'w',0,42,0),(20005,'Create/modify leave requests for everybody','holiday',1,'writeall',NULL,'w',0,42,0),(20005,'Voir les logs de modification des congés payés','holiday',2,'view_log',NULL,'w',0,42,0),(20006,'Setup leave requests of users (setup and update balance)','holiday',1,'define_holiday',NULL,'w',0,42,0),(20006,'Accéder au rapport mensuel des congés payés','holiday',2,'month_report',NULL,'w',0,42,0),(20007,'Approve leave requests','holiday',1,'approve',NULL,'w',0,42,0),(23001,'Read cron jobs','cron',1,'read',NULL,'w',0,50,0),(23002,'Create cron Jobs','cron',1,'create',NULL,'w',0,50,0),(23003,'Delete cron Jobs','cron',1,'delete',NULL,'w',0,50,0),(23004,'Execute cron Jobs','cron',1,'execute',NULL,'w',0,50,0),(50151,'Use Point Of Sale (record a sale, add products, record payment)','takepos',1,'run',NULL,'a',0,60,0),(50152,'Can modify added sales lines (prices, discount)','takepos',1,'editlines',NULL,'a',0,60,0),(50153,'Edit ordered sales lines (useful only when option \"Order printers\" has been enabled). Allow to edit sales lines even after the order has been printed','takepos',1,'editorderedlines',NULL,'a',0,60,0),(50401,'Bind products and invoices with accounting accounts','accounting',1,'bind','write','r',0,61,0),(50411,'Read operations in General Ledger','accounting',1,'mouvements','lire','r',0,61,0),(50412,'Write/Edit operations in General Ledger','accounting',1,'mouvements','creer','w',0,61,0),(50414,'Delete operations in Ledger','accounting',1,'mouvements','supprimer','d',0,61,0),(50415,'Delete all operations by year and journal in Ledger','accounting',1,'mouvements','supprimer_tous','d',0,61,0),(50418,'Export operations of the Ledger','accounting',1,'mouvements','export','r',0,61,0),(50420,'Report and export reports (turnover, balance, journals, general ledger)','accounting',1,'comptarapport','lire','r',0,61,0),(50430,'Define and close a fiscal year','accounting',1,'fiscalyear','write','r',0,61,0),(50440,'Manage chart of accounts, setup of accountancy','accounting',1,'chartofaccount',NULL,'r',0,61,0),(55001,'Read surveys','opensurvey',1,'read',NULL,'r',0,40,0),(55002,'Create/modify surveys','opensurvey',1,'write',NULL,'w',0,40,0),(56001,'Read ticket','ticket',1,'read',NULL,'r',0,60,0),(56002,'Create les tickets','ticket',1,'write',NULL,'w',0,60,0),(56003,'Delete les tickets','ticket',1,'delete',NULL,'d',0,60,0),(56004,'Manage tickets','ticket',1,'manage',NULL,'w',0,60,0),(57001,'Read articles','knowledgemanagement',1,'knowledgerecord','read','w',0,90,0),(57002,'Create/Update articles','knowledgemanagement',1,'knowledgerecord','write','w',0,90,0),(57003,'Delete articles','knowledgemanagement',1,'knowledgerecord','delete','w',0,90,0),(59001,'Visualiser les marges','margins',1,'liretous',NULL,'r',0,55,0),(59002,'Définir les marges','margins',1,'creer',NULL,'w',0,55,0),(59003,'Read every user margin','margins',1,'read','all','r',0,55,0),(63001,'Read resources','resource',1,'read',NULL,'w',0,16,0),(63002,'Create/Modify resources','resource',1,'write',NULL,'w',0,16,0),(63003,'Delete resources','resource',1,'delete',NULL,'w',0,16,0),(63004,'Link resources to agenda events','resource',1,'link',NULL,'w',0,16,0),(64001,'DirectPrint','printing',1,'read',NULL,'r',0,52,0),(101250,'Read surveys','opensurvey',2,'survey','read','r',0,40,0),(101251,'Create/modify surveys','opensurvey',2,'survey','write','w',0,40,0),(941601,'Lire les receptions','reception',1,'lire',NULL,'r',0,40,0),(941602,'Creer modifier les receptions','reception',1,'creer',NULL,'w',0,40,0),(941603,'Valider les receptions','reception',1,'reception_advance','validate','d',0,40,0),(941604,'Envoyer les receptions aux clients','reception',1,'reception_advance','send','d',0,40,0),(941605,'Exporter les receptions','reception',1,'reception','export','r',0,40,0),(941606,'Supprimer les receptions','reception',1,'supprimer',NULL,'d',0,40,0); /*!40000 ALTER TABLE `llx_rights_def` ENABLE KEYS */; UNLOCK TABLES; @@ -11037,6 +11490,32 @@ INSERT INTO `llx_salary` VALUES (1,'1','2021-04-15 10:22:55',NULL,19,NULL,NULL,N /*!40000 ALTER TABLE `llx_salary` ENABLE KEYS */; UNLOCK TABLES; +-- +-- Table structure for table `llx_salary_extrafields` +-- + +DROP TABLE IF EXISTS `llx_salary_extrafields`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `llx_salary_extrafields` ( + `rowid` int(11) NOT NULL AUTO_INCREMENT, + `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(), + `fk_object` int(11) NOT NULL, + `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, + PRIMARY KEY (`rowid`), + KEY `idx_salary_extrafields` (`fk_object`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `llx_salary_extrafields` +-- + +LOCK TABLES `llx_salary_extrafields` WRITE; +/*!40000 ALTER TABLE `llx_salary_extrafields` DISABLE KEYS */; +/*!40000 ALTER TABLE `llx_salary_extrafields` ENABLE KEYS */; +UNLOCK TABLES; + -- -- Table structure for table `llx_session` -- @@ -11050,7 +11529,7 @@ CREATE TABLE `llx_session` ( `last_accessed` datetime NOT NULL, `fk_user` int(11) NOT NULL, `remote_ip` varchar(64) CHARACTER SET utf8mb4 DEFAULT NULL, - `user_agent` varchar(128) CHARACTER SET utf8mb4 DEFAULT NULL, + `user_agent` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, PRIMARY KEY (`session_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; @@ -11095,15 +11574,6 @@ CREATE TABLE `llx_societe` ( `url` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `email` varchar(128) COLLATE utf8_unicode_ci DEFAULT NULL, `socialnetworks` text COLLATE utf8_unicode_ci DEFAULT NULL, - `skype` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `whatsapp` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `linkedin` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `youtube` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `googleplus` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `snapchat` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `instagram` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `facebook` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `twitter` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `fk_effectif` int(11) DEFAULT 0, `fk_typent` int(11) DEFAULT NULL, `fk_forme_juridique` int(11) DEFAULT 0, @@ -11163,7 +11633,7 @@ CREATE TABLE `llx_societe` ( `location_incoterms` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `model_pdf` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `fk_account` int(11) DEFAULT NULL, `fk_warehouse` int(11) DEFAULT NULL, `logo_squarred` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, @@ -11185,7 +11655,7 @@ CREATE TABLE `llx_societe` ( LOCK TABLES `llx_societe` WRITE; /*!40000 ALTER TABLE `llx_societe` DISABLE KEYS */; -INSERT INTO `llx_societe` VALUES (1,0,NULL,'2018-01-16 15:21:09','2012-07-08 14:21:44','Indian SAS',1,NULL,NULL,'CU1212-0007','SU1212-0005','7050','6050','1 alalah road',NULL,'Delhi',0,117,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,4,NULL,'0','','','','','',5000.00000000,1,NULL,NULL,NULL,1,1,NULL,NULL,0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,NULL,NULL,'en_IN',NULL,NULL,1,'indiancompany.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,NULL,NULL,0,NULL),(2,0,NULL,'2018-07-30 11:45:49','2012-07-08 14:23:48','Teclib',1,NULL,NULL,'CU1108-0001','SU1108-0001','411CU11080001','401SU11080001','',NULL,'Paris',0,1,NULL,NULL,'www.teclib.com',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,4,3,57,'0','123456789','','ACE14','','',400000.00000000,0,NULL,NULL,NULL,3,1,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,0.000,NULL,0.000,NULL,NULL,'fr_FR',NULL,NULL,1,'teclibcompany.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,0,'',NULL,0,NULL),(3,0,NULL,'2017-02-16 00:47:25','2012-07-08 22:42:12','Spanish Comp',1,NULL,NULL,'SPANISHCOMP','SU1601-0009',NULL,NULL,'1 via mallere',NULL,'Madrid',123,4,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,3,4,408,'0','','','','','',10000.00000000,0,NULL,NULL,NULL,1,1,NULL,NULL,0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,NULL,NULL,'es_AR',NULL,NULL,1,'spanishcompany.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,NULL,NULL,0,NULL),(4,0,NULL,'2018-01-22 17:24:53','2012-07-08 22:48:18','Prospector Vaalen',1,NULL,NULL,'CU1303-0014',NULL,NULL,NULL,'',NULL,'Bruxelles',103,2,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,3,4,201,'0','12345678','','','','',0.00000000,0,NULL,NULL,NULL,3,0,NULL,'PL_LOW',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'valeencompany.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,NULL,NULL,0,NULL),(5,0,NULL,'2017-02-21 11:01:17','2012-07-08 23:22:57','NoCountry GmBh',1,NULL,NULL,NULL,NULL,NULL,NULL,'',NULL,NULL,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'0','','','','','',0.00000000,0,NULL,NULL,NULL,0,0,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'nocountrycomp.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,1,'EUR',NULL,0,NULL),(6,0,NULL,'2018-01-16 15:35:56','2012-07-09 00:15:09','Swiss Touch',1,NULL,NULL,'CU1601-0018','SU1601-0010',NULL,NULL,'',NULL,'Genevia',0,6,NULL,NULL,NULL,'swisstouch@example.ch',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,2,2,601,'0','','','','','',56000.00000000,0,NULL,NULL,NULL,3,1,NULL,NULL,0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'swisstouch.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,NULL,NULL,0,NULL),(7,0,NULL,'2018-01-16 15:38:32','2012-07-09 01:24:26','Generic customer',1,NULL,NULL,'CU1302-0011',NULL,NULL,NULL,'',NULL,NULL,0,7,NULL,NULL,NULL,'ttt@ttt.com',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,8,NULL,'0','','','','','',0.00000000,0,'Generic customer to use for Point Of Sale module.
',NULL,NULL,1,0,NULL,NULL,0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'genericcustomer.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,NULL,NULL,0,NULL),(10,0,NULL,'2020-01-13 12:57:02','2012-07-10 15:13:08','NLTechno',1,NULL,NULL,'CU1212-0005','SU1601-0011','411CU12120005','401SU16010011','',NULL,NULL,0,102,NULL,NULL,NULL,'vsmith@email.com',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,4,54,'0','493861496','49386149600039','6209Z','22-01-2007','FR123456789',10000.00000000,0,NULL,'aa < aa
\r\ndddd',NULL,1,1,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,'123456789012',NULL,'fr_FR',NULL,NULL,1,'logo_nltechno_94x100.png','','',0,NULL,NULL,NULL,NULL,'The OpenSource company',0,NULL,'generic_odt:/home/ldestailleur/git/dolibarr_11.0/documents/doctemplates/thirdparties/template_thirdparty.ods',0,'',NULL,0,NULL),(11,0,NULL,'2019-11-28 11:52:58','2012-07-10 18:35:57','Company Corp 1',1,NULL,NULL,'CU1510-0017',NULL,'7051',NULL,'21 Green Hill street','75500','Los Angeles',0,11,'444123456',NULL,'companycorp1.com','companycorp1@example.com','{\"skype\":\"corp1\"}',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,1,NULL,'0','AB1234567','','','','USABS123',10000.00000000,0,NULL,NULL,NULL,3,0,NULL,'PL_LOW',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,0.000,NULL,0.000,NULL,NULL,'en_US',NULL,NULL,1,'comapnycorp1company.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,1,'EUR',NULL,0,NULL),(12,0,NULL,'2019-09-26 11:38:11','2012-07-11 16:18:08','Dupont Alain',1,NULL,NULL,'CU1601-0019',NULL,'411CU16010019',NULL,'',NULL,NULL,0,0,NULL,NULL,NULL,'pcurie@example.com',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'0','','','','','',0.00000000,0,NULL,NULL,NULL,1,0,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'pierrecurie.jpg','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,0,'',NULL,0,NULL),(13,0,NULL,'2019-10-08 09:57:51','2012-07-11 17:13:20','Company Corp 2',1,NULL,NULL,'CU1910-00021','SU1510-0008','411CU191000021','401SU15100008','',NULL,NULL,0,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'0','','','','','',0.00000000,0,NULL,NULL,NULL,3,1,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'companycorp2company.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,1,'EUR',NULL,0,NULL),(17,0,NULL,'2019-11-28 15:02:49','2013-08-01 02:41:26','Book Keeping Company',1,NULL,NULL,'CU1108-0004','SU1108-0004',NULL,'401SU11080004','The French Company',NULL,'Paris',0,1,NULL,NULL,NULL,NULL,'[]',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,NULL,'0','','','','','',0.00000000,0,NULL,NULL,NULL,0,1,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'bookkeepercompany.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,1,'EUR',NULL,0,NULL),(19,0,NULL,'2019-09-26 12:03:13','2015-01-12 12:23:05','Magic Food Store',1,NULL,NULL,'CU1301-0008',NULL,NULL,NULL,'65 holdywood boulevard','123456','BigTown',0,4,NULL,'0101',NULL,'myemail@domain.com',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'0','','','10/10/2010','','',0.00000000,0,NULL,NULL,NULL,1,0,NULL,NULL,0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,0.000,NULL,0.000,NULL,NULL,'en_US',NULL,NULL,1,'magicfoodstore.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,'sepamandate',NULL,NULL,NULL,0,NULL),(25,0,NULL,'2018-01-22 17:21:17','2015-03-10 15:47:37','Print Company',1,NULL,NULL,'CU1303-0016','SU1303-0007',NULL,NULL,'21 Gutenberg street','45600','Berlin',0,5,NULL,NULL,NULL,'printcompany@example.com',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'0','','','','','',0.00000000,0,NULL,NULL,NULL,0,1,NULL,NULL,0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,NULL,NULL,'de_DE',NULL,NULL,1,'printcompany.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,NULL,NULL,0,NULL),(26,0,NULL,'2019-09-26 12:06:05','2017-02-12 23:17:04','Calculation Power',1,NULL,NULL,'CU1702-0020',NULL,'411CU17020020',NULL,'',NULL,'Calgary',0,14,NULL,NULL,NULL,'calculationpower@example.com',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'','','','','',NULL,0,NULL,NULL,NULL,3,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,0.000,0,0.000,NULL,NULL,'en_US',NULL,NULL,1,'bookkeepercompany.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,1,'EUR',NULL,0,NULL),(29,0,NULL,'2020-01-13 12:56:22','2020-01-06 00:39:58','Patient',1,NULL,NULL,'CU2001-00022',NULL,'411CU200100022',NULL,'',NULL,NULL,0,117,'01','02',NULL,NULL,'null',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'','','','','',NULL,0,'aa < ddd',NULL,NULL,3,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0.000,NULL,0.000,NULL,NULL,NULL,'patient@cabinetmed',NULL,1,NULL,'','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,0,'',NULL,0,NULL),(30,0,NULL,'2020-01-17 14:21:26','2020-01-13 17:19:24','Italo',1,NULL,NULL,'CU2001-00023',NULL,'411CU200100023',NULL,'12 Alagio','123','Milano',777,3,NULL,NULL,NULL,NULL,'[]',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'','','','','',NULL,0,NULL,NULL,NULL,3,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,0.000,0,0.000,NULL,4,NULL,NULL,NULL,1,NULL,'','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,1,'EUR',NULL,0,NULL); +INSERT INTO `llx_societe` VALUES (1,0,NULL,'2018-01-16 15:21:09','2012-07-08 14:21:44','Indian SAS',1,NULL,NULL,'CU1212-0007','SU1212-0005','7050','6050','1 alalah road',NULL,'Delhi',0,117,NULL,NULL,NULL,NULL,NULL,NULL,4,NULL,'0','','','','','',5000.00000000,1,NULL,NULL,NULL,1,1,NULL,NULL,0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,NULL,NULL,'en_IN',NULL,NULL,1,'indiancompany.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,NULL,NULL,0,NULL),(2,0,NULL,'2018-07-30 11:45:49','2012-07-08 14:23:48','Teclib',1,NULL,NULL,'CU1108-0001','SU1108-0001','411CU11080001','401SU11080001','',NULL,'Paris',0,1,NULL,NULL,'www.teclib.com',NULL,NULL,4,3,57,'0','123456789','','ACE14','','',400000.00000000,0,NULL,NULL,NULL,3,1,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,0.000,NULL,0.000,NULL,NULL,'fr_FR',NULL,NULL,1,'teclibcompany.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,0,'',NULL,0,NULL),(3,0,NULL,'2017-02-16 00:47:25','2012-07-08 22:42:12','Spanish Comp',1,NULL,NULL,'SPANISHCOMP','SU1601-0009',NULL,NULL,'1 via mallere',NULL,'Madrid',123,4,NULL,NULL,NULL,NULL,NULL,3,4,408,'0','','','','','',10000.00000000,0,NULL,NULL,NULL,1,1,NULL,NULL,0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,NULL,NULL,'es_AR',NULL,NULL,1,'spanishcompany.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,NULL,NULL,0,NULL),(4,0,NULL,'2018-01-22 17:24:53','2012-07-08 22:48:18','Prospector Vaalen',1,NULL,NULL,'CU1303-0014',NULL,NULL,NULL,'',NULL,'Bruxelles',103,2,NULL,NULL,NULL,NULL,NULL,3,4,201,'0','12345678','','','','',0.00000000,0,NULL,NULL,NULL,3,0,NULL,'PL_LOW',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'valeencompany.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,NULL,NULL,0,NULL),(5,0,NULL,'2017-02-21 11:01:17','2012-07-08 23:22:57','NoCountry GmBh',1,NULL,NULL,NULL,NULL,NULL,NULL,'',NULL,NULL,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'0','','','','','',0.00000000,0,NULL,NULL,NULL,0,0,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'nocountrycomp.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,1,'EUR',NULL,0,NULL),(6,0,NULL,'2018-01-16 15:35:56','2012-07-09 00:15:09','Swiss Touch',1,NULL,NULL,'CU1601-0018','SU1601-0010',NULL,NULL,'',NULL,'Genevia',0,6,NULL,NULL,NULL,'swisstouch@example.ch',NULL,2,2,601,'0','','','','','',56000.00000000,0,NULL,NULL,NULL,3,1,NULL,NULL,0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'swisstouch.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,NULL,NULL,0,NULL),(7,0,NULL,'2018-01-16 15:38:32','2012-07-09 01:24:26','Generic customer',1,NULL,NULL,'CU1302-0011',NULL,NULL,NULL,'',NULL,NULL,0,7,NULL,NULL,NULL,'ttt@ttt.com',NULL,NULL,8,NULL,'0','','','','','',0.00000000,0,'Generic customer to use for Point Of Sale module.
',NULL,NULL,1,0,NULL,NULL,0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'genericcustomer.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,NULL,NULL,0,NULL),(10,0,NULL,'2020-01-13 12:57:02','2012-07-10 15:13:08','NLTechno',1,NULL,NULL,'CU1212-0005','SU1601-0011','411CU12120005','401SU16010011','',NULL,NULL,0,102,NULL,NULL,NULL,'vsmith@email.com',NULL,1,4,54,'0','493861496','49386149600039','6209Z','22-01-2007','FR123456789',10000.00000000,0,NULL,'aa < aa
\r\ndddd',NULL,1,1,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,'123456789012',NULL,'fr_FR',NULL,NULL,1,'logo_nltechno_94x100.png','','',0,NULL,NULL,NULL,NULL,'The OpenSource company',0,NULL,'generic_odt:/home/ldestailleur/git/dolibarr_11.0/documents/doctemplates/thirdparties/template_thirdparty.ods',0,'',NULL,0,NULL),(11,0,NULL,'2019-11-28 11:52:58','2012-07-10 18:35:57','Company Corp 1',1,NULL,NULL,'CU1510-0017',NULL,'7051',NULL,'21 Green Hill street','75500','Los Angeles',0,11,'444123456',NULL,'companycorp1.com','companycorp1@example.com','{\"skype\":\"corp1\"}',1,1,NULL,'0','AB1234567','','','','USABS123',10000.00000000,0,NULL,NULL,NULL,3,0,NULL,'PL_LOW',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,0.000,NULL,0.000,NULL,NULL,'en_US',NULL,NULL,1,'comapnycorp1company.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,1,'EUR',NULL,0,NULL),(12,0,NULL,'2019-09-26 11:38:11','2012-07-11 16:18:08','Dupont Alain',1,NULL,NULL,'CU1601-0019',NULL,'411CU16010019',NULL,'',NULL,NULL,0,0,NULL,NULL,NULL,'pcurie@example.com',NULL,NULL,NULL,NULL,'0','','','','','',0.00000000,0,NULL,NULL,NULL,1,0,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'pierrecurie.jpg','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,0,'',NULL,0,NULL),(13,0,NULL,'2019-10-08 09:57:51','2012-07-11 17:13:20','Company Corp 2',1,NULL,NULL,'CU1910-00021','SU1510-0008','411CU191000021','401SU15100008','',NULL,NULL,0,1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'0','','','','','',0.00000000,0,NULL,NULL,NULL,3,1,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'companycorp2company.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,1,'EUR',NULL,0,NULL),(17,0,NULL,'2019-11-28 15:02:49','2013-08-01 02:41:26','Book Keeping Company',1,NULL,NULL,'CU1108-0004','SU1108-0004',NULL,'401SU11080004','The French Company',NULL,'Paris',0,1,NULL,NULL,NULL,NULL,'[]',1,NULL,NULL,'0','','','','','',0.00000000,0,NULL,NULL,NULL,0,1,NULL,'',0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,NULL,NULL,NULL,NULL,NULL,1,'bookkeepercompany.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,1,'EUR',NULL,0,NULL),(19,0,NULL,'2019-09-26 12:03:13','2015-01-12 12:23:05','Magic Food Store',1,NULL,NULL,'CU1301-0008',NULL,NULL,NULL,'65 holdywood boulevard','123456','BigTown',0,4,NULL,'0101',NULL,'myemail@domain.com',NULL,NULL,NULL,NULL,'0','','','10/10/2010','','',0.00000000,0,NULL,NULL,NULL,1,0,NULL,NULL,0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,0.000,NULL,0.000,NULL,NULL,'en_US',NULL,NULL,1,'magicfoodstore.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,'sepamandate',NULL,NULL,NULL,0,NULL),(25,0,NULL,'2018-01-22 17:21:17','2015-03-10 15:47:37','Print Company',1,NULL,NULL,'CU1303-0016','SU1303-0007',NULL,NULL,'21 Gutenberg street','45600','Berlin',0,5,NULL,NULL,NULL,'printcompany@example.com',NULL,NULL,NULL,NULL,'0','','','','','',0.00000000,0,NULL,NULL,NULL,0,1,NULL,NULL,0,0,0,1,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0.000,NULL,0.000,NULL,NULL,'de_DE',NULL,NULL,1,'printcompany.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,NULL,NULL,NULL,0,NULL),(26,0,NULL,'2019-09-26 12:06:05','2017-02-12 23:17:04','Calculation Power',1,NULL,NULL,'CU1702-0020',NULL,'411CU17020020',NULL,'',NULL,'Calgary',0,14,NULL,NULL,NULL,'calculationpower@example.com',NULL,NULL,NULL,NULL,NULL,'','','','','',NULL,0,NULL,NULL,NULL,3,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,0,0.000,0,0.000,NULL,NULL,'en_US',NULL,NULL,1,'bookkeepercompany.png','','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,1,'EUR',NULL,0,NULL),(29,0,NULL,'2020-01-13 12:56:22','2020-01-06 00:39:58','Patient',1,NULL,NULL,'CU2001-00022',NULL,'411CU200100022',NULL,'',NULL,NULL,0,117,'01','02',NULL,NULL,'null',NULL,NULL,NULL,NULL,'','','','','',NULL,0,'aa < ddd',NULL,NULL,3,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0.000,NULL,0.000,NULL,NULL,NULL,'patient@cabinetmed',NULL,1,NULL,'','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,0,'',NULL,0,NULL),(30,0,NULL,'2020-01-17 14:21:26','2020-01-13 17:19:24','Italo',1,NULL,NULL,'CU2001-00023',NULL,'411CU200100023',NULL,'12 Alagio','123','Milano',777,3,NULL,NULL,NULL,NULL,'[]',NULL,NULL,NULL,NULL,'','','','','',NULL,0,NULL,NULL,NULL,3,0,NULL,'',0,0,0,12,12,0,0,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,0.000,0,0.000,NULL,4,NULL,NULL,NULL,1,NULL,'','',0,NULL,NULL,NULL,NULL,'',0,NULL,NULL,1,'EUR',NULL,0,NULL); /*!40000 ALTER TABLE `llx_societe` ENABLE KEYS */; UNLOCK TABLES; @@ -11381,6 +11851,8 @@ CREATE TABLE `llx_societe_perentity` ( `rowid` int(11) NOT NULL AUTO_INCREMENT, `fk_soc` int(11) DEFAULT NULL, `entity` int(11) NOT NULL DEFAULT 1, + `accountancy_code_customer` varchar(24) COLLATE utf8_unicode_ci DEFAULT NULL, + `accountancy_code_supplier` varchar(24) COLLATE utf8_unicode_ci DEFAULT NULL, `accountancy_code_sell` varchar(32) COLLATE utf8_unicode_ci DEFAULT NULL, `accountancy_code_buy` varchar(32) COLLATE utf8_unicode_ci DEFAULT NULL, PRIMARY KEY (`rowid`), @@ -11637,16 +12109,6 @@ CREATE TABLE `llx_socpeople` ( `fax` varchar(30) COLLATE utf8_unicode_ci DEFAULT NULL, `email` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `socialnetworks` text COLLATE utf8_unicode_ci DEFAULT NULL, - `jabberid` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `skype` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `whatsapp` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `linkedin` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `youtube` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `googleplus` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `snapchat` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `instagram` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `facebook` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, - `twitter` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `photo` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `priv` smallint(6) NOT NULL DEFAULT 0, `fk_prospectcontactlevel` varchar(12) COLLATE utf8_unicode_ci DEFAULT NULL, @@ -11674,7 +12136,7 @@ CREATE TABLE `llx_socpeople` ( LOCK TABLES `llx_socpeople` WRITE; /*!40000 ALTER TABLE `llx_socpeople` DISABLE KEYS */; -INSERT INTO `llx_socpeople` VALUES (1,'2012-07-08 14:26:14','2019-11-28 11:52:58',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2012-07-08','Project leader','','','','','','[]',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2012-07-08 22:44:50','2019-11-28 11:52:58',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','[]',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2012-07-08 22:59:02','2019-11-28 11:52:58',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','[]',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,NULL,0,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2012-07-09 00:16:58','2019-11-28 11:52:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','[]',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2013-08-01 02:41:26','2019-11-28 11:52:58',17,1,NULL,'','Bookkeeper','Bob','','','',NULL,NULL,NULL,'book keeper','','','','','bbookkeeper@example.com','{\"skype\":\"skypebbookkeeper\"}',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'',0,NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2018-07-30 16:11:06','2019-11-28 11:52:58',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','[]',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'',1,NULL,0,0,12,12,'','',NULL,NULL,NULL,1),(8,'2018-07-30 16:13:03','2019-11-28 11:52:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','[]',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'',1,NULL,0,0,12,12,'','',NULL,NULL,NULL,1),(9,'2018-07-30 16:14:41','2019-11-28 11:52:58',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','[]',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'',0,NULL,0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2018-07-30 16:26:22','2019-11-28 11:52:58',10,1,'','','Destailleur','Laurent','','','',NULL,NULL,'1972-10-10','Dolibarr project leader','','','','','ldestailleur@example.com','[]',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'ldestailleur_200x200.jpg',0,NULL,0,0,NULL,12,'','',NULL,NULL,NULL,1),(11,'2017-05-12 13:16:36','2019-11-28 11:52:58',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','[]',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'ldestailleur_200x200.png',0,NULL,0,0,12,12,'','',NULL,NULL,NULL,1),(12,'2017-05-12 13:19:31','2019-11-28 11:52:58',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','[]',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'Einstein.jpg',0,NULL,0,0,12,12,'','',NULL,NULL,NULL,1); +INSERT INTO `llx_socpeople` VALUES (1,'2012-07-08 14:26:14','2019-11-28 11:52:58',1,1,NULL,'MR','Indra','Mahala','','','',297,117,'2012-07-08','Project leader','','','','','','[]',NULL,0,NULL,0,0,1,12,'Met during a congress at Dubai','',NULL,NULL,NULL,1),(2,'2012-07-08 22:44:50','2019-11-28 11:52:58',NULL,1,NULL,'MR','Freeman','Public','','','',200,11,NULL,'','','','','','','[]',NULL,0,NULL,0,0,1,1,'A friend that is a free contact not linked to any company',NULL,NULL,NULL,NULL,1),(3,'2012-07-08 22:59:02','2019-11-28 11:52:58',NULL,1,NULL,'MR','Mywife','Nicy','','','',NULL,11,'1980-10-03','','','','','','','[]',NULL,1,NULL,0,0,1,12,'This is a private contact','',NULL,NULL,NULL,1),(4,'2012-07-09 00:16:58','2019-11-28 11:52:58',6,1,NULL,'MR','Rotchield','Evan','','','',NULL,6,NULL,'Bank director','','','','','','[]',NULL,0,NULL,0,0,1,1,'The bank director',NULL,NULL,NULL,NULL,1),(6,'2013-08-01 02:41:26','2019-11-28 11:52:58',17,1,NULL,'','Bookkeeper','Bob','','','',NULL,NULL,NULL,'book keeper','','','','','bbookkeeper@example.com','{\"skype\":\"skypebbookkeeper\"}','',0,NULL,0,0,1,12,'','',NULL,NULL,NULL,1),(7,'2018-07-30 16:11:06','2019-11-28 11:52:58',NULL,1,'','MR','Dad','','','','',NULL,14,'1967-09-04','','','','','','','[]','',1,NULL,0,0,12,12,'','',NULL,NULL,NULL,1),(8,'2018-07-30 16:13:03','2019-11-28 11:52:58',NULL,1,'','MLE','Mom','','','','',NULL,14,NULL,'','','','','','','[]','',1,NULL,0,0,12,12,'','',NULL,NULL,NULL,1),(9,'2018-07-30 16:14:41','2019-11-28 11:52:58',NULL,1,'','MR','Francky','','','89455','Virigia',NULL,205,'1980-07-09','Baker','555-98989898','','','','francky@example.com','[]','',0,NULL,0,0,12,12,'','',NULL,NULL,NULL,1),(10,'2018-07-30 16:26:22','2019-11-28 11:52:58',10,1,'','','Destailleur','Laurent','','','',NULL,NULL,'1972-10-10','Dolibarr project leader','','','','','ldestailleur@example.com','[]','ldestailleur_200x200.jpg',0,NULL,0,0,NULL,12,'','',NULL,NULL,NULL,1),(11,'2017-05-12 13:16:36','2019-11-28 11:52:58',11,1,'','MR','Smith','Laurent','45 Big road','897','Seattle',NULL,11,NULL,'Director','','','','','','[]','ldestailleur_200x200.png',0,NULL,0,0,12,12,'','',NULL,NULL,NULL,1),(12,'2017-05-12 13:19:31','2019-11-28 11:52:58',11,1,'','MR','Einstein','','','','',NULL,11,NULL,'Genius','333444555','','','','genius@example.com','[]','Einstein.jpg',0,NULL,0,0,12,12,'','',NULL,NULL,NULL,1); /*!40000 ALTER TABLE `llx_socpeople` ENABLE KEYS */; UNLOCK TABLES; @@ -11723,7 +12185,7 @@ CREATE TABLE `llx_stock_mouvement` ( `fk_user_author` int(11) DEFAULT NULL, `label` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `fk_origin` int(11) DEFAULT NULL, - `origintype` varchar(32) COLLATE utf8_unicode_ci DEFAULT NULL, + `origintype` varchar(64) COLLATE utf8_unicode_ci DEFAULT NULL, `model_pdf` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `fk_projet` int(11) NOT NULL DEFAULT 0, `inventorycode` varchar(128) COLLATE utf8_unicode_ci DEFAULT NULL, @@ -11827,7 +12289,7 @@ CREATE TABLE `llx_supplier_proposal` ( `import_key` varchar(14) COLLATE utf8_unicode_ci DEFAULT NULL, `extraparams` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_tx` double(24,8) DEFAULT 1.00000000, `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000, `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000, @@ -11843,7 +12305,7 @@ CREATE TABLE `llx_supplier_proposal` ( LOCK TABLES `llx_supplier_proposal` WRITE; /*!40000 ALTER TABLE `llx_supplier_proposal` DISABLE KEYS */; -INSERT INTO `llx_supplier_proposal` VALUES (2,'(PROV2)',1,NULL,NULL,10,NULL,'2021-04-15 10:22:31','2021-02-17 04:40:14',NULL,NULL,12,12,NULL,NULL,0,0,NULL,NULL,0,290.00000000,0.00000000,0.00000000,0.00000000,290.00000000,NULL,NULL,2,7,'Private note','Public note','aurore','2017-02-17',1,NULL,NULL,1,'EUR',1.00000000,290.00000000,0.00000000,290.00000000,NULL),(3,'(PROV3)',1,NULL,NULL,1,NULL,'2021-04-15 10:22:31','2021-01-20 12:06:39',NULL,NULL,12,NULL,NULL,NULL,0,0,NULL,NULL,0,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL,'','','aurore',NULL,NULL,NULL,NULL,1,'EUR',1.00000000,0.00000000,0.00000000,0.00000000,NULL),(4,'(PROV4)',1,NULL,NULL,17,NULL,'2021-04-15 10:22:31','2021-01-20 12:23:22',NULL,NULL,12,NULL,NULL,NULL,0,0,NULL,NULL,0,195.00000000,0.00000000,0.00000000,0.00000000,195.00000000,NULL,NULL,NULL,NULL,'','','aurore',NULL,NULL,NULL,NULL,1,'EUR',1.00000000,195.00000000,0.00000000,195.00000000,NULL); +INSERT INTO `llx_supplier_proposal` VALUES (2,'(PROV2)',1,NULL,NULL,10,NULL,'2021-04-15 10:22:31','2021-02-17 04:40:14',NULL,NULL,12,12,NULL,NULL,0,0,NULL,NULL,0,290.00000000,0.00000000,0.00000000,0.00000000,290.00000000,NULL,NULL,2,7,'Private note','Public note','aurore','2017-02-17',1,NULL,NULL,1,'EUR',1.00000000,290.00000000,0.00000000,290.00000000,NULL),(3,'(PROV3)',1,NULL,NULL,1,NULL,'2022-02-07 13:37:54','2022-01-20 12:06:39',NULL,NULL,12,NULL,NULL,NULL,0,0,NULL,NULL,0,0.00000000,0.00000000,0.00000000,0.00000000,0.00000000,NULL,NULL,NULL,NULL,'','','aurore',NULL,NULL,NULL,NULL,1,'EUR',1.00000000,0.00000000,0.00000000,0.00000000,NULL),(4,'(PROV4)',1,NULL,NULL,17,NULL,'2022-02-07 13:37:54','2022-01-20 12:23:22',NULL,NULL,12,NULL,NULL,NULL,0,0,NULL,NULL,0,195.00000000,0.00000000,0.00000000,0.00000000,195.00000000,NULL,NULL,NULL,NULL,'','','aurore',NULL,NULL,NULL,NULL,1,'EUR',1.00000000,195.00000000,0.00000000,195.00000000,NULL); /*!40000 ALTER TABLE `llx_supplier_proposal` ENABLE KEYS */; UNLOCK TABLES; @@ -11912,7 +12374,7 @@ CREATE TABLE `llx_supplier_proposaldet` ( `rang` int(11) DEFAULT 0, `ref_fourn` varchar(30) COLLATE utf8_unicode_ci DEFAULT NULL, `fk_multicurrency` int(11) DEFAULT NULL, - `multicurrency_code` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL, + `multicurrency_code` varchar(3) COLLATE utf8_unicode_ci DEFAULT NULL, `multicurrency_subprice` double(24,8) DEFAULT 0.00000000, `multicurrency_total_ht` double(24,8) DEFAULT 0.00000000, `multicurrency_total_tva` double(24,8) DEFAULT 0.00000000, @@ -12013,7 +12475,7 @@ CREATE TABLE `llx_ticket` ( `message` mediumtext COLLATE utf8_unicode_ci DEFAULT NULL, `fk_statut` int(11) DEFAULT NULL, `resolution` int(11) DEFAULT NULL, - `progress` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL, + `progress` int(11) DEFAULT NULL, `timing` varchar(20) COLLATE utf8_unicode_ci DEFAULT NULL, `type_code` varchar(32) COLLATE utf8_unicode_ci DEFAULT NULL, `category_code` varchar(32) COLLATE utf8_unicode_ci DEFAULT NULL, @@ -12042,7 +12504,7 @@ CREATE TABLE `llx_ticket` ( LOCK TABLES `llx_ticket` WRITE; /*!40000 ALTER TABLE `llx_ticket` DISABLE KEYS */; -INSERT INTO `llx_ticket` VALUES (2,1,'TS1909-0001','15ff11cay39skiaa',NULL,6,NULL,12,12,'Increase memory on server','Pleae increase the memory of server to 164GB',3,NULL,'0',NULL,'REQUEST','OTHER','NORMAL','2020-09-26 14:08:46',NULL,NULL,0,'2021-04-15 10:22:31',NULL,NULL),(3,1,'TS1909-0002','r5ya6gdi9f39dcjt',1,NULL,NULL,12,14,'Problem with customer','Please recontact customer.
\r\nNeed someone speaking chinese...',0,NULL,'100',NULL,'ISSUE','OTHER','NORMAL','2020-09-26 14:10:31',NULL,'2020-10-04 13:05:55',0,'2021-04-15 10:22:31',NULL,NULL),(4,1,'TS1910-0003','fdv9wrzcte7b3c8b',NULL,NULL,NULL,12,NULL,'test','test',2,NULL,'0',NULL,'COM','OTHER','NORMAL','2020-10-04 12:58:04',NULL,NULL,0,'2021-04-15 10:22:31',NULL,NULL),(6,1,'TS1911-0004','5gvo9bsjri55zef9',NULL,4,NULL,12,16,'What is the price for Dolibarr ERP CRM ?','I need to use it for 10 users.',3,NULL,'0',NULL,'COM','OTHER','NORMAL','2020-11-29 12:46:29','2020-11-29 12:46:34',NULL,0,'2021-04-15 10:22:31',NULL,NULL),(7,1,'TS1911-0005','d51wjy4nym7wltg7',NULL,NULL,'customer@customercompany.com',NULL,16,'What is the price for Dolibarr ERP CRM ?','I need it for 10 people...',8,NULL,'100',NULL,'COM','OTHER','NORMAL','2020-11-29 12:50:45','2020-11-29 12:52:32','2020-11-29 12:55:48',1,'2021-04-15 10:22:31',NULL,NULL); +INSERT INTO `llx_ticket` VALUES (2,1,'TS1909-0001','15ff11cay39skiaa',NULL,6,NULL,12,12,'Increase memory on server','Pleae increase the memory of server to 164GB',3,NULL,0,NULL,'REQUEST','OTHER','NORMAL','2021-09-26 14:08:46',NULL,NULL,0,'2022-02-07 13:37:54',NULL,NULL),(3,1,'TS1909-0002','r5ya6gdi9f39dcjt',1,NULL,NULL,12,14,'Problem with customer','Please recontact customer.
\r\nNeed someone speaking chinese...',0,NULL,100,NULL,'ISSUE','OTHER','NORMAL','2021-09-26 14:10:31',NULL,'2021-10-04 13:05:55',0,'2022-02-07 13:37:54',NULL,NULL),(4,1,'TS1910-0003','fdv9wrzcte7b3c8b',NULL,NULL,NULL,12,NULL,'test','test',2,NULL,0,NULL,'COM','OTHER','NORMAL','2021-10-04 12:58:04',NULL,NULL,0,'2022-02-07 13:37:54',NULL,NULL),(6,1,'TS1911-0004','5gvo9bsjri55zef9',NULL,4,NULL,12,16,'What is the price for Dolibarr ERP CRM ?','I need to use it for 10 users.',3,NULL,0,NULL,'COM','OTHER','NORMAL','2021-11-29 12:46:29','2021-11-29 12:46:34',NULL,0,'2022-02-07 13:37:54',NULL,NULL),(7,1,'TS1911-0005','d51wjy4nym7wltg7',NULL,NULL,'customer@customercompany.com',NULL,16,'What is the price for Dolibarr ERP CRM ?','I need it for 10 people...',8,NULL,100,NULL,'COM','OTHER','NORMAL','2021-11-29 12:50:45','2021-11-29 12:52:32','2021-11-29 12:55:48',1,'2022-02-07 13:37:54',NULL,NULL); /*!40000 ALTER TABLE `llx_ticket` ENABLE KEYS */; UNLOCK TABLES; @@ -12416,7 +12878,7 @@ CREATE TABLE `llx_user_rights` ( UNIQUE KEY `uk_user_rights` (`entity`,`fk_user`,`fk_id`), KEY `fk_user_rights_fk_user_user` (`fk_user`), CONSTRAINT `fk_user_rights_fk_user_user` FOREIGN KEY (`fk_user`) REFERENCES `llx_user` (`rowid`) -) ENGINE=InnoDB AUTO_INCREMENT=20602 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +) ENGINE=InnoDB AUTO_INCREMENT=20841 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; /*!40101 SET character_set_client = @saved_cs_client */; -- @@ -12425,7 +12887,7 @@ CREATE TABLE `llx_user_rights` ( LOCK TABLES `llx_user_rights` WRITE; /*!40000 ALTER TABLE `llx_user_rights` DISABLE KEYS */; -INSERT INTO `llx_user_rights` VALUES (12402,1,1,11),(12380,1,1,12),(12385,1,1,13),(12389,1,1,14),(12393,1,1,15),(12398,1,1,16),(12404,1,1,19),(9726,1,1,21),(9700,1,1,22),(9706,1,1,24),(9711,1,1,25),(9716,1,1,26),(9722,1,1,27),(9728,1,1,28),(9978,1,1,31),(9968,1,1,32),(9974,1,1,34),(1910,1,1,36),(9980,1,1,38),(11573,1,1,41),(11574,1,1,42),(11575,1,1,44),(11576,1,1,45),(7184,1,1,61),(7181,1,1,62),(7183,1,1,64),(7185,1,1,67),(7186,1,1,68),(1678,1,1,71),(1673,1,1,72),(1675,1,1,74),(1679,1,1,75),(1677,1,1,76),(1681,1,1,78),(1682,1,1,79),(12322,1,1,81),(12309,1,1,82),(12312,1,1,84),(12314,1,1,86),(12317,1,1,87),(12320,1,1,88),(12323,1,1,89),(11580,1,1,91),(11581,1,1,92),(11582,1,1,93),(11583,1,1,94),(10097,1,1,95),(10099,1,1,96),(10103,1,1,97),(10104,1,1,98),(7139,1,1,101),(7134,1,1,102),(7136,1,1,104),(7137,1,1,105),(7138,1,1,106),(7140,1,1,109),(10229,1,1,111),(10201,1,1,112),(10207,1,1,113),(10213,1,1,114),(10219,1,1,115),(10225,1,1,116),(10231,1,1,117),(12518,1,1,121),(12508,1,1,122),(12514,1,1,125),(12520,1,1,126),(11577,1,1,141),(11578,1,1,142),(11579,1,1,144),(2307,1,1,151),(2304,1,1,152),(2306,1,1,153),(2308,1,1,154),(10092,1,1,161),(10093,1,1,162),(10094,1,1,163),(10095,1,1,164),(10096,1,1,165),(1585,1,1,170),(12342,1,1,171),(12331,1,1,172),(12335,1,1,173),(12339,1,1,174),(12343,1,1,178),(10000,1,1,221),(9990,1,1,222),(9996,1,1,223),(10002,1,1,229),(10007,1,1,237),(10011,1,1,238),(10015,1,1,239),(1686,1,1,241),(1685,1,1,242),(1687,1,1,243),(12604,1,1,251),(12566,1,1,252),(12569,1,1,253),(12572,1,1,254),(12575,1,1,255),(12579,1,1,256),(1617,1,1,258),(12525,1,1,262),(12544,1,1,281),(12534,1,1,282),(12540,1,1,283),(12546,1,1,286),(12288,1,1,300),(12290,1,1,301),(11591,1,1,302),(1763,1,1,331),(1762,1,1,332),(1764,1,1,333),(12582,1,1,341),(12584,1,1,342),(12586,1,1,343),(12588,1,1,344),(12600,1,1,351),(12593,1,1,352),(12597,1,1,353),(12601,1,1,354),(12605,1,1,358),(12560,1,1,531),(12553,1,1,532),(12557,1,1,534),(1625,1,1,536),(12561,1,1,538),(12358,1,1,700),(12348,1,1,701),(12354,1,1,702),(12360,1,1,703),(1755,1,1,1001),(1754,1,1,1002),(1756,1,1,1003),(1758,1,1,1004),(1759,1,1,1005),(7146,1,1,1101),(7143,1,1,1102),(7145,1,1,1104),(7147,1,1,1109),(12412,1,1,1181),(12458,1,1,1182),(12417,1,1,1183),(12420,1,1,1184),(12423,1,1,1185),(12427,1,1,1186),(12431,1,1,1187),(12437,1,1,1188),(12434,1,1,1189),(1578,1,1,1201),(1579,1,1,1202),(12454,1,1,1231),(12443,1,1,1232),(12446,1,1,1233),(12449,1,1,1234),(12452,1,1,1235),(12455,1,1,1236),(12459,1,1,1237),(1736,1,1,1251),(12409,1,1,1321),(12326,1,1,1421),(8190,1,1,1791),(8187,1,1,1792),(8191,1,1,1793),(12264,1,1,2401),(12260,1,1,2402),(12266,1,1,2403),(12280,1,1,2411),(12276,1,1,2412),(12282,1,1,2413),(12286,1,1,2414),(1618,1,1,2500),(12370,1,1,2501),(12367,1,1,2503),(12371,1,1,2515),(9610,1,1,5001),(9611,1,1,5002),(12490,1,1,20001),(12474,1,1,20003),(12480,1,1,20004),(12486,1,1,20005),(12492,1,1,20006),(12302,1,1,23001),(12295,1,1,23002),(12299,1,1,23003),(12303,1,1,23004),(7701,1,1,50101),(4984,1,1,50401),(4983,1,1,50402),(4985,1,1,50403),(4987,1,1,50411),(4988,1,1,50412),(4989,1,1,50415),(12498,1,1,55001),(12499,1,1,55002),(3564,1,1,100700),(3565,1,1,100701),(9596,1,1,101051),(9598,1,1,101052),(9600,1,1,101053),(9604,1,1,101060),(9605,1,1,101061),(7177,1,1,101201),(7178,1,1,101202),(10353,1,1,101250),(10355,1,1,101251),(8980,1,1,101261),(8981,1,1,101262),(7616,1,1,101331),(10030,1,1,101701),(10031,1,1,101702),(3582,1,1,102000),(3583,1,1,102001),(9819,1,1,400051),(9823,1,1,400052),(9827,1,1,400053),(9831,1,1,400055),(132,1,2,11),(133,1,2,12),(134,1,2,13),(135,1,2,14),(136,1,2,16),(137,1,2,19),(138,1,2,21),(139,1,2,22),(140,1,2,24),(141,1,2,25),(142,1,2,26),(143,1,2,27),(10359,1,2,31),(145,1,2,32),(10361,1,2,34),(146,1,2,36),(147,1,2,41),(148,1,2,42),(149,1,2,44),(150,1,2,61),(151,1,2,62),(152,1,2,64),(153,1,2,71),(154,1,2,72),(155,1,2,74),(156,1,2,75),(157,1,2,78),(158,1,2,79),(159,1,2,81),(160,1,2,82),(161,1,2,84),(162,1,2,86),(163,1,2,87),(164,1,2,88),(165,1,2,89),(166,1,2,91),(167,1,2,92),(168,1,2,93),(2475,1,2,95),(2476,1,2,96),(2477,1,2,97),(2478,1,2,98),(169,1,2,101),(170,1,2,102),(171,1,2,104),(172,1,2,109),(173,1,2,111),(174,1,2,112),(175,1,2,113),(176,1,2,114),(177,1,2,116),(178,1,2,117),(179,1,2,121),(180,1,2,122),(181,1,2,125),(182,1,2,141),(183,1,2,142),(184,1,2,144),(2479,1,2,151),(2480,1,2,152),(2481,1,2,153),(2482,1,2,154),(185,1,2,161),(186,1,2,162),(187,1,2,163),(188,1,2,164),(189,1,2,165),(190,1,2,170),(2471,1,2,171),(192,1,2,172),(2472,1,2,173),(193,1,2,221),(194,1,2,222),(195,1,2,229),(196,1,2,241),(197,1,2,242),(198,1,2,243),(199,1,2,251),(201,1,2,262),(202,1,2,281),(203,1,2,282),(204,1,2,283),(205,1,2,331),(15072,1,2,510),(2483,1,2,531),(207,1,2,532),(2484,1,2,534),(208,1,2,536),(2473,1,2,700),(210,1,2,701),(211,1,2,702),(2474,1,2,703),(15064,1,2,771),(15057,1,2,772),(15059,1,2,773),(15061,1,2,774),(15063,1,2,775),(15065,1,2,776),(212,1,2,1001),(213,1,2,1002),(214,1,2,1003),(215,1,2,1004),(216,1,2,1005),(217,1,2,1101),(218,1,2,1102),(219,1,2,1104),(220,1,2,1109),(15073,1,2,1121),(15074,1,2,1122),(15075,1,2,1123),(15076,1,2,1124),(15077,1,2,1125),(15078,1,2,1126),(221,1,2,1181),(222,1,2,1182),(223,1,2,1183),(224,1,2,1184),(225,1,2,1185),(226,1,2,1186),(227,1,2,1187),(228,1,2,1188),(229,1,2,1201),(230,1,2,1202),(231,1,2,1231),(232,1,2,1232),(233,1,2,1233),(234,1,2,1234),(235,1,2,1421),(236,1,2,2401),(237,1,2,2402),(238,1,2,2403),(239,1,2,2411),(240,1,2,2412),(241,1,2,2413),(242,1,2,2500),(2470,1,2,2501),(243,1,2,2515),(10363,1,2,20001),(10365,1,2,20003),(10366,1,2,20004),(10367,1,2,20005),(10368,1,2,20006),(15054,1,2,23001),(10362,1,2,50101),(15067,1,2,55001),(15066,1,2,59001),(15068,1,2,63001),(15069,1,2,63002),(15070,1,2,63003),(15071,1,2,63004),(10372,1,2,101250),(1807,1,3,11),(1808,1,3,31),(1809,1,3,36),(1810,1,3,41),(1811,1,3,61),(1812,1,3,71),(1813,1,3,72),(1814,1,3,74),(1815,1,3,75),(1816,1,3,78),(1817,1,3,79),(1818,1,3,91),(1819,1,3,95),(1820,1,3,97),(1821,1,3,111),(1822,1,3,121),(1823,1,3,122),(1824,1,3,125),(1825,1,3,161),(1826,1,3,170),(1827,1,3,171),(1828,1,3,172),(1829,1,3,221),(1830,1,3,222),(1831,1,3,229),(1832,1,3,241),(1833,1,3,242),(1834,1,3,243),(1835,1,3,251),(1836,1,3,255),(1837,1,3,256),(1838,1,3,262),(1839,1,3,281),(1840,1,3,282),(1841,1,3,283),(1842,1,3,331),(1843,1,3,531),(1844,1,3,536),(1845,1,3,700),(1846,1,3,1001),(1847,1,3,1002),(1848,1,3,1003),(1849,1,3,1004),(1850,1,3,1005),(1851,1,3,1181),(1852,1,3,1182),(1853,1,3,1201),(1854,1,3,1202),(1855,1,3,1231),(1856,1,3,2401),(1857,1,3,2402),(1858,1,3,2403),(1859,1,3,2411),(1860,1,3,2412),(1861,1,3,2413),(1862,1,3,2500),(1863,1,3,2515),(8026,1,4,11),(8027,1,4,21),(8028,1,4,31),(8029,1,4,41),(8030,1,4,61),(8031,1,4,71),(8032,1,4,72),(8033,1,4,74),(8034,1,4,75),(8035,1,4,78),(8036,1,4,79),(8037,1,4,81),(8038,1,4,91),(8039,1,4,95),(8040,1,4,97),(8041,1,4,101),(8042,1,4,111),(8043,1,4,121),(8044,1,4,151),(8045,1,4,161),(8046,1,4,171),(8047,1,4,221),(8048,1,4,222),(8049,1,4,229),(8050,1,4,241),(8051,1,4,242),(8052,1,4,243),(8146,1,4,251),(8147,1,4,253),(8053,1,4,262),(8054,1,4,281),(8055,1,4,331),(8056,1,4,341),(8057,1,4,342),(8058,1,4,343),(8059,1,4,344),(8060,1,4,531),(8061,1,4,700),(8062,1,4,1001),(8063,1,4,1002),(8064,1,4,1003),(8065,1,4,1004),(8066,1,4,1005),(8067,1,4,1101),(8068,1,4,1181),(8069,1,4,1182),(8070,1,4,1201),(8071,1,4,1202),(8072,1,4,1231),(8073,1,4,2401),(8074,1,4,2501),(8075,1,4,2503),(8076,1,4,2515),(8077,1,4,20001),(8078,1,4,50101),(8079,1,4,101201),(8080,1,4,101261),(8081,1,4,102000),(8082,1,4,400051),(8083,1,4,400052),(8084,1,4,400053),(8085,1,4,400055),(12608,1,10,11),(12609,1,10,21),(12610,1,10,31),(12611,1,10,41),(12612,1,10,61),(12613,1,10,71),(12614,1,10,72),(12615,1,10,74),(12616,1,10,75),(12617,1,10,78),(12618,1,10,79),(12619,1,10,81),(12620,1,10,91),(12621,1,10,95),(12622,1,10,97),(12623,1,10,101),(12624,1,10,111),(12625,1,10,121),(12626,1,10,151),(12627,1,10,161),(12628,1,10,171),(12629,1,10,221),(12630,1,10,222),(12631,1,10,229),(12632,1,10,241),(12633,1,10,242),(12634,1,10,243),(12635,1,10,262),(12636,1,10,281),(12637,1,10,300),(12638,1,10,331),(12639,1,10,341),(12640,1,10,342),(12641,1,10,343),(12642,1,10,344),(12643,1,10,531),(12644,1,10,700),(12645,1,10,1001),(12646,1,10,1002),(12647,1,10,1003),(12648,1,10,1004),(12649,1,10,1005),(12650,1,10,1101),(12651,1,10,1181),(12652,1,10,1182),(12653,1,10,1201),(12654,1,10,1202),(12655,1,10,1231),(12656,1,10,2401),(12657,1,10,2501),(12658,1,10,2503),(12659,1,10,2515),(12660,1,10,20001),(12662,1,10,23001),(12663,1,10,50101),(12664,1,11,11),(12665,1,11,21),(12666,1,11,31),(12667,1,11,41),(12668,1,11,61),(12669,1,11,71),(12670,1,11,72),(12671,1,11,74),(12672,1,11,75),(12673,1,11,78),(12674,1,11,79),(12675,1,11,81),(12676,1,11,91),(12677,1,11,95),(12678,1,11,97),(12679,1,11,101),(12680,1,11,111),(12681,1,11,121),(12682,1,11,151),(12683,1,11,161),(12684,1,11,171),(12685,1,11,221),(12686,1,11,222),(12687,1,11,229),(12688,1,11,241),(12689,1,11,242),(12690,1,11,243),(12691,1,11,262),(12692,1,11,281),(12693,1,11,300),(12694,1,11,331),(12695,1,11,341),(12696,1,11,342),(12697,1,11,343),(12698,1,11,344),(12699,1,11,531),(12700,1,11,700),(12701,1,11,1001),(12702,1,11,1002),(12703,1,11,1003),(12704,1,11,1004),(12705,1,11,1005),(12706,1,11,1101),(12707,1,11,1181),(12708,1,11,1182),(12709,1,11,1201),(12710,1,11,1202),(12711,1,11,1231),(12712,1,11,2401),(12713,1,11,2501),(12714,1,11,2503),(12715,1,11,2515),(12716,1,11,20001),(12718,1,11,23001),(12719,1,11,50101),(20456,1,12,11),(20448,1,12,12),(20449,1,12,13),(20450,1,12,14),(20451,1,12,15),(20454,1,12,16),(20457,1,12,19),(14146,1,12,21),(14135,1,12,22),(14137,1,12,24),(14139,1,12,25),(14142,1,12,26),(14145,1,12,27),(14148,1,12,28),(14930,1,12,31),(14926,1,12,32),(14929,1,12,34),(14932,1,12,38),(13816,1,12,41),(13813,1,12,42),(13815,1,12,44),(13817,1,12,45),(14094,1,12,61),(14091,1,12,62),(14093,1,12,64),(14095,1,12,67),(14096,1,12,68),(16203,1,12,71),(16198,1,12,72),(16200,1,12,74),(16204,1,12,75),(16202,1,12,76),(16206,1,12,78),(16207,1,12,79),(20413,1,12,81),(20408,1,12,82),(20409,1,12,84),(20410,1,12,86),(20411,1,12,87),(20412,1,12,88),(20414,1,12,89),(15401,1,12,91),(15397,1,12,92),(15400,1,12,93),(15403,1,12,94),(13990,1,12,95),(12734,1,12,97),(19241,1,12,101),(19237,1,12,102),(19238,1,12,104),(19239,1,12,105),(19240,1,12,106),(19242,1,12,109),(20395,1,12,111),(20381,1,12,112),(20384,1,12,113),(20387,1,12,114),(20390,1,12,115),(20393,1,12,116),(20396,1,12,117),(20547,1,12,121),(20542,1,12,122),(20545,1,12,125),(20548,1,12,126),(13821,1,12,141),(13820,1,12,142),(13822,1,12,144),(13912,1,12,151),(13909,1,12,152),(13911,1,12,153),(13913,1,12,154),(14063,1,12,161),(14056,1,12,162),(14058,1,12,163),(14060,1,12,164),(14062,1,12,165),(14064,1,12,167),(13350,1,12,171),(13345,1,12,172),(13347,1,12,173),(13349,1,12,174),(13351,1,12,178),(13838,1,12,221),(13834,1,12,222),(13837,1,12,223),(13840,1,12,229),(13842,1,12,237),(13844,1,12,238),(13846,1,12,239),(13516,1,12,241),(13515,1,12,242),(13517,1,12,243),(20591,1,12,251),(20572,1,12,252),(20574,1,12,253),(20575,1,12,254),(20577,1,12,255),(20579,1,12,256),(20549,1,12,262),(20559,1,12,281),(20554,1,12,282),(20557,1,12,283),(20560,1,12,286),(19877,1,12,300),(20397,1,12,301),(20398,1,12,302),(16194,1,12,331),(16193,1,12,332),(16195,1,12,333),(20580,1,12,341),(20581,1,12,342),(20582,1,12,343),(20583,1,12,344),(20589,1,12,351),(20586,1,12,352),(20588,1,12,353),(20590,1,12,354),(20592,1,12,358),(19249,1,12,430),(16384,1,12,501),(16378,1,12,502),(13865,1,12,510),(20529,1,12,511),(20524,1,12,512),(20526,1,12,514),(20528,1,12,517),(20530,1,12,519),(15291,1,12,520),(15286,1,12,522),(15288,1,12,524),(15290,1,12,525),(15292,1,12,527),(20536,1,12,531),(20533,1,12,532),(20535,1,12,534),(20537,1,12,538),(20076,1,12,561),(20073,1,12,562),(20075,1,12,563),(20077,1,12,564),(16932,1,12,650),(20375,1,12,651),(20374,1,12,652),(20376,1,12,653),(17124,1,12,660),(20504,1,12,661),(20503,1,12,662),(20505,1,12,663),(13358,1,12,700),(20422,1,12,701),(20420,1,12,702),(20423,1,12,703),(20513,1,12,750),(20512,1,12,751),(20514,1,12,752),(20442,1,12,771),(20431,1,12,772),(20433,1,12,773),(15085,1,12,774),(20435,1,12,775),(20437,1,12,776),(20439,1,12,777),(20441,1,12,778),(20443,1,12,779),(14917,1,12,1001),(14916,1,12,1002),(14918,1,12,1003),(14920,1,12,1004),(14921,1,12,1005),(19247,1,12,1101),(19245,1,12,1102),(19246,1,12,1104),(19248,1,12,1109),(19233,1,12,1121),(19226,1,12,1122),(19228,1,12,1123),(19230,1,12,1124),(19232,1,12,1125),(19234,1,12,1126),(20460,1,12,1181),(20474,1,12,1182),(20463,1,12,1183),(20464,1,12,1184),(20466,1,12,1185),(20468,1,12,1186),(20470,1,12,1187),(20473,1,12,1188),(20471,1,12,1189),(20475,1,12,1191),(13827,1,12,1201),(13828,1,12,1202),(20483,1,12,1231),(20478,1,12,1232),(20479,1,12,1233),(20481,1,12,1234),(20482,1,12,1235),(20484,1,12,1236),(16302,1,12,1237),(13829,1,12,1251),(20458,1,12,1321),(20459,1,12,1322),(20415,1,12,1421),(20361,1,12,2401),(20359,1,12,2402),(20362,1,12,2403),(20369,1,12,2411),(20367,1,12,2412),(20370,1,12,2413),(20371,1,12,2414),(20427,1,12,2501),(20426,1,12,2503),(20428,1,12,2515),(20082,1,12,3200),(20341,1,12,3301),(15435,1,12,5001),(15436,1,12,5002),(20600,1,12,10001),(20595,1,12,10002),(20597,1,12,10003),(20599,1,12,10005),(20601,1,12,10008),(20496,1,12,20001),(20487,1,12,20002),(20489,1,12,20003),(20493,1,12,20004),(20495,1,12,20005),(20497,1,12,20006),(20491,1,12,20007),(20404,1,12,23001),(20401,1,12,23002),(20403,1,12,23003),(20405,1,12,23004),(19019,1,12,50101),(20568,1,12,50151),(20569,1,12,50152),(20570,1,12,50153),(20343,1,12,50401),(20351,1,12,50411),(20346,1,12,50412),(20348,1,12,50414),(20350,1,12,50415),(20352,1,12,50418),(20353,1,12,50420),(20354,1,12,50430),(20342,1,12,50440),(20507,1,12,55001),(20508,1,12,55002),(20566,1,12,56001),(20563,1,12,56002),(20565,1,12,56003),(20567,1,12,56004),(16742,1,12,56005),(20498,1,12,59001),(20499,1,12,59002),(20500,1,12,59003),(20520,1,12,63001),(20517,1,12,63002),(20519,1,12,63003),(20521,1,12,63004),(20509,1,12,64001),(17328,1,12,101130),(17327,1,12,101131),(17329,1,12,101132),(16009,1,12,101331),(16010,1,12,101332),(16011,1,12,101333),(19208,1,12,101701),(19209,1,12,101702),(20069,1,12,941601),(20065,1,12,941602),(20066,1,12,941603),(20067,1,12,941604),(20068,1,12,941605),(20070,1,12,941606),(12776,1,13,11),(12777,1,13,21),(12778,1,13,31),(12779,1,13,41),(12780,1,13,61),(12781,1,13,71),(12782,1,13,72),(12783,1,13,74),(12784,1,13,75),(12785,1,13,78),(12786,1,13,79),(12787,1,13,81),(12788,1,13,91),(12789,1,13,95),(12790,1,13,97),(12791,1,13,101),(12792,1,13,111),(12793,1,13,121),(12794,1,13,151),(12795,1,13,161),(12796,1,13,171),(12797,1,13,221),(12798,1,13,222),(12799,1,13,229),(12800,1,13,241),(12801,1,13,242),(12802,1,13,243),(12803,1,13,262),(12804,1,13,281),(12805,1,13,300),(12806,1,13,331),(12807,1,13,341),(12808,1,13,342),(12809,1,13,343),(12810,1,13,344),(12811,1,13,531),(12812,1,13,700),(12813,1,13,1001),(12814,1,13,1002),(12815,1,13,1003),(12816,1,13,1004),(12817,1,13,1005),(12818,1,13,1101),(12819,1,13,1181),(12820,1,13,1182),(12821,1,13,1201),(12822,1,13,1202),(12823,1,13,1231),(12824,1,13,2401),(12825,1,13,2501),(12826,1,13,2503),(12827,1,13,2515),(12828,1,13,20001),(12830,1,13,23001),(12831,1,13,50101),(12832,1,14,11),(12833,1,14,21),(12834,1,14,31),(12835,1,14,41),(12836,1,14,61),(12837,1,14,71),(12838,1,14,72),(12839,1,14,74),(12840,1,14,75),(12841,1,14,78),(12842,1,14,79),(12843,1,14,81),(12844,1,14,91),(12845,1,14,95),(12846,1,14,97),(12847,1,14,101),(12848,1,14,111),(12849,1,14,121),(12850,1,14,151),(12851,1,14,161),(12852,1,14,171),(12853,1,14,221),(12854,1,14,222),(12855,1,14,229),(12856,1,14,241),(12857,1,14,242),(12858,1,14,243),(12859,1,14,262),(12860,1,14,281),(12861,1,14,300),(12862,1,14,331),(12863,1,14,341),(12864,1,14,342),(12865,1,14,343),(12866,1,14,344),(12867,1,14,531),(12868,1,14,700),(12869,1,14,1001),(12870,1,14,1002),(12871,1,14,1003),(12872,1,14,1004),(12873,1,14,1005),(12874,1,14,1101),(12875,1,14,1181),(12876,1,14,1182),(12877,1,14,1201),(12878,1,14,1202),(12879,1,14,1231),(12880,1,14,2401),(12881,1,14,2501),(12882,1,14,2503),(12883,1,14,2515),(12884,1,14,20001),(12886,1,14,23001),(12887,1,14,50101),(12944,1,16,11),(12945,1,16,21),(12946,1,16,31),(13056,1,16,41),(13057,1,16,42),(13058,1,16,44),(13059,1,16,45),(12948,1,16,61),(12949,1,16,71),(12950,1,16,72),(12951,1,16,74),(12952,1,16,75),(12953,1,16,78),(12954,1,16,79),(12955,1,16,81),(12956,1,16,91),(12957,1,16,95),(12958,1,16,97),(12959,1,16,101),(12960,1,16,111),(12961,1,16,121),(13060,1,16,141),(13061,1,16,142),(13062,1,16,144),(12962,1,16,151),(12963,1,16,161),(12964,1,16,171),(12965,1,16,221),(12966,1,16,222),(12967,1,16,229),(12968,1,16,241),(12969,1,16,242),(12970,1,16,243),(13128,1,16,251),(13064,1,16,262),(12972,1,16,281),(12973,1,16,300),(12974,1,16,331),(12975,1,16,341),(12976,1,16,342),(12977,1,16,343),(12978,1,16,344),(12979,1,16,531),(12980,1,16,700),(12981,1,16,1001),(12982,1,16,1002),(12983,1,16,1003),(12984,1,16,1004),(12985,1,16,1005),(12986,1,16,1101),(12987,1,16,1181),(12988,1,16,1182),(12989,1,16,1201),(12990,1,16,1202),(12991,1,16,1231),(12992,1,16,2401),(12993,1,16,2501),(12994,1,16,2503),(12995,1,16,2515),(12996,1,16,20001),(12998,1,16,23001),(12999,1,16,50101),(13000,1,17,11),(13001,1,17,21),(13002,1,17,31),(13065,1,17,41),(13066,1,17,42),(13067,1,17,44),(13068,1,17,45),(13004,1,17,61),(13005,1,17,71),(13006,1,17,72),(13007,1,17,74),(13008,1,17,75),(13009,1,17,78),(13010,1,17,79),(13011,1,17,81),(13012,1,17,91),(13013,1,17,95),(13014,1,17,97),(13015,1,17,101),(13016,1,17,111),(13017,1,17,121),(13069,1,17,141),(13070,1,17,142),(13071,1,17,144),(13018,1,17,151),(13019,1,17,161),(13020,1,17,171),(13021,1,17,221),(13022,1,17,222),(13023,1,17,229),(13024,1,17,241),(13025,1,17,242),(13026,1,17,243),(13028,1,17,281),(13029,1,17,300),(13030,1,17,331),(13031,1,17,341),(13032,1,17,342),(13033,1,17,343),(13034,1,17,344),(13035,1,17,531),(13036,1,17,700),(13037,1,17,1001),(13038,1,17,1002),(13039,1,17,1003),(13040,1,17,1004),(13041,1,17,1005),(13042,1,17,1101),(13043,1,17,1181),(13044,1,17,1182),(13045,1,17,1201),(13046,1,17,1202),(13047,1,17,1231),(13048,1,17,2401),(13049,1,17,2501),(13050,1,17,2503),(13051,1,17,2515),(13052,1,17,20001),(13054,1,17,23001),(13055,1,17,50101),(14504,1,18,11),(14505,1,18,21),(14506,1,18,31),(14507,1,18,41),(14508,1,18,61),(14509,1,18,71),(14510,1,18,78),(14511,1,18,81),(14512,1,18,91),(14513,1,18,95),(14514,1,18,101),(14515,1,18,111),(14516,1,18,121),(14517,1,18,151),(14518,1,18,161),(14519,1,18,221),(14520,1,18,241),(14521,1,18,262),(14522,1,18,281),(14523,1,18,300),(14524,1,18,331),(14525,1,18,332),(14526,1,18,333),(14527,1,18,341),(14528,1,18,342),(14529,1,18,343),(14530,1,18,344),(14531,1,18,531),(14532,1,18,701),(14533,1,18,771),(14534,1,18,774),(14535,1,18,1001),(14536,1,18,1004),(14537,1,18,1101),(14538,1,18,1181),(14539,1,18,1182),(14540,1,18,1201),(14541,1,18,1231),(14542,1,18,2401),(14543,1,18,2501),(14544,1,18,2503),(14545,1,18,2515),(14546,1,18,20001),(14548,1,18,50101),(14549,1,18,59001),(15242,1,19,21),(15243,1,19,31),(15244,1,19,41),(15245,1,19,61),(15246,1,19,71),(15247,1,19,78),(15248,1,19,81),(15249,1,19,101),(15250,1,19,121),(15251,1,19,151),(15252,1,19,161),(15253,1,19,221),(15254,1,19,241),(15255,1,19,262),(15256,1,19,281),(15257,1,19,300),(15258,1,19,331),(15259,1,19,332),(15260,1,19,341),(15261,1,19,342),(15262,1,19,343),(15263,1,19,344),(15264,1,19,531),(15265,1,19,701),(15266,1,19,771),(15267,1,19,774),(15268,1,19,777),(15269,1,19,1001),(15270,1,19,1004),(15271,1,19,1101),(15272,1,19,1121),(15273,1,19,1181),(15274,1,19,1182),(15275,1,19,1201),(15276,1,19,1231),(15277,1,19,2401),(15278,1,19,2501),(15279,1,19,20001),(15281,1,19,50101),(15282,1,19,59001),(15283,1,19,63001); +INSERT INTO `llx_user_rights` VALUES (12402,1,1,11),(12380,1,1,12),(12385,1,1,13),(12389,1,1,14),(12393,1,1,15),(12398,1,1,16),(12404,1,1,19),(9726,1,1,21),(9700,1,1,22),(9706,1,1,24),(9711,1,1,25),(9716,1,1,26),(9722,1,1,27),(9728,1,1,28),(9978,1,1,31),(9968,1,1,32),(9974,1,1,34),(1910,1,1,36),(9980,1,1,38),(11573,1,1,41),(11574,1,1,42),(11575,1,1,44),(11576,1,1,45),(7184,1,1,61),(7181,1,1,62),(7183,1,1,64),(7185,1,1,67),(7186,1,1,68),(1678,1,1,71),(1673,1,1,72),(1675,1,1,74),(1679,1,1,75),(1677,1,1,76),(1681,1,1,78),(1682,1,1,79),(12322,1,1,81),(12309,1,1,82),(12312,1,1,84),(12314,1,1,86),(12317,1,1,87),(12320,1,1,88),(12323,1,1,89),(11580,1,1,91),(11581,1,1,92),(11582,1,1,93),(11583,1,1,94),(10097,1,1,95),(10099,1,1,96),(10103,1,1,97),(10104,1,1,98),(7139,1,1,101),(7134,1,1,102),(7136,1,1,104),(7137,1,1,105),(7138,1,1,106),(7140,1,1,109),(10229,1,1,111),(10201,1,1,112),(10207,1,1,113),(10213,1,1,114),(10219,1,1,115),(10225,1,1,116),(10231,1,1,117),(12518,1,1,121),(12508,1,1,122),(12514,1,1,125),(12520,1,1,126),(11577,1,1,141),(11578,1,1,142),(11579,1,1,144),(2307,1,1,151),(2304,1,1,152),(2306,1,1,153),(2308,1,1,154),(10092,1,1,161),(10093,1,1,162),(10094,1,1,163),(10095,1,1,164),(10096,1,1,165),(1585,1,1,170),(12342,1,1,171),(12331,1,1,172),(12335,1,1,173),(12339,1,1,174),(12343,1,1,178),(10000,1,1,221),(9990,1,1,222),(9996,1,1,223),(10002,1,1,229),(10007,1,1,237),(10011,1,1,238),(10015,1,1,239),(1686,1,1,241),(1685,1,1,242),(1687,1,1,243),(12604,1,1,251),(12566,1,1,252),(12569,1,1,253),(12572,1,1,254),(12575,1,1,255),(12579,1,1,256),(1617,1,1,258),(12525,1,1,262),(12544,1,1,281),(12534,1,1,282),(12540,1,1,283),(12546,1,1,286),(12288,1,1,300),(12290,1,1,301),(11591,1,1,302),(1763,1,1,331),(1762,1,1,332),(1764,1,1,333),(12582,1,1,341),(12584,1,1,342),(12586,1,1,343),(12588,1,1,344),(12600,1,1,351),(12593,1,1,352),(12597,1,1,353),(12601,1,1,354),(12605,1,1,358),(12560,1,1,531),(12553,1,1,532),(12557,1,1,534),(1625,1,1,536),(12561,1,1,538),(12358,1,1,700),(12348,1,1,701),(12354,1,1,702),(12360,1,1,703),(1755,1,1,1001),(1754,1,1,1002),(1756,1,1,1003),(1758,1,1,1004),(1759,1,1,1005),(7146,1,1,1101),(7143,1,1,1102),(7145,1,1,1104),(7147,1,1,1109),(12412,1,1,1181),(12458,1,1,1182),(12417,1,1,1183),(12420,1,1,1184),(12423,1,1,1185),(12427,1,1,1186),(12431,1,1,1187),(12437,1,1,1188),(12434,1,1,1189),(1578,1,1,1201),(1579,1,1,1202),(12454,1,1,1231),(12443,1,1,1232),(12446,1,1,1233),(12449,1,1,1234),(12452,1,1,1235),(12455,1,1,1236),(12459,1,1,1237),(1736,1,1,1251),(12409,1,1,1321),(12326,1,1,1421),(8190,1,1,1791),(8187,1,1,1792),(8191,1,1,1793),(12264,1,1,2401),(12260,1,1,2402),(12266,1,1,2403),(12280,1,1,2411),(12276,1,1,2412),(12282,1,1,2413),(12286,1,1,2414),(1618,1,1,2500),(12370,1,1,2501),(12367,1,1,2503),(12371,1,1,2515),(9610,1,1,5001),(9611,1,1,5002),(12490,1,1,20001),(12474,1,1,20003),(12480,1,1,20004),(12486,1,1,20005),(12492,1,1,20006),(12302,1,1,23001),(12295,1,1,23002),(12299,1,1,23003),(12303,1,1,23004),(7701,1,1,50101),(4984,1,1,50401),(4983,1,1,50402),(4985,1,1,50403),(4987,1,1,50411),(4988,1,1,50412),(4989,1,1,50415),(12498,1,1,55001),(12499,1,1,55002),(3564,1,1,100700),(3565,1,1,100701),(9596,1,1,101051),(9598,1,1,101052),(9600,1,1,101053),(9604,1,1,101060),(9605,1,1,101061),(7177,1,1,101201),(7178,1,1,101202),(10353,1,1,101250),(10355,1,1,101251),(8980,1,1,101261),(8981,1,1,101262),(7616,1,1,101331),(10030,1,1,101701),(10031,1,1,101702),(3582,1,1,102000),(3583,1,1,102001),(9819,1,1,400051),(9823,1,1,400052),(9827,1,1,400053),(9831,1,1,400055),(132,1,2,11),(133,1,2,12),(134,1,2,13),(135,1,2,14),(136,1,2,16),(137,1,2,19),(138,1,2,21),(139,1,2,22),(140,1,2,24),(141,1,2,25),(142,1,2,26),(143,1,2,27),(10359,1,2,31),(145,1,2,32),(10361,1,2,34),(146,1,2,36),(147,1,2,41),(148,1,2,42),(149,1,2,44),(150,1,2,61),(151,1,2,62),(152,1,2,64),(153,1,2,71),(154,1,2,72),(155,1,2,74),(156,1,2,75),(157,1,2,78),(158,1,2,79),(159,1,2,81),(160,1,2,82),(161,1,2,84),(162,1,2,86),(163,1,2,87),(164,1,2,88),(165,1,2,89),(166,1,2,91),(167,1,2,92),(168,1,2,93),(2475,1,2,95),(2476,1,2,96),(2477,1,2,97),(2478,1,2,98),(169,1,2,101),(170,1,2,102),(171,1,2,104),(172,1,2,109),(173,1,2,111),(174,1,2,112),(175,1,2,113),(176,1,2,114),(177,1,2,116),(178,1,2,117),(179,1,2,121),(180,1,2,122),(181,1,2,125),(182,1,2,141),(183,1,2,142),(184,1,2,144),(2479,1,2,151),(2480,1,2,152),(2481,1,2,153),(2482,1,2,154),(185,1,2,161),(186,1,2,162),(187,1,2,163),(188,1,2,164),(189,1,2,165),(190,1,2,170),(2471,1,2,171),(192,1,2,172),(2472,1,2,173),(193,1,2,221),(194,1,2,222),(195,1,2,229),(196,1,2,241),(197,1,2,242),(198,1,2,243),(199,1,2,251),(201,1,2,262),(202,1,2,281),(203,1,2,282),(204,1,2,283),(205,1,2,331),(15072,1,2,510),(2483,1,2,531),(207,1,2,532),(2484,1,2,534),(208,1,2,536),(2473,1,2,700),(210,1,2,701),(211,1,2,702),(2474,1,2,703),(15064,1,2,771),(15057,1,2,772),(15059,1,2,773),(15061,1,2,774),(15063,1,2,775),(15065,1,2,776),(212,1,2,1001),(213,1,2,1002),(214,1,2,1003),(215,1,2,1004),(216,1,2,1005),(217,1,2,1101),(218,1,2,1102),(219,1,2,1104),(220,1,2,1109),(15073,1,2,1121),(15074,1,2,1122),(15075,1,2,1123),(15076,1,2,1124),(15077,1,2,1125),(15078,1,2,1126),(221,1,2,1181),(222,1,2,1182),(223,1,2,1183),(224,1,2,1184),(225,1,2,1185),(226,1,2,1186),(227,1,2,1187),(228,1,2,1188),(229,1,2,1201),(230,1,2,1202),(231,1,2,1231),(232,1,2,1232),(233,1,2,1233),(234,1,2,1234),(235,1,2,1421),(236,1,2,2401),(237,1,2,2402),(238,1,2,2403),(239,1,2,2411),(240,1,2,2412),(241,1,2,2413),(242,1,2,2500),(2470,1,2,2501),(243,1,2,2515),(10363,1,2,20001),(10365,1,2,20003),(10366,1,2,20004),(10367,1,2,20005),(10368,1,2,20006),(15054,1,2,23001),(10362,1,2,50101),(15067,1,2,55001),(15066,1,2,59001),(15068,1,2,63001),(15069,1,2,63002),(15070,1,2,63003),(15071,1,2,63004),(10372,1,2,101250),(1807,1,3,11),(1808,1,3,31),(1809,1,3,36),(1810,1,3,41),(1811,1,3,61),(1812,1,3,71),(1813,1,3,72),(1814,1,3,74),(1815,1,3,75),(1816,1,3,78),(1817,1,3,79),(1818,1,3,91),(1819,1,3,95),(1820,1,3,97),(1821,1,3,111),(1822,1,3,121),(1823,1,3,122),(1824,1,3,125),(1825,1,3,161),(1826,1,3,170),(1827,1,3,171),(1828,1,3,172),(1829,1,3,221),(1830,1,3,222),(1831,1,3,229),(1832,1,3,241),(1833,1,3,242),(1834,1,3,243),(1835,1,3,251),(1836,1,3,255),(1837,1,3,256),(1838,1,3,262),(1839,1,3,281),(1840,1,3,282),(1841,1,3,283),(1842,1,3,331),(1843,1,3,531),(1844,1,3,536),(1845,1,3,700),(1846,1,3,1001),(1847,1,3,1002),(1848,1,3,1003),(1849,1,3,1004),(1850,1,3,1005),(1851,1,3,1181),(1852,1,3,1182),(1853,1,3,1201),(1854,1,3,1202),(1855,1,3,1231),(1856,1,3,2401),(1857,1,3,2402),(1858,1,3,2403),(1859,1,3,2411),(1860,1,3,2412),(1861,1,3,2413),(1862,1,3,2500),(1863,1,3,2515),(8026,1,4,11),(8027,1,4,21),(8028,1,4,31),(8029,1,4,41),(8030,1,4,61),(8031,1,4,71),(8032,1,4,72),(8033,1,4,74),(8034,1,4,75),(8035,1,4,78),(8036,1,4,79),(8037,1,4,81),(8038,1,4,91),(8039,1,4,95),(8040,1,4,97),(8041,1,4,101),(8042,1,4,111),(8043,1,4,121),(8044,1,4,151),(8045,1,4,161),(8046,1,4,171),(8047,1,4,221),(8048,1,4,222),(8049,1,4,229),(8050,1,4,241),(8051,1,4,242),(8052,1,4,243),(8146,1,4,251),(8147,1,4,253),(8053,1,4,262),(8054,1,4,281),(8055,1,4,331),(8056,1,4,341),(8057,1,4,342),(8058,1,4,343),(8059,1,4,344),(8060,1,4,531),(8061,1,4,700),(8062,1,4,1001),(8063,1,4,1002),(8064,1,4,1003),(8065,1,4,1004),(8066,1,4,1005),(8067,1,4,1101),(8068,1,4,1181),(8069,1,4,1182),(8070,1,4,1201),(8071,1,4,1202),(8072,1,4,1231),(8073,1,4,2401),(8074,1,4,2501),(8075,1,4,2503),(8076,1,4,2515),(8077,1,4,20001),(8078,1,4,50101),(8079,1,4,101201),(8080,1,4,101261),(8081,1,4,102000),(8082,1,4,400051),(8083,1,4,400052),(8084,1,4,400053),(8085,1,4,400055),(12608,1,10,11),(12609,1,10,21),(12610,1,10,31),(12611,1,10,41),(12612,1,10,61),(12613,1,10,71),(12614,1,10,72),(12615,1,10,74),(12616,1,10,75),(12617,1,10,78),(12618,1,10,79),(12619,1,10,81),(12620,1,10,91),(12621,1,10,95),(12622,1,10,97),(12623,1,10,101),(12624,1,10,111),(12625,1,10,121),(12626,1,10,151),(12627,1,10,161),(12628,1,10,171),(12629,1,10,221),(12630,1,10,222),(12631,1,10,229),(12632,1,10,241),(12633,1,10,242),(12634,1,10,243),(12635,1,10,262),(12636,1,10,281),(12637,1,10,300),(12638,1,10,331),(12639,1,10,341),(12640,1,10,342),(12641,1,10,343),(12642,1,10,344),(12643,1,10,531),(12644,1,10,700),(12645,1,10,1001),(12646,1,10,1002),(12647,1,10,1003),(12648,1,10,1004),(12649,1,10,1005),(12650,1,10,1101),(12651,1,10,1181),(12652,1,10,1182),(12653,1,10,1201),(12654,1,10,1202),(12655,1,10,1231),(12656,1,10,2401),(12657,1,10,2501),(12658,1,10,2503),(12659,1,10,2515),(12660,1,10,20001),(12662,1,10,23001),(12663,1,10,50101),(12664,1,11,11),(12665,1,11,21),(12666,1,11,31),(12667,1,11,41),(12668,1,11,61),(12669,1,11,71),(12670,1,11,72),(12671,1,11,74),(12672,1,11,75),(12673,1,11,78),(12674,1,11,79),(12675,1,11,81),(12676,1,11,91),(12677,1,11,95),(12678,1,11,97),(12679,1,11,101),(12680,1,11,111),(12681,1,11,121),(12682,1,11,151),(12683,1,11,161),(12684,1,11,171),(12685,1,11,221),(12686,1,11,222),(12687,1,11,229),(12688,1,11,241),(12689,1,11,242),(12690,1,11,243),(12691,1,11,262),(12692,1,11,281),(12693,1,11,300),(12694,1,11,331),(12695,1,11,341),(12696,1,11,342),(12697,1,11,343),(12698,1,11,344),(12699,1,11,531),(12700,1,11,700),(12701,1,11,1001),(12702,1,11,1002),(12703,1,11,1003),(12704,1,11,1004),(12705,1,11,1005),(12706,1,11,1101),(12707,1,11,1181),(12708,1,11,1182),(12709,1,11,1201),(12710,1,11,1202),(12711,1,11,1231),(12712,1,11,2401),(12713,1,11,2501),(12714,1,11,2503),(12715,1,11,2515),(12716,1,11,20001),(12718,1,11,23001),(12719,1,11,50101),(20696,1,12,11),(20690,1,12,12),(20691,1,12,13),(20692,1,12,14),(20693,1,12,15),(20695,1,12,16),(20697,1,12,19),(14146,1,12,21),(14135,1,12,22),(14137,1,12,24),(14139,1,12,25),(14142,1,12,26),(14145,1,12,27),(14148,1,12,28),(14930,1,12,31),(14926,1,12,32),(14929,1,12,34),(14932,1,12,38),(13816,1,12,41),(13813,1,12,42),(13815,1,12,44),(13817,1,12,45),(14094,1,12,61),(14091,1,12,62),(14093,1,12,64),(14095,1,12,67),(14096,1,12,68),(16203,1,12,71),(16198,1,12,72),(16200,1,12,74),(16204,1,12,75),(16202,1,12,76),(16206,1,12,78),(16207,1,12,79),(20660,1,12,81),(20655,1,12,82),(20656,1,12,84),(20657,1,12,86),(20658,1,12,87),(20659,1,12,88),(20661,1,12,89),(15401,1,12,91),(15397,1,12,92),(15400,1,12,93),(15403,1,12,94),(13990,1,12,95),(12734,1,12,97),(19241,1,12,101),(19237,1,12,102),(19238,1,12,104),(19239,1,12,105),(19240,1,12,106),(19242,1,12,109),(20642,1,12,111),(20633,1,12,112),(20635,1,12,113),(20637,1,12,114),(20639,1,12,115),(20641,1,12,116),(20643,1,12,117),(20783,1,12,121),(20780,1,12,122),(20782,1,12,125),(20784,1,12,126),(20785,1,12,130),(13821,1,12,141),(13820,1,12,142),(13822,1,12,144),(13912,1,12,151),(13909,1,12,152),(13911,1,12,153),(13913,1,12,154),(14063,1,12,161),(14056,1,12,162),(14058,1,12,163),(14060,1,12,164),(14062,1,12,165),(14064,1,12,167),(13350,1,12,171),(13345,1,12,172),(13347,1,12,173),(13349,1,12,174),(13351,1,12,178),(13838,1,12,221),(13834,1,12,222),(13837,1,12,223),(13840,1,12,229),(13842,1,12,237),(13844,1,12,238),(13846,1,12,239),(13516,1,12,241),(13515,1,12,242),(13517,1,12,243),(20824,1,12,251),(20805,1,12,252),(20807,1,12,253),(20808,1,12,254),(20810,1,12,255),(20812,1,12,256),(20786,1,12,262),(20792,1,12,281),(20789,1,12,282),(20791,1,12,283),(20793,1,12,286),(19877,1,12,300),(20644,1,12,301),(20645,1,12,302),(16194,1,12,331),(16193,1,12,332),(16195,1,12,333),(20813,1,12,341),(20814,1,12,342),(20815,1,12,343),(20816,1,12,344),(20822,1,12,351),(20819,1,12,352),(20821,1,12,353),(20823,1,12,354),(20825,1,12,358),(19249,1,12,430),(16384,1,12,501),(16378,1,12,502),(13865,1,12,510),(20769,1,12,511),(20764,1,12,512),(20766,1,12,514),(20768,1,12,517),(20770,1,12,519),(15291,1,12,520),(15286,1,12,522),(15288,1,12,524),(15290,1,12,525),(15292,1,12,527),(20776,1,12,531),(20773,1,12,532),(20775,1,12,534),(20777,1,12,538),(20076,1,12,561),(20073,1,12,562),(20075,1,12,563),(20077,1,12,564),(16932,1,12,650),(20629,1,12,651),(20628,1,12,652),(20630,1,12,653),(17124,1,12,660),(20744,1,12,661),(20743,1,12,662),(20745,1,12,663),(13358,1,12,700),(20666,1,12,701),(20665,1,12,702),(20667,1,12,703),(20753,1,12,750),(20752,1,12,751),(20754,1,12,752),(20686,1,12,771),(20675,1,12,772),(20677,1,12,773),(15085,1,12,774),(20679,1,12,775),(20681,1,12,776),(20683,1,12,777),(20685,1,12,778),(20687,1,12,779),(14917,1,12,1001),(14916,1,12,1002),(14918,1,12,1003),(14920,1,12,1004),(14921,1,12,1005),(19247,1,12,1101),(19245,1,12,1102),(19246,1,12,1104),(19248,1,12,1109),(19233,1,12,1121),(19226,1,12,1122),(19228,1,12,1123),(19230,1,12,1124),(19232,1,12,1125),(19234,1,12,1126),(20700,1,12,1181),(20714,1,12,1182),(20703,1,12,1183),(20704,1,12,1184),(20706,1,12,1185),(20708,1,12,1186),(20710,1,12,1187),(20713,1,12,1188),(20711,1,12,1189),(20715,1,12,1191),(13827,1,12,1201),(13828,1,12,1202),(20723,1,12,1231),(20718,1,12,1232),(20719,1,12,1233),(20721,1,12,1234),(20722,1,12,1235),(20724,1,12,1236),(16302,1,12,1237),(13829,1,12,1251),(20698,1,12,1321),(20699,1,12,1322),(20662,1,12,1421),(20618,1,12,2401),(20617,1,12,2402),(20619,1,12,2403),(20623,1,12,2411),(20622,1,12,2412),(20624,1,12,2413),(20625,1,12,2414),(20671,1,12,2501),(20670,1,12,2503),(20672,1,12,2515),(20082,1,12,3200),(20840,1,12,3201),(20341,1,12,3301),(15435,1,12,5001),(15436,1,12,5002),(20833,1,12,10001),(20828,1,12,10002),(20830,1,12,10003),(20832,1,12,10005),(20834,1,12,10008),(20736,1,12,20001),(20727,1,12,20002),(20729,1,12,20003),(20733,1,12,20004),(20735,1,12,20005),(20737,1,12,20006),(20731,1,12,20007),(20651,1,12,23001),(20648,1,12,23002),(20650,1,12,23003),(20652,1,12,23004),(19019,1,12,50101),(20801,1,12,50151),(20802,1,12,50152),(20803,1,12,50153),(20603,1,12,50401),(20611,1,12,50411),(20606,1,12,50412),(20608,1,12,50414),(20610,1,12,50415),(20612,1,12,50418),(20613,1,12,50420),(20614,1,12,50430),(20602,1,12,50440),(20747,1,12,55001),(20748,1,12,55002),(20799,1,12,56001),(20796,1,12,56002),(20798,1,12,56003),(20800,1,12,56004),(16742,1,12,56005),(20838,1,12,57001),(20837,1,12,57002),(20839,1,12,57003),(20738,1,12,59001),(20739,1,12,59002),(20740,1,12,59003),(20760,1,12,63001),(20757,1,12,63002),(20759,1,12,63003),(20761,1,12,63004),(20749,1,12,64001),(17328,1,12,101130),(17327,1,12,101131),(17329,1,12,101132),(16009,1,12,101331),(16010,1,12,101332),(16011,1,12,101333),(19208,1,12,101701),(19209,1,12,101702),(20069,1,12,941601),(20065,1,12,941602),(20066,1,12,941603),(20067,1,12,941604),(20068,1,12,941605),(20070,1,12,941606),(12776,1,13,11),(12777,1,13,21),(12778,1,13,31),(12779,1,13,41),(12780,1,13,61),(12781,1,13,71),(12782,1,13,72),(12783,1,13,74),(12784,1,13,75),(12785,1,13,78),(12786,1,13,79),(12787,1,13,81),(12788,1,13,91),(12789,1,13,95),(12790,1,13,97),(12791,1,13,101),(12792,1,13,111),(12793,1,13,121),(12794,1,13,151),(12795,1,13,161),(12796,1,13,171),(12797,1,13,221),(12798,1,13,222),(12799,1,13,229),(12800,1,13,241),(12801,1,13,242),(12802,1,13,243),(12803,1,13,262),(12804,1,13,281),(12805,1,13,300),(12806,1,13,331),(12807,1,13,341),(12808,1,13,342),(12809,1,13,343),(12810,1,13,344),(12811,1,13,531),(12812,1,13,700),(12813,1,13,1001),(12814,1,13,1002),(12815,1,13,1003),(12816,1,13,1004),(12817,1,13,1005),(12818,1,13,1101),(12819,1,13,1181),(12820,1,13,1182),(12821,1,13,1201),(12822,1,13,1202),(12823,1,13,1231),(12824,1,13,2401),(12825,1,13,2501),(12826,1,13,2503),(12827,1,13,2515),(12828,1,13,20001),(12830,1,13,23001),(12831,1,13,50101),(12832,1,14,11),(12833,1,14,21),(12834,1,14,31),(12835,1,14,41),(12836,1,14,61),(12837,1,14,71),(12838,1,14,72),(12839,1,14,74),(12840,1,14,75),(12841,1,14,78),(12842,1,14,79),(12843,1,14,81),(12844,1,14,91),(12845,1,14,95),(12846,1,14,97),(12847,1,14,101),(12848,1,14,111),(12849,1,14,121),(12850,1,14,151),(12851,1,14,161),(12852,1,14,171),(12853,1,14,221),(12854,1,14,222),(12855,1,14,229),(12856,1,14,241),(12857,1,14,242),(12858,1,14,243),(12859,1,14,262),(12860,1,14,281),(12861,1,14,300),(12862,1,14,331),(12863,1,14,341),(12864,1,14,342),(12865,1,14,343),(12866,1,14,344),(12867,1,14,531),(12868,1,14,700),(12869,1,14,1001),(12870,1,14,1002),(12871,1,14,1003),(12872,1,14,1004),(12873,1,14,1005),(12874,1,14,1101),(12875,1,14,1181),(12876,1,14,1182),(12877,1,14,1201),(12878,1,14,1202),(12879,1,14,1231),(12880,1,14,2401),(12881,1,14,2501),(12882,1,14,2503),(12883,1,14,2515),(12884,1,14,20001),(12886,1,14,23001),(12887,1,14,50101),(12944,1,16,11),(12945,1,16,21),(12946,1,16,31),(13056,1,16,41),(13057,1,16,42),(13058,1,16,44),(13059,1,16,45),(12948,1,16,61),(12949,1,16,71),(12950,1,16,72),(12951,1,16,74),(12952,1,16,75),(12953,1,16,78),(12954,1,16,79),(12955,1,16,81),(12956,1,16,91),(12957,1,16,95),(12958,1,16,97),(12959,1,16,101),(12960,1,16,111),(12961,1,16,121),(13060,1,16,141),(13061,1,16,142),(13062,1,16,144),(12962,1,16,151),(12963,1,16,161),(12964,1,16,171),(12965,1,16,221),(12966,1,16,222),(12967,1,16,229),(12968,1,16,241),(12969,1,16,242),(12970,1,16,243),(13128,1,16,251),(13064,1,16,262),(12972,1,16,281),(12973,1,16,300),(12974,1,16,331),(12975,1,16,341),(12976,1,16,342),(12977,1,16,343),(12978,1,16,344),(12979,1,16,531),(12980,1,16,700),(12981,1,16,1001),(12982,1,16,1002),(12983,1,16,1003),(12984,1,16,1004),(12985,1,16,1005),(12986,1,16,1101),(12987,1,16,1181),(12988,1,16,1182),(12989,1,16,1201),(12990,1,16,1202),(12991,1,16,1231),(12992,1,16,2401),(12993,1,16,2501),(12994,1,16,2503),(12995,1,16,2515),(12996,1,16,20001),(12998,1,16,23001),(12999,1,16,50101),(13000,1,17,11),(13001,1,17,21),(13002,1,17,31),(13065,1,17,41),(13066,1,17,42),(13067,1,17,44),(13068,1,17,45),(13004,1,17,61),(13005,1,17,71),(13006,1,17,72),(13007,1,17,74),(13008,1,17,75),(13009,1,17,78),(13010,1,17,79),(13011,1,17,81),(13012,1,17,91),(13013,1,17,95),(13014,1,17,97),(13015,1,17,101),(13016,1,17,111),(13017,1,17,121),(13069,1,17,141),(13070,1,17,142),(13071,1,17,144),(13018,1,17,151),(13019,1,17,161),(13020,1,17,171),(13021,1,17,221),(13022,1,17,222),(13023,1,17,229),(13024,1,17,241),(13025,1,17,242),(13026,1,17,243),(13028,1,17,281),(13029,1,17,300),(13030,1,17,331),(13031,1,17,341),(13032,1,17,342),(13033,1,17,343),(13034,1,17,344),(13035,1,17,531),(13036,1,17,700),(13037,1,17,1001),(13038,1,17,1002),(13039,1,17,1003),(13040,1,17,1004),(13041,1,17,1005),(13042,1,17,1101),(13043,1,17,1181),(13044,1,17,1182),(13045,1,17,1201),(13046,1,17,1202),(13047,1,17,1231),(13048,1,17,2401),(13049,1,17,2501),(13050,1,17,2503),(13051,1,17,2515),(13052,1,17,20001),(13054,1,17,23001),(13055,1,17,50101),(14504,1,18,11),(14505,1,18,21),(14506,1,18,31),(14507,1,18,41),(14508,1,18,61),(14509,1,18,71),(14510,1,18,78),(14511,1,18,81),(14512,1,18,91),(14513,1,18,95),(14514,1,18,101),(14515,1,18,111),(14516,1,18,121),(14517,1,18,151),(14518,1,18,161),(14519,1,18,221),(14520,1,18,241),(14521,1,18,262),(14522,1,18,281),(14523,1,18,300),(14524,1,18,331),(14525,1,18,332),(14526,1,18,333),(14527,1,18,341),(14528,1,18,342),(14529,1,18,343),(14530,1,18,344),(14531,1,18,531),(14532,1,18,701),(14533,1,18,771),(14534,1,18,774),(14535,1,18,1001),(14536,1,18,1004),(14537,1,18,1101),(14538,1,18,1181),(14539,1,18,1182),(14540,1,18,1201),(14541,1,18,1231),(14542,1,18,2401),(14543,1,18,2501),(14544,1,18,2503),(14545,1,18,2515),(14546,1,18,20001),(14548,1,18,50101),(14549,1,18,59001),(15242,1,19,21),(15243,1,19,31),(15244,1,19,41),(15245,1,19,61),(15246,1,19,71),(15247,1,19,78),(15248,1,19,81),(15249,1,19,101),(15250,1,19,121),(15251,1,19,151),(15252,1,19,161),(15253,1,19,221),(15254,1,19,241),(15255,1,19,262),(15256,1,19,281),(15257,1,19,300),(15258,1,19,331),(15259,1,19,332),(15260,1,19,341),(15261,1,19,342),(15262,1,19,343),(15263,1,19,344),(15264,1,19,531),(15265,1,19,701),(15266,1,19,771),(15267,1,19,774),(15268,1,19,777),(15269,1,19,1001),(15270,1,19,1004),(15271,1,19,1101),(15272,1,19,1121),(15273,1,19,1181),(15274,1,19,1182),(15275,1,19,1201),(15276,1,19,1231),(15277,1,19,2401),(15278,1,19,2501),(15279,1,19,20001),(15281,1,19,50101),(15282,1,19,59001),(15283,1,19,63001); /*!40000 ALTER TABLE `llx_user_rights` ENABLE KEYS */; UNLOCK TABLES; @@ -12661,7 +13123,7 @@ CREATE TABLE `llx_website_page` ( LOCK TABLES `llx_website_page` WRITE; /*!40000 ALTER TABLE `llx_website_page` DISABLE KEYS */; -INSERT INTO `llx_website_page` VALUES (1,5,'blog','','Blog','Blog','blog','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
The latest news...\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n

\n
\n\n

\n\n \n\n
\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,12,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(2,5,'blog-our-company-is-now-on-dolibarr','','Our company is now on Dolibarr ERP CRM','Our company has moved on Dolibarr ERP CRM. This is an important step in improving all of our services.','','\n\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n
title; ?>\n
\n
\n
\n
\n
\n
\n
\n
\n\n
\n


\n Like several thousands of companies, our company (name ?>) has moved all its information system to Dolibarr ERP CRM. More than 20 applications have been replaced by only one, easier to use and fully integrated.\n This is an important step in improving all of our services.\n \n


\n \n
\n \n

\n
Screenshot of our new Open Source solution
\n
\n \n \n \n





\n
\n\n\n\n\n\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,12,'blogpost','en',NULL,'','',NULL,'image/template-corporate/background_dolibarr.jpg','',0,NULL,NULL),(3,5,'blog-our-new-web-site-has-been-launched','','Our new web site has been launched','Our new website, based on Dolibarr CMS, has been launched. Modern and directly integrated with the internal management tools of the company, many new online services for our customers will be able to see the day...','','\n\n
\n
\n
\n
\n
\n
\n
\n
\n
title; ?>\n
\n
\n
\n
\n
\n
\n
\n
\n\n
\n





\n\n\n Our new website, based on Dolibarr CMS, has been launched.
\n Now it is modern and directly integrated with the internal management tools of the company. Many new online services will be available for our customers...\n\n \n


\n \n
\n \n

\n
Theme of our new web site
\n
\n \n\n





\n
\n\n\n\n\n\n\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,12,'blogpost','en',NULL,'','',NULL,'image/template-corporate/background_rough-horn.jpg','',0,NULL,NULL),(4,5,'careers','','Careers','Our job opportunities','career','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Job opportunities\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n
\n
\n\n\n

\n\n \n\n
\n \n\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,12,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(5,5,'carriere','','Carrière','Nos opportunités professionnelles','career','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Offres d\'emploi\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n
\n
\n
\n
\nNous n\'avons pas d\'offres d\'emploi ouvertes en ce moment...
\n
\n
\n
\n
\n
\n
\n\n\n

\n\n \n\n
\n \n\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,12,'page','fr',NULL,'','',NULL,'','',0,NULL,NULL),(6,5,'clients-testimonials','','Clients Testimonials','Client Testimonials','testimonials, use cases, success story','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Testimonials\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n

\n

What they say about us

\n



\n Send us your testimonial (by email to email; ?>\">email; ?>)\n



\n

\n
\n\n

\n\n \n\n
\n \n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,12,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(7,5,'contact','','Contact','Privacy Policies','Contact','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Contact\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n
\n

Contact us:



\n email ?>
\n getFullAddress() ?>
\n
\n
\n\n\n \n
\n
\n \n
\n\n


\n\n \n\n
\n \n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,12,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(8,5,'faq','','FAQ','Frequently Asked Questions','faq','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
FAQs\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n
\n


Frequently Asked Questions

\n
\n
\n
\n

How can I contact you ?


\nYou can contact us by using this page.\n
\n
\n
\n

What is your privacy policy ?


\nYou may find information about our privacy policy on this page.\n\n\n



\n\n
\n
\n\n\n

\n\n \n\n
\n \n\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,12,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(9,5,'footer','','Footer','Footer','','\n
\n\n \n \n \n\n
\n\n\n\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,12,'other','en',NULL,'','',NULL,'','',0,NULL,NULL),(10,5,'header','','Header and Top Menu','Header with menu','','\n\n\n\n
\n
\n
\n \n
\n
\n
\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,12,'other','en',NULL,'','',NULL,'','',0,NULL,NULL),(11,5,'home','','Home','Welcome','','
\n \n \n \n \n \n
\n
\n
\n
\n
\n
\n
\n
\n
Boost your business\n
\n
\n

We provide powerful solutions for all businesses

\n
\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
 Best prices on the market \n
\n
\n

Our optimized processes allows us to provide you very competitive prices

\n
\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n

Our sales representative are also technicians.

\n
\n
\n
\n
\n
\n \n
\n

Take a look at our offers...

\n
\n
\n
\n
\n
\n \n
\n

Our customer-supplier relationship is very appreciated by our customers

\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n

We continue to follow and assist you after the sale. Contact us at any time.

\n
\n
\n
\n
\n
\n\n\n \n
\n
\n

Looking for

\n

a high quality service?

\n

With a lot of experience, hiring us is a security for your business!

\n
\n
\n
11
\n
Years of Experience
\n
\n
\n
\n query($sql); $obj = $db->fetch_object($resql); print $obj->nb; ?>\n
\n
Experts
\n
\n
\n
\n query($sql); $obj = $db->fetch_object($resql); print $obj->nb; ?>\n
\n
Trusted Clients
\n
\n
\n
\n \n
\n
\n
\n\n \n \n \n
\n
\n
\n \n
\n \n
\n \n
\n

our plans

\n\n \n
\n \n
\n
\n
\n
FREE
\n
The best choice for personal use
\n
The service 1 for free
\n
\n 0/ month\n
\n
\n Available features are : \n
    \n
  • \n \n Service 1 \n
  • \n
\n
\n
\n Subcribe\n
\n
\n
\n \n \n \n
\n
\n
\n
STARTER
\n
For small companiess
\n
The service 1 and product 1 at low price
\n
\n 29/ month\n
\n
\n Available features are : \n
    \n
  • \n \n Service 1\n
  • \n
  • \n \n Product 1\n
  • \n
\n
\n
\n Subscribe\n
\n
\n
\n \n \n \n
\n
\n
\n
PREMIUM
\n
For large companies
\n
The full option package for a one shot price\n
\n
\n 2499\n
\n
\n Available features are :\n
    \n
  • \n \n Service 1
  • \n
  • \n \n Service 2
  • \n
  • \n \n Product 1
  • \n
\n
\n
\n Buy\n
\n
\n
\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n
\n \n \n \n
\n
\n

our team

\n
\n
\n \n
\n
\n
\n
\n\n\n \n
\n
\n
\n
\n
\n

Request a callback

\n
\n
\n \n
\n
\n \n
\n
\n \n
\n
\n \n
\n
\n
\n
\n
\n
\n
\n \n \n \n
\n
\n
\n
\n
\n

successful cases

\n
\n
\n
\n
\n
\"\"\n
\n
\n
\n
\"\"\n
\n
\n
\n
\"\"\n
\n
\n
\n
\"\"\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n Albert Einstein\n
\n
Scientist, www.emc2.org
\n
\n
\n
\n
\n
-20%
\n
Expenses
\n
\n
\n
\n
\n
\n
\n \n They did everything, with almost no time or effort for me. The best part was that I could trust their team to represent our company professionally with our clients.\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n Pierre Curie\n
\n
CEO “Cyclonic”
\n
\n
\n
\n
\n
-30%
\n
Expenses
\n
\n
\n
\n
\n
\n
\n \n Their course gave me the confidence to implement new techniques in my work. I learn “how” to write – “what” and “why” also became much clearer.\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n Marie Curie\n
\n
CTO \"Cyclonic\"
\n
\n
\n
\n
\n
+22%
\n
Turnover
\n
\n
\n
\n
\n
\n
\n \n We were skeptical to work with a consultant to optimize our sales emails, but they were highly recommended by many other startups we knew. They helped us to reach our objective of 20% turnover increase, in 4 monthes.\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n John Doe\n
\n
Sale representative
\n
\n
\n
\n
\n
+40%
\n
Quotes
\n
\n
\n
\n
\n
\n
\n \n Their work on our website and Internet marketing has made a significant different to our business. We’ve seen a +40% increase in quote requests from our website.\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n \n\n \n
\n
\n

Latest News

\n \n
\n
\n\n\n \n\n\n
\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,12,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(12,5,'our-team','','Our team','Our team','team','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Our team\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n

\n

The crew...




\n query($sql);\n if (! $resql) dol_print_error($db);\n while ($obj = $db->fetch_object($resql))\n {\n $arrayofusers[]=$obj->rowid;\n }\n \n print \'
\';\n foreach($arrayofusers as $id)\n {\n $fuser->fetch($id);\n\n print \'
\';\n print \'
\';\n print \'
\';\n if ($fuser->photo) print Form::showphoto(\'userphoto\', $fuser, 100, 0, 0, \'photowithmargin\', \'\', 0);\n //print \'photo.\'\" width=\"129\" height=\"129\" alt=\"\">\';\n else print \'\"\"\';\n print \'
\';\n print \'
\';\n print \'
\'.$fuser->firstname.\'
\';\n print \'
    \';\n //print \'
  • September 24, 2018
  • \';\n if ($fuser->job) print \'
  • \'.$fuser->job.\'
  • \';\n else print \'
  • \';\n print \'
\';\n print \'
\';\n print \'
\';\n print \'
\';\n }\n print \'
\';\n\n ?>\n
\n
\n\n

\n\n \n\n
\n \n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,12,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(13,5,'partners','','Partners','Partners','partners','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Partners\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n
\n

Our partners...

\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n

\n\n \n\n
\n \n\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,12,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(14,5,'pricing','','Pricing','All the prices of our offers','pricing','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Our plans\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n\n\n \n
\n
\n
\n \n
\n \n
\n \n
\n\n \n
\n \n
\n
\n
\n
FREE
\n
The best choice for personal use
\n
The service 1 for free
\n
\n 0/ month\n
\n
\n Available features are : \n
    \n
  • \n \n Service 1 \n
  • \n
\n
\n
\n Subcribe\n
\n
\n
\n \n \n \n
\n
\n
\n
STARTER
\n
For small companiess
\n
The service 1 and product 1 at low price
\n
\n 29/ month\n
\n
\n Available features are : \n
    \n
  • \n \n Service 1\n
  • \n
  • \n \n Product 1\n
  • \n
\n
\n
\n Subscribe\n
\n
\n
\n \n \n \n
\n
\n
\n
PREMIUM
\n
For large companies
\n
The full option package for a one shot price\n
\n
\n 2499\n
\n
\n Available features are :\n
    \n
  • \n \n Service 1
  • \n
  • \n \n Service 2
  • \n
  • \n \n Product 1
  • \n
\n
\n
\n Buy\n
\n
\n
\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n
\n \n \n \n

\n\n \n\n
\n \n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,12,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(15,5,'privacy-policies','','Privacy Policies','Privacy Policies','Privacy policies, GDPR','
\n \n \n \n\n\n
\n
\n
\n
\n
\n
\n
\n
\n
Privacy Policy\n
\n
\n
\n
\n
\n
\n
\n
\n\n


\n\n
\n
\n

Information collected and used


\n

* Your customer information (email, phone, business name, first and last name of contact, address, postal code, country and VAT number) are stored when you become a customer. This information allows us to bill you. \n

* If you paid using our online service, we also store the last 4 digits of your card. The full details of your credit card is stored by our payment provider Stripe (the world leader in online payment).

\n

* You have the option to request the deletion of your data and the above information at any time (except data required y fiscal tracking rules, like your invoices).

\n

* The Privacy Policies and GDPR referral contact for our services is: global->MAIN_INFO_GDPR; ?>

\n


\n

Data Storage and Backups


\n

* The storage of collected data (see \'Information collected and used\') is done in a database.

\n

* We made one backup every week. Only 4 weeks are kept.

\n


\n

Subcontractor


\n

* Our services relies on the following subcontractors and service:
\n** The host of computer servers, which is ABC company. These servers are hosted in US. No customer information is communicated to this subcontractor who only provides the hardware and network layer, the installation and operation being carried out by us directly.
\n** The online payment service Stripe, which is used, to ensure regular payment of subscription or your invoices paid online.

\n


\n

Software Protection


\n

* Our services runs on Linux Ubuntu systems and software. They benefit from regular security updates when the operating system editor (Ubuntu Canonical) publishes them.

\n

* Our services are accessible in HTTPS (HTTP encrypted) only, encrypted with SHA256 certificates.

\n

* Our technical platform are protected by various solutions.

\n


\n

Data theft


\n

* In case of suspicion of a theft of the data we have collected (see first point \'Information collected and used\'), customers will be informed by email, at email corresponding to their customer account

\n

 

\n
\n
\n\n\n \n \n \n
\n \n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,12,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(16,5,'product-p','','Product P','Product P','','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Product P\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n
\n
\n
\n
\nThis is a description page of our product P...
\n
\n
\n
\n
\n
\n
\n\n\n

\n\n \n\n
\n \n\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,12,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(17,5,'search','','Search Page','Search Page','','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Search\n
\n
\n
\n
\n
\n
\n
\n
\n\n


\n\n
\n \n
\n
\n \" />\n
\n \">\n
\n
\n \n
\n
\n
\n \n load(\"main\");\n \n if (function_exists(\'getPagesFromSearchCriterias\'))\n {\n if (GETPOSTISSET(\'s\'))\n {\n $listofpages = getPagesFromSearchCriterias(\'page\', \'meta\', GETPOST(\'s\', \'alphanohtml\'));\n if ($listofpages[\'code\'] == \'OK\')\n {\n foreach($listofpages[\'list\'] as $websitepagefound)\n {\n print \'
ref.\'.php\">\'.$websitepagefound->title.\' - \'.$websitepagefound->description.\'
\';\n }\n }\n else\n {\n // If error, show message\n print $listofpages[\'message\'];\n }\n }\n }\n else\n {\n print $weblangs->trans(\"FeatureNotYetAvailable\");\n }\n ?>\n \n





\n
\n\n \n\n
\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,12,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(18,5,'service-s','','Service S','Service S','','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Service S\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n
\n
\n
\n
\nThis is a description page of our service S...
\n
\n
\n
\n
\n
\n
\n\n\n

\n\n \n\n
\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,12,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(19,5,'test','','test','Page test','test','Test\n',1,'2020-10-07 13:13:26',NULL,'2020-10-07 11:13:26',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(20,4,'credits','','Credits','Credits and legal notices','',' \n \n
\n\n \n
\n

Mentions légales

\n

Curriculum Vitae

\n
\n\n \n \n\n \n
\n\n \n
\n\n

\n \nThis site is edited by name; ?>\n\n \n

\n\n
\n\n
\n\n \n \n\n
\n\n',1,'2019-08-15 16:39:56',NULL,'2020-02-21 09:27:17',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(21,4,'footer','','Footer','','',' \n
\n
\n

Aliquam sed mauris

\n

Sed lorem ipsum dolor sit amet et nullam consequat feugiat consequat magna adipiscing tempus etiam dolore veroeros. eget dapibus mauris. Cras aliquet, nisl ut viverra sollicitudin, ligula erat egestas velit, vitae tincidunt odio.

\n \n
\n
\n

Etiam feugiat

\n
\n
Address
\n
getFullAddress(1, \'
\'); ?>
\n
Phone
\n
phone; ?>
\n
Email
\n
email; ?>\">email; ?>
\n
\n
\n
© Untitled. Design: HTML5 UP adapted for Dolibarr by NLTechno.
\n
\n\n\n\n\n\n',1,'2019-08-15 16:42:44',NULL,'2020-06-19 08:18:14',NULL,NULL,'page','fr',NULL,'','',NULL,'','',0,NULL,NULL),(22,4,'generic','','Generic page','Generic page or my personal Blog','My generic page',' \n\n
\n\n \n
\n

Another page

\n

Ipsum dolor sit amet nullam

\n
\n\n \n \n\n \n
\n\n \n
\n \"\"\n

Magna feugiat lorem

\n

Donec eget ex magna. Interdum et malesuada fames ac ante ipsum primis in faucibus. Pellentesque venenatis dolor imperdiet dolor mattis sagittis. Praesent rutrum sem diam, vitae egestas enim auctor sit amet. Pellentesque leo mauris, consectetur id ipsum sit amet, fergiat. Pellentesque in mi eu massa lacinia malesuada et a elit. Donec urna ex, lacinia in purus ac, pretium pulvinar mauris. Curabitur sapien risus, commodo eget turpis at, elementum convallis fames ac ante ipsum primis in faucibus.

\n

Pellentesque venenatis dolor imperdiet dolor mattis sagittis. Praesent rutrum sem diam, vitae egestas enim auctor sit amet.

\n

Tempus veroeros

\n

Cep risus aliquam gravida cep ut lacus amet. Adipiscing faucibus nunc placerat. Tempus adipiscing turpis non blandit accumsan eget lacinia nunc integer interdum amet aliquam ut orci non col ut ut praesent.

\n
\n\n \n
\n

Latest Blog posts

\n
\n loadLangs(array(\"main\",\"website\"));\n $fuser = new User($db);\n $arrayofblogs = $websitepage->fetchAll($website->id, \'DESC\', \'date_creation\', 5, 0, array(\'type_container\'=>\'blogpost\', \'status\'=>1, \'lang\'=>\'null,\'.$websitepage->lang)); // , \'keywords\'=>$keyword\n if (is_numeric($arrayofblogs) && $arrayofblogs < 0)\n {\n print \'
\'.$weblangs->trans($websitepage->error).\'
\';\n }\n elseif (is_array($arrayofblogs) && ! empty($arrayofblogs))\n {\n foreach($arrayofblogs as $blog)\n {\n print \'\';\n }\n }\n else\n {\n print \'
\';\n print \'
\';\n //print $weblangs->trans(\"NoArticlesFoundForTheKeyword\", $keyword);\n print $weblangs->trans(\"NoArticlesFound\");\n print \'
\';\n print \'
\';\n \n }\n ?>\n
\n
\n\n
\n\n\n\n \n \n \n \n
\n\n',1,'2019-08-15 00:03:43',NULL,'2020-05-14 16:48:34',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(23,4,'home','','My personal blog','Home page or my personal Blog','My personal blog','\n
\n\n \n
\n
\n

David Doe

\n

Welcome on my website
\n

\n
\n
\n\n \n \n\n \n
\n\n \n
\n
\n
\n
\n

Ipsum sed adipiscing

\n
\n

Sed lorem ipsum dolor sit amet nullam consequat feugiat consequat magna\n adipiscing magna etiam amet veroeros. Lorem ipsum dolor tempus sit cursus.\n Tempus nisl et nullam lorem ipsum dolor sit amet aliquam.

\n \n
\n \"\"\n
\n
\n\n \n
\n
\n

Magna veroeros

\n
\n
    \n
  • \n \n

    Ipsum consequat

    \n

    Sed lorem amet ipsum dolor et amet nullam consequat a feugiat consequat tempus veroeros sed consequat.

    \n
  • \n
  • \n \n

    Amed sed feugiat

    \n

    Sed lorem amet ipsum dolor et amet nullam consequat a feugiat consequat tempus veroeros sed consequat.

    \n
  • \n
  • \n \n

    Dolor nullam

    \n

    Sed lorem amet ipsum dolor et amet nullam consequat a feugiat consequat tempus veroeros sed consequat.

    \n
  • \n
\n \n
\n\n \n
\n
\n

Ipsum consequat

\n

Donec imperdiet consequat consequat. Suspendisse feugiat congue
\n posuere. Nulla massa urna, fermentum eget quam aliquet.

\n
\n
    \n
  • \n \n 5,120 Etiam\n
  • \n
  • \n \n 8,192 Magna\n
  • \n
  • \n \n 2,048 Tempus\n
  • \n
  • \n \n 4,096 Aliquam\n
  • \n
  • \n \n 1,024 Nullam\n
  • \n
\n

Nam elementum nisl et mi a commodo porttitor. Morbi sit amet nisl eu arcu faucibus hendrerit vel a risus. Nam a orci mi, elementum ac arcu sit amet, fermentum pellentesque et purus. Integer maximus varius lorem, sed convallis diam accumsan sed. Etiam porttitor placerat sapien, sed eleifend a enim pulvinar faucibus semper quis ut arcu. Ut non nisl a mollis est efficitur vestibulum. Integer eget purus nec nulla mattis et accumsan ut magna libero. Morbi auctor iaculis porttitor. Sed ut magna ac risus et hendrerit scelerisque. Praesent eleifend lacus in lectus aliquam porta. Cras eu ornare dui curabitur lacinia.

\n \n
\n\n \n
\n
\n

Congue imperdiet

\n

Donec imperdiet consequat consequat. Suspendisse feugiat congue
\n posuere. Nulla massa urna, fermentum eget quam aliquet.

\n
\n \n
\n\n
\n\n \n\n
\n\n',1,'2019-08-15 00:03:43',NULL,'2020-11-26 10:30:41',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(24,4,'menu','','Menu','Menu common to all pages','','\n',1,'2019-08-15 00:03:43',NULL,'2020-02-21 09:27:17',NULL,NULL,'menu','fr',NULL,'','',NULL,'','',0,NULL,NULL),(25,4,'this-is-a-blog-post','','This is a Blog post','This is a full meta description of the article','blog','\n
\n This is a blog post article...\n
\n',1,'2019-08-17 17:18:45',NULL,'2020-05-14 16:54:52',NULL,NULL,'blogpost','',NULL,'','',NULL,'','webmaster',0,NULL,NULL); +INSERT INTO `llx_website_page` VALUES (1,5,'blog','','Blog','Blog','blog','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
The latest news...\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n

\n
\n\n

\n\n \n\n
\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(2,5,'blog-our-company-is-now-on-dolibarr','','Our company is now on Dolibarr ERP CRM','Our company has moved on Dolibarr ERP CRM. This is an important step in improving all of our services.','','\n\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n
title; ?>\n
\n
\n
\n
\n
\n
\n
\n
\n\n
\n


\n Like several thousands of companies, our company (name ?>) has moved all its information system to Dolibarr ERP CRM. More than 20 applications have been replaced by only one, easier to use and fully integrated.\n This is an important step in improving all of our services.\n \n


\n \n
\n \n

\n
Screenshot of our new Open Source solution
\n
\n \n \n \n





\n
\n\n\n\n\n\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,NULL,'blogpost','en',NULL,'','',NULL,'image/template-corporate/background_dolibarr.jpg','',0,NULL,NULL),(3,5,'blog-our-new-web-site-has-been-launched','','Our new web site has been launched','Our new website, based on Dolibarr CMS, has been launched. Modern and directly integrated with the internal management tools of the company, many new online services for our customers will be able to see the day...','','\n\n
\n
\n
\n
\n
\n
\n
\n
\n
title; ?>\n
\n
\n
\n
\n
\n
\n
\n
\n\n
\n





\n\n\n Our new website, based on Dolibarr CMS, has been launched.
\n Now it is modern and directly integrated with the internal management tools of the company. Many new online services will be available for our customers...\n\n \n


\n \n
\n \n

\n
Theme of our new web site
\n
\n \n\n





\n
\n\n\n\n\n\n\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,NULL,'blogpost','en',NULL,'','',NULL,'image/template-corporate/background_rough-horn.jpg','',0,NULL,NULL),(4,5,'careers','','Careers','Our job opportunities','career','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Job opportunities\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n
\n
\n\n\n

\n\n \n\n
\n \n\n',1,'2020-10-07 13:13:26',NULL,'2021-01-03 18:01:53',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(5,5,'carriere','','Carrière','Nos opportunités professionnelles','career','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Offres d\'emploi\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n
\n
\n
\n
\nNous n\'avons pas d\'offres d\'emploi ouvertes en ce moment...
\n
\n
\n
\n
\n
\n
\n\n\n

\n\n \n\n
\n \n\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,NULL,'page','fr',NULL,'','',NULL,'','',0,NULL,NULL),(6,5,'clients-testimonials','','Clients Testimonials','Client Testimonials','testimonials, use cases, success story','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Testimonials\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n

\n

What they say about us

\n



\n Send us your testimonial (by email to email; ?>\">email; ?>)\n



\n

\n
\n\n

\n\n \n\n
\n \n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(7,5,'contact','','Contact','Privacy Policies','Contact','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Contact\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n
\n

Contact us:



\n email ?>
\n getFullAddress() ?>
\n
\n
\n\n\n \n
\n
\n \n
\n\n


\n\n \n\n
\n \n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(8,5,'faq','','FAQ','Frequently Asked Questions','faq','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
FAQs\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n
\n


Frequently Asked Questions

\n
\n
\n
\n

How can I contact you ?


\nYou can contact us by using this page.\n
\n
\n
\n

What is your privacy policy ?


\nYou may find information about our privacy policy on this page.\n\n\n



\n\n
\n
\n\n\n

\n\n \n\n
\n \n\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(9,5,'footer','','Footer','Footer','','\n
\n\n \n \n \n\n
\n\n\n\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,NULL,'other','en',NULL,'','',NULL,'','',0,NULL,NULL),(10,5,'header','','Header and Top Menu','Header with menu','','\n\n\n\n
\n
\n
\n \n
\n
\n
\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,NULL,'other','en',NULL,'','',NULL,'','',0,NULL,NULL),(11,5,'home','','Home','Welcome','','
\n \n \n \n \n \n
\n
\n
\n
\n
\n
\n
\n
\n
Boost your business\n
\n
\n

We provide powerful solutions for all businesses

\n
\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
 Best prices on the market \n
\n
\n

Our optimized processes allows us to provide you very competitive prices

\n
\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n

Our sales representative are also technicians.

\n
\n
\n
\n
\n
\n \n
\n

Take a look at our offers...

\n
\n
\n
\n
\n
\n \n
\n

Our customer-supplier relationship is very appreciated by our customers

\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n

We continue to follow and assist you after the sale. Contact us at any time.

\n
\n
\n
\n
\n
\n\n\n \n
\n
\n

Looking for

\n

a high quality service?

\n

With a lot of experience, hiring us is a security for your business!

\n
\n
\n
11
\n
Years of Experience
\n
\n
\n
\n query($sql); $obj = $db->fetch_object($resql); print $obj->nb; ?>\n
\n
Experts
\n
\n
\n
\n query($sql); $obj = $db->fetch_object($resql); print $obj->nb; ?>\n
\n
Trusted Clients
\n
\n
\n
\n \n
\n
\n
\n\n \n \n \n
\n
\n
\n \n
\n \n
\n \n
\n

our plans

\n\n \n
\n \n
\n
\n
\n
FREE
\n
The best choice for personal use
\n
The service 1 for free
\n
\n 0/ month\n
\n
\n Available features are : \n
    \n
  • \n \n Service 1 \n
  • \n
\n
\n
\n Subcribe\n
\n
\n
\n \n \n \n
\n
\n
\n
STARTER
\n
For small companiess
\n
The service 1 and product 1 at low price
\n
\n 29/ month\n
\n
\n Available features are : \n
    \n
  • \n \n Service 1\n
  • \n
  • \n \n Product 1\n
  • \n
\n
\n
\n Subscribe\n
\n
\n
\n \n \n \n
\n
\n
\n
PREMIUM
\n
For large companies
\n
The full option package for a one shot price\n
\n
\n 2499\n
\n
\n Available features are :\n
    \n
  • \n \n Service 1
  • \n
  • \n \n Service 2
  • \n
  • \n \n Product 1
  • \n
\n
\n
\n Buy\n
\n
\n
\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n
\n \n \n \n
\n
\n

our team

\n
\n
\n \n
\n
\n
\n
\n\n\n \n
\n
\n
\n
\n
\n

Request a callback

\n
\n
\n \n
\n
\n \n
\n
\n \n
\n
\n \n
\n
\n
\n
\n
\n
\n
\n \n \n \n
\n
\n
\n
\n
\n

successful cases

\n
\n
\n
\n
\n
\"\"\n
\n
\n
\n
\"\"\n
\n
\n
\n
\"\"\n
\n
\n
\n
\"\"\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n Albert Einstein\n
\n
Scientist, www.emc2.org
\n
\n
\n
\n
\n
-20%
\n
Expenses
\n
\n
\n
\n
\n
\n
\n \n They did everything, with almost no time or effort for me. The best part was that I could trust their team to represent our company professionally with our clients.\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n Pierre Curie\n
\n
CEO “Cyclonic”
\n
\n
\n
\n
\n
-30%
\n
Expenses
\n
\n
\n
\n
\n
\n
\n \n Their course gave me the confidence to implement new techniques in my work. I learn “how” to write – “what” and “why” also became much clearer.\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n Marie Curie\n
\n
CTO \"Cyclonic\"
\n
\n
\n
\n
\n
+22%
\n
Turnover
\n
\n
\n
\n
\n
\n
\n \n We were skeptical to work with a consultant to optimize our sales emails, but they were highly recommended by many other startups we knew. They helped us to reach our objective of 20% turnover increase, in 4 monthes.\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n John Doe\n
\n
Sale representative
\n
\n
\n
\n
\n
+40%
\n
Quotes
\n
\n
\n
\n
\n
\n
\n \n Their work on our website and Internet marketing has made a significant different to our business. We’ve seen a +40% increase in quote requests from our website.\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n \n\n \n
\n
\n

Latest News

\n \n
\n
\n\n\n \n\n\n
\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(12,5,'our-team','','Our team','Our team','team','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Our team\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n

\n

The crew...




\n query($sql);\n if (! $resql) dol_print_error($db);\n while ($obj = $db->fetch_object($resql))\n {\n $arrayofusers[]=$obj->rowid;\n }\n \n print \'
\';\n foreach($arrayofusers as $id)\n {\n $fuser->fetch($id);\n\n print \'
\';\n print \'
\';\n print \'
\';\n if ($fuser->photo) print Form::showphoto(\'userphoto\', $fuser, 100, 0, 0, \'photowithmargin\', \'\', 0);\n //print \'photo.\'\" width=\"129\" height=\"129\" alt=\"\">\';\n else print \'\"\"\';\n print \'
\';\n print \'
\';\n print \'
\'.$fuser->firstname.\'
\';\n print \'
    \';\n //print \'
  • September 24, 2018
  • \';\n if ($fuser->job) print \'
  • \'.$fuser->job.\'
  • \';\n else print \'
  • \';\n print \'
\';\n print \'
\';\n print \'
\';\n print \'
\';\n }\n print \'
\';\n\n ?>\n
\n
\n\n

\n\n \n\n
\n \n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(13,5,'partners','','Partners','Partners','partners','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Partners\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n
\n

Our partners...

\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n

\n\n \n\n
\n \n\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(14,5,'pricing','','Pricing','All the prices of our offers','pricing','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Our plans\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n\n\n \n
\n
\n
\n \n
\n \n
\n \n
\n\n \n
\n \n
\n
\n
\n
FREE
\n
The best choice for personal use
\n
The service 1 for free
\n
\n 0/ month\n
\n
\n Available features are : \n
    \n
  • \n \n Service 1 \n
  • \n
\n
\n
\n Subcribe\n
\n
\n
\n \n \n \n
\n
\n
\n
STARTER
\n
For small companiess
\n
The service 1 and product 1 at low price
\n
\n 29/ month\n
\n
\n Available features are : \n
    \n
  • \n \n Service 1\n
  • \n
  • \n \n Product 1\n
  • \n
\n
\n
\n Subscribe\n
\n
\n
\n \n \n \n
\n
\n
\n
PREMIUM
\n
For large companies
\n
The full option package for a one shot price\n
\n
\n 2499\n
\n
\n Available features are :\n
    \n
  • \n \n Service 1
  • \n
  • \n \n Service 2
  • \n
  • \n \n Product 1
  • \n
\n
\n
\n Buy\n
\n
\n
\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n
\n \n \n \n

\n\n \n\n
\n \n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(15,5,'privacy-policies','','Privacy Policies','Privacy Policies','Privacy policies, GDPR','
\n \n \n \n\n\n
\n
\n
\n
\n
\n
\n
\n
\n
Privacy Policy\n
\n
\n
\n
\n
\n
\n
\n
\n\n


\n\n
\n
\n

Information collected and used


\n

* Your customer information (email, phone, business name, first and last name of contact, address, postal code, country and VAT number) are stored when you become a customer. This information allows us to bill you. \n

* If you paid using our online service, we also store the last 4 digits of your card. The full details of your credit card is stored by our payment provider Stripe (the world leader in online payment).

\n

* You have the option to request the deletion of your data and the above information at any time (except data required y fiscal tracking rules, like your invoices).

\n

* The Privacy Policies and GDPR referral contact for our services is: global->MAIN_INFO_GDPR; ?>

\n


\n

Data Storage and Backups


\n

* The storage of collected data (see \'Information collected and used\') is done in a database.

\n

* We made one backup every week. Only 4 weeks are kept.

\n


\n

Subcontractor


\n

* Our services relies on the following subcontractors and service:
\n** The host of computer servers, which is ABC company. These servers are hosted in US. No customer information is communicated to this subcontractor who only provides the hardware and network layer, the installation and operation being carried out by us directly.
\n** The online payment service Stripe, which is used, to ensure regular payment of subscription or your invoices paid online.

\n


\n

Software Protection


\n

* Our services runs on Linux Ubuntu systems and software. They benefit from regular security updates when the operating system editor (Ubuntu Canonical) publishes them.

\n

* Our services are accessible in HTTPS (HTTP encrypted) only, encrypted with SHA256 certificates.

\n

* Our technical platform are protected by various solutions.

\n


\n

Data theft


\n

* In case of suspicion of a theft of the data we have collected (see first point \'Information collected and used\'), customers will be informed by email, at email corresponding to their customer account

\n

 

\n
\n
\n\n\n \n \n \n
\n \n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(16,5,'product-p','','Product P','Product P','','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Product P\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n
\n
\n
\n
\nThis is a description page of our product P...
\n
\n
\n
\n
\n
\n
\n\n\n

\n\n \n\n
\n \n\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(17,5,'search','','Search Page','Search Page','','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Search\n
\n
\n
\n
\n
\n
\n
\n
\n\n


\n\n
\n \n
\n
\n \" />\n
\n \">\n
\n
\n \n
\n
\n
\n \n load(\"main\");\n \n if (function_exists(\'getPagesFromSearchCriterias\'))\n {\n if (GETPOSTISSET(\'s\'))\n {\n $listofpages = getPagesFromSearchCriterias(\'page\', \'meta\', GETPOST(\'s\', \'alphanohtml\'));\n if ($listofpages[\'code\'] == \'OK\')\n {\n foreach($listofpages[\'list\'] as $websitepagefound)\n {\n print \'
ref.\'.php\">\'.$websitepagefound->title.\' - \'.$websitepagefound->description.\'
\';\n }\n }\n else\n {\n // If error, show message\n print $listofpages[\'message\'];\n }\n }\n }\n else\n {\n print $weblangs->trans(\"FeatureNotYetAvailable\");\n }\n ?>\n \n





\n
\n\n \n\n
\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(18,5,'service-s','','Service S','Service S','','
\n\n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
Service S\n
\n
\n
\n
\n
\n
\n
\n
\n\n\n
\n
\n
\n
\n
\nThis is a description page of our service S...
\n
\n
\n
\n
\n
\n
\n\n\n

\n\n \n\n
\n',1,'2020-10-07 13:13:26',NULL,'2020-12-10 12:28:18',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(19,5,'test','','test','Page test','test','Test\n',1,'2020-10-07 13:13:26',NULL,'2020-10-07 11:13:26',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(20,4,'credits','','Credits','Credits and legal notices','',' \n \n
\n\n \n
\n

Mentions légales

\n

Curriculum Vitae

\n
\n\n \n \n\n \n
\n\n \n
\n\n

\n \nThis site is edited by name; ?>\n\n \n

\n\n
\n\n
\n\n \n \n\n
\n\n',1,'2019-08-15 16:39:56',NULL,'2020-02-21 09:27:17',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(21,4,'footer','','Footer','','',' \n
\n
\n

Aliquam sed mauris

\n

Sed lorem ipsum dolor sit amet et nullam consequat feugiat consequat magna adipiscing tempus etiam dolore veroeros. eget dapibus mauris. Cras aliquet, nisl ut viverra sollicitudin, ligula erat egestas velit, vitae tincidunt odio.

\n \n
\n
\n

Etiam feugiat

\n
\n
Address
\n
getFullAddress(1, \'
\'); ?>
\n
Phone
\n
phone; ?>
\n
Email
\n
email; ?>\">email; ?>
\n
\n
\n
© Untitled. Design: HTML5 UP adapted for Dolibarr by NLTechno.
\n
\n\n\n\n\n\n',1,'2019-08-15 16:42:44',NULL,'2020-06-19 08:18:14',NULL,NULL,'page','fr',NULL,'','',NULL,'','',0,NULL,NULL),(22,4,'generic','','Generic page','Generic page or my personal Blog','My generic page',' \n\n
\n\n \n
\n

Another page

\n

Ipsum dolor sit amet nullam

\n
\n\n \n \n\n \n
\n\n \n
\n \"\"\n

Magna feugiat lorem

\n

Donec eget ex magna. Interdum et malesuada fames ac ante ipsum primis in faucibus. Pellentesque venenatis dolor imperdiet dolor mattis sagittis. Praesent rutrum sem diam, vitae egestas enim auctor sit amet. Pellentesque leo mauris, consectetur id ipsum sit amet, fergiat. Pellentesque in mi eu massa lacinia malesuada et a elit. Donec urna ex, lacinia in purus ac, pretium pulvinar mauris. Curabitur sapien risus, commodo eget turpis at, elementum convallis fames ac ante ipsum primis in faucibus.

\n

Pellentesque venenatis dolor imperdiet dolor mattis sagittis. Praesent rutrum sem diam, vitae egestas enim auctor sit amet.

\n

Tempus veroeros

\n

Cep risus aliquam gravida cep ut lacus amet. Adipiscing faucibus nunc placerat. Tempus adipiscing turpis non blandit accumsan eget lacinia nunc integer interdum amet aliquam ut orci non col ut ut praesent.

\n
\n\n \n
\n

Latest Blog posts

\n
\n loadLangs(array(\"main\",\"website\"));\n $fuser = new User($db);\n $arrayofblogs = $websitepage->fetchAll($website->id, \'DESC\', \'date_creation\', 5, 0, array(\'type_container\'=>\'blogpost\', \'status\'=>1, \'lang\'=>\'null,\'.$websitepage->lang)); // , \'keywords\'=>$keyword\n if (is_numeric($arrayofblogs) && $arrayofblogs < 0)\n {\n print \'
\'.$weblangs->trans($websitepage->error).\'
\';\n }\n elseif (is_array($arrayofblogs) && ! empty($arrayofblogs))\n {\n foreach($arrayofblogs as $blog)\n {\n print \'\';\n }\n }\n else\n {\n print \'
\';\n print \'
\';\n //print $weblangs->trans(\"NoArticlesFoundForTheKeyword\", $keyword);\n print $weblangs->trans(\"NoArticlesFound\");\n print \'
\';\n print \'
\';\n \n }\n ?>\n
\n
\n\n
\n\n\n\n \n \n \n \n
\n\n',1,'2019-08-15 00:03:43',NULL,'2020-05-14 16:48:34',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(23,4,'home','','My personal blog','Home page or my personal Blog','My personal blog','\n
\n\n \n
\n
\n

David Doe

\n

Welcome on my website
\n

\n
\n
\n\n \n \n\n \n
\n\n \n
\n
\n
\n
\n

Ipsum sed adipiscing

\n
\n

Sed lorem ipsum dolor sit amet nullam consequat feugiat consequat magna\n adipiscing magna etiam amet veroeros. Lorem ipsum dolor tempus sit cursus.\n Tempus nisl et nullam lorem ipsum dolor sit amet aliquam.

\n \n
\n \"\"\n
\n
\n\n \n
\n
\n

Magna veroeros

\n
\n
    \n
  • \n \n

    Ipsum consequat

    \n

    Sed lorem amet ipsum dolor et amet nullam consequat a feugiat consequat tempus veroeros sed consequat.

    \n
  • \n
  • \n \n

    Amed sed feugiat

    \n

    Sed lorem amet ipsum dolor et amet nullam consequat a feugiat consequat tempus veroeros sed consequat.

    \n
  • \n
  • \n \n

    Dolor nullam

    \n

    Sed lorem amet ipsum dolor et amet nullam consequat a feugiat consequat tempus veroeros sed consequat.

    \n
  • \n
\n \n
\n\n \n
\n
\n

Ipsum consequat

\n

Donec imperdiet consequat consequat. Suspendisse feugiat congue
\n posuere. Nulla massa urna, fermentum eget quam aliquet.

\n
\n
    \n
  • \n \n 5,120 Etiam\n
  • \n
  • \n \n 8,192 Magna\n
  • \n
  • \n \n 2,048 Tempus\n
  • \n
  • \n \n 4,096 Aliquam\n
  • \n
  • \n \n 1,024 Nullam\n
  • \n
\n

Nam elementum nisl et mi a commodo porttitor. Morbi sit amet nisl eu arcu faucibus hendrerit vel a risus. Nam a orci mi, elementum ac arcu sit amet, fermentum pellentesque et purus. Integer maximus varius lorem, sed convallis diam accumsan sed. Etiam porttitor placerat sapien, sed eleifend a enim pulvinar faucibus semper quis ut arcu. Ut non nisl a mollis est efficitur vestibulum. Integer eget purus nec nulla mattis et accumsan ut magna libero. Morbi auctor iaculis porttitor. Sed ut magna ac risus et hendrerit scelerisque. Praesent eleifend lacus in lectus aliquam porta. Cras eu ornare dui curabitur lacinia.

\n \n
\n\n \n
\n
\n

Congue imperdiet

\n

Donec imperdiet consequat consequat. Suspendisse feugiat congue
\n posuere. Nulla massa urna, fermentum eget quam aliquet.

\n
\n \n
\n\n
\n\n \n\n
\n\n',1,'2019-08-15 00:03:43',NULL,'2020-11-26 10:30:41',NULL,NULL,'page','en',NULL,'','',NULL,'','',0,NULL,NULL),(24,4,'menu','','Menu','Menu common to all pages','','\n',1,'2019-08-15 00:03:43',NULL,'2020-02-21 09:27:17',NULL,NULL,'menu','fr',NULL,'','',NULL,'','',0,NULL,NULL),(25,4,'this-is-a-blog-post','','This is a Blog post','This is a full meta description of the article','blog','\n
\n This is a blog post article...\n
\n',1,'2019-08-17 17:18:45',NULL,'2020-05-14 16:54:52',NULL,NULL,'blogpost','',NULL,'','',NULL,'','webmaster',0,NULL,NULL); /*!40000 ALTER TABLE `llx_website_page` ENABLE KEYS */; UNLOCK TABLES; @@ -12732,6 +13194,31 @@ LOCK TABLES `llx_workstation_workstation_resource` WRITE; /*!40000 ALTER TABLE `llx_workstation_workstation_resource` ENABLE KEYS */; UNLOCK TABLES; +-- +-- Table structure for table `llx_workstation_workstation_usergroup` +-- + +DROP TABLE IF EXISTS `llx_workstation_workstation_usergroup`; +/*!40101 SET @saved_cs_client = @@character_set_client */; +/*!40101 SET character_set_client = utf8 */; +CREATE TABLE `llx_workstation_workstation_usergroup` ( + `rowid` int(11) NOT NULL AUTO_INCREMENT, + `tms` timestamp NOT NULL DEFAULT current_timestamp() ON UPDATE current_timestamp(), + `fk_usergroup` int(11) DEFAULT NULL, + `fk_workstation` int(11) DEFAULT NULL, + PRIMARY KEY (`rowid`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; +/*!40101 SET character_set_client = @saved_cs_client */; + +-- +-- Dumping data for table `llx_workstation_workstation_usergroup` +-- + +LOCK TABLES `llx_workstation_workstation_usergroup` WRITE; +/*!40000 ALTER TABLE `llx_workstation_workstation_usergroup` DISABLE KEYS */; +/*!40000 ALTER TABLE `llx_workstation_workstation_usergroup` ENABLE KEYS */; +UNLOCK TABLES; + -- -- Table structure for table `llx_zapier_hook` -- @@ -12773,4 +13260,4 @@ UNLOCK TABLES; /*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */; /*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */; --- Dump completed on 2021-07-11 19:54:10 +-- Dump completed on 2022-02-07 15:44:10 diff --git a/dev/initdemo/savedemo.sh b/dev/initdemo/savedemo.sh index 7366f5b0bc9..d863bd75c9d 100755 --- a/dev/initdemo/savedemo.sh +++ b/dev/initdemo/savedemo.sh @@ -116,7 +116,7 @@ then fichtemp=`tempfile 2>/dev/null` || fichtemp=/tmp/test$$ trap "rm -f $fichtemp" 0 1 2 5 15 $DIALOG --title "Save Dolibarr with demo values" --clear \ - --inputbox "Password for Mysql root login :" 16 55 2> $fichtemp + --passwordbox "Password for Mysql root login :" 16 55 2> $fichtemp valret=$? @@ -150,7 +150,7 @@ then # ---------------------------- confirmation DIALOG=${DIALOG=dialog} $DIALOG --title "Save Dolibarr with demo values" --clear \ - --yesno "Do you confirm ? \n Dump file : '$dumpfile' \n Dump dir : '$mydir' \n Mysql database : '$base' \n Mysql port : '$port' \n Mysql login: '$admin' \n Mysql password : '$passwd'" 15 55 + --yesno "Do you confirm ? \n Dump file : '$dumpfile' \n Dump dir : '$mydir' \n Mysql database : '$base' \n Mysql port : '$port' \n Mysql login: '$admin' \n Mysql password : --hidden--" 15 55 case $? in 0) echo "Ok, start process...";; diff --git a/dev/initdemo/sftpget_and_loaddump.php b/dev/initdemo/sftpget_and_loaddump.php index 7d781fe5b0c..63b5ac65054 100755 --- a/dev/initdemo/sftpget_and_loaddump.php +++ b/dev/initdemo/sftpget_and_loaddump.php @@ -4,7 +4,7 @@ * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or + * the Free Software Foundation; either version 3 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, diff --git a/dev/initdemo/updatedemo.php b/dev/initdemo/updatedemo.php index 4dd98451823..4ee2032c7cf 100755 --- a/dev/initdemo/updatedemo.php +++ b/dev/initdemo/updatedemo.php @@ -4,7 +4,7 @@ * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or + * the Free Software Foundation; either version 3 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, diff --git a/dev/resources/iso-normes/Intracommreport-ManuelDebXml.pdf b/dev/resources/iso-normes/Intracommreport-ManuelDebXml.pdf deleted file mode 100644 index fef9f48f53e..00000000000 Binary files a/dev/resources/iso-normes/Intracommreport-ManuelDebXml.pdf and /dev/null differ diff --git a/dev/resources/iso-normes/QR code for invoices.txt b/dev/resources/iso-normes/QR code for invoices.txt new file mode 100644 index 00000000000..a55c9569297 --- /dev/null +++ b/dev/resources/iso-normes/QR code for invoices.txt @@ -0,0 +1,13 @@ +List of QR Code format we found on some invoices +------------------------------------------------ + + +* For SEPA QR payment Code format (Europe) +------------------------------------------ +https://en.wikipedia.org/wiki/EPC_QR_code#Generators + + + +* For ZATCA QR Code format (Saudi Arabia) +----------------------------------------- +https://www.pwc.com/m1/en/services/tax/me-tax-legal-news/2021/saudi-arabia-guide-to-develop-compliant-qr-code-for-simplified-einvoices.html diff --git a/dev/resources/iso-normes/address_format.txt b/dev/resources/iso-normes/address_format.txt index d87e90e79b5..18069cd89fa 100644 --- a/dev/resources/iso-normes/address_format.txt +++ b/dev/resources/iso-normes/address_format.txt @@ -1,3 +1,5 @@ +Address format + https://bitboost.com/ref/international-address-formats.html#Formats https://www.upu.int/en/Postal-Solutions/Programmes-Services/Addressing-Solutions diff --git a/dev/resources/facturx-zugferd/README.txt b/dev/resources/iso-normes/facturx-zugferd/README.txt similarity index 100% rename from dev/resources/facturx-zugferd/README.txt rename to dev/resources/iso-normes/facturx-zugferd/README.txt diff --git a/dev/resources/iso-normes/format PDF - PDF A.pdf b/dev/resources/iso-normes/format PDF - PDF A.pdf new file mode 100644 index 00000000000..0ceeb5230de Binary files /dev/null and b/dev/resources/iso-normes/format PDF - PDF A.pdf differ diff --git a/dev/resources/iso-normes/format_FEC-Lien_outil_de_test_agréé.pdf b/dev/resources/iso-normes/format_FEC - Lien_outil_de_test_agréé.pdf similarity index 100% rename from dev/resources/iso-normes/format_FEC-Lien_outil_de_test_agréé.pdf rename to dev/resources/iso-normes/format_FEC - Lien_outil_de_test_agréé.pdf diff --git a/dev/resources/iso-normes/sample_FEC_file.txt b/dev/resources/iso-normes/format_FEC - fie example.txt similarity index 100% rename from dev/resources/iso-normes/sample_FEC_file.txt rename to dev/resources/iso-normes/format_FEC - fie example.txt diff --git a/dev/resources/intracommreport/manuelDebXml1.2.pdf b/dev/resources/iso-normes/intracommreport/Intracommreport-ManuelDebXml.pdf similarity index 100% rename from dev/resources/intracommreport/manuelDebXml1.2.pdf rename to dev/resources/iso-normes/intracommreport/Intracommreport-ManuelDebXml.pdf diff --git a/dev/resources/iso-normes/Intracommreport-ManuelDesXML.pdf b/dev/resources/iso-normes/intracommreport/Intracommreport-ManuelDesXML.pdf similarity index 100% rename from dev/resources/iso-normes/Intracommreport-ManuelDesXML.pdf rename to dev/resources/iso-normes/intracommreport/Intracommreport-ManuelDesXML.pdf diff --git a/dev/resources/intracommreport/schema_deb.xsd b/dev/resources/iso-normes/intracommreport/schema_deb.xsd similarity index 100% rename from dev/resources/intracommreport/schema_deb.xsd rename to dev/resources/iso-normes/intracommreport/schema_deb.xsd diff --git a/dev/resources/iso-normes/locales.txt b/dev/resources/iso-normes/locales.txt index 67ea5280342..a4459d2a8b1 100644 --- a/dev/resources/iso-normes/locales.txt +++ b/dev/resources/iso-normes/locales.txt @@ -1,3 +1,5 @@ +Date and number format +---------------------- For languages: https://icu4c-demos.unicode.org/icu-bin/icudemos - Locale Explorer -> Error 404 diff --git a/dev/resources/sepa/pain.001.001.03.xsd b/dev/resources/iso-normes/sepa/pain.001.001.03.xsd similarity index 100% rename from dev/resources/sepa/pain.001.001.03.xsd rename to dev/resources/iso-normes/sepa/pain.001.001.03.xsd diff --git a/dev/resources/sepa/pain.008.001.02.xsd b/dev/resources/iso-normes/sepa/pain.008.001.02.xsd similarity index 100% rename from dev/resources/sepa/pain.008.001.02.xsd rename to dev/resources/iso-normes/sepa/pain.008.001.02.xsd diff --git a/dev/resources/sepa/sample-credit-transfer.xml b/dev/resources/iso-normes/sepa/sample-credit-transfer.xml similarity index 100% rename from dev/resources/sepa/sample-credit-transfer.xml rename to dev/resources/iso-normes/sepa/sample-credit-transfer.xml diff --git a/dev/resources/sepa/sample-direct-debit.xml b/dev/resources/iso-normes/sepa/sample-direct-debit.xml similarity index 100% rename from dev/resources/sepa/sample-direct-debit.xml rename to dev/resources/iso-normes/sepa/sample-direct-debit.xml diff --git a/dev/resources/sepa/text.txt b/dev/resources/iso-normes/sepa/text.txt similarity index 100% rename from dev/resources/sepa/text.txt rename to dev/resources/iso-normes/sepa/text.txt diff --git a/dev/resources/iso-normes/world_tax_rates.txt b/dev/resources/iso-normes/world_tax_rates.txt index c007474e5fd..508446b618a 100644 --- a/dev/resources/iso-normes/world_tax_rates.txt +++ b/dev/resources/iso-normes/world_tax_rates.txt @@ -1,3 +1,6 @@ +VAT Rates +--------- + http://www.taxrates.cc/index.html https://en.wikipedia.org/wiki/List_of_countries_by_tax_rates diff --git a/dev/setup/apache/virtualhost b/dev/setup/apache/virtualhost index c3a2dff3e43..8c7682fe3d9 100644 --- a/dev/setup/apache/virtualhost +++ b/dev/setup/apache/virtualhost @@ -1,62 +1,93 @@ -#php_admin_value sendmail_path "/usr/sbin/sendmail -t -i" -#php_admin_value mail.force_extra_parameters "-f postmaster@mydomain.com" -php_admin_value sendmail_path "/usr/sbin/sendmail -t -i -f postmaster@mydomain.com" -php_admin_value open_basedir /tmp/:/home/../htdocs + #php_admin_value sendmail_path "/usr/sbin/sendmail -t -i" + #php_admin_value mail.force_extra_parameters "-f postmaster@mydomain.com" + php_admin_value sendmail_path "/usr/sbin/sendmail -t -i -f postmaster@mydomain.com" + php_admin_value open_basedir /tmp/:/home/.../htdocs:/home/.../dolibarr_documents: + + ServerName myvirtualalias + ServerAlias myvirtualalias + + UseCanonicalName On + + KeepAlive On + KeepAliveTimeout 5 + MaxKeepAliveRequests 20 + + AddDefaultCharset UTF-8 + + DocumentRoot "/home/.../htdocs" + + + AllowOverride None + Options -Indexes -MultiViews +FollowSymLinks -ExecCGI + Require all granted -ServerName myvirtualalias -ServerAlias myvirtualalias + # To restrict access by a HTTP basic auth + #AuthType Basic + #AuthName "Authenticate to backoffice" + #AuthUserFile /etc/apache2/.htpasswd + #require valid-user + + + # Leaving /public and /api, /dav, .well_known but also wrappers for document and viewimage accessible to everyone + + AuthType None + Require all granted + Satisfy any + + + AuthType None + Require all granted + Satisfy any + + + AuthType None + Require all granted + Satisfy any + + + AuthType None + Require all granted + Satisfy any + + + AuthType None + Require all granted + Satisfy any + -UseCanonicalName On - -AddDefaultCharset UTF-8 - -DocumentRoot "/home/.../htdocs" - - - AllowOverride None - Options -Indexes -MultiViews +FollowSymLinks -ExecCGI - Require all granted - - - - Deny from all - RemoveHandler .phtml .php .php3 .php4 .php5 .php6 .phps .cgi .exe .pl .asp .aspx .shtml .shtm .fcgi .fpl .jsp .htm .html .wml - AddType application/x-httpd-php-source .phtml .php .php3 .php4 .php5 .php6 .phps .cgi .exe .pl .asp .aspx .shtml .shtm .fcgi .fpl .jsp .htm .html .wml - - - -ErrorLog /var/log/apache2/myvirtualalias_error_log -TransferLog /var/log/apache2/myvirtualalias_access_log - -# Compress returned resources of type php pages, text file export, css and javascript -AddOutputFilterByType DEFLATE text/html text/plain text/xml text/css text/javascript application/javascript application/x-javascript - -AddType text/javascript .jgz -AddEncoding gzip .jgz -ExpiresActive On -ExpiresByType image/x-icon A2592000 -ExpiresByType image/gif A2592000 -ExpiresByType image/png A2592000 -ExpiresByType image/jpeg A2592000 -ExpiresByType text/css A2592000 -ExpiresByType text/javascript A2592000 -ExpiresByType application/x-javascript A2592000 -ExpiresByType application/javascript A2592000 - -SSLEngine On - -# A self-signed (snakeoil) certificate can be created by installing -# the ssl-cert package. See -# /usr/share/doc/apache2.2-common/README.Debian.gz for more info. -# If both key and certificate are stored in the same file, only the -# SSLCertificateFile directive is needed. -SSLCertificateFile /etc/letsencrypt/live/www.mydomain.com/cert.pem -SSLCertificateKeyFile /etc/letsencrypt/live/www.mydomain.com/privkey.pem -SSLCertificateChainFile /etc/letsencrypt/live/www.mydomain.com/chain.pem - -#RewriteEngine on -#RewriteCond %{SERVER_PORT} ^80$ -#RewriteRule ^(.*)$ https://%{SERVER_NAME}$1 [L,R] + + ErrorLog /var/log/apache2/myvirtualalias_error_log + TransferLog /var/log/apache2/myvirtualalias_access_log + + # Compress returned resources of type php pages, text file export, css and javascript + AddOutputFilterByType DEFLATE text/html text/plain text/xml text/css text/javascript application/javascript application/x-javascript + + AddType text/javascript .jgz + AddEncoding gzip .jgz + ExpiresActive On + ExpiresByType image/x-icon A2592000 + ExpiresByType image/gif A2592000 + ExpiresByType image/png A2592000 + ExpiresByType image/jpeg A2592000 + ExpiresByType text/css A2592000 + ExpiresByType text/javascript A2592000 + ExpiresByType application/x-javascript A2592000 + ExpiresByType application/javascript A2592000 + + SSLEngine On + + # A self-signed (snakeoil) certificate can be created by installing + # the ssl-cert package. See + # /usr/share/doc/apache2.2-common/README.Debian.gz for more info. + # If both key and certificate are stored in the same file, only the + # SSLCertificateFile directive is needed. + SSLCertificateFile /etc/letsencrypt/live/www.mydomain.com/cert.pem + SSLCertificateKeyFile /etc/letsencrypt/live/www.mydomain.com/privkey.pem + SSLCertificateChainFile /etc/letsencrypt/live/www.mydomain.com/chain.pem + + #RewriteEngine on + #RewriteCond %{SERVER_PORT} ^80$ + #RewriteRule ^(.*)$ https://%{SERVER_NAME}$1 [L,R] diff --git a/dev/tools/fixdosfiles.sh b/dev/tools/fixdosfiles.sh index 6fd152127fb..4be867aea98 100755 --- a/dev/tools/fixdosfiles.sh +++ b/dev/tools/fixdosfiles.sh @@ -17,14 +17,14 @@ fi # To detec if [ "x$1" = "xlist" ] then - find . \( -iname "functions" -o -iname "*.md" -o -iname "*.html" -o -iname "*.htm" -o -iname "*.php" -o -iname "*.sh" -o -iname "*.cml" -o -iname "*.css" -o -iname "*.js" -o -iname "*.lang" -o -iname "*.pl" -o -iname "*.sql" -o -iname "*.txt" -o -iname "*.xml" -o -iname "*.pml" \) -exec file "{}" + | grep -v 'documents\/website' | grep -v 'documents\/mdedias' | grep CRLF -# find . \( -iname "*.md" -o -iname "*.html" -o -iname "*.htm" -o -iname "*.php" -o -iname "*.sh" -o -iname "*.cml" -o -iname "*.css" -o -iname "*.js" -o -iname "*.lang" -o -iname "*.pl" -o -iname "*.sql" -o -iname "*.txt" -o -iname "*.xml" \) -exec file "{}" + | grep -v 'documents\/website' | grep -v 'documents\/mdedias' | grep -v 'htdocs\/includes' | grep CRLF + find . \( -iname "functions" -o -iname "*.md" -o -iname "*.html" -o -iname "*.htm" -o -iname "*.php" -o -iname "*.sh" -o -iname "*.cml" -o -iname "*.css" -o -iname "*.js" -o -iname "*.lang" -o -iname "*.pl" -o -iname "*.sql" -o -iname "*.txt" -o -iname "*.xml" -o -iname "*.pml" \) -exec file "{}" + | grep -v 'custom\/' | grep -v 'documents\/website' | grep -v 'documents\/medias' | grep -v 'documents\/sellyoursaas' | grep CRLF +# find . \( -iname "*.md" -o -iname "*.html" -o -iname "*.htm" -o -iname "*.php" -o -iname "*.sh" -o -iname "*.cml" -o -iname "*.css" -o -iname "*.js" -o -iname "*.lang" -o -iname "*.pl" -o -iname "*.sql" -o -iname "*.txt" -o -iname "*.xml" \) -exec file "{}" + | grep -v 'custom\/' | grep -v 'documents\/website' | grep -v 'documents\/medias' | grep -v 'documents\/sellyoursaas' | grep -v 'htdocs\/includes' | grep CRLF fi # To convert if [ "x$1" = "xfix" ] then - for fic in `find . \( -iname "functions" -o -iname "*.md" -o -iname "*.html" -o -iname "*.htm" -o -iname "*.php" -o -iname "*.sh" -o -iname "*.cml" -o -iname "*.css" -o -iname "*.js" -o -iname "*.lang" -o -iname "*.pl" -o -iname "*.sql" -o -iname "*.txt" -o -iname "*.xml" -o -iname "*.pml" \) -exec file "{}" + | grep -v 'documents\/website' | grep -v 'documents\/mdedias' | grep CRLF | awk -F':' '{ print $1 }' ` + for fic in `find . \( -iname "functions" -o -iname "*.md" -o -iname "*.html" -o -iname "*.htm" -o -iname "*.php" -o -iname "*.sh" -o -iname "*.cml" -o -iname "*.css" -o -iname "*.js" -o -iname "*.lang" -o -iname "*.pl" -o -iname "*.sql" -o -iname "*.txt" -o -iname "*.xml" -o -iname "*.pml" \) -exec file "{}" + | grep -v 'custom\/' | grep -v 'documents\/website' | grep -v 'documents\/medias' | grep -v 'documents\/sellyoursaas' | grep CRLF | awk -F':' '{ print $1 }' ` do echo "Fix file $fic" dos2unix "$fic" diff --git a/dev/tools/optimize_images.sh b/dev/tools/optimize_images.sh index 2f8a84c57e7..dd538c5e1aa 100755 --- a/dev/tools/optimize_images.sh +++ b/dev/tools/optimize_images.sh @@ -14,7 +14,8 @@ max_output_size=0 usage() { cat <trans("New"), $langs->trans("Addanaccount"), 'fa fa-plus-circle', './card.php?action=create'); include DOL_DOCUMENT_ROOT.'/core/tpl/massactions_pre.tpl.php'; - print_barre_liste($langs->trans('ListAccounts'), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 'title_accountancy', 0, $newcardbutton, '', $limit, 0, 0, 1); + print_barre_liste($langs->trans('ListAccounts'), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 'accounting_account', 0, $newcardbutton, '', $limit, 0, 0, 1); // Box to select active chart of account print $langs->trans("Selectchartofaccounts")." : "; @@ -404,6 +404,11 @@ if ($resql) { $moreforfilter = ''; + $accountstatic = new AccountingAccount($db); + $accountparent = new AccountingAccount($db); + $totalarray = array(); + $totalarray['nbfield'] = 0; + print '
'; print ''."\n"; @@ -466,11 +471,6 @@ if ($resql) { print_liste_field_titre($selectedfields, $_SERVER["PHP_SELF"], "", '', '', '', $sortfield, $sortorder, 'center maxwidthsearch '); print "\n"; - $accountstatic = new AccountingAccount($db); - $accountparent = new AccountingAccount($db); - $totalarray = array(); - $totalarray['nbfield'] = 0; - $i = 0; while ($i < min($num, $limit)) { $obj = $db->fetch_object($resql); @@ -615,8 +615,13 @@ if ($resql) { } if ($num == 0) { - $totalarray['nbfield']++; - print ''; + $colspan = 1; + foreach ($arrayfields as $key => $val) { + if (!empty($val['checked'])) { + $colspan++; + } + } + print ''; } print "
'.$langs->trans("None").'
'.$langs->trans("None").'
"; diff --git a/htdocs/accountancy/admin/accountmodel.php b/htdocs/accountancy/admin/accountmodel.php index 97a460beaac..fd0ff2e72da 100644 --- a/htdocs/accountancy/admin/accountmodel.php +++ b/htdocs/accountancy/admin/accountmodel.php @@ -185,11 +185,6 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) { $ok = 0; setEventMessages($langs->transnoentities('ErrorCodeCantContainZero'), null, 'errors'); } - /*if (!is_numeric($_POST['code'])) // disabled, code may not be in numeric base - { - $ok = 0; - $msg .= $langs->transnoentities('ErrorFieldFormat', $langs->transnoentities('Code')).'
'; - }*/ } if (GETPOSTISSET("country") && (GETPOST("country") == '0') && ($id != 2)) { $ok = 0; @@ -228,17 +223,17 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) { $i = 0; foreach ($listfieldinsert as $f => $value) { if ($value == 'price' || preg_match('/^amount/i', $value) || $value == 'taux') { - $_POST[$listfieldvalue[$i]] = price2num($_POST[$listfieldvalue[$i]], 'MU'); + $_POST[$listfieldvalue[$i]] = price2num(GETPOST($listfieldvalue[$i]), 'MU'); } elseif ($value == 'entity') { $_POST[$listfieldvalue[$i]] = $conf->entity; } if ($i) { $sql .= ","; } - if ($_POST[$listfieldvalue[$i]] == '') { + if (GETPOST($listfieldvalue[$i]) == '') { $sql .= "null"; } else { - $sql .= "'".$db->escape($_POST[$listfieldvalue[$i]])."'"; + $sql .= "'".$db->escape(GETPOST($listfieldvalue[$i]))."'"; } $i++; } @@ -276,7 +271,7 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) { $i = 0; foreach ($listfieldmodify as $field) { if ($field == 'price' || preg_match('/^amount/i', $field) || $field == 'taux') { - $_POST[$listfieldvalue[$i]] = price2num($_POST[$listfieldvalue[$i]], 'MU'); + $_POST[$listfieldvalue[$i]] = price2num(GETPOST($listfieldvalue[$i]), 'MU'); } elseif ($field == 'entity') { $_POST[$listfieldvalue[$i]] = $conf->entity; } @@ -284,10 +279,10 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) { $sql .= ","; } $sql .= $field."="; - if ($_POST[$listfieldvalue[$i]] == '') { + if (GETPOST($listfieldvalue[$i]) == '') { $sql .= "null"; } else { - $sql .= "'".$db->escape($_POST[$listfieldvalue[$i]])."'"; + $sql .= "'".$db->escape(GETPOST($listfieldvalue[$i]))."'"; } $i++; } @@ -495,7 +490,7 @@ if ($id) { if ($valuetoshow != '') { print ''; if (!empty($tabhelp[$id][$value]) && preg_match('/^http(s*):/i', $tabhelp[$id][$value])) { - print ''.$valuetoshow.' '.img_help(1, $valuetoshow).''; + print ''.$valuetoshow.' '.img_help(1, $valuetoshow).''; } elseif (!empty($tabhelp[$id][$value])) { print $form->textwithpicto($valuetoshow, $tabhelp[$id][$value]); } else { diff --git a/htdocs/accountancy/admin/card.php b/htdocs/accountancy/admin/card.php index 9430bf33439..91d8257ea7f 100644 --- a/htdocs/accountancy/admin/card.php +++ b/htdocs/accountancy/admin/card.php @@ -417,13 +417,13 @@ if ($action == 'create') { print '
'; if (!empty($user->rights->accounting->chartofaccount)) { - print ''.$langs->trans('Modify').''; + print 'id.'">'.$langs->trans('Modify').''; } else { print ''.$langs->trans('Modify').''; } if (!empty($user->rights->accounting->chartofaccount)) { - print ''.$langs->trans('Delete').''; + print 'id.'">'.$langs->trans('Delete').''; } else { print ''.$langs->trans('Delete').''; } diff --git a/htdocs/accountancy/admin/categories_list.php b/htdocs/accountancy/admin/categories_list.php index d914b825b7f..c0439445261 100644 --- a/htdocs/accountancy/admin/categories_list.php +++ b/htdocs/accountancy/admin/categories_list.php @@ -148,10 +148,10 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) { if ($value == 'formula' && !GETPOST('formula')) { continue; } - if ($value == 'range_account' && empty($_POST['range_account'])) { + if ($value == 'range_account' && !GETPOST('range_account')) { continue; } - if (($value == 'country' || $value == 'country_id') && (!empty($_POST['country_id']))) { + if (($value == 'country' || $value == 'country_id') && GETPOST('country_id')) { continue; } if (!GETPOSTISSET($value) || GETPOST($value) == '') { @@ -195,17 +195,6 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) { setEventMessages($langs->transnoentities('ErrorFieldMustBeANumeric', $langs->transnoentities("Position")), null, 'errors'); } - // Clean some parameters - if ($_POST["accountancy_code"] <= 0) { - $_POST["accountancy_code"] = ''; // If empty, we force to null - } - if ($_POST["accountancy_code_sell"] <= 0) { - $_POST["accountancy_code_sell"] = ''; // If empty, we force to null - } - if ($_POST["accountancy_code_buy"] <= 0) { - $_POST["accountancy_code_buy"] = ''; // If empty, we force to null - } - // Si verif ok et action add, on ajoute la ligne if ($ok && GETPOST('actionadd', 'alpha')) { if ($tabrowid[$id]) { @@ -243,7 +232,7 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) { if ($i) { $sql .= ","; } - if ($_POST[$listfieldvalue[$i]] == '' && !$listfieldvalue[$i] == 'formula') { + if (GETPOST($listfieldvalue[$i]) == '' && !$listfieldvalue[$i] == 'formula') { $sql .= "null"; // For vat, we want/accept code = '' } else { $sql .= "'".$db->escape(GETPOST($listfieldvalue[$i]))."'"; @@ -283,8 +272,8 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) { } $i = 0; foreach ($listfieldmodify as $field) { - if ($field == 'fk_country' && $_POST['country'] > 0) { - $_POST[$listfieldvalue[$i]] = $_POST['country']; + if ($field == 'fk_country' && GETPOST('country') > 0) { + $_POST[$listfieldvalue[$i]] = GETPOST('country'); } elseif ($field == 'entity') { $_POST[$listfieldvalue[$i]] = $conf->entity; } @@ -292,10 +281,10 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) { $sql .= ","; } $sql .= $field."="; - if ($_POST[$listfieldvalue[$i]] == '' && !$listfieldvalue[$i] == 'range_account') { + if (GETPOST($listfieldvalue[$i]) == '' && !$listfieldvalue[$i] == 'range_account') { $sql .= "null"; // For range_account, we want/accept code = '' } else { - $sql .= "'".$db->escape($_POST[$listfieldvalue[$i]])."'"; + $sql .= "'".$db->escape(GETPOST($listfieldvalue[$i]))."'"; } $i++; } @@ -520,7 +509,7 @@ if ($tabname[$id]) { if ($valuetoshow != '') { print ''; if (!empty($tabhelp[$id][$value]) && preg_match('/^http(s*):/i', $tabhelp[$id][$value])) { - print ''.$valuetoshow.' '.img_help(1, $valuetoshow).''; + print ''.$valuetoshow.' '.img_help(1, $valuetoshow).''; } elseif (!empty($tabhelp[$id][$value])) { print $form->textwithpicto($valuetoshow, $tabhelp[$id][$value]); } else { diff --git a/htdocs/accountancy/admin/defaultaccounts.php b/htdocs/accountancy/admin/defaultaccounts.php index 5d78036159a..c99503f95f6 100644 --- a/htdocs/accountancy/admin/defaultaccounts.php +++ b/htdocs/accountancy/admin/defaultaccounts.php @@ -52,6 +52,7 @@ $list_account_main = array( ); $list_account = array(); + $list_account[] = '---Product---'; $list_account[] = 'ACCOUNTING_PRODUCT_SOLD_ACCOUNT'; if ($mysoc->isInEEC()) { @@ -63,6 +64,7 @@ if ($mysoc->isInEEC()) { $list_account[] = 'ACCOUNTING_PRODUCT_BUY_INTRA_ACCOUNT'; } $list_account[] = 'ACCOUNTING_PRODUCT_BUY_EXPORT_ACCOUNT'; + $list_account[] = '---Service---'; $list_account[] = 'ACCOUNTING_SERVICE_SOLD_ACCOUNT'; if ($mysoc->isInEEC()) { @@ -74,11 +76,11 @@ if ($mysoc->isInEEC()) { $list_account[] = 'ACCOUNTING_SERVICE_BUY_INTRA_ACCOUNT'; } $list_account[] = 'ACCOUNTING_SERVICE_BUY_EXPORT_ACCOUNT'; + $list_account[] = '---Others---'; $list_account[] = 'ACCOUNTING_VAT_BUY_ACCOUNT'; $list_account[] = 'ACCOUNTING_VAT_SOLD_ACCOUNT'; $list_account[] = 'ACCOUNTING_VAT_PAY_ACCOUNT'; -$list_account[] = 'ACCOUNTING_ACCOUNT_SUSPENSE'; if ($conf->banque->enabled) { $list_account[] = 'ACCOUNTING_ACCOUNT_TRANSFER_CASH'; } @@ -96,6 +98,7 @@ if ($conf->loan->enabled) { if ($conf->societe->enabled) { $list_account[] = 'ACCOUNTING_ACCOUNT_CUSTOMER_DEPOSIT'; } +$list_account[] = 'ACCOUNTING_ACCOUNT_SUSPENSE'; /* * Actions @@ -154,6 +157,7 @@ print ''; // Define main accounts for thirdparty +print '
'; print ''; print ''; @@ -164,17 +168,29 @@ foreach ($list_account_main as $key) { $keydesc = $key.'_Desc'; $htmltext = $langs->trans($keydesc); - print ''; // Value - print ''; print ''; } +print "
'.$langs->trans("ThirdParties").' | '.$langs->trans("Users").'
'; + print ''; + if ($key == 'ACCOUNTING_ACCOUNT_CUSTOMER') { + print img_picto('', 'company', 'class="pictofixedwidth"'); + } elseif ($key == 'ACCOUNTING_ACCOUNT_SUPPLIER') { + print img_picto('', 'company', 'class="pictofixedwidth"'); + } else { + print img_picto('', 'user', 'class="pictofixedwidth"'); + } print $form->textwithpicto($label, $htmltext); print ''; // Do not force class=right, or it align also the content of the select box + print ''; // Do not force class=right, or it align also the content of the select box print $formaccounting->select_account($conf->global->$key, $key, 1, '', 1, 1, 'minwidth100 maxwidth300 maxwidthonsmartphone', 'accountsmain'); print '
\n"; +print "
\n"; +print '
'; +print ''; + foreach ($list_account as $key) { $reg = array(); if (preg_match('/---(.*)---/', $key, $reg)) { @@ -183,9 +199,32 @@ foreach ($list_account as $key) { print ''; // Param $label = $langs->trans($key); - print ''; + print ''; // Value - print ''; print ''; @@ -194,7 +233,7 @@ foreach ($list_account as $key) { print "
'.$label.''; + if (preg_match('/^ACCOUNTING_PRODUCT/', $key)) { + print img_picto('', 'product', 'class="pictofixedwidth"'); + } elseif (preg_match('/^ACCOUNTING_SERVICE/', $key)) { + print img_picto('', 'service', 'class="pictofixedwidth"'); + } elseif (preg_match('/^ACCOUNTING_VAT_PAY_ACCOUNT/', $key)) { + print img_picto('', 'payment_vat', 'class="pictofixedwidth"'); + } elseif (preg_match('/^ACCOUNTING_VAT/', $key)) { + print img_picto('', 'vat', 'class="pictofixedwidth"'); + } elseif (preg_match('/^ACCOUNTING_ACCOUNT_CUSTOMER/', $key)) { + print img_picto('', 'bill', 'class="pictofixedwidth"'); + } elseif (preg_match('/^LOAN_ACCOUNTING_ACCOUNT/', $key)) { + print img_picto('', 'loan', 'class="pictofixedwidth"'); + } elseif (preg_match('/^DONATION_ACCOUNTING/', $key)) { + print img_picto('', 'donation', 'class="pictofixedwidth"'); + } elseif (preg_match('/^ADHERENT_SUBSCRIPTION/', $key)) { + print img_picto('', 'member', 'class="pictofixedwidth"'); + } elseif (preg_match('/^ACCOUNTING_ACCOUNT_TRANSFER/', $key)) { + print img_picto('', 'bank_account', 'class="pictofixedwidth"'); + } elseif (preg_match('/^ACCOUNTING_ACCOUNT_SUSPENSE/', $key)) { + print img_picto('', 'question', 'class="pictofixedwidth"'); + } + print $label; + print ''; // Do not force class=right, or it align also the content of the select box + print ''; // Do not force class=right, or it align also the content of the select box print $formaccounting->select_account(getDolGlobalString($key), $key, 1, '', 1, 1, 'minwidth100 maxwidth300 maxwidthonsmartphone', 'accounts'); print '
\n"; - +print "
\n"; print '
'; diff --git a/htdocs/accountancy/admin/export.php b/htdocs/accountancy/admin/export.php index 9e393beeacd..8cef3a05cf4 100644 --- a/htdocs/accountancy/admin/export.php +++ b/htdocs/accountancy/admin/export.php @@ -142,7 +142,7 @@ $linkback = ''; print load_fiche_titre($langs->trans('ExportOptions'), $linkback, 'accountancy'); -print "\n".''; + +$object_label = $langs->trans("ObjectsRef"); +if ($object->nature == 2 || $object->nature == 3) $object_label = $langs->trans("InvoiceRef"); +if ($object->nature == 5) $object_label = $langs->trans("ExpenseReportRef"); + +/* + * Show result array + */ +print '
'; + +print '
'; +print ''; +print ''; +print ''; +print ''; +print ''; +print ''; +print ''; +if ($object->nature == 4) print ''; // bank +print ''; +print ''; +print "\n"; + +foreach ($journal_data as $element_id => $element) { + foreach ($element['blocks'] as $lines) { + foreach ($lines as $line) { + print ''; + print ''; + print ''; + print ''; + print ''; + print ''; + if ($object->nature == 4) print ''; + print ''; + print ''; + print ''; + } + } +} + +print '
' . $langs->trans("Date") . '' . $langs->trans("Piece") . ' (' . $object_label . ')' . $langs->trans("AccountAccounting") . '' . $langs->trans("SubledgerAccount") . '' . $langs->trans("LabelOperation") . '' . $langs->trans("PaymentMode") . '' . $langs->trans("Debit") . '' . $langs->trans("Credit") . '
' . $line['date'] . '' . $line['piece'] . '' . $line['account_accounting'] . '' . $line['subledger_account'] . '' . $line['label_operation'] . '' . $line['payment_mode'] . '' . $line['debit'] . '' . $line['credit'] . '
'; +print '
'; + +llxFooter(); + +$db->close(); diff --git a/htdocs/accountancy/supplier/index.php b/htdocs/accountancy/supplier/index.php index 4147762aff4..e46b508512d 100644 --- a/htdocs/accountancy/supplier/index.php +++ b/htdocs/accountancy/supplier/index.php @@ -34,6 +34,9 @@ require_once DOL_DOCUMENT_ROOT.'/accountancy/class/accountingaccount.class.php'; // Load translation files required by the page $langs->loadLangs(array("compta", "bills", "other", "accountancy")); +$validatemonth = GETPOST('validatemonth', 'int'); +$validateyear = GETPOST('validateyear', 'int'); + // Security check if (empty($conf->accounting->enabled)) { accessforbidden(); @@ -114,6 +117,9 @@ if (($action == 'clean' || $action == 'validatehistory') && $user->rights->accou if ($action == 'validatehistory') { $error = 0; + $nbbinddone = 0; + $notpossible = 0; + $db->begin(); // Now make the binding. Bind automatically only for product with a dedicated account that exists into chart of account, others need a manual bind @@ -149,7 +155,6 @@ if ($action == 'validatehistory') { } else { $sql .= " s.accountancy_code_buy as company_code_buy"; } - $sql .= " FROM ".MAIN_DB_PREFIX."facture_fourn as f"; $sql .= " INNER JOIN ".MAIN_DB_PREFIX."societe as s ON s.rowid = f.fk_soc"; if (!empty($conf->global->MAIN_COMPANY_PERENTITY_SHARED)) { @@ -167,11 +172,13 @@ if ($action == 'validatehistory') { $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."accounting_account as aa2 ON " . $alias_product_perentity . ".accountancy_code_buy_intra = aa2.account_number AND aa2.active = 1 AND aa2.fk_pcg_version = '".$db->escape($chartaccountcode)."' AND aa2.entity = ".$conf->entity; $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."accounting_account as aa3 ON " . $alias_product_perentity . ".accountancy_code_buy_export = aa3.account_number AND aa3.active = 1 AND aa3.fk_pcg_version = '".$db->escape($chartaccountcode)."' AND aa3.entity = ".$conf->entity; $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."accounting_account as aa4 ON " . $alias_societe_perentity . ".accountancy_code_buy = aa4.account_number AND aa4.active = 1 AND aa4.fk_pcg_version = '".$db->escape($chartaccountcode)."' AND aa4.entity = ".$conf->entity; - $sql .= " WHERE f.fk_statut > 0 AND l.fk_code_ventilation <= 0"; - $sql .= " AND l.product_type <= 2"; + $sql .= " WHERE f.fk_statut > 0 AND l.fk_code_ventilation <= 0 AND l.product_type <= 2 AND f.entity = ".((int) $conf->entity); if (!empty($conf->global->ACCOUNTING_DATE_START_BINDING)) { $sql .= " AND f.datef >= '".$db->idate($conf->global->ACCOUNTING_DATE_START_BINDING)."'"; } + if ($validatemonth && $validateyear) { + $sql .= dolSqlDateFilter('f.datef', 0, $validatemonth, $validateyear); + } dol_syslog('htdocs/accountancy/supplier/index.php'); @@ -204,7 +211,7 @@ if ($action == 'validatehistory') { $thirdpartystatic->email = $objp->email; $thirdpartystatic->country_code = $objp->country_code; $thirdpartystatic->tva_intra = $objp->tva_intra; - $thirdpartystatic->code_compta = $objp->company_code_sell; + $thirdpartystatic->code_compta_product = $objp->company_code_buy; // The accounting account for product stored on thirdparty object (for level3 suggestion) $product_static->ref = $objp->product_ref; $product_static->id = $objp->product_id; @@ -223,7 +230,7 @@ if ($action == 'validatehistory') { $facture_static->ref = $objp->ref; $facture_static->id = $objp->facid; $facture_static->type = $objp->ftype; - $facture_static->datef = $objp->datef; + $facture_static->date = $objp->datef; $facture_static_det->id = $objp->rowid; $facture_static_det->total_ht = $objp->total_ht; @@ -241,30 +248,23 @@ if ($action == 'validatehistory') { $code_buy_p_notset = ''; $code_buy_t_notset = ''; + $suggestedid = 0; + $return = $accountingAccount->getAccountingCodeToBind($mysoc, $thirdpartystatic, $product_static, $facture_static, $facture_static_det, $accountingAccountArray, 'supplier'); if (!is_array($return) && $return<0) { setEventMessage($accountingAccount->error, 'errors'); } else { - $suggestedid=$return['suggestedid']; - $suggestedaccountingaccountfor=$return['suggestedaccountingaccountfor']; + $suggestedid = $return['suggestedid']; + $suggestedaccountingaccountfor = $return['suggestedaccountingaccountfor']; - if (!empty($suggestedid) && $suggestedaccountingaccountfor<>'') { - $suggestedid=$return['suggestedid']; + if (!empty($suggestedid) && $suggestedaccountingaccountfor != '' && $suggestedaccountingaccountfor != 'eecwithoutvatnumber') { + $suggestedid = $return['suggestedid']; } else { - $suggestedid=0; + $suggestedid = 0; } } - if (!empty($conf->global->ACCOUNTANCY_USE_PRODUCT_ACCOUNT_ON_THIRDPARTY)) { - // Level 3: Search suggested account for this thirdparty (similar code exists in page index.php to make automatic binding) - if (!empty($objp->company_code_buy)) { - $objp->code_buy_t = $objp->company_code_buy; - $objp->aarowid_suggest = $objp->aarowid_thirdparty; - $suggestedaccountingaccountfor = ''; - } - } - - if ($objp->aarowid_suggest > 0) { + if ($suggestedid > 0) { $sqlupdate = "UPDATE ".MAIN_DB_PREFIX."facture_fourn_det"; $sqlupdate .= " SET fk_code_ventilation = ".((int) $suggestedid); $sqlupdate .= " WHERE fk_code_ventilation <= 0 AND product_type <= 2 AND rowid = ".((int) $facture_static_det->id); @@ -274,18 +274,25 @@ if ($action == 'validatehistory') { $error++; setEventMessages($db->lasterror(), null, 'errors'); break; + } else { + $nbbinddone++; } + } else { + $notpossible++; } $i++; } + if ($num_lines > 10000) { + $notpossible += ($num_lines - 10000); + } } if ($error) { $db->rollback(); } else { $db->commit(); - setEventMessages($langs->trans('AutomaticBindingDone'), null, 'mesgs'); + setEventMessages($langs->trans('AutomaticBindingDone', $nbbinddone, $notpossible), null, 'mesgs'); } } @@ -307,7 +314,7 @@ print '
'; $y = $year_current; -$buttonbind = ''.$langs->trans("ValidateHistory").''; +$buttonbind = ''.$langs->trans("ValidateHistory").''; print_barre_liste(img_picto('', 'unlink', 'class="paddingright fa-color-unset"').$langs->trans("OverviewOfAmountOfLinesNotBound"), '', '', '', '', '', '', -1, '', '', 0, $buttonbind, '', 0, 1, 1); @@ -322,7 +329,24 @@ for ($i = 1; $i <= 12; $i++) { if ($j > 12) { $j -= 12; } - print ''.$langs->trans('MonthShort'.str_pad($j, 2, '0', STR_PAD_LEFT)).''; + $cursormonth = $j; + if ($cursormonth > 12) { + $cursormonth -= 12; + } + $cursoryear = ($cursormonth < ($conf->global->SOCIETE_FISCAL_MONTH_START ? $conf->global->SOCIETE_FISCAL_MONTH_START : 1)) ? $y + 1 : $y; + $tmp = dol_getdate(dol_get_last_day($cursoryear, $cursormonth, 'gmt'), false, 'gmt'); + + print ''; + if (!empty($tmp['mday'])) { + $param = 'search_date_startday=1&search_date_startmonth='.$cursormonth.'&search_date_startyear='.$cursoryear; + $param .= '&search_date_endday='.$tmp['mday'].'&search_date_endmonth='.$tmp['mon'].'&search_date_endyear='.$tmp['year']; + print ''; + } + print $langs->trans('MonthShort'.str_pad($j, 2, '0', STR_PAD_LEFT)); + if (!empty($tmp['mday'])) { + print ''; + } + print ''; } print ''.$langs->trans("Total").''; @@ -350,6 +374,7 @@ $sql .= " AND ffd.product_type <= 2"; $sql .= " AND ff.entity IN (".getEntity('facture_fourn', 0).")"; // We don't share object for accountancy $sql .= " AND aa.account_number IS NULL"; $sql .= " GROUP BY ffd.fk_code_ventilation,aa.account_number,aa.label"; +$sql .= ' ORDER BY aa.account_number'; dol_syslog('htdocs/accountancy/supplier/index.php'); $resql = $db->query($sql); @@ -357,7 +382,8 @@ if ($resql) { $num = $db->num_rows($resql); while ($row = $db->fetch_row($resql)) { - print ''; + print ''; + print ''; if ($row[0] == 'tobind') { print ''.$langs->trans("Unknown").''; } else { @@ -366,19 +392,26 @@ if ($resql) { print ''; print ''; if ($row[0] == 'tobind') { - print $langs->trans("UseMenuToSetBindindManualy", DOL_URL_ROOT.'/accountancy/supplier/list.php?search_year='.$y, $langs->transnoentitiesnoconv("ToBind")); + print $langs->trans("UseMenuToSetBindindManualy", DOL_URL_ROOT.'/accountancy/supplier/list.php?search_year='.((int) $y), $langs->transnoentitiesnoconv("ToBind")); } else { print $row[1]; } print ''; - for ($i = 2; $i <= 12; $i++) { - print ''.price($row[$i]).''; + for ($i = 2; $i <= 13; $i++) { + print ''; + print price($row[$i]); + print ''; } - print ''.price($row[13]).''; print ''.price($row[14]).''; print ''; } $db->free($resql); + + if ($num == 0) { + print ''; + print ''.$langs->trans("NoRecordFound").''; + print ''; + } } else { print $db->lasterror(); // Show last sql error } @@ -401,7 +434,24 @@ for ($i = 1; $i <= 12; $i++) { if ($j > 12) { $j -= 12; } - print ''.$langs->trans('MonthShort'.str_pad($j, 2, '0', STR_PAD_LEFT)).''; + $cursormonth = $j; + if ($cursormonth > 12) { + $cursormonth -= 12; + } + $cursoryear = ($cursormonth < ($conf->global->SOCIETE_FISCAL_MONTH_START ? $conf->global->SOCIETE_FISCAL_MONTH_START : 1)) ? $y + 1 : $y; + $tmp = dol_getdate(dol_get_last_day($cursoryear, $cursormonth, 'gmt'), false, 'gmt'); + + print ''; + if (!empty($tmp['mday'])) { + $param = 'search_date_startday=1&search_date_startmonth='.$cursormonth.'&search_date_startyear='.$cursoryear; + $param .= '&search_date_endday='.$tmp['mday'].'&search_date_endmonth='.$tmp['mon'].'&search_date_endyear='.$tmp['year']; + print ''; + } + print $langs->trans('MonthShort'.str_pad($j, 2, '0', STR_PAD_LEFT)); + if (!empty($tmp['mday'])) { + print ''; + } + print ''; } print ''.$langs->trans("Total").''; @@ -436,7 +486,8 @@ if ($resql) { $num = $db->num_rows($resql); while ($row = $db->fetch_row($resql)) { - print ''; + print ''; + print ''; if ($row[0] == 'tobind') { print $langs->trans("Unknown"); } else { @@ -445,19 +496,26 @@ if ($resql) { print ''; print ''; if ($row[0] == 'tobind') { - print $langs->trans("UseMenuToSetBindindManualy", DOL_URL_ROOT.'/accountancy/supplier/list.php?search_year='.$y, $langs->transnoentitiesnoconv("ToBind")); + print $langs->trans("UseMenuToSetBindindManualy", DOL_URL_ROOT.'/accountancy/supplier/list.php?search_year='.((int) $y), $langs->transnoentitiesnoconv("ToBind")); } else { print $row[1]; } print ''; - for ($i = 2; $i <= 12; $i++) { - print ''.price($row[$i]).''; + for ($i = 2; $i <= 13; $i++) { + print ''; + print price($row[$i]); + print ''; } - print ''.price($row[13]).''; print ''.price($row[14]).''; print ''; } $db->free($resql); + + if ($num == 0) { + print ''; + print ''.$langs->trans("NoRecordFound").''; + print ''; + } } else { print $db->lasterror(); // Show last sql error } diff --git a/htdocs/accountancy/supplier/lines.php b/htdocs/accountancy/supplier/lines.php index b7d0a0423f3..9f769ae13b4 100644 --- a/htdocs/accountancy/supplier/lines.php +++ b/htdocs/accountancy/supplier/lines.php @@ -521,7 +521,7 @@ if ($result) { } print ''; - print ''.$objp->tva_intra.''; + print ''.dol_escape_htmltag($objp->tva_intra).''; print ''; print $accountingaccountstatic->getNomUrl(0, 1, 1, '', 1); diff --git a/htdocs/accountancy/supplier/list.php b/htdocs/accountancy/supplier/list.php index 20230c7cfad..24d0ed08a0a 100644 --- a/htdocs/accountancy/supplier/list.php +++ b/htdocs/accountancy/supplier/list.php @@ -291,7 +291,7 @@ if (strlen(trim($search_ref))) { $sql .= natural_search("p.ref", $search_ref); } if (strlen(trim($search_label))) { - $sql .= natural_search("f.libelle", $search_label); + $sql .= natural_search(array("p.label", "f.libelle"), $search_label); } if (strlen(trim($search_desc))) { $sql .= natural_search("l.description", $search_desc); @@ -529,11 +529,12 @@ if ($result) { while ($i < min($num_lines, $limit)) { $objp = $db->fetch_object($result); - // product_type: 0 = service ? 1 = product + // product_type: 0 = service, 1 = product // if product does not exist we use the value of product_type provided in facturedet to define if this is a product or service // issue : if we change product_type value in product DB it should differ from the value stored in facturedet DB ! - $objp->code_buy_l = ''; - $objp->code_buy_p = ''; + $code_buy_l = ''; + $code_buy_p = ''; + $code_buy_t = ''; $thirdpartystatic->id = $objp->socid; $thirdpartystatic->name = $objp->name; @@ -546,7 +547,7 @@ if ($result) { $thirdpartystatic->email = $objp->email; $thirdpartystatic->country_code = $objp->country_code; $thirdpartystatic->tva_intra = $objp->tva_intra; - $thirdpartystatic->code_compta_fournisseur = $objp->company_code_buy; + $thirdpartystatic->code_compta_product = $objp->company_code_buy; // The accounting account for product stored on thirdparty object (for level3 suggestion) $product_static->ref = $objp->product_ref; $product_static->id = $objp->product_id; @@ -566,18 +567,15 @@ if ($result) { $facturefourn_static->id = $objp->facid; $facturefourn_static->type = $objp->ftype; $facturefourn_static->label = $objp->invoice_label; + $facturefourn_static->date = $db->jdate($objp->datef); $facturefourn_static_det->id = $objp->rowid; $facturefourn_static_det->total_ht = $objp->total_ht; - $facturefourn_static_det->tva_tx_line = $objp->tva_tx_line; + $facturefourn_static_det->tva_tx = $objp->tva_tx_line; $facturefourn_static_det->vat_src_code = $objp->vat_src_code; $facturefourn_static_det->product_type = $objp->type_l; $facturefourn_static_det->desc = $objp->description; - $code_buy_p_notset = ''; - $code_buy_t_notset = ''; - $objp->aarowid_suggest = ''; // Will be set later - $accountingAccountArray = array( 'dom'=>$objp->aarowid, 'intra'=>$objp->aarowid_intra, @@ -587,6 +585,8 @@ if ($result) { $code_buy_p_notset = ''; $code_buy_t_notset = ''; + $suggestedid = 0; + $return=$accountingAccount->getAccountingCodeToBind($mysoc, $thirdpartystatic, $product_static, $facturefourn_static, $facturefourn_static_det, $accountingAccountArray, 'supplier'); if (!is_array($return) && $return<0) { setEventMessage($accountingAccount->error, 'errors'); @@ -594,9 +594,9 @@ if ($result) { $suggestedid=$return['suggestedid']; $suggestedaccountingaccountfor=$return['suggestedaccountingaccountfor']; $suggestedaccountingaccountbydefaultfor=$return['suggestedaccountingaccountbydefaultfor']; - $code_buy_l=$return['code_buy_l']; - $code_buy_p=$return['code_buy_p']; - $code_buy_t=$return['code_buy_t']; + $code_buy_l=$return['code_l']; + $code_buy_p=$return['code_p']; + $code_buy_t=$return['code_t']; } //var_dump($return); @@ -608,10 +608,14 @@ if ($result) { if (empty($code_buy_l) && empty($code_buy_p)) { $code_buy_p_notset = 'color:red'; } + /*if ($suggestedaccountingaccountfor == 'eecwithoutvatnumber' && empty($code_sell_p_notset)) { + $code_sell_p_notset = 'color:orange'; + }*/ // $code_buy_l is now default code of product/service // $code_buy_p is now code of product/service // $code_buy_t is now code of thirdparty + //var_dump($code_buy_l.' - '.$code_buy_p.' - '.$code_buy_t.' -> '.$suggestedid.' ('.$suggestedaccountingaccountbydefaultfor.' '.$suggestedaccountingaccountfor.')'); print ''; @@ -626,15 +630,15 @@ if ($result) { print ''; */ - print ''.dol_print_date($db->jdate($facturefourn_static_det->datef), 'day').''; + print ''.dol_print_date($facturefourn_static->date, 'day').''; // Ref Product print ''; if ($product_static->id > 0) { print $product_static->getNomUrl(1); } - if ($product_static->product_label) { - print '
'.$product_static->product_label.''; + if ($product_static->label) { + print '
'.$product_static->label.''; } print ''; @@ -650,11 +654,12 @@ if ($result) { print ''; // Vat rate - if ($objp->vat_tx_l != $objp->vat_tx_p && ! empty($objp->vat_tx_l)) { // Note: having a vat rate of 0 is often the normal case when sells is intra b2b or to export - $code_vat_differ = 'font-weight:bold; text-decoration:blink; color:red'; + $code_vat_differ = ''; + if ($objp->vat_tx_l != $objp->vat_tx_p && price2num($objp->vat_tx_p) && price2num($objp->vat_tx_l)) { // Note: having a vat rate of 0 is often the normal case when sells is intra b2b or to export + $code_vat_differ = 'warning bold'; } - print ''; - print vatrate($facturefourn_static_det->tva_tx_line.($facturefourn_static_det->vat_src_code ? ' ('.$facturefourn_static_det->vat_src_code.')' : '')); + print ''; + print vatrate($facturefourn_static_det->tva_tx.($facturefourn_static_det->vat_src_code ? ' ('.$facturefourn_static_det->vat_src_code.')' : '')); print ''; // Thirdparty @@ -667,11 +672,11 @@ if ($result) { print ''; // VAT Num - print ''.dol_escape_htmltag($objp->tva_intra).''; + print ''.dol_escape_htmltag($objp->tva_intra).''; // Found accounts print ''; - $s = '1. '.(($facturefourn_static_det->type_l == 1) ? $langs->trans("DefaultForService") : $langs->trans("DefaultForProduct")).': '; + $s = '1. '.(($facturefourn_static_det->product_type == 1) ? $langs->trans("DefaultForService") : $langs->trans("DefaultForProduct")).': '; $shelp = ''; if ($suggestedaccountingaccountbydefaultfor == 'eec') { $shelp .= $langs->trans("SaleEEC"); @@ -686,6 +691,11 @@ if ($result) { $shelp = ''; $ttype = 'help'; if ($suggestedaccountingaccountfor == 'eec') { $shelp = $langs->trans("SaleEEC"); + } elseif ($suggestedaccountingaccountfor == 'eecwithvat') { + $shelp = $langs->trans("SaleEECWithVAT"); + } elseif ($suggestedaccountingaccountfor == 'eecwithoutvatnumber') { + $shelp = $langs->trans("SaleEECWithoutVATNumber"); + $ttype = 'warning'; } elseif ($suggestedaccountingaccountfor == 'export') { $shelp = $langs->trans("SaleExport"); } @@ -714,12 +724,11 @@ if ($result) { // Column with checkbox print ''; - if (!empty($suggestedid)) { + $ischecked = 0; + if (!empty($suggestedid) && $suggestedaccountingaccountfor != '' && $suggestedaccountingaccountfor != 'eecwithoutvatnumber') { $ischecked = 1; - } else { - $ischecked = 0; } - print ''; + print ''; print ''; print ''; @@ -738,7 +747,7 @@ if ($db->type == 'mysqli') { } // Add code to auto check the box when we select an account -print ''; + } + } elseif ($val['type'] == 'product') { + if (!empty($conf->product->enabled) || !empty($conf->service->enabled)) { + $selected = (empty($conf->global->$constname) ? '' : $conf->global->$constname); + $form->select_produits($selected, $constname, '', 0); + } + } elseif ($val['type'] == 'accountancy_code') { + $selected = (empty($conf->global->$constname) ? '' : $conf->global->$constname); + if (!empty($conf->accounting->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/core/class/html.formaccounting.class.php'; + $formaccounting = new FormAccounting($db); + print $formaccounting->select_account($selected, $constname, 1, null, 1, 1, 'minwidth150 maxwidth300', 1); + } else { + print ''; + } + } elseif ($val['type'] == 'accountancy_category') { + $selected = (empty($conf->global->$constname) ? '' : $conf->global->$constname); + if (!empty($conf->accounting->enabled)) { + print ''; + // autosuggest from existing account types if found + print ''; + require_once DOL_DOCUMENT_ROOT . '/accountancy/class/accountancysystem.class.php'; + $accountsystem = new AccountancySystem($db); + $accountsystem->fetch($conf->global->CHARTOFACCOUNTS); + $sql = 'SELECT DISTINCT pcg_type FROM ' . MAIN_DB_PREFIX . 'accounting_account'; + $sql .= " WHERE fk_pcg_version = '" . $db->escape($accountsystem->ref) . "'"; + $sql .= ' AND entity in ('.getEntity('accounting_account', 0).')'; // Always limit to current entity. No sharing in accountancy. + $sql .= ' LIMIT 50000'; // just as a sanity check + $resql = $db->query($sql); + if ($resql) { + while ($obj = $db->fetch_object($resql)) { + print ''; + } else { + print ''; + } + } else { + print ''; + } + print ''; + } + } print ''; - print $form->buttonsSaveCancel("Save", ''); + print '
'; + print ''; + print '
'; print ''; print '
'; } else { - print ''; - print ''; + if (!empty($arrayofparameters)) { + print '
'.$langs->trans("Parameter").''.$langs->trans("Value").'
'; + print ''; - foreach ($arrayofparameters as $key => $val) { - print ''; + foreach ($arrayofparameters as $constname => $val) { + if ($val['enabled']==1) { + $setupnotempty++; + print ''; + } + } + + print '
'.$langs->trans("Parameter").''.$langs->trans("Value").'
'; - print $form->textwithpicto($langs->trans($key), $langs->trans($key.'Tooltip')); - print ''.$conf->global->$key.'
'; + $tooltiphelp = (($langs->trans($constname . 'Tooltip') != $constname . 'Tooltip') ? $langs->trans($constname . 'Tooltip') : ''); + print $form->textwithpicto($langs->trans($constname), $tooltiphelp); + print ''; + + if ($val['type'] == 'textarea') { + print dol_nl2br($conf->global->{$constname}); + } elseif ($val['type']== 'html') { + print $conf->global->{$constname}; + } elseif ($val['type'] == 'yesno') { + print ajax_constantonoff($constname); + } elseif (preg_match('/emailtemplate:/', $val['type'])) { + include_once DOL_DOCUMENT_ROOT . '/core/class/html.formmail.class.php'; + $formmail = new FormMail($db); + + $tmp = explode(':', $val['type']); + + $template = $formmail->getEMailTemplate($db, $tmp[1], $user, $langs, $conf->global->{$constname}); + if ($template<0) { + setEventMessages(null, $formmail->errors, 'errors'); + } + print $langs->trans($template->label); + } elseif (preg_match('/category:/', $val['type'])) { + $c = new Categorie($db); + $result = $c->fetch($conf->global->{$constname}); + if ($result < 0) { + setEventMessages(null, $c->errors, 'errors'); + } elseif ($result > 0 ) { + $ways = $c->print_all_ways(' >> ', 'none', 0, 1); // $ways[0] = "ccc2 >> ccc2a >> ccc2a1" with html formated text + $toprint = array(); + foreach ($ways as $way) { + $toprint[] = '
  • color ? ' style="background: #' . $c->color . ';"' : ' style="background: #bbb"') . '>' . $way . '
  • '; + } + print '
      ' . implode(' ', $toprint) . '
    '; + } + } elseif (preg_match('/thirdparty_type/', $val['type'])) { + if ($conf->global->{$constname}==2) { + print $langs->trans("Prospect"); + } elseif ($conf->global->{$constname}==3) { + print $langs->trans("ProspectCustomer"); + } elseif ($conf->global->{$constname}==1) { + print $langs->trans("Customer"); + } elseif ($conf->global->{$constname}==0) { + print $langs->trans("NorProspectNorCustomer"); + } + } elseif ($val['type'] == 'product') { + $product = new Product($db); + $resprod = $product->fetch($conf->global->{$constname}); + if ($resprod > 0) { + print $product->ref; + } elseif ($resprod < 0) { + setEventMessages(null, $object->errors, "errors"); + } + } elseif ($val['type'] == 'accountancy_code') { + if (!empty($conf->accounting->enabled)) { + require_once DOL_DOCUMENT_ROOT . '/accountancy/class/accountingaccount.class.php'; + $accountingaccount = new AccountingAccount($db); + $accountingaccount->fetch('', $conf->global->{$constname}, 1); + + print $accountingaccount->getNomUrl(0, 1, 1, '', 1); + } else { + print $conf->global->{$constname}; + } + } else { + print $conf->global->{$constname}; + } + print '
    '; + + print '
    '; + print ''.$langs->trans("Modify").''; + print '
    '; + } else { + print '
    '.$langs->trans("NothingToSetup"); } - - print ''; - - print '
    '; - print ''.$langs->trans("Modify").''; - print '
    '; } +if (empty($setupnotempty)) { + print '
    '.$langs->trans("NothingToSetup"); +} + +// Page end print dol_get_fiche_end(); -// End of page llxFooter(); $db->close(); diff --git a/htdocs/asset/agenda.php b/htdocs/asset/agenda.php new file mode 100644 index 00000000000..49a0c215701 --- /dev/null +++ b/htdocs/asset/agenda.php @@ -0,0 +1,215 @@ + + * Copyright (C) ---Put here your own copyright and developer email--- + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file htdocs/asset/agenda.php + * \ingroup asset + * \brief Tab of events on Asset + */ + +require '../main.inc.php'; +require_once DOL_DOCUMENT_ROOT.'/core/lib/asset.lib.php'; +require_once DOL_DOCUMENT_ROOT.'/asset/class/asset.class.php'; +require_once DOL_DOCUMENT_ROOT.'/contact/class/contact.class.php'; +require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php'; +require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; + +// Load translation files required by the page +$langs->loadLangs(array("assets", "other")); + +// Get parameters +$id = GETPOST('id', 'int'); +$ref = GETPOST('ref', 'alpha'); +$action = GETPOST('action', 'aZ09'); +$cancel = GETPOST('cancel', 'aZ09'); +$backtopage = GETPOST('backtopage', 'alpha'); + +if (GETPOST('actioncode', 'array')) { + $actioncode = GETPOST('actioncode', 'array', 3); + if (!count($actioncode)) { + $actioncode = '0'; + } +} else { + $actioncode = GETPOST("actioncode", "alpha", 3) ? GETPOST("actioncode", "alpha", 3) : (GETPOST("actioncode") == '0' ? '0' : (empty($conf->global->AGENDA_DEFAULT_FILTER_TYPE_FOR_OBJECT) ? '' : $conf->global->AGENDA_DEFAULT_FILTER_TYPE_FOR_OBJECT)); +} +$search_agenda_label = GETPOST('search_agenda_label'); + +$limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; +$sortfield = GETPOST("sortfield", 'alpha'); +$sortorder = GETPOST("sortorder", 'alpha'); +$page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); +if (empty($page) || $page == -1) { + $page = 0; +} // If $page is not defined, or '' or -1 +$offset = $limit * $page; +$pageprev = $page - 1; +$pagenext = $page + 1; +if (!$sortfield) { + $sortfield = 'a.datep,a.id'; +} +if (!$sortorder) { + $sortorder = 'DESC,DESC'; +} + +// Initialize technical objects +$object = new Asset($db); +$extrafields = new ExtraFields($db); +$diroutputmassaction = $conf->asset->dir_output.'/temp/massgeneration/'.$user->id; +$hookmanager->initHooks(array('assetagenda', 'globalcard')); // Note that conf->hooks_modules contains array +// Fetch optionals attributes and labels +$extrafields->fetch_name_optionals_label($object->table_element); + +// Load object +include DOL_DOCUMENT_ROOT.'/core/actions_fetchobject.inc.php'; // Must be include, not include_once // Must be include, not include_once. Include fetch and fetch_thirdparty but not fetch_optionals +if ($id > 0 || !empty($ref)) { + $upload_dir = $conf->asset->multidir_output[$object->entity]."/".$object->id; +} + +$permissiontoadd = $user->rights->asset->write; // Used by the include of actions_addupdatedelete.inc.php + +// Security check (enable the most restrictive one) +if ($user->socid > 0) accessforbidden(); +$isdraft = (($object->status == $object::STATUS_DRAFT) ? 1 : 0); +restrictedArea($user, $object->element, $object->id, $object->table_element, '', 'fk_soc', 'rowid', $isdraft); +if (empty($conf->asset->enabled)) accessforbidden(); + + +/* + * Actions + */ + +$parameters = array('id'=>$id); +$reshook = $hookmanager->executeHooks('doActions', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks +if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); +} + +if (empty($reshook)) { + // Cancel + if (GETPOST('cancel', 'alpha') && !empty($backtopage)) { + header("Location: ".$backtopage); + exit; + } + + // Purge search criteria + if (GETPOST('button_removefilter_x', 'alpha') || GETPOST('button_removefilter.x', 'alpha') || GETPOST('button_removefilter', 'alpha')) { // All tests are required to be compatible with all browsers + $actioncode = ''; + $search_agenda_label = ''; + } +} + + + +/* + * View + */ + +$form = new Form($db); + +if ($object->id > 0) { + $title = $langs->trans("Agenda"); + //if (! empty($conf->global->MAIN_HTML_TITLE) && preg_match('/thirdpartynameonly/',$conf->global->MAIN_HTML_TITLE) && $object->name) $title=$object->name." - ".$title; + $help_url = 'EN:Module_Agenda_En'; + llxHeader('', $title, $help_url); + + if (!empty($conf->notification->enabled)) { + $langs->load("mails"); + } + $head = assetPrepareHead($object); + + + print dol_get_fiche_head($head, 'agenda', $langs->trans("Asset"), -1, $object->picto); + + // Object card + // ------------------------------------------------------------ + $linkback = '' . $langs->trans("BackToList") . ''; + + $morehtmlref = '
    '; + $morehtmlref .= '
    '; + + + dol_banner_tab($object, 'ref', $linkback, 1, 'ref', 'ref', $morehtmlref); + + print '
    '; + print '
    '; + + $object->info($object->id); + dol_print_object_info($object, 1); + + print '
    '; + + print dol_get_fiche_end(); + + + // Actions buttons + + $objthirdparty = $object; + $objcon = new stdClass(); + + $out = '&origin=' . urlencode($object->element . '@' . $object->module) . '&originid=' . urlencode($object->id); + $urlbacktopage = $_SERVER['PHP_SELF'] . '?id=' . $object->id; + $out .= '&backtopage=' . urlencode($urlbacktopage); + $permok = $user->rights->agenda->myactions->create; + if ((!empty($objthirdparty->id) || !empty($objcon->id)) && $permok) { + //$out.='trans("AddAnAction"),'filenew'); + //$out.=""; + } + + + print '
    '; + + if (!empty($conf->agenda->enabled)) { + if (!empty($user->rights->agenda->myactions->create) || !empty($user->rights->agenda->allactions->create)) { + print '' . $langs->trans("AddAction") . ''; + } else { + print '' . $langs->trans("AddAction") . ''; + } + } + + print '
    '; + + if (!empty($conf->agenda->enabled) && (!empty($user->rights->agenda->myactions->read) || !empty($user->rights->agenda->allactions->read))) { + $param = '&id=' . $object->id . '&socid=' . $socid; + if (!empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) { + $param .= '&contextpage=' . urlencode($contextpage); + } + if ($limit > 0 && $limit != $conf->liste_limit) { + $param .= '&limit=' . urlencode($limit); + } + + + print load_fiche_titre($langs->trans("ActionsOnAsset"), '', ''); + + // List of all actions + $filters = array(); + $filters['search_agenda_label'] = $search_agenda_label; + + // TODO Replace this with same code than into list.php + show_actions_done($conf, $langs, $db, $object, null, 0, $actioncode, '', $filters, $sortfield, $sortorder, $object->module); + } +} + +// End of page +llxFooter(); +$db->close(); diff --git a/htdocs/asset/card.php b/htdocs/asset/card.php index 35c0ffcff88..c516866b7d0 100644 --- a/htdocs/asset/card.php +++ b/htdocs/asset/card.php @@ -1,6 +1,6 @@ - * Copyright (C) 2018 Alexandre Spangaro +/* Copyright (C) 2017 Laurent Destailleur + * Copyright (C) 2018 Alexandre Spangaro * * 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 @@ -29,7 +29,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/html.formcompany.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php'; // Load translation files required by the page -$langs->loadLangs(array("asset")); +$langs->loadLangs(array("assets", "other")); // Get parameters $id = GETPOST('id', 'int'); @@ -68,12 +68,6 @@ if (empty($action) && empty($id) && empty($ref)) { // Load object include DOL_DOCUMENT_ROOT.'/core/actions_fetchobject.inc.php'; // Must be include, not include_once. -// Security check -if (!empty($user->socid)) { - $socid = $user->socid; -} -$result = restrictedArea($user, 'asset', $id); - $permissiontoread = $user->rights->asset->read; $permissiontoadd = $user->rights->asset->write; // Used by the include of actions_addupdatedelete.inc.php and actions_lineupdown.inc.php $permissiontodelete = $user->rights->asset->delete || ($permissiontoadd && isset($object->status) && $object->status == $object::STATUS_DRAFT); @@ -81,7 +75,13 @@ $permissionnote = $user->rights->asset->write; // Used by the include of actions $permissiondellink = $user->rights->asset->write; // Used by the include of actions_dellink.inc.php $upload_dir = $conf->asset->multidir_output[isset($object->entity) ? $object->entity : 1]; -$error = 0; +// Security check (enable the most restrictive one) +if ($user->socid > 0) accessforbidden(); +if ($user->socid > 0) $socid = $user->socid; +$isdraft = (($object->status == $object::STATUS_DRAFT) ? 1 : 0); +restrictedArea($user, $object->element, $object->id, $object->table_element, '', 'fk_soc', 'rowid', $isdraft); +if (empty($conf->asset->enabled)) accessforbidden(); +if (!$permissiontoread) accessforbidden(); /* @@ -95,6 +95,8 @@ if ($reshook < 0) { } if (empty($reshook)) { + $error = 0; + $backurlforlist = DOL_URL_ROOT.'/asset/list.php'; if (empty($backtopage) || ($cancel && empty($id))) { @@ -107,6 +109,27 @@ if (empty($reshook)) { } } + $object->oldcopy = dol_clone($object); + $triggermodname = 'ASSET_MODIFY'; // Name of trigger action code to execute when we modify record + + // Action dispose object + if ($action == 'confirm_disposal' && $confirm == 'yes' && $permissiontoadd) { + $object->disposal_date = dol_mktime(12, 0, 0, GETPOST('disposal_datemonth', 'int'), GETPOST('disposal_dateday', 'int'), GETPOST('disposal_dateyear', 'int')); // for date without hour, we use gmt + $object->disposal_amount_ht = GETPOST('disposal_amount', 'int'); + $object->fk_disposal_type = GETPOST('fk_disposal_type', 'int'); + $disposal_invoice_id = GETPOST('disposal_invoice_id', 'int'); + $object->disposal_depreciated = ((GETPOST('disposal_depreciated') == '1' || GETPOST('disposal_depreciated') == 'on') ? 1 : 0); + $object->disposal_subject_to_vat = ((GETPOST('disposal_subject_to_vat') == '1' || GETPOST('disposal_subject_to_vat') == 'on') ? 1 : 0); + + $result = $object->dispose($user, $disposal_invoice_id); + if ($result < 0) { + setEventMessages($object->error, $object->errors, 'errors'); + } + $action = ''; + } elseif ($action == "add") { + $object->supplier_invoice_id = GETPOST('supplier_invoice_id', 'int'); + } + // Actions cancel, add, update, update_extras, confirm_validate, confirm_delete, confirm_deleteline, confirm_clone, confirm_close, confirm_setdraft, confirm_reopen include DOL_DOCUMENT_ROOT.'/core/actions_addupdatedelete.inc.php'; @@ -122,13 +145,6 @@ if (empty($reshook)) { // Action to build doc include DOL_DOCUMENT_ROOT.'/core/actions_builddoc.inc.php'; - if ($action == 'set_thirdparty' && $permissiontoadd) { - $object->setValueFrom('fk_soc', GETPOST('fk_soc', 'int'), '', '', 'date', '', $user, 'MYOBJECT_MODIFY'); - } - if ($action == 'classin' && $permissiontoadd) { - $object->setProject(GETPOST('projectid', 'int')); - } - // Actions to send emails $triggersendname = 'ASSET_SENTBYMAIL'; $autocopy = 'MAIN_MAIL_AUTOCOPY_ASSET_TO'; @@ -136,6 +152,7 @@ if (empty($reshook)) { include DOL_DOCUMENT_ROOT.'/core/actions_sendmails.inc.php'; } + /* * View * @@ -150,7 +167,7 @@ llxHeader('', $title, $help_url); // Part to create if ($action == 'create') { - print load_fiche_titre($langs->trans("NewAsset"), '', $object->picto); + print load_fiche_titre($langs->trans("NewObject", $langs->transnoentitiesnoconv("Asset")), '', 'object_'.$object->picto); print '
    '; print ''; @@ -161,9 +178,16 @@ if ($action == 'create') { if ($backtopageforcancel) { print ''; } + if (GETPOSTISSET('supplier_invoice_id')) { + $object->fields['supplier_invoice_id'] = array('type' => 'integer:FactureFournisseur:fourn/class/fournisseur.facture.class.php:1:entity IN (__SHARED_ENTITIES__)', 'label' => 'SupplierInvoice', 'enabled' => '1', 'noteditable' => '1', 'position' => 280, 'notnull' => 0, 'visible' => 1, 'index' => 1, 'validate' => '1',); + print ''; + } print dol_get_fiche_head(array(), ''); + // Set some default values + //if (! GETPOSTISSET('fieldname')) $_POST['fieldname'] = 'myvalue'; + print ''."\n"; // Common attributes @@ -185,12 +209,11 @@ if ($action == 'create') { // Part to edit record if (($id || $ref) && $action == 'edit') { - print load_fiche_titre($langs->trans("Assets")); + print load_fiche_titre($langs->trans("Asset"), '', 'object_'.$object->picto); print ''; print ''; print ''; - print ''; print ''; if ($backtopage) { print ''; @@ -222,18 +245,60 @@ if (($id || $ref) && $action == 'edit') { if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'create'))) { $res = $object->fetch_optionals(); - $head = asset_prepare_head($object); + $head = assetPrepareHead($object); print dol_get_fiche_head($head, 'card', $langs->trans("Asset"), -1, $object->picto); $formconfirm = ''; // Confirmation to delete if ($action == 'delete') { - $formconfirm = $form->formconfirm($_SERVER["PHP_SELF"].'?id='.$object->id, $langs->trans('DeleteAssets'), $langs->trans('ConfirmDeleteAsset'), 'confirm_delete', '', 0, 1); + $formconfirm = $form->formconfirm($_SERVER["PHP_SELF"].'?id='.$object->id, $langs->trans('DeleteAsset'), $langs->trans('ConfirmDeleteObject'), 'confirm_delete', '', 0, 1); + } elseif ($action == 'disposal') { + // Disposal + $langs->load('bills'); + + $disposal_date = dol_mktime(12, 0, 0, GETPOST('disposal_datemonth', 'int'), GETPOST('disposal_dateday', 'int'), GETPOST('disposal_dateyear', 'int')); // for date without hour, we use gmt + $disposal_amount = GETPOST('disposal_amount', 'int'); + $fk_disposal_type = GETPOST('fk_disposal_type', 'int'); + $disposal_invoice_id = GETPOST('disposal_invoice_id', 'int'); + $disposal_depreciated = GETPOSTISSET('disposal_depreciated') ? GETPOST('disposal_depreciated') : 1; + $disposal_depreciated = !empty($disposal_depreciated) ? 1 : 0; + $disposal_subject_to_vat = GETPOSTISSET('disposal_subject_to_vat') ? GETPOST('disposal_subject_to_vat') : 1; + $disposal_subject_to_vat = !empty($disposal_subject_to_vat) ? 1 : 0; + + $object->fields['fk_disposal_type']['visible'] = 1; + $disposal_type_form = $object->showInputField(null, 'fk_disposal_type', $fk_disposal_type, '', '', '', 0); + $object->fields['fk_disposal_type']['visible'] = -2; + + $object->fields['disposal_invoice_id'] = array('type' => 'integer:Facture:compta/facture/class/facture.class.php::entity IN (__SHARED_ENTITIES__)', 'enabled' => '1', 'notnull' => 1, 'visible' => 1, 'index' => 1, 'validate' => '1',); + $disposal_invoice_form = $object->showInputField(null, 'disposal_invoice_id', $disposal_invoice_id, '', '', '', 0); + unset($object->fields['disposal_invoice_id']); + + // Create an array for form + $formquestion = array( + array('type' => 'date', 'name' => 'disposal_date', 'tdclass' => 'fieldrequired', 'label' => $langs->trans("AssetDisposalDate"), 'value' => $disposal_date), + array('type' => 'text', 'name' => 'disposal_amount', 'tdclass' => 'fieldrequired', 'label' => $langs->trans("AssetDisposalAmount"), 'value' => $disposal_amount), + array('type' => 'other', 'name' => 'fk_disposal_type', 'tdclass' => 'fieldrequired', 'label' => $langs->trans("AssetDisposalType"), 'value' => $disposal_type_form), + array('type' => 'other', 'name' => 'disposal_invoice_id', 'label' => $langs->trans("InvoiceCustomer"), 'value' => $disposal_invoice_form), + array('type' => 'checkbox', 'name' => 'disposal_depreciated', 'label' => $langs->trans("AssetDisposalDepreciated"), 'value' => $disposal_depreciated), + array('type' => 'checkbox', 'name' => 'disposal_subject_to_vat', 'label' => $langs->trans("AssetDisposalSubjectToVat"), 'value' => $disposal_subject_to_vat), + ); + $formconfirm = $form->formconfirm($_SERVER["PHP_SELF"] . '?id=' . $object->id, $langs->trans('AssetDisposal'), $langs->trans('AssetConfirmDisposalAsk', $object->ref . ' - ' . $object->label), 'confirm_disposal', $formquestion, 'yes', 1); + } elseif ($action == 'reopen') { + // Re-open + // Create an array for form + $formquestion = array(); + $formconfirm = $form->formconfirm($_SERVER["PHP_SELF"].'?id='.$object->id, $langs->trans('ReOpen'), $langs->trans('AssetConfirmReOpenAsk', $object->ref), 'confirm_reopen', $formquestion, 'yes', 1); } + // Clone confirmation + /* elseif ($action == 'clone') { + // Create an array for form + $formquestion = array(); + $formconfirm = $form->formconfirm($_SERVER["PHP_SELF"].'?id='.$object->id, $langs->trans('ToClone'), $langs->trans('ConfirmCloneAsk', $object->ref), 'confirm_clone', $formquestion, 'yes', 1); + }*/ // Call Hook formConfirm - $parameters = array('formConfirm' => $formconfirm, 'lineid' => $lineid); + $parameters = array('formConfirm' => $formconfirm); $reshook = $hookmanager->executeHooks('formConfirm', $parameters, $object, $action); // Note that $action and $object may have been modified by hook if (empty($reshook)) { $formconfirm .= $hookmanager->resPrint; @@ -250,24 +315,19 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea $linkback = ''.$langs->trans("BackToList").''; $morehtmlref = '
    '; - /* - // Ref bis - $morehtmlref.=$form->editfieldkey("RefBis", 'ref_client', $object->ref_client, $object, $user->rights->asset->creer, 'string', '', 0, 1); - $morehtmlref.=$form->editfieldval("RefBis", 'ref_client', $object->ref_client, $object, $user->rights->asset->creer, 'string', '', null, null, '', 1); - // Thirdparty - $morehtmlref.='
    '.$langs->trans('ThirdParty') . ' : ' . $soc->getNomUrl(1); - */ $morehtmlref .= '
    '; + dol_banner_tab($object, 'ref', $linkback, 1, 'ref', 'ref', $morehtmlref); + print '
    '; print '
    '; print '
    '; - print '
    '."\n"; + print '
    '."\n"; // Common attributes - //$keyforbreak='fieldkeytoswitchonsecondcolumn'; // We change column just after this field + $keyforbreak='date_acquisition'; // We change column just before this field //unset($object->fields['fk_project']); // Hide field already shown in banner //unset($object->fields['fk_soc']); // Hide field already shown in banner include DOL_DOCUMENT_ROOT.'/core/tpl/commonfields_view.tpl.php'; @@ -277,69 +337,100 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea print '
    '; print '
    '; + print '
    '; print '
    '; print dol_get_fiche_end(); - - /* - * Buttons - */ - if ($user->socid == 0) { - print '
    '; - + // Buttons for actions + if ($action != 'presend' && $action != 'editline') { + print '
    ' . "\n"; $parameters = array(); $reshook = $hookmanager->executeHooks('addMoreActionsButtons', $parameters, $object, $action); // Note that $action and $object may have been modified by hook + if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); + } if (empty($reshook)) { - if ($user->rights->asset->write) { - print ''.$langs->trans("Modify").''."\n"; - } else { - print ''.$langs->trans('Modify').''."\n"; + // Send + if (empty($user->socid)) { + print dolGetButtonAction($langs->trans('SendMail'), '', 'default', $_SERVER["PHP_SELF"] . '?id=' . $object->id . '&action=presend&mode=init&token=' . newToken() . '#formmailbeforetitle'); } - if ($user->rights->asset->delete) { - print ''.$langs->trans('Delete').''."\n"; - } else { - print ''.$langs->trans('Delete').''."\n"; + if ($object->status == $object::STATUS_DRAFT) { + print dolGetButtonAction($langs->trans('Modify'), '', 'default', $_SERVER["PHP_SELF"] . '?id=' . $object->id . '&action=edit&token=' . newToken(), '', $permissiontoadd); } + + // Clone + //print dolGetButtonAction($langs->trans('ToClone'), '', 'default', $_SERVER['PHP_SELF'] . '?id=' . $object->id . '&action=clone&token=' . newToken(), '', false && $permissiontoadd); + + if ($object->status == $object::STATUS_DRAFT) { + print dolGetButtonAction($langs->trans('AssetDisposal'), '', 'default', $_SERVER['PHP_SELF'] . '?id=' . $object->id . '&action=disposal&token=' . newToken(), '', $permissiontoadd); + } else { + print dolGetButtonAction($langs->trans('ReOpen'), '', 'default', $_SERVER['PHP_SELF'] . '?id=' . $object->id . '&action=reopen&token=' . newToken(), '', $permissiontoadd); + } + + // Delete (need delete permission, or if draft, just need create/modify permission) + print dolGetButtonAction($langs->trans('Delete'), '', 'delete', $_SERVER['PHP_SELF'] . '?id=' . $object->id . '&action=delete&token=' . newToken(), '', $permissiontodelete || ($object->status == $object::STATUS_DRAFT && $permissiontoadd)); } - print "
    "; + print '
    ' . "\n"; + } + + // Select mail models is same action as presend + if (GETPOST('modelselected')) { + $action = 'presend'; } if ($action != 'presend') { print '
    '; print ''; // ancre - // Documents - $filename = dol_sanitizeFileName($object->ref); - $filedir = $conf->contrat->dir_output."/".dol_sanitizeFileName($object->ref); - $urlsource = $_SERVER["PHP_SELF"]."?id=".$object->id; - $genallowed = $user->rights->asset->read; // If you can read, you can build the PDF to read content - $delallowed = $user->rights->asset->write; // If you can create/edit, you can remove a file on card + $includedocgeneration = 0; - print $formfile->showdocuments('asset', $filename, $filedir, $urlsource, 0, $delallowed, $object->model_pdf, 1, 0, 0, 28, 0, '', '', '', $soc->default_lang); + // Documents + if ($includedocgeneration) { + $objref = dol_sanitizeFileName($object->ref); + $relativepath = $objref.'/'.$objref.'.pdf'; + $filedir = $conf->asset->dir_output.'/'.$objref; + $urlsource = $_SERVER["PHP_SELF"]."?id=".$object->id; + $genallowed = $user->rights->asset->read; // If you can read, you can build the PDF to read content + $delallowed = $user->rights->asset->write; // If you can create/edit, you can remove a file on card + print $formfile->showdocuments('asset:Asset', $objref, $filedir, $urlsource, $genallowed, $delallowed, $object->model_pdf, 1, 0, 0, 28, 0, '', '', '', $langs->defaultlang); + } // Show links to link elements $linktoelem = $form->showLinkToObjectBlock($object, null, array('asset')); $somethingshown = $form->showLinkedObjectBlock($object, $linktoelem); + print '
    '; $MAXEVENT = 10; - $morehtmlcenter = dolGetButtonTitle($langs->trans('SeeAll'), '', 'fa fa-list-alt imgforviewmode', DOL_URL_ROOT.'/asset/info.php?id='.$object->id); + $morehtmlcenter = dolGetButtonTitle($langs->trans('SeeAll'), '', 'fa fa-list-alt imgforviewmode', DOL_URL_ROOT.'/asset/agenda.php?id='.$object->id); // List of actions on element include_once DOL_DOCUMENT_ROOT.'/core/class/html.formactions.class.php'; $formactions = new FormActions($db); - $somethingshown = $formactions->showactions($object, $object->element, $socid, 1, '', $MAXEVENT, '', $morehtmlright); + $somethingshown = $formactions->showactions($object, $object->element, 0, 1, '', $MAXEVENT, '', $morehtmlright); print '
    '; } -} + //Select mail models is same action as presend + if (GETPOST('modelselected')) { + $action = 'presend'; + } + + // Presend form + $modelmail = 'asset'; + $defaulttopic = 'InformationMessage'; + $diroutput = $conf->asset->dir_output; + $trackid = 'asset'.$object->id; + + include DOL_DOCUMENT_ROOT.'/core/tpl/card_presend.tpl.php'; +} // End of page llxFooter(); diff --git a/htdocs/asset/class/asset.class.php b/htdocs/asset/class/asset.class.php index e5ec21bfa6d..19c15839231 100644 --- a/htdocs/asset/class/asset.class.php +++ b/htdocs/asset/class/asset.class.php @@ -1,6 +1,6 @@ - * Copyright (C) 2018 Alexandre Spangaro +/* Copyright (C) 2017 Laurent Destailleur + * Copyright (C) 2018 Alexandre Spangaro * * 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 @@ -19,7 +19,7 @@ /** * \file asset/class/asset.class.php * \ingroup asset - * \brief This file is a CRUD class file for asset (Create/Read/Update/Delete) + * \brief This file is a CRUD class file for Asset (Create/Read/Update/Delete) */ require_once DOL_DOCUMENT_ROOT.'/core/class/commonobject.class.php'; @@ -30,22 +30,28 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/commonobject.class.php'; class Asset extends CommonObject { /** - * @var string ID to identify managed object + * @var string ID of module. + */ + public $module = 'asset'; + + /** + * @var string ID to identify managed object. */ public $element = 'asset'; /** - * @var string Name of table without prefix where object is stored + * @var string Name of table without prefix where object is stored. This is also the key used for extrafields management. */ public $table_element = 'asset'; /** - * @var int Does module support multicompany module ? 0=No test on entity, 1=Test with field entity, 2=Test with link by societe + * @var int Does this object support multicompany module ? + * 0=No test on entity, 1=Test with field entity, 'field@table'=Test with link by field@table */ - public $ismultientitymanaged = 0; + public $ismultientitymanaged = 1; /** - * @var int Does asset support extrafields ? 0=No, 1=Yes + * @var int Does object support extrafields ? 0=No, 1=Yes */ public $isextrafieldmanaged = 1; @@ -54,111 +60,124 @@ class Asset extends CommonObject */ public $picto = 'asset'; - - const STATUS_DRAFT = 0; - const STATUS_VALIDATED = 1; - const STATUS_CANCELED = 9; - + const STATUS_DRAFT = 0; // In progress + const STATUS_DISPOSED = 9; // Disposed /** - * 'type' if the field format. + * 'type' field format ('integer', 'integer:ObjectClass:PathToClass[:AddCreateButtonOrNot[:Filter[:Sortfield]]]', 'sellist:TableName:LabelFieldName[:KeyFieldName[:KeyFieldParent[:Filter[:Sortfield]]]]', 'varchar(x)', 'double(24,8)', 'real', 'price', 'text', 'text:none', 'html', 'date', 'datetime', 'timestamp', 'duration', 'mail', 'phone', 'url', 'password') + * Note: Filter can be a string like "(t.ref:like:'SO-%') or (t.date_creation:<:'20160101') or (t.nature:is:NULL)" * 'label' the translation key. - * 'enabled' is a condition when the field must be managed. - * 'visible' says if field is visible in list (Examples: 0=Not visible, 1=Visible on list and create/update/view forms, 2=Visible on list only. Using a negative value means field is not shown by default on list but can be selected for viewing) + * 'picto' is code of a picto to show before value in forms + * 'enabled' is a condition when the field must be managed (Example: 1 or '$conf->global->MY_SETUP_PARAM) + * 'position' is the sort order of field. * 'notnull' is set to 1 if not null in database. Set to -1 if we must set data to null if empty ('' or 0). + * 'visible' says if field is visible in list (Examples: 0=Not visible, 1=Visible on list and create/update/view forms, 2=Visible on list only, 3=Visible on create/update/view form only (not list), 4=Visible on list and update/view form only (not create). 5=Visible on list and view only (not create/not update). Using a negative value means field is not shown by default on list but can be selected for viewing) + * 'noteditable' says if field is not editable (1 or 0) + * 'default' is a default value for creation (can still be overwrote by the Setup of Default Values if field is editable in creation form). Note: If default is set to '(PROV)' and field is 'ref', the default value will be set to '(PROVid)' where id is rowid when a new record is created. * 'index' if we want an index in database. * 'foreignkey'=>'tablename.field' if the field is a foreign key (it is recommanded to name the field fk_...). - * 'position' is the sort order of field. * 'searchall' is 1 if we want to search in this field when making a search from the quick search button. - * 'isameasure' must be set to 1 if you want to have a total on list for this field. Field type must be summable like integer or double(24,8). - * 'help' is a string visible as a tooltip on field + * 'isameasure' must be set to 1 or 2 if field can be used for measure. Field type must be summable like integer or double(24,8). Use 1 in most cases, or 2 if you don't want to see the column total into list (for example for percentage) + * 'css' and 'cssview' and 'csslist' is the CSS style to use on field. 'css' is used in creation and update. 'cssview' is used in view mode. 'csslist' is used for columns in lists. For example: 'css'=>'minwidth300 maxwidth500 widthcentpercentminusx', 'cssview'=>'wordbreak', 'csslist'=>'tdoverflowmax200' + * 'help' is a 'TranslationString' to use to show a tooltip on field. You can also use 'TranslationString:keyfortooltiponlick' for a tooltip on click. + * 'showoncombobox' if value of the field must be visible into the label of the combobox that list record + * 'disabled' is 1 if we want to have the field locked by a 'disabled' attribute. In most cases, this is never set into the definition of $fields into class, but is set dynamically by some part of code. + * 'arrayofkeyval' to set a list of values if type is a list of predefined values. For example: array("0"=>"Draft","1"=>"Active","-1"=>"Cancel"). Note that type can be 'integer' or 'varchar' + * 'autofocusoncreate' to have field having the focus on a create form. Only 1 field should have this property set to 1. * 'comment' is not used. You can store here any text of your choice. It is not used by application. - * 'default' is a default value for creation (can still be replaced by the global setup of default values) - * 'showoncombobox' if field must be shown into the label of combobox + * 'validate' is 1 if need to validate with $this->validateField() + * 'copytoclipboard' is 1 or 2 to allow to add a picto to copy value into clipboard (1=picto after label, 2=picto after value) + * + * Note: To have value dynamic, you can set value to 0 in definition and edit the value on the fly into the constructor. */ /** * @var array Array with all fields and their property. Do not use it as a static var. It may be modified by constructor. */ - public $fields = array( - 'rowid' => array('type'=>'integer', 'label'=>'TechnicalID', 'visible'=>-1, 'enabled'=>1, 'position'=>1, 'notnull'=>1, 'index'=>1, 'comment'=>"Id",), - 'ref' => array('type'=>'varchar(10)', 'label'=>'Ref', 'visible'=>1, 'enabled'=>1, 'position'=>10, 'notnull'=>1, 'index'=>1, 'searchall'=>1, 'comment'=>"Reference of object", 'showoncombobox'=>1), - 'entity' => array('type'=>'integer', 'label'=>'Entity', 'visible'=>0, 'enabled'=>1, 'position'=>20, 'notnull'=>1, 'index'=>1,), - 'label' => array('type'=>'varchar(255)', 'label'=>'Label', 'visible'=>1, 'enabled'=>1, 'position'=>30, 'notnull'=>-1, 'searchall'=>1), - 'fk_asset_type' => array('type'=>'integer:AssetType:asset/class/asset_type.class.php', 'label'=>'AssetsType', 'visible'=>1, 'enabled'=>1, 'position'=>35, 'notnull'=>1, 'index'=>1, 'searchall'=>1), - 'amount_ht' => array('type'=>'double(24,8)', 'label'=>'AmountHTShort', 'visible'=>1, 'enabled'=>1, 'position'=>40, 'notnull'=>-1, 'isameasure'=>'1', 'help'=>"Help text",), - 'amount_vat' => array('type'=>'double(24,8)', 'label'=>'AmountVAT', 'visible'=>1, 'enabled'=>1, 'position'=>41, 'notnull'=>-1, 'isameasure'=>'1', 'help'=>"Help text",), - 'description' => array('type'=>'text', 'label'=>'Description', 'visible'=>-1, 'enabled'=>1, 'position'=>90, 'notnull'=>-1,), - 'note_public' => array('type'=>'html', 'label'=>'NotePublic', 'visible'=>-1, 'enabled'=>1, 'position'=>91, 'notnull'=>-1,), - 'note_private' => array('type'=>'html', 'label'=>'NotePrivate', 'visible'=>-1, 'enabled'=>1, 'position'=>92, 'notnull'=>-1,), - 'date_creation' => array('type'=>'datetime', 'label'=>'DateCreation', 'visible'=>-2, 'enabled'=>1, 'position'=>500, 'notnull'=>1,), - 'tms' => array('type'=>'timestamp', 'label'=>'DateModification', 'visible'=>-2, 'enabled'=>1, 'position'=>501, 'notnull'=>1,), - 'fk_user_creat' => array('type'=>'integer', 'label'=>'UserAuthor', 'visible'=>-2, 'enabled'=>1, 'position'=>510, 'notnull'=>1,), - 'fk_user_modif' => array('type'=>'integer', 'label'=>'UserModif', 'visible'=>-2, 'enabled'=>1, 'position'=>511, 'notnull'=>-1,), - 'import_key' => array('type'=>'varchar(14)', 'label'=>'ImportId', 'visible'=>-2, 'enabled'=>1, 'position'=>1000, 'notnull'=>-1,), - 'status' => array('type'=>'integer', 'label'=>'Status', 'visible'=>1, 'enabled'=>1, 'position'=>1000, 'notnull'=>1, 'index'=>1, 'arrayofkeyval'=>array('0'=>'Draft', '1'=>'Active', '9'=>'Cancel')), + public $fields=array( + 'rowid' => array('type'=>'integer', 'label'=>'TechnicalID', 'enabled'=>'1', 'position'=>1, 'notnull'=>1, 'visible'=>0, 'noteditable'=>'1', 'index'=>1, 'css'=>'left', 'comment'=>"Id"), + 'ref' => array('type'=>'varchar(128)', 'label'=>'Ref', 'enabled'=>'1', 'position'=>20, 'notnull'=>1, 'visible'=>1, 'noteditable'=>'0', 'index'=>1, 'searchall'=>1, 'showoncombobox'=>'1', 'validate'=>'1', 'comment'=>"Reference of object"), + 'label' => array('type'=>'varchar(255)', 'label'=>'Label', 'enabled'=>'1', 'position'=>30, 'notnull'=>1, 'visible'=>1, 'searchall'=>1, 'css'=>'minwidth300', 'cssview'=>'wordbreak', 'showoncombobox'=>'2', 'validate'=>'1',), + 'fk_asset_model' => array('type'=>'integer:AssetModel:asset/class/assetmodel.class.php:1:status=1 AND entity IN (__SHARED_ENTITIES__)', 'label'=>'AssetModel', 'enabled'=>'1', 'position'=>40, 'notnull'=>0, 'visible'=>1, 'index'=>1, 'validate'=>'1',), + 'qty' => array('type'=>'real', 'label'=>'Qty', 'enabled'=>'1', 'position'=>50, 'notnull'=>1, 'visible'=>0, 'default'=>'1', 'isameasure'=>'1', 'css'=>'maxwidth75imp', 'validate'=>'1',), + 'acquisition_type' => array('type'=>'smallint', 'label'=>'AssetAcquisitionType', 'enabled'=>'1', 'position'=>60, 'notnull'=>1, 'visible'=>1, 'arrayofkeyval'=>array('0'=>'AssetAcquisitionTypeNew', '1'=>'AssetAcquisitionTypeOccasion'), 'validate'=>'1',), + 'asset_type' => array('type'=>'smallint', 'label'=>'AssetType', 'enabled'=>'1', 'position'=>70, 'notnull'=>1, 'visible'=>1, 'arrayofkeyval'=>array('0'=>'AssetTypeIntangible', '1'=>'AssetTypeTangible', '2'=>'AssetTypeInProgress', '3'=>'AssetTypeFinancial'), 'validate'=>'1',), + 'not_depreciated' => array('type'=>'boolean', 'label'=>'AssetNotDepreciated', 'enabled'=>'1', 'position'=>80, 'notnull'=>0, 'default'=>'0', 'visible'=>1, 'validate'=>'1',), + 'date_acquisition' => array('type'=>'date', 'label'=>'AssetDateAcquisition', 'enabled'=>'1', 'position'=>90, 'notnull'=>1, 'visible'=>1,), + 'date_start' => array('type'=>'date', 'label'=>'AssetDateStart', 'enabled'=>'1', 'position'=>100, 'notnull'=>0, 'visible'=>-1,), + 'acquisition_value_ht' => array('type'=>'price', 'label'=>'AssetAcquisitionValueHT', 'enabled'=>'1', 'position'=>110, 'notnull'=>1, 'visible'=>1, 'isameasure'=>'1', 'validate'=>'1',), + 'recovered_vat' => array('type'=>'price', 'label'=>'AssetRecoveredVAT', 'enabled'=>'1', 'position'=>120, 'notnull'=>0, 'visible'=>1, 'isameasure'=>'1', 'validate'=>'1',), + 'reversal_date' => array('type'=>'date', 'label'=>'AssetReversalDate', 'enabled'=>'1', 'position'=>130, 'notnull'=>0, 'visible'=>1,), + 'reversal_amount_ht' => array('type'=>'price', 'label'=>'AssetReversalAmountHT', 'enabled'=>'1', 'position'=>140, 'notnull'=>0, 'visible'=>1, 'isameasure'=>'1', 'validate'=>'1',), + 'disposal_date' => array('type'=>'date', 'label'=>'AssetDisposalDate', 'enabled'=>'1', 'position'=>200, 'notnull'=>0, 'visible'=>-2,), + 'disposal_amount_ht' => array('type'=>'price', 'label'=>'AssetDisposalAmount', 'enabled'=>'1', 'position'=>210, 'notnull'=>0, 'visible'=>-2, 'default'=>'0', 'isameasure'=>'1', 'validate'=>'1',), + 'fk_disposal_type' => array('type'=>'sellist:c_asset_disposal_type:label:rowid::active=1', 'label'=>'AssetDisposalType', 'enabled'=>'1', 'position'=>220, 'notnull'=>0, 'visible'=>-2, 'index'=>1, 'validate'=>'1',), + 'disposal_depreciated' => array('type'=>'boolean', 'label'=>'AssetDisposalDepreciated', 'enabled'=>'1', 'position'=>230, 'notnull'=>0, 'default'=>'0', 'visible'=>-2, 'validate'=>'1',), + 'disposal_subject_to_vat' => array('type'=>'boolean', 'label'=>'AssetDisposalSubjectToVat', 'enabled'=>'1', 'position'=>240, 'notnull'=>0, 'default'=>'0', 'visible'=>-2, 'validate'=>'1',), + 'note_public' => array('type'=>'html', 'label'=>'NotePublic', 'enabled'=>'1', 'position'=>300, 'notnull'=>0, 'visible'=>0, 'validate'=>'1',), + 'note_private' => array('type'=>'html', 'label'=>'NotePrivate', 'enabled'=>'1', 'position'=>301, 'notnull'=>0, 'visible'=>0, 'validate'=>'1',), + 'date_creation' => array('type'=>'datetime', 'label'=>'DateCreation', 'enabled'=>'1', 'position'=>500, 'notnull'=>1, 'visible'=>-2,), + 'tms' => array('type'=>'timestamp', 'label'=>'DateModification', 'enabled'=>'1', 'position'=>501, 'notnull'=>0, 'visible'=>-2,), + 'fk_user_creat' => array('type'=>'integer:User:user/class/user.class.php', 'label'=>'UserAuthor', 'enabled'=>'1', 'position'=>510, 'notnull'=>1, 'visible'=>-2, 'foreignkey'=>'user.rowid',), + 'fk_user_modif' => array('type'=>'integer:User:user/class/user.class.php', 'label'=>'UserModif', 'enabled'=>'1', 'position'=>511, 'notnull'=>-1, 'visible'=>-2,), + 'last_main_doc' => array('type'=>'varchar(255)', 'label'=>'LastMainDoc', 'enabled'=>'1', 'position'=>600, 'notnull'=>0, 'visible'=>0,), + 'import_key' => array('type'=>'varchar(14)', 'label'=>'ImportId', 'enabled'=>'1', 'position'=>1000, 'notnull'=>-1, 'visible'=>-2,), + 'model_pdf' => array('type'=>'varchar(255)', 'label'=>'Model pdf', 'enabled'=>'1', 'position'=>1010, 'notnull'=>-1, 'visible'=>0,), + 'status' => array('type'=>'smallint', 'label'=>'Status', 'enabled'=>'1', 'position'=>1000, 'notnull'=>1, 'default'=>'0', 'visible'=>2, 'index'=>1, 'arrayofkeyval'=>array('0'=>'Draft', '1'=>'Validated', '9'=>'Canceled'), 'validate'=>'1',), ); - - /** - * @var int ID - */ public $rowid; - - /** - * @var string Ref - */ public $ref; - - /** - * @var int Entity - */ - public $entity; - - /** - * @var string Asset label - */ public $label; - - public $amount; - - /** - * @var int Thirdparty ID - */ - public $fk_soc; - - /** - * @var string description - */ - public $description; - - /** - * @var integer|string date_creation - */ + public $fk_asset_model; + public $reversal_amount_ht; + public $acquisition_value_ht; + public $recovered_vat; + public $reversal_date; + public $date_acquisition; + public $date_start; + public $qty; + public $acquisition_type; + public $asset_type; + public $not_depreciated; + public $disposal_date; + public $disposal_amount_ht; + public $fk_disposal_type; + public $disposal_depreciated; + public $disposal_subject_to_vat; + public $note_public; + public $note_private; public $date_creation; - - public $tms; - - /** - * @var int ID - */ public $fk_user_creat; - - /** - * @var int ID - */ public $fk_user_modif; - - /** - * @var string import key - */ + public $last_main_doc; public $import_key; - - /** - * @var int Status - */ + public $model_pdf; public $status; + // /** + // * @var string Field with ID of parent key if this object has a parent + // */ + // public $fk_element = 'fk_asset'; + // /** + // * @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. + // * If name matches '@ClassNAme:FilePathClass;ParentFkFieldName' it will + // * call method deleteByParentField(parentId, ParentFkFieldName) to fetch and delete child object + // */ + // protected $childtablesoncascade = array('asset_assetdet'); + + /** + * @var AssetDepreciationOptions Used for computed fields of depreciation options class. + */ + public $asset_depreciation_options; + /** + * @var array List of depreciation lines for each mode (sort by depreciation date). + */ + public $depreciation_lines = array(); /** * Constructor @@ -167,16 +186,34 @@ class Asset extends CommonObject */ public function __construct(DoliDB $db) { - global $conf; + global $conf, $langs; $this->db = $db; - if (empty($conf->global->MAIN_SHOW_TECHNICAL_ID)) { + if (empty($conf->global->MAIN_SHOW_TECHNICAL_ID) && isset($this->fields['rowid'])) { $this->fields['rowid']['visible'] = 0; } - if (empty($conf->multicompany->enabled)) { + if (empty($conf->multicompany->enabled) && isset($this->fields['entity'])) { $this->fields['entity']['enabled'] = 0; } + + // Unset fields that are disabled + foreach ($this->fields as $key => $val) { + if (isset($val['enabled']) && empty($val['enabled'])) { + unset($this->fields[$key]); + } + } + + // Translate some data of arrayofkeyval + if (is_object($langs)) { + foreach ($this->fields as $key => $val) { + if (!empty($val['arrayofkeyval']) && is_array($val['arrayofkeyval'])) { + foreach ($val['arrayofkeyval'] as $key2 => $val2) { + $this->fields[$key]['arrayofkeyval'][$key2] = $langs->trans($val2); + } + } + } + } } /** @@ -188,11 +225,27 @@ class Asset extends CommonObject */ public function create(User $user, $notrigger = false) { - return $this->createCommon($user, $notrigger); + if (!isset($this->date_start) || $this->date_start === "") $this->date_start = $this->date_acquisition; + + $this->db->begin(); + + $result = $result_create = $this->createCommon($user, $notrigger); + if ($result > 0 && $this->fk_asset_model > 0) $result = $this->setDataFromAssetModel($user, $notrigger); + if ($result > 0) { + if ($this->supplier_invoice_id > 0) $this->add_object_linked('invoice_supplier', $this->supplier_invoice_id); + } + + if ($result < 0) { + $this->db->rollback(); + } else { + $this->db->commit(); + } + + return $result > 0 ? $result_create : $result; } /** - * Clone and object into another one + * Clone an object into another one * * @param User $user User that creates * @param int $fromid Id of object to clone @@ -200,45 +253,95 @@ class Asset extends CommonObject */ public function createFromClone(User $user, $fromid) { - global $hookmanager, $langs; + global $langs, $extrafields; $error = 0; dol_syslog(__METHOD__, LOG_DEBUG); - $object = new self($this->db); - - $this->db->begin(); - - // Load source object - $object->fetchCommon($fromid); - // Reset some properties - unset($object->id); - unset($object->fk_user_creat); - unset($object->import_key); - - // Clear fields - $object->ref = "copy_of_".$object->ref; - $object->title = $langs->trans("CopyOf")." ".$object->title; - - // Create clone - $object->context['createfromclone'] = 'createfromclone'; - $result = $object->createCommon($user); - if ($result < 0) { - $error++; - $this->error = $object->error; - $this->errors = $object->errors; - } - - unset($object->context['createfromclone']); - - // End - if (!$error) { - $this->db->commit(); - return $object; - } else { - $this->db->rollback(); - return -1; - } + // $object = new self($this->db); + // + // $this->db->begin(); + // + // // Load source object + // $result = $object->fetchCommon($fromid); + // if ($result > 0 && !empty($object->table_element_line)) { + // $object->fetchLines(); + // } + // + // // get lines so they will be clone + // //foreach($this->lines as $line) + // // $line->fetch_optionals(); + // + // // Reset some properties + // unset($object->id); + // unset($object->fk_user_creat); + // unset($object->import_key); + // + // // Clear fields + // if (property_exists($object, 'ref')) { + // $object->ref = empty($this->fields['ref']['default']) ? "Copy_Of_".$object->ref : $this->fields['ref']['default']; + // } + // if (property_exists($object, 'label')) { + // $object->label = empty($this->fields['label']['default']) ? $langs->trans("CopyOf")." ".$object->label : $this->fields['label']['default']; + // } + // if (property_exists($object, 'status')) { + // $object->status = self::STATUS_DRAFT; + // } + // if (property_exists($object, 'date_creation')) { + // $object->date_creation = dol_now(); + // } + // if (property_exists($object, 'date_modification')) { + // $object->date_modification = null; + // } + // // ... + // // Clear extrafields that are unique + // if (is_array($object->array_options) && count($object->array_options) > 0) { + // $extrafields->fetch_name_optionals_label($this->table_element); + // foreach ($object->array_options as $key => $option) { + // $shortkey = preg_replace('/options_/', '', $key); + // if (!empty($extrafields->attributes[$this->table_element]['unique'][$shortkey])) { + // //var_dump($key); var_dump($clonedObj->array_options[$key]); exit; + // unset($object->array_options[$key]); + // } + // } + // } + // + // // Create clone + // $object->context['createfromclone'] = 'createfromclone'; + // $result = $object->createCommon($user); + // if ($result < 0) { + // $error++; + // $this->error = $object->error; + // $this->errors = $object->errors; + // } + // + // if (!$error) { + // // copy internal contacts + // if ($this->copy_linked_contact($object, 'internal') < 0) { + // $error++; + // } + // } + // + // if (!$error) { + // // copy external contacts if same company + // if (property_exists($this, 'fk_soc') && $this->fk_soc == $object->socid) { + // if ($this->copy_linked_contact($object, 'external') < 0) { + // $error++; + // } + // } + // } + // + // unset($object->context['createfromclone']); + // + // // End + // if (!$error) { + // $this->db->commit(); + // return $object; + // } else { + // $this->db->rollback(); + // return -1; + // } + return -1; } /** @@ -251,7 +354,21 @@ class Asset extends CommonObject public function fetch($id, $ref = null) { $result = $this->fetchCommon($id, $ref); - //if ($result > 0 && ! empty($this->table_element_line)) $this->fetchLines(); + if ($result > 0) { + if (!empty($this->table_element_line)) $this->fetchLines(); + + $res = $this->hasDepreciationLinesInBookkeeping(); + if ($res < 0) { + return -1; + } elseif ($res > 0) { + $this->fields['date_acquisition']['noteditable'] = '1'; + $this->fields['date_start']['noteditable'] = '1'; + $this->fields['acquisition_value_ht']['noteditable'] = '1'; + $this->fields['recovered_vat']['noteditable'] = '1'; + $this->fields['reversal_date']['noteditable'] = '1'; + $this->fields['reversal_amount_ht']['noteditable'] = '1'; + } + } return $result; } @@ -260,14 +377,93 @@ class Asset extends CommonObject * * @return int <0 if KO, 0 if not found, >0 if OK */ - /*public function fetchLines() + public function fetchLines() { - $this->lines=array(); + $this->lines = array(); - // Load lines with object AssetsLine + return 1; + } - return count($this->lines)?1:0; - }*/ + + /** + * Load list of objects in memory from the database. + * + * @param string $sortorder Sort Order + * @param string $sortfield Sort field + * @param int $limit limit + * @param int $offset Offset + * @param array $filter Filter array. Example array('field'=>'valueforlike', 'customurl'=>...) + * @param string $filtermode Filter mode (AND or OR) + * @return array|int int <0 if KO, array of pages if OK + */ + public function fetchAll($sortorder = '', $sortfield = '', $limit = 0, $offset = 0, array $filter = array(), $filtermode = 'AND') + { + global $conf; + + dol_syslog(__METHOD__, LOG_DEBUG); + + $records = array(); + + $sql = "SELECT "; + $sql .= $this->getFieldList('t'); + $sql .= " FROM ".MAIN_DB_PREFIX.$this->table_element." as t"; + if (isset($this->ismultientitymanaged) && $this->ismultientitymanaged == 1) { + $sql .= " WHERE t.entity IN (".getEntity($this->table_element).")"; + } else { + $sql .= " WHERE 1 = 1"; + } + // Manage filter + $sqlwhere = array(); + if (count($filter) > 0) { + foreach ($filter as $key => $value) { + if ($key == 't.rowid') { + $sqlwhere[] = $key." = ".((int) $value); + } elseif (in_array($this->fields[$key]['type'], array('date', 'datetime', 'timestamp'))) { + $sqlwhere[] = $key." = '".$this->db->idate($value)."'"; + } elseif ($key == 'customsql') { + $sqlwhere[] = $value; + } elseif (strpos($value, '%') === false) { + $sqlwhere[] = $key." IN (".$this->db->sanitize($this->db->escape($value)).")"; + } else { + $sqlwhere[] = $key." LIKE '%".$this->db->escape($value)."%'"; + } + } + } + if (count($sqlwhere) > 0) { + $sql .= " AND (".implode(" ".$filtermode." ", $sqlwhere).")"; + } + + if (!empty($sortfield)) { + $sql .= $this->db->order($sortfield, $sortorder); + } + if (!empty($limit)) { + $sql .= $this->db->plimit($limit, $offset); + } + + $resql = $this->db->query($sql); + if ($resql) { + $num = $this->db->num_rows($resql); + $i = 0; + while ($i < ($limit ? min($limit, $num) : $num)) { + $obj = $this->db->fetch_object($resql); + + $record = new self($this->db); + $record->setVarsFromFetchObj($obj); + + $records[$record->id] = $record; + + $i++; + } + $this->db->free($resql); + + return $records; + } else { + $this->errors[] = 'Error '.$this->db->lasterror(); + dol_syslog(__METHOD__.' '.join(',', $this->errors), LOG_ERR); + + return -1; + } + } /** * Update object into database @@ -278,7 +474,32 @@ class Asset extends CommonObject */ public function update(User $user, $notrigger = false) { - return $this->updateCommon($user, $notrigger); + if (!isset($this->date_start) || $this->date_start === "") $this->date_start = $this->date_acquisition; + + $this->db->begin(); + + $result = $this->updateCommon($user, $notrigger); + if ($result > 0 && $this->fk_asset_model > 0 && $this->fk_asset_model != $this->oldcopy->fk_asset_model) { + $result = $this->setDataFromAssetModel($user, $notrigger); + } + if ($result > 0 && ( + $this->date_start != $this->oldcopy->date_start || + $this->acquisition_value_ht != $this->oldcopy->acquisition_value_ht || + $this->reversal_date != $this->oldcopy->reversal_date || + $this->reversal_amount_ht != $this->oldcopy->reversal_amount_ht || + ($this->fk_asset_model > 0 && $this->fk_asset_model != $this->oldcopy->fk_asset_model) + ) + ) { + $result = $this->calculationDepreciation(); + } + + if ($result < 0) { + $this->db->rollback(); + } else { + $this->db->commit(); + } + + return $result; } /** @@ -291,21 +512,760 @@ class Asset extends CommonObject public function delete(User $user, $notrigger = false) { return $this->deleteCommon($user, $notrigger); + //return $this->deleteCommon($user, $notrigger, 1); + } + + /** + * Set asset model + * + * @param User $user User that creates + * @param bool $notrigger false=launch triggers after, true=disable triggers + * @return int <0 if KO, Id of created object if OK + */ + public function setDataFromAssetModel(User $user, $notrigger = false) + { + global $langs; + $langs->load('assets'); + + // Clean parameters + $this->id = $this->id > 0 ? $this->id : 0; + $this->fk_asset_model = $this->fk_asset_model > 0 ? $this->fk_asset_model : 0; + + // Check parameters + $error = 0; + if (empty($this->id)) { + $this->errors[] = $langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("Asset") . ' (' . $langs->transnoentitiesnoconv("TechnicalID") . ')'); + $error++; + } + if (empty($this->fk_asset_model)) { + $this->errors[] = $langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("AssetModel") . ' (' . $langs->transnoentitiesnoconv("TechnicalID") . ')'); + $error++; + } + if ($error) { + return -1; + } + + $this->db->begin(); + + // Get depreciation options + //--------------------------- + require_once DOL_DOCUMENT_ROOT . '/asset/class/assetdepreciationoptions.class.php'; + $options_model = new AssetDepreciationOptions($this->db); + $result = $options_model->fetchDeprecationOptions(0, $this->fk_asset_model); + if ($result < 0) { + $this->error = $options_model->error; + $this->errors = $options_model->errors; + $error++; + } elseif ($result > 0) { + $options = new AssetDepreciationOptions($this->db); + $result = $options->fetchDeprecationOptions($this->id); + if ($result < 0) { + $this->error = $options->error; + $this->errors = $options->errors; + $error++; + } + + if (!$error) { + foreach ($options_model->deprecation_options as $mode_key => $fields) { + foreach ($fields as $field_key => $value) { + $options->deprecation_options[$mode_key][$field_key] = $value; + } + } + + $result = $options->updateDeprecationOptions($user, $this->id, 0, $notrigger); + if ($result < 0) { + $this->error = $options->error; + $this->errors = $options->errors; + $error++; + } + } + } + + // Get accountancy codes + //--------------------------- + if (!$error) { + require_once DOL_DOCUMENT_ROOT . '/asset/class/assetaccountancycodes.class.php'; + $accountancy_codes_model = new AssetAccountancyCodes($this->db); + $result = $accountancy_codes_model->fetchAccountancyCodes(0, $this->fk_asset_model); + if ($result < 0) { + $this->error = $accountancy_codes_model->error; + $this->errors = $accountancy_codes_model->errors; + $error++; + } elseif ($result > 0) { + $accountancy_codes = new AssetAccountancyCodes($this->db); + $result = $accountancy_codes->fetchAccountancyCodes($this->id); + if ($result < 0) { + $this->error = $accountancy_codes->error; + $this->errors = $accountancy_codes->errors; + $error++; + } + + if (!$error) { + foreach ($accountancy_codes_model->accountancy_codes as $mode_key => $fields) { + foreach ($fields as $field_key => $value) { + $accountancy_codes->accountancy_codes[$mode_key][$field_key] = $value; + } + } + + $result = $accountancy_codes->updateAccountancyCodes($user, $this->id, 0, $notrigger); + if ($result < 0) { + $this->error = $accountancy_codes->error; + $this->errors = $accountancy_codes->errors; + $error++; + } + } + } + } + + if ($error) { + $this->db->rollback(); + return -1; + } else { + $this->db->commit(); + return 1; + } + } + + /** + * Fetch depreciation lines for each mode in $this->depreciation_lines (sort by depreciation date) + * + * @return int <0 if KO, Id of created object if OK + */ + public function fetchDepreciationLines() + { + global $langs; + $langs->load('assets'); + $this->depreciation_lines = array(); + + // Clean parameters + $this->id = $this->id > 0 ? $this->id : 0; + + // Check parameters + $error = 0; + if (empty($this->id)) { + $this->errors[] = $langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("Asset") . ' (' . $langs->transnoentitiesnoconv("TechnicalID") . ')'); + $error++; + } + if ($error) { + return -1; + } + + $sql = "WITH in_accounting_bookkeeping(fk_docdet) AS ("; + $sql .= " SELECT DISTINCT fk_docdet"; + $sql .= " FROM " . MAIN_DB_PREFIX . "accounting_bookkeeping"; + $sql .= " WHERE doc_type = 'asset'"; + $sql .= ")"; + $sql .= "SELECT ad.rowid, ad.depreciation_mode, ad.ref, ad.depreciation_date, ad.depreciation_ht, ad.cumulative_depreciation_ht"; + $sql .= ", " . $this->db->ifsql('iab.fk_docdet IS NOT NULL', 1, 0) . " AS bookkeeping"; + $sql .= " FROM " . MAIN_DB_PREFIX . "asset_depreciation AS ad"; + $sql .= " LEFT JOIN in_accounting_bookkeeping as iab ON iab.fk_docdet = ad.rowid"; + $sql .= " WHERE ad.fk_asset = " . (int) $this->id; + $sql .= " ORDER BY ad.depreciation_date ASC"; + + $resql = $this->db->query($sql); + if (!$resql) { + $this->errors[] = $langs->trans('AssetErrorFetchDepreciationLines') . ': ' . $this->db->lasterror(); + return -1; + } + + while ($obj = $this->db->fetch_object($resql)) { + if (!isset($this->depreciation_lines[$obj->depreciation_mode])) $this->depreciation_lines[$obj->depreciation_mode] = array(); + $this->depreciation_lines[$obj->depreciation_mode][] = array( + 'id' => $obj->rowid, + 'ref' => $obj->ref, + 'depreciation_date' => $this->db->jdate($obj->depreciation_date), + 'depreciation_ht' => $obj->depreciation_ht, + 'cumulative_depreciation_ht' => $obj->cumulative_depreciation_ht, + 'bookkeeping' => $obj->bookkeeping, + ); + } + + return 1; + } + + /** + * If has depreciation lines in bookkeeping + * + * @return int <0 if KO, 0 if NO, 1 if Yes + */ + public function hasDepreciationLinesInBookkeeping() + { + global $langs; + $langs->load('assets'); + + // Clean parameters + $this->id = $this->id > 0 ? $this->id : 0; + + // Check parameters + $error = 0; + if (empty($this->id)) { + $this->errors[] = $langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("Asset") . ' (' . $langs->transnoentitiesnoconv("TechnicalID") . ')'); + $error++; + } + if ($error) { + return -1; + } + + $sql = "WITH in_accounting_bookkeeping(fk_docdet) AS ("; + $sql .= " SELECT DISTINCT fk_docdet"; + $sql .= " FROM " . MAIN_DB_PREFIX . "accounting_bookkeeping"; + $sql .= " WHERE doc_type = 'asset'"; + $sql .= ")"; + $sql .= "SELECT COUNT(*) AS has_bookkeeping"; + $sql .= " FROM " . MAIN_DB_PREFIX . "asset_depreciation AS ad"; + $sql .= " LEFT JOIN in_accounting_bookkeeping as iab ON iab.fk_docdet = ad.rowid"; + $sql .= " WHERE ad.fk_asset = " . (int) $this->id; + $sql .= " AND iab.fk_docdet IS NOT NULL"; + + $resql = $this->db->query($sql); + if (!$resql) { + $this->errors[] = $langs->trans('AssetErrorFetchDepreciationLines') . ': ' . $this->db->lasterror(); + return -1; + } + + if ($obj = $this->db->fetch_object($resql)) { + return $obj->has_bookkeeping > 0 ? 1 : 0; + } + + return 0; + } + + /** + * Add depreciation line for a mode + * + * @param string $mode Depreciation mode (economic, accelerated_depreciation, ...) + * @param string $ref Ref line + * @param int $depreciation_date Depreciation date + * @param double $depreciation_ht Depreciation amount HT + * @param double $cumulative_depreciation_ht Depreciation cumulative amount HT + * @param string $accountancy_code_debit Accountancy code Debit + * @param string $accountancy_code_credit Accountancy code Credit + * @return int <0 if KO, Id of created line if OK + */ + public function addDepreciationLine($mode, $ref, $depreciation_date, $depreciation_ht, $cumulative_depreciation_ht, $accountancy_code_debit, $accountancy_code_credit) + { + global $langs; + $langs->load('assets'); + + // Clean parameters + $this->id = $this->id > 0 ? $this->id : 0; + $mode = strtolower(trim($mode)); + $ref = trim($ref); + $accountancy_code_debit = trim($accountancy_code_debit); + $accountancy_code_credit = trim($accountancy_code_credit); + + // Check parameters + $error = 0; + if (empty($this->id)) { + $this->errors[] = $langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("Asset") . ' (' . $langs->transnoentitiesnoconv("TechnicalID") . ')'); + $error++; + } + if ($error) { + return -1; + } + + $sql = "INSERT INTO " . MAIN_DB_PREFIX . "asset_depreciation(fk_asset, depreciation_mode, ref, depreciation_date, depreciation_ht, cumulative_depreciation_ht, accountancy_code_debit, accountancy_code_credit)"; + $sql .= " VALUES ( "; + $sql .= " " . (int) $this->id; + $sql .= ", '" . $this->db->escape($mode) . "'"; + $sql .= ", '" . $this->db->escape($ref) . "'"; + $sql .= ", '" . $this->db->idate($depreciation_date) . "'"; + $sql .= ", " . (double) $depreciation_ht; + $sql .= ", " . (double) $cumulative_depreciation_ht; + $sql .= ", '" . $this->db->escape($accountancy_code_debit) . "'"; + $sql .= ", '" . $this->db->escape($accountancy_code_credit) . "'"; + $sql .= ")"; + + $resql = $this->db->query($sql); + if (!$resql) { + $this->errors[] = $langs->trans('AssetErrorAddDepreciationLine') . ': ' . $this->db->lasterror(); + return -1; + } + + return 1; + } + + /** + * Calculation depreciation lines (reversal and future) for each mode + * + * @return int <0 if KO, Id of created object if OK + */ + public function calculationDepreciation() + { + global $conf, $langs; + $langs->load('assets'); + + // Clean parameters + $this->id = $this->id > 0 ? $this->id : 0; + + // Check parameters + $error = 0; + if (empty($this->id)) { + $this->errors[] = $langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("Asset") . ' (' . $langs->transnoentitiesnoconv("TechnicalID") . ')'); + $error++; + } + if ($error) { + return -1; + } + + // Get depreciation options + //--------------------------- + require_once DOL_DOCUMENT_ROOT . '/asset/class/assetdepreciationoptions.class.php'; + $options = new AssetDepreciationOptions($this->db); + $result = $options->fetchDeprecationOptions($this->id); + if ($result < 0) { + $this->error = $options->error; + $this->errors = $options->errors; + return -1; + } + + // Get accountancy codes + //--------------------------- + require_once DOL_DOCUMENT_ROOT . '/asset/class/assetaccountancycodes.class.php'; + $accountancy_codes = new AssetAccountancyCodes($this->db); + $result = $accountancy_codes->fetchAccountancyCodes($this->id); + if ($result < 0) { + $this->error = $accountancy_codes->error; + $this->errors = $accountancy_codes->errors; + return -1; + } + + $this->db->begin(); + + // Delete old lines + $modes = array(); + foreach ($options->deprecation_options as $mode_key => $fields) { + $modes[$mode_key] = $this->db->escape($mode_key); + } + $sql = "DELETE FROM " . MAIN_DB_PREFIX . "asset_depreciation"; + $sql .= " WHERE fk_asset = " . (int) $this->id; + $sql .= " AND depreciation_mode NOT IN ('" . $this->db->sanitize(implode("', '", $modes)) . "')"; + + $resql = $this->db->query($sql); + if (!$resql) { + $this->errors[] = $langs->trans('AssetErrorClearDepreciationLines') . ': ' . $this->db->lasterror(); + $error++; + } + + if (!$error) { + // Get fiscal period + require_once DOL_DOCUMENT_ROOT . '/core/lib/date.lib.php'; + require_once DOL_DOCUMENT_ROOT . '/core/lib/accounting.lib.php'; + $dates = getDefaultDatesForTransfer(); + $init_fiscal_period_start = $dates['date_start']; + $init_fiscal_period_end = $dates['date_end']; + if (empty($init_fiscal_period_start) || empty($init_fiscal_period_end)) { + $pastmonthyear = $dates['pastmonthyear']; + $pastmonth = $dates['pastmonth']; + $init_fiscal_period_start = dol_get_first_day($pastmonthyear, $pastmonth, false); + $init_fiscal_period_end = dol_get_last_day($pastmonthyear, $pastmonth, false); + } + + foreach ($options->deprecation_options as $mode_key => $fields) { + // Get last depreciation lines save in bookkeeping + //----------------------------------------------------- + $sql = "WITH in_accounting_bookkeeping(fk_docdet) AS ("; + $sql .= " SELECT fk_docdet"; + $sql .= " FROM " . MAIN_DB_PREFIX . "accounting_bookkeeping"; + $sql .= " WHERE doc_type = 'asset'"; + $sql .= ")"; + $sql .= "SELECT ad.depreciation_date, ad.cumulative_depreciation_ht"; + $sql .= " FROM " . MAIN_DB_PREFIX . "asset_depreciation AS ad"; + $sql .= " LEFT JOIN in_accounting_bookkeeping as iab ON iab.fk_docdet = ad.rowid"; + $sql .= " WHERE ad.fk_asset = " . (int) $this->id; + $sql .= " AND ad.depreciation_mode = '" . $this->db->escape($mode_key) . "'"; + $sql .= " AND iab.fk_docdet IS NOT NULL"; + $sql .= " ORDER BY ad.depreciation_date DESC"; + $sql .= " LIMIT 1"; + $resql = $this->db->query($sql); + if (!$resql) { + $this->errors[] = $langs->trans('AssetErrorFetchMaxDepreciationDateForMode', $mode_key) . ': ' . $this->db->lasterror(); + $error++; + break; + } + $last_depreciation_date = ''; + $last_cumulative_depreciation_ht = $this->reversal_amount_ht; + if ($obj = $this->db->fetch_object($resql)) { + $last_depreciation_date = $this->db->jdate($obj->depreciation_date); + $last_cumulative_depreciation_ht = $obj->cumulative_depreciation_ht; + } + + // Set last cumulative depreciation + $sql = "UPDATE " . MAIN_DB_PREFIX . $options->deprecation_options_fields[$mode_key]['table']; + $sql .= " SET total_amount_last_depreciation_ht = " . (empty($last_cumulative_depreciation_ht) ? 0 : $last_cumulative_depreciation_ht); + $sql .= " WHERE fk_asset = " . (int) $this->id; + $resql = $this->db->query($sql); + if (!$resql) { + $this->errors[] = $langs->trans('AssetErrorSetLastCumulativeDepreciation') . ': ' . $this->db->lasterror(); + $error++; + break; + } + + // Delete old lines + $sql = "DELETE " . MAIN_DB_PREFIX . "asset_depreciation FROM " . MAIN_DB_PREFIX . "asset_depreciation"; + $sql .= " LEFT JOIN " . MAIN_DB_PREFIX . "accounting_bookkeeping as ab ON ab.doc_type = 'asset' AND ab.fk_docdet = " . MAIN_DB_PREFIX . "asset_depreciation.rowid"; + $sql .= " WHERE " . MAIN_DB_PREFIX . "asset_depreciation.fk_asset = " . (int) $this->id; + $sql .= " AND " . MAIN_DB_PREFIX . "asset_depreciation.depreciation_mode = '" . $this->db->escape($mode_key) . "'"; + $sql .= " AND ab.fk_docdet IS NULL"; + if ($last_depreciation_date !== "") $sql .= " AND " . MAIN_DB_PREFIX . "asset_depreciation.ref != ''"; + $resql = $this->db->query($sql); + if (!$resql) { + $this->errors[] = $langs->trans('AssetErrorClearDepreciationLines') . ': ' . $this->db->lasterror(); + $error++; + break; + } + + // Get depreciation period + $depreciation_date_start = $this->date_start > $this->date_acquisition ? $this->date_start : $this->date_acquisition; + $depreciation_date_end = dol_time_plus_duree($depreciation_date_start, $fields['duration'], $fields['duration_type'] == 1 ? 'm' : ($fields['duration_type'] == 2 ? 'd' : 'y')); + $depreciation_amount = $fields['amount_base_depreciation_ht']; + if ($fields['duration_type'] == 2) { // Daily + $fiscal_period_start = $depreciation_date_start; + $fiscal_period_end = $depreciation_date_start; + } elseif ($fields['duration_type'] == 1) { // Monthly + $date_temp = dol_getdate($depreciation_date_start); + $fiscal_period_start = dol_get_first_day($date_temp['year'], $date_temp['mon'], false); + $fiscal_period_end = dol_get_last_day($date_temp['year'], $date_temp['mon'], false); + } else { // Annually + $fiscal_period_start = $init_fiscal_period_start; + $fiscal_period_end = $init_fiscal_period_end; + } + $cumulative_depreciation_ht = $last_cumulative_depreciation_ht; + $depreciation_period_amount = $depreciation_amount - $this->reversal_amount_ht; + $start_date = $depreciation_date_start; + $disposal_date = isset($this->disposal_date) && $this->disposal_date !== "" ? $this->disposal_date : ""; + $finish_date = $disposal_date !== "" ? $disposal_date : $depreciation_date_end; + $accountancy_code_depreciation_debit_key = $accountancy_codes->accountancy_codes_fields[$mode_key]['depreciation_debit']; + $accountancy_code_depreciation_debit = $accountancy_codes->accountancy_codes[$mode_key][$accountancy_code_depreciation_debit_key]; + $accountancy_code_depreciation_credit_key = $accountancy_codes->accountancy_codes_fields[$mode_key]['depreciation_credit']; + $accountancy_code_credit = $accountancy_codes->accountancy_codes[$mode_key][$accountancy_code_depreciation_credit_key]; + + // Reversal depreciation line + //----------------------------------------------------- + if ($last_depreciation_date === "" && ($depreciation_date_start < $fiscal_period_start || is_numeric($this->reversal_date))) { + if (is_numeric($this->reversal_date)) { + if ($this->reversal_date < $fiscal_period_start) { + $this->errors[] = $langs->trans('AssetErrorReversalDateNotGreaterThanCurrentBeginFiscalDateForMode', $mode_key); + $error++; + break; + } + + if (empty($this->reversal_amount_ht)) { + $this->errors[] = $langs->trans('AssetErrorReversalAmountNotProvidedForMode', $mode_key); + $error++; + break; + } + + $start_date = $this->reversal_date; + $result = $this->addDepreciationLine($mode_key, '', $start_date, $this->reversal_amount_ht, $this->reversal_amount_ht, $accountancy_code_depreciation_debit, $accountancy_code_credit); + if ($result < 0) { + $error++; + break; + } + } else { + $this->errors[] = $langs->trans('AssetErrorReversalDateNotProvidedForMode', $mode_key); + $error++; + break; + } + } + + // futures depreciation lines + //----------------------------------------------------- + $nb_days_in_year = !empty($conf->global->ASSET_DEPRECIATION_DURATION_PER_YEAR) ? $conf->global->ASSET_DEPRECIATION_DURATION_PER_YEAR : 365; + $nb_days_in_month = !empty($conf->global->ASSET_DEPRECIATION_DURATION_PER_MONTH) ? $conf->global->ASSET_DEPRECIATION_DURATION_PER_MONTH : 30; + $period_amount = (double) price2num($depreciation_period_amount / $fields['duration'], 'MT'); + $first_period_found = false; + $first_period_date = isset($begin_period) && $begin_period > $fiscal_period_start ? $begin_period : $fiscal_period_start; + + $ref_date_format = "%Y" . ($fields['duration_type'] == 1 || $fields['duration_type'] == 2 ? '-%m' : '') . ($fields['duration_type'] == 2 ? '-%d' : ''); + + // Loop security + $idx_loop = 0; + $max_loop = $fields['duration'] + 2; + do { + // Loop security + $idx_loop++; + if ($idx_loop > $max_loop) break; + + if ($last_depreciation_date < $fiscal_period_end && ($first_period_date <= $start_date || $first_period_found)) { + // Disposal not depreciated + if ($fiscal_period_start <= $disposal_date && $disposal_date <= $fiscal_period_end && empty($this->disposal_depreciated)) { + break; + } + + $first_period_found = true; + + $period_begin = dol_print_date($fiscal_period_start, $ref_date_format); + $period_end = dol_print_date($fiscal_period_end, $ref_date_format); + $ref = $period_begin . ($period_begin != $period_end ? ' - ' . $period_end : ''); + if ($fiscal_period_start <= $disposal_date && $disposal_date <= $fiscal_period_end) { + $ref .= ' - ' . $langs->transnoentitiesnoconv('AssetDisposal'); + } + + $begin_date = $fiscal_period_start < $start_date && $start_date <= $fiscal_period_end ? $start_date : $fiscal_period_start; + $end_date = $fiscal_period_start < $finish_date && $finish_date <= $fiscal_period_end ? $finish_date : $fiscal_period_end; + if ($fields['duration_type'] == 2) { // Daily + $depreciation_ht = $period_amount; + } elseif ($fields['duration_type'] == 1) { // Monthly + $nb_days = min($nb_days_in_month, num_between_day($begin_date, $end_date, 1)); + if ($nb_days >= 28) { + $date_temp = dol_getdate($begin_date); + if ($date_temp['mon'] == 2) { + $nb_days = 30; + } + } + $depreciation_ht = (double) price2num($period_amount * $nb_days / $nb_days_in_month, 'MT'); + } else { // Annually + $nb_days = min($nb_days_in_year, num_between_day($begin_date, $end_date, 1)); + $depreciation_ht = (double) price2num($period_amount * $nb_days / $nb_days_in_year, 'MT'); + } + + if ($fiscal_period_start <= $depreciation_date_end && $depreciation_date_end <= $fiscal_period_end) { // last period + $depreciation_ht = (double) price2num($depreciation_amount - $cumulative_depreciation_ht, 'MT'); + $cumulative_depreciation_ht = $depreciation_amount; + } else { + $cumulative_depreciation_ht += $depreciation_ht; + } + + $result = $this->addDepreciationLine($mode_key, $ref, $fiscal_period_end, $depreciation_ht, $cumulative_depreciation_ht, $accountancy_code_depreciation_debit, $accountancy_code_credit); + if ($result < 0) { + $error++; + break; + } + } + + // Next fiscal period (+1 day/month/year) + $fiscal_period_start = dol_time_plus_duree($fiscal_period_end, 1, 'd'); + if ($fields['duration_type'] == 2) { // Daily + $fiscal_period_end = $fiscal_period_start; + } elseif ($fields['duration_type'] == 1) { // Monthly + $fiscal_period_end = dol_time_plus_duree(dol_time_plus_duree($fiscal_period_start, 1, 'm'), -1, 'd'); + } else { // Annually + $fiscal_period_end = dol_time_plus_duree(dol_time_plus_duree($fiscal_period_start, 1, 'y'), -1, 'd'); + } + $last_period_date = $disposal_date !== "" && $disposal_date < $depreciation_date_end ? $disposal_date : $depreciation_date_end; + } while ($fiscal_period_start < $last_period_date); + + if ($error) { + break; + } + } + } + + if ($error) { + $this->db->rollback(); + return -1; + } else { + $this->db->commit(); + return 1; + } + } + + /** + * Set last cumulative depreciation for each mode + * + * @param int $asset_depreciation_id Asset depreciation line ID + * @return int <0 if KO, >0 if OK + */ + public function setLastCumulativeDepreciation($asset_depreciation_id) + { + global $langs; + $langs->load('assets'); + + // Clean parameters + $asset_depreciation_id = $asset_depreciation_id > 0 ? $asset_depreciation_id : 0; + + // Check parameters + $error = 0; + if (empty($asset_depreciation_id)) { + $this->errors[] = $langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("AssetDepreciation") . ' (' . $langs->transnoentitiesnoconv("TechnicalID") . ')'); + $error++; + } + if ($error) { + return -1; + } + + $this->db->begin(); + + require_once DOL_DOCUMENT_ROOT . '/asset/class/assetdepreciationoptions.class.php'; + $options = new AssetDepreciationOptions($this->db); + + // Get last depreciation lines save in bookkeeping + //----------------------------------------------------- + $sql = "SELECT fk_asset, depreciation_mode, cumulative_depreciation_ht"; + $sql .= " FROM " . MAIN_DB_PREFIX . "asset_depreciation"; + $sql .= " WHERE rowid = " . (int) $asset_depreciation_id; + $resql = $this->db->query($sql); + if (!$resql) { + $this->errors[] = $langs->trans('AssetErrorFetchCumulativeDepreciation') . ': ' . $this->db->lasterror(); + $error++; + } else { + if ($obj = $this->db->fetch_object($resql)) { + $mode_key = $obj->depreciation_mode; + if (!empty($options->deprecation_options_fields[$mode_key])) { + $sql = "UPDATE " . MAIN_DB_PREFIX . $options->deprecation_options_fields[$mode_key]['table']; + $sql .= " SET total_amount_last_depreciation_ht = " . $obj->cumulative_depreciation_ht; + $sql .= " WHERE fk_asset = " . (int) $obj->fk_asset; + $resql = $this->db->query($sql); + if (!$resql) { + $this->errors[] = $langs->trans('AssetErrorSetLastCumulativeDepreciation') . ': ' . $this->db->lasterror(); + $error++; + } + } + } + } + + if ($error) { + $this->db->rollback(); + return -1; + } else { + $this->db->commit(); + return 1; + } + } + + /** + * Set dispose status + * + * @param User $user Object user that dispose + * @param int $disposal_invoice_id Disposal invoice ID + * @param int $notrigger 1=Does not execute triggers, 0=Execute triggers + * @return int <0 if KO, 0=Nothing done, >0 if OK + */ + public function dispose($user, $disposal_invoice_id, $notrigger = 0) + { + global $conf, $langs; + + // Protection + if ($this->status != self::STATUS_DRAFT || $this->status == self::STATUS_DISPOSED) { + return 0; + } + + $this->db->begin(); + + $required_fields = array('disposal_date', 'disposal_date', 'fk_disposal_type'); + foreach ($required_fields as $field) { + $this->fields[$field]['notnull'] = 1; + } + $result = $this->update($user, 1); + foreach ($required_fields as $field) { + $this->fields[$field]['notnull'] = 0; + } + if ($result > 0) { + if ($disposal_invoice_id > 0) $this->add_object_linked('facture', $disposal_invoice_id); + $result = $this->setStatusCommon($user, self::STATUS_DISPOSED, $notrigger, 'ASSET_DISPOSED'); + } + if ($result > 0) $result = $this->calculationDepreciation(); + + if ($result < 0) { + $this->db->rollback(); + } else { + $this->db->commit(); + } + + // Define output language + if ($result > 0 && empty($conf->global->MAIN_DISABLE_PDF_AUTOUPDATE)) { + if (method_exists($this, 'generateDocument')) { + global $hidedetails, $hidedesc, $hideref; + $outputlangs = $langs; + $newlang = ''; + if ($conf->global->MAIN_MULTILANGS && empty($newlang) && GETPOST('lang_id', 'aZ09')) { + $newlang = GETPOST('lang_id', 'aZ09'); + } + if ($conf->global->MAIN_MULTILANGS && empty($newlang)) { + $newlang = $this->thirdparty->default_lang; + } + if (!empty($newlang)) { + $outputlangs = new Translate("", $conf); + $outputlangs->setDefaultLang($newlang); + } + $model = $this->model_pdf; + $ret = $this->fetch($this->id); // Reload to get new records + + $this->generateDocument($model, $outputlangs, $hidedetails, $hidedesc, $hideref); + } + } + + return $result; + } + + /** + * Set back to validated status + * + * @param User $user Object user that modify + * @param int $notrigger 1=Does not execute triggers, 0=Execute triggers + * @return int <0 if KO, 0=Nothing done, >0 if OK + */ + public function reopen($user, $notrigger = 0) + { + global $conf, $langs; + + // Protection + if ($this->status != self::STATUS_DISPOSED || $this->status == self::STATUS_DRAFT) { + return 0; + } + + + $this->db->begin(); + + $this->disposal_date = null; + $this->disposal_amount_ht = null; + $this->fk_disposal_type = null; + $this->disposal_depreciated = null; + $this->disposal_subject_to_vat = null; + $result = $this->update($user, 1); + if ($result > 0) { + $this->deleteObjectLinked(null, 'facture'); + $result = $this->setStatusCommon($user, self::STATUS_DRAFT, $notrigger, 'ASSET_REOPEN'); + } + if ($result > 0) $result = $this->calculationDepreciation(); + + if ($result < 0) { + $this->db->rollback(); + } else { + $this->db->commit(); + } + + // Define output language + if ($result > 0 && empty($conf->global->MAIN_DISABLE_PDF_AUTOUPDATE)) { + if (method_exists($this, 'generateDocument')) { + global $hidedetails, $hidedesc, $hideref; + $outputlangs = $langs; + $newlang = ''; + if ($conf->global->MAIN_MULTILANGS && empty($newlang) && GETPOST('lang_id', 'aZ09')) { + $newlang = GETPOST('lang_id', 'aZ09'); + } + if ($conf->global->MAIN_MULTILANGS && empty($newlang)) { + $newlang = $this->thirdparty->default_lang; + } + if (!empty($newlang)) { + $outputlangs = new Translate("", $conf); + $outputlangs->setDefaultLang($newlang); + } + $model = $this->model_pdf; + $ret = $this->fetch($this->id); // Reload to get new records + + $this->generateDocument($model, $outputlangs, $hidedetails, $hidedesc, $hideref); + } + } + + return $result; } /** * Return a link to the object card (with optionaly the picto) * - * @param int $withpicto Include picto in link (0=No picto, 1=Include picto into link, 2=Only picto) - * @param string $option On what the link point to ('nolink', ...) - * @param int $notooltip 1=Disable tooltip - * @param string $morecss Add more css on link - * @param int $save_lastsearch_value -1=Auto, 0=No save of lastsearch_values when clicking, 1=Save lastsearch_values whenclicking - * @return string String with URL + * @param int $withpicto Include picto in link (0=No picto, 1=Include picto into link, 2=Only picto) + * @param string $option On what the link point to ('nolink', ...) + * @param int $maxlen Max length of name + * @param int $notooltip 1=Disable tooltip + * @param string $morecss Add more css on link + * @param int $save_lastsearch_value -1=Auto, 0=No save of lastsearch_values when clicking, 1=Save lastsearch_values whenclicking + * @return string String with URL */ - public function getNomUrl($withpicto = 0, $option = '', $notooltip = 0, $morecss = '', $save_lastsearch_value = -1) + public function getNomUrl($withpicto = 0, $option = '', $maxlen = 0, $notooltip = 0, $morecss = '', $save_lastsearch_value = -1) { - global $db, $conf, $langs; + global $db, $conf, $langs, $hookmanager; global $dolibarr_main_authentication, $dolibarr_main_demo; global $menumanager; @@ -338,7 +1298,7 @@ class Asset extends CommonObject $linkclose = ''; if (empty($notooltip)) { if (!empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER)) { - $label = $langs->trans("ShowAssets"); + $label = $langs->trans("ShowAsset"); $linkclose .= ' alt="'.dol_escape_htmltag($label, 1).'"'; } $linkclose .= ' title="'.dol_escape_htmltag($label, 1).'"'; @@ -347,28 +1307,87 @@ class Asset extends CommonObject $linkclose = ($morecss ? ' class="'.$morecss.'"' : ''); } - $linkstart = ''; - $linkend = ''; + if ($option == 'nolink') { + $linkend = ''; + } else { + $linkend = ''; + } $result .= $linkstart; - if ($withpicto) { - $result .= img_object(($notooltip ? '' : $label), ($this->picto ? $this->picto : 'generic'), ($notooltip ? (($withpicto != 2) ? 'class="paddingright"' : '') : 'class="'.(($withpicto != 2) ? 'paddingright ' : '').'classfortooltip"'), 0, 0, $notooltip ? 0 : 1); + + if (empty($this->showphoto_on_popup)) { + if ($withpicto) { + $result .= img_object(($notooltip ? '' : $label), ($this->picto ? $this->picto : 'generic'), ($notooltip ? (($withpicto != 2) ? 'class="paddingright"' : '') : 'class="'.(($withpicto != 2) ? 'paddingright ' : '').'classfortooltip"'), 0, 0, $notooltip ? 0 : 1); + } + } else { + if ($withpicto) { + require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; + + list($class, $module) = explode('@', $this->picto); + $upload_dir = $conf->$module->multidir_output[$conf->entity]."/$class/".dol_sanitizeFileName($this->ref); + $filearray = dol_dir_list($upload_dir, "files"); + $filename = $filearray[0]['name']; + if (!empty($filename)) { + $pospoint = strpos($filearray[0]['name'], '.'); + + $pathtophoto = $class.'/'.$this->ref.'/thumbs/'.substr($filename, 0, $pospoint).'_mini'.substr($filename, $pospoint); + if (empty($conf->global->{strtoupper($module.'_'.$class).'_FORMATLISTPHOTOSASUSERS'})) { + $result .= '
    No photo
    '; + } else { + $result .= '
    No photo
    '; + } + + $result .= ''; + } else { + $result .= img_object(($notooltip ? '' : $label), ($this->picto ? $this->picto : 'generic'), ($notooltip ? (($withpicto != 2) ? 'class="paddingright"' : '') : 'class="'.(($withpicto != 2) ? 'paddingright ' : '').'classfortooltip"'), 0, 0, $notooltip ? 0 : 1); + } + } } + if ($withpicto != 2) { - $result .= $this->ref; + $name = $this->ref; + if ($option == 'label') $name = $this->label; + elseif ($option == 'with_label') $name .= ' - ' . $this->label; + $result .= dol_escape_htmltag($maxlen ? dol_trunc($name, $maxlen) : $name); } + $result .= $linkend; //if ($withpicto != 2) $result.=(($addlabel && $this->label) ? $sep . dol_trunc($this->label, ($addlabel > 1 ? $addlabel : 0)) : ''); + global $action; + $hookmanager->initHooks(array($this->element . 'dao')); + $parameters = array('id'=>$this->id, 'getnomurl' => &$result); + $reshook = $hookmanager->executeHooks('getNomUrl', $parameters, $this, $action); // Note that $action and $object may have been modified by some hooks + if ($reshook > 0) { + $result = $hookmanager->resPrint; + } else { + $result .= $hookmanager->resPrint; + } return $result; } /** - * Retourne le libelle du status d'un user (actif, inactif) + * Return the label of the status * - * @param int $mode 0=libelle long, 1=libelle court, 2=Picto + Libelle court, 3=Picto, 4=Picto + Libelle long, 5=Libelle court + Picto - * @return string Label of status + * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto + * @return string Label of status + */ + public function getLabelStatus($mode = 0) + { + return $this->LibStatut($this->status, $mode); + } + + /** + * Return the label of the status + * + * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto + * @return string Label of status */ public function getLibStatut($mode = 0) { @@ -379,43 +1398,43 @@ class Asset extends CommonObject /** * Return the status * - * @param int $status Id status - * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto - * @return string Label of status + * @param int $status Id status + * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto + * @return string Label of status */ - public static function LibStatut($status, $mode = 0) + public function LibStatut($status, $mode = 0) { // phpcs:enable - global $langs; - - $langs->load("contracts"); - $labelStatus = array(); - $labelStatus[self::STATUS_DRAFT] = $langs->transnoentitiesnoconv('Disabled'); - $labelStatus[self::STATUS_VALIDATED] = $langs->transnoentitiesnoconv('Enabled'); - $labelStatusShort = array(); - $labelStatusShort[self::STATUS_DRAFT] = $langs->transnoentitiesnoconv('Disabled'); - $labelStatusShort[self::STATUS_VALIDATED] = $langs->transnoentitiesnoconv('Enabled'); - - $statusType = 'status0'; - if ($status == self::STATUS_VALIDATED) { - $statusType = 'status4'; + if (empty($this->labelStatus) || empty($this->labelStatusShort)) { + global $langs; + //$langs->load("asset@asset"); + $this->labelStatus[self::STATUS_DRAFT] = $langs->transnoentitiesnoconv('AssetInProgress'); + $this->labelStatus[self::STATUS_DISPOSED] = $langs->transnoentitiesnoconv('AssetDisposed'); + $this->labelStatusShort[self::STATUS_DRAFT] = $langs->transnoentitiesnoconv('AssetInProgress'); + $this->labelStatusShort[self::STATUS_DISPOSED] = $langs->transnoentitiesnoconv('AssetDisposed'); } - return dolGetStatus($labelStatus[$status], $labelStatusShort[$status], '', $statusType, $mode); + $statusType = 'status4'; + if ($status == self::STATUS_DISPOSED) { + $statusType = 'status6'; + } + + return dolGetStatus($this->labelStatus[$status], $this->labelStatusShort[$status], '', $statusType, $mode); } /** - * Load info into asset object + * Load the info information in the object * - * @param int $id Id of order + * @param int $id Id of object * @return void */ public function info($id) { - $sql = 'SELECT rowid, date_creation as datec, tms as datem,'; - $sql .= ' fk_user_creat, fk_user_modif'; - $sql .= ' FROM '.MAIN_DB_PREFIX.$this->table_element.' as t'; - $sql .= ' WHERE t.rowid = '.((int) $id); + $sql = "SELECT rowid, date_creation as datec, tms as datem,"; + $sql .= " fk_user_creat, fk_user_modif"; + $sql .= " FROM ".MAIN_DB_PREFIX.$this->table_element." as t"; + $sql .= " WHERE t.rowid = ".((int) $id); + $result = $this->db->query($sql); if ($result) { if ($this->db->num_rows($result)) { @@ -458,25 +1477,116 @@ class Asset extends CommonObject */ public function initAsSpecimen() { + // Set here init that are not commonf fields + // $this->property1 = ... + // $this->property2 = ... + $this->initAsSpecimenCommon(); } + /** + * Create an array of lines + * + * @return array|int array of lines if OK, <0 if KO + */ + public function getLinesArray() + { + $this->lines = array(); + + return $this->lines; + } /** - * Action executed by scheduler - * CAN BE A CRON TASK + * Returns the reference to the following non used object depending on the active numbering module. * - * @return int 0 if OK, <>0 if KO (this function is used also by cron so only 0 is OK) + * @return string Object free reference */ - public function doScheduledJob() + public function getNextNumRef() { - global $conf, $langs; + global $langs, $conf; + $langs->load("asset@asset"); - $this->output = ''; - $this->error = ''; + if (empty($conf->global->ASSET_ASSET_ADDON)) { + $conf->global->ASSET_ASSET_ADDON = 'mod_asset_standard'; + } - dol_syslog(__METHOD__, LOG_DEBUG); + if (!empty($conf->global->ASSET_ASSET_ADDON)) { + $mybool = false; - return 0; + $file = $conf->global->ASSET_ASSET_ADDON.".php"; + $classname = $conf->global->ASSET_ASSET_ADDON; + + // Include file with class + $dirmodels = array_merge(array('/'), (array) $conf->modules_parts['models']); + foreach ($dirmodels as $reldir) { + $dir = dol_buildpath($reldir."core/modules/asset/"); + + // Load file with numbering class (if found) + $mybool |= @include_once $dir.$file; + } + + if ($mybool === false) { + dol_print_error('', "Failed to include file ".$file); + return ''; + } + + if (class_exists($classname)) { + $obj = new $classname(); + $numref = $obj->getNextValue($this); + + if ($numref != '' && $numref != '-1') { + return $numref; + } else { + $this->error = $obj->error; + //dol_print_error($this->db,get_class($this)."::getNextNumRef ".$obj->error); + return ""; + } + } else { + print $langs->trans("Error")." ".$langs->trans("ClassNotFound").' '.$classname; + return ""; + } + } else { + print $langs->trans("ErrorNumberingModuleNotSetup", $this->element); + return ""; + } } + + /** + * Create a document onto disk according to template module. + * + * @param string $modele Force template to use ('' to not force) + * @param Translate $outputlangs objet lang a utiliser pour traduction + * @param int $hidedetails Hide details of lines + * @param int $hidedesc Hide description + * @param int $hideref Hide ref + * @param null|array $moreparams Array to provide more information + * @return int 0 if KO, 1 if OK + */ + // public function generateDocument($modele, $outputlangs, $hidedetails = 0, $hidedesc = 0, $hideref = 0, $moreparams = null) + // { + // global $conf, $langs; + // + // $result = 0; + // $includedocgeneration = 1; + // + // $langs->load("asset@asset"); + // + // if (!dol_strlen($modele)) { + // $modele = 'standard_asset'; + // + // if (!empty($this->model_pdf)) { + // $modele = $this->model_pdf; + // } elseif (!empty($conf->global->ASSET_ADDON_PDF)) { + // $modele = $conf->global->ASSET_ADDON_PDF; + // } + // } + // + // $modelpath = "core/modules/asset/doc/"; + // + // if ($includedocgeneration && !empty($modele)) { + // $result = $this->commonGenerateDocument($modelpath, $modele, $outputlangs, $hidedetails, $hidedesc, $hideref, $moreparams); + // } + // + // return $result; + // } } diff --git a/htdocs/asset/class/asset_type.class.php b/htdocs/asset/class/asset_type.class.php deleted file mode 100644 index 75b3030eac9..00000000000 --- a/htdocs/asset/class/asset_type.class.php +++ /dev/null @@ -1,449 +0,0 @@ - - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -/** - * \file htdocs/asset/class/asset_type.class.php - * \ingroup asset - * \brief File of class to manage asset types - */ - -require_once DOL_DOCUMENT_ROOT.'/core/class/commonobject.class.php'; - - -/** - * Class to manage asset type - */ -class AssetType extends CommonObject -{ - /** - * @var string Name of table without prefix where object is stored - */ - public $table_element = 'asset_type'; - - /** - * @var string ID to identify managed object - */ - public $element = 'asset_type'; - - /** - * @var string String with name of icon for myobject. Must be the part after the 'object_' into object_myobject.png - */ - public $picto = 'asset'; - - /** - * 0=No test on entity, 1=Test with field entity, 2=Test with link by societe - * @var int - */ - public $ismultientitymanaged = 1; - - /** - * @var string Asset type label - */ - public $label; - - /** @var string Accountancy code asset */ - public $accountancy_code_asset; - - /** @var string Accountancy code depreciation asset */ - public $accountancy_code_depreciation_asset; - - /** @var string Accountancy code depreciation expense */ - public $accountancy_code_depreciation_expense; - - /** @var string Public note */ - public $note; - - /** @var array Array of asset */ - public $asset = array(); - - public $fields = array( - 'rowid' =>array('type'=>'integer', 'label'=>'TechnicalID', 'enabled'=>1, 'visible'=>-1, 'notnull'=>1, 'position'=>10), - 'entity' =>array('type'=>'integer', 'label'=>'Entity', 'default'=>1, 'enabled'=>1, 'visible'=>-2, 'notnull'=>1, 'position'=>15, 'index'=>1), - 'tms' =>array('type'=>'timestamp', 'label'=>'DateModification', 'enabled'=>1, 'visible'=>-1, 'notnull'=>1, 'position'=>20), - 'label' =>array('type'=>'varchar(50)', 'label'=>'Label', 'enabled'=>1, 'visible'=>-1, 'notnull'=>1, 'position'=>25, 'showoncombobox'=>1), - 'accountancy_code_asset' =>array('type'=>'varchar(32)', 'label'=>'Accountancy code asset', 'enabled'=>1, 'visible'=>-1, 'position'=>30), - 'accountancy_code_depreciation_asset' =>array('type'=>'varchar(32)', 'label'=>'Accountancy code depreciation asset', 'enabled'=>1, 'visible'=>-1, 'position'=>35), - 'accountancy_code_depreciation_expense' =>array('type'=>'varchar(32)', 'label'=>'Accountancy code depreciation expense', 'enabled'=>1, 'visible'=>-1, 'position'=>40), - 'note' =>array('type'=>'mediumtext', 'label'=>'Note', 'enabled'=>1, 'visible'=>-1, 'position'=>45), - ); - - - /** - * Constructor - * - * @param DoliDB $db Database handler - */ - public function __construct($db) - { - $this->db = $db; - } - - - /** - * Fonction qui permet de creer le type d'immobilisation - * - * @param User $user User making creation - * @param int $notrigger 1=do not execute triggers, 0 otherwise - * @return int >0 if OK, < 0 if KO - */ - public function create($user, $notrigger = 0) - { - global $conf; - - $error = 0; - - $this->label = trim($this->label); - $this->accountancy_code_asset = trim($this->accountancy_code_asset); - $this->accountancy_code_depreciation_asset = trim($this->accountancy_code_depreciation_asset); - $this->accountancy_code_depreciation_expense = trim($this->accountancy_code_depreciation_expense); - - $this->db->begin(); - - $sql = "INSERT INTO ".MAIN_DB_PREFIX."asset_type ("; - $sql .= "label"; - $sql .= ", accountancy_code_asset"; - $sql .= ", accountancy_code_depreciation_asset"; - $sql .= ", accountancy_code_depreciation_expense"; - $sql .= ", note"; - $sql .= ", entity"; - $sql .= ") VALUES ("; - $sql .= "'".$this->db->escape($this->label)."'"; - $sql .= ", '".$this->db->escape($this->accountancy_code_asset)."'"; - $sql .= ", '".$this->db->escape($this->accountancy_code_depreciation_asset)."'"; - $sql .= ", '".$this->db->escape($this->accountancy_code_depreciation_expense)."'"; - $sql .= ", '".$this->db->escape($this->note)."'"; - $sql .= ", ".((int) $conf->entity); - $sql .= ")"; - - dol_syslog("Asset_type::create", LOG_DEBUG); - $result = $this->db->query($sql); - if ($result) { - $this->id = $this->db->last_insert_id(MAIN_DB_PREFIX."asset_type"); - - $result = $this->update($user, 1); - if ($result < 0) { - $this->db->rollback(); - return -3; - } - - if (!$notrigger) { - // Call trigger - $result = $this->call_trigger('ASSET_TYPE_CREATE', $user); - if ($result < 0) { - $error++; - } - // End call triggers - } - - if (!$error) { - $this->db->commit(); - return $this->id; - } else { - dol_syslog(get_class($this)."::create ".$this->error, LOG_ERR); - $this->db->rollback(); - return -2; - } - } else { - $this->error = $this->db->lasterror(); - $this->db->rollback(); - return -1; - } - } - - /** - * Met a jour en base donnees du type - * - * @param User $user Object user making change - * @param int $notrigger 1=do not execute triggers, 0 otherwise - * @return int >0 if OK, < 0 if KO - */ - public function update($user, $notrigger = 0) - { - global $conf, $hookmanager; - - $error = 0; - - $this->label = trim($this->label); - - $this->db->begin(); - - $sql = "UPDATE ".MAIN_DB_PREFIX."asset_type "; - $sql .= "SET "; - $sql .= "label = '".$this->db->escape($this->label)."',"; - $sql .= "accountancy_code_asset = '".$this->db->escape($this->accountancy_code_asset)."',"; - $sql .= "accountancy_code_depreciation_asset = '".$this->db->escape($this->accountancy_code_depreciation_asset)."',"; - $sql .= "accountancy_code_depreciation_expense = '".$this->db->escape($this->accountancy_code_depreciation_expense)."',"; - $sql .= "note = '".$this->db->escape($this->note)."'"; - $sql .= " WHERE rowid = ".((int) $this->id); - - $result = $this->db->query($sql); - if ($result) { - $action = 'update'; - - // Actions on extra fields - if (!$error) { - $result = $this->insertExtraFields(); - if ($result < 0) { - $error++; - } - } - - if (!$error && !$notrigger) { - // Call trigger - $result = $this->call_trigger('ASSET_TYPE_MODIFY', $user); - if ($result < 0) { - $error++; - } - // End call triggers - } - - if (!$error) { - $this->db->commit(); - return 1; - } else { - $this->db->rollback(); - dol_syslog(get_class($this)."::update ".$this->error, LOG_ERR); - return -$error; - } - } else { - $this->error = $this->db->lasterror(); - $this->db->rollback(); - return -1; - } - } - - /** - * Fonction qui permet de supprimer le status de l'adherent - * - * @return int >0 if OK, 0 if not found, < 0 if KO - */ - public function delete() - { - global $user; - - $error = 0; - - $sql = "DELETE FROM ".MAIN_DB_PREFIX."asset_type"; - $sql .= " WHERE rowid = ".((int) $this->id); - - $resql = $this->db->query($sql); - if ($resql) { - // Call trigger - $result = $this->call_trigger('ASSET_TYPE_DELETE', $user); - if ($result < 0) { - $error++; $this->db->rollback(); return -2; - } - // End call triggers - - $this->db->commit(); - return 1; - } else { - $this->db->rollback(); - $this->error = $this->db->lasterror(); - return -1; - } - } - - /** - * Fonction qui permet de recuperer le status de l'immobilisation - * - * @param int $rowid Id of member type to load - * @return int <0 if KO, >0 if OK - */ - public function fetch($rowid) - { - $sql = "SELECT d.rowid, d.label as label, d.accountancy_code_asset, d.accountancy_code_depreciation_asset, d.accountancy_code_depreciation_expense, d.note"; - $sql .= " FROM ".MAIN_DB_PREFIX."asset_type as d"; - $sql .= " WHERE d.rowid = ".(int) $rowid; - - dol_syslog("Asset_type::fetch", LOG_DEBUG); - - $resql = $this->db->query($sql); - if ($resql) { - if ($this->db->num_rows($resql)) { - $obj = $this->db->fetch_object($resql); - - $this->id = $obj->rowid; - $this->ref = $obj->rowid; - $this->label = $obj->label; - $this->accountancy_code_asset = $obj->accountancy_code_asset; - $this->accountancy_code_depreciation_asset = $obj->accountancy_code_depreciation_asset; - $this->accountancy_code_depreciation_expense = $obj->accountancy_code_depreciation_expense; - $this->note = $obj->note; - } - - return 1; - } else { - $this->error = $this->db->lasterror(); - return -1; - } - } - - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps - /** - * Return list of asset's type - * - * @return array List of types of members - */ - public function liste_array() - { - // phpcs:enable - global $conf, $langs; - - $assettypes = array(); - - $sql = "SELECT rowid, label as label"; - $sql .= " FROM ".MAIN_DB_PREFIX."asset_type"; - $sql .= " WHERE entity IN (".getEntity('asset_type').")"; - - $resql = $this->db->query($sql); - if ($resql) { - $nump = $this->db->num_rows($resql); - - if ($nump) { - $i = 0; - while ($i < $nump) { - $obj = $this->db->fetch_object($resql); - - $assettypes[$obj->rowid] = $langs->trans($obj->label); - $i++; - } - } - } else { - print $this->db->error(); - } - return $assettypes; - } - - /** - * Return array of Asset objects for asset type this->id (or all if this->id not defined) - * - * @param string $excludefilter Filter string to exclude. This parameter must not be provided by input of users - * @param int $mode 0=Return array of asset instance - * 1=Return array of asset instance without extra data - * 2=Return array of asset id only - * @return mixed Array of asset or -1 on error - */ - public function listAssetForAssetType($excludefilter = '', $mode = 0) - { - global $conf, $user; - - $ret = array(); - - $sql = "SELECT a.rowid"; - $sql .= " FROM ".MAIN_DB_PREFIX."asset as a"; - $sql .= " WHERE a.entity IN (".getEntity('asset').")"; - $sql .= " AND a.fk_asset_type = ".((int) $this->id); - if (!empty($excludefilter)) { - $sql .= ' AND ('.$excludefilter.')'; - } - - dol_syslog(get_class($this)."::listAssetsForGroup", LOG_DEBUG); - $resql = $this->db->query($sql); - if ($resql) { - while ($obj = $this->db->fetch_object($resql)) { - if (!array_key_exists($obj->rowid, $ret)) { - if ($mode < 2) { - $assetstatic = new Asset($this->db); - if ($mode == 1) { - $assetstatic->fetch($obj->rowid, '', '', '', false, false); - } else { - $assetstatic->fetch($obj->rowid); - } - $ret[$obj->rowid] = $assetstatic; - } else { - $ret[$obj->rowid] = $obj->rowid; - } - } - } - - $this->db->free($resql); - - $this->asset = $ret; - - return $ret; - } else { - $this->error = $this->db->lasterror(); - return -1; - } - } - - /** - * Return clicable name (with picto eventually) - * - * @param int $withpicto 0=No picto, 1=Include picto into link, 2=Only picto - * @param int $maxlen length max label - * @param int $notooltip 1=Disable tooltip - * @return string String with URL - */ - public function getNomUrl($withpicto = 0, $maxlen = 0, $notooltip = 0) - { - global $langs; - - $result = ''; - $label = $langs->trans("ShowTypeCard", $this->label); - - $linkstart = ''; - $linkend = ''; - - $result .= $linkstart; - if ($withpicto) { - $result .= img_object(($notooltip ? '' : $label), ($this->picto ? $this->picto : 'generic'), ($notooltip ? (($withpicto != 2) ? 'class="paddingright"' : '') : 'class="'.(($withpicto != 2) ? 'paddingright ' : '').'classfortooltip"'), 0, 0, $notooltip ? 0 : 1); - } - if ($withpicto != 2) { - $result .= ($maxlen ?dol_trunc($this->label, $maxlen) : $this->label); - } - $result .= $linkend; - - return $result; - } - - /** - * Initialise an instance with random values. - * Used to build previews or test instances. - * id must be 0 if object instance is a specimen. - * - * @return void - */ - public function initAsSpecimen() - { - global $conf, $user, $langs; - - // Initialize parameters - $this->id = 0; - $this->ref = 'ATSPEC'; - $this->specimen = 1; - - $this->label = 'ASSET TYPE SPECIMEN'; - $this->note = 'This is a note'; - - // Assets of this asset type is just me - $this->asset = array( - $user->id => $user - ); - } - - /** - * getLibStatut - * - * @return string Return status of a type of asset - */ - public function getLibStatut() - { - return ''; - } -} diff --git a/htdocs/asset/class/assetaccountancycodes.class.php b/htdocs/asset/class/assetaccountancycodes.class.php new file mode 100644 index 00000000000..720dd1e745d --- /dev/null +++ b/htdocs/asset/class/assetaccountancycodes.class.php @@ -0,0 +1,279 @@ + + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file asset/class/assetaccountancycodes.class.php + * \ingroup asset + * \brief This file is a class file for AssetAccountancyCodes + */ + +require_once DOL_DOCUMENT_ROOT.'/core/class/commonobject.class.php'; + +/** + * Class for AssetAccountancyCodes + */ +class AssetAccountancyCodes extends CommonObject +{ + /** + * @var array Array with all accountancy codes info by mode. + * Note : 'economic' mode is mandatory and is the primary accountancy codes + * 'depreciation_asset' and 'depreciation_expense' is mandatory and is used for write depreciation in bookkeeping + */ + public $accountancy_codes_fields = array( + 'economic' => array( + 'label' => 'AssetAccountancyCodeDepreciationEconomic', + 'table' => 'asset_accountancy_codes_economic', + 'depreciation_debit' => 'depreciation_asset', + 'depreciation_credit' => 'depreciation_expense', + 'fields' => array( + 'asset' => array('label' => 'AssetAccountancyCodeAsset'), + 'depreciation_asset' => array('label' => 'AssetAccountancyCodeDepreciationAsset'), + 'depreciation_expense' => array('label' => 'AssetAccountancyCodeDepreciationExpense'), + 'value_asset_sold' => array('label' => 'AssetAccountancyCodeValueAssetSold'), + 'receivable_on_assignment' => array('label' => 'AssetAccountancyCodeReceivableOnAssignment'), + 'proceeds_from_sales' => array('label' => 'AssetAccountancyCodeProceedsFromSales'), + 'vat_collected' => array('label' => 'AssetAccountancyCodeVatCollected'), + 'vat_deductible' => array('label' => 'AssetAccountancyCodeVatDeductible'), + ), + ), + 'accelerated_depreciation' => array( + 'label' => 'AssetAccountancyCodeDepreciationAcceleratedDepreciation', + 'table' => 'asset_accountancy_codes_fiscal', + 'depreciation_debit' => 'accelerated_depreciation', + 'depreciation_credit' => 'endowment_accelerated_depreciation', + 'fields' => array( + 'accelerated_depreciation' => array('label' => 'AssetAccountancyCodeAcceleratedDepreciation'), + 'endowment_accelerated_depreciation' => array('label' => 'AssetAccountancyCodeEndowmentAcceleratedDepreciation'), + 'provision_accelerated_depreciation' => array('label' => 'AssetAccountancyCodeProvisionAcceleratedDepreciation'), + ), + ), + ); + + /** + * @var array Array with all accountancy codes by mode. + */ + public $accountancy_codes = array(); + + /** + * Constructor + * + * @param DoliDb $db Database handler + */ + public function __construct(DoliDB $db) + { + $this->db = $db; + } + + /** + * Fill accountancy_codes property of object (using for data sent by forms) + * + * @return array Array of values + */ + public function setAccountancyCodesFromPost() + { + $this->accountancy_codes = array(); + foreach ($this->accountancy_codes_fields as $mode_key => $mode_info) { + $this->accountancy_codes[$mode_key] = array(); + foreach ($mode_info['fields'] as $field_key => $field_info) { + $accountancy_code = GETPOST($mode_key . '_' . $field_key, 'aZ09'); + if (empty($accountancy_code) || $accountancy_code == '-1') $accountancy_code = ''; + $this->accountancy_codes[$mode_key][$field_key] = $accountancy_code; + } + } + } + + /** + * Load accountancy codes of a asset or a asset model + * + * @param int $asset_id Asset ID to set + * @param int $asset_model_id Asset model ID to set + * @return int <0 if KO, >0 if OK + */ + public function fetchAccountancyCodes($asset_id = 0, $asset_model_id = 0) + { + global $langs, $hookmanager; + dol_syslog(__METHOD__ . " asset_id=$asset_id, asset_model_id=$asset_model_id"); + + $error = 0; + $this->errors = array(); + $this->accountancy_codes = array(); + + // Clean parameters + $asset_id = $asset_id > 0 ? $asset_id : 0; + $asset_model_id = $asset_model_id > 0 ? $asset_model_id : 0; + + if (!is_object($hookmanager)) { + require_once DOL_DOCUMENT_ROOT . '/core/class/hookmanager.class.php'; + $hookmanager = new HookManager($this->db); + } + + $hookmanager->initHooks(array('assetaccountancycodesdao')); + $parameters = array('asset_id' => $asset_id, 'asset_model_id' => $asset_model_id); + $reshook = $hookmanager->executeHooks('fetchAccountancyCodes', $parameters, $this); // Note that $action and $object may have been modified by some hooks + if (!empty($reshook)) { + return $reshook; + } + + // Check parameters + if (empty($asset_id) && empty($asset_model_id)) { + $this->errors[] = $langs->trans('AssetErrorAssetOrAssetModelIDNotProvide'); + $error++; + } + if ($error) { + dol_syslog(__METHOD__ . " Error check parameters: " . $this->errorsToString(), LOG_ERR); + return -1; + } + + $accountancy_codes = array(); + foreach ($this->accountancy_codes_fields as $mode_key => $mode_info) { + $sql = "SELECT " . implode(',', array_keys($mode_info['fields'])); + $sql .= " FROM " . MAIN_DB_PREFIX . $mode_info['table']; + $sql .= " WHERE " . ($asset_id > 0 ? " fk_asset = " . (int) $asset_id : " fk_asset_model = " . (int) $asset_model_id); + + $resql = $this->db->query($sql); + if ($resql) { + if ($obj = $this->db->fetch_object($resql)) { + $accountancy_codes[$mode_key] = array(); + foreach ($mode_info['fields'] as $field_key => $field_info) { + $accountancy_codes[$mode_key][$field_key] = $obj->$field_key; + } + } + } else { + $this->errors[] = $langs->trans('AssetErrorFetchAccountancyCodesForMode', $mode_key) . ': ' . $this->db->lasterror(); + $error++; + } + } + + if ($error) { + dol_syslog(__METHOD__ . " Error fetch accountancy codes: " . $this->errorsToString(), LOG_ERR); + return -1; + } else { + $this->accountancy_codes = $accountancy_codes; + return 1; + } + } + + /** + * Update accountancy codes of a asset or a asset model + * + * @param User $user User making update + * @param int $asset_id Asset ID to set + * @param int $asset_model_id Asset model ID to set + * @param int $notrigger 1=disable trigger UPDATE (when called by create) + * @return int <0 if KO, >0 if OK + */ + public function updateAccountancyCodes($user, $asset_id = 0, $asset_model_id = 0, $notrigger = 0) + { + global $langs, $hookmanager; + dol_syslog(__METHOD__ . " user_id={$user->id}, asset_id=$asset_id, asset_model_id=$asset_model_id, notrigger=$notrigger"); + + $error = 0; + $this->errors = array(); + + // Clean parameters + $asset_id = $asset_id > 0 ? $asset_id : 0; + $asset_model_id = $asset_model_id > 0 ? $asset_model_id : 0; + + if (!is_object($hookmanager)) { + require_once DOL_DOCUMENT_ROOT . '/core/class/hookmanager.class.php'; + $hookmanager = new HookManager($this->db); + } + + $hookmanager->initHooks(array('assetaccountancycodesdao')); + $parameters = array('user' => $user, 'asset_id' => $asset_id, 'asset_model_id' => $asset_model_id); + $reshook = $hookmanager->executeHooks('updateAccountancyCodes', $parameters, $this); // Note that $action and $object may have been modified by some hooks + if (!empty($reshook)) { + return $reshook; + } + + // Check parameters + if (empty($asset_id) && empty($asset_model_id)) { + $this->errors[] = $langs->trans('AssetErrorAssetOrAssetModelIDNotProvide'); + $error++; + } + if ($error) { + dol_syslog(__METHOD__ . " Error check parameters: " . $this->errorsToString(), LOG_ERR); + return -1; + } + + $this->db->begin(); + $now = dol_now(); + + foreach ($this->accountancy_codes_fields as $mode_key => $mode_info) { + // Delete old accountancy codes + $sql = "DELETE FROM " . MAIN_DB_PREFIX . $mode_info['table']; + $sql .= " WHERE " . ($asset_id > 0 ? " fk_asset = " . (int) $asset_id : " fk_asset_model = " . (int) $asset_model_id); + $resql = $this->db->query($sql); + if (!$resql) { + $this->errors[] = $langs->trans('AssetErrorDeleteAccountancyCodesForMode', $mode_key) . ': ' . $this->db->lasterror(); + $error++; + } + + if (!$error && !empty($this->accountancy_codes[$mode_key])) { + // Insert accountancy codes + $sql = "INSERT INTO " . MAIN_DB_PREFIX . $mode_info['table'] . "("; + $sql .= $asset_id > 0 ? "fk_asset," : "fk_asset_model,"; + $sql .= implode(',', array_keys($mode_info['fields'])); + $sql .= ", tms, fk_user_modif"; + $sql .= ") VALUES("; + $sql .= $asset_id > 0 ? $asset_id : $asset_model_id; + foreach ($mode_info['fields'] as $field_key => $field_info) { + $sql .= ', ' . (empty($this->accountancy_codes[$mode_key][$field_key]) ? 'NULL' : "'" . $this->db->escape($this->accountancy_codes[$mode_key][$field_key]) . "'"); + } + $sql .= ", '" . $this->db->idate($now) . "'"; + $sql .= ", " . $user->id; + $sql .= ")"; + + $resql = $this->db->query($sql); + if (!$resql) { + $this->errors[] = $langs->trans('AssetErrorInsertAccountancyCodesForMode', $mode_key) . ': ' . $this->db->lasterror(); + $error++; + } + } + } + + if (!$error && $asset_id > 0) { + // Calculation of depreciation lines (reversal and future) + require_once DOL_DOCUMENT_ROOT . '/asset/class/asset.class.php'; + $asset = new Asset($this->db); + $result = $asset->fetch($asset_id); + if ($result > 0) $result = $asset->calculationDepreciation(); + if ($result < 0) { + $this->errors[] = $langs->trans('AssetErrorCalculationDepreciationLines'); + $this->errors[] = $asset->errorsToString(); + $error++; + } + } + + if (!$error && !$notrigger) { + // Call trigger + $result = $this->call_trigger('ASSET_ACCOUNTANCY_CODES_MODIFY', $user); + if ($result < 0) { + $error++; + } + // End call triggers + } + + if (!$error) { + $this->db->commit(); + return 1; + } else { + $this->db->rollback(); + return -1; + } + } +} diff --git a/htdocs/asset/class/assetdepreciationoptions.class.php b/htdocs/asset/class/assetdepreciationoptions.class.php new file mode 100644 index 00000000000..ce2ddd73c08 --- /dev/null +++ b/htdocs/asset/class/assetdepreciationoptions.class.php @@ -0,0 +1,546 @@ + + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file asset/class/assetdepreciationoptions.class.php + * \ingroup asset + * \brief This file is a class file for AssetDepreciationOptions + */ + +require_once DOL_DOCUMENT_ROOT.'/core/class/commonobject.class.php'; + +/** + * Class for AssetDepreciationOptions + */ +class AssetDepreciationOptions extends CommonObject +{ + /** + * @var string Name of table without prefix where object is stored. This is also the key used for extrafields management. + */ + public $table_element = ''; + + /** + * 'type' field format ('integer', 'integer:ObjectClass:PathToClass[:AddCreateButtonOrNot[:Filter[:Sortfield]]]', 'sellist:TableName:LabelFieldName[:KeyFieldName[:KeyFieldParent[:Filter[:Sortfield]]]]', 'varchar(x)', 'double(24,8)', 'real', 'price', 'text', 'text:none', 'html', 'date', 'datetime', 'timestamp', 'duration', 'mail', 'phone', 'url', 'password') + * Note: Filter can be a string like "(t.ref:like:'SO-%') or (t.date_creation:<:'20160101') or (t.nature:is:NULL)" + * 'label' the translation key. + * 'picto' is code of a picto to show before value in forms + * 'enabled' is a condition when the field must be managed (Example: 1 or '$conf->global->MY_SETUP_PARAM) + * 'position' is the sort order of field. + * 'notnull' is set to 1 if not null in database. Set to -1 if we must set data to null if empty ('' or 0). + * 'visible' says if field is visible in list (Examples: 0=Not visible, 1=Visible on list and create/update/view forms, 2=Visible on list only, 3=Visible on create/update/view form only (not list), 4=Visible on list and update/view form only (not create). 5=Visible on list and view only (not create/not update). Using a negative value means field is not shown by default on list but can be selected for viewing) + * 'noteditable' says if field is not editable (1 or 0) + * 'default' is a default value for creation (can still be overwrote by the Setup of Default Values if field is editable in creation form). Note: If default is set to '(PROV)' and field is 'ref', the default value will be set to '(PROVid)' where id is rowid when a new record is created. + * 'index' if we want an index in database. + * 'foreignkey'=>'tablename.field' if the field is a foreign key (it is recommanded to name the field fk_...). + * 'searchall' is 1 if we want to search in this field when making a search from the quick search button. + * 'isameasure' must be set to 1 or 2 if field can be used for measure. Field type must be summable like integer or double(24,8). Use 1 in most cases, or 2 if you don't want to see the column total into list (for example for percentage) + * 'css' and 'cssview' and 'csslist' is the CSS style to use on field. 'css' is used in creation and update. 'cssview' is used in view mode. 'csslist' is used for columns in lists. For example: 'css'=>'minwidth300 maxwidth500 widthcentpercentminusx', 'cssview'=>'wordbreak', 'csslist'=>'tdoverflowmax200' + * 'help' is a 'TranslationString' to use to show a tooltip on field. You can also use 'TranslationString:keyfortooltiponlick' for a tooltip on click. + * 'showoncombobox' if value of the field must be visible into the label of the combobox that list record + * 'disabled' is 1 if we want to have the field locked by a 'disabled' attribute. In most cases, this is never set into the definition of $fields into class, but is set dynamically by some part of code. + * 'arrayofkeyval' to set a list of values if type is a list of predefined values. For example: array("0"=>"Draft","1"=>"Active","-1"=>"Cancel"). Note that type can be 'integer' or 'varchar' + * 'autofocusoncreate' to have field having the focus on a create form. Only 1 field should have this property set to 1. + * 'comment' is not used. You can store here any text of your choice. It is not used by application. + * 'validate' is 1 if need to validate with $this->validateField() + * 'copytoclipboard' is 1 or 2 to allow to add a picto to copy value into clipboard (1=picto after label, 2=picto after value) + * 'enabled_field' if the mode block or a field is enabled if another field equal a value (="mode_key:field_key:value") + * 'only_on_asset' is 1 if only a field on a asset + * + * Note: To have value dynamic, you can set value to 0 in definition and edit the value on the fly into the constructor. + */ + + /** + * @var array Array with all fields and their property. Do not use it as a static var. It may be modified by constructor. + */ + public $fields = array(); + + /** + * @var array Array with all deprecation options info by mode. + * Note : economic mode is mandatory and is the primary options + */ + public $deprecation_options_fields = array( + 'economic' => array( + 'label' => 'AssetDepreciationOptionEconomic', + 'table' => 'asset_depreciation_options_economic', + 'fields' => array( + 'depreciation_type' => array('type'=>'smallint', 'label'=>'AssetDepreciationOptionDepreciationType', 'enabled'=>'1', 'position'=>10, 'notnull'=>1, 'visible'=>1, 'default'=>'0', 'arrayofkeyval'=>array('0'=>'AssetDepreciationOptionDepreciationTypeLinear', '1'=>'AssetDepreciationOptionDepreciationTypeDegressive', '2'=>'AssetDepreciationOptionDepreciationTypeExceptional'), 'validate'=>'1',), + 'degressive_coefficient' => array('type'=>'double(24,8)', 'label'=>'AssetDepreciationOptionDegressiveRate', 'enabled'=>'1', 'position'=>20, 'notnull'=>1, 'visible'=>1, 'default'=>'0', 'isameasure'=>'1', 'validate'=>'1','enabled_field' => 'economic:depreciation_type:1'), + 'duration' => array('type'=>'integer', 'label'=>'AssetDepreciationOptionDuration', 'enabled'=>'1', 'position'=>30, 'notnull'=>1, 'visible'=>1, 'default'=>'0', 'isameasure'=>'1', 'validate'=>'1',), + 'duration_type' => array('type'=>'smallint', 'label'=>'AssetDepreciationOptionDurationType', 'enabled'=>'1', 'position'=>40, 'notnull'=>1, 'visible'=>1, 'default'=>'0', 'arrayofkeyval'=>array('0'=>'AssetDepreciationOptionDurationTypeAnnual', '1'=>'AssetDepreciationOptionDurationTypeMonthly'/*, '2'=>'AssetDepreciationOptionDurationTypeDaily'*/), 'validate'=>'1',), + 'rate' => array('type'=>'double(24,8)', 'label'=>'AssetDepreciationOptionRate', 'enabled'=>'1', 'position'=>50, 'visible'=>3, 'default'=>'0', 'isameasure'=>'1', 'validate'=>'1', 'computed' => '$object->asset_depreciation_options->getRate("economic")',), + 'accelerated_depreciation_option' => array('type'=>'boolean', 'label'=>'AssetDepreciationOptionAcceleratedDepreciation', 'enabled'=>'1', 'position'=>60, 'column_break' => true, 'notnull'=>0, 'default'=>'0', 'visible'=>1, 'validate'=>'1',), + 'amount_base_depreciation_ht' => array('type'=>'price', 'label'=>'AssetDepreciationOptionAmountBaseDepreciationHT', 'enabled'=>'isset($object)&&get_class($object)=="Asset"', 'only_on_asset'=>1, 'position'=>90, 'notnull'=>0, 'required'=>1, 'visible'=>1, 'default'=>'$object->reversal_amount_ht > 0 ? $object->reversal_amount_ht : $object->acquisition_value_ht', 'isameasure'=>'1', 'validate'=>'1',), + 'amount_base_deductible_ht' => array('type'=>'price', 'label'=>'AssetDepreciationOptionAmountBaseDeductibleHT', 'enabled'=>'isset($object)&&get_class($object)=="Asset"', 'only_on_asset'=>1, 'position'=>100, 'notnull'=>0, 'visible'=>1, 'default'=>'0', 'isameasure'=>'1', 'validate'=>'1',), + 'total_amount_last_depreciation_ht' => array('type'=>'price', 'label'=>'AssetDepreciationOptionTotalAmountLastDepreciationHT', 'enabled'=>'isset($object)&&get_class($object)=="Asset"', 'only_on_asset'=>1, 'position'=>110, 'noteditable'=> 1, 'notnull'=>0, 'visible'=>1, 'default'=>'0', 'isameasure'=>'1', 'validate'=>'1',), + ), + ), + 'accelerated_depreciation' => array( + 'label' => 'AssetDepreciationOptionAcceleratedDepreciation', + 'table' => 'asset_depreciation_options_fiscal', + 'enabled_field' => 'economic:accelerated_depreciation_option:1', + 'fields' => array( + 'depreciation_type' => array('type'=>'smallint', 'label'=>'AssetDepreciationOptionDepreciationType', 'enabled'=>'1', 'position'=>10, 'notnull'=>1, 'visible'=>1, 'default'=>'0', 'arrayofkeyval'=>array('0'=>'AssetDepreciationOptionDepreciationTypeLinear', '1'=>'AssetDepreciationOptionDepreciationTypeDegressive', '2'=>'AssetDepreciationOptionDepreciationTypeExceptional'), 'validate'=>'1',), + 'degressive_coefficient' => array('type'=>'double(24,8)', 'label'=>'AssetDepreciationOptionDegressiveRate', 'enabled'=>'1', 'position'=>20, 'notnull'=>1, 'visible'=>1, 'default'=>'0', 'isameasure'=>'1', 'validate'=>'1','enabled_field' => 'accelerated_depreciation:depreciation_type:1'), + 'duration' => array('type'=>'integer', 'label'=>'AssetDepreciationOptionDuration', 'enabled'=>'1', 'position'=>30, 'notnull'=>1, 'visible'=>1, 'default'=>'0', 'isameasure'=>'1', 'validate'=>'1',), + 'duration_type' => array('type'=>'smallint', 'label'=>'AssetDepreciationOptionDurationType', 'enabled'=>'1', 'position'=>40, 'notnull'=>1, 'visible'=>1, 'default'=>'0', 'arrayofkeyval'=>array('0'=>'AssetDepreciationOptionDurationTypeAnnual', '1'=>'AssetDepreciationOptionDurationTypeMonthly'/*, '2'=>'AssetDepreciationOptionDurationTypeDaily'*/), 'validate'=>'1',), + 'rate' => array('type'=>'double(24,8)', 'label'=>'AssetDepreciationOptionRate', 'enabled'=>'1', 'position'=>50, 'visible'=>3, 'default'=>'0', 'isameasure'=>'1', 'validate'=>'1', 'computed' => '$object->asset_depreciation_options->getRate("accelerated_depreciation")',), + 'amount_base_depreciation_ht' => array('type'=>'price', 'label'=>'AssetDepreciationOptionAmountBaseDepreciationHT', 'enabled'=>'isset($object)&&get_class($object)=="Asset"', 'only_on_asset'=>1, 'position'=>80, 'column_break' => true, 'notnull'=>0, 'required'=>1, 'visible'=>1, 'default'=>'$object->reversal_amount_ht > 0 ? $object->reversal_amount_ht : $object->acquisition_value_ht', 'isameasure'=>'1', 'validate'=>'1',), + 'amount_base_deductible_ht' => array('type'=>'price', 'label'=>'AssetDepreciationOptionAmountBaseDeductibleHT', 'enabled'=>'isset($object)&&get_class($object)=="Asset"', 'only_on_asset'=>1, 'position'=>90, 'notnull'=>0, 'visible'=>1, 'default'=>'0', 'isameasure'=>'1', 'validate'=>'1',), + 'total_amount_last_depreciation_ht' => array('type'=>'price', 'label'=>'AssetDepreciationOptionTotalAmountLastDepreciationHT', 'enabled'=>'isset($object)&&get_class($object)=="Asset"', 'only_on_asset'=>1, 'position'=>100, 'noteditable'=> 1, 'notnull'=>0, 'visible'=>1, 'default'=>'0', 'isameasure'=>'1', 'validate'=>'1',), + ), + ), + ); + public $fk_asset; + public $fk_asset_model; + public $tms; + public $fk_user_modif; + + /** + * @var array Array with all deprecation options by mode. + */ + public $deprecation_options = array(); + + /** + * Constructor + * + * @param DoliDb $db Database handler + */ + public function __construct(DoliDB $db) + { + global $langs; + $this->db = $db; + + // Translate some data of arrayofkeyval + if (is_object($langs)) { + foreach ($this->deprecation_options_fields as $mode_key => $mode_info) { + if (!empty($mode_info['fields']) && is_array($mode_info['fields'])) { + foreach ($mode_info['fields'] as $field_key => $field_info) { + if (!empty($field_info['arrayofkeyval']) && is_array($field_info['arrayofkeyval'])) { + foreach ($field_info['arrayofkeyval'] as $key => $val) { + $this->deprecation_options_fields[$mode_key]['fields'][$field_key]['arrayofkeyval'][$key] = $langs->trans($val); + } + } + } + } + } + } + } + + /** + * Set object infos for a mode + * + * @param string $mode Depreciation mode (economic, accelerated_depreciation, ...) + * @param int $class_type Type (0:asset, 1:asset model) + * @param bool $all_field Get all fields + * @return int <0 if KO, >0 if OK + */ + public function setInfosForMode($mode, $class_type = 0, $all_field = false) + { + // Clean parameters + $mode = strtolower(trim($mode)); + + if (!empty($this->deprecation_options_fields[$mode])) { + $this->table_element = $this->deprecation_options_fields[$mode]['table']; + $this->fields = $this->deprecation_options_fields[$mode]['fields']; + foreach ($this->fields as $field_key => $field_info) { + if ((!empty($field_info['computed']) && !$all_field) || (!empty($field_info['only_on_asset']) && !empty($class_type))) { + unset($this->fields[$field_key]); + continue; + } + + // Unset required option (notnull) if field disabled + if (!empty($mode_info['enabled_field'])) { + $info = explode(':', $mode_info['enabled_field']); + if ($this->deprecation_options[$info[0]][$info[1]] != $info[2] && isset($this->fields[$field_key]['notnull'])) { + unset($this->fields[$field_key]['notnull']); + } + } + // Set value of the field in the object (for createCommon and setDeprecationOptionsFromPost functions) + $this->{$field_key} = $this->deprecation_options[$mode][$field_key]; + } + + $this->fields['rowid'] = array('type'=>'integer', 'label'=>'TechnicalID', 'enabled'=>'1', 'position'=>1, 'notnull'=>1, 'visible'=>0, 'noteditable'=>'1', 'index'=>1, 'css'=>'left', 'comment'=>"Id"); + if (empty($class_type)) { + $this->fields['fk_asset'] = array('type' => 'integer:Asset:asset/class/asset.class.php:1:status=1 AND entity IN (__SHARED_ENTITIES__)', 'label' => 'Asset', 'enabled' => '1', 'position' => 0, 'notnull' => 0, 'visible' => 0, 'index' => 1, 'validate' => '1',); + } else { + $this->fields['fk_asset_model'] = array('type' => 'integer:AssetModel:asset/class/assetmodel.class.php:1:status=1 AND entity IN (__SHARED_ENTITIES__)', 'label' => 'AssetModel', 'enabled' => '1', 'position' => 0, 'notnull' => 0, 'visible' => 0, 'index' => 1, 'validate' => '1',); + } + $this->fields['tms'] = array('type' => 'timestamp', 'label' => 'DateModification', 'enabled' => '1', 'position' => 501, 'notnull' => 0, 'visible' => 0,); + $this->fields['fk_user_modif'] = array('type' => 'integer:User:user/class/user.class.php', 'label' => 'UserModif', 'enabled' => '1', 'position' => 511, 'notnull' => -1, 'visible' => 0,); + } + + return 1; + } + + /** + * Fill deprecation_options property of object (using for data sent by forms) + * + * @param int $class_type Type (0:asset, 1:asset model) + * @return int <0 if KO, >0 if OK + */ + public function setDeprecationOptionsFromPost($class_type = 0) + { + global $conf, $langs; + + $error = 0; + + $deprecation_options = array(); + foreach ($this->deprecation_options_fields as $mode_key => $mode_info) { + $this->setInfosForMode($mode_key, $class_type); + + foreach ($mode_info['fields'] as $field_key => $field_info) { + if (!empty($field_info['computed'])) { + continue; + } + + $html_name = $mode_key . '_' . $field_key; + if ($field_info['type'] == 'duration') { + if (GETPOST($html_name . 'hour') == '' && GETPOST($html_name . 'min') == '') { + continue; // The field was not submited to be saved + } + } else { + if (!GETPOSTISSET($html_name)) { + continue; // The field was not submited to be saved + } + } + // Ignore special fields + if (in_array($field_key, array('rowid', 'entity', 'import_key'))) { + continue; + } + if (in_array($field_key, array('date_creation', 'tms', 'fk_user_creat', 'fk_user_modif'))) { + if (!in_array(abs($field_info['visible']), array(1, 3))) { + continue; // Only 1 and 3 that are case to create + } + } + + // Set value to insert + if (in_array($field_info['type'], array('text', 'html'))) { + $value = GETPOST($html_name, 'restricthtml'); + } elseif ($field_info['type'] == 'date') { + $value = dol_mktime(12, 0, 0, GETPOST($html_name . 'month', 'int'), GETPOST($html_name . 'day', 'int'), GETPOST($html_name . 'year', 'int')); // for date without hour, we use gmt + } elseif ($field_info['type'] == 'datetime') { + $value = dol_mktime(GETPOST($html_name . 'hour', 'int'), GETPOST($html_name . 'min', 'int'), GETPOST($html_name . 'sec', 'int'), GETPOST($html_name . 'month', 'int'), GETPOST($html_name . 'day', 'int'), GETPOST($html_name . 'year', 'int'), 'tzuserrel'); + } elseif ($field_info['type'] == 'duration') { + $value = 60 * 60 * GETPOST($html_name . 'hour', 'int') + 60 * GETPOST($html_name . 'min', 'int'); + } elseif (preg_match('/^(integer|price|real|double)/', $field_info['type'])) { + $value = price2num(GETPOST($html_name, 'alphanohtml')); // To fix decimal separator according to lang setup + } elseif ($field_info['type'] == 'boolean') { + $value = ((GETPOST($html_name) == '1' || GETPOST($html_name) == 'on') ? 1 : 0); + } elseif ($field_info['type'] == 'reference') { + // todo to check + $tmparraykey = array(); //array_keys($object->param_list); + $value = $tmparraykey[GETPOST($html_name)] . ',' . GETPOST($html_name . '2'); + } else { + if ($field_key == 'lang') { + $value = GETPOST($html_name, 'aZ09') ? GETPOST($html_name, 'aZ09') : ""; + } else { + $value = GETPOST($html_name, 'alphanohtml'); + } + } + if (preg_match('/^integer:/i', $field_info['type']) && $value == '-1') { + $value = ''; // This is an implicit foreign key field + } + if (!empty($field_info['foreignkey']) && $value == '-1') { + $value = ''; // This is an explicit foreign key field + } + + //var_dump($field_key.' '.$value.' '.$field_info['type']); + $field_value = $value; + if ($field_info['notnull'] > 0 && $field_value == '' && !is_null($field_info['default']) && $field_info['default'] == '(PROV)') { + $field_value = '(PROV)'; + } elseif ((!empty($field_info['required']) || $field_info['notnull'] > 0) && $field_value == '' && !empty($field_info['default'])) { + $field_value = dol_eval($field_info['default'], 1); + } + if ($field_info['notnull'] > 0 && $field_value == '' && is_null($field_info['default'])) { + $error++; + setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv($field_info['label'])), null, 'errors'); + } + $deprecation_options[$mode_key][$field_key] = $field_value; + + // Validation of fields values + if ($conf->global->MAIN_FEATURE_LEVEL >= 2 || !empty($conf->global->MAIN_ACTIVATE_VALIDATION_RESULT)) { + if (!$error && !empty($field_info['validate']) && is_callable(array($this, 'validateField'))) { + if (!$this->validateField($mode_info['fields'], $field_key, $value)) { + $error++; + } + } + } + } + } + // Unset not enabled modes + foreach ($this->deprecation_options_fields as $mode_key => $mode_info) { + if (!empty($mode_info['enabled_field'])) { + $info = explode(':', $mode_info['enabled_field']); + if ($deprecation_options[$info[0]][$info[1]] != $info[2]) { + unset($deprecation_options[$info[0]][$info[1]]); + } + } + } + $this->deprecation_options = $deprecation_options; + + if ($error) { + return -1; + } else { + return 1; + } + } + + /** + * Load deprecation options of a asset or a asset model + * + * @param int $asset_id Asset ID to set + * @param int $asset_model_id Asset model ID to set + * @return int <0 if KO, >0 if OK + */ + public function fetchDeprecationOptions($asset_id = 0, $asset_model_id = 0) + { + global $langs, $hookmanager; + dol_syslog(__METHOD__ . " asset_id=$asset_id, asset_model_id=$asset_model_id"); + + $error = 0; + $this->errors = array(); + $this->deprecation_options = array(); + + // Clean parameters + $asset_id = $asset_id > 0 ? $asset_id : 0; + $asset_model_id = $asset_model_id > 0 ? $asset_model_id : 0; + + if (!is_object($hookmanager)) { + require_once DOL_DOCUMENT_ROOT . '/core/class/hookmanager.class.php'; + $hookmanager = new HookManager($this->db); + } + + $hookmanager->initHooks(array('assetdepreciationoptionsdao')); + $parameters = array('asset_id' => $asset_id, 'asset_model_id' => $asset_model_id); + $reshook = $hookmanager->executeHooks('fetchDepreciationOptions', $parameters, $this); // Note that $action and $object may have been modified by some hooks + if (!empty($reshook)) { + return $reshook; + } + + // Check parameters + if (empty($asset_id) && empty($asset_model_id)) { + $this->errors[] = $langs->trans('AssetErrorAssetOrAssetModelIDNotProvide'); + $error++; + } + if ($error) { + dol_syslog(__METHOD__ . " Error check parameters: " . $this->errorsToString(), LOG_ERR); + return -1; + } + + $class_type = $asset_id > 0 ? 0 : 1; + $deprecation_options = array(); + foreach ($this->deprecation_options_fields as $mode_key => $mode_info) { + $this->setInfosForMode($mode_key, $class_type); + + $result = $this->fetchCommon(0, '', " AND " . ($asset_id > 0 ? " fk_asset = " . (int) $asset_id : " fk_asset_model = " . (int) $asset_model_id)); + if ($result < 0) { + $this->errors = array_merge(array($langs->trans('AssetErrorFetchDepreciationOptionsForMode', $mode_key) . ':'), $this->errors); + $error++; + } elseif ($result > 0) { + foreach ($this->fields as $field_key => $field_info) { + if (in_array($field_key, array('rowid', 'fk_asset', 'fk_asset_model', 'tms', 'fk_user_modif'))) continue; + $deprecation_options[$mode_key][$field_key] = $this->{$field_key}; + } + } + } + // Unset not enabled modes + foreach ($this->deprecation_options_fields as $mode_key => $mode_info) { + if (!empty($mode_info['enabled_field'])) { + $info = explode(':', $mode_info['enabled_field']); + if ($deprecation_options[$info[0]][$info[1]] != $info[2]) { + unset($deprecation_options[$info[0]][$info[1]]); + } + } + } + + if ($error) { + dol_syslog(__METHOD__ . " Error fetch accountancy codes: " . $this->errorsToString(), LOG_ERR); + return -1; + } else { + $this->deprecation_options = $deprecation_options; + return 1; + } + } + + /** + * get general depreciation info for a mode (used in depreciation card) + * + * @param string $mode Depreciation mode (economic, accelerated_depreciation, ...) + * @return array|int <0 if KO otherwise array with general depreciation info + */ + public function getGeneralDepreciationInfoForMode($mode) + { + global $hookmanager; + dol_syslog(__METHOD__ . " mode=$mode"); + + $this->errors = array(); + + // Clean parameters + $mode = strtolower(trim($mode)); + + if (!is_object($hookmanager)) { + require_once DOL_DOCUMENT_ROOT . '/core/class/hookmanager.class.php'; + $hookmanager = new HookManager($this->db); + } + + $hookmanager->initHooks(array('assetdepreciationoptionsdao')); + $parameters = array('mode' => $mode); + $reshook = $hookmanager->executeHooks('getGeneralDepreciationInfoForMode', $parameters, $this); // Note that $action and $object may have been modified by some hooks + if ($reshook < 0) { + return $reshook; + } elseif ($reshook > 0) { + return $hookmanager->resArray; + } + + $duration_type_list = $this->deprecation_options_fields[$mode]['fields']['duration_type']['arrayofkeyval']; + + return array( + 'base_depreciation_ht' => $this->deprecation_options[$mode]['amount_base_depreciation_ht'], + 'duration' => $this->deprecation_options[$mode]['duration'], + 'duration_type' => $duration_type_list[$this->deprecation_options[$mode]['duration_type']], + 'rate' => $this->getRate($mode), + ); + } + + /** + * Update deprecation options of a asset or a asset model + * + * @param User $user User making update + * @param int $asset_id Asset ID to set + * @param int $asset_model_id Asset model ID to set + * @param int $notrigger 1=disable trigger UPDATE (when called by create) + * @return int <0 if KO, >0 if OK + */ + public function updateDeprecationOptions($user, $asset_id = 0, $asset_model_id = 0, $notrigger = 0) + { + global $langs, $hookmanager; + dol_syslog(__METHOD__ . " user_id={$user->id}, asset_id=$asset_id, asset_model_id=$asset_model_id, notrigger=$notrigger"); + + $error = 0; + $this->errors = array(); + + // Clean parameters + $asset_id = $asset_id > 0 ? $asset_id : 0; + $asset_model_id = $asset_model_id > 0 ? $asset_model_id : 0; + + if (!is_object($hookmanager)) { + require_once DOL_DOCUMENT_ROOT . '/core/class/hookmanager.class.php'; + $hookmanager = new HookManager($this->db); + } + + $hookmanager->initHooks(array('assetdepreciationoptionsdao')); + $parameters = array('user' => $user, 'asset_id' => $asset_id, 'asset_model_id' => $asset_model_id); + $reshook = $hookmanager->executeHooks('updateDepreciationOptions', $parameters, $this); // Note that $action and $object may have been modified by some hooks + if (!empty($reshook)) { + return $reshook; + } + + // Check parameters + if (empty($asset_id) && empty($asset_model_id)) { + $this->errors[] = $langs->trans('AssetErrorAssetOrAssetModelIDNotProvide'); + $error++; + } + if ($error) { + dol_syslog(__METHOD__ . " Error check parameters: " . $this->errorsToString(), LOG_ERR); + return -1; + } + + $this->db->begin(); + + if ($asset_id > 0) { + $this->fk_asset = $asset_id; + $class_type = 0; + } else { + $this->fk_asset_model = $asset_model_id; + $class_type = 1; + } + $this->tms = dol_now(); + $this->fk_user_modif = $user->id; + + foreach ($this->deprecation_options_fields as $mode_key => $mode_info) { + // Delete old accountancy codes + $sql = "DELETE FROM " . MAIN_DB_PREFIX . $mode_info['table']; + $sql .= " WHERE " . ($asset_id > 0 ? " fk_asset = " . (int) $asset_id : " fk_asset_model = " . (int) $asset_model_id); + $resql = $this->db->query($sql); + if (!$resql) { + $this->errors[] = $langs->trans('AssetErrorDeleteDepreciationOptionsForMode', $mode_key) . ': ' . $this->db->lasterror(); + $error++; + } + + if (!$error && !empty($this->deprecation_options[$mode_key])) { + if (!empty($mode_info['enabled_field'])) { + $info = explode(':', $mode_info['enabled_field']); + if ($this->deprecation_options[$info[0]][$info[1]] != $info[2]) { + continue; + } + } + + $this->setInfosForMode($mode_key, $class_type); + + $result = $this->createCommon($user, 1); + if ($result < 0) { + $this->errors = array_merge(array($langs->trans('AssetErrorInsertDepreciationOptionsForMode', $mode_key) . ':'), $this->errors); + $error++; + } + } + } + + if (!$error && $this->fk_asset > 0) { + // Calculation of depreciation lines (reversal and future) + require_once DOL_DOCUMENT_ROOT . '/asset/class/asset.class.php'; + $asset = new Asset($this->db); + $result = $asset->fetch($this->fk_asset); + if ($result > 0) $result = $asset->calculationDepreciation(); + if ($result < 0) { + $this->errors[] = $langs->trans('AssetErrorCalculationDepreciationLines'); + $this->errors[] = $asset->errorsToString(); + $error++; + } + } + + if (!$error && !$notrigger) { + // Call trigger + $result = $this->call_trigger('ASSET_DEPRECIATION_OPTIONS_MODIFY', $user); + if ($result < 0) { + $error++; + } + // End call triggers + } + + if ($error) { + $this->db->rollback(); + return -1; + } else { + $this->db->commit(); + return 1; + } + } + + /** + * Get rate + * + * @param string $mode Depreciation mode (economic, accelerated_depreciation, ...) + * @return string Rate of the provided mode option + */ + public function getRate($mode) + { + $duration = $this->deprecation_options[$mode]["duration"] > 0 ? $this->deprecation_options[$mode]["duration"] : 0; + $duration_type = $this->deprecation_options[$mode]["duration_type"] > 0 ? $this->deprecation_options[$mode]["duration_type"] : 0; + + return price(price2num($duration > 0 ? (100 * ($duration_type == 1 ? 12 : 1) / $duration) : 0, 2)); + } +} diff --git a/htdocs/asset/class/assetmodel.class.php b/htdocs/asset/class/assetmodel.class.php new file mode 100644 index 00000000000..eae7b5d0fde --- /dev/null +++ b/htdocs/asset/class/assetmodel.class.php @@ -0,0 +1,822 @@ + + * Copyright (C) 2021 Open-Dsi + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file class/assetmodel.class.php + * \ingroup asset + * \brief This file is a CRUD class file for AssetModel (Create/Read/Update/Delete) + */ + +// Put here all includes required by your class file +require_once DOL_DOCUMENT_ROOT.'/core/class/commonobject.class.php'; +//require_once DOL_DOCUMENT_ROOT . '/societe/class/societe.class.php'; +//require_once DOL_DOCUMENT_ROOT . '/product/class/product.class.php'; + +/** + * Class for AssetModel + */ +class AssetModel extends CommonObject +{ + /** + * @var string ID of module. + */ + public $module = 'asset'; + + /** + * @var string ID to identify managed object. + */ + public $element = 'assetmodel'; + + /** + * @var string Name of table without prefix where object is stored. This is also the key used for extrafields management. + */ + public $table_element = 'asset_model'; + + /** + * @var int Does this object support multicompany module ? + * 0=No test on entity, 1=Test with field entity, 'field@table'=Test with link by field@table + */ + public $ismultientitymanaged = 1; + + /** + * @var int Does object support extrafields ? 0=No, 1=Yes + */ + public $isextrafieldmanaged = 1; + + /** + * @var string String with name of icon for assetmodel. Must be the part after the 'object_' into object_assetmodel.png + */ + public $picto = 'asset'; + + + const STATUS_DRAFT = 0; + const STATUS_VALIDATED = 1; + const STATUS_CANCELED = 9; + + + /** + * 'type' field format ('integer', 'integer:ObjectClass:PathToClass[:AddCreateButtonOrNot[:Filter[:Sortfield]]]', 'sellist:TableName:LabelFieldName[:KeyFieldName[:KeyFieldParent[:Filter[:Sortfield]]]]', 'varchar(x)', 'double(24,8)', 'real', 'price', 'text', 'text:none', 'html', 'date', 'datetime', 'timestamp', 'duration', 'mail', 'phone', 'url', 'password') + * Note: Filter can be a string like "(t.ref:like:'SO-%') or (t.date_creation:<:'20160101') or (t.nature:is:NULL)" + * 'label' the translation key. + * 'picto' is code of a picto to show before value in forms + * 'enabled' is a condition when the field must be managed (Example: 1 or '$conf->global->MY_SETUP_PARAM) + * 'position' is the sort order of field. + * 'notnull' is set to 1 if not null in database. Set to -1 if we must set data to null if empty ('' or 0). + * 'visible' says if field is visible in list (Examples: 0=Not visible, 1=Visible on list and create/update/view forms, 2=Visible on list only, 3=Visible on create/update/view form only (not list), 4=Visible on list and update/view form only (not create). 5=Visible on list and view only (not create/not update). Using a negative value means field is not shown by default on list but can be selected for viewing) + * 'noteditable' says if field is not editable (1 or 0) + * 'default' is a default value for creation (can still be overwrote by the Setup of Default Values if field is editable in creation form). Note: If default is set to '(PROV)' and field is 'ref', the default value will be set to '(PROVid)' where id is rowid when a new record is created. + * 'index' if we want an index in database. + * 'foreignkey'=>'tablename.field' if the field is a foreign key (it is recommanded to name the field fk_...). + * 'searchall' is 1 if we want to search in this field when making a search from the quick search button. + * 'isameasure' must be set to 1 or 2 if field can be used for measure. Field type must be summable like integer or double(24,8). Use 1 in most cases, or 2 if you don't want to see the column total into list (for example for percentage) + * 'css' and 'cssview' and 'csslist' is the CSS style to use on field. 'css' is used in creation and update. 'cssview' is used in view mode. 'csslist' is used for columns in lists. For example: 'css'=>'minwidth300 maxwidth500 widthcentpercentminusx', 'cssview'=>'wordbreak', 'csslist'=>'tdoverflowmax200' + * 'help' is a 'TranslationString' to use to show a tooltip on field. You can also use 'TranslationString:keyfortooltiponlick' for a tooltip on click. + * 'showoncombobox' if value of the field must be visible into the label of the combobox that list record + * 'disabled' is 1 if we want to have the field locked by a 'disabled' attribute. In most cases, this is never set into the definition of $fields into class, but is set dynamically by some part of code. + * 'arrayofkeyval' to set a list of values if type is a list of predefined values. For example: array("0"=>"Draft","1"=>"Active","-1"=>"Cancel"). Note that type can be 'integer' or 'varchar' + * 'autofocusoncreate' to have field having the focus on a create form. Only 1 field should have this property set to 1. + * 'comment' is not used. You can store here any text of your choice. It is not used by application. + * 'validate' is 1 if need to validate with $this->validateField() + * 'copytoclipboard' is 1 or 2 to allow to add a picto to copy value into clipboard (1=picto after label, 2=picto after value) + * + * Note: To have value dynamic, you can set value to 0 in definition and edit the value on the fly into the constructor. + */ + + /** + * @var array Array with all fields and their property. Do not use it as a static var. It may be modified by constructor. + */ + public $fields=array( + 'rowid' => array('type'=>'integer', 'label'=>'TechnicalID', 'enabled'=>'1', 'position'=>1, 'notnull'=>1, 'visible'=>0, 'noteditable'=>'1', 'index'=>1, 'css'=>'left', 'comment'=>"Id"), + 'ref' => array('type'=>'varchar(128)', 'label'=>'Ref', 'enabled'=>'1', 'position'=>20, 'notnull'=>1, 'visible'=>1, 'index'=>1, 'searchall'=>1, 'showoncombobox'=>'1', 'validate'=>'1'), + 'label' => array('type'=>'varchar(255)', 'label'=>'Label', 'enabled'=>'1', 'position'=>30, 'notnull'=>1, 'visible'=>1, 'searchall'=>1, 'css'=>'minwidth300', 'cssview'=>'wordbreak', 'showoncombobox'=>'2', 'validate'=>'1',), + 'asset_type' => array('type'=>'smallint', 'label'=>'AssetType', 'enabled'=>'1', 'position'=>40, 'notnull'=>1, 'visible'=>1, 'arrayofkeyval'=>array('0'=>'AssetTypeIntangible', '1'=>'AssetTypeTangible', '2'=>'AssetTypeInProgress', '3'=>'AssetTypeFinancial'), 'validate'=>'1',), + 'fk_pays' =>array('type'=>'integer:Ccountry:core/class/ccountry.class.php', 'label'=>'Country', 'enabled'=>1, 'visible'=>1, 'position'=>50), + 'note_public' => array('type'=>'html', 'label'=>'NotePublic', 'enabled'=>'1', 'position'=>300, 'notnull'=>0, 'visible'=>0, 'validate'=>'1',), + 'note_private' => array('type'=>'html', 'label'=>'NotePrivate', 'enabled'=>'1', 'position'=>301, 'notnull'=>0, 'visible'=>0, 'validate'=>'1',), + 'date_creation' => array('type'=>'datetime', 'label'=>'DateCreation', 'enabled'=>'1', 'position'=>500, 'notnull'=>1, 'visible'=>-2,), + 'tms' => array('type'=>'timestamp', 'label'=>'DateModification', 'enabled'=>'1', 'position'=>501, 'notnull'=>0, 'visible'=>-2,), + 'fk_user_creat' => array('type'=>'integer:User:user/class/user.class.php', 'label'=>'UserAuthor', 'enabled'=>'1', 'position'=>510, 'notnull'=>1, 'visible'=>-2, 'foreignkey'=>'user.rowid',), + 'fk_user_modif' => array('type'=>'integer:User:user/class/user.class.php', 'label'=>'UserModif', 'enabled'=>'1', 'position'=>511, 'notnull'=>-1, 'visible'=>-2,), + 'import_key' => array('type'=>'varchar(14)', 'label'=>'ImportId', 'enabled'=>'1', 'position'=>1000, 'notnull'=>-1, 'visible'=>-2,), + 'status' => array('type'=>'smallint', 'label'=>'Status', 'enabled'=>'1', 'position'=>1000, 'notnull'=>1, 'default'=>'0', 'visible'=>2, 'index'=>1, 'arrayofkeyval'=>array('0'=>'Draft', '1'=>'Enabled', '9'=>'Disabled'), 'validate'=>'1',), + ); + public $rowid; + public $ref; + public $label; + public $asset_type; + public $note_public; + public $note_private; + public $date_creation; + public $tms; + public $fk_user_creat; + public $fk_user_modif; + public $last_main_doc; + public $import_key; + public $model_pdf; + public $status; + + // /** + // * @var string Field with ID of parent key if this object has a parent + // */ + // public $fk_element = 'fk_assetmodel'; + // /** + // * @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. + // * If name matches '@ClassNAme:FilePathClass;ParentFkFieldName' it will + // * call method deleteByParentField(parentId, ParentFkFieldName) to fetch and delete child object + // */ + // protected $childtablesoncascade = array('asset_assetmodeldet'); + + + /** + * Constructor + * + * @param DoliDb $db Database handler + */ + public function __construct(DoliDB $db) + { + global $conf, $langs; + + $this->db = $db; + + if (empty($conf->global->MAIN_SHOW_TECHNICAL_ID) && isset($this->fields['rowid'])) { + $this->fields['rowid']['visible'] = 0; + } + if (empty($conf->multicompany->enabled) && isset($this->fields['entity'])) { + $this->fields['entity']['enabled'] = 0; + } + + // Unset fields that are disabled + foreach ($this->fields as $key => $val) { + if (isset($val['enabled']) && empty($val['enabled'])) { + unset($this->fields[$key]); + } + } + + // Translate some data of arrayofkeyval + if (is_object($langs)) { + foreach ($this->fields as $key => $val) { + if (!empty($val['arrayofkeyval']) && is_array($val['arrayofkeyval'])) { + foreach ($val['arrayofkeyval'] as $key2 => $val2) { + $this->fields[$key]['arrayofkeyval'][$key2] = $langs->trans($val2); + } + } + } + } + } + + /** + * Create object into database + * + * @param User $user User that creates + * @param bool $notrigger false=launch triggers after, true=disable triggers + * @return int <0 if KO, Id of created object if OK + */ + public function create(User $user, $notrigger = false) + { + $resultcreate = $this->createCommon($user, $notrigger); + + return $resultcreate; + } + + /** + * Clone an object into another one + * + * @param User $user User that creates + * @param int $fromid Id of object to clone + * @return mixed New object created, <0 if KO + */ + public function createFromClone(User $user, $fromid) + { + global $langs, $extrafields; + $error = 0; + + dol_syslog(__METHOD__, LOG_DEBUG); + + $object = new self($this->db); + + $this->db->begin(); + + // Load source object + $result = $object->fetchCommon($fromid); + if ($result > 0 && !empty($object->table_element_line)) { + $object->fetchLines(); + } + + // get lines so they will be clone + //foreach($this->lines as $line) + // $line->fetch_optionals(); + + // Reset some properties + unset($object->id); + unset($object->fk_user_creat); + unset($object->import_key); + + // Clear fields + if (property_exists($object, 'ref')) { + $object->ref = empty($this->fields['ref']['default']) ? "Copy_Of_".$object->ref : $this->fields['ref']['default']; + } + if (property_exists($object, 'label')) { + $object->label = empty($this->fields['label']['default']) ? $langs->trans("CopyOf")." ".$object->label : $this->fields['label']['default']; + } + if (property_exists($object, 'status')) { + $object->status = self::STATUS_DRAFT; + } + if (property_exists($object, 'date_creation')) { + $object->date_creation = dol_now(); + } + if (property_exists($object, 'date_modification')) { + $object->date_modification = null; + } + // ... + // Clear extrafields that are unique + if (is_array($object->array_options) && count($object->array_options) > 0) { + $extrafields->fetch_name_optionals_label($this->table_element); + foreach ($object->array_options as $key => $option) { + $shortkey = preg_replace('/options_/', '', $key); + if (!empty($extrafields->attributes[$this->table_element]['unique'][$shortkey])) { + //var_dump($key); var_dump($clonedObj->array_options[$key]); exit; + unset($object->array_options[$key]); + } + } + } + + // Create clone + $object->context['createfromclone'] = 'createfromclone'; + $result = $object->createCommon($user); + if ($result < 0) { + $error++; + $this->error = $object->error; + $this->errors = $object->errors; + } + + if (!$error) { + // copy internal contacts + if ($this->copy_linked_contact($object, 'internal') < 0) { + $error++; + } + } + + if (!$error) { + // copy external contacts if same company + if (property_exists($this, 'fk_soc') && $this->fk_soc == $object->socid) { + if ($this->copy_linked_contact($object, 'external') < 0) { + $error++; + } + } + } + + unset($object->context['createfromclone']); + + // End + if (!$error) { + $this->db->commit(); + return $object; + } else { + $this->db->rollback(); + return -1; + } + } + + /** + * Load object in memory from the database + * + * @param int $id Id object + * @param string $ref Ref + * @return int <0 if KO, 0 if not found, >0 if OK + */ + public function fetch($id, $ref = null) + { + $result = $this->fetchCommon($id, $ref); + if ($result > 0 && !empty($this->table_element_line)) { + $this->fetchLines(); + } + return $result; + } + + /** + * Load object lines in memory from the database + * + * @return int <0 if KO, 0 if not found, >0 if OK + */ + public function fetchLines() + { + $this->lines = array(); + + return 1; + } + + + /** + * Load list of objects in memory from the database. + * + * @param string $sortorder Sort Order + * @param string $sortfield Sort field + * @param int $limit limit + * @param int $offset Offset + * @param array $filter Filter array. Example array('field'=>'valueforlike', 'customurl'=>...) + * @param string $filtermode Filter mode (AND or OR) + * @return array|int int <0 if KO, array of pages if OK + */ + public function fetchAll($sortorder = '', $sortfield = '', $limit = 0, $offset = 0, array $filter = array(), $filtermode = 'AND') + { + global $conf; + + dol_syslog(__METHOD__, LOG_DEBUG); + + $records = array(); + + $sql = "SELECT "; + $sql .= $this->getFieldList('t'); + $sql .= " FROM ".MAIN_DB_PREFIX.$this->table_element." as t"; + if (isset($this->ismultientitymanaged) && $this->ismultientitymanaged == 1) { + $sql .= " WHERE t.entity IN (".getEntity($this->table_element).")"; + } else { + $sql .= " WHERE 1 = 1"; + } + // Manage filter + $sqlwhere = array(); + if (count($filter) > 0) { + foreach ($filter as $key => $value) { + if ($key == 't.rowid') { + $sqlwhere[] = $key." = ".((int) $value); + } elseif (in_array($this->fields[$key]['type'], array('date', 'datetime', 'timestamp'))) { + $sqlwhere[] = $key." = '".$this->db->idate($value)."'"; + } elseif ($key == 'customsql') { + $sqlwhere[] = $value; + } elseif (strpos($value, '%') === false) { + $sqlwhere[] = $key." IN (".$this->db->sanitize($this->db->escape($value)).")"; + } else { + $sqlwhere[] = $key." LIKE '%".$this->db->escape($value)."%'"; + } + } + } + if (count($sqlwhere) > 0) { + $sql .= " AND (".implode(" ".$filtermode." ", $sqlwhere).")"; + } + + if (!empty($sortfield)) { + $sql .= $this->db->order($sortfield, $sortorder); + } + if (!empty($limit)) { + $sql .= $this->db->plimit($limit, $offset); + } + + $resql = $this->db->query($sql); + if ($resql) { + $num = $this->db->num_rows($resql); + $i = 0; + while ($i < ($limit ? min($limit, $num) : $num)) { + $obj = $this->db->fetch_object($resql); + + $record = new self($this->db); + $record->setVarsFromFetchObj($obj); + + $records[$record->id] = $record; + + $i++; + } + $this->db->free($resql); + + return $records; + } else { + $this->errors[] = 'Error '.$this->db->lasterror(); + dol_syslog(__METHOD__.' '.join(',', $this->errors), LOG_ERR); + + return -1; + } + } + + /** + * Update object into database + * + * @param User $user User that modifies + * @param bool $notrigger false=launch triggers after, true=disable triggers + * @return int <0 if KO, >0 if OK + */ + public function update(User $user, $notrigger = false) + { + return $this->updateCommon($user, $notrigger); + } + + /** + * Delete object in database + * + * @param User $user User that deletes + * @param bool $notrigger false=launch triggers after, true=disable triggers + * @return int <0 if KO, >0 if OK + */ + public function delete(User $user, $notrigger = false) + { + return $this->deleteCommon($user, $notrigger); + //return $this->deleteCommon($user, $notrigger, 1); + } + + + /** + * Validate object + * + * @param User $user User making status change + * @param int $notrigger 1=Does not execute triggers, 0= execute triggers + * @return int <=0 if OK, 0=Nothing done, >0 if KO + */ + public function validate($user, $notrigger = 0) + { + global $conf, $langs; + + $error = 0; + + // Protection + if ($this->status == self::STATUS_VALIDATED) { + dol_syslog(get_class($this) . "::validate action abandonned: already validated", LOG_WARNING); + return 0; + } + + $now = dol_now(); + + $this->db->begin(); + + // Validate + $sql = "UPDATE " . MAIN_DB_PREFIX . $this->table_element; + $sql .= " SET status = " . self::STATUS_VALIDATED; + if (!empty($this->fields['date_validation'])) { + $sql .= ", date_validation = '" . $this->db->idate($now) . "'"; + } + if (!empty($this->fields['fk_user_valid'])) { + $sql .= ", fk_user_valid = " . ((int) $user->id); + } + $sql .= " WHERE rowid = " . ((int) $this->id); + + dol_syslog(get_class($this) . "::validate()", LOG_DEBUG); + $resql = $this->db->query($sql); + if (!$resql) { + dol_print_error($this->db); + $this->error = $this->db->lasterror(); + $error++; + } + + if (!$error && !$notrigger) { + // Call trigger + $result = $this->call_trigger('ASSETMODEL_VALIDATE', $user); + if ($result < 0) { + $error++; + } + // End call triggers + } + + // Set new ref and current status + if (!$error) { + $this->status = self::STATUS_VALIDATED; + } + + if (!$error) { + $this->db->commit(); + return 1; + } else { + $this->db->rollback(); + return -1; + } + } + + + /** + * Set draft status + * + * @param User $user Object user that modify + * @param int $notrigger 1=Does not execute triggers, 0=Execute triggers + * @return int <0 if KO, >0 if OK + */ + public function setDraft($user, $notrigger = 0) + { + // Protection + if ($this->status <= self::STATUS_DRAFT) { + return 0; + } + + return $this->setStatusCommon($user, self::STATUS_DRAFT, $notrigger, 'ASSETMODEL_UNVALIDATE'); + } + + /** + * Set cancel status + * + * @param User $user Object user that modify + * @param int $notrigger 1=Does not execute triggers, 0=Execute triggers + * @return int <0 if KO, 0=Nothing done, >0 if OK + */ + public function cancel($user, $notrigger = 0) + { + // Protection + if ($this->status != self::STATUS_VALIDATED) { + return 0; + } + + return $this->setStatusCommon($user, self::STATUS_CANCELED, $notrigger, 'ASSETMODEL_CANCEL'); + } + + /** + * Set back to validated status + * + * @param User $user Object user that modify + * @param int $notrigger 1=Does not execute triggers, 0=Execute triggers + * @return int <0 if KO, 0=Nothing done, >0 if OK + */ + public function reopen($user, $notrigger = 0) + { + // Protection + if ($this->status != self::STATUS_CANCELED) { + return 0; + } + + return $this->setStatusCommon($user, self::STATUS_VALIDATED, $notrigger, 'ASSETMODEL_REOPEN'); + } + + /** + * Return a link to the object card (with optionaly the picto) + * + * @param int $withpicto Include picto in link (0=No picto, 1=Include picto into link, 2=Only picto) + * @param string $option On what the link point to ('nolink', ...) + * @param int $notooltip 1=Disable tooltip + * @param string $morecss Add more css on link + * @param int $save_lastsearch_value -1=Auto, 0=No save of lastsearch_values when clicking, 1=Save lastsearch_values whenclicking + * @return string String with URL + */ + public function getNomUrl($withpicto = 0, $option = '', $notooltip = 0, $morecss = '', $save_lastsearch_value = -1) + { + global $conf, $langs, $hookmanager; + + if (!empty($conf->dol_no_mouse_hover)) { + $notooltip = 1; // Force disable tooltips + } + + $result = ''; + + $label = img_picto('', $this->picto).' '.$langs->trans("AssetModel").''; + if (isset($this->status)) { + $label .= ' '.$this->getLibStatut(5); + } + $label .= '
    '; + $label .= ''.$langs->trans('Ref').': '.$this->ref; + + $url = dol_buildpath('/asset/model/card.php', 1).'?id='.$this->id; + + if ($option != 'nolink') { + // Add param to save lastsearch_values or not + $add_save_lastsearch_values = ($save_lastsearch_value == 1 ? 1 : 0); + if ($save_lastsearch_value == -1 && preg_match('/list\.php/', $_SERVER["PHP_SELF"])) { + $add_save_lastsearch_values = 1; + } + if ($add_save_lastsearch_values) { + $url .= '&save_lastsearch_values=1'; + } + } + + $linkclose = ''; + if (empty($notooltip)) { + if (!empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER)) { + $label = $langs->trans("ShowAssetModel"); + $linkclose .= ' alt="'.dol_escape_htmltag($label, 1).'"'; + } + $linkclose .= ' title="'.dol_escape_htmltag($label, 1).'"'; + $linkclose .= ' class="classfortooltip'.($morecss ? ' '.$morecss : '').'"'; + } else { + $linkclose = ($morecss ? ' class="'.$morecss.'"' : ''); + } + + if ($option == 'nolink') { + $linkstart = ''; + if ($option == 'nolink') { + $linkend = ''; + } else { + $linkend = ''; + } + + $result .= $linkstart; + + if (empty($this->showphoto_on_popup)) { + if ($withpicto) { + $result .= img_object(($notooltip ? '' : $label), ($this->picto ? $this->picto : 'generic'), ($notooltip ? (($withpicto != 2) ? 'class="paddingright"' : '') : 'class="'.(($withpicto != 2) ? 'paddingright ' : '').'classfortooltip"'), 0, 0, $notooltip ? 0 : 1); + } + } else { + if ($withpicto) { + require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; + + list($class, $module) = explode('@', $this->picto); + $upload_dir = $conf->$module->multidir_output[$conf->entity]."/$class/".dol_sanitizeFileName($this->ref); + $filearray = dol_dir_list($upload_dir, "files"); + $filename = $filearray[0]['name']; + if (!empty($filename)) { + $pospoint = strpos($filearray[0]['name'], '.'); + + $pathtophoto = $class.'/'.$this->ref.'/thumbs/'.substr($filename, 0, $pospoint).'_mini'.substr($filename, $pospoint); + if (empty($conf->global->{strtoupper($module.'_'.$class).'_FORMATLISTPHOTOSASUSERS'})) { + $result .= '
    No photo
    '; + } else { + $result .= '
    No photo
    '; + } + + $result .= ''; + } else { + $result .= img_object(($notooltip ? '' : $label), ($this->picto ? $this->picto : 'generic'), ($notooltip ? (($withpicto != 2) ? 'class="paddingright"' : '') : 'class="'.(($withpicto != 2) ? 'paddingright ' : '').'classfortooltip"'), 0, 0, $notooltip ? 0 : 1); + } + } + } + + if ($withpicto != 2) { + $result .= $this->ref; + } + + $result .= $linkend; + //if ($withpicto != 2) $result.=(($addlabel && $this->label) ? $sep . dol_trunc($this->label, ($addlabel > 1 ? $addlabel : 0)) : ''); + + global $action, $hookmanager; + $hookmanager->initHooks(array('assetmodeldao')); + $parameters = array('id'=>$this->id, 'getnomurl'=>$result); + $reshook = $hookmanager->executeHooks('getNomUrl', $parameters, $this, $action); // Note that $action and $object may have been modified by some hooks + if ($reshook > 0) { + $result = $hookmanager->resPrint; + } else { + $result .= $hookmanager->resPrint; + } + + return $result; + } + + /** + * Return the label of the status + * + * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto + * @return string Label of status + */ + public function getLabelStatus($mode = 0) + { + return $this->LibStatut($this->status, $mode); + } + + /** + * Return the label of the status + * + * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto + * @return string Label of status + */ + public function getLibStatut($mode = 0) + { + return $this->LibStatut($this->status, $mode); + } + + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps + /** + * Return the status + * + * @param int $status Id status + * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto + * @return string Label of status + */ + public function LibStatut($status, $mode = 0) + { + // phpcs:enable + if (empty($this->labelStatus) || empty($this->labelStatusShort)) { + global $langs; + //$langs->load("asset@asset"); + $this->labelStatus[self::STATUS_DRAFT] = $langs->transnoentitiesnoconv('Draft'); + $this->labelStatus[self::STATUS_VALIDATED] = $langs->transnoentitiesnoconv('Enabled'); + $this->labelStatus[self::STATUS_CANCELED] = $langs->transnoentitiesnoconv('Disabled'); + $this->labelStatusShort[self::STATUS_DRAFT] = $langs->transnoentitiesnoconv('Draft'); + $this->labelStatusShort[self::STATUS_VALIDATED] = $langs->transnoentitiesnoconv('Enabled'); + $this->labelStatusShort[self::STATUS_CANCELED] = $langs->transnoentitiesnoconv('Disabled'); + } + + $statusType = 'status'.$status; + //if ($status == self::STATUS_VALIDATED) $statusType = 'status1'; + if ($status == self::STATUS_CANCELED) { + $statusType = 'status6'; + } + + return dolGetStatus($this->labelStatus[$status], $this->labelStatusShort[$status], '', $statusType, $mode); + } + + /** + * Load the info information in the object + * + * @param int $id Id of object + * @return void + */ + public function info($id) + { + $sql = "SELECT rowid, date_creation as datec, tms as datem,"; + $sql .= " fk_user_creat, fk_user_modif"; + $sql .= " FROM ".MAIN_DB_PREFIX.$this->table_element." as t"; + $sql .= " WHERE t.rowid = ".((int) $id); + + $result = $this->db->query($sql); + if ($result) { + if ($this->db->num_rows($result)) { + $obj = $this->db->fetch_object($result); + $this->id = $obj->rowid; + if ($obj->fk_user_author) { + $cuser = new User($this->db); + $cuser->fetch($obj->fk_user_author); + $this->user_creation = $cuser; + } + + if ($obj->fk_user_valid) { + $vuser = new User($this->db); + $vuser->fetch($obj->fk_user_valid); + $this->user_validation = $vuser; + } + + if ($obj->fk_user_cloture) { + $cluser = new User($this->db); + $cluser->fetch($obj->fk_user_cloture); + $this->user_cloture = $cluser; + } + + $this->date_creation = $this->db->jdate($obj->datec); + $this->date_modification = $this->db->jdate($obj->datem); + $this->date_validation = $this->db->jdate($obj->datev); + } + + $this->db->free($result); + } else { + dol_print_error($this->db); + } + } + + /** + * Initialise object with example values + * Id must be 0 if object instance is a specimen + * + * @return void + */ + public function initAsSpecimen() + { + // Set here init that are not commonf fields + // $this->property1 = ... + // $this->property2 = ... + + $this->initAsSpecimenCommon(); + } + + /** + * Create an array of lines + * + * @return array|int array of lines if OK, <0 if KO + */ + public function getLinesArray() + { + $this->lines = array(); + + return $this->lines; + } + + /** + * Action executed by scheduler + * CAN BE A CRON TASK. In such a case, parameters come from the schedule job setup field 'Parameters' + * Use public function doScheduledJob($param1, $param2, ...) to get parameters + * + * @return int 0 if OK, <>0 if KO (this function is used also by cron so only 0 is OK) + */ + public function doScheduledJob() + { + global $conf, $langs; + + //$conf->global->SYSLOG_FILE = 'DOL_DATA_ROOT/dolibarr_mydedicatedlofile.log'; + + $error = 0; + $this->output = ''; + $this->error = ''; + + dol_syslog(__METHOD__, LOG_DEBUG); + + $now = dol_now(); + + $this->db->begin(); + + // ... + + $this->db->commit(); + + return $error; + } +} diff --git a/htdocs/asset/depreciation.php b/htdocs/asset/depreciation.php new file mode 100644 index 00000000000..8f3547d81fb --- /dev/null +++ b/htdocs/asset/depreciation.php @@ -0,0 +1,199 @@ + + * Copyright (C) 2018 Alexandre Spangaro + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file htdocs/asset/depreciation.php + * \ingroup asset + * \brief Card with depreciation on Asset + */ + +require '../main.inc.php'; +require_once DOL_DOCUMENT_ROOT . '/core/lib/asset.lib.php'; +require_once DOL_DOCUMENT_ROOT . '/asset/class/asset.class.php'; +require_once DOL_DOCUMENT_ROOT . '/asset/class/assetdepreciationoptions.class.php'; + +// Load translation files required by the page +$langs->loadLangs(array("assets", "companies")); + +// Get parameters +$id = GETPOST('id', 'int'); +$ref = GETPOST('ref', 'alpha'); +$action = GETPOST('action', 'aZ09'); +$cancel = GETPOST('cancel', 'aZ09'); +$backtopage = GETPOST('backtopage', 'alpha'); + +// Initialize technical objects +$object = new Asset($db); +$assetdepreciationoptions = new AssetDepreciationOptions($db); +$extrafields = new ExtraFields($db); +$diroutputmassaction = $conf->asset->dir_output.'/temp/massgeneration/'.$user->id; +$hookmanager->initHooks(array('assetdepreciation', 'globalcard')); // Note that conf->hooks_modules contains array +// Fetch optionals attributes and labels +$extrafields->fetch_name_optionals_label($object->table_element); + +// Load object +include DOL_DOCUMENT_ROOT . '/core/actions_fetchobject.inc.php'; // Must be include, not include_once // Must be include, not include_once. Include fetch and fetch_thirdparty but not fetch_optionals +if ($id > 0 || !empty($ref)) { + $upload_dir = $conf->asset->multidir_output[$object->entity] . "/" . $object->id; +} + +// Security check (enable the most restrictive one) +if ($user->socid > 0) accessforbidden(); +$isdraft = (($object->status == $object::STATUS_DRAFT) ? 1 : 0); +restrictedArea($user, $object->element, $object->id, $object->table_element, '', 'fk_soc', 'rowid', $isdraft); +if (empty($conf->asset->enabled)) accessforbidden(); +if (!empty($object->not_depreciated)) accessforbidden(); + +$object->asset_depreciation_options = &$assetdepreciationoptions; +$result = $assetdepreciationoptions->fetchDeprecationOptions($object->id); +if ($result < 0) { + setEventMessages($assetdepreciationoptions->error, $assetdepreciationoptions->errors, 'errors'); +} +$result = $object->fetchDepreciationLines(); +if ($result < 0) { + setEventMessages($object->error, $object->errors, 'errors'); +} + + +/* + * Actions + */ + +$reshook = $hookmanager->executeHooks('doActions', array(), $object, $action); // Note that $action and $object may have been modified by some hooks +if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); +} +if (empty($reshook)) { +} + + +/* + * View + */ + +$form = new Form($db); + +$help_url = ''; +llxHeader('', $langs->trans('Asset'), $help_url); + +if ($id > 0 || !empty($ref)) { + $head = assetPrepareHead($object); + print dol_get_fiche_head($head, 'depreciation', $langs->trans("Asset"), -1, $object->picto); + + // Object card + // ------------------------------------------------------------ + $linkback = '' . $langs->trans("BackToList") . ''; + + $morehtmlref = '
    '; + $morehtmlref .= '
    '; + + dol_banner_tab($object, 'ref', $linkback, 1, 'ref', 'ref', $morehtmlref); + + print '
    '; + print '
    '; + print '
    '; + + print dol_get_fiche_end(); + + $parameters = array(); + $reshook = $hookmanager->executeHooks('listAssetDeprecation', $parameters, $object, $action); + print $hookmanager->resPrint; + if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); + } elseif (empty($reshook)) { + $bookkeeping_icon = ''; + $future_icon = ''; + $now = dol_now(); + + foreach ($assetdepreciationoptions->deprecation_options_fields as $mode_key => $fields) { + $lines = $object->depreciation_lines[$mode_key]; + if (!empty($lines)) { + $mode_info = $assetdepreciationoptions->deprecation_options_fields[$mode_key]; + $depreciation_info = $assetdepreciationoptions->getGeneralDepreciationInfoForMode($mode_key); + + print load_fiche_titre($langs->trans($mode_info['label']), '', ''); + + // Depreciation general info + //--------------------------------- + print '
    '; + print '
    '; + print '
    '; + print '' . "\n"; + print ''; + print ''; + print '
    ' . $langs->trans('AssetBaseDepreciationHT') . '' . price($depreciation_info['base_depreciation_ht']) . '
    ' . $langs->trans('AssetDepreciationBeginDate') . '' . dol_print_date($object->date_start > $object->date_acquisition ? $object->date_start : $object->date_acquisition, 'day') . '
    '; + + // We close div and reopen for second column + print '
    '; + print '
    '; + + print '
    '; + print ''; + print ''; + print ''; + print '
    ' . $langs->trans('AssetDepreciationDuration') . '' . $depreciation_info['duration'] . ' ( ' . $depreciation_info['duration_type'] . ' )
    ' . $langs->trans('AssetDepreciationRate') . '' . $depreciation_info['rate'] . '
    '; + print '
    '; + print '
    '; + print '
    '; + + // Depreciation lines + //--------------------------------- + print '
    '; + print '
    '; + print ''; + + print ''; + print ''; + print ''; + print ''; + print ''; + print ''; + print ''; + print ''; + + if (empty($lines)) { + print ''; + } else { + foreach ($lines as $line) { + print ''; + print ''; + print ''; + print ''; + print ''; + print ''; + print ''; + print "\n"; + } + } + + print '
    ' . $langs->trans("Ref") . '' . $langs->trans("AssetDepreciationDate") . '' . $langs->trans("AssetDepreciationHT") . '' . $langs->trans("AssetCumulativeDepreciationHT") . '' . $langs->trans("AssetResidualHT") . '
    ' . $langs->trans("None") . '
    ' . ($line['bookkeeping'] ? $bookkeeping_icon : ($line['depreciation_date'] > $now ? $future_icon : '')) . '' . (empty($line['ref']) ? $langs->trans('AssetDepreciationReversal') : $line['ref']) . '' . dol_print_date($line['depreciation_date'], 'day') . ''; + print price($line['depreciation_ht']); + print ''; + print price($line['cumulative_depreciation_ht']); + print ''; + print price(price2num($depreciation_info['base_depreciation_ht'] - $line['cumulative_depreciation_ht'], 'MT')); + print '
    '; + print '
    '; + } + } + } +} + +// End of page +llxFooter(); +$db->close(); diff --git a/htdocs/asset/depreciation_options.php b/htdocs/asset/depreciation_options.php new file mode 100644 index 00000000000..ba5719705dc --- /dev/null +++ b/htdocs/asset/depreciation_options.php @@ -0,0 +1,190 @@ + + * Copyright (C) 2018 Alexandre Spangaro + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file htdocs/asset/depreciation_options.php + * \ingroup asset + * \brief Card with depreciation options on Asset + */ + +require '../main.inc.php'; +require_once DOL_DOCUMENT_ROOT . '/core/lib/asset.lib.php'; +require_once DOL_DOCUMENT_ROOT . '/asset/class/asset.class.php'; +require_once DOL_DOCUMENT_ROOT . '/asset/class/assetdepreciationoptions.class.php'; + +// Load translation files required by the page +$langs->loadLangs(array("assets", "companies")); + +// Get parameters +$id = GETPOST('id', 'int'); +$ref = GETPOST('ref', 'alpha'); +$action = GETPOST('action', 'aZ09'); +$cancel = GETPOST('cancel', 'aZ09'); +$backtopage = GETPOST('backtopage', 'alpha'); + +// Initialize technical objects +$object = new Asset($db); +$assetdepreciationoptions = new AssetDepreciationOptions($db); +$extrafields = new ExtraFields($db); +$diroutputmassaction = $conf->asset->dir_output.'/temp/massgeneration/'.$user->id; +$hookmanager->initHooks(array('assetdepreciationoptions', 'globalcard')); // Note that conf->hooks_modules contains array +// Fetch optionals attributes and labels +$extrafields->fetch_name_optionals_label($object->table_element); + +// Load object +include DOL_DOCUMENT_ROOT . '/core/actions_fetchobject.inc.php'; // Must be include, not include_once // Must be include, not include_once. Include fetch and fetch_thirdparty but not fetch_optionals +if ($id > 0 || !empty($ref)) { + $upload_dir = $conf->asset->multidir_output[$object->entity] . "/" . $object->id; +} + +$permissiontoadd = $user->rights->asset->write; // Used by the include of actions_addupdatedelete.inc.php + +// Security check (enable the most restrictive one) +if ($user->socid > 0) accessforbidden(); +$isdraft = (($object->status == $object::STATUS_DRAFT) ? 1 : 0); +restrictedArea($user, $object->element, $object->id, $object->table_element, '', 'fk_soc', 'rowid', $isdraft); +if (empty($conf->asset->enabled)) accessforbidden(); +if (!empty($object->not_depreciated)) accessforbidden(); + +$object->asset_depreciation_options = &$assetdepreciationoptions; +$result = $assetdepreciationoptions->fetchDeprecationOptions($object->id); +if ($result < 0) { + setEventMessages($assetdepreciationoptions->error, $assetdepreciationoptions->errors, 'errors'); +} + + +/* + * Actions + */ + +$reshook = $hookmanager->executeHooks('doActions', array(), $object, $action); // Note that $action and $object may have been modified by some hooks +if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); +} +if (empty($reshook)) { + $backurlforlist = DOL_URL_ROOT.'/asset/list.php'; + + if (empty($backtopage) || ($cancel && empty($id))) { + if (empty($backtopage) || ($cancel && strpos($backtopage, '__ID__'))) { + if (empty($id) && (($action != 'add' && $action != 'create') || $cancel)) { + $backtopage = $backurlforlist; + } else { + $backtopage = DOL_URL_ROOT.'/asset/depreciation_options.php?id='.((!empty($id) && $id > 0) ? $id : '__ID__'); + } + } + } + + if ($cancel) { + /*var_dump($cancel);var_dump($backtopage);var_dump($backtopageforcancel);exit;*/ + if (!empty($backtopageforcancel)) { + header("Location: ".$backtopageforcancel); + exit; + } elseif (!empty($backtopage)) { + header("Location: ".$backtopage); + exit; + } + $action = ''; + } + + if ($action == "update") { + $result = $assetdepreciationoptions->setDeprecationOptionsFromPost(); + if ($result > 0) $result = $assetdepreciationoptions->updateDeprecationOptions($user, $object->id); + if ($result < 0) { + setEventMessages($assetdepreciationoptions->error, $assetdepreciationoptions->errors, 'errors'); + $action = 'edit'; + } else { + setEventMessage($langs->trans('RecordSaved')); + header("Location: " . $_SERVER["PHP_SELF"] . '?id=' . $object->id); + exit; + } + } +} + + +/* + * View + */ + +$form = new Form($db); + +$help_url = ''; +llxHeader('', $langs->trans('Asset'), $help_url); + +if ($id > 0 || !empty($ref)) { + $head = assetPrepareHead($object); + print dol_get_fiche_head($head, 'depreciation_options', $langs->trans("Asset"), -1, $object->picto); + + // Object card + // ------------------------------------------------------------ + $linkback = ''.$langs->trans("BackToList").''; + + $morehtmlref = '
    '; + $morehtmlref .= '
    '; + + dol_banner_tab($object, 'ref', $linkback, 1, 'ref', 'ref', $morehtmlref); + + print '
    '; + print '
    '; + print '
    '; + + if ($action == 'edit') { + print ''; + print ''; + print ''; + if ($backtopage) { + print ''; + } + if ($backtopageforcancel) { + print ''; + } + + print dol_get_fiche_head(array(), ''); + + include DOL_DOCUMENT_ROOT . '/asset/tpl/depreciation_options_edit.tpl.php'; + + print dol_get_fiche_end(); + + print $form->buttonsSaveCancel(); + + print ''; + } else { + include DOL_DOCUMENT_ROOT . '/asset/tpl/depreciation_options_view.tpl.php'; + } + + print dol_get_fiche_end(); + + if ($action != 'edit') { + print '
    ' . "\n"; + $parameters = array(); + $reshook = $hookmanager->executeHooks('addMoreActionsButtons', $parameters, $object, $action); // Note that $action and $object may have been modified by hook + if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); + } + + if (empty($reshook)) { + if ($object->status == $object::STATUS_DRAFT/* && !empty($object->enabled_modes)*/) { + print dolGetButtonAction($langs->trans('Modify'), '', 'default', $_SERVER["PHP_SELF"] . '?id=' . $object->id . '&action=edit&token=' . newToken(), '', $permissiontoadd); + } + } + print '
    ' . "\n"; + } +} + +// End of page +llxFooter(); +$db->close(); diff --git a/htdocs/asset/disposal.php b/htdocs/asset/disposal.php new file mode 100644 index 00000000000..7fddb92b05f --- /dev/null +++ b/htdocs/asset/disposal.php @@ -0,0 +1,120 @@ + + * Copyright (C) 2018 Alexandre Spangaro + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file htdocs/asset/disposal.php + * \ingroup asset + * \brief Card with disposal info on Asset + */ + +require '../main.inc.php'; +require_once DOL_DOCUMENT_ROOT.'/core/lib/asset.lib.php'; +require_once DOL_DOCUMENT_ROOT.'/asset/class/asset.class.php'; + +// Load translation files required by the page +$langs->loadLangs(array("assets", "companies")); + +// Get parameters +$id = GETPOST('id', 'int'); +$ref = GETPOST('ref', 'alpha'); +$action = GETPOST('action', 'aZ09'); +$cancel = GETPOST('cancel', 'aZ09'); +$backtopage = GETPOST('backtopage', 'alpha'); + +// Initialize technical objects +$object = new Asset($db); +$extrafields = new ExtraFields($db); +$diroutputmassaction = $conf->asset->dir_output.'/temp/massgeneration/'.$user->id; +$hookmanager->initHooks(array('assetdisposal', 'globalcard')); // Note that conf->hooks_modules contains array +// Fetch optionals attributes and labels +$extrafields->fetch_name_optionals_label($object->table_element); + +// Load object +include DOL_DOCUMENT_ROOT.'/core/actions_fetchobject.inc.php'; // Must be include, not include_once // Must be include, not include_once. Include fetch and fetch_thirdparty but not fetch_optionals +if ($id > 0 || !empty($ref)) { + $upload_dir = $conf->asset->multidir_output[$object->entity]."/".$object->id; +} + +$permissionnote = $user->rights->asset->write; // Used by the include of actions_setnotes.inc.php +$permissiontoadd = $user->rights->asset->write; // Used by the include of actions_addupdatedelete.inc.php + +// Security check (enable the most restrictive one) +if ($user->socid > 0) accessforbidden(); +$isdraft = (($object->status == $object::STATUS_DRAFT) ? 1 : 0); +restrictedArea($user, $object->element, $object->id, $object->table_element, '', 'fk_soc', 'rowid', $isdraft); +if (empty($conf->asset->enabled)) accessforbidden(); +if (!isset($object->disposal_date) || $object->disposal_date === "") accessforbidden(); + + +/* + * Actions + */ + +$reshook = $hookmanager->executeHooks('doActions', array(), $object, $action); // Note that $action and $object may have been modified by some hooks +if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); +} +if (empty($reshook)) { +} + + +/* + * View + */ + +$form = new Form($db); + +$help_url = ''; +llxHeader('', $langs->trans('Asset'), $help_url); + +if ($id > 0 || !empty($ref)) { + $object->fetch_thirdparty(); + + $head = assetPrepareHead($object); + + print dol_get_fiche_head($head, 'disposal', $langs->trans("Asset"), -1, $object->picto); + + // Object card + // ------------------------------------------------------------ + $linkback = '' . $langs->trans("BackToList") . ''; + + $morehtmlref = '
    '; + $morehtmlref .= '
    '; + + dol_banner_tab($object, 'ref', $linkback, 1, 'ref', 'ref', $morehtmlref); + + print '
    '; + print '
    '; + print ''."\n"; + + // Common attributes + $show_fields = array('disposal_date', 'disposal_amount_ht', 'fk_disposal_type', 'disposal_depreciated', 'disposal_subject_to_vat'); + foreach ($object->fields as $field_key => $field_info) { + $object->fields[$field_key]['visible'] = in_array($field_key, $show_fields) ? 1 : 0; + } + include DOL_DOCUMENT_ROOT.'/core/tpl/commonfields_view.tpl.php'; + + print '
    '; + print '
    '; + + print dol_get_fiche_end(); +} + +// End of page +llxFooter(); +$db->close(); diff --git a/htdocs/asset/document.php b/htdocs/asset/document.php index b4ee3a0a175..96b222b26c1 100644 --- a/htdocs/asset/document.php +++ b/htdocs/asset/document.php @@ -31,14 +31,13 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/images.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php'; // Load translation files required by the page -$langs->loadLangs(array('assets', 'companies', 'other')); +$langs->loadLangs(array('assets', 'companies', 'other', 'mails')); -$id = (GETPOST('id', 'int') ?GETPOST('id', 'int') : GETPOST('facid', 'int')); // For backward compatibility -$ref = GETPOST('ref', 'alpha'); -$socid = GETPOST('socid', 'int'); $action = GETPOST('action', 'aZ09'); $confirm = GETPOST('confirm', 'alpha'); +$id = GETPOST('id', 'int'); +$ref = GETPOST('ref', 'alpha'); // Get parameters $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; @@ -58,18 +57,28 @@ if (!$sortfield) { $sortfield = "name"; } +// Initialize technical objects $object = new Asset($db); -if ($object->fetch($id)) { - $upload_dir = $conf->asset->dir_output."/".dol_sanitizeFileName($object->ref); +$extrafields = new ExtraFields($db); +$diroutputmassaction = $conf->asset->dir_output.'/temp/massgeneration/'.$user->id; +$hookmanager->initHooks(array('assetdocument', 'globalcard')); // Note that conf->hooks_modules contains array +// Fetch optionals attributes and labels +$extrafields->fetch_name_optionals_label($object->table_element); + +// Load object +include DOL_DOCUMENT_ROOT.'/core/actions_fetchobject.inc.php'; // Must be include, not include_once // Must be include, not include_once. Include fetch and fetch_thirdparty but not fetch_optionals + +if ($id > 0 || !empty($ref)) { + $upload_dir = $conf->asset->multidir_output[$object->entity ? $object->entity : $conf->entity]."/".get_exdir(0, 0, 0, 1, $object); } -$permissiontoadd = $user->rights->asset->write; // Used by the include of actions_addupdatedelete.inc.php and actions_linkedfiles.inc.php +$permissiontoadd = $user->rights->asset->asset->write; // Used by the include of actions_addupdatedelete.inc.php and actions_linkedfiles.inc.php -// Security check -if ($user->socid) { - $socid = $user->socid; -} -$result=restrictedArea($user, 'asset', $id, ''); +// Security check (enable the most restrictive one) +if ($user->socid > 0) accessforbidden(); +$isdraft = (($object->status == $object::STATUS_DRAFT) ? 1 : 0); +restrictedArea($user, $object->element, $object->id, $object->table_element, '', 'fk_soc', 'rowid', $isdraft); +if (empty($conf->asset->enabled)) accessforbidden(); /* @@ -83,60 +92,67 @@ include DOL_DOCUMENT_ROOT.'/core/actions_linkedfiles.inc.php'; * View */ -$title = $langs->trans('Assets')." - ".$langs->trans('Documents'); - -$help_url = ''; - -llxHeader('', $title, $help_url); - $form = new Form($db); +$title = $langs->trans("Asset").' - '.$langs->trans("Files"); +$help_url = ''; +llxHeader('', $title, $help_url); + +if ($object->id) { + /* + * Show tabs + */ + $head = assetPrepareHead($object); + + print dol_get_fiche_head($head, 'document', $langs->trans("Asset"), -1, $object->picto); -if ($id > 0 || !empty($ref)) { - if ($object->fetch($id, $ref) > 0) { - $upload_dir = $conf->asset->multidir_output[$object->entity].'/'.dol_sanitizeFileName($object->ref); - - $head = asset_prepare_head($object); - print dol_get_fiche_head($head, 'documents', $langs->trans('Asset'), -1, 'accounting'); - - // Build file list - $filearray = dol_dir_list($upload_dir, "files", 0, '', '(\.meta|_preview.*\.png)$', $sortfield, (strtolower($sortorder) == 'desc' ?SORT_DESC:SORT_ASC), 1); - $totalsize = 0; - foreach ($filearray as $key => $file) { - $totalsize += $file['size']; - } - - // Asset content - - $linkback = ''.$langs->trans("BackToList").''; - - $morehtmlref = ''; - dol_banner_tab($object, 'ref', $linkback, 1, 'ref', 'ref', $morehtmlref, '', 0); - - print '
    '; - print '
    '; - - print ''; - - print ''; - print ''; - print "
    '.$langs->trans("NbOfAttachedFiles").''.count($filearray).'
    '.$langs->trans("TotalSizeOfAttachedFiles").''.dol_print_size($totalsize, 1, 1).'
    \n"; - - print "
    \n"; - - print dol_get_fiche_end(); - - $modulepart = 'asset'; - $permissiontoadd = $user->rights->asset->write; - $permtoedit = $user->rights->asset->write; - $param = '&id='.$object->id; - include DOL_DOCUMENT_ROOT.'/core/tpl/document_actions_post_headers.tpl.php'; - } else { - dol_print_error($db); + // Build file list + $filearray = dol_dir_list($upload_dir, "files", 0, '', '(\.meta|_preview.*\.png)$', $sortfield, (strtolower($sortorder) == 'desc' ? SORT_DESC : SORT_ASC), 1); + $totalsize = 0; + foreach ($filearray as $key => $file) { + $totalsize += $file['size']; } + + // Object card + // ------------------------------------------------------------ + $linkback = '' . $langs->trans("BackToList") . ''; + + $morehtmlref = '
    '; + $morehtmlref .= '
    '; + + dol_banner_tab($object, 'ref', $linkback, 1, 'ref', 'ref', $morehtmlref); + + print '
    '; + + print '
    '; + print ''; + + // Number of files + print ''; + + // Total size + print ''; + + print '
    ' . $langs->trans("NbOfAttachedFiles") . '' . count($filearray) . '
    ' . $langs->trans("TotalSizeOfAttachedFiles") . '' . $totalsize . ' ' . $langs->trans("bytes") . '
    '; + + print '
    '; + + print dol_get_fiche_end(); + + $modulepart = 'asset'; + $permissiontoadd = $user->rights->asset->write; + // $permissiontoadd = 1; + $permtoedit = $user->rights->asset->write; + // $permtoedit = 1; + $param = '&id=' . $object->id; + + //$relativepathwithnofile='asset/' . dol_sanitizeFileName($object->id).'/'; + $relativepathwithnofile = dol_sanitizeFileName($object->ref) . '/'; + + include DOL_DOCUMENT_ROOT . '/core/tpl/document_actions_post_headers.tpl.php'; } else { - print $langs->trans("ErrorUnknown"); + accessforbidden('', 0, 1); } // End of page diff --git a/htdocs/asset/info.php b/htdocs/asset/info.php deleted file mode 100644 index 7a8f4c20ce2..00000000000 --- a/htdocs/asset/info.php +++ /dev/null @@ -1,93 +0,0 @@ - - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -/** - * \file htdocs/asset/info.php - * \ingroup asset - * \brief Page to show an asset information - */ - -require '../main.inc.php'; -require_once DOL_DOCUMENT_ROOT.'/core/lib/asset.lib.php'; -require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; -require_once DOL_DOCUMENT_ROOT.'/asset/class/asset.class.php'; - -// Load translation files required by the page -$langs->loadLangs(array("asset")); - -$id = GETPOSTINT('id'); -$ref = GETPOST('ref', 'alpha'); -$action = GETPOST('action', 'aZ09'); - -// Security check -if ($user->socid) { - $socid = $user->socid; -} -$result = restrictedArea($user, 'asset', $id); - -$object = new Asset($db); -$object->fetch($id); - - -/* - * Actions - */ - -// None - - -/* - * View - */ - -$form = new Form($db); - -$title = $langs->trans('Asset')." - ".$langs->trans('Info'); - -$help_url = ""; - -llxHeader('', $title, $help_url); - -$object->info($id); - -$head = asset_prepare_head($object); - -print dol_get_fiche_head($head, 'info', $langs->trans("Asset"), -1, 'generic'); - -$linkback = ''.$langs->trans("BackToList").''; - -$morehtmlref = '
    '; -$morehtmlref .= '
    '; - -dol_banner_tab($object, 'rowid', $linkback, 1, 'rowid', 'ref', $morehtmlref); - -print '
    '; -print '
    '; - -print '
    '; - -print '
    '; -dol_print_object_info($object); -print '
    '; - -print '
    '; - -print dol_get_fiche_end(); - -// End of page -llxFooter(); -$db->close(); diff --git a/htdocs/asset/list.php b/htdocs/asset/list.php index 1abdabd333e..c475e22fc83 100644 --- a/htdocs/asset/list.php +++ b/htdocs/asset/list.php @@ -31,26 +31,26 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php'; require_once DOL_DOCUMENT_ROOT.'/asset/class/asset.class.php'; // Load translation files required by the page -$langs->loadLangs(array("assets")); +$langs->loadLangs(array("assets", "other")); -$action = GETPOST('action', 'aZ09') ?GETPOST('action', 'aZ09') : 'view'; // The action 'add', 'create', 'edit', 'update', 'view', ... -$massaction = GETPOST('massaction', 'alpha'); // The bulk action (combo box choice into lists) -$show_files = GETPOST('show_files', 'int'); // Show files area generated by bulk actions ? -$confirm = GETPOST('confirm', 'alpha'); // Result of a confirmation -$cancel = GETPOST('cancel', 'alpha'); // We click on a Cancel button -$toselect = GETPOST('toselect', 'array'); // Array of ids of elements selected into a list -$contextpage = GETPOST('contextpage', 'aZ') ?GETPOST('contextpage', 'aZ') : 'assetlist'; // To manage different context of search -$backtopage = GETPOST('backtopage', 'alpha'); // Go back to a dedicated page -$optioncss = GETPOST('optioncss', 'aZ'); // Option for the css output (always '' except when 'print') +$action = GETPOST('action', 'aZ09') ?GETPOST('action', 'aZ09') : 'view'; // The action 'add', 'create', 'edit', 'update', 'view', ... +$massaction = GETPOST('massaction', 'alpha'); // The bulk action (combo box choice into lists) +$show_files = GETPOST('show_files', 'int'); // Show files area generated by bulk actions ? +$confirm = GETPOST('confirm', 'alpha'); // Result of a confirmation +$cancel = GETPOST('cancel', 'alpha'); // We click on a Cancel button +$toselect = GETPOST('toselect', 'array'); // Array of ids of elements selected into a list +$contextpage = GETPOST('contextpage', 'aZ') ? GETPOST('contextpage', 'aZ') : 'assetlist'; // To manage different context of search +$backtopage = GETPOST('backtopage', 'alpha'); // Go back to a dedicated page +$optioncss = GETPOST('optioncss', 'aZ'); // Option for the css output (always '' except when 'print') $id = GETPOST('id', 'int'); // Load variable for pagination -$limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; +$limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; $sortfield = GETPOST('sortfield', 'aZ09comma'); $sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); -if (empty($page) || $page == -1 || GETPOST('button_search', 'alpha') || GETPOST('button_removefilter', 'alpha') || (empty($toselect) && $massaction === '0')) { +if (empty($page) || $page < 0 || GETPOST('button_search', 'alpha') || GETPOST('button_removefilter', 'alpha') || (empty($toselect) && $massaction === '0')) { $page = 0; } // If $page is not defined, or '' or -1 or if we click on clear filters or if we select empty mass action $offset = $limit * $page; @@ -71,33 +71,24 @@ $search_array_options = $extrafields->getOptionalsFromPost($object->table_elemen // Default sort order (if not yet defined by previous GETPOST) if (!$sortfield) { + reset($object->fields); // Reset is required to avoid key() to return null. $sortfield = "t.".key($object->fields); // Set here default search field. By default 1st field in definition. } if (!$sortorder) { $sortorder = "ASC"; } -// Security check -$socid = 0; -if ($user->socid) { - $socid = $user->socid; -} -if ($user->socid > 0) { - // Protection if external user - //$socid = $user->socid; - accessforbidden(); -} -// Security check -$result = restrictedArea($user, 'asset', $id); - - // Initialize array of search criterias -$search_all = GETPOST("search_all", 'alpha'); +$search_all = GETPOST('search_all', 'alphanohtml'); $search = array(); foreach ($object->fields as $key => $val) { if (GETPOST('search_'.$key, 'alpha') !== '') { $search[$key] = GETPOST('search_'.$key, 'alpha'); } + if (preg_match('/^(date|timestamp|datetime)/', $val['type'])) { + $search[$key.'_dtstart'] = dol_mktime(0, 0, 0, GETPOST('search_'.$key.'_dtstartmonth', 'int'), GETPOST('search_'.$key.'_dtstartday', 'int'), GETPOST('search_'.$key.'_dtstartyear', 'int')); + $search[$key.'_dtend'] = dol_mktime(23, 59, 59, GETPOST('search_'.$key.'_dtendmonth', 'int'), GETPOST('search_'.$key.'_dtendday', 'int'), GETPOST('search_'.$key.'_dtendyear', 'int')); + } } // List of fields to search into when doing a "search in all" @@ -108,27 +99,24 @@ foreach ($object->fields as $key => $val) { } } -// Definition of fields for list +// Definition of array of fields for columns $arrayfields = array(); foreach ($object->fields as $key => $val) { // If $val['visible']==0, then we never show the field if (!empty($val['visible'])) { - $arrayfields['t.'.$key] = array('label'=>$val['label'], 'checked'=>(($val['visible'] < 0) ? 0 : 1), 'enabled'=>($val['enabled'] && ($val['visible'] != 3)), 'position'=>$val['position']); + $visible = (int) dol_eval($val['visible'], 1); + $arrayfields['t.'.$key] = array( + 'label'=>$val['label'], + 'checked'=>(($visible < 0) ? 0 : 1), + 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1)), + 'position'=>$val['position'], + 'help'=> isset($val['help']) ? $val['help'] : '' + ); } } // Extra fields -if (is_array($extrafields->attributes[$object->table_element]['label']) && count($extrafields->attributes[$object->table_element]['label']) > 0) { - foreach ($extrafields->attributes[$object->table_element]['label'] as $key => $val) { - if (!empty($extrafields->attributes[$object->table_element]['list'][$key])) { - $arrayfields["ef.".$key] = array( - 'label'=>$extrafields->attributes[$object->table_element]['label'][$key], - 'checked'=>(($extrafields->attributes[$object->table_element]['list'][$key] < 0) ? 0 : 1), - 'position'=>$extrafields->attributes[$object->table_element]['pos'][$key], - 'enabled'=>(abs($extrafields->attributes[$object->table_element]['list'][$key]) != 3 && $extrafields->attributes[$object->table_element]['perms'][$key]) - ); - } - } -} +include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_array_fields.tpl.php'; + $object->fields = dol_sort_array($object->fields, 'position'); $arrayfields = dol_sort_array($arrayfields, 'position'); @@ -136,13 +124,28 @@ $permissiontoread = $user->rights->asset->read; $permissiontoadd = $user->rights->asset->write; $permissiontodelete = $user->rights->asset->delete; +// Security check +if (empty($conf->asset->enabled)) { + accessforbidden('Module not enabled'); +} + +// Security check (enable the most restrictive one) +if ($user->socid > 0) accessforbidden(); +$socid = 0; if ($user->socid > 0) $socid = $user->socid; +$isdraft = (($object->status == $object::STATUS_DRAFT) ? 1 : 0); +restrictedArea($user, $object->element, $object->id, $object->table_element, '', 'fk_soc', 'rowid', $isdraft); +if (empty($conf->asset->enabled)) accessforbidden(); +if (!$permissiontoread) accessforbidden(); + + /* * Actions */ if (GETPOST('cancel', 'alpha')) { - $action = 'list'; $massaction = ''; + $action = 'list'; + $massaction = ''; } if (!GETPOST('confirmmassaction', 'alpha') && $massaction != 'presend' && $massaction != 'confirm_presend') { $massaction = ''; @@ -162,8 +165,12 @@ if (empty($reshook)) { if (GETPOST('button_removefilter_x', 'alpha') || GETPOST('button_removefilter.x', 'alpha') || GETPOST('button_removefilter', 'alpha')) { // All tests are required to be compatible with all browsers foreach ($object->fields as $key => $val) { $search[$key] = ''; + if (preg_match('/^(date|timestamp|datetime)/', $val['type'])) { + $search[$key.'_dtstart'] = ''; + $search[$key.'_dtend'] = ''; + } } - $toselect = ''; + $toselect = array(); $search_array_options = array(); } if (GETPOST('button_removefilter_x', 'alpha') || GETPOST('button_removefilter.x', 'alpha') || GETPOST('button_removefilter', 'alpha') @@ -188,21 +195,20 @@ $form = new Form($db); $now = dol_now(); -//$help_url="EN:Module_Asset|FR:Module_Asset_FR|ES:Módulo_Asset"; $help_url = ''; $title = $langs->trans('ListOf', $langs->transnoentitiesnoconv("Assets")); +$morejs = array(); +$morecss = array(); // Build and execute select // -------------------------------------------------------------------- $sql = 'SELECT '; -foreach ($object->fields as $key => $val) { - $sql .= "t.".$key.", "; -} +$sql .= $object->getFieldList('t'); // Add fields from extrafields if (!empty($extrafields->attributes[$object->table_element]['label'])) { foreach ($extrafields->attributes[$object->table_element]['label'] as $key => $val) { - $sql .= ($extrafields->attributes[$object->table_element]['type'][$key] != 'separate' ? "ef.".$key." as options_".$key.', ' : ''); + $sql .= ($extrafields->attributes[$object->table_element]['type'][$key] != 'separate' ? ", ef.".$key." as options_".$key : ''); } } // Add fields from hooks @@ -211,27 +217,45 @@ $reshook = $hookmanager->executeHooks('printFieldListSelect', $parameters, $obje $sql .= preg_replace('/^,/', '', $hookmanager->resPrint); $sql = preg_replace('/,\s*$/', '', $sql); $sql .= " FROM ".MAIN_DB_PREFIX.$object->table_element." as t"; -if (is_array($extrafields->attributes[$object->table_element]['label']) && count($extrafields->attributes[$object->table_element]['label'])) { +if (isset($extrafields->attributes[$object->table_element]['label']) && is_array($extrafields->attributes[$object->table_element]['label']) && count($extrafields->attributes[$object->table_element]['label'])) { $sql .= " LEFT JOIN ".MAIN_DB_PREFIX.$object->table_element."_extrafields as ef on (t.rowid = ef.fk_object)"; } +// Add table from hooks +$parameters = array(); +$reshook = $hookmanager->executeHooks('printFieldListFrom', $parameters, $object); // Note that $action and $object may have been modified by hook +$sql .= $hookmanager->resPrint; if ($object->ismultientitymanaged == 1) { $sql .= " WHERE t.entity IN (".getEntity($object->element).")"; } else { $sql .= " WHERE 1 = 1"; } foreach ($search as $key => $val) { - if ($key == 'status' && $search[$key] == -1) { - continue; - } - $mode_search = (($object->isInt($object->fields[$key]) || $object->isFloat($object->fields[$key])) ? 1 : 0); - if (strpos($object->fields[$key]['type'], 'integer:') === 0) { - if ($search[$key] == '-1') { - $search[$key] = ''; + if (array_key_exists($key, $object->fields)) { + if ($key == 'status' && $search[$key] == -1) { + continue; + } + $mode_search = (($object->isInt($object->fields[$key]) || $object->isFloat($object->fields[$key])) ? 1 : 0); + if ((strpos($object->fields[$key]['type'], 'integer:') === 0) || (strpos($object->fields[$key]['type'], 'sellist:') === 0) || !empty($object->fields[$key]['arrayofkeyval'])) { + if ($search[$key] == '-1' || ($search[$key] === '0' && (empty($object->fields[$key]['arrayofkeyval']) || !array_key_exists('0', $object->fields[$key]['arrayofkeyval'])))) { + $search[$key] = ''; + } + $mode_search = 2; + } + if ($search[$key] != '') { + $sql .= natural_search($key, $search[$key], (($key == 'status') ? 2 : $mode_search)); + } + } else { + if (preg_match('/(_dtstart|_dtend)$/', $key) && $search[$key] != '') { + $columnName = preg_replace('/(_dtstart|_dtend)$/', '', $key); + if (preg_match('/^(date|timestamp|datetime)/', $object->fields[$columnName]['type'])) { + if (preg_match('/_dtstart$/', $key)) { + $sql .= " AND t.".$columnName." >= '".$db->idate($search[$key])."'"; + } + if (preg_match('/_dtend$/', $key)) { + $sql .= " AND t." . $columnName . " <= '" . $db->idate($search[$key]) . "'"; + } + } } - $mode_search = 2; - } - if ($search[$key] != '') { - $sql .= natural_search($key, $search[$key], (($key == 'status') ? 2 : $mode_search)); } } if ($search_all) { @@ -246,51 +270,69 @@ $reshook = $hookmanager->executeHooks('printFieldListWhere', $parameters, $objec $sql .= $hookmanager->resPrint; /* If a group by is required -$sql.= " GROUP BY " -foreach($object->fields as $key => $val) -{ +$sql .= " GROUP BY "; +foreach($object->fields as $key => $val) { $sql .= "t.".$key.", "; } // Add fields from extrafields -if (! empty($extrafields->attributes[$object->table_element]['label'])) { - foreach ($extrafields->attributes[$object->table_element]['label'] as $key => $val) $sql.=($extrafields->attributes[$object->table_element]['type'][$key] != 'separate' ? "ef.".$key.', ' : ''); +if (!empty($extrafields->attributes[$object->table_element]['label'])) { + foreach ($extrafields->attributes[$object->table_element]['label'] as $key => $val) { + $sql .= ($extrafields->attributes[$object->table_element]['type'][$key] != 'separate' ? "ef.".$key.', ' : ''); + } } // Add where from hooks -$parameters=array(); -$reshook=$hookmanager->executeHooks('printFieldListGroupBy',$parameters); // Note that $action and $object may have been modified by hook -$sql.=$hookmanager->resPrint; -$sql=preg_replace('/,\s*$/','', $sql); +$parameters = array(); +$reshook = $hookmanager->executeHooks('printFieldListGroupBy', $parameters, $object); // Note that $action and $object may have been modified by hook +$sql .= $hookmanager->resPrint; +$sql = preg_replace('/,\s*$/', '', $sql); */ -$sql .= $db->order($sortfield, $sortorder); +// Add HAVING from hooks +/* +$parameters = array(); +$reshook = $hookmanager->executeHooks('printFieldListHaving', $parameters, $object); // Note that $action and $object may have been modified by hook +$sql .= !empty($hookmanager->resPrint) ? (" HAVING 1=1 " . $hookmanager->resPrint) : ""; +*/ // Count total nb of records $nbtotalofrecords = ''; if (empty($conf->global->MAIN_DISABLE_FULL_SCANLIST)) { + /* This old and fast method to get and count full list returns all record so use a high amount of memory. $resql = $db->query($sql); $nbtotalofrecords = $db->num_rows($resql); + */ + /* The slow method does not consume memory on mysql (not tested on pgsql) */ + /*$resql = $db->query($sql, 0, 'auto', 1); + while ($db->fetch_object($resql)) { + $nbtotalofrecords++; + }*/ + /* The fast and low memory method to get and count full list converts the sql into a sql count */ + $sqlforcount = preg_replace('/^SELECT[a-z0-9\._\s\(\),]+FROM/i', 'SELECT COUNT(*) as nbtotalofrecords FROM', $sql); + $resql = $db->query($sqlforcount); + $objforcount = $db->fetch_object($resql); + $nbtotalofrecords = $objforcount->nbtotalofrecords; if (($page * $limit) > $nbtotalofrecords) { // if total of record found is smaller than page * limit, goto and load page 0 $page = 0; $offset = 0; } + $db->free($resql); } -// if total of record found is smaller than limit, no need to do paging and to restart another select with limits set. -if (is_numeric($nbtotalofrecords) && ($limit > $nbtotalofrecords || empty($limit))) { - $num = $nbtotalofrecords; -} else { - if ($limit) { - $sql .= $db->plimit($limit + 1, $offset); - } - $resql = $db->query($sql); - if (!$resql) { - dol_print_error($db); - exit; - } - - $num = $db->num_rows($resql); +// Complete request and execute it with limit +$sql .= $db->order($sortfield, $sortorder); +if ($limit) { + $sql .= $db->plimit($limit + 1, $offset); } +$resql = $db->query($sql); +if (!$resql) { + dol_print_error($db); + exit; +} + +$num = $db->num_rows($resql); + + // Direct jump if only one record found if ($num == 1 && !empty($conf->global->MAIN_SEARCH_DIRECT_OPEN_IF_ONLY_ONE) && $search_all && !$page) { $obj = $db->fetch_object($resql); @@ -303,7 +345,7 @@ if ($num == 1 && !empty($conf->global->MAIN_SEARCH_DIRECT_OPEN_IF_ONLY_ONE) && $ // Output page // -------------------------------------------------------------------- -llxHeader('', $title, $help_url); +llxHeader('', $title, $help_url, '', 0, 0, $morejs, $morecss, '', ''); $arrayofselected = is_array($toselect) ? $toselect : array(); @@ -317,9 +359,11 @@ if ($limit > 0 && $limit != $conf->liste_limit) { foreach ($search as $key => $val) { if (is_array($search[$key]) && count($search[$key])) { foreach ($search[$key] as $skey) { - $param .= '&search_'.$key.'[]='.urlencode($skey); + if ($skey != '') { + $param .= '&search_'.$key.'[]='.urlencode($skey); + } } - } else { + } elseif ($search[$key] != '') { $param .= '&search_'.$key.'='.urlencode($search[$key]); } } @@ -328,11 +372,17 @@ if ($optioncss != '') { } // Add $param from extra fields include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_search_param.tpl.php'; +// Add $param from hooks +$parameters = array(); +$reshook = $hookmanager->executeHooks('printFieldListSearchParam', $parameters, $object); // Note that $action and $object may have been modified by hook +$param .= $hookmanager->resPrint; // List of mass actions available $arrayofmassactions = array( - //'presend'=>img_picto('', 'email', 'class="pictofixedwidth"').$langs->trans("SendByMail"), + //'validate'=>img_picto('', 'check', 'class="pictofixedwidth"').$langs->trans("Validate"), + //'generate_doc'=>img_picto('', 'pdf', 'class="pictofixedwidth"').$langs->trans("ReGeneratePDF"), //'builddoc'=>img_picto('', 'pdf', 'class="pictofixedwidth"').$langs->trans("PDFMerge"), + //'presend'=>img_picto('', 'email', 'class="pictofixedwidth"').$langs->trans("SendByMail"), ); if ($permissiontodelete) { $arrayofmassactions['predelete'] = img_picto('', 'delete', 'class="pictofixedwidth"').$langs->trans("Delete"); @@ -351,24 +401,25 @@ print ''; print ''; print ''; +print ''; print ''; -$newcardbutton = dolGetButtonTitle($langs->trans('NewAsset'), '', 'fa fa-plus-circle', dol_buildpath('/asset/card.php', 1).'?action=create&backtopage='.urlencode($_SERVER['PHP_SELF']), '', $permissiontoadd); +$newcardbutton = dolGetButtonTitle($langs->trans('New'), '', 'fa fa-plus-circle', DOL_URL_ROOT.'/asset/card.php?action=create&backtopage='.urlencode($_SERVER['PHP_SELF']), '', $permissiontoadd); -print_barre_liste($title, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, $object->picto, 0, $newcardbutton, '', $limit, 0, 0, 1); +print_barre_liste($title, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 'object_'.$object->picto, 0, $newcardbutton, '', $limit, 0, 0, 1); // Add code for pre mass action (confirmation or email presend form) -$topicmail = "SendAssetsRef"; +$topicmail = "SendAssetRef"; $modelmail = "asset"; $objecttmp = new Asset($db); $trackid = 'asset'.$object->id; include DOL_DOCUMENT_ROOT.'/core/tpl/massactions_pre.tpl.php'; -if ($sall) { +if ($search_all) { foreach ($fieldstosearchall as $key => $val) { $fieldstosearchall[$key] = $langs->trans($val); } - print '
    '.$langs->trans("FilterOnInto", $sall).join(', ', $fieldstosearchall).'
    '; + print '
    '.$langs->trans("FilterOnInto", $search_all).join(', ', $fieldstosearchall).'
    '; } $moreforfilter = ''; @@ -395,31 +446,42 @@ $selectedfields = $form->multiSelectArrayWithCheckbox('selectedfields', $arrayfi $selectedfields .= (count($arrayofmassactions) ? $form->showCheckAddButtons('checkforselect', 1) : ''); print '
    '; // You can use div-table-responsive-no-min if you dont need reserved height for your table -print ''."\n"; +print '
    '."\n"; // Fields title search // -------------------------------------------------------------------- print ''; foreach ($object->fields as $key => $val) { - $cssforfield = (empty($val['css']) ? '' : $val['css']); + $cssforfield = (empty($val['csslist']) ? (empty($val['css']) ? '' : $val['css']) : $val['csslist']); if ($key == 'status') { $cssforfield .= ($cssforfield ? ' ' : '').'center'; } elseif (in_array($val['type'], array('date', 'datetime', 'timestamp'))) { $cssforfield .= ($cssforfield ? ' ' : '').'center'; } elseif (in_array($val['type'], array('timestamp'))) { $cssforfield .= ($cssforfield ? ' ' : '').'nowrap'; - } elseif (in_array($val['type'], array('double(24,8)', 'double(6,3)', 'integer', 'real', 'price')) && $val['label'] != 'TechnicalID') { + } elseif (in_array($val['type'], array('double(24,8)', 'double(6,3)', 'integer', 'real', 'price')) && $val['label'] != 'TechnicalID' && empty($val['arrayofkeyval'])) { $cssforfield .= ($cssforfield ? ' ' : '').'right'; } if (!empty($arrayfields['t.'.$key]['checked'])) { print ''; } @@ -443,14 +505,14 @@ print ''."\n"; // -------------------------------------------------------------------- print ''; foreach ($object->fields as $key => $val) { - $cssforfield = (empty($val['css']) ? '' : $val['css']); + $cssforfield = (empty($val['csslist']) ? (empty($val['css']) ? '' : $val['css']) : $val['csslist']); if ($key == 'status') { $cssforfield .= ($cssforfield ? ' ' : '').'center'; } elseif (in_array($val['type'], array('date', 'datetime', 'timestamp'))) { $cssforfield .= ($cssforfield ? ' ' : '').'center'; } elseif (in_array($val['type'], array('timestamp'))) { $cssforfield .= ($cssforfield ? ' ' : '').'nowrap'; - } elseif (in_array($val['type'], array('double(24,8)', 'double(6,3)', 'integer', 'real', 'price')) && $val['label'] != 'TechnicalID') { + } elseif (in_array($val['type'], array('double(24,8)', 'double(6,3)', 'integer', 'real', 'price')) && $val['label'] != 'TechnicalID' && empty($val['arrayofkeyval'])) { $cssforfield .= ($cssforfield ? ' ' : '').'right'; } if (!empty($arrayfields['t.'.$key]['checked'])) { @@ -464,13 +526,13 @@ $parameters = array('arrayfields'=>$arrayfields, 'param'=>$param, 'sortfield'=>$ $reshook = $hookmanager->executeHooks('printFieldListTitle', $parameters, $object); // Note that $action and $object may have been modified by hook print $hookmanager->resPrint; // Action column -print getTitleFieldOfList($selectedfields, 0, $_SERVER["PHP_SELF"], '', '', '', 'align="center"', $sortfield, $sortorder, 'maxwidthsearch ')."\n"; +print getTitleFieldOfList($selectedfields, 0, $_SERVER["PHP_SELF"], '', '', '', '', $sortfield, $sortorder, 'center maxwidthsearch ')."\n"; print ''."\n"; // Detect if we need a fetch on each output line $needToFetchEachLine = 0; -if (is_array($extrafields->attributes[$object->table_element]['computed']) && count($extrafields->attributes[$object->table_element]['computed']) > 0) { +if (isset($extrafields->attributes[$object->table_element]['computed']) && is_array($extrafields->attributes[$object->table_element]['computed']) && count($extrafields->attributes[$object->table_element]['computed']) > 0) { foreach ($extrafields->attributes[$object->table_element]['computed'] as $key => $val) { if (preg_match('/\$object/', $val)) { $needToFetchEachLine++; // There is at least one compute field that use $object @@ -483,6 +545,7 @@ if (is_array($extrafields->attributes[$object->table_element]['computed']) && co // -------------------------------------------------------------------- $i = 0; $totalarray = array(); +$totalarray['nbfield'] = 0; while ($i < ($limit ? min($num, $limit) : $num)) { $obj = $db->fetch_object($resql); if (empty($obj)) { @@ -495,7 +558,7 @@ while ($i < ($limit ? min($num, $limit) : $num)) { // Show here line of result print ''; foreach ($object->fields as $key => $val) { - $cssforfield = (empty($val['css']) ? '' : $val['css']); + $cssforfield = (empty($val['csslist']) ? (empty($val['css']) ? '' : $val['css']) : $val['csslist']); if (in_array($val['type'], array('date', 'datetime', 'timestamp'))) { $cssforfield .= ($cssforfield ? ' ' : '').'center'; } elseif ($key == 'status') { @@ -508,14 +571,17 @@ while ($i < ($limit ? min($num, $limit) : $num)) { $cssforfield .= ($cssforfield ? ' ' : '').'nowrap'; } - if (in_array($val['type'], array('double(24,8)', 'double(6,3)', 'integer', 'real', 'price')) && $key != 'status') { + if (in_array($val['type'], array('double(24,8)', 'double(6,3)', 'integer', 'real', 'price')) && !in_array($key, array('rowid', 'status')) && empty($val['arrayofkeyval'])) { $cssforfield .= ($cssforfield ? ' ' : '').'right'; } + //if (in_array($key, array('fk_soc', 'fk_user', 'fk_warehouse'))) $cssforfield = 'tdoverflowmax100'; if (!empty($arrayfields['t.'.$key]['checked'])) { print ''; if ($key == 'status') { print $object->getLibStatut(5); + } elseif ($key == 'rowid') { + print $object->showOutputField($val, $key, $object->id, ''); } else { print $object->showOutputField($val, $key, $object->$key, ''); } @@ -545,7 +611,7 @@ while ($i < ($limit ? min($num, $limit) : $num)) { print $hookmanager->resPrint; // Action column print ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo "\n"; +} +if (count($linkedObjectBlock) > 1) { + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo ''; + echo "\n"; +} + +echo "\n"; diff --git a/htdocs/asset/type.php b/htdocs/asset/type.php deleted file mode 100644 index 2413364426f..00000000000 --- a/htdocs/asset/type.php +++ /dev/null @@ -1,608 +0,0 @@ - - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -/** - * \file htdocs/asset/type.php - * \ingroup asset - * \brief Asset's type setup - */ - -require '../main.inc.php'; -require_once DOL_DOCUMENT_ROOT.'/core/lib/asset.lib.php'; -require_once DOL_DOCUMENT_ROOT.'/asset/class/asset.class.php'; -require_once DOL_DOCUMENT_ROOT.'/asset/class/asset_type.class.php'; -require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php'; -if (!empty($conf->accounting->enabled)) { - require_once DOL_DOCUMENT_ROOT.'/core/lib/accounting.lib.php'; -} -if (!empty($conf->accounting->enabled)) { - require_once DOL_DOCUMENT_ROOT.'/core/class/html.formaccounting.class.php'; -} -if (!empty($conf->accounting->enabled)) { - require_once DOL_DOCUMENT_ROOT.'/accountancy/class/accountingaccount.class.php'; -} - -// Load translation files required by the page -$langs->load("assets"); - -$rowid = GETPOST('rowid', 'int'); -$action = GETPOST('action', 'aZ09'); -$cancel = GETPOST('cancel', 'alpha'); -$backtopage = GETPOST('backtopage', 'alpha'); - -$type = GETPOST('type', 'alpha'); - -$limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); -$page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); -if (empty($page) || $page == -1) { - $page = 0; -} // If $page is not defined, or '' or -1 -$offset = $limit * $page; -$pageprev = $page - 1; -$pagenext = $page + 1; -if (!$sortorder) { - $sortorder = "DESC"; -} -if (!$sortfield) { - $sortfield = "a.label"; -} - -$label = GETPOST("label", "alpha"); -$accountancy_code_asset = GETPOST('accountancy_code_asset', 'string'); -$accountancy_code_depreciation_asset = GETPOST('accountancy_code_depreciation_asset', 'string'); -$accountancy_code_depreciation_expense = GETPOST('accountancy_code_depreciation_expense', 'string'); -$comment = GETPOST('comment', 'string'); - -// Security check -$result = restrictedArea($user, 'asset', $rowid, 'asset_type'); - -$object = new AssetType($db); - -$extrafields = new ExtraFields($db); - -// fetch optionals attributes and labels -$extrafields->fetch_name_optionals_label($object->table_element); - -if (GETPOST('button_removefilter_x', 'alpha') || GETPOST('button_removefilter_x', 'alpha') || GETPOST('button_removefilter', 'alpha')) { // All tests are required to be compatible with all browsers - $type = ""; - $sall = ""; -} - - -// Initialize technical object to manage hooks of page. Note that conf->hooks_modules contains array of hook context -$hookmanager->initHooks(array('assettypecard', 'globalcard')); - -$permissiontoadd = $user->rights->asset->setup_advance; - - -/* - * Actions - */ - -if ($cancel) { - $action = ''; - - if (!empty($backtopage)) { - header("Location: ".$backtopage); - exit; - } -} - -if ($action == 'add' && $user->rights->asset->write) { - $object->label = trim($label); - $object->accountancy_code_asset = trim($accountancy_code_asset); - $object->accountancy_code_depreciation_asset = trim($accountancy_code_depreciation_asset); - $object->accountancy_code_depreciation_expense = trim($accountancy_code_depreciation_expense); - $object->note = trim($comment); - - // Fill array 'array_options' with data from add form - $ret = $extrafields->setOptionalsFromPost(null, $object); - if ($ret < 0) { - $error++; - } - - if (empty($object->label)) { - $error++; - setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentities("Label")), null, 'errors'); - } else { - $sql = "SELECT label FROM ".MAIN_DB_PREFIX."asset_type WHERE label='".$db->escape($object->label)."'"; - $result = $db->query($sql); - if ($result) { - $num = $db->num_rows($result); - } - if ($num) { - $error++; - $langs->load("errors"); - setEventMessages($langs->trans("ErrorLabelAlreadyExists", $login), null, 'errors'); - } - } - - if (!$error) { - $id = $object->create($user); - if ($id > 0) { - header("Location: ".$_SERVER["PHP_SELF"]); - exit; - } else { - setEventMessages($object->error, $object->errors, 'errors'); - $action = 'create'; - } - } else { - $action = 'create'; - } -} - -if ($action == 'update' && $user->rights->asset->write) { - $object->fetch($rowid); - - $object->oldcopy = clone $object; - - $object->label = trim($label); - $object->accountancy_code_asset = trim($accountancy_code_asset); - $object->accountancy_code_depreciation_asset = trim($accountancy_code_depreciation_asset); - $object->accountancy_code_depreciation_expense = trim($accountancy_code_depreciation_expense); - $object->note = trim($comment); - - // Fill array 'array_options' with data from add form - $ret = $extrafields->setOptionalsFromPost(null, $object); - if ($ret < 0) { - $error++; - } - - $ret = $object->update($user); - - if ($ret >= 0 && !count($object->errors)) { - setEventMessages($langs->trans("AssetTypeModified"), null, 'mesgs'); - } else { - setEventMessages($object->error, $object->errors, 'errors'); - } - - header("Location: ".$_SERVER["PHP_SELF"]."?rowid=".$object->id); - exit; -} - -if ($action == 'confirm_delete' && $user->rights->asset->write) { - $object->fetch($rowid); - $res = $object->delete(); - - if ($res > 0) { - setEventMessages($langs->trans("AssetsTypeDeleted"), null, 'mesgs'); - header("Location: ".$_SERVER["PHP_SELF"]); - exit; - } else { - setEventMessages($langs->trans("AssetsTypeCanNotBeDeleted"), null, 'errors'); - $action = ''; - } -} - - -/* - * View - */ - -$form = new Form($db); - -$help_url = ''; - -llxHeader('', $langs->trans("AssetsTypeSetup"), $help_url); - - -// List of asset type -if (!$rowid && $action != 'create' && $action != 'edit') { - //print dol_get_fiche_head(''); - - $sql = "SELECT d.rowid, d.label as label, d.accountancy_code_asset, d.accountancy_code_depreciation_asset, d.accountancy_code_depreciation_expense, d.note"; - $sql .= " FROM ".MAIN_DB_PREFIX."asset_type as d"; - $sql .= " WHERE d.entity IN (".getEntity('asset_type').")"; - - $result = $db->query($sql); - if ($result) { - $num = $db->num_rows($result); - $nbtotalofrecords = $num; - - $i = 0; - - $param = ''; - - print '
    '; - if ($optioncss != '') { - print ''; - } - print ''; - print ''; - print ''; - print ''; - print ''; - print ''; - - $newcardbutton = dolGetButtonTitle($langs->trans('NewAssetType'), '', 'fa fa-plus-circle', dol_buildpath('/asset/type.php', 1).'?action=create&backtopage='.urlencode($_SERVER['PHP_SELF']), '', $permissiontoadd); - - print_barre_liste($langs->trans("AssetsTypes"), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, '', $num, $nbtotalofrecords, $object->picto, 0, $newcardbutton, '', $limit); - - $moreforfilter = ''; - - print '
    '; - print '
    '; if (!empty($val['arrayofkeyval']) && is_array($val['arrayofkeyval'])) { - print $form->selectarray('search_'.$key, $val['arrayofkeyval'], $search[$key], $val['notnull'], 0, 0, '', 1, 0, 0, '', 'maxwidth100', 1); - } elseif (strpos($val['type'], 'integer:') === 0) { - print $object->showInputField($val, $key, $search[$key], '', '', 'search_', 'maxwidth150', 1); - } elseif (!preg_match('/^(date|timestamp)/', $val['type'])) { - print ''; + print $form->selectarray('search_'.$key, $val['arrayofkeyval'], (isset($search[$key]) ? $search[$key] : ''), $val['notnull'], 0, 0, '', 1, 0, 0, '', 'maxwidth100', 1); + } elseif ((strpos($val['type'], 'integer:') === 0) || (strpos($val['type'], 'sellist:') === 0)) { + print $object->showInputField($val, $key, (isset($search[$key]) ? $search[$key] : ''), '', '', 'search_', 'maxwidth125', 1); + } elseif (preg_match('/^(date|timestamp|datetime)/', $val['type'])) { + print '
    '; + print $form->selectDate($search[$key.'_dtstart'] ? $search[$key.'_dtstart'] : '', "search_".$key."_dtstart", 0, 0, 1, '', 1, 0, 0, '', '', '', '', 1, '', $langs->trans('From')); + print '
    '; + print '
    '; + print $form->selectDate($search[$key.'_dtend'] ? $search[$key.'_dtend'] : '', "search_".$key."_dtend", 0, 0, 1, '', 1, 0, 0, '', '', '', '', 1, '', $langs->trans('to')); + print '
    '; + } elseif ($key == 'lang') { + require_once DOL_DOCUMENT_ROOT.'/core/class/html.formadmin.class.php'; + $formadmin = new FormAdmin($db); + print $formadmin->select_language($search[$key], 'search_lang', 0, null, 1, 0, 0, 'minwidth150 maxwidth200', 2); + } else { + print ''; } print '
    '; - if ($massactionbutton || $massaction) { // If we are in select mode (massactionbutton defined) or if we have already selected and sent an action ($massaction) defined + if ($massactionbutton || $massaction) { // If we are in select mode (massactionbutton defined) or if we have already selected and sent an action ($massaction) defined $selected = 0; if (in_array($object->id, $arrayofselected)) { $selected = 1; @@ -605,7 +671,7 @@ if (in_array('builddoc', $arrayofmassactions) && ($nbtotalofrecords === '' || $n $genallowed = $permissiontoread; $delallowed = $permissiontoadd; - print $formfile->showdocuments('massfilesarea_asset', '', $filedir, $urlsource, 0, $delallowed, '', 1, 1, 0, 48, 1, $param, $title, ''); + print $formfile->showdocuments('massfilesarea_asset', '', $filedir, $urlsource, 0, $delallowed, '', 1, 1, 0, 48, 1, $param, $title, '', '', '', null, $hidegeneratedfilelistifempty); } // End of page diff --git a/htdocs/asset/model/accountancy_codes.php b/htdocs/asset/model/accountancy_codes.php new file mode 100644 index 00000000000..fd5999b20b0 --- /dev/null +++ b/htdocs/asset/model/accountancy_codes.php @@ -0,0 +1,191 @@ + + * Copyright (C) 2018 Alexandre Spangaro + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file htdocs/asset/model/accountancy_code.php + * \ingroup asset + * \brief Card with accountancy code on Asset Model + */ + +require '../../main.inc.php'; +require_once DOL_DOCUMENT_ROOT . '/core/lib/asset.lib.php'; +require_once DOL_DOCUMENT_ROOT . '/asset/class/assetmodel.class.php'; +require_once DOL_DOCUMENT_ROOT . '/asset/class/assetaccountancycodes.class.php'; + +// Load translation files required by the page +$langs->loadLangs(array("assets", "companies")); + +// Get parameters +$id = GETPOST('id', 'int'); +$ref = GETPOST('ref', 'alpha'); +$action = GETPOST('action', 'aZ09'); +$cancel = GETPOST('cancel', 'aZ09'); +$backtopage = GETPOST('backtopage', 'alpha'); + +// Initialize technical objects +$object = new AssetModel($db); +$assetaccountancycodes = new AssetAccountancyCodes($db); +$extrafields = new ExtraFields($db); +$diroutputmassaction = $conf->asset->dir_output . '/temp/massgeneration/' . $user->id; +$hookmanager->initHooks(array('assetmodelaccountancycodes', 'globalcard')); // Note that conf->hooks_modules contains array +// Fetch optionals attributes and labels +$extrafields->fetch_name_optionals_label($object->table_element); + +// Load object +include DOL_DOCUMENT_ROOT . '/core/actions_fetchobject.inc.php'; // Must be include, not include_once // Must be include, not include_once. Include fetch and fetch_thirdparty but not fetch_optionals +if ($id > 0 || !empty($ref)) { + $upload_dir = $conf->asset->multidir_output[$object->entity] . "/" . $object->id; +} + +$permissiontoread = ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && $user->rights->asset->read) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($user->rights->asset->setup_advance->read))); +$permissiontoadd = ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && $user->rights->asset->write) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($user->rights->asset->setup_advance->write))); // Used by the include of actions_addupdatedelete.inc.php + +// Security check (enable the most restrictive one) +if ($user->socid > 0) accessforbidden(); +$isdraft = (($object->status == $object::STATUS_DRAFT) ? 1 : 0); +restrictedArea($user, 'asset', $object->id, $object->table_element, '', 'fk_soc', 'rowid', $isdraft); +if (empty($conf->asset->enabled)) accessforbidden(); +if (!$permissiontoread) accessforbidden(); + +$result = $assetaccountancycodes->fetchAccountancyCodes(0, $object->id); +if ($result < 0) { + setEventMessages($assetaccountancycodes->error, $assetaccountancycodes->errors, 'errors'); +} + + +/* + * Actions + */ + +$reshook = $hookmanager->executeHooks('doActions', array(), $object, $action); // Note that $action and $object may have been modified by some hooks +if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); +} +if (empty($reshook)) { + $backurlforlist = DOL_URL_ROOT.'/asset/list.php'; + + if (empty($backtopage) || ($cancel && empty($id))) { + if (empty($backtopage) || ($cancel && strpos($backtopage, '__ID__'))) { + if (empty($id) && (($action != 'add' && $action != 'create') || $cancel)) { + $backtopage = $backurlforlist; + } else { + $backtopage = DOL_URL_ROOT.'/asset/model/accountancy_codes.php?id='.((!empty($id) && $id > 0) ? $id : '__ID__'); + } + } + } + + if ($cancel) { + /*var_dump($cancel);var_dump($backtopage);var_dump($backtopageforcancel);exit;*/ + if (!empty($backtopageforcancel)) { + header("Location: ".$backtopageforcancel); + exit; + } elseif (!empty($backtopage)) { + header("Location: ".$backtopage); + exit; + } + $action = ''; + } + + if ($action == "update") { + $assetaccountancycodes->setAccountancyCodesFromPost(); + + $result = $assetaccountancycodes->updateAccountancyCodes($user, 0, $object->id); + if ($result < 0) { + setEventMessages($assetaccountancycodes->error, $assetaccountancycodes->errors, 'errors'); + $action = 'edit'; + } else { + setEventMessage($langs->trans('RecordSaved')); + header("Location: " . $_SERVER["PHP_SELF"] . '?id=' . $object->id); + exit; + } + } +} + + +/* + * View + */ + +$form = new Form($db); + +$help_url = ''; +llxHeader('', $langs->trans('AssetModel'), $help_url); + +if ($id > 0 || !empty($ref)) { + $head = assetModelPrepareHead($object); + print dol_get_fiche_head($head, 'accountancy_codes', $langs->trans("AssetModel"), -1, $object->picto); + + // Object card + // ------------------------------------------------------------ + $linkback = '' . $langs->trans("BackToList") . ''; + + $morehtmlref = '
    '; + $morehtmlref .= '
    '; + + dol_banner_tab($object, 'ref', $linkback, 1, 'ref', 'ref', $morehtmlref); + + print '
    '; + print '
    '; + print '
    '; + + if ($action == 'edit') { + print '
    '; + print ''; + print ''; + if ($backtopage) { + print ''; + } + if ($backtopageforcancel) { + print ''; + } + + print dol_get_fiche_head(array(), ''); + + include DOL_DOCUMENT_ROOT . '/asset/tpl/accountancy_codes_edit.tpl.php'; + + print dol_get_fiche_end(); + + print $form->buttonsSaveCancel(); + + print '
    '; + } else { + include DOL_DOCUMENT_ROOT . '/asset/tpl/accountancy_codes_view.tpl.php'; + } + + print dol_get_fiche_end(); + + if ($action != 'edit') { + print '
    ' . "\n"; + $parameters = array(); + $reshook = $hookmanager->executeHooks('addMoreActionsButtons', $parameters, $object, $action); // Note that $action and $object may have been modified by hook + if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); + } + + if (empty($reshook)) { + if ($object->status == $object::STATUS_DRAFT/* && !empty($object->enabled_modes)*/) { + print dolGetButtonAction($langs->trans('Modify'), '', 'default', $_SERVER["PHP_SELF"] . '?id=' . $object->id . '&action=edit&token=' . newToken(), '', $permissiontoadd); + } + } + print '
    ' . "\n"; + } +} + +// End of page +llxFooter(); +$db->close(); diff --git a/htdocs/asset/model/agenda.php b/htdocs/asset/model/agenda.php new file mode 100644 index 00000000000..cd0365a1418 --- /dev/null +++ b/htdocs/asset/model/agenda.php @@ -0,0 +1,217 @@ + + * Copyright (C) ---Put here your own copyright and developer email--- + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file htdocs/asset/model/agenda.php + * \ingroup asset + * \brief Tab of events on Asset Model + */ + +require '../../main.inc.php'; +require_once DOL_DOCUMENT_ROOT . '/core/lib/asset.lib.php'; +require_once DOL_DOCUMENT_ROOT . '/asset/class/assetmodel.class.php'; +require_once DOL_DOCUMENT_ROOT . '/contact/class/contact.class.php'; +require_once DOL_DOCUMENT_ROOT . '/core/lib/company.lib.php'; +require_once DOL_DOCUMENT_ROOT . '/core/lib/functions2.lib.php'; + +// Load translation files required by the page +$langs->loadLangs(array("assets", "other")); + +// Get parameters +$id = GETPOST('id', 'int'); +$ref = GETPOST('ref', 'alpha'); +$action = GETPOST('action', 'aZ09'); +$cancel = GETPOST('cancel', 'aZ09'); +$backtopage = GETPOST('backtopage', 'alpha'); + +if (GETPOST('actioncode', 'array')) { + $actioncode = GETPOST('actioncode', 'array', 3); + if (!count($actioncode)) { + $actioncode = '0'; + } +} else { + $actioncode = GETPOST("actioncode", "alpha", 3) ? GETPOST("actioncode", "alpha", 3) : (GETPOST("actioncode") == '0' ? '0' : (empty($conf->global->AGENDA_DEFAULT_FILTER_TYPE_FOR_OBJECT) ? '' : $conf->global->AGENDA_DEFAULT_FILTER_TYPE_FOR_OBJECT)); +} +$search_agenda_label = GETPOST('search_agenda_label'); + +$limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; +$sortfield = GETPOST("sortfield", 'alpha'); +$sortorder = GETPOST("sortorder", 'alpha'); +$page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); +if (empty($page) || $page == -1) { + $page = 0; +} // If $page is not defined, or '' or -1 +$offset = $limit * $page; +$pageprev = $page - 1; +$pagenext = $page + 1; +if (!$sortfield) { + $sortfield = 'a.datep,a.id'; +} +if (!$sortorder) { + $sortorder = 'DESC,DESC'; +} + +// Initialize technical objects +$object = new AssetModel($db); +$extrafields = new ExtraFields($db); +$diroutputmassaction = $conf->asset->dir_output . '/temp/massgeneration/' . $user->id; +$hookmanager->initHooks(array('assetmodelagenda', 'globalcard')); // Note that conf->hooks_modules contains array +// Fetch optionals attributes and labels +$extrafields->fetch_name_optionals_label($object->table_element); + +// Load object +include DOL_DOCUMENT_ROOT . '/core/actions_fetchobject.inc.php'; // Must be include, not include_once // Must be include, not include_once. Include fetch and fetch_thirdparty but not fetch_optionals +if ($id > 0 || !empty($ref)) { + $upload_dir = $conf->asset->multidir_output[$object->entity] . "/model/" . $object->id; +} + +$permissiontoread = ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && $user->rights->asset->read) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($user->rights->asset->setup_advance->read))); +$permissiontoadd = ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && $user->rights->asset->write) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($user->rights->asset->setup_advance->write))); // Used by the include of actions_addupdatedelete.inc.php + +// Security check (enable the most restrictive one) +if ($user->socid > 0) accessforbidden(); +if ($user->socid > 0) $socid = $user->socid; +$isdraft = (($object->status == $object::STATUS_DRAFT) ? 1 : 0); +restrictedArea($user, 'asset', $object->id, $object->table_element, '', 'fk_soc', 'rowid', $isdraft); +if (empty($conf->asset->enabled)) accessforbidden(); +if (!$permissiontoread) accessforbidden(); + + +/* + * Actions + */ + +$parameters = array('id' => $id); +$reshook = $hookmanager->executeHooks('doActions', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks +if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); +} + +if (empty($reshook)) { + // Cancel + if (GETPOST('cancel', 'alpha') && !empty($backtopage)) { + header("Location: " . $backtopage); + exit; + } + + // Purge search criteria + if (GETPOST('button_removefilter_x', 'alpha') || GETPOST('button_removefilter.x', 'alpha') || GETPOST('button_removefilter', 'alpha')) { // All tests are required to be compatible with all browsers + $actioncode = ''; + $search_agenda_label = ''; + } +} + + +/* + * View + */ + +$form = new Form($db); + +if ($object->id > 0) { + $title = $langs->trans("Agenda"); + //if (! empty($conf->global->MAIN_HTML_TITLE) && preg_match('/thirdpartynameonly/',$conf->global->MAIN_HTML_TITLE) && $object->name) $title=$object->name." - ".$title; + $help_url = 'EN:Module_Agenda_En'; + llxHeader('', $title, $help_url); + + if (!empty($conf->notification->enabled)) { + $langs->load("mails"); + } + $head = assetModelPrepareHead($object); + + + print dol_get_fiche_head($head, 'agenda', $langs->trans("AssetModel"), -1, $object->picto); + + // Object card + // ------------------------------------------------------------ + $linkback = '' . $langs->trans("BackToList") . ''; + + $morehtmlref = '
    '; + $morehtmlref .= '
    '; + + + dol_banner_tab($object, 'ref', $linkback, 1, 'ref', 'ref', $morehtmlref); + + print '
    '; + print '
    '; + + $object->info($object->id); + dol_print_object_info($object, 1); + + print '
    '; + + print dol_get_fiche_end(); + + + // Actions buttons + + $objthirdparty = $object; + $objcon = new stdClass(); + + $out = '&origin=' . urlencode($object->element . '@' . $object->module) . '&originid=' . urlencode($object->id); + $urlbacktopage = $_SERVER['PHP_SELF'] . '?id=' . $object->id; + $out .= '&backtopage=' . urlencode($urlbacktopage); + $permok = $user->rights->agenda->myactions->create; + if ((!empty($objthirdparty->id) || !empty($objcon->id)) && $permok) { + //$out.='trans("AddAnAction"),'filenew'); + //$out.=""; + } + + + print '
    '; + + // if (!empty($conf->agenda->enabled)) { + // if (!empty($user->rights->agenda->myactions->create) || !empty($user->rights->agenda->allactions->create)) { + // print '' . $langs->trans("AddAction") . ''; + // } else { + // print '' . $langs->trans("AddAction") . ''; + // } + // } + + print '
    '; + + // if (!empty($conf->agenda->enabled) && (!empty($user->rights->agenda->myactions->read) || !empty($user->rights->agenda->allactions->read))) { + // $param = '&id=' . $object->id . '&socid=' . $socid; + // if (!empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) { + // $param .= '&contextpage=' . urlencode($contextpage); + // } + // if ($limit > 0 && $limit != $conf->liste_limit) { + // $param .= '&limit=' . urlencode($limit); + // } + // + // + // print load_fiche_titre($langs->trans("ActionsOnAssetModel"), '', ''); + // + // // List of all actions + // $filters = array(); + // $filters['search_agenda_label'] = $search_agenda_label; + // + // // TODO Replace this with same code than into list.php + // show_actions_done($conf, $langs, $db, $object, null, 0, $actioncode, '', $filters, $sortfield, $sortorder, $object->module); + // } +} + +// End of page +llxFooter(); +$db->close(); diff --git a/htdocs/asset/model/card.php b/htdocs/asset/model/card.php new file mode 100644 index 00000000000..3e0858da55e --- /dev/null +++ b/htdocs/asset/model/card.php @@ -0,0 +1,330 @@ + + * Copyright (C) 2018 Alexandre Spangaro + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file htdocs/asset/model/card.php + * \ingroup asset + * \brief Page to create/edit/view asset Model + */ + +require '../../main.inc.php'; +require_once DOL_DOCUMENT_ROOT . '/core/lib/asset.lib.php'; +require_once DOL_DOCUMENT_ROOT . '/asset/class/assetmodel.class.php'; +require_once DOL_DOCUMENT_ROOT . '/core/class/html.formcompany.class.php'; +require_once DOL_DOCUMENT_ROOT . '/core/class/html.formfile.class.php'; + +// Load translation files required by the page +$langs->loadLangs(array("assets", "other")); + +// Get parameters +$id = GETPOST('id', 'int'); +$ref = GETPOST('ref', 'alpha'); +$action = GETPOST('action', 'aZ09'); +$confirm = GETPOST('confirm', 'alpha'); +$cancel = GETPOST('cancel', 'aZ09'); +$contextpage = GETPOST('contextpage', 'aZ') ? GETPOST('contextpage', 'aZ') : 'assetmodelcard'; // To manage different context of search +$backtopage = GETPOST('backtopage', 'alpha'); +$backtopageforcancel = GETPOST('backtopageforcancel', 'alpha'); + +// Initialize technical objects +$object = new AssetModel($db); +$extrafields = new ExtraFields($db); +$diroutputmassaction = $conf->asset->dir_output . '/temp/massgeneration/' . $user->id; +$hookmanager->initHooks(array('assetmodelcard', 'globalcard')); // Note that conf->hooks_modules contains array + +// Fetch optionals attributes and labels +$extrafields->fetch_name_optionals_label($object->table_element); + +$search_array_options = $extrafields->getOptionalsFromPost($object->table_element, '', 'search_'); + +// Initialize array of search criterias +$search_all = GETPOST("search_all", 'alpha'); +$search = array(); +foreach ($object->fields as $key => $val) { + if (GETPOST('search_' . $key, 'alpha')) { + $search[$key] = GETPOST('search_' . $key, 'alpha'); + } +} + +if (empty($action) && empty($id) && empty($ref)) { + $action = 'view'; +} + +// Load object +include DOL_DOCUMENT_ROOT . '/core/actions_fetchobject.inc.php'; // Must be include, not include_once. + +$permissiontoread = ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && $user->rights->asset->read) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($user->rights->asset->setup_advance->read))); +$permissiontoadd = ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && $user->rights->asset->write) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($user->rights->asset->setup_advance->write))); // Used by the include of actions_addupdatedelete.inc.php and actions_lineupdown.inc.php +$permissiontodelete = ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && $user->rights->asset->delete) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($user->rights->asset->setup_advance->delete))) || ($permissiontoadd && isset($object->status) && $object->status == $object::STATUS_DRAFT); +$permissionnote = $permissiontoadd; // Used by the include of actions_setnotes.inc.php +$permissiondellink = $permissiontoadd; // Used by the include of actions_dellink.inc.php +$upload_dir = $conf->asset->multidir_output[isset($object->entity) ? $object->entity : 1]; + +// Security check (enable the most restrictive one) +if ($user->socid > 0) accessforbidden(); +if ($user->socid > 0) $socid = $user->socid; +$isdraft = (($object->status == $object::STATUS_DRAFT) ? 1 : 0); +restrictedArea($user, 'asset', $object->id, $object->table_element, '', 'fk_soc', 'rowid', $isdraft); +if (empty($conf->asset->enabled)) accessforbidden(); +if (!$permissiontoread) accessforbidden(); + + +/* + * Actions + */ + +$parameters = array(); +$reshook = $hookmanager->executeHooks('doActions', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks +if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); +} + +if (empty($reshook)) { + $error = 0; + + $backurlforlist = DOL_URL_ROOT . '/asset/model/list.php'; + + if (empty($backtopage) || ($cancel && empty($id))) { + if (empty($backtopage) || ($cancel && strpos($backtopage, '__ID__'))) { + if (empty($id) && (($action != 'add' && $action != 'create') || $cancel)) { + $backtopage = $backurlforlist; + } else { + $backtopage = DOL_URL_ROOT . '/asset/model/card.php?id=' . ((!empty($id) && $id > 0) ? $id : '__ID__'); + } + } + } + + $triggermodname = 'ASSETMODEL_MODIFY'; // Name of trigger action code to execute when we modify record + + if (($action == 'edit' && !($permissiontoadd && $object->status == $object::STATUS_DRAFT)) || + ($action == 'confirm_setdraft' && !($permissiontoadd && $object->status != $object::STATUS_DRAFT)) || + ($action == 'confirm_validate' && !($permissiontoadd && $object->status != $object::STATUS_VALIDATED)) || + ($action == 'confirm_close' && !($permissiontoadd && $object->status != $object::STATUS_CANCELED)) + ) { + $action = ""; + } + + // Actions cancel, add, update, update_extras, confirm_validate, confirm_delete, confirm_deleteline, confirm_clone, confirm_close, confirm_setdraft, confirm_reopen + include DOL_DOCUMENT_ROOT . '/core/actions_addupdatedelete.inc.php'; +} + + +/* + * View + * + * Put here all code to build page + */ + +$form = new Form($db); +$formfile = new FormFile($db); + +$title = $langs->trans("AssetModel") . ' - ' . $langs->trans("Card"); +$help_url = ''; +llxHeader('', $title, $help_url); + +// Part to create +if ($action == 'create') { + print load_fiche_titre($langs->trans("NewObject", $langs->transnoentitiesnoconv("AssetModel")), '', 'object_' . $object->picto); + + print '
    '; + print ''; + print ''; + if ($backtopage) { + print ''; + } + if ($backtopageforcancel) { + print ''; + } + + print dol_get_fiche_head(array(), ''); + + // Set some default values + //if (! GETPOSTISSET('fieldname')) $_POST['fieldname'] = 'myvalue'; + + print '' . "\n"; + + // Common attributes + include DOL_DOCUMENT_ROOT . '/core/tpl/commonfields_add.tpl.php'; + + // Other attributes + include DOL_DOCUMENT_ROOT . '/core/tpl/extrafields_add.tpl.php'; + + print '
    ' . "\n"; + + print dol_get_fiche_end(); + + print $form->buttonsSaveCancel("Create"); + + print '
    '; + + //dol_set_focus('input[name="ref"]'); +} + +// Part to edit record +if (($id || $ref) && $action == 'edit') { + print load_fiche_titre($langs->trans("AssetModel"), '', 'object_' . $object->picto); + + print '
    '; + print ''; + print ''; + print ''; + if ($backtopage) { + print ''; + } + if ($backtopageforcancel) { + print ''; + } + + print dol_get_fiche_head(); + + print '' . "\n"; + + // Common attributes + include DOL_DOCUMENT_ROOT . '/core/tpl/commonfields_edit.tpl.php'; + + // Other attributes + include DOL_DOCUMENT_ROOT . '/core/tpl/extrafields_edit.tpl.php'; + + print '
    '; + + print dol_get_fiche_end(); + + print $form->buttonsSaveCancel(); + + print '
    '; +} + +// Part to show record +if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'create'))) { + $res = $object->fetch_optionals(); + + $head = assetModelPrepareHead($object); + print dol_get_fiche_head($head, 'card', $langs->trans("AssetModel"), -1, $object->picto); + + $formconfirm = ''; + + // Confirmation to delete + if ($action == 'delete') { + $formconfirm = $form->formconfirm($_SERVER["PHP_SELF"] . '?id=' . $object->id, $langs->trans('DeleteAssetModel'), $langs->trans('ConfirmDeleteObject'), 'confirm_delete', '', 0, 1); + } elseif ($action == 'clone') { + // Clone confirmation + // Create an array for form + $formquestion = array(); + $formconfirm = $form->formconfirm($_SERVER["PHP_SELF"] . '?id=' . $object->id, $langs->trans('ToClone'), $langs->trans('ConfirmCloneAsk', $object->ref), 'confirm_clone', $formquestion, 'yes', 1); + } + + // Call Hook formConfirm + $parameters = array('formConfirm' => $formconfirm); + $reshook = $hookmanager->executeHooks('formConfirm', $parameters, $object, $action); // Note that $action and $object may have been modified by hook + if (empty($reshook)) { + $formconfirm .= $hookmanager->resPrint; + } elseif ($reshook > 0) { + $formconfirm = $hookmanager->resPrint; + } + + // Print form confirm + print $formconfirm; + + + // Object card + // ------------------------------------------------------------ + $linkback = '' . $langs->trans("BackToList") . ''; + + $morehtmlref = '
    '; + $morehtmlref .= '
    '; + + + dol_banner_tab($object, 'ref', $linkback, 1, 'ref', 'ref', $morehtmlref); + + + print '
    '; + print '
    '; + print '
    '; + print '' . "\n"; + + // Common attributes + include DOL_DOCUMENT_ROOT . '/core/tpl/commonfields_view.tpl.php'; + + // Other attributes. Fields from hook formObjectOptions and Extrafields. + include DOL_DOCUMENT_ROOT . '/core/tpl/extrafields_view.tpl.php'; + + print '
    '; + print '
    '; + print '
    '; + + print '
    '; + + print dol_get_fiche_end(); + + + // Buttons for actions + if ($action != 'editline') { + print '
    ' . "\n"; + $parameters = array(); + $reshook = $hookmanager->executeHooks('addMoreActionsButtons', $parameters, $object, $action); // Note that $action and $object may have been modified by hook + if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); + } + + if (empty($reshook)) { + if ($object->status == $object::STATUS_DRAFT) { + print dolGetButtonAction($langs->trans('Modify'), '', 'default', $_SERVER["PHP_SELF"] . '?id=' . $object->id . '&action=edit&token=' . newToken(), '', $permissiontoadd); + } + + // Back to draft + if ($object->status != $object::STATUS_DRAFT) { + print dolGetButtonAction($langs->trans('SetToDraft'), '', 'default', $_SERVER["PHP_SELF"] . '?id=' . $object->id . '&action=confirm_setdraft&confirm=yes&token=' . newToken(), '', $permissiontoadd); + } + + if ($object->status != $object::STATUS_VALIDATED) { + print dolGetButtonAction($langs->trans('Enable'), '', 'default', $_SERVER['PHP_SELF'] . '?id=' . $object->id . '&action=confirm_validate&confirm=yes&token=' . newToken(), '', $permissiontoadd); + } + + if ($object->status != $object::STATUS_CANCELED) { + print dolGetButtonAction($langs->trans('Disable'), '', 'default', $_SERVER['PHP_SELF'].'?id='.$object->id.'&action=confirm_close&confirm=yes&token='.newToken(), '', $permissiontoadd); + } + + // Clone + print dolGetButtonAction($langs->trans('ToClone'), '', 'default', $_SERVER['PHP_SELF'] . '?id=' . $object->id . '&socid=' . $object->socid . '&action=clone&token=' . newToken(), '', $permissiontoadd); + + // Delete (need delete permission, or if draft, just need create/modify permission) + print dolGetButtonAction($langs->trans('Delete'), '', 'delete', $_SERVER['PHP_SELF'] . '?id=' . $object->id . '&action=delete&token=' . newToken(), '', $permissiontodelete || ($object->status == $object::STATUS_DRAFT && $permissiontoadd)); + } + print '
    ' . "\n"; + } + + print '
    '; + print ''; // ancre + + print '
    '; + + // $MAXEVENT = 10; + // + // $morehtmlcenter = dolGetButtonTitle($langs->trans('SeeAll'), '', 'fa fa-list-alt imgforviewmode', DOL_URL_ROOT . '/asset/model/agenda.php?id=' . $object->id); + // + // // List of actions on element + // include_once DOL_DOCUMENT_ROOT . '/core/class/html.formactions.class.php'; + // $formactions = new FormActions($db); + // $somethingshown = $formactions->showactions($object, $object->element.'@'.$object->module, 0, 1, '', $MAXEVENT, '', $morehtmlright); + + print '
    '; +} + +// End of page +llxFooter(); +$db->close(); diff --git a/htdocs/asset/model/depreciation_options.php b/htdocs/asset/model/depreciation_options.php new file mode 100644 index 00000000000..f5bc751663b --- /dev/null +++ b/htdocs/asset/model/depreciation_options.php @@ -0,0 +1,191 @@ + + * Copyright (C) 2018 Alexandre Spangaro + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file htdocs/asset/model/depreciation_options.php + * \ingroup asset + * \brief Card with depreciation options on Asset Model + */ + +require '../../main.inc.php'; +require_once DOL_DOCUMENT_ROOT . '/core/lib/asset.lib.php'; +require_once DOL_DOCUMENT_ROOT . '/asset/class/assetmodel.class.php'; +require_once DOL_DOCUMENT_ROOT . '/asset/class/assetdepreciationoptions.class.php'; + +// Load translation files required by the page +$langs->loadLangs(array("assets", "companies")); + +// Get parameters +$id = GETPOST('id', 'int'); +$ref = GETPOST('ref', 'alpha'); +$action = GETPOST('action', 'aZ09'); +$cancel = GETPOST('cancel', 'aZ09'); +$backtopage = GETPOST('backtopage', 'alpha'); + +// Initialize technical objects +$object = new AssetModel($db); +$assetdepreciationoptions = new AssetDepreciationOptions($db); +$extrafields = new ExtraFields($db); +$diroutputmassaction = $conf->asset->dir_output . '/temp/massgeneration/' . $user->id; +$hookmanager->initHooks(array('assetmodeldeprectationoptions', 'globalcard')); // Note that conf->hooks_modules contains array +// Fetch optionals attributes and labels +$extrafields->fetch_name_optionals_label($object->table_element); + +// Load object +include DOL_DOCUMENT_ROOT . '/core/actions_fetchobject.inc.php'; // Must be include, not include_once // Must be include, not include_once. Include fetch and fetch_thirdparty but not fetch_optionals +if ($id > 0 || !empty($ref)) { + $upload_dir = $conf->asset->multidir_output[$object->entity] . "/" . $object->id; +} + +$permissiontoread = ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && $user->rights->asset->read) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($user->rights->asset->setup_advance->read))); +$permissiontoadd = ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && $user->rights->asset->write) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($user->rights->asset->setup_advance->write))); // Used by the include of actions_addupdatedelete.inc.php + +// Security check (enable the most restrictive one) +if ($user->socid > 0) accessforbidden(); +$isdraft = (($object->status == $object::STATUS_DRAFT) ? 1 : 0); +restrictedArea($user, 'asset', $object->id, $object->table_element, '', 'fk_soc', 'rowid', $isdraft); +if (empty($conf->asset->enabled)) accessforbidden(); +if (!$permissiontoread) accessforbidden(); + +$object->asset_depreciation_options = &$assetdepreciationoptions; +$result = $assetdepreciationoptions->fetchDeprecationOptions(0, $object->id); +if ($result < 0) { + setEventMessages($assetdepreciationoptions->error, $assetdepreciationoptions->errors, 'errors'); +} + + +/* + * Actions + */ + +$reshook = $hookmanager->executeHooks('doActions', array(), $object, $action); // Note that $action and $object may have been modified by some hooks +if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); +} +if (empty($reshook)) { + $backurlforlist = DOL_URL_ROOT.'/asset/list.php'; + + if (empty($backtopage) || ($cancel && empty($id))) { + if (empty($backtopage) || ($cancel && strpos($backtopage, '__ID__'))) { + if (empty($id) && (($action != 'add' && $action != 'create') || $cancel)) { + $backtopage = $backurlforlist; + } else { + $backtopage = DOL_URL_ROOT.'/asset/model/depreciation_options.php?id='.((!empty($id) && $id > 0) ? $id : '__ID__'); + } + } + } + + if ($cancel) { + /*var_dump($cancel);var_dump($backtopage);var_dump($backtopageforcancel);exit;*/ + if (!empty($backtopageforcancel)) { + header("Location: ".$backtopageforcancel); + exit; + } elseif (!empty($backtopage)) { + header("Location: ".$backtopage); + exit; + } + $action = ''; + } + + if ($action == "update") { + $result = $assetdepreciationoptions->setDeprecationOptionsFromPost(1); + if ($result > 0) $result = $assetdepreciationoptions->updateDeprecationOptions($user, 0, $object->id); + if ($result < 0) { + setEventMessages($assetdepreciationoptions->error, $assetdepreciationoptions->errors, 'errors'); + $action = 'edit'; + } else { + setEventMessage($langs->trans('RecordSaved')); + header("Location: " . $_SERVER["PHP_SELF"] . '?id=' . $object->id); + exit; + } + } +} + + +/* + * View + */ + +$form = new Form($db); + +$help_url = ''; +llxHeader('', $langs->trans('AssetModel'), $help_url); + +if ($id > 0 || !empty($ref)) { + $head = assetModelPrepareHead($object); + print dol_get_fiche_head($head, 'depreciation_options', $langs->trans("AssetModel"), -1, $object->picto); + + // Object card + // ------------------------------------------------------------ + $linkback = '' . $langs->trans("BackToList") . ''; + + $morehtmlref = '
    '; + $morehtmlref .= '
    '; + + dol_banner_tab($object, 'ref', $linkback, 1, 'ref', 'ref', $morehtmlref); + + print '
    '; + print '
    '; + print '
    '; + + if ($action == 'edit') { + print '
    '; + print ''; + print ''; + if ($backtopage) { + print ''; + } + if ($backtopageforcancel) { + print ''; + } + + print dol_get_fiche_head(array(), ''); + + include DOL_DOCUMENT_ROOT . '/asset/tpl/depreciation_options_edit.tpl.php'; + + print dol_get_fiche_end(); + + print $form->buttonsSaveCancel(); + + print '
    '; + } else { + include DOL_DOCUMENT_ROOT . '/asset/tpl/depreciation_options_view.tpl.php'; + } + + print dol_get_fiche_end(); + + if ($action != 'edit') { + print '
    ' . "\n"; + $parameters = array(); + $reshook = $hookmanager->executeHooks('addMoreActionsButtons', $parameters, $object, $action); // Note that $action and $object may have been modified by hook + if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); + } + + if (empty($reshook)) { + if ($object->status == $object::STATUS_DRAFT/* && !empty($object->enabled_modes)*/) { + print dolGetButtonAction($langs->trans('Modify'), '', 'default', $_SERVER["PHP_SELF"] . '?id=' . $object->id . '&action=edit&token=' . newToken(), '', $permissiontoadd); + } + } + print '
    ' . "\n"; + } +} + +// End of page +llxFooter(); +$db->close(); diff --git a/htdocs/asset/model/list.php b/htdocs/asset/model/list.php new file mode 100644 index 00000000000..a6423bb3a73 --- /dev/null +++ b/htdocs/asset/model/list.php @@ -0,0 +1,681 @@ + + * Copyright (C) 2018 Alexandre Spangaro + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file htdocs/asset/model/list.php + * \ingroup asset + * \brief List page for asset model + */ + +// Load Dolibarr environment +require '../../main.inc.php'; +require_once DOL_DOCUMENT_ROOT.'/core/class/html.formcompany.class.php'; +require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php'; +require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php'; +require_once DOL_DOCUMENT_ROOT.'/asset/class/assetmodel.class.php'; + +// Load translation files required by the page +$langs->loadLangs(array("assets", "other")); + +$action = GETPOST('action', 'aZ09') ?GETPOST('action', 'aZ09') : 'view'; // The action 'add', 'create', 'edit', 'update', 'view', ... +$massaction = GETPOST('massaction', 'alpha'); // The bulk action (combo box choice into lists) +$show_files = GETPOST('show_files', 'int'); // Show files area generated by bulk actions ? +$confirm = GETPOST('confirm', 'alpha'); // Result of a confirmation +$cancel = GETPOST('cancel', 'alpha'); // We click on a Cancel button +$toselect = GETPOST('toselect', 'array'); // Array of ids of elements selected into a list +$contextpage = GETPOST('contextpage', 'aZ') ? GETPOST('contextpage', 'aZ') : 'assetmodellist'; // To manage different context of search +$backtopage = GETPOST('backtopage', 'alpha'); // Go back to a dedicated page +$optioncss = GETPOST('optioncss', 'aZ'); // Option for the css output (always '' except when 'print') + +$id = GETPOST('id', 'int'); + +// Load variable for pagination +$limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); +$page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); +if (empty($page) || $page < 0 || GETPOST('button_search', 'alpha') || GETPOST('button_removefilter', 'alpha') || (empty($toselect) && $massaction === '0')) { + $page = 0; +} // If $page is not defined, or '' or -1 or if we click on clear filters or if we select empty mass action +$offset = $limit * $page; +$pageprev = $page - 1; +$pagenext = $page + 1; + +// Initialize technical objects +$object = new AssetModel($db); +$extrafields = new ExtraFields($db); +$diroutputmassaction = $conf->asset->dir_output.'/temp/massgeneration/'.$user->id; +$hookmanager->initHooks(array('assetmodellist')); // Note that conf->hooks_modules contains array + +// Fetch optionals attributes and labels +$extrafields->fetch_name_optionals_label($object->table_element); +//$extrafields->fetch_name_optionals_label($object->table_element_line); + +$search_array_options = $extrafields->getOptionalsFromPost($object->table_element, '', 'search_'); + +// Default sort order (if not yet defined by previous GETPOST) +if (!$sortfield) { + reset($object->fields); // Reset is required to avoid key() to return null. + $sortfield = "t.".key($object->fields); // Set here default search field. By default 1st field in definition. +} +if (!$sortorder) { + $sortorder = "ASC"; +} + +// Initialize array of search criterias +$search_all = GETPOST('search_all', 'alphanohtml'); +$search = array(); +foreach ($object->fields as $key => $val) { + if ($key == 'fk_pays' && !GETPOSTISSET('search_'.$key)) { + $search[$key] = $mysoc->country_id; + } elseif (GETPOST('search_'.$key, 'alpha') !== '') { + $search[$key] = GETPOST('search_'.$key, 'alpha'); + } + if (preg_match('/^(date|timestamp|datetime)/', $val['type'])) { + $search[$key.'_dtstart'] = dol_mktime(0, 0, 0, GETPOST('search_'.$key.'_dtstartmonth', 'int'), GETPOST('search_'.$key.'_dtstartday', 'int'), GETPOST('search_'.$key.'_dtstartyear', 'int')); + $search[$key.'_dtend'] = dol_mktime(23, 59, 59, GETPOST('search_'.$key.'_dtendmonth', 'int'), GETPOST('search_'.$key.'_dtendday', 'int'), GETPOST('search_'.$key.'_dtendyear', 'int')); + } +} + +// List of fields to search into when doing a "search in all" +$fieldstosearchall = array(); +foreach ($object->fields as $key => $val) { + if (!empty($val['searchall'])) { + $fieldstosearchall['t.'.$key] = $val['label']; + } +} + +// Definition of array of fields for columns +$arrayfields = array(); +foreach ($object->fields as $key => $val) { + // If $val['visible']==0, then we never show the field + if (!empty($val['visible'])) { + $visible = (int) dol_eval($val['visible'], 1); + $arrayfields['t.'.$key] = array( + 'label'=>$val['label'], + 'checked'=>(($visible < 0) ? 0 : 1), + 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1)), + 'position'=>$val['position'], + 'help'=> isset($val['help']) ? $val['help'] : '' + ); + } +} +// Extra fields +include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_array_fields.tpl.php'; + +$object->fields = dol_sort_array($object->fields, 'position'); +$arrayfields = dol_sort_array($arrayfields, 'position'); + +$permissiontoread = ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && $user->rights->asset->read) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($user->rights->asset->setup_advance->read))); +$permissiontoadd = ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && $user->rights->asset->write) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($user->rights->asset->setup_advance->write))); +$permissiontodelete = ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && $user->rights->asset->delete) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($user->rights->asset->setup_advance->delete))); + +// Security check +if (empty($conf->asset->enabled)) { + accessforbidden('Module not enabled'); +} + +// Security check (enable the most restrictive one) +if ($user->socid > 0) accessforbidden(); +$socid = 0; if ($user->socid > 0) $socid = $user->socid; +$isdraft = (($object->status == $object::STATUS_DRAFT) ? 1 : 0); +restrictedArea($user, 'asset', $object->id, $object->table_element, '', 'fk_soc', 'rowid', $isdraft); +if (empty($conf->asset->enabled)) accessforbidden(); +if (!$permissiontoread) accessforbidden(); + + + +/* + * Actions + */ + +if (GETPOST('cancel', 'alpha')) { + $action = 'list'; + $massaction = ''; +} +if (!GETPOST('confirmmassaction', 'alpha') && $massaction != 'presend' && $massaction != 'confirm_presend') { + $massaction = ''; +} + +$parameters = array(); +$reshook = $hookmanager->executeHooks('doActions', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks +if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); +} + +if (empty($reshook)) { + // Selection of new fields + include DOL_DOCUMENT_ROOT.'/core/actions_changeselectedfields.inc.php'; + + // Purge search criteria + if (GETPOST('button_removefilter_x', 'alpha') || GETPOST('button_removefilter.x', 'alpha') || GETPOST('button_removefilter', 'alpha')) { // All tests are required to be compatible with all browsers + foreach ($object->fields as $key => $val) { + $search[$key] = ''; + if ($key == 'fk_pays') $search[$key] = $mysoc->country_id; + if (preg_match('/^(date|timestamp|datetime)/', $val['type'])) { + $search[$key.'_dtstart'] = ''; + $search[$key.'_dtend'] = ''; + } + } + $toselect = array(); + $search_array_options = array(); + } + if (GETPOST('button_removefilter_x', 'alpha') || GETPOST('button_removefilter.x', 'alpha') || GETPOST('button_removefilter', 'alpha') + || GETPOST('button_search_x', 'alpha') || GETPOST('button_search.x', 'alpha') || GETPOST('button_search', 'alpha')) { + $massaction = ''; // Protection to avoid mass action if we force a new search during a mass action confirmation + } + + // Mass actions + $objectclass = 'AssetModel'; + $objectlabel = 'AssetModel'; + $uploaddir = $conf->asset->dir_output; + include DOL_DOCUMENT_ROOT.'/core/actions_massactions.inc.php'; +} + + + +/* + * View + */ + +$form = new Form($db); + +$now = dol_now(); + +$help_url = ''; +$title = $langs->trans('ListOf', $langs->transnoentitiesnoconv("AssetModels")); +$morejs = array(); +$morecss = array(); + + +// Build and execute select +// -------------------------------------------------------------------- +$sql = 'SELECT '; +$sql .= $object->getFieldList('t'); +// Add fields from extrafields +if (!empty($extrafields->attributes[$object->table_element]['label'])) { + foreach ($extrafields->attributes[$object->table_element]['label'] as $key => $val) { + $sql .= ($extrafields->attributes[$object->table_element]['type'][$key] != 'separate' ? ", ef.".$key." as options_".$key : ''); + } +} +// Add fields from hooks +$parameters = array(); +$reshook = $hookmanager->executeHooks('printFieldListSelect', $parameters, $object); // Note that $action and $object may have been modified by hook +$sql .= preg_replace('/^,/', '', $hookmanager->resPrint); +$sql = preg_replace('/,\s*$/', '', $sql); +$sql .= " FROM ".MAIN_DB_PREFIX.$object->table_element." as t"; +if (isset($extrafields->attributes[$object->table_element]['label']) && is_array($extrafields->attributes[$object->table_element]['label']) && count($extrafields->attributes[$object->table_element]['label'])) { + $sql .= " LEFT JOIN ".MAIN_DB_PREFIX.$object->table_element."_extrafields as ef on (t.rowid = ef.fk_object)"; +} +// Add table from hooks +$parameters = array(); +$reshook = $hookmanager->executeHooks('printFieldListFrom', $parameters, $object); // Note that $action and $object may have been modified by hook +$sql .= $hookmanager->resPrint; +if ($object->ismultientitymanaged == 1) { + $sql .= " WHERE t.entity IN (".getEntity($object->element).")"; +} else { + $sql .= " WHERE 1 = 1"; +} +foreach ($search as $key => $val) { + if (array_key_exists($key, $object->fields)) { + if ($key == 'status' && $search[$key] == -1) { + continue; + } + $mode_search = (($object->isInt($object->fields[$key]) || $object->isFloat($object->fields[$key])) ? 1 : 0); + if ((strpos($object->fields[$key]['type'], 'integer:') === 0) || (strpos($object->fields[$key]['type'], 'sellist:') === 0) || !empty($object->fields[$key]['arrayofkeyval'])) { + if ($search[$key] == '-1' || ($search[$key] === '0' && (empty($object->fields[$key]['arrayofkeyval']) || !array_key_exists('0', $object->fields[$key]['arrayofkeyval'])))) { + $search[$key] = ''; + } + $mode_search = 2; + } + if ($search[$key] != '') { + $sql .= natural_search($key, $search[$key], (($key == 'status') ? 2 : $mode_search)); + } + } else { + if (preg_match('/(_dtstart|_dtend)$/', $key) && $search[$key] != '') { + $columnName = preg_replace('/(_dtstart|_dtend)$/', '', $key); + if (preg_match('/^(date|timestamp|datetime)/', $object->fields[$columnName]['type'])) { + if (preg_match('/_dtstart$/', $key)) { + $sql .= " AND t.".$columnName." >= '".$db->idate($search[$key])."'"; + } + if (preg_match('/_dtend$/', $key)) { + $sql .= " AND t." . $columnName . " <= '" . $db->idate($search[$key]) . "'"; + } + } + } + } +} +if ($search_all) { + $sql .= natural_search(array_keys($fieldstosearchall), $search_all); +} +//$sql.= dolSqlDateFilter("t.field", $search_xxxday, $search_xxxmonth, $search_xxxyear); +// Add where from extra fields +include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_search_sql.tpl.php'; +// Add where from hooks +$parameters = array(); +$reshook = $hookmanager->executeHooks('printFieldListWhere', $parameters, $object); // Note that $action and $object may have been modified by hook +$sql .= $hookmanager->resPrint; + +/* If a group by is required +$sql .= " GROUP BY "; +foreach($object->fields as $key => $val) { + $sql .= "t.".$key.", "; +} +// Add fields from extrafields +if (!empty($extrafields->attributes[$object->table_element]['label'])) { + foreach ($extrafields->attributes[$object->table_element]['label'] as $key => $val) { + $sql .= ($extrafields->attributes[$object->table_element]['type'][$key] != 'separate' ? "ef.".$key.', ' : ''); + } +} +// Add where from hooks +$parameters = array(); +$reshook = $hookmanager->executeHooks('printFieldListGroupBy', $parameters, $object); // Note that $action and $object may have been modified by hook +$sql .= $hookmanager->resPrint; +$sql = preg_replace('/,\s*$/', '', $sql); +*/ + +// Add HAVING from hooks +/* +$parameters = array(); +$reshook = $hookmanager->executeHooks('printFieldListHaving', $parameters, $object); // Note that $action and $object may have been modified by hook +$sql .= !empty($hookmanager->resPrint) ? (" HAVING 1=1 " . $hookmanager->resPrint) : ""; +*/ + +// Count total nb of records +$nbtotalofrecords = ''; +if (empty($conf->global->MAIN_DISABLE_FULL_SCANLIST)) { + /* This old and fast method to get and count full list returns all record so use a high amount of memory. + $resql = $db->query($sql); + $nbtotalofrecords = $db->num_rows($resql); + */ + /* The slow method does not consume memory on mysql (not tested on pgsql) */ + /*$resql = $db->query($sql, 0, 'auto', 1); + while ($db->fetch_object($resql)) { + $nbtotalofrecords++; + }*/ + /* The fast and low memory method to get and count full list converts the sql into a sql count */ + $sqlforcount = preg_replace('/^SELECT[a-z0-9\._\s\(\),]+FROM/i', 'SELECT COUNT(*) as nbtotalofrecords FROM', $sql); + $resql = $db->query($sqlforcount); + $objforcount = $db->fetch_object($resql); + $nbtotalofrecords = $objforcount->nbtotalofrecords; + if (($page * $limit) > $nbtotalofrecords) { // if total of record found is smaller than page * limit, goto and load page 0 + $page = 0; + $offset = 0; + } + $db->free($resql); +} + +// Complete request and execute it with limit +$sql .= $db->order($sortfield, $sortorder); +if ($limit) { + $sql .= $db->plimit($limit + 1, $offset); +} + +$resql = $db->query($sql); +if (!$resql) { + dol_print_error($db); + exit; +} + +$num = $db->num_rows($resql); + + +// Direct jump if only one record found +if ($num == 1 && !empty($conf->global->MAIN_SEARCH_DIRECT_OPEN_IF_ONLY_ONE) && $search_all && !$page) { + $obj = $db->fetch_object($resql); + $id = $obj->rowid; + header("Location: ".DOL_URL_ROOT.'/asset/model/card.php?id='.$id); + exit; +} + + +// Output page +// -------------------------------------------------------------------- + +llxHeader('', $title, $help_url, '', 0, 0, $morejs, $morecss, '', ''); + +$arrayofselected = is_array($toselect) ? $toselect : array(); + +$param = ''; +if (!empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) { + $param .= '&contextpage='.urlencode($contextpage); +} +if ($limit > 0 && $limit != $conf->liste_limit) { + $param .= '&limit='.urlencode($limit); +} +foreach ($search as $key => $val) { + if (is_array($search[$key]) && count($search[$key])) { + foreach ($search[$key] as $skey) { + if ($skey != '') { + $param .= '&search_'.$key.'[]='.urlencode($skey); + } + } + } elseif ($search[$key] != '') { + $param .= '&search_'.$key.'='.urlencode($search[$key]); + } +} +if ($optioncss != '') { + $param .= '&optioncss='.urlencode($optioncss); +} +// Add $param from extra fields +include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_search_param.tpl.php'; +// Add $param from hooks +$parameters = array(); +$reshook = $hookmanager->executeHooks('printFieldListSearchParam', $parameters, $object); // Note that $action and $object may have been modified by hook +$param .= $hookmanager->resPrint; + +// List of mass actions available +$arrayofmassactions = array( + //'validate'=>img_picto('', 'check', 'class="pictofixedwidth"').$langs->trans("Validate"), + //'generate_doc'=>img_picto('', 'pdf', 'class="pictofixedwidth"').$langs->trans("ReGeneratePDF"), + //'builddoc'=>img_picto('', 'pdf', 'class="pictofixedwidth"').$langs->trans("PDFMerge"), + //'presend'=>img_picto('', 'email', 'class="pictofixedwidth"').$langs->trans("SendByMail"), +); +if ($permissiontodelete) { + $arrayofmassactions['predelete'] = img_picto('', 'delete', 'class="pictofixedwidth"').$langs->trans("Delete"); +} +if (GETPOST('nomassaction', 'int') || in_array($massaction, array('presend', 'predelete'))) { + $arrayofmassactions = array(); +} +$massactionbutton = $form->selectMassAction('', $arrayofmassactions); + +print '
    '."\n"; +if ($optioncss != '') { + print ''; +} +print ''; +print ''; +print ''; +print ''; +print ''; +print ''; +print ''; + +$newcardbutton = dolGetButtonTitle($langs->trans('New'), '', 'fa fa-plus-circle', DOL_URL_ROOT.'/asset/model/card.php?action=create&backtopage='.urlencode($_SERVER['PHP_SELF']), '', $permissiontoadd); + +print_barre_liste($title, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 'object_'.$object->picto, 0, $newcardbutton, '', $limit, 0, 0, 1); + +// Add code for pre mass action (confirmation or email presend form) +$topicmail = "SendAssetModelRef"; +$modelmail = "assetmodel"; +$objecttmp = new AssetModel($db); +$trackid = 'assetmodel'.$object->id; +include DOL_DOCUMENT_ROOT.'/core/tpl/massactions_pre.tpl.php'; + +if ($search_all) { + foreach ($fieldstosearchall as $key => $val) { + $fieldstosearchall[$key] = $langs->trans($val); + } + print '
    '.$langs->trans("FilterOnInto", $search_all).join(', ', $fieldstosearchall).'
    '; +} + +$moreforfilter = ''; +/*$moreforfilter.='
    '; +$moreforfilter.= $langs->trans('MyFilter') . ': '; +$moreforfilter.= '
    ';*/ + +$parameters = array(); +$reshook = $hookmanager->executeHooks('printFieldPreListTitle', $parameters, $object); // Note that $action and $object may have been modified by hook +if (empty($reshook)) { + $moreforfilter .= $hookmanager->resPrint; +} else { + $moreforfilter = $hookmanager->resPrint; +} + +if (!empty($moreforfilter)) { + print '
    '; + print $moreforfilter; + print '
    '; +} + +$varpage = empty($contextpage) ? $_SERVER["PHP_SELF"] : $contextpage; +$selectedfields = $form->multiSelectArrayWithCheckbox('selectedfields', $arrayfields, $varpage); // This also change content of $arrayfields +$selectedfields .= (count($arrayofmassactions) ? $form->showCheckAddButtons('checkforselect', 1) : ''); + +print '
    '; // You can use div-table-responsive-no-min if you dont need reserved height for your table +print ''."\n"; + + +// Fields title search +// -------------------------------------------------------------------- +print ''; +foreach ($object->fields as $key => $val) { + $cssforfield = (empty($val['csslist']) ? (empty($val['css']) ? '' : $val['css']) : $val['csslist']); + if ($key == 'status') { + $cssforfield .= ($cssforfield ? ' ' : '').'center'; + } elseif (in_array($val['type'], array('date', 'datetime', 'timestamp'))) { + $cssforfield .= ($cssforfield ? ' ' : '').'center'; + } elseif (in_array($val['type'], array('timestamp'))) { + $cssforfield .= ($cssforfield ? ' ' : '').'nowrap'; + } elseif (in_array($val['type'], array('double(24,8)', 'double(6,3)', 'integer', 'real', 'price')) && $val['label'] != 'TechnicalID' && empty($val['arrayofkeyval'])) { + $cssforfield .= ($cssforfield ? ' ' : '').'right'; + } + if (!empty($arrayfields['t.'.$key]['checked'])) { + print ''; + } +} +// Extra fields +include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_search_input.tpl.php'; + +// Fields from hook +$parameters = array('arrayfields'=>$arrayfields); +$reshook = $hookmanager->executeHooks('printFieldListOption', $parameters, $object); // Note that $action and $object may have been modified by hook +print $hookmanager->resPrint; +// Action column +print ''; +print ''."\n"; + + +// Fields title label +// -------------------------------------------------------------------- +print ''; +foreach ($object->fields as $key => $val) { + $cssforfield = (empty($val['csslist']) ? (empty($val['css']) ? '' : $val['css']) : $val['csslist']); + if ($key == 'status') { + $cssforfield .= ($cssforfield ? ' ' : '').'center'; + } elseif (in_array($val['type'], array('date', 'datetime', 'timestamp'))) { + $cssforfield .= ($cssforfield ? ' ' : '').'center'; + } elseif (in_array($val['type'], array('timestamp'))) { + $cssforfield .= ($cssforfield ? ' ' : '').'nowrap'; + } elseif (in_array($val['type'], array('double(24,8)', 'double(6,3)', 'integer', 'real', 'price')) && $val['label'] != 'TechnicalID' && empty($val['arrayofkeyval'])) { + $cssforfield .= ($cssforfield ? ' ' : '').'right'; + } + if (!empty($arrayfields['t.'.$key]['checked'])) { + print getTitleFieldOfList($arrayfields['t.'.$key]['label'], 0, $_SERVER['PHP_SELF'], 't.'.$key, '', $param, ($cssforfield ? 'class="'.$cssforfield.'"' : ''), $sortfield, $sortorder, ($cssforfield ? $cssforfield.' ' : ''))."\n"; + } +} +// Extra fields +include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_search_title.tpl.php'; +// Hook fields +$parameters = array('arrayfields'=>$arrayfields, 'param'=>$param, 'sortfield'=>$sortfield, 'sortorder'=>$sortorder); +$reshook = $hookmanager->executeHooks('printFieldListTitle', $parameters, $object); // Note that $action and $object may have been modified by hook +print $hookmanager->resPrint; +// Action column +print getTitleFieldOfList($selectedfields, 0, $_SERVER["PHP_SELF"], '', '', '', '', $sortfield, $sortorder, 'center maxwidthsearch ')."\n"; +print ''."\n"; + + +// Detect if we need a fetch on each output line +$needToFetchEachLine = 0; +if (isset($extrafields->attributes[$object->table_element]['computed']) && is_array($extrafields->attributes[$object->table_element]['computed']) && count($extrafields->attributes[$object->table_element]['computed']) > 0) { + foreach ($extrafields->attributes[$object->table_element]['computed'] as $key => $val) { + if (preg_match('/\$object/', $val)) { + $needToFetchEachLine++; // There is at least one compute field that use $object + } + } +} + + +// Loop on record +// -------------------------------------------------------------------- +$i = 0; +$totalarray = array(); +$totalarray['nbfield'] = 0; +while ($i < ($limit ? min($num, $limit) : $num)) { + $obj = $db->fetch_object($resql); + if (empty($obj)) { + break; // Should not happen + } + + // Store properties in $object + $object->setVarsFromFetchObj($obj); + + // Show here line of result + print ''; + foreach ($object->fields as $key => $val) { + $cssforfield = (empty($val['csslist']) ? (empty($val['css']) ? '' : $val['css']) : $val['csslist']); + if (in_array($val['type'], array('date', 'datetime', 'timestamp'))) { + $cssforfield .= ($cssforfield ? ' ' : '').'center'; + } elseif ($key == 'status') { + $cssforfield .= ($cssforfield ? ' ' : '').'center'; + } + + if (in_array($val['type'], array('timestamp'))) { + $cssforfield .= ($cssforfield ? ' ' : '').'nowrap'; + } elseif ($key == 'ref') { + $cssforfield .= ($cssforfield ? ' ' : '').'nowrap'; + } + + if (in_array($val['type'], array('double(24,8)', 'double(6,3)', 'integer', 'real', 'price')) && !in_array($key, array('rowid', 'status')) && empty($val['arrayofkeyval'])) { + $cssforfield .= ($cssforfield ? ' ' : '').'right'; + } + //if (in_array($key, array('fk_soc', 'fk_user', 'fk_warehouse'))) $cssforfield = 'tdoverflowmax100'; + + if (!empty($arrayfields['t.'.$key]['checked'])) { + print ''; + if ($key == 'status') { + print $object->getLibStatut(5); + } elseif ($key == 'rowid') { + print $object->showOutputField($val, $key, $object->id, ''); + } else { + print $object->showOutputField($val, $key, $object->$key, ''); + } + print ''; + if (!$i) { + $totalarray['nbfield']++; + } + if (!empty($val['isameasure']) && $val['isameasure'] == 1) { + if (!$i) { + $totalarray['pos'][$totalarray['nbfield']] = 't.'.$key; + } + if (!isset($totalarray['val'])) { + $totalarray['val'] = array(); + } + if (!isset($totalarray['val']['t.'.$key])) { + $totalarray['val']['t.'.$key] = 0; + } + $totalarray['val']['t.'.$key] += $object->$key; + } + } + } + // Extra fields + include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_print_fields.tpl.php'; + // Fields from hook + $parameters = array('arrayfields'=>$arrayfields, 'object'=>$object, 'obj'=>$obj, 'i'=>$i, 'totalarray'=>&$totalarray); + $reshook = $hookmanager->executeHooks('printFieldListValue', $parameters, $object); // Note that $action and $object may have been modified by hook + print $hookmanager->resPrint; + // Action column + print ''; + if (!$i) { + $totalarray['nbfield']++; + } + + print ''."\n"; + + $i++; +} + +// Show total line +include DOL_DOCUMENT_ROOT.'/core/tpl/list_print_total.tpl.php'; + +// If no record found +if ($num == 0) { + $colspan = 1; + foreach ($arrayfields as $key => $val) { + if (!empty($val['checked'])) { + $colspan++; + } + } + print ''; +} + + +$db->free($resql); + +$parameters = array('arrayfields'=>$arrayfields, 'sql'=>$sql); +$reshook = $hookmanager->executeHooks('printFieldListFooter', $parameters, $object); // Note that $action and $object may have been modified by hook +print $hookmanager->resPrint; + +print '
    '; + if (!empty($val['arrayofkeyval']) && is_array($val['arrayofkeyval'])) { + print $form->selectarray('search_'.$key, $val['arrayofkeyval'], (isset($search[$key]) ? $search[$key] : ''), $val['notnull'], 0, 0, '', 1, 0, 0, '', 'maxwidth100', 1); + } elseif ((strpos($val['type'], 'integer:') === 0) || (strpos($val['type'], 'sellist:') === 0)) { + print $object->showInputField($val, $key, (isset($search[$key]) ? $search[$key] : ''), '', '', 'search_', 'maxwidth125', 1); + } elseif (preg_match('/^(date|timestamp|datetime)/', $val['type'])) { + print '
    '; + print $form->selectDate($search[$key.'_dtstart'] ? $search[$key.'_dtstart'] : '', "search_".$key."_dtstart", 0, 0, 1, '', 1, 0, 0, '', '', '', '', 1, '', $langs->trans('From')); + print '
    '; + print '
    '; + print $form->selectDate($search[$key.'_dtend'] ? $search[$key.'_dtend'] : '', "search_".$key."_dtend", 0, 0, 1, '', 1, 0, 0, '', '', '', '', 1, '', $langs->trans('to')); + print '
    '; + } elseif ($key == 'lang') { + require_once DOL_DOCUMENT_ROOT.'/core/class/html.formadmin.class.php'; + $formadmin = new FormAdmin($db); + print $formadmin->select_language($search[$key], 'search_lang', 0, null, 1, 0, 0, 'minwidth150 maxwidth200', 2); + } else { + print ''; + } + print '
    '; +$searchpicto = $form->showFilterButtons(); +print $searchpicto; +print '
    '; + if ($massactionbutton || $massaction) { // If we are in select mode (massactionbutton defined) or if we have already selected and sent an action ($massaction) defined + $selected = 0; + if (in_array($object->id, $arrayofselected)) { + $selected = 1; + } + print ''; + } + print '
    '.$langs->trans("NoRecordFound").'
    '."\n"; +print '
    '."\n"; + +print '
    '."\n"; + +if (in_array('builddoc', $arrayofmassactions) && ($nbtotalofrecords === '' || $nbtotalofrecords)) { + $hidegeneratedfilelistifempty = 1; + if ($massaction == 'builddoc' || $action == 'remove_file' || $show_files) { + $hidegeneratedfilelistifempty = 0; + } + + require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php'; + $formfile = new FormFile($db); + + // Show list of available documents + $urlsource = $_SERVER['PHP_SELF'].'?sortfield='.$sortfield.'&sortorder='.$sortorder; + $urlsource .= str_replace('&', '&', $param); + + $filedir = $diroutputmassaction; + $genallowed = $permissiontoread; + $delallowed = $permissiontoadd; + + print $formfile->showdocuments('massfilesarea_asset', '', $filedir, $urlsource, 0, $delallowed, '', 1, 1, 0, 48, 1, $param, $title, '', '', '', null, $hidegeneratedfilelistifempty); +} + +// End of page +llxFooter(); +$db->close(); diff --git a/htdocs/asset/model/note.php b/htdocs/asset/model/note.php new file mode 100644 index 00000000000..4af8407976f --- /dev/null +++ b/htdocs/asset/model/note.php @@ -0,0 +1,120 @@ + + * Copyright (C) 2018 Alexandre Spangaro + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file htdocs/asset/model/note.php + * \ingroup asset + * \brief Card with notes on Asset Model + */ + +require '../../main.inc.php'; +require_once DOL_DOCUMENT_ROOT . '/core/lib/asset.lib.php'; +require_once DOL_DOCUMENT_ROOT . '/asset/class/assetmodel.class.php'; + +// Load translation files required by the page +$langs->loadLangs(array("assets", "companies")); + +// Get parameters +$id = GETPOST('id', 'int'); +$ref = GETPOST('ref', 'alpha'); +$action = GETPOST('action', 'aZ09'); +$cancel = GETPOST('cancel', 'aZ09'); +$backtopage = GETPOST('backtopage', 'alpha'); + +// Initialize technical objects +$object = new AssetModel($db); +$extrafields = new ExtraFields($db); +$diroutputmassaction = $conf->asset->dir_output . '/temp/massgeneration/' . $user->id; +$hookmanager->initHooks(array('assetmodelnote', 'globalcard')); // Note that conf->hooks_modules contains array +// Fetch optionals attributes and labels +$extrafields->fetch_name_optionals_label($object->table_element); + +// Load object +include DOL_DOCUMENT_ROOT . '/core/actions_fetchobject.inc.php'; // Must be include, not include_once // Must be include, not include_once. Include fetch and fetch_thirdparty but not fetch_optionals +if ($id > 0 || !empty($ref)) { + $upload_dir = $conf->asset->multidir_output[$object->entity] . "/" . $object->id; +} + +$permissiontoread = ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && $user->rights->asset->read) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($user->rights->asset->setup_advance->read))); +$permissiontoadd = ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && $user->rights->asset->write) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($user->rights->asset->setup_advance->write))); // Used by the include of actions_addupdatedelete.inc.php +$permissionnote = $permissiontoadd; // Used by the include of actions_setnotes.inc.php + +// Security check (enable the most restrictive one) +if ($user->socid > 0) accessforbidden(); +if ($user->socid > 0) $socid = $user->socid; +$isdraft = (($object->status == $object::STATUS_DRAFT) ? 1 : 0); +restrictedArea($user, 'asset', $object->id, $object->table_element, '', 'fk_soc', 'rowid', $isdraft); +if (empty($conf->asset->enabled)) accessforbidden(); +if (!$permissiontoread) accessforbidden(); + + +/* + * Actions + */ + +$reshook = $hookmanager->executeHooks('doActions', array(), $object, $action); // Note that $action and $object may have been modified by some hooks +if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); +} +if (empty($reshook)) { + include DOL_DOCUMENT_ROOT . '/core/actions_setnotes.inc.php'; // Must be include, not include_once +} + + +/* + * View + */ + +$form = new Form($db); + +$help_url = ''; +llxHeader('', $langs->trans('AssetModel'), $help_url); + +if ($id > 0 || !empty($ref)) { + $object->fetch_thirdparty(); + + $head = assetModelPrepareHead($object); + + print dol_get_fiche_head($head, 'note', $langs->trans("AssetModel"), -1, $object->picto); + + // Object card + // ------------------------------------------------------------ + $linkback = '' . $langs->trans("BackToList") . ''; + + $morehtmlref = '
    '; + $morehtmlref .= '
    '; + + + dol_banner_tab($object, 'ref', $linkback, 1, 'ref', 'ref', $morehtmlref); + + + print '
    '; + print '
    '; + + + $cssclass = "titlefield"; + include DOL_DOCUMENT_ROOT . '/core/tpl/notes.tpl.php'; + + print '
    '; + + print dol_get_fiche_end(); +} + +// End of page +llxFooter(); +$db->close(); diff --git a/htdocs/asset/note.php b/htdocs/asset/note.php index ebd340e393d..8de86d49bb7 100644 --- a/htdocs/asset/note.php +++ b/htdocs/asset/note.php @@ -27,7 +27,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/asset.lib.php'; require_once DOL_DOCUMENT_ROOT.'/asset/class/asset.class.php'; // Load translation files required by the page -$langs->loadLangs(array("asset", "companies")); +$langs->loadLangs(array("assets", "companies")); // Get parameters $id = GETPOST('id', 'int'); @@ -40,30 +40,24 @@ $backtopage = GETPOST('backtopage', 'alpha'); $object = new Asset($db); $extrafields = new ExtraFields($db); $diroutputmassaction = $conf->asset->dir_output.'/temp/massgeneration/'.$user->id; -$hookmanager->initHooks(array('assetnote')); // Note that conf->hooks_modules contains array - +$hookmanager->initHooks(array('assetnote', 'globalcard')); // Note that conf->hooks_modules contains array // Fetch optionals attributes and labels $extrafields->fetch_name_optionals_label($object->table_element); -// Security check - Protection if external user -//if ($user->socid > 0) accessforbidden(); -//if ($user->socid > 0) $socid = $user->socid; -//$result = restrictedArea($user, 'asset', $id); - // Load object include DOL_DOCUMENT_ROOT.'/core/actions_fetchobject.inc.php'; // Must be include, not include_once // Must be include, not include_once. Include fetch and fetch_thirdparty but not fetch_optionals if ($id > 0 || !empty($ref)) { $upload_dir = $conf->asset->multidir_output[$object->entity]."/".$object->id; } -// Security check -if (!empty($user->socid)) { - $socid = $user->socid; -} -$result = restrictedArea($user, 'asset', $id); +$permissionnote = $user->rights->asset->write; // Used by the include of actions_setnotes.inc.php +$permissiontoadd = $user->rights->asset->write; // Used by the include of actions_addupdatedelete.inc.php -$permissionnote = 1; -//$permissionnote=$user->rights->asset->creer; // Used by the include of actions_setnotes.inc.php +// Security check (enable the most restrictive one) +if ($user->socid > 0) accessforbidden(); +$isdraft = (($object->status == $object::STATUS_DRAFT) ? 1 : 0); +restrictedArea($user, $object->element, $object->id, $object->table_element, '', 'fk_soc', 'rowid', $isdraft); +if (empty($conf->asset->enabled)) accessforbidden(); /* @@ -78,67 +72,28 @@ if (empty($reshook)) { include DOL_DOCUMENT_ROOT.'/core/actions_setnotes.inc.php'; // Must be include, not include_once } + /* * View */ $form = new Form($db); -//$help_url='EN:Customers_Orders|FR:Commandes_Clients|ES:Pedidos de clientes'; $help_url = ''; -llxHeader('', $langs->trans('Assets'), $help_url); +llxHeader('', $langs->trans('Asset'), $help_url); if ($id > 0 || !empty($ref)) { $object->fetch_thirdparty(); - $head = asset_prepare_head($object); + $head = assetPrepareHead($object); - print dol_get_fiche_head($head, 'note', $langs->trans("Asset"), -1, 'generic'); + print dol_get_fiche_head($head, 'note', $langs->trans("Asset"), -1, $object->picto); // Object card // ------------------------------------------------------------ - $linkback = ''.$langs->trans("BackToList").''; + $linkback = '' . $langs->trans("BackToList") . ''; $morehtmlref = '
    '; - /* - // Ref customer - $morehtmlref.=$form->editfieldkey("RefCustomer", 'ref_client', $object->ref_client, $object, 0, 'string', '', 0, 1); - $morehtmlref.=$form->editfieldval("RefCustomer", 'ref_client', $object->ref_client, $object, 0, 'string', '', null, null, '', 1); - // Thirdparty - $morehtmlref.='
    '.$langs->trans('ThirdParty') . ' : ' . $object->thirdparty->getNomUrl(1); - // Project - if (! empty($conf->projet->enabled)) - { - $langs->load("projects"); - $morehtmlref.='
    '.$langs->trans('Project') . ' '; - if ($user->rights->asset->creer) - { - if ($action != 'classify') - //$morehtmlref.='' . img_edit($langs->transnoentitiesnoconv('SetProject')) . ' : '; - $morehtmlref.=' : '; - if ($action == 'classify') { - //$morehtmlref.=$form->form_project($_SERVER['PHP_SELF'] . '?id=' . $object->id, $object->socid, $object->fk_project, 'projectid', 0, 0, 1, 1); - $morehtmlref.='
    '; - $morehtmlref.=''; - $morehtmlref.=''; - $morehtmlref.=$formproject->select_projects($object->socid, $object->fk_project, 'projectid', $maxlength, 0, 1, 0, 1, 0, 0, '', 1); - $morehtmlref.=''; - $morehtmlref.='
    '; - } else { - $morehtmlref.=$form->form_project($_SERVER['PHP_SELF'] . '?id=' . $object->id, $object->socid, $object->fk_project, 'none', 0, 0, 0, 1); - } - } else { - if (! empty($object->fk_project)) { - $proj = new Project($db); - $proj->fetch($object->fk_project); - $morehtmlref.=''; - $morehtmlref.=$proj->ref; - $morehtmlref.=''; - } else { - $morehtmlref.=''; - } - } - }*/ $morehtmlref .= '
    '; @@ -150,7 +105,7 @@ if ($id > 0 || !empty($ref)) { $cssclass = "titlefield"; - include DOL_DOCUMENT_ROOT.'/core/tpl/notes.tpl.php'; + include DOL_DOCUMENT_ROOT . '/core/tpl/notes.tpl.php'; print ''; diff --git a/htdocs/asset/tpl/accountancy_codes_edit.tpl.php b/htdocs/asset/tpl/accountancy_codes_edit.tpl.php new file mode 100644 index 00000000000..bbd2b3d797c --- /dev/null +++ b/htdocs/asset/tpl/accountancy_codes_edit.tpl.php @@ -0,0 +1,81 @@ + + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + * + * Show extrafields. It also show fields from hook formAssetAccountancyCode. Need to have following variables defined: + * $object (asset, assetmodel, ...) + * $assetaccountancycodes + * $action + * $conf + * $langs + * + * $parameters + */ + +// Protection to avoid direct call of template +if (empty($object) || !is_object($object)) { + print "Error, template page can't be called as URL"; + exit; +} + +if (!is_object($form)) { + $form = new Form($db); +} + +if (!empty($conf->accounting->enabled) && !is_object($formaccounting)) { + require_once DOL_DOCUMENT_ROOT . '/core/class/html.formaccounting.class.php'; + $formaccounting = new FormAccounting($db); +} + + +?> + +executeHooks('formAssetAccountancyCodes', $parameters, $object, $action); +print $hookmanager->resPrint; +if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); +} + +if (empty($reshook)) { + foreach ($assetaccountancycodes->accountancy_codes_fields as $mode_key => $mode_info) { + //if (empty($object->enabled_modes[$mode_key])) continue; + + print load_fiche_titre($langs->trans($mode_info['label']), '', ''); + print '
    '; + print '
    '; + print ''; + foreach ($mode_info['fields'] as $field_key => $field_info) { + $html_name = $mode_key . '_' . $field_key; + print ''; + } + print '
    ' . $langs->trans($field_info['label']) . ''; + $accountancy_code = GETPOSTISSET($html_name) ? GETPOST($html_name, 'aZ09') : (!empty($assetaccountancycodes->accountancy_codes[$mode_key][$field_key]) ? $assetaccountancycodes->accountancy_codes[$mode_key][$field_key] : ''); + if (!empty($conf->accounting->enabled)) { + print $formaccounting->select_account($accountancy_code, $html_name, 1, null, 1, 1, 'minwidth150 maxwidth300', 1); + } else { + print ''; + } + print '
    '; + print '
    '; + } +} +?> + diff --git a/htdocs/asset/tpl/accountancy_codes_view.tpl.php b/htdocs/asset/tpl/accountancy_codes_view.tpl.php new file mode 100644 index 00000000000..0d92ad8eb37 --- /dev/null +++ b/htdocs/asset/tpl/accountancy_codes_view.tpl.php @@ -0,0 +1,82 @@ + + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + * + * Show extrafields. It also show fields from hook formAssetAccountancyCode. Need to have following variables defined: + * $object (asset, assetmodel, ...) + * $assetaccountancycodes + * $action + * $conf + * $langs + * + * $parameters + */ + +// Protection to avoid direct call of template +if (empty($object) || !is_object($object)) { + print "Error, template page can't be called as URL"; + exit; +} + +if (!is_object($form)) { + $form = new Form($db); +} + + +?> + +executeHooks('formAssetAccountancyCodes', $parameters, $object, $action); +print $hookmanager->resPrint; +if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); +} + +if (empty($reshook)) { + if (!empty($conf->accounting->enabled)) require_once DOL_DOCUMENT_ROOT . '/accountancy/class/accountingaccount.class.php'; + + foreach ($assetaccountancycodes->accountancy_codes_fields as $mode_key => $mode_info) { + //if (empty($object->enabled_modes[$mode_key])) continue; + + print load_fiche_titre($langs->trans($mode_info['label']), '', ''); + print '
    '; + print '
    '; + print ''; + foreach ($mode_info['fields'] as $field_key => $field_info) { + print ''; + } + print '
    ' . $langs->trans($field_info['label']) . ''; + if (!empty($assetaccountancycodes->accountancy_codes[$mode_key][$field_key])) { + $accountancy_code = $assetaccountancycodes->accountancy_codes[$mode_key][$field_key]; + if (!empty($conf->accounting->enabled)) { + $accountingaccount = new AccountingAccount($db); + $accountingaccount->fetch('', $accountancy_code, 1); + + print $accountingaccount->getNomUrl(0, 1, 1, '', 1); + } else { + print $accountancy_code; + } + } + print '
    '; + print '
    '; + } +} +?> + diff --git a/htdocs/asset/tpl/depreciation_options_edit.tpl.php b/htdocs/asset/tpl/depreciation_options_edit.tpl.php new file mode 100644 index 00000000000..cef22936260 --- /dev/null +++ b/htdocs/asset/tpl/depreciation_options_edit.tpl.php @@ -0,0 +1,228 @@ + + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + * + * Show extrafields. It also show fields from hook formAssetAccountancyCode. Need to have following variables defined: + * $object (asset, assetmodel, ...) + * $assetaccountancycodes + * $action + * $conf + * $langs + * + * $parameters + */ + +// Protection to avoid direct call of template +if (empty($object) || !is_object($object)) { + print "Error, template page can't be called as URL"; + exit; +} + +if (!is_object($form)) { + $form = new Form($db); +} + +if (!is_object($formadmin)) { + require_once DOL_DOCUMENT_ROOT . '/core/class/html.formadmin.class.php'; + $formadmin = new FormAdmin($db); +} + + +?> + +executeHooks('formAssetDeprecationOptions', $parameters, $object, $action); +print $hookmanager->resPrint; +if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); +} + +if (empty($reshook)) { + $class_type = get_class($object) == 'Asset' ? 0 : 1; + foreach ($assetdepreciationoptions->deprecation_options_fields as $mode_key => $mode_info) { + if (!empty($mode_info['enabled_field'])) { + $info = explode(':', $mode_info['enabled_field']); + $enabled_field_info[] = array( + 'mode_key' => $info[0], + 'field_key' => $info[1], + 'value' => $info[2], + 'target' => 'block_' . $mode_key, + ); + } + + $assetdepreciationoptions->setInfosForMode($mode_key, $class_type, true); + $prefix_html_name = $mode_key . '_'; + + print '
    '; + print load_fiche_titre($langs->trans($mode_info['label']), '', ''); + print '
    '; + print '
    '; + print '
    '; + print '' . "\n"; + $mode_info['fields'] = dol_sort_array($mode_info['fields'], 'position'); + foreach ($mode_info['fields'] as $field_key => $field_info) { + // Discard if extrafield is a hidden field on form + if (abs($field_info['visible']) != 1 && abs($field_info['visible']) != 3 && abs($field_info['visible']) != 4) { + continue; + } + if (array_key_exists('enabled', $field_info) && isset($field_info['enabled']) && !verifCond($field_info['enabled'])) { + continue; // We don't want this field + } + if (!empty($field_info['column_break'])) { + print '
    '; + + // We close div and reopen for second column + print '
    '; + print '
    '; + + print '
    '; + print ''; + } + + $html_name = $prefix_html_name . $field_key; + if (!empty($field_info['enabled_field'])) { + $info = explode(':', $field_info['enabled_field']); + $enabled_field_info[] = array( + 'mode_key' => $info[0], + 'field_key' => $info[1], + 'value' => $info[2], + 'target' => 'field_' . $html_name, + ); + } + + $more_class = ''; + if (!empty($field_info['required']) || (isset($field_info['notnull']) && $field_info['notnull'] > 0)) { + $more_class .= ' fieldrequired'; + } + if (preg_match('/^(text|html)/', $val['type'])) { + $more_class .= ' tdtop'; + } + + print ''; + if (!empty($field_info['help'])) { + print $form->textwithpicto($langs->trans($field_info['label']), $langs->trans($field_info['help'])); + } else { + print $langs->trans($field_info['label']); + } + print ''; + print ''; + print ''; + } + print '
    '; + if (!empty($field_info['picto'])) { + print img_picto('', $field_info['picto'], '', false, 0, 0, '', 'pictofixedwidth'); + } + if (in_array($field_info['type'], array('int', 'integer'))) { + $value = GETPOSTISSET($html_name) ?GETPOST($html_name, 'int') : $assetdepreciationoptions->$field_key; + } elseif ($field_info['type'] == 'double') { + $value = GETPOSTISSET($html_name) ? price2num(GETPOST($html_name, 'alphanohtml')) : $assetdepreciationoptions->$field_key; + } elseif (preg_match('/^(text|html)/', $field_info['type'])) { + $tmparray = explode(':', $field_info['type']); + if (!empty($tmparray[1])) { + $check = $tmparray[1]; + } else { + $check = 'restricthtml'; + } + $value = GETPOSTISSET($html_name) ? GETPOST($html_name, $check) : $assetdepreciationoptions->$field_key; + } elseif ($field_info['type'] == 'price') { + $value = GETPOSTISSET($html_name) ? price2num(GETPOST($html_name)) : ($assetdepreciationoptions->$field_key ? price2num($assetdepreciationoptions->$field_key) : (!empty($field_info['default']) ? dol_eval($field_info['default'], 1) : 0)); + } elseif ($field_key == 'lang') { + $value = GETPOSTISSET($html_name) ? GETPOST($html_name, 'aZ09') : $assetdepreciationoptions->lang; + } else { + $value = GETPOSTISSET($html_name) ? GETPOST($html_name, 'alpha') : $assetdepreciationoptions->$field_key; + } + if (!empty($field_info['noteditable'])) { + print $assetdepreciationoptions->showOutputField($field_info, $field_key, $value, '', '', $prefix_html_name, 0); + } else { + if ($field_key == 'lang') { + print img_picto('', 'language', 'class="pictofixedwidth"'); + print $formadmin->select_language($value, $html_name, 0, null, 1, 0, 0, 'minwidth300', 2); + } else { + print $assetdepreciationoptions->showInputField($field_info, $field_key, $value, '', '', $prefix_html_name, 0); + } + } + print '
    '; + print '
    '; + print '
    '; + print '
    '; + print '
    '; + } +} + +if (!empty($enabled_field_info)) { + $enabled_field_info = json_encode($enabled_field_info); + print << +SCRIPT; +} + +?> + diff --git a/htdocs/asset/tpl/depreciation_options_view.tpl.php b/htdocs/asset/tpl/depreciation_options_view.tpl.php new file mode 100644 index 00000000000..2660fbbaee7 --- /dev/null +++ b/htdocs/asset/tpl/depreciation_options_view.tpl.php @@ -0,0 +1,154 @@ + + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + * + * Show extrafields. It also show fields from hook formAssetAccountancyCode. Need to have following variables defined: + * $object (asset, assetmodel, ...) + * $assetaccountancycodes + * $action + * $conf + * $langs + * + * $parameters + */ + +// Protection to avoid direct call of template +if (empty($object) || !is_object($object)) { + print "Error, template page can't be called as URL"; + exit; +} + +if (!is_object($form)) { + $form = new Form($db); +} + + +?> + +executeHooks('formAssetDeprecationOptions', $parameters, $object, $action); +print $hookmanager->resPrint; +if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); +} + +if (empty($reshook)) { + $class_type = get_class($object) == 'Asset' ? 0 : 1; + foreach ($assetdepreciationoptions->deprecation_options_fields as $mode_key => $mode_info) { + if (!empty($mode_info['enabled_field'])) { + $info = explode(':', $mode_info['enabled_field']); + if ($assetdepreciationoptions->deprecation_options[$info[0]][$info[1]] != $info[2]) { + continue; + } + } + + $assetdepreciationoptions->setInfosForMode($mode_key, $class_type, true); + + print load_fiche_titre($langs->trans($mode_info['label']), '', ''); + print '
    '; + print '
    '; + print '
    '; + print '' . "\n"; + $mode_info['fields'] = dol_sort_array($mode_info['fields'], 'position'); + foreach ($mode_info['fields'] as $field_key => $field_info) { + if (!empty($field_info['enabled_field'])) { + $info = explode(':', $field_info['enabled_field']); + if ($assetdepreciationoptions->deprecation_options[$info[0]][$info[1]] != $info[2]) { + continue; + } + } + // Discard if extrafield is a hidden field on form + if (abs($field_info['visible']) != 1 && abs($field_info['visible']) != 3 && abs($field_info['visible']) != 4 && abs($field_info['visible']) != 5) { + continue; + } + if (array_key_exists('enabled', $field_info) && isset($field_info['enabled']) && !verifCond($field_info['enabled'])) { + continue; // We don't want this field + } + if (!empty($field_info['column_break'])) { + print '
    '; + + // We close div and reopen for second column + print '
    '; + print '
    '; + + print '
    '; + print ''; + } + + $key = $mode_key . '_' . $field_key; + $value = $assetdepreciationoptions->deprecation_options[$mode_key][$field_key]; + + print ''; + if (!empty($field_info['help'])) { + print $form->textwithpicto($langs->trans($field_info['label']), $langs->trans($field_info['help'])); + } else { + if (isset($field_info['copytoclipboard']) && $field_info['copytoclipboard'] == 1) { + print showValueWithClipboardCPButton($value, 0, $langs->transnoentitiesnoconv($field_info['label'])); + } else { + print $langs->trans($field_info['label']); + } + } + print ''; + print ''; + print ''; + } + print '
    '; + if (in_array($field_info['type'], array('text', 'html'))) { + print '
    '; + } + if ($field_key == 'lang') { + $langs->load("languages"); + $labellang = ($value ? $langs->trans('Language_' . $value) : ''); + print picto_from_langcode($value, 'class="paddingrightonly saturatemedium opacitylow"'); + print $labellang; + } else { + if (isset($field_info['copytoclipboard']) && $field_info['copytoclipboard'] == 2) { + $out = $assetdepreciationoptions->showOutputField($field_info, $field_key, $value, '', '', $mode_key . '_', 0); + print showValueWithClipboardCPButton($out, 0, $out); + } else { + print $assetdepreciationoptions->showOutputField($field_info, $field_key, $value, '', '', $mode_key . '_', 0); + } + } + if (in_array($field_info['type'], array('text', 'html'))) { + print '
    '; + } + print '
    '; + print '
    '; + print '
    '; + print '
    '; + } +} + +?> + diff --git a/htdocs/asset/tpl/depreciation_view.tpl.php b/htdocs/asset/tpl/depreciation_view.tpl.php new file mode 100644 index 00000000000..2660fbbaee7 --- /dev/null +++ b/htdocs/asset/tpl/depreciation_view.tpl.php @@ -0,0 +1,154 @@ + + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + * + * Show extrafields. It also show fields from hook formAssetAccountancyCode. Need to have following variables defined: + * $object (asset, assetmodel, ...) + * $assetaccountancycodes + * $action + * $conf + * $langs + * + * $parameters + */ + +// Protection to avoid direct call of template +if (empty($object) || !is_object($object)) { + print "Error, template page can't be called as URL"; + exit; +} + +if (!is_object($form)) { + $form = new Form($db); +} + + +?> + +executeHooks('formAssetDeprecationOptions', $parameters, $object, $action); +print $hookmanager->resPrint; +if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); +} + +if (empty($reshook)) { + $class_type = get_class($object) == 'Asset' ? 0 : 1; + foreach ($assetdepreciationoptions->deprecation_options_fields as $mode_key => $mode_info) { + if (!empty($mode_info['enabled_field'])) { + $info = explode(':', $mode_info['enabled_field']); + if ($assetdepreciationoptions->deprecation_options[$info[0]][$info[1]] != $info[2]) { + continue; + } + } + + $assetdepreciationoptions->setInfosForMode($mode_key, $class_type, true); + + print load_fiche_titre($langs->trans($mode_info['label']), '', ''); + print '
    '; + print '
    '; + print '
    '; + print '' . "\n"; + $mode_info['fields'] = dol_sort_array($mode_info['fields'], 'position'); + foreach ($mode_info['fields'] as $field_key => $field_info) { + if (!empty($field_info['enabled_field'])) { + $info = explode(':', $field_info['enabled_field']); + if ($assetdepreciationoptions->deprecation_options[$info[0]][$info[1]] != $info[2]) { + continue; + } + } + // Discard if extrafield is a hidden field on form + if (abs($field_info['visible']) != 1 && abs($field_info['visible']) != 3 && abs($field_info['visible']) != 4 && abs($field_info['visible']) != 5) { + continue; + } + if (array_key_exists('enabled', $field_info) && isset($field_info['enabled']) && !verifCond($field_info['enabled'])) { + continue; // We don't want this field + } + if (!empty($field_info['column_break'])) { + print '
    '; + + // We close div and reopen for second column + print '
    '; + print '
    '; + + print '
    '; + print ''; + } + + $key = $mode_key . '_' . $field_key; + $value = $assetdepreciationoptions->deprecation_options[$mode_key][$field_key]; + + print ''; + if (!empty($field_info['help'])) { + print $form->textwithpicto($langs->trans($field_info['label']), $langs->trans($field_info['help'])); + } else { + if (isset($field_info['copytoclipboard']) && $field_info['copytoclipboard'] == 1) { + print showValueWithClipboardCPButton($value, 0, $langs->transnoentitiesnoconv($field_info['label'])); + } else { + print $langs->trans($field_info['label']); + } + } + print ''; + print ''; + print ''; + } + print '
    '; + if (in_array($field_info['type'], array('text', 'html'))) { + print '
    '; + } + if ($field_key == 'lang') { + $langs->load("languages"); + $labellang = ($value ? $langs->trans('Language_' . $value) : ''); + print picto_from_langcode($value, 'class="paddingrightonly saturatemedium opacitylow"'); + print $labellang; + } else { + if (isset($field_info['copytoclipboard']) && $field_info['copytoclipboard'] == 2) { + $out = $assetdepreciationoptions->showOutputField($field_info, $field_key, $value, '', '', $mode_key . '_', 0); + print showValueWithClipboardCPButton($out, 0, $out); + } else { + print $assetdepreciationoptions->showOutputField($field_info, $field_key, $value, '', '', $mode_key . '_', 0); + } + } + if (in_array($field_info['type'], array('text', 'html'))) { + print '
    '; + } + print '
    '; + print '
    '; + print '
    '; + print '
    '; + } +} + +?> + diff --git a/htdocs/asset/tpl/linkedobjectblock.tpl.php b/htdocs/asset/tpl/linkedobjectblock.tpl.php new file mode 100644 index 00000000000..59df306c829 --- /dev/null +++ b/htdocs/asset/tpl/linkedobjectblock.tpl.php @@ -0,0 +1,81 @@ + + * Copyright (C) 2013 Juanjo Menent + * Copyright (C) 2014 Marcos García + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +// Protection to avoid direct call of template +if (empty($conf) || !is_object($conf)) { + print "Error, template page can't be called as URL"; + exit; +} + +print "\n"; + +global $user; +global $noMoreLinkedObjectBlockAfter; + +$langs = $GLOBALS['langs']; +$linkedObjectBlock = $GLOBALS['linkedObjectBlock']; + +// Load translation files required by the page +$langs->load("assets"); + +$linkedObjectBlock = dol_sort_array($linkedObjectBlock, 'date', 'desc', 0, 0, 1); + +$total = 0; +$ilink = 0; +foreach ($linkedObjectBlock as $key => $objectlink) { + $ilink++; + + $trclass = 'oddeven'; + if ($ilink == count($linkedObjectBlock) && empty($noMoreLinkedObjectBlockAfter) && count($linkedObjectBlock) <= 1) { + $trclass .= ' liste_sub_total'; + } + echo '
    '.$langs->trans("Asset"); + if (!empty($showImportButton) && !empty($conf->global->MAIN_ENABLE_IMPORT_LINKED_OBJECT_LINES)) { + print ' '; + echo ''.$objectlink->getNomUrl(1).''.$objectlink->label.''.dol_print_date($objectlink->date_start, 'day').''; + if ($user->rights->asset->read) { + $total = $total + $objectlink->acquisition_value_ht; + echo price($objectlink->acquisition_value_ht); + } + echo ''.$objectlink->getLibStatut(3).''; + echo ''.img_picto($langs->transnoentitiesnoconv("RemoveLink"), 'unlink').''; + echo '
    '.$langs->trans("Total").''.price($total).'
    '."\n"; - - print ''; - print ''; - print ''; - print ''; - print ''; - print ''; - print ''; - print "\n"; - - $assettype = new AssetType($db); - - while ($i < $num) { - $objp = $db->fetch_object($result); - - $assettype->id = $objp->rowid; - $assettype->ref = $objp->rowid; - $assettype->label = $objp->rowid; - - print ''; - print ''; - print ''; - - print ''; - - print ''; - - print ''; - - if ($user->rights->asset->write) { - print ''; - } else { - print ''; - } - print ""; - $i++; - } - - // If no record found - if ($num == 0) { - $colspan = 6; - print ''; - } - - print "
    '.$langs->trans("Ref").''.$langs->trans("Label").''.$langs->trans("AccountancyCodeAsset").''.$langs->trans("AccountancyCodeDepreciationAsset").''.$langs->trans("AccountancyCodeDepreciationExpense").' 
    '; - print $assettype->getNomUrl(1); - //'.img_object($langs->trans("ShowType"),'group').' '.$objp->rowid.' - print ''.dol_escape_htmltag($objp->label).''; - if (!empty($conf->accounting->enabled)) { - $accountingaccount = new AccountingAccount($db); - $accountingaccount->fetch('', $objp->accountancy_code_asset, 1); - - print $accountingaccount->getNomUrl(0, 1, 1, '', 0); - } else { - print $objp->accountancy_code_asset; - } - print ''; - if (!empty($conf->accounting->enabled)) { - $accountingaccount2 = new AccountingAccount($db); - $accountingaccount2->fetch('', $objp->accountancy_code_depreciation_asset, 1); - - print $accountingaccount2->getNomUrl(0, 1, 1, '', 0); - } else { - print $objp->accountancy_code_depreciation_asset; - } - print ''; - if (!empty($conf->accounting->enabled)) { - $accountingaccount3 = new AccountingAccount($db); - $accountingaccount3->fetch('', $objp->accountancy_code_depreciation_expense, 1); - - print $accountingaccount3->getNomUrl(0, 1, 1, '', 0); - } else { - print $objp->accountancy_code_depreciation_expense; - } - print 'rowid.'">'.img_edit().' 
    '.$langs->trans("NoRecordFound").'
    "; - print '
    '; - - print ''; - } else { - dol_print_error($db); - } -} - - -/* ************************************************************************** */ -/* */ -/* Creation mode */ -/* */ -/* ************************************************************************** */ -if ($action == 'create') { - $object = new AssetType($db); - if (!empty($conf->accounting->enabled)) { - $formaccounting = new FormAccounting($db); - } - - print load_fiche_titre($langs->trans("NewAssetType"), '', $object->picto); - - print '
    '; - print ''; - print ''; - - print dol_get_fiche_head(''); - - print ''; - print ''; - - print ''; - - if (!empty($conf->accounting->enabled)) { - // Accountancy_code_asset - print ''; - print ''; - - // Accountancy_code_depreciation_expense - print ''; - print ''; - - // Accountancy_code_depreciation_expense - print ''; - print ''; - } else // For external software - { - // Accountancy_code_asset - print ''; - print ''; - - // Accountancy_code_depreciation_asset - print ''; - print ''; - - // Accountancy_code_depreciation_expense - print ''; - print ''; - } - - print ''; - - // Other attributes - $parameters = array(); - $reshook = $hookmanager->executeHooks('formObjectOptions', $parameters, $object, $action); // Note that $action and $object may have been modified by hook - print $hookmanager->resPrint; - if (empty($reshook)) { - print $object->showOptionals($extrafields, 'create', $parameters); - } - print ''; - print "
    '.$langs->trans("Label").'
    '.$langs->trans("AccountancyCodeAsset").''; - print $formaccounting->select_account($object->accountancy_code_asset, 'accountancy_code_asset', 1, '', 1, 1); - print '
    '.$langs->trans("AccountancyCodeDepreciationAsset").''; - print $formaccounting->select_account($object->accountancy_code_depreciation_asset, 'accountancy_code_depreciation_asset', 1, '', 1, 1); - print '
    '.$langs->trans("AccountancyCodeDepreciationExpense").''; - print $formaccounting->select_account($object->accountancy_code_depreciation_expense, 'accountancy_code_depreciation_expense', 1, '', 1, 1); - print '
    '.$langs->trans("AccountancyCodeAsset").''; - print '
    '.$langs->trans("AccountancyCodeDepreciationAsset").''; - print '
    '.$langs->trans("AccountancyCodeDepreciationExpense").''; - print '
    '.$langs->trans("Description").''; - print '
    \n"; - - print dol_get_fiche_end(); - - print $form->buttonsSaveCancel("Add"); - - print "
    \n"; -} - -/* ************************************************************************** */ -/* */ -/* View mode */ -/* */ -/* ************************************************************************** */ -if ($rowid > 0) { - if ($action != 'edit') { - $object = new AssetType($db); - $object->fetch($rowid); - $object->fetch_optionals(); - - /* - * Confirmation suppression - */ - if ($action == 'delete') { - print $form->formconfirm($_SERVER['PHP_SELF']."?rowid=".$object->id, $langs->trans("DeleteAnAssetType"), $langs->trans("ConfirmDeleteAssetType", $object->label), "confirm_delete", '', 0, 1); - } - - $head = asset_type_prepare_head($object); - - print dol_get_fiche_head($head, 'card', $langs->trans("AssetType"), -1, 'asset'); - - $linkback = ''.$langs->trans("BackToList").''; - - $morehtmlref = '
    '; - // Ref asset type - $morehtmlref .= $form->editfieldkey("Label", 'label', $object->label, $object, $user->rights->asset->write, 'string', '', 0, 1); - $morehtmlref .= $form->editfieldval("Label", 'label', $object->label, $object, $user->rights->asset->write, 'string', '', null, null, '', 1); - $morehtmlref .= '
    '; - - dol_banner_tab($object, 'rowid', $linkback, 1, 'rowid', 'ref', $morehtmlref, '', 0, '', $morehtmlright); - - print '
    '; - print '
    '; - - print ''; - - print ''; - print ''; - print ''; - - print ''; - print ''; - print ''; - - print ''; - print ''; - print ''; - - print '"; - - // Other attributes - include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_view.tpl.php'; - - print '
    '; - print $langs->trans("AccountancyCodeAsset"); - print ''; - if (!empty($conf->accounting->enabled)) { - $accountingaccount = new AccountingAccount($db); - $accountingaccount->fetch('', $object->accountancy_code_asset, 1); - - print $accountingaccount->getNomUrl(0, 1, 1, '', 1); - } else { - print $object->accountancy_code_asset; - } - print '
    '; - print $langs->trans("AccountancyCodeDepreciationAsset"); - print ''; - if (!empty($conf->accounting->enabled)) { - $accountingaccount2 = new AccountingAccount($db); - $accountingaccount2->fetch('', $object->accountancy_code_depreciation_asset, 1); - - print $accountingaccount2->getNomUrl(0, 1, 1, '', 1); - } else { - print $object->accountancy_code_depreciation_asset; - } - print '
    '; - print $langs->trans("AccountancyCodeDepreciationExpense"); - print ''; - if (!empty($conf->accounting->enabled)) { - $accountingaccount3 = new AccountingAccount($db); - $accountingaccount3->fetch('', $object->accountancy_code_depreciation_expense, 1); - - print $accountingaccount3->getNomUrl(0, 1, 1, '', 1); - } else { - print $object->accountancy_code_depreciation_expense; - } - print '
    '.$langs->trans("Description").''; - print nl2br($object->note)."
    '; - print '
    '; - - print dol_get_fiche_end(); - - /* - * Buttons - */ - - print '
    '; - - // Edit - if ($user->rights->asset->write) { - print ''; - } - - // Delete - if ($user->rights->asset->write) { - print ''; - } - - print "
    "; - } - - /* ************************************************************************** */ - /* */ - /* Edition mode */ - /* */ - /* ************************************************************************** */ - - if ($action == 'edit') { - $object = new AssetType($db); - $object->fetch($rowid); - $object->fetch_optionals(); - if (!empty($conf->accounting->enabled)) { - $formaccounting = new FormAccounting($db); - } - - $head = asset_type_prepare_head($object); - - print '
    '; - print ''; - print ''; - print ''; - - print dol_get_fiche_head($head, 'card', $langs->trans("AssetsType"), -1, 'setup'); - - print ''; - - print ''; - - print ''; - - if (!empty($conf->accounting->enabled)) { - // Accountancy_code_asset - print ''; - print ''; - - // Accountancy_code_depreciation_expense - print ''; - print ''; - - // Accountancy_code_depreciation_expense - print ''; - print ''; - } else // For external software - { - // Accountancy_code_asset - print ''; - print ''; - - // Accountancy_code_depreciation_asset - print ''; - print ''; - - // Accountancy_code_depreciation_expense - print ''; - print ''; - } - - print ''; - - // Other attributes - $parameters = array(); - $reshook = $hookmanager->executeHooks('formObjectOptions', $parameters, $act, $action); // Note that $action and $object may have been modified by hook - print $hookmanager->resPrint; - if (empty($reshook)) { - print $object->showOptionals($extrafields, 'edit', $parameters); - } - - // Other attributes - include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_edit.tpl.php'; - - print '
    '.$langs->trans("Ref").''.$object->id.'
    '.$langs->trans("Label").'
    '.$langs->trans("AccountancyCodeAsset").''; - print $formaccounting->select_account($object->accountancy_code_asset, 'accountancy_code_asset', 1, '', 1, 1); - print '
    '.$langs->trans("AccountancyCodeDepreciationAsset").''; - print $formaccounting->select_account($object->accountancy_code_depreciation_asset, 'accountancy_code_depreciation_asset', 1, '', 1, 1); - print '
    '.$langs->trans("AccountancyCodeDepreciationExpense").''; - print $formaccounting->select_account($object->accountancy_code_depreciation_expense, 'accountancy_code_depreciation_expense', 1, '', 1, 1); - print '
    '.$langs->trans("AccountancyCodeAsset").''; - print '
    '.$langs->trans("AccountancyCodeDepreciationAsset").''; - print '
    '.$langs->trans("AccountancyCodeDepreciationExpense").''; - print '
    '.$langs->trans("Description").''; - print '
    '; - - print dol_get_fiche_end(); - - print $form->buttonsSaveCancel(); - - print "
    "; - } -} - -// End of page -llxFooter(); -$db->close(); diff --git a/htdocs/barcode/codeinit.php b/htdocs/barcode/codeinit.php index be76a00099c..ef3c23eff2b 100644 --- a/htdocs/barcode/codeinit.php +++ b/htdocs/barcode/codeinit.php @@ -224,7 +224,7 @@ if ($conf->societe->enabled) { // For products if ($conf->product->enabled || $conf->product->service) { // Example 1 : Adding jquery code - print ''; // Checkbox to select from free text -print ' '.$langs->trans("FillBarCodeTypeAndValueManually").'   '; +print ''; print '
    '; if (!empty($user->rights->produit->lire) || !empty($user->rights->service->lire)) { - print ' '.$langs->trans("FillBarCodeTypeAndValueFromProduct").'   '; + print ''; print '
    '; print '
    '; $form->select_produits(GETPOST('productid', 'int'), 'productid', '', '', 0, -1, 2, '', 0, array(), 0, '1', 0, 'minwidth400imp', 1); - print '   '; + print '   '; print '
    '; } if (!empty($user->rights->societe->lire)) { - print ' '.$langs->trans("FillBarCodeTypeAndValueFromThirdParty").'   '; + print ''; print '
    '; print '
    '; print $form->select_company(GETPOST('socid', 'int'), 'socid', '', 'SelectThirdParty', 0, 0, array(), 0, 'minwidth300'); - print '   '; + print '   '; print '
    '; } diff --git a/htdocs/blockedlog/class/blockedlog.class.php b/htdocs/blockedlog/class/blockedlog.class.php index a7be2fb3630..578e1afa497 100644 --- a/htdocs/blockedlog/class/blockedlog.class.php +++ b/htdocs/blockedlog/class/blockedlog.class.php @@ -320,12 +320,12 @@ class BlockedLog $this->error++; } } elseif ($this->action == 'MODULE_SET') { - return 'System to track events into unalterable logs were enabled'; + return ''.$langs->trans("BlockedLogEnabled").''; } elseif ($this->action == 'MODULE_RESET') { if ($this->signature == '0000000000') { - return 'System to track events into unalterable logs were disabled after some recording were done. We saved a special Fingerprint to track the chain as broken.'; + return ''.$langs->trans("BlockedLogDisabled").''; } else { - return 'System to track events into unalterable logs were disabled. This is possible because no record were done yet.'; + return ''.$langs->trans("BlockedLogDisabledBis").''; } } @@ -796,7 +796,7 @@ class BlockedLog { $res = $this->db->query("UPDATE ".MAIN_DB_PREFIX."blockedlog SET certified=1 WHERE rowid=".((int) $this->id)); - if ($res === false) { + if (!$res) { return false; } diff --git a/htdocs/bom/bom_agenda.php b/htdocs/bom/bom_agenda.php index 841086399c9..2b9c6f57bbd 100644 --- a/htdocs/bom/bom_agenda.php +++ b/htdocs/bom/bom_agenda.php @@ -52,8 +52,8 @@ if (GETPOST('actioncode', 'array')) { $search_agenda_label = GETPOST('search_agenda_label'); $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/bom/bom_card.php b/htdocs/bom/bom_card.php index bd873f0052d..f6e40b511f1 100644 --- a/htdocs/bom/bom_card.php +++ b/htdocs/bom/bom_card.php @@ -148,8 +148,17 @@ if (empty($reshook)) { $error = 0; // Set if we used free entry or predefined product - $idprod = (int) GETPOST('idprod', 'int'); - $bom_child = (int) GETPOST('bom_select', 'int'); + $bom_child_id = (int) GETPOST('bom_id', 'int'); + if ($bom_child_id > 0) { + $bom_child = new BOM($db); + $res = $bom_child->fetch($bom_child_id); + if ($res) { + $idprod = $bom_child->fk_product; + } + } else { + $idprod = (int) GETPOST('idprod', 'int'); + } + $qty = price2num(GETPOST('qty', 'alpha'), 'MS'); $qty_frozen = price2num(GETPOST('qty_frozen', 'alpha'), 'MS'); $disable_stock_change = GETPOST('disable_stock_change', 'int'); @@ -173,7 +182,7 @@ if (empty($reshook)) { $bomline = new BOMLine($db); $bomline->fk_bom = $id; $bomline->fk_product = $idprod; - $bomline->fk_bom_child = $bom_child; + $bomline->fk_bom_child = $bom_child_id; $bomline->qty = $qty; $bomline->qty_frozen = (int) $qty_frozen; $bomline->disable_stock_change = (int) $disable_stock_change; @@ -242,7 +251,7 @@ if (empty($reshook)) { } } -$conf->global->BOM_SUB_BOM=1; + /* * View @@ -354,8 +363,6 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea $formquestion = array(); if (!empty($conf->bom->enabled)) { $langs->load("mrp"); - require_once DOL_DOCUMENT_ROOT.'/product/class/html.formproduct.class.php'; - $formproduct = new FormProduct($db); $forcecombo = 0; if ($conf->browser->name == 'ie') { $forcecombo = 1; // There is a bug in IE10 that make combo inside popup crazy @@ -384,8 +391,6 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea $formquestion = array(); if (!empty($conf->bom->enabled)) { $langs->load("mrp"); - require_once DOL_DOCUMENT_ROOT.'/product/class/html.formproduct.class.php'; - $formproduct = new FormProduct($db); $forcecombo = 0; if ($conf->browser->name == 'ie') { $forcecombo = 1; // There is a bug in IE10 that make combo inside popup crazy @@ -415,7 +420,6 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea if (!empty($conf->bom->enabled)) { $langs->load("mrp"); require_once DOL_DOCUMENT_ROOT.'/product/class/html.formproduct.class.php'; - $formproduct = new FormProduct($db); $forcecombo = 0; if ($conf->browser->name == 'ie') { $forcecombo = 1; // There is a bug in IE10 that make combo inside popup crazy @@ -514,7 +518,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea // Common attributes $keyforbreak = 'duration'; include DOL_DOCUMENT_ROOT.'/core/tpl/commonfields_view.tpl.php'; - + $object->calculateCosts(); print ''.$form->textwithpicto($langs->trans("TotalCost"), $langs->trans("BOMTotalCost")).''.price($object->total_cost).''; print ''.$langs->trans("UnitCost").''.price($object->unit_cost).''; @@ -585,13 +589,14 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea $(".collapse_bom").click(function() { console.log("We click on collapse"); var id_bom_line = $(this).attr('id').replace('collapse-', ''); - if($(this).text().indexOf('+') > 0) { + console.log($(this).html().indexOf('folder-open')); + if($(this).html().indexOf('folder-open') <= 0) { $('[parentid="'+ id_bom_line +'"]').show(); - $(this).html('(-) '); + $(this).html(''); } else { $('[parentid="'+ id_bom_line +'"]').hide(); - $(this).html('(+) '); + $(this).html(''); } return false; @@ -601,7 +606,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea $("#show_all").click(function() { console.log("We click on show all"); $("[class^=sub_bom_lines]").show(); - $("[class^=collapse_bom]").html('(-) '); + $("[class^=collapse_bom]").html(''); return false; }); @@ -609,7 +614,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea $("#hide_all").click(function() { console.log("We click on hide all"); $("[class^=sub_bom_lines]").hide(); - $("[class^=collapse_bom]").html('(+) '); + $("[class^=collapse_bom]").html(''); return false; }); @@ -737,14 +742,12 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea $MAXEVENT = 10; - $morehtmlright = ''; - $morehtmlright .= $langs->trans("SeeAll"); - $morehtmlright .= ''; + $morehtmlcenter = dolGetButtonTitle($langs->trans('SeeAll'), '', 'fa fa-list-alt imgforviewmode', DOL_URL_ROOT.'/bom/bom_agenda.php?id='.$object->id); // List of actions on element include_once DOL_DOCUMENT_ROOT.'/core/class/html.formactions.class.php'; $formactions = new FormActions($db); - $somethingshown = $formactions->showactions($object, $object->element, $socid, 1, '', $MAXEVENT, '', $morehtmlright); + $somethingshown = $formactions->showactions($object, $object->element, 0, 1, '', $MAXEVENT, '', $morehtmlcenter); print ''; } diff --git a/htdocs/bom/bom_document.php b/htdocs/bom/bom_document.php index c36ac32bb59..64f3cdbfac1 100644 --- a/htdocs/bom/bom_document.php +++ b/htdocs/bom/bom_document.php @@ -47,8 +47,8 @@ $ref = GETPOST('ref', 'alpha'); // Get parameters $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/bom/bom_list.php b/htdocs/bom/bom_list.php index 3cc0dc1753a..48798db9b8f 100644 --- a/htdocs/bom/bom_list.php +++ b/htdocs/bom/bom_list.php @@ -106,7 +106,7 @@ foreach ($object->fields as $key => $val) { $arrayfields['t.'.$key] = array( 'label'=>$val['label'], 'checked'=>(($visible < 0) ? 0 : 1), - 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1)), + 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1, 1, '1')), 'position'=>$val['position'], 'help'=> isset($val['help']) ? $val['help'] : '' ); diff --git a/htdocs/bom/bom_net_needs.php b/htdocs/bom/bom_net_needs.php new file mode 100644 index 00000000000..4b2d5cdecab --- /dev/null +++ b/htdocs/bom/bom_net_needs.php @@ -0,0 +1,328 @@ + + * Copyright (C) 2019 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 + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file htdocs/bom/bom_net_needs.php + * \ingroup bom + * \brief Page to create/edit/view bom + */ + +// Load Dolibarr environment +require '../main.inc.php'; +require_once DOL_DOCUMENT_ROOT.'/core/class/html.formcompany.class.php'; +require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php'; +require_once DOL_DOCUMENT_ROOT.'/bom/class/bom.class.php'; +require_once DOL_DOCUMENT_ROOT.'/bom/lib/bom.lib.php'; + +// Load translation files required by the page +$langs->loadLangs(array("mrp", "other")); + +// Get parameters +$id = GETPOST('id', 'int'); +$ref = GETPOST('ref', 'alpha'); +$action = GETPOST('action', 'aZ09'); +$confirm = GETPOST('confirm', 'alpha'); +$cancel = GETPOST('cancel', 'aZ09'); +$contextpage = GETPOST('contextpage', 'aZ') ?GETPOST('contextpage', 'aZ') : 'bomnet_needs'; // To manage different context of search +$backtopage = GETPOST('backtopage', 'alpha'); + + + +// Initialize technical objects +$object = new BOM($db); +$extrafields = new ExtraFields($db); +$diroutputmassaction = $conf->bom->dir_output.'/temp/massgeneration/'.$user->id; +$hookmanager->initHooks(array('bomnetneeds')); // Note that conf->hooks_modules contains array +// Fetch optionals attributes and labels +$extrafields->fetch_name_optionals_label($object->table_element); +$search_array_options = $extrafields->getOptionalsFromPost($object->table_element, '', 'search_'); + +// Initialize array of search criterias +$search_all = GETPOST("search_all", 'alpha'); +$search = array(); +foreach ($object->fields as $key => $val) { + if (GETPOST('search_'.$key, 'alpha')) { + $search[$key] = GETPOST('search_'.$key, 'alpha'); + } +} + +if (empty($action) && empty($id) && empty($ref)) { + $action = 'view'; +} + +// Load object +include DOL_DOCUMENT_ROOT.'/core/actions_fetchobject.inc.php'; // Must be include, not include_once. +if ($object->id > 0) { + $object->calculateCosts(); +} + + + +// Security check - Protection if external user +//if ($user->socid > 0) accessforbidden(); +//if ($user->socid > 0) $socid = $user->socid; +$isdraft = (($object->status == $object::STATUS_DRAFT) ? 1 : 0); +$result = restrictedArea($user, 'bom', $object->id, 'bom_bom', '', '', 'rowid', $isdraft); + +$permissionnote = $user->rights->bom->write; // Used by the include of actions_setnotes.inc.php +$permissiondellink = $user->rights->bom->write; // Used by the include of actions_dellink.inc.php +$permissiontoadd = $user->rights->bom->write; // Used by the include of actions_addupdatedelete.inc.php and actions_lineupdown.inc.php +$permissiontodelete = $user->rights->bom->delete || ($permissiontoadd && isset($object->status) && $object->status == $object::STATUS_DRAFT); +$upload_dir = $conf->bom->multidir_output[isset($object->entity) ? $object->entity : 1]; + + +/* + * Actions + */ + +$parameters = array(); +$reshook = $hookmanager->executeHooks('doActions', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks +if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); +} + +if (empty($reshook)) { + $error = 0; + + $backurlforlist = DOL_URL_ROOT.'/bom/bom_list.php'; + + if (empty($backtopage) || ($cancel && empty($id))) { + if (empty($backtopage) || ($cancel && strpos($backtopage, '__ID__'))) { + if (empty($id) && (($action != 'add' && $action != 'create') || $cancel)) { + $backtopage = $backurlforlist; + } else { + $backtopage = DOL_URL_ROOT.'/bom/bom_net_needs.php?id='.($id > 0 ? $id : '__ID__'); + } + } + } + if ($action == 'treeview') $object->getNetNeedsTree($TChildBom, 1); + else $object->getNetNeeds($TChildBom, 1); +} + + +/* + * View + */ + +$form = new Form($db); +$formfile = new FormFile($db); + + +$title = $langs->trans('BOM'); +$help_url ='EN:Module_BOM'; +llxHeader('', $title, $help_url); + + + +// Part to show record +if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'create'))) { + $head = bomPrepareHead($object); + print dol_get_fiche_head($head, 'net_needs', $langs->trans("BillOfMaterials"), -1, 'bom'); + + $formconfirm = ''; + + // Call Hook formConfirm + $parameters = array('formConfirm' => $formconfirm, 'lineid' => $lineid); + $reshook = $hookmanager->executeHooks('formConfirm', $parameters, $object, $action); // Note that $action and $object may have been modified by hook + if (empty($reshook)) { + $formconfirm .= $hookmanager->resPrint; + } elseif ($reshook > 0) { + $formconfirm = $hookmanager->resPrint; + } + + // Print form confirm + print $formconfirm; + + + // Object card + // ------------------------------------------------------------ + $linkback = ''.$langs->trans("BackToList").''; + + $morehtmlref = '
    '; + + $morehtmlref .= '
    '; + + + dol_banner_tab($object, 'ref', $linkback, 1, 'ref', 'ref', $morehtmlref); + + + print '
    '; + print '
    '; + print '
    '; + print ''."\n"; + + // Common attributes + $keyforbreak = 'duration'; + include DOL_DOCUMENT_ROOT.'/core/tpl/commonfields_view.tpl.php'; + + print ''; + print ''; + + // Other attributes + include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_view.tpl.php'; + + print '
    '.$form->textwithpicto($langs->trans("TotalCost"), $langs->trans("BOMTotalCost")).''.price($object->total_cost).'
    '.$langs->trans("UnitCost").''.price($object->unit_cost).'
    '; + print '
    '; + print '
    '; + + print '
    '; + + print dol_get_fiche_end(); + + $viewlink = dolGetButtonTitle($langs->trans('GroupByProduct'), '', 'fa fa-list-alt imgforviewmode', $_SERVER['PHP_SELF'].'?id='.$object->id.'&token='.newToken(), '', 1, array('morecss' => 'reposition '.($action !== 'treeview' ? 'btnTitleSelected':''))); + $viewlink .= dolGetButtonTitle($langs->trans('TreeStructure'), '', 'fa fa-stream imgforviewmode', $_SERVER['PHP_SELF'].'?id='.$object->id.'&action=treeview&token='.newToken(), '', 1, array('morecss' => 'reposition marginleftonly '.($action == 'treeview' ? 'btnTitleSelected':''))); + + print load_fiche_titre($langs->trans("BillOfMaterials"), $viewlink, 'cubes'); + + /* + * Lines + */ + $text_stock_options = $langs->trans("RealStockDesc").'
    '; + $text_stock_options .= $langs->trans("RealStockWillAutomaticallyWhen").'
    '; + $text_stock_options .= (! empty($conf->global->STOCK_CALCULATE_ON_SHIPMENT) || ! empty($conf->global->STOCK_CALCULATE_ON_SHIPMENT_CLOSE) ? '- '.$langs->trans("DeStockOnShipment").'
    ' : ''); + $text_stock_options .= (! empty($conf->global->STOCK_CALCULATE_ON_VALIDATE_ORDER) ? '- '.$langs->trans("DeStockOnValidateOrder").'
    ' : ''); + $text_stock_options .= (! empty($conf->global->STOCK_CALCULATE_ON_BILL) ? '- '.$langs->trans("DeStockOnBill").'
    ' : ''); + $text_stock_options .= (! empty($conf->global->STOCK_CALCULATE_ON_SUPPLIER_BILL) ? '- '.$langs->trans("ReStockOnBill").'
    ' : ''); + $text_stock_options .= (! empty($conf->global->STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER) ? '- '.$langs->trans("ReStockOnValidateOrder").'
    ' : ''); + $text_stock_options .= (! empty($conf->global->STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER) ? '- '.$langs->trans("ReStockOnDispatchOrder").'
    ' : ''); + $text_stock_options .= (!empty($conf->global->STOCK_CALCULATE_ON_RECEPTION) || !empty($conf->global->STOCK_CALCULATE_ON_RECEPTION_CLOSE) ? '- '.$langs->trans("StockOnReception").'
    ' : ''); + + print ''; + print "\n"; + print ''; + print ''; + print ''; + print ''; + print ''; + print ''; + if (! empty($TChildBom)) { + if ($action == 'treeview') { + foreach ($TChildBom as $fk_bom => $TProduct) { + $repeatChar = ' '; + if (! empty($TProduct['bom'])) { + if ($TProduct['parentid'] != $object->id) print ''; + else print ''; + print ''; + print ''; + print ''; + print ''; + print ''; + } + if (! empty($TProduct['product'])) { + foreach ($TProduct['product'] as $fk_product => $TInfos) { + $prod = new Product($db); + $prod->fetch($fk_product); + $prod->load_virtual_stock(); + if (empty($prod->stock_reel)) $prod->stock_reel = 0; + if ($fk_bom != $object->id) print ''; + else print ''; + print ''; + print ''; + print ''; + print ''; + print ''; + } + } + } + } else { + foreach ($TChildBom as $fk_product => $qty) { + $prod = new Product($db); + $prod->fetch($fk_product); + $prod->load_virtual_stock(); + if (empty($prod->stock_reel)) $prod->stock_reel = 0; + print ''; + print ''; + print ''; + print ''; + print ''; + print ''; + } + } + } + print ''; + print '
    '.$langs->trans('Product'); + if (! empty($conf->global->BOM_SUB_BOM) && $action == 'treeview') { + print '   '.img_picto('', 'folder-open', 'class="paddingright"').$langs->trans("ExpandAll").'  '; + print ''.img_picto('', 'folder', 'class="paddingright"').$langs->trans("UndoExpandAll").' '; + } + print ''.$langs->trans('Quantity').''.$form->textwithpicto($langs->trans("PhysicalStock"), $text_stock_options, 1).''.$form->textwithpicto($langs->trans("VirtualStock"), $langs->trans("VirtualStockDesc")).'
    '.str_repeat($repeatChar, $TProduct['level']).$TProduct['bom']->getNomUrl(1); + print ' '; + print img_picto('', 'folder-open'); + print ''; + print ''.$TProduct['qty'].'
    '.str_repeat($repeatChar, $TInfos['level']).$prod->getNomUrl(1).''.$TInfos['qty'].''.$prod->stock_reel.''.$prod->stock_theorique.'
    '.$prod->getNomUrl(1).''.$qty.''.$prod->stock_reel.''.$prod->stock_theorique.'
    '; + + + + /* + * ButAction + */ + print '
    '."\n"; + $parameters = array(); + $reshook = $hookmanager->executeHooks('addMoreActionsButtons', $parameters, $object, $action); // Note that $action and $object may have been modified by hook + if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); + } + print '
    '; + + + ?> + + + + close(); diff --git a/htdocs/bom/class/api_boms.class.php b/htdocs/bom/class/api_boms.class.php index 0eeefda9b3d..91af888ffd8 100644 --- a/htdocs/bom/class/api_boms.class.php +++ b/htdocs/bom/class/api_boms.class.php @@ -148,8 +148,9 @@ class Boms extends DolibarrApi $sql .= " AND sc.fk_user = ".((int) $search_sale); } if ($sqlfilters) { - if (!DolibarrApi::_checkFilters($sqlfilters)) { - throw new RestException(503, 'Error when validating parameter sqlfilters '.$sqlfilters); + $errormessage = ''; + if (!DolibarrApi::_checkFilters($sqlfilters, $errormessage)) { + throw new RestException(503, 'Error when validating parameter sqlfilters -> '.$errormessage); } $regexstring = '\(([^:\'\(\)]+:[^:\'\(\)]+:[^\(\)]+)\)'; $sql .= " AND (".preg_replace_callback('/'.$regexstring.'/', 'DolibarrApi::_forge_criteria_callback', $sqlfilters).")"; diff --git a/htdocs/bom/class/bom.class.php b/htdocs/bom/class/bom.class.php index fd8d4a19a75..20ff5fe27b1 100644 --- a/htdocs/bom/class/bom.class.php +++ b/htdocs/bom/class/bom.class.php @@ -789,6 +789,15 @@ class BOM extends CommonObject if (isset($this->label)) { $label .= '
    '.$langs->trans('Label').': '.$this->label; } + if (!empty($this->fk_product) && $this->fk_product > 0) { + include_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php'; + $product = new Product($db); + $resultFetch = $product->fetch($this->fk_product); + if ($resultFetch > 0) { + $label .= "
    ".$langs->trans("Product").': '.$product->ref.' - '.$product->label; + } + } + $url = DOL_URL_ROOT.'/bom/bom_card.php?id='.$this->id; @@ -838,7 +847,7 @@ class BOM extends CommonObject global $action, $hookmanager; $hookmanager->initHooks(array('bomdao')); - $parameters = array('id'=>$this->id, 'getnomurl'=>$result); + $parameters = array('id'=>$this->id, 'getnomurl' => &$result); $reshook = $hookmanager->executeHooks('getNomUrl', $parameters, $this, $action); // Note that $action and $object may have been modified by some hooks if ($reshook > 0) { $result = $hookmanager->resPrint; @@ -1055,26 +1064,89 @@ class BOM extends CommonObject $tmpproduct->cost_price = 0; $tmpproduct->pmp = 0; - $result = $tmpproduct->fetch($line->fk_product, '', '', '', 0, 1, 1); // We discard selling price and language loading - if ($result < 0) { - $this->error = $tmpproduct->error; - return -1; - } - $line->unit_cost = price2num((!empty($tmpproduct->cost_price)) ? $tmpproduct->cost_price : $tmpproduct->pmp); - if (empty($line->unit_cost)) { - if ($productFournisseur->find_min_price_product_fournisseur($line->fk_product) > 0) { - $line->unit_cost = $productFournisseur->fourn_unitprice; + if (empty($line->fk_bom_child)) { + $result = $tmpproduct->fetch($line->fk_product, '', '', '', 0, 1, 1); // We discard selling price and language loading + if ($result < 0) { + $this->error = $tmpproduct->error; + return -1; + } + $line->unit_cost = price2num((!empty($tmpproduct->cost_price)) ? $tmpproduct->cost_price : $tmpproduct->pmp); + if (empty($line->unit_cost)) { + if ($productFournisseur->find_min_price_product_fournisseur($line->fk_product) > 0) { + $line->unit_cost = $productFournisseur->fourn_unitprice; + } + } + + $line->total_cost = price2num($line->qty * $line->unit_cost, 'MT'); + + $this->total_cost += $line->total_cost; + } else { + $bom_child= new BOM($this->db); + $res = $bom_child->fetch($line->fk_bom_child); + if ($res>0) { + $bom_child->calculateCosts(); + $line->childBom[] = $bom_child; + $this->total_cost += $bom_child->total_cost * $line->qty; + } else { + $this->error = $bom_child->error; + return -2; } } - - $line->total_cost = price2num($line->qty * $line->unit_cost, 'MT'); - - $this->total_cost += $line->total_cost; } $this->total_cost = price2num($this->total_cost, 'MT'); - if ($this->qty) { + if ($this->qty > 0) { $this->unit_cost = price2num($this->total_cost / $this->qty, 'MU'); + } elseif ($this->qty < 0) { + $this->unit_cost = price2num($this->total_cost * $this->qty, 'MU'); + } + } + } + + /** + * Get Net needs by product + * + * @param array $TNetNeeds Array of ChildBom and infos linked to + * @param int $qty qty needed + * @return void + */ + public function getNetNeeds(&$TNetNeeds = array(), $qty = 0) + { + if (! empty($this->lines)) { + foreach ($this->lines as $line) { + if (! empty($line->childBom)) { + foreach ($line->childBom as $childBom) $childBom->getNetNeeds($TNetNeeds, $line->qty*$qty); + } else { + $TNetNeeds[$line->fk_product] += $line->qty*$qty; + } + } + } + } + + /** + * Get Net needs Tree by product or bom + * + * @param array $TNetNeeds Array of ChildBom and infos linked to + * @param int $qty qty needed + * @param int $level level of recursivity + * @return void + */ + public function getNetNeedsTree(&$TNetNeeds = array(), $qty = 0, $level = 0) + { + if (! empty($this->lines)) { + foreach ($this->lines as $line) { + if (! empty($line->childBom)) { + foreach ($line->childBom as $childBom) { + $TNetNeeds[$childBom->id]['bom'] = $childBom; + $TNetNeeds[$childBom->id]['parentid'] = $this->id; + $TNetNeeds[$childBom->id]['qty'] = $line->qty*$qty; + $TNetNeeds[$childBom->id]['level'] = $level; + $childBom->getNetNeedsTree($TNetNeeds, $line->qty*$qty, $level+1); + } + } else { + $TNetNeeds[$this->id]['product'][$line->fk_product]['qty'] += $line->qty * $qty; + $TNetNeeds[$this->id]['product'][$line->fk_product]['level'] = $level; + } } } } @@ -1204,6 +1276,11 @@ class BOMLine extends CommonObjectLine public $unit_cost = 0; + /** + * @var Bom array of Bom in line + */ + public $childBom = array(); + /** * Constructor * @@ -1444,7 +1521,7 @@ class BOMLine extends CommonObjectLine global $action, $hookmanager; $hookmanager->initHooks(array('bomlinedao')); - $parameters = array('id'=>$this->id, 'getnomurl'=>$result); + $parameters = array('id'=>$this->id, 'getnomurl' => &$result); $reshook = $hookmanager->executeHooks('getNomUrl', $parameters, $this, $action); // Note that $action and $object may have been modified by some hooks if ($reshook > 0) { $result = $hookmanager->resPrint; diff --git a/htdocs/bom/lib/bom.lib.php b/htdocs/bom/lib/bom.lib.php index edd9bd69ef4..954959d5d7a 100644 --- a/htdocs/bom/lib/bom.lib.php +++ b/htdocs/bom/lib/bom.lib.php @@ -56,7 +56,7 @@ function bomAdminPrepareHead() //); // to remove a tab complete_head_from_modules($conf, $langs, null, $head, $h, 'bom@mrp'); - complete_head_from_modules($conf, $langs, $object, $head, $h, 'bom@mrp', 'remove'); + complete_head_from_modules($conf, $langs, null, $head, $h, 'bom@mrp', 'remove'); return $head; } @@ -84,6 +84,11 @@ function bomPrepareHead($object) $head[$h][2] = 'card'; $h++; + $head[$h][0] = DOL_URL_ROOT."/bom/bom_net_needs.php?id=".$object->id; + $head[$h][1] = $langs->trans("BOMNetNeeds"); + $head[$h][2] = 'net_needs'; + $h++; + if (isset($object->fields['note_public']) || isset($object->fields['note_private'])) { $nbNote = 0; if (!empty($object->note_private)) { diff --git a/htdocs/bom/tpl/linkedobjectblock.tpl.php b/htdocs/bom/tpl/linkedobjectblock.tpl.php index c42da9bdb19..2737b425c9c 100644 --- a/htdocs/bom/tpl/linkedobjectblock.tpl.php +++ b/htdocs/bom/tpl/linkedobjectblock.tpl.php @@ -54,7 +54,7 @@ foreach ($linkedObjectBlock as $key => $objectlink) { echo ''; echo ''.$objectlink->getNomUrl(1).''; - echo ''; + echo ''; $result = $product_static->fetch($objectlink->fk_product); if ($result < 0) { setEventMessage($product_static->error, 'errors'); @@ -62,7 +62,7 @@ foreach ($linkedObjectBlock as $key => $objectlink) { $product_static->getNomUrl(1); } print ''; - echo ''.dol_print_date($objectlink->date_creation, 'day').''; + echo ''.dol_print_date($objectlink->date_creation, 'day').''; echo ''; if ($user->rights->commande->lire) { $total = $total + $objectlink->total_ht; diff --git a/htdocs/bom/tpl/objectline_create.tpl.php b/htdocs/bom/tpl/objectline_create.tpl.php index fc8c811379c..0a3a3b34e7a 100644 --- a/htdocs/bom/tpl/objectline_create.tpl.php +++ b/htdocs/bom/tpl/objectline_create.tpl.php @@ -107,9 +107,9 @@ if (!empty($conf->product->enabled) || !empty($conf->service->enabled)) { echo ''; } if (!empty($conf->global->BOM_SUB_BOM)) { - print '
    '.$langs->trans("or").' '.$langs->trans("BOM"); + print '
    '.$langs->trans("or").'
    '.$langs->trans("BOM"); // TODO Add component to select a BOM - print ''; + $form->select_bom(); } print ''; diff --git a/htdocs/bom/tpl/objectline_view.tpl.php b/htdocs/bom/tpl/objectline_view.tpl.php index 82626c12fec..8040310ea53 100644 --- a/htdocs/bom/tpl/objectline_view.tpl.php +++ b/htdocs/bom/tpl/objectline_view.tpl.php @@ -41,7 +41,7 @@ if (empty($object) || !is_object($object)) { } -global $forceall, $senderissupplier, $inputalsopricewithtax, $outputalsopricetotalwithtax; +global $forceall, $senderissupplier, $inputalsopricewithtax, $outputalsopricetotalwithtax, $langs; if (empty($dateSelector)) { $dateSelector = 0; @@ -83,8 +83,12 @@ $tmpproduct->fetch($line->fk_product); $tmpbom = new BOM($object->db); $res = $tmpbom->fetch($line->fk_bom_child); if ($tmpbom->id > 0) { + print $tmpproduct->getNomUrl(1); + print ' '.$langs->trans("or").' '; print $tmpbom->getNomUrl(1); - print '' . (empty($conf->global->BOM_SHOW_ALL_BOM_BY_DEFAULT) ? '(+)' : '(-)') . ' '; + print ' '; + print (empty($conf->global->BOM_SHOW_ALL_BOM_BY_DEFAULT) ? img_picto('', 'folder') : img_picto('', 'folder-open')); + print ''; } else { print $tmpproduct->getNomUrl(1); print ' - '.$tmpproduct->label; @@ -176,7 +180,8 @@ if ($action == 'selectlines') { print ''; // Select of all the sub-BOM lines -$sql = 'SELECT rowid, fk_bom_child, fk_product FROM '.MAIN_DB_PREFIX.'bom_bomline AS bl'; +// From this pont to the end of the file, we only take care of sub-BOM lines +$sql = 'SELECT rowid, fk_bom_child, fk_product, qty FROM '.MAIN_DB_PREFIX.'bom_bomline AS bl'; $sql.= ' WHERE fk_bom ='. (int) $tmpbom->id; $resql = $object->db->query($sql); @@ -187,7 +192,9 @@ if ($resql) { $sub_bom_product->fetch($obj->fk_product); $sub_bom = new BOM($object->db); - $sub_bom->fetch($obj->fk_bom_child); + if (!empty($obj->fk_bom_child)) { + $sub_bom->fetch($obj->fk_bom_child); + } $sub_bom_line = new BOMLine($object->db); $sub_bom_line->fetch($obj->rowid); @@ -199,21 +206,23 @@ if ($resql) { print ''; } - // Product - print ''.$sub_bom_product->getNomUrl(1).''; - - // Sub-BOM - if ($sub_bom_line->fk_bom_child > 0) { - print ''.$sub_bom->getNomUrl(1).''; + // Product OR BOM + print ''; + if (!empty($obj->fk_bom_child)) { + print $sub_bom_product->getNomUrl(1); + print ' '.$langs->trans('or').' '; + print $sub_bom->getNomUrl(1); } else { - print ' '; + print $sub_bom_product->getNomUrl(1); + print ''; } // Qty - print ''.price($sub_bom_line->qty * $line->qty, 0, '', 0, 0).''; if ($sub_bom_line->qty_frozen > 0) { - print ''.$sub_bom_line->qty_frozen.''; + print ''.price($sub_bom_line->qty, 0, '', 0, 0).''; + print ''.$langs->trans('Yes').''; } else { + print ''.price($sub_bom_line->qty * $line->qty, 0, '', 0, 0).''; print ' '; } @@ -227,21 +236,26 @@ if ($resql) { // Efficiency print ''.$sub_bom_line->efficiency.''; - // Cost price if it's defined - if ($sub_bom_product->cost_price > 0) { - print ''.price($sub_bom_product->cost_price * $line->qty).''; - $total_cost.= $sub_bom_product->cost_price * $line->qty; + if (!empty($sub_bom->id)) { + $sub_bom->calculateCosts(); + print ''.price($sub_bom->total_cost * $sub_bom_line->qty * $line->qty).''; + $total_cost+= $sub_bom->total_cost * $sub_bom_line->qty * $line->qty; + } elseif ($sub_bom_product->cost_price > 0) { + print ''.price($sub_bom_product->cost_price * $sub_bom_line->qty * $line->qty).''; + $total_cost+= $sub_bom_product->cost_price * $sub_bom_line->qty * $line->qty; } elseif ($sub_bom_product->pmp > 0) { // PMP if cost price isn't defined - print ''.price($sub_bom_product->pmp * $line->qty).''; - $total_cost.= $sub_bom_product->pmp * $line->qty; + print ''.price($sub_bom_product->pmp * $sub_bom_line->qty * $line->qty).''; + $total_cost.= $sub_bom_product->pmp * $sub_bom_line->qty * $line->qty; } else { // Minimum purchase price if cost price and PMP aren't defined - $sql_supplier_price = 'SELECT MIN(price) AS min_price FROM '.MAIN_DB_PREFIX.'product_fournisseur_price'; + $sql_supplier_price = 'SELECT MIN(price) AS min_price, quantity AS qty FROM '.MAIN_DB_PREFIX.'product_fournisseur_price'; $sql_supplier_price.= ' WHERE fk_product = '. (int) $sub_bom_product->id; $resql_supplier_price = $object->db->query($sql_supplier_price); if ($resql_supplier_price) { $obj = $object->db->fetch_object($resql_supplier_price); - print ''.price($obj->min_price * $line->qty).''; - $total_cost+= $obj->min_price * $line->qty; + $line_cost = $obj->min_price/$obj->qty * $sub_bom_line->qty * $line->qty; + + print ''.price($line_cost).''; + $total_cost+= $line_cost; } } diff --git a/htdocs/bookmarks/bookmarks.lib.php b/htdocs/bookmarks/bookmarks.lib.php index d24ba63ef55..e5781d98561 100644 --- a/htdocs/bookmarks/bookmarks.lib.php +++ b/htdocs/bookmarks/bookmarks.lib.php @@ -66,7 +66,7 @@ function printDropdownBookmarksList() // Url to list bookmark - $listbtn = ''; + $listbtn = ''; $listbtn .= img_picto('', 'bookmark', 'class="paddingright"').$langs->trans('Bookmarks').''; // Url to go on create new bookmark page @@ -90,7 +90,7 @@ function printDropdownBookmarksList() $bookmarkList = ''."\n"; - $formconfirm .= "\n\n"; + $formconfirm .= "\n\n"; $formconfirm .= ''; } - // Try also magic suggest - $out .= ''; if ($useempty) { $out .= ''; } - while ($obj = $db->fetch_object($resql)) { + while ($obj = $this->db->fetch_object($resql)) { $out .= ''; } $out .= ''; @@ -9388,11 +9513,11 @@ class Form } if (!empty($target)) { - $sql = "SELECT c.id FROM ".MAIN_DB_PREFIX."c_type_fees as c WHERE c.code = 'EX_KME' AND c.active = 1"; - $resql = $db->query($sql); + $sql = "SELECT c.id FROM ".$this->db->prefix()."c_type_fees as c WHERE c.code = 'EX_KME' AND c.active = 1"; + $resql = $this->db->query($sql); if ($resql) { - if ($db->num_rows($resql) > 0) { - $obj = $db->fetch_object($resql); + if ($this->db->num_rows($resql) > 0) { + $obj = $this->db->fetch_object($resql); $out .= ''; + } return $out; } @@ -527,7 +541,7 @@ class FormAccounting extends Form $out_array = array(); $sql = "SELECT DISTINCT date_format(doc_date, '%Y') as dtyear"; - $sql .= " FROM ".MAIN_DB_PREFIX."accounting_bookkeeping"; + $sql .= " FROM ".$this->db->prefix()."accounting_bookkeeping"; $sql .= " WHERE entity IN (".getEntity('accountancy').")"; $sql .= " ORDER BY date_format(doc_date, '%Y')"; dol_syslog(__METHOD__, LOG_DEBUG); diff --git a/htdocs/core/class/html.formactions.class.php b/htdocs/core/class/html.formactions.class.php index d4f4779a606..457d310492c 100644 --- a/htdocs/core/class/html.formactions.class.php +++ b/htdocs/core/class/html.formactions.class.php @@ -352,14 +352,14 @@ class FormActions * @param array|string $selected Type pre-selected (can be 'manual', 'auto' or 'AC_xxx'). Can be an array too. * @param string $htmlname Name of select field * @param string $excludetype A type to exclude ('systemauto', 'system', '') - * @param integer $onlyautoornot 1=Group all type AC_XXX into 1 line AC_MANUAL. 0=Keep details of type, -1=Keep details and add a combined line "All manual" + * @param integer $onlyautoornot 1=Group all type AC_XXX into 1 line AC_MANUAL. 0=Keep details of type, -1=Keep details and add a combined line "All manual", -2=Combined line is disabled (not implemented yet) * @param int $hideinfohelp 1=Do not show info help, 0=Show, -1=Show+Add info to tell how to set default value * @param int $multiselect 1=Allow multiselect of action type * @param int $nooutput 1=No output * @param string $morecss More css to add to SELECT component. * @return string */ - public function select_type_actions($selected = '', $htmlname = 'actioncode', $excludetype = '', $onlyautoornot = 0, $hideinfohelp = 0, $multiselect = 0, $nooutput = 0, $morecss = '') + public function select_type_actions($selected = '', $htmlname = 'actioncode', $excludetype = '', $onlyautoornot = 0, $hideinfohelp = 0, $multiselect = 0, $nooutput = 0, $morecss = 'minwidth300') { // phpcs:enable global $langs, $user, $form, $conf; @@ -373,7 +373,7 @@ class FormActions $caction = new CActionComm($this->db); // Suggest a list with manual events or all auto events - $arraylist = $caction->liste_array(1, 'code', $excludetype, $onlyautoornot); + $arraylist = $caction->liste_array(1, 'code', $excludetype, $onlyautoornot, '', 0); // If we use param 'all' instead of 'code', there is no group by include in answer but the key 'type' of answer array contains the key for the group by. if (empty($multiselect)) { // Add empty line at start only if no multiselect array_unshift($arraylist, ' '); @@ -399,7 +399,7 @@ class FormActions } $out .= $form->multiselectarray($htmlname, $arraylist, $selected, 0, 0, 'centpercent', 0, 0); } else { - $out .= $form->selectarray($htmlname, $arraylist, $selected, 0, 0, 0, '', 0, 0, 0, '', 'minwidth300'.($morecss ? ' '.$morecss : ''), 1); + $out .= $form->selectarray($htmlname, $arraylist, $selected, 0, 0, 0, '', 0, 0, 0, '', $morecss, 1); } if ($user->admin && empty($onlyautoornot) && $hideinfohelp <= 0) { diff --git a/htdocs/core/class/html.formadmin.class.php b/htdocs/core/class/html.formadmin.class.php index 13619fe5aa3..9f9a096c0b9 100644 --- a/htdocs/core/class/html.formadmin.class.php +++ b/htdocs/core/class/html.formadmin.class.php @@ -73,15 +73,19 @@ class FormAdmin $langs_available = $langs->get_available_languages(DOL_DOCUMENT_ROOT, 12, 0, $mainlangonly); - // If the language to select is not inside the list of available language and empty value is not available, we must find - // an alternative as the language code to pre-select (to avoid to have first element in list pre-selected). - if ($selected && !in_array($selected, $langs_available) && empty($showempty)) { - $tmparray = explode('_', $selected); - if (!empty($tmparray[1])) { - $selected = getLanguageCodeFromCountryCode($tmparray[1]); - } - if (empty($selected)) { - $selected = $langs->defaultlang; + // If empty value is not allowed and the language to select is not inside the list of available language and we must find + // an alternative of the language code to pre-select (to avoid to have first element in list pre-selected). + if ($selected && empty($showempty)) { + if (!is_array($selected) && !array_key_exists($selected, $langs_available)) { + $tmparray = explode('_', $selected); + if (!empty($tmparray[1])) { + $selected = getLanguageCodeFromCountryCode($tmparray[1]); + } + if (empty($selected)) { + $selected = $langs->defaultlang; + } + } else { + // If the preselected value is an array, we do not try to find alternative to preselect } } @@ -304,7 +308,7 @@ class FormAdmin if (preg_match('/\.lib/i', $filelib)) { continue; } - if (empty($conf->global->MAIN_FEATURES_LEVEL) && in_array($file, $expdevmenu)) { + if (getDolGlobalInt('MAIN_FEATURES_LEVEL') == 0 && in_array($file, $expdevmenu)) { continue; } @@ -416,7 +420,7 @@ class FormAdmin $langs->load("dict"); $sql = "SELECT code, label, width, height, unit"; - $sql .= " FROM ".MAIN_DB_PREFIX."c_paper_format"; + $sql .= " FROM ".$this->db->prefix()."c_paper_format"; $sql .= " WHERE active=1"; if ($filter) { $sql .= " AND code LIKE '%".$this->db->escape($filter)."%'"; diff --git a/htdocs/core/class/html.formbarcode.class.php b/htdocs/core/class/html.formbarcode.class.php index 23811b1f5b7..8c3d84dffa4 100644 --- a/htdocs/core/class/html.formbarcode.class.php +++ b/htdocs/core/class/html.formbarcode.class.php @@ -67,7 +67,7 @@ class FormBarCode $disable = ''; if (!empty($conf->use_javascript_ajax)) { - print "\n".''; - if (!empty($hidemargininfos)) { - print ''; + if (!empty($hidemargininfos)) { + print ''; + } } - } - print '
    '; - print ''."\n"; + print '
    '; + print '' . "\n"; - print ''; - print ''; - print ''; - print ''; - if ($conf->global->MARGIN_TYPE == "1") { - print ''; - } else { - print ''; - } - print ''; - if (!empty($conf->global->DISPLAY_MARGIN_RATES)) { - print ''; - } - if (!empty($conf->global->DISPLAY_MARK_RATES)) { - print ''; - } - print ''; - - if (!empty($conf->product->enabled)) { - //if ($marginInfo['margin_on_products'] != 0 && $marginInfo['margin_on_services'] != 0) { - print ''; - print ''; - print ''; - print ''; - print ''; + print '
    '.$langs->trans('Margins').''.$langs->trans('SellingPrice').''.$langs->trans('BuyingPrice').''.$langs->trans('CostPrice').''.$langs->trans('Margin').''.$langs->trans('MarginRate').''.$langs->trans('MarkRate').'
    '.$langs->trans('MarginOnProducts').''.price($marginInfo['pv_products']).''.price($marginInfo['pa_products']).''.price($marginInfo['margin_on_products']).'
    '; + print ''; + print ''; + print ''; + if ($conf->global->MARGIN_TYPE == "1") { + print ''; + } else { + print ''; + } + print ''; if (!empty($conf->global->DISPLAY_MARGIN_RATES)) { - print ''; + print ''; } if (!empty($conf->global->DISPLAY_MARK_RATES)) { - print ''; + print ''; } print ''; - } - if (!empty($conf->service->enabled)) { - print ''; - print ''; - print ''; - print ''; - print ''; - if (!empty($conf->global->DISPLAY_MARGIN_RATES)) { - print ''; + if (!empty($conf->product->enabled)) { + //if ($marginInfo['margin_on_products'] != 0 && $marginInfo['margin_on_services'] != 0) { + print ''; + print ''; + print ''; + print ''; + print ''; + if (!empty($conf->global->DISPLAY_MARGIN_RATES)) { + print ''; + } + if (!empty($conf->global->DISPLAY_MARK_RATES)) { + print ''; + } + print ''; } - if (!empty($conf->global->DISPLAY_MARK_RATES)) { - print ''; - } - print ''; - } - if (!empty($conf->product->enabled) && !empty($conf->service->enabled)) { - print ''; - print ''; - print ''; - print ''; - print ''; - if (!empty($conf->global->DISPLAY_MARGIN_RATES)) { - print ''; + if (!empty($conf->service->enabled)) { + print ''; + print ''; + print ''; + print ''; + print ''; + if (!empty($conf->global->DISPLAY_MARGIN_RATES)) { + print ''; + } + if (!empty($conf->global->DISPLAY_MARK_RATES)) { + print ''; + } + print ''; } - if (!empty($conf->global->DISPLAY_MARK_RATES)) { - print ''; + + if (!empty($conf->product->enabled) && !empty($conf->service->enabled)) { + print ''; + print ''; + print ''; + print ''; + print ''; + if (!empty($conf->global->DISPLAY_MARGIN_RATES)) { + print ''; + } + if (!empty($conf->global->DISPLAY_MARK_RATES)) { + print ''; + } + print ''; } - print ''; + print $hookmanager->resPrint; + print '
    ' . $langs->trans('Margins') . '' . $langs->trans('SellingPrice') . '' . $langs->trans('BuyingPrice') . '' . $langs->trans('CostPrice') . '' . $langs->trans('Margin') . ''.(($marginInfo['margin_rate_products'] == '') ? '' : price($marginInfo['margin_rate_products'], null, null, null, null, 2).'%').'' . $langs->trans('MarginRate') . ''.(($marginInfo['mark_rate_products'] == '') ? '' : price($marginInfo['mark_rate_products'], null, null, null, null, 2).'%').'' . $langs->trans('MarkRate') . '
    '.$langs->trans('MarginOnServices').''.price($marginInfo['pv_services']).''.price($marginInfo['pa_services']).''.price($marginInfo['margin_on_services']).''.(($marginInfo['margin_rate_services'] == '') ? '' : price($marginInfo['margin_rate_services'], null, null, null, null, 2).'%').'
    ' . $langs->trans('MarginOnProducts') . '' . price($marginInfo['pv_products']) . '' . price($marginInfo['pa_products']) . '' . price($marginInfo['margin_on_products']) . '' . (($marginInfo['margin_rate_products'] == '') ? '' : price($marginInfo['margin_rate_products'], null, null, null, null, 2) . '%') . '' . (($marginInfo['mark_rate_products'] == '') ? '' : price($marginInfo['mark_rate_products'], null, null, null, null, 2) . '%') . '
    '.(($marginInfo['mark_rate_services'] == '') ? '' : price($marginInfo['mark_rate_services'], null, null, null, null, 2).'%').'
    '.$langs->trans('TotalMargin').''.price($marginInfo['pv_total']).''.price($marginInfo['pa_total']).''.price($marginInfo['total_margin']).''.(($marginInfo['total_margin_rate'] == '') ? '' : price($marginInfo['total_margin_rate'], null, null, null, null, 2).'%').'
    ' . $langs->trans('MarginOnServices') . '' . price($marginInfo['pv_services']) . '' . price($marginInfo['pa_services']) . '' . price($marginInfo['margin_on_services']) . '' . (($marginInfo['margin_rate_services'] == '') ? '' : price($marginInfo['margin_rate_services'], null, null, null, null, 2) . '%') . '' . (($marginInfo['mark_rate_services'] == '') ? '' : price($marginInfo['mark_rate_services'], null, null, null, null, 2) . '%') . '
    '.(($marginInfo['total_mark_rate'] == '') ? '' : price($marginInfo['total_mark_rate'], null, null, null, null, 2).'%').'
    ' . $langs->trans('TotalMargin') . '' . price($marginInfo['pv_total']) . '' . price($marginInfo['pa_total']) . '' . price($marginInfo['total_margin']) . '' . (($marginInfo['total_margin_rate'] == '') ? '' : price($marginInfo['total_margin_rate'], null, null, null, null, 2) . '%') . '' . (($marginInfo['total_mark_rate'] == '') ? '' : price($marginInfo['total_mark_rate'], null, null, null, null, 2) . '%') . '
    '; + print '
    '; + } elseif ($reshook > 0) { + print $hookmanager->resPrint; } - print ''; - print '
    '; } } diff --git a/htdocs/core/class/html.formorder.class.php b/htdocs/core/class/html.formorder.class.php index 9c75d15bae5..b97175f1397 100644 --- a/htdocs/core/class/html.formorder.class.php +++ b/htdocs/core/class/html.formorder.class.php @@ -87,7 +87,7 @@ class FormOrder extends Form $listofmethods = array(); $sql = "SELECT rowid, code, libelle as label"; - $sql .= " FROM ".MAIN_DB_PREFIX."c_input_method"; + $sql .= " FROM ".$this->db->prefix()."c_input_method"; $sql .= " WHERE active = 1"; dol_syslog(get_class($this)."::selectInputMethod", LOG_DEBUG); diff --git a/htdocs/core/class/html.formother.class.php b/htdocs/core/class/html.formother.class.php index 99ee1b6af9b..f1f0a846f93 100644 --- a/htdocs/core/class/html.formother.class.php +++ b/htdocs/core/class/html.formother.class.php @@ -57,13 +57,14 @@ class FormOther } /** - * Return HTML code for scanner tool. + * Return the HTML code for scanner tool. * This must be called into an existing
    * - * @param string $jstoexecuteonadd Name of javascript function to call + * @param string $jstoexecuteonadd Name of javascript function to call once the barcode scanning session is complete and user has click on "Add". + * @param string $mode 'all' (both product and lot barcode) or 'product' (product barcode only) or 'lot' (lot number only) * @return string HTML component */ - public function getHTMLScannerForm($jstoexecuteonadd = 'barcodescannerjs') + public function getHTMLScannerForm($jstoexecuteonadd = 'barcodescannerjs', $mode = 'all') { global $langs; @@ -71,14 +72,23 @@ class FormOther $out .= ''."\n"; $out .= '
    '; - $out .= '
    Barcode scanner tool...

    '; + $out .= '
    '.img_picto('', 'barcode', 'class="pictofixedwidth"').'Barcode scanner tool...

    '; - $out .= ' Autodetect if we scan a product barcode or a lot/serial barcode
    '; - $out .= ' Scan a product barcode
    '; - $out .= ' Scan a product lot or serial number
    '; - - $out .= $langs->trans("QtyToAddAfterBarcodeScan").'
    '; - $out .= ''; + if ($mode == 'product') { + $out .= ''; + } elseif ($mode == 'lot') { + $out .= ''; + } else { // $mode = 'all' + $out .= '
    '; + $out .= '
    '; + $out .= '
    '; + } + $stringaddbarcode = $langs->trans("QtyToAddAfterBarcodeScan", "tmphtml"); + $htmltoreplaceby = ''; + $stringaddbarcode = str_replace("tmphtml", $htmltoreplaceby, $stringaddbarcode); + $out .= $stringaddbarcode.'
    '; + $out .= '
    '; + $out .= ''; /*print '
    '.$langs->trans("or").'
    '; @@ -88,14 +98,21 @@ class FormOther */ $out .= '
    '; $out .= '
    '; - $out .= ''; - $out .= ''; + $out .= ''; + $out .= ''; + $out .= '
    '; $out .= '
    '; + $out .= '
    '; $out .= ''; @@ -122,7 +139,7 @@ class FormOther global $conf, $langs, $user; $sql = "SELECT rowid, label, fk_user"; - $sql .= " FROM ".MAIN_DB_PREFIX."export_model"; + $sql .= " FROM ".$this->db->prefix()."export_model"; $sql .= " WHERE type = '".$this->db->escape($type)."'"; if (empty($conf->global->EXPORTS_SHARE_MODELS)) { // EXPORTS_SHARE_MODELS means all templates are visible, whatever is owner. $sql .= " AND fk_user IN (0, ".((int) $fk_user).")"; @@ -184,7 +201,7 @@ class FormOther global $conf, $langs, $user; $sql = "SELECT rowid, label, fk_user"; - $sql .= " FROM ".MAIN_DB_PREFIX."import_model"; + $sql .= " FROM ".$this->db->prefix()."import_model"; $sql .= " WHERE type = '".$this->db->escape($type)."'"; if (empty($conf->global->EXPORTS_SHARE_MODELS)) { // EXPORTS_SHARE_MODELS means all templates are visible, whatever is owner. $sql .= " AND fk_user IN (0, ".((int) $fk_user).")"; @@ -244,7 +261,7 @@ class FormOther $sql = "SELECT e.rowid, e.code, e.label, e.price, e.organization,"; $sql .= " c.label as country"; - $sql .= " FROM ".MAIN_DB_PREFIX."c_ecotaxe as e,".MAIN_DB_PREFIX."c_country as c"; + $sql .= " FROM ".$this->db->prefix()."c_ecotaxe as e,".$this->db->prefix()."c_country as c"; $sql .= " WHERE e.active = 1 AND e.fk_pays = c.rowid"; $sql .= " ORDER BY country, e.organization ASC, e.code ASC"; @@ -296,7 +313,7 @@ class FormOther $out = ''; $sql = "SELECT r.taux, r.revenuestamp_type"; - $sql .= " FROM ".MAIN_DB_PREFIX."c_revenuestamp as r,".MAIN_DB_PREFIX."c_country as c"; + $sql .= " FROM ".$this->db->prefix()."c_revenuestamp as r,".$this->db->prefix()."c_country as c"; $sql .= " WHERE r.active = 1 AND r.fk_pays = c.rowid"; $sql .= " AND c.code = '".$this->db->escape($country_code)."'"; @@ -443,7 +460,7 @@ class FormOther * @param string $htmlname Name of combo list (example: 'search_sale') * @param User $user Object user * @param int $showstatus 0=show user status only if status is disabled, 1=always show user status into label, -1=never show user status - * @param int|string $showempty 1=show also an empty value + * @param int|string $showempty 1=show also an empty value or text to show for empty * @param string $morecss More CSS * @param int $norepresentative Show also an entry "Not categorized" * @return string Html combo list code @@ -456,15 +473,6 @@ class FormOther $langs->load('users'); $out = ''; - // Enhance with select2 - if ($conf->use_javascript_ajax) { - include_once DOL_DOCUMENT_ROOT.'/core/lib/ajax.lib.php'; - - $comboenhancement = ajax_combobox($htmlname); - if ($comboenhancement) { - $out .= $comboenhancement; - } - } $reshook = $hookmanager->executeHooks('addSQLWhereFilterOnSelectSalesRep', array(), $this, $action); @@ -472,24 +480,24 @@ class FormOther $out .= ''; + // Enhance with select2 + if ($conf->use_javascript_ajax) { + include_once DOL_DOCUMENT_ROOT.'/core/lib/ajax.lib.php'; + + $comboenhancement = ajax_combobox($htmlname); + if ($comboenhancement) { + $out .= $comboenhancement; + } + } + return $out; } @@ -828,6 +845,7 @@ class FormOther $out .= ''; $out .= ''; } $out .= ''; - } else // In most cases, this is not used. We used instead function with no specific list of colors - { + } else { // In most cases, this is not used. We used instead function with no specific list of colors if (empty($conf->dol_use_jmobile) && !empty($conf->use_javascript_ajax)) { $out .= ''; $out .= ''; @@ -906,11 +938,11 @@ class FormOther // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps /** - * Creation d'un icone de couleur + * Creae an image for color * - * @param string $color Couleur de l'image - * @param string $module Nom du module - * @param string $name Nom de l'image + * @param string $color Color of image + * @param string $module Name of module + * @param string $name Name of image * @param int $x Largeur de l'image en pixels * @param int $y Hauteur de l'image en pixels * @return void @@ -1195,7 +1227,7 @@ class FormOther // Javascript code for dynamic actions if (!empty($conf->use_javascript_ajax)) { - $selectboxlist .= ''; + } + return $out; + } + + /** + * get the type : used for old module builder setup conf style conversion and tests + * because this two class will quickly evolve it's important to not set or get directly $this->type (will be protected) so this method exist + * to be sure we can manage evolution easily + * + * @return string + */ + public function getType() + { + return $this->type; + } + + /** + * set the type from string : used for old module builder setup conf style conversion and tests + * because this two class will quickly evolve it's important to not set directly $this->type (will be protected) so this method exist + * to be sure we can manage evolution easily + * @param string $type possible values based on old module builder setup : 'string', 'textarea', 'category:'.Categorie::TYPE_CUSTOMER', 'emailtemplate', 'thirdparty_type' + * @deprecated yes this setTypeFromTypeString came deprecated because it exists only for manage setup convertion + * @return bool + */ + public function setTypeFromTypeString($type) + { + $this->type = $type; + return true; + } + + /** + * Add error + * @param array|string $errors the error text + * @return null + */ + public function setErrors($errors) + { + if (is_array($errors)) { + if (!empty($errors)) { + foreach ($errors as $error) { + $this->setErrors($error); + } + } + } elseif (!empty($errors)) { + $this->errors[] = $errors; + } + } + + /** + * @return bool|string Generate the output html for this item + */ + public function generateOutputField() + { + global $conf, $user; + + if (!empty($this->fieldOverride)) { + return $this->fieldOverride; + } + + if (!empty($this->fieldOutputOverride)) { + return $this->fieldOutputOverride; + } + + $out = ''; + + if ($this->type == 'title') { + // nothing to do + } elseif ($this->type == 'textarea') { + $out.= dol_nl2br($this->fieldValue); + } elseif ($this->type== 'html') { + $out.= $this->fieldValue; + } elseif ($this->type == 'yesno') { + $out.= ajax_constantonoff($this->confKey); + } elseif (preg_match('/emailtemplate:/', $this->type)) { + include_once DOL_DOCUMENT_ROOT . '/core/class/html.formmail.class.php'; + $formmail = new FormMail($this->db); + + $tmp = explode(':', $this->type); + + $template = $formmail->getEMailTemplate($this->db, $tmp[1], $user, $this->langs, $this->fieldValue); + if ($template<0) { + $this->setErrors($formmail->errors); + } + $out.= $this->langs->trans($template->label); + } elseif (preg_match('/category:/', $this->type)) { + $c = new Categorie($this->db); + $result = $c->fetch($this->fieldValue); + if ($result < 0) { + $this->setErrors($c->errors); + } + $ways = $c->print_all_ways(' >> ', 'none', 0, 1); // $ways[0] = "ccc2 >> ccc2a >> ccc2a1" with html formated text + $toprint = array(); + foreach ($ways as $way) { + $toprint[] = '
  • color ? ' style="background: #' . $c->color . ';"' : ' style="background: #bbb"') . '>' . $way . '
  • '; + } + $out.='
      ' . implode(' ', $toprint) . '
    '; + } elseif (preg_match('/thirdparty_type/', $this->type)) { + if ($this->fieldValue==2) { + $out.= $this->langs->trans("Prospect"); + } elseif ($this->fieldValue==3) { + $out.= $this->langs->trans("ProspectCustomer"); + } elseif ($this->fieldValue==1) { + $out.= $this->langs->trans("Customer"); + } elseif ($this->fieldValue==0) { + $out.= $this->langs->trans("NorProspectNorCustomer"); + } + } elseif ($this->type == 'product') { + $product = new Product($this->db); + $resprod = $product->fetch($this->fieldValue); + if ($resprod > 0) { + $out.= $product->ref; + } elseif ($resprod < 0) { + $this->setErrors($product->errors); + } + } else { + $out.= $this->fieldValue; + } + + return $out; + } + + + /* + * METHODS FOR SETTING DISPLAY TYPE + */ + + /** + * Set type of input as string + * @return self + */ + public function setAsString() + { + $this->type = 'string'; + return $this; + } + + /** + * Set type of input as textarea + * @return self + */ + public function setAsTextarea() + { + $this->type = 'textarea'; + return $this; + } + + /** + * Set type of input as html editor + * @return self + */ + public function setAsHtml() + { + $this->type = 'html'; + return $this; + } + + /** + * Set type of input as emailtemplate selector + * @param string $templateType email template type + * @return self + */ + public function setAsEmailTemplate($templateType) + { + $this->type = 'emailtemplate:'.$templateType; + return $this; + } + + /** + * Set type of input as thirdparty_type selector + * @return self + */ + public function setAsThirdpartyType() + { + $this->type = 'thirdparty_type'; + return $this; + } + + /** + * Set type of input as Yes + * @return self + */ + public function setAsYesNo() + { + $this->type = 'yesno'; + return $this; + } + + /** + * Set type of input as secure key + * @return self + */ + public function setAsSecureKey() + { + $this->type = 'securekey'; + return $this; + } + + /** + * Set type of input as product + * @return self + */ + public function setAsProduct() + { + $this->type = 'product'; + return $this; + } + + /** + * Set type of input as a category selector + * TODO add default value + * @param int $catType Type of category ('customer', 'supplier', 'contact', 'product', 'member'). Old mode (0, 1, 2, ...) is deprecated. + * @return self + */ + public function setAsCategory($catType) + { + $this->type = 'category:'.$catType; + return $this; + } + + /** + * Set type of input as a simple title + * no data to store + * @return self + */ + public function setAsTitle() + { + $this->type = 'title'; + return $this; + } +} diff --git a/htdocs/core/class/html.formsms.class.php b/htdocs/core/class/html.formsms.class.php index 60811956c32..68b8410e647 100644 --- a/htdocs/core/class/html.formsms.class.php +++ b/htdocs/core/class/html.formsms.class.php @@ -127,7 +127,7 @@ class FormSms print "\n\n"; print ' -'; } else { // Default Header Redirect @@ -495,7 +460,15 @@ class SimpleOpenID if ($openid_server == false) { return false; } - $response = $this->CURL_Request($openid_server, 'POST', $params); + + if (is_array($params)) { + $params = $this->array2url($params); + } + + $result = getURLContent($openid_server, 'POST', $params); + + $response = $result['content']; + $data = $this->splitResponse($response); if ($data['is_valid'] == "true") { return true; diff --git a/htdocs/core/class/smtps.class.php b/htdocs/core/class/smtps.class.php index c287aae1c2f..dbaaacc2d18 100644 --- a/htdocs/core/class/smtps.class.php +++ b/htdocs/core/class/smtps.class.php @@ -464,20 +464,26 @@ class SMTPs $host = 'tls://'.$host; } - $hosth = $host; + $hosth = $host; // so for example 'localhost' or 'smtp-relay.gmail.com' if (!empty($conf->global->MAIL_SMTP_USE_FROM_FOR_HELO)) { - // If the from to is 'aaa ', we will keep 'ccc.com' - $hosth = $this->getFrom('addr'); - $hosth = preg_replace('/^.*.*$/', '', $hosth); - $hosth = preg_replace('/.*@/', '', $hosth); + if (!is_numeric($conf->global->MAIL_SMTP_USE_FROM_FOR_HELO)) { + // If value of MAIL_SMTP_USE_FROM_FOR_HELO is a string, we use it as domain name + $hosth = $conf->global->MAIL_SMTP_USE_FROM_FOR_HELO; + } else { + // If value of MAIL_SMTP_USE_FROM_FOR_HELO is 1, we use the domain in the from. + // So if the from to is 'aaa ', we will keep 'ccc.com' + $hosth = $this->getFrom('addr'); + $hosth = preg_replace('/^.*.*$/', '', $hosth); + $hosth = preg_replace('/.*@/', '', $hosth); + } } if ($_retVal = $this->socket_send_str('EHLO '.$hosth, '250')) { if ($usetls) { /* - The following dialog illustrates how a client and server can start a TLS STARTTLS session + The following dialog illustrates how a client and server can start a TLS STARTTLS session: S: C: S: 220 mail.imc.org SMTP service ready @@ -494,6 +500,39 @@ class SMTPs S: 250-server-domain.com S: 250 AUTH LOGIN C: + S: 250 OK + C: RCPT TO: + S: 250 OK + C: DATA + S: 354 Send message, end with a "." on a line by itself + C: + S . + S: 250 OK, message accepted for delivery: queued as 12345 + C: QUIT + S: 221 Bye */ if (!$_retVal = $this->socket_send_str('STARTTLS', 220)) { $this->_setErr(131, 'STARTTLS connection is not supported.'); @@ -517,10 +556,10 @@ class SMTPs $this->_setErr(132, 'STARTTLS connection failed.'); return $_retVal; } - // Most server servers expect a 2nd pass of EHLO after TLS is established to get another time + // Most servers expect a 2nd pass of EHLO after TLS is established to get another time // the answer with list of supported AUTH methods. They may differs between non STARTTLS and with STARTTLS. - if (!$_retVal = $this->socket_send_str('EHLO '.$hosth, '250')) { - $this->_setErr(126, '"'.$hosth.'" does not support authenticated connections.'); + if (! $_retVal = $this->socket_send_str('EHLO '.$hosth, '250')) { + $this->_setErr(126, '"'.$hosth.'" does not support authenticated connections. Error after sending EHLO '.$hosth); return $_retVal; } } @@ -560,7 +599,7 @@ class SMTPs $this->_setErr(130, 'Invalid Authentication Credentials.'); } } else { - $this->_setErr(126, '"'.$host.'" does not support authenticated connections.'); + $this->_setErr(126, '"'.$host.'" does not support authenticated connections. Error after sending EHLO '.$hosth); } return $_retVal; @@ -603,11 +642,17 @@ class SMTPs $hosth = $host; if (!empty($conf->global->MAIL_SMTP_USE_FROM_FOR_HELO)) { - // If the from to is 'aaa ', we will keep 'ccc.com' - $hosth = $this->getFrom('addr'); - $hosth = preg_replace('/^.*.*$/', '', $hosth); - $hosth = preg_replace('/.*@/', '', $hosth); + if (!is_numeric($conf->global->MAIL_SMTP_USE_FROM_FOR_HELO)) { + // If value of MAIL_SMTP_USE_FROM_FOR_HELO is a string, we use it as domain name + $hosth = $conf->global->MAIL_SMTP_USE_FROM_FOR_HELO; + } else { + // If value of MAIL_SMTP_USE_FROM_FOR_HELO is 1, we use the domain in the from. + // If the from to is 'aaa ', we will keep 'ccc.com' + $hosth = $this->getFrom('addr'); + $hosth = preg_replace('/^.*.*$/', '', $hosth); + $hosth = preg_replace('/.*@/', '', $hosth); + } } $_retVal = $this->socket_send_str('HELO '.$hosth, '250'); diff --git a/htdocs/core/class/translate.class.php b/htdocs/core/class/translate.class.php index b535d2b3585..27f3ca1c836 100644 --- a/htdocs/core/class/translate.class.php +++ b/htdocs/core/class/translate.class.php @@ -480,7 +480,7 @@ class Translate if (!$found && !empty($conf->global->MAIN_ENABLE_OVERWRITE_TRANSLATION)) { // Overwrite translation with database read - $sql = "SELECT transkey, transvalue FROM ".MAIN_DB_PREFIX."overwrite_trans where lang='".$db->escape($this->defaultlang)."' OR lang IS NULL"; + $sql = "SELECT transkey, transvalue FROM ".$db->prefix()."overwrite_trans where lang='".$db->escape($this->defaultlang)."' OR lang IS NULL"; $sql .= " AND entity IN (0, ".getEntity('overwrite_trans').")"; $sql .= $db->order("lang", "DESC"); $resql = $db->query($sql); @@ -555,9 +555,9 @@ class Translate * Return translated value of key for special keys ("Currency...", "Civility...", ...). * Search in lang file, then into database. Key must be any complete entry into lang file: CurrencyEUR, ... * If not found, return key. - * The string return is not formated (translated with transnoentitiesnoconv) - * NOTE: To avoid infinite loop (getLabelFromKey->transnoentities->getTradFromKey), if you modify this function, - * check that getLabelFromKey is not called with same value than input. + * The string return is not formated (translated with transnoentitiesnoconv). + * NOTE: To avoid infinite loop (getLabelFromKey->transnoentities->getTradFromKey->getLabelFromKey), if you modify this function, + * check that getLabelFromKey is never called with the same value than $key. * * @param string $key Key to translate * @return string Translated string (translated with transnoentitiesnoconv) @@ -579,17 +579,17 @@ class Translate $newstr = $this->getLabelFromKey($db, $reg[1], 'c_currencies', 'code_iso', 'label'); } elseif (preg_match('/^SendingMethod([0-9A-Z]+)$/i', $key, $reg)) { $newstr = $this->getLabelFromKey($db, $reg[1], 'c_shipment_mode', 'code', 'libelle'); - } elseif (preg_match('/^PaymentTypeShort([0-9A-Z]+)$/i', $key, $reg)) { + } elseif (preg_match('/^PaymentType(?:Short)?([0-9A-Z]+)$/i', $key, $reg)) { $newstr = $this->getLabelFromKey($db, $reg[1], 'c_paiement', 'code', 'libelle', '', 1); } elseif (preg_match('/^OppStatus([0-9A-Z]+)$/i', $key, $reg)) { $newstr = $this->getLabelFromKey($db, $reg[1], 'c_lead_status', 'code', 'label'); } elseif (preg_match('/^OrderSource([0-9A-Z]+)$/i', $key, $reg)) { // TODO OrderSourceX must be replaced with content of table llx_c_input_reason or llx_c_input_method - //$newstr=$this->getLabelFromKey($db,$reg[1],'c_ordersource','code','label'); + //$newstr=$this->getLabelFromKey($db,$reg[1],'llx_c_input_reason','code','label'); } /* Disabled. There is too many cases where translation of $newstr is not defined is normal (like when output with setEventMessage an already translated string) - if (! empty($conf->global->MAIN_FEATURES_LEVEL) && $conf->global->MAIN_FEATURES_LEVEL >= 2) + if (getDolGlobalInt('MAIN_FEATURES_LEVEL') >= 2) { dol_syslog(__METHOD__." MAIN_FEATURES_LEVEL=DEVELOP: missing translation for key '".$newstr."' in ".$_SERVER["PHP_SELF"], LOG_DEBUG); }*/ @@ -656,7 +656,7 @@ class Translate return $str; } else { // Translation is not available - //if ($key[0] == '$') { return dol_eval($key,1); } + //if ($key[0] == '$') { return dol_eval($key, 1, 1, '1'); } return $this->getTradFromKey($key); } } @@ -722,7 +722,7 @@ class Translate return $str; } else { if ($key[0] == '$') { - return dol_eval($key, 1); + return dol_eval($key, 1, 1, '1'); } return $this->getTradFromKey($key); } @@ -945,9 +945,9 @@ class Translate * * @param DoliDB $db Database handler * @param string $key Translation key to get label (key in language file) - * @param string $tablename Table name without prefix - * @param string $fieldkey Field for key - * @param string $fieldlabel Field for label + * @param string $tablename Table name without prefix. This value must always be a hardcoded string and not a value coming from user input. + * @param string $fieldkey Field for key. This value must always be a hardcoded string and not a value coming from user input. + * @param string $fieldlabel Field for label. This value must always be a hardcoded string and not a value coming from user input. * @param string $keyforselect Use another value than the translation key for the where into select * @param int $filteronentity Use a filter on entity * @return string Label in UTF8 (but without entities) @@ -959,10 +959,15 @@ class Translate if ($key == '') { return ''; } + // Test should be useless because the 3 variables are never set from user input but we keep it in case of. + if (preg_match('/[^0-9A-Z_]/i', $tablename) || preg_match('/[^0-9A-Z_]/i', $fieldkey) || preg_match('/[^0-9A-Z_]/i', $fieldlabel)) { + $this->error = 'Bad value for parameter tablename, fieldkey or fieldlabel'; + return -1; + } //print 'param: '.$key.'-'.$keydatabase.'-'.$this->trans($key); exit; - // Check if a translation is available (this can call getTradFromKey) + // Check if a translation is available (Note: this can call getTradFromKey that can call getLabelFromKey) $tmp = $this->transnoentitiesnoconv($key); if ($tmp != $key && $tmp != 'ErrorBadValueForParamNotAString') { return $tmp; // Found in language array @@ -973,8 +978,9 @@ class Translate return $this->cache_labels[$tablename][$key]; // Found in cache } + // Not found in loaded language file nor in cache. So we will take the label into database. $sql = "SELECT ".$fieldlabel." as label"; - $sql .= " FROM ".MAIN_DB_PREFIX.$tablename; + $sql .= " FROM ".$db->prefix().$tablename; $sql .= " WHERE ".$fieldkey." = '".$db->escape($keyforselect ? $keyforselect : $key)."'"; if ($filteronentity) { $sql .= " AND entity IN (".getEntity($tablename).')'; @@ -1061,7 +1067,7 @@ class Translate } $sql = "SELECT code_iso, label, unicode"; - $sql .= " FROM ".MAIN_DB_PREFIX."c_currencies"; + $sql .= " FROM ".$db->prefix()."c_currencies"; $sql .= " WHERE active = 1"; if (!empty($currency_code)) { $sql .= " AND code_iso = '".$db->escape($currency_code)."'"; diff --git a/htdocs/core/class/utils.class.php b/htdocs/core/class/utils.class.php index d56fcddafa7..2fa329406fb 100644 --- a/htdocs/core/class/utils.class.php +++ b/htdocs/core/class/utils.class.php @@ -241,8 +241,15 @@ class Utils // MYSQL if ($type == 'mysql' || $type == 'mysqli') { - $cmddump = $conf->global->SYSTEMTOOLS_MYSQLDUMP; - + if (empty($conf->global->SYSTEMTOOLS_MYSQLDUMP)) { + $cmddump = $db->getPathOfDump(); + } else { + $cmddump = $conf->global->SYSTEMTOOLS_MYSQLDUMP; + } + if (empty($cmddump)) { + $this->error = "Failed to detect command to use for mysqldump. Try a manual backup before to set path of command."; + return -1; + } $outputfile = $outputdir.'/'.$file; // for compression format, we add extension @@ -358,10 +365,19 @@ class Utils dol_syslog("Utils::dumpDatabase execmethod=".$execmethod." command:".$fullcommandcrypted, LOG_INFO); + + /* If value has been forced with a php_admin_value, this has no effect. Example of value: '512M' */ + $MemoryLimit = getDolGlobalString('MAIN_MEMORY_LIMIT_DUMP'); + if (!empty($MemoryLimit)) { + @ini_set('memory_limit', $MemoryLimit); + } + + // TODO Replace with executeCLI function if ($execmethod == 1) { $output_arr = array(); $retval = null; + exec($fullcommandclear, $output_arr, $retval); if ($retval != 0) { @@ -390,21 +406,23 @@ class Utils if ($execmethod == 2) { // With this method, there is no way to get the return code, only output $handlein = popen($fullcommandclear, 'r'); $i = 0; - while (!feof($handlein)) { - $i++; // output line number - $read = fgets($handlein); - // Exclude warning line we don't want - if ($i == 1 && preg_match('/Warning.*Using a password/i', $read)) { - continue; - } - fwrite($handle, $read); - if (preg_match('/'.preg_quote('-- Dump completed').'/i', $read)) { - $ok = 1; - } elseif (preg_match('/'.preg_quote('SET SQL_NOTES=@OLD_SQL_NOTES').'/i', $read)) { - $ok = 1; + if ($handlein) { + while (!feof($handlein)) { + $i++; // output line number + $read = fgets($handlein); + // Exclude warning line we don't want + if ($i == 1 && preg_match('/Warning.*Using a password/i', $read)) { + continue; + } + fwrite($handle, $read); + if (preg_match('/'.preg_quote('-- Dump completed').'/i', $read)) { + $ok = 1; + } elseif (preg_match('/'.preg_quote('SET SQL_NOTES=@OLD_SQL_NOTES').'/i', $read)) { + $ok = 1; + } } + pclose($handlein); } - pclose($handlein); } @@ -627,7 +645,6 @@ class Utils $execmethod = 1; } //$execmethod=1; - dol_syslog("Utils::executeCLI execmethod=".$execmethod." system:".$command, LOG_DEBUG); $output_arr = array(); diff --git a/htdocs/core/class/validate.class.php b/htdocs/core/class/validate.class.php index 1b2447dc23a..d3aa5707c05 100644 --- a/htdocs/core/class/validate.class.php +++ b/htdocs/core/class/validate.class.php @@ -55,13 +55,17 @@ class Validate { global $langs; - if ($outputLang) { + if (empty($outputLang)) { $this->outputLang = $langs; } else { $this->outputLang = $outputLang; } - $outputLang->load('validate'); + if (!is_object($this->outputLang) || !method_exists($this->outputLang, 'load')) { + return false; + } + + $this->outputLang->loadLangs(array('validate', 'errors')); $this->db = $db; } @@ -212,7 +216,7 @@ class Validate /** * Check Duration validity * - * @param string $duration to validate + * @param mixed $duration to validate * @return boolean Validity is ok or not */ public function isDuration($duration) @@ -224,6 +228,21 @@ class Validate return true; } + /** + * Check numeric validity + * + * @param mixed $string to validate + * @return boolean Validity is ok or not + */ + public function isNumeric($string) + { + if (!is_numeric($string)) { + $this->error = $this->outputLang->trans('RequireValidNumeric'); + return false; + } + return true; + } + /** * Check for boolean validity * @@ -243,7 +262,7 @@ class Validate * Check for all values in db * * @param array $values Boolean to validate - * @param string $table the db table name without MAIN_DB_PREFIX + * @param string $table the db table name without $this->db->prefix() * @param string $col the target col * @return boolean Validity is ok or not * @throws Exception @@ -262,7 +281,7 @@ class Validate } foreach ($value_arr as $val) { - $sql = "SELECT ".$col." FROM ".MAIN_DB_PREFIX.$table." WHERE ".$col." = '".$this->db->escape($val)."'"; // nore quick than count(*) to check existing of a row + $sql = "SELECT ".$col." FROM ".$this->db->prefix().$table." WHERE ".$col." = '".$this->db->escape($val)."'"; // nore quick than count(*) to check existing of a row $resql = $this->db->getRow($sql); if ($resql) { continue; diff --git a/htdocs/core/customreports.php b/htdocs/core/customreports.php index b7f01de0aeb..7331b08e13e 100644 --- a/htdocs/core/customreports.php +++ b/htdocs/core/customreports.php @@ -40,7 +40,6 @@ if (!defined('USE_CUSTOM_REPORT_AS_INCLUDE')) { $objecttype = 'thirdparty'; } - $search_filters = GETPOST('search_filters', 'array'); $search_measures = GETPOST('search_measures', 'array'); //$search_xaxis = GETPOST('search_xaxis', 'array'); @@ -57,7 +56,7 @@ if (!defined('USE_CUSTOM_REPORT_AS_INCLUDE')) { } $search_yaxis = GETPOST('search_yaxis', 'array'); - $search_graph = GETPOST('search_graph', 'none'); + $search_graph = GETPOST('search_graph', 'restricthtml'); // Load variable for pagination $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; @@ -100,7 +99,8 @@ $arrayoftype = array( 'order' => array('label' => 'Orders', 'ObjectClassName' => 'Commande', 'enabled' => $conf->commande->enabled, 'ClassPath' => "/commande/class/commande.class.php"), 'invoice' => array('label' => 'Invoices', 'ObjectClassName' => 'Facture', 'enabled' => $conf->facture->enabled, 'ClassPath' => "/compta/facture/class/facture.class.php"), 'invoice_template'=>array('label' => 'PredefinedInvoices', 'ObjectClassName' => 'FactureRec', 'enabled' => $conf->facture->enabled, 'ClassPath' => "/compta/class/facturerec.class.php", 'langs'=>'bills'), - 'contract' => array('label' => 'Contracts', 'ObjectClassName' => 'Contrat', 'enabled' => $conf->contrat->enabled, 'ClassPath' => "/contrat/class/contrat.class.php", 'langs'=>'contract'), + 'contract' => array('label' => 'Contracts', 'ObjectClassName' => 'Contrat', 'enabled' => $conf->contrat->enabled, 'ClassPath' => "/contrat/class/contrat.class.php", 'langs'=>'contracts'), + 'contractdet' => array('label' => 'ContractLines', 'ObjectClassName' => 'ContratLigne', 'enabled' => $conf->contrat->enabled, 'ClassPath' => "/contrat/class/contrat.class.php", 'langs'=>'contracts'), 'bom' => array('label' => 'BOM', 'ObjectClassName' => 'Bom', 'enabled' => $conf->bom->enabled), 'mo' => array('label' => 'MO', 'ObjectClassName' => 'Mo', 'enabled' => $conf->mrp->enabled, 'ClassPath' => "/mrp/class/mo.class.php"), 'ticket' => array('label' => 'Ticket', 'ObjectClassName' => 'Ticket', 'enabled' => $conf->ticket->enabled), @@ -158,6 +158,12 @@ $extrafields->fetch_name_optionals_label($object->table_element); $search_array_options = $extrafields->getOptionalsFromPost($object->table_element, '', 'search_'); $search_component_params = array(''); +$search_component_params_hidden = GETPOST('search_component_params_hidden', 'alphanohtml'); + +// For the case we enter a criteria manually, the search_component_params_input will be defined and must be used in priority +if (GETPOST('search_component_params_input', 'alphanohtml')) { + $search_component_params_hidden = GETPOST('search_component_params_input', 'alphanohtml'); +} $MAXUNIQUEVALFORGROUP = 20; $MAXMEASURESINBARGRAPH = 20; @@ -169,20 +175,27 @@ $HH = substr($langs->trans("Hour"), 0, 1).substr($langs->trans("Hour"), 0, 1); $MI = substr($langs->trans("Minute"), 0, 1).substr($langs->trans("Minute"), 0, 1); $SS = substr($langs->trans("Second"), 0, 1).substr($langs->trans("Second"), 0, 1); -$arrayofmesures = array('t.count'=>'Count'); +$arrayofmesures = array(); $arrayofxaxis = array(); $arrayofgroupby = array(); $arrayofyaxis = array(); $arrayofvaluesforgroupby = array(); -$result = restrictedArea($user, $object->element, 0, ''); +$features = $object->element; +if (!empty($object->element_for_permission)) { + $features = $object->element_for_permission; +} + +restrictedArea($user, $features, 0, ''); + +$error = 0; /* * Actions */ - +// None @@ -245,8 +258,19 @@ if (is_array($search_groupby) && count($search_groupby)) { } else { $sql .= ' FROM '.MAIN_DB_PREFIX.$object->table_element.' as t'; } - // TODO Add the where here - // ... + + // Add the where here + /* + $sqlfilters = GETPOST('search_component_params_hidden', 'alphanohtml'); + if ($sqlfilters) { + $errormessage = ''; + if (dolCheckFilters($sqlfilters, $errormessage)) { + $regexstring = '\(([^:\'\(\)]+:[^:\'\(\)]+:[^\(\)]+)\)'; + $sql .= " WHERE (".preg_replace_callback('/'.$regexstring.'/', 'dolForgeCriteriaCallback', $sqlfilters).")"; + } else { + print $errormessage; + } + }*/ $sql .= ' LIMIT '.($MAXUNIQUEVALFORGROUP + 1); @@ -333,6 +357,24 @@ print ''; print ''; print ''; +$viewmode = ''; + +$viewmode .= '
    '; +$arrayofgraphs = array('bars' => 'Bars', 'lines' => 'Lines'); // also 'pies' +$viewmode .= '
    '.$langs->trans("Graph").'
    '; +$viewmode .= $form->selectarray('search_graph', $arrayofgraphs, $search_graph, 0, 0, 0, 'minwidth100', 1); +$viewmode .= '
    '; + +$num = 0; +$massactionbutton = ''; +$nav = ''; +$newcardbutton = ''; +$limit = 0; + +print_barre_liste('', $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, -1, 'object_action', 0, $nav.''.$newcardbutton, '', $limit, 1, 0, 1, $viewmode); + + + print '
    '; // Select object @@ -340,7 +382,7 @@ print '
    '; print '
    '.$langs->trans("StatisticsOn").'
    '; $newarrayoftype = array(); foreach ($arrayoftype as $key => $val) { - if (dol_eval($val['enabled'], 1)) { + if (dol_eval($val['enabled'], 1, 1, '1')) { $newarrayoftype[$key] = $arrayoftype[$key]; } if ($val['langs']) { @@ -349,61 +391,51 @@ foreach ($arrayoftype as $key => $val) { } print $form->selectarray('objecttype', $newarrayoftype, $objecttype, 0, 0, 0, '', 1, 0, 0, '', 'minwidth200', 1); if (empty($conf->use_javascript_ajax)) { - print ''; + print ''; } else { - print ''; } print '
    '; -// Add Filter +// Add Filter (you can use param &show_search_component_params_hidden=1 for debug) print '
    '; -print $form->searchComponent(array($object->element => $object->fields), $search_component_params); +print $form->searchComponent(array($object->element => $object->fields), $search_component_params, array(), $search_component_params_hidden); print '
    '; // Add measures into array +$count = 0; +$arrayofmesures = fillArrayOfMeasures($object, 't', $langs->trans($newarrayoftype[$objecttype]['label']), $arrayofmesures, 0, $count); +//var_dump($arrayofmesures); print '
    '; -foreach ($object->fields as $key => $val) { - if (!empty($val['isameasure']) && (!isset($val['enabled']) || dol_eval($val['enabled'], 1))) { - $arrayofmesures['t.'.$key.'-sum'] = $langs->trans($val['label']).' ('.$langs->trans("Sum").')'; - $arrayofmesures['t.'.$key.'-average'] = $langs->trans($val['label']).' ('.$langs->trans("Average").')'; - $arrayofmesures['t.'.$key.'-min'] = $langs->trans($val['label']).' ('.$langs->trans("Minimum").')'; - $arrayofmesures['t.'.$key.'-max'] = $langs->trans($val['label']).' ('.$langs->trans("Maximum").')'; - } -} -// Add extrafields to Measures -if ($object->isextrafieldmanaged) { - foreach ($extrafields->attributes[$object->table_element]['label'] as $key => $val) { - if (!empty($extrafields->attributes[$object->table_element]['totalizable'][$key]) && (!isset($extrafields->attributes[$object->table_element]['enabled'][$key]) || dol_eval($extrafields->attributes[$object->table_element]['enabled'][$key], 1))) { - $arrayofmesures['te.'.$key.'-sum'] = $langs->trans($extrafields->attributes[$object->table_element]['label'][$key]).' ('.$langs->trans("Sum").')'; - $arrayofmesures['te.'.$key.'-average'] = $langs->trans($extrafields->attributes[$object->table_element]['label'][$key]).' ('.$langs->trans("Average").')'; - $arrayofmesures['te.'.$key.'-min'] = $langs->trans($extrafields->attributes[$object->table_element]['label'][$key]).' ('.$langs->trans("Minimum").')'; - $arrayofmesures['te.'.$key.'-max'] = $langs->trans($extrafields->attributes[$object->table_element]['label'][$key]).' ('.$langs->trans("Maximum").')'; - } - } -} -print '
    '.$langs->trans("Measures").'
    '; -print $form->multiselectarray('search_measures', $arrayofmesures, $search_measures, 0, 0, 'minwidth400', 1); +print '
    '; +print $form->multiselectarray('search_measures', $arrayofmesures, $search_measures, 0, 0, 'minwidth400', 1, 0, '', '', $langs->trans("Measures")); // Fill the array $arrayofmeasures with possible fields print '
    '; - -// Group by -print '
    '; -print '
    '.$langs->trans("GroupBy").'
    '; -print $formother->selectGroupByField($object, $search_groupby, $arrayofgroupby); -print '
    '; - - // XAxis +$count = 0; +$arrayofxaxis = fillArrayOfXAxis($object, 't', $langs->trans($newarrayoftype[$objecttype]['label']), $arrayofxaxis, 0, $count); +$arrayofxaxis = dol_sort_array($arrayofxaxis, 'position', 'asc', 0, 0, 1); print '
    '; -print '
    '.$langs->trans("XAxis").'
    '; -print $formother->selectXAxisField($object, $search_xaxis, $arrayofxaxis); +print '
    '; +//var_dump($arrayofxaxis); +print $formother->selectXAxisField($object, $search_xaxis, $arrayofxaxis, $langs->trans("XAxis")); // Fill the array $arrayofxaxis with possible fields +print '
    '; + +// Group by +$count = 0; +$arrayofgroupby = fillArrayOfGroupBy($object, 't', $langs->trans($newarrayoftype[$objecttype]['label']), $arrayofgroupby, 0, $count); +$arrayofgroupby = dol_sort_array($arrayofgroupby, 'position', 'asc', 0, 0, 1); +print '
    '; +print '
    '; +print $formother->selectGroupByField($object, $search_groupby, $arrayofgroupby, 'minwidth200 maxwidth250', $langs->trans("GroupBy")); // Fill the array $arrayofgroupby with possible fields print '
    '; @@ -411,7 +443,7 @@ if ($mode == 'grid') { // YAxis print '
    '; foreach ($object->fields as $key => $val) { - if (empty($val['measure']) && (!isset($val['enabled']) || dol_eval($val['enabled'], 1))) { + if (empty($val['measure']) && (!isset($val['enabled']) || dol_eval($val['enabled'], 1, 1, '1'))) { if (in_array($key, array('id', 'rowid', 'entity', 'last_main_doc', 'extraparams'))) { continue; } @@ -432,7 +464,7 @@ if ($mode == 'grid') { // Add measure from extrafields if ($object->isextrafieldmanaged) { foreach ($extrafields->attributes[$object->table_element]['label'] as $key => $val) { - if (!empty($extrafields->attributes[$object->table_element]['totalizable'][$key]) && (!isset($extrafields->attributes[$object->table_element]['enabled'][$key]) || dol_eval($extrafields->attributes[$object->table_element]['enabled'][$key], 1))) { + if (!empty($extrafields->attributes[$object->table_element]['totalizable'][$key]) && (!isset($extrafields->attributes[$object->table_element]['enabled'][$key]) || dol_eval($extrafields->attributes[$object->table_element]['enabled'][$key], 1, 1, '1'))) { $arrayofyaxis['te.'.$key] = array('label' => $extrafields->attributes[$object->table_element]['label'][$key], 'position' => (int) $extrafields->attributes[$object->table_element]['pos'][$key]); } } @@ -449,14 +481,11 @@ if ($mode == 'grid') { } if ($mode == 'graph') { - print '
    '; - $arrayofgraphs = array('bars' => 'Bars', 'lines' => 'Lines'); // also 'pies' - print '
    '.$langs->trans("Graph").'
    '; - print $form->selectarray('search_graph', $arrayofgraphs, $search_graph, 0, 0, 0, 'minwidth100', 1); - print '
    '; + // } + print '
    '; -print ''; +print ''; print '
    '; print '
    '; print ''; @@ -531,8 +560,16 @@ if (!empty($search_measures) && !empty($search_xaxis)) { if ($object->ismultientitymanaged == 1) { $sql .= ' AND entity IN ('.getEntity($object->element).')'; } - foreach ($search_filters as $key => $val) { - // TODO Add the where here + // Add the where here + $sqlfilters = $search_component_params_hidden; + if ($sqlfilters) { + $errormessage = ''; + if (dolCheckFilters($sqlfilters, $errormessage)) { + $regexstring = '\(([^:\'\(\)]+:[^:\'\(\)]+:[^\(\)]+)\)'; + $sql .= " AND (".preg_replace_callback('/'.$regexstring.'/', 'dolForgeCriteriaCallback', $sqlfilters).")"; + } else { + print $errormessage; + } } $sql .= ' GROUP BY '; foreach ($search_xaxis as $key => $val) { @@ -798,3 +835,276 @@ if (!defined('USE_CUSTOM_REPORT_AS_INCLUDE')) { llxFooter(); $db->close(); + + + + + +/** + * Fill arrayofmesures for an object + * + * @param mixed $object Any object + * @param string $tablealias Alias of table + * @param string $labelofobject Label of object + * @param array $arrayofmesures Array of mesures already filled + * @param int $level Level + * @param int $count Count + * @return array Array of mesures + */ +function fillArrayOfMeasures($object, $tablealias, $labelofobject, &$arrayofmesures, $level = 0, &$count = 0) +{ + global $langs, $extrafields, $db; + + if ($level > 10) { // Protection against infinite loop + return $arrayofmesures; + } + + if ($level == 0) { + // Add the count of record only for the main/first level object. Parents are necessarly unique for each record. + $arrayofmesures[$tablealias.'.count'] = img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': Count'; + } + + // Add main fields of object + foreach ($object->fields as $key => $val) { + if (!empty($val['isameasure']) && (!isset($val['enabled']) || dol_eval($val['enabled'], 1, 1, '1'))) { + $arrayofmesures[$tablealias.'.'.$key.'-sum'] = img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': '.$langs->trans($val['label']).' ('.$langs->trans("Sum").')'; + $arrayofmesures[$tablealias.'.'.$key.'-average'] = img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': '.$langs->trans($val['label']).' ('.$langs->trans("Average").')'; + $arrayofmesures[$tablealias.'.'.$key.'-min'] = img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': '.$langs->trans($val['label']).' ('.$langs->trans("Minimum").')'; + $arrayofmesures[$tablealias.'.'.$key.'-max'] = img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': '.$langs->trans($val['label']).' ('.$langs->trans("Maximum").')'; + } + } + // Add extrafields to Measures + if ($object->isextrafieldmanaged) { + foreach ($extrafields->attributes[$object->table_element]['label'] as $key => $val) { + if (!empty($extrafields->attributes[$object->table_element]['totalizable'][$key]) && (!isset($extrafields->attributes[$object->table_element]['enabled'][$key]) || dol_eval($extrafields->attributes[$object->table_element]['enabled'][$key], 1, 1, '1'))) { + $arrayofmesures[$tablealias.'e.'.$key.'-sum'] = img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': '.$langs->trans($extrafields->attributes[$object->table_element]['label'][$key]).' ('.$langs->trans("Sum").')'; + $arrayofmesures[$tablealias.'e.'.$key.'-average'] = img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': '.$langs->trans($extrafields->attributes[$object->table_element]['label'][$key]).' ('.$langs->trans("Average").')'; + $arrayofmesures[$tablealias.'e.'.$key.'-min'] = img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': '.$langs->trans($extrafields->attributes[$object->table_element]['label'][$key]).' ('.$langs->trans("Minimum").')'; + $arrayofmesures[$tablealias.'e.'.$key.'-max'] = img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': '.$langs->trans($extrafields->attributes[$object->table_element]['label'][$key]).' ('.$langs->trans("Maximum").')'; + } + } + } + // Add fields for parent objects + foreach ($object->fields as $key => $val) { + if (preg_match('/^[^:]+:[^:]+:/', $val['type'])) { + $tmptype = explode(':', $val['type'], 4); + if ($tmptype[0] = 'integer' && $tmptype[1] && $tmptype[2]) { + $newobject = $tmptype[1]; + dol_include_once($tmptype[2]); + if (class_exists($newobject)) { + $tmpobject = new $newobject($db); + /*var_dump($val['label']); + var_dump($tmptype); + var_dump($arrayofmesures); + var_dump('t-'.$key);*/ + $count++; + $arrayofmesures = fillArrayOfMeasures($tmpobject, $tablealias.'__'.$key, $langs->trans($val['label']), $arrayofmesures, $level + 1, $count); + } else { + print 'Failed to find '.$newobject.' class for field '.$key.' of object '.$object->element."\n"; + } + } + } + } + + return $arrayofmesures; +} + + +/** + * Fill arrayofmesures for an object + * + * @param mixed $object Any object + * @param string $tablealias Alias of table + * @param string $labelofobject Label of object + * @param array $arrayofxaxis Array of xaxis already filled + * @param int $level Level + * @param int $count Count + * @return array Array of xaxis + */ +function fillArrayOfXAxis($object, $tablealias, $labelofobject, &$arrayofxaxis, $level = 0, &$count = 0) +{ + global $langs, $extrafields, $db; + + if ($level > 10) { // Protection against infinite loop + return $arrayofxaxis; + } + + if ($level >= 2) { + return $arrayofxaxis; + } + + $YYYY = substr($langs->trans("Year"), 0, 1).substr($langs->trans("Year"), 0, 1).substr($langs->trans("Year"), 0, 1).substr($langs->trans("Year"), 0, 1); + $MM = substr($langs->trans("Month"), 0, 1).substr($langs->trans("Month"), 0, 1); + $DD = substr($langs->trans("Day"), 0, 1).substr($langs->trans("Day"), 0, 1); + $HH = substr($langs->trans("Hour"), 0, 1).substr($langs->trans("Hour"), 0, 1); + $MI = substr($langs->trans("Minute"), 0, 1).substr($langs->trans("Minute"), 0, 1); + $SS = substr($langs->trans("Second"), 0, 1).substr($langs->trans("Second"), 0, 1); + + // Add main fields of object + foreach ($object->fields as $key => $val) { + if (empty($val['measure'])) { + if (in_array($key, array( + 'id', 'ref_int', 'ref_ext', 'rowid', 'entity', 'last_main_doc', 'logo', 'logo_squarred', 'extraparams', + 'parent', 'photo', 'socialnetworks', 'webservices_url', 'webservices_key'))) { + continue; + } + if (isset($val['enabled']) && !dol_eval($val['enabled'], 1, 1, '1')) { + continue; + } + if (isset($val['visible']) && !dol_eval($val['visible'], 1, 1, '1')) { + continue; + } + if (preg_match('/^fk_/', $key) && !preg_match('/^fk_statu/', $key)) { + continue; + } + if (preg_match('/^pass/', $key)) { + continue; + } + if (in_array($val['type'], array('html', 'text'))) { + continue; + } + if (in_array($val['type'], array('timestamp', 'date', 'datetime'))) { + $arrayofxaxis[$tablealias.'.'.$key.'-year'] = array('label' => img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': '.$langs->trans($val['label']).' ('.$YYYY.')', 'position' => ($val['position']+($count * 100000)).'.1'); + $arrayofxaxis[$tablealias.'.'.$key.'-month'] = array('label' => img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': '.$langs->trans($val['label']).' ('.$YYYY.'-'.$MM.')', 'position' => ($val['position']+($count * 100000)).'.2'); + $arrayofxaxis[$tablealias.'.'.$key.'-day'] = array('label' => img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': '.$langs->trans($val['label']).' ('.$YYYY.'-'.$MM.'-'.$DD.')', 'position' => ($val['position']+($count * 100000)).'.3'); + } else { + $arrayofxaxis[$tablealias.'.'.$key] = array('label' => img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': '.$langs->trans($val['label']), 'position' => ($val['position']+($count * 100000))); + } + } + } + // Add extrafields to X-Axis + if ($object->isextrafieldmanaged) { + foreach ($extrafields->attributes[$object->table_element]['label'] as $key => $val) { + if ($extrafields->attributes[$object->table_element]['type'][$key] == 'separate') { + continue; + } + if (!empty($extrafields->attributes[$object->table_element]['totalizable'][$key])) { + continue; + } + $arrayofxaxis[$tablealias.'e.'.$key] = array('label' => img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': '.$langs->trans($extrafields->attributes[$object->table_element]['label'][$key]), 'position' => 1000 + (int) $extrafields->attributes[$object->table_element]['pos'][$key] + ($count * 100000)); + } + } + // Add fields for parent objects + foreach ($object->fields as $key => $val) { + if (preg_match('/^[^:]+:[^:]+:/', $val['type'])) { + $tmptype = explode(':', $val['type'], 4); + if ($tmptype[0] = 'integer' && $tmptype[1] && $tmptype[2]) { + $newobject = $tmptype[1]; + dol_include_once($tmptype[2]); + if (class_exists($newobject)) { + $tmpobject = new $newobject($db); + /*var_dump($val['label']); + var_dump($tmptype); + var_dump($arrayofmesures); + var_dump('t-'.$key);*/ + $count++; + $arrayofxaxis = fillArrayOfXAxis($tmpobject, $tablealias.'__'.$key, $langs->trans($val['label']), $arrayofxaxis, $level + 1, $count); + } else { + print 'Failed to find '.$newobject.' class for field '.$key.' of object '.$object->element."\n"; + } + } + } + } + + return $arrayofxaxis; +} + + +/** + * Fill arrayofgrupby for an object + * + * @param mixed $object Any object + * @param string $tablealias Alias of table + * @param string $labelofobject Label of object + * @param array $arrayofgroupby Array of groupby already filled + * @param int $level Level + * @param int $count Count + * @return array Array of groupby + */ +function fillArrayOfGroupBy($object, $tablealias, $labelofobject, &$arrayofgroupby, $level = 0, &$count = 0) +{ + global $langs, $extrafields, $db; + + if ($level > 10) { // Protection against infinite loop + return $arrayofgroupby; + } + + if ($level >= 2) { + return $arrayofgroupby; + } + + $YYYY = substr($langs->trans("Year"), 0, 1).substr($langs->trans("Year"), 0, 1).substr($langs->trans("Year"), 0, 1).substr($langs->trans("Year"), 0, 1); + $MM = substr($langs->trans("Month"), 0, 1).substr($langs->trans("Month"), 0, 1); + $DD = substr($langs->trans("Day"), 0, 1).substr($langs->trans("Day"), 0, 1); + $HH = substr($langs->trans("Hour"), 0, 1).substr($langs->trans("Hour"), 0, 1); + $MI = substr($langs->trans("Minute"), 0, 1).substr($langs->trans("Minute"), 0, 1); + $SS = substr($langs->trans("Second"), 0, 1).substr($langs->trans("Second"), 0, 1); + + // Add main fields of object + foreach ($object->fields as $key => $val) { + if (!$val['isameasure']) { + if (in_array($key, array( + 'id', 'ref_int', 'ref_ext', 'rowid', 'entity', 'last_main_doc', 'logo', 'logo_squarred', 'extraparams', + 'parent', 'photo', 'socialnetworks', 'webservices_url', 'webservices_key'))) { + continue; + } + if (isset($val['enabled']) && !dol_eval($val['enabled'], 1, 1, '1')) { + continue; + } + if (isset($val['visible']) && !dol_eval($val['visible'], 1, 1, '1')) { + continue; + } + if (preg_match('/^fk_/', $key) && !preg_match('/^fk_statu/', $key)) { + continue; + } + if (preg_match('/^pass/', $key)) { + continue; + } + if (in_array($val['type'], array('html', 'text'))) { + continue; + } + if (in_array($val['type'], array('timestamp', 'date', 'datetime'))) { + $arrayofgroupby[$tablealias.'.'.$key.'-year'] = array('label' => img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': '.$langs->trans($val['label']).' ('.$YYYY.')', 'position' => ($val['position']+($count * 100000)).'.1'); + $arrayofgroupby[$tablealias.'.'.$key.'-month'] = array('label' => img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': '.$langs->trans($val['label']).' ('.$YYYY.'-'.$MM.')', 'position' => ($val['position']+($count * 100000)).'.2'); + $arrayofgroupby[$tablealias.'.'.$key.'-day'] = array('label' => img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': '.$langs->trans($val['label']).' ('.$YYYY.'-'.$MM.'-'.$DD.')', 'position' => ($val['position']+($count * 100000)).'.3'); + } else { + $arrayofgroupby[$tablealias.'.'.$key] = array('label' => img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': '.$langs->trans($val['label']), 'position' => ($val['position']+($count * 100000))); + } + } + } + // Add extrafields to Group by + if ($object->isextrafieldmanaged) { + foreach ($extrafields->attributes[$object->table_element]['label'] as $key => $val) { + if ($extrafields->attributes[$object->table_element]['type'][$key] == 'separate') { + continue; + } + if (!empty($extrafields->attributes[$object->table_element]['totalizable'][$key])) { + continue; + } + $arrayofgroupby[$tablealias.'e.'.$key] = array('label' => img_picto('', $object->picto, 'class="pictofixedwidth"').' '.$labelofobject.': '.$langs->trans($extrafields->attributes[$object->table_element]['label'][$key]), 'position' => 1000 + (int) $extrafields->attributes[$object->table_element]['pos'][$key] + ($count * 100000)); + } + } + // Add fields for parent objects + foreach ($object->fields as $key => $val) { + if (preg_match('/^[^:]+:[^:]+:/', $val['type'])) { + $tmptype = explode(':', $val['type'], 4); + if ($tmptype[0] = 'integer' && $tmptype[1] && $tmptype[2]) { + $newobject = $tmptype[1]; + dol_include_once($tmptype[2]); + if (class_exists($newobject)) { + $tmpobject = new $newobject($db); + /*var_dump($val['label']); + var_dump($tmptype); + var_dump($arrayofmesures); + var_dump('t-'.$key);*/ + $count++; + $arrayofgroupby = fillArrayOfGroupBy($tmpobject, $tablealias.'__'.$key, $langs->trans($val['label']), $arrayofgroupby, $level + 1, $count); + } else { + print 'Failed to find '.$newobject.' class for field '.$key.' of object '.$object->element."\n"; + } + } + } + } + + return $arrayofgroupby; +} diff --git a/htdocs/core/db/Database.interface.php b/htdocs/core/db/Database.interface.php index c6769ad0619..e349072ddec 100644 --- a/htdocs/core/db/Database.interface.php +++ b/htdocs/core/db/Database.interface.php @@ -227,7 +227,7 @@ interface Database * Note that with Mysql, this parameter is not used as Myssql can already commit a transaction even if one request is in error, without using savepoints. * @param string $type Type of SQL order ('ddl' for insert, update, select, delete or 'dml' for create, alter...) * @param int $result_mode Result mode - * @return resource Resultset of answer + * @return bool|resource Resultset of answer or false */ public function query($query, $usesavepoint = 0, $type = 'auto', $result_mode = 0); diff --git a/htdocs/core/db/DoliDB.class.php b/htdocs/core/db/DoliDB.class.php index 29ced10dc35..f23a66bbee4 100644 --- a/htdocs/core/db/DoliDB.class.php +++ b/htdocs/core/db/DoliDB.class.php @@ -62,11 +62,26 @@ abstract class DoliDB implements Database /** @var string Last error number. For example: 'DB_ERROR_RECORD_ALREADY_EXISTS', '12345', ... */ public $lasterrno; + /** @var string If we need to set a prefix specific to the database so it can be reused (when defined instead of MAIN_DB_PREFIX) to forge requests */ + public $prefix_db; + /** @var bool Status */ public $ok; /** @var string */ public $error; + + + /** + * Return the DB prefix + * + * @return string The DB prefix + */ + public function prefix() + { + return (empty($this->prefix_db) ? MAIN_DB_PREFIX : $this->prefix_db); + } + /** * Format a SQL IF * @@ -77,7 +92,8 @@ abstract class DoliDB implements Database */ public function ifsql($test, $resok, $resko) { - return 'IF('.$test.','.$resok.','.$resko.')'; + //return 'IF('.$test.','.$resok.','.$resko.')'; // Not sql standard + return '(CASE WHEN '.$test.' THEN '.$resok.' ELSE '.$resko.' END)'; } /** @@ -233,7 +249,7 @@ abstract class DoliDB implements Database * Define sort criteria of request * * @param string $sortfield List of sort fields, separated by comma. Example: 't1.fielda,t2.fieldb' - * @param string $sortorder Sort order, separated by comma. Example: 'ASC,DESC'; + * @param string $sortorder Sort order, separated by comma. Example: 'ASC,DESC'. Note: If the quantity fo sortorder values is lower than sortfield, we used the last value for missing values. * @return string String to provide syntax of a sort sql string */ public function order($sortfield = null, $sortorder = null) @@ -286,8 +302,8 @@ abstract class DoliDB implements Database /** * Convert (by PHP) a PHP server TZ string date into a Timestamps date (GMT if gm=true) - * 19700101020000 -> 3600 with TZ+1 and gmt=0 - * 19700101020000 -> 7200 whaterver is TZ if gmt=1 + * 19700101020000 -> 3600 with server TZ = +1 and $gm='tzserver' + * 19700101020000 -> 7200 whaterver is server TZ if $gm='gmt' * * @param string $string Date in a string (YYYYMMDDHHMMSS, YYYYMMDD, YYYY-MM-DD HH:MM:SS) * @param mixed $gm 'gmt'=Input informations are GMT values, 'tzserver'=Local to server TZ @@ -319,28 +335,34 @@ abstract class DoliDB implements Database * Return first result from query as object * Note : This method executes a given SQL query and retrieves the first row of results as an object. It should only be used with SELECT queries * Dont add LIMIT to your query, it will be added by this method - * @param string $sql the sql query string - * @return bool| object - * @deprecated + * + * @param string $sql The sql query string + * @return bool|int|object False on failure, 0 on empty, object on success */ public function getRow($sql) { - $sql .= ' LIMIT 1;'; + $sql .= ' LIMIT 1'; $res = $this->query($sql); if ($res) { - return $this->fetch_object($res); + $obj = $this->fetch_object($res); + if ($obj) { + return $obj; + } else { + return 0; + } } return false; } /** - * return all results from query as an array of objects + * Return all results from query as an array of objects * Note : This method executes a given SQL query and retrieves all row of results as an array of objects. It should only be used with SELECT queries - * be carefull with this method use it only with some limit of results to avoid performences loss - * @param string $sql the sql query string - * @return bool| array + * be carefull with this method use it only with some limit of results to avoid performences loss. + * + * @param string $sql The sql query string + * @return bool|array Result * @deprecated */ public function getRows($sql) diff --git a/htdocs/core/db/mysqli.class.php b/htdocs/core/db/mysqli.class.php index 0db4e16a897..fa24e4a70ac 100644 --- a/htdocs/core/db/mysqli.class.php +++ b/htdocs/core/db/mysqli.class.php @@ -210,6 +210,8 @@ class DoliDBMysqli extends DoliDB { dol_syslog(get_class($this)."::connect host=$host, port=$port, login=$login, passwd=--hidden--, name=$name", LOG_DEBUG); + //mysqli_report(MYSQLI_REPORT_ERROR | MYSQLI_REPORT_STRICT); + // Can also be // mysqli::init(); mysql::options(MYSQLI_INIT_COMMAND, 'SET AUTOCOMMIT = 0'); mysqli::options(MYSQLI_OPT_CONNECT_TIMEOUT, 5); // return mysqli::real_connect($host, $user, $pass, $db, $port); @@ -255,6 +257,8 @@ class DoliDBMysqli extends DoliDB return false; } + + /** * Execute a SQL request and return the resultset * @@ -288,11 +292,16 @@ class DoliDBMysqli extends DoliDB } } - if (!$this->database_name) { - // Ordre SQL ne necessitant pas de connexion a une base (exemple: CREATE DATABASE) - $ret = $this->db->query($query, $result_mode); - } else { - $ret = $this->db->query($query, $result_mode); + try { + if (!$this->database_name) { + // Ordre SQL ne necessitant pas de connexion a une base (exemple: CREATE DATABASE) + $ret = $this->db->query($query, $result_mode); + } else { + $ret = $this->db->query($query, $result_mode); + } + } catch (Exception $e) { + dol_syslog(get_class($this)."::query Exception in query instead of returning an error: ".$e->getMessage(), LOG_ERR); + $ret = false; } if (!preg_match("/^COMMIT/i", $query) && !preg_match("/^ROLLBACK/i", $query)) { @@ -663,9 +672,13 @@ class DoliDBMysqli extends DoliDB $like = ''; if ($table) { - $like = "LIKE '".$table."'"; + $tmptable = preg_replace('/[^a-z0-9\.\-\_%]/i', '', $table); + + $like = "LIKE '".$this->escape($tmptable)."'"; } - $sql = "SHOW TABLES FROM ".$database." ".$like.";"; + $tmpdatabase = preg_replace('/[^a-z0-9\.\-\_]/i', '', $database); + + $sql = "SHOW TABLES FROM ".$tmpdatabase." ".$like.";"; //print $sql; $result = $this->query($sql); if ($result) { @@ -688,7 +701,9 @@ class DoliDBMysqli extends DoliDB // phpcs:enable $infotables = array(); - $sql = "SHOW FULL COLUMNS FROM ".$table.";"; + $tmptable = preg_replace('/[^a-z0-9\.\-\_]/i', '', $table); + + $sql = "SHOW FULL COLUMNS FROM ".$tmptable.";"; dol_syslog($sql, LOG_DEBUG); $result = $this->query($sql); @@ -794,7 +809,9 @@ class DoliDBMysqli extends DoliDB public function DDLDropTable($table) { // phpcs:enable - $sql = "DROP TABLE ".$table; + $tmptable = preg_replace('/[^a-z0-9\.\-\_]/i', '', $table); + + $sql = "DROP TABLE ".$tmptable; if (!$this->query($sql)) { return -1; @@ -925,8 +942,9 @@ class DoliDBMysqli extends DoliDB public function DDLDropField($table, $field_name) { // phpcs:enable - $sql = "ALTER TABLE ".$table." DROP COLUMN `".$field_name."`"; - dol_syslog(get_class($this)."::DDLDropField ".$sql, LOG_DEBUG); + $tmp_field_name = preg_replace('/[^a-z0-9\.\-\_]/i', '', $field_name); + + $sql = "ALTER TABLE ".$table." DROP COLUMN `".$tmp_field_name."`"; if ($this->query($sql)) { return 1; } diff --git a/htdocs/core/db/pgsql.class.php b/htdocs/core/db/pgsql.class.php index 5997349d0c5..74abf7a1e36 100644 --- a/htdocs/core/db/pgsql.class.php +++ b/htdocs/core/db/pgsql.class.php @@ -495,7 +495,7 @@ class DoliDBPgsql extends DoliDB * @param int $usesavepoint 0=Default mode, 1=Run a savepoint before and a rollback to savepoint if error (this allow to have some request with errors inside global transactions). * @param string $type Type of SQL order ('ddl' for insert, update, select, delete or 'dml' for create, alter...) * @param int $result_mode Result mode (not used with pgsql) - * @return false|resource Resultset of answer + * @return bool|resource Resultset of answer */ public function query($query, $usesavepoint = 0, $type = 'auto', $result_mode = 0) { @@ -937,7 +937,9 @@ class DoliDBPgsql extends DoliDB $escapedlike = ''; if ($table) { - $escapedlike = " AND table_name LIKE '".$this->escape($table)."'"; + $tmptable = preg_replace('/[^a-z0-9\.\-\_%]/i', '', $table); + + $escapedlike = " AND table_name LIKE '".$this->escape($tmptable)."'"; } $result = pg_query($this->db, "SELECT table_name FROM information_schema.tables WHERE table_schema = 'public'".$escapedlike." ORDER BY table_name"); if ($result) { @@ -973,8 +975,8 @@ class DoliDBPgsql extends DoliDB $sql .= " '' as \"Extra\","; $sql .= " '' as \"Privileges\""; $sql .= " FROM information_schema.columns infcol"; - $sql .= " WHERE table_schema='public' "; - $sql .= " AND table_name='".$this->escape($table)."'"; + $sql .= " WHERE table_schema = 'public' "; + $sql .= " AND table_name = '".$this->escape($table)."'"; $sql .= " ORDER BY ordinal_position;"; dol_syslog($sql, LOG_DEBUG); @@ -1078,7 +1080,9 @@ class DoliDBPgsql extends DoliDB public function DDLDropTable($table) { // phpcs:enable - $sql = "DROP TABLE ".$table; + $tmptable = preg_replace('/[^a-z0-9\.\-\_]/i', '', $table); + + $sql = "DROP TABLE ".$tmptable; if (!$this->query($sql)) { return -1; @@ -1236,8 +1240,9 @@ class DoliDBPgsql extends DoliDB public function DDLDropField($table, $field_name) { // phpcs:enable - $sql = "ALTER TABLE ".$table." DROP COLUMN ".$field_name; - dol_syslog($sql, LOG_DEBUG); + $tmp_field_name = preg_replace('/[^a-z0-9\.\-\_]/i', '', $field_name); + + $sql = "ALTER TABLE ".$table." DROP COLUMN ".$tmp_field_name; if (!$this->query($sql)) { $this->error = $this->lasterror(); return -1; diff --git a/htdocs/core/db/sqlite3.class.php b/htdocs/core/db/sqlite3.class.php index c03d2a5ee04..10f9c021c0d 100644 --- a/htdocs/core/db/sqlite3.class.php +++ b/htdocs/core/db/sqlite3.class.php @@ -394,7 +394,7 @@ class DoliDBSqlite3 extends DoliDB * Note that with Mysql, this parameter is not used as Myssql can already commit a transaction even if one request is in error, without using savepoints. * @param string $type Type of SQL order ('ddl' for insert, update, select, delete or 'dml' for create, alter...) * @param int $result_mode Result mode (not used with sqlite) - * @return SQLite3Result Resultset of answer + * @return bool|SQLite3Result Resultset of answer */ public function query($query, $usesavepoint = 0, $type = 'auto', $result_mode = 0) { @@ -407,6 +407,7 @@ class DoliDBSqlite3 extends DoliDB $this->error = ''; // Convert MySQL syntax to SQLite syntax + $reg = array(); if (preg_match('/ALTER\s+TABLE\s*(.*)\s*ADD\s+CONSTRAINT\s+(.*)\s*FOREIGN\s+KEY\s*\(([\w,\s]+)\)\s*REFERENCES\s+(\w+)\s*\(([\w,\s]+)\)/i', $query, $reg)) { // Ajout d'une clef étrangère à la table // procédure de remplacement de la table pour ajouter la contrainte @@ -875,9 +876,13 @@ class DoliDBSqlite3 extends DoliDB $like = ''; if ($table) { - $like = "LIKE '".$table."'"; + $tmptable = preg_replace('/[^a-z0-9\.\-\_%]/i', '', $table); + + $like = "LIKE '".$this->escape($tmptable)."'"; } - $sql = "SHOW TABLES FROM ".$database." ".$like.";"; + $tmpdatabase = preg_replace('/[^a-z0-9\.\-\_]/i', '', $database); + + $sql = "SHOW TABLES FROM ".$tmpdatabase." ".$like.";"; //print $sql; $result = $this->query($sql); if ($result) { @@ -901,7 +906,9 @@ class DoliDBSqlite3 extends DoliDB // phpcs:enable $infotables = array(); - $sql = "SHOW FULL COLUMNS FROM ".$table.";"; + $tmptable = preg_replace('/[^a-z0-9\.\-\_]/i', '', $table); + + $sql = "SHOW FULL COLUMNS FROM ".$tmptable.";"; dol_syslog($sql, LOG_DEBUG); $result = $this->query($sql); @@ -1002,7 +1009,9 @@ class DoliDBSqlite3 extends DoliDB public function DDLDropTable($table) { // phpcs:enable - $sql = "DROP TABLE ".$table; + $tmptable = preg_replace('/[^a-z0-9\.\-\_]/i', '', $table); + + $sql = "DROP TABLE ".$tmptable; if (!$this->query($sql)) { return -1; @@ -1112,8 +1121,9 @@ class DoliDBSqlite3 extends DoliDB public function DDLDropField($table, $field_name) { // phpcs:enable - $sql = "ALTER TABLE ".$table." DROP COLUMN `".$field_name."`"; - dol_syslog(get_class($this)."::DDLDropField ".$sql, LOG_DEBUG); + $tmp_field_name = preg_replace('/[^a-z0-9\.\-\_]/i', '', $field_name); + + $sql = "ALTER TABLE ".$table." DROP COLUMN `".$tmp_field_name."`"; if (!$this->query($sql)) { $this->error = $this->lasterror(); return -1; diff --git a/htdocs/core/extrafieldsinexport.inc.php b/htdocs/core/extrafieldsinexport.inc.php index 70dd0077e57..fc2210eabd8 100644 --- a/htdocs/core/extrafieldsinexport.inc.php +++ b/htdocs/core/extrafieldsinexport.inc.php @@ -48,7 +48,7 @@ if ($resql) { // This can fail when class is used on old database (during mig case 'sellist': $tmp = ''; $tmpparam = jsonOrUnserialize($obj->param); // $tmp may be array 'options' => array 'c_currencies:code_iso:code_iso' => null - if ($tmpparam['options'] && is_array($tmpparam['options'])) { + if (is_array($tmpparam) && array_key_exists('options', $tmpparam) && $tmpparam['options'] && is_array($tmpparam['options'])) { $tmpkeys = array_keys($tmpparam['options']); $tmp = array_shift($tmpkeys); } diff --git a/htdocs/core/get_info.php b/htdocs/core/get_info.php index 4927be6a005..067372c26ff 100644 --- a/htdocs/core/get_info.php +++ b/htdocs/core/get_info.php @@ -33,7 +33,7 @@ if (!defined('NOCSRFCHECK')) { if (!defined('NOTOKENRENEWAL')) { define('NOTOKENRENEWAL', 1); } -//if (! defined('NOLOGIN')) define('NOLOGIN',1); // Not disabled cause need to load personalized language +//if (! defined('NOLOGIN')) define('NOLOGIN',1); // Not disabled cause need to load personalized language and need security layer if (!defined('NOREQUIREMENU')) { define('NOREQUIREMENU', 1); } @@ -56,8 +56,8 @@ $left = ($langs->trans("DIRECTION") == 'rtl' ? 'right' : 'left'); $title = $langs->trans("Info"); -// URL http://mydolibarr/core/search_page?dol_use_jmobile=1 can be used for tests -$head = ''."\n"; +// URL http://mydolibarr/core/get_info.php?dol_use_jmobile=1 can be used for tests +$head = ''."\n"; $arrayofjs = array(); $arrayofcss = array(); top_htmlhead($head, $title, 0, 0, $arrayofjs, $arrayofcss); @@ -83,8 +83,8 @@ if (!empty($conf->global->MAIN_APPLICATION_TITLE)) { $appli .= " ".DOL_VERSION; } -if (!empty($conf->global->MAIN_FEATURES_LEVEL)) { - $appli .= "
    ".$langs->trans("LevelOfFeature").': '.$conf->global->MAIN_FEATURES_LEVEL; +if (getDolGlobalInt('MAIN_FEATURES_LEVEL')) { + $appli .= "
    ".$langs->trans("LevelOfFeature").': '.getDolGlobalInt('MAIN_FEATURES_LEVEL'); } $logouttext = ''; @@ -93,7 +93,7 @@ if (empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER)) { if ($_SESSION["dol_authmode"] != 'forceuser' && $_SESSION["dol_authmode"] != 'http') { $logouthtmltext .= $langs->trans("Logout").'
    '; - $logouttext .= ''; + $logouttext .= ''; //$logouttext .= img_picto($langs->trans('Logout').":".$langs->trans('Logout'), 'logout_top.png', 'class="login"', 0, 0, 1); $logouttext .= ''; $logouttext .= ''; @@ -158,7 +158,7 @@ if (empty($conf->global->MAIN_PRINT_DISABLELINK) && empty($conf->global->MAIN_OP } } $qs.=(($qs && $morequerystring)?'&':'').$morequerystring; - $text =''; + $text =''; //$text.= img_picto(":".$langs->trans("PrintContentArea"), 'printer_top.png', 'class="printer"'); $text.=''; $text.=''; @@ -191,7 +191,7 @@ if (empty($conf->global->MAIN_HELP_DISABLELINK) && empty($conf->global->MAIN_OPT $title=$appli.'
    '; $title.=$langs->trans($mode == 'wiki' ? 'GoToWikiHelpPage': 'GoToHelpPage'); if ($mode == 'wiki') $title.=' - '.$langs->trans("PageWiki").' "'.dol_escape_htmltag(strtr($helppage,'_',' ')).'"'; - $text.=''; diff --git a/htdocs/core/get_menudiv.php b/htdocs/core/get_menudiv.php index 84be9ff8e0f..597031945f1 100644 --- a/htdocs/core/get_menudiv.php +++ b/htdocs/core/get_menudiv.php @@ -81,10 +81,22 @@ $left = ($langs->trans("DIRECTION") == 'rtl' ? 'right' : 'left'); * View */ +// Important: Following code is to avoid page request by browser and PHP CPU at each Dolibarr page access. +if (empty($dolibarr_nocache) && GETPOST('cache', 'int')) { + header('Cache-Control: max-age='.GETPOST('cache', 'int').', public, must-revalidate'); + // For a .php, we must set an Expires to avoid to have it forced to an expired value by the web server + header('Expires: '.gmdate('D, d M Y H:i:s', dol_now('gmt') + GETPOST('cache', 'int')).' GMT'); + // HTTP/1.0 + header('Pragma: token=public'); +} else { + // HTTP/1.0 + header('Cache-Control: no-cache'); +} + $title = $langs->trans("Menu"); // URL http://mydolibarr/core/get_menudiv.php?dol_use_jmobile=1 can be used for tests -$head = ''."\n"; +$head = ''."\n"; // This is used by DoliDroid to know page is a menu page $arrayofjs = array(); $arrayofcss = array(); top_htmlhead($head, $title, 0, 0, $arrayofjs, $arrayofcss); @@ -109,12 +121,13 @@ print ' display: none; } - a.alilevel0 { + a.alilevel0, span.spanlilevel0 { background-image: url(\''.DOL_URL_ROOT.'/theme/'.urlencode($conf->theme).'/img/next.png\') !important; background-repeat: no-repeat !important; background-position-x: 10px; background-position-y: 16px; padding: 1em 15px 1em 40px; + display: block; } li.lilevel0 font.vsmenudisabled { background-repeat: no-repeat !important; diff --git a/htdocs/core/js/dst.js b/htdocs/core/js/dst.js index 83d4abd5f08..8433ada72a9 100644 --- a/htdocs/core/js/dst.js +++ b/htdocs/core/js/dst.js @@ -26,7 +26,8 @@ $(document).ready(function () { var timezone = jstz.determine(); - + console.log("Timezone detected for user: "+timezone.name()); + // Detect and save TZ and DST var rightNow = new Date(); var jan1 = new Date(rightNow.getFullYear(), 0, 1, 0, 0, 0, 0); diff --git a/htdocs/core/js/lib_head.js.php b/htdocs/core/js/lib_head.js.php index 68bb8236d72..1e9b53b1424 100644 --- a/htdocs/core/js/lib_head.js.php +++ b/htdocs/core/js/lib_head.js.php @@ -562,7 +562,7 @@ function setConstant(url, code, input, entity, strict, forcereload, userid, toke value: value }, function() { /* handler for success of post */ - console.log("url request success forcereload="+forcereload+" value="+value); + console.log("Ajax url request to set constant is a success. Make complementary actions and then forcereload="+forcereload+" value="+value); if (value == 0) { $("#set_" + code).show(); $("#del_" + code).hide(); @@ -615,9 +615,19 @@ function setConstant(url, code, input, entity, strict, forcereload, userid, toke } }); if (forcereload) { - location.reload(); + var url = window.location.href; + if (url.indexOf('dol_resetcache') < 0) { + if (url.indexOf('?') > -1) { + url = url + "&dol_resetcache=1"; + } else { + url = url + "?dol_resetcache=1"; + } + } + window.location.href = url; + //location.reload(); + return false; } - }).fail(function(error) { location.reload(); }); /* When it fails, we always force reload to have setEventErrorMessages in session visible */ + }).fail(function(error) { console.log("Error, we force reload"); location.reload(); }); /* When it fails, we always force reload to have setEventErrorMessages in session visible */ } /* @@ -642,7 +652,7 @@ function delConstant(url, code, input, entity, strict, forcereload, userid, toke token: token }, function() { - console.log("url request success forcereload="+forcereload); + console.log("Ajax url request to delete constant is success. Make complementary actions and then forcereload="+forcereload); $("#del_" + code).hide(); $("#set_" + code).show(); $.each(input, function(type, data) { @@ -686,9 +696,19 @@ function delConstant(url, code, input, entity, strict, forcereload, userid, toke } }); if (forcereload) { - location.reload(); + var url = window.location.href; + if (url.indexOf('dol_resetcache') < 0) { + if (url.indexOf('?') > -1) { + url = url + "&dol_resetcache=1"; + } else { + url = url + "?dol_resetcache=1"; + } + } + window.location.href = url; + //location.reload(); + return false; } - }).fail(function(error) { location.reload(); }); /* When it fails, we always force reload to have setEventErrorMessages in session visible */ + }).fail(function(error) { console.log("Error, we force reload"); location.reload(); }); /* When it fails, we always force reload to have setEventErrorMessages in session visible */ } /* diff --git a/htdocs/core/js/lib_notification.js.php b/htdocs/core/js/lib_notification.js.php index ee41555119a..af5952f6026 100644 --- a/htdocs/core/js/lib_notification.js.php +++ b/htdocs/core/js/lib_notification.js.php @@ -64,26 +64,31 @@ print "jQuery(document).ready(function () {\n"; //print " console.log('referrer=".dol_escape_js($_SERVER['HTTP_REFERER'])."');\n"; print ' var nowtime = Date.now();'; -print ' var time_auto_update = '.$conf->global->MAIN_BROWSER_NOTIFICATION_FREQUENCY.';'."\n"; // Always defined +print ' var time_auto_update = '.max(1, getDolGlobalInt('MAIN_BROWSER_NOTIFICATION_FREQUENCY')).';'."\n"; // Always defined print ' var time_js_next_test;'."\n"; ?> -/* Check if permission ok */ -if (Notification.permission !== "granted") { - console.log("Ask Notification.permission"); - Notification.requestPermission() +/* Check if Notification is supported */ +if ("Notification" in window) { + /* Check if permission ok */ + if (Notification.permission !== "granted") { + console.log("Ask Notification.permission"); + Notification.requestPermission() + } + + /* Launch timer */ + + // We set a delay before launching first test so next check will arrive after the time_auto_update compared to previous one. + //var time_first_execution = (time_auto_update + (time_js_next_test - nowtime)) * 1000; //need milliseconds + var time_first_execution = global->MAIN_BROWSER_NOTIFICATION_CHECK_FIRST_EXECUTION) ? 0 : $conf->global->MAIN_BROWSER_NOTIFICATION_CHECK_FIRST_EXECUTION); ?>; + + setTimeout(first_execution, time_first_execution * 1000); + time_js_next_test = nowtime + time_first_execution; + console.log("Launch browser notif check: setTimeout is set to launch 'first_execution' function after a wait of time_first_execution="+time_first_execution+". nowtime (time php page generation) = "+nowtime+" time_js_next_check = "+time_js_next_test); +} else { + console.log("This browser in this context does not support Notification."); } -/* Launch timer */ - -// We set a delay before launching first test so next check will arrive after the time_auto_update compared to previous one. -//var time_first_execution = (time_auto_update + (time_js_next_test - nowtime)) * 1000; //need milliseconds -var time_first_execution = global->MAIN_BROWSER_NOTIFICATION_CHECK_FIRST_EXECUTION) ? 0 : $conf->global->MAIN_BROWSER_NOTIFICATION_CHECK_FIRST_EXECUTION); ?>; - -setTimeout(first_execution, time_first_execution * 1000); -time_js_next_test = nowtime + time_first_execution; -console.log("Launch browser notif check: setTimeout is set to launch 'first_execution' function after a wait of time_first_execution="+time_first_execution+". nowtime (time php page generation) = "+nowtime+" time_js_next_check = "+time_js_next_test); - function first_execution() { console.log("Call first_execution then set repeat time to time_auto_update = MAIN_BROWSER_NOTIFICATION_FREQUENCY = "+time_auto_update); diff --git a/htdocs/core/js/lib_photosresize.js b/htdocs/core/js/lib_photosresize.js index 99c7c36c29e..38c508f90b3 100644 --- a/htdocs/core/js/lib_photosresize.js +++ b/htdocs/core/js/lib_photosresize.js @@ -32,12 +32,40 @@ function updateCoords(c) { //alert(parseInt(jQuery("#ratioforcrop").val())); ratio=1; - if (parseInt(jQuery("#ratioforcrop").val()) > 0) ratio = parseInt(jQuery("#ratioforcrop").val()); + imagewidth=0; + imageheight=0; + + console.log(c); + + if (parseInt(jQuery("#ratioforcrop").val()) > 1) { + ratio = parseInt(jQuery("#ratioforcrop").val()); + if (parseInt(jQuery("#imagewidth").val()) > 0) imagewidth = parseInt(jQuery("#imagewidth").val()); + if (parseInt(jQuery("#imageheight").val()) > 0) imageheight = parseInt(jQuery("#imageheight").val()); + } + + x = Math.floor(c.x * ratio); + y = Math.floor(c.y * ratio); + x2 = Math.ceil(c.x2 * ratio); + y2 = Math.ceil(c.y2 * ratio); + console.log("x="+x+" y="+y+" x2="+x2+" y2="+y2+" imageheight="+imageheight+" ratio="+ratio); + if (imagewidth > 0 && x > imagewidth) { + x = imagewidth; + } + if (imageheight > 0 && y > imageheight) { + y = imageheight; + } + if (imagewidth > 0 && x2 > imagewidth) { + x2 = imagewidth; + } + if (imageheight > 0 && y2 > imageheight) { + y2 = imageheight; + } + //console.log(ratio); - jQuery('#x').val(Math.ceil(c.x * ratio)); - jQuery('#y').val(Math.ceil(c.y * ratio)); - jQuery('#x2').val(Math.ceil(c.x2 * ratio)); - jQuery('#y2').val(Math.ceil(c.y2 * ratio)); - jQuery('#w').val(Math.ceil(c.w * ratio)); - jQuery('#h').val(Math.ceil(c.h * ratio)); + jQuery('#x').val(x); + jQuery('#y').val(y); + jQuery('#x2').val(x2); + jQuery('#y2').val(y2); + jQuery('#w').val(x2-x); + jQuery('#h').val(y2-y); }; diff --git a/htdocs/core/lib/admin.lib.php b/htdocs/core/lib/admin.lib.php index 842d7333bbd..6054b05aab3 100644 --- a/htdocs/core/lib/admin.lib.php +++ b/htdocs/core/lib/admin.lib.php @@ -240,6 +240,7 @@ function run_sql($sqlfile, $silent = 1, $entity = '', $usesavepoint = 1, $handle if (empty($nocommentremoval)) { $buf = preg_replace('/([,;ERLT\)])\s*--.*$/i', '\1', $buf); //remove comment from a line that not start with -- before add it to the buffer } + if ($buffer) $buffer .= ' '; $buffer .= trim($buf); } @@ -319,6 +320,7 @@ function run_sql($sqlfile, $silent = 1, $entity = '', $usesavepoint = 1, $handle // Loop on each request to execute request $cursorinsert = 0; $listofinsertedrowid = array(); + $keyforsql = md5($sqlfile); foreach ($arraysql as $i => $sql) { if ($sql) { // Replace the prefix tables @@ -334,7 +336,7 @@ function run_sql($sqlfile, $silent = 1, $entity = '', $usesavepoint = 1, $handle // Add log of request if (!$silent) { - print ''.$langs->trans("Request").' '.($i + 1)." sql='".dol_htmlentities($newsql, ENT_NOQUOTES)."'\n"; + print ''.$langs->trans("Request").' '.($i + 1)." sql='".dol_htmlentities($newsql, ENT_NOQUOTES)."'\n"; } dol_syslog('Admin.lib::run_sql Request '.($i + 1), LOG_DEBUG); $sqlmodified = 0; @@ -451,20 +453,20 @@ function run_sql($sqlfile, $silent = 1, $entity = '', $usesavepoint = 1, $handle } //if (!empty($conf->use_javascript_ajax)) { // use_javascript_ajax is not defined - print ''; - print ' - '.$langs->trans("ShowHideDetails").''; + print ' - '.$langs->trans("ShowHideDetails").''; //} print ''."\n"; @@ -637,8 +639,9 @@ function modules_prepare_head($nbofactivatedmodules, $nboftotalmodules) $mode = empty($conf->global->MAIN_MODULE_SETUP_ON_LIST_BY_DEFAULT) ? 'commonkanban' : 'common'; $head[$h][0] = DOL_URL_ROOT."/admin/modules.php?mode=".$mode; if ($nbofactivatedmodules <= (empty($conf->global->MAIN_MIN_NB_ENABLED_MODULE_FOR_WARNING) ? 1 : $conf->global->MAIN_MIN_NB_ENABLED_MODULE_FOR_WARNING)) { // If only minimal initial modules enabled) - $head[$h][1] = $form->textwithpicto($langs->trans("AvailableModules"), $desc); - $head[$h][1] .= img_warning($langs->trans("YouMustEnableOneModule")); + //$head[$h][1] = $form->textwithpicto($langs->trans("AvailableModules"), $desc); + $head[$h][1] = $langs->trans("AvailableModules"); + $head[$h][1] .= $form->textwithpicto('', $langs->trans("YouMustEnableOneModule").'.

    '.$desc.'', 1, 'warning'); } else { //$head[$h][1] = $langs->trans("AvailableModules").$form->textwithpicto(''.$nbofactivatedmodules.' / '.$nboftotalmodules.'', $desc, 1, 'help', '', 1, 3); $head[$h][1] = $langs->trans("AvailableModules").''.$nbofactivatedmodules.' / '.$nboftotalmodules.''; @@ -1625,6 +1628,7 @@ function form_constantes($tableau, $strictw3c = 0, $helptext = '', $text = 'Valu if (empty($strictw3c)) { print "\n".'
    '; print ''; + print ''; } print ''; @@ -1731,7 +1735,7 @@ function form_constantes($tableau, $strictw3c = 0, $helptext = '', $text = 'Valu // Submit if (empty($strictw3c)) { print ''; - print ''; + print ''; print ""; } @@ -1746,7 +1750,7 @@ function form_constantes($tableau, $strictw3c = 0, $helptext = '', $text = 'Valu print '
    '; if (!empty($strictw3c) && $strictw3c == 1) { - print '
    '; + print '
    '; print "\n"; } } diff --git a/htdocs/core/lib/agenda.lib.php b/htdocs/core/lib/agenda.lib.php index 667a2808f58..d2528f45dfa 100644 --- a/htdocs/core/lib/agenda.lib.php +++ b/htdocs/core/lib/agenda.lib.php @@ -73,11 +73,11 @@ function print_actions_filter($form, $canedit, $status, $year, $month, $day, $sh print '
    '; // Type - print ''; $multiselect = 0; if (!empty($conf->global->MAIN_ENABLE_MULTISELECT_TYPE)) { // We use an option here because it adds bugs when used on agenda page "peruser" and "list" $multiselect = (!empty($conf->global->AGENDA_USE_EVENT_TYPE)); } + print img_picto($langs->trans("ActionType"), 'square', 'class="fawidth30 inline-block" style="color: #ddd;"'); print $formactions->select_type_actions($actioncode, "search_actioncode", $excludetype, (empty($conf->global->AGENDA_USE_EVENT_TYPE) ? 1 : -1), 0, $multiselect, 0, 'maxwidth500'); print '
    '; @@ -183,7 +183,7 @@ function show_array_actions_to_do($max = 5) print '
    '; print ''; print ''; - print ''; + print ''; print ''; $i = 0; @@ -299,7 +299,7 @@ function show_array_last_actions_done($max = 5) print '
    '; print '
    '.$langs->trans("LastActionsToDo", $max).''.$langs->trans("FullList").''.$langs->trans("FullList").'
    '; print ''; - print ''; + print ''; print ''; $i = 0; @@ -479,22 +479,22 @@ function calendars_prepare_head($param) $h = 0; $head = array(); - $head[$h][0] = DOL_URL_ROOT.'/comm/action/list.php?action=show_list'.($param ? '&'.$param : ''); + $head[$h][0] = DOL_URL_ROOT.'/comm/action/list.php?mode=show_list'.($param ? '&'.$param : ''); $head[$h][1] = $langs->trans("ViewList"); $head[$h][2] = 'cardlist'; $h++; - $head[$h][0] = DOL_URL_ROOT.'/comm/action/index.php?action=show_month'.($param ? '&'.$param : ''); + $head[$h][0] = DOL_URL_ROOT.'/comm/action/index.php?mode=show_month'.($param ? '&'.$param : ''); $head[$h][1] = $langs->trans("ViewCal"); $head[$h][2] = 'cardmonth'; $h++; - $head[$h][0] = DOL_URL_ROOT.'/comm/action/index.php?action=show_week'.($param ? '&'.$param : ''); + $head[$h][0] = DOL_URL_ROOT.'/comm/action/index.php?mode=show_week'.($param ? '&'.$param : ''); $head[$h][1] = $langs->trans("ViewWeek"); $head[$h][2] = 'cardweek'; $h++; - $head[$h][0] = DOL_URL_ROOT.'/comm/action/index.php?action=show_day'.($param ? '&'.$param : ''); + $head[$h][0] = DOL_URL_ROOT.'/comm/action/index.php?mode=show_day'.($param ? '&'.$param : ''); $head[$h][1] = $langs->trans("ViewDay"); $head[$h][2] = 'cardday'; $h++; diff --git a/htdocs/core/lib/ajax.lib.php b/htdocs/core/lib/ajax.lib.php index 903bb08f655..e7bea722e0c 100644 --- a/htdocs/core/lib/ajax.lib.php +++ b/htdocs/core/lib/ajax.lib.php @@ -563,9 +563,9 @@ function ajax_constantonoff($code, $input = array(), $entity = null, $revertonof if (empty($conf->use_javascript_ajax) || $forcenoajax) { if (empty($conf->global->$code)) { - print ''.img_picto($langs->trans("Disabled"), 'off').''; + print ''.img_picto($langs->trans("Disabled"), 'off').''; } else { - print ''.img_picto($langs->trans("Enabled"), 'on').''; + print ''.img_picto($langs->trans("Enabled"), 'on').''; } } else { $out = "\n".' @@ -573,10 +573,10 @@ function ajax_constantonoff($code, $input = array(), $entity = null, $revertonof $(document).ready(function() { var input = '.json_encode($input).'; var url = \''.DOL_URL_ROOT.'/core/ajax/constantonoff.php\'; - var code = \''.$code.'\'; - var entity = \''.$entity.'\'; - var strict = \''.$strict.'\'; - var userid = \''.$user->id.'\'; + var code = \''.dol_escape_js($code).'\'; + var entity = \''.dol_escape_js($entity).'\'; + var strict = \''.dol_escape_js($strict).'\'; + var userid = \''.dol_escape_js($user->id).'\'; var yesButton = \''.dol_escape_js($langs->transnoentities("Yes")).'\'; var noButton = \''.dol_escape_js($langs->transnoentities("No")).'\'; var token = \''.currentToken().'\'; @@ -588,7 +588,7 @@ function ajax_constantonoff($code, $input = array(), $entity = null, $revertonof if (input.alert.set.noButton) noButton = input.alert.set.noButton; confirmConstantAction("set", url, code, input, input.alert.set, entity, yesButton, noButton, strict, userid, token); } else { - setConstant(url, code, input, entity, 0, '.$forcereload.', userid, token); + setConstant(url, code, input, entity, 0, '.((int) $forcereload).', userid, token); } }); @@ -600,9 +600,9 @@ function ajax_constantonoff($code, $input = array(), $entity = null, $revertonof confirmConstantAction("del", url, code, input, input.alert.del, entity, yesButton, noButton, strict, userid, token); } else {'; if (empty($setzeroinsteadofdel)) { - $out .=' delConstant(url, code, input, entity, 0, '.$forcereload.', userid, token);'; + $out .=' delConstant(url, code, input, entity, 0, '.((int) $forcereload).', userid, token);'; } else { - $out .=' setConstant(url, code, input, entity, 0, '.$forcereload.', userid, token, 0);'; + $out .=' setConstant(url, code, input, entity, 0, '.((int) $forcereload).', userid, token, 0);'; } $out .= ' } }); diff --git a/htdocs/core/lib/asset.lib.php b/htdocs/core/lib/asset.lib.php index 840aca1339a..9d71e2b38f1 100644 --- a/htdocs/core/lib/asset.lib.php +++ b/htdocs/core/lib/asset.lib.php @@ -1,5 +1,5 @@ +/* Copyright (C) 2018-2022 OpenDSI * * 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 @@ -26,7 +26,7 @@ * * @return array head array with tabs */ -function asset_admin_prepare_head() +function assetAdminPrepareHead() { global $langs, $conf; @@ -43,90 +43,118 @@ function asset_admin_prepare_head() // Show more tabs from modules // Entries must be declared in modules descriptor with line //$this->tabs = array( - // 'entity:+tabname:Title:@assets:/asset/mypage.php?id=__ID__' + // 'entity:+tabname:Title:@asset:/asset/mypage.php?id=__ID__' //); // to add new tab //$this->tabs = array( - // 'entity:-tabname:Title:@assets:/asset/mypage.php?id=__ID__' + // 'entity:-tabname:Title:@asset:/asset/mypage.php?id=__ID__' //); // to remove a tab - complete_head_from_modules($conf, $langs, null, $head, $h, 'assets_admin'); + complete_head_from_modules($conf, $langs, null, $head, $h, 'asset_admin'); - $head[$h][0] = DOL_URL_ROOT.'/asset/admin/assets_extrafields.php'; + $head[$h][0] = DOL_URL_ROOT.'/asset/admin/asset_extrafields.php'; $head[$h][1] = $langs->trans("ExtraFields"); - $head[$h][2] = 'attributes'; + $head[$h][2] = 'asset_extrafields'; $h++; - $head[$h][0] = DOL_URL_ROOT.'/asset/admin/assets_type_extrafields.php'; - $head[$h][1] = $langs->trans("ExtraFieldsAssetsType"); - $head[$h][2] = 'attributes_type'; + $head[$h][0] = DOL_URL_ROOT.'/asset/admin/assetmodel_extrafields.php'; + $head[$h][1] = $langs->trans("ExtraFieldsAssetModel"); + $head[$h][2] = 'assetmodel_extrafields'; $h++; - complete_head_from_modules($conf, $langs, null, $head, $h, 'assets_admin', 'remove'); + complete_head_from_modules($conf, $langs, null, $head, $h, 'asset_admin', 'remove'); return $head; } /** - * Prepare admin pages header + * Prepare array of tabs for Asset * - * @param Contrat $object Object related to tabs - * @return array head array with tabs + * @param Asset $object Asset + * @return array Array of tabs */ -function asset_prepare_head(Asset $object) +function assetPrepareHead(Asset $object) { global $db, $langs, $conf; - $langs->load("assets"); + $langs->load("assets", "admin"); $h = 0; $head = array(); - $head[$h][0] = DOL_URL_ROOT.'/asset/card.php?id='.$object->id; + $head[$h][0] = DOL_URL_ROOT . '/asset/card.php?id=' . $object->id; $head[$h][1] = $langs->trans("Card"); $head[$h][2] = 'card'; $h++; + if (empty($object->not_depreciated)) { + $head[$h][0] = DOL_URL_ROOT . '/asset/depreciation_options.php?id=' . $object->id; + $head[$h][1] = $langs->trans("AssetDepreciationOptions"); + $head[$h][2] = 'depreciation_options'; + $h++; + } + + $head[$h][0] = DOL_URL_ROOT . '/asset/accountancy_codes.php?id=' . $object->id; + $head[$h][1] = $langs->trans("AssetAccountancyCodes"); + $head[$h][2] = 'accountancy_codes'; + $h++; + + if (empty($object->not_depreciated)) { + $head[$h][0] = DOL_URL_ROOT . '/asset/depreciation.php?id=' . $object->id; + $head[$h][1] = $langs->trans("AssetDepreciation"); + $head[$h][2] = 'depreciation'; + $h++; + } + + if (isset($object->disposal_date) && $object->disposal_date !== "") { + $head[$h][0] = DOL_URL_ROOT . '/asset/disposal.php?id=' . $object->id; + $head[$h][1] = $langs->trans("AssetDisposal"); + $head[$h][2] = 'disposal'; + $h++; + } + + if (isset($object->fields['note_public']) || isset($object->fields['note_private'])) { + $nbNote = 0; + if (!empty($object->note_private)) { + $nbNote++; + } + if (!empty($object->note_public)) { + $nbNote++; + } + $head[$h][0] = DOL_URL_ROOT . '/asset/note.php?id=' . $object->id; + $head[$h][1] = $langs->trans('Notes'); + if ($nbNote > 0) { + $head[$h][1] .= (empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER) ? '' . $nbNote . '' : ''); + } + $head[$h][2] = 'note'; + $h++; + } + + require_once DOL_DOCUMENT_ROOT . '/core/lib/files.lib.php'; + require_once DOL_DOCUMENT_ROOT . '/core/class/link.class.php'; + $upload_dir = $conf->asset->dir_output . "/asset/" . dol_sanitizeFileName($object->ref); + $nbFiles = count(dol_dir_list($upload_dir, 'files', 0, '', '(\.meta|_preview.*\.png)$')); + $nbLinks = Link::count($db, $object->element, $object->id); + $head[$h][0] = DOL_URL_ROOT . '/asset/document.php?id=' . $object->id; + $head[$h][1] = $langs->trans('Documents'); + if (($nbFiles + $nbLinks) > 0) { + $head[$h][1] .= '' . ($nbFiles + $nbLinks) . ''; + } + $head[$h][2] = 'document'; + $h++; + + $head[$h][0] = DOL_URL_ROOT . '/asset/agenda.php?id=' . $object->id; + $head[$h][1] = $langs->trans("Events"); + $head[$h][2] = 'agenda'; + $h++; + // Show more tabs from modules // Entries must be declared in modules descriptor with line //$this->tabs = array( - // 'entity:+tabname:Title:@assets:/asset/mypage.php?id=__ID__' + // 'entity:+tabname:Title:@asset:/asset/mypage.php?id=__ID__' //); // to add new tab //$this->tabs = array( - // 'entity:-tabname:Title:@assets:/asset/mypage.php?id=__ID__' + // 'entity:-tabname:Title:@asset:/asset/mypage.php?id=__ID__' //); // to remove a tab - complete_head_from_modules($conf, $langs, $object, $head, $h, 'assets'); - - require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; - require_once DOL_DOCUMENT_ROOT.'/core/class/link.class.php'; - $upload_dir = $conf->assets->dir_output.'/'.dol_sanitizeFileName($object->ref); - $nbFiles = count(dol_dir_list($upload_dir, 'files', 0, '', '(\.meta|_preview.*\.png)$')); - $nbLinks = Link::count($db, $object->element, $object->id); - $head[$h][0] = DOL_URL_ROOT.'/asset/document.php?id='.$object->id; - $head[$h][1] = $langs->trans('Documents'); - if (($nbFiles + $nbLinks) > 0) { - $head[$h][1] .= ''.($nbFiles + $nbLinks).''; - } - $head[$h][2] = 'documents'; - $h++; - - $nbNote = 0; - if (!empty($object->note_private)) { - $nbNote++; - } - if (!empty($object->note_public)) { - $nbNote++; - } - $head[$h][0] = DOL_URL_ROOT.'/asset/note.php?id='.$object->id; - $head[$h][1] = $langs->trans("Notes"); - if ($nbNote > 0) { - $head[$h][1] .= ''.$nbNote.''; - } - $head[$h][2] = 'note'; - $h++; - - $head[$h][0] = DOL_URL_ROOT.'/asset/info.php?id='.$object->id; - $head[$h][1] = $langs->trans("Info"); - $head[$h][2] = 'info'; - $h++; + complete_head_from_modules($conf, $langs, $object, $head, $h, 'asset'); complete_head_from_modules($conf, $langs, $object, $head, $h, 'asset', 'remove'); @@ -134,30 +162,69 @@ function asset_prepare_head(Asset $object) } /** - * Return array head with list of tabs to view object informations + * Prepare array of tabs for AssetModel * - * @param AssetType $object Asset - * @return array head + * @param AssetModel $object AssetModel + * @return array Array of tabs */ -function asset_type_prepare_head(AssetType $object) +function assetModelPrepareHead($object) { - global $langs, $conf, $user; + global $langs, $conf; + + $langs->load("assets", "admin"); $h = 0; $head = array(); - $head[$h][0] = DOL_URL_ROOT.'/asset/type.php?rowid='.$object->id; + $head[$h][0] = DOL_URL_ROOT . '/asset/model/card.php?id=' . $object->id; $head[$h][1] = $langs->trans("Card"); $head[$h][2] = 'card'; $h++; + $head[$h][0] = DOL_URL_ROOT . '/asset/model/depreciation_options.php?id=' . $object->id; + $head[$h][1] = $langs->trans("AssetDepreciationOptions"); + $head[$h][2] = 'depreciation_options'; + $h++; + + $head[$h][0] = DOL_URL_ROOT . '/asset/model/accountancy_codes.php?id=' . $object->id; + $head[$h][1] = $langs->trans("AssetAccountancyCodes"); + $head[$h][2] = 'accountancy_codes'; + $h++; + + if (isset($object->fields['note_public']) || isset($object->fields['note_private'])) { + $nbNote = 0; + if (!empty($object->note_private)) { + $nbNote++; + } + if (!empty($object->note_public)) { + $nbNote++; + } + $head[$h][0] = DOL_URL_ROOT . '/asset/model/note.php?id=' . $object->id; + $head[$h][1] = $langs->trans('Notes'); + if ($nbNote > 0) { + $head[$h][1] .= (empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER) ? '' . $nbNote . '' : ''); + } + $head[$h][2] = 'note'; + $h++; + } + + $head[$h][0] = DOL_URL_ROOT . '/asset/model/agenda.php?id=' . $object->id; + $head[$h][1] = $langs->trans("Events"); + $head[$h][2] = 'agenda'; + $h++; + + // Show more tabs from modules // Entries must be declared in modules descriptor with line - // $this->tabs = array('entity:+tabname:Title:@mymodule:/mymodule/mypage.php?id=__ID__'); to add new tab - // $this->tabs = array('entity:-tabname:Title:@mymodule:/mymodule/mypage.php?id=__ID__'); to remove a tab - complete_head_from_modules($conf, $langs, $object, $head, $h, 'assettype'); + //$this->tabs = array( + // 'entity:+tabname:Title:@asset:/asset/mypage.php?id=__ID__' + //); // to add new tab + //$this->tabs = array( + // 'entity:-tabname:Title:@asset:/asset/mypage.php?id=__ID__' + //); // to remove a tab + complete_head_from_modules($conf, $langs, $object, $head, $h, 'assetmodel'); - complete_head_from_modules($conf, $langs, $object, $head, $h, 'assettype', 'remove'); + complete_head_from_modules($conf, $langs, $object, $head, $h, 'assetmodel', 'remove'); return $head; } diff --git a/htdocs/core/lib/bank.lib.php b/htdocs/core/lib/bank.lib.php index 30a3d21de90..563f0be8665 100644 --- a/htdocs/core/lib/bank.lib.php +++ b/htdocs/core/lib/bank.lib.php @@ -4,6 +4,7 @@ * Copyright (C) 2015 Alexandre Spangaro * Copyright (C) 2016 Juanjo Menent * Copyright (C) 2019 Nicolas ZABOURI + * Copyright (C) 2021 Ferran Marcet * * 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 @@ -66,7 +67,7 @@ function bank_prepare_head(Account $object) $head[$h][2] = 'graph'; $h++; - if ($object->courant != Account::TYPE_CASH) { + if ($object->courant != Account::TYPE_CASH || !empty($conf->global->BANK_CAN_RECONCILIATE_CASHACCOUNT)) { $nbReceipts = 0; // List of all standing receipts @@ -276,7 +277,9 @@ function checkIbanForAccount($account) { require_once DOL_DOCUMENT_ROOT.'/includes/php-iban/oophp-iban.php'; - $iban = new IBAN($account->iban); + $ibantocheck = ($account->iban ? $account->iban : $account->iban_prefix); // iban or iban_prefix for backward compatibility + + $iban = new IBAN($ibantocheck); $check = $iban->Verify(); if ($check) { diff --git a/htdocs/core/lib/company.lib.php b/htdocs/core/lib/company.lib.php index ddaf1d320c3..4bf8a0e7219 100644 --- a/htdocs/core/lib/company.lib.php +++ b/htdocs/core/lib/company.lib.php @@ -199,10 +199,9 @@ function societe_prepare_head(Societe $object) if (empty($conf->global->SOCIETE_DISABLE_BANKACCOUNT)) { $nbBankAccount = 0; $foundonexternalonlinesystem = 0; - $langs->load("banks"); + $langs->load("bills"); - //$title = $langs->trans("BankAccounts"); - $title = $langs->trans("PaymentInformation"); + $title = $langs->trans("PaymentModes"); if (!empty($conf->stripe->enabled)) { //$langs->load("stripe"); @@ -274,6 +273,7 @@ function societe_prepare_head(Societe $object) if (getDolGlobalString('PARTNERSHIP_IS_MANAGED_FOR') == 'thirdparty') { if (!empty($user->rights->partnership->read)) { + $langs->load("partnership"); $nbPartnership = is_array($object->partnerships) ? count($object->partnerships) : 0; $head[$h][0] = DOL_URL_ROOT.'/societe/partnership.php?socid='.$object->id; $head[$h][1] = $langs->trans("Partnership"); @@ -295,7 +295,7 @@ function societe_prepare_head(Societe $object) // Notifications if (!empty($conf->notification->enabled)) { $nbNotif = 0; - // Enable caching of thirdrparty count notifications + // Enable caching of thirdparty count notifications require_once DOL_DOCUMENT_ROOT.'/core/lib/memory.lib.php'; $cachekey = 'count_notifications_thirdparty_'.$object->id; $dataretrieved = dol_getcache($cachekey); @@ -915,8 +915,8 @@ function show_contacts($conf, $langs, $db, $object, $backtopage = '') $form = new Form($db); $optioncss = GETPOST('optioncss', 'alpha'); - $sortfield = GETPOST("sortfield", 'alpha'); - $sortorder = GETPOST("sortorder", 'alpha'); + $sortfield = GETPOST('sortfield', 'aZ09comma'); + $sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); $search_status = GETPOST("search_status", 'int'); @@ -1709,7 +1709,7 @@ function show_actions_done($conf, $langs, $db, $filterobj, $objcon = '', $noprin $out .= ''; $out .= ''; $out .= ''; $out .= ''; $out .= ''; @@ -1781,7 +1781,7 @@ function show_actions_done($conf, $langs, $db, $filterobj, $objcon = '', $noprin $out .= ''; // Author of event - $out .= ''; - // Title - $out .= ''; @@ -1887,13 +1889,8 @@ function show_actions_done($conf, $langs, $db, $filterobj, $objcon = '', $noprin $out .= ''; // Contact(s) for action - if (empty($objcon->id) && isset($histo[$key]['contact_id']) && $histo[$key]['contact_id'] > 0) { - $contactstatic->lastname = $histo[$key]['lastname']; - $contactstatic->firstname = $histo[$key]['firstname']; - $contactstatic->id = $histo[$key]['contact_id']; - $out .= ''; - } elseif (isset($histo[$key]['socpeopleassigned']) && is_array($histo[$key]['socpeopleassigned']) && count($histo[$key]['socpeopleassigned']) > 0) { - $out .= ''; + } elseif (empty($objcon->id) && isset($histo[$key]['contact_id']) && $histo[$key]['contact_id'] > 0) { + $contactstatic->lastname = $histo[$key]['lastname']; + $contactstatic->firstname = $histo[$key]['firstname']; + $contactstatic->id = $histo[$key]['contact_id']; + $contactstatic->photo = $histo[$key]['contact_photo']; + $out .= ''; } else { $out .= ''; } @@ -2103,7 +2106,7 @@ function addMailingEventTypeSQL($actioncode, $objcon, $filterobj) $langs->load("mails"); $sql2 = "SELECT m.rowid as id, m.titre as label, mc.date_envoi as dp, mc.date_envoi as dp2, '100' as percent, 'mailing' as type"; - $sql2 .= ", '' as fk_element, '' as elementtype, '' as contact_id"; + $sql2 .= ", null as fk_element, '' as elementtype, null as contact_id"; $sql2 .= ", 'AC_EMAILING' as acode, '' as alabel, '' as apicto"; $sql2 .= ", u.rowid as user_id, u.login as user_login, u.photo as user_photo, u.firstname as user_firstname, u.lastname as user_lastname"; // User that valid action if (is_object($filterobj) && get_class($filterobj) == 'Societe') { diff --git a/htdocs/core/lib/contact.lib.php b/htdocs/core/lib/contact.lib.php index c60cb0c8c18..5a0c6c376fb 100644 --- a/htdocs/core/lib/contact.lib.php +++ b/htdocs/core/lib/contact.lib.php @@ -57,6 +57,40 @@ function contact_prepare_head(Contact $object) $head[$tab][2] = 'perso'; $tab++; + if (!empty($conf->projet->enabled) && (!empty($user->rights->projet->lire))) { + $nbProject = 0; + // Enable caching of thirdrparty count projects + require_once DOL_DOCUMENT_ROOT.'/core/lib/memory.lib.php'; + $cachekey = 'count_projects_contact_'.$object->id; + $dataretrieved = dol_getcache($cachekey); + + if (!is_null($dataretrieved)) { + $nbProject = $dataretrieved; + } else { + $sql = 'SELECT COUNT(n.rowid) as nb'; + $sql .= ' FROM '.MAIN_DB_PREFIX.'projet as n'; + $sql .= ' INNER JOIN '.MAIN_DB_PREFIX.'element_contact as cc ON (n.rowid = cc.element_id)'; + $sql .= ' WHERE cc.fk_socpeople = '.((int) $object->id); + $sql .= ' AND cc.fk_c_type_contact IN (SELECT rowid FROM '.MAIN_DB_PREFIX.'c_type_contact WHERE element="project" AND source="external")'; + $sql .= ' AND n.entity IN ('.getEntity('project').')'; + $resql = $db->query($sql); + if ($resql) { + $obj = $db->fetch_object($resql); + $nbProject = $obj->nb; + } else { + dol_print_error($db); + } + dol_setcache($cachekey, $nbProject, 120); // If setting cache fails, this is not a problem, so we do not test result. + } + $head[$tab][0] = DOL_URL_ROOT.'/contact/project.php?id='.$object->id; + $head[$tab][1] = $langs->trans("Projects"); + if ($nbProject > 0) { + $head[$tab][1] .= ''.$nbProject.''; + } + $head[$tab][2] = 'project'; + $tab++; + } + // Related items if (!empty($conf->commande->enabled) || !empty($conf->propal->enabled) || !empty($conf->facture->enabled) || !empty($conf->ficheinter->enabled) || (!empty($conf->fournisseur->enabled) && empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD)) || !empty($conf->supplier_order->enabled) || !empty($conf->supplier_invoice->enabled)) { $head[$tab][0] = DOL_URL_ROOT.'/contact/consumption.php?id='.$object->id; @@ -117,3 +151,131 @@ function contact_prepare_head(Contact $object) return $head; } + +/** + * Show html area for list of projects + * + * @param Conf $conf Object conf + * @param Translate $langs Object langs + * @param DoliDB $db Database handler + * @param Object $object Third party object + * @param string $backtopage Url to go once contact is created + * @param int $nocreatelink 1=Hide create project link + * @param string $morehtmlright More html on right of title + * @return int + */ +function show_contacts_projects($conf, $langs, $db, $object, $backtopage = '', $nocreatelink = 0, $morehtmlright = '') +{ + global $user; + + $i = -1; + + if (!empty($conf->projet->enabled) && $user->rights->projet->lire) { + $langs->load("projects"); + + $newcardbutton = ''; + if (!empty($conf->projet->enabled) && $user->rights->projet->creer && empty($nocreatelink)) { + $newcardbutton .= dolGetButtonTitle($langs->trans('AddProject'), '', 'fa fa-plus-circle', DOL_URL_ROOT.'/projet/card.php?socid='.$object->id.'&action=create&backtopage='.urlencode($backtopage)); + } + + print "\n"; + print load_fiche_titre($langs->trans("ProjectsHavingThisContact"), $newcardbutton.$morehtmlright, ''); + print '
    '; + print "\n".'
    '.$langs->trans("LastDoneTasks", $max).''.$langs->trans("FullList").''.$langs->trans("FullList").'
    '; - $out .= $formactions->select_type_actions($actioncode, "actioncode", '', empty($conf->global->AGENDA_USE_EVENT_TYPE) ? 1 : -1, 0, (empty($conf->global->AGENDA_USE_MULTISELECT_TYPE) ? 0 : 1), 1); + $out .= $formactions->select_type_actions($actioncode, "actioncode", '', empty($conf->global->AGENDA_USE_EVENT_TYPE) ? 1 : -1, 0, (empty($conf->global->AGENDA_USE_MULTISELECT_TYPE) ? 0 : 1), 1, 'minwidth200'); $out .= ''; @@ -1729,7 +1729,7 @@ function show_actions_done($conf, $langs, $db, $filterobj, $objcon = '', $noprin if ($donetodo) { $tmp = ''; if (get_class($filterobj) == 'Societe') { - $tmp .= ''; + $tmp .= ''; } $tmp .= ($donetodo != 'done' ? $langs->trans("ActionsToDoShort") : ''); $tmp .= ($donetodo != 'done' && $donetodo != 'todo' ? ' / ' : ''); @@ -1740,14 +1740,14 @@ function show_actions_done($conf, $langs, $db, $filterobj, $objcon = '', $noprin } $out .= getTitleFieldOfList($tmp); } - $out .= getTitleFieldOfList($langs->trans("Ref"), 0, $_SERVER["PHP_SELF"], 'a.id', '', $param, '', $sortfield, $sortorder); - $out .= getTitleFieldOfList($langs->trans("Owner")); - $out .= getTitleFieldOfList($langs->trans("Type")); - $out .= getTitleFieldOfList($langs->trans("Label"), 0, $_SERVER["PHP_SELF"], '', '', $param, '', $sortfield, $sortorder); - $out .= getTitleFieldOfList($langs->trans("Date"), 0, $_SERVER["PHP_SELF"], 'a.datep,a.id', '', $param, 'align="center"', $sortfield, $sortorder); - $out .= getTitleFieldOfList($langs->trans("RelatedObjects"), 0, $_SERVER["PHP_SELF"], '', '', $param, '', $sortfield, $sortorder); - $out .= getTitleFieldOfList($langs->trans("ActionOnContact"), 0, $_SERVER["PHP_SELF"], '', '', $param, '', $sortfield, $sortorder); - $out .= getTitleFieldOfList($langs->trans("Status"), 0, $_SERVER["PHP_SELF"], 'a.percent', '', $param, 'align="center"', $sortfield, $sortorder); + $out .= getTitleFieldOfList("Ref", 0, $_SERVER["PHP_SELF"], 'a.id', '', $param, '', $sortfield, $sortorder); + $out .= getTitleFieldOfList("Owner"); + $out .= getTitleFieldOfList("Type"); + $out .= getTitleFieldOfList("Label", 0, $_SERVER["PHP_SELF"], '', '', $param, '', $sortfield, $sortorder); + $out .= getTitleFieldOfList("Date", 0, $_SERVER["PHP_SELF"], 'a.datep,a.id', '', $param, '', $sortfield, $sortorder, 'center '); + $out .= getTitleFieldOfList("RelatedObjects", 0, $_SERVER["PHP_SELF"], '', '', $param, '', $sortfield, $sortorder); + $out .= getTitleFieldOfList("ActionOnContact", 0, $_SERVER["PHP_SELF"], '', '', $param, '', $sortfield, $sortorder, 'tdoverflowmax125 ', 0, '', 0); + $out .= getTitleFieldOfList("Status", 0, $_SERVER["PHP_SELF"], 'a.percent', '', $param, '', $sortfield, $sortorder, 'center '); $out .= getTitleFieldOfList('', 0, $_SERVER["PHP_SELF"], '', '', $param, '', $sortfield, $sortorder, 'maxwidthsearch '); $out .= '
    '; + $out .= ''; //$userstatic->id=$histo[$key]['userid']; //$userstatic->login=$histo[$key]['login']; //$out.=$userstatic->getLoginUrl(1); @@ -1812,25 +1812,27 @@ function show_actions_done($conf, $langs, $db, $filterobj, $objcon = '', $noprin $labeltype .= ' - '.$arraylist[$actionstatic->code]; // Use code in priority on type_code } } - $out .= ''; + $out .= ''; $out .= $actionstatic->getTypePicto(); $out .= $labeltype; $out .= ''; + // Title/Label of event + $out .= 'trans("Action".$histo[$key]['acode']); $libelle = ($transcode != "Action".$histo[$key]['acode'] ? $transcode : $histo[$key]['alabel']); //$actionstatic->libelle=$libelle; $libelle = $histo[$key]['note']; $actionstatic->id = $histo[$key]['id']; + $out .= ' title="'.dol_escape_htmltag($libelle).'">'; $out .= dol_trunc($libelle, 120); } if (isset($histo[$key]['type']) && $histo[$key]['type'] == 'mailing') { $out .= ''.img_object($langs->trans("ShowEMailing"), "email").' '; $transcode = $langs->trans("Action".$histo[$key]['acode']); $libelle = ($transcode != "Action".$histo[$key]['acode'] ? $transcode : 'Send mass mailing'); + $out .= ' title="'.dol_escape_htmltag($libelle).'">'; $out .= dol_trunc($libelle, 120); } $out .= ''.$contactstatic->getNomUrl(1, '', 10).''; + if (isset($histo[$key]['socpeopleassigned']) && is_array($histo[$key]['socpeopleassigned']) && count($histo[$key]['socpeopleassigned']) > 0) { + $out .= ''; $contact = new Contact($db); foreach ($histo[$key]['socpeopleassigned'] as $cid => $value) { $result = $contact->fetch($cid); @@ -1903,7 +1900,7 @@ function show_actions_done($conf, $langs, $db, $filterobj, $objcon = '', $noprin } if ($result > 0) { - $out .= $contact->getNomUrl(1, '', 16); + $out .= $contact->getNomUrl(-3, '', 10, '', -1, 0, 'paddingright'); if (isset($histo[$key]['acode']) && $histo[$key]['acode'] == 'AC_TEL') { if (!empty($contact->phone_pro)) { $out .= '('.dol_print_phone($contact->phone_pro).')'; @@ -1913,6 +1910,12 @@ function show_actions_done($conf, $langs, $db, $filterobj, $objcon = '', $noprin } } $out .= ''.$contactstatic->getNomUrl(-1, '', 10).' 
    '; + + $sql = 'SELECT p.rowid as id, p.entity, p.title, p.ref, p.public, p.dateo as do, p.datee as de, p.fk_statut as status, p.fk_opp_status, p.opp_amount, p.opp_percent, p.tms as date_update, p.budget_amount'; + $sql .= ', cls.code as opp_status_code, ctc.libelle'; + $sql .= ' FROM '.MAIN_DB_PREFIX.'projet as p'; + $sql .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_lead_status as cls on p.fk_opp_status = cls.rowid'; + $sql .= ' INNER JOIN '.MAIN_DB_PREFIX.'element_contact as cc ON (p.rowid = cc.element_id)'; + $sql .= ' INNER JOIN '.MAIN_DB_PREFIX.'c_type_contact as ctc ON (ctc.rowid = cc.fk_c_type_contact)'; + $sql .= ' WHERE cc.fk_socpeople = '.((int) $object->id); + $sql .= ' AND ctc.element="project" AND ctc.source="external"'; + $sql .= ' AND p.entity IN ('.getEntity('project').')'; + $sql .= ' ORDER BY p.dateo DESC'; + + $result = $db->query($sql); + if ($result) { + $num = $db->num_rows($result); + + print ''; + print ''; + print ''; + print ''; + print ''; + print ''; + print ''; + print ''; + print ''; + print ''; + print ''; + + if ($num > 0) { + require_once DOL_DOCUMENT_ROOT.'/projet/class/project.class.php'; + + $projecttmp = new Project($db); + + $i = 0; + + while ($i < $num) { + $obj = $db->fetch_object($result); + $projecttmp->fetch($obj->id); + + // To verify role of users + $userAccess = $projecttmp->restrictedProjectArea($user); + + if ($user->rights->projet->lire && $userAccess > 0) { + print ''; + + // Ref + print ''; + + // Label + print ''; + print ''; + // Date start + print ''; + // Date end + print ''; + // Opp amount + print ''; + // Opp status + print ''; + // Opp percent + print ''; + // Status + print ''; + + print ''; + } + $i++; + } + } else { + print ''; + } + $db->free($result); + } else { + dol_print_error($db); + } + print "
    '.$langs->trans("Ref").''.$langs->trans("Name").''.$langs->trans("ContactType").''.$langs->trans("DateStart").''.$langs->trans("DateEnd").''.$langs->trans("OpportunityAmountShort").''.$langs->trans("OpportunityStatusShort").''.$langs->trans("OpportunityProbabilityShort").''.$langs->trans("Status").'
    '; + print $projecttmp->getNomUrl(1); + print ''.$obj->title.''.$obj->libelle.''.dol_print_date($db->jdate($obj->do), "day").''.dol_print_date($db->jdate($obj->de), "day").''; + if ($obj->opp_status_code) { + print price($obj->opp_amount, 1, '', 1, -1, -1, ''); + } + print ''; + if ($obj->opp_status_code) { + print $langs->trans("OppStatus".$obj->opp_status_code); + } + print ''; + if ($obj->opp_percent) { + print price($obj->opp_percent, 1, '', 1, 0).'%'; + } + print ''.$projecttmp->getLibStatut(5).'
    '.$langs->trans("None").'
    "; + print '
    '; + + print "
    \n"; + } + + return $i; +} diff --git a/htdocs/core/lib/cron.lib.php b/htdocs/core/lib/cron.lib.php index 5216ff554e4..b4c728fd611 100644 --- a/htdocs/core/lib/cron.lib.php +++ b/htdocs/core/lib/cron.lib.php @@ -100,10 +100,10 @@ function dol_print_cron_urls() print '
    '; print $langs->trans("URLToLaunchCronJobs").':
    '; $url = $urlwithroot.'/public/cron/cron_run_jobs_by_url.php?'.(empty($conf->global->CRON_KEY) ? '' : 'securitykey='.$conf->global->CRON_KEY.'&').'userlogin='.$user->login; - print img_picto('', 'globe').' '.$url."
    \n"; + print img_picto('', 'globe').' '.$url."
    \n"; print ' '.$langs->trans("OrToLaunchASpecificJob").'
    '; $url = $urlwithroot.'/public/cron/cron_run_jobs_by_url.php?'.(empty($conf->global->CRON_KEY) ? '' : 'securitykey='.$conf->global->CRON_KEY.'&').'userlogin='.$user->login.'&id=cronjobid'; - print img_picto('', 'globe').' '.$url."
    \n"; + print img_picto('', 'globe').' '.$url."
    \n"; print '
    '; print '
    '; diff --git a/htdocs/core/lib/date.lib.php b/htdocs/core/lib/date.lib.php index d4028e2196b..237adc9447a 100644 --- a/htdocs/core/lib/date.lib.php +++ b/htdocs/core/lib/date.lib.php @@ -357,18 +357,18 @@ function dolSqlDateFilter($datefield, $day_date, $month_date, $year_date, $exclu * Convert a string date into a GM Timestamps date * Warning: YYYY-MM-DDTHH:MM:SS+02:00 (RFC3339) is not supported. If parameter gm is 1, we will use no TZ, if not we will use TZ of server, not the one inside string. * - * @param string $string Date in a string - * YYYYMMDD - * YYYYMMDDHHMMSS - * YYYYMMDDTHHMMSSZ - * YYYY-MM-DDTHH:MM:SSZ (RFC3339) - * DD/MM/YY or DD/MM/YYYY (deprecated) - * DD/MM/YY HH:MM:SS or DD/MM/YYYY HH:MM:SS (deprecated) - * @param int $gm 1 =Input date is GM date, - * 0 =Input date is local date using PHP server timezone - * @return int Date as a timestamp - * 19700101020000 -> 7200 with gm=1 - * 19700101000000 -> 0 with gm=1 + * @param string $string Date in a string + * YYYYMMDD + * YYYYMMDDHHMMSS + * YYYYMMDDTHHMMSSZ + * YYYY-MM-DDTHH:MM:SSZ (RFC3339) + * DD/MM/YY or DD/MM/YYYY (deprecated) + * DD/MM/YY HH:MM:SS or DD/MM/YYYY HH:MM:SS (deprecated) + * @param int|string $gm 'gmt' or 1 =Input date is GM date, + * 'tzserver' or 0 =Input date is date using PHP server timezone + * @return int Date as a timestamp + * 19700101020000 -> 7200 with gm=1 + * 19700101000000 -> 0 with gm=1 * * @see dol_print_date(), dol_mktime(), dol_getdate() */ @@ -408,7 +408,14 @@ function dol_stringtotime($string, $gm = 1) $string = preg_replace('/([^0-9])/i', '', $string); $tmp = $string.'000000'; - $date = dol_mktime(substr($tmp, 8, 2), substr($tmp, 10, 2), substr($tmp, 12, 2), substr($tmp, 4, 2), substr($tmp, 6, 2), substr($tmp, 0, 4), ($gm ? 1 : 0)); + // Clean $gm + if ($gm === 1) { + $gm = 'gmt'; + } elseif (empty($gm) || $gm === 'tzserver') { + $gm = 'tzserver'; + } + + $date = dol_mktime(substr($tmp, 8, 2), substr($tmp, 10, 2), substr($tmp, 12, 2), substr($tmp, 4, 2), substr($tmp, 6, 2), substr($tmp, 0, 4), $gm); return $date; } diff --git a/htdocs/core/lib/doleditor.lib.php b/htdocs/core/lib/doleditor.lib.php index 79f38a8990a..fecf10f48fe 100644 --- a/htdocs/core/lib/doleditor.lib.php +++ b/htdocs/core/lib/doleditor.lib.php @@ -66,10 +66,6 @@ function show_skin($fuser, $edit = 0) // Title print ''.$langs->trans("DefaultSkin").''; print ''; - $url = 'http://ckeditor.com/addons/skins/all'; - /*print ''; - print $langs->trans('DownloadMoreSkins'); - print '';*/ print ''; print ''; diff --git a/htdocs/core/lib/files.lib.php b/htdocs/core/lib/files.lib.php index 2bd4ada3ad0..efde963d077 100644 --- a/htdocs/core/lib/files.lib.php +++ b/htdocs/core/lib/files.lib.php @@ -987,7 +987,7 @@ function dol_unescapefile($filename) */ function dolCheckVirus($src_file) { - global $conf; + global $conf, $db; if (!empty($conf->global->MAIN_ANTIVIRUS_COMMAND)) { if (!class_exists('AntiVir')) { @@ -2004,11 +2004,15 @@ function dol_compress_file($inputfile, $outputfile, $mode = "gz", &$errorstring // Skip directories (they would be added automatically) if (!$file->isDir()) { // Get real and relative path for current file - $filePath = $file->getRealPath(); - $relativePath = substr($filePath, strlen($rootPath) + 1); + $filePath = $file->getPath(); // the full path with filename using the $inputdir root. + $fileName = $file->getFilename(); + $fileFullRealPath = $file->getRealPath(); // the full path with name and transformed to use real path directory. + + //$relativePath = substr($fileFullRealPath, strlen($rootPath) + 1); + $relativePath = substr(($filePath ? $filePath.'/' : '').$fileName, strlen($rootPath) + 1); // Add current file to archive - $zip->addFile($filePath, $relativePath); + $zip->addFile($fileFullRealPath, $relativePath); } } @@ -2196,22 +2200,29 @@ function dol_compress_dir($inputdir, $outputfile, $mode = "zip", $excludefiles = } // Create recursive directory iterator + // This does not return symbolic links /** @var SplFileInfo[] $files */ $files = new RecursiveIteratorIterator( new RecursiveDirectoryIterator($inputdir), RecursiveIteratorIterator::LEAVES_ONLY ); + //var_dump($inputdir); foreach ($files as $name => $file) { // Skip directories (they would be added automatically) if (!$file->isDir()) { // Get real and relative path for current file - $filePath = $file->getRealPath(); - $relativePath = ($rootdirinzip ? $rootdirinzip.'/' : '').substr($filePath, strlen($inputdir) + 1); + $filePath = $file->getPath(); // the full path with filename using the $inputdir root. + $fileName = $file->getFilename(); + $fileFullRealPath = $file->getRealPath(); // the full path with name and transformed to use real path directory. - if (empty($excludefiles) || !preg_match($excludefiles, $filePath)) { + //$relativePath = ($rootdirinzip ? $rootdirinzip.'/' : '').substr($fileFullRealPath, strlen($inputdir) + 1); + $relativePath = ($rootdirinzip ? $rootdirinzip.'/' : '').substr(($filePath ? $filePath.'/' : '').$fileName, strlen($inputdir) + 1); + + //var_dump($filePath);var_dump($fileFullRealPath);var_dump($relativePath); + if (empty($excludefiles) || !preg_match($excludefiles, $fileFullRealPath)) { // Add current file to archive - $zip->addFile($filePath, $relativePath); + $zip->addFile($fileFullRealPath, $relativePath); } } } @@ -2259,13 +2270,13 @@ function dol_most_recent_file($dir, $regexfilter = '', $excludefilter = array('( /** * Security check when accessing to a document (used by document.php, viewimage.php and webservices to get documents). - * TODO Replace code that set $accesallowed by a call to restrictedArea() + * TODO Replace code that set $accessallowed by a call to restrictedArea() * * @param string $modulepart Module of document ('module', 'module_user_temp', 'module_user' or 'module_temp'). Exemple: 'medias', 'invoice', 'logs', 'tax-vat', ... * @param string $original_file Relative path with filename, relative to modulepart. * @param string $entity Restrict onto entity (0=no restriction) * @param User $fuser User object (forced) - * @param string $refname Ref of object to check permission for external users (autodetect if not provided) + * @param string $refname Ref of object to check permission for external users (autodetect if not provided) or for hierarchy * @param string $mode Check permission for 'read' or 'write' * @return mixed Array with access information : 'accessallowed' & 'sqlprotectagainstexternals' & 'original_file' (as a full path name) * @see restrictedArea() @@ -2337,15 +2348,15 @@ function dol_check_secure_access_document($modulepart, $original_file, $entity, $accessallowed = ($user->admin && basename($original_file) == $original_file && preg_match('/^dolibarr.*\.log$/', basename($original_file))); $original_file = $dolibarr_main_data_root.'/'.$original_file; } elseif ($modulepart == 'doctemplates' && !empty($dolibarr_main_data_root)) { - // Wrapping for *.log files, like when used with url http://.../document.php?modulepart=logs&file=dolibarr.log + // Wrapping for doctemplates $accessallowed = $user->admin; $original_file = $dolibarr_main_data_root.'/doctemplates/'.$original_file; } elseif ($modulepart == 'doctemplateswebsite' && !empty($dolibarr_main_data_root)) { - // Wrapping for *.zip files, like when used with url http://.../document.php?modulepart=packages&file=module_myfile.zip + // Wrapping for doctemplates of websites $accessallowed = ($fuser->rights->website->write && preg_match('/\.jpg$/i', basename($original_file))); $original_file = $dolibarr_main_data_root.'/doctemplates/websites/'.$original_file; } elseif ($modulepart == 'packages' && !empty($dolibarr_main_data_root)) { - // Wrapping for *.zip files, like when used with url http://.../document.php?modulepart=packages&file=module_myfile.zip + // Wrapping for *.zip package files, like when used with url http://.../document.php?modulepart=packages&file=module_myfile.zip // Dir for custom dirs $tmp = explode(',', $dolibarr_main_document_root_alt); $dirins = $tmp[0]; @@ -2358,11 +2369,21 @@ function dol_check_secure_access_document($modulepart, $original_file, $entity, $original_file = $conf->mycompany->dir_output.'/'.$original_file; } elseif ($modulepart == 'userphoto' && !empty($conf->user->dir_output)) { // Wrapping for users photos - $accessallowed = 1; + $accessallowed = 0; + if (preg_match('/^\d+\/photos\//', $original_file)) { + $accessallowed = 1; + } $original_file = $conf->user->dir_output.'/'.$original_file; + } elseif (($modulepart == 'companylogo') && !empty($conf->mycompany->dir_output)) { + // Wrapping for users logos + $accessallowed = 1; + $original_file = $conf->mycompany->dir_output.'/logos/'.$original_file; } elseif ($modulepart == 'memberphoto' && !empty($conf->adherent->dir_output)) { // Wrapping for members photos - $accessallowed = 1; + $accessallowed = 0; + if (preg_match('/^\d+\/photos\//', $original_file)) { + $accessallowed = 1; + } $original_file = $conf->adherent->dir_output.'/'.$original_file; } elseif ($modulepart == 'apercufacture' && !empty($conf->facture->multidir_output[$entity])) { // Wrapping pour les apercu factures @@ -2412,8 +2433,32 @@ function dol_check_secure_access_document($modulepart, $original_file, $entity, $accessallowed = 1; } $original_file = $conf->fournisseur->facture->dir_output.'/'.$original_file; + } elseif (($modulepart == 'holiday') && !empty($conf->holiday->dir_output)) { + if ($fuser->rights->holiday->{$read} || !empty($fuser->rights->holiday->readall) || preg_match('/^specimen/i', $original_file)) { + $accessallowed = 1; + // If we known $id of holiday, call checkUserAccessToObject to check permission on properties and hierarchy of leave request + if ($refname && empty($fuser->rights->holiday->readall) && !preg_match('/^specimen/i', $original_file)) { + include_once DOL_DOCUMENT_ROOT.'/holiday/class/holiday.class.php'; + $tmpholiday = new Holiday($db); + $tmpholiday->fetch('', $refname); + $accessallowed = checkUserAccessToObject($user, array('holiday'), $tmpholiday, 'holiday', '', '', 'rowid', ''); + } + } + $original_file = $conf->holiday->dir_output.'/'.$original_file; + } elseif (($modulepart == 'expensereport') && !empty($conf->expensereport->dir_output)) { + if ($fuser->rights->expensereport->{$lire} || !empty($fuser->rights->expensereport->readall) || preg_match('/^specimen/i', $original_file)) { + $accessallowed = 1; + // If we known $id of expensereport, call checkUserAccessToObject to check permission on properties and hierarchy of expense report + if ($refname && empty($fuser->rights->expensereport->readall) && !preg_match('/^specimen/i', $original_file)) { + include_once DOL_DOCUMENT_ROOT.'/expensereport/class/expensereport.class.php'; + $tmpexpensereport = new ExpenseReport($db); + $tmpexpensereport->fetch('', $refname); + $accessallowed = checkUserAccessToObject($user, array('expensereport'), $tmpexpensereport, 'expensereport', '', '', 'rowid', ''); + } + } + $original_file = $conf->expensereport->dir_output.'/'.$original_file; } elseif (($modulepart == 'apercuexpensereport') && !empty($conf->expensereport->dir_output)) { - // Wrapping pour les apercu supplier invoice + // Wrapping pour les apercu expense report if ($fuser->rights->expensereport->{$lire}) { $accessallowed = 1; } @@ -2498,7 +2543,7 @@ function dol_check_secure_access_document($modulepart, $original_file, $entity, if (empty($entity) || empty($conf->categorie->multidir_output[$entity])) { return array('accessallowed'=>0, 'error'=>'Value entity must be provided'); } - if ($fuser->rights->categorie->{$lire}) { + if ($fuser->rights->categorie->{$lire} || $fuser->rights->takepos->run) { $accessallowed = 1; } $original_file = $conf->categorie->multidir_output[$entity].'/'.$original_file; @@ -2675,7 +2720,7 @@ function dol_check_secure_access_document($modulepart, $original_file, $entity, include_once DOL_DOCUMENT_ROOT.'/projet/class/task.class.php'; $tmptask = new Task($db); $tmptask->fetch('', $refname); - $accessallowed = checkUserAccessToObject($user, array('projet_task'), $tmptask->id, 'projet&project', '', '', 'rowid', ''); + $accessallowed = checkUserAccessToObject($user, array('projet_task'), $tmptask->id, 'projet_task&project', '', '', 'rowid', ''); } } $original_file = $conf->projet->dir_output.'/'.$original_file; @@ -2960,9 +3005,9 @@ function dol_check_secure_access_document($modulepart, $original_file, $entity, } $ret = array( - 'accessallowed' => $accessallowed, - 'sqlprotectagainstexternals'=>$sqlprotectagainstexternals, - 'original_file'=>$original_file + 'accessallowed' => ($accessallowed ? 1 : 0), + 'sqlprotectagainstexternals' => $sqlprotectagainstexternals, + 'original_file' => $original_file ); return $ret; diff --git a/htdocs/core/lib/fourn.lib.php b/htdocs/core/lib/fourn.lib.php index efc9f60147c..683b4b49912 100644 --- a/htdocs/core/lib/fourn.lib.php +++ b/htdocs/core/lib/fourn.lib.php @@ -132,7 +132,7 @@ function facturefourn_prepare_head($object) * @param Object $object Object related to tabs * @return array Array of tabs to show */ -function ordersupplier_prepare_head($object) +function ordersupplier_prepare_head(CommandeFournisseur $object) { global $db, $langs, $conf, $user; @@ -159,6 +159,28 @@ function ordersupplier_prepare_head($object) $langs->load("stocks"); $head[$h][0] = DOL_URL_ROOT.'/fourn/commande/dispatch.php?id='.$object->id; $head[$h][1] = $langs->trans("OrderDispatch"); + + //If dispach process running we add the number of item to dispatch into the head + if (in_array($object->statut, array($object::STATUS_ORDERSENT, $object::STATUS_RECEIVED_PARTIALLY, $object::STATUS_RECEIVED_COMPLETELY))) { + $sumQtyAllreadyDispatched = 0; + $sumQtyOrdered = 0; + + if (empty($object->lines)) { + $object->fetch_lines(); + } + $nbLinesOrdered = count($object->lines); + $dispachedLines = $object->getDispachedLines(1); + $nbDispachedLines = count($dispachedLines); + + for ($line = 0 ; $line < $nbDispachedLines; $line++) { + $sumQtyAllreadyDispatched = $sumQtyAllreadyDispatched + $dispachedLines[$line]['qty']; + } + for ($line = 0 ; $line < $nbLinesOrdered; $line++) { + $sumQtyOrdered = $sumQtyOrdered + $object->lines[$line]->qty; + } + $head[$h][1] .= ''.price2num($sumQtyAllreadyDispatched, 'MS').' / '.price2num($sumQtyOrdered, 'MS').''; + } + $head[$h][2] = 'dispatch'; $h++; } diff --git a/htdocs/core/lib/functions.lib.php b/htdocs/core/lib/functions.lib.php index 22f59b0ed33..d8595c15bbf 100644 --- a/htdocs/core/lib/functions.lib.php +++ b/htdocs/core/lib/functions.lib.php @@ -17,6 +17,7 @@ * Copyright (C) 2019 Thibault Foucart * Copyright (C) 2020 Open-Dsi * Copyright (C) 2021 Gauthier VERDOL + * Copyright (C) 2022 Anthony Berton * * 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 @@ -106,7 +107,11 @@ function getDoliDBInstance($type, $host, $user, $pass, $name, $port) */ function getEntity($element, $shared = 1, $currentobject = null) { - global $conf, $mc, $hookmanager, $object, $action; + global $conf, $mc, $hookmanager, $object, $action, $db; + + if (! is_object($hookmanager)) { + $hookmanager = new HookManager($db); + } // fix different element names (France to English) switch ($element) { @@ -140,10 +145,10 @@ function getEntity($element, $shared = 1, $currentobject = null) $reshook = $hookmanager->executeHooks('hookGetEntity', $parameters, $currentobject, $action); // Note that $action and $object may have been modified by some hooks if (is_numeric($reshook)) { - if ($reshook == 0 && !empty($hookmanager->resprints)) { - $out .= ','.$hookmanager->resprints; // add + if ($reshook == 0 && !empty($hookmanager->resPrint)) { + $out .= ','.$hookmanager->resPrint; // add } elseif ($reshook == 1) { - $out = $hookmanager->resprints; // replace + $out = $hookmanager->resPrint; // replace } } @@ -348,12 +353,14 @@ function GETPOSTISSET($paramname) } } } - // If there is saved contextpage, page or limit + // If there is saved contextpage, limit, page or mode if ($paramname == 'contextpage' && !empty($_SESSION['lastsearch_contextpage_'.$relativepathstring])) { $isset = true; + } elseif ($paramname == 'limit' && !empty($_SESSION['lastsearch_limit_'.$relativepathstring])) { + $isset = true; } elseif ($paramname == 'page' && !empty($_SESSION['lastsearch_page_'.$relativepathstring])) { $isset = true; - } elseif ($paramname == 'limit' && !empty($_SESSION['lastsearch_limit_'.$relativepathstring])) { + } elseif ($paramname == 'mode' && !empty($_SESSION['lastsearch_mode_'.$relativepathstring])) { $isset = true; } } else { @@ -443,10 +450,12 @@ function GETPOST($paramname, $check = 'alphanohtml', $method = 0, $filter = null // If there is saved contextpage, page or limit if ($paramname == 'contextpage' && !empty($_SESSION['lastsearch_contextpage_'.$relativepathstring])) { $out = $_SESSION['lastsearch_contextpage_'.$relativepathstring]; - } elseif ($paramname == 'page' && !empty($_SESSION['lastsearch_page_'.$relativepathstring])) { - $out = $_SESSION['lastsearch_page_'.$relativepathstring]; } elseif ($paramname == 'limit' && !empty($_SESSION['lastsearch_limit_'.$relativepathstring])) { $out = $_SESSION['lastsearch_limit_'.$relativepathstring]; + } elseif ($paramname == 'page' && !empty($_SESSION['lastsearch_page_'.$relativepathstring])) { + $out = $_SESSION['lastsearch_page_'.$relativepathstring]; + } elseif ($paramname == 'mode' && !empty($_SESSION['lastsearch_mode_'.$relativepathstring])) { + $out = $_SESSION['lastsearch_mode_'.$relativepathstring]; } } elseif (!isset($_GET['sortfield'])) { // Else, retrieve default values if we are not doing a sort @@ -637,7 +646,7 @@ function GETPOST($paramname, $check = 'alphanohtml', $method = 0, $filter = null } // Check rule - if (preg_match('/^array/', $check)) { // If 'array' or 'array:restricthtml' or 'array:aZ09' + if (preg_match('/^array/', $check)) { // If 'array' or 'array:restricthtml' or 'array:aZ09' or 'array:intcomma' if (!is_array($out) || empty($out)) { $out = array(); } else { @@ -656,16 +665,16 @@ function GETPOST($paramname, $check = 'alphanohtml', $method = 0, $filter = null } // Sanitizing for special parameters. - // Note: There is no reason to allow the backtopage, backtolist or backtourl parameter to contains an external URL. + // Note: There is no reason to allow the backtopage, backtolist or backtourl parameter to contains an external URL. Only relative URLs are allowed. if ($paramname == 'backtopage' || $paramname == 'backtolist' || $paramname == 'backtourl') { - $out = str_replace('\\', '/', $out); // Can be before the loop because only 1 char is replaced. No risk to get it after other replacements. - $out = str_replace(array(':', ';', '@'), '', $out); // Can be before the loop because only 1 char is replaced. No risk to get it after other replacements. + $out = str_replace('\\', '/', $out); // Can be before the loop because only 1 char is replaced. No risk to get it after other replacements. + $out = str_replace(array(':', ';', '@', "\t", ' '), '', $out); // Can be before the loop because only 1 char is replaced. No risk to retreive it after other replacements. do { $oldstringtoclean = $out; $out = str_ireplace(array('javascript', 'vbscript', '&colon', '&#'), '', $out); + $out = preg_replace(array('/^[^\?]*%/'), '', $out); // We remove any % chars before the ?. Example in url: '/product/stock/card.php?action=create&backtopage=%2Fdolibarr_dev%2Fhtdocs%2Fpro%25duct%2Fcard.php%3Fid%3Dabc' + $out = preg_replace(array('/^[a-z]*\/\s*\/+/i'), '', $out); // We remove schema*// to remove external URL } while ($oldstringtoclean != $out); - - $out = preg_replace(array('/^[a-z]*\/\/+/i'), '', $out); // We remove schema*// to remove external URL } // Code for search criteria persistence. @@ -704,11 +713,11 @@ function GETPOSTINT($paramname, $method = 0) /** * Return a value after checking on a rule. A sanitization may also have been done. * - * @param string $out Value to check/clear. - * @param string $check Type of check/sanitizing - * @param int $filter Filter to apply when $check is set to 'custom'. (See http://php.net/manual/en/filter.filters.php for détails) - * @param mixed $options Options to pass to filter_var when $check is set to 'custom' - * @return string|array Value sanitized (string or array). It may be '' if format check fails. + * @param string|array $out Value to check/clear. + * @param string $check Type of check/sanitizing + * @param int $filter Filter to apply when $check is set to 'custom'. (See http://php.net/manual/en/filter.filters.php for détails) + * @param mixed $options Options to pass to filter_var when $check is set to 'custom' + * @return string|array Value sanitized (string or array). It may be '' if format check fails. */ function checkVal($out = '', $check = 'alphanohtml', $filter = null, $options = null) { @@ -778,7 +787,7 @@ function checkVal($out = '', $check = 'alphanohtml', $filter = null, $options = // keep lines feed } break; - case 'alphawithlgt': // No " and no ../ but we keep balanced < > tags with no special chars inside. Can be used for email string like "Name " + case 'alphawithlgt': // No " and no ../ but we keep balanced < > tags with no special chars inside. Can be used for email string like "Name ". Less secured than 'alphanohtml' if (!is_array($out)) { $out = trim($out); do { @@ -824,17 +833,20 @@ function checkVal($out = '', $check = 'alphanohtml', $filter = null, $options = // We replace chars from a/A to z/Z encoded with numeric HTML entities with the real char so we won't loose the chars at the next step (preg_replace). // No need to use a loop here, this step is not to sanitize (this is done at next step, this is to try to save chars, even if they are // using a non coventionnel way to be encoded, to not have them sanitized just after) - $out = preg_replace_callback('/&#(x?[0-9][0-9a-f]+;?)/i', 'realCharForNumericEntities', $out); + //$out = preg_replace_callback('/&#(x?[0-9][0-9a-f]+;?)/i', 'realCharForNumericEntities', $out); + $out = preg_replace_callback('/&#(x?[0-9][0-9a-f]+;?)/i', function ($m) { + return realCharForNumericEntities($m); }, $out); + // Now we remove all remaining HTML entities starting with a number. We don't want such entities. $out = preg_replace('/&#x?[0-9]+/i', '', $out); // For example if we have javascript with an entities without the ; to hide the 'a' of 'javascript'. $out = dol_string_onlythesehtmltags($out, 0, 1, 1); - // We should also exclude non expected attributes + // We should also exclude non expected HTML attributes and clean content of some attributes. if (!empty($conf->global->MAIN_RESTRICTHTML_REMOVE_ALSO_BAD_ATTRIBUTES)) { // Warning, the function may add a LF so we are forced to trim to compare with old $out without having always a difference and an infinit loop. - $out = trim(dol_string_onlythesehtmlattributes($out)); + $out = dol_string_onlythesehtmlattributes($out); } // Restore entity ' into ' (restricthtml is for html content so we can use html entity) @@ -858,31 +870,32 @@ if (!function_exists('dol_getprefix')) { * Return a prefix to use for this Dolibarr instance, for session/cookie names or email id. * The prefix is unique for instance and avoid conflict between multi-instances, even when having two instances with same root dir * or two instances in same virtual servers. + * This function must not use dol_hash (that is used for password hash) and need to have all context $conf loaded. * * @param string $mode '' (prefix for session name) or 'email' (prefix for email id) * @return string A calculated prefix */ function dol_getprefix($mode = '') { - // If prefix is for email (we need to have $conf alreayd loaded for this case) + // If prefix is for email (we need to have $conf already loaded for this case) if ($mode == 'email') { global $conf; - if (!empty($conf->global->MAIL_PREFIX_FOR_EMAIL_ID)) { // If MAIL_PREFIX_FOR_EMAIL_ID is set (a value initialized with a random value is recommended) + if (!empty($conf->global->MAIL_PREFIX_FOR_EMAIL_ID)) { // If MAIL_PREFIX_FOR_EMAIL_ID is set if ($conf->global->MAIL_PREFIX_FOR_EMAIL_ID != 'SERVER_NAME') { return $conf->global->MAIL_PREFIX_FOR_EMAIL_ID; - } elseif (isset($_SERVER["SERVER_NAME"])) { + } elseif (isset($_SERVER["SERVER_NAME"])) { // If MAIL_PREFIX_FOR_EMAIL_ID is set to 'SERVER_NAME' return $_SERVER["SERVER_NAME"]; } } - // The recommended value (may be not defined for old versions) + // The recommended value if MAIL_PREFIX_FOR_EMAIL_ID is not defined (may be not defined for old versions) if (!empty($conf->file->instance_unique_id)) { - return $conf->file->instance_unique_id; + return sha1('dolibarr'.$conf->file->instance_unique_id); } - // For backward compatibility - return dol_hash(DOL_DOCUMENT_ROOT.DOL_URL_ROOT, '3'); + // For backward compatibility when instance_unique_id is not set + return sha1(DOL_DOCUMENT_ROOT.DOL_URL_ROOT); } // If prefix is for session (no need to have $conf loaded) @@ -891,15 +904,15 @@ if (!function_exists('dol_getprefix')) { // The recommended value (may be not defined for old versions) if (!empty($tmp_instance_unique_id)) { - return $tmp_instance_unique_id; + return sha1('dolibarr'.$tmp_instance_unique_id); } - // For backward compatibility + // For backward compatibility when instance_unique_id is not set if (isset($_SERVER["SERVER_NAME"]) && isset($_SERVER["DOCUMENT_ROOT"])) { - return dol_hash($_SERVER["SERVER_NAME"].$_SERVER["DOCUMENT_ROOT"].DOL_DOCUMENT_ROOT.DOL_URL_ROOT, '3'); + return sha1($_SERVER["SERVER_NAME"].$_SERVER["DOCUMENT_ROOT"].DOL_DOCUMENT_ROOT.DOL_URL_ROOT); + } else { + return sha1(DOL_DOCUMENT_ROOT.DOL_URL_ROOT); } - - return dol_hash(DOL_DOCUMENT_ROOT.DOL_URL_ROOT, '3'); } } @@ -1092,6 +1105,7 @@ function dol_sanitizeFileName($str, $newstr = '_', $unaccent = 1) $tmp = dol_string_nospecial($unaccent ? dol_string_unaccent($str) : $str, $newstr, $filesystem_forbidden_chars); $tmp = preg_replace('/\-\-+/', '_', $tmp); $tmp = preg_replace('/\s+\-([^\s])/', ' _$1', $tmp); + $tmp = str_replace('..', '', $tmp); return $tmp; } @@ -1115,6 +1129,7 @@ function dol_sanitizePathName($str, $newstr = '_', $unaccent = 1) $tmp = dol_string_nospecial($unaccent ? dol_string_unaccent($str) : $str, $newstr, $filesystem_forbidden_chars); $tmp = preg_replace('/\-\-+/', '_', $tmp); $tmp = preg_replace('/\s+\-([^\s])/', ' _$1', $tmp); + $tmp = str_replace('..', '', $tmp); return $tmp; } @@ -1165,23 +1180,34 @@ function dol_sanitizeUrl($stringtoclean, $type = 1) */ function dol_string_unaccent($str) { + global $conf; + if (utf8_check($str)) { + if (extension_loaded('intl') && !empty($conf->global->MAIN_UNACCENT_USE_TRANSLITERATOR)) { + $transliterator = \Transliterator::createFromRules(':: Any-Latin; :: Latin-ASCII; :: NFD; :: [:Nonspacing Mark:] Remove; :: NFC;', \Transliterator::FORWARD); + return $transliterator->transliterate($str); + } // See http://www.utf8-chartable.de/ $string = rawurlencode($str); $replacements = array( '%C3%80' => 'A', '%C3%81' => 'A', '%C3%82' => 'A', '%C3%83' => 'A', '%C3%84' => 'A', '%C3%85' => 'A', + '%C3%87' => 'C', '%C3%88' => 'E', '%C3%89' => 'E', '%C3%8A' => 'E', '%C3%8B' => 'E', '%C3%8C' => 'I', '%C3%8D' => 'I', '%C3%8E' => 'I', '%C3%8F' => 'I', + '%C3%91' => 'N', '%C3%92' => 'O', '%C3%93' => 'O', '%C3%94' => 'O', '%C3%95' => 'O', '%C3%96' => 'O', + '%C5%A0' => 'S', '%C3%99' => 'U', '%C3%9A' => 'U', '%C3%9B' => 'U', '%C3%9C' => 'U', + '%C3%9D' => 'Y', '%C5%B8' => 'y', '%C3%A0' => 'a', '%C3%A1' => 'a', '%C3%A2' => 'a', '%C3%A3' => 'a', '%C3%A4' => 'a', '%C3%A5' => 'a', '%C3%A7' => 'c', '%C3%A8' => 'e', '%C3%A9' => 'e', '%C3%AA' => 'e', '%C3%AB' => 'e', '%C3%AC' => 'i', '%C3%AD' => 'i', '%C3%AE' => 'i', '%C3%AF' => 'i', '%C3%B1' => 'n', '%C3%B2' => 'o', '%C3%B3' => 'o', '%C3%B4' => 'o', '%C3%B5' => 'o', '%C3%B6' => 'o', + '%C5%A1' => 's', '%C3%B9' => 'u', '%C3%BA' => 'u', '%C3%BB' => 'u', '%C3%BC' => 'u', - '%C3%BF' => 'y' + '%C3%BD' => 'y', '%C3%BF' => 'y' ); $string = strtr($string, $replacements); return rawurldecode($string); @@ -1213,8 +1239,8 @@ function dol_string_unaccent($str) * * @param string $str String to clean * @param string $newstr String to replace forbidden chars with - * @param array|string $badcharstoreplace List of forbidden characters to replace - * @param array|string $badcharstoremove List of forbidden characters to remove + * @param array|string $badcharstoreplace Array of forbidden characters to replace. Use '' to keep default list. + * @param array|string $badcharstoremove Array of forbidden characters to remove. Use '' to keep default list. * @return string Cleaned string * * @see dol_sanitizeFilename(), dol_string_unaccent(), dol_string_nounprintableascii() @@ -1526,6 +1552,7 @@ function dol_syslog($message, $level = LOG_INFO, $ident = 0, $suffixinfilename = // This is when PHP session is ran outside a web server, like from Linux command line (Not always defined, but usefull if OS defined it). $data['ip'] = '???@'.$_SERVER['LOGNAME']; } + // Loop on each log handler and send output foreach ($conf->loghandlers as $loghandlerinstance) { if ($restricttologhandler && $loghandlerinstance->code != $restricttologhandler) { @@ -1565,7 +1592,7 @@ function dolButtonToOpenUrlInDialogPopup($name, $label, $buttonstring, $url, $di //print ''; $out = ''.$buttonstring.''; $out .= ''; - $out .= ''; if ($addlink) { if ($textonlink === 'image') { - $out .= ' '.img_picto('', 'globe').''; + $out .= ' '.img_picto('', 'globe').''; } else { - $out .= ' '.$langs->trans("Link").''; + $out .= ' '.$langs->trans("Link").''; } } return $out; @@ -9170,7 +9421,7 @@ function dolIsAllowedForPreview($file) /** - * Return mime type of a file + * Return MIME type of a file from its name with extension. * * @param string $file Filename we looking for MIME type * @param string $default Default mime type if extension not found in known list @@ -10040,7 +10291,7 @@ function dolGetButtonTitle($label, $helpText = '', $iconClass = 'fa fa-file', $u } $class = 'btnTitle'; - if (in_array($iconClass, array('fa fa-plus-circle', 'fa fa-comment-dots'))) { + if (in_array($iconClass, array('fa fa-plus-circle', 'fa fa-plus-circle size15x', 'fa fa-comment-dots'))) { $class .= ' btnTitlePlus'; } $useclassfortooltip = 1; @@ -10310,6 +10561,7 @@ function newToken() /** * Return the value of token currently saved into session with name 'token'. + * For ajax call, you must use this token as a parameter of the call into the js calling script (the called ajax php page must also set constant NOTOKENRENEWAL). * * @return string */ @@ -10546,3 +10798,93 @@ function jsonOrUnserialize($stringtodecode) return $result; } + + + +/** + * Return if a $sqlfilters parameter is valid and will pass the preg_replace_callback() to replace Generic filter string with SQL filter string + * Example of usage: + * if ($sqlfilters) { + * $errormessage = ''; + * if (dolCheckFilters($sqlfilters, $errormessage)) { + * $regexstring = '\(([^:\'\(\)]+:[^:\'\(\)]+:[^\(\)]+)\)'; + * $sql .= " AND (".preg_replace_callback('/'.$regexstring.'/', 'dolForgeCriteriaCallback', $sqlfilters).")"; + * } + * } + * + * @param string $sqlfilters sqlfilter string + * @param string $error Error message + * @return boolean True if valid, False if not valid ($error is filled with the reason in such a case) + */ +function dolCheckFilters($sqlfilters, &$error = '') +{ + //$regexstring='\(([^:\'\(\)]+:[^:\'\(\)]+:[^:\(\)]+)\)'; + //$tmp=preg_replace_all('/'.$regexstring.'/', '', $sqlfilters); + $tmp = $sqlfilters; + $i = 0; $nb = strlen($tmp); + $counter = 0; + while ($i < $nb) { + if ($tmp[$i] == '(') { + $counter++; + } + if ($tmp[$i] == ')') { + $counter--; + } + if ($counter < 0) { + $error = "Bad sqlfilters=".$sqlfilters; + dol_syslog($error, LOG_WARNING); + return false; + } + $i++; + } + return true; +} + +/** + * Function to forge a SQL criteria from a Generic filter string. + * Example of usage: + * if ($sqlfilters) { + * $errormessage = ''; + * if (dolCheckFilters($sqlfilters, $errormessage)) { + * $regexstring = '\(([^:\'\(\)]+:[^:\'\(\)]+:[^\(\)]+)\)'; + * $sql .= " AND (".preg_replace_callback('/'.$regexstring.'/', 'dolForgeCriteriaCallback', $sqlfilters).")"; + * } + * } + * + * @param array $matches Array of found string by regex search. + * Example: "t.ref:like:'SO-%'" or "t.date_creation:<:'20160101'" or "t.date_creation:<:'2016-01-01 12:30:00'" or "t.nature:is:NULL" + * @return string Forged criteria. Example: "t.field like 'abc%'" + */ +function dolForgeCriteriaCallback($matches) +{ + global $db; + + dol_syslog("Convert matches ".$matches[1]); + if (empty($matches[1])) { + return ''; + } + $tmp = explode(':', $matches[1], 3); + + if (count($tmp) < 3) { + return ''; + } + + $operand = preg_replace('/[^a-z0-9\._]/i', '', trim($tmp[0])); + + $operator = strtoupper(preg_replace('/[^a-z<>=]/i', '', trim($tmp[1]))); + if ($operator == 'NOTLIKE') { + $operator = 'NOT LIKE'; + } + + $tmpescaped = trim($tmp[2]); + $regbis = array(); + if ($operator == 'IN') { + $tmpescaped = "(".$db->sanitize($tmpescaped, 1).")"; + } elseif (preg_match('/^\'(.*)\'$/', $tmpescaped, $regbis)) { + $tmpescaped = "'".$db->escape($regbis[1])."'"; + } else { + $tmpescaped = $db->sanitize($db->escape($tmpescaped)); + } + + return $db->escape($operand).' '.$db->escape($operator)." ".$tmpescaped; +} diff --git a/htdocs/core/lib/functions2.lib.php b/htdocs/core/lib/functions2.lib.php index 26c56d45463..3a0b077be6b 100644 --- a/htdocs/core/lib/functions2.lib.php +++ b/htdocs/core/lib/functions2.lib.php @@ -1368,6 +1368,7 @@ function get_next_value($db, $mask, $table, $field, $where = '', $objsoc = '', $ $numFinal = $ref; } elseif ($mode == 'next') { $counter++; + $maskrefclient_counter = 0; // If value for $counter has a length higher than $maskcounter chars if ($counter >= pow(10, dol_strlen($maskcounter))) { @@ -1398,7 +1399,6 @@ function get_next_value($db, $mask, $table, $field, $where = '', $objsoc = '', $ $maskrefclient_maskLike = str_replace(dol_string_nospecial('{'.$maskrefclient.'}'), $maskrefclient_clientcode.str_pad("", dol_strlen($maskrefclient_maskcounter), "_"), $maskrefclient_maskLike); // Get counter in database - $maskrefclient_counter = 0; $maskrefclient_sql = "SELECT MAX(".$maskrefclient_sqlstring.") as val"; $maskrefclient_sql .= " FROM ".MAIN_DB_PREFIX.$table; //$sql.= " WHERE ".$field." not like '(%'"; @@ -2131,30 +2131,38 @@ function dolGetElementUrl($objectid, $objecttype, $withpicto = 0, $option = '') // Special cases, to work with non standard path if ($objecttype == 'facture' || $objecttype == 'invoice') { + $langs->load('bills'); $classpath = 'compta/facture/class'; $module = 'facture'; $myobject = 'facture'; } elseif ($objecttype == 'commande' || $objecttype == 'order') { + $langs->load('orders'); $classpath = 'commande/class'; $module = 'commande'; $myobject = 'commande'; } elseif ($objecttype == 'propal') { + $langs->load('propal'); $classpath = 'comm/propal/class'; } elseif ($objecttype == 'supplier_proposal') { + $langs->load('supplier_proposal'); $classpath = 'supplier_proposal/class'; } elseif ($objecttype == 'shipping') { + $langs->load('sendings'); $classpath = 'expedition/class'; $myobject = 'expedition'; $module = 'expedition_bon'; } elseif ($objecttype == 'delivery') { + $langs->load('deliveries'); $classpath = 'delivery/class'; $myobject = 'delivery'; $module = 'delivery_note'; } elseif ($objecttype == 'contract') { + $langs->load('contracts'); $classpath = 'contrat/class'; $module = 'contrat'; $myobject = 'contrat'; } elseif ($objecttype == 'member') { + $langs->load('members'); $classpath = 'adherents/class'; $module = 'adherent'; $myobject = 'adherent'; @@ -2163,13 +2171,16 @@ function dolGetElementUrl($objectid, $objecttype, $withpicto = 0, $option = '') $module = 'cabinetmed'; $myobject = 'cabinetmedcons'; } elseif ($objecttype == 'fichinter') { + $langs->load('interventions'); $classpath = 'fichinter/class'; $module = 'ficheinter'; $myobject = 'fichinter'; } elseif ($objecttype == 'project') { + $langs->load('projects'); $classpath = 'projet/class'; $module = 'projet'; } elseif ($objecttype == 'task') { + $langs->load('projects'); $classpath = 'projet/class'; $module = 'projet'; $myobject = 'task'; diff --git a/htdocs/core/lib/geturl.lib.php b/htdocs/core/lib/geturl.lib.php index 3398189a771..64cc4388718 100644 --- a/htdocs/core/lib/geturl.lib.php +++ b/htdocs/core/lib/geturl.lib.php @@ -35,9 +35,10 @@ * @param string[] $addheaders Array of string to add into header. Example: ('Accept: application/xrds+xml', ....) * @param string[] $allowedschemes List of schemes that are allowed ('http' + 'https' only by default) * @param int $localurl 0=Only external URL are possible, 1=Only local URL, 2=Both external and local URL are allowed. - * @return array Returns an associative array containing the response from the server array('content'=>response, 'curl_error_no'=>errno, 'curl_error_msg'=>errmsg...) + * @param int $ssl_verifypeer -1=Auto (no ssl check on dev, check on prod), 0=No ssl check, 1=Always ssl check + * @return array Returns an associative array containing the response from the server array('http_code'=>http response code, 'content'=>response, 'curl_error_no'=>errno, 'curl_error_msg'=>errmsg...) */ -function getURLContent($url, $postorget = 'GET', $param = '', $followlocation = 1, $addheaders = array(), $allowedschemes = array('http', 'https'), $localurl = 0) +function getURLContent($url, $postorget = 'GET', $param = '', $followlocation = 1, $addheaders = array(), $allowedschemes = array('http', 'https'), $localurl = 0, $ssl_verifypeer = -1) { //declaring of global variables global $conf; @@ -75,9 +76,18 @@ function getURLContent($url, $postorget = 'GET', $param = '', $followlocation = } //curl_setopt($ch, CURLOPT_SSLVERSION, 6); for tls 1.2 + // Turning on or off the ssl target certificate + if ($ssl_verifypeer < 0) { + global $dolibarr_main_prod; + $ssl_verifypeer = ($dolibarr_main_prod ? true : false); + } + if (!empty($conf->global->MAIN_CURL_DISABLE_VERIFYPEER)) { + $ssl_verifypeer = 0; + } + // Turning off the server and peer verification(TrustManager Concept). - curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false); - curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false); + curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, ($ssl_verifypeer ? true : false)); + curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, ($ssl_verifypeer ? true : false)); // Restrict use to some protocols only $protocols = 0; @@ -214,11 +224,21 @@ function getURLContent($url, $postorget = 'GET', $param = '', $followlocation = } } - // Common check (local and external) - if (in_array($iptocheck, array('100.100.100.200'))) { - $info['http_code'] = 400; - $info['content'] = 'Error bad hostname IP (Used by Alibaba metadata). Must be an external URL.'; - break; + // Common check on ip (local and external) + // See list on https://tagmerge.com/gist/a7b9d57ff8ec11d63642f8778609a0b8 + // Not evasive url that ar enot IP are excluded by test on IP v4/v6 validity. + $arrayofmetadataserver = array( + '100.100.100.200' => 'Alibaba', + '192.0.0.192' => 'Oracle', + '192.80.8.124' => 'Packet', + '100.88.222.5' => 'Tencent cloud', + ); + foreach ($arrayofmetadataserver as $ipofmetadataserver => $nameofmetadataserver) { + if ($iptocheck == $ipofmetadataserver) { + $info['http_code'] = 400; + $info['content'] = 'Error bad hostname IP (Used by '.$nameofmetadataserver.' metadata server). This IP is forbidden.'; + break 2; // exit the foreach and the do... + } } // Set CURLOPT_CONNECT_TO so curl will not try another resolution that may give a different result. Possible only on PHP v7+ @@ -249,7 +269,10 @@ function getURLContent($url, $postorget = 'GET', $param = '', $followlocation = $request = curl_getinfo($ch, CURLINFO_HEADER_OUT); // Reading of request must be done after sending request dol_syslog("getURLContent request=".$request); - //dol_syslog("getURLContent response =".response); // This may contains binary data, so we dont output it + if (!empty($conf->global->MAIN_GETURLCONTENT_OUTPUT_RESPONSE)) { + // This may contains binary data, so we dont output reponse by default. + dol_syslog("getURLContent response =".$response); + } dol_syslog("getURLContent response size=".strlen($response)); // This may contains binary data, so we dont output it $rep = array(); diff --git a/htdocs/core/lib/images.lib.php b/htdocs/core/lib/images.lib.php index 0ccb6a415fc..6b973d89887 100644 --- a/htdocs/core/lib/images.lib.php +++ b/htdocs/core/lib/images.lib.php @@ -388,7 +388,7 @@ function dolRotateImage($file_path) * Add exif orientation correction for image * * @param string $fileSource Full path to source image to rotate - * @param string $fileDest string : Full path to image to rotate | false return gd img | null the raw image stream will be outputted directly + * @param string|bool $fileDest string : Full path to image to rotate | false return gd img | null the raw image stream will be outputted directly * @param int $quality output image quality * @return bool : true on success or false on failure or gd img if $fileDest is false. */ @@ -630,7 +630,7 @@ function vignette($file, $maxWidth = 160, $maxHeight = 120, $extName = '_small', } // replace image with good orientation - if (!empty($rotated)) { + if (!empty($rotated) && isset($trueImgWidth) && isset($trueImgHeight)) { $img = $rotated; $imgWidth = $trueImgWidth; $imgHeight = $trueImgHeight; diff --git a/htdocs/core/lib/invoice.lib.php b/htdocs/core/lib/invoice.lib.php index 8b61a690910..c6f972f46c8 100644 --- a/htdocs/core/lib/invoice.lib.php +++ b/htdocs/core/lib/invoice.lib.php @@ -200,7 +200,7 @@ function invoice_rec_prepare_head($object) $h = 0; $head = array(); - $head[$h][0] = DOL_URL_ROOT.'/compta/facture/card-rec.php?id='.$object->id; + $head[$h][0] = DOL_URL_ROOT . '/compta/facture/card-rec.php?id=' . $object->id; $head[$h][1] = $langs->trans("RepeatableInvoice"); $head[$h][2] = 'card'; $h++; @@ -216,6 +216,35 @@ function invoice_rec_prepare_head($object) return $head; } +/** + * Return array head with list of tabs to view object informations. + * + * @param Facture $object Invoice object + * @return array head array with tabs + */ +function supplier_invoice_rec_prepare_head($object) +{ + global $db, $langs, $conf; + + $h = 0; + $head = array(); + + $head[$h][0] = DOL_URL_ROOT . '/fourn/facture/card-rec.php?id=' . $object->id; + $head[$h][1] = $langs->trans("RepeatableSupplierInvoice"); + $head[$h][2] = 'card'; + $h++; + + // Show more tabs from modules + // Entries must be declared in modules descriptor with line + // $this->tabs = array('entity:+tabname:Title:@mymodule:/mymodule/mypage.php?id=__ID__'); to add new tab + // $this->tabs = array('entity:-tabname); to remove a tab + complete_head_from_modules($conf, $langs, $object, $head, $h, 'invoice_supplier_rec'); + + complete_head_from_modules($conf, $langs, $object, $head, $h, 'invoice_supplier_rec', 'remove'); + + return $head; +} + /** * Return a HTML table that contains a pie chart of customer invoices * @@ -509,12 +538,14 @@ function getNumberInvoicesPieChart($mode) while ($i < $num) { $obj = $db->fetch_object($resql); - /*$dataseries = array(array($langs->trans('InvoiceLate30Days'), $obj->nblate30) + /* + $dataseries = array(array($langs->trans('InvoiceLate30Days'), $obj->nblate30) ,array($langs->trans('InvoiceLate15Days'), $obj->nblate15 - $obj->nblate30) ,array($langs->trans('InvoiceLateMinus15Days'), $obj->nblatenow - $obj->nblate15) ,array($langs->trans('InvoiceNotLate'), $obj->nbnotlatenow - $obj->nbnotlate15) ,array($langs->trans('InvoiceNotLate15Days'), $obj->nbnotlate15 - $obj->nbnotlate30) - ,array($langs->trans('InvoiceNotLate30Days'), $obj->nbnotlate30));*/ + ,array($langs->trans('InvoiceNotLate30Days'), $obj->nbnotlate30)); + */ $dataseries[$i]=array($langs->trans('NbOfOpenInvoices'), $obj->nblate30, $obj->nblate15 - $obj->nblate30, $obj->nblatenow - $obj->nblate15, $obj->nbnotlatenow - $obj->nbnotlate15, $obj->nbnotlate15 - $obj->nbnotlate30, $obj->nbnotlate30); $i++; } @@ -561,8 +592,9 @@ function getNumberInvoicesPieChart($mode) $dolgraph->setShowLegend(2); $dolgraph->setShowPercent(1); $dolgraph->SetType(array('bars', 'bars', 'bars', 'bars', 'bars', 'bars')); - $dolgraph->setHeight('160'); - $dolgraph->setWidth('400'); + //$dolgraph->SetType(array('pie')); + $dolgraph->setHeight('160'); /* 160 min is required to show the 6 lines of legend */ + $dolgraph->setWidth('450'); $dolgraph->setHideXValues(true); if ($mode == 'customers') { $dolgraph->draw('idgraphcustomerinvoices'); @@ -1193,11 +1225,6 @@ function getCustomerInvoiceUnpaidOpenTable($maxCount = 500, $socid = 0) print ''; print $tmpinvoice->getNomUrl(1, ''); print ''; - print ''; - if ($tmpinvoice->hasDelay()) { - print img_warning($langs->trans("Late")); - } - print ''; print ''; $filename = dol_sanitizeFileName($obj->ref); $filedir = $conf->facture->dir_output.'/'.dol_sanitizeFileName($obj->ref); @@ -1209,7 +1236,12 @@ function getCustomerInvoiceUnpaidOpenTable($maxCount = 500, $socid = 0) print ''; print $societestatic->getNomUrl(1, 'customer'); print ''; - print ''.dol_print_date($db->jdate($obj->datelimite), 'day').''; + print ''; + print dol_print_date($db->jdate($obj->datelimite), 'day'); + if ($tmpinvoice->hasDelay()) { + print img_warning($langs->trans("Late")); + } + print ''; if (!empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) { print ''.price($obj->total_ht).''; } diff --git a/htdocs/core/lib/ldap.lib.php b/htdocs/core/lib/ldap.lib.php index 9d6e0193108..56a8bcc4285 100644 --- a/htdocs/core/lib/ldap.lib.php +++ b/htdocs/core/lib/ldap.lib.php @@ -1,6 +1,6 @@ - * Copyright (C) 2006-2017 Regis Houssin + * Copyright (C) 2006-2021 Regis Houssin * * 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 @@ -89,7 +89,6 @@ function ldap_prepare_head() return $head; } - /** * Show button test LDAP synchro * @@ -119,7 +118,6 @@ function show_ldap_test_button($butlabel, $testlabel, $key, $dn, $objectclass) print '

    '; } - /** * Show a LDAP array into an HTML output array. * @@ -153,7 +151,7 @@ function show_ldap_content($result, $level, $count, $var, $hide = 0, $subcount = if ("$key" == "dn") { continue; } - if ("$val" == "objectclass") { + if (!is_array($val) && "$val" == "objectclass") { continue; } @@ -181,7 +179,7 @@ function show_ldap_content($result, $level, $count, $var, $hide = 0, $subcount = } print '
    '; } - if ("$val" != $lastkey[$level] && !$subcount) { + if (!is_array($val) && "$val" != $lastkey[$level] && !$subcount) { print ''; } } diff --git a/htdocs/core/lib/memory.lib.php b/htdocs/core/lib/memory.lib.php index 557bbe6dcf5..0c056ddbc2e 100644 --- a/htdocs/core/lib/memory.lib.php +++ b/htdocs/core/lib/memory.lib.php @@ -93,7 +93,7 @@ function dol_setcache($memoryid, $data, $expire = 0) $dolmemcache->add($memoryid, $data, $expire); // This fails if key already exists $rescode = $dolmemcache->getResultCode(); if ($rescode == 0) { - return is_countable($data) ? count($data) : 0; + return is_array($data) ? count($data) : (is_scalar($data) ? strlen($data) : 0); } else { return -$rescode; } @@ -113,7 +113,7 @@ function dol_setcache($memoryid, $data, $expire = 0) //$dolmemcache->setOption(Memcached::OPT_COMPRESSION, false); $result = $dolmemcache->add($memoryid, $data, false, $expire); // This fails if key already exists if ($result) { - return is_countable($data) ? count($data) : 0; + return is_array($data) ? count($data) : (is_scalar($data) ? strlen($data) : 0); } else { return -1; } diff --git a/htdocs/core/lib/modulebuilder.lib.php b/htdocs/core/lib/modulebuilder.lib.php index a5589679b50..7c32b377bd4 100644 --- a/htdocs/core/lib/modulebuilder.lib.php +++ b/htdocs/core/lib/modulebuilder.lib.php @@ -17,8 +17,8 @@ */ /** - * \file htdocs/core/lib/memory.lib.php - * \brief Set of function for memory/cache management + * \file htdocs/core/lib/modulebuilder.lib.php + * \brief Set of function for modulebuilder management */ @@ -305,6 +305,8 @@ function rebuildObjectSql($destdir, $module, $objectname, $newmask, $readdir = ' $texttoinsert .= "\t".$key." ".$type; if ($key == 'rowid') { $texttoinsert .= ' AUTO_INCREMENT PRIMARY KEY'; + } elseif ($type == 'timestamp') { + $texttoinsert .= ' DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP'; } if ($key == 'entity') { $texttoinsert .= ' DEFAULT 1'; diff --git a/htdocs/core/lib/oauth.lib.php b/htdocs/core/lib/oauth.lib.php index 48356868143..ab1b5a217b8 100644 --- a/htdocs/core/lib/oauth.lib.php +++ b/htdocs/core/lib/oauth.lib.php @@ -25,13 +25,13 @@ // Supported OAUTH (a provider is supported when a file xxx_oauthcallback.php is available into htdocs/core/modules/oauth) $supportedoauth2array = array( - 'OAUTH_GOOGLE_NAME'=>'google', + 'OAUTH_GOOGLE_NAME'=>array('callbackfile' => 'google', 'picto' => 'google', 'urlforapp' => 'OAUTH_GOOGLE_DESC', 'name'=>'Google'), ); -if ($conf->global->MAIN_FEATURES_LEVEL >= 2) { - $supportedoauth2array['OAUTH_STRIPE_TEST_NAME'] = 'stripetest'; - $supportedoauth2array['OAUTH_STRIPE_LIVE_NAME'] = 'stripelive'; +if (!empty($conf->stripe->enabled)) { + $supportedoauth2array['OAUTH_STRIPE_TEST_NAME'] = array('callbackfile' => 'stripetest', 'picto' => 'stripe', 'urlforapp' => '', 'name'=>'StripeTest'); + $supportedoauth2array['OAUTH_STRIPE_LIVE_NAME'] = array('callbackfile' => 'stripelive', 'picto' => 'stripe', 'urlforapp' => '', 'name'=>'StripeLive'); } -$supportedoauth2array['OAUTH_GITHUB_NAME'] = 'github'; +$supportedoauth2array['OAUTH_GITHUB_NAME'] = array('callbackfile' => 'github', 'picto' => 'github', 'urlforapp' => 'OAUTH_GITHUB_DESC', 'name'=>'GitHub'); diff --git a/htdocs/core/lib/payments.lib.php b/htdocs/core/lib/payments.lib.php index 2bb1cf1d0cf..2911564adef 100644 --- a/htdocs/core/lib/payments.lib.php +++ b/htdocs/core/lib/payments.lib.php @@ -187,7 +187,7 @@ function showOnlinePaymentUrl($type, $ref) $out = img_picto('', 'globe').' '.$langs->trans("ToOfferALinkForOnlinePayment", $servicename).'
    '; $url = getOnlinePaymentUrl(0, $type, $ref); $out .= ''; $out .= ajax_autoselect("onlinepaymenturl", 0); return $out; @@ -205,7 +205,7 @@ function getHtmlOnlinePaymentLink($type, $ref, $label = '') { $url = getOnlinePaymentUrl(0, $type, $ref); $label = $label ? $label : $url; - return''.$label.''; + return ''.$label.''; } @@ -213,14 +213,14 @@ function getHtmlOnlinePaymentLink($type, $ref, $label = '') * Return string with full Url * * @param int $mode 0=True url, 1=Url formated with colors - * @param string $type Type of URL ('free', 'order', 'invoice', 'contractline', 'member' ...) + * @param string $type Type of URL ('free', 'order', 'invoice', 'contractline', 'member', 'boothlocation', ...) * @param string $ref Ref of object - * @param int $amount Amount (required for $type='free' only) - * @param string $freetag Free tag + * @param int $amount Amount (required and used for $type='free' only) + * @param string $freetag Free tag (required and used for $type='free' only) * @param string $localorexternal 0=Url for browser, 1=Url for external access * @return string Url string */ -function getOnlinePaymentUrl($mode, $type, $ref = '', $amount = '9.99', $freetag = 'your_tag', $localorexternal = 0) +function getOnlinePaymentUrl($mode, $type, $ref = '', $amount = '9.99', $freetag = 'your_tag', $localorexternal = 1) { global $conf, $dolibarr_main_url_root; @@ -248,7 +248,7 @@ function getOnlinePaymentUrl($mode, $type, $ref = '', $amount = '9.99', $freetag } //if ($mode) $out.='&noidempotency=1'; } elseif ($type == 'order') { - $out = $urltouse.'/public/payment/newpayment.php?source=order&ref='.($mode ? '' : ''); + $out = $urltouse.'/public/payment/newpayment.php?source='.$type.'&ref='.($mode ? '' : ''); if ($mode == 1) { $out .= 'order_ref'; } @@ -271,7 +271,7 @@ function getOnlinePaymentUrl($mode, $type, $ref = '', $amount = '9.99', $freetag } } } elseif ($type == 'invoice') { - $out = $urltouse.'/public/payment/newpayment.php?source=invoice&ref='.($mode ? '' : ''); + $out = $urltouse.'/public/payment/newpayment.php?source='.$type.'&ref='.($mode ? '' : ''); if ($mode == 1) { $out .= 'invoice_ref'; } @@ -294,7 +294,7 @@ function getOnlinePaymentUrl($mode, $type, $ref = '', $amount = '9.99', $freetag } } } elseif ($type == 'contractline') { - $out = $urltouse.'/public/payment/newpayment.php?source=contractline&ref='.($mode ? '' : ''); + $out = $urltouse.'/public/payment/newpayment.php?source='.$type.'&ref='.($mode ? '' : ''); if ($mode == 1) { $out .= 'contractline_ref'; } @@ -340,9 +340,8 @@ function getOnlinePaymentUrl($mode, $type, $ref = '', $amount = '9.99', $freetag $out .= ($mode ? '' : ''); } } - } - if ($type == 'donation') { - $out = $urltouse.'/public/payment/newpayment.php?source=donation&ref='.($mode ? '' : ''); + } elseif ($type == 'donation') { + $out = $urltouse.'/public/payment/newpayment.php?source='.$type.'&ref='.($mode ? '' : ''); if ($mode == 1) { $out .= 'donation_ref'; } @@ -364,6 +363,29 @@ function getOnlinePaymentUrl($mode, $type, $ref = '', $amount = '9.99', $freetag $out .= ($mode ? '' : ''); } } + } elseif ($type == 'boothlocation') { + $out = $urltouse.'/public/payment/newpayment.php?source='.$type.'&ref='.($mode ? '' : ''); + if ($mode == 1) { + $out .= 'invoice_ref'; + } + if ($mode == 0) { + $out .= urlencode($ref); + } + $out .= ($mode ? '' : ''); + if (!empty($conf->global->PAYMENT_SECURITY_TOKEN)) { + if (empty($conf->global->PAYMENT_SECURITY_TOKEN_UNIQUE)) { + $out .= '&securekey='.urlencode($conf->global->PAYMENT_SECURITY_TOKEN); + } else { + $out .= '&securekey='.($mode ? '' : ''); + if ($mode == 1) { + $out .= "hash('".$conf->global->PAYMENT_SECURITY_TOKEN."' + '".$type."' + invoice_ref)"; + } + if ($mode == 0) { + $out .= dol_hash($conf->global->PAYMENT_SECURITY_TOKEN.$type.$ref, 2); + } + $out .= ($mode ? '' : ''); + } + } } // For multicompany @@ -439,9 +461,11 @@ function htmlPrintOnlinePaymentFooter($fromcompany, $langs, $addformmessage = 0, $line2 .= ($line2 ? " - " : "").$langs->transnoentities("VATIntraShort").": ".$fromcompany->tva_intra; } + print ''."\n"; + print '
    '; - print '
    '."\n"; + print '
    '."\n"; if ($addformmessage) { print ''; print '
    '; diff --git a/htdocs/core/lib/pdf.lib.php b/htdocs/core/lib/pdf.lib.php index 8293d3d1c65..ea8c6c2ce23 100644 --- a/htdocs/core/lib/pdf.lib.php +++ b/htdocs/core/lib/pdf.lib.php @@ -12,7 +12,7 @@ * Copyright (C) 2015-2016 Marcos García * Copyright (C) 2019 Lenin Rivas * Copyright (C) 2020 Nicolas ZABOURI - * Copyright (C) 2021 Anthony Berton + * Copyright (C) 2021-2022 Anthony Berton * * 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 @@ -35,6 +35,8 @@ * \ingroup core */ +include_once DOL_DOCUMENT_ROOT.'/core/lib/signature.lib.php'; + /** * Return array head with list of tabs to view object informations. @@ -707,9 +709,13 @@ function pdf_pagehead(&$pdf, $outputlangs, $page_height) // Add a background image on document only if good setup of const if (!empty($conf->global->MAIN_USE_BACKGROUND_ON_PDF) && ($conf->global->MAIN_USE_BACKGROUND_ON_PDF != '-1')) { // Warning, this option make TCPDF generation being crazy and some content disappeared behind the image - $pdf->SetAutoPageBreak(0, 0); // Disable auto pagebreak before adding image - $pdf->Image($conf->mycompany->dir_output.'/logos/'.$conf->global->MAIN_USE_BACKGROUND_ON_PDF, (isset($conf->global->MAIN_USE_BACKGROUND_ON_PDF_X) ? $conf->global->MAIN_USE_BACKGROUND_ON_PDF_X : 0), (isset($conf->global->MAIN_USE_BACKGROUND_ON_PDF_Y) ? $conf->global->MAIN_USE_BACKGROUND_ON_PDF_Y : 0), 0, $page_height); - $pdf->SetAutoPageBreak(1, 0); // Restore pagebreak + $filepath = $conf->mycompany->dir_output.'/logos/'.$conf->global->MAIN_USE_BACKGROUND_ON_PDF; + if (file_exists($filepath)) { + $pdf->SetAutoPageBreak(0, 0); // Disable auto pagebreak before adding image + $pdf->Image($filepath, (isset($conf->global->MAIN_USE_BACKGROUND_ON_PDF_X) ? $conf->global->MAIN_USE_BACKGROUND_ON_PDF_X : 0), (isset($conf->global->MAIN_USE_BACKGROUND_ON_PDF_Y) ? $conf->global->MAIN_USE_BACKGROUND_ON_PDF_Y : 0), 0, $page_height); + $pdf->SetPageMark(); // This option avoid to have the images missing on some pages + $pdf->SetAutoPageBreak(1, 0); // Restore pagebreak + } } } @@ -975,10 +981,11 @@ function pdf_bank(&$pdf, $outputlangs, $curx, $cury, $account, $onlynumber = 0, */ function pdf_pagefoot(&$pdf, $outputlangs, $paramfreetext, $fromcompany, $marge_basse, $marge_gauche, $page_hauteur, $object, $showdetails = 0, $hidefreetext = 0) { - global $conf, $user, $mysoc; + global $conf, $user, $mysoc, $hookmanager; $outputlangs->load("dict"); $line = ''; + $reg = array(); $dims = $pdf->getPageDimensions(); @@ -1045,7 +1052,7 @@ function pdf_pagefoot(&$pdf, $outputlangs, $paramfreetext, $fromcompany, $marge_ $line2 .= ($line2 ? " - " : "").$fromcompany->email; } } - if ($showdetails == 2 || $showdetails == 3 || ($fromcompany->country_code == 'DE')) { + if ($showdetails == 2 || $showdetails == 3 || (!empty($fromcompany->country_code) && $fromcompany->country_code == 'DE')) { // Managers if ($fromcompany->managers) { $line2 .= ($line2 ? " - " : "").$fromcompany->managers; @@ -1054,20 +1061,20 @@ function pdf_pagefoot(&$pdf, $outputlangs, $paramfreetext, $fromcompany, $marge_ // Line 3 of company infos // Juridical status - if ($fromcompany->forme_juridique_code) { + if (!empty($fromcompany->forme_juridique_code) && $fromcompany->forme_juridique_code) { $line3 .= ($line3 ? " - " : "").$outputlangs->convToOutputCharset(getFormeJuridiqueLabel($fromcompany->forme_juridique_code)); } // Capital - if ($fromcompany->capital) { - $tmpamounttoshow = price2num($fromcompany->capital); // This field is a free string + if (!empty($fromcompany->capital)) { + $tmpamounttoshow = price2num($fromcompany->capital); // This field is a free string or a float if (is_numeric($tmpamounttoshow) && $tmpamounttoshow > 0) { $line3 .= ($line3 ? " - " : "").$outputlangs->transnoentities("CapitalOf", price($tmpamounttoshow, 0, $outputlangs, 0, 0, 0, $conf->currency)); - } else { - $line3 .= ($line3 ? " - " : "").$outputlangs->transnoentities("CapitalOf", $tmpamounttoshow, $outputlangs); + } elseif (!empty($fromcompany->capital)) { + $line3 .= ($line3 ? " - " : "").$outputlangs->transnoentities("CapitalOf", $fromcompany->capital, $outputlangs); } } // Prof Id 1 - if ($fromcompany->idprof1 && ($fromcompany->country_code != 'FR' || !$fromcompany->idprof2)) { + if (!empty($fromcompany->idprof1) && $fromcompany->idprof1 && ($fromcompany->country_code != 'FR' || !$fromcompany->idprof2)) { $field = $outputlangs->transcountrynoentities("ProfId1", $fromcompany->country_code); if (preg_match('/\((.*)\)/i', $field, $reg)) { $field = $reg[1]; @@ -1075,7 +1082,7 @@ function pdf_pagefoot(&$pdf, $outputlangs, $paramfreetext, $fromcompany, $marge_ $line3 .= ($line3 ? " - " : "").$field.": ".$outputlangs->convToOutputCharset($fromcompany->idprof1); } // Prof Id 2 - if ($fromcompany->idprof2) { + if (!empty($fromcompany->idprof2) && $fromcompany->idprof2) { $field = $outputlangs->transcountrynoentities("ProfId2", $fromcompany->country_code); if (preg_match('/\((.*)\)/i', $field, $reg)) { $field = $reg[1]; @@ -1085,7 +1092,7 @@ function pdf_pagefoot(&$pdf, $outputlangs, $paramfreetext, $fromcompany, $marge_ // Line 4 of company infos // Prof Id 3 - if ($fromcompany->idprof3) { + if (!empty($fromcompany->idprof3) && $fromcompany->idprof3) { $field = $outputlangs->transcountrynoentities("ProfId3", $fromcompany->country_code); if (preg_match('/\((.*)\)/i', $field, $reg)) { $field = $reg[1]; @@ -1093,7 +1100,7 @@ function pdf_pagefoot(&$pdf, $outputlangs, $paramfreetext, $fromcompany, $marge_ $line4 .= ($line4 ? " - " : "").$field.": ".$outputlangs->convToOutputCharset($fromcompany->idprof3); } // Prof Id 4 - if ($fromcompany->idprof4) { + if (!empty($fromcompany->idprof4) && $fromcompany->idprof4) { $field = $outputlangs->transcountrynoentities("ProfId4", $fromcompany->country_code); if (preg_match('/\((.*)\)/i', $field, $reg)) { $field = $reg[1]; @@ -1101,7 +1108,7 @@ function pdf_pagefoot(&$pdf, $outputlangs, $paramfreetext, $fromcompany, $marge_ $line4 .= ($line4 ? " - " : "").$field.": ".$outputlangs->convToOutputCharset($fromcompany->idprof4); } // Prof Id 5 - if ($fromcompany->idprof5) { + if (!empty($fromcompany->idprof5) && $fromcompany->idprof5) { $field = $outputlangs->transcountrynoentities("ProfId5", $fromcompany->country_code); if (preg_match('/\((.*)\)/i', $field, $reg)) { $field = $reg[1]; @@ -1109,7 +1116,7 @@ function pdf_pagefoot(&$pdf, $outputlangs, $paramfreetext, $fromcompany, $marge_ $line4 .= ($line4 ? " - " : "").$field.": ".$outputlangs->convToOutputCharset($fromcompany->idprof5); } // Prof Id 6 - if ($fromcompany->idprof6) { + if (!empty($fromcompany->idprof6) && $fromcompany->idprof6) { $field = $outputlangs->transcountrynoentities("ProfId6", $fromcompany->country_code); if (preg_match('/\((.*)\)/i', $field, $reg)) { $field = $reg[1]; @@ -1117,7 +1124,7 @@ function pdf_pagefoot(&$pdf, $outputlangs, $paramfreetext, $fromcompany, $marge_ $line4 .= ($line4 ? " - " : "").$field.": ".$outputlangs->convToOutputCharset($fromcompany->idprof6); } // IntraCommunautary VAT - if ($fromcompany->tva_intra != '') { + if (!empty($fromcompany->tva_intra) && $fromcompany->tva_intra != '') { $line4 .= ($line4 ? " - " : "").$outputlangs->transnoentities("VATIntraShort").": ".$outputlangs->convToOutputCharset($fromcompany->tva_intra); } @@ -1142,50 +1149,82 @@ function pdf_pagefoot(&$pdf, $outputlangs, $paramfreetext, $fromcompany, $marge_ } } - $marginwithfooter = $marge_basse + $freetextheight + (!empty($line1) ? 3 : 0) + (!empty($line2) ? 3 : 0) + (!empty($line3) ? 3 : 0) + (!empty($line4) ? 3 : 0); - $posy = $marginwithfooter + 0; + // For customize footer + if (is_object($hookmanager)) { + $parameters = array('line1' => $line1, 'line2' => $line2, 'line3' => $line3, 'line4' => $line4, 'outputlangs'=>$outputlangs); + $action = ''; + $hookmanager->executeHooks('pdf_pagefoot', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks + if (!empty($hookmanager->resPrint) && $hidefreetext == 0) { + $mycustomfooter = $hookmanager->resPrint; + $mycustomfooterheight = pdfGetHeightForHtmlContent($pdf, dol_htmlentitiesbr($mycustomfooter, 1, 'UTF-8', 0)); - if ($line) { // Free text - $pdf->SetXY($dims['lm'], -$posy); - if (empty($conf->global->PDF_ALLOW_HTML_FOR_FREE_TEXT)) { // by default - $pdf->MultiCell(0, 3, $line, 0, $align, 0); + $marginwithfooter = $marge_basse + $freetextheight + $mycustomfooterheight; + $posy = $marginwithfooter + 0; + + if ($line) { // Free text + $pdf->SetXY($dims['lm'], -$posy); + if (empty($conf->global->PDF_ALLOW_HTML_FOR_FREE_TEXT)) { // by default + $pdf->MultiCell(0, 3, $line, 0, $align, 0); + } else { + $pdf->writeHTMLCell($pdf->page_largeur - $pdf->margin_left - $pdf->margin_right, $freetextheight, $dims['lm'], $dims['hk'] - $marginwithfooter, dol_htmlentitiesbr($line, 1, 'UTF-8', 0)); + } + $posy -= $freetextheight; + } + + $pdf->SetY(-$posy); + $pdf->line($dims['lm'], $dims['hk'] - $posy, $dims['wk'] - $dims['rm'], $dims['hk'] - $posy); + $posy--; + + $pdf->writeHTMLCell($pdf->page_largeur - $pdf->margin_left - $pdf->margin_right, $freetextheight, $dims['lm'], $dims['hk'] - $posy, dol_htmlentitiesbr($mycustomfooter, 1, 'UTF-8', 0)); + + $posy -= $mycustomfooterheight - 3; } else { - $pdf->writeHTMLCell($pdf->page_largeur - $pdf->margin_left - $pdf->margin_right, $freetextheight, $dims['lm'], $dims['hk'] - $marginwithfooter, dol_htmlentitiesbr($line, 1, 'UTF-8', 0)); + // Else default footer + $marginwithfooter = $marge_basse + $freetextheight + (!empty($line1) ? 3 : 0) + (!empty($line2) ? 3 : 0) + (!empty($line3) ? 3 : 0) + (!empty($line4) ? 3 : 0); + $posy = $marginwithfooter + 0; + + if ($line) { // Free text + $pdf->SetXY($dims['lm'], -$posy); + if (empty($conf->global->PDF_ALLOW_HTML_FOR_FREE_TEXT)) { // by default + $pdf->MultiCell(0, 3, $line, 0, $align, 0); + } else { + $pdf->writeHTMLCell($pdf->page_largeur - $pdf->margin_left - $pdf->margin_right, $freetextheight, $dims['lm'], $dims['hk'] - $marginwithfooter, dol_htmlentitiesbr($line, 1, 'UTF-8', 0)); + } + $posy -= $freetextheight; + } + + $pdf->SetY(-$posy); + $pdf->line($dims['lm'], $dims['hk'] - $posy, $dims['wk'] - $dims['rm'], $dims['hk'] - $posy); + $posy--; + + if (!empty($line1)) { + $pdf->SetFont('', 'B', 7); + $pdf->SetXY($dims['lm'], -$posy); + $pdf->MultiCell($dims['wk'] - $dims['rm'] - $dims['lm'], 2, $line1, 0, 'C', 0); + $posy -= 3; + $pdf->SetFont('', '', 7); + } + + if (!empty($line2)) { + $pdf->SetFont('', 'B', 7); + $pdf->SetXY($dims['lm'], -$posy); + $pdf->MultiCell($dims['wk'] - $dims['rm'] - $dims['lm'], 2, $line2, 0, 'C', 0); + $posy -= 3; + $pdf->SetFont('', '', 7); + } + + if (!empty($line3)) { + $pdf->SetXY($dims['lm'], -$posy); + $pdf->MultiCell($dims['wk'] - $dims['rm'] - $dims['lm'], 2, $line3, 0, 'C', 0); + } + + if (!empty($line4)) { + $posy -= 3; + $pdf->SetXY($dims['lm'], -$posy); + $pdf->MultiCell($dims['wk'] - $dims['rm'] - $dims['lm'], 2, $line4, 0, 'C', 0); + } } - $posy -= $freetextheight; } - - $pdf->SetY(-$posy); - $pdf->line($dims['lm'], $dims['hk'] - $posy, $dims['wk'] - $dims['rm'], $dims['hk'] - $posy); - $posy--; - - if (!empty($line1)) { - $pdf->SetFont('', 'B', 7); - $pdf->SetXY($dims['lm'], -$posy); - $pdf->MultiCell($dims['wk'] - $dims['rm'] - $dims['lm'], 2, $line1, 0, 'C', 0); - $posy -= 3; - $pdf->SetFont('', '', 7); - } - - if (!empty($line2)) { - $pdf->SetFont('', 'B', 7); - $pdf->SetXY($dims['lm'], -$posy); - $pdf->MultiCell($dims['wk'] - $dims['rm'] - $dims['lm'], 2, $line2, 0, 'C', 0); - $posy -= 3; - $pdf->SetFont('', '', 7); - } - - if (!empty($line3)) { - $pdf->SetXY($dims['lm'], -$posy); - $pdf->MultiCell($dims['wk'] - $dims['rm'] - $dims['lm'], 2, $line3, 0, 'C', 0); - } - - if (!empty($line4)) { - $posy -= 3; - $pdf->SetXY($dims['lm'], -$posy); - $pdf->MultiCell($dims['wk'] - $dims['rm'] - $dims['lm'], 2, $line4, 0, 'C', 0); - } - // Show page nb only on iso languages (so default Helvetica font) if (strtolower(pdf_getPDFFont($outputlangs)) == 'helvetica') { $pdf->SetXY($dims['wk'] - $dims['rm'] - 15, -$posy); @@ -1273,6 +1312,7 @@ function pdf_writelinedesc(&$pdf, $object, $i, $outputlangs, $w, $h, $posx, $pos // Fix bug of some HTML editors that replace links ]*src=")([^"]*)(&)([^"]*")/', '\1\2&\4', $labelproductservice, -1, $nbrep); //var_dump($labelproductservice);exit; @@ -1353,7 +1393,7 @@ function pdf_getlinedesc($object, $i, $outputlangs, $hideref = 0, $hidedesc = 0, $note = $prodser->multilangs[$outputlangs->defaultlang]["other"]; } } - } elseif ($object->element == 'facture' || $object->element == 'facturefourn') { + } elseif (($object->element == 'facture' || $object->element == 'facturefourn') && preg_match('/^\(DEPOSIT\).+/', $desc)) { // We must not replace '(DEPOSIT)' when it is alone, it will be translated and detailed later $desc = str_replace('(DEPOSIT)', $outputlangs->trans('Deposit'), $desc); } @@ -1361,6 +1401,11 @@ function pdf_getlinedesc($object, $i, $outputlangs, $hideref = 0, $hidedesc = 0, // Description short of product line $libelleproduitservice = $label; if (!empty($libelleproduitservice) && !empty($conf->global->PDF_BOLD_PRODUCT_LABEL)) { + // Adding may convert the original string into a HTML string. Sowe have to first + // convert \n into
    we text is not already HTML. + if (!dol_textishtml($libelleproduitservice)) { + $libelleproduitservice = str_replace("\n", '
    ', $libelleproduitservice); + } $libelleproduitservice = ''.$libelleproduitservice.''; } } @@ -1371,18 +1416,20 @@ function pdf_getlinedesc($object, $i, $outputlangs, $hideref = 0, $hidedesc = 0, $prodser->get_sousproduits_arbo(); if (!empty($prodser->sousprods) && is_array($prodser->sousprods) && count($prodser->sousprods)) { $tmparrayofsubproducts = reset($prodser->sousprods); - foreach ($tmparrayofsubproducts as $subprodval) { - $libelleproduitservice .= "\n * ".$subprodval[5].(($subprodval[5] && $subprodval[3]) ? ' - ' : '').$subprodval[3].' ('.$subprodval[1].')'; + if (!empty($conf->global->MAIN_GENERATE_DOCUMENTS_HIDE_REF)) { + foreach ($tmparrayofsubproducts as $subprodval) { + $libelleproduitservice = dol_concatdesc($libelleproduitservice, " * ".$subprodval[3].' ('.$subprodval[1].')'); + } + } else { + foreach ($tmparrayofsubproducts as $subprodval) { + $libelleproduitservice = dol_concatdesc($libelleproduitservice, " * ".$subprodval[5].(($subprodval[5] && $subprodval[3]) ? ' - ' : '').$subprodval[3].' ('.$subprodval[1].')'); + } } } } // Description long of product line if (!empty($desc) && ($desc != $label)) { - if ($libelleproduitservice && empty($hidedesc)) { - $libelleproduitservice .= '__N__'; - } - if ($desc == '(CREDIT_NOTE)' && $object->lines[$i]->fk_remise_except) { $discount = new DiscountAbsolute($db); $discount->fetch($object->lines[$i]->fk_remise_except); @@ -1416,17 +1463,17 @@ function pdf_getlinedesc($object, $i, $outputlangs, $hideref = 0, $hidedesc = 0, } if (empty($hidedesc)) { if (!empty($conf->global->MAIN_DOCUMENTS_DESCRIPTION_FIRST)) { - $libelleproduitservice = $desc."\n".$libelleproduitservice; + $libelleproduitservice = dol_concatdesc($desc, $libelleproduitservice); } else { if (!empty($conf->global->HIDE_LABEL_VARIANT_PDF) && $prodser->isVariant()) { $libelleproduitservice = $desc; } else { - $libelleproduitservice .= $desc; + $libelleproduitservice = dol_concatdesc($libelleproduitservice, $desc); } } } } else { - $libelleproduitservice .= $desc; + $libelleproduitservice = dol_concatdesc($libelleproduitservice, $desc); } } } @@ -1490,7 +1537,11 @@ function pdf_getlinedesc($object, $i, $outputlangs, $hideref = 0, $hidedesc = 0, } if (!empty($ref_prodserv) && !empty($conf->global->PDF_BOLD_PRODUCT_REF_AND_PERIOD)) { + if (!dol_textishtml($libelleproduitservice)) { + $libelleproduitservice = str_replace("\n", '
    ', $libelleproduitservice); + } $ref_prodserv = ''.$ref_prodserv.''; + // $prefix_prodserv and $ref_prodser are not HTML var } $libelleproduitservice = $prefix_prodserv.$ref_prodserv.$libelleproduitservice; @@ -1504,7 +1555,7 @@ function pdf_getlinedesc($object, $i, $outputlangs, $hideref = 0, $hidedesc = 0, // Adding the descriptions if they are filled $desccateg = $cate->description; if ($desccateg) { - $libelleproduitservice .= '__N__'.$desccateg; + $libelleproduitservice = dol_concatdesc($libelleproduitservice, $desccateg); } } } @@ -1524,9 +1575,12 @@ function pdf_getlinedesc($object, $i, $outputlangs, $hideref = 0, $hidedesc = 0, } //print '>'.$outputlangs->charset_output.','.$period; if (!empty($conf->global->PDF_BOLD_PRODUCT_REF_AND_PERIOD)) { - $libelleproduitservice .= ''."__N__ ".$period.''; + if (!dol_textishtml($libelleproduitservice)) { + $libelleproduitservice = str_replace("\n", '
    ', $libelleproduitservice); + } + $libelleproduitservice .= '
    '.$period.''; } else { - $libelleproduitservice .= "__N__".$period; + $libelleproduitservice = dol_concatdesc($libelleproduitservice, $period); } //print $libelleproduitservice; } @@ -2088,9 +2142,9 @@ function pdf_getlineprogress($object, $i, $outputlangs, $hidedetails = 0, $hookm return ''; } if (empty($hidedetails) || $hidedetails > 1) { - if ($conf->global->SITUATION_DISPLAY_DIFF_ON_PDF) { + if (!empty($conf->global->SITUATION_DISPLAY_DIFF_ON_PDF)) { $prev_progress = 0; - if (method_exists($object, 'get_prev_progress')) { + if (method_exists($object->lines[$i], 'get_prev_progress')) { $prev_progress = $object->lines[$i]->get_prev_progress($object->id); } $result = round($object->lines[$i]->situation_percent - $prev_progress, 1).'%'; @@ -2214,48 +2268,6 @@ function pdf_getlinetotalwithtax($object, $i, $outputlangs, $hidedetails = 0) return $result; } -/** - * Return total quantity of products and/or services - * - * @param Object $object Object - * @param string $type Type - * @param Translate $outputlangs Object langs for output - * @return integer - * @deprecated Not used by Dolibarr core, so will be removed. - */ -function pdf_getTotalQty($object, $type, $outputlangs) -{ - global $hookmanager; - - $total = 0; - $nblines = count($object->lines); - - // Loop on each lines - for ($i = 0; $i < $nblines; $i++) { - if ($object->lines[$i]->special_code != 3) { - if ($type == 'all') { - $total += $object->lines[$i]->qty; - } elseif ($type == 9 && is_object($hookmanager) && (($object->lines[$i]->product_type == 9 && !empty($object->lines[$i]->special_code)) || !empty($object->lines[$i]->fk_parent_line))) { - $special_code = $object->lines[$i]->special_code; - if (!empty($object->lines[$i]->fk_parent_line)) { - $special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line); - } - $hidedetails = ''; - $parameters = array('i'=>$i, 'outputlangs'=>$outputlangs, 'hidedetails'=>$hidedetails, 'special_code'=>$special_code); - $action = ''; - $reshook = $hookmanager->executeHooks('pdf_getTotalQty', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks - return $hookmanager->resPrint; - } elseif ($type == 0 && $object->lines[$i]->product_type == 0) { - $total += $object->lines[$i]->qty; - } elseif ($type == 1 && $object->lines[$i]->product_type == 1) { - $total += $object->lines[$i]->qty; - } - } - } - - return $total; -} - /** * Return linked objects to use for document generation. * Warning: To save space, this function returns only one link per link type (all links are concated on same record string). This function is used by pdf_writeLinkedObjects @@ -2287,13 +2299,11 @@ function pdf_getLinkedObjects(&$object, $outputlangs) } elseif ($objecttype == 'commande' || $objecttype == 'supplier_order') { $outputlangs->load('orders'); - if (count($objects) > 1) { - $object->note_public .= dol_concatdesc($object->note_public, '
    '.$outputlangs->transnoentities("RefOrder").' :
    '); + if (count($objects) > 1 && count($objects) <= (getDolGlobalInt("MAXREFONDOC") ? getDolGlobalInt("MAXREFONDOC") : 10)) { + $object->note_public = dol_concatdesc($object->note_public, '
    '.$outputlangs->transnoentities("RefOrder").' :
    '); foreach ($objects as $elementobject) { - $object->note_public .= dol_concatdesc($object->note_public, $outputlangs->transnoentities($elementobject->ref).($elementobject->ref_client ? ' ('.$elementobject->ref_client.')' : '').($elementobject->ref_supplier ? ' ('.$elementobject->ref_supplier.')' : '').' '); - $object->note_public .= dol_concatdesc($object->note_public, $outputlangs->transnoentities("OrderDate").' : '); - $object->note_public .= dol_concatdesc($object->note_public, dol_print_date($elementobject->date, 'day', '', $outputlangs)); - $object->note_public .= dol_concatdesc($object->note_public, '
    '); + $object->note_public = dol_concatdesc($object->note_public, $outputlangs->transnoentities($elementobject->ref).($elementobject->ref_client ? ' ('.$elementobject->ref_client.')' : '').($elementobject->ref_supplier ? ' ('.$elementobject->ref_supplier.')' : '').' '); + $object->note_public = dol_concatdesc($object->note_public, $outputlangs->transnoentities("OrderDate").' : '.dol_print_date($elementobject->date, 'day', '', $outputlangs).'
    '); } } elseif (count($objects) == 1) { $elementobject = array_shift($objects); @@ -2323,8 +2333,11 @@ function pdf_getLinkedObjects(&$object, $outputlangs) if (count($objects) > 1) { $order = null; - if (empty($object->linkedObjects['commande']) && $object->element != 'commande') $object->note_public .= dol_concatdesc($object->note_public, '
    '.$outputlangs->transnoentities("RefOrder").' / '.$outputlangs->transnoentities("RefSending").' :
    '); - else $object->note_public .= dol_concatdesc($object->note_public, '
    '.$outputlangs->transnoentities("RefSending").' :
    '); + if (empty($object->linkedObjects['commande']) && $object->element != 'commande') { + $object->note_public = dol_concatdesc($object->note_public, '
    '.$outputlangs->transnoentities("RefOrder").' / '.$outputlangs->transnoentities("RefSending").' :
    '); + } else { + $object->note_public = dol_concatdesc($object->note_public, '
    '.$outputlangs->transnoentities("RefSending").' :
    '); + } // We concat this record info into fields xxx_value. title is overwrote. foreach ($objects as $elementobject) { if (empty($object->linkedObjects['commande']) && $object->element != 'commande') { // There is not already a link to order and object is not the order, so we show also info with order @@ -2340,12 +2353,12 @@ function pdf_getLinkedObjects(&$object, $outputlangs) } if (! is_object($order)) { - $object->note_public .= dol_concatdesc($object->note_public, $outputlangs->transnoentities($elementobject->ref)); - $object->note_public .= dol_concatdesc($object->note_public, '
    '); + $object->note_public = dol_concatdesc($object->note_public, $outputlangs->transnoentities($elementobject->ref)); + $object->note_public = dol_concatdesc($object->note_public, '
    '); } else { - $object->note_public .= dol_concatdesc($object->note_public, $outputlangs->convToOutputCharset($order->ref).($order->ref_client ? ' ('.$order->ref_client.')' : '')); - $object->note_public .= dol_concatdesc($object->note_public, ' / '.$outputlangs->transnoentities($elementobject->ref)); - $object->note_public .= dol_concatdesc($object->note_public, '
    '); + $object->note_public = dol_concatdesc($object->note_public, $outputlangs->convToOutputCharset($order->ref).($order->ref_client ? ' ('.$order->ref_client.')' : '')); + $object->note_public = dol_concatdesc($object->note_public, ' / '.$outputlangs->transnoentities($elementobject->ref)); + $object->note_public = dol_concatdesc($object->note_public, '
    '); } } } elseif (count($objects) == 1) { diff --git a/htdocs/core/lib/phpsessionindb.lib.php b/htdocs/core/lib/phpsessionindb.lib.php index 132036ba23d..8001b3ece60 100644 --- a/htdocs/core/lib/phpsessionindb.lib.php +++ b/htdocs/core/lib/phpsessionindb.lib.php @@ -29,15 +29,29 @@ /** * The session open handler called by PHP whenever a session is initialized. * - * @param string $database_name Database NamedConstraint - * @param string $table_name Table name + * @param string $save_path Value of session.save_path into php.ini + * @param string $session_name Session name (Example: 'DOLSESSID_xxxxxx') * @return boolean Always true */ -function dolSessionOpen($database_name, $table_name) +function dolSessionOpen($save_path, $session_name) { - global $conf, $dbsession; + global $dbsession; - $dbsession = getDoliDBInstance($conf->db->type, $conf->db->host, $conf->db->user, $conf->db->pass, $conf->db->name, $conf->db->port); + global $dolibarr_main_db_type, $dolibarr_main_db_host; + global $dolibarr_main_db_user, $dolibarr_main_db_pass, $dolibarr_main_db_name, $dolibarr_main_db_port; + + global $dolibarr_session_db_type, $dolibarr_session_db_host; + global $dolibarr_session_db_user, $dolibarr_session_db_pass, $dolibarr_session_db_name, $dolibarr_session_db_port; + + if (empty($dolibarr_session_db_type)) { $dolibarr_session_db_type = $dolibarr_main_db_type; } + if (empty($dolibarr_session_db_host)) { $dolibarr_session_db_host = $dolibarr_main_db_host; } + if (empty($dolibarr_session_db_user)) { $dolibarr_session_db_user = $dolibarr_main_db_user; } + if (empty($dolibarr_session_db_pass)) { $dolibarr_session_db_pass = $dolibarr_main_db_pass; } + if (empty($dolibarr_session_db_name)) { $dolibarr_session_db_name = $dolibarr_main_db_name; } + if (empty($dolibarr_session_db_port)) { $dolibarr_session_db_port = $dolibarr_main_db_port; } + //var_dump('open '.$database_name.' '.$table_name); + + $dbsession = getDoliDBInstance($dolibarr_session_db_type, $dolibarr_session_db_host, $dolibarr_session_db_user, $dolibarr_session_db_pass, $dolibarr_session_db_name, $dolibarr_session_db_port); return true; } @@ -51,8 +65,10 @@ function dolSessionOpen($database_name, $table_name) function dolSessionRead($sess_id) { global $dbsession; + global $sessionlastvalueread; + global $sessionidfound; - $sql = "SELECT session_variable FROM ".MAIN_DB_PREFIX."session"; + $sql = "SELECT session_id, session_variable FROM ".MAIN_DB_PREFIX."session"; $sql .= " WHERE session_id = '".$dbsession->escape($sess_id)."'"; // Execute the query @@ -60,10 +76,16 @@ function dolSessionRead($sess_id) $num_rows = $dbsession->num_rows($resql); if ($num_rows == 0) { // No session found - return an empty string + $sessionlastvalueread = ''; + $sessionidfound = ''; return ''; } else { // Found a session - return the serialized string $obj = $dbsession->fetch_object($resql); + $sessionlastvalueread = $obj->session_variable; + $sessionidfound = $obj->session_id; + //var_dump($sessionlastvalueread); + //var_dump($sessionidfound); return $obj->session_variable; } } @@ -79,42 +101,84 @@ function dolSessionRead($sess_id) function dolSessionWrite($sess_id, $val) { global $dbsession; + global $sessionlastvalueread; + global $sessionidfound; - $time_stamp = dol_now(); + /*var_dump('write '.$sess_id); + var_dump($val); + var_dump('sessionlastvalueread='.$sessionlastvalueread.' sessionidfound='.$sessionidfound); + */ - $sql = "SELECT session_id FROM ".MAIN_DB_PREFIX."session"; - $sql .= " WHERE session_id = '".$dbsession->escape($sess_id)."'"; + //$sessionlastvalueread=''; + if ($sessionlastvalueread != $val) { + $time_stamp = dol_now(); - // Execute the query - $resql = $dbsession->query($sql); - $num_rows = $dbsession->num_rows($resql); - if ($num_rows == 0) { - // No session found, insert a new one - $insert_query = "INSERT INTO ".MAIN_DB_PREFIX."session"; - $insert_query .= "(session_id, session_variable, last_accessed)"; - $insert_query .= " VALUES ('".$dbsession->escape($sess_id)."', '".$dbsession->escape($val)."', '".$dbsession->idate($time_stamp)."')"; - $dbsession->query($insert_query); - } else { - // Existing session found - Update the session variables - $update_query = "UPDATE ".MAIN_DB_PREFIX."session"; - $update_query .= "SET session_variable = '".$dbsession->escape($val)."',"; - $update_query .= " last_accessed = '".$dbsession->idate($time_stamp)."'"; - $update_query .= " WHERE session_id = '".$dbsession->escape($sess_id)."'"; - $dbsession->query($update_query); + if (empty($sessionidfound)) { + // No session found, insert a new one + $insert_query = "INSERT INTO ".MAIN_DB_PREFIX."session"; + $insert_query .= "(session_id, session_variable, last_accessed, fk_user, remote_ip, user_agent)"; + $insert_query .= " VALUES ('".$dbsession->escape($sess_id)."', '".$dbsession->escape($val)."', '".$dbsession->idate($time_stamp)."', 0, '".$dbsession->escape(getUserRemoteIP())."', '".$dbsession->escape(substr($_SERVER['HTTP_USER_AGENT'], 0, 255))."')"; + + $result = $dbsession->query($insert_query); + if (!$result) { + dol_print_error($dbsession); + return false; + } + } else { + if ($sessionidfound != $sess_id) { + // oops. How can this happen ? + dol_print_error($dbsession, 'Oops sess_id received in dolSessionWrite differs from the cache value $sessionidfound. How can this happen ?'); + return false; + } + /*$sql = "SELECT session_id, session_variable FROM ".MAIN_DB_PREFIX."session"; + $sql .= " WHERE session_id = '".$dbsession->escape($sess_id)."'"; + + // Execute the query + $resql = $dbsession->query($sql); + $num_rows = $dbsession->num_rows($resql); + if ($num_rows == 0) { + // No session found, insert a new one + $insert_query = "INSERT INTO ".MAIN_DB_PREFIX."session"; + $insert_query .= "(session_id, session_variable, last_accessed, fk_user, remote_ip, user_agent)"; + $insert_query .= " VALUES ('".$dbsession->escape($sess_id)."', '".$dbsession->escape($val)."', '".$dbsession->idate($time_stamp)."', 0, '".$dbsession->escape(getUserRemoteIP())."', '".$dbsession->escape(substr($_SERVER['HTTP_USER_AGENT'], 0, 255)."')"; + var_dump($insert_query); + $result = $dbsession->query($insert_query); + if (!$result) { + dol_print_error($dbsession); + return false; + } + } else { + */ + // Existing session found - Update the session variables + $update_query = "UPDATE ".MAIN_DB_PREFIX."session"; + $update_query .= " SET session_variable = '".$dbsession->escape($val)."',"; + $update_query .= " last_accessed = '".$dbsession->idate($time_stamp)."',"; + $update_query .= " remote_ip = '".$dbsession->escape(getUserRemoteIP())."',"; + $update_query .= " user_agent = '".$dbsession->escape($_SERVER['HTTP_USER_AGENT'])."'"; + $update_query .= " WHERE session_id = '".$dbsession->escape($sess_id)."'"; + + $result = $dbsession->query($update_query); + if (!$result) { + dol_print_error($dbsession); + return false; + } + } } + return true; } /** * This function is executed on shutdown of the session. * - * @param string $sess_id Session ID * @return boolean Always returns true. */ -function dolSessionClose($sess_id) +function dolSessionClose() { global $dbsession; + //var_dump('close'); + $dbsession->close(); return true; @@ -130,6 +194,8 @@ function dolSessionDestroy($sess_id) { global $dbsession; + //var_dump('destroy'); + $delete_query = "DELETE FROM ".MAIN_DB_PREFIX."session"; $delete_query .= " WHERE session_id = '".$dbsession->escape($sess_id)."'"; $dbsession->query($delete_query); diff --git a/htdocs/core/lib/price.lib.php b/htdocs/core/lib/price.lib.php index 28723ab87db..4375d14430b 100644 --- a/htdocs/core/lib/price.lib.php +++ b/htdocs/core/lib/price.lib.php @@ -404,7 +404,7 @@ function calcul_price_total($qty, $pu, $remise_percent_ligne, $txtva, $uselocalt } } - // Recal function using the multicurrency price as reference price. We must set param $multicurrency_tx to 1 to avoid infinite loop. + // Recall function using the multicurrency price as reference price. We must set param $multicurrency_tx to 1 to avoid infinite loop. $newresult = calcul_price_total($qty, $pu_devise, $remise_percent_ligne, $txtva, $uselocaltax1_rate, $uselocaltax2_rate, $remise_percent_global, $price_base_type, $info_bits, $type, $seller, $localtaxes_array, $progress, 1, 0, ''); if ($multicurrency_code) { diff --git a/htdocs/core/lib/product.lib.php b/htdocs/core/lib/product.lib.php index 10c838b4c43..117871b4712 100644 --- a/htdocs/core/lib/product.lib.php +++ b/htdocs/core/lib/product.lib.php @@ -382,7 +382,7 @@ function show_stats_for_company($product, $socid) } $langs->load("propal"); print ''; - print ''.img_object('', 'propal', 'class="paddingright"').$langs->trans("Proposals").''; + print ''.img_object('', 'propal', 'class="pictofixedwidth"').$langs->trans("Proposals").''; print ''; print $product->stats_propale['customers']; print ''; @@ -401,7 +401,7 @@ function show_stats_for_company($product, $socid) } $langs->load("supplier_proposal"); print ''; - print ''.img_object('', 'supplier_proposal', 'class="paddingright"').$langs->trans("SupplierProposals").''; + print ''.img_object('', 'supplier_proposal', 'class="pictofixedwidth"').$langs->trans("SupplierProposals").''; print ''; print $product->stats_proposal_supplier['suppliers']; print ''; @@ -420,7 +420,7 @@ function show_stats_for_company($product, $socid) } $langs->load("orders"); print ''; - print ''.img_object('', 'order', 'class="paddingright"').$langs->trans("CustomersOrders").''; + print ''.img_object('', 'order', 'class="pictofixedwidth"').$langs->trans("CustomersOrders").''; print ''; print $product->stats_commande['customers']; print ''; @@ -439,7 +439,7 @@ function show_stats_for_company($product, $socid) } $langs->load("orders"); print ''; - print ''.img_object('', 'supplier_order', 'class="paddingright"').$langs->trans("SuppliersOrders").''; + print ''.img_object('', 'supplier_order', 'class="pictofixedwidth"').$langs->trans("SuppliersOrders").''; print ''; print $product->stats_commande_fournisseur['suppliers']; print ''; @@ -458,7 +458,7 @@ function show_stats_for_company($product, $socid) } $langs->load("bills"); print ''; - print ''.img_object('', 'bill').' '.$langs->trans("CustomersInvoices").''; + print ''.img_object('', 'bill', 'class="pictofixedwidth"').$langs->trans("CustomersInvoices").''; print ''; print $product->stats_facture['customers']; print ''; @@ -477,7 +477,7 @@ function show_stats_for_company($product, $socid) } $langs->load("bills"); print ''; - print ''.img_object('', 'supplier_invoice', 'class="paddingright"').$langs->trans("SuppliersInvoices").''; + print ''.img_object('', 'supplier_invoice', 'class="pictofixedwidth"').$langs->trans("SuppliersInvoices").''; print ''; print $product->stats_facture_fournisseur['suppliers']; print ''; @@ -497,7 +497,7 @@ function show_stats_for_company($product, $socid) } $langs->load("contracts"); print ''; - print ''.img_object('', 'contract', 'class="paddingright"').$langs->trans("Contracts").''; + print ''.img_object('', 'contract', 'class="pictofixedwidth"').$langs->trans("Contracts").''; print ''; print $product->stats_contrat['customers']; print ''; @@ -518,7 +518,7 @@ function show_stats_for_company($product, $socid) $langs->load("mrp"); print ''; - print ''.img_object('', 'bom', 'class="paddingright"').$langs->trans("BOM").''; + print ''.img_object('', 'bom', 'class="pictofixedwidth"').$langs->trans("BOM").''; print ''; print ''; @@ -540,7 +540,7 @@ function show_stats_for_company($product, $socid) } $langs->load("mrp"); print ''; - print ''.img_object('', 'mrp', 'class="paddingright"').$langs->trans("MO").''; + print ''.img_object('', 'mrp', 'class="pictofixedwidth"').$langs->trans("MO").''; print ''; print $form->textwithpicto($product->stats_mo['customers_toconsume'], $langs->trans("ToConsume")); print $form->textwithpicto($product->stats_mo['customers_consumed'], $langs->trans("QtyAlreadyConsumed")); diff --git a/htdocs/core/lib/project.lib.php b/htdocs/core/lib/project.lib.php index c66bcdfc2d8..90a67991413 100644 --- a/htdocs/core/lib/project.lib.php +++ b/htdocs/core/lib/project.lib.php @@ -471,14 +471,6 @@ function project_timesheet_prepare_head($mode, $fuser = null) $h++; } - /*if ($conf->global->MAIN_FEATURES_LEVEL >= 2) - { - $head[$h][0] = DOL_URL_ROOT."/projet/activity/perline.php".($param?'?'.$param:''); - $head[$h][1] = $langs->trans("InputDetail"); - $head[$h][2] = 'inputperline'; - $h++; - }*/ - complete_head_from_modules($conf, $langs, null, $head, $h, 'project_timesheet'); complete_head_from_modules($conf, $langs, null, $head, $h, 'project_timesheet', 'remove'); @@ -517,7 +509,7 @@ function project_admin_prepare_head() $head[$h][2] = 'attributes_task'; $h++; - if (! empty($conf->global->MAIN_FEATURES_LEVEL) && $conf->global->MAIN_FEATURES_LEVEL >= 2) { + if (getDolGlobalInt('MAIN_FEATURES_LEVEL') >= 2) { $langs->load("members"); $head[$h][0] = DOL_URL_ROOT.'/projet/admin/website.php'; @@ -687,22 +679,23 @@ function projectLinesa(&$inc, $parent, &$lines, &$level, $var, $showproject, &$t // Title of task if (count($arrayfields) > 0 && !empty($arrayfields['t.label']['checked'])) { - print ''; + $labeltoshow = ''; if ($showlineingray) { - print ''; + $labeltoshow .= ''; } //else print ''; for ($k = 0; $k < $level; $k++) { - print '
    '; + $labeltoshow .= '
    '; } - print $lines[$i]->label; + $labeltoshow .= dol_escape_htmltag($lines[$i]->label); for ($k = 0; $k < $level; $k++) { - print '
    '; + $labeltoshow .= '
    '; } if ($showlineingray) { - print '
    '; + $labeltoshow .= '
    '; } - //else print ''; + print ''; + print $labeltoshow; print "\n"; } @@ -830,29 +823,7 @@ function projectLinesa(&$inc, $parent, &$lines, &$level, $var, $showproject, &$t } } - // Contacts of tasks. Disabled, because available by default just after - /* - if (!empty($conf->global->PROJECT_SHOW_CONTACTS_IN_LIST)) { - print ''; - foreach (array('internal', 'external') as $source) { - $tab = $lines[$i]->liste_contact(-1, $source); - $num = count($tab); - if (!empty($num)) { - foreach ($tab as $contacttask) { - //var_dump($contacttask); - if ($source == 'internal') { - $c = new User($db); - } else { - $c = new Contact($db); - } - $c->fetch($contacttask['id']); - print $c->getNomUrl(1).' ('.$contacttask['libelle'].')
    '; - } - } - } - print ''; - }*/ - if (count($arrayfields) > 0 && !empty($arrayfields['c.assigned']['checked'])) { + if (count($arrayfields) > 0 && !empty($arrayfields['t.budget_amount']['checked'])) { print ''; print price($lines[$i]->budget_amount, 0, $langs, 1, 0, 0, $conf->currency); $total_budget_amount += $lines[$i]->budget_amount; @@ -862,10 +833,11 @@ function projectLinesa(&$inc, $parent, &$lines, &$level, $var, $showproject, &$t // Contacts of task if (count($arrayfields) > 0 && !empty($arrayfields['c.assigned']['checked'])) { print ''; + $ifisrt = 1; foreach (array('internal', 'external') as $source) { $tab = $lines[$i]->liste_contact(-1, $source); - $num = count($tab); - if (!empty($num)) { + $numcontact = count($tab); + if (!empty($numcontact)) { foreach ($tab as $contacttask) { //var_dump($contacttask); if ($source == 'internal') { @@ -875,14 +847,19 @@ function projectLinesa(&$inc, $parent, &$lines, &$level, $var, $showproject, &$t } $c->fetch($contacttask['id']); if (!empty($c->photo)) { - print $c->getNomUrl(-2).' '; + if (get_class($c) == 'User') { + print $c->getNomUrl(-2, '', 0, 0, 24, 1, '', ($ifisrt ? '' : 'notfirst')); + } else { + print $c->getNomUrl(-2, '', 0, '', -1, 0, ($ifisrt ? '' : 'notfirst')); + } } else { if (get_class($c) == 'User') { - print $c->getNomUrl(2, '', 0, 0, 24, 1);//.' '; + print $c->getNomUrl(2, '', 0, 0, 24, 1, '', ($ifisrt ? '' : 'notfirst')); } else { - print $c->getNomUrl(2);//.' '; + print $c->getNomUrl(2, '', 0, '', -1, 0, ($ifisrt ? '' : 'notfirst')); } } + $ifisrt = 0; } } } diff --git a/htdocs/core/lib/reception.lib.php b/htdocs/core/lib/reception.lib.php index 42355497286..26f6817ed24 100644 --- a/htdocs/core/lib/reception.lib.php +++ b/htdocs/core/lib/reception.lib.php @@ -36,8 +36,7 @@ function reception_prepare_head(Reception $object) { global $db, $langs, $conf, $user; - $langs->load("sendings"); - $langs->load("deliveries"); + $langs->loadLangs(array("sendings", "deliveries")); $h = 0; $head = array(); @@ -49,8 +48,8 @@ function reception_prepare_head(Reception $object) if (empty($conf->global->MAIN_DISABLE_CONTACTS_TAB)) { $objectsrc = $object; - if ($object->origin == 'commande' && $object->origin_id > 0) { - $objectsrc = new Commande($db); + if ($object->origin == 'supplier_order' && $object->origin_id > 0) { + $objectsrc = new CommandeFournisseur($db); $objectsrc->fetch($object->origin_id); } $nbContact = count($objectsrc->liste_contact(-1, 'internal')) + count($objectsrc->liste_contact(-1, 'external')); @@ -69,6 +68,19 @@ function reception_prepare_head(Reception $object) // $this->tabs = array('entity:-tabname); to remove a tab complete_head_from_modules($conf, $langs, $object, $head, $h, 'reception'); + require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; + require_once DOL_DOCUMENT_ROOT.'/core/class/link.class.php'; + $upload_dir = $conf->reception->dir_output."/".dol_sanitizeFileName($object->ref); + $nbFiles = count(dol_dir_list($upload_dir, 'files', 0, '', '(\.meta|_preview.*\.png)$')); + $nbLinks = Link::count($db, $object->element, $object->id); + $head[$h][0] = DOL_URL_ROOT.'/reception/document.php?id='.$object->id; + $head[$h][1] = $langs->trans('Documents'); + if (($nbFiles + $nbLinks) > 0) { + $head[$h][1] .= ''.($nbFiles + $nbLinks).''; + } + $head[$h][2] = 'documents'; + $h++; + $nbNote = 0; if (!empty($object->note_private)) { $nbNote++; diff --git a/htdocs/core/lib/security.lib.php b/htdocs/core/lib/security.lib.php index 89fd9fe590b..ce94d6128dc 100644 --- a/htdocs/core/lib/security.lib.php +++ b/htdocs/core/lib/security.lib.php @@ -1,6 +1,6 @@ - * Copyright (C) 2008-2017 Regis Houssin +/* Copyright (C) 2008-2021 Laurent Destailleur + * Copyright (C) 2008-2021 Regis Houssin * Copyright (C) 2020 Ferran Marcet * * This program is free software; you can redistribute it and/or modify @@ -91,14 +91,13 @@ function dol_decode($chain, $key = '1') return $chain; } - /** * Returns a hash of a string. * If constant MAIN_SECURITY_HASH_ALGO is defined, we use this function as hashing function (recommanded value is 'password_hash') * If constant MAIN_SECURITY_SALT is defined, we use it as a salt (used only if hashing algorightm is something else than 'password_hash'). * * @param string $chain String to hash - * @param string $type Type of hash ('0':auto will use MAIN_SECURITY_HASH_ALGO else md5, '1':sha1, '2':sha1+md5, '3':md5, '4':md5 for OpenLdap with no salt, '5':sha256, '6':password_hash). Use '3' here, if hash is not needed for security purpose, for security need, prefer '0'. + * @param string $type Type of hash ('0':auto will use MAIN_SECURITY_HASH_ALGO else md5, '1':sha1, '2':sha1+md5, '3':md5, '4': for OpenLdap, '5':sha256, '6':password_hash). Use '3' here, if hash is not needed for security purpose, for security need, prefer '0'. * @return string Hash of string * @see getRandomPassword() */ @@ -112,7 +111,7 @@ function dol_hash($chain, $type = '0') } // Salt value - if (!empty($conf->global->MAIN_SECURITY_SALT) && $type != '4' && $type !== 'md5openldap') { + if (!empty($conf->global->MAIN_SECURITY_SALT) && $type != '4' && $type !== 'openldap') { $chain = $conf->global->MAIN_SECURITY_SALT.$chain; } @@ -122,8 +121,8 @@ function dol_hash($chain, $type = '0') return sha1(md5($chain)); } elseif ($type == '3' || $type == 'md5') { return md5($chain); - } elseif ($type == '4' || $type == 'md5openldap') { - return '{md5}'.base64_encode(mhash(MHASH_MD5, $chain)); // For OpenLdap with md5 (based on an unencrypted password in base) + } elseif ($type == '4' || $type == 'openldap') { + return dolGetLdapPasswordHash($chain, getDolGlobalString('LDAP_PASSWORD_HASH_TYPE', 'md5')); } elseif ($type == '5' || $type == 'sha256') { return hash('sha256', $chain); } elseif ($type == '6' || $type == 'password_hash') { @@ -146,7 +145,7 @@ function dol_hash($chain, $type = '0') * * @param string $chain String to hash (not hashed string) * @param string $hash hash to compare - * @param string $type Type of hash ('0':auto, '1':sha1, '2':sha1+md5, '3':md5, '4':md5 for OpenLdap, '5':sha256). Use '3' here, if hash is not needed for security purpose, for security need, prefer '0'. + * @param string $type Type of hash ('0':auto, '1':sha1, '2':sha1+md5, '3':md5, '4': for OpenLdap, '5':sha256). Use '3' here, if hash is not needed for security purpose, for security need, prefer '0'. * @return bool True if the computed hash is the same as the given one */ function dol_verifyHash($chain, $hash, $type = '0') @@ -168,25 +167,68 @@ function dol_verifyHash($chain, $hash, $type = '0') return dol_hash($chain, $type) == $hash; } +/** + * Returns a specific ldap hash of a password. + * + * @param string $password Password to hash + * @param string $type Type of hash + * @return string Hash of password + */ +function dolGetLdapPasswordHash($password, $type = 'md5') +{ + if (empty($type)) { + $type = 'md5'; + } + + $salt = substr(sha1(time()), 0, 8); + + if ($type === 'md5') { + return '{MD5}' . base64_encode(hash("md5", $password, true)); //For OpenLdap with md5 (based on an unencrypted password in base) + } elseif ($type === 'md5frommd5') { + return '{MD5}' . base64_encode(hex2bin($password)); // Create OpenLDAP MD5 password from Dolibarr MD5 password + } elseif ($type === 'smd5') { + return "{SMD5}" . base64_encode(hash("md5", $password . $salt, true) . $salt); + } elseif ($type === 'sha') { + return '{SHA}' . base64_encode(hash("sha1", $password, true)); + } elseif ($type === 'ssha') { + return "{SSHA}" . base64_encode(hash("sha1", $password . $salt, true) . $salt); + } elseif ($type === 'sha256') { + return "{SHA256}" . base64_encode(hash("sha256", $password, true)); + } elseif ($type === 'ssha256') { + return "{SSHA256}" . base64_encode(hash("sha256", $password . $salt, true) . $salt); + } elseif ($type === 'sha384') { + return "{SHA384}" . base64_encode(hash("sha384", $password, true)); + } elseif ($type === 'ssha384') { + return "{SSHA384}" . base64_encode(hash("sha384", $password . $salt, true) . $salt); + } elseif ($type === 'sha512') { + return "{SHA512}" . base64_encode(hash("sha512", $password, true)); + } elseif ($type === 'ssha512') { + return "{SSHA512}" . base64_encode(hash("sha512", $password . $salt, true) . $salt); + } elseif ($type === 'crypt') { + return '{CRYPT}' . crypt($password, $salt); + } elseif ($type === 'clear') { + return '{CLEAR}' . $password; // Just for test, plain text password is not secured ! + } +} /** * Check permissions of a user to show a page and an object. Check read permission. * If GETPOST('action','aZ09') defined, we also check write and delete permission. * This method check permission on module then call checkUserAccessToObject() for permission on object (according to entity and socid of user). * - * @param User $user User to check - * @param string $features Features to check (it must be module $object->element. Can be a 'or' check with 'levela|levelb'. - * Examples: 'societe', 'contact', 'produit&service', 'produit|service', ...) - * This is used to check permission $user->rights->features->... - * @param int $objectid Object ID if we want to check a particular record (optional) is linked to a owned thirdparty (optional). - * @param string $tableandshare 'TableName&SharedElement' with Tablename is table where object is stored. SharedElement is an optional key to define where to check entity for multicompany module. Param not used if objectid is null (optional). - * @param string $feature2 Feature to check, second level of permission (optional). Can be a 'or' check with 'sublevela|sublevelb'. - * This is used to check permission $user->rights->features->feature2... - * @param string $dbt_keyfield Field name for socid foreign key if not fk_soc. Not used if objectid is null (optional) - * @param string $dbt_select Field name for select if not rowid. Not used if objectid is null (optional) - * @param int $isdraft 1=The object with id=$objectid is a draft - * @param int $mode Mode (0=default, 1=return with not die) - * @return int If mode = 0 (default): Always 1, die process if not allowed. If mode = 1: Return 0 if access not allowed. + * @param User $user User to check + * @param string $features Features to check (it must be module $object->element. Can be a 'or' check with 'levela|levelb'. + * Examples: 'societe', 'contact', 'produit&service', 'produit|service', ...) + * This is used to check permission $user->rights->features->... + * @param int $objectid Object ID if we want to check a particular record (optional) is linked to a owned thirdparty (optional). + * @param string $tableandshare 'TableName&SharedElement' with Tablename is table where object is stored. SharedElement is an optional key to define where to check entity for multicompany module. Param not used if objectid is null (optional). + * @param string $feature2 Feature to check, second level of permission (optional). Can be a 'or' check with 'sublevela|sublevelb'. + * This is used to check permission $user->rights->features->feature2... + * @param string $dbt_keyfield Field name for socid foreign key if not fk_soc. Not used if objectid is null (optional) + * @param string $dbt_select Field name for select if not rowid. Not used if objectid is null (optional) + * @param int $isdraft 1=The object with id=$objectid is a draft + * @param int $mode Mode (0=default, 1=return with not die) + * @return int If mode = 0 (default): Always 1, die process if not allowed. If mode = 1: Return 0 if access not allowed. * @see dol_check_secure_access_document(), checkUserAccessToObject() */ function restrictedArea($user, $features, $objectid = 0, $tableandshare = '', $feature2 = '', $dbt_keyfield = 'fk_soc', $dbt_select = 'rowid', $isdraft = 0, $mode = 0) @@ -194,6 +236,8 @@ function restrictedArea($user, $features, $objectid = 0, $tableandshare = '', $f global $db, $conf; global $hookmanager; + $objectid = ((int) $objectid); // For the case value is coming from a non sanitized user input + //dol_syslog("functions.lib:restrictedArea $feature, $objectid, $dbtablename, $feature2, $dbt_socfield, $dbt_select, $isdraft"); //print "user_id=".$user->id.", features=".$features.", feature2=".$feature2.", objectid=".$objectid; //print ", dbtablename=".$dbtablename.", dbt_socfield=".$dbt_keyfield.", dbt_select=".$dbt_select; @@ -245,10 +289,6 @@ function restrictedArea($user, $features, $objectid = 0, $tableandshare = '', $f return 1; } - if ($dbt_select != 'rowid' && $dbt_select != 'id') { - $objectid = "'".$objectid."'"; - } - // Features/modules to check $featuresarray = array($features); if (preg_match('/&/', $features)) { @@ -492,10 +532,14 @@ function restrictedArea($user, $features, $objectid = 0, $tableandshare = '', $f if (!$user->rights->fournisseur->commande->supprimer) { $deleteok = 0; } - } elseif ($feature == 'payment_supplier') { + } elseif ($feature == 'payment_supplier') { // Permission to delete a payment of an invoice is permission to edit an invoice. if (!$user->rights->fournisseur->facture->creer) { $deleteok = 0; } + } elseif ($feature == 'payment') { // Permission to delete a payment of an invoice is permission to edit an invoice. + if (!$user->rights->facture->creer) { + $deleteok = 0; + } } elseif ($feature == 'banque') { if (empty($user->rights->banque->modifier)) { $deleteok = 0; @@ -520,6 +564,14 @@ function restrictedArea($user, $features, $objectid = 0, $tableandshare = '', $f if (empty($user->rights->adherent->supprimer)) { $deleteok = 0; } + } elseif ($feature == 'paymentbybanktransfer') { + if (empty($user->rights->paymentbybanktransfer->create)) { // There is no delete permission + $deleteok = 0; + } + } elseif ($feature == 'prelevement') { + if (empty($user->rights->prelevement->bons->creer)) { // There is no delete permission + $deleteok = 0; + } } elseif (!empty($feature2)) { // This is for permissions on 2 levels foreach ($feature2 as $subfeature) { if (empty($user->rights->$feature->$subfeature->supprimer) && empty($user->rights->$feature->$subfeature->delete)) { @@ -571,24 +623,30 @@ function restrictedArea($user, $features, $objectid = 0, $tableandshare = '', $f } /** - * Check access by user to object is ok. - * This function is also called by restrictedArea that check before if module is enabled and if permission of user for $action is ok. + * Check that access by a given user to an object is ok. + * This function is also called by restrictedArea() that check before if module is enabled and if permission of user for $action is ok. * - * @param User $user User to check - * @param array $featuresarray Features/modules to check. Example: ('user','service','member','project','task',...) - * @param int|string $objectid Object ID if we want to check a particular record (optional) is linked to a owned thirdparty (optional). - * @param string $tableandshare 'TableName&SharedElement' with Tablename is table where object is stored. SharedElement is an optional key to define where to check entity for multicompany modume. Param not used if objectid is null (optional). - * @param string $feature2 Feature to check, second level of permission (optional). Can be or check with 'level1|level2'. - * @param string $dbt_keyfield Field name for socid foreign key if not fk_soc. Not used if objectid is null (optional) - * @param string $dbt_select Field name for select if not rowid. Not used if objectid is null (optional) - * @param string $parenttableforentity Parent table for entity. Example 'fk_website@website' - * @return bool True if user has access, False otherwise + * @param User $user User to check + * @param array $featuresarray Features/modules to check. Example: ('user','service','member','project','task',...) + * @param int|string|Object $object Full object or object ID or list of object id. For example if we want to check a particular record (optional) is linked to a owned thirdparty (optional). + * @param string $tableandshare 'TableName&SharedElement' with Tablename is table where object is stored. SharedElement is an optional key to define where to check entity for multicompany modume. Param not used if objectid is null (optional). + * @param string $feature2 Feature to check, second level of permission (optional). Can be or check with 'level1|level2'. + * @param string $dbt_keyfield Field name for socid foreign key if not fk_soc. Not used if objectid is null (optional) + * @param string $dbt_select Field name for select if not rowid. Not used if objectid is null (optional) + * @param string $parenttableforentity Parent table for entity. Example 'fk_website@website' + * @return bool True if user has access, False otherwise * @see restrictedArea() */ -function checkUserAccessToObject($user, array $featuresarray, $objectid = 0, $tableandshare = '', $feature2 = '', $dbt_keyfield = '', $dbt_select = 'rowid', $parenttableforentity = '') +function checkUserAccessToObject($user, array $featuresarray, $object = 0, $tableandshare = '', $feature2 = '', $dbt_keyfield = '', $dbt_select = 'rowid', $parenttableforentity = '') { global $db, $conf; + if (is_object($object)) { + $objectid = $object->id; + } else { + $objectid = $object; // $objectid can be X or 'X,Y,Z' + } + //dol_syslog("functions.lib:restrictedArea $feature, $objectid, $dbtablename, $feature2, $dbt_socfield, $dbt_select, $isdraft"); //print "user_id=".$user->id.", features=".join(',', $featuresarray).", feature2=".$feature2.", objectid=".$objectid; //print ", tableandshare=".$tableandshare.", dbt_socfield=".$dbt_keyfield.", dbt_select=".$dbt_select."
    "; @@ -601,7 +659,7 @@ function checkUserAccessToObject($user, array $featuresarray, $objectid = 0, $ta foreach ($featuresarray as $feature) { $sql = ''; - //var_dump($feature); + //var_dump($feature);exit; // For backward compatibility if ($feature == 'member') { @@ -614,11 +672,15 @@ function checkUserAccessToObject($user, array $featuresarray, $objectid = 0, $ta $feature = 'projet_task'; } + $checkonentitydone = 0; + + // Array to define rules of checks to do $check = array('adherent', 'banque', 'bom', 'don', 'mrp', 'user', 'usergroup', 'payment', 'payment_supplier', 'product', 'produit', 'service', 'produit|service', 'categorie', 'resource', 'expensereport', 'holiday', 'salaries', 'website'); // Test on entity only (Objects with no link to company) $checksoc = array('societe'); // Test for societe object $checkother = array('contact', 'agenda'); // Test on entity + link to third party on field $dbt_keyfield. Allowed if link is empty (Ex: contacts...). $checkproject = array('projet', 'project'); // Test for project object $checktask = array('projet_task'); // Test for task object + $checkhierarchy = array('expensereport', 'holiday'); $nocheck = array('barcode', 'stock'); // No test //$checkdefault = 'all other not already defined'; // Test on entity + link to third party on field $dbt_keyfield. Not allowed if link is empty (Ex: invoice, orders...). @@ -659,10 +721,12 @@ function checkUserAccessToObject($user, array $featuresarray, $objectid = 0, $ta $sql .= " AND dbt.entity IN (".getEntity($sharedelement, 1).")"; } } - } elseif (in_array($feature, $checksoc)) { // We check feature = checksoc + $checkonentitydone = 1; + } + if (in_array($feature, $checksoc)) { // We check feature = checksoc // If external user: Check permission for external users if ($user->socid > 0) { - if ($user->socid <> $objectid) { + if ($user->socid != $objectid) { return false; } } elseif (!empty($conf->societe->enabled) && ($user->rights->societe->lire && empty($user->rights->societe->client->voir))) { @@ -681,7 +745,10 @@ function checkUserAccessToObject($user, array $featuresarray, $objectid = 0, $ta $sql .= " WHERE s.rowid IN (".$db->sanitize($objectid, 1).")"; $sql .= " AND s.entity IN (".getEntity($sharedelement, 1).")"; } - } elseif (in_array($feature, $checkother)) { // Test on entity + link to thirdparty. Allowed if link is empty (Ex: contacts...). + + $checkonentitydone = 1; + } + if (in_array($feature, $checkother)) { // Test on entity + link to thirdparty. Allowed if link is empty (Ex: contacts...). // If external user: Check permission for external users if ($user->socid > 0) { $sql = "SELECT COUNT(dbt.".$dbt_select.") as nb"; @@ -703,25 +770,19 @@ function checkUserAccessToObject($user, array $featuresarray, $objectid = 0, $ta $sql .= " WHERE dbt.".$dbt_select." IN (".$db->sanitize($objectid, 1).")"; $sql .= " AND dbt.entity IN (".getEntity($sharedelement, 1).")"; } - if ($feature == 'agenda') { - // Also check owner or attendee for users without allactions->read - if ($objectid > 0 && empty($user->rights->agenda->allactions->read)) { - require_once DOL_DOCUMENT_ROOT.'/comm/action/class/actioncomm.class.php'; - $action = new ActionComm($db); - $action->fetch($objectid); - if ($action->authorid != $user->id && $action->userownerid != $user->id && !(array_key_exists($user->id, $action->userassigned))) { - return false; - } - } - } - } elseif (in_array($feature, $checkproject)) { + + $checkonentitydone = 1; + } + if (in_array($feature, $checkproject)) { if (!empty($conf->projet->enabled) && empty($user->rights->projet->all->lire)) { + $projectid = $objectid; + include_once DOL_DOCUMENT_ROOT.'/projet/class/project.class.php'; $projectstatic = new Project($db); $tmps = $projectstatic->getProjectsAuthorizedForUser($user, 0, 1, 0); $tmparray = explode(',', $tmps); - if (!in_array($objectid, $tmparray)) { + if (!in_array($projectid, $tmparray)) { return false; } } else { @@ -730,16 +791,21 @@ function checkUserAccessToObject($user, array $featuresarray, $objectid = 0, $ta $sql .= " WHERE dbt.".$dbt_select." IN (".$db->sanitize($objectid, 1).")"; $sql .= " AND dbt.entity IN (".getEntity($sharedelement, 1).")"; } - } elseif (in_array($feature, $checktask)) { + + $checkonentitydone = 1; + } + if (in_array($feature, $checktask)) { if (!empty($conf->projet->enabled) && empty($user->rights->projet->all->lire)) { $task = new Task($db); $task->fetch($objectid); + $projectid = $task->fk_project; include_once DOL_DOCUMENT_ROOT.'/projet/class/project.class.php'; $projectstatic = new Project($db); $tmps = $projectstatic->getProjectsAuthorizedForUser($user, 0, 1, 0); + $tmparray = explode(',', $tmps); - if (!in_array($task->fk_project, $tmparray)) { + if (!in_array($projectid, $tmparray)) { return false; } } else { @@ -748,7 +814,10 @@ function checkUserAccessToObject($user, array $featuresarray, $objectid = 0, $ta $sql .= " WHERE dbt.".$dbt_select." IN (".$db->sanitize($objectid, 1).")"; $sql .= " AND dbt.entity IN (".getEntity($sharedelement, 1).")"; } - } elseif (!in_array($feature, $nocheck)) { // By default (case of $checkdefault), we check on object entity + link to third party on field $dbt_keyfield + + $checkonentitydone = 1; + } + if (!$checkonentitydone && !in_array($feature, $nocheck)) { // By default (case of $checkdefault), we check on object entity + link to third party on field $dbt_keyfield // If external user: Check permission for external users if ($user->socid > 0) { if (empty($dbt_keyfield)) { @@ -790,11 +859,49 @@ function checkUserAccessToObject($user, array $featuresarray, $objectid = 0, $ta } //print $sql; + // For events, check on users assigned to event + if ($feature === 'agenda') { + // Also check owner or attendee for users without allactions->read + if ($objectid > 0 && empty($user->rights->agenda->allactions->read)) { + require_once DOL_DOCUMENT_ROOT.'/comm/action/class/actioncomm.class.php'; + $action = new ActionComm($db); + $action->fetch($objectid); + if ($action->authorid != $user->id && $action->userownerid != $user->id && !(array_key_exists($user->id, $action->userassigned))) { + return false; + } + } + } + + // For some object, we also have to check it is in the user hierarchy + // Param $object must be the full object and not a simple id to have this test possible. + if (in_array($feature, $checkhierarchy) && is_object($object)) { + $childids = $user->getAllChildIds(1); + $useridtocheck = 0; + if ($feature == 'holiday') { + $useridtocheck = $object->fk_user; + if (!in_array($useridtocheck, $childids)) { + return false; + } + $useridtocheck = $object->fk_validator; + if (!in_array($useridtocheck, $childids)) { + return false; + } + } + if ($feature == 'expensereport') { + $useridtocheck = $object->fk_user_author; + if (!$user->rights->expensereport->readall) { + if (!in_array($useridtocheck, $childids)) { + return false; + } + } + } + } + if ($sql) { $resql = $db->query($sql); if ($resql) { $obj = $db->fetch_object($resql); - if (!$obj || $obj->nb < count(explode(',', $objectid))) { + if (!$obj || $obj->nb < count(explode(',', $objectid))) { // error if we found 0 or less record than nb of id provided return false; } } else { @@ -855,9 +962,11 @@ function accessforbidden($message = '', $printheader = 1, $printfooter = 1, $sho $reshook = $hookmanager->executeHooks('getAccessForbiddenMessage', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks print $hookmanager->resPrint; if (empty($reshook)) { + $langs->loadLangs(array("errors")); if ($user->login) { print $langs->trans("CurrentLogin").': '.$user->login.'
    '; print $langs->trans("ErrorForbidden2", $langs->transnoentitiesnoconv("Home"), $langs->transnoentitiesnoconv("Users")); + print $langs->trans("ErrorForbidden4"); } else { print $langs->trans("ErrorForbidden3"); } diff --git a/htdocs/core/lib/security2.lib.php b/htdocs/core/lib/security2.lib.php index ab47bc02899..e156c83b147 100644 --- a/htdocs/core/lib/security2.lib.php +++ b/htdocs/core/lib/security2.lib.php @@ -157,7 +157,7 @@ if (!function_exists('dol_loginfunction')) { // Note: $conf->css looks like '/theme/eldy/style.css.php' /* - $conf->css = "/theme/".(GETPOST('theme','alpha')?GETPOST('theme','alpha'):$conf->theme)."/style.css.php"; + $conf->css = "/theme/".(GETPOST('theme','aZ09')?GETPOST('theme','aZ09'):$conf->theme)."/style.css.php"; $themepath=dol_buildpath($conf->css,1); if (! empty($conf->modules_parts['theme'])) // Using this feature slow down application { @@ -187,7 +187,8 @@ if (!function_exists('dol_loginfunction')) { $template_dir = DOL_DOCUMENT_ROOT."/core/tpl/"; } - // Set cookie for timeout management + // Set cookie for timeout management. We set it as a cookie so we will be able to use it to set timeout on next page before the session start + // and the conf file is loaded. $prefix = dol_getprefix(''); $sessiontimeout = 'DOLSESSTIMEOUT_'.$prefix; if (!empty($conf->global->MAIN_SESSION_TIMEOUT)) { @@ -215,15 +216,20 @@ if (!function_exists('dol_loginfunction')) { } // Execute hook getLoginPageOptions (for table) - $parameters = array('entity' => GETPOST('entity', 'int')); + $parameters = array('entity' => GETPOST('entity', 'int'), 'switchentity' => GETPOST('switchentity', 'int')); $reshook = $hookmanager->executeHooks('getLoginPageOptions', $parameters); // Note that $action and $object may have been modified by some hooks. $morelogincontent = $hookmanager->resPrint; // Execute hook getLoginPageExtraOptions (eg for js) - $parameters = array('entity' => GETPOST('entity', 'int')); + $parameters = array('entity' => GETPOST('entity', 'int'), 'switchentity' => GETPOST('switchentity', 'int')); $reshook = $hookmanager->executeHooks('getLoginPageExtraOptions', $parameters); // Note that $action and $object may have been modified by some hooks. $moreloginextracontent = $hookmanager->resPrint; + //Redirect after connection + $parameters = array('entity' => GETPOST('entity', 'int'), 'switchentity' => GETPOST('switchentity', 'int')); + $reshook = $hookmanager->executeHooks('redirectAfterConnection', $parameters); // Note that $action and $object may have been modified by some hooks. + $php_self = $hookmanager->resPrint; + // Login $login = (!empty($hookmanager->resArray['username']) ? $hookmanager->resArray['username'] : (GETPOST("username", "alpha") ? GETPOST("username", "alpha") : $demologin)); $password = $demopassword; diff --git a/htdocs/core/lib/sendings.lib.php b/htdocs/core/lib/sendings.lib.php index 0814c0f4825..e2ab74b8cfc 100644 --- a/htdocs/core/lib/sendings.lib.php +++ b/htdocs/core/lib/sendings.lib.php @@ -180,7 +180,7 @@ function delivery_prepare_head($object) require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/link.class.php'; - $upload_dir = $conf->commande->dir_output."/".dol_sanitizeFileName($tmpobject->ref); + $upload_dir = $conf->expedition->dir_output."/sending/".dol_sanitizeFileName($object->ref); $nbFiles = count(dol_dir_list($upload_dir, 'files', 0, '', '(\.meta|_preview.*\.png)$')); $nbLinks = Link::count($db, $tmpobject->element, $tmpobject->id); $head[$h][0] = DOL_URL_ROOT.'/expedition/document.php?id='.$tmpobject->id; diff --git a/htdocs/core/lib/signature.lib.php b/htdocs/core/lib/signature.lib.php index 13df1ad8d9d..1d529be6327 100644 --- a/htdocs/core/lib/signature.lib.php +++ b/htdocs/core/lib/signature.lib.php @@ -18,7 +18,7 @@ */ /** - * Return string with full Url + * Return string with full online Url to accept and sign a quote * * @param string $type Type of URL ('proposal', ...) * @param string $ref Ref of object @@ -41,7 +41,7 @@ function showOnlineSignatureUrl($type, $ref) } else { $out .= ''; } - $out .= ''.img_picto('', 'globe', 'class="paddingleft"').''; + $out .= ''.img_picto('', 'globe', 'class="paddingleft"').''; $out .= '
    '; $out .= ajax_autoselect("onlinesignatureurl", 0); return $out; @@ -51,20 +51,35 @@ function showOnlineSignatureUrl($type, $ref) /** * Return string with full Url * - * @param int $mode 0=True url, 1=Url formated with colors - * @param string $type Type of URL ('proposal', ...) - * @param string $ref Ref of object - * @return string Url string + * @param int $mode 0=True url, 1=Url formated with colors + * @param string $type Type of URL ('proposal', ...) + * @param string $ref Ref of object + * @param string $localorexternal 0=Url for browser, 1=Url for external access + * @return string Url string */ -function getOnlineSignatureUrl($mode, $type, $ref = '') +function getOnlineSignatureUrl($mode, $type, $ref = '', $localorexternal = 1) { - global $conf, $db, $langs; + global $conf, $db, $langs, $dolibarr_main_url_root; $ref = str_replace(' ', '', $ref); $out = ''; + // Define $urlwithroot + $urlwithouturlroot = preg_replace('/'.preg_quote(DOL_URL_ROOT, '/').'$/i', '', trim($dolibarr_main_url_root)); + $urlwithroot = $urlwithouturlroot.DOL_URL_ROOT; // This is to use external domain name found into config file + //$urlwithroot=DOL_MAIN_URL_ROOT; // This is to use same domain name than current + + $urltouse = DOL_MAIN_URL_ROOT; + if ($localorexternal) { + $urltouse = $urlwithroot; + } + + $securekeyseed = ''; + if ($type == 'proposal') { - $out = DOL_MAIN_URL_ROOT.'/public/onlinesign/newonlinesign.php?source=proposal&ref='.($mode ? '' : ''); + $securekeyseed = $conf->global->PROPOSAL_ONLINE_SIGNATURE_SECURITY_TOKEN; + + $out = $urltouse.'/public/onlinesign/newonlinesign.php?source=proposal&ref='.($mode ? '' : ''); if ($mode == 1) { $out .= 'proposal_ref'; } @@ -72,6 +87,12 @@ function getOnlineSignatureUrl($mode, $type, $ref = '') $out .= urlencode($ref); } $out .= ($mode ? '' : ''); + if ($mode == 1) { + $out .= "hash('".$securekeyseed."' + '".$type."' + proposal_ref)"; + } else { + $out .= '&securekey='.dol_hash($securekeyseed.$type.$ref, '0'); + } + /* if ($mode == 1) { $out .= '&hashp=hash_of_file'; } else { @@ -94,13 +115,15 @@ function getOnlineSignatureUrl($mode, $type, $ref = '') } else { $out .= '&hashp='.$hashp; } - } + }*/ } // For multicompany + /* if (!empty($out)) { $out .= "&entity=".$conf->entity; // Check the entity because He may be the same reference in several entities } + */ return $out; } diff --git a/htdocs/core/lib/stock.lib.php b/htdocs/core/lib/stock.lib.php index 2e58e6c8082..c6b1bdefe6c 100644 --- a/htdocs/core/lib/stock.lib.php +++ b/htdocs/core/lib/stock.lib.php @@ -109,6 +109,16 @@ function stock_admin_prepare_head() $head[$h][2] = 'attributes'; $h++; + $head[$h][0] = DOL_URL_ROOT.'/product/admin/stock_mouvement_extrafields.php'; + $head[$h][1] = $langs->trans("StockMouvementExtraFields"); + $head[$h][2] = 'stockMouvementAttributes'; + $h++; + + $head[$h][0] = DOL_URL_ROOT.'/product/admin/inventory_extrafields.php'; + $head[$h][1] = $langs->trans("InventoryExtraFields"); + $head[$h][2] = 'inventoryAttributes'; + $h++; + complete_head_from_modules($conf, $langs, null, $head, $h, 'stock_admin', 'remove'); return $head; diff --git a/htdocs/core/lib/tax.lib.php b/htdocs/core/lib/tax.lib.php index 40e50544b22..490b95cc92d 100644 --- a/htdocs/core/lib/tax.lib.php +++ b/htdocs/core/lib/tax.lib.php @@ -6,7 +6,7 @@ * Copyright (C) 2012 Cédric Salvador * Copyright (C) 2012-2014 Raphaël Doursenaud * Copyright (C) 2015 Marcos García - * Copyright (C) 2021 Open-Dsi + * Copyright (C) 2021-2022 Open-Dsi * * 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 @@ -696,7 +696,7 @@ function tax_by_rate($type, $db, $y, $q, $date_start, $date_end, $modetax, $dire if (($direction == 'sell' && $conf->global->TAX_MODE_SELL_PRODUCT == 'invoice') || ($direction == 'buy' && $conf->global->TAX_MODE_BUY_PRODUCT == 'invoice')) { // Count on delivery date (use invoice date as delivery is unknown) - $sql = "SELECT d.rowid, d.product_type as dtype, d.".$fk_facture." as facid, d.$f_rate as rate, d.total_ht as total_ht, d.total_ttc as total_ttc, d.".$total_tva." as total_vat, d.description as descr,"; + $sql = "SELECT d.rowid, d.product_type as dtype, d.".$fk_facture." as facid, d.$f_rate as rate, d.vat_src_code as vat_src_code, d.total_ht as total_ht, d.total_ttc as total_ttc, d.".$total_tva." as total_vat, d.description as descr,"; $sql .= " d.".$total_localtax1." as total_localtax1, d.".$total_localtax2." as total_localtax2, "; $sql .= " d.date_start as date_start, d.date_end as date_end,"; $sql .= " f.".$invoicefieldref." as facnum, f.type, f.total_ttc as ftotal_ttc, f.datef,"; @@ -739,7 +739,7 @@ function tax_by_rate($type, $db, $y, $q, $date_start, $date_end, $modetax, $dire $sql .= " ORDER BY d.rowid, d.".$fk_facture; } else { // Count on payments date - $sql = "SELECT d.rowid, d.product_type as dtype, d.".$fk_facture." as facid, d.$f_rate as rate, d.total_ht as total_ht, d.total_ttc as total_ttc, d.".$total_tva." as total_vat, d.description as descr,"; + $sql = "SELECT d.rowid, d.product_type as dtype, d.".$fk_facture." as facid, d.$f_rate as rate, d.vat_src_code as vat_src_code, d.total_ht as total_ht, d.total_ttc as total_ttc, d.".$total_tva." as total_vat, d.description as descr,"; $sql .= " d.".$total_localtax1." as total_localtax1, d.".$total_localtax2." as total_localtax2, "; $sql .= " d.date_start as date_start, d.date_end as date_end,"; $sql .= " f.".$invoicefieldref." as facnum, f.type, f.total_ttc as ftotal_ttc, f.datef,"; @@ -799,66 +799,71 @@ function tax_by_rate($type, $db, $y, $q, $date_start, $date_end, $modetax, $dire $rate = -1; $oldrowid = ''; while ($assoc = $db->fetch_array($resql)) { + $rate_key = $assoc['rate']; + if ($f_rate == 'tva_tx' && !empty($assoc['vat_src_code']) && !preg_match('/\(/', $rate_key)) { + $rate_key .= ' (' . $assoc['vat_src_code'] . ')'; + } + // Code to avoid warnings when array entry not defined - if (!isset($list[$assoc['rate']]['totalht'])) { - $list[$assoc['rate']]['totalht'] = 0; + if (!isset($list[$rate_key]['totalht'])) { + $list[$rate_key]['totalht'] = 0; } - if (!isset($list[$assoc['rate']]['vat'])) { - $list[$assoc['rate']]['vat'] = 0; + if (!isset($list[$rate_key]['vat'])) { + $list[$rate_key]['vat'] = 0; } - if (!isset($list[$assoc['rate']]['localtax1'])) { - $list[$assoc['rate']]['localtax1'] = 0; + if (!isset($list[$rate_key]['localtax1'])) { + $list[$rate_key]['localtax1'] = 0; } - if (!isset($list[$assoc['rate']]['localtax2'])) { - $list[$assoc['rate']]['localtax2'] = 0; + if (!isset($list[$rate_key]['localtax2'])) { + $list[$rate_key]['localtax2'] = 0; } if ($assoc['rowid'] != $oldrowid) { // Si rupture sur d.rowid $oldrowid = $assoc['rowid']; - $list[$assoc['rate']]['totalht'] += $assoc['total_ht']; - $list[$assoc['rate']]['vat'] += $assoc['total_vat']; - $list[$assoc['rate']]['localtax1'] += $assoc['total_localtax1']; - $list[$assoc['rate']]['localtax2'] += $assoc['total_localtax2']; + $list[$rate_key]['totalht'] += $assoc['total_ht']; + $list[$rate_key]['vat'] += $assoc['total_vat']; + $list[$rate_key]['localtax1'] += $assoc['total_localtax1']; + $list[$rate_key]['localtax2'] += $assoc['total_localtax2']; } - $list[$assoc['rate']]['dtotal_ttc'][] = $assoc['total_ttc']; - $list[$assoc['rate']]['dtype'][] = $assoc['dtype']; - $list[$assoc['rate']]['datef'][] = $db->jdate($assoc['datef']); - $list[$assoc['rate']]['datep'][] = $db->jdate($assoc['datep']); + $list[$rate_key]['dtotal_ttc'][] = $assoc['total_ttc']; + $list[$rate_key]['dtype'][] = $assoc['dtype']; + $list[$rate_key]['datef'][] = $db->jdate($assoc['datef']); + $list[$rate_key]['datep'][] = $db->jdate($assoc['datep']); - $list[$assoc['rate']]['company_name'][] = $assoc['company_name']; - $list[$assoc['rate']]['company_id'][] = $assoc['company_id']; - $list[$assoc['rate']]['company_alias'][] = $assoc['company_alias']; - $list[$assoc['rate']]['company_email'][] = $assoc['company_email']; - $list[$assoc['rate']]['company_tva_intra'][] = $assoc['company_tva_intra']; - $list[$assoc['rate']]['company_client'][] = $assoc['company_client']; - $list[$assoc['rate']]['company_fournisseur'][] = $assoc['company_fournisseur']; - $list[$assoc['rate']]['company_customer_code'][] = $assoc['company_customer_code']; - $list[$assoc['rate']]['company_supplier_code'][] = $assoc['company_supplier_code']; - $list[$assoc['rate']]['company_customer_accounting_code'][] = $assoc['company_customer_accounting_code']; - $list[$assoc['rate']]['company_supplier_accounting_code'][] = $assoc['company_supplier_accounting_code']; - $list[$assoc['rate']]['company_status'][] = $assoc['company_status']; + $list[$rate_key]['company_name'][] = $assoc['company_name']; + $list[$rate_key]['company_id'][] = $assoc['company_id']; + $list[$rate_key]['company_alias'][] = $assoc['company_alias']; + $list[$rate_key]['company_email'][] = $assoc['company_email']; + $list[$rate_key]['company_tva_intra'][] = $assoc['company_tva_intra']; + $list[$rate_key]['company_client'][] = $assoc['company_client']; + $list[$rate_key]['company_fournisseur'][] = $assoc['company_fournisseur']; + $list[$rate_key]['company_customer_code'][] = $assoc['company_customer_code']; + $list[$rate_key]['company_supplier_code'][] = $assoc['company_supplier_code']; + $list[$rate_key]['company_customer_accounting_code'][] = $assoc['company_customer_accounting_code']; + $list[$rate_key]['company_supplier_accounting_code'][] = $assoc['company_supplier_accounting_code']; + $list[$rate_key]['company_status'][] = $assoc['company_status']; - $list[$assoc['rate']]['ddate_start'][] = $db->jdate($assoc['date_start']); - $list[$assoc['rate']]['ddate_end'][] = $db->jdate($assoc['date_end']); + $list[$rate_key]['ddate_start'][] = $db->jdate($assoc['date_start']); + $list[$rate_key]['ddate_end'][] = $db->jdate($assoc['date_end']); - $list[$assoc['rate']]['facid'][] = $assoc['facid']; - $list[$assoc['rate']]['facnum'][] = $assoc['facnum']; - $list[$assoc['rate']]['type'][] = $assoc['type']; - $list[$assoc['rate']]['ftotal_ttc'][] = $assoc['ftotal_ttc']; - $list[$assoc['rate']]['descr'][] = $assoc['descr']; + $list[$rate_key]['facid'][] = $assoc['facid']; + $list[$rate_key]['facnum'][] = $assoc['facnum']; + $list[$rate_key]['type'][] = $assoc['type']; + $list[$rate_key]['ftotal_ttc'][] = $assoc['ftotal_ttc']; + $list[$rate_key]['descr'][] = $assoc['descr']; - $list[$assoc['rate']]['totalht_list'][] = $assoc['total_ht']; - $list[$assoc['rate']]['vat_list'][] = $assoc['total_vat']; - $list[$assoc['rate']]['localtax1_list'][] = $assoc['total_localtax1']; - $list[$assoc['rate']]['localtax2_list'][] = $assoc['total_localtax2']; + $list[$rate_key]['totalht_list'][] = $assoc['total_ht']; + $list[$rate_key]['vat_list'][] = $assoc['total_vat']; + $list[$rate_key]['localtax1_list'][] = $assoc['total_localtax1']; + $list[$rate_key]['localtax2_list'][] = $assoc['total_localtax2']; - $list[$assoc['rate']]['pid'][] = $assoc['pid']; - $list[$assoc['rate']]['pref'][] = $assoc['pref']; - $list[$assoc['rate']]['ptype'][] = $assoc['ptype']; + $list[$rate_key]['pid'][] = $assoc['pid']; + $list[$rate_key]['pref'][] = $assoc['pref']; + $list[$rate_key]['ptype'][] = $assoc['ptype']; - $list[$assoc['rate']]['payment_id'][] = $assoc['payment_id']; - $list[$assoc['rate']]['payment_ref'][] = $assoc['payment_ref']; - $list[$assoc['rate']]['payment_amount'][] = $assoc['payment_amount']; + $list[$rate_key]['payment_id'][] = $assoc['payment_id']; + $list[$rate_key]['payment_ref'][] = $assoc['payment_ref']; + $list[$rate_key]['payment_amount'][] = $assoc['payment_amount']; $rate = $assoc['rate']; } @@ -876,7 +881,7 @@ function tax_by_rate($type, $db, $y, $q, $date_start, $date_end, $modetax, $dire if (($direction == 'sell' && $conf->global->TAX_MODE_SELL_SERVICE == 'invoice') || ($direction == 'buy' && $conf->global->TAX_MODE_BUY_SERVICE == 'invoice')) { // Count on invoice date - $sql = "SELECT d.rowid, d.product_type as dtype, d.".$fk_facture." as facid, d.$f_rate as rate, d.total_ht as total_ht, d.total_ttc as total_ttc, d.".$total_tva." as total_vat, d.description as descr,"; + $sql = "SELECT d.rowid, d.product_type as dtype, d.".$fk_facture." as facid, d.$f_rate as rate, d.vat_src_code as vat_src_code, d.total_ht as total_ht, d.total_ttc as total_ttc, d.".$total_tva." as total_vat, d.description as descr,"; $sql .= " d.".$total_localtax1." as total_localtax1, d.".$total_localtax2." as total_localtax2, "; $sql .= " d.date_start as date_start, d.date_end as date_end,"; $sql .= " f.".$invoicefieldref." as facnum, f.type, f.total_ttc as ftotal_ttc, f.datef,"; @@ -919,7 +924,7 @@ function tax_by_rate($type, $db, $y, $q, $date_start, $date_end, $modetax, $dire $sql .= " ORDER BY d.rowid, d.".$fk_facture; } else { // Count on payments date - $sql = "SELECT d.rowid, d.product_type as dtype, d.".$fk_facture." as facid, d.$f_rate as rate, d.total_ht as total_ht, d.total_ttc as total_ttc, d.".$total_tva." as total_vat, d.description as descr,"; + $sql = "SELECT d.rowid, d.product_type as dtype, d.".$fk_facture." as facid, d.$f_rate as rate, d.vat_src_code as vat_src_code, d.total_ht as total_ht, d.total_ttc as total_ttc, d.".$total_tva." as total_vat, d.description as descr,"; $sql .= " d.".$total_localtax1." as total_localtax1, d.".$total_localtax2." as total_localtax2, "; $sql .= " d.date_start as date_start, d.date_end as date_end,"; $sql .= " f.".$invoicefieldref." as facnum, f.type, f.total_ttc as ftotal_ttc, f.datef,"; @@ -979,66 +984,71 @@ function tax_by_rate($type, $db, $y, $q, $date_start, $date_end, $modetax, $dire $rate = -1; $oldrowid = ''; while ($assoc = $db->fetch_array($resql)) { + $rate_key = $assoc['rate']; + if ($f_rate == 'tva_tx' && !empty($assoc['vat_src_code']) && !preg_match('/\(/', $rate_key)) { + $rate_key .= ' (' . $assoc['vat_src_code'] . ')'; + } + // Code to avoid warnings when array entry not defined - if (!isset($list[$assoc['rate']]['totalht'])) { - $list[$assoc['rate']]['totalht'] = 0; + if (!isset($list[$rate_key]['totalht'])) { + $list[$rate_key]['totalht'] = 0; } - if (!isset($list[$assoc['rate']]['vat'])) { - $list[$assoc['rate']]['vat'] = 0; + if (!isset($list[$rate_key]['vat'])) { + $list[$rate_key]['vat'] = 0; } - if (!isset($list[$assoc['rate']]['localtax1'])) { - $list[$assoc['rate']]['localtax1'] = 0; + if (!isset($list[$rate_key]['localtax1'])) { + $list[$rate_key]['localtax1'] = 0; } - if (!isset($list[$assoc['rate']]['localtax2'])) { - $list[$assoc['rate']]['localtax2'] = 0; + if (!isset($list[$rate_key]['localtax2'])) { + $list[$rate_key]['localtax2'] = 0; } if ($assoc['rowid'] != $oldrowid) { // Si rupture sur d.rowid $oldrowid = $assoc['rowid']; - $list[$assoc['rate']]['totalht'] += $assoc['total_ht']; - $list[$assoc['rate']]['vat'] += $assoc['total_vat']; - $list[$assoc['rate']]['localtax1'] += $assoc['total_localtax1']; - $list[$assoc['rate']]['localtax2'] += $assoc['total_localtax2']; + $list[$rate_key]['totalht'] += $assoc['total_ht']; + $list[$rate_key]['vat'] += $assoc['total_vat']; + $list[$rate_key]['localtax1'] += $assoc['total_localtax1']; + $list[$rate_key]['localtax2'] += $assoc['total_localtax2']; } - $list[$assoc['rate']]['dtotal_ttc'][] = $assoc['total_ttc']; - $list[$assoc['rate']]['dtype'][] = $assoc['dtype']; - $list[$assoc['rate']]['datef'][] = $db->jdate($assoc['datef']); - $list[$assoc['rate']]['datep'][] = $db->jdate($assoc['datep']); + $list[$rate_key]['dtotal_ttc'][] = $assoc['total_ttc']; + $list[$rate_key]['dtype'][] = $assoc['dtype']; + $list[$rate_key]['datef'][] = $db->jdate($assoc['datef']); + $list[$rate_key]['datep'][] = $db->jdate($assoc['datep']); - $list[$assoc['rate']]['ddate_start'][] = $db->jdate($assoc['date_start']); - $list[$assoc['rate']]['ddate_end'][] = $db->jdate($assoc['date_end']); + $list[$rate_key]['ddate_start'][] = $db->jdate($assoc['date_start']); + $list[$rate_key]['ddate_end'][] = $db->jdate($assoc['date_end']); - $list[$assoc['rate']]['company_name'][] = $assoc['company_name']; - $list[$assoc['rate']]['company_id'][] = $assoc['company_id']; - $list[$assoc['rate']]['company_alias'][] = $assoc['company_alias']; - $list[$assoc['rate']]['company_email'][] = $assoc['company_email']; - $list[$assoc['rate']]['company_tva_intra'][] = $assoc['company_tva_intra']; - $list[$assoc['rate']]['company_client'][] = $assoc['company_client']; - $list[$assoc['rate']]['company_fournisseur'][] = $assoc['company_fournisseur']; - $list[$assoc['rate']]['company_customer_code'][] = $assoc['company_customer_code']; - $list[$assoc['rate']]['company_supplier_code'][] = $assoc['company_supplier_code']; - $list[$assoc['rate']]['company_customer_accounting_code'][] = $assoc['company_customer_accounting_code']; - $list[$assoc['rate']]['company_supplier_accounting_code'][] = $assoc['company_supplier_accounting_code']; - $list[$assoc['rate']]['company_status'][] = $assoc['company_status']; + $list[$rate_key]['company_name'][] = $assoc['company_name']; + $list[$rate_key]['company_id'][] = $assoc['company_id']; + $list[$rate_key]['company_alias'][] = $assoc['company_alias']; + $list[$rate_key]['company_email'][] = $assoc['company_email']; + $list[$rate_key]['company_tva_intra'][] = $assoc['company_tva_intra']; + $list[$rate_key]['company_client'][] = $assoc['company_client']; + $list[$rate_key]['company_fournisseur'][] = $assoc['company_fournisseur']; + $list[$rate_key]['company_customer_code'][] = $assoc['company_customer_code']; + $list[$rate_key]['company_supplier_code'][] = $assoc['company_supplier_code']; + $list[$rate_key]['company_customer_accounting_code'][] = $assoc['company_customer_accounting_code']; + $list[$rate_key]['company_supplier_accounting_code'][] = $assoc['company_supplier_accounting_code']; + $list[$rate_key]['company_status'][] = $assoc['company_status']; - $list[$assoc['rate']]['facid'][] = $assoc['facid']; - $list[$assoc['rate']]['facnum'][] = $assoc['facnum']; - $list[$assoc['rate']]['type'][] = $assoc['type']; - $list[$assoc['rate']]['ftotal_ttc'][] = $assoc['ftotal_ttc']; - $list[$assoc['rate']]['descr'][] = $assoc['descr']; + $list[$rate_key]['facid'][] = $assoc['facid']; + $list[$rate_key]['facnum'][] = $assoc['facnum']; + $list[$rate_key]['type'][] = $assoc['type']; + $list[$rate_key]['ftotal_ttc'][] = $assoc['ftotal_ttc']; + $list[$rate_key]['descr'][] = $assoc['descr']; - $list[$assoc['rate']]['totalht_list'][] = $assoc['total_ht']; - $list[$assoc['rate']]['vat_list'][] = $assoc['total_vat']; - $list[$assoc['rate']]['localtax1_list'][] = $assoc['total_localtax1']; - $list[$assoc['rate']]['localtax2_list'][] = $assoc['total_localtax2']; + $list[$rate_key]['totalht_list'][] = $assoc['total_ht']; + $list[$rate_key]['vat_list'][] = $assoc['total_vat']; + $list[$rate_key]['localtax1_list'][] = $assoc['total_localtax1']; + $list[$rate_key]['localtax2_list'][] = $assoc['total_localtax2']; - $list[$assoc['rate']]['pid'][] = $assoc['pid']; - $list[$assoc['rate']]['pref'][] = $assoc['pref']; - $list[$assoc['rate']]['ptype'][] = $assoc['ptype']; + $list[$rate_key]['pid'][] = $assoc['pid']; + $list[$rate_key]['pref'][] = $assoc['pref']; + $list[$rate_key]['ptype'][] = $assoc['ptype']; - $list[$assoc['rate']]['payment_id'][] = $assoc['payment_id']; - $list[$assoc['rate']]['payment_ref'][] = $assoc['payment_ref']; - $list[$assoc['rate']]['payment_amount'][] = $assoc['payment_amount']; + $list[$rate_key]['payment_id'][] = $assoc['payment_id']; + $list[$rate_key]['payment_ref'][] = $assoc['payment_ref']; + $list[$rate_key]['payment_amount'][] = $assoc['payment_amount']; $rate = $assoc['rate']; } @@ -1056,7 +1066,7 @@ function tax_by_rate($type, $db, $y, $q, $date_start, $date_end, $modetax, $dire $sql = ''; // Count on payments date - $sql = "SELECT d.rowid, d.product_type as dtype, e.rowid as facid, d.$f_rate as rate, d.total_ht as total_ht, d.total_ttc as total_ttc, d.total_tva as total_vat, e.note_private as descr,"; + $sql = "SELECT d.rowid, d.product_type as dtype, e.rowid as facid, d.$f_rate as rate, d.vat_src_code as vat_src_code, d.total_ht as total_ht, d.total_ttc as total_ttc, d.total_tva as total_vat, e.note_private as descr,"; $sql .= " d.total_localtax1 as total_localtax1, d.total_localtax2 as total_localtax2, "; $sql .= " e.date_debut as date_start, e.date_fin as date_end, e.fk_user_author,"; $sql .= " e.ref as facnum, e.total_ttc as ftotal_ttc, e.date_create, d.fk_c_type_fees as type,"; @@ -1101,55 +1111,60 @@ function tax_by_rate($type, $db, $y, $q, $date_start, $date_end, $modetax, $dire $rate = -1; $oldrowid = ''; while ($assoc = $db->fetch_array($resql)) { + $rate_key = $assoc['rate']; + if ($f_rate == 'tva_tx' && !empty($assoc['vat_src_code']) && !preg_match('/\(/', $rate_key)) { + $rate_key .= ' (' . $assoc['vat_src_code'] . ')'; + } + // Code to avoid warnings when array entry not defined - if (!isset($list[$assoc['rate']]['totalht'])) { - $list[$assoc['rate']]['totalht'] = 0; + if (!isset($list[$rate_key]['totalht'])) { + $list[$rate_key]['totalht'] = 0; } - if (!isset($list[$assoc['rate']]['vat'])) { - $list[$assoc['rate']]['vat'] = 0; + if (!isset($list[$rate_key]['vat'])) { + $list[$rate_key]['vat'] = 0; } - if (!isset($list[$assoc['rate']]['localtax1'])) { - $list[$assoc['rate']]['localtax1'] = 0; + if (!isset($list[$rate_key]['localtax1'])) { + $list[$rate_key]['localtax1'] = 0; } - if (!isset($list[$assoc['rate']]['localtax2'])) { - $list[$assoc['rate']]['localtax2'] = 0; + if (!isset($list[$rate_key]['localtax2'])) { + $list[$rate_key]['localtax2'] = 0; } if ($assoc['rowid'] != $oldrowid) { // Si rupture sur d.rowid $oldrowid = $assoc['rowid']; - $list[$assoc['rate']]['totalht'] += $assoc['total_ht']; - $list[$assoc['rate']]['vat'] += $assoc['total_vat']; - $list[$assoc['rate']]['localtax1'] += $assoc['total_localtax1']; - $list[$assoc['rate']]['localtax2'] += $assoc['total_localtax2']; + $list[$rate_key]['totalht'] += $assoc['total_ht']; + $list[$rate_key]['vat'] += $assoc['total_vat']; + $list[$rate_key]['localtax1'] += $assoc['total_localtax1']; + $list[$rate_key]['localtax2'] += $assoc['total_localtax2']; } - $list[$assoc['rate']]['dtotal_ttc'][] = $assoc['total_ttc']; - $list[$assoc['rate']]['dtype'][] = 'ExpenseReportPayment'; - $list[$assoc['rate']]['datef'][] = $assoc['datef']; - $list[$assoc['rate']]['company_name'][] = ''; - $list[$assoc['rate']]['company_id'][] = ''; - $list[$assoc['rate']]['user_id'][] = $assoc['fk_user_author']; - $list[$assoc['rate']]['ddate_start'][] = $db->jdate($assoc['date_start']); - $list[$assoc['rate']]['ddate_end'][] = $db->jdate($assoc['date_end']); + $list[$rate_key]['dtotal_ttc'][] = $assoc['total_ttc']; + $list[$rate_key]['dtype'][] = 'ExpenseReportPayment'; + $list[$rate_key]['datef'][] = $assoc['datef']; + $list[$rate_key]['company_name'][] = ''; + $list[$rate_key]['company_id'][] = ''; + $list[$rate_key]['user_id'][] = $assoc['fk_user_author']; + $list[$rate_key]['ddate_start'][] = $db->jdate($assoc['date_start']); + $list[$rate_key]['ddate_end'][] = $db->jdate($assoc['date_end']); - $list[$assoc['rate']]['facid'][] = $assoc['facid']; - $list[$assoc['rate']]['facnum'][] = $assoc['facnum']; - $list[$assoc['rate']]['type'][] = $assoc['type']; - $list[$assoc['rate']]['ftotal_ttc'][] = $assoc['ftotal_ttc']; - $list[$assoc['rate']]['descr'][] = $assoc['descr']; + $list[$rate_key]['facid'][] = $assoc['facid']; + $list[$rate_key]['facnum'][] = $assoc['facnum']; + $list[$rate_key]['type'][] = $assoc['type']; + $list[$rate_key]['ftotal_ttc'][] = $assoc['ftotal_ttc']; + $list[$rate_key]['descr'][] = $assoc['descr']; - $list[$assoc['rate']]['totalht_list'][] = $assoc['total_ht']; - $list[$assoc['rate']]['vat_list'][] = $assoc['total_vat']; - $list[$assoc['rate']]['localtax1_list'][] = $assoc['total_localtax1']; - $list[$assoc['rate']]['localtax2_list'][] = $assoc['total_localtax2']; + $list[$rate_key]['totalht_list'][] = $assoc['total_ht']; + $list[$rate_key]['vat_list'][] = $assoc['total_vat']; + $list[$rate_key]['localtax1_list'][] = $assoc['total_localtax1']; + $list[$rate_key]['localtax2_list'][] = $assoc['total_localtax2']; - $list[$assoc['rate']]['pid'][] = $assoc['pid']; - $list[$assoc['rate']]['pref'][] = $assoc['pref']; - $list[$assoc['rate']]['ptype'][] = 'ExpenseReportPayment'; + $list[$rate_key]['pid'][] = $assoc['pid']; + $list[$rate_key]['pref'][] = $assoc['pref']; + $list[$rate_key]['ptype'][] = 'ExpenseReportPayment'; - $list[$assoc['rate']]['payment_id'][] = $assoc['payment_id']; - $list[$assoc['rate']]['payment_ref'][] = $assoc['payment_ref']; - $list[$assoc['rate']]['payment_amount'][] = $assoc['payment_amount']; + $list[$rate_key]['payment_id'][] = $assoc['payment_id']; + $list[$rate_key]['payment_ref'][] = $assoc['payment_ref']; + $list[$rate_key]['payment_amount'][] = $assoc['payment_amount']; $rate = $assoc['rate']; } diff --git a/htdocs/core/lib/ticket.lib.php b/htdocs/core/lib/ticket.lib.php index e2067240c45..2e70bfba3b9 100644 --- a/htdocs/core/lib/ticket.lib.php +++ b/htdocs/core/lib/ticket.lib.php @@ -164,7 +164,7 @@ function showDirectPublicLink($object) if ($url) { $out .= ''; $out .= ajax_autoselect("directpubliclink", 0); } else { @@ -178,16 +178,16 @@ function showDirectPublicLink($object) /** * Generate a random id * - * @param int $car Length of string to generate key + * @param int $car Length of string to generate key * @return string */ function generate_random_id($car = 16) { $string = ""; $chaine = "abcdefghijklmnopqrstuvwxyz123456789"; - srand((double) microtime() * 1000000); + mt_srand((double) microtime() * 1000000); for ($i = 0; $i < $car; $i++) { - $string .= $chaine[rand() % strlen($chaine)]; + $string .= $chaine[mt_rand() % strlen($chaine)]; } return $string; } @@ -476,7 +476,7 @@ function show_ticket_messaging($conf, $langs, $db, $filterobj, $objcon = '', $no if ($sql) { // May not be defined if module Agenda is not enabled and mailing module disabled too $sql .= $db->order($sortfield_new, $sortorder); - dol_syslog("company.lib::show_actions_done", LOG_DEBUG); + dol_syslog("ticket.lib::show_ticket_messaging", LOG_DEBUG); $resql = $db->query($sql); if ($resql) { $i = 0; @@ -491,7 +491,7 @@ function show_ticket_messaging($conf, $langs, $db, $filterobj, $objcon = '', $no $result = $contactaction->fetchResources(); if ($result < 0) { dol_print_error($db); - setEventMessage("company.lib::show_actions_done Error fetch ressource", 'errors'); + setEventMessage("ticket.lib::show_ticket_messaging Error fetch ressource", 'errors'); } //if ($donetodo == 'todo') $sql.= " AND ((a.percent >= 0 AND a.percent < 100) OR (a.percent = -1 AND a.datep > '".$db->idate($now)."'))"; @@ -635,7 +635,7 @@ function show_ticket_messaging($conf, $langs, $db, $filterobj, $objcon = '', $no if ($donetodo) { $tmp = ''; if (get_class($filterobj) == 'Societe') { - $tmp .= ''; + $tmp .= ''; } $tmp .= ($donetodo != 'done' ? $langs->trans("ActionsToDoShort") : ''); $tmp .= ($donetodo != 'done' && $donetodo != 'todo' ? ' / ' : ''); @@ -850,7 +850,7 @@ function show_ticket_messaging($conf, $langs, $db, $filterobj, $objcon = '', $no $class .= ' documentpreview'; } - $footer .= ''; + $footer .= ''; $footer .= img_mime($filePath).' '.$doc->filename; $footer .= ''; diff --git a/htdocs/core/lib/treeview.lib.php b/htdocs/core/lib/treeview.lib.php index 05e6d51a78d..78703c669c5 100644 --- a/htdocs/core/lib/treeview.lib.php +++ b/htdocs/core/lib/treeview.lib.php @@ -121,7 +121,7 @@ function tree_recur($tab, $pere, $rang, $iddivjstree = 'iddivjstree', $donoreset if ($rang == 0) { // Test also done with jstree and dynatree (not able to have inside label) - print ''; echo $dialog; if ($parameters['currentcontext'] == 'thirdpartycard' && in_array($object->forme_juridique_code, array(11, 12, 13, 15, 17, 18, 19, 35, 60, 200, 311, 312, 316, 401, 600, 700, 1005)) || $object->typent_id == 8) { - echo ''; + echo ''; } elseif ($parameters['currentcontext'] == 'membercard') { - echo ''; + echo ''; } elseif ($parameters['currentcontext'] == 'contactcard') { - echo ''; + echo ''; } if (!empty($object->mail) && empty($object->array_options['options_datapolicy_send']) && $parameters['currentcontext'] == 'thirdpartycard' && in_array($object->forme_juridique_code, array(11, 12, 13, 15, 17, 18, 19, 35, 60, 200, 311, 312, 316, 401, 600, 700, 1005)) || $object->typent_id == 8) { echo ''; diff --git a/htdocs/datapolicy/class/datapolicy.class.php b/htdocs/datapolicy/class/datapolicy.class.php index a7ed08d7e6f..d0cf2e48434 100644 --- a/htdocs/datapolicy/class/datapolicy.class.php +++ b/htdocs/datapolicy/class/datapolicy.class.php @@ -182,8 +182,8 @@ class DataPolicy $deliveryreceipt = 0; $substitutionarray = array( - '__LINKACCEPT__' => ''.$linka.'', - '__LINKREFUSED__' => ''.$linkr.'', + '__LINKACCEPT__' => ''.$linka.'', + '__LINKREFUSED__' => ''.$linkr.'', '__FIRSTNAME__' => $contact->firstname, '__NAME__' => $contact->lastname, '__CIVILITY__' => $contact->civility, @@ -259,8 +259,8 @@ class DataPolicy $deliveryreceipt = 0; $substitutionarray = array( - '__LINKACCEPT__' => ''.$linka.'', - '__LINKREFUSED__' => ''.$linkr.'', + '__LINKACCEPT__' => ''.$linka.'', + '__LINKREFUSED__' => ''.$linkr.'', ); $subject = make_substitutions($subject, $substitutionarray); $message = make_substitutions($message, $substitutionarray); @@ -269,11 +269,11 @@ class DataPolicy $actionmsg = $langs->transnoentities('MailSentBy').' '.$from.' '.$langs->transnoentities('To').' '.$sendto; if ($message) { if ($sendtocc) { - $actionmsg .= dol_concatdesc($actionmsg, $langs->transnoentities('Bcc').": ".$sendtocc); + $actionmsg = dol_concatdesc($actionmsg, $langs->transnoentities('Bcc').": ".$sendtocc); } - $actionmsg .= dol_concatdesc($actionmsg, $langs->transnoentities('MailTopic').": ".$subject); - $actionmsg .= dol_concatdesc($actionmsg, $langs->transnoentities('TextUsedInTheMessageBody').":"); - $actionmsg .= dol_concatdesc($actionmsg, $message); + $actionmsg = dol_concatdesc($actionmsg, $langs->transnoentities('MailTopic').": ".$subject); + $actionmsg = dol_concatdesc($actionmsg, $langs->transnoentities('TextUsedInTheMessageBody').":"); + $actionmsg = dol_concatdesc($actionmsg, $message); } // Send mail @@ -311,7 +311,6 @@ class DataPolicy $sendto = $adherent->email; - $code = md5($adherent->email); if (!empty($adherent->default_lang)) { $l = $adherent->default_lang; @@ -333,8 +332,8 @@ class DataPolicy $deliveryreceipt = 0; $substitutionarray = array( - '__LINKACCEPT__' => ''.$linka.'', - '__LINKREFUSED__' => ''.$linkr.'', + '__LINKACCEPT__' => ''.$linka.'', + '__LINKREFUSED__' => ''.$linkr.'', ); $subject = make_substitutions($subject, $substitutionarray); $message = make_substitutions($message, $substitutionarray); @@ -343,11 +342,11 @@ class DataPolicy $actionmsg = $langs->transnoentities('MailSentBy').' '.$from.' '.$langs->transnoentities('To').' '.$sendto; if ($message) { if ($sendtocc) { - $actionmsg .= dol_concatdesc($actionmsg, $langs->transnoentities('Bcc').": ".$sendtocc); + $actionmsg = dol_concatdesc($actionmsg, $langs->transnoentities('Bcc').": ".$sendtocc); } - $actionmsg .= dol_concatdesc($actionmsg, $langs->transnoentities('MailTopic').": ".$subject); - $actionmsg .= dol_concatdesc($actionmsg, $langs->transnoentities('TextUsedInTheMessageBody').":"); - $actionmsg .= dol_concatdesc($actionmsg, $message); + $actionmsg = dol_concatdesc($actionmsg, $langs->transnoentities('MailTopic').": ".$subject); + $actionmsg = dol_concatdesc($actionmsg, $langs->transnoentities('TextUsedInTheMessageBody').":"); + $actionmsg = dol_concatdesc($actionmsg, $message); } diff --git a/htdocs/datapolicy/langs/en_US/datapolicy.lang b/htdocs/datapolicy/langs/en_US/datapolicy.lang index 368caffcbda..a870c3499a6 100644 --- a/htdocs/datapolicy/langs/en_US/datapolicy.lang +++ b/htdocs/datapolicy/langs/en_US/datapolicy.lang @@ -23,7 +23,7 @@ Module4100Desc = Module to manage Data Privacy (Conformity with the GDPR) # datapolicySetup = Module Data Privacy Policy Setup Deletion = Deletion of data -datapolicySetupPage = Depending of laws of your countries (Example Article 5 of the GDPR), personal data must be kept for a period not exceeding that necessary for the purposes for which they were collected, except for archival purposes.
    The deletion will be done automatically after a certain duration without event (the duration which you will have indicated below). +datapolicySetupPage = Depending of laws of your countries (Example Article 5 of the GDPR), personal data must be kept for a period not exceeding that necessary for the purposes for which they were collected, except for archival purposes.
    The deletion will be done automatically after a certain duration without event (the duration which you will have indicated below). NB_MONTHS = %s months ONE_YEAR = 1 year NB_YEARS = %s years diff --git a/htdocs/datapolicy/langs/fr_FR/datapolicy.lang b/htdocs/datapolicy/langs/fr_FR/datapolicy.lang index 48b6a88cce3..6bf0c6a904d 100644 --- a/htdocs/datapolicy/langs/fr_FR/datapolicy.lang +++ b/htdocs/datapolicy/langs/fr_FR/datapolicy.lang @@ -27,7 +27,7 @@ Module4100Desc = Module de gestion de la protection des données (RGPD) # datapolicySetup = Configuration du module Protection des données Settings_DATAPOLICY = Paramétrage du module Protection des données -datapolicySetupPage = Selon la loi de votre pays (Exemple l’article 5 du RGPD), les données à caractère personnel doivent être conservées pendant une durée n’excédant pas celle nécessaire au regard des finalités pour lesquelles elles ont été traitées, à l’exception de fins archivistiques. La suppression se fera automatiquement après une certaine durée sans évènement (la durée que vous aurez indiquée ci-dessous). +datapolicySetupPage = Selon la loi de votre pays (Exemple l’article 5 du RGPD), les données à caractère personnel doivent être conservées pendant une durée n’excédant pas celle nécessaire au regard des finalités pour lesquelles elles ont été traitées, à l’exception de fins archivistiques. La suppression se fera automatiquement après une certaine durée sans évènement (la durée que vous aurez indiquée ci-dessous). NB_MONTHS = %s mois ONE_YEAR = 1 an NB_YEARS = %s ans diff --git a/htdocs/datapolicy/langs/it_IT/datapolicy.lang b/htdocs/datapolicy/langs/it_IT/datapolicy.lang index d8858b56c5b..68284e17844 100644 --- a/htdocs/datapolicy/langs/it_IT/datapolicy.lang +++ b/htdocs/datapolicy/langs/it_IT/datapolicy.lang @@ -10,7 +10,7 @@ Module4100Desc = Conformità con GDPR # datapolicySetup = Module Setup Settings_DATAPOLICY = Configurazione modulo GDPR -datapolicySetupPage = In accordo con l'art 5 del GDPR i dati personali devono essere conservati per un periodo di tempo che .... ed eliminati se non sono più utili agli scopi per cui sono stati processati. +datapolicySetupPage = In accordo con l'art 5 del GDPR i dati personali devono essere conservati per un periodo di tempo che .... ed eliminati se non sono più utili agli scopi per cui sono stati processati. NB_MONTHS = %s mesi ONE_YEAR = 1 anno NB_YEARS = %s anni diff --git a/htdocs/delivery/card.php b/htdocs/delivery/card.php index eededc31aa2..00975946f6b 100644 --- a/htdocs/delivery/card.php +++ b/htdocs/delivery/card.php @@ -101,7 +101,7 @@ if ($action == 'add') { $object->fk_incoterms = GETPOST('incoterm_id', 'int'); if (!$conf->expedition_bon->enabled && !empty($conf->stock->enabled)) { - $expedition->entrepot_id = GETPOST('entrepot_id'); + $expedition->entrepot_id = GETPOST('entrepot_id', 'int'); } // We loop on each line of order to complete object delivery with qty to delivery @@ -282,7 +282,7 @@ if ($action == 'create') { // Create. Seems to no be used print ''; print ''; - print dol_get_fiche_head($head, 'delivery', $langs->trans("Shipment"), -1, 'sending'); + print dol_get_fiche_head($head, 'delivery', $langs->trans("Shipment"), -1, 'dolly'); /* * Confirmation de la suppression @@ -348,9 +348,10 @@ if ($action == 'create') { // Create. Seems to no be used if (!empty($objectsrc->fk_project)) { $proj = new Project($db); $proj->fetch($objectsrc->fk_project); - $morehtmlref .= ''; - $morehtmlref .= $proj->ref; - $morehtmlref .= ''; + $morehtmlref .= ' : '.$proj->getNomUrl(1); + if ($proj->title) { + $morehtmlref .= ' - '.$proj->title; + } } else { $morehtmlref .= ''; } diff --git a/htdocs/delivery/class/delivery.class.php b/htdocs/delivery/class/delivery.class.php index 6bfe3a33dd7..3241461ace1 100644 --- a/htdocs/delivery/class/delivery.class.php +++ b/htdocs/delivery/class/delivery.class.php @@ -725,7 +725,7 @@ class Delivery extends CommonObject */ public function getNomUrl($withpicto = 0, $save_lastsearch_value = -1) { - global $langs; + global $langs, $hookmanager; $result = ''; @@ -757,6 +757,16 @@ class Delivery extends CommonObject $result .= ' '; } $result .= $linkstart.$this->ref.$linkend; + + global $action; + $hookmanager->initHooks(array($this->element . 'dao')); + $parameters = array('id'=>$this->id, 'getnomurl' => &$result); + $reshook = $hookmanager->executeHooks('getNomUrl', $parameters, $this, $action); // Note that $action and $object may have been modified by some hooks + if ($reshook > 0) { + $result = $hookmanager->resPrint; + } else { + $result .= $hookmanager->resPrint; + } return $result; } diff --git a/htdocs/document.php b/htdocs/document.php index 7fc0dd6fff3..7498fbb3cf6 100644 --- a/htdocs/document.php +++ b/htdocs/document.php @@ -138,6 +138,7 @@ if (in_array($modulepart, array('facture_paiement', 'unpaid'))) { */ // If we have a hash public (hashp), we guess the original_file. +$ecmfile=''; if (!empty($hashp)) { include_once DOL_DOCUMENT_ROOT.'/ecm/class/ecmfiles.class.php'; $ecmfile = new EcmFiles($db); @@ -213,7 +214,7 @@ $check_access = dol_check_secure_access_document($modulepart, $original_file, $e $accessallowed = $check_access['accessallowed']; $sqlprotectagainstexternals = $check_access['sqlprotectagainstexternals']; $fullpath_original_file = $check_access['original_file']; // $fullpath_original_file is now a full path name -//var_dump($fullpath_original_file);exit; +//var_dump($fullpath_original_file.' '.$original_file.' '.$refname.' '.$accessallowed);exit; if (!empty($hashp)) { $accessallowed = 1; // When using hashp, link is public so we force $accessallowed diff --git a/htdocs/don/card.php b/htdocs/don/card.php index 6bfa9130363..960ff7e7b2d 100644 --- a/htdocs/don/card.php +++ b/htdocs/don/card.php @@ -140,6 +140,7 @@ if (empty($reshook)) { exit; } else { setEventMessages($object->error, $object->errors, 'errors'); + $action = 'create'; } } @@ -172,7 +173,7 @@ if (empty($reshook)) { $object->lastname = (string) GETPOST("lastname", 'alpha'); $object->societe = (string) GETPOST("societe", 'alpha'); $object->address = (string) GETPOST("address", 'alpha'); - $object->amount = price2num(GETPOST("amount", 'alpha')); + $object->amount = price2num(GETPOST("amount", 'alpha'), '', 2); $object->town = (string) GETPOST("town", 'alpha'); $object->zip = (string) GETPOST("zipcode", 'alpha'); $object->country_id = (int) GETPOST('country_id', 'int'); @@ -185,7 +186,7 @@ if (empty($reshook)) { $object->modepaymentid = (int) GETPOST('modepayment', 'int'); // Fill array 'array_options' with data from add form - $ret = $extrafields->setOptionalsFromPost(null, $object); + $ret = $extrafields->setOptionalsFromPost(null, $object, '@GETPOSTISSET'); if ($ret < 0) { $error++; } @@ -193,6 +194,9 @@ if (empty($reshook)) { if ($object->update($user) > 0) { header("Location: ".$_SERVER['PHP_SELF']."?id=".$object->id); exit; + } else { + setEventMessages($object->error, $object->errors, 'errors'); + $action = "create"; } } } @@ -230,7 +234,7 @@ if (empty($reshook)) { $object->lastname = (string) GETPOST("lastname", 'alpha'); $object->societe = (string) GETPOST("societe", 'alpha'); $object->address = (string) GETPOST("address", 'alpha'); - $object->amount = price2num(GETPOST("amount", 'alpha')); + $object->amount = price2num(GETPOST("amount", 'alpha'), '', 2); $object->zip = (string) GETPOST("zipcode", 'alpha'); $object->town = (string) GETPOST("town", 'alpha'); $object->country_id = (int) GETPOST('country_id', 'int'); @@ -254,6 +258,7 @@ if (empty($reshook)) { exit; } else { setEventMessages($object->error, $object->errors, 'errors'); + $action = "create"; } } } @@ -717,9 +722,10 @@ if (!empty($id) && $action != 'edit') { if (!empty($object->fk_project)) { $proj = new Project($db); $proj->fetch($object->fk_project); - $morehtmlref .= ''; - $morehtmlref .= $proj->ref; - $morehtmlref .= ''; + $morehtmlref .= ' : '.$proj->getNomUrl(1); + if ($proj->title) { + $morehtmlref .= ' - '.$proj->title; + } } else { $morehtmlref .= ''; } diff --git a/htdocs/don/class/api_donations.class.php b/htdocs/don/class/api_donations.class.php index cfd9e8ccd8b..597f15b7f10 100644 --- a/htdocs/don/class/api_donations.class.php +++ b/htdocs/don/class/api_donations.class.php @@ -128,8 +128,9 @@ class Donations extends DolibarrApi // Add sql filters if ($sqlfilters) { - if (!DolibarrApi::_checkFilters($sqlfilters)) { - throw new RestException(503, 'Error when validating parameter sqlfilters '.$sqlfilters); + $errormessage = ''; + if (!DolibarrApi::_checkFilters($sqlfilters, $errormessage)) { + throw new RestException(503, 'Error when validating parameter sqlfilters -> '.$errormessage); } $regexstring = '\(([^:\'\(\)]+:[^:\'\(\)]+:[^\(\)]+)\)'; $sql .= " AND (".preg_replace_callback('/'.$regexstring.'/', 'DolibarrApi::_forge_criteria_callback', $sqlfilters).")"; diff --git a/htdocs/don/class/don.class.php b/htdocs/don/class/don.class.php index 7ca70a31aa2..0ce92f44e1b 100644 --- a/htdocs/don/class/don.class.php +++ b/htdocs/don/class/don.class.php @@ -353,6 +353,13 @@ class Don extends CommonObject $this->town = ($this->town > 0 ? $this->town : $this->town); $this->country_id = ($this->country_id > 0 ? $this->country_id : $this->country_id); $this->country = ($this->country ? $this->country : $this->country); + $this->amount = price2num($this->amount); + + // Check parameters + if ($this->amount < 0) { + $this->error = $langs->trans('FieldCannotBeNegative', $langs->transnoentitiesnoconv("Amount")); + return -1; + } $this->db->begin(); @@ -382,7 +389,7 @@ class Don extends CommonObject $sql .= ") VALUES ("; $sql .= "'".$this->db->idate($this->date ? $this->date : $now)."'"; $sql .= ", ".((int) $conf->entity); - $sql .= ", ".price2num($this->amount); + $sql .= ", ".((float) $this->amount); $sql .= ", ".($this->modepaymentid ? $this->modepaymentid : "null"); $sql .= ", ".($this->socid > 0 ? $this->socid : "null"); $sql .= ", '".$this->db->escape($this->firstname)."'"; @@ -464,29 +471,36 @@ class Don extends CommonObject $this->town = ($this->town > 0 ? $this->town : $this->town); $this->country_id = ($this->country_id > 0 ? $this->country_id : $this->country_id); $this->country = ($this->country ? $this->country : $this->country); + $this->amount = price2num($this->amount); + + // Check parameters + if ($this->amount < 0) { + $this->error = $langs->trans('FieldCannotBeNegative', $langs->transnoentitiesnoconv("Amount")); + return -1; + } $this->db->begin(); - $sql = "UPDATE ".MAIN_DB_PREFIX."don SET "; - $sql .= "amount = ".price2num($this->amount); - $sql .= ",fk_payment = ".($this->modepaymentid ? $this->modepaymentid : "null"); - $sql .= ",firstname = '".$this->db->escape($this->firstname)."'"; - $sql .= ",lastname='".$this->db->escape($this->lastname)."'"; - $sql .= ",societe='".$this->db->escape($this->societe)."'"; - $sql .= ",address='".$this->db->escape($this->address)."'"; - $sql .= ",zip='".$this->db->escape($this->zip)."'"; - $sql .= ",town='".$this->db->escape($this->town)."'"; - $sql .= ",fk_country = ".($this->country_id > 0 ? ((int) $this->country_id) : '0'); - $sql .= ",public=".((int) $this->public); - $sql .= ",fk_projet=".($this->fk_project > 0 ? $this->fk_project : 'null'); - $sql .= ",note_private=".(!empty($this->note_private) ? ("'".$this->db->escape($this->note_private)."'") : "NULL"); - $sql .= ",note_public=".(!empty($this->note_public) ? ("'".$this->db->escape($this->note_public)."'") : "NULL"); - $sql .= ",datedon='".$this->db->idate($this->date)."'"; - $sql .= ",date_valid=".($this->date_valid ? "'".$this->db->idate($this->date)."'" : "null"); - $sql .= ",email='".$this->db->escape(trim($this->email))."'"; - $sql .= ",phone='".$this->db->escape(trim($this->phone))."'"; - $sql .= ",phone_mobile='".$this->db->escape(trim($this->phone_mobile))."'"; - $sql .= ",fk_statut=".((int) $this->statut); + $sql = "UPDATE ".MAIN_DB_PREFIX."don SET"; + $sql .= " amount = ".((float) $this->amount); + $sql .= ", fk_payment = ".($this->modepaymentid ? $this->modepaymentid : "null"); + $sql .= ", firstname = '".$this->db->escape($this->firstname)."'"; + $sql .= ", lastname='".$this->db->escape($this->lastname)."'"; + $sql .= ", societe='".$this->db->escape($this->societe)."'"; + $sql .= ", address='".$this->db->escape($this->address)."'"; + $sql .= ", zip='".$this->db->escape($this->zip)."'"; + $sql .= ", town='".$this->db->escape($this->town)."'"; + $sql .= ", fk_country = ".($this->country_id > 0 ? ((int) $this->country_id) : '0'); + $sql .= ", public=".((int) $this->public); + $sql .= ", fk_projet=".($this->fk_project > 0 ? $this->fk_project : 'null'); + $sql .= ", note_private=".(!empty($this->note_private) ? ("'".$this->db->escape($this->note_private)."'") : "NULL"); + $sql .= ", note_public=".(!empty($this->note_public) ? ("'".$this->db->escape($this->note_public)."'") : "NULL"); + $sql .= ", datedon='".$this->db->idate($this->date)."'"; + $sql .= ", date_valid=".($this->date_valid ? "'".$this->db->idate($this->date)."'" : "null"); + $sql .= ", email='".$this->db->escape(trim($this->email))."'"; + $sql .= ", phone='".$this->db->escape(trim($this->phone))."'"; + $sql .= ", phone_mobile='".$this->db->escape(trim($this->phone_mobile))."'"; + $sql .= ", fk_statut=".((int) $this->statut); $sql .= " WHERE rowid = ".((int) $this->id); dol_syslog(get_class($this)."::Update", LOG_DEBUG); @@ -899,7 +913,7 @@ class Don extends CommonObject */ public function getNomUrl($withpicto = 0, $notooltip = 0, $moretitle = '', $save_lastsearch_value = -1) { - global $conf, $langs; + global $conf, $langs, $hookmanager; if (!empty($conf->dol_no_mouse_hover)) { $notooltip = 1; // Force disable tooltips @@ -939,7 +953,15 @@ class Don extends CommonObject $result .= $this->ref; } $result .= $linkend; - + global $action; + $hookmanager->initHooks(array($this->element . 'dao')); + $parameters = array('id'=>$this->id, 'getnomurl' => &$result); + $reshook = $hookmanager->executeHooks('getNomUrl', $parameters, $this, $action); // Note that $action and $object may have been modified by some hooks + if ($reshook > 0) { + $result = $hookmanager->resPrint; + } else { + $result .= $hookmanager->resPrint; + } return $result; } diff --git a/htdocs/don/class/paymentdonation.class.php b/htdocs/don/class/paymentdonation.class.php index b5775ce18ac..0f8db03597d 100644 --- a/htdocs/don/class/paymentdonation.class.php +++ b/htdocs/don/class/paymentdonation.class.php @@ -661,7 +661,7 @@ class PaymentDonation extends CommonObject */ public function getNomUrl($withpicto = 0, $maxlen = 0) { - global $langs; + global $langs, $hookmanager; $result = ''; @@ -684,6 +684,15 @@ class PaymentDonation extends CommonObject } } + global $action; + $hookmanager->initHooks(array($this->element . 'dao')); + $parameters = array('id'=>$this->id, 'getnomurl' => &$result); + $reshook = $hookmanager->executeHooks('getNomUrl', $parameters, $this, $action); // Note that $action and $object may have been modified by some hooks + if ($reshook > 0) { + $result = $hookmanager->resPrint; + } else { + $result .= $hookmanager->resPrint; + } return $result; } } diff --git a/htdocs/don/document.php b/htdocs/don/document.php index 51227a07ef4..ab99ba3df1d 100644 --- a/htdocs/don/document.php +++ b/htdocs/don/document.php @@ -151,9 +151,10 @@ if ($object->id) { if (!empty($object->fk_project)) { $proj = new Project($db); $proj->fetch($object->fk_project); - $morehtmlref .= ''; - $morehtmlref .= $proj->ref; - $morehtmlref .= ''; + $morehtmlref .= ' : '.$proj->getNomUrl(1); + if ($proj->title) { + $morehtmlref .= ' - '.$proj->title; + } } else { $morehtmlref .= ''; } diff --git a/htdocs/don/info.php b/htdocs/don/info.php index 431783e873a..0057bf87dce 100644 --- a/htdocs/don/info.php +++ b/htdocs/don/info.php @@ -99,9 +99,10 @@ if (!empty($conf->projet->enabled)) { if (!empty($object->fk_project)) { $proj = new Project($db); $proj->fetch($object->fk_project); - $morehtmlref .= ''; - $morehtmlref .= $proj->ref; - $morehtmlref .= ''; + $morehtmlref .= ' : '.$proj->getNomUrl(1); + if ($proj->title) { + $morehtmlref .= ' - '.$proj->title; + } } else { $morehtmlref .= ''; } diff --git a/htdocs/don/list.php b/htdocs/don/list.php index 0c8f51281a3..d7697dba43d 100644 --- a/htdocs/don/list.php +++ b/htdocs/don/list.php @@ -37,8 +37,8 @@ $langs->loadLangs(array("companies", "donations")); $contextpage = GETPOST('contextpage', 'aZ') ?GETPOST('contextpage', 'aZ') : 'sclist'; $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/don/note.php b/htdocs/don/note.php index 9dca36bd1a0..1629aa0f28f 100644 --- a/htdocs/don/note.php +++ b/htdocs/don/note.php @@ -122,9 +122,10 @@ if ($id > 0 || !empty($ref)) { if (!empty($object->fk_project)) { $proj = new Project($db); $proj->fetch($object->fk_project); - $morehtmlref .= ''; - $morehtmlref .= $proj->ref; - $morehtmlref .= ''; + $morehtmlref .= ' : '.$proj->getNomUrl(1); + if ($proj->title) { + $morehtmlref .= ' - '.$proj->title; + } } else { $morehtmlref .= ''; } diff --git a/htdocs/don/payment/payment.php b/htdocs/don/payment/payment.php index 719b6e9951b..5128509c88c 100644 --- a/htdocs/don/payment/payment.php +++ b/htdocs/don/payment/payment.php @@ -78,7 +78,7 @@ if ($action == 'add_payment') { foreach ($_POST as $key => $value) { if (substr($key, 0, 7) == 'amount_') { $other_chid = substr($key, 7); - $amounts[$other_chid] = price2num($_POST[$key]); + $amounts[$other_chid] = price2num(GETPOST($key)); } } @@ -110,7 +110,7 @@ if ($action == 'add_payment') { } if (!$error) { - $result = $payment->addPaymentToBank($user, 'payment_donation', '(DonationPayment)', $_POST['accountid'], '', ''); + $result = $payment->addPaymentToBank($user, 'payment_donation', '(DonationPayment)', GETPOST('accountid', 'int'), '', ''); if (!$result > 0) { $errmsg = $payment->error; setEventMessages($errmsg, null, 'errors'); @@ -162,7 +162,7 @@ if ($action == 'create') { print load_fiche_titre($langs->trans("DoPayment")); if (!empty($conf->use_javascript_ajax)) { - print "\n".''; @@ -1674,12 +1707,12 @@ if ($action == 'create') { // Payment term print ''.$langs->trans('PaymentConditionsShort').''; - $form->select_conditions_paiements(isset($_POST['cond_reglement_id']) ? $_POST['cond_reglement_id'] : $cond_reglement_id, 'cond_reglement_id'); + $form->select_conditions_paiements(GETPOSTISSET('cond_reglement_id') ? GETPOST('cond_reglement_id') : $cond_reglement_id, 'cond_reglement_id'); print ''; // Payment mode print ''.$langs->trans('PaymentMode').''; - $form->select_types_paiements(isset($_POST['mode_reglement_id']) ? $_POST['mode_reglement_id'] : $mode_reglement_id, 'mode_reglement_id'); + $form->select_types_paiements(GETPOSTISSET('mode_reglement_id') ? GETPOST('mode_reglement_id') : $mode_reglement_id, 'mode_reglement_id'); print ''; // Planned delivery date @@ -2002,7 +2035,7 @@ if ($action == 'create') { $morehtmlref .= '
    '; $morehtmlref .= ''; $morehtmlref .= ''; - $morehtmlref .= $formproject->select_projects((empty($conf->global->PROJECT_CAN_ALWAYS_LINK_TO_ALL_SUPPLIERS) ? $object->socid : -1), $object->fk_project, 'projectid', 0, 0, 1, 0, 1, 0, 0, '', 1, 0, 'maxwidth500'); + $morehtmlref .= $formproject->select_projects((empty($conf->global->PROJECT_CAN_ALWAYS_LINK_TO_ALL_SUPPLIERS) ? $object->socid : -1), $object->fk_project, 'projectid', 0, 0, 1, 1, 1, 0, 0, '', 1, 0, 'maxwidth500'); $morehtmlref .= ''; $morehtmlref .= '
    '; } else { @@ -2012,9 +2045,10 @@ if ($action == 'create') { if (!empty($object->fk_project)) { $proj = new Project($db); $proj->fetch($object->fk_project); - $morehtmlref .= ''; - $morehtmlref .= $proj->ref; - $morehtmlref .= ''; + $morehtmlref .= ' : '.$proj->getNomUrl(1); + if ($proj->title) { + $morehtmlref .= ' - '.$proj->title; + } } else { $morehtmlref .= ''; } @@ -2504,7 +2538,7 @@ if ($action == 'create') { } if (in_array($object->statut, array(3, 4, 5))) { - if (((!empty($conf->fournisseur->enabled) && empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD)) || !empty($conf->supplier_order->enabled)) && $usercanreceived) { + if (((!empty($conf->fournisseur->enabled) && empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD)) || !empty($conf->supplier_order->enabled)) && $usercanreceive) { print ''; } else { print ''; @@ -2522,7 +2556,7 @@ if ($action == 'create') { // Classify received (this does not record reception) if ($object->statut == CommandeFournisseur::STATUS_ORDERSENT || $object->statut == CommandeFournisseur::STATUS_RECEIVED_PARTIALLY) { - if ($usercanreceived) { + if ($usercanreceive) { print ''; } } @@ -2563,14 +2597,14 @@ if ($action == 'create') { } // Cancel - if ($object->statut == 2) { + if ($object->statut == CommandeFournisseur::STATUS_ACCEPTED) { if ($usercanorder) { print ''.$langs->trans("CancelOrder").''; } } // Delete - if (!empty($usercandelete) || ($object->statut == CommandeFournisseur::STATUS_DRAFT && !empty($usercancreate))) { + if (!empty($usercandelete)) { if ($hasreception) { print ''.$langs->trans("Delete").''; } else { @@ -2641,7 +2675,7 @@ if ($action == 'create') { print '
    '; if ($action == 'classifyreception') { - if ($usercanreceived && ($object->statut == CommandeFournisseur::STATUS_ORDERSENT || $object->statut == CommandeFournisseur::STATUS_RECEIVED_PARTIALLY)) { + if ($usercanreceive && ($object->statut == CommandeFournisseur::STATUS_ORDERSENT || $object->statut == CommandeFournisseur::STATUS_RECEIVED_PARTIALLY)) { // Set status to received (action=livraison) print ''."\n"; print '
    '; diff --git a/htdocs/fourn/commande/contact.php b/htdocs/fourn/commande/contact.php index 8d9fc8f57c6..e521caf1080 100644 --- a/htdocs/fourn/commande/contact.php +++ b/htdocs/fourn/commande/contact.php @@ -158,9 +158,10 @@ if ($id > 0 || !empty($ref)) { if (!empty($object->fk_project)) { $proj = new Project($db); $proj->fetch($object->fk_project); - $morehtmlref .= ''; - $morehtmlref .= $proj->ref; - $morehtmlref .= ''; + $morehtmlref .= ' : '.$proj->getNomUrl(1); + if ($proj->title) { + $morehtmlref .= ' - '.$proj->title; + } } else { $morehtmlref .= ''; } diff --git a/htdocs/fourn/commande/dispatch.php b/htdocs/fourn/commande/dispatch.php index 7192f976219..ca9bd1b3065 100644 --- a/htdocs/fourn/commande/dispatch.php +++ b/htdocs/fourn/commande/dispatch.php @@ -10,19 +10,18 @@ * Copyright (C) 2018 Frédéric France * Copyright (C) 2019-2020 Christophe Battarel * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or * (at your option) any later version. * - * This program is distributed in the hope that it will be useful, + * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . - * or see https://www.gnu.org/ */ /** @@ -63,11 +62,6 @@ $confirm = GETPOST('confirm', 'alpha'); if ($user->socid) { $socid = $user->socid; } -$result = restrictedArea($user, 'fournisseur', $id, 'commande_fournisseur', 'commande'); - -if (empty($conf->stock->enabled)) { - accessforbidden(); -} $hookmanager->initHooks(array('ordersupplierdispatch')); @@ -90,6 +84,21 @@ if ($id > 0 || !empty($ref)) { } } +if (empty($conf->reception->enabled)) { + $permissiontoreceive = $user->rights->fournisseur->commande->receptionner; + $permissiontocontrol = ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($user->rights->fournisseur->commande->receptionner)) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($user->rights->fournisseur->commande_advance->check))); +} else { + $permissiontoreceive = $user->rights->reception->creer; + $permissiontocontrol = ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($user->rights->reception->creer)) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && !empty($user->rights->reception->reception_advance->validate))); +} + +// $id is id of a purchase order. +$result = restrictedArea($user, 'fournisseur', $id, 'commande_fournisseur', 'commande'); + +if (empty($conf->stock->enabled)) { + accessforbidden(); +} + /* * Actions @@ -101,7 +110,7 @@ if ($reshook < 0) { setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); } -if ($action == 'checkdispatchline' && !((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && empty($user->rights->fournisseur->commande->receptionner)) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && empty($user->rights->fournisseur->commande_advance->check)))) { +if ($action == 'checkdispatchline' && $permissiontocontrol) { $error = 0; $supplierorderdispatch = new CommandeFournisseurDispatch($db); @@ -138,7 +147,7 @@ if ($action == 'checkdispatchline' && !((empty($conf->global->MAIN_USE_ADVANCED_ } } -if ($action == 'uncheckdispatchline' && !((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && empty($user->rights->fournisseur->commande->receptionner)) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && empty($user->rights->fournisseur->commande_advance->check)))) { +if ($action == 'uncheckdispatchline' && $permissiontocontrol) { $error = 0; $supplierorderdispatch = new CommandeFournisseurDispatch($db); @@ -174,7 +183,7 @@ if ($action == 'uncheckdispatchline' && !((empty($conf->global->MAIN_USE_ADVANCE } } -if ($action == 'denydispatchline' && !((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && empty($user->rights->fournisseur->commande->receptionner)) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && empty($user->rights->fournisseur->commande_advance->check)))) { +if ($action == 'denydispatchline' && $permissiontocontrol) { $error = 0; $supplierorderdispatch = new CommandeFournisseurDispatch($db); @@ -210,7 +219,7 @@ if ($action == 'denydispatchline' && !((empty($conf->global->MAIN_USE_ADVANCED_P } } -if ($action == 'dispatch' && $user->rights->fournisseur->commande->receptionner) { +if ($action == 'dispatch' && $permissiontoreceive) { $error = 0; $db->begin(); @@ -296,8 +305,8 @@ if ($action == 'dispatch' && $user->rights->fournisseur->commande->receptionner) $pu = 'pu_'.$reg[1].'_'.$reg[2]; $fk_commandefourndet = 'fk_commandefourndet_'.$reg[1].'_'.$reg[2]; $lot = 'lot_number_'.$reg[1].'_'.$reg[2]; - $dDLUO = dol_mktime(12, 0, 0, $_POST['dluo_'.$reg[1].'_'.$reg[2].'month'], $_POST['dluo_'.$reg[1].'_'.$reg[2].'day'], $_POST['dluo_'.$reg[1].'_'.$reg[2].'year']); - $dDLC = dol_mktime(12, 0, 0, $_POST['dlc_'.$reg[1].'_'.$reg[2].'month'], $_POST['dlc_'.$reg[1].'_'.$reg[2].'day'], $_POST['dlc_'.$reg[1].'_'.$reg[2].'year']); + $dDLUO = dol_mktime(12, 0, 0, GETPOST('dluo_'.$reg[1].'_'.$reg[2].'month', 'int'), GETPOST('dluo_'.$reg[1].'_'.$reg[2].'day', 'int'), GETPOST('dluo_'.$reg[1].'_'.$reg[2].'year', 'int')); + $dDLC = dol_mktime(12, 0, 0, GETPOST('dlc_'.$reg[1].'_'.$reg[2].'month', 'int'), GETPOST('dlc_'.$reg[1].'_'.$reg[2].'day', 'int'), GETPOST('dlc_'.$reg[1].'_'.$reg[2].'year', 'int')); $fk_commandefourndet = 'fk_commandefourndet_'.$reg[1].'_'.$reg[2]; @@ -388,7 +397,7 @@ if ($action == 'dispatch' && $user->rights->fournisseur->commande->receptionner) } // Remove a dispatched line -if ($action == 'confirm_deleteline' && $confirm == 'yes' && $user->rights->fournisseur->commande->receptionner) { +if ($action == 'confirm_deleteline' && $confirm == 'yes' && $permissiontoreceive) { $db->begin(); $supplierorderdispatch = new CommandeFournisseurDispatch($db); @@ -431,7 +440,7 @@ if ($action == 'confirm_deleteline' && $confirm == 'yes' && $user->rights->fourn } // Update a dispatched line -if ($action == 'updateline' && $user->rights->fournisseur->commande->receptionner) { +if ($action == 'updateline' && $permissiontoreceive) { $db->begin(); $error = 0; @@ -565,9 +574,10 @@ if ($id > 0 || !empty($ref)) { if (!empty($object->fk_project)) { $proj = new Project($db); $proj->fetch($object->fk_project); - $morehtmlref .= ''; - $morehtmlref .= $proj->ref; - $morehtmlref .= ''; + $morehtmlref .= ' : '.$proj->getNomUrl(1); + if ($proj->title) { + $morehtmlref .= ' - '.$proj->title; + } } else { $morehtmlref .= ''; } @@ -612,10 +622,11 @@ if ($id > 0 || !empty($ref)) { // if ($mesg) print $mesg; print '
    '; - $disabled = 1; + /*$disabled = 1; if (!empty($conf->global->STOCK_CALCULATE_ON_SUPPLIER_DISPATCH_ORDER)) { $disabled = 0; - } + }*/ + $disabled = 0; // This is used to disable or not the bulk selection of target warehouse. No reason to have it disabled so forced to 0. // Line of orders if ($object->statut <= CommandeFournisseur::STATUS_ACCEPTED || $object->statut >= CommandeFournisseur::STATUS_CANCELED) { @@ -751,9 +762,9 @@ if ($id > 0 || !empty($ref)) { // Select warehouse to force it everywhere if (count($listwarehouses) > 1) { - print '
    '.$langs->trans("ForceTo").' '.$form->selectarray('fk_default_warehouse', $listwarehouses, $fk_default_warehouse, 1, 0, 0, '', 0, 0, $disabled, '', 'minwidth100 maxwidth300', 1); + print '
    '.$langs->trans("ForceTo").' '.$form->selectarray('fk_default_warehouse', $listwarehouses, $fk_default_warehouse, 1, 0, 0, '', 0, 0, $disabled, '', 'minwidth100 maxwidth300', 1); } elseif (count($listwarehouses) == 1) { - print '
    '.$langs->trans("ForceTo").' '.$form->selectarray('fk_default_warehouse', $listwarehouses, $fk_default_warehouse, 0, 0, 0, '', 0, 0, $disabled, '', 'minwidth100 maxwidth300', 1); + print '
    '.$langs->trans("ForceTo").' '.$form->selectarray('fk_default_warehouse', $listwarehouses, $fk_default_warehouse, 0, 0, 0, '', 0, 0, $disabled, '', 'minwidth100 maxwidth300', 1); } print ''; @@ -778,6 +789,8 @@ if ($id > 0 || !empty($ref)) { $nbproduct = 0; // Nb of predefined product lines to dispatch (already done or not) if SUPPLIER_ORDER_DISABLE_STOCK_DISPATCH_WHEN_TOTAL_REACHED is off (default) // or nb of line that remain to dispatch if SUPPLIER_ORDER_DISABLE_STOCK_DISPATCH_WHEN_TOTAL_REACHED is on. + $conf->cache['product'] = array(); + while ($i < $num) { $objp = $db->fetch_object($resql); @@ -805,11 +818,20 @@ if ($id > 0 || !empty($ref)) { print ''; print ''; - $linktoprod = ''.img_object($langs->trans("ShowProduct"), 'product').' '.$objp->ref.''; + if (empty($conf->cache['product'][$objp->fk_product])) { + $tmpproduct = new Product($db); + $tmpproduct->fetch($objp->fk_product); + $conf->cache['product'][$objp->fk_product] = $tmpproduct; + } else { + $tmpproduct = $conf->cache['product'][$objp->fk_product]; + } + + $linktoprod = $tmpproduct->getNomUrl(1); $linktoprod .= ' - '.$objp->label."\n"; if (!empty($conf->productbatch->enabled)) { if ($objp->tobatch) { + // Product print ''; print $linktoprod; print ""; @@ -821,6 +843,7 @@ if ($id > 0 || !empty($ref)) { print ''; } } else { + // Product print ''; print $linktoprod; print ""; @@ -1055,10 +1078,19 @@ if ($id > 0 || !empty($ref)) { $dispatchBt = empty($conf->reception->enabled) ? $langs->trans("Receive") : $langs->trans("CreateReception"); - print '
    '; + print ''; } print '
    '; @@ -1131,10 +1163,11 @@ if ($id > 0 || !empty($ref)) { print ''; print ''; + // Reception ref if ($conf->reception->enabled) { print ''; } - + // Product print ''; print ''; print ''; @@ -1162,9 +1195,14 @@ if ($id > 0 || !empty($ref)) { print "\n"; + while ($i < $num) { $objp = $db->fetch_object($resql); + $tmpproduct->id = $objp->fk_product; + $tmpproduct->ref = $objp->ref; + $tmpproduct->label = $objp->label; + if ($action == 'editline' && $lineid == $objp->dispatchlineid) { print ' @@ -1175,6 +1213,7 @@ if ($id > 0 || !empty($ref)) { print ''; + // Reception ref if (!empty($conf->reception->enabled)) { print '"; } + // Product print '\n"; print ''; @@ -1257,7 +1304,7 @@ if ($id > 0 || !empty($ref)) { // Add button to check/uncheck disaptching print ''; + print "
    '.$langs->trans("Reception").''.$langs->trans("Product").''.$langs->trans("DateCreation").''.$langs->trans("DateDeliveryPlanned").'
    '; if (!empty($objp->fk_reception)) { @@ -1186,8 +1225,16 @@ if ($id > 0 || !empty($ref)) { print "'; - print ''.img_object($langs->trans("ShowProduct"), 'product').' '.$objp->ref.''; + if (empty($conf->cache['product'][$objp->fk_product])) { + $tmpproduct = new Product($db); + $tmpproduct->fetch($objp->fk_product); + $conf->cache['product'][$objp->fk_product] = $tmpproduct; + } else { + $tmpproduct = $conf->cache['product'][$objp->fk_product]; + } + print $tmpproduct->getNomUrl(1); print ' - '.$objp->label; print "'.dol_print_date($db->jdate($objp->datec), 'day').''; - if ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && empty($user->rights->fournisseur->commande->receptionner)) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && empty($user->rights->fournisseur->commande_advance->check))) { + if (!$permissiontocontrol) { if (empty($objp->status)) { print ''.$langs->trans("Approve").''; print ''.$langs->trans("Deny").''; diff --git a/htdocs/fourn/commande/document.php b/htdocs/fourn/commande/document.php index 993830eb539..d54d5553efb 100644 --- a/htdocs/fourn/commande/document.php +++ b/htdocs/fourn/commande/document.php @@ -48,8 +48,8 @@ $confirm = GETPOST('confirm', 'alpha'); // Get parameters $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; @@ -154,9 +154,10 @@ if ($object->id > 0) { if (!empty($object->fk_project)) { $proj = new Project($db); $proj->fetch($object->fk_project); - $morehtmlref .= ''; - $morehtmlref .= $proj->ref; - $morehtmlref .= ''; + $morehtmlref .= ' : '.$proj->getNomUrl(1); + if ($proj->title) { + $morehtmlref .= ' - '.$proj->title; + } } else { $morehtmlref .= ''; } diff --git a/htdocs/fourn/commande/info.php b/htdocs/fourn/commande/info.php index bb8dc302b1c..6c64672ee84 100644 --- a/htdocs/fourn/commande/info.php +++ b/htdocs/fourn/commande/info.php @@ -41,8 +41,8 @@ $ref = GETPOST('ref', 'alpha'); $action = GETPOST('action', 'aZ09'); $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; @@ -162,9 +162,10 @@ if (!empty($conf->projet->enabled)) { if (!empty($object->fk_project)) { $proj = new Project($db); $proj->fetch($object->fk_project); - $morehtmlref .= ''; - $morehtmlref .= $proj->ref; - $morehtmlref .= ''; + $morehtmlref .= ' : '.$proj->getNomUrl(1); + if ($proj->title) { + $morehtmlref .= ' - '.$proj->title; + } } else { $morehtmlref .= ''; } diff --git a/htdocs/fourn/commande/list.php b/htdocs/fourn/commande/list.php index 419e75b55aa..e5cc12fe1c4 100644 --- a/htdocs/fourn/commande/list.php +++ b/htdocs/fourn/commande/list.php @@ -135,8 +135,8 @@ $result = restrictedArea($user, 'fournisseur', $orderid, '', 'commande'); $diroutputmassaction = $conf->fournisseur->commande->dir_output.'/temp/massgeneration/'.$user->id; $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1 || !empty($search_btn) || !empty($search_remove_btn) || (empty($toselect) && $massaction === '0')) { $page = 0; @@ -738,7 +738,7 @@ $help_url = ''; // llxHeader('',$title,$help_url); $sql = 'SELECT'; -if ($sall || $search_product_category > 0 || $search_user > 0) { +if ($sall || $search_product_category > 0) { $sql = 'SELECT DISTINCT'; } $sql .= ' s.rowid as socid, s.nom as name, s.town, s.zip, s.fk_pays, s.client, s.code_client, s.email,'; @@ -765,7 +765,7 @@ $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."c_country as country on (country.rowid = s $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."c_typent as typent on (typent.id = s.fk_typent)"; $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."c_departements as state on (state.rowid = s.fk_departement)"; $sql .= ", ".MAIN_DB_PREFIX."commande_fournisseur as cf"; -if (is_array($extrafields->attributes[$object->table_element]['label']) && count($extrafields->attributes[$object->table_element]['label'])) { +if (!empty($extrafields->attributes[$object->table_element]['label']) && is_array($extrafields->attributes[$object->table_element]['label']) && count($extrafields->attributes[$object->table_element]['label'])) { $sql .= " LEFT JOIN ".MAIN_DB_PREFIX.$object->table_element."_extrafields as ef on (cf.rowid = ef.fk_object)"; } if ($sall || $search_product_category > 0) { @@ -780,10 +780,6 @@ $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."projet as p ON p.rowid = cf.fk_projet"; if ($search_sale > 0 || (empty($user->rights->societe->client->voir) && !$socid)) { $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; } -if ($search_user > 0) { - $sql .= ", ".MAIN_DB_PREFIX."element_contact as ec"; - $sql .= ", ".MAIN_DB_PREFIX."c_type_contact as tc"; -} $parameters = array(); $reshook = $hookmanager->executeHooks('printFieldListFrom', $parameters, $object); // Note that $action and $object may have been modified by hook $sql .= $hookmanager->resPrint; @@ -869,7 +865,13 @@ if ($search_sale > 0) { $sql .= " AND s.rowid = sc.fk_soc AND sc.fk_user = ".((int) $search_sale); } if ($search_user > 0) { - $sql .= " AND ec.fk_c_type_contact = tc.rowid AND tc.element='supplier_order' AND tc.source='internal' AND ec.element_id = cf.rowid AND ec.fk_socpeople = ".((int) $search_user); + $sql .= " AND EXISTS ("; + $sql .= " SELECT ec.rowid "; + $sql .= " FROM " . MAIN_DB_PREFIX . "element_contact as ec"; + $sql .= " INNER JOIN " . MAIN_DB_PREFIX . "c_type_contact as tc ON tc.rowid = ec.fk_c_type_contact"; + $sql .= " WHERE ec.element_id = cf.rowid AND ec.fk_socpeople = " . ((int) $search_user); + $sql .= " AND tc.element = 'order_supplier' AND tc.source = 'internal'"; + $sql .= ")"; } if ($search_total_ht != '') { $sql .= natural_search('cf.total_ht', $search_total_ht, 1); @@ -1200,14 +1202,14 @@ if ($resql) { $langs->load("commercial"); $moreforfilter .= '
    '; $tmptitle = $langs->trans('ThirdPartiesOfSaleRepresentative'); - $moreforfilter .= img_picto($tmptitle, 'user', 'class="pictofixedwidth"').$formother->select_salesrepresentatives($search_sale, 'search_sale', $user, 0, $tmptitle, 'maxwidth250'); + $moreforfilter .= img_picto($tmptitle, 'user', 'class="pictofixedwidth"').$formother->select_salesrepresentatives($search_sale, 'search_sale', $user, 0, $tmptitle, 'maxwidth250 widthcentpercentminusx'); $moreforfilter .= '
    '; } // If the user can view other users if ($user->rights->user->user->lire) { $moreforfilter .= '
    '; $tmptitle = $langs->trans('LinkedToSpecificUsers'); - $moreforfilter .= img_picto($tmptitle, 'user', 'class="pictofixedwidth"').$form->select_dolusers($search_user, 'search_user', $tmptitle, '', 0, '', '', 0, 0, 0, '', 0, '', 'maxwidth250'); + $moreforfilter .= img_picto($tmptitle, 'user', 'class="pictofixedwidth"').$form->select_dolusers($search_user, 'search_user', $tmptitle, '', 0, '', '', 0, 0, 0, '', 0, '', 'maxwidth250 widthcentpercentminusx'); $moreforfilter .= '
    '; } // If the user can view prospects other than his' @@ -1216,7 +1218,7 @@ if ($resql) { $moreforfilter .= '
    '; $tmptitle = $langs->trans('IncludingProductWithTag'); $cate_arbo = $form->select_all_categories(Categorie::TYPE_PRODUCT, null, 'parent', null, null, 1); - $moreforfilter .= img_picto($tmptitle, 'category', 'class="pictofixedwidth"').$form->selectarray('search_product_category', $cate_arbo, $search_product_category, $tmptitle, 0, 0, '', 0, 0, 0, 0, 'maxwidth300', 1); + $moreforfilter .= img_picto($tmptitle, 'category', 'class="pictofixedwidth"').$form->selectarray('search_product_category', $cate_arbo, $search_product_category, $tmptitle, 0, 0, '', 0, 0, 0, 0, 'maxwidth300 widthcentpercentminusx', 1); $moreforfilter .= '
    '; } $parameters = array(); @@ -1530,9 +1532,7 @@ if ($resql) { $projectstatic = new Project($db); $i = 0; - $totalarray = array(); - $totalarray['nbfield'] = 0; - $totalarray['val'] = array(); + $totalarray = array('nbfield' => 0, 'val' => array(), 'pos' => array()); $totalarray['val']['cf.total_ht'] = 0; $totalarray['val']['cf.total_ttc'] = 0; while ($i < min($num, $limit)) { diff --git a/htdocs/fourn/commande/note.php b/htdocs/fourn/commande/note.php index f19943a3244..1c67c03d727 100644 --- a/htdocs/fourn/commande/note.php +++ b/htdocs/fourn/commande/note.php @@ -129,9 +129,10 @@ if ($id > 0 || !empty($ref)) { if (!empty($object->fk_project)) { $proj = new Project($db); $proj->fetch($object->fk_project); - $morehtmlref .= ''; - $morehtmlref .= $proj->ref; - $morehtmlref .= ''; + $morehtmlref .= ' : '.$proj->getNomUrl(1); + if ($proj->title) { + $morehtmlref .= ' - '.$proj->title; + } } else { $morehtmlref .= ''; } diff --git a/htdocs/fourn/contact.php b/htdocs/fourn/contact.php index cabf726beee..9d6e3abd4cf 100644 --- a/htdocs/fourn/contact.php +++ b/htdocs/fourn/contact.php @@ -41,8 +41,8 @@ if ($user->socid > 0) { } $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/fourn/facture/card-rec.php b/htdocs/fourn/facture/card-rec.php new file mode 100644 index 00000000000..502d0d124ce --- /dev/null +++ b/htdocs/fourn/facture/card-rec.php @@ -0,0 +1,1644 @@ + + * Copyright (C) 2004-2016 Laurent Destailleur + * Copyright (C) 2005-2012 Regis Houssin + * Copyright (C) 2013 Florian Henry + * Copyright (C) 2013 Juanjo Menent + * Copyright (C) 2015 Jean-François Ferry + * Copyright (C) 2012 Cedric Salvador + * Copyright (C) 2015 Alexandre Spangaro + * Copyright (C) 2016 Meziane Sof + * Copyright (C) 2017-2018 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 + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file htdocs/fourn/facture/card-rec.php + * \ingroup facture fournisseurs + * \brief Page to show predefined invoice + */ + +require '../../main.inc.php'; +require_once DOL_DOCUMENT_ROOT . '/fourn/class/fournisseur.facture-rec.class.php'; +require_once DOL_DOCUMENT_ROOT . '/fourn/class/fournisseur.product.class.php'; +require_once DOL_DOCUMENT_ROOT . '/product/class/product.class.php'; +require_once DOL_DOCUMENT_ROOT . '/core/class/html.formother.class.php'; +if (! empty($conf->projet->enabled)) { + include_once DOL_DOCUMENT_ROOT . '/projet/class/project.class.php'; +} +require_once DOL_DOCUMENT_ROOT . '/core/class/html.formprojet.class.php'; +require_once DOL_DOCUMENT_ROOT . '/core/class/doleditor.class.php'; +require_once DOL_DOCUMENT_ROOT . '/core/lib/invoice.lib.php'; +require_once DOL_DOCUMENT_ROOT . '/core/class/extrafields.class.php'; + +// Load translation files required by the page +$langs->loadLangs(array('bills', 'companies', 'compta', 'admin', 'other', 'products', 'banks', 'suppliers')); + +$action = GETPOST('action', 'alpha'); +$massaction = GETPOST('massaction', 'alpha'); +$show_files = GETPOST('show_files', 'int'); +$confirm = GETPOST('confirm', 'alpha'); +$cancel = GETPOST('cancel', 'alpha'); +$toselect = GETPOST('toselect', 'array'); +$contextpage = GETPOST('contextpage', 'aZ') ? GETPOST('contextpage', 'aZ') : 'supplierinvoicetemplatelist'; // To manage different context of search + +$limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; +$sortfield = GETPOST("sortfield", 'alpha'); +$sortorder = GETPOST("sortorder", 'alpha'); +$page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); + +// Security check +$id = (GETPOST('facid', 'int') ? GETPOST('facid', 'int') : GETPOST('id', 'int')); +$lineid = GETPOST('lineid', 'int'); +$title = GETPOST('title', 'alpha'); +$ref_supplier = GETPOST('ref_supplier', 'alpha'); +$projectid = GETPOST('projectid', 'int'); +$year_date_when = GETPOST('year_date_when'); +$month_date_when = GETPOST('month_date_when'); +if ($user->socid) { + $socid = $user->socid; +} +$objecttype = 'facturefournisseur_rec'; +if ($action == "create" || $action == "add") { + $objecttype = ''; +} + +if (empty($page) || $page == -1) { + $page = 0; +} // If $page is not defined, or '' or -1 +$offset = $limit * $page; +if (! $sortorder) { + $sortorder = 'DESC'; +} +if (! $sortfield) { + $sortfield = 'f.titre'; +} +$pageprev = $page - 1; +$pagenext = $page + 1; + +$object = new FactureFournisseurRec($db); +if (($id > 0 || $title) && $action != 'create' && $action != 'add') { + $ret = $object->fetch($id, $title); + if (! $ret) { + setEventMessages($langs->trans("ErrorRecordNotFound"), null, 'errors'); + } +} + +// Initialize technical object to manage hooks of page. Note that conf->hooks_modules contains array of hook context +$hookmanager->initHooks(array('supplierinvoicereccard', 'globalcard')); +$extrafields = new ExtraFields($db); + +// fetch optionals attributes and labels +$extrafields->fetch_name_optionals_label($object->table_element); + +$search_array_options = $extrafields->getOptionalsFromPost($object->table_element, '', 'search_'); + +$permissionnote = $user->rights->fournisseur->facture->creer || $user->rights->supplier_invoice->creer; // Used by the include of actions_setnotes.inc.php +$permissiondellink = $user->rights->fournisseur->facture->creer || $user->rights->supplier_invoice->creer;; // Used by the include of actions_dellink.inc.php +$permissiontoedit = $user->rights->fournisseur->facture->creer || $user->rights->supplier_invoice->creer;; // Used by the include of actions_lineupdonw.inc.php + +$usercanread = $user->rights->fournisseur->facture->lire || $user->rights->supplier_invoice->lire; +$usercancreate = $user->rights->fournisseur->facture->creer || $user->rights->supplier_invoice->creer; +$usercandelete = $user->rights->fournisseur->facture->supprimer || $user->rights->supplier_invoice->supprimer; +$usercanvalidate = ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && ! empty($usercancreate)) || (! empty($conf->global->MAIN_USE_ADVANCED_PERMS) && ! empty($user->rights->fournisseur->supplier_invoice_advance->validate))); +$usercansend = (empty($conf->global->MAIN_USE_ADVANCED_PERMS) || $user->rights->fournisseur->supplier_invoice_advance->send); + +$usercanproductignorepricemin = ((! empty($conf->global->MAIN_USE_ADVANCED_PERMS) && empty($user->rights->produit->ignore_price_min_advance)) || empty($conf->global->MAIN_USE_ADVANCED_PERMS)); +$usercancreatemargin = $user->rights->margins->creer; +$usercanreadallmargin = $user->rights->margins->liretous; +$usercancreatewithdrarequest = $user->rights->prelevement->bons->creer; + +$now = dol_now(); + +$error = 0; + +$result = restrictedArea($user, 'facture', $object->id, $objecttype); + +/* + * Actions + */ + +if (GETPOST('cancel', 'alpha')) { + $action = 'list'; + $massaction = ''; +} +if (! GETPOST('confirmmassaction', 'alpha') && $massaction != 'presend' && $massaction != 'confirm_presend') { + $massaction = ''; +} + +$parameters = array('socid' => $socid); +$reshook = $hookmanager->executeHooks('doActions', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks +if ($reshook < 0) { + setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); +} + +if (empty($reshook)) { + if (GETPOST('cancel', 'alpha')) { + $action = ''; + } + + // Selection of new fields + include DOL_DOCUMENT_ROOT . '/core/actions_changeselectedfields.inc.php'; + + // Set note + include DOL_DOCUMENT_ROOT . '/core/actions_setnotes.inc.php'; // Must be include, not include_once + + include DOL_DOCUMENT_ROOT . '/core/actions_dellink.inc.php'; // Must be include, not include_once + + include DOL_DOCUMENT_ROOT . '/core/actions_lineupdown.inc.php'; // Must be include, not include_once + + // Create predefined invoice + if ($action == 'add') { + if (! GETPOST('title', 'alphanohtml')) { + setEventMessages($langs->transnoentities("ErrorFieldRequired", $langs->trans("Title")), null, 'errors'); + $action = "create"; + $error++; + } + + $frequency = GETPOST('frequency', 'int'); + $reyear = GETPOST('reyear', 'int'); + $remonth = GETPOST('remonth', 'int'); + $reday = GETPOST('reday', 'int'); + $rehour = GETPOST('rehour', 'int'); + $remin = GETPOST('remin', 'int'); + $nb_gen_max = GETPOST('nb_gen_max', 'int'); + //if (empty($nb_gen_max)) $nb_gen_max =0; + + if (GETPOST('frequency', 'int')) { + if (empty($reyear) || empty($remonth) || empty($reday)) { + setEventMessages($langs->transnoentities("ErrorFieldRequired", $langs->trans("Date")), null, 'errors'); + $action = "create"; + $error++; + } + } + + if (! $error) { + $object->titre = GETPOST('title', 'nohtml'); // deprecated + $object->title = GETPOST('title', 'nohtml'); + $object->fk_project = GETPOST('projectid', 'int'); + $object->ref_supplier = GETPOST('ref_supplier', 'nohtml'); + + $object->note_private = GETPOST('note_private', 'restricthtml'); + $object->note_public = GETPOST('note_public', 'restricthtml'); + $object->model_pdf = GETPOST('modelpdf', 'alpha'); + $object->usenewprice = GETPOST('usenewprice', 'alpha'); + + $object->frequency = $frequency; + $object->unit_frequency = GETPOST('unit_frequency', 'alpha'); + $object->nb_gen_max = $nb_gen_max; + $object->auto_validate = GETPOST('auto_validate', 'int'); + $object->generate_pdf = GETPOST('generate_pdf', 'int'); + + $date_next_execution = dol_mktime($rehour, $remin, 0, $remonth, $reday, $reyear); + $object->date_when = $date_next_execution; + + $db->begin(); + + $oldinvoice = new FactureFournisseur($db); + $oldinvoice->fetch(GETPOST('facid', 'int')); + + $object->cond_reglement_id = $oldinvoice->cond_reglement_id; + $object->cond_reglement_code = $oldinvoice->cond_reglement_code; + $object->cond_reglement_label = $oldinvoice->cond_reglement_label; + $object->cond_reglement_doc = $oldinvoice->cond_reglement_doc; + $object->mode_reglement_id = $oldinvoice->mode_reglement_id; + $object->mode_reglement_code = $oldinvoice->mode_reglement_code; + + $result = $object->create($user, $oldinvoice->id); + if ($result > 0) { + $result = $oldinvoice->delete($user, 1); + if ($result < 0) { + $error++; + setEventMessages($oldinvoice->error, $oldinvoice->errors, 'errors'); + $action = "create"; + } + } else { + $error++; + setEventMessages($object->error, $object->errors, 'errors'); + $action = "create"; + } + + if (! $error) { + $db->commit(); + + header("Location: " . $_SERVER['PHP_SELF'] . '?facid=' . $object->id); + exit; + } else { + $db->rollback(); + + $error++; + setEventMessages($object->error, $object->errors, 'errors'); + $action = "create"; + } + } + } + + // Delete + //TODO : Droits + if ($action == 'confirm_deleteinvoice' && $confirm == 'yes' && ($user->rights->fournisseur->facture->supprimer || $user->rights->supplier_invoice->supprimer)) { + $object->delete($user); + + header('Location: ' . DOL_URL_ROOT . '/fourn/facture/list-rec.php'); + exit; + } + + // Update field + // Set condition + if ($action == 'setconditions' && $usercancreate) { + $result = $object->setPaymentTerms(GETPOST('cond_reglement_id', 'int')); + } elseif ($action == 'setmode' && $usercancreate) { + // Set mode + $result = $object->setPaymentMethods(GETPOST('mode_reglement_id', 'int')); + } elseif ($action == 'classin' && $usercancreate) { + // Set project + $object->setProject(GETPOST('projectid', 'int')); + } elseif ($action == 'setref_supplier' && $usercancreate) { + $result = $object->setValueFrom('ref_supplier', $ref_supplier, '', null, 'text', '', $user); + + if ($result <= 0) { + $error++; + if ($object->error == 'DB_ERROR_RECORD_ALREADY_EXISTS') { + $langs->load("errors"); + setEventMessages($langs->trans('ErrorRefAlreadyExists', $ref_supplier), null, 'errors'); + } else { + setEventMessages($object->error, $object->errors, 'errors'); + } + } + } elseif ($action == 'settitle' && $usercancreate) { + $result = $object->setValueFrom('titre', $title, '', null, 'text', '', $user); + + if ($result > 0) { + $object->titre = $title; + $object->title = $title; + $object->ref = $object->title; + } else { + $error++; + if ($object->error == 'DB_ERROR_RECORD_ALREADY_EXISTS') { + $langs->load("errors"); + setEventMessages($langs->trans('ErrorTitreAlreadyExists', $title), null, 'errors'); + } else { + setEventMessages($object->error, $object->errors, 'errors'); + } + } + } elseif ($action == 'setbankaccount' && $usercancreate) { + // Set bank account + $result = $object->setBankAccount(GETPOST('fk_account', 'int')); + } elseif ($action == 'setfrequency' && $usercancreate) { + // Set frequency and unit frequency + $object->setFrequencyAndUnit(GETPOST('frequency', 'int'), GETPOST('unit_frequency', 'alpha')); + } elseif ($action == 'setdate_when' && $usercancreate) { + // Set next date of execution + $date = dol_mktime(GETPOST('date_whenhour'), GETPOST('date_whenmin'), 0, GETPOST('date_whenmonth'), GETPOST('date_whenday'), GETPOST('date_whenyear')); + if (! empty($date)) { + $object->setNextDate($date); + } + } elseif ($action == 'setnb_gen_max' && $usercancreate) { + // Set max period + $object->setMaxPeriod(GETPOST('nb_gen_max', 'int')); + } elseif ($action == 'setauto_validate' && $usercancreate) { + // Set auto validate + $object->setAutoValidate(GETPOST('auto_validate', 'int')); + } elseif ($action == 'setgenerate_pdf' && $usercancreate) { + // Set generate pdf + $object->setGeneratepdf(GETPOST('generate_pdf', 'int')); + } elseif ($action == 'setmodelpdf' && $usercancreate) { + // Set model pdf + $object->setModelpdf(GETPOST('modelpdf', 'alpha')); + } elseif ($action == 'disable' && $usercancreate) { + // Set status disabled + $db->begin(); + + $object->fetch($id); + + $res = $object->setValueFrom('suspended', 1); + if ($res <= 0) { + $error++; + } + + if (! $error) { + $db->commit(); + } else { + $db->rollback(); + setEventMessages($object->error, $object->errors, 'errors'); + } + } elseif ($action == 'enable' && $usercancreate) { + // Set status enabled + $db->begin(); + + $object->fetch($id); + + $res = $object->setValueFrom('suspended', 0); + if ($res <= 0) { + $error++; + } + + if (! $error) { + $db->commit(); + } else { + $db->rollback(); + setEventMessages($object->error, $object->errors, 'errors'); + } + } elseif ($action == 'setmulticurrencycode' && $usercancreate) { + // Multicurrency Code + $result = $object->setMulticurrencyCode(GETPOST('multicurrency_code', 'alpha')); + } elseif ($action == 'setmulticurrencyrate' && $usercancreate) { + // Multicurrency rate + $result = $object->setMulticurrencyRate(price2num(GETPOST('multicurrency_tx')), GETPOST('calculation_mode', 'int')); + } elseif ($action == 'setlibelle' && $usercancreate) { + // Set label + $object->fetch($id); + $object->libelle = GETPOST('libelle'); + $result = $object->update($user); + + if ($result < 0) { + dol_print_error($db); + } + } + + // Delete line + if ($action == 'confirm_deleteline' && $confirm == 'yes' && $usercancreate) { + $object->fetch($id); + $object->fetch_thirdparty(); + + $db->begin(); + + $line = new FactureFournisseurLigneRec($db); + + // For triggers + $line->id = $lineid; + + if ($line->delete($user) > 0) { + $result = $object->update_price(1); + + if ($result > 0) { + $db->commit(); + $object->fetch($object->id); // Reload lines + } else { + $db->rollback(); + setEventMessages($db->lasterror(), null, 'errors'); + } + } else { + $db->rollback(); + setEventMessages($line->error, $line->errors, 'errors'); + } + } elseif ($action == 'update_extras') { + $object->oldcopy = dol_clone($object); + + // Fill array 'array_options' with data from update form + $ret = $extrafields->setOptionalsFromPost(null, $object, GETPOST('attribute', 'restricthtml')); + if ($ret < 0) { + $error++; + } + + if (! $error) { + $result = $object->insertExtraFields('BILLREC_MODIFY'); + if ($result < 0) { + setEventMessages($object->error, $object->errors, 'errors'); + $error++; + } + } + } + + // Add a new line + if ($action == 'addline' && $usercancreate) { + $langs->load('errors'); + $error = 0; + + // Set if we used free entry or predefined product + + $product_desc = (GETPOSTISSET('dp_desc') ? GETPOST('dp_desc', 'restricthtml') : ''); + $price_ht = price2num(GETPOST('price_ht'), 'MU', 2); + $price_ht_devise = price2num(GETPOST('multicurrency_price_ht'), 'CU', 2); + $prod_entry_mode = GETPOST('prod_entry_mode', 'alpha'); + if ($prod_entry_mode == 'free') { + $idprod = 0; + $tva_tx = (GETPOST('tva_tx', 'alpha') ? GETPOST('tva_tx', 'alpha') : 0); + $ref_fournisseur = (GETPOSTISSET('fourn_ref') ? GETPOST('fourn_ref', 'restricthtml') : ''); + } else { + $idprod = GETPOST('idprod', 'int'); + $tva_tx = ''; + } + + $qty = price2num(GETPOST('qty' . $predef, 'alpha'), 'MS', 2); + $remise_percent = price2num(GETPOST('remise_percent' . $predef), '', 2); + + // Extrafields + $extralabelsline = $extrafields->fetch_name_optionals_label($object->table_element_line); + $array_options = $extrafields->getOptionalsFromPost($object->table_element_line, $predef); + // Unset extrafield + if (is_array($extralabelsline)) { + // Get extra fields + foreach ($extralabelsline as $key => $value) { + unset($_POST["options_" . $key . $predef]); + } + } + + if ((empty($idprod) || $idprod < 0) && ($price_ht < 0) && ($qty < 0)) { + setEventMessages($langs->trans('ErrorBothFieldCantBeNegative', $langs->transnoentitiesnoconv('UnitPriceHT'), $langs->transnoentitiesnoconv('Qty')), null, 'errors'); + $error++; + } + if ($prod_entry_mode == 'free' && (empty($idprod) || $idprod < 0) && GETPOST('type') < 0) { + setEventMessages($langs->trans('ErrorFieldRequired', $langs->transnoentitiesnoconv('Type')), null, 'errors'); + $error++; + } + if ($prod_entry_mode == 'free' && (empty($idprod) || $idprod < 0) && (! ($price_ht >= 0) || $price_ht == '')) { // Unit price can be 0 but not '' + setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("UnitPriceHT")), null, 'errors'); + $error++; + } + if ($qty == '') { + setEventMessages($langs->trans('ErrorFieldRequired', $langs->transnoentitiesnoconv('Qty')), null, 'errors'); + $error++; + } + if ($prod_entry_mode == 'free' && (empty($idprod) || $idprod < 0) && empty($product_desc)) { + setEventMessages($langs->trans('ErrorFieldRequired', $langs->transnoentitiesnoconv('Description')), null, 'errors'); + $error++; + } + if ($qty < 0) { + $langs->load("errors"); + setEventMessages($langs->trans('ErrorQtyForCustomerInvoiceCantBeNegative'), null, 'errors'); + $error++; + } + + if ($prod_entry_mode != 'free' && empty($error)) { // With combolist mode idprodfournprice is > 0 or -1. With autocomplete, idprodfournprice is > 0 or '' + $productsupplier = new ProductFournisseur($db); + + $idprod = 0; + if (GETPOST('idprodfournprice', 'alpha') == -1 || GETPOST('idprodfournprice', 'alpha') == '') { + $idprod = -99; // Same behaviour than with combolist. When not select idprodfournprice is now -99 (to avoid conflict with next action that may return -1, -2, ...) + } + $reg = array(); + if (preg_match('/^idprod_([0-9]+)$/', GETPOST('idprodfournprice', 'alpha'), $reg)) { + $idprod = (int) $reg[1]; + $res = $productsupplier->fetch($idprod); // Load product from its id + // Call to init some price properties of $productsupplier + // So if a supplier price already exists for another thirdparty (first one found), we use it as reference price + if (! empty($conf->global->SUPPLIER_TAKE_FIRST_PRICE_IF_NO_PRICE_FOR_CURRENT_SUPPLIER)) { + $fksoctosearch = 0; + $productsupplier->get_buyprice(0, -1, $idprod, 'none', $fksoctosearch); // We force qty to -1 to be sure to find if a supplier price exist + if ($productsupplier->fourn_socid != $socid) { // The price we found is for another supplier, so we clear supplier price + $productsupplier->ref_supplier = ''; + } + } else { + $fksoctosearch = $object->thirdparty->id; + $productsupplier->get_buyprice(0, -1, $idprod, 'none', $fksoctosearch); // We force qty to -1 to be sure to find if a supplier price exist + } + } elseif (GETPOST('idprodfournprice', 'alpha') > 0) { + $qtytosearch = $qty; // Just to see if a price exists for the quantity. Not used to found vat. + $idprod = $productsupplier->get_buyprice(GETPOST('idprodfournprice', 'alpha'), $qtytosearch); + $res = $productsupplier->fetch($idprod); + $ref_fournisseur = $productsupplier->ref_supplier; + } + } + + if (! $error && ($qty >= 0) && (! empty($product_desc) || (! empty($idprod) && $idprod > 0))) { + $ret = $object->fetch($id); + if ($ret < 0) { + dol_print_error($db, $object->error); + exit(); + } + $ret = $object->fetch_thirdparty(); + + // Clean parameters + $date_start = dol_mktime(GETPOST('date_start' . $predef . 'hour'), GETPOST('date_start' . $predef . 'min'), GETPOST('date_start' . $predef . 'sec'), GETPOST('date_start' . $predef . 'month'), GETPOST('date_start' . $predef . 'day'), GETPOST('date_start' . $predef . 'year')); + $date_end = dol_mktime(GETPOST('date_end' . $predef . 'hour'), GETPOST('date_end' . $predef . 'min'), GETPOST('date_end' . $predef . 'sec'), GETPOST('date_end' . $predef . 'month'), GETPOST('date_end' . $predef . 'day'), GETPOST('date_end' . $predef . 'year')); + $price_base_type = (GETPOST('price_base_type', 'alpha') ? GETPOST('price_base_type', 'alpha') : 'HT'); + + // Define special_code for special lines + $special_code = 0; + // if (empty($_POST['qty'])) $special_code=3; // Options should not exists on invoices + + // Ecrase $pu par celui du produit + // Ecrase $desc par celui du produit + // Ecrase $tva_tx par celui du produit + // Ecrase $base_price_type par celui du produit + // Replaces $fk_unit with the product's + if (! empty($idprod) && $idprod > 0) { + $prod = new Product($db); + $prod->fetch($idprod); + + $label = ((GETPOST('product_label') && GETPOST('product_label') != $prod->label) ? GETPOST('product_label') : ''); + + // Update if prices fields are defined + $tva_tx = get_default_tva($mysoc, $object->thirdparty, $prod->id); + $tva_npr = get_default_npr($mysoc, $object->thirdparty, $prod->id); + if (empty($tva_tx)) { + $tva_npr = 0; + } + + // Search the correct price into loaded array product_price_by_qty using id of array retrieved into POST['pqp']. + $pqp = (GETPOST('pbq', 'int') ? GETPOST('pbq', 'int') : 0); + + $datapriceofproduct = $prod->getSellPrice($mysoc, $object->thirdparty, $pqp); + + $pu_ht = $datapriceofproduct['pu_ht']; + $pu_ttc = $datapriceofproduct['pu_ttc']; + $price_min = $datapriceofproduct['price_min']; + $price_base_type = $datapriceofproduct['price_base_type']; + $tva_tx = $datapriceofproduct['tva_tx']; + $tva_npr = $datapriceofproduct['tva_npr']; + + $tmpvat = price2num(preg_replace('/\s*\(.*\)/', '', $tva_tx)); + $tmpprodvat = price2num(preg_replace('/\s*\(.*\)/', '', $prod->tva_tx)); + + // if price ht was forced (ie: from gui when calculated by margin rate and cost price). TODO Why this ? + if (! empty($price_ht)) { + $pu_ht = price2num($price_ht, 'MU'); + $pu_ttc = price2num($pu_ht * (1 + ($tmpvat / 100)), 'MU'); + } elseif ($tmpvat != $tmpprodvat) { + // On reevalue prix selon taux tva car taux tva transaction peut etre different + // de ceux du produit par defaut (par exemple si pays different entre vendeur et acheteur). + if ($price_base_type != 'HT') { + $pu_ht = price2num($pu_ttc / (1 + ($tmpvat / 100)), 'MU'); + } else { + $pu_ttc = price2num($pu_ht * (1 + ($tmpvat / 100)), 'MU'); + } + } + + $desc = ''; + + // Define output language + if (! empty($conf->global->MAIN_MULTILANGS) && ! empty($conf->global->PRODUIT_TEXTS_IN_THIRDPARTY_LANGUAGE)) { + $outputlangs = $langs; + $newlang = ''; + if (empty($newlang) && GETPOST('lang_id', 'aZ09')) { + $newlang = GETPOST('lang_id', 'aZ09'); + } + if (empty($newlang)) { + $newlang = $object->thirdparty->default_lang; + } + if (! empty($newlang)) { + $outputlangs = new Translate("", $conf); + $outputlangs->setDefaultLang($newlang); + } + + $desc = (! empty($prod->multilangs [$outputlangs->defaultlang] ["description"])) ? $prod->multilangs [$outputlangs->defaultlang] ["description"] : $prod->description; + } else { + $desc = $prod->description; + } + + $desc = dol_concatdesc($desc, $product_desc); + + // Add custom code and origin country into description + if (empty($conf->global->MAIN_PRODUCT_DISABLE_CUSTOMCOUNTRYCODE) && (! empty($prod->customcode) || ! empty($prod->country_code))) { + $tmptxt = '('; + // Define output language + if (! empty($conf->global->MAIN_MULTILANGS) && ! empty($conf->global->PRODUIT_TEXTS_IN_THIRDPARTY_LANGUAGE)) { + $outputlangs = $langs; + $newlang = ''; + if (empty($newlang) && GETPOST('lang_id', 'alpha')) { + $newlang = GETPOST('lang_id', 'alpha'); + } + if (empty($newlang)) { + $newlang = $object->thirdparty->default_lang; + } + if (! empty($newlang)) { + $outputlangs = new Translate("", $conf); + $outputlangs->setDefaultLang($newlang); + $outputlangs->load('products'); + } + if (! empty($prod->customcode)) { + $tmptxt .= $outputlangs->transnoentitiesnoconv("CustomCode") . ': ' . $prod->customcode; + } + if (! empty($prod->customcode) && ! empty($prod->country_code)) { + $tmptxt .= ' - '; + } + if (! empty($prod->country_code)) { + $tmptxt .= $outputlangs->transnoentitiesnoconv("CountryOrigin") . ': ' . getCountry($prod->country_code, 0, $db, $outputlangs, 0); + } + } else { + if (! empty($prod->customcode)) { + $tmptxt .= $langs->transnoentitiesnoconv("CustomCode") . ': ' . $prod->customcode; + } + if (! empty($prod->customcode) && ! empty($prod->country_code)) { + $tmptxt .= ' - '; + } + if (! empty($prod->country_code)) { + $tmptxt .= $langs->transnoentitiesnoconv("CountryOrigin") . ': ' . getCountry($prod->country_code, 0, $db, $langs, 0); + } + } + $tmptxt .= ')'; + $desc = dol_concatdesc($desc, $tmptxt); + } + + $type = $prod->type; + $fk_unit = $prod->fk_unit; + } else { + $pu_ht = price2num($price_ht, 'MU'); + $pu_ttc = price2num(GETPOST('price_ttc'), 'MU'); + $tva_npr = (preg_match('/\*/', $tva_tx) ? 1 : 0); + $tva_tx = str_replace('*', '', $tva_tx); + if (empty($tva_tx)) { + $tva_npr = 0; + } + $desc = $product_desc; + $type = GETPOST('type'); + $fk_unit = GETPOST('units', 'alpha'); + } + + $date_start_fill = ! empty(GETPOST('date_start_fill', 'int')) ? GETPOST('date_start_fill', 'int') : null; + $date_end_fill = ! empty(GETPOST('date_end_fill', 'int')) ? GETPOST('date_end_fill', 'int') : null; + + // Margin + $fournprice = price2num(GETPOST('fournprice' . $predef) ? GETPOST('fournprice' . $predef) : ''); + $buyingprice = price2num(GETPOST('buying_price' . $predef) != '' ? GETPOST('buying_price' . $predef) : ''); // If buying_price is '0', we must keep this value + + // Local Taxes + $localtax1_tx = get_localtax($tva_tx, 1, $object->thirdparty, $mysoc, $tva_npr); + $localtax2_tx = get_localtax($tva_tx, 2, $object->thirdparty, $mysoc, $tva_npr); + $info_bits = 0; + if ($tva_npr) { + $info_bits |= 0x01; + } + + //To set vars in float type to avoid non-numeric warnings + $pu_ht = (float) price2num($pu_ht); + $remise_percent = (float) price2num($remise_percent); + + $price_min = (float) price2num($price_min); + if ($usercanproductignorepricemin && (! empty($price_min) && ($pu_ht * (1 - $remise_percent / 100) < $price_min))) { + $mesg = $langs->trans("CantBeLessThanMinPrice", price(price2num($price_min, 'MU'), 0, $langs, 0, 0, -1, $conf->currency)); + setEventMessages($mesg, null, 'errors'); + } else { + // Insert line + $result = $object->addline($idprod, $ref_fournisseur, $label, $desc, $pu_ht, $pu_ttc, $qty, $remise_percent, $tva_tx, $localtax1_tx, $localtax2_tx, $price_base_type, $type, $date_start_fill, $date_end_fill, $info_bits, $special_code, -1, $fk_unit); + + if ($result > 0) { + $object->fetch($object->id); // Reload lines + + unset($_POST['prod_entry_mode']); + unset($_POST['qty']); + unset($_POST['type']); + unset($_POST['remise_percent']); + unset($_POST['price_ht']); + unset($_POST['multicurrency_price_ht']); + unset($_POST['price_ttc']); + unset($_POST['tva_tx']); + unset($_POST['product_ref']); + unset($_POST['product_label']); + unset($_POST['product_desc']); + unset($_POST['fournprice']); + unset($_POST['buying_price']); + unset($_POST['np_marginRate']); + unset($_POST['np_markRate']); + unset($_POST['dp_desc']); + unset($_POST['idprod']); + unset($_POST['units']); + unset($_POST['date_starthour']); + unset($_POST['date_startmin']); + unset($_POST['date_startsec']); + unset($_POST['date_startday']); + unset($_POST['date_startmonth']); + unset($_POST['date_startyear']); + unset($_POST['date_endhour']); + unset($_POST['date_endmin']); + unset($_POST['date_endsec']); + unset($_POST['date_endday']); + unset($_POST['date_endmonth']); + unset($_POST['date_endyear']); + unset($_POST['date_start_fill']); + unset($_POST['date_end_fill']); + unset($_POST['situations']); + unset($_POST['progress']); + } else { + setEventMessages($object->error, $object->errors, 'errors'); + } + + $action = ''; + } + } + } elseif ($action == 'updateline' && $usercancreate && ! GETPOST('cancel', 'alpha')) { + if (! $object->fetch($id) > 0) { + dol_print_error($db); + } + $object->fetch_thirdparty(); + + // Clean parameters + $date_start = ''; + $date_end = ''; + $description = dol_htmlcleanlastbr(GETPOST('product_desc', 'restricthtml') ? GETPOST('product_desc', 'restricthtml') : GETPOST('desc', 'restricthtml')); + $ref_fourn = GETPOST('fourn_ref', 'alpha'); + $pu_ht = price2num(GETPOST('price_ht'), '', 2); + $vat_rate = (GETPOST('tva_tx') ? GETPOST('tva_tx') : 0); + $qty = GETPOST('qty'); + $pu_ht_devise = price2num(GETPOST('multicurrency_subprice'), '', 2); + + // Define info_bits + $info_bits = 0; + if (preg_match('/\*/', $vat_rate)) { + $info_bits |= 0x01; + } + + // Define vat_rate + $vat_rate = str_replace('*', '', $vat_rate); + $localtax1_rate = get_localtax($vat_rate, 1, $object->thirdparty); + $localtax2_rate = get_localtax($vat_rate, 2, $object->thirdparty); + + // Extrafields + $extralabelsline = $extrafields->fetch_name_optionals_label($object->table_element_line); + $array_options = $extrafields->getOptionalsFromPost($object->table_element_line); + + $objectline = new FactureFournisseurLigneRec($db); + if ($objectline->fetch(GETPOST('lineid', 'int'))) { + $objectline->array_options = $array_options; + $result = $objectline->insertExtraFields(); + if ($result < 0) { + setEventMessages($langs->trans('Error') . $result, null, 'errors'); + } + } + + $position = ($objectline->rang >= 0 ? $objectline->rang : 0); + + // Unset extrafield + if (is_array($extralabelsline)) { + // Get extra fields + foreach ($extralabelsline as $key => $value) { + unset($_POST["options_" . $key]); + } + } + + // Define special_code for special lines + $special_code = GETPOST('special_code', 'int'); + if (! GETPOST('qty', 'alpha')) { + $special_code = 3; + } + + $remise_percent = price2num(GETPOST('remise_percent'), '', 2); + + // Check minimum price + $productid = GETPOST('productid', 'int'); + if (! empty($productid)) { + $product = new Product($db); + $product->fetch($productid); + + $type = $product->type; + + $price_min = $product->price_min; + if (! empty($conf->global->PRODUIT_MULTIPRICES) && ! empty($object->thirdparty->price_level)) { + $price_min = $product->multiprices_min[$object->thirdparty->price_level]; + } + + $label = $product->label; + + // Check price is not lower than minimum (check is done only for standard or replacement invoices) + if (((! empty($conf->global->MAIN_USE_ADVANCED_PERMS) && empty($user->rights->produit->ignore_price_min_advance)) || empty($conf->global->MAIN_USE_ADVANCED_PERMS)) && $price_min && (price2num($pu_ht) * (1 - $remise_percent / 100) < price2num($price_min))) { + setEventMessages($langs->trans("CantBeLessThanMinPrice", price(price2num($price_min, 'MU'), 0, $langs, 0, 0, -1, $conf->currency)), null, 'errors'); + $error++; + } + } else { + $type = GETPOST('type', 'int'); + $label = (GETPOST('product_label') ? GETPOST('product_label') : ''); + + // Check parameters + if (GETPOST('type', 'int') < 0) { + setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("Type")), null, 'errors'); + $error++; + } + } + if ($qty < 0) { + $langs->load("errors"); + setEventMessages($langs->trans('ErrorQtyForCustomerInvoiceCantBeNegative'), null, 'errors'); + $error++; + } + + $date_start_fill = ! empty(GETPOST('date_start_fill', 'int')) ? GETPOST('date_start_fill', 'int') : 'NULL'; + $date_end_fill = ! empty(GETPOST('date_end_fill', 'int')) ? GETPOST('date_end_fill', 'int') : 'NULL'; + + // Update line + if (! $error) { + $result = $object->updateline(GETPOST('lineid', 'int'), GETPOST('productid', 'int'), $ref_fourn, $label, $description, $pu_ht, $qty, $remise_percent, $vat_rate, $localtax1_rate, $localtax1_rate, 'HT', $type, $date_start_fill, $date_end_fill, $info_bits, $special_code, -1); + if ($result >= 0) { + $object->fetch($object->id); // Reload lines + + unset($_POST['qty']); + unset($_POST['type']); + unset($_POST['productid']); + unset($_POST['remise_percent']); + unset($_POST['price_ht']); + unset($_POST['multicurrency_price_ht']); + unset($_POST['price_ttc']); + unset($_POST['tva_tx']); + unset($_POST['product_ref']); + unset($_POST['product_label']); + unset($_POST['product_desc']); + unset($_POST['fournprice']); + unset($_POST['buying_price']); + unset($_POST['np_marginRate']); + unset($_POST['np_markRate']); + unset($_POST['dp_desc']); + unset($_POST['idprod']); + unset($_POST['units']); + unset($_POST['date_starthour']); + unset($_POST['date_startmin']); + unset($_POST['date_startsec']); + unset($_POST['date_startday']); + unset($_POST['date_startmonth']); + unset($_POST['date_startyear']); + unset($_POST['date_endhour']); + unset($_POST['date_endmin']); + unset($_POST['date_endsec']); + unset($_POST['date_endday']); + unset($_POST['date_endmonth']); + unset($_POST['date_endyear']); + unset($_POST['situations']); + unset($_POST['progress']); + } else { + setEventMessages($object->error, $object->errors, 'errors'); + } + } + } +} + +/* + * View + */ + +$help_url = ''; +llxHeader('', $langs->trans("RepeatableSupplierInvoice"), $help_url); + +$form = new Form($db); +$formother = new FormOther($db); +if (! empty($conf->projet->enabled)) { + $formproject = new FormProjets($db); +} +$companystatic = new Societe($db); +$invoicerectmp = new FactureFournisseurRec($db); + +$now = dol_now(); +$nowlasthour = dol_get_last_hour($now); + +/* + * Create mode + */ +if ($action == 'create') { + print load_fiche_titre($langs->trans("CreateRepeatableInvoice"), '', 'bill'); + + $object = new FactureFournisseur($db); // Source invoice + $product_static = new Product($db); + + if ($object->fetch($id) > 0) { + $result = $object->fetch_lines(); + + print ''; + print ''; + print ''; + print ''; + + print dol_get_fiche_head(null, '', '', 0); + + $rowspan = 4; + if (! empty($conf->projet->enabled)) $rowspan++; + if ($object->fk_account > 0) $rowspan++; + + print ''; + + $object->fetch_thirdparty(); + + // Title + print ''; + + // Ref supplier + print ''; + + // Third party + print ''; + print ''; + + $note_public = GETPOSTISSET('note_public') ? GETPOST('note_public', 'restricthtml') : $object->note_public; + $note_private = GETPOSTISSET('note_private') ? GETPOST('note_private', 'restricthtml') : $object->note_private; + + // Help of substitution key + $substitutionarray = getCommonSubstitutionArray($langs, 2, null, $object); + + $substitutionarray['__INVOICE_PREVIOUS_MONTH__'] = $langs->trans("PreviousMonthOfInvoice") . ' (' . $langs->trans("Example") . ': ' . dol_print_date(dol_time_plus_duree($object->date, -1, 'm'), '%m') . ')'; + $substitutionarray['__INVOICE_MONTH__'] = $langs->trans("MonthOfInvoice") . ' (' . $langs->trans("Example") . ': ' . dol_print_date($object->date, '%m') . ')'; + $substitutionarray['__INVOICE_NEXT_MONTH__'] = $langs->trans("NextMonthOfInvoice") . ' (' . $langs->trans("Example") . ': ' . dol_print_date(dol_time_plus_duree($object->date, 1, 'm'), '%m') . ')'; + $substitutionarray['__INVOICE_PREVIOUS_MONTH_TEXT__'] = $langs->trans("TextPreviousMonthOfInvoice") . ' (' . $langs->trans("Example") . ': ' . dol_print_date(dol_time_plus_duree($object->date, -1, 'm'), '%B') . ')'; + $substitutionarray['__INVOICE_MONTH_TEXT__'] = $langs->trans("TextMonthOfInvoice") . ' (' . $langs->trans("Example") . ': ' . dol_print_date($object->date, '%B') . ')'; + $substitutionarray['__INVOICE_NEXT_MONTH_TEXT__'] = $langs->trans("TextNextMonthOfInvoice") . ' (' . $langs->trans("Example") . ': ' . dol_print_date(dol_time_plus_duree($object->date, 1, 'm'), '%B') . ')'; + $substitutionarray['__INVOICE_PREVIOUS_YEAR__'] = $langs->trans("PreviousYearOfInvoice") . ' (' . $langs->trans("Example") . ': ' . dol_print_date(dol_time_plus_duree($object->date, -1, 'y'), '%Y') . ')'; + $substitutionarray['__INVOICE_YEAR__'] = $langs->trans("YearOfInvoice") . ' (' . $langs->trans("Example") . ': ' . dol_print_date($object->date, '%Y') . ')'; + $substitutionarray['__INVOICE_NEXT_YEAR__'] = $langs->trans("NextYearOfInvoice") . ' (' . $langs->trans("Example") . ': ' . dol_print_date(dol_time_plus_duree($object->date, 1, 'y'), '%Y') . ')'; + // Only on template invoices + $substitutionarray['__INVOICE_DATE_NEXT_INVOICE_BEFORE_GEN__'] = $langs->trans("DateNextInvoiceBeforeGen") . ' (' . $langs->trans("Example") . ': ' . dol_print_date($object->date_when, 'dayhour') . ')'; + $substitutionarray['__INVOICE_DATE_NEXT_INVOICE_AFTER_GEN__'] = $langs->trans("DateNextInvoiceAfterGen") . ' (' . $langs->trans("Example") . ': ' . dol_print_date(dol_time_plus_duree($object->date_when, $object->frequency, $object->unit_frequency), 'dayhour') . ')'; + $substitutionarray['__INVOICE_COUNTER_CURRENT__'] = $langs->trans("Count"); + $substitutionarray['__INVOICE_COUNTER_MAX__'] = $langs->trans("MaxPeriodNumber"); + + $htmltext = '' . $langs->trans("FollowingConstantsWillBeSubstituted") . ':
    '; + foreach ($substitutionarray as $key => $val) { + $htmltext .= $key . ' = ' . $langs->trans($val) . '
    '; + } + $htmltext .= '
    '; + + // Libelle + print ''; + + // Public note + print ''; + print ''; + print ''; + print ''; + print ''; + } + + // Author + print ""; + + // Payment term + print ""; + + // Payment mode + print ""; + + // Project + if (! empty($conf->projet->enabled) && is_object($object->thirdparty) && $object->thirdparty->id > 0) { + $projectid = GETPOST('projectid') ? GETPOST('projectid') : $object->fk_project; + $langs->load('projects'); + print ''; + } + + // Bank account + if ($object->fk_account > 0) { + print ""; + } + + // Model pdf + print ""; + + print "
    ' . $langs->trans("Title") . ''; + print ''; + print '
    ' . $langs->trans("SupplierRef") . ''; + print ''; + print '
    ' . $langs->trans("Customer") . '' . $object->thirdparty->getNomUrl(1, 'customer') . '
    ' . $langs->trans("Label") . ''; + print ''; + print '
    '; + print $form->textwithpicto($langs->trans('NotePublic'), $htmltext, 1, 'help', '', 0, 2, 'notepublic'); + print ''; + $doleditor = new DolEditor('note_public', $note_public, '', 80, 'dolibarr_notes', 'In', 0, false, empty($conf->global->FCKEDITOR_ENABLE_NOTE_PUBLIC) ? 0 : 1, ROWS_3, '90%'); + print $doleditor->Create(1); + + // Private note + if (empty($user->socid)) { + print '
    '; + print $form->textwithpicto($langs->trans('NotePrivate'), $htmltext, 1, 'help', '', 0, 2, 'noteprivate'); + print ''; + $doleditor = new DolEditor('note_private', $note_private, '', 80, 'dolibarr_notes', 'In', 0, false, empty($conf->global->FCKEDITOR_ENABLE_NOTE_PRIVATE) ? 0 : 1, ROWS_3, '90%'); + print $doleditor->Create(1); + print '
    " . $langs->trans("Author") . "" . $user->getFullName($langs) . "
    " . $langs->trans("PaymentConditions") . ""; + $form->form_conditions_reglement($_SERVER['PHP_SELF'] . '?id=' . $object->id, $object->cond_reglement_id, 'none'); + print "
    " . $langs->trans("PaymentMode") . ""; + $form->form_modes_reglement($_SERVER['PHP_SELF'] . '?id=' . $object->id, $object->mode_reglement_id, 'none', '', 1); + print "
    ' . $langs->trans('Project') . ''; + $numprojet = $formproject->select_projects($object->thirdparty->id, $projectid, 'projectid', 0, 0, 1, 0, 0, 0, 0, '', 0, 0, ''); + print '   thirdparty->id . (! empty($id) ? '&id=' . $id : '')) . '">' . $langs->trans("AddProject") . ''; + print '
    " . $langs->trans('BankAccount') . ""; + $form->formSelectAccount($_SERVER['PHP_SELF'] . '?id=' . $object->id, $object->fk_account, 'none'); + print "
    " . $langs->trans('Model') . ""; + include_once DOL_DOCUMENT_ROOT . '/core/modules/supplier_invoice/modules_facturefournisseur.php'; + $list = ModelePDFSuppliersInvoices::liste_modeles($db); + print $form->selectarray('modelpdf', $list, $conf->global->INVOICE_SUPPLIER_ADDON_PDF); + print "
    "; + + print dol_get_fiche_end(); + + // Autogeneration + $title = $langs->trans("Recurrence"); + print load_fiche_titre(img_picto('', 'recurring', 'class="pictofixedwidth"') . $title, '', ''); + + print dol_get_fiche_head(null, '', '', 0); + + print ''; + + // Frequency + unit + print '"; + + // Date next run + print ""; + + // Number max of generation + print ""; + + // Auto validate the invoice + print ""; + + // Auto generate document + if (! empty($conf->global->INVOICE_REC_CAN_DISABLE_DOCUMENT_FILE_GENERATION)) { + print ""; + } else { + print ''; + } + + print "
    ' . $form->textwithpicto($langs->trans("Frequency"), $langs->transnoentitiesnoconv('toolTipFrequency')) . ""; + print " " . $form->selectarray('unit_frequency', array('d' => $langs->trans('Day'), 'm' => $langs->trans('Month'), 'y' => $langs->trans('Year')), (GETPOST('unit_frequency') ? GETPOST('unit_frequency') : 'm')); + print "
    " . $langs->trans('NextDateToExecution') . ""; + $date_next_execution = isset($date_next_execution) ? $date_next_execution : (GETPOST('remonth') ? dol_mktime(12, 0, 0, GETPOST('remonth'), GETPOST('reday'), GETPOST('reyear')) : -1); + print $form->selectDate($date_next_execution, '', 1, 1, '', "add", 1, 1); + print "
    " . $langs->trans("MaxPeriodNumber") . ""; + print ''; + print "
    " . $langs->trans("StatusOfGeneratedInvoices") . ""; + $select = array('0' => $langs->trans('BillStatusDraft'), '1' => $langs->trans('BillStatusValidated')); + print $form->selectarray('auto_validate', $select, GETPOST('auto_validate')); + print "
    " . $langs->trans("StatusOfGeneratedDocuments") . ""; + $select = array('0' => $langs->trans('DoNotGenerateDoc'), '1' => $langs->trans('AutoGenerateDoc')); + print $form->selectarray('generate_pdf', $select, GETPOST('generate_pdf')); + print "
    "; + + print dol_get_fiche_end(); + + $title = $langs->trans("ProductsAndServices"); + if (empty($conf->service->enabled)) { + $title = $langs->trans("Products"); + } elseif (empty($conf->product->enabled)) { + $title = $langs->trans("Services"); + } + + print load_fiche_titre($title, '', ''); + + /* + * Invoice lines + */ + print '
    '; + print ''; + // Show object lines + if (! empty($object->lines)) { + $disableedit = 1; + $disablemove = 1; + $disableremove = 1; + $object->printObjectLines('', $mysoc, $object->thirdparty, $lineid, 0); // No date selector for template invoice + } + + print "
    \n"; + print '
    '; + print '
    \n"; + + print $form->buttonsSaveCancel("Create"); + + print "\n"; + } else { + dol_print_error('', "Error, no invoice " . $object->id); + } +} else { + /* + * View mode + */ + if ($object->id > 0) { + $object->fetch($object->id); + $object->fetch_thirdparty(); + + // Confirmation de la suppression d'une ligne produit + if ($action == 'ask_deleteline') { + $formconfirm = $form->formconfirm($_SERVER["PHP_SELF"] . '?id=' . $object->id . '&lineid=' . $lineid, $langs->trans('DeleteProductLine'), $langs->trans('ConfirmDeleteProductLine'), 'confirm_deleteline', '', 'no', 1); + } + + // Confirm delete of repeatable invoice + if ($action == 'ask_deleteinvoice') { + $formconfirm = $form->formconfirm($_SERVER["PHP_SELF"] . '?id=' . $object->id, $langs->trans('DeleteRepeatableInvoice'), $langs->trans('ConfirmDeleteRepeatableInvoice'), 'confirm_deleteinvoice', '', 'no', 1); + } + + print $formconfirm; + + $author = new User($db); + $author->fetch($object->user_author); + + $head = supplier_invoice_rec_prepare_head($object); + + print dol_get_fiche_head($head, 'card', $langs->trans('RepeatableInvoice'), -1, 'bill'); // Add a div + + // Recurring invoice content + + $linkback = '' . $langs->trans('BackToList') . ''; + + $morehtmlref = ''; + if ($action != 'edittitle') { + $morehtmlref .= $form->editfieldkey($object->titre, 'title', $object->titre, $object, $usercancreate, '', '', 0, 2); + } else { + $morehtmlref .= $form->editfieldval('', 'title', $object->titre, $object, $usercancreate, 'string'); + } + $morehtmlref .= '
    '; + //Ref supplier + $morehtmlref .= $form->editfieldkey("RefSupplier", 'ref_supplier', $object->ref_supplier, $object, $usercancreate, 'string', '', 0, 1); + $morehtmlref .= $form->editfieldval("RefSupplier", 'ref_supplier', $object->ref_supplier, $object, $usercancreate, 'string', '', null, null, '', 1); + // Thirdparty + $morehtmlref .= '
    ' . $langs->trans('ThirdParty') . ' : ' . $object->thirdparty->getNomUrl(1); + + // Project + if (! empty($conf->projet->enabled)) { + $langs->load('projects'); + $morehtmlref .= '
    ' . $langs->trans('Project') . ' '; + if ($usercancreate) { + if ($action != 'classify') { + $morehtmlref .= '' . img_edit($langs->transnoentitiesnoconv('SetProject')) . ' : '; + } + if ($action == 'classify') { + $morehtmlref .= '
    '; + $morehtmlref .= ''; + $morehtmlref .= ''; + $morehtmlref .= $formproject->select_projects($object->socid, $object->fk_project, 'projectid', $maxlength, 0, 1, 0, 1, 0, 0, '', 1); + $morehtmlref .= ''; + $morehtmlref .= '
    '; + } else { + $morehtmlref .= $form->form_project($_SERVER['PHP_SELF'] . '?id=' . $object->id, $object->socid, $object->fk_project, 'none', 0, 0, 0, 1); + } + } else { + if (! empty($object->fk_project)) { + $project = new Project($db); + $project->fetch($object->fk_project); + $morehtmlref .= ' : ' . $project->getNomUrl(1); + if ($project->title) { + $morehtmlref .= ' - ' . $project->title; + } + } else { + $morehtmlref .= ''; + } + } + } + $morehtmlref .= '
    '; + + $morehtmlright = ''; + + dol_banner_tab($object, 'ref', $linkback, 1, 'title', 'none', $morehtmlref, '', 0, '', $morehtmlright); + + print '
    '; + print '
    '; + print '
    '; + + print ''; + + print '"; + + // Label + print ''; + print ''; + print ''; + print ''; + + print ''; + print ''; + print ''; + + print ''; + print ''; + + // Amount Local Taxes + if (($mysoc->localtax1_assuj == "1" && $mysoc->useLocalTax(1)) || $object->total_localtax1 != 0) { // Localtax1 + print ''; + print ''; + } + if (($mysoc->localtax2_assuj == "1" && $mysoc->useLocalTax(2)) || $object->total_localtax2 != 0) { // Localtax2 + print ''; + print ''; + } + + print ''; + print ''; + + // Payment term + print ''; + + // Payment mode + print ''; + + // Multicurrency + if (! empty($conf->multicurrency->enabled)) { + // Multicurrency code + print ''; + print ''; + + // Multicurrency rate + if ($object->multicurrency_code != $conf->currency || $object->multicurrency_tx != 1) { + print ''; + print ''; + } + } + + // Help of substitution key + $dateexample = dol_now(); + if (! empty($object->frequency) && ! empty($object->date_when)) { + $dateexample = $object->date_when; + } + + $substitutionarray = getCommonSubstitutionArray($langs, 2, null, $object); + + $substitutionarray['__INVOICE_PREVIOUS_MONTH__'] = $langs->trans("PreviousMonthOfInvoice") . ' (' . $langs->trans("Example") . ': ' . dol_print_date(dol_time_plus_duree($dateexample, -1, 'm'), '%m') . ')'; + $substitutionarray['__INVOICE_MONTH__'] = $langs->trans("MonthOfInvoice") . ' (' . $langs->trans("Example") . ': ' . dol_print_date($dateexample, '%m') . ')'; + $substitutionarray['__INVOICE_NEXT_MONTH__'] = $langs->trans("NextMonthOfInvoice") . ' (' . $langs->trans("Example") . ': ' . dol_print_date(dol_time_plus_duree($dateexample, 1, 'm'), '%m') . ')'; + $substitutionarray['__INVOICE_PREVIOUS_MONTH_TEXT__'] = $langs->trans("TextPreviousMonthOfInvoice") . ' (' . $langs->trans("Example") . ': ' . dol_print_date(dol_time_plus_duree($dateexample, -1, 'm'), '%B') . ')'; + $substitutionarray['__INVOICE_MONTH_TEXT__'] = $langs->trans("TextMonthOfInvoice") . ' (' . $langs->trans("Example") . ': ' . dol_print_date($dateexample, '%B') . ')'; + $substitutionarray['__INVOICE_NEXT_MONTH_TEXT__'] = $langs->trans("TextNextMonthOfInvoice") . ' (' . $langs->trans("Example") . ': ' . dol_print_date(dol_time_plus_duree($dateexample, 1, 'm'), '%B') . ')'; + $substitutionarray['__INVOICE_PREVIOUS_YEAR__'] = $langs->trans("PreviousYearOfInvoice") . ' (' . $langs->trans("Example") . ': ' . dol_print_date(dol_time_plus_duree($dateexample, -1, 'y'), '%Y') . ')'; + $substitutionarray['__INVOICE_YEAR__'] = $langs->trans("YearOfInvoice") . ' (' . $langs->trans("Example") . ': ' . dol_print_date($dateexample, '%Y') . ')'; + $substitutionarray['__INVOICE_NEXT_YEAR__'] = $langs->trans("NextYearOfInvoice") . ' (' . $langs->trans("Example") . ': ' . dol_print_date(dol_time_plus_duree($dateexample, 1, 'y'), '%Y') . ')'; + // Only on template invoices + $substitutionarray['__INVOICE_DATE_NEXT_INVOICE_BEFORE_GEN__'] = $langs->trans("DateNextInvoiceBeforeGen") . ' (' . $langs->trans("Example") . ': ' . dol_print_date(($object->date_when ? $object->date_when : dol_now()), 'dayhour') . ')'; + $substitutionarray['__INVOICE_DATE_NEXT_INVOICE_AFTER_GEN__'] = $langs->trans("DateNextInvoiceAfterGen") . ' (' . $langs->trans("Example") . ': ' . dol_print_date(dol_time_plus_duree(($object->date_when ? $object->date_when : dol_now()), $object->frequency, $object->unit_frequency), 'dayhour') . ')'; + $substitutionarray['__INVOICE_COUNTER_CURRENT__'] = $object->nb_gen_done; + $substitutionarray['__INVOICE_COUNTER_MAX__'] = $object->nb_gen_max; + + $htmltext = '' . $langs->trans("FollowingConstantsWillBeSubstituted") . ':
    '; + foreach ($substitutionarray as $key => $val) { + $htmltext .= $key . ' = ' . $langs->trans($val) . '
    '; + } + $htmltext .= '
    '; + + // Note public + print ''; + print ''; + + // Note private + print ''; + print ''; + + // Bank Account + print '"; + print ''; + + // Model pdf + print '"; + print ''; + + // Other attributes + $cols = 2; + include DOL_DOCUMENT_ROOT . '/core/tpl/extrafields_view.tpl.php'; + + print '
    ' . $langs->trans('Author') . ''; + print $author->getNomUrl(-1); + print "
    ' . $form->editfieldkey("Label", 'libelle', $object->libelle, $object, $usercancreate) . '' . $form->editfieldval("Label", 'libelle', $object->libelle, $object, $usercancreate) . '
    ' . $langs->trans('AmountHT') . '' . price($object->total_ht, '', $langs, 1, -1, -1, $conf->currency) . '
    ' . $langs->trans("AmountVAT") . '' . price($object->total_tva, '', $langs, 1, -1, -1, $conf->currency) . '
    ' . $langs->transcountry("AmountLT1", $mysoc->country_code) . '' . price($object->total_localtax1, 1, '', 1, -1, -1, $conf->currency) . '
    ' . $langs->transcountry("AmountLT2", $mysoc->country_code) . '' . price($object->total_localtax2, 1, '', 1, -1, -1, $conf->currency) . '
    ' . $langs->trans("AmountTTC") . '' . price($object->total_ttc, '', $langs, 1, -1, -1, $conf->currency) . '
    '; + print ''; + if ($action != 'editconditions' && $usercancreate) { + print ''; + } + print '
    '; + print $langs->trans('PaymentConditionsShort'); + print '' . img_edit($langs->trans('SetConditions'), 1) . '
    '; + print '
    '; + if ($action == 'editconditions') { + $form->form_conditions_reglement($_SERVER['PHP_SELF'] . '?facid=' . $object->id, $object->cond_reglement_id, 'cond_reglement_id'); + } else { + $form->form_conditions_reglement($_SERVER['PHP_SELF'] . '?facid=' . $object->id, $object->cond_reglement_id, 'none'); + } + + print '
    '; + print ''; + if ($action != 'editmode' && $usercancreate) { + print ''; + } + print '
    '; + print $langs->trans('PaymentMode'); + print '' . img_edit($langs->trans('SetMode'), 1) . '
    '; + print '
    '; + if ($action == 'editmode') { + $form->form_modes_reglement($_SERVER['PHP_SELF'] . '?facid=' . $object->id, $object->mode_reglement_id, 'mode_reglement_id', 'CRDT', 1, 1); + } else { + $form->form_modes_reglement($_SERVER['PHP_SELF'] . '?facid=' . $object->id, $object->mode_reglement_id, 'none'); + } + print '
    '; + print ''; + if ($usercancreate && $action != 'editmulticurrencycode' && ! empty($object->brouillon)) { + print ''; + } + print '
    '; + print $form->editfieldkey('Currency', 'multicurrency_code', '', $object, 0); + print '' . img_edit($langs->transnoentitiesnoconv('SetMultiCurrencyCode'), 1) . '
    '; + print '
    '; + $htmlname = (($usercancreate && $action == 'editmulticurrencycode') ? 'multicurrency_code' : 'none'); + $form->form_multicurrency_code($_SERVER['PHP_SELF'] . '?id=' . $object->id, $object->multicurrency_code, $htmlname); + print '
    '; + print ''; + if ($usercancreate && $action != 'editmulticurrencyrate' && ! empty($object->brouillon) && $object->multicurrency_code && $object->multicurrency_code != $conf->currency) { + print ''; + } + print '
    '; + print $form->editfieldkey('CurrencyRate', 'multicurrency_tx', '', $object, 0); + print '' . img_edit($langs->transnoentitiesnoconv('SetMultiCurrencyCode'), 1) . '
    '; + print '
    '; + if ($action == 'editmulticurrencyrate' || $action == 'actualizemulticurrencyrate') { + if ($action == 'actualizemulticurrencyrate') { + list($object->fk_multicurrency, $object->multicurrency_tx) = MultiCurrency::getIdAndTxFromCode($object->db, $object->multicurrency_code); + } + $form->form_multicurrency_rate($_SERVER['PHP_SELF'] . '?id=' . $object->id, $object->multicurrency_tx, ($usercancreate ? 'multicurrency_tx' : 'none'), $object->multicurrency_code); + } else { + $form->form_multicurrency_rate($_SERVER['PHP_SELF'] . '?id=' . $object->id, $object->multicurrency_tx, 'none', $object->multicurrency_code); + if ($object->statut == $object::STATUS_DRAFT && $object->multicurrency_code && $object->multicurrency_code != $conf->currency) { + print '
            '; + print '' . $langs->trans("ActualizeCurrency") . ''; + print '
    '; + } + } + print '
    '; + print $form->editfieldkey($form->textwithpicto($langs->trans('NotePublic'), $htmltext, 1, 'help', '', 0, 2, 'notepublic'), 'note_public', $object->note_public, $object, $usercancreate); + print ''; + print $form->editfieldval($langs->trans("NotePublic"), 'note_public', $object->note_public, $object, $usercancreate, 'textarea:' . ROWS_4 . ':90%', '', null, null, '', 1); + print '
    '; + print $form->editfieldkey($form->textwithpicto($langs->trans("NotePrivate"), $htmltext, 1, 'help', '', 0, 2, 'noteprivate'), 'note_private', $object->note_private, $object, $usercancreate); + print ''; + print $form->editfieldval($langs->trans("NotePrivate"), 'note_private', $object->note_private, $object, $usercancreate, 'textarea:' . ROWS_4 . ':90%', '', null, null, '', 1); + print '
    '; + print ''; + } + print '
    '; + print $langs->trans('BankAccount'); + print ''; + if ($action != 'editbankaccount' && $usercancreate && $object->statut == FactureFournisseurRec::STATUS_NOTSUSPENDED) { + print '' . img_edit($langs->trans('SetBankAccount'), 1) . '
    '; + print '
    '; + if ($action == 'editbankaccount') { + $form->formSelectAccount($_SERVER['PHP_SELF'] . '?id=' . $object->id, $object->fk_account, 'fk_account', 1); + } else { + $form->formSelectAccount($_SERVER['PHP_SELF'] . '?id=' . $object->id, $object->fk_account, 'none'); + } + print "
    '; + print ''; + } + print '
    '; + print $langs->trans('Model'); + print ''; + if ($action != 'editmodelpdf' && $usercancreate && $object->statut == FactureFournisseurRec::STATUS_NOTSUSPENDED) { + print '' . img_edit($langs->trans('SetModel'), 1) . '
    '; + print '
    '; + if ($action == 'editmodelpdf') { + include_once DOL_DOCUMENT_ROOT . '/core/modules/supplier_invoice/modules_facturefournisseur.php'; + $list = array(); + $models = ModelePDFSuppliersInvoices::liste_modeles($db); + foreach ($models as $k => $model) { + $list[] = str_replace(':', '|', $k) . ':' . $model; + } + $select = 'select;' . implode(',', $list); + //TODO : Droits + print $form->editfieldval($langs->trans('Model'), 'modelpdf', $object->model_pdf, $object, $usercancreate, $select); + } else { + print $object->model_pdf; + } + print "
    '; + + print '
    '; + print '
    '; + print '
    '; + + /* + * Recurrence + */ + $title = $langs->trans("Recurrence"); + //print load_fiche_titre($title, '', 'calendar'); + + print ''; + + print ''; + + // if "frequency" is empty or = 0, the reccurence is disabled + print ''; + + // Date when (next invoice generation) + print ''; + print ''; + + // Max period / Rest period + print ''; + print ''; + + // Status of generated invoices + print ''; + // Auto generate documents + if (! empty($conf->global->INVOICE_REC_CAN_DISABLE_DOCUMENT_FILE_GENERATION)) { + print ''; + print ''; + print ''; + print ''; + } else { + print ''; + } + + print '
    ' . img_picto('', 'recurring', 'class="pictofixedwidth"') . $title . '
    '; + print ''; + if ($action != 'editfrequency' && $usercancreate) { + print ''; + } + print '
    '; + print $langs->trans('Frequency'); + print '' . img_edit($langs->trans('Edit'), 1) . '
    '; + print '
    '; + if ($action == 'editfrequency') { + print '
    '; + print ''; + print ''; + print ''; + print ''; + print ''; + print '
    '; + print " " . $form->selectarray('unit_frequency', array('d' => $langs->trans('Day'), 'm' => $langs->trans('Month'), 'y' => $langs->trans('Year')), ($object->unit_frequency ? $object->unit_frequency : 'm')); + print '
    '; + } else { + if ($object->frequency > 0) { + print $langs->trans('FrequencyPer_' . $object->unit_frequency, $object->frequency); + } else { + print $langs->trans("NotARecurringInvoiceTemplate"); + } + } + print '
    '; + if ($action == 'date_when' || $object->frequency > 0) { + print $form->editfieldkey($langs->trans("NextDateToExecution"), 'date_when', $object->date_when, $object, $usercancreate, 'day'); + } else { + print $langs->trans("NextDateToExecution"); + } + print ''; + if ($action == 'date_when' || $object->frequency > 0) { + print $form->editfieldval($langs->trans("NextDateToExecution"), 'date_when', $object->date_when, $object, $usercancreate, 'day', $object->date_when, null, '', '', 0, 'strikeIfMaxNbGenReached'); + } + //var_dump(dol_print_date($object->date_when+60, 'dayhour').' - '.dol_print_date($now, 'dayhour')); + if (! $object->isMaxNbGenReached()) { + if (! $object->suspended && $action != 'editdate_when' && $object->frequency > 0 && $object->date_when && $object->date_when < $now) { + print img_warning($langs->trans("Late")); + } + } else { + print img_info($langs->trans("MaxNumberOfGenerationReached")); + } + print '
    '; + if ($action == 'nb_gen_max' || $object->frequency > 0) { + print $form->editfieldkey($langs->trans("MaxPeriodNumber"), 'nb_gen_max', $object->nb_gen_max, $object, $usercancreate); + } else { + print $langs->trans("MaxPeriodNumber"); + } + print ''; + if ($action == 'nb_gen_max' || $object->frequency > 0) { + print $form->editfieldval($langs->trans("MaxPeriodNumber"), 'nb_gen_max', $object->nb_gen_max ? $object->nb_gen_max : '', $object, $usercancreate); + } else { + print ''; + } + print '
    '; + if ($action == 'auto_validate' || $object->frequency > 0) { + print $form->editfieldkey($langs->trans("StatusOfGeneratedInvoices"), 'auto_validate', $object->auto_validate, $object, $usercancreate); + } else { + print $langs->trans("StatusOfGeneratedInvoices"); + } + print ''; + $select = 'select;0:' . $langs->trans('BillStatusDraft') . ',1:' . $langs->trans('BillStatusValidated'); + if ($action == 'auto_validate' || $object->frequency > 0) { + print $form->editfieldval($langs->trans("StatusOfGeneratedInvoices"), 'auto_validate', $object->auto_validate, $object, $usercancreate, $select); + } + print '
    '; + if ($action == 'generate_pdf' || $object->frequency > 0) { + print $form->editfieldkey($langs->trans("StatusOfGeneratedDocuments"), 'generate_pdf', $object->generate_pdf, $object, $usercancreate); + } else { + print $langs->trans("StatusOfGeneratedDocuments"); + } + print ''; + $select = 'select;0:' . $langs->trans('DoNotGenerateDoc') . ',1:' . $langs->trans('AutogenerateDoc'); + if ($action == 'generate_pdf' || $object->frequency > 0) { + print $form->editfieldval($langs->trans("StatusOfGeneratedDocuments"), 'generate_pdf', $object->generate_pdf, $object, $usercancreate, $select); + } + print '
    '; + + // Frequencry/Recurring section + if ($object->frequency > 0) { + print '
    '; + + if (empty($conf->cron->enabled)) { + print info_admin($langs->trans("EnableAndSetupModuleCron", $langs->transnoentitiesnoconv("Module2300Name"))); + } + + print '
    '; + print ''; + + // Nb of generation already done + print ''; + print ''; + print ''; + + // Date last + print ''; + print ''; + + print '
    ' . $langs->trans("NbOfGenerationDone") . ''; + print $object->nb_gen_done ? $object->nb_gen_done : '0'; + print '
    '; + print $langs->trans("DateLastGeneration"); + print ''; + print dol_print_date($object->date_last_gen, 'dayhour'); + print '
    '; + + print '
    '; + } + + print '
    '; + print '
    '; + + print '

    '; + + // Lines + print '
    + + + + + '; + + if (! empty($conf->use_javascript_ajax) && $object->statut == 0) { + include DOL_DOCUMENT_ROOT . '/core/tpl/ajaxrow.tpl.php'; + } + + print '
    '; + print ''; + $object->fetch_lines(); + // Show object lines + if (! empty($object->lines)) { + $canchangeproduct = 1; + // To set ref for getNomURL function + foreach ($object->lines as $line) { + $line->ref = $line->label; + $line->product_label = $line->label; + $line->subprice = $line->pu_ht; + } + + global $canchangeproduct; + $canchangeproduct = 0; + + $object->statut = $object->suspended; + $object->printObjectLines($action, $mysoc, $object->thirdparty, $lineid, 0); // No date selector for template invoice + } + + // Form to add new line + //TODO : Droits + if ($object->statut == $object::STATUS_DRAFT && $usercancreate && $action != 'valid' && $action != 'editline') { + if ($action != 'editline') { + // Add free products/services + + $parameters = array(); + $reshook = $hookmanager->executeHooks('formAddObjectLine', $parameters, $object, $action); // Note that $action and $object may have been modified by hook + if ($reshook < 0) setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); + if (empty($reshook)) + global $senderissupplier; + $senderissupplier = 2; + $object->formAddObjectLine(0, $object->thirdparty, $mysoc); // No date selector for template invoice + } + } + + print "
    \n"; + print '
    '; + + print "
    \n"; + + print dol_get_fiche_end(); + + /* + * Action bar + */ + print '
    '; + + if (empty($object->suspended)) { + if ($usercancreate) { + if (! empty($object->frequency) && $object->nb_gen_max > 0 && ($object->nb_gen_done >= $object->nb_gen_max)) { + print ''; + } else { + if (empty($object->frequency) || $object->date_when <= $nowlasthour) { + print ''; + } else { + print ''; + } + } + } else { + print ''; + } + } + + if ($usercancreate) { + if (empty($object->suspended)) { + print ''; + } else { + print ''; + } + } + + //if ($object->statut == Facture::STATUS_DRAFT && ($user->rights->fournisseur->facture->supprimer || $user->rights->supplier_invoice->supprimer)) + if (($user->rights->fournisseur->facture->supprimer || $user->rights->supplier_invoice->supprimer)) { + print ''; + } + + print '
    '; + + print '
    '; + print ''; // ancre + + // Show links to link elements + $linktoelem = $form->showLinkToObjectBlock($object, null, array('invoice')); + + $somethingshown = $form->showLinkedObjectBlock($object, $linktoelem); + + print '
    '; + } +} + +// End of page +llxFooter(); +$db->close(); diff --git a/htdocs/fourn/facture/card.php b/htdocs/fourn/facture/card.php index 946958594d8..d384f3f90d2 100644 --- a/htdocs/fourn/facture/card.php +++ b/htdocs/fourn/facture/card.php @@ -37,6 +37,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php'; require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/modules/supplier_invoice/modules_facturefournisseur.php'; require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.facture.class.php'; +require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.facture-rec.class.php'; require_once DOL_DOCUMENT_ROOT.'/fourn/class/paiementfourn.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/discount.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/fourn.lib.php'; @@ -265,6 +266,8 @@ if (empty($reshook)) { // Remove a product line $result = $object->deleteline($lineid); if ($result > 0) { + // reorder lines + $object->line_order(true); // Define output language /*$outputlangs = $langs; $newlang = ''; @@ -542,9 +545,9 @@ if (empty($reshook)) { if ($line->product_type < 9 && $line->total_ht != 0) { // Remove lines with product_type greater than or equal to 9 and no need to create discount if amount is null $keyforvatrate = $line->tva_tx.($line->vat_src_code ? ' ('.$line->vat_src_code.')' : ''); - $amount_ht[$line->tva_tx] += $line->total_ht; - $amount_tva[$line->tva_tx] += $line->total_tva; - $amount_ttc[$line->tva_tx] += $line->total_ttc; + $amount_ht[$keyforvatrate] += $line->total_ht; + $amount_tva[$keyforvatrate] += $line->total_tva; + $amount_ttc[$keyforvatrate] += $line->total_ttc; $multicurrency_amount_ht[$keyforvatrate] += $line->multicurrency_total_ht; $multicurrency_amount_tva[$keyforvatrate] += $line->multicurrency_total_tva; $multicurrency_amount_ttc[$keyforvatrate] += $line->multicurrency_total_ttc; @@ -881,8 +884,52 @@ if (empty($reshook)) { } } + // Standard invoice or Deposit invoice, created from a Predefined template invoice + if ((GETPOST('type') == FactureFournisseur::TYPE_STANDARD || GETPOST('type') == FactureFournisseur::TYPE_DEPOSIT) && GETPOST('fac_rec', 'int') > 0) { + if (empty($dateinvoice)) { + $error++; + setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("Date")), null, 'errors'); + $action = 'create'; + } elseif ($dateinvoice > (dol_get_last_hour(dol_now('tzuserrel')) + (empty($conf->global->INVOICE_MAX_FUTURE_DELAY) ? 0 : $conf->global->INVOICE_MAX_FUTURE_DELAY))) { + $error++; + setEventMessages($langs->trans("ErrorDateIsInFuture"), null, 'errors'); + $action = 'create'; + } + + if (!$error) { + $object->socid = GETPOST('socid', 'int'); + $object->type = GETPOST('type'); + $object->ref = GETPOST('ref'); + $object->date = $dateinvoice; + $object->note_public = trim(GETPOST('note_public', 'restricthtml')); + $object->note_private = trim(GETPOST('note_private', 'restricthtml')); + $object->ref_client = GETPOST('ref_client'); + $object->model_pdf = GETPOST('model'); + $object->fk_project = GETPOST('projectid', 'int'); + $object->cond_reglement_id = (GETPOST('type') == 3 ? 1 : GETPOST('cond_reglement_id')); + $object->mode_reglement_id = GETPOST('mode_reglement_id', 'int'); + $object->fk_account = GETPOST('fk_account', 'int'); + $object->amount = price2num(GETPOST('amount')); + $object->remise_absolue = price2num(GETPOST('remise_absolue'), 'MU'); + $object->remise_percent = price2num(GETPOST('remise_percent'), '', 2); + $object->fk_incoterms = GETPOST('incoterm_id', 'int'); + $object->location_incoterms = GETPOST('location_incoterms', 'alpha'); + $object->multicurrency_code = GETPOST('multicurrency_code', 'alpha'); + $object->multicurrency_tx = GETPOST('originmulticurrency_tx', 'int'); + + // Source facture + $object->fac_rec = GETPOST('fac_rec', 'int'); + $fac_rec = new FactureFournisseurRec($db); + $fac_rec->fetch($object->fac_rec); + $fac_rec->fetch_lines(); + $object->lines = $fac_rec->lines; + + $id = $object->create($user); // This include recopy of links from recurring invoice and recurring invoice lines + } + } + // Standard invoice or Deposit invoice, not from a Predefined template invoice - if (GETPOST('type') == FactureFournisseur::TYPE_STANDARD || GETPOST('type') == FactureFournisseur::TYPE_DEPOSIT) { + if (GETPOST('type') == FactureFournisseur::TYPE_STANDARD || GETPOST('type') == FactureFournisseur::TYPE_DEPOSIT && GETPOST('fac_rec') <= 0) { if (GETPOST('socid', 'int') < 1) { setEventMessages($langs->trans('ErrorFieldRequired', $langs->transnoentities('Supplier')), null, 'errors'); $action = 'create'; @@ -943,7 +990,7 @@ if (empty($reshook)) { if (!$error && GETPOST('origin', 'alpha') && GETPOST('originid')) { // Parse element/subelement (ex: project_task) $element = $subelement = GETPOST('origin', 'alpha'); - /*if (preg_match('/^([^_]+)_([^_]+)/i',$_POST['origin'],$regs)) + /*if (preg_match('/^([^_]+)_([^_]+)/i', GETPOST('origin'),$regs)) { $element = $regs[1]; $subelement = $regs[2]; @@ -1297,7 +1344,7 @@ if (empty($reshook)) { $localtax2_tx = get_localtax($tva_tx, 2, $mysoc, $object->thirdparty); $remise_percent = price2num(GETPOST('remise_percent'), '', 2); - $pu_ht_devise = price2num(GETPOST('multicurrency_subprice'), 'MU', 2); + $pu_devise = price2num(GETPOST('multicurrency_subprice'), 'MU', 2); // Extrafields Lines $extralabelsline = $extrafields->fetch_name_optionals_label($object->table_element_line); @@ -1309,7 +1356,7 @@ if (empty($reshook)) { } } - $result = $object->updateline(GETPOST('lineid', 'int'), $label, $up, $tva_tx, $localtax1_tx, $localtax2_tx, price2num(GETPOST('qty'), 'MS'), GETPOST('productid', 'int'), $price_base_type, $info_bits, $type, $remise_percent, 0, $date_start, $date_end, $array_options, GETPOST('units'), $pu_ht_devise, GETPOST('fourn_ref', 'alpha')); + $result = $object->updateline(GETPOST('lineid', 'int'), $label, $up, $tva_tx, $localtax1_tx, $localtax2_tx, price2num(GETPOST('qty'), 'MS'), GETPOST('productid', 'int'), $price_base_type, $info_bits, $type, $remise_percent, 0, $date_start, $date_end, $array_options, GETPOST('units'), $pu_devise, GETPOST('fourn_ref', 'alpha')); if ($result >= 0) { unset($_POST['label']); unset($_POST['fourn_ref']); @@ -1325,6 +1372,8 @@ if (empty($reshook)) { unset($_POST['date_endday']); unset($_POST['date_endmonth']); unset($_POST['date_endyear']); + unset($_POST['price_ttc']); + unset($_POST['price_ht']); $db->commit(); } else { @@ -1332,6 +1381,7 @@ if (empty($reshook)) { setEventMessages($object->error, $object->errors, 'errors'); } } elseif ($action == 'addline' && $usercancreate) { + // Add a product line $db->begin(); $ret = $object->fetch($id); @@ -1353,17 +1403,22 @@ if (empty($reshook)) { $prod_entry_mode = GETPOST('prod_entry_mode'); if ($prod_entry_mode == 'free') { $idprod = 0; - $price_ht = price2num(GETPOST('price_ht'), 'MU', 2); - $tva_tx = (GETPOST('tva_tx') ? GETPOST('tva_tx') : 0); } else { $idprod = GETPOST('idprod', 'int'); - $price_ht = price2num(GETPOST('price_ht'), 'MU', 2); - $tva_tx = ''; } + $tva_tx = (GETPOST('tva_tx') ? GETPOST('tva_tx') : 0); // Can be '1.2' or '1.2 (CODE)' + + $price_ht = price2num(GETPOST('price_ht'), 'MU', 2); + $price_ht_devise = price2num(GETPOST('multicurrency_price_ht'), 'CU', 2); + $price_ttc = price2num(GETPOST('price_ttc'), 'MU', 2); + $price_ttc_devise = price2num(GETPOST('multicurrency_price_ttc'), 'CU', 2); $qty = price2num(GETPOST('qty'.$predef, 'alpha'), 'MS'); - $remise_percent = price2num(GETPOST('remise_percent'.$predef), 2); - $price_ht_devise = price2num(GETPOST('multicurrency_price_ht'), 'MU', 2); + + $remise_percent = (GETPOSTISSET('remise_percent'.$predef) ? price2num(GETPOST('remise_percent'.$predef, 'alpha'), '', 2) : 0); + if (empty($remise_percent)) { + $remise_percent = 0; + } // Extrafields $extralabelsline = $extrafields->fetch_name_optionals_label($object->table_element_line); @@ -1453,8 +1508,8 @@ if (empty($reshook)) { } //If text set in desc is the same as product descpription (as now it's preloaded) whe add it only one time - if ($product_desc==$desc && !empty($conf->global->PRODUIT_AUTOFILL_DESC)) { - $product_desc=''; + if (trim($product_desc) == trim($desc) && !empty($conf->global->PRODUIT_AUTOFILL_DESC)) { + $product_desc = ''; } if (!empty($product_desc) && !empty($conf->global->MAIN_NO_CONCAT_DESCRIPTION)) { $desc = $product_desc; @@ -1463,32 +1518,39 @@ if (empty($reshook)) { $desc = dol_concatdesc($desc, $product_desc, '', !empty($conf->global->MAIN_CHANGE_ORDER_CONCAT_DESCRIPTION)); } - $type = $productsupplier->type; - if (GETPOST('price_ht') != '' || GETPOST('price_ht_devise') != '') { - $price_base_type = 'HT'; - $pu = price2num($price_ht, 'MU'); - $pu_ht_devise = price2num($price_ht_devise, 'CU'); - } else { - $price_base_type = ($productsupplier->fourn_price_base_type ? $productsupplier->fourn_price_base_type : 'HT'); - if (empty($object->multicurrency_code) || ($productsupplier->fourn_multicurrency_code != $object->multicurrency_code)) { // If object is in a different currency and price not in this currency - $pu = $productsupplier->fourn_pu; - $pu_ht_devise = 0; - } else { - $pu = $productsupplier->fourn_pu; - $pu_ht_devise = $productsupplier->fourn_multicurrency_unitprice; - } - } - $ref_supplier = $productsupplier->ref_supplier; - $tva_tx = get_default_tva($object->thirdparty, $mysoc, $productsupplier->id, GETPOST('idprodfournprice', 'alpha')); - $tva_npr = get_default_npr($object->thirdparty, $mysoc, $productsupplier->id, GETPOST('idprodfournprice', 'alpha')); + // Get vat rate + if (!GETPOSTISSET('tva_tx')) { // If vat rate not provided from the form (the form has the priority) + $tva_tx = get_default_tva($object->thirdparty, $mysoc, $productsupplier->id, GETPOST('idprodfournprice', 'alpha')); + $tva_npr = get_default_npr($object->thirdparty, $mysoc, $productsupplier->id, GETPOST('idprodfournprice', 'alpha')); + } if (empty($tva_tx)) { $tva_npr = 0; } $localtax1_tx = get_localtax($tva_tx, 1, $mysoc, $object->thirdparty, $tva_npr); $localtax2_tx = get_localtax($tva_tx, 2, $mysoc, $object->thirdparty, $tva_npr); + $type = $productsupplier->type; + if (GETPOST('price_ht') != '' || GETPOST('price_ht_devise') != '') { + $price_base_type = 'HT'; + $pu = price2num($price_ht, 'MU'); + $pu_devise = price2num($price_ht_devise, 'CU'); + } elseif (GETPOST('price_ttc') != '' || GETPOST('price_ttc_devise') != '') { + $price_base_type = 'TTC'; + $pu = price2num($price_ttc, 'MU'); + $pu_devise = price2num($price_ttc_devise, 'CU'); + } else { + $price_base_type = ($productsupplier->fourn_price_base_type ? $productsupplier->fourn_price_base_type : 'HT'); + if (empty($object->multicurrency_code) || ($productsupplier->fourn_multicurrency_code != $object->multicurrency_code)) { // If object is in a different currency and price not in this currency + $pu = $productsupplier->fourn_pu; + $pu_devise = 0; + } else { + $pu = $productsupplier->fourn_pu; + $pu_devise = $productsupplier->fourn_multicurrency_unitprice; + } + } + if (empty($pu)) { $pu = 0; // If pu is '' or null, we force to have a numeric value } @@ -1513,7 +1575,7 @@ if (empty($reshook)) { $array_options, $productsupplier->fk_unit, 0, - $pu_ht_devise, + $pu_devise, $ref_supplier, '' ); @@ -1555,9 +1617,9 @@ if (empty($reshook)) { $pu_ht = price2num($pu_ttc / (1 + ($tva_tx / 100)), 'MU'); // $pu_ht must be rounded according to settings } $price_base_type = 'HT'; - $pu_ht_devise = price2num($price_ht_devise, 'CU'); + $pu_devise = price2num($price_devise, 'CU'); - $result = $object->addline($product_desc, $pu_ht, $tva_tx, $localtax1_tx, $localtax2_tx, $qty, 0, $remise_percent, $date_start, $date_end, 0, $tva_npr, $price_base_type, $type, -1, 0, $array_options, $fk_unit, 0, $pu_ht_devise, $ref_supplier); + $result = $object->addline($product_desc, $pu_ht, $tva_tx, $localtax1_tx, $localtax2_tx, $qty, 0, $remise_percent, $date_start, $date_end, 0, $tva_npr, $price_base_type, $type, -1, 0, $array_options, $fk_unit, 0, $pu_devise, $ref_supplier); } //print "xx".$tva_tx; exit; @@ -1892,7 +1954,7 @@ if ($action == 'create') { $datetmp = dol_mktime(12, 0, 0, GETPOST('remonth', 'int'), GETPOST('reday', 'int'), GETPOST('reyear', 'int')); $dateinvoice = ($datetmp == '' ? (empty($conf->global->MAIN_AUTOFILL_DATE) ?-1 : '') : $datetmp); - $datetmp = dol_mktime(12, 0, 0, $_POST['echmonth'], $_POST['echday'], $_POST['echyear']); + $datetmp = dol_mktime(12, 0, 0, GETPOST('echmonth', 'int'), GETPOST('echday', 'int'), GETPOST('echyear', 'int')); $datedue = ($datetmp == '' ?-1 : $datetmp); // Replicate extrafields @@ -1905,7 +1967,7 @@ if ($action == 'create') { $fk_account = $societe->fk_account; $datetmp = dol_mktime(12, 0, 0, GETPOST('remonth', 'int'), GETPOST('reday', 'int'), GETPOST('reyear', 'int')); $dateinvoice = ($datetmp == '' ? (empty($conf->global->MAIN_AUTOFILL_DATE) ?-1 : '') : $datetmp); - $datetmp = dol_mktime(12, 0, 0, $_POST['echmonth'], $_POST['echday'], $_POST['echyear']); + $datetmp = dol_mktime(12, 0, 0, GETPOST('echmonth', 'int'), GETPOST('echday', 'int'), GETPOST('echyear', 'int')); $datedue = ($datetmp == '' ?-1 : $datetmp); if (!empty($conf->multicurrency->enabled) && !empty($soc->multicurrency_code)) { @@ -1945,34 +2007,110 @@ if ($action == 'create') { // Ref print ''.$langs->trans('Ref').''.$langs->trans('Draft').''; + $exampletemplateinvoice = new FactureFournisseurRec($db); + $invoice_predefined = new FactureFournisseurRec($db); + if (empty($origin) && empty($originid) && GETPOST('fac_rec', 'int') > 0) { + $invoice_predefined->fetch(GETPOST('fac_rec', 'int')); + } + // Third party print ''.$langs->trans('Supplier').''; print ''; - if ($societe->id > 0) { + if ($societe->id > 0 && (!GETPOST('fac_rec', 'int') || !empty($invoice_predefined->frequency))) { $absolute_discount = $societe->getAvailableDiscounts('', '', 0, 1); print $societe->getNomUrl(1, 'supplier'); print ''; } else { - print img_picto('', 'company').$form->select_company($societe->id, 'socid', 's.fournisseur=1', 'SelectThirdParty', 0, 0, null, 0, 'minwidth300 widthcentpercentminusxx'); + print img_picto('', 'company').$form->select_company($societe->id, 'socid', 's.fournisseur=1', 'SelectThirdParty', 0, 0, null, 0, 'minwidth300 widthcentpercentminusxx maxwidth500'); // reload page to retrieve supplier informations if (!empty($conf->global->RELOAD_PAGE_ON_SUPPLIER_CHANGE)) { print ''; } - print ' '; + if (!GETPOST('fac_rec', 'int')) { + print ' '; + } } print ''; + // Overwrite some values if creation of invoice is from a predefined invoice + if (empty($origin) && empty($originid) && GETPOST('fac_rec', 'int') > 0) { + $invoice_predefined->fetch(GETPOST('fac_rec', 'int')); + + $dateinvoice = $invoice_predefined->date_when; // To use next gen date by default later + if (empty($projectid)) { + $projectid = $invoice_predefined->fk_project; + } + $cond_reglement_id = $invoice_predefined->cond_reglement_id; + $mode_reglement_id = $invoice_predefined->mode_reglement_id; + $fk_account = $invoice_predefined->fk_account; + $note_public = $invoice_predefined->note_public; + $note_private = $invoice_predefined->note_private; + + if (!empty($invoice_predefined->multicurrency_code)) { + $currency_code = $invoice_predefined->multicurrency_code; + } + if (!empty($invoice_predefined->multicurrency_tx)) { + $currency_tx = $invoice_predefined->multicurrency_tx; + } + + $sql = 'SELECT r.rowid, r.titre as title, r.total_ttc'; + $sql .= ' FROM '.MAIN_DB_PREFIX.'facture_fourn_rec as r'; + $sql .= ' WHERE r.fk_soc = '. (int) $invoice_predefined->socid; + + $resql = $db->query($sql); + if ($resql) { + $num = $db->num_rows($resql); + $i = 0; + + if ($num > 0) { + print ''.$langs->trans('CreateFromRepeatableInvoice').''; + //print ''; + print ''; + // Option to reload page to retrieve customer informations. Note, this clear other input + if (empty($conf->global->RELOAD_PAGE_ON_TEMPLATE_CHANGE_DISABLED)) { + print ''; + } + print ''; + } + $db->free($resql); + } else { + dol_print_error($db); + } + } + // Ref supplier - print ''.$langs->trans('RefSupplier').''.$langs->trans('RefSupplier').'id > 0) { print ' autofocus'; } @@ -1995,7 +2133,7 @@ if ($action == 'create') { if (empty($conf->global->INVOICE_DISABLE_DEPOSIT)) { print '
    '; $tmp=' '; - print ' + fk_user == 0) { + return $langs->trans("VacantPosition"); + } + return parent::showOutputField($val, $key, $value, $moreparam, $keysuffix, $keyprefix, $morecss); + } + + + /** * Load the info information in the object * * @param int $id Id of object @@ -1072,7 +1143,7 @@ require_once DOL_DOCUMENT_ROOT . '/core/class/commonobjectline.class.php'; class PositionLine extends CommonObjectLine { // To complete with content of an object PositionLine - // We should have a field rowid, fk_position and position + // We should have a field rowid , fk_position and position /** * @var int Does object support extrafields ? 0=No, 1=Yes diff --git a/htdocs/hrm/class/skill.class.php b/htdocs/hrm/class/skill.class.php index 478b267ac1f..724c14b93c0 100644 --- a/htdocs/hrm/class/skill.class.php +++ b/htdocs/hrm/class/skill.class.php @@ -241,29 +241,46 @@ class Skill extends CommonObject } /** - * @param int $i rank from which we want to create skilldets + * createSkills + * + * @param int $i Rank from which we want to create skilldets (level $i to HRM_MAXRANK wil be created) * @return null */ public function createSkills($i = 1) { - global $conf, $user, $langs; $MaxNumberSkill = isset($conf->global->HRM_MAXRANK) ? $conf->global->HRM_MAXRANK : self::DEFAULT_MAX_RANK_PER_SKILL; $defaultSkillDesc = !empty($conf->global->HRM_DEFAULT_SKILL_DESCRIPTION) ? $conf->global->HRM_DEFAULT_SKILL_DESCRIPTION : 'no Description'; + + $error = 0; + require_once __DIR__ . '/skilldet.class.php'; + + $this->db->begin(); + + // Create level of skills for ($i; $i <= $MaxNumberSkill ; $i++) { $skilldet = new Skilldet($this->db); - $skilldet->description = $defaultSkillDesc . " " . $i ; - $skilldet->rank = $i; + $skilldet->description = $defaultSkillDesc . " " . $i; + $skilldet->rankorder = $i; $skilldet->fk_skill = $this->id; $result = $skilldet->create($user); - - if ($result > 0) { - setEventMessage($langs->trans('TraductionCreadted'), $i); + if ($result <= 0) { + $error++; } } + + if (! $error) { + $this->db->commit(); + + setEventMessage($langs->trans('SkillCreated'), $i); + return 1; + } else { + $this->db->rollback(); + return -1; + } } /** @@ -384,7 +401,7 @@ class Skill extends CommonObject /** * Load object lines in memory from the database * - * @return array|int <0 if KO, 0 if not found, array if OK + * @return array <0 if KO, array of skill level found */ public function fetchLines() { @@ -393,7 +410,13 @@ class Skill extends CommonObject $skilldet = new Skilldet($this->db); $this->lines = $skilldet->fetchAll('ASC', '', '', '', array('fk_skill' => $this->id), ''); - return (count($this->lines) > 0 ) ? $this->lines : 0; + if (is_array($this->lines)) { + return (count($this->lines) > 0) ? $this->lines : array(); + } elseif ($this->lines < 0) { + $this->errors = array_merge($this->errors, $skilldet->errors); + $this->error = $skilldet->error; + return $this->lines; + } } @@ -830,8 +853,8 @@ class Skill extends CommonObject //if ($withpicto != 2) $result.=(($addlabel && $this->label) ? $sep . dol_trunc($this->label, ($addlabel > 1 ? $addlabel : 0)) : ''); global $action, $hookmanager; - $hookmanager->initHooks(array('jobdao')); - $parameters = array('id'=>$this->id, 'getnomurl'=>$result); + $hookmanager->initHooks(array('skilldao')); + $parameters = array('id'=>$this->id, 'getnomurl' => &$result); $reshook = $hookmanager->executeHooks('getNomUrl', $parameters, $this, $action); // Note that $action and $object may have been modified by some hooks if ($reshook > 0) { $result = $hookmanager->resPrint; @@ -955,7 +978,7 @@ class Skill extends CommonObject $this->lines = array(); $objectline = new SkillLine($this->db); - $result = $objectline->fetchAll('ASC', 'rank', 0, 0, array('customsql'=>'fk_skill = '.$this->id)); + $result = $objectline->fetchAll('ASC', 'rankorder', 0, 0, array('customsql'=>'fk_skill = '.$this->id)); if (is_numeric($result)) { $this->error = $this->error; diff --git a/htdocs/hrm/class/skilldet.class.php b/htdocs/hrm/class/skilldet.class.php index 1fb90b907db..5e2da1ba7aa 100644 --- a/htdocs/hrm/class/skilldet.class.php +++ b/htdocs/hrm/class/skilldet.class.php @@ -104,18 +104,18 @@ class Skilldet extends CommonObject */ public $fields=array( 'rowid' => array('type'=>'integer', 'label'=>'TechnicalID', 'enabled'=>'1', 'position'=>1, 'notnull'=>1, 'visible'=>0, 'noteditable'=>'1', 'index'=>1, 'css'=>'left', 'comment'=>"Id"), - 'rank' => array('type'=>'integer', 'label'=>'rank', 'enabled'=>'1', 'position'=>2, 'notnull'=>0, 'visible'=>2,), + 'fk_skill' => array('type'=>'integer:Skill:/hrm/class/skill.class.php', 'label'=>'fk_skill', 'enabled'=>'1', 'position'=>5, 'notnull'=>1, 'visible'=>0,), + 'rankorder' => array('type'=>'integer', 'label'=>'rank', 'enabled'=>'1', 'position'=>10, 'notnull'=>0, 'visible'=>2,), 'description' => array('type'=>'text', 'label'=>'Description', 'enabled'=>'1', 'position'=>60, 'notnull'=>0, 'visible'=>1,), 'fk_user_creat' => array('type'=>'integer:User:user/class/user.class.php', 'label'=>'UserAuthor', 'enabled'=>'1', 'position'=>510, 'notnull'=>1, 'visible'=>-2, 'foreignkey'=>'user.rowid',), 'fk_user_modif' => array('type'=>'integer:User:user/class/user.class.php', 'label'=>'UserModif', 'enabled'=>'1', 'position'=>511, 'notnull'=>-1, 'visible'=>0,), - 'fk_skill' => array('type'=>'integer:Skill:/hrm/class/skill.class.php', 'label'=>'fk_skill', 'enabled'=>'1', 'position'=>513, 'notnull'=>1, 'visible'=>0,), ); public $rowid; + public $fk_skill; + public $rankorder; public $description; public $fk_user_creat; public $fk_user_modif; - public $fk_skill; - public $rank; // END MODULEBUILDER PROPERTIES @@ -768,7 +768,7 @@ class Skilldet extends CommonObject global $action, $hookmanager; $hookmanager->initHooks(array('skilldetdao')); - $parameters = array('id'=>$this->id, 'getnomurl'=>$result); + $parameters = array('id'=>$this->id, 'getnomurl' => &$result); $reshook = $hookmanager->executeHooks('getNomUrl', $parameters, $this, $action); // Note that $action and $object may have been modified by some hooks if ($reshook > 0) { $result = $hookmanager->resPrint; diff --git a/htdocs/hrm/class/skillrank.class.php b/htdocs/hrm/class/skillrank.class.php index a07015ef763..eb93208040b 100644 --- a/htdocs/hrm/class/skillrank.class.php +++ b/htdocs/hrm/class/skillrank.class.php @@ -107,7 +107,7 @@ class SkillRank extends CommonObject public $fields=array( 'rowid' => array('type'=>'integer', 'label'=>'TechnicalID', 'enabled'=>'1', 'position'=>1, 'notnull'=>1, 'visible'=>0, 'noteditable'=>'1', 'index'=>1, 'css'=>'left', 'comment'=>"Id"), 'fk_skill' => array('type'=>'integer:Skill:hrm/class/skill.class.php:1', 'label'=>'Skill', 'enabled'=>'1', 'position'=>3, 'notnull'=>1, 'visible'=>1, 'index'=>1,), - 'rank' => array('type'=>'integer', 'label'=>'Rank', 'enabled'=>'1', 'position'=>4, 'notnull'=>1, 'visible'=>1, 'default' => 0), + 'rankorder' => array('type'=>'integer', 'label'=>'Rank', 'enabled'=>'1', 'position'=>4, 'notnull'=>1, 'visible'=>1, 'default' => 0), 'fk_object' => array('type'=>'integer', 'label'=>'object', 'enabled'=>'1', 'position'=>5, 'notnull'=>1, 'visible'=>0,), 'date_creation' => array('type'=>'datetime', 'label'=>'DateCreation', 'enabled'=>'1', 'position'=>500, 'notnull'=>1, 'visible'=>-2,), 'tms' => array('type'=>'timestamp', 'label'=>'DateModification', 'enabled'=>'1', 'position'=>501, 'notnull'=>0, 'visible'=>-2,), @@ -371,7 +371,7 @@ class SkillRank extends CommonObject global $user; $this->fk_skill = $currentSkill->fk_skill; - $this->rank = $currentSkill->rank; + $this->rankorder = $currentSkill->rankorder; $this->fk_object = $fk_user; $this->date_creation = dol_now(); $this->fk_user_creat = $user->id; @@ -807,7 +807,7 @@ class SkillRank extends CommonObject global $action, $hookmanager; $hookmanager->initHooks(array('skillrankdao')); - $parameters = array('id'=>$this->id, 'getnomurl'=>$result); + $parameters = array('id'=>$this->id, 'getnomurl' => &$result); $reshook = $hookmanager->executeHooks('getNomUrl', $parameters, $this, $action); // Note that $action and $object may have been modified by some hooks if ($reshook > 0) { $result = $hookmanager->resPrint; diff --git a/htdocs/hrm/compare.php b/htdocs/hrm/compare.php index 13b83af9737..c8bb01d85e5 100644 --- a/htdocs/hrm/compare.php +++ b/htdocs/hrm/compare.php @@ -36,21 +36,25 @@ require_once '../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/functions.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; - -ini_set('display_errors', 1); - require_once DOL_DOCUMENT_ROOT . '/hrm/class/skill.class.php'; require_once DOL_DOCUMENT_ROOT . '/hrm/class/job.class.php'; require_once DOL_DOCUMENT_ROOT . '/hrm/class/evaluation.class.php'; require_once DOL_DOCUMENT_ROOT . '/hrm/class/position.class.php'; require_once DOL_DOCUMENT_ROOT . '/hrm/lib/hrm.lib.php'; -$permissiontoread = $user->rights->hrm->compare->read; +$permissiontoread = $user->rights->hrm->evaluation->read || $user->rights->hrm->compare_advance->read; +$permissiontoadd = 0; if (empty($conf->hrm->enabled)) accessforbidden(); if (!$permissiontoread || ($action === 'create' && !$permissiontoadd)) accessforbidden(); $langs->load('hrm'); + + +/* + * View + */ + $css = array(); $css[] = '/hrm/css/style.css'; llxHeader('', $langs->trans('SkillComparison'), '', '', 0, 0, '', $css); @@ -256,10 +260,13 @@ $fk_usergroup1 = GETPOST('fk_usergroup1');
    fk_skill])) $Tab[$sk->fk_skill] = new stdClass; - $Tab[$sk->fk_skill]->rate1 = $sk->rank; + $Tab[$sk->fk_skill]->rate1 = $sk->rankorder; $Tab[$sk->fk_skill]->how_many_max1 = $sk->how_many_max; $Tab[$sk->fk_skill]->label = $sk->label; $Tab[$sk->fk_skill]->description = $sk->description; @@ -373,7 +380,7 @@ function mergeSkills($TSkill1, $TSkill2) foreach ($TSkill2 as &$sk) { if (empty($Tab[$sk->fk_skill])) $Tab[$sk->fk_skill] = new stdClass; - $Tab[$sk->fk_skill]->rate2 = $sk->rank; + $Tab[$sk->fk_skill]->rate2 = $sk->rankorder; $Tab[$sk->fk_skill]->label = $sk->label; $Tab[$sk->fk_skill]->description = $sk->description; $Tab[$sk->fk_skill]->how_many_max2 = $sk->how_many_max; @@ -474,7 +481,7 @@ function getSkillForUsers($TUser) if (empty($TUser)) return array(); $sql = 'SELECT sk.rowid, sk.label, sk.description, sk.skill_type, sr.fk_object, sr.objecttype, sr.fk_skill, '; - $sql.= ' MAX(sr.rank) as "rank"'; + $sql.= ' MAX(sr.rankorder) as "rankorder"'; $sql.= ' FROM '.MAIN_DB_PREFIX.'hrm_skill sk'; $sql.= ' LEFT JOIN '.MAIN_DB_PREFIX.'hrm_skillrank sr ON (sk.rowid = sr.fk_skill)'; $sql.= " WHERE sr.objecttype = '".SkillRank::SKILLRANK_TYPE_USER."'"; @@ -489,7 +496,7 @@ function getSkillForUsers($TUser) $num = 0; while ($obj = $db->fetch_object($resql) ) { $sql1 = "SELECT count(*) as how_many_max FROM ".MAIN_DB_PREFIX."hrm_skillrank sr"; - $sql1.=" WHERE sr.rank = ".((int) $obj->rank); + $sql1.=" WHERE sr.rankorder = ".((int) $obj->rankorder); $sql1.=" AND sr.objecttype = '".Skillrank::SKILLRANK_TYPE_USER."'"; $sql1.=" AND sr.fk_skill = ".((int) $obj->fk_skill); $sql1.=" AND sr.fk_object IN (".$db->sanitize(implode(',', $TUser)).")"; @@ -504,7 +511,7 @@ function getSkillForUsers($TUser) $Tab[$num]->skill_type = $obj->skill_type; $Tab[$num]->fk_object = $obj->fk_object; $Tab[$num]->objectType = SkillRank::SKILLRANK_TYPE_USER; - $Tab[$num]->rank = $obj->rank; + $Tab[$num]->rankorder = $obj->rankorder; $Tab[$num]->how_many_max = $objMax->how_many_max; $num++; @@ -529,7 +536,7 @@ function getSkillForJob($fk_job) if (empty($fk_job)) return array(); $sql = 'SELECT sk.rowid, sk.label, sk.description, sk.skill_type, sr.fk_object, sr.objecttype, sr.fk_skill, '; - $sql.= ' MAX(sr.rank) as "rank"'; + $sql.= ' MAX(sr.rankorder) as "rankorder"'; $sql.=' FROM '.MAIN_DB_PREFIX.'hrm_skill sk'; $sql.=' LEFT JOIN '.MAIN_DB_PREFIX.'hrm_skillrank sr ON (sk.rowid = sr.fk_skill)'; $sql.=" WHERE sr.objecttype = '".SkillRank::SKILLRANK_TYPE_JOB."'"; @@ -552,7 +559,7 @@ function getSkillForJob($fk_job) //$Tab[$num]->date_end = ''; // du poste $Tab[$num]->fk_object = $obj->fk_object; $Tab[$num]->objectType = SkillRank::SKILLRANK_TYPE_JOB; - $Tab[$num]->rank = $obj->rank; + $Tab[$num]->rankorder = $obj->rankorder; $Tab[$num]->how_many_max = $obj->how_many_max; $num++; diff --git a/htdocs/hrm/core/tpl/objectline_view.tpl.php b/htdocs/hrm/core/tpl/objectline_view.tpl.php index 9be74a5f38f..ce436ca604a 100644 --- a/htdocs/hrm/core/tpl/objectline_view.tpl.php +++ b/htdocs/hrm/core/tpl/objectline_view.tpl.php @@ -57,11 +57,6 @@ $domData .= ' data-id="'.$line->id.'"'; $domData .= ' data-qty="'.$line->qty.'"'; $domData .= ' data-product_type="'.$line->product_type.'"'; -$sign = 1; -if (!empty($conf->global->INVOICE_POSITIVE_CREDIT_NOTE_SCREEN) && in_array($object->element, array('facture', 'invoice_supplier')) && $object->type == $object::TYPE_CREDIT_NOTE) { - $sign = -1; -} - $coldisplay = 0; ?> @@ -98,7 +93,7 @@ print ''; rank, $line->fk_skill, 'TNote', ($this->status == 0 && $permissiontoadd) ? 'edit' : 'view'); + print displayRankInfos($line->rankorder, $line->fk_skill, 'TNote', ($this->status == 0 && $permissiontoadd) ? 'edit' : 'view'); ?> diff --git a/htdocs/hrm/css/radio_js_number.css b/htdocs/hrm/css/radio_js_number.css deleted file mode 100644 index 320b0ddc1f2..00000000000 --- a/htdocs/hrm/css/radio_js_number.css +++ /dev/null @@ -1,18 +0,0 @@ -.radio_js_bloc_number { - display:inline-block; - padding:5px 7px; - min-width:20px; - border-radius:3px; - border:1px solid #ccc; - background:#eee; - color:#555; - cursor:pointer; - margin:2px; - text-align:center; -} -.radio_js_bloc_number.selected { - transition:0.2s ease background; - background:#888; - color:#fff; - border-color:#555; -} \ No newline at end of file diff --git a/htdocs/hrm/establishment/card.php b/htdocs/hrm/establishment/card.php index 0ce7d793003..1fe67dd0bd1 100644 --- a/htdocs/hrm/establishment/card.php +++ b/htdocs/hrm/establishment/card.php @@ -135,14 +135,14 @@ if ($action == 'confirm_delete' && $confirm == "yes") { $result = $object->update($user); if ($result > 0) { - header("Location: ".$_SERVER["PHP_SELF"]."?id=".$_POST['id']); + header("Location: ".$_SERVER["PHP_SELF"]."?id=".GETPOST('id', 'int')); exit; } else { setEventMessages($object->error, $object->errors, 'errors'); } } } else { - header("Location: ".$_SERVER["PHP_SELF"]."?id=".$_POST['id']); + header("Location: ".$_SERVER["PHP_SELF"]."?id=".GETPOST('id', 'int')); exit; } } diff --git a/htdocs/hrm/establishment/info.php b/htdocs/hrm/establishment/info.php index 30dbd932dcb..b1f7057f6a5 100644 --- a/htdocs/hrm/establishment/info.php +++ b/htdocs/hrm/establishment/info.php @@ -46,8 +46,8 @@ if (GETPOST('actioncode', 'array')) { $search_agenda_label = GETPOST('search_agenda_label'); $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/hrm/evaluation_agenda.php b/htdocs/hrm/evaluation_agenda.php index 91a0615bc95..87a09043a62 100644 --- a/htdocs/hrm/evaluation_agenda.php +++ b/htdocs/hrm/evaluation_agenda.php @@ -58,8 +58,8 @@ if (GETPOST('actioncode', 'array')) { $search_agenda_label = GETPOST('search_agenda_label'); $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/hrm/evaluation_card.php b/htdocs/hrm/evaluation_card.php index 28e030ffc42..7b0b7bcfd7d 100644 --- a/htdocs/hrm/evaluation_card.php +++ b/htdocs/hrm/evaluation_card.php @@ -82,7 +82,7 @@ include DOL_DOCUMENT_ROOT.'/core/actions_fetchobject.inc.php'; // Must be includ $permissiontoread = $user->rights->hrm->evaluation->read; $permissiontoadd = $user->rights->hrm->evaluation->write; // Used by the include of actions_addupdatedelete.inc.php and actions_lineupdown.inc.php -$permissiontovalidate = $user->rights->hrm->evaluation->validate; +$permissiontovalidate = $user->rights->hrm->evaluation_advance->validate; $permissiontoClose = $user->rights->hrm->evaluation->write; $permissiontodelete = $user->rights->hrm->evaluation->delete/* || ($permissiontoadd && isset($object->status) && $object->status == $object::STATUS_DRAFT)*/; $permissiondellink = $user->rights->hrm->evaluation->write; // Used by the include of actions_dellink.inc.php @@ -156,7 +156,7 @@ if (empty($reshook)) { $TNote = GETPOST('TNote', 'array'); if (!empty($TNote)) { foreach ($object->lines as $line) { - $line->rank = $TNote[$line->fk_skill]; + $line->rankorder = $TNote[$line->fk_skill]; $line->update($user); } } @@ -172,16 +172,12 @@ if (empty($reshook)) { foreach ($object->lines as $key => $line) { // no reference .. we add the line to use it if (count($SkillrecordsForActiveUser) == 0) { - if ($res > 0) { - $newSkill = new SkillRank($db); - $resCreate = $newSkill->cloneFromCurrentSkill($line, $object->fk_user); + $newSkill = new SkillRank($db); + $resCreate = $newSkill->cloneFromCurrentSkill($line, $object->fk_user); - if ($resCreate <= 0) { - $errors++; - setEventMessage($langs->trans('ErrorCreateUserSkill'), $line->fk_skill); - } - } else { - setEventMessage($langs->trans('NoSkilRankLoaded')); + if ($resCreate <= 0) { + $errors++; + setEventMessage($langs->trans('ErrorCreateUserSkill'), $line->fk_skill); } } else { //check if the skill is present to use it @@ -198,7 +194,7 @@ if (empty($reshook)) { if ($find) { $updSkill = $SkillrecordsForActiveUser[$k]; - $updSkill->rank = $line->rank; + $updSkill->rankorder = $line->rankorder; $updSkill->update($user); } else { // sinon on ajoute la skill $newSkill = new SkillRank($db); @@ -273,9 +269,6 @@ if ($action == 'create') { print dol_get_fiche_head(array(), ''); - // Set some default values - //if (! GETPOSTISSET('fieldname')) $_POST['fieldname'] = 'myvalue'; - print ''."\n"; // Common attributes @@ -519,9 +512,9 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea $sql .= ' sk.label as "skilllabel",'; $sql .= ' sk.skill_type,'; $sql .= ' sk.description,'; - $sql .= ' ed.rank,'; + $sql .= ' ed.rankorder,'; $sql .= ' ed.required_rank,'; - $sql .= ' ed.rank as "userRankForSkill",'; + $sql .= ' ed.rankorder as "userRankForSkill",'; $sql .= ' skdet_user.description as "userRankForSkillDesc",'; $sql .= ' skdet_required.description as "required_rank_desc"'; @@ -529,9 +522,9 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea $sql .= ' LEFT JOIN ' . MAIN_DB_PREFIX . 'hrm_evaluationdet as ed ON e.rowid = ed.fk_evaluation'; $sql .= ' LEFT JOIN ' . MAIN_DB_PREFIX . 'hrm_job as j ON e.fk_job = j.rowid'; $sql .= ' LEFT JOIN ' . MAIN_DB_PREFIX . 'hrm_skill as sk ON ed.fk_skill = sk.rowid'; - $sql .= ' INNER JOIN ' . MAIN_DB_PREFIX . 'hrm_skilldet as skdet_user ON (skdet_user.fk_skill = sk.rowid AND skdet_user.rank = ed.rank)'; + $sql .= ' INNER JOIN ' . MAIN_DB_PREFIX . 'hrm_skilldet as skdet_user ON (skdet_user.fk_skill = sk.rowid AND skdet_user.rankorder = ed.rankorder)'; //$sql .= " LEFT JOIN " . MAIN_DB_PREFIX . "hrm_skillrank as skr ON (j.rowid = skr.fk_object AND skr.fk_skill = ed.fk_skill AND skr.objecttype = 'job')"; - $sql .= ' LEFT JOIN ' . MAIN_DB_PREFIX . 'hrm_skilldet as skdet_required ON (skdet_required.fk_skill = sk.rowid AND skdet_required.rank = ed.required_rank)'; + $sql .= ' LEFT JOIN ' . MAIN_DB_PREFIX . 'hrm_skilldet as skdet_required ON (skdet_required.fk_skill = sk.rowid AND skdet_required.rankorder = ed.required_rank)'; $sql .= " WHERE e.rowid =" . ((int) $object->id); // echo $sql; @@ -686,14 +679,12 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea $MAXEVENT = 10; - $morehtmlright = ''; - $morehtmlright .= $langs->trans("SeeAll"); - $morehtmlright .= ''; + $morehtmlcenter = dolGetButtonTitle($langs->trans('SeeAll'), '', 'fa fa-list-alt imgforviewmode', DOL_URL_ROOT.'/hrm/evaluation_agenda.php?id='.$object->id); // List of actions on element include_once DOL_DOCUMENT_ROOT.'/core/class/html.formactions.class.php'; $formactions = new FormActions($db); - $somethingshown = $formactions->showactions($object, $object->element.'@'.$object->module, (is_object($object->thirdparty) ? $object->thirdparty->id : 0), 1, '', $MAXEVENT, '', $morehtmlright); + $somethingshown = $formactions->showactions($object, $object->element.'@'.$object->module, (is_object($object->thirdparty) ? $object->thirdparty->id : 0), 1, '', $MAXEVENT, '', $morehtmlcenter); print ''; } diff --git a/htdocs/hrm/evaluation_document.php b/htdocs/hrm/evaluation_document.php index 7318819644e..215756eff8b 100644 --- a/htdocs/hrm/evaluation_document.php +++ b/htdocs/hrm/evaluation_document.php @@ -48,8 +48,8 @@ $ref = GETPOST('ref', 'alpha'); // Get parameters $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/hrm/evaluation_list.php b/htdocs/hrm/evaluation_list.php index 35189f11b87..ad99573b096 100644 --- a/htdocs/hrm/evaluation_list.php +++ b/htdocs/hrm/evaluation_list.php @@ -114,11 +114,11 @@ $arrayfields = array(); foreach ($object->fields as $key => $val) { // If $val['visible']==0, then we never show the field if (!empty($val['visible'])) { - $visible = (int) dol_eval($val['visible'], 1); + $visible = (int) dol_eval($val['visible'], 1, 1, '1'); $arrayfields['t.'.$key] = array( 'label'=>$val['label'], 'checked'=>(($visible < 0) ? 0 : 1), - 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1)), + 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1, 1, '1')), 'position'=>$val['position'], 'help'=> isset($val['help']) ? $val['help'] : '' ); diff --git a/htdocs/hrm/index.php b/htdocs/hrm/index.php index 0b887667561..2603d73ab81 100644 --- a/htdocs/hrm/index.php +++ b/htdocs/hrm/index.php @@ -52,7 +52,7 @@ $hookmanager = new HookManager($db); $hookmanager->initHooks('hrmindex'); // Load translation files required by the page -$langs->loadLangs(array('users', 'holidays', 'trips', 'boxes')); +$langs->loadLangs(array('users', 'holiday', 'trips', 'boxes')); $socid = GETPOST("socid", "int"); @@ -153,7 +153,7 @@ if (!empty($conf->holiday->enabled)) { print '
    '; print ''; print ''; - print ''; print ''; @@ -222,6 +223,7 @@ if (!empty($conf->holiday->enabled) && $user->rights->holiday->read) { $holidaystatic->id = $obj->rowid; $holidaystatic->ref = $obj->ref; $holidaystatic->statut = $obj->status; + $holidaystatic->date_debut = $db->jdate($obj->date_start); $userstatic->id = $obj->uid; $userstatic->lastname = $obj->lastname; @@ -242,7 +244,7 @@ if (!empty($conf->holiday->enabled) && $user->rights->holiday->read) { print ''; - print ''; + print ''; print ''; $i++; diff --git a/htdocs/hrm/job_agenda.php b/htdocs/hrm/job_agenda.php index d7772763d8d..0d966e67416 100644 --- a/htdocs/hrm/job_agenda.php +++ b/htdocs/hrm/job_agenda.php @@ -57,8 +57,8 @@ if (GETPOST('actioncode', 'array')) { $search_agenda_label = GETPOST('search_agenda_label'); $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; @@ -189,18 +189,13 @@ if ($object->id > 0) { } - print '
    '; - if (!empty($conf->agenda->enabled)) { if (!empty($user->rights->agenda->myactions->create) || !empty($user->rights->agenda->allactions->create)) { - print ''.$langs->trans("AddAction").''; - } else { - print ''.$langs->trans("AddAction").''; + $newcardbutton = ''; + $newcardbutton .= dolGetButtonTitle($langs->trans('AddAction'), '', 'fa fa-plus-circle', DOL_URL_ROOT.'/comm/action/card.php?action=create'.$out); } } - print '
    '; - if (!empty($conf->agenda->enabled) && (!empty($user->rights->agenda->myactions->read) || !empty($user->rights->agenda->allactions->read))) { $param = '&id='.$object->id.'&socid='.$socid; if (!empty($contextpage) && $contextpage != $_SERVER["PHP_SELF"]) { @@ -211,7 +206,7 @@ if ($object->id > 0) { } - //print load_fiche_titre($langs->trans("ActionsOnJob"), '', ''); + print load_fiche_titre($langs->trans("ActionsOnJob"), $newcardbutton, ''); // List of all actions $filters = array(); diff --git a/htdocs/hrm/job_card.php b/htdocs/hrm/job_card.php index 42ee4d6f4b1..906eb83b945 100644 --- a/htdocs/hrm/job_card.php +++ b/htdocs/hrm/job_card.php @@ -195,9 +195,6 @@ if ($action == 'create') { print dol_get_fiche_head(array(), ''); - // Set some default values - //if (! GETPOSTISSET('fieldname')) $_POST['fieldname'] = 'myvalue'; - print '
    '.$langs->trans("Holidays").'
    '; + print ''; $out = ''; $nb_holiday = 0; @@ -163,8 +163,9 @@ if (!empty($conf->holiday->enabled)) { $nb_holiday += $nb_type; $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; + $balancetoshow = $langs->trans('SoldeCPUser', '{s1}'); + print '
    '.str_replace('{s1}', img_picto('', 'holiday', 'class="paddingleft pictofixedwidth"').''.round($nb_holiday, 5).'', $balancetoshow).'
    '; + print ''.$out.''; print '
    '.dol_print_date($db->jdate($obj->date_start), 'day').' '.$langs->trans($listhalfday[$starthalfday]).''; print ''.dol_print_date($db->jdate($obj->date_end), 'day').' '.$langs->trans($listhalfday[$endhalfday]).''; print ''.dol_print_date($db->jdate($obj->dm), 'day').''.$holidaystatic->LibStatut($obj->status, 3).''.$holidaystatic->LibStatut($obj->status, 3, $holidaystatic->date_debut).'
    ' . "\n"; // Common attributes @@ -454,14 +451,12 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea $MAXEVENT = 10; - $morehtmlright = ''; - $morehtmlright .= $langs->trans("SeeAll"); - $morehtmlright .= ''; + $morehtmlcenter = dolGetButtonTitle($langs->trans('SeeAll'), '', 'fa fa-list-alt imgforviewmode', DOL_URL_ROOT.'/hrm/job_agenda.php?id='.$object->id); // List of actions on element include_once DOL_DOCUMENT_ROOT . '/core/class/html.formactions.class.php'; $formactions = new FormActions($db); - $somethingshown = $formactions->showactions($object, $object->element . '@' . $object->module, (is_object($object->thirdparty) ? $object->thirdparty->id : 0), 1, '', $MAXEVENT, '', $morehtmlright); + $somethingshown = $formactions->showactions($object, $object->element . '@' . $object->module, (is_object($object->thirdparty) ? $object->thirdparty->id : 0), 1, '', $MAXEVENT, '', $morehtmlcenter); print ''; } diff --git a/htdocs/hrm/job_document.php b/htdocs/hrm/job_document.php index a055fbbc325..83745962052 100644 --- a/htdocs/hrm/job_document.php +++ b/htdocs/hrm/job_document.php @@ -46,8 +46,8 @@ $ref = GETPOST('ref', 'alpha'); // Get parameters $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/hrm/job_list.php b/htdocs/hrm/job_list.php index 55363d729b5..7644ea1fd0f 100644 --- a/htdocs/hrm/job_list.php +++ b/htdocs/hrm/job_list.php @@ -114,11 +114,11 @@ $arrayfields = array(); foreach ($object->fields as $key => $val) { // If $val['visible']==0, then we never show the field if (!empty($val['visible'])) { - $visible = (int) dol_eval($val['visible'], 1); + $visible = (int) dol_eval($val['visible'], 1, 1, '1'); $arrayfields['t.'.$key] = array( 'label'=>$val['label'], 'checked'=>(($visible < 0) ? 0 : 1), - 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1)), + 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1, 1, '1')), 'position'=>$val['position'], 'help'=> isset($val['help']) ? $val['help'] : '' ); diff --git a/htdocs/hrm/lib/hrm_skillrank.lib.php b/htdocs/hrm/lib/hrm_skillrank.lib.php index 2aca41504ad..d979e8ca4b7 100644 --- a/htdocs/hrm/lib/hrm_skillrank.lib.php +++ b/htdocs/hrm/lib/hrm_skillrank.lib.php @@ -113,46 +113,50 @@ function displayRankInfos($selected_rank, $fk_skill, $inputname = 'TNote', $mode // On charge les différentes notes possibles pour la compétence $fk_skill $skilldet = new Skilldet($db); - $Lines = $skilldet->fetchAll('ASC', 'rank', 0, 0, array('customsql'=>'fk_skill = '.$fk_skill)); + $Lines = $skilldet->fetchAll('ASC', 'rankorder', 0, 0, array('customsql'=>'fk_skill = '.$fk_skill)); + if (!is_array($Lines) && $Lines<0) { + setEventMessages($skilldet->error, $skilldet->errors, 'errors'); + } if (empty($Lines)) return $langs->trans('SkillHasNoLines'); $ret = '0'; + if (is_array($Lines) && !empty($Lines)) { + foreach ($Lines as $line) { + $MaxNumberSkill = isset($conf->global->HRM_MAXRANK) ? $conf->global->HRM_MAXRANK : Skill::DEFAULT_MAX_RANK_PER_SKILL; + if ($line->rankorder > $MaxNumberSkill) { + continue; + } - foreach ($Lines as $line) { - $MaxNumberSkill = isset($conf->global->HRM_MAXRANK) ? $conf->global->HRM_MAXRANK : Skill::DEFAULT_MAX_RANK_PER_SKILL; - if ($line->rank > $MaxNumberSkill) { - continue; + $ret .= '' . $line->rankorder . ''; } - $ret.= ''.$line->rank.''; - } - - if ($mode == 'edit') { - $ret.= ' - + if ($mode == 'edit') { + $ret .= ' + '; + } } return $ret; diff --git a/htdocs/hrm/position.php b/htdocs/hrm/position.php index 208a397f135..86167ef4024 100644 --- a/htdocs/hrm/position.php +++ b/htdocs/hrm/position.php @@ -42,7 +42,6 @@ //if (! defined("MAIN_LANG_DEFAULT")) define('MAIN_LANG_DEFAULT', 'auto'); // Force lang to a particular value //if (! defined("MAIN_AUTHENTICATION_MODE")) define('MAIN_AUTHENTICATION_MODE', 'aloginmodule'); // Force authentication handler //if (! defined("NOREDIRECTBYMAINTOLOGIN")) define('NOREDIRECTBYMAINTOLOGIN', 1); // The main.inc.php does not make a redirect if not logged, instead show simple error message -//if (! defined("FORCECSP")) define('FORCECSP', 'none'); // Disable all Content Security Policies //if (! defined('CSRFCHECK_WITH_TOKEN')) define('CSRFCHECK_WITH_TOKEN', '1'); // Force use of CSRF protection with tokens even for GET //if (! defined('NOBROWSERNOTIF')) define('NOBROWSERNOTIF', '1'); // Disable browser notification @@ -358,11 +357,11 @@ function DisplayPositionList() foreach ($object->fields as $key => $val) { // If $val['visible']==0, then we never show the field if (!empty($val['visible'])) { - $visible = (int) dol_eval($val['visible'], 1); + $visible = (int) dol_eval($val['visible'], 1, 1, '1'); $arrayfields['t.' . $key] = array( 'label' => $val['label'], 'checked' => (($visible < 0) ? 0 : 1), - 'enabled' => ($visible != 3 && dol_eval($val['enabled'], 1)), + 'enabled' => ($visible != 3 && dol_eval($val['enabled'], 1, 1, '1')), 'position' => $val['position'], 'help' => isset($val['help']) ? $val['help'] : '' ); @@ -916,9 +915,6 @@ if ($action == 'create') { print dol_get_fiche_head(array(), ''); - // Set some default values - //if (! GETPOSTISSET('fieldname')) $_POST['fieldname'] = 'myvalue'; - print '
    ' . "\n"; // Common attributes diff --git a/htdocs/hrm/position_agenda.php b/htdocs/hrm/position_agenda.php index b3b68d9bcbc..fda60a29259 100644 --- a/htdocs/hrm/position_agenda.php +++ b/htdocs/hrm/position_agenda.php @@ -58,8 +58,8 @@ if (GETPOST('actioncode', 'array')) { $search_agenda_label = GETPOST('search_agenda_label'); $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/hrm/position_card.php b/htdocs/hrm/position_card.php index 4d6b36b52f3..c26d981a324 100644 --- a/htdocs/hrm/position_card.php +++ b/htdocs/hrm/position_card.php @@ -276,7 +276,7 @@ function DisplayPositionCard(&$object) $morehtmlref = '
    '; $u_position = new User(($db)); $u_position->fetch($object->fk_user); - $morehtmlref .= $langs->trans('Employee').' : '.$u_position->getNomUrl(1); + $morehtmlref .= $langs->trans('Employee').' : '.($u_position->id > 0 ? $u_position->getNomUrl(1) : ''); $job = new Job($db); $job->fetch($object->fk_job); $morehtmlref .= '
    '.$langs->trans('Job').' : '.$job->getNomUrl(1); @@ -377,13 +377,12 @@ if ($action !== 'edit' && $action !== 'create') { $MAXEVENT = 10; - $morehtmlright = ''; - $morehtmlright .= $langs->trans("SeeAll"); - $morehtmlright .= ''; + $morehtmlcenter = dolGetButtonTitle($langs->trans('SeeAll'), '', 'fa fa-list-alt imgforviewmode', DOL_URL_ROOT.'/hrm/position_agenda.php?id='.$object->id); + // List of actions on element include_once DOL_DOCUMENT_ROOT . '/core/class/html.formactions.class.php'; $formactions = new FormActions($db); - $somethingshown = $formactions->showactions($object, $object->element . '@' . $object->module, (is_object($object->thirdparty) ? $object->thirdparty->id : 0), 1, '', $MAXEVENT, '', $morehtmlright); + $somethingshown = $formactions->showactions($object, $object->element . '@' . $object->module, (is_object($object->thirdparty) ? $object->thirdparty->id : 0), 1, '', $MAXEVENT, '', $morehtmlcenter); print '
    '; } diff --git a/htdocs/hrm/position_document.php b/htdocs/hrm/position_document.php index 7a820310ee2..845f846a212 100644 --- a/htdocs/hrm/position_document.php +++ b/htdocs/hrm/position_document.php @@ -47,8 +47,8 @@ $ref = GETPOST('ref', 'alpha'); // Get parameters $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/hrm/position_list.php b/htdocs/hrm/position_list.php index d6ed72c2612..13315a2a9bc 100644 --- a/htdocs/hrm/position_list.php +++ b/htdocs/hrm/position_list.php @@ -114,11 +114,11 @@ $arrayfields = array(); foreach ($object->fields as $key => $val) { // If $val['visible']==0, then we never show the field if (!empty($val['visible'])) { - $visible = (int) dol_eval($val['visible'], 1); + $visible = (int) dol_eval($val['visible'], 1, 1, '1'); $arrayfields['t.'.$key] = array( 'label'=>$val['label'], 'checked'=>(($visible < 0) ? 0 : 1), - 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1)), + 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1, 1, '1')), 'position'=>$val['position'], 'help'=> isset($val['help']) ? $val['help'] : '' ); @@ -270,6 +270,10 @@ foreach ($search as $key => $val) { } } } +$vacant = GETPOST('search_fk_uservacant', 'alphanohtml') === 'on'; +if ($vacant) { + $sql .= ' AND t.fk_user = 0'; +} if ($search_all) { $sql .= natural_search(array_keys($fieldstosearchall), $search_all); } diff --git a/htdocs/hrm/skill_agenda.php b/htdocs/hrm/skill_agenda.php index 9c1821fb8d7..d73271a4f26 100644 --- a/htdocs/hrm/skill_agenda.php +++ b/htdocs/hrm/skill_agenda.php @@ -57,8 +57,8 @@ if (GETPOST('actioncode', 'array')) { $search_agenda_label = GETPOST('search_agenda_label'); $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; @@ -147,7 +147,7 @@ if ($object->id > 0) { // Object card // ------------------------------------------------------------ - $linkback = ''.$langs->trans("BackToList").''; + $linkback = ''.$langs->trans("BackToList").''; $morehtmlref = '
    '; $morehtmlref.= $object->label; diff --git a/htdocs/hrm/skill_card.php b/htdocs/hrm/skill_card.php index ed66dc4ebb9..e1144f75866 100644 --- a/htdocs/hrm/skill_card.php +++ b/htdocs/hrm/skill_card.php @@ -21,8 +21,8 @@ /** * \file skill_card.php - * \ingroup hrm - * \brief Page to create/edit/view skill + * \ingroup hrm + * \brief Page to create/edit/view skill */ @@ -84,6 +84,8 @@ $upload_dir = $conf->hrm->multidir_output[isset($object->entity) ? $object->enti if (empty($conf->hrm->enabled)) accessforbidden(); if (!$permissiontoread || ($action === 'create' && !$permissiontoadd)) accessforbidden(); +$MaxNumberSkill = isset($conf->global->HRM_MAXRANK) ? $conf->global->HRM_MAXRANK : Skill::DEFAULT_MAX_RANK_PER_SKILL; + /* * Actions @@ -98,14 +100,14 @@ if ($reshook < 0) { if (empty($reshook)) { $error = 0; - $backurlforlist = dol_buildpath('/hrm/skill_list.php', 1); + $backurlforlist = DOL_URL_ROOT.'/hrm/skill_list.php'; if (empty($backtopage) || ($cancel && empty($id))) { if (empty($backtopage) || ($cancel && strpos($backtopage, '__ID__'))) { if (empty($id) && (($action != 'add' && $action != 'create') || $cancel)) { $backtopage = $backurlforlist; } else { - $backtopage = dol_buildpath('/hrm/skill_card.php', 1) . '?id=' . ($id > 0 ? $id : '__ID__'); + $backtopage = DOL_URL_ROOT.'/hrm/skill_card.php?id=' . ($id > 0 ? $id : '__ID__'); } } } @@ -166,8 +168,6 @@ if (empty($reshook)) { /* * View - * - * Put here all code to build page */ $form = new Form($db); @@ -186,9 +186,9 @@ if ($action == 'create') { print '
    '; print ''; print ''; - $backtopage .= "&objecttype=job"; + $backtopage .= (strpos($backtopage, '?') > 0 ? '&' : '?' ) ."objecttype=job"; if ($backtopage) { - print ''; + print ''; } if ($backtopageforcancel) { print ''; @@ -196,9 +196,6 @@ if ($action == 'create') { print dol_get_fiche_head(array(), ''); - // Set some default values - //if (! GETPOSTISSET('fieldname')) $_POST['fieldname'] = 'myvalue'; - print '
    ' . "\n"; // Common attributes @@ -254,12 +251,17 @@ if (($id || $ref) && $action == 'edit') { // SKILLDET print dol_get_fiche_head(array(), ''); + $SkilldetRecords = $object->fetchLines(); + + if (is_array($SkilldetRecords) && count($SkilldetRecords) == 0) { + $object->createSkills(1); + } + if (is_array($SkilldetRecords) && count($SkilldetRecords) > 0) { print '
    '; foreach ($SkilldetRecords as $sk) { - $MaxNumberSkill = isset($conf->global->HRM_MAXRANK) ? $conf->global->HRM_MAXRANK : Skill::DEFAULT_MAX_RANK_PER_SKILL; - if ($sk->rank > $MaxNumberSkill) { + if ($sk->rankorder > $MaxNumberSkill) { continue; } @@ -286,7 +288,7 @@ if (($id || $ref) && $action == 'edit') { // if (!empty($val['help'])) { // print $form->textwithpicto($langs->trans($val['label']), $langs->trans($val['help'])); // } else { - print $langs->trans($val['label']).' '.$langs->trans('rank').' '.$sk->rank; + print $langs->trans($val['label']).' '.$langs->trans('rank').' '.$sk->rankorder; // } print ''; print ''; if ($objecttype != 'user' && $permissiontoadd) { print ''; diff --git a/htdocs/imports/import.php b/htdocs/imports/import.php index 4227aed6afa..01f152f1ea5 100644 --- a/htdocs/imports/import.php +++ b/htdocs/imports/import.php @@ -141,6 +141,7 @@ $endatlinenb = (GETPOST('endatlinenb') ? GETPOST('endatlinenb') : ''); $updatekeys = (GETPOST('updatekeys', 'array') ? GETPOST('updatekeys', 'array') : array()); $separator = (GETPOST('separator', 'nohtml') ? GETPOST('separator', 'nohtml') : (!empty($conf->global->IMPORT_CSV_SEPARATOR_TO_USE) ? $conf->global->IMPORT_CSV_SEPARATOR_TO_USE : ',')); $enclosure = (GETPOST('enclosure', 'nohtml') ? GETPOST('enclosure', 'nohtml') : '"'); +$separator_used = str_replace('\t', "\t", $separator); $objimport = new Import($db); $objimport->load_arrays($user, ($step == 1 ? '' : $datatoimport)); @@ -465,7 +466,7 @@ if ($step == 2 && $datatoimport) { print '
    '; @@ -397,7 +399,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea // Object card // ------------------------------------------------------------ - $linkback = '' . $langs->trans("BackToList") . ''; + $linkback = '' . $langs->trans("BackToList") . ''; $morehtmlref = '
    '; @@ -533,11 +535,11 @@ if ($action != "create" && $action != "edit") { foreach ($objectline->fields as $key => $val) { // If $val['visible']==0, then we never show the field if (!empty($val['visible'])) { - $visible = (int) dol_eval($val['visible'], 1); + $visible = (int) dol_eval($val['visible'], 1, 1, '1'); $arrayfields['t.' . $key] = array( 'label' => $val['label'], 'checked' => (($visible < 0) ? 0 : 1), - 'enabled' => ($visible != 3 && dol_eval($val['enabled'], 1)), + 'enabled' => ($visible != 3 && dol_eval($val['enabled'], 1, 1, '1')), 'position' => $val['position'], 'help' => isset($val['help']) ? $val['help'] : '' ); @@ -691,8 +693,7 @@ if ($action != "create" && $action != "edit") { break; // Should not happen } - $MaxNumberSkill = isset($conf->global->HRM_MAXRANK) ? $conf->global->HRM_MAXRANK : Skill::DEFAULT_MAX_RANK_PER_SKILL; - if ($obj->rank > $MaxNumberSkill) { + if ($obj->rankorder > $MaxNumberSkill) { continue; } @@ -840,13 +841,12 @@ if ($action != "create" && $action != "edit") { $MAXEVENT = 10; - $morehtmlright = ''; - $morehtmlright .= $langs->trans("SeeAll"); - $morehtmlright .= ''; + $morehtmlcenter = dolGetButtonTitle($langs->trans('SeeAll'), '', 'fa fa-list-alt imgforviewmode', DOL_URL_ROOT.'/hrm/skill_agenda.php?id='.$object->id); + // List of actions on element include_once DOL_DOCUMENT_ROOT . '/core/class/html.formactions.class.php'; $formactions = new FormActions($db); - $somethingshown = $formactions->showactions($object, $object->element . '@' . $object->module, (is_object($object->thirdparty) ? $object->thirdparty->id : 0), 1, '', $MAXEVENT, '', $morehtmlright); + $somethingshown = $formactions->showactions($object, $object->element . '@' . $object->module, (is_object($object->thirdparty) ? $object->thirdparty->id : 0), 1, '', $MAXEVENT, '', $morehtmlcenter); print '
    '; } diff --git a/htdocs/hrm/skill_contact.php b/htdocs/hrm/skill_contact.php index f8ea2a04a9f..d8fecd74610 100644 --- a/htdocs/hrm/skill_contact.php +++ b/htdocs/hrm/skill_contact.php @@ -129,7 +129,7 @@ if ($object->id) { print dol_get_fiche_head($head, 'contact', '', -1, $object->picto); - $linkback = ''.$langs->trans("BackToList").''; + $linkback = ''.$langs->trans("BackToList").''; $morehtmlref = '
    '; /* diff --git a/htdocs/hrm/skill_document.php b/htdocs/hrm/skill_document.php index 77f3325de15..f305ecd1e2e 100644 --- a/htdocs/hrm/skill_document.php +++ b/htdocs/hrm/skill_document.php @@ -47,8 +47,8 @@ $ref = GETPOST('ref', 'alpha'); // Get parameters $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; @@ -127,7 +127,7 @@ if ($object->id) { // Object card // ------------------------------------------------------------ - $linkback = ''.$langs->trans("BackToList").''; + $linkback = ''.$langs->trans("BackToList").''; $morehtmlref = '
    '; $morehtmlref.= $object->label; diff --git a/htdocs/hrm/skill_list.php b/htdocs/hrm/skill_list.php index 1fc5440e589..8ef800b3ffc 100644 --- a/htdocs/hrm/skill_list.php +++ b/htdocs/hrm/skill_list.php @@ -114,11 +114,11 @@ $arrayfields = array(); foreach ($object->fields as $key => $val) { // If $val['visible']==0, then we never show the field if (!empty($val['visible'])) { - $visible = (int) dol_eval($val['visible'], 1); + $visible = (int) dol_eval($val['visible'], 1, 1, '1'); $arrayfields['t.'.$key] = array( 'label'=>$val['label'], 'checked'=>(($visible < 0) ? 0 : 1), - 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1)), + 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1, 1, '1')), 'position'=>$val['position'], 'help'=> isset($val['help']) ? $val['help'] : '' ); diff --git a/htdocs/hrm/skill_note.php b/htdocs/hrm/skill_note.php index 1510f746e5e..45a0690f176 100644 --- a/htdocs/hrm/skill_note.php +++ b/htdocs/hrm/skill_note.php @@ -100,7 +100,7 @@ if ($id > 0 || !empty($ref)) { // Object card // ------------------------------------------------------------ - $linkback = ''.$langs->trans("BackToList").''; + $linkback = ''.$langs->trans("BackToList").''; $morehtmlref = '
    '; $morehtmlref.= $object->label; diff --git a/htdocs/hrm/skill_tab.php b/htdocs/hrm/skill_tab.php index 9a9ea39e31d..1ed9e370839 100644 --- a/htdocs/hrm/skill_tab.php +++ b/htdocs/hrm/skill_tab.php @@ -93,14 +93,14 @@ if ($reshook < 0) { if (empty($reshook)) { $error = 0; - $backurlforlist = dol_buildpath('/hrm/skill_list.php', 1); + $backurlforlist = DOL_URL_ROOT.'/hrm/skill_list.php'; if (empty($backtopage) || ($cancel && empty($id))) { if (empty($backtopage) || ($cancel && strpos($backtopage, '__ID__'))) { if (empty($id) && (($action != 'add' && $action != 'create') || $cancel)) { $backtopage = $backurlforlist; } else { - $backtopage = dol_buildpath('/hrm/skill_list.php', 1) . '?id=' . ($id > 0 ? $id : '__ID__'); + $backtopage = DOL_URL_ROOT.'/hrm/skill_list.php?id=' . ($id > 0 ? $id : '__ID__'); } } } @@ -130,7 +130,7 @@ if (empty($reshook)) { $TSkills = $skill->fetchAll('ASC', 't.rowid', 0, 0, array('customsql' => 'fk_object=' . ((int) $id) . " AND objecttype='" . $db->escape($objecttype) . "' AND fk_skill = " . ((int) $skillId))); if (is_array($TSkills) && !empty($TSkills)) { foreach ($TSkills as $tmpObj) { - $tmpObj->rank = $rank; + $tmpObj->rankorder = $rank; $tmpObj->update($user); } } @@ -305,7 +305,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea print '
    '; print $sk->description; print ''; - print displayRankInfos($skillElement->rank, $skillElement->fk_skill, 'TNote', $objecttype == 'job' && $permissiontoadd ? 'edit' : 'view'); + print displayRankInfos($skillElement->rankorder, $skillElement->fk_skill, 'TNote', $objecttype == 'job' && $permissiontoadd ? 'edit' : 'view'); print '
    '; // Module - print ''; + print ''; print ''; print ''; @@ -571,10 +572,10 @@ if ($step == 3 && $datatoimport) { print '
    '; print '
    '; - print '
    '.$langs->trans("Module").'
    '.$langs->trans("Module").''; $titleofmodule = $objimport->array_import_module[0]['module']->getName(); // Special cas for import common to module/services @@ -519,7 +520,7 @@ if ($step == 2 && $datatoimport) { $text = $objmodelimport->getDriverDescForKey($key); print ''.$form->textwithpicto($objmodelimport->getDriverLabelForKey($key), $text).''; - print img_picto('', 'download', 'class="paddingright opacitymedium"').''.$langs->trans("DownloadEmptyExample"); + print img_picto('', 'download', 'class="paddingright opacitymedium"').''.$langs->trans("DownloadEmptyExample"); print ''; print ' ('.$langs->trans("StarAreMandatory").')'; print '
    '; + print '
    '; // Module - print ''; + print ''; print ''; print ''; print ''; - if ($conf->productbatch->enabled) { + if (!empty($conf->productbatch->enabled)) { print ''; } print ''; - print ''; - if ($object->status == $object::STATUS_VALIDATED) { - // Actions + if ($object->status == $object::STATUS_DRAFT || $object->status == $object::STATUS_VALIDATED) { + // Actions or link to stock movement print ''; - print ''; + } else { + // Actions or link to stock movement + print ''; } + print ''; // Line to add a new line in inventory - if ($object->status == $object::STATUS_VALIDATED) { + if ($object->status == $object::STATUS_DRAFT || $object->status == $object::STATUS_VALIDATED) { print ''; print ''; - if ($conf->productbatch->enabled) { + if (!empty($conf->productbatch->enabled)) { print ''; } print ''; - print ''; // Actions @@ -704,7 +902,7 @@ if ($object->id > 0) { // Request to show lines of inventory (prefilled after start/validate step) $sql = 'SELECT id.rowid, id.datec as date_creation, id.tms as date_modification, id.fk_inventory, id.fk_warehouse,'; - $sql .= ' id.fk_product, id.batch, id.qty_stock, id.qty_view, id.qty_regulated'; + $sql .= ' id.fk_product, id.batch, id.qty_stock, id.qty_view, id.qty_regulated, id.fk_movement'; $sql .= ' FROM '.MAIN_DB_PREFIX.'inventorydet as id'; $sql .= ' WHERE id.fk_inventory = '.((int) $object->id); @@ -731,15 +929,17 @@ if ($object->id > 0) { $cacheOfWarehouses[$warehouse_static->id] = $warehouse_static; } + // Load real stock we have now + $option = ''; if (isset($cacheOfProducts[$obj->fk_product])) { $product_static = $cacheOfProducts[$obj->fk_product]; } else { $product_static = new Product($db); $result = $product_static->fetch($obj->fk_product, '', '', '', 1, 1, 1); - $option = 'nobatch'; + //$option = 'nobatch'; $option .= ',novirtual'; - $product_static->load_stock($option); // Load stock_reel + stock_warehouse. This can also call load_virtual_stock() + $product_static->load_stock($option); // Load stock_reel + stock_warehouse. $cacheOfProducts[$product_static->id] = $product_static; } @@ -752,35 +952,59 @@ if ($object->id > 0) { print $product_static->getNomUrl(1).' - '.$product_static->label; print ''; - if ($conf->productbatch->enabled) { + if (!empty($conf->productbatch->enabled)) { print ''; } - // Expected quantity - print ''; // Real quantity - print ''; + + // Picto delete line print ''; $qty_tmp = price2num(GETPOST("id_".$obj->rowid."_input_tmp", 'MS')) >= 0 ? GETPOST("id_".$obj->rowid."_input_tmp") : $qty_view; print ''; + print ''; } else { - print $obj->qty_view; + print ''; + print ''; } print ''; @@ -801,10 +1025,13 @@ if ($object->id > 0) { print ''; + // Call method to disable the button if no qty entered yet for inventory + if ($object->status != $object::STATUS_VALIDATED || !$hasinput) { - print ''; diff --git a/htdocs/product/inventory/list.php b/htdocs/product/inventory/list.php index 41e43fdf433..c4548b3aa66 100644 --- a/htdocs/product/inventory/list.php +++ b/htdocs/product/inventory/list.php @@ -102,11 +102,11 @@ $arrayfields = array(); foreach ($object->fields as $key => $val) { // If $val['visible']==0, then we never show the field if (!empty($val['visible'])) { - $visible = (int) dol_eval($val['visible'], 1); + $visible = (int) dol_eval($val['visible'], 1, 1, '1'); $arrayfields['t.'.$key] = array( 'label'=>$val['label'], 'checked'=>(($visible < 0) ? 0 : 1), - 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1)), + 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1, 1, '1')), 'position'=>$val['position'], 'help'=> isset($val['help']) ? $val['help'] : '' ); diff --git a/htdocs/product/list.php b/htdocs/product/list.php index 14d9b320e8e..a3c6f0c582b 100644 --- a/htdocs/product/list.php +++ b/htdocs/product/list.php @@ -65,7 +65,12 @@ $search_barcode = GETPOST("search_barcode", 'alpha'); $search_label = GETPOST("search_label", 'alpha'); $search_type = GETPOST("search_type", 'int'); $search_vatrate = GETPOST("search_vatrate", 'alpha'); -$searchCategoryProductOperator = (GETPOST('search_category_product_operator', 'int') ? GETPOST('search_category_product_operator', 'int') : 0); +$searchCategoryProductOperator = 0; +if (GETPOSTISSET('formfilteraction')) { + $searchCategoryProductOperator = GETPOST('search_category_product_operator', 'int'); +} elseif (!empty($conf->global->MAIN_SEARCH_CAT_OR_BY_DEFAULT)) { + $searchCategoryProductOperator = $conf->global->MAIN_SEARCH_CAT_OR_BY_DEFAULT; +} $searchCategoryProductList = GETPOST('search_category_product_list', 'array'); $search_tosell = GETPOST("search_tosell", 'int'); $search_tobuy = GETPOST("search_tobuy", 'int'); @@ -94,8 +99,8 @@ if (!empty($conf->variants->enabled) && !empty($conf->global->PRODUIT_ATTRIBUTES $diroutputmassaction = $conf->product->dir_output.'/temp/massgeneration/'.$user->id; $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page < 0 || GETPOST('button_search', 'alpha') || GETPOST('button_removefilter', 'alpha')) { $page = 0; @@ -199,6 +204,7 @@ $arrayfields = array( 'p.rowid'=>array('type'=>'integer', 'label'=>'TechnicalID', 'enabled'=>1, 'visible'=>-2, 'noteditable'=>1, 'notnull'=> 1, 'index'=>1, 'position'=>1, 'comment'=>'Id', 'css'=>'left'), 'p.ref'=>array('label'=>"Ref", 'checked'=>1, 'position'=>10), //'pfp.ref_fourn'=>array('label'=>$langs->trans("RefSupplier"), 'checked'=>1, 'enabled'=>(! empty($conf->barcode->enabled))), + 'thumbnail'=>array('label'=>'Photo', 'checked'=>0, 'position'=>10), 'p.label'=>array('label'=>"Label", 'checked'=>1, 'position'=>10), 'p.fk_product_type'=>array('label'=>"Type", 'checked'=>0, 'enabled'=>(!empty($conf->product->enabled) && !empty($conf->service->enabled)), 'position'=>11), 'p.barcode'=>array('label'=>"Gencod", 'checked'=>1, 'enabled'=>(!empty($conf->barcode->enabled)), 'position'=>12), @@ -244,11 +250,11 @@ $arrayfields = array( /*foreach ($object->fields as $key => $val) { // If $val['visible']==0, then we never show the field if (!empty($val['visible'])) { - $visible = dol_eval($val['visible'], 1); + $visible = dol_eval($val['visible'], 1, 1, '1'); $arrayfields['p.'.$key] = array( 'label'=>$val['label'], 'checked'=>(($visible < 0) ? 0 : 1), - 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1)), + 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1, 1, '1')), 'position'=>$val['position'] ); } @@ -355,6 +361,25 @@ if (empty($reshook)) { $permissiontoadd = $user->rights->{$rightskey}->creer; $uploaddir = $conf->product->dir_output; include DOL_DOCUMENT_ROOT.'/core/actions_massactions.inc.php'; + + if (!$error && $massaction == 'switchonsalestatus' && $permissiontoadd) { + $product = new Product($db); + foreach ($toselect as $toselectid) { + $result = $product->fetch($toselectid); + if ($result > 0 && $product->id > 0) { + $product->setStatut($product->status ? 0 : 1, null, 'product', 'PRODUCT_MODIFY', 'tosell'); + } + } + } + if (!$error && $massaction == 'switchonpurchasestatus' && $permissiontoadd) { + $product = new Product($db); + foreach ($toselect as $toselectid) { + $result = $product->fetch($toselectid); + if ($result > 0 && $product->id > 0) { + $product->setStatut($product->status_buy ? 0 : 1, null, 'product', 'PRODUCT_MODIFY', 'tobuy'); + } + } + } } @@ -710,6 +735,8 @@ if ($resql) { $arrayofmassactions['predelete'] = img_picto('', 'delete', 'class="pictofixedwidth"').$langs->trans("Delete"); } if ($user->rights->{$rightskey}->creer) { + $arrayofmassactions['switchonsalestatus'] = img_picto('', 'stop-circle', 'class="pictofixedwidth"').$langs->trans("SwitchOnSaleStatus"); + $arrayofmassactions['switchonpurchasestatus'] = img_picto('', 'stop-circle', 'class="pictofixedwidth"').$langs->trans("SwitchOnPurchaseStatus"); $arrayofmassactions['preaffecttag'] = img_picto('', 'category', 'class="pictofixedwidth"').$langs->trans("AffectTag"); } if (in_array($massaction, array('presend', 'predelete','preaffecttag'))) { @@ -846,6 +873,11 @@ if ($resql) { print ''; print ''; } + // Thumbnail + if (!empty($arrayfields['thumbnail']['checked'])) { + print ''; + } if (!empty($arrayfields['p.label']['checked'])) { print ''; + if (!$i) { + $totalarray['nbfield']++; + } + } + // Label if (!empty($arrayfields['p.label']['checked'])) { print ''; diff --git a/htdocs/product/popuprop.php b/htdocs/product/popuprop.php index 8ffae0bee8c..707f95d2202 100644 --- a/htdocs/product/popuprop.php +++ b/htdocs/product/popuprop.php @@ -30,7 +30,7 @@ require '../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php'; // Load translation files required by the page -$langs->loadLangs(array('commande', 'propal', 'bills', 'other')); +$langs->loadLangs(array('commande', 'propal', 'bills', 'other', 'products')); $backtopage = GETPOST('backtopage', 'alpha'); $backtopageforcancel = GETPOST('backtopageforcancel', 'alpha'); @@ -44,8 +44,8 @@ if (!empty($user->socid)) { } $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; @@ -178,7 +178,7 @@ $arrayofmode = array( 'facture' => 'Facture' ); $title .= ' '.$form->selectarray('mode', $arrayofmode, $mode, 1); -$title .= ' '; +$title .= ' '; print ''; @@ -198,7 +198,7 @@ print_barre_liste($title, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sort print '
    '.$langs->trans("Module").'
    '.$langs->trans("Module").''; $titleofmodule = $objimport->array_import_module[0]['module']->getName(); // Special cas for import common to module/services @@ -603,12 +604,12 @@ if ($step == 3 && $datatoimport) { print ''; // Source file format - print ''; + print ''; print ''; @@ -733,9 +734,9 @@ if ($step == 3 && $datatoimport) { $relativepath = $file; print ''; - print ''; print ''; @@ -773,7 +774,7 @@ if ($step == 4 && $datatoimport) { require_once $dir.$file; $obj = new $classname($db, $datatoimport); if ($model == 'csv') { - $obj->separator = $separator; + $obj->separator = $separator_used; $obj->enclosure = $enclosure; } if ($model == 'xlsx') { @@ -876,7 +877,7 @@ if ($step == 4 && $datatoimport) { print '
    '.$langs->trans("SourceFileFormat").'
    '.$langs->trans("SourceFileFormat").''; $text = $objmodelimport->getDriverDescForKey($format); print $form->textwithpicto($objmodelimport->getDriverLabelForKey($format), $text); print ''; - print img_picto('', 'download', 'class="paddingright opacitymedium"').''.$langs->trans("DownloadEmptyExample"); + print img_picto('', 'download', 'class="paddingright opacitymedium"').''.$langs->trans("DownloadEmptyExample"); print ''; print ' ('.$langs->trans("StarAreMandatory").')'; print '
    '.img_mime($file).''; - print ''; + print img_mime($file, '', 'pictofixedwidth'); + print ''; print $file; print ''; print '
    '; // Module - print ''; + print ''; print ''; // Warehouse print ''; + // Stock if ($conf->stock->enabled) { - print ''; } + // Lot if ($conf->productbatch->enabled) { - print ''; // Lot + print ''; } + // Action delete line if ($permissiontodelete) { - $href = $_SERVER["PHP_SELF"]; - $href .= '?id='.$object->id; - $href .= '&action=deleteline'; - $href .= '&lineid='.$line->id; + $href = $_SERVER["PHP_SELF"].'?id='.((int) $object->id).'&action=deleteline&token='.newToken().'&lineid='.((int) $line->id); print ''; } @@ -911,16 +929,26 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea // Show detailed of already consumed with js code to collapse foreach ($arrayoflines as $line2) { print ''; + + // Date print ''; + + // Already consumed print ''; + + // Qty print ''; + + // Cost price if ($permissiontoupdatecost && !empty($conf->global->MRP_SHOW_COST_FOR_CONSUMPTION)) { print ''; } + + // Warehouse print ''; + + // Stock + if ($conf->stock->enabled) { + print ''; + } + // Lot Batch print ''; + + // Action delete line + if ($permissiontodelete) { + print ''; + } + print ''; } if (in_array($action, array('consumeorproduce', 'consumeandproduceall'))) { $i = 1; print ''."\n"; - print ''; + print ''; print ''; $preselected = (GETPOSTISSET('qty-'.$line->id.'-'.$i) ? GETPOST('qty-'.$line->id.'-'.$i) : max(0, $line->qty - $alreadyconsumed)); if ($action == 'consumeorproduce' && !GETPOSTISSET('qty-'.$line->id.'-'.$i)) { @@ -954,24 +994,37 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea $disable = 'disabled'; } - print ''; + // Qty + print ''; + + // Cost if ($permissiontoupdatecost && !empty($conf->global->MRP_SHOW_COST_FOR_CONSUMPTION)) { print ''; } + + // Already consumed print ''; + + // Warehouse print ''; + + // Stock + if ($conf->stock->enabled) { + print ''; + } + + // Lot / Batch if ($conf->productbatch->enabled) { print ''; + print ''; } + + // Action delete line + if ($permissiontodelete) { + print ''; + } + print ''; } } @@ -1003,13 +1068,16 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea $nblinetoproduce++; } } - $newlinetext = ''; - if ($object->status != $object::STATUS_PRODUCED && $object->status != $object::STATUS_CANCELED && $action != 'consumeorproduce' && $action != 'consumeandproduceall') { - if ($nblinetoproduce == 0 || $object->mrptype == 1) { - $newlinetext = ''.$langs->trans("AddNewProduceLines").''; - } + + $newcardbutton = ''; + $url = $_SERVER["PHP_SELF"].'?id='.$object->id.'&action=addproduceline&token='.newToken(); + $permissiontoaddaproductline = $object->status != $object::STATUS_PRODUCED && $object->status != $object::STATUS_CANCELED && $action != 'consumeorproduce' && $action != 'consumeandproduceall'; + $parameters = array('morecss'=>'reposition'); + if ($nblinetoproduce == 0 || $object->mrptype == 1) { + $newcardbutton = dolGetButtonTitle($langs->trans('AddNewProduceLines'), '', 'fa fa-plus-circle size15x', $url, '', $permissiontoaddaproductline, $parameters); } - print load_fiche_titre($langs->trans('Production'), '', '', 0, '', '', $newlinetext); + + print load_fiche_titre($langs->trans('Production'), $newcardbutton, '', 0, '', ''); print '
    '; print '
    '.$langs->trans("Module").'
    '.$langs->trans("Module").''; $titleofmodule = $objimport->array_import_module[0]['module']->getName(); // Special cas for import common to module/services @@ -905,7 +906,7 @@ if ($step == 4 && $datatoimport) { print ''; // Source file format - print ''; + print ''; print ''; } @@ -937,7 +938,8 @@ if ($step == 4 && $datatoimport) { print ''; @@ -1177,7 +1179,7 @@ if ($step == 4 && $datatoimport) { if ($conf->use_javascript_ajax) { - print ''."\n"; } - /*if (! empty($conf->global->MAIN_FEATURES_LEVEL) && ! defined('JS_JQUERY_MIGRATE_DISABLED')) - { - if (defined('JS_JQUERY_MIGRATE') && constant('JS_JQUERY_MIGRATE')) print ''."\n"; - else print ''."\n"; - }*/ if (defined('JS_JQUERY_UI') && constant('JS_JQUERY_UI')) { print ''."\n"; } else { print ''."\n"; } - if (!defined('DISABLE_JQUERY_TABLEDND')) { - print ''."\n"; - } // jQuery jnotify if (empty($conf->global->MAIN_DISABLE_JQUERY_JNOTIFY) && !defined('DISABLE_JQUERY_JNOTIFY')) { print ''."\n"; } + // Table drag and drop lines + if (empty($disableforlogin) && !defined('DISABLE_JQUERY_TABLEDND')) { + print ''."\n"; + } // Chart - if ((empty($conf->global->MAIN_JS_GRAPH) || $conf->global->MAIN_JS_GRAPH == 'chart') && !defined('DISABLE_JS_GRAPH')) { + if (empty($disableforlogin) && (empty($conf->global->MAIN_JS_GRAPH) || $conf->global->MAIN_JS_GRAPH == 'chart') && !defined('DISABLE_JS_GRAPH')) { print ''."\n"; } @@ -1686,7 +1709,7 @@ function top_htmlhead($head, $title = '', $disablejs = 0, $disablehead = 0, $arr if (!$disablejs && !empty($conf->use_javascript_ajax)) { // CKEditor - if ((!empty($conf->fckeditor->enabled) && (empty($conf->global->FCKEDITOR_EDITORNAME) || $conf->global->FCKEDITOR_EDITORNAME == 'ckeditor') && !defined('DISABLE_CKEDITOR')) || defined('FORCE_CKEDITOR')) { + if (empty($disableforlogin) && (!empty($conf->fckeditor->enabled) && (empty($conf->global->FCKEDITOR_EDITORNAME) || $conf->global->FCKEDITOR_EDITORNAME == 'ckeditor') && !defined('DISABLE_CKEDITOR')) || defined('FORCE_CKEDITOR')) { print ''."\n"; $pathckeditor = DOL_URL_ROOT.'/includes/ckeditor/ckeditor/'; $jsckeditor = 'ckeditor.js'; @@ -1696,8 +1719,8 @@ function top_htmlhead($head, $title = '', $disablejs = 0, $disablehead = 0, $arr } print ''."\n"; @@ -1737,7 +1760,12 @@ function top_htmlhead($head, $title = '', $disablejs = 0, $disablehead = 0, $arr $filesjs = (array) $filesjs; // To be sure filejs is an array foreach ($filesjs as $jsfile) { // jsfile is a relative path - print ''."\n".''."\n"; + $urlforjs = dol_buildpath($jsfile, 1); + if ($urlforjs && $urlforjs != '/') { + print ''."\n".''."\n"; + } else { + dol_syslog("Warning: module ".$modjs." declared a js path file for a file we can't find.", LOG_WARNING); + } } } } @@ -1754,6 +1782,14 @@ function top_htmlhead($head, $title = '', $disablejs = 0, $disablehead = 0, $arr } } + //If you want to load custom javascript file from your selected theme directory + if (!empty($conf->global->ALLOW_THEME_JS)) { + $theme_js = dol_buildpath('/theme/'.$conf->theme.'/'.$conf->theme.'.js', 0); + if (file_exists($theme_js)) { + print ''."\n"; + } + } + if (!empty($head)) { print $head."\n"; } @@ -1842,8 +1878,8 @@ function top_menu($head, $title = '', $target = '', $disablejs = 0, $disablehead $appli .= " ".DOL_VERSION; } - if (!empty($conf->global->MAIN_FEATURES_LEVEL)) { - $appli .= "
    ".$langs->trans("LevelOfFeature").': '.$conf->global->MAIN_FEATURES_LEVEL; + if (getDolGlobalInt('MAIN_FEATURES_LEVEL')) { + $appli .= "
    ".$langs->trans("LevelOfFeature").': '.getDolGlobalInt('MAIN_FEATURES_LEVEL'); } $logouttext = ''; @@ -1853,7 +1889,7 @@ function top_menu($head, $title = '', $target = '', $disablejs = 0, $disablehead if ($_SESSION["dol_authmode"] != 'forceuser' && $_SESSION["dol_authmode"] != 'http') { $logouthtmltext .= $langs->trans("Logout").'
    '; - $logouttext .= ''; + $logouttext .= ''; $logouttext .= img_picto($langs->trans('Logout'), 'sign-out', '', false, 0, 0, '', 'atoplogin'); $logouttext .= ''; } else { @@ -1900,7 +1936,7 @@ function top_menu($head, $title = '', $target = '', $disablejs = 0, $disablehead } } $qs .= (($qs && $morequerystring) ? '&' : '').$morequerystring; - $text = ''; + $text = ''; //$text.= img_picto(":".$langs->trans("PrintContentArea"), 'printer_top.png', 'class="printer"'); $text .= ''; $text .= ''; @@ -1931,16 +1967,16 @@ function top_menu($head, $title = '', $target = '', $disablejs = 0, $disablehead // Link to help pages if ($helpbaseurl && $helppage) { $text = ''; - $title = $langs->trans($mode == 'wiki' ? 'GoToWikiHelpPage' : 'GoToHelpPage').'...'; + $title = $langs->trans($mode == 'wiki' ? 'GoToWikiHelpPage' : 'GoToHelpPage').', '; if ($mode == 'wiki') { - $title .= '
    '.$langs->trans("PageWiki").' '.dol_escape_htmltag('"'.strtr($helppage, '_', ' ').'"'); + $title .= '
    '.img_picto('', 'globe', 'class="pictofixedwidth"').$langs->trans("PageWiki").' '.dol_escape_htmltag('"'.strtr($helppage, '_', ' ').'"'); if ($helppresent) { $title .= ' ('.$langs->trans("DedicatedPageAvailable").')'; } else { $title .= ' ('.$langs->trans("HomePage").')'; } } - $text .= ''; $text .= ''; - $text .= ''; + $text .= ''; $text .= ''; $toprightmenu .= $form->textwithtooltip('', $title, 2, 1, $text, 'login_block_elem', 2); } @@ -2019,7 +2055,7 @@ function top_menu($head, $title = '', $target = '', $disablejs = 0, $disablehead * Build the tooltip on user login * * @param int $hideloginname Hide login name. Show only the image. - * @param string $urllogout URL for logout + * @param string $urllogout URL for logout (Will use DOL_URL_ROOT.'/user/logout.php?token=...' if empty) * @return string HTML content */ function top_menu_user($hideloginname = 0, $urllogout = '') @@ -2052,24 +2088,24 @@ function top_menu_user($hideloginname = 0, $urllogout = '') $dropdownBody .= '
    '; if ($langs->transcountry("ProfId1", $mysoc->country_code) != '-') { - $dropdownBody .= '
    '.$langs->transcountry("ProfId1", $mysoc->country_code).': '.showValueWithClipboardCPButton(getDolGlobalString("MAIN_INFO_SIREN")).''; + $dropdownBody .= '
    '.$langs->transcountry("ProfId1", $mysoc->country_code).': '.dol_print_profids(getDolGlobalString("MAIN_INFO_SIREN"), 1).''; } if ($langs->transcountry("ProfId2", $mysoc->country_code) != '-') { - $dropdownBody .= '
    '.$langs->transcountry("ProfId2", $mysoc->country_code).': '.showValueWithClipboardCPButton(getDolGlobalString("MAIN_INFO_SIRET")).''; + $dropdownBody .= '
    '.$langs->transcountry("ProfId2", $mysoc->country_code).': '.dol_print_profids(getDolGlobalString("MAIN_INFO_SIRET"), 2).''; } if ($langs->transcountry("ProfId3", $mysoc->country_code) != '-') { - $dropdownBody .= '
    '.$langs->transcountry("ProfId3", $mysoc->country_code).': '.showValueWithClipboardCPButton(getDolGlobalString("MAIN_INFO_APE")).''; + $dropdownBody .= '
    '.$langs->transcountry("ProfId3", $mysoc->country_code).': '.dol_print_profids(getDolGlobalString("MAIN_INFO_APE"), 3).''; } if ($langs->transcountry("ProfId4", $mysoc->country_code) != '-') { - $dropdownBody .= '
    '.$langs->transcountry("ProfId4", $mysoc->country_code).': '.showValueWithClipboardCPButton(getDolGlobalString("MAIN_INFO_RCS")).''; + $dropdownBody .= '
    '.$langs->transcountry("ProfId4", $mysoc->country_code).': '.dol_print_profids(getDolGlobalString("MAIN_INFO_RCS"), 4).''; } if ($langs->transcountry("ProfId5", $mysoc->country_code) != '-') { - $dropdownBody .= '
    '.$langs->transcountry("ProfId5", $mysoc->country_code).': '.showValueWithClipboardCPButton(getDolGlobalString("MAIN_INFO_PROFID5")).''; + $dropdownBody .= '
    '.$langs->transcountry("ProfId5", $mysoc->country_code).': '.dol_print_profids(getDolGlobalString("MAIN_INFO_PROFID5"), 5).''; } if ($langs->transcountry("ProfId6", $mysoc->country_code) != '-') { - $dropdownBody .= '
    '.$langs->transcountry("ProfId6", $mysoc->country_code).': '.showValueWithClipboardCPButton(getDolGlobalString("MAIN_INFO_PROFID6")).''; + $dropdownBody .= '
    '.$langs->transcountry("ProfId6", $mysoc->country_code).': '.dol_print_profids(getDolGlobalString("MAIN_INFO_PROFID6"), 6).''; } - $dropdownBody .= '
    '.$langs->trans("VATIntraShort").': '.showValueWithClipboardCPButton(getDolGlobalString("MAIN_INFO_TVAINTRA")).''; + $dropdownBody .= '
    '.$langs->trans("VATIntraShort").': '.dol_print_profids(getDolGlobalString("MAIN_INFO_TVAINTRA"), 'VAT').''; $dropdownBody .= '
    '; @@ -2135,7 +2171,7 @@ function top_menu_user($hideloginname = 0, $urllogout = '') } if (empty($urllogout)) { - $urllogout = DOL_URL_ROOT.'/user/logout.php'; + $urllogout = DOL_URL_ROOT.'/user/logout.php?token='.newToken(); } $logoutLink = ' '.$langs->trans("Logout").''; $profilLink = ' '.$langs->trans("Card").''; @@ -2823,7 +2859,7 @@ function left_menu($menu_array_before, $helppagename = '', $notused = '', $menu_ } print '
    '; if ($doliurl) { - print ''; + print ''; } else { print ''; } @@ -2891,7 +2927,7 @@ function left_menu($menu_array_before, $helppagename = '', $notused = '', $menu_ } print ''; } @@ -2928,7 +2964,7 @@ function left_menu($menu_array_before, $helppagename = '', $notused = '', $menu_ */ function main_area($title = '') { - global $conf, $langs; + global $conf, $langs, $hookmanager; if (empty($conf->dol_hide_leftmenu)) { print '
    '; @@ -2938,14 +2974,17 @@ function main_area($title = '') print ''."\n".'
    '."\n"; + $hookmanager->initHooks(array('main')); + $parameters = array(); + $reshook = $hookmanager->executeHooks('printMainArea', $parameters); // Note that $action and $object may have been modified by some hooks + print $hookmanager->resPrint; + if (!empty($conf->global->MAIN_ONLY_LOGIN_ALLOWED)) { print info_admin($langs->trans("WarningYouAreInMaintenanceMode", $conf->global->MAIN_ONLY_LOGIN_ALLOWED), 0, 0, 1, 'warning maintenancemode'); } // Permit to add user company information on each printed document by setting SHOW_SOCINFO_ON_PRINT if (!empty($conf->global->SHOW_SOCINFO_ON_PRINT) && GETPOST('optioncss', 'aZ09') == 'print' && empty(GETPOST('disable_show_socinfo_on_print', 'az09'))) { - global $hookmanager; - $hookmanager->initHooks(array('main')); $parameters = array(); $reshook = $hookmanager->executeHooks('showSocinfoOnPrint', $parameters); if (empty($reshook)) { @@ -3083,7 +3122,7 @@ if (!function_exists("llxFooter")) { { global $conf, $db, $langs, $user, $mysoc, $object, $hookmanager; global $delayedhtmlcontent; - global $contextpage, $page, $limit; + global $contextpage, $page, $limit, $mode; global $dolibarr_distrib; $ext = 'layout='.$conf->browser->layout.'&version='.urlencode(DOL_VERSION); @@ -3123,6 +3162,7 @@ if (!function_exists("llxFooter")) { unset($_SESSION['lastsearch_contextpage_tmp_'.$relativepathstring]); unset($_SESSION['lastsearch_page_tmp_'.$relativepathstring]); unset($_SESSION['lastsearch_limit_tmp_'.$relativepathstring]); + unset($_SESSION['lastsearch_mode_tmp_'.$relativepathstring]); if (!empty($contextpage)) { $_SESSION['lastsearch_contextpage_tmp_'.$relativepathstring] = $contextpage; @@ -3133,10 +3173,14 @@ if (!function_exists("llxFooter")) { if (!empty($limit) && $limit != $conf->liste_limit) { $_SESSION['lastsearch_limit_tmp_'.$relativepathstring] = $limit; } + if (!empty($mode)) { + $_SESSION['lastsearch_mode_tmp_'.$relativepathstring] = $mode; + } unset($_SESSION['lastsearch_contextpage_'.$relativepathstring]); unset($_SESSION['lastsearch_page_'.$relativepathstring]); unset($_SESSION['lastsearch_limit_'.$relativepathstring]); + unset($_SESSION['lastsearch_mode_'.$relativepathstring]); } // Core error message @@ -3195,6 +3239,7 @@ if (!function_exists("llxFooter")) { id:id; ?> , element:'element ?>' , action:'DOC_PREVIEW' + , token: '' } ); }); @@ -3204,6 +3249,7 @@ if (!function_exists("llxFooter")) { id:id; ?> , element:'element ?>' , action:'DOC_DOWNLOAD' + , token: '' } ); }); @@ -3214,7 +3260,7 @@ if (!function_exists("llxFooter")) { } // A div for the address popup - print "\n\n"; + print "\n\n"; print ''."\n"; // Add code for the asynchronous anonymous first ping (for telemetry) @@ -3222,7 +3268,7 @@ if (!function_exists("llxFooter")) { $forceping = GETPOST('forceping', 'alpha'); if (($_SERVER["PHP_SELF"] == DOL_URL_ROOT.'/index.php') || $forceping) { //print ''; - $hash_unique_id = md5('dolibarr'.$conf->file->instance_unique_id); + $hash_unique_id = md5('dolibarr'.$conf->file->instance_unique_id); // Do not use dol_hash(), must not change if salt changes. if (empty($conf->global->MAIN_FIRST_PING_OK_DATE) || (!empty($conf->file->instance_unique_id) && ($hash_unique_id != $conf->global->MAIN_FIRST_PING_OK_ID) && ($conf->global->MAIN_FIRST_PING_OK_ID != 'disabled')) diff --git a/htdocs/margin/admin/margin.php b/htdocs/margin/admin/margin.php index 30c85197337..94330eb8dc1 100644 --- a/htdocs/margin/admin/margin.php +++ b/htdocs/margin/admin/margin.php @@ -64,7 +64,7 @@ if (preg_match('/del_([a-z0-9_\-]+)/i', $action, $reg)) { } if ($action == 'remises') { - if (dolibarr_set_const($db, 'MARGIN_METHODE_FOR_DISCOUNT', $_POST['MARGIN_METHODE_FOR_DISCOUNT'], 'chaine', 0, '', $conf->entity) > 0) { + if (dolibarr_set_const($db, 'MARGIN_METHODE_FOR_DISCOUNT', GETPOST('MARGIN_METHODE_FOR_DISCOUNT'), 'chaine', 0, '', $conf->entity) > 0) { setEventMessages($langs->trans("RecordModifiedSuccessfully"), null, 'mesgs'); } else { dol_print_error($db); @@ -72,7 +72,7 @@ if ($action == 'remises') { } if ($action == 'typemarges') { - if (dolibarr_set_const($db, 'MARGIN_TYPE', $_POST['MARGIN_TYPE'], 'chaine', 0, '', $conf->entity) > 0) { + if (dolibarr_set_const($db, 'MARGIN_TYPE', GETPOST('MARGIN_TYPE'), 'chaine', 0, '', $conf->entity) > 0) { setEventMessages($langs->trans("RecordModifiedSuccessfully"), null, 'mesgs'); } else { dol_print_error($db); @@ -80,7 +80,7 @@ if ($action == 'typemarges') { } if ($action == 'contact') { - if (dolibarr_set_const($db, 'AGENT_CONTACT_TYPE', $_POST['AGENT_CONTACT_TYPE'], 'chaine', 0, '', $conf->entity) > 0) { + if (dolibarr_set_const($db, 'AGENT_CONTACT_TYPE', GETPOST('AGENT_CONTACT_TYPE'), 'chaine', 0, '', $conf->entity) > 0) { setEventMessages($langs->trans("RecordModifiedSuccessfully"), null, 'mesgs'); } else { dol_print_error($db); diff --git a/htdocs/margin/customerMargins.php b/htdocs/margin/customerMargins.php index 7fe151b93f7..290a94908c0 100644 --- a/htdocs/margin/customerMargins.php +++ b/htdocs/margin/customerMargins.php @@ -129,8 +129,8 @@ if ($socid > 0) { print ''; } -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); if (!$sortorder) { $sortorder = "ASC"; } diff --git a/htdocs/margin/tabs/productMargins.php b/htdocs/margin/tabs/productMargins.php index 062462be267..93895b01e2f 100644 --- a/htdocs/margin/tabs/productMargins.php +++ b/htdocs/margin/tabs/productMargins.php @@ -43,8 +43,8 @@ if (!empty($user->socid)) { $object = new Product($db); $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/margin/tabs/thirdpartyMargins.php b/htdocs/margin/tabs/thirdpartyMargins.php index 43e9c87c6e6..c69c0443e28 100644 --- a/htdocs/margin/tabs/thirdpartyMargins.php +++ b/htdocs/margin/tabs/thirdpartyMargins.php @@ -35,8 +35,8 @@ if (!empty($user->socid)) { } $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/master.inc.php b/htdocs/master.inc.php index e04adb4ee86..aa836842e71 100644 --- a/htdocs/master.inc.php +++ b/htdocs/master.inc.php @@ -32,7 +32,8 @@ * This script reads the conf file, init $lang, $db and and empty $user */ -// Declaration of variables. May have been already require by main.inc.php. But may not by scripts. So, here the require_once must be kept. +// Include the conf.php and functions.lib.php and security.lib.php. This defined the constants like DOL_DOCUMENT_ROOT, DOL_DATA_ROOT, DOL_URL_ROOT... +// This file may have been already required by main.inc.php. But may not by scripts. So, here the require_once must be kept. require_once 'filefunc.inc.php'; @@ -161,9 +162,10 @@ if (!defined('NOREQUIREDB')) { } // Now database connexion is known, so we can forget password -//unset($dolibarr_main_db_pass); // We comment this because this constant is used in a lot of pages +//unset($dolibarr_main_db_pass); // We comment this because this constant is used in some other pages unset($conf->db->pass); // This is to avoid password to be shown in memory/swap dump + /* * Object $user */ @@ -171,9 +173,9 @@ if (!defined('NOREQUIREUSER')) { $user = new User($db); } + /* * Load object $conf - * After this, all parameters conf->global->CONSTANTS are loaded */ // By default conf->entity is 1, but we change this if we ask another value. @@ -190,15 +192,12 @@ if (session_id() && !empty($_SESSION["dol_entity"])) { // For public page with MultiCompany module $conf->entity = constant('DOLENTITY'); } - // Sanitize entity if (!is_numeric($conf->entity)) { $conf->entity = 1; } - -//print "We work with data into entity instance number '".$conf->entity."'"; - // Here we read database (llx_const table) and define $conf->global->XXX var. +//print "We work with data into entity instance number '".$conf->entity."'"; $conf->setValues($db); // Create object $mysoc (A thirdparty object that contains properties of companies managed by Dolibarr. diff --git a/htdocs/modulebuilder/index.php b/htdocs/modulebuilder/index.php index cab90270d64..60f23cbee1a 100644 --- a/htdocs/modulebuilder/index.php +++ b/htdocs/modulebuilder/index.php @@ -46,6 +46,9 @@ $action = GETPOST('action', 'aZ09'); $confirm = GETPOST('confirm', 'alpha'); $cancel = GETPOST('cancel', 'alpha'); +$sortfield=GETPOST('sortfield', 'alpha'); +$sortorder=GETPOST('sortorder', 'alpha'); + $module = GETPOST('module', 'alpha'); $tab = GETPOST('tab', 'aZ09'); $tabobj = GETPOST('tabobj', 'alpha'); @@ -262,6 +265,7 @@ if ($dirins && $action == 'initmodule' && $modulename) { // Delete some files related to Object (because the previous dolCopyDir has copied everything) dol_delete_file($destdir.'/myobject_card.php'); + dol_delete_file($destdir.'/myobject_contact.php'); dol_delete_file($destdir.'/myobject_note.php'); dol_delete_file($destdir.'/myobject_document.php'); dol_delete_file($destdir.'/myobject_agenda.php'); @@ -337,6 +341,14 @@ if ($dirins && $action == 'initmodule' && $modulename) { setEventMessages('ModuleInitialized', null); $module = $modulename; $modulename = ''; + + clearstatcache(true); + if (function_exists('opcache_invalidate')) { + opcache_reset(); // remove the include cache hell ! + } + + header("Location: ".$_SERVER["PHP_SELF"].'?module='.$modulename); + exit; } } @@ -733,9 +745,9 @@ if ($dirins && $action == 'addlanguage' && !empty($module)) { // Dir for module $diroflang = dol_buildpath($modulelowercase, 0); - if ($diroflang == $dirread.'/'.$modulelowercase) { + if ($diroflang == $dolibarr_main_document_root.'/'.$modulelowercase) { // This is not a custom module, we force diroflang to htdocs root - $diroflang = $dirread; + $diroflang = $dolibarr_main_document_root; $srcfile = $diroflang.'/langs/en_US/'.$modulelowercase.'.lang'; $destfile = $diroflang.'/langs/'.$newlangcode.'/'.$modulelowercase.'.lang'; @@ -758,7 +770,7 @@ if ($dirins && $action == 'addlanguage' && !empty($module)) { // remove/delete File if ($dirins && $action == 'confirm_removefile' && !empty($module)) { - $relativefilename = dol_sanitizePathName(GETPOST('file', 'none')); + $relativefilename = dol_sanitizePathName(GETPOST('file', 'restricthtml')); if ($relativefilename) { $dirnametodelete = dirname($relativefilename); $filetodelete = $dirins.'/'.$relativefilename; @@ -953,7 +965,7 @@ if ($dirins && $action == 'initobject' && $module && GETPOST('createtablearray', if ($notnull) { $string .= ", 'notnull'=>".$notnull; } - if ($fieldname == 'ref') { + if ($fieldname == 'ref' || $fieldname == 'code') { $string .= ", 'showoncombobox'=>1"; } $string .= ", 'position'=>".$position; @@ -1417,6 +1429,14 @@ if ($dirins && $action == 'confirm_deletemodule') { if ($result > 0) { setEventMessages($langs->trans("DirWasRemoved", $modulelowercase), null); + + clearstatcache(true); + if (function_exists('opcache_invalidate')) { + opcache_reset(); // remove the include cache hell ! + } + + header("Location: ".$_SERVER["PHP_SELF"].'?module=deletemodule'); + exit; } else { setEventMessages($langs->trans("PurgeNothingToDelete"), null, 'warnings'); } @@ -1707,8 +1727,8 @@ print load_fiche_titre($text, '', 'title_setup'); print ''.$langs->trans("ModuleBuilderDesc", 'https://wiki.dolibarr.org/index.php/Module_development#Create_your_module').'
    '; -print $textforlistofdirs; -print '
    '; +//print $textforlistofdirs; +//print '
    '; //var_dump($listofmodules); @@ -1733,7 +1753,7 @@ if ($message) { } //print $langs->trans("ModuleBuilderDesc3", count($listofmodules), $FILEFLAG).'
    '; -$infomodulesfound = '
    '.$form->textwithpicto(''.$langs->trans("ModuleBuilderDesc3", count($listofmodules)).'', $langs->trans("ModuleBuilderDesc4", $FILEFLAG)).'
    '; +$infomodulesfound = '
    '.$form->textwithpicto(''.$langs->trans("ModuleBuilderDesc3", count($listofmodules)).'', $langs->trans("ModuleBuilderDesc4", $FILEFLAG).'
    '.$textforlistofdirs).'
    '; // Load module descriptor @@ -1757,6 +1777,10 @@ if (!empty($module) && $module != 'initmodule' && $module != 'deletemodule') { $loadclasserrormessage = $e->getMessage()."
    \n"; $loadclasserrormessage .= 'File: '.$e->getFile()."
    \n"; $loadclasserrormessage .= 'Line: '.$e->getLine()."
    \n"; + } catch (Exception $e) { + $loadclasserrormessage = $e->getMessage()."
    \n"; + $loadclasserrormessage .= 'File: '.$e->getFile()."
    \n"; + $loadclasserrormessage .= 'Line: '.$e->getLine()."
    \n"; } if (class_exists($class)) { @@ -1771,6 +1795,7 @@ if (!empty($module) && $module != 'initmodule' && $module != 'deletemodule') { $error++; } $langs->load("errors"); + print ''; print img_warning('').' '.$langs->trans("ErrorFailedToLoadModuleDescriptorForXXX", $module).'
    '; print $loadclasserrormessage; } @@ -2045,8 +2070,8 @@ if ($module == 'initmodule') { print $langs->trans("Numero"); print '
    '; print '\n"; - if (is_array($dicts) && is_array($dicts['tabname'])) { + if (!empty($dicts) && is_array($dicts) && !empty($dicts['tabname']) && is_array($dicts['tabname'])) { $i = 0; $maxi = count($dicts['tabname']); while ($i < $maxi) { @@ -2423,8 +2448,8 @@ if ($module == 'initmodule') { print ''.$langs->trans("EnterNameOfObjectDesc").'

    '; print '
    '; - print ' '.$form->textwithpicto($langs->trans("IncludeRefGeneration"), $langs->trans("IncludeRefGenerationHelp")).'
    '; - print ' '.$form->textwithpicto($langs->trans("IncludeDocGeneration"), $langs->trans("IncludeDocGenerationHelp")).'
    '; + print '
    '; + print '
    '; print ''; print '
    '; print '
    '; @@ -2633,6 +2658,7 @@ if ($module == 'initmodule') { print '


    '; + clearstatcache(true); if (function_exists('opcache_invalidate')) { opcache_invalidate($dirread.'/'.$pathtoclass, true); // remove the include cache hell ! } @@ -2674,7 +2700,7 @@ if ($module == 'initmodule') { print '
    '.$langs->trans("SourceFileFormat").'
    '.$langs->trans("SourceFileFormat").''; $text = $objmodelimport->getDriverDescForKey($format); print $form->textwithpicto($objmodelimport->getDriverLabelForKey($format), $text); @@ -926,8 +927,8 @@ if ($step == 4 && $datatoimport) { print $langs->trans("Separator").' : '; print ''; print '    '.$langs->trans("Enclosure").' : '; - print ''; - print ''; + print ' '; + print ''; print ''; print '
    '; $modulepart = 'import'; $relativepath = GETPOST('filetoimport'); - print ''; + print ''; + print img_mime($file, '', 'pictofixedwidth'); print $filetoimport; print ''; print '
    '; print $moduleobj->numero; - print '   ('.$langs->trans("SeeIDsInUse").''; - print ' - '.$langs->trans("SeeReservedIDsRangeHere").')'; + print '   ('.$langs->trans("SeeIDsInUse").''; + print ' - '.$langs->trans("SeeReservedIDsRangeHere").')'; print '
    '; @@ -2274,7 +2299,7 @@ if ($module == 'initmodule') { print_liste_field_titre("Condition", $_SERVER["PHP_SELF"], '', "", $param, '', $sortfield, $sortorder); print "
    '; print ''; print ''; print ''; @@ -3332,7 +3358,8 @@ if ($module == 'initmodule') { } } else { print ''; print ''; print ''; @@ -3816,7 +3843,7 @@ if ($module == 'initmodule') { print ''.$langs->trans("FileNotYetGenerated").''; } else { print ''; - print ''; + print ''; print $outputfiledoc; print ''; print ''; @@ -3830,7 +3857,7 @@ if ($module == 'initmodule') { print ''.$langs->trans("FileNotYetGenerated").''; } else { print ''; - print ''; + print ''; print $outputfiledocpdf; print ''; print ''; diff --git a/htdocs/modulebuilder/template/README.md b/htdocs/modulebuilder/template/README.md index 45c5e4b51eb..03cf25d74f4 100644 --- a/htdocs/modulebuilder/template/README.md +++ b/htdocs/modulebuilder/template/README.md @@ -28,10 +28,10 @@ There is a [Transifex project](https://transifex.com/projects/p/dolibarr-module- ### From the ZIP file and GUI interface -- If you get the module in a zip file (like when downloading it from the market place [Dolistore](https://www.dolistore.com)), go into -menu ```Home - Setup - Modules - Deploy external module``` and upload the zip file. +If the module is a ready to deploy zip file, so with a name module_xxx-version.zip (like when downloading it from a market place like [Dolistore](https://www.dolistore.com)), +go into menu ```Home - Setup - Modules - Deploy external module``` and upload the zip file. -Note: If this screen tell you there is no custom directory, check your setup is correct: +Note: If this screen tell you that there is no "custom" directory, check that your setup is correct: - In your Dolibarr installation directory, edit the ```htdocs/conf/conf.php``` file and check that following lines are not commented: @@ -58,7 +58,7 @@ Note: If this screen tell you there is no custom directory, check your setup is ### From a GIT repository -- Clone the repository in ```$dolibarr_main_document_root_alt/mymodule``` +Clone the repository in ```$dolibarr_main_document_root_alt/mymodule``` ```sh cd ....../custom diff --git a/htdocs/modulebuilder/template/admin/setup.php b/htdocs/modulebuilder/template/admin/setup.php index 7c6c6b2c04e..eeca8b77358 100644 --- a/htdocs/modulebuilder/template/admin/setup.php +++ b/htdocs/modulebuilder/template/admin/setup.php @@ -60,6 +60,9 @@ require_once '../lib/mymodule.lib.php'; // Translations $langs->loadLangs(array("admin", "mymodule@mymodule")); +// Initialize technical object to manage hooks of page. Note that conf->hooks_modules contains array of hook context +$hookmanager->initHooks(array('mymodulesetup', 'globalsetup')); + // Access control if (!$user->admin) { accessforbidden(); @@ -68,6 +71,7 @@ if (!$user->admin) { // Parameters $action = GETPOST('action', 'aZ09'); $backtopage = GETPOST('backtopage', 'alpha'); +$modulepart = GETPOST('modulepart', 'aZ09'); // Used by actions_setmoduleoptions.inc.php $value = GETPOST('value', 'alpha'); $label = GETPOST('label', 'alpha'); @@ -88,6 +92,52 @@ $arrayofparameters = array( $error = 0; $setupnotempty = 0; +// Set this to 1 to use the factory to manage constants. Warning, the generated module will be compatible with version v15+ only +$useFormSetup = 0; +// Convert arrayofparameter into a formSetup object +if ($useFormSetup && (float) DOL_VERSION >= 15) { + require_once DOL_DOCUMENT_ROOT.'/core/class/html.formsetup.class.php'; + $formSetup = new FormSetup($db); + + // you can use the param convertor + $formSetup->addItemsFromParamsArray($arrayofparameters); + + // or use the new system see exemple as follow (or use both because you can ;-) ) + + /* + // Hôte + $item = $formSetup->newItem('NO_PARAM_JUST_TEXT'); + $item->fieldOverride = (empty($_SERVER['HTTPS']) ? 'http://' : 'https://') . $_SERVER['HTTP_HOST']; + $item->cssClass = 'minwidth500'; + + // Setup conf MYMODULE_MYPARAM1 as a simple string input + $item = $formSetup->newItem('MYMODULE_MYPARAM1'); + + // Setup conf MYMODULE_MYPARAM1 as a simple textarea input but we replace the text of field title + $item = $formSetup->newItem('MYMODULE_MYPARAM2'); + $item->nameText = $item->getNameText().' more html text '; + + // Setup conf MYMODULE_MYPARAM3 + $item = $formSetup->newItem('MYMODULE_MYPARAM3'); + $item->setAsThirdpartyType(); + + // Setup conf MYMODULE_MYPARAM4 : exemple of quick define write style + $formSetup->newItem('MYMODULE_MYPARAM4')->setAsYesNo(); + + // Setup conf MYMODULE_MYPARAM5 + $formSetup->newItem('MYMODULE_MYPARAM5')->setAsEmailTemplate('thirdparty'); + + // Setup conf MYMODULE_MYPARAM6 + $formSetup->newItem('MYMODULE_MYPARAM6')->setAsSecureKey()->enabled = 0; // disabled + + // Setup conf MYMODULE_MYPARAM7 + $formSetup->newItem('MYMODULE_MYPARAM7')->setAsProduct(); + */ + + $setupnotempty = count($formSetup->items); +} + + $dirmodels = array_merge(array('/'), (array) $conf->modules_parts['models']); @@ -95,16 +145,14 @@ $dirmodels = array_merge(array('/'), (array) $conf->modules_parts['models']); * Actions */ -if ((float) DOL_VERSION >= 6) { - include DOL_DOCUMENT_ROOT.'/core/actions_setmoduleoptions.inc.php'; -} +include DOL_DOCUMENT_ROOT.'/core/actions_setmoduleoptions.inc.php'; if ($action == 'updateMask') { - $maskconstorder = GETPOST('maskconstorder', 'alpha'); - $maskorder = GETPOST('maskorder', 'alpha'); + $maskconst = GETPOST('maskconst', 'alpha'); + $maskvalue = GETPOST('maskvalue', 'alpha'); - if ($maskconstorder) { - $res = dolibarr_set_const($db, $maskconstorder, $maskorder, 'chaine', 0, '', $conf->entity); + if ($maskconst) { + $res = dolibarr_set_const($db, $maskconst, $maskvalue, 'chaine', 0, '', $conf->entity); if (!($res > 0)) { $error++; } @@ -223,71 +271,74 @@ echo ''.$langs->trans("MyModuleSetupPage").'< if ($action == 'edit') { - print ''; - print ''; - print ''; + if ($useFormSetup && (float) DOL_VERSION >= 15) { + print $formSetup->generateOutput(true); + } else { + print ''; + print ''; + print ''; - print '
    '.$langs->trans("Property"); - print ' ('.$langs->trans("SeeExamples").')'; + print ' ('.$langs->trans("SeeExamples").')'; print ''; print $form->textwithpicto($langs->trans("Label"), $langs->trans("YouCanUseTranslationKey")); @@ -2755,25 +2781,25 @@ if ($module == 'initmodule') { $propname = $propkey; $proplabel = $propval['label']; $proptype = $propval['type']; - $proparrayofkeyval = $propval['arrayofkeyval']; + $proparrayofkeyval = !empty($propval['arrayofkeyval'])?$propval['arrayofkeyval']:''; $propnotnull = $propval['notnull']; - $propdefault = $propval['default']; - $propindex = $propval['index']; - $propforeignkey = $propval['foreignkey']; + $propdefault = !empty($propval['default'])?$propval['default']:''; + $propindex = !empty($propval['index'])?$propval['index']:''; + $propforeignkey = !empty($propval['foreignkey'])?$propval['foreignkey']:''; $propposition = $propval['position']; $propenabled = $propval['enabled']; $propvisible = $propval['visible']; - $propnoteditable = $propval['noteditable']; - $propsearchall = $propval['searchall']; - $propisameasure = $propval['isameasure']; - $propcss = $propval['css']; - $propcssview = $propval['cssview']; - $propcsslist = $propval['csslist']; - $prophelp = $propval['help']; - $propshowoncombobox = $propval['showoncombobox']; + $propnoteditable = !empty($propval['noteditable'])?$propval['noteditable']:0; + $propsearchall = !empty($propval['searchall'])?$propval['searchall']:0; + $propisameasure = !empty($propval['isameasure'])?$propval['isameasure']:0; + $propcss = !empty($propval['css'])?$propval['css']:''; + $propcssview = !empty($propval['cssview'])?$propval['cssview']:''; + $propcsslist = !empty($propval['csslist'])?$propval['csslist']:''; + $prophelp = !empty($propval['help'])?$propval['help']:''; + $propshowoncombobox = !empty($propval['showoncombobox'])?$propval['showoncombobox']:0; //$propdisabled=$propval['disabled']; - $propvalidate = $propval['validate']; - $propcomment = $propval['comment']; + $propvalidate = !empty($propval['validate'])?$propval['validate']:0; + $propcomment = !empty($propval['comment'])?$propval['comment']:''; print '
    '; - print ' '.$langs->trans("NoTrigger"); + print ' '.$langs->trans("TriggersFile"); + print ' : '.$langs->trans("FileNotYetGenerated").''; print ''.img_picto('Generate', 'generate', 'class="paddingleft"').'
    '; - print ''; + print '
    '.$langs->trans("Parameter").''.$langs->trans("Value").'
    '; + print ''; - foreach ($arrayofparameters as $constname => $val) { - if ($val['enabled']==1) { - $setupnotempty++; - print ''; - } - } - print '
    '.$langs->trans("Parameter").''.$langs->trans("Value").'
    '; - $tooltiphelp = (($langs->trans($constname . 'Tooltip') != $constname . 'Tooltip') ? $langs->trans($constname . 'Tooltip') : ''); - print ''.$form->textwithpicto($langs->trans($constname), $tooltiphelp, 1, 'info', '', 0, 3, 'tootips'.$constname).''; - print ''; + foreach ($arrayofparameters as $constname => $val) { + if ($val['enabled']==1) { + $setupnotempty++; + print '
    '; + $tooltiphelp = (($langs->trans($constname . 'Tooltip') != $constname . 'Tooltip') ? $langs->trans($constname . 'Tooltip') : ''); + print ''.$form->textwithpicto($langs->trans($constname), $tooltiphelp, 1, 'info', '', 0, 3, 'tootips'.$constname).''; + print ''; - if ($val['type'] == 'textarea') { - print '\n"; - } elseif ($val['type']== 'html') { - require_once DOL_DOCUMENT_ROOT . '/core/class/doleditor.class.php'; - $doleditor = new DolEditor($constname, $conf->global->{$constname}, '', 160, 'dolibarr_notes', '', false, false, $conf->fckeditor->enabled, ROWS_5, '90%'); - $doleditor->Create(); - } elseif ($val['type'] == 'yesno') { - print $form->selectyesno($constname, $conf->global->{$constname}, 1); - } elseif (preg_match('/emailtemplate:/', $val['type'])) { - include_once DOL_DOCUMENT_ROOT . '/core/class/html.formmail.class.php'; - $formmail = new FormMail($db); + if ($val['type'] == 'textarea') { + print '\n"; + } elseif ($val['type']== 'html') { + require_once DOL_DOCUMENT_ROOT . '/core/class/doleditor.class.php'; + $doleditor = new DolEditor($constname, $conf->global->{$constname}, '', 160, 'dolibarr_notes', '', false, false, $conf->fckeditor->enabled, ROWS_5, '90%'); + $doleditor->Create(); + } elseif ($val['type'] == 'yesno') { + print $form->selectyesno($constname, $conf->global->{$constname}, 1); + } elseif (preg_match('/emailtemplate:/', $val['type'])) { + include_once DOL_DOCUMENT_ROOT . '/core/class/html.formmail.class.php'; + $formmail = new FormMail($db); - $tmp = explode(':', $val['type']); - $nboftemplates = $formmail->fetchAllEMailTemplate($tmp[1], $user, null, 1); // We set lang=null to get in priority record with no lang - //$arraydefaultmessage = $formmail->getEMailTemplate($db, $tmp[1], $user, null, 0, 1, ''); - $arrayofmessagename = array(); - if (is_array($formmail->lines_model)) { - foreach ($formmail->lines_model as $modelmail) { - //var_dump($modelmail); - $moreonlabel = ''; - if (!empty($arrayofmessagename[$modelmail->label])) { - $moreonlabel = ' (' . $langs->trans("SeveralLangugeVariatFound") . ')'; + $tmp = explode(':', $val['type']); + $nboftemplates = $formmail->fetchAllEMailTemplate($tmp[1], $user, null, 1); // We set lang=null to get in priority record with no lang + //$arraydefaultmessage = $formmail->getEMailTemplate($db, $tmp[1], $user, null, 0, 1, ''); + $arrayofmessagename = array(); + if (is_array($formmail->lines_model)) { + foreach ($formmail->lines_model as $modelmail) { + //var_dump($modelmail); + $moreonlabel = ''; + if (!empty($arrayofmessagename[$modelmail->label])) { + $moreonlabel = ' (' . $langs->trans("SeveralLangugeVariatFound") . ')'; + } + // The 'label' is the key that is unique if we exclude the language + $arrayofmessagename[$modelmail->id] = $langs->trans(preg_replace('/\(|\)/', '', $modelmail->label)) . $moreonlabel; } - // The 'label' is the key that is unique if we exclude the language - $arrayofmessagename[$modelmail->id] = $langs->trans(preg_replace('/\(|\)/', '', $modelmail->label)) . $moreonlabel; } - } - print $form->selectarray($constname, $arrayofmessagename, $conf->global->{$constname}, 'None', 0, 0, '', 0, 0, 0, '', '', 1); - } elseif (preg_match('/category:/', $val['type'])) { - require_once DOL_DOCUMENT_ROOT.'/categories/class/categorie.class.php'; - require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php'; - $formother = new FormOther($db); + print $form->selectarray($constname, $arrayofmessagename, $conf->global->{$constname}, 'None', 0, 0, '', 0, 0, 0, '', '', 1); + } elseif (preg_match('/category:/', $val['type'])) { + require_once DOL_DOCUMENT_ROOT.'/categories/class/categorie.class.php'; + require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php'; + $formother = new FormOther($db); - $tmp = explode(':', $val['type']); - print img_picto('', 'category', 'class="pictofixedwidth"'); - print $formother->select_categories($tmp[1], $conf->global->{$constname}, $constname, 0, $langs->trans('CustomersProspectsCategoriesShort')); - } elseif (preg_match('/thirdparty_type/', $val['type'])) { - require_once DOL_DOCUMENT_ROOT.'/core/class/html.formcompany.class.php'; - $formcompany = new FormCompany($db); - print $formcompany->selectProspectCustomerType($conf->global->{$constname}, $constname); - } elseif ($val['type'] == 'securekey') { - print ''; - if (!empty($conf->use_javascript_ajax)) { - print ' '.img_picto($langs->trans('Generate'), 'refresh', 'id="generate_token'.$constname.'" class="linkobject"'); - } - if (!empty($conf->use_javascript_ajax)) { - print "\n".''; - } - } elseif ($val['type'] == 'product') { - if (!empty($conf->product->enabled) || !empty($conf->service->enabled)) { - $selected = (empty($conf->global->$constname) ? '' : $conf->global->$constname); - $form->select_produits($selected, $constname, '', 0); - } - } else { - print ''; - } - print '
    '; - - print '
    '; - print ''; - print '
    '; - - print ''; - print '
    '; -} else { - if (!empty($arrayofparameters)) { - print ''; - print ''; - - foreach ($arrayofparameters as $constname => $val) { - if ($val['enabled']==1) { - $setupnotempty++; - print ''; } } - print '
    '.$langs->trans("Parameter").''.$langs->trans("Value").'
    '; - $tooltiphelp = (($langs->trans($constname . 'Tooltip') != $constname . 'Tooltip') ? $langs->trans($constname . 'Tooltip') : ''); - print $form->textwithpicto($langs->trans($constname), $tooltiphelp); - print ''; - - if ($val['type'] == 'textarea') { - print dol_nl2br($conf->global->{$constname}); - } elseif ($val['type']== 'html') { - print $conf->global->{$constname}; - } elseif ($val['type'] == 'yesno') { - print ajax_constantonoff($constname); - } elseif (preg_match('/emailtemplate:/', $val['type'])) { - include_once DOL_DOCUMENT_ROOT . '/core/class/html.formmail.class.php'; - $formmail = new FormMail($db); - - $tmp = explode(':', $val['type']); - - $template = $formmail->getEMailTemplate($db, $tmp[1], $user, $langs, $conf->global->{$constname}); - if ($template<0) { - setEventMessages(null, $formmail->errors, 'errors'); - } - print $langs->trans($template->label); - } elseif (preg_match('/category:/', $val['type'])) { - $c = new Categorie($db); - $result = $c->fetch($conf->global->{$constname}); - if ($result < 0) { - setEventMessages(null, $c->errors, 'errors'); - } - $ways = $c->print_all_ways(' >> ', 'none', 0, 1); // $ways[0] = "ccc2 >> ccc2a >> ccc2a1" with html formated text - $toprint = array(); - foreach ($ways as $way) { - $toprint[] = '
  • color ? ' style="background: #' . $c->color . ';"' : ' style="background: #bbb"') . '>' . $way . '
  • '; - } - print '
      ' . implode(' ', $toprint) . '
    '; - } elseif (preg_match('/thirdparty_type/', $val['type'])) { - if ($conf->global->{$constname}==2) { - print $langs->trans("Prospect"); - } elseif ($conf->global->{$constname}==3) { - print $langs->trans("ProspectCustomer"); - } elseif ($conf->global->{$constname}==1) { - print $langs->trans("Customer"); - } elseif ($conf->global->{$constname}==0) { - print $langs->trans("NorProspectNorCustomer"); + print ''; } } elseif ($val['type'] == 'product') { - $product = new Product($db); - $resprod = $product->fetch($conf->global->{$constname}); - if ($resprod > 0) { - print $product->ref; - } elseif ($resprod < 0) { - setEventMessages(null, $object->errors, "errors"); + if (!empty($conf->product->enabled) || !empty($conf->service->enabled)) { + $selected = (empty($conf->global->$constname) ? '' : $conf->global->$constname); + $form->select_produits($selected, $constname, '', 0); } } else { - print $conf->global->{$constname}; + print ''; } print '
    '; + print '
    '; + print ''; + print '
    '; + + print ''; + } + + print '
    '; +} else { + if ($useFormSetup && (float) DOL_VERSION >= 15) { + if (!empty($formSetup->items)) { + print $formSetup->generateOutput(); + } + } else { + if (!empty($arrayofparameters)) { + print ''; + print ''; + + foreach ($arrayofparameters as $constname => $val) { + if ($val['enabled']==1) { + $setupnotempty++; + print ''; + } + } + + print '
    '.$langs->trans("Parameter").''.$langs->trans("Value").'
    '; + $tooltiphelp = (($langs->trans($constname . 'Tooltip') != $constname . 'Tooltip') ? $langs->trans($constname . 'Tooltip') : ''); + print $form->textwithpicto($langs->trans($constname), $tooltiphelp); + print ''; + + if ($val['type'] == 'textarea') { + print dol_nl2br($conf->global->{$constname}); + } elseif ($val['type']== 'html') { + print $conf->global->{$constname}; + } elseif ($val['type'] == 'yesno') { + print ajax_constantonoff($constname); + } elseif (preg_match('/emailtemplate:/', $val['type'])) { + include_once DOL_DOCUMENT_ROOT . '/core/class/html.formmail.class.php'; + $formmail = new FormMail($db); + + $tmp = explode(':', $val['type']); + + $template = $formmail->getEMailTemplate($db, $tmp[1], $user, $langs, $conf->global->{$constname}); + if ($template<0) { + setEventMessages(null, $formmail->errors, 'errors'); + } + print $langs->trans($template->label); + } elseif (preg_match('/category:/', $val['type'])) { + $c = new Categorie($db); + $result = $c->fetch($conf->global->{$constname}); + if ($result < 0) { + setEventMessages(null, $c->errors, 'errors'); + } elseif ($result > 0 ) { + $ways = $c->print_all_ways(' >> ', 'none', 0, 1); // $ways[0] = "ccc2 >> ccc2a >> ccc2a1" with html formated text + $toprint = array(); + foreach ($ways as $way) { + $toprint[] = '
  • color ? ' style="background: #' . $c->color . ';"' : ' style="background: #bbb"') . '>' . $way . '
  • '; + } + print '
      ' . implode(' ', $toprint) . '
    '; + } + } elseif (preg_match('/thirdparty_type/', $val['type'])) { + if ($conf->global->{$constname}==2) { + print $langs->trans("Prospect"); + } elseif ($conf->global->{$constname}==3) { + print $langs->trans("ProspectCustomer"); + } elseif ($conf->global->{$constname}==1) { + print $langs->trans("Customer"); + } elseif ($conf->global->{$constname}==0) { + print $langs->trans("NorProspectNorCustomer"); + } + } elseif ($val['type'] == 'product') { + $product = new Product($db); + $resprod = $product->fetch($conf->global->{$constname}); + if ($resprod > 0) { + print $product->ref; + } elseif ($resprod < 0) { + setEventMessages(null, $object->errors, "errors"); + } + } else { + print $conf->global->{$constname}; + } + print '
    '; + } + } + + if ($setupnotempty) { print '
    '; print ''.$langs->trans("Modify").''; print '
    '; diff --git a/htdocs/modulebuilder/template/class/api_mymodule.class.php b/htdocs/modulebuilder/template/class/api_mymodule.class.php index cb2fbda68a6..4cb50c8de2f 100644 --- a/htdocs/modulebuilder/template/class/api_mymodule.class.php +++ b/htdocs/modulebuilder/template/class/api_mymodule.class.php @@ -155,8 +155,9 @@ class MyModuleApi extends DolibarrApi $sql .= " AND sc.fk_user = ".((int) $search_sale); } if ($sqlfilters) { - if (!DolibarrApi::_checkFilters($sqlfilters)) { - throw new RestException(503, 'Error when validating parameter sqlfilters '.$sqlfilters); + $errormessage = ''; + if (!DolibarrApi::_checkFilters($sqlfilters, $errormessage)) { + throw new RestException(503, 'Error when validating parameter sqlfilters -> '.$errormessage); } $regexstring = '\(([^:\'\(\)]+:[^:\'\(\)]+:[^\(\)]+)\)'; $sql .= " AND (".preg_replace_callback('/'.$regexstring.'/', 'DolibarrApi::_forge_criteria_callback', $sqlfilters).")"; diff --git a/htdocs/modulebuilder/template/class/myobject.class.php b/htdocs/modulebuilder/template/class/myobject.class.php index 8e316d014d5..ac934439934 100644 --- a/htdocs/modulebuilder/template/class/myobject.class.php +++ b/htdocs/modulebuilder/template/class/myobject.class.php @@ -362,7 +362,7 @@ class MyObject extends CommonObject if (!$error) { // copy external contacts if same company - if (property_exists($this, 'fk_soc') && $this->fk_soc == $object->socid) { + if (!empty($object->socid) && property_exists($this, 'fk_soc') && $this->fk_soc == $object->socid) { if ($this->copy_linked_contact($object, 'external') < 0) { $error++; } @@ -767,7 +767,7 @@ class MyObject extends CommonObject if ($save_lastsearch_value == -1 && preg_match('/list\.php/', $_SERVER["PHP_SELF"])) { $add_save_lastsearch_values = 1; } - if ($add_save_lastsearch_values) { + if ($url && $add_save_lastsearch_values) { $url .= '&save_lastsearch_values=1'; } } @@ -784,13 +784,13 @@ class MyObject extends CommonObject $linkclose = ($morecss ? ' class="'.$morecss.'"' : ''); } - if ($option == 'nolink') { + if ($option == 'nolink' || empty($url)) { $linkstart = ''; - if ($option == 'nolink') { + if ($option == 'nolink' || empty($url)) { $linkend = ''; } else { $linkend = ''; @@ -836,7 +836,7 @@ class MyObject extends CommonObject global $action, $hookmanager; $hookmanager->initHooks(array('myobjectdao')); - $parameters = array('id'=>$this->id, 'getnomurl'=>$result); + $parameters = array('id'=>$this->id, 'getnomurl' => &$result); $reshook = $hookmanager->executeHooks('getNomUrl', $parameters, $this, $action); // Note that $action and $object may have been modified by some hooks if ($reshook > 0) { $result = $hookmanager->resPrint; @@ -918,19 +918,19 @@ class MyObject extends CommonObject if ($this->db->num_rows($result)) { $obj = $this->db->fetch_object($result); $this->id = $obj->rowid; - if ($obj->fk_user_author) { + if (!empty($obj->fk_user_author)) { $cuser = new User($this->db); $cuser->fetch($obj->fk_user_author); $this->user_creation = $cuser; } - if ($obj->fk_user_valid) { + if (!empty($obj->fk_user_valid)) { $vuser = new User($this->db); $vuser->fetch($obj->fk_user_valid); $this->user_validation = $vuser; } - if ($obj->fk_user_cloture) { + if (!empty($obj->fk_user_cloture)) { $cluser = new User($this->db); $cluser->fetch($obj->fk_user_cloture); $this->user_cloture = $cluser; diff --git a/htdocs/modulebuilder/template/core/boxes/README.md b/htdocs/modulebuilder/template/core/boxes/README.md index b641e7136bc..3989bca5847 100644 --- a/htdocs/modulebuilder/template/core/boxes/README.md +++ b/htdocs/modulebuilder/template/core/boxes/README.md @@ -1 +1 @@ -Directory where widgets files are stored. \ No newline at end of file +# Directory where widgets files are stored diff --git a/htdocs/modulebuilder/template/core/boxes/mymodulewidget1.php b/htdocs/modulebuilder/template/core/boxes/mymodulewidget1.php index 82632773c87..7ea4b553e71 100644 --- a/htdocs/modulebuilder/template/core/boxes/mymodulewidget1.php +++ b/htdocs/modulebuilder/template/core/boxes/mymodulewidget1.php @@ -92,8 +92,8 @@ class mymodulewidget1 extends ModeleBoxes public function __construct(DoliDB $db, $param = '') { global $user, $conf, $langs; - $langs->load("boxes"); - $langs->load('mymodule@mymodule'); + // Translations + $langs->loadLangs(array("boxes", "mymodule@mymodule")); parent::__construct($db, $param); diff --git a/htdocs/modulebuilder/template/core/modules/mailings/mailinglist_mymodule_myobject.modules.php b/htdocs/modulebuilder/template/core/modules/mailings/mailinglist_mymodule_myobject.modules.php index dc797b99a94..b50f4acf741 100644 --- a/htdocs/modulebuilder/template/core/modules/mailings/mailinglist_mymodule_myobject.modules.php +++ b/htdocs/modulebuilder/template/core/modules/mailings/mailinglist_mymodule_myobject.modules.php @@ -55,9 +55,9 @@ class mailing_mailinglist_mymodule_myobject extends MailingTargets /** - * Affiche formulaire de filtre qui apparait dans page de selection des destinataires de mailings + * Displays the filter form that appears in the mailing recipient selection page * - * @return string Retourne zone select + * @return string Return select zone */ public function formFilter() { @@ -83,7 +83,7 @@ class mailing_mailinglist_mymodule_myobject extends MailingTargets /** - * Renvoie url lien vers fiche de la source du destinataire du mailing + * Returns url link to file of the source of the recipient of the mailing * * @param int $id ID * @return string Url lien @@ -115,7 +115,7 @@ class mailing_mailinglist_mymodule_myobject extends MailingTargets } $sql .= " ORDER BY email"; - // Stocke destinataires dans target + // Store recipients in target $result = $this->db->query($sql); if ($result) { $num = $this->db->num_rows($result); diff --git a/htdocs/modulebuilder/template/core/modules/modMyModule.class.php b/htdocs/modulebuilder/template/core/modules/modMyModule.class.php index de9188e714d..13e34593bba 100644 --- a/htdocs/modulebuilder/template/core/modules/modMyModule.class.php +++ b/htdocs/modulebuilder/template/core/modules/modMyModule.class.php @@ -148,8 +148,8 @@ class modMyModule extends DolibarrModules $this->need_dolibarr_version = array(11, -3); // Minimum version of Dolibarr required by module // Messages at activation - $this->warnings_activation = array(); // Warning to show when we activate module. array('always'='text') or array('FR'='textfr','ES'='textes'...) - $this->warnings_activation_ext = array(); // Warning to show when we activate an external module. array('always'='text') or array('FR'='textfr','ES'='textes'...) + $this->warnings_activation = array(); // Warning to show when we activate module. array('always'='text') or array('FR'='textfr','MX'='textmx'...) + $this->warnings_activation_ext = array(); // Warning to show when we activate an external module. array('always'='text') or array('FR'='textfr','MX'='textmx'...) //$this->automatic_activation = array('FR'=>'MyModuleWasAutomaticallyActivatedBecauseOfYourCountryChoice'); //$this->always_enabled = true; // If true, can't be disabled @@ -411,6 +411,7 @@ class modMyModule extends DolibarrModules { global $conf, $langs; + //$result = $this->_load_tables('/install/mysql/tables/', 'mymodule'); $result = $this->_load_tables('/mymodule/sql/'); if ($result < 0) { return -1; // Do not activate module if error 'not allowed' returned when loading module SQL queries (the _load_table run sql with run_sql with the error allowed parameter set to 'default') diff --git a/htdocs/modulebuilder/template/core/modules/mymodule/doc/doc_generic_myobject_odt.modules.php b/htdocs/modulebuilder/template/core/modules/mymodule/doc/doc_generic_myobject_odt.modules.php index 9126da0070d..689503f0dee 100644 --- a/htdocs/modulebuilder/template/core/modules/mymodule/doc/doc_generic_myobject_odt.modules.php +++ b/htdocs/modulebuilder/template/core/modules/mymodule/doc/doc_generic_myobject_odt.modules.php @@ -122,9 +122,10 @@ class doc_generic_myobject_odt extends ModelePDFMyObject $texte = $this->description.".
    \n"; $texte .= '
    '; $texte .= ''; + $texte .= ''; $texte .= ''; $texte .= ''; - $texte .= ''; + $texte .= '
    '; // List of directories area $texte .= ''; + // Add input to upload a new template file. + $texte .= '
    '.$langs->trans("UploadNewTemplate").' '; + $texte .= ''; + $texte .= ''; + $texte .= '
    '; + $texte .= ''; + $texte .= ''; $texte .= ''; diff --git a/htdocs/modulebuilder/template/core/modules/mymodule/mod_myobject_advanced.php b/htdocs/modulebuilder/template/core/modules/mymodule/mod_myobject_advanced.php index b7fd7085783..0573edc6b2a 100644 --- a/htdocs/modulebuilder/template/core/modules/mymodule/mod_myobject_advanced.php +++ b/htdocs/modulebuilder/template/core/modules/mymodule/mod_myobject_advanced.php @@ -68,8 +68,8 @@ class mod_myobject_advanced extends ModeleNumRefMyObject $texte .= ''; $texte .= ''; $texte .= ''; - $texte .= ''; - $texte .= '
    '; @@ -158,7 +159,7 @@ class doc_generic_myobject_odt extends ModelePDFMyObject $texte .= $conf->global->MYMODULE_MYOBJECT_ADDON_PDF_ODT_PATH; $texte .= ''; $texte .= '
    '; - $texte .= ''; + $texte .= ''; $texte .= '
    '; // Scan directories @@ -174,15 +175,27 @@ class doc_generic_myobject_odt extends ModelePDFMyObject if ($nbofiles) { $texte .= ''; } $texte .= '
    '; + $texte .= ''; $texte .= $langs->trans("ExampleOfDirectoriesForModelGen"); + $texte .= ''; $texte .= '
    '; + $texte .= ''; + $texte .= '
    '; $tooltip = $langs->trans("GenericMaskCodes", $langs->transnoentities("MyObject"), $langs->transnoentities("MyObject")); $tooltip .= $langs->trans("GenericMaskCodes2"); @@ -79,10 +79,8 @@ class mod_myobject_advanced extends ModeleNumRefMyObject // Parametrage du prefix $texte .= ''; - $texte .= ''; - - $texte .= ''; - + $texte .= ''; + $texte .= ''; $texte .= ''; $texte .= '
    '.$langs->trans("Mask").':'.$form->textwithpicto('', $tooltip, 1, 1).'  '.$form->textwithpicto('', $tooltip, 1, 1).' 
    '; diff --git a/htdocs/modulebuilder/template/lib/mymodule.lib.php b/htdocs/modulebuilder/template/lib/mymodule.lib.php index 32ae980e946..ab8a647efe4 100644 --- a/htdocs/modulebuilder/template/lib/mymodule.lib.php +++ b/htdocs/modulebuilder/template/lib/mymodule.lib.php @@ -62,7 +62,7 @@ function mymoduleAdminPrepareHead() //); // to remove a tab complete_head_from_modules($conf, $langs, null, $head, $h, 'mymodule@mymodule'); - complete_head_from_modules($conf, $langs, $object, $head, $h, 'mymodule@mymodule', 'remove'); + complete_head_from_modules($conf, $langs, null, $head, $h, 'mymodule@mymodule', 'remove'); return $head; } diff --git a/htdocs/modulebuilder/template/myobject_agenda.php b/htdocs/modulebuilder/template/myobject_agenda.php index add786498b2..5eb4f6e3028 100644 --- a/htdocs/modulebuilder/template/myobject_agenda.php +++ b/htdocs/modulebuilder/template/myobject_agenda.php @@ -102,8 +102,8 @@ if (GETPOST('actioncode', 'array')) { $search_agenda_label = GETPOST('search_agenda_label'); $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; @@ -129,7 +129,7 @@ $extrafields->fetch_name_optionals_label($object->table_element); // Load object include DOL_DOCUMENT_ROOT.'/core/actions_fetchobject.inc.php'; // Must be include, not include_once // Must be include, not include_once. Include fetch and fetch_thirdparty but not fetch_optionals if ($id > 0 || !empty($ref)) { - $upload_dir = $conf->mymodule->multidir_output[$object->entity]."/".$object->id; + $upload_dir = $conf->mymodule->multidir_output[!empty($object->entity) ? $object->entity : $conf->entity]."/".$object->id; } $permissiontoadd = $user->rights->mymodule->myobject->write; // Used by the include of actions_addupdatedelete.inc.php diff --git a/htdocs/modulebuilder/template/myobject_card.php b/htdocs/modulebuilder/template/myobject_card.php index 43c57ca1f94..531d463eea1 100644 --- a/htdocs/modulebuilder/template/myobject_card.php +++ b/htdocs/modulebuilder/template/myobject_card.php @@ -28,7 +28,7 @@ //if (! defined('NOREQUIRETRAN')) define('NOREQUIRETRAN', '1'); // Do not load object $langs //if (! defined('NOSCANGETFORINJECTION')) define('NOSCANGETFORINJECTION', '1'); // Do not check injection attack on GET parameters //if (! defined('NOSCANPOSTFORINJECTION')) define('NOSCANPOSTFORINJECTION', '1'); // Do not check injection attack on POST parameters -//if (! defined('NOCSRFCHECK')) define('NOCSRFCHECK', '1'); // Do not check CSRF attack (test on referer + on token if option MAIN_SECURITY_CSRF_WITH_TOKEN is on). +//if (! defined('NOCSRFCHECK')) define('NOCSRFCHECK', '1'); // Do not check CSRF attack (test on referer + on token). //if (! defined('NOTOKENRENEWAL')) define('NOTOKENRENEWAL', '1'); // Do not roll the Anti CSRF token (used if MAIN_SECURITY_CSRF_WITH_TOKEN is on) //if (! defined('NOSTYLECHECK')) define('NOSTYLECHECK', '1'); // Do not check style html tag into posted data //if (! defined('NOREQUIREMENU')) define('NOREQUIREMENU', '1'); // If there is no need to load and show top and left menu @@ -42,6 +42,7 @@ //if (! defined("FORCECSP")) define('FORCECSP', 'none'); // Disable all Content Security Policies //if (! defined('CSRFCHECK_WITH_TOKEN')) define('CSRFCHECK_WITH_TOKEN', '1'); // Force use of CSRF protection with tokens even for GET //if (! defined('NOBROWSERNOTIF')) define('NOBROWSERNOTIF', '1'); // Disable browser notification +//if (! defined('NOSESSION')) define('NOSESSION', '1'); // Disable session // Load Dolibarr environment $res = 0; @@ -92,7 +93,7 @@ $cancel = GETPOST('cancel', 'aZ09'); $contextpage = GETPOST('contextpage', 'aZ') ? GETPOST('contextpage', 'aZ') : 'myobjectcard'; // To manage different context of search $backtopage = GETPOST('backtopage', 'alpha'); $backtopageforcancel = GETPOST('backtopageforcancel', 'alpha'); -//$lineid = GETPOST('lineid', 'int'); +$lineid = GETPOST('lineid', 'int'); // Initialize technical objects $object = new MyObject($db); @@ -132,7 +133,7 @@ $upload_dir = $conf->mymodule->multidir_output[isset($object->entity) ? $object- // Security check (enable the most restrictive one) //if ($user->socid > 0) accessforbidden(); //if ($user->socid > 0) $socid = $user->socid; -//$isdraft = (($object->status == $object::STATUS_DRAFT) ? 1 : 0); +//$isdraft = (isset($object->status) && ($object->status == $object::STATUS_DRAFT) ? 1 : 0); //restrictedArea($user, $object->element, $object->id, $object->table_element, '', 'fk_soc', 'rowid', $isdraft); //if (empty($conf->mymodule->enabled)) accessforbidden(); //if (!$permissiontoread) accessforbidden(); @@ -212,7 +213,7 @@ $help_url = ''; llxHeader('', $title, $help_url); // Example : Adding jquery code -// print ''; } } - print ' '.$alreadyconsumed; + print ' '.price2num($alreadyconsumed, 'MS'); print '
    '; print ''; + print ''; if ($tmpproduct->stock_reel < ($line->qty - $alreadyconsumed)) { print img_warning($langs->trans('StockTooLow')).' '; } - print $tmpproduct->stock_reel; // Available + print price2num($tmpproduct->stock_reel, 'MS'); // Available print ''; - print ''; - print img_picto('', "delete"); + print ''; + print img_picto('', 'delete'); print ''; print '
    '; $tmpstockmovement->id = $line2['fk_stock_movement']; print ''.img_picto($langs->trans("StockMovement"), 'movement', 'class="paddingright"').''; print dol_print_date($line2['date'], 'dayhour', 'tzuserrel'); print ''.$line2['qty'].''; if ($line2['fk_warehouse'] > 0) { $result = $tmpwarehouse->fetch($line2['fk_warehouse']); @@ -929,6 +957,12 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea } } print ''; if ($line2['batch'] != '') { @@ -936,13 +970,19 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea print $tmpbatch->getNomUrl(1); } print '
    '.$langs->trans("ToConsume").''; if ($tmpproduct->type == Product::TYPE_PRODUCT || !empty($conf->global->STOCK_SUPPORTS_SERVICES)) { if (empty($line->disable_stock_change)) { $preselected = (GETPOSTISSET('idwarehouse-'.$line->id.'-'.$i) ? GETPOST('idwarehouse-'.$line->id.'-'.$i) : ($tmpproduct->fk_default_warehouse > 0 ? $tmpproduct->fk_default_warehouse : 'ifone')); - print $formproduct->selectWarehouses($preselected, 'idwarehouse-'.$line->id.'-'.$i, '', 1, 0, $line->fk_product, '', 1, 0, null, 'maxwidth300'); + print $formproduct->selectWarehouses($preselected, 'idwarehouse-'.$line->id.'-'.$i, '', 1, 0, $line->fk_product, '', 1, 0, null, 'maxwidth200 csswarehouse_'.$line->id.'_'.$i); } else { print ''.$langs->trans("DisableStockChange").''; } } else { print ''.$langs->trans("NoStockChangeOnServices").''; } - // Lot / Batch print ''; if ($tmpproduct->status_batch) { @@ -980,7 +1033,19 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea print $formproduct->selectLotDataList('batch-'.$line->id.'-'.$i, 0, $line->fk_product, '', ''); } print ''; + if ($tmpproduct->status_batch) { + $type = 'batch'; + print img_picto($langs->trans('AddStockLocationLine'), 'split.png', 'class="splitbutton" onClick="addDispatchLine('.$line->id.', \''.$type.'\', \'qtymissingconsume\')"'); + } + print '
    '; @@ -1044,7 +1112,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea print ''."\n"; print ''; print ''; // Qty print ''; @@ -1052,10 +1120,10 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea print ''; // Qty already produced - print ''; + print ''; // Lot - serial if ($conf->productbatch->enabled) { @@ -1155,7 +1223,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea $href .= '&action=deleteline'; $href .= '&lineid='.$line->id; print ''; @@ -1228,7 +1296,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea print ''; print ''; print ''; +print ''; +print ''; print ''; print ''; //print ''; diff --git a/htdocs/multicurrency/multicurrency_rate.php b/htdocs/multicurrency/multicurrency_rate.php index 36a6af12750..73cff1b4502 100644 --- a/htdocs/multicurrency/multicurrency_rate.php +++ b/htdocs/multicurrency/multicurrency_rate.php @@ -55,8 +55,8 @@ $dateinput = dol_mktime(0, 0, 0, GETPOST('dateinputmonth', 'int'), GETPOST('d $rateinput = price2num(GETPOST('rateinput', 'alpha')); $optioncss = GETPOST('optioncss', 'alpha'); $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = (GETPOST("page", 'int') ?GETPOST("page", 'int') : 0); if (empty($page) || $page == -1) { @@ -229,7 +229,7 @@ if (empty($reshook)) { * View */ -$htmlother = new FormOther($db); +$form = new Form($db); $title = $langs->trans("CurrencyRate"); $page_name = "MultiCurrencySetup"; @@ -247,12 +247,6 @@ print dol_get_fiche_head($head, 'ratelist', $langs->trans("ModuleSetup"), -1, "m // ACTION if (!in_array($action, array("updateRate", "deleteRate"))) { - print '
    '; - print $form->select_produits('', 'productidtoadd', '', 0, 0, -1, 2, '', 0, array(), 0, '1', 0, 'maxwidth300'); + print $form->select_produits('', 'productidtoadd', '', 0, 0, -1, 2, '', 1, array(), 0, '1', 0, 'maxwidth300'); print ''; // Warehouse - print ''; print ''; + print ''; print ''; - print ''; + print ''; print img_picto('', "delete"); print ''; print ''; if ($tmpproduct->type == Product::TYPE_PRODUCT || !empty($conf->global->STOCK_SUPPORTS_SERVICES)) { $preselected = (GETPOSTISSET('idwarehousetoproduce-'.$line->id.'-'.$i) ? GETPOST('idwarehousetoproduce-'.$line->id.'-'.$i) : ($object->fk_warehouse > 0 ? $object->fk_warehouse : 'ifone')); - print $formproduct->selectWarehouses($preselected, 'idwarehousetoproduce-'.$line->id.'-'.$i, '', 1, 0, $line->fk_product, '', 1, 0, null, 'maxwidth300 csswarehouse_'.$line->id.'_'.$i); + print $formproduct->selectWarehouses($preselected, 'idwarehousetoproduce-'.$line->id.'-'.$i, '', 1, 0, $line->fk_product, '', 1, 0, null, 'maxwidth200 csswarehouse_'.$line->id.'_'.$i); } else { print ''.$langs->trans("NoStockChangeOnServices").''; } diff --git a/htdocs/mrp/tpl/originproductline.tpl.php b/htdocs/mrp/tpl/originproductline.tpl.php index 478c6504979..ba1d7fccd86 100644 --- a/htdocs/mrp/tpl/originproductline.tpl.php +++ b/htdocs/mrp/tpl/originproductline.tpl.php @@ -39,6 +39,16 @@ $qtytoconsumeforline = price2num($qtytoconsumeforline, 'MS'); print '
    '.$this->tpl['label'].''.$this->tpl['qty'].(($this->tpl['efficiency'] > 0 && $this->tpl['efficiency'] < 1) ? ' / '.$form->textwithpicto($this->tpl['efficiency'], $langs->trans("ValueOfMeansLoss")).' = '.$qtytoconsumeforline : '').''.(empty($this->tpl['stock']) ? 0 : price2num($this->tpl['stock'], 'MS')); +if ($this->tpl['seuil_stock_alerte'] != '' && ($this->tpl['stock'] < $this->tpl['seuil_stock_alerte'])) { + print ' '.img_warning($langs->trans("StockLowerThanLimit", $this->tpl['seuil_stock_alerte'])); +} +print ''.((empty($this->tpl['virtual_stock']) ? 0 : price2num($this->tpl['virtual_stock'], 'MS'))); +if ($this->tpl['seuil_stock_alerte'] != '' && ($this->tpl['virtual_stock'] < $this->tpl['seuil_stock_alerte'])) { + print ' '.img_warning($langs->trans("StockLowerThanLimit", $this->tpl['seuil_stock_alerte'])); +} +print ''.($this->tpl['qty_frozen'] ? yn($this->tpl['qty_frozen']) : '').''.($this->tpl['disable_stock_change'] ? yn($this->tpl['disable_stock_change']) : '').''.$this->tpl['efficiency'].'
    '; - print ''; - print ''."\n"; - print '
    '.$langs->trans("FormCreateRate").'
    '; - - $form = new Form($db); print ''; print ''; @@ -410,8 +404,8 @@ if ($resql) { $selectedfields .= $form->showCheckAddButtons('checkforselect', 1); } - print '
    '; - print ''."\n"; + print '
    '; + print '
    '."\n"; // Lines with input filters print ''; diff --git a/htdocs/opensurvey/card.php b/htdocs/opensurvey/card.php index 773571b7b1c..bc018a2dda1 100644 --- a/htdocs/opensurvey/card.php +++ b/htdocs/opensurvey/card.php @@ -54,6 +54,9 @@ if ($result <= 0) { exit; } +// Initialize technical object to manage hooks of page. Note that conf->hooks_modules contains array of hook context +$hookmanager->initHooks(array('surveycard', 'globalcard')); + $expiredate = dol_mktime(0, 0, 0, GETPOST('expiremonth'), GETPOST('expireday'), GETPOST('expireyear')); @@ -134,18 +137,18 @@ if (empty($reshook)) { if (GETPOST('ajoutcomment')) { $error = 0; - if (!GETPOST('comment')) { + if (!GETPOST('comment', "alphanohtml")) { $error++; setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("Comment")), null, 'errors'); } - if (!GETPOST('commentuser')) { + if (!GETPOST('commentuser', "alphanohtml")) { $error++; setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("User")), null, 'errors'); } if (!$error) { - $comment = (string) GETPOST("comment", "restricthtml"); - $comment_user = (string) GETPOST('commentuser', "restricthtml"); + $comment = (string) GETPOST("comment", "alphanohtml"); + $comment_user = (string) GETPOST('commentuser', "alphanohtml"); $resql = $object->addComment($comment, $comment_user); @@ -338,6 +341,11 @@ if ($action != 'edit') { print ''; +// Other attributes +$parameters = array(); +$reshook = $hookmanager->executeHooks('formObjectOptions', $parameters, $object, $action); // Note that $action and $object may have been modified by hook +print $hookmanager->resPrint; + print '
    '; print '
    '; @@ -414,7 +422,7 @@ print '
    '; if ($object->allow_comments) { print $langs->trans("AddACommentForPoll").'
    '; print '
    '."\n"; - print $langs->trans("Name").': '."\n"; + print $langs->trans("Name").': '."\n"; print '
    '."\n"; } diff --git a/htdocs/opensurvey/fonctions.php b/htdocs/opensurvey/fonctions.php index 3d8d76c5c1e..f844921720b 100644 --- a/htdocs/opensurvey/fonctions.php +++ b/htdocs/opensurvey/fonctions.php @@ -206,7 +206,7 @@ function getUrlSondage($id, $admin = false) /** * Generate a random id * - * @param string $car Char to generate key + * @param int $car Length of string to generate key * @return string */ function dol_survey_random($car) diff --git a/htdocs/opensurvey/results.php b/htdocs/opensurvey/results.php index e37f9bf3de5..5b564f617fd 100644 --- a/htdocs/opensurvey/results.php +++ b/htdocs/opensurvey/results.php @@ -103,13 +103,13 @@ $testmodifier = false; $testligneamodifier = false; $ligneamodifier = -1; for ($i = 0; $i < $nblines; $i++) { - if (isset($_POST['modifierligne'.$i])) { + if (GETPOSTISSET('modifierligne'.$i)) { $ligneamodifier = $i; $testligneamodifier = true; } //test pour voir si une ligne est a modifier - if (isset($_POST['validermodifier'.$i])) { + if (GETPOSTISSET('validermodifier'.$i)) { $modifier = $i; $testmodifier = true; } @@ -153,7 +153,7 @@ if (GETPOST("ajoutercolonne") && GETPOST('nouvellecolonne') && $object->format = //on rajoute la valeur a la fin de tous les sujets deja entrés $nouveauxsujets .= ','; - $nouveauxsujets .= str_replace(array(",", "@"), " ", GETPOST("nouvellecolonne")).(empty($_POST["typecolonne"]) ? '' : '@'.GETPOST("typecolonne")); + $nouveauxsujets .= str_replace(array(",", "@"), " ", GETPOST("nouvellecolonne")).(!GETPOST("typecolonne") ? '' : '@'.GETPOST("typecolonne")); //mise a jour avec les nouveaux sujets dans la base $sql = 'UPDATE '.MAIN_DB_PREFIX."opensurvey_sondage"; diff --git a/htdocs/opensurvey/wizard/choix_date.php b/htdocs/opensurvey/wizard/choix_date.php index 817f3d88139..762770acee6 100644 --- a/htdocs/opensurvey/wizard/choix_date.php +++ b/htdocs/opensurvey/wizard/choix_date.php @@ -51,7 +51,8 @@ if (GETPOST('confirmation')) { for ($i = 0; $i < $nbofchoice; $i++) { // Show hours choices for ($j = 0; $j < $_SESSION["nbrecaseshoraires"]; $j++) { - $_SESSION["horaires$i"][$j] = $_POST["horaires$i"][$j]; + $horairesi = GETPOST("horaires".$i); + $_SESSION["horaires$i"][$j] = $horairesi[$j]; $tmphorairesi = GETPOST('horaires'.$i, 'array'); @@ -248,7 +249,8 @@ if (issetAndNoEmpty('moisavant_x') || issetAndNoEmpty('moisavant')) { for ($i = 0; $i < $nbofchoice; $i++) { //affichage des 5 cases horaires for ($j = 0; $j < $_SESSION["nbrecaseshoraires"]; $j++) { - $_SESSION["horaires$i"][$j] = $_POST["horaires$i"][$j]; + $horairesi = GETPOST("horaires".$i); + $_SESSION["horaires$i"][$j] = $horairesi[$j]; } } } @@ -269,7 +271,8 @@ if (issetAndNoEmpty('moisapres_x') || issetAndNoEmpty('moisapres')) { for ($i = 0; $i < $nbofchoice; $i++) { //affichage des 5 cases horaires for ($j = 0; $j < $_SESSION["nbrecaseshoraires"]; $j++) { - $_SESSION["horaires$i"][$j] = $_POST["horaires$i"][$j]; + $horairesi = GETPOST("horaires".$i); + $_SESSION["horaires$i"][$j] = $horairesi[$j]; } } } @@ -285,7 +288,8 @@ if (issetAndNoEmpty('anneeavant_x') || issetAndNoEmpty('anneeavant')) { for ($i = 0; $i < $nbofchoice; $i++) { //affichage des 5 cases horaires for ($j = 0; $j < $_SESSION["nbrecaseshoraires"]; $j++) { - $_SESSION["horaires$i"][$j] = $_POST["horaires$i"][$j]; + $horairesi = GETPOST("horaires".$i); + $_SESSION["horaires$i"][$j] = $horairesi[$j]; } } } @@ -301,7 +305,8 @@ if (issetAndNoEmpty('anneeapres_x') || issetAndNoEmpty('anneeapres')) { for ($i = 0; $i < $nbofchoice; $i++) { //affichage des 5 cases horaires for ($j = 0; $j < $_SESSION["nbrecaseshoraires"]; $j++) { - $_SESSION["horaires$i"][$j] = $_POST["horaires$i"][$j]; + $horairesi = GETPOST("horaires".$i); + $_SESSION["horaires$i"][$j] = $horairesi[$j]; } } } @@ -365,7 +370,8 @@ if (issetAndNoEmpty('choixjourajout')) { if (issetAndNoEmpty('totalchoixjour', $_SESSION) === true && issetAndNoEmpty('choixjourajout') === true) { $nbofchoice = count($_SESSION["totalchoixjour"]); for ($i = 0; $i < $nbofchoice; $i++) { - if ($_SESSION["totalchoixjour"][$i] == mktime(0, 0, 0, $_SESSION["mois"], $_POST["choixjourajout"][0], $_SESSION["annee"])) { + $choixjourajout = GETPOST("choixjourajout"); + if ($_SESSION["totalchoixjour"][$i] == mktime(0, 0, 0, $_SESSION["mois"], $choixjourajout[0], $_SESSION["annee"])) { $journeuf = false; } } @@ -373,15 +379,17 @@ if (issetAndNoEmpty('choixjourajout')) { // Si le test est passé, alors on insere la valeur dans la variable de session qui contient les dates if ($journeuf && issetAndNoEmpty('choixjourajout') === true) { - array_push($_SESSION["totalchoixjour"], dol_mktime(0, 0, 0, $_SESSION["mois"], $_POST["choixjourajout"][0], $_SESSION["annee"])); + $choixjourajout = GETPOST("choixjourajout"); + array_push($_SESSION["totalchoixjour"], dol_mktime(0, 0, 0, $_SESSION["mois"], $choixjourajout[0], $_SESSION["annee"])); sort($_SESSION["totalchoixjour"]); - $cle = array_search(dol_mktime(0, 0, 0, $_SESSION["mois"], $_POST["choixjourajout"][0], $_SESSION["annee"]), $_SESSION["totalchoixjour"]); + $cle = array_search(dol_mktime(0, 0, 0, $_SESSION["mois"], $choixjourajout[0], $_SESSION["annee"]), $_SESSION["totalchoixjour"]); //On sauvegarde les heures deja entrées for ($i = 0; $i < $cle; $i++) { + $horairesi = GETPOST("horaires".$i); for ($j = 0; $j < $_SESSION["nbrecaseshoraires"]; $j++) { if (issetAndNoEmpty('horaires'.$i) === true && issetAndNoEmpty($i, $_POST['horaires'.$i]) === true) { - $_SESSION["horaires$i"][$j] = $_POST["horaires$i"][$j]; + $_SESSION["horaires$i"][$j] = $horairesi[$j]; } } } @@ -391,7 +399,8 @@ if (issetAndNoEmpty('choixjourajout')) { $k = $i + 1; if (issetAndNoEmpty('horaires'.$i) === true && issetAndNoEmpty($i, $_POST['horaires'.$i]) === true) { for ($j = 0; $j < $_SESSION["nbrecaseshoraires"]; $j++) { - $_SESSION["horaires$k"][$j] = $_POST["horaires$i"][$j]; + $horairesi = GETPOST("horaires".$i); + $_SESSION["horaires$i"][$j] = $horairesi[$j]; } } } @@ -407,12 +416,14 @@ if (issetAndNoEmpty('choixjourretrait')) { for ($i = 0; $i < $nbofchoice; $i++) { //affichage des 5 cases horaires for ($j = 0; $j < $_SESSION["nbrecaseshoraires"]; $j++) { - $_SESSION["horaires$i"][$j] = $_POST["horaires$i"][$j]; + $horairesi = GETPOST("horaires".$i); + $_SESSION["horaires$i"][$j] = $horairesi[$j]; } } for ($i = 0; $i < $nbofchoice; $i++) { - if ($_SESSION["totalchoixjour"][$i] == mktime(0, 0, 0, $_SESSION["mois"], $_POST["choixjourretrait"][0], $_SESSION["annee"])) { + $choixjourretrait = GETPOST('choixjourretrait'); + if ($_SESSION["totalchoixjour"][$i] == mktime(0, 0, 0, $_SESSION["mois"], $choixjourretrait[0], $_SESSION["annee"])) { for ($j = $i; $j < $nbofchoice; $j++) { $k = $j + 1; $_SESSION["horaires$j"] = $_SESSION["horaires$k"]; @@ -425,7 +436,7 @@ if (issetAndNoEmpty('choixjourretrait')) { //report des horaires dans toutes les cases if (issetAndNoEmpty('reporterhoraires')) { - $_SESSION["horaires0"] = $_POST["horaires0"]; + $_SESSION["horaires0"] = GETPOST("horaires0"); $nbofchoice = count($_SESSION["totalchoixjour"]); for ($i = 0; $i < $nbofchoice; $i++) { $j = $i + 1; diff --git a/htdocs/partnership/admin/website.php b/htdocs/partnership/admin/website.php index 96ebb4ba6e9..5fb48248280 100644 --- a/htdocs/partnership/admin/website.php +++ b/htdocs/partnership/admin/website.php @@ -248,7 +248,7 @@ if (!empty($conf->global->PARTNERSHIP_ENABLE_PUBLIC)) { print ''; print ajax_autoselect('publicurlmember'); } diff --git a/htdocs/partnership/class/partnership.class.php b/htdocs/partnership/class/partnership.class.php index f2b15735762..b9c6cc86113 100644 --- a/htdocs/partnership/class/partnership.class.php +++ b/htdocs/partnership/class/partnership.class.php @@ -1,6 +1,6 @@ - * Copyright (C) 2021 NextGestion +/* Copyright (C) 2017 Laurent Destailleur + * Copyright (C) 2021 NextGestion * * 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 @@ -27,6 +27,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/commonobject.class.php'; //require_once DOL_DOCUMENT_ROOT . '/societe/class/societe.class.php'; //require_once DOL_DOCUMENT_ROOT . '/product/class/product.class.php'; + /** * Class for Partnership */ @@ -66,7 +67,7 @@ class Partnership extends CommonObject const STATUS_DRAFT = 0; const STATUS_VALIDATED = 1; // Validate (no more draft) - const STATUS_ACCEPTED = 2; // Approved + const STATUS_APPROVED = 2; // Approved const STATUS_REFUSED = 3; // Refused const STATUS_CANCELED = 9; @@ -105,7 +106,7 @@ class Partnership extends CommonObject 'rowid' => array('type'=>'integer', 'label'=>'TechnicalID', 'enabled'=>'1', 'position'=>1, 'notnull'=>1, 'visible'=>0, 'noteditable'=>'1', 'index'=>1, 'css'=>'left', 'comment'=>"Id"), 'ref' => array('type'=>'varchar(128)', 'label'=>'Ref', 'enabled'=>'1', 'position'=>10, 'notnull'=>1, 'visible'=>4, 'noteditable'=>'1', 'default'=>'(PROV)', 'index'=>1, 'searchall'=>1, 'showoncombobox'=>'1', 'comment'=>"Reference of object"), 'entity' => array('type' => 'integer', 'label' => 'Entity', 'default' => 1, 'enabled' => 1, 'visible' => -2, 'notnull' => 1, 'position' => 15, 'index' => 1), - //'fk_type' => array('type' => 'integer:PartnershipType:partnership/class/partnershiptype.class.php', 'label' => 'Type', 'default' => 1, 'enabled' => 1, 'visible' => 1, 'position' => 20), + 'fk_type' => array('type' => 'integer:PartnershipType:partnership/class/partnership_type.class.php', 'label' => 'Type', 'notnull'=>1, 'enabled' => 1, 'visible' => 1, 'position' => 20), 'note_public' => array('type'=>'html', 'label'=>'NotePublic', 'enabled'=>'1', 'position'=>61, 'notnull'=>0, 'visible'=>0,), 'note_private' => array('type'=>'html', 'label'=>'NotePrivate', 'enabled'=>'1', 'position'=>62, 'notnull'=>0, 'visible'=>0,), 'date_creation' => array('type'=>'datetime', 'label'=>'DateCreation', 'enabled'=>'1', 'position'=>500, 'notnull'=>1, 'visible'=>-2,), @@ -117,7 +118,7 @@ class Partnership extends CommonObject 'model_pdf' => array('type'=>'varchar(255)', 'label'=>'Model pdf', 'enabled'=>'1', 'position'=>1010, 'notnull'=>-1, 'visible'=>0,), 'date_partnership_start' => array('type'=>'date', 'label'=>'DatePartnershipStart', 'enabled'=>'1', 'position'=>52, 'notnull'=>1, 'visible'=>1,), 'date_partnership_end' => array('type'=>'date', 'label'=>'DatePartnershipEnd', 'enabled'=>'1', 'position'=>53, 'notnull'=>0, 'visible'=>1,), - 'status' => array('type'=>'smallint', 'label'=>'Status', 'enabled'=>'1', 'position'=>54, 'notnull'=>0, 'visible'=>2, 'index'=>1, 'arrayofkeyval'=>array('-1'=>'','0'=>'Draft', '1'=>'Accepted', '2'=>'Refused', '9'=>'Canceled'),), + 'status' => array('type'=>'smallint', 'label'=>'Status', 'enabled'=>'1', 'position'=>54, 'notnull'=>0, 'visible'=>2, 'index'=>1, 'arrayofkeyval'=>array('-1'=>'','0'=>'Draft', '1'=>'Accepted', '2'=>'Refused', '9'=>'Terminated'),), 'count_last_url_check_error' => array('type'=>'integer', 'label'=>'CountLastUrlCheckError', 'enabled'=>'1', 'position'=>63, 'notnull'=>0, 'visible'=>-2, 'default'=>'0',), 'last_check_backlink' => array('type'=>'datetime', 'label'=>'LastCheckBacklink', 'enabled'=>'1', 'position'=>65, 'notnull'=>0, 'visible'=>-2,), 'reason_decline_or_cancel' => array('type'=>'text', 'label'=>'ReasonDeclineOrCancel', 'enabled'=>'1', 'position'=>64, 'notnull'=>0, 'visible'=>-2,), @@ -244,6 +245,11 @@ class Partnership extends CommonObject */ public function create(User $user, $notrigger = false) { + if ($this->fk_soc <= 0 && $this->fk_member <= 0) { + $this->error[] = "ErrorThirpdartyOrMemberidIsManadatory"; + return -1; + } + $this->status = 0; return $this->createCommon($user, $notrigger); } @@ -366,14 +372,15 @@ class Partnership extends CommonObject return -1; } - $sql = 'SELECT p.rowid, p.ref, p.fk_soc, p.fk_member, p.status'; + $sql = 'SELECT p.rowid, p.ref, p.fk_type, p.fk_soc, p.fk_member, p.status'; $sql .= ', p.entity, p.date_partnership_start, p.date_partnership_end, p.date_creation'; $sql .= ', p.fk_user_creat, p.tms, p.fk_user_modif, p.fk_user_modif'; $sql .= ', p.note_private, p.note_public'; $sql .= ', p.last_main_doc, p.count_last_url_check_error, p.last_check_backlink, p.reason_decline_or_cancel'; $sql .= ', p.import_key, p.model_pdf'; - + $sql .= ', pt.code as type_code, pt.label as type_label'; $sql .= ' FROM '.MAIN_DB_PREFIX.'partnership as p'; + $sql .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_partnership_type as pt ON p.fk_type = pt.rowid'; if ($id) { $sql .= " WHERE p.rowid=".((int) $id); @@ -400,8 +407,12 @@ class Partnership extends CommonObject if ($obj) { $this->id = $obj->rowid; $this->entity = $obj->entity; - $this->rowid = $obj->rowid; $this->ref = $obj->ref; + + $this->fk_type = $obj->fk_type; + $this->type_code = $obj->type_code; + $this->type_label = $obj->type_label; + $this->fk_soc = $obj->fk_soc; $this->fk_member = $obj->fk_member; $this->status = $obj->status; @@ -541,6 +552,11 @@ class Partnership extends CommonObject */ public function update(User $user, $notrigger = false) { + if ($this->fk_soc <= 0 && $this->fk_member <= 0) { + $this->error[] = "ErrorThirpdartyOrMemberidIsManadatory"; + return -1; + } + return $this->updateCommon($user, $notrigger); } @@ -701,13 +717,13 @@ class Partnership extends CommonObject } /** - * Accept object + * Approve object * * @param User $user User making status change * @param int $notrigger 1=Does not execute triggers, 0= execute triggers * @return int <=0 if OK, 0=Nothing done, >0 if KO */ - public function accept($user, $notrigger = 0) + public function approve($user, $notrigger = 0) { global $conf, $langs; @@ -716,7 +732,7 @@ class Partnership extends CommonObject $error = 0; // Protection - if ($this->status == self::STATUS_ACCEPTED) { + if ($this->status == self::STATUS_APPROVED) { dol_syslog(get_class($this)."::accept action abandonned: already acceptd", LOG_WARNING); return 0; } @@ -745,7 +761,7 @@ class Partnership extends CommonObject // Accept $sql = "UPDATE ".MAIN_DB_PREFIX.$this->table_element; $sql .= " SET ref = '".$this->db->escape($num)."',"; - $sql .= " status = ".self::STATUS_ACCEPTED; + $sql .= " status = ".self::STATUS_APPROVED; // if (!empty($this->fields['date_validation'])) { // $sql .= ", date_validation = '".$this->db->idate($now)."'"; // } @@ -812,7 +828,7 @@ class Partnership extends CommonObject // Set new ref and current status if (!$error) { $this->ref = $num; - $this->status = self::STATUS_ACCEPTED; + $this->status = self::STATUS_APPROVED; } if (!$error) { @@ -887,7 +903,7 @@ class Partnership extends CommonObject public function cancel($user, $notrigger = 0) { // Protection - if ($this->status != self::STATUS_ACCEPTED) { + if ($this->status != self::STATUS_APPROVED) { return 0; } @@ -922,7 +938,7 @@ class Partnership extends CommonObject return -1; }*/ - return $this->setStatusCommon($user, self::STATUS_ACCEPTED, $notrigger, 'PARTNERSHIP_REOPEN'); + return $this->setStatusCommon($user, self::STATUS_APPROVED, $notrigger, 'PARTNERSHIP_REOPEN'); } /** @@ -1029,7 +1045,7 @@ class Partnership extends CommonObject global $action, $hookmanager; $hookmanager->initHooks(array('partnershipdao')); - $parameters = array('id'=>$this->id, 'getnomurl'=>$result); + $parameters = array('id'=>$this->id, 'getnomurl' => &$result); $reshook = $hookmanager->executeHooks('getNomUrl', $parameters, $this, $action); // Note that $action and $object may have been modified by some hooks if ($reshook > 0) { $result = $hookmanager->resPrint; @@ -1067,18 +1083,18 @@ class Partnership extends CommonObject //$langs->load("partnership"); $this->labelStatus[self::STATUS_DRAFT] = $langs->transnoentitiesnoconv('Draft'); $this->labelStatus[self::STATUS_VALIDATED] = $langs->transnoentitiesnoconv('Validated'); - $this->labelStatus[self::STATUS_ACCEPTED] = $langs->transnoentitiesnoconv('Accepted'); + $this->labelStatus[self::STATUS_APPROVED] = $langs->transnoentitiesnoconv('Approved'); $this->labelStatus[self::STATUS_REFUSED] = $langs->transnoentitiesnoconv('Refused'); - $this->labelStatus[self::STATUS_CANCELED] = $langs->transnoentitiesnoconv('Canceled'); + $this->labelStatus[self::STATUS_CANCELED] = $langs->transnoentitiesnoconv('Terminated'); $this->labelStatusShort[self::STATUS_DRAFT] = $langs->transnoentitiesnoconv('Draft'); $this->labelStatusShort[self::STATUS_VALIDATED] = $langs->transnoentitiesnoconv('Validated'); - $this->labelStatusShort[self::STATUS_ACCEPTED] = $langs->transnoentitiesnoconv('Accepted'); + $this->labelStatusShort[self::STATUS_APPROVED] = $langs->transnoentitiesnoconv('Approved'); $this->labelStatusShort[self::STATUS_REFUSED] = $langs->transnoentitiesnoconv('Refused'); - $this->labelStatusShort[self::STATUS_CANCELED] = $langs->transnoentitiesnoconv('Canceled'); + $this->labelStatusShort[self::STATUS_CANCELED] = $langs->transnoentitiesnoconv('Terminated'); } $statusType = 'status'.$status; - if ($status == self::STATUS_ACCEPTED) { + if ($status == self::STATUS_APPROVED) { $statusType = 'status4'; } if ($status == self::STATUS_REFUSED) { diff --git a/htdocs/partnership/class/partnership_type.class.php b/htdocs/partnership/class/partnership_type.class.php new file mode 100644 index 00000000000..5b6ed5e5378 --- /dev/null +++ b/htdocs/partnership/class/partnership_type.class.php @@ -0,0 +1,562 @@ + + * Copyright (C) 2004-2008 Laurent Destailleur + * Copyright (C) 2009-2017 Regis Houssin + * Copyright (C) 2016 Charlie Benke + * Copyright (C) 2018-2019 Thibault Foucart + * Copyright (C) 2021 Waël Almoman + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file htdocs/partnership/class/partnership_type.class.php + * \ingroup partnership + * \brief File of class to manage partnership types + */ + +require_once DOL_DOCUMENT_ROOT.'/core/class/commonobject.class.php'; + + +/** + * Class to manage partnership type + */ +class PartnershipType extends CommonObject +{ + /** + * @var string Name of table without prefix where object is stored + */ + public $table_element = 'c_partnership_type'; + + /** + * @var string ID to identify managed object + */ + public $element = 'partnership_type'; + + /** + * @var string String with name of icon for myobject. Must be the part after the 'object_' into object_myobject.png + */ + public $picto = 'generic'; + + /** + * 0=No test on entity, 1=Test with field entity, 2=Test with link by societe + * @var int + */ + public $ismultientitymanaged = 1; + + /** + * @var string Partnership code + */ + public $code; + + /** + * @var string Partnership type label + */ + public $label; + + + public $fields=array( + 'rowid' =>array('type'=>'integer', 'label'=>'TechnicalID', 'enabled'=>1, 'visible'=>-1, 'notnull'=>1, 'position'=>10), + 'entity' =>array('type'=>'integer', 'label'=>'Entity', 'default'=>1, 'enabled'=>1, 'visible'=>-2, 'notnull'=>1, 'position'=>15, 'index'=>1), + 'code' =>array('type'=>'varchar(32)', 'label'=>'Code', 'enabled'=>1, 'visible'=>-1, 'notnull'=>1, 'position'=>20, 'showoncombobox'=>1), + 'label' =>array('type'=>'varchar(64)', 'label'=>'Label', 'enabled'=>1, 'visible'=>-1, 'notnull'=>1, 'position'=>25, 'showoncombobox'=>1), + 'active' =>array('type'=>'integer', 'label'=>'Active', 'enabled'=>1, 'visible'=>-1, 'notnull'=>1, 'position'=>30), + ); + + + + /** + * Constructor + * + * @param DoliDb $db Database handler + */ + public function __construct(DoliDB $db) + { + global $conf, $langs; + + $this->db = $db; + + if (empty($conf->global->MAIN_SHOW_TECHNICAL_ID) && isset($this->fields['rowid'])) { + $this->fields['rowid']['visible'] = 0; + } + if (empty($conf->multicompany->enabled) && isset($this->fields['entity'])) { + $this->fields['entity']['enabled'] = 0; + } + + // Example to show how to set values of fields definition dynamically + /*if ($user->rights->mymodule->myobject->read) { + $this->fields['myfield']['visible'] = 1; + $this->fields['myfield']['noteditable'] = 0; + }*/ + + // Unset fields that are disabled + foreach ($this->fields as $key => $val) { + if (isset($val['enabled']) && empty($val['enabled'])) { + unset($this->fields[$key]); + } + } + + // Translate some data of arrayofkeyval + if (is_object($langs)) { + foreach ($this->fields as $key => $val) { + if (!empty($val['arrayofkeyval']) && is_array($val['arrayofkeyval'])) { + foreach ($val['arrayofkeyval'] as $key2 => $val2) { + $this->fields[$key]['arrayofkeyval'][$key2] = $langs->trans($val2); + } + } + } + } + } + + /** + * Create object into database + * + * @param User $user User that creates + * @param bool $notrigger false=launch triggers after, true=disable triggers + * @return int <0 if KO, Id of created object if OK + */ + public function create(User $user, $notrigger = false) + { + $resultcreate = $this->createCommon($user, $notrigger); + + //$resultvalidate = $this->validate($user, $notrigger); + + return $resultcreate; + } + + /** + * Load object in memory from the database + * + * @param int $id Id object + * @param string $ref Ref + * @return int <0 if KO, 0 if not found, >0 if OK + */ + public function fetch($id, $ref = null) + { + $result = $this->fetchCommon($id, $ref); + if ($result > 0 && !empty($this->table_element_line)) { + $this->fetchLines(); + } + return $result; + } + + /** + * Load list of objects in memory from the database. + * + * @param string $sortorder Sort Order + * @param string $sortfield Sort field + * @param int $limit limit + * @param int $offset Offset + * @param array $filter Filter array. Example array('field'=>'valueforlike', 'customurl'=>...) + * @param string $filtermode Filter mode (AND or OR) + * @return array|int int <0 if KO, array of pages if OK + */ + public function fetchAll($sortorder = '', $sortfield = '', $limit = 0, $offset = 0, array $filter = array(), $filtermode = 'AND') + { + global $conf; + + dol_syslog(__METHOD__, LOG_DEBUG); + + $records = array(); + + $sql = "SELECT "; + $sql .= $this->getFieldList('t'); + $sql .= " FROM ".MAIN_DB_PREFIX.$this->table_element." as t"; + if (isset($this->ismultientitymanaged) && $this->ismultientitymanaged == 1) { + $sql .= " WHERE t.entity IN (".getEntity($this->table_element).")"; + } else { + $sql .= " WHERE 1 = 1"; + } + // Manage filter + $sqlwhere = array(); + if (count($filter) > 0) { + foreach ($filter as $key => $value) { + if ($key == 't.rowid') { + $sqlwhere[] = $key." = ".((int) $value); + } elseif (in_array($this->fields[$key]['type'], array('date', 'datetime', 'timestamp'))) { + $sqlwhere[] = $key." = '".$this->db->idate($value)."'"; + } elseif ($key == 'customsql') { + $sqlwhere[] = $value; + } elseif (strpos($value, '%') === false) { + $sqlwhere[] = $key." IN (".$this->db->sanitize($this->db->escape($value)).")"; + } else { + $sqlwhere[] = $key." LIKE '%".$this->db->escape($value)."%'"; + } + } + } + if (count($sqlwhere) > 0) { + $sql .= " AND (".implode(" ".$filtermode." ", $sqlwhere).")"; + } + + if (!empty($sortfield)) { + $sql .= $this->db->order($sortfield, $sortorder); + } + if (!empty($limit)) { + $sql .= $this->db->plimit($limit, $offset); + } + + $resql = $this->db->query($sql); + if ($resql) { + $num = $this->db->num_rows($resql); + $i = 0; + while ($i < ($limit ? min($limit, $num) : $num)) { + $obj = $this->db->fetch_object($resql); + + $record = new self($this->db); + $record->setVarsFromFetchObj($obj); + + $records[$record->id] = $record; + + $i++; + } + $this->db->free($resql); + + return $records; + } else { + $this->errors[] = 'Error '.$this->db->lasterror(); + dol_syslog(__METHOD__.' '.join(',', $this->errors), LOG_ERR); + + return -1; + } + } + + /** + * Update object into database + * + * @param User $user User that modifies + * @param bool $notrigger false=launch triggers after, true=disable triggers + * @return int <0 if KO, >0 if OK + */ + public function update(User $user, $notrigger = false) + { + return $this->updateCommon($user, $notrigger); + } + + /** + * Delete object in database + * + * @param User $user User that deletes + * @param bool $notrigger false=launch triggers after, true=disable triggers + * @return int <0 if KO, >0 if OK + */ + public function delete(User $user, $notrigger = false) + { + return $this->deleteCommon($user, $notrigger); + //return $this->deleteCommon($user, $notrigger, 1); + } + + /** + * Set draft status + * + * @param User $user Object user that modify + * @param int $notrigger 1=Does not execute triggers, 0=Execute triggers + * @return int <0 if KO, >0 if OK + */ + public function setDraft($user, $notrigger = 0) + { + // Protection + if ($this->status <= self::STATUS_DRAFT) { + return 0; + } + + /*if (! ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && ! empty($user->rights->mymodule->write)) + || (! empty($conf->global->MAIN_USE_ADVANCED_PERMS) && ! empty($user->rights->mymodule->mymodule_advance->validate)))) + { + $this->error='Permission denied'; + return -1; + }*/ + + return $this->setStatusCommon($user, self::STATUS_DRAFT, $notrigger, 'PARTNERSHIPTYPE_UNVALIDATE'); + } + + /** + * Set cancel status + * + * @param User $user Object user that modify + * @param int $notrigger 1=Does not execute triggers, 0=Execute triggers + * @return int <0 if KO, 0=Nothing done, >0 if OK + */ + public function cancel($user, $notrigger = 0) + { + // Protection + if ($this->status != self::STATUS_VALIDATED) { + return 0; + } + + /*if (! ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && ! empty($user->rights->mymodule->write)) + || (! empty($conf->global->MAIN_USE_ADVANCED_PERMS) && ! empty($user->rights->mymodule->mymodule_advance->validate)))) + { + $this->error='Permission denied'; + return -1; + }*/ + + return $this->setStatusCommon($user, self::STATUS_CANCELED, $notrigger, 'PARTNERSHIPTYPE_CANCEL'); + } + + /** + * Set back to validated status + * + * @param User $user Object user that modify + * @param int $notrigger 1=Does not execute triggers, 0=Execute triggers + * @return int <0 if KO, 0=Nothing done, >0 if OK + */ + public function reopen($user, $notrigger = 0) + { + // Protection + if ($this->status != self::STATUS_CANCELED) { + return 0; + } + + /*if (! ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && ! empty($user->rights->mymodule->write)) + || (! empty($conf->global->MAIN_USE_ADVANCED_PERMS) && ! empty($user->rights->mymodule->mymodule_advance->validate)))) + { + $this->error='Permission denied'; + return -1; + }*/ + + return $this->setStatusCommon($user, self::STATUS_VALIDATED, $notrigger, 'PARTNERSHIPTYPE_REOPEN'); + } + + /** + * Return a link to the object card (with optionaly the picto) + * + * @param int $withpicto Include picto in link (0=No picto, 1=Include picto into link, 2=Only picto) + * @param string $option On what the link point to ('nolink', ...) + * @param int $notooltip 1=Disable tooltip + * @param string $morecss Add more css on link + * @param int $save_lastsearch_value -1=Auto, 0=No save of lastsearch_values when clicking, 1=Save lastsearch_values whenclicking + * @return string String with URL + */ + public function getNomUrl($withpicto = 0, $option = '', $notooltip = 0, $morecss = '', $save_lastsearch_value = -1) + { + global $conf, $langs, $hookmanager; + + if (!empty($conf->dol_no_mouse_hover)) { + $notooltip = 1; // Force disable tooltips + } + + $result = ''; + + $label = img_picto('', $this->picto).' '.$langs->trans("PartnershipType").''; + if (isset($this->status)) { + $label .= ' '.$this->getLibStatut(5); + } + $label .= '
    '; + $label .= ''.$langs->trans('Code').': '.$this->code; + $label .= '
    '.$langs->trans('Label').': '.$this->label; + + //$url = dol_buildpath('/partnership/partnership_card.php', 1).'?id='.$this->id; + $url = ''; + + if ($option != 'nolink') { + // Add param to save lastsearch_values or not + $add_save_lastsearch_values = ($save_lastsearch_value == 1 ? 1 : 0); + if ($save_lastsearch_value == -1 && preg_match('/list\.php/', $_SERVER["PHP_SELF"])) { + $add_save_lastsearch_values = 1; + } + if ($url && $add_save_lastsearch_values) { + $url .= '&save_lastsearch_values=1'; + } + } + + $linkclose = ''; + if (empty($notooltip)) { + if (!empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER)) { + $label = $langs->trans("ShowMyObject"); + $linkclose .= ' alt="'.dol_escape_htmltag($label, 1).'"'; + } + $linkclose .= ' title="'.dol_escape_htmltag($label, 1).'"'; + $linkclose .= ' class="classfortooltip'.($morecss ? ' '.$morecss : '').'"'; + } else { + $linkclose = ($morecss ? ' class="'.$morecss.'"' : ''); + } + + if ($option == 'nolink' || empty($url)) { + $linkstart = ''; + if ($option == 'nolink' || empty($url)) { + $linkend = ''; + } else { + $linkend = ''; + } + + $result .= $linkstart; + + if (empty($this->showphoto_on_popup)) { + if ($withpicto) { + $result .= img_object(($notooltip ? '' : $label), ($this->picto ? $this->picto : 'generic'), ($notooltip ? (($withpicto != 2) ? 'class="paddingright"' : '') : 'class="'.(($withpicto != 2) ? 'paddingright ' : '').'classfortooltip"'), 0, 0, $notooltip ? 0 : 1); + } + } else { + if ($withpicto) { + require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; + + list($class, $module) = explode('@', $this->picto); + $upload_dir = $conf->$module->multidir_output[$conf->entity]."/$class/".dol_sanitizeFileName($this->ref); + $filearray = dol_dir_list($upload_dir, "files"); + $filename = $filearray[0]['name']; + if (!empty($filename)) { + $pospoint = strpos($filearray[0]['name'], '.'); + + $pathtophoto = $class.'/'.$this->ref.'/thumbs/'.substr($filename, 0, $pospoint).'_mini'.substr($filename, $pospoint); + if (empty($conf->global->{strtoupper($module.'_'.$class).'_FORMATLISTPHOTOSASUSERS'})) { + $result .= '
    No photo
    '; + } else { + $result .= '
    No photo
    '; + } + + $result .= ''; + } else { + $result .= img_object(($notooltip ? '' : $label), ($this->picto ? $this->picto : 'generic'), ($notooltip ? (($withpicto != 2) ? 'class="paddingright"' : '') : 'class="'.(($withpicto != 2) ? 'paddingright ' : '').'classfortooltip"'), 0, 0, $notooltip ? 0 : 1); + } + } + } + + if ($withpicto != 2) { + $result .= $this->ref; + } + + $result .= $linkend; + //if ($withpicto != 2) $result.=(($addlabel && $this->label) ? $sep . dol_trunc($this->label, ($addlabel > 1 ? $addlabel : 0)) : ''); + + global $action, $hookmanager; + $hookmanager->initHooks(array('myobjectdao')); + $parameters = array('id'=>$this->id, 'getnomurl' => &$result); + $reshook = $hookmanager->executeHooks('getNomUrl', $parameters, $this, $action); // Note that $action and $object may have been modified by some hooks + if ($reshook > 0) { + $result = $hookmanager->resPrint; + } else { + $result .= $hookmanager->resPrint; + } + + return $result; + } + + /** + * Return the label of the status + * + * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto + * @return string Label of status + */ + public function getLabelStatus($mode = 0) + { + return $this->LibStatut($this->status, $mode); + } + + /** + * Return the label of the status + * + * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto + * @return string Label of status + */ + public function getLibStatut($mode = 0) + { + return $this->LibStatut($this->status, $mode); + } + + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps + /** + * Return the status + * + * @param int $status Id status + * @param int $mode 0=long label, 1=short label, 2=Picto + short label, 3=Picto, 4=Picto + long label, 5=Short label + Picto, 6=Long label + Picto + * @return string Label of status + */ + public function LibStatut($status, $mode = 0) + { + // phpcs:enable + if (empty($this->labelStatus) || empty($this->labelStatusShort)) { + global $langs; + //$langs->load("mymodule@mymodule"); + $this->labelStatus[self::STATUS_DRAFT] = $langs->transnoentitiesnoconv('Draft'); + $this->labelStatus[self::STATUS_VALIDATED] = $langs->transnoentitiesnoconv('Enabled'); + $this->labelStatus[self::STATUS_CANCELED] = $langs->transnoentitiesnoconv('Disabled'); + $this->labelStatusShort[self::STATUS_DRAFT] = $langs->transnoentitiesnoconv('Draft'); + $this->labelStatusShort[self::STATUS_VALIDATED] = $langs->transnoentitiesnoconv('Enabled'); + $this->labelStatusShort[self::STATUS_CANCELED] = $langs->transnoentitiesnoconv('Disabled'); + } + + $statusType = 'status'.$status; + //if ($status == self::STATUS_VALIDATED) $statusType = 'status1'; + if ($status == self::STATUS_CANCELED) { + $statusType = 'status6'; + } + + return dolGetStatus($this->labelStatus[$status], $this->labelStatusShort[$status], '', $statusType, $mode); + } + + /** + * Load the info information in the object + * + * @param int $id Id of object + * @return void + */ + public function info($id) + { + $sql = "SELECT rowid, date_creation as datec, tms as datem,"; + $sql .= " fk_user_creat, fk_user_modif"; + $sql .= " FROM ".MAIN_DB_PREFIX.$this->table_element." as t"; + $sql .= " WHERE t.rowid = ".((int) $id); + + $result = $this->db->query($sql); + if ($result) { + if ($this->db->num_rows($result)) { + $obj = $this->db->fetch_object($result); + $this->id = $obj->rowid; + if ($obj->fk_user_author) { + $cuser = new User($this->db); + $cuser->fetch($obj->fk_user_author); + $this->user_creation = $cuser; + } + + if ($obj->fk_user_valid) { + $vuser = new User($this->db); + $vuser->fetch($obj->fk_user_valid); + $this->user_validation = $vuser; + } + + if ($obj->fk_user_cloture) { + $cluser = new User($this->db); + $cluser->fetch($obj->fk_user_cloture); + $this->user_cloture = $cluser; + } + + $this->date_creation = $this->db->jdate($obj->datec); + $this->date_modification = $this->db->jdate($obj->datem); + $this->date_validation = $this->db->jdate($obj->datev); + } + + $this->db->free($result); + } else { + dol_print_error($this->db); + } + } + + /** + * Initialise object with example values + * Id must be 0 if object instance is a specimen + * + * @return void + */ + public function initAsSpecimen() + { + // Set here init that are not commonf fields + // $this->property1 = ... + // $this->property2 = ... + + $this->initAsSpecimenCommon(); + } +} diff --git a/htdocs/partnership/class/partnershiputils.class.php b/htdocs/partnership/class/partnershiputils.class.php index 0588b9e5df2..ef4f7cfdeb4 100644 --- a/htdocs/partnership/class/partnershiputils.class.php +++ b/htdocs/partnership/class/partnershiputils.class.php @@ -64,7 +64,7 @@ class PartnershipUtils { global $conf, $langs, $user; - $managedfor = $conf->global->PARTNERSHIP_IS_MANAGED_FOR; + $managedfor = empty($conf->global->PARTNERSHIP_IS_MANAGED_FOR) ? 'thirdparty' : $conf->global->PARTNERSHIP_IS_MANAGED_FOR; if ($managedfor != 'member') { return 0; // If option 'PARTNERSHIP_IS_MANAGED_FOR' = 'thirdparty', this cron job does nothing. @@ -101,7 +101,7 @@ class PartnershipUtils $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."adherent_type as dty on (dty.rowid = d.fk_adherent_type)"; $sql .= " WHERE fk_member > 0"; $sql .= " AND (d.datefin < '".$this->db->idate($datetotest)."' AND dty.subscription = 1)"; - $sql .= " AND p.status = ".((int) $partnership::STATUS_ACCEPTED); // Only accepted not yet canceled + $sql .= " AND p.status = ".((int) $partnership::STATUS_APPROVED); // Only accepted not yet canceled $sql .= $this->db->order('d.rowid', 'ASC'); // Limit is managed into loop later @@ -262,7 +262,7 @@ class PartnershipUtils $sql .= " WHERE 1 = 1"; $sql .= " AND p.".$fk_partner." > 0"; - $sql .= " AND p.status = ".((int) $partnership::STATUS_ACCEPTED); // Only accepted not yet canceled + $sql .= " AND p.status = ".((int) $partnership::STATUS_APPROVED); // Only accepted not yet canceled $sql .= " AND (p.last_check_backlink IS NULL OR p.last_check_backlink <= '".$this->db->idate($now - 7 * 24 * 3600)."')"; // Every week, check that website contains a link to dolibarr. $sql .= $this->db->order('p.rowid', 'ASC'); // Limit is managed into loop later diff --git a/htdocs/partnership/core/modules/partnership/mod_partnership_standard.php b/htdocs/partnership/core/modules/partnership/mod_partnership_standard.php index fefcafa2350..d5a2bb326b2 100644 --- a/htdocs/partnership/core/modules/partnership/mod_partnership_standard.php +++ b/htdocs/partnership/core/modules/partnership/mod_partnership_standard.php @@ -36,7 +36,7 @@ class mod_partnership_standard extends ModeleNumRefPartnership */ public $version = 'dolibarr'; // 'development', 'experimental', 'dolibarr' - public $prefix = 'PARTNERSHIP'; + public $prefix = 'PSHIP'; /** * @var string Error code (or message) diff --git a/htdocs/partnership/lib/partnership.lib.php b/htdocs/partnership/lib/partnership.lib.php index 23b5a2901fb..cfc54ce3134 100644 --- a/htdocs/partnership/lib/partnership.lib.php +++ b/htdocs/partnership/lib/partnership.lib.php @@ -121,10 +121,10 @@ function partnershipPrepareHead($object) $head[$h][2] = 'document'; $h++; - // $head[$h][0] = dol_buildpath("/partnership/partnership_agenda.php", 1).'?id='.$object->id; - // $head[$h][1] = $langs->trans("Events"); - // $head[$h][2] = 'agenda'; - // $h++; + $head[$h][0] = dol_buildpath("/partnership/partnership_agenda.php", 1).'?id='.$object->id; + $head[$h][1] = $langs->trans("Events"); + $head[$h][2] = 'agenda'; + $h++; // Show more tabs from modules // Entries must be declared in modules descriptor with line diff --git a/htdocs/partnership/partnership_agenda.php b/htdocs/partnership/partnership_agenda.php index f154e1b9f5b..4c68a83d4e2 100644 --- a/htdocs/partnership/partnership_agenda.php +++ b/htdocs/partnership/partnership_agenda.php @@ -53,8 +53,8 @@ if (GETPOST('actioncode', 'array')) { $search_agenda_label = GETPOST('search_agenda_label'); $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/partnership/partnership_card.php b/htdocs/partnership/partnership_card.php index 99cdb74e264..c83a83e6357 100644 --- a/htdocs/partnership/partnership_card.php +++ b/htdocs/partnership/partnership_card.php @@ -79,13 +79,14 @@ $permissiontodelete = $user->rights->partnership->delete || ($permissiontoadd & $permissionnote = $user->rights->partnership->write; // Used by the include of actions_setnotes.inc.php $permissiondellink = $user->rights->partnership->write; // Used by the include of actions_dellink.inc.php $upload_dir = $conf->partnership->multidir_output[isset($object->entity) ? $object->entity : 1]; -$managedfor = $conf->global->PARTNERSHIP_IS_MANAGED_FOR; +$managedfor = empty($conf->global->PARTNERSHIP_IS_MANAGED_FOR) ? 'thirdparty' : $conf->global->PARTNERSHIP_IS_MANAGED_FOR; if (empty($conf->partnership->enabled)) accessforbidden(); if (empty($permissiontoread)) accessforbidden(); if ($object->id > 0 && $object->fk_member > 0 && $managedfor != 'member') accessforbidden(); if ($object->id > 0 && $object->fk_soc > 0 && $managedfor != 'thirdparty') accessforbidden(); + /* * Actions */ @@ -153,7 +154,7 @@ if (empty($reshook)) { setEventMessages($object->error, $object->errors, 'errors'); } } elseif ($action == 'confirm_accept' && $confirm == 'yes' && $permissiontoadd) { - $result = $object->accept($user); + $result = $object->approve($user); if ($result >= 0) { // Define output language if (empty($conf->global->MAIN_DISABLE_PDF_AUTOUPDATE)) { @@ -232,7 +233,7 @@ if (empty($reshook)) { // Actions to send emails $triggersendname = 'PARTNERSHIP_SENTBYMAIL'; $autocopy = 'MAIN_MAIL_AUTOCOPY_PARTNERSHIP_TO'; - $trackid = 'partnership'.$object->id; + $trackid = 'pship'.$object->id; include DOL_DOCUMENT_ROOT.'/core/actions_sendmails.inc.php'; if (!empty($id) && !empty(GETPOST('confirm'))) { @@ -273,9 +274,6 @@ if ($action == 'create') { print dol_get_fiche_head(array(), ''); - // Set some default values - //if (! GETPOSTISSET('fieldname')) $_POST['fieldname'] = 'myvalue'; - print ''."\n"; // Common attributes @@ -581,7 +579,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea // Approve if ($object->status == $object::STATUS_VALIDATED) { if (empty($object->table_element_line) || (is_array($object->lines) && count($object->lines) > 0)) { - print dolGetButtonAction($langs->trans('Approved'), '', 'default', $_SERVER['PHP_SELF'].'?id='.$object->id.'&action=confirm_accept&confirm=yes&token='.newToken(), '', $permissiontoadd); + print dolGetButtonAction($langs->trans('Approve'), '', 'default', $_SERVER['PHP_SELF'].'?id='.$object->id.'&action=confirm_accept&confirm=yes&token='.newToken(), '', $permissiontoadd); } else { $langs->load("errors"); print dolGetButtonAction($langs->trans("ErrorAddAtLeastOneLineFirst"), $langs->trans("Approved"), 'default', '#', '', 0); @@ -590,9 +588,9 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea // Cancel if ($permissiontoadd) { - if ($object->status == $object::STATUS_ACCEPTED) { - print dolGetButtonAction($langs->trans('Cancel'), '', 'default', $_SERVER["PHP_SELF"].'?id='.$object->id.'&action=close&token='.newToken(), '', $permissiontoadd); - } elseif ($object->status > $object::STATUS_ACCEPTED) { + if ($object->status == $object::STATUS_APPROVED) { + print dolGetButtonAction($langs->trans('Resiliate'), '', 'default', $_SERVER["PHP_SELF"].'?id='.$object->id.'&action=close&token='.newToken(), '', $permissiontoadd); + } elseif ($object->status > $object::STATUS_APPROVED) { // print ''.$langs->trans("Re-Open").''."\n"; print dolGetButtonAction($langs->trans('Re-Open'), '', 'default', $_SERVER["PHP_SELF"].'?id='.$object->id.'&action=confirm_reopen&confirm=yes&token='.newToken(), '', $permissiontoadd); } @@ -600,7 +598,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea // Refuse if ($permissiontoadd) { - if ($object->status != $object::STATUS_DRAFT && $object->status != $object::STATUS_ACCEPTED && $object->status != $object::STATUS_CANCELED && $object->status != $object::STATUS_REFUSED) { + if ($object->status != $object::STATUS_DRAFT && $object->status != $object::STATUS_APPROVED && $object->status != $object::STATUS_CANCELED && $object->status != $object::STATUS_REFUSED) { print dolGetButtonAction($langs->trans('Refuse'), '', 'default', $_SERVER['PHP_SELF'].'?id='.$object->id.'&action=refuse&token='.newToken(), '', $permissiontoadd); } } @@ -643,14 +641,12 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea $MAXEVENT = 10; - $morehtmlright = ''; - $morehtmlright .= $langs->trans("SeeAll"); - $morehtmlright .= ''; + $morehtmlcenter = dolGetButtonTitle($langs->trans('SeeAll'), '', 'fa fa-list-alt imgforviewmode', DOL_URL_ROOT.'/partnership/partnership_agenda.php?id='.$object->id); // List of actions on element include_once DOL_DOCUMENT_ROOT.'/core/class/html.formactions.class.php'; $formactions = new FormActions($db); - $somethingshown = $formactions->showactions($object, $object->element, (is_object($object->thirdparty) ? $object->thirdparty->id : 0), 1, '', $MAXEVENT, '', $morehtmlright); + $somethingshown = $formactions->showactions($object, $object->element, (is_object($object->thirdparty) ? $object->thirdparty->id : 0), 1, '', $MAXEVENT, '', $morehtmlcenter); print ''; } @@ -664,7 +660,7 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea $modelmail = 'partnership_send'; $defaulttopic = 'InformationMessage'; $diroutput = $conf->partnership->dir_output; - $trackid = 'partnership'.$object->id; + $trackid = 'pship'.$object->id; include DOL_DOCUMENT_ROOT.'/core/tpl/card_presend.tpl.php'; } diff --git a/htdocs/partnership/partnership_document.php b/htdocs/partnership/partnership_document.php index 79b7be0057a..f96eb6e58ec 100644 --- a/htdocs/partnership/partnership_document.php +++ b/htdocs/partnership/partnership_document.php @@ -43,8 +43,8 @@ $ref = GETPOST('ref', 'alpha'); // Get parameters $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/partnership/partnership_list.php b/htdocs/partnership/partnership_list.php index a5c52609d74..dc9958fa3df 100644 --- a/htdocs/partnership/partnership_list.php +++ b/htdocs/partnership/partnership_list.php @@ -29,8 +29,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/html.formcompany.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php'; require_once DOL_DOCUMENT_ROOT.'/adherents/class/adherent.class.php'; - -// load partnership libraries require_once DOL_DOCUMENT_ROOT.'/partnership/class/partnership.class.php'; // for other modules @@ -76,7 +74,7 @@ $extrafields->fetch_name_optionals_label($object->table_element); $search_array_options = $extrafields->getOptionalsFromPost($object->table_element, '', 'search_'); -$managedfor = $conf->global->PARTNERSHIP_IS_MANAGED_FOR; +$managedfor = empty($conf->global->PARTNERSHIP_IS_MANAGED_FOR) ? 'thirdparty' : $conf->global->PARTNERSHIP_IS_MANAGED_FOR; if ($managedfor != 'member' && $sortfield == 'd.datefin') $sortfield = ''; @@ -120,11 +118,11 @@ $arrayfields = array(); foreach ($object->fields as $key => $val) { // If $val['visible']==0, then we never show the field if (!empty($val['visible'])) { - $visible = (int) dol_eval($val['visible'], 1); + $visible = (int) dol_eval($val['visible'], 1, 1, '1'); $arrayfields['t.'.$key] = array( 'label'=>$val['label'], 'checked'=>(($visible < 0) ? 0 : 1), - 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1)), + 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1, 1, '1')), 'position'=>$val['position'], 'help'=> isset($val['help']) ? $val['help'] : '' ); @@ -158,6 +156,8 @@ if ($user->socid > 0) { // Protection if external user * Actions */ +$error = 0; + if (GETPOST('cancel', 'alpha')) { $action = 'list'; $massaction = ''; @@ -200,6 +200,43 @@ if (empty($reshook)) { $uploaddir = $conf->partnership->dir_output; include DOL_DOCUMENT_ROOT.'/core/actions_massactions.inc.php'; + // Validate and approve + if (!$error && $massaction == 'approve' && $permissiontoadd) { + $objecttmp = new Partnership($db); + + $db->begin(); + $error = 0; + $result = 0; + + foreach ($toselect as $checked) { + if ($objecttmp->fetch($checked)) { + if ($objecttmp->status == $objecttmp::STATUS_DRAFT) { + //$objecttmp->date = dol_now(); + $result = $objecttmp->validate($user); + } + + if ($result >= 0 && $objecttmp->status == $objecttmp::STATUS_VALIDATED) { + $result = $objecttmp->approve($user); + if ($result > 0) { + setEventMessages($langs->trans("PartnershipRefApproved", $objecttmp->ref), null); + } else { + setEventMessages($objecttmp->error, $objecttmp->errors, 'errors'); + $error++; + } + } else { + setEventMessages($objecttmp->error, $objecttmp->errors, 'errors'); + $error++; + } + } + } + + if (!$error) { + $db->commit(); + } else { + $db->rollback(); + } + } + // Cancel partnership if ($massaction == 'cancel' && $permissiontoadd) { $db->begin(); @@ -208,9 +245,14 @@ if (empty($reshook)) { $nbok = 0; foreach ($toselect as $toselectid) { $result = $objecttmp->fetch($toselectid); + var_dump($objecttmp->status); if ($result > 0) { - $result = $objecttmp->cancel($user, 3); - if ($result <= 0) { + $result = $objecttmp->cancel($user, 0); + var_dump($result); + if ($result == 0) { + setEventMessages($langs->trans('StatusOfRefMustBe', $objecttmp->ref, $objecttmp->LibStatut($objecttmp::STATUS_APPROVED)), null, 'warnings'); + $error++; + } elseif ($result <= 0) { setEventMessages($objecttmp->error, $objecttmp->errors, 'errors'); $error++; break; @@ -432,7 +474,9 @@ $param .= $hookmanager->resPrint; // List of mass actions available $arrayofmassactions = array( -'cancel'=>img_picto('', 'close_title', 'class="pictofixedwidth"').$langs->trans("Cancel"), + //'validate'=>img_picto('', 'check', 'class="pictofixedwidth"').$langs->trans("Validate"), + 'approve'=>img_picto('', 'check', 'class="pictofixedwidth"').$langs->trans("ValidateAndApprove"), + 'cancel'=>img_picto('', 'close_title', 'class="pictofixedwidth"').$langs->trans("Cancel"), //'generate_doc'=>img_picto('', 'pdf').$langs->trans("ReGeneratePDF"), //'builddoc'=>img_picto('', 'pdf').$langs->trans("PDFMerge"), 'presend'=>img_picto('', 'email', 'class="pictofixedwidth"').$langs->trans("SendMail"), @@ -440,7 +484,7 @@ $arrayofmassactions = array( if ($permissiontodelete) { $arrayofmassactions['predelete'] = img_picto('', 'delete', 'class="pictofixedwidth"').$langs->trans("Delete"); } -if (GETPOST('nomassaction', 'int') || in_array($massaction, array('presend', 'predelete'))) { +if (GETPOST('nomassaction', 'int') || in_array($massaction, array('prevalidate', 'presend', 'predelete'))) { $arrayofmassactions = array(); } $massactionbutton = $form->selectMassAction('', $arrayofmassactions); @@ -464,7 +508,7 @@ print_barre_liste($title, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sort $topicmail = "SendPartnershipRef"; $modelmail = "partnership_send"; $objecttmp = new Partnership($db); -$trackid = 'partnership'.$object->id; +$trackid = 'pship'.$object->id; include DOL_DOCUMENT_ROOT.'/core/tpl/massactions_pre.tpl.php'; if ($search_all) { diff --git a/htdocs/paybox/admin/paybox.php b/htdocs/paybox/admin/paybox.php index bcad50de457..60426e6a3b0 100644 --- a/htdocs/paybox/admin/paybox.php +++ b/htdocs/paybox/admin/paybox.php @@ -30,7 +30,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php'; $servicename = 'PayBox'; // Load translation files required by the page -$langs->loadLangs(array('admin', 'other', 'paybox', 'paypal')); +$langs->loadLangs(array('admin', 'other', 'paybox', 'paypal', 'stripe')); if (!$user->admin) { accessforbidden(); @@ -261,7 +261,7 @@ $doleditor->Create(); print ''; -print ''; } if (empty($conf->global->PRODUCT_DISABLE_SIZE)) { // Brut Length print ''; } if (empty($conf->global->PRODUCT_DISABLE_SURFACE)) { // Brut Surface print ''; } if (empty($conf->global->PRODUCT_DISABLE_VOLUME)) { // Brut Volume print ''; } if (!empty($conf->global->PRODUCT_ADD_NET_MEASURE)) { // Net Measure print ''; } } @@ -2178,8 +2178,8 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($action)) { print ''; - if ((($object->status_batch == '1' && $conf->global->PRODUCTBATCH_LOT_USE_PRODUCT_MASKS && $conf->global->PRODUCTBATCH_LOT_ADDON == 'mod_lot_advanced') - || ($object->status_batch == '2' && $conf->global->PRODUCTBATCH_SN_ADDON == 'mod_sn_advanced' && $conf->global->PRODUCTBATCH_SN_USE_PRODUCT_MASKS))) { + if ((($object->status_batch == '1' && !empty($conf->global->PRODUCTBATCH_LOT_USE_PRODUCT_MASKS) && $conf->global->PRODUCTBATCH_LOT_ADDON == 'mod_lot_advanced') + || ($object->status_batch == '2' && $conf->global->PRODUCTBATCH_SN_ADDON == 'mod_sn_advanced' && !empty($conf->global->PRODUCTBATCH_SN_USE_PRODUCT_MASKS)))) { print ''; @@ -2689,7 +2689,6 @@ if ($action != 'create' && $action != 'edit' && $action != 'delete') { // Documents $objectref = dol_sanitizeFileName($object->ref); - $relativepath = $comref.'/'.$objectref.'.pdf'; if (!empty($conf->product->multidir_output[$object->entity])) { $filedir = $conf->product->multidir_output[$object->entity].'/'.$objectref; //Check repertories of current entities } else { @@ -2699,21 +2698,19 @@ if ($action != 'create' && $action != 'edit' && $action != 'delete') { $genallowed = $usercanread; $delallowed = $usercancreate; - print $formfile->showdocuments($modulepart, $object->ref, $filedir, $urlsource, $genallowed, $delallowed, '', 0, 0, 0, 28, 0, '', 0, '', $object->default_lang, '', $object); + print $formfile->showdocuments($modulepart, $object->ref, $filedir, $urlsource, $genallowed, $delallowed, '', 0, 0, 0, 28, 0, '', 0, '', $langs->getDefaultLang(), '', $object); $somethingshown = $formfile->numoffiles; print '
    '; $MAXEVENT = 10; - $morehtmlright = ''; - $morehtmlright .= $langs->trans("SeeAll"); - $morehtmlright .= ''; + $morehtmlcenter = dolGetButtonTitle($langs->trans('SeeAll'), '', 'fa fa-list-alt imgforviewmode', DOL_URL_ROOT.'/product/agenda.php?id='.$object->id); // List of actions on element include_once DOL_DOCUMENT_ROOT.'/core/class/html.formactions.class.php'; $formactions = new FormActions($db); - $somethingshown = $formactions->showactions($object, 'product', 0, 1, '', $MAXEVENT, '', $morehtmlright); // Show all action for product + $somethingshown = $formactions->showactions($object, 'product', 0, 1, '', $MAXEVENT, '', $morehtmlcenter); // Show all action for product print '
    '; } diff --git a/htdocs/product/class/api_products.class.php b/htdocs/product/class/api_products.class.php index 6283b692a28..d42a8c00759 100644 --- a/htdocs/product/class/api_products.class.php +++ b/htdocs/product/class/api_products.class.php @@ -172,9 +172,10 @@ class Products extends DolibarrApi * @param bool $ids_only Return only IDs of product instead of all properties (faster, above all if list is long) * @param int $variant_filter Use this param to filter list (0 = all, 1=products without variants, 2=parent of variants, 3=variants only) * @param bool $pagination_data If this parameter is set to true the response will include pagination data. Default value is false. Page starts from 0 + * @param int $includestockdata Load also information about stock (slower) * @return array Array of product objects */ - public function index($sortfield = "t.ref", $sortorder = 'ASC', $limit = 100, $page = 0, $mode = 0, $category = 0, $sqlfilters = '', $ids_only = false, $variant_filter = 0, $pagination_data = false) + public function index($sortfield = "t.ref", $sortorder = 'ASC', $limit = 100, $page = 0, $mode = 0, $category = 0, $sqlfilters = '', $ids_only = false, $variant_filter = 0, $pagination_data = false, $includestockdata = 0) { global $db, $conf; @@ -187,21 +188,21 @@ class Products extends DolibarrApi $socid = DolibarrApiAccess::$user->socid ? DolibarrApiAccess::$user->socid : ''; $sql = "SELECT t.rowid, t.ref, t.ref_ext"; - $sql .= " FROM ".MAIN_DB_PREFIX."product as t"; + $sql .= " FROM ".$this->db->prefix()."product as t"; if ($category > 0) { - $sql .= ", ".MAIN_DB_PREFIX."categorie_product as c"; + $sql .= ", ".$this->db->prefix()."categorie_product as c"; } $sql .= ' WHERE t.entity IN ('.getEntity('product').')'; if ($variant_filter == 1) { - $sql .= ' AND t.rowid not in (select distinct fk_product_parent from '.MAIN_DB_PREFIX.'product_attribute_combination)'; - $sql .= ' AND t.rowid not in (select distinct fk_product_child from '.MAIN_DB_PREFIX.'product_attribute_combination)'; + $sql .= ' AND t.rowid not in (select distinct fk_product_parent from '.$this->db->prefix().'product_attribute_combination)'; + $sql .= ' AND t.rowid not in (select distinct fk_product_child from '.$this->db->prefix().'product_attribute_combination)'; } if ($variant_filter == 2) { - $sql .= ' AND t.rowid in (select distinct fk_product_parent from '.MAIN_DB_PREFIX.'product_attribute_combination)'; + $sql .= ' AND t.rowid in (select distinct fk_product_parent from '.$this->db->prefix().'product_attribute_combination)'; } if ($variant_filter == 3) { - $sql .= ' AND t.rowid in (select distinct fk_product_child from '.MAIN_DB_PREFIX.'product_attribute_combination)'; + $sql .= ' AND t.rowid in (select distinct fk_product_child from '.$this->db->prefix().'product_attribute_combination)'; } // Select products of given category @@ -218,8 +219,9 @@ class Products extends DolibarrApi } // Add sql filters if ($sqlfilters) { - if (!DolibarrApi::_checkFilters($sqlfilters)) { - throw new RestException(503, 'Error when validating parameter sqlfilters '.$sqlfilters); + $errormessage = ''; + if (!DolibarrApi::_checkFilters($sqlfilters, $errormessage)) { + throw new RestException(503, 'Error when validating parameter sqlfilters -> '.$errormessage); } //var_dump($sqlfilters);exit; $regexstring = '\(([^:\'\(\)]+:[^:\'\(\)]+:[^\(\)]+)\)'; // We must accept datc:<:2020-01-01 10:10:10 @@ -249,6 +251,21 @@ class Products extends DolibarrApi if (!$ids_only) { $product_static = new Product($this->db); if ($product_static->fetch($obj->rowid)) { + if ($includestockdata && DolibarrApiAccess::$user->rights->stock->lire) { + $product_static->load_stock(); + + if (is_array($product_static->stock_warehouse)) { + foreach ($product_static->stock_warehouse as $keytmp => $valtmp) { + if (is_array($product_static->stock_warehouse[$keytmp]->detail_batch)) { + foreach ($product_static->stock_warehouse[$keytmp]->detail_batch as $keytmp2 => $valtmp2) { + unset($product_static->stock_warehouse[$keytmp]->detail_batch[$keytmp2]->db); + } + } + } + } + } + + $obj_ret[] = $this->_cleanObjectDatas($product_static); } } else { @@ -462,7 +479,7 @@ class Products extends DolibarrApi $childsArbo = $this->product->getChildsArbo($id, 1); - $keys = array('rowid', 'qty', 'fk_product_type', 'label', 'incdec', 'ref'); + $keys = array('rowid', 'qty', 'fk_product_type', 'label', 'incdec', 'ref', 'fk_association', 'rang'); $childs = array(); foreach ($childsArbo as $values) { $childs[] = array_combine($keys, $values); @@ -844,11 +861,11 @@ class Products extends DolibarrApi } $sql = "SELECT t.rowid, t.ref, t.ref_ext"; - $sql .= " FROM ".MAIN_DB_PREFIX."product as t"; + $sql .= " FROM ".$this->db->prefix()."product as t"; if ($category > 0) { - $sql .= ", ".MAIN_DB_PREFIX."categorie_product as c"; + $sql .= ", ".$this->db->prefix()."categorie_product as c"; } - $sql .= ", ".MAIN_DB_PREFIX."product_fournisseur_price as s"; + $sql .= ", ".$this->db->prefix()."product_fournisseur_price as s"; $sql .= ' WHERE t.entity IN ('.getEntity('product').')'; @@ -873,8 +890,9 @@ class Products extends DolibarrApi } // Add sql filters if ($sqlfilters) { - if (!DolibarrApi::_checkFilters($sqlfilters)) { - throw new RestException(503, 'Error when validating parameter sqlfilters '.$sqlfilters); + $errormessage = ''; + if (!DolibarrApi::_checkFilters($sqlfilters, $errormessage)) { + throw new RestException(503, 'Error when validating parameter sqlfilters -> '.$errormessage); } $regexstring = '\(([^:\'\(\)]+:[^:\'\(\)]+:[^\(\)]+)\)'; $sql .= " AND (".preg_replace_callback('/'.$regexstring.'/', 'DolibarrApi::_forge_criteria_callback', $sqlfilters).")"; @@ -995,13 +1013,14 @@ class Products extends DolibarrApi } $sql = "SELECT t.rowid, t.ref, t.ref_ext, t.label, t.rang, t.entity"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_attribute as t"; + $sql .= " FROM ".$this->db->prefix()."product_attribute as t"; $sql .= ' WHERE t.entity IN ('.getEntity('product').')'; // Add sql filters if ($sqlfilters) { - if (!DolibarrApi::_checkFilters($sqlfilters)) { - throw new RestException(503, 'Error when validating parameter sqlfilters '.$sqlfilters); + $errormessage = ''; + if (!DolibarrApi::_checkFilters($sqlfilters, $errormessage)) { + throw new RestException(503, 'Error when validating parameter sqlfilters -> '.$errormessage); } $regexstring = '\(([^:\'\(\)]+:[^:\'\(\)]+:[^\(\)]+)\)'; $sql .= " AND (".preg_replace_callback('/'.$regexstring.'/', 'DolibarrApi::_forge_criteria_callback', $sqlfilters).")"; @@ -1075,8 +1094,8 @@ class Products extends DolibarrApi } } - $sql = "SELECT COUNT(*) as nb FROM ".MAIN_DB_PREFIX."product_attribute_combination2val as pac2v"; - $sql .= " JOIN ".MAIN_DB_PREFIX."product_attribute_combination as pac ON pac2v.fk_prod_combination = pac.rowid"; + $sql = "SELECT COUNT(*) as nb FROM ".$this->db->prefix()."product_attribute_combination2val as pac2v"; + $sql .= " JOIN ".$this->db->prefix()."product_attribute_combination as pac ON pac2v.fk_prod_combination = pac.rowid"; $sql .= " WHERE pac2v.fk_prod_attr = ".((int) $prodattr->id)." AND pac.entity IN (".getEntity('product').")"; $resql = $this->db->query($sql); @@ -1103,7 +1122,7 @@ class Products extends DolibarrApi throw new RestException(401); } - $sql = "SELECT rowid, ref, ref_ext, label, rang, entity FROM ".MAIN_DB_PREFIX."product_attribute WHERE ref LIKE '".trim($ref)."' AND entity IN (".getEntity('product').")"; + $sql = "SELECT rowid, ref, ref_ext, label, rang, entity FROM ".$this->db->prefix()."product_attribute WHERE ref LIKE '".trim($ref)."' AND entity IN (".getEntity('product').")"; $query = $this->db->query($sql); @@ -1121,8 +1140,8 @@ class Products extends DolibarrApi $attr['rang'] = $result->rang; $attr['entity'] = $result->entity; - $sql = "SELECT COUNT(*) as nb FROM ".MAIN_DB_PREFIX."product_attribute_combination2val as pac2v"; - $sql .= " JOIN ".MAIN_DB_PREFIX."product_attribute_combination as pac ON pac2v.fk_prod_combination = pac.rowid"; + $sql = "SELECT COUNT(*) as nb FROM ".$this->db->prefix()."product_attribute_combination2val as pac2v"; + $sql .= " JOIN ".$this->db->prefix()."product_attribute_combination as pac ON pac2v.fk_prod_combination = pac.rowid"; $sql .= " WHERE pac2v.fk_prod_attr = ".((int) $result->rowid)." AND pac.entity IN (".getEntity('product').")"; $resql = $this->db->query($sql); @@ -1150,7 +1169,7 @@ class Products extends DolibarrApi throw new RestException(401); } - $sql = "SELECT rowid, ref, ref_ext, label, rang, entity FROM ".MAIN_DB_PREFIX."product_attribute WHERE ref_ext LIKE '".trim($ref_ext)."' AND entity IN (".getEntity('product').")"; + $sql = "SELECT rowid, ref, ref_ext, label, rang, entity FROM ".$this->db->prefix()."product_attribute WHERE ref_ext LIKE '".trim($ref_ext)."' AND entity IN (".getEntity('product').")"; $query = $this->db->query($sql); @@ -1168,8 +1187,8 @@ class Products extends DolibarrApi $attr['rang'] = $result->rang; $attr['entity'] = $result->entity; - $sql = "SELECT COUNT(*) as nb FROM ".MAIN_DB_PREFIX."product_attribute_combination2val as pac2v"; - $sql .= " JOIN ".MAIN_DB_PREFIX."product_attribute_combination as pac ON pac2v.fk_prod_combination = pac.rowid"; + $sql = "SELECT COUNT(*) as nb FROM ".$this->db->prefix()."product_attribute_combination2val as pac2v"; + $sql .= " JOIN ".$this->db->prefix()."product_attribute_combination as pac ON pac2v.fk_prod_combination = pac.rowid"; $sql .= " WHERE pac2v.fk_prod_attr = ".((int) $result->rowid)." AND pac.entity IN (".getEntity('product').")"; $resql = $this->db->query($sql); @@ -1303,7 +1322,7 @@ class Products extends DolibarrApi throw new RestException(401); } - $sql = "SELECT rowid, fk_product_attribute, ref, value FROM ".MAIN_DB_PREFIX."product_attribute_value WHERE rowid = ".(int) $id." AND entity IN (".getEntity('product').")"; + $sql = "SELECT rowid, fk_product_attribute, ref, value FROM ".$this->db->prefix()."product_attribute_value WHERE rowid = ".(int) $id." AND entity IN (".getEntity('product').")"; $query = $this->db->query($sql); @@ -1346,7 +1365,7 @@ class Products extends DolibarrApi $ref = trim($ref); - $sql = "SELECT rowid, fk_product_attribute, ref, value FROM ".MAIN_DB_PREFIX."product_attribute_value"; + $sql = "SELECT rowid, fk_product_attribute, ref, value FROM ".$this->db->prefix()."product_attribute_value"; $sql .= " WHERE ref LIKE '".$this->db->escape($ref)."' AND fk_product_attribute = ".((int) $id)." AND entity IN (".getEntity('product').")"; $query = $this->db->query($sql); @@ -1389,7 +1408,7 @@ class Products extends DolibarrApi $ref = trim($ref); - $sql = "SELECT rowid FROM ".MAIN_DB_PREFIX."product_attribute_value"; + $sql = "SELECT rowid FROM ".$this->db->prefix()."product_attribute_value"; $sql .= " WHERE ref LIKE '".$this->db->escape($ref)."' AND fk_product_attribute = ".((int) $id)." AND entity IN (".getEntity('product').")"; $query = $this->db->query($sql); @@ -1465,9 +1484,9 @@ class Products extends DolibarrApi $return = array(); - $sql = 'SELECT '; - $sql .= 'v.fk_product_attribute, v.rowid, v.ref, v.value FROM '.MAIN_DB_PREFIX.'product_attribute_value as v'; - $sql .= " WHERE v.fk_product_attribute IN (SELECT rowid FROM ".MAIN_DB_PREFIX."product_attribute WHERE ref LIKE '".$this->db->escape($ref)."')"; + $sql = "SELECT "; + $sql .= "v.fk_product_attribute, v.rowid, v.ref, v.value FROM ".$this->db->prefix()."product_attribute_value as v"; + $sql .= " WHERE v.fk_product_attribute IN (SELECT rowid FROM ".$this->db->prefix()."product_attribute WHERE ref LIKE '".$this->db->escape($ref)."')"; $resql = $this->db->query($sql); @@ -1948,6 +1967,7 @@ class Products extends DolibarrApi if (empty(DolibarrApiAccess::$user->rights->stock->lire)) { unset($object->stock_reel); unset($object->stock_theorique); + unset($object->stock_warehouse); } return $object; @@ -2029,7 +2049,7 @@ class Products extends DolibarrApi if ($includesubproducts) { $childsArbo = $this->product->getChildsArbo($id, 1); - $keys = array('rowid', 'qty', 'fk_product_type', 'label', 'incdec'); + $keys = array('rowid', 'qty', 'fk_product_type', 'label', 'incdec', 'ref', 'fk_association', 'rang'); $childs = array(); foreach ($childsArbo as $values) { $childs[] = array_combine($keys, $values); diff --git a/htdocs/product/class/html.formproduct.class.php b/htdocs/product/class/html.formproduct.class.php index da10faa4f34..4ede9e1e297 100644 --- a/htdocs/product/class/html.formproduct.class.php +++ b/htdocs/product/class/html.formproduct.class.php @@ -102,12 +102,12 @@ class FormProduct } elseif ($sumStock) { $sql .= ", sum(ps.reel) as stock"; } - $sql .= " FROM ".MAIN_DB_PREFIX."entrepot as e"; - $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."product_stock as ps on ps.fk_entrepot = e.rowid"; + $sql .= " FROM ".$this->db->prefix()."entrepot as e"; + $sql .= " LEFT JOIN ".$this->db->prefix()."product_stock as ps on ps.fk_entrepot = e.rowid"; if (!empty($fk_product) && $fk_product > 0) { $sql .= " AND ps.fk_product = ".((int) $fk_product); if (!empty($batch)) { - $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."product_batch as pb on pb.fk_product_stock = ps.rowid AND pb.batch = '".$this->db->escape($batch)."'"; + $sql .= " LEFT JOIN ".$this->db->prefix()."product_batch as pb on pb.fk_product_stock = ps.rowid AND pb.batch = '".$this->db->escape($batch)."'"; } } $sql .= " WHERE e.entity IN (".getEntity('stock').")"; @@ -202,7 +202,7 @@ class FormProduct /** * Return list of warehouses * - * @param string|int $selected Id of preselected warehouse ('' or '-1' for no value, 'ifone'=select value if one value otherwise no value, '-2' to use the default value from setup) + * @param string|int $selected Id of preselected warehouse ('' or '-1' for no value, 'ifone' and 'ifonenodefault' = select value if one value otherwise no value, '-2' to use the default value from setup) * @param string $htmlname Name of html select html * @param string $filterstatus warehouse status filter, following comma separated filter options can be used * 'warehouseopen' = select products from open warehouses, @@ -279,7 +279,7 @@ class FormProduct } $out .= ''; + if (array_key_exists($productId, $this->cache_lot)) { + foreach ($this->cache_lot[$productId] as $id => $arraytypes) { + if (empty($fk_entrepot) || $fk_entrepot == $arraytypes['entrepot_id']) { + $label = $arraytypes['entrepot_label'] . ' - '; + $label .= $arraytypes['batch']; + $out .= ''; + } } } } @@ -699,9 +701,9 @@ class FormProduct $this->cache_lot = array(); $productIdList = implode(',', $productIdArray); $sql = "SELECT pb.batch, pb.rowid, ps.fk_entrepot, pb.qty, e.ref as label, ps.fk_product"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_batch as pb"; - $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."product_stock as ps on ps.rowid = pb.fk_product_stock"; - $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."entrepot as e on e.rowid = ps.fk_entrepot AND e.entity IN (".getEntity('stock').")"; + $sql .= " FROM ".$this->db->prefix()."product_batch as pb"; + $sql .= " LEFT JOIN ".$this->db->prefix()."product_stock as ps on ps.rowid = pb.fk_product_stock"; + $sql .= " LEFT JOIN ".$this->db->prefix()."entrepot as e on e.rowid = ps.fk_entrepot AND e.entity IN (".getEntity('stock').")"; if (!empty($productIdList)) { $sql .= " WHERE ps.fk_product IN (".$this->db->sanitize($productIdList).")"; } diff --git a/htdocs/product/class/product.class.php b/htdocs/product/class/product.class.php index 1d4a5926b6e..8e61663d339 100644 --- a/htdocs/product/class/product.class.php +++ b/htdocs/product/class/product.class.php @@ -689,7 +689,7 @@ class Product extends CommonObject if ($result >= 0) { $sql = "SELECT count(*) as nb"; - $sql .= " FROM ".MAIN_DB_PREFIX."product"; + $sql .= " FROM ".$this->db->prefix()."product"; $sql .= " WHERE entity IN (".getEntity('product').")"; $sql .= " AND ref = '".$this->db->escape($this->ref)."'"; @@ -698,7 +698,7 @@ class Product extends CommonObject $obj = $this->db->fetch_object($result); if ($obj->nb == 0) { // Produit non deja existant - $sql = "INSERT INTO ".MAIN_DB_PREFIX."product ("; + $sql = "INSERT INTO ".$this->db->prefix()."product ("; $sql .= "datec"; $sql .= ", entity"; $sql .= ", ref"; @@ -761,7 +761,7 @@ class Product extends CommonObject dol_syslog(get_class($this)."::Create", LOG_DEBUG); $result = $this->db->query($sql); if ($result) { - $id = $this->db->last_insert_id(MAIN_DB_PREFIX."product"); + $id = $this->db->last_insert_id($this->db->prefix()."product"); if ($id > 0) { $this->id = $id; @@ -782,9 +782,9 @@ class Product extends CommonObject // update accountancy for this entity if (!$error && !empty($conf->global->MAIN_PRODUCT_PERENTITY_SHARED)) { - $this->db->query("DELETE FROM " . MAIN_DB_PREFIX . "product_perentity WHERE fk_product = " .((int) $this->id) . " AND entity = " . ((int) $conf->entity)); + $this->db->query("DELETE FROM " . $this->db->prefix() . "product_perentity WHERE fk_product = " .((int) $this->id) . " AND entity = " . ((int) $conf->entity)); - $sql = "INSERT INTO " . MAIN_DB_PREFIX . "product_perentity ("; + $sql = "INSERT INTO " . $this->db->prefix() . "product_perentity ("; $sql .= " fk_product"; $sql .= ", entity"; $sql .= ", accountancy_code_buy"; @@ -860,6 +860,8 @@ class Product extends CommonObject */ public function verify() { + global $langs; + $this->errors = array(); $result = 0; @@ -870,6 +872,16 @@ class Product extends CommonObject $result = -2; } + $arrayofnonnegativevalue = array('weight'=>'Weight', 'width'=>'Width', 'height'=>'Height', 'length'=>'Length', 'surface'=>'Surface', 'volume'=>'Volume'); + foreach ($arrayofnonnegativevalue as $key => $value) { + if (property_exists($this, $key) && !empty($this->$key) && ($this->$key < 0)) { + $langs->loadLangs(array("main", "other")); + $this->error = $langs->trans("FieldCannotBeNegative", $langs->transnoentitiesnoconv($value)); + $this->errors[] = $this->error; + $result = -4; + } + } + $rescode = $this->check_barcode($this->barcode, $this->barcode_type_code); if ($rescode) { if ($rescode == -1) { @@ -1062,7 +1074,7 @@ class Product extends CommonObject foreach ($ObjW->detail_batch as $detail) { // Each lines of detail in product_batch of the current $ObjW = product_stock if ($detail->batch == $valueforundefinedlot || $detail->batch == 'Undefined') { // We discard this line, we will create it later - $sqlclean = "DELETE FROM ".MAIN_DB_PREFIX."product_batch WHERE batch in('Undefined', '".$this->db->escape($valueforundefinedlot)."') AND fk_product_stock = ".((int) $ObjW->id); + $sqlclean = "DELETE FROM ".$this->db->prefix()."product_batch WHERE batch in('Undefined', '".$this->db->escape($valueforundefinedlot)."') AND fk_product_stock = ".((int) $ObjW->id); $result = $this->db->query($sqlclean); if (!$result) { dol_print_error($this->db); @@ -1094,7 +1106,7 @@ class Product extends CommonObject $this->barcode = $this->get_barcode($this, $this->barcode_type_code); } - $sql = "UPDATE ".MAIN_DB_PREFIX."product"; + $sql = "UPDATE ".$this->db->prefix()."product"; $sql .= " SET label = '".$this->db->escape($this->label)."'"; if ($updatetype && ($this->isProduct() || $this->isService())) { @@ -1182,9 +1194,9 @@ class Product extends CommonObject // update accountancy for this entity if (!$error && !empty($conf->global->MAIN_PRODUCT_PERENTITY_SHARED)) { - $this->db->query("DELETE FROM " . MAIN_DB_PREFIX . "product_perentity WHERE fk_product = " . ((int) $this->id) . " AND entity = " . ((int) $conf->entity)); + $this->db->query("DELETE FROM " . $this->db->prefix() . "product_perentity WHERE fk_product = " . ((int) $this->id) . " AND entity = " . ((int) $conf->entity)); - $sql = "INSERT INTO " . MAIN_DB_PREFIX . "product_perentity ("; + $sql = "INSERT INTO " . $this->db->prefix() . "product_perentity ("; $sql .= " fk_product"; $sql .= ", entity"; $sql .= ", accountancy_code_buy"; @@ -1327,9 +1339,9 @@ class Product extends CommonObject // Delete from product_batch on product delete if (!$error) { - $sql = "DELETE FROM ".MAIN_DB_PREFIX.'product_batch'; + $sql = "DELETE FROM ".$this->db->prefix().'product_batch'; $sql .= " WHERE fk_product_stock IN ("; - $sql .= "SELECT rowid FROM ".MAIN_DB_PREFIX.'product_stock'; + $sql .= "SELECT rowid FROM ".$this->db->prefix().'product_stock'; $sql .= " WHERE fk_product = ".((int) $this->id).")"; $result = $this->db->query($sql); @@ -1344,7 +1356,7 @@ class Product extends CommonObject $elements = array('product_fournisseur_price', 'product_price', 'product_lang', 'categorie_product', 'product_stock', 'product_customer_price', 'product_lot'); // product_batch is done before foreach ($elements as $table) { if (!$error) { - $sql = "DELETE FROM ".MAIN_DB_PREFIX.$table; + $sql = "DELETE FROM ".$this->db->prefix().$table; $sql .= " WHERE fk_product = ".(int) $this->id; $result = $this->db->query($sql); @@ -1377,7 +1389,7 @@ class Product extends CommonObject // Delete from product_association if (!$error) { - $sql = "DELETE FROM ".MAIN_DB_PREFIX."product_association"; + $sql = "DELETE FROM ".$this->db->prefix()."product_association"; $sql .= " WHERE fk_product_pere = ".(int) $this->id." OR fk_product_fils = ".(int) $this->id; $result = $this->db->query($sql); @@ -1398,7 +1410,7 @@ class Product extends CommonObject // Delete product if (!$error) { - $sqlz = "DELETE FROM ".MAIN_DB_PREFIX."product"; + $sqlz = "DELETE FROM ".$this->db->prefix()."product"; $sqlz .= " WHERE rowid = ".(int) $this->id; $resultz = $this->db->query($sqlz); @@ -1456,14 +1468,14 @@ class Product extends CommonObject foreach ($langs_available as $key => $value) { if ($key == $current_lang) { $sql = "SELECT rowid"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_lang"; + $sql .= " FROM ".$this->db->prefix()."product_lang"; $sql .= " WHERE fk_product = ".((int) $this->id); $sql .= " AND lang = '".$this->db->escape($key)."'"; $result = $this->db->query($sql); if ($this->db->num_rows($result)) { // if there is already a description line for this language - $sql2 = "UPDATE ".MAIN_DB_PREFIX."product_lang"; + $sql2 = "UPDATE ".$this->db->prefix()."product_lang"; $sql2 .= " SET "; $sql2 .= " label='".$this->db->escape($this->label)."',"; $sql2 .= " description='".$this->db->escape($this->description)."'"; @@ -1472,7 +1484,7 @@ class Product extends CommonObject } $sql2 .= " WHERE fk_product = ".((int) $this->id)." AND lang = '".$this->db->escape($key)."'"; } else { - $sql2 = "INSERT INTO ".MAIN_DB_PREFIX."product_lang (fk_product, lang, label, description"; + $sql2 = "INSERT INTO ".$this->db->prefix()."product_lang (fk_product, lang, label, description"; if (!empty($conf->global->PRODUCT_USE_OTHER_FIELD_IN_TRANSLATION)) { $sql2 .= ", note"; } @@ -1496,14 +1508,14 @@ class Product extends CommonObject } $sql = "SELECT rowid"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_lang"; + $sql .= " FROM ".$this->db->prefix()."product_lang"; $sql .= " WHERE fk_product = ".((int) $this->id); $sql .= " AND lang = '".$this->db->escape($key)."'"; $result = $this->db->query($sql); if ($this->db->num_rows($result)) { // if there is already a description line for this language - $sql2 = "UPDATE ".MAIN_DB_PREFIX."product_lang"; + $sql2 = "UPDATE ".$this->db->prefix()."product_lang"; $sql2 .= " SET "; $sql2 .= " label = '".$this->db->escape($this->multilangs["$key"]["label"])."',"; $sql2 .= " description = '".$this->db->escape($this->multilangs["$key"]["description"])."'"; @@ -1512,7 +1524,7 @@ class Product extends CommonObject } $sql2 .= " WHERE fk_product = ".((int) $this->id)." AND lang = '".$this->db->escape($key)."'"; } else { - $sql2 = "INSERT INTO ".MAIN_DB_PREFIX."product_lang (fk_product, lang, label, description"; + $sql2 = "INSERT INTO ".$this->db->prefix()."product_lang (fk_product, lang, label, description"; if (!empty($conf->global->PRODUCT_USE_OTHER_FIELD_IN_TRANSLATION)) { $sql2 .= ", note"; } @@ -1558,7 +1570,7 @@ class Product extends CommonObject */ public function delMultiLangs($langtodelete, $user) { - $sql = "DELETE FROM ".MAIN_DB_PREFIX."product_lang"; + $sql = "DELETE FROM ".$this->db->prefix()."product_lang"; $sql .= " WHERE fk_product = ".((int) $this->id)." AND lang = '".$this->db->escape($langtodelete)."'"; dol_syslog(get_class($this).'::delMultiLangs', LOG_DEBUG); @@ -1612,7 +1624,7 @@ class Product extends CommonObject return -1; } - $sql = "UPDATE ".MAIN_DB_PREFIX.$this->table_element." SET "; + $sql = "UPDATE ".$this->db->prefix().$this->table_element." SET "; $sql .= "$field = '".$this->db->escape($value)."'"; $sql .= " WHERE rowid = ".((int) $this->id); @@ -1655,7 +1667,7 @@ class Product extends CommonObject $current_lang = $langs->getDefaultLang(); $sql = "SELECT lang, label, description, note as other"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_lang"; + $sql .= " FROM ".$this->db->prefix()."product_lang"; $sql .= " WHERE fk_product = ".((int) $this->id); $result = $this->db->query($sql); @@ -1731,7 +1743,7 @@ class Product extends CommonObject } // Add new price - $sql = "INSERT INTO ".MAIN_DB_PREFIX."product_price(price_level,date_price, fk_product, fk_user_author, price, price_ttc, price_base_type,tosell, tva_tx, default_vat_code, recuperableonly,"; + $sql = "INSERT INTO ".$this->db->prefix()."product_price(price_level,date_price, fk_product, fk_user_author, price, price_ttc, price_base_type,tosell, tva_tx, default_vat_code, recuperableonly,"; $sql .= " localtax1_tx, localtax2_tx, localtax1_type, localtax2_type, price_min,price_min_ttc,price_by_qty,entity,fk_price_expression) "; $sql .= " VALUES(".($level ? ((int) $level) : 1).", '".$this->db->idate($now)."', ".((int) $this->id).", ".((int) $user->id).", ".((float) price2num($this->price)).", ".((float) price2num($this->price_ttc)).",'".$this->db->escape($this->price_base_type)."',".((int) $this->status).", ".((float) price2num($this->tva_tx)).", ".($this->default_vat_code ? ("'".$this->db->escape($this->default_vat_code)."'") : "null").", ".((int) $this->tva_npr).","; $sql .= " ".price2num($this->localtax1_tx).", ".price2num($this->localtax2_tx).", '".$this->db->escape($this->localtax1_type)."', '".$this->db->escape($this->localtax2_type)."', ".price2num($this->price_min).", ".price2num($this->price_min_ttc).", ".price2num($this->price_by_qty).", ".((int) $conf->entity).",".($this->fk_price_expression > 0 ? ((int) $this->fk_price_expression) : 'null'); @@ -1760,11 +1772,11 @@ class Product extends CommonObject public function log_price_delete($user, $rowid) { // phpcs:enable - $sql = "DELETE FROM ".MAIN_DB_PREFIX."product_price_by_qty"; + $sql = "DELETE FROM ".$this->db->prefix()."product_price_by_qty"; $sql .= " WHERE fk_product_price = ".((int) $rowid); $resql = $this->db->query($sql); - $sql = "DELETE FROM ".MAIN_DB_PREFIX."product_price"; + $sql = "DELETE FROM ".$this->db->prefix()."product_price"; $sql .= " WHERE rowid=".((int) $rowid); $resql = $this->db->query($sql); if ($resql) { @@ -1912,7 +1924,7 @@ class Product extends CommonObject if (!empty($conf->global->PRODUCT_USE_SUPPLIER_PACKAGING)) { $sql .= ", pfp.packaging"; } - $sql .= " FROM ".MAIN_DB_PREFIX."product_fournisseur_price as pfp"; + $sql .= " FROM ".$this->db->prefix()."product_fournisseur_price as pfp"; $sql .= " WHERE pfp.rowid = ".((int) $prodfournprice); if ($qty > 0) { $sql .= " AND pfp.quantity <= ".((float) $qty); @@ -1966,7 +1978,7 @@ class Product extends CommonObject $sql .= " pfp.default_vat_code,"; $sql .= " pfp.multicurrency_price, pfp.multicurrency_unitprice, pfp.multicurrency_tx, pfp.fk_multicurrency, pfp.multicurrency_code,"; $sql .= " pfp.packaging"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_fournisseur_price as pfp"; + $sql .= " FROM ".$this->db->prefix()."product_fournisseur_price as pfp"; $sql .= " WHERE pfp.fk_product = ".((int) $product_id); if ($fourn_ref != 'none') { $sql .= " AND pfp.ref_fourn = '".$this->db->escape($fourn_ref)."'"; @@ -2037,7 +2049,7 @@ class Product extends CommonObject /** - * Modify customer price of a product/Service + * Modify customer price of a product/Service * * @param double $newprice New price * @param string $newpricebase HT or TTC @@ -2146,7 +2158,7 @@ class Product extends CommonObject // Ne pas mettre de quote sur les numeriques decimaux. // Ceci provoque des stockages avec arrondis en base au lieu des valeurs exactes. - $sql = "UPDATE ".MAIN_DB_PREFIX."product SET"; + $sql = "UPDATE ".$this->db->prefix()."product SET"; $sql .= " price_base_type='".$this->db->escape($newpricebase)."',"; $sql .= " price=".$price.","; $sql .= " price_ttc=".$price_ttc.","; @@ -2276,7 +2288,7 @@ class Product extends CommonObject $separatedStock = false; // Set to true will count stock from subtable llx_product_stock. It is slower than using denormalized field 'stock', but it is required when using multientity and shared warehouses. if (!empty($conf->global->MULTICOMPANY_PRODUCT_SHARING_ENABLED)) { if (!empty($conf->global->MULTICOMPANY_PMP_PER_ENTITY_ENABLED)) { - $checkPMPPerEntity = $this->db->query("SELECT pmp FROM " . MAIN_DB_PREFIX . "product_perentity WHERE fk_product = ".((int) $id)." AND entity = ".(int) $conf->entity); + $checkPMPPerEntity = $this->db->query("SELECT pmp FROM " . $this->db->prefix() . "product_perentity WHERE fk_product = ".((int) $id)." AND entity = ".(int) $conf->entity); if ($this->db->num_rows($checkPMPPerEntity)>0) { $separatedEntityPMP = true; } @@ -2300,12 +2312,12 @@ class Product extends CommonObject } else { $sql .= " p.stock"; } - $sql .= " FROM ".MAIN_DB_PREFIX."product as p"; + $sql .= " FROM ".$this->db->prefix()."product as p"; if (!empty($conf->global->MAIN_PRODUCT_PERENTITY_SHARED) || $separatedEntityPMP) { - $sql .= " LEFT JOIN " . MAIN_DB_PREFIX . "product_perentity as ppe ON ppe.fk_product = p.rowid AND ppe.entity = " . ((int) $conf->entity); + $sql .= " LEFT JOIN " . $this->db->prefix() . "product_perentity as ppe ON ppe.fk_product = p.rowid AND ppe.entity = " . ((int) $conf->entity); } if ($separatedStock) { - $sql .= " LEFT JOIN " . MAIN_DB_PREFIX . "product_stock as sp ON sp.fk_product = p.rowid AND sp.fk_entrepot IN (SELECT rowid FROM ".MAIN_DB_PREFIX."entrepot WHERE entity IN (".$this->db->sanitize($visibleWarehousesEntities)."))"; + $sql .= " LEFT JOIN " . $this->db->prefix() . "product_stock as sp ON sp.fk_product = p.rowid AND sp.fk_entrepot IN (SELECT rowid FROM ".$this->db->prefix()."entrepot WHERE entity IN (".$this->db->sanitize($visibleWarehousesEntities)."))"; } if ($id) { @@ -2455,7 +2467,7 @@ class Product extends CommonObject for ($i = 1; $i <= $conf->global->PRODUIT_MULTIPRICES_LIMIT; $i++) { $sql = "SELECT price, price_ttc, price_min, price_min_ttc,"; $sql .= " price_base_type, tva_tx, default_vat_code, tosell, price_by_qty, rowid, recuperableonly"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_price"; + $sql .= " FROM ".$this->db->prefix()."product_price"; $sql .= " WHERE entity IN (".getEntity('productprice').")"; $sql .= " AND price_level=".((int) $i); $sql .= " AND fk_product = ".((int) $this->id); @@ -2482,7 +2494,7 @@ class Product extends CommonObject if ($this->prices_by_qty[$i] == 1) { $sql = "SELECT rowid, price, unitprice, quantity, remise_percent, remise, price_base_type"; - $sql.= " FROM ".MAIN_DB_PREFIX."product_price_by_qty"; + $sql.= " FROM ".$this->db->prefix()."product_price_by_qty"; $sql.= " WHERE fk_product_price = ".((int) $this->prices_by_qty_id[$i]); $sql.= " ORDER BY quantity ASC"; $resultat=array(); @@ -2519,7 +2531,7 @@ class Product extends CommonObject } elseif (!empty($conf->global->PRODUIT_CUSTOMER_PRICES_BY_QTY) && empty($ignore_price_load)) { // prices per quantity $sql = "SELECT price, price_ttc, price_min, price_min_ttc,"; $sql .= " price_base_type, tva_tx, default_vat_code, tosell, price_by_qty, rowid"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_price"; + $sql .= " FROM ".$this->db->prefix()."product_price"; $sql .= " WHERE fk_product = ".((int) $this->id); $sql .= " ORDER BY date_price DESC, rowid DESC"; $sql .= " LIMIT 1"; @@ -2533,7 +2545,7 @@ class Product extends CommonObject // Récuperation de la liste des prix selon qty si flag positionné if ($this->prices_by_qty[0] == 1) { $sql = "SELECT rowid,price, unitprice, quantity, remise_percent, remise, remise, price_base_type"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_price_by_qty"; + $sql .= " FROM ".$this->db->prefix()."product_price_by_qty"; $sql .= " WHERE fk_product_price = ".((int) $this->prices_by_qty_id[0]); $sql .= " ORDER BY quantity ASC"; $resultat = array(); @@ -2565,7 +2577,7 @@ class Product extends CommonObject for ($i = 1; $i <= $conf->global->PRODUIT_MULTIPRICES_LIMIT; $i++) { $sql = "SELECT price, price_ttc, price_min, price_min_ttc,"; $sql .= " price_base_type, tva_tx, default_vat_code, tosell, price_by_qty, rowid, recuperableonly"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_price"; + $sql .= " FROM ".$this->db->prefix()."product_price"; $sql .= " WHERE entity IN (".getEntity('productprice').")"; $sql .= " AND price_level=".((int) $i); $sql .= " AND fk_product = ".((int) $this->id); @@ -2590,7 +2602,7 @@ class Product extends CommonObject // Récuperation de la liste des prix selon qty si flag positionné if ($this->prices_by_qty[$i] == 1) { $sql = "SELECT rowid, price, unitprice, quantity, remise_percent, remise, price_base_type"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_price_by_qty"; + $sql .= " FROM ".$this->db->prefix()."product_price_by_qty"; $sql .= " WHERE fk_product_price = ".((int) $this->prices_by_qty_id[$i]); $sql .= " ORDER BY quantity ASC"; $resultat = array(); @@ -2668,10 +2680,10 @@ class Product extends CommonObject $sql = "SELECT COUNT(DISTINCT c.fk_soc) as nb_customers, COUNT(DISTINCT c.rowid) as nb,"; $sql .= " SUM(mp.qty) as qty"; - $sql .= " FROM ".MAIN_DB_PREFIX."mrp_mo as c"; - $sql .= " INNER JOIN ".MAIN_DB_PREFIX."mrp_production as mp ON mp.fk_mo=c.rowid"; + $sql .= " FROM ".$this->db->prefix()."mrp_mo as c"; + $sql .= " INNER JOIN ".$this->db->prefix()."mrp_production as mp ON mp.fk_mo=c.rowid"; if (empty($user->rights->societe->client->voir) && !$socid) { - $sql .= "INNER JOIN ".MAIN_DB_PREFIX."societe_commerciaux as sc ON sc.fk_soc=c.fk_soc AND sc.fk_user = ".((int) $user->id); + $sql .= "INNER JOIN ".$this->db->prefix()."societe_commerciaux as sc ON sc.fk_soc=c.fk_soc AND sc.fk_user = ".((int) $user->id); } $sql .= " WHERE "; $sql .= " c.entity IN (".getEntity('mo').")"; @@ -2728,8 +2740,8 @@ class Product extends CommonObject $sql = "SELECT COUNT(DISTINCT b.rowid) as nb_toproduce,"; $sql .= " SUM(b.qty) as qty_toproduce"; - $sql .= " FROM ".MAIN_DB_PREFIX."bom_bom as b"; - $sql .= " INNER JOIN ".MAIN_DB_PREFIX."bom_bomline as bl ON bl.fk_bom=b.rowid"; + $sql .= " FROM ".$this->db->prefix()."bom_bom as b"; + $sql .= " INNER JOIN ".$this->db->prefix()."bom_bomline as bl ON bl.fk_bom=b.rowid"; $sql .= " WHERE "; $sql .= " b.entity IN (".getEntity('bom').")"; $sql .= " AND b.fk_product =".((int) $this->id); @@ -2747,8 +2759,8 @@ class Product extends CommonObject $sql = "SELECT COUNT(DISTINCT bl.rowid) as nb_toconsume,"; $sql .= " SUM(bl.qty) as qty_toconsume"; - $sql .= " FROM ".MAIN_DB_PREFIX."bom_bom as b"; - $sql .= " INNER JOIN ".MAIN_DB_PREFIX."bom_bomline as bl ON bl.fk_bom=b.rowid"; + $sql .= " FROM ".$this->db->prefix()."bom_bom as b"; + $sql .= " INNER JOIN ".$this->db->prefix()."bom_bomline as bl ON bl.fk_bom=b.rowid"; $sql .= " WHERE "; $sql .= " b.entity IN (".getEntity('bom').")"; $sql .= " AND bl.fk_product =".((int) $this->id); @@ -2790,11 +2802,11 @@ class Product extends CommonObject $sql = "SELECT COUNT(DISTINCT p.fk_soc) as nb_customers, COUNT(DISTINCT p.rowid) as nb,"; $sql .= " COUNT(pd.rowid) as nb_rows, SUM(pd.qty) as qty"; - $sql .= " FROM ".MAIN_DB_PREFIX."propaldet as pd"; - $sql .= ", ".MAIN_DB_PREFIX."propal as p"; - $sql .= ", ".MAIN_DB_PREFIX."societe as s"; + $sql .= " FROM ".$this->db->prefix()."propaldet as pd"; + $sql .= ", ".$this->db->prefix()."propal as p"; + $sql .= ", ".$this->db->prefix()."societe as s"; if (empty($user->rights->societe->client->voir) && !$socid) { - $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } $sql .= " WHERE p.rowid = pd.fk_propal"; $sql .= " AND p.fk_soc = s.rowid"; @@ -2865,11 +2877,11 @@ class Product extends CommonObject $sql = "SELECT COUNT(DISTINCT p.fk_soc) as nb_suppliers, COUNT(DISTINCT p.rowid) as nb,"; $sql .= " COUNT(pd.rowid) as nb_rows, SUM(pd.qty) as qty"; - $sql .= " FROM ".MAIN_DB_PREFIX."supplier_proposaldet as pd"; - $sql .= ", ".MAIN_DB_PREFIX."supplier_proposal as p"; - $sql .= ", ".MAIN_DB_PREFIX."societe as s"; + $sql .= " FROM ".$this->db->prefix()."supplier_proposaldet as pd"; + $sql .= ", ".$this->db->prefix()."supplier_proposal as p"; + $sql .= ", ".$this->db->prefix()."societe as s"; if (empty($user->rights->societe->client->voir) && !$socid) { - $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } $sql .= " WHERE p.rowid = pd.fk_supplier_proposal"; $sql .= " AND p.fk_soc = s.rowid"; @@ -2921,11 +2933,11 @@ class Product extends CommonObject $sql = "SELECT COUNT(DISTINCT c.fk_soc) as nb_customers, COUNT(DISTINCT c.rowid) as nb,"; $sql .= " COUNT(cd.rowid) as nb_rows, SUM(cd.qty) as qty"; - $sql .= " FROM ".MAIN_DB_PREFIX."commandedet as cd"; - $sql .= ", ".MAIN_DB_PREFIX."commande as c"; - $sql .= ", ".MAIN_DB_PREFIX."societe as s"; + $sql .= " FROM ".$this->db->prefix()."commandedet as cd"; + $sql .= ", ".$this->db->prefix()."commande as c"; + $sql .= ", ".$this->db->prefix()."societe as s"; if (empty($user->rights->societe->client->voir) && !$socid && !$forVirtualStock) { - $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } $sql .= " WHERE c.rowid = cd.fk_commande"; $sql .= " AND c.fk_soc = s.rowid"; @@ -2976,10 +2988,10 @@ class Product extends CommonObject if (!empty($conf->global->STOCK_CALCULATE_ON_BILL)) { if (!empty($conf->global->DECREASE_ONLY_UNINVOICEDPRODUCTS)) { $adeduire = 0; - $sql = "SELECT sum(fd.qty) as count FROM ".MAIN_DB_PREFIX."facturedet fd "; - $sql .= " JOIN ".MAIN_DB_PREFIX."facture f ON fd.fk_facture = f.rowid "; - $sql .= " JOIN ".MAIN_DB_PREFIX."element_element el ON el.fk_target = f.rowid and el.targettype = 'facture' and sourcetype = 'commande'"; - $sql .= " JOIN ".MAIN_DB_PREFIX."commande c ON el.fk_source = c.rowid "; + $sql = "SELECT sum(fd.qty) as count FROM ".$this->db->prefix()."facturedet fd "; + $sql .= " JOIN ".$this->db->prefix()."facture f ON fd.fk_facture = f.rowid "; + $sql .= " JOIN ".$this->db->prefix()."element_element el ON el.fk_target = f.rowid and el.targettype = 'facture' and sourcetype = 'commande'"; + $sql .= " JOIN ".$this->db->prefix()."commande c ON el.fk_source = c.rowid "; $sql .= " WHERE c.fk_statut IN (".$this->db->sanitize($filtrestatut).") AND c.facture = 0 AND fd.fk_product = ".((int) $this->id); dol_syslog(__METHOD__.":: sql $sql", LOG_NOTICE); @@ -3023,11 +3035,11 @@ class Product extends CommonObject $sql = "SELECT COUNT(DISTINCT c.fk_soc) as nb_suppliers, COUNT(DISTINCT c.rowid) as nb,"; $sql .= " COUNT(cd.rowid) as nb_rows, SUM(cd.qty) as qty"; - $sql .= " FROM ".MAIN_DB_PREFIX."commande_fournisseurdet as cd"; - $sql .= ", ".MAIN_DB_PREFIX."commande_fournisseur as c"; - $sql .= ", ".MAIN_DB_PREFIX."societe as s"; + $sql .= " FROM ".$this->db->prefix()."commande_fournisseurdet as cd"; + $sql .= ", ".$this->db->prefix()."commande_fournisseur as c"; + $sql .= ", ".$this->db->prefix()."societe as s"; if (empty($user->rights->societe->client->voir) && !$socid && !$forVirtualStock) { - $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } $sql .= " WHERE c.rowid = cd.fk_commande"; $sql .= " AND c.fk_soc = s.rowid"; @@ -3081,13 +3093,13 @@ class Product extends CommonObject $sql = "SELECT COUNT(DISTINCT e.fk_soc) as nb_customers, COUNT(DISTINCT e.rowid) as nb,"; $sql .= " COUNT(ed.rowid) as nb_rows, SUM(ed.qty) as qty"; - $sql .= " FROM ".MAIN_DB_PREFIX."expeditiondet as ed"; - $sql .= ", ".MAIN_DB_PREFIX."commandedet as cd"; - $sql .= ", ".MAIN_DB_PREFIX."commande as c"; - $sql .= ", ".MAIN_DB_PREFIX."expedition as e"; - $sql .= ", ".MAIN_DB_PREFIX."societe as s"; + $sql .= " FROM ".$this->db->prefix()."expeditiondet as ed"; + $sql .= ", ".$this->db->prefix()."commandedet as cd"; + $sql .= ", ".$this->db->prefix()."commande as c"; + $sql .= ", ".$this->db->prefix()."expedition as e"; + $sql .= ", ".$this->db->prefix()."societe as s"; if (empty($user->rights->societe->client->voir) && !$socid && !$forVirtualStock) { - $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } $sql .= " WHERE e.rowid = ed.fk_expedition"; $sql .= " AND c.rowid = cd.fk_commande"; @@ -3166,11 +3178,11 @@ class Product extends CommonObject $sql = "SELECT COUNT(DISTINCT cf.fk_soc) as nb_suppliers, COUNT(DISTINCT cf.rowid) as nb,"; $sql .= " COUNT(fd.rowid) as nb_rows, SUM(fd.qty) as qty"; - $sql .= " FROM ".MAIN_DB_PREFIX."commande_fournisseur_dispatch as fd"; - $sql .= ", ".MAIN_DB_PREFIX."commande_fournisseur as cf"; - $sql .= ", ".MAIN_DB_PREFIX."societe as s"; + $sql .= " FROM ".$this->db->prefix()."commande_fournisseur_dispatch as fd"; + $sql .= ", ".$this->db->prefix()."commande_fournisseur as cf"; + $sql .= ", ".$this->db->prefix()."societe as s"; if (empty($user->rights->societe->client->voir) && !$socid && !$forVirtualStock) { - $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } $sql .= " WHERE cf.rowid = fd.fk_commande"; $sql .= " AND cf.fk_soc = s.rowid"; @@ -3223,11 +3235,11 @@ class Product extends CommonObject $sql = "SELECT COUNT(DISTINCT m.fk_soc) as nb_customers, COUNT(DISTINCT m.rowid) as nb,"; $sql .= " COUNT(mp.rowid) as nb_rows, SUM(mp.qty) as qty, role"; - $sql .= " FROM ".MAIN_DB_PREFIX."mrp_production as mp"; - $sql .= ", ".MAIN_DB_PREFIX."mrp_mo as m"; - $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."societe as s ON s.rowid = m.fk_soc"; + $sql .= " FROM ".$this->db->prefix()."mrp_production as mp"; + $sql .= ", ".$this->db->prefix()."mrp_mo as m"; + $sql .= " LEFT JOIN ".$this->db->prefix()."societe as s ON s.rowid = m.fk_soc"; if (empty($user->rights->societe->client->voir) && !$socid && !$forVirtualStock) { - $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } $sql .= " WHERE m.rowid = mp.fk_mo"; $sql .= " AND m.entity IN (".getEntity($forVirtualStock && !empty($conf->global->STOCK_CALCULATE_VIRTUAL_STOCK_TRANSVERSE_MODE) ? 'stock' : 'mrp').")"; @@ -3316,11 +3328,11 @@ class Product extends CommonObject $sql = "SELECT COUNT(DISTINCT c.fk_soc) as nb_customers, COUNT(DISTINCT c.rowid) as nb,"; $sql .= " COUNT(cd.rowid) as nb_rows, SUM(cd.qty) as qty"; - $sql .= " FROM ".MAIN_DB_PREFIX."contratdet as cd"; - $sql .= ", ".MAIN_DB_PREFIX."contrat as c"; - $sql .= ", ".MAIN_DB_PREFIX."societe as s"; + $sql .= " FROM ".$this->db->prefix()."contratdet as cd"; + $sql .= ", ".$this->db->prefix()."contrat as c"; + $sql .= ", ".$this->db->prefix()."societe as s"; if (empty($user->rights->societe->client->voir) && !$socid) { - $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } $sql .= " WHERE c.rowid = cd.fk_contrat"; $sql .= " AND c.fk_soc = s.rowid"; @@ -3390,11 +3402,11 @@ class Product extends CommonObject $sql = "SELECT COUNT(DISTINCT f.fk_soc) as nb_customers, COUNT(DISTINCT f.rowid) as nb,"; $sql .= " COUNT(fd.rowid) as nb_rows, SUM(".$this->db->ifsql('f.type != 2', 'fd.qty', 'fd.qty * -1').") as qty"; - $sql .= " FROM ".MAIN_DB_PREFIX."facturedet as fd"; - $sql .= ", ".MAIN_DB_PREFIX."facture as f"; - $sql .= ", ".MAIN_DB_PREFIX."societe as s"; + $sql .= " FROM ".$this->db->prefix()."facturedet as fd"; + $sql .= ", ".$this->db->prefix()."facture as f"; + $sql .= ", ".$this->db->prefix()."societe as s"; if (empty($user->rights->societe->client->voir) && !$socid) { - $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } $sql .= " WHERE f.rowid = fd.fk_facture"; $sql .= " AND f.fk_soc = s.rowid"; @@ -3464,11 +3476,11 @@ class Product extends CommonObject $sql = "SELECT COUNT(DISTINCT f.fk_soc) as nb_suppliers, COUNT(DISTINCT f.rowid) as nb,"; $sql .= " COUNT(fd.rowid) as nb_rows, SUM(fd.qty) as qty"; - $sql .= " FROM ".MAIN_DB_PREFIX."facture_fourn_det as fd"; - $sql .= ", ".MAIN_DB_PREFIX."facture_fourn as f"; - $sql .= ", ".MAIN_DB_PREFIX."societe as s"; + $sql .= " FROM ".$this->db->prefix()."facture_fourn_det as fd"; + $sql .= ", ".$this->db->prefix()."facture_fourn as f"; + $sql .= ", ".$this->db->prefix()."societe as s"; if (empty($user->rights->societe->client->voir) && !$socid) { - $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } $sql .= " WHERE f.rowid = fd.fk_facture_fourn"; $sql .= " AND f.fk_soc = s.rowid"; @@ -3595,12 +3607,12 @@ class Product extends CommonObject if ($mode == 'bynumber') { $sql .= ", count(DISTINCT f.rowid)"; } - $sql .= " FROM ".MAIN_DB_PREFIX."facturedet as d, ".MAIN_DB_PREFIX."facture as f, ".MAIN_DB_PREFIX."societe as s"; + $sql .= " FROM ".$this->db->prefix()."facturedet as d, ".$this->db->prefix()."facture as f, ".$this->db->prefix()."societe as s"; if ($filteronproducttype >= 0) { - $sql .= ", ".MAIN_DB_PREFIX."product as p"; + $sql .= ", ".$this->db->prefix()."product as p"; } if (empty($user->rights->societe->client->voir) && !$socid) { - $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } $sql .= " WHERE f.rowid = d.fk_facture"; if ($this->id > 0) { @@ -3648,12 +3660,12 @@ class Product extends CommonObject if ($mode == 'bynumber') { $sql .= ", count(DISTINCT f.rowid)"; } - $sql .= " FROM ".MAIN_DB_PREFIX."facture_fourn_det as d, ".MAIN_DB_PREFIX."facture_fourn as f, ".MAIN_DB_PREFIX."societe as s"; + $sql .= " FROM ".$this->db->prefix()."facture_fourn_det as d, ".$this->db->prefix()."facture_fourn as f, ".$this->db->prefix()."societe as s"; if ($filteronproducttype >= 0) { - $sql .= ", ".MAIN_DB_PREFIX."product as p"; + $sql .= ", ".$this->db->prefix()."product as p"; } if (empty($user->rights->societe->client->voir) && !$socid) { - $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } $sql .= " WHERE f.rowid = d.fk_facture_fourn"; if ($this->id > 0) { @@ -3699,12 +3711,12 @@ class Product extends CommonObject if ($mode == 'bynumber') { $sql .= ", count(DISTINCT p.rowid)"; } - $sql .= " FROM ".MAIN_DB_PREFIX."propaldet as d, ".MAIN_DB_PREFIX."propal as p, ".MAIN_DB_PREFIX."societe as s"; + $sql .= " FROM ".$this->db->prefix()."propaldet as d, ".$this->db->prefix()."propal as p, ".$this->db->prefix()."societe as s"; if ($filteronproducttype >= 0) { - $sql .= ", ".MAIN_DB_PREFIX."product as prod"; + $sql .= ", ".$this->db->prefix()."product as prod"; } if (empty($user->rights->societe->client->voir) && !$socid) { - $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } $sql .= " WHERE p.rowid = d.fk_propal"; if ($this->id > 0) { @@ -3751,12 +3763,12 @@ class Product extends CommonObject if ($mode == 'bynumber') { $sql .= ", count(DISTINCT p.rowid)"; } - $sql .= " FROM ".MAIN_DB_PREFIX."supplier_proposaldet as d, ".MAIN_DB_PREFIX."supplier_proposal as p, ".MAIN_DB_PREFIX."societe as s"; + $sql .= " FROM ".$this->db->prefix()."supplier_proposaldet as d, ".$this->db->prefix()."supplier_proposal as p, ".$this->db->prefix()."societe as s"; if ($filteronproducttype >= 0) { - $sql .= ", ".MAIN_DB_PREFIX."product as prod"; + $sql .= ", ".$this->db->prefix()."product as prod"; } if (empty($user->rights->societe->client->voir) && !$socid) { - $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } $sql .= " WHERE p.rowid = d.fk_supplier_proposal"; if ($this->id > 0) { @@ -3802,12 +3814,12 @@ class Product extends CommonObject if ($mode == 'bynumber') { $sql .= ", count(DISTINCT c.rowid)"; } - $sql .= " FROM ".MAIN_DB_PREFIX."commandedet as d, ".MAIN_DB_PREFIX."commande as c, ".MAIN_DB_PREFIX."societe as s"; + $sql .= " FROM ".$this->db->prefix()."commandedet as d, ".$this->db->prefix()."commande as c, ".$this->db->prefix()."societe as s"; if ($filteronproducttype >= 0) { - $sql .= ", ".MAIN_DB_PREFIX."product as p"; + $sql .= ", ".$this->db->prefix()."product as p"; } if (empty($user->rights->societe->client->voir) && !$socid) { - $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } $sql .= " WHERE c.rowid = d.fk_commande"; if ($this->id > 0) { @@ -3853,12 +3865,12 @@ class Product extends CommonObject if ($mode == 'bynumber') { $sql .= ", count(DISTINCT c.rowid)"; } - $sql .= " FROM ".MAIN_DB_PREFIX."commande_fournisseurdet as d, ".MAIN_DB_PREFIX."commande_fournisseur as c, ".MAIN_DB_PREFIX."societe as s"; + $sql .= " FROM ".$this->db->prefix()."commande_fournisseurdet as d, ".$this->db->prefix()."commande_fournisseur as c, ".$this->db->prefix()."societe as s"; if ($filteronproducttype >= 0) { - $sql .= ", ".MAIN_DB_PREFIX."product as p"; + $sql .= ", ".$this->db->prefix()."product as p"; } if (empty($user->rights->societe->client->voir) && !$socid) { - $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } $sql .= " WHERE c.rowid = d.fk_commande"; if ($this->id > 0) { @@ -3904,12 +3916,12 @@ class Product extends CommonObject if ($mode == 'bynumber') { $sql .= ", count(DISTINCT c.rowid)"; } - $sql .= " FROM ".MAIN_DB_PREFIX."contratdet as d, ".MAIN_DB_PREFIX."contrat as c, ".MAIN_DB_PREFIX."societe as s"; + $sql .= " FROM ".$this->db->prefix()."contratdet as d, ".$this->db->prefix()."contrat as c, ".$this->db->prefix()."societe as s"; if ($filteronproducttype >= 0) { - $sql .= ", ".MAIN_DB_PREFIX."product as p"; + $sql .= ", ".$this->db->prefix()."product as p"; } if (empty($user->rights->societe->client->voir) && !$socid) { - $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } $sql .= " WHERE c.entity IN (".getEntity('contract').")"; @@ -3958,12 +3970,12 @@ class Product extends CommonObject if ($mode == 'bynumber') { $sql .= ", count(DISTINCT d.rowid)"; } - $sql .= " FROM ".MAIN_DB_PREFIX."mrp_mo as d LEFT JOIN ".MAIN_DB_PREFIX."societe as s ON d.fk_soc = s.rowid"; + $sql .= " FROM ".$this->db->prefix()."mrp_mo as d LEFT JOIN ".$this->db->prefix()."societe as s ON d.fk_soc = s.rowid"; if ($filteronproducttype >= 0) { - $sql .= ", ".MAIN_DB_PREFIX."product as p"; + $sql .= ", ".$this->db->prefix()."product as p"; } if (empty($user->rights->societe->client->voir) && !$socid) { - $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc"; + $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } $sql .= " WHERE d.entity IN (".getEntity('mo').")"; @@ -4021,21 +4033,21 @@ class Product extends CommonObject } // Check not already father of id_pere (to avoid father -> child -> father links) - $sql = "SELECT fk_product_pere from ".MAIN_DB_PREFIX."product_association"; + $sql = "SELECT fk_product_pere from ".$this->db->prefix()."product_association"; $sql .= " WHERE fk_product_pere = ".((int) $id_fils)." AND fk_product_fils = ".((int) $id_pere); if (!$this->db->query($sql)) { dol_print_error($this->db); return -1; } else { //Selection of the highest row - $sql = "SELECT MAX(rang) as max_rank FROM ".MAIN_DB_PREFIX."product_association"; + $sql = "SELECT MAX(rang) as max_rank FROM ".$this->db->prefix()."product_association"; $sql .= " WHERE fk_product_pere = ".((int) $id_pere); $resql = $this->db->query($sql); if ($resql > 0) { $obj = $this->db->fetch_object($resql); $rank = $obj->max_rank + 1; //Addition of a product with the highest rank +1 - $sql = "INSERT INTO ".MAIN_DB_PREFIX."product_association(fk_product_pere,fk_product_fils,qty,incdec,rang)"; + $sql = "INSERT INTO ".$this->db->prefix()."product_association(fk_product_pere,fk_product_fils,qty,incdec,rang)"; $sql .= " VALUES (".((int) $id_pere).", ".((int) $id_fils).", ".price2num($qty, 'MS').", ".price2num($incdec, 'MS').", ".((int) $rank).")"; if (! $this->db->query($sql)) { dol_print_error($this->db); @@ -4077,7 +4089,7 @@ class Product extends CommonObject $qty = 1; } - $sql = 'UPDATE '.MAIN_DB_PREFIX.'product_association SET '; + $sql = 'UPDATE '.$this->db->prefix().'product_association SET '; $sql .= 'qty = '.price2num($qty, 'MS'); $sql .= ',incdec = '.price2num($incdec, 'MS'); $sql .= ' WHERE fk_product_pere = '.((int) $id_pere).' AND fk_product_fils = '.((int) $id_fils); @@ -4108,7 +4120,7 @@ class Product extends CommonObject $fk_child = 0; } - $sql = "DELETE FROM ".MAIN_DB_PREFIX."product_association"; + $sql = "DELETE FROM ".$this->db->prefix()."product_association"; $sql .= " WHERE fk_product_pere = ".((int) $fk_parent); $sql .= " AND fk_product_fils = ".((int) $fk_child); @@ -4119,7 +4131,7 @@ class Product extends CommonObject } // Updated ranks so that none are missing - $sqlrank = "SELECT rowid, rang FROM ".MAIN_DB_PREFIX."product_association"; + $sqlrank = "SELECT rowid, rang FROM ".$this->db->prefix()."product_association"; $sqlrank.= " WHERE fk_product_pere = ".((int) $fk_parent); $sqlrank.= " ORDER BY rang"; $resqlrank = $this->db->query($sqlrank); @@ -4127,7 +4139,7 @@ class Product extends CommonObject $cpt = 0; while ($objrank = $this->db->fetch_object($resqlrank)) { $cpt++; - $sql = "UPDATE ".MAIN_DB_PREFIX."product_association"; + $sql = "UPDATE ".$this->db->prefix()."product_association"; $sql.= " SET rang = ".((int) $cpt); $sql.= " WHERE rowid = ".((int) $objrank->rowid); if (! $this->db->query($sql)) { @@ -4151,7 +4163,7 @@ class Product extends CommonObject { // phpcs:enable $sql = "SELECT fk_product_pere, qty, incdec"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_association"; + $sql .= " FROM ".$this->db->prefix()."product_association"; $sql .= " WHERE fk_product_pere = ".((int) $fk_parent); $sql .= " AND fk_product_fils = ".((int) $fk_child); @@ -4201,7 +4213,7 @@ class Product extends CommonObject if ($ref_fourn) { $sql = "SELECT rowid, fk_product"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_fournisseur_price"; + $sql .= " FROM ".$this->db->prefix()."product_fournisseur_price"; $sql .= " WHERE fk_soc = ".((int) $id_fourn); $sql .= " AND ref_fourn = '".$this->db->escape($ref_fourn)."'"; $sql .= " AND fk_product <> ".((int) $this->id); @@ -4220,7 +4232,7 @@ class Product extends CommonObject } $sql = "SELECT rowid"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_fournisseur_price"; + $sql .= " FROM ".$this->db->prefix()."product_fournisseur_price"; $sql .= " WHERE fk_soc = ".((int) $id_fourn); if ($ref_fourn) { $sql .= " AND ref_fourn = '".$this->db->escape($ref_fourn)."'"; @@ -4237,7 +4249,7 @@ class Product extends CommonObject // The reference supplier does not exist, we create it for this product. if (empty($obj)) { - $sql = "INSERT INTO ".MAIN_DB_PREFIX."product_fournisseur_price("; + $sql = "INSERT INTO ".$this->db->prefix()."product_fournisseur_price("; $sql .= "datec"; $sql .= ", entity"; $sql .= ", fk_product"; @@ -4258,7 +4270,7 @@ class Product extends CommonObject $sql .= ")"; if ($this->db->query($sql)) { - $this->product_fourn_price_id = $this->db->last_insert_id(MAIN_DB_PREFIX."product_fournisseur_price"); + $this->product_fourn_price_id = $this->db->last_insert_id($this->db->prefix()."product_fournisseur_price"); return 1; } else { $this->error = $this->db->lasterror(); @@ -4290,7 +4302,7 @@ class Product extends CommonObject $list = array(); $sql = "SELECT DISTINCT p.fk_soc"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_fournisseur_price as p"; + $sql .= " FROM ".$this->db->prefix()."product_fournisseur_price as p"; $sql .= " WHERE p.fk_product = ".((int) $this->id); $sql .= " AND p.entity = ".((int) $conf->entity); @@ -4325,7 +4337,7 @@ class Product extends CommonObject $this->db->begin(); // prices - $sql = "INSERT INTO ".MAIN_DB_PREFIX."product_price ("; + $sql = "INSERT INTO ".$this->db->prefix()."product_price ("; $sql .= " entity"; $sql .= ", fk_product"; $sql .= ", date_price"; @@ -4378,7 +4390,7 @@ class Product extends CommonObject $sql .= ", multicurrency_tx"; $sql .= ", multicurrency_price"; $sql .= ", multicurrency_price_ttc"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_price"; + $sql .= " FROM ".$this->db->prefix()."product_price"; $sql .= " WHERE fk_product = ".((int) $fromId); $sql .= " ORDER BY date_price DESC"; if ($conf->global->PRODUIT_MULTIPRICES_LIMIT > 0) { @@ -4409,8 +4421,8 @@ class Product extends CommonObject // phpcs:enable $this->db->begin(); - $sql = 'INSERT INTO '.MAIN_DB_PREFIX.'product_association (fk_product_pere, fk_product_fils, qty)'; - $sql .= " SELECT ".$toId.", fk_product_fils, qty FROM ".MAIN_DB_PREFIX."product_association"; + $sql = 'INSERT INTO '.$this->db->prefix().'product_association (fk_product_pere, fk_product_fils, qty)'; + $sql .= " SELECT ".$toId.", fk_product_fils, qty FROM ".$this->db->prefix()."product_association"; $sql .= " WHERE fk_product_pere = ".((int) $fromId); dol_syslog(get_class($this).'::clone_association', LOG_DEBUG); @@ -4439,10 +4451,10 @@ class Product extends CommonObject $now = dol_now(); // les fournisseurs - /*$sql = "INSERT ".MAIN_DB_PREFIX."product_fournisseur (" + /*$sql = "INSERT ".$this->db->prefix()."product_fournisseur (" . " datec, fk_product, fk_soc, ref_fourn, fk_user_author )" . " SELECT '".$this->db->idate($now)."', ".$toId.", fk_soc, ref_fourn, fk_user_author" - . " FROM ".MAIN_DB_PREFIX."product_fournisseur" + . " FROM ".$this->db->prefix()."product_fournisseur" . " WHERE fk_product = ".((int) $fromId); if ( ! $this->db->query($sql ) ) @@ -4452,10 +4464,10 @@ class Product extends CommonObject }*/ // les prix de fournisseurs. - $sql = "INSERT ".MAIN_DB_PREFIX."product_fournisseur_price ("; + $sql = "INSERT ".$this->db->prefix()."product_fournisseur_price ("; $sql .= " datec, fk_product, fk_soc, price, quantity, fk_user)"; $sql .= " SELECT '".$this->db->idate($now)."', ".((int) $toId).", fk_soc, price, quantity, fk_user"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_fournisseur_price"; + $sql .= " FROM ".$this->db->prefix()."product_fournisseur_price"; $sql .= " WHERE fk_product = ".((int) $fromId); dol_syslog(get_class($this).'::clone_fournisseurs', LOG_DEBUG); @@ -4573,7 +4585,7 @@ class Product extends CommonObject $nb = 0; $sql = "SELECT COUNT(pa.rowid) as nb"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_association as pa"; + $sql .= " FROM ".$this->db->prefix()."product_association as pa"; if ($mode == 0) { $sql .= " WHERE pa.fk_product_fils = ".((int) $this->id)." OR pa.fk_product_pere = ".((int) $this->id); } elseif ($mode == -1) { @@ -4603,7 +4615,7 @@ class Product extends CommonObject public function hasVariants() { $nb = 0; - $sql = "SELECT count(rowid) as nb FROM ".MAIN_DB_PREFIX."product_attribute_combination WHERE fk_product_parent = ".((int) $this->id); + $sql = "SELECT count(rowid) as nb FROM ".$this->db->prefix()."product_attribute_combination WHERE fk_product_parent = ".((int) $this->id); $sql .= " AND entity IN (".getEntity('product').")"; $resql = $this->db->query($sql); @@ -4627,7 +4639,7 @@ class Product extends CommonObject { global $conf; if (!empty($conf->variants->enabled)) { - $sql = "SELECT rowid FROM ".MAIN_DB_PREFIX."product_attribute_combination WHERE fk_product_child = ".((int) $this->id)." AND entity IN (".getEntity('product').")"; + $sql = "SELECT rowid FROM ".$this->db->prefix()."product_attribute_combination WHERE fk_product_child = ".((int) $this->id)." AND entity IN (".getEntity('product').")"; $query = $this->db->query($sql); @@ -4655,8 +4667,8 @@ class Product extends CommonObject { $sql = "SELECT p.rowid, p.label as label, p.ref as ref, pa.fk_product_pere as id, p.fk_product_type, pa.qty, pa.incdec, p.entity"; $sql .= ", p.tosell as status, p.tobuy as status_buy"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_association as pa,"; - $sql .= " ".MAIN_DB_PREFIX."product as p"; + $sql .= " FROM ".$this->db->prefix()."product_association as pa,"; + $sql .= " ".$this->db->prefix()."product as p"; $sql .= " WHERE p.rowid = pa.fk_product_pere"; $sql .= " AND pa.fk_product_fils = ".((int) $this->id); @@ -4702,8 +4714,8 @@ class Product extends CommonObject $sql = "SELECT p.rowid, p.ref, p.label as label, p.fk_product_type,"; $sql .= " pa.qty as qty, pa.fk_product_fils as id, pa.incdec,"; $sql .= " pa.rowid as fk_association, pa.rang"; - $sql .= " FROM ".MAIN_DB_PREFIX."product as p,"; - $sql .= " ".MAIN_DB_PREFIX."product_association as pa"; + $sql .= " FROM ".$this->db->prefix()."product as p,"; + $sql .= " ".$this->db->prefix()."product_association as pa"; $sql .= " WHERE p.rowid = pa.fk_product_fils"; $sql .= " AND pa.fk_product_pere = ".((int) $id); $sql .= " AND pa.fk_product_fils <> ".((int) $id); // This should not happens, it is to avoid infinite loop if it happens @@ -4800,9 +4812,10 @@ class Product extends CommonObject if (!empty($this->entity)) { $tmpphoto = $this->show_photos('product', $conf->product->multidir_output[$this->entity], 1, 1, 0, 0, 0, 80); if ($this->nbphoto > 0) { - $label .= '
    '; + $label .= '
    '; $label .= $tmpphoto; - $label .= '
    '; + $label .= '
    '; + //$label .= '
    '; } } @@ -4930,7 +4943,7 @@ class Product extends CommonObject global $action; $hookmanager->initHooks(array('productdao')); - $parameters = array('id'=>$this->id, 'getnomurl'=>$result); + $parameters = array('id'=>$this->id, 'getnomurl' => &$result); $reshook = $hookmanager->executeHooks('getNomUrl', $parameters, $this, $action); // Note that $action and $object may have been modified by some hooks if ($reshook > 0) { $result = $hookmanager->resPrint; @@ -5087,7 +5100,7 @@ class Product extends CommonObject $langs->load('products'); if (isset($this->finished) && $this->finished >= 0) { - $sql = "SELECT label, code FROM ".MAIN_DB_PREFIX."c_product_nature where code = ".((int) $this->finished)." AND active=1"; + $sql = "SELECT label, code FROM ".$this->db->prefix()."c_product_nature where code = ".((int) $this->finished)." AND active=1"; $resql = $this->db->query($sql); if ($resql && $this->db->num_rows($resql) > 0) { $res = $this->db->fetch_array($resql); @@ -5119,9 +5132,10 @@ class Product extends CommonObject * @param string $origin_element Origin element type * @param int $origin_id Origin id of element * @param int $disablestockchangeforsubproduct Disable stock change for sub-products of kit (usefull only if product is a subproduct) - * @return int <0 if KO, >0 if OK + * @param array $extrafields Array of extrafields + * @return int <0 if KO, >0 if OK */ - public function correct_stock($user, $id_entrepot, $nbpiece, $movement, $label = '', $price = 0, $inventorycode = '', $origin_element = '', $origin_id = null, $disablestockchangeforsubproduct = 0) + public function correct_stock($user, $id_entrepot, $nbpiece, $movement, $label = '', $price = 0, $inventorycode = '', $origin_element = '', $origin_id = null, $disablestockchangeforsubproduct = 0, $extrafields = null) { // phpcs:enable if ($id_entrepot) { @@ -5144,6 +5158,11 @@ class Product extends CommonObject $result = $movementstock->_create($user, $this->id, $id_entrepot, $op[$movement], $movement, $price, $label, $inventorycode, '', '', '', '', false, 0, $disablestockchangeforsubproduct); if ($result >= 0) { + if ($extrafields) { + $array_options = $extrafields->getOptionalsFromPost('stock_mouvement'); + $movementstock->array_options = $array_options; + $movementstock->insertExtraFields(); + } $this->db->commit(); return 1; } else { @@ -5173,9 +5192,10 @@ class Product extends CommonObject * @param string $origin_element Origin element type * @param int $origin_id Origin id of element * @param int $disablestockchangeforsubproduct Disable stock change for sub-products of kit (usefull only if product is a subproduct) + * @param array $extrafields Array of extrafields * @return int <0 if KO, >0 if OK */ - public function correct_stock_batch($user, $id_entrepot, $nbpiece, $movement, $label = '', $price = 0, $dlc = '', $dluo = '', $lot = '', $inventorycode = '', $origin_element = '', $origin_id = null, $disablestockchangeforsubproduct = 0) + public function correct_stock_batch($user, $id_entrepot, $nbpiece, $movement, $label = '', $price = 0, $dlc = '', $dluo = '', $lot = '', $inventorycode = '', $origin_element = '', $origin_id = null, $disablestockchangeforsubproduct = 0, $extrafields = null) { // phpcs:enable if ($id_entrepot) { @@ -5198,6 +5218,11 @@ class Product extends CommonObject $result = $movementstock->_create($user, $this->id, $id_entrepot, $op[$movement], $movement, $price, $label, $inventorycode, '', $dlc, $dluo, $lot, false, 0, $disablestockchangeforsubproduct); if ($result >= 0) { + if ($extrafields) { + $array_options = $extrafields->getOptionalsFromPost('stock_mouvement'); + $movementstock->array_options = $array_options; + $movementstock->insertExtraFields(); + } $this->db->commit(); return 1; } else { @@ -5248,8 +5273,8 @@ class Product extends CommonObject } $sql = "SELECT ps.rowid, ps.reel, ps.fk_entrepot"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_stock as ps"; - $sql .= ", ".MAIN_DB_PREFIX."entrepot as w"; + $sql .= " FROM ".$this->db->prefix()."product_stock as ps"; + $sql .= ", ".$this->db->prefix()."entrepot as w"; $sql .= " WHERE w.entity IN (".getEntity('stock').")"; $sql .= " AND w.rowid = ps.fk_entrepot"; $sql .= " AND ps.fk_product = ".((int) $this->id); @@ -5345,7 +5370,20 @@ class Product extends CommonObject } $stock_commande_fournisseur = $this->stats_commande_fournisseur['qty']; } + if (((!empty($conf->fournisseur->enabled) && empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD)) || !empty($conf->supplier_order->enabled) || !empty($conf->supplier_invoice->enabled)) && empty($conf->reception->enabled)) { + // Case module reception is not used + $filterStatus = '4'; + if (isset($includedraftpoforvirtual)) { + $filterStatus = '0,'.$filterStatus; + } + $result = $this->load_stats_reception(0, $filterStatus, 1); + if ($result < 0) { + dol_print_error($this->db, $this->error); + } + $stock_reception_fournisseur = $this->stats_reception['qty']; + } if (((!empty($conf->fournisseur->enabled) && empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD)) || !empty($conf->supplier_order->enabled) || !empty($conf->supplier_invoice->enabled)) && !empty($conf->reception->enabled)) { + // Case module reception is used $filterStatus = '4'; if (isset($includedraftpoforvirtual)) { $filterStatus = '0,'.$filterStatus; @@ -5412,7 +5450,7 @@ class Product extends CommonObject { $result = array(); - $sql = "SELECT pb.batch, pb.eatby, pb.sellby, SUM(pb.qty) AS qty FROM ".MAIN_DB_PREFIX."product_batch as pb, ".MAIN_DB_PREFIX."product_stock as ps"; + $sql = "SELECT pb.batch, pb.eatby, pb.sellby, SUM(pb.qty) AS qty FROM ".$this->db->prefix()."product_batch as pb, ".$this->db->prefix()."product_stock as ps"; $sql .= " WHERE pb.fk_product_stock = ps.rowid AND ps.fk_product = ".((int) $this->id)." AND pb.batch = '".$this->db->escape($batch)."'"; $sql .= " GROUP BY pb.batch, pb.eatby, pb.sellby"; dol_syslog(get_class($this)."::loadBatchInfo load first entry found for lot/serial = ".$batch, LOG_DEBUG); @@ -5646,7 +5684,7 @@ class Product extends CommonObject $this->nb = array(); $sql = "SELECT count(p.rowid) as nb, fk_product_type"; - $sql .= " FROM ".MAIN_DB_PREFIX."product as p"; + $sql .= " FROM ".$this->db->prefix()."product as p"; $sql .= ' WHERE p.entity IN ('.getEntity($this->element, 1).')'; // Add where from hooks if (is_object($hookmanager)) { @@ -5804,7 +5842,7 @@ class Product extends CommonObject $label_type = 'short_label'; } - $sql = "SELECT ".$label_type.", code from ".MAIN_DB_PREFIX."c_units where rowid = ".((int) $this->fk_unit); + $sql = "SELECT ".$label_type.", code from ".$this->db->prefix()."c_units where rowid = ".((int) $this->fk_unit); $resql = $this->db->query($sql); if ($resql && $this->db->num_rows($resql) > 0) { @@ -5912,7 +5950,7 @@ class Product extends CommonObject { global $conf, $db; - $sql = "SELECT rowid, level, fk_level, var_percent, var_min_percent FROM ".MAIN_DB_PREFIX."product_pricerules"; + $sql = "SELECT rowid, level, fk_level, var_percent, var_min_percent FROM ".$this->db->prefix()."product_pricerules"; $query = $this->db->query($sql); $rules = array(); @@ -5985,7 +6023,7 @@ class Product extends CommonObject { $sql = "SELECT p.rowid, p.ref, p.datec as date_creation, p.tms as date_modification,"; $sql .= " p.fk_user_author, p.fk_user_modif"; - $sql .= " FROM ".MAIN_DB_PREFIX.$this->table_element." as p"; + $sql .= " FROM ".$this->db->prefix().$this->table_element." as p"; $sql .= " WHERE p.rowid = ".((int) $id); $result = $this->db->query($sql); diff --git a/htdocs/product/class/productbatch.class.php b/htdocs/product/class/productbatch.class.php index 9bd361858ba..790a7aace44 100644 --- a/htdocs/product/class/productbatch.class.php +++ b/htdocs/product/class/productbatch.class.php @@ -87,7 +87,7 @@ class Productbatch extends CommonObject // Put here code to add control on parameters values // Insert request - $sql = "INSERT INTO ".MAIN_DB_PREFIX."product_batch ("; + $sql = "INSERT INTO ".$this->db->prefix()."product_batch ("; $sql .= "fk_product_stock,"; $sql .= "sellby,"; // no more used $sql .= "eatby,"; // no more used @@ -111,7 +111,7 @@ class Productbatch extends CommonObject $error++; $this->errors[] = "Error ".$this->db->lasterror(); } if (!$error) { - $this->id = $this->db->last_insert_id(MAIN_DB_PREFIX.self::$_table_element); + $this->id = $this->db->last_insert_id($this->db->prefix().self::$_table_element); } // Commit or rollback @@ -149,8 +149,8 @@ class Productbatch extends CommonObject $sql .= " pl.eatby,"; $sql .= " pl.sellby"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_batch as t INNER JOIN ".MAIN_DB_PREFIX."product_stock w on t.fk_product_stock = w.rowid"; - $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."product_lot as pl on pl.fk_product = w.fk_product and pl.batch = t.batch"; + $sql .= " FROM ".$this->db->prefix()."product_batch as t INNER JOIN ".$this->db->prefix()."product_stock w on t.fk_product_stock = w.rowid"; + $sql .= " LEFT JOIN ".$this->db->prefix()."product_lot as pl on pl.fk_product = w.fk_product and pl.batch = t.batch"; $sql .= " WHERE t.rowid = ".((int) $id); dol_syslog(get_class($this)."::fetch", LOG_DEBUG); @@ -199,7 +199,7 @@ class Productbatch extends CommonObject } // Update request - $sql = "UPDATE ".MAIN_DB_PREFIX.self::$_table_element." SET"; + $sql = "UPDATE ".$this->db->prefix().self::$_table_element." SET"; $sql .= " fk_product_stock=".(isset($this->fk_product_stock) ? $this->fk_product_stock : "null").","; $sql .= " sellby=".(dol_strlen($this->sellby) != 0 ? "'".$this->db->idate($this->sellby)."'" : 'null').","; $sql .= " eatby=".(dol_strlen($this->eatby) != 0 ? "'".$this->db->idate($this->eatby)."'" : 'null').","; @@ -245,7 +245,7 @@ class Productbatch extends CommonObject $this->db->begin(); if (!$error) { - $sql = "DELETE FROM ".MAIN_DB_PREFIX.self::$_table_element.""; + $sql = "DELETE FROM ".$this->db->prefix().self::$_table_element.""; $sql .= " WHERE rowid=".((int) $this->id); dol_syslog(get_class($this)."::delete", LOG_DEBUG); @@ -383,7 +383,7 @@ class Productbatch extends CommonObject $sql .= " t.batch,"; $sql .= " t.qty,"; $sql .= " t.import_key"; - $sql .= " FROM ".MAIN_DB_PREFIX.self::$_table_element." as t"; + $sql .= " FROM ".$this->db->prefix().self::$_table_element." as t"; $sql .= " WHERE fk_product_stock=".((int) $fk_product_stock); if (!empty($eatby)) { @@ -428,15 +428,15 @@ class Productbatch extends CommonObject /** * Return all batch detail records for a given product and warehouse * - * @param DoliDB $db database object + * @param DoliDB $dbs database object * @param int $fk_product_stock id product_stock for objet * @param int $with_qty 1 = doesn't return line with 0 quantity * @param int $fk_product If set to a product id, get eatby and sellby from table llx_product_lot * @return array <0 if KO, array of batch */ - public static function findAll($db, $fk_product_stock, $with_qty = 0, $fk_product = 0) + public static function findAll($dbs, $fk_product_stock, $with_qty = 0, $fk_product = 0) { - global $langs, $conf; + global $conf; $ret = array(); @@ -453,9 +453,9 @@ class Productbatch extends CommonObject $sql .= ", pl.rowid as lotid, pl.eatby as eatby, pl.sellby as sellby"; // TODO May add extrafields to ? } - $sql .= " FROM ".MAIN_DB_PREFIX."product_batch as t"; + $sql .= " FROM ".$dbs->prefix()."product_batch as t"; if ($fk_product > 0) { - $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."product_lot as pl ON pl.fk_product = ".((int) $fk_product)." AND pl.batch = t.batch"; + $sql .= " LEFT JOIN ".$dbs->prefix()."product_lot as pl ON pl.fk_product = ".((int) $fk_product)." AND pl.batch = t.batch"; // TODO May add extrafields to ? } $sql .= " WHERE fk_product_stock=".((int) $fk_product_stock); @@ -470,20 +470,20 @@ class Productbatch extends CommonObject $sql .= ", t.qty ".(!empty($conf->global->DO_NOT_TRY_TO_DEFRAGMENT_STOCKS_WAREHOUSE)?'DESC':'ASC'); // Note : qty ASC is important for expedition card, to avoid stock fragmentation dol_syslog("productbatch::findAll", LOG_DEBUG); - $resql = $db->query($sql); + $resql = $dbs->query($sql); if ($resql) { - $num = $db->num_rows($resql); + $num = $dbs->num_rows($resql); $i = 0; while ($i < $num) { - $obj = $db->fetch_object($resql); + $obj = $dbs->fetch_object($resql); - $tmp = new Productbatch($db); + $tmp = new Productbatch($dbs); $tmp->id = $obj->rowid; $tmp->lotid = $obj->lotid; - $tmp->tms = $db->jdate($obj->tms); + $tmp->tms = $dbs->jdate($obj->tms); $tmp->fk_product_stock = $obj->fk_product_stock; - $tmp->sellby = $db->jdate($obj->sellby ? $obj->sellby : $obj->oldsellby); - $tmp->eatby = $db->jdate($obj->eatby ? $obj->eatby : $obj->oldeatby); + $tmp->sellby = $dbs->jdate($obj->sellby ? $obj->sellby : $obj->oldsellby); + $tmp->eatby = $dbs->jdate($obj->eatby ? $obj->eatby : $obj->oldeatby); $tmp->batch = $obj->batch; $tmp->qty = $obj->qty; $tmp->import_key = $obj->import_key; @@ -491,11 +491,11 @@ class Productbatch extends CommonObject $ret[$tmp->batch] = $tmp; // $ret is for a $fk_product_stock and unique key is on $fk_product_stock+batch $i++; } - $db->free($resql); + $dbs->free($resql); return $ret; } else { - $error = "Error ".$db->lasterror(); + $error = "Error ".$dbs->lasterror(); return -1; } } @@ -503,7 +503,6 @@ class Productbatch extends CommonObject /** * Return all batch for a product and a warehouse * - * @param DoliDB $db Database object * @param int $fk_product Id of product * @param int $fk_warehouse Id of warehouse * @param int $qty_min [=NULL] Minimum quantity @@ -513,7 +512,7 @@ class Productbatch extends CommonObject * * @throws Exception */ - public static function findAllForProduct($db, $fk_product, $fk_warehouse = 0, $qty_min = null, $sortfield = null, $sortorder = null) + public function findAllForProduct($fk_product, $fk_warehouse = 0, $qty_min = null, $sortfield = null, $sortorder = null) { $productBatchList = array(); @@ -526,10 +525,10 @@ class Productbatch extends CommonObject $sql .= ", pl.sellby"; $sql .= ", pl.eatby"; $sql .= ", pb.qty"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_lot as pl"; - $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."product as p ON p.rowid = pl.fk_product"; - $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."product_batch AS pb ON pl.batch = pb.batch"; - $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."product_stock AS ps ON ps.rowid = pb.fk_product_stock"; + $sql .= " FROM ".$this->db->prefix()."product_lot as pl"; + $sql .= " LEFT JOIN ".$this->db->prefix()."product as p ON p.rowid = pl.fk_product"; + $sql .= " LEFT JOIN ".$this->db->prefix()."product_batch AS pb ON pl.batch = pb.batch"; + $sql .= " LEFT JOIN ".$this->db->prefix()."product_stock AS ps ON ps.rowid = pb.fk_product_stock"; $sql .= " WHERE p.entity IN (".getEntity('product').")"; $sql .= " AND pl.fk_product = ".((int) $fk_product); if ($fk_warehouse > 0) { @@ -538,25 +537,25 @@ class Productbatch extends CommonObject if ($qty_min !== null) { $sql .= " AND pb.qty > ".((float) price2num($qty_min, 'MS')); } - $sql .= $db->order($sortfield, $sortorder); + $sql .= $this->db->order($sortfield, $sortorder); - $resql = $db->query($sql); + $resql = $this->db->query($sql); if ($resql) { - while ($obj = $db->fetch_object($resql)) { - $productBatch = new self($db); + while ($obj = $this->db->fetch_object($resql)) { + $productBatch = new self($this->db); $productBatch->id = $obj->rowid; $productBatch->fk_product = $obj->fk_product; $productBatch->batch = $obj->batch; - $productBatch->eatby = $db->jdate($obj->eatby); - $productBatch->sellby = $db->jdate($obj->sellby); + $productBatch->eatby = $this->db->jdate($obj->eatby); + $productBatch->sellby = $this->db->jdate($obj->sellby); $productBatch->qty = $obj->qty; $productBatchList[] = $productBatch; } - $db->free($resql); + $this->db->free($resql); return $productBatchList; } else { - dol_syslog(__METHOD__.' Error: '.$db->lasterror(), LOG_ERR); + dol_syslog(__METHOD__.' Error: '.$this->db->lasterror(), LOG_ERR); return -1; } } diff --git a/htdocs/product/class/productcustomerprice.class.php b/htdocs/product/class/productcustomerprice.class.php index 407eac7c30a..1c91c3804d2 100644 --- a/htdocs/product/class/productcustomerprice.class.php +++ b/htdocs/product/class/productcustomerprice.class.php @@ -188,7 +188,7 @@ class Productcustomerprice extends CommonObject } // Insert request - $sql = "INSERT INTO ".MAIN_DB_PREFIX."product_customer_price("; + $sql = "INSERT INTO ".$this->db->prefix()."product_customer_price("; $sql .= "entity,"; $sql .= "datec,"; $sql .= "fk_product,"; @@ -240,7 +240,7 @@ class Productcustomerprice extends CommonObject } if (!$error) { - $this->id = $this->db->last_insert_id(MAIN_DB_PREFIX."product_customer_price"); + $this->id = $this->db->last_insert_id($this->db->prefix()."product_customer_price"); if (!$notrigger) { $result = $this->call_trigger('PRODUCT_CUSTOMER_PRICE_CREATE', $user); @@ -301,7 +301,7 @@ class Productcustomerprice extends CommonObject $sql .= " t.localtax2_tx,"; $sql .= " t.fk_user,"; $sql .= " t.import_key"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_customer_price as t"; + $sql .= " FROM ".$this->db->prefix()."product_customer_price as t"; $sql .= " WHERE t.rowid = ".((int) $id); dol_syslog(get_class($this)."::fetch", LOG_DEBUG); @@ -392,9 +392,9 @@ class Productcustomerprice extends CommonObject $sql .= " t.import_key,"; $sql .= " soc.nom as socname,"; $sql .= " prod.ref as prodref"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_customer_price as t "; - $sql .= " ,".MAIN_DB_PREFIX."product as prod "; - $sql .= " ,".MAIN_DB_PREFIX."societe as soc "; + $sql .= " FROM ".$this->db->prefix()."product_customer_price as t,"; + $sql .= " ".$this->db->prefix()."product as prod,"; + $sql .= " ".$this->db->prefix()."societe as soc"; $sql .= " WHERE soc.rowid=t.fk_soc "; $sql .= " AND prod.rowid=t.fk_product "; $sql .= " AND prod.entity IN (".getEntity('product').")"; @@ -510,9 +510,9 @@ class Productcustomerprice extends CommonObject $sql .= " t.import_key,"; $sql .= " soc.nom as socname,"; $sql .= " prod.ref as prodref"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_customer_price_log as t"; - $sql .= " ,".MAIN_DB_PREFIX."product as prod"; - $sql .= " ,".MAIN_DB_PREFIX."societe as soc"; + $sql .= " FROM ".$this->db->prefix()."product_customer_price_log as t"; + $sql .= " ,".$this->db->prefix()."product as prod"; + $sql .= " ,".$this->db->prefix()."societe as soc"; $sql .= " WHERE soc.rowid=t.fk_soc"; $sql .= " AND prod.rowid=t.fk_product "; $sql .= " AND prod.entity IN (".getEntity('product').")"; @@ -675,7 +675,7 @@ class Productcustomerprice extends CommonObject // Do a copy of current record into log table // Insert request - $sql = "INSERT INTO ".MAIN_DB_PREFIX."product_customer_price_log("; + $sql = "INSERT INTO ".$this->db->prefix()."product_customer_price_log("; $sql .= "entity,"; $sql .= "datec,"; @@ -720,7 +720,7 @@ class Productcustomerprice extends CommonObject $sql .= " t.fk_user,"; $sql .= " t.import_key"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_customer_price as t"; + $sql .= " FROM ".$this->db->prefix()."product_customer_price as t"; $sql .= " WHERE t.rowid = ".((int) $this->id); $this->db->begin(); @@ -732,7 +732,7 @@ class Productcustomerprice extends CommonObject } // Update request - $sql = "UPDATE ".MAIN_DB_PREFIX."product_customer_price SET"; + $sql = "UPDATE ".$this->db->prefix()."product_customer_price SET"; $sql .= " entity=".$conf->entity.","; $sql .= " datec='".$this->db->idate(dol_now())."',"; @@ -813,7 +813,7 @@ class Productcustomerprice extends CommonObject // Find all susidiaries $sql = "SELECT s.rowid"; - $sql .= " FROM ".MAIN_DB_PREFIX."societe as s"; + $sql .= " FROM ".$this->db->prefix()."societe as s"; $sql .= " WHERE s.parent = ".((int) $this->fk_soc); $sql .= " AND s.entity IN (".getEntity('societe').")"; @@ -911,7 +911,7 @@ class Productcustomerprice extends CommonObject } if (!$error) { - $sql = "DELETE FROM ".MAIN_DB_PREFIX."product_customer_price"; + $sql = "DELETE FROM ".$this->db->prefix()."product_customer_price"; $sql .= " WHERE rowid=".((int) $this->id); dol_syslog(get_class($this)."::delete", LOG_DEBUG); diff --git a/htdocs/product/class/productfournisseurprice.class.php b/htdocs/product/class/productfournisseurprice.class.php index d82d1784938..ef9b2a49117 100644 --- a/htdocs/product/class/productfournisseurprice.class.php +++ b/htdocs/product/class/productfournisseurprice.class.php @@ -316,11 +316,11 @@ class ProductFournisseurPrice extends CommonObject $records = array(); - $sql = 'SELECT '; + $sql = "SELECT "; $sql .= $this->getFieldList(); - $sql .= ' FROM '.MAIN_DB_PREFIX.$this->table_element.' as t'; - if (isset($this->ismultientitymanaged) && $this->ismultientitymanaged == 1) $sql .= ' WHERE t.entity IN ('.getEntity($this->element).')'; - else $sql .= ' WHERE 1 = 1'; + $sql .= " FROM ".$this->db->prefix().$this->table_element." as t"; + if (isset($this->ismultientitymanaged) && $this->ismultientitymanaged == 1) $sql .= " WHERE t.entity IN (".getEntity($this->element).")"; + else $sql .= " WHERE 1 = 1"; // Manage filter $sqlwhere = array(); if (count($filter) > 0) { @@ -433,7 +433,7 @@ class ProductFournisseurPrice extends CommonObject if (!empty($num)) { // Validate - $sql = "UPDATE ".MAIN_DB_PREFIX.$this->table_element; + $sql = "UPDATE ".$this->db->prefix().$this->table_element; $sql .= " SET ref = '".$this->db->escape($num)."',"; $sql .= " status = ".self::STATUS_VALIDATED; if (!empty($this->fields['date_validation'])) $sql .= ", date_validation = '".$this->db->idate($now)."'"; @@ -462,7 +462,7 @@ class ProductFournisseurPrice extends CommonObject // Rename directory if dir was a temporary ref if (preg_match('/^[\(]?PROV/i', $this->ref)) { // Now we rename also files into index - $sql = 'UPDATE '.MAIN_DB_PREFIX."ecm_files set filename = CONCAT('".$this->db->escape($this->newref)."', SUBSTR(filename, ".(strlen($this->ref) + 1).")), filepath = 'productfournisseurprice/".$this->db->escape($this->newref)."'"; + $sql = 'UPDATE '.$this->db->prefix()."ecm_files set filename = CONCAT('".$this->db->escape($this->newref)."', SUBSTR(filename, ".(strlen($this->ref) + 1).")), filepath = 'productfournisseurprice/".$this->db->escape($this->newref)."'"; $sql .= " WHERE filename LIKE '".$this->db->escape($this->ref)."%' AND filepath = 'productfournisseurprice/".$this->db->escape($this->ref)."' and entity = ".$conf->entity; $resql = $this->db->query($sql); if (!$resql) { $error++; $this->error = $this->db->lasterror(); } @@ -642,7 +642,7 @@ class ProductFournisseurPrice extends CommonObject global $action, $hookmanager; $hookmanager->initHooks(array('productfournisseurpricedao')); - $parameters = array('id'=>$this->id, 'getnomurl'=>$result); + $parameters = array('id'=>$this->id, 'getnomurl' => &$result); $reshook = $hookmanager->executeHooks('getNomUrl', $parameters, $this, $action); // Note that $action and $object may have been modified by some hooks if ($reshook > 0) $result = $hookmanager->resPrint; else $result .= $hookmanager->resPrint; @@ -698,10 +698,10 @@ class ProductFournisseurPrice extends CommonObject */ public function info($id) { - $sql = 'SELECT rowid, date_creation as datec, tms as datem,'; - $sql .= ' fk_user_creat, fk_user_modif'; - $sql .= ' FROM '.MAIN_DB_PREFIX.$this->table_element.' as t'; - $sql .= ' WHERE t.rowid = '.((int) $id); + $sql = "SELECT rowid, date_creation as datec, tms as datem,"; + $sql .= " fk_user_creat, fk_user_modif"; + $sql .= " FROM ".$this->db->prefix().$this->table_element." as t"; + $sql .= " WHERE t.rowid = ".((int) $id); $result = $this->db->query($sql); if ($result) { if ($this->db->num_rows($result)) { diff --git a/htdocs/product/class/propalmergepdfproduct.class.php b/htdocs/product/class/propalmergepdfproduct.class.php index 9663bea4756..00c492f91de 100644 --- a/htdocs/product/class/propalmergepdfproduct.class.php +++ b/htdocs/product/class/propalmergepdfproduct.class.php @@ -104,7 +104,7 @@ class Propalmergepdfproduct extends CommonObject // Put here code to add control on parameters values // Insert request - $sql = "INSERT INTO ".MAIN_DB_PREFIX."propal_merge_pdf_product("; + $sql = "INSERT INTO ".$this->db->prefix()."propal_merge_pdf_product("; $sql .= "fk_product,"; $sql .= "file_name,"; if ($conf->global->MAIN_MULTILANGS) { @@ -132,7 +132,7 @@ class Propalmergepdfproduct extends CommonObject } if (!$error) { - $this->id = $this->db->last_insert_id(MAIN_DB_PREFIX."propal_merge_pdf_product"); + $this->id = $this->db->last_insert_id($this->db->prefix()."propal_merge_pdf_product"); } // Commit or rollback @@ -173,7 +173,7 @@ class Propalmergepdfproduct extends CommonObject $sql .= " t.import_key"; - $sql .= " FROM ".MAIN_DB_PREFIX."propal_merge_pdf_product as t"; + $sql .= " FROM ".$this->db->prefix()."propal_merge_pdf_product as t"; $sql .= " WHERE t.rowid = ".((int) $id); dol_syslog(__METHOD__, LOG_DEBUG); @@ -231,7 +231,7 @@ class Propalmergepdfproduct extends CommonObject $sql .= " t.import_key"; - $sql .= " FROM ".MAIN_DB_PREFIX."propal_merge_pdf_product as t"; + $sql .= " FROM ".$this->db->prefix()."propal_merge_pdf_product as t"; $sql .= " WHERE t.fk_product = ".((int) $product_id); if (!empty($conf->global->MAIN_MULTILANGS) && !empty($lang)) { $sql .= " AND t.lang = '".$this->db->escape($lang)."'"; @@ -307,7 +307,7 @@ class Propalmergepdfproduct extends CommonObject // Put here code to add a control on parameters values // Update request - $sql = "UPDATE ".MAIN_DB_PREFIX."propal_merge_pdf_product SET"; + $sql = "UPDATE ".$this->db->prefix()."propal_merge_pdf_product SET"; $sql .= " fk_product=".(isset($this->fk_product) ? $this->fk_product : "null").","; $sql .= " file_name=".(isset($this->file_name) ? "'".$this->db->escape($this->file_name)."'" : "null").","; @@ -357,7 +357,7 @@ class Propalmergepdfproduct extends CommonObject $this->db->begin(); if (!$error) { - $sql = "DELETE FROM ".MAIN_DB_PREFIX."propal_merge_pdf_product"; + $sql = "DELETE FROM ".$this->db->prefix()."propal_merge_pdf_product"; $sql .= " WHERE rowid=".((int) $this->id); dol_syslog(__METHOD__, LOG_DEBUG); @@ -400,7 +400,7 @@ class Propalmergepdfproduct extends CommonObject $this->db->begin(); if (!$error) { - $sql = "DELETE FROM ".MAIN_DB_PREFIX."propal_merge_pdf_product"; + $sql = "DELETE FROM ".$this->db->prefix()."propal_merge_pdf_product"; $sql .= " WHERE fk_product = ".((int) $product_id); if ($conf->global->MAIN_MULTILANGS && !empty($lang_id)) { @@ -444,7 +444,7 @@ class Propalmergepdfproduct extends CommonObject $this->db->begin(); if (!$error) { - $sql = "DELETE FROM ".MAIN_DB_PREFIX."propal_merge_pdf_product"; + $sql = "DELETE FROM ".$this->db->prefix()."propal_merge_pdf_product"; $sql .= " WHERE fk_product = ".((int) $this->fk_product)." AND file_name = '".$this->db->escape($this->file_name)."'"; dol_syslog(__METHOD__, LOG_DEBUG); diff --git a/htdocs/product/composition/card.php b/htdocs/product/composition/card.php index 2cecfc84bc4..d5325029771 100644 --- a/htdocs/product/composition/card.php +++ b/htdocs/product/composition/card.php @@ -339,7 +339,7 @@ if ($id > 0 || !empty($ref)) { print ''; // Rank - print ''; + print ''; // Product ref print ''; // Product label @@ -401,8 +401,8 @@ if ($id > 0 || !empty($ref)) { $totalline = price2num($value['nb'] * ($fourn_unitprice * (1 - ($fourn_remise_percent / 100)) - $fourn_remise), 'MT'); $total += $totalline; - print ''; // Best selling price @@ -414,11 +414,11 @@ if ($id > 0 || !empty($ref)) { $totalsell += $totallinesell; } print ''; @@ -603,6 +603,7 @@ if ($id > 0 || !empty($ref)) { print ''; print ''; print ''; + print '
    '; +print '
    '; print $langs->trans("ONLINE_PAYMENT_SENDEMAIL").''; print ''; print '   '.$langs->trans("Example").': myemail@myserver.com, Payment service <myemail2@myserver2.com>'; diff --git a/htdocs/paybox/lib/paybox.lib.php b/htdocs/paybox/lib/paybox.lib.php index e5f53b34978..7f41d45d374 100644 --- a/htdocs/paybox/lib/paybox.lib.php +++ b/htdocs/paybox/lib/paybox.lib.php @@ -218,7 +218,7 @@ function print_paybox_redirect($PRICE, $CURRENCY, $EMAIL, $urlok, $urlko, $TAG) print "\n"; - print ''."\n"; print "\n"; diff --git a/htdocs/paypal/admin/paypal.php b/htdocs/paypal/admin/paypal.php index f4edec7630c..df5bb4161a5 100644 --- a/htdocs/paypal/admin/paypal.php +++ b/htdocs/paypal/admin/paypal.php @@ -350,7 +350,7 @@ $sandboxpaypalurl = 'developer.paypal.com'; print '
    '; print 'Your API authentication information can be found with following steps. We recommend that you open a separate Web browser session when carrying out this procedure.
    -1. Log in to your PayPal account (on real paypal '.$realpaypalurl.' (or sandbox '.$sandboxpaypalurl.').
    +1. Log in to your PayPal account (on real paypal '.$realpaypalurl.' (or sandbox '.$sandboxpaypalurl.').
    2. Click the "Profile" or "Preferencies" subtab located under the My Account heading.
    3. Click the link "API Access".
    4. Click the View API Certificate link in the right column.
    diff --git a/htdocs/paypal/lib/paypal.lib.php b/htdocs/paypal/lib/paypal.lib.php index 16e728512f6..79003956f12 100644 --- a/htdocs/paypal/lib/paypal.lib.php +++ b/htdocs/paypal/lib/paypal.lib.php @@ -498,9 +498,20 @@ function hash_call($methodName, $nvpStr) // TLSv1 by default or change to TLSv1.2 in module configuration curl_setopt($ch, CURLOPT_SSLVERSION, (empty($conf->global->PAYPAL_SSLVERSION) ? 1 : $conf->global->PAYPAL_SSLVERSION)); + $ssl_verifypeer = -1; + + // Turning on or off the ssl target certificate + if ($ssl_verifypeer < 0) { + global $dolibarr_main_prod; + $ssl_verifypeer = ($dolibarr_main_prod ? true : false); + } + if (!empty($conf->global->MAIN_CURL_DISABLE_VERIFYPEER)) { + $ssl_verifypeer = 0; + } + //turning off the server and peer verification(TrustManager Concept). - curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false); - curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false); + curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, ($ssl_verifypeer ? true : false)); + curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, ($ssl_verifypeer ? true : false)); curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, empty($conf->global->MAIN_USE_CONNECT_TIMEOUT) ? 5 : $conf->global->MAIN_USE_CONNECT_TIMEOUT); curl_setopt($ch, CURLOPT_TIMEOUT, empty($conf->global->MAIN_USE_RESPONSE_TIMEOUT) ? 30 : $conf->global->MAIN_USE_RESPONSE_TIMEOUT); diff --git a/htdocs/product/admin/inventory_extrafields.php b/htdocs/product/admin/inventory_extrafields.php new file mode 100644 index 00000000000..d21328da336 --- /dev/null +++ b/htdocs/product/admin/inventory_extrafields.php @@ -0,0 +1,123 @@ + + * Copyright (C) 2003 Jean-Louis Bergamo + * Copyright (C) 2004-2011 Laurent Destailleur + * Copyright (C) 2012 Regis Houssin + * Copyright (C) 2014 Florian Henry + * Copyright (C) 2015 Jean-François Ferry + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file htdocs/product/admin/inventory_extrafields.php + * \ingroup stock + * \brief Page to setup extra fields of inventory + */ + +// Load Dolibarr environment +$res = 0; +// Try main.inc.php into web root known defined into CONTEXT_DOCUMENT_ROOT (not always defined) +if (!$res && !empty($_SERVER["CONTEXT_DOCUMENT_ROOT"])) $res = @include $_SERVER["CONTEXT_DOCUMENT_ROOT"]."/main.inc.php"; +// Try main.inc.php into web root detected using web root calculated from SCRIPT_FILENAME +$tmp = empty($_SERVER['SCRIPT_FILENAME']) ? '' : $_SERVER['SCRIPT_FILENAME']; $tmp2 = realpath(__FILE__); $i = strlen($tmp) - 1; $j = strlen($tmp2) - 1; +while ($i > 0 && $j > 0 && isset($tmp[$i]) && isset($tmp2[$j]) && $tmp[$i] == $tmp2[$j]) { $i--; $j--; } +if (!$res && $i > 0 && file_exists(substr($tmp, 0, ($i + 1))."/main.inc.php")) $res = @include substr($tmp, 0, ($i + 1))."/main.inc.php"; +if (!$res && $i > 0 && file_exists(dirname(substr($tmp, 0, ($i + 1)))."/main.inc.php")) $res = @include dirname(substr($tmp, 0, ($i + 1)))."/main.inc.php"; +// Try main.inc.php using relative path +if (!$res && file_exists("../../main.inc.php")) $res = @include "../../main.inc.php"; +if (!$res && file_exists("../../../main.inc.php")) $res = @include "../../../main.inc.php"; +if (!$res) die("Include of main fails"); + +require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php'; +require_once DOL_DOCUMENT_ROOT.'/core/lib/stock.lib.php'; + +// Load translation files required by the page +$langs->loadLangs(array('stock@stock', 'admin')); + +$extrafields = new ExtraFields($db); +$form = new Form($db); + +// List of supported format +$tmptype2label = ExtraFields::$type2label; +$type2label = array(''); +foreach ($tmptype2label as $key => $val) $type2label[$key] = $langs->transnoentitiesnoconv($val); + +$action = GETPOST('action', 'aZ09'); +$attrname = GETPOST('attrname', 'alpha'); +$elementtype = 'inventory'; //Must be the $table_element of the class that manage extrafield + +if (!$user->admin) accessforbidden(); + + +/* + * Actions + */ + +require DOL_DOCUMENT_ROOT.'/core/actions_extrafields.inc.php'; + + + +/* + * View + */ + + +llxHeader('', $langs->trans("InventorySetup"), $help_url); + + +$linkback = ''.$langs->trans("BackToModuleList").''; +print load_fiche_titre($langs->trans("InventorySetup"), $linkback, 'title_setup'); + + +$head = stock_admin_prepare_head(); + +print dol_get_fiche_head($head, 'inventoryAttributes', $langs->trans("InventoryExtraFields"), -1, 'account'); + +require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_view.tpl.php'; + +print dol_get_fiche_end(); + + +// Buttons +if ($action != 'create' && $action != 'edit') { + print '
    '; + print "".$langs->trans("NewAttribute").""; + print "
    "; +} + + +/* + * Creation of an optional field + */ +if ($action == 'create') { + print '
    '; + print load_fiche_titre($langs->trans('NewAttribute')); + + require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_add.tpl.php'; +} + +/* + * Edition of an optional field + */ +if ($action == 'edit' && !empty($attrname)) { + print "
    "; + print load_fiche_titre($langs->trans("FieldEdition", $attrname)); + + require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_edit.tpl.php'; +} + +// End of page +llxFooter(); +$db->close(); diff --git a/htdocs/product/admin/product.php b/htdocs/product/admin/product.php index 4f6094e1787..2d7d99a9ab3 100644 --- a/htdocs/product/admin/product.php +++ b/htdocs/product/admin/product.php @@ -46,6 +46,8 @@ if (!$user->admin || (empty($conf->product->enabled) && empty($conf->service->en $action = GETPOST('action', 'aZ09'); $value = GETPOST('value', 'alpha'); +$modulepart = GETPOST('modulepart', 'aZ09'); // Used by actions_setmoduleoptions.inc.php + $label = GETPOST('label', 'alpha'); $scandir = GETPOST('scan_dir', 'alpha'); $type = 'product'; diff --git a/htdocs/product/admin/stock_mouvement_extrafields.php b/htdocs/product/admin/stock_mouvement_extrafields.php new file mode 100644 index 00000000000..23e5aadc9cc --- /dev/null +++ b/htdocs/product/admin/stock_mouvement_extrafields.php @@ -0,0 +1,123 @@ + + * Copyright (C) 2003 Jean-Louis Bergamo + * Copyright (C) 2004-2011 Laurent Destailleur + * Copyright (C) 2012 Regis Houssin + * Copyright (C) 2014 Florian Henry + * Copyright (C) 2015 Jean-François Ferry + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + +/** + * \file htdocs/product/admin/stock_mouvement_extrafields.php + * \ingroup stock + * \brief Page to setup extra fields of stock mouvement + */ + +// Load Dolibarr environment +$res = 0; +// Try main.inc.php into web root known defined into CONTEXT_DOCUMENT_ROOT (not always defined) +if (!$res && !empty($_SERVER["CONTEXT_DOCUMENT_ROOT"])) $res = @include $_SERVER["CONTEXT_DOCUMENT_ROOT"]."/main.inc.php"; +// Try main.inc.php into web root detected using web root calculated from SCRIPT_FILENAME +$tmp = empty($_SERVER['SCRIPT_FILENAME']) ? '' : $_SERVER['SCRIPT_FILENAME']; $tmp2 = realpath(__FILE__); $i = strlen($tmp) - 1; $j = strlen($tmp2) - 1; +while ($i > 0 && $j > 0 && isset($tmp[$i]) && isset($tmp2[$j]) && $tmp[$i] == $tmp2[$j]) { $i--; $j--; } +if (!$res && $i > 0 && file_exists(substr($tmp, 0, ($i + 1))."/main.inc.php")) $res = @include substr($tmp, 0, ($i + 1))."/main.inc.php"; +if (!$res && $i > 0 && file_exists(dirname(substr($tmp, 0, ($i + 1)))."/main.inc.php")) $res = @include dirname(substr($tmp, 0, ($i + 1)))."/main.inc.php"; +// Try main.inc.php using relative path +if (!$res && file_exists("../../main.inc.php")) $res = @include "../../main.inc.php"; +if (!$res && file_exists("../../../main.inc.php")) $res = @include "../../../main.inc.php"; +if (!$res) die("Include of main fails"); + +require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php'; +require_once DOL_DOCUMENT_ROOT.'/core/lib/stock.lib.php'; + +// Load translation files required by the page +$langs->loadLangs(array('stock@stock', 'admin')); + +$extrafields = new ExtraFields($db); +$form = new Form($db); + +// List of supported format +$tmptype2label = ExtraFields::$type2label; +$type2label = array(''); +foreach ($tmptype2label as $key => $val) $type2label[$key] = $langs->transnoentitiesnoconv($val); + +$action = GETPOST('action', 'aZ09'); +$attrname = GETPOST('attrname', 'alpha'); +$elementtype = 'stock_mouvement'; //Must be the $table_element of the class that manage extrafield + +if (!$user->admin) accessforbidden(); + + +/* + * Actions + */ + +require DOL_DOCUMENT_ROOT.'/core/actions_extrafields.inc.php'; + + + +/* + * View + */ + + +llxHeader('', $langs->trans("StockSetup"), $help_url); + + +$linkback = ''.$langs->trans("BackToModuleList").''; +print load_fiche_titre($langs->trans("StockSetup"), $linkback, 'title_setup'); + + +$head = stock_admin_prepare_head(); + +print dol_get_fiche_head($head, 'stockMouvementAttributes', $langs->trans("StockMouvementExtraFields"), -1, 'account'); + +require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_view.tpl.php'; + +print dol_get_fiche_end(); + + +// Buttons +if ($action != 'create' && $action != 'edit') { + print '
    '; + print "".$langs->trans("NewAttribute").""; + print "
    "; +} + + +/* + * Creation of an optional field + */ +if ($action == 'create') { + print '
    '; + print load_fiche_titre($langs->trans('NewAttribute')); + + require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_add.tpl.php'; +} + +/* + * Edition of an optional field + */ +if ($action == 'edit' && !empty($attrname)) { + print "
    "; + print load_fiche_titre($langs->trans("FieldEdition", $attrname)); + + require DOL_DOCUMENT_ROOT.'/core/tpl/admin_extrafields_edit.tpl.php'; +} + +// End of page +llxFooter(); +$db->close(); diff --git a/htdocs/product/agenda.php b/htdocs/product/agenda.php index 815014e259f..40d451653e7 100644 --- a/htdocs/product/agenda.php +++ b/htdocs/product/agenda.php @@ -54,8 +54,8 @@ if ($user->socid) { } $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/product/ajax/products.php b/htdocs/product/ajax/products.php index 84562bf95a4..74fa53dccb8 100644 --- a/htdocs/product/ajax/products.php +++ b/htdocs/product/ajax/products.php @@ -47,11 +47,12 @@ if (empty($_GET['keysearch']) && !defined('NOREQUIREHTML')) { require '../../main.inc.php'; -$htmlname = GETPOST('htmlname', 'alpha'); +$htmlname = GETPOST('htmlname', 'aZ09'); $socid = GETPOST('socid', 'int'); $type = GETPOST('type', 'int'); $mode = GETPOST('mode', 'int'); -$status = ((GETPOST('status', 'int') >= 0) ? GETPOST('status', 'int') : - 1); +$status = ((GETPOST('status', 'int') >= 0) ? GETPOST('status', 'int') : - 1); // status buy when mode = customer , status purchase when mode = supplier +$status_purchase = ((GETPOST('status_purchase', 'int') >= 0) ? GETPOST('status_purchase', 'int') : - 1); // status purchase when mode = customer $outjson = (GETPOST('outjson', 'int') ? GETPOST('outjson', 'int') : 0); $price_level = GETPOST('price_level', 'int'); $action = GETPOST('action', 'aZ09'); @@ -73,7 +74,7 @@ restrictedArea($user, 'produit|service', 0, 'product&product'); // print ''."\n"; // print_r($_GET); -if (!empty($action) && $action == 'fetch' && !empty($id)) { +if ($action == 'fetch' && !empty($id)) { // action='fetch' is used to get product information on a product. So when action='fetch', id must be the product id. require_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php'; require_once DOL_DOCUMENT_ROOT.'/societe/class/societe.class.php'; @@ -85,10 +86,15 @@ if (!empty($action) && $action == 'fetch' && !empty($id)) { if ($ret > 0) { $outref = $object->ref; $outlabel = $object->label; - $outlabel_trans =''; + $outlabel_trans = ''; $outdesc = $object->description; - $outdesc_trans =''; + $outdesc_trans = ''; $outtype = $object->type; + $outprice_ht = null; + $outprice_ttc = null; + $outpricebasetype = null; + $outtva_tx = 0; + $outdefault_vat_code = ''; $outqty = 1; $outdiscount = 0; $mandatory_period = $object->mandatory_period; @@ -132,17 +138,21 @@ if (!empty($action) && $action == 'fetch' && !empty($id)) { $found = true; $outprice_ht = price($objp->unitprice); $outprice_ttc = price($objp->unitprice * (1 + ($object->tva_tx / 100))); + $outpricebasetype = $object->price_base_type; $outtva_tx = $object->tva_tx; + $outdefault_vat_code = $object->default_vat_code; + $outqty = $objp->quantity; $outdiscount = $objp->remise_percent; } } } - // Multiprice + // Multiprice (1 price per level) if (!$found && isset($price_level) && $price_level >= 1 && (!empty($conf->global->PRODUIT_MULTIPRICES) || !empty($conf->global->PRODUIT_CUSTOMER_PRICES_BY_QTY_MULTIPRICES))) { // If we need a particular price level (from 1 to 6) - $sql = "SELECT price, price_ttc, price_base_type, tva_tx"; + $sql = "SELECT price, price_ttc, price_base_type,"; + $sql .= " tva_tx, default_vat_code"; // Vat rate and code will be used if PRODUIT_MULTIPRICES_USE_VAT_PER_LEVEL is on. $sql .= " FROM ".MAIN_DB_PREFIX."product_price "; $sql .= " WHERE fk_product = ".((int) $id); $sql .= " AND entity IN (".getEntity('productprice').")"; @@ -158,7 +168,14 @@ if (!empty($action) && $action == 'fetch' && !empty($id)) { $outprice_ht = price($objp->price); $outprice_ttc = price($objp->price_ttc); $outpricebasetype = $objp->price_base_type; - $outtva_tx = $objp->tva_tx; + if (!empty($conf->global->PRODUIT_MULTIPRICES_USE_VAT_PER_LEVEL)) { + $outtva_tx = $objp->tva_tx; + $outdefault_vat_code = $objp->default_vat_code; + } else { + // The common and default behaviour. + $outtva_tx = $object->tva_tx; + $outdefault_vat_code = $object->default_vat_code; + } } } } @@ -175,10 +192,11 @@ if (!empty($action) && $action == 'fetch' && !empty($id)) { if ($result) { if (count($prodcustprice->lines) > 0) { $found = true; - $outprice_ht = price($prodcustprice->lines [0]->price); - $outprice_ttc = price($prodcustprice->lines [0]->price_ttc); - $outpricebasetype = $prodcustprice->lines [0]->price_base_type; - $outtva_tx = $prodcustprice->lines [0]->tva_tx; + $outprice_ht = price($prodcustprice->lines[0]->price); + $outprice_ttc = price($prodcustprice->lines[0]->price_ttc); + $outpricebasetype = $prodcustprice->lines[0]->price_base_type; + $outtva_tx = $prodcustprice->lines[0]->tva_tx; + $outdefault_vat_code = $prodcustprice->lines[0]->default_vat_code; } } } @@ -188,6 +206,7 @@ if (!empty($action) && $action == 'fetch' && !empty($id)) { $outprice_ttc = price($object->price_ttc); $outpricebasetype = $object->price_base_type; $outtva_tx = $object->tva_tx; + $outdefault_vat_code = $object->default_vat_code; } $outjson = array( @@ -201,6 +220,7 @@ if (!empty($action) && $action == 'fetch' && !empty($id)) { 'price_ttc' => $outprice_ttc, 'pricebasetype' => $outpricebasetype, 'tva_tx' => $outtva_tx, + 'default_vat_code' => $outdefault_vat_code, 'qty' => $outqty, 'discount' => $outdiscount, 'mandatory_period' => $mandatory_period, @@ -223,7 +243,7 @@ if (!empty($action) && $action == 'fetch' && !empty($id)) { // Filter on the product to search can be: // Into an array with key $htmlname123 (we take first one found). Which page use this ? // Into a var with name $htmlname can be 'prodid', 'productid', ... - $match = preg_grep('/('.$htmlname.'[0-9]+)/', array_keys($_GET)); + $match = preg_grep('/('.preg_quote($htmlname, '/').'[0-9]+)/', array_keys($_GET)); sort($match); $idprod = (empty($match[0]) ? '' : $match[0]); // Take first key found into GET array with matching $htmlname123 @@ -241,7 +261,7 @@ if (!empty($action) && $action == 'fetch' && !empty($id)) { } if (empty($mode) || $mode == 1) { // mode=1: customer - $arrayresult = $form->select_produits_list("", $htmlname, $type, 0, $price_level, $searchkey, $status, $finished, $outjson, $socid, '1', 0, '', $hidepriceinlabel, $warehouseStatus); + $arrayresult = $form->select_produits_list("", $htmlname, $type, 0, $price_level, $searchkey, $status, $finished, $outjson, $socid, '1', 0, '', $hidepriceinlabel, $warehouseStatus, $status_purchase); } elseif ($mode == 2) { // mode=2: supplier $arrayresult = $form->select_produits_fournisseurs_list($socid, "", $htmlname, $type, "", $searchkey, $status, $outjson, 0, $alsoproductwithnosupplierprice); } diff --git a/htdocs/product/canvas/service/actions_card_service.class.php b/htdocs/product/canvas/service/actions_card_service.class.php index c4296dc63a8..b07c3d96a52 100644 --- a/htdocs/product/canvas/service/actions_card_service.class.php +++ b/htdocs/product/canvas/service/actions_card_service.class.php @@ -39,6 +39,13 @@ class ActionsCardService public $field_list = array(); public $list_datas = array(); + public $id; + public $ref; + public $description; + public $note; + public $price; + public $price_min; + /** * Constructor @@ -196,6 +203,7 @@ class ActionsCardService } // Duration + $dur = array(); if ($this->object->duration_value > 1) { $dur = array("h"=>$langs->trans("Hours"), "d"=>$langs->trans("Days"), "w"=>$langs->trans("Weeks"), "m"=>$langs->trans("Months"), "y"=>$langs->trans("Years")); } elseif ($this->object->duration_value > 0) { @@ -286,6 +294,7 @@ class ActionsCardService if ($search_categ) { $sql .= ", ".MAIN_DB_PREFIX."categorie_product as cp"; } + $fourn_id = 0; if (GETPOST("fourn_id", 'int') > 0) { $fourn_id = GETPOST("fourn_id", 'int'); $sql .= ", ".MAIN_DB_PREFIX."product_fournisseur_price as pfp"; diff --git a/htdocs/product/card.php b/htdocs/product/card.php index dd4fd64a28c..64c6b6817bd 100644 --- a/htdocs/product/card.php +++ b/htdocs/product/card.php @@ -1870,40 +1870,40 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($action)) { if (empty($conf->global->PRODUCT_DISABLE_WEIGHT)) { // Brut Weight print '
    '.$langs->trans("Weight").''; - print ' '; - print $formproduct->selectMeasuringUnits("weight_units", "weight", $object->weight_units, 0, 2); + print ' '; + print $formproduct->selectMeasuringUnits("weight_units", "weight", GETPOSTISSET('weight_units') ? GETPOST('weight_units') : $object->weight_units, 0, 2); print '
    '.$langs->trans("Length").' x '.$langs->trans("Width").' x '.$langs->trans("Height").''; - print 'x'; - print 'x'; - print ' '; - print $formproduct->selectMeasuringUnits("size_units", "size", $object->length_units, 0, 2); + print 'x'; + print 'x'; + print ' '; + print $formproduct->selectMeasuringUnits("size_units", "size", GETPOSTISSET('size_units') ? GETPOST('size_units') : $object->length_units, 0, 2); print '
    '.$langs->trans("Surface").''; - print ' '; - print $formproduct->selectMeasuringUnits("surface_units", "surface", $object->surface_units, 0, 2); + print ' '; + print $formproduct->selectMeasuringUnits("surface_units", "surface", GETPOSTISSET('surface_units') ? GETPOST('surface_units') : $object->surface_units, 0, 2); print '
    '.$langs->trans("Volume").''; - print ' '; - print $formproduct->selectMeasuringUnits("volume_units", "volume", $object->volume_units, 0, 2); + print ' '; + print $formproduct->selectMeasuringUnits("volume_units", "volume", GETPOSTISSET('volume_units') ? GETPOST('volume_units') : $object->volume_units, 0, 2); print '
    '.$langs->trans("NetMeasure").''; - print ' '; - print $formproduct->selectMeasuringUnits("net_measure_units", "", $object->net_measure_units, 0, 0); + print ' '; + print $formproduct->selectMeasuringUnits("net_measure_units", "", GETPOSTISSET('net_measure_units') ? GETPOST('net_measure_units') : $object->net_measure_units, 0, 0); print '
    '.$langs->trans("ManageLotSerial").''; print $object->getLibStatut(0, 2); print '
    '.$langs->trans("ManageLotMask").''; print $object->batch_mask; print '
    '.$langs->trans('Rank').''.$langs->trans('Position').''.$langs->trans('ComposedProduct').''; - print ($notdefined ? '' : ($value['nb'] > 1 ? $value['nb'].'x' : '').price($unitline, '', '', 0, 0, -1, $conf->currency)); + print ''; + print ($notdefined ? '' : ($value['nb'] > 1 ? $value['nb'].'x ' : '').''.price($unitline, '', '', 0, 0, -1, $conf->currency)).''; print ''; - print ($notdefined ? '' : ($value['nb'] > 1 ? $value['nb'].'x' : '')); + print ($notdefined ? '' : ($value['nb'] > 1 ? $value['nb'].'x ' : '')); if (is_numeric($pricesell)) { - print price($pricesell, '', '', 0, 0, -1, $conf->currency); + print ''.price($pricesell, '', '', 0, 0, -1, $conf->currency).''; } else { - print $langs->trans($pricesell); + print ''.$langs->trans($pricesell).''; } print '
    '; print ''; print ''; @@ -931,7 +930,7 @@ END; 'pfp.fk_availability'=>array('label'=>$langs->trans("Availability"), 'enabled' => !empty($conf->global->FOURN_PRODUCT_AVAILABILITY), 'checked'=>0, 'position'=>4), 'pfp.quantity'=>array('label'=>$langs->trans("QtyMin"), 'checked'=>1, 'position'=>5), 'pfp.unitprice'=>array('label'=>$langs->trans("UnitPriceHT"), 'checked'=>1, 'position'=>9), - 'pfp.multicurrency_unitprice'=>array('label'=>$langs->trans("UnitPriceHTCurrency"), 'enabled' => $conf->multicurrency->enabled, 'checked'=>0, 'position'=>10), + 'pfp.multicurrency_unitprice'=>array('label'=>$langs->trans("UnitPriceHTCurrency"), 'enabled' => (!empty($conf->multicurrency->enabled)), 'checked'=>0, 'position'=>10), 'pfp.delivery_time_days'=>array('label'=>$langs->trans("NbDaysToDelivery"), 'checked'=>1, 'position'=>13), 'pfp.supplier_reputation'=>array('label'=>$langs->trans("ReputationForThisProduct"), 'checked'=>1, 'position'=>14), 'pfp.fk_barcode_type'=>array('label'=>$langs->trans("BarcodeType"), 'enabled' => $conf->barcode->enabled, 'checked'=>0, 'position'=>15), @@ -942,14 +941,19 @@ END; // fetch optionals attributes and labels $extrafields->fetch_name_optionals_label("product_fournisseur_price"); - $extralabels = $extrafields->attributes["product_fournisseur_price"]['label']; + if ($extrafields->attributes["product_fournisseur_price"] && array_key_exists('label', $extrafields->attributes["product_fournisseur_price"])) { + $extralabels = $extrafields->attributes["product_fournisseur_price"]['label']; - if (!empty($extralabels)) { - foreach ($extralabels as $key => $value) { - // Show field if not hidden - if (!empty($extrafields->attributes["product_fournisseur_price"]['list'][$key]) && $extrafields->attributes["product_fournisseur_price"]['list'][$key] != 3) { - $extratitle = $langs->trans($value); - $arrayfields['ef.'.$key] = array('label'=>$extratitle, 'checked'=>0, 'position'=>(end($arrayfields)['position'] + 1), 'langfile'=>$extrafields->attributes["product_fournisseur_price"]['langfile'][$key], 'help'=>$extrafields->attributes["product_fournisseur_price"]['help'][$key]); + if (!empty($extralabels)) { + foreach ($extralabels as $key => $value) { + // Show field if not hidden + if (!empty($extrafields->attributes["product_fournisseur_price"]['list'][$key]) && $extrafields->attributes["product_fournisseur_price"]['list'][$key] != 3) { + $extratitle = $langs->trans($value); + $arrayfields['ef.' . $key] = array('label' => $extratitle, 'checked' => 0, + 'position' => (end($arrayfields)['position'] + 1), + 'langfile' => $extrafields->attributes["product_fournisseur_price"]['langfile'][$key], + 'help' => $extrafields->attributes["product_fournisseur_price"]['help'][$key]); + } } } } @@ -1023,29 +1027,31 @@ END; // fetch optionals attributes and labels $extrafields->fetch_name_optionals_label("product_fournisseur_price"); - $extralabels = $extrafields->attributes["product_fournisseur_price"]['label']; + if ($extrafields->attributes["product_fournisseur_price"] && array_key_exists('label', $extrafields->attributes["product_fournisseur_price"])) { + $extralabels = $extrafields->attributes["product_fournisseur_price"]['label']; - if (!empty($extralabels)) { - foreach ($extralabels as $key => $value) { - // Show field if not hidden - if (!empty($extrafields->attributes["product_fournisseur_price"]['list'][$key]) && $extrafields->attributes["product_fournisseur_price"]['list'][$key] != 3) { - if (!empty($extrafields->attributes["product_fournisseur_price"]['langfile'][$key])) { - $langs->load($extrafields->attributes["product_fournisseur_price"]['langfile'][$key]); - } - if (!empty($extrafields->attributes["product_fournisseur_price"]['help'][$key])) { - $extratitle = $form->textwithpicto($langs->trans($value), $langs->trans($extrafields->attributes["product_fournisseur_price"]['help'][$key])); - } else { - $extratitle = $langs->trans($value); - } - if (!empty($arrayfields['ef.'.$key]['checked'])) { - print_liste_field_titre($extratitle, $_SERVER["PHP_SELF"], 'ef.'.$key, '', $param, '', $sortfield, $sortorder, 'right '); + if (!empty($extralabels)) { + foreach ($extralabels as $key => $value) { + // Show field if not hidden + if (!empty($extrafields->attributes["product_fournisseur_price"]['list'][$key]) && $extrafields->attributes["product_fournisseur_price"]['list'][$key] != 3) { + if (!empty($extrafields->attributes["product_fournisseur_price"]['langfile'][$key])) { + $langs->load($extrafields->attributes["product_fournisseur_price"]['langfile'][$key]); + } + if (!empty($extrafields->attributes["product_fournisseur_price"]['help'][$key])) { + $extratitle = $form->textwithpicto($langs->trans($value), $langs->trans($extrafields->attributes["product_fournisseur_price"]['help'][$key])); + } else { + $extratitle = $langs->trans($value); + } + if (!empty($arrayfields['ef.' . $key]['checked'])) { + print_liste_field_titre($extratitle, $_SERVER["PHP_SELF"], 'ef.' . $key, '', $param, '', $sortfield, $sortorder, 'right '); + } } } } } if (is_object($hookmanager)) { - $parameters = array('id_fourn'=>$id_fourn, 'prod_id'=>$object->id); + $parameters = array('id_fourn'=>(!empty($id_fourn)?$id_fourn:''), 'prod_id'=>$object->id); $reshook = $hookmanager->executeHooks('printFieldListTitle', $parameters, $object, $action); } print_liste_field_titre($selectedfields, $_SERVER["PHP_SELF"], "", '', '', '', $sortfield, $sortorder, 'center maxwidthsearch '); @@ -1204,7 +1210,7 @@ END; $obj = $db->fetch_object($resql); foreach ($extralabels as $key => $value) { if (!empty($arrayfields['ef.'.$key]['checked']) && !empty($extrafields->attributes["product_fournisseur_price"]['list'][$key]) && $extrafields->attributes["product_fournisseur_price"]['list'][$key] != 3) { - print '"; + print '"; } } } @@ -1213,7 +1219,7 @@ END; } if (is_object($hookmanager)) { - $parameters = array('id_pfp'=>$productfourn->product_fourn_price_id, 'id_fourn'=>$id_fourn, 'prod_id'=>$object->id); + $parameters = array('id_pfp'=>$productfourn->product_fourn_price_id, 'id_fourn'=>(!empty($id_fourn)?$id_fourn:''), 'prod_id'=>$object->id); $reshook = $hookmanager->executeHooks('printFieldListValue', $parameters, $object, $action); } diff --git a/htdocs/product/index.php b/htdocs/product/index.php index 082e8a4d8d2..e4a0bfc7421 100644 --- a/htdocs/product/index.php +++ b/htdocs/product/index.php @@ -225,6 +225,7 @@ if (!empty($conf->categorie->enabled) && !empty($conf->global->CATEGORY_GRAPHSTA $sql .= " WHERE c.type = 0"; $sql .= " AND c.entity IN (".getEntity('category').")"; $sql .= " GROUP BY c.label"; + $sql .= " ORDER BY nb desc"; $total = 0; $result = $db->query($sql); if ($result) { @@ -341,8 +342,8 @@ if ((!empty($conf->product->enabled) || !empty($conf->service->enabled)) && ($us if (!empty($conf->global->MAIN_MULTILANGS)) { $sql = "SELECT label"; $sql .= " FROM ".MAIN_DB_PREFIX."product_lang"; - $sql .= " WHERE fk_product=".((int) $objp->rowid); - $sql .= " AND lang='".$db->escape($langs->getDefaultLang())."'"; + $sql .= " WHERE fk_product = ".((int) $objp->rowid); + $sql .= " AND lang = '".$db->escape($langs->getDefaultLang())."'"; $resultd = $db->query($sql); if ($resultd) { diff --git a/htdocs/product/inventory/ajax/ajax.inventory.php b/htdocs/product/inventory/ajax/ajax.inventory.php deleted file mode 100644 index 920607f4c1e..00000000000 --- a/htdocs/product/inventory/ajax/ajax.inventory.php +++ /dev/null @@ -1,47 +0,0 @@ -rights->stock->creer)) { - echo -1; exit; - } - - $fk_det_inventory = GETPOST('fk_det_inventory'); - - $det = new InventoryLine($db); - if ($det->fetch($fk_det_inventory)) { - $det->qty_view += GETPOST('qty'); - $res = $det->update($user); - - echo $det->qty_view; - } else { - echo -2; - } - - break; - - case 'pmp': - if (empty($user->rights->stock->creer) || empty($user->rights->stock->changePMP)) { - echo -1; exit; - } - - $fk_det_inventory = GETPOST('fk_det_inventory'); - - $det = new InventoryLine($db); - if ($det->fetch($fk_det_inventory)) { - $det->new_pmp = price2num(GETPOST('pmp')); - $det->update($user); - - echo $det->new_pmp; - } else { - echo -2; - } - - break; -} diff --git a/htdocs/product/inventory/ajax/searchfrombarcode.php b/htdocs/product/inventory/ajax/searchfrombarcode.php new file mode 100644 index 00000000000..68ffee43c23 --- /dev/null +++ b/htdocs/product/inventory/ajax/searchfrombarcode.php @@ -0,0 +1,135 @@ +. + */ + +/** + * \file /htdocs/product/inventory/ajax/searchfrombarcode.php + * \brief File to make Ajax action on product and stock + */ + +if (!defined('NOTOKENRENEWAL')) { + define('NOTOKENRENEWAL', 1); // Disables token renewal +} +if (!defined('NOREQUIREMENU')) { + define('NOREQUIREMENU', '1'); +} +if (!defined('NOREQUIREHTML')) { + define('NOREQUIREHTML', '1'); +} +if (!defined('NOREQUIREAJAX')) { + define('NOREQUIREAJAX', '1'); +} +if (!defined('NOREQUIRESOC')) { + define('NOREQUIRESOC', '1'); +} +if (!defined('NOCSRFCHECK')) { + define('NOCSRFCHECK', '1'); +} +require '../../../main.inc.php'; +require_once DOL_DOCUMENT_ROOT."/product/stock/class/entrepot.class.php"; +$warehouse = new Entrepot($db); + +$action = GETPOST("action", "alpha"); +$barcode = GETPOST("barcode", "aZ09"); +$product = GETPOST("product"); +$response = ""; + +$fk_entrepot = GETPOST("fk_entrepot", "int"); +$fk_inventory = GETPOST("fk_inventory", "int"); +$fk_product = GETPOST("fk_product", "int"); +$reelqty = GETPOST("reelqty", "int"); +$batch = GETPOST("batch", "int"); +$mode = GETPOST("mode", "aZ"); + +$warehousefound = 0; +$warehouseid = 0; +$objectreturn = array(); + +if ($action == "existbarcode" && !empty($barcode)) { + if (!empty($mode) && $mode == "lotserial") { + $sql = "SELECT ps.fk_entrepot, ps.fk_product, p.barcode, ps.reel, pb.batch"; + $sql .= " FROM ".MAIN_DB_PREFIX."product_batch as pb"; + $sql .= " JOIN ".MAIN_DB_PREFIX."product_stock as ps ON pb.fk_product_stock = ps.rowid JOIN ".MAIN_DB_PREFIX."product as p ON ps.fk_product = p.rowid"; + $sql .= " WHERE pb.batch = '".$db->escape($barcode)."'"; + } else { + $sql = "SELECT ps.fk_entrepot, ps.fk_product, p.barcode,ps.reel"; + $sql .= " FROM ".MAIN_DB_PREFIX."product_stock as ps JOIN ".MAIN_DB_PREFIX."product as p ON ps.fk_product = p.rowid"; + $sql .= " WHERE p.barcode = '".$db->escape($barcode)."'"; + } + if (!empty($fk_entrepot)) { + $sql .= " AND ps.fk_entrepot = '".$db->escape($fk_entrepot)."'"; + } + if (!empty($fk_product)) { + $sql .= " AND ps.fk_product = '".$db->escape($fk_product)."'"; + } + $result = $db->query($sql); + if ($result) { + $nbline = $db->num_rows($result); + for ($i=0; $i < $nbline; $i++) { + $object = $db->fetch_object($result); + if (($mode == "barcode" && $barcode == $object->barcode) || ($mode == "lotserial" && $barcode == $object->batch)) { + $warehouse->fetch(0, $product["Warehouse"]); + if (!empty($object->fk_entrepot) && $warehouse->id == $object->fk_entrepot) { + $warehousefound++; + $warehouseid = $object->fk_entrepot; + $fk_product = $object->fk_product; + $reelqty = $object->reel; + + $objectreturn = array('fk_warehouse'=>$warehouseid,'fk_product'=>$fk_product,'reelqty'=>$reelqty); + } + } + } + if ($warehousefound < 1) { + $response = array('status'=>'error','errorcode'=>'NotFound','message'=>'No warehouse found for barcode'.$barcode); + } elseif ($warehousefound > 1) { + $response = array('status'=>'error','errorcode'=>'TooManyWarehouse','message'=>'Too many warehouse found'); + } else { + $response = array('status'=>'success','message'=>'Warehouse found','object'=>$objectreturn); + } + } else { + $response = array('status'=>'error','errorcode'=>'NotFound','message'=>"No results found for barcode"); + } +} else { + $response = array('status'=>'error','errorcode'=>'ActionError','message'=>"Error on action"); +} + +if ($action == "addnewlineproduct") { + require_once DOL_DOCUMENT_ROOT."/product/inventory/class/inventory.class.php"; + $inventoryline = new InventoryLine($db); + if (!empty($fk_inventory)) { + $inventoryline->fk_inventory = $fk_inventory; + + $inventoryline->fk_warehouse = $fk_entrepot; + $inventoryline->fk_product = $fk_product; + $inventoryline->qty_stock = $reelqty; + if (!empty($batch)) { + $inventoryline->batch = $batch; + } + $inventoryline->datec = dol_now(); + + $result = $inventoryline->create($user); + if ($result > 0) { + $response = array('status'=>'success','message'=>'Success on creating line','id_line'=>$result); + } else { + $response = array('status'=>'error','errorcode'=>'ErrorCreation','message'=>"Error on line creation"); + } + } else { + $response = array('status'=>'error','errorcode'=>'NoIdForInventory','message'=>"No id for inventory"); + } +} + +$response = json_encode($response); +echo $response; diff --git a/htdocs/product/inventory/card.php b/htdocs/product/inventory/card.php index b3a3fdc0b00..b71047a5f47 100644 --- a/htdocs/product/inventory/card.php +++ b/htdocs/product/inventory/card.php @@ -109,6 +109,7 @@ if ($reshook < 0) { } if (empty($reshook)) { + $savaction = $action; $error = 0; $backurlforlist = DOL_URL_ROOT.'/product/inventory/list.php'; @@ -152,6 +153,12 @@ if (empty($reshook)) { $autocopy = 'MAIN_MAIL_AUTOCOPY_INVENTORY_TO'; $trackid = 'stockinv'.$object->id; include DOL_DOCUMENT_ROOT.'/core/actions_sendmails.inc.php'; + + if (!$error && $savaction == 'confirm_validate' && $action == '' && $object->id > 0) { + // Switch to the tab inventory + header("Location: ".DOL_URL_ROOT.'/product/inventory/inventory.php?id='.$object->id); + exit; + } } @@ -189,9 +196,6 @@ if ($action == 'create') { print dol_get_fiche_head(array(), ''); - // Set some default values - //if (! GETPOSTISSET('fieldname')) $_POST['fieldname'] = 'myvalue'; - print '
    '.$langs->trans("ComposedProduct").''; diff --git a/htdocs/product/document.php b/htdocs/product/document.php index 230f8375538..79ff858ba6e 100644 --- a/htdocs/product/document.php +++ b/htdocs/product/document.php @@ -58,8 +58,8 @@ $hookmanager->initHooks(array('productdocuments')); // Get parameters $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/product/dynamic_price/class/price_expression.class.php b/htdocs/product/dynamic_price/class/price_expression.class.php index 564c2448e58..255908726d4 100644 --- a/htdocs/product/dynamic_price/class/price_expression.class.php +++ b/htdocs/product/dynamic_price/class/price_expression.class.php @@ -88,7 +88,7 @@ class PriceExpression } // Insert request - $sql = "INSERT INTO ".MAIN_DB_PREFIX.$this->table_element." ("; + $sql = "INSERT INTO ".$this->db->prefix().$this->table_element." ("; $sql .= "title, expression"; $sql .= ") VALUES ("; $sql .= " ".(isset($this->title) ? "'".$this->db->escape($this->title)."'" : "''").","; @@ -104,7 +104,7 @@ class PriceExpression } if (!$error) { - $this->id = $this->db->last_insert_id(MAIN_DB_PREFIX.$this->table_element); + $this->id = $this->db->last_insert_id($this->db->prefix().$this->table_element); //if (! $notrigger) //{ @@ -148,7 +148,7 @@ class PriceExpression } $sql = "SELECT title, expression"; - $sql .= " FROM ".MAIN_DB_PREFIX.$this->table_element; + $sql .= " FROM ".$this->db->prefix().$this->table_element; $sql .= " WHERE rowid = ".((int) $id); dol_syslog(__METHOD__); @@ -179,7 +179,7 @@ class PriceExpression { // phpcs:enable $sql = "SELECT rowid, title, expression"; - $sql .= " FROM ".MAIN_DB_PREFIX.$this->table_element; + $sql .= " FROM ".$this->db->prefix().$this->table_element; $sql .= " ORDER BY title"; dol_syslog(__METHOD__, LOG_DEBUG); @@ -215,7 +215,7 @@ class PriceExpression { // phpcs:enable $sql = "SELECT rowid"; - $sql .= " FROM ".MAIN_DB_PREFIX.$this->table_element; + $sql .= " FROM ".$this->db->prefix().$this->table_element; $sql .= " WHERE title = '".$this->db->escape($title)."'"; dol_syslog(__METHOD__, LOG_DEBUG); @@ -254,7 +254,7 @@ class PriceExpression } // Update request - $sql = "UPDATE ".MAIN_DB_PREFIX.$this->table_element." SET"; + $sql = "UPDATE ".$this->db->prefix().$this->table_element." SET"; $sql .= " title = ".(isset($this->title) ? "'".$this->db->escape($this->title)."'" : "''").","; $sql .= " expression = ".(isset($this->expression) ? "'".$this->db->escape($this->expression)."'" : "''").""; $sql .= " WHERE rowid = ".((int) $this->id); @@ -326,7 +326,7 @@ class PriceExpression //} if (!$error) { - $sql = "DELETE FROM ".MAIN_DB_PREFIX.$this->table_element; + $sql = "DELETE FROM ".$this->db->prefix().$this->table_element; $sql .= " WHERE rowid = ".((int) $rowid); dol_syslog(__METHOD__); diff --git a/htdocs/product/dynamic_price/class/price_global_variable.class.php b/htdocs/product/dynamic_price/class/price_global_variable.class.php index a7b22f2ef13..336fb024470 100644 --- a/htdocs/product/dynamic_price/class/price_global_variable.class.php +++ b/htdocs/product/dynamic_price/class/price_global_variable.class.php @@ -88,7 +88,7 @@ class PriceGlobalVariable $this->checkParameters(); // Insert request - $sql = "INSERT INTO ".MAIN_DB_PREFIX.$this->table_element." ("; + $sql = "INSERT INTO ".$this->db->prefix().$this->table_element." ("; $sql .= "code, description, value"; $sql .= ") VALUES ("; $sql .= " ".(isset($this->code) ? "'".$this->db->escape($this->code)."'" : "''").","; @@ -105,7 +105,7 @@ class PriceGlobalVariable } if (!$error) { - $this->id = $this->db->last_insert_id(MAIN_DB_PREFIX.$this->table_element); + $this->id = $this->db->last_insert_id($this->db->prefix().$this->table_element); if (!$notrigger) { // Uncomment this and change MYOBJECT to your own tag if you @@ -142,7 +142,7 @@ class PriceGlobalVariable public function fetch($id) { $sql = "SELECT code, description, value"; - $sql .= " FROM ".MAIN_DB_PREFIX.$this->table_element; + $sql .= " FROM ".$this->db->prefix().$this->table_element; $sql .= " WHERE rowid = ".((int) $id); dol_syslog(__METHOD__); @@ -179,7 +179,7 @@ class PriceGlobalVariable $this->checkParameters(); // Update request - $sql = "UPDATE ".MAIN_DB_PREFIX.$this->table_element." SET"; + $sql = "UPDATE ".$this->db->prefix().$this->table_element." SET"; $sql .= " code = ".(isset($this->code) ? "'".$this->db->escape($this->code)."'" : "''").","; $sql .= " description = ".(isset($this->description) ? "'".$this->db->escape($this->description)."'" : "''").","; $sql .= " value = ".((float) $this->value); @@ -249,7 +249,7 @@ class PriceGlobalVariable } if (!$error) { - $sql = "DELETE FROM ".MAIN_DB_PREFIX.$this->table_element; + $sql = "DELETE FROM ".$this->db->prefix().$this->table_element; $sql .= " WHERE rowid = ".((int) $rowid); dol_syslog(__METHOD__); @@ -316,7 +316,7 @@ class PriceGlobalVariable public function listGlobalVariables() { $sql = "SELECT rowid, code, description, value"; - $sql .= " FROM ".MAIN_DB_PREFIX.$this->table_element; + $sql .= " FROM ".$this->db->prefix().$this->table_element; $sql .= " ORDER BY code"; dol_syslog(__METHOD__, LOG_DEBUG); diff --git a/htdocs/product/dynamic_price/class/price_global_variable_updater.class.php b/htdocs/product/dynamic_price/class/price_global_variable_updater.class.php index 8a9c1197a7f..317bc7fb5fd 100644 --- a/htdocs/product/dynamic_price/class/price_global_variable_updater.class.php +++ b/htdocs/product/dynamic_price/class/price_global_variable_updater.class.php @@ -100,7 +100,7 @@ class PriceGlobalVariableUpdater $this->checkParameters(); // Insert request - $sql = "INSERT INTO ".MAIN_DB_PREFIX.$this->table_element." ("; + $sql = "INSERT INTO ".$this->db->prefix().$this->table_element." ("; $sql .= "type, description, parameters, fk_variable, update_interval, next_update, last_status"; $sql .= ") VALUES ("; $sql .= " ".((int) $this->type).","; @@ -121,7 +121,7 @@ class PriceGlobalVariableUpdater } if (!$error) { - $this->id = $this->db->last_insert_id(MAIN_DB_PREFIX.$this->table_element); + $this->id = $this->db->last_insert_id($this->db->prefix().$this->table_element); if (!$notrigger) { // Uncomment this and change MYOBJECT to your own tag if you @@ -158,7 +158,7 @@ class PriceGlobalVariableUpdater public function fetch($id) { $sql = "SELECT type, description, parameters, fk_variable, update_interval, next_update, last_status"; - $sql .= " FROM ".MAIN_DB_PREFIX.$this->table_element; + $sql .= " FROM ".$this->db->prefix().$this->table_element; $sql .= " WHERE rowid = ".((int) $id); dol_syslog(__METHOD__); @@ -199,7 +199,7 @@ class PriceGlobalVariableUpdater $this->checkParameters(); // Update request - $sql = "UPDATE ".MAIN_DB_PREFIX.$this->table_element." SET"; + $sql = "UPDATE ".$this->db->prefix().$this->table_element." SET"; $sql .= " type = ".((int) $this->type).","; $sql .= " description = ".(isset($this->description) ? "'".$this->db->escape($this->description)."'" : "''").","; $sql .= " parameters = ".(isset($this->parameters) ? "'".$this->db->escape($this->parameters)."'" : "''").","; @@ -274,7 +274,7 @@ class PriceGlobalVariableUpdater //} if (!$error) { - $sql = "DELETE FROM ".MAIN_DB_PREFIX.$this->table_element; + $sql = "DELETE FROM ".$this->db->prefix().$this->table_element; $sql .= " WHERE rowid = ".((int) $rowid); dol_syslog(__METHOD__); @@ -372,7 +372,7 @@ class PriceGlobalVariableUpdater public function listUpdaters() { $sql = "SELECT rowid, type, description, parameters, fk_variable, update_interval, next_update, last_status"; - $sql .= " FROM ".MAIN_DB_PREFIX.$this->table_element; + $sql .= " FROM ".$this->db->prefix().$this->table_element; dol_syslog(__METHOD__, LOG_DEBUG); $resql = $this->db->query($sql); @@ -409,7 +409,7 @@ class PriceGlobalVariableUpdater public function listPendingUpdaters() { $sql = "SELECT rowid, type, description, parameters, fk_variable, update_interval, next_update, last_status"; - $sql .= " FROM ".MAIN_DB_PREFIX.$this->table_element; + $sql .= " FROM ".$this->db->prefix().$this->table_element; $sql .= " WHERE next_update < ".dol_now(); dol_syslog(__METHOD__, LOG_DEBUG); @@ -568,7 +568,7 @@ class PriceGlobalVariableUpdater $this->checkParameters(); // Update request - $sql = "UPDATE ".MAIN_DB_PREFIX.$this->table_element." SET"; + $sql = "UPDATE ".$this->db->prefix().$this->table_element." SET"; $sql .= " next_update = ".$this->next_update; $sql .= " WHERE rowid = ".((int) $this->id); @@ -612,7 +612,7 @@ class PriceGlobalVariableUpdater $this->checkParameters(); // Update request - $sql = "UPDATE ".MAIN_DB_PREFIX.$this->table_element." SET"; + $sql = "UPDATE ".$this->db->prefix().$this->table_element." SET"; $sql .= " last_status = ".(isset($this->last_status) ? "'".$this->db->escape($this->last_status)."'" : "''"); $sql .= " WHERE rowid = ".((int) $this->id); diff --git a/htdocs/product/dynamic_price/class/price_parser.class.php b/htdocs/product/dynamic_price/class/price_parser.class.php index 3d28f4b6011..9bd986a3c73 100644 --- a/htdocs/product/dynamic_price/class/price_parser.class.php +++ b/htdocs/product/dynamic_price/class/price_parser.class.php @@ -263,13 +263,16 @@ class PriceParser return -1; } elseif ($res == 0) { $supplier_min_price = 0; + $supplier_min_price_with_discount = 0; } else { $supplier_min_price = $productFournisseur->fourn_unitprice; + $supplier_min_price_with_discount = $productFournisseur->fourn_unitprice_with_discount; } //Accessible values by expressions $extra_values = array_merge($extra_values, array( "supplier_min_price" => $supplier_min_price, + "supplier_min_price_with_discount" => $supplier_min_price_with_discount, )); //Parse the expression and return the price, if not error occurred check if price is higher than min @@ -329,12 +332,13 @@ class PriceParser //Values for product expressions $extra_values = array_merge($extra_values, array( "supplier_min_price" => 1, + "supplier_min_price_with_discount" => 2, )); //Values for supplier product expressions $extra_values = array_merge($extra_values, array( - "supplier_quantity" => 2, - "supplier_tva_tx" => 3, + "supplier_quantity" => 3, + "supplier_tva_tx" => 4, )); return $this->parseExpression($product, $expression, $extra_values); } diff --git a/htdocs/product/fournisseurs.php b/htdocs/product/fournisseurs.php index a3ae38184e9..3bf563c82f7 100644 --- a/htdocs/product/fournisseurs.php +++ b/htdocs/product/fournisseurs.php @@ -63,10 +63,9 @@ $error = 0; $extrafields = new ExtraFields($db); // If socid provided by ajax company selector -if (!empty($_REQUEST['search_fourn_id'])) { +if (GETPOST('search_fourn_id', 'int')) { $_GET['id_fourn'] = GETPOST('search_fourn_id', 'int'); $_POST['id_fourn'] = GETPOST('search_fourn_id', 'int'); - $_REQUEST['id_fourn'] = GETPOST('search_fourn_id', 'int'); } // Security check @@ -81,8 +80,8 @@ if (empty($user->rights->fournisseur->lire)) { } $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = (GETPOST("page", 'int') ?GETPOST("page", 'int') : 0); if (empty($page) || $page == -1) { $page = 0; @@ -518,7 +517,7 @@ if ($id > 0 || $ref) { } else { $events = array(); $events[] = array('method' => 'getVatRates', 'url' => dol_buildpath('/core/ajax/vatrates.php', 1), 'htmlname' => 'tva_tx', 'params' => array()); - print $form->select_company(GETPOST("id_fourn", 'alpha'), 'id_fourn', 'fournisseur=1', 'SelectThirdParty', 0, 0, $events); + print img_picto('', 'company', 'class="pictofixedwidth"').$form->select_company(GETPOST("id_fourn", 'alpha'), 'id_fourn', 'fournisseur=1', 'SelectThirdParty', 0, 0, $events); $parameters = array('filtre'=>"fournisseur=1", 'html_name'=>'id_fourn', 'selected'=>GETPOST("id_fourn"), 'showempty'=>1, 'prod_id'=>$object->id); $reshook = $hookmanager->executeHooks('formCreateThirdpartyOptions', $parameters, $object, $action); @@ -613,7 +612,7 @@ if ($id > 0 || $ref) { $default_vat = $object->tva_tx; } } - $vattosuggest = (GETPOST("tva_tx") ?vatrate(GETPOST("tva_tx")) : ($default_vat != '' ?vatrate($default_vat) : '')); + $vattosuggest = (GETPOSTISSET("tva_tx") ? vatrate(GETPOST("tva_tx")) : ($default_vat != '' ?vatrate($default_vat) : '')); $vattosuggest = preg_replace('/\s*\(.*\)$/', '', $vattosuggest); print ''; print '
    '.$extrafields->showOutputField($key, $obj->{$key})."'.$extrafields->showOutputField($key, $obj->{$key}, '', 'product_fournisseur_price')."
    '."\n"; // Common attributes @@ -200,6 +204,8 @@ if ($action == 'create') { // Other attributes include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_add.tpl.php'; + //print ''; + print '
    '.$langs->trans("InventoryCode").'INV'.$object->id.'
    '."\n"; print dol_get_fiche_end(); @@ -455,14 +461,13 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea $MAXEVENT = 10; - $morehtmlright = ''; - $morehtmlright .= $langs->trans("SeeAll"); - $morehtmlright .= ''; + //$morehtmlcenter = dolGetButtonTitle($langs->trans('SeeAll'), '', 'fa fa-list-alt imgforviewmode', DOL_URL_ROOT.'/product/inventory/inventory_info.php?id='.$object->id); + $morehtmlcenter = ''; // List of actions on element include_once DOL_DOCUMENT_ROOT.'/core/class/html.formactions.class.php'; $formactions = new FormActions($db); - $somethingshown = $formactions->showactions($object, $object->element, 0, 1, '', $MAXEVENT, '', $morehtmlright); + $somethingshown = $formactions->showactions($object, $object->element, 0, 1, '', $MAXEVENT, '', $morehtmlcenter); print ''; } diff --git a/htdocs/product/inventory/class/inventory.class.php b/htdocs/product/inventory/class/inventory.class.php index 57abc333a58..92061972e60 100644 --- a/htdocs/product/inventory/class/inventory.class.php +++ b/htdocs/product/inventory/class/inventory.class.php @@ -26,6 +26,7 @@ // Put here all includes required by your class file require_once DOL_DOCUMENT_ROOT.'/core/class/commonobject.class.php'; +require_once DOL_DOCUMENT_ROOT.'/core/class/commonobjectline.class.php'; //require_once DOL_DOCUMENT_ROOT . '/societe/class/societe.class.php'; //require_once DOL_DOCUMENT_ROOT . '/product/class/product.class.php'; @@ -59,10 +60,10 @@ class Inventory extends CommonObject */ public $picto = 'inventory'; - const STATUS_DRAFT = 0; - const STATUS_VALIDATED = 1; - const STATUS_RECORDED = 2; - const STATUS_CANCELED = 9; + const STATUS_DRAFT = 0; // Draft + const STATUS_VALIDATED = 1; // Inventory is in process + const STATUS_RECORDED = 2; // Inventory is finisged. Stock movement has been recorded. + const STATUS_CANCELED = 9; // Canceled /** * 'type' field format ('integer', 'integer:ObjectClass:PathToClass[:AddCreateButtonOrNot[:Filter]]', 'sellist:TableName:LabelFieldName[:KeyFieldName[:KeyFieldParent[:Filter]]]', 'varchar(x)', 'double(24,8)', 'real', 'price', 'text', 'text:none', 'html', 'date', 'datetime', 'timestamp', 'duration', 'mail', 'phone', 'url', 'password') @@ -101,8 +102,7 @@ class Inventory extends CommonObject 'title' => array('type'=>'varchar(255)', 'label'=>'Label', 'visible'=>1, 'enabled'=>1, 'position'=>25, 'css'=>'minwidth300', 'csslist'=>'tdoverflowmax200'), 'fk_warehouse' => array('type'=>'integer:Entrepot:product/stock/class/entrepot.class.php', 'label'=>'Warehouse', 'visible'=>1, 'enabled'=>1, 'position'=>30, 'index'=>1, 'help'=>'InventoryForASpecificWarehouse', 'picto'=>'stock', 'css'=>'minwidth300 maxwidth500 widthcentpercentminusx', 'csslist'=>'tdoverflowmax200'), 'fk_product' => array('type'=>'integer:Product:product/class/product.class.php', 'label'=>'Product', 'visible'=>1, 'enabled'=>1, 'position'=>32, 'index'=>1, 'help'=>'InventoryForASpecificProduct', 'picto'=>'product', 'css'=>'minwidth300 maxwidth500 widthcentpercentminusx', 'csslist'=>'tdoverflowmax200'), - 'date_inventory' => array('type'=>'date', 'label'=>'DateValue', 'visible'=>1, 'enabled'=>1, 'position'=>35), - + 'date_inventory' => array('type'=>'date', 'label'=>'DateValue', 'visible'=>1, 'enabled'=>'$conf->global->STOCK_INVENTORY_ADD_A_VALUE_DATE', 'position'=>35), // This date is not used so disabled by default. 'date_creation' => array('type'=>'datetime', 'label'=>'DateCreation', 'enabled'=>1, 'visible'=>-2, 'notnull'=>1, 'position'=>500), 'tms' => array('type'=>'timestamp', 'label'=>'DateModification', 'enabled'=>1, 'visible'=>-2, 'notnull'=>1, 'position'=>501), 'date_validation' => array('type'=>'datetime', 'label'=>'DateValidation', 'visible'=>-2, 'enabled'=>1, 'position'=>502), @@ -111,7 +111,7 @@ class Inventory extends CommonObject 'fk_user_valid' => array('type'=>'integer:User:user/class/user.class.php', 'label'=>'UserValidation', 'visible'=>-2, 'enabled'=>1, 'position'=>512, 'csslist'=>'tdoverflowmax200'), 'import_key' => array('type'=>'varchar(14)', 'label'=>'ImportId', 'enabled'=>1, 'visible'=>-2, 'notnull'=>-1, 'index'=>0, 'position'=>1000), - 'status' => array('type'=>'integer', 'label'=>'Status', 'visible'=>4, 'enabled'=>1, 'position'=>1000, 'notnull'=>1, 'default'=>0, 'index'=>1, 'arrayofkeyval'=>array(0=>'Draft', 1=>'Validated', 2=>'Recorded', 9=>'Canceled')) + 'status' => array('type'=>'integer', 'label'=>'Status', 'visible'=>4, 'enabled'=>1, 'position'=>1000, 'notnull'=>1, 'default'=>0, 'index'=>1, 'arrayofkeyval'=>array(0=>'Draft', 1=>'Validated', 2=>'Closed', 9=>'Canceled')) ); /** @@ -266,7 +266,7 @@ class Inventory extends CommonObject if ($this->status == self::STATUS_DRAFT) { // Delete inventory - $sql = 'DELETE FROM '.MAIN_DB_PREFIX.'inventorydet WHERE fk_inventory = '.((int) $this->id); + $sql = 'DELETE FROM '.$this->db->prefix().'inventorydet WHERE fk_inventory = '.((int) $this->id); $resql = $this->db->query($sql); if (!$resql) { $this->error = $this->db->lasterror(); @@ -275,21 +275,21 @@ class Inventory extends CommonObject } // Scan existing stock to prefill the inventory - $sql = 'SELECT ps.rowid, ps.fk_entrepot as fk_warehouse, ps.fk_product, ps.reel,'; - $sql .= ' pb.batch, pb.qty'; - $sql .= ' FROM '.MAIN_DB_PREFIX.'product_stock as ps'; - $sql .= ' LEFT JOIN '.MAIN_DB_PREFIX.'product_batch as pb ON pb.fk_product_stock = ps.rowid,'; - $sql .= ' '.MAIN_DB_PREFIX.'product as p, '.MAIN_DB_PREFIX.'entrepot as e'; - $sql .= ' WHERE p.entity IN ('.getEntity('product').')'; - $sql .= ' AND ps.fk_product = p.rowid AND ps.fk_entrepot = e.rowid'; + $sql = "SELECT ps.rowid, ps.fk_entrepot as fk_warehouse, ps.fk_product, ps.reel,"; + $sql .= " pb.batch, pb.qty"; + $sql .= " FROM ".$this->db->prefix()."product_stock as ps"; + $sql .= " LEFT JOIN ".$this->db->prefix()."product_batch as pb ON pb.fk_product_stock = ps.rowid,"; + $sql .= " ".$this->db->prefix()."product as p, ".$this->db->prefix()."entrepot as e"; + $sql .= " WHERE p.entity IN (".getEntity('product').")"; + $sql .= " AND ps.fk_product = p.rowid AND ps.fk_entrepot = e.rowid"; if (empty($conf->global->STOCK_SUPPORTS_SERVICES)) { $sql .= " AND p.fk_product_type = 0"; } if ($this->fk_product > 0) { - $sql .= ' AND ps.fk_product = '.((int) $this->fk_product); + $sql .= " AND ps.fk_product = ".((int) $this->fk_product); } if ($this->fk_warehouse > 0) { - $sql .= ' AND ps.fk_entrepot = '.((int) $this->fk_warehouse); + $sql .= " AND ps.fk_entrepot = ".((int) $this->fk_warehouse); } $inventoryline = new InventoryLine($this->db); @@ -349,7 +349,7 @@ class Inventory extends CommonObject $this->db->begin(); // Delete inventory - $sql = 'DELETE FROM '.MAIN_DB_PREFIX.'inventorydet WHERE fk_inventory = '.((int) $this->id); + $sql = 'DELETE FROM '.$this->db->prefix().'inventorydet WHERE fk_inventory = '.((int) $this->id); $resql = $this->db->query($sql); if (!$resql) { $this->error = $this->db->lasterror(); @@ -368,7 +368,7 @@ class Inventory extends CommonObject } /** - * Set to Recorded + * Set to inventory to status "Closed". It means all stock movements were recorded. * * @param User $user User that creates * @param bool $notrigger false=launch triggers after, true=disable triggers @@ -616,17 +616,17 @@ class Inventory extends CommonObject $labelStatus = array(); $labelStatus[self::STATUS_DRAFT] = $langs->transnoentitiesnoconv('Draft'); - $labelStatus[self::STATUS_VALIDATED] = $langs->transnoentitiesnoconv('Validated').' ('.$langs->transnoentitiesnoconv('Started').')'; + $labelStatus[self::STATUS_VALIDATED] = $langs->transnoentitiesnoconv('Validated').' ('.$langs->transnoentitiesnoconv('InventoryStartedShort').')'; $labelStatus[self::STATUS_CANCELED] = $langs->transnoentitiesnoconv('Canceled'); $labelStatus[self::STATUS_RECORDED] = $langs->transnoentitiesnoconv('Closed'); $labelStatusShort[self::STATUS_DRAFT] = $langs->transnoentitiesnoconv('Draft'); - $labelStatusShort[self::STATUS_VALIDATED] = $langs->transnoentitiesnoconv('Started'); + $labelStatusShort[self::STATUS_VALIDATED] = $langs->transnoentitiesnoconv('InventoryStartedShort'); $labelStatusShort[self::STATUS_CANCELED] = $langs->transnoentitiesnoconv('Canceled'); $labelStatusShort[self::STATUS_RECORDED] = $langs->transnoentitiesnoconv('Closed'); $statusType = 'status'.$status; if ($status == self::STATUS_RECORDED) { - $statusType = 'status5'; + $statusType = 'status6'; } return dolGetStatus($labelStatus[$status], $labelStatusShort[$status], '', $statusType, $mode); @@ -640,10 +640,10 @@ class Inventory extends CommonObject */ public function info($id) { - $sql = 'SELECT rowid, date_creation as datec, tms as datem, date_validation as datev,'; - $sql .= ' fk_user_creat, fk_user_modif, fk_user_valid'; - $sql .= ' FROM '.MAIN_DB_PREFIX.$this->table_element.' as t'; - $sql .= ' WHERE t.rowid = '.((int) $id); + $sql = "SELECT rowid, date_creation as datec, tms as datem, date_validation as datev,"; + $sql .= " fk_user_creat, fk_user_modif, fk_user_valid"; + $sql .= " FROM ".$this->db->prefix().$this->table_element." as t"; + $sql .= " WHERE t.rowid = ".((int) $id); $result = $this->db->query($sql); if ($result) { if ($this->db->num_rows($result)) { diff --git a/htdocs/product/inventory/inventory.php b/htdocs/product/inventory/inventory.php index 9a4d61209ba..95c9e2972cb 100644 --- a/htdocs/product/inventory/inventory.php +++ b/htdocs/product/inventory/inventory.php @@ -103,122 +103,6 @@ if ($cancel) { $action = ''; } -if ($action == 'cancel_record' && $permissiontoadd) { - $object->setCanceled($user); -} - -if ($action == 'update' && !empty($user->rights->stock->mouvement->creer)) { - $stockmovment = new MouvementStock($db); - $stockmovment->setOrigin($object->element, $object->id); - - $db->begin(); - - $sql = 'SELECT id.rowid, id.datec as date_creation, id.tms as date_modification, id.fk_inventory, id.fk_warehouse,'; - $sql .= ' id.fk_product, id.batch, id.qty_stock, id.qty_view, id.qty_regulated'; - $sql .= ' FROM '.MAIN_DB_PREFIX.'inventorydet as id'; - $sql .= ' WHERE id.fk_inventory = '.((int) $object->id); - - $resql = $db->query($sql); - if ($resql) { - $num = $db->num_rows($resql); - $i = 0; - $totalarray = array(); - while ($i < $num) { - $line = $db->fetch_object($resql); - $qty_stock = $line->qty_stock; - $qty_view = $line->qty_view; // The quantity viewed by inventorier, the qty we target - - if (!is_null($qty_view)) { - $stock_movement_qty = price2num($qty_view - $qty_stock, 'MS'); - if ($stock_movement_qty != 0) { - if ($stock_movement_qty < 0) { - $movement_type = 1; - } else { - $movement_type = 0; - } - - $datemovement = ''; - - $idstockmove = $stockmovment->_create($user, $line->fk_product, $line->fk_warehouse, $stock_movement_qty, $movement_type, 0, $langs->trans('LabelOfInventoryMovemement', $object->id), 'INV'.$object->id, $datemovement, '', '', $line->batch); - if ($idstockmove < 0) { - $error++; - setEventMessages($stockmovment->error, $stockmovment->errors, 'errors'); - break; - } - } - } - $i++; - } - - if (!$error) { - $object->setRecorded($user); - } - } else { - setEventMessages($db->lasterror, null, 'errors'); - $error++; - } - - if (! $error) { - $db->commit(); - } else { - $db->rollback(); - } -} - -if ($action =='updateinventorylines' && $permissiontoadd) { - $sql = 'SELECT id.rowid, id.datec as date_creation, id.tms as date_modification, id.fk_inventory, id.fk_warehouse,'; - $sql .= ' id.fk_product, id.batch, id.qty_stock, id.qty_view, id.qty_regulated'; - $sql .= ' FROM '.MAIN_DB_PREFIX.'inventorydet as id'; - $sql .= ' WHERE id.fk_inventory = '.((int) $object->id); - - $db->begin(); - - $resql = $db->query($sql); - if ($resql) { - $num = $db->num_rows($resql); - $i = 0; - $totalarray = array(); - $inventoryline = new InventoryLine($db); - - while ($i < $num) { - $line = $db->fetch_object($resql); - $lineid = $line->rowid; - - if (GETPOST("id_".$lineid, 'alpha') != '') { // If a value was set ('0' or something else) - $qtytoupdate = price2num(GETPOST("id_".$lineid, 'alpha'), 'MS'); - $result = $inventoryline->fetch($lineid); - if ($qtytoupdate < 0) { - $result = -1; - setEventMessages($langs->trans("FieldCannotBeNegative", $langs->transnoentitiesnoconv("RealQty")), null, 'errors'); - } - if ($result > 0) { - $inventoryline->qty_view = $qtytoupdate; - $resultupdate = $inventoryline->update($user); - } - } else { - // Delete record - $result = $inventoryline->fetch($lineid); - if ($result > 0) { - $inventoryline->qty_view = null; - $resultupdate = $inventoryline->update($user); - } - } - - if ($result < 0 || $resultupdate < 0) { - $error++; - } - - $i++; - } - } - - if (!$error) { - $db->commit(); - } else { - $db->rollback(); - } -} - $parameters = array(); $reshook = $hookmanager->executeHooks('doActions', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks if ($reshook < 0) { @@ -228,6 +112,179 @@ if ($reshook < 0) { if (empty($reshook)) { $error = 0; + if ($action == 'cancel_record' && $permissiontoadd) { + $object->setCanceled($user); + } + + // Close inventory by recording the stock movements + if ($action == 'update' && !empty($user->rights->stock->mouvement->creer)) { + $stockmovment = new MouvementStock($db); + $stockmovment->setOrigin($object->element, $object->id); + + $cacheOfProducts = array(); + + $db->begin(); + + $sql = 'SELECT id.rowid, id.datec as date_creation, id.tms as date_modification, id.fk_inventory, id.fk_warehouse,'; + $sql .= ' id.fk_product, id.batch, id.qty_stock, id.qty_view, id.qty_regulated'; + $sql .= ' FROM '.MAIN_DB_PREFIX.'inventorydet as id'; + $sql .= ' WHERE id.fk_inventory = '.((int) $object->id); + + $resql = $db->query($sql); + if ($resql) { + $num = $db->num_rows($resql); + $i = 0; + $totalarray = array(); + while ($i < $num) { + $line = $db->fetch_object($resql); + + $qty_stock = $line->qty_stock; + $qty_view = $line->qty_view; // The quantity viewed by inventorier, the qty we target + + + // Load real stock we have now. + if (isset($cacheOfProducts[$line->fk_product])) { + $product_static = $cacheOfProducts[$line->fk_product]; + } else { + $product_static = new Product($db); + $result = $product_static->fetch($line->fk_product, '', '', '', 1, 1, 1); + + //$option = 'nobatch'; + $option .= ',novirtual'; + $product_static->load_stock($option); // Load stock_reel + stock_warehouse. + + $cacheOfProducts[$product_static->id] = $product_static; + } + + // Get the real quantity in stock now, but before the stock move for inventory. + $realqtynow = $product_static->stock_warehouse[$line->fk_warehouse]->real; + if ($conf->productbatch->enabled && $product_static->hasbatch()) { + $realqtynow = $product_static->stock_warehouse[$line->fk_warehouse]->detail_batch[$line->batch]->qty; + } + + + if (!is_null($qty_view)) { + $stock_movement_qty = price2num($qty_view - $realqtynow, 'MS'); + if ($stock_movement_qty != 0) { + if ($stock_movement_qty < 0) { + $movement_type = 1; + } else { + $movement_type = 0; + } + + $datemovement = ''; + //$inventorycode = 'INV'.$object->id; + $inventorycode = 'INV-'.$object->ref; + + $idstockmove = $stockmovment->_create($user, $line->fk_product, $line->fk_warehouse, $stock_movement_qty, $movement_type, 0, $langs->trans('LabelOfInventoryMovemement', $object->ref), $inventorycode, $datemovement, '', '', $line->batch); + if ($idstockmove < 0) { + $error++; + setEventMessages($stockmovment->error, $stockmovment->errors, 'errors'); + break; + } + + // Update line with id of stock movement (and the start quantity if it has changed this last recording) + $sqlupdate = "UPDATE ".MAIN_DB_PREFIX."inventorydet"; + $sqlupdate .= " SET fk_movement = ".((int) $idstockmove); + if ($qty_stock != $realqtynow) { + $sqlupdate .= ", qty_stock = ".((float) $realqtynow); + } + $sqlupdate .= " WHERE rowid = ".((int) $line->rowid); + $resqlupdate = $db->query($sqlupdate); + if (! $resqlupdate) { + $error++; + setEventMessages($db->lasterror(), null, 'errors'); + break; + } + } + } + $i++; + } + + if (!$error) { + $object->setRecorded($user); + } + } else { + setEventMessages($db->lasterror, null, 'errors'); + $error++; + } + + if (! $error) { + $db->commit(); + } else { + $db->rollback(); + } + } + + // Save quantity found during inventory + if ($action =='updateinventorylines' && $permissiontoadd) { + $sql = 'SELECT id.rowid, id.datec as date_creation, id.tms as date_modification, id.fk_inventory, id.fk_warehouse,'; + $sql .= ' id.fk_product, id.batch, id.qty_stock, id.qty_view, id.qty_regulated'; + $sql .= ' FROM '.MAIN_DB_PREFIX.'inventorydet as id'; + $sql .= ' WHERE id.fk_inventory = '.((int) $object->id); + + $db->begin(); + + $resql = $db->query($sql); + if ($resql) { + $num = $db->num_rows($resql); + $i = 0; + $totalarray = array(); + $inventoryline = new InventoryLine($db); + + while ($i < $num) { + $line = $db->fetch_object($resql); + $lineid = $line->rowid; + + if (GETPOST("id_".$lineid, 'alpha') != '') { // If a value was set ('0' or something else) + $qtytoupdate = price2num(GETPOST("id_".$lineid, 'alpha'), 'MS'); + $result = $inventoryline->fetch($lineid); + if ($qtytoupdate < 0) { + $result = -1; + setEventMessages($langs->trans("FieldCannotBeNegative", $langs->transnoentitiesnoconv("RealQty")), null, 'errors'); + } + if ($result > 0) { + $inventoryline->qty_stock = price2num(GETPOST('stock_qty_'.$lineid, 'alpha'), 'MS'); // The new value that was set in as hidden field + $inventoryline->qty_view = $qtytoupdate; // The new value we want + $resultupdate = $inventoryline->update($user); + } + } else { + // Delete record + $result = $inventoryline->fetch($lineid); + if ($result > 0) { + $inventoryline->qty_view = null; // The new value we want + $resultupdate = $inventoryline->update($user); + } + } + + if ($result < 0 || $resultupdate < 0) { + $error++; + } + + $i++; + } + } + + // Update line with id of stock movement (and the start quantity if it has changed this last recording) + if (! $error) { + $sqlupdate = "UPDATE ".MAIN_DB_PREFIX."inventory"; + $sqlupdate .= " SET fk_user_modif = ".((int) $user->id); + $sqlupdate .= " WHERE rowid = ".((int) $object->id); + $resqlupdate = $db->query($sqlupdate); + if (! $resqlupdate) { + $error++; + setEventMessages($db->lasterror(), null, 'errors'); + } + } + + if (!$error) { + $db->commit(); + } else { + $db->rollback(); + } + } + + $backurlforlist = DOL_URL_ROOT.'/product/inventory/list.php'; $backtopage = DOL_URL_ROOT.'/product/inventory/inventory.php?id='.$object->id; @@ -286,10 +343,15 @@ if (empty($reshook)) { $result = $tmp->create($user); if ($result < 0) { if ($db->lasterrno() == 'DB_ERROR_RECORD_ALREADY_EXISTS') { - setEventMessages($langs->trans("DuplicateRecord"), null, 'errors'); + $langs->load("errors"); + setEventMessages($langs->trans("ErrorRecordAlreadyExists"), null, 'errors'); } else { dol_print_error($db, $tmp->error, $tmp->errors); } + } else { + // Clear var + $_POST['batch'] = ''; + $_POST['qtytoadd'] = ''; } } } @@ -310,20 +372,22 @@ $help_url = ''; llxHeader('', $langs->trans('Inventory'), $help_url); -// Disable button Generate movement if data were not saved -print ''; + // Link to autofill + print ''.img_picto('', 'autofill', 'class="paddingrightonly"').$langs->trans('AutofillWithExpected').''; + print ''; + + // Link to reset qty + print ''.img_picto('', 'eraser', 'class="paddingrightonly"').$langs->trans("ClearQtys").''; + } else { + print ''.$langs->trans("Save").''."\n"; + } } print '
    '; print '
    '; @@ -539,17 +606,37 @@ if ($object->id > 0) { // Popup for mass barcode scanning if ($action == 'updatebyscaning') { if ($permissiontoadd) { + // Output the javascript to manage the scanner tool. print ''; } include DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php'; $formother = new FormOther($db); - print $formother->getHTMLScannerForm(); + print $formother->getHTMLScannerForm("barcodescannerjs", 'all'); } //Call method to undo changes in real qty print ''; @@ -661,24 +854,29 @@ if ($object->id > 0) { print '
    '.$langs->trans("Warehouse").''.$langs->trans("Product").''; print $langs->trans("Batch"); print ''.$langs->trans("ExpectedQty").''; + print ''; print $form->textwithpicto($langs->trans("RealQty"), $langs->trans("InventoryRealQtyHelp")); print ''; print '
    '; + //print $langs->trans("StockMovement"); + print '
    '; print $formproduct->selectWarehouses((GETPOSTISSET('fk_warehouse') ? GETPOST('fk_warehouse', 'int') : $object->fk_warehouse), 'fk_warehouse', 'warehouseopen', 1, 0, 0, '', 0, 0, array(), 'maxwidth300'); @@ -686,13 +884,13 @@ if ($object->id > 0) { print ''; print $form->select_produits((GETPOSTISSET('fk_product') ? GETPOST('fk_product', 'int') : $object->fk_product), 'fk_product', '', 0, 0, -1, 2, '', 0, null, 0, '1', 0, 'maxwidth300'); print ''; print ''; print ''; + print ''; print ''; print ''; print $obj->batch; print ''; - print $obj->qty_stock; + // Expected quantity = Quantity in stock when we start inventory + print ''; + $valuetoshow = $obj->qty_stock; + // For inventory not yet close, we overwrite with the real value in stock now + if ($object->status == $object::STATUS_DRAFT || $object->status == $object::STATUS_VALIDATED) { + if (!empty($conf->productbatch->enabled) && $product_static->hasbatch()) { + $valuetoshow = $product_static->stock_warehouse[$obj->fk_warehouse]->detail_batch[$obj->batch]->qty; + } else { + $valuetoshow = $product_static->stock_warehouse[$obj->fk_warehouse]->real; + } + } + print price2num($valuetoshow, 'MS'); + print ''; print ''; - if ($object->status == $object::STATUS_VALIDATED) { + if ($object->status == $object::STATUS_DRAFT || $object->status == $object::STATUS_VALIDATED) { + print ''; $qty_view = GETPOST("id_".$obj->rowid) && price2num(GETPOST("id_".$obj->rowid), 'MS') >= 0 ? GETPOST("id_".$obj->rowid) : $obj->qty_view; - if (!$hasinput && $qty_view !== null && $obj->qty_stock != $qty_view) { + + //if (!$hasinput && $qty_view !== null && $obj->qty_stock != $qty_view) { + if ($qty_view != '') { $hasinput = true; } + print ''; + print img_picto('', 'eraser', 'class="opacitymedium"'); + print ''; print ''; print ''; - print '  '; print ''.img_delete().''; - print ''; + print $obj->qty_view; // qty found + print ''; + if ($obj->fk_movement > 0) { + $stockmovment = new MouvementStock($db); + $stockmovment->fetch($obj->fk_movement); + print $stockmovment->getNomUrl(1, 'movements'); + } print '
    '; + print ''; print ''; @@ -1096,6 +1128,9 @@ if ($resql) { if (!empty($arrayfields['pfp.ref_fourn']['checked'])) { print_liste_field_titre($arrayfields['pfp.ref_fourn']['label'], $_SERVER["PHP_SELF"], "pfp.ref_fourn", "", $param, "", $sortfield, $sortorder); } + if (!empty($arrayfields['thumbnail']['checked'])) { + print_liste_field_titre($arrayfields['thumbnail']['label'], $_SERVER["PHP_SELF"], '', '', $param, '', $sortfield, $sortorder, 'center '); + } if (!empty($arrayfields['p.label']['checked'])) { print_liste_field_titre($arrayfields['p.label']['label'], $_SERVER["PHP_SELF"], "p.label", "", $param, "", $sortfield, $sortorder); } @@ -1343,6 +1378,22 @@ if ($resql) { } } + // Thumbnail + if (!empty($arrayfields['thumbnail']['checked'])) { + $product_thumbnail_html = ''; + if (!empty($product_static->entity)) { + $product_thumbnail = $product_static->show_photos('product', $conf->product->multidir_output[$product_static->entity], 1, 1, 0, 0, 0, 80); + if ($product_static->nbphoto > 0) { + $product_thumbnail_html = $product_thumbnail; + } + } + + print '' . $product_thumbnail_html . ''.$obj->label.'
    '; -print ""; +print ''; print_liste_field_titre('Ref', $_SERVER["PHP_SELF"], 'p.ref', '', $param, '', $sortfield, $sortorder); print_liste_field_titre('Type', $_SERVER["PHP_SELF"], 'p.fk_product_type', '', $param, '', $sortfield, $sortorder); print_liste_field_titre('Label', $_SERVER["PHP_SELF"], 'p.label', '', $param, '', $sortfield, $sortorder); @@ -212,7 +212,7 @@ if ($mode && $mode != '-1') { $sql = "SELECT label"; $sql .= " FROM ".MAIN_DB_PREFIX."product_lang"; $sql .= " WHERE fk_product = ".((int) $prodid); - $sql .= " AND lang='".$db->escape($langs->getDefaultLang())."'"; + $sql .= " AND lang = '".$db->escape($langs->getDefaultLang())."'"; $sql .= " LIMIT 1"; $resultp = $db->query($sql); diff --git a/htdocs/product/price.php b/htdocs/product/price.php index 773a097fed8..45ecbd9bafa 100644 --- a/htdocs/product/price.php +++ b/htdocs/product/price.php @@ -127,7 +127,7 @@ if (empty($reshook)) { $reg = array(); $vatratecode = ''; if (preg_match('/\((.*)\)/', $tva_tx_txt, $reg)) { - $vat_src_code = $reg[1]; + $vatratecode = $reg[1]; $tva_tx = preg_replace('/\s*\(.*\)/', '', $tva_tx_txt); // Remove code into vatrate. } @@ -143,15 +143,35 @@ if (empty($reshook)) { $sql .= " FROM ".MAIN_DB_PREFIX."c_tva as t, ".MAIN_DB_PREFIX."c_country as c"; $sql .= " WHERE t.fk_pays = c.rowid AND c.code = '".$db->escape($mysoc->country_code)."'"; $sql .= " AND t.taux = ".((float) $tva_tx)." AND t.active = 1"; - $sql .= " AND t.code ='".$db->escape($vatratecode)."'"; + $sql .= " AND t.code = '".$db->escape($vatratecode)."'"; $resql = $db->query($sql); if ($resql) { $obj = $db->fetch_object($resql); - $npr = $obj->recuperableonly; - $localtax1 = $obj->localtax1; - $localtax2 = $obj->localtax2; - $localtax1_type = $obj->localtax1_type; - $localtax2_type = $obj->localtax2_type; + if ($obj) { + $npr = $obj->recuperableonly; + $localtax1 = $obj->localtax1; + $localtax2 = $obj->localtax2; + $localtax1_type = $obj->localtax1_type; + $localtax2_type = $obj->localtax2_type; + } + } + } else { + // Get record with empty code + $sql = "SELECT t.rowid, t.code, t.recuperableonly, t.localtax1, t.localtax2, t.localtax1_type, t.localtax2_type"; + $sql .= " FROM ".MAIN_DB_PREFIX."c_tva as t, ".MAIN_DB_PREFIX."c_country as c"; + $sql .= " WHERE t.fk_pays = c.rowid AND c.code = '".$db->escape($mysoc->country_code)."'"; + $sql .= " AND t.taux = ".((float) $tva_tx)." AND t.active = 1"; + $sql .= " AND t.code = ''"; + $resql = $db->query($sql); + if ($resql) { + $obj = $db->fetch_object($resql); + if ($obj) { + $npr = $obj->recuperableonly; + $localtax1 = $obj->localtax1; + $localtax2 = $obj->localtax2; + $localtax1_type = $obj->localtax1_type; + $localtax2_type = $obj->localtax2_type; + } } } @@ -172,6 +192,8 @@ if (empty($reshook)) { } if ($error) { + // Force the update of the price of the product to 0 if error + //$localtaxarray=array('0'=>$localtax1_type,'1'=>$localtax1,'2'=>$localtax2_type,'3'=>$localtax2); $localtaxarray = array(); // We do not store localtaxes into product, we will use instead the "vat code" to retrieve them. $object->updatePrice(0, $object->price_base_type, $user, $tva_tx, '', 0, $npr, 0, 0, $localtaxarray, $vatratecode); @@ -256,11 +278,37 @@ if (empty($reshook)) { $resql = $db->query($sql); if ($resql) { $obj = $db->fetch_object($resql); - $npr = $obj->recuperableonly; - $localtax1 = $obj->localtax1; - $localtax2 = $obj->localtax2; - $localtax1_type = $obj->localtax1_type; - $localtax2_type = $obj->localtax2_type; + if ($obj) { + $npr = $obj->recuperableonly; + $localtax1 = $obj->localtax1; + $localtax2 = $obj->localtax2; + $localtax1_type = $obj->localtax1_type; + $localtax2_type = $obj->localtax2_type; + } + + // If spain, we don't use the localtax found into tax record in database with same code, but using the get_localtax rule. + if (in_array($mysoc->country_code, array('ES'))) { + $localtax1 = get_localtax($tva_tx, 1); + $localtax2 = get_localtax($tva_tx, 2); + } + } + } else { + // Get record with empty code + $sql = "SELECT t.rowid, t.code, t.recuperableonly, t.localtax1, t.localtax2, t.localtax1_type, t.localtax2_type"; + $sql .= " FROM ".MAIN_DB_PREFIX."c_tva as t, ".MAIN_DB_PREFIX."c_country as c"; + $sql .= " WHERE t.fk_pays = c.rowid AND c.code = '".$db->escape($mysoc->country_code)."'"; + $sql .= " AND t.taux = ".((float) $tva_tx)." AND t.active = 1"; + $sql .= " AND t.code = ''"; + $resql = $db->query($sql); + if ($resql) { + $obj = $db->fetch_object($resql); + if ($obj) { + $npr = $obj->recuperableonly; + $localtax1 = $obj->localtax1; + $localtax2 = $obj->localtax2; + $localtax1_type = $obj->localtax1_type; + $localtax2_type = $obj->localtax2_type; + } } } @@ -309,19 +357,40 @@ if (empty($reshook)) { $resql = $db->query($sql); if ($resql) { $obj = $db->fetch_object($resql); - $npr = $obj->recuperableonly; - $localtax1 = $obj->localtax1; - $localtax2 = $obj->localtax2; - $localtax1_type = $obj->localtax1_type; - $localtax2_type = $obj->localtax2_type; + if ($obj) { + $npr = $obj->recuperableonly; + $localtax1 = $obj->localtax1; + $localtax2 = $obj->localtax2; + $localtax1_type = $obj->localtax1_type; + $localtax2_type = $obj->localtax2_type; + } - // If spain, we don't use the localtax found into tax record in database with same code, but using the get_localtax rule + // If spain, we don't use the localtax found into tax record in database with same code, but using the get_localtax rule. if (in_array($mysoc->country_code, array('ES'))) { $localtax1 = get_localtax($tva_tx, 1); $localtax2 = get_localtax($tva_tx, 2); } } + } else { + // Get record with empty code + $sql = "SELECT t.rowid, t.code, t.recuperableonly, t.localtax1, t.localtax2, t.localtax1_type, t.localtax2_type"; + $sql .= " FROM ".MAIN_DB_PREFIX."c_tva as t, ".MAIN_DB_PREFIX."c_country as c"; + $sql .= " WHERE t.fk_pays = c.rowid AND c.code = '".$db->escape($mysoc->country_code)."'"; + $sql .= " AND t.taux = ".((float) $tva_tx)." AND t.active = 1"; + $sql .= " AND t.code = ''"; + $resql = $db->query($sql); + if ($resql) { + $obj = $db->fetch_object($resql); + if ($obj) { + $npr = $obj->recuperableonly; + $localtax1 = $obj->localtax1; + $localtax2 = $obj->localtax2; + $localtax1_type = $obj->localtax1_type; + $localtax2_type = $obj->localtax2_type; + } + } } + $pricestoupdate[0] = array( 'price' => $newprice, 'price_min' => $newprice_min, @@ -532,11 +601,37 @@ if (empty($reshook)) { $resql = $db->query($sql); if ($resql) { $obj = $db->fetch_object($resql); - $npr = $obj->recuperableonly; - $localtax1 = $obj->localtax1; - $localtax2 = $obj->localtax2; - $localtax1_type = $obj->localtax1_type; - $localtax2_type = $obj->localtax2_type; + if ($obj) { + $npr = $obj->recuperableonly; + $localtax1 = $obj->localtax1; + $localtax2 = $obj->localtax2; + $localtax1_type = $obj->localtax1_type; + $localtax2_type = $obj->localtax2_type; + } + + // If spain, we don't use the localtax found into tax record in database with same code, but using the get_localtax rule. + if (in_array($mysoc->country_code, array('ES'))) { + $localtax1 = get_localtax($tva_tx, 1); + $localtax2 = get_localtax($tva_tx, 2); + } + } + } else { + // Get record with empty code + $sql = "SELECT t.rowid, t.code, t.recuperableonly, t.localtax1, t.localtax2, t.localtax1_type, t.localtax2_type"; + $sql .= " FROM ".MAIN_DB_PREFIX."c_tva as t, ".MAIN_DB_PREFIX."c_country as c"; + $sql .= " WHERE t.fk_pays = c.rowid AND c.code = '".$db->escape($mysoc->country_code)."'"; + $sql .= " AND t.taux = ".((float) $tva_tx)." AND t.active = 1"; + $sql .= " AND t.code = ''"; + $resql = $db->query($sql); + if ($resql) { + $obj = $db->fetch_object($resql); + if ($obj) { + $npr = $obj->recuperableonly; + $localtax1 = $obj->localtax1; + $localtax2 = $obj->localtax2; + $localtax1_type = $obj->localtax1_type; + $localtax2_type = $obj->localtax2_type; + } } } @@ -625,11 +720,37 @@ if (empty($reshook)) { $resql = $db->query($sql); if ($resql) { $obj = $db->fetch_object($resql); - $npr = $obj->recuperableonly; - $localtax1 = $obj->localtax1; - $localtax2 = $obj->localtax2; - $localtax1_type = $obj->localtax1_type; - $localtax2_type = $obj->localtax2_type; + if ($obj) { + $npr = $obj->recuperableonly; + $localtax1 = $obj->localtax1; + $localtax2 = $obj->localtax2; + $localtax1_type = $obj->localtax1_type; + $localtax2_type = $obj->localtax2_type; + } + + // If spain, we don't use the localtax found into tax record in database with same code, but using the get_localtax rule. + if (in_array($mysoc->country_code, array('ES'))) { + $localtax1 = get_localtax($tva_tx, 1); + $localtax2 = get_localtax($tva_tx, 2); + } + } + } else { + // Get record with empty code + $sql = "SELECT t.rowid, t.code, t.recuperableonly, t.localtax1, t.localtax2, t.localtax1_type, t.localtax2_type"; + $sql .= " FROM ".MAIN_DB_PREFIX."c_tva as t, ".MAIN_DB_PREFIX."c_country as c"; + $sql .= " WHERE t.fk_pays = c.rowid AND c.code = '".$db->escape($mysoc->country_code)."'"; + $sql .= " AND t.taux = ".((float) $tva_tx)." AND t.active = 1"; + $sql .= " AND t.code = ''"; + $resql = $db->query($sql); + if ($resql) { + $obj = $db->fetch_object($resql); + if ($obj) { + $npr = $obj->recuperableonly; + $localtax1 = $obj->localtax1; + $localtax2 = $obj->localtax2; + $localtax1_type = $obj->localtax1_type; + $localtax2_type = $obj->localtax2_type; + } } } @@ -733,9 +854,9 @@ if (!empty($conf->global->PRODUIT_MULTIPRICES) || !empty($conf->global->PRODUIT_ print ''; print ''; if ($object->multiprices_base_type [$i] == 'TTC') { - print ''; + print ' '.$langs->trans($object->multiprices_base_type [$i]).''; } else { - print ' '.$langs->trans($object->price_base_type).''; + print ' '.$langs->trans($object->price_base_type).''; } // Prix min @@ -1156,22 +1278,30 @@ if (!$action || $action == 'delete' || $action == 'showlog_customer_price' || $a if (empty($conf->global->PRODUIT_MULTIPRICES) && empty($conf->global->PRODUIT_CUSTOMER_PRICES_BY_QTY_MULTIPRICES)) { if ($user->rights->produit->creer || $user->rights->service->creer) { print ''; + } else { + print '
    ' . $langs->trans("UpdateDefaultPrice") . '
    '; } } if (!empty($conf->global->PRODUIT_CUSTOMER_PRICES)) { if ($user->rights->produit->creer || $user->rights->service->creer) { print ''; + } else { + print '
    ' . $langs->trans("AddCustomerPrice") . '
    '; } } if (!empty($conf->global->PRODUIT_MULTIPRICES) || !empty($conf->global->PRODUIT_CUSTOMER_PRICES_BY_QTY_MULTIPRICES)) { if ($user->rights->produit->creer || $user->rights->service->creer) { print ''; + } else { + print '
    ' . $langs->trans("UpdateVAT") . '
    '; } if ($user->rights->produit->creer || $user->rights->service->creer) { print ''; + } else { + print '
    ' . $langs->trans("UpdateLevelPrices") . '
    '; } } } @@ -1669,8 +1799,8 @@ if (!empty($conf->global->PRODUIT_CUSTOMER_PRICES)) { $prodcustprice = new Productcustomerprice($db); $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; - $sortfield = GETPOST("sortfield", 'alpha'); - $sortorder = GETPOST("sortorder", 'alpha'); + $sortfield = GETPOST('sortfield', 'aZ09comma'); + $sortorder = GETPOST('sortorder', 'aZ09comma'); $page = (GETPOST("page", 'int') ?GETPOST("page", 'int') : 0); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/product/reassort.php b/htdocs/product/reassort.php index b0a1ce87ddd..e8e7bbda3cd 100644 --- a/htdocs/product/reassort.php +++ b/htdocs/product/reassort.php @@ -39,17 +39,17 @@ $action = GETPOST('action', 'aZ09'); $sref = GETPOST("sref", 'alpha'); $snom = GETPOST("snom", 'alpha'); $sall = trim((GETPOST('search_all', 'alphanohtml') != '') ?GETPOST('search_all', 'alphanohtml') : GETPOST('sall', 'alphanohtml')); -$type = GETPOST("type", "int"); +$type = GETPOSTISSET('type') ? GETPOST('type', 'int') : Product::TYPE_PRODUCT; $search_barcode = GETPOST("search_barcode", 'alpha'); -$catid = GETPOST('catid', 'int'); $toolowstock = GETPOST('toolowstock'); $tosell = GETPOST("tosell"); $tobuy = GETPOST("tobuy"); $fourn_id = GETPOST("fourn_id", 'int'); $sbarcode = GETPOST("sbarcode", 'int'); +$search_stock_physique = GETPOST('search_stock_physique', 'alpha'); -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page < 0) { $page = 0; @@ -68,7 +68,11 @@ $offset = $limit * $page; // Load sale and categ filters $search_sale = GETPOST("search_sale"); -$search_categ = GETPOST("search_categ"); +if (GETPOSTISSET('catid')) { + $search_categ = GETPOST('catid', 'int'); +} else { + $search_categ = GETPOST('search_categ', 'int'); +} // Get object canvas (By default, this is not defined, so standard usage of dolibarr) $canvas = GETPOST("canvas"); @@ -111,11 +115,10 @@ if (GETPOST('button_removefilter_x', 'alpha') || GETPOST('button_removefilter.x' $tobuy = ""; $search_sale = ""; $search_categ = ""; - $type = ""; - $catid = ''; $toolowstock = ''; $fourn_id = ''; $sbarcode = ''; + $search_stock_physique = ''; } @@ -146,13 +149,22 @@ $sql .= ' LEFT JOIN '.MAIN_DB_PREFIX.'entrepot as e ON s.fk_entrepot = e.rowid A if (!empty($conf->global->PRODUCT_USE_UNITS)) { $sql .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_units as u on p.fk_unit = u.rowid'; } -// We'll need this table joined to the select in order to filter by categ -if ($search_categ) { - $sql .= ", ".MAIN_DB_PREFIX."categorie_product as cp"; -} $sql .= " WHERE p.entity IN (".getEntity('product').")"; -if ($search_categ) { - $sql .= " AND p.rowid = cp.fk_product"; // Join for the needed table to filter by categ +if (!empty($search_categ) && $search_categ != '-1') { + $sql .= " AND "; + if ($search_categ == -2) { + $sql .= " NOT EXISTS "; + } else { + $sql .= " EXISTS "; + } + $sql .= "("; + $sql .= " SELECT cp.fk_categorie, cp.fk_product"; + $sql .= " FROM " . MAIN_DB_PREFIX . "categorie_product as cp"; + $sql .= " WHERE cp.fk_product = p.rowid"; // Join for the needed table to filter by categ + if ($search_categ > 0) { + $sql .= " AND cp.fk_categorie = " . ((int) $search_categ); + } + $sql .= ")"; } if ($sall) { $sql .= natural_search(array('p.ref', 'p.label', 'p.description', 'p.note'), $sall); @@ -183,24 +195,32 @@ if (!empty($tobuy)) { if (!empty($canvas)) { $sql .= " AND p.canvas = '".$db->escape($canvas)."'"; } -if ($catid > 0) { - $sql .= " AND cp.fk_categorie = ".((int) $catid); -} if ($fourn_id > 0) { $sql .= " AND p.rowid = pf.fk_product AND pf.fk_soc = ".((int) $fourn_id); } -// Insert categ filter -if ($search_categ > 0) { - $sql .= " AND cp.fk_categorie = ".((int) $search_categ); -} $sql .= " GROUP BY p.rowid, p.ref, p.label, p.barcode, p.price, p.price_ttc, p.price_base_type, p.entity,"; $sql .= " p.fk_product_type, p.tms, p.duration, p.tosell, p.tobuy, p.seuil_stock_alerte, p.desiredstock"; // Add fields from hooks $parameters = array(); $reshook = $hookmanager->executeHooks('printFieldSelect', $parameters); // Note that $action and $object may have been modified by hook $sql .= $hookmanager->resPrint; +$sql_having = ''; if ($toolowstock) { - $sql .= " HAVING SUM(".$db->ifsql('s.reel IS NULL', '0', 's.reel').") < p.seuil_stock_alerte"; + $sql_having .= " HAVING SUM(".$db->ifsql('s.reel IS NULL', '0', 's.reel').") < p.seuil_stock_alerte"; +} +if ($search_stock_physique != '') { + //$natural_search_physique = natural_search('HAVING SUM(' . $db->ifsql('s.reel IS NULL', '0', 's.reel') . ')', $search_stock_physique, 1, 1); + $natural_search_physique = natural_search('SUM(' . $db->ifsql('s.reel IS NULL', '0', 's.reel') . ')', $search_stock_physique, 1, 1); + $natural_search_physique = " " . substr($natural_search_physique, 1, -1); // remove first "(" and last ")" characters + if (!empty($sql_having)) { + $sql_having .= " AND"; + } else { + $sql_having .= " HAVING"; + } + $sql_having .= $natural_search_physique; +} +if (!empty($sql_having)) { + $sql .= $sql_having; } $sql .= $db->order($sortfield, $sortorder); @@ -253,7 +273,7 @@ if ($resql) { if ($tobuy) { $param .= "&tobuy=".urlencode($tobuy); } - if ($type) { + if ($type != '') { $param .= "&type=".urlencode($type); } if ($fourn_id) { @@ -268,7 +288,7 @@ if ($resql) { if ($search_sale) { $param .= "&search_sale=".urlencode($search_sale); } - if ($search_categ) { + if ($search_categ > 0) { $param .= "&search_categ=".urlencode($search_categ); } if ($toolowstock) { @@ -277,8 +297,8 @@ if ($resql) { if ($sbarcode) { $param .= "&sbarcode=".urlencode($sbarcode); } - if ($catid) { - $param .= "&catid=".urlencode($catid); + if ($search_stock_physique) { + $param .= '&search_stock_physique=' . urlencode($search_stock_physique); } llxHeader("", $texte, $helpurl); @@ -292,10 +312,10 @@ if ($resql) { print_barre_liste($texte, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, '', $num, $nbtotalofrecords, 'product', 0, '', '', $limit); - if (!empty($catid)) { + if ($search_categ > 0) { print "
    "; $c = new Categorie($db); - $c->fetch($catid); + $c->fetch($search_categ); $ways = $c->print_all_ways(' > ', 'product/reassort.php'); print " > ".$ways[0]."
    \n"; print "

    "; @@ -306,7 +326,7 @@ if ($resql) { if (!empty($conf->categorie->enabled)) { $moreforfilter .= '
    '; $moreforfilter .= img_picto($langs->trans('Categories'), 'category', 'class="pictofixedwidth"'); - $moreforfilter .= $htmlother->select_categories(Categorie::TYPE_PRODUCT, $search_categ, 'search_categ'); + $moreforfilter .= $htmlother->select_categories(Categorie::TYPE_PRODUCT, $search_categ, 'search_categ', 1); $moreforfilter .= '
    '; } @@ -323,32 +343,6 @@ if ($resql) { print ''; } - $param = ''; - if ($tosell) { - $param .= "&tosell=".urlencode($tosell); - } - if ($tobuy) { - $param .= "&tobuy=".urlencode($tobuy); - } - if ($type) { - $param .= "&type=".urlencode($type); - } - if ($fourn_id) { - $param .= "&fourn_id=".urlencode($fourn_id); - } - if ($snom) { - $param .= "&snom=".urlencode($snom); - } - if ($sref) { - $param .= "&sref=".urlencode($sref); - } - if ($toolowstock) { - $param .= "&toolowstock=".urlencode($toolowstock); - } - if ($search_categ) { - $param .= "&search_categ=".urlencode($search_categ); - } - $formProduct = new FormProduct($db); $formProduct->loadWarehouses(); $warehouses_list = $formProduct->cache_warehouses; @@ -378,7 +372,10 @@ if ($resql) { // Stock limit print ''; print ''; - print ''; + // Physical stock + print ''; if ($virtualdiffersfromphysical) { print ''; } @@ -396,14 +393,14 @@ if ($resql) { //Line for column titles print ""; - print_liste_field_titre("Ref", $_SERVER["PHP_SELF"], "p.ref", $param, "", "", $sortfield, $sortorder); - print_liste_field_titre("Label", $_SERVER["PHP_SELF"], "p.label", $param, "", "", $sortfield, $sortorder); + print_liste_field_titre("Ref", $_SERVER["PHP_SELF"], "p.ref", '', $param, "", $sortfield, $sortorder); + print_liste_field_titre("Label", $_SERVER["PHP_SELF"], "p.label", '', $param, "", $sortfield, $sortorder); if (!empty($conf->service->enabled) && $type == 1) { - print_liste_field_titre("Duration", $_SERVER["PHP_SELF"], "p.duration", $param, "", '', $sortfield, $sortorder, 'center '); + print_liste_field_titre("Duration", $_SERVER["PHP_SELF"], "p.duration", '', $param, "", $sortfield, $sortorder, 'center '); } - print_liste_field_titre("StockLimit", $_SERVER["PHP_SELF"], "p.seuil_stock_alerte", $param, "", '', $sortfield, $sortorder, 'right '); - print_liste_field_titre("DesiredStock", $_SERVER["PHP_SELF"], "p.desiredstock", $param, "", '', $sortfield, $sortorder, 'right '); - print_liste_field_titre("PhysicalStock", $_SERVER["PHP_SELF"], "stock_physique", $param, "", '', $sortfield, $sortorder, 'right '); + print_liste_field_titre("StockLimit", $_SERVER["PHP_SELF"], "p.seuil_stock_alerte", '', $param, "", $sortfield, $sortorder, 'right '); + print_liste_field_titre("DesiredStock", $_SERVER["PHP_SELF"], "p.desiredstock", '', $param, "", $sortfield, $sortorder, 'right '); + print_liste_field_titre("PhysicalStock", $_SERVER["PHP_SELF"], "stock_physique", '', $param, "", $sortfield, $sortorder, 'right '); // Details per warehouse if (!empty($conf->global->STOCK_DETAIL_ON_WAREHOUSE)) { // TODO This should be moved into the selection of fields on page product/list (page product/stock will be removed and replaced with product/list with its own context) if ($nb_warehouse > 1) { @@ -413,15 +410,15 @@ if ($resql) { } } if ($virtualdiffersfromphysical) { - print_liste_field_titre("VirtualStock", $_SERVER["PHP_SELF"], "", $param, "", '', $sortfield, $sortorder, 'right ', 'VirtualStockDesc'); + print_liste_field_titre("VirtualStock", $_SERVER["PHP_SELF"], "", '', $param, "", $sortfield, $sortorder, 'right ', 'VirtualStockDesc'); } // Units if (!empty($conf->global->PRODUCT_USE_UNITS)) { - print_liste_field_titre("Unit", $_SERVER["PHP_SELF"], "unit_short", $param, "", 'align="right"', $sortfield, $sortorder); + print_liste_field_titre("Unit", $_SERVER["PHP_SELF"], "unit_short", '', $param, 'align="right"', $sortfield, $sortorder); } print_liste_field_titre(''); - print_liste_field_titre("ProductStatusOnSell", $_SERVER["PHP_SELF"], "p.tosell", $param, "", '', $sortfield, $sortorder, 'right '); - print_liste_field_titre("ProductStatusOnBuy", $_SERVER["PHP_SELF"], "p.tobuy", $param, "", '', $sortfield, $sortorder, 'right '); + print_liste_field_titre("ProductStatusOnSell", $_SERVER["PHP_SELF"], "p.tosell", '', $param, "", $sortfield, $sortorder, 'right '); + print_liste_field_titre("ProductStatusOnBuy", $_SERVER["PHP_SELF"], "p.tobuy", '', $param, "", $sortfield, $sortorder, 'right '); // Hook fields $parameters = array('param'=>$param, 'sortfield'=>$sortfield, 'sortorder'=>$sortorder); $reshook = $hookmanager->executeHooks('printFieldListTitle', $parameters); // Note that $action and $object may have been modified by hook diff --git a/htdocs/product/reassortlot.php b/htdocs/product/reassortlot.php index e75d1504267..c5463e3e4e2 100644 --- a/htdocs/product/reassortlot.php +++ b/htdocs/product/reassortlot.php @@ -41,19 +41,19 @@ $action = GETPOST('action', 'aZ09'); $sref = GETPOST("sref", 'alpha'); $snom = GETPOST("snom", 'alpha'); $sall = trim((GETPOST('search_all', 'alphanohtml') != '') ?GETPOST('search_all', 'alphanohtml') : GETPOST('sall', 'alphanohtml')); -$type = GETPOST("type", "int"); +$type = GETPOSTISSET('type') ? GETPOST('type', 'int') : Product::TYPE_PRODUCT; $search_barcode = GETPOST("search_barcode", 'alpha'); $search_warehouse = GETPOST('search_warehouse', 'alpha'); $search_batch = GETPOST('search_batch', 'alpha'); -$catid = GETPOST('catid', 'int'); $toolowstock = GETPOST('toolowstock'); $tosell = GETPOST("tosell"); $tobuy = GETPOST("tobuy"); $fourn_id = GETPOST("fourn_id", 'int'); $sbarcode = GETPOST("sbarcode", 'int'); +$search_stock_physique = GETPOST('search_stock_physique', 'alpha'); -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page < 0) { $page = 0; @@ -72,7 +72,11 @@ $offset = $limit * $page; // Load sale and categ filters $search_sale = GETPOST("search_sale"); -$search_categ = GETPOST("search_categ"); +if (GETPOSTISSET('catid')) { + $search_categ = GETPOST('catid', 'int'); +} else { + $search_categ = GETPOST('search_categ', 'int'); +} // Get object canvas (By default, this is not defined, so standard usage of dolibarr) $canvas = GETPOST("canvas"); @@ -102,13 +106,12 @@ if (GETPOST('button_removefilter_x', 'alpha') || GETPOST('button_removefilter.x' $tobuy = ""; $search_sale = ""; $search_categ = ""; - $type = ""; - $catid = ''; $toolowstock = ''; $search_batch = ''; $search_warehouse = ''; $fourn_id = ''; $sbarcode = ''; + $search_stock_physique = ''; } @@ -135,13 +138,22 @@ $sql .= ' LEFT JOIN '.MAIN_DB_PREFIX.'product_stock as ps on p.rowid = ps.fk_pro $sql .= ' LEFT JOIN '.MAIN_DB_PREFIX.'entrepot as e on ps.fk_entrepot = e.rowid'; // Link on unique key $sql .= ' LEFT JOIN '.MAIN_DB_PREFIX.'product_batch as pb on pb.fk_product_stock = ps.rowid'; // Detail for each lot on each warehouse $sql .= ' LEFT JOIN '.MAIN_DB_PREFIX.'product_lot as pl on pl.fk_product = p.rowid AND pl.batch = pb.batch'; // Link on unique key -// We'll need this table joined to the select in order to filter by categ -if ($search_categ > 0) { - $sql .= ", ".MAIN_DB_PREFIX."categorie_product as cp"; -} $sql .= " WHERE p.entity IN (".getEntity('product').")"; -if ($search_categ > 0) { - $sql .= " AND p.rowid = cp.fk_product"; // Join for the needed table to filter by categ +if (!empty($search_categ) && $search_categ != '-1') { + $sql .= " AND "; + if ($search_categ == -2) { + $sql .= " NOT EXISTS "; + } else { + $sql .= " EXISTS "; + } + $sql .= "("; + $sql .= " SELECT cp.fk_categorie, cp.fk_product"; + $sql .= " FROM " . MAIN_DB_PREFIX . "categorie_product as cp"; + $sql .= " WHERE cp.fk_product = p.rowid"; // Join for the needed table to filter by categ + if ($search_categ > 0) { + $sql .= " AND cp.fk_categorie = " . ((int) $search_categ); + } + $sql .= ")"; } if ($sall) { $sql .= natural_search(array('p.ref', 'p.label', 'p.description', 'p.note'), $sall); @@ -172,16 +184,9 @@ if (!empty($tobuy)) { if (!empty($canvas)) { $sql .= " AND p.canvas = '".$db->escape($canvas)."'"; } -if ($catid > 0) { - $sql .= " AND cp.fk_categorie = ".((int) $catid); -} if ($fourn_id > 0) { $sql .= " AND p.rowid = pf.fk_product AND pf.fk_soc = ".((int) $fourn_id); } -// Insert categ filter -if ($search_categ > 0) { - $sql .= " AND cp.fk_categorie = ".((int) $search_categ); -} if ($search_warehouse) { $sql .= natural_search("e.ref", $search_warehouse); } @@ -195,8 +200,22 @@ $sql .= " ps.fk_entrepot,"; $sql .= " e.ref, e.lieu, e.fk_parent,"; $sql .= " pb.batch, pb.eatby, pb.sellby,"; $sql .= " pl.rowid, pl.eatby, pl.sellby"; +$sql_having = ''; if ($toolowstock) { - $sql .= " HAVING SUM(".$db->ifsql('ps.reel IS NULL', '0', 'ps.reel').") < p.seuil_stock_alerte"; // Not used yet + $sql_having .= " HAVING SUM(".$db->ifsql('ps.reel IS NULL', '0', 'ps.reel').") < p.seuil_stock_alerte"; // Not used yet +} +if ($search_stock_physique != '') { + $natural_search_physique = natural_search('SUM(' . $db->ifsql('pb.qty IS NULL', '0', 'pb.qty') . ')', $search_stock_physique, 1, 1); + $natural_search_physique = " " . substr($natural_search_physique, 1, -1); // remove first "(" and last ")" characters + if (!empty($sql_having)) { + $sql_having .= " AND"; + } else { + $sql_having .= " HAVING"; + } + $sql_having .= $natural_search_physique; +} +if (!empty($sql_having)) { + $sql .= $sql_having; } $sql .= $db->order($sortfield, $sortorder); @@ -248,7 +267,7 @@ if ($resql) { if ($tobuy) { $param .= "&tobuy=".urlencode($tobuy); } - if ($type) { + if ($type != '') { $param .= "&type=".urlencode($type); } if ($fourn_id) { @@ -269,18 +288,18 @@ if ($resql) { if ($search_warehouse) { $param .= "&search_warehouse=".urlencode($search_warehouse); } - if ($catid) { - $param .= "&catid=".urlencode($catid); - } if ($toolowstock) { $param .= "&toolowstock=".urlencode($toolowstock); } if ($search_sale) { $param .= "&search_sale=".urlencode($search_sale); } - if ($search_categ > 0) { + if (!empty($search_categ) && $search_categ != '-1') { $param .= "&search_categ=".urlencode($search_categ); } + if ($search_stock_physique) { + $param .= '&search_stock_physique=' . urlencode($search_stock_physique); + } /*if ($eatby) $param.="&eatby=".$eatby; if ($sellby) $param.="&sellby=".$sellby;*/ @@ -295,10 +314,10 @@ if ($resql) { print_barre_liste($texte, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, '', $num, $nbtotalofrecords, 'product', 0, '', '', $limit, 0, 0, 1); - if (!empty($catid)) { + if ($search_categ > 0) { print "
    "; $c = new Categorie($db); - $c->fetch($catid); + $c->fetch($search_categ); $ways = $c->print_all_ways(' > ', 'product/reassortlot.php'); print " > ".$ways[0]."
    \n"; print "

    "; @@ -309,7 +328,7 @@ if ($resql) { if (!empty($conf->categorie->enabled)) { $moreforfilter .= '
    '; $moreforfilter .= img_picto($langs->trans('Categories'), 'category', 'class="pictofixedwidth"'); - $moreforfilter .= $htmlother->select_categories(Categorie::TYPE_PRODUCT, $search_categ, 'search_categ'); + $moreforfilter .= $htmlother->select_categories(Categorie::TYPE_PRODUCT, $search_categ, 'search_categ', 1); $moreforfilter .= '
    '; } //$moreforfilter.=$langs->trans("StockTooLow").' '; @@ -342,14 +361,17 @@ if ($resql) { } print ''; print ''; - print ''; - print ''; if (empty($conf->global->PRODUCT_DISABLE_SELLBY)) { print ''; } if (empty($conf->global->PRODUCT_DISABLE_EATBY)) { print ''; } + // Physical stock + print ''; + print ''; print ''; print ''; print '"; - print_liste_field_titre("Ref", $_SERVER["PHP_SELF"], "p.ref", $param, "", "", $sortfield, $sortorder); - print_liste_field_titre("Label", $_SERVER["PHP_SELF"], "p.label", $param, "", "", $sortfield, $sortorder); + print_liste_field_titre("Ref", $_SERVER["PHP_SELF"], "p.ref", '', $param, "", $sortfield, $sortorder); + print_liste_field_titre("Label", $_SERVER["PHP_SELF"], "p.label", '', $param, "", $sortfield, $sortorder); if (!empty($conf->service->enabled) && $type == 1) { - print_liste_field_titre("Duration", $_SERVER["PHP_SELF"], "p.duration", $param, "", '', $sortfield, $sortorder, 'center '); + print_liste_field_titre("Duration", $_SERVER["PHP_SELF"], "p.duration", '', $param, "", $sortfield, $sortorder, 'center '); } - print_liste_field_titre("Warehouse", $_SERVER["PHP_SELF"], "e.ref", $param, "", '', $sortfield, $sortorder); + print_liste_field_titre("Warehouse", $_SERVER["PHP_SELF"], "e.ref", '', $param, "", $sortfield, $sortorder); //print_liste_field_titre("DesiredStock", $_SERVER["PHP_SELF"], "p.desiredstock",$param,"",'',$sortfield,$sortorder, 'right ); - print_liste_field_titre("Batch", $_SERVER["PHP_SELF"], "pb.batch", $param, "", '', $sortfield, $sortorder, 'center '); + print_liste_field_titre("Batch", $_SERVER["PHP_SELF"], "pb.batch", '', $param, "", $sortfield, $sortorder, 'center '); if (empty($conf->global->PRODUCT_DISABLE_SELLBY)) { - print_liste_field_titre("SellByDate", $_SERVER["PHP_SELF"], "pb.sellby", $param, "", '', $sortfield, $sortorder, 'center '); + print_liste_field_titre("SellByDate", $_SERVER["PHP_SELF"], "pb.sellby", '', $param, "", $sortfield, $sortorder, 'center '); } if (empty($conf->global->PRODUCT_DISABLE_EATBY)) { - print_liste_field_titre("EatByDate", $_SERVER["PHP_SELF"], "pb.eatby", $param, "", '', $sortfield, $sortorder, 'center '); + print_liste_field_titre("EatByDate", $_SERVER["PHP_SELF"], "pb.eatby", '', $param, "", $sortfield, $sortorder, 'center '); } - print_liste_field_titre("PhysicalStock", $_SERVER["PHP_SELF"], "stock_physique", $param, "", '', $sortfield, $sortorder, 'right '); + print_liste_field_titre("PhysicalStock", $_SERVER["PHP_SELF"], "stock_physique", '', $param, "", $sortfield, $sortorder, 'right '); // TODO Add info of running suppliers/customers orders //print_liste_field_titre("TheoreticalStock",$_SERVER["PHP_SELF"], "stock_theorique",$param,"",'',$sortfield,$sortorder, 'right '); print_liste_field_titre(''); diff --git a/htdocs/product/stats/bom.php b/htdocs/product/stats/bom.php index ef4923e89be..b7c4321dfd1 100644 --- a/htdocs/product/stats/bom.php +++ b/htdocs/product/stats/bom.php @@ -50,8 +50,8 @@ $option = ''; // Load variable for pagination $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; @@ -129,11 +129,11 @@ if ($id > 0 || !empty($ref)) { //Calcul total qty and amount for global if full scan list $total_qty_toconsume = 0; $total_qty_toproduce = 0; + $product_cache=array(); $bom_data_result = array(); - //Qauntity to produce - $sql = "SELECT b.rowid as rowid, b.ref, b.status, b.date_valid,"; + $sql = "SELECT b.rowid as rowid, b.ref, b.status, b.date_valid, b.fk_product,"; $sql .= " b.qty as qty_toproduce"; $sql .= " FROM ".MAIN_DB_PREFIX."bom_bom as b"; $sql .= " WHERE "; @@ -166,7 +166,20 @@ if ($id > 0 || !empty($ref)) { $objp = $db->fetch_object($result); $bomtmp->id = $objp->rowid; $bomtmp->ref = $objp->ref; + $product = new Product($db); + if (!empty($objp->fk_product)) { + if (!array_key_exists($product->id, $product_cache)) { + $resultFetch = $product->fetch($objp->fk_product); + if ($resultFetch < 0) { + setEventMessages($product->error, $product->errors, 'errors'); + } else { + $product_cache[$product->id] = $product; + } + } + } + $bomtmp->fk_product = $objp->fk_product; $bom_data_result[$objp->rowid]['link'] = $bomtmp->getNomUrl(1, 'production'); + $bom_data_result[$objp->rowid]['product'] = (array_key_exists($objp->fk_product, $product_cache)? $product_cache[$objp->fk_product]->getNomUrl(1): ''); $bom_data_result[$objp->rowid]['qty_toproduce'] += ($objp->qty_toproduce > 0 ? $objp->qty_toproduce : 0); $bom_data_result[$objp->rowid]['qty_toconsume'] = 0; $bom_data_result[$objp->rowid]['date_valid'] = dol_print_date($db->jdate($objp->date_valid), 'dayhour'); @@ -180,7 +193,7 @@ if ($id > 0 || !empty($ref)) { $db->free($result); //Qauntity to consume - $sql = "SELECT b.rowid as rowid, b.ref, b.status, b.date_valid,"; + $sql = "SELECT b.rowid as rowid, b.ref, b.status, b.date_valid, b.fk_product,"; $sql .= " SUM(bl.qty) as qty_toconsume"; $sql .= " FROM ".MAIN_DB_PREFIX."bom_bom as b"; $sql .= " INNER JOIN ".MAIN_DB_PREFIX."bom_bomline as bl ON bl.fk_bom=b.rowid"; @@ -214,9 +227,22 @@ if ($id > 0 || !empty($ref)) { $objp = $db->fetch_object($result); $bomtmp->id = $objp->rowid; $bomtmp->ref = $objp->ref; + $product = new Product($db); + if (!empty($objp->fk_product)) { + if (!array_key_exists($product->id, $product_cache)) { + $resultFetch = $product->fetch($objp->fk_product); + if ($resultFetch < 0) { + setEventMessages($product->error, $product->errors, 'errors'); + } else { + $product_cache[$product->id] = $product; + } + } + } + $bomtmp->fk_product = $objp->fk_product; if (!array_key_exists($objp->rowid, $bom_data_result)) { $bom_data_result[$objp->rowid]['link'] = $bomtmp->getNomUrl(1, 'production'); + $bom_data_result[$objp->rowid]['product'] = (array_key_exists($objp->fk_product, $product_cache)? $product_cache[$objp->fk_product]->getNomUrl(1): ''); $bom_data_result[$objp->rowid]['qty_toproduce'] = 0; $bom_data_result[$objp->rowid]['qty_toconsume'] += ($objp->qty_toconsume > 0 ? $objp->qty_toconsume : 0); $bom_data_result[$objp->rowid]['date_valid'] = dol_print_date($db->jdate($objp->date_valid), 'dayhour'); @@ -232,7 +258,6 @@ if ($id > 0 || !empty($ref)) { } $db->free($result); - if ($limit > 0 && $limit != $conf->liste_limit) { $option .= '&limit='.urlencode($limit); } @@ -265,6 +290,7 @@ if ($id > 0 || !empty($ref)) { print ''; print_liste_field_titre("Ref", $_SERVER["PHP_SELF"], "b.rowid", "", "&id=".$product->id, '', $sortfield, $sortorder); + print_liste_field_titre("Product", $_SERVER["PHP_SELF"], "b.fk_product", "", "&id=".$product->id, '', $sortfield, $sortorder); print_liste_field_titre("Date", $_SERVER["PHP_SELF"], "b.date_valid", "", "&id=".$product->id, 'align="center"', $sortfield, $sortorder); print_liste_field_titre("RowMaterial", $_SERVER["PHP_SELF"], "", "", "&id=".$product->id, '', $sortfield, $sortorder, 'center '); print_liste_field_titre("Finished", $_SERVER["PHP_SELF"], "", "", "&id=".$product->id, '', $sortfield, $sortorder, 'center '); @@ -277,6 +303,9 @@ if ($id > 0 || !empty($ref)) { print '\n"; + print '\n"; print ""; print ''; diff --git a/htdocs/product/stats/card.php b/htdocs/product/stats/card.php index ef4abef5173..f45a851ecad 100644 --- a/htdocs/product/stats/card.php +++ b/htdocs/product/stats/card.php @@ -45,6 +45,7 @@ $ref = GETPOST('ref', 'alpha'); $mode = (GETPOST('mode', 'alpha') ? GETPOST('mode', 'alpha') : 'byunit'); $search_year = GETPOST('search_year', 'int'); $search_categ = GETPOST('search_categ', 'int'); +$notab = GETPOST('notab', 'int'); $error = 0; $mesg = ''; @@ -56,7 +57,7 @@ if (!empty($user->socid)) { } // Security check -$fieldvalue = (!empty($id) ? $id : $ref); +$fieldvalue = ($id > 0 ? $id : $ref); $fieldtype = (!empty($ref) ? 'ref' : 'rowid'); // Initialize technical object to manage hooks of page. Note that conf->hooks_modules contains array of hook context @@ -69,6 +70,11 @@ if (empty($search_year)) { } $moreforfilter = ""; +$object = new Product($db); +if ($id > 0 || !empty($ref)) { + $result = $object->fetch($id, $ref); +} + $result = restrictedArea($user, 'produit|service', $fieldvalue, 'product&product', '', '', $fieldtype); @@ -85,9 +91,10 @@ $result = restrictedArea($user, 'produit|service', $fieldvalue, 'product&product $form = new Form($db); $htmlother = new FormOther($db); -$object = new Product($db); -if (!$id && empty($ref)) { +if (!($id > 0) && empty($ref) || $notab) { + $notab = 1; + llxHeader("", $langs->trans("ProductStatistics")); $type = GETPOST('type', 'int'); @@ -132,7 +139,7 @@ if (!$id && empty($ref)) { } -if ($result && (!empty($id) || !empty($ref))) { +if ($result && ($id > 0 || !empty($ref)) && empty($notab)) { $head = product_prepare_head($object); $titre = $langs->trans("CardProduct".$object->type); $picto = ($object->type == Product::TYPE_SERVICE ? 'service' : 'product'); @@ -145,11 +152,11 @@ if ($result && (!empty($id) || !empty($ref))) { print dol_get_fiche_end(); } -if (empty($id) && empty($ref)) { +if ((!($id > 0) && empty($ref)) || $notab) { $h = 0; $head = array(); - $head[$h][0] = DOL_URL_ROOT.'/product/stats/card.php'.($type != '' ? '?type='.$type : ''); + $head[$h][0] = DOL_URL_ROOT.'/product/stats/card.php'.($type != '' ? '?type='.((int) $type) : ''); $head[$h][1] = $langs->trans("Chart"); $head[$h][2] = 'chart'; $h++; @@ -162,7 +169,7 @@ if (empty($id) && empty($ref)) { $title = $langs->trans("ListProductByPopularity"); } - $head[$h][0] = DOL_URL_ROOT.'/product/popuprop.php'.($type != '' ? '?type='.$type : ''); + $head[$h][0] = DOL_URL_ROOT.'/product/popuprop.php'.($type != '' ? '?type='.((int) $type) : ''); $head[$h][1] = $langs->trans("ProductsPerPopularity"); $head[$h][2] = 'popularity'; $h++; @@ -171,29 +178,39 @@ if (empty($id) && empty($ref)) { } -if ($result || empty($id)) { +if ($result || !($id > 0)) { print ''; print ''; - print ''; + if (empty($id) || $notab) { + print ''; + } print '
    '; if ($object->multiprices_base_type[$soc->price_level] == 'TTC') { - print price($object->multiprices_ttc[$soc->price_level]); + print ''.price($object->multiprices_ttc[$soc->price_level]).''; } else { - print price($object->multiprices[$soc->price_level]); + print ''.price($object->multiprices[$soc->price_level]).''; } if ($object->multiprices_base_type[$soc->price_level]) { print ' '.$langs->trans($object->multiprices_base_type[$soc->price_level]); @@ -827,22 +948,23 @@ if (!empty($conf->global->PRODUIT_MULTIPRICES) || !empty($conf->global->PRODUIT_ } // TVA + print ''; print '
    '.$langs->trans("DefaultTaxRate").''; $positiverates = ''; if (price2num($object->tva_tx)) { - $positiverates .= ($positiverates ? '/' : '').price2num($object->tva_tx); + $positiverates .= ($positiverates ? '/' : '').price2num($object->tva_tx); } if (price2num($object->localtax1_type)) { - $positiverates .= ($positiverates ? '/' : '').price2num($object->localtax1_tx); + $positiverates .= ($positiverates ? '/' : '').price2num($object->localtax1_tx); } if (price2num($object->localtax2_type)) { - $positiverates .= ($positiverates ? '/' : '').price2num($object->localtax2_tx); + $positiverates .= ($positiverates ? '/' : '').price2num($object->localtax2_tx); } if (empty($positiverates)) { $positiverates = '0'; } - echo vatrate($positiverates.($object->default_vat_code ? ' ('.$object->default_vat_code.')' : ''), '%', $object->tva_npr); + print vatrate($positiverates.($object->default_vat_code ? ' ('.$object->default_vat_code.')' : ''), true, $object->tva_npr, 1); /* if ($object->default_vat_code) { @@ -890,15 +1012,15 @@ if (!empty($conf->global->PRODUIT_MULTIPRICES) || !empty($conf->global->PRODUIT_ print ''.price($object->multiprices_ttc[$i]); + print ''.price($object->multiprices_ttc[$i]); } else { - print ''.price($object->multiprices[$i]); + print ''.price($object->multiprices[$i]); } if ($object->multiprices_base_type[$i]) { - print ' '.$langs->trans($object->multiprices_base_type [$i]).'   '; + print ''; + print ' 
        '; + print ''; + print '   '; @@ -360,21 +382,21 @@ if ($resql) { //Line for column titles print "
    '; print $data['link']; print "'; + print $data['product']; + print ""; print $data['date_valid']."'.$data['qty_toconsume'].'
    '; print ''; - if (empty($id)) { + if (!($id > 0) || $notab) { // Type - print ''; + + // Product + print ''; // Tag if ($conf->categorie->enabled) { print ''; } + } else { + print ''; } // Year @@ -224,7 +241,7 @@ if ($result || empty($id)) { } if ($mode == 'bynumber') { - print 'id).($type != '' ? '&type='.$type : '').'&mode=byunit&search_year='.$search_year.'">'; + print ''; } else { print ''; } @@ -240,7 +257,7 @@ if ($result || empty($id)) { } if ($mode == 'byunit') { - print 'id).($type != '' ? '&type='.$type : '').'&mode=bynumber&search_year='.$search_year.'">'; + print ''; } else { print ''; } @@ -258,10 +275,8 @@ if ($result || empty($id)) { } print '
    '; - //print '
    '.$langs->trans("Filter").'
    '.$langs->trans("ProductsAndServices").''; + print '
    '.$langs->trans("Type").''; $array = array('-1'=>' ', '0'=>$langs->trans('Product'), '1'=>$langs->trans('Service')); - print $form->selectarray('type', $array, $type); + print $form->selectarray('type', $array, $type, 0, 0, 0, '', 0, 0, 0, '', 'minwidth100'); + print '
    '.$langs->trans("ProductOrService").''; + print img_picto('', 'product', 'class="pictofixedwidth"'); + print $form->select_produits($id, 'id', '', 0, 0, 1, 2, '', ($conf->dol_optimize_smallscreen ? 1 : 0), array(), 0, '1', 0, 'widthcentpercentminusx maxwidth400'); print '
    '.$langs->trans("Categories").''; $moreforfilter .= img_picto($langs->trans("Categories"), 'category', 'class="pictofixedwidth"'); - $moreforfilter .= $htmlother->select_categories(Categorie::TYPE_PRODUCT, $search_categ, 'search_categ', 1, 1, 'widthcentpercentminusx maxwidth300'); + $moreforfilter .= $htmlother->select_categories(Categorie::TYPE_PRODUCT, $search_categ, 'search_categ', 1, 1, 'widthcentpercentminusx maxwidth400'); print $moreforfilter; print '
    '; - - // Generation des graphs - $dir = (!empty($conf->product->multidir_temp[$object->entity]) ? $conf->product->multidir_temp[$object->entity] : $conf->service->multidir_temp[$object->entity]); + // Generation of graphs + $dir = (!empty($conf->product->multidir_temp[$conf->entity]) ? $conf->product->multidir_temp[$conf->entity] : $conf->service->multidir_temp[$conf->entity]); if ($object->id > 0) { // We are on statistics for a dedicated product if (!file_exists($dir.'/'.$object->id)) { if (dol_mkdir($dir.'/'.$object->id) < 0) { @@ -385,7 +400,7 @@ if ($result || empty($id)) { $px->SetShading(3); //print 'x '.$key.' '.$graphfiles[$key]['file']; - $url = DOL_URL_ROOT.'/viewimage.php?modulepart='.$graphfiles[$key]['modulepart'].'&entity='.$object->entity.'&file='.urlencode($graphfiles[$key]['file']); + $url = DOL_URL_ROOT.'/viewimage.php?modulepart='.$graphfiles[$key]['modulepart'].'&entity='.((int) $object->entity).'&file='.urlencode($graphfiles[$key]['file']).($notab ? '¬ab='.$notab : ''); $px->draw($dir."/".$graphfiles[$key]['file'], $url); $graphfiles[$key]['total'] = $px->total(); @@ -446,9 +461,13 @@ if ($result || empty($id)) { } else { $dategenerated = ($mesg ? ''.$mesg.'' : $langs->trans("ChartNotGenerated")); } - $linktoregenerate = 'id).((string) $type != '' ? '&type='.$type : '').'&action=recalcul&mode='.$mode.'&search_year='.$search_year.'&search_categ='.$search_categ.'">'.img_picto($langs->trans("ReCalculate").' ('.$dategenerated.')', 'refresh').''; + $linktoregenerate = ' 0 ? '&search_categ='.((int) $search_categ) : '').'">'; + $linktoregenerate .= img_picto($langs->trans("ReCalculate").' ('.$dategenerated.')', 'refresh'); + $linktoregenerate .= ''; + // Show graph + print '
    '; print '
    '; // Label print ''; print '
    '; @@ -461,6 +480,7 @@ if ($result || empty($id)) { print $graphfiles[$key]['output']; print '
    '; + print '
    '; if ($i % 2 == 0) { print "\n".'
    '."\n"; @@ -480,7 +500,7 @@ if ($result || empty($id)) { } } -if (!$id) { +if (!($id > 0)) { print dol_get_fiche_end(); } diff --git a/htdocs/product/stats/commande.php b/htdocs/product/stats/commande.php index abfd329dfa4..9f38f68ee33 100644 --- a/htdocs/product/stats/commande.php +++ b/htdocs/product/stats/commande.php @@ -49,8 +49,8 @@ $hookmanager->initHooks(array('productstatsorder')); // Load variable for pagination $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/product/stats/contrat.php b/htdocs/product/stats/contrat.php index e44619d1b19..0c569d3530c 100644 --- a/htdocs/product/stats/contrat.php +++ b/htdocs/product/stats/contrat.php @@ -46,8 +46,8 @@ $hookmanager->initHooks(array('productstatscontract')); // Load variable for pagination $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/product/stats/facture.php b/htdocs/product/stats/facture.php index 8da6e97f55c..13c6329b34f 100644 --- a/htdocs/product/stats/facture.php +++ b/htdocs/product/stats/facture.php @@ -52,8 +52,8 @@ $showmessage = GETPOST('showmessage'); // Load variable for pagination $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/product/stats/facture_fournisseur.php b/htdocs/product/stats/facture_fournisseur.php index d61b6de9491..9db71e92148 100644 --- a/htdocs/product/stats/facture_fournisseur.php +++ b/htdocs/product/stats/facture_fournisseur.php @@ -50,8 +50,8 @@ $hookmanager->initHooks(array('productstatssupplierinvoice')); // Load variable for pagination $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/product/stats/mo.php b/htdocs/product/stats/mo.php index c63034e95a6..693f1fbae03 100644 --- a/htdocs/product/stats/mo.php +++ b/htdocs/product/stats/mo.php @@ -46,8 +46,8 @@ $hookmanager->initHooks(array('productstatsmo')); // Load variable for pagination $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; diff --git a/htdocs/product/stock/card.php b/htdocs/product/stock/card.php index e485ea3d543..db3e8b2ea69 100644 --- a/htdocs/product/stock/card.php +++ b/htdocs/product/stock/card.php @@ -54,8 +54,8 @@ $id = GETPOST('id', 'int'); $socid = GETPOST('socid', 'int'); $ref = GETPOST('ref', 'alpha'); -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); if (!$sortfield) { $sortfield = "p.ref"; } @@ -159,6 +159,7 @@ if (empty($reshook)) { $categories = GETPOST('categories', 'array'); $object->setCategories($categories); if (!empty($backtopage)) { + $backtopage = str_replace("__ID__", $id, $backtopage); header("Location: ".$backtopage); exit; } else { @@ -207,7 +208,7 @@ if (empty($reshook)) { $object->fax = GETPOST("fax"); // Fill array 'array_options' with data from add form - $ret = $extrafields->setOptionalsFromPost(null, $object); + $ret = $extrafields->setOptionalsFromPost(null, $object, '@GETPOSTISSET'); if ($ret < 0) { $error++; } @@ -451,9 +452,10 @@ if ($action == 'create') { if (!empty($object->fk_project)) { $proj = new Project($db); $proj->fetch($object->fk_project); - $morehtmlref .= ''; - $morehtmlref .= $proj->ref; - $morehtmlref .= ''; + $morehtmlref .= ' : '.$proj->getNomUrl(1); + if ($proj->title) { + $morehtmlref .= ' - '.$proj->title; + } } else { $morehtmlref .= ''; } @@ -958,21 +960,20 @@ if ($action != 'create' && $action != 'edit' && $action != 'delete') { $delallowed = $usercancreate; $modulepart = 'stock'; - print $formfile->showdocuments($modulepart, $object->ref, $filedir, $urlsource, $genallowed, $delallowed, $object->model_pdf, 0, 0, 0, 28, 0, '', 0, '', $object->default_lang, '', $object); + print $formfile->showdocuments($modulepart, $objectref, $filedir, $urlsource, $genallowed, $delallowed, $object->model_pdf, 0, 0, 0, 28, 0, '', 0, '', $object->default_lang, '', $object); $somethingshown = $formfile->numoffiles; print '
    '; $MAXEVENT = 10; - $morehtmlright = ''; - $morehtmlright .= $langs->trans("SeeAll"); - $morehtmlright .= ''; + $morehtmlcenter = ''; + //$morehtmlcenter = dolGetButtonTitle($langs->trans('SeeAll'), '', 'fa fa-list-alt imgforviewmode', DOL_URL_ROOT.'/product/stock/agenda.php?id='.$object->id); // List of actions on element include_once DOL_DOCUMENT_ROOT.'/core/class/html.formactions.class.php'; $formactions = new FormActions($db); - $somethingshown = $formactions->showactions($object, 'stock', 0, 1, '', $MAXEVENT, '', $morehtmlright); // Show all action for product + $somethingshown = $formactions->showactions($object, 'stock', 0, 1, '', $MAXEVENT, '', $morehtmlcenter); // Show all action for product print '
    '; } diff --git a/htdocs/product/stock/class/api_stockmovements.class.php b/htdocs/product/stock/class/api_stockmovements.class.php index 19f23edd4f4..544485060af 100644 --- a/htdocs/product/stock/class/api_stockmovements.class.php +++ b/htdocs/product/stock/class/api_stockmovements.class.php @@ -104,13 +104,14 @@ class StockMovements extends DolibarrApi } $sql = "SELECT t.rowid"; - $sql .= " FROM ".MAIN_DB_PREFIX."stock_mouvement as t"; + $sql .= " FROM ".$this->db->prefix()."stock_mouvement as t"; //$sql.= ' WHERE t.entity IN ('.getEntity('stock').')'; $sql .= ' WHERE 1 = 1'; // Add sql filters if ($sqlfilters) { - if (!DolibarrApi::_checkFilters($sqlfilters)) { - throw new RestException(503, 'Error when validating parameter sqlfilters '.$sqlfilters); + $errormessage = ''; + if (!DolibarrApi::_checkFilters($sqlfilters, $errormessage)) { + throw new RestException(503, 'Error when validating parameter sqlfilters -> '.$errormessage); } $regexstring = '\(([^:\'\(\)]+:[^:\'\(\)]+:[^\(\)]+)\)'; $sql .= " AND (".preg_replace_callback('/'.$regexstring.'/', 'DolibarrApi::_forge_criteria_callback', $sqlfilters).")"; @@ -155,14 +156,16 @@ class StockMovements extends DolibarrApi * $price Can be set to update AWP (Average Weighted Price) when you make a stock increase * $dlc Eat-by date. Will be used if lot does not exists yet and will be created. * $dluo Sell-by date. Will be used if lot does not exists yet and will be created. - * + * * @param int $product_id Id product id {@min 1} {@from body} {@required true} * @param int $warehouse_id Id warehouse {@min 1} {@from body} {@required true} * @param float $qty Qty to add (Use negative value for a stock decrease) {@from body} {@required true} + * @param int $type Optionally specify the type of movement. 0=input (stock increase by a stock transfer), 1=output (stock decrease by a stock transfer), 2=output (stock decrease), 3=input (stock increase). {@from body} {@type int} * @param string $lot Lot {@from body} * @param string $movementcode Movement code {@example INV123} {@from body} * @param string $movementlabel Movement label {@example Inventory number 123} {@from body} * @param string $price To update AWP (Average Weighted Price) when you make a stock increase (qty must be higher then 0). {@from body} + * @param string $datem Date of movement {@from body} {@type date} * @param string $dlc Eat-by date. {@from body} {@type date} * @param string $dluo Sell-by date. {@from body} {@type date} * @param string $origin_type Origin type (Element of source object, like 'project', 'inventory', ...) @@ -171,7 +174,7 @@ class StockMovements extends DolibarrApi * @return int ID of stock movement * @throws RestException */ - public function post($product_id, $warehouse_id, $qty, $lot = '', $movementcode = '', $movementlabel = '', $price = '', $dlc = '', $dluo = '', $origin_type = '', $origin_id = 0) + public function post($product_id, $warehouse_id, $qty, $type = 2, $lot = '', $movementcode = '', $movementlabel = '', $price = '', $datem = '', $dlc = '', $dluo = '', $origin_type = '', $origin_id = 0) { if (!DolibarrApiAccess::$user->rights->stock->creer) { throw new RestException(401); @@ -182,17 +185,20 @@ class StockMovements extends DolibarrApi } // Type increase or decrease - $type = 2; - if ($qty >= 0) { + if ($type == 1 && $qty >= 0) { + $type = 0; + } + if ($type == 2 && $qty >= 0) { $type = 3; } require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php'; $eatBy = empty($dluo) ? '' : dol_stringtotime($dluo); $sellBy = empty($dlc) ? '' : dol_stringtotime($dlc); + $dateMvt = empty($datem) ? '' : dol_stringtotime($datem); $this->stockmovement->setOrigin($origin_type, $origin_id); - if ($this->stockmovement->_create(DolibarrApiAccess::$user, $product_id, $warehouse_id, $qty, $type, $price, $movementlabel, $movementcode, '', $eatBy, $sellBy, $lot) <= 0) { + if ($this->stockmovement->_create(DolibarrApiAccess::$user, $product_id, $warehouse_id, $qty, $type, $price, $movementlabel, $movementcode, $dateMvt, $eatBy, $sellBy, $lot) <= 0) { $errormessage = $this->stockmovement->error; if (empty($errormessage)) { $errormessage = join(',', $this->stockmovement->errors); diff --git a/htdocs/product/stock/class/api_warehouses.class.php b/htdocs/product/stock/class/api_warehouses.class.php index 3bddbaff8f9..0cf0e57fe3a 100644 --- a/htdocs/product/stock/class/api_warehouses.class.php +++ b/htdocs/product/stock/class/api_warehouses.class.php @@ -104,9 +104,9 @@ class Warehouses extends DolibarrApi } $sql = "SELECT t.rowid"; - $sql .= " FROM ".MAIN_DB_PREFIX."entrepot as t"; + $sql .= " FROM ".$this->db->prefix()."entrepot as t"; if ($category > 0) { - $sql .= ", ".MAIN_DB_PREFIX."categorie_societe as c"; + $sql .= ", ".$this->db->prefix()."categorie_societe as c"; } $sql .= ' WHERE t.entity IN ('.getEntity('stock').')'; // Select warehouses of given category @@ -116,8 +116,9 @@ class Warehouses extends DolibarrApi } // Add sql filters if ($sqlfilters) { - if (!DolibarrApi::_checkFilters($sqlfilters)) { - throw new RestException(503, 'Error when validating parameter sqlfilters '.$sqlfilters); + $errormessage = ''; + if (!DolibarrApi::_checkFilters($sqlfilters, $errormessage)) { + throw new RestException(503, 'Error when validating parameter sqlfilters -> '.$errormessage); } $regexstring = '\(([^:\'\(\)]+:[^:\'\(\)]+:[^\(\)]+)\)'; $sql .= " AND (".preg_replace_callback('/'.$regexstring.'/', 'DolibarrApi::_forge_criteria_callback', $sqlfilters).")"; diff --git a/htdocs/product/stock/class/entrepot.class.php b/htdocs/product/stock/class/entrepot.class.php index fe36b6364fc..155c525de8c 100644 --- a/htdocs/product/stock/class/entrepot.class.php +++ b/htdocs/product/stock/class/entrepot.class.php @@ -204,13 +204,13 @@ class Entrepot extends CommonObject $this->db->begin(); - $sql = "INSERT INTO ".MAIN_DB_PREFIX."entrepot (ref, entity, datec, fk_user_author, fk_parent, fk_project)"; + $sql = "INSERT INTO ".$this->db->prefix()."entrepot (ref, entity, datec, fk_user_author, fk_parent, fk_project)"; $sql .= " VALUES ('".$this->db->escape($this->label)."', ".((int) $conf->entity).", '".$this->db->idate($now)."', ".((int) $user->id).", ".($this->fk_parent > 0 ? ((int) $this->fk_parent) : "NULL").", ".($this->fk_project > 0 ? ((int) $this->fk_project) : "NULL").")"; dol_syslog(get_class($this)."::create", LOG_DEBUG); $result = $this->db->query($sql); if ($result) { - $id = $this->db->last_insert_id(MAIN_DB_PREFIX."entrepot"); + $id = $this->db->last_insert_id($this->db->prefix()."entrepot"); if ($id > 0) { $this->id = $id; @@ -293,7 +293,7 @@ class Entrepot extends CommonObject $this->town = trim($this->town); $this->country_id = ($this->country_id > 0 ? $this->country_id : 0); - $sql = "UPDATE ".MAIN_DB_PREFIX."entrepot"; + $sql = "UPDATE ".$this->db->prefix()."entrepot"; $sql .= " SET ref = '".$this->db->escape($this->label)."'"; $sql .= ", fk_parent = ".(($this->fk_parent > 0) ? $this->fk_parent : "NULL"); $sql .= ", fk_project = ".(($this->fk_project > 0) ? $this->fk_project : "NULL"); @@ -365,7 +365,7 @@ class Entrepot extends CommonObject $elements = array('stock_mouvement', 'product_stock', 'product_warehouse_properties'); foreach ($elements as $table) { if (!$error) { - $sql = "DELETE FROM ".MAIN_DB_PREFIX.$table; + $sql = "DELETE FROM ".$this->db->prefix().$table; $sql .= " WHERE fk_entrepot = ".((int) $this->id); $result = $this->db->query($sql); @@ -388,7 +388,7 @@ class Entrepot extends CommonObject } if (!$error) { - $sql = "DELETE FROM ".MAIN_DB_PREFIX."entrepot"; + $sql = "DELETE FROM ".$this->db->prefix()."entrepot"; $sql .= " WHERE rowid = ".((int) $this->id); $resql1 = $this->db->query($sql); if (!$resql1) { @@ -400,7 +400,7 @@ class Entrepot extends CommonObject if (!$error) { // Update denormalized fields because we change content of produt_stock. Warning: Do not use "SET p.stock", does not works with pgsql - $sql = "UPDATE ".MAIN_DB_PREFIX."product as p SET stock = (SELECT SUM(ps.reel) FROM ".MAIN_DB_PREFIX."product_stock as ps WHERE ps.fk_product = p.rowid)"; + $sql = "UPDATE ".$this->db->prefix()."product as p SET stock = (SELECT SUM(ps.reel) FROM ".$this->db->prefix()."product_stock as ps WHERE ps.fk_product = p.rowid)"; $resql2 = $this->db->query($sql); if (!$resql2) { $error++; @@ -441,11 +441,11 @@ class Entrepot extends CommonObject $sql = "SELECT rowid, entity, fk_parent, fk_project, ref as label, description, statut, lieu, address, zip, town, fk_pays as country_id, phone, fax,"; $sql .= " model_pdf, import_key"; - $sql .= " FROM ".MAIN_DB_PREFIX."entrepot"; + $sql .= " FROM ".$this->db->prefix()."entrepot"; if ($id) { $sql .= " WHERE rowid = ".((int) $id); } else { - $sql .= " WHERE entity = ".$conf->entity; + $sql .= " WHERE entity IN (".getEntity('stock').")"; if ($ref) { $sql .= " AND ref = '".$this->db->escape($ref)."'"; } @@ -506,7 +506,7 @@ class Entrepot extends CommonObject public function info($id) { $sql = "SELECT e.rowid, e.datec, e.tms as datem, e.fk_user_author"; - $sql .= " FROM ".MAIN_DB_PREFIX."entrepot as e"; + $sql .= " FROM ".$this->db->prefix()."entrepot as e"; $sql .= " WHERE e.rowid = ".((int) $id); dol_syslog(get_class($this)."::info", LOG_DEBUG); @@ -553,7 +553,7 @@ class Entrepot extends CommonObject $liste = array(); $sql = "SELECT rowid, ref as label"; - $sql .= " FROM ".MAIN_DB_PREFIX."entrepot"; + $sql .= " FROM ".$this->db->prefix()."entrepot"; $sql .= " WHERE entity IN (".getEntity('stock').")"; $sql .= " AND statut = ".((int) $status); @@ -583,8 +583,8 @@ class Entrepot extends CommonObject $ret = array(); $sql = "SELECT count(distinct p.rowid) as nb"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_stock as ps"; - $sql .= ", ".MAIN_DB_PREFIX."product as p"; + $sql .= " FROM ".$this->db->prefix()."product_stock as ps"; + $sql .= ", ".$this->db->prefix()."product as p"; $sql .= " WHERE ps.fk_entrepot = ".((int) $this->id); $sql .= " AND ps.fk_product = p.rowid"; @@ -625,10 +625,10 @@ class Entrepot extends CommonObject } else { $sql = "SELECT sum(ps.reel) as nb, sum(ps.reel * p.pmp) as value"; } - $sql .= " FROM ".MAIN_DB_PREFIX."product_stock as ps"; - $sql .= ", ".MAIN_DB_PREFIX."product as p"; + $sql .= " FROM ".$this->db->prefix()."product_stock as ps"; + $sql .= ", ".$this->db->prefix()."product as p"; if ($separatedPMP) { - $sql .= ", ".MAIN_DB_PREFIX."product_perentity as pa"; + $sql .= ", ".$this->db->prefix()."product_perentity as pa"; } $sql .= " WHERE ps.fk_entrepot = ".((int) $this->id); if ($separatedPMP) { @@ -760,7 +760,7 @@ class Entrepot extends CommonObject global $action; $hookmanager->initHooks(array('warehousedao')); - $parameters = array('id'=>$this->id, 'getnomurl'=>$result, 'withpicto' => $withpicto, 'option' => $option, 'showfullpath' => $showfullpath, 'notooltip'=> $notooltip); + $parameters = array('id'=>$this->id, 'getnomurl' => &$result, 'withpicto' => $withpicto, 'option' => $option, 'showfullpath' => $showfullpath, 'notooltip'=> $notooltip); $reshook = $hookmanager->executeHooks('getNomUrl', $parameters, $this, $action); // Note that $action and $object may have been modified by some hooks if ($reshook > 0) { $result = $hookmanager->resPrint; @@ -819,7 +819,7 @@ class Entrepot extends CommonObject $parentid = $this->fk_parent; // If parent_id not defined on current object, we do not start consecutive searches of parents $i = 0; while ($parentid > 0 && $i < $protection) { - $sql = "SELECT fk_parent FROM ".MAIN_DB_PREFIX."entrepot WHERE rowid = ".((int) $parentid); + $sql = "SELECT fk_parent FROM ".$this->db->prefix()."entrepot WHERE rowid = ".((int) $parentid); $resql = $this->db->query($sql); if ($resql) { $objarbo = $this->db->fetch_object($resql); @@ -852,9 +852,9 @@ class Entrepot extends CommonObject { // phpcs:enable - $sql = 'SELECT rowid - FROM '.MAIN_DB_PREFIX.'entrepot - WHERE fk_parent = '.((int) $id); + $sql = "SELECT rowid + FROM ".$this->db->prefix()."entrepot + WHERE fk_parent = ".((int) $id); $resql = $this->db->query($sql); if ($resql) { diff --git a/htdocs/product/stock/class/mouvementstock.class.php b/htdocs/product/stock/class/mouvementstock.class.php index 3a43d9ee6bb..67119ff6839 100644 --- a/htdocs/product/stock/class/mouvementstock.class.php +++ b/htdocs/product/stock/class/mouvementstock.class.php @@ -156,7 +156,7 @@ class MouvementStock extends CommonObject * @param int $price Unit price HT of product, used to calculate average weighted price (AWP or PMP in french). If 0, average weighted price is not changed. * @param string $label Label of stock movement * @param string $inventorycode Inventory code - * @param string $datem Force date of movement + * @param integer|string $datem Force date of movement * @param integer|string $eatby eat-by date. Will be used if lot does not exists yet and will be created. * @param integer|string $sellby sell-by date. Will be used if lot does not exists yet and will be created. * @param string $batch batch number @@ -287,7 +287,7 @@ class MouvementStock extends CommonObject // If found and eatby/sellby not defined into table and provided, we update table // If found and eatby/sellby not defined into table and not provided, we do nothing // If not found, we add record - $sql = "SELECT pb.rowid, pb.batch, pb.eatby, pb.sellby FROM ".MAIN_DB_PREFIX."product_lot as pb"; + $sql = "SELECT pb.rowid, pb.batch, pb.eatby, pb.sellby FROM ".$this->db->prefix()."product_lot as pb"; $sql .= " WHERE pb.fk_product = ".((int) $fk_product)." AND pb.batch = '".$this->db->escape($batch)."'"; dol_syslog(get_class($this)."::_create scan serial for this product to check if eatby and sellby match", LOG_DEBUG); $resql = $this->db->query($sql); @@ -435,11 +435,11 @@ class MouvementStock extends CommonObject $origin_id = 0; } - $sql = "INSERT INTO ".MAIN_DB_PREFIX."stock_mouvement("; + $sql = "INSERT INTO ".$this->db->prefix()."stock_mouvement("; $sql .= " datem, fk_product, batch, eatby, sellby,"; $sql .= " fk_entrepot, value, type_mouvement, fk_user_author, label, inventorycode, price, fk_origin, origintype, fk_projet"; $sql .= ")"; - $sql .= " VALUES ('".$this->db->idate($now)."', ".((int) $this->product_id).", "; + $sql .= " VALUES ('".$this->db->idate($this->datem)."', ".((int) $this->product_id).", "; $sql .= " ".($batch ? "'".$this->db->escape($batch)."'" : "null").", "; $sql .= " ".($eatby ? "'".$this->db->idate($eatby)."'" : "null").", "; $sql .= " ".($sellby ? "'".$this->db->idate($sellby)."'" : "null").", "; @@ -457,7 +457,7 @@ class MouvementStock extends CommonObject $resql = $this->db->query($sql); if ($resql) { - $mvid = $this->db->last_insert_id(MAIN_DB_PREFIX."stock_mouvement"); + $mvid = $this->db->last_insert_id($this->db->prefix()."stock_mouvement"); $this->id = $mvid; } else { $this->error = $this->db->lasterror(); @@ -473,7 +473,7 @@ class MouvementStock extends CommonObject // Test if there is already a record for couple (warehouse / product), so later we will make an update or create. $alreadyarecord = 0; if (!$error) { - $sql = "SELECT rowid, reel FROM ".MAIN_DB_PREFIX."product_stock"; + $sql = "SELECT rowid, reel FROM ".$this->db->prefix()."product_stock"; $sql .= " WHERE fk_entrepot = ".((int) $entrepot_id)." AND fk_product = ".((int) $fk_product); // This is a unique key dol_syslog(get_class($this)."::_create check if a record already exists in product_stock", LOG_DEBUG); @@ -524,10 +524,10 @@ class MouvementStock extends CommonObject // Update stock quantity if (!$error) { if ($alreadyarecord > 0) { - $sql = "UPDATE ".MAIN_DB_PREFIX."product_stock SET reel = reel + ".((float) $qty); + $sql = "UPDATE ".$this->db->prefix()."product_stock SET reel = reel + ".((float) $qty); $sql .= " WHERE fk_entrepot = ".((int) $entrepot_id)." AND fk_product = ".((int) $fk_product); } else { - $sql = "INSERT INTO ".MAIN_DB_PREFIX."product_stock"; + $sql = "INSERT INTO ".$this->db->prefix()."product_stock"; $sql .= " (reel, fk_entrepot, fk_product) VALUES "; $sql .= " (".((float) $qty).", ".((int) $entrepot_id).", ".((int) $fk_product).")"; } @@ -538,7 +538,7 @@ class MouvementStock extends CommonObject $this->errors[] = $this->db->lasterror(); $error = -3; } elseif (empty($fk_product_stock)) { - $fk_product_stock = $this->db->last_insert_id(MAIN_DB_PREFIX."product_stock"); + $fk_product_stock = $this->db->last_insert_id($this->db->prefix()."product_stock"); } } @@ -559,11 +559,11 @@ class MouvementStock extends CommonObject if (!$error) { $newpmp = price2num($newpmp, 'MU'); - // $sql = "UPDATE ".MAIN_DB_PREFIX."product SET pmp = ".$newpmp.", stock = ".$this->db->ifsql("stock IS NULL", 0, "stock") . " + ".$qty; + // $sql = "UPDATE ".$this->db->prefix()."product SET pmp = ".$newpmp.", stock = ".$this->db->ifsql("stock IS NULL", 0, "stock") . " + ".$qty; // $sql.= " WHERE rowid = ".((int) $fk_product); // Update pmp + denormalized fields because we change content of produt_stock. Warning: Do not use "SET p.stock", does not works with pgsql - $sql = "UPDATE ".MAIN_DB_PREFIX."product as p SET pmp = ".((float) $newpmp).","; - $sql .= " stock=(SELECT SUM(ps.reel) FROM ".MAIN_DB_PREFIX."product_stock as ps WHERE ps.fk_product = p.rowid)"; + $sql = "UPDATE ".$this->db->prefix()."product as p SET pmp = ".((float) $newpmp).","; + $sql .= " stock=(SELECT SUM(ps.reel) FROM ".$this->db->prefix()."product_stock as ps WHERE ps.fk_product = p.rowid)"; $sql .= " WHERE rowid = ".((int) $fk_product); dol_syslog(get_class($this)."::_create update AWP", LOG_DEBUG); @@ -576,7 +576,7 @@ class MouvementStock extends CommonObject // If stock is now 0, we can remove entry into llx_product_stock, but only if there is no child lines into llx_product_batch (detail of batch, because we can imagine // having a lot1/qty=X and lot2/qty=-X, so 0 but we must not loose repartition of different lot. - $sql = "DELETE FROM ".MAIN_DB_PREFIX."product_stock WHERE reel = 0 AND rowid NOT IN (SELECT fk_product_stock FROM ".MAIN_DB_PREFIX."product_batch as pb)"; + $sql = "DELETE FROM ".$this->db->prefix()."product_stock WHERE reel = 0 AND rowid NOT IN (SELECT fk_product_stock FROM ".$this->db->prefix()."product_batch as pb)"; $resql = $this->db->query($sql); // We do not test error, it can fails if there is child in batch details } @@ -626,8 +626,8 @@ class MouvementStock extends CommonObject { dol_syslog(__METHOD__, LOG_DEBUG); - $sql = 'SELECT'; - $sql .= ' t.rowid,'; + $sql = "SELECT"; + $sql .= " t.rowid,"; $sql .= " t.tms,"; $sql .= " t.datem,"; $sql .= " t.fk_product,"; @@ -644,8 +644,8 @@ class MouvementStock extends CommonObject $sql .= " t.eatby,"; $sql .= " t.sellby,"; $sql .= " t.fk_projet as fk_project"; - $sql .= ' FROM '.MAIN_DB_PREFIX.$this->table_element.' as t'; - $sql .= ' WHERE t.rowid = '.((int) $id); + $sql .= " FROM ".$this->db->prefix().$this->table_element." as t"; + $sql .= " WHERE t.rowid = ".((int) $id); $resql = $this->db->query($sql); if ($resql) { @@ -721,7 +721,7 @@ class MouvementStock extends CommonObject $pqtys = array(); $sql = "SELECT fk_product_pere, fk_product_fils, qty"; - $sql .= " FROM ".MAIN_DB_PREFIX."product_association"; + $sql .= " FROM ".$this->db->prefix()."product_association"; $sql .= " WHERE fk_product_pere = ".((int) $idProduct); $sql .= " AND incdec = 1"; @@ -764,19 +764,19 @@ class MouvementStock extends CommonObject /** * Decrease stock for product and subproducts * - * @param User $user Object user - * @param int $fk_product Id product - * @param int $entrepot_id Warehouse id - * @param int $qty Quantity - * @param int $price Price - * @param string $label Label of stock movement - * @param string $datem Force date of movement - * @param integer $eatby eat-by date - * @param integer $sellby sell-by date - * @param string $batch batch number - * @param int $id_product_batch Id product_batch - * @param string $inventorycode Inventory code - * @return int <0 if KO, >0 if OK + * @param User $user Object user + * @param int $fk_product Id product + * @param int $entrepot_id Warehouse id + * @param int $qty Quantity + * @param int $price Price + * @param string $label Label of stock movement + * @param integer|string $datem Force date of movement + * @param integer $eatby eat-by date + * @param integer $sellby sell-by date + * @param string $batch batch number + * @param int $id_product_batch Id product_batch + * @param string $inventorycode Inventory code + * @return int <0 if KO, >0 if OK */ public function livraison($user, $fk_product, $entrepot_id, $qty, $price = 0, $label = '', $datem = '', $eatby = '', $sellby = '', $batch = '', $id_product_batch = 0, $inventorycode = '') { @@ -799,7 +799,7 @@ class MouvementStock extends CommonObject * @param integer|string $eatby eat-by date * @param integer|string $sellby sell-by date * @param string $batch batch number - * @param string $datem Force date of movement + * @param integer|string $datem Force date of movement * @param int $id_product_batch Id product_batch * @param string $inventorycode Inventory code * @return int <0 if KO, >0 if OK @@ -813,28 +813,6 @@ class MouvementStock extends CommonObject return $this->_create($user, $fk_product, $entrepot_id, $qty, 3, $price, $label, $inventorycode, $datem, $eatby, $sellby, $batch, $skip_batch, $id_product_batch); } - - // /** - // * Return nb of subproducts lines for a product - // * - // * @param int $id Id of product - // * @return int <0 if KO, nb of subproducts if OK - // * @deprecated A count($product->getChildsArbo($id,1)) is same. No reason to have this in this class. - // */ - // public function nbOfSubProducts($id) - // { - // $nbSP=0; - - // $resql = "SELECT count(*) as nb FROM ".MAIN_DB_PREFIX."product_association"; - // $resql.= " WHERE fk_product_pere = ".((int) $id); - // if ($this->db->query($resql)) - // { - // $obj=$this->db->fetch_object($resql); - // $nbSP=$obj->nb; - // } - // return $nbSP; - // } - /** * Count number of product in stock before a specific date * @@ -846,8 +824,8 @@ class MouvementStock extends CommonObject { $nb = 0; - $sql = 'SELECT SUM(value) as nb from '.MAIN_DB_PREFIX.'stock_mouvement'; - $sql .= ' WHERE fk_product = '.((int) $productidselected); + $sql = "SELECT SUM(value) as nb from ".$this->db->prefix()."stock_mouvement"; + $sql .= " WHERE fk_product = ".((int) $productidselected); $sql .= " AND datem < '".$this->db->idate($datebefore)."'"; dol_syslog(get_class($this).__METHOD__.'', LOG_DEBUG); @@ -873,7 +851,9 @@ class MouvementStock extends CommonObject */ private function createBatch($dluo, $qty) { - global $user; + global $user, $langs; + + $langs->load('productbatch'); $pdluo = new Productbatch($this->db); @@ -884,7 +864,7 @@ class MouvementStock extends CommonObject $result = $pdluo->fetch($dluo); if (empty($pdluo->id)) { // We didn't find the line. May be it was deleted before by a previous move in same transaction. - $this->error = 'Error. You ask a move on a record for a serial that does not exists anymore. May be you take the same serial on same warehouse several times in same shipment or it was used by another shipment. Remove this shipment and prepare another one.'; + $this->error = $langs->trans('CantMoveNonExistantSerial'); $this->errors[] = $this->error; $result = -2; } @@ -1093,7 +1073,7 @@ class MouvementStock extends CommonObject * Use this->id,this->lastname, this->firstname * * @param int $withpicto Include picto in link (0=No picto, 1=Include picto into link, 2=Only picto) - * @param string $option On what the link point to + * @param string $option On what the link point to ('' = Tab of stock movement of warehouse, 'movements' = list of movements) * @param integer $notooltip 1=Disable tooltip * @param int $maxlen Max length of visible user name * @param string $morecss Add more css on link @@ -1104,16 +1084,21 @@ class MouvementStock extends CommonObject global $langs, $conf, $db; $result = ''; - $companylink = ''; - $label = ''.$langs->trans("Movement").' '.$this->id.''; + $label = img_picto('', 'stock', 'class="pictofixedwidth"').''.$langs->trans("Movement").' '.$this->id.''; $label .= '
    '; $label .= ''.$langs->trans('Label').': '.$this->label; - $label .= '
    '.$langs->trans('Qty').': '.$this->qty; + $label .= '
    '.$langs->trans('Qty').': '.($this->qty > 0 ? '+' : '').$this->qty; $label .= '
    '; - $link = 'id; + } else { + $url = DOL_URL_ROOT.'/product/stock/movement_list.php?id='.$this->warehouse_id.'&msid='.$this->id; + } + + $link = 'db->prefix()."product_batch as pb"; + $sql .= " INNER JOIN ".$this->db->prefix()."product_stock as ps ON ps.rowid = pb.fk_product_stock"; $sql .= " WHERE ps.fk_product = " . ((int) $fk_product); $sql .= " AND pb.batch = '" . $this->db->escape($batch) . "'"; diff --git a/htdocs/product/stock/class/productlot.class.php b/htdocs/product/stock/class/productlot.class.php index 360978ac736..fdb82800067 100644 --- a/htdocs/product/stock/class/productlot.class.php +++ b/htdocs/product/stock/class/productlot.class.php @@ -188,7 +188,7 @@ class Productlot extends CommonObject // Put here code to add control on parameters values // Insert request - $sql = 'INSERT INTO '.MAIN_DB_PREFIX.$this->table_element.'('; + $sql = 'INSERT INTO '.$this->db->prefix().$this->table_element.'('; $sql .= 'entity,'; $sql .= 'fk_product,'; $sql .= 'batch,'; @@ -230,7 +230,7 @@ class Productlot extends CommonObject } if (!$error) { - $this->id = $this->db->last_insert_id(MAIN_DB_PREFIX.$this->table_element); + $this->id = $this->db->last_insert_id($this->db->prefix().$this->table_element); // Actions on extra fields if (!$error) { @@ -279,8 +279,8 @@ class Productlot extends CommonObject global $conf; dol_syslog(__METHOD__, LOG_DEBUG); - $sql = 'SELECT'; - $sql .= ' t.rowid,'; + $sql = "SELECT"; + $sql .= " t.rowid,"; $sql .= " t.entity,"; $sql .= " t.fk_product,"; $sql .= " t.batch,"; @@ -296,11 +296,11 @@ class Productlot extends CommonObject $sql .= " t.fk_user_creat,"; $sql .= " t.fk_user_modif,"; $sql .= " t.import_key"; - $sql .= ' FROM '.MAIN_DB_PREFIX.$this->table_element.' as t'; + $sql .= " FROM ".$this->db->prefix().$this->table_element." as t"; if ($product_id > 0 && $batch != '') { $sql .= " WHERE t.batch = '".$this->db->escape($batch)."' AND t.fk_product = ".((int) $product_id); } else { - $sql .= ' WHERE t.rowid = '.((int) $id); + $sql .= " WHERE t.rowid = ".((int) $id); } $resql = $this->db->query($sql); @@ -394,7 +394,7 @@ class Productlot extends CommonObject } // Update request - $sql = 'UPDATE '.MAIN_DB_PREFIX.$this->table_element.' SET'; + $sql = 'UPDATE '.$this->db->prefix().$this->table_element.' SET'; $sql .= ' entity = '.(isset($this->entity) ? $this->entity : "null").','; $sql .= ' fk_product = '.(isset($this->fk_product) ? $this->fk_product : "null").','; $sql .= ' batch = '.(isset($this->batch) ? "'".$this->db->escape($this->batch)."'" : "null").','; @@ -479,7 +479,7 @@ class Productlot extends CommonObject //} if (!$error) { - $sql = 'DELETE FROM '.MAIN_DB_PREFIX.$this->table_element; + $sql = 'DELETE FROM '.$this->db->prefix().$this->table_element; $sql .= ' WHERE rowid='.((int) $this->id); $resql = $this->db->query($sql); diff --git a/htdocs/product/stock/class/productstockentrepot.class.php b/htdocs/product/stock/class/productstockentrepot.class.php index 9b32fe1fe5e..95da65cd540 100644 --- a/htdocs/product/stock/class/productstockentrepot.class.php +++ b/htdocs/product/stock/class/productstockentrepot.class.php @@ -113,7 +113,7 @@ class ProductStockEntrepot extends CommonObject // Put here code to add control on parameters values // Insert request - $sql = 'INSERT INTO '.MAIN_DB_PREFIX.$this->table_element.'('; + $sql = 'INSERT INTO '.$this->db->prefix().$this->table_element.'('; $sql .= 'fk_product,'; $sql .= 'fk_entrepot,'; @@ -143,7 +143,7 @@ class ProductStockEntrepot extends CommonObject } if (!$error) { - $this->id = $this->db->last_insert_id(MAIN_DB_PREFIX.$this->table_element); + $this->id = $this->db->last_insert_id($this->db->prefix().$this->table_element); //if (!$notrigger) { // Uncomment this and change MYOBJECT to your own tag if you @@ -184,19 +184,19 @@ class ProductStockEntrepot extends CommonObject dol_syslog(__METHOD__, LOG_DEBUG); - $sql = 'SELECT'; - $sql .= ' t.rowid,'; + $sql = "SELECT"; + $sql .= " t.rowid,"; $sql .= " t.tms,"; $sql .= " t.fk_product,"; $sql .= " t.fk_entrepot,"; $sql .= " t.seuil_stock_alerte,"; $sql .= " t.desiredstock,"; $sql .= " t.import_key"; - $sql .= ' FROM '.MAIN_DB_PREFIX.$this->table_element.' as t'; + $sql .= " FROM ".$this->db->prefix().$this->table_element." as t"; if (!empty($id)) { - $sql .= ' WHERE t.rowid = '.((int) $id); + $sql .= " WHERE t.rowid = ".((int) $id); } else { - $sql .= ' WHERE t.fk_product = '.((int) $fk_product).' AND t.fk_entrepot = '.((int) $fk_entrepot); + $sql .= " WHERE t.fk_product = ".((int) $fk_product)." AND t.fk_entrepot = ".((int) $fk_entrepot); } $resql = $this->db->query($sql); @@ -254,8 +254,8 @@ class ProductStockEntrepot extends CommonObject { dol_syslog(__METHOD__, LOG_DEBUG); - $sql = 'SELECT'; - $sql .= ' t.rowid,'; + $sql = "SELECT"; + $sql .= " t.rowid,"; $sql .= " t.tms,"; $sql .= " t.fk_product,"; @@ -265,9 +265,9 @@ class ProductStockEntrepot extends CommonObject $sql .= " t.import_key"; - $sql .= ' FROM '.MAIN_DB_PREFIX.$this->table_element.' as t'; + $sql .= " FROM ".$this->db->prefix().$this->table_element." as t"; - $sql .= ' WHERE 1=1'; + $sql .= " WHERE 1=1"; // Manage filter $sqlwhere = array(); @@ -277,13 +277,13 @@ class ProductStockEntrepot extends CommonObject } } if (count($sqlwhere) > 0) { - $sql .= ' AND '.implode(' '.$this->db->escape($filtermode).' ', $sqlwhere); + $sql .= " AND ".implode(' '.$this->db->escape($filtermode).' ', $sqlwhere); } if (!empty($fk_product) && $fk_product > 0) { - $sql .= ' AND fk_product = '.((int) $fk_product); + $sql .= " AND fk_product = ".((int) $fk_product); } elseif (!empty($fk_entrepot) && $fk_entrepot > 0) { - $sql .= ' AND fk_entrepot = '.((int) $fk_entrepot); + $sql .= " AND fk_entrepot = ".((int) $fk_entrepot); } // "elseif" used instead of "if" because getting list with specified fk_product and specified fk_entrepot would be the same as doing a fetch @@ -355,7 +355,7 @@ class ProductStockEntrepot extends CommonObject // Put here code to add a control on parameters values // Update request - $sql = 'UPDATE '.MAIN_DB_PREFIX.$this->table_element.' SET'; + $sql = 'UPDATE '.$this->db->prefix().$this->table_element.' SET'; $sql .= ' tms = '.(dol_strlen($this->tms) != 0 ? "'".$this->db->idate($this->tms)."'" : "'".$this->db->idate(dol_now())."'").','; $sql .= ' fk_product = '.(isset($this->fk_product) ? $this->fk_product : "null").','; @@ -425,7 +425,7 @@ class ProductStockEntrepot extends CommonObject //} if (!$error) { - $sql = 'DELETE FROM '.MAIN_DB_PREFIX.$this->table_element; + $sql = 'DELETE FROM '.$this->db->prefix().$this->table_element; $sql .= ' WHERE rowid='.((int) $this->id); $resql = $this->db->query($sql); diff --git a/htdocs/product/stock/info.php b/htdocs/product/stock/info.php index 36897c7aef0..db6560a9970 100644 --- a/htdocs/product/stock/info.php +++ b/htdocs/product/stock/info.php @@ -81,9 +81,10 @@ if (!empty($conf->projet->enabled)) { if (!empty($object->fk_project)) { $proj = new Project($db); $proj->fetch($object->fk_project); - $morehtmlref .= ''; - $morehtmlref .= $proj->ref; - $morehtmlref .= ''; + $morehtmlref .= ' : '.$proj->getNomUrl(1); + if ($proj->title) { + $morehtmlref .= ' - '.$proj->title; + } } else { $morehtmlref .= ''; } diff --git a/htdocs/product/stock/list.php b/htdocs/product/stock/list.php index e223714e82d..93c963e0065 100644 --- a/htdocs/product/stock/list.php +++ b/htdocs/product/stock/list.php @@ -78,7 +78,7 @@ if (!$sortorder) { // Initialize technical object to manage hooks of page. Note that conf->hooks_modules contains array of hook context $object = new Entrepot($db); $extrafields = new ExtraFields($db); -$diroutputmassaction = $conf->inventory->dir_output.'/temp/massgeneration/'.$user->id; +$diroutputmassaction = $conf->stock->dir_output.'/temp/massgeneration/'.$user->id; $hookmanager->initHooks(array('stocklist')); // Fetch optionals attributes and labels @@ -117,11 +117,11 @@ $arrayfields = array( foreach ($object->fields as $key => $val) { // If $val['visible']==0, then we never show the field if (!empty($val['visible'])) { - $visible = (int) dol_eval($val['visible'], 1); + $visible = (int) dol_eval($val['visible'], 1, 1, '1'); $arrayfields['t.'.$key] = array( 'label'=>$val['label'], 'checked'=>(($visible < 0) ? 0 : 1), - 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1)), + 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1, 1, '1')), 'position'=>$val['position'], 'help'=> isset($val['help']) ? $val['help'] : 'help' ); @@ -195,6 +195,8 @@ $now = dol_now(); $help_url = 'EN:Module_Stocks_En|FR:Module_Stock|ES:Módulo_Stocks'; $title = $langs->trans("ListOfWarehouses"); +$totalarray = array(); +$totalarray['nbfield'] = 0; // Build and execute select // -------------------------------------------------------------------- @@ -227,7 +229,7 @@ $sql .= " FROM ".MAIN_DB_PREFIX.$object->table_element." as t"; if (!empty($conf->categorie->enabled)) { $sql .= Categorie::getFilterJoinQuery(Categorie::TYPE_WAREHOUSE, "t.rowid"); } -if (is_array($extrafields->attributes[$object->table_element]['label']) && count($extrafields->attributes[$object->table_element]['label'])) { +if (!empty($extrafields->attributes[$object->table_element]['label']) && is_array($extrafields->attributes[$object->table_element]['label']) && count($extrafields->attributes[$object->table_element]['label'])) { $sql .= " LEFT JOIN ".MAIN_DB_PREFIX.$object->table_element."_extrafields as ef on (t.rowid = ef.fk_object)"; } $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."product_stock as ps ON t.rowid = ps.fk_entrepot"; @@ -472,7 +474,7 @@ foreach ($object->fields as $key => $val) { } elseif ((strpos($val['type'], 'integer:') === 0) || (strpos($val['type'], 'sellist:') === 0)) { print $object->showInputField($val, $key, $search[$key], '', '', 'search_', 'maxwidth125', 1); } elseif (!preg_match('/^(date|timestamp)/', $val['type'])) { - print ''; + print ''; } print ''; } @@ -566,7 +568,6 @@ print ''."\n"; // Loop on record // -------------------------------------------------------------------- $i = 0; -$totalarray = array(); $warehouse = new Entrepot($db); diff --git a/htdocs/product/stock/massstockmove.php b/htdocs/product/stock/massstockmove.php index d7bd8bee9b4..781f2037dba 100644 --- a/htdocs/product/stock/massstockmove.php +++ b/htdocs/product/stock/massstockmove.php @@ -486,28 +486,36 @@ if (!empty($conf->global->MAIN_UPLOAD_DOC)) { $max = $conf->global->MAIN_UPLOAD_DOC; // In Kb $maxphp = @ini_get('upload_max_filesize'); // In unknown if (preg_match('/k$/i', $maxphp)) { + $maxphp = preg_replace('/k$/i', '', $maxphp); $maxphp = $maxphp * 1; } if (preg_match('/m$/i', $maxphp)) { + $maxphp = preg_replace('/m$/i', '', $maxphp); $maxphp = $maxphp * 1024; } if (preg_match('/g$/i', $maxphp)) { + $maxphp = preg_replace('/g$/i', '', $maxphp); $maxphp = $maxphp * 1024 * 1024; } if (preg_match('/t$/i', $maxphp)) { + $maxphp = preg_replace('/t$/i', '', $maxphp); $maxphp = $maxphp * 1024 * 1024 * 1024; } $maxphp2 = @ini_get('post_max_size'); // In unknown if (preg_match('/k$/i', $maxphp2)) { + $maxphp2 = preg_replace('/k$/i', '', $maxphp2); $maxphp2 = $maxphp2 * 1; } if (preg_match('/m$/i', $maxphp2)) { + $maxphp2 = preg_replace('/m$/i', '', $maxphp2); $maxphp2 = $maxphp2 * 1024; } if (preg_match('/g$/i', $maxphp2)) { + $maxphp2 = preg_replace('/g$/i', '', $maxphp2); $maxphp2 = $maxphp2 * 1024 * 1024; } if (preg_match('/t$/i', $maxphp2)) { + $maxphp2 = preg_replace('/t$/i', '', $maxphp2); $maxphp2 = $maxphp2 * 1024 * 1024 * 1024; } // Now $max and $maxphp and $maxphp2 are in Kb diff --git a/htdocs/product/stock/movement_card.php b/htdocs/product/stock/movement_card.php index b5373fc9de6..ebe8f0552ce 100644 --- a/htdocs/product/stock/movement_card.php +++ b/htdocs/product/stock/movement_card.php @@ -75,8 +75,8 @@ $search_type_mouvement = GETPOST('search_type_mouvement', 'int'); $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); if (empty($page) || $page == -1) { $page = 0; } // If $page is not defined, or '' or -1 @@ -489,7 +489,7 @@ if ($search_warehouse != '' && $search_warehouse != '-1') { $sql .= natural_search('e.rowid', $search_warehouse, 2); } if (!empty($search_user)) { - $sql .= natural_search('u.login', $search_user); + $sql .= natural_search(array('u.lastname', 'u.firstname', 'u.login'), $search_user); } if (!empty($search_batch)) { $sql .= natural_search('m.batch', $search_batch); @@ -1207,14 +1207,12 @@ if ($action != 'create' && $action != 'edit' && $action != 'delete' && $id > 0) $MAXEVENT = 10; - $morehtmlright = ''; - $morehtmlright .= $langs->trans("SeeAll"); - $morehtmlright .= ''; + $morehtmlcenter = dolGetButtonTitle($langs->trans('SeeAll'), '', 'fa fa-list-alt imgforviewmode', DOL_URL_ROOT.'/product/agenda.php?id='.$object->id); // List of actions on element include_once DOL_DOCUMENT_ROOT.'/core/class/html.formactions.class.php'; $formactions = new FormActions($db); - $somethingshown = $formactions->showactions($object, 'mouvement', 0, 1, '', $MAXEVENT, '', $morehtmlright); // Show all action for product + $somethingshown = $formactions->showactions($object, 'mouvement', 0, 1, '', $MAXEVENT, '', $morehtmlcenter); // Show all action for product print ''; } diff --git a/htdocs/product/stock/movement_list.php b/htdocs/product/stock/movement_list.php index e028c49396b..73c6751262a 100644 --- a/htdocs/product/stock/movement_list.php +++ b/htdocs/product/stock/movement_list.php @@ -3,7 +3,7 @@ * Copyright (C) 2004-2017 Laurent Destailleur * Copyright (C) 2005-2014 Regis Houssin * Copyright (C) 2015 Juanjo Menent - * Copyright (C) 2018 Ferran Marcet + * Copyright (C) 2018-2022 Ferran Marcet * Copyright (C) 2019 Frédéric France * * This program is free software; you can redistribute it and/or modify @@ -49,9 +49,6 @@ if (!empty($conf->productbatch->enabled)) { $langs->load("productbatch"); } -// Security check -$result = restrictedArea($user, 'stock'); - $id = GETPOST('id', 'int'); $ref = GETPOST('ref', 'alpha'); $msid = GETPOST('msid', 'int'); @@ -63,11 +60,8 @@ $cancel = GETPOST('cancel', 'alpha'); $contextpage = GETPOST('contextpage', 'aZ') ?GETPOST('contextpage', 'aZ') : 'movementlist'; $toselect = GETPOST('toselect', 'array'); // Array of ids of elements selected into a list -// Security check -//$result=restrictedArea($user, 'stock', $id, 'entrepot&stock'); -$result = restrictedArea($user, 'stock'); - $idproduct = GETPOST('idproduct', 'int'); +$sall = trim((GETPOST('search_all', 'alphanohtml') != '') ?GETPOST('search_all', 'alphanohtml') : GETPOST('sall', 'alphanohtml')); $search_date_startday = GETPOST('search_date_startday', 'int'); $search_date_startmonth = GETPOST('search_date_startmonth', 'int'); $search_date_startyear = GETPOST('search_date_startyear', 'int'); @@ -87,15 +81,22 @@ $search_batch = trim(GETPOST("search_batch")); $search_qty = trim(GETPOST("search_qty")); $search_type_mouvement = GETPOST('search_type_mouvement', 'int'); $search_fk_projet=GETPOST("search_fk_projet", 'int'); +$optioncss = GETPOST('optioncss', 'alpha'); +$type = GETPOST("type", "int"); +// Load variable for pagination $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); -if (empty($page) || $page == -1) { +if (empty($page) || $page < 0 || GETPOST('button_search', 'alpha') || GETPOST('button_removefilter', 'alpha')) { + // If $page is not defined, or '' or -1 or if we click on clear filters $page = 0; -} // If $page is not defined, or '' or -1 +} $offset = $limit * $page; +$pageprev = $page - 1; +$pagenext = $page + 1; + if (!$sortfield) { $sortfield = "m.datem"; } @@ -107,8 +108,10 @@ $pdluoid = GETPOST('pdluoid', 'int'); // Initialize technical object to manage hooks of page. Note that conf->hooks_modules contains array of hook context $object = new MouvementStock($db); -$hookmanager->initHooks(array('movementlist')); $extrafields = new ExtraFields($db); +$diroutputmassaction = $conf->stock->dir_output.'/temp/massgeneration/'.$user->id; +$hookmanager->initHooks(array('movementlist')); + $formfile = new FormFile($db); // fetch optionals attributes and labels @@ -136,6 +139,9 @@ $arrayfields = array( //'m.datec'=>array('label'=>"DateCreation", 'checked'=>0, 'position'=>500), //'m.tms'=>array('label'=>"DateModificationShort", 'checked'=>0, 'position'=>500) ); + +include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_array_fields.tpl.php'; + if (!empty($conf->global->PRODUCT_DISABLE_SELLBY)) { unset($arrayfields['pl.sellby']); } @@ -143,11 +149,25 @@ if (!empty($conf->global->PRODUCT_DISABLE_EATBY)) { unset($arrayfields['pl.eatby']); } + +$tmpwarehouse = new Entrepot($db); +if ($id > 0 || !empty($ref)) { + $tmpwarehouse->fetch($id, $ref); + $id = $tmpwarehouse->id; +} + + +// Security check +//$result=restrictedArea($user, 'stock', $id, 'entrepot&stock'); +$result = restrictedArea($user, 'stock'); + // Security check if (!$user->rights->stock->mouvement->lire) { accessforbidden(); } +$uploaddir = $conf->stock->dir_output.'/movements'; + $permissiontoread = $user->rights->stock->mouvement->lire; $permissiontoadd = $user->rights->stock->mouvement->creer; $permissiontodelete = $user->rights->stock->mouvement->creer; // There is no deletion permission for stock movement as we shoul dnever delete @@ -164,7 +184,8 @@ $error = 0; */ if (GETPOST('cancel', 'alpha')) { - $action = 'list'; $massaction = ''; + $action = 'list'; + $massaction = ''; } if (!GETPOST('confirmmassaction', 'alpha') && $massaction != 'presend' && $massaction != 'confirm_presend') { $massaction = ''; @@ -177,9 +198,10 @@ if ($reshook < 0) { } if (empty($reshook)) { + // Selection of new fields include DOL_DOCUMENT_ROOT.'/core/actions_changeselectedfields.inc.php'; - // Do we click on purge search criteria ? + // Purge search criteria if (GETPOST('button_removefilter_x', 'alpha') || GETPOST('button_removefilter.x', 'alpha') || GETPOST('button_removefilter', 'alpha')) { // Both test are required to be compatible with all browsers $search_date_startday = ''; $search_date_startmonth = ''; @@ -204,18 +226,96 @@ if (empty($reshook)) { $toselect = ''; $search_array_options = array(); } + if (GETPOST('button_removefilter_x', 'alpha') || GETPOST('button_removefilter.x', 'alpha') || GETPOST('button_removefilter', 'alpha') + || GETPOST('button_search_x', 'alpha') || GETPOST('button_search.x', 'alpha') || GETPOST('button_search', 'alpha')) { + $massaction = ''; // Protection to avoid mass action if we force a new search during a mass action confirmation + } // Mass actions $objectclass = 'MouvementStock'; $objectlabel = 'MouvementStock'; - $uploaddir = $conf->stock->dir_output; + + if (!$error && $massaction == "builddoc" && $permissiontoread && !GETPOST('button_search')) { + if (empty($diroutputmassaction)) { + dol_print_error(null, 'include of actions_massactions.inc.php is done but var $diroutputmassaction was not defined'); + exit; + } + + require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; + require_once DOL_DOCUMENT_ROOT.'/core/lib/pdf.lib.php'; + require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php'; + + $objecttmp = new $objectclass($db); + $listofobjectid = array(); + foreach ($toselect as $toselectid) { + $objecttmp = new $objectclass($db); // must create new instance because instance is saved into $listofobjectref array for future use + $result = $objecttmp->fetch($toselectid); + if ($result > 0) { + $listofobjectid[$toselectid] = $toselectid; + } + } + + $arrayofinclusion = array(); + foreach ($listofobjectref as $tmppdf) { + $arrayofinclusion[] = '^'.preg_quote(dol_sanitizeFileName($tmppdf), '/').'\.pdf$'; + } + foreach ($listofobjectref as $tmppdf) { + $arrayofinclusion[] = '^'.preg_quote(dol_sanitizeFileName($tmppdf), '/').'_[a-zA-Z0-9-_]+\.pdf$'; // To include PDF generated from ODX files + } + $listoffiles = dol_dir_list($uploaddir, 'all', 1, implode('|', $arrayofinclusion), '\.meta$|\.png', 'date', SORT_DESC, 0, true); + + // Define output language (Here it is not used because we do only merging existing PDF) + $outputlangs = $langs; + $newlang = ''; + if ($conf->global->MAIN_MULTILANGS && empty($newlang) && GETPOST('lang_id', 'aZ09')) { + $newlang = GETPOST('lang_id', 'aZ09'); + } + //elseif ($conf->global->MAIN_MULTILANGS && empty($newlang) && is_object($objecttmp->thirdparty)) { // On massaction, we can have several values for $objecttmp->thirdparty + // $newlang = $objecttmp->thirdparty->default_lang; + //} + if (!empty($newlang)) { + $outputlangs = new Translate("", $conf); + $outputlangs->setDefaultLang($newlang); + } + + // Create output dir if not exists + dol_mkdir($diroutputmassaction); + + // Defined name of merged file + $filename = strtolower(dol_sanitizeFileName($langs->transnoentities($objectlabel))); + $filename = preg_replace('/\s/', '_', $filename); + + // Save merged file + /* + if ($year) { + $filename .= '_'.$year; + } + if ($month) { + $filename .= '_'.$month; + } + */ + $now = dol_now(); + $file = $diroutputmassaction.'/'.$filename.'_'.dol_print_date($now, 'dayhourlog').'.pdf'; + + + // Create PDF + // TODO Create the pdf including list of movement ids found into $listofobjectid + // ... + + + if (!$error) { + $langs->load("exports"); + setEventMessages($langs->trans('FileSuccessfullyBuilt', $filename.'_'.dol_print_date($now, 'dayhourlog')), null, 'mesgs'); + } + + $massaction = ''; + $action = ''; + } + include DOL_DOCUMENT_ROOT.'/core/actions_massactions.inc.php'; } if ($action == 'update_extras') { - $tmpwarehouse = new Entrepot($db); - $tmpwarehouse->fetch($id); - $tmpwarehouse->oldcopy = dol_clone($tmpwarehouse); // Fill array 'array_options' with data from update form @@ -284,7 +384,9 @@ if ($action == "correct_stock") { $batch, GETPOST('inventorycode', 'alphanohtml'), $origin_element, - $origin_id + $origin_id, + 0, + $extrafields ); // We do not change value of stock for a correction } else { $result = $product->correct_stock( @@ -296,7 +398,9 @@ if ($action == "correct_stock") { price2num(GETPOST('unitprice'), 'MT'), GETPOST('inventorycode', 'alphanohtml'), $origin_element, - $origin_id + $origin_id, + 0, + $extrafields ); // We do not change value of stock for a correction } @@ -403,7 +507,11 @@ if ($action == "transfert_stock" && !$cancel) { $eatby, $sellby, $batch, - GETPOST('inventorycode') + GETPOST('inventorycode'), + '', + null, + 0, + $extrafields ); // Add stock $result2 = $product->correct_stock_batch( @@ -416,7 +524,11 @@ if ($action == "transfert_stock" && !$cancel) { $eatby, $sellby, $batch, - GETPOST('inventorycode', 'alphanohtml') + GETPOST('inventorycode', 'alphanohtml'), + '', + null, + 0, + $extrafields ); } } else { @@ -428,7 +540,11 @@ if ($action == "transfert_stock" && !$cancel) { 1, GETPOST("label", 'san_alpha'), $pricesrc, - GETPOST('inventorycode', 'alphanohtml') + GETPOST('inventorycode', 'alphanohtml'), + '', + null, + 0, + $extrafields ); // Add stock @@ -439,7 +555,11 @@ if ($action == "transfert_stock" && !$cancel) { 0, GETPOST("label", 'san_alpha'), $pricedest, - GETPOST('inventorycode', 'alphanohtml') + GETPOST('inventorycode', 'alphanohtml'), + '', + null, + 0, + $extrafields ); } if (!$error && $result1 >= 0 && $result2 >= 0) { @@ -477,6 +597,8 @@ if (!empty($conf->projet->enabled)) { $formproject = new FormProjets($db); } +// Build and execute select +// -------------------------------------------------------------------- $sql = "SELECT p.rowid, p.ref as product_ref, p.label as produit, p.tosell, p.tobuy, p.tobatch, p.fk_product_type as type, p.entity,"; $sql .= " e.ref as warehouse_ref, e.rowid as entrepot_id, e.lieu, e.fk_parent, e.statut,"; $sql .= " m.rowid as mid, m.value as qty, m.datem, m.fk_user_author, m.label, m.inventorycode, m.fk_origin, m.origintype,"; @@ -494,11 +616,12 @@ if (!empty($extrafields->attributes[$object->table_element]['label'])) { // Add fields from hooks $parameters = array(); $reshook = $hookmanager->executeHooks('printFieldListSelect', $parameters); // Note that $action and $object may have been modified by hook -$sql .= $hookmanager->resPrint; +$sql .= preg_replace('/^,/', '', $hookmanager->resPrint); +$sql = preg_replace('/,\s*$/', '', $sql); $sql .= " FROM ".MAIN_DB_PREFIX."entrepot as e,"; $sql .= " ".MAIN_DB_PREFIX."product as p,"; $sql .= " ".MAIN_DB_PREFIX."stock_mouvement as m"; -if (is_array($extrafields->attributes[$object->table_element]['label']) && count($extrafields->attributes[$object->table_element]['label'])) { +if (!empty($extrafields->attributes[$object->table_element]['label']) && is_array($extrafields->attributes[$object->table_element]['label']) && count($extrafields->attributes[$object->table_element]['label'])) { $sql .= " LEFT JOIN ".MAIN_DB_PREFIX.$object->table_element."_extrafields as ef on (m.rowid = ef.fk_object)"; } $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."user as u ON m.fk_user_author = u.rowid"; @@ -543,7 +666,7 @@ if ($search_warehouse != '' && $search_warehouse != '-1') { $sql .= natural_search('e.rowid', $search_warehouse, 2); } if (!empty($search_user)) { - $sql .= natural_search('u.login', $search_user); + $sql .= natural_search(array('u.lastname', 'u.firstname', 'u.login'), $search_user); } if (!empty($search_batch)) { $sql .= natural_search('m.batch', $search_batch); @@ -567,6 +690,31 @@ $parameters = array(); $reshook = $hookmanager->executeHooks('printFieldListWhere', $parameters); // Note that $action and $object may have been modified by hook $sql .= $hookmanager->resPrint; +/* If a group by is required + $sql .= " GROUP BY "; + foreach($object->fields as $key => $val) { + $sql .= "t.".$key.", "; + } + // Add fields from extrafields + if (!empty($extrafields->attributes[$object->table_element]['label'])) { + foreach ($extrafields->attributes[$object->table_element]['label'] as $key => $val) { + $sql .= ($extrafields->attributes[$object->table_element]['type'][$key] != 'separate' ? "ef.".$key.', ' : ''); + } + } + // Add where from hooks + $parameters = array(); + $reshook = $hookmanager->executeHooks('printFieldListGroupBy', $parameters, $object); // Note that $action and $object may have been modified by hook + $sql .= $hookmanager->resPrint; + $sql = preg_replace('/,\s*$/', '', $sql); + */ + +// Add HAVING from hooks +/* + $parameters = array(); + $reshook = $hookmanager->executeHooks('printFieldListHaving', $parameters, $object); // Note that $action and $object may have been modified by hook + $sql .= empty($hookmanager->resPrint) ? "" : " HAVING 1=1 ".$hookmanager->resPrint; + */ + // Count total nb of records $nbtotalofrecords = ''; if (empty($conf->global->MAIN_DISABLE_FULL_SCANLIST)) { @@ -584,20 +732,19 @@ if (empty($conf->global->MAIN_DISABLE_FULL_SCANLIST)) { $resql = $db->query($sqlforcount); $objforcount = $db->fetch_object($resql); $nbtotalofrecords = $objforcount->nbtotalofrecords; - if (($page * $limit) > $nbtotalofrecords) { // if total resultset is smaller then paging size (filtering), goto and load page 0 + if (($page * $limit) > $nbtotalofrecords) { // if total of record found is smaller than page * limit, goto and load page 0 $page = 0; $offset = 0; } $db->free($resql); } +// Complete request and execute it with limit $sql .= $db->order($sortfield, $sortorder); if ($limit) { $sql .= $db->plimit($limit + 1, $offset); } -//print $sql; - $resql = $db->query($sql); if (!$resql) { dol_print_error($db); @@ -619,20 +766,24 @@ if ($id > 0 || $ref) { $num = $db->num_rows($resql); -$arrayofselected = is_array($toselect) ? $toselect : array(); +// Output page +// -------------------------------------------------------------------- $i = 0; $help_url = 'EN:Module_Stocks_En|FR:Module_Stock|ES:Módulo_Stocks'; if ($msid) { - $texte = $langs->trans('StockMovementForId', $msid); + $title = $langs->trans('StockMovementForId', $msid); } else { - $texte = $langs->trans("ListOfStockMovements"); + $title = $langs->trans("ListOfStockMovements"); if ($id) { - $texte .= ' ('.$langs->trans("ForThisWarehouse").')'; + $title .= ' ('.$langs->trans("ForThisWarehouse").')'; } } -llxHeader("", $texte, $help_url); + +llxHeader('', $title, $help_url); + +$arrayofselected = is_array($toselect) ? $toselect : array(); /* * Show tab only if we ask a particular warehouse @@ -671,9 +822,10 @@ if ($object->id > 0) { if (!empty($object->fk_project)) { $proj = new Project($db); $proj->fetch($object->fk_project); - $morehtmlref .= ''; - $morehtmlref .= $proj->ref; - $morehtmlref .= ''; + $morehtmlref .= ' : '.$proj->getNomUrl(1); + if ($proj->title) { + $morehtmlref .= ' - '.$proj->title; + } } else { $morehtmlref .= ''; } @@ -768,26 +920,20 @@ if ($object->id > 0) { } -/* - * Correct stock - */ +// Correct stock if ($action == "correction") { include DOL_DOCUMENT_ROOT.'/product/stock/tpl/stockcorrection.tpl.php'; print '
    '; } -/* - * Transfer of units - */ +// Transfer of units if ($action == "transfert") { include DOL_DOCUMENT_ROOT.'/product/stock/tpl/stocktransfer.tpl.php'; print '
    '; } -/* - * Action bar - */ +// Action bar if ((empty($action) || $action == 'list') && $id > 0) { print "
    \n"; @@ -861,12 +1007,11 @@ if ($idproduct > 0) { include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_search_param.tpl.php'; // List of mass actions available -$arrayofmassactions = array( - 'generate_doc'=>img_picto('', 'pdf', 'class="pictofixedwidth"').$langs->trans("ReGeneratePDF"), -// 'presend'=>img_picto('', 'email', 'class="pictofixedwidth"').$langs->trans("SendByMail"), -// 'builddoc'=>img_picto('', 'pdf', 'class="pictofixedwidth"').$langs->trans("PDFMerge"), -); -// By default, we should never accept deletion of stock movement. +$arrayofmassactions = array(); +if (getDolGlobalInt('MAIN_FEATURES_LEVEL') >= 2) { + $arrayofmassactions['builddoc'] = img_picto('', 'pdf', 'class="pictofixedwidth"').$langs->trans("GeneratePDF"); +} +// By default, we should never accept deletion of stock movement if (!empty($conf->global->STOCK_ALLOW_DELETE_OF_MOVEMENT) && $permissiontodelete) { $arrayofmassactions['predelete'] = img_picto('', 'delete', 'class="pictofixedwidth"').$langs->trans("Delete"); } @@ -875,7 +1020,7 @@ if (GETPOST('nomassaction', 'int') || in_array($massaction, array('presend', 'pr } $massactionbutton = $form->selectMassAction('', $arrayofmassactions); -print ''; +print ''."\n"; if ($optioncss != '') { print ''; } @@ -885,15 +1030,16 @@ print ''; print ''; print ''; print ''; +print ''; print ''; if ($id > 0) { print ''; } if ($id > 0) { - print_barre_liste($texte, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 'movement', 0, '', '', $limit, 0, 0, 1); + print_barre_liste($title, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 'movement', 0, '', '', $limit, 0, 0, 1); } else { - print_barre_liste($texte, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 'movement', 0, '', '', $limit, 0, 0, 1); + print_barre_liste($title, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 'movement', 0, '', '', $limit, 0, 0, 1); } // Add code for pre mass action (confirmation or email presend form) @@ -913,7 +1059,7 @@ if ($sall) { $moreforfilter = ''; $parameters = array('arrayfields'=>&$arrayfields); -$reshook = $hookmanager->executeHooks('printFieldPreListTitle', $parameters); // Note that $action and $object may have been modified by hook +$reshook = $hookmanager->executeHooks('printFieldPreListTitle', $parameters, $object); // Note that $action and $object may have been modified by hook if (empty($reshook)) { $moreforfilter .= $hookmanager->resPrint; } else { @@ -928,12 +1074,14 @@ if (!empty($moreforfilter)) { $varpage = empty($contextpage) ? $_SERVER["PHP_SELF"] : $contextpage; $selectedfields = $form->multiSelectArrayWithCheckbox('selectedfields', $arrayfields, $varpage); // This also change content of $arrayfields +$selectedfields .= (count($arrayofmassactions) ? $form->showCheckAddButtons('checkforselect', 1) : ''); -print '
    '; -print ''."\n"; +print '
    '; // You can use div-table-responsive-no-min if you dont need reserved height for your table +print '
    '."\n"; // Fields title search -print ''; +// -------------------------------------------------------------------- +print ''; if (!empty($arrayfields['m.rowid']['checked'])) { // Ref print ''; } -// Actions +// Action column print ''; -print "\n"; +print ''."\n"; + +// Fields title label +// -------------------------------------------------------------------- print ''; if (!empty($arrayfields['m.rowid']['checked'])) { print_liste_field_titre($arrayfields['m.rowid']['label'], $_SERVER["PHP_SELF"], 'm.rowid', '', $param, '', $sortfield, $sortorder); @@ -1121,7 +1272,7 @@ include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_search_title.tpl.php'; // Hook fields $parameters = array('arrayfields'=>$arrayfields, 'param'=>$param, 'sortfield'=>$sortfield, 'sortorder'=>$sortorder); -$reshook = $hookmanager->executeHooks('printFieldListTitle', $parameters); // Note that $action and $object may have been modified by hook +$reshook = $hookmanager->executeHooks('printFieldListTitle', $parameters, $object); // Note that $action and $object may have been modified by hook print $hookmanager->resPrint; if (!empty($arrayfields['m.datec']['checked'])) { print_liste_field_titre($arrayfields['p.datec']['label'], $_SERVER["PHP_SELF"], "p.datec", "", $param, '', $sortfield, $sortorder, 'center nowrap '); @@ -1129,51 +1280,77 @@ if (!empty($arrayfields['m.datec']['checked'])) { if (!empty($arrayfields['m.tms']['checked'])) { print_liste_field_titre($arrayfields['p.tms']['label'], $_SERVER["PHP_SELF"], "p.tms", "", $param, '', $sortfield, $sortorder, 'center nowrap '); } +// Action column print_liste_field_titre($selectedfields, $_SERVER["PHP_SELF"], "", '', '', '', $sortfield, $sortorder, 'center maxwidthsearch '); -print "\n"; +print ''."\n"; $arrayofuniqueproduct = array(); + +// Loop on record +// -------------------------------------------------------------------- $i = 0; $totalarray = array(); -while ($i < min($num, $limit)) { - $objp = $db->fetch_object($resql); +$totalarray['nbfield'] = 0; +while ($i < ($limit ? min($num, $limit) : $num)) { + $obj = $db->fetch_object($resql); + if (empty($obj)) { + break; // Should not happen + } - $userstatic->id = $objp->fk_user_author; - $userstatic->login = $objp->login; - $userstatic->lastname = $objp->lastname; - $userstatic->firstname = $objp->firstname; - $userstatic->photo = $objp->photo; - $userstatic->email = $objp->user_email; - $userstatic->statut = $objp->user_status; + $userstatic->id = $obj->fk_user_author; + $userstatic->login = $obj->login; + $userstatic->lastname = $obj->lastname; + $userstatic->firstname = $obj->firstname; + $userstatic->photo = $obj->photo; + $userstatic->email = $obj->user_email; + $userstatic->statut = $obj->user_status; - $productstatic->id = $objp->rowid; - $productstatic->ref = $objp->product_ref; - $productstatic->label = $objp->produit; - $productstatic->type = $objp->type; - $productstatic->entity = $objp->entity; - $productstatic->status = $objp->tosell; - $productstatic->status_buy = $objp->tobuy; - $productstatic->status_batch = $objp->tobatch; + // Multilangs + if (!empty($conf->global->MAIN_MULTILANGS)) { // If multilang is enabled + // TODO Use a cache + $sql = "SELECT label"; + $sql .= " FROM ".MAIN_DB_PREFIX."product_lang"; + $sql .= " WHERE fk_product = ".((int) $obj->rowid); + $sql .= " AND lang = '".$db->escape($langs->getDefaultLang())."'"; + $sql .= " LIMIT 1"; - $productlot->id = $objp->lotid; - $productlot->batch = $objp->batch; - $productlot->eatby = $objp->eatby; - $productlot->sellby = $objp->sellby; + $result = $db->query($sql); + if ($result) { + $objtp = $db->fetch_object($result); + if (!empty($objtp->label)) { + $obj->produit = $objtp->label; + } + } + } - $warehousestatic->id = $objp->entrepot_id; - $warehousestatic->ref = $objp->warehouse_ref; - $warehousestatic->label = $objp->warehouse_ref; - $warehousestatic->lieu = $objp->lieu; - $warehousestatic->fk_parent = $objp->fk_parent; - $warehousestatic->statut = $objp->statut; + $productstatic->id = $obj->rowid; + $productstatic->ref = $obj->product_ref; + $productstatic->label = $obj->produit; + $productstatic->type = $obj->type; + $productstatic->entity = $obj->entity; + $productstatic->status = $obj->tosell; + $productstatic->status_buy = $obj->tobuy; + $productstatic->status_batch = $obj->tobatch; - $movement->type = $objp->type_mouvement; + $productlot->id = $obj->lotid; + $productlot->batch = $obj->batch; + $productlot->eatby = $obj->eatby; + $productlot->sellby = $obj->sellby; - $arrayofuniqueproduct[$objp->rowid] = $objp->produit; - if (!empty($objp->fk_origin)) { - $origin = $movement->get_origin($objp->fk_origin, $objp->origintype); + $warehousestatic->id = $obj->entrepot_id; + $warehousestatic->ref = $obj->warehouse_ref; + $warehousestatic->label = $obj->warehouse_ref; + $warehousestatic->lieu = $obj->lieu; + $warehousestatic->fk_parent = $obj->fk_parent; + $warehousestatic->statut = $obj->statut; + + $movement->type = $obj->type_mouvement; + + $arrayofuniqueproduct[$obj->rowid] = $obj->produit; + if (!empty($obj->fk_origin)) { + $origin = $movement->get_origin($obj->fk_origin, $obj->origintype); } else { $origin = ''; } @@ -1183,12 +1360,12 @@ while ($i < min($num, $limit)) { if (!empty($arrayfields['m.rowid']['checked'])) { print ''; // This is primary not movement id } if (!empty($arrayfields['m.datem']['checked'])) { // Date - print ''; + print ''; } if (!empty($arrayfields['p.ref']['checked'])) { // Product ref @@ -1212,10 +1389,10 @@ while ($i < min($num, $limit)) { print ''; } if (!empty($arrayfields['pl.eatby']['checked'])) { - print ''; + print ''; } if (!empty($arrayfields['pl.sellby']['checked'])) { - print ''; + print ''; } // Warehouse if (!empty($arrayfields['e.ref']['checked'])) { @@ -1231,11 +1408,11 @@ while ($i < min($num, $limit)) { } if (!empty($arrayfields['m.inventorycode']['checked'])) { // Inventory code - print ''; + print ''; } if (!empty($arrayfields['m.label']['checked'])) { // Label of movement - print ''; + print ''; } if (!empty($arrayfields['origin']['checked'])) { // Origin of movement @@ -1244,8 +1421,8 @@ while ($i < min($num, $limit)) { if (!empty($arrayfields['m.fk_projet']['checked'])) { // fk_project print ''; } @@ -1258,14 +1435,14 @@ while ($i < min($num, $limit)) { if (!empty($arrayfields['m.value']['checked'])) { // Qty print ''; @@ -1273,34 +1450,36 @@ while ($i < min($num, $limit)) { if (!empty($arrayfields['m.price']['checked'])) { // Price print ''; } // Extra fields + $object = $movement; include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_print_fields.tpl.php'; // Fields from hook - $parameters = array('arrayfields'=>$arrayfields, 'objp'=>$objp, 'i'=>$i, 'totalarray'=>&$totalarray); - $reshook = $hookmanager->executeHooks('printFieldListValue', $parameters); // Note that $action and $object may have been modified by hook + $parameters = array('arrayfields'=>$arrayfields, 'object'=>$object, 'obj'=>$obj, 'i'=>$i, 'totalarray'=>&$totalarray); + $reshook = $hookmanager->executeHooks('printFieldListValue', $parameters, $object); // Note that $action and $object may have been modified by hook print $hookmanager->resPrint; // Action column print ''; if (!$i) { $totalarray['nbfield']++; } - print "\n"; + print ''."\n"; + $i++; } @@ -1340,6 +1519,26 @@ if (count($arrayofuniqueproduct) == 1 && is_numeric($year)) { //print ''; } +if (in_array('builddoc', $arrayofmassactions) && ($nbtotalofrecords === '' || $nbtotalofrecords)) { + $hidegeneratedfilelistifempty = 1; + if ($massaction == 'builddoc' || $action == 'remove_file' || $show_files) { + $hidegeneratedfilelistifempty = 0; + } + + require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php'; + $formfile = new FormFile($db); + + // Show list of available documents + $urlsource = $_SERVER['PHP_SELF'].'?sortfield='.$sortfield.'&sortorder='.$sortorder; + $urlsource .= str_replace('&', '&', $param); + + $filedir = $diroutputmassaction; + $genallowed = $permissiontoread; + $delallowed = $permissiontoadd; + + print $formfile->showdocuments('massfilesarea_mymodule', '', $filedir, $urlsource, 0, $delallowed, '', 1, 1, 0, 48, 1, $param, $title, '', '', '', null, $hidegeneratedfilelistifempty); +} + // End of page llxFooter(); $db->close(); diff --git a/htdocs/product/stock/product.php b/htdocs/product/stock/product.php index 23900c85c0b..3d16b6bac7c 100644 --- a/htdocs/product/stock/product.php +++ b/htdocs/product/stock/product.php @@ -496,8 +496,8 @@ if ($action == 'updateline' && GETPOST('save') == $langs->trans("Save")) { if ((!GETPOST("sellby")) && (!GETPOST("eatby")) && (!$batchnumber)) { setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("atleast1batchfield")), null, 'errors'); } else { - $d_eatby = dol_mktime(0, 0, 0, $_POST['eatbymonth'], $_POST['eatbyday'], $_POST['eatbyyear']); - $d_sellby = dol_mktime(0, 0, 0, $_POST['sellbymonth'], $_POST['sellbyday'], $_POST['sellbyyear']); + $d_eatby = dol_mktime(0, 0, 0, GETPOST('eatbymonth', 'int'), GETPOST('eatbyday', 'int'), GETPOST('eatbyyear', 'int')); + $d_sellby = dol_mktime(0, 0, 0, GETPOST('sellbymonth', 'int'), GETPOST('sellbyday', 'int'), GETPOST('sellbyyear', 'int')); $pdluo->batch = $batchnumber; $pdluo->eatby = $d_eatby; $pdluo->sellby = $d_sellby; @@ -552,7 +552,7 @@ if ($id > 0 || $ref) { if (!empty($conf->use_javascript_ajax)) { ?> - '.$addform; + } print load_fiche_titre($langs->trans($title), $addform, ''); @@ -1073,7 +1101,7 @@ foreach ($listofreferent as $key => $value) { print ''; // if $key == 'project_task', we don't want details per user } elseif (in_array($tablename, array('payment_various'))) { print ''; // if $key == 'payment_various', we don't have any thirdparty - } elseif (in_array($tablename, array('expensereport_det', 'don', 'projet_task', 'stock_mouvement', 'payment_salary'))) { + } elseif (in_array($tablename, array('expensereport_det', 'don', 'projet_task', 'stock_mouvement', 'salary'))) { print $langs->trans("User"); } else { print $langs->trans("ThirdParty"); @@ -1113,7 +1141,6 @@ foreach ($listofreferent as $key => $value) { } print ''; - $elementarray = $object->get_element_list($key, $tablename, $datefieldname, $dates, $datee, !empty($project_field) ? $project_field : 'fk_projet'); if (is_array($elementarray) && count($elementarray) > 0) { $total_ht = 0; $total_ttc = 0; @@ -1168,9 +1195,16 @@ foreach ($listofreferent as $key => $value) { if (!empty($element->close_code) && $element->close_code == 'replaced') { $qualifiedfortotal = false; // Replacement invoice, do not include into total } + } elseif ($key == 'order_supplier' && $element->status == 7) { + $qualifiedfortotal = false; // It makes no sense to include canceled orders in the total + } + + if ($key == "order_supplier" && $element->status == 7) { + print ''; + } else { + print ''; } - print ''; // Remove link print ''; if (in_array($tablename, array('projet_task'))) { print ''; } else { if (!is_array($elementarray)) { // error - print $elementarray; + print ''; + } else { + $colspan = 7; + if (in_array($tablename, array('projet_task'))) { + $colspan = 5; + } + if ($tablename == 'fichinter') { + $colspan++; + } + print ''; } } print "
    '; @@ -1046,7 +1194,7 @@ include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_search_input.tpl.php'; // Fields from hook $parameters = array('arrayfields'=>$arrayfields); -$reshook = $hookmanager->executeHooks('printFieldListOption', $parameters); // Note that $action and $object may have been modified by hook +$reshook = $hookmanager->executeHooks('printFieldListOption', $parameters, $object); // Note that $action and $object may have been modified by hook print $hookmanager->resPrint; // Date creation if (!empty($arrayfields['m.datec']['checked'])) { @@ -1058,13 +1206,16 @@ if (!empty($arrayfields['m.tms']['checked'])) { print ''; print ''; -$searchpicto = $form->showFilterAndCheckAddButtons(0); +$searchpicto = $form->showFilterButtons(); print $searchpicto; print '
    '; print img_picto($langs->trans("StockMovement"), 'movement', 'class="pictofixedwidth"'); - print $objp->mid; + print $obj->mid; print ''.dol_print_date($db->jdate($objp->datem), 'dayhour', 'tzuserrel').''.dol_print_date($db->jdate($obj->datem), 'dayhour', 'tzuserrel').''.dol_print_date($objp->eatby, 'day').''.dol_print_date($obj->eatby, 'day').''.dol_print_date($objp->sellby, 'day').''.dol_print_date($obj->sellby, 'day').'inventorycode.'$').'&search_type_mouvement='.urlencode($objp->type_mouvement).'">'.$objp->inventorycode.'inventorycode.'$').'&search_type_mouvement='.urlencode($obj->type_mouvement).'">'.$obj->inventorycode.''.$objp->label.''.$obj->label.''; - if ($objp->fk_project != 0) { - print $movement->get_origin($objp->fk_project, 'project'); + if ($obj->fk_project != 0) { + print $movement->get_origin($obj->fk_project, 'project'); } print ''; - if ($objp->qty > 0) { + if ($obj->qty > 0) { print ''; print '+'; - print $objp->qty; + print $obj->qty; print ''; } else { print ''; - print $objp->qty; + print $obj->qty; print ''; } print ''; - if ($objp->price != 0) { - print price($objp->price); + if ($obj->price != 0) { + print price($obj->price); } print ''; if ($massactionbutton || $massaction) { // If we are in select mode (massactionbutton defined) or if we have already selected and sent an action ($massaction) defined $selected = 0; - if (in_array($objp->mid, $arrayofselected)) { + if (in_array($obj->mid, $arrayofselected)) { $selected = 1; } - print ''; + print ''; } print '
    '; @@ -1231,8 +1265,8 @@ foreach ($listofreferent as $key => $value) { $date = $element->date; // No draft status on lines } elseif ($tablename == 'stock_mouvement') { $date = $element->datem; - } elseif ($tablename == 'payment_salary') { - $date = $element->datev; + } elseif ($tablename == 'salary') { + $date = $element->datesp; } elseif ($tablename == 'payment_various') { $date = $element->datev; } elseif ($tablename == 'chargesociales') { @@ -1290,7 +1324,7 @@ foreach ($listofreferent as $key => $value) { $tmpuser = new User($db); $tmpuser->fetch($expensereport->fk_user_author); print $tmpuser->getNomUrl(1, '', 48); - } elseif ($tablename == 'payment_salary') { + } elseif ($tablename == 'salary') { $tmpuser = new User($db); $tmpuser->fetch($element->fk_user); print $tmpuser->getNomUrl(1, '', 48); @@ -1318,7 +1352,7 @@ foreach ($listofreferent as $key => $value) { if (empty($value['disableamount'])) { $total_ht_by_line = null; $othermessage = ''; - if ($tablename == 'don' || $tablename == 'chargesociales' || $tablename == 'payment_various' || $tablename == 'payment_salary') { + if ($tablename == 'don' || $tablename == 'chargesociales' || $tablename == 'payment_various' || $tablename == 'salary') { $total_ht_by_line = $element->amount; } elseif ($tablename == 'fichinter') { $total_ht_by_line = $element->getAmount(); @@ -1356,7 +1390,7 @@ foreach ($listofreferent as $key => $value) { if (!$qualifiedfortotal) { print ''; } - print price($total_ht_by_line); + print ''.price($total_ht_by_line).''; if (!$qualifiedfortotal) { print ''; } @@ -1372,7 +1406,7 @@ foreach ($listofreferent as $key => $value) { // Amount inc tax if (empty($value['disableamount'])) { $total_ttc_by_line = null; - if ($tablename == 'don' || $tablename == 'chargesociales' || $tablename == 'payment_various' || $tablename == 'payment_salary') { + if ($tablename == 'don' || $tablename == 'chargesociales' || $tablename == 'payment_various' || $tablename == 'salary') { $total_ttc_by_line = $element->amount; } elseif ($tablename == 'fichinter') { $total_ttc_by_line = $element->getAmount(); @@ -1407,7 +1441,7 @@ foreach ($listofreferent as $key => $value) { if (!$qualifiedfortotal) { print ''; } - print price($total_ttc_by_line); + print ''.price($total_ttc_by_line).''; if (!$qualifiedfortotal) { print ''; } @@ -1480,6 +1514,7 @@ foreach ($listofreferent as $key => $value) { if (in_array($tablename, array('projet_task'))) { $colspan = 2; } + print '
    '.$langs->trans("Number").': '.$i.''; @@ -1518,7 +1553,16 @@ foreach ($listofreferent as $key => $value) { print '
    '.$elementarray.'
    '.$langs->trans("None").'
    "; diff --git a/htdocs/projet/index.php b/htdocs/projet/index.php index e1f86bcffc9..51e78f23d57 100644 --- a/htdocs/projet/index.php +++ b/htdocs/projet/index.php @@ -56,8 +56,8 @@ if (!$user->rights->projet->lire) { accessforbidden(); } -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $max = $conf->global->MAIN_SIZE_SHORTLIST_LIMIT; diff --git a/htdocs/projet/list.php b/htdocs/projet/list.php index 444dc6d525f..b254ac2b26f 100644 --- a/htdocs/projet/list.php +++ b/htdocs/projet/list.php @@ -98,6 +98,7 @@ $search_opp_amount = GETPOST("search_opp_amount", 'alpha'); $search_budget_amount = GETPOST("search_budget_amount", 'alpha'); $search_public = GETPOST("search_public", 'int'); $search_project_user = GETPOST('search_project_user', 'int'); +$search_project_contact = GETPOST('search_project_contact', 'int'); $search_sale = GETPOST('search_sale', 'int'); $search_usage_opportunity = GETPOST('search_usage_opportunity', 'int'); $search_usage_task = GETPOST('search_usage_task', 'int'); @@ -182,11 +183,11 @@ $arrayfields = array(); foreach ($object->fields as $key => $val) { // If $val['visible']==0, then we never show the field if (!empty($val['visible'])) { - $visible = dol_eval($val['visible'], 1); + $visible = dol_eval($val['visible'], 1, 1, '1'); $arrayfields['p.'.$key] = array( 'label'=>$val['label'], 'checked'=>(($visible < 0) ? 0 : 1), - 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1)), + 'enabled'=>($visible != 3 && dol_eval($val['enabled'], 1, 1, '1')), 'position'=>$val['position'], 'help'=> isset($val['help']) ? $val['help'] : '' ); @@ -198,6 +199,7 @@ include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_array_fields.tpl.php'; // Add non object fields to fields for list $arrayfields['s.nom'] = array('label'=>$langs->trans("ThirdParty"), 'checked'=>1, 'position'=>21, 'enabled'=>(empty($conf->societe->enabled) ? 0 : 1)); $arrayfields['commercial'] = array('label'=>$langs->trans("SaleRepresentativesOfThirdParty"), 'checked'=>0, 'position'=>23); +$arrayfields['c.assigned'] = array('label'=>$langs->trans("AssignedTo"), 'checked'=>-1, 'position'=>120); $arrayfields['opp_weighted_amount'] = array('label'=>$langs->trans('OpportunityWeightedAmountShort'), 'checked'=>0, 'position'=> 116, 'enabled'=>(empty($conf->global->PROJECT_USE_OPPORTUNITIES) ? 0 : 1), 'position'=>106); // Force some fields according to search_usage filter... if (GETPOST('search_usage_opportunity')) { @@ -252,6 +254,7 @@ if (empty($reshook)) { $search_public = ""; $search_sale = ""; $search_project_user = ''; + $search_project_contact = ''; $search_sday = ""; $search_smonth = ""; $search_syear = ""; @@ -363,13 +366,14 @@ if (empty($user->rights->projet->all->lire)) { // Get id of types of contacts for projects (This list never contains a lot of elements) $listofprojectcontacttype = array(); -$sql = "SELECT ctc.rowid, ctc.code FROM ".MAIN_DB_PREFIX."c_type_contact as ctc"; +$listofprojectcontacttypeexternal = array(); +$sql = "SELECT ctc.rowid, ctc.code, ctc.source FROM ".MAIN_DB_PREFIX."c_type_contact as ctc"; $sql .= " WHERE ctc.element = '".$db->escape($object->element)."'"; -$sql .= " AND ctc.source = 'internal'"; $resql = $db->query($sql); if ($resql) { while ($obj = $db->fetch_object($resql)) { - $listofprojectcontacttype[$obj->rowid] = $obj->code; + if ($obj->source == 'internal') $listofprojectcontacttype[$obj->rowid] = $obj->code; + else $listofprojectcontacttypeexternal[$obj->rowid] = $obj->code; } } else { dol_print_error($db); @@ -377,6 +381,9 @@ if ($resql) { if (count($listofprojectcontacttype) == 0) { $listofprojectcontacttype[0] = '0'; // To avoid sql syntax error if not found } +if (count($listofprojectcontacttypeexternal) == 0) { + $listofprojectcontacttypeexternal[0] = '0'; // To avoid sql syntax error if not found +} $distinct = 'DISTINCT'; // We add distinct until we are added a protection to be sure a contact of a project and task is only once. $sql = "SELECT ".$distinct." p.rowid as id, p.ref, p.title, p.fk_statut as status, p.fk_opp_status, p.public, p.fk_user_creat,"; @@ -417,6 +424,9 @@ if ($search_sale > 0) { if ($search_project_user > 0) { $sql .= ", ".MAIN_DB_PREFIX."element_contact as ecp"; } +if ($search_project_contact > 0) { + $sql .= ", ".MAIN_DB_PREFIX."element_contact as ecp_contact"; +} $sql .= " WHERE p.entity IN (".getEntity('project').')'; if (!empty($conf->categorie->enabled)) { $sql .= Categorie::getFilterSelectQuery(Categorie::TYPE_PROJECT, "p.rowid", $search_category_array); @@ -501,6 +511,9 @@ if ($search_sale > 0) { if ($search_project_user > 0) { $sql .= " AND ecp.fk_c_type_contact IN (".$db->sanitize(join(',', array_keys($listofprojectcontacttype))).") AND ecp.element_id = p.rowid AND ecp.fk_socpeople = ".((int) $search_project_user); } +if ($search_project_contact > 0) { + $sql .= " AND ecp_contact.fk_c_type_contact IN (".$db->sanitize(join(',', array_keys($listofprojectcontacttypeexternal))).") AND ecp_contact.element_id = p.rowid AND ecp_contact.fk_socpeople = ".((int) $search_project_contact); +} if ($search_opp_amount != '') { $sql .= natural_search('p.opp_amount', $search_opp_amount, 1); } @@ -686,9 +699,12 @@ if ($search_opp_percent != '') { if ($search_public != '') { $param .= '&search_public='.urlencode($search_public); } -if ($search_project_user != '') { +if ($search_project_user > 0) { $param .= '&search_project_user='.urlencode($search_project_user); } +if ($search_project_contact != '') { + $param .= '&search_project_user='.urlencode($search_project_contact); +} if ($search_sale > 0) { $param .= '&search_sale='.urlencode($search_sale); } @@ -751,6 +767,9 @@ $url = DOL_URL_ROOT.'/projet/card.php?action=create'; if (!empty($socid)) { $url .= '&socid='.$socid; } +if ($search_usage_event_organization == 1) { + $url .= '&usage_organize_event=1'; +} $newcardbutton = dolGetButtonTitle($langs->trans('NewProject'), '', 'fa fa-plus-circle', $url, '', $user->rights->projet->creer); print ''; @@ -802,7 +821,12 @@ $includeonly = ''; if (empty($user->rights->user->user->lire)) { $includeonly = array($user->id); } -$moreforfilter .= img_picto($tmptitle, 'user', 'class="pictofixedwidth"').$form->select_dolusers($search_project_user ? $search_project_user : '', 'search_project_user', $tmptitle, '', 0, $includeonly, '', 0, 0, 0, '', 0, '', 'maxwidth250'); +$moreforfilter .= img_picto($tmptitle, 'user', 'class="pictofixedwidth"').$form->select_dolusers($search_project_user ? $search_project_user : '', 'search_project_user', $tmptitle, '', 0, $includeonly, '', 0, 0, 0, '', 0, '', 'maxwidth250 widthcentpercentminusx'); +$moreforfilter .= '
    '; + +$moreforfilter .= '
    '; +$tmptitle = $langs->trans('ProjectsWithThisContact'); +$moreforfilter .= img_picto($tmptitle, 'user', 'class="pictofixedwidth"').$form->selectcontacts(0, $search_project_contact ? $search_project_contact : '', 'search_project_contact', $tmptitle, '', '', 0, 'maxwidth250 widthcentpercentminusx'); $moreforfilter .= '
    '; // If the user can view thirdparties other than his' @@ -810,7 +834,7 @@ if ($user->rights->societe->client->voir || $socid) { $langs->load("commercial"); $moreforfilter .= '
    '; $tmptitle = $langs->trans('ThirdPartiesOfSaleRepresentative'); - $moreforfilter .= img_picto($tmptitle, 'user', 'class="pictofixedwidth"').$formother->select_salesrepresentatives($search_sale, 'search_sale', $user, 0, $tmptitle, 'maxwidth250'); + $moreforfilter .= img_picto($tmptitle, 'user', 'class="pictofixedwidth"').$formother->select_salesrepresentatives($search_sale, 'search_sale', $user, 0, $tmptitle, 'maxwidth250 widthcentpercentminusx'); $moreforfilter .= '
    '; } @@ -908,7 +932,7 @@ if (!empty($arrayfields['p.public']['checked'])) { // Opp status if (!empty($arrayfields['p.fk_opp_status']['checked'])) { print ''; - print $formproject->selectOpportunityStatus('search_opp_status', $search_opp_status, 1, 0, 1, 0, 'maxwidth100'); + print $formproject->selectOpportunityStatus('search_opp_status', $search_opp_status, 1, 0, 1, 0, 'maxwidth100', 1); print ''; } if (!empty($arrayfields['p.opp_amount']['checked'])) { @@ -930,6 +954,10 @@ if (!empty($arrayfields['p.budget_amount']['checked'])) { print ''; print ''; } +if (!empty($arrayfields['c.assigned']['checked'])) { + print ''; + print ''; +} if (!empty($arrayfields['p.usage_opportunity']['checked'])) { print ''; print $form->selectyesno('search_usage_opportunity', $search_usage_opportunity, 1, false, 1); @@ -1000,7 +1028,7 @@ if (!empty($arrayfields['p.fk_statut']['checked'])) { $arrayofstatus[$key] = $langs->trans($val); } $arrayofstatus['99'] = $langs->trans("NotClosed").' ('.$langs->trans('Draft').' + '.$langs->trans('Opened').')'; - print $form->selectarray('search_status', $arrayofstatus, $search_status, 1, 0, 0, '', 0, 0, 0, '', 'minwidth75imp maxwidth150 selectarrowonleft'); + print $form->selectarray('search_status', $arrayofstatus, $search_status, 1, 0, 0, '', 0, 0, 0, '', 'minwidth75imp maxwidth125 selectarrowonleft'); print ajax_combobox('search_status'); print ''; } @@ -1049,6 +1077,9 @@ if (!empty($arrayfields['opp_weighted_amount']['checked'])) { if (!empty($arrayfields['p.budget_amount']['checked'])) { print_liste_field_titre($arrayfields['p.budget_amount']['label'], $_SERVER["PHP_SELF"], 'p.budget_amount', "", $param, '', $sortfield, $sortorder, 'right '); } +if (!empty($arrayfields['c.assigned']['checked'])) { + print_liste_field_titre($arrayfields['c.assigned']['label'], $_SERVER["PHP_SELF"], "", '', $param, '', $sortfield, $sortorder, 'center ', ''); +} if (!empty($arrayfields['p.usage_opportunity']['checked'])) { print_liste_field_titre($arrayfields['p.usage_opportunity']['label'], $_SERVER["PHP_SELF"], 'p.usage_opportunity', "", $param, '', $sortfield, $sortorder, 'right '); } @@ -1309,6 +1340,41 @@ while ($i < min($num, $limit)) { $totalarray['pos'][$totalarray['nbfield']] = 'p.budget_amount'; } } + // Contacts of project + if (!empty($arrayfields['c.assigned']['checked'])) { + print ''; + $ifisrt = 1; + foreach (array('internal', 'external') as $source) { + $tab = $object->liste_contact(-1, $source); + $numcontact = count($tab); + if (!empty($numcontact)) { + foreach ($tab as $contactproject) { + //var_dump($contacttask); + if ($source == 'internal') { + $c = new User($db); + } else { + $c = new Contact($db); + } + $c->fetch($contactproject['id']); + if (!empty($c->photo)) { + if (get_class($c) == 'User') { + print $c->getNomUrl(-2, '', 0, 0, 24, 1, '', ($ifisrt ? '' : 'notfirst')); + } else { + print $c->getNomUrl(-2, '', 0, '', -1, 0, ($ifisrt ? '' : 'notfirst')); + } + } else { + if (get_class($c) == 'User') { + print $c->getNomUrl(2, '', 0, 0, 24, 1, '', ($ifisrt ? '' : 'notfirst')); + } else { + print $c->getNomUrl(2, '', 0, '', -1, 0, ($ifisrt ? '' : 'notfirst')); + } + } + $ifisrt = 0; + } + } + } + print ''; + } // Usage opportunity if (!empty($arrayfields['p.usage_opportunity']['checked'])) { print ''; diff --git a/htdocs/projet/stats/index.php b/htdocs/projet/stats/index.php index c5acc20bfe6..f41651e15d8 100644 --- a/htdocs/projet/stats/index.php +++ b/htdocs/projet/stats/index.php @@ -298,11 +298,13 @@ if (!in_array($nowyear, $arrayyears)) { $arrayyears[$nowyear] = $nowyear; } arsort($arrayyears); -print $form->selectarray('year', $arrayyears, $year, 0); +print $form->selectarray('year', $arrayyears, $year, 0, 0, 0, '', 0, 0, 0, '', 'width75'); print ''; print ''; print ''; + print ''; + print '

    '; print '
    '; @@ -369,10 +371,12 @@ $stringtoshow .= ''; print $stringtoshow; +print '
    '; -print ''; print '
    '; +print dol_get_fiche_end(); + // End of page llxFooter(); $db->close(); diff --git a/htdocs/projet/tasks.php b/htdocs/projet/tasks.php index 80d39cf08d4..310857e24cc 100644 --- a/htdocs/projet/tasks.php +++ b/htdocs/projet/tasks.php @@ -171,6 +171,7 @@ if ($object->usage_bill_time) { } // Extra fields +$extrafieldsobjectkey = $taskstatic->table_element; include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_array_fields.tpl.php'; $arrayfields = dol_sort_array($arrayfields, 'position'); @@ -302,8 +303,6 @@ if ($action == 'createtask' && $user->rights->projet->creer) { $error = 0; // If we use user timezone, we must change also view/list to use user timezone everywhere - //$date_start = dol_mktime($_POST['dateohour'],$_POST['dateomin'],0,$_POST['dateomonth'],$_POST['dateoday'],$_POST['dateoyear'],'user'); - //$date_end = dol_mktime($_POST['dateehour'],$_POST['dateemin'],0,$_POST['dateemonth'],$_POST['dateeday'],$_POST['dateeyear'],'user'); $date_start = dol_mktime(GETPOST('dateohour', 'int'), GETPOST('dateomin', 'int'), 0, GETPOST('dateomonth', 'int'), GETPOST('dateoday', 'int'), GETPOST('dateoyear', 'int')); $date_end = dol_mktime(GETPOST('dateehour', 'int'), GETPOST('dateemin', 'int'), 0, GETPOST('dateemonth', 'int'), GETPOST('dateeday', 'int'), GETPOST('dateeyear', 'int')); @@ -317,7 +316,7 @@ if ($action == 'createtask' && $user->rights->projet->creer) { setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentities("Label")), null, 'errors'); $action = 'create'; $error++; - } elseif (empty($_POST['task_parent'])) { + } elseif (!GETPOST('task_parent')) { setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentities("ChildOfProjectTask")), null, 'errors'); $action = 'create'; $error++; @@ -625,7 +624,7 @@ if ($id > 0 || !empty($ref)) { // Budget print ''.$langs->trans("Budget").''; if (strcmp($object->budget_amount, '')) { - print price($object->budget_amount, '', $langs, 1, 0, 0, $conf->currency); + print ''.price($object->budget_amount, '', $langs, 1, 0, 0, $conf->currency).''; } print ''; @@ -810,9 +809,7 @@ if ($action == 'create' && $user->rights->projet->creer && (empty($object->third $linktocreatetask = dolGetButtonTitle($langs->trans('AddTask'), '', 'fa fa-plus-circle', DOL_URL_ROOT.'/projet/tasks.php?action=create'.$param.'&backtopage='.urlencode($_SERVER['PHP_SELF'].'?id='.$object->id), '', $linktocreatetaskUserRight, $linktocreatetaskParam); print '
    '; - if ($optioncss != '') { - print ''; - } + print ''; print ''; print ''; print ''; @@ -851,8 +848,8 @@ if ($action == 'create' && $user->rights->projet->creer && (empty($object->third $moreforfilter = ''; if (count($tasksarray) > 0) { $moreforfilter .= '
    '; - $moreforfilter .= $langs->trans("TasksAssignedTo").': '; - $moreforfilter .= $form->select_dolusers($tmpuser->id > 0 ? $tmpuser->id : '', 'search_user_id', 1); + $moreforfilter .= img_picto('', 'user', 'class="pictofixedwidth"'); + $moreforfilter .= $form->select_dolusers($tmpuser->id > 0 ? $tmpuser->id : '', 'search_user_id', $langs->trans("TasksAssignedTo"), null, 0, '', ''); $moreforfilter .= '
    '; } if ($moreforfilter) { @@ -969,7 +966,6 @@ if ($action == 'create' && $user->rights->projet->creer && (empty($object->third print ''; } - $extrafieldsobjectkey = $taskstatic->table_element; include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_search_input.tpl.php'; // Action column diff --git a/htdocs/projet/tasks/document.php b/htdocs/projet/tasks/document.php index c60e3324741..c57610d0130 100644 --- a/htdocs/projet/tasks/document.php +++ b/htdocs/projet/tasks/document.php @@ -46,8 +46,8 @@ $project_ref = GETPOST('project_ref', 'alpha'); // Get parameters $limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; @@ -74,7 +74,7 @@ $socid = 0; restrictedArea($user, 'projet', $object->fk_project, 'projet&project'); -$permissiontoadd = $$user->rights->mrp->write; // Used by the include of actions_addupdatedelete.inc.php and actions_linkedfiles.inc.php +$permissiontoadd = $user->rights->projet->creer; // Used by the include of actions_addupdatedelete.inc.php and actions_linkedfiles.inc.php /* diff --git a/htdocs/projet/tasks/list.php b/htdocs/projet/tasks/list.php index 53b1a85e889..697969c6060 100644 --- a/htdocs/projet/tasks/list.php +++ b/htdocs/projet/tasks/list.php @@ -67,11 +67,14 @@ $search_task_user = GETPOST('search_task_user', 'int'); $search_task_progress = GETPOST('search_task_progress'); $search_task_budget_amount = GETPOST('search_task_budget_amount'); $search_societe = GETPOST('search_societe'); +$search_opp_status = GETPOST("search_opp_status", 'alpha'); -$mine = $_REQUEST['mode'] == 'mine' ? 1 : 0; +$mine = GETPOST('mode', 'alpha') == 'mine' ? 1 : 0; if ($mine) { - $search_task_user = $user->id; $mine = 0; + $search_task_user = $user->id; + $mine = 0; } +$type = GETPOST('type'); $search_date_startday = GETPOST('search_date_startday', 'int'); $search_date_startmonth = GETPOST('search_date_startmonth', 'int'); @@ -112,8 +115,8 @@ if (!$user->rights->projet->lire) { $diroutputmassaction = $conf->projet->dir_output.'/tasks/temp/massgeneration/'.$user->id; $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; @@ -346,7 +349,7 @@ $sql .= ", ".MAIN_DB_PREFIX."projet_task as t"; if (!empty($arrayfields['t.tobill']['checked']) || !empty($arrayfields['t.billed']['checked'])) { $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."projet_task_time as tt ON tt.fk_task = t.rowid"; } -if (is_array($extrafields->attributes[$object->table_element]['label']) && count($extrafields->attributes[$object->table_element]['label'])) { +if (isset($extrafields->attributes[$object->table_element]['label']) && is_array($extrafields->attributes[$object->table_element]['label']) && count($extrafields->attributes[$object->table_element]['label'])) { $sql .= " LEFT JOIN ".MAIN_DB_PREFIX.$object->table_element."_extrafields as ef on (t.rowid = ef.fk_object)"; } if ($search_project_user > 0) { @@ -604,7 +607,9 @@ print ''; print ''; print ''; print ''; -print ''; +if (!empty($type)) { + print ''; +} print ''; // Show description of content @@ -634,7 +639,7 @@ if ($search_all) { print '
    '.$langs->trans("FilterOnInto", $search_all).join(', ', $fieldstosearchall).'
    '; } -$morehtmlfilter = ''; +$moreforfilter = ''; // Filter on categories if (!empty($conf->categorie->enabled) && $user->rights->categorie->lire) { @@ -861,10 +866,34 @@ if (!empty($arrayfields['t.tobill']['checked'])) { if (!empty($arrayfields['t.billed']['checked'])) { print_liste_field_titre($arrayfields['t.billed']['label'], $_SERVER["PHP_SELF"], "", "", $param, '', $sortfield, $sortorder, 'center '); } +$totalarray = array( + 'nbfield' => 0, + 'val' => array( + 't.planned_workload' => 0, + 't.duration_effective' => 0, + 't.progress' => 0, + 't.budget_amount' => 0, + ), + 'totalplannedworkload' => 0, + 'totaldurationeffective' => 0, + 'totaldurationdeclared' => 0, + 'totaltobillfield' => 0, + 'totalbilledfield' => 0, + 'totalbudget_amountfield' => 0, + 'totalbudgetamount' => 0, + 'totaltobill' => 0, + 'totalbilled' => 0, +); // Extra fields include DOL_DOCUMENT_ROOT.'/core/tpl/extrafields_list_search_title.tpl.php'; // Hook fields -$parameters = array('arrayfields'=>$arrayfields, 'param'=>$param, 'sortfield'=>$sortfield, 'sortorder'=>$sortorder); +$parameters = array( + 'arrayfields' => $arrayfields, + 'param' => $param, + 'sortfield' => $sortfield, + 'sortorder' => $sortorder, + 'totalarray' => &$totalarray, +); $reshook = $hookmanager->executeHooks('printFieldListTitle', $parameters); // Note that $action and $object may have been modified by hook print $hookmanager->resPrint; if (!empty($arrayfields['t.datec']['checked'])) { @@ -887,7 +916,6 @@ if (!empty($conf->global->PROJECT_TIMES_SPENT_FORMAT)) { } $i = 0; -$totalarray = array(); while ($i < min($num, $limit)) { $obj = $db->fetch_object($resql); @@ -1148,7 +1176,7 @@ while ($i < min($num, $limit)) { } $totalarray['val']['t.budget_amount'] += $obj->budget_amount; if (!$i) { - $totalarray['totalbudget_amount'] = $totalarray['nbfield']; + $totalarray['totalbudget_amountfield'] = $totalarray['nbfield']; } $totalarray['totalbudgetamount'] += $obj->budget_amount; print ''; @@ -1269,7 +1297,7 @@ if (isset($totalarray['totaldurationeffectivefield']) || isset($totalarray['tota print ''.convertSecondToTime($totalarray['totaltobill'], $plannedworkloadoutputformat).''; } elseif ($totalarray['totalbilledfield'] == $i) { print ''.convertSecondToTime($totalarray['totalbilled'], $plannedworkloadoutputformat).''; - } elseif ($totalarray['totalbudget_amount'] == $i) { + } elseif ($totalarray['totalbudget_amountfield'] == $i) { print ''.price($totalarray['totalbudgetamount'], 0, $langs, 1, 0, 0, $conf->currency).''; } else { print ''; diff --git a/htdocs/projet/tasks/note.php b/htdocs/projet/tasks/note.php index 3d1ec610b48..5f3d74a3c68 100644 --- a/htdocs/projet/tasks/note.php +++ b/htdocs/projet/tasks/note.php @@ -47,7 +47,6 @@ if (!$user->rights->projet->lire) { $hookmanager->initHooks(array('projettasknote')); -//$result = restrictedArea($user, 'projet', $id, '', 'task'); // TODO ameliorer la verification $object = new Task($db); $projectstatic = new Project($db); @@ -89,6 +88,7 @@ if ($id > 0 || $ref) { $object->fetch($id, $ref); } +//$result = restrictedArea($user, 'projet', $id, '', 'task'); // TODO ameliorer la verification restrictedArea($user, 'projet', $object->fk_project, 'projet&project'); $permissionnote = ($user->rights->projet->creer || $user->rights->projet->all->creer); diff --git a/htdocs/projet/tasks/stats/index.php b/htdocs/projet/tasks/stats/index.php index 60cbdf37072..70c093f46e3 100644 --- a/htdocs/projet/tasks/stats/index.php +++ b/htdocs/projet/tasks/stats/index.php @@ -168,11 +168,13 @@ if (!in_array($nowyear, $arrayyears)) { $arrayyears[$nowyear] = $nowyear; } arsort($arrayyears); -print $form->selectarray('year', $arrayyears, $year, 0); +print $form->selectarray('year', $arrayyears, $year, 0, 0, 0, '', 0, 0, 0, '', 'width75'); print ''; print ''; print ''; + print '
    '; + print '

    '; @@ -190,13 +192,13 @@ foreach ($data_all_year as $val) { $oldyear--; print ''; - print ' 0 ? '&userid='.$userid : '').'">'.$oldyear.''; + print ' 0 ? '&userid='.$userid : '').'">'.$oldyear.''; print '0'; print ''; } print ''; - print ' 0 ? '&userid='.$userid : '').'">'.$year.''; + print ' 0 ? '&userid='.$userid : '').'">'.$year.''; print ''.$val['nb'].''; print ''; $oldyear = $year; @@ -220,8 +222,11 @@ print $stringtoshow; print ''; + print '
    '; +print dol_get_fiche_end(); + // End of page llxFooter(); $db->close(); diff --git a/htdocs/projet/tasks/task.php b/htdocs/projet/tasks/task.php index 62714c72216..19be96cc558 100644 --- a/htdocs/projet/tasks/task.php +++ b/htdocs/projet/tasks/task.php @@ -91,7 +91,7 @@ if ($action == 'update' && !GETPOST("cancel") && $user->rights->projet->creer) { if (!$error) { $object->oldcopy = clone $object; - $tmparray = explode('_', $_POST['task_parent']); + $tmparray = explode('_', GETPOST('task_parent')); $task_parent = $tmparray[1]; if (empty($task_parent)) { $task_parent = 0; // If task_parent is '' @@ -108,7 +108,7 @@ if ($action == 'update' && !GETPOST("cancel") && $user->rights->projet->creer) { $object->budget_amount = price2num(GETPOST('budget_amount', 'alphanohtml')); // Fill array 'array_options' with data from add form - $ret = $extrafields->setOptionalsFromPost(null, $object); + $ret = $extrafields->setOptionalsFromPost(null, $object, '@GETPOSTISSET'); if ($ret < 0) { $error++; } @@ -117,6 +117,7 @@ if ($action == 'update' && !GETPOST("cancel") && $user->rights->projet->creer) { $result = $object->update($user); if ($result < 0) { setEventMessages($object->error, $object->errors, 'errors'); + $action = 'edit'; } } } else { diff --git a/htdocs/projet/tasks/time.php b/htdocs/projet/tasks/time.php index e8dc79951f7..ef8ac6aa9df 100644 --- a/htdocs/projet/tasks/time.php +++ b/htdocs/projet/tasks/time.php @@ -1,6 +1,6 @@ - * Copyright (C) 2006-2020 Laurent Destailleur + * Copyright (C) 2006-2021 Laurent Destailleur * Copyright (C) 2010-2012 Regis Houssin * Copyright (C) 2011 Juanjo Menent * Copyright (C) 2018 Ferran Marcet @@ -74,16 +74,9 @@ $search_task_label = GETPOST('search_task_label', 'alpha'); $search_user = GETPOST('search_user', 'int'); $search_valuebilled = GETPOST('search_valuebilled', 'int'); -// Security check -$socid = 0; -//if ($user->socid > 0) $socid = $user->socid; // For external user, no check is done on company because readability is managed by public status of project and assignement. -if (!$user->rights->projet->lire) { - accessforbidden(); -} - $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { $page = 0; @@ -98,6 +91,8 @@ if (!$sortorder) { $sortorder = 'DESC,DESC,DESC'; } +$childids = $user->getAllChildIds(1); + // Initialize technical object to manage hooks of page. Note that conf->hooks_modules contains array of hook context //$object = new TaskTime($db); $hookmanager->initHooks(array('projecttasktime', 'globalcard')); @@ -108,11 +103,28 @@ $extrafields = new ExtraFields($db); $extrafields->fetch_name_optionals_label($projectstatic->table_element); $extrafields->fetch_name_optionals_label($object->table_element); +// Load task if ($id > 0 || $ref) { $object->fetch($id, $ref); } -restrictedArea($user, 'projet', $object->fk_project, 'projet&project'); + +// Security check +$socid = 0; +//if ($user->socid > 0) $socid = $user->socid; // For external user, no check is done on company because readability is managed by public status of project and assignement. +if (!$user->rights->projet->lire) { + accessforbidden(); +} + +if ($object->fk_project > 0) { + restrictedArea($user, 'projet', $object->fk_project, 'projet&project'); +} else { + restrictedArea($user, 'projet', null, 'projet&project'); + // We check user has permission to see all tasks of all users + if (empty($projectid) && !$user->hasRight('projet', 'all', 'lire')) { + $search_user = $user->id; + } +} @@ -237,10 +249,14 @@ if (($action == 'updateline' || $action == 'updatesplitline') && !$cancel && $us $id = GETPOST('taskid', 'int'); $object->fetchTimeSpent(GETPOST('lineid', 'int')); - // TODO Check that ($task_time->fk_user == $user->id || in_array($task_time->fk_user, $childids)) - $result = $object->delTimeSpent($user); + + $result = 0; + if (in_array($object->timespent_fk_user, $childids) || $user->rights->projet->all->creer) { + $result = $object->delTimeSpent($user); + } $object->fetch($id, $ref); + $object->timespent_note = GETPOST("timespent_note_line", 'alpha'); $object->timespent_old_duration = GETPOST("old_duration"); $object->timespent_duration = GETPOSTINT("new_durationhour") * 60 * 60; // We store duration in seconds @@ -252,7 +268,12 @@ if (($action == 'updateline' || $action == 'updatesplitline') && !$cancel && $us $object->timespent_date = dol_mktime(12, 0, 0, GETPOST("timelinemonth"), GETPOST("timelineday"), GETPOST("timelineyear")); } $object->timespent_fk_user = GETPOST("userid_line", 'int'); - $result = $object->addTimeSpent($user); + + $result = 0; + if (in_array($object->timespent_fk_user, $childids) || $user->rights->projet->all->creer) { + $result = $object->addTimeSpent($user); + } + if ($result >= 0) { setEventMessages($langs->trans("RecordSaved"), null, 'mesgs'); } else { @@ -261,7 +282,6 @@ if (($action == 'updateline' || $action == 'updatesplitline') && !$cancel && $us } } else { $object->fetch($id, $ref); - // TODO Check that ($task_time->fk_user == $user->id || in_array($task_time->fk_user, $childids)) $object->timespent_id = GETPOST("lineid", 'int'); $object->timespent_note = GETPOST("timespent_note_line"); @@ -276,12 +296,16 @@ if (($action == 'updateline' || $action == 'updatesplitline') && !$cancel && $us } $object->timespent_fk_user = GETPOST("userid_line", 'int'); - $result = $object->updateTimeSpent($user); - if ($result >= 0) { - setEventMessages($langs->trans("RecordSaved"), null, 'mesgs'); - } else { - setEventMessages($langs->trans($object->error), null, 'errors'); - $error++; + $result = 0; + if (in_array($object->timespent_fk_user, $childids) || $user->rights->projet->all->creer) { + $result = $object->updateTimeSpent($user); + + if ($result >= 0) { + setEventMessages($langs->trans("RecordSaved"), null, 'mesgs'); + } else { + setEventMessages($langs->trans($object->error), null, 'errors'); + $error++; + } } } } else { @@ -289,18 +313,20 @@ if (($action == 'updateline' || $action == 'updatesplitline') && !$cancel && $us } } -if ($action == 'confirm_delete' && $confirm == "yes" && $user->rights->projet->lire) { - $object->fetchTimeSpent(GETPOST('lineid', 'int')); - // TODO Check that ($task_time->fk_user == $user->id || in_array($task_time->fk_user, $childids)) - $result = $object->delTimeSpent($user); +if ($action == 'confirm_deleteline' && $confirm == "yes" && $user->rights->projet->lire) { + $object->fetchTimeSpent(GETPOST('lineid', 'int')); // load properties like $object->timespent_id - if ($result < 0) { - $langs->load("errors"); - setEventMessages($langs->trans($object->error), null, 'errors'); - $error++; - $action = ''; - } else { - setEventMessages($langs->trans("RecordDeleted"), null, 'mesgs'); + if (in_array($object->timespent_fk_user, $childids) || $user->rights->projet->all->creer) { + $result = $object->delTimeSpent($user); // delete line with $object->timespent_id + + if ($result < 0) { + $langs->load("errors"); + setEventMessages($langs->trans($object->error), null, 'errors'); + $error++; + $action = ''; + } else { + setEventMessages($langs->trans("RecordDeleted"), null, 'mesgs'); + } } } @@ -335,6 +361,10 @@ if (GETPOST('projectid', 'int') > 0) { $object->fetch($id); $result = $projectstatic->fetch($object->fk_project); } +// If not task selected and no project selected +if ($id <= 0 && $projectidforalltimes == 0) { + $allprojectforuser = $user->id; +} if ($action == 'confirm_generateinvoice') { if (!empty($projectstatic->socid)) { @@ -629,9 +659,10 @@ if ($action == 'confirm_generateinter') { if (!$error) { $arrayoftasks = array(); foreach ($toselect as $key => $value) { - // Get userid, timepent + // Get userid, timespent $object->fetchTimeSpent($value); // $object->id is the task id + $arrayoftasks[$object->timespent_id]['id'] = $object->id; $arrayoftasks[$object->timespent_id]['timespent'] = $object->timespent_duration; $arrayoftasks[$object->timespent_id]['totalvaluetodivideby3600'] = $object->timespent_duration * $object->timespent_thm; $arrayoftasks[$object->timespent_id]['note'] = $object->timespent_note; @@ -640,7 +671,7 @@ if ($action == 'confirm_generateinter') { foreach ($arrayoftasks as $timespent_id => $value) { $ftask = new Task($db); - $ftask->fetch($object->id); + $ftask->fetch($value['id']); // Define qty per hour $qtyhour = $value['timespent'] / 3600; $qtyhourtext = convertSecondToTime($value['timespent'], 'all', $conf->global->MAIN_DURATION_OF_WORKDAY); @@ -678,7 +709,7 @@ $formother = new FormOther($db); $formproject = new FormProjets($db); $userstatic = new User($db); -if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { +if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0 || $allprojectforuser > 0) { /* * Fiche projet en mode visu */ @@ -720,6 +751,15 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { print dol_get_fiche_head($head, $tab, $langs->trans("Project"), -1, ($projectstatic->public ? 'projectpub' : 'project')); $param = ((!empty($mode) && $mode == 'mine') ? '&mode=mine' : ''); + if ($search_user) { + $param .= '&search_user='.((int) $search_user); + } + if ($search_month) { + $param .= '&search_month='.((int) $search_month); + } + if ($search_year) { + $param .= '&search_year='.((int) $search_year); + } // Project card @@ -740,7 +780,7 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { $projectstatic->next_prev_filter = " rowid IN (".$db->sanitize(count($objectsListId) ?join(',', array_keys($objectsListId)) : '0').")"; } - dol_banner_tab($projectstatic, 'project_ref', $linkback, 1, 'ref', 'ref', $morehtmlref); + dol_banner_tab($projectstatic, 'project_ref', $linkback, 1, 'ref', 'ref', $morehtmlref, $param); print '
    '; print '
    '; @@ -804,7 +844,7 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { // Budget print ''.$langs->trans("Budget").''; if (strcmp($projectstatic->budget_amount, '')) { - print price($projectstatic->budget_amount, '', $langs, 1, 0, 0, $conf->currency); + print ''.price($projectstatic->budget_amount, '', $langs, 1, 0, 0, $conf->currency).''; } print ''; @@ -818,7 +858,7 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { print '
    '; print '
    '; - print ''; + print '
    '; // Description print ''; print ''; + if (!empty($allprojectforuser)) { + print ''; + } if (empty($id)) { print ''; } @@ -1343,6 +1396,12 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { print $form->selectDate($newdate, 'time', ($conf->browser->layout == 'phone' ? 2 : 1), 1, 2, "timespent_date", 1, 0); print ''; + if (!empty($allprojectforuser)) { + print ''; + } + // Task $nboftasks = 0; if (empty($id)) { @@ -1375,12 +1434,12 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { // Note print ''; // Duration - Time spent print ''; } + if (!empty($allprojectforuser)) { + print ''; + } + // Task if ((empty($id) && empty($ref)) || !empty($projectidforalltimes)) { // Not a dedicated task if (!empty($arrayfields['t.task_ref']['checked'])) { print ''; @@ -1493,6 +1556,9 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { if (!empty($arrayfields['t.task_date']['checked'])) { print_liste_field_titre($arrayfields['t.task_date']['label'], $_SERVER['PHP_SELF'], 't.task_date,t.task_datehour,t.rowid', '', $param, '', $sortfield, $sortorder); } + if (!empty($allprojectforuser)) { + print_liste_field_titre("Project", $_SERVER['PHP_SELF'], '', '', $param, '', $sortfield, $sortorder); + } if ((empty($id) && empty($ref)) || !empty($projectidforalltimes)) { // Not a dedicated task if (!empty($arrayfields['t.task_ref']['checked'])) { print_liste_field_titre($arrayfields['t.task_ref']['label'], $_SERVER['PHP_SELF'], 'pt.ref', '', $param, '', $sortfield, $sortorder); @@ -1532,8 +1598,6 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { $i = 0; - $childids = $user->getAllChildIds(); - $total = 0; $totalvalue = 0; $totalarray = array(); @@ -1565,6 +1629,23 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { } } + // Project ref + if (!empty($allprojectforuser)) { + print ''; + if (!$i) { + $totalarray['nbfield']++; + } + } + // Task ref if (!empty($arrayfields['t.task_ref']['checked'])) { if ((empty($id) && empty($ref)) || !empty($projectidforalltimes)) { // Not a dedicated task @@ -1732,7 +1813,7 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { print '
    '; print ''; } elseif ($user->rights->projet->lire || $user->rights->projet->all->creer) { // Read project and enter time consumed on assigned tasks - if ($task_time->fk_user == $user->id || in_array($task_time->fk_user, $childids) || $user->rights->projet->all->creer) { + if (in_array($task_time->fk_user, $childids) || $user->rights->projet->all->creer) { if ($conf->MAIN_FEATURES_LEVEL >= 2) { print ' '; print 'rowid.$param.((empty($id) || $tab == 'timespent') ? '&tab=timespent' : '').'">'; @@ -1788,6 +1869,14 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { print ''; } + // Project ref + if (!empty($allprojectforuser)) { + if ((empty($id) && empty($ref)) || !empty($projectidforalltimes)) { // Not a dedicated task + print ''; + } + } + // Task ref if (!empty($arrayfields['t.task_ref']['checked'])) { if ((empty($id) && empty($ref)) || !empty($projectidforalltimes)) { // Not a dedicated task @@ -1916,6 +2005,14 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { print ''; } + // Project ref + if (!empty($allprojectforuser)) { + if ((empty($id) && empty($ref)) || !empty($projectidforalltimes)) { // Not a dedicated task + print ''; + } + } + // Task ref if (!empty($arrayfields['t.task_ref']['checked'])) { if ((empty($id) && empty($ref)) || !empty($projectidforalltimes)) { // Not a dedicated task diff --git a/htdocs/public/demo/demo.css b/htdocs/public/demo/demo.css index b185f8c933f..8edd0faecce 100644 --- a/htdocs/public/demo/demo.css +++ b/htdocs/public/demo/demo.css @@ -3,14 +3,28 @@ /* Demo */ /* ============================================================================== */ +div.titre { + text-transform: none; +} + a:hover { text-decoration: none; } + +.CTable { + /* padding: 6px; */ + font-weight: normal; + color: #444444 !important; + + margin: 8px 2px 8px 2px; + max-width: 346px; +} .demobox { border: 1px solid #bbb; border-radius: 8px; -moz-border-radius: 8px; min-height: 210px; + background: -webkit-linear-gradient(bottom, rgb(255,255,255) 85%, rgb(255,255,255) 100%); } .demobox:hover { border: 1px solid #bbb; @@ -18,33 +32,29 @@ a:hover { -moz-border-radius: 8px; box-shadow: 2px 2px 8px #BBB; } -.CTable { - padding: 6px; - font-weight: normal; - color: #444444 !important; - - margin: 8px 2px 8px 2px; - - /*border: 1px solid #bbb; - border-radius: 8px; - -moz-border-radius: 8px;*/ - background: -webkit-linear-gradient(bottom, rgb(255,255,255) 85%, rgb(255,255,255) 100%); - - max-width: 346px; -} -.csscolumns { - margin-top: 6px; - margin-bottom: 5px; - -webkit-column-count: 2; /* Chrome, Safari, Opera */ - -moz-column-count: 2; /* Firefox */ - column-count: 2; - text-align: left; -} .demomaxoveflow { max-width: 120px; overflow: hidden; text-overflow: ellipsis; } +@media only screen and (min-width: 641px) +{ + .csscolumns { + margin-top: 6px; + margin-bottom: 5px; + -webkit-column-count: 3; /* Chrome, Safari, Opera */ + -moz-column-count: 3; /* Firefox */ + column-count: 3; + text-align: left; + } + #divprofdemoall { + max-width: unset; + } + + .demomaxoveflow { + max-width: 200px; + } +} @media only screen and (max-width: 840px) { .csscolumns { @@ -76,6 +86,9 @@ a:hover { column-count: 1; text-align: left; } + .demomaxoveflow { + max-width: 220px !important; + } } diff --git a/htdocs/public/demo/index.php b/htdocs/public/demo/index.php index 0932b17baf5..49bde1a2b9b 100644 --- a/htdocs/public/demo/index.php +++ b/htdocs/public/demo/index.php @@ -212,7 +212,7 @@ if (GETPOST('action', 'aZ09') == 'gotodemo') { // Action run when we click o // If we disable modules using personalized list foreach ($modules as $val) { $modulekeyname = strtolower($val->name); - if (empty($_POST[$modulekeyname]) && empty($val->always_enabled) && !in_array($modulekeyname, $alwayscheckedmodules)) { + if (!GETPOST($modulekeyname) && empty($val->always_enabled) && !in_array($modulekeyname, $alwayscheckedmodules)) { $disablestring .= $modulekeyname.','; if ($modulekeyname == 'propale') { $disablestring .= 'propal,'; @@ -250,17 +250,18 @@ jQuery(document).ready(function () { jQuery(".modulelineshow").attr("href","#a1profdemoall"); jQuery(".cursorpointer").css("cursor","pointer"); jQuery(".modulelineshow").click(function() { - var idstring=$(this).attr("id"); - if (typeof idstring != "undefined") - { - var currentId = idstring.substring(2); - jQuery("tr.moduleline").hide(); - if (currentId != openedId) - { - openedId=currentId; - jQuery("#tr1"+currentId).show(); - jQuery("#tr2"+currentId).show(); - } + console.log("We select the custom demo"); + var idstring=$(this).attr("id"); + if (typeof idstring != "undefined") + { + var currentId = idstring.substring(2); + jQuery("tr.moduleline").hide(); + if (currentId != openedId) + { + openedId=currentId; + jQuery("#tr1"+currentId).show(); + jQuery("#tr2"+currentId).show(); + } else openedId = ""; } }); @@ -350,7 +351,7 @@ foreach ($demoprofiles as $profilearray) { // Modules (a profile you must choose modules) if (empty($profilearray['url'])) { - print ''; print ''; print '
    '; - print '
    '; + print '>'; + /* + $s = img_picto('', $modulekeyname, 'class="pictofixedwidth paddingleft"'); + if ($s) { + print $s; + } else { + print img_picto('', 'generic', 'class="pictofixedwidth paddingleft"'); + }*/ + print '
    '; print '
    '; //if ($modulo == ($nbcolsmod - 1)) print '
    '; $j++; @@ -405,6 +416,7 @@ foreach ($demoprofiles as $profilearray) { print '
    '; print ''; + print '

    '; print '
    '; print ''; @@ -419,6 +431,8 @@ foreach ($demoprofiles as $profilearray) { print ''; +print '
    '; + // TODO Replace this with a hook // Google Adsense (need Google module) diff --git a/htdocs/public/eventorganization/attendee_new.php b/htdocs/public/eventorganization/attendee_new.php index ede24103bdb..a7cdd1ceda8 100644 --- a/htdocs/public/eventorganization/attendee_new.php +++ b/htdocs/public/eventorganization/attendee_new.php @@ -19,16 +19,6 @@ * \file htdocs/public/eventorganization/attendee_new.php * \ingroup project * \brief Example of form to subscribe to an event - * - * Note that you can add following constant to change behaviour of page - * MEMBER_NEWFORM_AMOUNT Default amount for auto-subscribe form - * MEMBER_NEWFORM_EDITAMOUNT 0 or 1 = Amount can be edited - * MEMBER_NEWFORM_PAYONLINE Suggest payment with paypal, paybox or stripe - * MEMBER_NEWFORM_DOLIBARRTURNOVER Show field turnover (specific for dolibarr foundation) - * MEMBER_URL_REDIRECT_SUBSCRIPTION Url to redirect once subscribe submitted - * MEMBER_NEWFORM_FORCETYPE Force type of member - * MEMBER_NEWFORM_FORCEMORPHY Force nature of member (mor/phy) - * MEMBER_NEWFORM_FORCECOUNTRYCODE Force country */ if (!defined('NOLOGIN')) { @@ -66,7 +56,6 @@ require_once DOL_DOCUMENT_ROOT.'/compta/facture/class/paymentterm.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formcompany.class.php'; require_once DOL_DOCUMENT_ROOT.'/contact/class/contact.class.php'; -global $dolibarr_main_instance_unique_id; global $dolibarr_main_url_root; // Init vars @@ -268,6 +257,7 @@ if (empty($reshook) && $action == 'add' && (!empty($conference->id) && $conferen } else { // Need to create a confattendee $confattendee->date_creation = dol_now(); + $confattendee->date_subscription = dol_now(); $confattendee->email = $email; $confattendee->fk_project = $project->id; $confattendee->fk_actioncomm = $id; diff --git a/htdocs/public/eventorganization/subscriptionok.php b/htdocs/public/eventorganization/subscriptionok.php index 4a81084223d..8acf3daba78 100644 --- a/htdocs/public/eventorganization/subscriptionok.php +++ b/htdocs/public/eventorganization/subscriptionok.php @@ -57,7 +57,7 @@ if (!empty($conf->paypal->enabled)) { require_once DOL_DOCUMENT_ROOT.'/paypal/lib/paypalfunctions.lib.php'; } -global $dolibarr_main_instance_unique_id, $dolibarr_main_url_root, $mysoc; +global $dolibarr_main_url_root, $mysoc; $langs->loadLangs(array("main", "companies", "install", "other", "eventorganization")); diff --git a/htdocs/public/members/new.php b/htdocs/public/members/new.php index 4795338a938..055ffec56f9 100644 --- a/htdocs/public/members/new.php +++ b/htdocs/public/members/new.php @@ -30,6 +30,7 @@ * Note that you can add following constant to change behaviour of page * MEMBER_NEWFORM_AMOUNT Default amount for auto-subscribe form * MEMBER_NEWFORM_EDITAMOUNT 0 or 1 = Amount can be edited + * MEMBER_MIN_AMOUNT Minimum amount * MEMBER_NEWFORM_PAYONLINE Suggest payment with paypal, paybox or stripe * MEMBER_NEWFORM_DOLIBARRTURNOVER Show field turnover (specific for dolibarr foundation) * MEMBER_URL_REDIRECT_SUBSCRIPTION Url to redirect once subscribe submitted @@ -174,6 +175,7 @@ function llxFooterVierge() /* * Actions */ + $parameters = array(); // Note that $action and $object may have been modified by some hooks $reshook = $hookmanager->executeHooks('doActions', $parameters, $object, $action); @@ -385,75 +387,25 @@ if (empty($reshook) && $action == 'add') { } if (!empty($conf->global->MEMBER_NEWFORM_PAYONLINE) && $conf->global->MEMBER_NEWFORM_PAYONLINE != '-1') { - if ($conf->global->MEMBER_NEWFORM_PAYONLINE == 'all') { - $urlback = DOL_MAIN_URL_ROOT.'/public/payment/newpayment.php?from=membernewform&source=membersubscription&ref='.urlencode($adh->ref); - if (price2num(GETPOST('amount', 'alpha'))) { - $urlback .= '&amount='.price2num(GETPOST('amount', 'alpha')); - } - if (GETPOST('email')) { - $urlback .= '&email='.urlencode(GETPOST('email')); - } - if (!empty($conf->global->PAYMENT_SECURITY_TOKEN)) { - if (!empty($conf->global->PAYMENT_SECURITY_TOKEN_UNIQUE)) { - $urlback .= '&securekey='.urlencode(dol_hash($conf->global->PAYMENT_SECURITY_TOKEN.'membersubscription'.$adh->ref, 2)); - } else { - $urlback .= '&securekey='.urlencode($conf->global->PAYMENT_SECURITY_TOKEN); - } - } - } elseif ($conf->global->MEMBER_NEWFORM_PAYONLINE == 'paybox') { - $urlback = DOL_MAIN_URL_ROOT.'/public/paybox/newpayment.php?from=membernewform&source=membersubscription&ref='.urlencode($adh->ref); - if (price2num(GETPOST('amount', 'alpha'))) { - $urlback .= '&amount='.price2num(GETPOST('amount', 'alpha')); - } - if (GETPOST('email')) { - $urlback .= '&email='.urlencode(GETPOST('email')); - } - if (!empty($conf->global->PAYMENT_SECURITY_TOKEN)) { - if (!empty($conf->global->PAYMENT_SECURITY_TOKEN_UNIQUE)) { - $urlback .= '&securekey='.urlencode(dol_hash($conf->global->PAYMENT_SECURITY_TOKEN.'membersubscription'.$adh->ref, 2)); - } else { - $urlback .= '&securekey='.urlencode($conf->global->PAYMENT_SECURITY_TOKEN); - } - } - } elseif ($conf->global->MEMBER_NEWFORM_PAYONLINE == 'paypal') { - $urlback = DOL_MAIN_URL_ROOT.'/public/paypal/newpayment.php?from=membernewform&source=membersubscription&ref='.urlencode($adh->ref); - if (price2num(GETPOST('amount', 'alpha'))) { - $urlback .= '&amount='.price2num(GETPOST('amount', 'alpha')); - } - if (GETPOST('email')) { - $urlback .= '&email='.urlencode(GETPOST('email')); - } - if (!empty($conf->global->PAYMENT_SECURITY_TOKEN)) { - if (!empty($conf->global->PAYMENT_SECURITY_TOKEN_UNIQUE)) { - $urlback .= '&securekey='.urlencode(dol_hash($conf->global->PAYMENT_SECURITY_TOKEN.'membersubscription'.$adh->ref, 2)); - } else { - $urlback .= '&securekey='.urlencode($conf->global->PAYMENT_SECURITY_TOKEN); - } - } - } elseif ($conf->global->MEMBER_NEWFORM_PAYONLINE == 'stripe') { - $urlback = DOL_MAIN_URL_ROOT.'/public/stripe/newpayment.php?from=membernewform&source=membersubscription&ref='.$adh->ref; - if (price2num(GETPOST('amount', 'alpha'))) { - $urlback .= '&amount='.price2num(GETPOST('amount', 'alpha')); - } - if (GETPOST('email')) { - $urlback .= '&email='.urlencode(GETPOST('email')); - } - if (!empty($conf->global->PAYMENT_SECURITY_TOKEN)) { - if (!empty($conf->global->PAYMENT_SECURITY_TOKEN_UNIQUE)) { - $urlback .= '&securekey='.urlencode(dol_hash($conf->global->PAYMENT_SECURITY_TOKEN.'membersubscription'.$adh->ref, 2)); - } else { - $urlback .= '&securekey='.urlencode($conf->global->PAYMENT_SECURITY_TOKEN); - } - } - } else { - dol_print_error('', "Autosubscribe form is setup to ask an online payment for a not managed online payment"); - exit; + if (empty($conf->global->MEMBER_NEWFORM_EDITAMOUNT)) { // If edition of amount not allowed + // TODO Check amount is same than the amount required for the type of member or if not defined as the defeault amount into $conf->global->MEMBER_NEWFORM_AMOUNT + // It is not so important because a test is done on return of payment validation. + } + + $urlback = getOnlinePaymentUrl(0, 'member', $adh->ref, price2num(GETPOST('amount', 'alpha'), 'MT'), '', 0); + + if (GETPOST('email')) { + $urlback .= '&email='.urlencode(GETPOST('email')); + } + if ($conf->global->MEMBER_NEWFORM_PAYONLINE != '-1' && $conf->global->MEMBER_NEWFORM_PAYONLINE != 'all') { + $urlback .= '&paymentmethod='.urlencode($conf->global->MEMBER_NEWFORM_PAYONLINE); + } + } else { + if (!empty($entity)) { + $urlback .= '&entity='.((int) $entity); } } - if (!empty($entity)) { - $urlback .= '&entity='.$entity; - } dol_syslog("member ".$adh->ref." was created, we redirect to ".$urlback); } else { $error++; @@ -721,21 +673,24 @@ if (!empty($conf->global->MEMBER_NEWFORM_DOLIBARRTURNOVER)) { print ''."\n"; } -if (!empty($conf->global->MEMBER_NEWFORM_AMOUNT) || !empty($conf->global->MEMBER_NEWFORM_PAYONLINE)) { - // $conf->global->MEMBER_NEWFORM_SHOWAMOUNT is an amount +if (!empty($conf->global->MEMBER_NEWFORM_PAYONLINE)) { + $amount = 0; + $typeid = $conf->global->MEMBER_NEWFORM_FORCETYPE ? $conf->global->MEMBER_NEWFORM_FORCETYPE : GETPOST('typeid', 'int'); - // Set amount for the subscription - $amountbytype = $adht->amountByType(1); - $amount = !empty($amountbytype[GETPOST('typeid', 'int')]) ? $amountbytype[GETPOST('typeid', 'int')] : (isset($amount) ? $amount : 0); - - if (!empty($conf->global->MEMBER_NEWFORM_AMOUNT)) { + // Set amount for the subscription: + // - First check the amount of the member type. + $amountbytype = $adht->amountByType(1); // Load the array of amount per type + $amount = empty($amountbytype[$typeid]) ? (isset($amount) ? $amount : 0) : $amountbytype[$typeid]; + // - If not found, take the default amount + if (empty($amount) && !empty($conf->global->MEMBER_NEWFORM_AMOUNT)) { $amount = $conf->global->MEMBER_NEWFORM_AMOUNT; } - - if (!empty($conf->global->MEMBER_NEWFORM_PAYONLINE)) { - $amount = $amount ? $amount : (GETPOST('amount') ? price2num(GETPOST('amount'), 'MT', 2) : $conf->global->MEMBER_NEWFORM_AMOUNT); + // - If not set, we accept ot have amount defined as parameter (for backward compatibility). + if (empty($amount)) { + $amount = (GETPOST('amount') ? price2num(GETPOST('amount', 'alpha'), 'MT', 2) : ''); } + // Clean the amount $amount = price2num($amount); // $conf->global->MEMBER_NEWFORM_PAYONLINE is 'paypal', 'paybox' or 'stripe' @@ -749,6 +704,7 @@ if (!empty($conf->global->MEMBER_NEWFORM_AMOUNT) || !empty($conf->global->MEMBER print ' '.$langs->trans("Currency".$conf->currency); print ''; } + print "
    '.$langs->trans("Description").''; @@ -866,7 +906,8 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { } } - $linktocreatetime = dolGetButtonTitle($langs->trans('AddTimeSpent'), $linktocreatetimeHelpText, 'fa fa-plus-circle', $linktocreatetimeUrl, '', $linktocreatetimeBtnStatus); + $paramsbutton = array('morecss'=>'reposition'); + $linktocreatetime = dolGetButtonTitle($langs->trans('AddTimeSpent'), $linktocreatetimeHelpText, 'fa fa-plus-circle', $linktocreatetimeUrl, '', $linktocreatetimeBtnStatus, $paramsbutton); } $massactionbutton = ''; @@ -888,12 +929,12 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { $massactionbutton = $form->selectMassAction('', $arrayofmassactions); // Show section with information of task. If id of task is not defined and project id defined, then $projectidforalltimes is not empty. - if (empty($projectidforalltimes)) { + if (empty($projectidforalltimes) && empty($allprojectforuser)) { $head = task_prepare_head($object); print dol_get_fiche_head($head, 'task_time', $langs->trans("Task"), -1, 'projecttask', 0, '', 'reposition'); if ($action == 'deleteline') { - print $form->formconfirm($_SERVER["PHP_SELF"]."?".($object->id > 0 ? "id=".$object->id : 'projectid='.$projectstatic->id).'&lineid='.GETPOST("lineid", 'int').($withproject ? '&withproject=1' : ''), $langs->trans("DeleteATimeSpent"), $langs->trans("ConfirmDeleteATimeSpent"), "confirm_delete", '', '', 1); + print $form->formconfirm($_SERVER["PHP_SELF"]."?".($object->id > 0 ? "id=".$object->id : 'projectid='.$projectstatic->id).'&lineid='.GETPOST("lineid", 'int').($withproject ? '&withproject=1' : ''), $langs->trans("DeleteATimeSpent"), $langs->trans("ConfirmDeleteATimeSpent"), "confirm_deleteline", '', '', 1); } $param = ($withproject ? '&withproject=1' : ''); @@ -990,9 +1031,9 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { } - if ($projectstatic->id > 0) { + if ($projectstatic->id > 0 || $allprojectforuser > 0) { if ($action == 'deleteline' && !empty($projectidforalltimes)) { - print $form->formconfirm($_SERVER["PHP_SELF"]."?".($object->id > 0 ? "id=".$object->id : 'projectid='.$projectstatic->id).'&lineid='.GETPOST('lineid', 'int').($withproject ? '&withproject=1' : ''), $langs->trans("DeleteATimeSpent"), $langs->trans("ConfirmDeleteATimeSpent"), "confirm_delete", '', '', 1); + print $form->formconfirm($_SERVER["PHP_SELF"]."?".($object->id > 0 ? "id=".$object->id : 'projectid='.$projectstatic->id).'&lineid='.GETPOST('lineid', 'int').($withproject ? '&withproject=1' : ''), $langs->trans("DeleteATimeSpent"), $langs->trans("ConfirmDeleteATimeSpent"), "confirm_deleteline", '', '', 1); } // Initialize technical object to manage hooks. Note that conf->hooks_modules contains array @@ -1216,7 +1257,7 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { $tasks = array(); $sql = "SELECT t.rowid, t.fk_task, t.task_date, t.task_datehour, t.task_date_withhour, t.task_duration, t.fk_user, t.note, t.thm,"; - $sql .= " pt.ref, pt.label,"; + $sql .= " pt.ref, pt.label, pt.fk_projet,"; $sql .= " u.lastname, u.firstname, u.login, u.photo, u.statut as user_status,"; $sql .= " il.fk_facture as invoice_id, inv.fk_statut"; $sql .= " FROM ".MAIN_DB_PREFIX."projet_task_time as t"; @@ -1225,11 +1266,20 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { $sql .= " ".MAIN_DB_PREFIX."projet_task as pt, ".MAIN_DB_PREFIX."user as u"; $sql .= " WHERE t.fk_user = u.rowid AND t.fk_task = pt.rowid"; - if (empty($projectidforalltimes)) { + if (empty($projectidforalltimes) && empty($allprojectforuser)) { + // Limit on one task $sql .= " AND t.fk_task =".((int) $object->id); - } else { + } elseif (!empty($projectidforalltimes)) { + // Limit on one project $sql .= " AND pt.fk_projet IN (".$db->sanitize($projectidforalltimes).")"; + } elseif (!empty($allprojectforuser)) { + // Limit on on user + if (empty($search_user)) { + $search_user = $user->id; + } + $sql .= " AND t.fk_user = ".((int) $search_user); } + if ($search_note) { $sql .= natural_search('t.note', $search_note); } @@ -1290,7 +1340,7 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { print_barre_liste($title, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 'clock', 0, $linktocreatetime, '', $limit, 0, 0, 1); } else { - print ''."\n"; + print ''."\n"; $title = $langs->trans("ListTaskTimeForTask"); @@ -1322,6 +1372,9 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { print '
    '.$langs->trans("Date").''.$langs->trans("Project").''.$langs->trans("Task").''; + // Add project selector + print ''; - print ''; + print ''; print ''; - $durationtouse = ($_POST['timespent_duration'] ? $_POST['timespent_duration'] : ''); + $durationtouse = (GETPOST('timespent_duration') ? GETPOST('timespent_duration') : ''); if (GETPOSTISSET('timespent_durationhour') || GETPOSTISSET('timespent_durationmin')) { $durationtouse = (GETPOST('timespent_durationhour') * 3600 + GETPOST('timespent_durationmin') * 60); } @@ -1445,6 +1504,10 @@ if (($id > 0 || !empty($ref)) || $projectidforalltimes > 0) { $formother->select_year($search_year, 'search_year', 1, 20, 5); print ''; + if (empty($conf->cache['project'][$task_time->fk_projet])) { + $tmpproject = new Project($db); + $tmpproject->fetch($task_time->fk_projet); + $conf->cache['project'][$task_time->fk_projet] = $tmpproject; + } else { + $tmpproject = $conf->cache['project'][$task_time->fk_projet]; + } + print $tmpproject->getNomUrl(1); + print ''; + print ''; + print '
    \n"; print dol_get_fiche_end(); diff --git a/htdocs/public/members/public_list.php b/htdocs/public/members/public_list.php index 80e092f2951..4bf2a6b94bf 100644 --- a/htdocs/public/members/public_list.php +++ b/htdocs/public/members/public_list.php @@ -92,8 +92,8 @@ function llxFooterVierge() } -$sortfield = GETPOST("sortfield", 'alpha'); -$sortorder = GETPOST("sortorder", 'alpha'); +$sortfield = GETPOST('sortfield', 'aZ09comma'); +$sortorder = GETPOST('sortorder', 'aZ09comma'); $limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit; $page = GETPOSTISSET('pageplusone') ? (GETPOST('pageplusone') - 1) : GETPOST("page", 'int'); if (empty($page) || $page == -1) { diff --git a/htdocs/public/onlinesign/newonlinesign.php b/htdocs/public/onlinesign/newonlinesign.php index 65b12a91342..8bd95d23c8d 100644 --- a/htdocs/public/onlinesign/newonlinesign.php +++ b/htdocs/public/onlinesign/newonlinesign.php @@ -21,6 +21,7 @@ * \file htdocs/public/onlinesign/newonlinesign.php * \ingroup core * \brief File to offer a way to make an online signature for a particular Dolibarr entity + * Example of URL: https://localhost/public/onlinesign/newonlinesign.php?ref=PR... */ if (!defined('NOLOGIN')) { @@ -47,12 +48,13 @@ if (is_numeric($entity)) { require '../../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/company.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/payments.lib.php'; +require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; require_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php'; require_once DOL_DOCUMENT_ROOT.'/comm/propal/class/propal.class.php'; // Load translation files -$langs->loadLangs(array("main", "other", "dict", "bills", "companies", "errors", "paybox","propal")); +$langs->loadLangs(array("main", "other", "dict", "bills", "companies", "errors", "members", "paybox", "propal")); // Security check // No check on module enabled. Done later according to $validpaymentmethod @@ -60,7 +62,11 @@ $langs->loadLangs(array("main", "other", "dict", "bills", "companies", "errors", // Get parameters $action = GETPOST('action', 'aZ09'); $cancel = GETPOST('cancel', 'alpha'); +$confirm = GETPOST('confirm', 'alpha'); + + $refusepropal = GETPOST('refusepropal', 'alpha'); +$message = GETPOST('message', 'aZ09'); // Input are: // type ('invoice','order','contractline'), @@ -117,28 +123,55 @@ $urlko = preg_replace('/&$/', '', $urlko); // Remove last & $creditor = $mysoc->name; -$object = new Propal($db); -$object->fetch(0, $ref); +$type = $source; +if ($source == 'proposal') { + $object = new Propal($db); + $object->fetch(0, $ref); +} else { + accessforbidden('Bad value for source'); + exit; +} + + +// Check securitykey +$securekeyseed = ''; +if ($source == 'proposal') { + $securekeyseed = $conf->global->PROPOSAL_ONLINE_SIGNATURE_SECURITY_TOKEN; +} + +if (!dol_verifyHash($securekeyseed.$type.$ref, $SECUREKEY, '0')) { + http_response_code(403); + print 'Bad value for securitykey. Value provided '.dol_escape_htmltag($SECUREKEY).' does not match expected value for ref='.dol_escape_htmltag($ref); + exit(-1); +} + /* * Actions */ -if ($action == 'confirm_refusepropal') { +if ($action == 'confirm_refusepropal' && $confirm == 'yes') { + $db->begin(); + $sql = "UPDATE ".MAIN_DB_PREFIX."propal"; - $sql .= " SET fk_statut = ".((int) $object::STATUS_NOTSIGNED).", note_private = '".$object->note_private."', date_signature='".$db->idate(dol_now())."'"; + $sql .= " SET fk_statut = ".((int) $object::STATUS_NOTSIGNED).", note_private = '".$db->escape($object->note_private)."', date_signature='".$db->idate(dol_now())."'"; $sql .= " WHERE rowid = ".((int) $object->id); + dol_syslog(__METHOD__, LOG_DEBUG); $resql = $db->query($sql); if (!$resql) { $error++; } + if (!$error) { $db->commit(); - setEventMessage("PropalRefused"); + + $message = 'refused'; + setEventMessages("PropalRefused", null, 'warnings'); } else { $db->rollback(); } + $object->fetch(0, $ref); } @@ -160,11 +193,11 @@ $replacemainarea = (empty($conf->dol_hide_leftmenu) ? '
    ' : '').'
    '; llxHeader($head, $langs->trans("OnlineSignature"), '', '', 0, 0, '', '', '', 'onlinepaymentbody', $replacemainarea, 1); if ($action == 'refusepropal') { - print $form->formconfirm($_SERVER["PHP_SELF"].'?ref='.$ref, $langs->trans('RefusePropal'), $langs->trans('ConfirmRefusePropal', $object->ref), 'confirm_refusepropal', '', '', 1); + print $form->formconfirm($_SERVER["PHP_SELF"].'?ref='.urlencode($ref).'&securekey='.urlencode($SECUREKEY), $langs->trans('RefusePropal'), $langs->trans('ConfirmRefusePropal', $object->ref), 'confirm_refusepropal', '', '', 1); } -// Check link validity for param 'source' -if (!empty($source) && in_array($ref, array('member_ref', 'contractline_ref', 'invoice_ref', 'order_ref', ''))) { +// Check link validity for param 'source' to avoid use of the examples as value +if (!empty($source) && in_array($ref, array('member_ref', 'contractline_ref', 'invoice_ref', 'order_ref', 'proposal_ref', ''))) { $langs->load("errors"); dol_print_error_email('BADREFINONLINESIGNFORM', $langs->trans("ErrorBadLinkSourceSetButBadValueForRef", $source, $ref)); // End of page @@ -182,10 +215,11 @@ print ''."\n print ''."\n"; print ''."\n"; print ''; +print ''; print "\n"; print ''."\n"; -print ''."\n"; +print '
    '."\n"; // Show logo (search order: logo defined by ONLINE_SIGN_LOGO_suffix, then ONLINE_SIGN_LOGO_, then small company logo, large company logo, theme logo, common logo) // Define logo and logosmall @@ -220,16 +254,15 @@ if ($urllogo) { } print ''; } -if (!empty($conf->global->PROPOSAL_IMAGE_PUBLIC_SIGN)) { +if ($source == 'proposal' && !empty($conf->global->PROPOSAL_IMAGE_PUBLIC_SIGN)) { print '
    '; - print ''; + print ''; print '
    '; } // Output introduction text $text = ''; if (!empty($conf->global->ONLINE_SIGN_NEWFORM_TEXT)) { - $langs->load("members"); $reg = array(); if (preg_match('/^\((.*)\)$/', $conf->global->ONLINE_SIGN_NEWFORM_TEXT, $reg)) { $text .= $langs->trans($reg[1])."
    \n"; @@ -285,6 +318,13 @@ if ($source == 'proposal') { print ''.$proposal->thirdparty->name.''; print ''."\n"; + // Amount + + print ''."\n"; + // Object $text = ''.$langs->trans("SignatureProposalRef", $proposal->ref).''; @@ -298,9 +338,32 @@ if ($source == 'proposal') { print $langs->trans("DownloadDocument").''; } } else { - /* TODO If proposal signed newer than proposal ref, get link of proposal signed + $last_main_doc_file = $proposal->last_main_doc; - */ + if ($proposal->status == $proposal::STATUS_NOTSIGNED) { + $directdownloadlink = $proposal->getLastMainDocLink('proposal'); + if ($directdownloadlink) { + print '
    '; + print img_mime($proposal->last_main_doc, ''); + print $langs->trans("DownloadDocument").''; + } + } elseif ($proposal->status == $proposal::STATUS_SIGNED || $proposal->status == $proposal::STATUS_BILLED) { + if (preg_match('/_signed-(\d+)/', $last_main_doc_file)) { // If the last main doc has been signed + $last_main_doc_file_not_signed = preg_replace('/_signed-(\d+)/', '', $last_main_doc_file); + + $datefilesigned = dol_filemtime($last_main_doc_file); + $datefilenotsigned = dol_filemtime($last_main_doc_file_not_signed); + + if (empty($datefilenotsigned) || $datefilesigned > $datefilenotsigned) { + $directdownloadlink = $proposal->getLastMainDocLink('proposal'); + if ($directdownloadlink) { + print '
    '; + print img_mime($proposal->last_main_doc, ''); + print $langs->trans("DownloadDocument").''; + } + } + } + } } print ''; @@ -336,23 +399,27 @@ if ($action != 'dosign') { print ''."\n"; print ''."\n"; diff --git a/htdocs/public/opensurvey/studs.php b/htdocs/public/opensurvey/studs.php index 42cde055ac2..a1c9efed6c3 100644 --- a/htdocs/public/opensurvey/studs.php +++ b/htdocs/public/opensurvey/studs.php @@ -79,8 +79,8 @@ if (GETPOST('ajoutcomment', 'alpha')) { $error = 0; - $comment = GETPOST("comment", 'restricthtml'); - $comment_user = GETPOST('commentuser', 'nohtml'); + $comment = GETPOST("comment", 'alphanohtml'); + $comment_user = GETPOST('commentuser', 'alphanohtml'); if (!$comment) { $error++; @@ -202,7 +202,6 @@ for ($i = 0; $i < $nblines; $i++) { } if ($testmodifier) { - //var_dump($_POST);exit; $nouveauchoix = ''; for ($i = 0; $i < $nbcolonnes; $i++) { if (GETPOSTISSET("choix".$i) && GETPOST("choix".$i) == '1') { @@ -781,9 +780,9 @@ if ($comments) { if ($object->allow_comments) { print '
    '.$langs->trans("AddACommentForPoll")."
    \n"; - print '
    '."\n"; + print '
    '."\n"; print $langs->trans("Name").': '; - print '   '."\n"; + print '   '."\n"; print '
    '."\n"; print ''."\n"; diff --git a/htdocs/public/payment/newpayment.php b/htdocs/public/payment/newpayment.php index a5e24312ded..7bb61a708c5 100644 --- a/htdocs/public/payment/newpayment.php +++ b/htdocs/public/payment/newpayment.php @@ -70,9 +70,6 @@ include_once DOL_DOCUMENT_ROOT.'/core/class/hookmanager.class.php'; $hookmanager = new HookManager($db); $hookmanager->initHooks(array('newpayment')); -// For encryption -global $dolibarr_main_instance_unique_id; - // Load translation files $langs->loadLangs(array("main", "other", "dict", "bills", "companies", "errors", "paybox", "paypal", "stripe")); // File with generic data @@ -184,11 +181,12 @@ if ($source == 'organizedeventregistration') { } -$paymentmethod = GETPOST('paymentmethod', 'alphanohtml') ?GETPOST('paymentmethod', 'alphanohtml') : ''; // Empty in most cases. Defined when a payment mode is forced +$paymentmethod = GETPOST('paymentmethod', 'alphanohtml') ? GETPOST('paymentmethod', 'alphanohtml') : ''; // Empty in most cases. Defined when a payment mode is forced $validpaymentmethod = array(); // Detect $paymentmethod foreach ($_POST as $key => $val) { + $reg = array(); if (preg_match('/^dopayment_(.*)$/', $key, $reg)) { $paymentmethod = $reg[1]; break; @@ -246,7 +244,6 @@ $urlok = preg_replace('/&$/', '', $urlok); // Remove last & $urlko = preg_replace('/&$/', '', $urlko); // Remove last & - // Make special controls if ((empty($paymentmethod) || $paymentmethod == 'paypal') && !empty($conf->paypal->enabled)) { @@ -299,21 +296,23 @@ if ($tmpsource == 'membersubscription') { } $valid = true; if (!empty($conf->global->PAYMENT_SECURITY_TOKEN)) { - $token = ''; - $tokenoldcompat = ''; + $tokenisok = false; if (!empty($conf->global->PAYMENT_SECURITY_TOKEN_UNIQUE)) { if ($tmpsource && $REF) { - $token = dol_hash($conf->global->PAYMENT_SECURITY_TOKEN.$tmpsource.$REF, 2); // Use the source in the hash to avoid duplicates if the references are identical + // Use the source in the hash to avoid duplicates if the references are identical + $tokenisok = dol_verifyHash($conf->global->PAYMENT_SECURITY_TOKEN.$tmpsource.$REF, $SECUREKEY, '2'); + // Do a second test for retro-compatibility (token may have been hashed with membersubscription in external module) if ($tmpsource != $source) { - $tokenoldcompat = dol_hash($conf->global->PAYMENT_SECURITY_TOKEN.$source.$REF, 2); // for retro-compatibility (token may have been hashed with membersubscription in external module) + $tokenisok = dol_verifyHash($conf->global->PAYMENT_SECURITY_TOKEN.$source.$REF, $SECUREKEY, '2'); } } else { - $token = dol_hash($conf->global->PAYMENT_SECURITY_TOKEN, 2); + $tokenisok = dol_verifyHash($conf->global->PAYMENT_SECURITY_TOKEN, $SECUREKEY, '2'); } } else { - $token = $conf->global->PAYMENT_SECURITY_TOKEN; + $tokenisok = ($conf->global->PAYMENT_SECURITY_TOKEN == $SECUREKEY); } - if ($SECUREKEY != $token && (empty($tokenoldcompat) || $SECUREKEY != $tokenoldcompat)) { + + if (! $tokenisok) { if (empty($conf->global->PAYMENT_SECURITY_ACCEPT_ANY_TOKEN)) { $valid = false; // PAYMENT_SECURITY_ACCEPT_ANY_TOKEN is for backward compatibility } else { @@ -323,7 +322,7 @@ if (!empty($conf->global->PAYMENT_SECURITY_TOKEN)) { if (!$valid) { print '
    Bad value for key.
    '; - //print 'SECUREKEY='.$SECUREKEY.' token='.$token.' valid='.$valid; + //print 'SECUREKEY='.$SECUREKEY.' valid='.$valid; exit; } } @@ -439,21 +438,21 @@ if ($action == 'dopayment') { $origfulltag = GETPOST("fulltag", 'alpha'); // Securekey into back url useless for back url and we need an url lower than 150. - $urlok = preg_replace('/securekey=[^&]+/', '', $urlok); - $urlko = preg_replace('/securekey=[^&]+/', '', $urlko); + $urlok = preg_replace('/securekey=[^&]+&?/', '', $urlok); + $urlko = preg_replace('/securekey=[^&]+&?/', '', $urlko); if (empty($PRICE) || !is_numeric($PRICE)) { $mesg = $langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("Amount")); } elseif (empty($email)) { - $mesg = $langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("YourEMail")); + $mesg = $langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("ONLINE_PAYMENT_SENDEMAIL")); } elseif (!isValidEMail($email)) { $mesg = $langs->trans("ErrorBadEMail", $email); } elseif (!$origfulltag) { $mesg = $langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("PaymentCode")); } elseif (dol_strlen($urlok) > 150) { - $mesg = 'Error urlok too long '.$urlok.'( Paybox requires 150, found '.strlen($urlok).')'; + $mesg = 'Error urlok too long '.$urlok.' (Paybox requires 150, found '.strlen($urlok).')'; } elseif (dol_strlen($urlko) > 150) { - $mesg = 'Error urlko too long '.$urlko.'( Paybox requires 150, found '.strlen($urlok).')'; + $mesg = 'Error urlko too long '.$urlko.' (Paybox requires 150, found '.strlen($urlok).')'; } if (empty($mesg)) { @@ -479,8 +478,8 @@ if ($action == 'dopayment') { // Called when choosing Stripe mode. -// When using the Charge API architecture, this code is called after clicking the 'dopayment' with the Charge API architecture. -// When using the PaymentIntent API architecture, the Stripe customer is already created when creating PaymentIntent when showing payment page and the payment is already ok. +// When using the old Charge API architecture, this code is called after clicking the 'dopayment' with the Charge API architecture. +// When using the PaymentIntent API architecture, the Stripe customer was already created when creating PaymentIntent when showing payment page, and the payment is already ok when action=charge. if ($action == 'charge' && !empty($conf->stripe->enabled)) { $amountstripe = $amount; @@ -726,7 +725,7 @@ if ($action == 'charge' && !empty($conf->stripe->enabled)) { } } - // When using the PaymentIntent API architecture + // When using the PaymentIntent API architecture (mode set on by default into conf.class.php) if (!empty($conf->global->STRIPE_USE_INTENT_WITH_AUTOMATIC_CONFIRMATION)) { $service = 'StripeTest'; $servicestatus = 0; @@ -767,9 +766,23 @@ if ($action == 'charge' && !empty($conf->stripe->enabled)) { setEventMessages($paymentintent->status, null, 'errors'); $action = ''; } else { - // TODO We can alse record the payment mode into llx_societe_rib with stripe $paymentintent->payment_method + // TODO We can also record the payment mode into llx_societe_rib with stripe $paymentintent->payment_method // Note that with other old Stripe architecture (using Charge API), the payment mode was not recorded, so it is not mandatory to do it here. //dol_syslog("Create payment_method for ".$paymentintent->payment_method, LOG_DEBUG, 0, '_stripe'); + + // Get here amount and currency used for payment and force value into $amount and $currency so the real amount is saved into session instead + // of the amount and currency retreived from the POST. + if (!empty($paymentintent->currency) && !empty($paymentintent->amount)) { + $currency = strtoupper($paymentintent->currency); + $amount = $paymentintent->amount; + + // Correct the amount according to unit of currency + // See https://support.stripe.com/questions/which-zero-decimal-currencies-does-stripe-support + $arrayzerounitcurrency = array('BIF', 'CLP', 'DJF', 'GNF', 'JPY', 'KMF', 'KRW', 'MGA', 'PYG', 'RWF', 'VND', 'VUV', 'XAF', 'XOF', 'XPF'); + if (!in_array($currency, $arrayzerounitcurrency)) { + $amount = $amount / 100; + } + } } } @@ -777,8 +790,8 @@ if ($action == 'charge' && !empty($conf->stripe->enabled)) { $remoteip = getUserRemoteIP(); $_SESSION["onlinetoken"] = $stripeToken; - $_SESSION["FinalPaymentAmt"] = $amount; - $_SESSION["currencyCodeType"] = $currency; + $_SESSION["FinalPaymentAmt"] = $amount; // amount really paid (coming from Stripe). Will be used for check in paymentok.php. + $_SESSION["currencyCodeType"] = $currency; // currency really used for payment (coming from Stripe). Will be used for check in paymentok.php. $_SESSION["paymentType"] = ''; $_SESSION['ipaddress'] = ($remoteip ? $remoteip : 'unknown'); // Payer ip $_SESSION['payerID'] = is_object($customer) ? $customer->id : ''; @@ -911,7 +924,8 @@ print ''."\n"; print ''."\n"; print "\n"; -print '
    '.$langs->trans("Amount"); + print ''; + print ''.price($proposal->total_ttc, 0, $langs, 1, -1, -1, $conf->currency).''; + print '
    '; + if ($action == "dosign" && empty($cancel)) { print '
    '; print ''; print '
    '; print '
    '; - print ''; + // Do not use class="reposition" here: It breaks the submit and there is a message on top to say it's ok, so going back top is better. + print ''; print ''; + + // Add js code managed into the div #signature print ' '; } else { - if ($object->status == $object::STATUS_SIGNED) { - print '
    '; - print ''.$langs->trans("PropalAlreadySigned").''; - } elseif ($object->status == $object::STATUS_NOTSIGNED) { - print '
    '; - print ''.$langs->trans("PropalAlreadyRefused").''; - } else { - print ''; - print ''; + if ($source == 'proposal') { + if ($object->status == $object::STATUS_SIGNED) { + print '
    '; + if ($message == 'signed') { + print ''.$langs->trans("PropalSigned").''; + } else { + print ''.$langs->trans("PropalAlreadySigned").''; + } + } elseif ($object->status == $object::STATUS_NOTSIGNED) { + print '
    '; + if ($message == 'refused') { + print ''.$langs->trans("PropalRefused").''; + } else { + print ''.$langs->trans("PropalAlreadyRefused").''; + } + } else { + print ''; + print ''; + } } } print '
    '."\n"; +// Section with payment informationsummary +print '
    '."\n"; // Output introduction text $text = ''; @@ -968,13 +982,13 @@ if (!$source) { if (empty($amount) || !is_numeric($amount)) { print ''; print ''; + // Currency + print ' '.$langs->trans("Currency".$currency).''; } else { - print ''.price($amount).''; + print ''.price($amount, 1, $langs, 1, -1, -1, $currency).''; // Price with currency print ''; print ''; } - // Currency - print ' '.$langs->trans("Currency".$currency).''; print ''; print ''."\n"; @@ -1067,13 +1081,13 @@ if ($source == 'order') { if (empty($amount) || !is_numeric($amount)) { print ''; print ''; + // Currency + print ' '.$langs->trans("Currency".$currency).''; } else { - print ''.price($amount).''; + print ''.price($amount, 1, $langs, 1, -1, -1, $currency).''; // Price with currency print ''; print ''; } - // Currency - print ' '.$langs->trans("Currency".$currency).''; print ''; print ''."\n"; @@ -1198,18 +1212,16 @@ if ($source == 'invoice') { if (empty($amount) || !is_numeric($amount)) { print ''; print ''; + print ' '.$langs->trans("Currency".$currency).''; } else { - print ''.price($amount).''; + print ''.price($amount, 1, $langs, 1, -1, -1, $currency).''; // Price with currency print ''; print ''; } - print ' '.$langs->trans("Currency".$currency).''; - print ''; } else { - print ''.price($object->total_ttc, 1, $langs).''; - print ' '.$langs->trans("Currency".$currency).''; - print ''; + print ''.price($object->total_ttc, 1, $langs, 1, -1, -1, $currency).''; // Price with currency } + print ''; print ''."\n"; // Tag @@ -1325,7 +1337,7 @@ if ($source == 'contractline') { $qty = 1; if (GETPOST('qty')) { - $qty = GETPOST('qty'); + $qty = price2num(GETPOST('qty', 'alpha'), 'MS'); } // Creditor @@ -1402,13 +1414,13 @@ if ($source == 'contractline') { if (empty($amount) || !is_numeric($amount)) { print ''; print ''; + // Currency + print ' '.$langs->trans("Currency".$currency).''; } else { - print ''.price($amount).''; + print ''.price($amount, 1, $langs, 1, -1, -1, $currency).''; // Price with currency print ''; print ''; } - // Currency - print ' '.$langs->trans("Currency".$currency).''; print ''; print ''."\n"; @@ -1460,9 +1472,12 @@ if ($source == 'member' || $source == 'membersubscription') { $langs->load("members"); require_once DOL_DOCUMENT_ROOT.'/adherents/class/adherent.class.php'; + require_once DOL_DOCUMENT_ROOT.'/adherents/class/adherent_type.class.php'; require_once DOL_DOCUMENT_ROOT.'/adherents/class/subscription.class.php'; $member = new Adherent($db); + $adht = new AdherentType($db); + $result = $member->fetch('', $ref); if ($result <= 0) { $mesg = $member->error; @@ -1470,6 +1485,8 @@ if ($source == 'member' || $source == 'membersubscription') { } else { $member->fetch_thirdparty(); $subscription = new Subscription($db); + + $adht->fetch($member->typeid); } $object = $member; @@ -1478,6 +1495,11 @@ if ($source == 'member' || $source == 'membersubscription') { if (GETPOST("amount", 'alpha')) { $amount = GETPOST("amount", 'alpha'); } + // If amount still not defined, we take amount of the type of member + if (empty($amount)) { + $amount = $adht->amount; + } + $amount = price2num($amount, 'MT'); } @@ -1499,10 +1521,13 @@ if ($source == 'member' || $source == 'membersubscription') { // Debitor print ''."\n"; @@ -1752,7 +1776,7 @@ if ($source == 'donation') { print ' ('.$langs->trans("ToComplete"); } if (!empty($conf->global->MEMBER_EXT_URL_SUBSCRIPTION_INFO)) { - print ' - '.$langs->trans("SeeHere").''; + print ' - '.$langs->trans("SeeHere").''; } if (empty($conf->global->MEMBER_NEWFORM_AMOUNT)) { print ')'; @@ -1782,18 +1806,18 @@ if ($source == 'donation') { } print ''; print ''; + // Currency + print ' '.$langs->trans("Currency".$currency).''; } else { $valtoshow = $amount; if (!empty($conf->global->MEMBER_MIN_AMOUNT) && $valtoshow) { $valtoshow = max($conf->global->MEMBER_MIN_AMOUNT, $valtoshow); $amount = $valtoshow; } - print ''.price($valtoshow).''; + print ''.price($valtoshow, 1, $langs, 1, -1, -1, $currency).''; // Price with currency print ''; print ''; } - // Currency - print ' '.$langs->trans("Currency".$currency).''; print ''; print ''."\n"; @@ -1882,12 +1906,9 @@ if ($source == 'organizedeventregistration') { print ''."\n"; @@ -1968,12 +1989,9 @@ if ($source == 'boothlocation') { print ''."\n"; @@ -2286,7 +2304,7 @@ if (preg_match('/^dopayment/', $action)) { // If we choosed/click on the payme print ''."\n"; // Code to ask the credit card. This use the default "API version". No way to force API version when using JS code. - print ' + + + + + + diff --git a/htdocs/public/test/test_exec.php b/htdocs/public/test/test_exec.php new file mode 100644 index 00000000000..94a1d96462b --- /dev/null +++ b/htdocs/public/test/test_exec.php @@ -0,0 +1,101 @@ +\n"; +print "Legend:
    \n"; +print 'PHP_SESSION_DISABLED='.PHP_SESSION_DISABLED."
    \n"; +print 'PHP_SESSION_NONE='.PHP_SESSION_NONE."
    \n"; +print 'PHP_SESSION_ACTIVE='.PHP_SESSION_ACTIVE."
    \n"; +print '
    '; + +print 'session_status='.session_status().' (before main.inc.php)
    '; + +print '

    '."\n"; + +require '../../main.inc.php'; + +// Security +if ($dolibarr_main_prod) { + accessforbidden('Access forbidden when $dolibarr_main_prod is set to 1'); +} + + +/* + * View + */ + +print "*** TEST READ OF /tmp/test.txt FILE
    \n"; + +$out=''; +$ret=0; + +$file = '/tmp/test.txt'; +$f=fopen($file, 'r'); +if ($f) { + $s=fread($f, 4096); + print $s; + fclose($f); +} else { + print "Failed to open file ".$file."
    \n"; +} + +print '

    '."\n"; + + +print "*** TEST READ OF /test.txt FILE AND LS /dev/std*
    \n"; + +exec('cat /test.txt; ls /dev/std*; sleep 1;', $out, $ret); +print $ret."
    \n"; +print_r($out); +print '
    '; + +print '

    '."\n"; + + +print "*** TRY TO RUN CLAMDSCAN
    \n"; + +$ret = 0; +$out = null; +exec('/usr/bin/clamdscan --fdpass filethatdoesnotexists.php', $out, $ret); +print $ret."
    \n"; +print_r($out); diff --git a/htdocs/public/test/test_forms.php b/htdocs/public/test/test_forms.php index d89e04e12a6..47d827cbaf5 100644 --- a/htdocs/public/test/test_forms.php +++ b/htdocs/public/test/test_forms.php @@ -8,10 +8,16 @@ if (!defined('NOSESSION')) { require '../../main.inc.php'; include_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php'; +// Security if ($dolibarr_main_prod) { - accessforbidden(); + accessforbidden('Access forbidden when $dolibarr_main_prod is set to 1'); } + +/* + * View + */ + llxHeader(); ?> diff --git a/htdocs/public/test/test_sessionlock.php b/htdocs/public/test/test_sessionlock.php index 18a1ef73d08..8464ba2eb4f 100644 --- a/htdocs/public/test/test_sessionlock.php +++ b/htdocs/public/test/test_sessionlock.php @@ -52,11 +52,15 @@ print '
    '; require '../../main.inc.php'; -/* No need for this. +// Security if ($dolibarr_main_prod) { accessforbidden(); } -*/ + + +/* + * View + */ print 'session_status='.session_status().' (after main.inc.php)'; print '
    '; diff --git a/htdocs/public/ticket/create_ticket.php b/htdocs/public/ticket/create_ticket.php index e621feb6653..51424d9277e 100644 --- a/htdocs/public/ticket/create_ticket.php +++ b/htdocs/public/ticket/create_ticket.php @@ -4,7 +4,7 @@ * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or + * the Free Software Foundation; either version 3 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, @@ -47,6 +47,12 @@ if (!defined('NOBROWSERNOTIF')) { define('NOBROWSERNOTIF', '1'); } +// For MultiCompany module. +// Do not use GETPOST here, function is not defined and define must be done before including main.inc.php +$entity = (!empty($_GET['entity']) ? (int) $_GET['entity'] : (!empty($_POST['entity']) ? (int) $_POST['entity'] : 1)); +if (is_numeric($entity)) { + define("DOLENTITY", $entity); +} require '../../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/ticket/class/actions_ticket.class.php'; @@ -120,7 +126,7 @@ if (empty($reshook) && GETPOST('removedfile', 'alpha') && !GETPOST('save', 'alph $upload_dir_tmp = $vardir.'/temp/'.session_id(); // TODO Delete only files that was uploaded from email form - dol_remove_file_process($_POST['removedfile'], 0, 0); + dol_remove_file_process(GETPOST('removedfile'), 0, 0); $action = 'create_ticket'; } @@ -167,7 +173,7 @@ if (empty($reshook) && $action == 'create_ticket' && GETPOST('save', 'alpha')) { // Check Captcha code if is enabled if (!empty($conf->global->MAIN_SECURITY_ENABLECAPTCHA)) { $sessionkey = 'dol_antispam_value'; - $ok = (array_key_exists($sessionkey, $_SESSION) === true && (strtolower($_SESSION[$sessionkey]) === strtolower(GETPOST('code', 'none')))); + $ok = (array_key_exists($sessionkey, $_SESSION) === true && (strtolower($_SESSION[$sessionkey]) === strtolower(GETPOST('code', 'restricthtml')))); if (!$ok) { $error++; array_push($object->errors, $langs->trans("ErrorBadValueForCode")); @@ -253,7 +259,7 @@ if (empty($reshook) && $action == 'create_ticket' && GETPOST('save', 'alpha')) { $message = ($conf->global->TICKET_MESSAGE_MAIL_NEW ? $conf->global->TICKET_MESSAGE_MAIL_NEW : $langs->transnoentities('TicketNewEmailBody')).'

    '; $message .= $langs->transnoentities('TicketNewEmailBodyInfosTicket').'
    '; - $url_public_ticket = ($conf->global->TICKET_URL_PUBLIC_INTERFACE ? $conf->global->TICKET_URL_PUBLIC_INTERFACE.'/' : dol_buildpath('/public/ticket/view.php', 2)).'?track_id='.$object->track_id; + $url_public_ticket = ($conf->global->TICKET_URL_PUBLIC_INTERFACE ? $conf->global->TICKET_URL_PUBLIC_INTERFACE.'/view.php' : dol_buildpath('/public/ticket/view.php', 2)).'?track_id='.$object->track_id; $infos_new_ticket = $langs->transnoentities('TicketNewEmailBodyInfosTrackId', ''.$object->track_id.'').'
    '; $infos_new_ticket .= $langs->transnoentities('TicketNewEmailBodyInfosTrackUrl').'

    '; @@ -297,7 +303,7 @@ if (empty($reshook) && $action == 'create_ticket' && GETPOST('save', 'alpha')) { if (is_array($object->array_options) && count($object->array_options) > 0) { foreach ($object->array_options as $key => $value) { $key = substr($key, 8); // remove "options_" - $message_admin .= '
  • '.$langs->trans($extrafields->attributes[$object->element]['label'][$key]).' : '.$extrafields->showOutputField($key, $value).'
  • '; + $message_admin .= '
  • '.$langs->trans($extrafields->attributes[$object->table_element]['label'][$key]).' : '.$extrafields->showOutputField($key, $value, '', $object->table_element).'
  • '; } } $message_admin .= ''; @@ -342,7 +348,7 @@ if (empty($reshook) && $action == 'create_ticket' && GETPOST('save', 'alpha')) { $messagetoshow = str_replace(array('{s1}', '{s2}'), array(''.$object->track_id.'', ''.$object->ref.''), $messagetoshow); setEventMessages($messagetoshow, null, 'warnings'); setEventMessages($langs->trans('PleaseRememberThisId'), null, 'warnings'); - header("Location: index.php"); + header("Location: index.php".(!empty($entity) && !empty($conf->multicompany->enabled)?'?entity='.$entity:'')); exit; } } else { diff --git a/htdocs/public/ticket/index.php b/htdocs/public/ticket/index.php index 6abeb5f8b12..227dcf3867b 100644 --- a/htdocs/public/ticket/index.php +++ b/htdocs/public/ticket/index.php @@ -40,7 +40,6 @@ if (!defined('NOBROWSERNOTIF')) { // For MultiCompany module. // Do not use GETPOST here, function is not defined and define must be done before including main.inc.php -// TODO This should be useless. Because entity must be retrieve from object ref and not from url. $entity = (!empty($_GET['entity']) ? (int) $_GET['entity'] : (!empty($_POST['entity']) ? (int) $_POST['entity'] : 1)); if (is_numeric($entity)) { define("DOLENTITY", $entity); @@ -77,7 +76,6 @@ if (empty($conf->global->TICKET_ENABLE_PUBLIC_INTERFACE)) { print $langs->trans('TicketPublicInterfaceForbidden'); exit; } - $arrayofjs = array(); $arrayofcss = array('/ticket/css/styles.css.php'); @@ -86,9 +84,9 @@ llxHeaderTicket($langs->trans("Tickets"), "", 0, 0, $arrayofjs, $arrayofcss); print ''; diff --git a/htdocs/public/ticket/list.php b/htdocs/public/ticket/list.php index db5f5d8d754..1a3c0c3babd 100644 --- a/htdocs/public/ticket/list.php +++ b/htdocs/public/ticket/list.php @@ -40,6 +40,13 @@ if (!defined('NOBROWSERNOTIF')) { } // If this page is public (can be called outside logged session) +// For MultiCompany module. +// Do not use GETPOST here, function is not defined and define must be done before including main.inc.php +$entity = (!empty($_GET['entity']) ? (int) $_GET['entity'] : (!empty($_POST['entity']) ? (int) $_POST['entity'] : 1)); +if (is_numeric($entity)) { + define("DOLENTITY", $entity); +} + require '../../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/ticket/class/actions_ticket.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formticket.class.php'; @@ -70,6 +77,9 @@ if (isset($_SESSION['email_customer'])) { $object = new Ticket($db); +// Initialize technical object to manage hooks of page. Note that conf->hooks_modules contains array of hook context +$hookmanager->initHooks(array('ticketpubliclist', 'globalcard')); + if (empty($conf->ticket->enabled)) { accessforbidden('', 0, 0, 1); } @@ -154,10 +164,6 @@ if ($action == "view_ticketlist") { } } -//$object->doActions($action); - - - /* * View */ @@ -215,6 +221,9 @@ if ($action == "view_ticketlist") { $filter = array(); $param = 'action=view_ticketlist'; + if (!empty($entity) && !empty($conf->multicompany->enabled)) { + $param .= '&entity='.$entity; + } // Definition of fields for list $arrayfields = array( @@ -288,8 +297,8 @@ if ($action == "view_ticketlist") { require DOL_DOCUMENT_ROOT.'/core/actions_changeselectedfields.inc.php'; - $sortfield = GETPOST("sortfield", 'alpha'); - $sortorder = GETPOST("sortorder", 'alpha'); + $sortfield = GETPOST('sortfield', 'aZ09comma'); + $sortorder = GETPOST('sortorder', 'aZ09comma'); if (!$sortfield) { $sortfield = 't.datec'; @@ -392,7 +401,7 @@ if ($action == "view_ticketlist") { print_barre_liste($langs->trans('TicketList'), $page, 'public/list.php', $param, $sortfield, $sortorder, '', $num, $num_total, 'ticket'); // Search bar - print ''."\n"; + print ''."\n"; print ''; print ''; print ''; @@ -401,6 +410,11 @@ if ($action == "view_ticketlist") { $varpage = empty($contextpage) ? $url_page_current : $contextpage; $selectedfields = $form->multiSelectArrayWithCheckbox('selectedfields', $arrayfields, $varpage); // This also change content of $arrayfields + // allow to display information before list + $parameters=array('arrayfields'=>$arrayfields); + $reshook=$hookmanager->executeHooks('printFieldListHeader', $parameters, $object, $action); // Note that $action and $object may have been modified by hook + print $hookmanager->resPrint; + print '
    '.$langs->trans("Member"); - print ''; - if ($member->morphy == 'mor' && !empty($member->societe)) { - print $member->societe; + print ''; + print ''; + if ($member->morphy == 'mor' && !empty($member->company)) { + print img_picto('', 'company', 'class="pictofixedwidth"'); + print $member->company; } else { + print img_picto('', 'member', 'class="pictofixedwidth"'); print $member->getFullName($langs); } print ''; @@ -1591,7 +1616,7 @@ if ($source == 'member' || $source == 'membersubscription') { print ' ('.$langs->trans("ToComplete"); } if (!empty($conf->global->MEMBER_EXT_URL_SUBSCRIPTION_INFO)) { - print ' - '.$langs->trans("SeeHere").''; + print ' - '.$langs->trans("SeeHere").''; } if (empty($conf->global->MEMBER_NEWFORM_AMOUNT)) { print ')'; @@ -1621,23 +1646,22 @@ if ($source == 'member' || $source == 'membersubscription') { } print ''; if (empty($conf->global->MEMBER_NEWFORM_EDITAMOUNT)) { - print ''; + print ''; print ''; } else { print ''; } + print ' '.$langs->trans("Currency".$currency).''; } else { $valtoshow = $amount; if (!empty($conf->global->MEMBER_MIN_AMOUNT) && $valtoshow) { $valtoshow = max($conf->global->MEMBER_MIN_AMOUNT, $valtoshow); $amount = $valtoshow; } - print ''.price($valtoshow).''; + print ''.price($valtoshow, 1, $langs, 1, -1, -1, $currency).''; // Price with currency print ''; print ''; } - // Currency - print ' '.$langs->trans("Currency".$currency).''; print ''; print '
    '.$langs->trans("Amount"); print ''; $valtoshow = $amount; - print ''.price($valtoshow).''; + print ''.price($valtoshow, 1, $langs, 1, -1, -1, $currency).''; // Price with currency print ''; print ''; - - // Currency - print ' '.$langs->trans("Currency".$currency).''; print ''; print '
    '.$langs->trans("Amount"); print ''; $valtoshow = $amount; - print ''.price($valtoshow).''; + print ''.price($valtoshow, 1, $langs, 1, -1, -1, $currency).''; // Price with currency print ''; print ''; - - // Currency - print ' '.$langs->trans("Currency".$currency).''; print ''; print '
    '; // Filter bar @@ -651,7 +665,7 @@ if ($action == "view_ticketlist") { } print '>'; $tmpkey = 'options_'.$key; - print $extrafields->showOutputField($key, $obj->$tmpkey, '', 1); + print $extrafields->showOutputField($key, $obj->$tmpkey, '', $object->table_element); print ''; } } @@ -674,7 +688,7 @@ if ($action == "view_ticketlist") { print '
    '; print ''; - print '