I'm creating a plugin for Redmine. I want to use the core Issue model, but I want to include in it a relation with my model, which created in the plugin structure. How can I patch the Issue
model for including a new relationship in my plugin?
You can create a decorator in your main project to decorate the Issue
model:
# app/decorators/issue_decorator.rb
Redmine::Issue.class_eval do
has_many :blurps # or whatever your model is called
end