Call bug_report_page.php with query params to pre-fill form?

Post about your customizations to share with others.

Moderators: Developer, Contributor

Post Reply
GeoffM
Posts: 6
Joined: 24 Feb 2008, 21:58

Call bug_report_page.php with query params to pre-fill form?

Post by GeoffM »

Is there a way to call bug_report_page.php (to submit a new ticket) with URL query parameters in order to pre-fill certain fields? Often a user will report an issue with our software via our forum and then an administrator has to separately go into Mantis and copy relevant details from the post. It would be nice if our forum software could have a button for administrators which calls a URL to have some of those details already set up. I don't think we can use the REST API as we don't have data for the mandatory fields.

Something like [a href="hxxps://mantis.mywebsite.com/bug_report_page.php?summary=the_forum_posts_title&additional_information=forum_post_id_12345"]

I suspect we could write a new PHP page/file which interfaces to the bug_report_page.php logic somehow, preferably without touching the official Mantis code at all, but just wondering if there already is a feature like this that I've missed.

Thanks.
cas
Posts: 1586
Joined: 11 Mar 2006, 16:08
Contact:

Re: Call bug_report_page.php with query params to pre-fill form?

Post by cas »

There is a development to introduce a simple screen issue entry where your customers only have to fill in a minimal data set. Then customers are more willing to use that form and you would not need anything else.
If you are interested I can share a few screenshots :mrgreen:
atrol
Site Admin
Posts: 8366
Joined: 26 Mar 2008, 21:37
Location: Germany

Re: Call bug_report_page.php with query params to pre-fill form?

Post by atrol »

GeoffM wrote: 16 Dec 2022, 03:37
Something like [a href="hxxps://mantis.mywebsite.com/bug_report_page.php?summary=the_forum_posts_title&additional_information=forum_post_id_12345"]
That works

Code: Select all

https://www.mantisbt.org/bugs/bug_report_page.php?summary=Hello&additional_info=Additional
There are also configuration parameters, check the Amdin Guide for that, e. g. there is $g_default_bug_additional_info (and some more)
Please use Search before posting and read the Manual
GeoffM
Posts: 6
Joined: 24 Feb 2008, 21:58

Re: Call bug_report_page.php with query params to pre-fill form?

Post by GeoffM »

cas wrote: 16 Dec 2022, 07:45 There is a development to introduce a simple screen issue entry where your customers only have to fill in a minimal data set. Then customers are more willing to use that form and you would not need anything else.
If you are interested I can share a few screenshots :mrgreen:
Ooh, sounds interesting. I'm very wary of customers submitting nonsense though, whether maliciously or "not a bug". Do these issues go into a kind of holding pattern until a proper use comes along and either approves or rejects them?
GeoffM
Posts: 6
Joined: 24 Feb 2008, 21:58

Re: Call bug_report_page.php with query params to pre-fill form?

Post by GeoffM »

atrol wrote: 16 Dec 2022, 08:49
GeoffM wrote: 16 Dec 2022, 03:37
Something like [a href="hxxps://mantis.mywebsite.com/bug_report_page.php?summary=the_forum_posts_title&additional_information=forum_post_id_12345"]
That works

Code: Select all

https://www.mantisbt.org/bugs/bug_report_page.php?summary=Hello&additional_info=Additional
There are also configuration parameters, check the Amdin Guide for that, e. g. there is $g_default_bug_additional_info (and some more)
Oh, :oops: maybe I should have just tried it! I did flick through the Developer guide but not the Admin guide. Thanks, sounds like it's what I want!
cas
Posts: 1586
Joined: 11 Mar 2006, 16:08
Contact:

Re: Call bug_report_page.php with query params to pre-fill form?

Post by cas »

GeoffM wrote: 16 Dec 2022, 17:55 Ooh, sounds interesting. I'm very wary of customers submitting nonsense though, whether maliciously or "not a bug". Do these issues go into a kind of holding pattern until a proper use comes along and either approves or rejects them?
One could ensure they first get into a special project where someone can judge the reported issues before they are taken too seriously :lol:
cas
Posts: 1586
Joined: 11 Mar 2006, 16:08
Contact:

Re: Call bug_report_page.php with query params to pre-fill form?

Post by cas »

By the way, you could also use the email_reporting plugin. One of the features is doing something similar
All reported so-called issues go into a project from where you can do your review.
Post Reply