diff --git a/htdocs/compta/bank/releve.php b/htdocs/compta/bank/releve.php index 1f747cd04ec..5facd023c4e 100644 --- a/htdocs/compta/bank/releve.php +++ b/htdocs/compta/bank/releve.php @@ -29,6 +29,19 @@ require("./pre.inc.php"); if (!$user->rights->banque->lire) accessforbidden(); +if ($_GET["action"] == 'dvnext') +{ + $ac = new Account($db); + $ac->datev_next($_GET["dvid"]); +} + + +if ($_GET["action"] == 'dvprev') +{ + $ac = new Account($db); + $ac->datev_previous($_GET["dvid"]); +} + llxHeader(); @@ -135,7 +148,7 @@ else print ""; print '
| Date | Type | Description | '; + print 'Date Ope | Valeur | Type | Description | '; print 'Debit | '; print 'Credit | '; print 'Solde | '; @@ -151,14 +164,14 @@ else } - $sql = "SELECT b.rowid,".$db->pdate("b.dateo")." as do, b.amount, b.label, b.rappro, b.num_releve, b.num_chq, b.fk_type"; + $sql = "SELECT b.rowid,".$db->pdate("b.dateo")." as do,".$db->pdate("b.datev")." as dv, b.amount, b.label, b.rappro, b.num_releve, b.num_chq, b.fk_type"; $sql .= " FROM ".MAIN_DB_PREFIX."bank as b WHERE"; $sql .= " num_releve='".$_GET["num"]."'"; if (! $_GET["num"]) { $sql .= " or num_releve is null"; } $sql .= " AND fk_account = ".$acct->id; - $sql .= " ORDER BY dateo ASC"; + $sql .= " ORDER BY datev ASC"; $result = $db->query($sql); if ($result) { @@ -176,7 +189,17 @@ else $var=!$var; print "
| ".strftime("%d %b %Y",$objp->do)." | \n"; + print ''.strftime("%d %b %Y",$objp->do).' | '; + + /* Mise à jour de la date de valeur */ + + print 'rowid.'">'; + print img_previous() . " "; + print strftime("%d/%m/%Y",$objp->dv) ." "; + print 'rowid.'">'; + print img_next(); + + print " | \n"; print ''.$objp->fk_type.' '.($objp->num_chq?$objp->num_chq:'').' | '; print "$objp->label"; |