Don't know if you found a solution to this but here's mine: In my
database definition I make the default value a '-' (or some other
non-meaningful value) for a varchar field, or 0 for an int field. My
migration to modify existing columns looks like this:
<code>
class ChangeDefaults < ActiveRecord::Migration
def self.up
change_column :nodes, :sysName, :string, :null => false, :default
=> '-'
change_column :nodes, :ip, :string, :null => false, :default
=> '-'
change_column :ports, :vlan, :integer, :null => false, :default =>
0
end
end
</code>
With this you don't need to modify any plugin code.
Hope this helps.
James Riley wrote:
> A pretty common problem but I haven't found a solution that works.
>
> I'm using in_place_editor_field in my view and all works well when there
> is data but when the field is blank, I am unable to edit as there is no
> clickable area. Is there a simple and working solution out there I could
> make use of?
>
> Thanks
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---