How to Add Fied to Mangament Project Page?

Get help from other users here.

Moderators: Developer, Contributor

danilolutz
Posts: 9
Joined: 12 Apr 2012, 12:26
Contact:

How to Add Fied to Mangament Project Page?

Post by danilolutz »

Hi,

How to Add Field to Mangament Project Page?

This field would be added below the project name field and will be a dropdown field.

I'm developing a plugin for this... but until now, i see new fields added in bugs page only!

Someone can help me?

Note: Sorry if this post already exists, I could't find it!

Thank's
Danilo Lutz.
istvanb
Posts: 226
Joined: 22 Aug 2010, 21:00

Re: How to Add Fied to Mangament Project Page?

Post by istvanb »

There is no easy way to do that, you have to edit the /mantis/manage_proj_edit_page.php page directly.

Custom fields appear only for the issues, which makes sense. What would be the purpose of the new field?
danilolutz
Posts: 9
Joined: 12 Apr 2012, 12:26
Contact:

Re: How to Add Fied to Mangament Project Page?

Post by danilolutz »

hi, istvanb !
Thank,s for helping!

This is a project type field. It's must be linked to the project and dosen't to the bug!

I have made the plugin with table, inserting, updating data.
I cannot insert the new field in the mantis management project page only! Like new fields added by plugins on the bug's page.

Thank's!
istvanb
Posts: 226
Joined: 22 Aug 2010, 21:00

Re: How to Add Fied to Mangament Project Page?

Post by istvanb »

Dan,

as I said, you can not add custom fields to the project management page, you have to find your own way to do it. I am not aware of any plugins actually modifing the project management page, but I could miss the things.

Again, if you tell us what is the reason of the change you want to make we may can come out with some ideas (especially atrol:)
danilolutz
Posts: 9
Joined: 12 Apr 2012, 12:26
Contact:

Re: How to Add Fied to Mangament Project Page?

Post by danilolutz »

istvanb,

The idea is create a project type filter...

thanks again for helping! :)
istvanb
Posts: 226
Joined: 22 Aug 2010, 21:00

Re: How to Add Fied to Mangament Project Page?

Post by istvanb »

Dan,

What you mean on project type filter?

Option 1: you explain your idea in details and then you may receive some hints (if we can help)
Option 2: dont explain your idea in details and then you wont receive hints :)
danilolutz
Posts: 9
Joined: 12 Apr 2012, 12:26
Contact:

Re: How to Add Fied to Mangament Project Page?

Post by danilolutz »

Now I can explain, I think :lol: !! Sorry for confusion!

The Mantis Project Management Page like bellow:
Image

The Project Type field loads the values from plugin. The question is: How I add the Project Type Field like the image?

The Plugin page is:
Image

Thanks for help me!
Attachments
Project Page after modify...
Project Page after modify...
editproject.png (16.74 KiB) Viewed 32414 times
Plugin Page
Plugin Page
plugin_management.png (10.98 KiB) Viewed 32414 times
istvanb
Posts: 226
Joined: 22 Aug 2010, 21:00

Re: How to Add Fied to Mangament Project Page?

Post by istvanb »

Well, I think MS Paint would suffice:) But asides to jokes: you have to modify the php source of the page, there is no other way I am aware of to include the field to that page.

The good news is that modifying that page wouldnt be a big trouble for you since I know you know php a lot. The bad news is that its your best interest to comply with the mantis architecture if you want this change working fine. Also a bad news that if you modify the source code, you may find difficulties to upgrade later on.

I see the result you want to achieve, but still dont understand what is the underlying idea. What is the feature you want to achieve? Isnt this something you may can achieve by proper subproject system?
danilolutz
Posts: 9
Joined: 12 Apr 2012, 12:26
Contact:

Re: How to Add Fied to Mangament Project Page?

Post by danilolutz »

A more plausible explanation: Instead of registering an application, responsible for testing, registered each screen as a project instead of creating a hierarchical structure as:
1. Project;
1.1. Sub-projects(Modules);
1.1.1. Screen;

Now, the boss ask me to include this field... we have more than 150 registered screens.

Anyway, correct this mistake is not in boss plans.

So thanks a lot for help!
istvanb
Posts: 226
Joined: 22 Aug 2010, 21:00

Re: How to Add Fied to Mangament Project Page?

Post by istvanb »

Just give me the number of your boss, I will kick his ass:)

I see the point although - and I went thru this many times - mantis is an awesome tool for doing certain things, and not that awesome for doing other things.

This being said, good luck for your project! Dont forget to come back to us and share your solution when its done!

i-
danilolutz
Posts: 9
Joined: 12 Apr 2012, 12:26
Contact:

Re: How to Add Fied to Mangament Project Page?

Post by danilolutz »

istvanb, hi! Hi community!

I found a solution! It's the attachment (pluginsolution.png)!

But together I found another trouble: how I create a new filter in the View Issues Page? If is possible, of course!

For more explanation see the viewissue.png attachment... pay attention to red labels called Module.

:mrgreen: I'm a Paint Piccasso ? kkkkkk. Poor joke! hahaha.

Thanks for everything folks!
Attachments
View Issue.
View Issue.
viewissue.png (31.17 KiB) Viewed 32395 times
Plugin Solution.
Plugin Solution.
pluginsolution.png (24.33 KiB) Viewed 32395 times
danilolutz
Posts: 9
Joined: 12 Apr 2012, 12:26
Contact:

Re: How to Add Fied to Mangament Project Page?

Post by danilolutz »

Nobody can help me?
istvanb
Posts: 226
Joined: 22 Aug 2010, 21:00

Re: How to Add Fied to Mangament Project Page?

Post by istvanb »

Hey dude,

nice work. Unfortunately you will face the same issue when you try to add this new filter to the filter options, since its for filtering the fields of the issues and not for filtering your new project field. So if you add a custom field to the project than that field will appear in the filter options, but since you did something completly different which anyways not supported by the original mantis architecture you have to apply a custom solution as well.

i-
danilolutz
Posts: 9
Joined: 12 Apr 2012, 12:26
Contact:

Re: How to Add Fied to Mangament Project Page?

Post by danilolutz »

Hi man!!
The custom fields can't get the values of a table? This should end my problem!

If can't, is a tip to increment the Mantis Project..

Thanks!
istvanb
Posts: 226
Joined: 22 Aug 2010, 21:00

Re: How to Add Fied to Mangament Project Page?

Post by istvanb »

Well, let me rephrase:

1, lets call "custom field" what is supported by Mantis. These can be added via the administration interface and they belongs to issues of the project to which you assign these custom fields
2, the one you try to add is not a custom field in mantis terminology, its a new feature thing, or customization. "special-feature-thing"

Now, the original "custom fields" will show up in the filter list. This is supported by the mantis engine. So if the certain project has the field then you can filter to it. But dont forget this works on an issue basis.

What you did is out of the scope of the current mantis infrastructure. Your "special-feature-field" is assigned to the project itself (via your plugin) and the individual issues have nothing to do with it. Or at least this how I understand you work.

I suggest to try to create some "custom fields" to understand the difference if you have not done it yet.

not sure if this helps,
i-
Post Reply