2010-06-20 22:01:11 +02:00
|
|
|
# encoding: utf-8
|
|
|
|
|
|
|
|
module CouchRest #:nodoc:
|
|
|
|
module Model #:nodoc:
|
|
|
|
|
|
|
|
module Callbacks
|
|
|
|
extend ActiveSupport::Concern
|
|
|
|
included do
|
|
|
|
extend ActiveModel::Callbacks
|
|
|
|
|
|
|
|
define_model_callbacks \
|
|
|
|
:create,
|
|
|
|
:destroy,
|
|
|
|
:save,
|
2011-02-01 20:32:38 +01:00
|
|
|
:update
|
2010-06-20 22:01:11 +02:00
|
|
|
|
|
|
|
end
|
|
|
|
|
|
|
|
def valid?(*) #nodoc
|
|
|
|
_run_validation_callbacks { super }
|
|
|
|
end
|
|
|
|
|
|
|
|
end
|
|
|
|
|
|
|
|
end
|
|
|
|
end
|