update existing drupal module

Job ID: 35610426

Budget: £20 – £250 GBP

I have a drupal module that connects to a 3rd party api.

The module works fine except if more than one user is using it at a given time.

what happens is
1) a user inputs data into a form
2) another user also inputs data into the form
3) user 1 submits form , it gets next free ID
4) it calls api (sometimes it takes 10 seconds to respond)
5) user 2 submits form, it gets next free ID (same ID as user 1 becuase user 1 has not save data to db table)
6) user 2 data has called api
7) api responds for user 1 call and it saves data for user 1 using the ID
8) api responds for user 2 call and it saves data for user 2 using the same ID


What it needs to do is adjust order of tasks.
1) a user inputs data into a form
2) another user also inputs data into the form
3) user 1 submits form ,gets next free ID, save the data and note the ID
4) it calls api (sometimes it takes 10 seconds to respond)
5) user 2 submits form, save the data and note the ID (now will be different ID from user 1)
6) user 2 data has called api
7) api responds for user 1 call and it updates a field value for user 1 using the ID
8) api responds for user 2 call and it updates a field value for user 2 using the same ID

I have details of the php file that needs the script updated

Its not too complex an issue for someone who understands Drupal, PHP, MySQL

There are other separate tasks that are required to be done that will be discussed with successful candidateafter this is completed. As well as a project of building 2 separate modules.

Thank you
Related categories: PHP JavaScript Drupal MySQL HTML