From 85b74bab2713dcad3cfc502b54ea0027dd08ac22 Mon Sep 17 00:00:00 2001 From: Valentin Samir Date: Thu, 17 Dec 2015 19:24:10 +0100 Subject: [PATCH] Add verbose name for cas_server app and models --- cas_server/__init__.py | 2 + cas_server/apps.py | 7 ++ cas_server/locale/en/LC_MESSAGES/django.mo | Bin 4614 -> 4686 bytes cas_server/locale/en/LC_MESSAGES/django.po | 108 ++++++++++++--------- cas_server/locale/fr/LC_MESSAGES/django.mo | Bin 6033 -> 6235 bytes cas_server/locale/fr/LC_MESSAGES/django.po | 108 ++++++++++++--------- cas_server/models.py | 4 + 7 files changed, 137 insertions(+), 92 deletions(-) create mode 100644 cas_server/apps.py diff --git a/cas_server/__init__.py b/cas_server/__init__.py index 271fe5c..1bb1fa4 100644 --- a/cas_server/__init__.py +++ b/cas_server/__init__.py @@ -8,3 +8,5 @@ # Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. # # (c) 2015 Valentin Samir + +default_app_config = 'cas_server.apps.AppConfig' diff --git a/cas_server/apps.py b/cas_server/apps.py new file mode 100644 index 0000000..bb93d57 --- /dev/null +++ b/cas_server/apps.py @@ -0,0 +1,7 @@ +from django.utils.translation import ugettext_lazy as _ +from django.apps import AppConfig + + +class AppConfig(AppConfig): + name = 'cas_server' + verbose_name = _('Central Authentication Service') diff --git a/cas_server/locale/en/LC_MESSAGES/django.mo b/cas_server/locale/en/LC_MESSAGES/django.mo index 9f500a4a8ccd65f8de3db288ce0723d5b3aef054..c0307293f448d41231addb4d5814e60949c7e20f 100644 GIT binary patch delta 1137 zcmZA0Pe{{Y9LMqR*4CV@&8>gaw6*Q_{1_jOz z(IqK}x{eM(mz})Tr9+pBAoSQFiinWjpWp8ZqAz=Xujlz~kH6>n{2pg>Z*tX-sn7$X z^0ao^Lcr_<#@2A5(jl|W*oytQACKZS=QBLOcp00pBW$(}J5lonF@ zYKwF<;T>+oZ+HZo)|&CLAuimqQ*Jzh2N{pzVXR>Q=<@ghD%KK7FfQ!Nnn$5GV06vi=) z`o0T`Jm2zk_Tm-PAHI)eUc&-v<-eN!=#%UG=!czmP|+{paa=_uc`WA7yM&7VmK)EZ zqF+R!x7S$Jgs*hEF;0GpzJy=!HfrS;ST?EJI4b(GB`=cqCV^LcWu3G zZC>r<8l-9AO8akhsH69vqbVNkRHZ~zycO^LY2{hn_@}gJ6-UIjdOiPCtE=c$Y1$r| zl2mDftzOS;6Yij8^xpK&bn!Xy1LeC=Gs<^q$rhHY=aYiIA`wCaK^I{=gp^mY4$;M;@9)jq$G-WzH?uSIf4{f;Irl6VeoHs38m&O@ zq(84SyM~7W2inhivy=D>hq1B2>^hEnL%hm-6C3e2cHuwNeVLe98i!ExJ9q}Cv1k_B z5(C}v22bE8Q~|qq1iLsev|iLa&tU|MIEIf=#joQr+`)^uhgwiN9=-Sy9%o*{A$)}0 zyx*1?=*926A5bf)q8|JmRX~c9EXvyPHg@7PmXVKbap0@=(a*o2?)!?(xa+SUpbGed z1H9h`6VZbo;4JY^p`v=9j3Te1B2P6%-a|#cj1#zxN-%LWy00G<`3*mxL`6Q2L~c(} z-`~J6&tQjvA`i%K5696(PT8brd32GZiyRA_Uq=@?y2#N*-r^(2SA4I8T5%P-vAH!$ zywFPiivAWSNW&hY9$fbGm#E0sP?5hzMgGHIpGZZK-$mVjA657iQj5*_>x-xYmT&;y z;viO2\n" "Language-Team: django \n" "Language: en\n" @@ -17,6 +17,10 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "X-Generator: Poedit 1.8.6\n" +#: apps.py:7 templates/cas_server/base.html:3 +msgid "Central Authentication Service" +msgstr "Central Authentication Service" + #: forms.py:23 msgid "login" msgstr "username" @@ -45,101 +49,117 @@ msgstr "Clean deleted sessions" msgid "Clean old trickets" msgstr "Clean old trickets" -#: models.py:90 +#: models.py:42 +msgid "User" +msgstr "" + +#: models.py:43 +msgid "Users" +msgstr "" + +#: models.py:101 #, python-format msgid "Error during service logout %s" msgstr "Error during service logout %s" -#: models.py:160 +#: models.py:169 +msgid "Service pattern" +msgstr "Service pattern" + +#: models.py:170 +msgid "Services patterns" +msgstr "" + +#: models.py:174 msgid "position" msgstr "position" -#: models.py:167 models.py:271 +#: models.py:181 models.py:303 msgid "name" msgstr "name" -#: models.py:168 +#: models.py:182 msgid "A name for the service" msgstr "A name for the service" -#: models.py:173 models.py:299 models.py:317 +#: models.py:187 models.py:331 models.py:349 msgid "pattern" msgstr "pattern" -#: models.py:175 +#: models.py:189 msgid "" "A regular expression matching services. Will usually looks like '^https://" "some\\.server\\.com/path/.*$'.As it is a regular expression, special " "character must be escaped with a '\\'." msgstr "" -#: models.py:184 +#: models.py:198 msgid "user field" msgstr "" -#: models.py:185 +#: models.py:199 msgid "Name of the attribut to transmit as username, empty = login" msgstr "Name of the attribut to transmit as username, empty = login" -#: models.py:189 +#: models.py:203 msgid "restrict username" msgstr "" -#: models.py:190 +#: models.py:204 msgid "Limit username allowed to connect to the list provided bellow" msgstr "Limit username allowed to connect to the list provided bellow" -#: models.py:194 +#: models.py:208 msgid "proxy" msgstr "proxy" -#: models.py:195 +#: models.py:209 msgid "Proxy tickets can be delivered to the service" msgstr "Proxy tickets can be delivered to the service" -#: models.py:199 +#: models.py:213 msgid "proxy callback" msgstr "proxy callback" -#: models.py:200 +#: models.py:214 msgid "can be used as a proxy callback to deliver PGT" msgstr "can be used as a proxy callback to deliver PGT" -#: models.py:204 +#: models.py:218 msgid "single log out" msgstr "" -#: models.py:205 +#: models.py:219 msgid "Enable SLO for the service" msgstr "Enable SLO for the service" -#: models.py:212 +#: models.py:226 msgid "single log out callback" msgstr "" -#: models.py:213 +#: models.py:227 msgid "" "URL where the SLO request will be POST. empty = service url\n" "This is usefull for non HTTP proxied services." msgstr "" -#: models.py:256 +#: models.py:288 msgid "username" msgstr "" -#: models.py:257 +#: models.py:289 msgid "username allowed to connect to the service" msgstr "username allowed to connect to the service" -#: models.py:272 +#: models.py:304 msgid "name of an attribut to send to the service, use * for all attributes" msgstr "name of an attribut to send to the service, use * for all attributes" -#: models.py:277 models.py:323 +#: models.py:309 models.py:355 msgid "replace" msgstr "replace" -#: models.py:278 +#: models.py:310 msgid "" "name under which the attribut will be showto the service. empty = default " "name of the attribut" @@ -147,31 +167,31 @@ msgstr "" "name under which the attribut will be showto the service. empty = default " "name of the attribut" -#: models.py:294 models.py:312 +#: models.py:326 models.py:344 msgid "attribut" msgstr "attribut" -#: models.py:295 +#: models.py:327 msgid "Name of the attribut which must verify pattern" msgstr "Name of the attribut which must verify pattern" -#: models.py:300 +#: models.py:332 msgid "a regular expression" msgstr "a regular expression" -#: models.py:313 +#: models.py:345 msgid "Name of the attribut for which the value must be replace" msgstr "Name of the attribut for which the value must be replace" -#: models.py:318 +#: models.py:350 msgid "An regular expression maching whats need to be replaced" msgstr "An regular expression maching whats need to be replaced" -#: models.py:324 +#: models.py:356 msgid "replace expression, groups are capture by \\1, \\2 …" msgstr "replace expression, groups are capture by \\1, \\2 …" -#: models.py:416 +#: models.py:463 #, python-format msgid "" "Error during service logout %(service)s:\n" @@ -180,10 +200,6 @@ msgstr "" "Error during service logout %(service)s:\n" "%(error)s" -#: templates/cas_server/base.html:3 -msgid "Central Authentication Service" -msgstr "Central Authentication Service" - #: templates/cas_server/logged.html:6 msgid "Logged" msgstr "" @@ -208,7 +224,7 @@ msgstr "Please loggin" msgid "Login" msgstr "Login" -#: templates/cas_server/logout.html:6 views.py:112 +#: templates/cas_server/logout.html:6 views.py:123 msgid "Successfully logout" msgstr "" "

Logout successful

You have successfully logged out of the Central " @@ -218,44 +234,44 @@ msgstr "" msgid "Connect to the service" msgstr "Connect to the service" -#: views.py:186 +#: views.py:197 msgid "Invalid login ticket" msgstr "Invalid login ticket, please retry to login" -#: views.py:277 +#: views.py:292 #, python-format msgid "Authentication has been required by service %(name)s (%(url)s)" msgstr "Authentication has been required by service %(name)s (%(url)s)" -#: views.py:311 +#: views.py:326 #, python-format msgid "Service %(url)s non allowed." msgstr "Service %(url)s non allowed." -#: views.py:318 +#: views.py:333 msgid "Username non allowed" msgstr "Username non allowed" -#: views.py:325 +#: views.py:340 msgid "User charateristics non allowed" msgstr "User charateristics non allowed" -#: views.py:332 +#: views.py:347 #, python-format msgid "The attribut %(field)s is needed to use that service" msgstr "The attribut %(field)s is needed to use that service" -#: views.py:397 +#: views.py:417 #, python-format msgid "Authentication renewal required by service %(name)s (%(url)s)." msgstr "Authentication renewal required by service %(name)s (%(url)s)." -#: views.py:404 +#: views.py:424 #, python-format msgid "Authentication required by service %(name)s (%(url)s)." msgstr "Authentication required by service %(name)s (%(url)s)." -#: views.py:411 +#: views.py:431 #, python-format msgid "Service %s non allowed" msgstr "Service %s non allowed" diff --git a/cas_server/locale/fr/LC_MESSAGES/django.mo b/cas_server/locale/fr/LC_MESSAGES/django.mo index 1fde40547b310a31bfa1063f6674fac28e6f8c42..d1fab0f2a272ded8037f81355d78e55f7d459e4d 100644 GIT binary patch delta 1414 zcmZY9OGs2v9LMqh*p!-<`Is!z8q@6M_!u20wG?`g1Sz6IZ3N8`6iIQ$7DX5>qn8Xu zg;=2k(I%P}xd^IFxTqEpWlBhkf}m(oi>RpYZ@hxgf&YB&xz}^<|NPInj+D-p4ZqKD zj~ZV@G@@1YpC%LF#}&Z z{STO9Hf%q+@be%mabdtg%%b0od+-!)!YSlWZ3cO#%{%>%sN}z3Ef(?i670lPID$UB zfm+~mR6?IIjrW@?*({wK>6nQHScyUG#Xe-w_6C*694f)zs6^6NF7&gJIjtC#Kmhf; z3pKtM_hUb{;{#0M{g#J>Y zv7IkaD{iM8UvUVPNY`rW-^|4wF81OtR0-?S7WyY~GyO-HkMqc$S;88#Y|O(v3}6$s z;BK72eK?Otu#l{a@HDzeXc8%&-Oix?%xU*H85;N)yYLV0#7_3ZgBLM?leiV%p%O}9 zA9#lqB10^Icd-Gr!tZzitC@r%*fZ3;uh5HsJ=8yy3orH2%6zC&Hed}lqXwQweGpgi z5RN&1LXG!R4sBUIYWxAG--vqNiuKrmIzzWmTmEF23#wt$jwMkt&O*0$3?UVuha26>g)^$`B6#O`v00rT}tRMB@oJ3$!SG}gg(b| zLX{~Y)ReTEs-Ufne<8>^Y#X8TMA72s!KV*F`>4ZEMX;^5o>0?vY$5bdBtWR?u&J@F z@qLeXmi$z3y}{}0OURB5xqWVLXz)bOv59=Dc-et7XlIC?W_D%zS{mDm;z z4Th~FI^xcZjVJ$bB?i6a)iwU|==GF*=h`28n({ia;BbGWr`y{V@-jk`Tl_|N$(?ZQ gO6D0?N?W9-uP59Q2@MTKJ)XwYCH-)$(^H!84-;;gPXGV_ delta 1219 zcmYk*T}YEr9LMqhW6QVfWlm?NrZ#KUa&EI1GfUE-2t+~x0|}xoBIxC2kO(azEC!-6 zVsusAgb)O^B8aZK@G_{7T|^OeQ3OR@NOTeP{XIK_4m;21oafnj&N=`8dEO>&^km-G z2W}c=JGGVi+%r3f6U(?zE(XlPIEjyN4tL@3aHo%ROjMe!$K9y$<5-X9 zUH=NMGt1a58Yvz;Mh*Ck4Om%awijEl9giW8Y!aEnF1!9T_R*igJ-C2ztY8%@F^Szc zh}z&;)Pk}YVt%_zL%V;1XYea(!lN~%g`}NXWK(eVzYrk*w8v2qZK3Myka9mF6&Rsve)G=&k{0WtD)eiq%BjMt9O}~~3r33l z65zVgwVR##+z5nU6it;RRcAp_Qqd>;Unvv=u|Te?=4tLjP0~A&`xyuoVzo\n" "Language-Team: django \n" "Language: fr\n" @@ -18,6 +18,10 @@ msgstr "" "Plural-Forms: nplurals=2; plural=(n > 1);\n" "X-Generator: Poedit 1.8.6\n" +#: apps.py:7 templates/cas_server/base.html:3 +msgid "Central Authentication Service" +msgstr "Service Central d'Authentification" + #: forms.py:23 msgid "login" msgstr "Identifiant" @@ -46,28 +50,44 @@ msgstr "Nettoyer les sessions supprimées" msgid "Clean old trickets" msgstr "Nettoyer les vieux tickets" -#: models.py:90 +#: models.py:42 +msgid "User" +msgstr "Utilisateur" + +#: models.py:43 +msgid "Users" +msgstr "Utilisateurs" + +#: models.py:101 #, python-format msgid "Error during service logout %s" msgstr "Une erreur est survenue durant la déconnexion du service %s" -#: models.py:160 +#: models.py:169 +msgid "Service pattern" +msgstr "Motif de service" + +#: models.py:170 +msgid "Services patterns" +msgstr "Motifs de services" + +#: models.py:174 msgid "position" msgstr "position" -#: models.py:167 models.py:271 +#: models.py:181 models.py:303 msgid "name" msgstr "nom" -#: models.py:168 +#: models.py:182 msgid "A name for the service" msgstr "Un nom pour le service" -#: models.py:173 models.py:299 models.py:317 +#: models.py:187 models.py:331 models.py:349 msgid "pattern" msgstr "motif" -#: models.py:175 +#: models.py:189 msgid "" "A regular expression matching services. Will usually looks like '^https://" "some\\.server\\.com/path/.*$'.As it is a regular expression, special " @@ -78,55 +98,55 @@ msgstr "" "expression rationnelle, les caractères spéciaux doivent être échappés avec " "un '\\'." -#: models.py:184 +#: models.py:198 msgid "user field" msgstr "champ utilisateur" -#: models.py:185 +#: models.py:199 msgid "Name of the attribut to transmit as username, empty = login" msgstr "" "Nom de l'attribut devant être transmis comme nom d'utilisateur au service. " "vide = nom de connection" -#: models.py:189 +#: models.py:203 msgid "restrict username" msgstr "limiter les noms d'utilisateurs" -#: models.py:190 +#: models.py:204 msgid "Limit username allowed to connect to the list provided bellow" msgstr "" "Limiter les noms d'utilisateurs autorisé à se connecter à la liste fournie " "ci-dessous" -#: models.py:194 +#: models.py:208 msgid "proxy" msgstr "proxy" -#: models.py:195 +#: models.py:209 msgid "Proxy tickets can be delivered to the service" msgstr "des proxy tickets peuvent être délivrés au service" -#: models.py:199 +#: models.py:213 msgid "proxy callback" msgstr "" -#: models.py:200 +#: models.py:214 msgid "can be used as a proxy callback to deliver PGT" msgstr "peut être utilisé comme un callback pour recevoir un PGT" -#: models.py:204 +#: models.py:218 msgid "single log out" msgstr "" -#: models.py:205 +#: models.py:219 msgid "Enable SLO for the service" msgstr "Active le SLO pour le service" -#: models.py:212 +#: models.py:226 msgid "single log out callback" msgstr "" -#: models.py:213 +#: models.py:227 msgid "" "URL where the SLO request will be POST. empty = service url\n" "This is usefull for non HTTP proxied services." @@ -135,55 +155,55 @@ msgstr "" "service\n" "Ceci n'est utilise que pour des services non HTTP proxifiés" -#: models.py:256 +#: models.py:288 msgid "username" msgstr "nom d'utilisateur" -#: models.py:257 +#: models.py:289 msgid "username allowed to connect to the service" msgstr "noms d'utilisateurs autorisé à se connecter au service" -#: models.py:272 +#: models.py:304 msgid "name of an attribut to send to the service, use * for all attributes" msgstr "" "nom d'un attribut a envoyer au service, utiliser * pour tous les attributs" -#: models.py:277 models.py:323 +#: models.py:309 models.py:355 msgid "replace" msgstr "remplacement" -#: models.py:278 +#: models.py:310 msgid "" "name under which the attribut will be showto the service. empty = default " "name of the attribut" msgstr "" "nom sous lequel l'attribut sera rendu visible au service. vide = inchangé" -#: models.py:294 models.py:312 +#: models.py:326 models.py:344 msgid "attribut" msgstr "attribut" -#: models.py:295 +#: models.py:327 msgid "Name of the attribut which must verify pattern" msgstr "Nom de l'attribut devant vérifier un motif" -#: models.py:300 +#: models.py:332 msgid "a regular expression" msgstr "une expression régulière" -#: models.py:313 +#: models.py:345 msgid "Name of the attribut for which the value must be replace" msgstr "nom de l'attribue pour lequel la valeur doit être remplacé" -#: models.py:318 +#: models.py:350 msgid "An regular expression maching whats need to be replaced" msgstr "une expression régulière reconnaissant ce qui doit être remplacé" -#: models.py:324 +#: models.py:356 msgid "replace expression, groups are capture by \\1, \\2 …" msgstr "expression de remplacement, les groupe sont capturé par \\1, \\2" -#: models.py:416 +#: models.py:463 #, python-format msgid "" "Error during service logout %(service)s:\n" @@ -192,10 +212,6 @@ msgstr "" "Une erreur est survenue durant la déconnexion du service %(service)s:" "%(error)s" -#: templates/cas_server/base.html:3 -msgid "Central Authentication Service" -msgstr "Service Central d'Authentification" - #: templates/cas_server/logged.html:6 msgid "Logged" msgstr "" @@ -220,7 +236,7 @@ msgstr "Merci de se connecter" msgid "Login" msgstr "Connexion" -#: templates/cas_server/logout.html:6 views.py:112 +#: templates/cas_server/logout.html:6 views.py:123 msgid "Successfully logout" msgstr "" "

Déconnexion réussie

\n" @@ -231,46 +247,46 @@ msgstr "" msgid "Connect to the service" msgstr "Se connecter au service" -#: views.py:186 +#: views.py:197 msgid "Invalid login ticket" msgstr "Ticket de connexion invalide, merci de réessayé de vous connecter" -#: views.py:277 +#: views.py:292 #, python-format msgid "Authentication has been required by service %(name)s (%(url)s)" msgstr "" "Une demande d'authentification a été émise pour le service %(name)s " "(%(url)s)." -#: views.py:311 +#: views.py:326 #, python-format msgid "Service %(url)s non allowed." msgstr "le service %(url)s n'est pas autorisé." -#: views.py:318 +#: views.py:333 msgid "Username non allowed" msgstr "Nom d'utilisateur non authorisé" -#: views.py:325 +#: views.py:340 msgid "User charateristics non allowed" msgstr "Caractéristique utilisateur non autorisée" -#: views.py:332 +#: views.py:347 #, python-format msgid "The attribut %(field)s is needed to use that service" msgstr "L'attribut %(field)s est nécessaire pour se connecter à ce service" -#: views.py:397 +#: views.py:417 #, python-format msgid "Authentication renewal required by service %(name)s (%(url)s)." msgstr "Demande de réauthentification pour le service %(name)s (%(url)s)." -#: views.py:404 +#: views.py:424 #, python-format msgid "Authentication required by service %(name)s (%(url)s)." msgstr "Authentification requise par le service %(name)s (%(url)s)." -#: views.py:411 +#: views.py:431 #, python-format msgid "Service %s non allowed" msgstr "Le service %s n'est pas autorisé" diff --git a/cas_server/models.py b/cas_server/models.py index 8997f4c..50740f4 100644 --- a/cas_server/models.py +++ b/cas_server/models.py @@ -39,6 +39,8 @@ class User(models.Model): """A user logged into the CAS""" class Meta: unique_together = ("username", "session_key") + verbose_name = _("User") + verbose_name_plural = _("Users") session_key = models.CharField(max_length=40, blank=True, null=True) username = models.CharField(max_length=30) date = models.DateTimeField(auto_now=True) @@ -164,6 +166,8 @@ class ServicePattern(models.Model): """Allowed services pattern agains services are tested to""" class Meta: ordering = ("pos", ) + verbose_name = _("Service pattern") + verbose_name_plural = _("Services patterns") pos = models.IntegerField( default=100,