@degenerate/generic 0.0.19 → 0.0.22
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/_settings/application-settings.d.ts +14 -0
- package/dist/_settings/application-settings.d.ts.map +1 -0
- package/dist/_settings/application-settings.js +16 -0
- package/dist/application/audit-log/additional-ids/create-audit-log-additional-ids-with-query.d.ts +12 -0
- package/dist/application/audit-log/additional-ids/create-audit-log-additional-ids-with-query.d.ts.map +1 -0
- package/dist/application/audit-log/additional-ids/create-audit-log-additional-ids-with-query.js +33 -0
- package/dist/application/audit-log/additional-ids/create-mulitple-path-alai.d.ts +10 -0
- package/dist/application/audit-log/additional-ids/create-mulitple-path-alai.d.ts.map +1 -0
- package/dist/application/audit-log/additional-ids/create-mulitple-path-alai.js +18 -0
- package/dist/application/audit-log/additional-ids/create-query-audit-log-for-alai.d.ts +10 -0
- package/dist/application/audit-log/additional-ids/create-query-audit-log-for-alai.d.ts.map +1 -0
- package/dist/application/audit-log/additional-ids/create-query-audit-log-for-alai.js +19 -0
- package/dist/application/audit-log/create-application-audit-log.d.ts +16 -0
- package/dist/application/audit-log/create-application-audit-log.d.ts.map +1 -0
- package/dist/application/audit-log/create-application-audit-log.js +33 -0
- package/dist/application/index.d.ts +5 -0
- package/dist/application/index.d.ts.map +1 -0
- package/dist/application/index.js +26 -0
- package/dist/errors/audit-log/audit-log-errors.d.ts +20 -0
- package/dist/errors/audit-log/audit-log-errors.d.ts.map +1 -0
- package/dist/errors/audit-log/audit-log-errors.js +31 -0
- package/dist/errors/index.d.ts +1 -0
- package/dist/errors/index.d.ts.map +1 -1
- package/dist/errors/index.js +1 -0
- package/dist/errors/share-data/share-data-errors.d.ts +18 -0
- package/dist/errors/share-data/share-data-errors.d.ts.map +1 -1
- package/dist/errors/share-data/share-data-errors.js +27 -1
- package/dist/helpers/file/file-helpers.d.ts +2 -1
- package/dist/helpers/file/file-helpers.d.ts.map +1 -1
- package/dist/helpers/file/file-helpers.js +6 -2
- package/dist/models/application/audit-log/application-audit-log-models.d.ts +87 -0
- package/dist/models/application/audit-log/application-audit-log-models.d.ts.map +1 -0
- package/dist/models/application/audit-log/application-audit-log-models.js +59 -0
- package/dist/models/rules/share-rule-models.d.ts +74 -70
- package/dist/models/rules/share-rule-models.d.ts.map +1 -1
- package/dist/models/rules/share-rule-models.js +25 -40
- package/package.json +1 -1
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This contains the settings for the application.
|
|
3
|
+
*/
|
|
4
|
+
export declare const ApplicationSettings: {
|
|
5
|
+
MultiplePathALAI: string;
|
|
6
|
+
SystemValues: {
|
|
7
|
+
MaxSnapshotSize: number;
|
|
8
|
+
MaxSnapshotSizeLargeDocSet: number;
|
|
9
|
+
MaxStorageRecordsPerDoc: number;
|
|
10
|
+
MaxDocumentsToDeleteInBatch: number;
|
|
11
|
+
};
|
|
12
|
+
SystemUser: string;
|
|
13
|
+
};
|
|
14
|
+
//# sourceMappingURL=application-settings.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"application-settings.d.ts","sourceRoot":"","sources":["../../src/_settings/application-settings.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,eAAO,MAAM,mBAAmB;;;;;;;;;CAS/B,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ApplicationSettings = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* This contains the settings for the application.
|
|
6
|
+
*/
|
|
7
|
+
exports.ApplicationSettings = {
|
|
8
|
+
MultiplePathALAI: 'MultiplePathALAI', // the multiple path ALAI (used for the reference path fo the ALAI)
|
|
9
|
+
SystemValues: {
|
|
10
|
+
MaxSnapshotSize: 20, // the maximum number of snapshots to execute aka, store or retrieve in one request.
|
|
11
|
+
MaxSnapshotSizeLargeDocSet: 5, // the maximum number of snapshots to execute aka, store or retrieve in one request for a large document set.
|
|
12
|
+
MaxStorageRecordsPerDoc: 20, // the maximum number of records to store on a document.
|
|
13
|
+
MaxDocumentsToDeleteInBatch: 100, // the maximum number of documents to delete in a batch.
|
|
14
|
+
},
|
|
15
|
+
SystemUser: 'System', // the system user
|
|
16
|
+
};
|
package/dist/application/audit-log/additional-ids/create-audit-log-additional-ids-with-query.d.ts
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { IAdditionalApplicationAuditLogIds, IQueryObjectAndValueForAuditLog } from '../../../models/application/audit-log/application-audit-log-models';
|
|
2
|
+
/**
|
|
3
|
+
* This function creates the Audit Log Additional Ids with a query
|
|
4
|
+
*
|
|
5
|
+
* @param isQuery this is a query
|
|
6
|
+
* @param additionalApplicationAuditLogs the additional application audit logs
|
|
7
|
+
* @param queryVariables the query variables
|
|
8
|
+
* @returns
|
|
9
|
+
*/
|
|
10
|
+
declare const createAuditLogAdditionalIdsWithQuery: (isQuery: boolean, additionalApplicationAuditLogIds: IAdditionalApplicationAuditLogIds[], queryVariables?: IQueryObjectAndValueForAuditLog[]) => IAdditionalApplicationAuditLogIds[];
|
|
11
|
+
export { createAuditLogAdditionalIdsWithQuery };
|
|
12
|
+
//# sourceMappingURL=create-audit-log-additional-ids-with-query.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-audit-log-additional-ids-with-query.d.ts","sourceRoot":"","sources":["../../../../src/application/audit-log/additional-ids/create-audit-log-additional-ids-with-query.ts"],"names":[],"mappings":"AACA,OAAO,EACH,iCAAiC,EACjC,+BAA+B,EAClC,MAAM,oEAAoE,CAAC;AAG5E;;;;;;;GAOG;AACH,QAAA,MAAM,oCAAoC,YAC7B,OAAO,oCACkB,iCAAiC,EAAE,mBACrD,+BAA+B,EAAE,KAClD,iCAAiC,EAiBnC,CAAC;AAEF,OAAO,EAAE,oCAAoC,EAAE,CAAC"}
|
package/dist/application/audit-log/additional-ids/create-audit-log-additional-ids-with-query.js
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.createAuditLogAdditionalIdsWithQuery = void 0;
|
|
4
|
+
const audit_log_errors_1 = require("../../../errors/audit-log/audit-log-errors");
|
|
5
|
+
const create_query_audit_log_for_alai_1 = require("./create-query-audit-log-for-alai");
|
|
6
|
+
/**
|
|
7
|
+
* This function creates the Audit Log Additional Ids with a query
|
|
8
|
+
*
|
|
9
|
+
* @param isQuery this is a query
|
|
10
|
+
* @param additionalApplicationAuditLogs the additional application audit logs
|
|
11
|
+
* @param queryVariables the query variables
|
|
12
|
+
* @returns
|
|
13
|
+
*/
|
|
14
|
+
const createAuditLogAdditionalIdsWithQuery = (isQuery, additionalApplicationAuditLogIds, queryVariables = []) => {
|
|
15
|
+
if (isQuery) {
|
|
16
|
+
if (queryVariables.length === 0)
|
|
17
|
+
throw new audit_log_errors_1.AuditLogAlaiQueryNotProvidedError();
|
|
18
|
+
const queryALAI = (0, create_query_audit_log_for_alai_1.createQueryAuditLogForALAI)(queryVariables);
|
|
19
|
+
// get the last audit log additional id record
|
|
20
|
+
const lastIndex = additionalApplicationAuditLogIds.length - 1;
|
|
21
|
+
const queryALAIRecord = additionalApplicationAuditLogIds[lastIndex];
|
|
22
|
+
queryALAIRecord.referenceId = queryALAI; // update the reference path
|
|
23
|
+
additionalApplicationAuditLogIds[lastIndex] = queryALAIRecord;
|
|
24
|
+
}
|
|
25
|
+
else {
|
|
26
|
+
const lastIndex = additionalApplicationAuditLogIds.length - 1;
|
|
27
|
+
const lastRecord = additionalApplicationAuditLogIds[lastIndex];
|
|
28
|
+
if (lastRecord.referenceId === '')
|
|
29
|
+
throw new audit_log_errors_1.AuditLogAlaiIdNotProvidedError();
|
|
30
|
+
}
|
|
31
|
+
return additionalApplicationAuditLogIds;
|
|
32
|
+
};
|
|
33
|
+
exports.createAuditLogAdditionalIdsWithQuery = createAuditLogAdditionalIdsWithQuery;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { IAdditionalApplicationAuditLogIds } from '../../../models/application/audit-log/application-audit-log-models';
|
|
2
|
+
/**
|
|
3
|
+
* This function creates the multiple path Audit Log Additional Ids
|
|
4
|
+
*
|
|
5
|
+
* @param referencePaths the paths to the database storage for the audit log ie. /sharedata/{id}, /sharefunctions/{id}
|
|
6
|
+
* @returns
|
|
7
|
+
*/
|
|
8
|
+
declare const createMultiplePathALAI: (referencePaths: string[]) => IAdditionalApplicationAuditLogIds[];
|
|
9
|
+
export { createMultiplePathALAI };
|
|
10
|
+
//# sourceMappingURL=create-mulitple-path-alai.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-mulitple-path-alai.d.ts","sourceRoot":"","sources":["../../../../src/application/audit-log/additional-ids/create-mulitple-path-alai.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iCAAiC,EAAE,MAAM,oEAAoE,CAAC;AAEvH;;;;;GAKG;AACH,QAAA,MAAM,sBAAsB,mBAAoB,MAAM,EAAE,KAAG,iCAAiC,EAQ3F,CAAC;AAEF,OAAO,EAAE,sBAAsB,EAAE,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.createMultiplePathALAI = void 0;
|
|
4
|
+
const application_settings_1 = require("../../../_settings/application-settings");
|
|
5
|
+
/**
|
|
6
|
+
* This function creates the multiple path Audit Log Additional Ids
|
|
7
|
+
*
|
|
8
|
+
* @param referencePaths the paths to the database storage for the audit log ie. /sharedata/{id}, /sharefunctions/{id}
|
|
9
|
+
* @returns
|
|
10
|
+
*/
|
|
11
|
+
const createMultiplePathALAI = (referencePaths) => {
|
|
12
|
+
const additionalApplicationAuditLogIds = [];
|
|
13
|
+
for (const referencePath of referencePaths) {
|
|
14
|
+
additionalApplicationAuditLogIds.push({ referencePath: application_settings_1.ApplicationSettings.MultiplePathALAI, referenceId: referencePath });
|
|
15
|
+
}
|
|
16
|
+
return additionalApplicationAuditLogIds;
|
|
17
|
+
};
|
|
18
|
+
exports.createMultiplePathALAI = createMultiplePathALAI;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { IQueryObjectAndValueForAuditLog } from '../../../models/application/audit-log/application-audit-log-models';
|
|
2
|
+
/**
|
|
3
|
+
* this creates a query audit log for ALAI
|
|
4
|
+
*
|
|
5
|
+
* @param queryVariables the query variables to add for the audit log.
|
|
6
|
+
* @returns
|
|
7
|
+
*/
|
|
8
|
+
declare const createQueryAuditLogForALAI: (queryVariables: IQueryObjectAndValueForAuditLog[]) => string;
|
|
9
|
+
export { createQueryAuditLogForALAI };
|
|
10
|
+
//# sourceMappingURL=create-query-audit-log-for-alai.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-query-audit-log-for-alai.d.ts","sourceRoot":"","sources":["../../../../src/application/audit-log/additional-ids/create-query-audit-log-for-alai.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,+BAA+B,EAAE,MAAM,oEAAoE,CAAC;AAErH;;;;;GAKG;AACH,QAAA,MAAM,0BAA0B,mBAAoB,+BAA+B,EAAE,KAAG,MASvF,CAAC;AAEF,OAAO,EAAE,0BAA0B,EAAE,CAAC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.createQueryAuditLogForALAI = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* this creates a query audit log for ALAI
|
|
6
|
+
*
|
|
7
|
+
* @param queryVariables the query variables to add for the audit log.
|
|
8
|
+
* @returns
|
|
9
|
+
*/
|
|
10
|
+
const createQueryAuditLogForALAI = (queryVariables) => {
|
|
11
|
+
let queryAuditLog = 'Query Performed with variables: ';
|
|
12
|
+
if (queryVariables.length > 0) {
|
|
13
|
+
for (const queryVariable of queryVariables) {
|
|
14
|
+
queryAuditLog += queryVariable.queryObject + ':' + queryVariable.queryValue.toString() + ', ';
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
return queryAuditLog;
|
|
18
|
+
};
|
|
19
|
+
exports.createQueryAuditLogForALAI = createQueryAuditLogForALAI;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { ApplicationAuditLogAction, ApplicationAuditLogSubType, ApplicationAuditLogType, IAdditionalApplicationAuditLogIds, IApplicationAuditLog } from '../../models/application/audit-log/application-audit-log-models';
|
|
2
|
+
/**
|
|
3
|
+
* This creates the application audit log.
|
|
4
|
+
*
|
|
5
|
+
* @param applicationAuditLogAction this is the action that was performed.
|
|
6
|
+
* @param applicationAuditLogType this is the type of audit log.
|
|
7
|
+
* @param applicationAuditLogSubType the sub type of audit log.
|
|
8
|
+
* @param createdBy the is the user Id of the user that created the audit log.
|
|
9
|
+
* @param currentData the current data.
|
|
10
|
+
* @param previousData the previous data.
|
|
11
|
+
* @param championsNetworkId the champions network Id.
|
|
12
|
+
* @param organizationId the organization Id.
|
|
13
|
+
*/
|
|
14
|
+
declare const createApplicationLog: (applicationAuditLogAction: ApplicationAuditLogAction, applicationAuditLogSubType: ApplicationAuditLogSubType, createdBy: string, applicationAuditLogType?: ApplicationAuditLogType, alai?: IAdditionalApplicationAuditLogIds[], currentData?: any, previousData?: any) => IApplicationAuditLog;
|
|
15
|
+
export { createApplicationLog };
|
|
16
|
+
//# sourceMappingURL=create-application-audit-log.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-application-audit-log.d.ts","sourceRoot":"","sources":["../../../src/application/audit-log/create-application-audit-log.ts"],"names":[],"mappings":"AAEA,OAAO,EACH,yBAAyB,EACzB,0BAA0B,EAC1B,uBAAuB,EACvB,iCAAiC,EACjC,oBAAoB,EACvB,MAAM,iEAAiE,CAAC;AAEzE;;;;;;;;;;;GAWG;AACH,QAAA,MAAM,oBAAoB,8BACK,yBAAyB,8BACxB,0BAA0B,aAC3C,MAAM,4BACQ,uBAAuB,SAC1C,iCAAiC,EAAE,gBAC3B,GAAG,iBACF,GAAG,KACnB,oBAaF,CAAC;AAEF,OAAO,EAAE,oBAAoB,EAAE,CAAC"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.createApplicationLog = void 0;
|
|
5
|
+
const application_audit_log_models_1 = require("../../models/application/audit-log/application-audit-log-models");
|
|
6
|
+
/**
|
|
7
|
+
* This creates the application audit log.
|
|
8
|
+
*
|
|
9
|
+
* @param applicationAuditLogAction this is the action that was performed.
|
|
10
|
+
* @param applicationAuditLogType this is the type of audit log.
|
|
11
|
+
* @param applicationAuditLogSubType the sub type of audit log.
|
|
12
|
+
* @param createdBy the is the user Id of the user that created the audit log.
|
|
13
|
+
* @param currentData the current data.
|
|
14
|
+
* @param previousData the previous data.
|
|
15
|
+
* @param championsNetworkId the champions network Id.
|
|
16
|
+
* @param organizationId the organization Id.
|
|
17
|
+
*/
|
|
18
|
+
const createApplicationLog = (applicationAuditLogAction, applicationAuditLogSubType, createdBy, applicationAuditLogType = application_audit_log_models_1.ApplicationAuditLogType.global, alai = [], currentData, previousData) => {
|
|
19
|
+
const auditLog = {
|
|
20
|
+
additionalAuditLogIds: alai,
|
|
21
|
+
applicationAuditLogAction,
|
|
22
|
+
applicationAuditLogType,
|
|
23
|
+
applicationAuditLogSubType,
|
|
24
|
+
createdBy,
|
|
25
|
+
createdAt: Date.now(),
|
|
26
|
+
};
|
|
27
|
+
if (currentData)
|
|
28
|
+
auditLog.currentData = currentData;
|
|
29
|
+
if (previousData)
|
|
30
|
+
auditLog.previousData = previousData;
|
|
31
|
+
return auditLog;
|
|
32
|
+
};
|
|
33
|
+
exports.createApplicationLog = createApplicationLog;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export * from './audit-log/additional-ids/create-audit-log-additional-ids-with-query';
|
|
2
|
+
export * from './audit-log/additional-ids/create-mulitple-path-alai';
|
|
3
|
+
export * from './audit-log/additional-ids/create-query-audit-log-for-alai';
|
|
4
|
+
export * from './audit-log/create-application-audit-log';
|
|
5
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/application/index.ts"],"names":[],"mappings":"AAKA,cAAc,uEAAuE,CAAC;AACtF,cAAc,sDAAsD,CAAC;AACrE,cAAc,4DAA4D,CAAC;AAG3E,cAAc,0CAA0C,CAAC"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
//#region Application
|
|
3
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
+
if (k2 === undefined) k2 = k;
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
10
|
+
}) : (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
o[k2] = m[k];
|
|
13
|
+
}));
|
|
14
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
15
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
16
|
+
};
|
|
17
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
+
//#region Audit Log
|
|
19
|
+
//#region Additional Ids
|
|
20
|
+
__exportStar(require("./audit-log/additional-ids/create-audit-log-additional-ids-with-query"), exports);
|
|
21
|
+
__exportStar(require("./audit-log/additional-ids/create-mulitple-path-alai"), exports);
|
|
22
|
+
__exportStar(require("./audit-log/additional-ids/create-query-audit-log-for-alai"), exports);
|
|
23
|
+
//#endregion Additional Ids
|
|
24
|
+
__exportStar(require("./audit-log/create-application-audit-log"), exports);
|
|
25
|
+
//#endregion Audit Log
|
|
26
|
+
//#endregion Application
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { BaseError } from '../base-error';
|
|
2
|
+
/**
|
|
3
|
+
* This is throw when the Audit Log Additional Id's reference id is not provided.
|
|
4
|
+
*/
|
|
5
|
+
export declare class AuditLogAlaiIdNotProvidedError extends BaseError {
|
|
6
|
+
/**
|
|
7
|
+
* This is throw when the Additional Log Additional Id's reference id is not provided.
|
|
8
|
+
*/
|
|
9
|
+
constructor();
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* This is throw when the Audit Log Additional Id's query is not provided.
|
|
13
|
+
*/
|
|
14
|
+
export declare class AuditLogAlaiQueryNotProvidedError extends BaseError {
|
|
15
|
+
/**
|
|
16
|
+
* This is throw when the Audit Log Additional Id's query is not provided.
|
|
17
|
+
*/
|
|
18
|
+
constructor();
|
|
19
|
+
}
|
|
20
|
+
//# sourceMappingURL=audit-log-errors.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"audit-log-errors.d.ts","sourceRoot":"","sources":["../../../src/errors/audit-log/audit-log-errors.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAI1C;;GAEG;AACH,qBAAa,8BAA+B,SAAQ,SAAS;IACzD;;OAEG;;CAIN;AAED;;GAEG;AACH,qBAAa,iCAAkC,SAAQ,SAAS;IAC5D;;OAEG;;CAIN"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.AuditLogAlaiQueryNotProvidedError = exports.AuditLogAlaiIdNotProvidedError = void 0;
|
|
4
|
+
// This file contains the errors for that can occur in the audit log.
|
|
5
|
+
const base_error_1 = require("../base-error");
|
|
6
|
+
//#region Audit Log Additional Id's Errors
|
|
7
|
+
/**
|
|
8
|
+
* This is throw when the Audit Log Additional Id's reference id is not provided.
|
|
9
|
+
*/
|
|
10
|
+
class AuditLogAlaiIdNotProvidedError extends base_error_1.BaseError {
|
|
11
|
+
/**
|
|
12
|
+
* This is throw when the Additional Log Additional Id's reference id is not provided.
|
|
13
|
+
*/
|
|
14
|
+
constructor() {
|
|
15
|
+
super('Audit Log Additional Id\'s reference id is not provided');
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
exports.AuditLogAlaiIdNotProvidedError = AuditLogAlaiIdNotProvidedError;
|
|
19
|
+
/**
|
|
20
|
+
* This is throw when the Audit Log Additional Id's query is not provided.
|
|
21
|
+
*/
|
|
22
|
+
class AuditLogAlaiQueryNotProvidedError extends base_error_1.BaseError {
|
|
23
|
+
/**
|
|
24
|
+
* This is throw when the Audit Log Additional Id's query is not provided.
|
|
25
|
+
*/
|
|
26
|
+
constructor() {
|
|
27
|
+
super('Audit Log Additional Id\'s query is not provided');
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
exports.AuditLogAlaiQueryNotProvidedError = AuditLogAlaiQueryNotProvidedError;
|
|
31
|
+
//#endregion Audit Log Additional Id's Errors
|
package/dist/errors/index.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/errors/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC;AAC7B,cAAc,0BAA0B,CAAC;AACzC,cAAc,0BAA0B,CAAC;AACzC,cAAc,0BAA0B,CAAC;AACzC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,gCAAgC,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/errors/index.ts"],"names":[],"mappings":"AAAA,cAAc,8BAA8B,CAAC;AAC7C,cAAc,cAAc,CAAC;AAC7B,cAAc,0BAA0B,CAAC;AACzC,cAAc,0BAA0B,CAAC;AACzC,cAAc,0BAA0B,CAAC;AACzC,cAAc,8BAA8B,CAAC;AAC7C,cAAc,gCAAgC,CAAC"}
|
package/dist/errors/index.js
CHANGED
|
@@ -14,6 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
14
14
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
15
|
};
|
|
16
16
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./audit-log/audit-log-errors"), exports);
|
|
17
18
|
__exportStar(require("./base-error"), exports);
|
|
18
19
|
__exportStar(require("./generic/generic-errors"), exports);
|
|
19
20
|
__exportStar(require("./request/request-errors"), exports);
|
|
@@ -46,4 +46,22 @@ export declare class ShareDataFunctionHashNotValid extends BaseError {
|
|
|
46
46
|
*/
|
|
47
47
|
constructor(shareDataId: string, shareDataFunction: IShareDataFunction, calculatedHash: string);
|
|
48
48
|
}
|
|
49
|
+
/**
|
|
50
|
+
* This is thrown when a rule doesn't have current conditions present.
|
|
51
|
+
*/
|
|
52
|
+
export declare class ShareRuleCurrentConditionsNotPresentError extends BaseError {
|
|
53
|
+
/**
|
|
54
|
+
* This is thrown when a rule doesn't have a before or after conditions.
|
|
55
|
+
*/
|
|
56
|
+
constructor(ruleId: string);
|
|
57
|
+
}
|
|
58
|
+
/**
|
|
59
|
+
* This is thrown when a rule doesn't have proposed conditions present.
|
|
60
|
+
*/
|
|
61
|
+
export declare class ShareRuleProposedConditionsNotPresentError extends BaseError {
|
|
62
|
+
/**
|
|
63
|
+
* This is thrown when a rule doesn't have a before or after conditions.
|
|
64
|
+
*/
|
|
65
|
+
constructor(ruleId: string);
|
|
66
|
+
}
|
|
49
67
|
//# sourceMappingURL=share-data-errors.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"share-data-errors.d.ts","sourceRoot":"","sources":["../../../src/errors/share-data/share-data-errors.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAC1C,OAAO,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAC;AACpE,OAAO,EAAE,kBAAkB,EAAE,MAAM,mDAAmD,CAAC;AAEvF;;GAEG;AACH,qBAAa,sBAAuB,SAAQ,SAAS;IACjD;;OAEG;gBACS,WAAW,EAAE,MAAM,EAAE,aAAa,EAAE,cAAc;CAGjE;AAED;;GAEG;AACH,qBAAa,2CAA4C,SAAQ,SAAS;IACtE;;OAEG;gBACS,WAAW,EAAE,MAAM;CAGlC;AAED;;GAEG;AACH,qBAAa,uBAAwB,SAAQ,SAAS;IAClD;;OAEG;gBACS,WAAW,EAAE,MAAM;CAGlC;AAED;;GAEG;AACH,qBAAa,yDAA0D,SAAQ,SAAS;IACpF;;OAEG;gBACS,WAAW,EAAE,MAAM,EAAE,YAAY,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM;CAI5E;AAGD;;GAEG;AACH,qBAAa,6BAA8B,SAAQ,SAAS;IACxD;;OAEG;gBACS,WAAW,EAAE,MAAM,EAAE,iBAAiB,EAAE,kBAAkB,EAAE,cAAc,EAAE,MAAM;CAIjG"}
|
|
1
|
+
{"version":3,"file":"share-data-errors.d.ts","sourceRoot":"","sources":["../../../src/errors/share-data/share-data-errors.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAC1C,OAAO,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAC;AACpE,OAAO,EAAE,kBAAkB,EAAE,MAAM,mDAAmD,CAAC;AAEvF;;GAEG;AACH,qBAAa,sBAAuB,SAAQ,SAAS;IACjD;;OAEG;gBACS,WAAW,EAAE,MAAM,EAAE,aAAa,EAAE,cAAc;CAGjE;AAED;;GAEG;AACH,qBAAa,2CAA4C,SAAQ,SAAS;IACtE;;OAEG;gBACS,WAAW,EAAE,MAAM;CAGlC;AAED;;GAEG;AACH,qBAAa,uBAAwB,SAAQ,SAAS;IAClD;;OAEG;gBACS,WAAW,EAAE,MAAM;CAGlC;AAED;;GAEG;AACH,qBAAa,yDAA0D,SAAQ,SAAS;IACpF;;OAEG;gBACS,WAAW,EAAE,MAAM,EAAE,YAAY,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM;CAI5E;AAGD;;GAEG;AACH,qBAAa,6BAA8B,SAAQ,SAAS;IACxD;;OAEG;gBACS,WAAW,EAAE,MAAM,EAAE,iBAAiB,EAAE,kBAAkB,EAAE,cAAc,EAAE,MAAM;CAIjG;AAKD;;GAEG;AACH,qBAAa,yCAA0C,SAAQ,SAAS;IACpE;;OAEG;gBACS,MAAM,EAAE,MAAM;CAG7B;AAED;;GAEG;AACH,qBAAa,0CAA2C,SAAQ,SAAS;IACrE;;OAEG;gBACS,MAAM,EAAE,MAAM;CAG7B"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ShareDataFunctionHashNotValid = exports.ShareDataFunctionBeingAppliedDoesNotExistOnShareDataError = exports.ShareDataIntegrityError = exports.ShareDataCurrentAndProposalDataMatchesError = exports.ShareDataIsLockedError = void 0;
|
|
3
|
+
exports.ShareRuleProposedConditionsNotPresentError = exports.ShareRuleCurrentConditionsNotPresentError = exports.ShareDataFunctionHashNotValid = exports.ShareDataFunctionBeingAppliedDoesNotExistOnShareDataError = exports.ShareDataIntegrityError = exports.ShareDataCurrentAndProposalDataMatchesError = exports.ShareDataIsLockedError = void 0;
|
|
4
4
|
const base_error_1 = require("../base-error");
|
|
5
5
|
/**
|
|
6
6
|
* This error is thrown when a function is tried to be applied to the share data thats state is locked.
|
|
@@ -64,3 +64,29 @@ class ShareDataFunctionHashNotValid extends base_error_1.BaseError {
|
|
|
64
64
|
}
|
|
65
65
|
}
|
|
66
66
|
exports.ShareDataFunctionHashNotValid = ShareDataFunctionHashNotValid;
|
|
67
|
+
//#region Rules
|
|
68
|
+
/**
|
|
69
|
+
* This is thrown when a rule doesn't have current conditions present.
|
|
70
|
+
*/
|
|
71
|
+
class ShareRuleCurrentConditionsNotPresentError extends base_error_1.BaseError {
|
|
72
|
+
/**
|
|
73
|
+
* This is thrown when a rule doesn't have a before or after conditions.
|
|
74
|
+
*/
|
|
75
|
+
constructor(ruleId) {
|
|
76
|
+
super(`Rule with id ${ruleId} does not have any current conditions present.`);
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
exports.ShareRuleCurrentConditionsNotPresentError = ShareRuleCurrentConditionsNotPresentError;
|
|
80
|
+
/**
|
|
81
|
+
* This is thrown when a rule doesn't have proposed conditions present.
|
|
82
|
+
*/
|
|
83
|
+
class ShareRuleProposedConditionsNotPresentError extends base_error_1.BaseError {
|
|
84
|
+
/**
|
|
85
|
+
* This is thrown when a rule doesn't have a before or after conditions.
|
|
86
|
+
*/
|
|
87
|
+
constructor(ruleId) {
|
|
88
|
+
super(`Rule with id ${ruleId} does not have any proposed conditions present.`);
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
exports.ShareRuleProposedConditionsNotPresentError = ShareRuleProposedConditionsNotPresentError;
|
|
92
|
+
//#endregion Rules
|
|
@@ -5,8 +5,9 @@
|
|
|
5
5
|
* @param arrayOfFiles the array of files to add to.
|
|
6
6
|
* @param ignoreIndexFiles the flag to ignore index files.
|
|
7
7
|
* @param ignoreTestFiles the flag to ignore test files.
|
|
8
|
+
* @param ignoreTestDataFiles the flag to ignore test data files.
|
|
8
9
|
* @returns
|
|
9
10
|
*/
|
|
10
|
-
declare const getAllFiles: (dirPath: string, arrayOfFiles?: string[], ignoreIndexFiles?: boolean, ignoreTestFiles?: boolean) => string[];
|
|
11
|
+
declare const getAllFiles: (dirPath: string, arrayOfFiles?: string[], ignoreIndexFiles?: boolean, ignoreTestFiles?: boolean, ignoreTestDataFiles?: boolean) => string[];
|
|
11
12
|
export { getAllFiles };
|
|
12
13
|
//# sourceMappingURL=file-helpers.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"file-helpers.d.ts","sourceRoot":"","sources":["../../../src/helpers/file/file-helpers.ts"],"names":[],"mappings":"AAKA
|
|
1
|
+
{"version":3,"file":"file-helpers.d.ts","sourceRoot":"","sources":["../../../src/helpers/file/file-helpers.ts"],"names":[],"mappings":"AAKA;;;;;;;;;GASG;AACH,QAAA,MAAM,WAAW,YACN,MAAM,iBACD,MAAM,EAAE,2FAIrB,MAAM,EAsBR,CAAA;AAED,OAAO,EAAE,WAAW,EAAE,CAAC"}
|
|
@@ -14,20 +14,24 @@ const path_1 = __importDefault(require("path"));
|
|
|
14
14
|
* @param arrayOfFiles the array of files to add to.
|
|
15
15
|
* @param ignoreIndexFiles the flag to ignore index files.
|
|
16
16
|
* @param ignoreTestFiles the flag to ignore test files.
|
|
17
|
+
* @param ignoreTestDataFiles the flag to ignore test data files.
|
|
17
18
|
* @returns
|
|
18
19
|
*/
|
|
19
|
-
const getAllFiles = (dirPath, arrayOfFiles = [], ignoreIndexFiles = true, ignoreTestFiles = true) => {
|
|
20
|
+
const getAllFiles = (dirPath, arrayOfFiles = [], ignoreIndexFiles = true, ignoreTestFiles = true, ignoreTestDataFiles = true) => {
|
|
20
21
|
const files = fs_1.default.readdirSync(dirPath);
|
|
21
22
|
// loop through all the files in the directory.
|
|
22
23
|
files.forEach((file) => {
|
|
23
24
|
const filePath = path_1.default.join(dirPath, file);
|
|
24
25
|
if (fs_1.default.statSync(filePath).isDirectory()) {
|
|
25
|
-
getAllFiles(filePath, arrayOfFiles);
|
|
26
|
+
getAllFiles(filePath, arrayOfFiles, ignoreIndexFiles, ignoreTestFiles, ignoreTestDataFiles);
|
|
26
27
|
}
|
|
27
28
|
else {
|
|
28
29
|
if (ignoreTestFiles && file.endsWith('.test.ts')) {
|
|
29
30
|
return;
|
|
30
31
|
}
|
|
32
|
+
if (ignoreTestDataFiles && file.endsWith('.test-data.ts')) {
|
|
33
|
+
return;
|
|
34
|
+
}
|
|
31
35
|
if (ignoreIndexFiles && file === 'index.ts') {
|
|
32
36
|
return;
|
|
33
37
|
}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This contains interfaces for the audit logs that are generated in the system.
|
|
3
|
+
* This type of audit log is used to create and log application functions within a non structured database.
|
|
4
|
+
*/
|
|
5
|
+
export type IApplicationAuditLog = IApplicationAuditLogUnstructured;
|
|
6
|
+
/**
|
|
7
|
+
* This is an application audit log.
|
|
8
|
+
*/
|
|
9
|
+
export interface IApplicationAuditLogUnstructured {
|
|
10
|
+
additionalAuditLogIds: IAdditionalApplicationAuditLogIds[];
|
|
11
|
+
applicationAuditLogAction: ApplicationAuditLogAction;
|
|
12
|
+
applicationAuditLogType: ApplicationAuditLogType;
|
|
13
|
+
applicationAuditLogSubType: ApplicationAuditLogSubType;
|
|
14
|
+
createdAt: number;
|
|
15
|
+
createdBy: string;
|
|
16
|
+
currentData?: any;
|
|
17
|
+
previousData?: any;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* This contains the additional audit log Ids in order of the access in the application
|
|
21
|
+
* for database this would be the reference path and reference Id
|
|
22
|
+
* for User Financial data this would be
|
|
23
|
+
* [
|
|
24
|
+
* { referencePath: 'Administrator', referenceId: '{{ administratorId }} ' }, // These are every path downstream from the root data
|
|
25
|
+
* { referencePath: 'Accounts', referenceId: '{{ accountId }}' },
|
|
26
|
+
* ]
|
|
27
|
+
*
|
|
28
|
+
* These are available in the helper files based on the Application Audit Log Sub Types.
|
|
29
|
+
*/
|
|
30
|
+
export interface IAdditionalApplicationAuditLogIds {
|
|
31
|
+
referencePath: string;
|
|
32
|
+
referenceId: string;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* This contains the enum for the audit log actions.
|
|
36
|
+
*/
|
|
37
|
+
export declare enum ApplicationAuditLogAction {
|
|
38
|
+
create = "create",
|
|
39
|
+
update = "update",
|
|
40
|
+
delete = "delete",
|
|
41
|
+
read = "read",
|
|
42
|
+
list = "list",
|
|
43
|
+
file = "file"
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* This contains the model for the audit logs that are generated in the system.
|
|
47
|
+
*/
|
|
48
|
+
export declare enum ApplicationAuditLogType {
|
|
49
|
+
authorizedAuthority = "authorizedAuthority",// the authorized authority audit log
|
|
50
|
+
global = "global"
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* This contains the enum for the audit log sub types for the multiple path classes.
|
|
54
|
+
*/
|
|
55
|
+
export declare enum MultiplePathAuditLogSubType {
|
|
56
|
+
multiplePathALAI = "multiplePathALAI"
|
|
57
|
+
}
|
|
58
|
+
/**
|
|
59
|
+
* This contains the interface for keeping the query audit log and value.
|
|
60
|
+
*/
|
|
61
|
+
export interface IQueryObjectAndValueForAuditLog {
|
|
62
|
+
queryObject: string;
|
|
63
|
+
queryValue: string | number | boolean;
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* This contains the enum for the audit log sub types.
|
|
67
|
+
*/
|
|
68
|
+
export type ApplicationAuditLogSubType = AdministrationAuditLogSubType | UserAuditLogSubType | PublicDataAuditLogSubType | MultiplePathAuditLogSubType;
|
|
69
|
+
/**
|
|
70
|
+
* This contains the enum for the audit log sub types for the administrator classes.
|
|
71
|
+
*/
|
|
72
|
+
export declare enum AdministrationAuditLogSubType {
|
|
73
|
+
administrator = "administrator"
|
|
74
|
+
}
|
|
75
|
+
/**
|
|
76
|
+
* This contains the enum for the audit log sub types for the user classes.
|
|
77
|
+
*/
|
|
78
|
+
export declare enum UserAuditLogSubType {
|
|
79
|
+
profile = "profile"
|
|
80
|
+
}
|
|
81
|
+
/**
|
|
82
|
+
* This contains the enum for the audit log sub types for the public data classes.
|
|
83
|
+
*/
|
|
84
|
+
export declare enum PublicDataAuditLogSubType {
|
|
85
|
+
userRelatedProfile = "userRelatedProfile"
|
|
86
|
+
}
|
|
87
|
+
//# sourceMappingURL=application-audit-log-models.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"application-audit-log-models.d.ts","sourceRoot":"","sources":["../../../../src/models/application/audit-log/application-audit-log-models.ts"],"names":[],"mappings":"AAEA;;;GAGG;AAIH,MAAM,MAAM,oBAAoB,GAAG,gCAAgC,CAAC;AACpE;;GAEG;AACH,MAAM,WAAW,gCAAgC;IAC7C,qBAAqB,EAAE,iCAAiC,EAAE,CAAC;IAC3D,yBAAyB,EAAE,yBAAyB,CAAC;IACrD,uBAAuB,EAAE,uBAAuB,CAAC;IACjD,0BAA0B,EAAE,0BAA0B,CAAC;IACvD,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,CAAC,EAAE,GAAG,CAAC;IAClB,YAAY,CAAC,EAAE,GAAG,CAAC;CACtB;AAED;;;;;;;;;;GAUG;AACH,MAAM,WAAW,iCAAiC;IAC9C,aAAa,EAAE,MAAM,CAAC;IACtB,WAAW,EAAE,MAAM,CAAC;CACvB;AAED;;GAEG;AACH,oBAAY,yBAAyB;IACjC,MAAM,WAAW;IACjB,MAAM,WAAW;IACjB,MAAM,WAAW;IACjB,IAAI,SAAS;IACb,IAAI,SAAS;IACb,IAAI,SAAS;CAChB;AAED;;GAEG;AACH,oBAAY,uBAAuB;IAC/B,mBAAmB,wBAAwB,CAAE,qCAAqC;IAClF,MAAM,WAAW;CACpB;AAKD;;GAEG;AACH,oBAAY,2BAA2B;IACnC,gBAAgB,qBAAqB;CACxC;AAMD;;GAEG;AACH,MAAM,WAAW,+BAA+B;IAC5C,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,GAAG,MAAM,GAAG,OAAO,CAAC;CACzC;AAMD;;GAEG;AAEH,MAAM,MAAM,0BAA0B,GAAG,6BAA6B,GAAG,mBAAmB,GAAG,yBAAyB,GAClH,2BAA2B,CAAC;AAIlC;;GAEG;AACH,oBAAY,6BAA6B;IACrC,aAAa,kBAAkB;CAClC;AAMD;;GAEG;AACH,oBAAY,mBAAmB;IAC3B,OAAO,YAAY;CACtB;AAMD;;GAEG;AACH,oBAAY,yBAAyB;IACjC,kBAAkB,uBAAuB;CAC5C"}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.PublicDataAuditLogSubType = exports.UserAuditLogSubType = exports.AdministrationAuditLogSubType = exports.MultiplePathAuditLogSubType = exports.ApplicationAuditLogType = exports.ApplicationAuditLogAction = void 0;
|
|
5
|
+
/**
|
|
6
|
+
* This contains the enum for the audit log actions.
|
|
7
|
+
*/
|
|
8
|
+
var ApplicationAuditLogAction;
|
|
9
|
+
(function (ApplicationAuditLogAction) {
|
|
10
|
+
ApplicationAuditLogAction["create"] = "create";
|
|
11
|
+
ApplicationAuditLogAction["update"] = "update";
|
|
12
|
+
ApplicationAuditLogAction["delete"] = "delete";
|
|
13
|
+
ApplicationAuditLogAction["read"] = "read";
|
|
14
|
+
ApplicationAuditLogAction["list"] = "list";
|
|
15
|
+
ApplicationAuditLogAction["file"] = "file";
|
|
16
|
+
})(ApplicationAuditLogAction || (exports.ApplicationAuditLogAction = ApplicationAuditLogAction = {}));
|
|
17
|
+
/**
|
|
18
|
+
* This contains the model for the audit logs that are generated in the system.
|
|
19
|
+
*/
|
|
20
|
+
var ApplicationAuditLogType;
|
|
21
|
+
(function (ApplicationAuditLogType) {
|
|
22
|
+
ApplicationAuditLogType["authorizedAuthority"] = "authorizedAuthority";
|
|
23
|
+
ApplicationAuditLogType["global"] = "global";
|
|
24
|
+
})(ApplicationAuditLogType || (exports.ApplicationAuditLogType = ApplicationAuditLogType = {}));
|
|
25
|
+
//#region Multiple Path Audit Log Types
|
|
26
|
+
/**
|
|
27
|
+
* This contains the enum for the audit log sub types for the multiple path classes.
|
|
28
|
+
*/
|
|
29
|
+
var MultiplePathAuditLogSubType;
|
|
30
|
+
(function (MultiplePathAuditLogSubType) {
|
|
31
|
+
MultiplePathAuditLogSubType["multiplePathALAI"] = "multiplePathALAI";
|
|
32
|
+
})(MultiplePathAuditLogSubType || (exports.MultiplePathAuditLogSubType = MultiplePathAuditLogSubType = {}));
|
|
33
|
+
//#region Administration Audit Log Types
|
|
34
|
+
/**
|
|
35
|
+
* This contains the enum for the audit log sub types for the administrator classes.
|
|
36
|
+
*/
|
|
37
|
+
var AdministrationAuditLogSubType;
|
|
38
|
+
(function (AdministrationAuditLogSubType) {
|
|
39
|
+
AdministrationAuditLogSubType["administrator"] = "administrator";
|
|
40
|
+
})(AdministrationAuditLogSubType || (exports.AdministrationAuditLogSubType = AdministrationAuditLogSubType = {}));
|
|
41
|
+
// #endregion Administration Audit Log Types
|
|
42
|
+
//#region User Audit Log Types
|
|
43
|
+
/**
|
|
44
|
+
* This contains the enum for the audit log sub types for the user classes.
|
|
45
|
+
*/
|
|
46
|
+
var UserAuditLogSubType;
|
|
47
|
+
(function (UserAuditLogSubType) {
|
|
48
|
+
UserAuditLogSubType["profile"] = "profile";
|
|
49
|
+
})(UserAuditLogSubType || (exports.UserAuditLogSubType = UserAuditLogSubType = {}));
|
|
50
|
+
//#endregion User Audit Log Types
|
|
51
|
+
//#region Public Data audit log types
|
|
52
|
+
/**
|
|
53
|
+
* This contains the enum for the audit log sub types for the public data classes.
|
|
54
|
+
*/
|
|
55
|
+
var PublicDataAuditLogSubType;
|
|
56
|
+
(function (PublicDataAuditLogSubType) {
|
|
57
|
+
PublicDataAuditLogSubType["userRelatedProfile"] = "userRelatedProfile";
|
|
58
|
+
})(PublicDataAuditLogSubType || (exports.PublicDataAuditLogSubType = PublicDataAuditLogSubType = {}));
|
|
59
|
+
//#endregion Public Data audit log types
|
|
@@ -33,6 +33,7 @@ export interface IRuleEvaluationResults {
|
|
|
33
33
|
*/
|
|
34
34
|
export interface IRuleSet {
|
|
35
35
|
id: string;
|
|
36
|
+
version: number;
|
|
36
37
|
name: string;
|
|
37
38
|
description: string;
|
|
38
39
|
ruleGroups: IRuleGroup[];
|
|
@@ -51,7 +52,7 @@ export declare enum LogicalOperator {
|
|
|
51
52
|
*/
|
|
52
53
|
export interface IRuleGroup {
|
|
53
54
|
operator: LogicalOperator;
|
|
54
|
-
rules: (
|
|
55
|
+
rules: (IShareRuleApplied | IRuleGroup)[];
|
|
55
56
|
}
|
|
56
57
|
/**
|
|
57
58
|
* This contains the interface for a share rule in the share data object
|
|
@@ -70,20 +71,23 @@ export interface IShareRuleApplied extends IShareRule {
|
|
|
70
71
|
/**
|
|
71
72
|
* This contains the different types of conditions that can be evaluated.
|
|
72
73
|
*/
|
|
73
|
-
export type ConditionType =
|
|
74
|
+
export type ConditionType = ConditionTypeSingle | ConditionTypeRange | ConditionTypeStartsEndsWith | ConditionTypeBoolean | ConditionTypeCombinedRules;
|
|
74
75
|
/**
|
|
75
|
-
* This contains the choices for the
|
|
76
|
+
* This contains the choices for the type of qualifier.
|
|
76
77
|
*/
|
|
77
|
-
export declare enum
|
|
78
|
-
|
|
79
|
-
|
|
78
|
+
export declare enum ConditionTypeQualifier {
|
|
79
|
+
IS = "is",
|
|
80
|
+
IS_NOT = "is not"
|
|
80
81
|
}
|
|
81
82
|
/**
|
|
82
|
-
* This contains the choices for the
|
|
83
|
+
* This contains the choices for the type of condition.
|
|
83
84
|
*/
|
|
84
|
-
export declare enum
|
|
85
|
-
|
|
86
|
-
|
|
85
|
+
export declare enum ConditionTypeSingle {
|
|
86
|
+
TYPEOF = "typeof",// the type of the property
|
|
87
|
+
EQUAL = "equal",// the value is equal to the condition value
|
|
88
|
+
CONTAINS = "contains",// the value contains the condition value
|
|
89
|
+
NULL = "null",// the value is null
|
|
90
|
+
EMPTY = "empty"
|
|
87
91
|
}
|
|
88
92
|
/**
|
|
89
93
|
* This contains the choices for the range conditions.
|
|
@@ -94,13 +98,6 @@ export declare enum ConditionTypeRange {
|
|
|
94
98
|
GREATER_THAN_OR_EQUAL = "greater than or equal",
|
|
95
99
|
LESS_THAN_OR_EQUAL = "less than or equal"
|
|
96
100
|
}
|
|
97
|
-
/**
|
|
98
|
-
* This contains the choices for the contains conditions.
|
|
99
|
-
*/
|
|
100
|
-
export declare enum ConditionTypeContains {
|
|
101
|
-
CONTAINS = "contains",
|
|
102
|
-
NOT_CONTAINS = "not contains"
|
|
103
|
-
}
|
|
104
101
|
/**
|
|
105
102
|
* This contains the choices for the starts with and ends with conditions.
|
|
106
103
|
*/
|
|
@@ -108,26 +105,12 @@ export declare enum ConditionTypeStartsEndsWith {
|
|
|
108
105
|
STARTS_WITH = "starts with",
|
|
109
106
|
ENDS_WITH = "ends with"
|
|
110
107
|
}
|
|
111
|
-
/**
|
|
112
|
-
* This contains the choices for the null conditions.
|
|
113
|
-
*/
|
|
114
|
-
export declare enum ConditionTypeNull {
|
|
115
|
-
IS_NULL = "is null",
|
|
116
|
-
IS_NOT_NULL = "is not null"
|
|
117
|
-
}
|
|
118
108
|
/**
|
|
119
109
|
* This contains the choices for the boolean conditions.
|
|
120
110
|
*/
|
|
121
111
|
export declare enum ConditionTypeBoolean {
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
}
|
|
125
|
-
/**
|
|
126
|
-
* This contains the choices for the empty conditions.
|
|
127
|
-
*/
|
|
128
|
-
export declare enum ConditionTypeEmpty {
|
|
129
|
-
IS_EMPTY = "is empty",
|
|
130
|
-
IS_NOT_EMPTY = "is not empty"
|
|
112
|
+
TRUE = "true",
|
|
113
|
+
FALSE = "false"
|
|
131
114
|
}
|
|
132
115
|
/**
|
|
133
116
|
* This contains the choices for the special conditions.
|
|
@@ -135,10 +118,24 @@ export declare enum ConditionTypeEmpty {
|
|
|
135
118
|
export declare enum ConditionTypeSpecial {
|
|
136
119
|
PATTERN = "pattern"
|
|
137
120
|
}
|
|
121
|
+
/**
|
|
122
|
+
* This contains the choices for the combined rule conditions that are a type of object
|
|
123
|
+
*/
|
|
124
|
+
export declare enum ConditionTypeCombinedRules {
|
|
125
|
+
OBJECT = "object"
|
|
126
|
+
}
|
|
138
127
|
/**
|
|
139
128
|
* This is the interface for the conditional information in the checks.
|
|
140
129
|
*/
|
|
141
130
|
export type ICondition = IConditionTypeOf | IConditionEquality | IConditionRange | IConditionContains | IConditionStartsEndsWith | IConditionNull | IConditionBoolean | IConditionEmpty | IConditionSpecial;
|
|
131
|
+
/**
|
|
132
|
+
* This is the interface for the base condition.
|
|
133
|
+
*/
|
|
134
|
+
export interface IConditionBase {
|
|
135
|
+
conditionType: ConditionType;
|
|
136
|
+
conditionTypeQualifier: ConditionTypeQualifier;
|
|
137
|
+
targettedProperty: string;
|
|
138
|
+
}
|
|
142
139
|
/**
|
|
143
140
|
* These are the different choices for the types of data in a condition.
|
|
144
141
|
*/
|
|
@@ -158,41 +155,41 @@ export declare enum ConditionTypeOf {
|
|
|
158
155
|
* This is the interface for the type of condition.
|
|
159
156
|
*
|
|
160
157
|
const exampleConditionTypeOf: IConditionTypeOf = {
|
|
158
|
+
conditionType: ConditionTypeSingle.TYPEOF,
|
|
159
|
+
ConditionTypeQualifier: ConditionTypeQualifier.IS,
|
|
160
|
+
conditionValue: ConditionTypeOf.NUMBER,
|
|
161
161
|
targettedProperty: 'address.city.total',
|
|
162
|
-
conditionType: ConditionTypeTypeOf.IS_TYPEOF,
|
|
163
|
-
conditionValue: ConditionTypeOf.NUMBER
|
|
164
162
|
};
|
|
165
163
|
*/
|
|
166
|
-
export interface IConditionTypeOf {
|
|
167
|
-
|
|
168
|
-
conditionType: ConditionTypeTypeOf;
|
|
164
|
+
export interface IConditionTypeOf extends IConditionBase {
|
|
165
|
+
conditionType: ConditionTypeSingle.TYPEOF;
|
|
169
166
|
conditionValue: ConditionTypeOf;
|
|
170
167
|
}
|
|
171
168
|
/**
|
|
172
169
|
* This is the interface for the equality condition.
|
|
173
170
|
*
|
|
174
171
|
const exampleConditionEquality: IConditionEquality = {
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
172
|
+
conditionType: ConditionTypeSingle.EQUAL,
|
|
173
|
+
ConditionTypeQualifier: ConditionTypeQualifier.IS,
|
|
174
|
+
conditionValue: 100,
|
|
175
|
+
targettedProperty: 'address.city.total',
|
|
178
176
|
};
|
|
179
177
|
*/
|
|
180
|
-
export interface IConditionEquality {
|
|
181
|
-
|
|
182
|
-
conditionType: ConditionTypeEquality;
|
|
178
|
+
export interface IConditionEquality extends IConditionBase {
|
|
179
|
+
conditionType: ConditionTypeSingle.EQUAL;
|
|
183
180
|
conditionValue: number | string;
|
|
184
181
|
}
|
|
185
182
|
/**
|
|
186
183
|
* This is the interface for the range condition.
|
|
187
184
|
*
|
|
188
185
|
const exampleConditionRange: IConditionRange = {
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
186
|
+
conditionType: ConditionTypeRange.GREATER_THAN,
|
|
187
|
+
ConditionTypeQualifier: ConditionTypeQualifier.IS,
|
|
188
|
+
conditionValue: 100,
|
|
189
|
+
targettedProperty: 'address.city.total',
|
|
192
190
|
};
|
|
193
191
|
*/
|
|
194
|
-
export interface IConditionRange {
|
|
195
|
-
targettedProperty: string;
|
|
192
|
+
export interface IConditionRange extends IConditionBase {
|
|
196
193
|
conditionType: ConditionTypeRange;
|
|
197
194
|
conditionValue: string | number;
|
|
198
195
|
}
|
|
@@ -200,27 +197,27 @@ export interface IConditionRange {
|
|
|
200
197
|
* This is the interface for the contains condition.
|
|
201
198
|
*
|
|
202
199
|
const exampleConditionContains: IConditionContains = {
|
|
203
|
-
|
|
204
|
-
|
|
200
|
+
conditionType: ConditionTypeSingle.CONTAINS,
|
|
201
|
+
conditionTypeQualifier: ConditionTypeQualifier.IS,
|
|
205
202
|
conditionValue: ['gar'| 'garison' | 'garage']
|
|
203
|
+
targettedProperty: 'address.city.name',
|
|
206
204
|
* };
|
|
207
205
|
*/
|
|
208
|
-
export interface IConditionContains {
|
|
209
|
-
|
|
210
|
-
conditionType: ConditionTypeContains;
|
|
206
|
+
export interface IConditionContains extends IConditionBase {
|
|
207
|
+
conditionType: ConditionTypeSingle.CONTAINS;
|
|
211
208
|
conditionValue: string | string[] | number[];
|
|
212
209
|
}
|
|
213
210
|
/**
|
|
214
211
|
* This is the interface for the starts with and ends with condition.
|
|
215
212
|
*
|
|
216
213
|
const exampleConditionStartsEndsWith: IConditionStartsEndsWith = {
|
|
217
|
-
targettedProperty: 'address.city.name',
|
|
218
214
|
conditionType: ConditionTypeStartsEndsWith.STARTS_WITH,
|
|
215
|
+
conditionTypeQualifier: ConditionTypeQualifier.IS,
|
|
219
216
|
conditionValue: 'cal'
|
|
217
|
+
targettedProperty: 'address.city.name',
|
|
220
218
|
};
|
|
221
219
|
*/
|
|
222
|
-
export interface IConditionStartsEndsWith {
|
|
223
|
-
targettedProperty: string;
|
|
220
|
+
export interface IConditionStartsEndsWith extends IConditionBase {
|
|
224
221
|
conditionType: ConditionTypeStartsEndsWith;
|
|
225
222
|
conditionValue: string;
|
|
226
223
|
}
|
|
@@ -228,50 +225,57 @@ export interface IConditionStartsEndsWith {
|
|
|
228
225
|
* This is the interface for the null condition.
|
|
229
226
|
*
|
|
230
227
|
const exampleConditionNull: IConditionNull = {
|
|
228
|
+
conditionType: ConditionTypeSingle.NULL
|
|
231
229
|
targettedProperty: 'address.city.name',
|
|
232
|
-
conditionType: ConditionTypeNull.IS_NULL
|
|
233
230
|
};
|
|
234
231
|
*/
|
|
235
|
-
export interface IConditionNull {
|
|
236
|
-
|
|
237
|
-
conditionType: ConditionTypeNull;
|
|
232
|
+
export interface IConditionNull extends IConditionBase {
|
|
233
|
+
conditionType: ConditionTypeSingle.NULL;
|
|
238
234
|
}
|
|
239
235
|
/**
|
|
240
236
|
* This is the interface for the boolean condition.
|
|
241
237
|
*
|
|
242
238
|
const exampleConditionBoolean: IConditionBoolean = {
|
|
239
|
+
conditionType: ConditionTypeBoolean.TRUE,
|
|
240
|
+
conditionTypeQualifier: ConditionTypeQualifier.IS,
|
|
243
241
|
targettedProperty: 'address.city.name',
|
|
244
|
-
conditionType: ConditionTypeBoolean.IS_TRUE
|
|
245
242
|
};
|
|
246
243
|
*/
|
|
247
|
-
export interface IConditionBoolean {
|
|
248
|
-
targettedProperty: string;
|
|
244
|
+
export interface IConditionBoolean extends IConditionBase {
|
|
249
245
|
conditionType: ConditionTypeBoolean;
|
|
250
246
|
}
|
|
251
247
|
/**
|
|
252
248
|
* This is the interface for the empty condition.
|
|
253
249
|
*
|
|
254
250
|
const exampleConditionEmpty: IConditionEmpty = {
|
|
251
|
+
conditionType: ConditionTypeEmpty.IS_EMPTY,
|
|
252
|
+
conditionTypeQualifier: ConditionTypeQualifier.IS,
|
|
255
253
|
targettedProperty: 'address.city.name',
|
|
256
|
-
conditionType: ConditionTypeEmpty.IS_EMPTY
|
|
257
254
|
};
|
|
258
255
|
*/
|
|
259
|
-
export interface IConditionEmpty {
|
|
260
|
-
|
|
261
|
-
conditionType: ConditionTypeEmpty;
|
|
256
|
+
export interface IConditionEmpty extends IConditionBase {
|
|
257
|
+
conditionType: ConditionTypeSingle.EMPTY;
|
|
262
258
|
}
|
|
263
259
|
/**
|
|
264
260
|
* This is the interface for the special condition.
|
|
265
261
|
*
|
|
266
262
|
const exampleConditionSpecial: IConditionSpecial = {
|
|
267
|
-
targettedProperty: 'address.city.name',
|
|
268
263
|
conditionType: ConditionTypeSpecial.PATTERN,
|
|
264
|
+
conditionTypeQualifier: ConditionTypeQualifier.IS,
|
|
269
265
|
conditionValue: '^[a-zA-Z0-9]*$'
|
|
266
|
+
targettedProperty: 'address.city.name',
|
|
270
267
|
};
|
|
271
268
|
*/
|
|
272
269
|
export interface IConditionSpecial {
|
|
273
|
-
targettedProperty: string;
|
|
274
270
|
conditionType: ConditionTypeSpecial;
|
|
275
271
|
conditionValue: string;
|
|
276
272
|
}
|
|
273
|
+
/**
|
|
274
|
+
* This is the interface for the combined rule condition.
|
|
275
|
+
*/
|
|
276
|
+
export interface IConditionCombinedRules {
|
|
277
|
+
targettedProperty: string;
|
|
278
|
+
conditionType: ConditionTypeCombinedRules;
|
|
279
|
+
conditionValue: IRuleGroup;
|
|
280
|
+
}
|
|
277
281
|
//# sourceMappingURL=share-rule-models.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"share-rule-models.d.ts","sourceRoot":"","sources":["../../../src/models/rules/share-rule-models.ts"],"names":[],"mappings":"AACA;;GAEG;AAIH;;GAEG;AACH,MAAM,WAAW,yBAAyB;IACtC,MAAM,EAAE,MAAM,CAAC;IACf,aAAa,EAAE,OAAO,CAAC;IACvB,uBAAuB,EAAE,UAAU,EAAE,CAAC;IACtC,cAAc,EAAE,OAAO,CAAC;IACxB,wBAAwB,EAAE,UAAU,EAAE,CAAC;CAC1C;AAED;;GAEG;AACH,MAAM,WAAW,2BAA2B;IACxC,SAAS,EAAE,MAAM,CAAC;IAClB,eAAe,EAAE,OAAO,CAAC;IACzB,YAAY,EAAE,MAAM,CAAC;IACrB,yBAAyB,EAAE,yBAAyB,EAAE,CAAC;CAC1D;AAED;;GAEG;AACH,MAAM,WAAW,sBAAsB;IACnC,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,EAAE,2BAA2B,EAAE,CAAC;IAC5C,eAAe,EAAE,OAAO,CAAC;CAC5B;AAMD;;GAEG;AACH,MAAM,WAAW,QAAQ;IACrB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,UAAU,EAAE,CAAC;CAC5B;AAMD;;GAEG;AACH,oBAAY,eAAe;IACvB,GAAG,QAAQ;IACX,EAAE,OAAO;CACZ;AAED;;;;GAIG;AACH,MAAM,WAAW,UAAU;IACvB,QAAQ,EAAE,eAAe,CAAC;IAC1B,KAAK,EAAE,CAAC,
|
|
1
|
+
{"version":3,"file":"share-rule-models.d.ts","sourceRoot":"","sources":["../../../src/models/rules/share-rule-models.ts"],"names":[],"mappings":"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"}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* This file contains the models for the rules used in the share data.
|
|
4
4
|
*/
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.ConditionTypeOf = exports.
|
|
6
|
+
exports.ConditionTypeOf = exports.ConditionTypeCombinedRules = exports.ConditionTypeSpecial = exports.ConditionTypeBoolean = exports.ConditionTypeStartsEndsWith = exports.ConditionTypeRange = exports.ConditionTypeSingle = exports.ConditionTypeQualifier = exports.LogicalOperator = void 0;
|
|
7
7
|
//#endregion RuleSet
|
|
8
8
|
//#region RuleGroup
|
|
9
9
|
/**
|
|
@@ -15,21 +15,24 @@ var LogicalOperator;
|
|
|
15
15
|
LogicalOperator["OR"] = "OR";
|
|
16
16
|
})(LogicalOperator || (exports.LogicalOperator = LogicalOperator = {}));
|
|
17
17
|
/**
|
|
18
|
-
* This contains the choices for the
|
|
18
|
+
* This contains the choices for the type of qualifier.
|
|
19
19
|
*/
|
|
20
|
-
var
|
|
21
|
-
(function (
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
})(
|
|
20
|
+
var ConditionTypeQualifier;
|
|
21
|
+
(function (ConditionTypeQualifier) {
|
|
22
|
+
ConditionTypeQualifier["IS"] = "is";
|
|
23
|
+
ConditionTypeQualifier["IS_NOT"] = "is not";
|
|
24
|
+
})(ConditionTypeQualifier || (exports.ConditionTypeQualifier = ConditionTypeQualifier = {}));
|
|
25
25
|
/**
|
|
26
|
-
* This contains the choices for the
|
|
26
|
+
* This contains the choices for the type of condition.
|
|
27
27
|
*/
|
|
28
|
-
var
|
|
29
|
-
(function (
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
28
|
+
var ConditionTypeSingle;
|
|
29
|
+
(function (ConditionTypeSingle) {
|
|
30
|
+
ConditionTypeSingle["TYPEOF"] = "typeof";
|
|
31
|
+
ConditionTypeSingle["EQUAL"] = "equal";
|
|
32
|
+
ConditionTypeSingle["CONTAINS"] = "contains";
|
|
33
|
+
ConditionTypeSingle["NULL"] = "null";
|
|
34
|
+
ConditionTypeSingle["EMPTY"] = "empty";
|
|
35
|
+
})(ConditionTypeSingle || (exports.ConditionTypeSingle = ConditionTypeSingle = {}));
|
|
33
36
|
/**
|
|
34
37
|
* This contains the choices for the range conditions.
|
|
35
38
|
*/
|
|
@@ -40,14 +43,6 @@ var ConditionTypeRange;
|
|
|
40
43
|
ConditionTypeRange["GREATER_THAN_OR_EQUAL"] = "greater than or equal";
|
|
41
44
|
ConditionTypeRange["LESS_THAN_OR_EQUAL"] = "less than or equal";
|
|
42
45
|
})(ConditionTypeRange || (exports.ConditionTypeRange = ConditionTypeRange = {}));
|
|
43
|
-
/**
|
|
44
|
-
* This contains the choices for the contains conditions.
|
|
45
|
-
*/
|
|
46
|
-
var ConditionTypeContains;
|
|
47
|
-
(function (ConditionTypeContains) {
|
|
48
|
-
ConditionTypeContains["CONTAINS"] = "contains";
|
|
49
|
-
ConditionTypeContains["NOT_CONTAINS"] = "not contains";
|
|
50
|
-
})(ConditionTypeContains || (exports.ConditionTypeContains = ConditionTypeContains = {}));
|
|
51
46
|
/**
|
|
52
47
|
* This contains the choices for the starts with and ends with conditions.
|
|
53
48
|
*/
|
|
@@ -56,30 +51,14 @@ var ConditionTypeStartsEndsWith;
|
|
|
56
51
|
ConditionTypeStartsEndsWith["STARTS_WITH"] = "starts with";
|
|
57
52
|
ConditionTypeStartsEndsWith["ENDS_WITH"] = "ends with";
|
|
58
53
|
})(ConditionTypeStartsEndsWith || (exports.ConditionTypeStartsEndsWith = ConditionTypeStartsEndsWith = {}));
|
|
59
|
-
/**
|
|
60
|
-
* This contains the choices for the null conditions.
|
|
61
|
-
*/
|
|
62
|
-
var ConditionTypeNull;
|
|
63
|
-
(function (ConditionTypeNull) {
|
|
64
|
-
ConditionTypeNull["IS_NULL"] = "is null";
|
|
65
|
-
ConditionTypeNull["IS_NOT_NULL"] = "is not null";
|
|
66
|
-
})(ConditionTypeNull || (exports.ConditionTypeNull = ConditionTypeNull = {}));
|
|
67
54
|
/**
|
|
68
55
|
* This contains the choices for the boolean conditions.
|
|
69
56
|
*/
|
|
70
57
|
var ConditionTypeBoolean;
|
|
71
58
|
(function (ConditionTypeBoolean) {
|
|
72
|
-
ConditionTypeBoolean["
|
|
73
|
-
ConditionTypeBoolean["
|
|
59
|
+
ConditionTypeBoolean["TRUE"] = "true";
|
|
60
|
+
ConditionTypeBoolean["FALSE"] = "false";
|
|
74
61
|
})(ConditionTypeBoolean || (exports.ConditionTypeBoolean = ConditionTypeBoolean = {}));
|
|
75
|
-
/**
|
|
76
|
-
* This contains the choices for the empty conditions.
|
|
77
|
-
*/
|
|
78
|
-
var ConditionTypeEmpty;
|
|
79
|
-
(function (ConditionTypeEmpty) {
|
|
80
|
-
ConditionTypeEmpty["IS_EMPTY"] = "is empty";
|
|
81
|
-
ConditionTypeEmpty["IS_NOT_EMPTY"] = "is not empty";
|
|
82
|
-
})(ConditionTypeEmpty || (exports.ConditionTypeEmpty = ConditionTypeEmpty = {}));
|
|
83
62
|
/**
|
|
84
63
|
* This contains the choices for the special conditions.
|
|
85
64
|
*/
|
|
@@ -87,6 +66,13 @@ var ConditionTypeSpecial;
|
|
|
87
66
|
(function (ConditionTypeSpecial) {
|
|
88
67
|
ConditionTypeSpecial["PATTERN"] = "pattern";
|
|
89
68
|
})(ConditionTypeSpecial || (exports.ConditionTypeSpecial = ConditionTypeSpecial = {}));
|
|
69
|
+
/**
|
|
70
|
+
* This contains the choices for the combined rule conditions that are a type of object
|
|
71
|
+
*/
|
|
72
|
+
var ConditionTypeCombinedRules;
|
|
73
|
+
(function (ConditionTypeCombinedRules) {
|
|
74
|
+
ConditionTypeCombinedRules["OBJECT"] = "object";
|
|
75
|
+
})(ConditionTypeCombinedRules || (exports.ConditionTypeCombinedRules = ConditionTypeCombinedRules = {}));
|
|
90
76
|
/**
|
|
91
77
|
* These are the different choices for the types of data in a condition.
|
|
92
78
|
*/
|
|
@@ -101,7 +87,6 @@ var ConditionTypeOf;
|
|
|
101
87
|
ConditionTypeOf["NULL"] = "null";
|
|
102
88
|
ConditionTypeOf["UNDEFINED"] = "undefined";
|
|
103
89
|
ConditionTypeOf["FUNCTION"] = "function";
|
|
104
|
-
// SYMBOL = 'symbol',
|
|
105
90
|
ConditionTypeOf["BIGINT"] = "bigint";
|
|
106
91
|
})(ConditionTypeOf || (exports.ConditionTypeOf = ConditionTypeOf = {}));
|
|
107
92
|
//#endregion Conditions
|
package/package.json
CHANGED