No commit activity in last 3 years
No release in over 3 years
ActiveSalesforce (ASF) is a Rails connection adapter that provides direct access to Salesforce.com hosted data and metadata via the ActiveRecord model layer. Objects, fields, and relationships are all auto surfaced as active record attributes and rels.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

>= 1.2.4
>= 2.4
>= 2.3.3
>= 0.6
 Project Readme
== Welcome to Active Salesforce

ActiveSalesforce is an extension to the Rails Framework that allows for the dynamic creation and management of ActiveRecord objects through the use of Salesforce meta-data and uses a Salesforce.com organization as the backing store.

== Getting started

1. gem install johnreilly-activerecord-activesalesforce-adapter --source http://gems.github.com

2. If you have not already done so generate your initial rails app:

    rails myappname

3. Edit config/environment.rb and add a config.gem requirement:

    Rails::Initializer.run do |config|
      ...
      config.gem "johnreilly-activerecord-activesalesforce-adapter", :source => 'http://gems.github.com', :lib => 'activerecord-activesalesforce-adapter'
      ...
    end

4. Edit database.yml

    development:
      adapter: activesalesforce
      url: https://www.salesforce.com
      username: <salesforce user name goes here>
      password: <salesforce password goes here>

    NOTE: If you want to access your Salesforce Sandbox account use https://test.salesforce.com as your url instead.

5. Create your salesforce models using a Salesforce::<ModelName> namespace.

    script/generate model Salesforce::Contact

6. Run a quick test to make sure things are working

    > script/console
    Loading development environment (Rails 2.3.3)
    
    >> Salesforce::Contact.first
    => <Salesforce::Contact id: "003T000000GqvJsIAJ", ... >

7. Proceed using standard Rails development techniques!

== Advanced Features

1. Session ID based Authentication: Add the following to /app/controllers/application.rb to enable SID auth for all controllers

   class ApplicationController < ActionController::Base
     before_filter ActiveSalesforce::SessionIDAuthenticationFilter
   end

2. Boxcar'ing of updates, inserts, and deletes. Use <YourModel>.transaction() to demark boxcar boundaries.

== Description of contents

lib
 Application specific libraries. Basically, any kind of custom code that doesn't
 belong under controllers, models, or helpers. This directory is in the load path.

script
 Helper scripts for automation and generation.

test
 Unit and functional tests along with fixtures.