/[dolibarr]/dolibarr/htdocs/telephonie/distributeurs/fiche.php
ViewVC logotype

Diff of /dolibarr/htdocs/telephonie/distributeurs/fiche.php

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.2 by rodolphe, Tue Jun 21 15:41:50 2005 UTC revision 1.3 by rodolphe, Mon Sep 5 14:37:15 2005 UTC
# Line 44  if($_POST["action"] == 'add') Line 44  if($_POST["action"] == 'add')
44      }      }
45  }  }
46    
47  if($_POST["action"] == 'add_commercial')  if($_POST["action"] == 'add_commercial' && $user->admin)
48  {  {
49    $commercial->nom = $_POST["nom"];    $commercial->nom = $_POST["nom"];
50    $commercial->prenom = $_POST["prenom"];    $commercial->prenom = $_POST["prenom"];
51    $commercial->distri = $_GET["distri"];    $commercial->distri = $_GET["distri"];
52      $commercial->email = $_POST["email"];
53        
54    if ($commercial->create() <> 0)    if ($commercial->create() <> 0)
55      {      {
# Line 90  if ($_GET["action"] == 'create_commercia Line 91  if ($_GET["action"] == 'create_commercia
91    print '<table class="noborder" width="100%" cellspacing="0" cellpadding="4">';    print '<table class="noborder" width="100%" cellspacing="0" cellpadding="4">';
92    
93    print '<tr><td width="20%">Prénom</td>';    print '<tr><td width="20%">Prénom</td>';
94    print '<td><input type="text" size="30" name="prenom" value="'.$commercial->prenom.'"></td>';    print '<td><input type="text" size="20" maxlength="20" name="prenom" value="'.$commercial->prenom.'"></td>';
95    print '<td>'.$commercial->error_string["prenom"].'</td></tr>';    print '<td>'.$commercial->error_string["prenom"].'</td></tr>';
96    print '<tr><td width="20%">Nom</td>';    print '<tr><td width="20%">Nom</td>';
97    print '<td><input type="text" size="30" name="nom" value="'.$commercial->nom.'"></td>';    print '<td><input type="text" size="30" maxlength="30" name="nom" value="'.$commercial->nom.'"></td>';
98    print '<td>'.$commercial->error_string["nom"].'</td></tr>';    print '<td>'.$commercial->error_string["nom"].'</td></tr>';
99    
100      print '<tr><td width="20%">Email</td>';
101      print '<td><input type="text" size="50" maxlength="70" name="email" value="'.$commercial->email.'"></td>';
102      print '<td>'.$commercial->error_string["email"].'</td></tr>';
103    
104    print '<tr><td colspan="2"><input type="submit"></td></tr>';    print '<tr><td colspan="2"><input type="submit"></td></tr>';
105    
106    print '</table><br />';    print '</table><br />';

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.3

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26