Commit Graph

7121 Commits

Author SHA1 Message Date
MDW
09b7308607 Fix type with cast/idate/phpdoc 2024-03-22 09:52:24 +01:00
Laurent Destailleur
51a3641105 Merge branch '19.0' of git@github.com:Dolibarr/dolibarr.git into develop
Conflicts:
	htdocs/bom/tpl/objectline_create.tpl.php
	htdocs/compta/bank/releve.php
	htdocs/core/class/html.formsetup.class.php
	htdocs/takepos/freezone.php
2024-03-22 02:35:37 +01:00
Laurent Destailleur
7b0177a84d Move to getDolGlobalString 2024-03-22 00:37:56 +01:00
Laurent Destailleur
922f30eceb Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into
develop
2024-03-21 15:38:11 +01:00
MDW
effe9e79b5 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:23 +01:00
MDW
e19a60cd62 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:21 +01:00
MDW
476d8cfd9c 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:20 +01:00
MDW
aeefca7e7e Fix $arrayfields typing lost by dol_sort_array() by forcing the type 2024-03-20 23:29:48 +01:00
MDW
9f93a55468 Fix arg type to trim with cast 2024-03-20 04:10:10 +01:00
MDW
32db6eebbb Fix arg type to abs() with cast 2024-03-20 04:09:33 +01:00
MDW
2175c55085 Fix arg type to preg_replace() with cast 2024-03-20 04:09:32 +01:00
MDW
8ac8e5844c Fix arg type to preg_match(),preg_replace(),abs() with cast 2024-03-20 04:09:31 +01:00
MDW
2c0f77c1b9 Fix arg type to preg_match(),preg_replace() with cast 2024-03-20 04:09:30 +01:00
MDW
3682cec8ff Fix arg type to preg_match() with cast 2024-03-20 04:09:29 +01:00
MDW
60a3631d58 Fix arg type to abs() with cast 2024-03-20 04:08:42 +01:00
MDW
c5479f4520 Fix: Update typing for qty as float 2024-03-19 20:37:38 +01:00
Christophe Battarel
07597c4515 renaming of columns impact db access 2024-03-19 15:56:44 +01:00
Christophe Battarel
3f5ffc5e9d renaming of columns impact db access 2024-03-19 15:50:15 +01:00
Christophe Battarel
446b574de5 renaming of columns impact db access 2024-03-19 15:49:42 +01:00
Christophe Battarel
f94d282c17 renam fk_commande and fk_commandefourdet 2024-03-19 15:24:08 +01:00
Christophe Battarel
b2baacccb4 update credentials 2024-03-19 14:58:05 +01:00
MDW
fd9d48faac Fix phpstan CommonObject->fields - notnull is optional field 2024-03-19 00:32:00 +01:00
MDW
2917b34519 Fix phpstan $fields property issue
Fix Property FactureFournisseur::$fields (array) does not accept default value of type array{rowid: array
2024-03-19 00:31:58 +01:00
MDW
a5d16b326b Fix: Initialise $amount_ttc_diff to fix PhanUndeclaredVariableAssignOp 2024-03-18 13:12:49 +01:00
Laurent Destailleur
5e51092efd Merge pull request #28926 from frederic34/phpstanphpstan
fix phpstan
2024-03-17 21:57:25 +01:00
Laurent Destailleur
ebba438fbe Merge pull request #27528 from altairisfr/rdb
[DATA_MODEL] rename commande_fournisseur_dispatch into receptiondet_batch
2024-03-17 21:31:27 +01:00
Frédéric France
17ea003a69 fix phpstan 2024-03-17 21:20:36 +01:00
Laurent Destailleur
90ecb139b3 Merge pull request #28919 from mdeweerd/fix/trim
Fix several useless trims or bad arguments to trim (PhanTypeMismatchArgumentInternal) & related bugs
2024-03-17 21:14:13 +01:00
MDW
7ab07a1549 Fix PhanPluginSuspiciousParamOrder in updete() by removeing arg 2024-03-17 20:12:47 +01:00
MDW
18cfd0dae6 Fix PhanTypeComparisonFromArray by testing $error field
# Fix PhanTypeComparisonFromArray by testing $error field

getListOfPayments always returns an array, comparing it to 0 is invalid.
To know if there was an error, we should test error, not the size of the result.
Updated getListOfPayments as well to initialize error to ""
2024-03-17 20:12:45 +01:00
MDW
e56546515c Fix unneeded trim, unneeded urlencode 2024-03-17 15:04:48 +01:00
Laurent Destailleur
de58435ef1 FIX: if we stop for security purpose, we must exit a non zero value. 2024-03-16 23:08:15 +01:00
Laurent Destailleur
487a55750a Fix warnings 2024-03-16 22:13:00 +01:00
Laurent Destailleur
e994d6650f Fix regression in GETPOST limit 2024-03-16 11:41:00 +01:00
Laurent Destailleur
79aa9fb1f1 Code simpler 2024-03-15 20:29:21 +01:00
Laurent Destailleur
0ee6fd6bad Merge pull request #28877 from mdeweerd/PhanTypeMismatchDefault
Fix & enable PhanTypeMismatchDefault
2024-03-15 15:44:30 +01:00
MDW
82157757f0 Fix PhanTypeMismatchDefault by updating defaults 2024-03-15 14:53:03 +01:00
MDW
61b55f21ab Fix PhanTypeMismatchDefault with typing hint 2024-03-15 14:53:02 +01:00
MDW
575e620300 Fix Assign 0 to fk_project, not null (dolibarr's way) 2024-03-15 10:12:02 +01:00
Laurent Destailleur
80e2e59373 Merge pull request #28862 from mdeweerd/fix/PhanTypeMismatchPropertyDefault
Fix & enable PhanTypeMismatchPropertyDefault
2024-03-15 09:33:40 +01:00
Laurent Destailleur
e238cc204e Merge pull request #28750 from mdeweerd/fix/PhanPluginSuspiciousParamPosition
Fix: Resolve several PhanPluginSuspiciousParamPosition cases
2024-03-15 08:45:25 +01:00
MDW
23785393a3 Add csslist to json keys 2024-03-15 03:55:52 +01:00
MDW
9ea2b38c47 Fix PhanTypeMismatchPropertyDefault 2024-03-15 03:48:17 +01:00
MDW
cbd42a7906 Fix PhanPluginSuspiciousParamPosition by renaming arg (local assign) 2024-03-14 19:39:46 +01:00
Frédéric France
ad13f6fc76 fix phpstan is incompatible with 2024-03-14 18:46:17 +01:00
MDW
a997447ce3 Fix PhanPluginRedundantAssignment 2024-03-13 01:04:54 +01:00
MDW
af5816f344 Fix PhanPluginRedundantAssignment 2024-03-13 01:04:53 +01:00
MDW
b1b6ce6dc0 Fix PhanPluginMixedKeyNoKey by using explicit keys 2024-03-12 21:35:48 +01:00
Laurent Destailleur
74b8162d22 Merge pull request #28700 from mdeweerd/urlencode/fixuptype
Fix: Ensure the argument type for urlencode is string
2024-03-12 14:43:41 +01:00
Laurent Destailleur
9e16016125 Merge pull request #28770 from mdeweerd/typing/fields
Fix: Repeat fields typing in CommonClass children
2024-03-12 14:30:36 +01:00