Sha256: 11408b27397fb6a74c549a7f570f70e49da59daab857a84a9f538312bd5f5c6b
Contents?: true
Size: 656 Bytes
Versions: 8
Compression:
Stored size: 656 Bytes
Contents
module ButtonsHelper def add_button? Snaptable.add_button && (!Snaptable.use_permission || current_permission.allow_create?(params[:controller])) end def edit_button? Snaptable.edit_button && (!Snaptable.use_permission || current_permission.allow_modify?(params[:controller], "update")) end def show_button? Snaptable.show_button && (!Snaptable.use_permission || current_permission.allow_modify?(params[:controller], "read")) end def delete_button? Snaptable.delete_button && (!Snaptable.use_permission || current_permission.allow_modify?(params[:controller], "destroy")) end end
Version data entries
8 entries across 8 versions & 1 rubygems