dburkes / databasedotcom-rails Goto Github PK
View Code? Open in Web Editor NEWConvenience classes to make using the databasedotcom gem with Rails apps even easier
License: MIT License
Convenience classes to make using the databasedotcom gem with Rails apps even easier
License: MIT License
Hi,
I work for salesforce.com and working database.com heroku addon. Do you mind adding an option for reading database.com config (in the Controller.rb class) from environment variable 'DATABASE_COM_URL' as well, similar to databasedotcom's Client.rb.
For example,something similar to this.
def dbdc_client
unless @dbdc_client
if ENV['DATABASE_COM_URL']
@dbdc_client = Databasedotcom::Client.new
else
config = YAML.load_file(File.join(::Rails.root, 'config', 'databasedotcom.yml'))
@dbdc_client = Databasedotcom::Client.new(config)
end
@dbdc_client.authenticate(:username => @dbdc_client.username, :password => @dbdc_client.password)
end
@dbdc_client
end
Thanks
Babu
I am getting ArgumentError while creating access_token via OAuth2.
OAuth2::Client.new(consumer_key, consumer_secret, {:site => 'https://login.salesforce.com', :authorize_path => '/services/oauth2/authorize', :access_token_path => '/services/oauth2/token', :ssl=>{:verify => false }})
This the line where I am getting error.
Hey,
I've forked your really useful and awesome gem. What I found was that I didn't want to have to include this into controllers as much as anywhere I need to interact with databasedotcom data. I'm pulling it out into a convenient module you can include, not really having to change much of the code.
One of my reasons for this is because I don't see the necessity for keeping this code in controllers only. The whole project can benefit from this, and it could lend towards keeping my codebase clean and my controllers skinny.
I'm removing the rails dependency, as well as renaming the gem a bit.
I'll keep the commits separate if you'd like a pull request that helps make this gem a bit more generic to any ruby class.
Stay frosty,
~Spaceghost
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.