[solved] Redirect to table after bug creation / update?

Post about your customizations to share with others.

Moderators: Developer, Contributor

Post Reply
Tagirijus
Posts: 30
Joined: Dec 05, 2017 5:19 am
Contact:

[solved] Redirect to table after bug creation / update?

Post by Tagirijus »

Hey there,

I am currently trying to understand how it is possible to customize MantisBT without changing core code (which I did before ... but now I wanted to do it the right way after I updated MantisBT on my local server).

Is it somehow possible to let MantisBT redirect to the "view_all_bug_page.php" after I created an issue / a bug?


Till now I changed the redirect code in the bug_update.php, IIRC. But this is - obviously - a core file.

Thanks for your help! :)
Last edited by Tagirijus on Sep 30, 2020 7:46 am, edited 1 time in total.
cas
Posts: 906
Joined: Mar 11, 2006 11:08 am
Contact:

Re: Redirect to table after bug creation / update?

Post by cas »

I assume you adjusted bug_report.php since that is used to handle new issues.
Currently there is no alternative for what you ask :mrgreen:
Tagirijus
Posts: 30
Joined: Dec 05, 2017 5:19 am
Contact:

Re: Redirect to table after bug creation / update?

Post by Tagirijus »

cas wrote:
Sep 30, 2020 2:35 am
I assume you adjusted bug_report.php since that is used to handle new issues.
Eh, that could also be, sorry, yes. I had so many files open yesterday, while I wrote this thread, haha. :D


cas wrote:
Sep 30, 2020 2:35 am
Currently there is no alternative for what you ask
Hm, what a bummer. :( ... I am still trying to dig the plugin event hooks etc. Are you familiar with these and would say even with such event hooks it would not be possible?

Thanks for your reply, by the way! (=
cas
Posts: 906
Joined: Mar 11, 2006 11:08 am
Contact:

Re: Redirect to table after bug creation / update?

Post by cas »

With the standard available events it is not possible. Of course you can define your own events but then you need to adjust core files to add that event.
So think you are stuck with adjusting core files. Biggest challenge there is to maintain a complete overview of all changes made in case of future updates.
Possibly for other customizations plugins do exist, so do not give up :mrgreen:
Tagirijus
Posts: 30
Joined: Dec 05, 2017 5:19 am
Contact:

Re: Redirect to table after bug creation / update?

Post by Tagirijus »

cas wrote:
Sep 30, 2020 4:31 am
Biggest challenge there is to maintain a complete overview of all changes made in case of future updates.
Exactly, haha. :D

cas wrote:
Sep 30, 2020 4:31 am
Possibly for other customizations plugins do exist, so do not give up :mrgreen:
Thanks for your help, though. (=
Tagirijus
Posts: 30
Joined: Dec 05, 2017 5:19 am
Contact:

Re: Redirect to table after bug creation / update?

Post by Tagirijus »

Weeeeeeell, haha. :D I made it! I actually started to write a plugin, which allows me (or others, since I made it public!) to enable some workflow tweaks. The "redirect to table after report or update" is one of these points. Feel free to use it:

https://github.com/Tagirijus/MantisBTTagiWorkflow


I am still working on it!
cas
Posts: 906
Joined: Mar 11, 2006 11:08 am
Contact:

Re: [solved] Redirect to table after bug creation / update?

Post by cas »

Nice, will try it out. Just wondering about the action to give new status to issue when assigned since this is standard available 8O
Tagirijus
Posts: 30
Joined: Dec 05, 2017 5:19 am
Contact:

Re: [solved] Redirect to table after bug creation / update?

Post by Tagirijus »

cas wrote:
Sep 30, 2020 1:28 pm
Just wondering about the action to give new status to issue when assigned since this is standard available 8O
Do you mean the option on the work threshold page? Somehow this option has no effect here ... or I simply don't understand it. But in the end my plugin works like I want it to, for now, hehe.
cas
Posts: 906
Joined: Mar 11, 2006 11:08 am
Contact:

Re: [solved] Redirect to table after bug creation / update?

Post by cas »

it is a standard config as you can find in config_defaults_inc.php
Tagirijus
Posts: 30
Joined: Dec 05, 2017 5:19 am
Contact:

Re: [solved] Redirect to table after bug creation / update?

Post by Tagirijus »

Ah okay ... maybe I should have digged this then. But too late and nevermind. Thanks, though! (=
cas
Posts: 906
Joined: Mar 11, 2006 11:08 am
Contact:

Re: [solved] Redirect to table after bug creation / update?

Post by cas »

Suggest you examine config_defaults_inc.php so you get a feel what is already standard available, most likely more than you expect :mrgreen:
Tagirijus
Posts: 30
Joined: Dec 05, 2017 5:19 am
Contact:

Re: [solved] Redirect to table after bug creation / update?

Post by Tagirijus »

I just took some time to watch through the whole file: thanks for the hint, since I found some development and logging / error display options, which might become handy in the future, when developing, hehe.

Besides this, I did not find anything useful for my workflow wishes, unfortunately. The $g_bug_assigned_status did not work as I thought it would (actually it didn't make a difference). Either its buggy, or it's just something completely different than I expected, hehe. Again: I stick to my workflow plugin. It's almost done anyway. (=

Thanks again!!
Post Reply