@punks/backend-entity-manager 0.0.492 → 0.0.494
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/cjs/index.js +9 -2
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/types/integrations/repository/typeorm/clause.d.ts +1 -0
- package/dist/esm/index.js +10 -3
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/types/integrations/repository/typeorm/clause.d.ts +1 -0
- package/dist/index.d.ts +1 -0
- package/package.json +1 -1
package/dist/cjs/index.js
CHANGED
|
@@ -3472,6 +3472,7 @@ class PipelineInstance {
|
|
|
3472
3472
|
async executeStep(step, input, state) {
|
|
3473
3473
|
const preconditionResult = await this.validateStepPrecondition(step, input, state);
|
|
3474
3474
|
if (!preconditionResult.hasValidPrecondition) {
|
|
3475
|
+
this.logger.error(`[VALIDATION ERROR] | Step ${step.name} failed for invalid precondition`);
|
|
3475
3476
|
return {
|
|
3476
3477
|
operationResults: [],
|
|
3477
3478
|
type: "error",
|
|
@@ -3524,7 +3525,7 @@ class PipelineInstance {
|
|
|
3524
3525
|
};
|
|
3525
3526
|
}
|
|
3526
3527
|
catch (error) {
|
|
3527
|
-
this.logger.exception(`
|
|
3528
|
+
this.logger.exception(`[OPERATION ERROR] -> operation:${operation.name}`, error, {
|
|
3528
3529
|
input,
|
|
3529
3530
|
});
|
|
3530
3531
|
return {
|
|
@@ -3713,6 +3714,12 @@ class QueryClauseBuilder {
|
|
|
3713
3714
|
if (filter?.isNull === false) {
|
|
3714
3715
|
clauses.push(typeorm.Not(typeorm.IsNull()));
|
|
3715
3716
|
}
|
|
3717
|
+
if (filter?.isEmpty === true) {
|
|
3718
|
+
clauses.push(typeorm.Raw((alias) => `TRIM(${alias}) IS NULL OR TRIM(${alias}) = ''`));
|
|
3719
|
+
}
|
|
3720
|
+
if (filter?.isEmpty === false) {
|
|
3721
|
+
clauses.push(typeorm.Raw((alias) => `TRIM(${alias}) IS NOT NULL AND TRIM(${alias}) <> ''`));
|
|
3722
|
+
}
|
|
3716
3723
|
return typeorm.And(...clauses);
|
|
3717
3724
|
}
|
|
3718
3725
|
stringListFilter(filter) {
|
|
@@ -35693,7 +35700,7 @@ class NestPipelineTemplate {
|
|
|
35693
35700
|
};
|
|
35694
35701
|
this.logger.debug(`[START] | ${this.metadata.name}`, this.processLogMetadata(logMetadata));
|
|
35695
35702
|
if (!this.isAuthorized(data.context)) {
|
|
35696
|
-
this.logger.debug(`[
|
|
35703
|
+
this.logger.debug(`[UNAUTHORIZED] | ${this.metadata.name} -> Unauthorized`, this.processLogMetadata(logMetadata));
|
|
35697
35704
|
return {
|
|
35698
35705
|
type: "error",
|
|
35699
35706
|
errorType: exports.PipelineErrorType.Unauthorized,
|