Sha256: e4f5d375a56d2bd803663021f51ceca2dd060f6fc391c64cb0b5a8f8b44fe48f

Contents?: true

Size: 690 Bytes

Versions: 56

Compression:

Stored size: 690 Bytes

Contents

module Xeroizer
  module ApplicationHttpProxy
    
    def self.included(base)
      base.send :include, InstanceMethods
    end
    
    module InstanceMethods
      
      # URL end-point for this model.
      def url
        @application.xero_url + '/' + api_controller_name
      end

      def http_get(extra_params = {})
        application.http_get(application.client, url, extra_params)
      end

      def http_put(xml, extra_params = {})
        application.http_put(application.client, url, xml, extra_params)
      end

      def http_post(xml, extra_params = {})
        application.http_post(application.client, url, xml, extra_params)
      end
      
    end
    
  end
end

Version data entries

56 entries across 56 versions & 3 rubygems

Version Path
xeroizer-3.0.1 lib/xeroizer/application_http_proxy.rb
xeroizer-3.0.0 lib/xeroizer/application_http_proxy.rb
xeroizer-3-pre-beta-3.0.0.pre.beta lib/xeroizer/application_http_proxy.rb
xeroizer-2.20.0 lib/xeroizer/application_http_proxy.rb
xeroizer-2.19.0 lib/xeroizer/application_http_proxy.rb
xeroizer-2.18.1 lib/xeroizer/application_http_proxy.rb
xeroizer-2.17.1 lib/xeroizer/application_http_proxy.rb
xeroizer-2.16.5 lib/xeroizer/application_http_proxy.rb
xeroizer-2.16.4 lib/xeroizer/application_http_proxy.rb
xeroizer-2.16.3 lib/xeroizer/application_http_proxy.rb
xeroizer-2.16.1 lib/xeroizer/application_http_proxy.rb
xeroizer-2.16.0 lib/xeroizer/application_http_proxy.rb
xeroizer-2.15.9 lib/xeroizer/application_http_proxy.rb
xeroizer-2.15.8 lib/xeroizer/application_http_proxy.rb
xeroizer-2.15.7 lib/xeroizer/application_http_proxy.rb
xeroizer-2.15.6 lib/xeroizer/application_http_proxy.rb
xeroizer-float-2.15.5.2 lib/xeroizer/application_http_proxy.rb
xeroizer-float-2.15.5.1 lib/xeroizer/application_http_proxy.rb
xeroizer-2.15.5 lib/xeroizer/application_http_proxy.rb
xeroizer-float-2.15.3.16 lib/xeroizer/application_http_proxy.rb