From c0f2d57dd9595ce4bc503ed83f02da9604a37f6c Mon Sep 17 00:00:00 2001 From: thibdrev Date: Tue, 23 Jan 2024 19:31:52 +0100 Subject: [PATCH] qual : phsptan htdocs/expensereport/payment/payment.php 113 Property PaymentExpenseReport::$fk_typepayment (int) does not accept array|string. htdocs/expensereport/payment/payment.php 116 Property PaymentExpenseReport::$fk_bank (int) does not accept array|string. --- htdocs/expensereport/payment/payment.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/htdocs/expensereport/payment/payment.php b/htdocs/expensereport/payment/payment.php index 007ee7372f4..851adb381a0 100644 --- a/htdocs/expensereport/payment/payment.php +++ b/htdocs/expensereport/payment/payment.php @@ -32,11 +32,11 @@ require_once DOL_DOCUMENT_ROOT.'/compta/bank/class/account.class.php'; // Load translation files required by the page $langs->loadLangs(array('bills', 'banks', 'trips')); -$id = GETPOST("id", 'int'); +$id = GETPOSTINT('id'); $ref = GETPOST('ref', 'alpha'); $action = GETPOST('action', 'aZ09'); $amounts = array(); -$accountid = GETPOST('accountid', 'int'); +$accountid = GETPOSTINT('accountid'); $cancel = GETPOST('cancel'); // Security check @@ -110,7 +110,7 @@ if ($action == 'add_payment') { $payment->datep = $datepaid; $payment->amounts = $amounts; // Tableau de montant $payment->total = $total; - $payment->fk_typepayment = GETPOST("fk_typepayment", 'int'); + $payment->fk_typepayment = GETPOSTINT("fk_typepayment"); $payment->num_payment = GETPOST("num_payment", 'alphanothtml'); $payment->note_public = GETPOST("note_public", 'restricthtml'); $payment->fk_bank = $accountid;