amalc / rubyzoho

Abstracting Zoho’s API into a set of Ruby classes, with reflection of Zoho’s fields using a more familiar ActiveRecord lifecycle, but without ActiveRecord. Works with Rails and Devise.
MIT License
62 stars 57 forks source link

Proper method for retrieving records modified after #44

Open bjminihan opened 9 years ago

bjminihan commented 9 years ago

Using version 0.2.0, I was able to pull Account records modified within the past 4 hours.

Since upgrading to 0.5.0, this method no longer works.

Here's how I'm doing it:

    z = ZohoApi::Crm.new(Autobahn::Config.zoho_api_key, ["Accounts"], true, true)
    z.find_records("Accounts", "modified_time", ">", "2015-02-19 11:39:33")

I could find no other way of achieving this with the RubyZoho::Crm::Account.new object, but would love any other method that returns more than the exact match (the > is being ignored).

Apologies if there was a better place to post this. I'm at my wit's end.

amalc commented 9 years ago

Well, the Zoho API for retrievals changed between ‎those versions and it's entirely possible that the new API doesn't support it. I'll take a look.  From: Bryan MinihanSent: Tuesday, July 21, 2015 21:20To: amalc/rubyzohoReply To: amalc/rubyzohoSubject: [rubyzoho] Proper method for retrieving records modified after (#44)Using version 0.2.0, I was able to pull Account records modified within the past 4 hours.

Since upgrading to 0.5.0, this method no longer works.

Here's how I'm doing it:

z = ZohoApi::Crm.new(Autobahn::Config.zoho_api_key, ["Accounts"], true, true)
z.find_records("Accounts", "modified_time", ">", "2015-02-19 11:39:33")

I could find no other way of achieving this with the RubyZoho::Crm::Account.new object, but would love any other method that returns more than the exact match (the > is being ignored).

Apologies if there was a better place to post this. I'm at my wit's end.

—Reply to this email directly or view it on GitHub.

bjminihan commented 9 years ago

Any news on how to find recent accounts in rubyzoho? Buehler?

amalc commented 9 years ago

@bjminihan Sorry, been a bit hectic and didn't get a chance to look at the API call. Will check over the next couple of days.