nicot 1.1.24 → 1.1.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +8 -5
- package/dist/index.cjs.map +2 -2
- package/dist/index.mjs +8 -5
- package/dist/index.mjs.map +2 -2
- package/dist/src/crud-base.d.ts +1 -1
- package/dist/src/restful.d.ts +7 -3
- package/package.json +2 -2
- package/build.js +0 -167
package/dist/index.cjs
CHANGED
|
@@ -709,17 +709,20 @@ var TimeBase = class extends PageSettingsDto {
|
|
|
709
709
|
__decorateClass([
|
|
710
710
|
(0, import_typeorm2.CreateDateColumn)({ select: false }),
|
|
711
711
|
NotColumn(),
|
|
712
|
-
NotInResult({ entityVersioningDate: true })
|
|
712
|
+
NotInResult({ entityVersioningDate: true }),
|
|
713
|
+
Reflect.metadata("design:type", Date)
|
|
713
714
|
], TimeBase.prototype, "createTime", 2);
|
|
714
715
|
__decorateClass([
|
|
715
716
|
(0, import_typeorm2.UpdateDateColumn)({ select: false }),
|
|
716
717
|
NotColumn(),
|
|
717
|
-
NotInResult({ entityVersioningDate: true })
|
|
718
|
+
NotInResult({ entityVersioningDate: true }),
|
|
719
|
+
Reflect.metadata("design:type", Date)
|
|
718
720
|
], TimeBase.prototype, "updateTime", 2);
|
|
719
721
|
__decorateClass([
|
|
720
722
|
(0, import_typeorm2.DeleteDateColumn)({ select: false }),
|
|
721
723
|
NotColumn(),
|
|
722
|
-
NotInResult({ entityVersioningDate: true })
|
|
724
|
+
NotInResult({ entityVersioningDate: true }),
|
|
725
|
+
Reflect.metadata("design:type", Date)
|
|
723
726
|
], TimeBase.prototype, "deleteTime", 2);
|
|
724
727
|
|
|
725
728
|
// src/bases/id-base.ts
|
|
@@ -1150,6 +1153,7 @@ var CrudBase = class {
|
|
|
1150
1153
|
this.crudOptions.relations,
|
|
1151
1154
|
(r) => !r.computed
|
|
1152
1155
|
);
|
|
1156
|
+
// eslint-disable-next-line @typescript-eslint/no-empty-function
|
|
1153
1157
|
this.extraGetQuery = this.crudOptions.extraGetQuery || ((qb) => {
|
|
1154
1158
|
});
|
|
1155
1159
|
this.log = new import_common2.ConsoleLogger(`${this.entityClass.name}Service`);
|
|
@@ -1197,7 +1201,7 @@ var CrudBase = class {
|
|
|
1197
1201
|
}
|
|
1198
1202
|
async _batchCreate(ents, beforeCreate, skipErrors = false) {
|
|
1199
1203
|
const entsWithId = ents.filter((ent) => ent.id != null);
|
|
1200
|
-
|
|
1204
|
+
return this.repo.manager.transaction(async (mdb) => {
|
|
1201
1205
|
let skipped = [];
|
|
1202
1206
|
const repo = mdb.getRepository(this.entityClass);
|
|
1203
1207
|
let entsToSave = ents;
|
|
@@ -1298,7 +1302,6 @@ var CrudBase = class {
|
|
|
1298
1302
|
throw new import_nesties8.BlankReturnMessageDto(500, "Internal error").toException();
|
|
1299
1303
|
}
|
|
1300
1304
|
});
|
|
1301
|
-
return result;
|
|
1302
1305
|
}
|
|
1303
1306
|
async create(_ent, beforeCreate) {
|
|
1304
1307
|
if (!_ent) {
|