View Issue Details

IDProjectCategoryView StatusLast Update
0016975mantisbtlocalizationpublic2014-12-08 00:34
ReporterbadfilesAssigned Todregad 
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
Product Version1.2.17 
Target Version1.3.0-beta.1Fixed in Version1.3.0-beta.1 
Summary0016975: Invalid enumeration string value displayed if localized value does not exist
Description

There is an unnamed custom field type @10@.

TagsNo tags attached.

Activities

atrol

atrol

2014-02-15 13:47

developer   ~0039413

badfiles,

I was not able to reproduce your problem.

Please provide detailed, step-by-step instructions to reproduce the issue.

badfiles

badfiles

2014-02-15 15:00

reporter   ~0039414

this is a translation issue, my language file lacks in custom_field_type_enum_string '10:textarea'.

badfiles

badfiles

2014-02-15 15:05

reporter   ~0039415

looks like fallback to English does not work for enums

atrol

atrol

2014-02-15 15:08

developer   ~0039416

Will be fixed after we switch translatewiki to master and translators updated translation.

atrol

atrol

2014-02-15 15:12

developer   ~0039417

looks like fallback to English does not work for enums
The fallback works only for the whole string but not parts of the string.

grangeway

grangeway

2014-05-27 07:45

reporter   ~0040651

Atrol,

I've generated PR with a fix for this: https://github.com/mantisbt/mantisbt/pull/198

grangeway

grangeway

2014-06-01 17:06

reporter   ~0040697

Reminder sent to: rombert

Added test case for rombert to review

grangeway

grangeway

2014-06-01 17:09

reporter   ~0040698

Reminder sent to: vboctor

Victor: Where do you stand on fixing this issue?

From a code point of view, you didn't follow the fix, so i'm just making sure you've also read this bug report.

In addition, if we aren't happy with the implementation approach i've taken so far, we need to decide on an alternative approach to implementing the code change for this bug.

grangeway

grangeway

2014-06-01 17:10

reporter   ~0040699

Reminder sent to: atrol

Atrol, do you have any thoughts on this PR atm?

atrol

atrol

2014-06-02 16:49

developer   ~0040724

Will be fixed after we switch translatewiki to master and translators updated translation.
I thought there is no code change needed when writing this

fallback works only for the whole string but not parts of the string.
I thought this is an acceptable behavior

grangeway

grangeway

2014-06-02 16:53

reporter   ~0040725

For some of our lesser used languages (And especially if users add their own custom statuses) the fallback could be useful.

For the core project and popular languages, it's likely to get translated, but if a user customises one of the enumerations for their own internal needs, they might not be able to translate it into all languages, hence we do need to fix this.

atrol

atrol

2014-06-02 17:40

developer   ~0040726

@grangeway, your PR is probably an enhancement and looks good at first sight. (didn't test anything)

Related Changesets

MantisBT: master 4fbd340f

2014-05-31 09:57:47

Paul Richards


Committer: dregad Details Diff
Fix invalid enumeration string value display

Prior to this, an invalid enumeration string value (e.g. @32@) was
displayed if the corresponding localized value did not exist.

This allows fallback to English language for individual enum elements.

Fixes 0016975, https://github.com/mantisbt/mantisbt/pull/198

Signed-off-by: Damien Regad <dregad@mantisbt.org>
mod - core/classes/MantisEnum.class.php Diff File
mod - tests/Mantis/EnumTest.php Diff File

Issue History

Date Modified Username Field Change
2014-02-15 12:39 badfiles New Issue
2014-02-15 13:47 atrol Note Added: 0039413
2014-02-15 13:47 atrol Status new => feedback
2014-02-15 15:00 badfiles Note Added: 0039414
2014-02-15 15:00 badfiles Status feedback => new
2014-02-15 15:03 atrol Status new => confirmed
2014-02-15 15:03 atrol Category custom fields => localization
2014-02-15 15:03 atrol Target Version => 1.3.0-beta.1
2014-02-15 15:05 badfiles Note Added: 0039415
2014-02-15 15:08 atrol Note Added: 0039416
2014-02-15 15:12 atrol Note Added: 0039417
2014-05-26 18:42 grangeway Assigned To => grangeway
2014-05-26 18:42 grangeway Status confirmed => assigned
2014-05-27 07:45 grangeway Note Added: 0040651
2014-05-27 14:54 grangeway Summary Unnamed type => Invalid enumeration string value displayed if localized value does not exist
2014-06-01 17:06 grangeway Note Added: 0040697
2014-06-01 17:09 grangeway Note Added: 0040698
2014-06-01 17:10 grangeway Note Added: 0040699
2014-06-02 16:49 atrol Note Added: 0040724
2014-06-02 16:53 grangeway Note Added: 0040725
2014-06-02 17:40 atrol Note Added: 0040726
2014-07-07 09:03 dregad Changeset attached => MantisBT master 4fbd340f
2014-07-07 09:03 dregad Assigned To grangeway => dregad
2014-07-07 09:03 dregad Status assigned => resolved
2014-07-07 09:03 dregad Resolution open => fixed
2014-07-07 09:03 dregad Fixed in Version => 1.3.0-beta.1
2014-07-07 09:04 dregad Product Version git trunk => 1.2.17
2014-12-08 00:34 vboctor Status resolved => closed