@spinajs/orm
Advanced tools
Comparing version 2.0.74 to 2.0.75
@@ -556,4 +556,15 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) { | ||
whereObject(obj) { | ||
for (const key of Object.keys(obj)) { | ||
this.andWhere(key, SqlOperator.EQ, obj[key]); | ||
this._boolean = WhereBoolean.AND; | ||
for (const key of Object.keys(obj).filter(x => obj[x] !== undefined)) { | ||
const val = obj[key]; | ||
if (Array.isArray(val)) { | ||
if (val.length !== 0) { | ||
this.whereIn(key, val); | ||
} | ||
} | ||
else if (val === null) { | ||
this.whereNull(key); | ||
} | ||
else | ||
this.andWhere(key, SqlOperator.EQ, val); | ||
} | ||
@@ -560,0 +571,0 @@ return this; |
{ | ||
"name": "@spinajs/orm", | ||
"version": "2.0.74", | ||
"version": "2.0.75", | ||
"description": "framework orm module", | ||
@@ -52,7 +52,7 @@ "exports": "./lib/index.js", | ||
"dependencies": { | ||
"@spinajs/configuration": "^2.0.74", | ||
"@spinajs/di": "^2.0.74", | ||
"@spinajs/exceptions": "^2.0.74", | ||
"@spinajs/log": "^2.0.74", | ||
"@spinajs/reflection": "^2.0.74", | ||
"@spinajs/configuration": "^2.0.75", | ||
"@spinajs/di": "^2.0.75", | ||
"@spinajs/exceptions": "^2.0.75", | ||
"@spinajs/log": "^2.0.75", | ||
"@spinajs/reflection": "^2.0.75", | ||
"glob": "^8.1.0", | ||
@@ -59,0 +59,0 @@ "lodash": "^4.17.21", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
484488
7321
Updated@spinajs/di@^2.0.75
Updated@spinajs/exceptions@^2.0.75
Updated@spinajs/log@^2.0.75
Updated@spinajs/reflection@^2.0.75