Skip to content
Snippets Groups Projects
Unverified Commit e805bc6c authored by Sébastien Gaya's avatar Sébastien Gaya
Browse files

pause/unpause git sync and comment on clear items

parent 55adf2cb
No related branches found
No related tags found
No related merge requests found
module Communication::Website::Menu::WithAutomatism
extend ActiveSupport::Concern
included do
included do
scope :automatic, -> { where(automatic: true) }
end
......@@ -20,13 +20,14 @@ module Communication::Website::Menu::WithAutomatism
end
protected
def pause_git_sync
# TODO
Communication::Website::Menu.skip_callback :save, :after, :connect_dependencies
Communication::Website::Menu.skip_callback :touch, :after, :connect_dependencies
end
def clear_items
# TODO est-ce bien de ne pas gérer les dépendances avec un destroy? Effet de bord?
# We don't use the destroy method to prevent items' callbacks
items.delete_all
end
......@@ -54,6 +55,6 @@ module Communication::Website::Menu::WithAutomatism
end
def unpause_git_sync
# TODO
Communication::Website::Menu.set_callback :save, :after, :connect_dependencies
end
end
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment