Save new folder
This commit is contained in:
361
front/drh.MonDossierRH.php
Normal file
361
front/drh.MonDossierRH.php
Normal file
@ -0,0 +1,361 @@
|
||||
<?php
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
use Glpi\Event;
|
||||
|
||||
include ('../inc/includes.php');
|
||||
|
||||
Session::checkLoginUser();
|
||||
|
||||
require_once '../functionsophalglpi.php';
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
if (Session::getCurrentInterface() == "helpdesk") {
|
||||
|
||||
Html::helpHeader("DRH", '', $_SESSION["glpiname"]);
|
||||
|
||||
} else {
|
||||
|
||||
Html::header("DRH", '', "", "");
|
||||
|
||||
}
|
||||
|
||||
$currentDate = date("Y-m-d");
|
||||
|
||||
/*
|
||||
|
||||
function callWebService($matricule , $operation){
|
||||
|
||||
|
||||
|
||||
$url = "http://si.sophal.net/controller/Webservices.php";
|
||||
|
||||
$accessKey = 'D*G-KaNdRgUkXp2s5v8y/B?E(H+MbQeS'; //CSRF ATTACK
|
||||
|
||||
|
||||
|
||||
$data = array(
|
||||
|
||||
'accessKey' => $accessKey ,
|
||||
|
||||
'matricule' => $matricule,
|
||||
|
||||
'operation' => $operation
|
||||
|
||||
);
|
||||
|
||||
|
||||
|
||||
$resource = curl_init();
|
||||
|
||||
curl_setopt($resource, CURLOPT_URL, $url);
|
||||
|
||||
curl_setopt($resource, CURLOPT_HTTPHEADER, array('Content-Type:multipart/form-data'));
|
||||
|
||||
curl_setopt($resource, CURLOPT_POST, 1);
|
||||
|
||||
curl_setopt($resource, CURLOPT_RETURNTRANSFER, 1);
|
||||
|
||||
curl_setopt($resource, CURLOPT_POSTFIELDS, $data);
|
||||
|
||||
|
||||
|
||||
$response = curl_exec($resource);
|
||||
|
||||
|
||||
|
||||
curl_close($resource);
|
||||
|
||||
|
||||
|
||||
if ($response !== false) {
|
||||
|
||||
return $response;
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
return false;
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
function getMatricule(){
|
||||
|
||||
|
||||
|
||||
global $DB;
|
||||
|
||||
|
||||
|
||||
$query = "SELECT registration_number as matricule from glpi_users
|
||||
|
||||
where glpi_users.id ='".$_SESSION["glpiID"]."' ";
|
||||
|
||||
$result = $DB->query($query);
|
||||
|
||||
|
||||
|
||||
if ($result->num_rows > 0) {
|
||||
|
||||
$res = $result->fetch_assoc();
|
||||
|
||||
return $res['matricule'];
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
return null;
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
$mat = getMatricule();
|
||||
|
||||
//echo"<div id='loadingslide'><div class='loadingindicator'>Chargement...</div></div>";
|
||||
|
||||
if(!empty($mat)){
|
||||
|
||||
|
||||
|
||||
$response =callWebService($mat , 'get_MonDossierRH');
|
||||
|
||||
|
||||
|
||||
echo "<div id='tabs1216654411' class='center vertical ui-tabs ui-corner-all ui-widget ui-widget-content ui-tabs-vertical ui-helper-clearfix ui-corner-left'>
|
||||
|
||||
<div id='ui-id-3' style='padding:0px;' aria-live='polite' aria-labelledby='ui-id-2' role='tabpanel' class='ui-tabs-panel ui-corner-bottom ui-widget-content' aria-hidden='false'>
|
||||
|
||||
|
||||
|
||||
<br>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<div class='spaced' id='tabsbody'>
|
||||
|
||||
<table class='tab_cadre_fixe' id='mainformtable'>
|
||||
|
||||
<tbody>
|
||||
|
||||
<tr class='headerRow'>
|
||||
|
||||
<th colspan='2' class=''>Mon Dossier</th>
|
||||
|
||||
<th colspan='2' class=''></th>
|
||||
|
||||
</tr>
|
||||
|
||||
|
||||
|
||||
<tr class=''>
|
||||
|
||||
<td width='20%'>Nom & Prenom :</td>
|
||||
|
||||
<td width='30%'>
|
||||
|
||||
<input id='fullname' size='40' type='text' name='fullname' value='' readonly>
|
||||
|
||||
</td>
|
||||
|
||||
<td colspan='2' rowspan='7' ><center><img style='width: 150px;' id='photo' src='' /></center></td>
|
||||
|
||||
</tr>
|
||||
|
||||
|
||||
|
||||
<tr class=''>
|
||||
|
||||
<td width='20%'>Département :</td>
|
||||
|
||||
<td colspan='3'>
|
||||
|
||||
<input size='40' id='Departement' type='text' name='Departement' value='' readonly>
|
||||
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
|
||||
|
||||
|
||||
<tr class=''>
|
||||
|
||||
<td width='20%'>Fonction :</td>
|
||||
|
||||
<td width='30%'>
|
||||
|
||||
<input id='Fonction' size='40' type='text' name='Fonction' value='' readonly>
|
||||
|
||||
|
||||
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
|
||||
<tr class=''>
|
||||
|
||||
<td width='20%'>Periode :</td>
|
||||
|
||||
<td width='30%'>
|
||||
|
||||
<input id='Periode' size='40' type='text' name='Periode' value='' readonly>
|
||||
|
||||
|
||||
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
|
||||
|
||||
|
||||
<tr class=''>
|
||||
|
||||
<td width='20%'>Téléphone :</td>
|
||||
|
||||
<td width='30%'>
|
||||
|
||||
<input id='tele' size='40' type='text' name='tele' value='' readonly>
|
||||
|
||||
|
||||
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
|
||||
<tr class=''>
|
||||
|
||||
<td width='20%'>Matricule :</td>
|
||||
|
||||
<td width='30%'>
|
||||
|
||||
<input id='Matricule' size='40' type='text' name='Matricule' value='' readonly>
|
||||
|
||||
|
||||
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
|
||||
|
||||
|
||||
<tr class=''>
|
||||
|
||||
<td width='20%'>Service :</td>
|
||||
|
||||
<td width='30%'>
|
||||
|
||||
<input id='Service' size='40' type='text' name='Service' value='' readonly>
|
||||
|
||||
|
||||
|
||||
</td>
|
||||
|
||||
</tr>
|
||||
|
||||
<tr class=''>
|
||||
|
||||
<td width='20%'>Date recrutement :</td>
|
||||
|
||||
<td width='30%' id='Date_recrutement'></td>
|
||||
|
||||
</tr>
|
||||
|
||||
<tr class=''>
|
||||
|
||||
<td width='20%'>au :</td>
|
||||
|
||||
<td width='30%' id='au'> </td>
|
||||
|
||||
</tr>
|
||||
|
||||
|
||||
|
||||
</tr>";
|
||||
|
||||
|
||||
|
||||
echo" </tbody>
|
||||
|
||||
</table>
|
||||
|
||||
</div>";
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/*
|
||||
|
||||
echo"<table class='tab_cadre_fixehov'>
|
||||
|
||||
<tr>
|
||||
|
||||
<th class=''>Num Contrat</th>
|
||||
|
||||
<th class=''>Date Début</th>
|
||||
|
||||
<th class=''>Date Fin</th>
|
||||
|
||||
<th class=''>Modèle</th>
|
||||
|
||||
</tr>
|
||||
|
||||
<tbody id='Contrats'></tbody>
|
||||
|
||||
</table>
|
||||
|
||||
<br><br>";
|
||||
|
||||
*/
|
||||
|
||||
|
||||
|
||||
echo"<table class='tab_cadre_fixehov'>
|
||||
|
||||
<tr>
|
||||
|
||||
<th class=''>Sanction</th>
|
||||
|
||||
<th class=''>Date Début</th>
|
||||
|
||||
<th class=''>Motif</th>
|
||||
|
||||
<th class=''>Degré</th>
|
||||
|
||||
</tr>
|
||||
|
||||
<tbody id='sanctions'></tbody>
|
||||
|
||||
</table>
|
||||
|
||||
<br><br>";
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user