Mise à jour des permissions
This commit is contained in:
parent
e1cf783a85
commit
45327fe709
@ -1,5 +1,5 @@
|
|||||||
<?php
|
<?php
|
||||||
/* Copyright (C) 2001-2002 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
/* Copyright (C) 2001-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||||
* Copyright (C) 2004 Laurent Destailleur <eldy@users.sourceforge.net>
|
* Copyright (C) 2004 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
@ -25,8 +25,7 @@ require("./bank.lib.php");
|
|||||||
|
|
||||||
$user->getrights('compta');
|
$user->getrights('compta');
|
||||||
|
|
||||||
if (!$user->admin && !$user->rights->banque->lire)
|
if (!$user->rights->banque->lire) accessforbidden();
|
||||||
accessforbidden();
|
|
||||||
|
|
||||||
llxHeader();
|
llxHeader();
|
||||||
|
|
||||||
@ -36,7 +35,6 @@ $offset = $conf->liste_limit * $page ;
|
|||||||
$pageprev = $page - 1;
|
$pageprev = $page - 1;
|
||||||
$pagenext = $page + 1;
|
$pagenext = $page + 1;
|
||||||
|
|
||||||
|
|
||||||
print_barre_liste("Transactions BPLC", $page, "bplc.php");
|
print_barre_liste("Transactions BPLC", $page, "bplc.php");
|
||||||
|
|
||||||
print "<table class=\"noborder\" width=\"100%\" cellspacing=\"0\" cellpadding=\"2\">";
|
print "<table class=\"noborder\" width=\"100%\" cellspacing=\"0\" cellpadding=\"2\">";
|
||||||
@ -59,16 +57,18 @@ $sql = "SELECT ipclient,
|
|||||||
|
|
||||||
$sql .= " FROM ".MAIN_DB_PREFIX."transaction_bplc";
|
$sql .= " FROM ".MAIN_DB_PREFIX."transaction_bplc";
|
||||||
|
|
||||||
$result = $db->query($sql);
|
$resql = $db->query($sql);
|
||||||
if ($result) {
|
if ($resql)
|
||||||
|
{
|
||||||
$var=True;
|
$var=True;
|
||||||
$num = $db->num_rows();
|
$num = $db->num_rows($resql);
|
||||||
$i = 0; $total = 0;
|
$i = 0; $total = 0;
|
||||||
|
|
||||||
$sep = 0;
|
$sep = 0;
|
||||||
|
|
||||||
while ($i < $num) {
|
while ($i < $num)
|
||||||
$objp = $db->fetch_object($result);
|
{
|
||||||
|
$objp = $db->fetch_object($resql);
|
||||||
|
|
||||||
print "<tr $bc[1]>";
|
print "<tr $bc[1]>";
|
||||||
|
|
||||||
@ -87,12 +87,9 @@ if ($result) {
|
|||||||
print "<td>$objp->num_autorisation</td>";
|
print "<td>$objp->num_autorisation</td>";
|
||||||
print "<td>$objp->cle_acceptation</td>";
|
print "<td>$objp->cle_acceptation</td>";
|
||||||
print "<td>$objp->code_retour</td>";
|
print "<td>$objp->code_retour</td>";
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
$i++;
|
$i++;
|
||||||
}
|
}
|
||||||
$db->free();
|
$db->free($resql);
|
||||||
}
|
}
|
||||||
print "</table>";
|
print "</table>";
|
||||||
|
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
<?php
|
<?php
|
||||||
/* Copyright (C) 2001-2003 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
/* Copyright (C) 2001-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||||
* Copyright (C) 2003 Jean-Louis Bergamo <jlb@j1b.org>
|
* Copyright (C) 2003 Jean-Louis Bergamo <jlb@j1b.org>
|
||||||
* Copyright (C) 2004-2005 Laurent Destailleur <eldy@users.sourceforge.net>
|
* Copyright (C) 2004-2005 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
*
|
*
|
||||||
@ -31,12 +31,10 @@
|
|||||||
require_once("../../main.inc.php");
|
require_once("../../main.inc.php");
|
||||||
require_once(DOL_DOCUMENT_ROOT."/compta/bank/account.class.php");
|
require_once(DOL_DOCUMENT_ROOT."/compta/bank/account.class.php");
|
||||||
|
|
||||||
|
|
||||||
$langs->load("banks");
|
$langs->load("banks");
|
||||||
|
|
||||||
$user->getrights('banque');
|
$user->getrights('banque');
|
||||||
|
|
||||||
|
|
||||||
function llxHeader($head = "")
|
function llxHeader($head = "")
|
||||||
{
|
{
|
||||||
global $db, $user, $conf, $langs;
|
global $db, $user, $conf, $langs;
|
||||||
@ -44,7 +42,8 @@ function llxHeader($head = "")
|
|||||||
top_menu($head);
|
top_menu($head);
|
||||||
|
|
||||||
$menu = new Menu();
|
$menu = new Menu();
|
||||||
|
if ($user->rights->banque->lire)
|
||||||
|
{
|
||||||
$sql = "SELECT rowid, label, courant";
|
$sql = "SELECT rowid, label, courant";
|
||||||
$sql.= " FROM ".MAIN_DB_PREFIX."bank_account";
|
$sql.= " FROM ".MAIN_DB_PREFIX."bank_account";
|
||||||
$sql.= " WHERE clos = 0";
|
$sql.= " WHERE clos = 0";
|
||||||
@ -65,7 +64,7 @@ function llxHeader($head = "")
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
$db->free($resql);
|
$db->free($resql);
|
||||||
|
}
|
||||||
$menu->add(DOL_URL_ROOT."/compta/bank/index.php",$langs->trans("Bank"));
|
$menu->add(DOL_URL_ROOT."/compta/bank/index.php",$langs->trans("Bank"));
|
||||||
|
|
||||||
$menu->add_submenu(DOL_URL_ROOT."/compta/bank/search.php",$langs->trans("SearchTransaction"));
|
$menu->add_submenu(DOL_URL_ROOT."/compta/bank/search.php",$langs->trans("SearchTransaction"));
|
||||||
@ -88,8 +87,5 @@ function llxHeader($head = "")
|
|||||||
}
|
}
|
||||||
|
|
||||||
left_menu($menu->liste);
|
left_menu($menu->liste);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user