Files
dolibarr/htdocs/commande
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
..
2025-11-22 16:23:07 +01:00
2025-11-24 16:29:21 +01:00
CI
2026-02-01 19:04:53 +01:00
2025-10-17 02:31:07 +02:00
2025-10-17 02:31:07 +02:00
2025-11-18 15:37:37 +01:00
2025-10-30 01:51:29 +01:00
2026-01-15 03:12:15 +01:00