Skip to content
Snippets Groups Projects
Commit c89fd4b1 authored by Laurent Destailleur's avatar Laurent Destailleur
Browse files

New: Can conciliate several lines in one operation.

parent f0936408
Branches
Tags v1.0.4
No related merge requests found
...@@ -20,6 +20,7 @@ For users: ...@@ -20,6 +20,7 @@ For users:
- New: Add hidden option FOURN_PRODUCT_AVAILABILITY. - New: Add hidden option FOURN_PRODUCT_AVAILABILITY.
- New: task #11123: Add best supplier price. - New: task #11123: Add best supplier price.
- New: Enhancement in styles. - New: Enhancement in styles.
- New: Can conciliate several lines in one operation.
- New: task #11289 : Modify third party accountancy code generator aquarium. - New: task #11289 : Modify third party accountancy code generator aquarium.
- New: task #10606 : more comprehensive message error. - New: task #10606 : more comprehensive message error.
- New: task #11278 : Option into point of sale module to add services in list. - New: task #11278 : Option into point of sale module to add services in list.
......
...@@ -189,8 +189,11 @@ class Account extends CommonObject ...@@ -189,8 +189,11 @@ class Account extends CommonObject
$sql = "SELECT fk_bank, url_id, url, label, type"; $sql = "SELECT fk_bank, url_id, url, label, type";
$sql.= " FROM ".MAIN_DB_PREFIX."bank_url"; $sql.= " FROM ".MAIN_DB_PREFIX."bank_url";
if ($fk_bank > 0) { $sql.= " WHERE fk_bank = ".$fk_bank; } if ($fk_bank > 0) {
else { $sql.= " WHERE url_id = ".$url_id." AND type = '".$type."'"; } $sql.= " WHERE fk_bank = ".$fk_bank;
}
else { $sql.= " WHERE url_id = ".$url_id." AND type = '".$type."'";
}
$sql.= " ORDER BY type, label"; $sql.= " ORDER BY type, label";
dol_syslog(get_class($this)."::get_url sql=".$sql); dol_syslog(get_class($this)."::get_url sql=".$sql);
...@@ -780,7 +783,8 @@ class Account extends CommonObject ...@@ -780,7 +783,8 @@ class Account extends CommonObject
/** /**
* Return current sold * Return current sold
* @param option 1=Exclude future operation date (this is to exclude input made in advance and have real account sold) *
* @param int $option 1=Exclude future operation date (this is to exclude input made in advance and have real account sold)
* @return int Current sold (value date <= today) * @return int Current sold (value date <= today)
*/ */
function solde($option=0) function solde($option=0)
...@@ -803,61 +807,11 @@ class Account extends CommonObject ...@@ -803,61 +807,11 @@ class Account extends CommonObject
} }
} }
/**
* @param rowid
* @param sign 1 or -1
*/
function datev_change($rowid,$sign=1)
{
$sql = "SELECT datev FROM ".MAIN_DB_PREFIX."bank WHERE rowid = ".$rowid;
$resql = $this->db->query($sql);
if ($resql)
{
$obj=$this->db->fetch_object($resql);
$newdate=$this->db->jdate($obj->datev)+(3600*24*$sign);
$sql = "UPDATE ".MAIN_DB_PREFIX."bank SET ";
$sql.= " datev = '".$this->db->idate($newdate)."'";
$sql.= " WHERE rowid = ".$rowid;
$result = $this->db->query($sql);
if ($result)
{
if ($this->db->affected_rows($result))
{
return 1;
}
}
else
{
dol_print_error($this->db);
return 0;
}
}
else dol_print_error($this->db);
return 0;
}
/**
* @param rowid
*/
function datev_next($rowid)
{
return $this->datev_change($rowid,1);
}
/**
* @param rowid
*/
function datev_previous($rowid)
{
return $this->datev_change($rowid,-1);
}
/** /**
* Load indicators for dashboard (this->nbtodo and this->nbtodolate) * Load indicators for dashboard (this->nbtodo and this->nbtodolate)
* @param user Objet user *
* @param filteraccountid To get info for a particular account id * @param User $user Objet user
* @param int $filteraccountid To get info for a particular account id
* @return int <0 if KO, 0=Nothing to show, >0 if OK * @return int <0 if KO, 0=Nothing to show, >0 if OK
*/ */
function load_board($user,$filteraccountid=0) function load_board($user,$filteraccountid=0)
...@@ -1067,16 +1021,13 @@ class AccountLine extends CommonObject ...@@ -1067,16 +1021,13 @@ class AccountLine extends CommonObject
/** /**
* Constructeur * Constructor
*
* @param DoliDB $db Database handler
*/ */
function AccountLine($DB, $rowid=0) function AccountLine($db)
{ {
global $langs; $this->db = $db;
$this->db = $DB;
$this->rowid = $rowid;
return 1;
} }
/** /**
...@@ -1152,6 +1103,7 @@ class AccountLine extends CommonObject ...@@ -1152,6 +1103,7 @@ class AccountLine extends CommonObject
/** /**
* Delete transaction bank line record * Delete transaction bank line record
*
* @param user User object that delete * @param user User object that delete
* @return int <0 if KO, >0 if OK * @return int <0 if KO, >0 if OK
*/ */
...@@ -1200,6 +1152,7 @@ class AccountLine extends CommonObject ...@@ -1200,6 +1152,7 @@ class AccountLine extends CommonObject
/** /**
* Delete bank line records * Delete bank line records
*
* @param user User object that delete * @param user User object that delete
* @return int <0 if KO, >0 if OK * @return int <0 if KO, >0 if OK
*/ */
...@@ -1236,6 +1189,7 @@ class AccountLine extends CommonObject ...@@ -1236,6 +1189,7 @@ class AccountLine extends CommonObject
/** /**
* Update bank account record in database * Update bank account record in database
*
* @param user Object user making update * @param user Object user making update
* @param notrigger 0=Disable all triggers * @param notrigger 0=Disable all triggers
* @return int <0 if KO, >0 if OK * @return int <0 if KO, >0 if OK
...@@ -1269,6 +1223,7 @@ class AccountLine extends CommonObject ...@@ -1269,6 +1223,7 @@ class AccountLine extends CommonObject
/** /**
* Update conciliation field * Update conciliation field
*
* @param user Objet user making update * @param user Objet user making update
* @param cat Category id * @param cat Category id
* @return int <0 if KO, >0 if OK * @return int <0 if KO, >0 if OK
...@@ -1315,8 +1270,71 @@ class AccountLine extends CommonObject ...@@ -1315,8 +1270,71 @@ class AccountLine extends CommonObject
} }
} }
/**
* Increase/decrease value date of a rowid
*
* @param int $rowid
* @param int sign 1 or -1
* @return int >0 if OK, 0 if KO
*/
function datev_change($rowid,$sign=1)
{
$sql = "SELECT datev FROM ".MAIN_DB_PREFIX."bank WHERE rowid = ".$rowid;
$resql = $this->db->query($sql);
if ($resql)
{
$obj=$this->db->fetch_object($resql);
$newdate=$this->db->jdate($obj->datev)+(3600*24*$sign);
$sql = "UPDATE ".MAIN_DB_PREFIX."bank SET";
$sql.= " datev = '".$this->db->idate($newdate)."'";
$sql.= " WHERE rowid = ".$rowid;
$result = $this->db->query($sql);
if ($result)
{
if ($this->db->affected_rows($result))
{
return 1;
}
}
else
{
dol_print_error($this->db);
return 0;
}
}
else dol_print_error($this->db);
return 0;
}
/**
* Increase value date of a rowid
*
* @param int $rowid Id of line to change
* @return int >0 if OK, 0 if KO
*/
function datev_next($rowid)
{
return $this->datev_change($rowid,1);
}
/**
* Decrease value date of a rowid
*
* @param int $rowid Id of line to change
* @return int >0 if OK, 0 if KO
*/
function datev_previous($rowid)
{
return $this->datev_change($rowid,-1);
}
/** /**
* Charge les informations d'ordre info dans l'objet * Charge les informations d'ordre info dans l'objet
*
* @param rowid Id of object * @param rowid Id of object
*/ */
function info($rowid) function info($rowid)
...@@ -1361,6 +1379,7 @@ class AccountLine extends CommonObject ...@@ -1361,6 +1379,7 @@ class AccountLine extends CommonObject
/** /**
* Renvoie nom clicable (avec eventuellement le picto) * Renvoie nom clicable (avec eventuellement le picto)
*
* @param withpicto 0=Pas de picto, 1=Inclut le picto dans le lien, 2=Picto seul * @param withpicto 0=Pas de picto, 1=Inclut le picto dans le lien, 2=Picto seul
* @param maxlen Longueur max libelle * @param maxlen Longueur max libelle
* @param option Option ('showall') * @param option Option ('showall')
......
...@@ -25,9 +25,9 @@ ...@@ -25,9 +25,9 @@
*/ */
require("./pre.inc.php"); require("./pre.inc.php");
require_once(DOL_DOCUMENT_ROOT."/compta/bank/class/account.class.php");
if (! $user->rights->banque->lire && ! $user->rights->banque->consolidate) if (! $user->rights->banque->lire && ! $user->rights->banque->consolidate) accessforbidden();
accessforbidden();
$langs->load("banks"); $langs->load("banks");
$langs->load("compta"); $langs->load("compta");
...@@ -48,16 +48,16 @@ $form = new Form($db); ...@@ -48,16 +48,16 @@ $form = new Form($db);
* Actions * Actions
*/ */
if ($user->rights->banque->consolidate && $_GET["action"] == 'dvnext') if ($user->rights->banque->consolidate && $action == 'dvnext')
{ {
$ac = new Account($db); $al = new AccountLine($db);
$ac->datev_next($_GET["rowid"]); $al->datev_next($_GET["rowid"]);
} }
if ($user->rights->banque->consolidate && $_GET["action"] == 'dvprev') if ($user->rights->banque->consolidate && $action == 'dvprev')
{ {
$ac = new Account($db); $al = new AccountLine($db);
$ac->datev_previous($_GET["rowid"]); $al->datev_previous($_GET["rowid"]);
} }
if ($action == 'confirm_delete_categ' && $confirm == "yes" && $user->rights->banque->modifier) if ($action == 'confirm_delete_categ' && $confirm == "yes" && $user->rights->banque->modifier)
......
...@@ -43,18 +43,6 @@ if (! $user->rights->banque->consolidate) accessforbidden(); ...@@ -43,18 +43,6 @@ if (! $user->rights->banque->consolidate) accessforbidden();
* Actions * Actions
*/ */
if (($user->rights->banque->modifier || $user->rights->banque->consolidate) && $_GET["action"] == 'dvnext')
{
$ac = new Account($db);
$ac->datev_next($_GET["rowid"]);
}
if (($user->rights->banque->modifier || $user->rights->banque->consolidate) && $_GET["action"] == 'dvprev')
{
$ac = new Account($db);
$ac->datev_previous($_GET["rowid"]);
}
// Conciliation // Conciliation
if ($user->rights->banque->consolidate && $_POST["action"] == 'rappro') if ($user->rights->banque->consolidate && $_POST["action"] == 'rappro')
{ {
...@@ -64,11 +52,20 @@ if ($user->rights->banque->consolidate && $_POST["action"] == 'rappro') ...@@ -64,11 +52,20 @@ if ($user->rights->banque->consolidate && $_POST["action"] == 'rappro')
if ($num_releve) if ($num_releve)
{ {
$bankline=new AccountLine($db); $bankline=new AccountLine($db);
$result=$bankline->fetch($_POST["rowid"]);
$bankline->num_releve=$_POST["num_releve"];
if (isset($_POST["rowid"]) && is_array($_POST["rowid"]))
{
foreach($_POST["rowid"] as $row)
{
if($row > 0)
{
$result=$bankline->fetch($row);
$bankline->num_releve=$num_releve; //$_POST["num_releve"];
$result=$bankline->update_conciliation($user,$_POST["cat"]); $result=$bankline->update_conciliation($user,$_POST["cat"]);
if ($result < 0) $mesg=$bankline->error; if ($result < 0) $mesg.=$bankline->error;
}
}
}
} }
else else
{ {
...@@ -92,21 +89,26 @@ if ($_GET["action"] == 'del') ...@@ -92,21 +89,26 @@ if ($_GET["action"] == 'del')
} }
// Charge categories // Load bank groups
$sql = "SELECT rowid, label FROM ".MAIN_DB_PREFIX."bank_categ ORDER BY label"; $sql = "SELECT rowid, label FROM ".MAIN_DB_PREFIX."bank_categ ORDER BY label";
$resql = $db->query($sql); $resql = $db->query($sql);
$options=""; $options="";
if ($resql) { if ($resql)
{
$var=True; $var=True;
$num = $db->num_rows($resql); $num = $db->num_rows($resql);
if ($num > 0) $options .= '<option value="0"'.(GETPOST('cat')?'':' selected="true"').'>&nbsp;</option>';
$i = 0; $i = 0;
while ($i < $num) { while ($i < $num)
if ($options == "") { $options = "<option value=\"0\" selected=\"true\">&nbsp;</option>"; } {
$obj = $db->fetch_object($resql); $obj = $db->fetch_object($resql);
$options .= "<option value=\"$obj->rowid\">$obj->label</option>\n"; $i++; $options .= '<option value="'.$obj->rowid.'"'.(GETPOST('cat')==$obj->rowid?' selected="true"':'').'>'.$obj->label.'</option>'."\n";
$i++;
} }
$db->free($resql); $db->free($resql);
//print $options;
} }
else dol_print_error($db);
/* /*
...@@ -135,6 +137,26 @@ $sql.= " WHERE rappro=0 AND fk_account=".$_GET["account"]; ...@@ -135,6 +137,26 @@ $sql.= " WHERE rappro=0 AND fk_account=".$_GET["account"];
$sql.= " ORDER BY dateo ASC"; $sql.= " ORDER BY dateo ASC";
$sql.= " LIMIT 1000"; // Limit to avoid page overload $sql.= " LIMIT 1000"; // Limit to avoid page overload
/// ajax adjust value date
print '
<script type="text/javascript">
$(function() {
$("a.ajax").each(function(){
var current = $(this);
current.click(function()
{
$.get("'.DOL_URL_ROOT.'/core/ajax/bankconciliate.php?"+current.attr("href").split("?")[1], function(data)
{
current.parent().prev().replaceWith(data);
});
return false;
});
});
});
</script>
';
$resql = $db->query($sql); $resql = $db->query($sql);
if ($resql) if ($resql)
{ {
...@@ -168,7 +190,6 @@ if ($resql) ...@@ -168,7 +190,6 @@ if ($resql)
} }
if ($numr >= $nbmax) $liste="... &nbsp; ".$liste; if ($numr >= $nbmax) $liste="... &nbsp; ".$liste;
print $liste; print $liste;
if ($numr > 0) print '<br><br>'; if ($numr > 0) print '<br><br>';
else print '<b>'.$langs->trans("None").'</b><br><br>'; else print '<b>'.$langs->trans("None").'</b><br><br>';
} }
...@@ -177,31 +198,49 @@ if ($resql) ...@@ -177,31 +198,49 @@ if ($resql)
dol_print_error($db); dol_print_error($db);
} }
print '<form method="post" action="rappro.php?account='.$_GET["account"].'">';
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
print "<input type=\"hidden\" name=\"action\" value=\"rappro\">";
print "<input type=\"hidden\" name=\"account\" value=\"".$_GET["account"]."\">";
print $langs->trans("InputReceiptNumber").': ';
print '<input class="flat" name="num_releve" type="text" value="'.(GETPOST('num_releve')?GETPOST('num_releve'):$objp->num_releve).'" size="10">';
print '<br>';
if ($options)
{
print $langs->trans("EventualyAddCategory").': <select class="flat" name="cat">'.$options.'</select><br>';
}
print $langs->trans("ThenCheckLinesAndConciliate").' ';
print "<input class=\"button\" type=\"submit\" value=\"".$langs->trans("Conciliate")."\"><br>";
print '<br>';
print '<table class="liste" width="100%">'; print '<table class="liste" width="100%">';
print "<tr class=\"liste_titre\">\n"; print '<tr class="liste_titre">'."\n";
print '<td align="center">'.$langs->trans("DateOperationShort").'</td>'; print '<td align="center">'.$langs->trans("DateOperationShort").'</td>';
print '<td align="center">'.$langs->trans("DateValueShort").'</td>'; print '<td align="center">'.$langs->trans("DateValueShort").'</td>';
print '<td>'.$langs->trans("Type").'</td>'; print '<td>'.$langs->trans("Type").'</td>';
print '<td>'.$langs->trans("Description").'</td>'; print '<td>'.$langs->trans("Description").'</td>';
print '<td align="right" width="60" nowrap>'.$langs->trans("Debit").'</td>'; print '<td align="right" width="60" nowrap="nowrap">'.$langs->trans("Debit").'</td>';
print '<td align="right" width="60" nowrap>'.$langs->trans("Credit").'</td>'; print '<td align="right" width="60" nowrap="nowrap">'.$langs->trans("Credit").'</td>';
print '<td align="center" width="40">'.$langs->trans("Action").'</td>'; print '<td align="center" width="80">'.$langs->trans("Action").'</td>';
print '<td align="center">'.$langs->trans("AccountStatement").'<br>(Ex: YYYYMM)</td>'; print '<td align="center" width="60" nowrap="nowrap">'.$langs->trans("ToConciliate").'</td>';
print "</tr>\n"; print "</tr>\n";
$i = 0; $i = 0;
while ($i < $num) while ($i < $num)
{ {
$objp = $db->fetch_object($resql); $objp = $db->fetch_object($resql);
$var=!$var; $var=!$var;
print "<tr $bc[$var]>"; print "<tr ".$bc[$var].">";
print '<form method="post" action="rappro.php?account='.$_GET["account"].'">'; // print '<form method="post" action="rappro.php?account='.$_GET["account"].'">';
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">'; // print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
print "<input type=\"hidden\" name=\"action\" value=\"rappro\">";
print "<input type=\"hidden\" name=\"account\" value=\"".$_GET["account"]."\">"; // print "<input type=\"hidden\" name=\"rowid\" value=\"".$objp->rowid."\">";
print "<input type=\"hidden\" name=\"rowid\" value=\"".$objp->rowid."\">";
// Date op // Date op
print '<td align="center" nowrap="nowrap">'.dol_print_date($db->jdate($objp->do),"day").'</td>'; print '<td align="center" nowrap="nowrap">'.dol_print_date($db->jdate($objp->do),"day").'</td>';
...@@ -210,12 +249,12 @@ if ($resql) ...@@ -210,12 +249,12 @@ if ($resql)
if (! $objp->rappro && ($user->rights->banque->modifier || $user->rights->banque->consolidate)) if (! $objp->rappro && ($user->rights->banque->modifier || $user->rights->banque->consolidate))
{ {
print '<td align="center" nowrap="nowrap">'; print '<td align="center" nowrap="nowrap">';
print dol_print_date($db->jdate($objp->dv),"day"); print '<span id="datevalue_'.$objp->rowid.'">'.dol_print_date($db->jdate($objp->dv),"day")."</span>";
print ' &nbsp; '; print ' <span>&nbsp; ';
print '<a href="'.$_SERVER['PHP_SELF'].'?action=dvprev&amp;account='.$_GET["account"].'&amp;rowid='.$objp->rowid.'">'; print '<a class="ajax" href="'.$_SERVER['PHP_SELF'].'?action=dvprev&amp;account='.$_GET["account"].'&amp;rowid='.$objp->rowid.'">';
print img_edit_remove() . "</a> "; print img_edit_remove() . "</a> ";
print '<a href="'.$_SERVER['PHP_SELF'].'?action=dvnext&amp;account='.$_GET["account"].'&amp;rowid='.$objp->rowid.'">'; print '<a class="ajax" href="'.$_SERVER['PHP_SELF'].'?action=dvnext&amp;account='.$_GET["account"].'&amp;rowid='.$objp->rowid.'">';
print img_edit_add() ."</a>"; print img_edit_add() ."</a></span>";
print '</td>'; print '</td>';
} }
else else
...@@ -362,15 +401,17 @@ if ($resql) ...@@ -362,15 +401,17 @@ if ($resql)
// Affiche zone saisie releve + bouton "Rapprocher" // Affiche zone saisie releve + bouton "Rapprocher"
if ($db->jdate($objp->do) <= $now) if ($db->jdate($objp->do) <= $now)
{ {
print '<td align="center" nowrap="nowrap">'; print '<td align="center" nowrap="nowrap">';
print '<input class="flat" name="num_releve" type="text" value="'.$objp->num_releve.'" size="8">'; print '<input class="flat" name="rowid[]" type="checkbox" value="'.$objp->rowid.'" size="1">';
print ' &nbsp; '; // print '<input class="flat" name="num_releve" type="text" value="'.$objp->num_releve.'" size="8">';
print "<input class=\"button\" type=\"submit\" value=\"".$langs->trans("Conciliate")."\">"; // print ' &nbsp; ';
if ($options) // print "<input class=\"button\" type=\"submit\" value=\"".$langs->trans("Conciliate")."\">";
{ // if ($options)
print "<br><select class=\"flat\" name=\"cat\">$options"; // {
print "</select>"; // print "<br><select class=\"flat\" name=\"cat\">$options";
} // print "</select>";
// }
print "</td>"; print "</td>";
} }
else else
...@@ -381,23 +422,26 @@ if ($resql) ...@@ -381,23 +422,26 @@ if ($resql)
} }
print "</tr>\n"; print "</tr>\n";
print "</form>\n";
$i++; $i++;
} }
$db->free($resql); $db->free($resql);
print "</form>\n";
if ($num != 0) if ($num != 0)
{ {
print "</table><br>\n"; print "</table><br>\n";
} }
} }
else else
{ {
dol_print_error($db); dol_print_error($db);
} }
$db->close();
llxFooter(); llxFooter();
$db->close();
?> ?>
...@@ -26,6 +26,8 @@ ...@@ -26,6 +26,8 @@
require("./pre.inc.php"); require("./pre.inc.php");
require_once(DOL_DOCUMENT_ROOT."/core/lib/bank.lib.php"); require_once(DOL_DOCUMENT_ROOT."/core/lib/bank.lib.php");
$action=GETPOST('action');
$langs->load("companies"); $langs->load("companies");
$langs->load("banks"); $langs->load("banks");
$langs->load("bills"); $langs->load("bills");
...@@ -39,16 +41,16 @@ $fieldid = isset($_GET["ref"])?'ref':'rowid'; ...@@ -39,16 +41,16 @@ $fieldid = isset($_GET["ref"])?'ref':'rowid';
if ($user->societe_id) $socid=$user->societe_id; if ($user->societe_id) $socid=$user->societe_id;
$result=restrictedArea($user,'banque',$id,'bank_account','','',$fieldid); $result=restrictedArea($user,'banque',$id,'bank_account','','',$fieldid);
if ($_GET["action"] == 'dvnext') if ($user->rights->banque->consolidate && $action == 'dvnext')
{ {
$ac = new Account($db); $al = new AccountLine($db);
$ac->datev_next($_GET["dvid"]); $al->datev_next($_GET["dvid"]);
} }
if ($_GET["action"] == 'dvprev') if ($user->rights->banque->consolidate && $action == 'dvprev')
{ {
$ac = new Account($db); $al = new AccountLine($db);
$ac->datev_previous($_GET["dvid"]); $al->datev_previous($_GET["dvid"]);
} }
......
<?php
/* Copyright (C) 2012 Laurent Destailleur <eldy@users.sourceforge.net>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/**
* \file htdocs/core/ajax/bankconciliate.php
* \brief File to set data for bank concilation
*/
if (! defined('NOTOKENRENEWAL')) define('NOTOKENRENEWAL','1'); // Disables token renewal
if (! defined('NOREQUIREMENU')) define('NOREQUIREMENU','1');
if (! defined('NOREQUIREHTML')) define('NOREQUIREHTML','1');
if (! defined('NOREQUIREAJAX')) define('NOREQUIREAJAX','1');
if (! defined('NOREQUIRESOC')) define('NOREQUIRESOC','1');
//if (! defined('NOREQUIRETRAN')) define('NOREQUIRETRAN','1'); // Required to knwo date format for dol_print_date
require('../../main.inc.php');
require_once(DOL_DOCUMENT_ROOT."/core/lib/admin.lib.php");
require_once(DOL_DOCUMENT_ROOT."/compta/bank/class/account.class.php");
$action=GETPOST('action');
/*
* View
*/
// Ajout directives pour resoudre bug IE
//header('Cache-Control: Public, must-revalidate');
//header('Pragma: public');
//top_htmlhead("", "", 1); // Replaced with top_httphead. An ajax page does not need html header.
top_httphead();
//print '<!-- Ajax page called with url '.$_SERVER["PHP_SELF"].'?'.$_SERVER["QUERY_STRING"].' -->'."\n";
if (($user->rights->banque->modifier || $user->rights->banque->consolidate) && $action == 'dvnext')
{
// Increase date
$al =new AccountLine($db);
$al->datev_next($_GET["rowid"]);
$al->fetch($_GET["rowid"]);
print '<span>'.dol_print_date($db->jdate($al->datev),"day").'</span>';
exit;
}
if (($user->rights->banque->modifier || $user->rights->banque->consolidate) && $action == 'dvprev')
{
// Decrease date
$al =new AccountLine($db);
$al->datev_previous($_GET["rowid"]);
$al->fetch($_GET["rowid"]);
print '<span>'.dol_print_date($db->jdate($al->datev),"day").'</span>';
exit;
}
?>
...@@ -143,3 +143,7 @@ BackToAccount=Retour au compte ...@@ -143,3 +143,7 @@ BackToAccount=Retour au compte
ShowAllAccounts=Afficher pour tous les comptes ShowAllAccounts=Afficher pour tous les comptes
FutureTransaction=Transaction future. Pas moyen de concilier. FutureTransaction=Transaction future. Pas moyen de concilier.
SelectChequeTransactionAndGenerate=Sélectionner/filtrer les chèques à inclure dans le bordereau de remise et cliquer sur "Créer". SelectChequeTransactionAndGenerate=Sélectionner/filtrer les chèques à inclure dans le bordereau de remise et cliquer sur "Créer".
InputReceiptNumber=Saisissez le relevé bancaire concerné par le rapprochement. Utilisez une valeur numérique triable (par exemple YYYYMM)
EventualyAddCategory=Eventuellement, saisissez une catégorie dans laquelle classer les écritures
ToConciliate=A rapprocher ?
ThenCheckLinesAndConciliate=Ensuite, cochez les lignes présentes sur le relevé et cliquez sur
\ No newline at end of file
...@@ -62,7 +62,7 @@ ErrorLDAPSetupNotComplete=Le matching Dolibarr-LDAP est incomplet. ...@@ -62,7 +62,7 @@ ErrorLDAPSetupNotComplete=Le matching Dolibarr-LDAP est incomplet.
ErrorLDAPMakeManualTest=Un fichier .ldif a été généré dans le répertoire %s. Essayez de charger ce fichier en manuel depuis la ligne de commande pour plus de détail sur l'erreur. ErrorLDAPMakeManualTest=Un fichier .ldif a été généré dans le répertoire %s. Essayez de charger ce fichier en manuel depuis la ligne de commande pour plus de détail sur l'erreur.
ErrorCantSaveADoneUserWithZeroPercentage=Impossible de sauver une action à l'état non commencé avec un utilisateur défini comme ayant fait l'action. ErrorCantSaveADoneUserWithZeroPercentage=Impossible de sauver une action à l'état non commencé avec un utilisateur défini comme ayant fait l'action.
ErrorRefAlreadyExists=La référence utilisée pour la création existe déjà ErrorRefAlreadyExists=La référence utilisée pour la création existe déjà
ErrorPleaseTypeBankTransactionReportName=Veuillez saisir le nom de relevé bancaire sur lequel l'écriture est constatée (Format AAAAMM ou AAAMMJJ) ErrorPleaseTypeBankTransactionReportName=Veuillez saisir le nom de relevé bancaire sur lequel l'écriture est constatée (Format AAAAMM de préférence ou AAAAMMJJ)
ErrorRecordHasChildren=Impossible de supprimer l'enregistrement car il possède des enregistrements fils. ErrorRecordHasChildren=Impossible de supprimer l'enregistrement car il possède des enregistrements fils.
ErrorModuleRequireJavascript=Le javascript ne doit pas être désactivé pour que cette fonctionnalité soit utilisable. Pour activer/désactiver l'utilisation de javascript, allez dans le menu Accueil->Configuration->Affichage. ErrorModuleRequireJavascript=Le javascript ne doit pas être désactivé pour que cette fonctionnalité soit utilisable. Pour activer/désactiver l'utilisation de javascript, allez dans le menu Accueil->Configuration->Affichage.
ErrorPasswordsMustMatch=Les 2 mots de passe saisis doivent correspondre ErrorPasswordsMustMatch=Les 2 mots de passe saisis doivent correspondre
......
...@@ -175,7 +175,7 @@ Info=Suivi ...@@ -175,7 +175,7 @@ Info=Suivi
Family=Famille Family=Famille
Description=Description Description=Description
Designation=Désignation Designation=Désignation
Action=Evénement Action=Action
Model=Modèle Model=Modèle
DefaultModel=Modèle par défaut DefaultModel=Modèle par défaut
About=À propos About=À propos
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment