Fix blockedlog module must store ref of invoice once validated
This commit is contained in:
parent
d0680b429f
commit
8014f7d822
@ -364,6 +364,8 @@ class BlockedLog
|
|||||||
))) continue; // Discard if not into a dedicated list
|
))) continue; // Discard if not into a dedicated list
|
||||||
if (!is_object($value)) $this->object_data->{$key} = $value;
|
if (!is_object($value)) $this->object_data->{$key} = $value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (! empty($object->newref)) $this->object_data->ref = $object->newref;
|
||||||
}
|
}
|
||||||
elseif ($this->element == 'invoice_supplier')
|
elseif ($this->element == 'invoice_supplier')
|
||||||
{
|
{
|
||||||
@ -375,6 +377,8 @@ class BlockedLog
|
|||||||
))) continue; // Discard if not into a dedicated list
|
))) continue; // Discard if not into a dedicated list
|
||||||
if (!is_object($value)) $this->object_data->{$key} = $value;
|
if (!is_object($value)) $this->object_data->{$key} = $value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (! empty($object->newref)) $this->object_data->ref = $object->newref;
|
||||||
}
|
}
|
||||||
elseif ($this->element == 'payment' || $this->element == 'payment_supplier' || $this->element == 'payment_donation')
|
elseif ($this->element == 'payment' || $this->element == 'payment_supplier' || $this->element == 'payment_donation')
|
||||||
{
|
{
|
||||||
@ -474,10 +478,14 @@ class BlockedLog
|
|||||||
}
|
}
|
||||||
|
|
||||||
$this->object_data->amount = $totalamount;
|
$this->object_data->amount = $totalamount;
|
||||||
|
|
||||||
|
if (! empty($object->newref)) $this->object_data->ref = $object->newref;
|
||||||
}
|
}
|
||||||
elseif($this->element == 'payment_salary')
|
elseif($this->element == 'payment_salary')
|
||||||
{
|
{
|
||||||
$this->object_data->amounts = array($object->amount);
|
$this->object_data->amounts = array($object->amount);
|
||||||
|
|
||||||
|
if (! empty($object->newref)) $this->object_data->ref = $object->newref;
|
||||||
}
|
}
|
||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
|
|||||||
@ -1,5 +1,6 @@
|
|||||||
<?php
|
<?php
|
||||||
/* Copyright (C) 2017 ATM Consulting <contact@atm-consulting.fr>
|
/* Copyright (C) 2017 ATM Consulting <contact@atm-consulting.fr>
|
||||||
|
* Copyright (C) 2017-2018 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user