Module: Railsdav::ControllerExtensions
- Extended by:
- ActiveSupport::Concern
- Defined in:
- lib/railsdav/controller_extensions.rb
Defined Under Namespace
Modules: ClassMethods, RespondWithWebdav
Instance Method Summary collapse
-
#respond_to_with_webdav(*mimes, &block) ⇒ Object
decorate behaviour defined in ActionController::MimeResponds.
-
#respond_with_with_webdav(*resources, &block) ⇒ Object
decorate behaviour defined in ActionController::MimeResponds.
- #webdav_metadata_for_current_action ⇒ Object
Instance Method Details
#respond_to_with_webdav(*mimes, &block) ⇒ Object
decorate behaviour defined in ActionController::MimeResponds
59 60 61 62 63 64 65 |
# File 'lib/railsdav/controller_extensions.rb', line 59 def respond_to_with_webdav(*mimes, &block) if request.propfind? render :webdav => :propstat, :respond_to_block => block else respond_to_without_webdav *mimes, &block end end |
#respond_with_with_webdav(*resources, &block) ⇒ Object
decorate behaviour defined in ActionController::MimeResponds
68 69 70 71 72 73 74 |
# File 'lib/railsdav/controller_extensions.rb', line 68 def respond_with_with_webdav(*resources, &block) if request.propfind? render :webdav => :propstat, :respond_to_block => block else respond_with_without_webdav *resources, &block end end |
#webdav_metadata_for_current_action ⇒ Object
76 77 78 |
# File 'lib/railsdav/controller_extensions.rb', line 76 def self.class. params[:action] end |