{% extends 'layout.twig' %}

{% block body %}

<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<div class="contenu clearfix"  id="marche">
    <h1>
        {{'Marché' | trad }}                       
    </h1>
            
    {{ ariane() }}
    
    <div id="visualisation_marche">
        <h2>{{'Visualisation Marché' | trad }} {{ marche.LIBELLE }} {% if marche.STEMARCHE != '' %} ({{ marche.CODE }}) {% endif %}</h2>
        <div class="colonne2">
            <div class="block_edition">
                <div class="titre_block">
                    {{'Marché' | trad }}
                </div>
                <div class="colonne2 conditions">
                    <div class="informations">
                        <p>
                            <span class="champs_label">{{'Marché' | trad }} : </span>
                            <span class="resultat"> {{ marche.CODE }} </span>
                        </p>
                    </div>
                </div>
                <div class="colonne2 conditions">
                    <div class="informations">
                        <p>
                            <span class="champs_label">{{'Validité du' | trad }} : </span>
                            <span class="resultat">{{ marche.DDEBVAL | dateTrad}}</span>
                        </p>
                        <p>
                            <span class="champs_label">{{'Validité au' | trad }} : </span>
                            <span class="resultat">{{ marche.DFINVAL | dateTrad}}</span>
                        </p>
                    </div>
                </div>
            </div>
            <div class="block_edition">
                <div class="titre_block">
                    {{'Conditions' | trad }}
                </div>
                <div class="colonne2">
                    <div class="informations conditions">
                        <p>
                            <span class="champs_label">{{'Condition de paiement' | trad }}: </span>
                            <span class="resultat">
                                {% if condPaie %} 
                                    {{ condPaie.LIBELLE }} ({{ condPaie.CODE_CDP }})
                                {% endif %}
                            </span>
                        </p>
                        <p>
                            <span class="champs_label">{{'Mode de paiement' | trad }} : </span>
                            <span class="resultat">
                                {% if modePaie %}
                                    {{ modePaie.LIBELLE }} ({{ modePaie.CODE_MDP }})
                                {% endif %}
                            </span>
                        </p>
                    </div>
                </div>
                <div class="colonne2 montant">
                    <div class="informations">
                        <p>
                            <span class="champs_label">{{'Mode de livraison' | trad}} : </span>
                            <span class="resultat">
                                {% if modeLivr %}
                                    {{ modeLivr.LIBELLE }} ({{ marche.MODELIV }})
                                {% endif %}
                            </span>
                        </p>
                        <p>
                            <span class="champs_label">{{'Délai de livraison' | trad}} : </span>
                            <span class="resultat">{{ marche.DELAILIV }}</span>
                        </p>
                    </div>
                </div>
                <div class="full" style="margin:1%!important;width:98%!important;">
                    <div class="informations">
                        <p>
                            <span class="champs_label">{{'Commentaires' | trad }}: </span>
                            <span class="resultat">{{ marcheCommentaire.CONTMEMO | nl2br }}</span>
                        </p>
                    </div>
                </div>
            </div>
        </div>
        <div class="colonne2 last">
            <div class="block_edition">
                <div class="titre_block">
                    {{'Informations' | trad }}
                    <div class="parametrage" >
                        <span class="parametre ferme"></span>
                        <ul class="ss_parametres" >

                            <li><a href="javascript:void(0)" onclick="ajaxPopup ('{{ path('Contrat.marche-popup.cumulACD', {'id' : marche.CODE}) }}', 'Cumul ACD' , 'name', 'name')" data-toggle="modal" data-target="#cumuls_acd">{{'Cumuls ACD' | trad}}</a></li>
                            <li><a href="javascript:void(0)" onclick="ajaxPopup ('{{ path('Contrat.marche-popup.cumulSOC', {'id' : marche.CODE}) }}', 'Cumul Societe', 'name', 'name')" data-toggle="modal" data-target="#cumuls_societes">{{'Cumuls Sociétés' | trad }}</a></li>
                        </ul>
                    </div>
                </div>
                <div class="colonne2">
                    <div class="informations conditions">
                        <p>
                            <span class="champs_label">{{'Type de marché' | trad}} : </span>
                            <span class="resultat">
                                {% if typeMarche %} 
                                    {{ typeMarche.LIBELLE }} ({{ typeMarche.CODE_TYMA }})
                                {% endif %}
                            </span>
                        </p>
                        <p>
                            <span class="champs_label">{{'Société de rattachement' | trad}} : </span>
                            <span class="resultat">
                                {% if societe %}
                                    {{ societe.RAIS_SOC }} ({{ societe.CODE_STE }})
                                {% endif %}
                            </span>
                        </p>
                        <p>
                            <span class="champs_label">{{'Achet' | trad}} : </span>
                            <span class="resultat">
                                {% if marche.ACHETEURCODE | trim != '' %} 
                                    {{ utiliMap[ marche.ACHETEURCODE ].NOM }}
                                    ({{ marche.ACHETEURCODE }}) 
                                {% endif %}
                            </span>
                        </p>
                        <p>
                            <span class="champs_label">{{'Signataire' | trad}} : </span>
                            <span class="resultat">
                                {% if marche.SIGNATAIR | trim != '' %} 
                                    {{ utiliMap[ marche.SIGNATAIR ].NOM }} 
                                    ({{ marche.SIGNATAIR }}) 
                                {% endif %}
                            </span>
                        </p>
                    </div>
                </div>
                <div class="colonne2">
                    <div class="informations">
                        <p>
                            <span class="champs_label">{{'Prévisionnel Mini' | trad }} : </span>
                            <span class="resultat">{{ marche.MNTPREMIN | prix}} {{ devise }}</span>
                        </p>
                        <p>
                            <span class="champs_label">{{'Prévisionnel Maxi' | trad }}: </span>
                            <span class="resultat">{{ marche.MNTPREMAX | prix}} {{ devise }}</span>
                        </p>                                    
                    </div>
                </div>
            </div>
            
            {% if listeCS %} 
            <div class="block_edition supplementaire">
            
                <div class="titre_block">
                    {{'Supplémentaire' | trad}}
                </div>

                {{ VisualisationCS('MARCHES', marche.CODE) }}
            </div>
            {% endif %}
        </div>
    </div>
</div>
   

 
{% endblock %}