Refactor configuration files and clean up project structure

Removed unused datasource definitions and redundant module references. Added default settings for code styles and inspection profiles. Adjusted indentation and formatting in HTML and PHP files for better readability and maintainability.
This commit is contained in:
e025532
2025-05-27 09:48:15 +02:00
parent 90c911835c
commit f1aebef05b
11 changed files with 434 additions and 455 deletions

5
.idea/codeStyles/codeStyleConfig.xml generated Normal file
View File

@@ -0,0 +1,5 @@
<component name="ProjectCodeStyleConfiguration">
<state>
<option name="PREFERRED_PROJECT_CODE_STYLE" value="Default" />
</state>
</component>

19
.idea/dataSources.xml generated
View File

@@ -1,19 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="DataSourceManagerImpl" format="xml" multifile-model="true">
<data-source source="LOCAL" name="GLPI" uuid="06d48534-f219-40f0-abc2-525fb3fb7abb">
<driver-ref>mysql.8</driver-ref>
<synchronize>true</synchronize>
<jdbc-driver>com.mysql.cj.jdbc.Driver</jdbc-driver>
<jdbc-url>jdbc:mysql://mys_glpi_prod.appliarmony.net:3306/GLPI</jdbc-url>
<working-dir>$ProjectFileDir$</working-dir>
</data-source>
<data-source source="LOCAL" name="DUN-SUP-ENTRY01" uuid="bfae45b5-d30f-4d9a-89b9-397d849a56ba">
<driver-ref>mysql.8</driver-ref>
<synchronize>true</synchronize>
<jdbc-driver>com.mysql.cj.jdbc.Driver</jdbc-driver>
<jdbc-url>jdbc:mysql://DUN-SUP-ENTRY01:3306/infra</jdbc-url>
<working-dir>$ProjectFileDir$</working-dir>
</data-source>
</component>
</project>

View File

@@ -0,0 +1,7 @@
<component name="InspectionProjectProfileManager">
<settings>
<option name="PROJECT_PROFILE" value="Default" />
<option name="USE_PROJECT_PROFILE" value="false" />
<version value="1.0" />
</settings>
</component>

4
.idea/modules.xml generated
View File

@@ -2,11 +2,7 @@
<project version="4"> <project version="4">
<component name="ProjectModuleManager"> <component name="ProjectModuleManager">
<modules> <modules>
<module fileurl="file://$PROJECT_DIR$/../Infra-Tools/.idea/Infra-Tools.iml" filepath="$PROJECT_DIR$/../Infra-Tools/.idea/Infra-Tools.iml" />
<module fileurl="file://$PROJECT_DIR$/../web-infra-diy/.idea/web-infra-diy.iml" filepath="$PROJECT_DIR$/../web-infra-diy/.idea/web-infra-diy.iml" />
<module fileurl="file://$PROJECT_DIR$/.idea/web-infra-reports.iml" filepath="$PROJECT_DIR$/.idea/web-infra-reports.iml" /> <module fileurl="file://$PROJECT_DIR$/.idea/web-infra-reports.iml" filepath="$PROJECT_DIR$/.idea/web-infra-reports.iml" />
<module fileurl="file://$PROJECT_DIR$/../web-pingcastle/.idea/web-pingcastle.iml" filepath="$PROJECT_DIR$/../web-pingcastle/.idea/web-pingcastle.iml" />
<module fileurl="file://$PROJECT_DIR$/../web-wintel/.idea/web-wintel.iml" filepath="$PROJECT_DIR$/../web-wintel/.idea/web-wintel.iml" />
</modules> </modules>
</component> </component>
</project> </project>

3
.idea/php.xml generated
View File

@@ -10,6 +10,9 @@
<option name="highlightLevel" value="WARNING" /> <option name="highlightLevel" value="WARNING" />
<option name="transferred" value="true" /> <option name="transferred" value="true" />
</component> </component>
<component name="PhpProjectSharedConfiguration" php_language_level="7.0">
<option name="suggestChangeDefaultLanguageLevel" value="false" />
</component>
<component name="PhpStanOptionsConfiguration"> <component name="PhpStanOptionsConfiguration">
<option name="transferred" value="true" /> <option name="transferred" value="true" />
</component> </component>

6
.idea/sqldialects.xml generated Normal file
View File

@@ -0,0 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="SqlDialectMappings">
<file url="file://$PROJECT_DIR$/crossover/GlobalCrossover2.php" dialect="GenericSQL" />
</component>
</project>

2
.idea/vcs.xml generated
View File

@@ -2,8 +2,6 @@
<project version="4"> <project version="4">
<component name="VcsDirectoryMappings"> <component name="VcsDirectoryMappings">
<mapping directory="" vcs="Git" /> <mapping directory="" vcs="Git" />
<mapping directory="$PROJECT_DIR$/../Infra-Tools" vcs="Git" />
<mapping directory="$PROJECT_DIR$" vcs="Git" /> <mapping directory="$PROJECT_DIR$" vcs="Git" />
<mapping directory="$PROJECT_DIR$/../web-wintel" vcs="Git" />
</component> </component>
</project> </project>

View File

@@ -1,12 +1,10 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<module type="WEB_MODULE" version="4"> <module type="WEB_MODULE" version="4">
<component name="NewModuleRootManager"> <component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$" /> <content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$" isTestSource="false" />
</content>
<orderEntry type="inheritedJdk" /> <orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" /> <orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="module" module-name="web-pingcastle" />
<orderEntry type="module" module-name="Infra-Tools" />
<orderEntry type="module" module-name="web-wintel" />
<orderEntry type="module" module-name="web-infra-diy" />
</component> </component>
</module> </module>

View File

@@ -28,10 +28,10 @@
</head> </head>
<body class="bg-light text-dark"> <body class="bg-light text-dark">
<?php include $_SERVER['DOCUMENT_ROOT'] . "/include/preloader.inc.html"; ?> <!-- Preloader --> <?php include $_SERVER['DOCUMENT_ROOT'] . "/include/preloader.inc.html"; ?> <!-- Preloader -->
<?php include $_SERVER['DOCUMENT_ROOT'] . "/include/db_connect.php"; ?> <!-- Database connexion --> <?php include $_SERVER['DOCUMENT_ROOT'] . "/include/db_connect.php"; ?> <!-- Database connexion -->
<?php //include $_SERVER['DOCUMENT_ROOT']."/include/functions.inc.php" ; ?> <!-- Functions --> <?php //include $_SERVER['DOCUMENT_ROOT']."/include/functions.inc.php" ; ?> <!-- Functions -->
<div class="container-fluid"> <div class="container-fluid">
<div class="row flex-nowrap"> <div class="row flex-nowrap">
<!-- Left NAVBAR --> <!-- Left NAVBAR -->
<div class="col-auto col-md-2 col-xl-2 px-sm-2 px-0 bg-dark" style="-ms-flex: 0 0 230px;flex: 0 0 230px;"> <div class="col-auto col-md-2 col-xl-2 px-sm-2 px-0 bg-dark" style="-ms-flex: 0 0 230px;flex: 0 0 230px;">
@@ -104,7 +104,8 @@
<th data-field="ADlu" data-sortable="true" data-visible="false">AD Last Logon</th> <th data-field="ADlu" data-sortable="true" data-visible="false">AD Last Logon</th>
<th data-field="GLPI" data-sortable="true">GLPI</th> <th data-field="GLPI" data-sortable="true">GLPI</th>
<th data-field="GLPIlu" data-sortable="true" data-visible="false" data-footer-formatter="FI">Last FI <th data-field="GLPIlu" data-sortable="true" data-visible="false" data-footer-formatter="FI">Last FI
Inventory</th> Inventory
</th>
<th data-field="SCCM" data-sortable="true">SCCM<br></th> <th data-field="SCCM" data-sortable="true">SCCM<br></th>
<th data-field="SCCMlu" data-sortable="true" data-visible="false">SCCM Last Heartbeat</th> <th data-field="SCCMlu" data-sortable="true" data-visible="false">SCCM Last Heartbeat</th>
<th data-field="Backup" data-sortable="true">Backup</th> <th data-field="Backup" data-sortable="true">Backup</th>
@@ -282,8 +283,8 @@
} }
// zabbix // zabbix
if ($row['zabbix'] == 'Y' || strpos($row['zabbix'], '.') !== false ) { if ($row['zabbix'] == 'Y' || strpos($row['zabbix'], '.') !== false) {
echo "<td class='bg-success text-white'>".str_replace('Y','OK',$row['zabbix'])."</td>"; echo "<td class='bg-success text-white'>" . str_replace('Y', 'OK', $row['zabbix']) . "</td>";
} else { } else {
if (isset($row['zabbix'])) { if (isset($row['zabbix'])) {
echo "<td class='bg-secondary'><small>" . $row['zabbix'] . "</small></td>"; echo "<td class='bg-secondary'><small>" . $row['zabbix'] . "</small></td>";
@@ -418,8 +419,8 @@
<!-- End of main content --> <!-- End of main content -->
</div> </div>
</div> </div>
</div> </div>
<script src="/js/switch.js"></script> <script src="/js/switch.js"></script>
</body> </body>
@@ -437,7 +438,11 @@
$('.preloader').addClass('preloader-deactivate'); $('.preloader').addClass('preloader-deactivate');
}); });
document.addEventListener("DOMContentLoaded", function () { setTimeout(function () { document.getElementById('button').click(); }, 1000); }); document.addEventListener("DOMContentLoaded", function () {
setTimeout(function () {
document.getElementById('button').click();
}, 1000);
});
</script> </script>
</HTML> </HTML>

View File

@@ -11,15 +11,10 @@
function DB_GLPI() { function DB_GLPI() {
$username="glpi_lect_seule"; $username="glpi_lect_seule";
$password="glpi_lect_seule"; $password="glpi_lect_seule";
$dbserver="srvv-n4glpi-aim.process.dkm";
$dbserver="mys_glpi_prod.appliarmony.net"; $dbserver="mys_glpi_prod.appliarmony.net";
$database="glpi"; $database="glpi";
global $conn ; global $conn ;
$conn = new mysqli($dbserver,$username,$password,$database); $conn = new mysqli($dbserver,$username,$password,$database);
if (!$conn) {
echo "No connection to the database: " ;
exit;
}
} }
function DB_ENTRY01() { function DB_ENTRY01() {
@@ -29,10 +24,6 @@
$database="infra"; $database="infra";
global $conn ; global $conn ;
$conn = new mysqli($dbserver,$username,$password,$database); $conn = new mysqli($dbserver,$username,$password,$database);
if (!$conn) {
echo "No connection to the database: " ;
exit;
}
} }
function DB_ENTRY02() { function DB_ENTRY02() {
@@ -42,22 +33,9 @@
$database="web-infra-reports"; $database="web-infra-reports";
global $conn ; global $conn ;
$conn = new mysqli($dbserver,$username,$password,$database); $conn = new mysqli($dbserver,$username,$password,$database);
if (!$conn) {
echo "No connection to the database: " ;
exit;
}
}
function DB_EPO(){
$user = "epo_db_read_bdnorth_admin";
$pwd = 'Qs$PeBtg5nPJ7J';
global $conn ;
$conn = odbc_connect("Driver={SQL Server};Server=CORP1PWSR001EDB.agd.agn;Database=epo_ARMEOSDDC001;", $user, $pwd);
if(!($conn)){echo "Pas de connexion";}
} }
?>

View File

@@ -1,5 +1,6 @@
<!-- MODAL WAIT --> <!-- MODAL WAIT -->
<div class="modal fade bs-example-modal-sm" id="wait" tabindex="-1" role="dialog" aria-hidden="true" data-backdrop="static" style="padding-top: 15%;"> <div class="modal fade bs-example-modal-sm" id="wait" tabindex="-1" role="dialog" aria-hidden="true"
data-backdrop="static" style="padding-top: 15%;">
<div class="modal-dialog modal-sm"> <div class="modal-dialog modal-sm">
<div class="modal-content"> <div class="modal-content">
<div class="modal-header"> <div class="modal-header">
@@ -9,7 +10,8 @@
</div> </div>
<div class="modal-body"> <div class="modal-body">
<div class="progress"> <div class="progress">
<div class="progress-bar progress-bar-secondary progress-bar-striped progress-bar-animated" style="width: 100%"></div> <div class="progress-bar progress-bar-secondary progress-bar-striped progress-bar-animated"
style="width: 100%"></div>
</div> </div>
</div> </div>
</div> </div>