FullCircle ERP Inventory Buffer

Problem: Website sales are continually overselling styles.

For some time now website sales have caused issues with inventory. Due to the speed at which inventory is updated along with the multiple channels in which inventory is sold there is now a need to build a buffer into web sales inventory. This should eliminate the frequency that web sales cause inventory over-sale.

Solution: Write a program that gives the ability to make granular adjusts to a buffer for inventory sent to company website.

In other words. Trick the site into thinking we have x number less inventory in every style sold then actual available inventory in stock.

Key constraints:
  • Do not under any circumstance edit the original inventory file that is written twice daily by the ERP.
  • Allow a user to adjust buffer size to their specifications.
  • Do not allow inventory buffer to drop items below 0
  • Run program remotely in a hands off manor
Execution:

With everything above in mind I set out and built an independent solution for managing a inventory buffer to a users desire. First I used python’s ftplib library to make a connection to the remote server using ftp. Once I had that established I copy the Inventory file down from the server locally to the remote computer. Once I have the raw inventory file I parse through the data using pythons built in tools and use the formula y = y – x  when y = current real inventory  and x = desired buffer. Followed by an if statement to catch and remove all negative numbers if y < 0, y = 0. This is all the logic i need to keep the inventory numbers above -1. The data once process is write to a new file with a new file name and subsequently uploaded via ftp. By renaming the file this allows me to run the buffer script with as much frequency as I want without the worry of writing a file that has already had its buffer subtracted. Having the same functionality built by the solutions provider cost $1700. feel free to review my code via github.

You can find my source code here.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s