You mention that the api you have used in the past has been deprecated. You also mention having fixed it in the 6.x branch, I would like to apply the changes to the 7.x branch as it is a fairly important feature on our site.

Comments

toftat’s picture

charlie-s’s picture

Happy to share it. Are you interested in co-maintaining this module in any way?

I'll have to pull my D6 version up and drop a couple of specific things for the client it's used on, but I'm happy to work with you to get a D7 version up and running.

toftat’s picture

Sure!

charlie-s’s picture

Ok, I've thrown it up on GitHub in its current state: https://github.com/csdco/webform_to_gdocs

It may be easier to just work with it there and post a link on the front page of this module. Drupal.org doesn't have the simplest git interface to work with.

So, what I've linked to is the Drupal 6 version. You can either spin it up in a D6 install or start migrating the code to D7. I'd recommend the former so that you can see how it works, as the codebase is quite small and could possibly be ported over to D7 in an even more simple fashion. Let me know your thoughts.

toftat’s picture

Digging into this a little bit this afternoon (diff from the module hosted here and the github code), it looks like that the 6.x version stopped using the Zend framework for its interface with gdocs. I think that the best way to go about this is to extract an interface from the module to an internal API, then implement that API using the whatever lower layer is necessary.

This way both the 6.x and 7.x modules can share the code.

Thoughts?

charlie-s’s picture

The 6.x version's download history is remarkably low, so we may not need to spend any time on that. Your thoughts?

Yes, no longer using the Zend framework, now using Google's own API PHP client (https://github.com/google/google-api-php-client) along with a couple of API calls where necessary as you've seen in the code. Decoupling that would be great, I suppose it's just a question of the time involved.

toftat’s picture

Well I figured that starting with the working 6.x version even though it doesn't get a large number of downloads would be easier as it currently works and I have a 6.x demo site on hand.

Once this is working, then transfering it to 7.x _should_ be easy

toftat’s picture

Can you give me access to push some changes to a branch, I needed to make fixes to make it work on 6.x

charlie-s’s picture

Sure, what's your name on GitHub? We can discuss further there.

toftat’s picture

It's the same as here :)

charlie-s’s picture

You have access to push there now.

toftat’s picture

there are 2 pull requests:

one to fix a couple of syntax errors that my version of php was upset over
one to make it work for version 7.x

Wimmmmm’s picture

Any result in this 7.x fix effort?

charlie-s’s picture

This pull request has a couple of outstanding items and then I think it can be merged in and will work w D7: https://github.com/csdco/webform_to_gdocs/pull/2

If you know PHP / Drupal development-wise at all, feel free to check it out and chime in there if you'd like.

piscos’s picture

I'm also very interested in the 7.x fix! We've been using the module for the past year with lots of forms and we love it.

I don't know enough Module development or PHP, but I could donate a few bucks if that helps ^_^

charlie-s’s picture

Thanks piscos. Can you shoot me an email? charlie (at) csdv (dot) co

OscarH’s picture

Anything left before we can create a new release? I have been running the github code in production for a while with no issues.

OGPadmin’s picture

I'm getting a 400 error. Did I do something wrong? I follow the HOWTO but I wasn't sure what "with a newline at the end" means in the console.


    proxy=oauth2relay330700068
    access_type=offline
    approval_prompt=force
    scope=https://www.googleapis.com/auth/drive https://spreadsheets.google.com/feeds https://www.googleapis.com/auth/userinfo.email https://www.googleapis.com/auth/plus.me
    origin=http://www.ohiogreens.org
    response_type=code
    redirect_uri=http://www.ohiogreens.org/webform_to_gdocs/oauth2callback
    client_id=xxx.apps.googleusercontent.com
    include_granted_scopes=true
charlie-s’s picture

Version: 7.x-1.1 » 7.x-4.x-dev
Status: Active » Closed (fixed)

Released pushed and tagged. Will appear shortly on the module page. Thanks everyone for the help here :)

charlie-s’s picture

@OGPadmin I missed your message above. Can you post a new issue and I can help you debug this, assuming you're still experiencing that issue?