<?php
/****************************************************************************************
SMI (Services Maintenance Interventions) est une gestion libre de maintenance et de SAV

Version 1.0.0

Copyright (C) 2006-2014  Sylvain FATOME
This program is free software; you can redistribute it and/or modify it under the terms
of the GNU General Public License as published by the Free Software Foundation; 
either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; 
without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program
(in the directory docs); 
if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 
Boston, MA  02110-1301, USA.

Contact : galawa@free.fr

Web : http://smi.no-ip.org
 ****************************************************************************************/

session_start();

require_once("../lib/gettext/gettext.inc");
include_once("../inc/config.inc.php");
include_once("../inc/func_log.inc.php");
if (CheckURLLog(FALSE) == FALSE) header("Location: ../index.php");
if (CheckNivLog("10-11") == FALSE) header("Location: ../index.php");

include_once("../inc/fic_cli.inc.php");
include_once("../inc/fic_droits.inc.php");
include_once("../inc/fic_fici.inc.php");
include_once("../inc/fic_prm.inc.php");
include_once("../inc/fic_statut.inc.php");
include_once("../inc/func.inc.php");
include_once("../inc/func_date.inc.php");
include_once("../inc/func_time.inc.php");
include_once("../inc/func_txt.inc.php");
include_once("../inc/func_geo.inc.php");
include_once("../inc/lst.inc.php");
include_once("../classes/dirtool/class_dirtool.php");
include_once("../classes/ezSQL/shared/ez_sql_core.php");
include_once("../classes/ezSQL/mysqli/ez_sql_mysqli.php");
include_once("../inc/func_sql.inc.php");
Archivelog(@$_SESSION["code_log"]);
$pbm_conf = FALSE;
if (!exist_logo("cge")) $pbm_conf = TRUE;
if (!exist_logo(@$_SESSION["code_st"])) $pbm_conf = TRUE;
if (!existe_cdg()) $pbm_conf = TRUE;
$tx = "m";
?>
    <!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">
        <title>SMI - <?PHP echo _("ESPACE PRIVE"); ?> : <?PHP echo _("Index Sous-Traitant"); ?></title>

        <?PHP include_once("../inc/header.inc.php"); ?>

        <script type="text/javascript">
            <!--
            function init_all() {
                init_Body();
                $( "#onglets_idx" ).tabs();
                init_autohref_classe('falselnkimg','<?PHP echo str_escape(_("Merci de confirmer").'<br />'._("Sinon, cliquez sur 'Annuler'")); ?>');
                warn_taches("<?php echo $nbtaches; ?>");
                Focus_first();
            }

            $(document).ready(function () {
                init_all();
            });
            //-->
        </script>

    </head>

<body>

<?php
if ($pbm_conf == FALSE) {
    include_once("../inc/entete.inc.php");
    ?>
    <p align="center"><span class="titrepage"><?PHP echo _("VOTRE TABLEAU DE BORD"); ?></span><br /></p>
    <div id="onglets_idx">
    <ul>
        <li><a href="#idx_tac"><?PHP echo _("Tâches à effectuer"); ?></a></li>
        <li><a href="#idx_btc"><?PHP echo _("Bons de travail en cours"); ?></a></li>
        <li><a href="#idx_bta"><?PHP echo _("Bons de travail à affecter"); ?></a></li>
    </ul>
    <div id="idx_tac">
    <?PHP
    $db = open_database(DBUSER, DBPASS, DBNAME, DBHOST);

    $rech = cree_strrechlsttac();
    switch (@$_SESSION["niv_log"]) {
        // Filtre pour les techniciens sous-traitants
        case 11 :
            if (!stristr($rech, "WHERE "))
                $rech .= " WHERE " . TBTAC . ".tac_codedest='" . @$_SESSION["code_log"] . "'";
            else
                $rech .= " AND " . TBTAC . ".tac_codedest='" . @$_SESSION["code_log"] . "'";
            break;
        // Filtre pour les sous-traitants
        case 10 :
            // On construit la liste des techniciens actifs du sous-traitant
            $tab_lst_tec = [];
            $rech2 = "SELECT tec_code FROM `" . TBTEC . "` WHERE tec_codest='" . @$_SESSION["code_log"] . "' AND tec_out=0";
            $rows2 = $db->get_results($rech2, ARRAY_A);
            if ($rows2) {
                foreach ($rows2 as $row2) {
                    extract($row2);
                    $tab_lst_tec[] = $tec_code;
                }
            }

            if (!stristr($rech, "WHERE "))
                $rech .= " WHERE (" . TBTAC . ".tac_codedest='" . @$_SESSION["code_log"] . "'";
            else
                $rech .= " AND (" . TBTAC . ".tac_codedest='" . @$_SESSION["code_log"] . "'";
            if (count($tab_lst_tec) > 0) {
                foreach ($tab_lst_tec as $key => $value) {
                    $rech .= " OR " . TBTAC . ".tac_codedest='" . $value . "'";
                }
            }
            $rech .= ")";
            break;
    }

    if (!stristr($rech, "WHERE "))
        $rech .= " WHERE tac_datefin='0000-00-00'";
    else
        $rech .= " AND tac_datefin='0000-00-00'";
    $rech .= "ORDER BY " . TBTAC . ".tac_code DESC";

    $rows = $db->get_results($rech, ARRAY_A);

    if ($rows) {
        $numrows = count($rows);
        $nbtaches = $numrows;
        // *** Affichage de la table
        echo "<table class=\"Mtable\" border=\"0\" width=\"100%\" cellpadding=\"0\" cellspacing=\"0\">\n";

        // création entête
        titlst($tac_titre_col, FALSE);
        echo "<th>" . _("Cliquer") . "</th>\n";

        $i = 0;

        // Inclusion module affichage liste tâches
        include_once("../inc/tacr_lst.inc.php");

        echo "</table>\n";
        // *** Fin affichage de la table
    } else {
        echo "<div class=\"annot_gras_it\">";
        echo "<br />" . _("Pas de tâche en cours");
        echo "</div>";
    }

    $db->disconnect();

    $taille_piedla = "";
    include("../inc/piedla.inc.php");
    ?>
    </div>

    <div id="idx_btc">
    <?PHP
    $db = open_database(DBUSER, DBPASS, DBNAME, DBHOST);

    $rech = cree_strrechlstotst();
    if (!stristr($rech, "WHERE "))
        $rech .= " WHERE " . TBOT . ".ot_codest='" . @$_SESSION["code_st"] . "' AND " . TBOT . ".ot_codetec <> '-1' AND " . TBOT . ".ot_codestatut <> 'CLOT'";
    else
        $rech .= " AND " . TBOT . ".ot_codest='" . @$_SESSION["code_st"] . "' AND " . TBOT . ".ot_codetec <> '-1' AND " . TBOT . ".ot_codestatut <> 'CLOT'";

    $rech .= "ORDER BY " . TBOT . ".ot_code DESC";
    // *** Fin de chaîne de Recherche

    $rows = $db->get_results($rech, ARRAY_A);

    if ($rows) {
        $numrows = count($rows);
        echo "<span class=\"annot_std_it\">";
        echo "(" . _("Lieu/Statut : laisser la souris sur l'icône pour le détail") . "<br />";
        echo "</span>";

        // *** Affichage de la table
        echo "<table class=\"Mtable\" border=\"0\" width=\"100%\" cellpadding=\"0\" cellspacing=\"0\">\n";

        // création entête
        titlst($ot2_titre_col);
        echo "<th>" . _("Cliquer") . "</th>\n";

        $i = 0;

        foreach ($rows as $row) {
            $row = encode_str($row);
            // Affichage résumé ordre

            // création de l'entête de ligne (TR)
            creetrlst($i);

            echo "<td>";
            echo $row["ot_code"];
            $detfic = ">>" . _("Matériel") . " :<br />" . $row["ot_mat"] . "<br /><br />>>" . _("Travail à effectuer") . " :<br />" . $row["ot_pbm"];
            if ($detfic <> "")
                echo ' <a href="#" class="pop"><img src="../img/help.png" alt="'._("Détail").'" border="0" align="absmiddle"><span>' . formatetxtbr($detfic) . '</span></a>';
            echo "</td>\n";

            echo "<td>";
            echo "<div align=\"center\">";
            echo datetolocal($row["ot_datedde"]);
            echo "</div>";
            echo "</td>\n";
            echo "<td align=\"center\">";
            echo datetolocal($row["ot_daterdv"]);
            if (datetolocal($row["ot_daterdv"]) <> "") {
                echo "<div align=\"center\" class=\"annot_petit_it\">";
                echo substr($row["ot_hrdv"], 0, 5);
                echo "</div>";
            }
            echo "</td>\n";

            // Affichage icône Lieu
            echo "<td>";
            $lieu = $row["ot_codelieu"];
            $rech2 = "SELECT * FROM `" . TBLIEU . "` WHERE lieu_code = '$lieu'";

            $row2 = $db->get_row($rech2, ARRAY_A);

            if ($row2) {
                $row2 = encode_str($row2);
                extract($row2);
                if ($lieu_img <> "") {
                    $lieuint = $lieu_desc . " (" . $lieu . ")";
                    echo "<div style=\"float:left;width:40px;\">";
                    echo "<img src=\"" . $lieu_img . "\" title=\"" . $lieuint . "\" border=\"0\" align=\"absmiddle\">";
                    echo "</div>";
                } else {
                    echo "<span class=\"annot_std_it\" style=\"float:left;\">";
                    echo $lieu;
                    echo "</span>";
                }
            }

            // Affichage site client
            $sitecli = "";
            switch (trim($row["ot_idsite"])) {
                case "0" :
                    $row2 = lit_enr_cli($row["ot_codecli"], FALSE);
                    if (is_array($row2)) {
                        $row2 = encode_str($row2);
                        extract($row2);
                        $sitecli .= "<strong>";
                        if ($cli_ste <> "")
                            $sitecli .= $cli_ste . "<br />";
                        else
                            $sitecli .= $cli_civilite . " " . $cli_prenom . " " . $cli_nom . "<br />";
                        $sitecli .= "</strong>";
                        $sitecli .= $cli_adr1 . "<br />";
                        if ($cli_adr2 <> "")
                            $sitecli .= $cli_adr2 . "<br />";
                        $sitecli .= Retournecp_Id($cli_ville, FALSE) . " " . Retourneville_Id($cli_ville, FALSE) . "<br />";
                    }
                    break;
                default :
                    $rech2 = "SELECT * FROM `" . TBSCLI . "` WHERE `scli_id` = '" . trim($row["ot_idsite"]) . "'";
                    $row2 = $db->get_row($rech2, ARRAY_A);
                    if ($row2) {
                        extract($row2);
                        $sitecli .= "<strong>";
                        $sitecli .= $scli_ste . "<br />";
                        $sitecli .= "</strong>";
                        $sitecli .= $scli_adr1 . "<br />";
                        if ($scli_adr2 <> "")
                            $sitecli .= $scli_adr2 . "<br />";
                        $sitecli .= Retournecp_Id($scli_ville, FALSE) . " " . Retourneville_Id($scli_ville, FALSE) . "<br />";
                    }
            }

            if ($sitecli <> "") {
                echo "<div class=\"annot_petit_it\" style=\"float:left;\">";
                echo $sitecli;
                echo "</div>";
            }

            echo "</td>\n";

            // Affichage détail urgence
            echo '<td ';
            $couleur = give_coul_urg($row["ot_urg"], FALSE);
            if ($couleur <> "XX")
                echo ' style="background:' . $couleur . '"';
            echo ' align="center">';
            echo give_nom_urg($row["ot_urg"], FALSE);;
            echo "</td>\n";
            // Fin affichage détail urgence

            // Affichage technicien traitant
            echo "<td align=\"center\">";
            if (($row["ot_codetec"] <> "") AND ($row["ot_codetec"] <> "-1"))
                echo $row["ot_codetec"];
            else
                echo "&nbsp;";
            echo "</td>\n";

            // Affichage icône Statut
            echo "<td align=\"center\">";
            $statut = $row["ot_codestatut"];
            $rech2 = "SELECT * FROM `" . TBSTA . "` WHERE statut_code = '$statut'";

            $row2 = $db->get_row($rech2, ARRAY_A);

            if ($row2) {
                $row2 = encode_str($row2);
                extract($row2);
                if ($statut_img <> "") {
                    $statint = $statut_desc . " (" . $statut . ")";
                    echo "<img src=\"" . $statut_img . "\" title=\"" . $statint . "\" border=\"0\" align=\"absmiddle\">";
                } else {
                    echo "<span class=\"annot_std_it\">";
                    echo $statut;
                    echo "</span>";
                }
            }

            echo "</td>\n";

            // CREATION lien dynamique sur icône (édition, suppression, etc...)
            echo "<td align=\"center\">";

            $rech2 = "SELECT int_idsite, int_codecli FROM `" . TBINT . "` WHERE `int_code` = '" . $row["ot_codeint"] . "'";
            $row2 = $db->get_row($rech2, ARRAY_A);
            if ($row2) {
                $row2 = encode_str($row2);
                extract($row2);
            }

            if ($row["ot_codestatut"] <> "CLOT") {
                $lst_maj = TRUE;
                cre_falselnk_img('', 'ot_edit_'.$row["ot_id"], 'span', 'center', _("Edition"), 'lnk', 'ot_maj.php?tx=' . $tx . '&td=edit&ca=' . $ca . '&cas=' . $cas . '&ci=&cc=' . $row["ot_codecli"] . '&co=' . $row["ot_code"] . '&si=' . $row["ot_idsite"] . '&tr=', '../img/edit.png');
            } else {
                $lst_voir = TRUE;
                cre_falselnk_img('', 'ot_view_'.$row["ot_id"], 'span', 'center', _("Visualisation"), 'lnk', 'ot_maj.php?tx=' . $tx . '&td=view&ca=' . $ca . '&cas=' . $cas . '&ci=&cc=' . $row["ot_codecli"] . '&co=' . $row["ot_code"] . '&si=' . $row["ot_idsite"] . '&tr=', '../img/eye.png');
            }

            $lst_imp = TRUE;
            $urlimp = "ot_pdf.php?co=" . $row["ot_code"];
            cre_falselnk_img('', 'ot_prn_'.$row["ot_id"], 'span', 'center', _("Impression"), 'lnkpop', $urlimp, '../img/print.png');

            if ($row["ot_codestatut"] <> "CLOT") {
                $del = TRUE;
                if ((@$_SESSION["niv_log"] == 11) OR (@$_SESSION["niv_log"] == 10))
                    $del = FALSE;

                if ($del == TRUE) {
                    $lst_del = TRUE;
                    cre_falselnk_img('', 'ot_del_'.$row["ot_id"], 'span', 'center', _("Suppression"), 'lnk', 'ot_maj.php?tx=' . $tx . '&td=del&ca=' . $ca . '&cas=' . $cas . '&ci=&cc=' . $row["ot_codecli"] . '&co=' . $row["ot_code"] . '&si=' . $row["ot_idsite"] . '&tr=', '../img/del.png');
                }
            }
            echo "</td>\n";

            echo "</tr>\n";
            // Fin affichage résumé ordre

            $i++;
        }
        echo "</table>\n";
        // *** Fin affichage de la table
    } else {
        echo "<span class=\"annot_gras_it\">";
        echo "<br / ><br / >" . _("Pas de bons de travail en cours");
        echo "</span>";
    }

    $db->disconnect();

    $taille_piedla = "";
    include("../inc/piedla.inc.php");
    ?>
    </div>

    <div id="idx_bta">
    <?PHP
    $db = open_database(DBUSER, DBPASS, DBNAME, DBHOST);

    $rech = cree_strrechlstotst();
    if (!stristr($rech, "WHERE "))
        $rech .= " WHERE " . TBOT . ".ot_codest='" . @$_SESSION["code_st"] . "' AND " . TBOT . ".ot_codetec = '-1'";
    else
        $rech .= " AND " . TBOT . ".ot_codest='" . @$_SESSION["code_st"] . "' AND " . TBOT . ".ot_codetec = '-1'";

    $rech .= " ORDER BY " . TBOT . ".ot_code DESC";
    // *** Fin de chaîne de Recherche

    $rows = $db->get_results($rech, ARRAY_A);

    if ($rows) {
        $numrows = count($rows);
        echo "<span class=\"annot_std_it\">";
        echo "(" . _("Lieu/Statut : laisser la souris sur l'icône pour le détail") . ")<br />";
        echo "</span>";

        // *** Affichage de la table
        echo "<table class=\"Mtable\" border=\"0\" width=\"100%\" cellpadding=\"0\" cellspacing=\"0\">\n";

        // création entête
        titlst($ot2_titre_col);
        echo "<th>" . _("Cliquer") . "</th>\n";

        $i = 0;

        foreach ($rows as $row) {
            $row = encode_str($row);
            // Affichage résumé ordre

            // création de l'entête de ligne (TR)
            creetrlst($i);

            echo "<td>";
            echo $row["ot_code"];
            $detfic = ">>" . _("Matériel") . " :<br />" . $row["ot_mat"] . "<br /><br />>>" . _("Travail à effectuer") . " :<br />" . $row["ot_pbm"];
            if ($detfic <> "")
                echo ' <a href="#" class="pop"><img src="../img/help.png" alt="'._("Détail").'" border="0" align="absmiddle"><span>' . formatetxtbr($detfic) . '</span></a>';

            echo "</td>\n";

            echo "<td align=\"center\">";
            echo datetolocal($row["ot_datedde"]);
            echo "</td>\n";
            echo "<td align=\"center\">";
            echo datetolocal($row["ot_daterdv"]);
            if (datetolocal($row["ot_daterdv"]) <> "") {
                echo "<div align=\"center\" class=\"annot_petit_it\">";
                echo substr($row["ot_hrdv"], 0, 5);
                echo "</div>";
            }
            echo "</td>\n";

            // Affichage icône Lieu
            echo "<td>";
            $lieu = $row["ot_codelieu"];
            $rech2 = "SELECT * FROM `" . TBLIEU . "` WHERE lieu_code = '$lieu'";

            $row2 = $db->get_row($rech2, ARRAY_A);

            if ($row2) {
                $row2 = encode_str($row2);
                extract($row2);
                if ($lieu_img <> "") {
                    $lieuint = $lieu_desc . " (" . $lieu . ")";
                    echo "<div style=\"float:left;width:40px;\">";
                    echo "<img src=\"" . $lieu_img . "\" title=\"" . $lieuint . "\" border=\"0\" align=\"absmiddle\">";
                    echo "</div>";
                } else {
                    echo "<span class=\"annot_std_it\" style=\"float:left;\">";
                    echo $lieu;
                    echo "</span>";
                }
            }

            // Affichage site client
            $sitecli = "";
            switch (trim($row["ot_idsite"])) {
                case "0" :
                    $row2 = lit_enr_cli($row["ot_codecli"], FALSE);
                    if (is_array($row2)) {
                        $row2 = encode_str($row2);
                        extract($row2);
                        $sitecli .= "<strong>";
                        if ($cli_ste <> "")
                            $sitecli .= $cli_ste . "<br />";
                        else
                            $sitecli .= $cli_civilite . " " . $cli_prenom . " " . $cli_nom . "<br />";
                        $sitecli .= "</strong>";
                        $sitecli .= $cli_adr1 . "<br />";
                        if ($cli_adr2 <> "")
                            $sitecli .= $cli_adr2 . "<br />";
                        $sitecli .= Retournecp_Id($cli_ville, FALSE) . " " . Retourneville_Id($cli_ville, FALSE) . "<br />";
                    }
                    break;
                default :
                    $rech2 = "SELECT * FROM `" . TBSCLI . "` WHERE `scli_id` = '" . trim($row["ot_idsite"]) . "'";
                    $row2 = $db->get_row($rech2, ARRAY_A);
                    if ($row2) {
                        extract($row2);
                        $sitecli .= "<strong>";
                        $sitecli .= $scli_ste . "<br />";
                        $sitecli .= "</strong>";
                        $sitecli .= $scli_adr1 . "<br />";
                        if ($scli_adr2 <> "")
                            $sitecli .= $scli_adr2 . "<br />";
                        $sitecli .= Retournecp_Id($scli_ville, FALSE) . " " . Retourneville_Id($scli_ville, FALSE) . "<br />";
                    }
            }

            if ($sitecli <> "") {
                echo "<div class=\"annot_petit_it\" style=\"float:left;\">";
                echo $sitecli;
                echo "</div>";
            }

            echo "</td>\n";

            // Affichage détail urgence
            echo '<td ';
            $couleur = give_coul_urg($row["ot_urg"], FALSE);
            if ($couleur <> "XX")
                echo ' style="background:' . $couleur . '"';
            echo ' align="center">';
            echo give_nom_urg($row["ot_urg"], FALSE);;
            echo "</td>\n";
            // Fin affichage détail urgence

            // Affichage technicien traitant
            echo "<td align=\"center\">";
            if (($row["ot_codetec"] <> "") AND ($row["ot_codetec"] <> "-1"))
                echo $row["ot_codetec"];
            else
                echo "&nbsp;";
            echo "</td>\n";

            // Affichage icône Statut
            echo "<td align=\"center\">";

            echo str_div_ico_statut($row["ot_codestatut"], '', FALSE);

            echo "</td>\n";

            // CREATION lien dynamique sur icône (édition, suppression, etc...)
            echo "<td align=\"center\">";

            $rech2 = "SELECT int_idsite, int_codecli FROM `" . TBINT . "` WHERE `int_code` = '" . $row["ot_codeint"] . "'";
            $row2 = $db->get_row($rech2, ARRAY_A);
            if ($row2) {
                $row2 = encode_str($row2);
                extract($row2);
            }

            if ($row["ot_codestatut"] <> "CLOT") {
                $lst_maj = TRUE;
                cre_falselnk_img('', 'ot_edit_'.$row["ot_id"], 'span', 'center', _("Edition"), 'lnk', 'ot_maj.php?tx=' . $tx . '&td=edit&ca=' . $ca . '&cas=' . $cas . '&ci=&cc=' . $row["ot_codecli"] . '&co=' . $row["ot_code"] . '&si=' . $row["ot_idsite"] . '&tr=', '../img/edit.png');
            } else {
                $lst_voir = TRUE;
                cre_falselnk_img('', 'ot_view_'.$row["ot_id"], 'span', 'center', _("Visualisation"), 'lnk', 'ot_maj.php?tx=' . $tx . '&td=view&ca=' . $ca . '&cas=' . $cas . '&ci=&cc=' . $row["ot_codecli"] . '&co=' . $row["ot_code"] . '&si=' . $row["ot_idsite"] . '&tr=', '../img/eye.png');
            }

            $lst_imp = TRUE;
            $urlimp = "ot_pdf.php?co=" . $row["ot_code"];
            cre_falselnk_img('', 'ot_prn_'.$row["ot_id"], 'span', 'center', _("Impression"), 'lnkpop', $urlimp, '../img/print.png');

            if ($row["ot_codestatut"] <> "CLOT") {
                $del = TRUE;
                if ((@$_SESSION["niv_log"] == 11) OR (@$_SESSION["niv_log"] == 10))
                    $del = FALSE;

                if ($del == TRUE) {
                    $lst_del = TRUE;
                    cre_falselnk_img('', 'ot_del_'.$row["ot_id"], 'span', 'center', _("Suppression"), 'lnk', 'ot_maj.php?tx=' . $tx . '&td=del&ca=' . $ca . '&cas=' . $cas . '&ci=&cc=' . $row["ot_codecli"] . '&co=' . $row["ot_code"] . '&si=' . $row["ot_idsite"] . '&tr=', '../img/del.png');
                }
            }
            echo "</td>\n";

            echo "</tr>\n";
            // Fin affichage résumé ordre

            $i++;
        }
        echo "</table>\n";
        // *** Fin affichage de la table
    } else {
        echo "<span class=\"annot_gras_it\">";
        echo "<br /><br />" . _("Pas de bons de travail en cours");
        echo "</span>";
    }

    $db->disconnect();

    $taille_piedla = "";
    include("../inc/piedla.inc.php");
    ?>
    </div>
    </div>
    <?PHP
    include_once("pied.php");
} else {
    ?>
    <p align="center"><span class="titrepageerr"><?PHP echo _("PROBLEME DE CONFIGURATION"); ?></span></p>
    <p>&nbsp;</p>
    <p>&nbsp;</p>
    <?PHP
    pop_ret_auto(_("SMI n'a pas encore été totalement configuré pour votre compte") . "<br />" . _("Merci de contacter l'administrateur ou le centre de gestion"), 'warn', "index.php");
}
?>