From 9a963da77c8aebabcb2e72d6fa35c0fe38f4950f Mon Sep 17 00:00:00 2001
From: Marc de Lima Lucio <68746600+marc-dll@users.noreply.github.com>
Date: Wed, 13 Oct 2021 11:39:09 +0200
Subject: [PATCH] FIX: deposit payment terms: adapt
Form::form_conditions_reglement() calls to new parameter added in between PRs
---
htdocs/comm/card.php | 4 ++--
htdocs/comm/propal/card.php | 4 ++--
htdocs/comm/propal/list.php | 2 +-
htdocs/commande/card.php | 4 ++--
htdocs/commande/list.php | 2 +-
5 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/htdocs/comm/card.php b/htdocs/comm/card.php
index 45437020107..be96a22e41a 100644
--- a/htdocs/comm/card.php
+++ b/htdocs/comm/card.php
@@ -411,9 +411,9 @@ if ($object->id > 0) {
print '';
print '
';
if ($action == 'editconditions') {
- $form->form_conditions_reglement($_SERVER['PHP_SELF'].'?socid='.$object->id, $object->cond_reglement_id, 'cond_reglement_id', 1, 1, $object->deposit_percent);
+ $form->form_conditions_reglement($_SERVER['PHP_SELF'].'?socid='.$object->id, $object->cond_reglement_id, 'cond_reglement_id', 1, '', 1, $object->deposit_percent);
} else {
- $form->form_conditions_reglement($_SERVER['PHP_SELF'].'?socid='.$object->id, $object->cond_reglement_id, 'none', 0, 1, $object->deposit_percent);
+ $form->form_conditions_reglement($_SERVER['PHP_SELF'].'?socid='.$object->id, $object->cond_reglement_id, 'none', 0, '', 1, $object->deposit_percent);
}
print " | ";
print '';
diff --git a/htdocs/comm/propal/card.php b/htdocs/comm/propal/card.php
index c0c630a0fde..647412e113a 100644
--- a/htdocs/comm/propal/card.php
+++ b/htdocs/comm/propal/card.php
@@ -2329,9 +2329,9 @@ if ($action == 'create') {
print '';
print '';
if ($object->statut == Propal::STATUS_DRAFT && $action == 'editconditions' && $usercancreate) {
- $form->form_conditions_reglement($_SERVER['PHP_SELF'].'?id='.$object->id, $object->cond_reglement_id, 'cond_reglement_id', 0, 1, $object->deposit_percent);
+ $form->form_conditions_reglement($_SERVER['PHP_SELF'].'?id='.$object->id, $object->cond_reglement_id, 'cond_reglement_id', 0, '', 1, $object->deposit_percent);
} else {
- $form->form_conditions_reglement($_SERVER['PHP_SELF'].'?id='.$object->id, $object->cond_reglement_id, 'none', 0, 1, $object->deposit_percent);
+ $form->form_conditions_reglement($_SERVER['PHP_SELF'].'?id='.$object->id, $object->cond_reglement_id, 'none', 0, '', 1, $object->deposit_percent);
}
print ' | ';
print '';
diff --git a/htdocs/comm/propal/list.php b/htdocs/comm/propal/list.php
index c3276887635..282fbe3ec22 100644
--- a/htdocs/comm/propal/list.php
+++ b/htdocs/comm/propal/list.php
@@ -1673,7 +1673,7 @@ if ($resql) {
// Payment terms
if (!empty($arrayfields['p.fk_cond_reglement']['checked'])) {
print '';
- $form->form_conditions_reglement($_SERVER['PHP_SELF'], $obj->fk_cond_reglement, 'none', 0, 1, $obj->deposit_percent);
+ $form->form_conditions_reglement($_SERVER['PHP_SELF'], $obj->fk_cond_reglement, 'none', 0, '', 1, $obj->deposit_percent);
print ' | ';
if (!$i) {
$totalarray['nbfield']++;
diff --git a/htdocs/commande/card.php b/htdocs/commande/card.php
index e94f6bb460c..80782a53a81 100644
--- a/htdocs/commande/card.php
+++ b/htdocs/commande/card.php
@@ -2374,9 +2374,9 @@ if ($action == 'create' && $usercancreate) {
print $form->editfieldkey("PaymentConditionsShort", 'conditions', '', $object, $editenable);
print '';
if ($action == 'editconditions') {
- $form->form_conditions_reglement($_SERVER['PHP_SELF'].'?id='.$object->id, $object->cond_reglement_id, 'cond_reglement_id', 1, 1, $object->deposit_percent);
+ $form->form_conditions_reglement($_SERVER['PHP_SELF'].'?id='.$object->id, $object->cond_reglement_id, 'cond_reglement_id', 1, '', 1, $object->deposit_percent);
} else {
- $form->form_conditions_reglement($_SERVER['PHP_SELF'].'?id='.$object->id, $object->cond_reglement_id, 'none', 1, 1, $object->deposit_percent);
+ $form->form_conditions_reglement($_SERVER['PHP_SELF'].'?id='.$object->id, $object->cond_reglement_id, 'none', 1, '', 1, $object->deposit_percent);
}
print ' | ';
diff --git a/htdocs/commande/list.php b/htdocs/commande/list.php
index 5fb66a9dd62..216e1aa0bfb 100644
--- a/htdocs/commande/list.php
+++ b/htdocs/commande/list.php
@@ -1592,7 +1592,7 @@ if ($resql) {
// Payment terms
if (!empty($arrayfields['c.fk_cond_reglement']['checked'])) {
print '';
- $form->form_conditions_reglement($_SERVER['PHP_SELF'], $obj->fk_cond_reglement, 'none', 0, 1, $obj->deposit_percent);
+ $form->form_conditions_reglement($_SERVER['PHP_SELF'], $obj->fk_cond_reglement, 'none', 0, '', 1, $obj->deposit_percent);
print ' | ';
if (!$i) {
$totalarray['nbfield']++;