diff --git a/doc/developper/Doxyfile b/doc/developper/Doxyfile index c827a12e4..bbe229171 100644 --- a/doc/developper/Doxyfile +++ b/doc/developper/Doxyfile @@ -31,7 +31,7 @@ PROJECT_NAME = noalyss # This could be handy for archiving the generated documentation or # if some version control system is used. -PROJECT_NUMBER = Version-7.1 +PROJECT_NUMBER = Version-7.2 # The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) # base path where the generated documentation will be put. diff --git a/include/ajax/ajax_search_operation.php b/include/ajax/ajax_search_operation.php index 68988eab9..9c3a5ef6c 100644 --- a/include/ajax/ajax_search_operation.php +++ b/include/ajax/ajax_search_operation.php @@ -45,8 +45,8 @@ $tiers=$http->get("tiers", "string", ""); if (isset($_GET['amount_id'])) { put_global(array( - array("key"=>'amount_min', 'value'=>$_GET['amount_id']), - array("key"=>'amount_max', 'value'=>$_GET['amount_id']) + array("key"=>'amount_min', 'value'=>$http->get('amount_id',"number",0)), + array("key"=>'amount_max', 'value'=>$http->get('amount_id',"number",0)) )); } $target=$http->get("target", "string", ""); @@ -93,12 +93,14 @@ if (isset($_GET['viewsearch'])) // Navigation bar $step=MAX_RECONCILE; - $page=(isset($_GET['offset']))?$_GET['page']:1; - $offset=(isset($_GET['offset']))?$_GET['offset']:0; + $page=$http->get("page","number",1); + $offset=$http->get("offset","number",0); + if (count($_GET)==0) $array=null; else $array=$_GET; + $array['p_action']='ALL'; if (!isset($array['date_start'])||!isset($array['date_end'])) { diff --git a/include/class/acc_ledger_search.class.php b/include/class/acc_ledger_search.class.php index 12ba84e18..6f4ea8c1d 100644 --- a/include/class/acc_ledger_search.class.php +++ b/include/class/acc_ledger_search.class.php @@ -321,34 +321,79 @@ class Acc_Ledger_Search case when jrn_def_type='VEN' then (select ad_value from fiche_detail where ad_id=1 - and f_id=(select max(qs_client) from quant_sold join jrnx using (j_id) join jrn as e on (e.jr_grpt_id=j_grpt) where e.jr_id=x.jr_id)) + and f_id=(select max(qs_client) from quant_sold join jrnx + using (j_id) join jrn as e on (e.jr_grpt_id=j_grpt) + where e.jr_id=x.jr_id)) when jrn_def_type = 'ACH' then - (select ad_value from fiche_detail where ad_id=1 - and f_id=(select max(qp_supplier) from quant_purchase join jrnx using (j_id) join jrn as e on (e.jr_grpt_id=j_grpt) where e.jr_id=x.jr_id)) + (select ad_value + from fiche_detail + where ad_id=1 + and f_id=(select max(qp_supplier) from quant_purchase + join jrnx using (j_id) join jrn as e on (e.jr_grpt_id=j_grpt) where e.jr_id=x.jr_id)) when jrn_def_type = 'FIN' then (select ad_value from fiche_detail where ad_id=1 and f_id=(select qf_other from quant_fin where quant_fin.jr_id=x.jr_id)) end as name, case - when jrn_def_type='VEN' then (select ad_value from fiche_detail where ad_id=32 and f_id=(select max(qs_client) from quant_sold join jrnx using (j_id) join jrn as e on (e.jr_grpt_id=j_grpt) where e.jr_id=x.jr_id)) - when jrn_def_type = 'ACH' then (select ad_value from fiche_detail where ad_id=32 and f_id=(select max(qp_supplier) from quant_purchase join jrnx using (j_id) join jrn as e on (e.jr_grpt_id=j_grpt) where e.jr_id=x.jr_id)) - when jrn_def_type = 'FIN' then (select ad_value from fiche_detail where ad_id=32 and f_id=(select qf_other from quant_fin where quant_fin.jr_id=x.jr_id)) + when jrn_def_type='VEN' then + (select ad_value from fiche_detail + where ad_id=32 + and f_id=(select max(qs_client) + from quant_sold + join jrnx using (j_id) + join jrn as e on (e.jr_grpt_id=j_grpt) + where e.jr_id=x.jr_id)) + when jrn_def_type = 'ACH' then (select ad_value + from fiche_detail + where ad_id=32 + and f_id=(select max(qp_supplier) + from quant_purchase + join jrnx using (j_id) + join jrn as e on (e.jr_grpt_id=j_grpt) + where e.jr_id=x.jr_id)) + when jrn_def_type = 'FIN' then (select ad_value + from fiche_detail + where ad_id=32 + and f_id=(select qf_other from quant_fin where quant_fin.jr_id=x.jr_id)) end as first_name, case - when jrn_def_type='VEN' then (select ad_value from fiche_detail where ad_id=23 and f_id=(select max(qs_client) from quant_sold join jrnx using (j_id) join jrn as e on (e.jr_grpt_id=j_grpt) where e.jr_id=x.jr_id)) - when jrn_def_type = 'ACH' then (select ad_value from fiche_detail where ad_id=23 and f_id=(select max(qp_supplier) from quant_purchase join jrnx using (j_id) join jrn as e on (e.jr_grpt_id=j_grpt) where e.jr_id=x.jr_id)) - when jrn_def_type = 'FIN' then (select ad_value from fiche_detail where ad_id=23 and f_id=(select qf_other from quant_fin where quant_fin.jr_id=x.jr_id)) + when jrn_def_type='VEN' then + (select ad_value + from fiche_detail + where ad_id=23 + and f_id=(select max(qs_client) + from quant_sold + join jrnx using (j_id) + join jrn as e on (e.jr_grpt_id=j_grpt) + where e.jr_id=x.jr_id)) + when jrn_def_type = 'ACH' then (select ad_value + from fiche_detail + where ad_id=23 + and f_id=(select max(qp_supplier) + from quant_purchase + join jrnx using (j_id) + join jrn as e on (e.jr_grpt_id=j_grpt) + where e.jr_id=x.jr_id)) + when jrn_def_type = 'FIN' then (select ad_value + from fiche_detail + where ad_id=23 + and f_id=(select qf_other from quant_fin where quant_fin.jr_id=x.jr_id)) end as quick_code, case when jrn_def_type='VEN' then (select sum(qs_price)+sum(vat) from - (select qs_internal,qs_price,case when qs_vat_sided<>0 then 0 else qs_vat end as vat from quant_sold where qs_internal=X.jr_internal) as ven_invoice + (select qs_internal,qs_price,case when qs_vat_sided<>0 then 0 + else qs_vat end as vat + from quant_sold + where qs_internal=X.jr_internal) as ven_invoice ) when jrn_def_type = 'ACH' then ( select sum(qp_price)+sum(vat)+sum(qp_nd_tva)+sum(qp_nd_tva_recup) from - (select qp_internal,qp_price,qp_nd_tva,qp_nd_tva_recup,qp_vat-qp_vat_sided as vat from quant_purchase where qp_internal=X.jr_internal) as invoice_purchase + (select qp_internal,qp_price,qp_nd_tva,qp_nd_tva_recup,qp_vat-qp_vat_sided as vat + from quant_purchase + where qp_internal=X.jr_internal) as invoice_purchase ) else null end as total_invoice, @@ -1069,7 +1114,7 @@ class Acc_Ledger_Search } $r.="