Merge branch '16.0' of git@github.com:Dolibarr/dolibarr.git into 16.0
This commit is contained in:
commit
9a0b10bf9f
@ -1755,6 +1755,7 @@ function weight_convert($weight, &$from_unit, $to_unit)
|
|||||||
* weigh_convert(320, $f, 0) retournera 0.32
|
* weigh_convert(320, $f, 0) retournera 0.32
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
$weight = is_numeric($weight) ? $weight : 0;
|
||||||
while ($from_unit <> $to_unit) {
|
while ($from_unit <> $to_unit) {
|
||||||
if ($from_unit > $to_unit) {
|
if ($from_unit > $to_unit) {
|
||||||
$weight = $weight * 10;
|
$weight = $weight * 10;
|
||||||
|
|||||||
@ -174,6 +174,9 @@ if (empty($reshook)) {
|
|||||||
if (GETPOST('button_removefilter_x', 'alpha') || GETPOST('button_removefilter.x', 'alpha') || GETPOST('button_removefilter', 'alpha')) { // All tests are required to be compatible with all browsers
|
if (GETPOST('button_removefilter_x', 'alpha') || GETPOST('button_removefilter.x', 'alpha') || GETPOST('button_removefilter', 'alpha')) { // All tests are required to be compatible with all browsers
|
||||||
foreach ($object->fields as $key => $val) {
|
foreach ($object->fields as $key => $val) {
|
||||||
$search[$key] = '';
|
$search[$key] = '';
|
||||||
|
if ($key == 'status') {
|
||||||
|
$search[$key] = -1;
|
||||||
|
}
|
||||||
if (preg_match('/^(date|timestamp|datetime)/', $val['type'])) {
|
if (preg_match('/^(date|timestamp|datetime)/', $val['type'])) {
|
||||||
$search[$key.'_dtstart'] = '';
|
$search[$key.'_dtstart'] = '';
|
||||||
$search[$key.'_dtend'] = '';
|
$search[$key.'_dtend'] = '';
|
||||||
@ -247,7 +250,7 @@ foreach ($search as $key => $val) {
|
|||||||
if ($key == 'status' && $search[$key] == -1) {
|
if ($key == 'status' && $search[$key] == -1) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if ($key == 'fk_parent_line') {
|
if ($key == 'fk_parent_line' && $search[$key] != '') {
|
||||||
$sql .= natural_search('moparent.ref', $search[$key], 0);
|
$sql .= natural_search('moparent.ref', $search[$key], 0);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user