send-tables-to-db-lib
v2.0.1
Published
This is a lib who send needed tables from one to another db and check user permission with Authorisation
Downloads
13
Maintainers
Readme
send-tables-to-db-lib
Lib for send needed tables with his columns from one to another db and check userPermissions with Authorisation.
Table of contents
One file with all the functionality of the plugin
/index.js
Installation
npm i send-tables-to-db-lib
Start Plugin
npm run dev or node index.js
Functions
- Function that starts will send a few tables with his columns to another db
You have to write destionation db config in the function
createTable('userName', 'Host', 'DataBase', 'Password', 'port');
- When written true userName and password in that function will response user Permissions
You have to write userName and password in the function
CheckUserPermissions("userName", "password");
The result of the plugin
Console
Start
1. Send tables response
Success response (Table created successfully in the destination database.)
Bad response (Error)
2. Check User Permissions
Succes request:
data: {
message: 'Succes Request',
permissions: [
...
]
}
Bad Request:
Message: 400 Bad Request