From 4fb649e343e0938f2bcd46d84d7d3219d99e337e Mon Sep 17 00:00:00 2001 From: Julio Montoya Date: Mon, 12 Nov 2012 16:54:00 +0100 Subject: [PATCH] Adding add_meses_label_to_extra_field_fase function see BT#5186 --- tests/migrate/migration.custom.class.php | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/tests/migrate/migration.custom.class.php b/tests/migrate/migration.custom.class.php index 9b260a5583..211d6fdda2 100644 --- a/tests/migrate/migration.custom.class.php +++ b/tests/migrate/migration.custom.class.php @@ -64,6 +64,15 @@ class MigrationCustom { return utf8_encode($value); } + static function add_meses_label_to_extra_field_fase($value, $data, $row_data) { + $label = 'meses'; + if ($row_data['chrOrdenFase'] == 1) { + $label = 'mes'; + } + $value = $row_data['vchNombreFase'] .' ['.trim($row_data['chrOrdenFase']).' '.$label.']'; + return self::clean_utf8($value); + } + static function clean_session_name($value, $omigrate, $row_data) { return self::clean_utf8($row_data['session_name']); }