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

This commit is contained in:
Laurent Destailleur 2024-03-01 19:05:46 +01:00
commit 47861abb48
5 changed files with 9 additions and 7 deletions

View file

@ -3024,6 +3024,7 @@ class Adherent extends CommonObject
$sql = 'SELECT rowid FROM '.MAIN_DB_PREFIX.'adherent';
$sql .= " WHERE entity = ".((int) $conf->entity); // Do not use getEntity('adherent').")" here, we want the batch to be on its entity only;
$sql .= " AND statut = 1";
$sql .= " AND datefin = '".$this->db->idate($datetosearchfor)."'";
//$sql .= " LIMIT 10000";

View file

@ -1906,7 +1906,8 @@ if ($num > 0) {
$facturestatic->id = $obj->id;
$facturestatic->ref = $obj->ref;
$facturestatic->ref_client = $obj->ref_client;
$facturestatic->ref_client = $obj->ref_client; // deprecated
$facturestatic->ref_customer = $obj->ref_client;
$facturestatic->type = $obj->type;
$facturestatic->subtype = $obj->subtype;
$facturestatic->total_ht = $obj->total_ht;

View file

@ -9423,9 +9423,9 @@ abstract class CommonObject
/**
* Function to prepare a part of the query for insert by returning an array with all properties of object.
* Function to return the array of data key-value from the ->fields and all the ->properties of an object.
*
* Note $this->${field} are set by the page that make the createCommon() or the updateCommon().
* Note: $this->${field} are set by the page that make the createCommon() or the updateCommon().
* $this->${field} should be a clean and string value (so date are formated for SQL insert).
*
* @return array Array with all values of each properties to update

View file

@ -81,7 +81,7 @@ function expensereport_prepare_head($object)
$head[$h][2] = 'info';
$h++;
complete_head_from_modules($conf, $langs, $object, $head, $h, 'donation', 'add', 'external');
complete_head_from_modules($conf, $langs, $object, $head, $h, 'expensereport', 'add', 'external');
complete_head_from_modules($conf, $langs, $object, $head, $h, 'expensereport', 'remove');

View file

@ -1351,8 +1351,6 @@ if (empty($reshook)) {
$tva_tx = get_default_tva($soc, $mysoc, $lines[$i]->fk_product, $product_fourn_price_id);
}
$object->special_code = $lines[$i]->special_code;
$result = $object->addline(
$desc,
$lines[$i]->subprice,
@ -1375,7 +1373,9 @@ if (empty($reshook)) {
$lines[$i]->fk_unit,
0,
$element,
!empty($lines[$i]->id) ? $lines[$i]->id : $lines[$i]->rowid
!empty($lines[$i]->id) ? $lines[$i]->id : $lines[$i]->rowid,
-1,
$lines[$i]->special_code
);
if ($result < 0) {