Compare commits

..

882 Commits

Author SHA1 Message Date
Eric - CAP-REL
ff146c4713 handle race condition user with no right - prevent infinite loop (#37220) 2026-02-23 20:12:44 +01:00
John BOTELLA
3d88e03c88 UIUX : Dolibarr js context from experimental to core (#37228)
* NEW Use the js lib into htdocs/public/includes instead of htdocs/includes

* New LNE Collect of buisness informations (#37084)

* Working LNE ping

* remove GPDA

* Add of other informations

* remove testing var

* fix Ci

* fix Ci

* fix ci

* fix CI

* Fix Ci

* fix Ci

---------

Co-authored-by: Lucas Marcouiller <lmarcouiller@dolicloud.com>

* CI

* CI

* CI

* CI

* Clean code. File not used.

* CSS

* CSS

* Fix phpunit

* More legal info

* CI

* Fix CI

* Fix: IRPF tax not applied when creating invoice from project times (#37077)

* Remove 'supplier_invoice' from old path array

* Update module path in arrayforoldpath

Sorry Eldy, I was confused. You are absolutely right, it is already corrected.

* Replace localtax2 assignment with get_localtax function


Error when creating an invoice with personal income tax from project times. The rate does not apply

* Refactor localtax1 calculation using get_localtax

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Fix: IRPF tax not applied when creating invoice from project times (#37077)

* Remove 'supplier_invoice' from old path array

* Update module path in arrayforoldpath

Sorry Eldy, I was confused. You are absolutely right, it is already corrected.

* Replace localtax2 assignment with get_localtax function


Error when creating an invoice with personal income tax from project times. The rate does not apply

* Refactor localtax1 calculation using get_localtax

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Protect module

* Add currency

* CSS

* WIP LNE

* Fix navigation

* cs

* Debug registration process

* Debug setup navigation

* CI

* CI

* Factorize code

* Fix CI

* Fix CI

* Fix CI

* CI

* CI

* CI

* CI

* Disable phan on v23

* CI

* CI

* FIX: missing include for blockedlog lib (#37165)

* Debug CI

* fix ternary always true (#37161)

* fix ternary always true

* Update requests.php

* Update registration.php

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* CI

* FIX: missing include for blockedlog lib (#37165)

* FIX #37134 Use json_encode for IMAP search logging in EmailCollector (#37135)

var_export() produces multiline output that breaks log aggregators
(Loki, Splunk, Elasticsearch) as each line becomes a separate log entry.

Using json_encode() produces single-line structured output that works
correctly with all log aggregation tools.

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Populate syslog with placeholder (#37163)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Doc

* datamodel for user change password next time (#37155)

* Qual: Update phan baseline (#37172)

* Fix typo in file path (#37160)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Fix phpunit

* Complete call to setStatus so we have a trigy as 4th parameter (help to
fix the #37129)

* FIX Product - Warning on admin (#37157)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* FIX Product - Warning on admin + CSS (#37158)

* FIX Product - Warning on admin

* CSS

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* CI

* CI

* CI

* Avoid error if include fails

* More functions in blacklist (even if nw we use the whitelist by default)

* #37166 [SQL] add: email template for ticket admin creation (#37182)

* Replace var_export with new function formatLogObject (#37178)

* FIX BOM - Class product missing, column offset and information recording (form/input overlap) in admin (#37177)

* FIX BOM - Class product missing in admin

* Fix column offset and information recording (form/input overlap)

* ci

* ci

* FIX Intracommreport - Warning & link problem on tab (#37176)

* FIX Bank transfer admin - Warning & save 0 on constant PAYMENTBYBANKTRANSFER_ADDDAYS (#37175)

* Look and feel v24

* Update default time handling in index.php (#37150)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Fix file path comment in supplier invoice module (#37133)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Fix file path comment in supplier invoice module (#37133)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Fix CI

* Add template in migration

* fix phpdoc comment (#37184)

* fix phpdoc comment

* fix phpdoc comment

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* CI

* Fix phpstan

* Replace var_export by formatLogObject (continued) (#37188)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Debug amount suggested on membership public form

* Issue 36923 Fix session title handling in survey creation (#37105)

* Issue 36923 Fix session title handling in survey creation

* Change input field to use id attribute for title

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* fix phpstan errors blocking action baseline (#37189)

* fix phpstan errors blocking action baseline

* fix phpstan errors blocking action baseline

* fix phpstan errors blocking action baseline

* fix phpstan errors blocking action baseline

* fix phpstan errors blocking action baseline

* refresh baseline

* QUAL Replace var_export() with json_encode() in dol_syslog() calls (#37138)

var_export() produces multiline output that breaks log aggregators
(Loki, Splunk, Elasticsearch, Graylog) as each line becomes a separate
log entry.

json_encode() produces single-line structured output that works correctly
with all log aggregation tools. This pattern is already used elsewhere
in Dolibarr (accountancy, install modules).

Files changed:
- core/class/commoninvoice.class.php (payment intent logging)
- core/class/commonobject.class.php (payment terms logging)
- core/modules/mailings/advthirdparties.modules.php (mailing targets)
- core/modules/oauth/google_oauthcallback.php (userinfo logging)
- core/modules/oauth/generic_oauthcallback.php (userinfo logging)
- public/payment/newpayment.php (GET/POST debug logging)
- public/payment/paymentok.php (payment tag logging)
- public/stripe/ipn.php (Stripe event data logging)
- paypal/lib/paypal.lib.php (PayPal response logging)
- api/index.php (API debug logging)
- stripe/class/stripe.class.php (payment/setup intent logging)

Co-authored-by: f-hoedl <hoefla14@htl-kaindorf.ac.at>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Fix CI

* CI

* Check if upload_max_filesize is not empty

* clean code

* Debug v23

* CI

* Fix #33521 VAT total false (#36990)

* - Fix #33521 VAT total false
- Fix some warnings
- Fix : delete $this->vat_rate

* - Fix #33521 VAT total false
- Fix some warnings
- Fix  :delete $this->tva array (replaced by $this->tva_array)

* - Fix #33521 VAT total false
- Fix some warnings
- Fix  :delete $this->tva array (replaced by $this->tva_array)

* Update pdf_octopus.modules.php

* Update pdf_octopus.modules.php

* Update pdf_octopus.modules.php

* Update pdf_octopus.modules.php

* Update pdf_octopus.modules.php

---------

Co-authored-by: vmaury <vmaury@vmaury-Lafite-Pro-16-AMD>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* NEW #25829 Automatically send the invoice generated from a template (#36967)

* Update DB

* ADD email template

* Ajout d'une clé de trad

* Ajout des traductions

* Suppression des traductions, sauf en_US

* Add flag auto send

* Modif form + cron auto send

* Suppression auto_send

* correction loopError

* ajout du selected au model de mail

* Prise en compte default model

* Fix pre-commit

* ménage

* precommit

* Correction Phan

* Correction Phan

* Correction, double cal du trigger

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Develop force user change pass userclass (#37174)

* datamodel for user change password next time

* add force_pass_change in user object

* Initialize force_pass_change to 0

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Another step for #37171

* Qual: Partial phan run on PR's, complete run on integration branches (#37186)

* Qual: Partial phan run on PR's, complete on main

# Qual: Partial phan run on PR's, complete on main

The selection is based on the branch name.
To run a complete phan run in a PR, the branch name of the PR must include phan_full.
This can help to fix remaining phan issue before re-integrating to the develop branch.

* qual: Update workflow and pre-commit configurations

- Enable phan workflow by uncommenting the relevant lines
- Update actionlint version to v1.7.10
- Add manual stage to actionlint hook in pre-commit-config.yaml

* qual: Update Phan analysis conditions

The conditions for running Phan analysis have been updated to include an additional check for branches containing 'phan_full'.

* qual: Update Phan workflow

- Replace github.event.ref with github.ref_name
- Add FILE_CHANGE_LIST environment variable for better file handling
- Update file list creation and usage in the workflow

* qual: Update Phan workflow conditions

Fix the branch reference (head_ref in PR, ref_name otherwise)

* Add step for debug information

* Remove debug step

* Fix: Missing initialisations members/new.php

Following a suppression of assignments, the variables disabledphy and disabledmor were undefined.

* fix: Update budget selection dropdown arguments in member creation form

Correct the arguments in the member creation form.

* qual: Add cs2pr to phan workflow

- Add cs2pr to the tools list in the phan workflow
- Change the output mode of phan to checkstyle
- Add a step to add results to PR as Github notices
- Add a step to provide phan log as artifact

* qual: Update Phan workflow to use environment variable for file list

The change fixes the Phan workflow to use the environment variable `$FILE_CHANGED_LIST` to clear the file

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Fix phan

* Fix phan

* Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into 23.0

* Doc

* Qual: Fix ambigious redirect error on Phan workflow (#37200)

# Qual: Fix ambigious redirect error on Phan workflow

Rewrote the shell command that is supposed to suppress a file contents
but is flagged by the environment.

* PHPStan > Update baseline (#37197)

Co-authored-by: Dolibot <dolibarr-bot@users.noreply.github.com>

* Typo fix (#37195)

* Debug v23 - filters on agenda pages

* css

* css

* css

* qual: Update PHPStan workflow to run on all files in integration (#37207)

The PHPStan workflow has been updated to run on all files in integration branches.

* Fix CI

* Add hook in isEditable()

* Debug v23

* CLOSE #37190 ODT Templates for thirdparties - Birthday is returned in epoch format (#37198)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* fix: Remove HTML from accounting menu tooltips in eldy theme (#37203)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Qual: Update spelling (#37199)

* Qual: Update spelling for pre-select variants

# Qual: Update spelling for pre-select variants

In English, preselect is without the hyphen.  Update text and made some translations
related to preselect.

* Qual: Update composant to component and/or adequate translation.

# Qual: Update composant to component and/or adequate translation.

"Composant(s)" was mostly referenced in french file/class comments.
Updated

* Qual: Fix misspellings related to "criteria"

# Qual: Fix misspellings related to "criteria"

* Qual: Fix produt misspellings

# Qual: Fix produt misspellings

Change 'produt' to 'product'.

* Qual: Update French comments with "composants"

#Qual: Update French comments with "composants"

- Translating French comments to English (avoid codespell notice)

* Qual: Fixed typo 'bad practive' to 'bad practice'

# Qual: Fixed typo 'bad practive' to 'bad practice'

* Qual: Update phan.yml to exclude specific files from analysis

- Added file exclusion pattern to match phan configuration
- Added check for empty file list to avoid unnecessary phan execution

* Qual: Update file filtering in phan.yml workflow

The change updates the file filtering process in the phan.yml workflow to correctly redirect the output of the grep command to a temporary file.

* Qual: Ignore $systemfunction always exists

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Error handling methods for commonobject (#37201)

* Error handling methods for commonobject (#37201)

* NEW Can request and force user to change its password (#37196)

* force user to change password : redirect to user card on login

* force user to change password : redirect to user card on login

* redirect to a dedicated page

* bad old idea : self change passwd on user card + edit mode and rights: it makes a hole on security check

* only apply on dolibarr auth mode context

* only on dolibarr auth mode context

* Fix force_pass_change SQL assignment logic

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Doc

* Setup easier to understand between INVOICE_CHECK_POSTERIOR_DATE and
FAC_FORCE_DATE_VALIDATION

* Setup easier to understand between INVOICE_CHECK_POSTERIOR_DATE and
FAC_FORCE_DATE_VALIDATION

* Prepare 23.0

* Qual: Ignore exit code from `grep -v` in phan flow (#37213)

# Qual: Ignore exit code from `grep -v` in phan flow

`grep -v` returns 1 when the resulting filtered list is empty and would stop the execution.
This is fixed with `|| true` to have a final exit code that is 0.

* WIP LNE

* Debug v23

* Debug v23

* WIP LNE

* FIX Bad header name

* Fix CSP for ping

* Compatibility with multicompany

* Debug

* Fix include

* Transfert feedback css from experimental to core

* Dolibarr JS context Tools from experiemntal to Core

* Fix lang public mode

* fix php phan

* Fix phan

* Fix phan

* Fix phan

* Fix phan

* Fix phan

* Fix phan

* Fix phan

* Fix phan

* Fix phan

* Fix phan

* Fix phan

* Fix multi instance of Dolibarr on same Domain

* remove french comment

* FIX phpdoc on createFixedAmountDiscount() (#37212)

* FIX phpdoc on createFixedAmountDiscount

* FIX phpdoc

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Fix path

* Fix in card css modal display (#36569)

* Fix display of cards in a modal

* fix php stan

* fix php stan

* Try a change to force CI

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* More complete data on pings.

* Debug v23

* Debug initdemo

* Debug initdemo

* Debug initdemo

* Debug v23

* Update initdemo

* Update initdemo

* Cleaner GET call

* Add id of perm in url

* Init demo for v24

* Fix translation of "various payment" (not english, not pro) with the
term used in english to mean "Opérations diverses (OD)"

* Sync transifex

* CSS

* Trans

* Doc

* Trans

* Debug v23

* Debug v23

* Trans

* Debug v24

* Debug v23

* Debug v23

* WIP

* Debug v23

* Debug v23

* Debug v24

* Work on LNE

* WIP LNE

* Debug v24

* Doc

* Translation

* Sync transifex

* Debug

* Debug

* Debug

* Responsive

* Dev control archive integrity

* Debug

* Update supplier_proposal.lang (#37238)

* add company name on dropdown contract list (#37245)

* Clean dump file

* Fix CI

* FIX #37246 Modifying resteapayer calculation for credit note (#37247)

* Add 'type' parameter to completeTabsHead hook (#37235)

* #37257 FIX for piesemicircle (#37258)

* Fix #37227 Fix #37233

* Fix #37227 Fix #37233

* QUAL French comment in English (#37225)

* Edit label of $fields

* QUAL French comment in English

* Bump actions/upload-artifact from 4 to 6 (#37250)

Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4 to 6.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v4...v6)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* UI/UX : Transfert feedback css from experimental to core (#37226)

* Transfert feedback css from experimental to core

* fix php phan

* Fix phan

* Fix phan

* Fix phan

* Missing label

* Debug

* Debug savedemo

* Fix mention

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
Co-authored-by: Lucas Marcouiller <45882981+Hystepik@users.noreply.github.com>
Co-authored-by: Lucas Marcouiller <lmarcouiller@dolicloud.com>
Co-authored-by: Laurent Destailleur <eldy@users.sourceforge.net>
Co-authored-by: Yamil Esteban Garcia <120027058+developmentOYR@users.noreply.github.com>
Co-authored-by: Noé Cendrier <81741011+altairis-noe@users.noreply.github.com>
Co-authored-by: Frédéric FRANCE <frederic34@users.noreply.github.com>
Co-authored-by: minimexat <minimexat@gmail.com>
Co-authored-by: hansemschnokeloch <hansemschnokeloch@users.noreply.github.com>
Co-authored-by: Eric - CAP-REL <1468823+rycks@users.noreply.github.com>
Co-authored-by: MDW <mdeweerd@users.noreply.github.com>
Co-authored-by: Alexandre SPANGARO <alexandre.spangaro@gmail.com>
Co-authored-by: evarisk-kilyan <kilyan.evarisk@gmail.com>
Co-authored-by: Vanyo <vanyolai@gmail.com>
Co-authored-by: jeremydassaud <49372108+jeremydassaud@users.noreply.github.com>
Co-authored-by: f-hoedl <hoefla14@htl-kaindorf.ac.at>
Co-authored-by: Vincent Maury <artec.vm@arnac.net>
Co-authored-by: vmaury <vmaury@vmaury-Lafite-Pro-16-AMD>
Co-authored-by: Vincent Penel <vincent.penel@atm-consulting.fr>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Dolibot <dolibarr-bot@users.noreply.github.com>
Co-authored-by: Joris Le Blansch <jleblansch@gmail.com>
Co-authored-by: intelliking <tyleradams93226@gmail.com>
Co-authored-by: Benjamin Falière <121813548+BenjaminFlr@users.noreply.github.com>
Co-authored-by: Charlène Benke <1179011+defrance@users.noreply.github.com>
Co-authored-by: demiton <fabien.cisse@gmail.com>
Co-authored-by: Jyhere <jyhere@gmail.com>
Co-authored-by: Delthair <41671350+Delthair@users.noreply.github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-23 20:11:39 +01:00
Lucky
6041233c4b Fix_massaction_withdraw_control (#37237)
* CI

* CI

* CI

* CI

* Clean code. File not used.

* CSS

* CSS

* Fix phpunit

* More legal info

* CI

* Fix CI

* Fix: IRPF tax not applied when creating invoice from project times (#37077)

* Remove 'supplier_invoice' from old path array

* Update module path in arrayforoldpath

Sorry Eldy, I was confused. You are absolutely right, it is already corrected.

* Replace localtax2 assignment with get_localtax function


Error when creating an invoice with personal income tax from project times. The rate does not apply

* Refactor localtax1 calculation using get_localtax

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Fix: IRPF tax not applied when creating invoice from project times (#37077)

* Remove 'supplier_invoice' from old path array

* Update module path in arrayforoldpath

Sorry Eldy, I was confused. You are absolutely right, it is already corrected.

* Replace localtax2 assignment with get_localtax function


Error when creating an invoice with personal income tax from project times. The rate does not apply

* Refactor localtax1 calculation using get_localtax

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Protect module

* Add currency

* CSS

* WIP LNE

* Fix navigation

* cs

* Debug registration process

* Debug setup navigation

* CI

* CI

* Factorize code

* Fix CI

* Fix CI

* Fix CI

* CI

* CI

* CI

* CI

* Disable phan on v23

* CI

* CI

* FIX: missing include for blockedlog lib (#37165)

* Debug CI

* fix ternary always true (#37161)

* fix ternary always true

* Update requests.php

* Update registration.php

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* CI

* FIX: missing include for blockedlog lib (#37165)

* FIX #37134 Use json_encode for IMAP search logging in EmailCollector (#37135)

var_export() produces multiline output that breaks log aggregators
(Loki, Splunk, Elasticsearch) as each line becomes a separate log entry.

Using json_encode() produces single-line structured output that works
correctly with all log aggregation tools.

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Populate syslog with placeholder (#37163)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Doc

* datamodel for user change password next time (#37155)

* Qual: Update phan baseline (#37172)

* Fix typo in file path (#37160)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Fix phpunit

* Complete call to setStatus so we have a trigy as 4th parameter (help to
fix the #37129)

* FIX Product - Warning on admin (#37157)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* FIX Product - Warning on admin + CSS (#37158)

* FIX Product - Warning on admin

* CSS

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* CI

* CI

* CI

* Avoid error if include fails

* More functions in blacklist (even if nw we use the whitelist by default)

* #37166 [SQL] add: email template for ticket admin creation (#37182)

* Replace var_export with new function formatLogObject (#37178)

* FIX BOM - Class product missing, column offset and information recording (form/input overlap) in admin (#37177)

* FIX BOM - Class product missing in admin

* Fix column offset and information recording (form/input overlap)

* ci

* ci

* FIX Intracommreport - Warning & link problem on tab (#37176)

* FIX Bank transfer admin - Warning & save 0 on constant PAYMENTBYBANKTRANSFER_ADDDAYS (#37175)

* Look and feel v24

* Update default time handling in index.php (#37150)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Fix file path comment in supplier invoice module (#37133)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Fix file path comment in supplier invoice module (#37133)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Fix CI

* Add template in migration

* fix phpdoc comment (#37184)

* fix phpdoc comment

* fix phpdoc comment

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* CI

* Fix phpstan

* Replace var_export by formatLogObject (continued) (#37188)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Debug amount suggested on membership public form

* Issue 36923 Fix session title handling in survey creation (#37105)

* Issue 36923 Fix session title handling in survey creation

* Change input field to use id attribute for title

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* fix phpstan errors blocking action baseline (#37189)

* fix phpstan errors blocking action baseline

* fix phpstan errors blocking action baseline

* fix phpstan errors blocking action baseline

* fix phpstan errors blocking action baseline

* fix phpstan errors blocking action baseline

* refresh baseline

* QUAL Replace var_export() with json_encode() in dol_syslog() calls (#37138)

var_export() produces multiline output that breaks log aggregators
(Loki, Splunk, Elasticsearch, Graylog) as each line becomes a separate
log entry.

json_encode() produces single-line structured output that works correctly
with all log aggregation tools. This pattern is already used elsewhere
in Dolibarr (accountancy, install modules).

Files changed:
- core/class/commoninvoice.class.php (payment intent logging)
- core/class/commonobject.class.php (payment terms logging)
- core/modules/mailings/advthirdparties.modules.php (mailing targets)
- core/modules/oauth/google_oauthcallback.php (userinfo logging)
- core/modules/oauth/generic_oauthcallback.php (userinfo logging)
- public/payment/newpayment.php (GET/POST debug logging)
- public/payment/paymentok.php (payment tag logging)
- public/stripe/ipn.php (Stripe event data logging)
- paypal/lib/paypal.lib.php (PayPal response logging)
- api/index.php (API debug logging)
- stripe/class/stripe.class.php (payment/setup intent logging)

Co-authored-by: f-hoedl <hoefla14@htl-kaindorf.ac.at>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Fix CI

* CI

* Check if upload_max_filesize is not empty

* clean code

* Debug v23

* CI

* Fix #33521 VAT total false (#36990)

* - Fix #33521 VAT total false
- Fix some warnings
- Fix : delete $this->vat_rate

* - Fix #33521 VAT total false
- Fix some warnings
- Fix  :delete $this->tva array (replaced by $this->tva_array)

* - Fix #33521 VAT total false
- Fix some warnings
- Fix  :delete $this->tva array (replaced by $this->tva_array)

* Update pdf_octopus.modules.php

* Update pdf_octopus.modules.php

* Update pdf_octopus.modules.php

* Update pdf_octopus.modules.php

* Update pdf_octopus.modules.php

---------

Co-authored-by: vmaury <vmaury@vmaury-Lafite-Pro-16-AMD>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* NEW #25829 Automatically send the invoice generated from a template (#36967)

* Update DB

* ADD email template

* Ajout d'une clé de trad

* Ajout des traductions

* Suppression des traductions, sauf en_US

* Add flag auto send

* Modif form + cron auto send

* Suppression auto_send

* correction loopError

* ajout du selected au model de mail

* Prise en compte default model

* Fix pre-commit

* ménage

* precommit

* Correction Phan

* Correction Phan

* Correction, double cal du trigger

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Develop force user change pass userclass (#37174)

* datamodel for user change password next time

* add force_pass_change in user object

* Initialize force_pass_change to 0

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Another step for #37171

* Qual: Partial phan run on PR's, complete run on integration branches (#37186)

* Qual: Partial phan run on PR's, complete on main

# Qual: Partial phan run on PR's, complete on main

The selection is based on the branch name.
To run a complete phan run in a PR, the branch name of the PR must include phan_full.
This can help to fix remaining phan issue before re-integrating to the develop branch.

* qual: Update workflow and pre-commit configurations

- Enable phan workflow by uncommenting the relevant lines
- Update actionlint version to v1.7.10
- Add manual stage to actionlint hook in pre-commit-config.yaml

* qual: Update Phan analysis conditions

The conditions for running Phan analysis have been updated to include an additional check for branches containing 'phan_full'.

* qual: Update Phan workflow

- Replace github.event.ref with github.ref_name
- Add FILE_CHANGE_LIST environment variable for better file handling
- Update file list creation and usage in the workflow

* qual: Update Phan workflow conditions

Fix the branch reference (head_ref in PR, ref_name otherwise)

* Add step for debug information

* Remove debug step

* Fix: Missing initialisations members/new.php

Following a suppression of assignments, the variables disabledphy and disabledmor were undefined.

* fix: Update budget selection dropdown arguments in member creation form

Correct the arguments in the member creation form.

* qual: Add cs2pr to phan workflow

- Add cs2pr to the tools list in the phan workflow
- Change the output mode of phan to checkstyle
- Add a step to add results to PR as Github notices
- Add a step to provide phan log as artifact

* qual: Update Phan workflow to use environment variable for file list

The change fixes the Phan workflow to use the environment variable `$FILE_CHANGED_LIST` to clear the file

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Fix phan

* Fix phan

* Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into 23.0

* Doc

* Qual: Fix ambigious redirect error on Phan workflow (#37200)

# Qual: Fix ambigious redirect error on Phan workflow

Rewrote the shell command that is supposed to suppress a file contents
but is flagged by the environment.

* PHPStan > Update baseline (#37197)

Co-authored-by: Dolibot <dolibarr-bot@users.noreply.github.com>

* Typo fix (#37195)

* Debug v23 - filters on agenda pages

* css

* css

* css

* qual: Update PHPStan workflow to run on all files in integration (#37207)

The PHPStan workflow has been updated to run on all files in integration branches.

* Fix CI

* Add hook in isEditable()

* Debug v23

* CLOSE #37190 ODT Templates for thirdparties - Birthday is returned in epoch format (#37198)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* fix: Remove HTML from accounting menu tooltips in eldy theme (#37203)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Qual: Update spelling (#37199)

* Qual: Update spelling for pre-select variants

# Qual: Update spelling for pre-select variants

In English, preselect is without the hyphen.  Update text and made some translations
related to preselect.

* Qual: Update composant to component and/or adequate translation.

# Qual: Update composant to component and/or adequate translation.

"Composant(s)" was mostly referenced in french file/class comments.
Updated

* Qual: Fix misspellings related to "criteria"

# Qual: Fix misspellings related to "criteria"

* Qual: Fix produt misspellings

# Qual: Fix produt misspellings

Change 'produt' to 'product'.

* Qual: Update French comments with "composants"

#Qual: Update French comments with "composants"

- Translating French comments to English (avoid codespell notice)

* Qual: Fixed typo 'bad practive' to 'bad practice'

# Qual: Fixed typo 'bad practive' to 'bad practice'

* Qual: Update phan.yml to exclude specific files from analysis

- Added file exclusion pattern to match phan configuration
- Added check for empty file list to avoid unnecessary phan execution

* Qual: Update file filtering in phan.yml workflow

The change updates the file filtering process in the phan.yml workflow to correctly redirect the output of the grep command to a temporary file.

* Qual: Ignore $systemfunction always exists

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Error handling methods for commonobject (#37201)

* Error handling methods for commonobject (#37201)

* NEW Can request and force user to change its password (#37196)

* force user to change password : redirect to user card on login

* force user to change password : redirect to user card on login

* redirect to a dedicated page

* bad old idea : self change passwd on user card + edit mode and rights: it makes a hole on security check

* only apply on dolibarr auth mode context

* only on dolibarr auth mode context

* Fix force_pass_change SQL assignment logic

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Doc

* Setup easier to understand between INVOICE_CHECK_POSTERIOR_DATE and
FAC_FORCE_DATE_VALIDATION

* Setup easier to understand between INVOICE_CHECK_POSTERIOR_DATE and
FAC_FORCE_DATE_VALIDATION

* Prepare 23.0

* Qual: Ignore exit code from `grep -v` in phan flow (#37213)

# Qual: Ignore exit code from `grep -v` in phan flow

`grep -v` returns 1 when the resulting filtered list is empty and would stop the execution.
This is fixed with `|| true` to have a final exit code that is 0.

* WIP LNE

* Debug v23

* Debug v23

* WIP LNE

* FIX Bad header name

* Fix CSP for ping

* Compatibility with multicompany

* Debug

* Fix include

* Fix_massaction_withdraw_control

Include pending transfer receipt amounts in bank transfer request validation

This code ensures that when creating a new bank transfer request for a supplier invoice, the system also checks for amounts that are already in generated but unprocessed transfer receipts.

Summary:
The second query ($sqlPending2) retrieves pending amounts from the prelevement_lignes table where the transfer receipt has been created but not yet executed (status = 0 or NULL).

This prevents users from requesting a bank transfer that would exceed the invoice total by accounting for:

Pending requests not yet included in any transfer receipt
Amounts already included in transfer receipts waiting to be processed

* FIX phpdoc on createFixedAmountDiscount() (#37212)

* FIX phpdoc on createFixedAmountDiscount

* FIX phpdoc

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* Fix in card css modal display (#36569)

* Fix display of cards in a modal

* fix php stan

* fix php stan

* Try a change to force CI

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* More complete data on pings.

* Debug v23

* Debug initdemo

* Debug initdemo

* Debug initdemo

* Debug v23

* Update initdemo

* Update initdemo

* Cleaner GET call

* Add id of perm in url

* Init demo for v24

* Fix translation of "various payment" (not english, not pro) with the
term used in english to mean "Opérations diverses (OD)"

* Sync transifex

* CSS

* Trans

* Doc

* Trans

* Debug v23

* Debug v23

* Trans

* Debug v24

* Debug v23

* Debug v23

* WIP

* Debug v23

* Debug v23

* Debug v24

* Work on LNE

* WIP LNE

* Debug v24

* Doc

* Translation

* Sync transifex

* Debug

* Debug

* Debug

* Responsive

* Dev control archive integrity

* Debug

* Update supplier_proposal.lang (#37238)

* add company name on dropdown contract list (#37245)

* Clean dump file

* Fix CI

* FIX #37246 Modifying resteapayer calculation for credit note (#37247)

* Add 'type' parameter to completeTabsHead hook (#37235)

* #37257 FIX for piesemicircle (#37258)

* Fix #37227 Fix #37233

* Fix #37227 Fix #37233

* QUAL French comment in English (#37225)

* Edit label of $fields

* QUAL French comment in English

* Bump actions/upload-artifact from 4 to 6 (#37250)

Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4 to 6.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v4...v6)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* UI/UX : Transfert feedback css from experimental to core (#37226)

* Transfert feedback css from experimental to core

* fix php phan

* Fix phan

* Fix phan

* Fix phan

* Missing label

* Debug

* traduction for massaction withdrawal control

* Add method to chech if invoice can be replaced

* Fix return

* Debug v24

* Fix CI

* fix commoninvoice.class.php (#37267)

* fix commoninvoice.class.php

* Update commoninvoice.class.php

* CI

* CI

* Debug v23

* CI

* Fix CI

* Debug v23

* clean code pdf.lib.php (#37265)

* clean code pdf.lib.php

* Update pdf.lib.php

* Update pdf.lib.php

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* FixCI

* FIX: linktoref should be able to receive more than 255 chars (#37262)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* NEW Increase satement decription to 12 on card payment, 22 on sepa

* CI

* Restore deleted file

* Add $dolibarr_main_restrict_eval_methods to install step1.php (#37268)

Since this variable has a significant impact in future versions of Dolibarr, it is preferable that it be directly included in the conf.php file created during installation.

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
Co-authored-by: Laurent Destailleur <eldy@users.sourceforge.net>
Co-authored-by: Yamil Esteban Garcia <120027058+developmentOYR@users.noreply.github.com>
Co-authored-by: Noé Cendrier <81741011+altairis-noe@users.noreply.github.com>
Co-authored-by: Frédéric FRANCE <frederic34@users.noreply.github.com>
Co-authored-by: minimexat <minimexat@gmail.com>
Co-authored-by: hansemschnokeloch <hansemschnokeloch@users.noreply.github.com>
Co-authored-by: Eric - CAP-REL <1468823+rycks@users.noreply.github.com>
Co-authored-by: MDW <mdeweerd@users.noreply.github.com>
Co-authored-by: Alexandre SPANGARO <alexandre.spangaro@gmail.com>
Co-authored-by: evarisk-kilyan <kilyan.evarisk@gmail.com>
Co-authored-by: Vanyo <vanyolai@gmail.com>
Co-authored-by: jeremydassaud <49372108+jeremydassaud@users.noreply.github.com>
Co-authored-by: f-hoedl <hoefla14@htl-kaindorf.ac.at>
Co-authored-by: Vincent Maury <artec.vm@arnac.net>
Co-authored-by: vmaury <vmaury@vmaury-Lafite-Pro-16-AMD>
Co-authored-by: Vincent Penel <vincent.penel@atm-consulting.fr>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Dolibot <dolibarr-bot@users.noreply.github.com>
Co-authored-by: Joris Le Blansch <jleblansch@gmail.com>
Co-authored-by: intelliking <tyleradams93226@gmail.com>
Co-authored-by: Benjamin Falière <121813548+BenjaminFlr@users.noreply.github.com>
Co-authored-by: John BOTELLA <68917336+thersane-john@users.noreply.github.com>
Co-authored-by: Charlène Benke <1179011+defrance@users.noreply.github.com>
Co-authored-by: demiton <fabien.cisse@gmail.com>
Co-authored-by: Jyhere <jyhere@gmail.com>
Co-authored-by: Delthair <41671350+Delthair@users.noreply.github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-23 20:09:42 +01:00
splohmer
f919a83721 FIX upload of files with multiple spaces via drag'n'drop flow (#37271)
* Debug savedemo

* Fix mention

* FIX upload of files with multiple spaces via drag'n'drop flow

Currently there are two ways to upload files to products, orders, etc. via the "old" way and the document tab and the "new" flow via drag'n'drop on the main tab of the object.

Both ways triggering completely different code paths. In the end the new way uses dol_sanitzieFileName to sanitize the name of the file and the old way uses dol_string_nohtmltag (both from functions.lib.php).

One of the main difference between the two mentioned functions is that in the old way multiple spaces behind each other are replaced by a single space. E.g. "A␠␠B␠␠␠C␠␠D" is tranformed to "A␠B␠C␠D".

This is needed to make sure that the files are properly uploaded and can be later also downloaded correctly.

How to reproduce?
Upload a file like "test␠␠test.txt" via the drag'n'drop flow and try to download it from the document tab. This is not working. You can see the file but cannot download it. The same flow via the input field of the document tab is working correctly.

* typo in comment

* FIX Phan warnings (unrelated to feature)

* FIX Phan warnings (unrelated to feature)

* FIX Phan warnings (unrelated to feature)

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-23 20:08:30 +01:00
William Mead
c8111f9726 QUAL updated projects API PHPDoc (#37275)
* Debug savedemo

* Fix mention

* Fix pdf font for CZ

* Added project API class and methods since tag

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-23 20:07:15 +01:00
minimexat
472665c038 fix(adherents): show cotisation create form for members with existing subscriptions (#37312)
Co-authored-by: f-hoedl <hoefla14@htl-kaindorf.ac.at>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-23 20:05:26 +01:00
Laurent Destailleur
06e67ee3da Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-23 12:23:34 +01:00
William Mead
f15efe2ca8 Added data pagination for index method (#37302)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-23 01:47:39 +01:00
Erwan-Wiwit
08feb72c6c Add hook stripeWebhookEvent in Stripe IPN for external modules (#37293)
* Add hook stripeWebhookEvent in Stripe IPN for external modules

Allow external modules to intercept and handle Stripe webhook events
via the standard Dolibarr hook system. The hook is called before the
built-in event processing, and modules can return >0 to stop default
processing if they handled the event entirely.

Hook context: stripeipn
Hook method: stripeWebhookEvent
Parameters: event (full Stripe event), servicestatus, service

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* Fix phpstan: instantiate HookManager before use in ipn.php

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-23 01:43:25 +01:00
minimexat
dd3709be29 fix: use ob_end_clean() instead of ob_end_flush() in readfileLowMemory() (#37298)
* fix: use ob_end_clean() instead of ob_end_flush() in readfileLowMemory() (fixes #37239)

* fix: use robust ob level cleanup loop per hregis review

---------

Co-authored-by: f-hoedl <hoefla14@htl-kaindorf.ac.at>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-23 01:36:32 +01:00
Laurent Destailleur
dad5f55081 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-23 01:31:13 +01:00
Laurent Destailleur
717f315551 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-23 01:30:54 +01:00
Lucas Marcouiller
be46c48f55 fix some technical debt (#37296)
* fix some technical debt

* fix CI

---------

Co-authored-by: Lucas Marcouiller <lmarcouiller@dolicloud.com>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-23 01:17:17 +01:00
minimexat
79c6f82841 fix: add class existence check after failed include in barcode.php (#37297)
* fix: add class existence check after failed include in barcode.php (fixes #37249)

* fix: move continue into catch block per reviewer feedback

* fix: add continue in catch block per hregis review

* fix: replace invalid continue with $error++ in printsheet.php catch block

---------

Co-authored-by: f-hoedl <hoefla14@htl-kaindorf.ac.at>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-23 01:15:29 +01:00
William Mead
ff7e2c4292 Updated PHPDoc with since tag (#37300)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-23 01:03:57 +01:00
Laurent Destailleur
7de8680a37 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-23 00:58:50 +01:00
Laurent Destailleur
cbdeebd338 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-23 00:57:52 +01:00
Laurent Destailleur
e31e6371e3 CI 2026-02-23 00:55:32 +01:00
MDW
095f72a3a7 Qual: Update pre-commit hooks and dependencies (#37313)
Updated the following pre-commit hooks and dependencies:
- gitleaks: v8.29.0 -> v8.30.0
- actionlint: v1.7.10 -> v1.7.11
- yamllint: v1.37.1 -> v1.38.0
- sqlfluff: 3.3.1 -> 4.0.4
- Added LT15 to exclude_rules in pyproject.toml (new since 3.3.1)

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-23 00:41:04 +01:00
William Mead
9560eb00bd Updated PHPDoc with since tag (#37299)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-23 00:40:39 +01:00
minimexat
e52c212a81 fix(expedition): add 'shipping' as valid modulepart alias in dol_check_secure_access_document (#37307)
Co-authored-by: f-hoedl <hoefla14@htl-kaindorf.ac.at>
2026-02-23 00:38:56 +01:00
MDW
1a8f540dc8 Fix: CI (#37320)
* Fix: http_response_code type

# Fix: http_response_code type

- Fixed http_response_code type

* Fix: Initialize refcashcontrol variable

Initialize refcashcontrol variable to 0 to ensure it is defined before use in the invoice.php script.

* Fix: Remove redundant check for BILL_SENTBYMAIL & $object type

# Fix: Remove redundant check for BILL_SENTBYMAIL & $object type

- Removed redundant check for BILL_SENTBYMAIL

* Fix: Correct date calculation for full year cash control

# Fix: Correct date calculation for full year cash control

Calculates the start date by subtracting one year from the end date.

* Qual: Add default batch value for invoice processing

# Qual: Add default batch value for invoice processing

Adds default empty string for the batch variable.

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-23 00:35:33 +01:00
Laurent Destailleur
de8f15ce38 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2026-02-23 00:11:16 +01:00
Laurent Destailleur
fe4648657e Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-22 23:53:46 +01:00
Laurent Destailleur
2d5b6ea490 CI 2026-02-22 23:53:27 +01:00
Charlène Benke
f810a89977 verify if Hierarchical Responsible is allowed to validate holiday/exp (#37315)
* verify if Hierarchical Responsible is allowed to validate holiday/expense

* Add messages for holiday and expense report approval

* Add French translations for approval messages
2026-02-22 23:41:35 +01:00
Laurent Destailleur
cea9183889 CI 2026-02-22 23:40:56 +01:00
Laurent Destailleur
3fa9d82ca5 Fix CI 2026-02-22 23:15:20 +01:00
Laurent Destailleur
95e941dd23 Trans 2026-02-22 17:33:26 +01:00
Laurent Destailleur
68385e59d0 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-22 17:16:20 +01:00
Laurent Destailleur
e3e15e5df1 Add option MAIN_JQUERY_JNOTIFY_UNDER_MENU to have notification under
menu (not a so good idea, under menu is blocking the use of navigation
buttons needing to wait more often the notif disappear).
2026-02-22 17:16:09 +01:00
Laurent Destailleur
0ca643dffb sync transifex 2026-02-22 17:09:40 +01:00
hansemschnokeloch
e728453b7a Log message additionnal info (#37215) 2026-02-22 01:22:08 +01:00
Laurent Destailleur
c73820a931 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-21 23:50:34 +01:00
Laurent Destailleur
2821d18720 Doc 2026-02-21 23:50:24 +01:00
Laurent Destailleur
0eeac1817d FIX fail2ban rules 2026-02-21 23:50:18 +01:00
evarisk-kilyan
3d2c20193f #37185 [Workflow] add: ticket workflow read ticket when assign someone (#37187)
* #37185 [Workflow] add: ticket workflow read ticket when assign someone

* #37185 [Workflow] remove: double quote

* #37185 [Ticket] fix: move conf to ticket conf

* #37185 [Ticket] fix: typo
2026-02-21 23:28:21 +01:00
Laurent Destailleur
cdbd56c0ba Clean code 2026-02-21 22:34:37 +01:00
Laurent Destailleur
bb8290ef23 Demo 2026-02-21 18:32:13 +01:00
Laurent Destailleur
7df18dbad8 Clean scripts 2026-02-21 12:28:45 +01:00
Laurent Destailleur
63ed00fdba Fix CI 2026-02-21 12:22:59 +01:00
Laurent Destailleur
ac8af31c51 Fix CI 2026-02-21 11:56:15 +01:00
Laurent Destailleur
7728f8c895 WIP LNE 2026-02-21 11:44:43 +01:00
Laurent Destailleur
acc5f754e6 Removed the header that was a copy past, but this file was authored by
one dev only
2026-02-21 10:28:13 +01:00
minimexat
9e3f3e70d6 fix(product): default empty/null price_base_type to HT instead of treating as TTC (#37309)
Co-authored-by: f-hoedl <hoefla14@htl-kaindorf.ac.at>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-21 06:51:59 +01:00
MDW
829ea724cd Qual: Update codespell skip pattern to exclude blockedlog demo archives files (#37306)
# Qual: Update codespell skip pattern to exclude blockedlog demo archives files

The skip pattern in the pyproject.toml file has been updated to exclude additional files, specifically those in the dev/initdemo/documents_demo/blockedlog/archives/ directory.
2026-02-21 06:48:47 +01:00
Laurent Destailleur
c1db001cd8 Doc 2026-02-20 20:09:13 +01:00
Laurent Destailleur
4f17908c59 WIP LNE 2026-02-20 19:21:34 +01:00
Laurent Destailleur
12f0351deb Reduce size of blockedlogs 2026-02-20 19:09:16 +01:00
Laurent Destailleur
8efce11329 Add pos_number in blockedlog 2026-02-20 18:51:38 +01:00
Laurent Destailleur
80d48a0d52 Debug 2026-02-20 16:58:00 +01:00
Laurent Destailleur
9a9784238c Debug 2026-02-20 16:50:53 +01:00
Laurent Destailleur
97dcd936df Add hooks 2026-02-20 13:29:30 +01:00
Laurent Destailleur
a2fb7eea1b Regression 2026-02-20 12:43:49 +01:00
Laurent Destailleur
38ca2ddefe Trans 2026-02-20 12:41:39 +01:00
Laurent Destailleur
a318ee912b Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-20 12:40:11 +01:00
Laurent Destailleur
b2fc785985 Label 2026-02-20 12:40:01 +01:00
Laurent Destailleur
e8a053f1df Add link 2026-02-20 12:33:28 +01:00
Laurent Destailleur
2c6a346811 Add info link to for credit note 2026-02-20 12:26:50 +01:00
Laurent Destailleur
89634f83da Add discount of line in invoice 2026-02-20 12:22:43 +01:00
Laurent Destailleur
d6b780eab3 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-20 11:37:28 +01:00
Laurent Destailleur
3c531d2058 Add remise_percent in unalterablelog 2026-02-20 11:37:13 +01:00
Laurent Destailleur
4fb2746e6f Debug 2026-02-20 01:02:58 +01:00
Laurent Destailleur
a4d5990c2e Add full version 2026-02-20 00:49:35 +01:00
Laurent Destailleur
4a212daf49 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2026-02-20 00:30:35 +01:00
Laurent Destailleur
9738ce853a WIP LNE 2026-02-20 00:27:56 +01:00
Laurent Destailleur
11d4fafca0 Version module 2026-02-19 22:29:20 +01:00
Laurent Destailleur
dec4b2b0a2 More complet command 2026-02-19 03:25:15 +01:00
Laurent Destailleur
0250d5de8a CI 2026-02-19 03:09:27 +01:00
Laurent Destailleur
e6cb968eff Debug use gmt in v2 lines 2026-02-19 03:04:53 +01:00
Laurent Destailleur
970b07f646 Doc 2026-02-19 01:16:29 +01:00
Laurent Destailleur
5bf181adf7 Test 2026-02-19 01:01:46 +01:00
Laurent Destailleur
5033716755 Move files 2026-02-18 23:56:08 +01:00
Laurent Destailleur
b0489d32ab Fix unexpected exit 2026-02-18 23:33:57 +01:00
Laurent Destailleur
35caafadb7 Debug v24 2026-02-18 23:03:16 +01:00
Laurent Destailleur
23da8b6934 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-18 03:34:33 +01:00
Laurent Destailleur
aac5629f55 Fix save/initdemo 2026-02-18 03:30:40 +01:00
Laurent Destailleur
9b7afdcbbd Doc 2026-02-18 03:20:12 +01:00
Laurent Destailleur
b986f2f1a7 Debug v24 2025-03-05 11:13:24 +01:00
Laurent Destailleur
74157e15d2 Debug 2025-03-05 10:17:10 +01:00
Laurent Destailleur
fb70814412 Debug v24 2025-02-05 15:36:32 +01:00
Laurent Destailleur
c295e97f9c Debug 2025-02-05 14:59:32 +01:00
Laurent Destailleur
8478c38477 Debug 2025-02-05 13:57:10 +01:00
Laurent Destailleur
f6db26a21d Trans 2025-02-05 13:14:56 +01:00
Laurent Destailleur
3b9f0d9ce6 Clean code 2025-02-05 13:13:34 +01:00
Laurent Destailleur
ca41760a68 Add example of blockedlog archive file 2025-02-05 13:00:48 +01:00
Laurent Destailleur
483523e24c CSS 2025-02-05 11:52:09 +01:00
Laurent Destailleur
935374d368 Debug v24 2025-02-05 11:47:52 +01:00
Laurent Destailleur
5ea91b5399 Add example of blockedlog archive file 2025-02-05 11:11:51 +01:00
Laurent Destailleur
e09180ce0c Debug 2025-02-05 09:39:21 +01:00
Laurent Destailleur
de56758859 Fix pdf font for CZ 2026-02-18 11:36:17 +01:00
Laurent Destailleur
cc6b3f968c Fix mention 2026-02-18 03:45:33 +01:00
Laurent Destailleur
70d711e083 Debug savedemo 2026-02-18 03:36:56 +01:00
Laurent Destailleur
10beb6cfc6 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2025-01-16 12:52:41 +01:00
Laurent Destailleur
f72245353f Debug send email for takepos 2025-01-16 12:52:03 +01:00
Laurent Destailleur
cc88462e1a Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2025-01-16 12:21:46 +01:00
Laurent Destailleur
22a1340ba9 Debug v23 2025-01-16 12:21:06 +01:00
Mohamed DAOUD
2faa32b9c8 fix iseditable hook (#37269)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-17 19:42:12 +01:00
Laurent Destailleur
1a3662176b Fix CI 2026-02-17 18:44:03 +01:00
Charlène Benke
177c5eb51f Add $dolibarr_main_restrict_eval_methods to install step1.php (#37268)
Since this variable has a significant impact in future versions of Dolibarr, it is preferable that it be directly included in the conf.php file created during installation.

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-17 18:22:53 +01:00
Laurent Destailleur
dff4b0077b Restore deleted file 2026-02-17 18:10:31 +01:00
Laurent Destailleur
f1c47cf536 CI 2026-02-17 18:06:56 +01:00
Laurent Destailleur
233865da21 NEW Increase satement decription to 12 on card payment, 22 on sepa 2026-02-17 18:05:44 +01:00
Laurent Destailleur
30e1fc6c9f Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-17 17:27:34 +01:00
Laurent Destailleur
de0832bcea Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2026-02-17 17:23:29 +01:00
Laurent Destailleur
6cf4969100 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-17 17:22:50 +01:00
Laurent Destailleur
bebc6fbb78 FixCI 2026-02-17 17:22:32 +01:00
Frédéric FRANCE
589fe1215a clean code pdf.lib.php (#37265)
* clean code pdf.lib.php

* Update pdf.lib.php

* Update pdf.lib.php

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-17 17:00:38 +01:00
Laurent Destailleur
cfedd3b485 Fix CI 2026-02-17 16:15:26 +01:00
Laurent Destailleur
d2a78ce515 CI 2026-02-17 16:02:55 +01:00
Laurent Destailleur
b1aefa13d7 CI 2026-02-17 15:36:58 +01:00
Laurent Destailleur
9d0a2c0978 CI 2026-02-17 15:33:38 +01:00
Laurent Destailleur
2328de8e7c Fix CI 2026-02-17 15:16:31 +01:00
Laurent Destailleur
c205803687 Debug v24 2026-02-17 15:01:38 +01:00
Laurent Destailleur
b595f8468d Fix return 2026-02-17 14:56:03 +01:00
Laurent Destailleur
9c837750a5 Add method to chech if invoice can be replaced 2026-02-17 14:53:26 +01:00
Laurent Destailleur
769b1935e3 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-17 02:51:46 +01:00
Laurent Destailleur
da3edf38ed Debug 2026-02-17 02:51:35 +01:00
Laurent Destailleur
8f0d1d4e25 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-16 21:57:24 +01:00
Laurent Destailleur
8dbdf910f9 Missing label 2026-02-16 21:54:48 +01:00
Laurent Destailleur
d0c80f3228 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-16 21:47:14 +01:00
John BOTELLA
22391f32dd UI/UX : Transfert feedback css from experimental to core (#37226)
* Transfert feedback css from experimental to core

* fix php phan

* Fix phan

* Fix phan

* Fix phan
2026-02-16 21:37:57 +01:00
dependabot[bot]
16542692d5 Bump actions/upload-artifact from 4 to 6 (#37250)
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4 to 6.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v4...v6)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-16 21:29:59 +01:00
Alexandre SPANGARO
fbc9934e62 QUAL French comment in English (#37225)
* Edit label of $fields

* QUAL French comment in English
2026-02-16 21:29:33 +01:00
Laurent Destailleur
125d97cf5d Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-16 21:23:48 +01:00
Delthair
a544af5d02 #37257 FIX for piesemicircle (#37258) 2026-02-16 20:29:44 +01:00
Jyhere
8fde66127c Add 'type' parameter to completeTabsHead hook (#37235) 2026-02-16 20:26:58 +01:00
demiton
45483a6fd9 FIX #37246 Modifying resteapayer calculation for credit note (#37247) 2026-02-16 20:26:20 +01:00
Laurent Destailleur
ecf01bacd7 Fix CI 2026-02-16 20:25:07 +01:00
Laurent Destailleur
d66612eb55 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-16 20:08:19 +01:00
Laurent Destailleur
cc9f0e5bcf Clean dump file 2026-02-16 20:08:06 +01:00
Charlène Benke
87fc31fa7c add company name on dropdown contract list (#37245) 2026-02-16 20:03:27 +01:00
Frédéric FRANCE
1a2813e13c Update supplier_proposal.lang (#37238) 2026-02-16 19:53:07 +01:00
Laurent Destailleur
904dbef1b2 Debug 2026-02-16 19:51:19 +01:00
Laurent Destailleur
db521258ea Dev control archive integrity 2026-02-16 15:57:00 +01:00
Laurent Destailleur
adc251a053 Responsive 2026-02-16 06:21:12 +01:00
Laurent Destailleur
a8675af65b Debug 2026-02-16 06:06:23 +01:00
Laurent Destailleur
66a9b7b7c3 Debug 2026-02-16 06:03:01 +01:00
Laurent Destailleur
7f06c6b326 Debug 2026-02-16 05:48:39 +01:00
Laurent Destailleur
f9b19c8336 Sync transifex 2026-02-16 05:45:10 +01:00
Laurent Destailleur
549fa27308 Translation 2026-02-16 05:41:19 +01:00
Laurent Destailleur
b31ff84b11 Doc 2026-02-16 05:26:30 +01:00
Laurent Destailleur
1dbf850bf1 Debug v24 2026-02-16 05:22:37 +01:00
Laurent Destailleur
bc9ce0c208 WIP LNE 2026-02-16 05:20:49 +01:00
Laurent Destailleur
4655321e82 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-16 04:04:45 +01:00
Laurent Destailleur
7328aeacf9 Work on LNE 2026-02-16 04:04:17 +01:00
Laurent Destailleur
1d8e24660c Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-16 03:23:02 +01:00
Laurent Destailleur
252811d116 Debug v24 2026-02-16 03:22:52 +01:00
Laurent Destailleur
dad0061495 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-16 02:04:12 +01:00
Laurent Destailleur
75a54088fc Debug v23 2026-02-16 02:03:38 +01:00
Laurent Destailleur
160f061326 WIP 2026-02-16 02:03:30 +01:00
Laurent Destailleur
51bd610f0c Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-16 01:21:44 +01:00
Laurent Destailleur
ebe7aacf54 Debug v24 2026-02-16 01:21:20 +01:00
Laurent Destailleur
03c3218a0c Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-16 01:06:12 +01:00
Laurent Destailleur
59a51cc3ed Trans 2026-02-16 01:05:45 +01:00
Laurent Destailleur
15b9cab91c Debug v23 2026-02-16 00:57:14 +01:00
Laurent Destailleur
7e8e7a24c3 Debug v23 2026-02-16 00:50:53 +01:00
Laurent Destailleur
414ea91137 Trans 2026-02-16 00:08:14 +01:00
Laurent Destailleur
0a172228f9 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-15 23:13:52 +01:00
Laurent Destailleur
f36f7c62a5 Doc 2026-02-15 23:13:45 +01:00
Laurent Destailleur
b5260fc0cc Trans 2026-02-15 23:13:19 +01:00
Laurent Destailleur
0dda1f9a3e Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-15 22:58:58 +01:00
Laurent Destailleur
055add5503 Sync transifex 2026-02-15 22:19:43 +01:00
Laurent Destailleur
2ec81d9a18 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-15 22:09:49 +01:00
Laurent Destailleur
0152770cfe Fix translation of "various payment" (not english, not pro) with the
term used in english to mean "Opérations diverses (OD)"
2026-02-15 22:09:29 +01:00
Laurent Destailleur
310cad4455 Init demo for v24 2026-02-15 21:25:58 +01:00
Laurent Destailleur
454f381e11 Update initdemo 2026-02-15 19:54:36 +01:00
Laurent Destailleur
717d769009 Debug v23 2026-02-15 19:52:53 +01:00
Laurent Destailleur
77b557e954 Debug initdemo 2026-02-15 17:57:58 +01:00
Laurent Destailleur
dd08c92f2a Debug initdemo 2026-02-15 17:52:26 +01:00
Laurent Destailleur
6bd194b3fa Merge branch 'develop' of github.com:Dolibarr/dolibarr into develop 2026-02-15 17:40:54 +01:00
Laurent Destailleur
061ebaf0b9 Debug initdemo 2026-02-15 17:40:43 +01:00
Laurent Destailleur
9529bd2f3a Debug v23 2026-02-15 17:26:05 +01:00
Laurent Destailleur
f5d90ef9c0 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-15 16:57:58 +01:00
Laurent Destailleur
6a6a24ee3c More complete data on pings. 2026-02-15 16:57:48 +01:00
John BOTELLA
b313d7c0fd Fix in card css modal display (#36569)
* Fix display of cards in a modal

* fix php stan

* fix php stan

* Try a change to force CI

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-14 14:51:33 +01:00
Benjamin Falière
793bfde2a6 FIX phpdoc on createFixedAmountDiscount() (#37212)
* FIX phpdoc on createFixedAmountDiscount

* FIX phpdoc

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-13 15:10:58 +01:00
Laurent Destailleur
4d319bc2e1 Fix include 2026-02-13 02:01:19 +01:00
Laurent Destailleur
8978367505 Debug 2026-02-13 01:22:06 +01:00
Laurent Destailleur
b416748451 Compatibility with multicompany 2026-02-13 01:05:25 +01:00
Laurent Destailleur
961989d149 Fix CSP for ping 2026-02-13 00:20:53 +01:00
Laurent Destailleur
0463e210d8 FIX Bad header name 2026-02-13 00:18:01 +01:00
Laurent Destailleur
e9b064b7f0 WIP LNE 2026-02-12 22:55:44 +01:00
Laurent Destailleur
efd79201dc Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-12 21:45:49 +01:00
Laurent Destailleur
3bc7eb5c59 Debug v23 2026-02-12 21:45:22 +01:00
Laurent Destailleur
f022de3ff2 WIP LNE 2026-02-12 21:43:54 +01:00
MDW
c47998522a Qual: Ignore exit code from grep -v in phan flow (#37213)
# Qual: Ignore exit code from `grep -v` in phan flow

`grep -v` returns 1 when the resulting filtered list is empty and would stop the execution.
This is fixed with `|| true` to have a final exit code that is 0.
2026-02-12 19:53:03 +01:00
Laurent Destailleur
56618e0c59 Merge branch '22.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-12 19:51:13 +01:00
Laurent Destailleur
e1c499bbe7 Setup easier to understand between INVOICE_CHECK_POSTERIOR_DATE and
FAC_FORCE_DATE_VALIDATION
2026-02-12 19:22:58 +01:00
Laurent Destailleur
0fdb91548f Setup easier to understand between INVOICE_CHECK_POSTERIOR_DATE and
FAC_FORCE_DATE_VALIDATION
2026-02-12 19:18:51 +01:00
Laurent Destailleur
c0911e55c8 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-12 18:57:51 +01:00
Laurent Destailleur
2f584530ce Doc 2026-02-12 18:04:16 +01:00
Eric - CAP-REL
7f38769d62 NEW Can request and force user to change its password (#37196)
* force user to change password : redirect to user card on login

* force user to change password : redirect to user card on login

* redirect to a dedicated page

* bad old idea : self change passwd on user card + edit mode and rights: it makes a hole on security check

* only apply on dolibarr auth mode context

* only on dolibarr auth mode context

* Fix force_pass_change SQL assignment logic

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-12 17:35:03 +01:00
hansemschnokeloch
6a9d4c5ca9 Error handling methods for commonobject (#37201) 2026-02-12 16:42:55 +01:00
MDW
f8e609b3b3 Qual: Update spelling (#37199)
* Qual: Update spelling for pre-select variants

# Qual: Update spelling for pre-select variants

In English, preselect is without the hyphen.  Update text and made some translations
related to preselect.

* Qual: Update composant to component and/or adequate translation.

# Qual: Update composant to component and/or adequate translation.

"Composant(s)" was mostly referenced in french file/class comments.
Updated

* Qual: Fix misspellings related to "criteria"

# Qual: Fix misspellings related to "criteria"

* Qual: Fix produt misspellings

# Qual: Fix produt misspellings

Change 'produt' to 'product'.

* Qual: Update French comments with "composants"

#Qual: Update French comments with "composants"

- Translating French comments to English (avoid codespell notice)

* Qual: Fixed typo 'bad practive' to 'bad practice'

# Qual: Fixed typo 'bad practive' to 'bad practice'

* Qual: Update phan.yml to exclude specific files from analysis

- Added file exclusion pattern to match phan configuration
- Added check for empty file list to avoid unnecessary phan execution

* Qual: Update file filtering in phan.yml workflow

The change updates the file filtering process in the phan.yml workflow to correctly redirect the output of the grep command to a temporary file.

* Qual: Ignore $systemfunction always exists

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-12 16:29:11 +01:00
intelliking
d5cc1d7754 fix: Remove HTML from accounting menu tooltips in eldy theme (#37203)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-12 16:28:05 +01:00
Joris Le Blansch
b1d60ec82b CLOSE #37190 ODT Templates for thirdparties - Birthday is returned in epoch format (#37198)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-12 16:27:30 +01:00
Laurent Destailleur
bada2c29df Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-12 15:19:27 +01:00
Laurent Destailleur
7b453994d8 Fix CI 2026-02-12 15:18:31 +01:00
MDW
8436004ce6 qual: Update PHPStan workflow to run on all files in integration (#37207)
The PHPStan workflow has been updated to run on all files in integration branches.
2026-02-12 15:14:03 +01:00
Laurent Destailleur
ed0b3a6f4d css 2026-02-12 01:40:00 +01:00
Laurent Destailleur
d092852768 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-12 00:39:28 +01:00
Laurent Destailleur
de948fad37 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-11 21:17:35 +01:00
Laurent Destailleur
b6f9a62a65 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-11 21:17:28 +01:00
hansemschnokeloch
09b69a178b Typo fix (#37195) 2026-02-11 21:15:41 +01:00
github-actions[bot]
e199ef7cae PHPStan > Update baseline (#37197)
Co-authored-by: Dolibot <dolibarr-bot@users.noreply.github.com>
2026-02-11 21:15:15 +01:00
MDW
358a4883c6 Qual: Fix ambigious redirect error on Phan workflow (#37200)
# Qual: Fix ambigious redirect error on Phan workflow

Rewrote the shell command that is supposed to suppress a file contents
but is flagged by the environment.
2026-02-11 21:13:08 +01:00
Laurent Destailleur
ff63da5fac Fix phan 2026-02-11 15:08:13 +01:00
Laurent Destailleur
bd65974d56 Fix phan 2026-02-11 15:07:19 +01:00
MDW
411a18ec9f Qual: Partial phan run on PR's, complete run on integration branches (#37186)
* Qual: Partial phan run on PR's, complete on main

# Qual: Partial phan run on PR's, complete on main

The selection is based on the branch name.
To run a complete phan run in a PR, the branch name of the PR must include phan_full.
This can help to fix remaining phan issue before re-integrating to the develop branch.

* qual: Update workflow and pre-commit configurations

- Enable phan workflow by uncommenting the relevant lines
- Update actionlint version to v1.7.10
- Add manual stage to actionlint hook in pre-commit-config.yaml

* qual: Update Phan analysis conditions

The conditions for running Phan analysis have been updated to include an additional check for branches containing 'phan_full'.

* qual: Update Phan workflow

- Replace github.event.ref with github.ref_name
- Add FILE_CHANGE_LIST environment variable for better file handling
- Update file list creation and usage in the workflow

* qual: Update Phan workflow conditions

Fix the branch reference (head_ref in PR, ref_name otherwise)

* Add step for debug information

* Remove debug step

* Fix: Missing initialisations members/new.php

Following a suppression of assignments, the variables disabledphy and disabledmor were undefined.

* fix: Update budget selection dropdown arguments in member creation form

Correct the arguments in the member creation form.

* qual: Add cs2pr to phan workflow

- Add cs2pr to the tools list in the phan workflow
- Change the output mode of phan to checkstyle
- Add a step to add results to PR as Github notices
- Add a step to provide phan log as artifact

* qual: Update Phan workflow to use environment variable for file list

The change fixes the Phan workflow to use the environment variable `$FILE_CHANGED_LIST` to clear the file

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-11 12:58:04 +01:00
Laurent Destailleur
00136cf9e3 Another step for #37171 2026-02-11 03:27:42 +01:00
Laurent Destailleur
67c9853cd2 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-11 03:24:06 +01:00
Eric - CAP-REL
4bf8b3097f Develop force user change pass userclass (#37174)
* datamodel for user change password next time

* add force_pass_change in user object

* Initialize force_pass_change to 0

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-11 03:20:54 +01:00
Laurent Destailleur
ca854a434e Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-11 03:18:04 +01:00
Vincent Penel
8a8a7f4e95 NEW #25829 Automatically send the invoice generated from a template (#36967)
* Update DB

* ADD email template

* Ajout d'une clé de trad

* Ajout des traductions

* Suppression des traductions, sauf en_US

* Add flag auto send

* Modif form + cron auto send

* Suppression auto_send

* correction loopError

* ajout du selected au model de mail

* Prise en compte default model

* Fix pre-commit

* ménage

* precommit

* Correction Phan

* Correction Phan

* Correction, double cal du trigger

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-11 03:14:18 +01:00
Vincent Maury
3623872851 Fix #33521 VAT total false (#36990)
* - Fix #33521 VAT total false
- Fix some warnings
- Fix : delete $this->vat_rate

* - Fix #33521 VAT total false
- Fix some warnings
- Fix  :delete $this->tva array (replaced by $this->tva_array)

* - Fix #33521 VAT total false
- Fix some warnings
- Fix  :delete $this->tva array (replaced by $this->tva_array)

* Update pdf_octopus.modules.php

* Update pdf_octopus.modules.php

* Update pdf_octopus.modules.php

* Update pdf_octopus.modules.php

* Update pdf_octopus.modules.php

---------

Co-authored-by: vmaury <vmaury@vmaury-Lafite-Pro-16-AMD>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-11 03:07:58 +01:00
Laurent Destailleur
55c33edeec Check if upload_max_filesize is not empty 2026-02-11 02:16:24 +01:00
Laurent Destailleur
602bcc5361 CI 2026-02-11 02:03:45 +01:00
Laurent Destailleur
b699b3f9b9 Fix CI 2026-02-11 01:55:09 +01:00
minimexat
92562150ec QUAL Replace var_export() with json_encode() in dol_syslog() calls (#37138)
var_export() produces multiline output that breaks log aggregators
(Loki, Splunk, Elasticsearch, Graylog) as each line becomes a separate
log entry.

json_encode() produces single-line structured output that works correctly
with all log aggregation tools. This pattern is already used elsewhere
in Dolibarr (accountancy, install modules).

Files changed:
- core/class/commoninvoice.class.php (payment intent logging)
- core/class/commonobject.class.php (payment terms logging)
- core/modules/mailings/advthirdparties.modules.php (mailing targets)
- core/modules/oauth/google_oauthcallback.php (userinfo logging)
- core/modules/oauth/generic_oauthcallback.php (userinfo logging)
- public/payment/newpayment.php (GET/POST debug logging)
- public/payment/paymentok.php (payment tag logging)
- public/stripe/ipn.php (Stripe event data logging)
- paypal/lib/paypal.lib.php (PayPal response logging)
- api/index.php (API debug logging)
- stripe/class/stripe.class.php (payment/setup intent logging)

Co-authored-by: f-hoedl <hoefla14@htl-kaindorf.ac.at>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-11 01:44:21 +01:00
Frédéric FRANCE
9ac93e1e98 fix phpstan errors blocking action baseline (#37189)
* fix phpstan errors blocking action baseline

* fix phpstan errors blocking action baseline

* fix phpstan errors blocking action baseline

* fix phpstan errors blocking action baseline

* fix phpstan errors blocking action baseline

* refresh baseline
2026-02-11 00:52:15 +01:00
jeremydassaud
8a52b78f3d Issue 36923 Fix session title handling in survey creation (#37105)
* Issue 36923 Fix session title handling in survey creation

* Change input field to use id attribute for title

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-11 00:51:17 +01:00
Laurent Destailleur
89698730d0 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-10 20:37:09 +01:00
Laurent Destailleur
9f9ca3faf7 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-10 20:36:42 +01:00
hansemschnokeloch
019e17c040 Replace var_export by formatLogObject (continued) (#37188)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-10 16:54:51 +01:00
Laurent Destailleur
448bd21195 Fix phpstan 2026-02-10 16:09:20 +01:00
Laurent Destailleur
9d14dd25c4 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-10 16:00:31 +01:00
Laurent Destailleur
b6f714fe44 CI 2026-02-10 15:59:57 +01:00
Frédéric FRANCE
89d15ac306 fix phpdoc comment (#37184)
* fix phpdoc comment

* fix phpdoc comment

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-10 15:50:34 +01:00
Laurent Destailleur
52de478d6a Add template in migration 2026-02-10 15:49:23 +01:00
Laurent Destailleur
7601198799 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-10 15:46:40 +01:00
Laurent Destailleur
830fdbdaca Fix CI 2026-02-10 15:46:28 +01:00
hansemschnokeloch
23780ad765 Fix file path comment in supplier invoice module (#37133)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-10 15:31:51 +01:00
Vanyo
72a2510b46 Update default time handling in index.php (#37150)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-10 15:31:24 +01:00
Laurent Destailleur
1774bca857 Look and feel v24 2026-02-10 15:26:36 +01:00
Laurent Destailleur
8150d06abe Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-10 15:10:25 +01:00
Laurent Destailleur
7715579d71 ci 2026-02-10 15:10:11 +01:00
Laurent Destailleur
db7a02f33d ci 2026-02-10 15:09:12 +01:00
hansemschnokeloch
16cec77d5b Replace var_export with new function formatLogObject (#37178) 2026-02-10 15:01:34 +01:00
evarisk-kilyan
0341d1b961 #37166 [SQL] add: email template for ticket admin creation (#37182) 2026-02-10 15:00:50 +01:00
Laurent Destailleur
0cda79c2d9 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-10 14:42:14 +01:00
Laurent Destailleur
8f32564580 Avoid error if include fails 2026-02-10 13:56:04 +01:00
Laurent Destailleur
249feb265f CI 2026-02-10 01:32:04 +01:00
Laurent Destailleur
9b7fb5e28f CI 2026-02-10 01:26:08 +01:00
Laurent Destailleur
6d26cec36c CI 2026-02-10 00:50:53 +01:00
Laurent Destailleur
fb39d0973d Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-10 00:45:31 +01:00
Laurent Destailleur
36108255e3 Complete call to setStatus so we have a trigy as 4th parameter (help to
fix the #37129)
2026-02-10 00:44:46 +01:00
hansemschnokeloch
acb45dd61c Fix typo in file path (#37160)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-09 23:50:17 +01:00
MDW
2353b94eb7 Qual: Update phan baseline (#37172) 2026-02-09 23:49:44 +01:00
Eric - CAP-REL
1090494e90 datamodel for user change password next time (#37155) 2026-02-09 23:48:20 +01:00
Laurent Destailleur
fd0b21a5a6 Doc 2026-02-09 23:37:00 +01:00
hansemschnokeloch
f7db0d6cb7 Populate syslog with placeholder (#37163)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-09 23:18:36 +01:00
minimexat
b6980ebb8f FIX #37134 Use json_encode for IMAP search logging in EmailCollector (#37135)
var_export() produces multiline output that breaks log aggregators
(Loki, Splunk, Elasticsearch) as each line becomes a separate log entry.

Using json_encode() produces single-line structured output that works
correctly with all log aggregation tools.

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-09 23:12:39 +01:00
Frédéric FRANCE
3429546116 fix ternary always true (#37161)
* fix ternary always true

* Update requests.php

* Update registration.php

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-09 22:48:16 +01:00
Laurent Destailleur
14180b3a40 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-09 22:44:17 +01:00
Laurent Destailleur
6251540dc9 Debug CI 2026-02-09 22:43:56 +01:00
Noé Cendrier
a7f13f59c1 FIX: missing include for blockedlog lib (#37165) 2026-02-09 20:37:19 +01:00
Laurent Destailleur
4075db8df5 CI 2026-02-09 20:31:21 +01:00
Laurent Destailleur
7221f0a8ef CI 2026-02-09 20:00:35 +01:00
Laurent Destailleur
fd9f4484fa Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-09 20:00:02 +01:00
Laurent Destailleur
34f1ec1f94 CI 2026-02-09 19:55:56 +01:00
Laurent Destailleur
853f09ccef CI 2026-02-09 19:50:05 +01:00
Laurent Destailleur
1c59868e79 CI 2026-02-09 19:43:22 +01:00
Laurent Destailleur
45abf7643c CI 2026-02-09 19:29:17 +01:00
Laurent Destailleur
cec0c2086c Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-09 19:22:44 +01:00
Laurent Destailleur
332fb8c3ef Factorize code 2026-02-09 19:11:37 +01:00
Laurent Destailleur
233a70b5e2 Debug setup navigation 2026-02-09 18:28:53 +01:00
Laurent Destailleur
4c4a3d23eb Debug registration process 2026-02-09 18:04:59 +01:00
Laurent Destailleur
414337e358 Fix navigation 2026-02-09 16:17:01 +01:00
Laurent Destailleur
a2822764e5 WIP LNE 2026-02-09 07:11:20 +01:00
Laurent Destailleur
426f13d495 CSS 2026-02-09 04:35:40 +01:00
Laurent Destailleur
22c824642a Add currency 2026-02-09 04:31:22 +01:00
Laurent Destailleur
616ba86bb8 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-09 04:25:03 +01:00
Laurent Destailleur
5321c29a00 Protect module 2026-02-09 04:24:41 +01:00
Yamil Esteban Garcia
eaa146293e Fix: IRPF tax not applied when creating invoice from project times (#37077)
* Remove 'supplier_invoice' from old path array

* Update module path in arrayforoldpath

Sorry Eldy, I was confused. You are absolutely right, it is already corrected.

* Replace localtax2 assignment with get_localtax function


Error when creating an invoice with personal income tax from project times. The rate does not apply

* Refactor localtax1 calculation using get_localtax

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-09 03:55:34 +01:00
Laurent Destailleur
9da14a6eb2 Fix CI 2026-02-09 03:54:32 +01:00
Laurent Destailleur
71e4553504 CI 2026-02-09 03:23:06 +01:00
Laurent Destailleur
a84271f339 More legal info 2026-02-09 03:21:18 +01:00
Laurent Destailleur
776fed3834 Fix phpunit 2026-02-09 03:18:00 +01:00
Laurent Destailleur
ed03a6f1f8 CSS 2026-02-09 01:06:34 +01:00
Laurent Destailleur
f921204bd4 Clean code. File not used. 2026-02-09 00:05:00 +01:00
Laurent Destailleur
8eda44e96a Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-08 23:59:27 +01:00
Laurent Destailleur
822bc7ffef CI 2026-02-08 23:59:18 +01:00
Laurent Destailleur
a25d4e0e22 CI 2026-02-08 23:42:45 +01:00
Laurent Destailleur
8eb76e4da8 CI 2026-02-08 23:25:11 +01:00
Laurent Destailleur
900b28b97a Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-08 23:21:38 +01:00
Laurent Destailleur
9ab084cee2 CI 2026-02-08 23:21:27 +01:00
Lucas Marcouiller
0e27ee5643 New LNE Collect of buisness informations (#37084)
* Working LNE ping

* remove GPDA

* Add of other informations

* remove testing var

* fix Ci

* fix Ci

* fix ci

* fix CI

* Fix Ci

* fix Ci

---------

Co-authored-by: Lucas Marcouiller <lmarcouiller@dolicloud.com>
2026-02-08 23:14:07 +01:00
Laurent Destailleur
7e1fb745b5 NEW Use the js lib into htdocs/public/includes instead of htdocs/includes 2026-02-08 23:11:40 +01:00
Laurent Destailleur
1025c6798a Clean code 2026-02-08 22:38:26 +01:00
Jarvis
9d52c129e4 Update modProduct.class.php (#37087)
Fix: allow import of sell_or_eat_by_mandatory for products

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-08 22:26:21 +01:00
adamhocini
138c571c75 TakePOS hook “AddAction” jamais exécuté (#35961) (#37113)
@defrance 
Adam Hocini
2026-02-08 22:25:08 +01:00
Laurent Destailleur
67a598d0be Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-08 21:58:41 +01:00
Laurent Destailleur
1c435e2a67 Clean sql 2026-02-08 21:17:56 +01:00
Laurent Destailleur
102b65364c Avoid ( in sql 2026-02-08 20:57:11 +01:00
Laurent Destailleur
fe3314d07a Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-08 20:40:42 +01:00
minimexat
b74c6d3ee0 FIX PHP 8.1 undefined array key warnings in ProductCombination multiprices loop (#37142)
When PRODUIT_MULTIPRICES is enabled and a product variant's parent has
multiprices configured, the updateChildPrice() method iterates through
all price levels up to PRODUIT_MULTIPRICES_LIMIT. For price levels that
don't have prices defined, accessing $parent->multiprices[$i] and
related arrays directly causes 'undefined array key' warnings on
PHP 8.1+.

Changes:
- Add isset() check before comparing $parent->multiprices[$i]
- Use isset() ternary for $parent->multiprices_min[$i] (default: 0)
- Use !empty() for $parent->prices_by_qty_list[$i] check
- Use isset() ternary for $parent->multiprices_ttc[$i] (default: 0)
- Use isset() ternary for second $parent->multiprices[$i] (default: 0)

Co-authored-by: f-hoedl <hoefla14@htl-kaindorf.ac.at>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-08 20:02:02 +01:00
Eric - CAP-REL
b560a05e68 add fk_parent on group group for permission inheritance (#37152) 2026-02-08 20:01:25 +01:00
Laurent Destailleur
938f8b2d46 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-08 19:52:49 +01:00
Laurent Destailleur
8c5fe25137 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-08 19:04:03 +01:00
Laurent Destailleur
48254ef6d0 Comment 2026-02-08 17:51:20 +01:00
Laurent Destailleur
f4dc5dfee9 Fix CI 2026-02-08 17:51:08 +01:00
David Beniamine
de71085394 Ensure that if $object->members is not loaded either we do not send m… (#37126)
* Ensure that if $object->members is not loaded either we do not send members to LDAP or we explicitly loads them before according to LDAP configuration

* Fix typo
2026-02-08 15:39:27 +01:00
MDW
1166dd305b Qual: Update comments from French to English (#37097)
* Qual: Update comments from French to English

# Qual: Update comments from French to English

* Qual: Fix missing initialisations

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-08 15:29:53 +01:00
Laurent Destailleur
2b1d0e1012 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-08 15:28:31 +01:00
Laurent Destailleur
8a8ba06698 Fix CI 2026-02-08 15:28:19 +01:00
minimexat
f70eaae6f5 FIX #34342 PHP 8.1 undefined array key warnings in Product::getSellPrice() multiprices (#37144)
When using multiprices (PRODUIT_MULTIPRICES or
PRODUIT_CUSTOMER_PRICES_AND_MULTIPRICES), getSellPrice() accesses
$this->multiprices[$level], multiprices_ttc, multiprices_min,
multiprices_min_ttc, and multiprices_base_type arrays using the
buyer's price_level as key without checking if the key exists.

This causes 'undefined array key' warnings on PHP 8.1+ when a
third party has a price_level set but the product doesn't have
prices defined for that specific level.

Similarly, prices_by_qty array accesses for PRODUIT_CUSTOMER_PRICES_BY_QTY
and PRODUIT_CUSTOMER_PRICES_BY_QTY_MULTIPRICES modes could trigger
warnings when the array index doesn't exist.

Changes:
- Add isset() checks with safe defaults for all multiprices array
  accesses (0 for prices, 'HT' for price_base_type)
- Replace direct prices_by_qty access with !empty() checks

Co-authored-by: f-hoedl <hoefla14@htl-kaindorf.ac.at>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-08 15:08:58 +01:00
Laurent Destailleur
28a7c69f11 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-08 14:56:01 +01:00
Laurent Destailleur
d15f196249 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-08 14:51:29 +01:00
Laurent Destailleur
f6ec5b44fe CI 2026-02-08 14:51:11 +01:00
minimexat
7496ec701c FIX #36923 Fix undefined array key warnings in opensurvey create_survey.php (#37140)
The session variable initialization logic was inverted: it set variables
to null only when they already existed, instead of initializing them
when they were missing. This caused 'undefined array key' warnings on
PHP 8.1+ when accessing the poll creation form for the first time.

Changes:
- Inverted isset() condition to !isset() to properly initialize missing
  session variables
- Initialize to empty string instead of null
- Added missing session variables (allow_comments, allow_spy, champdatefin)
  to the initialization array
- Added dol_escape_htmltag() for title output (XSS hardening)

Co-authored-by: f-hoedl <hoefla14@htl-kaindorf.ac.at>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-08 14:46:02 +01:00
Vanyo
1cd73239fc Initialize arrayforbutaction before hook (#37149) 2026-02-08 14:44:15 +01:00
Laurent Destailleur
aa36309755 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-08 14:40:13 +01:00
Laurent Destailleur
c939f56b56 NEW Add method formatLogObject to allow logs in 1 line #37135 2026-02-08 14:39:46 +01:00
Mathieu G.
3f412cf745 fix avoids undefined array key (#37103) 2026-02-08 14:28:09 +01:00
Laurent Destailleur
ce50e32a71 Fix regression 2026-02-08 14:25:27 +01:00
Laurent Destailleur
5e960ae089 FIX Show total on multicurrency only if currency are the same on all
lines
2026-02-08 13:57:11 +01:00
Laurent Destailleur
04c72eea0f Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2026-02-08 13:15:16 +01:00
Laurent Destailleur
eeae12ed63 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-08 13:05:32 +01:00
Laurent Destailleur
9fa2fd0b92 Debug v23 2026-02-08 13:04:23 +01:00
Laurent Destailleur
5c6bc657f4 CI 2026-02-08 12:58:22 +01:00
minimexat
02d0b6524c FIX Add missing isset() check for $_GET['file'] in viewimage.php (#37141)
On line 65, $_GET['file'] is accessed without isset() check inside
the modulepart=='mycompany' condition. This causes an 'undefined array
key' warning on PHP 8.1+ when modulepart is 'mycompany' but no file
parameter is provided.

Note: GETPOST() is intentionally not used here as it is not available
before main.inc.php is loaded (see existing code comment).

Co-authored-by: f-hoedl <hoefla14@htl-kaindorf.ac.at>
2026-02-08 03:06:36 +01:00
minimexat
61ece3d5c5 FIX Replace direct $_POST access with GETPOST() in origin/originid recovery paths (#37143)
When a create action fails and rolls back, several list/card pages
restore origin parameters by assigning $_POST values directly to
$_GET. This causes 'undefined array key' warnings on PHP 8.1+ if
the POST data is missing or malformed.

Replace raw $_POST['origin'] with GETPOST('origin', 'alpha') and
raw $_POST['originid'] with GETPOSTINT('originid') which safely
handle missing parameters.

Files fixed:
- htdocs/expedition/list.php
- htdocs/fourn/commande/list.php
- htdocs/commande/list.php
- htdocs/compta/facture/card.php
- htdocs/reception/list.php

These files had TODO-style comments ('Keep this ?', 'Keep GET and
POST here ?') indicating the pattern was already questionable.

Co-authored-by: f-hoedl <hoefla14@htl-kaindorf.ac.at>
2026-02-08 03:05:47 +01:00
Laurent Destailleur
9369f4aea3 Fix CI 2026-02-08 00:19:03 +01:00
Laurent Destailleur
192e181d8a Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-08 00:11:09 +01:00
Laurent Destailleur
b82f488c54 Fix CI 2026-02-08 00:11:01 +01:00
DarmonNoah
7cd3abb9f8 Fixed Bug : email sending test #36741 (#37107)
Fixed Bug : email sending test #36741
@defrance 
-->
Issue fixed
The problem was caused by initializing $result = 0 in core/actions_sendmails.inc.php.
When sending a test email from Setup → Emails, there is no $object to fetch. As a result, $result remained 0 and the code incorrectly triggered ErrorFailedToReadObject.

The fix consists in explicitly setting $result = 1 when no $object is provided (test email / generic email context). This correctly treats the absence of an object as a valid case and restores the ability to send test emails, while keeping $result properly initialized.

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-08 00:00:12 +01:00
adamhocini
ebce799bdb Correct linked_objects assignment for 'propal' #Wrong sourcetype 'commande' instead of 'propal' when creating recurring invoice template from invoice linked to proposal #37099 @defrance (#37112)
* Correct linked_objects assignment for 'propal'

@defrance Adam Hocini

* Refactor linked objects assignment for proposals

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-07 23:58:14 +01:00
Laurent Destailleur
f20eb01d0e Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-07 23:57:50 +01:00
Laurent Destailleur
fd6ecb3901 Fix CI 2026-02-07 23:57:41 +01:00
Laurent Destailleur
43034bfc30 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-07 23:56:27 +01:00
Laurent Destailleur
ee0df74f83 Fix CI 2026-02-07 23:54:21 +01:00
Laurent Destailleur
e364607856 Fix CI 2026-02-07 23:53:07 +01:00
AnthoXic
5078e42330 Update card.php (#37108)
@defrance https://github.com/Dolibarr/dolibarr/issues/36767
2026-02-07 23:41:13 +01:00
Charlène Benke
712b4ce5c4 Increase editor height for note input fields (#37128) 2026-02-07 23:23:56 +01:00
Laurent Destailleur
a781d91469 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-07 22:04:13 +01:00
Laurent Destailleur
e5b2243565 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-07 17:13:24 +01:00
Laurent Destailleur
1ec65e0589 Debug extrafields chckbxlist v23 2026-02-07 14:55:51 +01:00
Laurent Destailleur
d03e1bd940 Debug v23 2026-02-07 12:05:53 +01:00
Laurent Destailleur
a1bc833c3f Fix link 2026-02-07 11:54:54 +01:00
Laurent Destailleur
5b0b22fe28 NEW Add direct debit to close on home thumbs 2026-02-07 11:24:26 +01:00
Laurent Destailleur
0ee93311e9 Fix status code 2026-02-06 22:14:38 +01:00
Laurent Destailleur
8ba58b33ae Fix list of status 2026-02-06 22:11:17 +01:00
Laurent Destailleur
2f023619e9 Fix link 2026-02-06 21:57:46 +01:00
Laurent Destailleur
eaab8a8242 Fix link 2026-02-06 21:53:20 +01:00
Laurent Destailleur
fbd92432b1 Debug v24 2026-02-06 21:50:44 +01:00
Laurent Destailleur
bbba60fa3f Link are clicable on page 2026-02-06 21:47:11 +01:00
Laurent Destailleur
e907abd201 NEW Add status canceled on direct debit payment 2026-02-06 21:27:31 +01:00
Laurent Destailleur
5bde9c7b56 Add tab on sepa direct debit 2026-02-06 20:22:21 +01:00
Laurent Destailleur
38690cd872 Clean code 2026-02-06 19:41:16 +01:00
Laurent Destailleur
92e05a521d Debug filter on status 2026-02-06 19:04:15 +01:00
Laurent Destailleur
d909b6cb75 NEW Filter on status of direct debit 2026-02-06 18:58:34 +01:00
Laurent Destailleur
53045c7377 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-06 18:08:06 +01:00
Laurent Destailleur
4721d852bf Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2026-02-06 18:07:54 +01:00
Jarvis
954233c67d Fix extrafields visibility formulas using $objectoffield without computed fields (#37116)
Initialize $objectoffield before evaluating extrafield visibility/perms so formulas work even when no computed field exists.
Affects create/edit/view visibility logic for extrafields.

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-06 12:57:19 +01:00
Laurent Destailleur
f4b7ce7f20 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-06 12:46:04 +01:00
Laurent Destailleur
5728e44c3d NEW Introduce THIRDPARTY_LIMIT_SIZE for a limit on thirdpaty in select
list
2026-02-06 12:45:40 +01:00
Christophe Battarel
7c20573ef2 FIX : permission on pmp (#37119)
* fix pmp auth on stock at date screen

* fix pmp auth on warehouse list

* fix pmp auth on warehouse card

* FIX: bad argument for print_liste_field_titre

---------

Co-authored-by: Christophe Battarel <christophe@altairis.fr>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
Co-authored-by: Noé Cendrier <81741011+altairis-noe@users.noreply.github.com>
Co-authored-by: Noé Cendrier <noe.cendrier@altairis.fr>
2026-02-06 12:13:21 +01:00
Laurent Destailleur
22e7100281 Trans 2026-02-06 03:17:44 +01:00
Laurent Destailleur
5e206952f4 FIX Error on large product database 2026-02-06 03:10:25 +01:00
Laurent Destailleur
920627e75f Fix var 2026-02-06 02:41:02 +01:00
Laurent Destailleur
2dada142ba Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-06 02:38:10 +01:00
Florian Hödl
26aabf9e2d fix(emailcollector): prevent PHPIMAP body carryover between emails (#37121)
Reset global variables $htmlmsg, $plainmsg, and $attachments before
processing each email in PHPIMAP mode to prevent email body content
from previous email carrying over into the next one.

This issue only affected Microsoft OAuth (PHPIMAP) mode. When an email
had no plain-text body but the previous email did, the previous email's
plain-text would incorrectly be used for the current email.

The $charset variable is intentionally not reset as PHPIMAP handles
charset internally, unlike native IMAP mode.

Also standardized array syntax to use array() consistently per Dolibarr
coding conventions.

Co-authored-by: Florian Hödl <florian@hoedl.co>
2026-02-06 02:37:37 +01:00
Laurent Destailleur
9d68bebac4 NEW Can set position of search object in combo search 2026-02-06 01:29:53 +01:00
Laurent Destailleur
4112213431 Trans 2026-02-06 01:08:29 +01:00
Laurent Destailleur
7bc2523f57 Fix phan 2026-02-05 19:31:41 +01:00
Laurent Destailleur
7773c2504f Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-05 13:55:24 +01:00
Laurent Destailleur
b74e50d7e6 NEW Add method calculateVATNumberFromProperties() 2026-02-05 13:54:13 +01:00
Laurent Destailleur
c9b270b035 Code comment 2026-02-05 13:30:59 +01:00
William Mead
efb61ca449 NEW product barcode label print options (#36656)
* Added product reference and product label options to barcode label. Updated EN localization. Updated contributor details.

* Added reference and label input placeholder

* Updated logic and localizations

* Updated styling

* Updated localization

* Cleaned code
2026-02-05 12:44:00 +01:00
Anthony Berton
86a913d5b1 FIX - Standardization with other Dolibarr objects (#36725)
* FIX - Standardization with other Dolibarr objects

* Solve CI error

---------

Co-authored-by: Anthony Berton <anthony.berton@bb2a.fr>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-05 12:42:15 +01:00
William Mead
feca86b812 FIX supplier order delivery date from order (#36860)
* Fixed delivery date from order

* Updated comment

* Fixed delivery date from order

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-05 12:35:53 +01:00
Laurent Destailleur
16fe32f908 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-05 03:57:09 +01:00
Laurent Destailleur
a798501af3 Fix CI 2026-02-05 03:56:54 +01:00
atm-GregM
77a033999d Add new multiselect OF status search on list (#37069)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-05 03:28:37 +01:00
Anthony Berton
7b33e1c752 UIUX - Look and feel for knowledge (#37096)
* FIX

* FIX

* NEW - Look and feel for knowledge

---------

Co-authored-by: Anthony Berton <anthony.berton@bb2a.fr>
2026-02-05 01:08:00 +01:00
Frédéric FRANCE
ccdcee471b fix french doc (#37095) 2026-02-05 01:06:46 +01:00
Laurent Destailleur
e79416c801 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-04 21:33:26 +01:00
Laurent Destailleur
15658c56d5 CI 2026-02-04 21:33:07 +01:00
Laurent Destailleur
c681071c65 Fix phan 2026-02-04 21:30:16 +01:00
Benjamin Falière
5ed012c6e5 NEW(API): create fixed amount discount (#37091)
* NEW(API): create fixed amount discount

* FIX CI

* FIX CI

---------

Co-authored-by: Benjamin Falière <benjamin.faliere@altairis.fr>
2026-02-04 21:23:46 +01:00
ThomasNgr-OpenDSI
d75499d076 NEW : hide remise_except unit price on invoice lines (#37066)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-04 21:19:06 +01:00
Laurent Destailleur
2905b6096e Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-04 19:49:49 +01:00
Laurent Destailleur
5453a7a79b Close #36975 2026-02-04 18:05:10 +01:00
Charlène Benke
af7f01750b family assignment logic on user perms of external modules (#36456)
* family assignment logic on user perms of external modules

Updated family assignment logic to default to 'other' if family does not exist in $familyinfo.

* Update copyright year for Charlene Benke
2026-02-04 17:19:23 +01:00
Laurent Destailleur
7b96c31789 Fix CI 2026-02-04 17:13:38 +01:00
Laurent Destailleur
5b20b70b66 Doc 2026-02-04 16:56:20 +01:00
Laurent Destailleur
3399db3471 Fix CI 2026-02-04 16:33:50 +01:00
Laurent Destailleur
0ca6f7366b Clean code 2026-02-04 16:21:51 +01:00
AWeerWolf
09a840b6c3 #36843 Update card-rec.php (#37062)
The item desc is already added into the line when selecting the Item. No Need to concat it again when clicking the "add" button.
2026-02-04 16:21:11 +01:00
Laurent Destailleur
f3aa82e4ba Restrict to modiied files 2026-02-04 16:16:51 +01:00
Laurent Destailleur
d6bff9f364 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-04 16:16:10 +01:00
Laurent Destailleur
e3b3a8bbec Fix CI 2026-02-04 16:15:26 +01:00
LePat
8bca07597d fix: add missing geturl lib (#37088) 2026-02-04 16:11:55 +01:00
Laurent Destailleur
5fa75e981b CLOSE #37085 - Popup notif is just under the menu bar 2026-02-04 16:00:16 +01:00
Laurent Destailleur
e22ba4a3d2 Fix CI 2026-02-04 15:20:36 +01:00
Lenin Rivas
624407afcc NEW Show total multicurrency on payment (#37070)
* Total multicurrency

* Total multicurrency paiment

* total result multicurrency

* show total multicurrency
2026-02-04 15:19:48 +01:00
Vanyo
34f7bf1e68 Change translation function to transnoentities (#37065)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-04 15:08:56 +01:00
Laurent Destailleur
96a9d1f4e5 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2026-02-04 15:08:02 +01:00
Laurent Destailleur
89c40d9be6 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-04 15:05:56 +01:00
Laurent Destailleur
1a26f9a42e Trans 2026-02-04 15:05:35 +01:00
Frédéric FRANCE
80f9839253 translate french doc to english (#37064)
* fix french doc

* fix french doc

* fix french doc

* fix french doc

* fix

* fix

* fix

* fix
2026-02-04 14:49:13 +01:00
Laurent Destailleur
82d4bb9df6 fix: dev/examples/zapier/package.json to reduce vulnerabilities (#37071)
The following vulnerabilities are fixed with an upgrade:
- https://snyk.io/vuln/SNYK-JS-LODASH-15053838

Co-authored-by: snyk-bot <snyk-bot@snyk.io>
2026-02-04 14:48:57 +01:00
Braito
d45ed9d78e EmailCollector: exclude sender emails/domains (#37075)
# Conflicts:
#	htdocs/langs/en_US/admin.lang

Co-authored-by: braito4 <braito4@users.noreply.github.com>
2026-02-04 14:46:14 +01:00
Charlène Benke
00b04e9691 Adjust signature appearance position in PDF generation (#37076) 2026-02-04 14:45:07 +01:00
Laurent Destailleur
1cfb3dfaa3 Fix new path of dolreceiptprinter.class.php 2026-02-04 14:36:45 +01:00
Laurent Destailleur
85687d5d88 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2026-02-04 14:27:02 +01:00
Laurent Destailleur
8b920938de Clean code for Takepos 2026-02-04 14:21:47 +01:00
LePat
70d522a6d4 FIX: TakePOS, webapp-hardware-bridge and TakePOS-Connector for modern weighing scales (#37078)
* feat: CustomerDisplay through Webapp-Hardware-Bridge

* feat: WeighingScale through Webapp-Hardware-Bridge

* feat: WeighingScale through Webapp-Hardware-Bridge

* fix: looks like a typo

* feat: for small screens

* fix: attribut contenant le prix du produit ajouté

* feat: ajout d'un callback de gestion d'erreur
2026-02-04 14:20:59 +01:00
Charlène Benke
11241cd8da bad link on sql in fichinter list (#37081) 2026-02-04 14:19:46 +01:00
Laurent Destailleur
4b3a8ff24f Debug v23 2026-02-03 19:05:22 +01:00
Laurent Destailleur
fdce9453bc Make array of dispute status a shared constant 2026-02-03 18:40:36 +01:00
Laurent Destailleur
ca7e4346f0 More complete message 2026-02-03 18:16:05 +01:00
Laurent Destailleur
3a6bd97fc8 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-03 14:08:20 +01:00
Laurent Destailleur
9d8314a65a Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2026-02-03 11:23:24 +01:00
Laurent Destailleur
2faa3a0ae2 Link and filter on ountry for holiday types 2026-02-03 11:22:23 +01:00
Laurent Destailleur
62384bedb4 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2026-02-02 20:56:47 +01:00
Laurent Destailleur
fd41237049 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-02 20:03:05 +01:00
Laurent Destailleur
faa60854f9 Fix situation invoice 2026-02-02 20:02:28 +01:00
Charlène Benke
0a247c57ca load tables in init for create categorie table associated (#37059) 2026-02-02 19:24:31 +01:00
Frédéric FRANCE
95da49edf3 fix french doc (#37056)
* fix french doc

* fix french doc

* fix french doc

* doc translation

* doc translation

* doc translation

* doc translation

* doc translation
2026-02-02 19:22:04 +01:00
hansemschnokeloch
3ff9722903 Add optionnal img to openid login (#37060) 2026-02-02 19:09:57 +01:00
Laurent Destailleur
b5d5087550 Fix sql syntax error 2026-02-02 16:18:43 +01:00
Laurent Destailleur
84592e1f5d Fix CSS 2026-02-02 16:11:46 +01:00
Laurent Destailleur
f8d8abd70b Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-02 15:59:37 +01:00
Frédéric FRANCE
d02b05f1a7 remove french doc and fix travis migration missing (#37053)
* fix french doc

* fix french doc

* fix french doc

* fix french doc

* Clean up comments in card.php

Removed unnecessary comments from card.php

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-02 00:43:28 +01:00
Pierre Ardoin
73273a48da Fix Signature position (#37048)
Move up the position of the signature to fix its explosion on 3 pages
2026-02-02 00:38:06 +01:00
ThomasNgr-OpenDSI
079f0565d7 NEW : Manage discount for all lines for supplier elements. (#36954)
* NEW : Manage remise for all lines for supplier elements.

* Cast remise_percent to float in updateline call

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-02 00:23:40 +01:00
Laurent Destailleur
5b8eeba33d Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-01 19:22:03 +01:00
Laurent Destailleur
e2206a5849 FIX #36892 2026-02-01 19:20:52 +01:00
Frédéric FRANCE
d3dbfd8c6e Add thumbnails for avif (#37045)
* vignette for avif

* vignette for avif

* vignette for avif

* vignette for avif

* vignette for avif

* vignette for avif

* vignette for avif

* vignette for avif

* vignette for avif

* vignette for avif

* vignette for avif

* fix

* fix

* fix

* fix

* fix

* fix

* fix

* fix

* fix

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-01 19:07:15 +01:00
Laurent Destailleur
1395b5f66c CI 2026-02-01 19:04:53 +01:00
Lenin Rivas
429aff6991 FIX divisa rate indirect to direct because Dolibarr use indirect for default (#37046)
* FIX rate_indirect to rate_direct

Direct	: 	1 Divisa Currency = X Currency Main.
Indirect	: 	1 Currency Main = X Divisa Currency.
Then for Dolibarr use is Indirect for default

* FIX divisa rate indirect to direct

Direct	: 	1 Divisa Currency = X Currency Main.
Indirect: 	1 Currency Main = X Divisa Currency.
Then for Dolibarr use is Indirect for default

* FIX divisa rate indirect to direct

Direct	: 	1 Divisa Currency = X Currency Main.
Indirect: 	1 Currency Main = X Divisa Currency.
Then for Dolibarr use is Indirect for default

* FIX divisa rate indirect to direct

Direct	: 	1 Divisa Currency = X Currency Main.
Indirect: 	1 Currency Main = X Divisa Currency.
Then for Dolibarr use is Indirect for default

* FIX divisa rate indirect to direct

Direct	: 	1 Divisa Currency = X Currency Main.
Indirect: 	1 Currency Main = X Divisa Currency.
Then for Dolibarr use is Indirect for default

* Divisa rate direct

Direct	: 	1 Divisa Currency = X Currency Main.
Indirect: 	1 Currency Main = X Divisa Currency.
Then for Dolibarr use is Indirect for default

* Add col rate_direct because Dolibarr use for.default rate indirect

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-01 18:13:09 +01:00
MDW
4e8b6dc21d Qual: Translate french 'avec' comments to English (#37049)
# Qual: Translate french 'avec' comments to English
2026-02-01 18:09:39 +01:00
MDW
c5582f5085 Qual: Translate French 'valeur' in comments to English (#37051) 2026-02-01 18:05:15 +01:00
Alexandre SPANGARO
a84b9cf89d Qual: Translate French comments to English (#37052) 2026-02-01 18:04:58 +01:00
Laurent Destailleur
d02dfe0966 Fix ci 2026-02-01 02:56:16 +01:00
Laurent Destailleur
3ac710d260 Fix CI 2026-02-01 02:48:21 +01:00
Laurent Destailleur
20186dd991 Fix CI 2026-02-01 02:30:28 +01:00
Jyhere
9bb2ae7772 FIX: Add htmlname and selectedrate to parameters array for hook (#36998)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-01 02:08:03 +01:00
Vincent Maury
892f49ffb2 Fix #35394 Display public note on first page (#36993)
* Display public note (an incoterms and sales rep signat) only on real first page

* Display public note (an incoterms and sales rep signat) only on real first page

---------

Co-authored-by: vmaury <vmaury@vmaury-Lafite-Pro-16-AMD>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-01 02:05:08 +01:00
Thatoo
296372cf5f Minimum amount and subscription's amount formula description (#37006)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-01 01:19:29 +01:00
Laurent Destailleur
1e5a12708d CI 2026-02-01 00:44:24 +01:00
Laurent Destailleur
09ded05029 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2026-02-01 00:40:38 +01:00
Laurent Destailleur
47089ec3e1 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-01 00:14:21 +01:00
Laurent Destailleur
93c1013eff Fix CI 2026-02-01 00:13:37 +01:00
Frédéric FRANCE
d74cbcb26d fix french doc (#37047)
* fix french doc

* Update index.php

* Update index.php
2026-02-01 00:00:49 +01:00
Frédéric FRANCE
2e21b1d596 fix french doc (#37037)
* fix french doc

* Update dispatch.php

* Update dispatch.php

* Update graph.php
2026-01-31 20:29:59 +01:00
Charlène Benke
d4f68f8986 warning error if no societe->id defined (#37039) 2026-01-31 20:29:22 +01:00
Frédéric FRANCE
84774abc2c fix french doc (#37040) 2026-01-31 20:28:43 +01:00
MDW
e444abc3d1 Qual: Translate French comments to English ("niveau") (#37041)
Translate French comments to English (comments with "niveau")
2026-01-31 20:28:26 +01:00
Alexandre SPANGARO
1ac1cbf8de Qual: Translate French comments to English (#37044)
* Qual: Translate French comments to English

* Qual: Translate French comments to English
2026-01-31 20:28:09 +01:00
Frédéric FRANCE
73ec501b20 fix french doc (#36897)
* fix french doc

* fix french doc

* fix french doc

* fix french doc

* fix french doc

* fix french doc

* fix french doc

* fix french doc

* fix french doc

* fix french doc

* fix french doc

* fix

* fix

* fix

* fix

* fix french doc

* fix french doc

* fix french doc

* fix french doc

* fix french doc

* fix french doc

* fix french doc

* fix french doc

* Update html.form.class.php

* Update html.form.class.php

* Update index.php

* fix

* fix

* fix

* fix

* fix

* fix

* fix

* fix

* Update modules_facture.php

* Update phpstan.neon.dist

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-30 14:22:56 +01:00
Laurent Destailleur
f64c0136d7 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-30 13:33:44 +01:00
Laurent Destailleur
66746b7e18 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-30 13:26:28 +01:00
Laurent Destailleur
4ec7c5c3f6 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-30 13:26:10 +01:00
Frédéric FRANCE
003c22e772 fix CI (#37033) 2026-01-30 13:08:48 +01:00
Laurent Destailleur
5ae622fb28 Clean code 2026-01-30 05:40:34 +01:00
Laurent Destailleur
611188e32c Log 2026-01-30 05:40:27 +01:00
Laurent Destailleur
08b55f54c5 Fix IPN 2026-01-30 05:31:16 +01:00
Laurent Destailleur
a02afa7641 Fix IPN payment 2026-01-30 05:11:17 +01:00
Laurent Destailleur
2f76d0bc5a More Log 2026-01-30 04:46:32 +01:00
Laurent Destailleur
51c6165983 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2026-01-30 04:12:15 +01:00
Laurent Destailleur
1f77162fef More log 2026-01-30 04:11:42 +01:00
Laurent Destailleur
764f23c1b8 More log 2026-01-30 03:57:07 +01:00
Laurent Destailleur
a8cbcd7150 More log 2026-01-30 03:54:23 +01:00
Laurent Destailleur
dd7906a1d9 FIX Division by zero 2026-01-30 03:20:08 +01:00
Laurent Destailleur
fd71ba3fec Debug v24 2026-01-30 02:56:17 +01:00
Laurent Destailleur
adec349442 Fix when there is more than 99 direct debit in same month 2026-01-30 02:54:03 +01:00
Laurent Destailleur
842b09b2f5 FIX When bank direct debit SEPA ref is > 99 2026-01-30 02:52:34 +01:00
Laurent Destailleur
8882c5e79a Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-30 02:10:43 +01:00
Laurent Destailleur
c9dee9bcd1 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-30 02:10:31 +01:00
Laurent Destailleur
965fa8da72 Doc comment 2026-01-30 02:10:21 +01:00
Laurent Destailleur
22ef8998fb Doc 2026-01-30 00:56:32 +01:00
Frédéric FRANCE
b5d1f8d569 fix phan (#37030)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-30 00:52:36 +01:00
Frédéric FRANCE
001755285b fix phan (#37029)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-30 00:47:45 +01:00
MDW
3fef69e9bf Qual: Update french comments with 'nombre' (#37032)
Update french comments with 'nombre' in their phrasing

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-30 00:37:23 +01:00
Laurent Destailleur
ab0395e8c9 Fix LDAP 2026-01-29 23:52:43 +01:00
Laurent Destailleur
bb5a37e0ef Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-29 23:46:17 +01:00
Laurent Destailleur
63e4f2305f Clean code 2026-01-29 23:33:04 +01:00
Laurent Destailleur
8befaf1ae6 Clean code 2026-01-29 23:30:39 +01:00
Laurent Destailleur
736c269790 Fix phan 2026-01-29 23:19:36 +01:00
Laurent Destailleur
9140024505 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-29 23:17:02 +01:00
Laurent Destailleur
01d715053a try to fix phan 2026-01-29 23:16:51 +01:00
Alexandre SPANGARO
2af5a71c91 NEW Invoice - List - use select2 multiselect for status (#36834)
* NEW Invoice - List - use select2 multiselect for status

* Optimize

* CI

* CI

* Review

* Duplicate line and last problem

* CI

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-29 23:01:26 +01:00
Charlène Benke
a1662ed122 Add api document management for holiday (#36915)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-29 22:55:38 +01:00
Laurent Destailleur
be86aa3c37 CI 2026-01-29 19:21:34 +01:00
Laurent Destailleur
16bdaa5b50 Test without file list 2026-01-29 19:09:57 +01:00
Laurent Destailleur
f30acef13a Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-29 16:48:26 +01:00
Laurent Destailleur
bb833f7641 CI 2026-01-29 15:33:02 +01:00
Laurent Destailleur
225eda7d18 CI 2026-01-29 15:30:30 +01:00
Laurent Destailleur
07a2920ef6 css 2026-01-29 15:08:54 +01:00
Zakaria Boushaba
252ac1e008 NEW: Display thirdparty name with ref in supplier orders linked objects (#36952)
Co-authored-by: Zakaria Boushaba <z.boushaba@vold.africa>
2026-01-29 14:55:44 +01:00
Thatoo
eed9d743c1 [database] Minimum amount and subscription's amount formula description (#37021)
* Remove jstz.min.js from JavaScript array (#37017)

jstz.min.js was deleted in 5599ac733b

* prevent ST_AsWKT() (#37013)

* prevent ST_AsWKT()

* Update commonobject.class.php

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>

* css

* Update llx_adherent_type.sql

add minimumamount and amountformuladescription rows

* Update 22.0.0-23.0.0.sql

add minimumamount and amountformuladescription column

---------

Co-authored-by: hansemschnokeloch <hansemschnokeloch@users.noreply.github.com>
Co-authored-by: atm-jonathan <146709163+atm-jonathan@users.noreply.github.com>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-29 14:46:57 +01:00
Charlène Benke
d9910be2ea NEW allow to disable freezone product on takepos (#37004)
* allow to disable freezone product on takepos

* Conditionally add FreeZone product to menus

* Add NoFreeZoneProduct language entry

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-29 13:33:16 +01:00
Laurent Destailleur
8abe26fde8 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-29 13:32:01 +01:00
Laurent Destailleur
2b1a2e1357 Debug v24 2026-01-29 13:18:03 +01:00
Laurent Destailleur
a746d9b122 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-29 13:14:33 +01:00
Laurent Destailleur
c1456e9db9 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-29 13:14:14 +01:00
sonikf
48791de235 MCP server sql part (#37025)
* Create llx_ai_request_log.sql

* Create llx_ai_request_log.key.sql

* Update 23.0.0-24.0.0.sql

* Update llx_ai_request_log.sql

* Update 23.0.0-24.0.0.sql

* Remove foreign key constraint from llx_ai_request_log

Removed foreign key constraint for fk_user in llx_ai_request_log.

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-29 13:13:52 +01:00
Laurent Destailleur
ac8c35fa9d Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-29 12:32:03 +01:00
Laurent Destailleur
cde20fd1b9 CI 2026-01-29 12:31:55 +01:00
hansemschnokeloch
0e86d0c33a Populate openid data from wellknow url (#37023)
* Delete inexistant file

File jstz.min.js was deleted in
5599ac733b

* Populate openid parameters from wellknow url
2026-01-29 12:09:53 +01:00
Laurent Destailleur
758ee4bef7 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-29 11:28:53 +01:00
Laurent Destailleur
5cf7b54c41 More robust phpunit 2026-01-29 11:25:33 +01:00
Laurent Destailleur
234607a3dd Log 2026-01-29 11:00:43 +01:00
Laurent Destailleur
c23b58d416 Merge manually changes from #37012 that seems good. 2026-01-29 10:56:26 +01:00
Laurent Destailleur
c07ac38ddb Fix test 2026-01-29 10:31:49 +01:00
Laurent Destailleur
183451c607 Clean code 2026-01-29 09:56:10 +01:00
Laurent Destailleur
aa451769ce Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-28 19:47:35 +01:00
Laurent Destailleur
ffc5ee41f9 ci 2026-01-28 19:47:23 +01:00
MDW
ec69a624e0 qual: Update french texts (comments) to english (#37009)
* qual: Update french texts (comments) to english

* Qual: Update comment to english in card-rec.php and card.php

Translation of comments in the files card-rec.php and card.php.

* Qual: Translate comments to English

* Qual: Translate comments to English

* Fix space into tab

* Fix spelling

* Qual: Translate comments to English

* Update website.php

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-28 19:34:12 +01:00
Laurent Destailleur
42751b532e ci 2026-01-28 19:06:13 +01:00
Laurent Destailleur
3a80f4296f ci 2026-01-28 19:00:46 +01:00
Laurent Destailleur
863b5e4303 CI 2026-01-28 18:55:29 +01:00
Laurent Destailleur
de7190eb24 CI 2026-01-28 18:41:58 +01:00
Laurent Destailleur
72a13b8586 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-28 18:37:02 +01:00
Laurent Destailleur
2ed9107dc0 Try to fix phan 2026-01-28 18:32:27 +01:00
atm-jonathan
d9ee7a6b5e prevent ST_AsWKT() (#37013)
* prevent ST_AsWKT()

* Update commonobject.class.php

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-28 18:21:32 +01:00
hansemschnokeloch
4682a9bbfa Remove jstz.min.js from JavaScript array (#37017)
jstz.min.js was deleted in 5599ac733b
2026-01-28 18:01:17 +01:00
hansemschnokeloch
4f2d91d30b Fix typo in phpstan.neon.dist for isset() rule (#37018)
See https://github.com/Dolibarr/dolibarr/actions/runs/21444577128/job/61756970301?pr=37017
2026-01-28 18:00:32 +01:00
Laurent Destailleur
6323e09ba9 CI 2026-01-28 17:59:21 +01:00
Laurent Destailleur
0ccb67c2ef CI 2026-01-28 17:35:00 +01:00
Laurent Destailleur
fdaff88ff7 CI 2026-01-28 17:13:30 +01:00
Laurent Destailleur
49589ab9b1 Trans 2026-01-28 17:11:30 +01:00
Laurent Destailleur
568e69d537 CI 2026-01-28 17:03:52 +01:00
Laurent Destailleur
2890d4a196 CI 2026-01-28 16:55:01 +01:00
Laurent Destailleur
35305eb56e CI 2026-01-28 16:52:52 +01:00
Laurent Destailleur
0ccc9c2802 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2026-01-28 16:23:07 +01:00
Laurent Destailleur
71cb371a1a Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-28 16:21:37 +01:00
Laurent Destailleur
9c832c58ad Exclude non interesting warning 2026-01-28 16:21:24 +01:00
Frédéric FRANCE
11c2feb486 NEW add image format avif (#37014)
* add format avif

* Update functions.lib.php
2026-01-28 16:19:01 +01:00
Lucas Marcouiller
27db2c8169 NEW add import of leave balance (Implementation) (#37011)
* New add import Leave Balance

* add eof

* Update modHoliday.class.php

---------

Co-authored-by: Lucas Marcouiller <lmarcouiller@dolicloud.com>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-28 16:16:20 +01:00
Braito
d3bb30c1d5 Improve OAuth HTTP error details (#36951)
Keep throwing TokenResponseException on HTTP 4xx/5xx while also capturing the response body (ignore_errors) to include a short snippet for admins.

Co-authored-by: caminotravelcenter <caminotravelcenter@localhost>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-28 15:56:01 +01:00
Laurent Destailleur
882200d897 Fix CI 2026-01-28 15:24:31 +01:00
Laurent Destailleur
fa800c532a ci 2026-01-28 15:23:06 +01:00
Laurent Destailleur
2977297582 Doc 2026-01-28 15:21:46 +01:00
Alexandre SPANGARO
58709579cc NEW Add new EUID number (#36997) 2026-01-28 15:18:43 +01:00
Laurent Destailleur
f403a0c705 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-28 15:07:27 +01:00
Laurent Destailleur
06e328eb0b Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-28 15:06:59 +01:00
Laurent Destailleur
afc22d2ba0 CI 2026-01-28 15:06:40 +01:00
Frédéric FRANCE
1819296689 fix phan (#37008)
PhanTypeMismatchArgumentNullable Argument 3 ($txt) is $productlot->batch of type ?string but \TCPDF::MultiCell() takes string defined at htdocs/includes/tecnickcom/tcpdf/tcpdf.php:5871 (expected type to be non-nullable)
2026-01-28 15:04:49 +01:00
Laurent Destailleur
8710651e45 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-28 15:04:14 +01:00
Laurent Destailleur
1bcc8e7fbd CI 2026-01-28 15:04:03 +01:00
Frédéric FRANCE
35b74ef7d6 fix phan (#37007) 2026-01-28 14:58:32 +01:00
Laurent Destailleur
3646b8cbe7 Try to fix CI 2026-01-28 14:58:18 +01:00
Laurent Destailleur
f23394dd53 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-28 14:57:28 +01:00
Laurent Destailleur
18e7d44790 CI 2026-01-28 14:54:40 +01:00
MDW
58ee81186f Qual: Update Phan baseline.txt with reduced issue counts (#36996)
This commit updates the Phan baseline.txt file.
2026-01-27 17:56:36 +01:00
Lucas Marcouiller
8d6e02c373 New import Leave Balance (Datastructure) (#37001)
* New import Leave Balance (Datastructure)

* fix

---------

Co-authored-by: Lucas Marcouiller <lmarcouiller@dolicloud.com>
2026-01-27 17:55:23 +01:00
Laurent Destailleur
0a98a5ca44 Doc 2026-01-27 17:39:02 +01:00
Laurent Destailleur
3ff33915c0 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-27 01:15:58 +01:00
Laurent Destailleur
6808e132f3 WIP LNE 2026-01-27 01:15:30 +01:00
Laurent Destailleur
1212f640c0 Trans 2026-01-26 21:41:02 +01:00
Laurent Destailleur
8fbb1afae9 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-26 20:36:29 +01:00
Laurent Destailleur
5efcd7652f Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-26 19:35:29 +01:00
Braito
9ab11b497e FIX|Fix supplier payment presend mail/PDF (#36939)
- Keep the presend form open after applying an email template.

- Use getDolGlobalString('SUPPLIER_PAYMENT_ADDON_PDF') (no direct ->global access).

- Ensure a PDF model is selected (fallback to first available or standard_supplierpayment) so receipt generation/attachment works.

Signed-off-by: Camino Travel Center <noreply@caminotravelcenter.com>
Co-authored-by: Camino Travel Center <noreply@caminotravelcenter.com>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-26 18:23:01 +01:00
Laurent Destailleur
c1cb839d7d ci 2026-01-26 18:21:49 +01:00
Laurent Destailleur
801fcfbf34 CI 2026-01-26 18:07:51 +01:00
Laurent Destailleur
375fb90bed ci 2026-01-26 18:00:00 +01:00
Laurent Destailleur
45b15db4c6 ci 2026-01-26 17:37:31 +01:00
Laurent Destailleur
d3a1bd58eb Code comment 2026-01-26 16:19:45 +01:00
Laurent Destailleur
00e19d474e Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-26 16:11:36 +01:00
Laurent Destailleur
fab5a769e4 Fix CI 2026-01-26 16:11:21 +01:00
Vincent Penel
ba3df067f3 Automatically send the invoice generated from a template DB (#36947)
* Update DB

* Add flag auto send

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-26 15:53:45 +01:00
Laurent Destailleur
22ffe7f645 Fix ci 2026-01-26 15:47:04 +01:00
Laurent Destailleur
0b7dfad2cf Code comment 2026-01-26 15:21:50 +01:00
Laurent Destailleur
28ce9c657c Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-26 11:58:08 +01:00
Laurent Destailleur
a3c8a832a2 ci 2026-01-26 11:57:58 +01:00
Frédéric FRANCE
8ef582eaf5 display color selected in dict (#36500)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-25 16:16:47 +01:00
noec764
4b2ca3bd28 FIX: Add missing event counter on Agenda tab (#36972)
Co-authored-by: Noé <noe@scopen.fr>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-25 15:55:05 +01:00
Laurent Destailleur
619fb3a590 Debug v23 2026-01-25 15:49:44 +01:00
Laurent Destailleur
156828ac1f Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-25 15:35:34 +01:00
Laurent Destailleur
57950b25fd Trans 2026-01-25 15:33:54 +01:00
Laurent Destailleur
6318b1a836 Clean code 2026-01-25 14:54:56 +01:00
Laurent Destailleur
e79c8d0b87 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-25 14:20:52 +01:00
Laurent Destailleur
1da17070f5 Code comment 2026-01-25 14:19:59 +01:00
Alexandre SPANGARO
82cf80cbc3 Move module asset to stable (#36983) 2026-01-25 14:13:09 +01:00
Laurent Destailleur
57be3472a2 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-24 20:13:16 +01:00
Braito
3a61d3f2c9 Fix SMTP OAuth refresh scopes (#36950)
Recreate the OAuth service with its configured scopes when refreshing an access token (required by some providers like Microsoft v2).

Also keep the previous refresh token when the refreshed token does not include one (e.g. Google returns it only once).

Co-authored-by: caminotravelcenter <caminotravelcenter@localhost>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-24 20:13:06 +01:00
Laurent Destailleur
7f13a3035c Lazy load of substitution array can accept arrays. 2026-01-24 19:43:12 +01:00
Laurent Destailleur
06e2e60364 Fix ci 2026-01-24 19:24:19 +01:00
Laurent Destailleur
6b8214ea6a Fix ci 2026-01-24 18:07:53 +01:00
Laurent Destailleur
27026eced9 Fix ci 2026-01-24 18:00:45 +01:00
Laurent Destailleur
c8e755e5a8 ci 2026-01-24 17:53:57 +01:00
Laurent Destailleur
101b0d7e12 FIX substitution of vars in donation templates 2026-01-24 17:40:22 +01:00
Laurent Destailleur
bb28eed850 Fix ci 2026-01-24 16:15:31 +01:00
Laurent Destailleur
88a1b168ad Fix ci 2026-01-24 16:13:00 +01:00
Laurent Destailleur
7b17ceeefa Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-24 13:54:37 +01:00
Laurent Destailleur
e18220e8eb Fix code action 2026-01-24 13:54:10 +01:00
Charlène Benke
0e51a7a529 Add source parameter to getContacts on api interventional (#36931)
Added a new parameter 'source' to the getContacts method to filter contacts based on their source (internal or external). Updated the method to handle the new parameter appropriately.

propose to add this feature on all getContacts method.

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-24 13:42:54 +01:00
Laurent Destailleur
0029d891a6 Fix ci 2026-01-24 12:46:32 +01:00
Laurent Destailleur
b6c9c42144 Fix ci 2026-01-24 12:43:14 +01:00
Laurent Destailleur
237d623d31 Try fix ci 2026-01-23 22:53:22 +01:00
Laurent Destailleur
639e75b8ae Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-23 22:44:55 +01:00
Laurent Destailleur
455f91c215 Debug v23 2026-01-23 22:44:34 +01:00
Laurent Destailleur
eed0f219a1 Fix ci 2026-01-23 22:43:56 +01:00
Laurent Destailleur
de877188c1 ci 2026-01-23 18:48:57 +01:00
Laurent Destailleur
818dea526b ci 2026-01-23 18:46:38 +01:00
Laurent Destailleur
4c07ef386e Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-23 18:44:37 +01:00
Laurent Destailleur
61c913dff0 Fix ci 2026-01-23 18:43:54 +01:00
Laurent Destailleur
bf9f0e6eb8 Fix ci 2026-01-23 18:40:36 +01:00
Laurent Destailleur
e1b48219df Fix ci 2026-01-23 18:37:58 +01:00
Laurent Destailleur
b75383670c Fix select resource 2026-01-23 18:33:45 +01:00
Charlène Benke
4f15a2e408 Change resource selection index from 1 to 2 (#36955)
fix warning causing by returning array (1 to 2) and suppress search button (0 to 2)
2026-01-23 18:32:34 +01:00
Laurent Destailleur
037ba0212a Fix label of vdp report 2026-01-23 18:28:13 +01:00
Laurent Destailleur
a92cd402d6 Fix ci 2026-01-23 18:21:10 +01:00
Laurent Destailleur
21102855a7 Fix french comment 2026-01-23 18:16:53 +01:00
Laurent Destailleur
6d03ec417a Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-23 18:08:12 +01:00
Laurent Destailleur
237d8d5b90 ci 2026-01-23 18:07:16 +01:00
Alexandre SPANGARO
fd44a5f0e8 NEW - VAT Report - Add button to collapse / expand all rates (#36946)
* NEW - VAT Report - Add button to collapse / expand all rates

* Fix CI

* CI

* Update disposition

* Escape HTML tags in URL parameter handling

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-23 17:55:24 +01:00
Laurent Destailleur
ec04a1bbbd Fix ci 2026-01-23 17:52:27 +01:00
Laurent Destailleur
35f3c56b96 Fix ci 2026-01-23 17:49:37 +01:00
Zakaria Boushaba
ca56cbdaf7 fix: exclude special lines from supplier order dispatch count (#36964)
Co-authored-by: Zakaria Boushaba <z.boushaba@vold.africa>
2026-01-23 16:57:11 +01:00
Lucas Marcouiller
cc222b3ca7 Fix bad trans for member subscription on import (#36969)
* Fix bad trans for member subscription on import

* fix CI

---------

Co-authored-by: Lucas Marcouiller <lmarcouiller@dolicloud.com>
2026-01-23 16:51:57 +01:00
Lucas Marcouiller
1fd2674795 Fix email collector ticket fetch (#36968)
* Fix email collector ticket fetch

* fix CI

---------

Co-authored-by: Lucas Marcouiller <lmarcouiller@dolicloud.com>
2026-01-23 16:51:13 +01:00
Laurent Destailleur
f848220c59 Clean code 2026-01-23 13:29:28 +01:00
Laurent Destailleur
0ae23ec0d1 Fix log 2026-01-21 19:19:36 +01:00
Laurent Destailleur
7ad0874162 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-21 18:23:15 +01:00
Laurent Destailleur
3cbe24ad8c Doc 2026-01-21 18:23:03 +01:00
Laurent Destailleur
a3e6bbb862 Code comment 2026-01-21 17:43:10 +01:00
Laurent Destailleur
1edf2a6ae1 ci 2026-01-21 14:30:04 +01:00
splohmer
508cf6fba9 FIX missmatch of permission check of button and action of cancel delivery note (expedition) (#36943)
In expedition/card.php there is the action "confirm_cancel" which checks for the right supprimer of expedition. The corresponding UI Button checks for creer of expedition. This means some people can see the button, but nothing happens when clicking on it (also no error message).
2026-01-21 14:25:24 +01:00
John BOTELLA
3a3a20e537 QUAL : remove PHP in JS CODE (#36473)
* New hooks and data for ajax getSupplier price

* Fix header

* Quality of code : remove PHP from js code part 02

* Quality of code : remove PHP from js code part 02

* Quality of code : remove PHP from js code part 02

* remove last php

* import last develop changes

* Update objectline_create.tpl.php

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-21 14:24:30 +01:00
Laurent Destailleur
e72345334a Fix ci 2026-01-21 13:40:25 +01:00
Laurent Destailleur
7f3a6a5a40 ci 2026-01-21 13:35:29 +01:00
Laurent Destailleur
b14bae17ae Fix ci 2026-01-21 13:22:02 +01:00
Laurent Destailleur
c89d710fdd Fix ci 2026-01-21 12:47:45 +01:00
Laurent Destailleur
a79d80e11a Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-21 12:45:03 +01:00
Laurent Destailleur
ad092a37f3 Fix ci 2026-01-21 12:44:12 +01:00
Laurent Destailleur
d4030302c9 Comment 2026-01-21 12:29:49 +01:00
Laurent Destailleur
fba2a97ab6 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2026-01-21 12:16:44 +01:00
Laurent Destailleur
a2555bab6b Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-21 12:14:46 +01:00
Laurent Destailleur
eff943bbcf Fix false positive 2026-01-21 12:14:27 +01:00
Charlène Benke
47ae685061 NEW Update holiday class to handle date_create field (#36918)
* Update holiday class to handle date_create field

Add conditional logic to include date_create in SQL update.

* Update holiday.class.php

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-21 01:41:03 +01:00
Charlène Benke
9a75f66e29 NEW Can add date_create on expense report update (#36936)
* Add date_create on expense report update

* Update expensereport.class.php

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-21 01:39:46 +01:00
John BOTELLA
5672008258 FIX WebPortal responsive menu dropdown (#36937)
* Fix responsive menu dropdown

* Change comment from French to English

Updated comment to English for better clarity.

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-21 01:39:23 +01:00
Frédéric FRANCE
5ecc8fe61e add filter on product list (#36926)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-21 01:36:58 +01:00
Laurent Destailleur
01c2c563fb Fix css 2026-01-21 00:47:06 +01:00
Laurent Destailleur
c570b91c96 Debug 2026-01-21 00:36:37 +01:00
Laurent Destailleur
fb7232dc82 Doc 2026-01-21 00:33:24 +01:00
Laurent Destailleur
60dcff1475 Clean code 2026-01-21 00:31:08 +01:00
Laurent Destailleur
0698c3316b Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-21 00:10:40 +01:00
Laurent Destailleur
db49600983 Fix ci 2026-01-21 00:10:30 +01:00
Charlène Benke
33c51e3704 add holiday reference on user hr bank tabs (#36933) 2026-01-21 00:08:29 +01:00
Braito
8d388632cf fix(cron): clamp lastoutput and harden run_jobs (#36938)
* FIX|Fix Cron job lastoutput overflow

Clamp cronjob.lastoutput to MAXIMUM_LENGTH_FOR_LASTOUTPUT_FIELD in create/update to avoid SQL errors when output exceeds DB TEXT size.

Also harden run_jobs():
- jobtype=function: report lib/lang load failures into lastoutput/lastresult and parse params more reliably (comma + trim, supports "0").
- jobtype=command: mark run as failed when CLI is disabled, fall back to sys_get_temp_dir(), and report an explicit error if no temp dir can be resolved.

Signed-off-by: Camino Travel Center <noreply@caminotravelcenter.com>

* Update cronjob.class.php

---------

Signed-off-by: Camino Travel Center <noreply@caminotravelcenter.com>
Co-authored-by: Camino Travel Center <noreply@caminotravelcenter.com>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-20 23:53:29 +01:00
Laurent Destailleur
106ffcfbd6 Fix legacy code 2026-01-20 23:35:41 +01:00
Laurent Destailleur
38f6c4bce1 Remove a TODO 2026-01-20 23:25:27 +01:00
Laurent Destailleur
53231470fc Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-20 23:16:38 +01:00
Laurent Destailleur
715aeb91d9 Fix CI 2026-01-20 23:16:24 +01:00
Frédéric FRANCE
d77fe3afe8 fix ci (#36942)
* fix ci

* Update contact.php
2026-01-20 23:07:24 +01:00
Laurent Destailleur
b93aacbba2 Fix CI 2026-01-20 17:39:40 +01:00
Laurent Destailleur
618ef9925b Fix CI 2026-01-20 17:36:38 +01:00
Laurent Destailleur
6549f135d1 FIX CI 2026-01-20 17:12:25 +01:00
Laurent Destailleur
8da132d4ce Fix CI 2026-01-20 17:04:07 +01:00
Laurent Destailleur
d8a146d6f3 Fix CI 2026-01-20 16:48:27 +01:00
Laurent Destailleur
a6c11e27b1 Fix CI 2026-01-20 16:46:14 +01:00
Laurent Destailleur
275b82e51e Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-20 14:57:32 +01:00
Laurent Destailleur
6f8a8834b8 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2026-01-20 14:57:22 +01:00
lvessiller-opendsi
d51a5a9068 FIX color of ajax on/off button on setup page (#36917)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-20 14:51:43 +01:00
Laurent Destailleur
4ee6eb2e2d Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-20 14:04:47 +01:00
Laurent Destailleur
7d13c12252 Fix CI 2026-01-20 14:01:09 +01:00
Alexandre SPANGARO
3913f4418e Asset - Simplify menu (#36911)
* Asset - Simplify menu

* Asset - Simplify menu

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-20 13:57:33 +01:00
Laurent Destailleur
ff4b7c54d8 Fix CI 2026-01-20 13:56:52 +01:00
Laurent Destailleur
1e8fdd41c9 Fix CI 2026-01-20 13:35:31 +01:00
Laurent Destailleur
7b9a485f17 Fix CI 2026-01-20 13:22:48 +01:00
Laurent Destailleur
8af405a3e8 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-20 12:36:29 +01:00
Laurent Destailleur
ae52d75335 NEW Can add more tags to default tags in dolPrintHTML 2026-01-20 12:30:08 +01:00
Vincent Penel
20dfc743e0 Update DB (#36925) 2026-01-20 11:36:00 +01:00
Laurent Destailleur
6571096107 Merge 2026-01-20 02:37:16 +01:00
Laurent Destailleur
6e6779f401 Merge branch 'develop' of github.com:Dolibarr/dolibarr into develop 2026-01-20 00:30:09 +01:00
Laurent Destailleur
b79ade4c1f Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2026-01-19 21:18:00 +01:00
Laurent Destailleur
61f90ab20c Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-19 21:16:07 +01:00
Laurent Destailleur
9c899899f3 Fix CI 2026-01-19 21:15:46 +01:00
Frédéric FRANCE
3401bd6249 fetchAll ecm_files load extrafields (#36894) 2026-01-19 20:53:30 +01:00
Laurent Destailleur
92048de0f5 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-19 20:52:09 +01:00
Laurent Destailleur
01e37657a6 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-19 19:48:50 +01:00
Laurent Destailleur
f7e688f580 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-19 19:48:43 +01:00
William Mead
566aec36c6 Added since tags to orders api PHPDoc (#36919) 2026-01-19 19:10:44 +01:00
Charlène Benke
eeaa02390e Rename expense report to holiday in API class (#36920) 2026-01-19 19:10:20 +01:00
Laurent Destailleur
2893311770 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-19 19:08:15 +01:00
Laurent Destailleur
9790bf61c6 Fix CI 2026-01-19 19:08:02 +01:00
Laurent Destailleur
13d872a265 Fix warning 2026-01-19 18:39:34 +01:00
Laurent Destailleur
94217e800d Fix CI 2026-01-19 18:28:06 +01:00
Laurent Destailleur
3b23e76237 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-19 18:18:27 +01:00
Laurent Destailleur
7b12b10f9b Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-19 17:31:48 +01:00
Laurent Destailleur
68d92e59d2 Fix CI 2026-01-19 17:29:02 +01:00
Laurent Destailleur
76a2945d88 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-19 17:06:06 +01:00
Laurent Destailleur
99f5ede0ec Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-19 15:39:48 +01:00
Laurent Destailleur
3a01cd9002 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-19 14:48:21 +01:00
Laurent Destailleur
60fbdb1bc9 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-19 14:48:06 +01:00
Charlène Benke
76399298dc fix field name for create update payement (#36903) 2026-01-19 13:27:50 +01:00
Charlène Benke
b79aaf99d7 Add setpaid call on api expensereport (#36904) 2026-01-19 13:27:22 +01:00
Laurent Destailleur
27aa36b537 Fix div balance 2026-01-19 03:50:15 +01:00
Laurent Destailleur
a7e54c5e36 Better title for stipe pages 2026-01-19 01:17:36 +01:00
Laurent Destailleur
f2455704d2 NEW Button to close/reopen bank account status 2026-01-19 01:07:33 +01:00
Laurent Destailleur
354559aa19 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-19 00:27:30 +01:00
Laurent Destailleur
820f3f44c7 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-19 00:26:48 +01:00
Laurent Destailleur
47c4ebeb14 WIP Upload file with AI parsing 2026-01-18 21:29:19 +01:00
Laurent Destailleur
e26c965b7c Doc 2026-01-18 14:23:52 +01:00
Laurent Destailleur
3ba8daab0c Work on AI doc parsing protopype 2026-01-18 14:21:09 +01:00
Laurent Destailleur
f99df3ddc8 Fix position of html components 2026-01-17 18:32:25 +01:00
Laurent Destailleur
2e3d1b0ccd CSS 2026-01-17 16:03:14 +01:00
Laurent Destailleur
ec27124e24 Log message 2026-01-16 18:08:48 +01:00
Laurent Destailleur
c3e043d656 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-16 16:51:37 +01:00
Laurent Destailleur
06a5ea19c4 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-16 16:43:45 +01:00
Laurent Destailleur
3cc2f1b146 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-16 16:37:56 +01:00
Laurent Destailleur
7dee283762 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2026-01-16 16:34:32 +01:00
Laurent Destailleur
949c111f68 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-16 16:32:40 +01:00
Frédéric FRANCE
d07ce2bd08 enhance actioncomm reminder (#36316)
* enhance actioncomm reminder

* fix
2026-01-16 11:32:43 +01:00
Alexandre SPANGARO
8838ad7636 UX Accountancy - Card - Add link to element (#36452)
* UX Accountancy - Card - Add link to element

* CI
2026-01-16 11:31:20 +01:00
Francis
5180d59fc3 Update visibility logic for individual and professional lines (#36449)
Hi
It is a long time that I modify my Dolibarr to erase some items which are not interesting for individual customer...
I decided to post my solution !!!
A css class call professionalline to allow to erase some items !
A simple switch show/hide...
Francis
2026-01-16 11:29:41 +01:00
Frédéric FRANCE
723df03c0d clean printipp (#36472)
* clean printipp

* clean printipp

* clean printipp

* clean printipp

* clean printipp

* clean printipp

* Update functions.lib.php
2026-01-16 11:28:47 +01:00
Frédéric FRANCE
b5394f763a time to init modules (#36526)
* time to init modules

* time to init modules

* Update modules.php

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-16 11:14:27 +01:00
atm-corentin
9c04379799 NEW : add support for label field in addline method In supplier order (#36544)
* add support for label field in addline method to set description when empty

* update
2026-01-16 11:12:47 +01:00
Eric - CAP-REL
7f6966ee06 add hooks on extrafields (#36536) 2026-01-16 11:12:22 +01:00
Lucas Marcouiller
0aa629cfe0 fix change some conf->global to getdolglobal (#36874)
* fix change some conf->global to getdolglobal

* revert some changes

---------

Co-authored-by: Lucas Marcouiller <lmarcouiller@dolicloud.com>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-16 02:55:21 +01:00
Alexandre SPANGARO
bd4b90eadf NEW Supplier invoice - List - use select2 multiselect for status (#36887) 2026-01-16 02:51:21 +01:00
Frédéric FRANCE
b6a49cb4bd fix french doc (#36895)
* fix french doc

* fix french

* Update sync_members_types_dolibarr2ldap.php

* fix french doc

* Update translate.class.php

* Update export-bank-receipts.php

* Update product.class.php

* Update product.class.php
2026-01-16 02:32:37 +01:00
Frédéric FRANCE
d770d37e29 add phpcs rule extension (#36561)
* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* add phpcs rule extension

* test

* test

* test

* test

* test

* test

* fix

* fix

* fix

* fix

* fix

* fix

* fix translations

* fix translations

* translate

* translate

* translate

* translate

* translate

* translate

* translate

* Update propal.class.php
2026-01-15 16:05:06 +01:00
Charlène Benke
2c5be593c4 Add includepermissions parameter to infoGroups api method (#36856)
Added parameter to include permissions in infoGroups method.

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-15 03:19:59 +01:00
Laurent Destailleur
5929de443e Debug v24 2026-01-15 03:18:50 +01:00
William Mead
7b9a878af2 NEW IP restriction to CIDR range (#36855)
* Added IP in CIDR range check

* Cleaned code

* Cleaned code

* Updated conf example

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-15 03:16:10 +01:00
Charlène Benke
d37d84b66e add user table on api holiday index (#36862)
added a join to the user table in the SQL query.

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-15 03:14:24 +01:00
Charlène Benke
a994dbf674 NEW : Fichinter model on stable version (#36873)
* fichinter model on stable version

* Simplify menu addition for ListOfTemplates

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-15 03:04:27 +01:00
Lucas Marcouiller
f1b4379a0e Fix agenda search for holiday or birthday (#36878)
Co-authored-by: Lucas Marcouiller <lmarcouiller@dolicloud.com>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-15 02:04:57 +01:00
tcesar
200c88a55b New Add day selection for payment reports (#36799)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-15 02:04:41 +01:00
Charlène Benke
417bdc88ce Fix warning : add test on $key_fields['default'] is set (#36870)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-15 01:57:41 +01:00
github-actions[bot]
35602c6ff4 PHPStan > Update baseline (#36876)
Co-authored-by: Dolibot <dolibarr-bot@users.noreply.github.com>
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-15 01:28:31 +01:00
Laurent Destailleur
4255228273 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-14 21:39:25 +01:00
Laurent Destailleur
c39939fb21 Log travis 2026-01-14 17:48:49 +01:00
Laurent Destailleur
263cba5c0e Fix CI 2026-01-14 17:40:43 +01:00
Laurent Destailleur
4cffb37310 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-14 16:23:52 +01:00
Laurent Destailleur
e2cd37a178 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-14 15:42:21 +01:00
Laurent Destailleur
4d65ce61d6 Clean code 2026-01-13 23:25:12 +01:00
Laurent Destailleur
e9ac39c031 Fix CI 2026-01-13 23:06:07 +01:00
Laurent Destailleur
cb99921d7c Fix include 2026-01-13 21:51:01 +01:00
Laurent Destailleur
b02d1e0ada Fix error code 2026-01-13 21:48:45 +01:00
Laurent Destailleur
7a93278cb7 Fix generic password type 2026-01-13 19:00:00 +01:00
Laurent Destailleur
750e1ccc90 NEW Global option do diable email is on each email setup page 2026-01-13 16:10:34 +01:00
Laurent Destailleur
72b746ddd3 Fix CI 2026-01-13 15:56:03 +01:00
Laurent Destailleur
4abad0b347 Fix warning oauth 2026-01-13 15:55:56 +01:00
Laurent Destailleur
f1e45a3f69 Fix add missing message once token has been saved 2026-01-13 15:24:26 +01:00
Laurent Destailleur
f373c65b08 Fix missing state 2026-01-13 14:53:31 +01:00
Laurent Destailleur
5c43f8a2cf Fix CI 2026-01-13 11:34:25 +01:00
Laurent Destailleur
8531f6a2aa Fix CI 2026-01-13 11:33:09 +01:00
Laurent Destailleur
509e93e425 Fix CI 2026-01-13 11:31:48 +01:00
Laurent Destailleur
6ca16f700d Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-13 11:21:00 +01:00
Laurent Destailleur
8ed5f73a71 Add registration number into file 2026-01-12 19:44:43 +01:00
Laurent Destailleur
98a179f638 Fix filter 2026-01-12 19:18:52 +01:00
Laurent Destailleur
9464f88162 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-12 16:14:28 +01:00
Laurent Destailleur
1d37667947 Fix warning 2026-01-12 16:14:19 +01:00
github-actions[bot]
84ac2a32ee PHPStan > Update baseline (#36852)
Co-authored-by: Dolibot <dolibarr-bot@users.noreply.github.com>
2026-01-12 16:05:40 +01:00
Laurent Destailleur
9f151233be Clean code 2026-01-12 14:14:19 +01:00
Laurent Destailleur
c92b7874a3 Enhance modify control of invoices 2026-01-12 14:13:37 +01:00
Laurent Destailleur
91c35d4e40 NEW Add a protection against total change on a validated invoice. 2026-01-12 13:44:30 +01:00
Laurent Destailleur
15054810ba Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop
Debug v23
2026-01-12 13:42:02 +01:00
Laurent Destailleur
8dd0aeb1c8 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-12 01:36:19 +01:00
Laurent Destailleur
041f50a438 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-12 01:00:32 +01:00
Laurent Destailleur
fb99d6e736 Debug v23 2026-01-12 00:59:17 +01:00
Laurent Destailleur
8d1cb356c3 Link to societe_rib into llx_facture 2026-01-11 19:16:22 +01:00
Laurent Destailleur
9403eb5aab Copy some field of customer invoices into supplier invoices 2026-01-11 19:12:19 +01:00
Laurent Destailleur
94c75d399d Add field thirdparty_payment_id 2026-01-11 19:08:28 +01:00
Laurent Destailleur
d280468216 Debug v23 2026-01-11 18:12:45 +01:00
Laurent Destailleur
c019159f05 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-11 17:57:29 +01:00
Laurent Destailleur
a303b97330 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-11 17:53:32 +01:00
Laurent Destailleur
382a211962 Try to fix warning 2026-01-11 16:25:10 +01:00
Laurent Destailleur
a4852508e3 Clean code 2026-01-11 16:19:47 +01:00
Laurent Destailleur
d803fc5f28 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-11 16:18:52 +01:00
Laurent Destailleur
4d23bfbffa Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-11 13:13:14 +01:00
Laurent Destailleur
3fbee82d99 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-11 13:13:06 +01:00
spsolauv
ca52029551 CLOSE issue 36744 fix user can delete some actioncomm on which he has not the right (#36747)
* CLOSE issue 36744 fix user can delete some actioncomm on which he has not the right

* Fix whitespace

* Refactor delete confirmation logic for user access

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-11 12:33:17 +01:00
Expresion
9fa9d395dc Fix numeric input parsing to support comma as decimal separator (#36845)
* Fix numeric input parsing to support comma as decimal separator

GETPOSTINT()  only handles integer values and fails when input uses a comma as decimal

* Update dispatch.php

* Change GETPOST to GETPOSTFLOAT for price input

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-10 18:24:19 +01:00
Laurent Destailleur
cf621642fb Revert "NEW : allow to save stocks as 0 on a stock movement. (#36812)" (#36848)
This reverts commit 5662bfad31.
2026-01-10 18:21:41 +01:00
ThomasNgr-OpenDSI
5662bfad31 NEW : allow to save stocks as 0 on a stock movement. (#36812)
* NEW: Add global STOCK_MOVEMENT_FORCE_DO_NOT_CLEAN_EMPTY_LINES to force do not clean empty lines on movement stock. Because customer need to see the warehouse when the product previously even if the stock is at 0. And when in the reassort page, the product with a stock at 0 don't display and block the repleinishment of the stock of the product

* Fix un code manquant pour l'affichage des entrepots avec un stock a 0 lorsque la globale STOCK_MOVEMENT_FORCE_DO_NOT_CLEAN_EMPTY_LINES est activé

---------

Co-authored-by: Kamel Khelifa <kkhelifa@open-dsi.fr>
2026-01-10 18:21:22 +01:00
William Mead
dcbccdc0eb NEW concatenate PDF to strato contract model (#36803)
* Added option to concatenate terms of sale PDF to end of strato contract model

* Cleaned code

* Cleaned code

* Fix module name from 'contrat' to 'contract'

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-10 17:50:08 +01:00
Lucas Marcouiller
489197f1a5 NEW import process by removing some steps (#36811)
* Fix import process by removing some steps

* fix Ci

---------

Co-authored-by: Lucas Marcouiller <lmarcouiller@dolicloud.com>
2026-01-10 17:49:28 +01:00
Laurent Destailleur
984e3d88d8 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-10 17:48:24 +01:00
Laurent Destailleur
e8d12c8448 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-10 17:29:30 +01:00
Laurent Destailleur
03099babed Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-10 17:29:22 +01:00
Laurent Destailleur
8f12d3d0de Debug 2026-01-10 17:29:01 +01:00
lvessiller-opendsi
8e58606559 NEW webportal hooks on form list (#36844) 2026-01-10 17:09:01 +01:00
Laurent Destailleur
089800e477 Add try catch 2026-01-10 15:14:28 +01:00
Laurent Destailleur
0f48d5badf Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-10 15:12:39 +01:00
Laurent Destailleur
9469ba672b Add log 2026-01-09 19:22:46 +01:00
Laurent Destailleur
2208c49082 Debug tracking 2026-01-09 00:04:56 +01:00
Laurent Destailleur
e69290ee22 Implement the ping of last rowid 2026-01-08 23:58:34 +01:00
Laurent Destailleur
a32c92c8ad Debug track 2026-01-08 23:51:19 +01:00
Laurent Destailleur
d24cb36841 Debug sending message 2026-01-08 23:20:56 +01:00
Laurent Destailleur
5d07856182 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-08 23:14:20 +01:00
Laurent Destailleur
82ee93e2c2 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-08 22:55:36 +01:00
Laurent Destailleur
f47c6bbce8 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-08 22:55:15 +01:00
Laurent Destailleur
08c909195a Add tracking of event 2026-01-08 22:55:03 +01:00
Anthony Berton
4eeb3cfaae Ajout d'une div responsive autour du formulaire pour améliorer la mise en page (#36825)
Co-authored-by: Anthony Berton <anthony.berton@bb2a.fr>
2026-01-08 18:56:13 +01:00
Laurent Destailleur
6d48c9f36f Fix CI 2026-01-08 18:24:21 +01:00
Laurent Destailleur
f66ba35226 Clean code 2026-01-08 15:20:08 +01:00
Laurent Destailleur
3a0c8114f9 Fix CI 2026-01-08 15:07:56 +01:00
Laurent Destailleur
2e064b4015 Fix fatal error 2026-01-08 14:52:25 +01:00
Laurent Destailleur
235725b157 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-08 14:38:01 +01:00
Laurent Destailleur
c26a10fbb8 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-08 13:07:44 +01:00
Laurent Destailleur
52e3830618 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-08 03:47:32 +01:00
Laurent Destailleur
41de9c48c6 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-08 03:07:05 +01:00
Laurent Destailleur
e46a31a6ab Code clean 2026-01-08 01:41:55 +01:00
Laurent Destailleur
95d18194f3 NEW Switch default value of nature of a thirdparty. Individual if no
data to guess instead of company by default.
2026-01-08 01:38:32 +01:00
Laurent Destailleur
16506899eb Include last id in answer 2026-01-08 01:00:17 +01:00
ThomasNgr-OpenDSI
74f3cedaf5 Manage THIRDPARTY_PROPAGATE_EXTRAFIELDS_TO_PROPAL (#36810) 2026-01-07 19:16:45 +01:00
Laurent Destailleur
48fab7528f Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-07 19:15:36 +01:00
Laurent Destailleur
ca387ab576 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-07 19:02:52 +01:00
Laurent Destailleur
aeeb88ac19 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-07 19:02:45 +01:00
ThomasNgr-OpenDSI
c4dc8b9276 NEW : Add global MAIL_MASS_ACTION_SEARCH_MOST_RECENT_FILE_IF_NOT_FOUND for search and attach the most recent file if none file found when send email in mass action (#36813)
Co-authored-by: Kamel Khelifa <kkhelifa@open-dsi.fr>
2026-01-07 18:30:16 +01:00
Laurent Destailleur
a35d180c16 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-07 18:25:36 +01:00
Laurent Destailleur
b4b602cdbc Fix var not used 2026-01-07 18:25:27 +01:00
Jérémy
76f6048ba4 NEW : Add “Bank Account” column in invoicing views (customer & supplier invoice lists) (#36718)
* Fix: avoid empty from_template id on first email form display

* first try

* work now

* work with fourn

* perfect.

* perfect.

* Update list.php

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-07 18:23:39 +01:00
Laurent Destailleur
adf788b38e Doc 2026-01-07 15:11:44 +01:00
Laurent Destailleur
b493ed7f96 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-07 14:16:49 +01:00
Laurent Destailleur
2ff2ee02ed Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-07 14:16:39 +01:00
atm-corentin
515e095e27 NEW add Tags & Categories on MOs (#36816) 2026-01-07 11:23:20 +01:00
Frédéric FRANCE
fda736be6f can use an extrafield value in filter (#36822) 2026-01-07 11:14:27 +01:00
Frédéric FRANCE
5509203cef clean code (#36819) 2026-01-07 11:07:31 +01:00
ThomasNgr-OpenDSI
bf8575698d NEW : chose which payment request to include in bank transfer (#36814)
* Add checkboxes to bank transfer screen

* make checked lines be used when creating the SEPA mandate
2026-01-06 16:02:35 +01:00
Frédéric FRANCE
b369576a9d NEW add support of subtotals on more objects (#34125)
* add more subtotals

* add more subtotals

* class

* class

* wip

* wip

* wip

* wip

* doc

* clean code

* clean code

* clean code

* clean code

* clean code

* clean code

* clean code

* clean code

* clean code

* clean code

* clean code

* clean code

* clean code

* clean code

* clean code

* clean code

* fix

* fix

* fix

* fix

* fix

* fix

* clean code

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* wip

* fix

* fix

* fix

* fix

* fix

* fix

* fetch extraparams

* add confirms

* add options

* add options

* add options

* add options

* add options

* add options

* add options

* fix

* wip

* wip

* fix

* fix

* fix

* fix

* fix

* fix
2026-01-06 15:58:06 +01:00
Alexandre SPANGARO
55ba9fc1f9 NEW Accountancy - Add transaction model (SQL Part) (#36807)
* NEW Accountancy - Add transaction model

* FIX CI

* Fix name & length
2026-01-06 14:49:22 +01:00
github-actions[bot]
192b5525af PHPStan > Update baseline (#36809)
Co-authored-by: Dolibot <dolibarr-bot@users.noreply.github.com>
2026-01-06 14:48:25 +01:00
Laurent Destailleur
3a1892e0cd css 2026-01-06 10:34:53 +01:00
Laurent Destailleur
76cebeca39 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-06 10:26:32 +01:00
Laurent Destailleur
7f73d92dc8 Fix select of product and last date in list of time spent 2026-01-06 10:25:39 +01:00
Laurent Destailleur
925381937a Add last date of change 2026-01-06 10:05:59 +01:00
PsyCrow
c4ca165970 NEW Add condition to exclude unpaid invoices from profit (#36693)
* Add condition to exclude unpaid invoices from profit

Only qualify paid invoices to profit calculation

* Fix condition to check invoice status instead of type

Fix condition to check invoice status instead of type.
FIX #36692 issue
2026-01-06 07:44:58 +01:00
Adnan RIHAN
a8ec96baf5 CLOSE #36727 Add ability to objectlink invoice_supplier (#36728)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-06 00:12:05 +01:00
Laurent Destailleur
4d2c86aa8d NEW Can use colored switch in setup factory 2026-01-05 19:34:31 +01:00
Frédéric FRANCE
619a2a6d65 list product and service categories (#36779)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-05 19:01:11 +01:00
Laurent Destailleur
23930ca58e Fix CI 2026-01-05 18:52:32 +01:00
lvessiller-opendsi
eecc4a901d FIX height of shipping address box in proposal PDF model (#36775)
* FIX height of shipping adress box in proposal PDF model

* Update pdf_cyan.modules.php

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-05 18:39:27 +01:00
Laurent Destailleur
9f7a5da7c2 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-05 18:05:59 +01:00
Jyhere
d88730174c FIX: reception reopening lacks of message when an error occurs (#36752)
Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-05 17:46:45 +01:00
Frédéric FRANCE
7f06060592 fix getTooltipContentArray in myobject.class.php (#36755) 2026-01-05 17:45:24 +01:00
Francis Appels
007f8d6ea8 Fix missing line number when bom card in sub bom mode (#36805) 2026-01-05 17:43:08 +01:00
Laurent Destailleur
8734fb9f3b Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-05 17:41:33 +01:00
Laurent Destailleur
67e4c0e72b Fix warning 2026-01-05 17:39:54 +01:00
Laurent Destailleur
993f74ac3e Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-05 17:18:15 +01:00
Laurent Destailleur
0b172e0d27 Debug v23 2026-01-05 15:13:05 +01:00
Laurent Destailleur
a22d481f9e Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-05 14:57:18 +01:00
Laurent Destailleur
6af3e5f278 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-05 14:57:06 +01:00
Josep Lluís
a833788378 Fix qty 'tobuy' from INT to FLOAT type (#36780)
Change qty 'tobuy' from INT to FLOAT type

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-01-05 13:33:07 +01:00
Laurent Destailleur
86e6baf1cf Doc 2026-01-03 18:52:09 +01:00
Laurent Destailleur
676e27d32b Fix maxi debug blockedlog 2026-01-03 13:59:09 +01:00
Laurent Destailleur
07efadaa86 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2026-01-02 18:16:47 +01:00
Laurent Destailleur
3a09c7cfd9 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2025-12-31 15:00:40 +01:00
Laurent Destailleur
ebd018a476 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2025-12-31 14:42:02 +01:00
Laurent Destailleur
a18a544ca2 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2025-12-31 14:05:35 +01:00
Laurent Destailleur
f5aff05704 Debug v23 2025-12-31 01:30:20 +01:00
Laurent Destailleur
e7a6f779de Debug v23 2025-12-31 01:16:37 +01:00
Laurent Destailleur
f6ca154c4a Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2025-12-31 00:51:13 +01:00
Laurent Destailleur
670dde1074 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2025-12-31 00:24:15 +01:00
Laurent Destailleur
aacf34b3b5 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2025-12-30 14:52:44 +01:00
Laurent Destailleur
32ed90740c Debug v23 2025-12-30 14:51:28 +01:00
Laurent Destailleur
b474c07d48 Debug v23 2025-12-30 13:08:23 +01:00
Laurent Destailleur
a5d95ae8e6 Debug v23 2025-12-30 12:55:39 +01:00
Laurent Destailleur
99b685ce2a Debug v23 2025-12-30 11:57:01 +01:00
Laurent Destailleur
0953156549 Debug v23 2025-12-29 22:58:32 +01:00
Laurent Destailleur
a009bf4ef7 Merge branch '23.0' of git@github.com:Dolibarr/dolibarr.git into develop 2025-12-29 18:38:17 +01:00
Laurent Destailleur
60c98ddc30 Prepare v24 2025-12-29 17:52:21 +01:00
Laurent Destailleur
61188c10c0 Debug v24 2025-01-16 10:54:15 +01:00
Laurent Destailleur
219cd50c17 CI with beautify sh generates more trouble and time than it saves.
Removed.
2025-01-16 10:05:52 +01:00
Alexandre SPANGARO
de83d6b1c8 NEW Add EUID number (#37222)
* NEW Add EUID number

* Update example

* CI - Problem on formaccounting

* Fix merge

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-17 22:06:31 +01:00
MDW
7d89635c5b Qual: Update pre-commit for shell script formatting (#37221)
* Qual: Upgrade pre-commit/beautysh, .editorconfig for sh

# Qual: Upgrade pre-commit/beautysh, .editorconfig for sh

- Upgrade beautysh pre-commit hook (trixie/python 3.13 compatibility);
- Indicate tab indent for shell scripts in .editorconfig.

* Qual: Update pre-commit hooks configuration

- Exclude `dev/initdemo/initdemo.sh` from beautysh hook
- Enable shellcheck hook manually
- Fix indentation in `initdemo.sh`

* Qual: Update pre-commit hook configuration

- Update .pre-commit-config.yaml to exclude dolibarr.postrm from beautysh formatting

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-17 22:05:03 +01:00
Laurent Destailleur
bd2ff84a95 Debug v24 2026-02-17 22:00:22 +01:00
Laurent Destailleur
af872c27f7 Debug v24 2026-02-17 21:21:48 +01:00
Laurent Destailleur
753fbda91e Trans 2026-02-17 21:10:07 +01:00
Laurent Destailleur
48391fdbfa Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-17 21:01:39 +01:00
Laurent Destailleur
d213cc82f0 Sync transifex 2026-02-17 21:01:08 +01:00
Eric - CAP-REL
043e1520a6 remove id= from redirect : we use current logged user (#37217) 2026-02-17 20:46:15 +01:00
Francis
2aa45a3897 Comment out additional case for ORDER_SUPPLIER_SUBMIT (#37230)
Trigger ORDER_SUPPLIER_SUBMIT is not présent in module builder
See /fourn/commande/card.php line 2125
2026-02-17 20:37:10 +01:00
Laurent Destailleur
8558744df1 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop 2026-02-17 20:36:32 +01:00
Laurent Destailleur
60ed6ed3ca CI 2026-02-17 20:36:22 +01:00
evarisk-kilyan
da1ea959cb #37167 [TicketAdmin] add: notification ticket_create email template config (#37229)
* #37167 [TicketAdmin] add: notification ticket_create email template config

* #37167 [Lang] add: langs trans
2026-02-17 20:31:53 +01:00
Anthony Damhet
7786bfcd0a Added intuitive selection of table rows for missing objects (#37231)
Add the row-with-select class to list tables

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-17 20:29:00 +01:00
Laurent Destailleur
aef5a5ee91 CI 2026-02-17 20:28:28 +01:00
Erwan-Wiwit
0f397ece1c Add hook beforeCreateStripePaymentIntent in getPaymentIntent() (#37261)
Add a hook point in Stripe::getPaymentIntent() to allow external modules
to modify the $dataforintent array before the Stripe PaymentIntent::create()
API call.

This enables modules to customize:
- statement_descriptor (e.g. structured communication for SEPA DD)
- metadata
- description
- payment_method_types
- and other PaymentIntent parameters

The $arrayofoptions (containing stripe_account and idempotency_key) is
intentionally NOT exposed for security reasons.

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2026-02-17 20:21:35 +01:00
Laurent Destailleur
26aefd139e Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2026-02-17 19:55:06 +01:00
Laurent Destailleur
26a78801d5 Debug v23 Fix creation of thirdparty from member and fix deletion 2025-01-16 10:02:33 +01:00
Laurent Destailleur
37a67f6fa6 Debug v24 2025-01-15 10:25:47 +01:00
886 changed files with 61527 additions and 11868 deletions

View File

@@ -18,6 +18,8 @@ insert_final_newline = true
indent_style = tab
[*.css]
indent_style = tab
[*.sh]
indent_style = tab
[*.xml]
indent_style = tab
[*.md]

View File

@@ -8,12 +8,13 @@ jobs:
secrets: inherit
with:
gh_event: ${{ github.event_name }}
#phan:
# uses: ./.github/workflows/phan.yml
# secrets: inherit
# needs: [pre-commit]
# with:
# gh_event: ${{ github.event_name }}
phan:
# if: false # Uncommenting this line disables phan
uses: ./.github/workflows/phan.yml
secrets: inherit
needs: [pre-commit]
with:
gh_event: ${{ github.event_name }}
phpstan:
uses: ./.github/workflows/phpstan.yml
secrets: inherit

View File

@@ -8,12 +8,12 @@ jobs:
secrets: inherit
with:
gh_event: ${{ github.event_name }}
#phan:
# uses: ./.github/workflows/phan.yml
# secrets: inherit
# needs: [pre-commit]
# with:
# gh_event: ${{ github.event_name }}
phan:
uses: ./.github/workflows/phan.yml
secrets: inherit
needs: [pre-commit]
with:
gh_event: ${{ github.event_name }}
phpstan:
uses: ./.github/workflows/phpstan.yml
secrets: inherit

View File

@@ -49,17 +49,50 @@ jobs:
with:
php-version: 8.2
coverage: none # disable xdebug, pcov
tools: phan:5.5.2
tools: cs2pr,phan:5.5.2
- name: Run Phan analysis
if: "! cancelled() && steps.changed-php.outputs.any_changed == 'true'"
# Proceed when:
# - the action is not cancelled
# AND
# - the branch is an integration branch (no merge), or,
# - the merge from branch contains 'phan_full', or,
# - there are changes in PHP files.
# Note: --output-mode=github does not provide file:line, so using checkstyle and cs2pr
if: ${{ ! cancelled() && (github.ref_name == 'develop' || github.ref_name == 'refs/heads/develop' || endsWith(github.ref_name, '.0') || contains(github.head_ref, 'phan_full') || steps.changed-php.outputs.any_changed == 'true') }}
env:
ALL_CHANGED_FILES: ${{ steps.changed-php.outputs.all_changed_files }}
# shellcheck disable=2086
FILE_CHANGED_LIST: /tmp/phan-changed.lst
run: |
# shellcheck disable=2086
> /tmp/phpstan-files.txt
for f in $ALL_CHANGED_FILES; do echo "$f" >> /tmp/phan-files.txt; done
cat /tmp/phan-files.txt
echo phan --file-list /tmp/phan-files.txt $PHAN_QUICK -k "$PHAN_CONFIG" -B "$PHAN_BASELINE" --analyze-twice --minimum-target-php-version "$PHAN_MIN_PHP" --output-mode=github
phan --file-list /tmp/phan-files.txt $PHAN_QUICK -k "$PHAN_CONFIG" -B "$PHAN_BASELINE" --analyze-twice --minimum-target-php-version "$PHAN_MIN_PHP" --output-mode=github
if [ "${{ github.ref_name }}" == "develop" ] || [[ "${{ github.ref_name }}" == *.0 ]]|| [[ "${{ github.head_ref }}" == *"phan_full"* ]] ; then
echo phan $PHAN_QUICK -k "$PHAN_CONFIG" -B "$PHAN_BASELINE" --analyze-twice --minimum-target-php-version "$PHAN_MIN_PHP" --output-mode=checkstyle -o _phan.xml
phan $PHAN_QUICK -k "$PHAN_CONFIG" -B "$PHAN_BASELINE" --analyze-twice --minimum-target-php-version "$PHAN_MIN_PHP" --output-mode=checkstyle -o _phan.xml
else
echo -n "" > "$FILE_CHANGED_LIST"
for f in $ALL_CHANGED_FILES; do echo "$f" >> "$FILE_CHANGED_LIST"; done
# Must exclude same files as in phan configuration
grep -v -E '^htdocs/(custom/|.*/canvas/.*/tpl/.*.tpl.php|admin/tools/ui/|includes/(nusoap/|restler/|stripe/)|conf/conf.php)$' "$FILE_CHANGED_LIST"> "$FILE_CHANGED_LIST".tmp || true
mv "$FILE_CHANGED_LIST".tmp "$FILE_CHANGED_LIST"
if [ ! -s "$FILE_CHANGED_LIST" ] ; then
echo "All changed files are excluded for phan"
else
echo phan --file-list "$FILE_CHANGED_LIST" $PHAN_QUICK -k "$PHAN_CONFIG" -B "$PHAN_BASELINE" --analyze-twice --minimum-target-php-version "$PHAN_MIN_PHP" --output-mode=checkstyle -o _phan.xml
phan --file-list "$FILE_CHANGED_LIST" $PHAN_QUICK -k "$PHAN_CONFIG" -B "$PHAN_BASELINE" --analyze-twice --minimum-target-php-version "$PHAN_MIN_PHP" --output-mode=checkstyle -o _phan.xml
fi
fi
- name: Add results to PR as Github notices
if: ${{ always() }}
run: |
cs2pr --prepend-filename --prepend-source --notices-as-warnings _phan.xml
- name: Provide phan log as artifact
uses: actions/upload-artifact@v6
if: ${{ always() }}
with:
name: phan-srcrt
path: ${{ github.workspace }}/_phan.xml
retention-days: 2

View File

@@ -89,16 +89,28 @@ jobs:
# Run PHPStan
- name: Run PHPStan
id: phpstan
if: "! cancelled() && steps.changed-php.outputs.any_changed == 'true'"
# Proceed when:
# - the action is not cancelled
# AND
# - the branch is an integration branch (no merge), or,
# - the merge from branch contains 'phpstan_full', or,
# - there are changes in PHP files.
if: ${{ ! cancelled() && (github.ref_name == 'develop' || github.ref_name == 'refs/heads/develop' || endsWith(github.ref_name, '.0') || contains(github.head_ref, 'phpstan_full') || steps.changed-php.outputs.any_changed == 'true') }}
env:
ALL_CHANGED_FILES: ${{ steps.changed-php.outputs.all_changed_files }}
# shellcheck disable=2086
run: |
# shellcheck disable=2086
> /tmp/phpstan-files.txt
echo "$ALL_CHANGED_FILES" >> /tmp/phpstan-files.txt
cat /tmp/phpstan-files.txt
phpstan -vvv analyse --error-format=checkstyle --memory-limit 7G -a dev/build/phpstan/bootstrap_action.php ${ALL_CHANGED_FILES} | tee _stan.xml | cs2pr --graceful-warnings
if [ "${{ github.ref_name }}" == "develop" ] || [[ "${{ github.ref_name }}" == *.0 ]]|| [[ "${{ github.head_ref }}" == *"phpstan_full"* ]] ; then
# Run on all files in integration branch
phpstan -vvv analyse --error-format=checkstyle --memory-limit 7G -a dev/build/phpstan/bootstrap_action.php | tee _stan.xml | cs2pr --graceful-warnings
else
echo "$ALL_CHANGED_FILES" >> /tmp/phpstan-files.txt
cat /tmp/phpstan-files.txt
phpstan -vvv analyse --error-format=checkstyle --memory-limit 7G -a dev/build/phpstan/bootstrap_action.php ${ALL_CHANGED_FILES} | tee _stan.xml | cs2pr --graceful-warnings
fi
# continue-on-error: true
# Save cache

View File

@@ -1,5 +1,5 @@
---
exclude: (?x)^( htdocs/includes/ckeditor/.*|htdocs/public/includes/ckeditor/.*|(\.(?!github/workflows)[^/]*/.*))$
exclude: (?x)^( htdocs/includes/ckeditor/.*|htdocs/public/includes/ckeditor/.*|htdocs/public/includes/jquery/.*|(\.(?!github/workflows)[^/]*/.*))$
repos:
# Several miscellaneous checks and fix (on yaml files, end of files fix)
- repo: https://github.com/pre-commit/pre-commit-hooks
@@ -60,23 +60,26 @@ repos:
# Gitleaks is a SAST tool for detecting and preventing hardcoded secrets like passwords, api keys, and tokens in git repos
- repo: https://github.com/gitleaks/gitleaks.git
rev: v8.29.0
rev: v8.30.0
hooks:
- id: gitleaks
# Check github actions
#- repo: https://github.com/rhysd/actionlint
# rev: v1.7.8
# hooks:
# - id: actionlint
- repo: https://github.com/rhysd/actionlint
rev: v1.7.11
hooks:
- id: actionlint
stages: [manual] # To run: pre-commit run -a --hook-stage=manual actionlint
# Beautify shell scripts
#- repo: https://github.com/lovesegfault/beautysh.git
# rev: v6.2.1
# rev: v6.4.2
# hooks:
# - id: beautysh
# exclude: |
# (?x)^(dev/setup/git/hooks/pre-commit
# |dev/initdemo/initdemo.sh # indent/outdent mismatch
# |dev/build/debian/dolibarr.postrm # indent/outdent mismatch
# )$
# args: [--tab]
@@ -193,7 +196,7 @@ repos:
# Check format of yaml files
- repo: https://github.com/adrienverge/yamllint.git
rev: v1.37.1
rev: v1.38.0
hooks:
- id: yamllint
args:
@@ -245,15 +248,16 @@ repos:
- ned
# Check some shell scripts
#- repo: https://github.com/shellcheck-py/shellcheck-py
# rev: v0.11.0.1
# hooks:
# - id: shellcheck
# args: [-W, "100"]
- repo: https://github.com/shellcheck-py/shellcheck-py
rev: v0.11.0.1
hooks:
- id: shellcheck
stages: [manual] # To run: `pre-commit run -a --hook-stage=manual shellcheck`
args: [-W, "100"]
# Check sql file syntax
- repo: https://github.com/sqlfluff/sqlfluff
rev: 3.3.1
rev: 4.0.4
hooks:
- id: sqlfluff-lint
stages: [pre-commit, manual] # manual needed for ci
@@ -292,4 +296,4 @@ repos:
# # virtualmin excluded - reason https://github.com/Dolibarr/dolibarr/pull/36370#issuecomment-3565101823
# exclude: (?x)^
# (dev/build/perl/virtualmin/dolibarr.pl
# )$
# across all file typese )$

View File

@@ -531,6 +531,9 @@ script:
php upgrade.php 22.0.0 23.0.0 ignoredbversion > $TRAVIS_BUILD_DIR/upgrade22002300.log || cat $TRAVIS_BUILD_DIR/upgrade22002300.log
php upgrade2.php 22.0.0 23.0.0 > $TRAVIS_BUILD_DIR/upgrade22002300-2.log || cat $TRAVIS_BUILD_DIR/upgrade22002300-2.log
php step5.php 22.0.0 23.0.0 > $TRAVIS_BUILD_DIR/upgrade22002300-3.log || cat $TRAVIS_BUILD_DIR/upgrade22002300-3.log
php upgrade.php 23.0.0 24.0.0 ignoredbversion > $TRAVIS_BUILD_DIR/upgrade23002400.log || cat $TRAVIS_BUILD_DIR/upgrade23002400.log
php upgrade2.php 23.0.0 24.0.0 > $TRAVIS_BUILD_DIR/upgrade23002400-2.log || cat $TRAVIS_BUILD_DIR/upgrade23002400-2.log
php step5.php 23.0.0 24.0.0 > $TRAVIS_BUILD_DIR/upgrade23002400-3.log || cat $TRAVIS_BUILD_DIR/upgrade23002400-3.log
set +e
echo
@@ -571,6 +574,8 @@ script:
# Execute phpunit, check its exit status and that the phpunit output shows a test summary
phpunit -d memory_limit=-1 -c test/phpunit/phpunittest.xml test/phpunit/AllTests.php | tee /dev/tty | grep -qE "(OK .*[0-9]+ tests.*[0-9]+ assertions|Tests: [0-9]+)" ; phpunitresult=$((PIPESTATUS[0]?PIPESTATUS[0]:PIPESTATUS[2]))
echo "Phpunit return code = $phpunitresult"
echo "Content of end of apache error.log"
sudo tail -n 200 /var/log/apache2/travis_error_log
# Comment next line if you want to go to the end to see the dolibarr.log file.
[ $phpunitresult == 0 ] || exit $phpunitresult
echo

View File

@@ -299,12 +299,12 @@ If script fails with error Bad certificate, you can set "export PERL_LWP_SSL_VER
* Edit orig.tar.gz file to remove
- debian
- htdocs/includes/ckeditor
- htdocs/includes/jquery/css
- htdocs/includes/jquery/js
- htdocs/includes/jquery/plugins/flot
- htdocs/includes/jquery/plugins/multiselect
- htdocs/includes/jquery/plugins/datatables
- htdocs/public/includes/ckeditor
- htdocs/public/includes/jquery/css
- htdocs/public/includes/jquery/js
- htdocs/public/includes/jquery/plugins/flot
- htdocs/public/includes/jquery/plugins/multiselect
- htdocs/public/includes/jquery/plugins/datatables
- htdocs/includes/jszip
- htdocs/includes/mike42
- htdocs/includes/phpoffice

View File

@@ -61,7 +61,7 @@ License: GPL-3+
------------------------------------------------------------
Files: htdocs/includes/ckeditor/*
Files: htdocs/public/includes/ckeditor/*
Copyright: 2003-2012 CKSource - Frederico Knabben
License: GPL-2+
The ckeditor is triple licensed under the GNU General Public License (GPL),
@@ -190,7 +190,7 @@ License: CC-By-SA
------------------------------------------------------------
Files: htdocs/includes/jquery/*
Files: htdocs/public/includes/jquery/*
Copyright: JQuery team
https://www.jquery.com
License: GPL-2+ or MIT

View File

@@ -97,10 +97,9 @@ override_dh_install:
# rm -fr htdocs/includes/nusoap
# rm -fr htdocs/includes/odtphp/zip/pclzip
# clean from all JS-CSS embedded libraries (we use package dependencies instead)
# rm -fr htdocs/includes/ckeditor
# rm -fr htdocs/includes/jquery/js
# rm -fr htdocs/includes/jquery/css
# rm -fr htdocs/includes/jquery/plugins/flot
# rm -fr htdocs/public/includes/ckeditor
# rm -fr htdocs/public/includes/jquery/js
# rm -fr htdocs/public/includes/jquery/css
# clean from all embedded fonts (we use package dependencies instead)
# rm -fr htdocs/includes/fonts

View File

@@ -1,16 +1,9 @@
# Remove warning, we want to keep both standard and minified sources.
dolibarr: source-contains-prebuilt-javascript-object htdocs/includes/jquery/*
dolibarr: source-contains-prebuilt-javascript-object htdocs/public/includes/jquery/*
dolibarr: source-contains-prebuilt-javascript-object htdocs/includes/jsgantt/*
dolibarr: source-contains-prebuilt-javascript-object htdocs/includes/jstz/*
# Those are false positives, the files are their own sources since
# they are not minified
source-is-missing htdocs/includes/ckeditor/ckeditor/plugins/a11yhelp/dialogs/lang/*.js
source-is-missing htdocs/includes/ckeditor/ckeditor/plugins/specialchar/dialogs/lang/*.js
source-is-missing htdocs/includes/ckeditor/ckeditor/lang/*.js
source-is-missing htdocs/includes/ckeditor/ckeditor/plugins/*/dialogs/*.js
source-is-missing htdocs/includes/ckeditor/ckeditor/plugins/*/filter/*.js
source-is-missing htdocs/includes/ckeditor/ckeditor/plugins/templates/templates/default.js
source-is-missing htdocs/public/includes/ckeditor/ckeditor/plugins/a11yhelp/dialogs/lang/*.js
source-is-missing htdocs/public/includes/ckeditor/ckeditor/plugins/specialchar/dialogs/lang/*.js
source-is-missing htdocs/public/includes/ckeditor/ckeditor/lang/*.js

View File

@@ -44,6 +44,7 @@ define('DOL_DOCUMENT_ROOT', dirname(dirname($path)).'/htdocs');
$algo = 'sha256';
require_once $path."../../htdocs/master.inc.php";
require_once DOL_DOCUMENT_ROOT."/blockedlog/versionmod.inc.php";
require_once DOL_DOCUMENT_ROOT."/core/lib/files.lib.php";
@@ -128,7 +129,10 @@ if ($tmpver[0] == 'auto') {
$release .= '-'.$tmpver[1];
}
}
// If release is auto, we take current version
$releaseblockedlog = DOLCERT_VERSION;
// If release is auto, we take current version to read checklock file
$tmpver = explode('-', $checklock, 2);
if ($tmpver[0] == 'auto') {
$checklock = DOL_VERSION;
@@ -183,6 +187,7 @@ if ($checklock && empty($checksource)) {
if ($release) {
print "Working on files into : ".DOL_DOCUMENT_ROOT."\n";
print "Version of target release : ".$release."\n";
print "Version of blockedlog module : ".$releaseblockedlog."\n";
print "Algo : ".$algo."\n";
print "Include custom dir in signature : ".(empty($includecustom) ? 'no' : 'yes')."\n";
print "Include constants in signature : ".(empty($includeconstants) ? 'none' : '');
@@ -338,13 +343,13 @@ if ($release) {
$checksumconcat = array();
if ($release) {
fputs($fp, '<dolibarr_unalterable_files version="'.$release.'">'."\n");
if ($release && $releaseblockedlog) {
fputs($fp, '<dolibarr_unalterable_files version="'.$releaseblockedlog.'">'."\n");
}
// Array of dir/files to include in the section
$arrayofunalterablefiles = array(
array('dir' => dirname(__FILE__).'/../../htdocs/', 'file' => 'version.inc.php'),
//array('dir' => dirname(__FILE__).'/../../htdocs/', 'file' => 'version.inc.php'),
array('dir' => dirname(__FILE__).'/../../htdocs/blockedlog', 'file' => 'all', 'regextoinclude' => '(\.php|\.sql)$', 'regextoexclude' => ''),
array('dir' => dirname(__FILE__).'/../../htdocs/install/mysql/tables', 'file' => 'all', 'regextoinclude' => 'llx_blockedlog.*(\.php|\.sql)$', 'regextoexclude' => ''),
array('dir' => dirname(__FILE__).'/../../htdocs/core/triggers', 'file' => 'interface_50_modBlockedlog_ActionsBlockedLog.class.php'),
@@ -428,6 +433,7 @@ foreach ($arrayofunalterablefiles as $entry) {
}
asort($checksumconcat); // Sort list of checksum
$hashunalterable_files = hash($algo, join(',', $checksumconcat));
if ($release) {

View File

@@ -816,19 +816,19 @@ if ($nboftargetok) {
$ret = `rm -f $BUILDROOT/$PROJECT/htdocs/includes/geoip/sample*.*`;
$ret = `rm -f $BUILDROOT/$PROJECT/htdocs/includes/bin`;
$ret =
`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/ckeditor/ckeditor/adapters`
`rm -fr $BUILDROOT/$PROJECT/htdocs/public/includes/ckeditor/ckeditor/adapters`
; # Keep this removal in case we embed libraries
$ret =
`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/ckeditor/ckeditor/samples`
`rm -fr $BUILDROOT/$PROJECT/htdocs/public/includes/ckeditor/ckeditor/samples`
; # Keep this removal in case we embed libraries
$ret = `rm -fr $BUILDROOT/$PROJECT/htdocs/includes/ckeditor/_source`
$ret = `rm -fr $BUILDROOT/$PROJECT/htdocs/public/includes/ckeditor/_source`
; # _source must be kept into tarball for official debian, not for the rest
$ret = `rm -f $BUILDROOT/$PROJECT/htdocs/includes/composer`;
$ret = `rm -f $BUILDROOT/$PROJECT/htdocs/includes/doctrine`;
$ret =
`rm -f $BUILDROOT/$PROJECT/htdocs/includes/jquery/plugins/multiselect/MIT-LICENSE.txt`;
`rm -f $BUILDROOT/$PROJECT/htdocs/public/includes/jquery/plugins/multiselect/MIT-LICENSE.txt`;
$ret =
`rm -f $BUILDROOT/$PROJECT/htdocs/includes/jquery/plugins/select2/release.sh`;
`rm -f $BUILDROOT/$PROJECT/htdocs/public/includes/jquery/plugins/select2/release.sh`;
$ret =
`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/mike42/escpos-php/doc`;
$ret =
@@ -934,7 +934,7 @@ if ($nboftargetok) {
$ret = `rm -fr $BUILDROOT/$FILENAMETGZ/dev/build/exe`;
$ret =
`rm -fr $BUILDROOT/$FILENAMETGZ/htdocs/includes/ckeditor/_source`
`rm -fr $BUILDROOT/$FILENAMETGZ/htdocs/public/includes/ckeditor/_source`
; # We can't remove it with exclude file, we need it for some tarball packages
print "Compress $FILENAMETGZ into $FILENAMETGZ.tgz...\n";
@@ -971,7 +971,7 @@ if ($nboftargetok) {
$ret = `rm -fr $BUILDROOT/$FILENAMEXZ/dev/build/exe`;
$ret =
`rm -fr $BUILDROOT/$FILENAMEXZ/htdocs/includes/ckeditor/_source`
`rm -fr $BUILDROOT/$FILENAMEXZ/htdocs/public/includes/ckeditor/_source`
; # We can't remove it with exclude file, we need it for some tarball packages
print "Compress $FILENAMEXZ into $FILENAMEXZ.xz...\n";
@@ -1010,7 +1010,7 @@ if ($nboftargetok) {
$ret = `rm -fr $BUILDROOT/$FILENAMEZIP/dev/build/exe`;
$ret =
`rm -fr $BUILDROOT/$FILENAMEZIP/htdocs/includes/ckeditor/_source`
`rm -fr $BUILDROOT/$FILENAMEZIP/htdocs/public/includes/ckeditor/_source`
; # We can't remove it with exclude file, we need it for some tarball packages
print "Compress $FILENAMEZIP into $FILENAMEZIP.zip...\n";
@@ -1062,7 +1062,7 @@ if ($nboftargetok) {
$ret = `$cmd`;
# Removed files we don't need (already removed before)
#$ret=`rm -fr $BUILDROOT/$FILENAMETGZ2/htdocs/includes/ckeditor/_source`;
#$ret=`rm -fr $BUILDROOT/$FILENAMETGZ2/htdocs/public/includes/ckeditor/_source`;
print "Set permissions on files/dir\n";
$ret = `chmod -R 755 $BUILDROOT/$FILENAMETGZ2`;
@@ -1261,17 +1261,17 @@ if ($nboftargetok) {
# Removed duplicate license files
$ret =
`rm -fr $BUILDROOT/$PROJECT.tmp/htdocs/includes/ckeditor/ckeditor/_source/LICENSE.md`;
`rm -fr $BUILDROOT/$PROJECT.tmp/htdocs/public/includes/ckeditor/ckeditor/_source/LICENSE.md`;
$ret =
`rm -fr $BUILDROOT/$PROJECT.tmp/htdocs/includes/ckeditor/ckeditor/_source/plugins/scayt/LICENSE.md`;
`rm -fr $BUILDROOT/$PROJECT.tmp/htdocs/public/includes/ckeditor/ckeditor/_source/plugins/scayt/LICENSE.md`;
$ret =
`rm -fr $BUILDROOT/$PROJECT.tmp/htdocs/includes/ckeditor/ckeditor/_source/plugins/wsc/LICENSE.md`;
`rm -fr $BUILDROOT/$PROJECT.tmp/htdocs/public/includes/ckeditor/ckeditor/_source/plugins/wsc/LICENSE.md`;
$ret =
`rm -fr $BUILDROOT/$PROJECT.tmp/htdocs/includes/ckeditor/ckeditor/LICENSE.md`;
`rm -fr $BUILDROOT/$PROJECT.tmp/htdocs/public/includes/ckeditor/ckeditor/LICENSE.md`;
$ret =
`rm -fr $BUILDROOT/$PROJECT.tmp/htdocs/includes/ckeditor/ckeditor/plugins/scayt/LICENSE.md`;
`rm -fr $BUILDROOT/$PROJECT.tmp/htdocs/public/includes/ckeditor/ckeditor/plugins/scayt/LICENSE.md`;
$ret =
`rm -fr $BUILDROOT/$PROJECT.tmp/htdocs/includes/ckeditor/ckeditor/plugins/wsc/LICENSE.md`;
`rm -fr $BUILDROOT/$PROJECT.tmp/htdocs/public/includes/ckeditor/ckeditor/plugins/wsc/LICENSE.md`;
$ret =
`rm -fr $BUILDROOT/$PROJECT.tmp/htdocs/includes/php-iban/LICENSE`;
$ret =
@@ -1294,7 +1294,7 @@ if ($nboftargetok) {
`rm -fr $BUILDROOT/$PROJECT.tmp/htdocs/includes/mobiledetect/mobiledetectlib/LICENSE.txt`;
# Removed files we don't need (already removed)
#$ret=`rm -fr $BUILDROOT/$PROJECT.tmp/htdocs/includes/ckeditor/ckeditor/_source`;
#$ret=`rm -fr $BUILDROOT/$PROJECT.tmp/htdocs/public/includes/ckeditor/ckeditor/_source`;
$ret = `rm -fr $BUILDROOT/$PROJECT.tmp/.codeclimate.yml`;
$ret = `rm -fr $BUILDROOT/$PROJECT.tmp/.pre-commit-config.yaml`;
$ret = `rm -fr $BUILDROOT/$PROJECT.tmp/.vscode`;
@@ -1378,61 +1378,41 @@ if ($nboftargetok) {
print "Set permissions on files/dir\n";
$ret = `chmod -R 755 $BUILDROOT/$PROJECT.tmp`;
$cmd =
"find $BUILDROOT/$PROJECT.tmp -type f -exec chmod 644 {} \\; ";
$cmd = "find $BUILDROOT/$PROJECT.tmp -type f -exec chmod 644 {} \\; ";
$ret = `$cmd`;
$cmd =
"find $BUILDROOT/$PROJECT.tmp/dev/build -name '*.php' -type f -exec chmod 755 {} \\; ";
$cmd = "find $BUILDROOT/$PROJECT.tmp/dev/build -name '*.php' -type f -exec chmod 755 {} \\; ";
$ret = `$cmd`;
$cmd =
"find $BUILDROOT/$PROJECT.tmp/dev/build -name '*.dpatch' -type f -exec chmod 755 {} \\; ";
$cmd = "find $BUILDROOT/$PROJECT.tmp/dev/build -name '*.dpatch' -type f -exec chmod 755 {} \\; ";
$ret = `$cmd`;
$cmd =
"find $BUILDROOT/$PROJECT.tmp/dev/build -name '*.pl' -type f -exec chmod 755 {} \\; ";
$cmd = "find $BUILDROOT/$PROJECT.tmp/dev/build -name '*.pl' -type f -exec chmod 755 {} \\; ";
$ret = `$cmd`;
$cmd =
"find $BUILDROOT/$PROJECT.tmp/dev -name '*.php' -type f -exec chmod 755 {} \\; ";
$cmd = "find $BUILDROOT/$PROJECT.tmp/dev -name '*.php' -type f -exec chmod 755 {} \\; ";
$ret = `$cmd`;
$ret = `chmod 755 $BUILDROOT/$PROJECT.tmp/debian/rules`;
$ret =
`chmod -R 644 $BUILDROOT/$PROJECT.tmp/dev/translation/autotranslator.class.php`;
$ret =
`chmod -R 644 $BUILDROOT/$PROJECT.tmp/htdocs/modulebuilder/template/class/actions_mymodule.class.php`;
$ret =
`chmod -R 644 $BUILDROOT/$PROJECT.tmp/htdocs/modulebuilder/template/class/api_mymodule.class.php`;
$ret =
`chmod -R 644 $BUILDROOT/$PROJECT.tmp/htdocs/modulebuilder/template/class/myobject.class.php`;
$ret =
`chmod -R 644 $BUILDROOT/$PROJECT.tmp/htdocs/modulebuilder/template/core/modules/modMyModule.class.php`;
$ret =
`chmod -R 644 $BUILDROOT/$PROJECT.tmp/htdocs/modulebuilder/template/mymoduleindex.php`;
$ret =
`chmod -R 644 $BUILDROOT/$PROJECT.tmp/htdocs/modulebuilder/template/myobject_card.php`;
$ret =
`chmod -R 644 $BUILDROOT/$PROJECT.tmp/htdocs/modulebuilder/template/myobject_list.php`;
$ret =
`chmod -R 755 $BUILDROOT/$PROJECT.tmp/htdocs/modulebuilder/template/scripts/mymodule.php`;
$cmd =
"find $BUILDROOT/$PROJECT.tmp/scripts -name '*.php' -type f -exec chmod 755 {} \\; ";
$ret = `chmod -R 644 $BUILDROOT/$PROJECT.tmp/dev/translation/autotranslator.class.php`;
$ret = `chmod -R 644 $BUILDROOT/$PROJECT.tmp/htdocs/modulebuilder/template/class/actions_mymodule.class.php`;
$ret = `chmod -R 644 $BUILDROOT/$PROJECT.tmp/htdocs/modulebuilder/template/class/api_mymodule.class.php`;
$ret = `chmod -R 644 $BUILDROOT/$PROJECT.tmp/htdocs/modulebuilder/template/class/myobject.class.php`;
$ret = `chmod -R 644 $BUILDROOT/$PROJECT.tmp/htdocs/modulebuilder/template/core/modules/modMyModule.class.php`;
$ret = `chmod -R 644 $BUILDROOT/$PROJECT.tmp/htdocs/modulebuilder/template/mymoduleindex.php`;
$ret = `chmod -R 644 $BUILDROOT/$PROJECT.tmp/htdocs/modulebuilder/template/myobject_card.php`;
$ret = `chmod -R 644 $BUILDROOT/$PROJECT.tmp/htdocs/modulebuilder/template/myobject_list.php`;
$ret = `chmod -R 755 $BUILDROOT/$PROJECT.tmp/htdocs/modulebuilder/template/scripts/mymodule.php`;
$cmd = "find $BUILDROOT/$PROJECT.tmp/scripts -name '*.php' -type f -exec chmod 755 {} \\; ";
$ret = `$cmd`;
$cmd =
"find $BUILDROOT/$PROJECT.tmp/scripts -name '*.sh' -type f -exec chmod 755 {} \\; ";
$cmd = "find $BUILDROOT/$PROJECT.tmp/scripts -name '*.sh' -type f -exec chmod 755 {} \\; ";
$ret = `$cmd`;
print
"Rename directory $BUILDROOT/$PROJECT.tmp into $BUILDROOT/$PROJECT-$MAJOR.$MINOR.$build\n";
$cmd =
"mv $BUILDROOT/$PROJECT.tmp $BUILDROOT/$PROJECT-$MAJOR.$MINOR.$build";
print "Rename directory $BUILDROOT/$PROJECT.tmp into $BUILDROOT/$PROJECT-$MAJOR.$MINOR.$build\n";
$cmd = "mv $BUILDROOT/$PROJECT.tmp $BUILDROOT/$PROJECT-$MAJOR.$MINOR.$build";
$ret = `$cmd`;
print "Go into directory $BUILDROOT\n";
chdir("$BUILDROOT");
# We need a tarball to be able to build "quilt" debian package (not required for native but we need patch so it is not a native)
print
"Compress $BUILDROOT/$PROJECT-$MAJOR.$MINOR.$build into $BUILDROOT/$FILENAMEDEBNATIVE.orig.tar.gz...\n";
$cmd =
"tar --exclude-vcs --exclude-from \"$BUILDROOT/$PROJECT/dev/build/tgz/tar_exclude.txt\" --directory \"$BUILDROOT\" --mode=go-w --group=500 --owner=500 -czvf \"$BUILDROOT/$FILENAMEDEBNATIVE.orig.tar.gz\" $PROJECT-$MAJOR.$MINOR.$build";
# We need a tarball to be able to build "quilt" debian package (not required for native but we need patch so it is not a native)
print "Compress $BUILDROOT/$PROJECT-$MAJOR.$MINOR.$build into $BUILDROOT/$FILENAMEDEBNATIVE.orig.tar.gz...\n";
$cmd = "tar --exclude-vcs --exclude-from \"$BUILDROOT/$PROJECT/dev/build/tgz/tar_exclude.txt\" --directory \"$BUILDROOT\" --mode=go-w --group=500 --owner=500 -czvf \"$BUILDROOT/$FILENAMEDEBNATIVE.orig.tar.gz\" $PROJECT-$MAJOR.$MINOR.$build";
print $cmd. "\n";
$ret = `$cmd`;
@@ -1449,10 +1429,8 @@ if ($nboftargetok) {
chdir("$olddir");
print
"You can check bin package with lintian --pedantic -E -I \"$NEWDESTI/${FILENAMEDEB}_all.deb\"\n";
print
"You can check src package with lintian --pedantic -E -I \"$NEWDESTI/${FILENAMEDEB}.dsc\"\n";
print "You can check bin package with lintian --pedantic -E -I \"$NEWDESTI/${FILENAMEDEB}_all.deb\"\n";
print "You can check src package with lintian --pedantic -E -I \"$NEWDESTI/${FILENAMEDEB}.dsc\"\n";
# Move to final dir
print "Move *_all.deb *.dsc *.orig.tar.gz *.changes to $NEWDESTI\n";
@@ -1460,7 +1438,7 @@ if ($nboftargetok) {
$ret = `mv $BUILDROOT/*.dsc "$NEWDESTI/"`;
$ret = `mv $BUILDROOT/*.orig.tar.gz "$NEWDESTI/"`;
#$ret=`mv $BUILDROOT/*.debian.tar.xz "$NEWDESTI/"`; # xz file is generated when build/debian/sources/option
#$ret=`mv $BUILDROOT/*.debian.tar.xz "$NEWDESTI/"`; # xz file is generated when build/debian/sources/option
$ret = `mv $BUILDROOT/*.debian.tar.gz "$NEWDESTI/"`;
$ret = `mv $BUILDROOT/*.changes "$NEWDESTI/"`;
next;
@@ -1482,17 +1460,15 @@ if ($nboftargetok) {
print "Check that ISCC.exe is in your PATH.\n";
}
else {
print
"Check that in your Wine setup, you have created a Z: drive that point to your / directory.\n";
print "Check that in your Wine setup, you have created a Z: drive that point to your / directory.\n";
}
$SOURCEBACK = $SOURCE;
$SOURCEBACK =~ s/\//\\/g;
print
"Prepare file \"$SOURCEBACK\\dev\\build\\exe\\doliwamp\\doliwamp.tmp.iss\" from \"$SOURCEBACK\\dev\\build\\exe\\doliwamp\\doliwamp.iss\"\n";
print "Prepare file \"$SOURCEBACK\\dev\\build\\exe\\doliwamp\\doliwamp.tmp.iss\" from \"$SOURCEBACK\\dev\\build\\exe\\doliwamp\\doliwamp.iss\"\n";
#$ret=`cat "$SOURCE/dev/build/exe/doliwamp/doliwamp.iss" | sed -e 's/__FILENAMEEXEDOLIWAMP__/$FILENAMEEXEDOLIWAMP/g' > "$SOURCE/build/exe/doliwamp/doliwamp.tmp.iss"`;
#$ret=`cat "$SOURCE/dev/build/exe/doliwamp/doliwamp.iss" | sed -e 's/__FILENAMEEXEDOLIWAMP__/$FILENAMEEXEDOLIWAMP/g' > "$SOURCE/build/exe/doliwamp/doliwamp.tmp.iss"`;
open( my $IN3, '<',
$SOURCE . "/dev/build/exe/doliwamp/doliwamp.iss" )
or die $!;
@@ -1506,40 +1482,35 @@ if ($nboftargetok) {
close($IN3);
close($OUT);
print
"Compil exe $FILENAMEEXEDOLIWAMP.exe file from iss file \"$SOURCEBACK\\dev\\build\\exe\\doliwamp\\doliwamp.tmp.iss\" on OS $OS\n";
print "Compil exe $FILENAMEEXEDOLIWAMP.exe file from iss file \"$SOURCEBACK\\dev\\build\\exe\\doliwamp\\doliwamp.tmp.iss\" on OS $OS\n";
if ( $OS eq 'windows' ) {
$cmd =
"ISCC.exe \"$SOURCEBACK\\dev\\build\\exe\\doliwamp\\doliwamp.tmp.iss\"";
$cmd = "ISCC.exe \"$SOURCEBACK\\dev\\build\\exe\\doliwamp\\doliwamp.tmp.iss\"";
}
else {
#$cmd= "wine ISCC.exe \"Z:$SOURCEBACK\\dev\\build\\exe\\doliwamp\\doliwamp.tmp.iss\"";
#$cmd= "wine ISCC.exe \"Z:$SOURCEBACK\\dev\\build\\exe\\doliwamp\\doliwamp.tmp.iss\"";
}
print "$cmd\n";
$ret = `$cmd`;
print "ret=$ret\n";
# Move to final dir
print
"Move \"$SOURCE\\dev\\build\\$FILENAMEEXEDOLIWAMP.exe\" to $NEWDESTI/$FILENAMEEXEDOLIWAMP.exe\n";
print "Move \"$SOURCE\\dev\\build\\$FILENAMEEXEDOLIWAMP.exe\" to $NEWDESTI/$FILENAMEEXEDOLIWAMP.exe\n";
rename(
"$SOURCE/dev/build/$FILENAMEEXEDOLIWAMP.exe",
"$NEWDESTI/$FILENAMEEXEDOLIWAMP.exe"
);
print
"Move $SOURCE/dev/build/$FILENAMEEXEDOLIWAMP.exe to $NEWDESTI/$FILENAMEEXEDOLIWAMP.exe\n";
print "Move $SOURCE/dev/build/$FILENAMEEXEDOLIWAMP.exe to $NEWDESTI/$FILENAMEEXEDOLIWAMP.exe\n";
use File::Copy;
#$ret=`mv "$SOURCE/dev/build/$FILENAMEEXEDOLIWAMP.exe" "$NEWDESTI/$FILENAMEEXEDOLIWAMP.exe"`;
#$ret=`mv "$SOURCE/dev/build/$FILENAMEEXEDOLIWAMP.exe" "$NEWDESTI/$FILENAMEEXEDOLIWAMP.exe"`;
$ret = move(
"$SOURCE/dev/build/$FILENAMEEXEDOLIWAMP.exe",
"$NEWDESTI/$FILENAMEEXEDOLIWAMP.exe"
);
print
"Remove tmp file $SOURCE/dev/build/exe/doliwamp/doliwamp.tmp.iss\n";
print "Remove tmp file $SOURCE/dev/build/exe/doliwamp/doliwamp.tmp.iss\n";
#$ret=`rm "$SOURCE/dev/build/exe/doliwamp/doliwamp.tmp.iss"`;
$ret = unlink("$SOURCE/dev/build/exe/doliwamp/doliwamp.tmp.iss");
@@ -1558,7 +1529,7 @@ if ($nboftargetok) {
"$DESTI/signatures/filelist-$MAJOR.$MINOR.$BUILD.xml" =>
'none', # none means it won't be published on SF
"$DESTI/package_rpm_generic/$FILENAMERPM" =>
'Dolibarr installer for Fedora-Redhat-Mandriva-Opensuse (DoliRpm)',
'Dolibarr installer for Fedora-Redhat-Mandriva-Opensuse (DoliRpm)',
"$DESTI/package_rpm_generic/$FILENAMERPMSRC" =>
'none', # none means it won't be published on SF
"$DESTI/package_debian-ubuntu/${FILENAMEDEB}_all.deb" =>
@@ -1589,8 +1560,7 @@ if ($nboftargetok) {
'package_debian-ubuntu',
"$DESTI/package_debian-ubuntu/${FILENAMEDEB}.dsc" =>
'package_debian-ubuntu',
#"$DESTI/package_debian-ubuntu/${FILENAMEDEB}.debian.tar.xz"=>'package_debian-ubuntu',
#"$DESTI/package_debian-ubuntu/${FILENAMEDEB}.debian.tar.xz"=>'package_debian-ubuntu',
"$DESTI/package_debian-ubuntu/${FILENAMEDEB}.debian.tar.gz" =>
'package_debian-ubuntu',
"$DESTI/package_debian-ubuntu/${FILENAMEDEBSHORT}.orig.tar.gz" =>
@@ -1652,8 +1622,7 @@ if ($nboftargetok) {
$NUM_SCRIPT = <STDIN>;
chomp($NUM_SCRIPT);
print
"Create empty dir /tmp/emptydir. We need it to create target dir using rsync.\n";
print "Create empty dir /tmp/emptydir. We need it to create target dir using rsync.\n";
$ret = `mkdir -p "/tmp/emptydir/"`;
%filestoscan = %filestoscansf;
@@ -1697,13 +1666,13 @@ if ($nboftargetok) {
#use String::ShellQuote qw( shell_quote );
#$ssh->cmd('mkdir '.shell_quote($destFolder).' && exit');
#use Net::SFTP::Foreign;
#my $sftp = Net::SFTP::Foreign->new($ip, user => $user, password => $pass, autodie => 1);
#$sftp->mkdir($destFolder)
#use Net::SFTP::Foreign;
#my $sftp = Net::SFTP::Foreign->new($ip, user => $user, password => $pass, autodie => 1);
#$sftp->mkdir($destFolder)
#$command="ssh eldy,dolibarr\@frs.sourceforge.net mkdir -p \"$destFolder\"";
#print "$command\n";
#my $ret=`$command 2>&1`;
#$command="ssh eldy,dolibarr\@frs.sourceforge.net mkdir -p \"$destFolder\"";
#print "$command\n";
#my $ret=`$command 2>&1`;
$command = "rsync -s -e 'ssh' --recursive /tmp/emptydir/ \""
. $destFolder . "\"";

File diff suppressed because it is too large Load Diff

View File

@@ -103,7 +103,7 @@ cui hai bisogno ed essere facile da usare.
%{__cp} -pr dev/build/tgz/* $RPM_BUILD_ROOT%{_datadir}/%{name}/dev/build/tgz
%{__cp} -pr htdocs $RPM_BUILD_ROOT%{_datadir}/%{name}
%{__cp} -pr scripts $RPM_BUILD_ROOT%{_datadir}/%{name}
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/includes/ckeditor/_source
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/public/includes/ckeditor/_source
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/includes/nusoap
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/includes/fonts

View File

@@ -167,7 +167,7 @@ cui hai bisogno ed essere facile da usare.
%{__cp} -pr dev/build/tgz/* $RPM_BUILD_ROOT%{_datadir}/%{name}/dev/build/tgz
%{__cp} -pr htdocs $RPM_BUILD_ROOT%{_datadir}/%{name}
%{__cp} -pr scripts $RPM_BUILD_ROOT%{_datadir}/%{name}
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/includes/ckeditor/_source
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/public/includes/ckeditor/_source
%if 0%{?fedora} || 0%{?rhel_version} || 0%{?centos_version}
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/includes/nusoap
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/includes/fonts

View File

@@ -102,7 +102,7 @@ cui hai bisogno ed essere facile da usare.
%{__cp} -pr dev/build/tgz/* $RPM_BUILD_ROOT%{_datadir}/%{name}/dev/build/tgz
%{__cp} -pr htdocs $RPM_BUILD_ROOT%{_datadir}/%{name}
%{__cp} -pr scripts $RPM_BUILD_ROOT%{_datadir}/%{name}
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/includes/ckeditor/_source
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/public/includes/ckeditor/_source
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/includes/fonts
# Lang

View File

@@ -102,7 +102,7 @@ cui hai bisogno ed essere facile da usare.
%{__cp} -pr dev/build/tgz/* $RPM_BUILD_ROOT%{_datadir}/%{name}/dev/build/tgz
%{__cp} -pr htdocs $RPM_BUILD_ROOT%{_datadir}/%{name}
%{__cp} -pr scripts $RPM_BUILD_ROOT%{_datadir}/%{name}
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/includes/ckeditor/_source
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/public/includes/ckeditor/_source
%{__rm} -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/htdocs/includes/fonts
# Lang

View File

@@ -263,7 +263,7 @@ with
PHP JQUERYFILETREE:
-------------------
* Remove directory htdocs/includes/jquery/plugins/jqueryFileTree/connectors
* Remove directory htdocs/public/includes/jquery/plugins/jqueryFileTree/connectors

View File

@@ -15,7 +15,7 @@
"npm": ">=5.6.0"
},
"dependencies": {
"zapier-platform-core": "17.5.0"
"zapier-platform-core": "18.1.1"
},
"devDependencies": {
"mocha": "^5.2.0",

View File

@@ -1 +1,2 @@
/initdemopostsql.sql
/mysqldump_dolibarr_24.0.0.sql2

View File

@@ -0,0 +1,23 @@
BEGIN - regnumber=7dd3b63bd8… - date=2025-02-05T11:54:50Z - period=2025-01 - entity=1 - formatexport=VE1 - user=Alice Adminson;Id;Date création;Action;Origine;Montant HT;Montant TTC;Réf.;Date;Utilisateur;Lier à;Type de lien;Données complètes;Version;Version de la signature;Signature dans la base de données;État;NOTE - previoushash=b63e359ffca54d5c2bab869916eaf23d4a736703028ccbf77ce1167c5f830e7b
;"411";"1736932388";"MODULE_SET";"";"0";"0";"systemevent";"1736932388";"Alice Adminson";"";"";"{""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""id"":0,""ref"":""systemevent"",""entity"":1,""date"":1736932388}";"24.0.0-alpha";"V2";"2031b54f7017f18227cbee83d2e0c3beec2cf2169e472719dd6b920f143ed94e";"Valid";
;"413";"1736932630";"BLOCKEDLOG_EXPORT";"";"0";"0";"systemevent";"1736932630";"Alice Adminson";"";"";"{""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""id"":0,""ref"":""systemevent"",""entity"":1,""date"":1736932630,""fullname"":""Alice Adminson"",""label"":""Export unalterable logs"",""period"":""year=2024 month=1""}";"24.0.0-alpha";"V2";"b850352ef955c0b8133386b79f88dd347e2c625ed133e30e49314f502ace54fc";"Valid";
;"414";"1736932963";"BILL_VALIDATE";"";"9";"9";"FA2501-0037";"1736895600";"Alice Adminson";"";"";"{""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""FA2501-0037"",""module_source"":"""",""pos_source"":"""",""pos_print_counter"":""0"",""email_sent_counter"":""0"",""invoiceline"":{""1"":{""ref"":""PINKDRESS"",""product_type"":""0"",""product_label"":""Pink dress"",""qty"":""1"",""subprice"":""9.00000000"",""tva_tx"":""0.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""9.00000000"",""total_tva"":""0.00000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""9.00000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""9.00000000"",""multicurrency_total_tva"":""0.00000000"",""multicurrency_total_ttc"":""9.00000000""}},""type"":""0"",""date"":1736895600,""total_ht"":9,""total_tva"":0,""total_ttc"":9,""revenuestamp"":""0.00000000""}";"24.0.0-alpha";"V2";"1e43eda5e73678c9275d0137cbf5684d12a79b3d0d32eafa79583b8e21ae4869";"Valid";
;"415";"1737018433";"BILL_VALIDATE";"";"11";"11";"FA2501-0038";"1737018433";"Alice Adminson";"";"";"{""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""FA2501-0038"",""module_source"":"""",""pos_source"":"""",""pos_print_counter"":0,""email_sent_counter"":0,""invoiceline"":{""1"":{""product_type"":""1"",""product_label"":""Adh\u00e9sion \/ cotisation 2025"",""qty"":""1"",""subprice"":""11.00000000"",""tva_tx"":""0.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""11.00000000"",""total_tva"":""0.00000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""11.00000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""11.00000000"",""multicurrency_total_tva"":""0.00000000"",""multicurrency_total_ttc"":""11.00000000""}},""type"":0,""date"":1737018433,""total_ht"":11,""total_tva"":0,""total_ttc"":11}";"24.0.0-alpha";"V2";"20ea65b804e7250ef18a4c4bb40c0dc66362c0b1bf3a2055a596920f808a15ae";"Valid";
;"416";"1737018433";"PAYMENT_CUSTOMER_CREATE";"";"";"11";"PAY2501-0001";"1736982000";"Alice Adminson";"FA2501-0038";"payment";"{""thirdparty"":{""name"":""test test"",""email"":""test@test.com"",""idprof1"":"""",""idprof2"":"""",""tva_assuj"":""1"",""tva_intra"":"""",""code_client"":""CU2501-00037"",""country_code"":""FR""},""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""PAY2501-0001"",""date"":1736982000,""type_code"":""CHQ"",""payment_part"":{""1"":{""amount"":""11"",""invoice"":{""ref"":""FA2501-0038"",""module_source"":"""",""pos_source"":"""",""pos_print_counter"":""0"",""email_sent_counter"":""0"",""type"":""0"",""date"":1736982000,""total_ht"":""11.00000000"",""total_tva"":""0.00000000"",""total_ttc"":""11.00000000"",""revenuestamp"":""0.00000000""}}},""amount"":11}";"24.0.0-alpha";"V2";"af79bb9344a27868825a1c22b2c9ab6d2f7db2aef315541f049490ea620daae5";"Valid";
;"417";"1737018535";"BILL_VALIDATE";"takepos";"1.25";"1.5";"TC1-2501-0009";"1736982000";"Alice Adminson";"";"";"{""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""TC1-2501-0009"",""module_source"":""takepos"",""pos_source"":""1"",""pos_print_counter"":""0"",""email_sent_counter"":""0"",""invoiceline"":{""1"":{""ref"":""POS-APPLE"",""product_type"":""0"",""product_label"":""Apple"",""qty"":""1"",""subprice"":""1.25000000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.50000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.25000000"",""multicurrency_total_tva"":""0.25000000"",""multicurrency_total_ttc"":""1.50000000""}},""type"":""0"",""date"":1736982000,""total_ht"":1.25,""total_tva"":0.25,""total_ttc"":1.5,""revenuestamp"":""0.00000000""}";"24.0.0-alpha";"V2";"b9c58af18960660e2d98b7ca5539677ee0b611f2f49c2ce3ddcd2a7fff06e2b8";"Valid";
;"418";"1737018536";"PAYMENT_CUSTOMER_CREATE";"takepos";"";"1.5";"PAY2501-0002";"1737018535";"Alice Adminson";"TC1-2501-0009";"payment";"{""thirdparty"":{""name"":""Generic customer"",""email"":""ttt@ttt.com"",""idprof1"":"""",""idprof2"":"""",""tva_assuj"":""1"",""tva_intra"":"""",""capital"":""0.00000000"",""typent_code"":""TE_PRIVATE"",""code_client"":""CU1302-0011"",""country_code"":""GB""},""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""PAY2501-0002"",""date"":1737018535,""type_code"":""LIQ"",""payment_part"":{""1"":{""amount"":""1.5"",""invoice"":{""ref"":""TC1-2501-0009"",""module_source"":""takepos"",""pos_source"":""1"",""pos_print_counter"":""0"",""email_sent_counter"":""0"",""type"":""0"",""date"":1736982000,""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_ttc"":""1.50000000"",""revenuestamp"":""0.00000000""}}},""amount"":1.5}";"24.0.0-alpha";"V2";"bb3ffec5b8e04ceb0f1a469b882487aadd6f5e1e04244f5e7ddf1cc2f2f2e3c4";"Valid";
;"419";"1737019049";"DOC_PREVIEW";"takepos";"1.25";"1.5";"TC1-2501-0009";"1736982000";"Alice Adminson";"";"";"{""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""TC1-2501-0009"",""module_source"":""takepos"",""pos_source"":""1"",""pos_print_counter"":1,""email_sent_counter"":""0"",""invoiceline"":{""1"":{""ref"":""POS-APPLE"",""product_type"":""0"",""product_label"":""Apple"",""qty"":""1"",""subprice"":""1.25000000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.50000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.25000000"",""multicurrency_total_tva"":""0.25000000"",""multicurrency_total_ttc"":""1.50000000""}},""type"":""0"",""date"":1736982000,""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_ttc"":""1.50000000"",""revenuestamp"":""0.00000000""}";"24.0.0-alpha";"V2";"17a3c6170409b72a5fedf853abb00581877b18320a207e479c42d77b3d07c4d6";"Valid";
;"420";"1737019181";"DOC_PREVIEW";"takepos";"1.25";"1.5";"TC1-2501-0009";"1736982000";"Alice Adminson";"";"";"{""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""TC1-2501-0009"",""module_source"":""takepos"",""pos_source"":""1"",""pos_print_counter"":2,""email_sent_counter"":""0"",""invoiceline"":{""1"":{""ref"":""POS-APPLE"",""product_type"":""0"",""product_label"":""Apple"",""qty"":""1"",""subprice"":""1.25000000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.50000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.25000000"",""multicurrency_total_tva"":""0.25000000"",""multicurrency_total_ttc"":""1.50000000""}},""type"":""0"",""date"":1736982000,""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_ttc"":""1.50000000"",""revenuestamp"":""0.00000000""}";"24.0.0-alpha";"V2";"d8770dd062220b8332d304039a53565de2d2d5f917f0aa5620dbcb634e75462e";"Valid";
;"421";"1737019353";"DOC_PREVIEW";"takepos";"1.25";"1.5";"TC1-2501-0009";"1736982000";"Alice Adminson";"";"";"{""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""TC1-2501-0009"",""module_source"":""takepos"",""pos_source"":""1"",""pos_print_counter"":3,""email_sent_counter"":""0"",""invoiceline"":{""1"":{""ref"":""POS-APPLE"",""product_type"":""0"",""product_label"":""Apple"",""qty"":""1"",""subprice"":""1.25000000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.50000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.25000000"",""multicurrency_total_tva"":""0.25000000"",""multicurrency_total_ttc"":""1.50000000""}},""type"":""0"",""date"":1736982000,""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_ttc"":""1.50000000"",""revenuestamp"":""0.00000000""}";"24.0.0-alpha";"V2";"dbb2d0f11a6ed01566b69717ddb1c08cee10f6964c47cd6b5f0da213027fd1be";"Valid";
;"422";"1737019636";"DOC_PREVIEW";"takepos";"1.25";"1.5";"TC1-2501-0009";"1736982000";"Alice Adminson";"";"";"{""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""TC1-2501-0009"",""module_source"":""takepos"",""pos_source"":""1"",""pos_print_counter"":4,""email_sent_counter"":""0"",""invoiceline"":{""1"":{""ref"":""POS-APPLE"",""product_type"":""0"",""product_label"":""Apple"",""qty"":""1"",""subprice"":""1.25000000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.50000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.25000000"",""multicurrency_total_tva"":""0.25000000"",""multicurrency_total_ttc"":""1.50000000""}},""type"":""0"",""date"":1736982000,""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_ttc"":""1.50000000"",""revenuestamp"":""0.00000000""}";"24.0.0-alpha";"V2";"e6e65a101521cb8b3921ae31d9565be3432ac94703f2e055e8f1229cb2abee6b";"Valid";
;"423";"1737020016";"DOC_PREVIEW";"takepos";"1.25";"1.5";"TC1-2501-0009";"1736982000";"Alice Adminson";"";"";"{""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""TC1-2501-0009"",""module_source"":""takepos"",""pos_source"":""1"",""pos_print_counter"":5,""email_sent_counter"":""0"",""invoiceline"":{""1"":{""ref"":""POS-APPLE"",""product_type"":""0"",""product_label"":""Apple"",""qty"":""1"",""subprice"":""1.25000000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.50000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.25000000"",""multicurrency_total_tva"":""0.25000000"",""multicurrency_total_ttc"":""1.50000000""}},""type"":""0"",""date"":1736982000,""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_ttc"":""1.50000000"",""revenuestamp"":""0.00000000""}";"24.0.0-alpha";"V2";"24e0d354f83b5e216414930cfa0b07923725a98a0457969df3f962111932baa2";"Valid";
;"424";"1737024079";"DOC_PREVIEW";"takepos";"1.25";"1.5";"TC1-2501-0009";"1736982000";"Alice Adminson";"";"";"{""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""TC1-2501-0009"",""module_source"":""takepos"",""pos_source"":""1"",""pos_print_counter"":6,""email_sent_counter"":""0"",""invoiceline"":{""1"":{""ref"":""POS-APPLE"",""product_type"":""0"",""product_label"":""Apple"",""qty"":""1"",""subprice"":""1.25000000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.50000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.25000000"",""multicurrency_total_tva"":""0.25000000"",""multicurrency_total_ttc"":""1.50000000""}},""type"":""0"",""date"":1736982000,""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_ttc"":""1.50000000"",""revenuestamp"":""0.00000000""}";"24.0.0-alpha";"V2";"f1daed6d4977aed9427b2f6530c340b2613e0d9dbfc748d68cf5320af1def9ea";"Valid";
;"431";"1737028500";"BILL_SENTBYMAIL";"takepos";"1.25";"1.5";"TC1-2501-0009";"1736982000";"Alice Adminson";"";"";"{""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""TC1-2501-0009"",""module_source"":""takepos"",""pos_source"":""1"",""pos_print_counter"":""8"",""email_sent_counter"":5,""invoiceline"":{""1"":{""ref"":""POS-APPLE"",""product_type"":""0"",""product_label"":""Apple"",""qty"":""1"",""subprice"":""1.25000000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.50000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.25000000"",""multicurrency_total_tva"":""0.25000000"",""multicurrency_total_ttc"":""1.50000000""}},""type"":""0"",""date"":1736982000,""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_ttc"":""1.50000000"",""revenuestamp"":""0.00000000"",""action_email_sent"":{""email_from"":""myemail@mybigcompany.com"",""email_to"":""ttt@ttt.com"",""email_msgid"":""6788f3948bc635.10121388.phpmail@cc385f40e47e5be82815b1fa583939f749c7f86e""}}";"24.0.0-alpha";"V2";"749dbdedc18a10087649f00ee3e6b27ce8d092c513450174dc54503959d8a2f8";"Valid";
;"432";"1737028654";"BILL_SENTBYMAIL";"takepos";"1.25";"1.5";"TC1-2501-0009";"1736982000";"Alice Adminson";"";"";"{""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""TC1-2501-0009"",""module_source"":""takepos"",""pos_source"":""1"",""pos_print_counter"":""6"",""email_sent_counter"":2,""invoiceline"":{""1"":{""ref"":""POS-APPLE"",""product_type"":""0"",""product_label"":""Apple"",""qty"":""1"",""subprice"":""1.25000000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.50000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.25000000"",""multicurrency_total_tva"":""0.25000000"",""multicurrency_total_ttc"":""1.50000000""}},""type"":""0"",""date"":1736982000,""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_ttc"":""1.50000000"",""revenuestamp"":""0.00000000"",""action_email_sent"":{""email_from"":""aaaa <aaaa@aa.com>"",""email_to"":""test@test.com"",""email_msgid"":""6788f42ecbbfd9.77578037.phpmail-dolibarr-inv460@cc385f40e47e5be82815b1fa583939f749c7f86e""}}";"24.0.0-alpha";"V2";"2456751468d90ed6cdd06da34cf8a392585eb152db6a9d457c8f6f97539a77ae";"Valid";
;"433";"1737102950";"DOC_PREVIEW";"takepos";"2.33";"2.8";"(PROV-POS2-0)";"1737068400";"Alice Adminson";"";"";"{""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""(PROV-POS2-0)"",""module_source"":""takepos"",""pos_source"":""2"",""pos_print_counter"":""0"",""email_sent_counter"":""0"",""invoiceline"":{""1"":{""ref"":""POS-APPLE"",""product_type"":""0"",""product_label"":""Apple"",""qty"":""1"",""subprice"":""1.25000000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.50000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.25000000"",""multicurrency_total_tva"":""0.25000000"",""multicurrency_total_ttc"":""1.50000000""},""2"":{""ref"":""POS-KIWI"",""product_type"":""0"",""product_label"":""Kiwi"",""qty"":""1"",""subprice"":""1.08333000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.08000000"",""total_tva"":""0.22000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.30000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.08000000"",""multicurrency_total_tva"":""0.22000000"",""multicurrency_total_ttc"":""1.30000000""}},""type"":""0"",""date"":1737068400,""total_ht"":""2.33000000"",""total_tva"":""0.47000000"",""total_ttc"":""2.80000000"",""revenuestamp"":""0.00000000""}";"24.0.0-alpha";"V2";"451b90f983512fa095ef9475876d130084489f3e2cb89464ad522391dc1b06a2";"Valid";
;"434";"1737102963";"BILL_VALIDATE";"takepos";"2.33";"2.8";"TC2-2501-0001";"1737068400";"Alice Adminson";"";"";"{""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""TC2-2501-0001"",""module_source"":""takepos"",""pos_source"":""2"",""pos_print_counter"":""0"",""email_sent_counter"":""0"",""invoiceline"":{""1"":{""ref"":""POS-APPLE"",""product_type"":""0"",""product_label"":""Apple"",""qty"":""1"",""subprice"":""1.25000000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.50000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.25000000"",""multicurrency_total_tva"":""0.25000000"",""multicurrency_total_ttc"":""1.50000000""},""2"":{""ref"":""POS-KIWI"",""product_type"":""0"",""product_label"":""Kiwi"",""qty"":""1"",""subprice"":""1.08333000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.08000000"",""total_tva"":""0.22000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.30000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.08000000"",""multicurrency_total_tva"":""0.22000000"",""multicurrency_total_ttc"":""1.30000000""}},""type"":""0"",""date"":1737068400,""total_ht"":2.33,""total_tva"":0.47,""total_ttc"":2.8,""revenuestamp"":""0.00000000""}";"24.0.0-alpha";"V2";"a4f51205e87339187636bd26df2b330dba86c404204144a69711ec4e0e0cc58f";"Valid";
;"435";"1737102963";"PAYMENT_CUSTOMER_CREATE";"takepos";"";"2.8";"PAY2501-0003";"1737102963";"Alice Adminson";"TC2-2501-0001";"payment";"{""thirdparty"":{""name"":""Generic customer"",""email"":""ttt@ttt.com"",""idprof1"":"""",""idprof2"":"""",""tva_assuj"":""1"",""tva_intra"":"""",""capital"":""0.00000000"",""typent_code"":""TE_PRIVATE"",""code_client"":""CU1302-0011"",""country_code"":""GB""},""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""PAY2501-0003"",""date"":1737102963,""type_code"":""LIQ"",""payment_part"":{""1"":{""amount"":""2.8"",""invoice"":{""ref"":""TC2-2501-0001"",""module_source"":""takepos"",""pos_source"":""2"",""pos_print_counter"":""0"",""email_sent_counter"":""0"",""type"":""0"",""date"":1737068400,""total_ht"":""2.33000000"",""total_tva"":""0.47000000"",""total_ttc"":""2.80000000"",""revenuestamp"":""0.00000000""}}},""amount"":2.8}";"24.0.0-alpha";"V2";"e095af5c7eec1f1d0272d1ab633c9f9b78d5f9ee44f425f3fed5ed844ea700b2";"Valid";
;"436";"1737102971";"DOC_PREVIEW";"takepos";"2.33";"2.8";"TC2-2501-0001";"1737068400";"Alice Adminson";"";"";"{""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""TC2-2501-0001"",""module_source"":""takepos"",""pos_source"":""2"",""pos_print_counter"":1,""email_sent_counter"":""0"",""invoiceline"":{""1"":{""ref"":""POS-APPLE"",""product_type"":""0"",""product_label"":""Apple"",""qty"":""1"",""subprice"":""1.25000000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.50000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.25000000"",""multicurrency_total_tva"":""0.25000000"",""multicurrency_total_ttc"":""1.50000000""},""2"":{""ref"":""POS-KIWI"",""product_type"":""0"",""product_label"":""Kiwi"",""qty"":""1"",""subprice"":""1.08333000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.08000000"",""total_tva"":""0.22000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.30000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.08000000"",""multicurrency_total_tva"":""0.22000000"",""multicurrency_total_ttc"":""1.30000000""}},""type"":""0"",""date"":1737068400,""total_ht"":""2.33000000"",""total_tva"":""0.47000000"",""total_ttc"":""2.80000000"",""revenuestamp"":""0.00000000""}";"24.0.0-alpha";"V2";"fc5c19832334b5c00d7cc3a4414a5ca37867fa9ee5c367c921324aaebd0f81de";"Valid";
;"437";"1737102993";"DOC_PREVIEW";"takepos";"2.33";"2.8";"TC2-2501-0001";"1737068400";"Alice Adminson";"";"";"{""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""TC2-2501-0001"",""module_source"":""takepos"",""pos_source"":""2"",""pos_print_counter"":2,""email_sent_counter"":""0"",""invoiceline"":{""1"":{""ref"":""POS-APPLE"",""product_type"":""0"",""product_label"":""Apple"",""qty"":""1"",""subprice"":""1.25000000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.50000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.25000000"",""multicurrency_total_tva"":""0.25000000"",""multicurrency_total_ttc"":""1.50000000""},""2"":{""ref"":""POS-KIWI"",""product_type"":""0"",""product_label"":""Kiwi"",""qty"":""1"",""subprice"":""1.08333000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.08000000"",""total_tva"":""0.22000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.30000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.08000000"",""multicurrency_total_tva"":""0.22000000"",""multicurrency_total_ttc"":""1.30000000""}},""type"":""0"",""date"":1737068400,""total_ht"":""2.33000000"",""total_tva"":""0.47000000"",""total_ttc"":""2.80000000"",""revenuestamp"":""0.00000000""}";"24.0.0-alpha";"V2";"91cf7545174270befeb93fcefb67acb2f07525c7d73a190eee76936cfa7dfd7d";"Valid";
;"438";"1737104486";"BILL_SENTBYMAIL";"takepos";"2.33";"2.8";"TC2-2501-0001";"1737068400";"Alice Adminson";"";"";"{""mycompany"":{""name"":""MyBigCompany"",""phone"":""09123123"",""fax"":""09123124"",""email"":""myemail@mybigcompany.com"",""idprof1"":""123456"",""idprof2"":""ABC-DEF"",""idprof3"":""15E-45-8D"",""tva_assuj"":1,""tva_intra"":""FR12345678"",""localtax1_assuj"":0,""localtax2_assuj"":0,""managers"":""Zack Zeceo"",""capital"":10000,""forme_juridique_code"":0,""country_code"":""FR"",""address"":""21 Jump street."",""zip"":""75500"",""town"":""MyTown""},""ref"":""TC2-2501-0001"",""module_source"":""takepos"",""pos_source"":""2"",""pos_print_counter"":""2"",""email_sent_counter"":1,""invoiceline"":{""1"":{""ref"":""POS-APPLE"",""product_type"":""0"",""product_label"":""Apple"",""qty"":""1"",""subprice"":""1.25000000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.25000000"",""total_tva"":""0.25000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.50000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.25000000"",""multicurrency_total_tva"":""0.25000000"",""multicurrency_total_ttc"":""1.50000000""},""2"":{""ref"":""POS-KIWI"",""product_type"":""0"",""product_label"":""Kiwi"",""qty"":""1"",""subprice"":""1.08333000"",""tva_tx"":""20.000"",""localtax1_tx"":""0.000"",""localtax2_tx"":""0.000"",""total_ht"":""1.08000000"",""total_tva"":""0.22000000"",""total_localtax1"":""0.00000000"",""total_localtax2"":""0.00000000"",""total_ttc"":""1.30000000"",""info_bits"":""0"",""special_code"":""0"",""multicurrency_code"":""EUR"",""multicurrency_total_ht"":""1.08000000"",""multicurrency_total_tva"":""0.22000000"",""multicurrency_total_ttc"":""1.30000000""}},""type"":""0"",""date"":1737068400,""total_ht"":""2.33000000"",""total_tva"":""0.47000000"",""total_ttc"":""2.80000000"",""revenuestamp"":""0.00000000"",""action_email_sent"":{""email_from"":""Alice Adminson <laurent@destailleur.fr>"",""email_to"":""Generic customer <ttt@ttt.com>"",""email_msgid"":""678a1c6608cdb4.28637446.phpmail-dolibarr-inv461@cc385f40e47e5be82815b1fa583939f749c7f86e""}}";"24.0.0-alpha";"V2";"7ebd906d6133f5526411664bc637ad88fc5d30bd147d4e6dcfc460520144411f";"Valid";
END - sha256=14290f951be42f11da5b36274cdbb9d018ea1787855c19c92f317152bf7bb9e6 - hmac_sha256=851ac6dc40c60faf69efeb4ef6712abacfffe5a986c674ca478f8c1525a126eb
Can't render this file because it has a wrong number of fields in line 23.

View File

@@ -1,5 +1,6 @@
#!/bin/bash
# Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
# Copyright (C) 2010-2026 Laurent Destailleur <eldy@users.sourceforge.net>
# Copyright (C) 2024-2026 MDW <mdeweerd@users.noreply.github.com>
#------------------------------------------------------
# Script to purge and initialize a database with demo values.
@@ -11,8 +12,8 @@
# Regis Houssin - regis.houssin@inodbox.com
# Laurent Destailleur - eldy@users.sourceforge.net
#------------------------------------------------------
# Usage: initdemo.sh confirm
# usage: initdemo.sh confirm mysqldump_dolibarr_x.x.x.sql database port login pass
# Usage: initdemo.sh confirm|confirmresetblockedlog
# usage: initdemo.sh confirm|confirmresetblockedlog mysqldump_dolibarr_x.x.x.sql database port login pass
#------------------------------------------------------
@@ -43,12 +44,12 @@ admin=$5
passwd=$6
# ----------------------------- check params
if [ "$confirm" != "confirm" ]
if [ "$confirm" != "confirm" ] && [ "$confirm" != "confirmresetblockedlog" ]
then
echo "----- $0 -----"
echo "Usage: initdemo.sh confirm "
echo "Usage: initdemo.sh confirm|confirmresetblockedlog "
echo " or"
echo "Usage: initdemo.sh confirm [mysqldump_dolibarr_x.x.x.sql database port login pass]"
echo "Usage: initdemo.sh confirm|confirmresetblockedlog [mysqldump_dolibarr_x.x.x.sql database port login pass]"
exit
fi
@@ -91,7 +92,7 @@ then
fichtemp=$(mktemp 2>/dev/null) || fichtemp=/tmp/test$$
# shellcheck disable=2064,2172
trap "rm -f '$fichtemp'" 0 1 2 5 15
$DIALOG --title "Init Dolibarr with demo values" --clear --inputbox "Mysql database name :" 16 55 $base 2> "$fichtemp"
$DIALOG --title "Init Dolibarr with demo values" --clear --inputbox "Mysql database name :" 16 55 "$base" 2> "$fichtemp"
valret=$?
case $valret in
0)
@@ -107,7 +108,7 @@ then
fichtemp=$(mktemp 2>/dev/null) || fichtemp=/tmp/test$$
# shellcheck disable=2064,2172
trap "rm -f '$fichtemp'" 0 1 2 5 15
$DIALOG --title "Init Dolibarr with demo values" --clear --inputbox "Mysql port (ex: 3306):" 16 55 $port 2> "$fichtemp"
$DIALOG --title "Init Dolibarr with demo values" --clear --inputbox "Mysql port (ex: 3306):" 16 55 "$port" 2> "$fichtemp"
valret=$?
case $valret in
@@ -161,7 +162,7 @@ then
# ---------------------------- confirmation
$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 : --hidden--" 15 55
$DIALOG --title "Erase 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 : --hidden--" 15 55
case $? in
0) echo "Ok, start process..." ;;
@@ -172,7 +173,7 @@ then
fi
# ---------------------------- run sql file
# ---------------------------- Run sql file
if [ "$passwd" != "" ]
then
export passwd="-p$passwd"
@@ -181,8 +182,11 @@ fi
#echo "mysql -P$port -u$admin $passwd $base < $mydir/$dumpfile"
#mysql -P$port -u$admin $passwd $base < $mydir/$dumpfile
#echo "drop old table"
echo "drop table"
echo "drop table if exists llx_accounting_account;"
echo "drop table if exists llx_accounting_account;" | mysql "-P$port" "-u$admin" "$passwd" "$base"
echo "drop table if exists llx_accounting_system;"
echo "drop table if exists llx_accounting_system;" | mysql "-P$port" "-u$admin" "$passwd" "$base"
echo "mysql -P$port -u$admin $passwdshown $base < '$mydir/$dumpfile'"
mysql "-P$port" "-u$admin" "$passwd" "$base" < "$mydir/$dumpfile"
export res=$?
@@ -192,10 +196,24 @@ if [ $res -ne 0 ]; then
exit
fi
# ---------------------------- Run update of demo data
echo
echo Run script updatedemo.php confirm
"$mydir/updatedemo.php" confirm
export res=$?
# ---------------------------- copy demo files
# ---------------------------- Run update of demo data
if [ "$confirm" == "confirmresetblockedlog" ]; then
echo
echo Run script updatedemo.php confirmresetblockedlog
"$mydir/updatedemo.php" confirmresetblockedlog
export res=$?
fi
# ---------------------------- Copy demo files
export documentdir
# shellcheck disable=2016
documentdir=$(< "$mydir/../../htdocs/conf/conf.php" grep '^\$dolibarr_main_data_root' | sed -e 's/$dolibarr_main_data_root=//' | sed -e 's/;//' | sed -e "s/'//g" | sed -e 's/"//g')
@@ -246,8 +264,8 @@ fi
if [ "$res" = "0" ]
then
echo "Success, file successfully loaded."
echo "Success, file successfully loaded: Note that crypted data need to have dolibarr_main_instance_unique_id=11f3c81e86fc9e3b3fd11d81c9a31bd0 with this data set to be readable."
else
echo "Error, load failed."
echo "Error, 1 step of script has failed."
fi
echo

File diff suppressed because one or more lines are too long

View File

@@ -1,4 +1,6 @@
#!/bin/sh
#!/bin/bash
# Copyright (C) 2010-2026 Laurent Destailleur <eldy@users.sourceforge.net>
#------------------------------------------------------
# Script to extract a database with demo values.
# Note: "dialog" tool need to be available if no parameter provided.
@@ -11,26 +13,28 @@
#------------------------------------------------------
# shellcheck disable=2012,2006,2034,2046,2064,2086,2155,2166,2186,2172,2268
export mydir=`echo "$0" | sed -e 's/savedemo.sh//'`;
if [ "x$mydir" = "x" ]
export mydir
mydir=${0//savedemo.sh/}
if [ "$mydir" = "" ] || [ "$mydir" = "./" ]
then
export mydir="."
fi
export id=`id -u`;
export id
id=$(id -u)
# ----------------------------- check if root
if [ "x$id" != "x0" -a "x$id" != "x1001" ]
if [ "$id" != "0" ] && [ "$id" != "1001" ]
then
echo "Script must be ran as root"
echo "Script must be executed as root"
exit
fi
# ----------------------------- command line params
dumpfile=$1;
base=$2;
port=$3;
base="${2:-dolibarrdemo}"
port="${3:-3306}"
admin=$4;
passwd=$5;
@@ -54,7 +58,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 "Output dump file :" 16 55 $dumpfile 2> $fichtemp
--inputbox "Output dump file :" 16 55 "$dumpfile" 2> $fichtemp
valret=$?
case $valret in
0)
@@ -71,7 +75,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 "Mysql database name :" 16 55 dolibarrdemo 2> $fichtemp
--inputbox "Mysql database name :" 16 55 "$base" 2> $fichtemp
valret=$?
case $valret in
0)
@@ -87,7 +91,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 "Mysql port (ex: 3306):" 16 55 3306 2> $fichtemp
--inputbox "Mysql port (ex: 3306):" 16 55 "$port" 2> $fichtemp
valret=$?
@@ -172,6 +176,7 @@ fi
if [ "x$passwd" != "x" ]
then
export passwd="-p$passwd"
export passwdshown="-p*****"
fi
export list="
--ignore-table=$base.llx_abonne
@@ -347,20 +352,24 @@ export list="
--ignore-table=$base.llx_ultimatepdf
--ignore-table=$base.llx_update_modules
--ignore-table=$base.llx_ventilation_achat
--ignore-table=$base.llx_verifactudolibarr_add_tpls
--ignore-table=$base.llx_verifactudolibarr_facture_log
--ignore-table=$base.llx_verifactudolibarr_messages
--ignore-table=$base.llx_verifactudolibarr_tax_type
--ignore-table=$base.tmp_llx_accouting_account
--ignore-table=$base.tmp_llx_product_batch
--ignore-table=$base.tmp_llx_product_batch2
--ignore-table=$base.tmp_tmp
--ignore-table=$base.tmp_user
"
echo "mysqldump -P$port -u$admin -p***** $list $base > $mydir/$dumpfile"
echo "mysqldump -P$port -u$admin $passwdshown $list $base > $mydir/$dumpfile"
mysqldump -P$port -u$admin $passwd $list $base > $mydir/$dumpfile
export res=$?
if [ "x$res" = "x0" ]
then
echo "Success, file successfully loaded."
echo "Success, file successfully dumped."
else
echo "Error, load failed."
echo "Error, dump failed."
fi
echo

View File

@@ -65,6 +65,7 @@ if (!$res) {
* @var DoliDB $db
*/
include_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php';
include_once DOL_DOCUMENT_ROOT.'/blockedlog/class/blockedlog.class.php';
/*
@@ -101,6 +102,115 @@ $tables = array(
);
if ($confirm == 'regenerate') {
$entity = 1;
$fromrowid = 0;
//$fromrowid = 442;
$block_static = new BlockedLog($db);
$block_static->loadTrackedEvents();
print "TZ=".date_default_timezone_get()."\n";
$db->begin();
// Now restart request with all data, so without the limit(1) in sql request
$sql = "SELECT rowid, entity, date_creation, tms, user_fullname, action, module_source, amounts_taxexcl, amounts, element, fk_object, date_object, ref_object,";
$sql .= " linktoref, linktype, signature, fk_user, object_data, object_version, object_format, debuginfo";
$sql .= " FROM ".MAIN_DB_PREFIX."blockedlog";
$sql .= " WHERE entity = ".((int) $entity);
$sql .= " AND rowid >= ".((int) $fromrowid);
$sql .= " ORDER BY date_creation ASC, rowid ASC"; // Required so later we can use the parameter $previoushash of checkSignature()
$i = 0;
$resql = $db->query($sql);
if ($resql) {
// Make the first fetch to get first line and then get the previous hash.
while ($obj = $db->fetch_object($resql)) {
// We set here all data used into signature calculation (see checkSignature method) and more
// IMPORTANT: We must have here, the same rule for transformation of data than into
// the blockedlog->fetch() method (db->jdate for date, ...)
$block_static->id = $obj->rowid;
$block_static->entity = $obj->entity;
if ($i == 0) {
$tmparray = $block_static->getPreviousHash(0, $block_static->id);
$previoushash = $tmparray['previoushash'];
}
$tz = 'gmt';
if (empty($obj->object_format) || $obj->object_format == 'V1') {
$tz = 'tzserver';
}
$block_static->date_creation = $db->jdate($obj->date_creation, $tz); // jdate(date_creation) is UTC
$block_static->date_modification = $db->jdate($obj->tms, $tz); // jdate(tms) is UTC
$block_static->action = $obj->action;
$block_static->module_source = $obj->module_source;
$block_static->amounts_taxexcl = is_null($obj->amounts_taxexcl) ? null : (float) $obj->amounts_taxexcl; // Database store value with 8 digits, we cut ending 0 them with (flow)
$block_static->amounts = (float) $obj->amounts; // Database store value with 8 digits, we cut ending 0 them with (flow)
$block_static->fk_object = $obj->fk_object; // Not in signature
$block_static->date_object = $db->jdate($obj->date_object, $tz); // jdate(date_object) is UTC
$block_static->ref_object = $obj->ref_object;
$block_static->linktoref = $obj->linktoref;
$block_static->linktype = $obj->linktype;
$block_static->fk_user = $obj->fk_user; // Not in signature
$block_static->user_fullname = $obj->user_fullname;
$block_static->object_data = $block_static->dolDecodeBlockedData($obj->object_data);
// Old hash + Previous fields concatenated = signature
$block_static->signature = $obj->signature;
$block_static->element = $obj->element; // Not in signature
$block_static->object_format = $obj->object_format; // Not in signature.
$block_static->object_version = $obj->object_version; // Not in signature
//$block_static->certified = ($obj->certified == 1); // Not in signature
//var_dump($obj->date_creation, $tz, $block_static->date_creation);
// Build/Check the string for the signature
$signature = $block_static->checkSignature($previoushash, 2);
print "For ROWID ".$obj->rowid." - Previous hash = ".$previoushash."\n";
print "Signature in db: ".$obj->signature." - New calculated: ".$signature['calculatedsignature']."\n";
if ($obj->signature != $signature['calculatedsignature']) {
$tmpsql = "UPDATE ".MAIN_DB_PREFIX."blockedlog SET signature = '".$db->escape($signature['calculatedsignature'])."'";
$tmpsql .= " WHERE rowid = ".((int) $obj->rowid);
print "Update for ROWID ".$obj->rowid." with ".$tmpsql."\n";
$tmpresult = $db->query($tmpsql);
}
$previoushash = $signature['calculatedsignature'];
// Set new previous hash for next fetch
$i++;
// Uncomment to proceed one only
//break;
}
} else {
$error++;
setEventMessages($db->lasterror, null, 'errors');
}
$db->commit();
}
if ($confirm == 'confirm') {
print "Update dates to current year for database name = ".$db->database_name."\n";
@@ -236,7 +346,7 @@ if ($confirm == 'confirmresetblockedlog') {
$db->query($sql);
$sql = "UPDATE ".MAIN_DB_PREFIX."facture SET datef = datec WHERE datef >= NOW()";
$sql = "UPDATE ".MAIN_DB_PREFIX."facture SET datef = datec";
print $sql;
print "\n";
$db->query($sql);
@@ -252,6 +362,12 @@ if ($confirm == 'confirmresetblockedlog') {
print "\n";
$db->query($sql);
$sql = "DELETE FROM ".MAIN_DB_PREFIX."const WHERE name = 'MAIN_FIRST_REGISTRATION_OK_DATE'";
print $sql;
print "\n";
$db->query($sql);
/*
// Delete corrupted record no more used that still exists in demo image but can't exist in a production env
$sql = "DELETE FROM ".MAIN_DB_PREFIX."blockedlog WHERE action LIKE 'PAYMENT_VARIOUS_%'";

View File

@@ -0,0 +1,103 @@
<?php
/* Copyright (C) 2025 Frédéric France <frederic.france@free.fr>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
namespace codesniffer\Sniffs\Dolibarr;
use PHP_CodeSniffer\Sniffs\Sniff;
use PHP_CodeSniffer\Files\File;
/**
* CheckIsModEnabledArgumentSniff
*/
class CheckIsModEnabledArgumentSniff implements Sniff
{
// Nom de la fonction cible
protected $targetFunction = 'ismodenabled';
protected $deprecatedModulesNames = [
'actioncomm' => 'agenda',
'adherent' => 'member',
'adherent_type' => 'member_type',
'banque' => 'bank',
'categorie' => 'category',
'commande' => 'order',
'contrat' => 'contract',
'entrepot' => 'stock',
'expedition' => 'shipping',
'facture' => 'invoice',
'ficheinter' => 'intervention',
'product_fournisseur_price' => 'productsupplierprice',
'product_price' => 'productprice',
'projet' => 'project',
'propale' => 'propal',
'socpeople' => 'contact',
];
/**
* register
*
* @return void
*/
public function register()
{
// We are listening function calls (T_STRING)
return [T_STRING];
}
/**
* process
*
* @param File $phpcsFile file to process
* @param mixed $stackPtr pointer
* @return void
*/
public function process(File $phpcsFile, $stackPtr)
{
$tokens = $phpcsFile->getTokens();
if (strtolower($tokens[$stackPtr]['content']) !== strtolower($this->targetFunction)) {
return;
}
// Check that it is a function call (followed by '(')
$openParen = $phpcsFile->findNext(T_WHITESPACE, $stackPtr + 1, null, true);
if ($tokens[$openParen]['code'] !== T_OPEN_PARENTHESIS) {
return;
}
// We are looking for the first 'useful' token after the parenthesis
$firstArgTokenPtr = $phpcsFile->findNext(T_WHITESPACE, $openParen + 1, null, true);
// If the function is called without arguments (isModEnabled()), we stop
if ($tokens[$firstArgTokenPtr]['code'] === T_CLOSE_PARENTHESIS) {
return;
}
// check value of argument
$argContent = str_replace(["'", '"'], '', $tokens[$firstArgTokenPtr]['content']);
$argCode = $tokens[$firstArgTokenPtr]['code'];
if (array_key_exists($argContent, $this->deprecatedModulesNames)) {
$phpcsFile->addError(
'The function "%s" has deprecated argument ("%s") to replace with "%s".',
$firstArgTokenPtr,
'DeprecatedArgument',
[$tokens[$stackPtr]['content'], $argContent, $this->deprecatedModulesNames[$argContent]]
);
}
}
}

View File

@@ -0,0 +1,112 @@
<?php
/* Copyright (C) 2025 Frédéric France <frederic.france@free.fr>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
namespace codesniffer\Sniffs\Dolibarr;
use PHP_CodeSniffer\Sniffs\Sniff;
use PHP_CodeSniffer\Files\File;
/**
* LanguageOfCommentsSniff
*/
class LanguageOfCommentsSniff implements Sniff
{
// List of words that betray a comment in French
public $frenchWords = [
' additionner ',
' arrondir ',
' avec ',
' calculer ',
' chaine ',
' chaîne ',
' chercher ',
' chiffre ',
' chiffres ',
// ' commande ',
' commandes ',
' compteur ',
' compteurs ',
' contrats ',
' depuis ',
' diviser ',
' donnée ',
' entier ',
// ' facture ', // avoid french name of dolibarr object
' factures ',
' ligne ',
' lignes ',
' modèle ',
' niveau ',
' niveaux ',
' nombre ',
' parametrage ',
' paramétrage ',
' pourcentage ',
' produit ',
' produits ',
' quand ',
' rechercher ',
' sinon ',
' stocker ',
' soustraire ',
' sujet ',
' sujets ',
' suppression ',
' utilisateur ',
' utilisateurs ',
' valeur ',
' valeurs ',
];
/**
* Which tokens to listen ?
* T_COMMENT = comments // or #
* T_DOC_COMMENT_STRING = text in block comments
* @return int[]
*/
public function register()
{
return [
T_COMMENT,
T_DOC_COMMENT_STRING,
];
}
/**
* process
*
* @param File $phpcsFile file to process
* @param mixed $stackPtr pointer
* @return void
*/
public function process(File $phpcsFile, $stackPtr)
{
$tokens = $phpcsFile->getTokens();
$content = $tokens[$stackPtr]['content'];
// Basic cleanup (lowercase for comparison)
$contentLower = strtolower($content);
foreach ($this->frenchWords as $word) {
if (strpos($contentLower, $word) !== false) {
$error = "The comment appears to be in French (word detected: '%s'). Please write in English.";
$data = [trim($word)];
$phpcsFile->addWarning($error, $stackPtr, 'FrenchDetected', $data);
return; // We stop at the first occurrence.
}
}
}
}

View File

@@ -21,6 +21,11 @@
<exclude-pattern>/\.git/</exclude-pattern>
<exclude-pattern>/\.cache/</exclude-pattern>
<!-- Custom rules -->
<config name="installed_paths" value="/dev/setup/codesniffer" />
<rule ref="codesniffer.Dolibarr.LanguageOfComments"/>
<rule ref="codesniffer.Dolibarr.CheckIsModEnabledArgument"/>
<!-- List of all tests -->
@@ -31,12 +36,12 @@
<!-- Rules from Generic Standard -->
<!--
<rule ref="PSR12.Files.OpenTag">
<properties>
<property name="ignoreIndent" value="true"/>
</properties>
</rule>
<properties>
<property name="ignoreIndent" value="true"/>
</properties>
</rule>
<exclude name="PSR12.WhiteSpace.ScopeIndent"/>
-->
-->
<!-- We want to allow empty statement: It allows to put some code comments into the else for examples -->
<rule ref="Generic.CodeAnalysis.EmptyStatement">
@@ -76,16 +81,16 @@
<severity>0</severity>
</rule>
<!-- Lower severity on warnings we do not want to show in the pre-commit reports -->
<rule ref="Generic.Files.LineLength.TooLong">
<!-- Lower severity on warnings we do not want to show in the pre-commit reports -->
<rule ref="Generic.Files.LineLength.TooLong">
<severity>4</severity>
</rule>
<rule ref="Generic.Metrics.CyclomaticComplexity.TooHigh">
</rule>
<rule ref="Generic.Metrics.CyclomaticComplexity.TooHigh">
<severity>4</severity>
</rule>
<rule ref="Generic.Metrics.NestingLevel.TooHigh">
</rule>
<rule ref="Generic.Metrics.NestingLevel.TooHigh">
<severity>4</severity>
</rule>
</rule>
<!-- Warnings on TODO -->

View File

@@ -1,18 +1,18 @@
# Fail2Ban configuration file
#
# Regexp to detect try to check a couple login/password so we can add mitigation
# on IP making too much tries.
# Regexp to detect try to check a couple login/password so we can add mitigation on IPs making too much tries.
[Definition]
# To test, you can inject this example into log
# echo `date +'%Y-%m-%d %H:%M:%S'`" INFO 1.2.3.4 functions_dolibarr::check_user_password_abcd Authentication KO" >> /mypath/documents/dolibarr.log
# echo `date +'%Y-%m-%d %H:%M:%S'`" INFO 1.2.3.4 1234567 33 functions_dolibarr::check_user_password_abcd Authentication KO" >> /mypath/documents/dolibarr.log
#
# then
# fail2ban-client status web-dol-bruteforce
# fail2ban-client status web-dolibarr-bruteforce
#
# To test rule file on a existing log file
# fail2ban-regex /mypath/documents/dolibarr.log /etc/fail2ban/filter.d/web-dolibarr-rulesbruteforce.conf --print-all-matched
failregex = ^ [A-Z\s]+ <HOST>\s+functions_.*::check_user_.* Authentication KO
failregex = ^ [A-Z\s]+ <HOST>\s.*functions_.*::check_user_.* Authentication KO
ignoreregex =

View File

@@ -7,6 +7,7 @@
# To test, you can inject this example into log
# echo `date +'%Y-%m-%d %H:%M:%S'`" INFO 1.2.3.4 Hack attempt detected - xxx" >> /mypath/documents/dolibarr.log
# echo `date +'%Y-%m-%d %H:%M:%S'`" INFO 1.2.3.4 1234567 33 Hack attempt detected - xxx" >> /mypath/documents/dolibarr.log
#
# then
# fail2ban-client status web-dolibarr-hackattempt
@@ -14,5 +15,5 @@
# To test rule file on a existing log file
# fail2ban-regex /mypath/documents/dolibarr.log /etc/fail2ban/filter.d/web-dolibarr-hackattempt.conf --print-all-matched
failregex = ^ [A-Z\s]+ <HOST>\s+Hack attempt detected
failregex = ^ [A-Z\s]+ <HOST>\s.*Hack attempt detected
ignoreregex =

View File

@@ -6,7 +6,8 @@
[Definition]
# To test, you can inject this example into log
# echo `date +'%Y-%m-%d %H:%M:%S'`" INFO 1.2.3.4 --- Access to GET /public/clicktodial/cidlookup.php" >> /mypath/documents/dolibarr.log
# echo `date +'%Y-%m-%d %H:%M:%S'`" NOTICE 1.2.3.4 --- Access to GET /public/clicktodial/cidlookup.php" >> /mypath/documents/dolibarr.log
# echo `date +'%Y-%m-%d %H:%M:%S'`" NOTICE 1.2.3.4 1234567 33 --- Access to GET /public/clicktodial/cidlookup.php" >> /mypath/documents/dolibarr.log
#
# then
# fail2ban-client status web-dolibarr-limitpublic
@@ -14,5 +15,5 @@
# To test rule file on a existing log file
# fail2ban-regex /mypath/documents/dolibarr.log /etc/fail2ban/filter.d/web-dolibarr-limitpublic.conf --print-all-matched
failregex = ^ [A-Z\s]+ <HOST>\s+--- Access to .*/public/
failregex = ^ [A-Z\s]+ <HOST>\s.*--- Access to .*/public/
ignoreregex =

View File

@@ -6,7 +6,8 @@
[Definition]
# To test, you can inject this example into log
# echo `date +'%Y-%m-%d %H:%M:%S'`" INFO 1.2.3.4 --- Access to GET /passwordforgotten.php - action=buildnewpassword, massaction=" >> /mypath/documents/dolibarr.log
# echo `date +'%Y-%m-%d %H:%M:%S'`" NOTICE 1.2.3.4 --- Access to GET /passwordforgotten.php - action=buildnewpassword, massaction=" >> /mypath/documents/dolibarr.log
# echo `date +'%Y-%m-%d %H:%M:%S'`" NOTICE 1.2.3.4 1234567 33 --- Access to GET /passwordforgotten.php - action=buildnewpassword, massaction=" >> /mypath/documents/dolibarr.log
#
# then
# fail2ban-client status web-dolibarr-passf
@@ -14,5 +15,5 @@
# To test rule file on a existing log file
# fail2ban-regex /mypath/documents/dolibarr.log /etc/fail2ban/filter.d/web-dolibarr-passf.conf --print-all-matched
failregex = ^ [A-Z\s]+ <HOST>\s+--- Access to .*/passwordforgotten.php - action=buildnewpassword
failregex = ^ [A-Z\s]+ <HOST>\s.*--- Access to .*/passwordforgotten.php - action=buildnewpassword
ignoreregex =

View File

@@ -883,7 +883,7 @@ foreach ($arrayofalerts as $key => $alert) {
// VDP ID
$html .= '<td style="white-space: nowrap">';
if (!empty($alert['issueidvdp'])) {
$html .= '#vdp'.$alert['issueidvdp'];
$html .= '#'.$alert['issueidvdp'];
$arrayofalerts[$key]['description'] .= "\n<br>".'VDP ID #'.$alert['issueidvdp'];
} else {
//$html .= '<span class="opacitymedium">public issue</span>';
@@ -1158,11 +1158,11 @@ function cleanVal2($val)
if (preg_match('/CVE([0-9\-\s]+)/', $tmpval['title'], $reg)) {
$tmpval['issueidcve'] = preg_replace('/^\-/', '', preg_replace('/\s+/', '-', trim($reg[1])));
}
if (preg_match('/#yogosha(\d+)/i', $tmpval['title'], $reg)) {
$tmpval['issueidvdp'] = $reg[1];
if (preg_match('/#(yogosha\d+)/i', $tmpval['title'], $reg)) {
$tmpval['issueidvdp'] = strtolower($reg[1]);
}
if (preg_match('/#ghsa([a-z\-\d]+)/i', $tmpval['title'], $reg)) {
$tmpval['issueidvdp'] = $reg[1];
if (preg_match('/#(ghsa[a-z\-\d]+)/i', $tmpval['title'], $reg)) {
$tmpval['issueidvdp'] = strtolower($reg[1]);
}
return $tmpval;

View File

@@ -9,19 +9,18 @@
*/
return [
// # Issue statistics:
// PhanUndeclaredProperty : 410+ occurrences
// PhanTypeMismatchArgument : 65+ occurrences
// PhanUndeclaredGlobalVariable : 60+ occurrences
// PhanTypeMismatchArgumentNullable : 20+ occurrences
// PhanUndeclaredProperty : 400+ occurrences
// PhanTypeMismatchArgument : 60+ occurrences
// PhanUndeclaredGlobalVariable : 50+ occurrences
// PhanTypeMismatchProperty : 20+ occurrences
// PhanTypeInvalidDimOffset : 15+ occurrences
// PhanTypeInvalidDimOffset : 10+ occurrences
// PhanTypeMismatchDimFetch : 10+ occurrences
// PhanTypeMismatchArgumentNullable : 7 occurrences
// PhanTypeArraySuspiciousNull : 5 occurrences
// PhanTypeExpectedObjectPropAccess : 5 occurrences
// PhanUndeclaredMethod : 5 occurrences
// PhanPluginDuplicateArrayKey : 4 occurrences
// PhanPluginUndeclaredVariableIsset : 2 occurrences
// PhanPossiblyUndeclaredGlobalVariable : 2 occurrences
// PhanTypeMismatchArgumentProbablyReal : 2 occurrences
// PhanParamTooMany : 1 occurrence
// PhanPossiblyUndeclaredVariable : 1 occurrence
@@ -30,7 +29,6 @@ return [
// Currently, file_suppressions and directory_suppressions are the only supported suppressions
'file_suppressions' => [
'htdocs/categories/viewcat.php' => ['PhanUndeclaredProperty'],
'htdocs/comm/action/index.php' => ['PhanTypeMismatchArgument', 'PhanTypeMismatchProperty'],
'htdocs/comm/action/pertype.php' => ['PhanTypeExpectedObjectPropAccess'],
'htdocs/comm/action/peruser.php' => ['PhanTypeMismatchArgument'],
@@ -41,16 +39,12 @@ return [
'htdocs/commande/class/commande.class.php' => ['PhanUndeclaredProperty'],
'htdocs/commande/list.php' => ['PhanUndeclaredProperty'],
'htdocs/commande/list_det.php' => ['PhanTypeInvalidDimOffset'],
'htdocs/compta/bank/account_statement_document.php' => ['PhanUndeclaredGlobalVariable'],
'htdocs/compta/bank/class/account.class.php' => ['PhanUndeclaredProperty'],
'htdocs/compta/bank/class/paymentvarious.class.php' => ['PhanTypeMismatchArgument'],
'htdocs/compta/bank/line.php' => ['PhanUndeclaredGlobalVariable'],
'htdocs/compta/bank/various_payment/card.php' => ['PhanUndeclaredProperty'],
'htdocs/compta/bank/various_payment/document.php' => ['PhanUndeclaredGlobalVariable', 'PhanUndeclaredProperty'],
'htdocs/compta/bank/various_payment/info.php' => ['PhanUndeclaredGlobalVariable', 'PhanUndeclaredProperty'],
'htdocs/compta/clients.php' => ['PhanUndeclaredGlobalVariable'],
'htdocs/compta/facture/card-rec.php' => ['PhanTypeMismatchArgument'],
'htdocs/compta/facture/card.php' => ['PhanUndeclaredProperty'],
'htdocs/compta/facture/class/facture-rec.class.php' => ['PhanUndeclaredProperty'],
'htdocs/compta/facture/class/facture.class.php' => ['PhanUndeclaredProperty'],
'htdocs/compta/localtax/card.php' => ['PhanUndeclaredGlobalVariable'],
@@ -59,7 +53,6 @@ return [
'htdocs/compta/paiement/card.php' => ['PhanUndeclaredProperty'],
'htdocs/compta/paiement/cheque/list.php' => ['PhanTypeMismatchProperty', 'PhanUndeclaredGlobalVariable'],
'htdocs/compta/paiement/rapport.php' => ['PhanTypeMismatchArgument'],
'htdocs/compta/prelevement/card.php' => ['PhanTypeMismatchArgument'],
'htdocs/compta/resultat/clientfourn.php' => ['PhanTypeMismatchArgument'],
'htdocs/compta/resultat/index.php' => ['PhanTypeMismatchArgument'],
'htdocs/compta/resultat/projects.php' => ['PhanTypeMismatchArgument'],
@@ -76,7 +69,7 @@ return [
'htdocs/core/class/CMailFile.class.php' => ['PhanTypeMismatchArgument'],
'htdocs/core/class/canvas.class.php' => ['PhanUndeclaredMethod'],
'htdocs/core/class/cgenericdic.class.php' => ['PhanUndeclaredProperty'],
'htdocs/core/class/commonobject.class.php' => ['PhanParamTooMany', 'PhanTypeMismatchArgument', 'PhanUndeclaredProperty'],
'htdocs/core/class/commonobject.class.php' => ['PhanTypeMismatchArgument', 'PhanUndeclaredProperty'],
'htdocs/core/class/commonpeople.class.php' => ['PhanUndeclaredProperty'],
'htdocs/core/class/conf.class.php' => ['PhanTypeMismatchProperty'],
'htdocs/core/class/ctyperesource.class.php' => ['PhanUndeclaredProperty'],
@@ -101,38 +94,32 @@ return [
'htdocs/core/modules/asset/mod_asset_advanced.php' => ['PhanUndeclaredProperty'],
'htdocs/core/modules/bom/mod_bom_advanced.php' => ['PhanTypeMismatchArgument', 'PhanUndeclaredProperty'],
'htdocs/core/modules/cheque/modules_chequereceipts.php' => ['PhanTypeMismatchArgument'],
'htdocs/core/modules/commande/doc/pdf_einstein.modules.php' => ['PhanTypeMismatchArgumentNullable', 'PhanTypeMismatchDimFetch', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
'htdocs/core/modules/commande/doc/pdf_einstein.modules.php' => ['PhanTypeMismatchDimFetch', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
'htdocs/core/modules/commande/doc/pdf_eratosthene.modules.php' => ['PhanTypeMismatchArgument', 'PhanTypeMismatchDimFetch', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
'htdocs/core/modules/contract/doc/pdf_strato.modules.php' => ['PhanTypeMismatchArgument', 'PhanTypeMismatchArgumentNullable'],
'htdocs/core/modules/delivery/doc/pdf_storm.modules.php' => ['PhanTypeMismatchArgumentNullable'],
'htdocs/core/modules/delivery/doc/pdf_typhon.modules.php' => ['PhanTypeMismatchArgumentNullable'],
'htdocs/core/modules/contract/doc/pdf_strato.modules.php' => ['PhanTypeMismatchArgument'],
'htdocs/core/modules/delivery/mod_delivery_saphir.php' => ['PhanUndeclaredProperty'],
'htdocs/core/modules/expedition/doc/doc_generic_shipment_odt.modules.php' => ['PhanTypeMismatchArgument'],
'htdocs/core/modules/expedition/doc/pdf_espadon.modules.php' => ['PhanTypeMismatchArgument', 'PhanTypeMismatchArgumentNullable'],
'htdocs/core/modules/expedition/doc/pdf_merou.modules.php' => ['PhanTypeMismatchArgumentNullable'],
'htdocs/core/modules/expedition/doc/pdf_rouget.modules.php' => ['PhanTypeMismatchArgumentNullable'],
'htdocs/core/modules/expedition/doc/pdf_espadon.modules.php' => ['PhanTypeMismatchArgument'],
'htdocs/core/modules/expensereport/doc/pdf_standard_expensereport.modules.php' => ['PhanUndeclaredProperty'],
'htdocs/core/modules/facture/doc/pdf_octopus.modules.php' => ['PhanTypeMismatchArgument', 'PhanUndeclaredProperty'],
'htdocs/core/modules/fichinter/doc/pdf_soleil.modules.php' => ['PhanTypeMismatchArgumentNullable'],
'htdocs/core/modules/facture/doc/pdf_octopus.modules.php' => ['PhanTypeMismatchArgument', 'PhanTypeMismatchArgumentNullable', 'PhanUndeclaredProperty'],
'htdocs/core/modules/holiday/mod_holiday_immaculate.php' => ['PhanTypeMismatchArgument'],
'htdocs/core/modules/hrm/mod_evaluation_advanced.php' => ['PhanUndeclaredProperty'],
'htdocs/core/modules/import/import_csv.modules.php' => ['PhanPossiblyUndeclaredVariable'],
'htdocs/core/modules/member/modules_cards.php' => ['PhanTypeMismatchArgument'],
'htdocs/core/modules/mrp/doc/pdf_vinci.modules.php' => ['PhanUndeclaredProperty'],
'htdocs/core/modules/mrp/mod_mo_advanced.php' => ['PhanUndeclaredProperty'],
'htdocs/core/modules/oauth/github_oauthcallback.php' => ['PhanUndeclaredGlobalVariable'],
'htdocs/core/modules/project/doc/doc_generic_project_odt.modules.php' => ['PhanUndeclaredProperty'],
'htdocs/core/modules/project/task/doc/doc_generic_task_odt.modules.php' => ['PhanUndeclaredProperty'],
'htdocs/core/modules/propale/doc/pdf_azur.modules.php' => ['PhanTypeMismatchArgumentNullable', 'PhanUndeclaredProperty'],
'htdocs/core/modules/propale/doc/pdf_cyan.modules.php' => ['PhanTypeMismatchArgumentNullable', 'PhanUndeclaredProperty'],
'htdocs/core/modules/reception/doc/pdf_squille.modules.php' => ['PhanTypeMismatchArgumentNullable', 'PhanUndeclaredProperty'],
'htdocs/core/modules/propale/doc/pdf_azur.modules.php' => ['PhanUndeclaredProperty'],
'htdocs/core/modules/propale/doc/pdf_cyan.modules.php' => ['PhanUndeclaredProperty'],
'htdocs/core/modules/reception/doc/pdf_squille.modules.php' => ['PhanUndeclaredProperty'],
'htdocs/core/modules/stocktransfer/doc/pdf_eagle.modules.php' => ['PhanUndeclaredProperty'],
'htdocs/core/modules/stocktransfer/mod_stocktransfer_advanced.php' => ['PhanUndeclaredProperty'],
'htdocs/core/modules/supplier_invoice/doc/pdf_canelle.modules.php' => ['PhanTypeMismatchArgumentNullable', 'PhanTypeMismatchProperty'],
'htdocs/core/modules/supplier_order/doc/pdf_cornas.modules.php' => ['PhanTypeMismatchArgumentNullable', 'PhanTypeMismatchDimFetch', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
'htdocs/core/modules/supplier_order/doc/pdf_muscadet.modules.php' => ['PhanTypeMismatchArgumentNullable', 'PhanTypeMismatchDimFetch', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
'htdocs/core/modules/supplier_proposal/doc/pdf_aurore.modules.php' => ['PhanTypeMismatchArgumentNullable', 'PhanTypeMismatchDimFetch', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
'htdocs/core/modules/supplier_proposal/doc/pdf_zenith.modules.php' => ['PhanTypeMismatchArgumentNullable', 'PhanTypeMismatchDimFetch', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
'htdocs/core/modules/supplier_invoice/doc/pdf_canelle.modules.php' => ['PhanTypeMismatchProperty'],
'htdocs/core/modules/supplier_order/doc/pdf_cornas.modules.php' => ['PhanTypeMismatchDimFetch', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
'htdocs/core/modules/supplier_order/doc/pdf_muscadet.modules.php' => ['PhanTypeMismatchDimFetch', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
'htdocs/core/modules/supplier_proposal/doc/pdf_aurore.modules.php' => ['PhanTypeMismatchDimFetch', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
'htdocs/core/modules/supplier_proposal/doc/pdf_zenith.modules.php' => ['PhanTypeMismatchDimFetch', 'PhanTypeMismatchProperty', 'PhanUndeclaredProperty'],
'htdocs/core/modules/syslog/mod_syslog_file.php' => ['PhanPluginDuplicateArrayKey'],
'htdocs/core/modules/workstation/mod_workstation_advanced.php' => ['PhanUndeclaredProperty'],
'htdocs/core/multicompany_page.php' => ['PhanTypeMismatchArgument'],
@@ -146,7 +133,6 @@ return [
'htdocs/delivery/class/delivery.class.php' => ['PhanUndeclaredProperty'],
'htdocs/emailcollector/class/emailcollector.class.php' => ['PhanUndeclaredProperty'],
'htdocs/eventorganization/class/conferenceorboothattendee.class.php' => ['PhanUndeclaredMethod', 'PhanUndeclaredProperty'],
'htdocs/eventorganization/core/actions_massactions_mail.inc.php' => ['PhanUndeclaredProperty'],
'htdocs/expedition/card.php' => ['PhanUndeclaredGlobalVariable', 'PhanUndeclaredProperty'],
'htdocs/expedition/class/expedition.class.php' => ['PhanUndeclaredProperty'],
'htdocs/expensereport/card.php' => ['PhanUndeclaredProperty'],
@@ -235,16 +221,15 @@ return [
'htdocs/salaries/virement_request.php' => ['PhanUndeclaredProperty'],
'htdocs/societe/ajax/company.php' => ['PhanUndeclaredProperty'],
'htdocs/societe/class/societe.class.php' => ['PhanTypeMismatchProperty'],
'htdocs/societe/paymentmodes.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanTypeMismatchArgument'],
'htdocs/societe/paymentmodes.php' => ['PhanTypeMismatchArgument'],
'htdocs/supplier_proposal/card.php' => ['PhanUndeclaredGlobalVariable', 'PhanUndeclaredProperty'],
'htdocs/supplier_proposal/class/api_supplier_proposals.class.php' => ['PhanUndeclaredProperty'],
'htdocs/supplier_proposal/class/supplier_proposal.class.php' => ['PhanUndeclaredProperty'],
'htdocs/takepos/invoice.php' => ['PhanPossiblyUndeclaredGlobalVariable', 'PhanUndeclaredGlobalVariable'],
'htdocs/takepos/invoice.php' => ['PhanUndeclaredGlobalVariable'],
'htdocs/takepos/split.php' => ['PhanPluginUndeclaredVariableIsset'],
'htdocs/ticket/card.php' => ['PhanUndeclaredProperty'],
'htdocs/ticket/class/actions_ticket.class.php' => ['PhanUndeclaredProperty'],
'htdocs/ticket/class/cticketcategory.class.php' => ['PhanUndeclaredProperty'],
'htdocs/ticket/class/ticket.class.php' => ['PhanUndeclaredProperty'],
'htdocs/user/class/user.class.php' => ['PhanTypeMismatchArgumentNullable', 'PhanUndeclaredProperty'],
'htdocs/user/class/usergroup.class.php' => ['PhanUndeclaredProperty'],
'htdocs/variants/tpl/productattributevalueline_edit.tpl.php' => ['PhanUndeclaredProperty'],
@@ -253,7 +238,6 @@ return [
'htdocs/webhook/target_card.php' => ['PhanUndeclaredGlobalVariable'],
'htdocs/webportal/admin/setup.php' => ['PhanTypeMismatchArgument'],
'htdocs/webportal/class/html.formlistwebportal.class.php' => ['PhanUndeclaredProperty'],
'htdocs/webportal/class/webportalpropal.class.php' => ['PhanUndeclaredProperty'],
'htdocs/webservices/server_project.php' => ['PhanUndeclaredProperty'],
],
// 'directory_suppressions' => ['src/directory_name' => ['PhanIssueName1', 'PhanIssueName2']] can be manually added if needed.

View File

@@ -227,6 +227,24 @@ return [
'backward_compatibility_checks' => false,
'simplify_ast' => true,
'analyzed_file_extensions' => ['php','inc'],
/*'included_extension_subset' => [
'curl',
'dom',
'filter',
'gd',
'imap',
'intl',
'json',
'libxml',
'mbstring',
'mysqli',
'opcache',
'openssl',
'session',
'sqlite3',
'xml',
'zip'
],*/
'globals_type_map' => [
'_Avery_Labels' => 'array<string,array{name:string,paper-size:string|array{0:float,1:float},orientation:string,metric:string,marginLeft:float,marginTop:float,NX:int,NY:int,SpaceX:float,SpaceY:float,width:float,height:float,font-size:int,custom_x:float,custom_y:float}>',
'action' => 'string',
@@ -439,6 +457,7 @@ return [
'PhanTypeObjectUnsetDeclaredProperty',
'PhanTypePossiblyInvalidDimOffset', // a lot of false positive, in most cases, we want to keep the code as it is
// 'PhanPluginUnknownArrayFunctionReturnType', // a lot of false positive, in most cases, we want to keep the code as it is
'PhanTypeMismatchArgumentSuperType', // a lot of false positive, in most cases, we want to keep the code as it is
'PhanPluginWhitespaceTab', // Dolibarr uses tabs
'PhanPluginCanUsePHP71Void', // Dolibarr is maintaining 7.0 compatibility

View File

@@ -74,6 +74,7 @@ $config['suppress_issue_types'] = [
'PhanTypeObjectUnsetDeclaredProperty',
'PhanTypePossiblyInvalidDimOffset', // a lot of false positive, in most cases, we want to keep the code as it is
'PhanPluginUnknownArrayFunctionReturnType', // a lot of false positive, in most cases, we want to keep the code as it is
'PhanTypeMismatchArgumentSuperType', // a lot of false positive, in most cases, we want to keep the code as it is
'PhanPluginWhitespaceTab', // Dolibarr used tabs
'PhanPluginCanUsePHP71Void', // Dolibarr is maintaining 7.0 compatibility

View File

@@ -76,6 +76,8 @@ parameters:
- '#Empty array passed to foreach#'
- '#Unable to resolve the template type T#'
- '#in empty\(\) always exists and is always falsy#'
- '#in empty\(\) always exists and is not falsy#'
- '#in isset\(\) is not nullable#'
- '#is always#'
internalErrorsCountLimit: 50
cache:

View File

@@ -23,7 +23,7 @@
# - Some side effects from translations on variables.
# - Some other minors side effects to be examined (#, %).
#
# Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
# Copyright (C) 2024-2026 MDW <mdeweerd@users.noreply.github.com>
LANG_DIR=htdocs/langs/en_US/
MYDIR=$(dirname "$(realpath "$0")")
@@ -141,10 +141,10 @@ sed -n 's@< \(.*\)@^\1\\s*=@p' \
#
REPL_STR=""
for t in trans transnoentities transnoentitiesnoconv newItem buttonsSaveCancel; do
REPL_STR="${REPL_STR}\n->${t}(\"\\1\","
REPL_STR="${REPL_STR}\n->${t}('\\1',"
REPL_STR="${REPL_STR}\n->${t}(\"\\1\")"
REPL_STR="${REPL_STR}\n->${t}('\\1')"
REPL_STR="${REPL_STR}\n->${t}(\"\\1\","
REPL_STR="${REPL_STR}\n->${t}('\\1',"
REPL_STR="${REPL_STR}\n->${t}(\"\\1\")"
REPL_STR="${REPL_STR}\n->${t}('\\1')"
done
rm -f "${MISSING_FILE}.grep" >/dev/null 2>&1

View File

@@ -100,7 +100,7 @@ if (!$sortorder) {
$object = new AccountingAccount($db);
$arrayfields = array(
'aa.account_number' => array('label' => "AccountNumber", 'checked' => '1', 'csslist' => 'maxwidth50'),
'aa.account_number' => array('label' => "AccountNumber", 'checked' => '1'),
'aa.label' => array('label' => "Label", 'checked' => '1'),
'aa.labelshort' => array('label' => "ShortLabel", 'checked' => '1'),
'aa.account_parent' => array('label' => "Accountparent", 'checked' => '1'),
@@ -527,10 +527,10 @@ if ($resql) {
print '</td>';
}
if (!empty($arrayfields['aa.account_number']['checked'])) {
print '<td class="liste_titre"><input type="text" class="flat width75" name="search_account" value="'.$search_account.'"></td>';
print '<td class="liste_titre"><input type="text" class="flat width100" name="search_account" value="'.$search_account.'"></td>';
}
if (!empty($arrayfields['aa.label']['checked'])) {
print '<td class="liste_titre"><input type="text" class="flat width100" name="search_label" value="'.$search_label.'"></td>';
print '<td class="liste_titre"><input type="text" class="flat width150" name="search_label" value="'.$search_label.'"></td>';
}
if (!empty($arrayfields['aa.labelshort']['checked'])) {
print '<td class="liste_titre"><input type="text" class="flat width100" name="search_labelshort" value="'.$search_labelshort.'"></td>';

View File

@@ -11,8 +11,8 @@
* Copyright (C) 2011-2026 Alexandre Spangaro <alexandre@inovea-conseil.com>
* Copyright (C) 2015 Ferran Marcet <fmarcet@2byte.es>
* Copyright (C) 2016 Raphaël Doursenaud <rdoursenaud@gpcsolutions.fr>
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024-2025 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024-2026 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024-2026 MDW <mdeweerd@users.noreply.github.com>
*
* 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
@@ -196,7 +196,7 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) {
setEventMessages($langs->transnoentities("ErrorFieldRequired", $langs->transnoentities("Country")), null, 'errors');
}
// Si verif ok et action add, on ajoute la ligne
// In case of 'actionadd' and with valid parameters, add the line
if ($ok && GETPOST('actionadd', 'alpha')) {
$newid = 0;
@@ -241,11 +241,11 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) {
}
}
// Si verif ok et action modify, on modifie la ligne
// In case of 'actionmodify' and with valid parameters, modify the line
if ($ok && GETPOST('actionmodify', 'alpha')) {
// Modify entry
$sql = "UPDATE ".$db->sanitize($tabname[$id])." SET ";
// Modifie valeur des champs
// Change field's value
$i = 0;
foreach ($listfieldmodify as $field) {
@@ -268,7 +268,6 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) {
$sql .= " WHERE rowid = ".((int) $rowid);
dol_syslog("actionmodify", LOG_DEBUG);
//print $sql;
$resql = $db->query($sql);
if (!$resql) {
setEventMessages($db->error(), null, 'errors');
@@ -327,13 +326,13 @@ $linkback = '';
print load_fiche_titre($titre, $linkback, 'title_accountancy');
// Confirmation de la suppression de la ligne
// Confirmation of line deletion
if ($action == 'delete') {
print $form->formconfirm(dolBuildUrl($_SERVER["PHP_SELF"], ['page'=> $page, 'sortfield' => $sortfield, 'sortorder' => $sortorder, 'rowid' => $rowid, 'code' => $code, 'id' => $id]), $langs->trans('DeleteLine'), $langs->trans('ConfirmDeleteLine'), 'confirm_delete', '', 0, 1);
}
// Complete requete recherche valeurs avec critere de tri
// Complete the values search query with the sort order
$sql = $tabsql[$id];
if ($search_country_id > 0) {
@@ -351,7 +350,6 @@ if ($sortfield == 'country') {
}
$sql .= $db->order($sortfield, $sortorder);
$sql .= $db->plimit($listlimit + 1, $offset);
//print $sql;
$fieldlist = explode(',', $tabfield[$id]);
@@ -368,8 +366,8 @@ $fieldlist = explode(',', $tabfield[$id]);
// Line for title
print '<tr class="liste_titre">';
foreach ($fieldlist as $field => $value) {
// Determine le nom du champ par rapport aux noms possibles
// dans les dictionnaires de donnees
// Determine the field name based on the possible names
// in the data dictionaries
$valuetoshow = ucfirst($fieldlist[$field]); // By default
$valuetoshow = $langs->trans($valuetoshow); // try to translate
$class = "left";
@@ -393,7 +391,6 @@ foreach ($fieldlist as $field => $value) {
if ($fieldlist[$field] == 'pcg_version' || $fieldlist[$field] == 'fk_pcg_version') {
$valuetoshow = $langs->trans("Pcg_version");
}
//var_dump($value);
if ($valuetoshow != '') {
print '<td class="'.$class.'">';

View File

@@ -1,8 +1,8 @@
<?php
/* Copyright (C) 2004-2023 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2011-2025 Alexandre Spangaro <alexandre@inovea-conseil.com>
* Copyright (C) 2024-2025 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024-2025 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024-2026 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024-2026 MDW <mdeweerd@users.noreply.github.com>
*
* 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
@@ -209,7 +209,7 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) {
setEventMessages($langs->transnoentities('ErrorFieldMustBeANumeric', $langs->transnoentities("Position")), null, 'errors');
}
// Si verif ok et action add, on ajoute la ligne
// In case of 'actionadd' and with valid parameters, add the line
if ($ok && GETPOST('actionadd', 'alpha')) {
$newid = 0;
@@ -280,7 +280,7 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) {
// Modify entry
$sql = "UPDATE ".$db->sanitize($tabname[$id])." SET ";
// Modifie valeur des champs
// Modify field values
if ($tabrowid[$id] && !in_array($tabrowid[$id], $listfieldmodify)) {
$sql .= $db->sanitize($tabrowid[$id])." = ";
$sql .= "'".$db->escape($rowid)."', ";
@@ -493,8 +493,8 @@ if ($tabname[$id]) {
print '<td></td>';
}
foreach ($fieldlist as $field => $value) {
// Determine le nom du champ par rapport aux noms possibles
// dans les dictionnaires de donnees
// Determine the field name based on the possible names
// in the data dictionaries.
$valuetoshow = ucfirst($fieldlist[$field]); // By default
$valuetoshow = $langs->trans($valuetoshow); // try to translate
$class = "left";

View File

@@ -1,7 +1,7 @@
<?php
/* Copyright (C) 2017-2024 Alexandre Spangaro <aspangaro@easya.solutions>
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024-2025 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024-2026 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024-2026 MDW <mdeweerd@users.noreply.github.com>
*
* 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
@@ -194,7 +194,7 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) {
$ok = 0;
}
// Si verif ok et action add, on ajoute la ligne
// In case of 'actionadd' and with valid parameters, add the line
if ($ok && GETPOST('actionadd', 'alpha')) {
$newid = 0; // Initialise before if for static analysis
if ($tabrowid[$id]) {
@@ -251,7 +251,7 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) {
}
}
// Si verif ok et action modify, on modifie la ligne
// If check ok and action modify, we modify the line
if ($ok && GETPOST('actionmodify', 'alpha')) {
if ($tabrowid[$id]) {
$rowidcol = $tabrowid[$id];
@@ -261,7 +261,7 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) {
// Modify entry
$sql = "UPDATE ".$db->sanitize($tabname[$id])." SET ";
// Modifie valeur des champs
// Modify the field values
if ($tabrowid[$id] && !in_array($tabrowid[$id], $listfieldmodify)) {
$sql .= $db->sanitize($tabrowid[$id])." = ";
$sql .= "'".$db->escape($rowid)."', ";
@@ -373,7 +373,7 @@ $titlepicto = 'title_accountancy';
print load_fiche_titre($titre, $linkback, $titlepicto);
// Confirmation de la suppression de la ligne
// Generate a form to confirm the deletion of the row
if ($action == 'delete') {
print $form->formconfirm($_SERVER["PHP_SELF"].'?'.($page ? 'page='.$page.'&' : '').'sortfield='.$sortfield.'&sortorder='.$sortorder.'&rowid='.$rowid.'&code='.$code.'&id='.$id, $langs->trans('DeleteLine'), $langs->trans('ConfirmDeleteLine'), 'confirm_delete', '', 0, 1);
}
@@ -382,7 +382,7 @@ if ($action == 'delete') {
* Show a dictionary
*/
// Complete requete recherche valeurs avec critere de tri
// Complete the search query with sort criteria
$sql = $tabsql[$id];
$sql .= " WHERE a.entity = ".((int) $conf->entity);
@@ -409,8 +409,8 @@ if ($tabname[$id]) {
// Line for title
print '<tr class="liste_titre">';
foreach ($fieldlist as $field => $value) {
// Determine le nom du champ par rapport aux noms possibles
// dans les dictionnaires de donnees
// Determine the field name based on the possible names
// in the data dictionaries.
$valuetoshow = ucfirst($fieldlist[$field]); // By default
$valuetoshow = $langs->trans($valuetoshow); // try to translate
$class = "left";
@@ -522,8 +522,8 @@ if ($resql) {
// Title of lines
print '<tr class="liste_titre liste_titre_add">';
foreach ($fieldlist as $field => $value) {
// Determine le nom du champ par rapport aux noms possibles
// dans les dictionnaires de donnees
// Determine the field name based on the possible names
// in the data dictionaries.
$class = "left";
$sortable = 1;
$valuetoshow = '';

View File

@@ -552,10 +552,12 @@ if ($resql) {
if ($massaction == 'set_default_account') {
$formquestion = array();
$formquestion[] = array('type' => 'other',
$formquestion[] = array(
'type' => 'other',
'name' => 'set_default_account',
'label' => $langs->trans("AccountancyCode"),
'value' => $form->select_account('', 'default_account', 1, array(), 0, 0, 'maxwidth200 maxwidthonsmartphone', 'cachewithshowemptyone'));
'value' => $form->select_account('', 'default_account', 1, array(), 0, 0, 'maxwidth200 maxwidthonsmartphone', 'cachewithshowemptyone')
);
print $form->formconfirm($_SERVER["PHP_SELF"], $langs->trans("ConfirmPreselectAccount"), $langs->trans("ConfirmPreselectAccountQuestion", $nbselected), "confirm_set_default_account", $formquestion, 1, 0, 200, 500, 1);
}
@@ -662,7 +664,7 @@ if ($resql) {
while ($i < min($num, $limit)) {
$obj = $db->fetch_object($resql);
// Ref produit as link
// Product ref as link
$product_static->ref = $obj->ref;
$product_static->id = $obj->rowid;
$product_static->type = $obj->product_type;
@@ -907,49 +909,48 @@ if ($resql) {
}
print '</table>';
print '</div>';
?>
<script type="text/javascript">
jQuery(document).ready(function() {
function init_savebutton() {
console.log("We check if at least one line is checked")
print '<script type="text/javascript">
jQuery(document).ready(function() {
function init_savebutton()
{
console.log("We check if at least one line is checked")
atleastoneselected = 0;
jQuery(".checkforselect").each(function(index) {
/* console.log( index + ": " + $( this ).text() ); */
if ($(this).is(':checked')) atleastoneselected++;
});
atleastoneselected=0;
jQuery(".checkforselect").each(function( index ) {
/* console.log( index + ": " + $( this ).text() ); */
if ($(this).is(\':checked\')) atleastoneselected++;
});
if (atleastoneselected) jQuery("#changeaccount").removeAttr('disabled');
else jQuery("#changeaccount").attr('disabled', 'disabled');
if (atleastoneselected) jQuery("#changeaccount").attr('class', 'button');
else jQuery("#changeaccount").attr('class', 'button');
}
if (atleastoneselected) jQuery("#changeaccount").removeAttr(\'disabled\');
else jQuery("#changeaccount").attr(\'disabled\',\'disabled\');
if (atleastoneselected) jQuery("#changeaccount").attr(\'class\',\'button\');
else jQuery("#changeaccount").attr(\'class\',\'button\');
}
jQuery(".checkforselect").change(function() {
init_savebutton();
});
jQuery(".productforselect").change(function() {
console.log($(this).attr("id")+" "+$(this).val());
jQuery(".checkforselect").change(function() {
init_savebutton();
});
jQuery(".productforselect").change(function() {
console.log($(this).attr("id") + " " + $(this).val());
if ($(this).val() && $(this).val() != -1) {
$(".productforselect"+$(this).attr("id")).prop(\'checked\', true);
$(".productforselect"+$(this).attr("id")).prop('checked', true);
} else {
$(".productforselect"+$(this).attr("id")).prop(\'checked\', false);
$(".productforselect"+$(this).attr("id")).prop('checked', false);
}
init_savebutton();
});
init_savebutton();
});
init_savebutton();
init_savebutton();
jQuery("#search_current_account").keyup(function() {
if (jQuery("#search_current_account").val() != \'\')
{
console.log("We set a value of account to search "+jQuery("#search_current_account").val()+", so we disable the other search criteria on account");
jQuery("#search_current_account_valid").val(-1);
}
});
});
</script>';
jQuery("#search_current_account").keyup(function() {
if (jQuery("#search_current_account").val() != '') {
console.log("We set a value of account to search " + jQuery("#search_current_account").val() + ", so we disable the other search criteria on account");
jQuery("#search_current_account_valid").val(-1);
}
});
});
</script>
<?php
print '</form>';

View File

@@ -1,6 +1,7 @@
<?php
/* Copyright (C) 2024 Alexandre Spangaro <alexandre@inovea-conseil.com>
* Copyright (C) 2024-2025 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024-2026 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2026 MDW <mdeweerd@users.noreply.github.com>
*
* 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
@@ -183,7 +184,7 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) {
}
}
// Si verif ok et action add, on ajoute la ligne
// In case of 'actionadd' and with valid parameters, add the line
if ($ok && GETPOST('actionadd', 'alpha')) {
$newid = 0;
@@ -254,7 +255,7 @@ if (GETPOST('actionadd', 'alpha') || GETPOST('actionmodify', 'alpha')) {
// Modify entry
$sql = "UPDATE ".$db->sanitize($tabname[$id])." SET ";
// Modifie valeur des champs
// Modify field values
if ($tabrowid[$id] && !in_array($tabrowid[$id], $listfieldmodify)) {
$sql .= $db->sanitize($tabrowid[$id])." = ";
$sql .= "'".$db->escape($rowid)."', ";
@@ -427,8 +428,8 @@ if ($tabname[$id]) {
print '<td></td>';
}
foreach ($fieldlist as $field => $value) {
// Determine le nom du champ par rapport aux noms possibles
// dans les dictionnaires de donnees
// Determine the field name based on the possible names
// in the data dictionaries.
$valuetoshow = ucfirst($fieldlist[$field]); // By default
$valuetoshow = $langs->trans($valuetoshow); // try to translate
$class = "left";

View File

@@ -34,6 +34,7 @@ require_once DOL_DOCUMENT_ROOT.'/accountancy/class/bookkeeping.class.php';
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formaccounting.class.php';
require_once DOL_DOCUMENT_ROOT.'/compta/facture/class/facture.class.php';
require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.facture.class.php';
require_once DOL_DOCUMENT_ROOT.'/expensereport/class/expensereport.class.php';
require_once DOL_DOCUMENT_ROOT.'/accountancy/class/accountingjournal.class.php';
require_once DOL_DOCUMENT_ROOT.'/accountancy/class/accountingaccount.class.php';
require_once DOL_DOCUMENT_ROOT.'/accountancy/class/lettering.class.php';
@@ -738,7 +739,38 @@ if ($action == 'create') {
print '<input type="submit" class="button button-edit smallpaddingimp" value="'.$langs->trans('Modify').'">';
print '</form>';
} else {
print $object->doc_ref;
// Get information of an element
if ($object->doc_type === 'customer_invoice' && !empty($object->fk_doc)) {
$invoicestatic = new Facture($db);
$result = $invoicestatic->fetch($object->fk_doc);
if ($result > 0) {
$label_element = $invoicestatic->getNomUrl(1);
} else {
$label_element = $object->doc_ref;
}
} elseif ($object->doc_type === 'supplier_invoice' && !empty($object->fk_doc)) {
$supplierinvoicestatic = new FactureFournisseur($db);
$result = $supplierinvoicestatic->fetch($object->fk_doc);
if ($result > 0) {
$label_element = $supplierinvoicestatic->getNomUrl(1);
} else {
$label_element = $object->doc_ref;
}
} elseif ($object->doc_type === 'expense_report' && !empty($object->fk_doc)) {
$expensereportstatic = new ExpenseReport($db);
$result = $expensereportstatic->fetch($object->fk_doc);
if ($result > 0) {
$label_element = $expensereportstatic->getNomUrl(1);
} else {
$label_element = $object->doc_ref;
}
} else {
$label_element = $object->doc_ref;
}
print $label_element;
}
print '</td>';
print '</tr>';
@@ -804,7 +836,13 @@ if ($action == 'create') {
print '<input type="submit" class="button button-edit" value="'.$langs->trans('Modify').'">';
print '</form>';
} else {
print $object->code_journal;
// Get information of a journal
$accountingjournalstatic = new AccountingJournal($db);
$accountingjournalstatic->fetch(0, $object->code_journal);
$journal = $accountingjournalstatic->code;
$journal_label = $accountingjournalstatic->label;
print $accountingjournalstatic->getNomUrl(1, 1, 1);
}
print '</td>';
print '</tr>';

View File

@@ -14,7 +14,7 @@
* Copyright (C) 2020 Guillaume Alexandre <guillaume@tag-info.fr>
* Copyright (C) 2022 Joachim Kueter <jkueter@gmx.de>
* Copyright (C) 2022 Progiseize <a.bisotti@progiseize.fr>
* Copyright (C) 2024-2025 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024-2026 MDW <mdeweerd@users.noreply.github.com>
*
* 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
@@ -1391,7 +1391,7 @@ class AccountancyExport
$separator = ';';
$end_line = "\n";
// parcours du tableau pour recuperation des numero de compte des tiers pour pouvoir les fournir dans la bonne ligne pour istea
// Extract the Third party account numbers from the table to provide the correct line for ISTEA
$tiers = [];
foreach ($objectLines as $line) {
if ($line->subledger_account && substr($line->subledger_account, 0, 1) == '4') {
@@ -2752,7 +2752,7 @@ class AccountancyExport
$tab[] = substr($date, 3, 2);
$tab[] = substr($date, 0, 2);
$tab[] = $line->doc_ref;
//Conversion de chaine UTF8 en Latin9
// Convert the UTF-8 string in latin9
$tab[] = mb_convert_encoding(str_replace(' - Compte auxiliaire', '', $line->label_operation), "Windows-1252", 'UTF-8');
//Calcul de la longueur des numéros de comptes

View File

@@ -72,6 +72,11 @@ class AccountingAccount extends CommonObject
*/
public $rowid;
/**
* @var string Ref
*/
public $ref;
/**
* Date creation record (datec)
*

View File

@@ -1,6 +1,6 @@
<?php
/* Copyright (C) 2017-2022 OpenDSI <support@open-dsi.fr>
* Copyright (C) 2024-2025 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024-2026 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024-2025 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024 Alexandre Janniaux <alexandre.janniaux@gmail.com>
* Copyright (C) 2025 Alexandre Spangaro <alexandre@inovea-conseil.com>
@@ -1323,7 +1323,7 @@ class AccountingJournal extends CommonObject
$element['blocks'][] = $lines_book;
}
} else {
// si TVA = 0, pousser les 2 lignes view/bookkeeping déjà constituées
// When VAT = 0, push the 2 lines view/bookkeeping already prepared
if ($type == 'view') {
$element['blocks'][] = $lines_view;
} elseif ($type == 'bookkeeping') {

View File

@@ -1963,7 +1963,7 @@ class BookKeeping extends CommonObject
{
global $conf;
$sql = "SELECT piece_num, ref, doc_date, code_journal, journal_label, doc_ref, doc_type,";
$sql = "SELECT piece_num, ref, doc_date, code_journal, journal_label, doc_ref, doc_type, fk_doc,";
$sql .= " date_creation, tms as date_modification, date_validated as date_validation, date_lim_reglement, import_key";
// In llx_accounting_bookkeeping_tmp, field date_export doesn't exist
if ($mode != "_tmp") {
@@ -1985,6 +1985,7 @@ class BookKeeping extends CommonObject
$this->doc_date = $this->db->jdate($obj->doc_date);
$this->doc_ref = $obj->doc_ref;
$this->doc_type = $obj->doc_type;
$this->fk_doc = $obj->fk_doc;
$this->date_creation = $this->db->jdate($obj->date_creation);
$this->date_modification = $this->db->jdate($obj->date_modification);
if ($mode != "_tmp") {
@@ -2522,7 +2523,7 @@ class BookKeeping extends CommonObject
$alias = !empty($alias) && strpos($alias, '.') === false ? $alias . "." : $alias;
if (!isset(self::$can_modify_bookkeeping_sql_cached[$alias]) || $force) {
$result = $this->loadFiscalPeriods($force, 'active');
$result = $this->loadFiscalPeriods($force, 'active'); // This set $conf->cache['active_fiscal_period_cached']
if ($result < 0) {
return null;
}
@@ -2533,9 +2534,10 @@ class BookKeeping extends CommonObject
foreach ($conf->cache['active_fiscal_period_cached'] as $fiscal_period) {
$sql_list[$i] = "(";
$sql_list[$i] .= "'".$this->db->idate($fiscal_period['date_start']) . "' <= ".$this->db->sanitize($alias)."doc_date";
// @phan-suppress-next-line PhanTypeMismatchDimAssignment
if (!empty($fiscal_period['date_end'])) {
$sql_list[$i] .= " AND ";
$sql_list[$i] .= $this->db->sanitize($alias)."doc_date <= '" . $this->db->idate($fiscal_period['date_end'])."'";
$sql_list[$i] .= $this->db->sanitize($alias)."doc_date <= '" . $this->db->idate((int) $fiscal_period['date_end'])."'";
}
$sql_list[$i] .= ")";
$i++;
@@ -2595,6 +2597,7 @@ class BookKeeping extends CommonObject
}
if (!empty($conf->cache['active_fiscal_period_cached']) && is_array($conf->cache['active_fiscal_period_cached'])) {
foreach ($conf->cache['active_fiscal_period_cached'] as $fiscal_period) {
// @phan-suppress-next-line PhanTypeMismatchDimAssignment
if (!empty($fiscal_period['date_start']) && $fiscal_period['date_start'] <= $bookkeeping->doc_date && (empty($fiscal_period['date_end']) || $bookkeeping->doc_date <= $fiscal_period['date_end'])) {
return 1;
}
@@ -2693,6 +2696,7 @@ class BookKeeping extends CommonObject
if (!empty($conf->cache['active_fiscal_period_cached']) && is_array($conf->cache['active_fiscal_period_cached'])) {
foreach ($conf->cache['active_fiscal_period_cached'] as $fiscal_period) {
// @phan-suppress-next-line PhanTypeMismatchDimAssignment
if (!empty($fiscal_period['date_start']) && $fiscal_period['date_start'] <= $date && (empty($fiscal_period['date_end']) || $date <= $fiscal_period['date_end'])) {
return 1;
}

View File

@@ -2,7 +2,7 @@
/* Copyright (C) 2004-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2013 Olivier Geffroy <jeff@jeffinfo.com>
* Copyright (C) 2013-2024 Alexandre Spangaro <alexandre@inovea-conseil.com>
* Copyright (C) 2018-2024 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2018-2026 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024-2025 MDW <mdeweerd@users.noreply.github.com>
*
* This program is free software; you can redistribute it and/or modify
@@ -824,7 +824,7 @@ class Lettering extends BookKeeping
*
* @param int[] $document_ids List of document id
* @param string $doc_type Type of document ('customer_invoice' or 'supplier_invoice', ...)
* @return array<int,array<int,int>>|int<-1,-1> Return integer <0 if error otherwise all linked document ids by group and type [ [ 'doc_type' => [ doc_id, ... ], ... ], ... ]
* @return array<int,array<int,int>>|int<-1,-1> Return integer <0 if error otherwise all linked document ids by group and type [ [ 'doc_type' => [ doc_id, ... ], ... ], ... ]
*/
public function getLinkedDocumentByGroup($document_ids, $doc_type)
{
@@ -910,7 +910,7 @@ class Lettering extends BookKeeping
/**
* Get element ids grouped by link or element in common
*
* @param array<int,array<string,int>> $link_by_element List of payment ids by link key
* @param array<int,array<string,int|string>> $link_by_element List of payment ids by link key
* @param array<string,array<int,int>> $element_by_link List of element ids by link key
* @param string $link_key Link key (used for recursive function)
* @param array<int,int> $current_group Current group (used for recursive function)

View File

@@ -2191,7 +2191,7 @@ class Adherent extends CommonObject
$now = dol_now();
// Check parameters
if ($this->statut == self::STATUS_VALIDATED) {
if ($this->status == self::STATUS_VALIDATED) {
dol_syslog(get_class($this)."::validate statut of member does not allow this", LOG_WARNING);
return 0;
}
@@ -2208,6 +2208,7 @@ class Adherent extends CommonObject
$result = $this->db->query($sql);
if ($result) {
$this->statut = self::STATUS_VALIDATED;
$this->status = self::STATUS_VALIDATED;
// Call trigger
$result = $this->call_trigger('MEMBER_VALIDATE', $user);
@@ -2231,7 +2232,7 @@ class Adherent extends CommonObject
/**
* Fonction qui resilie un adherent
* Function that terminates a member
*
* @param User $user User making change
* @return int Return integer <0 if KO, >0 if OK
@@ -2243,7 +2244,7 @@ class Adherent extends CommonObject
$error = 0;
// Check parameters
if ($this->statut == self::STATUS_RESILIATED) {
if ($this->status == self::STATUS_RESILIATED) {
dol_syslog(get_class($this)."::resiliate statut of member does not allow this", LOG_WARNING);
return 0;
}
@@ -2258,6 +2259,7 @@ class Adherent extends CommonObject
$result = $this->db->query($sql);
if ($result) {
$this->statut = self::STATUS_RESILIATED;
$this->status = self::STATUS_RESILIATED;
// Call trigger
$result = $this->call_trigger('MEMBER_RESILIATE', $user);
@@ -2291,7 +2293,7 @@ class Adherent extends CommonObject
$error = 0;
// Check parameters
if ($this->statut == self::STATUS_EXCLUDED) {
if ($this->status == self::STATUS_EXCLUDED) {
dol_syslog(get_class($this)."::resiliate statut of member does not allow this", LOG_WARNING);
return 0;
}
@@ -2306,6 +2308,7 @@ class Adherent extends CommonObject
$result = $this->db->query($sql);
if ($result) {
$this->statut = self::STATUS_EXCLUDED;
$this->status = self::STATUS_EXCLUDED;
// Call trigger
$result = $this->call_trigger('MEMBER_EXCLUDE', $user);
@@ -2515,7 +2518,7 @@ class Adherent extends CommonObject
* @param int $save_lastsearch_value -1=Auto, 0=No save of lastsearch_values when clicking, 1=Save lastsearch_values whenclicking
* @param int $notooltip 1=Disable tooltip
* @param int $addlinktonotes 1=Add link to notes
* @return string Chaine avec URL
* @return string String with URL
*/
public function getNomUrl($withpictoimg = 0, $maxlen = 0, $option = 'card', $mode = '', $morecss = '', $save_lastsearch_value = -1, $notooltip = 0, $addlinktonotes = 0)
{
@@ -2746,7 +2749,7 @@ class Adherent extends CommonObject
global $conf, $langs;
if ($user->socid) {
return -1; // protection pour eviter appel par utilisateur externe
return -1; // Protection to prevent calls by external users
}
$now = dol_now();
@@ -2921,7 +2924,7 @@ class Adherent extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore
/**
* Retourne chaine DN complete dans l'annuaire LDAP pour l'objet
* Returns the complete DN (Distinguished Name) string in the LDAP directory for the object
*
* @param array<string,mixed> $info Info array loaded by _load_ldap_info
* @param int<0,2> $mode 0=Return full DN (uid=qqq,ou=xxx,dc=aaa,dc=bbb)
@@ -3147,7 +3150,7 @@ class Adherent extends CommonObject
$sql = "SELECT count(mc.email) as nb";
$sql .= " FROM ".MAIN_DB_PREFIX."mailing_cibles as mc";
$sql .= " WHERE mc.email = '".$this->db->escape($this->email)."'";
$sql .= " AND mc.statut NOT IN (-1,0)"; // -1 erreur, 0 non envoye, 1 envoye avec success
$sql .= " AND mc.statut NOT IN (-1,0)"; // -1 error, 0 not sent, 1 sent with success
$resql = $this->db->query($sql);
if ($resql) {

View File

@@ -6,7 +6,7 @@
* Copyright (C) 2018-2019 Thibault Foucart <support@ptibogxiv.net>
* Copyright (C) 2021 Waël Almoman <info@almoman.com>
* Copyright (C) 2024-2025 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024-2025 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024-2026 MDW <mdeweerd@users.noreply.github.com>
*
* 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
@@ -111,8 +111,10 @@ class AdherentType extends CommonObject
"rowid" => array("type" => "integer", "label" => "Ref", "enabled" => "1", 'position' => 10, 'notnull' => 1, "visible" => "1",),
"libelle" => array("type" => "varchar(50)", "label" => "Label", "enabled" => "1", 'position' => 30, 'notnull' => 1, "visible" => "1", "showoncombobox" => 1),
"subscription" => array("type" => "varchar(3)", "label" => "Subscription", "enabled" => "1", 'position' => 35, 'notnull' => 1, "visible" => "1",),
"amount" => array("type" => "double(24,8)", "label" => "Amount", "enabled" => "1", 'position' => 40, 'notnull' => 0, "visible" => "1",),
"caneditamount" => array("type" => "integer", "label" => "Caneditamount", "enabled" => "1", 'position' => 45, 'notnull' => 0, "visible" => "1",),
"caneditamount" => array("type" => "integer", "label" => "Caneditamount", "enabled" => "1", 'position' => 40, 'notnull' => 0, "visible" => "1",),
"minimumamount" => array("type" => "double(24,8)", "label" => "MinimumAmount", "enabled" => "1", 'position' => 42, 'notnull' => 0, "visible" => "1",),
"amount" => array("type" => "double(24,8)", "label" => "Amount", "enabled" => "1", 'position' => 45, 'notnull' => 0, "visible" => "1",),
"amountformuladescription" => array("type" => "longtext", "label" => "AmountFormulaDescription", "enabled" => "1", 'position' => 46, 'notnull' => 0, "visible" => "1",),
"vote" => array("type" => "varchar(3)", "label" => "Vote", "enabled" => "1", 'position' => 50, 'notnull' => 1, "visible" => "-1",),
"mail_valid" => array("type" => "longtext", "label" => "MailValidation", "enabled" => "1", 'position' => 60, 'notnull' => 0, "visible" => "-3",),
"morphy" => array("type" => "varchar(3)", "label" => "MembersNature", "enabled" => "1", 'position' => 65, 'notnull' => 0, "visible" => "1",),
@@ -160,15 +162,25 @@ class AdherentType extends CommonObject
*/
public $subscription;
/**
* @var int Amount can be chosen by the visitor during subscription (0 or 1)
*/
public $caneditamount;
/**
* @var float|string Minimum Amount for subscription (null or '' means not defined)
*/
public $minimumamount;
/**
* @var float|string Amount for subscription (null or '' means not defined)
*/
public $amount;
/**
* @var int Amount can be chosen by the visitor during subscription (0 or 1)
* @var string Describe the subscription amount formula to follow
*/
public $caneditamount;
public $amountformuladescription;
/**
* @var string Public note
@@ -273,7 +285,7 @@ class AdherentType extends CommonObject
if ($result) {
while ($obj = $this->db->fetch_object($result)) {
//print 'lang='.$obj->lang.' current='.$current_lang.'<br>';
if ($obj->lang == $current_lang) { // si on a les traduct. dans la langue courante on les charge en infos principales.
if ($obj->lang == $current_lang) { // if we have the translations in the current language, we load them as main information.
$this->label = $obj->label;
$this->description = $obj->description;
$this->email = $obj->email;
@@ -495,8 +507,10 @@ class AdherentType extends CommonObject
$sql .= "libelle = '".$this->db->escape($this->label)."',";
$sql .= "morphy = '".$this->db->escape($this->morphy)."',";
$sql .= "subscription = '".$this->db->escape((string) $this->subscription)."',";
$sql .= "amount = ".((empty($this->amount) && $this->amount == '') ? "null" : ((float) $this->amount)).",";
$sql .= "caneditamount = ".((int) $this->caneditamount).",";
$sql .= "minimumamount = ".((empty($this->minimumamount) && $this->minimumamount == '') ? "null" : ((float) $this->minimumamount)).",";
$sql .= "amount = ".((empty($this->amount) && $this->amount == '') ? "null" : ((float) $this->amount)).",";
$sql .= "amountformuladescription = '".$this->db->escape($this->amountformuladescription)."',";
$sql .= "duration = '".$this->db->escape($this->duration_value.$this->duration_unit)."',";
$sql .= "note = '".$this->db->escape($this->note_public)."',";
$sql .= "vote = ".(int) $this->db->escape((string) $this->vote).",";
@@ -586,7 +600,7 @@ class AdherentType extends CommonObject
*/
public function fetch($rowid)
{
$sql = "SELECT d.rowid, d.libelle as label, d.morphy, d.statut as status, d.duration, d.subscription, d.amount, d.caneditamount, d.mail_valid, d.note as note_public, d.vote";
$sql = "SELECT d.rowid, d.libelle as label, d.morphy, d.statut as status, d.duration, d.subscription, d.caneditamount, d.minimumamount, d.amount, d.amountformuladescription, d.mail_valid, d.note as note_public, d.vote";
$sql .= " FROM ".MAIN_DB_PREFIX."adherent_type as d";
$sql .= " WHERE d.rowid = ".(int) $rowid;
@@ -606,8 +620,10 @@ class AdherentType extends CommonObject
$this->duration_value = (int) substr($obj->duration, 0, dol_strlen($obj->duration) - 1);
$this->duration_unit = substr($obj->duration, -1);
$this->subscription = $obj->subscription;
$this->amount = $obj->amount;
$this->caneditamount = $obj->caneditamount;
$this->minimumamount = $obj->minimumamount;
$this->amount = $obj->amount;
$this->amountformuladescription = $obj->amountformuladescription;
$this->mail_valid = $obj->mail_valid;
$this->note = $obj->note_public; // deprecated
$this->note_public = $obj->note_public;
@@ -782,6 +798,80 @@ class AdherentType extends CommonObject
return $caneditamountbytype;
}
/**
* Return the array of all minimum amounts per membership type id
*
* @param int $status Filter on status of type
* @return array<int,float> Array of membership type
*/
public function minimumAmountByType($status = null)
{
$minimumamountbytype = array();
$sql = "SELECT rowid, minimumamount";
$sql .= " FROM ".MAIN_DB_PREFIX."adherent_type";
$sql .= " WHERE entity IN (".getEntity('member_type').")";
if ($status !== null) {
$sql .= " AND statut = ".((int) $status);
}
$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);
$minimumamountbytype[$obj->rowid] = (float) $obj->minimumamount;
$i++;
}
}
} else {
print $this->db->error();
}
return $minimumamountbytype;
}
/**
* Return the array of all amount formula's descriptions per membership type id
*
* @param int $status Filter on status of type
* @return array<int,float> Array of membership type
*/
public function amountFormulaDescriptionByType($status = null)
{
$amountformuladescriptionbytype = array();
$sql = "SELECT rowid, amountformuladescription";
$sql .= " FROM ".MAIN_DB_PREFIX."adherent_type";
$sql .= " WHERE entity IN (".getEntity('member_type').")";
if ($status !== null) {
$sql .= " AND statut = ".((int) $status);
}
$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);
$amountformuladescriptionbytype[$obj->rowid] = $obj->amountformuladescription;
$i++;
}
}
} else {
print $this->db->error();
}
return $amountformuladescriptionbytype;
}
/**
* Return array of Member objects for member type this->id (or all if this->id not defined)
*
@@ -1002,7 +1092,7 @@ class AdherentType extends CommonObject
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.PublicUnderscore
/**
* Retourne chaine DN complete dans l'annuaire LDAP pour l'objet
* Returns full DN description in LDAP directory format for the object
*
* @param array<string,mixed> $info Info array loaded by _load_ldap_info
* @param int<0,2> $mode 0=Return full DN (uid=qqq,ou=xxx,dc=aaa,dc=bbb)

View File

@@ -431,7 +431,7 @@ class Subscription extends CommonObject
* @param string $option Page for link ('', 'nolink', ...)
* @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 Chaine avec URL
* @return string String with URL
*/
public function getNomUrl($withpicto = 0, $notooltip = 0, $option = '', $morecss = '', $save_lastsearch_value = -1)
{

View File

@@ -6,7 +6,7 @@
* Copyright (C) 2014-2016 Juanjo Menent <jmenent@2byte.es>
* Copyright (C) 2018-2024 Alexandre Spangaro <aspangaro@open-dsi.fr>
* Copyright (C) 2021-2025 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024-2025 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024-2026 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024 Benjamin Falière <benjamin.faliere@altairis.fr>
* Copyright (C) 2024 Alexandre Spangaro <alexandre@inovea-conseil.com>
*
@@ -503,7 +503,7 @@ if ($search_filter == 'outofdate') {
$sql .= " AND (datefin < '".$db->idate($now)."')";
}
if ($search_status != '') {
// Peut valoir un nombre ou liste de nombre separates par virgules
// Can be a number or comma separated list of numbers
$sql .= " AND d.statut in (".$db->sanitize($db->escape($search_status)).")";
}
if ($search_morphy != '' && $search_morphy != '-1') {

View File

@@ -149,7 +149,9 @@ if (empty($reshook) && $action == 'confirm_create_thirdparty' && $confirm == 'ye
$langs->load("errors");
setEventMessages($company->error, $company->errors, 'errors');
} else {
$action = 'addsubscription';
$object->socid = $result;
$action = 'createsubscription';
}
} else {
setEventMessages($object->error, $object->errors, 'errors');
@@ -248,14 +250,14 @@ if (empty($reshook) && $user->hasRight('adherent', 'cotisation', 'creer') && $ac
$langs->load("errors");
$errmsg = $langs->trans("ErrorBadDateFormat", $langs->transnoentitiesnoconv("DateSubscription"));
setEventMessages($errmsg, null, 'errors');
$action = 'addsubscription';
$action = 'createsubscription';
}
if (GETPOST('end') && !$datesubend) {
$error++;
$langs->load("errors");
$errmsg = $langs->trans("ErrorBadDateFormat", $langs->transnoentitiesnoconv("DateEndSubscription"));
setEventMessages($errmsg, null, 'errors');
$action = 'addsubscription';
$action = 'createsubscription';
}
if (!$datesubend) {
$datesubend = dol_time_plus_duree(dol_time_plus_duree($datesubscription, $defaultdelay, $defaultdelayunit), -1, 'd');
@@ -264,7 +266,7 @@ if (empty($reshook) && $user->hasRight('adherent', 'cotisation', 'creer') && $ac
$error++;
$errmsg = $langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("DatePayment"));
setEventMessages($errmsg, null, 'errors');
$action = 'addsubscription';
$action = 'createsubscription';
}
// Check if a payment is mandatory or not
@@ -274,7 +276,7 @@ if (empty($reshook) && $user->hasRight('adherent', 'cotisation', 'creer') && $ac
$errmsg = $langs->trans("ErrorFieldRequired", $langs->transnoentities("Amount"));
setEventMessages($errmsg, null, 'errors');
$error++;
$action = 'addsubscription';
$action = 'createsubscription';
} else {
// If an amount has been provided, we check also fields that becomes mandatory when amount is not null.
if (isModEnabled('bank') && GETPOST("paymentsave") != 'none') {
@@ -283,26 +285,26 @@ if (empty($reshook) && $user->hasRight('adherent', 'cotisation', 'creer') && $ac
$errmsg = $langs->trans("ErrorFieldRequired", $langs->transnoentities("Label"));
setEventMessages($errmsg, null, 'errors');
$error++;
$action = 'addsubscription';
$action = 'createsubscription';
}
if (GETPOST("paymentsave") != 'invoiceonly' && !GETPOST("operation")) {
$errmsg = $langs->trans("ErrorFieldRequired", $langs->transnoentities("PaymentMode"));
setEventMessages($errmsg, null, 'errors');
$error++;
$action = 'addsubscription';
$action = 'createsubscription';
}
if (GETPOST("paymentsave") != 'invoiceonly' && !(GETPOSTINT("accountid") > 0)) {
$errmsg = $langs->trans("ErrorFieldRequired", $langs->transnoentities("FinancialAccount"));
setEventMessages($errmsg, null, 'errors');
$error++;
$action = 'addsubscription';
$action = 'createsubscription';
}
} else {
if (GETPOSTINT("accountid")) {
$errmsg = $langs->trans("ErrorDoNotProvideAccountsIfNullAmount");
setEventMessages($errmsg, null, 'errors');
$error++;
$action = 'addsubscription';
$action = 'createsubscription';
}
}
}
@@ -335,7 +337,7 @@ if (empty($reshook) && $user->hasRight('adherent', 'cotisation', 'creer') && $ac
$db->commit();
} else {
$db->rollback();
$action = 'addsubscription';
$action = 'createsubscription';
}
if (!$error) {
@@ -695,11 +697,11 @@ print dol_get_fiche_end();
// Button to create a new subscription if member no draft (-1) neither resiliated (0) neither excluded (-2)
if ($user->hasRight('adherent', 'cotisation', 'creer')) {
if ($action != 'addsubscription' && $action != 'create_thirdparty') {
if ($action != 'createsubscription' && $action != 'create_thirdparty') {
print '<div class="tabsAction">';
if ($object->status > 0) {
print '<div class="inline-block divButAction"><a class="butAction" href="'.$_SERVER["PHP_SELF"].'?rowid='.$rowid.'&action=addsubscription&token='.newToken().'">'.$langs->trans("AddSubscription")."</a></div>";
print '<div class="inline-block divButAction"><a class="butAction" href="'.$_SERVER["PHP_SELF"].'?rowid='.$rowid.'&action=createsubscription">'.$langs->trans("AddSubscription")."</a></div>";
} else {
print '<div class="inline-block divButAction"><a class="butActionRefused classfortooltip" href="#" title="'.dol_escape_htmltag($langs->trans("ValidateBefore")).'">'.$langs->trans("AddSubscription").'</a></div>';
}
@@ -711,7 +713,7 @@ if ($user->hasRight('adherent', 'cotisation', 'creer')) {
/*
* List of subscriptions
*/
if ($action != 'addsubscription' && $action != 'create_thirdparty') {
if ($action != 'createsubscription' && $action != 'create_thirdparty') {
$sql = "SELECT d.rowid, d.firstname, d.lastname, d.societe, d.fk_adherent_type as type,";
$sql .= " c.rowid as crowid, c.subscription,";
$sql .= " c.datec, c.fk_type as cfk_type,";
@@ -820,7 +822,7 @@ if ($action != 'addsubscription' && $action != 'create_thirdparty') {
}
if (($action != 'addsubscription' && $action != 'create_thirdparty')) {
if (($action != 'createsubscription' && $action != 'create_thirdparty')) {
// Show online payment link
// The list can be complete by the hook 'doValidatePayment' executed inside getValidOnlinePaymentMethods()
include_once DOL_DOCUMENT_ROOT.'/core/lib/payments.lib.php';
@@ -839,7 +841,7 @@ if (($action != 'addsubscription' && $action != 'create_thirdparty')) {
/*
* Add new subscription form
*/
if (($action == 'addsubscription' || $action == 'create_thirdparty') && $user->hasRight('adherent', 'cotisation', 'creer')) {
if (($action == 'createsubscription' || $action == 'create_thirdparty') && $user->hasRight('adherent', 'cotisation', 'creer')) {
print '<br>';
print load_fiche_titre($langs->trans("NewCotisation"));
@@ -932,7 +934,7 @@ if (($action == 'addsubscription' || $action == 'create_thirdparty') && $user->h
// If customer code was forced to "required", we ask it at creation to avoid error later
if (getDolGlobalString('MAIN_COMPANY_CODE_ALWAYS_REQUIRED')) {
$tmpcompany = new Societe($db);
$tmpcompany->name = $companyname;
$tmpcompany->name = (string) $companyname;
$tmpcompany->get_codeclient($tmpcompany, 0);
$customercode = $tmpcompany->code_client;
$formquestion[] = array(

View File

@@ -2,6 +2,7 @@
/* Copyright (C) 2007-2019 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2018-2024 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024 Alexandre Spangaro <alexandre@inovea-conseil.com>
* Copyright (C) 2026 MDW <mdeweerd@users.noreply.github.com>
*
* 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
@@ -344,7 +345,7 @@ if ($rowid && $action != 'edit') {
print '<tr><td>'.$langs->trans("Amount").'</td><td class="valeur"><span class="amount">'.price($object->amount).'</span></td></tr>';
// Label
print '<tr><td>'.$langs->trans("Label").'</td><td class="valeur sensiblehtmlcontent">'.dol_string_onlythesehtmltags(dol_htmlentitiesbr($object->note_public)).'</td></tr>';
print '<tr><td>'.$langs->trans("Label").'</td><td class="valeur sensiblehtmlcontent">'.dol_string_onlythesehtmltags(dol_htmlentitiesbr((string) $object->note_public)).'</td></tr>';
// Bank line
if (isModEnabled("bank") && (getDolGlobalString('ADHERENT_BANK_USE') || $object->fk_bank)) {

View File

@@ -91,13 +91,15 @@ $label = GETPOST("label", "alpha");
$morphy = GETPOST("morphy", "alpha");
$status = GETPOST("status", "intcomma");
$subscription = GETPOSTINT("subscription");
$caneditamount = GETPOSTINT("caneditamount");
$minimumamount = GETPOST('minimumamount', 'alpha');
$amount = GETPOST('amount', 'alpha');
$amountformuladescription = GETPOST("amountformuladescription", 'restricthtml');
$duration_value = GETPOSTINT('duration_value');
$duration_unit = GETPOST('duration_unit', 'alpha');
$vote = GETPOSTINT("vote");
$comment = GETPOST("comment", 'restricthtml');
$mail_valid = GETPOST("mail_valid", 'restricthtml');
$caneditamount = GETPOSTINT("caneditamount");
// Initialize a technical object
$object = new AdherentType($db);
@@ -172,8 +174,10 @@ if ($action == 'add' && $user->hasRight('adherent', 'configurer')) {
$object->morphy = trim($morphy);
$object->status = (int) $status;
$object->subscription = (string) (int) $subscription;
$object->amount = ($amount == '' ? '' : price2num($amount, 'MT'));
$object->caneditamount = $caneditamount;
$object->minimumamount = ($minimumamount == '' ? '' : price2num($minimumamount, 'MT'));
$object->amount = ($amount == '' ? '' : price2num($amount, 'MT'));
$object->amountformuladescription = trim($amountformuladescription);
$object->duration_value = $duration_value;
$object->duration_unit = $duration_unit;
$object->note_public = trim($comment);
@@ -233,8 +237,10 @@ if ($action == 'update' && $user->hasRight('adherent', 'configurer')) {
$object->morphy = trim($morphy);
$object->status = (int) $status;
$object->subscription = (string) (int) $subscription;
$object->amount = ($amount == '' ? '' : price2num($amount, 'MT'));
$object->caneditamount = $caneditamount;
$object->minimumamount = $minimumamount;
$object->amount = ($amount == '' ? '' : price2num($amount, 'MT'));
$object->amountformuladescription = trim($amountformuladescription);
$object->duration_value = $duration_value;
$object->duration_unit = $duration_unit;
$object->note_public = trim($comment);
@@ -296,7 +302,7 @@ $totalarray = [
if (!$rowid && $action != 'create' && $action != 'edit') {
//print dol_get_fiche_head([]);
$sql = "SELECT d.rowid, d.libelle as label, d.subscription, d.amount, d.caneditamount, d.vote,";
$sql = "SELECT d.rowid, d.libelle as label, d.subscription, d.caneditamount, d.minimumamount, d.amount, d.amountformuladescription, d.vote,";
$sql .= " d.statut as status, d.morphy, d.duration,";
$sql .= " d.tms";
$sql .= " FROM ".MAIN_DB_PREFIX."adherent_type as d";
@@ -380,12 +386,20 @@ if (!$rowid && $action != 'create' && $action != 'edit') {
print '<th class="center">'.$langs->trans("SubscriptionRequired").'</th>';
$totalarray['nbfield']++;
}
if (!empty($arrayfields['t.caneditamount']['checked'])) {
print '<th class="center">'.$langs->trans("CanEditAmountShort").'</th>';
$totalarray['nbfield']++;
}
if (!empty($arrayfields['t.minimumamount']['checked'])) {
print '<th class="center">'.$langs->trans("MinimumAmountShort").'</th>';
$totalarray['nbfield']++;
}
if (!empty($arrayfields['t.amount']['checked'])) {
print '<th class="center">'.$langs->trans("Amount").'</th>';
print '<th class="center">'.$langs->trans("RecommendedAmount").'</th>';
$totalarray['nbfield']++;
}
if (!empty($arrayfields['t.caneditamount']['checked'])) {
print '<th class="center">'.$langs->trans("CanEditAmountShort").'</th>';
if (!empty($arrayfields['t.amountformuladescription']['checked'])) {
print '<th class="center">'.$langs->trans("AmountFormulaDescription").'</th>';
$totalarray['nbfield']++;
}
if (!empty($arrayfields['t.vote']['checked'])) {
@@ -423,8 +437,10 @@ if (!$rowid && $action != 'create' && $action != 'edit') {
$membertype->label = $objp->rowid;
$membertype->status = $objp->status;
$membertype->subscription = $objp->subscription;
$membertype->amount = $objp->amount;
$membertype->caneditamount = $objp->caneditamount;
$membertype->minimumamount = $objp->minimumamount;
$membertype->amount = $objp->amount;
$membertype->amountformuladescription = $objp->amountformuladescription;
if ($mode == 'kanban') {
if ($i == 0) {
@@ -483,17 +499,27 @@ if (!$rowid && $action != 'create' && $action != 'edit') {
if (!empty($arrayfields['t.subscription']['checked'])) {
print '<td class="center">'.yn($objp->subscription).'</td>';
}
if (!empty($arrayfields['t.caneditamount']['checked'])) {
print '<td class="center">'.yn($objp->caneditamount).'</td>';
}
if (!empty($arrayfields['t.minimumamount']['checked'])) {
print '<td class="center">'.price($objp->minimumamount).'</td>';
}
if (!empty($arrayfields['t.amount']['checked'])) {
print '<td class="center">';
$amount = (is_null($objp->amount) || $objp->amount === '' ? '' : price($objp->amount));
$minimumamount = (is_null($objp->minimumamount) || $objp->minimumamount === '' ? '' : price($objp->minimumamount));
print '<span class="amount">'.$amount.'</span>';
if ($amount && $amount < (float) getDolGlobalInt("MEMBER_MIN_AMOUNT")) {
print img_warning('Amount lower than minimum of '.price(getDolGlobalInt("MEMBER_MIN_AMOUNT")).' defined in setup');
}
if ($amount && $minimumamount && $amount < $minimumamount) {
print img_warning('Amount lower than minimum of '.price($minimumamount).' defined in setup');
}
print '</td>';
}
if (!empty($arrayfields['t.caneditamount']['checked'])) {
print '<td class="center">'.yn($objp->caneditamount).'</td>';
if (!empty($arrayfields['t.amountformuladescription']['checked'])) {
print '<td class="center">'.dol_escape_htmltag($objp->amountformuladescription).'</td>';
}
if (!empty($arrayfields['t.vote']['checked'])) {
print '<td class="center">'.yn($objp->vote).'</td>';
@@ -572,14 +598,23 @@ if ($action == 'create') {
print $form->selectyesno("subscription", 1, 1);
print '</td></tr>';
print '<tr><td>'.$langs->trans("Amount").'</td><td>';
print '<input name="amount" size="5" value="'.(GETPOSTISSET('amount') ? GETPOST('amount') : '').'">';
print '</td></tr>';
print '<tr><td>'.$form->textwithpicto($langs->trans("CanEditAmountShort"), $langs->transnoentities("CanEditAmount")).'</td><td>';
print $form->selectyesno("caneditamount", GETPOSTISSET('caneditamount') ? GETPOST('caneditamount') : 0, 1);
print '</td></tr>';
print '<tr><td>'.$langs->trans("MinimumAmountShort").'</td><td>';
print '<input name="minimumamount" size="5" value="'.(GETPOSTISSET('minimumamount') ? GETPOST('minimumamount') : price($minimumamount)).'">';
print '</td></tr>';
print '<tr><td>'.$langs->trans("RecommendedAmount").'</td><td>';
print '<input name="amount" size="5" value="'.(GETPOSTISSET('amount') ? GETPOST('amount') : '').'">';
print '</td></tr>';
print '<tr><td class="tdtop">'.$langs->trans("AmountFormulaDescription").'</td><td>';
require_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php';
$doleditor = new DolEditor('amountformuladescription', (GETPOSTISSET('amountformuladescription') ? GETPOST('amountformuladescription', 'restricthtml') : $object->amountformuladescription), '', 100, 'dolibarr_notes', '', false, true, isModEnabled('fckeditor'), 15, '90%');
$doleditor->Create();
print '<tr><td>'.$langs->trans("VoteAllowed").'</td><td>';
print $form->selectyesno("vote", GETPOSTISSET("vote") ? GETPOST('vote', 'aZ09') : 1, 1);
print '</td></tr>';
@@ -649,17 +684,29 @@ if ($rowid > 0) {
print '</tr>';
// Amount
print '<tr><td class="titlefield">'.$langs->trans("Amount").'</td><td>';
print '<tr><td>'.$form->textwithpicto($langs->trans("CanEditAmountShort"), $langs->transnoentities("CanEditAmount")).'</td><td>';
print yn($object->caneditamount);
print '</td></tr>';
print '<tr><td class="titlefield">'.$langs->trans("MinimumAmountShort").'</td><td>';
$minimumamount = ((is_null($object->minimumamount) || $object->minimumamount === '') ? '' : price($object->minimumamount));
print $minimumamount;
print '</tr>';
print '<tr><td class="titlefield">'.$langs->trans("RecommendedAmount").'</td><td>';
$amount = ((is_null($object->amount) || $object->amount === '') ? '' : price($object->amount));
print '<span class="amount">'.$amount.'</span>';
if ($amount && $amount < (float) getDolGlobalInt("MEMBER_MIN_AMOUNT")) {
print ' '.img_warning('Amount lower than minimum of '.price(getDolGlobalInt("MEMBER_MIN_AMOUNT")).' defined in setup');
}
if ($amount && $minimumamount && $amount < $minimumamount) {
print ' '.img_warning('Amount lower than minimum of '.price($minimumamount).' defined in setup');
}
print '</tr>';
print '<tr><td>'.$form->textwithpicto($langs->trans("CanEditAmountShort"), $langs->transnoentities("CanEditAmount")).'</td><td>';
print yn($object->caneditamount);
print '</td></tr>';
print '<tr><td class="tdtop">'.$langs->trans("AmountFormulaDescription").'</td><td><div class="longmessagecut">';
print dol_string_onlythesehtmltags(dol_htmlentitiesbr($object->amountformuladescription));
print "</div></td></tr>";
print '<tr><td>'.$langs->trans("VoteAllowed").'</td><td>';
print yn($object->vote);
@@ -681,7 +728,7 @@ if ($rowid > 0) {
// Description
print '<tr><td class="tdtop">'.$langs->trans("Description").'</td><td><div class="longmessagecut">';
print dol_string_onlythesehtmltags(dol_htmlentitiesbr($object->note_public));
print dol_string_onlythesehtmltags(dol_htmlentitiesbr((string) $object->note_public));
print "</div></td></tr>";
// Welcome email content
@@ -1096,15 +1143,28 @@ if ($rowid > 0) {
print $form->selectyesno("subscription", $object->subscription, 1);
print '</td></tr>';
print '<tr><td>'.$langs->trans("Amount").'</td><td>';
print '<tr><td>'.$form->textwithpicto($langs->trans("CanEditAmountShort"), $langs->transnoentities("CanEditAmountDetail")).'</td><td>';
print $form->selectyesno("caneditamount", $object->caneditamount, 1);
print '</td></tr>';
print '<tr><td>'.$langs->trans("MinimumAmountShort").'</td><td>';
$minimumamount = ((is_null($object->minimumamount) || $object->minimumamount === '') ? '' : price($object->minimumamount));
print '<input name="minimumamount" size="5" value="';
print $minimumamount;
print '">';
print '</td></tr>';
print '<tr><td>'.$langs->trans("RecommendedAmount").'</td><td>';
$amount = ((is_null($object->amount) || $object->amount === '') ? '' : price($object->amount));
print '<input name="amount" size="5" value="';
print $amount;
print '">';
print '</td></tr>';
print '<tr><td>'.$form->textwithpicto($langs->trans("CanEditAmountShort"), $langs->transnoentities("CanEditAmountDetail")).'</td><td>';
print $form->selectyesno("caneditamount", $object->caneditamount, 1);
print '<tr><td class="tdtop">'.$langs->trans("AmountFormulaDescription").'</td><td>';
require_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php';
$doleditor = new DolEditor('amountformuladescription', $object->amountformuladescription, '', 220, 'dolibarr_notes', '', false, true, isModEnabled('fckeditor'), 15, '90%');
$doleditor->Create();
print '</td></tr>';
print '<tr><td>'.$langs->trans("VoteAllowed").'</td><td>';

View File

@@ -3,7 +3,7 @@
* Copyright (C) 2004-2015 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@inodbox.com>
* Copyright (C) 2011-2013 Juanjo Menent <jmenent@2byte.es>
* Copyright (C) 2024-2025 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024-2026 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024 Frédéric France <frederic.france@free.fr>
*
* This program is free software; you can redistribute it and/or modify
@@ -430,9 +430,9 @@ if (getDolGlobalString('BARCODE_USE_ON_PRODUCT') || getDolGlobalString('BARCODE_
print dol_escape_htmltag($obj->label);
print "</td><td>\n";
print $langs->trans('BarcodeDesc'.$obj->encoding);
//print "L'EAN se compose de 8 characters, 7 chiffres plus une cle de verification.<br>";
//print "L'utilisation des symbologies EAN8 impose la souscription et l'abonnement aupres d'organismes comme GENCOD.<br>";
//print "Codes numeriques utilises exclusivement a l'identification des produits susceptibles d'etre vendus au grand public.";
// print "The EAN consists of 8 characters, 7 digits plus a control digit.";
// print "The use of EAN8 symbols requires subscription to organizations such as GENCOD.";
// print "Numeric codes are used exclusively for the identification of products that are likely to be sold to the general public.";
print '</td>';
// Show example
@@ -520,7 +520,7 @@ if (getDolGlobalString('BARCODE_USE_ON_PRODUCT') || getDolGlobalString('BARCODE_
print '<td>'.$langs->trans("GenbarcodeLocation").'</td>';
print '<td width="60" class="center">';
print '<input type="text" size="40" name="GENBARCODE_LOCATION" value="'.getDolGlobalString('GENBARCODE_LOCATION').'">';
if (getDolGlobalString('GENBARCODE_LOCATION') && !@file_exists($conf->global->GENBARCODE_LOCATION)) {
if (getDolGlobalString('GENBARCODE_LOCATION') && !@file_exists(getDolGlobalString('GENBARCODE_LOCATION'))) {
$langs->load("errors");
print '<br><span class="error">'.$langs->trans("ErrorFileNotFound", getDolGlobalString('GENBARCODE_LOCATION')).'</span>';
}

View File

@@ -11,7 +11,7 @@
* Copyright (C) 2011-2025 Alexandre Spangaro <alexandre@inovea-conseil.com>
* Copyright (C) 2015 Ferran Marcet <fmarcet@2byte.es>
* Copyright (C) 2016 Raphaël Doursenaud <rdoursenaud@gpcsolutions.fr>
* Copyright (C) 2019-2025 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2019-2026 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2020-2022 Open-Dsi <support@open-dsi.fr>
* Copyright (C) 2024-2025 Charlene Benke <charlene@patas-monkey.com>
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
@@ -1053,7 +1053,7 @@ if (empty($reshook)) {
// Modify entry
$sql = "UPDATE ".MAIN_DB_PREFIX.$tablename." SET ";
// Modifie value of fields
// Update fields value
if ($tabrowid[$id] && !in_array($tabrowid[$id], $listfieldmodify)) {
$sql .= $tabrowid[$id]."=";
$sql .= "'".$db->escape($rowid)."', ";
@@ -1378,6 +1378,7 @@ if (empty($reshook)) {
*/
$form = new Form($db);
$formother = new FormOther($db);
$title = $langs->trans("DictionarySetup");
@@ -2625,6 +2626,8 @@ if ($id > 0) {
$valuetoshow = price2num($valuetoshow);
} elseif ($value == 'type' && $id == DICT_ACTIONCOMM && !empty($obj->module)) {
$titletoshow = $langs->trans("Module").' '.$obj->module;
} elseif ($value == 'color') {
$valuetoshow = $formother->showColor($obj->{$value}, '');
}
@@ -2829,14 +2832,13 @@ $db->close();
function dictFieldList($fieldlist, $obj = null, $tabname = '', $context = '')
{
global $langs, $db, $mysoc;
global $form;
global $form, $formother;
global $region_id;
global $elementList, $sourceList, $localtax_typeList, $type_vatList;
$formadmin = new FormAdmin($db);
$formcompany = new FormCompany($db);
$formaccounting = new FormAccounting($db);
$formother = new FormOther($db);
$withentity = '';

View File

@@ -662,6 +662,8 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
'cc' => array('label' => 'Cc', 'data-placeholder' => $langs->trans('SearchString')),
'bcc' => array('label' => 'Bcc', 'data-placeholder' => $langs->trans('SearchString')),
'replyto' => array('label' => 'ReplyTo', 'data-placeholder' => $langs->trans('SearchString')),
'excludeemail' => array('label' => 'EmailCollectorExcludeEmails', 'data-placeholder' => $langs->trans('EmailCollectorExcludeEmailsPlaceholder')),
'excludedomain' => array('label' => 'EmailCollectorExcludeDomains', 'data-placeholder' => $langs->trans('EmailCollectorExcludeDomainsPlaceholder')),
'subject' => array('label' => 'Subject', 'data-placeholder' => $langs->trans('SearchString')),
'body' => array('label' => 'Body', 'data-placeholder' => $langs->trans('SearchString')),
// disabled because PHP imap_search is not compatible IMAPv4, only IMAPv2

View File

@@ -788,7 +788,7 @@ if ($conf->use_javascript_ajax) {
print ajax_constantonoff('MAIN_IMAP_USE_PHPIMAP');
} else {
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
print $form->selectarray("MAIN_IMAP_USE_PHPIMAP", $arrval, $conf->global->MAIN_IMAP_USE_PHPIMAP);
print $form->selectarray("MAIN_IMAP_USE_PHPIMAP", $arrval, getDolGlobalString("MAIN_IMAP_USE_PHPIMAP"));
}
print '</td>';
print '</tr>';

View File

@@ -7,7 +7,7 @@
* Copyright (C) 2005-2011 Regis Houssin <regis.houssin@inodbox.com>
* Copyright (C) 2011 Juanjo Menent <jmenent@2byte.es>
* Copyright (C) 2020 Tobias Sekan <tobias.sekan@startmail.com>
* Copyright (C) 2024-2025 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024-2026 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024 Frédéric France <frederic.france@free.fr>
*
* This program is free software; you can redistribute it and/or modify
@@ -61,7 +61,7 @@ if (!$user->admin) {
*/
$error = 0;
// positionne la variable pour le nombre de rss externes
// Set the variable for the number of external RSS
$sql = "SELECT ".$db->decrypt('name')." as name FROM ".MAIN_DB_PREFIX."const";
$sql .= " WHERE ".$db->decrypt('name')." LIKE 'EXTERNAL_RSS_URLRSS_%'";
//print $sql;

View File

@@ -7,7 +7,7 @@
* Copyright (C) 2005-2011 Regis Houssin <regis.houssin@inodbox.com>
* Copyright (C) 2011 Juanjo Menent <jmenent@2byte.es>
* Copyright (C) 2020 Tobias Sekan <tobias.sekan@startmail.com>
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024-2026 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024 Frédéric France <frederic.france@free.fr>
*
* This program is free software; you can redistribute it and/or modify
@@ -193,7 +193,8 @@ if ($action == 'updatesocialnetwork') {
$paramsKey = GETPOST('paramsKey', 'array');
$paramsVal = GETPOST('paramsVal', 'array');
$result = dolibarr_get_const($db, "SOCIAL_NETWORKS_DATA_".$name, $conf->entity);
$result = getDolGlobalString("SOCIAL_NETWORKS_DATA_".$name);
$socialNetworkData = json_decode($result, true);
foreach ($paramsKey as $index => $key) {
@@ -244,7 +245,9 @@ if ($action == 'editsocialnetwork' && GETPOST('confirm') == 'yes') {
$paramKey = GETPOST('paramkey', 'alpha');
$key = GETPOST('key', 'alpha');
$name = GETPOST('name');
$result = dolibarr_get_const($db, "SOCIAL_NETWORKS_DATA_".$name, $conf->entity);
$result = getDolGlobalString("SOCIAL_NETWORKS_DATA_".$name);
$socialNetworkData = json_decode($result, true);
unset($socialNetworkData[$paramKey]);
@@ -349,7 +352,7 @@ foreach ($oauthservices as $key => $value) {
/** @phan-var-force array<string, array{label:string, data-html:string, disable?:int, css?:string}> $oauthservices */
if (!isModEnabled('multicompany') || ($user->admin && !$user->entity)) {
print $form->selectarray('OAUTH_SERVICE_SOCIAL_NETWORK', $oauthservicesStringKeys, (string) $conf->global->OAUTH_SERVICE_SOCIAL_NETWORK);
print $form->selectarray('OAUTH_SERVICE_SOCIAL_NETWORK', $oauthservicesStringKeys, (string) getDolGlobalString("OAUTH_SERVICE_SOCIAL_NETWORK"));
} else {
$selectedKey = (string) getDolGlobalString('OAUTH_SERVICE_SOCIAL_NETWORK');
$text = isset($oauthservicesStringKeys[$selectedKey]) ? $oauthservicesStringKeys[$selectedKey]['label'] : '';
@@ -387,17 +390,17 @@ print '<script type="text/javascript">
$(document).ready(function() {
function toggleOAuthServiceDisplay() {
if ($("#radio_oauth").is(":checked")) {
$("#oauth_service_div").show(); // Afficher le sélecteur OAuth
$("#oauth_service_div").show(); // Show the OAuth selector
} else {
$("#oauth_service_div").hide(); // Cacher le sélecteur OAuth
$("#oauth_service_div").hide(); // Hide the OAuth selector
}
}
function toggleAddParamRow() {
if ($("#radio_oauth").is(":checked")) {
$("#add_param_row").hide(); // Cacher toute la ligne
$("#add_param_row").hide(); // Hide the entire line
} else {
$("#add_param_row").show(); // Afficher toute la ligne
$("#add_param_row").show(); // Show the entire line
}
}

View File

@@ -49,7 +49,7 @@ $langs->loadLangs(array("admin", "errors"));
$action = GETPOST('action', 'aZ09');
if (!isset($conf->global->GEOIP_VERSION)) {
if (!getDolGlobalString("GEOIP_VERSION")) {
$conf->global->GEOIP_VERSION = '2';
}

View File

@@ -300,7 +300,7 @@ if ($action == 'update') {
$dirforimage = $conf->mycompany->dir_output . '/logos/';
if ($_FILES[$varforimage]["tmp_name"]) {
$reg = array();
if (preg_match('/([^\\/:]+)$/i', $_FILES[$varforimage]["name"], $reg)) {
if (preg_match('/([^\\/:]+)$/i', (string) $_FILES[$varforimage]["name"], $reg)) {
$original_file = $reg[1];
$isimage = image_format_supported($original_file);

View File

@@ -875,14 +875,16 @@ print '<input type="submit" class="button button-edit reposition" value="'.$lang
print "</td></tr>\n";
print '</form>';
print '<tr class="oddeven"><td>'.$langs->trans("InvoiceCheckPosteriorDate"). '&nbsp;' ;
print $form->textwithpicto('', $langs->trans("InvoiceCheckPosteriorDateHelp"), 1, 'help') . '</td>';
print '<td class="left" colspan="2">';
//if (!getDolGlobalInt('FAC_FORCE_DATE_VALIDATION')) { // If date is forced, this option to check become useless (it should be if you male import manually, it may be not)
print ajax_constantonoff('INVOICE_CHECK_POSTERIOR_DATE');
/*} else {
print img_picto($langs->trans("PreviousOptionGuaranteeThatDateIsAlwaysHigher"), 'switch_off', 'class="opacitymedium"');
}*/
print '</td></tr>';
// Allow external download
print '<tr class="oddeven">';
print '<td>'.$langs->trans("AllowExternalDownload").'</td>';

View File

@@ -118,7 +118,7 @@ $form->load_cache_conditions_paiements();
if (getDolGlobalString('INVOICE_SITUATION_DEFAULT_RETAINED_WARRANTY_COND_ID') && isset($form->cache_conditions_paiements[getDolGlobalString('INVOICE_SITUATION_DEFAULT_RETAINED_WARRANTY_COND_ID')]['label'])) {
$item->fieldOutputOverride = $form->cache_conditions_paiements[getDolGlobalString('INVOICE_SITUATION_DEFAULT_RETAINED_WARRANTY_COND_ID')]['label'];
}
$item->fieldInputOverride = $form->getSelectConditionsPaiements($conf->global->INVOICE_SITUATION_DEFAULT_RETAINED_WARRANTY_COND_ID, 'INVOICE_SITUATION_DEFAULT_RETAINED_WARRANTY_COND_ID', -1, 1);
$item->fieldInputOverride = $form->getSelectConditionsPaiements(getDolGlobalInt("INVOICE_SITUATION_DEFAULT_RETAINED_WARRANTY_COND_ID"), 'INVOICE_SITUATION_DEFAULT_RETAINED_WARRANTY_COND_ID', -1, 1);
/*

View File

@@ -298,11 +298,11 @@ if (function_exists("ldap_connect")) {
if (getDolGlobalString('LDAP_ADMIN_DN') && getDolGlobalString('LDAP_ADMIN_PASS')) {
if ($result == 2) {
print img_picto('', 'info').' ';
print '<span class="ok">'.$langs->trans("LDAPBindOK", $ldap->connectedServer, getDolGlobalString('LDAP_SERVER_PORT'), getDolGlobalString('LDAP_ADMIN_DN'), preg_replace('/./i', '*', $conf->global->LDAP_ADMIN_PASS)).'</span>';
print '<span class="ok">'.$langs->trans("LDAPBindOK", $ldap->connectedServer, getDolGlobalString('LDAP_SERVER_PORT'), getDolGlobalString('LDAP_ADMIN_DN'), preg_replace('/./i', '*', getDolGlobalString("LDAP_ADMIN_PASS"))).'</span>';
print '<br>';
} else {
print img_picto('', 'error').' ';
print '<span class="error">'.$langs->trans("LDAPBindKO", $ldap->connectedServer, getDolGlobalString('LDAP_SERVER_PORT'), getDolGlobalString('LDAP_ADMIN_DN'), preg_replace('/./i', '*', $conf->global->LDAP_ADMIN_PASS)).'</span>';
print '<span class="error">'.$langs->trans("LDAPBindKO", $ldap->connectedServer, getDolGlobalString('LDAP_SERVER_PORT'), getDolGlobalString('LDAP_ADMIN_DN'), preg_replace('/./i', '*', getDolGlobalString("LDAP_ADMIN_PASS"))).'</span>';
print '<br>';
print $langs->trans("Error").' '.$ldap->error;
print '<br>';

View File

@@ -208,14 +208,14 @@ if ($action == 'edit') {
print '<tr class="oddeven"><td>';
print $form->textwithpicto($langs->trans("MAIN_MAX_DECIMALS_UNIT"), $langs->trans("ParameterActiveForNextInputOnly"));
print '</td><td align="right">'.(isset($conf->global->$mainmaxdecimalsunit) ? $conf->global->$mainmaxdecimalsunit : $conf->global->MAIN_MAX_DECIMALS_UNIT).'</td></tr>';
print '</td><td align="right">'.(isset($conf->global->$mainmaxdecimalsunit) ? $conf->global->$mainmaxdecimalsunit : getDolGlobalString("MAIN_MAX_DECIMALS_UNIT")).'</td></tr>';
print '<tr class="oddeven"><td>';
print $form->textwithpicto($langs->trans("MAIN_MAX_DECIMALS_TOT"), $langs->trans("ParameterActiveForNextInputOnly"));
print '</td><td align="right">'.(isset($conf->global->$mainmaxdecimalstot) ? $conf->global->$mainmaxdecimalstot : $conf->global->MAIN_MAX_DECIMALS_TOT).'</td></tr>';
print '</td><td align="right">'.(isset($conf->global->$mainmaxdecimalstot) ? $conf->global->$mainmaxdecimalstot : getDolGlobalString("MAIN_MAX_DECIMALS_TOT")).'</td></tr>';
print '<tr class="oddeven"><td>'.$langs->trans("MAIN_MAX_DECIMALS_SHOWN").'</td>';
print '<td align="right">'.(isset($conf->global->$mainmaxdecimalsshown) ? $conf->global->$mainmaxdecimalsshown : $conf->global->MAIN_MAX_DECIMALS_SHOWN).'</td></tr>';
print '<td align="right">'.(isset($conf->global->$mainmaxdecimalsshown) ? $conf->global->$mainmaxdecimalsshown : getDolGlobalString("MAIN_MAX_DECIMALS_SHOWN")).'</td></tr>';
print '<tr class="oddeven"><td>';
print $form->textwithpicto($langs->trans("MAIN_ROUNDING_RULE_TOT"), $langs->trans("ParameterActiveForNextInputOnly"));

View File

@@ -162,7 +162,7 @@ print '<tr class="oddeven"><td>';
$help = img_help(1, $langs->trans("EMailHelpMsgSPFDKIM"));
print $langs->trans("MailingEMailFrom") . ' ' . $help . '</td><td>';
print '<input class="minwidth100" type="text" name="MAILING_EMAIL_FROM" value="' . getDolGlobalString('MAILING_EMAIL_FROM') . '">';
if (getDolGlobalString('MAILING_EMAIL_FROM') && !isValidEmail($conf->global->MAILING_EMAIL_FROM)) {
if (getDolGlobalString('MAILING_EMAIL_FROM') && !isValidEmail(getDolGlobalString('MAILING_EMAIL_FROM'))) {
print ' ' . img_warning($langs->trans("BadEMail"));
}
print '</td>';

View File

@@ -28,10 +28,6 @@
// Load Dolibarr environment
require '../main.inc.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/geturl.lib.php';
/**
* @var Conf $conf
* @var DoliDB $db
@@ -40,6 +36,9 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/geturl.lib.php';
* @var Translate $langs
* @var User $user
*/
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/geturl.lib.php';
// Load translation files required by the page
$langs->loadLangs(array("companies", "products", "admin", "mails", "other", "errors"));

View File

@@ -570,7 +570,21 @@ if ($action == 'edit') {
print dol_get_fiche_head($head, 'common_emailing', '', -1);
print '<span class="opacitymedium">'.$langs->trans("EMailsDesc")."</span><br>\n";
print "<br><br>\n";
print "<br>\n";
print $langs->trans("MAIN_DISABLE_ALL_MAILS");
if (!empty($conf->use_javascript_ajax)) {
print ajax_constantonoff('MAIN_DISABLE_ALL_MAILS', array(), null, 0, 0, 1, 2, 0, 0, '_red').'</a>';
} else {
print yn(getDolGlobalString('MAIN_DISABLE_ALL_MAILS'));
if (getDolGlobalString('MAIN_DISABLE_ALL_MAILS')) {
print img_warning($langs->trans("Disabled"));
}
}
print "<br>\n";
print "<br>\n";
print "<br>\n";
print '<div class="div-table-responsive-no-min">'; // You can use div-table-responsive-no-min if you don't need reserved height for your table
print '<table class="noborder centpercent">';

View File

@@ -589,7 +589,21 @@ if ($action == 'edit') {
print dol_get_fiche_head($head, 'common_passwordreset', '', -1);
print '<span class="opacitymedium">'.$langs->trans("EMailsDesc")."</span><br>\n";
print "<br><br>\n";
print "<br>\n";
print $langs->trans("MAIN_DISABLE_ALL_MAILS");
if (!empty($conf->use_javascript_ajax)) {
print ajax_constantonoff('MAIN_DISABLE_ALL_MAILS', array(), null, 0, 0, 1, 2, 0, 0, '_red').'</a>';
} else {
print yn(getDolGlobalString('MAIN_DISABLE_ALL_MAILS'));
if (getDolGlobalString('MAIN_DISABLE_ALL_MAILS')) {
print img_warning($langs->trans("Disabled"));
}
}
print "<br>\n";
print "<br>\n";
print "<br>\n";
print '<div class="div-table-responsive-no-min">'; // You can use div-table-responsive-no-min if you don't need reserved height for your table
print '<table class="noborder centpercent">';

View File

@@ -11,7 +11,7 @@
* Copyright (C) 2011-2016 Alexandre Spangaro <aspangaro@open-dsi.fr>
* Copyright (C) 2015-2024 Ferran Marcet <fmarcet@2byte.es>
* Copyright (C) 2016 Raphaël Doursenaud <rdoursenaud@gpcsolutions.fr>
* Copyright (C) 2018-2024 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2018-2026 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024-2025 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2025 Vincent Maury <vmaury@timgroup.fr>
* Copyright (C) 2025 Jon Bendtsen <jon.bendtsen.github@jonb.dk>
@@ -790,8 +790,8 @@ if ($action == 'create') {
// Line to enter new values (title)
print '<tr class="liste_titre">';
foreach ($fieldlist as $field => $value) {
// Determine le nom du champ par rapport aux noms possibles
// dans les dictionnaires de donnees
// Determine the field name based on the possible names
// in the data dictionaries.
$valuetoshow = ucfirst($fieldlist[$field]); // Par default
$valuetoshow = $langs->trans($valuetoshow); // try to translate
$css = "left";

View File

@@ -564,7 +564,21 @@ if ($action == 'edit') {
print dol_get_fiche_head($head, 'common_ticket', '', -1);
print '<span class="opacitymedium">'.$langs->trans("EMailsDesc")."</span><br>\n";
print "<br><br>\n";
print "<br>\n";
print $langs->trans("MAIN_DISABLE_ALL_MAILS");
if (!empty($conf->use_javascript_ajax)) {
print ajax_constantonoff('MAIN_DISABLE_ALL_MAILS', array(), null, 0, 0, 1, 2, 0, 0, '_red').'</a>';
} else {
print yn(getDolGlobalString('MAIN_DISABLE_ALL_MAILS'));
if (getDolGlobalString('MAIN_DISABLE_ALL_MAILS')) {
print img_warning($langs->trans("Disabled"));
}
}
print "<br>\n";
print "<br>\n";
print "<br>\n";
print '<div class="div-table-responsive-no-min">'; // You can use div-table-responsive-no-min if you don't need reserved height for your table
print '<table class="noborder centpercent">';

View File

@@ -196,7 +196,7 @@ print '<tr class="oddeven"><td>'.$langs->trans("DefaultMenuSmartphoneManager").'
print '<td>';
$formadmin->select_menu(getDolGlobalString('MAIN_MENU_SMARTPHONE_FORCED', getDolGlobalString('MAIN_MENU_SMARTPHONE')), 'MAIN_MENU_SMARTPHONE', array_merge($dirstandard, $dirsmartphone), !getDolGlobalString('MAIN_MENU_SMARTPHONE_FORCED') ? '' : ' disabled');
if (getDolGlobalString('MAIN_MENU_SMARTPHONE_FORCED') && preg_match('/smartphone/', $conf->global->MAIN_MENU_SMARTPHONE_FORCED)
if (getDolGlobalString('MAIN_MENU_SMARTPHONE_FORCED') && preg_match('/smartphone/', getDolGlobalString('MAIN_MENU_SMARTPHONE_FORCED'))
|| (!getDolGlobalString('MAIN_MENU_SMARTPHONE_FORCED') && getDolGlobalString('MAIN_MENU_SMARTPHONE') && preg_match('/smartphone/', getDolGlobalString('MAIN_MENU_SMARTPHONE')))) {
print ' '.img_warning($langs->transnoentitiesnoconv("ThisForceAlsoTheme"));
}
@@ -205,7 +205,7 @@ print '</td>';
print '<td>';
$formadmin->select_menu(getDolGlobalString('MAIN_MENUFRONT_SMARTPHONE_FORCED', getDolGlobalString('MAIN_MENUFRONT_SMARTPHONE')), 'MAIN_MENUFRONT_SMARTPHONE', array_merge($dirstandard, $dirsmartphone), !getDolGlobalString('MAIN_MENUFRONT_SMARTPHONE_FORCED') ? '' : ' disabled');
if (getDolGlobalString('MAIN_MENU_SMARTPHONE_FORCED') && preg_match('/smartphone/', $conf->global->MAIN_MENUFRONT_SMARTPHONE_FORCED)
if (getDolGlobalString('MAIN_MENU_SMARTPHONE_FORCED') && preg_match('/smartphone/', getDolGlobalString("MAIN_MENUFRONT_SMARTPHONE_FORCED"))
|| (!getDolGlobalString('MAIN_MENUFRONT_SMARTPHONE_FORCED') && getDolGlobalString('MAIN_MENU_SMARTPHONE') && preg_match('/smartphone/', getDolGlobalString('MAIN_MENUFRONT_SMARTPHONE')))) {
print ' '.img_warning($langs->transnoentitiesnoconv("ThisForceAlsoTheme"));
}

View File

@@ -3,7 +3,7 @@
* Copyright (C) 2007-2012 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2009-2011 Regis Houssin <regis.houssin@inodbox.com>
* Copyright (C) 2016 Meziane Sof <virtualsof@yahoo.fr>
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024-2026 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024-2025 Frédéric France <frederic.france@free.fr>
*
* This program is free software; you can redistribute it and/or modify
@@ -513,7 +513,7 @@ if ($action == 'create') {
print ', <span class="opacitymedium">'.$langs->trans("Example").': fk_mainmenu=abc&fk_leftmenu=def</span>';
print '</td></tr>';
// Niveau
// Level
//print '<tr><td>'.$langs->trans('Level').'</td><td>'.$menu->level.'</td><td>'.$langs->trans('DetailLevel').'</td></tr>';
// Title

View File

@@ -207,8 +207,8 @@ if ($action == 'up') {
$form = new Form($db);
$formadmin = new FormAdmin($db);
$arrayofjs = array('/includes/jquery/plugins/jquerytreeview/jquery.treeview.js', '/includes/jquery/plugins/jquerytreeview/lib/jquery.cookie.js');
$arrayofcss = array('/includes/jquery/plugins/jquerytreeview/jquery.treeview.css');
$arrayofjs = array('/public/includes/jquery/plugins/jquerytreeview/jquery.treeview.js', '/public/includes/jquery/plugins/jquerytreeview/lib/jquery.cookie.js');
$arrayofcss = array('/public/includes/jquery/plugins/jquerytreeview/jquery.treeview.css');
llxHeader('', $langs->trans("Menus"), '', '', 0, 0, $arrayofjs, $arrayofcss, '', 'mod-admin page-menus_index');

View File

@@ -414,7 +414,9 @@ if ($action == 'set' && $user->admin) {
// We made some check against evil eternal modules that try to low security options.
$checkOldValue = getDolGlobalInt('CHECKLASTVERSION_EXTERNALMODULE');
$csrfCheckOldValue = getDolGlobalInt('MAIN_SECURITY_CSRF_WITH_TOKEN');
$resarray = activateModule($value);
$resarray = activateModule($value, 1, 0, 'acceptredirect');
if ($checkOldValue != getDolGlobalInt('CHECKLASTVERSION_EXTERNALMODULE')) {
setEventMessage($langs->trans('WarningModuleHasChangedLastVersionCheckParameter', $value), 'warnings');
}
@@ -458,8 +460,11 @@ if ($action == 'set' && $user->admin) {
if ($result) {
setEventMessages($result, null, 'errors');
header("Location: ".$_SERVER["PHP_SELF"]."?mode=".$mode.$param.($page_y ? '&page_y='.$page_y : ''));
exit;
}
$resarray = activateModule($value, 0, 1);
$resarray = activateModule($value, 0, 1, 'acceptredirect');
dolibarr_set_const($db, "MAIN_IHM_PARAMS_REV", (getDolGlobalInt('MAIN_IHM_PARAMS_REV') + 1), 'chaine', 0, '', $conf->entity);
if (!empty($resarray['errors'])) {
setEventMessages('', $resarray['errors'], 'errors');
@@ -515,6 +520,7 @@ $filename = array();
$modules = array();
$orders = array();
$categ = array();
$timestoinit = [];
//$publisherlogoarray = array();
$i = 0; // is a sequencer of modules found
@@ -528,6 +534,7 @@ foreach ($modulesdir as $dir) {
//print $dir."\n<br>";
dol_syslog("Scan directory ".$dir." for module descriptor files (modXXX.class.php)");
$handle = @opendir($dir);
$timestart = microtime(true);
if (is_resource($handle)) {
while (($file = readdir($handle)) !== false) {
//print "$i ".$file."\n<br>";
@@ -595,6 +602,7 @@ foreach ($modulesdir as $dir) {
// Define an array $categ with categ with at least one qualified module
$filename[$i] = $modName;
$modules[$modName] = $objMod;
$timestoinit[$modName] = round((microtime(true) - $timestart) * 1000, 3);
// Gives the possibility to the module, to provide his own family info and position of this family
if (is_array($objMod->familyinfo) && !empty($objMod->familyinfo)) {
@@ -671,7 +679,7 @@ if ($action == 'reset_confirm' && $user->admin) {
}
$form = new Form($db);
$formconfirm = $form->formconfirm($_SERVER["PHP_SELF"].'?value='.$value.'&mode='.$mode.$param, $langs->trans('ConfirmUnactivation'), $langs->trans(GETPOST('confirm_message_code')), 'reset', '', 'no', 1);
$formconfirm = $form->formconfirm($_SERVER["PHP_SELF"].'?value='.$value.'&mode='.$mode.$param, $langs->trans('ConfirmUnactivation'), $langs->trans(GETPOST('confirm_message_code')), 'reset', '', 'no', 1, 300, 550);
}
}
@@ -1223,6 +1231,7 @@ if ($mode == 'common' || $mode == 'commonkanban') {
print '<a href="javascript:document_preview(\''.DOL_URL_ROOT.'/admin/modulehelp.php?id='.((int) $objMod->numero).'\',\'text/html\',\''.dol_escape_js($langs->trans("Module")).'\')">';
print img_picto(($objMod->isCoreOrExternalModule() == 'external' ? $langs->trans("ExternalModule").' - ' : '').$langs->trans("ClickToShowDescription"), $imginfo, '', 0, 0, 0, '', 'purple');
print '</a>';
print ($timestoinit[$modName] > 500 ? img_picto($langs->trans('InitModuleIsSlow'), 'fa-exclamation-circle') : '');
print '</td>';
// Version

View File

@@ -219,7 +219,7 @@ if ($conf->use_javascript_ajax) {
print ajax_constantonoff('MULTICURRENCY_USE_RATE_ON_DOCUMENT_DATE');
} else {
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
print $form->selectarray("MULTICURRENCY_USE_RATE_ON_DOCUMENT_DATE", $arrval, $conf->global->MULTICURRENCY_USE_RATE_ON_DOCUMENT_DATE);
print $form->selectarray("MULTICURRENCY_USE_RATE_ON_DOCUMENT_DATE", $arrval, getDolGlobalInt("MULTICURRENCY_USE_RATE_ON_DOCUMENT_DATE"));
}
print '</td></tr>';
@@ -232,7 +232,7 @@ if ($conf->use_javascript_ajax) {
print ajax_constantonoff('MULTICURRENCY_USE_ORIGIN_TX', array(), null, 0, 0, 0, 2, 0, 1);
} else {
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
print $form->selectarray("MULTICURRENCY_USE_ORIGIN_TX", $arrval, $conf->global->MULTICURRENCY_USE_ORIGIN_TX);
print $form->selectarray("MULTICURRENCY_USE_ORIGIN_TX", $arrval, getDolGlobalInt("MULTICURRENCY_USE_ORIGIN_TX"));
}
print '</td></tr>';
@@ -245,7 +245,7 @@ if (getDolGlobalInt('MAIN_FEATURES_LEVEL') >= 2) {
print ajax_constantonoff('MULTICURRENCY_USE_CURRENCY_ON_DOCUMENT');
} else {
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
print $form->selectarray("MULTICURRENCY_USE_CURRENCY_ON_DOCUMENT", $arrval, $conf->global->MULTICURRENCY_USE_CURRENCY_ON_DOCUMENT);
print $form->selectarray("MULTICURRENCY_USE_CURRENCY_ON_DOCUMENT", $arrval, getDolGlobalInt("MULTICURRENCY_USE_CURRENCY_ON_DOCUMENT"));
}
print '</td></tr>';
}

View File

@@ -24,10 +24,10 @@
// Load Dolibarr environment
require '../main.inc.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/openid_connect.lib.php';
require_once DOL_DOCUMENT_ROOT.'/core/class/html.form.class.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/openid_connect.lib.php';
require_once DOL_DOCUMENT_ROOT . '/core/lib/admin.lib.php';
require_once DOL_DOCUMENT_ROOT . '/core/lib/openid_connect.lib.php';
require_once DOL_DOCUMENT_ROOT . '/core/class/html.form.class.php';
require_once DOL_DOCUMENT_ROOT . '/core/lib/openid_connect.lib.php';
/**
* @var Conf $conf
@@ -111,6 +111,13 @@ if ($action == 'set') {
$errors[] = $db->lasterror();
$error++;
}
$openid_url_img = GETPOST('MAIN_AUTHENTICATION_OPENID_URL_IMG', 'alpha');
$res = dolibarr_set_const($db, 'MAIN_AUTHENTICATION_OPENID_URL_IMG', $openid_url_img, 'chaine', 0, '', 0);
if (!$res > 0) {
$errors[] = $db->lasterror();
$error++;
}
}
if ($action != '') {
@@ -133,14 +140,14 @@ llxHeader('', $langs->trans("Miscellaneous"), $wikihelp, '', 0, 0, '', '', '', '
print load_fiche_titre($langs->trans("SecuritySetup"), '', 'title_setup');
print '<span class="opacitymedium">'.$langs->trans("OpenIDDesc")."</span><br>\n";
print '<span class="opacitymedium">' . $langs->trans("OpenIDDesc") . "</span><br>\n";
print "<br>\n";
$head = security_prepare_head();
print dol_get_fiche_head($head, 'openid', '', -1);
$urlforwikidoc = img_picto('', 'url', 'class="pictofixedwidth"').'<a target="_blank" href="https://wiki.dolibarr.org/index.php?title=Authentication,_SSO_and_SSL#Mode_openid_connect">';
$urlforwikidoc = img_picto('', 'url', 'class="pictofixedwidth"') . '<a target="_blank" href="https://wiki.dolibarr.org/index.php?title=Authentication,_SSO_and_SSL#Mode_openid_connect">';
$urlforwikidoc .= $langs->trans("SeeHere");
$urlforwikidoc .= '</a>';
/*
@@ -156,9 +163,9 @@ if (!empty($conf->use_javascript_ajax)) {
print ajax_constantonoff('MAIN_AUTHENTICATION_OIDC_ON', array(), null, 0, 0, 1);
} else {
if (!getDolGlobalString('MAIN_AUTHENTICATION_OIDC_ON')) {
print '<a href="'.$_SERVER['PHP_SELF'].'?action=set_MAIN_AUTHENTICATION_OIDC_ON&token='.newToken().'">'.img_picto($langs->trans("Disabled"), 'off').'</a>';
print '<a href="' . $_SERVER['PHP_SELF'] . '?action=set_MAIN_AUTHENTICATION_OIDC_ON&token=' . newToken() . '">' . img_picto($langs->trans("Disabled"), 'off') . '</a>';
} else {
print '<a href="'.$_SERVER['PHP_SELF'].'?action=del_MAIN_AUTHENTICATION_OIDC_ON&token='.newToken().'">'.img_picto($langs->trans("Enabled"), 'on').'</a>';
print '<a href="' . $_SERVER['PHP_SELF'] . '?action=del_MAIN_AUTHENTICATION_OIDC_ON&token=' . newToken() . '">' . img_picto($langs->trans("Enabled"), 'on') . '</a>';
}
}
@@ -168,111 +175,137 @@ print '<br><br>';
if (getDolGlobalString('MAIN_AUTHENTICATION_OIDC_ON')) {
if (!preg_match('/openid_connect/', $dolibarr_main_authentication)) {
$langs->load("errors");
print info_admin($langs->trans("ErrorOpenIDSetupConfNotComplete").': '.$urlforwikidoc, 0, 0, 1, 'warning');
print info_admin($langs->trans("ErrorOpenIDSetupConfNotComplete") . ': ' . $urlforwikidoc, 0, 0, 1, 'warning');
} else {
print info_admin('In conf.php file: dolibarr_main_authentication is '.$dolibarr_main_authentication);
print info_admin('In conf.php file: dolibarr_main_authentication is ' . $dolibarr_main_authentication);
}
print '<br>';
print '<form method="post" action="'.dolBuildUrl($_SERVER["PHP_SELF"]).'">';
print '<input type="hidden" name="token" value="'.newToken().'">';
print '<div class="div-table-responsive-no-min">';
print '<table class="tagtable noborder liste nobottomiftotal">';
print '<tr class="liste_titre">';
print '<th class="liste_titre" colspan="3">' . $langs->trans("Parameters") . '</th>' . "\n";
print "</tr>\n";
print '<tr class="oddeven">' . "\n";
print '<td>' . $langs->trans("MainAuthenticationOidcAutofillWithWellknowUrl") . '</td>' . "\n";
print '<td align="right">' . "\n";
print '<input name="oidc_wellknow_url" id="oidc_wellknow_url" class="minwidth400 centpercent" value="">';
print '</td><td>' . "\n";
print '<input type="button" class="button smallpaddingimp reposition" id="oidc_wellknow_populate" value="'.$langs->trans("MainAuthenticationOidcAutofillButton").'"';
print '</td></tr>' . "\n";
print '</table>' . "\n";
print '</div>';
print '<br>';
print '<form method="post" action="' . dolBuildUrl($_SERVER["PHP_SELF"]) . '">';
print '<input type="hidden" name="token" value="' . newToken() . '">';
print '<input type="hidden" name="action" value="set">';
print '<div class="div-table-responsive-no-min">';
print '<table class="tagtable noborder liste nobottomiftotal">';
print '<tr class="liste_titre">';
print '<th class="liste_titre">'.$langs->trans("Parameters").'</th>'."\n";
print '<th class="liste_titre"></th>'."\n";
print '<th class="liste_titre"></th>'."\n";
print '<th class="liste_titre">' . $langs->trans("Parameters") . '</th>' . "\n";
print '<th class="liste_titre"></th>' . "\n";
print '<th class="liste_titre"></th>' . "\n";
print "</tr>\n";
// MAIN_AUTHENTICATION_OIDC_LOGIN_CLAIM
print '<tr class="oddeven">' . "\n";
print '<td>'.$langs->trans("MainAuthenticationOidcLoginClaimName").'</td>'."\n";
print '<td>'.$langs->trans("MainAuthenticationOidcLoginClaimDesc").'</td>'."\n";
print '<td>' . $langs->trans("MainAuthenticationOidcLoginClaimName") . '</td>' . "\n";
print '<td>' . $langs->trans("MainAuthenticationOidcLoginClaimDesc") . '</td>' . "\n";
print '<td align="right">' . "\n";
print '<input name="MAIN_AUTHENTICATION_OIDC_LOGIN_CLAIM" id="MAIN_AUTHENTICATION_OIDC_LOGIN_CLAIM" class="minwidth400" value="'.dol_escape_htmltag((GETPOSTISSET('MAIN_AUTHENTICATION_OIDC_LOGIN_CLAIM') ? GETPOST('MAIN_AUTHENTICATION_OIDC_LOGIN_CLAIM', 'nohtml') : (getDolGlobalString('MAIN_AUTHENTICATION_OIDC_LOGIN_CLAIM') ? getDolGlobalString("MAIN_AUTHENTICATION_OIDC_LOGIN_CLAIM") : ''))).'"></td></tr>';
print '<input name="MAIN_AUTHENTICATION_OIDC_LOGIN_CLAIM" id="MAIN_AUTHENTICATION_OIDC_LOGIN_CLAIM" class="minwidth400 centpercent" value="' . dol_escape_htmltag((GETPOSTISSET('MAIN_AUTHENTICATION_OIDC_LOGIN_CLAIM') ? GETPOST('MAIN_AUTHENTICATION_OIDC_LOGIN_CLAIM', 'nohtml') : (getDolGlobalString('MAIN_AUTHENTICATION_OIDC_LOGIN_CLAIM') ? getDolGlobalString("MAIN_AUTHENTICATION_OIDC_LOGIN_CLAIM") : ''))) . '">';
print '</td></tr>' . "\n";
// MAIN_AUTHENTICATION_OIDC_CLIENT_ID
print '<tr class="oddeven">' . "\n";
print '<td>'.$langs->trans("MainAuthenticationOidcClientIdName").'</td>'."\n";
print '<td>'.$langs->trans("MainAuthenticationOidcClientIdDesc").'</td>'."\n";
print '<td>' . $langs->trans("MainAuthenticationOidcClientIdName") . '</td>' . "\n";
print '<td>' . $langs->trans("MainAuthenticationOidcClientIdDesc") . '</td>' . "\n";
print '<td align="right">' . "\n";
print '<input name="MAIN_AUTHENTICATION_OIDC_CLIENT_ID" id="MAIN_AUTHENTICATION_OIDC_CLIENT_ID" class="minwidth400" value="'.dol_escape_htmltag((GETPOSTISSET('MAIN_AUTHENTICATION_OIDC_CLIENT_ID') ? GETPOST('MAIN_AUTHENTICATION_OIDC_CLIENT_ID', 'nohtml') : (getDolGlobalString('MAIN_AUTHENTICATION_OIDC_CLIENT_ID') ? getDolGlobalString("MAIN_AUTHENTICATION_OIDC_CLIENT_ID") : ''))).'"></td></tr>';
print '<input name="MAIN_AUTHENTICATION_OIDC_CLIENT_ID" id="MAIN_AUTHENTICATION_OIDC_CLIENT_ID" class="minwidth400 centpercent" value="' . dol_escape_htmltag((GETPOSTISSET('MAIN_AUTHENTICATION_OIDC_CLIENT_ID') ? GETPOST('MAIN_AUTHENTICATION_OIDC_CLIENT_ID', 'nohtml') : (getDolGlobalString('MAIN_AUTHENTICATION_OIDC_CLIENT_ID') ? getDolGlobalString("MAIN_AUTHENTICATION_OIDC_CLIENT_ID") : ''))) . '">';
print '</td></tr>' . "\n";
// MAIN_AUTHENTICATION_OIDC_CLIENT_SECRET
print '<tr class="oddeven">' . "\n";
print '<td>'.$langs->trans("MainAuthenticationOidcClientSecretName").'</td>'."\n";
print '<td>'.$langs->trans("MainAuthenticationOidcClientSecretDesc").'</td>'."\n";
print '<td>' . $langs->trans("MainAuthenticationOidcClientSecretName") . '</td>' . "\n";
print '<td>' . $langs->trans("MainAuthenticationOidcClientSecretDesc") . '</td>' . "\n";
print '<td align="right">' . "\n";
print '<input type="password" name="MAIN_AUTHENTICATION_OIDC_CLIENT_SECRET" id="MAIN_AUTHENTICATION_OIDC_CLIENT_SECRET" class="minwidth400" value="'.dol_escape_htmltag((GETPOSTISSET('MAIN_AUTHENTICATION_OIDC_CLIENT_SECRET') ? GETPOST('MAIN_AUTHENTICATION_OIDC_CLIENT_SECRET', 'nohtml') : (getDolGlobalString('MAIN_AUTHENTICATION_OIDC_CLIENT_SECRET') ? getDolGlobalString("MAIN_AUTHENTICATION_OIDC_CLIENT_SECRET") : ''))).'"></td></tr>';
print '<input type="password" name="MAIN_AUTHENTICATION_OIDC_CLIENT_SECRET" id="MAIN_AUTHENTICATION_OIDC_CLIENT_SECRET" class="minwidth400 centpercent" value="' . dol_escape_htmltag((GETPOSTISSET('MAIN_AUTHENTICATION_OIDC_CLIENT_SECRET') ? GETPOST('MAIN_AUTHENTICATION_OIDC_CLIENT_SECRET', 'nohtml') : (getDolGlobalString('MAIN_AUTHENTICATION_OIDC_CLIENT_SECRET') ? getDolGlobalString("MAIN_AUTHENTICATION_OIDC_CLIENT_SECRET") : ''))) . '">';
print '</td></tr>' . "\n";
// MAIN_AUTHENTICATION_OIDC_SCOPES
print '<tr class="oddeven">' . "\n";
print '<td>'.$langs->trans("MainAuthenticationOidcScopesName").'</td>'."\n";
print '<td>'.$langs->trans("MainAuthenticationOidcScopesDesc").'</td>'."\n";
print '<td>' . $langs->trans("MainAuthenticationOidcScopesName") . '</td>' . "\n";
print '<td>' . $langs->trans("MainAuthenticationOidcScopesDesc") . '</td>' . "\n";
print '<td align="right">' . "\n";
print '<input name="MAIN_AUTHENTICATION_OIDC_SCOPES" id="MAIN_AUTHENTICATION_OIDC_SCOPES" class="minwidth400" value="'.dol_escape_htmltag((GETPOSTISSET('MAIN_AUTHENTICATION_OIDC_SCOPES') ? GETPOST('MAIN_AUTHENTICATION_OIDC_SCOPES', 'nohtml') : (getDolGlobalString('MAIN_AUTHENTICATION_OIDC_SCOPES') ? getDolGlobalString("MAIN_AUTHENTICATION_OIDC_SCOPES") : ''))).'"></td></tr>';
print '<input name="MAIN_AUTHENTICATION_OIDC_SCOPES" id="MAIN_AUTHENTICATION_OIDC_SCOPES" class="minwidth400 centpercent" value="' . dol_escape_htmltag((GETPOSTISSET('MAIN_AUTHENTICATION_OIDC_SCOPES') ? GETPOST('MAIN_AUTHENTICATION_OIDC_SCOPES', 'nohtml') : (getDolGlobalString('MAIN_AUTHENTICATION_OIDC_SCOPES') ? getDolGlobalString("MAIN_AUTHENTICATION_OIDC_SCOPES") : ''))) . '">';
print '</td></tr>' . "\n";
// MAIN_AUTHENTICATION_OIDC_AUTHORIZE_URL
print '<tr class="oddeven">' . "\n";
print '<td>'.$langs->trans("MainAuthenticationOidcAuthorizeUrlName").'</td>'."\n";
print '<td>'.$langs->trans("MainAuthenticationOidcAuthorizeUrlDesc").'</td>'."\n";
print '<td>' . $langs->trans("MainAuthenticationOidcAuthorizeUrlName") . '</td>' . "\n";
print '<td>' . $langs->trans("MainAuthenticationOidcAuthorizeUrlDesc") . '</td>' . "\n";
print '<td align="right">' . "\n";
print '<input name="MAIN_AUTHENTICATION_OIDC_AUTHORIZE_URL" id="MAIN_AUTHENTICATION_OIDC_AUTHORIZE_URL" class="minwidth400" value="'.dol_escape_htmltag((GETPOSTISSET('MAIN_AUTHENTICATION_OIDC_AUTHORIZE_URL') ? GETPOST('MAIN_AUTHENTICATION_OIDC_AUTHORIZE_URL', 'nohtml') : (getDolGlobalString('MAIN_AUTHENTICATION_OIDC_AUTHORIZE_URL') ? getDolGlobalString("MAIN_AUTHENTICATION_OIDC_AUTHORIZE_URL") : ''))).'"></td></tr>';
print '<input name="MAIN_AUTHENTICATION_OIDC_AUTHORIZE_URL" id="MAIN_AUTHENTICATION_OIDC_AUTHORIZE_URL" class="minwidth400 centpercent" value="' . dol_escape_htmltag((GETPOSTISSET('MAIN_AUTHENTICATION_OIDC_AUTHORIZE_URL') ? GETPOST('MAIN_AUTHENTICATION_OIDC_AUTHORIZE_URL', 'nohtml') : (getDolGlobalString('MAIN_AUTHENTICATION_OIDC_AUTHORIZE_URL') ? getDolGlobalString("MAIN_AUTHENTICATION_OIDC_AUTHORIZE_URL") : ''))) . '">';
print '</td></tr>' . "\n";
// MAIN_AUTHENTICATION_OIDC_TOKEN_URL
print '<tr class="oddeven">' . "\n";
print '<td>'.$langs->trans("MainAuthenticationOidcTokenUrlName").'</td>'."\n";
print '<td>'.$langs->trans("MainAuthenticationOidcTokenUrlDesc").'</td>'."\n";
print '<td>' . $langs->trans("MainAuthenticationOidcTokenUrlName") . '</td>' . "\n";
print '<td>' . $langs->trans("MainAuthenticationOidcTokenUrlDesc") . '</td>' . "\n";
print '<td align="right">' . "\n";
print '<input name="MAIN_AUTHENTICATION_OIDC_TOKEN_URL" id="MAIN_AUTHENTICATION_OIDC_TOKEN_URL" class="minwidth400" value="'.dol_escape_htmltag((GETPOSTISSET('MAIN_AUTHENTICATION_OIDC_TOKEN_URL') ? GETPOST('MAIN_AUTHENTICATION_OIDC_TOKEN_URL', 'nohtml') : (getDolGlobalString('MAIN_AUTHENTICATION_OIDC_TOKEN_URL') ? getDolGlobalString("MAIN_AUTHENTICATION_OIDC_TOKEN_URL") : ''))).'"></td></tr>';
print '<input name="MAIN_AUTHENTICATION_OIDC_TOKEN_URL" id="MAIN_AUTHENTICATION_OIDC_TOKEN_URL" class="minwidth400 centpercent" value="' . dol_escape_htmltag((GETPOSTISSET('MAIN_AUTHENTICATION_OIDC_TOKEN_URL') ? GETPOST('MAIN_AUTHENTICATION_OIDC_TOKEN_URL', 'nohtml') : (getDolGlobalString('MAIN_AUTHENTICATION_OIDC_TOKEN_URL') ? getDolGlobalString("MAIN_AUTHENTICATION_OIDC_TOKEN_URL") : ''))) . '">';
print '</td></tr>' . "\n";
// MAIN_AUTHENTICATION_OIDC_USERINFO_URL
print '<tr class="oddeven">' . "\n";
print '<td>'.$langs->trans("MainAuthenticationOidcUserinfoUrlName").'</td>'."\n";
print '<td>'.$langs->trans("MainAuthenticationOidcUserinfoUrlDesc").'</td>'."\n";
print '<td>' . $langs->trans("MainAuthenticationOidcUserinfoUrlName") . '</td>' . "\n";
print '<td>' . $langs->trans("MainAuthenticationOidcUserinfoUrlDesc") . '</td>' . "\n";
print '<td align="right">' . "\n";
print '<input name="MAIN_AUTHENTICATION_OIDC_USERINFO_URL" id="MAIN_AUTHENTICATION_OIDC_USERINFO_URL" class="minwidth400" value="'.dol_escape_htmltag((GETPOSTISSET('MAIN_AUTHENTICATION_OIDC_USERINFO_URL') ? GETPOST('MAIN_AUTHENTICATION_OIDC_USERINFO_URL', 'nohtml') : (getDolGlobalString('MAIN_AUTHENTICATION_OIDC_USERINFO_URL') ? getDolGlobalString("MAIN_AUTHENTICATION_OIDC_USERINFO_URL") : ''))).'"></td></tr>';
print '<input name="MAIN_AUTHENTICATION_OIDC_USERINFO_URL" id="MAIN_AUTHENTICATION_OIDC_USERINFO_URL" class="minwidth400 centpercent" value="' . dol_escape_htmltag((GETPOSTISSET('MAIN_AUTHENTICATION_OIDC_USERINFO_URL') ? GETPOST('MAIN_AUTHENTICATION_OIDC_USERINFO_URL', 'nohtml') : (getDolGlobalString('MAIN_AUTHENTICATION_OIDC_USERINFO_URL') ? getDolGlobalString("MAIN_AUTHENTICATION_OIDC_USERINFO_URL") : ''))) . '">';
print '</td></tr>' . "\n";
// MAIN_AUTHENTICATION_OIDC_LOGOUT_URL
print '<tr class="oddeven">' . "\n";
print '<td>'.$langs->trans("MainAuthenticationOidcLogoutUrlName").'</td>'."\n";
print '<td>'.$langs->trans("MainAuthenticationOidcLogoutUrlDesc").'</td>'."\n";
print '<td>' . $langs->trans("MainAuthenticationOidcLogoutUrlName") . '</td>' . "\n";
print '<td>' . $langs->trans("MainAuthenticationOidcLogoutUrlDesc") . '</td>' . "\n";
print '<td align="right">' . "\n";
print '<input name="MAIN_AUTHENTICATION_OIDC_LOGOUT_URL" id="MAIN_AUTHENTICATION_OIDC_LOGOUT_URL" class="minwidth400" value="'.dol_escape_htmltag((GETPOSTISSET('MAIN_AUTHENTICATION_OIDC_LOGOUT_URL') ? GETPOST('MAIN_AUTHENTICATION_OIDC_LOGOUT_URL', 'nohtml') : (getDolGlobalString('MAIN_AUTHENTICATION_OIDC_LOGOUT_URL') ? getDolGlobalString("MAIN_AUTHENTICATION_OIDC_LOGOUT_URL") : ''))).'"></td></tr>';
print '<input name="MAIN_AUTHENTICATION_OIDC_LOGOUT_URL" id="MAIN_AUTHENTICATION_OIDC_LOGOUT_URL" class="minwidth400 centpercent" value="' . dol_escape_htmltag((GETPOSTISSET('MAIN_AUTHENTICATION_OIDC_LOGOUT_URL') ? GETPOST('MAIN_AUTHENTICATION_OIDC_LOGOUT_URL', 'nohtml') : (getDolGlobalString('MAIN_AUTHENTICATION_OIDC_LOGOUT_URL') ? getDolGlobalString("MAIN_AUTHENTICATION_OIDC_LOGOUT_URL") : ''))) . '">';
print '</td></tr>' . "\n";
// REDIRECT_URL
print '<tr class="oddeven">' . "\n";
print '<td>'.$langs->trans("MainAuthenticationOidcRedirectUrlName").'</td>'."\n";
print '<td>'.$langs->trans("MainAuthenticationOidcRedirectUrlDesc").'</td>'."\n";
print '<td>' . $langs->trans("MainAuthenticationOidcRedirectUrlName") . '</td>' . "\n";
print '<td>' . $langs->trans("MainAuthenticationOidcRedirectUrlDesc") . '</td>' . "\n";
print '<td align="right">' . "\n";
print '<input class="minwidth400" value="'.dol_escape_htmltag(openid_connect_get_redirect_url()).'" disabled></td></tr>';
print '<input class="minwidth400 centpercent" value="' . dol_escape_htmltag(openid_connect_get_redirect_url()) . '" disabled>';
print '</td></tr>' . "\n";
// LOGOUT_URL
print '<tr class="oddeven">' . "\n";
print '<td>'.$langs->trans("MainAuthenticationOidcLogoutRedirectUrlName").'</td>'."\n";
print '<td>'.$langs->trans("MainAuthenticationOidcLogoutRedirectUrlDesc").'</td>'."\n";
print '<td>' . $langs->trans("MainAuthenticationOidcLogoutRedirectUrlName") . '</td>' . "\n";
print '<td>' . $langs->trans("MainAuthenticationOidcLogoutRedirectUrlDesc") . '</td>' . "\n";
print '<td align="right">' . "\n";
print '<input class="minwidth400" value="'.dol_escape_htmltag(getDolGlobalString('MAIN_LOGOUT_GOTO_URL', DOL_MAIN_URL_ROOT . "/index.php")).'" disabled></td></tr>';
print '<input class="minwidth400 centpercent" value="' . dol_escape_htmltag(getDolGlobalString('MAIN_LOGOUT_GOTO_URL', DOL_MAIN_URL_ROOT . "/index.php")) . '" disabled>';
print '</td></tr>' . "\n";
print '</table>'."\n";
// OPENID_URL_IMG
print '<tr class="oddeven">' . "\n";
print '<td>' . $langs->trans("MainAuthenticationOpenIDUrlImgName") . '</td>' . "\n";
print '<td>' . $langs->trans("MainAuthenticationOpenIDUrlImgDesc") . '</td>' . "\n";
print '<td align="right">' . "\n";
print '<input name="MAIN_AUTHENTICATION_OPENID_URL_IMG" id="MAIN_AUTHENTICATION_OPENID_URL_IMG" class="minwidth400 centpercent" value="' . dol_escape_htmltag((GETPOSTISSET('MAIN_AUTHENTICATION_OPENID_URL_IMG') ? GETPOST('MAIN_AUTHENTICATION_OPENID_URL_IMG', 'nohtml') : (getDolGlobalString('MAIN_AUTHENTICATION_OPENID_URL_IMG') ? getDolGlobalString("MAIN_AUTHENTICATION_OPENID_URL_IMG") : ''))) . '">';
print '</td></tr>' . "\n";
print '</table>' . "\n";
print '</div>';
print '<br>';
print '<div align="center">';
print '<input type="submit" class="button" value="'.$langs->trans("Save").'">';
print '<input type="submit" class="button" value="' . $langs->trans("Save") . '">';
print '</div>';
print '</form>';
@@ -282,3 +315,41 @@ print '<br>';
llxFooter();
$db->close();
?>
<script type="text/javascript">
$(document).ready(function() {
$('#oidc_wellknow_populate').on('click', function() {
const url = $('#oidc_wellknow_url').val().trim();
if (!url) return;
// Ensure URL ends with /.well-known/openid-configuration
let wellKnownUrl = url;
if (!wellKnownUrl.endsWith('/.well-known/openid-configuration')) {
if (!wellKnownUrl.endsWith('/')) wellKnownUrl += '/';
wellKnownUrl += '.well-known/openid-configuration';
}
$.getJSON(wellKnownUrl)
.done(function(data) {
if (data.authorization_endpoint) {
$('#MAIN_AUTHENTICATION_OIDC_AUTHORIZE_URL').val(data.authorization_endpoint);
}
if (data.token_endpoint) {
$('#MAIN_AUTHENTICATION_OIDC_TOKEN_URL').val(data.token_endpoint);
}
if (data.userinfo_endpoint) {
$('#MAIN_AUTHENTICATION_OIDC_USERINFO_URL').val(data.userinfo_endpoint);
}
if (data.end_session_endpoint) {
$('#MAIN_AUTHENTICATION_OIDC_LOGOUT_URL').val(data.end_session_endpoint);
}
if (data.scopes_supported) {
$('#MAIN_AUTHENTICATION_OIDC_SCOPES').val(data.scopes_supported.join(' '));
}
})
.fail(function() {
alert('Failed to fetch OIDC well-known configuration from: ' + wellKnownUrl);
});
});
});
</script>

View File

@@ -34,11 +34,6 @@
// Load Dolibarr environment
require '../main.inc.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/pdf.lib.php';
require_once DOL_DOCUMENT_ROOT.'/commande/class/commande.class.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/order.lib.php';
/**
* @var Conf $conf
* @var DoliDB $db
@@ -47,6 +42,10 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/order.lib.php';
* @var Translate $langs
* @var User $user
*/
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/pdf.lib.php';
require_once DOL_DOCUMENT_ROOT.'/commande/class/commande.class.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/order.lib.php';
// Load translation files required by the page
$langs->loadLangs(array('admin', 'errors', 'orders', 'other'));

View File

@@ -8,6 +8,7 @@
* Copyright (C) 2022 Alexandre Spangaro <aspangaro@open-dsi.fr>
* Copyright (C) 2024-2025 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024-2025 Nick Fragoulis
* Copyright (C) 2025 William Mead <william@m34d.com>
*
* 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
@@ -67,6 +68,10 @@ if ($modulepart == 'order') {
$diroffile = $conf->order->dir_output;
$varname = 'MAIN_INFO_ORDER_TERMSOFSALE';
}
if ($modulepart == 'contrat') {
$diroffile = $conf->contract->dir_output;
$varname = 'MAIN_INFO_CONTRACT_TERMSOFSALE';
}
if ($modulepart == 'invoice') {
$diroffile = $conf->invoice->dir_output;
$varname = 'MAIN_INFO_INVOICE_TERMSOFSALE';
@@ -118,6 +123,9 @@ if ($action == 'update') {
if (GETPOSTISSET('MAIN_PDF_ADD_TERMSOFSALE_ORDER')) {
dolibarr_set_const($db, "MAIN_PDF_ADD_TERMSOFSALE_ORDER", GETPOST("MAIN_PDF_ADD_TERMSOFSALE_ORDER", 'int'), 'chaine', 0, '', $conf->entity);
}
if (GETPOSTISSET('MAIN_PDF_ADD_TERMSOFSALE_CONTRACT')) {
dolibarr_set_const($db, "MAIN_PDF_ADD_TERMSOFSALE_CONTRACT", GETPOST("MAIN_PDF_ADD_TERMSOFSALE_CONTRACT", 'int'), 'chaine', 0, '', $conf->entity);
}
if (GETPOSTISSET('MAIN_PDF_ADD_TERMSOFSALE_INVOICE')) {
dolibarr_set_const($db, "MAIN_PDF_ADD_TERMSOFSALE_INVOICE", GETPOST("MAIN_PDF_ADD_TERMSOFSALE_INVOICE", 'int'), 'chaine', 0, '', $conf->entity);
}
@@ -166,19 +174,27 @@ if ($action == 'update') {
if (GETPOSTISSET('BARCODE_ON_STOCKTRANSFER_PDF')) {
dolibarr_set_const($db, "BARCODE_ON_STOCKTRANSFER_PDF", GETPOSTINT("BARCODE_ON_STOCKTRANSFER_PDF"), 'chaine', 0, '', $conf->entity);
}
// add file to concat
foreach (array('MAIN_INFO_PROPAL_TERMSOFSALE', 'MAIN_INFO_ORDER_TERMSOFSALE', 'MAIN_INFO_INVOICE_TERMSOFSALE') as $varname) {
// add a file to concat
$concat_options = array('MAIN_INFO_PROPAL_TERMSOFSALE', 'MAIN_INFO_ORDER_TERMSOFSALE', 'MAIN_INFO_CONTRACT_TERMSOFSALE', 'MAIN_INFO_INVOICE_TERMSOFSALE');
foreach ($concat_options as $varname) {
if (isset($_FILES[$varname]) && $_FILES[$varname]["name"]) {
if (!preg_match('/(\.pdf)$/i', $_FILES[$varname]["name"])) { // Document can be used on a lot of different places. Only pdf can be supported.
$langs->load("errors");
setEventMessages($langs->trans("ErrorBadFormat"), null, 'errors');
} else {
if ($varname == 'MAIN_INFO_PROPAL_TERMSOFSALE') {
$diroffile = $conf->propal->dir_output;
} elseif ($varname == 'MAIN_INFO_ORDER_TERMSOFSALE') {
$diroffile = $conf->order->dir_output;
} elseif ($varname == 'MAIN_INFO_INVOICE_TERMSOFSALE') {
$diroffile = $conf->invoice->dir_output;
switch ($varname) {
case 'MAIN_INFO_PROPAL_TERMSOFSALE':
$diroffile = $conf->propal->dir_output;
break;
case 'MAIN_INFO_ORDER_TERMSOFSALE':
$diroffile = $conf->order->dir_output;
break;
case 'MAIN_INFO_CONTRACT_TERMSOFSALE':
$diroffile = $conf->contract->dir_output;
break;
case 'MAIN_INFO_INVOICE_TERMSOFSALE':
$diroffile = $conf->invoice->dir_output;
break;
}
if ($diroffile) {
$dirforterms = $diroffile.'/';
@@ -413,6 +429,49 @@ if (isModEnabled('order')) {
print '<br>';
}
if (isModEnabled('contract')) {
print '<div id="contrat" class="undertopmenu"></div>';
print load_fiche_titre($langs->trans("Contract"), '', 'contract');
print '<div class="div-table-responsive-no-min">';
print '<table summary="more" class="noborder centpercent">';
print '<tr class="liste_titre"><td class="titlefieldmiddle">'.$langs->trans("Parameter").'</td><td width="200px"></td></tr>';
// Concat PDF
print '<tr class="oddeven"><td>';
print $form->textwithpicto($langs->trans("MAIN_PDF_ADD_TERMSOFSALE_CONTRACT"), $tooltipconcatpdf);
print '</td><td>';
if ($conf->use_javascript_ajax) {
print ajax_constantonoff('MAIN_PDF_ADD_TERMSOFSALE_CONTRACT', array(), null, 0, 0, 1);
} else {
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
print $form->selectarray("MAIN_PDF_ADD_TERMSOFSALE_CONTRACT", $arrval, getDolGlobalString('MAIN_PDF_ADD_TERMSOFSALE_CONTRACT'));
}
if (getDolGlobalString("MAIN_PDF_ADD_TERMSOFSALE_CONTRACT")) {
$modulepart = 'contrat';
print '<div class="inline-block nobordernopadding valignmiddle "><div class="inline-block marginrightonly">';
print '<input type="file" class="flat minwidth100 maxwidthinputfileonsmartphone" name="MAIN_INFO_CONTRACT_TERMSOFSALE" id="MAIN_INFO_CONTRACT_TERMSOFSALE" accept="application/pdf">';
print '</div>';
if (getDolGlobalString("MAIN_INFO_CONTRACT_TERMSOFSALE")) {
$termofsale = getDolGlobalString("MAIN_INFO_CONTRACT_TERMSOFSALE");
if (file_exists($conf->contract->dir_output.'/'.$termofsale)) {
$file = dol_dir_list($conf->contract->dir_output, 'files', 0, $termofsale);
print ' ';
print '<div class="inline-block valignmiddle marginrightonly"><a href="'.$documenturl.'?modulepart='.$modulepart.'&file='.urlencode($termofsale).'">'.$termofsale.'</a>'.$formfile->showPreview($file[0], $modulepart, $termofsale, 0, '').'</div>';
print '<div class="inline-block valignmiddle marginrightonly"><a class="reposition" href="'.$_SERVER["PHP_SELF"].'?action=removetermsofsale&modulepart='.$modulepart.'&token='.newToken().'">'.img_delete($langs->trans("Delete"), '', 'marginleftonly').'</a></div>';
}
}
print '</div>';
}
print '</td></tr>';
print '</table>';
print '</div>';
print '<br>';
}
if (isModEnabled('invoice')) {
print '<div id="invoice" class="undertopmenu"></div>';

View File

@@ -38,7 +38,7 @@ require '../main.inc.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';
require_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/receiptprinter.lib.php';
require_once DOL_DOCUMENT_ROOT.'/core/class/dolreceiptprinter.class.php';
require_once DOL_DOCUMENT_ROOT.'/takepos/class/dolreceiptprinter.class.php';
// Load translation files required by the page
$langs->loadLangs(array("admin", "receiptprinter"));
@@ -487,7 +487,7 @@ if ($mode == 'template') {
print '<input type="hidden" name="templateid" value="'.($printer->listprinterstemplates[$line]['rowid'] ?? '').'">';
print '<td><input type="text" class="minwidth200" name="templatename" value="'.($printer->listprinterstemplates[$line]['name'] ?? '').'"></td>';
print '<td class="wordbreak">';
print '<textarea name="template" wrap="soft" cols="120" rows="12">'.($printer->listprinterstemplates[$line]['template'] ?? '').'</textarea>';
print '<textarea name="template" wrap="soft" cols="90" rows="12">'.($printer->listprinterstemplates[$line]['template'] ?? '').'</textarea>';
print '</td>';
print '<td>';
print $form->buttonsSaveCancel("Save", '');
@@ -516,7 +516,7 @@ if ($mode == 'template') {
print '<tr>';
print '<td><input type="text" class="minwidth200" name="templatename" value="'.($printer->listprinterstemplates[$line]['name'] ?? '').'"></td>';
print '<td class="wordbreak">';
print '<textarea name="template" wrap="soft" cols="120" rows="12">';
print '<textarea name="template" wrap="soft" cols="90" rows="12">';
print '</textarea>';
print '</td>';
print '<td>';

View File

@@ -187,7 +187,7 @@ print '</tr>';
print '<tr class="oddeven">';
print '<td>'.$langs->trans("MaxSizeForUploadedFiles").'.';
$max = @ini_get('upload_max_filesize');
if (isset($max)) {
if (!empty($max)) {
print '<br><span class="opacitymedium">'.$langs->trans("MustBeLowerThanPHPLimit", ((int) $max) * 1024, $langs->trans("Kb")).'.</span>';
} else {
print ' '.$langs->trans("NoMaxSizeByPHPLimit").'.';

View File

@@ -166,9 +166,9 @@ if (preg_match('/set_([a-z0-9_\-]+)/i', $action, $reg)) {
$sourcetype = $sourcesarray[$directivetype][$sourcecsp]["data-sourcetype"];
}
$securitycspstring = "";
if (isset($sourcetype) && $sourcetype == "data") {
if ($sourcetype == "data") {
$forceCSPArr[$directivecsp][] = "data:".$sourcedatacsp;
} elseif (isset($sourcetype) && $sourcetype == "input") {
} elseif ($sourcetype == "input") {
if (empty($forceCSPArr[$directivecsp])) {
$forceCSPArr[$directivecsp] = array();
}

View File

@@ -3,7 +3,7 @@
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@inodbox.com>
* Copyright (C) 2012-2013 Juanjo Menent <jmenent@2byte.es>
* Copyright (C) 2019 Christophe Battarel <christophe@altairis.fr>
* Copyright (C) 2024 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024-2025 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2025 Charlene Benke <charlene@patas-monkey.com>
*
@@ -63,6 +63,20 @@ $modules = [
'FICHINTER' => array('lang' => 'interventions', 'key' => 'Intervention', 'old_pdf' => '(soleil model)'),
'FACTURE' => array('lang' => 'bills', 'key' => 'CustomerInvoice', 'old_pdf' => '(crabe model)'),
'FACTUREREC' => array('lang' => 'bills', 'key' => 'RecurringInvoiceTemplate'),
'SUPPLIER_PROPOSAL' => [
'lang' => 'supplier_proposal',
'key' => 'SupplierProposal',
'old_pdf' => '(aurore model)',
],
'ORDER_SUPPLIER' => [
'lang' => 'orders',
'key' => 'SupplierOrder',
'old_pdf' => '(muscadet model)',
],
'INVOICE_SUPPLIER' => [
'lang' => 'bills',
'key' => 'SupplierInvoice',
],
];
// Conditions for the option to be offered
$conditions = [
@@ -71,6 +85,9 @@ $conditions = [
'FICHINTER' => (isModEnabled("intervention")),
'FACTURE' => isModEnabled("invoice"),
'FACTUREREC' => isModEnabled("invoice"),
'SUPPLIER_PROPOSAL' => isModEnabled("supplier_proposal"),
'ORDER_SUPPLIER' => isModEnabled("supplier_order"),
'INVOICE_SUPPLIER' => isModEnabled("supplier_invoice"),
];
$max_depth = 0;

View File

@@ -261,7 +261,7 @@ foreach ($syslogModules as $moduleName) {
$value = (isset($option['default']) ? $option['default'] : '');
}
print '<span class="hideonsmartphone opacitymedium">'.$option['name'].': </span><input type="text" class="flat'.(empty($option['css']) ? '' : ' '.$option['css']).'" name="'.dol_escape_htmltag($option['constant']).'" value="'.$value.'"'.(isset($option['attr']) ? ' '.$option['attr'] : '').'>';
print '<span class="hideonsmartphone opacitymedium">'.$option['name'].': </span><input type="text" placeholder="'.$option['default'].'" class="flat'.(empty($option['css']) ? '' : ' '.$option['css']).'" name="'.dol_escape_htmltag($option['constant']).'" value="'.$value.'"'.(isset($option['attr']) ? ' '.$option['attr'] : '').'>';
if (!empty($option['example'])) {
print '<br>'.$langs->trans("Example").': '.dol_escape_htmltag($option['example']);
}

View File

@@ -147,6 +147,7 @@ if ($logsql) {
// Define request to get table description
$base = 0;
$sql = null;
$row = array();
if (preg_match('/mysql/i', $conf->db->type)) {
$sql = "SHOW TABLE STATUS LIKE '".$db->escape($db->escapeforlike($table))."'";
$base = 1;

View File

@@ -3,7 +3,7 @@
* Copyright (C) 2007 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2007-2012 Regis Houssin <regis.houssin@inodbox.com>
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024-2025 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2024-2026 Frédéric France <frederic.france@free.fr>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -34,6 +34,7 @@ require '../../main.inc.php';
* @var User $user
*
* @var string $dolibarr_main_document_root_alt
* @var string $dolibarr_main_prod
* @var string $conffile
*/
'
@@ -64,7 +65,6 @@ $version = '0.0';
if ($action == 'getlastversion') {
$result = getURLContent('https://sourceforge.net/projects/dolibarr/rss');
//var_dump($result['content']);
if (function_exists('simplexml_load_string')) {
if (LIBXML_VERSION < 20900) {
// Avoid load of external entities (security problem).
@@ -325,10 +325,10 @@ print '</td></tr>'."\n";
print '</td></tr>'."\n";
print '<tr class="oddeven"><td>&nbsp; => '.$langs->trans("ClientHour").'</td><td>'.dol_print_date(dol_now('gmt'), 'dayhour', 'tzuser').'</td></tr>'."\n";
$filesystemencoding = ini_get("unicode.filesystem_encoding"); // Disponible avec PHP 6.0
$filesystemencoding = ini_get("unicode.filesystem_encoding"); // Available with PHP 6.0
print '<tr class="oddeven"><td>'.$langs->trans("File encoding").' (php.ini unicode.filesystem_encoding)</td><td>'.$filesystemencoding.'</td></tr>'."\n";
$tmp = ini_get("unicode.filesystem_encoding"); // Disponible avec PHP 6.0
$tmp = ini_get("unicode.filesystem_encoding"); // Available with PHP 6.0
if (empty($tmp) && !empty($_SERVER["WINDIR"])) {
$tmp = 'iso-8859-1'; // By default for windows
}

View File

@@ -255,7 +255,7 @@ jQuery(document).ready(function() {
getcssurl = $.ajax({
type: "GET",
data: { token: \'notrequired\' },
url: \''.DOL_URL_ROOT.'/includes/jquery/css/base/jquery-ui.css\',
url: \''.DOL_URL_ROOT.'/public/includes/jquery/css/base/jquery-ui.css\',
cache: false,
/* async: false, */
/* crossDomain: true, */

View File

@@ -53,10 +53,7 @@ if (!$user->admin) {
llxHeader('', '', '', '', 0, 0, '', '', '', 'mod-admin page-system_phpinfo');
$title = 'InfoPHP';
if (isset($title)) {
print load_fiche_titre($langs->trans($title), '', 'title_setup');
}
print load_fiche_titre($langs->trans($title), '', 'title_setup');
// Check PHP setup is OK

View File

@@ -1,6 +1,6 @@
<?php
/* Copyright (C) 2013-2022 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2024 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024-2026 MDW <mdeweerd@users.noreply.github.com>
* Copyright (C) 2024-2025 Frédéric France <frederic.france@free.fr>
*
* This program is free software; you can redistribute it and/or modify

View File

@@ -231,6 +231,17 @@ if ($action == 'updateMask') {
$error++;
}
$notification_email_template = GETPOST('TICKET_NOTIFICATION_EMAIL_TEMPLATE', 'alpha');
$notification_email_template_description = 'Template email for ticket create notification';
if (!empty($notification_email_to)) {
$res = dolibarr_set_const($db, 'TICKET_NOTIFICATION_EMAIL_TEMPLATE', $notification_email_template, 'chaine', 0, $notification_email_template_description, $conf->entity);
} else {
$res = dolibarr_set_const($db, 'TICKET_NOTIFICATION_EMAIL_TEMPLATE', '', 'chaine', 0, $notification_email_template_description, $conf->entity);
}
if (!($res > 0)) {
$error++;
}
$mail_intro = GETPOST('TICKET_MESSAGE_MAIL_INTRO', 'restricthtml');
$mail_intro_description = "Introduction text of ticket replies sent from Dolibarr";
if (!empty($mail_intro)) {
@@ -579,6 +590,22 @@ print $formcategory->textwithpicto('', $langs->trans("TicketsAutoReadTicketHelp"
print '</td>';
print '</tr>';
// Auto mark ticket as read when assign someone
print '<tr class="oddeven"><td>'.$langs->trans("TicketsAutoReadTicketWhenAssign").'</td>';
print '<td class="left">';
if ($conf->use_javascript_ajax) {
print ajax_constantonoff('TICKET_AUTO_READ_WHEN_ASSIGN');
} else {
$arrval = array('0' => $langs->trans("No"), '1' => $langs->trans("Yes"));
print $formcategory->selectarray("TICKET_AUTO_READ_WHEN_ASSIGN", $arrval, getDolGlobalString('TICKET_AUTO_READ_WHEN_ASSIGN'));
}
print '</td>';
print '<td class="center">';
print $formcategory->textwithpicto('', $langs->trans("TicketsAutoReadTicketWhenAssignHelp"), 1, 'help');
print '</td>';
print '</tr>';
// Auto assign ticket to user who created it
print '<tr class="oddeven">';
print '<td><label for="TICKET_AUTO_ASSIGN_USER_CREATE" class="block">'.$langs->trans("TicketsAutoAssignTicket").'</label></td>';
@@ -681,7 +708,7 @@ print '<tr class="oddeven"><td class="titlefieldmiddle"><label for="TICKET_SEND_
print $form->textwithpicto($langs->trans("TicketSendToInternalCC"), $langs->trans("TicketSendToInternalCCHelp")).'</label></td>';
print '<td>';
print img_picto('', 'email', 'class="pictofixedwidth"');
print '<input class="minwidth200" name="TICKET_SEND_INTERNAL_CC" value="'.getDolGlobalString('TICKET_SEND_INTERNAL_CC').'">';
print '<input class="flat width300" name="TICKET_SEND_INTERNAL_CC" value="'.getDolGlobalString('TICKET_SEND_INTERNAL_CC').'">';
print '</td>';
print '<td></td>';
print '</tr>';
@@ -699,6 +726,32 @@ print $formcategory->textwithpicto('', $langs->trans("TicketEmailNotificationToH
print '</td>';
print '</tr>';
include_once DOL_DOCUMENT_ROOT.'/core/class/html.formmail.class.php';
$formmail = new FormMail($db);
$formmail->fetchAllEMailTemplate('ticket_send', $user, null, -1); // We set lang=null to get in priority record with no lang
$arrayofmessagename = array();
if (is_array($formmail->lines_model)) {
foreach ($formmail->lines_model as $modelmail) {
//var_dump($modelmail);
$moreonlabel = '';
if (!empty($arrayofmessagename[$modelmail->label])) {
$moreonlabel = ' <span class="opacitymedium">('.$langs->trans("SeveralLangugeVariatFound").')</span>';
}
// The 'label' is the key that is unique if we exclude the language
$arrayofmessagename[$modelmail->label.':ticket_send'] = $langs->trans(preg_replace('/\(|\)/', '', $modelmail->label)).$moreonlabel;
}
}
// Email template for notification of TICKET_CREATE
print '<tr class="oddeven"><td><label for="TICKET_NOTIFICATION_EMAIL_TEMPLATE" class="block">'.$langs->trans('TicketEmailNotificationTemplate').'</label></td>';
print '<td class="left">';
print $form->selectarray('TICKET_NOTIFICATION_EMAIL_TEMPLATE', $arrayofmessagename, getDolGlobalString('TICKET_NOTIFICATION_EMAIL_TEMPLATE'), 'None', 0, 0, '', 0, 0, 0, '', '', 1);
print '<td class="center">';
print $formcategory->textwithpicto('', $langs->trans('TicketEmailNotificationTemplateHelp'), 1, 'help');
print '</td>';
print '</tr>';
// Check "Notify thirdparty" by default on ticket creation
print '<tr class="oddeven"><td>'.$langs->trans("TicketAutoCheckNotifyThirdParty").'</td>';
print '<td class="left">';

View File

@@ -34,6 +34,7 @@ require '../../main.inc.php';
* @var string $dolibarr_main_db_host
* @var string $dolibarr_main_db_name
* @var string $dolibarr_main_db_user
* @var string $dolibarr_main_db_pass
* @var Conf $conf
* @var DoliDB $db
* @var HookManager $hookmanager

View File

@@ -54,7 +54,7 @@ $limit = GETPOSTINT('limit') ? GETPOSTINT('limit') : $conf->liste_limit;
$sortfield = GETPOST('sortfield', 'aZ09comma');
$sortorder = GETPOST('sortorder', 'aZ09comma');
$page = GETPOSTISSET('pageplusone') ? (GETPOSTINT('pageplusone') - 1) : GETPOSTINT("page");
if (empty($page) || $page == -1 || GETPOST('button_search', 'alpha') || GETPOST('button_removefilter', 'alpha') || (empty($toselect) && $massaction === '0')) {
if (empty($page) || $page == -1 || GETPOST('button_search', 'alpha') || GETPOST('button_removefilter', 'alpha')) {
$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;

View File

@@ -1,6 +1,7 @@
<?php
/* Copyright (C) 2024 Anthony Damhet <a.damhet@progiseize.fr>
* Copyright (C) 2024 Frédéric France <frederic.france@free.fr>
* Copyright (C) 2026 MDW <mdeweerd@users.noreply.github.com>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -30,21 +31,21 @@ class Documentation
/**
* Views
*
* @var array
* @var array|array<int,string>
*/
public $view = array();
/**
* Menu - Set in setMenu in order to use dol_buildpath and called in constructor
*
* @var array
* @var array<array{url?: string, summary?: array<string,string>, submenu?: array<string,mixed>}>
*/
public $menu = array();
/**
* Summary - Set in setSummary and called in constructor
*
* @var array
* @var array<int,string>
*/
public $summary = array();
@@ -158,7 +159,7 @@ class Documentation
),
'Inputs' => array(
'url' => dol_buildpath($this->baseUrl.'/components/inputs.php', 1),
'icon' => 'fas fa-comments',
'icon' => 'far fa-edit',
'submenu' => array(),
'summary' => array(
'DocBasicUsage' => '#setinputssection-basicusage',
@@ -166,6 +167,12 @@ class Documentation
'DocHelperFunctionsGetSearchFilterToolInput' => '#setinputssection-getSearchFilterToolInput',
)
),
'ExperimentalUxInputAjaxFeedback' => array(
'url' => dol_buildpath($this->baseUrl.'/content/input-feedback.php', 1),
'icon' => 'far fa-share-square',
'submenu' => array(),
'summary' => array(),
),
),
);
@@ -229,7 +236,34 @@ class Documentation
)
);
// Elements
$this->menu['UxDolibarrContext'] = array(
'url' => dol_buildpath($this->baseUrl.'/dolibarr-context/index.php', 1),
'icon' => 'fab fa-fort-awesome',
'submenu' => array(
'UxDolibarrContextHowItWork' => array(
'url' => dol_buildpath($this->baseUrl.'/dolibarr-context/index.php', 1),
'icon' => 'fab fa-fort-awesome',
'submenu' => array(),
'summary' => array(
'Introduction' => '#titlesection-basicusage',
'ConsoleHelp' => '#titlesection-console-help',
'JSDolibarrhooks' => '#titlesection-hooks',
'JSDolibarrhooksReadyVsInit' => '#titlesection-event-init-vs-ready',
'JSDolibarrAwaitHooks' => '#titlesection-await-hooks',
'ExampleOfCreatingNewContextTool' => '#titlesection-create-tool-example',
'SetEventMessageTool' => '#titlesection-tool-seteventmessage',
'SetAndUseContextVars' => '#titlesection-contextvars',
),
),
'UxDolibarrContextLangsTool' => array(
'url' => dol_buildpath($this->baseUrl.'/dolibarr-context/langs-tool.php', 1),
'icon' => 'far fa-flag',
'submenu' => array(),
'summary' => array(),
),
)
);
// Elements
$this->menu['ExperimentalUx'] = array(
@@ -246,40 +280,6 @@ class Documentation
'ExperimentalUxContributionTitle' => '#experimental-ux-contribution',
),
),
'ExperimentalUxInputAjaxFeedback' => array(
'url' => dol_buildpath($this->baseUrl.'/experimental/experiments/input-feedback/index.php', 1),
'icon' => 'fas fa-flask',
'submenu' => array(),
'summary' => array(),
),
'UxDolibarrContext' => array(
'url' => dol_buildpath($this->baseUrl.'/experimental/experiments/dolibarr-context/index.php', 1),
'icon' => 'fas fa-flask',
'submenu' => array(
'UxDolibarrContextHowItWork' => array(
'url' => dol_buildpath($this->baseUrl.'/experimental/experiments/dolibarr-context/index.php', 1),
'icon' => 'fas fa-flask',
'submenu' => array(),
'summary' => array(
'Introduction' => '#titlesection-basicusage',
'ConsoleHelp' => '#titlesection-console-help',
'JSDolibarrhooks' => '#titlesection-hooks',
'JSDolibarrhooksReadyVsInit' => '#titlesection-event-init-vs-ready',
'JSDolibarrAwaitHooks' => '#titlesection-await-hooks',
'ExampleOfCreatingNewContextTool' => '#titlesection-create-tool-example',
'SetEventMessageTool' => '#titlesection-tool-seteventmessage',
'SetAndUseContextVars' => '#titlesection-contextvars',
),
),
'UxDolibarrContextLangsTool' => array(
'url' => dol_buildpath($this->baseUrl.'/experimental/experiments/dolibarr-context/langs-tool.php', 1),
'icon' => 'fas fa-flask',
'submenu' => array(),
'summary' => array(),
),
),
'summary' => array(),
),
)
);
@@ -368,7 +368,7 @@ class Documentation
/**
* Recursive function to set Menu
*
* @param array $menu $this->menu or submenus
* @param array<string, array{url?: string, icon?: string, summary?: array<string,string>, submenu?: array<string,array>}> $menu Menu entry or submenu
* @param int $level level of menu
* @return void
*/
@@ -441,13 +441,13 @@ class Documentation
$i = 0;
$menu_entry = [];
if (!empty($this->view)) {
// On se place au bon niveau
// Set the correct menu depth (level)
foreach ($this->view as $view) {
$i++;
if ($i == 1) {
$menu_entry = $this->menu[$view];
$menu_entry = $this->menu[$view] ?? [];
} else {
$menu_entry = $menu_entry['submenu'][$view];
$menu_entry = $menu_entry['submenu'][$view] ?? [];
}
}
}
@@ -463,7 +463,7 @@ class Documentation
/**
* Recursive function for Automatic Summary
*
* @param array $menu $this->menu or submenus
* @param array{summary?: array<string,string>, submenu?: array<string,array>} $menu $this->menu or submenus
* @param int $level level of menu
* @param int $showsubmenu Show Sub menus: 0 = No, 1 = Yes
* @param int $showsubmenu_summary Show summary of sub menus: 0 = No, 1 = Yes
@@ -517,7 +517,7 @@ class Documentation
/**
* Output a View Code area
*
* @param array $lines Lines of code to show
* @param array<int,string> $lines Lines of code to show
* @param string $option Source code language ('html', 'php' etc)
* @return void
*/

View File

@@ -1,6 +1,7 @@
<?php
/*
* Copyright (C) 2024 Anthony Damhet <a.damhet@progiseize.fr>
* Copyright (C) 2026 MDW <mdeweerd@users.noreply.github.com>
*
* This program and files/directory inner it is free software: you can
* redistribute it and/or modify it under the terms of the
@@ -100,9 +101,9 @@ $documentation->showSidebar(); ?>
</div>
<?php
$lines = array(
'<span class="spannature paddinglarge marginrightonly nonature-back valignmiddle"><label for="prospectinput" class="valignmiddle"><span class="valignmiddle">Prospect</span><input id="prospectinput" class="flat checkforselect marginleftonly valignmiddle" type="checkbox" name="prospect" value="1" checked></label></span>',
'<span class="spannature paddinglarge marginrightonly nonature-back valignmiddle"><label for="customerinput" class="valignmiddle"><span class="valignmiddle">Customer</span><input id="customerinput" class="flat checkforselect marginleftonly valignmiddle" type="checkbox" name="customer" value="1" checked></label></span>',
'<span class="spannature paddinglarge marginrightonly nonature-back valignmiddle"><label for="supplierinput" class="valignmiddle"><span class="valignmiddle">Supplier</span><input id="supplierinput" class="flat checkforselect marginleftonly valignmiddle" type="checkbox" name="supplier" value="1" checked></label></span>',
'<span class="spannature paddinglarge marginrightonly nonature-back valignmiddle"><label for="prospectinput" class="valignmiddle"><span class="valignmiddle">Prospect</span><input id="prospectinput" class="flat checkforselect marginleftonly valignmiddle" type="checkbox" name="prospect" value="1" checked></label></span>',
'<span class="spannature paddinglarge marginrightonly nonature-back valignmiddle"><label for="customerinput" class="valignmiddle"><span class="valignmiddle">Customer</span><input id="customerinput" class="flat checkforselect marginleftonly valignmiddle" type="checkbox" name="customer" value="1" checked></label></span>',
'<span class="spannature paddinglarge marginrightonly nonature-back valignmiddle"><label for="supplierinput" class="valignmiddle"><span class="valignmiddle">Supplier</span><input id="supplierinput" class="flat checkforselect marginleftonly valignmiddle" type="checkbox" name="supplier" value="1" checked></label></span>',
);
echo $documentation->showCode($lines); ?>
@@ -114,8 +115,8 @@ $documentation->showSidebar(); ?>
</div>
<?php
$lines = array(
'<input type="radio" id="idforradioinput1" name="radioinput" value="value1"><label for="idforradioinput1" class="marginrightonly"> Radio Input 1</label>',
'<input type="radio" id="idforradioinput2" name="radioinput" value="value2"><label for="idforradioinput2" class="marginrightonly"> Radio Input 2</label>'
'<input type="radio" id="idforradioinput1" name="radioinput" value="value1"><label for="idforradioinput1" class="marginrightonly"> Radio Input 1</label>',
'<input type="radio" id="idforradioinput2" name="radioinput" value="value2"><label for="idforradioinput2" class="marginrightonly"> Radio Input 2</label>'
);
echo $documentation->showCode($lines); ?>
</div>
@@ -141,36 +142,36 @@ $documentation->showSidebar(); ?>
</div>
<?php
$lines = array(
'<?php',
'',
'/**',
' * Function selectarray',
' *',
' * @param string $htmlname Name of html select area. Try to start name with "multi" or "search_multi" if this is a multiselect,',
' * @param array $array Array like array(key => value) or array(key=>array(\'label\'=>..., \'data-...\'=>..., \'disabled\'=>..., \'css\'=>...)),',
' * @param string|string[]|int $id Preselected key or array of preselected keys for multiselect. Use \'ifone\' to autoselect record if there is only one record.,',
' * @param int<0,1>|string $show_empty 0 no empty value allowed, 1 or string to add an empty value into list (If 1: key is -1 and value is \'\' or "&nbsp;", If \'Placeholder string\': key is -1 and value is the string), <0 to add an empty value with key that is this value.,',
' * @param int<0,1> $key_in_label 1 to show key into label with format "[key] value",',
' * @param int<0,1> $value_as_key 1 to use value as key,',
' * @param string $moreparam Add more parameters onto the select tag. For example "style=\"width: 95%\"" to avoid select2 component to go over parent container,',
' * @param int<0,1> $translate 1=Translate and encode value,',
' * @param int $maxlen Length maximum for labels,',
' * @param int<0,1> $disabled Html select box is disabled,',
' * @param string $sort \'ASC\' or \'DESC\' = Sort on label, \'\' or \'NONE\' or \'POS\' = Do not sort, we keep original order,',
' * @param string $morecss Add more class to css styles,',
' * @param int $addjscombo Add js combo,',
' * @param string $moreparamonempty Add more param on the empty option line. Not used if show_empty not set,',
' * @param int $disablebademail 1=Check if a not valid email, 2=Check string \'---\', and if found into value, disable and colorize entry,',
' * @param int $nohtmlescape No html escaping (not recommended, use \'data-html\' if you need to use label with HTML content).,',
' * @return string HTML select string.,',
' */',
'',
'<?php',
'',
'/**',
' * Function selectarray',
' *',
' * @param string $htmlname Name of html select area. Try to start name with "multi" or "search_multi" if this is a multiselect,',
' * @param array $array Array like array(key => value) or array(key=>array(\'label\'=>..., \'data-...\'=>..., \'disabled\'=>..., \'css\'=>...)),',
' * @param string|string[]|int $id Preselected key or array of preselected keys for multiselect. Use \'ifone\' to autoselect record if there is only one record.,',
' * @param int<0,1>|string $show_empty 0 no empty value allowed, 1 or string to add an empty value into list (If 1: key is -1 and value is \'\' or "&nbsp;", If \'Placeholder string\': key is -1 and value is the string), <0 to add an empty value with key that is this value.,',
' * @param int<0,1> $key_in_label 1 to show key into label with format "[key] value",',
' * @param int<0,1> $value_as_key 1 to use value as key,',
' * @param string $moreparam Add more parameters onto the select tag. For example "style=\"width: 95%\"" to avoid select2 component to go over parent container,',
' * @param int<0,1> $translate 1=Translate and encode value,',
' * @param int $maxlen Length maximum for labels,',
' * @param int<0,1> $disabled Html select box is disabled,',
' * @param string $sort \'ASC\' or \'DESC\' = Sort on label, \'\' or \'NONE\' or \'POS\' = Do not sort, we keep original order,',
' * @param string $morecss Add more class to css styles,',
' * @param int $addjscombo Add js combo,',
' * @param string $moreparamonempty Add more param on the empty option line. Not used if show_empty not set,',
' * @param int $disablebademail 1=Check if a not valid email, 2=Check string \'---\', and if found into value, disable and colorize entry,',
' * @param int $nohtmlescape No html escaping (not recommended, use \'data-html\' if you need to use label with HTML content).,',
' * @return string HTML select string.,',
' */',
'',
'// Select with empty value',
'print $form->selectarray(\'htmlnameselectwithemptyvalue\', $values, \'idselectwithemptyvalue\', 1, 0, 0, \'\', 0, 0, 0, \'\', \'minwidth200\');',
'',
'// Select within empty value',
'print $form->selectarray(\'htmlnameselectwithinemptyvalue\', $values, \'idnameselectwithinemptyvalue\', 0,0, 0, \'\', 0, 0, 0, \'\', \'minwidth200\');',
'// Select with empty value',
'print $form->selectarray(\'htmlnameselectwithemptyvalue\', $values, \'idselectwithemptyvalue\', 1, 0, 0, \'\', 0, 0, 0, \'\', \'minwidth200\');',
'',
'// Select within empty value',
'print $form->selectarray(\'htmlnameselectwithinemptyvalue\', $values, \'idnameselectwithinemptyvalue\', 0,0, 0, \'\', 0, 0, 0, \'\', \'minwidth200\');',
);
echo $documentation->showCode($lines, 'php'); ?>
@@ -187,29 +188,29 @@ $documentation->showSidebar(); ?>
</div>
<?php
$lines = array(
'<?php',
'',
'/**',
' * Show a multiselect form from an array. WARNING: Use this only for short lists.',
' *',
' * @param string $htmlname Name of select',
' * @param array<string,string|array{id:string,label:string,color:string,picto:string,labelhtml:string}> $array Array(key=>value) or Array(key=>array(\'id\'=>key, \'label\'=>value, \'color\'=> , \'picto\'=> , \'labelhtml\'=> ))',
' * @param string[] $selected Array of keys preselected',
' * @param int<0,1> $key_in_label 1 to show key like in "[key] value"',
' * @param int<0,1> $value_as_key 1 to use value as key',
' * @param string $morecss Add more css style',
' * @param int<0,1> $translate Translate and encode value',
' * @param int|string $width Force width of select box. May be used only when using jquery couch. Example: 250, \'95%\'',
' * @param string $moreattrib Add more options on select component. Example: \'disabled\'',
' * @param string $elemtype Type of element we show (\'category\', ...). Will execute a formatting function on it. To use in readonly mode if js component support HTML formatting.',
' * @param string $placeholder String to use as placeholder',
' * @param int<-1,1> $addjscombo Add js combo',
' * @return string HTML multiselect string',
' * @see selectarray(), selectArrayAjax(), selectArrayFilter()',
' */',
'',
'// Multiselect',
'print $form->multiselectarray(\'categories\', $values, GETPOST(\'categories\', \'array\'), 0, 0, \'minwidth200\', 0, 0);'
'<?php',
'',
'/**',
' * Show a multiselect form from an array. WARNING: Use this only for short lists.',
' *',
' * @param string $htmlname Name of select',
' * @param array<string,string|array{id:string,label:string,color:string,picto:string,labelhtml:string}> $array Array(key=>value) or Array(key=>array(\'id\'=>key, \'label\'=>value, \'color\'=> , \'picto\'=> , \'labelhtml\'=> ))',
' * @param string[] $selected Array of keys preselected',
' * @param int<0,1> $key_in_label 1 to show key like in "[key] value"',
' * @param int<0,1> $value_as_key 1 to use value as key',
' * @param string $morecss Add more css style',
' * @param int<0,1> $translate Translate and encode value',
' * @param int|string $width Force width of select box. May be used only when using jquery couch. Example: 250, \'95%\'',
' * @param string $moreattrib Add more options on select component. Example: \'disabled\'',
' * @param string $elemtype Type of element we show (\'category\', ...). Will execute a formatting function on it. To use in readonly mode if js component support HTML formatting.',
' * @param string $placeholder String to use as placeholder',
' * @param int<-1,1> $addjscombo Add js combo',
' * @return string HTML multiselect string',
' * @see selectarray(), selectArrayAjax(), selectArrayFilter()',
' */',
'',
'// Multiselect',
'print $form->multiselectarray(\'categories\', $values, GETPOST(\'categories\', \'array\'), 0, 0, \'minwidth200\', 0, 0);'
);
echo $documentation->showCode($lines, 'php'); ?>
@@ -232,41 +233,41 @@ $documentation->showSidebar(); ?>
</div>
<?php
$lines = array(
'<?php',
'/**',
' * Show a HTML widget to input a date or combo list for day, month, years and optionally hours and minutes.,',
' * Fields are preselected with :,',
' * - set_time date (must be a local PHP server timestamp or string date with format \'YYYY-MM-DD\' or \'YYYY-MM-DD HH:MM\'),',
' * - local date in user area, if set_time is \'\' (so if set_time is \'\', output may differs when done from two different location),',
' * - Empty (fields empty), if set_time is -1 (in this case, parameter empty must also have value 1),',
' *',
' * @param integer|string $set_time Pre-selected date (must be a local PHP server timestamp), -1 to keep date not preselected, \'\' to use current date with 00:00 hour (Parameter \'empty\' must be 0 or 2).,',
' * @param string $prefix Prefix for fields name,',
' * @param int $h 1 or 2=Show also hours (2=hours on a new line), -1 has same effect but hour and minutes are prefilled with 23:59 if date is empty, 3 or 4 (4=hours on a new line)=Show hour always empty,',
' * @param int $m 1=Show also minutes, -1 has same effect but hour and minutes are prefilled with 23:59 if date is empty, 3 show minutes always empty,',
' * @param int $empty 0=Fields required, 1=Empty inputs are allowed, 2=Empty inputs are allowed for hours only,',
' * @param string $form_name Not used,',
' * @param int<0,1> $d 1=Show days, month, years,',
' * @param int<0,2> $addnowlink Add a link "Now", 1 with server time, 2 with local computer time,',
' * @param int<0,1> $disabled Disable input fields,',
' * @param int|string $fullday When a checkbox with id #fullday is checked, hours are set with 00:00 (if value if \'fulldaystart\') or 23:59 (if value is \'fulldayend\'),',
' * @param string $addplusone Add a link "+1 hour". Value must be name of another selectDate field.,',
' * @param int|string|array<string,mixed> $adddateof Add a link "Date of ..." using the following date. Must be array(array(\'adddateof\' => ..., \'labeladddateof\' => ...)),',
' * @param string $openinghours Specify hour start and hour end for the select ex 8,20,',
' * @param int $stepminutes Specify step for minutes between 1 and 30,',
' * @param string $labeladddateof Label to use for the $adddateof parameter. Deprecated. Used only when $adddateof is not an array.,',
' * @param string $placeholder Placeholder,',
' * @param \'auto\'|\'gmt\'|\'tzserver\'|\'tzuserrel\' $gm \'auto\' (for backward compatibility, avoid this), \'gmt\' or \'tzserver\' or \'tzuserrel\',',
' * @param string $calendarpicto URL of the icon/image used to display the calendar,',
' * @return string Html for selectDate,',
' * @see form_date(), select_month(), select_year(), select_dayofweek(),',
' */',
'',
'// Date Select',
'print $form->selectDate();',
'',
'// Date Select with hours',
'print $form->selectDate(\'\', \'re2\', 1, 1, 1);'
'<?php',
'/**',
' * Show a HTML widget to input a date or combo list for day, month, years and optionally hours and minutes.,',
' * Fields are preselected with :,',
' * - set_time date (must be a local PHP server timestamp or string date with format \'YYYY-MM-DD\' or \'YYYY-MM-DD HH:MM\'),',
' * - local date in user area, if set_time is \'\' (so if set_time is \'\', output may differs when done from two different location),',
' * - Empty (fields empty), if set_time is -1 (in this case, parameter empty must also have value 1),',
' *',
' * @param integer|string $set_time Preselected date (must be a local PHP server timestamp), -1 to keep date not preselected, \'\' to use current date with 00:00 hour (Parameter \'empty\' must be 0 or 2).,',
' * @param string $prefix Prefix for fields name,',
' * @param int $h 1 or 2=Show also hours (2=hours on a new line), -1 has same effect but hour and minutes are prefilled with 23:59 if date is empty, 3 or 4 (4=hours on a new line)=Show hour always empty,',
' * @param int $m 1=Show also minutes, -1 has same effect but hour and minutes are prefilled with 23:59 if date is empty, 3 show minutes always empty,',
' * @param int $empty 0=Fields required, 1=Empty inputs are allowed, 2=Empty inputs are allowed for hours only,',
' * @param string $form_name Not used,',
' * @param int<0,1> $d 1=Show days, month, years,',
' * @param int<0,2> $addnowlink Add a link "Now", 1 with server time, 2 with local computer time,',
' * @param int<0,1> $disabled Disable input fields,',
' * @param int|string $fullday When a checkbox with id #fullday is checked, hours are set with 00:00 (if value if \'fulldaystart\') or 23:59 (if value is \'fulldayend\'),',
' * @param string $addplusone Add a link "+1 hour". Value must be name of another selectDate field.,',
' * @param int|string|array<string,mixed> $adddateof Add a link "Date of ..." using the following date. Must be array(array(\'adddateof\' => ..., \'labeladddateof\' => ...)),',
' * @param string $openinghours Specify hour start and hour end for the select ex 8,20,',
' * @param int $stepminutes Specify step for minutes between 1 and 30,',
' * @param string $labeladddateof Label to use for the $adddateof parameter. Deprecated. Used only when $adddateof is not an array.,',
' * @param string $placeholder Placeholder,',
' * @param \'auto\'|\'gmt\'|\'tzserver\'|\'tzuserrel\' $gm \'auto\' (for backward compatibility, avoid this), \'gmt\' or \'tzserver\' or \'tzuserrel\',',
' * @param string $calendarpicto URL of the icon/image used to display the calendar,',
' * @return string Html for selectDate,',
' * @see form_date(), select_month(), select_year(), select_dayofweek(),',
' */',
'',
'// Date Select',
'print $form->selectDate();',
'',
'// Date Select with hours',
'print $form->selectDate(\'\', \'re2\', 1, 1, 1);'
);
echo $documentation->showCode($lines, 'php'); ?>
@@ -281,29 +282,29 @@ $documentation->showSidebar(); ?>
</div>
<?php
$lines = array(
'<?php',
'/**',
' * Create an object to build an HTML area to edit a large string content',
' *',
' * @param string $htmlname HTML name of WYSIWYG field',
' * @param string $content Content of WYSIWYG field',
' * @param int|string $width Width in pixel of edit area (auto by default)',
' * @param int $height Height in pixel of edit area (200px by default)',
' * @param string $toolbarname Name of bar set to use (\'Full\', \'dolibarr_notes[_encoded]\', \'dolibarr_details[_encoded]\'=the less featured, \'dolibarr_mailings[_encoded]\', \'dolibarr_readonly\')',
' * @param string $toolbarlocation Deprecated. Not used',
' * @param bool $toolbarstartexpanded Bar is visible or not at start',
' * @param bool|int $uselocalbrowser Enabled to add links to local object with local browser. If false, only external images can be added in content.',
' * @param bool|int|string $okforextendededitor 1 or True=Allow usage of extended editor tool if qualified (like ckeditor). If \'textarea\', force use of simple textarea. If \'ace\', force use of Ace.',
' * Warning: If you use \'ace\', don\'t forget to also include ace.js in page header. Also, the button "save" must have class="buttonforacesave"',
' * @param int $rows Size of rows for textarea tool',
' * @param string $cols Size of cols for textarea tool (textarea number of cols \'70\' or percent \'x%\')',
' * @param int<0,1> $readonly 0=Read/Edit, 1=Read only',
' * @param array{x?:string,y?:string,find?:string} $poscursor Array for initial cursor position array(\'x\'=>x, \'y\'=>y).',
' * array(\'find\'=> \'word\') can be used to go to line were the word has been found',
' */',
'',
'$doleditor = new DolEditor(\'desc\', GETPOST(\'desc\', \'restricthtml\'), \'\', 160, \'dolibarr_details\', \'\', false, true, getDolGlobalString(\'FCKEDITOR_ENABLE_DETAILS\'), ROWS_4, \'90%\');',
'print $form->multiselectarray(\'categories\', $values, GETPOST(\'categories\', \'array\'), 0, 0, \'minwidth200\', 0, 0);'
'<?php',
'/**',
' * Create an object to build an HTML area to edit a large string content',
' *',
' * @param string $htmlname HTML name of WYSIWYG field',
' * @param string $content Content of WYSIWYG field',
' * @param int|string $width Width in pixel of edit area (auto by default)',
' * @param int $height Height in pixel of edit area (200px by default)',
' * @param string $toolbarname Name of bar set to use (\'Full\', \'dolibarr_notes[_encoded]\', \'dolibarr_details[_encoded]\'=the less featured, \'dolibarr_mailings[_encoded]\', \'dolibarr_readonly\')',
' * @param string $toolbarlocation Deprecated. Not used',
' * @param bool $toolbarstartexpanded Bar is visible or not at start',
' * @param bool|int $uselocalbrowser Enabled to add links to local object with local browser. If false, only external images can be added in content.',
' * @param bool|int|string $okforextendededitor 1 or True=Allow usage of extended editor tool if qualified (like ckeditor). If \'textarea\', force use of simple textarea. If \'ace\', force use of Ace.',
' * Warning: If you use \'ace\', don\'t forget to also include ace.js in page header. Also, the button "save" must have class="buttonforacesave"',
' * @param int $rows Size of rows for textarea tool',
' * @param string $cols Size of cols for textarea tool (textarea number of cols \'70\' or percent \'x%\')',
' * @param int<0,1> $readonly 0=Read/Edit, 1=Read only',
' * @param array{x?:string,y?:string,find?:string} $poscursor Array for initial cursor position array(\'x\'=>x, \'y\'=>y).',
' * array(\'find\'=> \'word\') can be used to go to line were the word has been found',
' */',
'',
'$doleditor = new DolEditor(\'desc\', GETPOST(\'desc\', \'restricthtml\'), \'\', 160, \'dolibarr_details\', \'\', false, true, getDolGlobalString(\'FCKEDITOR_ENABLE_DETAILS\'), ROWS_4, \'90%\');',
'print $form->multiselectarray(\'categories\', $values, GETPOST(\'categories\', \'array\'), 0, 0, \'minwidth200\', 0, 0);'
);
echo $documentation->showCode($lines, 'php'); ?>
</div>
@@ -316,14 +317,14 @@ $documentation->showSidebar(); ?>
<?php
$containerCssSelector = '#demo-search-filter-tool-container-01';
print $form->getSearchFilterToolInput(
$containerCssSelector. ' .search-item',
'',
'',
['attr' => [
'data-counter-target' => $containerCssSelector. ' .counter',
'data-no-item-target' => $containerCssSelector. ' .search-tool-no-results',
],
]
$containerCssSelector. ' .search-item',
'',
'',
['attr' => [
'data-counter-target' => $containerCssSelector. ' .counter',
'data-no-item-target' => $containerCssSelector. ' .search-tool-no-results',
],
]
);
?>
@@ -349,57 +350,57 @@ $documentation->showSidebar(); ?>
</div>
<?php
$lines = array(
'<div class="search-tool-container">',
' <input ',
' type="search"',
' name=""',
' autofocus="" <?php // To use only if search is in top of page ?> ',
' value=""',
' class="search-tool-input" <?php // optional for js filter you can use custom class ?> ',
' placeholder="Search"',
' autocomplete="off"',
' data-search-tool-target="#demo-filter .search-item" <?php // required for js filter ?> ',
' data-counter-target="#demo-filter .counter" <?php // optional for js filter ?> ',
' data-no-item-target="#demo-filter .search-tool-no-results" <?php // optional for js filter ?> ',
' >',
'</div>',
'<div id="demo-filter">',
' <p>Counter : <strong class="counter">4</strong></p>',
' <ul>',
' <li class="search-item">France</li>',
' <li class="search-item">Italy</li>',
' <li class="search-item">Germany</li>',
' <li class="search-item">Spain</li>',
' </ul>',
' <div class="search-tool-no-results hidden-search-result" >No results</div>',
'</div>',
'<div class="search-tool-container">',
' <input ',
' type="search"',
' name=""',
' autofocus="" <?php // To use only if search is in top of page ?> ',
' value=""',
' class="search-tool-input" <?php // optional for js filter you can use custom class ?> ',
' placeholder="Search"',
' autocomplete="off"',
' data-search-tool-target="#demo-filter .search-item" <?php // required for js filter ?> ',
' data-counter-target="#demo-filter .counter" <?php // optional for js filter ?> ',
' data-no-item-target="#demo-filter .search-tool-no-results" <?php // optional for js filter ?> ',
' >',
'</div>',
'<div id="demo-filter">',
' <p>Counter : <strong class="counter">4</strong></p>',
' <ul>',
' <li class="search-item">France</li>',
' <li class="search-item">Italy</li>',
' <li class="search-item">Germany</li>',
' <li class="search-item">Spain</li>',
' </ul>',
' <div class="search-tool-no-results hidden-search-result" >No results</div>',
'</div>',
);
echo $documentation->showCode($lines, 'php');
$lines = array(
'<?php',
'print $form->getSearchFilterToolInput(',
' \'#demo-filter .search-item\',',
' \'search-tools-input\',',
' [\'attr\' => [',
' \'data-no-item-target\' => \'#demo-filter .search-tool-no-results\', ',
' \'data-counter-target\' => \'#demo-filter .counter\', ',
' ],',
' ]',
'); ',
'?>',
'',
'<div id="demo-filter">',
' <p>Counter : <strong class="counter">4</strong></p>',
' <ul>',
' <li class="search-item">France</li>',
' <li class="search-item">Italy</li>',
' <li class="search-item">Germany</li>',
' <li class="search-item">Spain</li>',
' </ul>',
' <div class="search-tool-no-results hidden-search-result" >No results</div>',
'</div>',
'<?php',
'print $form->getSearchFilterToolInput(',
' \'#demo-filter .search-item\',',
' \'search-tools-input\',',
' [\'attr\' => [',
' \'data-no-item-target\' => \'#demo-filter .search-tool-no-results\', ',
' \'data-counter-target\' => \'#demo-filter .counter\', ',
' ],',
' ]',
'); ',
'?>',
'',
'<div id="demo-filter">',
' <p>Counter : <strong class="counter">4</strong></p>',
' <ul>',
' <li class="search-item">France</li>',
' <li class="search-item">Italy</li>',
' <li class="search-item">Germany</li>',
' <li class="search-item">Spain</li>',
' </ul>',
' <div class="search-tool-no-results hidden-search-result" >No results</div>',
'</div>',
);
echo $documentation->showCode($lines, 'php');

View File

@@ -66,16 +66,16 @@ if (empty($usedolheader)) {
<meta name="author" content="Dolibarr Development Team">
<title>Test page</title>
<!-- Includes for JQuery (Ajax library) -->
<link rel="stylesheet" type="text/css" href="<?php echo DOL_URL_ROOT ?>/includes/jquery/css/base/jquery-ui.css" />
<!-- <link rel="stylesheet" type="text/css" href="<?php echo DOL_URL_ROOT ?>/includes/jquery/plugins/datatables/media/css/jquery.dataTables.css" /> -->
<link rel="stylesheet" type="text/css" href="<?php echo DOL_URL_ROOT ?>/public/includes/jquery/css/base/jquery-ui.css" />
<!-- <link rel="stylesheet" type="text/css" href="<?php echo DOL_URL_ROOT ?>/public/includes/jquery/plugins/datatables/media/css/jquery.dataTables.css" /> -->
<link rel="stylesheet" type="text/css" title="default" href="<?php echo DOL_URL_ROOT ?>/theme/eldy/style.css.php<?php echo (GETPOST("dol_use_jmobile") == 1) ? '?dol_use_jmobile=1&dol_optimize_smallscreen=1' : ''; ?>" />
<!-- Includes JS for JQuery -->
<script type="text/javascript" src="<?php echo DOL_URL_ROOT ?>/includes/jquery/js/jquery.min.js"></script>
<script type="text/javascript" src="<?php echo DOL_URL_ROOT ?>/public/includes/jquery/js/jquery.min.js"></script>
<!-- migration fixes for removed Jquery functions -->
<script type="text/javascript" src="<?php echo DOL_URL_ROOT ?>/includes/jquery/js/jquery-migrate.min.js"></script>
<script type="text/javascript" src="<?php echo DOL_URL_ROOT ?>/includes/jquery/plugins/tablednd/jquery.tablednd.0.6.min.js"></script>
<!-- <script type="text/javascript" src="<?php echo DOL_URL_ROOT ?>/includes/jquery/plugins/datatables/media/js/jquery.dataTables.js"></script> -->
<script type="text/javascript" src="<?php echo DOL_URL_ROOT ?>/includes/jquery/plugins/select2/select2.min.js?version=4.0.0-beta"></script>
<script type="text/javascript" src="<?php echo DOL_URL_ROOT ?>/public/includes/jquery/js/jquery-migrate.min.js"></script>
<script type="text/javascript" src="<?php echo DOL_URL_ROOT ?>/public/includes/jquery/plugins/tablednd/jquery.tablednd.0.6.min.js"></script>
<!-- <script type="text/javascript" src="<?php echo DOL_URL_ROOT ?>/public/includes/jquery/plugins/datatables/media/js/jquery.dataTables.js"></script> -->
<script type="text/javascript" src="<?php echo DOL_URL_ROOT ?>/public/includes/jquery/plugins/select2/select2.min.js?version=4.0.0-beta"></script>
</head>
<body style="padding: 10px;">
@@ -86,17 +86,17 @@ if (empty($usedolheader)) {
$arraycss = array();
$arrayjs = array();
/*
$arraycss=array('/includes/jquery/plugins/datatables/media/css/jquery.dataTables.css',
'/includes/jquery/plugins/datatables/extensions/Buttons/css/buttons.dataTables.min.css',
'/includes/jquery/plugins/datatables/extensions/ColReorder/css/colReorder.dataTables.min.css'
$arraycss=array('/public/includes/jquery/plugins/datatables/media/css/jquery.dataTables.css',
'/public/includes/jquery/plugins/datatables/extensions/Buttons/css/buttons.dataTables.min.css',
'/public/includes/jquery/plugins/datatables/extensions/ColReorder/css/colReorder.dataTables.min.css'
);
$arrayjs=array('/includes/jquery/plugins/datatables/media/js/jquery.dataTables.js',
'/includes/jquery/plugins/datatables/extensions/Buttons/js/dataTables.buttons.js',
'/includes/jquery/plugins/datatables/extensions/Buttons/js/buttons.colVis.min.js',
'/includes/jquery/plugins/datatables/extensions/Buttons/js/buttons.html5.min.js',
'/includes/jquery/plugins/datatables/extensions/Buttons/js/buttons.flash.min.js',
'/includes/jquery/plugins/datatables/extensions/Buttons/js/buttons.print.min.js',
'/includes/jquery/plugins/datatables/extensions/ColReorder/js/dataTables.colReorder.min.js',
$arrayjs=array('/public/includes/jquery/plugins/datatables/media/js/jquery.dataTables.js',
'/public/includes/jquery/plugins/datatables/extensions/Buttons/js/dataTables.buttons.js',
'/public/includes/jquery/plugins/datatables/extensions/Buttons/js/buttons.colVis.min.js',
'/public/includes/jquery/plugins/datatables/extensions/Buttons/js/buttons.html5.min.js',
'/public/includes/jquery/plugins/datatables/extensions/Buttons/js/buttons.flash.min.js',
'/public/includes/jquery/plugins/datatables/extensions/Buttons/js/buttons.print.min.js',
'/public/includes/jquery/plugins/datatables/extensions/ColReorder/js/dataTables.colReorder.min.js',
'/includes/jszip/jszip.min.js',
'/includes/pdfmake/pdfmake.min.js',
'/includes/pdfmake/vfs_fonts.js'

Some files were not shown because too many files have changed in this diff Show More