From 18d7e15a230f1d3b638c85c68f8c85f7a1302d0a Mon Sep 17 00:00:00 2001 From: florian HENRY Date: Wed, 5 Jun 2019 16:03:42 +0200 Subject: [PATCH] fix scrutinizer --- htdocs/loan/class/loanschedule.class.php | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/htdocs/loan/class/loanschedule.class.php b/htdocs/loan/class/loanschedule.class.php index da871af0e26..e968daa69fe 100644 --- a/htdocs/loan/class/loanschedule.class.php +++ b/htdocs/loan/class/loanschedule.class.php @@ -275,17 +275,13 @@ class LoanSchedule extends CommonObject $error=0; // Clean parameters - if (isset($this->fk_loan)) $this->fk_loan=trim($this->fk_loan); if (isset($this->amount_capital)) $this->amount_capital=trim($this->amount_capital); if (isset($this->amount_insurance)) $this->amount_insurance=trim($this->amount_insurance); if (isset($this->amount_interest)) $this->amount_interest=trim($this->amount_interest); - if (isset($this->fk_typepayment)) $this->fk_typepayment=trim($this->fk_typepayment); if (isset($this->num_payment)) $this->num_payment=trim($this->num_payment); if (isset($this->note_private)) $this->note_private=trim($this->note_private); if (isset($this->note_public)) $this->note_public=trim($this->note_public); if (isset($this->fk_bank)) $this->fk_bank=trim($this->fk_bank); - if (isset($this->fk_user_creat)) $this->fk_user_creat=trim($this->fk_user_creat); - if (isset($this->fk_user_modif)) $this->fk_user_modif=trim($this->fk_user_modif); // Check parameters // Put here code to add control on parameters values @@ -564,6 +560,9 @@ class LoanSchedule extends CommonObject */ public function paimenttorecord($loanid, $datemax) { + + $result=array(); + $sql = "SELECT p.rowid"; $sql.= " FROM ".MAIN_DB_PREFIX.$this->table_element." as p "; $sql.= " WHERE p.fk_loan = " . $loanid;