how to add

Post about your customizations to share with others.

Moderators: Developer, Contributor

Post Reply
amartlk
Posts: 15
Joined: 04 Jan 2011, 07:47

how to add

Post by amartlk »

hi

i have to add some fields in Report issue tab i.e in Report issue tab -there is severity i need to add some fileds in severity list when i click on severity i get a list here i want to add some field in this list pls help

Amar
amartlk
Posts: 15
Joined: 04 Jan 2011, 07:47

Re: how to add

Post by amartlk »

pls reply
SystemCorp
Posts: 13
Joined: 21 Mar 2011, 06:23

Re: how to add

Post by SystemCorp »

If you haven't found it already, this is covered in the wiki
http://www.mantisbt.org/wiki/doku.php/mantisbt:faq

Hope this helps
amartlk
Posts: 15
Joined: 04 Jan 2011, 07:47

Re: how to add

Post by amartlk »

hi

i refer link given i add some file mantis/core/constant_inc.php under severity
severity i add some fileds here as define( 'trail', 90 ); below the last line but still not shown in severity columns , pls help
define( 'FEATURE', 10 );
define( 'TRIVIAL', 20 );
define( 'TEXT', 30 );
define( 'TWEAK', 40 );
define( 'MINOR', 50 );
define( 'MAJOR', 60 );
define( 'CRASH', 70 );
define( 'BLOCK', 80 );
define( 'trail', 90 );

Amar
SystemCorp
Posts: 13
Joined: 21 Mar 2011, 06:23

Re: how to add

Post by SystemCorp »

I note that all the other fields are in capitals, as well as the examples provided, but the final product is in lowecase, perhaps setting the ('trail', 90) to ('TRAIL', 90)?

Not sure, haven't dug into this too much yet, but I will be over the next couple of days. If I get a definitive answer, I'll let you know.
cor3huis
Posts: 21
Joined: 15 Jan 2010, 21:24

Re: how to add

Post by cor3huis »

Did you find out?
SystemCorp
Posts: 13
Joined: 21 Mar 2011, 06:23

Re: how to add

Post by SystemCorp »

According to the manual:

1. Create a new file in your mantisbt install called: custom_constant_inc.php
2. Add a new line to this file, in this case:

Code: Select all

define( 'TRAIL', 90 );
3. Create and modify 'config_inc.php' and make the following changes:

Code: Select all

$g_severity_enum_string =
    '10:feature,20:trivial,30:text,40:tweak,50:minor,60:major,70:crash,80:block,90:trail';
4. Create and modify 'custom_strings_inc.php' with the following:

Code: Select all

if ( lang_get_current() === 'english' ) {
    $s_severity_enum_string =
       '10:feature,20:trivial,30:text,40:tweak,50:minor,60:major,70:crash,80:block,90:trail';
}
To use these steps for other enumerations, find the $g_<variable_name>_enum_string and replace the relevant parts.
If you are using another language you will need to repeat the 4th step for each language you are using.

I haven't tested this yet, as I no longer need to implement it in-house, good luck!
Post Reply