示例#1
0
    $year  = date("Y");
    showAccessDenied($day, $month, $year, $area,$back);
    exit();
}

# print the page header
print_header("","","","",$type="with_session", $page="admin");
// Affichage de la colonne de gauche
include "admin_col_gauche.php";

$themessage = str_replace ( "'"  , "\\'"  , get_vocab("admin_purge_accounts_confirm"));
$themessage2 = str_replace ( "'"  , "\\'"  , get_vocab("admin_purge_accounts_confirm2"));
$themessage3 = str_replace ( "'"  , "\\'"  , get_vocab("admin_purge_tables_confirm"));
$themessage4 = str_replace ( "'"  , "\\'"  , get_vocab("admin_purge_accounts_confirm4"));

echo "<h2>".get_vocab('admin_purge_accounts.php').grr_help("aide_grr_purge_accounts")."</h2>";

echo get_vocab('admin_clean_accounts_desc');

echo "<div style=\"text-align:center;\">\n
<form id=\"purge_liaison\" action=\"admin_purge_accounts.php\" method=\"post\">\n
<div>
<input type=\"hidden\" name=\"do_purge_table_liaison\" value=\"1\" />\n
<input
	type=\"button\"
	value=\"".get_vocab('admin_purge_tables_liaison')."\"
	onclick=\"return confirmButton('purge_liaison', '$themessage3')\" />\n
</div></form></div>";

echo "<hr />";
示例#2
0
echo "<form action=\"./admin_config.php\"  method=\"get\" style=\"width: 100%;\" onsubmit=\"return verifierJoursCycles(false);\">\n";
echo "<h3>".get_vocab("Activer_module_jours_cycles").grr_help("aide_grr_jours_cycle")."</h3>\n";
echo "<table border='0'>\n<tr>\n<td>\n";
echo get_vocab("Activer_module_jours_cycles").get_vocab("deux_points");
echo "<select name='jours_cycles'>\n";
if (getSettingValue("jours_cycles_actif") == "Oui") {
    echo "<option value=\"Oui\" selected=\"selected\">".get_vocab('YES')."</option>\n";
    echo "<option value=\"Non\">".get_vocab('NO')."</option>\n";
} else {
    echo "<option value=\"Oui\">".get_vocab('YES')."</option>\n";
    echo "<option value=\"Non\" selected=\"selected\">".get_vocab('NO')."</option>\n";
}
echo "</select>\n</td>\n</tr>\n</table><hr />\n";


echo "<h3>".get_vocab("Activer_module_multisite").grr_help("aide_grr_multisites")."</h3>\n";
echo "<table border='0'>\n<tr>\n<td>\n";
echo get_vocab("Activer_module_multisite").get_vocab("deux_points");
echo "<select name='module_multisite'>\n";
if (getSettingValue("module_multisite") == "Oui") {
    echo "<option value=\"Oui\" selected=\"selected\">".get_vocab('YES')."</option>\n";
    echo "<option value=\"Non\">".get_vocab('NO')."</option>\n";
} else {
    echo "<option value=\"Oui\">".get_vocab('YES')."</option>\n";
    echo "<option value=\"Non\" selected=\"selected\">".get_vocab('NO')."</option>\n";
}
echo "</select>\n</td>\n</tr>\n</table>\n";


# La page de modification de la configuration d'une ressource utilise pour le champ "description complète"
# l'application FckEditor permettant une mise en forme "wysiwyg" de la page.
示例#3
0
     echo "<br /><input type=\"radio\" name=\"moderate\" value=\"S1\" />".get_vocab("accepter_resa_serie");
     echo "<br /><input type=\"radio\" name=\"moderate\" value=\"S0\" />".get_vocab("refuser_resa_serie");
  }
  echo "</p><p>";
  echo "<label for=\"description\">".get_vocab("justifier_decision_moderation").get_vocab("deux_points")."</label>\n";
  echo "<textarea name=\"description\" id=\"description\" cols=\"40\" rows=\"3\"></textarea>";
  echo "</p>";
  echo "<br /><div style=\"text-align:center;\"><input type=\"submit\" name=\"commit\" value=\"".get_vocab("save")."\" /></div>\n";
  echo "</fieldset></form>\n";
}

// Si l'utilisateur est administrateur, possibilité de modifier le statut de la réservation (en cours / libérée)
if ($active_ressource_empruntee == 'y') {
  if ((!$was_del) and ($moderate != 1) and (getUserName()!='') and (authGetUserLevel(getUserName(),$room_id) >= 3))          {
    echo "<form action=\"view_entry.php\" method=\"get\">";
    echo "<fieldset><legend style=\"font-weight:bold\">".get_vocab("reservation_en_cours").grr_help("aide_grr_ressource_empruntee")."</legend>\n";
    echo "<span class=\"larger\">".get_vocab("signaler_reservation_en_cours")."</span>".get_vocab("deux_points");
    echo "<br />".get_vocab("explications_signaler_reservation_en_cours");

    affiche_ressource_empruntee($room_id, "texte");
    echo "<br /><input type=\"radio\" name=\"statut_id\" value=\"-\" ";
    if ($statut_id=='-') {
        // La ressource est-elle empruntée ?
        if (!affiche_ressource_empruntee($room_id,"autre")=='yes')
        echo " checked=\"checked\" ";
    }
    echo " />".get_vocab("signaler_reservation_en_cours_option_0");
    echo "<br /><br /><input type=\"radio\" name=\"statut_id\" value=\"y\" ";
    if ($statut_id=='y') echo " checked=\"checked\" ";
    echo " />".get_vocab("signaler_reservation_en_cours_option_1");
    echo "<br /><br /><input type=\"radio\" name=\"statut_id\" value=\"e\" ";
示例#4
0
        echo "<input type=\"hidden\" name=\"ldap_base\" value=\"$ldap_base\" />";
    echo encode_message_utf8("<br /><br /><b>Remarque : pour le moment, aucune modification n'a été apportée au fichier de configuration \"config_ldap.inc.php\".</b><br />
    Les informations ne seront enregistrées qu'à la fin de la procédure de configuration.</div>");


    echo "<div style=\"text-align:center;\"><input type=\"submit\" value=\"Suivant\" /></div>";
    echo "</form>";

} else if ($etape == 0) {
    if (!(function_exists("ldap_connect"))) {
        echo encode_message_utf8("<h2>".$titre_ldap.grr_help("aide_grr_configuration_LDAP")."</h2>\n");
        echo encode_message_utf8("<p class=\"avertissement\"><b>Attention </b> : les fonctions liées à l'authentification <b>LDAP</b> ne sont pas activées sur votre serveur PHP.
        <br />La configuration LDAP est donc actuellement impossible.</p></td></tr></table></body></html>");
        die();
    }
    echo encode_message_utf8("<h2>".$titre_ldap.grr_help("aide_grr_configuration_LDAP")."</h2>\n");
    echo "<p>".encode_message_utf8("Si vous avez accès à un annuaire <b>LDAP</b>, vous pouvez configurer GRR afin que cet annuaire soit utilisé pour importer automatiquement des utilisateurs.")."</p>";
    echo "<form action=\"admin_config_ldap.php\" method=\"post\">\n";
    echo "<div>\n<input type=\"hidden\" name=\"etape\" value=\"0\" />\n";
    echo "<input type=\"hidden\" name=\"valid\" value=\"$valid\" />\n";
    echo "<input type=\"hidden\" name=\"reg_ldap_statut\" value=\"yes\" /></div>\n";
    if (getSettingValue("ldap_statut") != '') {
        echo encode_message_utf8("<h3>L'authentification LDAP est activée.</h3>\n");
        echo encode_message_utf8("<h3>Statut par défaut des utilisateurs importés</h3>\n");
        echo "<div>".encode_message_utf8("Choisissez le statut qui sera attribué aux personnes présentes
        dans l'annuaire LDAP lorsqu'elles se connectent pour la première fois.
        Vous pourrez par la suite modifier cette valeur pour chaque utilisateur.<br />");
        echo "<input type=\"radio\" name=\"ldap_statut\" value=\"visiteur\" ";
        if (getSettingValue("ldap_statut")=='visiteur') echo " checked=\"checked\" ";
        echo "/>Visiteur<br />";
        echo "<input type=\"radio\" name=\"ldap_statut\" value=\"utilisateur\" ";
示例#5
0
if ($version_old_RC == "") {
    $version_old_RC = 9;
    $display_version_old = $version_old;
} else {
    $display_version_old = $version_old."_RC".$version_old_RC;
}
$version_old .= ".".$version_old_RC;

// Calcul de la chaine à afficher
if ($version_grr_RC == "") {
    $display_version_grr = $version_grr.$sous_version_grr;
} else {
    $display_version_grr = $version_grr."_RC".$version_grr_RC;
}

echo "<h2>".get_vocab('admin_maj.php').grr_help("aide_grr_maj")."</h2>";

echo "<hr />";
// Numéro de version
echo "<h3>".get_vocab("num_version_title")."</h3>\n";
echo "<p>".get_vocab("num_version").$display_version_grr;
echo "</p>\n";

echo get_vocab('database') . grr_sql_version() . "\n";
echo "<br />" . get_vocab('system') . php_uname() . "\n";
echo "<br />Version PHP : " . phpversion() . "\n";


echo "<p>".get_vocab("maj_go_www")."<a href=\"".$grr_devel_url."\">".get_vocab("mrbs")."</a></p>\n";
echo "<hr />\n";
// Mise à jour de la base de donnée
示例#6
0
    if (!saveSetting("nombre_jours_Jours/Cycles", $_GET['nombreJours'])) {
        echo "Erreur lors de l'enregistrement de nombre_jours_Jours/Cycles ! <br />";
    }
}
// Met à jour dans la BD le premier jour du premier cycle
if (isset($_GET['jourDebut'])) {
    if (!saveSetting("jour_debut_Jours/Cycles", $_GET['jourDebut'])) {
        echo "Erreur lors de l'enregistrement de jour_debut_Jours/Cycles ! <br />";
    }
}

//
// Configurations du nombre de jours par Jours/Cycles et du premier jour du premier Jours/Cycles
//******************************
//
echo "<h3>".get_vocab("titre_config_Jours/Cycles").grr_help("aide_grr_jours_cycle")."</h3>\n";
echo "<form action=\"./admin_calend_jour_cycle.php\"  method=\"get\" style=\"width: 100%;\" onsubmit=\"return verifierJoursCycles(false);\">\n";
echo "<p>".get_vocab("explication_Jours_Cycles1");
echo "<br />".get_vocab("explication_Jours_Cycles2");
?>
<br /><br /></p><table border="1" cellpadding="5" cellspacing="1">
<tr>
<td>
<?php echo get_vocab("nombre_jours_Jours/Cycles").get_vocab("deux_points"); ?>
</td><td>
<!-- Pour sélectionner le nombre de jours par Cycle  -->
<?php
echo "<select name='nombreJours' id='nombreJours'>\n";
for($i = 1; $i < 21; $i++) {
    if ($i == getSettingValue("nombre_jours_Jours/Cycles")){
        echo "<option selected=\"selected\">".$i."</option>\n";
示例#7
0
sont regroupés dans une liste déroulante correspondant au cas $i = 3 ci-dessous
$rep_type = 4 -> Chaque année, même date
$rep_type = 6 -> Jours cycle
*/

if(($edit_type == "series") or (isset($flag_periodicite)))
{
  echo "
    <tr>
       <td id=\"ouvrir\" style=\"cursor: inherit\" align=\"center\" class=\"fontcolor4\">
       <span class=\"bground\"><b><a href='javascript:clicMenu(1);check_5()'>".get_vocab("click_here_for_series_open")."</a></b></span>".grr_help("aide_grr_periodicite")."
       </td>
       </tr>
       <tr>
       <td style=\"display:none; cursor: inherit\" id=\"fermer\" align=\"center\" class=\"fontcolor4\">
       <span class=\"bground\"><b><a href='javascript:clicMenu(1);check_5()'>".get_vocab("click_here_for_series_close")."</a></b></span>".grr_help("aide_grr_periodicite")."
       </td>
    </tr>
    ";

  echo "<tr><td><table border=\"0\" style=\"display:none\" id=\"menu1\" width=\"100%\">\n ";

  echo "<tr><td class=\"F\"><b>".get_vocab("rep_type")."</b></td></tr><tr><td class=\"CL\">\n";


  echo "<table border=\"0\"  width=\"100%\" >\n";
  //Vérifie si le jour cycle est activé ou non
  if (getSettingValue("jours_cycles_actif") == "Oui") $max = 7; //$max = 7 Pour afficher l'option Jour cycle dans les péridocidités
  else $max = 6;                                                //$max = 6 Pour ne pas afficher l'option Jour cycle dans les péridocidités
  for($i = 0; $i<$max ; $i++)
    {
示例#8
0
print_header("","","","",$type="with_session", $page="admin");
affiche_pop_up($msg,"admin");

// Affichage de la colonne de gauche
include "admin_col_gauche.php";

// Affichage du tableau de choix des sous-configuration
include "include/admin_config_tableau.inc.php";

//echo "<h2>".get_vocab('admin_config1.php')."</h2>";
//echo "<p>".get_vocab('mess_avertissement_config')."</p>";


// Adapter les fichiers de langue
echo "<h3>".get_vocab("adapter fichiers langue")."</h3>\n";
echo get_vocab("adapter fichiers langue explain").grr_help("aid_grr_adapter_fichiers_langue");

//
// Config générale
//****************
//
echo "<form enctype=\"multipart/form-data\" action=\"./admin_config.php\" id=\"nom_formulaire\" method=\"post\" style=\"width: 100%;\">";
echo "<h3>".get_vocab("miscellaneous")."</h3>\n";
?>
<table border='0'>

<tr><td><?php echo get_vocab("title_home_page"); ?></td>
<td><input type="text" name="title_home_page" id="title_home_page" size="40" value="<?php echo(getSettingValue("title_home_page")); ?>" /></td>
</tr>
<tr><td><?php echo get_vocab("message_home_page"); ?></td>
<td><textarea name="message_home_page" rows="3" cols="40"><?php echo(getSettingValue("message_home_page")); ?>
示例#9
0
        $sql = "DELETE FROM ".TABLE_PREFIX."_utilisateurs WHERE login='******'";
        if (grr_sql_command($sql) < 0) {fatal_error(1, "<p>" . grr_sql_error());}  else {
            grr_sql_command("DELETE FROM ".TABLE_PREFIX."_j_mailuser_room WHERE login='******'");
            grr_sql_command("DELETE FROM ".TABLE_PREFIX."_j_user_area WHERE login='******'");
            grr_sql_command("DELETE FROM ".TABLE_PREFIX."_j_user_room WHERE login='******'");
            grr_sql_command("DELETE FROM ".TABLE_PREFIX."_j_useradmin_area WHERE login='******'");
            grr_sql_command("DELETE FROM ".TABLE_PREFIX."_j_useradmin_site WHERE login='******'");
            $msg=get_vocab("del_user_succeed");
        }
    }
}

if (isset($mess) and ($mess != ""))
    echo "<p>".$mess."</p>";

echo "<h2>".get_vocab('admin_user.php').grr_help("aide_grr_gestion_utilisateurs")."</h2>";
if (empty($display)) { $display = 'actifs'; }
if (empty($order_by)) { $order_by = 'nom,prenom'; }

?>
| <a href="admin_user_modify.php?display=<?php echo $display; ?>"><?php echo get_vocab("display_add_user"); ?></a> |
<a href="admin_import_users_csv.php"><?php echo get_vocab("display_add_user_list_csv"); ?></a> |

<?php
// On propose de supprimer les utilisateurs ext de GRR qui ne sont plus présents dans la base LCS
if (getSettingValue("sso_statut") == "lcs") {
    echo "<br />Opérations LCS : | <a href=\"admin_user.php?action=nettoyage\" onclick=\"return confirmlink(this, '".AddSlashes(get_vocab("mess_maj_base_locale"))."', '".get_vocab("maj_base_locale")."')\">".get_vocab("maj_base_locale")."</a> |";
    echo " <a href=\"admin_user.php?action=synchro\" onclick=\"return confirmlink(this, '".AddSlashes(get_vocab("mess_synchro_base_locale"))."', '".get_vocab("synchro_base_locale")."')\">".get_vocab("synchro_base_locale")."</a> |";
}
// Autoriser ou non la modification par un utilisateur de ses informations personnelles (nom, prénom)
// Par ailleurs un gestionnaire d'utilisateurs ne peut pas Autoriser ou non la modification par un utilisateur de ses informations personnelles
示例#10
0
 function read_sites()
 {
   // Affichage des titres de la page
   echo '      <h2>'.get_vocab('admin_site.php').grr_help("aide_grr_multisites").'</h2>';
   echo '      <p>'.get_vocab('admin_site_explications').'</p>
      | <a href="admin_site.php?action=create&amp;id=0">'.get_vocab('display_add_site').'</a> |';
   if (count_sites()>0) {

   $sql = "SELECT id,sitecode,sitename,cp,ville
		FROM ".TABLE_PREFIX."_site
 		ORDER BY sitename,ville,id";
   $res = grr_sql_query($sql);
   if ($res)
   {
     // Affichage de l'entête du tableau
     echo '      <table border="1" cellpadding="3">
        <tr>
          <th>'.get_vocab('action').get_vocab('deux_points').'</th>
          <th>'.get_vocab('site_code').'</th>
          <th>'.get_vocab('site_name').'</th>
          <th>'.get_vocab('site_cp').'</th>
          <th>'.get_vocab('site_ville').'</th>
        </tr>';
     for ($i = 0; ($row=grr_sql_row($res,$i));$i++)
     {
       echo '        <tr>
          <td>
            <a href="admin_site.php?action=update&amp;id='.$row[0].'"><img class="image" title="'.get_vocab('change').'" alt="'.get_vocab('change').'" src="img_grr/edit_s.png" /></a>
            <a href="admin_site.php?action=delete&amp;id='.$row[0].'"><img class="image" title="'.get_vocab('delete').'" alt="'.get_vocab('delete').'" src="img_grr/delete_s.png" /></a>';
//echo '            <a href="admin_site.php?action=right&amp;id='.$row[0].'"><img class=\"image\" title="'.get_vocab('privileges').'" alt="'.get_vocab('privileges').'" src="img_grr/rights.png" /></a>';
echo '          </td>
          <td>'.$row[1].'</td>
          <td>'.$row[2].'</td>
          <td>'.$row[3].'</td>
          <td>'.$row[4].'</td>
        </tr>';
     }
     echo '      </table>';
   } else {
     echo '      <p>Une erreur est survenue pendant la préparation de la requète de lecture des sites.</p>';
     // fin de l'affichage de la colonne de droite
     echo "</td></tr></table>\n</body>\n</html>\n";
     die();
     }
     // fin de l'affichage de la colonne de droite
     echo "</td></tr></table>\n</body>\n</html>\n";
     die();
   }
 }
示例#11
0
    showAccessDenied($day, $month, $year, '',$back);
    exit();
}

// Date to delete logs to
if (isset($_POST['cleanDay']) && isset($_POST['cleanMonth']) && isset($_POST['cleanYear'])) {
    $sql = "delete from ".TABLE_PREFIX."_log where START < '" . $_POST['cleanYear'] . "-" . $_POST['cleanMonth'] . "-" . $_POST['cleanDay'] . "' and END < now()";
    $res = grr_sql_query($sql);
}

# print the page header
print_header("","","","",$type="with_session", $page="admin");
// Affichage de la colonne de gauche
include "admin_col_gauche.php";

echo "<h2>".get_vocab('admin_view_connexions.php').grr_help("aide_grr_suivi_connexions")."</h2>";
echo "<h3>".get_vocab("users_connected")."</h3>";
?>

<div title="User connected">
<ul>
<?php
// compte le nombre d'enregistrement dans la table
$sql = "select u.login, concat(u.prenom, ' ', u.nom) utilisa, u.email from ".TABLE_PREFIX."_log l, ".TABLE_PREFIX."_utilisateurs u where (l.LOGIN = u.login and l.END > now())";

$res = grr_sql_query($sql);
if ($res) {
    for ($i = 0; ($row = grr_sql_row($res, $i)); $i++)
    {
    if ((getSettingValue("sso_statut") != "") or  (getSettingValue("ldap_statut") != '') or  (getSettingValue("imap_statut") != ''))
        echo("<li>" . $row[1]. " | <a href=\"mailto:" . $row[2] . "\">".get_vocab("sen_a_mail")."</a> |</li>") ;
示例#12
0
        }
    }
}

if ($action=='del_user') {
    if(authGetUserLevel(getUserName(),$id_area,'area') < 4)
    {
        showAccessDenied($day, $month, $year, '',$back);
        exit();
    }
    unset($login_user); $login_user = $_GET["login_user"];
    $sql = "DELETE FROM ".TABLE_PREFIX."_j_user_area WHERE (login='******' and id_area = '$id_area')";
    if (grr_sql_command($sql) < 0) {fatal_error(1, "<p>" . grr_sql_error());} else {$msg=get_vocab("del_user_succeed");}
}
if (empty($id_area)) $id_area = -1;
echo "<h2>".get_vocab('admin_access_area.php').grr_help("aide_grr_domaine_restreint")."</h2>\n";
affiche_pop_up($msg,"admin");

echo "<table><tr>\n";
$this_area_name = "";
# Show all areas
$existe_domaine = 'no';
echo "<td ><p><b>".get_vocab('areas')."</b></p>\n";
$out_html = "\n<form id=\"area\" action=\"admin_access_area.php\" method=\"post\">\n<div><select name=\"area\" onchange=\"area_go()\">";
$out_html .= "\n<option value=\"admin_access_area.php?id_area=-1\">".get_vocab('select')."</option>";
    $sql = "select id, area_name from ".TABLE_PREFIX."_area where access='r' order by area_name";
    $res = grr_sql_query($sql);
    $nb = grr_sql_count($res);
    if ($res) for ($i = 0; ($row = grr_sql_row($res, $i)); $i++)
    {
        $selected = ($row[0] == $id_area) ? "selected = \"selected\"" : "";
示例#13
0
# Désactive les messages javascript d'information (pop-up) dans les menus d'administration
# 1 = Oui, 0 = Non
echo "\n<hr /><h3>".get_vocab("javascript_info_admin_disabled_msg")."</h3>";
echo "\n<table cellspacing=\"5\">";
echo "\n<tr><td>".get_vocab("javascript_info_admin_disabled0")."</td><td>";
echo "\n<input type='radio' name='javascript_info_admin_disabled' value='0' "; if (getSettingValue("javascript_info_admin_disabled")=='0') echo "checked=\"checked\""; echo " />";
echo "\n</td></tr>";
echo "\n<tr><td>".get_vocab("javascript_info_disabled1")."</td><td>";
echo "\n<input type='radio' name='javascript_info_admin_disabled' value='1' "; if (getSettingValue("javascript_info_admin_disabled")=='1') echo "checked=\"checked\""; echo " />";
echo "\n</td></tr>";
echo "\n</table>";

# tâche automatique de suppression
echo "\n<hr /><h3>".get_vocab("suppression automatique des réservations")."</h3>";
echo "\n<p>".get_vocab('Explications suppression automatique des réservations').grr_help("aide_grr_verif_auto_grr")."</p>";
echo "\n<table cellspacing=\"5\">";
echo "\n<tr><td>".get_vocab("verif_reservation_auto0")."</td><td>";
echo "\n<input type='radio' name='verif_reservation_auto' value='0' "; if (getSettingValue("verif_reservation_auto")=='0') echo "checked=\"checked\""; echo " />";
echo "\n</td></tr>";
echo "\n<tr><td>".get_vocab("verif_reservation_auto1")."</td><td>";
echo "\n<input type='radio' name='verif_reservation_auto' value='1' "; if (getSettingValue("verif_reservation_auto")=='1') echo "checked=\"checked\""; echo " />";
echo "\n</td></tr>";
echo "\n<tr><td>".get_vocab("verif_reservation_auto2").get_vocab("deux_points")."</td><td>";
echo "\n<input type=\"text\" name=\"motdepasse_verif_auto_grr\" value=\"".getSettingValue("motdepasse_verif_auto_grr")."\" size=\"20\" />";
echo "\n</td></tr>";
echo "\n<tr><td>".get_vocab("verif_reservation_auto3").get_vocab("deux_points")."</td><td>";
echo "\n<input type=\"text\" name=\"chemin_complet_grr\" value=\"".getSettingValue("chemin_complet_grr")."\" size=\"20\" />";
echo "\n</td></tr>";
echo "\n</table>";
echo "\n<p><input type=\"hidden\" name=\"page_config\" value=\"3\" />";
示例#14
0
    return $s;
}

if(authGetUserLevel(getUserName(),-1) < 6)
{
    showAccessDenied($day, $month, $year, '',$back);
    exit();
}

# print the page header
print_header("","","","",$type="with_session", $page="admin");
// Affichage de la colonne de gauche
include "admin_col_gauche.php";
// Affichage du tableau de choix des sous-configuration pour les Jours/Cycles (Créer et voir calendrier Jours/Cycle)
include "include/admin_calend_jour_cycle.inc.php";
echo "<h3>".get_vocab('calendrier_jours/cycles').grr_help("aide_grr_jours_cycle")."</h3>";
if (isset($_POST['record']) and  ($_POST['record'] == 'yes')) {
    // On vide la table
    $sql = "truncate table ".TABLE_PREFIX."_calendrier_jours_cycle";
    if (grr_sql_command($sql) < 0) fatal_error(1, "<p>" . grr_sql_error());
    $result = 0;
    $end_bookings = getSettingValue("end_bookings");
    $n = getSettingValue("begin_bookings");
    $month = strftime("%m", getSettingValue("begin_bookings"));
    $year = strftime("%Y", getSettingValue("begin_bookings"));
    $day = 1;
    // Pour aller chercher le Jour cycle qui débutera le premier cycle de jours
    $m = getSettingValue("jour_debut_Jours/Cycles");
    while ($n <= $end_bookings) {
         $daysInMonth = getDaysInMonth($month, $year);
         $day = 1;
示例#15
0
}

if ((empty($id_area)) and (isset($row[0]))) {
    if(authGetUserLevel(getUserName(),$row[0],'area') >= 6) $id_area = get_default_area();
    else {
    # Retourne le domaine par défaut; Utilisé si aucun domaine n'a été défini.
// On cherche le premier domaine à accès non restreint
    $id_area = grr_sql_query1("SELECT a.id FROM ".TABLE_PREFIX."_area a, ".TABLE_PREFIX."_j_useradmin_area j
    WHERE a.id=j.id_area and j.login='******'
    ORDER BY a.access, a.order_display, a.area_name
    LIMIT 1");
    }
}
if (empty($room)) $room = -1;

echo "<h2>".get_vocab('admin_right.php').grr_help("aide_grr_gestion_ressources")."</h2>\n";
echo "<p><i>".get_vocab("admin_right_explain")."</i></p>\n";
// Affichage d'un pop-up
affiche_pop_up($msg,"admin");

# Table with areas, rooms.
echo "<table><tr>\n";
$this_area_name = "";
$this_room_name = "";
# Show all areas
echo "<td ><p><b>".get_vocab("areas")."</b></p>\n";
$out_html = "<form id=\"area\" action=\"admin_right.php\" method=\"post\">\n<div><select name=\"area\" onchange=\"area_go()\">\n";
$out_html .= "<option value=\"admin_right.php?id_area=-1\">".get_vocab('select')."</option>\n";
    $sql = "select id, area_name from ".TABLE_PREFIX."_area order by order_display";
    $res = grr_sql_query($sql);
    if ($res) for ($i = 0; ($row = grr_sql_row($res, $i)); $i++)
示例#16
0
    showAccessDenied($day, $month, $year, '',$back);
    exit();
}
if ((authGetUserLevel(getUserName(),-1) < 5) and ($valid != 'yes'))
{
    $day   = date("d");
    $month = date("m");
    $year  = date("Y");
    showAccessDenied($day, $month, $year, $area,$back);
    exit();
}
# print the page header
print_header("","","","",$type="with_session", $page="admin");
// Affichage de la colonne de gauche
include "admin_col_gauche.php";
echo encode_message_utf8("<h2>Configuration de l'authentification IMAP/POP".grr_help("aide_grr_authentification_imap")."</h2>");
?>
<script type="text/javascript" src="./functions.js"></script>
<?php
if($etape==1){
  if (isset($_POST["Valider1"])) {
    $imap_domaine = $_POST["imap_domaine"];
    $imap_adresse = $_POST["imap_adresse"];
    $imap_port = $_POST["imap_port"];
    $imap_type = $_POST["server_type"];
    $imap_ssl = $_POST["server_ssl"];
    $imap_cert = $_POST["server_cert"];
    $imap_tls = $_POST["server_tls"];
    $erreur = '';
    $nom_fic = "include/config_imap.inc.php";
    if (@file_exists($nom_fic)) {
示例#17
0
    $day   = date("d");
    $month = date("m");
    $year  = date("Y");
    showAccessDenied($day, $month, $year, '',$back);
    exit();
}
// Utilisation de la bibliothèqye prototype dans ce script
$use_prototype = 'y';
// Utilisation de la bibliothèqye tooltip.js dans ce script
$use_tooltip_js = 'y';
// print the page header
print_header("","","","",$type="with_session", $page="admin");
// Affichage de la colonne de gauche
include "admin_col_gauche.php";

echo "<h2>".get_vocab("admin_overload.php").grr_help("aide_grr_champs_add")."</h2>\n";

// Intitialistion des données
if (isset($_POST["action"])) $action = $_POST["action"]; else $action = "default";

// 1- On récupère la liste des domaines accessibles à l'utilisateur dans un tableau.
// TODO: Ajouter une selection en relation avec le site courant
$res = grr_sql_query("select id, area_name, access from ".TABLE_PREFIX."_area order by order_display");
if (! $res) fatal_error(0, grr_sql_error());

$userdomain = array();
if (grr_sql_count($res) != 0)
{
  for ($i = 0; ($row = grr_sql_row($res, $i)); $i++)
    {
      if(authGetUserLevel(getUserName(),$row[0],'area') >= 4)
示例#18
0
echo "</td></tr>\n";
echo "</table>\n";

# allow_gestionnaire_modify_delete=0 : un gestionnaire d'une ressource ne peut pas supprimer ou modifier les réservation effectuées sur la ressource, sauf celles dont il est l'auteur.
# allow_gestionnaire_modify_delete=1 : un gestionnaire d'une ressource peut supprimer ou modifier n'importe quelle réservation effectuées sur la ressource
echo "<hr />\n";
echo "<table cellspacing=\"5\">\n";
echo "<tr><td>".get_vocab("allow_gestionnaire_modify_del0")."</td><td>\n";
echo "<input type='radio' name='allow_gestionnaire_modify_del' value='0' "; if (getSettingValue("allow_gestionnaire_modify_del")=='0') echo "checked=\"checked\""; echo " />\n";
echo "</td></tr>\n";
echo "<tr><td>".get_vocab("allow_gestionnaire_modify_del1")."</td><td>";
echo "<input type='radio' name='allow_gestionnaire_modify_del' value='1' "; if (getSettingValue("allow_gestionnaire_modify_del")=='1') echo "checked=\"checked\""; echo " />\n";
echo "</td></tr>\n";
echo "</table>\n";

// Nombre max de réservations (toutes ressources)
echo "<hr />\n";
echo "<table cellspacing=\"5\">\n";
echo "<tr><td>".get_vocab("max_booking")." ";
echo " - ".get_vocab("all_rooms");
echo grr_help("aide_grr_config_generale");
echo "</td><td><input type=\"text\" name=\"UserAllRoomsMaxBooking\" value=\"".getSettingValue("UserAllRoomsMaxBooking")."\" size=\"5\"/></td></tr>\n";
echo "</table>\n";

echo "<p><input type=\"hidden\" name=\"page_config\" value=\"2\" />\n";
echo "<br /></p><div id=\"fixe\" style=\"text-align:center;\"><input type=\"submit\" name=\"ok\" value=\"".get_vocab("save")."\" style=\"font-variant: small-caps;\"/></div>\n";
echo "</form>\n";

// fin de l'affichage de la colonne de droite
echo "</td></tr></table>\n";
?>
示例#19
0
    // Format d'affichage du temps : valeur 0 pour un affichage « 12 heures » et valeur 1 pour un affichage  « 24 heure ».
    echo "<tr>\n";
    echo "<td>".get_vocab("twentyfourhour_format_area").get_vocab("deux_points")."</td>\n";
    echo "<td>\n";
    echo "<label><input type=\"radio\" name=\"twentyfourhour_format_area\" value=\"0\" ";
    if ($row['twentyfourhour_format_area'] == 0) echo " checked=\"checked\"";
    echo " />".get_vocab("twentyfourhour_format_12")."</label>\n<br />";
    echo "<label><input type=\"radio\" name=\"twentyfourhour_format_area\" value=\"1\" ";
    if ($row['twentyfourhour_format_area'] == 1) echo " checked=\"checked\"";
    echo " />".get_vocab("twentyfourhour_format_24")."</label>\n";
    echo "</td>\n";
    echo "</tr>\n";

    // L'utilisateur ne peut réserver qu'une durée limitée (-1 désactivée), exprimée en minutes
    echo "<tr>\n<td>".get_vocab("duree_max_resa_area").grr_help("Configuration_affichage","duree_max_reser").get_vocab("deux_points");
    echo "</td>\n<td><input type=\"text\" name=\"duree_max_resa_area1\" size=\"5\" value=\"".$row["duree_max_resa_area"]."\" /></td></tr>\n";
    echo "</table>";
    echo "<table>";
        // Nombre max de réservation par domaine
    echo "<tr><td>".get_vocab("max_booking")." -  ".get_vocab("all_rooms_of_area").get_vocab("deux_points");
    echo "</td><td><input type=\"text\" name=\"max_booking\" value=\"".$row['max_booking']."\" /></td>\n";
    echo "</tr></table>";

    echo "<div style=\"text-align:center;\">\n";
    echo "<input type=\"submit\" name=\"change_area\" value=\"".get_vocab("save")."\" />\n";
    echo "<input type=\"submit\" name=\"change_done\" value=\"".get_vocab("back")."\" />";
    echo "<input type=\"submit\" name=\"change_area_and_back\" value=\"".get_vocab("save_and_back")."\" />";
    echo "</div></form>";

    echo "<script type=\"text/javascript\">";
示例#20
0
function print_header($day='',$month='',$year='',$area='',$type_session='with_session',$page='no_admin',$room='')
{
   global $vocab, $search_str, $grrSettings, $clock_file, $desactive_VerifNomPrenomUser, $grr_script_name;
   global $use_prototype, $use_tooltip_js, $desactive_bandeau_sup, $id_site;

   if (!($desactive_VerifNomPrenomUser)) $desactive_VerifNomPrenomUser = '******';
   // On vérifie que les noms et prénoms ne sont pas vides
   VerifNomPrenomUser($type_session);
   if ($type_session == "with_session")
       echo begin_page(get_vocab("mrbs").get_vocab("deux_points").getSettingValue("company"),"with_session");
   else
       echo begin_page(get_vocab("mrbs").get_vocab("deux_points").getSettingValue("company"),"no_session");

   // Si nous ne sommes pas dans un format imprimable
   if ((!isset($_GET['pview'])) or ($_GET['pview'] != 1)) {

   # If we dont know the right date then make it up
     if (!isset($day) or !isset($month) or !isset($year) or ($day == '') or ($month == '') or ($year == '')) {
         $date_now = mktime();
         if ($date_now < getSettingValue("begin_bookings"))
             $date_ = getSettingValue("begin_bookings");
         else if ($date_now > getSettingValue("end_bookings"))
             $date_ = getSettingValue("end_bookings");
         else
             $date_ = $date_now;
        $day   = date("d",$date_);
        $month = date("m",$date_);
        $year  = date("Y",$date_);
     }
   if (!(isset($search_str))) $search_str = get_vocab("search_for");
   if (empty($search_str)) $search_str = "";
   ?>
   <script type="text/javascript">
    chaine_recherche = "<?php echo $search_str; ?>";
   	function onsubmitForm()
	{
	if(document.pressed == 'a')
	{
  	document.getElementById('day').selectedIndex=<?php $date_now = mktime();echo (date("d",$date_now)-1); ?>;
		document.getElementById('month').selectedIndex=<?php echo (date("m",$date_now)-1);?>;
		document.getElementById('year').selectedIndex=<?php echo (date("Y",$date_now)-strftime("%Y", getSettingValue("begin_bookings")));?>;
  	var p=location.pathname;
	   	if(!p.match("day.php") && !p.match("week.php") && !p.match("week_all.php") && !p.match("month.php") && !p.match("month_all.php") && !p.match("month_all2.php") && !p.match("year.php"))
    document.getElementById('myform').action ="day.php";
	}
    if(document.pressed == 'd')
      document.getElementById('myform').action ="day.php";
    if(document.pressed == 'w')
    <?php
    echo "		document.getElementById('myform').action = \"";
    if ($room=="")
      echo "week_all.php";
		else
      echo "week.php";
    echo "\";\n";
    ?>
    if(document.pressed == 'm')
    <?php
    echo "		document.getElementById('myform').action = \"";
    if ($room=="") {
      if (isset($_SESSION['type_month_all'])) {echo $_SESSION['type_month_all'].".php";}
      else {echo "month_all.php";}
    } else
      echo "month.php";
    echo "\";\n";
    ?>
    return true;
		}
		</script>
    <?php

if (!(isset($desactive_bandeau_sup) and ($desactive_bandeau_sup==1) and ($type_session != 'with_session'))) {
    // On fabrique une date valide pour la réservation si ce n'est pas le cas
    $date_ = mktime(0, 0, 0, $month, $day, $year);
    if ($date_ < getSettingValue("begin_bookings"))
        $date_ = getSettingValue("begin_bookings");
    else if ($date_ > getSettingValue("end_bookings"))
        $date_ = getSettingValue("end_bookings");
    $day   = date("d",$date_);
    $month = date("m",$date_);
    $year  = date("Y",$date_);
?>

   <table width="100%" border="0">
    <tr>
      <td class="border_banner">
       <table width="100%" border="0">
        <tr>
        <?php
        $nom_picture = "./images/".getSettingValue("logo");
        if ((getSettingValue("logo")!='') and (@file_exists($nom_picture)))
         echo "<td class=\"banner\"><img src=\"".$nom_picture."\" class=\"image\" alt=\"logo\" /></td>\n";
         echo "<td class=\"banner\">\n";
          echo "&nbsp;<a href=\"".page_accueil('yes')."day=$day&amp;year=$year&amp;month=$month\">".get_vocab("welcome")."</a>";
          echo " - <b>".getSettingValue("company")."</b>";
          if ($type_session == 'no_session') {
            if ((getSettingValue('sso_statut') == 'cas_visiteur') or (getSettingValue('sso_statut') == 'cas_utilisateur'))
					  {
					    echo "<br />&nbsp;<a href='index.php?force_authentification=y'>".get_vocab("authentification")."</a>";
//					    echo "<br />&nbsp;<small><i><a href='login.php?url=".rawurlencode(str_replace('&amp;','&',get_request_uri()))."'>".get_vocab("connect_local")."</a></i></small>";
// corrige un bug dans le calcul de la page d'accueil après connexion.
					    echo "<br />&nbsp;<small><i><a href='login.php'>".get_vocab("connect_local")."</a></i></small>";
					  }
				    else
					  {
// echo "<br />&nbsp;<a href='login.php?url=".rawurlencode(str_replace('&amp;','&',get_request_uri()))."'>".get_vocab("connect")."</a>";
// corrige un bug dans le calcul de la page d'accueil après connexion.
					    echo "<br />&nbsp;<a href='login.php'>".get_vocab("connect")."</a>";
            }
          } else {
            echo "<br />&nbsp;<b>".get_vocab("welcome_to").grr_htmlSpecialChars($_SESSION['prenom'])." ".grr_htmlSpecialChars($_SESSION['nom'])."</b>";
            echo "<br />&nbsp;<a href=\"my_account.php?day=".$day."&amp;year=".$year."&amp;month=".$month."\">".get_vocab("manage_my_account")."</a>";
            //if ($type_session == "with_session") {
            $parametres_url = '';
                 $_SESSION['chemin_retour'] = '';
                 if (isset($_SERVER['QUERY_STRING']) and ($_SERVER['QUERY_STRING'] != '')) {
                     // Il y a des paramètres à passer
                     $parametres_url = grr_htmlSpecialChars($_SERVER['QUERY_STRING'])."&amp;";
                     $_SESSION['chemin_retour'] = traite_grr_url($grr_script_name)."?". $_SERVER['QUERY_STRING'];
                 }
                 echo " - <a href=\"".traite_grr_url($grr_script_name)."?".$parametres_url."default_language=fr\"><img src=\"img_grr/fr_dp.png\" alt=\"France\" title=\"france\" width=\"20\" height=\"13\" class=\"image\" /></a>\n";
                 echo "<a href=\"".traite_grr_url($grr_script_name)."?".$parametres_url."default_language=de\"><img src=\"img_grr/de_dp.png\" alt=\"Deutch\" title=\"deutch\" width=\"20\" height=\"13\" class=\"image\" /></a>\n";
                 echo "<a href=\"".traite_grr_url($grr_script_name)."?".$parametres_url."default_language=en\"><img src=\"img_grr/en_dp.png\" alt=\"English\" title=\"English\" width=\"20\" height=\"13\" class=\"image\" /></a>\n";
                 echo "<a href=\"".traite_grr_url($grr_script_name)."?".$parametres_url."default_language=it\"><img src=\"img_grr/it_dp.png\" alt=\"Italiano\" title=\"Italiano\" width=\"20\" height=\"13\" class=\"image\" /></a>\n";
                 echo "<a href=\"".traite_grr_url($grr_script_name)."?".$parametres_url."default_language=es\"><img src=\"img_grr/es_dp.png\" alt=\"Spanish\" title=\"Spanish\" width=\"20\" height=\"13\" class=\"image\" /></a>\n";

            //}
            $disconnect_link = false;
            if (!((getSettingValue("cacher_lien_deconnecter")=='y') and (isset($_SESSION['est_authentifie_sso'])))) {
               // on n'affiche pas le lien logout dans le cas d'un utilisateur LCS connecté.
               $disconnect_link = true;
               if (getSettingValue("authentification_obli") == 1) {
                   echo "<br />&nbsp;<a href=\"./logout.php?auto=0\" >".get_vocab('disconnect')."</a>";
               } else {
                   echo "<br />&nbsp;<a href=\"./logout.php?auto=0&amp;redirect_page_accueil=yes\" >".get_vocab('disconnect')."</a>";
               }
            }
            if ((getSettingValue("Url_portail_sso")!='') and (isset($_SESSION['est_authentifie_sso']))) {
                if ($disconnect_link)
                   echo "&nbsp;-&nbsp;";
                else
                   echo "<br />&nbsp;";
                echo('<a href="'.getSettingValue("Url_portail_sso").'">'.get_vocab("Portail_accueil").'</a>');
             }
             // Cas d'une authentification LASSO
             if ((getSettingValue('sso_statut') == 'lasso_visiteur') or (getSettingValue('sso_statut') == 'lasso_utilisateur')) {
               echo "<br />&nbsp;";
               if ($_SESSION['lasso_nameid'] == NULL)
                 echo "<a href=\"lasso/federate.php\">".get_vocab('lasso_federate_this_account')."</a>";
               else
                 echo "<a href=\"lasso/defederate.php\">".get_vocab('lasso_defederate_this_account')."</a>";
               }
          }
      ?>
     </td>
     <?php
	   if (((isset($area)) and ($area > 0)) or ((isset($room)) and ($room > 0)))
	      // si aucune ressource ni domaine ne sont définis, on affiche pas la colonne de sélection du jour
        $affiche_col_date = TRUE;
	   else
	      $affiche_col_date = FALSE;

     if (($page=="no_admin") and ($affiche_col_date)) {
     ?>
         <td class="banner"  align="center">
           <form id="myform" action="" method="get" onsubmit="return onsubmitForm();"><div>
           <?php
           genDateSelector("", $day, $month, $year,"");
    		   if ((isset($area)) and ($area > 0))
             echo "<input type=\"hidden\" id=\"area_\" name=\"area\" value=\"$area\" />";
    		   if ((isset($room)) and ($room > 0))
             echo "<input type=\"hidden\" id=\"room_\" name=\"room\" value=\"$room\" />";
           ?>
		   <input type="submit" value="<?php echo get_vocab("gototoday") ?>" onclick="document.pressed='a'" />
           <br />
           <br />
           <input type="submit" value="<?php echo get_vocab("allday") ?>" onclick="document.pressed='d'" />
           <input type="submit" value="<?php echo get_vocab("week") ?>" onclick="document.pressed='w'" />
           <input type="submit" value="<?php echo get_vocab("month") ?>" onclick="document.pressed='m'" />
           </div></form>
         </td>
         <?php
     }
     if ($type_session == "with_session") {
          if ((authGetUserLevel(getUserName(),-1,'area') >= 4) or (authGetUserLevel(getUserName(),-1,'user') == 1))  {
           echo "<td class=\"banner\" align=\"center\">";
           echo "<a href='admin_accueil.php?day=$day&amp;month=$month&amp;year=$year'>".get_vocab("admin")."</a>\n";
           if(authGetUserLevel(getUserName(),-1,'area') >= 6)  {
              echo "<br />\n<form action=\"admin_save_mysql.php\" method=\"get\"><div>\n
              <input type=\"hidden\" name=\"flag_connect\" value=\"yes\" />\n
              <input type=\"submit\" value=\"".get_vocab("submit_backup")."\" /></div>\n
              </form>";
              how_many_connected();
           }
           echo "\n</td>";
      }
     }
      ?>
          <td class="banner" align="center">
      <?php
      if (@file_exists($clock_file)) {
        echo "<script type=\"text/javascript\">";
        echo "<!--\n";
        echo "new LiveClock();\n";
        echo "//-->";
        echo "</script><br />";
      }

      echo grr_help("","")."<br />";
      if (verif_access_search(getUserName())) {
          echo "<a href=\"report.php\">".get_vocab("report")."</a><br />";
      }
      echo "<span class=\"small\">".affiche_version()."</span> - ";
      if ($type_session == "with_session") {
          if ($_SESSION['statut'] == 'administrateur') {
              echo affiche_lien_contact("contact_support","identifiant:non","seulement_si_email");
          } else {
              echo affiche_lien_contact("contact_administrateur","identifiant:non","seulement_si_email");
          }
      } else {
          echo affiche_lien_contact("contact_administrateur","identifiant:non","seulement_si_email");
      }

          ?>
         </td>
        </tr>
       </table>
      </td>
     </tr>
    </table>
<?php
}
if (isset($use_prototype))
    echo "<script type=\"text/javascript\" src=\"./include/prototype-1.6.0.3.js\"></script>";
if (isset($use_tooltip_js))
    echo "<script type=\"text/javascript\" src=\"./include/tooltip.js\"></script>";
echo getSettingValue('message_accueil');
  }
}
示例#21
0
// Configuration Lasso
echo "<h2>".get_vocab("config_lasso_title").grr_help("aide_grr_lasso_sso")."</h2>\n";
echo "<div><input type=\"hidden\" name=\"valid\" value=\"1\" /></div>\n";
echo "<p>".get_vocab("lasso_SSO_explain")."</p>\n";
echo "<h3>".get_vocab("Statut_par_defaut_utilisateurs_importes")."</h3>\n";
echo "<div>".get_vocab("choix_statut_lasso_SSO")."<br />\n";
echo "<input type=\"radio\" name=\"sso_statut\" value=\"lasso_visiteur\" ";
if (getSettingValue("sso_statut")=='lasso_visiteur') echo " checked=\"checked\" ";
echo "/>".get_vocab("statut_visitor")."<br />\n";
echo "<input type=\"radio\" name=\"sso_statut\" value=\"lasso_utilisateur\" ";
if (getSettingValue("sso_statut")=='lasso_utilisateur') echo " checked=\"checked\" ";
echo "/>".get_vocab("statut_user")."<br /></div>\n";

echo "<hr />\n";
// Configuration apache
echo "<h2>".get_vocab("config_http_title").grr_help("aide_grr_authentification_http")."</h2>\n";
echo "<div><input type=\"hidden\" name=\"valid\" value=\"1\" /></div>\n";
echo "<p>".get_vocab("http_SSO_explain")."</p>\n";
echo "<h3>".get_vocab("Statut_par_defaut_utilisateurs_importes")."</h3>\n";
echo "<div>".get_vocab("choix_statut_http_SSO")."<br />\n";
echo "<input type=\"radio\" name=\"sso_statut\" value=\"http_visiteur\" ";
if (getSettingValue("sso_statut")=='http_visiteur') echo " checked=\"checked\" ";
echo "/>".get_vocab("statut_visitor")."<br />\n";
echo "<input type=\"radio\" name=\"sso_statut\" value=\"http_utilisateur\" ";
if (getSettingValue("sso_statut")=='http_utilisateur') echo " checked=\"checked\" ";
echo "/>".get_vocab("statut_user")."<br /></div>\n";

//ajout des champs de recherche perso :
echo "<div><br />".get_vocab("explain_champs recherche")."<br />\n";
echo get_vocab("name").get_vocab("deux_points")."<input type=\"text\" name=\"http_champ_nom\"";
if (getSettingValue("http_champ_nom")) echo "value=\"".getSettingValue("http_champ_nom")."\"";
示例#22
0
        else
        $msg = get_vocab("message_records");
}


$back = "";
if (isset($_SERVER['HTTP_REFERER'])) $back = grr_htmlSpecialChars($_SERVER['HTTP_REFERER']);

# print the page header
print_header("","","","",$type="with_session", $page="admin");
// Affichage de la colonne de gauche
include "admin_col_gauche.php";
?>
<script src="./functions.js" type="text/javascript"></script>
<?php
echo "<h2>".get_vocab('admin_corresp_statut.php').grr_help("aide_grr_cas_attributs_ldap")."</h2>";
echo get_vocab('admin_corresp_statut_desc');
echo "<br />\n";
echo "<br />\n";

$sql = "SELECT code_fonction, libelle_fonction, statut_grr, id FROM  ".TABLE_PREFIX."_correspondance_statut";
$res = grr_sql_query($sql);
$nb_lignes = grr_sql_count($res);
if ($nb_lignes == 0) { // Si aucune ligne à afficher
    // fin de l'affichage de la colonne de droite
	echo get_vocab('aucune_correspondance');

}

else { // S'il y a des lignes à afficher
	// Affichage du tableau
示例#23
0
        $sql = "DELETE FROM ".TABLE_PREFIX."_j_mailuser_room WHERE (login='******'login_admin']."' and id_room = '$room')";
        if (grr_sql_command($sql) < 0) {fatal_error(1, "<p>" . grr_sql_error());}  else {$msg=get_vocab("del_user_succeed");}
    }
}
# print the page header
print_header("","","","",$type="with_session", $page="admin");
// Affichage de la colonne de gauche
include "admin_col_gauche.php";

affiche_pop_up($msg,"admin");


if (empty($room)) $room = -1;

echo "<h2>".get_vocab('admin_email_manager.php').grr_help("aide_grr_mail_auto")."</h2>\n";
if (getSettingValue("automatic_mail") != 'yes')
    echo "<h3 class=\"avertissement\">".get_vocab("attention_mail_automatique_désactive")."</h3>";

echo get_vocab("explain_automatic_mail3")."<br /><br /><hr />\n";
echo "<form action=\"admin_email_manager.php\" method=\"post\">\n";
echo "<div><input type=\"checkbox\" name=\"send_always_mail_to_creator\" value=\"y\" ";
if (getSettingValue('send_always_mail_to_creator')=='1')
    echo ' checked="checked" ';
echo ' />'."\n";
echo get_vocab("explain_automatic_mail1");
echo "\n".'<br /><br /><div style="text-align:center;"><input type="submit" name="mail1" value="'.get_vocab('save').'" /></div></div></form><hr />';
echo get_vocab("explain_automatic_mail2")."<br />";
echo $msg;
# Table with areas, rooms.
echo "\n<table><tr>\n";
示例#24
0
文件: report.php 项目: rhertzog/lcs
    if (!isset($From_year)) $From_year = $year;
    if (!isset($To_day)) $To_day   = date("d", $to_time);
    if (!isset($To_month)) $To_month = date("m", $to_time);
    if (!isset($To_year)) $To_year  = date("Y", $to_time);
}
    #$summarize:
    # 1=Rapport seulement,
    # 2=Résumé seulement,
    # 3=Les deux,
    # 4=Télécharger le CSV du rapport
    # 5=Télécharger le CSV du résumé
if (empty($summarize)) $summarize = 1;

if (($summarize != 4) and ($summarize != 5)) {
?>
<div class="page_sans_col_gauche"><h1><?php echo get_vocab("search report stats").grr_help("aide_grr_recherche");?></h1>
<form method="get" action="report.php">
<?php
// Si format imprimable ($_GET['pview'] = 1), on n'affiche pas cette partie
if ($_GET['pview'] != 1) {
?>
<table border="0">
<tr><td class="CR"><?php echo get_vocab("report_start").get_vocab("deux_points");?></td>
    <td class="CL">
    <?php genDateSelector("From_", $From_day, $From_month, $From_year,""); ?>
    </td></tr>
<tr><td class="CR"><?php echo get_vocab("report_end").get_vocab("deux_points");?></td>
    <td class="CL">
    <?php genDateSelector("To_", $To_day, $To_month, $To_year,""); ?>
    </td></tr>
<?php
示例#25
0
		} else {
           $msg = get_vocab("warning_exist");
		}
	}

}

if ($action) {
    if ($action == "del_admin") {
        unset($login_admin); $login_admin = $_GET["login_admin"];
        $sql = "DELETE FROM ".TABLE_PREFIX."_j_useradmin_area WHERE (login='******' and id_area = '$id_area')";
        if (grr_sql_command($sql) < 0) {fatal_error(1, "<p>" . grr_sql_error());} else {$msg=get_vocab("del_user_succeed");}
    }
}

echo "<h2>".get_vocab('admin_right_admin.php').grr_help("aide_grr_administateur_restreint")."</h2>\n";
echo "<p><i>".get_vocab("admin_right_admin_explain")."</i></p>\n";

// Affichage d'un pop-up
affiche_pop_up($msg,"admin");

# Table with areas.
echo "<table><tr>\n";
$this_area_name = "";
# Show all areas
echo "<td ><p><b>".get_vocab("areas")."</b></p>\n";
$out_html = "<form id=\"area\" action=\"admin_right_admin.php\" method=\"post\"><div><select name=\"area\" onchange=\"area_go()\">\n";
$out_html .= "<option value=\"admin_right_admin.php?id_area=-1\">".get_vocab('select')."</option>\n";
$sql = "select id, area_name from ".TABLE_PREFIX."_area order by order_display";
$res = grr_sql_query($sql);
if ($res) for ($i = 0; ($row = grr_sql_row($res, $i)); $i++)
示例#26
0
    showAccessDenied($day, $month, $year, '',$back);
    exit();
}

# print the page header
print_header("","","","",$type="with_session", $page="admin");
// Affichage de la colonne de gauche
if (!        isset($_GET['pview']))
    include "admin_col_gauche.php";
// Affichage du tableau de choix des sous-configurations des jours/cycles (créer et voir le calendrier des jours/cycles)
if (!isset($_GET['pview']))
    include "include/admin_calend_jour_cycle.inc.php";

echo "<h3>".get_vocab('calendrier_jours/cycles');
if (!isset($_GET['pview']))
    echo grr_help("aide_grr_jours_cycle");
echo "</h3>\n";
if (!isset($_GET['pview'])) {
    echo get_vocab("explication_Jours_Cycles3");
    echo "<br />".get_vocab("explication_Jours_Cycles4")."<br />\n";
}


// Modification d'un jour cycle
// intval($jour)=-1 : pas de jour cycle
// intval($jour)=0 : Titre
// intval($jour)>0 : Jour cycle
if(!isset($_GET['pview']) and isset($_GET['date'])) {
    $jour_cycle = grr_sql_query1("select Jours from ".TABLE_PREFIX."_calendrier_jours_cycle  WHERE DAY = ".$_GET['date']."");
    echo "<fieldset style=\"padding-top: 8px; padding-bottom: 8px; width: 80%; margin-left: auto; margin-right: auto;\">\n";
    echo "<legend>".get_vocab('Journee du')." ".affiche_date($_GET['date'])."</legend>\n";