Axios
connect to mongodb and perform CRUD operations
$3
Pass query parameter like below.
var query = {
'columnname': new RegExp(txtToSearch, 'i')
};
$3
call this method like this main.listByIds(uri, dbname, collection, ['62ca423ff60cea80458d7f8d'], (err, result) => {})
$3
call this method like this main.get(uri, dbname, collection, '62ca423ff60cea80458d7f8d', (err, result) => {})
$3
- insert(dbUri, dbName, collectionName, data, callback)
- delete(dbUri, dbName, collectionName, id, callback)
$3
call this method like this
var propertyArray = {
age: 40
};
main.update(uri, dbname, collection, '62ca4f6d903fd1ea9c85efaa',propertyArray, (err, result) => {})
$3
call this method like this
var propertyArray = {
age: 40,
address:'om sai hospital'
};
main.InsertOrUpdate(uri, dbname, collection, '62ca4f6d903fd1ea9c85efab',propertyArray, (err, result) => {