Module: Engine2::ActionDeleteSupport

Includes:
ActionModelSupport
Included in:
DeleteAction
Defined in:
lib/engine2/action.rb

Class Method Summary collapse

Instance Method Summary collapse

Methods included from ActionModelSupport

#get_type_info, #hide_pk, #node_defined, #show_pk, #unsupported_association

Class Method Details

.included(action) ⇒ Object



1147
1148
1149
1150
# File 'lib/engine2/action.rb', line 1147

def self.included action
    action.http_method :delete
    action.action_type :delete
end

Instance Method Details

#pre_runObject



1152
1153
1154
1155
1156
# File 'lib/engine2/action.rb', line 1152

def pre_run
    super
    execute "action.errors || [action.parent().invoke(), action.panel_close()]"
    node.parent.parent.*.menu(:item_menu).option :confirm_delete, icon: "trash", show: "action.selected_size() == 0", button_loc: false
end