<%
/******************************************************************************
 * Copyright (c) 2000-2005 e-Deal
 *
 * e-Deal S.A.
 * 55 rue Brillat Savarin
 * 75013 Paris
 * France
 *
 * T: +33 (0)1 53 80 80 30
 * F: +33 (0)1 73 01 69 77
 * http://www.e-deal.com
 * 
 * La diffusion de ce code source sous quelque forme que ce soit sans
 * l'autorisation de E-DEAL est interdite.
 *
 * Vous êtes autorisés à modifier ce code source uniquement pour votre usage
 * propre et sous réserve que les mentions de copyright demeurent intactes.
 *
 * Ce code est fourni en l'état. Aucune garantie d'aucune sorte, explicite ou
 * implicite n'est donnée. En aucun cas E-DEAL ne pourra être tenu pour
 * responsable des dommages pouvant résulter de l'utilisation de ce code
 * source.
 ******************************************************************************/
%>
<%@page session="true" import="com.edeal.frontline.*"%>
<%@page import="java.util.*" %>
<%@taglib uri="http://www.e-deal.com/taglib/fl" prefix="fl" %>
<%@taglib uri="http://www.e-deal.com/taglib/ft" prefix="ft" %>
<%@ page import="com.edeal.frontline.navigation.FlRequest" %>
<jsp:useBean class="com.edeal.frontline.SupplierBean" id="Supplier" scope="request"/>
<%
	final org.apache.commons.logging.Log logger = org.apache.commons.logging.LogFactory.getLog(getClass());
	FlRequest flRequest = new FlRequest(request);
	FlContext context = flRequest.getContext();
	String id = Supplier.getSplID();

	String mailC = "";
	try{
		mailC="mailto:"+Supplier.getSplContactMail() +" <"+Supplier.getSplContactMail()+">";
		}catch(FieldNotInitializedException fnie){}
	
	String mailA = "";
	try{
		mailA="mailto:"+Supplier.getSplAsst()+" <"+Supplier.getSplAsstMail()+">";
		}catch(FieldNotInitializedException fnie){}	
		
  String splZip = null;
  try{
  	splZip = Supplier.getSplZip();
  }catch(FieldNotInitializedException fnie){}	
  
  String splCity =null;
    try{
    	splCity = Supplier.getSplCity();
    }catch(FieldNotInitializedException fnie){}
%>
<link href="<fl:webapp/>/css/smalltabs_css.jsp" rel="stylesheet" type="text/css">

<fl:bigTabs objectTitle="<%=Utils.getMessage(session, \"L63E9\", false, true, \"Fournisseur\")%>" ou="<%=\"/read_supplier.fl?id=\"+id%>">
	<table class="container" cellpadding="0">
		<tr class="fieldline">
			<td colspan="3" class="titreFiche">
				<fl:getProperty name="Supplier" property="SplRS" alt="&nbsp;" />
			</td>
		</tr>		
		<tr class="ligne_separation"><td colspan="3"></td></tr>		
		<tr>
			<td class="column2">
				<table class="container" cellpadding="0">
					<fl:fieldRead property="SplCode" alt="Statut" />
					<fl:fieldRead property="SplStatut" alt="Statut" />
					<tr class="fieldline">
						<td class="dataLabel">
							<fl:getMessage code="F2012" alt="Adresse"/>
						</td>
						<td class="dataValue">
							<fl:getProperty name="Supplier" property="SplAd1" alt="" postText="<br>"/>
							<fl:getProperty name="Supplier" property="SplAd2" alt="" postText="<br>"/>
							<fl:getProperty name="Supplier" property="SplAd3" alt="" postText="<br>"/>
							<fl:getProperty name="Supplier" property="SplZip" alt="" postText="&nbsp;"/><fl:getProperty name="Supplier" property="SplCity" alt="" postText=""/>
							<fl:getProperty name="Supplier" property="SplCtrID" alt="&nbsp;" preText="<%= (splZip != null && splCity == null) ? \"<br>\" : \"\"%>"/>						
						</td>
					</tr>
					<fl:fieldRead property="SplTel" alt="&nbsp;" format="phone" />
				</table>
			</td>
			<td class="separation"><div class="separation"></div></td>			
			<td class="column2">
				<table class="container" cellpadding="0">									
					<fl:fieldRead property="SplFax" alt="&nbsp;" />	
					<tr class="fieldline">							
						<td class="dataLabel">
							<fl:getMessage code="L0055" alt="Web"/>
						</td>
						<td class="dataValue">
							<a href="<fl:getProperty name="Supplier" property="SplWeb" alt=""/>" target="_blank"><fl:getProperty name="Supplier" property="SplWeb" alt=""/></a>
						</td>
					</tr>
					<fl:fieldRead property="SplContact" alt="&nbsp;" bean="true"/>
					<fl:fieldRead property="SplContactTel" format="phone" alt="&nbsp;" />
					<fl:fieldRead property="SplContactMail">
						<ft:email/>
					</fl:fieldRead>	
					<fl:fieldRead property="SplAsst" alt="&nbsp;" bean="true"/>
					<fl:fieldRead property="SplAsstTel" format="phone" alt="&nbsp;" />
					<fl:fieldRead property="SplAsstMail">
						<ft:email/>
					</fl:fieldRead>			
				</table>			
			</td>
		</tr>	
	</table>
	<fl:notes name="SplNotes" title="<%= Utils.getMessage(session, \"F2024\", \"Notes\") %>" nbPix="30"><fl:getProperty name="Supplier" property="SplNotes" alt=""/></fl:notes>
	<fl:smallTabs name="FournisseurTabs">
		<fl:sTab id="FAMILY" title="<%= Utils.getMessage(session, \"L63E9\", \"Fournisseur\") %>" hideLink="true">
			<table class="container" cellpadding="0">
				<tr>
					<td class="column2">
						<table class="container" cellpadding="0">
							<fl:fieldRead property="SplFamilles"/>
						</table>
					</td>
					<td class="separation"><div class="separation"></div></td>		
					<td class="column2">&nbsp;</td>
				</tr>
			</table>
		</fl:sTab>
		<fl:sTab id="SUPPLIER1" title="<%= context.getAutoDisplayManager().getTitle(session, \"Supplier\", \"Supplier 1\") %>" visible="<%= context.getAutoDisplayManager().hasEntry(\"Supplier\", \"Supplier 1\") %>">
			<fl:autodisplay name="Supplier" zone="Supplier 1"/>
		</fl:sTab>
	</fl:smallTabs>
</fl:bigTabs>

