Is there a way to hide Description field?

General discussion of Mantis.

Moderators: Developer, Contributor

Post Reply
seizai
Posts: 16
Joined: 01 Aug 2013, 08:31

Is there a way to hide Description field?

Post by seizai »

I put this in config_inc.php but the description field still show.
$g_bug_report_page_fields = array(
'category_id',
'handler',
'summary',
'description',
'attachments',
);

Something I missed out?

another case...

I already hide tag function

$g_tag_view_threshold = NOBODY;
$g_tag_attach_threshold = NOBODY;

However in admin account under Manage, it still show Manage Tags. Is there a way to hide this too?
atrol
Site Admin
Posts: 8553
Joined: 26 Mar 2008, 21:37
Location: Germany

Re: Is there a way to hide Description field?

Post by atrol »

seizai wrote:I put this in config_inc.php but the description field still show.
$g_bug_report_page_fields = array(
'category_id',
'handler',
'summary',
'description',
'attachments',
);

Something I missed out?
Yes
remove the line with 'description' ;-)
seizai wrote:I already hide tag function

$g_tag_view_threshold = NOBODY;
$g_tag_attach_threshold = NOBODY;

However in admin account under Manage, it still show Manage Tags. Is there a way to hide this too?
add

Code: Select all

$g_tag_edit_threshold = NOBODY;
Please use Search before posting and read the Manual
seizai
Posts: 16
Joined: 01 Aug 2013, 08:31

Re: Is there a way to hide Description field?

Post by seizai »

opps.. sorry I post wrong code. I already took out the description & it still shows..

$g_bug_report_page_fields = array(
'category_id',
'handler',
'summary',
'attachments',
);


and

is there any code to control threshold for manage columns in myaccount?

TQ :mrgreen:
seizai
Posts: 16
Joined: 01 Aug 2013, 08:31

Re: Is there a way to hide Description field?

Post by seizai »

seizai wrote:opps.. sorry I post wrong code. I already took out the description & it still shows..

$g_bug_report_page_fields = array(
'category_id',
'handler',
'summary',
'attachments',
);


and

is there any code to control threshold for manage columns in myaccount?

TQ :mrgreen:
I follow this - http://www.mantisbt.org/forums/viewtopi ... =3&t=19987 - and it shows 2 manage columns in my account 8O

is there any way to hide from my account?
atrol
Site Admin
Posts: 8553
Joined: 26 Mar 2008, 21:37
Location: Germany

Re: Is there a way to hide Description field?

Post by atrol »

seizai wrote:opps.. sorry I post wrong code. I already took out the description & it still shows..

$g_bug_report_page_fields = array(
'category_id',
'handler',
'summary',
'attachments',
);
Sorry, I didn't check myself.
This is a known bug http://www.mantisbt.org/bugs/view.php?id=11472
seizai wrote: and

is there any code to control threshold for manage columns in myaccount?
Please don't mix different topics in one thread as this is hard to follow up.
Please use Search before posting and read the Manual
seizai
Posts: 16
Joined: 01 Aug 2013, 08:31

Re: Is there a way to hide Description field?

Post by seizai »

atrol wrote:
seizai wrote:opps.. sorry I post wrong code. I already took out the description & it still shows..

$g_bug_report_page_fields = array(
'category_id',
'handler',
'summary',
'attachments',
);
Sorry, I didn't check myself.
This is a known bug http://www.mantisbt.org/bugs/view.php?id=11472
Those 2 link down already
atrol
Site Admin
Posts: 8553
Joined: 26 Mar 2008, 21:37
Location: Germany

Re: Is there a way to hide Description field?

Post by atrol »

seizai wrote:Those 2 link down already
I tried to contact the user who is hosting git.mantisforge.org some weeks ago to setup the server again.
Unfortunately this did not happen until now (and maybe will never happen)
Maybe I will find some time to fix the bug (shouldn't be too hard) next weekend, but I can't promise anything.
Please use Search before posting and read the Manual
atrol
Site Admin
Posts: 8553
Joined: 26 Mar 2008, 21:37
Location: Germany

Re: Is there a way to hide Description field?

Post by atrol »

atrol wrote: Maybe I will find some time to fix the bug (shouldn't be too hard) next weekend, but I can't promise anything.
I was wrong.This is not a bug as the Description field is a mandatory field.
This can't be changed in MantisBT 1.2.x as there should be a new configuration option like $g_allow_empty_description with default setting to OFF to have 100% backward compatibility. Furthermore this would require deeper tests, as an empty description field might introduce regressions at various other places.
For future version there is a more general concept needed where every field can be mandatory or not, where every field can be visible on report page or not if if is not mandatory ....

If you want a quick and dirty hack in your own installation you have just to remove the following lines in file bug_report_page.php

Code: Select all

	<tr <?php echo helper_alternate_class() ?>>
		<td class="category">
			<span class="required">*</span><?php print_documentation_link( 'description' ) ?>
		</td>
		<td>
			<textarea <?php echo helper_get_tab_index() ?> name="description" cols="80" rows="10"><?php echo string_textarea( $f_description ) ?></textarea>
		</td>
	</tr>
Please use Search before posting and read the Manual
Post Reply