$udat{SAMURAI_Perm_vars}{id_sistema} = @_[1];
##Conexion con la base
#TODO Cambiar los parametros de conexion segun corresponda.
- my $dbh = DBI->connect('dbi:mysql:dbname=samurai;host=bal747f',"intranet","intranet");
+
+ my $dbh = DBI->connect('dbi:mysql:dbname=samurai;host=localhost',"samurai","25fdd50c0e4d68");
##Obtengo los permisos de la base
$re = $dbh->prepare($sql);
$re->execute($udat{SAMURAI_Perm_vars}{login});
$udat{SAMURAI_Perm_vars}{observaciones} = '';
$sql = 'SELECT ps.observaciones AS observaciones FROM samurai.perm_sist AS ps WHERE ps.id_permiso = ? AND ps.id_sistema = ?';
#TODO cambiar los parametros de conexion segun corresponda
- my $dbh = DBI->connect('dbi:mysql:dbname=samurai;host=bal747f',"intranet","intranet");
+ my $dbh = DBI->connect('dbi:mysql:dbname=samurai;host=localhost',"samurai","25fdd50c0e4d68");
$re = $dbh->prepare($sql);
$re->execute($perm, $sistema);
while ($r = $re->fetchrow_hashref()) {
my $sql = "REPLACE INTO perfil_sist_usuario (login,id_perfil,id_sistema,responsable) VALUES ('$login',$id_perfil,$id_sistema,'$resp')";
##Conexion con la base
#TODO Cambiar los parametros de conexion segun corresponda.
- my $dbh = DBI->connect('dbi:mysql:dbname=samurai;host=bal747f',"intranet","intranet");
+ my $dbh = DBI->connect('dbi:mysql:dbname=samurai;host=localhost',"samurai","25fdd50c0e4d68");
my $result=$dbh->do($sql);
#Desconexion con la base
$dbh->disconnect;
my $sql = "DELETE FROM perfil_sist_usuario where (login='$login') AND (id_perfil=$id_perfil) AND (id_sistema=$id_sistema)";
##Conexion con la base
#TODO Cambiar los parametros de conexion segun corresponda.
- my $dbh = DBI->connect('dbi:mysql:dbname=samurai;host=bal747f',"intranet","intranet");
+ my $dbh = DBI->connect('dbi:mysql:dbname=samurai;host=localhost',"samurai","25fdd50c0e4d68");
my $result=$dbh->do($sql);
#Desconexion con la base
$dbh->disconnect;