1.0.10 • Published 3 years ago

file-based-stock-manager v1.0.10

Weekly downloads
-
License
MIT
Repository
-
Last release
3 years ago

Instruction

Installation

$ npm i file-based-stock-manager
$ yarn add file-based-stock-manager

First you should import package into your project.

Usage

You should copy and paste these codes to your main javascript file in order to use package

const Warehouse = require("file-based-stock-manager");

;(async () => {
    let warehouse = new Warehouse('warehouse');
    let argv = process.argv;
    if (argv[2] === '--dep') {
        await warehouse.dep(argv[3], argv[4]);
    } else if (argv[2] === '-sell') {
        await warehouse.sell(argv[3], argv[4]);
    } else if (argv[2] === '-restore') {
        await warehouse.restore(argv[3])
    } else if (argv.length === 2) {
        if (await warehouse.dash() == false) {
            await warehouse.noDash()
        }
    }
})()

You can do these 4 main operations:

  • Deposit:
node example.js --dep productName productCount

image

  • Sell:
node example.js -sell productName productCount

image

  • Restore:
node example.js -restore productName

image

  • Dashboard:
node example.js

image

1.0.10

3 years ago

1.0.9

3 years ago

1.0.8

3 years ago

1.0.7

3 years ago

1.0.6

3 years ago

1.0.5

3 years ago

1.0.4

3 years ago

1.0.3

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago