cosmetical cleanup of models

This commit is contained in:
Nihad Abbasov 2012-09-26 23:20:36 -07:00
parent 2a4359a572
commit 841e4fbd08
18 changed files with 108 additions and 226 deletions

View file

@ -1,3 +1,15 @@
class SystemHook < WebHook
def async_execute(data)
Resque.enqueue(SystemHookWorker, id, data)
end
def self.all_hooks_fire(data)
SystemHook.all.each do |sh|
sh.async_execute data
end
end
end
# == Schema Information
#
# Table name: web_hooks
@ -9,17 +21,3 @@
# updated_at :datetime not null
# type :string(255) default("ProjectHook")
#
class SystemHook < WebHook
def async_execute(data)
Resque.enqueue(SystemHookWorker, id, data)
end
def self.all_hooks_fire(data)
SystemHook.all.each do |sh|
sh.async_execute data
end
end
end