Merge branch '6.0' into 6.0_fhe
This commit is contained in:
commit
06189f8153
@ -83,12 +83,14 @@ $mesg=(GETPOST("msg") ? GETPOST("msg") : GETPOST("mesg"));
|
|||||||
$search_day=GETPOST("search_day","int");
|
$search_day=GETPOST("search_day","int");
|
||||||
$search_month=GETPOST("search_month","int");
|
$search_month=GETPOST("search_month","int");
|
||||||
$search_year=GETPOST("search_year","int");
|
$search_year=GETPOST("search_year","int");
|
||||||
|
$search_btn=GETPOST('button_search','alpha');
|
||||||
|
$search_remove_btn=GETPOST('button_removefilter','alpha');
|
||||||
|
|
||||||
$limit = GETPOST('limit')?GETPOST('limit','int'):$conf->liste_limit;
|
$limit = GETPOST('limit')?GETPOST('limit','int'):$conf->liste_limit;
|
||||||
$sortfield = GETPOST("sortfield",'alpha');
|
$sortfield = GETPOST("sortfield",'alpha');
|
||||||
$sortorder = GETPOST("sortorder",'alpha');
|
$sortorder = GETPOST("sortorder",'alpha');
|
||||||
$page = GETPOST("page",'int');
|
$page = GETPOST("page",'int');
|
||||||
if (empty($page) || $page == -1) { $page = 0; } // If $page is not defined, or '' or -1
|
if (empty($page) || $page == -1 || !empty($search_btn) || !empty($search_remove_btn) || (empty($toselect) && $massaction === '0')) { $page = 0; } // If $page is not defined, or '' or -1
|
||||||
$offset = $limit * $page;
|
$offset = $limit * $page;
|
||||||
$pageprev = $page - 1;
|
$pageprev = $page - 1;
|
||||||
$pagenext = $page + 1;
|
$pagenext = $page + 1;
|
||||||
|
|||||||
@ -74,6 +74,8 @@ $search_total_ht=GETPOST('search_total_ht','alpha');
|
|||||||
$optioncss = GETPOST('optioncss','alpha');
|
$optioncss = GETPOST('optioncss','alpha');
|
||||||
$billed = GETPOST('billed','int');
|
$billed = GETPOST('billed','int');
|
||||||
$viewstatut=GETPOST('viewstatut');
|
$viewstatut=GETPOST('viewstatut');
|
||||||
|
$search_btn=GETPOST('button_search','alpha');
|
||||||
|
$search_remove_btn=GETPOST('button_removefilter','alpha');
|
||||||
|
|
||||||
// Security check
|
// Security check
|
||||||
$id = (GETPOST('orderid')?GETPOST('orderid','int'):GETPOST('id','int'));
|
$id = (GETPOST('orderid')?GETPOST('orderid','int'):GETPOST('id','int'));
|
||||||
@ -86,7 +88,7 @@ $limit = GETPOST('limit','int')?GETPOST('limit','int'):$conf->liste_limit;
|
|||||||
$sortfield = GETPOST("sortfield",'alpha');
|
$sortfield = GETPOST("sortfield",'alpha');
|
||||||
$sortorder = GETPOST("sortorder",'alpha');
|
$sortorder = GETPOST("sortorder",'alpha');
|
||||||
$page = GETPOST("page",'int');
|
$page = GETPOST("page",'int');
|
||||||
if (empty($page) || $page == -1) { $page = 0; } // If $page is not defined, or '' or -1
|
if (empty($page) || $page == -1 || !empty($search_btn) || !empty($search_remove_btn) || (empty($toselect) && $massaction === '0')) { $page = 0; } // If $page is not defined, or '' or -1
|
||||||
$offset = $limit * $page;
|
$offset = $limit * $page;
|
||||||
$pageprev = $page - 1;
|
$pageprev = $page - 1;
|
||||||
$pagenext = $page + 1;
|
$pagenext = $page + 1;
|
||||||
|
|||||||
@ -4834,7 +4834,7 @@ class FactureLigne extends CommonInvoiceLine
|
|||||||
$resql = $this->db->query($sql);
|
$resql = $this->db->query($sql);
|
||||||
if ($resql && $resql->num_rows > 0) {
|
if ($resql && $resql->num_rows > 0) {
|
||||||
$res = $this->db->fetch_array($resql);
|
$res = $this->db->fetch_array($resql);
|
||||||
return $res['situation_percent'];
|
return floatval($res['situation_percent']);
|
||||||
} else {
|
} else {
|
||||||
$this->error = $this->db->error();
|
$this->error = $this->db->error();
|
||||||
dol_syslog(get_class($this) . "::select Error " . $this->error, LOG_ERR);
|
dol_syslog(get_class($this) . "::select Error " . $this->error, LOG_ERR);
|
||||||
|
|||||||
@ -93,6 +93,8 @@ $year = GETPOST('year','int');
|
|||||||
$day_lim = GETPOST('day_lim','int');
|
$day_lim = GETPOST('day_lim','int');
|
||||||
$month_lim = GETPOST('month_lim','int');
|
$month_lim = GETPOST('month_lim','int');
|
||||||
$year_lim = GETPOST('year_lim','int');
|
$year_lim = GETPOST('year_lim','int');
|
||||||
|
$search_btn=GETPOST('button_search','alpha');
|
||||||
|
$search_remove_btn=GETPOST('button_removefilter','alpha');
|
||||||
|
|
||||||
$option = GETPOST('option');
|
$option = GETPOST('option');
|
||||||
if ($option == 'late') {
|
if ($option == 'late') {
|
||||||
@ -104,7 +106,7 @@ $limit = GETPOST('limit')?GETPOST('limit','int'):$conf->liste_limit;
|
|||||||
$sortfield = GETPOST("sortfield",'alpha');
|
$sortfield = GETPOST("sortfield",'alpha');
|
||||||
$sortorder = GETPOST("sortorder",'alpha');
|
$sortorder = GETPOST("sortorder",'alpha');
|
||||||
$page = GETPOST("page",'int');
|
$page = GETPOST("page",'int');
|
||||||
if (empty($page) || $page == -1) { $page = 0; } // If $page is not defined, or '' or -1
|
if (empty($page) || $page == -1 || !empty($search_btn) || !empty($search_remove_btn) || (empty($toselect) && $massaction === '0')) { $page = 0; } // If $page is not defined, or '' or -1
|
||||||
$offset = $limit * $page;
|
$offset = $limit * $page;
|
||||||
if (! $sortorder && ! empty($conf->global->INVOICE_DEFAULT_UNPAYED_SORT_ORDER) && $search_status == 1) $sortorder=$conf->global->INVOICE_DEFAULT_UNPAYED_SORT_ORDER;
|
if (! $sortorder && ! empty($conf->global->INVOICE_DEFAULT_UNPAYED_SORT_ORDER) && $search_status == 1) $sortorder=$conf->global->INVOICE_DEFAULT_UNPAYED_SORT_ORDER;
|
||||||
if (! $sortorder) $sortorder='DESC';
|
if (! $sortorder) $sortorder='DESC';
|
||||||
|
|||||||
@ -1899,13 +1899,13 @@ function pdf_getlinetotalexcltax($object,$i,$outputlangs,$hidedetails=0)
|
|||||||
{
|
{
|
||||||
$prev_progress = 0;
|
$prev_progress = 0;
|
||||||
$progress = 1;
|
$progress = 1;
|
||||||
if (method_exists($object, 'get_prev_progress'))
|
if (method_exists($object->lines[$i], 'get_prev_progress'))
|
||||||
{
|
{
|
||||||
$prev_progress = $object->lines[$i]->get_prev_progress($object->id);
|
$prev_progress = $object->lines[$i]->get_prev_progress($object->id);
|
||||||
$progress = ($object->lines[$i]->situation_percent - $prev_progress) / 100;
|
$progress = ($object->lines[$i]->situation_percent - $prev_progress) / 100;
|
||||||
}
|
}
|
||||||
$result.=price($sign * ($total_ht/($object->lines[$i]->situation_percent/100)) * $progress, 0, $outputlangs);
|
$result.=price($sign * ($total_ht/($object->lines[$i]->situation_percent/100)) * $progress, 0, $outputlangs);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
$result.=price($sign * $total_ht, 0, $outputlangs);
|
$result.=price($sign * $total_ht, 0, $outputlangs);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -85,6 +85,8 @@ $search_total_ttc=GETPOST('search_total_ttc','alpha');
|
|||||||
$optioncss = GETPOST('optioncss','alpha');
|
$optioncss = GETPOST('optioncss','alpha');
|
||||||
$billed = GETPOST('billed','int');
|
$billed = GETPOST('billed','int');
|
||||||
$search_project_ref=GETPOST('search_project_ref','alpha');
|
$search_project_ref=GETPOST('search_project_ref','alpha');
|
||||||
|
$search_btn=GETPOST('button_search','alpha');
|
||||||
|
$search_remove_btn=GETPOST('button_removefilter','alpha');
|
||||||
|
|
||||||
$page = GETPOST('page','int');
|
$page = GETPOST('page','int');
|
||||||
$sortorder = GETPOST('sortorder','alpha');
|
$sortorder = GETPOST('sortorder','alpha');
|
||||||
@ -105,7 +107,7 @@ $limit = GETPOST('limit','int')?GETPOST('limit','int'):$conf->liste_limit;
|
|||||||
$sortfield = GETPOST("sortfield",'alpha');
|
$sortfield = GETPOST("sortfield",'alpha');
|
||||||
$sortorder = GETPOST("sortorder",'alpha');
|
$sortorder = GETPOST("sortorder",'alpha');
|
||||||
$page = GETPOST("page",'int');
|
$page = GETPOST("page",'int');
|
||||||
if (empty($page) || $page == -1) { $page = 0; } // If $page is not defined, or '' or -1
|
if (empty($page) || $page == -1 || !empty($search_btn) || !empty($search_remove_btn) || (empty($toselect) && $massaction === '0')) { $page = 0; } // If $page is not defined, or '' or -1
|
||||||
$offset = $limit * $page;
|
$offset = $limit * $page;
|
||||||
$pageprev = $page - 1;
|
$pageprev = $page - 1;
|
||||||
$pagenext = $page + 1;
|
$pagenext = $page + 1;
|
||||||
|
|||||||
@ -99,6 +99,8 @@ $day_lim = GETPOST('day_lim','int');
|
|||||||
$month_lim = GETPOST('month_lim','int');
|
$month_lim = GETPOST('month_lim','int');
|
||||||
$year_lim = GETPOST('year_lim','int');
|
$year_lim = GETPOST('year_lim','int');
|
||||||
$toselect = GETPOST('toselect', 'array');
|
$toselect = GETPOST('toselect', 'array');
|
||||||
|
$search_btn=GETPOST('button_search','alpha');
|
||||||
|
$search_remove_btn=GETPOST('button_removefilter','alpha');
|
||||||
|
|
||||||
$option = GETPOST('option');
|
$option = GETPOST('option');
|
||||||
if ($option == 'late') {
|
if ($option == 'late') {
|
||||||
@ -110,7 +112,7 @@ $limit = GETPOST('limit')?GETPOST('limit','int'):$conf->liste_limit;
|
|||||||
$sortfield = GETPOST("sortfield",'alpha');
|
$sortfield = GETPOST("sortfield",'alpha');
|
||||||
$sortorder = GETPOST("sortorder",'alpha');
|
$sortorder = GETPOST("sortorder",'alpha');
|
||||||
$page=GETPOST("page",'int');
|
$page=GETPOST("page",'int');
|
||||||
if ($page == -1 || $page == null) { $page = 0 ; }
|
if ($page == -1 || $page == null || !empty($search_btn) || !empty($search_remove_btn) || (empty($toselect) && $massaction === '0')) { $page = 0 ; }
|
||||||
$offset = $limit * $page ;
|
$offset = $limit * $page ;
|
||||||
$pageprev = $page - 1;
|
$pageprev = $page - 1;
|
||||||
$pagenext = $page + 1;
|
$pagenext = $page + 1;
|
||||||
|
|||||||
@ -134,7 +134,7 @@ if (dol_strlen($type))
|
|||||||
$sql.= " AND p.fk_product_type <> '1'";
|
$sql.= " AND p.fk_product_type <> '1'";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if ($sref) $sql.= natural_search('p.ref', $ref);
|
if ($sref) $sql.= natural_search('p.ref', $sref);
|
||||||
if ($sbarcode) $sql.= natural_search('p.barcode', $sbarcode);
|
if ($sbarcode) $sql.= natural_search('p.barcode', $sbarcode);
|
||||||
if ($snom) $sql.= natural_search('p.label', $snom);
|
if ($snom) $sql.= natural_search('p.label', $snom);
|
||||||
if (! empty($tosell)) $sql.= " AND p.tosell = ".$tosell;
|
if (! empty($tosell)) $sql.= " AND p.tosell = ".$tosell;
|
||||||
|
|||||||
@ -82,6 +82,8 @@ $search_type=GETPOST('search_type','alpha');
|
|||||||
$search_level_from = GETPOST("search_level_from","alpha");
|
$search_level_from = GETPOST("search_level_from","alpha");
|
||||||
$search_level_to = GETPOST("search_level_to","alpha");
|
$search_level_to = GETPOST("search_level_to","alpha");
|
||||||
$search_stcomm=GETPOST('search_stcomm','int');
|
$search_stcomm=GETPOST('search_stcomm','int');
|
||||||
|
$search_btn=GETPOST('button_search','alpha');
|
||||||
|
$search_remove_btn=GETPOST('button_removefilter','alpha');
|
||||||
|
|
||||||
$type=GETPOST('type');
|
$type=GETPOST('type');
|
||||||
$optioncss=GETPOST('optioncss','alpha');
|
$optioncss=GETPOST('optioncss','alpha');
|
||||||
@ -95,7 +97,7 @@ $sortorder=GETPOST("sortorder",'alpha');
|
|||||||
$page=GETPOST("page",'int');
|
$page=GETPOST("page",'int');
|
||||||
if (! $sortorder) $sortorder="ASC";
|
if (! $sortorder) $sortorder="ASC";
|
||||||
if (! $sortfield) $sortfield="s.nom";
|
if (! $sortfield) $sortfield="s.nom";
|
||||||
if (empty($page) || $page == -1) { $page = 0; }
|
if (empty($page) || $page == -1 || !empty($search_btn) || !empty($search_remove_btn) || (empty($toselect) && $massaction === '0')) { $page = 0; }
|
||||||
$offset = $limit * $page;
|
$offset = $limit * $page;
|
||||||
$pageprev = $page - 1;
|
$pageprev = $page - 1;
|
||||||
$pagenext = $page + 1;
|
$pagenext = $page + 1;
|
||||||
|
|||||||
@ -73,6 +73,8 @@ $search_montant_vat=GETPOST('search_montant_vat','alpha');
|
|||||||
$search_montant_ttc=GETPOST('search_montant_ttc','alpha');
|
$search_montant_ttc=GETPOST('search_montant_ttc','alpha');
|
||||||
$search_status=GETPOST('viewstatut','alpha')?GETPOST('viewstatut','alpha'):GETPOST('search_status','int');
|
$search_status=GETPOST('viewstatut','alpha')?GETPOST('viewstatut','alpha'):GETPOST('search_status','int');
|
||||||
$object_statut=$db->escape(GETPOST('supplier_proposal_statut'));
|
$object_statut=$db->escape(GETPOST('supplier_proposal_statut'));
|
||||||
|
$search_btn=GETPOST('button_search','alpha');
|
||||||
|
$search_remove_btn=GETPOST('button_removefilter','alpha');
|
||||||
|
|
||||||
$sall=GETPOST('sall', 'alphanohtml');
|
$sall=GETPOST('sall', 'alphanohtml');
|
||||||
$mesg=(GETPOST("msg") ? GETPOST("msg") : GETPOST("mesg"));
|
$mesg=(GETPOST("msg") ? GETPOST("msg") : GETPOST("mesg"));
|
||||||
@ -85,7 +87,7 @@ $limit = GETPOST('limit')?GETPOST('limit','int'):$conf->liste_limit;
|
|||||||
$sortfield = GETPOST("sortfield",'alpha');
|
$sortfield = GETPOST("sortfield",'alpha');
|
||||||
$sortorder = GETPOST("sortorder",'alpha');
|
$sortorder = GETPOST("sortorder",'alpha');
|
||||||
$page = GETPOST("page",'int');
|
$page = GETPOST("page",'int');
|
||||||
if (empty($page) || $page == -1) { $page = 0; } // If $page is not defined, or '' or -1
|
if (empty($page) || $page == -1 || !empty($search_btn) || !empty($search_remove_btn) || (empty($toselect) && $massaction === '0')) { $page = 0; } // If $page is not defined, or '' or -1
|
||||||
$offset = $limit * $page;
|
$offset = $limit * $page;
|
||||||
$pageprev = $page - 1;
|
$pageprev = $page - 1;
|
||||||
$pagenext = $page + 1;
|
$pagenext = $page + 1;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user