Sha256: c9ea6660537b8af4a3882721d69d2be926eb4e3fee8fe28ee02d723bdf7e5044
Contents?: true
Size: 507 Bytes
Versions: 16
Compression:
Stored size: 507 Bytes
Contents
module ExtFormSubmit def redir_url() if params[:btn_reload] :back else eval("#{params[:controller]}_url") end end def flash_alert(obj) err_str = view_context.render_for_controller("validation_errors", {:obj => obj}) msg = ("Unable to #{action_name} #{obj.class} for the following" + " " + view_context.pluralize(obj.errors.full_messages.length, "reason") + ":#{err_str}") unless obj.errors.messages.size < 1 flash.now[:error] = msg.html_safe end end
Version data entries
16 entries across 16 versions & 1 rubygems