Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop

This commit is contained in:
Laurent Destailleur 2022-04-01 19:32:35 +02:00
commit 7b9b5d726a
3 changed files with 18 additions and 3 deletions

View File

@ -135,6 +135,11 @@ class Orders extends DolibarrApi
// Add external contacts ids
$this->commande->contacts_ids = $this->commande->liste_contact(-1, 'external', $contact_list);
$this->commande->fetchObjectLinked();
// Add online_payment_url, cf #20477
require_once DOL_DOCUMENT_ROOT.'/core/lib/payments.lib.php';
$this->commande->online_payment_url = getOnlinePaymentUrl(0, 'order', $this->commande->ref);
return $this->_cleanObjectDatas($this->commande);
}
@ -230,6 +235,10 @@ class Orders extends DolibarrApi
if ($commande_static->fetch($obj->rowid)) {
// Add external contacts ids
$commande_static->contacts_ids = $commande_static->liste_contact(-1, 'external', 1);
// Add online_payment_url, cf #20477
require_once DOL_DOCUMENT_ROOT.'/core/lib/payments.lib.php';
$commande_static->online_payment_url = getOnlinePaymentUrl(0, 'order', $commande_static->ref);
$obj_ret[] = $this->_cleanObjectDatas($commande_static);
}
$i++;
@ -735,6 +744,10 @@ class Orders extends DolibarrApi
$this->commande->fetchObjectLinked();
//fix #20477 : add online_payment_url
require_once DOL_DOCUMENT_ROOT.'/core/lib/payments.lib.php';
$this->commande->online_payment_url = getOnlinePaymentUrl(0, 'order', $this->commande->ref);
return $this->_cleanObjectDatas($this->commande);
}

View File

@ -266,6 +266,11 @@ class Commande extends CommonOrder
*/
public $expeditions;
/**
* @var string payment url
*/
public $online_payment_url;
/**
* 'type' if the field format ('integer', 'integer:ObjectClass:PathToClass[:AddCreateButtonOrNot[:Filter]]', 'varchar(x)', 'double(24,8)', 'real', 'price', 'text', 'html', 'date', 'datetime', 'timestamp', 'duration', 'mail', 'phone', 'url', 'password')

View File

@ -2493,10 +2493,7 @@ if ($action == 'create') {
print '<td></td>';
print '<td></td>';
print '<td></td>';
print '<td></td>';
print '<td></td>';
print '</tr>';
print '<tr class="oddeven nohover">';
// Line number