Suppression du PHP_SELF
This commit is contained in:
parent
a63ce971e5
commit
3f54dc26b4
@ -1,5 +1,5 @@
|
||||
<?PHP
|
||||
/* Copyright (C) 2003 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||
/* Copyright (C) 2003-2004 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||
*
|
||||
* 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
|
||||
@ -116,7 +116,7 @@ if ($id > 0)
|
||||
}
|
||||
else
|
||||
{
|
||||
echo '<a href="'.$PHP_SELF.'?id='.$propal->id.'&action=delete&urlfile='.urlencode($file).'">Supprimer</a>';
|
||||
echo '<a href="document.php?id='.$propal->id.'&action=delete&urlfile='.urlencode($file).'">Supprimer</a>';
|
||||
}
|
||||
print "</td></tr>\n";
|
||||
}
|
||||
|
||||
@ -40,7 +40,7 @@ require("../../propal.class.php");
|
||||
*/
|
||||
if ($user->societe_id > 0)
|
||||
{
|
||||
$action = '';
|
||||
unset($_GET["action"]);
|
||||
$socidp = $user->societe_id;
|
||||
}
|
||||
|
||||
@ -48,13 +48,12 @@ if ($user->societe_id > 0)
|
||||
/* Actions */
|
||||
/******************************************************************************/
|
||||
|
||||
if ($_GET["valid"] == 1 && $user->rights->propale->valider)
|
||||
if ($_POST["action"] == 'update' && $user->rights->propale->creer)
|
||||
{
|
||||
$propal = new Propal($db);
|
||||
$propal->fetch($_GET["propalid"]);
|
||||
$propal->update_price($_GET["propalid"]);
|
||||
propale_pdf_create($db, $_GET["propalid"], $propal->modelpdf);
|
||||
$propal->valid($user);
|
||||
$propal->update_note($_POST["note"]);
|
||||
|
||||
}
|
||||
|
||||
llxHeader();
|
||||
@ -113,7 +112,11 @@ if ($_GET["propalid"])
|
||||
|
||||
if ($_GET["action"] == 'edit')
|
||||
{
|
||||
print '<form method="post" action="note.php?propalid='.$propal->id.'">';
|
||||
print '<input type="hidden" name="action" value="update">';
|
||||
print '<tr><td valign="top" colspan="4"><textarea name="note" cols="80" rows="8">'.$propal->note."</textarea></td></tr>";
|
||||
print '<tr><td align="center" colspan="4"><input type="submit" value="Enregistrer"></td></tr>';
|
||||
print '</form>';
|
||||
}
|
||||
|
||||
|
||||
@ -128,7 +131,7 @@ if ($_GET["propalid"])
|
||||
|
||||
if ($user->rights->propale->creer && $_GET["action"] <> 'edit')
|
||||
{
|
||||
print "<a class=\"tabAction\" href=\"$PHP_SELF?propalid=$propal->id&action=edit\">Editer</a>";
|
||||
print "<a class=\"tabAction\" href=\"note.php?propalid=$propal->id&action=edit\">Editer</a>";
|
||||
}
|
||||
|
||||
print "</div>";
|
||||
|
||||
@ -117,13 +117,13 @@ if ($result)
|
||||
|
||||
$urladd="page=$page&stcomm=$stcomm";
|
||||
|
||||
print_barre_liste("Liste des prospects", $page, $PHP_SELF,'&stcomm='.$_GET["stcomm"],"","",'',$num);
|
||||
print_barre_liste("Liste des prospects", $page, "prospects.php",'&stcomm='.$_GET["stcomm"],"","",'',$num);
|
||||
|
||||
print '<div align="center">';
|
||||
|
||||
print "| <A href=\"$PHP_SELF?page=$pageprev&stcomm=$stcomm&begin=%25\">*</A>\n| ";
|
||||
print "| <A href=\"prospects.php?page=$pageprev&stcomm=$stcomm&begin=%25\">*</A>\n| ";
|
||||
for ($ij = 65 ; $ij < 91; $ij++) {
|
||||
print "<A href=\"$PHP_SELF?begin=" . chr($ij) . "&stcomm=$stcomm\" class=\"T3\">";
|
||||
print "<A href=\"prospects.php?begin=" . chr($ij) . "&stcomm=$stcomm\" class=\"T3\">";
|
||||
|
||||
if ($user->page_param["begin"] == chr($ij) )
|
||||
{
|
||||
@ -151,16 +151,16 @@ if ($result)
|
||||
print '<table class="noborder" width="100%" cellspacing="0" cellpadding="4">';
|
||||
print '<TR class="liste_titre">';
|
||||
print "<TD valign=\"center\">";
|
||||
print_liste_field_titre("Société",$PHP_SELF,"s.nom");
|
||||
print_liste_field_titre("Société","prospects.php","s.nom");
|
||||
print "</td><td>";
|
||||
print_liste_field_titre("Ville",$PHP_SELF,"s.ville");
|
||||
print_liste_field_titre("Ville","prospects.php","s.ville");
|
||||
print "</td>";
|
||||
print "<td align=\"center\">";
|
||||
print_liste_field_titre("Département",$PHP_SELF,"s.fk_departement");
|
||||
print_liste_field_titre("Département","prospects.php","s.fk_departement");
|
||||
print "</td><td>";
|
||||
print_liste_field_titre("Statut",$PHP_SELF,"s.fk_stcomm");
|
||||
print_liste_field_titre("Statut","prospects.php","s.fk_stcomm");
|
||||
print "</td><td>";
|
||||
print_liste_field_titre("Insertion",$PHP_SELF,"s.datec");
|
||||
print_liste_field_titre("Insertion","prospects.php","s.datec");
|
||||
print '</td><td colspan="4"> </td>';
|
||||
print "</TR>\n";
|
||||
$var=True;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user