How to hide 'Duplicate ID' field

Post about your customizations to share with others.

Moderators: Developer, Contributor

Post Reply
andreas.panozzo
Posts: 4
Joined: 23 Dec 2020, 12:22

How to hide 'Duplicate ID' field

Post by andreas.panozzo »

Hello,
I'd like to hide 'Duplicate ID' filed on the Resolve issue tab.
Please, some one could suggest me a way for that?

Thanks in advance.
Andreas
Attachments
Untitled.png
Untitled.png (30.45 KiB) Viewed 10683 times
cas
Posts: 1586
Joined: 11 Mar 2006, 16:08
Contact:

Re: How to hide 'Duplicate ID' field

Post by cas »

That depends on the value of your resolution field.
In bug_change_status.php you have the following code

Code: Select all

		if( $t_resolution != config_get( 'bug_duplicate_resolution' ) ) {
?>
<!-- Duplicate ID -->
			<tr>
				<th class="category">
					<?php echo lang_get( 'duplicate_id' ) ?>
				</th>
				<td>
					<input type="text" class="input-sm" name="duplicate_id" maxlength="10" />
				</td>
			</tr>

<?php
		}
config_get( 'bug_duplicate_resolution' ) is standard set to "DUPLICATE". To me it does not make much sense, actually think it is a bug.
It should read :

Code: Select all

if( $t_resolution == config_get( 'bug_duplicate_resolution' ) ) {
If you make that change, it will work as expected :mrgreen:
andreas.panozzo
Posts: 4
Joined: 23 Dec 2020, 12:22

Re: How to hide 'Duplicate ID' field

Post by andreas.panozzo »

It works!
Many thanks.
Andreas
cas
Posts: 1586
Joined: 11 Mar 2006, 16:08
Contact:

Re: How to hide 'Duplicate ID' field

Post by cas »

Be aware that with a future update you may have to do the change again.
I did register this as a bug but it appeared to be on purpose. So you still van indicate the issue as a duplicate even when the resolution was not stated as duplicate 8O
Post Reply