コード例 #1
0
/**
 * Display common message for item not found
 *
 * @return Nothing
**/
function displayNotFoundError()
{
    global $LANG, $CFG_GLPI, $HEADER_LOADED;
    if (!$HEADER_LOADED) {
        if (!isset($_SESSION["glpiactiveprofile"]["interface"])) {
            nullHeader($LANG['login'][5]);
        } else {
            if ($_SESSION["glpiactiveprofile"]["interface"] == "central") {
                commonHeader($LANG['login'][5]);
            } else {
                if ($_SESSION["glpiactiveprofile"]["interface"] == "helpdesk") {
                    helpHeader($LANG['login'][5]);
                }
            }
        }
    }
    echo "<div class='center'><br><br>";
    echo "<img src='" . $CFG_GLPI["root_doc"] . "/pics/warning.png' alt='warning'><br><br>";
    echo "<strong>" . $LANG['common'][54] . "</strong></div>";
    nullFooter();
    exit;
}
コード例 #2
0
<?php

include "helpCommon.php";
helpHeader();
?>
<H3>Work Order CSV Upload</H3>
Work orders can be upload via a properly formatted CSV (comma separated values) file.  This format is a common import and export option for most software packages that deal with data in different formats.
<BR>
<BR>
<H4>Supported Fields</H4>
Required fields are in bold:
<UL>
<LI><B>product</B>&nbsp;-&nbsp;Name or numeric ID of product.</LI>
<LI>account&nbsp;-&nbsp;Name or numeric ID of product.</LI>
<LI><B>deadlineon</B></LI>
<LI>eststarton</LI>
<LI>estendon</LI>
<LI><B>esthours</B></LI>
<LI><B>priority</B>&nbsp;-&nbsp;Name or numeric ID of priority.</LI>
<LI><B>severity</B>&nbsp;-&nbsp;Name or numeric ID of severity.</LI>
<LI>contact</LI>
<LI>contactphone</LI>
<LI><B>summary</B></LI>
<LI>notes</LI>
<LI><B>description</B></LI>
<LI><B>responsible</B>&nbsp;-&nbsp;Name or numeric ID of personnel responsible.</LI>
<LI>revision</LI>
</UL>
Note that your permissions may not permit you to specify some of the fields that are listed here.
<H4>File Format</H4>
The file must be a comma-delimited text file.  The first row should contain the field names as listed above.  Date and text fields must be enclosed in double quotes ( &quot; ).  Dates should be submitted in the same format expected by DCL.
コード例 #3
0
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 GLPI; if not, write to the Free Software Foundation, Inc.,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
--------------------------------------------------------------------------
*/
// ----------------------------------------------------------------------
// Original Author of file:
// Purpose of file:
// ----------------------------------------------------------------------
define('GLPI_ROOT', '..');
include GLPI_ROOT . "/inc/includes.php";
checkSeveralRightsOr(array("reservation_central" => "r", "reservation_helpdesk" => "1"));
if ($_SESSION["glpiactiveprofile"]["interface"] == "helpdesk") {
    helpHeader($LANG['Menu'][31], $_SERVER['PHP_SELF'], $_SESSION["glpiname"]);
} else {
    commonHeader($LANG['Menu'][17], $_SERVER['PHP_SELF'], "utils", "reservation");
}
if (!haveRight("reservation_central", "r")) {
    ReservationItem::showListSimple();
} else {
    Search::show('ReservationItem');
}
if ($_SESSION["glpiactiveprofile"]["interface"] == "helpdesk") {
    helpFooter();
} else {
    commonFooter();
}
コード例 #4
0
/**
 * Simple Error message page
 *
 * @param $message string displayed before dying
 * @param $minimal set to true do not display app menu
 *
 * @return nothing as function kill script
 **/
function displayErrorAndDie($message, $minimal = false)
{
    global $LANG, $CFG_GLPI, $HEADER_LOADED;
    if (!$HEADER_LOADED) {
        if ($minimal || !isset($_SESSION["glpiactiveprofile"]["interface"])) {
            nullHeader($LANG['login'][5], '');
        } else {
            if ($_SESSION["glpiactiveprofile"]["interface"] == "central") {
                commonHeader($LANG['login'][5], '');
            } else {
                if ($_SESSION["glpiactiveprofile"]["interface"] == "helpdesk") {
                    helpHeader($LANG['login'][5], '');
                }
            }
        }
    }
    echo "<div class='center'><br><br>";
    echo "<img src='" . $CFG_GLPI["root_doc"] . "/pics/warning.png' alt='warning'><br><br>";
    echo "<strong>{$message}</strong></div>";
    nullFooter();
    exit;
}
コード例 #5
0
                                $track->check($_REQUEST['tickets_id'], 'r');
                                $input = array('tickets_id' => $_REQUEST['tickets_id'], 'users_id' => getLoginUserID(), 'use_notification' => 1, 'type' => Ticket::OBSERVER);
                                $ticket_user->add($input);
                                Event::log($_REQUEST['tickets_id'], "ticket", 4, "tracking", $_SESSION["glpiname"] . " " . $LANG['log'][21]);
                                glpi_header($CFG_GLPI["root_doc"] . "/front/ticket.form.php?id=" . $_REQUEST['tickets_id']);
                            }
                        }
                    }
                }
            }
        }
    }
}
if (isset($_GET["id"]) && $_GET["id"] > 0) {
    if ($_SESSION["glpiactiveprofile"]["interface"] == "helpdesk") {
        helpHeader($LANG['Menu'][5], '', $_SESSION["glpiname"]);
    } else {
        commonHeader($LANG['Menu'][5], '', "maintain", "ticket");
    }
    $available_options = array('load_kb_sol');
    $options = array();
    foreach ($available_options as $key) {
        if (isset($_GET[$key])) {
            $options[$key] = $_GET[$key];
        }
    }
    $track->showForm($_GET["id"], $options);
} else {
    commonHeader($LANG['job'][13], '', "maintain", "ticket");
    $users_id_requester = getLoginUserID();
    // No default requester if own ticket right = tech and update_ticket right to update requester
コード例 #6
0
$user = new User();
// Manage lost password
if (isset($_GET['lostpassword'])) {
    nullHeader();
    if (isset($_GET['token'])) {
        User::showPasswordForgetChangeForm($_GET['token']);
    } else {
        User::showPasswordForgetRequestForm();
    }
    nullFooter();
    exit;
}
checkLoginUser();
if (isset($_POST["update"]) && $_POST["id"] === getLoginUserID()) {
    $user->update($_POST);
    Event::log(0, "users", 5, "setup", $_SESSION["glpiname"] . "  " . $LANG['log'][21] . "  " . $_SESSION["glpiname"] . ".");
    glpi_header($_SERVER['HTTP_REFERER']);
} else {
    if ($_SESSION["glpiactiveprofile"]["interface"] == "central") {
        commonHeader($LANG['title'][13], $_SERVER['PHP_SELF'], 'preference');
    } else {
        helpHeader($LANG['title'][13], $_SERVER['PHP_SELF']);
    }
    $pref = new Preference();
    $pref->show();
    if ($_SESSION["glpiactiveprofile"]["interface"] == "central") {
        commonFooter();
    } else {
        helpFooter();
    }
}
コード例 #7
0
ファイル: ticket.php プロジェクト: ryukansent/Thesis-SideB
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.

GLPI 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 GLPI; if not, write to the Free Software Foundation, Inc.,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
--------------------------------------------------------------------------
*/
// ----------------------------------------------------------------------
// Original Author of file:
// Purpose of file:
// ----------------------------------------------------------------------
define('GLPI_ROOT', '..');
include GLPI_ROOT . "/inc/includes.php";
checkLoginUser();
if ($_SESSION["glpiactiveprofile"]["interface"] == "helpdesk") {
    helpHeader($LANG['title'][10], '', $_SESSION["glpiname"]);
} else {
    commonHeader($LANG['title'][10], '', "maintain", "ticket");
}
Search::show('Ticket');
if ($_SESSION["glpiactiveprofile"]["interface"] == "helpdesk") {
    helpFooter();
} else {
    commonFooter();
}
コード例 #8
0
ファイル: helpdeskrating.php プロジェクト: geldarr/hack-space
 * http://sourceforge.net/projects/helpdeskrating/
 *
 ************************************************************************************************
 *
 * LICENSE
 *
 *     This file is part of the GLPI Plugin Helpdeskrating.
 *
 *     The GLPI Plugin Helpdeskrating is free software: you can redistribute it and/or modify
 *     it under the terms of the GNU Lesser Public License as published by
 *     the Free Software Foundation, either version 3 of the License, or
 *     (at your option) any later version.
 *
 *     The GLPI Plugin Helpdeskrating 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 Lesser Public License for more details.
 *
 *     You should have received a copy of the GNU Lesser Public License
 *     along with the GLPI Plugin Helpdeskrating.  If not, see <http://www.gnu.org/licenses/>.
 *
 ************************************************************************************************/
define('GLPI_ROOT', '../../..');
include GLPI_ROOT . '/inc/includes.php';
if ($_SESSION['glpiactiveprofile']['interface'] == 'central') {
    Html::header('TITRE', $_SERVER['PHP_SELF'], 'plugins', 'helpdeskrating', 'optionname');
} else {
    helpHeader('TITLE', $_SERVER['PHP_SELF']);
}
Search::show('PluginHelpdeskratingHelpdeskrating');
commonFooter();
コード例 #9
0
// redirect if no create ticket right
if (!haveRight('create_ticket', 1)) {
    if (haveRight('observe_ticket', 1) || haveRight('validate_ticket', 1)) {
        glpi_header($CFG_GLPI['root_doc'] . "/front/ticket.php");
    } else {
        if (haveRight('reservation_helpdesk', 1)) {
            glpi_header($CFG_GLPI['root_doc'] . "/front/reservationitem.php");
        } else {
            if (haveRight('faq', 'r')) {
                glpi_header($CFG_GLPI['root_doc'] . "/front/helpdesk.faq.php");
            }
        }
    }
}
checkHelpdeskAccess();
helpHeader($LANG['job'][13], $_SERVER['PHP_SELF'], $_SESSION["glpiname"]);
if (isset($_GET['create_ticket'])) {
    printHelpDesk(getLoginUserID(), 1);
} else {
    echo "<table class='tab_cadre_central'><tr>";
    echo "<td class='top'><br>";
    echo "<table>";
    if (haveRight('create_ticket', 1)) {
        echo "<tr><td class='top' width='450px'>";
        Ticket::showCentralCount(true);
        echo "</td></tr>";
    }
    if (haveRight("reminder_public", "r")) {
        echo "<tr><td class='top' width='450px'>";
        Reminder::showListForCentral($_SESSION["glpiactive_entity"]);
        $entities = array_reverse(getAncestorsOf("glpi_entities", $_SESSION["glpiactive_entity"]));