Google Drive is a cloud-based storage solution that allows you to save files online and access them anywhere from any smartphone, tablet, or computer. Clients using NetSuite for core business operations might find that storing files in NetSuite’s File Cabinet is a rather expensive proposition. A cost-effective alternative for bulk file storage is Google Drive.

The Tvarana team came across this very scenario with a client who utilizes Google Drive to store their vendor bills. Uploading vendor bills and related files into Google Drive, however, was a manual and time-consuming process. The client wanted the process to be automated, wherein vendor bills and associated files uploaded to NetSuite, would be automatically be uploaded to Google Drive as well. This process comes with the added advantage where users with limited or no access to NetSuite can still view files uploaded to Google Drive.

The Process:

  • Using Suitelets, the Tvarana team enabled a Google Drive subtab for any record. The subtab displays two sections – one to upload files, and the other that displays the list of files associated with that record. Scripts on the backend make it possible to upload files to Drive using APIs. To generate the API key, which is required to integrate Drive with NetSuite, Tvarana team created a project in Google Console. 

 

 

  • The user selects a file to upload and adds a description. As soon as the file is selected, it is uploaded to the Google Drive.
  • The script dynamically populates the upload percentage and displays the status of the upload as soon as it completes the request. 
  • Once the file is uploaded into the G-Drive folder, as a response we receive the ID of the file. These file IDs are stored in NetSuite for reference. 
  • Once the upload is complete, the NetSuite page will auto-reload after 5 seconds and display a list of the files uploaded. 
  • Uploaded files can be edited, deleted or viewed by navigating to the corresponding record. 
  • The Tvarana team has also extended this functionality to Expense Reports and Check forms.

 

Similar to the Google Drive integration, Tvarana developed a script to integrate NetSuite with Google Sheets. This was done to help migrate existing custom reports or saved search data as Google Sheets, making them available to sales reps to download from anywhere, without the need for NetSuite logins.

 

The Process:

  • The client had some unique custom reports which details sales bookings and forecasts across the years based on multiple saved searches.
  • These were run in the script, constructing all the required objects like file properties, file data etc in a format that Google Sheet APIs accept.
  • A project was created in Google Console in order to generate an Access Token. 
  • With the file details and access token a spreadsheet shell is created in Google Drive by making a request to sheet APIs.
  • In the response is the corresponding spreadsheet ID.
  • Using this ID, the file contents are updated with custom report data. 
  • The shared drive folder ID is specified in the request to make sure the sheet is available to all the users who have access to the folder.
  • In this way, sales representatives can easily download the required reports from the Google Drive folder without logging in to NetSuite.
Please follow and like us: