59 Commits

Author SHA1 Message Date
4959a10857 Merge branch 'master' into dist/envole/6/master 2022-07-06 11:18:42 +02:00
d0d8183f7a ne plus concidèrer les profils scribe comme des groupes de travail 2022-07-06 11:11:59 +02:00
d42fdbfedd Merge branch 'master' into dist/envole/6/master 2022-05-10 09:32:08 +02:00
4f2fa1db4f Synchronisation scribe niveaux + eleves classes + profs classes (ref #34132) 2022-05-10 09:12:21 +02:00
75d935aa57 Synchronisation scribe niveaux + eleves classes + profs classes (ref #34132) 2022-05-09 13:51:33 +02:00
27e23fffaf ne pas afficher le clic sonde sur les app autogénérées par envole (fixes #33944) 2022-05-09 11:43:01 +02:00
70e2d49e7c Merge branch 'master' into dist/envole/6/master 2022-03-03 11:55:03 +01:00
df8bcfc1a1 ajout de l'item cdt et sa synchronisation poshprofil 2022-03-03 11:51:43 +01:00
666b90d513 Merge branch 'master' into dist/envole/6/master 2022-02-21 14:02:28 +01:00
2b86aa4e2f appel sonde sur click 2022-02-18 09:57:20 +01:00
cbae74f041 Merge branch 'master' into dist/envole/6/master 2022-02-04 13:34:04 +01:00
57f96132f4 mise en place jquerydate sur le formulaire des annonces (ref #33524) 2022-02-04 13:14:52 +01:00
ecbaed5c85 Merge branch 'master' into dist/envole/6/master 2022-02-04 11:33:43 +01:00
aac017c263 hauteur auto sur les images insérées dans les alertes (ref #33523) 2022-02-04 10:55:33 +01:00
e2d9380f65 Merge branch 'master' into dist/envole/6/master 2022-02-03 16:53:55 +01:00
21fc95f71e Merge branch 'master' into dist/envole/6/master 2022-02-03 16:49:54 +01:00
702d060503 optiomisation sur annonces lues / non lues cas annonces visiteur (ref #33746) 2022-02-03 16:34:44 +01:00
c6d349696e optiomisation sur annonces lues / non lues (ref #33746) 2022-02-03 16:30:40 +01:00
3818a38106 Merge branch 'master' into dist/envole/6/master 2021-12-08 11:33:34 +01:00
d0d933f28e dicos ajout service wssninegate 2021-12-08 11:16:56 +01:00
d155d5331f Merge branch 'master' into dist/envole/6/master 2021-12-08 09:39:19 +01:00
1249b7be21 ajout variable activer_revprox si non existante 2021-12-08 09:23:12 +01:00
f535e165ef Merge branch 'master' into dist/envole/6/master 2021-12-07 17:06:43 +01:00
6081e6a692 passer par un alias pour les websockets 2021-12-07 16:47:22 +01:00
fce9842064 Merge branch 'master' into dist/envole/6/master 2021-12-06 11:56:04 +01:00
01da55e6d6 gestion copier / coller des images dans les editeurs de texte (fixes #33465) 2021-12-06 11:40:02 +01:00
95e51c4d53 ne plus bloquer bundle edispatcher si masteridentity != SSO (fixes #33444) 2021-12-06 10:41:18 +01:00
9157b78671 user ldap reader si masteridentity != SQL 2021-12-03 11:44:34 +01:00
fec7eff6c5 Merge branch 'master' into dist/envole/6/master 2021-10-18 15:10:39 +02:00
e66f8999ed mise en forme de la zone username dans la barre de navigation (fixes #32780) 2021-10-18 14:29:41 +02:00
41915a0547 correction orthographe (fixes #33045) 2021-10-18 14:13:45 +02:00
c7586c86d5 ajout du titre de l'enregistrement dans le titre de la page modifiée (fixes #33046) 2021-10-18 14:08:53 +02:00
6a8e102fc6 modification style (fixes #33143) 2021-10-18 13:37:10 +02:00
e41093d3b9 Merge branch 'master' into dist/envole/6/master 2021-10-07 10:54:33 +02:00
eedaa86dcf rapatrier les variables eoledb dans la famille eoledb (ref #33188) 2021-10-07 10:52:59 +02:00
91d2febf2e Merge branch 'master' into dist/envole/6/master 2021-09-14 11:45:01 +02:00
1d448e70c7 autocreate user (fixes #33139) 2021-09-14 11:40:18 +02:00
0fc2346281 Merge branch 'master' into dist/envole/6/master 2021-08-27 10:59:48 +02:00
63c710c4fd correctif si groupe shared sans page 2021-08-27 10:02:15 +02:00
fbb5a4aca6 Merge branch 'master' into dist/envole/6/master 2021-07-20 10:21:52 +02:00
ac37691536 [THEME ACREUNION] mode reduit affichage username 2021-07-14 07:50:54 +04:00
13e5bfb428 [THEME ACREUNION] Adaptation des couleurs 2021-07-12 20:43:57 +04:00
98718ccc1e Merge branch 'master' into dist/envole/6/master 2021-07-12 16:35:55 +02:00
ed75b5f5c3 fixes #31884 , faire en sortes sur les urls soient compatibles https et http 2021-07-12 18:10:11 +04:00
5147a2b105 Merge branch 'master' into dist/envole/6/master 2021-07-12 15:51:41 +02:00
f361110766 Merge branch 'master' of https://dev-eole.ac-dijon.fr/git/ninegate 2021-07-12 15:48:34 +02:00
a5fbe134cc les alertes sans date de fin ne peuvent pas etre archivées (fixes #32914) 2021-07-12 15:47:57 +02:00
7dc7d708d3 [THEME ACREUNION] couleur du nom de l'utilisateur adapté au fond blanc du theme 2021-07-12 17:18:17 +04:00
9a260e6ae5 Merge branch 'master' into dist/envole/6/master 2021-07-12 12:49:59 +02:00
7ecfa45d75 mise en forme du bage item 2021-07-12 12:46:55 +02:00
7380823897 config typesso client ou proxy (fixes #32904) 2021-07-12 10:32:14 +02:00
8b794e8aa1 Merge branch 'master' into dist/envole/6/master 2021-07-05 14:41:20 +02:00
911bea2b5d correction orthographe (fixes #32829 2021-07-05 14:30:46 +02:00
13c24bd1ee ajout du param timerefreshnotif (fixes #32871) 2021-07-05 14:26:51 +02:00
fac25a036e passage en cas proxy pour imapunread 2021-07-05 14:09:54 +02:00
d61c2fc94d passage en cas proxy pour imapunread 2021-07-05 14:07:18 +02:00
f228f01c62 Merge branch 'master' into dist/envole/6/master 2021-07-05 10:47:55 +02:00
3e9e581116 prise en compte des usage dnma accueil 2021-07-05 10:44:59 +02:00
14283a731e correctif sur admin calendar 2021-06-30 09:29:31 +02:00
80 changed files with 861 additions and 338 deletions

View File

@ -2,6 +2,7 @@
<creole>
<files>
<file filelist='ninegate' name='/etc/eole/eole-db.d/ninegate-db.yml' rm='True' mkdir='True'/>
<file filelist='ninegate_nginx' name='/etc/nginx/web.d/ninegate.conf' source='ninegate-nginx.conf' rm='True' mkdir='True' />
</files>
<containers>
@ -9,26 +10,22 @@
<package>ninegate-apps</package>
<file filelist='ninegate' name='/etc/apache2/sites-available/ninegate' source='ninegate-apache.conf' rm="True"/>
<file filelist='ninegate' name='/lib/systemd/system/wssninegate.service' source='ninegate.service'/>
<file filelist="ninegate" name="/var/www/html/ninegate/app/config/parameters.yml" source="ninegate-parameters.yml" rm="True"/>
<file filelist="ninegate" name="/var/www/html/ninegate/app/config/template.yml" source="ninegate-template.yml" rm="True"/>
<file filelist="ninegate" name="/var/www/html/ninegate/scripts/ninegate-postservice-00.sh" source="ninegate-postservice-00.sh" rm="True" mode="700" />
<file filelist="ninegate" name="/var/www/html/ninegate/src/Cadoles/CoreBundle/Command/data/core-init-01.sql" source="ninegate-init-01.sql" rm="True"/>
<file filelist="ninegate" name="/var/www/html/ninegate/web/imap-unread.php" source="ninegate-unread.php" rm="True"/>
<file filelist='ninegate' name='/etc/cron.d/ninegate' source='ninegate.cron' rm='True'/>
<file filelist='ninegate-migration' name='/var/www/html/envole-migration/config/config-db-ninegate.php' source='ninegate-migration.php' mkdir='True'/>
<service method='apache' servicelist='ninegate'>ninegate</service>
<service_access service='ninegate_websocket'>
<port port_type="SymLinkOption">ninegate_websocket_portexterne</port>
</service_access>
<service servicelist="ninegate">wssninegate</service>
</container>
</containers>
<variables>
<family name='Ninegate'>
<family name='Ninegate' icon='home'>
<variable type='oui/non' name='activer_cadolesldap' description='Activer Annuaire Cadoles' hidden='True' exists='False'/>
<variable type='string' name='cadolesldap_pwdadmin' description="Mot de passe du compte admin durant l'instance" hidden='True' exists='False'/>
<variable type='string' name='cadolesldap_organization' description="Nom de l'organisation principale" hidden='True' exists='False'/>
@ -40,6 +37,7 @@
<variable name="ninegate_test_ninegate" type="oui/non" hidden='True' exists='False'><value>non</value></variable>
<variable name="activer_adminer" type="oui/non" description="Activer Adminer" hidden='True' exists='False'><value>non</value></variable>
<variable name="activer_balado" type="oui/non" description="Activer Balado" hidden='True' exists='False'><value>non</value></variable>
<variable name="activer_cdt" type="oui/non" description="Activer CdT" hidden='True' exists='False'><value>non</value></variable>
<variable name="activer_dokuwiki" type="oui/non" description="Activer Dokuwiki" hidden='True' exists='False'><value>non</value></variable>
<variable name="activer_econnect" type="oui/non" description="Activer eConnect" hidden='True' exists='False'><value>non</value></variable>
<variable name="activer_ead_web" type="oui/non" description="Activer EAD" hidden='True' exists='False'><value>non</value></variable>
@ -66,6 +64,7 @@
<variable name="activer_roundcube" type="oui/non" description="Activer Roundcube" hidden='True' exists='False'><value>non</value></variable>
<variable name="activer_sacoche" type="oui/non" description="Activer Sacoche" hidden='True' exists='False'><value>non</value></variable>
<variable name="activer_wordpress" type="oui/non" description="Activer Wordpress" hidden='True' exists='False'><value>non</value></variable>
<variable name="activer_revprox" type="oui/non" description="Activer le reverse proxy Nginx" hidden='True' exists='False'><value>non</value></variable>
<variable name="activer_sondepiwik_local" type="oui/non" description="Activer Sonde Piwik" hidden='True' exists='False'><value>non</value></variable>
@ -89,6 +88,7 @@
<variable type='string' name='ninegate_ssoreqgroup' description="Attribut SSO associé à la notion de groupe" mandatory='True'><value>user_groups</value></variable>
<variable type='oui/non' name='ninegate_ssosynchroitem' description="Associer automatiquement les items en fonction d'un attribut SSO"><value>non</value></variable>
<variable type='string' name='ninegate_ssoreqitem' description="Attribut SSO associé à la notion d'item" mandatory='True'><value></value></variable>
<variable type='string' name='ninegate_typesso' description="Mode de connexion SSO (Client ou Proxy)" mandatory='True'><value>client</value></variable>
<variable type='oui/non' name='ninegate_syncldap' description="Synchroniser Ninegate vers votre Annuaire CadolesLDAP"><value>non</value></variable>
<variable type='string' name='ninegate_ldaptemplate' description="Modèle d'annuaire"><value>scribe</value></variable>
@ -196,6 +196,13 @@
<variable type='string' name='ninegate_widbalado_url' description='URL complète de votre Balado' mandatory='True' />
<variable type='string' name='ninegate_widbalado_syncenvole' description='URL Posh-Profil pour synchronisation Balado' mandatory='True' />
<!-- CDT -->
<variable type="oui/non" name='ninegate_activate_widcdt' description='Activer CdT' mandatory='True'>
<value>non</value>
</variable>
<variable type='string' name='ninegate_widcdt_url' description='URL complète de votre CdT' mandatory='True' />
<variable type='string' name='ninegate_widcdt_syncenvole' description='URL Posh-Profil pour synchronisation CdT' mandatory='True' />
<!-- DOKUWIKI -->
<variable type="oui/non" name='ninegate_activate_widdokuwiki' description='Activer Dokuwiki' mandatory='True'>
<value>non</value>
@ -372,19 +379,6 @@
<variable type='string' name='ninegate_widwordpress_url' description='URL complète de votre Wordpress' mandatory='True' />
<variable type='string' name='ninegate_widwordpress_syncenvole' description='URL Posh-Profil pour synchronisation Wordpress' mandatory='True' />
<!-- WEBSOCKET -->
<variable type='string' name='ninegate_websocket_url' description='Host du serveur Websocket' mandatory='True' />
<variable type='string' name='ninegate_websocket_portexterne' description='Port de commuinication externe du serveur Websocket' mandatory='True' >
<value>5555</value>
</variable>
<variable type='string' name='ninegate_websocket_portinterne' description='Port de commuinication interne du serveur Websocket' mandatory='True'>
<value>5556</value>
</variable>
<!-- EMAIL -->
<variable type='string' name='ninegate_noreply' description='Adresse mail utilisé pour le noreply' mandatory='True' />
<variable type="oui/non" name='ninegate_activer_localmail' description="Utiliser le serveur d'envoi de mail local" mandatory='True'>
@ -396,9 +390,9 @@
<variable type='string' name='ninegate_smtppwd' description='Fichier contenant le mot de passe associé du compte SMTP' />
<variable type='string' name='ninegate_smtpencryption' description='Type Encryptage du serveur SMTP' />
<variable type='string' name='ninegate_smtpauthmode' description='Mode Authentification du serveur SMTP' />
</family>
<family name='EoleDB' icon='database' mode='expert'>
<!-- EOLEDB -->
<variable type='string' name='ninegate_db_mode' description='Serveur de bases de données à utiliser' mode='expert'/>
<variable type='string' name='ninegate_dbserver' description='Adresse du serveur de base de données' mode='expert'/>
@ -414,6 +408,7 @@
<separator name="ninegate_activate_portal">Paramètres associés aux modules à activer</separator>
<separator name="ninegate_activate_widadminer">Paramètres associés à Adminer</separator>
<separator name="ninegate_activate_widbalado">Paramètres associés à Balado</separator>
<separator name="ninegate_activate_widcdt">Paramètres associés à CdT</separator>
<separator name="ninegate_activate_widdokuwiki">Paramètres associés à Dokuwiki</separator>
<separator name="ninegate_activate_wideconnect">Paramètres associés à eConnect</separator>
<separator name="ninegate_activate_widead">Paramètres associés à EAD</separator>
@ -441,9 +436,9 @@
<separator name="ninegate_activate_widroundcube">Paramètres associés à Roundcube</separator>
<separator name="ninegate_activate_widsacoche">Paramètres associés à Sacoche</separator>
<separator name="ninegate_activate_widwordpress">Paramètres associés à Wordpress</separator>
<separator name="ninegate_websocket_url">Paramètres associés au Serveur WEBSOCKET</separator>
<separator name="ninegate_activate_websocket">Paramètres associés au Serveur WEBSOCKET</separator>
<separator name="ninegate_noreply">Paramètres associés aux Mails</separator>
<separator name="ninegate_db_mode">Paramètres associés à la Base de Données</separator>
<separator name="ninegate_db_mode">Paramètres EoleDB associés à Ninegate</separator>
</separators>
</variables>
@ -453,6 +448,11 @@
<target type='variable'>activer_ninegate</target>
</condition>
<condition name='hidden_if_in' source='activer_revprox'>
<param>non</param>
<target type='filelist'>nineboard_nginx</target>
</condition>
<condition name='hidden_if_in' source='activer_ninegate'>
<param>non</param>
@ -464,7 +464,8 @@
<target type='variable'>ninegate_ssoreqgroup</target>
<target type='variable'>ninegate_ssosynchroitem</target>
<target type='variable'>ninegate_ssoreqitem</target>
<target type='variable'>ninegate_typesso</target>
<target type='variable'>ninegate_syncldap</target>
<target type='variable'>ninegate_ldaptemplate</target>
<target type='variable'>ninegate_scribegroup</target>
@ -528,6 +529,7 @@
<target type='variable'>ninegate_dbpass</target>
<target type='filelist'>ninegate</target>
<target type='filelist'>ninegate_nginx</target>
<target type='filelist'>ninegate-migration</target>
<target type='servicelist'>ninegate</target>
@ -563,7 +565,15 @@
<target type='variable'>ninegate_ssosynchrogroup</target>
<target type='variable'>ninegate_ssoreqgroup</target>
<target type='variable'>ninegate_ssosynchroitem</target>
<target type='variable'>ninegate_ssoreqitem</target>
<target type='variable'>ninegate_ssoreqitem</target>
</condition>
<condition name='hidden_if_in' source='ninegate_mode_auth'>
<param>SQL</param>
<param>LDAP</param>
<param>SAML</param>
<target type='variable'>ninegate_typesso</target>
</condition>
<condition name='hidden_if_in' source='ninegate_syncldap'>
@ -715,6 +725,7 @@
<target type='variable'>ninegate_activate_widadminer</target>
<target type='variable'>ninegate_activate_widbalado</target>
<target type='variable'>ninegate_activate_widcdt</target>
<target type='variable'>ninegate_activate_widdokuwiki</target>
<target type='variable'>ninegate_activate_wideconnect</target>
<target type='variable'>ninegate_activate_widead</target>
@ -764,6 +775,7 @@
<param>non</param>
<target type='variable'>ninegate_widbalado_syncenvole</target>
<target type='variable'>ninegate_widcdt_syncenvole</target>
<target type='variable'>ninegate_widgepi_syncenvole</target>
<target type='variable'>ninegate_widlimesurvey_syncenvole</target>
<target type='variable'>ninegate_widmoodle_syncenvole</target>
@ -782,30 +794,12 @@
<condition name='hidden_if_in' source='poshprofil_typesynchro'>
<param>Annuaire</param>
<target type='variable'>ninegate_widbalado_syncenvole</target>
<target type='variable'>ninegate_widcdt_syncenvole</target>
<target type='variable'>ninegate_widgepi_syncenvole</target>
<target type='variable'>ninegate_widnextcloud_syncenvole</target>
<target type='variable'>ninegate_widsacoche_syncenvole</target>
</condition>
<!-- AFFICHAGE EN FONCTION DU MODULE WEBSOCKET -->
<condition name='hidden_if_in' source='ninegate_activate_websocket'>
<param>non</param>
<target type='variable'>ninegate_websocket_url</target>
<target type='variable'>ninegate_websocket_portinterne</target>
<target type='variable'>ninegate_websocket_portexterne</target>
<target type='servicelist'>ninegate_websocket</target>
</condition>
<fill name='calc_multi_condition' target='ninegate_websocket_url'>
<param>oui</param>
<param type='eole' name='condition_1' hidden='False'>activer_apache</param>
<param type='eole' name='match' hidden='False'>web_url</param>
<param name='default_mismatch'>None</param>
</fill>
<!-- AFFICHAGE EN FONCTION DU WIDGET ADMINER -->
<fill name='calc_multi_condition' target='ninegate_activate_widadminer'>
<param>oui</param>
@ -830,7 +824,7 @@
<!-- AFFICHAGE EN FONCTION DU WIDGET BALADAO -->
<!-- AFFICHAGE EN FONCTION DU WIDGET BALADO -->
<fill name='calc_multi_condition' target='ninegate_activate_widbalado'>
<param>oui</param>
<param type='eole' name='condition_1' hidden='False'>activer_balado</param>
@ -861,6 +855,39 @@
</fill>
<!-- AFFICHAGE EN FONCTION DU WIDGET CDT -->
<fill name='calc_multi_condition' target='ninegate_activate_widcdt'>
<param>oui</param>
<param type='eole' name='condition_1' hidden='False'>activer_cdt</param>
<param name='match'>oui</param>
<param name='mismatch'>non</param>
<param name='default_mismatch'>non</param>
</fill>
<condition name='hidden_if_in' source='ninegate_activate_widcdt'>
<param>non</param>
<target type='variable'>ninegate_widcdt_url</target>
<target type='variable'>ninegate_widcdt_syncenvole</target>
</condition>
<fill name='calc_multi_condition' target='ninegate_widcdt_url'>
<param>oui</param>
<param type='eole' name='condition_1' hidden='False'>activer_cdt</param>
<param name='match'>/cdt</param>
<param name='default_mismatch'>None</param>
</fill>
<fill name='calc_multi_condition' target='ninegate_widcdt_syncenvole'>
<param>oui</param>
<param type='eole' name='condition_1' hidden='False'>activer_cdt</param>
<param name='match'>/posh-profil</param>
<param name='default_mismatch'>None</param>
</fill>
<!-- AFFICHAGE EN FONCTION DU WIDGET DOKUWIKI -->
<fill name='calc_multi_condition' target='ninegate_activate_widdokuwiki'>
<param>oui</param>
@ -1637,6 +1664,10 @@
<param>['CAS', 'SAML', 'SQL', 'LDAP']</param>
</check>
<check name='valid_enum' target='ninegate_typesso'>
<param>['client', 'proxy']</param>
</check>
<check name='valid_enum' target='ninegate_moderegistration'>
<param>['none', 'byuser', 'byadmin']</param>
</check>

View File

@ -127,16 +127,16 @@ gos_web_socket:
firewall: main
shared_config: true
server:
port: %websocket_port% #The port the socket server will listen on
host: %websocket_host% #The host ip to bind to
port: 443 #The port the socket server will listen on
host: %weburl%/wssninegate #The host ip to bind to
router:
resources:
- "@CadolesWebsocketBundle/Resources/config/topic.yml"
pushers:
wamp:
host: %websocket_host%
port: %websocket_portinterne%
host: 0.0.0.0
port: 5556
# ckeditor configuration
ivory_ck_editor:
@ -147,7 +147,7 @@ ivory_ck_editor:
language: fr
toolbar: "my_toolbar_1"
uiColor: "#ffffff"
extraPlugins: ["html5video","pastebase64"]
extraPlugins: ["html5video"]
light_config:
language: fr
toolbar: "my_toolbar_2"

View File

@ -1,11 +1,9 @@
#!/bin/bash
websocket_url=$(CreoleGet adresse_ip_eth0 non)
websocket_portinterne=$(CreoleGet ninegate_websocket_portinterne non)
# Server Websocket
if [[ "$1" != "restartifdown" ]]; then
echo WEBSOCKET = STOP
pid="$(pgrep -a -f gos:websocket | grep $websocket_portinterne)"
pid="$(pgrep -a -f gos:websocket | grep 5556)"
if [ -n "${pid}" ]; then
IFS=' ' read -r -a array <<< "$pid"
kill -9 ${array[0]};
@ -13,7 +11,7 @@ if [[ "$1" != "restartifdown" ]]; then
fi
# Port LISTEN ?
pid="$(pgrep -a -f gos:websocket | grep $websocket_portinterne)"
pid="$(pgrep -a -f gos:websocket | grep 5556)"
restart="yes"
if [ "$1" == "restartifdown" ] && [ -n "${pid}" ] ; then
restart="no"
@ -22,5 +20,5 @@ fi
if [ "$restart" == "yes" ] && [ "$1" != "stop" ] ; then
echo WEBSOCKET = START
cd /var/www/html/ninegate
bin/console gos:websocket:server --port $websocket_portinterne -a $websocket_url --no-debug -n -q --env=prod & disown
systemctl restart wssninegate
fi

View File

@ -30,7 +30,10 @@ class SecurityController extends Controller
// Init Client CAS
\phpCAS::setDebug("/var/log/phpcas/phpCAS-ninegate.log");
@\phpCAS::client(CAS_VERSION_2_0, $this->getParameter('cas_host'), $this->getParameter('cas_port'), is_null($this->getParameter('cas_path')) ? '' : $this->getParameter('cas_path'), false);
if($this->getParameter("cas_type")=="client")
@\phpCAS::client(CAS_VERSION_2_0, $this->getParameter('cas_host'), $this->getParameter('cas_port'), is_null($this->getParameter('cas_path')) ? '' : $this->getParameter('cas_path'), false);
else
@\phpCAS::proxy(CAS_VERSION_2_0, $this->getParameter('cas_host'), $this->getParameter('cas_port'), is_null($this->getParameter('cas_path')) ? '' : $this->getParameter('cas_path'), false);
\phpCAS::setNoCasServerValidation();
@ -75,7 +78,9 @@ class SecurityController extends Controller
if($masteridentity=="LDAP") {
// Normalement la synchronisation des comptes aurait du générer le compte en base c'est donc pas normal
// Peut-être juste relancer une synchronisation
throw $this->createNotFoundException('Permission denied. Need to synchronize LDAP ? Contact your administrator');
// On tente une synchronisation via methode SSO
$masteridentity="SSO";
// throw $this->createNotFoundException('Permission denied. Need to synchronize LDAP ? Contact your administrator');
}
if($masteridentity=="SSO") {
@ -86,8 +91,10 @@ class SecurityController extends Controller
// On calcule le niveau01 de l'utilisateur
$niveau01=$em->getRepository('CadolesCoreBundle:Niveau01')->calculateNiveau01($attributes);
if(!$niveau01)
throw $this->createNotFoundException('Permission denied. No Organisation Niveau 01 match');
if(!$niveau01) {
$niveau01=$em->getRepository('CadolesCoreBundle:Niveau01')->findAll()[0];
//throw $this->createNotFoundException('Permission denied. No Organisation Niveau 01 match');
}
$user->setUsername($username);
$user->setEmail($email);
@ -195,7 +202,10 @@ class SecurityController extends Controller
public function logoutAction() {
// Init Client CAS
\phpCAS::setDebug(false);
@\phpCAS::client(CAS_VERSION_2_0, $this->getParameter('cas_host'), $this->getParameter('cas_port'), is_null($this->getParameter('cas_path')) ? '' : $this->getParameter('cas_path'), true);
if($this->getParameter("cas_type")=="client")
@\phpCAS::client(CAS_VERSION_2_0, $this->getParameter('cas_host'), $this->getParameter('cas_port'), is_null($this->getParameter('cas_path')) ? '' : $this->getParameter('cas_path'), true);
else
@\phpCAS::proxy(CAS_VERSION_2_0, $this->getParameter('cas_host'), $this->getParameter('cas_port'), is_null($this->getParameter('cas_path')) ? '' : $this->getParameter('cas_path'), true);
\phpCAS::setNoCasServerValidation();
@ -209,7 +219,10 @@ class SecurityController extends Controller
// Init Client CAS
\phpCAS::setDebug("/var/log/phpcas/phpCAS-ninegate.log");
@\phpCAS::client(CAS_VERSION_2_0, $this->getParameter('cas_host'), $this->getParameter('cas_port'), is_null($this->getParameter('cas_path')) ? '' : $this->getParameter('cas_path'), false);
if($this->getParameter("cas_type")=="client")
@\phpCAS::client(CAS_VERSION_2_0, $this->getParameter('cas_host'), $this->getParameter('cas_port'), is_null($this->getParameter('cas_path')) ? '' : $this->getParameter('cas_path'), false);
else
@\phpCAS::proxy(CAS_VERSION_2_0, $this->getParameter('cas_host'), $this->getParameter('cas_port'), is_null($this->getParameter('cas_path')) ? '' : $this->getParameter('cas_path'), false);
\phpCAS::setNoCasServerValidation();
@ -295,4 +308,29 @@ class SecurityController extends Controller
}
}
function imapunreadAction() {
if($this->getParameter("active_imapunread")&&$this->getParameter("cas_type")=="proxy") {
$ip=$this->getParameter("imapundread_ip");
// Init Client CAS
\phpCAS::setDebug("/var/log/phpcas/phpCAS-ninegate.log");
@\phpCAS::proxy(CAS_VERSION_2_0, $this->getParameter('cas_host'), $this->getParameter('cas_port'), is_null($this->getParameter('cas_path')) ? '' : $this->getParameter('cas_path'), false);
\phpCAS::setNoCasServerValidation();
\phpCAS::forceAuthentication();
$pt= \phpCAS::retrievePT('imap://'.$ip,$t,$f);
$a = \phpCAS::serviceMail("{".$ip.":993/imap/ssl/novalidate-cert}","imap://".$ip,0, $errc,$err,$pt);
$unseen = imap_status($a, "{".$ip.":993/imap/ssl/novalidate-cert}INBOX", SA_UNSEEN);
$count=$unseen->unseen;
$response = new Response(json_encode($count));
}
else
$response = new Response(json_encode(""));
$response->headers->set('Content-Type', 'application/json');
return $response;
}
}

View File

@ -10,3 +10,7 @@ cas_sp.test:
path: /test
defaults: { _controller: CadolesCASBundle:Security:test }
cas_sp.imapunread:
path: /imapunread
defaults: { _controller: CadolesCASBundle:Security:imapunread }

View File

@ -228,9 +228,17 @@ class InitDataCommand extends ContainerAwareCommand
$this->addModeration($profil,'cadoles_portal_config_flux',1);
$this->addModeration($profil,'cadoles_portal_config_notice',1);
$this->addModeration($profil,'cadoles_portal_config_icon',1);
$this->addModeration($profil,'cadoles_portal_config_syncbalado',0);
$this->addModeration($profil,'cadoles_portal_config_synccdt',0);
$this->addModeration($profil,'cadoles_portal_config_syncgepiannu',0);
$this->addModeration($profil,'cadoles_portal_config_syncgepisiecle',0);
$this->addModeration($profil,'cadoles_portal_config_synclimesurvey',0);
$this->addModeration($profil,'cadoles_portal_config_syncmoodle',0);
$this->addModeration($profil,'cadoles_portal_config_syncnextcloud',0);
$this->addModeration($profil,'cadoles_portal_config_syncsacoche',0);
$this->addModeration($profil,'cadoles_portal_config_syncpiwik',0);
$this->addModeration($profil,'cadoles_portal_config_syncwordpress',0);
$this->addModeration($profil,'cadoles_core_config_statistic',1);
$this->addModeration($profil,'cadoles_core_config_mailing',1);
$this->addModeration($profil,'cadoles_core_config_importuser',0);

View File

@ -380,6 +380,46 @@ class PurgeFileCommand extends Command
if($result) $find=true;
}
// Si pas trouvé on la cherche dans les projecttask
if(!$find) {
$result = $this->em
->getRepository("CadolesPortalBundle:Projecttask")->createQueryBuilder('projecttask')
->where('projecttask.description LIKE :tofind')
->setParameter('tofind', '%'.$tofind.'%')
->getQuery()->getResult();
if($result) $find=true;
}
// Si pas trouvé on la cherche dans les projectcomment
if(!$find) {
$result = $this->em
->getRepository("CadolesPortalBundle:Projectcomment")->createQueryBuilder('projectcomment')
->where('projectcomment.description LIKE :tofind')
->setParameter('tofind', '%'.$tofind.'%')
->getQuery()->getResult();
if($result) $find=true;
}
// Si pas trouvé on la cherche dans les blogcomment
if(!$find) {
$result = $this->em
->getRepository("CadolesPortalBundle:Blogcomment")->createQueryBuilder('blogcomment')
->where('blogcomment.description LIKE :tofind')
->setParameter('tofind', '%'.$tofind.'%')
->getQuery()->getResult();
if($result) $find=true;
}
// Si pas trouvé on la cherche dans les alert
if(!$find) {
$result = $this->em
->getRepository("CadolesPortalBundle:Alert")->createQueryBuilder('alert')
->where('alert.content LIKE :tofind')
->setParameter('tofind', '%'.$tofind.'%')
->getQuery()->getResult();
if($result) $find=true;
}
// Si pas trouvé on supprime
if(!$find) {
$this->writeln($name);

View File

@ -168,6 +168,32 @@ class ScriptCommand extends Command
$this->writeln("");
}
$script=$this->em->getRepository("CadolesCoreBundle:Script")->findOneBy(["name"=>"updateorthographe02"]);
if(!$script) {
$this->writeln("== SCRIPT = updateorthographe02");
$this->updateorthographe02();
$script=new Script();
$script->setName("updateorthographe02");
$this->em->persist($script);
$this->em->flush();
$this->writeln("");
}
if($this->container->getParameter('ldap_template')=="scribe") {
$script=$this->em->getRepository("CadolesCoreBundle:Script")->findOneBy(["name"=>"purgepageprofil"]);
if(!$script) {
$this->writeln("== SCRIPT = purgepageprofil");
$this->purgepageprofil();
$script=new Script();
$script->setName("purgepageprofil");
$this->em->persist($script);
$this->em->flush();
$this->writeln("");
}
}
return 1;
}
@ -410,6 +436,31 @@ class ScriptCommand extends Command
}
}
private function updateorthographe02(){
$entityItem = $this->em->getRepository('CadolesPortalBundle:Item')->find(-398);
if($entityItem) {
if($entityItem->getSubtitle()!="Messagerie") {
$entityItem->setSubtitle("Messagerie");
$entityItem->setContent("Messagerie permettant la communication sécurisée par méls. La messagerie na pas pour but denvoyer des gros fichiers mais plutôt de communiquer des informations, des liens.");
$this->em->persist($entityItem);
$this->em->flush();
}
}
}
private function purgepageprofil() {
$page=$this->em->getRepository('CadolesPortalBundle:Page')->findOneBy(['name'=>'PROFIL - Enseignants']);
if($page) {
$this->em->remove($page);
$this->em->flush();
}
$page=$this->em->getRepository('CadolesPortalBundle:Page')->findOneBy(['name'=>'PROFIL - Administratifs']);
if($page) {
$this->em->remove($page);
$this->em->flush();
}
}

View File

@ -128,7 +128,7 @@ class SynchroCommand extends Command
$ldapfilter="(|(&(uid=*)(ENTPersonProfils=enseignant))(&(uid=*)(typeadmin=0))(&(uid=*)(typeadmin=2)))";
$label="PROFIL - Enseignants";
$this->writeln(" - $label");
if(!$simulate) $this->addmodGroup($label,$ldapfilter,$scribe_group);
if(!$simulate) $this->addmodGroup($label,$ldapfilter,false);
// Responsables
$ldapfilter="(&(uid=*)(ENTPersonProfils=responsable))";
@ -140,7 +140,20 @@ class SynchroCommand extends Command
$ldapfilter="(&(uid=*)(ENTPersonProfils=administratif))";
$label="PROFIL - Administratifs";
$this->writeln(" - $label");
if(!$simulate) $this->addmodGroup($label,$ldapfilter,$scribe_group);
if(!$simulate) $this->addmodGroup($label,$ldapfilter,false);
// Niveaux
$this->writeln('');
$this->writeln('== NIVEAUX ==========================================');
$results = $this->ldap->search("type=Niveau", ['cn','description','gidNumber'], $this->ldap_basedn);
foreach($results as $result) {
$cn=$result["cn"];
$ldapfilter="(&(type=Niveau)(cn=$cn))";
$label="NIVEAU - ".$result["cn"];
$this->writeln(" - $label");
if(!$simulate) $this->addmodGroup($label,$ldapfilter,false);
}
// Classes
$this->writeln('');
@ -155,6 +168,32 @@ class SynchroCommand extends Command
if(!$simulate) $this->addmodGroup($label,$ldapfilter,$scribe_group);
}
// Elèves des Classes
$this->writeln('');
$this->writeln('== ELEVES DES CLASSES ==========================================');
$results = $this->ldap->search("type=Classe", ['cn','description','gidNumber'], $this->ldap_basedn);
foreach($results as $result) {
$cn=$result["cn"];
$ldapfilter="(&(type=Classe)(cn=$cn))";
$label="ELEVES - ".$result["cn"];
$this->writeln(" - $label");
if(!$simulate) $this->addmodGroup($label,$ldapfilter,false);
}
// Professeurs des Classes
$this->writeln('');
$this->writeln('== PROFESSEURS DES CLASSES ==========================================');
$results = $this->ldap->search("type=Classe", ['cn','description','gidNumber'], $this->ldap_basedn);
foreach($results as $result) {
$cn=$result["cn"];
$ldapfilter="(|(&(type=Equipe)(cn=profs-$cn))(&(ENTPersonProfils=Administratif)(divcod=$cn)))";
$label="PROFESSEURS - ".$result["cn"];
$this->writeln(" - $label");
if(!$simulate) $this->addmodGroup($label,$ldapfilter,false);
}
// Options
$this->writeln('');
$this->writeln('== OPTIONS ==========================================');

View File

@ -331,8 +331,15 @@ class PermmodoprofilController extends Controller
$this->addModeration($profil,'cadoles_portal_config_flux',1);
$this->addModeration($profil,'cadoles_portal_config_notice',1);
$this->addModeration($profil,'cadoles_portal_config_icon',1);
$this->addModeration($profil,'cadoles_portal_config_syncbalado',0);
$this->addModeration($profil,'cadoles_portal_config_synccdt',0);
$this->addModeration($profil,'cadoles_portal_config_syncgepiannu',0);
$this->addModeration($profil,'cadoles_portal_config_syncgepisiecle',0);
$this->addModeration($profil,'cadoles_portal_config_synclimesurvey',0);
$this->addModeration($profil,'cadoles_portal_config_syncmoodle',0);
$this->addModeration($profil,'cadoles_portal_config_syncnextcloud',0);
$this->addModeration($profil,'cadoles_portal_config_syncsacoche',0);
$this->addModeration($profil,'cadoles_portal_config_syncpiwik',0);
$this->addModeration($profil,'cadoles_portal_config_syncwordpress',0);
$this->addModeration($profil,'cadoles_core_config_statistic',1);
$this->addModeration($profil,'cadoles_core_config_mailing',1);

View File

@ -46,6 +46,7 @@ class SondeController extends Controller
elseif($route=="cadoles_portal_user_page_view") {
if($usage=="group") $usagesonde="collaboratif";
elseif($usage=="user") $usagesonde="collaboratif";
elseif($usage=="accueil") $usagesonde="accueil";
else $usagesonde="portail";
}
elseif(stripos($route,"cadoles_portal_user_calendar")!==false)

View File

@ -13,12 +13,15 @@
class sessionListener {
protected $container;
protected $em;
protected $token_storage;
protected $session;
public function __construct($container, EntityManager $em, TokenStorageInterface $token_storage)
public function __construct($container, EntityManager $em, TokenStorageInterface $token_storage,Session $session)
{
$this->container = $container;
$this->em = $em;
$this->token_storage = $token_storage;
$this->session = $session;
}
public function haveRole($curentuser,$roles,$tohave,$route) {
@ -44,7 +47,7 @@
}
public function onDomainParse(Event $event) {
$session = new Session();
$session = $this->session;
$configs = $this->em->getRepository("CadolesCoreBundle:Config")->findAll();
foreach($configs as $config) {
@ -91,6 +94,7 @@
$app["activate_widwordpress"] =$this->container->getParameter('activate_widwordpress');
$app["widbalado_activate_syncenvole"] =$this->container->getParameter('widbalado_activate_syncenvole');
$app["widcdt_activate_syncenvole"] =$this->container->getParameter('widcdt_activate_syncenvole');
$app["widgepi_activate_syncenvole"] =$this->container->getParameter('widgepi_activate_syncenvole');
$app["widnextcloud_activate_syncenvole"] =$this->container->getParameter('widnextcloud_activate_syncenvole');
$app["widpiwik_activate_syncenvole"] =$this->container->getParameter('widpiwik_activate_syncenvole');

View File

@ -52,7 +52,7 @@ class MailType extends AbstractType
'mapped'=> false,
'required' => false,
'attr' => array("class" => "form-control", "style" => "margin-bottom:15px"),
'config' => ["height" => "150px",'filebrowserUploadRoute' => 'cadoles_portal_user_pagewidget_upload']
'config' => ["height" => "150px"]
]);
}

View File

@ -99,7 +99,7 @@ class MailingType extends AbstractType
'mapped'=> false,
'required' => true,
'attr' => array("class" => "form-control", "style" => "margin-bottom:15px"),
'config' => ["height" => "400px",'filebrowserUploadRoute' => 'cadoles_portal_user_pagewidget_upload']
'config' => ["height" => "400px"]
]);
}

View File

@ -26,7 +26,7 @@ services:
cadoles.core.session.listener:
public: true
class: Cadoles\CoreBundle\EventListener\sessionListener
arguments: ['@service_container','@doctrine.orm.entity_manager',"@security.token_storage"]
arguments: ['@service_container','@doctrine.orm.entity_manager',"@security.token_storage","@session"]
tags:
- { name: kernel.event_listener, event: kernel.request, method: onDomainParse }

View File

@ -60,6 +60,17 @@ body {
height: 20px;
}
@media (max-width: 991px) {
.header .title{
font-size: 30px;
}
.header small {
font-size:14px;
top: 25px;
}
}
@media (max-width: 767px) {
.header { display: none }
#menu-header { display: none }
@ -116,6 +127,19 @@ body {
right: 30px;
}
.navbar-top-links #navbar-nameuser {
position: relative;
top: -8px;
right: inherit;
}
@media (max-width: 991px) {
.navbar-top-links #navbar-nameuser {
display: none;
}
}
@media (max-width: 767px) {
.navbar-default .navbar-header #title {
display: none;
@ -741,6 +765,11 @@ a.item-heart {
max-width: 100%;
}
.widget-ckeditor img {
height:auto !important;
}
.frameitem {
position: absolute;
right: 0px;

View File

@ -49,6 +49,12 @@
.header.reduit .avatar {height: 25px; }
.header.reduit #navbar-nameuser
{
top: 14px;
right: 210px;
}
/* ===================== FIN MODE REDUIT ==========================*/
/* fix defaut d'affichage sur toogle switch */
@ -57,7 +63,11 @@ body {
background: linear-gradient(180deg, var(--main), white,50%);
}
body.eleves, body.grp-National_1 {
#navbar-nameuser a {
color: var(--main, #004d9a) !important;
}
body.eleves, body.grp-National_1, body.grp-eleves {
--colorbody: #ffffff;
--main: #169b62;
--mainR: 22;
@ -77,7 +87,7 @@ body.eleves, body.grp-National_1 {
/* responsables #MAUVE #7D4E5B
*/
body.responsables, body.grp-National_2 {
body.responsables, body.grp-National_2,body.grp-responsables {
--colorbody: #ffffff;
--main: #7d4e5b;
--mainR: 125;
@ -96,7 +106,7 @@ body.responsables, body.grp-National_2 {
/* professeurs, enseignants1d #BLEU1 #5770BE */
body.professeurs, body.enseignants1d, body.grp-National_3 {
body.professeurs, body.enseignants1d, body.grp-National_3, body.grp-professeurs {
--colorbody: #ffffff;
--main: #5770be;
--mainR: 87;
@ -114,7 +124,7 @@ body.professeurs, body.enseignants1d, body.grp-National_3 {
}
/* administratifs, admin #ORANGE #FF6F4C */
body.administratifs, body.admin, body.grp-National_4 , body.grp-National_5, body.grp-National_6 {
body.administratifs, body.admin, body.grp-National_4 , body.grp-National_5, body.grp-National_6 , body.grp-administratifs, {
--colorbody: #ffffff;
--main: #ff6f4c;
--mainR: 255;
@ -278,7 +288,9 @@ div.header > a.title > span {
}
.nav.navbar-top-links.navbar-right > li a:hover {
color: var(--fontcolorhover, white) !important;
background: var(--fontcolorhoverdark, black) !important;
background: var(--light, black) !important;
border-radius: 5px;
padding-top: 1px;
}
/*

View File

@ -2,7 +2,7 @@
{% block pagewrapper %}
{{ form_start(form) }}
<h1 class="page-header">Modification Configuration Générale</h1>
<h1 class="page-header">Modification Configuration Générale = {{config.id}}</h1>
{{ form_widget(form.submit) }} <a class="btn btn-default" href={{ path('cadoles_core_config_commun') }}>Annuler</a>

View File

@ -4,11 +4,11 @@
{{ form_start(form) }}
<h1 class="page-header">
{% if mode=="update" %}
Modification Groupe
Modification Groupe = {{ group.label }}
{% elseif mode=="submit" %}
Création Groupe
{% elseif mode=="delete" %}
Suppression Groupe
Suppression Groupe = {{ group.label }}
{% endif %}
</h1>

View File

@ -6,9 +6,9 @@
{% set permannu = app.session.get('permannu') %}
{% if fgheader %}
<li id="menu-header"><a onclick="switchHeader()" title="Cacher / Affichier Bannière " style="cursor:pointer"><i class="fa fa-chevron-up fa-fw"></i></a>
<li id="menu-header"><a onclick="switchHeader()" title="Cacher / Afficher Bannière " style="cursor:pointer"><i class="fa fa-chevron-up fa-fw"></i></a>
{% else %}
<li id="menu-header"><a onclick="switchHeader()" title="Cacher / Affichier Bannière " style="cursor:pointer"><i class="fa fa-chevron-down fa-fw"></i></a>
<li id="menu-header"><a onclick="switchHeader()" title="Cacher / Afficher Bannière " style="cursor:pointer"><i class="fa fa-chevron-down fa-fw"></i></a>
{% endif %}
{% if is_granted('ROLE_ADMIN') or (is_granted('ROLE_MODO') and (permannu=="ROLE_MODO" or permannu=="ROLE_ANIM" or permannu=="ROLE_USER")) or (is_granted('ROLE_ANIM') and (permannu=="ROLE_ANIM" or permannu=="ROLE_USER")) or (is_granted('ROLE_USER') and permannu=="ROLE_USER") %}

View File

@ -4,11 +4,11 @@
{{ form_start(form) }}
<h1 class="page-header">
{% if mode=="update" %}
Modification {{ labelniveau01 }}
Modification {{ labelniveau01 }} = {{niveau01.label}}
{% elseif mode=="submit" %}
Création {{ labelniveau01 }}
{% elseif mode=="delete" %}
Suppression {{ labelniveau01 }}
Suppression {{ labelniveau01 }} = {{niveau01.label}}
{% endif %}
</h1>

View File

@ -4,11 +4,11 @@
{{ form_start(form) }}
<h1 class="page-header">
{% if mode=="update" %}
Modification {{ labelniveau02 }}
Modification {{ labelniveau02 }} = {{niveau02.label}}
{% elseif mode=="submit" %}
Création {{ labelniveau02 }}
{% elseif mode=="delete" %}
Suppression {{ labelniveau02 }}
Suppression {{ labelniveau02 }} = {{niveau02.label}}
{% endif %}
</h1>

View File

@ -4,11 +4,11 @@
{{ form_start(form) }}
<h1 class="page-header">
{% if mode=="update" %}
Modification Profil de Modération
Modification Profil de Modération = {{ permmodoprofil.name }}
{% elseif mode=="submit" %}
Création Profil de Modération
{% elseif mode=="delete" %}
Suppression Profil de Modération
Suppression Profil de Modération = {{ permmodoprofil.name }}
{% endif %}
</h1>

View File

@ -5,11 +5,11 @@
{% if moderegistration!="none" %}
<h1 class="page-header">
{% if mode=="send" %}
Confirmation à l'Utilisateur
Confirmation à l'Utilisateur = {{ registration.username }}
{% elseif mode=="submit" %}
Inscription
{% elseif mode=="delete" %}
Suppression Inscription
Suppression Inscription = {{ registration.username }}
{% endif %}
</h1>

View File

@ -5,7 +5,7 @@
<h1 class="page-header">
{% if mode=="update" %}
{% if access=="config" %}
Modification Utilisateur
Modification Utilisateur = {{ user.username}}
{% else %}
Profil
{% endif %}

View File

@ -4,11 +4,11 @@
{{ form_start(form) }}
<h1 class="page-header">
{% if mode=="update" %}
Modification Liste Blanche
Modification Liste Blanche = {{ whitelist.label }}
{% elseif mode=="submit" %}
Création Liste Blanche
{% elseif mode=="delete" %}
Suppression Liste Blanche
Suppression Liste Blanche = {{ whitelist.label }}
{% endif %}
</h1>

View File

@ -110,6 +110,9 @@
</div>
<ul class="nav navbar-top-links navbar-right">
{% if app.user %}
<a id="navbar-nameuser" href="{{ path('cadoles_core_user') }}" title="Profil">{{ app.user.firstname }} {{ app.user.lastname }}</a>
{% endif %}
{% if mustread is not defined %}
{{ include('@CadolesCore/Include/menu.html.twig') }}
{% endif %}

View File

@ -200,7 +200,8 @@ class ApiController extends Controller
$bookmarks=null;
$items=null;
$itemcategorys=null;
$weburl="https://".$this->getParameter("weburl")."/".$this->getParameter("alias")."/";
# fixe #31884 "https://" => "//"
$weburl="//".$this->getParameter("weburl")."/".$this->getParameter("alias")."/";
$em->getRepository("CadolesPortalBundle:Item")->getUserItems($user,$bookmarks,$items,$itemcategorys,null,$ssoitems,3);
@ -673,10 +674,10 @@ $api('$id',data);";
}
public function sessionAction($id="",$access="config") {
// Masteridentity
$masteridentity=$this->getParameter("masteridentity");
if($masteridentity!="SSO") {
$output["error"]="Le bundle Edispatcher ne fonctionne qu'en mode MasterIdentity=SSO";
// mode_auth
$mode_auth=$this->getParameter("mode_auth");
if($mode_auth!="CAS") {
$output["error"]="Le bundle Edispatcher ne fonctionne qu'en mode mode_auth=CAS";
return new Response(json_encode($output), 400);
}

View File

@ -12,6 +12,10 @@ div.header {
position: relative !important;
}
#navbar-nameuser a {
color: var(--main, #004d9a) !important;
}
div.header > a > span {
color: black !important;
}

View File

@ -43,6 +43,7 @@ class InitDataCommand extends ContainerAwareCommand
$activate_widadminer = $this->getContainer()->getParameter('activate_widadminer');
$activate_widbalado = $this->getContainer()->getParameter('activate_widbalado');
$activate_widcdt = $this->getContainer()->getParameter('activate_widcdt');
$activate_widdokuwiki = $this->getContainer()->getParameter('activate_widdokuwiki');
$activate_wideconnect = $this->getContainer()->getParameter('activate_wideconnect');
$activate_widead = $this->getContainer()->getParameter('activate_widead');
@ -414,6 +415,29 @@ class InitDataCommand extends ContainerAwareCommand
$em->persist($entityItem);
}
// Item CdT
if($activate_widcdt) {
$widcdt_url =$this->getContainer()->getParameter('widcdt_url');
$entityItem = $em->getRepository('CadolesPortalBundle:Item')->find(-391);
if(!$entityItem) {
$entityicon = $em->getRepository('CadolesPortalBundle:Icon')->findoneby(["label"=>"uploads/icon/icon_cdt.png"]);
$entityItem = new Item();
$entityItem->setId(-391);
$entityItem->setRowOrder(0);
$entityItem->setTitle('CdT');
$entityItem->setSubtitle("Application complète de gestion de cahier de texte scolaire");
$entityItem->SetContent("Application complète de gestion de cahier de texte scolaire");
$entityItem->setIcon($entityicon);
$entityItem->setTarget("_blank");
$entityItem->setItemcategory($entityItemcategoryapp);
$entityItem->setEssential(true);
$entityItem->addGroup($groupall);
}
$entityItem->setUrl($widcdt_url);
$em->persist($entityItem);
}
// Item Dokuwiki
if($activate_widdokuwiki) {
$widdokuwiki_url =$this->getContainer()->getParameter('widdokuwiki_url');
@ -973,7 +997,12 @@ class InitDataCommand extends ContainerAwareCommand
$entityItem->addGroup($groupall);
}
$entityItem->setUrl($widroundcube_url);
$entityItem->setBadgeurl("/ninegate/imap-unread.php");
if($this->getContainer()->getParameter('cas_type')=="proxy")
$entityItem->setBadgeurl("/ninegate/cas/imapunread");
else
$entityItem->setBadgeurl(null);
$em->persist($entityItem);
}

View File

@ -8,6 +8,7 @@ use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\JsonResponse;
use Symfony\Component\Form\FormError;
use Symfony\Component\Filesystem\Filesystem;
use Cadoles\PortalBundle\Entity\Alert;
use Cadoles\PortalBundle\Form\AlertType;
@ -195,6 +196,32 @@ class AlertController extends Controller
return $response;
}
public function uploadAction(Request $request,$access=null) {
// Fichier temporaire uploadé
$tmpfile = $request->files->get('upload');
$extention = $tmpfile->getClientOriginalExtension();
// Répertoire de Destination
$fs = new Filesystem();
$rootdir = $this->get('kernel')->getRootDir()."/../web";
$fs->mkdir($rootdir."/uploads/ckeditor");
// Fichier cible
$targetName = uniqid().".".$extention;
$targetFile = $rootdir."/uploads/ckeditor/".$targetName;
$targetUrl = "/".$this->getParameter('alias')."/uploads/ckeditor/".$targetName;
$message = "";
move_uploaded_file($tmpfile,$targetFile);
$output["uploaded"]=1;
$output["fileName"]=$targetName;
$output["url"]=$targetUrl;
return new Response(json_encode($output));
}
public function readAction(Request $request) {
$output=array();
$id=$request->request->get('id');

View File

@ -361,7 +361,7 @@ class BlogController extends Controller
if($groups[0]) {
if($groups[0]->getFgcanshare()) {
$pages=$groups[0]->getPages();
if($pages) {
if($pages[0]) {
$idpage=$pages[0]->getId();
$groups=$pages[0]->getGroups();
$idgroup=$groups[0]->getId();

View File

@ -182,7 +182,7 @@ class BlogarticleController extends Controller
if($groups[0]) {
if($groups[0]->getFgcanshare()) {
$pages=$groups[0]->getPages();
if($pages) {
if($pages[0]) {
$idpage=$pages[0]->getId();
$groups=$pages[0]->getGroups();
$idgroup=$groups[0]->getId();

View File

@ -341,7 +341,7 @@ class CalendarController extends Controller
if($groups[0]) {
if($groups[0]->getFgcanshare()) {
$pages=$groups[0]->getPages();
if($pages) {
if($pages[0]) {
$idpage=$pages[0]->getId();
$groups=$pages[0]->getGroups();
$idgroup=$groups[0]->getId();

View File

@ -71,7 +71,8 @@ class ItemController extends Controller
"mode" => "submit",
"labelniveau01" => $this->GetParameter("labelsniveau01"),
"ssosynchroitem" => $this->GetParameter("ssosynchroitem"),
"user_attr_cas_item" => $this->GetParameter("user_attr_cas_item")
"user_attr_cas_item" => $this->GetParameter("user_attr_cas_item"),
"activate_widsonde" => $this->GetParameter("activate_widsonde"),
));
// Récupération des data du formulaire
@ -122,7 +123,8 @@ class ItemController extends Controller
"idicon" => ($data->getIcon()?$data->getIcon()->getId():null),
"labelniveau01" => $this->GetParameter("labelsniveau01"),
"ssosynchroitem" => $this->GetParameter("ssosynchroitem"),
"user_attr_cas_item" => $this->GetParameter("user_attr_cas_item")
"user_attr_cas_item" => $this->GetParameter("user_attr_cas_item"),
"activate_widsonde" => ($this->GetParameter("activate_widsonde")&&$data->getId()>0),
));
// Récupération des data du formulaire
@ -230,6 +232,13 @@ class ItemController extends Controller
if ($form->get('submit')->isClicked() && $mode=="submit") {
}
if ($form->get('submit')->isClicked() && ($mode=="submit" || $mode=="update")) {
// si clicksonde alors clicksondeservice obligatoire
if ($data->getClicksonde() && !$data->getClicksondeservice()) {
$form->addError(new FormError('Type de service sur le click sonde est obligatoire'));
}
}
if ($form->get('submit')->isClicked() && !$form->isValid()) {
$this->get('session')->getFlashBag()->clear();
$validator = $this->get('validator');

View File

@ -362,7 +362,7 @@ class ProjectController extends Controller
if($groups[0]) {
if($groups[0]->getFgcanshare()) {
$pages=$groups[0]->getPages();
if($pages) {
if($pages[0]) {
$idpage=$pages[0]->getId();
$groups=$pages[0]->getGroups();
$idgroup=$groups[0]->getId();

View File

@ -207,7 +207,7 @@ class ProjecttaskController extends Controller
if($groups[0]) {
if($groups[0]->getFgcanshare()) {
$pages=$groups[0]->getPages();
if($pages) {
if($pages[0]) {
$idpage=$pages[0]->getId();
$groups=$pages[0]->getGroups();
$idgroup=$groups[0]->getId();

View File

@ -39,6 +39,20 @@ class SyncenvoleController extends Controller
]);
}
public function cdtAction()
{
$url=$this->getParameter("widcdt_syncenvole");
$color=$this->get('session')->get('colormain');
$themename=$this->get('session')->get("theme");
return $this->render('CadolesPortalBundle:Tool:frame.html.twig', [
'useheader' => true,
'usemenu' => false,
'usesidebar' => true,
'url' => $url."/synchro.php?app=cdt&color=#color#"
]);
}
public function gepiannuAction()
{
$url=$this->getParameter("widgepi_syncenvole");

View File

@ -149,7 +149,7 @@ class Alert
{
$today = new \DateTime();
if (null === $this->unpublishedat) {
return true;
return false;
}
if ($this->unpublishedat->getTimestamp() < $today->getTimestamp()) {
return true;

View File

@ -122,6 +122,20 @@ class Item
*/
private $icon;
/**
* @var boolean
*
* @ORM\Column(name="clicksonde", type="boolean", nullable=true, options={"default":false})
*/
private $clicksonde = false;
/**
* @var boolean
*
* @ORM\Column(name="clicksondeservice", type="string", nullable=true)
*/
private $clicksondeservice;
/**
* @var ArrayCollection $bookmark
* @var Bookmark
@ -681,4 +695,52 @@ class Item
{
return $this->badgeurl;
}
/**
* Set clicksonde
*
* @param boolean $clicksonde
*
* @return Item
*/
public function setClicksonde($clicksonde)
{
$this->clicksonde = $clicksonde;
return $this;
}
/**
* Get clicksonde
*
* @return boolean
*/
public function getClicksonde()
{
return $this->clicksonde;
}
/**
* Set clicksondeservice
*
* @param string $clicksondeservice
*
* @return Item
*/
public function setClicksondeservice($clicksondeservice)
{
$this->clicksondeservice = $clicksondeservice;
return $this;
}
/**
* Get clicksondeservice
*
* @return string
*/
public function getClicksondeservice()
{
return $this->clicksondeservice;
}
}

View File

@ -33,7 +33,7 @@ class AlertType extends AbstractType
"label" => 'Description',
"required" => false,
"disabled" => ($options["mode"]=="delete"?true:false),
"config" => array("height" => "500px")
"config" => array("height" => "500px","filebrowserUploadRoute" => 'cadoles_portal_config_alert_upload')
])
->add("fghideable",ChoiceType::class,[
@ -118,14 +118,13 @@ class AlertType extends AbstractType
->add('publishedat', DateType::class, [
'label' => 'Publier du',
'input' => 'datetime',
"widget" => 'single_text',
])
->add('unpublishedat', DateType::class, [
'label' => 'Jusqu\'au',
'input' => 'datetime',
'required' => false,
'years' => range(date('Y'), date('Y')+10)
"widget" => 'single_text',
]);

View File

@ -146,6 +146,51 @@ class ItemType extends AbstractType
"disabled" => ($options["mode"]=="delete"?true:false),
]);
}
if($options["activate_widsonde"]) {
$builder
->add('clicksonde', CheckboxType::class, [
"label" => "Exécuter une sonde statistique sur le clic",
"required" => false
])
->add('clicksondeservice', ChoiceType::class, [
"label" => 'Type de Service associé à la sonde',
"placeholder" => 'Sélectionner un service',
"required" => false,
"choices" => [
"ACCUEIL" => "ACCUEIL",
"ACTUALITES" => "ACTUALITES",
"CAHIER TEXTES" => "CAHIER_TEXTES",
"CAHIER LIAISON" => "CAHIER_LIAISON",
"COURRIER ELECTRONIQUE" => "COURRIER_ELECTRONIQUE",
"MESSAGERIE INSTANTANEE" => "MESSAGERIE_INSTANTANEE",
"VISIOCONFERENCE" => "VISIOCONFERENCE",
"STOCKAGE PARTAGE" => "STOCKAGE_PARTAGE",
"PRODUCTION COLLABORATIVE" => "PRODUCTION_COLLABORATIVE",
"DOCUMENTATION CDI" => "DOCUMENTATION_CDI",
"PARCOURS PEDAGOGIQUE" => "PARCOURS_PEDAGOGIQUE",
"RESERVATION SALLES MATERIELS" => "RESERVATION_SALLES_MATERIELS",
"SERVICE COLLECTIVITE" => "SERVICE_COLLECTIVITE",
"SERVICES VIE SCOLAIRE" => "SERVICES_VIE_SCOLAIRE",
"GESTION TEMPS" => "GESTION_TEMPS",
"ABSENCES" => "ABSENCES",
"GESTION COMPETENCES" => "GESTION_COMPETENCES",
"NOTES" => "NOTES",
"MANUEL NUMERIQUE" => "MANUEL_NUMERIQUE",
"RESSOURCE MULTIMEDIA" => "RESSOURCE_MULTIMEDIA",
"RESSOURCE ORIENTATION" => "RESSOURCE_ORIENTATION",
"RESSOURCE PRODUCTION" => "RESSOURCE_PRODUCTION",
"RESSOURCE ACCOMPAGNEMENT ENTRAINEMENT" => "RESSOURCE_ACCOMPAGNEMENT_ENTRAINEMENT",
"RESSOURCE REFERENCE DICTIONNAIRE" => "RESSOURCE_REFERENCE_DICTIONNAIRE",
"RESSOURCE DOCUMENTAIRE" => "RESSOURCE_DOCUMENTAIRE",
"PAGE ENT" => "PAGE_ENT",
],
"disabled" => ($options["mode"]=="delete"?true:false),
]);
}
}
public function configureOptions(OptionsResolver $resolver)
@ -157,6 +202,7 @@ class ItemType extends AbstractType
'labelniveau01' => "string",
'ssosynchroitem' => "string",
'user_attr_cas_item' => "string",
"activate_widsonde" => "string",
]);
}
}

View File

@ -45,7 +45,9 @@ class AlertRepository extends EntityRepository
$roles=($user?$user->getRoles():["ROLE_ANONYME"]);
$niveau01=($user?$user->getNiveau01():null);
$groups=($user?$user->getGroups():[]);
$userreads=($user?$user->getAlertreaders():new ArrayCollection());
// Initialisation du calcul des alerts
$alerts=new ArrayCollection();
@ -67,8 +69,9 @@ class AlertRepository extends EntityRepository
->setParameter("alertcategory",$alertcategoryfilter);
}
$alertsroles=$qb->getQuery()->getResult();
foreach($alertsroles as $alertrole) {
if(!$alerts->contains($alertrole)&&!$alertrole->getReaders()->contains($user)) $alerts->add($alertrole);
if(!$alerts->contains($alertrole)&&!$userreads->contains($alertrole)) $alerts->add($alertrole);
}
}
@ -91,7 +94,7 @@ class AlertRepository extends EntityRepository
}
$alertsniveau01s=$qb->getQuery()->getResult();
foreach($alertsniveau01s as $alertniveau01) {
if(!$alerts->contains($alertniveau01)&&!$alertniveau01->getReaders()->contains($user)) $alerts->add($alertniveau01);
if(!$alerts->contains($alertniveau01)&&!$userreads->contains($alertniveau01)) $alerts->add($alertniveau01);
}
// Récupération des alerts par group
@ -113,8 +116,8 @@ class AlertRepository extends EntityRepository
->setParameter("alertcategory",$alertcategoryfilter);
}
$alertsgroups=$qb->getQuery()->getResult();
foreach($alertsgroups as $alertgroup) {
if(!$alerts->contains($alertgroup)&&!$alertgroup->getReaders()->contains($user)) $alerts->add($alertgroup);
foreach($alertsgroups as $alertgroup) {
if(!$alerts->contains($alertgroup)&&!$userreads->contains($alertgroup)) $alerts->add($alertgroup);
}
}
@ -141,8 +144,8 @@ class AlertRepository extends EntityRepository
->setParameter("alertcategory",$alertcategoryfilter);
}
$alertsitems=$qb->getQuery()->getResult();
foreach($alertsitems as $alertitem) {
if(!$alerts->contains($alertitem)&&!$alertitem->getReaders()->contains($user)) $alerts->add($alertitem);
foreach($alertsitems as $alertitem) {
if(!$alerts->contains($alertitem)&&!$userreads->contains($alertitem)) $alerts->add($alertitem);
}
}

View File

@ -8,7 +8,11 @@ cadoles_portal_config_syncdelegation:
cadoles_portal_config_syncbalado:
path: /config/syncenvole/balado
defaults: { _controller: CadolesPortalBundle:Syncenvole:balado }
cadoles_portal_config_synccdt:
path: /config/syncenvole/cdt
defaults: { _controller: CadolesPortalBundle:Syncenvole:cdt }
cadoles_portal_config_syncgepiannu:
path: /config/syncenvole/gepiannu
defaults: { _controller: CadolesPortalBundle:Syncenvole:gepiannu }
@ -159,6 +163,13 @@ cadoles_portal_config_alert_order:
path: /config/alert/order
defaults: { _controller: CadolesPortalBundle:Alert:order }
cadoles_portal_config_alert_upload:
path: /config/alert/upload
defaults: { _controller: CadolesPortalBundle:Alert:upload }
cadoles_portal_config_alert_upload_direct:
path: /config/alert/upload&responseType=json
defaults: { _controller: CadolesPortalBundle:Alert:upload }
cadoles_portal_config_ajax_alert_seleclist:
path: /config/alert/ajax/selectlist
defaults: { _controller: CadolesPortalBundle:Alert:ajaxseleclist }
@ -321,6 +332,9 @@ cadoles_portal_config_page_order:
cadoles_portal_config_page_upload:
path: /config/page/upload
defaults: { _controller: CadolesPortalBundle:Page:upload, access: config }
cadoles_portal_config_page_upload_direct:
path: /config/page/upload&responseType=json
defaults: { _controller: CadolesPortalBundle:Page:upload, access: config }
#-- Access user
cadoles_portal_user_page_submit:
@ -350,6 +364,9 @@ cadoles_portal_user_page_order:
cadoles_portal_user_page_upload:
path: /user/page/upload
defaults: { _controller: CadolesPortalBundle:Page:upload, access: user }
cadoles_portal_user_page_upload_direct:
path: /user/page/upload&responseType=json
defaults: { _controller: CadolesPortalBundle:Page:upload, access: user }
# Page spécifique
cadoles_portal_user_page_application:
@ -531,7 +548,10 @@ cadoles_portal_config_blogarticle_delete:
cadoles_portal_config_blogarticle_upload:
path: /config/blogarticle/upload
defaults: { _controller: CadolesPortalBundle:Blogarticle:upload, access: config }
cadoles_portal_config_blogarticle_upload_direct:
path: /config/blogarticle/upload&responseType=json
defaults: { _controller: CadolesPortalBundle:Blogarticle:upload, access: config }
cadoles_portal_config_blogarticle_image:
path: /config/blogarticle/image
defaults: { _controller: CadolesPortalBundle:Blogarticle:image, access: config }
@ -556,6 +576,9 @@ cadoles_portal_user_blogarticle_delete:
cadoles_portal_user_blogarticle_upload:
path: /user/blogarticle/upload
defaults: { _controller: CadolesPortalBundle:Blogarticle:upload, access: user }
cadoles_portal_user_blogarticle_upload_direct:
path: /user/blogarticle/upload&responseType=json
defaults: { _controller: CadolesPortalBundle:Blogarticle:upload, access: user }
cadoles_portal_user_blogarticle_image:
path: /user/blogarticle/image
@ -584,6 +607,9 @@ cadoles_portal_config_blogcomment_delete:
cadoles_portal_config_blogcomment_upload:
path: /config/blogcomment/upload
defaults: { _controller: CadolesPortalBundle:Blogcomment:upload, access: config }
cadoles_portal_config_blogcomment_upload_direct:
path: /config/blogcomment/upload&responseType=json
defaults: { _controller: CadolesPortalBundle:Blogcomment:upload, access: config }
#-- Access user
cadoles_portal_user_blogcomment_submit:
@ -605,7 +631,9 @@ cadoles_portal_user_blogcomment_delete:
cadoles_portal_user_blogcomment_upload:
path: /user/blogcomment/upload
defaults: { _controller: CadolesPortalBundle:Blogcomment:upload, access: user }
cadoles_portal_user_blogcomment_upload_direct:
path: /user/blogcomment/upload&responseType=json
defaults: { _controller: CadolesPortalBundle:Blogcomment:upload, access: user }
#== CALENDAR =============================================================================================================================================
@ -804,6 +832,9 @@ cadoles_portal_config_projecttask_delete:
cadoles_portal_config_projecttask_upload:
path: /config/projecttask/upload
defaults: { _controller: CadolesPortalBundle:Projecttask:upload, access: config }
cadoles_portal_config_projecttask_upload_direct:
path: /config/projecttask/upload&responseType=json
defaults: { _controller: CadolesPortalBundle:Projecttask:upload, access: config }
cadoles_portal_config_projecttask_users:
path: /config/projecttask/users
@ -833,6 +864,9 @@ cadoles_portal_user_projecttask_delete:
cadoles_portal_user_projecttask_upload:
path: /user/projecttask/upload
defaults: { _controller: CadolesPortalBundle:Projecttask:upload, access: user }
cadoles_portal_user_projecttask_upload_direct:
path: /user/projecttask/upload&responseType=json
defaults: { _controller: CadolesPortalBundle:Projecttask:upload, access: user }
cadoles_portal_user_projecttask_users:
path: /user/projecttask/users
@ -861,6 +895,9 @@ cadoles_portal_config_projectcomment_delete:
cadoles_portal_config_projectcomment_upload:
path: /config/projectcomment/upload
defaults: { _controller: CadolesPortalBundle:Projectcomment:upload, access: config }
cadoles_portal_config_projectcomment_upload_direct:
path: /config/projectcomment/upload&responseType=json
defaults: { _controller: CadolesPortalBundle:Projectcomment:upload, access: config }
#-- Access user
cadoles_portal_user_projectcomment_submit:
@ -878,7 +915,9 @@ cadoles_portal_user_projectcomment_delete:
cadoles_portal_user_projectcomment_upload:
path: /user/projectcomment/upload
defaults: { _controller: CadolesPortalBundle:Projectcomment:upload, access: user }
cadoles_portal_user_projectcomment_upload_direct:
path: /user/projectcomment/upload&responseType=json
defaults: { _controller: CadolesPortalBundle:Projectcomment:upload, access: user }
#== FEED =================================================================================================================================================
@ -930,6 +969,9 @@ cadoles_portal_config_pagewidget_order:
cadoles_portal_config_pagewidget_upload:
path: /config/pagewidget/upload
defaults: { _controller: CadolesPortalBundle:Pagewidget:upload, access: config }
cadoles_portal_config_pagewidget_upload_direct:
path: /config/pagewidget/upload&responseType=json
defaults: { _controller: CadolesPortalBundle:Pagewidget:upload, access: config }
cadoles_portal_config_panelwidget_view_url:
path: /config/pagewidget/view/url/{id}
@ -1051,6 +1093,9 @@ cadoles_portal_user_pagewidget_order:
cadoles_portal_user_pagewidget_upload:
path: /user/pagewidget/upload
defaults: { _controller: CadolesPortalBundle:Pagewidget:upload, access: user }
cadoles_portal_user_pagewidget_upload_direct:
path: /user/pagewidget/upload&responseType=json
defaults: { _controller: CadolesPortalBundle:Pagewidget:upload, access: user }
cadoles_portal_user_panelwidget_view_url:
path: /pagewidget/view/url/{id}

View File

@ -4,7 +4,7 @@
{{ form_start(form) }}
<h1 class="page-header">
{% if mode=="update" %}
Modification Annonces
Modification Annonces = {{alert.title}}
{% elseif mode=="submit" %}
Création Annonces
{% endif %}

View File

@ -4,7 +4,7 @@
{{ form_start(form) }}
<h1 class="page-header">
{% if mode=="update" %}
Modification Catégorie d'Annonce
Modification Catégorie d'Annonce = {{alertcategory.label}}
{% elseif mode=="submit" %}
Création Catégorie d'Annonce
{% endif %}

View File

@ -4,7 +4,7 @@
{{ form_start(form) }}
<h1 class="page-header">
{% if mode=="update" %}
Modification Blog
Modification Blog = {{entity.name}}
{% elseif mode=="submit" %}
Création Blog
{% endif %}

View File

@ -4,7 +4,7 @@
{{ form_start(form) }}
<h1 class="page-header">
{% if mode=="update" %}
Modification Calendrier
Modification Calendrier = {{entity.name}}
{% elseif mode=="submit" %}
Création Calendrier
{% endif %}

View File

@ -3,7 +3,7 @@
{% block pagewrapper %}
{{ form_start(form) }}
<h1>
Partage Calendrier
Partage Calendrier = {{entity.name}}
</h1>
<p>

View File

@ -288,7 +288,12 @@
{% if entity.id is defined %}
{% for calendar in calendars %}
{% if calendar.id==entity.id %}
showCalendar({{ calendar.id }}, {{ calendar.canadd }});
{% if access=="config" %}
{% set calendarcanadd=true %}
{% else %}
{% set calendarcanadd=calendar.canadd %}
{% endif %}
showCalendar({{ calendar.id }}, {{ calendarcanadd }});
{% endif %}
{% endfor %}
{% else %}

View File

@ -4,7 +4,7 @@
{{ form_start(form) }}
<h1 class="page-header">
{% if mode=="update" %}
Modification Flux
Modification Flux = {{flux.title}}
{% elseif mode=="submit" %}
Création Flux
{% endif %}
@ -17,7 +17,7 @@
<a href={{ path('cadoles_portal_config_flux_delete',{'id':flux.id}) }}
class="btn btn-danger pull-right"
data-method="delete" data-csrf="_token:{{ 'csrf' }}"
data-confirm="Êtes-vous sûr de vouloir supprimer cette annonce ?">
data-confirm="Êtes-vous sûr de vouloir supprimer ce flux ?">
Supprimer
</a>
{% endif %}

View File

@ -4,7 +4,7 @@
{{ form_start(form) }}
<h1 class="page-header">
{% if mode=="update" %}
Modification Item
Modification Item = {{item.title}}
{% elseif mode=="submit" %}
Création Item
{% endif %}
@ -67,6 +67,13 @@
{{ form_row(form.ssoitem) }}
{% endif %}
{% if form.clicksonde is defined %}
{{ form_row(form.clicksonde) }}
<div id="divclicksondeservice">
{{ form_row(form.clicksondeservice) }}
</div>
{% endif %}
{{ form_row(form.color) }}
<div id="diviconsel" class="col-md-12 text-left" style="height:140px; padding:20px; text-align:center; background-color: {{ item.color ? "#"~item.color : '#'~color['main'] }};">
@ -94,6 +101,10 @@
showhide();
});
$('#item_clicksonde').change(function() {
showhide();
});
function selIcon(idicon,label) {
$("#item_idicon").val(idicon);
$("#diviconsel img").remove();
@ -122,5 +133,13 @@
if($("#item_target").val()=="frame") {
$("#divhelp").show();
}
if($("#item_clicksonde").is(':checked')) {
$("#divclicksondeservice").show();
}
else {
$("#divclicksondeservice").hide();
}
}
{% endblock %}

View File

@ -4,7 +4,7 @@
{{ form_start(form) }}
<h1 class="page-header">
{% if mode=="update" %}
Modification Catégorie d'Item
Modification Catégorie d'Item = {{itemcategory.label}}
{% elseif mode=="submit" %}
Création Catégorie d'Item
{% endif %}

View File

@ -4,7 +4,7 @@
{{ form_start(form) }}
<h1 class="page-header">
{% if mode=="update" %}
Modification Charte
Modification Charte = {{notice.title}}
{% elseif mode=="submit" %}
Création Charte
{% endif %}

View File

@ -25,12 +25,17 @@
<div class="grid-item-content" style="background-color: {{ bookmark.color ? "#"~bookmark.color : '#'~colormain }};">
<a style="cursor:pointer" onClick="modBookmark({{ bookmark.id }})" class="item-update"><i style="color: #FFF" class="fa fa-file" title="Modifier le favori"></i></a>
{% set datasonde = "" %}
{% if bookmark.item and bookmark.item.clicksonde %}
{% set datasonde = "class='linktosonde' data-sondetitle='"~bookmark.item.title~"' data-sondeservice='"~bookmark.item.clicksondeservice~"'" %}
{% endif %}
{% if bookmark.target == 'frame' %}
<a class="linktosonde" data-sonde="{{ bookmark.title }}" style="cursor:pointer" onClick="showFrameitem('bookmark{{ bookmark.id }}','{{ bookmark.url }}')">
<a {{datasonde|raw}} style="cursor:pointer" onClick="showFrameitem('bookmark{{ bookmark.id }}','{{ bookmark.url }}')">
{% elseif bookmark.target == "_self" %}
<a class="linktosonde" data-sonde="{{ bookmark.title }}" href="{{ bookmark.url }}" target="{% if access=="user" %}_top{% else %}{{ bookmark.target }}{% endif %}">
<a {{datasonde|raw}} href="{{ bookmark.url }}" target="{% if access=="user" %}_top{% else %}{{ bookmark.target }}{% endif %}">
{% else %}
<a class="linktosonde" data-sonde="{{ bookmark.title }}" href="{{ bookmark.url }}" target="{{ bookmark.target }}">
<a {{datasonde|raw}} href="{{ bookmark.url }}" target="{{ bookmark.target }}">
{% endif %}
<div class="item-link clearfix">
@ -110,12 +115,17 @@
{% endif %}
{% else %}
{% set datasonde = "" %}
{% if item.clicksonde %}
{% set datasonde = "class='linktosonde' data-sondetitle='"~item.title~"' data-sondeservice='"~item.clicksondeservice~"'" %}
{% endif %}
{% if item.target == 'frame' %}
<a class="linktosonde" data-sonde="{{ item.title }}" style="cursor:pointer" onClick="showFrameitem({{ item.id }},'{{ item.url }}')">
<a {{datasonde|raw}} style="cursor:pointer" onClick="showFrameitem({{ item.id }},'{{ item.url }}')">
{% elseif item.target == "_self" %}
<a class="linktosonde" data-sonde="{{ item.title }}" href="{{ item.url }}" target="{% if access=="user" %}_top{% else %}{{ item.target }}{% endif %}">
<a {{datasonde|raw}} href="{{ item.url }}" target="{% if access=="user" %}_top{% else %}{{ item.target }}{% endif %}">
{% else %}
<a class="linktosonde" data-sonde="{{ item.title }}" href="{{ item.url }}" target="{{ item.target }}">
<a {{datasonde|raw}} href="{{ item.url }}" target="{{ item.target }}">
{% endif %}
{% endif %}
@ -196,9 +206,10 @@
// Sur click item à sonder
{% if activate_widsonde %}
$( ".linktosonde" ).click(function() {
title=$(this).attr("data-sonde");
//$.getScript( "{{ widsonde_url }}?appli="+title );
});
title=$(this).attr("data-sondetitle");
service=$(this).attr("data-sondeservice");
EnvoleClickSondes($(this),title,service);
});
{% endif %}
});

View File

@ -26,11 +26,11 @@
<a style="cursor:pointer" onClick="modBookmark({{ bookmark.id }})" class="item-update"><i style="color: #FFF" class="fa fa-file" title="Modifier le favori"></i></a>
{% if bookmark.target == 'frame' %}
<a class="linktosonde" data-sonde="{{ bookmark.title }}" style="cursor:pointer" onClick="showFrameitem('bookmark{{ bookmark.id }}','{{ bookmark.url }}')">
<a style="cursor:pointer" onClick="showFrameitem('bookmark{{ bookmark.id }}','{{ bookmark.url }}')">
{% elseif bookmark.target == "_self" %}
<a class="linktosonde" data-sonde="{{ bookmark.title }}" href="{{ bookmark.url }}" target="{% if access=="user" %}_top{% else %}{{ bookmark.target }}{% endif %}">
<a href="{{ bookmark.url }}" target="{% if access=="user" %}_top{% else %}{{ bookmark.target }}{% endif %}">
{% else %}
<a class="linktosonde" data-sonde="{{ bookmark.title }}" href="{{ bookmark.url }}" target="{{ bookmark.target }}">
<a href="{{ bookmark.url }}" target="{{ bookmark.target }}">
{% endif %}
<div class="item-link clearfix">
@ -111,11 +111,11 @@
{% else %}
{% if item.target == 'frame' %}
<a class="linktosonde" data-sonde="{{ item.title }}" style="cursor:pointer" onClick="showFrameitem({{ item.id }},'{{ item.url }}')">
<a style="cursor:pointer" onClick="showFrameitem({{ item.id }},'{{ item.url }}')">
{% elseif item.target == "_self" %}
<a class="linktosonde" data-sonde="{{ item.title }}" href="{{ item.url }}" target="{% if access=="user" %}_top{% else %}{{ item.target }}{% endif %}">
<a href="{{ item.url }}" target="{% if access=="user" %}_top{% else %}{{ item.target }}{% endif %}">
{% else %}
<a class="linktosonde" data-sonde="{{ item.title }}" href="{{ item.url }}" target="{{ item.target }}">
<a href="{{ item.url }}" target="{{ item.target }}">
{% endif %}
{% endif %}
@ -192,15 +192,6 @@
var grid = $('.grid').masonry(optiongrid);
}
});
// Sur click item à sonder
{% if activate_widsonde %}
$( ".linktosonde" ).click(function() {
title=$(this).attr("data-sonde");
//$.getScript( "{{ widsonde_url }}?appli="+title );
});
{% endif %}
});

View File

@ -13,9 +13,12 @@
{% set forcereload=page.toreload %}
{% endif %}
{% set usage="portal" %}
{% if loop.first %} {% set usage="accueil" %} {%endif %}
{% if entity.id is defined and page.id==entity.id %}
<li id="menupage-{{page.id}}" class="active" style="cursor:pointer">
<a onClick="showPage({{ page.id }},{{ page.pagecategory.id }},'{{ page.canupdate }}','portal','{{forcereload}}',null,'{{page.name}}')">
<a onClick="showPage({{ page.id }},{{ page.pagecategory.id }},'{{ page.canupdate }}','{{usage}}','{{forcereload}}',null,'{{page.name}}')">
{% if page.fonticon %}
<i class="{{ page.fonticon }} fa-faw"></i>&nbsp;
{% endif %}
@ -91,7 +94,7 @@
<div id="menupageaction">
<a id="menuname" style="cursor:pointer;font-size:80%" href="">qsfqsdf</a>
<a id="menuname" style="cursor:pointer;font-size:80%" href=""></a>
{% if canadd %}
<a id="menusubmit" style="cursor:pointer" onclick="submitPage()" title='Ajouter une page'><i class='fa fa-plus fa-fw'></i></a>
@ -258,7 +261,9 @@
{% if gotoroute is empty %}
{% for page in pagesadmin %}
{% if page.id==entity.id %}
showPage({{ page.id }}, {{ page.pagecategory.id }},'{{ page.canupdate }}','portal',false,null,'{{page.name}}');
{% set usage="portal" %}
{% if loop.first %} {% set usage="accueil" %} {%endif %}
showPage({{ page.id }}, {{ page.pagecategory.id }},'{{ page.canupdate }}','{{usage}}',false,null,'{{page.name}}');
{% endif %}
{% endfor %}
@ -308,54 +313,11 @@
order: [[ 1, "asc" ]],
});
{% if app.user %}
{% if app.user and app.session.get("timerefreshnotif") > 0%}
setInterval(function(){
loadmsgCounter()
}, 10000);
}, {{(app.session.get("timerefreshnotif")*1000)}});
{% endif %}
// Init socket de counter
/* Désactiver car il semble préférable de faire un appel ajax régulier plutot qu'ouvrir un channel websocket
{% if websocket_activate %}
var _WS_URI = "wss://{{ gos_web_socket_server_host }}:{{ gos_web_socket_server_port }}";
var webSocket = WS.connect(_WS_URI);
webSocket.on("socket/connect", function (session) {
// The callback function in "subscribe" is called everytime an event is published in that channel.
session.subscribe("websocket/counter", function (uri, payload) {
if(payload.log) {
console.log("Received message", payload.log);
}
if(payload.alert) {
alert(payload.alert);
}
{% if app.user %}
if(payload.from!="{{app.user.id}}") {
menu=$("a[data-group='"+payload.group+"']");
if(menu.length) {
if(payload.add) {
console.log("Ajout counter pour group "+payload.group+" by "+payload.from);
if(menu.children(".badge").length) {
menu.children(".badge").html(+(menu.children(".badge").html())+1);
}
else menu.append("<span id='badge-"+payload.group+"' class='badge'>1</span");
}
}
}
{% endif %}
});
$(document).on('click', '#refreshcounter', function(){
{% if app.user %}
event=$(this).data("event");
event.userid={{app.user.id}}
session.publish("websocket/counter", event);
{% endif %}
});
});
{% endif %}
*/
});
$(window).resize(function() {

View File

@ -4,7 +4,7 @@
{{ form_start(form) }}
<h1 class="page-header">
{% if mode=="update" %}
Modification Page Editeur
Modification Page Editeur = {{entity.name}}
{% elseif mode=="submit" %}
Création Page Editeur
{% endif %}

View File

@ -3,7 +3,7 @@
{% block pagewrapper %}
{{ form_start(form) }}
<h1 class="page-header">
Modification Page {{ entity.pagecategory.name}}
Modification Page {{ entity.pagecategory.name}} = {{entity.name}}
</h1>
<p>

View File

@ -4,7 +4,7 @@
{{ form_start(form) }}
<h1 class="page-header">
{% if mode=="update" %}
Modification Page URL
Modification Page URL = {{entity.name}}
{% elseif mode=="submit" %}
Création Page URL
{% endif %}

View File

@ -142,9 +142,9 @@
{{ form_start(form) }}
<h1 class="page-header">
{% if mode=="update" %}
Modification Page Widget
Modification Page Widget = {{entity.name}}
{% elseif mode=="updatetemplate" %}
Modification Modèle de Page
Modification Modèle de Page = {{entity.name}}
{% elseif mode=="submit" %}
Création Page Widget
{% endif %}

View File

@ -289,8 +289,9 @@
// Sur click item à sonder
{% if activate_widsonde %}
$( ".linktosonde" ).click(function() {
title=$(this).attr("data-sonde");
//$.getScript( "{{ widsonde_url }}?appli="+title );
title=$(this).attr("data-sondetitle");
service=$(this).attr("data-sondeservice");
EnvoleClickSondes($(this),title,service);
});
{% endif %}

View File

@ -68,7 +68,7 @@
</div>
<div class="panel-body">
{{ alert.content|raw }}
<div class="widget-ckeditor">{{ alert.content|raw }}</div>
{% if not alert.items is empty %}
{% if app.user %}
@ -95,11 +95,11 @@
{% else %}
{% if item.target == 'frame' %}
<a class="linktosonde" data-sonde="{{ item.title }}" style="cursor:pointer" onClick="showFrameitem({{ item.id }},'{{ item.url|replace({'#login#': username}) }}')">
<a style="cursor:pointer" onClick="showFrameitem({{ item.id }},'{{ item.url|replace({'#login#': username}) }}')">
{% elseif item.target == "_self" %}
<a class="linktosonde" data-sonde="{{ item.title }}" href="{{ item.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ item.target }}{% endif %}">
<a href="{{ item.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ item.target }}{% endif %}">
{% else %}
<a class="linktosonde" data-sonde="{{ item.title }}" href="{{ item.url|replace({'#login#': username}) }}" target="{{ item.target }}">
<a href="{{ item.url|replace({'#login#': username}) }}" target="{{ item.target }}">
{% endif %}
{% endif %}

View File

@ -83,7 +83,7 @@
<div class="grid-item {{ stylegrid }}" data-idcategory="{{ item.itemcategory.id }}" data-iditem="{{ item.id }}">
<div class="grid-item-content" style="background-color: {{ item.color ? "#"~item.color : '#'~colormain }};">
<a class="linktosonde" data-sonde="{{ item.itemcategory.label }}" href="{{ item.url }}" target="_blank">
<a href="{{ item.url }}" target="_blank">
<div class="item-link clearfix">

View File

@ -87,11 +87,11 @@
{% endif %}
{% if bookmark.target == 'frame' %}
<a class="linktosonde" data-sonde="{{ bookmark.title }}" style="cursor:pointer" onClick="showFrameitem('bookmark{{ bookmark.id }}','{{ bookmark.url|replace({'#login#': username}) }}')">
<a style="cursor:pointer" onClick="showFrameitem('bookmark{{ bookmark.id }}','{{ bookmark.url|replace({'#login#': username}) }}')">
{% elseif bookmark.target == "_self" %}
<a class="linktosonde" data-sonde="{{ bookmark.title }}" href="{{ bookmark.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ bookmark.target }}{% endif %}">
<a href="{{ bookmark.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ bookmark.target }}{% endif %}">
{% else %}
<a class="linktosonde" data-sonde="{{ bookmark.title }}" href="{{ bookmark.url|replace({'#login#': username}) }}" target="{{ bookmark.target }}">
<a href="{{ bookmark.url|replace({'#login#': username}) }}" target="{{ bookmark.target }}">
{% endif %}
<div class="item-link clearfix">

View File

@ -109,7 +109,7 @@
<div class="grid-item {{ stylegrid }} feed flux-{{ feed.fluxid }}">
<div class="grid-item-content" style="{{ stylecolor }};">
<a class="linktosonde" data-sonde="Flux = {{ feed.fluxtitle }}" href="{{ feed.link }}" target="_blank">
<a href="{{ feed.link }}" target="_blank">
<div class="item-link clearfix">
{% if feed.image is not empty %}
<div class="grid-item-logo">

View File

@ -125,11 +125,11 @@
<a style="cursor:pointer" onClick="delBookmark({{ bookmark.id }})" class="item-heart"><i style="color: #FFF" class="fa fa-trash" title="Supprimer le favori"></i></a>
{% if bookmark.target == 'frame' %}
<a class="linktosonde" data-sonde="{{ bookmark.title }}" style="cursor:pointer" onClick="showFrameitem('bookmark{{ bookmark.id }}','{{ bookmark.url|replace({'#login#': username}) }}')">
<a style="cursor:pointer" onClick="showFrameitem('bookmark{{ bookmark.id }}','{{ bookmark.url|replace({'#login#': username}) }}')">
{% elseif bookmark.target == "_self" %}
<a class="linktosonde" data-sonde="{{ bookmark.title }}" href="{{ bookmark.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ bookmark.target }}{% endif %}">
<a href="{{ bookmark.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ bookmark.target }}{% endif %}">
{% else %}
<a class="linktosonde" data-sonde="{{ bookmark.title }}" href="{{ bookmark.url|replace({'#login#': username}) }}" target="{{ bookmark.target }}">
<a href="{{ bookmark.url|replace({'#login#': username}) }}" target="{{ bookmark.target }}">
{% endif %}
<div class="item-link clearfix">
@ -180,7 +180,7 @@
{%endif%}
<div class="grid-item {{ stylegrid }}" data-idcategory="bookmark" data-title="{{ bookmark.item.title|lower }}">
<div class="grid-item-content" style="background-color: {{ bookmark.color ? "#"~bookmark.color : '#'~colormain }};">
<div class="grid-item-content" style="background-color: {{ bookmark.item.color ? "#"~bookmark.item.color : '#'~colormain }};">
{% if bookmark.item.content %}
<a style="cursor:pointer" class="item-preview"><i style="color: #FFF" class="fa fa-info" title="Informations sur ce service"></i></a>
{% endif %}
@ -188,12 +188,17 @@
<a style="cursor:pointer" onClick="delBookmark({{ bookmark.id }})" class="item-heart"><i style="color: #FFF" class="fa fa-trash" title="Supprimer des favoris"></i></a>
{% endif %}
{% set datasonde = "" %}
{% if bookmark.item and bookmark.item.clicksonde %}
{% set datasonde = "class='linktosonde' data-sondetitle='"~bookmark.item.title~"' data-sondeservice='"~bookmark.item.clicksondeservice~"'" %}
{% endif %}
{% if bookmark.item.target == 'frame' %}
<a class="linktosonde" data-sonde="{{ bookmark.item.title }}" style="cursor:pointer" onClick="showFrameitem('bookmark{{ bookmark.item.id }}','{{ bookmark.item.url|replace({'#login#': username}) }}')">
<a {{datasonde|raw}} style="cursor:pointer" onClick="showFrameitem('bookmark{{ bookmark.item.id }}','{{ bookmark.item.url|replace({'#login#': username}) }}')">
{% elseif bookmark.target == "_self" %}
<a class="linktosonde" data-sonde="{{ bookmark.item.title }}" href="{{ bookmark.item.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ bookmark.item.target }}{% endif %}">
<a {{datasonde|raw}} data-sonde="{{ bookmark.item.title }}" href="{{ bookmark.item.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ bookmark.item.target }}{% endif %}">
{% else %}
<a class="linktosonde" data-sonde="{{ bookmark.item.title }}" href="{{ bookmark.item.url|replace({'#login#': username}) }}" target="{{ bookmark.item.target }}">
<a {{datasonde|raw}} href="{{ bookmark.item.url|replace({'#login#': username}) }}" target="{{ bookmark.item.target }}">
{% endif %}
<div class="item-link clearfix">
@ -207,10 +212,10 @@
<div class="grid-item-title">
<h2>{{ bookmark.item.title }}</h2>
<span>{{ bookmark.item.subtitle|nl2br }}</span>
{% if not bookmark.item.badgeurl is empty %}
<div class="itembadgeurl badge badge-pill" data-url="{{bookmark.item.badgeurl}}" style="background-color: #449d44;"></div>
{% endif %}
<span>{{ bookmark.item.subtitle|nl2br }}</<span>
<div class="itembadgeurl badge badge-pill" data-url="{{bookmark.item.badgeurl}}" style="background-color: #ffffff; color: {{ bookmark.item.color ? "#"~bookmark.item.color : '#'~colormain }};"></div>
{% endif %}
</div>
</div>
</a>
@ -236,7 +241,7 @@
{% for bookmark in bookmarks %}
{% if bookmark.item %}
<div class="grid-item {{ stylegrid }}" data-idcategory="bookmark" data-title="{{ bookmark.item.title|lower }}">
<div class="grid-item-content" style="background-color: {{ bookmark.color ? "#"~bookmark.color : '#'~colormain }};">
<div class="grid-item-content" style="background-color: {{ bookmark.item.color ? "#"~bookmark.item.color : '#'~colormain }};">
{% if bookmark.item.content %}
<a style="cursor:pointer" class="item-preview"><i style="color: #FFF" class="fa fa-info" title="Informations sur ce service"></i></a>
{% endif %}
@ -244,12 +249,17 @@
<a style="cursor:pointer" onClick="delBookmark({{ bookmark.id }})" class="item-heart"><i style="color: #FFF" class="fa fa-trash" title="Supprimer des favoris"></i></a>
{% endif %}
{% set datasonde = "" %}
{% if bookmark.item and bookmark.item.clicksonde %}
{% set datasonde = "class='linktosonde' data-sondetitle='"~bookmark.item.title~"' data-sondeservice='"~bookmark.item.clicksondeservice~"'" %}
{% endif %}
{% if bookmark.item.target == 'frame' %}
<a class="linktosonde" data-sonde="{{ bookmark.item.title }}" style="cursor:pointer" onClick="showFrameitem('bookmark{{ bookmark.item.id }}','{{ bookmark.item.url|replace({'#login#': username}) }}')">
<a {{datasonde|raw}} style="cursor:pointer" onClick="showFrameitem('bookmark{{ bookmark.item.id }}','{{ bookmark.item.url|replace({'#login#': username}) }}')">
{% elseif bookmark.target == "_self" %}
<a class="linktosonde" data-sonde="{{ bookmark.item.title }}" href="{{ bookmark.item.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ bookmark.item.target }}{% endif %}">
<a {{datasonde|raw}} href="{{ bookmark.item.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ bookmark.item.target }}{% endif %}">
{% else %}
<a class="linktosonde" data-sonde="{{ bookmark.item.title }}" href="{{ bookmark.item.url|replace({'#login#': username}) }}" target="{{ bookmark.item.target }}">
<a {{datasonde|raw}} href="{{ bookmark.item.url|replace({'#login#': username}) }}" target="{{ bookmark.item.target }}">
{% endif %}
<div class="item-link clearfix">
@ -263,10 +273,12 @@
<div class="grid-item-title">
<h2>{{ bookmark.item.title }}</h2>
<span>{{ bookmark.item.subtitle|nl2br }}</span>
{% if not bookmark.item.badgeurl is empty %}
<div class="itembadgeurl badge badge-pill" data-url="{{bookmark.item.badgeurl}}" style="background-color: #449d44;"></div>
{% endif %}
<span>{{ bookmark.item.subtitle|nl2br }}</<span>
<div style="margin-top:5px;text-align:center;{% if stylegrid == "grid-list"%} float: right;position: absolute;top: 10px;right: -50px; {%endif%}">
<div class="itembadgeurl badge badge-pill" data-url="{{bookmark.item.badgeurl}}" style="background-color: #ffffff; color: {{ bookmark.color ? "#"~bookmark.color : '#'~colormain }};"></div>
</div>
{% endif %}
</div>
</div>
</a>
@ -283,11 +295,11 @@
<a style="cursor:pointer" onClick="delBookmark({{ bookmark.id }})" class="item-heart"><i style="color: #FFF" class="fa fa-trash" title="Supprimer le favori"></i></a>
{% if bookmark.target == 'frame' %}
<a class="linktosonde" data-sonde="{{ bookmark.title }}" style="cursor:pointer" onClick="showFrameitem('bookmark{{ bookmark.id }}','{{ bookmark.url|replace({'#login#': username}) }}')">
<a style="cursor:pointer" onClick="showFrameitem('bookmark{{ bookmark.id }}','{{ bookmark.url|replace({'#login#': username}) }}')">
{% elseif bookmark.target == "_self" %}
<a class="linktosonde" data-sonde="{{ bookmark.title }}" href="{{ bookmark.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ bookmark.target }}{% endif %}">
<a href="{{ bookmark.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ bookmark.target }}{% endif %}">
{% else %}
<a class="linktosonde" data-sonde="{{ bookmark.title }}" href="{{ bookmark.url|replace({'#login#': username}) }}" target="{{ bookmark.target }}">
<a href="{{ bookmark.url|replace({'#login#': username}) }}" target="{{ bookmark.target }}">
{% endif %}
<div class="item-link clearfix">
@ -301,7 +313,7 @@
<div class="grid-item-title">
<h2>{{ bookmark.title }}</h2>
<span>{{ bookmark.subtitle|nl2br }}</<span>
<span>{{ bookmark.subtitle|nl2br }}</span>
</div>
</div>
</a>
@ -392,12 +404,17 @@
{% endif %}
{% else %}
{% set datasonde = "" %}
{% if item.clicksonde %}
{% set datasonde = "class='linktosonde' data-sondetitle='"~item.title~"' data-sondeservice='"~item.clicksondeservice~"'" %}
{% endif %}
{% if item.target == 'frame' %}
<a class="linktosonde" data-sonde="{{ item.title }}" style="cursor:pointer" onClick="showFrameitem({{ item.id }},'{{ item.url|replace({'#login#': username}) }}')">
<a {{datasonde|raw}} style="cursor:pointer" onClick="showFrameitem({{ item.id }},'{{ item.url|replace({'#login#': username}) }}')">
{% elseif item.target == "_self" %}
<a class="linktosonde" data-sonde="{{ item.title }}" href="{{ item.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ item.target }}{% endif %}">
<a {{datasonde|raw}} href="{{ item.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ item.target }}{% endif %}">
{% else %}
<a class="linktosonde" data-sonde="{{ item.title }}" href="{{ item.url|replace({'#login#': username}) }}" target="{{ item.target }}">
<a {{datasonde|raw}} href="{{ item.url|replace({'#login#': username}) }}" target="{{ item.target }}">
{% endif %}
{% endif %}
@ -412,10 +429,12 @@
<div class="grid-item-title">
<h2>{{ item.title }}</h2>
<span>{{ item.subtitle|nl2br }}</span>
{% if not item.badgeurl is empty %}
<div class="itembadgeurl badge badge-pill" data-url="{{item.badgeurl}}" style="background-color: #449d44;"></div>
{% endif %}
<span>{{ item.subtitle|nl2br }}</<span>
<div style="margin-top:5px;text-align:center;{% if stylegrid == "grid-list"%} float: right;position: absolute;top: 10px;right: -50px; {%endif%}">
<div class="itembadgeurl badge badge-pill" data-url="{{item.badgeurl}}" style="background-color: #ffffff; color: {{ item.color ? "#"~item.color : '#'~colormain }};"></div>
</div>
{% endif %}
</div>
</div>
</a>

View File

@ -89,7 +89,7 @@
{% for bookmark in bookmarks %}
{% if bookmark.item %}
<div class="grid-item {{ stylegrid }}" data-idcategory="bookmark" data-title="{{ bookmark.item.title|lower }}">
<div class="grid-item-content" style="background-color: {{ bookmark.color ? "#"~bookmark.color : '#'~colormain }};">
<div class="grid-item-content" style="background-color: {{ bookmark.item.color ? "#"~bookmark.item.color : '#'~colormain }};">
{% if bookmark.item.content %}
<a style="cursor:pointer" class="item-preview"><i style="color: #FFF" class="fa fa-info" title="Informations sur ce service"></i></a>
{% endif %}
@ -97,18 +97,20 @@
<a style="cursor:pointer" onClick="delBookmark({{ bookmark.id }})" class="item-heart"><i style="color: #FFF" class="fa fa-trash" title="Supprimer des favoris"></i></a>
{% endif %}
{% set datasonde = "" %}
{% if bookmark.item.clicksonde %}
{% set datasonde = "class='linktosonde' data-sondetitle='"~bookmark.item.title~"' data-sondeservice='"~bookmark.item.clicksondeservice~"'" %}
{% endif %}
{% if bookmark.item.target == 'frame' %}
<a class="linktosonde" data-sonde="{{ bookmark.item.title }}" style="cursor:pointer" onClick="showFrameitem('bookmark{{ bookmark.item.id }}','{{ bookmark.item.url|replace({'#login#': username}) }}')">
<a {{datasonde|raw}} style="cursor:pointer" onClick="showFrameitem('bookmark{{ bookmark.item.id }}','{{ bookmark.item.url|replace({'#login#': username}) }}')">
{% elseif bookmark.target == "_self" %}
<a class="linktosonde" data-sonde="{{ bookmark.item.title }}" href="{{ bookmark.item.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ bookmark.item.target }}{% endif %}">
<a {{datasonde|raw}} href="{{ bookmark.item.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ bookmark.item.target }}{% endif %}">
{% else %}
<a class="linktosonde" data-sonde="{{ bookmark.item.title }}" href="{{ bookmark.item.url|replace({'#login#': username}) }}" target="{{ bookmark.item.target }}">
<a {{datasonde|raw}} href="{{ bookmark.item.url|replace({'#login#': username}) }}" target="{{ bookmark.item.target }}">
{% endif %}
<div class="item-link clearfix">
{% if not bookmark.item.badgeurl is empty %}
<span class="badge badge-primary">3</span>
{% endif %}
<div class="grid-item-logo" title="{{ bookmark.item.subtitle|nl2br }}">
{% if bookmark.item.icon %}
<img class="grid-item-img" src="/{{ alias }}/{{ bookmark.item.icon.label }}">
@ -119,10 +121,12 @@
<div class="grid-item-title">
<h2>{{ bookmark.item.title }}</h2>
<span>{{ bookmark.item.subtitle|nl2br }}</span>
{% if not bookmark.item.badgeurl is empty %}
<div class="itembadgeurl badge badge-pill" data-url="{{bookmark.item.badgeurl}}" style="background-color: #449d44;"></div>
<div style="margin-top:5px;text-align:center;{% if stylegrid == "grid-list"%} float: right;position: absolute;top: 10px;right: -50px; {%endif%}">
<div class="itembadgeurl badge badge-pill" data-url="{{bookmark.item.badgeurl}}" style="background-color: #ffffff; color: {{ bookmark.item.color ? "#"~bookmark.item.color : '#'~colormain }};"></div>
</div>
{% endif %}
<span>{{ bookmark.item.subtitle|nl2br }}</<span>
</div>
</div>
</a>
@ -139,11 +143,11 @@
<a style="cursor:pointer" onClick="delBookmark({{ bookmark.id }})" class="item-heart"><i style="color: #FFF" class="fa fa-trash" title="Supprimer le favori"></i></a>
{% if bookmark.target == 'frame' %}
<a class="linktosonde" data-sonde="{{ bookmark.title }}" style="cursor:pointer" onClick="showFrameitem('bookmark{{ bookmark.id }}','{{ bookmark.url|replace({'#login#': username}) }}')">
<a style="cursor:pointer" onClick="showFrameitem('bookmark{{ bookmark.id }}','{{ bookmark.url|replace({'#login#': username}) }}')">
{% elseif bookmark.target == "_self" %}
<a class="linktosonde" data-sonde="{{ bookmark.title }}" href="{{ bookmark.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ bookmark.target }}{% endif %}">
<a href="{{ bookmark.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ bookmark.target }}{% endif %}">
{% else %}
<a class="linktosonde" data-sonde="{{ bookmark.title }}" href="{{ bookmark.url|replace({'#login#': username}) }}" target="{{ bookmark.target }}">
<a href="{{ bookmark.url|replace({'#login#': username}) }}" target="{{ bookmark.target }}">
{% endif %}
<div class="item-link clearfix">
@ -187,12 +191,17 @@
{% endif %}
{% else %}
{% set datasonde = "" %}
{% if item.clicksonde %}
{% set datasonde = "class='linktosonde' data-sondetitle='"~item.title~"' data-sondeservice='"~item.clicksondeservice~"'" %}
{% endif %}
{% if item.target == 'frame' %}
<a class="linktosonde" data-sonde="{{ item.title }}" style="cursor:pointer" onClick="showFrameitem({{ item.id }},'{{ item.url|replace({'#login#': username}) }}')">
<a {{datasonde|raw}} style="cursor:pointer" onClick="showFrameitem({{ item.id }},'{{ item.url|replace({'#login#': username}) }}')">
{% elseif item.target == "_self" %}
<a class="linktosonde" data-sonde="{{ item.title }}" href="{{ item.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ item.target }}{% endif %}">
<a {{datasonde|raw}} href="{{ item.url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ item.target }}{% endif %}">
{% else %}
<a class="linktosonde" data-sonde="{{ item.title }}" href="{{ item.url|replace({'#login#': username}) }}" target="{{ item.target }}">
<a {{datasonde|raw}} href="{{ item.url|replace({'#login#': username}) }}" target="{{ item.target }}">
{% endif %}
{% endif %}
@ -207,10 +216,12 @@
<div class="grid-item-title">
<h2>{{ item.title }}</h2>
<span>{{ item.subtitle|nl2br }}</span>
{% if not item.badgeurl is empty %}
<div class="itembadgeurl badge badge-pill" data-url="{{item.badgeurl}}" style="background-color: #449d44;"></div>
{% endif %}
<span>{{ item.subtitle|nl2br }}</<span>
<div style="margin-top:5px;text-align:center;{% if stylegrid == "grid-list"%} float: right;position: absolute;top: 10px;right: -50px; {%endif%}">
<div class="itembadgeurl badge badge-pill" data-url="{{item.badgeurl}}" style="background-color: #ffffff; color: {{ item.color ? "#"~item.color : '#'~colormain }};"></div>
</div>
{% endif %}
</div>
</div>
</a>

View File

@ -28,11 +28,11 @@
<div class="widget widget-mini widget-link" data-id="{{ entity.id }}" loc="{{ entity.loc }}">
<div class="widgetheader">
{% if target == 'frame' %}
<a class="linktosonde" data-sonde="{{ entity.name }}" style="cursor:pointer; {{ stylelink }}" onClick="showFrameitem('link{{ entity.id }}','{{ url|replace({'#login#': username}) }}')">
<a style="cursor:pointer; {{ stylelink }}" onClick="showFrameitem('link{{ entity.id }}','{{ url|replace({'#login#': username}) }}')">
{% elseif target == "_self" %}
<a class="linktosonde" data-sonde="{{ entity.name }}" style="{{ stylelink }}"href="{{ url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ target }}{% endif %}">
<a style="{{ stylelink }}"href="{{ url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ target }}{% endif %}">
{% else %}
<a class="linktosonde" data-sonde="{{ entity.name }}" style="{{ stylelink }}" href="{{ url|replace({'#login#': username}) }}" target="{{ target }}">
<a style="{{ stylelink }}" href="{{ url|replace({'#login#': username}) }}" target="{{ target }}">
{% endif %}
{% if entity.icon %}
<img src="/{{ alias }}/{{ entity.icon.label }}" class="logo" title="{{entity.name}}" />
@ -54,11 +54,11 @@
<div class="widgetheader" style="{{ stylewidgetbodyimage }}; height:100%;">
{% if target == 'frame' %}
<a class="linktosonde" data-sonde="{{ entity.name }}" style="cursor:pointer; {{ stylelink }}" onClick="showFrameitem('link{{ entity.id }}','{{ url|replace({'#login#': username}) }}')">
<a style="cursor:pointer; {{ stylelink }}" onClick="showFrameitem('link{{ entity.id }}','{{ url|replace({'#login#': username}) }}')">
{% elseif target == "_self" %}
<a class="linktosonde" data-sonde="{{ entity.name }}" style="{{ stylelink }}"href="{{ url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ target }}{% endif %}">
<a style="{{ stylelink }}"href="{{ url|replace({'#login#': username}) }}" target="{% if access=="user" %}_top{% else %}{{ target }}{% endif %}">
{% else %}
<a class="linktosonde" data-sonde="{{ entity.name }}" style="{{ stylelink }}" href="{{ url|replace({'#login#': username}) }}" target="{{ target }}">
<a style="{{ stylelink }}" href="{{ url|replace({'#login#': username}) }}" target="{{ target }}">
{% endif %}
{% if entity.icon %}
<img src="/{{ alias }}/{{ entity.icon.label }}" style="max-height: 100%; width: auto; display: block; margin: auto; padding-top: 10px;" />

View File

@ -4,7 +4,7 @@
{{ form_start(form) }}
<h1 class="page-header">
{% if mode=="update" %}
Modification Projet
Modification Projet = {{entity.name}}
{% elseif mode=="submit" %}
Création Projet
{% endif %}

View File

@ -51,12 +51,16 @@ class ChatController extends Controller
if(!$group) die();
// Génération d'une clé temporaire d'accès au chat
$key = Uuid::uuid4();
$usergroup=$em->getRepository("CadolesCoreBundle:UserGroup")->findOneBy(["group"=>$group,"user"=>$user]);
$key=null;
if($usergroup) {
$usergroup->setKeyvalue($key);
$em->persist($usergroup);
$em->flush();
$key=$usergroup->getKeyvalue();
if(is_null($key)) {
$key = Uuid::uuid4();
$usergroup->setKeyvalue($key);
$em->persist($usergroup);
$em->flush();
}
}

View File

@ -30,7 +30,7 @@ class ChatType extends AbstractType
'mapped'=> false,
'required' => false,
'attr' => array("class" => "form-control", "style" => "margin-bottom:15px"),
'config' => ["height" => "100px",'filebrowserUploadRoute' => 'cadoles_portal_user_pagewidget_upload',],
'config' => ["height" => "100px"],
]);
$builder
@ -40,7 +40,7 @@ class ChatType extends AbstractType
'mapped'=> false,
'required' => false,
'attr' => array("class" => "form-control", "style" => "margin-bottom:15px"),
'config' => ["height" => "150px",'filebrowserUploadRoute' => 'cadoles_portal_user_pagewidget_upload']
'config' => ["height" => "150px"]
]);
}

View File

@ -362,7 +362,8 @@
function websocket()
{
var _WS_URI = "wss://{{ gos_web_socket_server_host }}:{{ gos_web_socket_server_port }}";
var _WS_URI = "wss://{{ gos_web_socket_server_host }}";
console.log(_WS_URI);
webSocket = WS.connect(_WS_URI,{retryDelay: delayRetry});
webSocket.on("socket/connect", function (sess) {

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.4 KiB

View File

@ -9,23 +9,6 @@ Alias /ninegate /var/www/html/ninegate/web
</Directory>
%if %%getVar("ninegate_activate_websocket", 'non') == "oui"
Listen %%adresse_ip_eth0:%%ninegate_websocket_portexterne
<VirtualHost %%adresse_ip_eth0:%%ninegate_websocket_portexterne>
ErrorLog /var/log/apache2/ssl_error.log
CustomLog /var/log/apache2/ssl_access.log common
SSLEngine on
%if %%cert_type == "letsencrypt"
SSLCertificateFile /etc/ssl/letsencrypt/conf/live/%%ninegate_websocket_url/cert.pem
SSLCertificateKeyFile /etc/ssl/letsencrypt/conf/live/%%ninegate_websocket_url/privkey.pem
%else
SSLCertificateFile %%server_cert
SSLCertificateKeyFile %%server_key
%end if
SSLProtocol all -SSLv3 -SSLv2
ServerName %%ninegate_websocket_url
RewriteEngine On
ProxyPass / ws://%%adresse_ip_eth0:%%ninegate_websocket_portinterne retry=0 keepalive=On
ProxyPassReverse / ws://%%adresse_ip_eth0:%%ninegate_websocket_portinterne retry=0
</VirtualHost>
ProxyPass /wssninegate ws://0.0.0.0:5556 retry=0 keepalive=On
ProxyPassReverse /wssninegate ws://0.0.0.0:5556 retry=0
%end if

View File

@ -67,11 +67,12 @@ INSERT IGNORE INTO `sidebar` (`id`, `parent_id`, `roworder`, `label`, `path`, `f
(3000, NULL, 3000, 'SYNCHRONISATION', NULL, 'fa fa-exchange-alt', 'ROLE_ADMIN,ROLE_MODO', 'syncenvole_activate'),
(3001, 3000, 3001, 'Délégation', 'cadoles_portal_config_syncdelegation', 'fa fa-balance-scale', 'ROLE_ADMIN,ROLE_MODO', 'syncenvole_activate'),
(3110, 3000, 3110, 'Balado', 'cadoles_portal_config_syncbalado', 'fa fa-microphone', 'ROLE_ADMIN,ROLE_MODO', 'widbalado_activate_syncenvole'),
(3112, 3000, 3112, 'CdT', 'cadoles_portal_config_synccdt', 'fa fa-star', 'ROLE_ADMIN,ROLE_MODO', 'widcdt_activate_syncenvole'),
(3115, 3000, 3115, 'GEPI via Annuaire', 'cadoles_portal_config_syncgepiannu', 'fa fa-tags', 'ROLE_ADMIN,ROLE_MODO', 'widgepi_activate_syncenvole'),
(3116, 3000, 3116, 'GEPI via SIECLE', 'cadoles_portal_config_syncgepisiecle', 'fa fa-tags', 'ROLE_ADMIN,ROLE_MODO', 'widgepi_activate_syncenvole'),
(3120, 3000, 3120, 'Limesurvey', 'cadoles_portal_config_synclimesurvey', 'fa fa-question', 'ROLE_ADMIN,ROLE_MODO', 'activate_widlimesurvey'),
(3130, 3000, 3130, 'Moodle', 'cadoles_portal_config_syncmoodle', 'fa fa-graduation-cap', 'ROLE_ADMIN,ROLE_MODO', 'activate_widmoodle'),
(3140, 3000, 3140, 'Nexcloud', 'cadoles_portal_config_syncnextcloud', 'fa fa-cloud', 'ROLE_ADMIN,ROLE_MODO', 'widnextcloud_activate_syncenvole'),
(3140, 3000, 3140, 'Nextcloud', 'cadoles_portal_config_syncnextcloud', 'fa fa-cloud', 'ROLE_ADMIN,ROLE_MODO', 'widnextcloud_activate_syncenvole'),
(3150, 3000, 3150, 'Sacoche via SIECLE', 'cadoles_portal_config_syncsacoche', 'fa fa-suitcase', 'ROLE_ADMIN,ROLE_MODO', 'widsacoche_activate_syncenvole'),
(3160, 3000, 3160, 'Piwik', 'cadoles_portal_config_syncpiwik', 'fa fa-signal', 'ROLE_ADMIN,ROLE_MODO', 'widpiwik_activate_syncenvole'),
(3230, 3000, 3230, 'Wordpress', 'cadoles_portal_config_syncwordpress', 'fab fa-wordpress', 'ROLE_ADMIN,ROLE_MODO', 'activate_widwordpress'),
@ -123,6 +124,7 @@ INSERT IGNORE INTO `config` (`order`, `visible`, `changeable`, `required`, `type
('501', 1, 1, 1, 'permgroup', 'permannu', 'ROLE_USER', '', 'Détermine quel rôle aura la permission de voir l\'annuaire'),
('502', 1, 1, 1, 'boolean', 'permunsubscribe', '0', '', 'Permettre aux utilisateurs de se désinscrire par eux-mêmes des groupes de travail'),
('503', 1, 1, 1, 'boolean', 'fgnotifgroup', '1', '', 'Activer les notifications mails sur les groupes de travail'),
('504', 1, 1, 1, 'integer', 'timerefreshnotif', '20', '', 'Temps en secondes pour rafraîchir les messages de notifications (0 = désactivé)'),
('600', 1, 1, 1, 'string', 'labelbookmarkuser','Favoris', '', 'Titre de la section des items créés par l\'utilisateur, et qui ne sont listés que dans cette section.'),
('601', 1, 1, 1, 'string', 'labelbookmarkitem','Mes Ressources', '', 'Titre de la section des items créés par l\'administrateur ou le modérateur, mis à la disposition de l\'utilisateur, et sélectionnés par ce dernier pour apparaitre dans cette section plutôt que dans leur catégorie d\'origine.');

6
tmpl/ninegate-nginx.conf Normal file
View File

@ -0,0 +1,6 @@
location /wssninegate {
proxy_pass https://%%container_ip_web;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
}

View File

@ -52,14 +52,8 @@ parameters:
%end if
%if %%getVar("ninegate_activate_websocket", 'non') == "oui"
websocket_activate: true
websocket_host: %%ninegate_websocket_url
websocket_port: %%ninegate_websocket_portexterne
websocket_portinterne: %%ninegate_websocket_portinterne
%else
websocket_activate: false
websocket_host: %%web_url
websocket_port: 80
websocket_portinterne: 80
%end if
%if %%getVar("ninegate_activate_portal", 'non') == "oui"
portal_activate: true
@ -133,6 +127,11 @@ parameters:
%else
ldap_tls: false
%end if
%if %%getVar("ninegate_masteridentity", 'SQL') != "SQL"
ldap_user: %%ldap_reader
ldap_password: %%pwdreader("",%%ldap_reader_passfile)
%else
%if %%getVar("activer_admin_passfile", 'non') == "oui"
%if %%getVar("ldap_writer", '') == ""
ldap_user: cn=admin,o=gouv,c=fr
@ -143,6 +142,7 @@ parameters:
%else
ldap_user: %%ldap_reader
ldap_password: %%pwdreader("",%%ldap_reader_passfile)
%end if
%end if
ldap_basedn: %%ldap_base_dn
%if %%getVar("ninegate_ldaptype", 'LDAP') == "AD"
@ -284,6 +284,20 @@ parameters:
widbalado_activate_syncenvole: false
%end if
%if %%getVar("ninegate_activate_widcdt", 'non') == "oui"
activate_widcdt: true
widcdt_url: %%ninegate_widcdt_url
%if %%getVar("poshprofil_typesynchro", "") == "ENT"
widcdt_activate_syncenvole: true
widcdt_syncenvole: %%ninegate_widcdt_syncenvole
%else
widcdt_activate_syncenvole: false
%end if
%else
activate_widcdt: false
widcdt_activate_syncenvole: false
%end if
%if %%getVar("ninegate_activate_widdokuwiki", 'non') == "oui"
activate_widdokuwiki: true
widdokuwiki_url: %%ninegate_widdokuwiki_url
@ -540,6 +554,8 @@ parameters:
cas_host: %%eolesso_adresse
cas_path: %%getVar("eolesso_cas_folder", '')
cas_port: %%eolesso_port
cas_type: %%getVar("ninegate_typesso", 'client')
# Si mode_aut = SAML
saml_entityid: 'http://dev.nuonet.cadoles'
@ -585,6 +601,18 @@ parameters:
noreply: %%ninegate_noreply
%end if
%if %%is_defined('adresse_imap') or %%is_defined('adresse_ip_mail')
active_imapunread: true
%if %%is_defined('adresse_imap')
imapundread_ip: %%adresse_imap
%else
imapundread_ip: %%adresse_ip_mail
%end if
%else
active_imapunread: false
imapunread_ip:
%end if
# Doctrine Configuration
doctrine:
dbal:

View File

@ -1,35 +0,0 @@
<?php
%if %%is_defined('adresse_imap') or %%is_defined('adresse_ip_mail')
require_once('/var/www/html/ninegate/vendor/jasig/phpcas/CAS.php');
require_once('configCAS/cas.inc.php');
// try to configure the phpCAS client
session_name("imapunread");
session_start();
if (__CAS_DEBUG){
phpCAS::setDebug("/var/log/phpcas/phpcas-imap.log");
}
$c= phpCAS::proxy(__CAS_VERSION, __CAS_SERVER, __CAS_PORT, __CAS_FOLDER, false);
phpCAS::setNoClearTicketsFromUrl();
phpCAS::setNoCasServerValidation();
phpCAS::forceAuthentication();
if (__CAS_LOGOUT){
if(method_exists('phpCAS','EoleLogoutRequests')) phpCAS::EoleLogoutRequests(false);
}
%if %%is_defined('adresse_imap')
$a = phpCAS::serviceMail("{%%adresse_imap:993/imap/ssl/novalidate-cert}","imap://%%adresse_imap",0, $errc,$err, phpCAS::retrievePT('imap://%%adresse_imap',$t,$f));
$unseen = imap_status($a, "{%%adresse_imap:993/imap/ssl/novalidate-cert}INBOX", SA_UNSEEN);
%else
$a = phpCAS::serviceMail("{%%adresse_ip_mail:993/imap/ssl/novalidate-cert}","imap://%%adresse_ip_mail",0, $errc,$err, phpCAS::retrievePT('imap://%%adresse_ip_mail',$t,$f));
$unseen = imap_status($a, "{%%adresse_ip_mail:993/imap/ssl/novalidate-cert}INBOX", SA_UNSEEN);
%end if
$count=$unseen->unseen;
echo $count;
%end if
?>

11
tmpl/ninegate.service Normal file
View File

@ -0,0 +1,11 @@
[Unit]
Description=Ninegate websocket server
After=local-fs.target network.target
[Service]
Type=simple
ExecStart=/var/www/html/ninegate/bin/console gos:websocket:server --port 5556 -a 0.0.0.0 --no-debug -n -q --env=prod
Restart=on-watchdog
[Install]
WantedBy=multi-user.target