@memberjunction/core-entities 4.1.0 → 4.3.0
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.
|
@@ -4890,7 +4890,7 @@ export const DuplicateRunDetailSchema = z.object({
|
|
|
4890
4890
|
* * Default Value: newsequentialid()`),
|
|
4891
4891
|
DuplicateRunID: z.string().describe(`
|
|
4892
4892
|
* * Field Name: DuplicateRunID
|
|
4893
|
-
* * Display Name: Duplicate Run
|
|
4893
|
+
* * Display Name: Duplicate Run
|
|
4894
4894
|
* * SQL Data Type: uniqueidentifier
|
|
4895
4895
|
* * Related Entity/Foreign Key: Duplicate Runs (vwDuplicateRuns.ID)`),
|
|
4896
4896
|
RecordID: z.string().describe(`
|
|
@@ -5153,7 +5153,7 @@ export const EmployeeSkillSchema = z.object({
|
|
|
5153
5153
|
* * Related Entity/Foreign Key: Employees (vwEmployees.ID)`),
|
|
5154
5154
|
SkillID: z.string().describe(`
|
|
5155
5155
|
* * Field Name: SkillID
|
|
5156
|
-
* * Display Name: Skill
|
|
5156
|
+
* * Display Name: Skill
|
|
5157
5157
|
* * SQL Data Type: uniqueidentifier
|
|
5158
5158
|
* * Related Entity/Foreign Key: Skills (vwSkills.ID)`),
|
|
5159
5159
|
__mj_CreatedAt: z.date().describe(`
|
|
@@ -5172,7 +5172,7 @@ export const EmployeeSkillSchema = z.object({
|
|
|
5172
5172
|
* * SQL Data Type: nvarchar(81)`),
|
|
5173
5173
|
Skill: z.string().describe(`
|
|
5174
5174
|
* * Field Name: Skill
|
|
5175
|
-
* * Display Name: Skill
|
|
5175
|
+
* * Display Name: Skill Name
|
|
5176
5176
|
* * SQL Data Type: nvarchar(50)`),
|
|
5177
5177
|
});
|
|
5178
5178
|
/**
|
|
@@ -5631,12 +5631,12 @@ export const EntityActionFilterSchema = z.object({
|
|
|
5631
5631
|
* * Default Value: newsequentialid()`),
|
|
5632
5632
|
EntityActionID: z.string().describe(`
|
|
5633
5633
|
* * Field Name: EntityActionID
|
|
5634
|
-
* * Display Name: Entity Action
|
|
5634
|
+
* * Display Name: Entity Action ID
|
|
5635
5635
|
* * SQL Data Type: uniqueidentifier
|
|
5636
5636
|
* * Related Entity/Foreign Key: Entity Actions (vwEntityActions.ID)`),
|
|
5637
5637
|
ActionFilterID: z.string().describe(`
|
|
5638
5638
|
* * Field Name: ActionFilterID
|
|
5639
|
-
* * Display Name: Action Filter
|
|
5639
|
+
* * Display Name: Action Filter ID
|
|
5640
5640
|
* * SQL Data Type: uniqueidentifier
|
|
5641
5641
|
* * Related Entity/Foreign Key: Action Filters (vwActionFilters.ID)`),
|
|
5642
5642
|
Sequence: z.number().describe(`
|
|
@@ -5721,12 +5721,12 @@ export const EntityActionInvocationSchema = z.object({
|
|
|
5721
5721
|
* * Default Value: newsequentialid()`),
|
|
5722
5722
|
EntityActionID: z.string().describe(`
|
|
5723
5723
|
* * Field Name: EntityActionID
|
|
5724
|
-
* * Display Name: Entity Action
|
|
5724
|
+
* * Display Name: Entity Action ID
|
|
5725
5725
|
* * SQL Data Type: uniqueidentifier
|
|
5726
5726
|
* * Related Entity/Foreign Key: Entity Actions (vwEntityActions.ID)`),
|
|
5727
5727
|
InvocationTypeID: z.string().describe(`
|
|
5728
5728
|
* * Field Name: InvocationTypeID
|
|
5729
|
-
* * Display Name: Invocation Type
|
|
5729
|
+
* * Display Name: Invocation Type ID
|
|
5730
5730
|
* * SQL Data Type: uniqueidentifier
|
|
5731
5731
|
* * Related Entity/Foreign Key: Entity Action Invocation Types (vwEntityActionInvocationTypes.ID)`),
|
|
5732
5732
|
Status: z.union([z.literal('Active'), z.literal('Disabled'), z.literal('Pending')]).describe(`
|
|
@@ -5752,11 +5752,11 @@ export const EntityActionInvocationSchema = z.object({
|
|
|
5752
5752
|
* * Default Value: getutcdate()`),
|
|
5753
5753
|
EntityAction: z.string().describe(`
|
|
5754
5754
|
* * Field Name: EntityAction
|
|
5755
|
-
* * Display Name: Action
|
|
5755
|
+
* * Display Name: Entity Action
|
|
5756
5756
|
* * SQL Data Type: nvarchar(425)`),
|
|
5757
5757
|
InvocationType: z.string().describe(`
|
|
5758
5758
|
* * Field Name: InvocationType
|
|
5759
|
-
* * Display Name: Invocation Type
|
|
5759
|
+
* * Display Name: Invocation Type
|
|
5760
5760
|
* * SQL Data Type: nvarchar(255)`),
|
|
5761
5761
|
});
|
|
5762
5762
|
/**
|
|
@@ -5815,7 +5815,7 @@ export const EntityActionParamSchema = z.object({
|
|
|
5815
5815
|
* * SQL Data Type: nvarchar(425)`),
|
|
5816
5816
|
ActionParam: z.string().describe(`
|
|
5817
5817
|
* * Field Name: ActionParam
|
|
5818
|
-
* * Display Name:
|
|
5818
|
+
* * Display Name: Parameter Name
|
|
5819
5819
|
* * SQL Data Type: nvarchar(255)`),
|
|
5820
5820
|
});
|
|
5821
5821
|
/**
|
|
@@ -6008,7 +6008,7 @@ export const EntityCommunicationFieldSchema = z.object({
|
|
|
6008
6008
|
* * Default Value: getutcdate()`),
|
|
6009
6009
|
EntityCommunicationMessageType: z.string().describe(`
|
|
6010
6010
|
* * Field Name: EntityCommunicationMessageType
|
|
6011
|
-
* * Display Name: Message Type
|
|
6011
|
+
* * Display Name: Entity Communication Message Type
|
|
6012
6012
|
* * SQL Data Type: nvarchar(100)`),
|
|
6013
6013
|
});
|
|
6014
6014
|
/**
|
|
@@ -7194,12 +7194,12 @@ export const ErrorLogSchema = z.object({
|
|
|
7194
7194
|
* * Related Entity/Foreign Key: Company Integration Run Details (vwCompanyIntegrationRunDetails.ID)`),
|
|
7195
7195
|
Code: z.string().nullable().describe(`
|
|
7196
7196
|
* * Field Name: Code
|
|
7197
|
-
* * Display Name: Code
|
|
7197
|
+
* * Display Name: Error Code
|
|
7198
7198
|
* * SQL Data Type: nchar(20)
|
|
7199
7199
|
* * Description: Error code for categorizing and handling specific error types.`),
|
|
7200
7200
|
Message: z.string().nullable().describe(`
|
|
7201
7201
|
* * Field Name: Message
|
|
7202
|
-
* * Display Name: Message
|
|
7202
|
+
* * Display Name: Error Message
|
|
7203
7203
|
* * SQL Data Type: nvarchar(MAX)
|
|
7204
7204
|
* * Description: The primary error message describing what went wrong.`),
|
|
7205
7205
|
CreatedBy: z.string().nullable().describe(`
|
|
@@ -7210,16 +7210,16 @@ export const ErrorLogSchema = z.object({
|
|
|
7210
7210
|
* * Description: User or system process that encountered this error.`),
|
|
7211
7211
|
Status: z.string().nullable().describe(`
|
|
7212
7212
|
* * Field Name: Status
|
|
7213
|
-
* * Display Name: Status
|
|
7213
|
+
* * Display Name: Error Status
|
|
7214
7214
|
* * SQL Data Type: nvarchar(10)`),
|
|
7215
7215
|
Category: z.string().nullable().describe(`
|
|
7216
7216
|
* * Field Name: Category
|
|
7217
|
-
* * Display Name: Category
|
|
7217
|
+
* * Display Name: Error Category
|
|
7218
7218
|
* * SQL Data Type: nvarchar(20)
|
|
7219
7219
|
* * Description: High-level category for grouping related errors (Database, API, Validation, etc.).`),
|
|
7220
7220
|
Details: z.string().nullable().describe(`
|
|
7221
7221
|
* * Field Name: Details
|
|
7222
|
-
* * Display Name: Details
|
|
7222
|
+
* * Display Name: Error Details
|
|
7223
7223
|
* * SQL Data Type: nvarchar(MAX)
|
|
7224
7224
|
* * Description: Full error details including stack trace, inner exceptions, and context data.`),
|
|
7225
7225
|
__mj_CreatedAt: z.date().describe(`
|
|
@@ -7234,11 +7234,11 @@ export const ErrorLogSchema = z.object({
|
|
|
7234
7234
|
* * Default Value: getutcdate()`),
|
|
7235
7235
|
CompanyIntegrationRun: z.string().nullable().describe(`
|
|
7236
7236
|
* * Field Name: CompanyIntegrationRun
|
|
7237
|
-
* * Display Name: Integration Run
|
|
7237
|
+
* * Display Name: Company Integration Run
|
|
7238
7238
|
* * SQL Data Type: nvarchar(100)`),
|
|
7239
7239
|
CompanyIntegrationRunDetail: z.string().nullable().describe(`
|
|
7240
7240
|
* * Field Name: CompanyIntegrationRunDetail
|
|
7241
|
-
* * Display Name: Integration Run Detail
|
|
7241
|
+
* * Display Name: Company Integration Run Detail
|
|
7242
7242
|
* * SQL Data Type: nvarchar(450)`),
|
|
7243
7243
|
});
|
|
7244
7244
|
/**
|
|
@@ -7691,6 +7691,7 @@ export const IntegrationURLFormatSchema = z.object({
|
|
|
7691
7691
|
* * Related Entity/Foreign Key: Entities (vwEntities.ID)`),
|
|
7692
7692
|
URLFormat: z.string().describe(`
|
|
7693
7693
|
* * Field Name: URLFormat
|
|
7694
|
+
* * Display Name: URL Format
|
|
7694
7695
|
* * SQL Data Type: nvarchar(500)
|
|
7695
7696
|
* * Description: The URL Format for the given integration including the ability to include markup with fields from the integration`),
|
|
7696
7697
|
Comments: z.string().nullable().describe(`
|
|
@@ -9148,7 +9149,7 @@ permanently, Warn means validation failed but execution continues.`),
|
|
|
9148
9149
|
detailed information about what validation rules failed.`),
|
|
9149
9150
|
ParentID: z.string().nullable().describe(`
|
|
9150
9151
|
* * Field Name: ParentID
|
|
9151
|
-
* * Display Name: Parent
|
|
9152
|
+
* * Display Name: Parent ID
|
|
9152
9153
|
* * SQL Data Type: uniqueidentifier
|
|
9153
9154
|
* * Related Entity/Foreign Key: MJ: AI Agent Run Steps (vwAIAgentRunSteps.ID)
|
|
9154
9155
|
* * Description: Optional reference to parent step for tracking hierarchical relationships like code->test->fix->code cycles`),
|
|
@@ -13111,7 +13112,7 @@ export const ConversationDetailArtifactSchema = z.object({
|
|
|
13111
13112
|
* * Default Value: getutcdate()`),
|
|
13112
13113
|
ConversationDetail: z.string().describe(`
|
|
13113
13114
|
* * Field Name: ConversationDetail
|
|
13114
|
-
* * Display Name:
|
|
13115
|
+
* * Display Name: Conversation Detail
|
|
13115
13116
|
* * SQL Data Type: nvarchar(MAX)`),
|
|
13116
13117
|
ArtifactVersion: z.string().nullable().describe(`
|
|
13117
13118
|
* * Field Name: ArtifactVersion
|
|
@@ -13261,7 +13262,7 @@ export const ConversationDetailRatingSchema = z.object({
|
|
|
13261
13262
|
* * Default Value: getutcdate()`),
|
|
13262
13263
|
ConversationDetail: z.string().describe(`
|
|
13263
13264
|
* * Field Name: ConversationDetail
|
|
13264
|
-
* * Display Name:
|
|
13265
|
+
* * Display Name: Message Text
|
|
13265
13266
|
* * SQL Data Type: nvarchar(MAX)`),
|
|
13266
13267
|
User: z.string().describe(`
|
|
13267
13268
|
* * Field Name: User
|
|
@@ -14397,11 +14398,11 @@ export const MCPServerConnectionToolSchema = z.object({
|
|
|
14397
14398
|
* * Default Value: getutcdate()`),
|
|
14398
14399
|
MCPServerConnection: z.string().describe(`
|
|
14399
14400
|
* * Field Name: MCPServerConnection
|
|
14400
|
-
* * Display Name: Connection
|
|
14401
|
+
* * Display Name: Server Connection
|
|
14401
14402
|
* * SQL Data Type: nvarchar(255)`),
|
|
14402
14403
|
MCPServerTool: z.string().nullable().describe(`
|
|
14403
14404
|
* * Field Name: MCPServerTool
|
|
14404
|
-
* * Display Name: Tool
|
|
14405
|
+
* * Display Name: Server Tool
|
|
14405
14406
|
* * SQL Data Type: nvarchar(255)`),
|
|
14406
14407
|
});
|
|
14407
14408
|
/**
|
|
@@ -14757,12 +14758,12 @@ export const MCPToolExecutionLogSchema = z.object({
|
|
|
14757
14758
|
* * Default Value: newsequentialid()`),
|
|
14758
14759
|
MCPServerConnectionID: z.string().describe(`
|
|
14759
14760
|
* * Field Name: MCPServerConnectionID
|
|
14760
|
-
* * Display Name: MCP Server Connection
|
|
14761
|
+
* * Display Name: MCP Server Connection
|
|
14761
14762
|
* * SQL Data Type: uniqueidentifier
|
|
14762
14763
|
* * Related Entity/Foreign Key: MJ: MCP Server Connections (vwMCPServerConnections.ID)`),
|
|
14763
14764
|
MCPServerToolID: z.string().nullable().describe(`
|
|
14764
14765
|
* * Field Name: MCPServerToolID
|
|
14765
|
-
* * Display Name: MCP Server Tool
|
|
14766
|
+
* * Display Name: MCP Server Tool
|
|
14766
14767
|
* * SQL Data Type: uniqueidentifier
|
|
14767
14768
|
* * Related Entity/Foreign Key: MJ: MCP Server Tools (vwMCPServerTools.ID)
|
|
14768
14769
|
* * Description: FK to MCP Server Tool (null if tool not cached)`),
|
|
@@ -18068,12 +18069,12 @@ export const RecommendationItemSchema = z.object({
|
|
|
18068
18069
|
* * Related Entity/Foreign Key: Recommendations (vwRecommendations.ID)`),
|
|
18069
18070
|
DestinationEntityID: z.string().describe(`
|
|
18070
18071
|
* * Field Name: DestinationEntityID
|
|
18071
|
-
* * Display Name: Destination Entity
|
|
18072
|
+
* * Display Name: Destination Entity
|
|
18072
18073
|
* * SQL Data Type: uniqueidentifier
|
|
18073
18074
|
* * Related Entity/Foreign Key: Entities (vwEntities.ID)`),
|
|
18074
18075
|
DestinationEntityRecordID: z.string().describe(`
|
|
18075
18076
|
* * Field Name: DestinationEntityRecordID
|
|
18076
|
-
* * Display Name: Destination
|
|
18077
|
+
* * Display Name: Destination Record ID
|
|
18077
18078
|
* * SQL Data Type: nvarchar(450)
|
|
18078
18079
|
* * Description: The record ID of the destination entity`),
|
|
18079
18080
|
MatchProbability: z.number().nullable().describe(`
|
|
@@ -18203,7 +18204,7 @@ export const RecommendationSchema = z.object({
|
|
|
18203
18204
|
* * Default Value: newsequentialid()`),
|
|
18204
18205
|
RecommendationRunID: z.string().describe(`
|
|
18205
18206
|
* * Field Name: RecommendationRunID
|
|
18206
|
-
* * Display Name: Recommendation Run
|
|
18207
|
+
* * Display Name: Recommendation Run ID
|
|
18207
18208
|
* * SQL Data Type: uniqueidentifier
|
|
18208
18209
|
* * Related Entity/Foreign Key: Recommendation Runs (vwRecommendationRuns.ID)`),
|
|
18209
18210
|
SourceEntityID: z.string().describe(`
|
|
@@ -18422,12 +18423,12 @@ export const RecordMergeDeletionLogSchema = z.object({
|
|
|
18422
18423
|
* * Default Value: newsequentialid()`),
|
|
18423
18424
|
RecordMergeLogID: z.string().describe(`
|
|
18424
18425
|
* * Field Name: RecordMergeLogID
|
|
18425
|
-
* * Display Name: Record Merge Log
|
|
18426
|
+
* * Display Name: Record Merge Log ID
|
|
18426
18427
|
* * SQL Data Type: uniqueidentifier
|
|
18427
18428
|
* * Related Entity/Foreign Key: Record Merge Logs (vwRecordMergeLogs.ID)`),
|
|
18428
18429
|
DeletedRecordID: z.string().describe(`
|
|
18429
18430
|
* * Field Name: DeletedRecordID
|
|
18430
|
-
* * Display Name: Deleted Record
|
|
18431
|
+
* * Display Name: Deleted Record ID
|
|
18431
18432
|
* * SQL Data Type: nvarchar(750)
|
|
18432
18433
|
* * Description: Field DeletedRecordID for entity Record Merge Deletion Logs.`),
|
|
18433
18434
|
Status: z.union([z.literal('Complete'), z.literal('Error'), z.literal('Pending')]).describe(`
|
|
@@ -18457,7 +18458,7 @@ export const RecordMergeDeletionLogSchema = z.object({
|
|
|
18457
18458
|
* * Default Value: getutcdate()`),
|
|
18458
18459
|
RecordMergeLog: z.string().describe(`
|
|
18459
18460
|
* * Field Name: RecordMergeLog
|
|
18460
|
-
* * Display Name: Merge Log
|
|
18461
|
+
* * Display Name: Record Merge Log
|
|
18461
18462
|
* * SQL Data Type: nvarchar(450)`),
|
|
18462
18463
|
});
|
|
18463
18464
|
/**
|
|
@@ -19027,6 +19028,7 @@ export const RoleSchema = z.object({
|
|
|
19027
19028
|
* * Description: The unique ID of the role in the directory being used for authentication, for example an ID in Azure.`),
|
|
19028
19029
|
SQLName: z.string().nullable().describe(`
|
|
19029
19030
|
* * Field Name: SQLName
|
|
19031
|
+
* * Display Name: SQL Name
|
|
19030
19032
|
* * SQL Data Type: nvarchar(250)
|
|
19031
19033
|
* * Description: The name of the role in the database, this is used for auto-generating permission statements by CodeGen`),
|
|
19032
19034
|
__mj_CreatedAt: z.date().describe(`
|
|
@@ -19250,12 +19252,12 @@ export const SchemaInfoSchema = z.object({
|
|
|
19250
19252
|
* * Description: The database schema this information applies to.`),
|
|
19251
19253
|
EntityIDMin: z.number().describe(`
|
|
19252
19254
|
* * Field Name: EntityIDMin
|
|
19253
|
-
* * Display Name: Entity
|
|
19255
|
+
* * Display Name: Entity ID Minimum
|
|
19254
19256
|
* * SQL Data Type: int
|
|
19255
19257
|
* * Description: Field EntityIDMin for entity Schema Info.`),
|
|
19256
19258
|
EntityIDMax: z.number().describe(`
|
|
19257
19259
|
* * Field Name: EntityIDMax
|
|
19258
|
-
* * Display Name: Entity
|
|
19260
|
+
* * Display Name: Entity ID Maximum
|
|
19259
19261
|
* * SQL Data Type: int
|
|
19260
19262
|
* * Description: Field EntityIDMax for entity Schema Info.`),
|
|
19261
19263
|
Comments: z.string().nullable().describe(`
|
|
@@ -19276,6 +19278,16 @@ export const SchemaInfoSchema = z.object({
|
|
|
19276
19278
|
* * Field Name: Description
|
|
19277
19279
|
* * Display Name: Description
|
|
19278
19280
|
* * SQL Data Type: nvarchar(MAX)`),
|
|
19281
|
+
EntityNamePrefix: z.string().nullable().describe(`
|
|
19282
|
+
* * Field Name: EntityNamePrefix
|
|
19283
|
+
* * Display Name: Entity Name Prefix
|
|
19284
|
+
* * SQL Data Type: nvarchar(25)
|
|
19285
|
+
* * Description: Optional prefix to prepend to entity names generated for this schema. For example, setting this to "Committees: " would result in entity names like "Committees: Individuals". Can be overridden by mj.config.cjs NameRulesBySchema settings.`),
|
|
19286
|
+
EntityNameSuffix: z.string().nullable().describe(`
|
|
19287
|
+
* * Field Name: EntityNameSuffix
|
|
19288
|
+
* * Display Name: Entity Name Suffix
|
|
19289
|
+
* * SQL Data Type: nvarchar(25)
|
|
19290
|
+
* * Description: Optional suffix to append to entity names generated for this schema. Can be overridden by mj.config.cjs NameRulesBySchema settings.`),
|
|
19279
19291
|
});
|
|
19280
19292
|
/**
|
|
19281
19293
|
* zod schema definition for the entity Skills
|
|
@@ -19597,7 +19609,7 @@ export const TemplateParamSchema = z.object({
|
|
|
19597
19609
|
* * Description: Default value of the parameter`),
|
|
19598
19610
|
IsRequired: z.boolean().describe(`
|
|
19599
19611
|
* * Field Name: IsRequired
|
|
19600
|
-
* * Display Name:
|
|
19612
|
+
* * Display Name: Required
|
|
19601
19613
|
* * SQL Data Type: bit
|
|
19602
19614
|
* * Default Value: 0
|
|
19603
19615
|
* * Description: Whether this parameter must be provided when using the template.`),
|
|
@@ -22092,6 +22104,41 @@ let ActionEntity = class ActionEntity extends BaseEntity {
|
|
|
22092
22104
|
return await super.InnerLoad(compositeKey, EntityRelationshipsToLoad);
|
|
22093
22105
|
}
|
|
22094
22106
|
/**
|
|
22107
|
+
* Actions - Delete method override to wrap in transaction since CascadeDeletes is true.
|
|
22108
|
+
* Wrapping in a transaction ensures that all cascade delete operations are handled atomically.
|
|
22109
|
+
* @public
|
|
22110
|
+
* @method
|
|
22111
|
+
* @override
|
|
22112
|
+
* @memberof ActionEntity
|
|
22113
|
+
* @returns {Promise<boolean>} - true if successful, false otherwise
|
|
22114
|
+
*/
|
|
22115
|
+
async Delete(options) {
|
|
22116
|
+
if (Metadata.Provider.ProviderType === ProviderType.Database) {
|
|
22117
|
+
// For database providers, use the transaction methods directly
|
|
22118
|
+
const provider = Metadata.Provider;
|
|
22119
|
+
try {
|
|
22120
|
+
await provider.BeginTransaction();
|
|
22121
|
+
const result = await super.Delete(options);
|
|
22122
|
+
if (result) {
|
|
22123
|
+
await provider.CommitTransaction();
|
|
22124
|
+
return true;
|
|
22125
|
+
}
|
|
22126
|
+
else {
|
|
22127
|
+
await provider.RollbackTransaction();
|
|
22128
|
+
return false;
|
|
22129
|
+
}
|
|
22130
|
+
}
|
|
22131
|
+
catch (error) {
|
|
22132
|
+
await provider.RollbackTransaction();
|
|
22133
|
+
throw error;
|
|
22134
|
+
}
|
|
22135
|
+
}
|
|
22136
|
+
else {
|
|
22137
|
+
// For network providers, cascading deletes are handled server-side
|
|
22138
|
+
return super.Delete(options);
|
|
22139
|
+
}
|
|
22140
|
+
}
|
|
22141
|
+
/**
|
|
22095
22142
|
* * Field Name: ID
|
|
22096
22143
|
* * Display Name: ID
|
|
22097
22144
|
* * SQL Data Type: uniqueidentifier
|
|
@@ -23932,6 +23979,41 @@ let AIAgentEntity = class AIAgentEntity extends BaseEntity {
|
|
|
23932
23979
|
return await super.InnerLoad(compositeKey, EntityRelationshipsToLoad);
|
|
23933
23980
|
}
|
|
23934
23981
|
/**
|
|
23982
|
+
* AI Agents - Delete method override to wrap in transaction since CascadeDeletes is true.
|
|
23983
|
+
* Wrapping in a transaction ensures that all cascade delete operations are handled atomically.
|
|
23984
|
+
* @public
|
|
23985
|
+
* @method
|
|
23986
|
+
* @override
|
|
23987
|
+
* @memberof AIAgentEntity
|
|
23988
|
+
* @returns {Promise<boolean>} - true if successful, false otherwise
|
|
23989
|
+
*/
|
|
23990
|
+
async Delete(options) {
|
|
23991
|
+
if (Metadata.Provider.ProviderType === ProviderType.Database) {
|
|
23992
|
+
// For database providers, use the transaction methods directly
|
|
23993
|
+
const provider = Metadata.Provider;
|
|
23994
|
+
try {
|
|
23995
|
+
await provider.BeginTransaction();
|
|
23996
|
+
const result = await super.Delete(options);
|
|
23997
|
+
if (result) {
|
|
23998
|
+
await provider.CommitTransaction();
|
|
23999
|
+
return true;
|
|
24000
|
+
}
|
|
24001
|
+
else {
|
|
24002
|
+
await provider.RollbackTransaction();
|
|
24003
|
+
return false;
|
|
24004
|
+
}
|
|
24005
|
+
}
|
|
24006
|
+
catch (error) {
|
|
24007
|
+
await provider.RollbackTransaction();
|
|
24008
|
+
throw error;
|
|
24009
|
+
}
|
|
24010
|
+
}
|
|
24011
|
+
else {
|
|
24012
|
+
// For network providers, cascading deletes are handled server-side
|
|
24013
|
+
return super.Delete(options);
|
|
24014
|
+
}
|
|
24015
|
+
}
|
|
24016
|
+
/**
|
|
23935
24017
|
* Validate() method override for AI Agents entity. This is an auto-generated method that invokes the generated validators for this entity for the following fields:
|
|
23936
24018
|
* * DefaultPromptEffortLevel: This rule ensures that if a default prompt effort level is specified, it must be a number between 1 and 100, inclusive.
|
|
23937
24019
|
* * MaxExecutionsPerRun: This rule ensures that if 'MaxExecutionsPerRun' is provided, it must be a value greater than zero. If it is left blank, that's acceptable.
|
|
@@ -25715,6 +25797,41 @@ let AIPromptEntity = class AIPromptEntity extends BaseEntity {
|
|
|
25715
25797
|
return await super.InnerLoad(compositeKey, EntityRelationshipsToLoad);
|
|
25716
25798
|
}
|
|
25717
25799
|
/**
|
|
25800
|
+
* AI Prompts - Delete method override to wrap in transaction since CascadeDeletes is true.
|
|
25801
|
+
* Wrapping in a transaction ensures that all cascade delete operations are handled atomically.
|
|
25802
|
+
* @public
|
|
25803
|
+
* @method
|
|
25804
|
+
* @override
|
|
25805
|
+
* @memberof AIPromptEntity
|
|
25806
|
+
* @returns {Promise<boolean>} - true if successful, false otherwise
|
|
25807
|
+
*/
|
|
25808
|
+
async Delete(options) {
|
|
25809
|
+
if (Metadata.Provider.ProviderType === ProviderType.Database) {
|
|
25810
|
+
// For database providers, use the transaction methods directly
|
|
25811
|
+
const provider = Metadata.Provider;
|
|
25812
|
+
try {
|
|
25813
|
+
await provider.BeginTransaction();
|
|
25814
|
+
const result = await super.Delete(options);
|
|
25815
|
+
if (result) {
|
|
25816
|
+
await provider.CommitTransaction();
|
|
25817
|
+
return true;
|
|
25818
|
+
}
|
|
25819
|
+
else {
|
|
25820
|
+
await provider.RollbackTransaction();
|
|
25821
|
+
return false;
|
|
25822
|
+
}
|
|
25823
|
+
}
|
|
25824
|
+
catch (error) {
|
|
25825
|
+
await provider.RollbackTransaction();
|
|
25826
|
+
throw error;
|
|
25827
|
+
}
|
|
25828
|
+
}
|
|
25829
|
+
else {
|
|
25830
|
+
// For network providers, cascading deletes are handled server-side
|
|
25831
|
+
return super.Delete(options);
|
|
25832
|
+
}
|
|
25833
|
+
}
|
|
25834
|
+
/**
|
|
25718
25835
|
* Validate() method override for AI Prompts entity. This is an auto-generated method that invokes the generated validators for this entity for the following fields:
|
|
25719
25836
|
* * CacheSimilarityThreshold: This rule ensures that the "CacheSimilarityThreshold" value, if provided, must be between 0 and 1 (including both 0 and 1). If it is not set, there is no restriction.
|
|
25720
25837
|
* * CacheTTLSeconds: This rule ensures that if a cache time-to-live (CacheTTLSeconds) value is provided, it must be greater than zero. If it is not set, that's allowed.
|
|
@@ -33240,7 +33357,7 @@ let DuplicateRunDetailEntity = class DuplicateRunDetailEntity extends BaseEntity
|
|
|
33240
33357
|
}
|
|
33241
33358
|
/**
|
|
33242
33359
|
* * Field Name: DuplicateRunID
|
|
33243
|
-
* * Display Name: Duplicate Run
|
|
33360
|
+
* * Display Name: Duplicate Run
|
|
33244
33361
|
* * SQL Data Type: uniqueidentifier
|
|
33245
33362
|
* * Related Entity/Foreign Key: Duplicate Runs (vwDuplicateRuns.ID)
|
|
33246
33363
|
*/
|
|
@@ -33879,7 +33996,7 @@ let EmployeeSkillEntity = class EmployeeSkillEntity extends BaseEntity {
|
|
|
33879
33996
|
}
|
|
33880
33997
|
/**
|
|
33881
33998
|
* * Field Name: SkillID
|
|
33882
|
-
* * Display Name: Skill
|
|
33999
|
+
* * Display Name: Skill
|
|
33883
34000
|
* * SQL Data Type: uniqueidentifier
|
|
33884
34001
|
* * Related Entity/Foreign Key: Skills (vwSkills.ID)
|
|
33885
34002
|
*/
|
|
@@ -33917,7 +34034,7 @@ let EmployeeSkillEntity = class EmployeeSkillEntity extends BaseEntity {
|
|
|
33917
34034
|
}
|
|
33918
34035
|
/**
|
|
33919
34036
|
* * Field Name: Skill
|
|
33920
|
-
* * Display Name: Skill
|
|
34037
|
+
* * Display Name: Skill Name
|
|
33921
34038
|
* * SQL Data Type: nvarchar(50)
|
|
33922
34039
|
*/
|
|
33923
34040
|
get Skill() {
|
|
@@ -35001,7 +35118,7 @@ let EntityActionFilterEntity = class EntityActionFilterEntity extends BaseEntity
|
|
|
35001
35118
|
}
|
|
35002
35119
|
/**
|
|
35003
35120
|
* * Field Name: EntityActionID
|
|
35004
|
-
* * Display Name: Entity Action
|
|
35121
|
+
* * Display Name: Entity Action ID
|
|
35005
35122
|
* * SQL Data Type: uniqueidentifier
|
|
35006
35123
|
* * Related Entity/Foreign Key: Entity Actions (vwEntityActions.ID)
|
|
35007
35124
|
*/
|
|
@@ -35013,7 +35130,7 @@ let EntityActionFilterEntity = class EntityActionFilterEntity extends BaseEntity
|
|
|
35013
35130
|
}
|
|
35014
35131
|
/**
|
|
35015
35132
|
* * Field Name: ActionFilterID
|
|
35016
|
-
* * Display Name: Action Filter
|
|
35133
|
+
* * Display Name: Action Filter ID
|
|
35017
35134
|
* * SQL Data Type: uniqueidentifier
|
|
35018
35135
|
* * Related Entity/Foreign Key: Action Filters (vwActionFilters.ID)
|
|
35019
35136
|
*/
|
|
@@ -35234,7 +35351,7 @@ let EntityActionInvocationEntity = class EntityActionInvocationEntity extends Ba
|
|
|
35234
35351
|
}
|
|
35235
35352
|
/**
|
|
35236
35353
|
* * Field Name: EntityActionID
|
|
35237
|
-
* * Display Name: Entity Action
|
|
35354
|
+
* * Display Name: Entity Action ID
|
|
35238
35355
|
* * SQL Data Type: uniqueidentifier
|
|
35239
35356
|
* * Related Entity/Foreign Key: Entity Actions (vwEntityActions.ID)
|
|
35240
35357
|
*/
|
|
@@ -35246,7 +35363,7 @@ let EntityActionInvocationEntity = class EntityActionInvocationEntity extends Ba
|
|
|
35246
35363
|
}
|
|
35247
35364
|
/**
|
|
35248
35365
|
* * Field Name: InvocationTypeID
|
|
35249
|
-
* * Display Name: Invocation Type
|
|
35366
|
+
* * Display Name: Invocation Type ID
|
|
35250
35367
|
* * SQL Data Type: uniqueidentifier
|
|
35251
35368
|
* * Related Entity/Foreign Key: Entity Action Invocation Types (vwEntityActionInvocationTypes.ID)
|
|
35252
35369
|
*/
|
|
@@ -35294,7 +35411,7 @@ let EntityActionInvocationEntity = class EntityActionInvocationEntity extends Ba
|
|
|
35294
35411
|
}
|
|
35295
35412
|
/**
|
|
35296
35413
|
* * Field Name: EntityAction
|
|
35297
|
-
* * Display Name: Action
|
|
35414
|
+
* * Display Name: Entity Action
|
|
35298
35415
|
* * SQL Data Type: nvarchar(425)
|
|
35299
35416
|
*/
|
|
35300
35417
|
get EntityAction() {
|
|
@@ -35302,7 +35419,7 @@ let EntityActionInvocationEntity = class EntityActionInvocationEntity extends Ba
|
|
|
35302
35419
|
}
|
|
35303
35420
|
/**
|
|
35304
35421
|
* * Field Name: InvocationType
|
|
35305
|
-
* * Display Name: Invocation Type
|
|
35422
|
+
* * Display Name: Invocation Type
|
|
35306
35423
|
* * SQL Data Type: nvarchar(255)
|
|
35307
35424
|
*/
|
|
35308
35425
|
get InvocationType() {
|
|
@@ -35447,7 +35564,7 @@ let EntityActionParamEntity = class EntityActionParamEntity extends BaseEntity {
|
|
|
35447
35564
|
}
|
|
35448
35565
|
/**
|
|
35449
35566
|
* * Field Name: ActionParam
|
|
35450
|
-
* * Display Name:
|
|
35567
|
+
* * Display Name: Parameter Name
|
|
35451
35568
|
* * SQL Data Type: nvarchar(255)
|
|
35452
35569
|
*/
|
|
35453
35570
|
get ActionParam() {
|
|
@@ -35924,7 +36041,7 @@ let EntityCommunicationFieldEntity = class EntityCommunicationFieldEntity extend
|
|
|
35924
36041
|
}
|
|
35925
36042
|
/**
|
|
35926
36043
|
* * Field Name: EntityCommunicationMessageType
|
|
35927
|
-
* * Display Name: Message Type
|
|
36044
|
+
* * Display Name: Entity Communication Message Type
|
|
35928
36045
|
* * SQL Data Type: nvarchar(100)
|
|
35929
36046
|
*/
|
|
35930
36047
|
get EntityCommunicationMessageType() {
|
|
@@ -38746,7 +38863,7 @@ let ErrorLogEntity = class ErrorLogEntity extends BaseEntity {
|
|
|
38746
38863
|
}
|
|
38747
38864
|
/**
|
|
38748
38865
|
* * Field Name: Code
|
|
38749
|
-
* * Display Name: Code
|
|
38866
|
+
* * Display Name: Error Code
|
|
38750
38867
|
* * SQL Data Type: nchar(20)
|
|
38751
38868
|
* * Description: Error code for categorizing and handling specific error types.
|
|
38752
38869
|
*/
|
|
@@ -38758,7 +38875,7 @@ let ErrorLogEntity = class ErrorLogEntity extends BaseEntity {
|
|
|
38758
38875
|
}
|
|
38759
38876
|
/**
|
|
38760
38877
|
* * Field Name: Message
|
|
38761
|
-
* * Display Name: Message
|
|
38878
|
+
* * Display Name: Error Message
|
|
38762
38879
|
* * SQL Data Type: nvarchar(MAX)
|
|
38763
38880
|
* * Description: The primary error message describing what went wrong.
|
|
38764
38881
|
*/
|
|
@@ -38783,7 +38900,7 @@ let ErrorLogEntity = class ErrorLogEntity extends BaseEntity {
|
|
|
38783
38900
|
}
|
|
38784
38901
|
/**
|
|
38785
38902
|
* * Field Name: Status
|
|
38786
|
-
* * Display Name: Status
|
|
38903
|
+
* * Display Name: Error Status
|
|
38787
38904
|
* * SQL Data Type: nvarchar(10)
|
|
38788
38905
|
*/
|
|
38789
38906
|
get Status() {
|
|
@@ -38794,7 +38911,7 @@ let ErrorLogEntity = class ErrorLogEntity extends BaseEntity {
|
|
|
38794
38911
|
}
|
|
38795
38912
|
/**
|
|
38796
38913
|
* * Field Name: Category
|
|
38797
|
-
* * Display Name: Category
|
|
38914
|
+
* * Display Name: Error Category
|
|
38798
38915
|
* * SQL Data Type: nvarchar(20)
|
|
38799
38916
|
* * Description: High-level category for grouping related errors (Database, API, Validation, etc.).
|
|
38800
38917
|
*/
|
|
@@ -38806,7 +38923,7 @@ let ErrorLogEntity = class ErrorLogEntity extends BaseEntity {
|
|
|
38806
38923
|
}
|
|
38807
38924
|
/**
|
|
38808
38925
|
* * Field Name: Details
|
|
38809
|
-
* * Display Name: Details
|
|
38926
|
+
* * Display Name: Error Details
|
|
38810
38927
|
* * SQL Data Type: nvarchar(MAX)
|
|
38811
38928
|
* * Description: Full error details including stack trace, inner exceptions, and context data.
|
|
38812
38929
|
*/
|
|
@@ -38836,7 +38953,7 @@ let ErrorLogEntity = class ErrorLogEntity extends BaseEntity {
|
|
|
38836
38953
|
}
|
|
38837
38954
|
/**
|
|
38838
38955
|
* * Field Name: CompanyIntegrationRun
|
|
38839
|
-
* * Display Name: Integration Run
|
|
38956
|
+
* * Display Name: Company Integration Run
|
|
38840
38957
|
* * SQL Data Type: nvarchar(100)
|
|
38841
38958
|
*/
|
|
38842
38959
|
get CompanyIntegrationRun() {
|
|
@@ -38844,7 +38961,7 @@ let ErrorLogEntity = class ErrorLogEntity extends BaseEntity {
|
|
|
38844
38961
|
}
|
|
38845
38962
|
/**
|
|
38846
38963
|
* * Field Name: CompanyIntegrationRunDetail
|
|
38847
|
-
* * Display Name: Integration Run Detail
|
|
38964
|
+
* * Display Name: Company Integration Run Detail
|
|
38848
38965
|
* * SQL Data Type: nvarchar(450)
|
|
38849
38966
|
*/
|
|
38850
38967
|
get CompanyIntegrationRunDetail() {
|
|
@@ -40035,6 +40152,7 @@ let IntegrationURLFormatEntity = class IntegrationURLFormatEntity extends BaseEn
|
|
|
40035
40152
|
}
|
|
40036
40153
|
/**
|
|
40037
40154
|
* * Field Name: URLFormat
|
|
40155
|
+
* * Display Name: URL Format
|
|
40038
40156
|
* * SQL Data Type: nvarchar(500)
|
|
40039
40157
|
* * Description: The URL Format for the given integration including the ability to include markup with fields from the integration
|
|
40040
40158
|
*/
|
|
@@ -43369,6 +43487,41 @@ let AIAgentRunStepEntity = class AIAgentRunStepEntity extends BaseEntity {
|
|
|
43369
43487
|
return await super.InnerLoad(compositeKey, EntityRelationshipsToLoad);
|
|
43370
43488
|
}
|
|
43371
43489
|
/**
|
|
43490
|
+
* MJ: AI Agent Run Steps - Delete method override to wrap in transaction since CascadeDeletes is true.
|
|
43491
|
+
* Wrapping in a transaction ensures that all cascade delete operations are handled atomically.
|
|
43492
|
+
* @public
|
|
43493
|
+
* @method
|
|
43494
|
+
* @override
|
|
43495
|
+
* @memberof AIAgentRunStepEntity
|
|
43496
|
+
* @returns {Promise<boolean>} - true if successful, false otherwise
|
|
43497
|
+
*/
|
|
43498
|
+
async Delete(options) {
|
|
43499
|
+
if (Metadata.Provider.ProviderType === ProviderType.Database) {
|
|
43500
|
+
// For database providers, use the transaction methods directly
|
|
43501
|
+
const provider = Metadata.Provider;
|
|
43502
|
+
try {
|
|
43503
|
+
await provider.BeginTransaction();
|
|
43504
|
+
const result = await super.Delete(options);
|
|
43505
|
+
if (result) {
|
|
43506
|
+
await provider.CommitTransaction();
|
|
43507
|
+
return true;
|
|
43508
|
+
}
|
|
43509
|
+
else {
|
|
43510
|
+
await provider.RollbackTransaction();
|
|
43511
|
+
return false;
|
|
43512
|
+
}
|
|
43513
|
+
}
|
|
43514
|
+
catch (error) {
|
|
43515
|
+
await provider.RollbackTransaction();
|
|
43516
|
+
throw error;
|
|
43517
|
+
}
|
|
43518
|
+
}
|
|
43519
|
+
else {
|
|
43520
|
+
// For network providers, cascading deletes are handled server-side
|
|
43521
|
+
return super.Delete(options);
|
|
43522
|
+
}
|
|
43523
|
+
}
|
|
43524
|
+
/**
|
|
43372
43525
|
* Validate() method override for MJ: AI Agent Run Steps entity. This is an auto-generated method that invokes the generated validators for this entity for the following fields:
|
|
43373
43526
|
* * FinalPayloadValidationResult: The FinalPayloadValidationResult field can be empty, but if a value is set it must be one of the allowed outcomes: Warn, Fail, Retry, or Pass. This ensures that only valid validation results are stored.
|
|
43374
43527
|
* * StepNumber: This rule ensures that the step number must be greater than zero.
|
|
@@ -43680,7 +43833,7 @@ detailed information about what validation rules failed.
|
|
|
43680
43833
|
}
|
|
43681
43834
|
/**
|
|
43682
43835
|
* * Field Name: ParentID
|
|
43683
|
-
* * Display Name: Parent
|
|
43836
|
+
* * Display Name: Parent ID
|
|
43684
43837
|
* * SQL Data Type: uniqueidentifier
|
|
43685
43838
|
* * Related Entity/Foreign Key: MJ: AI Agent Run Steps (vwAIAgentRunSteps.ID)
|
|
43686
43839
|
* * Description: Optional reference to parent step for tracking hierarchical relationships like code->test->fix->code cycles
|
|
@@ -43761,6 +43914,41 @@ let AIAgentRunEntity = class AIAgentRunEntity extends BaseEntity {
|
|
|
43761
43914
|
return await super.InnerLoad(compositeKey, EntityRelationshipsToLoad);
|
|
43762
43915
|
}
|
|
43763
43916
|
/**
|
|
43917
|
+
* MJ: AI Agent Runs - Delete method override to wrap in transaction since CascadeDeletes is true.
|
|
43918
|
+
* Wrapping in a transaction ensures that all cascade delete operations are handled atomically.
|
|
43919
|
+
* @public
|
|
43920
|
+
* @method
|
|
43921
|
+
* @override
|
|
43922
|
+
* @memberof AIAgentRunEntity
|
|
43923
|
+
* @returns {Promise<boolean>} - true if successful, false otherwise
|
|
43924
|
+
*/
|
|
43925
|
+
async Delete(options) {
|
|
43926
|
+
if (Metadata.Provider.ProviderType === ProviderType.Database) {
|
|
43927
|
+
// For database providers, use the transaction methods directly
|
|
43928
|
+
const provider = Metadata.Provider;
|
|
43929
|
+
try {
|
|
43930
|
+
await provider.BeginTransaction();
|
|
43931
|
+
const result = await super.Delete(options);
|
|
43932
|
+
if (result) {
|
|
43933
|
+
await provider.CommitTransaction();
|
|
43934
|
+
return true;
|
|
43935
|
+
}
|
|
43936
|
+
else {
|
|
43937
|
+
await provider.RollbackTransaction();
|
|
43938
|
+
return false;
|
|
43939
|
+
}
|
|
43940
|
+
}
|
|
43941
|
+
catch (error) {
|
|
43942
|
+
await provider.RollbackTransaction();
|
|
43943
|
+
throw error;
|
|
43944
|
+
}
|
|
43945
|
+
}
|
|
43946
|
+
else {
|
|
43947
|
+
// For network providers, cascading deletes are handled server-side
|
|
43948
|
+
return super.Delete(options);
|
|
43949
|
+
}
|
|
43950
|
+
}
|
|
43951
|
+
/**
|
|
43764
43952
|
* Validate() method override for MJ: AI Agent Runs entity. This is an auto-generated method that invokes the generated validators for this entity for the following fields:
|
|
43765
43953
|
* * EffortLevel: This rule ensures that the effort level, if specified, must be a number between 1 and 100, inclusive.
|
|
43766
43954
|
* * FinalStep: The FinalStep field can be left empty, but if a value is provided it must be one of the approved step names – While, ForEach, Chat, Sub-Agent, Actions, Retry, Failed, or Success. This ensures only valid workflow steps are recorded.
|
|
@@ -44687,6 +44875,41 @@ let AIAgentStepEntity = class AIAgentStepEntity extends BaseEntity {
|
|
|
44687
44875
|
return await super.InnerLoad(compositeKey, EntityRelationshipsToLoad);
|
|
44688
44876
|
}
|
|
44689
44877
|
/**
|
|
44878
|
+
* MJ: AI Agent Steps - Delete method override to wrap in transaction since CascadeDeletes is true.
|
|
44879
|
+
* Wrapping in a transaction ensures that all cascade delete operations are handled atomically.
|
|
44880
|
+
* @public
|
|
44881
|
+
* @method
|
|
44882
|
+
* @override
|
|
44883
|
+
* @memberof AIAgentStepEntity
|
|
44884
|
+
* @returns {Promise<boolean>} - true if successful, false otherwise
|
|
44885
|
+
*/
|
|
44886
|
+
async Delete(options) {
|
|
44887
|
+
if (Metadata.Provider.ProviderType === ProviderType.Database) {
|
|
44888
|
+
// For database providers, use the transaction methods directly
|
|
44889
|
+
const provider = Metadata.Provider;
|
|
44890
|
+
try {
|
|
44891
|
+
await provider.BeginTransaction();
|
|
44892
|
+
const result = await super.Delete(options);
|
|
44893
|
+
if (result) {
|
|
44894
|
+
await provider.CommitTransaction();
|
|
44895
|
+
return true;
|
|
44896
|
+
}
|
|
44897
|
+
else {
|
|
44898
|
+
await provider.RollbackTransaction();
|
|
44899
|
+
return false;
|
|
44900
|
+
}
|
|
44901
|
+
}
|
|
44902
|
+
catch (error) {
|
|
44903
|
+
await provider.RollbackTransaction();
|
|
44904
|
+
throw error;
|
|
44905
|
+
}
|
|
44906
|
+
}
|
|
44907
|
+
else {
|
|
44908
|
+
// For network providers, cascading deletes are handled server-side
|
|
44909
|
+
return super.Delete(options);
|
|
44910
|
+
}
|
|
44911
|
+
}
|
|
44912
|
+
/**
|
|
44690
44913
|
* Validate() method override for MJ: AI Agent Steps entity. This is an auto-generated method that invokes the generated validators for this entity for the following fields:
|
|
44691
44914
|
* * RetryCount: This rule ensures that the number of retries allowed cannot be negative.
|
|
44692
44915
|
* * TimeoutSeconds: This rule ensures that, if provided, the timeout value must be greater than zero seconds.
|
|
@@ -45579,6 +45802,41 @@ let AIConfigurationEntity = class AIConfigurationEntity extends BaseEntity {
|
|
|
45579
45802
|
return await super.InnerLoad(compositeKey, EntityRelationshipsToLoad);
|
|
45580
45803
|
}
|
|
45581
45804
|
/**
|
|
45805
|
+
* MJ: AI Configurations - Delete method override to wrap in transaction since CascadeDeletes is true.
|
|
45806
|
+
* Wrapping in a transaction ensures that all cascade delete operations are handled atomically.
|
|
45807
|
+
* @public
|
|
45808
|
+
* @method
|
|
45809
|
+
* @override
|
|
45810
|
+
* @memberof AIConfigurationEntity
|
|
45811
|
+
* @returns {Promise<boolean>} - true if successful, false otherwise
|
|
45812
|
+
*/
|
|
45813
|
+
async Delete(options) {
|
|
45814
|
+
if (Metadata.Provider.ProviderType === ProviderType.Database) {
|
|
45815
|
+
// For database providers, use the transaction methods directly
|
|
45816
|
+
const provider = Metadata.Provider;
|
|
45817
|
+
try {
|
|
45818
|
+
await provider.BeginTransaction();
|
|
45819
|
+
const result = await super.Delete(options);
|
|
45820
|
+
if (result) {
|
|
45821
|
+
await provider.CommitTransaction();
|
|
45822
|
+
return true;
|
|
45823
|
+
}
|
|
45824
|
+
else {
|
|
45825
|
+
await provider.RollbackTransaction();
|
|
45826
|
+
return false;
|
|
45827
|
+
}
|
|
45828
|
+
}
|
|
45829
|
+
catch (error) {
|
|
45830
|
+
await provider.RollbackTransaction();
|
|
45831
|
+
throw error;
|
|
45832
|
+
}
|
|
45833
|
+
}
|
|
45834
|
+
else {
|
|
45835
|
+
// For network providers, cascading deletes are handled server-side
|
|
45836
|
+
return super.Delete(options);
|
|
45837
|
+
}
|
|
45838
|
+
}
|
|
45839
|
+
/**
|
|
45582
45840
|
* * Field Name: ID
|
|
45583
45841
|
* * Display Name: ID
|
|
45584
45842
|
* * SQL Data Type: uniqueidentifier
|
|
@@ -48069,6 +48327,41 @@ let AIPromptRunEntity = class AIPromptRunEntity extends BaseEntity {
|
|
|
48069
48327
|
return await super.InnerLoad(compositeKey, EntityRelationshipsToLoad);
|
|
48070
48328
|
}
|
|
48071
48329
|
/**
|
|
48330
|
+
* MJ: AI Prompt Runs - Delete method override to wrap in transaction since CascadeDeletes is true.
|
|
48331
|
+
* Wrapping in a transaction ensures that all cascade delete operations are handled atomically.
|
|
48332
|
+
* @public
|
|
48333
|
+
* @method
|
|
48334
|
+
* @override
|
|
48335
|
+
* @memberof AIPromptRunEntity
|
|
48336
|
+
* @returns {Promise<boolean>} - true if successful, false otherwise
|
|
48337
|
+
*/
|
|
48338
|
+
async Delete(options) {
|
|
48339
|
+
if (Metadata.Provider.ProviderType === ProviderType.Database) {
|
|
48340
|
+
// For database providers, use the transaction methods directly
|
|
48341
|
+
const provider = Metadata.Provider;
|
|
48342
|
+
try {
|
|
48343
|
+
await provider.BeginTransaction();
|
|
48344
|
+
const result = await super.Delete(options);
|
|
48345
|
+
if (result) {
|
|
48346
|
+
await provider.CommitTransaction();
|
|
48347
|
+
return true;
|
|
48348
|
+
}
|
|
48349
|
+
else {
|
|
48350
|
+
await provider.RollbackTransaction();
|
|
48351
|
+
return false;
|
|
48352
|
+
}
|
|
48353
|
+
}
|
|
48354
|
+
catch (error) {
|
|
48355
|
+
await provider.RollbackTransaction();
|
|
48356
|
+
throw error;
|
|
48357
|
+
}
|
|
48358
|
+
}
|
|
48359
|
+
else {
|
|
48360
|
+
// For network providers, cascading deletes are handled server-side
|
|
48361
|
+
return super.Delete(options);
|
|
48362
|
+
}
|
|
48363
|
+
}
|
|
48364
|
+
/**
|
|
48072
48365
|
* Validate() method override for MJ: AI Prompt Runs entity. This is an auto-generated method that invokes the generated validators for this entity for the following fields:
|
|
48073
48366
|
* * EffortLevel: This rule ensures that if an effort level is provided, it must be between 1 and 100, inclusive.
|
|
48074
48367
|
* * Table-Level: This rule ensures that if the 'CompletedAt' date is provided, it must be the same as or later than the 'RunAt' date. If 'CompletedAt' is not specified, there is no restriction.
|
|
@@ -53841,7 +54134,7 @@ let ConversationDetailArtifactEntity = class ConversationDetailArtifactEntity ex
|
|
|
53841
54134
|
}
|
|
53842
54135
|
/**
|
|
53843
54136
|
* * Field Name: ConversationDetail
|
|
53844
|
-
* * Display Name:
|
|
54137
|
+
* * Display Name: Conversation Detail
|
|
53845
54138
|
* * SQL Data Type: nvarchar(MAX)
|
|
53846
54139
|
*/
|
|
53847
54140
|
get ConversationDetail() {
|
|
@@ -54265,7 +54558,7 @@ let ConversationDetailRatingEntity = class ConversationDetailRatingEntity extend
|
|
|
54265
54558
|
}
|
|
54266
54559
|
/**
|
|
54267
54560
|
* * Field Name: ConversationDetail
|
|
54268
|
-
* * Display Name:
|
|
54561
|
+
* * Display Name: Message Text
|
|
54269
54562
|
* * SQL Data Type: nvarchar(MAX)
|
|
54270
54563
|
*/
|
|
54271
54564
|
get ConversationDetail() {
|
|
@@ -57123,7 +57416,7 @@ let MCPServerConnectionToolEntity = class MCPServerConnectionToolEntity extends
|
|
|
57123
57416
|
}
|
|
57124
57417
|
/**
|
|
57125
57418
|
* * Field Name: MCPServerConnection
|
|
57126
|
-
* * Display Name: Connection
|
|
57419
|
+
* * Display Name: Server Connection
|
|
57127
57420
|
* * SQL Data Type: nvarchar(255)
|
|
57128
57421
|
*/
|
|
57129
57422
|
get MCPServerConnection() {
|
|
@@ -57131,7 +57424,7 @@ let MCPServerConnectionToolEntity = class MCPServerConnectionToolEntity extends
|
|
|
57131
57424
|
}
|
|
57132
57425
|
/**
|
|
57133
57426
|
* * Field Name: MCPServerTool
|
|
57134
|
-
* * Display Name: Tool
|
|
57427
|
+
* * Display Name: Server Tool
|
|
57135
57428
|
* * SQL Data Type: nvarchar(255)
|
|
57136
57429
|
*/
|
|
57137
57430
|
get MCPServerTool() {
|
|
@@ -58029,7 +58322,7 @@ let MCPToolExecutionLogEntity = class MCPToolExecutionLogEntity extends BaseEnti
|
|
|
58029
58322
|
}
|
|
58030
58323
|
/**
|
|
58031
58324
|
* * Field Name: MCPServerConnectionID
|
|
58032
|
-
* * Display Name: MCP Server Connection
|
|
58325
|
+
* * Display Name: MCP Server Connection
|
|
58033
58326
|
* * SQL Data Type: uniqueidentifier
|
|
58034
58327
|
* * Related Entity/Foreign Key: MJ: MCP Server Connections (vwMCPServerConnections.ID)
|
|
58035
58328
|
*/
|
|
@@ -58041,7 +58334,7 @@ let MCPToolExecutionLogEntity = class MCPToolExecutionLogEntity extends BaseEnti
|
|
|
58041
58334
|
}
|
|
58042
58335
|
/**
|
|
58043
58336
|
* * Field Name: MCPServerToolID
|
|
58044
|
-
* * Display Name: MCP Server Tool
|
|
58337
|
+
* * Display Name: MCP Server Tool
|
|
58045
58338
|
* * SQL Data Type: uniqueidentifier
|
|
58046
58339
|
* * Related Entity/Foreign Key: MJ: MCP Server Tools (vwMCPServerTools.ID)
|
|
58047
58340
|
* * Description: FK to MCP Server Tool (null if tool not cached)
|
|
@@ -66483,7 +66776,7 @@ let RecommendationItemEntity = class RecommendationItemEntity extends BaseEntity
|
|
|
66483
66776
|
}
|
|
66484
66777
|
/**
|
|
66485
66778
|
* * Field Name: DestinationEntityID
|
|
66486
|
-
* * Display Name: Destination Entity
|
|
66779
|
+
* * Display Name: Destination Entity
|
|
66487
66780
|
* * SQL Data Type: uniqueidentifier
|
|
66488
66781
|
* * Related Entity/Foreign Key: Entities (vwEntities.ID)
|
|
66489
66782
|
*/
|
|
@@ -66495,7 +66788,7 @@ let RecommendationItemEntity = class RecommendationItemEntity extends BaseEntity
|
|
|
66495
66788
|
}
|
|
66496
66789
|
/**
|
|
66497
66790
|
* * Field Name: DestinationEntityRecordID
|
|
66498
|
-
* * Display Name: Destination
|
|
66791
|
+
* * Display Name: Destination Record ID
|
|
66499
66792
|
* * SQL Data Type: nvarchar(450)
|
|
66500
66793
|
* * Description: The record ID of the destination entity
|
|
66501
66794
|
*/
|
|
@@ -66840,7 +67133,7 @@ let RecommendationEntity = class RecommendationEntity extends BaseEntity {
|
|
|
66840
67133
|
}
|
|
66841
67134
|
/**
|
|
66842
67135
|
* * Field Name: RecommendationRunID
|
|
66843
|
-
* * Display Name: Recommendation Run
|
|
67136
|
+
* * Display Name: Recommendation Run ID
|
|
66844
67137
|
* * SQL Data Type: uniqueidentifier
|
|
66845
67138
|
* * Related Entity/Foreign Key: Recommendation Runs (vwRecommendationRuns.ID)
|
|
66846
67139
|
*/
|
|
@@ -67363,7 +67656,7 @@ let RecordMergeDeletionLogEntity = class RecordMergeDeletionLogEntity extends Ba
|
|
|
67363
67656
|
}
|
|
67364
67657
|
/**
|
|
67365
67658
|
* * Field Name: RecordMergeLogID
|
|
67366
|
-
* * Display Name: Record Merge Log
|
|
67659
|
+
* * Display Name: Record Merge Log ID
|
|
67367
67660
|
* * SQL Data Type: uniqueidentifier
|
|
67368
67661
|
* * Related Entity/Foreign Key: Record Merge Logs (vwRecordMergeLogs.ID)
|
|
67369
67662
|
*/
|
|
@@ -67375,7 +67668,7 @@ let RecordMergeDeletionLogEntity = class RecordMergeDeletionLogEntity extends Ba
|
|
|
67375
67668
|
}
|
|
67376
67669
|
/**
|
|
67377
67670
|
* * Field Name: DeletedRecordID
|
|
67378
|
-
* * Display Name: Deleted Record
|
|
67671
|
+
* * Display Name: Deleted Record ID
|
|
67379
67672
|
* * SQL Data Type: nvarchar(750)
|
|
67380
67673
|
* * Description: Field DeletedRecordID for entity Record Merge Deletion Logs.
|
|
67381
67674
|
*/
|
|
@@ -67434,7 +67727,7 @@ let RecordMergeDeletionLogEntity = class RecordMergeDeletionLogEntity extends Ba
|
|
|
67434
67727
|
}
|
|
67435
67728
|
/**
|
|
67436
67729
|
* * Field Name: RecordMergeLog
|
|
67437
|
-
* * Display Name: Merge Log
|
|
67730
|
+
* * Display Name: Record Merge Log
|
|
67438
67731
|
* * SQL Data Type: nvarchar(450)
|
|
67439
67732
|
*/
|
|
67440
67733
|
get RecordMergeLog() {
|
|
@@ -68915,6 +69208,7 @@ let RoleEntity = class RoleEntity extends BaseEntity {
|
|
|
68915
69208
|
}
|
|
68916
69209
|
/**
|
|
68917
69210
|
* * Field Name: SQLName
|
|
69211
|
+
* * Display Name: SQL Name
|
|
68918
69212
|
* * SQL Data Type: nvarchar(250)
|
|
68919
69213
|
* * Description: The name of the role in the database, this is used for auto-generating permission statements by CodeGen
|
|
68920
69214
|
*/
|
|
@@ -69527,7 +69821,7 @@ let SchemaInfoEntity = class SchemaInfoEntity extends BaseEntity {
|
|
|
69527
69821
|
}
|
|
69528
69822
|
/**
|
|
69529
69823
|
* * Field Name: EntityIDMin
|
|
69530
|
-
* * Display Name: Entity
|
|
69824
|
+
* * Display Name: Entity ID Minimum
|
|
69531
69825
|
* * SQL Data Type: int
|
|
69532
69826
|
* * Description: Field EntityIDMin for entity Schema Info.
|
|
69533
69827
|
*/
|
|
@@ -69539,7 +69833,7 @@ let SchemaInfoEntity = class SchemaInfoEntity extends BaseEntity {
|
|
|
69539
69833
|
}
|
|
69540
69834
|
/**
|
|
69541
69835
|
* * Field Name: EntityIDMax
|
|
69542
|
-
* * Display Name: Entity
|
|
69836
|
+
* * Display Name: Entity ID Maximum
|
|
69543
69837
|
* * SQL Data Type: int
|
|
69544
69838
|
* * Description: Field EntityIDMax for entity Schema Info.
|
|
69545
69839
|
*/
|
|
@@ -69589,6 +69883,30 @@ let SchemaInfoEntity = class SchemaInfoEntity extends BaseEntity {
|
|
|
69589
69883
|
set Description(value) {
|
|
69590
69884
|
this.Set('Description', value);
|
|
69591
69885
|
}
|
|
69886
|
+
/**
|
|
69887
|
+
* * Field Name: EntityNamePrefix
|
|
69888
|
+
* * Display Name: Entity Name Prefix
|
|
69889
|
+
* * SQL Data Type: nvarchar(25)
|
|
69890
|
+
* * Description: Optional prefix to prepend to entity names generated for this schema. For example, setting this to "Committees: " would result in entity names like "Committees: Individuals". Can be overridden by mj.config.cjs NameRulesBySchema settings.
|
|
69891
|
+
*/
|
|
69892
|
+
get EntityNamePrefix() {
|
|
69893
|
+
return this.Get('EntityNamePrefix');
|
|
69894
|
+
}
|
|
69895
|
+
set EntityNamePrefix(value) {
|
|
69896
|
+
this.Set('EntityNamePrefix', value);
|
|
69897
|
+
}
|
|
69898
|
+
/**
|
|
69899
|
+
* * Field Name: EntityNameSuffix
|
|
69900
|
+
* * Display Name: Entity Name Suffix
|
|
69901
|
+
* * SQL Data Type: nvarchar(25)
|
|
69902
|
+
* * Description: Optional suffix to append to entity names generated for this schema. Can be overridden by mj.config.cjs NameRulesBySchema settings.
|
|
69903
|
+
*/
|
|
69904
|
+
get EntityNameSuffix() {
|
|
69905
|
+
return this.Get('EntityNameSuffix');
|
|
69906
|
+
}
|
|
69907
|
+
set EntityNameSuffix(value) {
|
|
69908
|
+
this.Set('EntityNameSuffix', value);
|
|
69909
|
+
}
|
|
69592
69910
|
};
|
|
69593
69911
|
SchemaInfoEntity = __decorate([
|
|
69594
69912
|
RegisterClass(BaseEntity, 'Schema Info')
|
|
@@ -70429,7 +70747,7 @@ let TemplateParamEntity = class TemplateParamEntity extends BaseEntity {
|
|
|
70429
70747
|
}
|
|
70430
70748
|
/**
|
|
70431
70749
|
* * Field Name: IsRequired
|
|
70432
|
-
* * Display Name:
|
|
70750
|
+
* * Display Name: Required
|
|
70433
70751
|
* * SQL Data Type: bit
|
|
70434
70752
|
* * Default Value: 0
|
|
70435
70753
|
* * Description: Whether this parameter must be provided when using the template.
|