瀏覽代碼

Customer portal : Finally translated form validation messages !

git-svn-id: http://svn.code.sf.net/p/itop/code/trunk@4071 a333f486-631f-4898-b8df-5754b55c2be0
glajarige 9 年之前
父節點
當前提交
ee47edc213

+ 5 - 1
dictionaries/cs.dictionary.itop.core.php

@@ -867,5 +867,9 @@ Dict::Add('CS CZ', 'Czech', 'Čeština', array(
     'Core:BulkExportCanRunNonInteractive' => 'Click here to run the export in non-interactive mode.~~',
     'Core:BulkExportCanRunNonInteractive' => 'Click here to run the export in non-interactive mode.~~',
     'Core:BulkExportLegacyExport' => 'Click here to access the legacy export.~~',
     'Core:BulkExportLegacyExport' => 'Click here to access the legacy export.~~',
 	'Core:BulkExport:XLSXOptions' => 'Excel Options~~',
 	'Core:BulkExport:XLSXOptions' => 'Excel Options~~',
-	'Core:BulkExport:TextFormat' => 'Text fields containing some HTML markup~~',		
+	'Core:BulkExport:TextFormat' => 'Text fields containing some HTML markup~~',
+	'Core:Validator:Default' => 'Wrong format~~',
+	'Core:Validator:Mandatory' => 'Please, fill this field~~',
+	'Core:Validator:MustBeInteger' => 'Must be an integer~~',
+	'Core:Validator:MustSelectOne' => 'Please, select one~~',
 ));
 ));

+ 4 - 0
dictionaries/da.dictionary.itop.core.php

@@ -2489,5 +2489,9 @@ Operators:<br/>
 	'Core:BulkExportLegacyExport' => 'Click here to access the legacy export.~~',
 	'Core:BulkExportLegacyExport' => 'Click here to access the legacy export.~~',
 	'Core:BulkExport:XLSXOptions' => 'Excel Options~~',
 	'Core:BulkExport:XLSXOptions' => 'Excel Options~~',
 	'Core:BulkExport:TextFormat' => 'Text fields containing some HTML markup~~',
 	'Core:BulkExport:TextFormat' => 'Text fields containing some HTML markup~~',
+	'Core:Validator:Default' => 'Wrong format~~',
+	'Core:Validator:Mandatory' => 'Please, fill this field~~',
+	'Core:Validator:MustBeInteger' => 'Must be an integer~~',
+	'Core:Validator:MustSelectOne' => 'Please, select one~~',
 ));
 ));
 ?>
 ?>

+ 4 - 0
dictionaries/de.dictionary.itop.core.php

@@ -624,4 +624,8 @@ Operatoren:<br/>
 	'Core:DateTime:Placeholder_A' => 'AM/PM', // AM/PM (uppercase)
 	'Core:DateTime:Placeholder_A' => 'AM/PM', // AM/PM (uppercase)
 	'Core:DateTime:Placeholder_i' => 'mm', // minutes, 2 digits: 00..59
 	'Core:DateTime:Placeholder_i' => 'mm', // minutes, 2 digits: 00..59
 	'Core:DateTime:Placeholder_s' => 'ss', // seconds, 2 digits 00..59
 	'Core:DateTime:Placeholder_s' => 'ss', // seconds, 2 digits 00..59
+	'Core:Validator:Default' => 'Wrong format~~',
+	'Core:Validator:Mandatory' => 'Please, fill this field~~',
+	'Core:Validator:MustBeInteger' => 'Must be an integer~~',
+	'Core:Validator:MustSelectOne' => 'Please, select one~~',
 ));
 ));

+ 4 - 0
dictionaries/dictionary.itop.core.php

@@ -870,4 +870,8 @@ Dict::Add('EN US', 'English', 'English', array(
 	'Core:DateTime:Placeholder_A' => 'AM/PM', // AM/PM (uppercase)
 	'Core:DateTime:Placeholder_A' => 'AM/PM', // AM/PM (uppercase)
 	'Core:DateTime:Placeholder_i' => 'mm', // minutes, 2 digits: 00..59
 	'Core:DateTime:Placeholder_i' => 'mm', // minutes, 2 digits: 00..59
 	'Core:DateTime:Placeholder_s' => 'ss', // seconds, 2 digits 00..59
 	'Core:DateTime:Placeholder_s' => 'ss', // seconds, 2 digits 00..59
+	'Core:Validator:Default' => 'Wrong format',
+	'Core:Validator:Mandatory' => 'Please, fill this field',
+	'Core:Validator:MustBeInteger' => 'Must be an integer',
+	'Core:Validator:MustSelectOne' => 'Please, select one',
 ));
 ));

+ 4 - 0
dictionaries/es_cr.dictionary.itop.core.php

@@ -847,6 +847,10 @@ Dict::Add('ES CR', 'Spanish', 'Español, Castellano', array(
 	'Core:BulkExportLegacyExport' => 'Click here to access the legacy export.~~',
 	'Core:BulkExportLegacyExport' => 'Click here to access the legacy export.~~',
 	'Core:BulkExport:XLSXOptions' => 'Excel Options~~',
 	'Core:BulkExport:XLSXOptions' => 'Excel Options~~',
 	'Core:BulkExport:TextFormat' => 'Text fields containing some HTML markup~~',
 	'Core:BulkExport:TextFormat' => 'Text fields containing some HTML markup~~',
+	'Core:Validator:Default' => 'Wrong format~~',
+	'Core:Validator:Mandatory' => 'Please, fill this field~~',
+	'Core:Validator:MustBeInteger' => 'Must be an integer~~',
+	'Core:Validator:MustSelectOne' => 'Please, select one~~',
 ));
 ));
 
 
 ?>
 ?>

+ 4 - 0
dictionaries/fr.dictionary.itop.core.php

@@ -732,4 +732,8 @@ Opérateurs :<br/>
 	'Core:SyncSplitModeCLIOnly' => 'The synchronization can be executed in chunks only if run in mode CLI~~',
 	'Core:SyncSplitModeCLIOnly' => 'The synchronization can be executed in chunks only if run in mode CLI~~',
 	'Core:ExecProcess:Code1' => 'Wrong command or command finished with errors (e.g. wrong script name)~~',
 	'Core:ExecProcess:Code1' => 'Wrong command or command finished with errors (e.g. wrong script name)~~',
 	'Core:ExecProcess:Code255' => 'PHP Error (parsing, or runtime)~~',
 	'Core:ExecProcess:Code255' => 'PHP Error (parsing, or runtime)~~',
+	'Core:Validator:Default' => 'Format incorrect',
+	'Core:Validator:Mandatory' => 'Veuillez remplir ce champ',
+	'Core:Validator:MustBeInteger' => 'Ce champ ne peut contenir qu\'un nombre entier',
+	'Core:Validator:MustSelectOne' => 'Veuillez choisir une valeur',
 ));
 ));

+ 4 - 0
dictionaries/hu.dictionary.itop.core.php

@@ -604,5 +604,9 @@ Operators:<br/>
 	'Core:BulkExportLegacyExport' => 'Click here to access the legacy export.~~',
 	'Core:BulkExportLegacyExport' => 'Click here to access the legacy export.~~',
 	'Core:BulkExport:XLSXOptions' => 'Excel Options~~',
 	'Core:BulkExport:XLSXOptions' => 'Excel Options~~',
 	'Core:BulkExport:TextFormat' => 'Text fields containing some HTML markup~~',
 	'Core:BulkExport:TextFormat' => 'Text fields containing some HTML markup~~',
+	'Core:Validator:Default' => 'Wrong format~~',
+	'Core:Validator:Mandatory' => 'Please, fill this field~~',
+	'Core:Validator:MustBeInteger' => 'Must be an integer~~',
+	'Core:Validator:MustSelectOne' => 'Please, select one~~',
 ));
 ));
 ?>
 ?>

+ 4 - 0
dictionaries/it.dictionary.itop.core.php

@@ -850,6 +850,10 @@ Dict::Add('IT IT', 'Italian', 'Italiano', array(
 	'Core:DateTime:Placeholder_A' => 'AM/PM', // AM/PM (uppercase)
 	'Core:DateTime:Placeholder_A' => 'AM/PM', // AM/PM (uppercase)
 	'Core:DateTime:Placeholder_i' => 'mm', // minutes, 2 digits: 00..59
 	'Core:DateTime:Placeholder_i' => 'mm', // minutes, 2 digits: 00..59
 	'Core:DateTime:Placeholder_s' => 'ss', // seconds, 2 digits 00..59
 	'Core:DateTime:Placeholder_s' => 'ss', // seconds, 2 digits 00..59
+	'Core:Validator:Default' => 'Wrong format~~',
+	'Core:Validator:Mandatory' => 'Please, fill this field~~',
+	'Core:Validator:MustBeInteger' => 'Must be an integer~~',
+	'Core:Validator:MustSelectOne' => 'Please, select one~~',
 ));
 ));
 
 
 ?>
 ?>

+ 4 - 0
dictionaries/ja.dictionary.itop.core.php

@@ -626,5 +626,9 @@ Operators:<br/>
 	'Core:BulkExportLegacyExport' => 'Click here to access the legacy export.~~',
 	'Core:BulkExportLegacyExport' => 'Click here to access the legacy export.~~',
 	'Core:BulkExport:XLSXOptions' => 'Excel Options~~',
 	'Core:BulkExport:XLSXOptions' => 'Excel Options~~',
 	'Core:BulkExport:TextFormat' => 'Text fields containing some HTML markup~~',
 	'Core:BulkExport:TextFormat' => 'Text fields containing some HTML markup~~',
+	'Core:Validator:Default' => 'Wrong format~~',
+	'Core:Validator:Mandatory' => 'Please, fill this field~~',
+	'Core:Validator:MustBeInteger' => 'Must be an integer~~',
+	'Core:Validator:MustSelectOne' => 'Please, select one~~',
 ));
 ));
 ?>
 ?>

+ 4 - 0
dictionaries/nl.dictionary.itop.core.php

@@ -856,6 +856,10 @@ Dict::Add('NL NL', 'Dutch', 'Nederlands', array(
 	'Core:BulkExportLegacyExport' => 'Click here to access the legacy export.~~',
 	'Core:BulkExportLegacyExport' => 'Click here to access the legacy export.~~',
 	'Core:BulkExport:XLSXOptions' => 'Excel Options~~',
 	'Core:BulkExport:XLSXOptions' => 'Excel Options~~',
 	'Core:BulkExport:TextFormat' => 'Text fields containing some HTML markup~~',
 	'Core:BulkExport:TextFormat' => 'Text fields containing some HTML markup~~',
+	'Core:Validator:Default' => 'Wrong format~~',
+	'Core:Validator:Mandatory' => 'Please, fill this field~~',
+	'Core:Validator:MustBeInteger' => 'Must be an integer~~',
+	'Core:Validator:MustSelectOne' => 'Please, select one~~',
 ));
 ));
 
 
 ?>
 ?>

+ 4 - 0
dictionaries/pt_br.dictionary.itop.core.php

@@ -849,6 +849,10 @@ Dict::Add('PT BR', 'Brazilian', 'Brazilian', array(
 	'Core:BulkExportLegacyExport' => 'Click here to access the legacy export.~~',
 	'Core:BulkExportLegacyExport' => 'Click here to access the legacy export.~~',
 	'Core:BulkExport:XLSXOptions' => 'Excel Options~~',
 	'Core:BulkExport:XLSXOptions' => 'Excel Options~~',
 	'Core:BulkExport:TextFormat' => 'Text fields containing some HTML markup~~',
 	'Core:BulkExport:TextFormat' => 'Text fields containing some HTML markup~~',
+	'Core:Validator:Default' => 'Wrong format~~',
+	'Core:Validator:Mandatory' => 'Please, fill this field~~',
+	'Core:Validator:MustBeInteger' => 'Must be an integer~~',
+	'Core:Validator:MustSelectOne' => 'Please, select one~~',
 ));
 ));
 
 
 ?>
 ?>

+ 4 - 0
dictionaries/ru.dictionary.itop.core.php

@@ -858,6 +858,10 @@ Dict::Add('RU RU', 'Russian', 'Русский', array(
 	'Core:DateTime:Placeholder_A' => 'AM/PM', // AM/PM (uppercase)
 	'Core:DateTime:Placeholder_A' => 'AM/PM', // AM/PM (uppercase)
 	'Core:DateTime:Placeholder_i' => 'мм', // minutes, 2 digits: 00..59
 	'Core:DateTime:Placeholder_i' => 'мм', // minutes, 2 digits: 00..59
 	'Core:DateTime:Placeholder_s' => 'сс', // seconds, 2 digits 00..59
 	'Core:DateTime:Placeholder_s' => 'сс', // seconds, 2 digits 00..59
+	'Core:Validator:Default' => 'Wrong format~~',
+	'Core:Validator:Mandatory' => 'Please, fill this field~~',
+	'Core:Validator:MustBeInteger' => 'Must be an integer~~',
+	'Core:Validator:MustSelectOne' => 'Please, select one~~',
 ));
 ));
 
 
 ?>
 ?>

+ 4 - 0
dictionaries/tr.dictionary.itop.core.php

@@ -776,6 +776,10 @@ Operators:<br/>
 	'Core:BulkExportLegacyExport' => 'Click here to access the legacy export.~~',
 	'Core:BulkExportLegacyExport' => 'Click here to access the legacy export.~~',
 	'Core:BulkExport:XLSXOptions' => 'Excel Options~~',
 	'Core:BulkExport:XLSXOptions' => 'Excel Options~~',
 	'Core:BulkExport:TextFormat' => 'Text fields containing some HTML markup~~',
 	'Core:BulkExport:TextFormat' => 'Text fields containing some HTML markup~~',
+	'Core:Validator:Default' => 'Wrong format~~',
+	'Core:Validator:Mandatory' => 'Please, fill this field~~',
+	'Core:Validator:MustBeInteger' => 'Must be an integer~~',
+	'Core:Validator:MustSelectOne' => 'Please, select one~~',
 ));
 ));
 
 
 
 

+ 4 - 0
dictionaries/zh.dictionary.itop.core.php

@@ -775,6 +775,10 @@ Operators:<br/>
 	'Core:BulkExportLegacyExport' => 'Click here to access the legacy export.~~',
 	'Core:BulkExportLegacyExport' => 'Click here to access the legacy export.~~',
 	'Core:BulkExport:XLSXOptions' => 'Excel Options~~',
 	'Core:BulkExport:XLSXOptions' => 'Excel Options~~',
 	'Core:BulkExport:TextFormat' => 'Text fields containing some HTML markup~~',
 	'Core:BulkExport:TextFormat' => 'Text fields containing some HTML markup~~',
+	'Core:Validator:Default' => 'Wrong format~~',
+	'Core:Validator:Mandatory' => 'Please, fill this field~~',
+	'Core:Validator:MustBeInteger' => 'Must be an integer~~',
+	'Core:Validator:MustSelectOne' => 'Please, select one~~',
 ));
 ));
 
 
 
 

+ 32 - 0
sources/form/field/passwordfield.class.inc.php

@@ -0,0 +1,32 @@
+<?php
+
+// Copyright (C) 2010-2016 Combodo SARL
+//
+//   This file is part of iTop.
+//
+//   iTop is free software; you can redistribute it and/or modify	
+//   it under the terms of the GNU Affero General Public License as published by
+//   the Free Software Foundation, either version 3 of the License, or
+//   (at your option) any later version.
+//
+//   iTop is distributed in the hope that it will be useful,
+//   but WITHOUT ANY WARRANTY; without even the implied warranty of
+//   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+//   GNU Affero General Public License for more details.
+//
+//   You should have received a copy of the GNU Affero General Public License
+//   along with iTop. If not, see <http://www.gnu.org/licenses/>
+
+namespace Combodo\iTop\Form\Field;
+
+use \Combodo\iTop\Form\Field\TextField;
+
+/**
+ * Description of PasswordField
+ *
+ * @author Guillaume Lajarige <guillaume.lajarige@combodo.com>
+ */
+class PasswordField extends TextField
+{
+
+}

+ 1 - 1
sources/form/validator/integervalidator.class.inc.php

@@ -30,6 +30,6 @@ class IntegerValidator extends Validator
 {
 {
 	const VALIDATOR_NAME = 'integer';
 	const VALIDATOR_NAME = 'integer';
 	const DEFAULT_REGEXP = '^[0-9]+$';
 	const DEFAULT_REGEXP = '^[0-9]+$';
-	const DEFAULT_ERROR_MESSAGE = 'TOTR: MUST NOT BE AN INTEGER MESSAGE';
+	const DEFAULT_ERROR_MESSAGE = 'Core:Validator:MustBeInteger';
 
 
 }
 }

+ 1 - 1
sources/form/validator/mandatoryvalidator.class.inc.php

@@ -32,6 +32,6 @@ class MandatoryValidator extends Validator
 {
 {
 	const VALIDATOR_NAME = 'mandatory';
 	const VALIDATOR_NAME = 'mandatory';
 	const DEFAULT_REGEXP = '.*\S.*';
 	const DEFAULT_REGEXP = '.*\S.*';
-	const DEFAULT_ERROR_MESSAGE = 'TOTR: MANDATORY MESSAGE';
+	const DEFAULT_ERROR_MESSAGE = 'Core:Validator:Mandatory';
 
 
 }
 }

+ 1 - 1
sources/form/validator/notemptyextkeyvalidator.class.inc.php

@@ -30,6 +30,6 @@ class NotEmptyExtKeyValidator extends Validator
 {
 {
 	const VALIDATOR_NAME = 'notemptyextkey';
 	const VALIDATOR_NAME = 'notemptyextkey';
 	const DEFAULT_REGEXP = '^[1-9]+$';
 	const DEFAULT_REGEXP = '^[1-9]+$';
-	const DEFAULT_ERROR_MESSAGE = 'TOTR: MUST SELECT ONE';
+	const DEFAULT_ERROR_MESSAGE = 'Core:Validator:MustSelectOne';
 
 
 }
 }

+ 1 - 1
sources/form/validator/validator.class.inc.php

@@ -28,7 +28,7 @@ class Validator
 {
 {
 	const VALIDATOR_NAME = 'expression';
 	const VALIDATOR_NAME = 'expression';
 	const DEFAULT_REGEXP = '';
 	const DEFAULT_REGEXP = '';
-	const DEFAULT_ERROR_MESSAGE = 'TOTR: Core:Validator:Default';
+	const DEFAULT_ERROR_MESSAGE = 'Core:Validator:Default';
 
 
 	protected $sRegExp;
 	protected $sRegExp;
 	protected $sErrorMessage;
 	protected $sErrorMessage;