@epip/crud
Advanced tools
Comparing version 1.0.52 to 1.0.53
@@ -1,2 +0,2 @@ | ||
import { DeepPartial, Repository } from "typeorm"; | ||
import { Repository } from "typeorm"; | ||
import { IResponse, IResponseAll } from "../types"; | ||
@@ -10,5 +10,5 @@ export declare class BaseService<T> { | ||
put(id: number, entity: T): Promise<IResponse<T>>; | ||
patch(id: number, entity: DeepPartial<T>): Promise<IResponse<DeepPartial<T>>>; | ||
patch(id: number, entity: T): Promise<IResponse<T>>; | ||
delete(id: number): Promise<IResponse<T>>; | ||
} | ||
//# sourceMappingURL=base.service.d.ts.map |
@@ -187,3 +187,3 @@ "use strict"; | ||
return __awaiter(this, void 0, void 0, function () { | ||
var _a, err, results, data, key, element, res; | ||
var _a, err, results, data, key, res; | ||
var _b; | ||
@@ -204,4 +204,3 @@ return __generator(this, function (_c) { | ||
for (key in entity) { | ||
if (Object.prototype.hasOwnProperty.call(data, key)) { | ||
element = entity[key]; | ||
if (Object.prototype.hasOwnProperty.call(data, key) && entity[key]) { | ||
data[key] = entity[key]; | ||
@@ -208,0 +207,0 @@ } |
{ | ||
"name": "@epip/crud", | ||
"version": "1.0.52", | ||
"version": "1.0.53", | ||
"description": "", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
258517
908