0.0.2 • Published 6 years ago
backend-entity v0.0.2
backend-entity
Simple, minimalist entity framework for Postgre wtih node.
Usage with Postgre
let eType = require('backend-entity').entity;
let propertyMap = {
"id": "id", //Key: Name of the property on the object,Value is the name of the column in PG.
"name": "name",
};
this._entity = new eType("entityname", propertyMap, pgPool); //This is used as your table name
Installation
This is a Node.js module available through the npm registry.
Before installing, download and install Node.js. Node.js 0.10 or higher is required.
Installation is done using the
npm install
command:
$ npm install backend-entity
Features
- Filter Builder to create dynamic where conditions.
Known Limitations
- Supports only postgresql in the backend
- Doesnt support JSON data type in postgre.
Operator Supported
Operator | SQL Operator | Description |
---|---|---|
= | equal | Single Operand Only, compares value is equal. |
!= | notequal | Single Operand Only, compares value is not equal. |