Need some assistance...

Added by Nick Peelman about 8 years ago

I'm attempting (and failing) to write a plugin to adapt Redmine to our needs a bit.

Basically, I need to create "Departments" (the entity name is flexible here, it could apply to any number of scenarios). The table is pretty simple:

-Department Name
-Department Contact Name(s)
-Department Contact Phone(s)
-Department Contact Email(s)
-Department Course(s)

This isn't a one to one relationship, or a one to many, it needs to be many-to-many in order to gain the desired functionality. The goal is to be able to add a department to an issue, just like you can add a related issue, or a resource (using the redmine_resources plugin). You would also, in theory, be able to view a department, its meta data, and any and all issues associated with it. The departments, in this case, represent requesting entities for the issues (in our particular case, and "issue" represents a software install.) They are not necessary associated with any one user or group, and even so the meta data is such that none of the existing entity containers really fit.

Previously we have added custom fields, but its not as flexible as I'd like it to be, hence the plugin.

If you promise not to make too much fun of the hackery, the code of what i have thus far is here:

its a menagerie of scary, and probably a good example of how not to do several things. Things aren't working, and its beginning to frustrate me; I think (hope) i just need a push back in the right direction...or if its completely wrong, if somebody could sketch out a skeleton of how it should be done, I hopefully could take the reins and add the flesh...

Once the gist of things works, I would like to revamp and organize it in such a way to make it as flexible and configurable as possible (without making it overly stupid-complicated) to hopefully save somebody else from going through a similar headache in the future :\

Replies (1)

RE: Need some assistance... - Added by Nick Peelman about 8 years ago

A friend who's something of a Rails Jedi it seems helped me clean up the worst of things, at least the stuff that was stopping me from having a running page. The code has been committed to github, I'm going to continue to work on it, but I still welcome any input anybody may have on it...