Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Features/fields translations #30

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

brenes
Copy link

@brenes brenes commented Aug 19, 2014

Changes needed to translate fields from Zoho to Ruby and remember the proper translations, as explained in #29

This way, I can have an utm_campaing attribute in my Zoho and Ruby will remember that the original attribute is not called Utm Campaign but utm_campaign.

I have tested it with our application (not in production yet) But I couldn't run any spec because I don't have a usable Zoho API Key (the only one I have is populated with real data and I can't run specs over them). Is there any procedure to run specs without a real API Key?

@coveralls
Copy link

Coverage Status

Coverage decreased (-67.87%) when pulling e8838b5 on simplelogica:features/fields-translations into ed496cf on amalc:master.

@amalc
Copy link
Owner

amalc commented Aug 19, 2014

No, there isn't but you can sign up for one of the free accounts. Just be
careful about running just the one spec, though so you don't use up all of
the calls.

On Tue, Aug 19, 2014 at 5:06 PM, brenes [email protected] wrote:

Changes needed to translate fields from Zoho to Ruby and remember the
proper translations, as explained in #29
#29

This way, I can have an utm_campaing attribute in my Zoho and Ruby will
remember that the original attribute is not called Utm Campaign but
utm_campaign.

I have tested it with our application (not in production yet) But I
couldn't run any spec because I don't have a usable Zoho API Key (the only
one I have is populated with real data and I can't run specs over them). Is

there any procedure to run specs without a real API Key?

You can merge this Pull Request by running

git pull https://github.com/simplelogica/rubyzoho features/fields-translations

Or view, comment on, or merge it at:

#30
Commit Summary

  • First we store translations when getting fields through the
    fields_for_api method
  • Then we store them when using the fields_from_record method
  • And now, when building the XML we look for the translation

File Changes

Patch Links:


Reply to this email directly or view it on GitHub
#30.

@amalc
Copy link
Owner

amalc commented Aug 22, 2014

@brenes Did you get a chance to test this?

@brenes
Copy link
Author

brenes commented Sep 16, 2014

Sorry, I had the most busy month at work and couldn't take a look :(

I'll try to test this in the following days.

@amalc
Copy link
Owner

amalc commented Sep 16, 2014

No worries. I need to get a new version out as well with the number of
records returned fix.

On Tue, Sep 16, 2014 at 2:01 PM, brenes [email protected] wrote:

Sorry, I had the most busy month at work and couldn't take a look :(

I'll try to test this in the following days.


Reply to this email directly or view it on GitHub
#30 (comment).

@amalc
Copy link
Owner

amalc commented Feb 23, 2015

@brenes Had to manually do the merge. Will test and release in the next couple of days. Thanks!

@amalc amalc closed this Feb 23, 2015
@brenes
Copy link
Author

brenes commented Feb 24, 2015

Thanks to you! And sorry for not being able to test it in months :(

@brenes
Copy link
Author

brenes commented Mar 25, 2015

@amalc We had an issue with a field containing a '/'. I solved it in my branch by cleaning it on the ApiUtils#string_to_symbol and everything worked fine.

I don't know if there's a way to obtain a right ruby variable name from a string with strange characters, so this problem doesn't repeat on the future.

@amalc
Copy link
Owner

amalc commented Mar 25, 2015

I've got your changes for mapping in master to map between fields. Will release as soon as I test. Thanks for the heads up.

@amalc
Copy link
Owner

amalc commented Mar 26, 2015

I'll add a reg ex to always generate a legal ruby variable. I take it you're using the mapping fixes you added? If you're processing a field with '/'?

@amalc amalc reopened this Mar 26, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants