Loading README.md +1 −0 Original line number Diff line number Diff line # OSCAR 2.12 "Spartan" (Documentation technique) ### Version actuelle - **VERSION 2.12.1 "Spartan"** ([Note de version](doc/versions/version-2.12.1.md)) - **VERSION 2.12 "Spartan"** ([Note de version](doc/versions/version-2.12.md) / [Mise à jour technique](doc/upgrade-to-spartan.md) ) ### Version antérieurs Loading config/autoload/global.php +5 −0 Original line number Diff line number Diff line Loading @@ -187,6 +187,10 @@ return array( // TRUE => en heure 'declarationsHours' => false, // Force une ligne de déclaration pour les périodes où un projet // est identifié, mais n'a aucun créneau renseigné par le déclarant 'empty_project_require_validation' => false, 'declarationsWeekend' => false, 'declarationsWeekendOverwrite' => false, Loading Loading @@ -279,6 +283,7 @@ return array( // Emplacement du template pour les feuilles de temps individuelles mensuelles 'timesheet_person_month_template' => realpath(__DIR__.'/../../data/templates/timesheet_person_month.default.html.php'), 'timesheet_period_template' => realpath(__DIR__.'/../../data/templates/timesheet_period.default.html.php'), // Emplacement du template pour les feuilles de temps des synthèse des activités 'timesheet_activity_synthesis_template' => realpath(__DIR__.'/../../data/templates/timesheet_activity_synthesis.default.html.php'), Loading config/autoload/unicaen-app.local.php.dist +6 −17 Original line number Diff line number Diff line Loading @@ -8,6 +8,7 @@ $settings = array( */ 'ldap' => array( /////////////////////////////////////// ACCES au SERVEUR LDAP 'connection' => array( 'default' => array( 'params' => array( Loading @@ -21,6 +22,8 @@ $settings = array( ) ) ), /////////////////////////////////////// DOMAINES 'dn' => [ 'UTILISATEURS_BASE_DN' => 'ou=people,dc=unicaen,dc=fr', 'UTILISATEURS_DESACTIVES_BASE_DN' => 'ou=deactivated,dc=unicaen,dc=fr', Loading @@ -28,24 +31,10 @@ $settings = array( 'STRUCTURES_BASE_DN' => 'ou=structures,dc=unicaen,dc=fr', ], /////////////////////////////////////// FILTRES 'filters' => [ // AUthentification (identifiant de l'utilisateur) 'LOGIN_FILTER' => '(supannAliasLogin=%s)', 'UTILISATEUR_STD_FILTER' => '(|(uid=p*)(&(uid=e*)(eduPersonAffiliation=student)))', 'CN_FILTER' => '(cn=%s)', 'NAME_FILTER' => '(cn=%s*)', 'UID_FILTER' => '(uid=%s)', 'NO_INDIVIDU_FILTER' => '(supannEmpId=%08s)', 'AFFECTATION_FILTER' => '(&(uid=*)(eduPersonOrgUnitDN=%s))', 'AFFECTATION_CSTRUCT_FILTER' => '(&(uid=*)(|(ucbnSousStructure=%s;*)(supannAffectation=%s;*)))', 'LOGIN_OR_NAME_FILTER' => '(|(supannAliasLogin=%s)(cn=%s*))', 'MEMBERSHIP_FILTER' => '(memberOf=%s)', 'AFFECTATION_ORG_UNIT_FILTER' => '(eduPersonOrgUnitDN=%s)', 'AFFECTATION_ORG_UNIT_PRIMARY_FILTER' => '(eduPersonPrimaryOrgUnitDN=%s)', 'ROLE_FILTER' => '(supannRoleEntite=[role={SUPANN}%s][type={SUPANN}%s][code=%s]*)', 'PROF_STRUCTURE' => '(&(eduPersonAffiliation=teacher)(eduPersonOrgUnitDN=%s))', 'FILTER_STRUCTURE_DN' => '(%s)', 'FILTER_STRUCTURE_CODE_ENTITE' => '(supannCodeEntite=%s)', 'FILTER_STRUCTURE_CODE_ENTITE_PARENT' => '(supannCodeEntiteParent=%s)', ], /****/ ), Loading data/templates/common.css +1 −1 Original line number Diff line number Diff line Loading @@ -83,7 +83,7 @@ th { vertical-align: center; font-weight: normal; } .main { .main, .current { background: #97c6d6; } .research { Loading data/templates/timesheet_period.default.html.php 0 → 100644 +148 −0 Original line number Diff line number Diff line <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>Feuille de temps</title> <style> <?php include __DIR__.'/common.css'; ?> thead td, thead th, tbody { font-size: 1.2em; } tr { line-height: 1em; } thead tr, tfoot tr { line-height: 1.4em; } tfoot th { border-top: #333333 solid 1px; } td.none { color: rgba(0,0,0,.5); font-size: .8em; } td.valued { } .error { background: #e34242; color: white; } .error.none { background: #e34242; color: rgba(255,255,255,.5); } </style> </head> <?php $duration = function($value) { return $this->duration($value); }; $durationRounded = function( $duration ) { $roundStep = 5; $heures = floor($duration); $minutes = round(($duration - $heures)*60 / $roundStep)*$roundStep; if( $minutes < 10 ){ $minutes = '0'.$minutes; } return sprintf('%s:%s', $heures, $minutes); }; $renderDate = function( $str ){ setlocale(LC_ALL, 'fr_FR'); $date = new DateTime($str); return $date->format("F Y m d"); }; $lines = $facet == 'period' ? $by_periods : $by_persons; ?> <body> <header> <h1> Synthèse du temps pour l'activité <em><?= $activity['num'] ?></em> - <strong><?= $activity['label'] ?></strong> </h1> <h2> de <strong><?= $period_from_label ?></strong> à <strong><?= $period_to_label ?></strong> </h2> </header> <table> <thead> <tr> <th>Personne / périodes</th> <?php foreach ($headings['current']['workpackages'] as $wp): ?> <th class="project main research"><?= $wp['code'] ?></th> <?php endforeach; ?> <th class="project main research total">TOTAL</th> <?php foreach ($headings['prjs']['prjs'] as $prj): ?> <th class="project research"><?= $prj['label'] ?></th> <?php endforeach; ?> <?php foreach ($headings['others'] as $other): // On n'affiche pas la colonne "Invalid" si ça n'est pas utile if( $other['label'] == 'Invalid' && ($headings['has_invalid'] == false) ) continue; ?> <th class="<?= $other['group'] ?>"><?= $other['label'] ?></th> <?php endforeach; ?> <th class="total">TOTAL</th> </tr> </thead> <tbody> <?php foreach ($lines as $line): ?> <tr class="person"> <th><?= $line['label'] ?></th> <?php foreach ($line['datas']['current']['workpackages'] as $wp): ?> <td class="main research <?= $wp['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($wp['total']) ?> </td> <?php endforeach; ?> <td class="main research total <?= $line['datas']['current']['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($line['datas']['current']['total']) ?></td> <?php foreach ($line['datas']['prjs'] as $prj): ?> <td class="research <?= $prj['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($prj['total']) ?></td> <?php endforeach; ?> <?php foreach ($line['datas']['others'] as $other): // On n'affiche pas la colonne "Invalid" si ça n'est pas utile if( $other['label'] == 'Invalid' && ($headings['has_invalid'] == false) ) continue; ?> <td class="<?= $other['group'] ?> <?= $other['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($other['total']) ?></td> <?php endforeach; ?> <td class="total <?= $line['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($line['total']) ?></td> </tr> <?php endforeach; ?> </tbody> <tfoot> <th>TOTAUX</th> <?php foreach ($headings['current']['workpackages'] as $wp): ?> <th class="main research <?= $wp['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($wp['total']) ?></th> <?php endforeach; ?> <th class="main research total <?= $headings['current']['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($headings['current']['total']) ?></th> <?php foreach ($headings['prjs']['prjs'] as $prj): ?> <th class="research <?= $prj['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($prj['total']) ?></th> <?php endforeach; ?> <?php foreach ($headings['others'] as $other): // On n'affiche pas la colonne "Invalid" si ça n'est pas utile if( $other['label'] == 'Invalid' && ($headings['has_invalid'] == false) ) continue; ?> <th class="<?= $other['group'] ?> <?= $other['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($other['total']) ?></th> <?php endforeach; ?> <th class="total <?= $headings['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($headings['total']) ?></th> </tfoot> </table> </body> </html> No newline at end of file Loading
README.md +1 −0 Original line number Diff line number Diff line # OSCAR 2.12 "Spartan" (Documentation technique) ### Version actuelle - **VERSION 2.12.1 "Spartan"** ([Note de version](doc/versions/version-2.12.1.md)) - **VERSION 2.12 "Spartan"** ([Note de version](doc/versions/version-2.12.md) / [Mise à jour technique](doc/upgrade-to-spartan.md) ) ### Version antérieurs Loading
config/autoload/global.php +5 −0 Original line number Diff line number Diff line Loading @@ -187,6 +187,10 @@ return array( // TRUE => en heure 'declarationsHours' => false, // Force une ligne de déclaration pour les périodes où un projet // est identifié, mais n'a aucun créneau renseigné par le déclarant 'empty_project_require_validation' => false, 'declarationsWeekend' => false, 'declarationsWeekendOverwrite' => false, Loading Loading @@ -279,6 +283,7 @@ return array( // Emplacement du template pour les feuilles de temps individuelles mensuelles 'timesheet_person_month_template' => realpath(__DIR__.'/../../data/templates/timesheet_person_month.default.html.php'), 'timesheet_period_template' => realpath(__DIR__.'/../../data/templates/timesheet_period.default.html.php'), // Emplacement du template pour les feuilles de temps des synthèse des activités 'timesheet_activity_synthesis_template' => realpath(__DIR__.'/../../data/templates/timesheet_activity_synthesis.default.html.php'), Loading
config/autoload/unicaen-app.local.php.dist +6 −17 Original line number Diff line number Diff line Loading @@ -8,6 +8,7 @@ $settings = array( */ 'ldap' => array( /////////////////////////////////////// ACCES au SERVEUR LDAP 'connection' => array( 'default' => array( 'params' => array( Loading @@ -21,6 +22,8 @@ $settings = array( ) ) ), /////////////////////////////////////// DOMAINES 'dn' => [ 'UTILISATEURS_BASE_DN' => 'ou=people,dc=unicaen,dc=fr', 'UTILISATEURS_DESACTIVES_BASE_DN' => 'ou=deactivated,dc=unicaen,dc=fr', Loading @@ -28,24 +31,10 @@ $settings = array( 'STRUCTURES_BASE_DN' => 'ou=structures,dc=unicaen,dc=fr', ], /////////////////////////////////////// FILTRES 'filters' => [ // AUthentification (identifiant de l'utilisateur) 'LOGIN_FILTER' => '(supannAliasLogin=%s)', 'UTILISATEUR_STD_FILTER' => '(|(uid=p*)(&(uid=e*)(eduPersonAffiliation=student)))', 'CN_FILTER' => '(cn=%s)', 'NAME_FILTER' => '(cn=%s*)', 'UID_FILTER' => '(uid=%s)', 'NO_INDIVIDU_FILTER' => '(supannEmpId=%08s)', 'AFFECTATION_FILTER' => '(&(uid=*)(eduPersonOrgUnitDN=%s))', 'AFFECTATION_CSTRUCT_FILTER' => '(&(uid=*)(|(ucbnSousStructure=%s;*)(supannAffectation=%s;*)))', 'LOGIN_OR_NAME_FILTER' => '(|(supannAliasLogin=%s)(cn=%s*))', 'MEMBERSHIP_FILTER' => '(memberOf=%s)', 'AFFECTATION_ORG_UNIT_FILTER' => '(eduPersonOrgUnitDN=%s)', 'AFFECTATION_ORG_UNIT_PRIMARY_FILTER' => '(eduPersonPrimaryOrgUnitDN=%s)', 'ROLE_FILTER' => '(supannRoleEntite=[role={SUPANN}%s][type={SUPANN}%s][code=%s]*)', 'PROF_STRUCTURE' => '(&(eduPersonAffiliation=teacher)(eduPersonOrgUnitDN=%s))', 'FILTER_STRUCTURE_DN' => '(%s)', 'FILTER_STRUCTURE_CODE_ENTITE' => '(supannCodeEntite=%s)', 'FILTER_STRUCTURE_CODE_ENTITE_PARENT' => '(supannCodeEntiteParent=%s)', ], /****/ ), Loading
data/templates/common.css +1 −1 Original line number Diff line number Diff line Loading @@ -83,7 +83,7 @@ th { vertical-align: center; font-weight: normal; } .main { .main, .current { background: #97c6d6; } .research { Loading
data/templates/timesheet_period.default.html.php 0 → 100644 +148 −0 Original line number Diff line number Diff line <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>Feuille de temps</title> <style> <?php include __DIR__.'/common.css'; ?> thead td, thead th, tbody { font-size: 1.2em; } tr { line-height: 1em; } thead tr, tfoot tr { line-height: 1.4em; } tfoot th { border-top: #333333 solid 1px; } td.none { color: rgba(0,0,0,.5); font-size: .8em; } td.valued { } .error { background: #e34242; color: white; } .error.none { background: #e34242; color: rgba(255,255,255,.5); } </style> </head> <?php $duration = function($value) { return $this->duration($value); }; $durationRounded = function( $duration ) { $roundStep = 5; $heures = floor($duration); $minutes = round(($duration - $heures)*60 / $roundStep)*$roundStep; if( $minutes < 10 ){ $minutes = '0'.$minutes; } return sprintf('%s:%s', $heures, $minutes); }; $renderDate = function( $str ){ setlocale(LC_ALL, 'fr_FR'); $date = new DateTime($str); return $date->format("F Y m d"); }; $lines = $facet == 'period' ? $by_periods : $by_persons; ?> <body> <header> <h1> Synthèse du temps pour l'activité <em><?= $activity['num'] ?></em> - <strong><?= $activity['label'] ?></strong> </h1> <h2> de <strong><?= $period_from_label ?></strong> à <strong><?= $period_to_label ?></strong> </h2> </header> <table> <thead> <tr> <th>Personne / périodes</th> <?php foreach ($headings['current']['workpackages'] as $wp): ?> <th class="project main research"><?= $wp['code'] ?></th> <?php endforeach; ?> <th class="project main research total">TOTAL</th> <?php foreach ($headings['prjs']['prjs'] as $prj): ?> <th class="project research"><?= $prj['label'] ?></th> <?php endforeach; ?> <?php foreach ($headings['others'] as $other): // On n'affiche pas la colonne "Invalid" si ça n'est pas utile if( $other['label'] == 'Invalid' && ($headings['has_invalid'] == false) ) continue; ?> <th class="<?= $other['group'] ?>"><?= $other['label'] ?></th> <?php endforeach; ?> <th class="total">TOTAL</th> </tr> </thead> <tbody> <?php foreach ($lines as $line): ?> <tr class="person"> <th><?= $line['label'] ?></th> <?php foreach ($line['datas']['current']['workpackages'] as $wp): ?> <td class="main research <?= $wp['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($wp['total']) ?> </td> <?php endforeach; ?> <td class="main research total <?= $line['datas']['current']['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($line['datas']['current']['total']) ?></td> <?php foreach ($line['datas']['prjs'] as $prj): ?> <td class="research <?= $prj['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($prj['total']) ?></td> <?php endforeach; ?> <?php foreach ($line['datas']['others'] as $other): // On n'affiche pas la colonne "Invalid" si ça n'est pas utile if( $other['label'] == 'Invalid' && ($headings['has_invalid'] == false) ) continue; ?> <td class="<?= $other['group'] ?> <?= $other['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($other['total']) ?></td> <?php endforeach; ?> <td class="total <?= $line['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($line['total']) ?></td> </tr> <?php endforeach; ?> </tbody> <tfoot> <th>TOTAUX</th> <?php foreach ($headings['current']['workpackages'] as $wp): ?> <th class="main research <?= $wp['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($wp['total']) ?></th> <?php endforeach; ?> <th class="main research total <?= $headings['current']['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($headings['current']['total']) ?></th> <?php foreach ($headings['prjs']['prjs'] as $prj): ?> <th class="research <?= $prj['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($prj['total']) ?></th> <?php endforeach; ?> <?php foreach ($headings['others'] as $other): // On n'affiche pas la colonne "Invalid" si ça n'est pas utile if( $other['label'] == 'Invalid' && ($headings['has_invalid'] == false) ) continue; ?> <th class="<?= $other['group'] ?> <?= $other['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($other['total']) ?></th> <?php endforeach; ?> <th class="total <?= $headings['total'] == 0 ? 'none' : 'valued'?>"><?= $duration($headings['total']) ?></th> </tfoot> </table> </body> </html> No newline at end of file