-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #6 from nicolas-eoxia/add_structure_projet
#5 [Mod] add: initialize project GMAO structure
- Loading branch information
Showing
25 changed files
with
1,309 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
name: 'Generate Auto Changelog' | ||
on: | ||
push: | ||
branches: | ||
- main | ||
jobs: | ||
master: | ||
name: 'build' | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@master | ||
with: | ||
fetch-depth: 0 | ||
- name: Generate Auto Changelog | ||
uses: Evarisk/action-auto-changelog@master | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# Generated binaries | ||
/build/*.zip | ||
/bin/*.zip | ||
# Doxygen generated documentation | ||
/build/doxygen/doxygen_warnings.log | ||
/doc/code/doxygen | ||
# Composer managed dependencies | ||
/vendor | ||
/dev/bin | ||
# PHPdocumentor generated files | ||
/build/phpdoc | ||
/doc/code/phpdoc | ||
# Sphinx generated files | ||
/doc/user/build | ||
/.settings/ | ||
/.buildpath | ||
/.project | ||
# Other | ||
*.back | ||
/.editorconfig | ||
/.gitattributes | ||
node_modules | ||
package-lock.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
<?php | ||
//Silence is golden |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
<?php | ||
/* Copyright (C) 2024 EVARISK <technique@evarisk.com> | ||
* | ||
* 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 3 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. If not, see <https://www.gnu.org/licenses/>. | ||
*/ | ||
|
||
/** | ||
* \file admin/setup.php | ||
* \ingroup gmao | ||
* \brief GMAO setup page | ||
*/ | ||
|
||
// Load GMAO environment | ||
if (file_exists('../gmao.main.inc.php')) { | ||
require_once __DIR__ . '/../gmao.main.inc.php'; | ||
} elseif (file_exists('../../gmao.main.inc.php')) { | ||
require_once __DIR__ . '/../../gmao.main.inc.php'; | ||
} else { | ||
die('Include of gmao main fails'); | ||
} | ||
|
||
// Load GMAO libraries | ||
require_once __DIR__ . '/../lib/gmao.lib.php'; | ||
|
||
// Global variables definitions | ||
global $conf, $db, $langs, $user; | ||
|
||
// Load translation files required by the page | ||
saturne_load_langs(); | ||
|
||
// Get parameters | ||
$action = GETPOST('action', 'alpha'); | ||
$backtopage = GETPOST('backtopage', 'alpha'); | ||
|
||
// Initialize view objects | ||
$form = new Form($db); | ||
|
||
// Security check - Protection if external user | ||
$permissionToRead = $user->rights->gmao->adminpage->read; | ||
saturne_check_access($permissionToRead); | ||
|
||
/* | ||
* View | ||
*/ | ||
|
||
$title = $langs->trans('ModuleSetup', 'GMAO'); | ||
$help_url = 'FR:Module_GMAO'; | ||
|
||
saturne_header(0,'', $title, $help_url); | ||
|
||
// Subheader | ||
$linkback = '<a href="' . ($backtopage ?: DOL_URL_ROOT . '/admin/modules.php?restore_lastsearch_values=1') . '">' . $langs->trans('BackToModuleList') . '</a>'; | ||
print load_fiche_titre($title, $linkback, 'title_setup'); | ||
|
||
// Configuration header | ||
$head = gmao_admin_prepare_head(); | ||
print dol_get_fiche_head($head, 'settings', $title, -1, 'gmao_color@gmao'); | ||
|
||
$db->close(); | ||
llxFooter(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
### Changelog | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
<?php | ||
/* Copyright (C) 2024 EVARISK <technique@evarisk.com> | ||
* | ||
* 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 3 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. If not, see <https://www.gnu.org/licenses/>. | ||
*/ | ||
|
||
/** | ||
* \file class/actions_gmao.class.php | ||
* \ingroup gmao | ||
* \brief GMAO hook overload | ||
*/ | ||
|
||
// Load GMAO libraries | ||
require_once __DIR__ . '/../lib/gmao_function.lib.php'; | ||
|
||
/** | ||
* Class ActionsGmao | ||
*/ | ||
class ActionsGmao | ||
{ | ||
/** | ||
* @var DoliDB Database handler | ||
*/ | ||
public DoliDB $db; | ||
|
||
/** | ||
* @var string Error code (or message) | ||
*/ | ||
public string $error = ''; | ||
|
||
/** | ||
* @var array Errors. | ||
*/ | ||
public array $errors = []; | ||
|
||
/** | ||
* @var array Hook results. Propagated to $hookmanager->resArray for later reuse | ||
*/ | ||
public array $results = []; | ||
|
||
/** | ||
* @var string String displayed by executeHook() immediately after return | ||
*/ | ||
public string $resprints; | ||
|
||
/** | ||
* Constructor | ||
* | ||
* @param DoliDB $db Database handler | ||
*/ | ||
public function __construct(DoliDB $db) | ||
{ | ||
$this->db = $db; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
<?php | ||
//Silence is golden |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
<?php | ||
//Silence is golden |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
<?php | ||
//Silence is golden |
Oops, something went wrong.