Sha256: 27b068587f9adeddd905bb50a11895a377fd3dcc4838fe75a9d270906281b339
Contents?: true
Size: 905 Bytes
Versions: 3
Compression:
Stored size: 905 Bytes
Contents
module SugarCRM; class Base # Retrieve a list of SugarBeans. This is the primary method for getting # a list of SugarBeans using the REST API. def get_entry_list(module_name, query, options={}) login! unless logged_in? { :order_by => '', :offset => '', :fields => '', :link_fields => [], :max_results => '', :deleted => '' }.merge! options json = <<-EOF { \"session\": \"#{@session}\"\, \"module_name\": \"#{module_name}\"\, \"query\": \"#{query}\"\, \"order_by\": \"#{options[:order_by]}\"\, \"offset\": \"#{options[:offset]}\"\, \"select_fields\": #{options[:fields].to_json}\, \"link_name_to_fields_array\": #{options[:link_fields].to_json}\, \"max_results\": \"#{options[:max_results]}\"\, \"deleted\": #{options[:deleted]} } EOF json.gsub!(/^\s{6}/,'') get(:get_entry_list, json) end end; end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
sugarcrm-0.5.3 | lib/sugarcrm/get_entry_list.rb |
sugarcrm-0.5.2 | lib/sugarcrm/get_entry_list.rb |
sugarcrm-0.5.1 | lib/sugarcrm/get_entry_list.rb |