From 312d93061a71a8e455adc883672c2f44e02eae30 Mon Sep 17 00:00:00 2001 From: Dany De Bontridder Date: Mon, 28 Jan 2019 20:10:01 +0100 Subject: [PATCH] Mantis #1665: Pouvoir modifier l'ordre dans les listing de compta analytique --- include/anc_history.inc.php | 3 +++ include/class/anc_listing.class.php | 24 +++++++++++++----------- include/class/anc_operation.class.php | 1 + include/class/anc_print.class.php | 16 +++++++++++----- 4 files changed, 28 insertions(+), 16 deletions(-) diff --git a/include/anc_history.inc.php b/include/anc_history.inc.php index bac4a8bbe..505927ede 100644 --- a/include/anc_history.inc.php +++ b/include/anc_history.inc.php @@ -27,6 +27,9 @@ if (isset($_GET['result'])) { echo $list->show_button(); echo $result; + echo '
'; + echo $list->show_button(); + } else { diff --git a/include/class/anc_listing.class.php b/include/class/anc_listing.class.php index 999c2fc7c..9ba5b34dd 100644 --- a/include/class/anc_listing.class.php +++ b/include/class/anc_listing.class.php @@ -72,9 +72,11 @@ class Anc_Listing extends Anc_Print } $cred=0;$deb=0; bcscale(2); - $r.= ''; + $r.='
'; + $r.=_('Cherche').HtmlInput::filter_table("tb_anchop",'0,1,2,3,4,5,6,7',1); + $r.= '
'; $r.= ''. - ''. + ''. ''. ''. ''. @@ -94,14 +96,14 @@ class Anc_Listing extends Anc_Print $card_detail=($row['f_id'] != null)?HtmlInput::history_card($row['f_id'],$row['qcode']):''; $r.= - ''. - td($post_detail). + ''. + td($post_detail,' sorttable_customkey="X'.$row['j_poste'].'"'). td($card_detail). ''. ''. td($row['jr_comment']). ''. - ''. + ''. ''; $r.= ''; if ( $row['oa_debit'] == 'f') {$cred=bcadd($cred,$row['oa_amount']);} @@ -112,15 +114,15 @@ class Anc_Listing extends Anc_Print ob_start(); echo _("Total"); echo '
    '; - echo '
  1. '.nbm($deb).' D '.'
  2. '; - echo '
  3. '.nbm($cred).' C '.'
  4. '; + echo '
  5. '._('Total')." ".nbm($deb).' D '.'
  6. '; + echo '
  7. '._('Total')." ".nbm($cred).' C '.'
  8. '; echo '
  9. '; echo _('Solde'); $solde=abs(bcsub($deb,$cred)); - echo $solde; - if ( $cred == $deb ) echo " = "; - else if ( $cred > $deb ) echo " C "; - else echo ' D '; + echo $solde." "; + echo findSide($deb-$cred); + echo '
  10. '; + echo '
'; $r_solde=ob_get_clean(); diff --git a/include/class/anc_operation.class.php b/include/class/anc_operation.class.php index aa3b19d3b..de27cbc90 100644 --- a/include/class/anc_operation.class.php +++ b/include/class/anc_operation.class.php @@ -235,6 +235,7 @@ class Anc_Operation po_description, oa_debit, (case when jr_date is not null then to_char(jr_date,'DD.MM.YYYY') else to_char(oa_date,'DD.MM.YYYY') end ) as oa_date, + (case when jr_date is not null then to_char(jr_date,'YYYYMMDD') else to_char(oa_date,'YYYYMMDD') end ) as str_order_date, oa_amount, oa_group, j_id , diff --git a/include/class/anc_print.class.php b/include/class/anc_print.class.php index 5e8ea00a1..174fb1a50 100644 --- a/include/class/anc_print.class.php +++ b/include/class/anc_print.class.php @@ -148,8 +148,6 @@ class Anc_Print echo $from->input(); ?> - - + + +
'._('Date').''._('Date').''._('Poste').''._('Quick_code').''._('Analytique').''.$row['oa_date'].''.$row['oa_date'].''.HtmlInput::history_anc_account($row['po_id'],h($row['po_name'])).''.h($row['oa_description']).''.$detail.''.nbm($row['oa_amount']).''.nbm($row['oa_amount']).''.(($row['oa_debit']=='f')?'C':'D').'
input(); ?> + + + input(); + echo Icon_Action::infobulle(42); + ?> +
- input(); - echo Icon_Action::infobulle(42); - ?> +