Compare commits

..

6 Commits

Author SHA1 Message Date
a3f54b2f11 reconf env.model 2023-09-06 14:23:54 +02:00
386d639151 gestion composer 1 & 2 2023-08-31 15:43:48 +02:00
a2899ee93b correctif breakday 2023-08-31 11:10:50 +02:00
efe978130c rest breakday depuis depuis début ninebadge 2023-08-25 15:43:56 +02:00
9c752523b4 rest breakday depuis depuis début ninebadge 2023-08-25 15:42:28 +02:00
afornerot
43c1b6f5ce correction feriées sur synthèse (fix #82) 2023-05-16 17:20:38 +02:00
16 changed files with 49 additions and 100 deletions

1
debian/compat vendored
View File

@@ -1 +0,0 @@
7

24
debian/control vendored
View File

@@ -1,24 +0,0 @@
Source: eole-schedule
Section: web
Priority: optional
Maintainer: Cadoles <contact@cadoles.com>
Build-Depends: debhelper (>= 7.0.50)
Standards-Version: 3.8.4
Homepage: https://forge.cadoles.com/Cadoles/schedule
Vcs-Git: https://forge.cadoles.com/Cadoles/schedule
Vcs-Browser: https://forge.cadoles.com/Cadoles/schedule
Package: schedule-sso
Architecture: all
Depends: ${misc:Depends}, eole-sso
Description: Filtre SSO pour schedule "EOLE".
Package: eole-schedule
Architecture: all
Depends: ${misc:Depends}, eole-envole-dependances, schedule-sso
Description: Eolisation de l'application schedule.
Package: schedule-apps
Architecture: all
Depends: ${misc:Depends}, envole-dependances-apps
Description: Sources pour schedule "EOLE".

44
debian/copyright vendored
View File

@@ -1,44 +0,0 @@
Format: http://dep.debian.net/deps/dep5
Upstream-Name: {PROJECT}
Source: {URL}
Files: *
Copyright: YEAR {UPSTREAM} {AUTHOR} <{MAIL}>
License: {UPSTREAM LICENSE}
Files: debian/*
Copyright: 2012 Équipe EOLE <eole@ac-dijon.fr>
License: CeCILL-2
License: {UPSTREAM LICENSE}
{TEXT OF THE LICENSE}
License: CeCILL-2
This software is governed by the CeCILL-2 license under French law and
abiding by the rules of distribution of free software. You can use,
modify and or redistribute the software under the terms of the CeCILL-2
license as circulated by CEA, CNRS and INRIA at the following URL
"http://www.cecill.info";.
.
As a counterpart to the access to the source code and rights to copy,
modify and redistribute granted by the license, users are provided only
with a limited warranty and the software's author, the holder of the
economic rights, and the successive licensors have only limited
liability.
.
In this respect, the user's attention is drawn to the risks associated
with loading, using, modifying and/or developing or reproducing the
software by the user in light of its specific status of free software,
that may mean that it is complicated to manipulate, and that also
therefore means that it is reserved for developers and experienced
professionals having in-depth computer knowledge. Users are therefore
encouraged to load and test the software's suitability as regards their
requirements in conditions enabling the security of their systems and/or
data to be ensured and, more generally, to use and operate it in the
same conditions as regards security.
.
The fact that you are presently reading this means that you have had
knowledge of the CeCILL-2 license and that you accept its terms.
.
On Eole systems, the complete text of the CeCILL-2 License can be found
in '/usr/share/common-licenses/CeCILL-2-en'.

View File

@@ -1 +0,0 @@
usr/share/eole

3
debian/gbp.conf vendored
View File

@@ -1,3 +0,0 @@
# Set per distribution debian tag
[DEFAULT]
debian-tag = debian/envole/%(version)s

8
debian/rules vendored
View File

@@ -1,8 +0,0 @@
#!/usr/bin/make -f
# -*- makefile -*-
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
%:
dh $@

View File

@@ -1 +0,0 @@
var/www/html

View File

@@ -1 +0,0 @@
usr/share/sso

View File

@@ -1 +0,0 @@
3.0 (native)

View File

@@ -6,7 +6,9 @@
<containers>
<container name='web'>
<!--
<package>schedule-apps</package>
-->
<!-- service de configuration apache -->
<service method="apache" servicelist="schedule">schedule</service>

View File

@@ -51,7 +51,10 @@
"preferred-install": {
"*": "dist"
},
"sort-packages": true
"sort-packages": true,
"allow-plugins": {
"symfony/flex": true
}
},
"autoload": {
"psr-4": {
@@ -72,6 +75,9 @@
"symfony/polyfill-php56": "*"
},
"scripts": {
"pre-install-cmd": [
"php scripts/checkcomposer.php"
],
"auto-scripts": {
"cache:clear": "symfony-cmd",
"cache:clear --env=prod": "symfony-cmd",

View File

@@ -0,0 +1,13 @@
<?php
$requiredVersion = 'version 1'; // La version interdite
$composerVersion = trim(shell_exec('COMPOSER_ALLOW_SUPERUSER=1 composer --version --no-ansi'));
echo $composerVersion."\n";
if (stripos($composerVersion,$requiredVersion)===false ) {
echo "La version de Composer $requiredVersion n'est pas autorisée" . PHP_EOL;
echo "Veuillez mettre à jour Composer avec 'composer self-update --1'." . PHP_EOL;
echo "Ou executez le scripts/reconfigure.sh" . PHP_EOL;
exit(1); // Quitte avec un code d'erreur
}

View File

@@ -6,12 +6,13 @@ cd /var/www/html/schedule
. scripts/proxy.sh
# Mise en place du fichier d'environnement model
if [ ! -f /var/www/html/schedule/.env ]; then
mv /var/www/html/schedule/scripts/.env.model /var/www/html/schedule/.env
fi
yes 2>/dev/null | cp /var/www/html/schedule/scripts/.env.model $DIR/.env
# Installation des dépendances composer
composer install
echo COMPOSER = Install
export COMPOSER_ALLOW_SUPERUSER=1
composer self-update --1 --quiet
composer install --quiet
php bin/console app:AppInit --env=prod
php bin/console app:CronInit --env=prod

View File

@@ -166,18 +166,19 @@ class ReportController extends AbstractController
$st=clone $breakday->getStart();
while($st<$breakday->getEnd()) {
$idday=$st->format("Ymd");
$tmp["events"][$idday]["allday"]=true;
$tmp["events"][$idday]["colorday"]="#6c7a89";
$tmp["events"][$idday]["descriptionday"]="Jour Férié";
$tmp["events"][$idday]["events"][-2000]["allday"]=true;
$tmp["events"][$idday]["events"][-2000]["colorday"]="#6c7a89";
$tmp["events"][$idday]["events"][-2000]["descriptionday"]="Jour Férié";
$st->add(new \DateInterval('P1D'));
}
}
array_push($tbevents,$tmp);
}
}
//dump($tbevents);
if($request->query->get('fgprint')) {
$render = $this->renderView('Report/synthese.html.twig',[
"useheader" => true,

View File

@@ -64,14 +64,10 @@ class RestController extends AbstractFOSRestController
}
// On formate le tableau de jour
$mini=new \Datetime('2022-03-07 00:00');
$start=new \Datetime('00:00');
$start->modify("monday this week");
$start=new \Datetime('2022-03-07 00:00');
$end=new \Datetime('00:00');
$end->modify("last day of this month");
$end->modify("next sunday");
$start->modify("previous month");
if($start<$mini) $start=clone $mini;
$events = $em
->createQueryBuilder('event')

View File

@@ -227,6 +227,20 @@
"phpdocumentor/type-resolver": {
"version": "1.1.0"
},
"phpunit/phpunit": {
"version": "8.5",
"recipe": {
"repo": "github.com/symfony/recipes",
"branch": "main",
"version": "4.7",
"ref": "db276258424d15e572d35a4eb834b8f815662b25"
},
"files": [
".env.test",
"phpunit.xml.dist",
"tests/bootstrap.php"
]
},
"psr/cache": {
"version": "1.0.1"
},