Commit 998c288c authored by Ayolo's avatar Ayolo

bleh

parent 38dbf16f
......@@ -95,6 +95,6 @@ foreach ($res as $line)
$conf .= "}\n";
//echo $conf;
$gene->generate_conf_from_string ($conf);
$gene->generate_conf_from_string (utf8_decode($conf));
$gene->generate ();
?>
\ No newline at end of file
?>
<?php
$topdir = "../";
require_once($topdir. "include/site.inc.php");
$site = new site ();
$req = new requete($site->db, "SELECT CONCAT(prenom_utl,' ',nom_utl) AS nom_utilisateur FROM utilisateurs WHERE ae_utl='1' ORDER by nom_utl");
$i = 0;
echo "<table>";
while( $row = $req->get_row() )
{
if($i == 0){echo "<tr>";}
echo "<td>".$row["nom_utilisateur"]."</td>";
if($i == 3){echo "</tr>"; $i = 0;}else{$i++;}
}
echo "</table>";
?>
<?php
$topdir = "../";
require_once($topdir. "include/site.inc.php");
require_once($topdir. "include/cts/sqltable.inc.php");
require_once ($topdir. "include/entities/asso.inc.php");
require_once ($topdir . "include/pdf/facture_pdf.inc.php");
$site = new site ();
$req = new requete($site->db, "SELECT " .
"`utilisateurs`.`id_utilisateur`,`utilisateurs`.`nom_utl` AS `nom_utilisateur`,`utilisateurs`.`prenom_utl` AS `prenom`, " .
"`cpt_vendu`.`quantite`, " .
"`cpt_vendu`.`prix_unit`/100 AS `prix_unit`, " .
"`cpt_vendu`.`prix_unit`*`cpt_vendu`.`quantite`/100 AS `total`," .
"`cpt_produits`.`nom_prod` " .
"FROM `cpt_vendu` " .
"INNER JOIN `cpt_produits` ON `cpt_produits`.`id_produit`=`cpt_vendu`.`id_produit` " .
"INNER JOIN `cpt_debitfacture` ON `cpt_debitfacture`.`id_facture` =`cpt_vendu`.`id_facture` " .
"INNER JOIN `utilisateurs` ON `utilisateurs`.`id_utilisateur`=`cpt_debitfacture`.`id_utilisateur_client` ".
"WHERE ".
"(`cpt_vendu`.`id_produit`='339' OR `cpt_vendu`.`id_produit`='340') " .
"ORDER BY `utilisateurs`.`nom_utl` ASC");
if (isset($_REQUEST['action']) && $_REQUEST['action']=="getpdf")
{
define('FPDF_FONTPATH', $topdir.'./font/');
$pdf=new FPDF();
$pdf->AliasNbPages();
$pdf->SetAutoPageBreak(false);
$pdf->AddPage();
$pdf->SetFont('Arial','B',14);
$pdf->Image($topdir."./images/Ae-blanc.jpg", 10, 10, 75);
$pdf->SetFont('Times','BI',22);
$pdf->Cell(0, 18, "Automne 2007",'','','R');
$pdf->Ln();
$pdf->SetFont('Arial','B',14);
$pdf->Cell('', 20, "Listing prvente EC3",'','','C');
$pdf->Ln();
$pdf->SetFont('Arial','B',11);
//Header
$w=array(50,50,60,20);
//Data
$fill=0;
$skip=57;
$height=0;
$page=1;
$breakpage = false;
while ($res = $req->get_row())
{
if(($skip + $height) > 255)
{
$breakpage = true;
$border = 'LRB';
}
else if($height == 0)
{
//Colors, line width and bold font
$pdf->SetFillColor(0,0,0);
$pdf->SetTextColor(255);
$pdf->SetDrawColor(128,128,128);
$pdf->SetLineWidth(.3);
$pdf->SetFont('','B');
$pdf->Cell($w[0],7,"Nom", 1, 0, 'L', 1);
$pdf->Cell($w[1],7,"Prnom", 1, 0, 'L', 1);
$pdf->Cell($w[2],7,"Produit", 1, 0, 'L', 1);
$pdf->Cell($w[3],7,"Quantit", 1, 0, 'L', 1);
$pdf->Ln();
//Color and font restoration
$pdf->SetFillColor(200,200,200);
$pdf->SetTextColor(0);
$pdf->SetFont('');
$height += 7;
$border = 'LR';
}
else
{
$border = 'LR';
$height += 6;
}
$pdf->Cell($w[0],6,utf8_decode($res['nom_utilisateur']),$border,0,'L',$fill);
$pdf->Cell($w[1],6,utf8_decode($res['prenom']),$border,0,'L',$fill);
$pdf->Cell($w[2],6,utf8_decode($res['nom_prod']),$border,0,'L',$fill);
$pdf->Cell($w[3],6,utf8_decode($res['quantite']),$border,0,'L',$fill);
$pdf->Ln();
if($breakpage == true)
{
$skip = 0;
$height = 0;
$pdf->Cell(0, 10, " AE R&D - Page " . $page . "",0,0,'C');
$pdf->AddPage();
$page++;
$breakpage = false;
}
$fill=!$fill;
}
$pdf->Cell(array_sum($w),0,'','T');
$pdf->Output('liste_place_non-retrait.pdf',D);
}
$site->start_page("services","AE - Recherche et Dveloppement");
$intro = new contents("Edition liste au format pdf");
$intro->add_paragraph("Cliquez <a href=\"".$_SERVER['SCRIPT_NAME']."?action=getpdf\">ici</a> pour obtenir le fichier pdf de cette liste : <a href=\"".$_SERVER['SCRIPT_NAME']."?action=getpdf\"><img src=\"".$topdir."/images/pdf.png\"></a>");
$cts = new sqltable(
"listeinteg",
utf8_encode("Liste des utilisateurs extrieurs l'UTBM non cotisants l'AE"), $req,$topdir."user.php",
"id_utilisateur",
array("nom_utilisateur"=>"Nom", "prenom" =>"Prnom"),
array(), array());
$site->add_contents($intro);
$site->add_contents($cts);
$site->end_page();
?>
<?php
$topdir = "../";
require_once($topdir. "include/site.inc.php");
require_once($topdir. "include/cts/sqltable.inc.php");
require_once ($topdir. "include/entities/asso.inc.php");
require_once ($topdir . "include/pdf/facture_pdf.inc.php");
$site = new site ();
if (!$site->user->ae)
$site->error_forbidden("none","reserved");
if (!$site->user->utbm)
$site->error_forbidden("none","reservedutbm");
if (!$site->user->is_valid())
$site->error_forbidden();
if (!$site->user->is_asso_role(1,2))
$site->error_forbidden("none",utf8_encode("Accs reserv aux membre du bureau AE"));
$req = new requete($site->db, "SELECT `utilisateurs`.`id_utilisateur`,`utilisateurs`.`nom_utl` AS `nom_utilisateur`,`utilisateurs`.`prenom_utl` AS `prenom` FROM `utilisateurs` INNER JOIN `utl_etu` ON `utilisateurs`.`id_utilisateur`=`utl_etu`.`id_utilisateur` WHERE `utilisateurs`.`ae_utl` = '1' AND (`utl_etu`.`nom_ecole_etudiant`!='UTBM' OR `utilisateurs`.`utbm_utl`='0')");
if (isset($_REQUEST['action']) && $_REQUEST['action']=="getpdf")
{
define('FPDF_FONTPATH', $topdir.'./font/');
$pdf=new FPDF();
$pdf->AliasNbPages();
$pdf->SetAutoPageBreak(false);
$pdf->AddPage();
$pdf->SetFont('Arial','B',14);
$pdf->Image($topdir."./images/Ae-blanc.jpg", 10, 10, 75);
$pdf->SetFont('Times','BI',22);
$pdf->Cell(0, 18, "Automne 2006",'','','R');
$pdf->Ln();
$pdf->SetFont('Arial','B',14);
$pdf->Cell('', 20, "Liste des tudiants extrieurs non cotisants l'AE",'','','C');
$pdf->Ln();
$pdf->SetFont('Arial','B',11);
//Header
$w=array(90,90);
//Data
$fill=0;
$skip=57;
$height=0;
$page=1;
$breakpage = false;
while ($res = $req->get_row())
{
if(($skip + $height) > 255)
{
$breakpage = true;
$border = 'LRB';
}
else if($height == 0)
{
//Colors, line width and bold font
$pdf->SetFillColor(0,0,0);
$pdf->SetTextColor(255);
$pdf->SetDrawColor(128,128,128);
$pdf->SetLineWidth(.3);
$pdf->SetFont('','B');
$pdf->Cell($w[0],7,"Nom", 1, 0, 'C', 1);
$pdf->Cell($w[1],7,"Prnom", 1, 0, 'C', 1);
//$pdf->Cell($w[2],7,"Surnom", 1, 0, 'C', 1);
$pdf->Ln();
//Color and font restoration
$pdf->SetFillColor(200,200,200);
$pdf->SetTextColor(0);
$pdf->SetFont('');
$height += 7;
$border = 'LR';
}
else
{
$border = 'LR';
$height += 6;
}
$pdf->Cell($w[0],6,utf8_decode($res['nom_utilisateur']),$border,0,'C',$fill);
$pdf->Cell($w[1],6,utf8_decode($res['prenom']),$border,0,'C',$fill);
//$pdf->Cell($w[2],6,utf8_decode($res['surnom']),$border,0,'L',$fill);
$pdf->Ln();
if($breakpage == true)
{
$skip = 0;
$height = 0;
$pdf->Cell(0, 10, " AE R&D - Page " . $page . " - Realised by Lorenzo",0,0,'C');
$pdf->AddPage();
$page++;
$breakpage = false;
}
$fill=!$fill;
}
$pdf->Cell(array_sum($w),0,'','T');
$pdf->Output('liste_etus_non_ae_non_utbm.pdf',D);
}
$site->start_page("services","AE - Recherche et D鶥loppement");
$intro = new contents("Edition liste au format pdf");
$intro->add_paragraph("Cliquez <a href=\"".$_SERVER['SCRIPT_NAME']."?action=getpdf\">ici</a> pour obtenir le fichier pdf de cette liste : <a href=\"".$_SERVER['SCRIPT_NAME']."?action=getpdf\"><img src=\"".$topdir."/images/pdf.png\"></a>");
$cts = new sqltable(
"listeinteg",
utf8_encode("Liste des utilisateurs extrieurs l'UTBM non cotisants l'AE"), $req,$topdir."user.php",
"id_utilisateur",
array("nom_utilisateur"=>"Nom", "prenom" =>"Prénom"),
array(), array());
$site->add_contents($intro);
$site->add_contents($cts);
$site->end_page();
?>
\ No newline at end of file
<?
$topdir = "../";
require_once($topdir . "include/globals.inc.php");
require_once ("../include/mysql.inc.php");
require_once ("../include/mysqlae.inc.php");
$subject = 'Soirée filles';
$headers = 'From: Laure Guicherd <laure.guicherd@gmail.com>' . "\r\n" .
'Reply-To: Laure Guicherd <laure.guicherd@gmail.com>' . "\r\n" .
'X-Mailer: PHP/' . phpversion();
$message = "Rebonjour les filles !
J'espère que vous n'avez pas oublié que la soirée filles est demain :p
Pour celles qui n'ont pas encore cotisé, je vous rappelle que la cotiz est toujours dispo sur l'e-boutic, et que demain à 10h devant l'A200 se tiendra une perm :)
Au cas ou il y a vraiment un problème, contactez-moi (numéro sur le matmatronch)
D'autre part, je vous contacte aussi à propos des perms de bar : si l'une d'entre vous est motivée, manifestez-vous rapidement histoire qu'on essaie de se mettre d'accord sur des horaires approximatifs.
A demain !
Locoms
";
$req = new requete (new mysqlae(),
"SELECT utilisateurs.id_utilisateur,
CONCAT(prenom_utl,' ',nom_utl) as nom,
email_utl
FROM utilisateurs
WHERE utilisateurs.sexe_utl='2'
AND ae_utl='1'
AND etudiant_utl='1'
AND utbm_utl='1'
ORDER BY id_utilisateur");
while($res = $req->get_row())
{
echo $res['nom'] . " &lt;" . $res['email_utl'] . "&gt; : Sent <br />";
//mail($res['nom']." <".$res['email_utl'].">", $subject, $message, $headers);
}
?>
<?php
/* Copyright 2008
* - Simon Lopez < simon DOT lopez AT ayolo DOT org >
*
* Ce fichier fait partie du site de l'Association des Étudiants de
* l'UTBM, http://ae.utbm.fr.
*
* 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 the Free Software Foundation; either version 2 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
* 02111-1307, USA.
*/
$topdir = "../";
require_once($topdir. "include/site.inc.php");
$site = new site ();
$req = new requete($site->db, "SHOW TABLES");
while(list($table)=$req->get_row())
new requete($site->dbrw, "OPTIMIZE TABLE `".$table."`");
?>
<?php
exit();
$topdir="../";
require_once($topdir. "include/site.inc.php");
require_once($topdir."include/entities/page.inc.php");
$site = new site();
new requete($site->dbrw,"TRUNCATE TABLE wiki");
new requete($site->dbrw,"TRUNCATE TABLE wiki_lock");
new requete($site->dbrw,"TRUNCATE TABLE wiki_ref_file");
new requete($site->dbrw,"TRUNCATE TABLE wiki_ref_missingwiki");
new requete($site->dbrw,"TRUNCATE TABLE wiki_ref_wiki");
new requete($site->dbrw,"TRUNCATE TABLE wiki_rev");
new insert($site->dbrw,"wiki", array (
"id_utilisateur" => 142,
"id_groupe" => 7,
"id_groupe_admin" => 7,
"droits_acces_wiki" => 1905,
"id_wiki_parent" => NULL,
"id_asso" => NULL,
"id_rev_last" => 1,
"name_wiki" => "",
"fullpath_wiki" => "",
"namespace_behaviour" => 1,
"section_wiki"=>NULL));
new insert($site->dbrw,"wiki_rev", array (
"id_wiki" => 1,
"id_utilisateur_rev" => 142,
"date_rev" => date("Y-m-d H:i:s"),
"contents_rev" => "Bienvenue sur Wiki2",
"title_rev" => "Wiki2",
"comment_rev" => "Big-bang"));
?>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment