Look: Modifications esthétiques mineures
This commit is contained in:
parent
0dee88b364
commit
7cae46ecfb
@ -29,10 +29,11 @@
|
|||||||
|
|
||||||
require("./pre.inc.php");
|
require("./pre.inc.php");
|
||||||
|
|
||||||
|
$langs->load("banks");
|
||||||
|
|
||||||
$user->getrights('compta');
|
$user->getrights('compta');
|
||||||
|
|
||||||
if (! $user->rights->banque->modifier)
|
if (! $user->rights->banque->modifier) accessforbidden();
|
||||||
accessforbidden();
|
|
||||||
|
|
||||||
|
|
||||||
llxHeader();
|
llxHeader();
|
||||||
@ -54,7 +55,6 @@ if ($_POST["action"] == 'rappro')
|
|||||||
$sql .= " WHERE rowid=".$_POST["rowid"];
|
$sql .= " WHERE rowid=".$_POST["rowid"];
|
||||||
|
|
||||||
$result = $db->query($sql);
|
$result = $db->query($sql);
|
||||||
|
|
||||||
if ($result) {
|
if ($result) {
|
||||||
if ($cat1 && $_POST["action"]) {
|
if ($cat1 && $_POST["action"]) {
|
||||||
$sql = "INSERT INTO ".MAIN_DB_PREFIX."bank_class (lineid, fk_categ) VALUES ($rowid, $cat1)";
|
$sql = "INSERT INTO ".MAIN_DB_PREFIX."bank_class (lineid, fk_categ) VALUES ($rowid, $cat1)";
|
||||||
@ -165,8 +165,8 @@ if ($result)
|
|||||||
print '<td>'.$langs->trans("Description").'</td>';
|
print '<td>'.$langs->trans("Description").'</td>';
|
||||||
print '<td align="right">'.$langs->trans("Debit").'</td>';
|
print '<td align="right">'.$langs->trans("Debit").'</td>';
|
||||||
print '<td align="right">'.$langs->trans("Credit").'</td>';
|
print '<td align="right">'.$langs->trans("Credit").'</td>';
|
||||||
print '<td align="center" width="100">'.$langs->trans("AccountStatement").'<br>(Ex: YYYYMM)</td>';
|
print '<td align="center" width="60">'.$langs->trans("Action").'</td>';
|
||||||
print '<td align="center" width="100" colspan="2">'.$langs->trans("Action").'</td>';
|
print '<td align="center" width="100" colspan="2">'.$langs->trans("AccountStatement").' (Ex: YYYYMM)</td>';
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -182,9 +182,9 @@ if ($result)
|
|||||||
print "<input type=\"hidden\" name=\"account\" value=\"".$_GET["account"]."\">";
|
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."\">";
|
||||||
|
|
||||||
print '<td>'.dolibarr_print_date($objp->do).'</td>';
|
print '<td nowrap>'.dolibarr_print_date($objp->do).'</td>';
|
||||||
print '<td>'.dolibarr_print_date($objp->dv).'</td>';
|
print '<td nowrap>'.dolibarr_print_date($objp->dv).'</td>';
|
||||||
print '<td>'.$objp->type.($objp->num_chq?' '.$objp->num_chq:'').'</td>';
|
print '<td nowrap>'.$objp->type.($objp->num_chq?' '.$objp->num_chq:'').'</td>';
|
||||||
print '<td>'.$objp->label.'</td>';
|
print '<td>'.$objp->label.'</td>';
|
||||||
|
|
||||||
if ($objp->amount < 0)
|
if ($objp->amount < 0)
|
||||||
@ -196,6 +196,40 @@ if ($result)
|
|||||||
print "<td> </td><td align=\"right\">".price($objp->amount)."</td>\n";
|
print "<td> </td><td align=\"right\">".price($objp->amount)."</td>\n";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ($objp->rappro)
|
||||||
|
{
|
||||||
|
// Si ligne déjà rapprochée, on affiche relevé.
|
||||||
|
print "<td align=\"center\"><a href=\"releve.php?num=$objp->num_releve&account=$acct->id\">$objp->num_releve</a></td>";
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// Si pas encore rapproché
|
||||||
|
if ($user->rights->banque->modifier)
|
||||||
|
{
|
||||||
|
print '<td align="center" width="30">';
|
||||||
|
|
||||||
|
print '<a href="'.DOL_URL_ROOT.'/compta/bank/ligne.php?rowid='.$objp->rowid.'&account='.$acct->id.'">';
|
||||||
|
print img_edit();
|
||||||
|
print '</a> ';
|
||||||
|
|
||||||
|
if ($objp->do <= mktime() ) {
|
||||||
|
print '<a href="'.DOL_URL_ROOT.'/compta/bank/rappro.php?action=del&rowid='.$objp->rowid.'&account='.$acct->id.'">';
|
||||||
|
print img_delete();
|
||||||
|
print "</a>";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
print " "; // On n'empeche la suppression car le raprochement ne pourra se faire qu'après la date passée et que l'écriture apparaissent bien sur le compte.
|
||||||
|
}
|
||||||
|
print "</td>";
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
print "<td align=\"center\"> </td>";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// Affiche bouton "Rapprocher"
|
||||||
if ($objp->do <= mktime() ) {
|
if ($objp->do <= mktime() ) {
|
||||||
print "<td align=\"center\">";
|
print "<td align=\"center\">";
|
||||||
print "<input class=\"flat\" name=\"num_releve\" type=\"text\" value=\"\" size=\"8\">";
|
print "<input class=\"flat\" name=\"num_releve\" type=\"text\" value=\"\" size=\"8\">";
|
||||||
@ -213,31 +247,6 @@ if ($result)
|
|||||||
print "</td>";
|
print "</td>";
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($objp->rappro)
|
|
||||||
{
|
|
||||||
print "<td align=\"center\"><a href=\"releve.php?num=$objp->num_releve&account=$acct->id\">$objp->num_releve</a></td>";
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
if ($user->rights->banque->modifier)
|
|
||||||
{
|
|
||||||
print '<td align="center" width="30">';
|
|
||||||
if ($objp->do <= mktime() ) {
|
|
||||||
print "<a href=\"rappro.php?action=del&rowid=$objp->rowid&account=$acct->id\">";
|
|
||||||
print img_delete();
|
|
||||||
print "</a>";
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
print " "; // On n'empeche la suppression car le raprochement ne pourra se faire qu'après la date passée et que l'écriture apparaissent bien sur le compte.
|
|
||||||
}
|
|
||||||
print "</td>";
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
print "<td align=\"center\"> </td>";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
print "</tr>";
|
print "</tr>";
|
||||||
|
|
||||||
print "</form>";
|
print "</form>";
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user