added categories to forms; forms without categories are merged in 'misc'

This commit is contained in:
Frédéric Péters 2005-05-19 22:10:22 +00:00
parent 8b88d1d78e
commit 44c4a5d359
10 changed files with 890 additions and 569 deletions

655
po/fr.po
View File

@ -2,7 +2,7 @@ msgid ""
msgstr ""
"Project-Id-Version: wcs 0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2005-05-19 16:00+0200\n"
"POT-Creation-Date: 2005-05-20 00:07+0200\n"
"PO-Revision-Date: 2005-04-29 12:27+0200\n"
"Last-Translator: Frederic Peters <fpeters@entrouvert.com>\n"
"Language-Team: french\n"
@ -11,166 +11,17 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n>1;\n"
#: ../wcs/admin/users.ptl:32 ../wcs/admin/users.ptl:49
msgid "User Id"
msgstr "Identifiant de l'utilisateur"
#: ../wcs/form.py:6
msgid "required field"
msgstr "champ obligatoire"
#: ../wcs/admin/users.ptl:34 ../wcs/admin/users.ptl:51
msgid "User Name"
msgstr "Nom de l'utilisateur"
#: ../wcs/admin/users.ptl:36 ../wcs/admin/users.ptl:53
msgid "Email"
msgstr "Email"
#: ../wcs/admin/users.ptl:38 ../wcs/admin/users.ptl:55 ../wcs/admin/menu.ptl:6
msgid "Roles"
msgstr "Rôles"
#: ../wcs/admin/users.ptl:39 ../wcs/admin/users.ptl:56
msgid "Add Role"
msgstr "Ajouter un rôle"
#: ../wcs/admin/users.ptl:43 ../wcs/admin/users.ptl:61
#: ../wcs/admin/users.ptl:97 ../wcs/admin/settings.ptl:53
#: ../wcs/admin/settings.ptl:125 ../wcs/admin/settings.ptl:141
#: ../wcs/admin/forms.ptl:72 ../wcs/admin/forms.ptl:105
#: ../wcs/admin/forms.ptl:234 ../wcs/admin/roles.ptl:28
#: ../wcs/admin/roles.ptl:38 ../wcs/admin/roles.ptl:73
msgid "Submit"
msgstr "Valider"
#: ../wcs/admin/users.ptl:44 ../wcs/admin/users.ptl:60
#: ../wcs/admin/users.ptl:96 ../wcs/admin/users.ptl:111
#: ../wcs/admin/settings.ptl:142 ../wcs/admin/forms.ptl:73
#: ../wcs/admin/forms.ptl:106 ../wcs/admin/forms.ptl:235
#: ../wcs/admin/roles.ptl:29 ../wcs/admin/roles.ptl:39
#: ../wcs/admin/roles.ptl:74
msgid "Cancel"
msgstr "Annuler"
#: ../wcs/admin/users.ptl:83 ../wcs/admin/users.ptl:84
msgid "Edit User"
msgstr "Éditer l'utilisateur"
#: ../wcs/admin/users.ptl:95
msgid "You are about to irrevocably delete this user."
msgstr "Vous allez définitivement supprimer cet utilisateur."
#: ../wcs/admin/users.ptl:101
msgid "Delete User"
msgstr "Supprimer l'utilisateur"
#: ../wcs/admin/users.ptl:102
msgid "Deleting User:"
msgstr "Suppression de l'utilisateur :"
#: ../wcs/admin/users.ptl:112
msgid "Generate"
msgstr "Générer"
#: ../wcs/admin/users.ptl:118 ../wcs/admin/users.ptl:119
#: ../wcs/admin/users.ptl:127 ../wcs/admin/users.ptl:167
msgid "Identification Token"
msgstr "Jeton d'identification"
#: ../wcs/admin/users.ptl:122
#, python-format
msgid "Note that user has already been issued an identification token: %s"
msgstr "À noter que l'utilisateur a déjà un jeton d'identification : %s"
#: ../wcs/admin/users.ptl:133
#, python-format
msgid "Identification Token for %s:"
msgstr "Jeton d'identification pour %s :"
#: ../wcs/admin/users.ptl:137
msgid "Done"
#: ../wcs/form.py:10
msgid "There were errors processing your form. See below for details."
msgstr ""
"Il y a eu un problème à la soumission du formulaire. Regardez ci-dessous "
"pour le détail."
#: ../wcs/admin/users.ptl:139
msgid "Send by email"
msgstr "Envoyer par email"
#: ../wcs/admin/users.ptl:157 ../wcs/admin/settings.ptl:27
#: ../wcs/admin/forms.ptl:268 ../wcs/admin/roles.ptl:96
msgid "New"
msgstr "Nouveau"
#: ../wcs/admin/users.ptl:168 ../wcs/admin/settings.ptl:38
#: ../wcs/admin/forms.ptl:166 ../wcs/admin/forms.ptl:278
#: ../wcs/admin/roles.ptl:103
msgid "Edit"
msgstr "Modifier"
#: ../wcs/admin/users.ptl:169 ../wcs/admin/settings.ptl:39
#: ../wcs/admin/forms.ptl:280 ../wcs/admin/roles.ptl:104
msgid "Delete"
msgstr "Supprimer"
#: ../wcs/admin/users.ptl:181 ../wcs/admin/users.ptl:182
msgid "New User"
msgstr "Nouvel utilisateur"
#: ../wcs/forms/root.ptl:49 ../wcs/forms/root.ptl:71 ../wcs/forms/root.ptl:157
#, python-format
msgid "The form has been recorded on %s with the number %s."
msgstr "Le formulaire a été enregistré le %s avec le numéro %s."
#: ../wcs/forms/root.ptl:53
msgid "Your case is handled by:"
msgstr "Votre dossier est pris en charge par :"
#: ../wcs/forms/root.ptl:64 ../wcs/forms/root.ptl:79 ../wcs/forms/root.ptl:174
msgid "Back Home"
msgstr "Retour à l'accueil"
#: ../wcs/forms/root.ptl:95
msgid "Filling"
msgstr "Je remplis ma demande"
#: ../wcs/forms/root.ptl:95
msgid "Validating"
msgstr "Je confirme ma demande"
#: ../wcs/forms/root.ptl:95
msgid "Receipt"
msgstr "Justificatif"
#: ../wcs/forms/root.ptl:105 ../wcs/forms/root.ptl:116
#: ../wcs/forms/root.ptl:146
msgid "Next"
msgstr "Suivant"
#: ../wcs/forms/root.ptl:115 ../wcs/forms/root.ptl:145
msgid "Previous"
msgstr "Précédent"
#: ../wcs/forms/root.ptl:142
msgid "Check values then click next."
msgstr "Vérifiez le contenu du formulaire puis cliquer sur 'Suivant'"
#: ../wcs/forms/root.ptl:161
msgid "Your case will be handled by:"
msgstr "Votre dossier sera pris en charge par :"
#: ../wcs/forms/root.ptl:187 ../wcs/admin/menu.ptl:4
msgid "Forms"
msgstr "Formulaires"
#: ../wcs/forms/root.ptl:207
msgid "Your Current Forms"
msgstr "Vos formulaires en cours"
#: ../wcs/forms/root.ptl:215
msgid "Logout"
msgstr "Se déconnecter"
#: ../wcs/forms/root.ptl:218
msgid "Login"
msgstr "S'identifier"
#: ../wcs/formdef.py:81
#: ../wcs/formdef.py:86
#, python-format
msgid ""
"Hi,\n"
@ -184,19 +35,293 @@ msgstr ""
"prendre connaissance en suivant ce lien :\n"
"%(url)s\n"
#: ../wcs/formdef.py:92
#: ../wcs/formdef.py:97
msgid "A new form has been submitted"
msgstr "Un nouveau formulaire a été enregistré"
#: ../wcs/form.py:6
msgid "required field"
msgstr "champ obligatoire"
#: ../wcs/forms/root.ptl:48 ../wcs/forms/root.ptl:70 ../wcs/forms/root.ptl:173
#, python-format
msgid "The form has been recorded on %s with the number %s."
msgstr "Le formulaire a été enregistré le %s avec le numéro %s."
#: ../wcs/form.py:10
msgid "There were errors processing your form. See below for details."
#: ../wcs/forms/root.ptl:52
msgid "Your case is handled by:"
msgstr "Votre dossier est pris en charge par :"
#: ../wcs/forms/root.ptl:63 ../wcs/forms/root.ptl:78 ../wcs/forms/root.ptl:190
msgid "Back Home"
msgstr "Retour à l'accueil"
#: ../wcs/forms/root.ptl:111
msgid "Filling"
msgstr "Je remplis ma demande"
#: ../wcs/forms/root.ptl:111
msgid "Validating"
msgstr "Je confirme ma demande"
#: ../wcs/forms/root.ptl:111
msgid "Receipt"
msgstr "Justificatif"
#: ../wcs/forms/root.ptl:121 ../wcs/forms/root.ptl:132
#: ../wcs/forms/root.ptl:162
msgid "Next"
msgstr "Suivant"
#: ../wcs/forms/root.ptl:131 ../wcs/forms/root.ptl:161
msgid "Previous"
msgstr "Précédent"
#: ../wcs/forms/root.ptl:158
msgid "Check values then click next."
msgstr "Vérifiez le contenu du formulaire puis cliquer sur 'Suivant'"
#: ../wcs/forms/root.ptl:177
msgid "Your case will be handled by:"
msgstr "Votre dossier sera pris en charge par :"
#: ../wcs/forms/root.ptl:203 ../wcs/forms/root.ptl:293 ../wcs/admin/menu.ptl:4
msgid "Forms"
msgstr "Formulaires"
#: ../wcs/forms/root.ptl:209
#, python-format
msgid "You are logged in as %s."
msgstr ""
"Il y a eu un problème à la soumission du formulaire. Regardez ci-dessous "
"pour le détail."
#: ../wcs/forms/root.ptl:243
msgid "Misc"
msgstr "Divers"
#: ../wcs/forms/root.ptl:261
msgid "Your Current Forms"
msgstr "Vos formulaires en cours"
#: ../wcs/forms/root.ptl:271
#, fuzzy
msgid "Enter Identification Token"
msgstr "Jeton d'identification"
#: ../wcs/forms/root.ptl:272
msgid "Logout"
msgstr "Se déconnecter"
#: ../wcs/forms/root.ptl:275
msgid "Login"
msgstr "S'identifier"
#: ../wcs/forms/root.ptl:284 ../wcs/admin/users.ptl:118
#: ../wcs/admin/users.ptl:119 ../wcs/admin/users.ptl:127
#: ../wcs/admin/users.ptl:167
msgid "Identification Token"
msgstr "Jeton d'identification"
#: ../wcs/forms/root.ptl:286 ../wcs/admin/forms.ptl:94
#: ../wcs/admin/forms.ptl:127 ../wcs/admin/forms.ptl:255
#: ../wcs/admin/roles.ptl:29 ../wcs/admin/roles.ptl:39
#: ../wcs/admin/roles.ptl:74 ../wcs/admin/settings.ptl:142
#: ../wcs/admin/users.ptl:44 ../wcs/admin/users.ptl:60
#: ../wcs/admin/users.ptl:96 ../wcs/admin/users.ptl:111
#: ../wcs/admin/categories.ptl:29 ../wcs/admin/categories.ptl:39
#: ../wcs/admin/categories.ptl:74
msgid "Cancel"
msgstr "Annuler"
#: ../wcs/forms/root.ptl:287 ../wcs/admin/forms.ptl:93
#: ../wcs/admin/forms.ptl:126 ../wcs/admin/forms.ptl:254
#: ../wcs/admin/roles.ptl:28 ../wcs/admin/roles.ptl:38
#: ../wcs/admin/roles.ptl:73 ../wcs/admin/settings.ptl:53
#: ../wcs/admin/settings.ptl:125 ../wcs/admin/settings.ptl:141
#: ../wcs/admin/users.ptl:43 ../wcs/admin/users.ptl:61
#: ../wcs/admin/users.ptl:97 ../wcs/admin/categories.ptl:28
#: ../wcs/admin/categories.ptl:38 ../wcs/admin/categories.ptl:73
msgid "Submit"
msgstr "Valider"
#: ../wcs/forms/root.ptl:295
msgid "Bla bla bla"
msgstr ""
#: ../wcs/admin/forms.ptl:37
msgid "Text (line)"
msgstr "Texte (ligne)"
#: ../wcs/admin/forms.ptl:38
msgid "Text (block)"
msgstr "Bloc de texte"
#: ../wcs/admin/forms.ptl:39
msgid "Boolean"
msgstr "Booléen"
#: ../wcs/admin/forms.ptl:40
msgid "Item from list"
msgstr "Élément d'une liste"
#: ../wcs/admin/forms.ptl:41
msgid "Title"
msgstr "Titre"
#: ../wcs/admin/forms.ptl:42
msgid "Subtitle"
msgstr "Sous-titre"
#: ../wcs/admin/forms.ptl:74
msgid "Form Id"
msgstr "Identifiant du formulaire"
#: ../wcs/admin/forms.ptl:76
msgid "Form Name"
msgstr "Nom du formulaire"
#: ../wcs/admin/forms.ptl:78 ../wcs/admin/forms.ptl:299
msgid "Fields"
msgstr "Champs"
#: ../wcs/admin/forms.ptl:79
msgid "Add Field"
msgstr "Ajouter un champ"
#: ../wcs/admin/forms.ptl:81
msgid "Recipient"
msgstr "Destinataire"
#: ../wcs/admin/forms.ptl:83
msgid "Recipient Email"
msgstr "Adresse email du destinataire"
#: ../wcs/admin/forms.ptl:85 ../wcs/admin/menu.ptl:6 ../wcs/admin/users.ptl:38
#: ../wcs/admin/users.ptl:55
msgid "Roles"
msgstr "Rôles"
#: ../wcs/admin/forms.ptl:86
msgid "Only show this form to the given roles."
msgstr ""
#: ../wcs/admin/forms.ptl:87 ../wcs/admin/users.ptl:39
#: ../wcs/admin/users.ptl:56
msgid "Add Role"
msgstr "Ajouter un rôle"
#: ../wcs/admin/forms.ptl:90
msgid "Category"
msgstr "Catégorie"
#: ../wcs/admin/forms.ptl:113
msgid "Name"
msgstr "Nom"
#: ../wcs/admin/forms.ptl:115
msgid "Type"
msgstr "Type"
#: ../wcs/admin/forms.ptl:118
msgid "Required"
msgstr "Obligatoire"
#: ../wcs/admin/forms.ptl:122
msgid "Items"
msgstr "Éléments"
#: ../wcs/admin/forms.ptl:185
msgid "optional"
msgstr ""
#: ../wcs/admin/forms.ptl:187 ../wcs/admin/forms.ptl:298
#: ../wcs/admin/roles.ptl:103 ../wcs/admin/settings.ptl:38
#: ../wcs/admin/users.ptl:168 ../wcs/admin/categories.ptl:103
msgid "Edit"
msgstr "Modifier"
#: ../wcs/admin/forms.ptl:197
msgid "Export to CSV format"
msgstr "Exporter au format CSV"
#: ../wcs/admin/forms.ptl:241 ../wcs/admin/forms.ptl:242
msgid "Edit Form"
msgstr "Éditer le formulaire"
#: ../wcs/admin/forms.ptl:253
msgid "You are about to irrevocably delete this form."
msgstr "Vous allez définitivement supprimer ce formulaire."
#: ../wcs/admin/forms.ptl:259
msgid "Delete Form"
msgstr "Supprimer le formulaire"
#: ../wcs/admin/forms.ptl:260
msgid "Deleting Form:"
msgstr "Suppression du formulaire :"
#: ../wcs/admin/forms.ptl:288 ../wcs/admin/roles.ptl:96
#: ../wcs/admin/settings.ptl:27 ../wcs/admin/users.ptl:157
#: ../wcs/admin/categories.ptl:96
msgid "New"
msgstr "Nouveau"
#: ../wcs/admin/forms.ptl:300 ../wcs/admin/roles.ptl:104
#: ../wcs/admin/settings.ptl:39 ../wcs/admin/users.ptl:169
#: ../wcs/admin/categories.ptl:104
msgid "Delete"
msgstr "Supprimer"
#: ../wcs/admin/forms.ptl:301
msgid "Listing"
msgstr "Listing"
#: ../wcs/admin/forms.ptl:317 ../wcs/admin/forms.ptl:318
msgid "New Form"
msgstr "Nouveau formulaire"
#: ../wcs/admin/menu.ptl:5
msgid "Users"
msgstr "Utilisateurs"
#: ../wcs/admin/menu.ptl:7
msgid "Categories"
msgstr "Catégories"
#: ../wcs/admin/menu.ptl:8
msgid "Settings"
msgstr "Paramètres"
#: ../wcs/admin/menu.ptl:9
msgid "WCS Form Server"
msgstr "Serveur de formulaires"
#: ../wcs/admin/menu.ptl:49
msgid "WCS Administration"
msgstr "Administration de WCS"
#: ../wcs/admin/roles.ptl:24 ../wcs/admin/roles.ptl:34
msgid "Role Id"
msgstr "Identifiant du rôle"
#: ../wcs/admin/roles.ptl:26 ../wcs/admin/roles.ptl:36
msgid "Role Name"
msgstr "Nom du rôle"
#: ../wcs/admin/roles.ptl:60 ../wcs/admin/roles.ptl:61
msgid "Edit Role"
msgstr "Éditer le rôle"
#: ../wcs/admin/roles.ptl:72
msgid "You are about to irrevocably delete this role."
msgstr "Vous allez définitivement supprimer ce rôle."
#: ../wcs/admin/roles.ptl:78
msgid "Delete Role"
msgstr "Supprimer le rôle"
#: ../wcs/admin/roles.ptl:79
msgid "Deleting Role:"
msgstr "Suppression du rôle :"
#: ../wcs/admin/roles.ptl:116 ../wcs/admin/roles.ptl:117
msgid "New Role"
msgstr "Nouveau rôle"
#: ../wcs/admin/settings.ptl:25 ../wcs/admin/settings.ptl:26
#: ../wcs/admin/settings.ptl:182
@ -213,7 +338,7 @@ msgid "Metadata"
msgstr "Metadata"
#: ../wcs/admin/settings.ptl:51 ../wcs/admin/settings.ptl:123
#: ../wcs/admin/settings.ptl:210
#: ../wcs/admin/settings.ptl:211
msgid "Public Key"
msgstr "Clé publique"
@ -262,169 +387,115 @@ msgstr "Télécharger le fichier des metadata du fournisseur de service"
msgid "Add and remove identity providers"
msgstr "Ajouter et supprimer des fournisseurs d'identités"
#: ../wcs/admin/settings.ptl:203
#: ../wcs/admin/settings.ptl:204
msgid "Provider ID"
msgstr "Identifiant du fournisseur (Provider ID)"
#: ../wcs/admin/settings.ptl:205
#: ../wcs/admin/settings.ptl:206
msgid "Base URL"
msgstr "URL de la racine"
#: ../wcs/admin/settings.ptl:207
#: ../wcs/admin/settings.ptl:208
msgid "Organization Name"
msgstr "Nom de l'organisation"
#: ../wcs/admin/settings.ptl:209
#: ../wcs/admin/settings.ptl:210
msgid "Private Key"
msgstr "Clé privée"
#: ../wcs/admin/settings.ptl:213
#: ../wcs/admin/settings.ptl:214
msgid "Identity Provider Introduction, Common Domain"
msgstr "Domaine commun, pour 'Identity Provider Introduction'"
#: ../wcs/admin/settings.ptl:214
#: ../wcs/admin/settings.ptl:215
msgid "Disabled if empty"
msgstr "Désactivé si vide"
#: ../wcs/admin/settings.ptl:217 ../wcs/admin/settings.ptl:218
#: ../wcs/admin/settings.ptl:218 ../wcs/admin/settings.ptl:219
msgid "Service Provider Configuration"
msgstr "Configuration du fournisseur de service"
#: ../wcs/admin/menu.ptl:5
msgid "Users"
msgstr "Utilisateurs"
#: ../wcs/admin/users.ptl:32 ../wcs/admin/users.ptl:49
msgid "User Id"
msgstr "Identifiant de l'utilisateur"
#: ../wcs/admin/menu.ptl:7
msgid "Settings"
msgstr "Paramètres"
#: ../wcs/admin/users.ptl:34 ../wcs/admin/users.ptl:51
msgid "User Name"
msgstr "Nom de l'utilisateur"
#: ../wcs/admin/menu.ptl:8
msgid "WCS Form Server"
msgstr "Serveur de formulaires"
#: ../wcs/admin/users.ptl:36 ../wcs/admin/users.ptl:53
msgid "Email"
msgstr "Email"
#: ../wcs/admin/menu.ptl:48
msgid "WCS Administration"
msgstr "Administration de WCS"
#: ../wcs/admin/users.ptl:83 ../wcs/admin/users.ptl:84
msgid "Edit User"
msgstr "Éditer l'utilisateur"
#: ../wcs/admin/forms.ptl:24
msgid "Text (line)"
msgstr "Texte (ligne)"
#: ../wcs/admin/users.ptl:95
msgid "You are about to irrevocably delete this user."
msgstr "Vous allez définitivement supprimer cet utilisateur."
#: ../wcs/admin/forms.ptl:25
msgid "Text (block)"
msgstr "Bloc de texte"
#: ../wcs/admin/users.ptl:101
msgid "Delete User"
msgstr "Supprimer l'utilisateur"
#: ../wcs/admin/forms.ptl:26
msgid "Boolean"
msgstr "Booléen"
#: ../wcs/admin/users.ptl:102
msgid "Deleting User:"
msgstr "Suppression de l'utilisateur :"
#: ../wcs/admin/forms.ptl:27
msgid "Item from list"
msgstr "Élément d'une liste"
#: ../wcs/admin/users.ptl:112
msgid "Generate"
msgstr "Générer"
#: ../wcs/admin/forms.ptl:28
msgid "Title"
msgstr "Titre"
#: ../wcs/admin/users.ptl:122
#, python-format
msgid "Note that user has already been issued an identification token: %s"
msgstr "À noter que l'utilisateur a déjà un jeton d'identification : %s"
#: ../wcs/admin/forms.ptl:29
msgid "Subtitle"
msgstr "Sous-titre"
#: ../wcs/admin/users.ptl:133
#, python-format
msgid "Identification Token for %s:"
msgstr "Jeton d'identification pour %s :"
#: ../wcs/admin/forms.ptl:61
msgid "Form Id"
msgstr "Identifiant du formulaire"
#: ../wcs/admin/forms.ptl:63
msgid "Form Name"
msgstr "Nom du formulaire"
#: ../wcs/admin/forms.ptl:65 ../wcs/admin/forms.ptl:279
msgid "Fields"
msgstr "Champs"
#: ../wcs/admin/forms.ptl:66
msgid "Add Field"
msgstr "Ajouter un champ"
#: ../wcs/admin/forms.ptl:68
msgid "Recipient"
msgstr "Destinataire"
#: ../wcs/admin/forms.ptl:70
msgid "Recipient Email"
msgstr "Adresse email du destinataire"
#: ../wcs/admin/forms.ptl:92
msgid "Name"
msgstr "Nom"
#: ../wcs/admin/forms.ptl:94
msgid "Type"
msgstr "Type"
#: ../wcs/admin/forms.ptl:97
msgid "Required"
msgstr "Obligatoire"
#: ../wcs/admin/forms.ptl:101
msgid "Items"
msgstr "Éléments"
#: ../wcs/admin/forms.ptl:176
msgid "Export to CSV format"
msgstr "Exporter au format CSV"
#: ../wcs/admin/forms.ptl:220 ../wcs/admin/forms.ptl:221
msgid "Edit Form"
msgstr "Éditer le formulaire"
#: ../wcs/admin/forms.ptl:233
msgid "You are about to irrevocably delete this form."
msgstr "Vous allez définitivement supprimer ce formulaire."
#: ../wcs/admin/forms.ptl:239
msgid "Delete Form"
msgstr "Supprimer le formulaire"
#: ../wcs/admin/forms.ptl:240
msgid "Deleting Form:"
msgstr "Suppression du formulaire :"
#: ../wcs/admin/forms.ptl:281
msgid "Listing"
msgstr "Listing"
#: ../wcs/admin/forms.ptl:297 ../wcs/admin/forms.ptl:298
msgid "New Form"
msgstr "Nouveau formulaire"
#: ../wcs/admin/roles.ptl:24 ../wcs/admin/roles.ptl:34
msgid "Role Id"
#: ../wcs/admin/users.ptl:137
msgid "Done"
msgstr ""
#: ../wcs/admin/roles.ptl:26 ../wcs/admin/roles.ptl:36
msgid "Role Name"
msgstr "Nom du rôle"
#: ../wcs/admin/users.ptl:139
msgid "Send by email"
msgstr "Envoyer par email"
#: ../wcs/admin/roles.ptl:60 ../wcs/admin/roles.ptl:61
msgid "Edit Role"
msgstr "Éditer le rôle"
#: ../wcs/admin/users.ptl:181 ../wcs/admin/users.ptl:182
msgid "New User"
msgstr "Nouvel utilisateur"
#: ../wcs/admin/roles.ptl:72
msgid "You are about to irrevocably delete this role."
msgstr "Vous allez définitivement supprimer ce rôle."
#: ../wcs/admin/categories.ptl:24 ../wcs/admin/categories.ptl:34
msgid "Category Id"
msgstr "Identifiant de la catégorie"
#: ../wcs/admin/roles.ptl:78
msgid "Delete Role"
msgstr "Supprimer le rôle"
#: ../wcs/admin/categories.ptl:26 ../wcs/admin/categories.ptl:36
msgid "Category Name"
msgstr "Nom de la catégorie"
#: ../wcs/admin/roles.ptl:79
msgid "Deleting Role:"
msgstr "Suppression du rôle :"
#: ../wcs/admin/categories.ptl:60 ../wcs/admin/categories.ptl:61
msgid "Edit Category"
msgstr "Éditer la catégorie"
#: ../wcs/admin/roles.ptl:116 ../wcs/admin/roles.ptl:117
msgid "New Role"
msgstr "Nouveau rôle"
#: ../wcs/admin/categories.ptl:72
msgid "You are about to irrevocably delete this category."
msgstr "Vous allez définitivement supprimer cette catégorie."
#: ../wcs/admin/categories.ptl:78
msgid "Delete Category"
msgstr "Supprimer la catégorie"
#: ../wcs/admin/categories.ptl:79
msgid "Deleting Category:"
msgstr "Suppression de la catégorie :"
#: ../wcs/admin/categories.ptl:116 ../wcs/admin/categories.ptl:117
msgid "New Category"
msgstr "Nouvelle catégorie"
#~ msgid "Forms Management"
#~ msgstr "Gestion des formulaires"

View File

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2005-05-19 16:00+0200\n"
"POT-Creation-Date: 2005-05-20 00:07+0200\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@ -16,166 +16,15 @@ msgstr ""
"Content-Type: text/plain; charset=CHARSET\n"
"Content-Transfer-Encoding: 8bit\n"
#: ../wcs/admin/users.ptl:32 ../wcs/admin/users.ptl:49
msgid "User Id"
#: ../wcs/form.py:6
msgid "required field"
msgstr ""
#: ../wcs/admin/users.ptl:34 ../wcs/admin/users.ptl:51
msgid "User Name"
#: ../wcs/form.py:10
msgid "There were errors processing your form. See below for details."
msgstr ""
#: ../wcs/admin/users.ptl:36 ../wcs/admin/users.ptl:53
msgid "Email"
msgstr ""
#: ../wcs/admin/users.ptl:38 ../wcs/admin/users.ptl:55 ../wcs/admin/menu.ptl:6
msgid "Roles"
msgstr ""
#: ../wcs/admin/users.ptl:39 ../wcs/admin/users.ptl:56
msgid "Add Role"
msgstr ""
#: ../wcs/admin/users.ptl:43 ../wcs/admin/users.ptl:61
#: ../wcs/admin/users.ptl:97 ../wcs/admin/settings.ptl:53
#: ../wcs/admin/settings.ptl:125 ../wcs/admin/settings.ptl:141
#: ../wcs/admin/forms.ptl:72 ../wcs/admin/forms.ptl:105
#: ../wcs/admin/forms.ptl:234 ../wcs/admin/roles.ptl:28
#: ../wcs/admin/roles.ptl:38 ../wcs/admin/roles.ptl:73
msgid "Submit"
msgstr ""
#: ../wcs/admin/users.ptl:44 ../wcs/admin/users.ptl:60
#: ../wcs/admin/users.ptl:96 ../wcs/admin/users.ptl:111
#: ../wcs/admin/settings.ptl:142 ../wcs/admin/forms.ptl:73
#: ../wcs/admin/forms.ptl:106 ../wcs/admin/forms.ptl:235
#: ../wcs/admin/roles.ptl:29 ../wcs/admin/roles.ptl:39
#: ../wcs/admin/roles.ptl:74
msgid "Cancel"
msgstr ""
#: ../wcs/admin/users.ptl:83 ../wcs/admin/users.ptl:84
msgid "Edit User"
msgstr ""
#: ../wcs/admin/users.ptl:95
msgid "You are about to irrevocably delete this user."
msgstr ""
#: ../wcs/admin/users.ptl:101
msgid "Delete User"
msgstr ""
#: ../wcs/admin/users.ptl:102
msgid "Deleting User:"
msgstr ""
#: ../wcs/admin/users.ptl:112
msgid "Generate"
msgstr ""
#: ../wcs/admin/users.ptl:118 ../wcs/admin/users.ptl:119
#: ../wcs/admin/users.ptl:127 ../wcs/admin/users.ptl:167
msgid "Identification Token"
msgstr ""
#: ../wcs/admin/users.ptl:122
#, python-format
msgid "Note that user has already been issued an identification token: %s"
msgstr ""
#: ../wcs/admin/users.ptl:133
#, python-format
msgid "Identification Token for %s:"
msgstr ""
#: ../wcs/admin/users.ptl:137
msgid "Done"
msgstr ""
#: ../wcs/admin/users.ptl:139
msgid "Send by email"
msgstr ""
#: ../wcs/admin/users.ptl:157 ../wcs/admin/settings.ptl:27
#: ../wcs/admin/forms.ptl:268 ../wcs/admin/roles.ptl:96
msgid "New"
msgstr ""
#: ../wcs/admin/users.ptl:168 ../wcs/admin/settings.ptl:38
#: ../wcs/admin/forms.ptl:166 ../wcs/admin/forms.ptl:278
#: ../wcs/admin/roles.ptl:103
msgid "Edit"
msgstr ""
#: ../wcs/admin/users.ptl:169 ../wcs/admin/settings.ptl:39
#: ../wcs/admin/forms.ptl:280 ../wcs/admin/roles.ptl:104
msgid "Delete"
msgstr ""
#: ../wcs/admin/users.ptl:181 ../wcs/admin/users.ptl:182
msgid "New User"
msgstr ""
#: ../wcs/forms/root.ptl:49 ../wcs/forms/root.ptl:71 ../wcs/forms/root.ptl:157
#, python-format
msgid "The form has been recorded on %s with the number %s."
msgstr ""
#: ../wcs/forms/root.ptl:53
msgid "Your case is handled by:"
msgstr ""
#: ../wcs/forms/root.ptl:64 ../wcs/forms/root.ptl:79 ../wcs/forms/root.ptl:174
msgid "Back Home"
msgstr ""
#: ../wcs/forms/root.ptl:95
msgid "Filling"
msgstr ""
#: ../wcs/forms/root.ptl:95
msgid "Validating"
msgstr ""
#: ../wcs/forms/root.ptl:95
msgid "Receipt"
msgstr ""
#: ../wcs/forms/root.ptl:105 ../wcs/forms/root.ptl:116
#: ../wcs/forms/root.ptl:146
msgid "Next"
msgstr ""
#: ../wcs/forms/root.ptl:115 ../wcs/forms/root.ptl:145
msgid "Previous"
msgstr ""
#: ../wcs/forms/root.ptl:142
msgid "Check values then click next."
msgstr ""
#: ../wcs/forms/root.ptl:161
msgid "Your case will be handled by:"
msgstr ""
#: ../wcs/forms/root.ptl:187 ../wcs/admin/menu.ptl:4
msgid "Forms"
msgstr ""
#: ../wcs/forms/root.ptl:207
msgid "Your Current Forms"
msgstr ""
#: ../wcs/forms/root.ptl:215
msgid "Logout"
msgstr ""
#: ../wcs/forms/root.ptl:218
msgid "Login"
msgstr ""
#: ../wcs/formdef.py:81
#: ../wcs/formdef.py:86
#, python-format
msgid ""
"Hi,\n"
@ -184,16 +33,291 @@ msgid ""
"link: %(url)s\n"
msgstr ""
#: ../wcs/formdef.py:92
#: ../wcs/formdef.py:97
msgid "A new form has been submitted"
msgstr ""
#: ../wcs/form.py:6
msgid "required field"
#: ../wcs/forms/root.ptl:48 ../wcs/forms/root.ptl:70 ../wcs/forms/root.ptl:173
#, python-format
msgid "The form has been recorded on %s with the number %s."
msgstr ""
#: ../wcs/form.py:10
msgid "There were errors processing your form. See below for details."
#: ../wcs/forms/root.ptl:52
msgid "Your case is handled by:"
msgstr ""
#: ../wcs/forms/root.ptl:63 ../wcs/forms/root.ptl:78 ../wcs/forms/root.ptl:190
msgid "Back Home"
msgstr ""
#: ../wcs/forms/root.ptl:111
msgid "Filling"
msgstr ""
#: ../wcs/forms/root.ptl:111
msgid "Validating"
msgstr ""
#: ../wcs/forms/root.ptl:111
msgid "Receipt"
msgstr ""
#: ../wcs/forms/root.ptl:121 ../wcs/forms/root.ptl:132
#: ../wcs/forms/root.ptl:162
msgid "Next"
msgstr ""
#: ../wcs/forms/root.ptl:131 ../wcs/forms/root.ptl:161
msgid "Previous"
msgstr ""
#: ../wcs/forms/root.ptl:158
msgid "Check values then click next."
msgstr ""
#: ../wcs/forms/root.ptl:177
msgid "Your case will be handled by:"
msgstr ""
#: ../wcs/forms/root.ptl:203 ../wcs/forms/root.ptl:293 ../wcs/admin/menu.ptl:4
msgid "Forms"
msgstr ""
#: ../wcs/forms/root.ptl:209
#, python-format
msgid "You are logged in as %s."
msgstr ""
#: ../wcs/forms/root.ptl:243
msgid "Misc"
msgstr ""
#: ../wcs/forms/root.ptl:261
msgid "Your Current Forms"
msgstr ""
#: ../wcs/forms/root.ptl:271
msgid "Enter Identification Token"
msgstr ""
#: ../wcs/forms/root.ptl:272
msgid "Logout"
msgstr ""
#: ../wcs/forms/root.ptl:275
msgid "Login"
msgstr ""
#: ../wcs/forms/root.ptl:284 ../wcs/admin/users.ptl:118
#: ../wcs/admin/users.ptl:119 ../wcs/admin/users.ptl:127
#: ../wcs/admin/users.ptl:167
msgid "Identification Token"
msgstr ""
#: ../wcs/forms/root.ptl:286 ../wcs/admin/forms.ptl:94
#: ../wcs/admin/forms.ptl:127 ../wcs/admin/forms.ptl:255
#: ../wcs/admin/roles.ptl:29 ../wcs/admin/roles.ptl:39
#: ../wcs/admin/roles.ptl:74 ../wcs/admin/settings.ptl:142
#: ../wcs/admin/users.ptl:44 ../wcs/admin/users.ptl:60
#: ../wcs/admin/users.ptl:96 ../wcs/admin/users.ptl:111
#: ../wcs/admin/categories.ptl:29 ../wcs/admin/categories.ptl:39
#: ../wcs/admin/categories.ptl:74
msgid "Cancel"
msgstr ""
#: ../wcs/forms/root.ptl:287 ../wcs/admin/forms.ptl:93
#: ../wcs/admin/forms.ptl:126 ../wcs/admin/forms.ptl:254
#: ../wcs/admin/roles.ptl:28 ../wcs/admin/roles.ptl:38
#: ../wcs/admin/roles.ptl:73 ../wcs/admin/settings.ptl:53
#: ../wcs/admin/settings.ptl:125 ../wcs/admin/settings.ptl:141
#: ../wcs/admin/users.ptl:43 ../wcs/admin/users.ptl:61
#: ../wcs/admin/users.ptl:97 ../wcs/admin/categories.ptl:28
#: ../wcs/admin/categories.ptl:38 ../wcs/admin/categories.ptl:73
msgid "Submit"
msgstr ""
#: ../wcs/forms/root.ptl:295
msgid "Bla bla bla"
msgstr ""
#: ../wcs/admin/forms.ptl:37
msgid "Text (line)"
msgstr ""
#: ../wcs/admin/forms.ptl:38
msgid "Text (block)"
msgstr ""
#: ../wcs/admin/forms.ptl:39
msgid "Boolean"
msgstr ""
#: ../wcs/admin/forms.ptl:40
msgid "Item from list"
msgstr ""
#: ../wcs/admin/forms.ptl:41
msgid "Title"
msgstr ""
#: ../wcs/admin/forms.ptl:42
msgid "Subtitle"
msgstr ""
#: ../wcs/admin/forms.ptl:74
msgid "Form Id"
msgstr ""
#: ../wcs/admin/forms.ptl:76
msgid "Form Name"
msgstr ""
#: ../wcs/admin/forms.ptl:78 ../wcs/admin/forms.ptl:299
msgid "Fields"
msgstr ""
#: ../wcs/admin/forms.ptl:79
msgid "Add Field"
msgstr ""
#: ../wcs/admin/forms.ptl:81
msgid "Recipient"
msgstr ""
#: ../wcs/admin/forms.ptl:83
msgid "Recipient Email"
msgstr ""
#: ../wcs/admin/forms.ptl:85 ../wcs/admin/menu.ptl:6 ../wcs/admin/users.ptl:38
#: ../wcs/admin/users.ptl:55
msgid "Roles"
msgstr ""
#: ../wcs/admin/forms.ptl:86
msgid "Only show this form to the given roles."
msgstr ""
#: ../wcs/admin/forms.ptl:87 ../wcs/admin/users.ptl:39
#: ../wcs/admin/users.ptl:56
msgid "Add Role"
msgstr ""
#: ../wcs/admin/forms.ptl:90
msgid "Category"
msgstr ""
#: ../wcs/admin/forms.ptl:113
msgid "Name"
msgstr ""
#: ../wcs/admin/forms.ptl:115
msgid "Type"
msgstr ""
#: ../wcs/admin/forms.ptl:118
msgid "Required"
msgstr ""
#: ../wcs/admin/forms.ptl:122
msgid "Items"
msgstr ""
#: ../wcs/admin/forms.ptl:185
msgid "optional"
msgstr ""
#: ../wcs/admin/forms.ptl:187 ../wcs/admin/forms.ptl:298
#: ../wcs/admin/roles.ptl:103 ../wcs/admin/settings.ptl:38
#: ../wcs/admin/users.ptl:168 ../wcs/admin/categories.ptl:103
msgid "Edit"
msgstr ""
#: ../wcs/admin/forms.ptl:197
msgid "Export to CSV format"
msgstr ""
#: ../wcs/admin/forms.ptl:241 ../wcs/admin/forms.ptl:242
msgid "Edit Form"
msgstr ""
#: ../wcs/admin/forms.ptl:253
msgid "You are about to irrevocably delete this form."
msgstr ""
#: ../wcs/admin/forms.ptl:259
msgid "Delete Form"
msgstr ""
#: ../wcs/admin/forms.ptl:260
msgid "Deleting Form:"
msgstr ""
#: ../wcs/admin/forms.ptl:288 ../wcs/admin/roles.ptl:96
#: ../wcs/admin/settings.ptl:27 ../wcs/admin/users.ptl:157
#: ../wcs/admin/categories.ptl:96
msgid "New"
msgstr ""
#: ../wcs/admin/forms.ptl:300 ../wcs/admin/roles.ptl:104
#: ../wcs/admin/settings.ptl:39 ../wcs/admin/users.ptl:169
#: ../wcs/admin/categories.ptl:104
msgid "Delete"
msgstr ""
#: ../wcs/admin/forms.ptl:301
msgid "Listing"
msgstr ""
#: ../wcs/admin/forms.ptl:317 ../wcs/admin/forms.ptl:318
msgid "New Form"
msgstr ""
#: ../wcs/admin/menu.ptl:5
msgid "Users"
msgstr ""
#: ../wcs/admin/menu.ptl:7
msgid "Categories"
msgstr ""
#: ../wcs/admin/menu.ptl:8
msgid "Settings"
msgstr ""
#: ../wcs/admin/menu.ptl:9
msgid "WCS Form Server"
msgstr ""
#: ../wcs/admin/menu.ptl:49
msgid "WCS Administration"
msgstr ""
#: ../wcs/admin/roles.ptl:24 ../wcs/admin/roles.ptl:34
msgid "Role Id"
msgstr ""
#: ../wcs/admin/roles.ptl:26 ../wcs/admin/roles.ptl:36
msgid "Role Name"
msgstr ""
#: ../wcs/admin/roles.ptl:60 ../wcs/admin/roles.ptl:61
msgid "Edit Role"
msgstr ""
#: ../wcs/admin/roles.ptl:72
msgid "You are about to irrevocably delete this role."
msgstr ""
#: ../wcs/admin/roles.ptl:78
msgid "Delete Role"
msgstr ""
#: ../wcs/admin/roles.ptl:79
msgid "Deleting Role:"
msgstr ""
#: ../wcs/admin/roles.ptl:116 ../wcs/admin/roles.ptl:117
msgid "New Role"
msgstr ""
#: ../wcs/admin/settings.ptl:25 ../wcs/admin/settings.ptl:26
@ -211,7 +335,7 @@ msgid "Metadata"
msgstr ""
#: ../wcs/admin/settings.ptl:51 ../wcs/admin/settings.ptl:123
#: ../wcs/admin/settings.ptl:210
#: ../wcs/admin/settings.ptl:211
msgid "Public Key"
msgstr ""
@ -260,166 +384,112 @@ msgstr ""
msgid "Add and remove identity providers"
msgstr ""
#: ../wcs/admin/settings.ptl:203
#: ../wcs/admin/settings.ptl:204
msgid "Provider ID"
msgstr ""
#: ../wcs/admin/settings.ptl:205
#: ../wcs/admin/settings.ptl:206
msgid "Base URL"
msgstr ""
#: ../wcs/admin/settings.ptl:207
#: ../wcs/admin/settings.ptl:208
msgid "Organization Name"
msgstr ""
#: ../wcs/admin/settings.ptl:209
#: ../wcs/admin/settings.ptl:210
msgid "Private Key"
msgstr ""
#: ../wcs/admin/settings.ptl:213
#: ../wcs/admin/settings.ptl:214
msgid "Identity Provider Introduction, Common Domain"
msgstr ""
#: ../wcs/admin/settings.ptl:214
#: ../wcs/admin/settings.ptl:215
msgid "Disabled if empty"
msgstr ""
#: ../wcs/admin/settings.ptl:217 ../wcs/admin/settings.ptl:218
#: ../wcs/admin/settings.ptl:218 ../wcs/admin/settings.ptl:219
msgid "Service Provider Configuration"
msgstr ""
#: ../wcs/admin/menu.ptl:5
msgid "Users"
#: ../wcs/admin/users.ptl:32 ../wcs/admin/users.ptl:49
msgid "User Id"
msgstr ""
#: ../wcs/admin/menu.ptl:7
msgid "Settings"
#: ../wcs/admin/users.ptl:34 ../wcs/admin/users.ptl:51
msgid "User Name"
msgstr ""
#: ../wcs/admin/menu.ptl:8
msgid "WCS Form Server"
#: ../wcs/admin/users.ptl:36 ../wcs/admin/users.ptl:53
msgid "Email"
msgstr ""
#: ../wcs/admin/menu.ptl:48
msgid "WCS Administration"
#: ../wcs/admin/users.ptl:83 ../wcs/admin/users.ptl:84
msgid "Edit User"
msgstr ""
#: ../wcs/admin/forms.ptl:24
msgid "Text (line)"
#: ../wcs/admin/users.ptl:95
msgid "You are about to irrevocably delete this user."
msgstr ""
#: ../wcs/admin/forms.ptl:25
msgid "Text (block)"
#: ../wcs/admin/users.ptl:101
msgid "Delete User"
msgstr ""
#: ../wcs/admin/forms.ptl:26
msgid "Boolean"
#: ../wcs/admin/users.ptl:102
msgid "Deleting User:"
msgstr ""
#: ../wcs/admin/forms.ptl:27
msgid "Item from list"
#: ../wcs/admin/users.ptl:112
msgid "Generate"
msgstr ""
#: ../wcs/admin/forms.ptl:28
msgid "Title"
#: ../wcs/admin/users.ptl:122
#, python-format
msgid "Note that user has already been issued an identification token: %s"
msgstr ""
#: ../wcs/admin/forms.ptl:29
msgid "Subtitle"
#: ../wcs/admin/users.ptl:133
#, python-format
msgid "Identification Token for %s:"
msgstr ""
#: ../wcs/admin/forms.ptl:61
msgid "Form Id"
#: ../wcs/admin/users.ptl:137
msgid "Done"
msgstr ""
#: ../wcs/admin/forms.ptl:63
msgid "Form Name"
#: ../wcs/admin/users.ptl:139
msgid "Send by email"
msgstr ""
#: ../wcs/admin/forms.ptl:65 ../wcs/admin/forms.ptl:279
msgid "Fields"
#: ../wcs/admin/users.ptl:181 ../wcs/admin/users.ptl:182
msgid "New User"
msgstr ""
#: ../wcs/admin/forms.ptl:66
msgid "Add Field"
#: ../wcs/admin/categories.ptl:24 ../wcs/admin/categories.ptl:34
msgid "Category Id"
msgstr ""
#: ../wcs/admin/forms.ptl:68
msgid "Recipient"
#: ../wcs/admin/categories.ptl:26 ../wcs/admin/categories.ptl:36
msgid "Category Name"
msgstr ""
#: ../wcs/admin/forms.ptl:70
msgid "Recipient Email"
#: ../wcs/admin/categories.ptl:60 ../wcs/admin/categories.ptl:61
msgid "Edit Category"
msgstr ""
#: ../wcs/admin/forms.ptl:92
msgid "Name"
#: ../wcs/admin/categories.ptl:72
msgid "You are about to irrevocably delete this category."
msgstr ""
#: ../wcs/admin/forms.ptl:94
msgid "Type"
#: ../wcs/admin/categories.ptl:78
msgid "Delete Category"
msgstr ""
#: ../wcs/admin/forms.ptl:97
msgid "Required"
#: ../wcs/admin/categories.ptl:79
msgid "Deleting Category:"
msgstr ""
#: ../wcs/admin/forms.ptl:101
msgid "Items"
msgstr ""
#: ../wcs/admin/forms.ptl:176
msgid "Export to CSV format"
msgstr ""
#: ../wcs/admin/forms.ptl:220 ../wcs/admin/forms.ptl:221
msgid "Edit Form"
msgstr ""
#: ../wcs/admin/forms.ptl:233
msgid "You are about to irrevocably delete this form."
msgstr ""
#: ../wcs/admin/forms.ptl:239
msgid "Delete Form"
msgstr ""
#: ../wcs/admin/forms.ptl:240
msgid "Deleting Form:"
msgstr ""
#: ../wcs/admin/forms.ptl:281
msgid "Listing"
msgstr ""
#: ../wcs/admin/forms.ptl:297 ../wcs/admin/forms.ptl:298
msgid "New Form"
msgstr ""
#: ../wcs/admin/roles.ptl:24 ../wcs/admin/roles.ptl:34
msgid "Role Id"
msgstr ""
#: ../wcs/admin/roles.ptl:26 ../wcs/admin/roles.ptl:36
msgid "Role Name"
msgstr ""
#: ../wcs/admin/roles.ptl:60 ../wcs/admin/roles.ptl:61
msgid "Edit Role"
msgstr ""
#: ../wcs/admin/roles.ptl:72
msgid "You are about to irrevocably delete this role."
msgstr ""
#: ../wcs/admin/roles.ptl:78
msgid "Delete Role"
msgstr ""
#: ../wcs/admin/roles.ptl:79
msgid "Deleting Role:"
msgstr ""
#: ../wcs/admin/roles.ptl:116 ../wcs/admin/roles.ptl:117
msgid "New Role"
#: ../wcs/admin/categories.ptl:116 ../wcs/admin/categories.ptl:117
msgid "New Category"
msgstr ""

View File

@ -117,3 +117,9 @@ h2#submitted {
ul li {
list-style: circle;
}
h2 {
color: #09F;
margin-left: 0.5em;
margin-bottom: 0;
}

126
wcs/admin/categories.ptl Normal file
View File

@ -0,0 +1,126 @@
import re
import os
from quixote import get_request, get_response, redirect
from quixote.directory import Directory
from quixote import errors
from quixote.html import htmltext
from quixote.util import dump_request
from menu import html_top, html_foot
import wcs.misc
from wcs.categories import Category
from wcs import storage
from wcs.form import *
class CategoryUI:
def __init__(self, category):
self.category = category
def form_new(self):
form = Form(enctype="multipart/form-data")
form.add(StringWidget, "id", title = _('Category Id'), required = True, size=30,
value = self.category.id)
form.add(StringWidget, "name", title = _('Category Name'), required = True, size=30,
value = self.category.name)
form.add_submit("submit", _("Submit"))
form.add_submit("cancel", _("Cancel"))
return form
def form_edit(self):
form = Form(enctype="multipart/form-data")
form.add(StringWidget, "id", title = _('Category Id'), required = False, size=30,
value = self.category.id, readonly = 'readonly')
form.add(StringWidget, "name", title = _('Category Name'), required = True, size=30,
value = self.category.name)
form.add_submit("submit", _("Submit"))
form.add_submit("cancel", _("Cancel"))
return form
def submit_form(self, form):
for f in ('id', 'name'):
setattr(self.category, f, form.get_widget(f).parse())
class CategoryPage(Directory):
_q_exports = ["edit", "delete"]
def __init__(self, component):
self.category = storage.get_storage().retrieve('categories', component)
self.category_ui = CategoryUI(self.category)
def edit [html] (self):
form = self.category_ui.form_edit()
if form.get_widget('cancel').parse():
return redirect('.')
if not form.is_submitted() or form.has_errors():
html_top('categories', title = _('Edit Category'))
"""<h2>%s</h2>""" % _('Edit Category')
form.render()
html_foot()
else:
self.category_ui.submit_form(form)
storage.get_storage().store(self.category)
return redirect('..')
def delete [html] (self):
form = Form(enctype="multipart/form-data")
form.widgets.append(HtmlWidget("""<p>%s</p>""" % _(
"You are about to irrevocably delete this category.")))
form.add_submit("submit", _("Submit"))
form.add_submit("cancel", _("Cancel"))
if form.get_widget('cancel').parse():
return redirect('..')
if not form.is_submitted() or form.has_errors():
html_top('categories', title = _('Delete Category'))
"""<h2>%s %s</h2>""" % (_('Deleting Category:'), self.category.name)
form.render()
html_foot()
else:
storage.get_storage().remove_id('categories', self.category.id)
return redirect('..')
class CategoriesDirectory(Directory):
_q_exports = ["", "new"]
def _q_index [html] (self):
wcs.misc.reload_cfg()
html_top('categories', title = 'Categories')
"""<ul id="nav-categories-admin">
<li><a href="new">%s</a></li>
</ul>""" % _('New')
for k in storage.get_storage().keys('categories'):
category = storage.get_storage().retrieve('categories', k)
"""<div class="form">"""
"<h3>%s</h3>" % category.name
"""<span class="cmds"> [ """
"""<a href="%s/edit">%s</a> - """ % (k, _('Edit'))
"""<a href="%s/delete">%s</a> """ % (k, _('Delete'))
"]</span></p></div>"
html_foot()
def new [html] (self):
category = Category()
category_ui = CategoryUI(category)
form = category_ui.form_new()
if form.get_widget('cancel').parse():
return redirect('.')
if not form.is_submitted() or form.has_errors():
html_top('categories', title = _('New Category'))
"""<h2>%s</h2>""" % _('New Category')
form.render()
html_foot()
else:
category_ui.submit_form(form)
storage.get_storage().store(category)
return redirect('.')
def _q_lookup(self, component):
return CategoryPage(component)

View File

@ -26,6 +26,14 @@ def get_user_roles():
l.append( (role.id, role.name) )
return l
def get_categories():
l = []
for category in storage.get_storage().values('categories'):
l.append( (category.id, category.name) )
return l
field_types = [ ('string', _('Text (line)')),
('text', _('Text (block)')),
('bool', _('Boolean')),
@ -61,7 +69,7 @@ class FormDefUI:
def __init__(self, formdef):
self.formdef = formdef
def edit_form_ui [html] (self):
def edit_form_ui(self):
form = Form(enctype="multipart/form-data")
form.add(StringWidget, "id", title = _('Form Id'), required = True, size=30,
value = self.formdef.id)
@ -69,7 +77,7 @@ class FormDefUI:
value = self.formdef.name)
form.add(WidgetList, 'fields', title = _('Fields'), element_type = FieldWidget,
value = self.formdef.fields, add_element_label = _('Add Field'),
element_kwargs = {str('render_br'): False})
element_kwargs = {'render_br': False})
form.add(TextWidget, "receiver", title = _('Recipient'), required = True,
value = self.formdef.receiver, rows = 3, cols = 40)
form.add(StringWidget, "emailrcpt", title = _('Recipient Email'), size=30,
@ -77,14 +85,17 @@ class FormDefUI:
form.add(WidgetList, 'roles', title = _('Roles'), element_type = SingleSelectWidget,
hint = _('Only show this form to the given roles.'),
value = self.formdef.roles, add_element_label = _('Add Role'),
element_kwargs = {str('render_br'): False,
str('options'): [('', '---')] + get_user_roles()})
element_kwargs = {'render_br': False,
'options': [('', '---')] + get_user_roles()})
form.add(SingleSelectWidget, 'category', title = _('Category'),
value = self.formdef.category,
options = [('', '---')] + get_categories())
form.add_submit("submit", _("Submit"))
form.add_submit("cancel", _("Cancel"))
return form
def submit_form(self, form):
for f in ('id', 'name', 'emailrcpt', 'fields', 'receiver'):
for f in ('id', 'name', 'emailrcpt', 'fields', 'receiver', 'category'):
setattr(self.formdef, f, form.get_widget(f).parse())
self.formdef.fields = [x for x in self.formdef.fields if x['name']] # remove empty names
self.formdef.roles = [x for x in form.get_widget('roles').parse() if x]
@ -110,7 +121,7 @@ class FormDefFieldPage(Directory):
if value.get('type') == 'item':
form.add(WidgetList, 'items', title = _('Items'), element_type = StringWidget,
value = value.get('items', []), required = True,
element_kwargs = {str('render_br'): False})
element_kwargs = {'render_br': False})
form.add_submit("submit", _("Submit"))
form.add_submit("cancel", _("Cancel"))

View File

@ -4,6 +4,7 @@ items = [
('forms', N_('Forms')),
('users', N_('Users')),
('roles', N_('Roles')),
('categories', N_('Categories')),
('settings', N_('Settings')),
('/', N_('WCS Form Server'))]

View File

@ -5,6 +5,7 @@ import settings
import forms
import roles
import users
import categories
from menu import html_top, html_foot
@ -29,7 +30,7 @@ def gpl [html] ():
class RootDirectory(AccessControlled, Directory): #, AccessControlled):
_q_exports = ["", "settings", "forms", "roles", "users"]
_q_exports = ["", "settings", "forms", "roles", "users", "categories"]
def _q_index [html] (self):
html_top('/')
@ -40,4 +41,5 @@ class RootDirectory(AccessControlled, Directory): #, AccessControlled):
forms = forms.FormsDirectory()
roles = roles.RolesDirectory()
users = users.UsersDirectory()
categories = categories.CategoriesDirectory()

12
wcs/categories.py Normal file
View File

@ -0,0 +1,12 @@
from quixote import get_request
import storage
class Category(storage.Storable):
key = 'id'
names = 'categories'
def __init__(self):
self.id = ''
self.name = ''

View File

@ -28,6 +28,7 @@ class FormDef(storage.Storable):
names = 'formdefs'
receiver = None
roles = None
category = None
def __init__(self):
self.id = ''
@ -35,6 +36,7 @@ class FormDef(storage.Storable):
self.fields = []
self.receiver = ''
self.emailrcpt = ''
self.category = ''
self.roles = []
def create_form(self): # XXX: merge create_form and create_view_form

View File

@ -212,8 +212,7 @@ class RootDirectory(Directory):
else:
user = None
"<ul>"
l = []
for k in storage.get_storage().keys(str('formdefs')):
formdef = storage.get_storage().retrieve('formdefs', k)
if formdef.roles:
@ -224,8 +223,29 @@ class RootDirectory(Directory):
break
else:
continue
"""<li><a href="%s/">%s</a></li>""" % (k, formdef.name)
"</ul>"
l.append(formdef)
cats = storage.get_storage().values('categories')
cats.sort(lambda x,y: cmp(x.name, y.name))
one = False
for c in cats:
l2 = [x for x in l if x.category == c.id]
if l2:
"<h2>%s</h2>" % c.name
"<ul>"
for formdef in l2:
"""<li><a href="%s/">%s</a></li>""" % (formdef.id, formdef.name)
"</ul>"
one = True
l2 = [x for x in l if not x.category]
if one and l2:
"<h2>%s</h2>" % _('Misc')
if l2:
"<ul>"
for formdef in l2:
"""<li><a href="%s/">%s</a></li>""" % (formdef.id, formdef.name)
"</ul>"
if session and session.user:
l = []