我正在使用Ruby Gem“Databasedotcom”将Salesforce集成到Rails应用程序中,并且所有工作都正常,但我现在在Rails应用程序和Salesforce中面临相同对象名称的问题。Ruby Gem“Databasedotcom”同一对象问题
我在我的Rails应用程序中有用户模型,用户对象也在Salesforce中。因此,当试图从Salesforce User对象获取数据时,它总是返回Rails应用程序User对象。
这里是我的代码
client = Databasedotcom::Client.new
client.client_id #=> foo
client.client_secret #=> bar
client.authenticate :username => "[email protected]", :password => "ThePasswordTheSecurityToken" #=> "the-oauth-token"
client.materialize("User");
@user = User.find_by_Id('005d0000001291x');
但上述说法始终使用Rails的用户模型。
我想使用Salesforce用户对象来获取其数据。
感谢您的任何帮助。
感谢您的回复,我会实施这一点,让你如果一切正常,谢谢 – 2012-07-16 06:14:47
非常感谢。有用 – 2012-07-16 08:22:08