Proposal For Updating the SCP Location Quantity And SCP TN Inventory Field In the Item record.

Proposal summary 

This proposal is for an update to the superior communication integration script that is currently in use. When an item is removed from the superior communication inventory response, the script currently ignores the item’s quantity update. 

To deal with this scenario, we’ll need to write scripts and set the quantity to 0 if an item isn’t present in the Superior communication inventory response. 

Requirement  

Adjust SPS Inventory script. So, there are SKUs that get removed from the API, and once removed, it needs to adjust those SKUs to 0. Currently it leaves them at the last inventory that was on the API.     EXAMPLE SKU: DIN-SAMGA12-PSM 

Also, in the Item record, update the “SCP TN Inventory Field”. 

Our Solution 

To achieve this scenario, we’ll need to write two schedule scripts. We can’t handle the missing item quantity update in the item record with the current script. 

For updating the SCP TN Inventory Field 

  1. A new map-reduce script will be written. 
  1. The script will run once every 12 hours. 
  1. The logic behind this script is that we will pull all items from NetSuite that have a SCP TN Inventory field value greater than 0. 
  1. Using the Superior communication inventory API, we can also get item quantity details. 
  1. We’ll see if the SCP number for each NetSuite item is present in the API response. 
  1. If this SCP number does not appear in the inventory response, the SCP TN Inventory field will be set to 0. 

For updating the Superior Communications TN location quantity 

  1. A new map-reduce script will be written. 
  1. The script will run once every 12 hours. 
  1. Get all the items from the IA49139 inventory adjustment record (internal id: 44418950). 
  1. We can also get item quantity information using the Superior communication inventory API. 
  1. We’ll check the API response for the SCP number for each NetSuite item. 
  1. We will adjust quantity is 0 for those items in Superior Communications TN location if this SCP number does not appear in the inventory response by updating the inventory adjustment record. 

Assumption  

  1. To meet this requirement, we’ll add two additional scripts. 
  1. If the item SCP number is not found in the inventory API response, the new script will delete the data unless it is manually updated by the user. 

Risk 

  1. This script cannot be developed in a production environment. 

Leave a comment

Your email address will not be published. Required fields are marked *