Skip to content

Commit

Permalink
Hotfix - Administración - Valores por defecto de DateTime traducidos …
Browse files Browse the repository at this point in the history
…y valor "first day of next month" corregido (#488)
  • Loading branch information
ainaraRT authored Dec 19, 2024
1 parent dbbaeb6 commit 9e2787a
Show file tree
Hide file tree
Showing 5 changed files with 65 additions and 30 deletions.
17 changes: 9 additions & 8 deletions include/language/ca_ES.lang.php
Original file line number Diff line number Diff line change
Expand Up @@ -2052,23 +2052,24 @@
'LBL_DESCRIPTION' => 'Descripció',

'LBL_YESTERDAY' => 'ahir',
'LBL_NOW' => 'ara',
'LBL_TODAY' => 'avui',
'LBL_TOMORROW' => 'demà',
'LBL_NEXT_WEEK' => 'la setmana vinent',
'LBL_NEXT_MONDAY' => 'el dilluns vinent',
'LBL_NEXT_FRIDAY' => 'el divendres vinent',
'LBL_TWO_WEEKS' => 'dues setmanes',
'LBL_TWO_WEEKS' => "d'aquí a dues setmanes",
'LBL_NEXT_MONTH' => 'el mes vinent',
'LBL_FIRST_DAY_OF_NEXT_MONTH' => 'el primer dia del mes vinent',
'LBL_THREE_MONTHS' => 'tres mesos',
'LBL_SIXMONTHS' => 'sis mesos',
'LBL_NEXT_YEAR' => 'l\'any següent',
'LBL_THREE_MONTHS' => "d'aquí a tres mesos",
'LBL_SIXMONTHS' => "d'aquí a sis mesos",
'LBL_NEXT_YEAR' => "l'any vinent",

//Datetimecombo fields
'LBL_HOURS' => 'Hores',
'LBL_MINUTES' => 'Minuts',
'LBL_MERIDIEM' => 'Meridiem',
'LBL_DATE' => 'Fecha',
'LBL_DATE' => 'Data',
'LBL_DASHLET_CONFIGURE_AUTOREFRESH' => 'Auto-Refrescar',

'LBL_DURATION_DAY' => 'dia',
Expand All @@ -2079,9 +2080,9 @@
'LBL_DURATION_MINUTES' => 'Minuts de durada',

//Calendar widget labels
'LBL_CHOOSE_MONTH' => 'Triï mes',
'LBL_ENTER_YEAR' => 'Triï any',
'LBL_ENTER_VALID_YEAR' => 'Si us plau, entri un any vàlid',
'LBL_CHOOSE_MONTH' => 'Trieu el mes',
'LBL_ENTER_YEAR' => "Trieu l'any",
'LBL_ENTER_VALID_YEAR' => 'Indiqueu un any vàlid',

//File write error label
'ERR_FILE_WRITE' => 'Error: No es pot escriure el fitxer {0}. Si us plau, comprovi els permisos del sistema i del servidor web.',
Expand Down
4 changes: 4 additions & 0 deletions include/language/en_us.lang.php
Original file line number Diff line number Diff line change
Expand Up @@ -1999,6 +1999,10 @@
'LBL_DESCRIPTION' => 'Description',

'LBL_YESTERDAY' => 'yesterday',
// STIC-Custom 20241126 ART - Translated Default Datetime Values
// https://github.com/SinergiaTIC/SinergiaCRM/pull/488
'LBL_NOW' => 'now',
// END STIC-Custom
'LBL_TODAY' => 'today',
'LBL_TOMORROW' => 'tomorrow',
'LBL_NEXT_WEEK' => 'next week',
Expand Down
3 changes: 2 additions & 1 deletion include/language/es_ES.lang.php
Original file line number Diff line number Diff line change
Expand Up @@ -2054,7 +2054,8 @@
'LBL_ASSIGNED_TO_NAME' => 'Asignado a',
'LBL_DESCRIPTION' => 'Descripción',

'LBL_YESTERDAY' => 'Ayer',
'LBL_YESTERDAY' => 'ayer',
'LBL_NOW' => 'ahora',
'LBL_TODAY' => 'hoy',
'LBL_TOMORROW' => 'mañana',
'LBL_NEXT_WEEK' => 'la semana que viene',
Expand Down
3 changes: 2 additions & 1 deletion include/language/gl_ES.lang.php
Original file line number Diff line number Diff line change
Expand Up @@ -2054,7 +2054,8 @@
'LBL_ASSIGNED_TO_NAME' => 'Asignado a',
'LBL_DESCRIPTION' => 'Descrición',

'LBL_YESTERDAY' => 'Onte',
'LBL_YESTERDAY' => 'onte',
'LBL_NOW' => 'ahora',
'LBL_TODAY' => 'hoxe',
'LBL_TOMORROW' => 'mañá',
'LBL_NEXT_WEEK' => 'a semana que ven',
Expand Down
68 changes: 48 additions & 20 deletions modules/DynamicFields/templates/Fields/TemplateDatetimecombo.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,26 +48,54 @@ class TemplateDatetimecombo extends TemplateRange
{
public $type = 'datetimecombo';
public $len = '';
public $dateStrings = array(
'-none-' => '',
// STIC-Custom 20221229 AAM - Adding "now" option to default datetime values
// STIC#949
// 'today'=>'now',
'now' => 'now',
'today'=> 'today',
// END STIC-Custom
'yesterday'=> '-1 day',
'tomorrow'=>'+1 day',
'next week'=> '+1 week',
'next monday'=>'next monday',
'next friday'=>'next friday',
'two weeks'=> '+2 weeks',
'next month'=> '+1 month',
'first day of next month'=> 'first of next month', // must handle this non-GNU date string in SugarBean->populateDefaultValues; if we don't this will evaluate to 1969...
'three months'=> '+3 months', //kbrill Bug #17023
'six months'=> '+6 months',
'next year'=> '+1 year',
);
// STIC-Custom 20241126 ART - Translated Default Datetime Values
// https://github.com/SinergiaTIC/SinergiaCRM/pull/488
// public $dateStrings = array(
// '-none-' => '',
// // STIC-Custom 20221229 AAM - Adding "now" option to default datetime values
// // STIC#949
// // 'today'=>'now',
// 'now' => 'now',
// 'today'=> 'today',
// // END STIC-Custom
// 'yesterday'=> '-1 day',
// 'tomorrow'=>'+1 day',
// 'next week'=> '+1 week',
// 'next monday'=>'next monday',
// 'next friday'=>'next friday',
// 'two weeks'=> '+2 weeks',
// 'next month'=> '+1 month',
// 'first day of next month'=> 'first of next month', // must handle this non-GNU date string in SugarBean->populateDefaultValues; if we don't this will evaluate to 1969...
// 'three months'=> '+3 months', //kbrill Bug #17023
// 'six months'=> '+6 months',
// 'next year'=> '+1 year',
// );
public $dateStrings;

public function __construct()
{
parent::__construct();
global $app_strings;
$this->dateStrings = array(
$app_strings['LBL_NONE']=>'',
$app_strings['LBL_NOW'] => 'now',
$app_strings['LBL_YESTERDAY']=> '-1 day',
$app_strings['LBL_TODAY']=>'today',
$app_strings['LBL_TOMORROW']=>'+1 day',
$app_strings['LBL_NEXT_WEEK']=> '+1 week',
$app_strings['LBL_NEXT_MONDAY']=>'next monday',
$app_strings['LBL_NEXT_FRIDAY']=>'next friday',
$app_strings['LBL_TWO_WEEKS']=> '+2 weeks',
$app_strings['LBL_NEXT_MONTH']=> '+1 month',
// Changed the value because “first of next moth” was generating an error
// https://github.com/SinergiaTIC/SinergiaCRM/issues/99
$app_strings['LBL_FIRST_DAY_OF_NEXT_MONTH']=> 'first day of next month', // must handle this non-GNU date string in SugarBean->populateDefaultValues; if we don't this will evaluate to 1969...
$app_strings['LBL_THREE_MONTHS']=> '+3 months', //kbrill Bug #17023
$app_strings['LBL_SIXMONTHS']=> '+6 months',
$app_strings['LBL_NEXT_YEAR']=> '+1 year',
);
}
// END STIC-Custom

public $hoursStrings = array(
'' => '',
Expand Down

0 comments on commit 9e2787a

Please sign in to comment.