2
0
forked from Wavyzz/dolibarr
Commit Graph

2171 Commits

Author SHA1 Message Date
Laurent Destailleur
b5de782c6b Fix use the good HTTP code 2024-04-07 14:59:25 +02:00
Laurent Destailleur
fd9475be03 Use same doc comment eveywhere. 2024-04-07 12:26:27 +02:00
Laurent Destailleur
38fb00489d PHPDoc 2024-04-05 13:44:59 +02:00
Laurent Destailleur
0fe0cd7c01 Merge branch '19.0' of git@github.com:Dolibarr/dolibarr.git into develop 2024-04-04 11:39:02 +02:00
Laurent Destailleur
404ba88107 Merge branch '18.0' of git@github.com:Dolibarr/dolibarr.git into 19.0 2024-04-04 11:19:45 +02:00
Laurent Destailleur
50f99a51bb Remove trigger BILLREC_CREATEBILL that should not exists as it is
duplicate of BILL_CREATE.
This trigger was not a CRUD event. If you used it, you can already use
the trigger BILL_CREATE and test that ($object->fac_rec > 0) to know if
creation trigger is from a recurring invoice or not. Also this old
trigger was never enabled into table llx_c_action_trigger.
2024-04-03 02:37:30 +02:00
Laurent Destailleur
714236a1ec Merge pull request #29203 from rycks/16_move_trigger_to_facture
move BILLREC_CREATEBILL to facture because of ui actions
2024-04-03 02:29:12 +02:00
Eric Seigne
6bd2d78fc9 fix object call 2024-04-02 21:35:25 +02:00
Eric Seigne
850ec25f23 move BILLREC_CREATEBILL to facture because of user can click on button "create" from ui, not only from cron 2024-04-02 21:29:21 +02:00
Frédéric France
83258058f0 fix Property FactureLigne::$localtax1_type (int) does not accept string 2024-04-02 20:31:37 +02:00
Laurent Destailleur
7715513ac9 Some API HTTP return code were moved from 401 to 403 to better follow
REST specification.
2024-04-02 14:47:49 +02:00
Laurent Destailleur
51f862ad28 Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2024-04-02 13:21:00 +02:00
Laurent Destailleur
990216b13f NEW Api parameters are sanitized by the WAF, same code than GET/POST 2024-04-02 13:07:13 +02:00
Jon Bendtsen
04b3b4d4d2 will allow updating 1 invoices single Complementary Attribute without specifying complementary attributes that we don't want to change. Similar to # 29115 but just for invoices 2024-04-01 10:17:58 +02:00
Regis Houssin
85a08a9288 FIX sometimes a string type instead integer is return, why ? 2024-03-31 19:17:58 +02:00
MDW
04c3e80fc5 Fix typing 2024-03-29 18:26:48 +01:00
Frédéric France
afcf1710f9 fix phpstan 2024-03-28 20:20:41 +01:00
Frédéric France
5b1af95864 fix phpstan 2024-03-28 20:16:32 +01:00
Laurent Destailleur
a7e33e6573 Merge pull request #29047 from mdeweerd/fix/PhanPluginUnknownObjectMethodCall1
Fixes for PhanPluginUnknownObjectMethodCall
2024-03-28 14:20:57 +01:00
Laurent Destailleur
415e99606d Merge pull request #29091 from mdeweerd/fix/facturefournisseur/card
Fix card FactureFournisseur
2024-03-28 12:55:24 +01:00
Laurent Destailleur
c112a965cc Fix phan warnings 2024-03-28 12:54:08 +01:00
Laurent Destailleur
f403a3e054 Fix warning 2024-03-28 12:45:47 +01:00
MDW
975243f1b5 Fix: Ensure DiscountAbsolute->fk_soc deprecation is possible
# Fix: Ensure DiscountAbsolute->fk_soc deprecation is possible

Assign socid whenever fk_soc is assigned so that socid can be accessed
instead of fk_soc.
2024-03-27 18:07:51 +01:00
MDW
bf659fee44 Force typing (phan) for typing checks 2024-03-27 10:18:05 +01:00
MDW
359a2688ff Fix PhanTypeInvalid{Left,Right}OperandOfNumericOp mostly by typing, casting, idate 2024-03-23 02:06:29 +01:00
Laurent Destailleur
b658bde88a Merge branch '18.0' of git@github.com:Dolibarr/dolibarr.git into 19.0
Conflicts:
	htdocs/core/class/html.formsetup.class.php
	htdocs/takepos/index.php
2024-03-22 02:11:58 +01:00
MDW
ecf24fd3b4 Fix $mybool |=... which is binary op, not boolean op
# Fix $mybool |=... which is binary op, not boolean op

This fixes PhanTypeInvalidLeftOperandOfBitwiseOp.
Replace $var |= ... with $var = ... || $var .
Add cast before ... when needed (@include does not always return bool).
|= always evaluates expression, there for || $var, not $var ||
2024-03-21 13:45:06 +01:00
MDW
34eb7c288a Fix arg type to preg_match(),abs(),trim() with cast 2024-03-20 04:08:34 +01:00
MDW
991ce81f93 Fix arg type to preg_match() and preg_replace() with cast 2024-03-20 04:08:34 +01:00
MDW
6eacf10d67 Fix arg type to preg_match with cast to string 2024-03-19 20:37:40 +01:00
MDW
fd9d48faac Fix phpstan CommonObject->fields - notnull is optional field 2024-03-19 00:32:00 +01:00
MDW
13ab939691 Fix deprecated function calls 2024-03-16 13:27:51 +01:00
Laurent Destailleur
e15f243e95 Clean code - Remove a deprecated tag that should not exists. 2024-03-16 11:51:32 +01:00
MDW
23785393a3 Add csslist to json keys 2024-03-15 03:55:52 +01:00
MDW
e7fde26b0f Fix PhanTypeMismatchPropertyDefault 2024-03-15 03:44:47 +01:00
MDW
b7b05d4d49 Fix PhanTypeMismatchPropertyDefault 2024-03-15 03:44:46 +01:00
MDW
3b0d19a160 Fix unneed test 'X ? Y : Y' by assigning '' to note_private 2024-03-14 19:47:10 +01:00
Laurent Destailleur
c867bc2706 Merge branch '19.0' of git@github.com:Dolibarr/dolibarr.git into develop 2024-03-13 22:36:45 +01:00
Laurent Destailleur
8bfc0779c4 Merge branch '19.0' of git@github.com:Dolibarr/dolibarr.git into 19.0 2024-03-13 22:20:08 +01:00
Laurent Destailleur
a0b26ae7cd FIX Amount of localtaxes in foreign currency was wrong on screen and PDF 2024-03-13 22:04:44 +01:00
MDW
9ee7611a08 Fix PhanPluginRedundantAssignment 2024-03-13 00:40:38 +01:00
MDW
ca8ccd84f0 Fix PhanPluginRedundantAssignment 2024-03-13 00:40:37 +01:00
MDW
88d59896ec Qual: 'enabled' in fields can be string ('isModEnabled(...)')
# Qual: 'enabled' in fields can be string ('isModEnabled(...)')

Update PHPdoc to allow that enabled is a string
2024-03-12 13:38:08 +01:00
MDW
0c0f04f2d5 Fix: Repeat fields typing in CommonClass children
# Fix: Repeat fields typing in CommonClass children

phpstan needs typing to be 'co-variant' and therefore typing must be repeated as
the method is not to initialise the property in the constructor, but to override
the proparty by a 'local' definition in the child class
2024-03-11 17:39:05 +01:00
MDW
88ba7d1bc5 Fix: Repeat fields typing in CommonClass children
# Fix: Repeat fields typing in CommonClass children

phpstan needs typing to be 'co-variant' and therefore typing must be repeated as
the method is not to initialise the property in the constructor, but to override
the proparty by a 'local' definition in the child class
2024-03-11 17:39:03 +01:00
MDW
b72cf193c4 Fix some cases of PhanTypeSuspiciousStringExpression (#28751)
* Fix PhanTypeSuspiciousStringExpression

* Fix PhanTypeSuspiciousStringExpression

* Fix PhanTypeSuspiciousStringExpression

* Fix PhanTypeSuspiciousStringExpression

* Fix PhanTypeSuspiciousStringExpression

* Fix PhanTypeSuspiciousStringExpression

* Fix PhanTypeSuspiciousStringExpression

* Fix PhanTypeSuspiciousStringExpression

* Fix PhanTypeSuspiciousStringExpression

* Fix PhanTypeSuspiciousStringExpression

* Fix PhanTypeSuspiciousStringExpression

* Fix PhanTypeSuspiciousStringExpression

* Fix PhanTypeSuspiciousStringExpression

---------

Co-authored-by: Laurent Destailleur <eldy@destailleur.fr>
2024-03-11 14:01:28 +01:00
Laurent Destailleur
31ae1bf97f Fix restore stop on failure. No need to continue, we must fix first.
Make travis error analysis easier too.
2024-03-05 01:05:50 +01:00
Laurent Destailleur
aedffc6cee Fix cast 2024-03-05 00:52:01 +01:00
Laurent Destailleur
ce010a54c7 Clean code and prepare a more powerfull phpunit check for sql forging. 2024-03-05 00:22:12 +01:00
PsyCrow
41bdcff4da Update facture.class.php (#28591)
* Update facture.class.php

FIX  #22948

* Update facture.class.php
2024-03-03 16:58:52 +01:00