CustomFieldFormat
Added by rere rere over 11 years ago
hello,
I created my own CustomFieldFormat :
- init.rb
Redmine::CustomFieldFormat.map do |fields|
fields.register MyCustomFieldFormat.new('my', :label => :label_test, :order => 1 + 0.6)
end
- lib/my_custom_field_format.rb
class MyCustomFieldFormat < Redmine::CustomFieldFormat
def format_value(value, field_format)
"test"
end
def show_value(custom_value)
"test"
end
end
I would like to modify the value of the field while updating. (For example, return "test" and not the true value). But nothing happens, there is always the true value in the field and not "test". Why ?
Thanks
Replies (2)
RE: CustomFieldFormat
-
Added by Martin Denizet (redmine.org team member) over 11 years ago
According to what I see in the source code you can do project substitutions on the issue text but not on header.
It would be quite simple to implement.
You could make a feature request on Github if you're not able to implement it yourself.
Cheers,
Martin
RE: CustomFieldFormat
-
Added by rere rere over 11 years ago
Thanks for your answer. I will make a feature request on GitHub.