Grosse MàJ
12
P51/apache-tomcat-6.0.14/webapps/RandoOnLine/.classpath
Normal file
@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<classpath>
|
||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
|
||||
<classpathentry kind="var" path="TOMCAT_HOME/lib/servlet-api.jar"/>
|
||||
<classpathentry kind="var" path="TOMCAT_HOME/lib/jasper.jar"/>
|
||||
<classpathentry kind="var" path="TOMCAT_HOME/lib/jsp-api.jar"/>
|
||||
<classpathentry kind="var" path="TOMCAT_HOME/lib/el-api.jar"/>
|
||||
<classpathentry kind="var" path="TOMCAT_HOME/lib/annotations-api.jar"/>
|
||||
<classpathentry kind="src" path="WEB-INF/src"/>
|
||||
<classpathentry kind="src" output="work" path="work"/>
|
||||
<classpathentry kind="output" path="WEB-INF/classes"/>
|
||||
</classpath>
|
1
P51/apache-tomcat-6.0.14/webapps/RandoOnLine/.cvsignore
Normal file
@ -0,0 +1 @@
|
||||
work
|
18
P51/apache-tomcat-6.0.14/webapps/RandoOnLine/.project
Normal file
@ -0,0 +1,18 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>RandoOnLine</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.jdt.core.javabuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
<nature>org.eclipse.jdt.core.javanature</nature>
|
||||
<nature>com.sysdeo.eclipse.tomcat.tomcatnature</nature>
|
||||
</natures>
|
||||
</projectDescription>
|
11
P51/apache-tomcat-6.0.14/webapps/RandoOnLine/.tomcatplugin
Normal file
@ -0,0 +1,11 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<tomcatProjectProperties>
|
||||
<rootDir>/</rootDir>
|
||||
<exportSource>false</exportSource>
|
||||
<reloadable>true</reloadable>
|
||||
<redirectLogger>false</redirectLogger>
|
||||
<updateXml>true</updateXml>
|
||||
<warLocation></warLocation>
|
||||
<extraInfo></extraInfo>
|
||||
<webPath>/RandoOnLine</webPath>
|
||||
</tomcatProjectProperties>
|
@ -0,0 +1 @@
|
||||
classes
|
@ -0,0 +1,90 @@
|
||||
/*
|
||||
* article.java
|
||||
*
|
||||
* Created on 18 janvier 2008, 14:26
|
||||
*/
|
||||
|
||||
package com.articles;
|
||||
|
||||
/**
|
||||
* Article de la base de donn<6E>e, avec la quantit<69> en plus
|
||||
* @author 3fvorillion
|
||||
*/
|
||||
public class Article
|
||||
{
|
||||
private String ref = "";
|
||||
private String categ = "";
|
||||
private String marque = "";
|
||||
private String modele = "";
|
||||
private double prix = 0;
|
||||
private String photo = "";
|
||||
private String description = "";
|
||||
private int quantite = 0;
|
||||
|
||||
public String getRef()
|
||||
{
|
||||
return this.ref;
|
||||
}
|
||||
public String getCateg()
|
||||
{
|
||||
return this.categ;
|
||||
}
|
||||
public String getMarque()
|
||||
{
|
||||
return this.marque;
|
||||
}
|
||||
public String getModele()
|
||||
{
|
||||
return this.modele;
|
||||
}
|
||||
public double getPrix()
|
||||
{
|
||||
return this.prix;
|
||||
}
|
||||
public String getPhoto()
|
||||
{
|
||||
return this.photo;
|
||||
}
|
||||
public String getDescription()
|
||||
{
|
||||
return this.description;
|
||||
}
|
||||
|
||||
public void setRef(String ref)
|
||||
{
|
||||
this.ref = ref;
|
||||
}
|
||||
public void setCateg(String categ)
|
||||
{
|
||||
this.categ = categ;
|
||||
}
|
||||
public void setMarque(String marque)
|
||||
{
|
||||
this.marque = marque;
|
||||
}
|
||||
public void setModele(String modele)
|
||||
{
|
||||
this.modele = modele;
|
||||
}
|
||||
public void setPrix(double prix)
|
||||
{
|
||||
this.prix = prix;
|
||||
}
|
||||
public void setPhoto(String photo)
|
||||
{
|
||||
this.photo = photo;
|
||||
}
|
||||
public void setDescription(String description)
|
||||
{
|
||||
this.description = description;
|
||||
}
|
||||
|
||||
public int getQuantite()
|
||||
{
|
||||
return this.quantite;
|
||||
}
|
||||
public void setQuantite(int quantite)
|
||||
{
|
||||
this.quantite = quantite;
|
||||
}
|
||||
}
|
@ -0,0 +1,41 @@
|
||||
package com.articles;
|
||||
|
||||
/**
|
||||
* Cat<61>gorie de la base de donn<6E>e
|
||||
* @author 3fvorillion
|
||||
*/
|
||||
public class Categorie
|
||||
{
|
||||
private int id = 0;
|
||||
private String cat = "";
|
||||
|
||||
public Categorie()
|
||||
{
|
||||
;
|
||||
}
|
||||
public Categorie(int id, String cat)
|
||||
{
|
||||
this.id = id;
|
||||
this.cat = cat;
|
||||
}
|
||||
|
||||
public int getId()
|
||||
{
|
||||
return this.id;
|
||||
}
|
||||
|
||||
public void setId(int id)
|
||||
{
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getCat()
|
||||
{
|
||||
return this.cat;
|
||||
}
|
||||
|
||||
public void setCat(String cat)
|
||||
{
|
||||
this.cat = cat;
|
||||
}
|
||||
}
|
@ -0,0 +1,64 @@
|
||||
package com.articles;
|
||||
|
||||
/**
|
||||
* Client qui ach<63>te des articles
|
||||
* @author 3fvorillion
|
||||
*/
|
||||
public class Client
|
||||
{
|
||||
private String nom = "";
|
||||
private String prenom = "";
|
||||
private String adresse = "";
|
||||
private String codePost = "";
|
||||
private String ville = "";
|
||||
|
||||
public String getNom()
|
||||
{
|
||||
return this.nom;
|
||||
}
|
||||
|
||||
public void setNom(String nom)
|
||||
{
|
||||
this.nom = nom;
|
||||
}
|
||||
|
||||
public String getPrenom()
|
||||
{
|
||||
return this.prenom;
|
||||
}
|
||||
|
||||
public void setPrenom(String prenom)
|
||||
{
|
||||
this.prenom = prenom;
|
||||
}
|
||||
|
||||
public String getAdresse()
|
||||
{
|
||||
return this.adresse;
|
||||
}
|
||||
|
||||
public void setAdresse(String adresse)
|
||||
{
|
||||
this.adresse = adresse;
|
||||
}
|
||||
|
||||
public String getCodePost()
|
||||
{
|
||||
return this.codePost;
|
||||
}
|
||||
|
||||
public void setCodePost(String codePost)
|
||||
{
|
||||
this.codePost = codePost;
|
||||
}
|
||||
|
||||
public String getVille()
|
||||
{
|
||||
return this.ville;
|
||||
}
|
||||
|
||||
public void setVille(String ville)
|
||||
{
|
||||
this.ville = ville;
|
||||
}
|
||||
}
|
@ -0,0 +1,29 @@
|
||||
package com.articles;
|
||||
|
||||
/**
|
||||
* Panier du client. Il contient des articles.
|
||||
* @author 3fvorillion
|
||||
*/
|
||||
public class Panier
|
||||
{
|
||||
private double prixTotal = 0;
|
||||
|
||||
public Panier()
|
||||
{
|
||||
;
|
||||
}
|
||||
public Panier(double prixTotal)
|
||||
{
|
||||
this.prixTotal = prixTotal;
|
||||
}
|
||||
|
||||
public double getPrixTotal()
|
||||
{
|
||||
return this.prixTotal;
|
||||
}
|
||||
|
||||
public void setPrixTotal(double prixTotal)
|
||||
{
|
||||
this.prixTotal = prixTotal;
|
||||
}
|
||||
}
|
@ -0,0 +1,27 @@
|
||||
package com.gestionnaires;
|
||||
|
||||
/**
|
||||
* Beans permettant d'afficher les erreurs dans la page erreurs.jsp
|
||||
* @author 3fvorillion
|
||||
*/
|
||||
public class Erreur
|
||||
{
|
||||
private String message = "";
|
||||
|
||||
public Erreur()
|
||||
{}
|
||||
public Erreur(String message)
|
||||
{
|
||||
this.message = message;
|
||||
}
|
||||
|
||||
public String getMessage()
|
||||
{
|
||||
return this.message;
|
||||
}
|
||||
|
||||
public void setMessage(String message)
|
||||
{
|
||||
this.message = message;
|
||||
}
|
||||
}
|
@ -0,0 +1,522 @@
|
||||
package com.gestionnaires;
|
||||
|
||||
/*
|
||||
* Remarque : Type de caract<63>res utilis<69>s dans ce fichier : UTF-8
|
||||
*/
|
||||
|
||||
//JDBC
|
||||
import java.sql.*;
|
||||
import java.util.Vector;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Op<4F>rations possibles avec GestionConnexion.
|
||||
* @author 3fvorillion
|
||||
*/
|
||||
enum OperationBDD
|
||||
{
|
||||
/**
|
||||
* opération de sélection .
|
||||
*/
|
||||
OP_BDD_SELECTION,
|
||||
/**
|
||||
* opération de création de table.
|
||||
*/
|
||||
OP_BDD_CREER_TABLE,
|
||||
/**
|
||||
* opération de suppression de table.
|
||||
*/
|
||||
OP_BDD_SUPPR_TABLE
|
||||
}
|
||||
|
||||
/**
|
||||
* Gestionnaire d'une connexion à une base de données.
|
||||
* @author 3fvorillion
|
||||
*/
|
||||
public class GestionConnexion
|
||||
{
|
||||
/*
|
||||
* VARIABLES
|
||||
*/
|
||||
// param<61>tres
|
||||
private ParametresConnexion paramsConn;
|
||||
|
||||
// connexion
|
||||
private Connection connection = null;
|
||||
private Statement statement = null;
|
||||
|
||||
// requ<71>te SQL
|
||||
private String requeteSQL = "";
|
||||
private ResultSet resultSet = null;
|
||||
|
||||
// erreurs - anomalies
|
||||
private Vector<String> vs_erreurs = null;
|
||||
private Vector<String> vs_anomalies = null;
|
||||
|
||||
|
||||
/*
|
||||
* CONSTRUCTEUR
|
||||
*/
|
||||
/**
|
||||
* Constructeur par défaut.<br>
|
||||
* Instancie le gestionnaire d'une connexion à une base de données.
|
||||
* @exception ClassNotFoundException La classe n'a pas été trouvée
|
||||
*/
|
||||
public GestionConnexion()
|
||||
throws ClassNotFoundException, Exception
|
||||
{
|
||||
/*
|
||||
* Init les autres variables
|
||||
*/
|
||||
this.statement = null;
|
||||
this.resultSet = null;
|
||||
this.requeteSQL = "";
|
||||
|
||||
this.paramsConn = new ParametresConnexion();
|
||||
|
||||
//init la gestion des erreurs - anomalies
|
||||
this.vs_erreurs = new Vector<String>();
|
||||
this.vs_anomalies = new Vector<String>();
|
||||
|
||||
try
|
||||
{
|
||||
// R<>cup<75>ration du driver
|
||||
Class.forName(ParametresConnexion.CLASSE).newInstance();
|
||||
}
|
||||
catch (ClassNotFoundException ex)
|
||||
{
|
||||
//remonte l'exception
|
||||
throw new ClassNotFoundException("La classe '"+ParametresConnexion.CLASSE+"' n'a pas <20>t<EFBFBD> trouv<75>e.");
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
//remonte l'exception
|
||||
throw ex;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* METHODES D'INSTANCES
|
||||
*/
|
||||
/**
|
||||
* Ouvre une connexion avec les paramètres spécifiés.
|
||||
* @param params Objet contenant les paramètres à appliquer pour la connexion.
|
||||
*/
|
||||
public void ouvrir(ParametresConnexion params)
|
||||
{
|
||||
//V<>rifie le param<61>tre
|
||||
if (params == null)
|
||||
throw new NullPointerException();
|
||||
|
||||
//Copie les param<61>tres
|
||||
this.paramsConn.CopierDepuis(params);
|
||||
|
||||
//Appelle la m<>thode sans param<61>tres
|
||||
this.ouvrir();
|
||||
}
|
||||
/**
|
||||
* Ouvre une connexion avec les paramètres déjà chargés.<br>
|
||||
* Note : si aucun paramètre n'a été chargé, utilise les paramètres de connexion par défaut (cf classe ParametresConnexion).
|
||||
*/
|
||||
public void ouvrir()
|
||||
{
|
||||
try
|
||||
{
|
||||
// ferme la conexion pr<70>c<EFBFBD>dente
|
||||
this.fermerConnexion();
|
||||
|
||||
// init la nouvelle connexion
|
||||
this.connection = DriverManager.getConnection(this.paramsConn.Url,
|
||||
this.paramsConn.Utilisateur, this.paramsConn.Pwd);
|
||||
|
||||
this.traiterWarning(this.connection.getWarnings());
|
||||
}
|
||||
catch (SQLException ex)
|
||||
{
|
||||
this.traiterSQLException(ex);
|
||||
|
||||
this.fermerConnexion();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Donne l'état de la connexion en cours.
|
||||
* @return true si la connexion est ouverte; false si fermée.
|
||||
*/
|
||||
public boolean estOuverte()
|
||||
{
|
||||
boolean bOuverte = false;
|
||||
|
||||
try
|
||||
{
|
||||
if (this.connection != null)
|
||||
bOuverte = !this.connection.isClosed();
|
||||
}
|
||||
catch (SQLException ex)
|
||||
{
|
||||
this.traiterSQLException(ex);
|
||||
}
|
||||
|
||||
return bOuverte;
|
||||
}
|
||||
|
||||
/**
|
||||
* Ferme les ressources utilisées par la requête:<br>
|
||||
* - ferme le ResultSet et le Statement;<br>
|
||||
* - vide le contenu de la requête.
|
||||
*/
|
||||
public void fermerRessourcesRequete()
|
||||
{
|
||||
try
|
||||
{
|
||||
// Ferme le resultSet
|
||||
if (this.resultSet != null)
|
||||
{
|
||||
this.resultSet.close();
|
||||
this.resultSet = null;
|
||||
}
|
||||
|
||||
// Ferme le statement
|
||||
if (this.statement != null)
|
||||
{
|
||||
this.statement.close();
|
||||
this.statement = null;
|
||||
}
|
||||
|
||||
// Vide la requ<71>te
|
||||
this.requeteSQL = "";
|
||||
}
|
||||
catch (SQLException ex)
|
||||
{
|
||||
this.traiterSQLException(ex);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Ferme la connexion et libère les autres ressources qui ont pu être utilisées.
|
||||
*/
|
||||
public void fermerConnexion()
|
||||
{
|
||||
try
|
||||
{
|
||||
// Ferme le statement
|
||||
this.fermerRessourcesRequete();
|
||||
|
||||
// Ferme la connexion
|
||||
if (this.connection != null)
|
||||
{
|
||||
this.connection.close();
|
||||
this.connection = null;
|
||||
}
|
||||
}
|
||||
catch (SQLException ex)
|
||||
{
|
||||
this.traiterSQLException(ex);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Lance la requête SQL de sélection spécifiée.
|
||||
* @param query Requête SQL de type SELECT à exécuter.
|
||||
* @return true si la requête a réussie; false sinon.
|
||||
*/
|
||||
public boolean lancerRequeteSelection(String query)
|
||||
{
|
||||
boolean res = true;
|
||||
|
||||
try
|
||||
{
|
||||
// verifie la connexion
|
||||
if (this.connection != null)
|
||||
{
|
||||
// lib<69>re les ressources de la pr<70>c<EFBFBD>dente requ<71>te
|
||||
this.fermerRessourcesRequete();
|
||||
|
||||
// prepare la requete
|
||||
this.statement = this.connection.createStatement();
|
||||
this.traiterWarning(this.statement.getWarnings());
|
||||
|
||||
// emet la requete
|
||||
this.resultSet = this.statement.executeQuery(query);
|
||||
this.traiterWarning(this.resultSet.getWarnings());
|
||||
|
||||
// si on est arriv<69> jusqu'ici, c'est qu'il n'y a pas eu de lev<65>e d'exception
|
||||
// =>actualise la requ<71>te
|
||||
this.requeteSQL = query;
|
||||
}
|
||||
}
|
||||
catch (SQLException ex)
|
||||
{
|
||||
this.traiterSQLException(ex);
|
||||
|
||||
// lib<69>re les ressources utilis<69>es
|
||||
this.fermerRessourcesRequete();
|
||||
|
||||
//annonce l'<27>chec de la requ<71>te SQL
|
||||
res = false;
|
||||
}
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
/**
|
||||
* Lance la requête SQL spécifiée qui modifie la base de donnée.
|
||||
* @param query Requête SQL de type DELETE, UPDATE, INSERT à exécuter.
|
||||
* @return nombre de lignes modifiées pour requête DDL;<br>
|
||||
* 0 pour requête ne donnant aucun r<>eacute;sultat;<br>
|
||||
* -1 si une erreur est survenue lors de l'ex<65>cution de la requ<71>te;
|
||||
*/
|
||||
public int lancerRequeteModifBDD(String query)
|
||||
{
|
||||
int res = 0;
|
||||
|
||||
try
|
||||
{
|
||||
// verifie la connexion
|
||||
if (this.connection != null)
|
||||
{
|
||||
// lib<69>re les ressources de la pr<70>c<EFBFBD>dente requ<71>te
|
||||
this.fermerRessourcesRequete();
|
||||
|
||||
// prepare la requete
|
||||
this.statement = this.connection.createStatement();
|
||||
|
||||
// emet la requete
|
||||
res = this.statement.executeUpdate(query);
|
||||
this.traiterWarning(this.statement.getWarnings());
|
||||
|
||||
// si on est arriv<69> jusqu'ici, c'est qu'il n'y a pas eu de lev<65>e d'exception
|
||||
// =>actualise la requ<71>te
|
||||
this.requeteSQL = query;
|
||||
}
|
||||
}
|
||||
catch (SQLException ex)
|
||||
{
|
||||
this.traiterSQLException(ex);
|
||||
|
||||
// lib<69>re les ressources utilis<69>es
|
||||
this.fermerRessourcesRequete();
|
||||
|
||||
//annonce l'<27>chec de la requ<71>te SQL
|
||||
res = -1;
|
||||
}
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
/**
|
||||
* Retourne une copie de l'objet contenant les paramètres de la connexion courante.
|
||||
* @return Copie de l'objet contenant les paramètres de connexion.
|
||||
*/
|
||||
public ParametresConnexion getParametresConnexion()
|
||||
{
|
||||
//Retourne une copie de l'objet contenant les param<61>tres de connexion
|
||||
return new ParametresConnexion(this.paramsConn);
|
||||
}
|
||||
|
||||
/**
|
||||
* Retourne la requête SQL qui a été lancée avec succès.
|
||||
* @return Requête SQL qui a été exécutée.<br>Si pas de résultats disponibles, renvoie une cha<68>ne vide.
|
||||
*/
|
||||
public String getRequeteSQL()
|
||||
{
|
||||
return this.requeteSQL;
|
||||
}
|
||||
|
||||
/**
|
||||
* Donne les infos sur la connexion courante.
|
||||
* @return Liste des infos de la connexion en cours.
|
||||
*/
|
||||
public Vector<String> getInfosConnexion()
|
||||
{
|
||||
Vector<String> vs_infosConn = new Vector<String>();
|
||||
DatabaseMetaData dmd;
|
||||
|
||||
try
|
||||
{
|
||||
// V<>rifie que la connexion soit ouverte
|
||||
if (this.estOuverte())
|
||||
{
|
||||
// Etat de la connexion
|
||||
vs_infosConn.add("Etat de la connexion : ouverte");
|
||||
vs_infosConn.add("------------------------------");
|
||||
|
||||
// Obtient les meta-datas de la base
|
||||
dmd = this.connection.getMetaData();
|
||||
|
||||
vs_infosConn.add("Connexion : " + dmd.getURL());
|
||||
vs_infosConn.add("Driver : " + dmd.getDriverName());
|
||||
vs_infosConn.add("Version : " + dmd.getDriverVersion());
|
||||
}
|
||||
else
|
||||
{
|
||||
// Etat de la connexion
|
||||
vs_infosConn.add("Etat de la connexion : ferm<72>e");
|
||||
vs_infosConn.add("------------------------------");
|
||||
|
||||
vs_infosConn.add("Connexion : " + this.paramsConn.Url);//contient le Serveur, le Port et la Base
|
||||
vs_infosConn.add("Utilisateur : " + this.paramsConn.Utilisateur);
|
||||
vs_infosConn.add("Mot de passe : " + this.paramsConn.Pwd.length() + " caract<63>re(s)");
|
||||
}
|
||||
}
|
||||
catch (SQLException ex)
|
||||
{
|
||||
// Erreur lors de l'obtention du nom des colonnes
|
||||
this.traiterSQLException(ex);
|
||||
}
|
||||
|
||||
return vs_infosConn;
|
||||
}
|
||||
|
||||
/**
|
||||
* Récupère la liste des noms des colonnes issues du résultat de la requête SQL précédemment lancée.
|
||||
* @return Liste des noms des colonnes issues du résultat de la requête SQL.
|
||||
*/
|
||||
public Vector<String> getNomsColonnes()
|
||||
{
|
||||
Vector<String> vs_cols = new Vector<String>();
|
||||
ResultSetMetaData rsmd;
|
||||
|
||||
try
|
||||
{
|
||||
// V<>rifie si la requ<71>te a d<>jà <20>t<EFBFBD> lanc<6E>e
|
||||
if (this.resultSet != null)
|
||||
{
|
||||
rsmd = this.resultSet.getMetaData(); // obtient les meta-datas de la requ<71>te
|
||||
int nbrCols = rsmd.getColumnCount();
|
||||
|
||||
for (int idCol = 1; idCol <= nbrCols; idCol++)
|
||||
if (rsmd.isSearchable(idCol))
|
||||
vs_cols.add(rsmd.getColumnName(idCol));
|
||||
}
|
||||
else if (this.statement == null)
|
||||
// anomalie
|
||||
this.vs_anomalies.add("Vous n'avez pas encore lanc<6E> la requ<71>te!!");
|
||||
}
|
||||
catch (SQLException ex)
|
||||
{
|
||||
// Erreur lors de l'obtention du nom des colonnes
|
||||
this.traiterSQLException(ex);
|
||||
}
|
||||
|
||||
return vs_cols;
|
||||
}
|
||||
|
||||
/**
|
||||
* Récupère le résultat de la requête SQL précédemment lancée dans un tableau d'objets.<br>
|
||||
* Note : Ce tableau est composé d'une liste de lignes.<br>Ces lignes sont elles-mêmes composées d'une liste d'objets.
|
||||
* @return Tableau d'objets correspondant au résultat de la requête SQL.
|
||||
*/
|
||||
public Vector<Vector<Object>> getDataVector()
|
||||
{
|
||||
Vector<Vector<Object>> v_datas = new Vector<Vector<Object>>();
|
||||
ResultSetMetaData rsmd;
|
||||
|
||||
try
|
||||
{
|
||||
rsmd = this.resultSet.getMetaData();
|
||||
// V<>rifie qu'il y ai un r<>sultat et place le curseur au d<>but
|
||||
if (rsmd.getColumnCount() > 0)
|
||||
{
|
||||
while (this.resultSet.next())
|
||||
{
|
||||
Vector<Object> vo_ligne = new Vector<Object>();
|
||||
// cr<63><72> la ligne
|
||||
for (int idCol = 1; idCol <= rsmd.getColumnCount(); idCol++)
|
||||
vo_ligne.add(this.resultSet.getObject(idCol));
|
||||
// ajoute la ligne au vecteur principal
|
||||
v_datas.add(vo_ligne);
|
||||
}
|
||||
}
|
||||
|
||||
if (v_datas.isEmpty()) // anomalie
|
||||
this.vs_anomalies.add("Aucune donn<6E>e trouv<75>e!!");
|
||||
}
|
||||
catch (SQLException ex)
|
||||
{
|
||||
// Probleme lors de l'obtention des donnees
|
||||
this.traiterSQLException(ex);
|
||||
}
|
||||
|
||||
return v_datas;
|
||||
}
|
||||
|
||||
/*
|
||||
* GESTION DES ERREURS - ANOMALIES
|
||||
*/
|
||||
/**
|
||||
* Trace les erreurs SQL qui ont été levées par une exception donnée.
|
||||
* @param ex SQLException à tracer.
|
||||
*/
|
||||
public void traiterSQLException(SQLException ex)
|
||||
{
|
||||
String str_ex;
|
||||
|
||||
str_ex = "********* SQLException *********\n";
|
||||
while (ex != null)
|
||||
{
|
||||
str_ex = "SQLState : " + ex.getSQLState() + "\n";
|
||||
str_ex += "Message : " + ex.getMessage() + "\n";
|
||||
str_ex += "------------------------------\n";
|
||||
this.vs_erreurs.add(str_ex);
|
||||
|
||||
ex = ex.getNextException();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Trace les anomalies SQL données.
|
||||
* @param warn Anomalies SQL à tracer.
|
||||
*/
|
||||
public void traiterWarning(SQLWarning warn)
|
||||
{
|
||||
String str_an;
|
||||
|
||||
str_an = "********* SQLWarning *********\n";
|
||||
while (warn != null)
|
||||
{
|
||||
str_an = "SQLState : " + warn.getSQLState() + "\n";
|
||||
str_an += "Message : " + warn.getMessage() + "\n";
|
||||
str_an += "------------------------------\n";
|
||||
this.vs_anomalies.add(str_an);
|
||||
|
||||
warn = warn.getNextWarning();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Récupère la liste des erreurs tracées.
|
||||
* @return Liste des erreurs tracées.<br>Note : retourne une copie du vecteur interne pour empêcher la modification directe de celui-ci.
|
||||
*/
|
||||
public Vector<String> getErreurs()
|
||||
{
|
||||
return new Vector<String>(this.vs_erreurs);
|
||||
}
|
||||
|
||||
/**
|
||||
* Récupère la liste des anomalies tracées.
|
||||
* @return Liste des anomalies tracées.<br>Note : retourne une copie du vecteur interne pour empêcher la modification directe de celui-ci.
|
||||
*/
|
||||
public Vector<String> getAnomalies()
|
||||
{
|
||||
return new Vector<String>(this.vs_anomalies);
|
||||
}
|
||||
|
||||
/**
|
||||
* Efface la liste des erreurs tracées.
|
||||
*/
|
||||
public void effaceErreurs()
|
||||
{
|
||||
this.vs_erreurs.clear();
|
||||
}
|
||||
|
||||
/**
|
||||
* Efface la liste des anomalies tracées.
|
||||
*/
|
||||
public void effaceAnomalies()
|
||||
{
|
||||
this.vs_anomalies.clear();
|
||||
}
|
||||
}
|
@ -0,0 +1,208 @@
|
||||
package com.gestionnaires;
|
||||
|
||||
import java.util.Vector;
|
||||
import com.articles.Article;
|
||||
import com.articles.Categorie;
|
||||
|
||||
/**
|
||||
* Gestionnaire des articles (et des cat<61>gories) :<br>
|
||||
* R<>cup<75>re les articles et les cat<61>gories depuis la BDD, selon des crit<69>res ou non.<br>
|
||||
* Note : il ne doit y avoir qu'une instance de cette classe : elle utilise le gestionnaire de connexion <20> la BDD.
|
||||
* @author 3fvorillion
|
||||
*/
|
||||
public class GestionnaireArticles
|
||||
{
|
||||
private static GestionnaireArticles instanceUnique = null;
|
||||
private GestionConnexion gestConn = null;
|
||||
private ParametresConnexion paramsConn = null;
|
||||
|
||||
/**
|
||||
* Instancie le gestionnaire d'articles.<br>
|
||||
* - instancie le gestionnaire de connexion <20> la BDD.
|
||||
* @throws Exception
|
||||
*/
|
||||
public GestionnaireArticles()
|
||||
throws Exception
|
||||
{
|
||||
//
|
||||
// Cr<43>ation de l'objet connexion
|
||||
//
|
||||
this.gestConn = new GestionConnexion();
|
||||
|
||||
this.paramsConn = new ParametresConnexion();
|
||||
}
|
||||
|
||||
/***
|
||||
* Donne la liste des articles correspondants aux conditions donnees.
|
||||
* @param sConditions Conditions de selection des articles.<br>Peut <20>tre null ou vide.<br>Sans la clause 'where'.
|
||||
* @return Liste des articles correspondants aux crit<69>res donn<6E>s.
|
||||
*/
|
||||
public Vector<Article> donnerListeArticles(String sConditions)
|
||||
throws Exception
|
||||
{
|
||||
Vector<Vector<Object>> vResReq = null;
|
||||
Vector<String> vLstCols = null;
|
||||
Vector<Article> vLstArts = null;
|
||||
Article tmpArt = null;
|
||||
String sReqSQL = "";
|
||||
|
||||
//
|
||||
// Se connecte <20> la base
|
||||
//
|
||||
// Ouvre la connexion si pas d<>j<EFBFBD> fait
|
||||
if (!this.gestConn.estOuverte())
|
||||
this.gestConn.ouvrir(this.paramsConn);
|
||||
|
||||
// Si pas ouverte, sort
|
||||
if ( !this.gestConn.estOuverte() )
|
||||
throw new Exception("La connexion avec la base de donn<6E>es n'a pas pu <20>tre <20>tablie.");
|
||||
|
||||
//
|
||||
// Cr<43>er la requ<71>te
|
||||
//
|
||||
sReqSQL = "SELECT * FROM ARTICLES_RANDO";
|
||||
if (sConditions != null)
|
||||
if (!sConditions.equals(""))
|
||||
sReqSQL += " WHERE " + sConditions;
|
||||
|
||||
//
|
||||
// Lance la requ<71>te et r<>cup<75>re les donn<6E>es
|
||||
//
|
||||
if (this.gestConn.lancerRequeteSelection(sReqSQL))
|
||||
{
|
||||
vResReq = this.gestConn.getDataVector();
|
||||
vLstCols = this.gestConn.getNomsColonnes();
|
||||
vLstArts = new Vector<Article>(vResReq.size());
|
||||
|
||||
for (int iArt=0; iArt<vResReq.size(); iArt++)
|
||||
{
|
||||
tmpArt = new Article();
|
||||
|
||||
//R<>cup<75>re les donn<6E>es
|
||||
for (int iCol=0; iCol<vLstCols.size(); iCol++)
|
||||
{
|
||||
if (vLstCols.get(iCol).toUpperCase().equals("REFERENCE"))
|
||||
tmpArt.setRef(String.valueOf(vResReq.get(iArt).get(iCol)));
|
||||
else if (vLstCols.get(iCol).toUpperCase().equals("CATEGORIE"))
|
||||
tmpArt.setCateg(String.valueOf(vResReq.get(iArt).get(iCol)));
|
||||
else if (vLstCols.get(iCol).toUpperCase().equals("MARQUE"))
|
||||
tmpArt.setMarque(String.valueOf(vResReq.get(iArt).get(iCol)));
|
||||
else if (vLstCols.get(iCol).toUpperCase().equals("MODELE"))
|
||||
tmpArt.setModele(String.valueOf(vResReq.get(iArt).get(iCol)));
|
||||
else if (vLstCols.get(iCol).toUpperCase().equals("PRIX"))
|
||||
tmpArt.setPrix(Double.parseDouble(vResReq.get(iArt).get(iCol).toString()));
|
||||
else if (vLstCols.get(iCol).toUpperCase().equals("PHOTO"))
|
||||
tmpArt.setPhoto(String.valueOf(vResReq.get(iArt).get(iCol)));
|
||||
else if (vLstCols.get(iCol).toUpperCase().equals("DESCRIPTION"))
|
||||
tmpArt.setDescription(String.valueOf(vResReq.get(iArt).get(iCol)));
|
||||
}
|
||||
|
||||
//Ajoute <20> la liste
|
||||
vLstArts.add(tmpArt);
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
// Se d<>connecte de la base
|
||||
//
|
||||
// Ferme la connexion
|
||||
this.gestConn.fermerConnexion();
|
||||
|
||||
return vLstArts;
|
||||
}
|
||||
|
||||
/***
|
||||
* Donne la liste des categories correspondants aux conditions donnees.
|
||||
* @param sConditions Conditions de selection des categories.<br>Peut <20>tre null ou vide.<br>Sans la clause 'where'.
|
||||
* @return Liste des categories correspondants aux crit<69>res donn<6E>s.
|
||||
*/
|
||||
public Vector<Categorie> donnerListeCategories(String sConditions)
|
||||
throws Exception
|
||||
{
|
||||
Vector<Vector<Object>> vResReq = null;
|
||||
Vector<String> vLstCols = null;
|
||||
Vector<Categorie> vLstCats = null;
|
||||
Categorie tmpCat = null;
|
||||
String sReqSQL = "";
|
||||
|
||||
//
|
||||
// Se connecte <20> la base
|
||||
//
|
||||
// Ouvre la connexion si pas d<>j<EFBFBD> fait
|
||||
if (!this.gestConn.estOuverte())
|
||||
this.gestConn.ouvrir(this.paramsConn);
|
||||
|
||||
// Si pas ouverte, sort
|
||||
if ( !this.gestConn.estOuverte() )
|
||||
throw new Exception("La connexion avec la base de donn<6E>es n'a pas pu <20>tre <20>tablie.");
|
||||
|
||||
//
|
||||
// Cr<43>er la requ<71>te
|
||||
//
|
||||
sReqSQL = "SELECT * FROM CATEGORIE_RANDO";
|
||||
if (sConditions != null)
|
||||
if (!sConditions.equals(""))
|
||||
sReqSQL += " WHERE " + sConditions;
|
||||
|
||||
//
|
||||
// Lance la requ<71>te et r<>cup<75>re les donn<6E>es
|
||||
//
|
||||
if (this.gestConn.lancerRequeteSelection(sReqSQL))
|
||||
{
|
||||
vResReq = this.gestConn.getDataVector();
|
||||
vLstCols = this.gestConn.getNomsColonnes();
|
||||
vLstCats = new Vector<Categorie>(vResReq.size());
|
||||
|
||||
for (int iArt=0; iArt<vResReq.size(); iArt++)
|
||||
{
|
||||
tmpCat = new Categorie();
|
||||
|
||||
//R<>cup<75>re les donn<6E>es
|
||||
for (int iCol=0; iCol<vLstCols.size(); iCol++)
|
||||
{
|
||||
if (vLstCols.get(iCol).toUpperCase().equals("ID"))
|
||||
tmpCat.setId(Integer.parseInt(vResReq.get(iArt).get(iCol).toString()));
|
||||
else if (vLstCols.get(iCol).toUpperCase().equals("CAT"))
|
||||
tmpCat.setCat(String.valueOf(vResReq.get(iArt).get(iCol)));
|
||||
}
|
||||
|
||||
//Ajoute <20> la liste
|
||||
vLstCats.add(tmpCat);
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
// Se d<>connecte de la base
|
||||
//
|
||||
// Ferme la connexion
|
||||
this.gestConn.fermerConnexion();
|
||||
|
||||
return vLstCats;
|
||||
}
|
||||
|
||||
/**
|
||||
* Retourne une instance unique pour le gestionnaire des articles.
|
||||
* @return instance unique du gestionnaire des articles.
|
||||
* @throws Exception
|
||||
*/
|
||||
public static GestionnaireArticles getInstanceUnique()
|
||||
throws Exception
|
||||
{
|
||||
if (GestionnaireArticles.instanceUnique == null)
|
||||
GestionnaireArticles.instanceUnique = new GestionnaireArticles();
|
||||
|
||||
return GestionnaireArticles.instanceUnique;
|
||||
}
|
||||
|
||||
/**
|
||||
* Modifie l'instance unique pour le gestionnaire des articles.
|
||||
* @param instanceUnique
|
||||
*/
|
||||
public static void setInstanceUnique(GestionnaireArticles instanceUnique)
|
||||
{
|
||||
if (instanceUnique == null)
|
||||
return;
|
||||
|
||||
GestionnaireArticles.instanceUnique = instanceUnique;
|
||||
}
|
||||
}
|
@ -0,0 +1,117 @@
|
||||
package com.gestionnaires;
|
||||
|
||||
import java.util.Vector;
|
||||
import com.articles.Article;
|
||||
|
||||
/**
|
||||
* Traite le contenu du panier.
|
||||
* @author 3fvorillion
|
||||
*/
|
||||
public class GestionnairePanier
|
||||
{
|
||||
Vector<Article> vArticles = null;
|
||||
boolean bEstPaye = false;
|
||||
|
||||
/**
|
||||
* Instancie le panier
|
||||
*/
|
||||
public GestionnairePanier()
|
||||
{
|
||||
this.vArticles = new Vector<Article>();
|
||||
}
|
||||
|
||||
/**
|
||||
* Ajoute un article au panier.
|
||||
* @param art article <20> ajouter.
|
||||
*/
|
||||
public void ajouterAchat(Article art)
|
||||
{
|
||||
Article artPan = null;
|
||||
boolean bArtTrouve = false;
|
||||
|
||||
if (art == null)
|
||||
return;
|
||||
|
||||
//V<>rifie si pas d<>j<EFBFBD> pr<70>sent
|
||||
for (int i=0; i<this.vArticles.size() && !bArtTrouve; i++)
|
||||
if (this.vArticles.get(i).getRef().equals(art.getRef()))
|
||||
{
|
||||
artPan = this.vArticles.get(i);
|
||||
bArtTrouve = true;
|
||||
}
|
||||
|
||||
//Si trouv<75>, incr<63>mente
|
||||
if (bArtTrouve)
|
||||
artPan.setQuantite(artPan.getQuantite()+1);
|
||||
//sinon, ajoute et met <20> jour la quantiti<74>
|
||||
else
|
||||
{
|
||||
art.setQuantite(1);
|
||||
this.vArticles.add(art);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Modifie la quantit<69> pour un article de r<>f<EFBFBD>rence donn<6E>e.
|
||||
* @param sRefArticle R<>f<EFBFBD>rence vers l'article.
|
||||
* @param quantite Nouvelle quantit<69>
|
||||
*/
|
||||
public void modifieAchat(String sRefArticle, int quantite)
|
||||
{
|
||||
for (int i=0; i<this.vArticles.size(); i++)
|
||||
if (this.vArticles.get(i).getRef().equals(sRefArticle))
|
||||
this.vArticles.get(i).setQuantite(quantite);
|
||||
}
|
||||
|
||||
/**
|
||||
* Enl<6E>ve du panier l'article de r<>f<EFBFBD>rence donn<6E>e
|
||||
* @param sRefArticle R<>f<EFBFBD>rence vers l'article.
|
||||
*/
|
||||
public void enleverAchat(String sRefArticle)
|
||||
{
|
||||
for (int i=0; i<this.vArticles.size(); i++)
|
||||
if (this.vArticles.get(i).getRef().equals(sRefArticle))
|
||||
this.vArticles.remove(i);
|
||||
}
|
||||
|
||||
/**
|
||||
* Donne les articles du panier.
|
||||
* @return liste des articles du panier.
|
||||
*/
|
||||
public Vector<Article> donneContenu()
|
||||
{
|
||||
return this.vArticles;
|
||||
}
|
||||
|
||||
/**
|
||||
* Donne l'<27>tat de payement du panier.
|
||||
* @return 'true' si le panier est pass<73> '<27> la caisse'. 'fase' sinon.
|
||||
*/
|
||||
public boolean getEstPaye()
|
||||
{
|
||||
return this.bEstPaye;
|
||||
}
|
||||
|
||||
/**
|
||||
* D<>termine l'<27>tat de payement du panier.
|
||||
* @param bEstPaye 'true' si le panier est pass<73> '<27> la caisse'. 'fase' sinon.
|
||||
*/
|
||||
public void setEstPaye(boolean bEstPaye)
|
||||
{
|
||||
this.bEstPaye = bEstPaye;
|
||||
}
|
||||
|
||||
/**
|
||||
* Calcule et retourne le prix total du panier.
|
||||
* @return Prix total du panier.
|
||||
*/
|
||||
public double getPrixTotalPanier()
|
||||
{
|
||||
double prixTotal = 0;
|
||||
|
||||
for (int i=0; i<this.vArticles.size(); i++)
|
||||
prixTotal += this.vArticles.get(i).getPrix() * this.vArticles.get(i).getQuantite();
|
||||
|
||||
return prixTotal;
|
||||
}
|
||||
}
|
@ -0,0 +1,98 @@
|
||||
package com.gestionnaires;
|
||||
/*
|
||||
* Remarque : Type de caract<63>res utilis<69>s dans ce fichier : UTF-8
|
||||
*/
|
||||
|
||||
/**
|
||||
* Structure qui contient les paramètres d'une connexion.
|
||||
* @author 3fvorillion
|
||||
*/
|
||||
public class ParametresConnexion
|
||||
{
|
||||
/*
|
||||
* ATTRIBUTS
|
||||
*/
|
||||
/**
|
||||
* Nom du serveur sur le réseau.
|
||||
*/
|
||||
public String Serveur = "localhost";
|
||||
/**
|
||||
* Numéro du port du serveur auquel se connecter pour accéder à la base.
|
||||
*/
|
||||
public String Port = "3306";
|
||||
/**
|
||||
* Nom de la base de données à utiliser.
|
||||
*/
|
||||
public String Base = "test";
|
||||
/**
|
||||
* Login par défaut de l'utilisateur habilité sur la base de données.
|
||||
*/
|
||||
public String Utilisateur = "root";
|
||||
/**
|
||||
* Mot de passe par défaut associé au Login.
|
||||
*/
|
||||
public String Pwd = "";
|
||||
|
||||
/**
|
||||
* Mot de passe par défaut associé au Login.
|
||||
*/
|
||||
public String Url = "jdbc:mysql://localhost:3306/test";
|
||||
|
||||
/**
|
||||
* Classe qui correspond au pilote à utiliser pour se connecter à une base de données.
|
||||
*/
|
||||
public static final String CLASSE = "com.mysql.jdbc.Driver";
|
||||
|
||||
/*
|
||||
* CONSTRUCTEURS
|
||||
*/
|
||||
/**
|
||||
* Créer une instance de la classe avec les valeurs par défaut des attributs.
|
||||
*/
|
||||
public ParametresConnexion() { ; }
|
||||
|
||||
/**
|
||||
* Créer une instance de la classe en copiant les valeurs d'une autre instance de cette classe.
|
||||
* @param params Paramètres définits dans une autre instance de cette classe qui sont à recopier.
|
||||
*/
|
||||
public ParametresConnexion( ParametresConnexion params )
|
||||
{
|
||||
this.CopierDepuis(params);
|
||||
}
|
||||
|
||||
/**
|
||||
* Créer une instance de la classe en copiant les valeurs données.
|
||||
* @param serveur Nom du serveur sur le réseau.
|
||||
* @param port Numéro du port du serveur auquel se connecter pour accéder à la base.
|
||||
* @param base Nom de la base de données à utiliser.
|
||||
* @param utilisateur Login par défaut de l'utilisateur habilité sur la base de données.
|
||||
* @param pwd Mot de passe par défaut associé au Login.
|
||||
*/
|
||||
public ParametresConnexion(String serveur, String port, String base,
|
||||
String utilisateur, String pwd, String url)
|
||||
{
|
||||
this.Serveur = serveur;
|
||||
this.Port = port;
|
||||
this.Base = base;
|
||||
this.Utilisateur = utilisateur;
|
||||
this.Pwd = pwd;
|
||||
this.Url = url;
|
||||
}
|
||||
|
||||
/*
|
||||
* METHODES
|
||||
*/
|
||||
/**
|
||||
* Copie les valeurs d'une autre instance de cette classe.
|
||||
* @param params Paramètres définits dans une autre instance de cette classe qui sont à recopier.
|
||||
*/
|
||||
public void CopierDepuis( ParametresConnexion params )
|
||||
{
|
||||
this.Serveur = params.Serveur;
|
||||
this.Port = params.Port;
|
||||
this.Base = params.Base;
|
||||
this.Utilisateur = params.Utilisateur;
|
||||
this.Pwd = params.Pwd;
|
||||
this.Url = params.Url;
|
||||
}
|
||||
}
|
@ -0,0 +1,135 @@
|
||||
/*
|
||||
* ArticlesServlet.java
|
||||
*
|
||||
* Created on 11 janvier 2008, 15:06
|
||||
*/
|
||||
|
||||
package com.servlets;
|
||||
|
||||
import java.io.*;
|
||||
|
||||
import javax.servlet.*;
|
||||
import javax.servlet.http.*;
|
||||
|
||||
import java.util.Vector;
|
||||
import com.articles.Article;
|
||||
import com.articles.Categorie;
|
||||
import com.gestionnaires.Erreur;
|
||||
import com.gestionnaires.GestionnairePanier;
|
||||
import java.sql.*;
|
||||
|
||||
/**
|
||||
* Servlet G<>rant l'affichage des articles de la BDD.<br>
|
||||
* - affichage, filtrage des articles et de leurs caract<63>ristiques.
|
||||
* @author 3fvorillion
|
||||
* @version
|
||||
*/
|
||||
public class ArticlesServlet
|
||||
extends HttpServlet
|
||||
{
|
||||
com.gestionnaires.GestionnaireArticles gestArts = null;
|
||||
|
||||
/**
|
||||
* Traite les messages et affiche en cons<6E>quence.
|
||||
* @param request
|
||||
* @param response
|
||||
* @throws ServletException
|
||||
* @throws IOException
|
||||
*/
|
||||
private void affArticles(HttpServletRequest request, HttpServletResponse response)
|
||||
throws ServletException, IOException
|
||||
{
|
||||
String sPageAffichage = "";
|
||||
Vector<Categorie> vCats = null;
|
||||
Vector<Article> vArts = null;
|
||||
String sIdCategAff;
|
||||
String sCondReqSQL = "";
|
||||
|
||||
//
|
||||
// Traite le filtre
|
||||
//
|
||||
sIdCategAff = request.getParameter("lstCategs");
|
||||
if (sIdCategAff != null)
|
||||
{
|
||||
//Si pas d<>finit ou "toutes cat<61>gorie"
|
||||
if (sIdCategAff.equals("") || sIdCategAff.equals("-1"))
|
||||
{
|
||||
sCondReqSQL = "";
|
||||
}
|
||||
else
|
||||
{
|
||||
sCondReqSQL = "CATEGORIE="+sIdCategAff;
|
||||
}
|
||||
}
|
||||
else
|
||||
sCondReqSQL = "";
|
||||
|
||||
//R<>cup<75>re le gestionnaire d'articles
|
||||
try
|
||||
{
|
||||
//
|
||||
// R<>cup<75>re les articles depuis la base
|
||||
//
|
||||
this.gestArts = com.gestionnaires.GestionnaireArticles.getInstanceUnique();
|
||||
|
||||
//R<>cup<75>re la liste des articles (filtr<74>s)
|
||||
vArts = this.gestArts.donnerListeArticles(sCondReqSQL);
|
||||
//R<>cup<75>re la liste des articles
|
||||
vCats = this.gestArts.donnerListeCategories("");
|
||||
vCats.add(0, new Categorie(-1, "Toutes categories"));
|
||||
|
||||
if (!vArts.isEmpty())
|
||||
{
|
||||
request.setAttribute("categories", vCats);
|
||||
request.setAttribute("articles", vArts);
|
||||
|
||||
sPageAffichage = "/listeArticles.jsp";
|
||||
}
|
||||
else
|
||||
{
|
||||
sPageAffichage = "/listeArticlesVide.jsp";
|
||||
}
|
||||
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Vector<Erreur> vErrs = new Vector<Erreur>();
|
||||
vErrs.add(new Erreur(ex.getMessage()));
|
||||
request.setAttribute("erreurs", vErrs);
|
||||
|
||||
sPageAffichage = "/erreurs.jsp";
|
||||
}
|
||||
|
||||
ServletContext ctx = getServletContext();
|
||||
RequestDispatcher rd = ctx.getRequestDispatcher(sPageAffichage);
|
||||
rd.forward(request,response);
|
||||
}
|
||||
|
||||
// <editor-fold defaultstate="collapsed" desc="HttpServlet methods. Click on the + sign on the left to edit the code.">
|
||||
/** Handles the HTTP <code>GET</code> method.
|
||||
* @param request servlet request
|
||||
* @param response servlet response
|
||||
*/
|
||||
protected void doGet(HttpServletRequest request, HttpServletResponse response)
|
||||
throws ServletException, IOException
|
||||
{
|
||||
this.affArticles(request, response);
|
||||
}
|
||||
|
||||
/** Handles the HTTP <code>POST</code> method.
|
||||
* @param request servlet request
|
||||
* @param response servlet response
|
||||
*/
|
||||
protected void doPost(HttpServletRequest request, HttpServletResponse response)
|
||||
throws ServletException, IOException
|
||||
{
|
||||
this.affArticles(request, response);
|
||||
}
|
||||
|
||||
/** Returns a short description of the servlet.
|
||||
*/
|
||||
public String getServletInfo() {
|
||||
return "Gestion de articles";
|
||||
}
|
||||
// </editor-fold>
|
||||
}
|
@ -0,0 +1,187 @@
|
||||
/*
|
||||
* Panier.java
|
||||
*
|
||||
* Created on 11 janvier 2008, 15:06
|
||||
*/
|
||||
|
||||
package com.servlets;
|
||||
|
||||
import java.io.*;
|
||||
|
||||
import javax.servlet.*;
|
||||
import javax.servlet.http.*;
|
||||
|
||||
import java.util.Vector;
|
||||
import com.articles.Article;
|
||||
import com.articles.Panier;
|
||||
import com.articles.Client;
|
||||
import com.gestionnaires.Erreur;
|
||||
import com.gestionnaires.GestionnairePanier;
|
||||
|
||||
/**
|
||||
* Servlet G<>rant l'affichage des commandes d'un client.<br>
|
||||
* - payement et confirmation de payement.
|
||||
* @author 3fvorillion
|
||||
* @version
|
||||
*/
|
||||
public class ClientServlet
|
||||
extends HttpServlet
|
||||
{
|
||||
com.gestionnaires.GestionnaireArticles gestArts = null;
|
||||
|
||||
/**
|
||||
* Traite les messages et affiche en cons<6E>quence.
|
||||
* @param request
|
||||
* @param response
|
||||
* @throws ServletException
|
||||
* @throws IOException
|
||||
*/
|
||||
private void affPayement(HttpServletRequest request, HttpServletResponse response)
|
||||
throws ServletException, IOException
|
||||
{
|
||||
GestionnairePanier panier = null;
|
||||
Vector<Erreur> vErrs = new Vector<Erreur>();
|
||||
Vector<Article> vArts = null;
|
||||
Client cli = null;
|
||||
String sAction;
|
||||
String sPageAffichage;
|
||||
|
||||
//
|
||||
// R<>cup<75>re l'objet de la session
|
||||
//
|
||||
panier = PanierServlet.getPanierSession(request);
|
||||
|
||||
//
|
||||
// Traite les actions
|
||||
//
|
||||
sAction = request.getParameter("action");
|
||||
if (sAction == null)
|
||||
{ ; }
|
||||
else if (sAction.equals("payer"))
|
||||
{
|
||||
cli = new Client();
|
||||
|
||||
//R<>cup<75>re les infos de l'utilisateur
|
||||
if (request.getParameter("nomCli") != null)
|
||||
{
|
||||
if (!request.getParameter("nomCli").equals(""))
|
||||
cli.setNom(request.getParameter("nomCli"));
|
||||
else
|
||||
vErrs.add(new Erreur("Votre nom n'est pas saisi."));
|
||||
}
|
||||
else
|
||||
vErrs.add(new Erreur("Le nom du client n'est pas disponible."));
|
||||
|
||||
if (request.getParameter("prenomCli") != null)
|
||||
{
|
||||
if (!request.getParameter("prenomCli").equals(""))
|
||||
cli.setPrenom(request.getParameter("prenomCli"));
|
||||
else
|
||||
vErrs.add(new Erreur("Votre prenom n'est pas saisi."));
|
||||
}
|
||||
else
|
||||
vErrs.add(new Erreur("Le prenom du client n'est pas disponible."));
|
||||
|
||||
if (request.getParameter("addrCli") != null)
|
||||
{
|
||||
if (!request.getParameter("addrCli").equals(""))
|
||||
cli.setAdresse(request.getParameter("addrCli"));
|
||||
else
|
||||
vErrs.add(new Erreur("Votre adresse n'est pas saisi."));
|
||||
}
|
||||
else
|
||||
vErrs.add(new Erreur("L'adresse du client n'est pas disponible."));
|
||||
|
||||
if (request.getParameter("cpCli") != null)
|
||||
{
|
||||
if (!request.getParameter("cpCli").equals(""))
|
||||
cli.setCodePost(request.getParameter("cpCli"));
|
||||
else
|
||||
vErrs.add(new Erreur("Votre code postal n'est pas saisi."));
|
||||
}
|
||||
else
|
||||
vErrs.add(new Erreur("Le code postal du client n'est pas disponible."));
|
||||
|
||||
if (request.getParameter("villeCli") != null)
|
||||
{
|
||||
if (!request.getParameter("villeCli").equals(""))
|
||||
cli.setVille(request.getParameter("villeCli"));
|
||||
else
|
||||
vErrs.add(new Erreur("Votre ville n'est pas saisi."));
|
||||
}
|
||||
else
|
||||
vErrs.add(new Erreur("La ville du client n'est pas disponible."));
|
||||
}
|
||||
|
||||
if (vErrs.isEmpty())
|
||||
{
|
||||
//
|
||||
// Affiche la liste des articles du panier
|
||||
//
|
||||
//R<>cup<75>re la liste des articles
|
||||
vArts = panier.donneContenu();
|
||||
|
||||
if (!vArts.isEmpty())
|
||||
{
|
||||
request.setAttribute("articles", vArts);
|
||||
request.setAttribute("panierTotal", new Panier(panier.getPrixTotalPanier()));
|
||||
|
||||
//V<>rifie si on a d<>j<EFBFBD> saisi les infos client
|
||||
if (cli != null)
|
||||
{
|
||||
request.setAttribute("client", cli);
|
||||
|
||||
sPageAffichage = "/resultPayement.jsp";
|
||||
|
||||
//Signale que le panier est pr<70>t <20> <20>tre supprim<69>
|
||||
panier.setEstPaye(true);
|
||||
}
|
||||
else
|
||||
sPageAffichage = "/payement.jsp";
|
||||
}
|
||||
else
|
||||
{
|
||||
sPageAffichage = "/panierVide.jsp";
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
request.setAttribute("erreurs", vErrs);
|
||||
|
||||
sPageAffichage = "/erreurs.jsp";
|
||||
}
|
||||
|
||||
|
||||
ServletContext ctx = getServletContext();
|
||||
RequestDispatcher rd = ctx.getRequestDispatcher(sPageAffichage);
|
||||
rd.forward(request,response);
|
||||
}
|
||||
|
||||
// <editor-fold defaultstate="collapsed" desc="HttpServlet methods. Click on the + sign on the left to edit the code.">
|
||||
/** Handles the HTTP <code>GET</code> method.
|
||||
* @param request servlet request
|
||||
* @param response servlet response
|
||||
*/
|
||||
protected void doGet(HttpServletRequest request, HttpServletResponse response)
|
||||
throws ServletException, IOException
|
||||
{
|
||||
this.affPayement(request, response);
|
||||
}
|
||||
|
||||
/** Handles the HTTP <code>POST</code> method.
|
||||
* @param request servlet request
|
||||
* @param response servlet response
|
||||
*/
|
||||
protected void doPost(HttpServletRequest request, HttpServletResponse response)
|
||||
throws ServletException, IOException
|
||||
{
|
||||
this.affPayement(request, response);
|
||||
}
|
||||
|
||||
/** Returns a short description of the servlet.
|
||||
*/
|
||||
public String getServletInfo() {
|
||||
return "Gestion du client";
|
||||
}
|
||||
// </editor-fold>
|
||||
}
|
@ -0,0 +1,228 @@
|
||||
/*
|
||||
* Panier.java
|
||||
*
|
||||
* Created on 11 janvier 2008, 15:06
|
||||
*/
|
||||
|
||||
package com.servlets;
|
||||
|
||||
import java.io.*;
|
||||
|
||||
import javax.servlet.*;
|
||||
import javax.servlet.http.*;
|
||||
|
||||
import java.lang.*;
|
||||
import java.util.Vector;
|
||||
import com.articles.Article;
|
||||
import com.articles.Panier;
|
||||
import com.gestionnaires.Erreur;
|
||||
import com.gestionnaires.GestionnairePanier;
|
||||
|
||||
/**
|
||||
* Servlet G<>rant l'affichage des articles du panier.<br>
|
||||
* - affichage des articles et de leurs caract<63>ristiques.
|
||||
* - modification des quantit<69>s.
|
||||
* - suppression des articles du panier.
|
||||
* @author 3fvorillion
|
||||
* @version
|
||||
*/
|
||||
public class PanierServlet
|
||||
extends HttpServlet
|
||||
{
|
||||
com.gestionnaires.GestionnaireArticles gestArts = null;
|
||||
|
||||
/**
|
||||
* R<>cup<75>re le panier courant de la session courante.<br>
|
||||
* Si pas de panier disponibles, en cr<63><72> un.<br>
|
||||
* Si le painier courant en d<>j<EFBFBD> pay<61>, en cr<63><72> un autre.
|
||||
* @param request requete du servlet
|
||||
* @return le panier courant de la session
|
||||
*/
|
||||
public static GestionnairePanier getPanierSession(HttpServletRequest request)
|
||||
{
|
||||
HttpSession session = request.getSession(true);
|
||||
|
||||
//
|
||||
// R<>cup<75>re l'objet de la session
|
||||
//
|
||||
GestionnairePanier panier = (GestionnairePanier)session.getAttribute("caddy");
|
||||
if ( panier == null )
|
||||
{
|
||||
panier = new GestionnairePanier();
|
||||
panier.setEstPaye(false);
|
||||
|
||||
session.setAttribute("caddy", panier) ;
|
||||
}
|
||||
else if ( panier.getEstPaye() )
|
||||
{
|
||||
//Supprime l'ancien de la liste de la session
|
||||
session.removeAttribute("caddy") ;
|
||||
|
||||
//Cr<43><72> un nouveau
|
||||
panier = new GestionnairePanier();
|
||||
panier.setEstPaye(false);
|
||||
|
||||
session.setAttribute("caddy", panier) ;
|
||||
}
|
||||
|
||||
|
||||
return panier;
|
||||
}
|
||||
|
||||
/**
|
||||
* Traite les messages et affiche en cons<6E>quence.
|
||||
* @param request
|
||||
* @param response
|
||||
* @throws ServletException
|
||||
* @throws IOException
|
||||
*/
|
||||
private void affArticlesPanier(HttpServletRequest request, HttpServletResponse response)
|
||||
throws ServletException, IOException
|
||||
{
|
||||
GestionnairePanier panier = null;
|
||||
Vector<Article> vArts = null;
|
||||
String sAction;
|
||||
String sPageAffichage;
|
||||
String sCondReqSQL;
|
||||
|
||||
//
|
||||
// R<>cup<75>re l'objet de la session
|
||||
//
|
||||
panier = PanierServlet.getPanierSession(request);
|
||||
|
||||
//
|
||||
// Traite les actions
|
||||
//
|
||||
sAction = request.getParameter("action");
|
||||
if (sAction == null)
|
||||
{ ; }
|
||||
else if (sAction.equals("add"))
|
||||
{
|
||||
if (request.getParameter("artRef") != null)
|
||||
{
|
||||
sCondReqSQL = "REFERENCE = '" + request.getParameter("artRef") + "'";
|
||||
|
||||
//R<>cup<75>re le gestionnaire d'articles
|
||||
try
|
||||
{
|
||||
//
|
||||
// R<>cup<75>re les articles depuis la base
|
||||
//
|
||||
this.gestArts = com.gestionnaires.GestionnaireArticles.getInstanceUnique();
|
||||
|
||||
//R<>cup<75>re la liste des articles
|
||||
vArts = this.gestArts.donnerListeArticles(sCondReqSQL);
|
||||
|
||||
if (vArts.size() == 1)
|
||||
{
|
||||
panier.ajouterAchat(vArts.get(0));
|
||||
}
|
||||
else
|
||||
{
|
||||
Vector<Erreur> vErrs = new Vector<Erreur>();
|
||||
if (vArts.isEmpty())
|
||||
vErrs.add(new Erreur("Aucun article n'est disponible dans la boutique"));
|
||||
else
|
||||
vErrs.add(new Erreur("Trop d'articles correspondent <20> la s<>lection"));
|
||||
request.setAttribute("erreurs", vErrs);
|
||||
|
||||
sPageAffichage = "/erreurs.jsp";
|
||||
|
||||
ServletContext ctx = getServletContext();
|
||||
RequestDispatcher rd = ctx.getRequestDispatcher(sPageAffichage);
|
||||
rd.forward(request,response);
|
||||
return;
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Vector<Erreur> vErrs = new Vector<Erreur>();
|
||||
vErrs.add(new Erreur(ex.getMessage()));
|
||||
request.setAttribute("erreurs", vErrs);
|
||||
|
||||
sPageAffichage = "/erreurs.jsp";
|
||||
|
||||
ServletContext ctx = getServletContext();
|
||||
RequestDispatcher rd = ctx.getRequestDispatcher(sPageAffichage);
|
||||
rd.forward(request,response);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (sAction.equals("del"))
|
||||
{
|
||||
if (request.getParameter("artRef") != null)
|
||||
panier.enleverAchat(request.getParameter("artRef"));
|
||||
}
|
||||
else if (sAction.equals("modif"))
|
||||
{
|
||||
//R<>cup<75>re la liste des articles
|
||||
vArts = panier.donneContenu();
|
||||
|
||||
for (int i=0;i<vArts.size(); i++)
|
||||
if (request.getParameter(vArts.get(i).getRef()) != null)
|
||||
panier.modifieAchat(vArts.get(i).getRef(),
|
||||
Integer.parseInt(request.getParameter(vArts.get(i).getRef())));
|
||||
}
|
||||
|
||||
//
|
||||
// Affiche la liste des articles du panier
|
||||
//
|
||||
//R<>cup<75>re la liste des articles
|
||||
vArts = panier.donneContenu();
|
||||
|
||||
if (!vArts.isEmpty())
|
||||
{
|
||||
request.setAttribute("articles", vArts);
|
||||
request.setAttribute("panierTotal", new Panier(panier.getPrixTotalPanier()));
|
||||
|
||||
//Si on valide, on affiche le r<>sum<75> (affichage normal, sans modification)
|
||||
if (sAction != null)
|
||||
{
|
||||
if (sAction.equals("valider"))
|
||||
sPageAffichage = "/resumePanier.jsp";
|
||||
else
|
||||
sPageAffichage = "/contenuPanier.jsp";
|
||||
}
|
||||
//Sinon, on affiche le panier et on permet la modification des quantit<69>s
|
||||
else
|
||||
sPageAffichage = "/contenuPanier.jsp";
|
||||
}
|
||||
else
|
||||
{
|
||||
sPageAffichage = "/panierVide.jsp";
|
||||
}
|
||||
|
||||
ServletContext ctx = getServletContext();
|
||||
RequestDispatcher rd = ctx.getRequestDispatcher(sPageAffichage);
|
||||
rd.forward(request,response);
|
||||
}
|
||||
|
||||
// <editor-fold defaultstate="collapsed" desc="HttpServlet methods. Click on the + sign on the left to edit the code.">
|
||||
/** Handles the HTTP <code>GET</code> method.
|
||||
* @param request servlet request
|
||||
* @param response servlet response
|
||||
*/
|
||||
protected void doGet(HttpServletRequest request, HttpServletResponse response)
|
||||
throws ServletException, IOException
|
||||
{
|
||||
this.affArticlesPanier(request, response);
|
||||
}
|
||||
|
||||
/** Handles the HTTP <code>POST</code> method.
|
||||
* @param request servlet request
|
||||
* @param response servlet response
|
||||
*/
|
||||
protected void doPost(HttpServletRequest request, HttpServletResponse response)
|
||||
throws ServletException, IOException
|
||||
{
|
||||
this.affArticlesPanier(request, response);
|
||||
}
|
||||
|
||||
/** Returns a short description of the servlet.
|
||||
*/
|
||||
public String getServletInfo() {
|
||||
return "Gestion du panier";
|
||||
}
|
||||
// </editor-fold>
|
||||
}
|
50
P51/apache-tomcat-6.0.14/webapps/RandoOnLine/WEB-INF/web.xml
Normal file
@ -0,0 +1,50 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
|
||||
<context-param>
|
||||
<param-name>com.sun.faces.verifyObjects</param-name>
|
||||
<param-value>false</param-value>
|
||||
</context-param>
|
||||
<context-param>
|
||||
<param-name>com.sun.faces.validateXml</param-name>
|
||||
<param-value>true</param-value>
|
||||
</context-param>
|
||||
<context-param>
|
||||
<param-name>javax.faces.STATE_SAVING_METHOD</param-name>
|
||||
<param-value>client</param-value>
|
||||
</context-param>
|
||||
<servlet>
|
||||
<servlet-name>PanierServlet</servlet-name>
|
||||
<servlet-class>com.servlets.PanierServlet</servlet-class>
|
||||
</servlet>
|
||||
<servlet-mapping>
|
||||
<servlet-name>PanierServlet</servlet-name>
|
||||
<url-pattern>/Panier</url-pattern>
|
||||
</servlet-mapping>
|
||||
<servlet>
|
||||
<servlet-name>ArticlesServlet</servlet-name>
|
||||
<servlet-class>com.servlets.ArticlesServlet</servlet-class>
|
||||
</servlet>
|
||||
<servlet-mapping>
|
||||
<servlet-name>ArticlesServlet</servlet-name>
|
||||
<url-pattern>/Articles</url-pattern>
|
||||
</servlet-mapping>
|
||||
<servlet>
|
||||
<servlet-name>ClientServlet</servlet-name>
|
||||
<servlet-class>com.servlets.ClientServlet</servlet-class>
|
||||
</servlet>
|
||||
<servlet-mapping>
|
||||
<servlet-name>ClientServlet</servlet-name>
|
||||
<url-pattern>/Client</url-pattern>
|
||||
</servlet-mapping>
|
||||
<session-config>
|
||||
<session-timeout>
|
||||
30
|
||||
</session-timeout>
|
||||
</session-config>
|
||||
<welcome-file-list>
|
||||
<welcome-file>
|
||||
index.jsp
|
||||
</welcome-file>
|
||||
</welcome-file-list>
|
||||
|
||||
</web-app>
|
@ -0,0 +1,87 @@
|
||||
<%@page contentType="text/html" %>
|
||||
<%@page pageEncoding="UTF-8" %>
|
||||
<%@page language="java" %>
|
||||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
|
||||
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
|
||||
"http://www.w3.org/TR/html4/loose.dtd">
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<link rel="stylesheet" href="style.css" type="text/css" />
|
||||
<title>RandoOnLine - Contenu du Panier</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h1>RandoOnLine</h1>
|
||||
<table border="0" width="100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><a href="./index.jsp">Accueil</a></th>
|
||||
<th>Panier</th>
|
||||
<th><a href="./Articles">Liste des articles</a></th>
|
||||
<th><a href="./Panier?action=valider">Passer <20> la caisse</a></th>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
|
||||
<h2>Contenu du Panier</h2>
|
||||
|
||||
<form method="post" action="./Panier">
|
||||
<table border="0" width="100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Aper<65>u</th>
|
||||
<th>Propri<72>t<EFBFBD>s</th>
|
||||
<th>Quantit<69></th>
|
||||
<th>Action</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<c:forEach items="${articles}" var="artRef" >
|
||||
<tr>
|
||||
<td>
|
||||
<img src="./img/${artRef.photo}" width="50" height="50" alt="image"/>
|
||||
</td>
|
||||
<td>
|
||||
<table border="0" width="100%" height="100%">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>Référence : ${artRef.ref}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Marque : ${artRef.marque}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Modèle : ${artRef.modele}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Prix : ${artRef.prix}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</td>
|
||||
<td>
|
||||
<input type="text" id="${artRef.ref}" name="${artRef.ref}" maxLength="3" size="3" value="${artRef.quantite}" />
|
||||
</td>
|
||||
<td>
|
||||
<a href="./Panier?action=del&artRef=${artRef.ref}">enlever</a>
|
||||
</td>
|
||||
</tr>
|
||||
</c:forEach>
|
||||
<tr>
|
||||
<td colspan="3" class="tabTotal">Total :</td>
|
||||
<td>
|
||||
<jsp:useBean id="panierTotal" class="com.articles.Panier" scope="request" />
|
||||
<jsp:getProperty name="panierTotal" property="prixTotal" />
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<br />
|
||||
<input type="hidden" name="action" value="modif" />
|
||||
<input type="submit" value="Recalculer">
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
39
P51/apache-tomcat-6.0.14/webapps/RandoOnLine/erreurs.jsp
Normal file
@ -0,0 +1,39 @@
|
||||
<%@page contentType="text/html" %>
|
||||
<%@page pageEncoding="UTF-8" %>
|
||||
<%@page language="java" %>
|
||||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
|
||||
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
|
||||
"http://www.w3.org/TR/html4/loose.dtd">
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<link rel="stylesheet" href="style.css" type="text/css" />
|
||||
<title>RandoOnLine - Erreurs</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h1>RandoOnLine</h1>
|
||||
<table border="0" width="100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><a href="./index.jsp">Accueil</a></th>
|
||||
<th><a href="./Panier">Panier</a></th>
|
||||
<th><a href="./Articles">Liste des articles</a></th>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
|
||||
<h2>Les erreurs suivantes se sont produites : </h2>
|
||||
<ul>
|
||||
<c:forEach items="${erreurs}" var="err" >
|
||||
<li>
|
||||
${err.message}
|
||||
</li>
|
||||
</c:forEach>
|
||||
</ul>
|
||||
|
||||
<p><a href="./index.jsp">Accueil</a></p>
|
||||
</body>
|
||||
</html>
|
BIN
P51/apache-tomcat-6.0.14/webapps/RandoOnLine/img/arva9000.jpg
Normal file
After Width: | Height: | Size: 4.3 KiB |
BIN
P51/apache-tomcat-6.0.14/webapps/RandoOnLine/img/baton.jpg
Normal file
After Width: | Height: | Size: 5.0 KiB |
BIN
P51/apache-tomcat-6.0.14/webapps/RandoOnLine/img/gps.jpg
Normal file
After Width: | Height: | Size: 3.2 KiB |
After Width: | Height: | Size: 4.4 KiB |
After Width: | Height: | Size: 3.8 KiB |
After Width: | Height: | Size: 3.6 KiB |
After Width: | Height: | Size: 3.0 KiB |
After Width: | Height: | Size: 2.8 KiB |
BIN
P51/apache-tomcat-6.0.14/webapps/RandoOnLine/img/lafuma_neve.jpg
Normal file
After Width: | Height: | Size: 2.5 KiB |
After Width: | Height: | Size: 2.9 KiB |
BIN
P51/apache-tomcat-6.0.14/webapps/RandoOnLine/img/marechal_4P.jpg
Normal file
After Width: | Height: | Size: 4.1 KiB |
After Width: | Height: | Size: 4.0 KiB |
BIN
P51/apache-tomcat-6.0.14/webapps/RandoOnLine/img/nic_impex.jpg
Normal file
After Width: | Height: | Size: 4.0 KiB |
After Width: | Height: | Size: 3.0 KiB |
20
P51/apache-tomcat-6.0.14/webapps/RandoOnLine/index.jsp
Normal file
@ -0,0 +1,20 @@
|
||||
<%@page contentType="text/html"%>
|
||||
<%@page pageEncoding="UTF-8"%>
|
||||
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
|
||||
"http://www.w3.org/TR/html4/loose.dtd">
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<link rel="stylesheet" href="style.css" type="text/css" />
|
||||
<title>RandoOnLine</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h1>RandoOnLine</h1>
|
||||
<br/>
|
||||
<a href="./Articles">Afficher les articles</a>
|
||||
|
||||
</body>
|
||||
</html>
|
69
P51/apache-tomcat-6.0.14/webapps/RandoOnLine/infos.jsp
Normal file
@ -0,0 +1,69 @@
|
||||
<%@page contentType="text/html" %>
|
||||
<%@page pageEncoding="UTF-8" %>
|
||||
<%@page language="java" %>
|
||||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
|
||||
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
|
||||
"http://www.w3.org/TR/html4/loose.dtd">
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<link rel="stylesheet" href="style.css" type="text/css" />
|
||||
<title>RandoOnLine - Infos</title>
|
||||
</head>
|
||||
<body>
|
||||
<jsp:useBean id="article" class="com.articles.Article" scope="request" />
|
||||
|
||||
<h2>Infos sur l'article</h2>
|
||||
<table border="0" width="100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Aper<65>u</th>
|
||||
<th>Propri<72>t<EFBFBD>s</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>
|
||||
<img src="./img/<jsp:getProperty name="art" property="photo" />" width="50" height="50" alt="image"/>
|
||||
</td>
|
||||
<td>
|
||||
<table border="0" width="100%" height="100%">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>Référence :
|
||||
<jsp:getProperty name="art" property="ref" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Marque :
|
||||
<jsp:getProperty name="art" property="marque" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Modèle :
|
||||
<jsp:getProperty name="art" property="modele" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Description :
|
||||
<jsp:getProperty name="art" property="description" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Prix :
|
||||
<jsp:getProperty name="art" property="prix" /></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<hr width="100%" size="1">
|
||||
<h2>Acheter l'article</h2>
|
||||
<form method="post" action="./Panier?action=add">
|
||||
<input type="hidden" id="ref" name="ref" value="<jsp:getProperty name="art" property="ref" />">
|
||||
Quantit<69> :<br />
|
||||
<input type="text" id="txtQte" name="txtQte" maxLength="3" size="3" /><br />
|
||||
<input type="submit" value="Acheter">
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
@ -0,0 +1,83 @@
|
||||
<%@page contentType="text/html" %>
|
||||
<%@page pageEncoding="UTF-8" %>
|
||||
<%@page language="java" %>
|
||||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
|
||||
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
|
||||
"http://www.w3.org/TR/html4/loose.dtd">
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<link rel="stylesheet" href="style.css" type="text/css" />
|
||||
<title>RandoOnLine - Articles disponibles</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h1>RandoOnLine</h1>
|
||||
<table border="0" width="100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><a href="./index.jsp">Accueil</a></th>
|
||||
<th><a href="./Panier">Panier</a></th>
|
||||
<th>Liste des articles</th>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
|
||||
<h2>Filtre</h2>
|
||||
<form method="post" action="./Articles">
|
||||
<select id="lstCategs" name="lstCategs" size="1">
|
||||
<c:forEach items="${categories}" var="categ" >
|
||||
<option value="${categ.id}">${categ.cat}</option>
|
||||
</c:forEach>
|
||||
</select>
|
||||
<input type="submit" value="Appliquer le filtre">
|
||||
</form>
|
||||
|
||||
<h2>Liste des articles disponibles</h2>
|
||||
<table border="0" width="100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Aper<65>u</th>
|
||||
<th>Propri<72>t<EFBFBD>s</th>
|
||||
<th>Action</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<c:forEach items="${articles}" var="artRef" >
|
||||
<tr>
|
||||
<td>
|
||||
<img src="./img/${artRef.photo}" width="50" height="50" alt="image"/>
|
||||
</td>
|
||||
<td>
|
||||
<table border="0" width="100%" height="100%">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>Référence : ${artRef.ref}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Marque : ${artRef.marque}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Modèle : ${artRef.modele}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Description : ${artRef.description}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Prix : ${artRef.prix}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</td>
|
||||
<td>
|
||||
<a href="./Panier?action=add&artRef=${artRef.ref}">ajouter au panier</a>
|
||||
</td>
|
||||
</tr>
|
||||
</c:forEach>
|
||||
</tbody>
|
||||
</table>
|
||||
</body>
|
||||
</HTML>
|
||||
|
@ -0,0 +1,31 @@
|
||||
<%@page contentType="text/html" %>
|
||||
<%@page pageEncoding="UTF-8" %>
|
||||
<%@page language="java" %>
|
||||
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
|
||||
"http://www.w3.org/TR/html4/loose.dtd">
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<link rel="stylesheet" href="style.css" type="text/css" />
|
||||
<title>RandoOnLine - Articles disponibles</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>RandoOnLine</h1>
|
||||
<table border="0" width="100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><a href="./index.jsp">Accueil</a></th>
|
||||
<th><a href="./Panier">Panier</a></th>
|
||||
<th>Liste des articles</th>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
|
||||
<h2>Liste des articles disponibles</h2>
|
||||
<P>Nous somme actuellement en rupture de stock !</P>
|
||||
<P>Nous serons livr<76> tr<74>s prochainement.</P>
|
||||
<a href="./index.jsp">Accueil</a>
|
||||
</body>
|
||||
</html>
|
30
P51/apache-tomcat-6.0.14/webapps/RandoOnLine/panierVide.jsp
Normal file
@ -0,0 +1,30 @@
|
||||
<%@page contentType="text/html" %>
|
||||
<%@page pageEncoding="UTF-8" %>
|
||||
<%@page language="java" %>
|
||||
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
|
||||
"http://www.w3.org/TR/html4/loose.dtd">
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<link rel="stylesheet" href="style.css" type="text/css" />
|
||||
<title>RandoOnLine - Contenu du Panier</title>
|
||||
</head>
|
||||
<body>
|
||||
<h1>RandoOnLine</h1>
|
||||
<table border="0" width="100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><a href="./index.jsp">Accueil</a></th>
|
||||
<th>Panier</th>
|
||||
<th><a href="./Articles">Liste des articles</a></th>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
|
||||
<h2>Contenu de votre panier</h2>
|
||||
<P>Votre panier est vide</P>
|
||||
<a href="./Articles">Continuez vos achats</a>
|
||||
</body>
|
||||
</html>
|
97
P51/apache-tomcat-6.0.14/webapps/RandoOnLine/payement.jsp
Normal file
@ -0,0 +1,97 @@
|
||||
<%@page contentType="text/html" %>
|
||||
<%@page pageEncoding="UTF-8" %>
|
||||
<%@page language="java" %>
|
||||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
|
||||
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
|
||||
"http://www.w3.org/TR/html4/loose.dtd">
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<link rel="stylesheet" href="style.css" type="text/css" />
|
||||
<title>RandoOnLine - Payement</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h1>RandoOnLine</h1>
|
||||
<table border="0" width="100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><a href="./index.jsp">Accueil</a></th>
|
||||
<th><a href="./Panier">Panier</a></th>
|
||||
<th><a href="./Articles">Liste des articles</a></th>
|
||||
<th>Passer <20> la caisse</th>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
|
||||
<h2>Payement</h2>
|
||||
|
||||
<p>Rappel de la commande :</p>
|
||||
<table border="0" width="100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Reference</th>
|
||||
<th>Modele</th>
|
||||
<th>Prix</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<c:forEach items="${articles}" var="artRef" >
|
||||
<tr>
|
||||
<td>
|
||||
Référence : ${artRef.ref}
|
||||
</td>
|
||||
<td>
|
||||
Modèle : ${artRef.modele}
|
||||
</td>
|
||||
<td>
|
||||
Prix : ${artRef.prix}
|
||||
</td>
|
||||
</tr>
|
||||
</c:forEach>
|
||||
<tr>
|
||||
<td colspan="2" class="tabTotal">Total :</td>
|
||||
<td>
|
||||
<jsp:useBean id="panierTotal" class="com.articles.Panier" scope="request" />
|
||||
<jsp:getProperty name="panierTotal" property="prixTotal" />
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<hr width="100%" size="1">
|
||||
|
||||
<form method="post" action="./Client">
|
||||
<table border="0">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>Nom :</td>
|
||||
<td><input type="text" id="nomCli" name="nomCli" size="10" value="" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Pr<50>nom :</td>
|
||||
<td><input type="text" id="prenomCli" name="prenomCli" size="10" value="" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Adresse :</td>
|
||||
<td><input type="text" id="addrCli" name="addrCli" size="10" value="" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Code postal :</td>
|
||||
<td><input type="text" id="cpCli" name="cpCli" size="10" value="" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Ville :</td>
|
||||
<td><input type="text" id="villeCli" name="villeCli" size="10" value="" /></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<p>Note : le payement se fera <20> la livraison de la commande.</p>
|
||||
<input type="hidden" name="action" value="payer" />
|
||||
<input type="button" value="Annuler" onclick="javascript:document.location='./Articles'" />
|
||||
<input type="submit" value="Payer" />
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
@ -0,0 +1,75 @@
|
||||
<%@page contentType="text/html" %>
|
||||
<%@page pageEncoding="UTF-8" %>
|
||||
<%@page language="java" %>
|
||||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
|
||||
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
|
||||
"http://www.w3.org/TR/html4/loose.dtd">
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<link rel="stylesheet" href="style.css" type="text/css" />
|
||||
<title>RandoOnLine - Payement</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h1>RandoOnLine</h1>
|
||||
<table border="0" width="100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><a href="./index.jsp">Accueil</a></th>
|
||||
<th><a href="./Panier">Panier</a></th>
|
||||
<th><a href="./Articles">Liste des articles</a></th>
|
||||
<th>Passer <20> la caisse</th>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
|
||||
<h2>Confirmation de la commande</h2>
|
||||
|
||||
<p>Rappel de la commande :</p>
|
||||
<table border="0" width="100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Reference</th>
|
||||
<th>Modele</th>
|
||||
<th>Prix</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<c:forEach items="${articles}" var="artRef" >
|
||||
<tr>
|
||||
<td>
|
||||
Référence : ${artRef.ref}
|
||||
</td>
|
||||
<td>
|
||||
Modèle : ${artRef.modele}
|
||||
</td>
|
||||
<td>
|
||||
Prix : ${artRef.prix}
|
||||
</td>
|
||||
</tr>
|
||||
</c:forEach>
|
||||
<tr>
|
||||
<td colspan="2" class="tabTotal">Total :</td>
|
||||
<td>
|
||||
<jsp:useBean id="panierTotal" class="com.articles.Panier" scope="request" />
|
||||
<jsp:getProperty name="panierTotal" property="prixTotal" />
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<hr width="100%" size="1">
|
||||
|
||||
<jsp:useBean id="client" class="com.articles.Client" scope="request" />
|
||||
<p>Note : le payement se fera <20> la livraison de la commande <20> l'adresse suivante :<br />
|
||||
<jsp:getProperty name="client" property="nom" /> <jsp:getProperty name="client" property="prenom" /><br />
|
||||
<jsp:getProperty name="client" property="adresse" /><br />
|
||||
<jsp:getProperty name="client" property="codePost" /> <jsp:getProperty name="client" property="ville" />
|
||||
</p>
|
||||
|
||||
<p><a href="./index.jsp">Accueil</a></p>
|
||||
</body>
|
||||
</html>
|
@ -0,0 +1,83 @@
|
||||
<%@page contentType="text/html" %>
|
||||
<%@page pageEncoding="UTF-8" %>
|
||||
<%@page language="java" %>
|
||||
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
|
||||
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
|
||||
"http://www.w3.org/TR/html4/loose.dtd">
|
||||
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
|
||||
<link rel="stylesheet" href="style.css" type="text/css" />
|
||||
<title>RandoOnLine - Resume du Panier</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h1>RandoOnLine</h1>
|
||||
<table border="0" width="100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><a href="./index.jsp">Accueil</a></th>
|
||||
<th><a href="./Panier">Panier</a></th>
|
||||
<th><a href="./Articles">Liste des articles</a></th>
|
||||
<th>Passer <20> la caisse</th>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
|
||||
<h2>Contenu du Panier</h2>
|
||||
|
||||
<form method="post" action="./Client">
|
||||
<table border="0" width="100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>Aper<65>u</th>
|
||||
<th>Propri<72>t<EFBFBD>s</th>
|
||||
<th>Quantit<69></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<c:forEach items="${articles}" var="artRef" >
|
||||
<tr>
|
||||
<td>
|
||||
<img src="./img/${artRef.photo}" width="50" height="50" alt="image"/>
|
||||
</td>
|
||||
<td>
|
||||
<table border="0" width="100%" height="100%">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>Référence : ${artRef.ref}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Marque : ${artRef.marque}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Modèle : ${artRef.modele}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Prix : ${artRef.prix}</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</td>
|
||||
<td>
|
||||
${artRef.quantite}
|
||||
</td>
|
||||
</tr>
|
||||
</c:forEach>
|
||||
<tr>
|
||||
<td colspan="2" class="tabTotal">Total :</td>
|
||||
<td>
|
||||
<jsp:useBean id="panierTotal" class="com.articles.Panier" scope="request" />
|
||||
<jsp:getProperty name="panierTotal" property="prixTotal" />
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<br />
|
||||
<input type="button" value="Annuler" onclick="javascript:document.location='./Articles'" />
|
||||
<input type="submit" value="Valider" />
|
||||
</form>
|
||||
</body>
|
||||
</html>
|
67
P51/apache-tomcat-6.0.14/webapps/RandoOnLine/style.css
Normal file
@ -0,0 +1,67 @@
|
||||
body {
|
||||
min-width: 610px;
|
||||
color: #222233;
|
||||
font-family : Verdana, Arial, Helvetica, sans-serif;
|
||||
}
|
||||
|
||||
h1 {
|
||||
padding-bottom:0.2em;
|
||||
padding-top:0.2em;
|
||||
padding-left:0.2em;
|
||||
background-color: #dfe5ea;
|
||||
margin: 2px 2px 2px 2px;
|
||||
border: 1px solid #B7D6E3;
|
||||
font-size: 14px;
|
||||
color: #144b8a;
|
||||
}
|
||||
|
||||
|
||||
h2 {
|
||||
margin-top:1em;
|
||||
padding-bottom:0.2em;
|
||||
border-bottom: 1px solid #ccc;
|
||||
font-size: 12px;
|
||||
color: #36628A;
|
||||
}
|
||||
|
||||
h3 {
|
||||
font-size: 12px;
|
||||
color: #7799D0;
|
||||
}
|
||||
|
||||
h4 {
|
||||
font-size: 10px;
|
||||
font-weight: bold;
|
||||
color: #000000;
|
||||
}
|
||||
|
||||
p {
|
||||
text-align: justify;
|
||||
font-size: 11px;
|
||||
line-height:150%;
|
||||
}
|
||||
|
||||
table, td {
|
||||
font-family: Verdana, Arial, Helvetica, sans-serif;
|
||||
font-size: 11px;
|
||||
line-height:120%;
|
||||
border-collapse: collapse;
|
||||
border: 1px solid #88aacc;
|
||||
padding: 0.3em
|
||||
}
|
||||
|
||||
td.selected {
|
||||
background-color: #EEDDDD;
|
||||
}
|
||||
td.tabTotal {
|
||||
text-align: right;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
th {
|
||||
font-weight: bold;
|
||||
color: #333377;
|
||||
background-color: #EEEEEE;
|
||||
border: 1px solid #224466;
|
||||
padding: 0.5em
|
||||
}
|
@ -0,0 +1,221 @@
|
||||
package org.apache.jsp;
|
||||
|
||||
import javax.servlet.*;
|
||||
import javax.servlet.http.*;
|
||||
import javax.servlet.jsp.*;
|
||||
|
||||
public final class contenuPanier_jsp extends org.apache.jasper.runtime.HttpJspBase
|
||||
implements org.apache.jasper.runtime.JspSourceDependent {
|
||||
|
||||
private static final JspFactory _jspxFactory = JspFactory.getDefaultFactory();
|
||||
|
||||
private static java.util.List _jspx_dependants;
|
||||
|
||||
private org.apache.jasper.runtime.TagHandlerPool _005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems;
|
||||
|
||||
private javax.el.ExpressionFactory _el_expressionfactory;
|
||||
private org.apache.AnnotationProcessor _jsp_annotationprocessor;
|
||||
|
||||
public Object getDependants() {
|
||||
return _jspx_dependants;
|
||||
}
|
||||
|
||||
public void _jspInit() {
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems = org.apache.jasper.runtime.TagHandlerPool.getTagHandlerPool(getServletConfig());
|
||||
_el_expressionfactory = _jspxFactory.getJspApplicationContext(getServletConfig().getServletContext()).getExpressionFactory();
|
||||
_jsp_annotationprocessor = (org.apache.AnnotationProcessor) getServletConfig().getServletContext().getAttribute(org.apache.AnnotationProcessor.class.getName());
|
||||
}
|
||||
|
||||
public void _jspDestroy() {
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.release();
|
||||
}
|
||||
|
||||
public void _jspService(HttpServletRequest request, HttpServletResponse response)
|
||||
throws java.io.IOException, ServletException {
|
||||
|
||||
PageContext pageContext = null;
|
||||
HttpSession session = null;
|
||||
ServletContext application = null;
|
||||
ServletConfig config = null;
|
||||
JspWriter out = null;
|
||||
Object page = this;
|
||||
JspWriter _jspx_out = null;
|
||||
PageContext _jspx_page_context = null;
|
||||
|
||||
|
||||
try {
|
||||
response.setContentType("text/html;charset=UTF-8");
|
||||
pageContext = _jspxFactory.getPageContext(this, request, response,
|
||||
null, true, 8192, true);
|
||||
_jspx_page_context = pageContext;
|
||||
application = pageContext.getServletContext();
|
||||
config = pageContext.getServletConfig();
|
||||
session = pageContext.getSession();
|
||||
out = pageContext.getOut();
|
||||
_jspx_out = out;
|
||||
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\"\r\n");
|
||||
out.write(" \"http://www.w3.org/TR/html4/loose.dtd\">\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<html>\r\n");
|
||||
out.write(" <head>\r\n");
|
||||
out.write(" <meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\">\r\n");
|
||||
out.write("\t\t<link rel=\"stylesheet\" href=\"style.css\" type=\"text/css\" />\r\n");
|
||||
out.write(" <title>RandoOnLine - Contenu du Panier</title>\r\n");
|
||||
out.write(" </head>\r\n");
|
||||
out.write(" <body>\r\n");
|
||||
out.write("\r\n");
|
||||
out.write(" <h1>RandoOnLine</h1>\r\n");
|
||||
out.write(" <table border=\"0\" width=\"100%\">\r\n");
|
||||
out.write(" <thead>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <th><a href=\"./index.jsp\">Accueil</a></th>\r\n");
|
||||
out.write(" <th>Panier</th>\r\n");
|
||||
out.write(" <th><a href=\"./Articles\">Liste des articles</a></th>\r\n");
|
||||
out.write(" <th><a href=\"./Panier?action=valider\">Passer <20> la caisse</a></th>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </thead>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write(" \r\n");
|
||||
out.write(" <h2>Contenu du Panier</h2>\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\t<form method=\"post\" action=\"./Panier\">\r\n");
|
||||
out.write(" <table border=\"0\" width=\"100%\">\r\n");
|
||||
out.write(" <thead>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <th>Aper<65>u</th>\r\n");
|
||||
out.write(" <th>Propri<72>t<EFBFBD>s</th>\r\n");
|
||||
out.write(" <th>Quantit<69></th>\r\n");
|
||||
out.write(" <th>Action</th>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </thead>\r\n");
|
||||
out.write(" <tbody>\r\n");
|
||||
if (_jspx_meth_c_005fforEach_005f0(_jspx_page_context))
|
||||
return;
|
||||
out.write("\r\n");
|
||||
out.write("\t\t\t<tr>\r\n");
|
||||
out.write(" <td colspan=\"3\" class=\"tabTotal\">Total :</td>\r\n");
|
||||
out.write(" <td>\r\n");
|
||||
com.articles.Panier panierTotal = null;
|
||||
synchronized (request) {
|
||||
panierTotal = (com.articles.Panier) _jspx_page_context.getAttribute("panierTotal", PageContext.REQUEST_SCOPE);
|
||||
if (panierTotal == null){
|
||||
panierTotal = new com.articles.Panier();
|
||||
_jspx_page_context.setAttribute("panierTotal", panierTotal, PageContext.REQUEST_SCOPE);
|
||||
}
|
||||
}
|
||||
out.write("\r\n");
|
||||
out.write("\t\t\t\t\t");
|
||||
out.write(org.apache.jasper.runtime.JspRuntimeLibrary.toString((((com.articles.Panier)_jspx_page_context.findAttribute("panierTotal")).getPrixTotal())));
|
||||
out.write("\r\n");
|
||||
out.write(" </td>\r\n");
|
||||
out.write("\t\t\t</tr>\r\n");
|
||||
out.write(" </tbody>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write(" <br />\r\n");
|
||||
out.write(" <input type=\"hidden\" name=\"action\" value=\"modif\" />\r\n");
|
||||
out.write(" <input type=\"submit\" value=\"Recalculer\">\r\n");
|
||||
out.write("\t</form>\r\n");
|
||||
out.write(" </body>\r\n");
|
||||
out.write("</html>\r\n");
|
||||
} catch (Throwable t) {
|
||||
if (!(t instanceof SkipPageException)){
|
||||
out = _jspx_out;
|
||||
if (out != null && out.getBufferSize() != 0)
|
||||
try { out.clearBuffer(); } catch (java.io.IOException e) {}
|
||||
if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
|
||||
}
|
||||
} finally {
|
||||
_jspxFactory.releasePageContext(_jspx_page_context);
|
||||
}
|
||||
}
|
||||
|
||||
private boolean _jspx_meth_c_005fforEach_005f0(PageContext _jspx_page_context)
|
||||
throws Throwable {
|
||||
PageContext pageContext = _jspx_page_context;
|
||||
JspWriter out = _jspx_page_context.getOut();
|
||||
// c:forEach
|
||||
org.apache.taglibs.standard.tag.rt.core.ForEachTag _jspx_th_c_005fforEach_005f0 = (org.apache.taglibs.standard.tag.rt.core.ForEachTag) _005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.get(org.apache.taglibs.standard.tag.rt.core.ForEachTag.class);
|
||||
_jspx_th_c_005fforEach_005f0.setPageContext(_jspx_page_context);
|
||||
_jspx_th_c_005fforEach_005f0.setParent(null);
|
||||
// /contenuPanier.jsp(42,0) name = items type = java.lang.Object reqTime = true required = false fragment = false deferredValue = false expectedTypeName = null deferredMethod = false methodSignature = null
|
||||
_jspx_th_c_005fforEach_005f0.setItems((java.lang.Object) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${articles}", java.lang.Object.class, (PageContext)_jspx_page_context, null, false));
|
||||
// /contenuPanier.jsp(42,0) name = var type = java.lang.String reqTime = false required = false fragment = false deferredValue = false expectedTypeName = null deferredMethod = false methodSignature = null
|
||||
_jspx_th_c_005fforEach_005f0.setVar("artRef");
|
||||
int[] _jspx_push_body_count_c_005fforEach_005f0 = new int[] { 0 };
|
||||
try {
|
||||
int _jspx_eval_c_005fforEach_005f0 = _jspx_th_c_005fforEach_005f0.doStartTag();
|
||||
if (_jspx_eval_c_005fforEach_005f0 != javax.servlet.jsp.tagext.Tag.SKIP_BODY) {
|
||||
do {
|
||||
out.write("\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>\r\n");
|
||||
out.write(" <img src=\"./img/");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.photo}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("\" width=\"50\" height=\"50\" alt=\"image\"/>\r\n");
|
||||
out.write(" </td>\r\n");
|
||||
out.write(" <td>\r\n");
|
||||
out.write(" <table border=\"0\" width=\"100%\" height=\"100%\">\r\n");
|
||||
out.write(" <tbody>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>Référence : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.ref}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("</td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>Marque : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.marque}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("</td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>Modèle : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.modele}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("</td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>Prix : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.prix}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("</td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </tbody>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write(" </td>\r\n");
|
||||
out.write(" <td>\r\n");
|
||||
out.write(" <input type=\"text\" id=\"");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.ref}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("\" name=\"");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.ref}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("\" maxLength=\"3\" size=\"3\" value=\"");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.quantite}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("\" />\r\n");
|
||||
out.write(" </td>\r\n");
|
||||
out.write(" <td>\r\n");
|
||||
out.write(" <a href=\"./Panier?action=del&artRef=");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.ref}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("\">enlever</a>\r\n");
|
||||
out.write(" </td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
int evalDoAfterBody = _jspx_th_c_005fforEach_005f0.doAfterBody();
|
||||
if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN)
|
||||
break;
|
||||
} while (true);
|
||||
}
|
||||
if (_jspx_th_c_005fforEach_005f0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
|
||||
return true;
|
||||
}
|
||||
} catch (Throwable _jspx_exception) {
|
||||
while (_jspx_push_body_count_c_005fforEach_005f0[0]-- > 0)
|
||||
out = _jspx_page_context.popBody();
|
||||
_jspx_th_c_005fforEach_005f0.doCatch(_jspx_exception);
|
||||
} finally {
|
||||
_jspx_th_c_005fforEach_005f0.doFinally();
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.reuse(_jspx_th_c_005fforEach_005f0);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
@ -0,0 +1,147 @@
|
||||
package org.apache.jsp;
|
||||
|
||||
import javax.servlet.*;
|
||||
import javax.servlet.http.*;
|
||||
import javax.servlet.jsp.*;
|
||||
|
||||
public final class erreurs_jsp extends org.apache.jasper.runtime.HttpJspBase
|
||||
implements org.apache.jasper.runtime.JspSourceDependent {
|
||||
|
||||
private static final JspFactory _jspxFactory = JspFactory.getDefaultFactory();
|
||||
|
||||
private static java.util.List _jspx_dependants;
|
||||
|
||||
private org.apache.jasper.runtime.TagHandlerPool _005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems;
|
||||
|
||||
private javax.el.ExpressionFactory _el_expressionfactory;
|
||||
private org.apache.AnnotationProcessor _jsp_annotationprocessor;
|
||||
|
||||
public Object getDependants() {
|
||||
return _jspx_dependants;
|
||||
}
|
||||
|
||||
public void _jspInit() {
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems = org.apache.jasper.runtime.TagHandlerPool.getTagHandlerPool(getServletConfig());
|
||||
_el_expressionfactory = _jspxFactory.getJspApplicationContext(getServletConfig().getServletContext()).getExpressionFactory();
|
||||
_jsp_annotationprocessor = (org.apache.AnnotationProcessor) getServletConfig().getServletContext().getAttribute(org.apache.AnnotationProcessor.class.getName());
|
||||
}
|
||||
|
||||
public void _jspDestroy() {
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.release();
|
||||
}
|
||||
|
||||
public void _jspService(HttpServletRequest request, HttpServletResponse response)
|
||||
throws java.io.IOException, ServletException {
|
||||
|
||||
PageContext pageContext = null;
|
||||
HttpSession session = null;
|
||||
ServletContext application = null;
|
||||
ServletConfig config = null;
|
||||
JspWriter out = null;
|
||||
Object page = this;
|
||||
JspWriter _jspx_out = null;
|
||||
PageContext _jspx_page_context = null;
|
||||
|
||||
|
||||
try {
|
||||
response.setContentType("text/html;charset=UTF-8");
|
||||
pageContext = _jspxFactory.getPageContext(this, request, response,
|
||||
null, true, 8192, true);
|
||||
_jspx_page_context = pageContext;
|
||||
application = pageContext.getServletContext();
|
||||
config = pageContext.getServletConfig();
|
||||
session = pageContext.getSession();
|
||||
out = pageContext.getOut();
|
||||
_jspx_out = out;
|
||||
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\"\r\n");
|
||||
out.write(" \"http://www.w3.org/TR/html4/loose.dtd\">\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<html>\r\n");
|
||||
out.write(" <head>\r\n");
|
||||
out.write(" <meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\">\r\n");
|
||||
out.write("\t\t<link rel=\"stylesheet\" href=\"style.css\" type=\"text/css\" />\r\n");
|
||||
out.write(" <title>RandoOnLine - Erreurs</title>\r\n");
|
||||
out.write(" </head>\r\n");
|
||||
out.write(" <body>\r\n");
|
||||
out.write("\r\n");
|
||||
out.write(" <h1>RandoOnLine</h1>\r\n");
|
||||
out.write(" <table border=\"0\" width=\"100%\">\r\n");
|
||||
out.write(" <thead>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <th><a href=\"./index.jsp\">Accueil</a></th>\r\n");
|
||||
out.write(" <th><a href=\"./Panier\">Panier</a></th>\r\n");
|
||||
out.write(" <th><a href=\"./Articles\">Liste des articles</a></th>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </thead>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write(" \r\n");
|
||||
out.write("\t\t<h2>Les erreurs suivantes se sont produites : </h2>\r\n");
|
||||
out.write("\t\t<ul>\r\n");
|
||||
out.write("\t\t\t");
|
||||
if (_jspx_meth_c_005fforEach_005f0(_jspx_page_context))
|
||||
return;
|
||||
out.write("\r\n");
|
||||
out.write("\t\t</ul>\r\n");
|
||||
out.write("\t</body>\r\n");
|
||||
out.write("</html>\r\n");
|
||||
} catch (Throwable t) {
|
||||
if (!(t instanceof SkipPageException)){
|
||||
out = _jspx_out;
|
||||
if (out != null && out.getBufferSize() != 0)
|
||||
try { out.clearBuffer(); } catch (java.io.IOException e) {}
|
||||
if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
|
||||
}
|
||||
} finally {
|
||||
_jspxFactory.releasePageContext(_jspx_page_context);
|
||||
}
|
||||
}
|
||||
|
||||
private boolean _jspx_meth_c_005fforEach_005f0(PageContext _jspx_page_context)
|
||||
throws Throwable {
|
||||
PageContext pageContext = _jspx_page_context;
|
||||
JspWriter out = _jspx_page_context.getOut();
|
||||
// c:forEach
|
||||
org.apache.taglibs.standard.tag.rt.core.ForEachTag _jspx_th_c_005fforEach_005f0 = (org.apache.taglibs.standard.tag.rt.core.ForEachTag) _005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.get(org.apache.taglibs.standard.tag.rt.core.ForEachTag.class);
|
||||
_jspx_th_c_005fforEach_005f0.setPageContext(_jspx_page_context);
|
||||
_jspx_th_c_005fforEach_005f0.setParent(null);
|
||||
// /erreurs.jsp(30,3) name = items type = java.lang.Object reqTime = true required = false fragment = false deferredValue = false expectedTypeName = null deferredMethod = false methodSignature = null
|
||||
_jspx_th_c_005fforEach_005f0.setItems((java.lang.Object) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${erreurs}", java.lang.Object.class, (PageContext)_jspx_page_context, null, false));
|
||||
// /erreurs.jsp(30,3) name = var type = java.lang.String reqTime = false required = false fragment = false deferredValue = false expectedTypeName = null deferredMethod = false methodSignature = null
|
||||
_jspx_th_c_005fforEach_005f0.setVar("err");
|
||||
int[] _jspx_push_body_count_c_005fforEach_005f0 = new int[] { 0 };
|
||||
try {
|
||||
int _jspx_eval_c_005fforEach_005f0 = _jspx_th_c_005fforEach_005f0.doStartTag();
|
||||
if (_jspx_eval_c_005fforEach_005f0 != javax.servlet.jsp.tagext.Tag.SKIP_BODY) {
|
||||
do {
|
||||
out.write("\r\n");
|
||||
out.write("\t\t\t\t\t<li>\r\n");
|
||||
out.write("\t\t\t\t\t\t");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${err.message}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("\r\n");
|
||||
out.write("\t\t\t\t\t</li>\r\n");
|
||||
out.write("\t\t\t");
|
||||
int evalDoAfterBody = _jspx_th_c_005fforEach_005f0.doAfterBody();
|
||||
if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN)
|
||||
break;
|
||||
} while (true);
|
||||
}
|
||||
if (_jspx_th_c_005fforEach_005f0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
|
||||
return true;
|
||||
}
|
||||
} catch (Throwable _jspx_exception) {
|
||||
while (_jspx_push_body_count_c_005fforEach_005f0[0]-- > 0)
|
||||
out = _jspx_page_context.popBody();
|
||||
_jspx_th_c_005fforEach_005f0.doCatch(_jspx_exception);
|
||||
} finally {
|
||||
_jspx_th_c_005fforEach_005f0.doFinally();
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.reuse(_jspx_th_c_005fforEach_005f0);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
@ -0,0 +1,84 @@
|
||||
package org.apache.jsp;
|
||||
|
||||
import javax.servlet.*;
|
||||
import javax.servlet.http.*;
|
||||
import javax.servlet.jsp.*;
|
||||
|
||||
public final class index_jsp extends org.apache.jasper.runtime.HttpJspBase
|
||||
implements org.apache.jasper.runtime.JspSourceDependent {
|
||||
|
||||
private static final JspFactory _jspxFactory = JspFactory.getDefaultFactory();
|
||||
|
||||
private static java.util.List _jspx_dependants;
|
||||
|
||||
private javax.el.ExpressionFactory _el_expressionfactory;
|
||||
private org.apache.AnnotationProcessor _jsp_annotationprocessor;
|
||||
|
||||
public Object getDependants() {
|
||||
return _jspx_dependants;
|
||||
}
|
||||
|
||||
public void _jspInit() {
|
||||
_el_expressionfactory = _jspxFactory.getJspApplicationContext(getServletConfig().getServletContext()).getExpressionFactory();
|
||||
_jsp_annotationprocessor = (org.apache.AnnotationProcessor) getServletConfig().getServletContext().getAttribute(org.apache.AnnotationProcessor.class.getName());
|
||||
}
|
||||
|
||||
public void _jspDestroy() {
|
||||
}
|
||||
|
||||
public void _jspService(HttpServletRequest request, HttpServletResponse response)
|
||||
throws java.io.IOException, ServletException {
|
||||
|
||||
PageContext pageContext = null;
|
||||
HttpSession session = null;
|
||||
ServletContext application = null;
|
||||
ServletConfig config = null;
|
||||
JspWriter out = null;
|
||||
Object page = this;
|
||||
JspWriter _jspx_out = null;
|
||||
PageContext _jspx_page_context = null;
|
||||
|
||||
|
||||
try {
|
||||
response.setContentType("text/html;charset=UTF-8");
|
||||
pageContext = _jspxFactory.getPageContext(this, request, response,
|
||||
null, true, 8192, true);
|
||||
_jspx_page_context = pageContext;
|
||||
application = pageContext.getServletContext();
|
||||
config = pageContext.getServletConfig();
|
||||
session = pageContext.getSession();
|
||||
out = pageContext.getOut();
|
||||
_jspx_out = out;
|
||||
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\"\r\n");
|
||||
out.write(" \"http://www.w3.org/TR/html4/loose.dtd\">\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<html>\r\n");
|
||||
out.write(" <head>\r\n");
|
||||
out.write(" <meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\">\r\n");
|
||||
out.write("\t\t<link rel=\"stylesheet\" href=\"style.css\" type=\"text/css\" />\r\n");
|
||||
out.write(" <title>RandoOnLine</title>\r\n");
|
||||
out.write(" </head>\r\n");
|
||||
out.write(" <body>\r\n");
|
||||
out.write("\r\n");
|
||||
out.write(" <h1>RandoOnLine</h1>\r\n");
|
||||
out.write(" <br/>\r\n");
|
||||
out.write(" <a href=\"./Articles\">Afficher les articles</a>\r\n");
|
||||
out.write(" \r\n");
|
||||
out.write(" </body>\r\n");
|
||||
out.write("</html>\r\n");
|
||||
} catch (Throwable t) {
|
||||
if (!(t instanceof SkipPageException)){
|
||||
out = _jspx_out;
|
||||
if (out != null && out.getBufferSize() != 0)
|
||||
try { out.clearBuffer(); } catch (java.io.IOException e) {}
|
||||
if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
|
||||
}
|
||||
} finally {
|
||||
_jspxFactory.releasePageContext(_jspx_page_context);
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,159 @@
|
||||
package org.apache.jsp;
|
||||
|
||||
import javax.servlet.*;
|
||||
import javax.servlet.http.*;
|
||||
import javax.servlet.jsp.*;
|
||||
|
||||
public final class infos_jsp extends org.apache.jasper.runtime.HttpJspBase
|
||||
implements org.apache.jasper.runtime.JspSourceDependent {
|
||||
|
||||
private static final JspFactory _jspxFactory = JspFactory.getDefaultFactory();
|
||||
|
||||
private static java.util.List _jspx_dependants;
|
||||
|
||||
private javax.el.ExpressionFactory _el_expressionfactory;
|
||||
private org.apache.AnnotationProcessor _jsp_annotationprocessor;
|
||||
|
||||
public Object getDependants() {
|
||||
return _jspx_dependants;
|
||||
}
|
||||
|
||||
public void _jspInit() {
|
||||
_el_expressionfactory = _jspxFactory.getJspApplicationContext(getServletConfig().getServletContext()).getExpressionFactory();
|
||||
_jsp_annotationprocessor = (org.apache.AnnotationProcessor) getServletConfig().getServletContext().getAttribute(org.apache.AnnotationProcessor.class.getName());
|
||||
}
|
||||
|
||||
public void _jspDestroy() {
|
||||
}
|
||||
|
||||
public void _jspService(HttpServletRequest request, HttpServletResponse response)
|
||||
throws java.io.IOException, ServletException {
|
||||
|
||||
PageContext pageContext = null;
|
||||
HttpSession session = null;
|
||||
ServletContext application = null;
|
||||
ServletConfig config = null;
|
||||
JspWriter out = null;
|
||||
Object page = this;
|
||||
JspWriter _jspx_out = null;
|
||||
PageContext _jspx_page_context = null;
|
||||
|
||||
|
||||
try {
|
||||
response.setContentType("text/html;charset=UTF-8");
|
||||
pageContext = _jspxFactory.getPageContext(this, request, response,
|
||||
null, true, 8192, true);
|
||||
_jspx_page_context = pageContext;
|
||||
application = pageContext.getServletContext();
|
||||
config = pageContext.getServletConfig();
|
||||
session = pageContext.getSession();
|
||||
out = pageContext.getOut();
|
||||
_jspx_out = out;
|
||||
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\"\r\n");
|
||||
out.write(" \"http://www.w3.org/TR/html4/loose.dtd\">\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<html>\r\n");
|
||||
out.write(" <head>\r\n");
|
||||
out.write(" <meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\">\r\n");
|
||||
out.write("\t\t<link rel=\"stylesheet\" href=\"style.css\" type=\"text/css\" />\r\n");
|
||||
out.write(" <title>Contenu du Panier</title>\r\n");
|
||||
out.write(" </head>\r\n");
|
||||
out.write(" <body>\r\n");
|
||||
com.articles.Article art = null;
|
||||
synchronized (request) {
|
||||
art = (com.articles.Article) _jspx_page_context.getAttribute("art", PageContext.REQUEST_SCOPE);
|
||||
if (art == null){
|
||||
art = new com.articles.Article();
|
||||
_jspx_page_context.setAttribute("art", art, PageContext.REQUEST_SCOPE);
|
||||
}
|
||||
}
|
||||
out.write("\r\n");
|
||||
out.write(" \r\n");
|
||||
out.write("\t<h2>Infos sur l'article</h2>\r\n");
|
||||
out.write(" <table border=\"0\" width=\"100%\">\r\n");
|
||||
out.write(" <thead>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <th>Aper<65>u</th>\r\n");
|
||||
out.write(" <th>Propri<72>t<EFBFBD>s</th>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </thead>\r\n");
|
||||
out.write(" <tbody>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>\r\n");
|
||||
out.write(" <img src=\"./img/");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.photo}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("\" width=\"50\" height=\"50\" alt=\"image\"/>\r\n");
|
||||
out.write(" </td>\r\n");
|
||||
out.write(" <td>\r\n");
|
||||
out.write(" <table border=\"0\" width=\"100%\" height=\"100%\">\r\n");
|
||||
out.write(" <tbody>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>Référence :\r\n");
|
||||
out.write(" ");
|
||||
out.write(org.apache.jasper.runtime.JspRuntimeLibrary.toString((((com.articles.Article)_jspx_page_context.findAttribute("art")).getRef())));
|
||||
out.write("</td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>Marque : \r\n");
|
||||
out.write(" ");
|
||||
out.write(org.apache.jasper.runtime.JspRuntimeLibrary.toString((((com.articles.Article)_jspx_page_context.findAttribute("art")).getMarque())));
|
||||
out.write("</td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>Modèle : \r\n");
|
||||
out.write(" ");
|
||||
out.write(org.apache.jasper.runtime.JspRuntimeLibrary.toString((((com.articles.Article)_jspx_page_context.findAttribute("art")).getModele())));
|
||||
out.write("</td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>Description : \r\n");
|
||||
out.write(" ");
|
||||
out.write(org.apache.jasper.runtime.JspRuntimeLibrary.toString((((com.articles.Article)_jspx_page_context.findAttribute("art")).getDescription())));
|
||||
out.write("</td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>Prix : \r\n");
|
||||
out.write(" ");
|
||||
out.write(org.apache.jasper.runtime.JspRuntimeLibrary.toString((((com.articles.Article)_jspx_page_context.findAttribute("art")).getPrix())));
|
||||
out.write("</td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </tbody>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write(" </td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </tbody>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write("\t\t<hr width=\"100%\" size=\"1\">\r\n");
|
||||
out.write("\t\t<form method=\"post\" action=\"./Panier?action=add\">\r\n");
|
||||
out.write("\t\t\t<table>\r\n");
|
||||
out.write("\t\t\t\t<tr>\r\n");
|
||||
out.write("\t\t\t\t\t<td><input type=\"submit\" value=\"");
|
||||
out.write(org.apache.jasper.runtime.JspRuntimeLibrary.toString((((com.articles.Article)_jspx_page_context.findAttribute("art")).getRef())));
|
||||
out.write("\"></td>\r\n");
|
||||
out.write("\t\t\t\t\t<td>Qt<51></td>\r\n");
|
||||
out.write("\t\t\t\t\t<td>\r\n");
|
||||
out.write("\t\t\t\t\t<input type=\"hidden\" value=\"Acheter\">\r\n");
|
||||
out.write("\t\t\t\t\t<input type=\"text\" maxLength=\"3\" size=\"3\" id=\"txtQte\" name=\"txtQte\" /></td>\r\n");
|
||||
out.write("\t\t\t\t\t</td>\r\n");
|
||||
out.write("\t\t\t\t</tr>\r\n");
|
||||
out.write("\t\t\t</table>\r\n");
|
||||
out.write("\t\t</form>\r\n");
|
||||
out.write("\t</body>\r\n");
|
||||
out.write("</html>\r\n");
|
||||
} catch (Throwable t) {
|
||||
if (!(t instanceof SkipPageException)){
|
||||
out = _jspx_out;
|
||||
if (out != null && out.getBufferSize() != 0)
|
||||
try { out.clearBuffer(); } catch (java.io.IOException e) {}
|
||||
if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
|
||||
}
|
||||
} finally {
|
||||
_jspxFactory.releasePageContext(_jspx_page_context);
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,95 @@
|
||||
package org.apache.jsp;
|
||||
|
||||
import javax.servlet.*;
|
||||
import javax.servlet.http.*;
|
||||
import javax.servlet.jsp.*;
|
||||
|
||||
public final class listeArticlesVide_jsp extends org.apache.jasper.runtime.HttpJspBase
|
||||
implements org.apache.jasper.runtime.JspSourceDependent {
|
||||
|
||||
private static final JspFactory _jspxFactory = JspFactory.getDefaultFactory();
|
||||
|
||||
private static java.util.List _jspx_dependants;
|
||||
|
||||
private javax.el.ExpressionFactory _el_expressionfactory;
|
||||
private org.apache.AnnotationProcessor _jsp_annotationprocessor;
|
||||
|
||||
public Object getDependants() {
|
||||
return _jspx_dependants;
|
||||
}
|
||||
|
||||
public void _jspInit() {
|
||||
_el_expressionfactory = _jspxFactory.getJspApplicationContext(getServletConfig().getServletContext()).getExpressionFactory();
|
||||
_jsp_annotationprocessor = (org.apache.AnnotationProcessor) getServletConfig().getServletContext().getAttribute(org.apache.AnnotationProcessor.class.getName());
|
||||
}
|
||||
|
||||
public void _jspDestroy() {
|
||||
}
|
||||
|
||||
public void _jspService(HttpServletRequest request, HttpServletResponse response)
|
||||
throws java.io.IOException, ServletException {
|
||||
|
||||
PageContext pageContext = null;
|
||||
HttpSession session = null;
|
||||
ServletContext application = null;
|
||||
ServletConfig config = null;
|
||||
JspWriter out = null;
|
||||
Object page = this;
|
||||
JspWriter _jspx_out = null;
|
||||
PageContext _jspx_page_context = null;
|
||||
|
||||
|
||||
try {
|
||||
response.setContentType("text/html;charset=UTF-8");
|
||||
pageContext = _jspxFactory.getPageContext(this, request, response,
|
||||
null, true, 8192, true);
|
||||
_jspx_page_context = pageContext;
|
||||
application = pageContext.getServletContext();
|
||||
config = pageContext.getServletConfig();
|
||||
session = pageContext.getSession();
|
||||
out = pageContext.getOut();
|
||||
_jspx_out = out;
|
||||
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\"\r\n");
|
||||
out.write(" \"http://www.w3.org/TR/html4/loose.dtd\">\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<html>\r\n");
|
||||
out.write(" <head>\r\n");
|
||||
out.write(" <meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\">\r\n");
|
||||
out.write("\t\t<link rel=\"stylesheet\" href=\"style.css\" type=\"text/css\" />\r\n");
|
||||
out.write(" <title>RandoOnLine - Articles disponibles</title>\r\n");
|
||||
out.write(" </head>\r\n");
|
||||
out.write(" <body>\r\n");
|
||||
out.write(" <h1>RandoOnLine</h1>\r\n");
|
||||
out.write(" <table border=\"0\" width=\"100%\">\r\n");
|
||||
out.write(" <thead>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <th><a href=\"./index.jsp\">Accueil</a></th>\r\n");
|
||||
out.write(" <th><a href=\"./Panier\">Panier</a></th>\r\n");
|
||||
out.write(" <th>Liste des articles</th>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </thead>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write(" \r\n");
|
||||
out.write("\t\t<h2>Liste des articles disponibles</h2>\r\n");
|
||||
out.write("\t\t<P>Nous somme actuellement en rupture de stock !</P>\r\n");
|
||||
out.write("\t\t<P>Nous serons livr<76> tr<74>s prochainement.</P>\r\n");
|
||||
out.write(" \t<a href=\"./index.jsp\">Accueil</a>\r\n");
|
||||
out.write("\t</body>\r\n");
|
||||
out.write("</html>\r\n");
|
||||
} catch (Throwable t) {
|
||||
if (!(t instanceof SkipPageException)){
|
||||
out = _jspx_out;
|
||||
if (out != null && out.getBufferSize() != 0)
|
||||
try { out.clearBuffer(); } catch (java.io.IOException e) {}
|
||||
if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
|
||||
}
|
||||
} finally {
|
||||
_jspxFactory.releasePageContext(_jspx_page_context);
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,246 @@
|
||||
package org.apache.jsp;
|
||||
|
||||
import javax.servlet.*;
|
||||
import javax.servlet.http.*;
|
||||
import javax.servlet.jsp.*;
|
||||
|
||||
public final class listeArticles_jsp extends org.apache.jasper.runtime.HttpJspBase
|
||||
implements org.apache.jasper.runtime.JspSourceDependent {
|
||||
|
||||
private static final JspFactory _jspxFactory = JspFactory.getDefaultFactory();
|
||||
|
||||
private static java.util.List _jspx_dependants;
|
||||
|
||||
private org.apache.jasper.runtime.TagHandlerPool _005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems;
|
||||
|
||||
private javax.el.ExpressionFactory _el_expressionfactory;
|
||||
private org.apache.AnnotationProcessor _jsp_annotationprocessor;
|
||||
|
||||
public Object getDependants() {
|
||||
return _jspx_dependants;
|
||||
}
|
||||
|
||||
public void _jspInit() {
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems = org.apache.jasper.runtime.TagHandlerPool.getTagHandlerPool(getServletConfig());
|
||||
_el_expressionfactory = _jspxFactory.getJspApplicationContext(getServletConfig().getServletContext()).getExpressionFactory();
|
||||
_jsp_annotationprocessor = (org.apache.AnnotationProcessor) getServletConfig().getServletContext().getAttribute(org.apache.AnnotationProcessor.class.getName());
|
||||
}
|
||||
|
||||
public void _jspDestroy() {
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.release();
|
||||
}
|
||||
|
||||
public void _jspService(HttpServletRequest request, HttpServletResponse response)
|
||||
throws java.io.IOException, ServletException {
|
||||
|
||||
PageContext pageContext = null;
|
||||
HttpSession session = null;
|
||||
ServletContext application = null;
|
||||
ServletConfig config = null;
|
||||
JspWriter out = null;
|
||||
Object page = this;
|
||||
JspWriter _jspx_out = null;
|
||||
PageContext _jspx_page_context = null;
|
||||
|
||||
|
||||
try {
|
||||
response.setContentType("text/html;charset=UTF-8");
|
||||
pageContext = _jspxFactory.getPageContext(this, request, response,
|
||||
null, true, 8192, true);
|
||||
_jspx_page_context = pageContext;
|
||||
application = pageContext.getServletContext();
|
||||
config = pageContext.getServletConfig();
|
||||
session = pageContext.getSession();
|
||||
out = pageContext.getOut();
|
||||
_jspx_out = out;
|
||||
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\"\r\n");
|
||||
out.write(" \"http://www.w3.org/TR/html4/loose.dtd\">\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<html>\r\n");
|
||||
out.write(" <head>\r\n");
|
||||
out.write(" <meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\">\r\n");
|
||||
out.write("\t\t<link rel=\"stylesheet\" href=\"style.css\" type=\"text/css\" />\r\n");
|
||||
out.write(" <title>RandoOnLine - Articles disponibles</title>\r\n");
|
||||
out.write(" </head>\r\n");
|
||||
out.write(" <body>\r\n");
|
||||
out.write(" \r\n");
|
||||
out.write(" <h1>RandoOnLine</h1>\r\n");
|
||||
out.write(" <table border=\"0\" width=\"100%\">\r\n");
|
||||
out.write(" <thead>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <th><a href=\"./index.jsp\">Accueil</a></th>\r\n");
|
||||
out.write(" <th><a href=\"./Panier\">Panier</a></th>\r\n");
|
||||
out.write(" <th>Liste des articles</th>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </thead>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write(" \r\n");
|
||||
out.write("\t<h2>Filtre</h2>\r\n");
|
||||
out.write("\t<form method=\"post\" action=\"./Articles\">\r\n");
|
||||
out.write("\t\t<select id=\"lstCategs\" name=\"lstCategs\" size=\"1\">\r\n");
|
||||
if (_jspx_meth_c_005fforEach_005f0(_jspx_page_context))
|
||||
return;
|
||||
out.write("\r\n");
|
||||
out.write("\t\t</select>\r\n");
|
||||
out.write(" <input type=\"submit\" value=\"Appliquer le filtre\">\r\n");
|
||||
out.write("\t</form>\r\n");
|
||||
out.write("\t\r\n");
|
||||
out.write("\t<h2>Liste des articles disponibles</h2>\r\n");
|
||||
out.write(" <table border=\"0\" width=\"100%\">\r\n");
|
||||
out.write(" <thead>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <th>Aper<65>u</th>\r\n");
|
||||
out.write(" <th>Propri<72>t<EFBFBD>s</th>\r\n");
|
||||
out.write(" <th>Action</th>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </thead>\r\n");
|
||||
out.write(" <tbody>\r\n");
|
||||
if (_jspx_meth_c_005fforEach_005f1(_jspx_page_context))
|
||||
return;
|
||||
out.write("\r\n");
|
||||
out.write(" </tbody>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write("\t</body>\r\n");
|
||||
out.write("</HTML>\r\n");
|
||||
out.write(" ");
|
||||
} catch (Throwable t) {
|
||||
if (!(t instanceof SkipPageException)){
|
||||
out = _jspx_out;
|
||||
if (out != null && out.getBufferSize() != 0)
|
||||
try { out.clearBuffer(); } catch (java.io.IOException e) {}
|
||||
if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
|
||||
}
|
||||
} finally {
|
||||
_jspxFactory.releasePageContext(_jspx_page_context);
|
||||
}
|
||||
}
|
||||
|
||||
private boolean _jspx_meth_c_005fforEach_005f0(PageContext _jspx_page_context)
|
||||
throws Throwable {
|
||||
PageContext pageContext = _jspx_page_context;
|
||||
JspWriter out = _jspx_page_context.getOut();
|
||||
// c:forEach
|
||||
org.apache.taglibs.standard.tag.rt.core.ForEachTag _jspx_th_c_005fforEach_005f0 = (org.apache.taglibs.standard.tag.rt.core.ForEachTag) _005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.get(org.apache.taglibs.standard.tag.rt.core.ForEachTag.class);
|
||||
_jspx_th_c_005fforEach_005f0.setPageContext(_jspx_page_context);
|
||||
_jspx_th_c_005fforEach_005f0.setParent(null);
|
||||
// /listeArticles.jsp(31,0) name = items type = java.lang.Object reqTime = true required = false fragment = false deferredValue = false expectedTypeName = null deferredMethod = false methodSignature = null
|
||||
_jspx_th_c_005fforEach_005f0.setItems((java.lang.Object) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${categories}", java.lang.Object.class, (PageContext)_jspx_page_context, null, false));
|
||||
// /listeArticles.jsp(31,0) name = var type = java.lang.String reqTime = false required = false fragment = false deferredValue = false expectedTypeName = null deferredMethod = false methodSignature = null
|
||||
_jspx_th_c_005fforEach_005f0.setVar("categ");
|
||||
int[] _jspx_push_body_count_c_005fforEach_005f0 = new int[] { 0 };
|
||||
try {
|
||||
int _jspx_eval_c_005fforEach_005f0 = _jspx_th_c_005fforEach_005f0.doStartTag();
|
||||
if (_jspx_eval_c_005fforEach_005f0 != javax.servlet.jsp.tagext.Tag.SKIP_BODY) {
|
||||
do {
|
||||
out.write("\r\n");
|
||||
out.write("\t\t\t<option value=\"");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${categ.id}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write('"');
|
||||
out.write('>');
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${categ.cat}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("</option>\r\n");
|
||||
int evalDoAfterBody = _jspx_th_c_005fforEach_005f0.doAfterBody();
|
||||
if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN)
|
||||
break;
|
||||
} while (true);
|
||||
}
|
||||
if (_jspx_th_c_005fforEach_005f0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
|
||||
return true;
|
||||
}
|
||||
} catch (Throwable _jspx_exception) {
|
||||
while (_jspx_push_body_count_c_005fforEach_005f0[0]-- > 0)
|
||||
out = _jspx_page_context.popBody();
|
||||
_jspx_th_c_005fforEach_005f0.doCatch(_jspx_exception);
|
||||
} finally {
|
||||
_jspx_th_c_005fforEach_005f0.doFinally();
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.reuse(_jspx_th_c_005fforEach_005f0);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
private boolean _jspx_meth_c_005fforEach_005f1(PageContext _jspx_page_context)
|
||||
throws Throwable {
|
||||
PageContext pageContext = _jspx_page_context;
|
||||
JspWriter out = _jspx_page_context.getOut();
|
||||
// c:forEach
|
||||
org.apache.taglibs.standard.tag.rt.core.ForEachTag _jspx_th_c_005fforEach_005f1 = (org.apache.taglibs.standard.tag.rt.core.ForEachTag) _005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.get(org.apache.taglibs.standard.tag.rt.core.ForEachTag.class);
|
||||
_jspx_th_c_005fforEach_005f1.setPageContext(_jspx_page_context);
|
||||
_jspx_th_c_005fforEach_005f1.setParent(null);
|
||||
// /listeArticles.jsp(48,0) name = items type = java.lang.Object reqTime = true required = false fragment = false deferredValue = false expectedTypeName = null deferredMethod = false methodSignature = null
|
||||
_jspx_th_c_005fforEach_005f1.setItems((java.lang.Object) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${articles}", java.lang.Object.class, (PageContext)_jspx_page_context, null, false));
|
||||
// /listeArticles.jsp(48,0) name = var type = java.lang.String reqTime = false required = false fragment = false deferredValue = false expectedTypeName = null deferredMethod = false methodSignature = null
|
||||
_jspx_th_c_005fforEach_005f1.setVar("artRef");
|
||||
int[] _jspx_push_body_count_c_005fforEach_005f1 = new int[] { 0 };
|
||||
try {
|
||||
int _jspx_eval_c_005fforEach_005f1 = _jspx_th_c_005fforEach_005f1.doStartTag();
|
||||
if (_jspx_eval_c_005fforEach_005f1 != javax.servlet.jsp.tagext.Tag.SKIP_BODY) {
|
||||
do {
|
||||
out.write("\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>\r\n");
|
||||
out.write(" <img src=\"./img/");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.photo}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("\" width=\"50\" height=\"50\" alt=\"image\"/>\r\n");
|
||||
out.write(" </td>\r\n");
|
||||
out.write(" <td>\r\n");
|
||||
out.write(" <table border=\"0\" width=\"100%\" height=\"100%\">\r\n");
|
||||
out.write(" <tbody>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>Référence : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.ref}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("</td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>Marque : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.marque}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("</td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>Modèle : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.modele}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("</td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>Description : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.description}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("</td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>Prix : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.prix}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("</td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </tbody>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write(" </td>\r\n");
|
||||
out.write(" <td>\r\n");
|
||||
out.write(" <a href=\"./Panier?action=add&artRef=");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.ref}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("\">ajouter au panier</a>\r\n");
|
||||
out.write(" </td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
int evalDoAfterBody = _jspx_th_c_005fforEach_005f1.doAfterBody();
|
||||
if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN)
|
||||
break;
|
||||
} while (true);
|
||||
}
|
||||
if (_jspx_th_c_005fforEach_005f1.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
|
||||
return true;
|
||||
}
|
||||
} catch (Throwable _jspx_exception) {
|
||||
while (_jspx_push_body_count_c_005fforEach_005f1[0]-- > 0)
|
||||
out = _jspx_page_context.popBody();
|
||||
_jspx_th_c_005fforEach_005f1.doCatch(_jspx_exception);
|
||||
} finally {
|
||||
_jspx_th_c_005fforEach_005f1.doFinally();
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.reuse(_jspx_th_c_005fforEach_005f1);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
@ -0,0 +1,94 @@
|
||||
package org.apache.jsp;
|
||||
|
||||
import javax.servlet.*;
|
||||
import javax.servlet.http.*;
|
||||
import javax.servlet.jsp.*;
|
||||
|
||||
public final class panierVide_jsp extends org.apache.jasper.runtime.HttpJspBase
|
||||
implements org.apache.jasper.runtime.JspSourceDependent {
|
||||
|
||||
private static final JspFactory _jspxFactory = JspFactory.getDefaultFactory();
|
||||
|
||||
private static java.util.List _jspx_dependants;
|
||||
|
||||
private javax.el.ExpressionFactory _el_expressionfactory;
|
||||
private org.apache.AnnotationProcessor _jsp_annotationprocessor;
|
||||
|
||||
public Object getDependants() {
|
||||
return _jspx_dependants;
|
||||
}
|
||||
|
||||
public void _jspInit() {
|
||||
_el_expressionfactory = _jspxFactory.getJspApplicationContext(getServletConfig().getServletContext()).getExpressionFactory();
|
||||
_jsp_annotationprocessor = (org.apache.AnnotationProcessor) getServletConfig().getServletContext().getAttribute(org.apache.AnnotationProcessor.class.getName());
|
||||
}
|
||||
|
||||
public void _jspDestroy() {
|
||||
}
|
||||
|
||||
public void _jspService(HttpServletRequest request, HttpServletResponse response)
|
||||
throws java.io.IOException, ServletException {
|
||||
|
||||
PageContext pageContext = null;
|
||||
HttpSession session = null;
|
||||
ServletContext application = null;
|
||||
ServletConfig config = null;
|
||||
JspWriter out = null;
|
||||
Object page = this;
|
||||
JspWriter _jspx_out = null;
|
||||
PageContext _jspx_page_context = null;
|
||||
|
||||
|
||||
try {
|
||||
response.setContentType("text/html;charset=UTF-8");
|
||||
pageContext = _jspxFactory.getPageContext(this, request, response,
|
||||
null, true, 8192, true);
|
||||
_jspx_page_context = pageContext;
|
||||
application = pageContext.getServletContext();
|
||||
config = pageContext.getServletConfig();
|
||||
session = pageContext.getSession();
|
||||
out = pageContext.getOut();
|
||||
_jspx_out = out;
|
||||
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\"\r\n");
|
||||
out.write(" \"http://www.w3.org/TR/html4/loose.dtd\">\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<html>\r\n");
|
||||
out.write(" <head>\r\n");
|
||||
out.write(" <meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\">\r\n");
|
||||
out.write("\t\t<link rel=\"stylesheet\" href=\"style.css\" type=\"text/css\" />\r\n");
|
||||
out.write(" <title>RandoOnLine - Contenu du Panier</title>\r\n");
|
||||
out.write(" </head>\r\n");
|
||||
out.write(" <body>\r\n");
|
||||
out.write(" <h1>RandoOnLine</h1>\r\n");
|
||||
out.write(" <table border=\"0\" width=\"100%\">\r\n");
|
||||
out.write(" <thead>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <th><a href=\"./index.jsp\">Accueil</a></th>\r\n");
|
||||
out.write(" <th>Panier</th>\r\n");
|
||||
out.write(" <th><a href=\"./Articles\">Liste des articles</a></th>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </thead>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write(" \r\n");
|
||||
out.write("\t\t<h2>Contenu de votre panier</h2>\r\n");
|
||||
out.write("\t\t<P>Votre panier est vide</P>\r\n");
|
||||
out.write(" \t<a href=\"./Articles\">Continuez vos achats</a>\r\n");
|
||||
out.write("\t</body>\r\n");
|
||||
out.write("</html>\r\n");
|
||||
} catch (Throwable t) {
|
||||
if (!(t instanceof SkipPageException)){
|
||||
out = _jspx_out;
|
||||
if (out != null && out.getBufferSize() != 0)
|
||||
try { out.clearBuffer(); } catch (java.io.IOException e) {}
|
||||
if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
|
||||
}
|
||||
} finally {
|
||||
_jspxFactory.releasePageContext(_jspx_page_context);
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,219 @@
|
||||
package org.apache.jsp;
|
||||
|
||||
import javax.servlet.*;
|
||||
import javax.servlet.http.*;
|
||||
import javax.servlet.jsp.*;
|
||||
|
||||
public final class payement_jsp extends org.apache.jasper.runtime.HttpJspBase
|
||||
implements org.apache.jasper.runtime.JspSourceDependent {
|
||||
|
||||
private static final JspFactory _jspxFactory = JspFactory.getDefaultFactory();
|
||||
|
||||
private static java.util.List _jspx_dependants;
|
||||
|
||||
private org.apache.jasper.runtime.TagHandlerPool _005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems;
|
||||
|
||||
private javax.el.ExpressionFactory _el_expressionfactory;
|
||||
private org.apache.AnnotationProcessor _jsp_annotationprocessor;
|
||||
|
||||
public Object getDependants() {
|
||||
return _jspx_dependants;
|
||||
}
|
||||
|
||||
public void _jspInit() {
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems = org.apache.jasper.runtime.TagHandlerPool.getTagHandlerPool(getServletConfig());
|
||||
_el_expressionfactory = _jspxFactory.getJspApplicationContext(getServletConfig().getServletContext()).getExpressionFactory();
|
||||
_jsp_annotationprocessor = (org.apache.AnnotationProcessor) getServletConfig().getServletContext().getAttribute(org.apache.AnnotationProcessor.class.getName());
|
||||
}
|
||||
|
||||
public void _jspDestroy() {
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.release();
|
||||
}
|
||||
|
||||
public void _jspService(HttpServletRequest request, HttpServletResponse response)
|
||||
throws java.io.IOException, ServletException {
|
||||
|
||||
PageContext pageContext = null;
|
||||
HttpSession session = null;
|
||||
ServletContext application = null;
|
||||
ServletConfig config = null;
|
||||
JspWriter out = null;
|
||||
Object page = this;
|
||||
JspWriter _jspx_out = null;
|
||||
PageContext _jspx_page_context = null;
|
||||
|
||||
|
||||
try {
|
||||
response.setContentType("text/html;charset=UTF-8");
|
||||
pageContext = _jspxFactory.getPageContext(this, request, response,
|
||||
null, true, 8192, true);
|
||||
_jspx_page_context = pageContext;
|
||||
application = pageContext.getServletContext();
|
||||
config = pageContext.getServletConfig();
|
||||
session = pageContext.getSession();
|
||||
out = pageContext.getOut();
|
||||
_jspx_out = out;
|
||||
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\"\r\n");
|
||||
out.write(" \"http://www.w3.org/TR/html4/loose.dtd\">\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<html>\r\n");
|
||||
out.write(" <head>\r\n");
|
||||
out.write(" <meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\">\r\n");
|
||||
out.write("\t\t<link rel=\"stylesheet\" href=\"style.css\" type=\"text/css\" />\r\n");
|
||||
out.write(" <title>RandoOnLine - Payement</title>\r\n");
|
||||
out.write(" </head>\r\n");
|
||||
out.write(" <body>\r\n");
|
||||
out.write("\r\n");
|
||||
out.write(" <h1>RandoOnLine</h1>\r\n");
|
||||
out.write(" <table border=\"0\" width=\"100%\">\r\n");
|
||||
out.write(" <thead>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <th><a href=\"./index.jsp\">Accueil</a></th>\r\n");
|
||||
out.write(" <th><a href=\"./Panier\">Panier</a></th>\r\n");
|
||||
out.write(" <th><a href=\"./Articles\">Liste des articles</a></th>\r\n");
|
||||
out.write(" <th>Passer <20> la caisse</th>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </thead>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write(" \r\n");
|
||||
out.write(" <h2>Payement</h2>\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\t<p>Rappel de la commande :</p>\r\n");
|
||||
out.write(" <table border=\"0\" width=\"100%\">\r\n");
|
||||
out.write(" <thead>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <th>Reference</th>\r\n");
|
||||
out.write(" <th>Modele</th>\r\n");
|
||||
out.write(" <th>Prix</th>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </thead>\r\n");
|
||||
out.write(" <tbody>\r\n");
|
||||
if (_jspx_meth_c_005fforEach_005f0(_jspx_page_context))
|
||||
return;
|
||||
out.write("\r\n");
|
||||
out.write("\t\t\t<tr>\r\n");
|
||||
out.write(" <td colspan=\"2\" class=\"tabTotal\">Total :</td>\r\n");
|
||||
out.write(" <td>\r\n");
|
||||
com.articles.Panier panierTotal = null;
|
||||
synchronized (request) {
|
||||
panierTotal = (com.articles.Panier) _jspx_page_context.getAttribute("panierTotal", PageContext.REQUEST_SCOPE);
|
||||
if (panierTotal == null){
|
||||
panierTotal = new com.articles.Panier();
|
||||
_jspx_page_context.setAttribute("panierTotal", panierTotal, PageContext.REQUEST_SCOPE);
|
||||
}
|
||||
}
|
||||
out.write("\r\n");
|
||||
out.write("\t\t\t\t\t");
|
||||
out.write(org.apache.jasper.runtime.JspRuntimeLibrary.toString((((com.articles.Panier)_jspx_page_context.findAttribute("panierTotal")).getPrixTotal())));
|
||||
out.write("\r\n");
|
||||
out.write(" </td>\r\n");
|
||||
out.write("\t\t\t</tr>\r\n");
|
||||
out.write(" </tbody>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\t\t<hr width=\"100%\" size=\"1\">\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\t<form method=\"post\" action=\"./Client\">\r\n");
|
||||
out.write("\t<table border=\"0\">\r\n");
|
||||
out.write(" <tbody>\r\n");
|
||||
out.write(" \t<tr>\r\n");
|
||||
out.write(" \t\t<td>Nom :</td>\r\n");
|
||||
out.write(" \t\t<td><input type=\"text\" id=\"nomCli\" name=\"nomCli\" size=\"10\" value=\"\" /></td>\r\n");
|
||||
out.write(" \t</tr>\r\n");
|
||||
out.write(" \t<tr>\r\n");
|
||||
out.write(" \t\t<td>Pr<50>nom :</td>\r\n");
|
||||
out.write(" \t\t<td><input type=\"text\" id=\"prenomCli\" name=\"prenomCli\" size=\"10\" value=\"\" /></td>\r\n");
|
||||
out.write(" \t</tr>\r\n");
|
||||
out.write(" \t<tr>\r\n");
|
||||
out.write(" \t\t<td>Adresse :</td>\r\n");
|
||||
out.write(" \t\t<td><input type=\"text\" id=\"addrCli\" name=\"addrCli\" size=\"10\" value=\"\" /></td>\r\n");
|
||||
out.write(" \t</tr>\r\n");
|
||||
out.write(" \t<tr>\r\n");
|
||||
out.write(" \t\t<td>Code postal :</td>\r\n");
|
||||
out.write(" \t\t<td><input type=\"text\" id=\"cpCli\" name=\"cpCli\" size=\"10\" value=\"\" /></td>\r\n");
|
||||
out.write(" \t</tr>\r\n");
|
||||
out.write(" \t<tr>\r\n");
|
||||
out.write(" \t\t<td>Ville :</td>\r\n");
|
||||
out.write(" \t\t<td><input type=\"text\" id=\"villeCli\" name=\"villeCli\" size=\"10\" value=\"\" /></td>\r\n");
|
||||
out.write(" \t</tr>\r\n");
|
||||
out.write(" </tbody>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write(" <p>Note : le payement se fera <20> la livraison de la commande.</p>\r\n");
|
||||
out.write(" <input type=\"hidden\" name=\"action\" value=\"payer\" />\r\n");
|
||||
out.write(" <input type=\"button\" value=\"Annuler\" onclick=\"javascript:document.location='./index.jsp'\" /> \r\n");
|
||||
out.write(" <input type=\"submit\" value=\"Payer\" />\r\n");
|
||||
out.write("\t</form>\r\n");
|
||||
out.write(" </body>\r\n");
|
||||
out.write("</html>\r\n");
|
||||
} catch (Throwable t) {
|
||||
if (!(t instanceof SkipPageException)){
|
||||
out = _jspx_out;
|
||||
if (out != null && out.getBufferSize() != 0)
|
||||
try { out.clearBuffer(); } catch (java.io.IOException e) {}
|
||||
if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
|
||||
}
|
||||
} finally {
|
||||
_jspxFactory.releasePageContext(_jspx_page_context);
|
||||
}
|
||||
}
|
||||
|
||||
private boolean _jspx_meth_c_005fforEach_005f0(PageContext _jspx_page_context)
|
||||
throws Throwable {
|
||||
PageContext pageContext = _jspx_page_context;
|
||||
JspWriter out = _jspx_page_context.getOut();
|
||||
// c:forEach
|
||||
org.apache.taglibs.standard.tag.rt.core.ForEachTag _jspx_th_c_005fforEach_005f0 = (org.apache.taglibs.standard.tag.rt.core.ForEachTag) _005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.get(org.apache.taglibs.standard.tag.rt.core.ForEachTag.class);
|
||||
_jspx_th_c_005fforEach_005f0.setPageContext(_jspx_page_context);
|
||||
_jspx_th_c_005fforEach_005f0.setParent(null);
|
||||
// /payement.jsp(41,0) name = items type = java.lang.Object reqTime = true required = false fragment = false deferredValue = false expectedTypeName = null deferredMethod = false methodSignature = null
|
||||
_jspx_th_c_005fforEach_005f0.setItems((java.lang.Object) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${articles}", java.lang.Object.class, (PageContext)_jspx_page_context, null, false));
|
||||
// /payement.jsp(41,0) name = var type = java.lang.String reqTime = false required = false fragment = false deferredValue = false expectedTypeName = null deferredMethod = false methodSignature = null
|
||||
_jspx_th_c_005fforEach_005f0.setVar("artRef");
|
||||
int[] _jspx_push_body_count_c_005fforEach_005f0 = new int[] { 0 };
|
||||
try {
|
||||
int _jspx_eval_c_005fforEach_005f0 = _jspx_th_c_005fforEach_005f0.doStartTag();
|
||||
if (_jspx_eval_c_005fforEach_005f0 != javax.servlet.jsp.tagext.Tag.SKIP_BODY) {
|
||||
do {
|
||||
out.write("\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>\r\n");
|
||||
out.write(" \tRéférence : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.ref}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("\r\n");
|
||||
out.write(" </td>\r\n");
|
||||
out.write("\t\t\t\t<td>\r\n");
|
||||
out.write("\t\t\t\t\tModèle : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.modele}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("\r\n");
|
||||
out.write("\t\t\t\t</td>\r\n");
|
||||
out.write("\t <td>\r\n");
|
||||
out.write("\t \tPrix : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.prix}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("\r\n");
|
||||
out.write("\t </td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
int evalDoAfterBody = _jspx_th_c_005fforEach_005f0.doAfterBody();
|
||||
if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN)
|
||||
break;
|
||||
} while (true);
|
||||
}
|
||||
if (_jspx_th_c_005fforEach_005f0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
|
||||
return true;
|
||||
}
|
||||
} catch (Throwable _jspx_exception) {
|
||||
while (_jspx_push_body_count_c_005fforEach_005f0[0]-- > 0)
|
||||
out = _jspx_page_context.popBody();
|
||||
_jspx_th_c_005fforEach_005f0.doCatch(_jspx_exception);
|
||||
} finally {
|
||||
_jspx_th_c_005fforEach_005f0.doFinally();
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.reuse(_jspx_th_c_005fforEach_005f0);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
@ -0,0 +1,214 @@
|
||||
package org.apache.jsp;
|
||||
|
||||
import javax.servlet.*;
|
||||
import javax.servlet.http.*;
|
||||
import javax.servlet.jsp.*;
|
||||
|
||||
public final class resultPayement_jsp extends org.apache.jasper.runtime.HttpJspBase
|
||||
implements org.apache.jasper.runtime.JspSourceDependent {
|
||||
|
||||
private static final JspFactory _jspxFactory = JspFactory.getDefaultFactory();
|
||||
|
||||
private static java.util.List _jspx_dependants;
|
||||
|
||||
private org.apache.jasper.runtime.TagHandlerPool _005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems;
|
||||
|
||||
private javax.el.ExpressionFactory _el_expressionfactory;
|
||||
private org.apache.AnnotationProcessor _jsp_annotationprocessor;
|
||||
|
||||
public Object getDependants() {
|
||||
return _jspx_dependants;
|
||||
}
|
||||
|
||||
public void _jspInit() {
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems = org.apache.jasper.runtime.TagHandlerPool.getTagHandlerPool(getServletConfig());
|
||||
_el_expressionfactory = _jspxFactory.getJspApplicationContext(getServletConfig().getServletContext()).getExpressionFactory();
|
||||
_jsp_annotationprocessor = (org.apache.AnnotationProcessor) getServletConfig().getServletContext().getAttribute(org.apache.AnnotationProcessor.class.getName());
|
||||
}
|
||||
|
||||
public void _jspDestroy() {
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.release();
|
||||
}
|
||||
|
||||
public void _jspService(HttpServletRequest request, HttpServletResponse response)
|
||||
throws java.io.IOException, ServletException {
|
||||
|
||||
PageContext pageContext = null;
|
||||
HttpSession session = null;
|
||||
ServletContext application = null;
|
||||
ServletConfig config = null;
|
||||
JspWriter out = null;
|
||||
Object page = this;
|
||||
JspWriter _jspx_out = null;
|
||||
PageContext _jspx_page_context = null;
|
||||
|
||||
|
||||
try {
|
||||
response.setContentType("text/html;charset=UTF-8");
|
||||
pageContext = _jspxFactory.getPageContext(this, request, response,
|
||||
null, true, 8192, true);
|
||||
_jspx_page_context = pageContext;
|
||||
application = pageContext.getServletContext();
|
||||
config = pageContext.getServletConfig();
|
||||
session = pageContext.getSession();
|
||||
out = pageContext.getOut();
|
||||
_jspx_out = out;
|
||||
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\"\r\n");
|
||||
out.write(" \"http://www.w3.org/TR/html4/loose.dtd\">\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<html>\r\n");
|
||||
out.write(" <head>\r\n");
|
||||
out.write(" <meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\">\r\n");
|
||||
out.write("\t\t<link rel=\"stylesheet\" href=\"style.css\" type=\"text/css\" />\r\n");
|
||||
out.write(" <title>RandoOnLine - Payement</title>\r\n");
|
||||
out.write(" </head>\r\n");
|
||||
out.write(" <body>\r\n");
|
||||
out.write("\r\n");
|
||||
out.write(" <h1>RandoOnLine</h1>\r\n");
|
||||
out.write(" <table border=\"0\" width=\"100%\">\r\n");
|
||||
out.write(" <thead>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <th><a href=\"./index.jsp\">Accueil</a></th>\r\n");
|
||||
out.write(" <th><a href=\"./Panier\">Panier</a></th>\r\n");
|
||||
out.write(" <th><a href=\"./Articles\">Liste des articles</a></th>\r\n");
|
||||
out.write(" <th>Passer <20> la caisse</th>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </thead>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write(" \r\n");
|
||||
out.write(" <h2>Confirmation de la commande</h2>\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\t<p>Rappel de la commande :</p>\r\n");
|
||||
out.write(" <table border=\"0\" width=\"100%\">\r\n");
|
||||
out.write(" <thead>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <th>Reference</th>\r\n");
|
||||
out.write(" <th>Modele</th>\r\n");
|
||||
out.write(" <th>Prix</th>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </thead>\r\n");
|
||||
out.write(" <tbody>\r\n");
|
||||
if (_jspx_meth_c_005fforEach_005f0(_jspx_page_context))
|
||||
return;
|
||||
out.write("\r\n");
|
||||
out.write("\t\t\t<tr>\r\n");
|
||||
out.write(" <td colspan=\"2\" class=\"tabTotal\">Total :</td>\r\n");
|
||||
out.write(" <td>\r\n");
|
||||
com.articles.Panier panierTotal = null;
|
||||
synchronized (request) {
|
||||
panierTotal = (com.articles.Panier) _jspx_page_context.getAttribute("panierTotal", PageContext.REQUEST_SCOPE);
|
||||
if (panierTotal == null){
|
||||
panierTotal = new com.articles.Panier();
|
||||
_jspx_page_context.setAttribute("panierTotal", panierTotal, PageContext.REQUEST_SCOPE);
|
||||
}
|
||||
}
|
||||
out.write("\r\n");
|
||||
out.write("\t\t\t\t\t");
|
||||
out.write(org.apache.jasper.runtime.JspRuntimeLibrary.toString((((com.articles.Panier)_jspx_page_context.findAttribute("panierTotal")).getPrixTotal())));
|
||||
out.write("\r\n");
|
||||
out.write(" </td>\r\n");
|
||||
out.write("\t\t\t</tr>\r\n");
|
||||
out.write(" </tbody>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\t\t<hr width=\"100%\" size=\"1\">\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\t");
|
||||
com.articles.Client client = null;
|
||||
synchronized (request) {
|
||||
client = (com.articles.Client) _jspx_page_context.getAttribute("client", PageContext.REQUEST_SCOPE);
|
||||
if (client == null){
|
||||
client = new com.articles.Client();
|
||||
_jspx_page_context.setAttribute("client", client, PageContext.REQUEST_SCOPE);
|
||||
}
|
||||
}
|
||||
out.write("\r\n");
|
||||
out.write(" <p>Note : le payement se fera <20> la livraison de la commande <20> l'adresse suivante :<br />\r\n");
|
||||
out.write("\t\t");
|
||||
out.write(org.apache.jasper.runtime.JspRuntimeLibrary.toString((((com.articles.Client)_jspx_page_context.findAttribute("client")).getNom())));
|
||||
out.write(" ");
|
||||
out.write(org.apache.jasper.runtime.JspRuntimeLibrary.toString((((com.articles.Client)_jspx_page_context.findAttribute("client")).getPrenom())));
|
||||
out.write("<br />\r\n");
|
||||
out.write(" \t");
|
||||
out.write(org.apache.jasper.runtime.JspRuntimeLibrary.toString((((com.articles.Client)_jspx_page_context.findAttribute("client")).getAdresse())));
|
||||
out.write("<br />\r\n");
|
||||
out.write(" \t");
|
||||
out.write(org.apache.jasper.runtime.JspRuntimeLibrary.toString((((com.articles.Client)_jspx_page_context.findAttribute("client")).getCodePost())));
|
||||
out.write(" ");
|
||||
out.write(org.apache.jasper.runtime.JspRuntimeLibrary.toString((((com.articles.Client)_jspx_page_context.findAttribute("client")).getVille())));
|
||||
out.write("\r\n");
|
||||
out.write(" </p>\r\n");
|
||||
out.write(" </body>\r\n");
|
||||
out.write("</html>\r\n");
|
||||
} catch (Throwable t) {
|
||||
if (!(t instanceof SkipPageException)){
|
||||
out = _jspx_out;
|
||||
if (out != null && out.getBufferSize() != 0)
|
||||
try { out.clearBuffer(); } catch (java.io.IOException e) {}
|
||||
if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
|
||||
}
|
||||
} finally {
|
||||
_jspxFactory.releasePageContext(_jspx_page_context);
|
||||
}
|
||||
}
|
||||
|
||||
private boolean _jspx_meth_c_005fforEach_005f0(PageContext _jspx_page_context)
|
||||
throws Throwable {
|
||||
PageContext pageContext = _jspx_page_context;
|
||||
JspWriter out = _jspx_page_context.getOut();
|
||||
// c:forEach
|
||||
org.apache.taglibs.standard.tag.rt.core.ForEachTag _jspx_th_c_005fforEach_005f0 = (org.apache.taglibs.standard.tag.rt.core.ForEachTag) _005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.get(org.apache.taglibs.standard.tag.rt.core.ForEachTag.class);
|
||||
_jspx_th_c_005fforEach_005f0.setPageContext(_jspx_page_context);
|
||||
_jspx_th_c_005fforEach_005f0.setParent(null);
|
||||
// /resultPayement.jsp(41,0) name = items type = java.lang.Object reqTime = true required = false fragment = false deferredValue = false expectedTypeName = null deferredMethod = false methodSignature = null
|
||||
_jspx_th_c_005fforEach_005f0.setItems((java.lang.Object) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${articles}", java.lang.Object.class, (PageContext)_jspx_page_context, null, false));
|
||||
// /resultPayement.jsp(41,0) name = var type = java.lang.String reqTime = false required = false fragment = false deferredValue = false expectedTypeName = null deferredMethod = false methodSignature = null
|
||||
_jspx_th_c_005fforEach_005f0.setVar("artRef");
|
||||
int[] _jspx_push_body_count_c_005fforEach_005f0 = new int[] { 0 };
|
||||
try {
|
||||
int _jspx_eval_c_005fforEach_005f0 = _jspx_th_c_005fforEach_005f0.doStartTag();
|
||||
if (_jspx_eval_c_005fforEach_005f0 != javax.servlet.jsp.tagext.Tag.SKIP_BODY) {
|
||||
do {
|
||||
out.write("\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>\r\n");
|
||||
out.write(" \tRéférence : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.ref}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("\r\n");
|
||||
out.write(" </td>\r\n");
|
||||
out.write("\t\t\t\t<td>\r\n");
|
||||
out.write("\t\t\t\t\tModèle : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.modele}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("\r\n");
|
||||
out.write("\t\t\t\t</td>\r\n");
|
||||
out.write("\t <td>\r\n");
|
||||
out.write("\t \tPrix : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.prix}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("\r\n");
|
||||
out.write("\t </td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
int evalDoAfterBody = _jspx_th_c_005fforEach_005f0.doAfterBody();
|
||||
if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN)
|
||||
break;
|
||||
} while (true);
|
||||
}
|
||||
if (_jspx_th_c_005fforEach_005f0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
|
||||
return true;
|
||||
}
|
||||
} catch (Throwable _jspx_exception) {
|
||||
while (_jspx_push_body_count_c_005fforEach_005f0[0]-- > 0)
|
||||
out = _jspx_page_context.popBody();
|
||||
_jspx_th_c_005fforEach_005f0.doCatch(_jspx_exception);
|
||||
} finally {
|
||||
_jspx_th_c_005fforEach_005f0.doFinally();
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.reuse(_jspx_th_c_005fforEach_005f0);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
@ -0,0 +1,211 @@
|
||||
package org.apache.jsp;
|
||||
|
||||
import javax.servlet.*;
|
||||
import javax.servlet.http.*;
|
||||
import javax.servlet.jsp.*;
|
||||
|
||||
public final class resumePanier_jsp extends org.apache.jasper.runtime.HttpJspBase
|
||||
implements org.apache.jasper.runtime.JspSourceDependent {
|
||||
|
||||
private static final JspFactory _jspxFactory = JspFactory.getDefaultFactory();
|
||||
|
||||
private static java.util.List _jspx_dependants;
|
||||
|
||||
private org.apache.jasper.runtime.TagHandlerPool _005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems;
|
||||
|
||||
private javax.el.ExpressionFactory _el_expressionfactory;
|
||||
private org.apache.AnnotationProcessor _jsp_annotationprocessor;
|
||||
|
||||
public Object getDependants() {
|
||||
return _jspx_dependants;
|
||||
}
|
||||
|
||||
public void _jspInit() {
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems = org.apache.jasper.runtime.TagHandlerPool.getTagHandlerPool(getServletConfig());
|
||||
_el_expressionfactory = _jspxFactory.getJspApplicationContext(getServletConfig().getServletContext()).getExpressionFactory();
|
||||
_jsp_annotationprocessor = (org.apache.AnnotationProcessor) getServletConfig().getServletContext().getAttribute(org.apache.AnnotationProcessor.class.getName());
|
||||
}
|
||||
|
||||
public void _jspDestroy() {
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.release();
|
||||
}
|
||||
|
||||
public void _jspService(HttpServletRequest request, HttpServletResponse response)
|
||||
throws java.io.IOException, ServletException {
|
||||
|
||||
PageContext pageContext = null;
|
||||
HttpSession session = null;
|
||||
ServletContext application = null;
|
||||
ServletConfig config = null;
|
||||
JspWriter out = null;
|
||||
Object page = this;
|
||||
JspWriter _jspx_out = null;
|
||||
PageContext _jspx_page_context = null;
|
||||
|
||||
|
||||
try {
|
||||
response.setContentType("text/html;charset=UTF-8");
|
||||
pageContext = _jspxFactory.getPageContext(this, request, response,
|
||||
null, true, 8192, true);
|
||||
_jspx_page_context = pageContext;
|
||||
application = pageContext.getServletContext();
|
||||
config = pageContext.getServletConfig();
|
||||
session = pageContext.getSession();
|
||||
out = pageContext.getOut();
|
||||
_jspx_out = out;
|
||||
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.01 Transitional//EN\"\r\n");
|
||||
out.write(" \"http://www.w3.org/TR/html4/loose.dtd\">\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("<html>\r\n");
|
||||
out.write(" <head>\r\n");
|
||||
out.write(" <meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\">\r\n");
|
||||
out.write("\t\t<link rel=\"stylesheet\" href=\"style.css\" type=\"text/css\" />\r\n");
|
||||
out.write(" <title>RandoOnLine - Resume du Panier</title>\r\n");
|
||||
out.write(" </head>\r\n");
|
||||
out.write(" <body>\r\n");
|
||||
out.write("\r\n");
|
||||
out.write(" <h1>RandoOnLine</h1>\r\n");
|
||||
out.write(" <table border=\"0\" width=\"100%\">\r\n");
|
||||
out.write(" <thead>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <th><a href=\"./index.jsp\">Accueil</a></th>\r\n");
|
||||
out.write(" <th><a href=\"./Panier\">Panier</a></th>\r\n");
|
||||
out.write(" <th><a href=\"./Articles\">Liste des articles</a></th>\r\n");
|
||||
out.write(" <th>Passer <20> la caisse</th>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </thead>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write(" \r\n");
|
||||
out.write(" <h2>Contenu du Panier</h2>\r\n");
|
||||
out.write("\r\n");
|
||||
out.write("\t<form method=\"post\" action=\"./Client\">\r\n");
|
||||
out.write(" <table border=\"0\" width=\"100%\">\r\n");
|
||||
out.write(" <thead>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <th>Aper<65>u</th>\r\n");
|
||||
out.write(" <th>Propri<72>t<EFBFBD>s</th>\r\n");
|
||||
out.write(" <th>Quantit<69></th>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </thead>\r\n");
|
||||
out.write(" <tbody>\r\n");
|
||||
if (_jspx_meth_c_005fforEach_005f0(_jspx_page_context))
|
||||
return;
|
||||
out.write("\r\n");
|
||||
out.write("\t\t\t<tr>\r\n");
|
||||
out.write(" <td colspan=\"2\" class=\"tabTotal\">Total :</td>\r\n");
|
||||
out.write(" <td>\r\n");
|
||||
com.articles.Panier panierTotal = null;
|
||||
synchronized (request) {
|
||||
panierTotal = (com.articles.Panier) _jspx_page_context.getAttribute("panierTotal", PageContext.REQUEST_SCOPE);
|
||||
if (panierTotal == null){
|
||||
panierTotal = new com.articles.Panier();
|
||||
_jspx_page_context.setAttribute("panierTotal", panierTotal, PageContext.REQUEST_SCOPE);
|
||||
}
|
||||
}
|
||||
out.write("\r\n");
|
||||
out.write("\t\t\t\t\t");
|
||||
out.write(org.apache.jasper.runtime.JspRuntimeLibrary.toString((((com.articles.Panier)_jspx_page_context.findAttribute("panierTotal")).getPrixTotal())));
|
||||
out.write("\r\n");
|
||||
out.write(" </td>\r\n");
|
||||
out.write("\t\t\t</tr>\r\n");
|
||||
out.write(" </tbody>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write(" <br />\r\n");
|
||||
out.write(" <input type=\"button\" value=\"Annuler\" onclick=\"javascript:document.location='./index.jsp'\" /> \r\n");
|
||||
out.write(" <input type=\"submit\" value=\"Valider\" />\r\n");
|
||||
out.write("\t</form>\r\n");
|
||||
out.write(" </body>\r\n");
|
||||
out.write("</html>\r\n");
|
||||
} catch (Throwable t) {
|
||||
if (!(t instanceof SkipPageException)){
|
||||
out = _jspx_out;
|
||||
if (out != null && out.getBufferSize() != 0)
|
||||
try { out.clearBuffer(); } catch (java.io.IOException e) {}
|
||||
if (_jspx_page_context != null) _jspx_page_context.handlePageException(t);
|
||||
}
|
||||
} finally {
|
||||
_jspxFactory.releasePageContext(_jspx_page_context);
|
||||
}
|
||||
}
|
||||
|
||||
private boolean _jspx_meth_c_005fforEach_005f0(PageContext _jspx_page_context)
|
||||
throws Throwable {
|
||||
PageContext pageContext = _jspx_page_context;
|
||||
JspWriter out = _jspx_page_context.getOut();
|
||||
// c:forEach
|
||||
org.apache.taglibs.standard.tag.rt.core.ForEachTag _jspx_th_c_005fforEach_005f0 = (org.apache.taglibs.standard.tag.rt.core.ForEachTag) _005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.get(org.apache.taglibs.standard.tag.rt.core.ForEachTag.class);
|
||||
_jspx_th_c_005fforEach_005f0.setPageContext(_jspx_page_context);
|
||||
_jspx_th_c_005fforEach_005f0.setParent(null);
|
||||
// /resumePanier.jsp(41,0) name = items type = java.lang.Object reqTime = true required = false fragment = false deferredValue = false expectedTypeName = null deferredMethod = false methodSignature = null
|
||||
_jspx_th_c_005fforEach_005f0.setItems((java.lang.Object) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${articles}", java.lang.Object.class, (PageContext)_jspx_page_context, null, false));
|
||||
// /resumePanier.jsp(41,0) name = var type = java.lang.String reqTime = false required = false fragment = false deferredValue = false expectedTypeName = null deferredMethod = false methodSignature = null
|
||||
_jspx_th_c_005fforEach_005f0.setVar("artRef");
|
||||
int[] _jspx_push_body_count_c_005fforEach_005f0 = new int[] { 0 };
|
||||
try {
|
||||
int _jspx_eval_c_005fforEach_005f0 = _jspx_th_c_005fforEach_005f0.doStartTag();
|
||||
if (_jspx_eval_c_005fforEach_005f0 != javax.servlet.jsp.tagext.Tag.SKIP_BODY) {
|
||||
do {
|
||||
out.write("\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>\r\n");
|
||||
out.write(" <img src=\"./img/");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.photo}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("\" width=\"50\" height=\"50\" alt=\"image\"/>\r\n");
|
||||
out.write(" </td>\r\n");
|
||||
out.write(" <td>\r\n");
|
||||
out.write(" <table border=\"0\" width=\"100%\" height=\"100%\">\r\n");
|
||||
out.write(" <tbody>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>Référence : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.ref}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("</td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>Marque : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.marque}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("</td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>Modèle : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.modele}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("</td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" <tr>\r\n");
|
||||
out.write(" <td>Prix : ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.prix}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("</td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
out.write(" </tbody>\r\n");
|
||||
out.write(" </table>\r\n");
|
||||
out.write(" </td>\r\n");
|
||||
out.write(" <td>\r\n");
|
||||
out.write(" ");
|
||||
out.write((java.lang.String) org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate("${artRef.quantite}", java.lang.String.class, (PageContext)_jspx_page_context, null, false));
|
||||
out.write("\r\n");
|
||||
out.write(" </td>\r\n");
|
||||
out.write(" </tr>\r\n");
|
||||
int evalDoAfterBody = _jspx_th_c_005fforEach_005f0.doAfterBody();
|
||||
if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN)
|
||||
break;
|
||||
} while (true);
|
||||
}
|
||||
if (_jspx_th_c_005fforEach_005f0.doEndTag() == javax.servlet.jsp.tagext.Tag.SKIP_PAGE) {
|
||||
return true;
|
||||
}
|
||||
} catch (Throwable _jspx_exception) {
|
||||
while (_jspx_push_body_count_c_005fforEach_005f0[0]-- > 0)
|
||||
out = _jspx_page_context.popBody();
|
||||
_jspx_th_c_005fforEach_005f0.doCatch(_jspx_exception);
|
||||
} finally {
|
||||
_jspx_th_c_005fforEach_005f0.doFinally();
|
||||
_005fjspx_005ftagPool_005fc_005fforEach_005fvar_005fitems.reuse(_jspx_th_c_005fforEach_005f0);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|