Page 1 of 2

When editing displays @30@

Posted: 23 Nov 2012, 12:57
by M@rce
Hi everybody,

I did changes in config_inc.php and manage config by Mantis Admin, but now appears symbols like @30@ when I am viewing a bug.

Prioridad @30@ Severidad @50@ Reproducibilidad @70@

But when I am editing appears the correct value...

Have anyone any idea what occurs this?

Thanks.

Re: When editing displays @30@

Posted: 29 Nov 2012, 14:48
by M@rce
In attachment other example with similar conditions.
Can anybody help me?

Regards.

Re: When editing displays @30@

Posted: 29 Nov 2012, 18:16
by M@rce
A new clue to decipher the doubt: If I change the order of items in the array, always is the first element that appears with @0@

Re: When editing displays @30@

Posted: 14 Jan 2013, 12:35
by M@rce
The same trouble with status in Mantis: I have modify the files string_spanish (s_status_enum_string) and config_inc (g_status_enum_string) to add new status ('10:nueva,20:se necesitan más datos,30:aceptada,40:confirmada,50:asignada,80:resuelta,90:cerrada;100:corregida;110:subida a test') but in the frontend always displays @0@ or @10@.
Can anybody help me?

Re: When editing displays @30@

Posted: 14 Jan 2013, 22:51
by atrol
Does the problem also occur if you make your customizations the recommend way?
This means you don't change any existing MantisBT file, but use custom_strings_inc.php for localization.
http://www.mantisbt.org/docs/master-1.2 ... MIZE.ENUMS

Re: When editing displays @30@

Posted: 15 Jan 2013, 14:01
by M@rce
@Atrol: thanks, but don't work although I made the modifications on files :-(

custom_strings_inc.php

Code: Select all

# custom_strings_inc.php

<?php 
if ( lang_get_current() == 'spanish' ) {
									$s_severity_enum_string =
                            '10:funcionalidad,20:trivial,30:texto,40:ajuste,50:menor,60:mayor,70:fallo,80:bloqueo,90:ALTA,100:MEDIA,110:BAJA'; } 
#code that I have uncomment
									else {
									$s_status_enum_string =
                            '10:new,20:feedback,30:acknowledged,40:confirmed,50:assigned,80:resolved,90:closed,100:corrected,110:uploaded in test'; }  ?>
custom_constant_inc.php

Code: Select all

# custom_constant_inc.php
<?php

define( 'ALTA', 90);
define( 'MEDIA', 100 );
define( 'BAJA', 110 );

#define( 'corregida', 100 );
#define( 'subida a test', 110);

define( 'CORRECTED', 100);
define( 'UPLOADED IN TEST', 110);

?>
Adding even the values in constant_inc.php or config_defaults.php to see the behavior of Mantis does not resolved the error and still view @0@. What i do?

Re: When editing displays @30@

Posted: 15 Jan 2013, 14:37
by atrol
Is there also a file custom_constants_inc.php in your installation?

Re: When editing displays @30@

Posted: 15 Jan 2013, 14:43
by atrol
There is probably an error custom_strings_inc.php
You set $s_status_enum_string instead of $s_severity_enum_string for non spanish settings

Re: When editing displays @30@

Posted: 15 Jan 2013, 15:58
by M@rce
atrol wrote:Is there also a file custom_constants_inc.php in your installation?
Yes...and the code is above in my previous message.

Do you say that options in the code

Code: Select all

else {
									$s_status_enum_string =
                            '10:new,20:feedback,30:acknowledged,40:confirmed,50:assigned,80:resolved,90:closed,100:corrected,110:uploaded in test'; }
must be in spanish? this values are by default, I have not changed even.

Re: When editing displays @30@

Posted: 15 Jan 2013, 16:12
by atrol
M@rce wrote:
atrol wrote:Is there also a file custom_constants_inc.php in your installation?
Yes...and the code is above in my previous message.
No, your code is in file custom_constant_inc.php
I asked for custom_constants_inc.php
Didn't you notice the red bold s?
M@rce wrote: Do you say that options in the code

Code: Select all

else {
									$s_status_enum_string =
                            '10:new,20:feedback,30:acknowledged,40:confirmed,50:assigned,80:resolved,90:closed,100:corrected,110:uploaded in test'; }
must be in spanish? this values are by default, I have not changed even.
Why do you change $s_status_enum_string if you want to change severity?

Re: When editing displays @30@

Posted: 15 Jan 2013, 18:51
by M@rce
atrol wrote:Didn't you notice the red bold s?
Really not, sorry! Being well, I don't have this file...I it set up then? With what values?
atrol wrote:Why do you change $s_status_enum_string if you want to change severity?
The initial report was for "Priority" (even not solved) not "Severity", but now is also for "Status"; when is solved, can be the solution to both?

Re: When editing displays @30@

Posted: 15 Jan 2013, 20:19
by atrol
M@rce wrote:
atrol wrote:Didn't you notice the red bold s?
Really not, sorry! Being well, I don't have this file...I it set up then? With what values?
First MantisBT looks for custom_constants_inc.php , if the file can not be found it looks for custom_constant_inc.php . This happens for backward compatibility with older versions and will be removed in future versions.
So you should only use custom_constants_inc.php

Ok, let's concentrate on one thing and not mixing up status, severity and priority.
Let's introduce a new status, which is the hardest one.

First of all I recommend that you start with a clean state, which means:
No custom_constant_inc.php , no custom_constants_inc.php , no custom_strings_inc.php , no changes in any of the language files in directory lang, no changes in config_defaults_inc.php, no entries in config_inc.php for any enum related settings.
After that follow exactly the steps described at
http://www.mantisbt.org/docs/master-1.2 ... IZE.STATUS
Come back if there are still any problems.

By the way, which version of MantisBT do you use?

Re: When editing displays @30@

Posted: 16 Jan 2013, 11:30
by M@rce
atrol wrote:By the way, which version of MantisBT do you use?
The version that I use is 1.2.5

Well, I will do that you say and then comment to you the results. Thanks!!

Re: When editing displays @30@

Posted: 16 Jan 2013, 12:03
by atrol
M@rce wrote: The version that I use is 1.2.5
As a first step I recommend to update to latest stable version (1.2.12 at the moment)
There are more than 280 fixes/enhancements since 1.2.5, some of them related to enums and customization.

Re: When editing displays @30@

Posted: 16 Jan 2013, 12:42
by M@rce
atrol wrote:As a first step I recommend to update to latest stable version (1.2.12 at the moment)
There are more than 280 fixes/enhancements since 1.2.5, some of them related to enums and customization.
Okay...this change my plans but I will do anyway; in this case, do you think Atrol, that is necessary make the changes metioned, more early, in custom and config files?..thanks again!