shop-warehouse-manager-asadbek
v1.0.4
Published
With this package you can manage your warehouse or you may use it in your projects :)
Downloads
7
Maintainers
Readme
Instruction
Installation
$ npm i shop-warehouse-manager-asadbek
$ yarn add shop-warehouse-manager-asadbek
First you should import package into your project.
Import
const Market = require("shop-warehouse-manager-asadbek");
Usage
You should add these line codes to your main javascript file in order to use package
const Market = require("shop-warehouse-manager-asadbek");
let keys = process.argv;
(async function () {
let shop = new Market("shop", __dirname);
if (keys[2] === "--dep") {
await shop.dep(keys[3], keys[4]);
} else if (keys[2] === "-sell") {
await shop.sell(keys[3], keys[4]);
} else if (keys.length === 2) {
await shop.dash();
}
})();
How to use it in terminal?
In our project has three main functions, there are
- deposit
- sell
- dashboard
Firstly you should enter product to desosit, and you may sell it, also you can see the information about warehouse with dashboard
- Deposit:
node main.js --dep product_name, count
- Sell:
node main.js -sell product_name, count
- Dashboard:
node main.js
- With dashboard you can see information in table format
Goog luck!