@memberjunction/server 5.16.0 → 5.18.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.
@@ -7180,12 +7180,12 @@ each time the agent processes a prompt step.`})
7180
7180
  @Field(() => [MJAIAgentRun_])
7181
7181
  MJAIAgentRuns_ParentRunIDArray: MJAIAgentRun_[]; // Link to MJAIAgentRuns
7182
7182
 
7183
- @Field(() => [MJAIAgentNote_])
7184
- MJAIAgentNotes_SourceAIAgentRunIDArray: MJAIAgentNote_[]; // Link to MJAIAgentNotes
7185
-
7186
7183
  @Field(() => [MJAIAgentExample_])
7187
7184
  MJAIAgentExamples_SourceAIAgentRunIDArray: MJAIAgentExample_[]; // Link to MJAIAgentExamples
7188
7185
 
7186
+ @Field(() => [MJAIAgentNote_])
7187
+ MJAIAgentNotes_SourceAIAgentRunIDArray: MJAIAgentNote_[]; // Link to MJAIAgentNotes
7188
+
7189
7189
  @Field(() => [MJAIAgentRunMedia_])
7190
7190
  MJAIAgentRunMedias_AgentRunIDArray: MJAIAgentRunMedia_[]; // Link to MJAIAgentRunMedias
7191
7191
 
@@ -7554,16 +7554,6 @@ export class MJAIAgentRunResolver extends ResolverBase {
7554
7554
  return result;
7555
7555
  }
7556
7556
 
7557
- @FieldResolver(() => [MJAIAgentNote_])
7558
- async MJAIAgentNotes_SourceAIAgentRunIDArray(@Root() mjaiagentrun_: MJAIAgentRun_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
7559
- this.CheckUserReadPermissions('MJ: AI Agent Notes', userPayload);
7560
- const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
7561
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwAIAgentNotes')} WHERE ${provider.QuoteIdentifier('SourceAIAgentRunID')}='${mjaiagentrun_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Agent Notes', userPayload, EntityPermissionType.Read, 'AND');
7562
- const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
7563
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: AI Agent Notes', rows, this.GetUserFromPayload(userPayload));
7564
- return result;
7565
- }
7566
-
7567
7557
  @FieldResolver(() => [MJAIAgentExample_])
7568
7558
  async MJAIAgentExamples_SourceAIAgentRunIDArray(@Root() mjaiagentrun_: MJAIAgentRun_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
7569
7559
  this.CheckUserReadPermissions('MJ: AI Agent Examples', userPayload);
@@ -7574,6 +7564,16 @@ export class MJAIAgentRunResolver extends ResolverBase {
7574
7564
  return result;
7575
7565
  }
7576
7566
 
7567
+ @FieldResolver(() => [MJAIAgentNote_])
7568
+ async MJAIAgentNotes_SourceAIAgentRunIDArray(@Root() mjaiagentrun_: MJAIAgentRun_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
7569
+ this.CheckUserReadPermissions('MJ: AI Agent Notes', userPayload);
7570
+ const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
7571
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwAIAgentNotes')} WHERE ${provider.QuoteIdentifier('SourceAIAgentRunID')}='${mjaiagentrun_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Agent Notes', userPayload, EntityPermissionType.Read, 'AND');
7572
+ const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
7573
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: AI Agent Notes', rows, this.GetUserFromPayload(userPayload));
7574
+ return result;
7575
+ }
7576
+
7577
7577
  @FieldResolver(() => [MJAIAgentRunMedia_])
7578
7578
  async MJAIAgentRunMedias_AgentRunIDArray(@Root() mjaiagentrun_: MJAIAgentRun_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
7579
7579
  this.CheckUserReadPermissions('MJ: AI Agent Run Medias', userPayload);
@@ -8700,12 +8700,12 @@ if this limit is exceeded.`})
8700
8700
  @MaxLength(36)
8701
8701
  RootParentID?: string;
8702
8702
 
8703
- @Field(() => [MJAIAgentModel_])
8704
- MJAIAgentModels_AgentIDArray: MJAIAgentModel_[]; // Link to MJAIAgentModels
8705
-
8706
8703
  @Field(() => [MJAIAgentAction_])
8707
8704
  MJAIAgentActions_AgentIDArray: MJAIAgentAction_[]; // Link to MJAIAgentActions
8708
8705
 
8706
+ @Field(() => [MJAIAgentModel_])
8707
+ MJAIAgentModels_AgentIDArray: MJAIAgentModel_[]; // Link to MJAIAgentModels
8708
+
8709
8709
  @Field(() => [MJAIAgentLearningCycle_])
8710
8710
  MJAIAgentLearningCycles_AgentIDArray: MJAIAgentLearningCycle_[]; // Link to MJAIAgentLearningCycles
8711
8711
 
@@ -9201,16 +9201,6 @@ export class MJAIAgentResolver extends ResolverBase {
9201
9201
  return result;
9202
9202
  }
9203
9203
 
9204
- @FieldResolver(() => [MJAIAgentModel_])
9205
- async MJAIAgentModels_AgentIDArray(@Root() mjaiagent_: MJAIAgent_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
9206
- this.CheckUserReadPermissions('MJ: AI Agent Models', userPayload);
9207
- const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
9208
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwAIAgentModels')} WHERE ${provider.QuoteIdentifier('AgentID')}='${mjaiagent_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Agent Models', userPayload, EntityPermissionType.Read, 'AND');
9209
- const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
9210
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: AI Agent Models', rows, this.GetUserFromPayload(userPayload));
9211
- return result;
9212
- }
9213
-
9214
9204
  @FieldResolver(() => [MJAIAgentAction_])
9215
9205
  async MJAIAgentActions_AgentIDArray(@Root() mjaiagent_: MJAIAgent_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
9216
9206
  this.CheckUserReadPermissions('MJ: AI Agent Actions', userPayload);
@@ -9221,6 +9211,16 @@ export class MJAIAgentResolver extends ResolverBase {
9221
9211
  return result;
9222
9212
  }
9223
9213
 
9214
+ @FieldResolver(() => [MJAIAgentModel_])
9215
+ async MJAIAgentModels_AgentIDArray(@Root() mjaiagent_: MJAIAgent_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
9216
+ this.CheckUserReadPermissions('MJ: AI Agent Models', userPayload);
9217
+ const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
9218
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwAIAgentModels')} WHERE ${provider.QuoteIdentifier('AgentID')}='${mjaiagent_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Agent Models', userPayload, EntityPermissionType.Read, 'AND');
9219
+ const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
9220
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: AI Agent Models', rows, this.GetUserFromPayload(userPayload));
9221
+ return result;
9222
+ }
9223
+
9224
9224
  @FieldResolver(() => [MJAIAgentLearningCycle_])
9225
9225
  async MJAIAgentLearningCycles_AgentIDArray(@Root() mjaiagent_: MJAIAgent_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
9226
9226
  this.CheckUserReadPermissions('MJ: AI Agent Learning Cycles', userPayload);
@@ -9923,21 +9923,21 @@ export class MJAIConfiguration_ {
9923
9923
  @MaxLength(36)
9924
9924
  RootParentID?: string;
9925
9925
 
9926
- @Field(() => [MJAIConfigurationParam_])
9927
- MJAIConfigurationParams_ConfigurationIDArray: MJAIConfigurationParam_[]; // Link to MJAIConfigurationParams
9928
-
9929
9926
  @Field(() => [MJAIAgentPrompt_])
9930
9927
  MJAIAgentPrompts_ConfigurationIDArray: MJAIAgentPrompt_[]; // Link to MJAIAgentPrompts
9931
9928
 
9929
+ @Field(() => [MJAIConfigurationParam_])
9930
+ MJAIConfigurationParams_ConfigurationIDArray: MJAIConfigurationParam_[]; // Link to MJAIConfigurationParams
9931
+
9932
9932
  @Field(() => [MJAIAgentConfiguration_])
9933
9933
  MJAIAgentConfigurations_AIConfigurationIDArray: MJAIAgentConfiguration_[]; // Link to MJAIAgentConfigurations
9934
9934
 
9935
- @Field(() => [MJAIPromptRun_])
9936
- MJAIPromptRuns_ConfigurationIDArray: MJAIPromptRun_[]; // Link to MJAIPromptRuns
9937
-
9938
9935
  @Field(() => [MJAIPromptModel_])
9939
9936
  MJAIPromptModels_ConfigurationIDArray: MJAIPromptModel_[]; // Link to MJAIPromptModels
9940
9937
 
9938
+ @Field(() => [MJAIPromptRun_])
9939
+ MJAIPromptRuns_ConfigurationIDArray: MJAIPromptRun_[]; // Link to MJAIPromptRuns
9940
+
9941
9941
  @Field(() => [MJAIResultCache_])
9942
9942
  MJAIResultCache_ConfigurationIDArray: MJAIResultCache_[]; // Link to MJAIResultCache
9943
9943
 
@@ -10082,16 +10082,6 @@ export class MJAIConfigurationResolver extends ResolverBase {
10082
10082
  return result;
10083
10083
  }
10084
10084
 
10085
- @FieldResolver(() => [MJAIConfigurationParam_])
10086
- async MJAIConfigurationParams_ConfigurationIDArray(@Root() mjaiconfiguration_: MJAIConfiguration_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
10087
- this.CheckUserReadPermissions('MJ: AI Configuration Params', userPayload);
10088
- const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
10089
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwAIConfigurationParams')} WHERE ${provider.QuoteIdentifier('ConfigurationID')}='${mjaiconfiguration_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Configuration Params', userPayload, EntityPermissionType.Read, 'AND');
10090
- const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
10091
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: AI Configuration Params', rows, this.GetUserFromPayload(userPayload));
10092
- return result;
10093
- }
10094
-
10095
10085
  @FieldResolver(() => [MJAIAgentPrompt_])
10096
10086
  async MJAIAgentPrompts_ConfigurationIDArray(@Root() mjaiconfiguration_: MJAIConfiguration_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
10097
10087
  this.CheckUserReadPermissions('MJ: AI Agent Prompts', userPayload);
@@ -10102,23 +10092,23 @@ export class MJAIConfigurationResolver extends ResolverBase {
10102
10092
  return result;
10103
10093
  }
10104
10094
 
10105
- @FieldResolver(() => [MJAIAgentConfiguration_])
10106
- async MJAIAgentConfigurations_AIConfigurationIDArray(@Root() mjaiconfiguration_: MJAIConfiguration_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
10107
- this.CheckUserReadPermissions('MJ: AI Agent Configurations', userPayload);
10095
+ @FieldResolver(() => [MJAIConfigurationParam_])
10096
+ async MJAIConfigurationParams_ConfigurationIDArray(@Root() mjaiconfiguration_: MJAIConfiguration_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
10097
+ this.CheckUserReadPermissions('MJ: AI Configuration Params', userPayload);
10108
10098
  const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
10109
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwAIAgentConfigurations')} WHERE ${provider.QuoteIdentifier('AIConfigurationID')}='${mjaiconfiguration_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Agent Configurations', userPayload, EntityPermissionType.Read, 'AND');
10099
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwAIConfigurationParams')} WHERE ${provider.QuoteIdentifier('ConfigurationID')}='${mjaiconfiguration_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Configuration Params', userPayload, EntityPermissionType.Read, 'AND');
10110
10100
  const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
10111
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: AI Agent Configurations', rows, this.GetUserFromPayload(userPayload));
10101
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: AI Configuration Params', rows, this.GetUserFromPayload(userPayload));
10112
10102
  return result;
10113
10103
  }
10114
10104
 
10115
- @FieldResolver(() => [MJAIPromptRun_])
10116
- async MJAIPromptRuns_ConfigurationIDArray(@Root() mjaiconfiguration_: MJAIConfiguration_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
10117
- this.CheckUserReadPermissions('MJ: AI Prompt Runs', userPayload);
10105
+ @FieldResolver(() => [MJAIAgentConfiguration_])
10106
+ async MJAIAgentConfigurations_AIConfigurationIDArray(@Root() mjaiconfiguration_: MJAIConfiguration_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
10107
+ this.CheckUserReadPermissions('MJ: AI Agent Configurations', userPayload);
10118
10108
  const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
10119
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwAIPromptRuns')} WHERE ${provider.QuoteIdentifier('ConfigurationID')}='${mjaiconfiguration_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Prompt Runs', userPayload, EntityPermissionType.Read, 'AND');
10109
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwAIAgentConfigurations')} WHERE ${provider.QuoteIdentifier('AIConfigurationID')}='${mjaiconfiguration_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Agent Configurations', userPayload, EntityPermissionType.Read, 'AND');
10120
10110
  const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
10121
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: AI Prompt Runs', rows, this.GetUserFromPayload(userPayload));
10111
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: AI Agent Configurations', rows, this.GetUserFromPayload(userPayload));
10122
10112
  return result;
10123
10113
  }
10124
10114
 
@@ -10132,6 +10122,16 @@ export class MJAIConfigurationResolver extends ResolverBase {
10132
10122
  return result;
10133
10123
  }
10134
10124
 
10125
+ @FieldResolver(() => [MJAIPromptRun_])
10126
+ async MJAIPromptRuns_ConfigurationIDArray(@Root() mjaiconfiguration_: MJAIConfiguration_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
10127
+ this.CheckUserReadPermissions('MJ: AI Prompt Runs', userPayload);
10128
+ const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
10129
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwAIPromptRuns')} WHERE ${provider.QuoteIdentifier('ConfigurationID')}='${mjaiconfiguration_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Prompt Runs', userPayload, EntityPermissionType.Read, 'AND');
10130
+ const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
10131
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: AI Prompt Runs', rows, this.GetUserFromPayload(userPayload));
10132
+ return result;
10133
+ }
10134
+
10135
10135
  @FieldResolver(() => [MJAIResultCache_])
10136
10136
  async MJAIResultCache_ConfigurationIDArray(@Root() mjaiconfiguration_: MJAIConfiguration_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
10137
10137
  this.CheckUserReadPermissions('MJ: AI Result Cache', userPayload);
@@ -16295,14 +16295,14 @@ export class MJAIVendor_ {
16295
16295
  @Field(() => [MJAIModelVendor_])
16296
16296
  MJAIModelVendors_VendorIDArray: MJAIModelVendor_[]; // Link to MJAIModelVendors
16297
16297
 
16298
- @Field(() => [MJAIResultCache_])
16299
- MJAIResultCache_VendorIDArray: MJAIResultCache_[]; // Link to MJAIResultCache
16298
+ @Field(() => [MJAIPromptModel_])
16299
+ MJAIPromptModels_VendorIDArray: MJAIPromptModel_[]; // Link to MJAIPromptModels
16300
16300
 
16301
16301
  @Field(() => [MJAIPromptRun_])
16302
16302
  MJAIPromptRuns_VendorIDArray: MJAIPromptRun_[]; // Link to MJAIPromptRuns
16303
16303
 
16304
- @Field(() => [MJAIPromptModel_])
16305
- MJAIPromptModels_VendorIDArray: MJAIPromptModel_[]; // Link to MJAIPromptModels
16304
+ @Field(() => [MJAIResultCache_])
16305
+ MJAIResultCache_VendorIDArray: MJAIResultCache_[]; // Link to MJAIResultCache
16306
16306
 
16307
16307
  @Field(() => [MJAIVendorType_])
16308
16308
  MJAIVendorTypes_VendorIDArray: MJAIVendorType_[]; // Link to MJAIVendorTypes
@@ -16425,13 +16425,13 @@ export class MJAIVendorResolver extends ResolverBase {
16425
16425
  return result;
16426
16426
  }
16427
16427
 
16428
- @FieldResolver(() => [MJAIResultCache_])
16429
- async MJAIResultCache_VendorIDArray(@Root() mjaivendor_: MJAIVendor_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
16430
- this.CheckUserReadPermissions('MJ: AI Result Cache', userPayload);
16428
+ @FieldResolver(() => [MJAIPromptModel_])
16429
+ async MJAIPromptModels_VendorIDArray(@Root() mjaivendor_: MJAIVendor_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
16430
+ this.CheckUserReadPermissions('MJ: AI Prompt Models', userPayload);
16431
16431
  const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
16432
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwAIResultCaches')} WHERE ${provider.QuoteIdentifier('VendorID')}='${mjaivendor_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Result Cache', userPayload, EntityPermissionType.Read, 'AND');
16432
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwAIPromptModels')} WHERE ${provider.QuoteIdentifier('VendorID')}='${mjaivendor_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Prompt Models', userPayload, EntityPermissionType.Read, 'AND');
16433
16433
  const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
16434
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: AI Result Cache', rows, this.GetUserFromPayload(userPayload));
16434
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: AI Prompt Models', rows, this.GetUserFromPayload(userPayload));
16435
16435
  return result;
16436
16436
  }
16437
16437
 
@@ -16445,13 +16445,13 @@ export class MJAIVendorResolver extends ResolverBase {
16445
16445
  return result;
16446
16446
  }
16447
16447
 
16448
- @FieldResolver(() => [MJAIPromptModel_])
16449
- async MJAIPromptModels_VendorIDArray(@Root() mjaivendor_: MJAIVendor_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
16450
- this.CheckUserReadPermissions('MJ: AI Prompt Models', userPayload);
16448
+ @FieldResolver(() => [MJAIResultCache_])
16449
+ async MJAIResultCache_VendorIDArray(@Root() mjaivendor_: MJAIVendor_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
16450
+ this.CheckUserReadPermissions('MJ: AI Result Cache', userPayload);
16451
16451
  const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
16452
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwAIPromptModels')} WHERE ${provider.QuoteIdentifier('VendorID')}='${mjaivendor_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Prompt Models', userPayload, EntityPermissionType.Read, 'AND');
16452
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwAIResultCaches')} WHERE ${provider.QuoteIdentifier('VendorID')}='${mjaivendor_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Result Cache', userPayload, EntityPermissionType.Read, 'AND');
16453
16453
  const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
16454
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: AI Prompt Models', rows, this.GetUserFromPayload(userPayload));
16454
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: AI Result Cache', rows, this.GetUserFromPayload(userPayload));
16455
16455
  return result;
16456
16456
  }
16457
16457
 
@@ -17818,12 +17818,12 @@ export class MJAPIScope_ {
17818
17818
  @Field(() => [MJAPIKeyScope_])
17819
17819
  MJAPIKeyScopes_ScopeIDArray: MJAPIKeyScope_[]; // Link to MJAPIKeyScopes
17820
17820
 
17821
- @Field(() => [MJAPIScope_])
17822
- MJAPIScopes_ParentIDArray: MJAPIScope_[]; // Link to MJAPIScopes
17823
-
17824
17821
  @Field(() => [MJAPIApplicationScope_])
17825
17822
  MJAPIApplicationScopes_ScopeIDArray: MJAPIApplicationScope_[]; // Link to MJAPIApplicationScopes
17826
17823
 
17824
+ @Field(() => [MJAPIScope_])
17825
+ MJAPIScopes_ParentIDArray: MJAPIScope_[]; // Link to MJAPIScopes
17826
+
17827
17827
  }
17828
17828
 
17829
17829
  //****************************************************************************
@@ -17963,16 +17963,6 @@ export class MJAPIScopeResolver extends ResolverBase {
17963
17963
  return result;
17964
17964
  }
17965
17965
 
17966
- @FieldResolver(() => [MJAPIScope_])
17967
- async MJAPIScopes_ParentIDArray(@Root() mjapiscope_: MJAPIScope_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
17968
- this.CheckUserReadPermissions('MJ: API Scopes', userPayload);
17969
- const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
17970
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwAPIScopes')} WHERE ${provider.QuoteIdentifier('ParentID')}='${mjapiscope_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: API Scopes', userPayload, EntityPermissionType.Read, 'AND');
17971
- const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
17972
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: API Scopes', rows, this.GetUserFromPayload(userPayload));
17973
- return result;
17974
- }
17975
-
17976
17966
  @FieldResolver(() => [MJAPIApplicationScope_])
17977
17967
  async MJAPIApplicationScopes_ScopeIDArray(@Root() mjapiscope_: MJAPIScope_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
17978
17968
  this.CheckUserReadPermissions('MJ: API Application Scopes', userPayload);
@@ -17983,6 +17973,16 @@ export class MJAPIScopeResolver extends ResolverBase {
17983
17973
  return result;
17984
17974
  }
17985
17975
 
17976
+ @FieldResolver(() => [MJAPIScope_])
17977
+ async MJAPIScopes_ParentIDArray(@Root() mjapiscope_: MJAPIScope_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
17978
+ this.CheckUserReadPermissions('MJ: API Scopes', userPayload);
17979
+ const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
17980
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwAPIScopes')} WHERE ${provider.QuoteIdentifier('ParentID')}='${mjapiscope_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: API Scopes', userPayload, EntityPermissionType.Read, 'AND');
17981
+ const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
17982
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: API Scopes', rows, this.GetUserFromPayload(userPayload));
17983
+ return result;
17984
+ }
17985
+
17986
17986
  @Mutation(() => MJAPIScope_)
17987
17987
  async CreateMJAPIScope(
17988
17988
  @Arg('input', () => CreateMJAPIScopeInput) input: CreateMJAPIScopeInput,
@@ -22882,12 +22882,12 @@ export class MJCompanyIntegrationEntityMap_ {
22882
22882
  @MaxLength(255)
22883
22883
  Entity: string;
22884
22884
 
22885
- @Field(() => [MJCompanyIntegrationSyncWatermark_])
22886
- MJCompanyIntegrationSyncWatermarks_EntityMapIDArray: MJCompanyIntegrationSyncWatermark_[]; // Link to MJCompanyIntegrationSyncWatermarks
22887
-
22888
22885
  @Field(() => [MJCompanyIntegrationFieldMap_])
22889
22886
  MJCompanyIntegrationFieldMaps_EntityMapIDArray: MJCompanyIntegrationFieldMap_[]; // Link to MJCompanyIntegrationFieldMaps
22890
22887
 
22888
+ @Field(() => [MJCompanyIntegrationSyncWatermark_])
22889
+ MJCompanyIntegrationSyncWatermarks_EntityMapIDArray: MJCompanyIntegrationSyncWatermark_[]; // Link to MJCompanyIntegrationSyncWatermarks
22890
+
22891
22891
  }
22892
22892
 
22893
22893
  //****************************************************************************
@@ -23041,16 +23041,6 @@ export class MJCompanyIntegrationEntityMapResolver extends ResolverBase {
23041
23041
  return result;
23042
23042
  }
23043
23043
 
23044
- @FieldResolver(() => [MJCompanyIntegrationSyncWatermark_])
23045
- async MJCompanyIntegrationSyncWatermarks_EntityMapIDArray(@Root() mjcompanyintegrationentitymap_: MJCompanyIntegrationEntityMap_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
23046
- this.CheckUserReadPermissions('MJ: Company Integration Sync Watermarks', userPayload);
23047
- const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
23048
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwCompanyIntegrationSyncWatermarks')} WHERE ${provider.QuoteIdentifier('EntityMapID')}='${mjcompanyintegrationentitymap_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Company Integration Sync Watermarks', userPayload, EntityPermissionType.Read, 'AND');
23049
- const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
23050
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Company Integration Sync Watermarks', rows, this.GetUserFromPayload(userPayload));
23051
- return result;
23052
- }
23053
-
23054
23044
  @FieldResolver(() => [MJCompanyIntegrationFieldMap_])
23055
23045
  async MJCompanyIntegrationFieldMaps_EntityMapIDArray(@Root() mjcompanyintegrationentitymap_: MJCompanyIntegrationEntityMap_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
23056
23046
  this.CheckUserReadPermissions('MJ: Company Integration Field Maps', userPayload);
@@ -23061,6 +23051,16 @@ export class MJCompanyIntegrationEntityMapResolver extends ResolverBase {
23061
23051
  return result;
23062
23052
  }
23063
23053
 
23054
+ @FieldResolver(() => [MJCompanyIntegrationSyncWatermark_])
23055
+ async MJCompanyIntegrationSyncWatermarks_EntityMapIDArray(@Root() mjcompanyintegrationentitymap_: MJCompanyIntegrationEntityMap_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
23056
+ this.CheckUserReadPermissions('MJ: Company Integration Sync Watermarks', userPayload);
23057
+ const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
23058
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwCompanyIntegrationSyncWatermarks')} WHERE ${provider.QuoteIdentifier('EntityMapID')}='${mjcompanyintegrationentitymap_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Company Integration Sync Watermarks', userPayload, EntityPermissionType.Read, 'AND');
23059
+ const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
23060
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Company Integration Sync Watermarks', rows, this.GetUserFromPayload(userPayload));
23061
+ return result;
23062
+ }
23063
+
23064
23064
  @Mutation(() => MJCompanyIntegrationEntityMap_)
23065
23065
  async CreateMJCompanyIntegrationEntityMap(
23066
23066
  @Arg('input', () => CreateMJCompanyIntegrationEntityMapInput) input: CreateMJCompanyIntegrationEntityMapInput,
@@ -25703,12 +25703,12 @@ export class MJComponent_ {
25703
25703
  @MaxLength(255)
25704
25704
  SourceRegistry?: string;
25705
25705
 
25706
- @Field(() => [MJComponentLibraryLink_])
25707
- MJComponentLibraryLinks_ComponentIDArray: MJComponentLibraryLink_[]; // Link to MJComponentLibraryLinks
25708
-
25709
25706
  @Field(() => [MJComponentDependency_])
25710
25707
  MJComponentDependencies_ComponentIDArray: MJComponentDependency_[]; // Link to MJComponentDependencies
25711
25708
 
25709
+ @Field(() => [MJComponentLibraryLink_])
25710
+ MJComponentLibraryLinks_ComponentIDArray: MJComponentLibraryLink_[]; // Link to MJComponentLibraryLinks
25711
+
25712
25712
  @Field(() => [MJComponentDependency_])
25713
25713
  MJComponentDependencies_DependencyComponentIDArray: MJComponentDependency_[]; // Link to MJComponentDependencies
25714
25714
 
@@ -25949,16 +25949,6 @@ export class MJComponentResolver extends ResolverBase {
25949
25949
  return result;
25950
25950
  }
25951
25951
 
25952
- @FieldResolver(() => [MJComponentLibraryLink_])
25953
- async MJComponentLibraryLinks_ComponentIDArray(@Root() mjcomponent_: MJComponent_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
25954
- this.CheckUserReadPermissions('MJ: Component Library Links', userPayload);
25955
- const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
25956
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwComponentLibraryLinks')} WHERE ${provider.QuoteIdentifier('ComponentID')}='${mjcomponent_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Component Library Links', userPayload, EntityPermissionType.Read, 'AND');
25957
- const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
25958
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Component Library Links', rows, this.GetUserFromPayload(userPayload));
25959
- return result;
25960
- }
25961
-
25962
25952
  @FieldResolver(() => [MJComponentDependency_])
25963
25953
  async MJComponentDependencies_ComponentIDArray(@Root() mjcomponent_: MJComponent_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
25964
25954
  this.CheckUserReadPermissions('MJ: Component Dependencies', userPayload);
@@ -25969,6 +25959,16 @@ export class MJComponentResolver extends ResolverBase {
25969
25959
  return result;
25970
25960
  }
25971
25961
 
25962
+ @FieldResolver(() => [MJComponentLibraryLink_])
25963
+ async MJComponentLibraryLinks_ComponentIDArray(@Root() mjcomponent_: MJComponent_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
25964
+ this.CheckUserReadPermissions('MJ: Component Library Links', userPayload);
25965
+ const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
25966
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwComponentLibraryLinks')} WHERE ${provider.QuoteIdentifier('ComponentID')}='${mjcomponent_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Component Library Links', userPayload, EntityPermissionType.Read, 'AND');
25967
+ const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
25968
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Component Library Links', rows, this.GetUserFromPayload(userPayload));
25969
+ return result;
25970
+ }
25971
+
25972
25972
  @FieldResolver(() => [MJComponentDependency_])
25973
25973
  async MJComponentDependencies_DependencyComponentIDArray(@Root() mjcomponent_: MJComponent_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
25974
25974
  this.CheckUserReadPermissions('MJ: Component Dependencies', userPayload);
@@ -27465,15 +27465,15 @@ export class MJContentSource_ {
27465
27465
  @MaxLength(255)
27466
27466
  ContentFileType: string;
27467
27467
 
27468
- @Field(() => [MJContentSourceParam_])
27469
- MJContentSourceParams_ContentSourceIDArray: MJContentSourceParam_[]; // Link to MJContentSourceParams
27470
-
27471
27468
  @Field(() => [MJContentItem_])
27472
27469
  MJContentItems_ContentSourceIDArray: MJContentItem_[]; // Link to MJContentItems
27473
27470
 
27474
27471
  @Field(() => [MJContentProcessRun_])
27475
27472
  MJContentProcessRuns_SourceIDArray: MJContentProcessRun_[]; // Link to MJContentProcessRuns
27476
27473
 
27474
+ @Field(() => [MJContentSourceParam_])
27475
+ MJContentSourceParams_ContentSourceIDArray: MJContentSourceParam_[]; // Link to MJContentSourceParams
27476
+
27477
27477
  }
27478
27478
 
27479
27479
  //****************************************************************************
@@ -27585,16 +27585,6 @@ export class MJContentSourceResolver extends ResolverBase {
27585
27585
  return result;
27586
27586
  }
27587
27587
 
27588
- @FieldResolver(() => [MJContentSourceParam_])
27589
- async MJContentSourceParams_ContentSourceIDArray(@Root() mjcontentsource_: MJContentSource_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
27590
- this.CheckUserReadPermissions('MJ: Content Source Params', userPayload);
27591
- const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
27592
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwContentSourceParams')} WHERE ${provider.QuoteIdentifier('ContentSourceID')}='${mjcontentsource_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Content Source Params', userPayload, EntityPermissionType.Read, 'AND');
27593
- const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
27594
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Content Source Params', rows, this.GetUserFromPayload(userPayload));
27595
- return result;
27596
- }
27597
-
27598
27588
  @FieldResolver(() => [MJContentItem_])
27599
27589
  async MJContentItems_ContentSourceIDArray(@Root() mjcontentsource_: MJContentSource_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
27600
27590
  this.CheckUserReadPermissions('MJ: Content Items', userPayload);
@@ -27615,6 +27605,16 @@ export class MJContentSourceResolver extends ResolverBase {
27615
27605
  return result;
27616
27606
  }
27617
27607
 
27608
+ @FieldResolver(() => [MJContentSourceParam_])
27609
+ async MJContentSourceParams_ContentSourceIDArray(@Root() mjcontentsource_: MJContentSource_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
27610
+ this.CheckUserReadPermissions('MJ: Content Source Params', userPayload);
27611
+ const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
27612
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwContentSourceParams')} WHERE ${provider.QuoteIdentifier('ContentSourceID')}='${mjcontentsource_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Content Source Params', userPayload, EntityPermissionType.Read, 'AND');
27613
+ const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
27614
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Content Source Params', rows, this.GetUserFromPayload(userPayload));
27615
+ return result;
27616
+ }
27617
+
27618
27618
  @Mutation(() => MJContentSource_)
27619
27619
  async CreateMJContentSource(
27620
27620
  @Arg('input', () => CreateMJContentSourceInput) input: CreateMJContentSourceInput,
@@ -35746,12 +35746,12 @@ export class MJEntity_ {
35746
35746
  @Field(() => [MJAIAgentNote_])
35747
35747
  MJAIAgentNotes_PrimaryScopeEntityIDArray: MJAIAgentNote_[]; // Link to MJAIAgentNotes
35748
35748
 
35749
- @Field(() => [MJVersionLabel_])
35750
- MJVersionLabels_EntityIDArray: MJVersionLabel_[]; // Link to MJVersionLabels
35751
-
35752
35749
  @Field(() => [MJVersionLabelItem_])
35753
35750
  MJVersionLabelItems_EntityIDArray: MJVersionLabelItem_[]; // Link to MJVersionLabelItems
35754
35751
 
35752
+ @Field(() => [MJVersionLabel_])
35753
+ MJVersionLabels_EntityIDArray: MJVersionLabel_[]; // Link to MJVersionLabels
35754
+
35755
35755
  @Field(() => [MJEntityAIAction_])
35756
35756
  MJEntityAIActions_EntityIDArray: MJEntityAIAction_[]; // Link to MJEntityAIActions
35757
35757
 
@@ -36594,16 +36594,6 @@ export class MJEntityResolverBase extends ResolverBase {
36594
36594
  return result;
36595
36595
  }
36596
36596
 
36597
- @FieldResolver(() => [MJVersionLabel_])
36598
- async MJVersionLabels_EntityIDArray(@Root() mjentity_: MJEntity_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
36599
- this.CheckUserReadPermissions('MJ: Version Labels', userPayload);
36600
- const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
36601
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwVersionLabels')} WHERE ${provider.QuoteIdentifier('EntityID')}='${mjentity_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Version Labels', userPayload, EntityPermissionType.Read, 'AND');
36602
- const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
36603
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Version Labels', rows, this.GetUserFromPayload(userPayload));
36604
- return result;
36605
- }
36606
-
36607
36597
  @FieldResolver(() => [MJVersionLabelItem_])
36608
36598
  async MJVersionLabelItems_EntityIDArray(@Root() mjentity_: MJEntity_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
36609
36599
  this.CheckUserReadPermissions('MJ: Version Label Items', userPayload);
@@ -36614,6 +36604,16 @@ export class MJEntityResolverBase extends ResolverBase {
36614
36604
  return result;
36615
36605
  }
36616
36606
 
36607
+ @FieldResolver(() => [MJVersionLabel_])
36608
+ async MJVersionLabels_EntityIDArray(@Root() mjentity_: MJEntity_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
36609
+ this.CheckUserReadPermissions('MJ: Version Labels', userPayload);
36610
+ const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
36611
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwVersionLabels')} WHERE ${provider.QuoteIdentifier('EntityID')}='${mjentity_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Version Labels', userPayload, EntityPermissionType.Read, 'AND');
36612
+ const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
36613
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Version Labels', rows, this.GetUserFromPayload(userPayload));
36614
+ return result;
36615
+ }
36616
+
36617
36617
  @FieldResolver(() => [MJEntityAIAction_])
36618
36618
  async MJEntityAIActions_EntityIDArray(@Root() mjentity_: MJEntity_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
36619
36619
  this.CheckUserReadPermissions('MJ: Entity AI Actions', userPayload);
@@ -41515,18 +41515,18 @@ export class MJEnvironment_ {
41515
41515
  @Field(() => [MJArtifact_])
41516
41516
  MJArtifacts_EnvironmentIDArray: MJArtifact_[]; // Link to MJArtifacts
41517
41517
 
41518
- @Field(() => [MJProject_])
41519
- MJProjects_EnvironmentIDArray: MJProject_[]; // Link to MJProjects
41520
-
41521
41518
  @Field(() => [MJCollection_])
41522
41519
  MJCollections_EnvironmentIDArray: MJCollection_[]; // Link to MJCollections
41523
41520
 
41524
- @Field(() => [MJTask_])
41525
- MJTasks_EnvironmentIDArray: MJTask_[]; // Link to MJTasks
41521
+ @Field(() => [MJProject_])
41522
+ MJProjects_EnvironmentIDArray: MJProject_[]; // Link to MJProjects
41526
41523
 
41527
41524
  @Field(() => [MJDashboard_])
41528
41525
  MJDashboards_EnvironmentIDArray: MJDashboard_[]; // Link to MJDashboards
41529
41526
 
41527
+ @Field(() => [MJTask_])
41528
+ MJTasks_EnvironmentIDArray: MJTask_[]; // Link to MJTasks
41529
+
41530
41530
  @Field(() => [MJReport_])
41531
41531
  MJReports_EnvironmentIDArray: MJReport_[]; // Link to MJReports
41532
41532
 
@@ -41648,16 +41648,6 @@ export class MJEnvironmentResolver extends ResolverBase {
41648
41648
  return result;
41649
41649
  }
41650
41650
 
41651
- @FieldResolver(() => [MJProject_])
41652
- async MJProjects_EnvironmentIDArray(@Root() mjenvironment_: MJEnvironment_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
41653
- this.CheckUserReadPermissions('MJ: Projects', userPayload);
41654
- const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
41655
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwProjects')} WHERE ${provider.QuoteIdentifier('EnvironmentID')}='${mjenvironment_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Projects', userPayload, EntityPermissionType.Read, 'AND');
41656
- const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
41657
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Projects', rows, this.GetUserFromPayload(userPayload));
41658
- return result;
41659
- }
41660
-
41661
41651
  @FieldResolver(() => [MJCollection_])
41662
41652
  async MJCollections_EnvironmentIDArray(@Root() mjenvironment_: MJEnvironment_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
41663
41653
  this.CheckUserReadPermissions('MJ: Collections', userPayload);
@@ -41668,13 +41658,13 @@ export class MJEnvironmentResolver extends ResolverBase {
41668
41658
  return result;
41669
41659
  }
41670
41660
 
41671
- @FieldResolver(() => [MJTask_])
41672
- async MJTasks_EnvironmentIDArray(@Root() mjenvironment_: MJEnvironment_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
41673
- this.CheckUserReadPermissions('MJ: Tasks', userPayload);
41661
+ @FieldResolver(() => [MJProject_])
41662
+ async MJProjects_EnvironmentIDArray(@Root() mjenvironment_: MJEnvironment_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
41663
+ this.CheckUserReadPermissions('MJ: Projects', userPayload);
41674
41664
  const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
41675
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwTasks')} WHERE ${provider.QuoteIdentifier('EnvironmentID')}='${mjenvironment_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Tasks', userPayload, EntityPermissionType.Read, 'AND');
41665
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwProjects')} WHERE ${provider.QuoteIdentifier('EnvironmentID')}='${mjenvironment_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Projects', userPayload, EntityPermissionType.Read, 'AND');
41676
41666
  const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
41677
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Tasks', rows, this.GetUserFromPayload(userPayload));
41667
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Projects', rows, this.GetUserFromPayload(userPayload));
41678
41668
  return result;
41679
41669
  }
41680
41670
 
@@ -41688,6 +41678,16 @@ export class MJEnvironmentResolver extends ResolverBase {
41688
41678
  return result;
41689
41679
  }
41690
41680
 
41681
+ @FieldResolver(() => [MJTask_])
41682
+ async MJTasks_EnvironmentIDArray(@Root() mjenvironment_: MJEnvironment_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
41683
+ this.CheckUserReadPermissions('MJ: Tasks', userPayload);
41684
+ const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
41685
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwTasks')} WHERE ${provider.QuoteIdentifier('EnvironmentID')}='${mjenvironment_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Tasks', userPayload, EntityPermissionType.Read, 'AND');
41686
+ const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
41687
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Tasks', rows, this.GetUserFromPayload(userPayload));
41688
+ return result;
41689
+ }
41690
+
41691
41691
  @FieldResolver(() => [MJReport_])
41692
41692
  async MJReports_EnvironmentIDArray(@Root() mjenvironment_: MJEnvironment_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
41693
41693
  this.CheckUserReadPermissions('MJ: Reports', userPayload);
@@ -43229,12 +43229,12 @@ export class MJGeneratedCodeCategory_ {
43229
43229
  @MaxLength(36)
43230
43230
  RootParentID?: string;
43231
43231
 
43232
- @Field(() => [MJGeneratedCode_])
43233
- MJGeneratedCodes_CategoryIDArray: MJGeneratedCode_[]; // Link to MJGeneratedCodes
43234
-
43235
43232
  @Field(() => [MJGeneratedCodeCategory_])
43236
43233
  MJGeneratedCodeCategories_ParentIDArray: MJGeneratedCodeCategory_[]; // Link to MJGeneratedCodeCategories
43237
43234
 
43235
+ @Field(() => [MJGeneratedCode_])
43236
+ MJGeneratedCodes_CategoryIDArray: MJGeneratedCode_[]; // Link to MJGeneratedCodes
43237
+
43238
43238
  }
43239
43239
 
43240
43240
  //****************************************************************************
@@ -43334,16 +43334,6 @@ export class MJGeneratedCodeCategoryResolver extends ResolverBase {
43334
43334
  return result;
43335
43335
  }
43336
43336
 
43337
- @FieldResolver(() => [MJGeneratedCode_])
43338
- async MJGeneratedCodes_CategoryIDArray(@Root() mjgeneratedcodecategory_: MJGeneratedCodeCategory_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
43339
- this.CheckUserReadPermissions('MJ: Generated Codes', userPayload);
43340
- const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
43341
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwGeneratedCodes')} WHERE ${provider.QuoteIdentifier('CategoryID')}='${mjgeneratedcodecategory_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Generated Codes', userPayload, EntityPermissionType.Read, 'AND');
43342
- const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
43343
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Generated Codes', rows, this.GetUserFromPayload(userPayload));
43344
- return result;
43345
- }
43346
-
43347
43337
  @FieldResolver(() => [MJGeneratedCodeCategory_])
43348
43338
  async MJGeneratedCodeCategories_ParentIDArray(@Root() mjgeneratedcodecategory_: MJGeneratedCodeCategory_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
43349
43339
  this.CheckUserReadPermissions('MJ: Generated Code Categories', userPayload);
@@ -43354,6 +43344,16 @@ export class MJGeneratedCodeCategoryResolver extends ResolverBase {
43354
43344
  return result;
43355
43345
  }
43356
43346
 
43347
+ @FieldResolver(() => [MJGeneratedCode_])
43348
+ async MJGeneratedCodes_CategoryIDArray(@Root() mjgeneratedcodecategory_: MJGeneratedCodeCategory_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
43349
+ this.CheckUserReadPermissions('MJ: Generated Codes', userPayload);
43350
+ const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
43351
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwGeneratedCodes')} WHERE ${provider.QuoteIdentifier('CategoryID')}='${mjgeneratedcodecategory_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Generated Codes', userPayload, EntityPermissionType.Read, 'AND');
43352
+ const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
43353
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Generated Codes', rows, this.GetUserFromPayload(userPayload));
43354
+ return result;
43355
+ }
43356
+
43357
43357
  @Mutation(() => MJGeneratedCodeCategory_)
43358
43358
  async CreateMJGeneratedCodeCategory(
43359
43359
  @Arg('input', () => CreateMJGeneratedCodeCategoryInput) input: CreateMJGeneratedCodeCategoryInput,
@@ -46769,12 +46769,12 @@ export class MJMCPServerConnection_ {
46769
46769
  @Field(() => [MJMCPToolExecutionLog_])
46770
46770
  MJMCPToolExecutionLogs_MCPServerConnectionIDArray: MJMCPToolExecutionLog_[]; // Link to MJMCPToolExecutionLogs
46771
46771
 
46772
- @Field(() => [MJOAuthToken_])
46773
- MJOAuthTokens_MCPServerConnectionIDArray: MJOAuthToken_[]; // Link to MJOAuthTokens
46774
-
46775
46772
  @Field(() => [MJOAuthClientRegistration_])
46776
46773
  MJOAuthClientRegistrations_MCPServerConnectionIDArray: MJOAuthClientRegistration_[]; // Link to MJOAuthClientRegistrations
46777
46774
 
46775
+ @Field(() => [MJOAuthToken_])
46776
+ MJOAuthTokens_MCPServerConnectionIDArray: MJOAuthToken_[]; // Link to MJOAuthTokens
46777
+
46778
46778
  @Field(() => [MJOAuthAuthorizationState_])
46779
46779
  MJOAuthAuthorizationStates_MCPServerConnectionIDArray: MJOAuthAuthorizationState_[]; // Link to MJOAuthAuthorizationStates
46780
46780
 
@@ -46978,16 +46978,6 @@ export class MJMCPServerConnectionResolver extends ResolverBase {
46978
46978
  return result;
46979
46979
  }
46980
46980
 
46981
- @FieldResolver(() => [MJOAuthToken_])
46982
- async MJOAuthTokens_MCPServerConnectionIDArray(@Root() mjmcpserverconnection_: MJMCPServerConnection_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
46983
- this.CheckUserReadPermissions('MJ: O Auth Tokens', userPayload);
46984
- const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
46985
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwOAuthTokens')} WHERE ${provider.QuoteIdentifier('MCPServerConnectionID')}='${mjmcpserverconnection_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: O Auth Tokens', userPayload, EntityPermissionType.Read, 'AND');
46986
- const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
46987
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: O Auth Tokens', rows, this.GetUserFromPayload(userPayload));
46988
- return result;
46989
- }
46990
-
46991
46981
  @FieldResolver(() => [MJOAuthClientRegistration_])
46992
46982
  async MJOAuthClientRegistrations_MCPServerConnectionIDArray(@Root() mjmcpserverconnection_: MJMCPServerConnection_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
46993
46983
  this.CheckUserReadPermissions('MJ: O Auth Client Registrations', userPayload);
@@ -46998,6 +46988,16 @@ export class MJMCPServerConnectionResolver extends ResolverBase {
46998
46988
  return result;
46999
46989
  }
47000
46990
 
46991
+ @FieldResolver(() => [MJOAuthToken_])
46992
+ async MJOAuthTokens_MCPServerConnectionIDArray(@Root() mjmcpserverconnection_: MJMCPServerConnection_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
46993
+ this.CheckUserReadPermissions('MJ: O Auth Tokens', userPayload);
46994
+ const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
46995
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwOAuthTokens')} WHERE ${provider.QuoteIdentifier('MCPServerConnectionID')}='${mjmcpserverconnection_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: O Auth Tokens', userPayload, EntityPermissionType.Read, 'AND');
46996
+ const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
46997
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: O Auth Tokens', rows, this.GetUserFromPayload(userPayload));
46998
+ return result;
46999
+ }
47000
+
47001
47001
  @FieldResolver(() => [MJOAuthAuthorizationState_])
47002
47002
  async MJOAuthAuthorizationStates_MCPServerConnectionIDArray(@Root() mjmcpserverconnection_: MJMCPServerConnection_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
47003
47003
  this.CheckUserReadPermissions('MJ: O Auth Authorization States', userPayload);
@@ -63429,12 +63429,12 @@ export class MJTestType_ {
63429
63429
  @Field({nullable: true, description: `JSON schema defining the variables available for tests of this type. Contains schemaVersion and array of variable definitions with name, displayName, description, dataType, valueSource, possibleValues, defaultValue, and required fields.`})
63430
63430
  VariablesSchema?: string;
63431
63431
 
63432
- @Field(() => [MJTest_])
63433
- MJTests_TypeIDArray: MJTest_[]; // Link to MJTests
63434
-
63435
63432
  @Field(() => [MJTestRubric_])
63436
63433
  MJTestRubrics_TypeIDArray: MJTestRubric_[]; // Link to MJTestRubrics
63437
63434
 
63435
+ @Field(() => [MJTest_])
63436
+ MJTests_TypeIDArray: MJTest_[]; // Link to MJTests
63437
+
63438
63438
  }
63439
63439
 
63440
63440
  //****************************************************************************
@@ -63546,16 +63546,6 @@ export class MJTestTypeResolver extends ResolverBase {
63546
63546
  return result;
63547
63547
  }
63548
63548
 
63549
- @FieldResolver(() => [MJTest_])
63550
- async MJTests_TypeIDArray(@Root() mjtesttype_: MJTestType_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
63551
- this.CheckUserReadPermissions('MJ: Tests', userPayload);
63552
- const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
63553
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwTests')} WHERE ${provider.QuoteIdentifier('TypeID')}='${mjtesttype_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Tests', userPayload, EntityPermissionType.Read, 'AND');
63554
- const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
63555
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Tests', rows, this.GetUserFromPayload(userPayload));
63556
- return result;
63557
- }
63558
-
63559
63549
  @FieldResolver(() => [MJTestRubric_])
63560
63550
  async MJTestRubrics_TypeIDArray(@Root() mjtesttype_: MJTestType_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
63561
63551
  this.CheckUserReadPermissions('MJ: Test Rubrics', userPayload);
@@ -63566,6 +63556,16 @@ export class MJTestTypeResolver extends ResolverBase {
63566
63556
  return result;
63567
63557
  }
63568
63558
 
63559
+ @FieldResolver(() => [MJTest_])
63560
+ async MJTests_TypeIDArray(@Root() mjtesttype_: MJTestType_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
63561
+ this.CheckUserReadPermissions('MJ: Tests', userPayload);
63562
+ const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
63563
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwTests')} WHERE ${provider.QuoteIdentifier('TypeID')}='${mjtesttype_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Tests', userPayload, EntityPermissionType.Read, 'AND');
63564
+ const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
63565
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Tests', rows, this.GetUserFromPayload(userPayload));
63566
+ return result;
63567
+ }
63568
+
63569
63569
  @Mutation(() => MJTestType_)
63570
63570
  async CreateMJTestType(
63571
63571
  @Arg('input', () => CreateMJTestTypeInput) input: CreateMJTestTypeInput,
@@ -66722,12 +66722,12 @@ export class MJUser_ {
66722
66722
  @Field(() => [MJResourceLink_])
66723
66723
  MJResourceLinks_UserIDArray: MJResourceLink_[]; // Link to MJResourceLinks
66724
66724
 
66725
- @Field(() => [MJAIAgentRequest_])
66726
- MJAIAgentRequests_RequestForUserIDArray: MJAIAgentRequest_[]; // Link to MJAIAgentRequests
66727
-
66728
66725
  @Field(() => [MJAIAgentNote_])
66729
66726
  MJAIAgentNotes_UserIDArray: MJAIAgentNote_[]; // Link to MJAIAgentNotes
66730
66727
 
66728
+ @Field(() => [MJAIAgentRequest_])
66729
+ MJAIAgentRequests_RequestForUserIDArray: MJAIAgentRequest_[]; // Link to MJAIAgentRequests
66730
+
66731
66731
  @Field(() => [MJReportUserState_])
66732
66732
  MJReportUserStates_UserIDArray: MJReportUserState_[]; // Link to MJReportUserStates
66733
66733
 
@@ -66773,12 +66773,12 @@ export class MJUser_ {
66773
66773
  @Field(() => [MJListShare_])
66774
66774
  MJListShares_UserIDArray: MJListShare_[]; // Link to MJListShares
66775
66775
 
66776
- @Field(() => [MJDashboardCategoryPermission_])
66777
- MJDashboardCategoryPermissions_SharedByUserIDArray: MJDashboardCategoryPermission_[]; // Link to MJDashboardCategoryPermissions
66778
-
66779
66776
  @Field(() => [MJDashboardCategoryLink_])
66780
66777
  MJDashboardCategoryLinks_UserIDArray: MJDashboardCategoryLink_[]; // Link to MJDashboardCategoryLinks
66781
66778
 
66779
+ @Field(() => [MJDashboardCategoryPermission_])
66780
+ MJDashboardCategoryPermissions_SharedByUserIDArray: MJDashboardCategoryPermission_[]; // Link to MJDashboardCategoryPermissions
66781
+
66782
66782
  @Field(() => [MJDashboardPermission_])
66783
66783
  MJDashboardPermissions_UserIDArray: MJDashboardPermission_[]; // Link to MJDashboardPermissions
66784
66784
 
@@ -66830,12 +66830,12 @@ export class MJUser_ {
66830
66830
  @Field(() => [MJTestRun_])
66831
66831
  MJTestRuns_RunByUserIDArray: MJTestRun_[]; // Link to MJTestRuns
66832
66832
 
66833
- @Field(() => [MJDashboardPermission_])
66834
- MJDashboardPermissions_SharedByUserIDArray: MJDashboardPermission_[]; // Link to MJDashboardPermissions
66835
-
66836
66833
  @Field(() => [MJDashboardCategoryPermission_])
66837
66834
  MJDashboardCategoryPermissions_UserIDArray: MJDashboardCategoryPermission_[]; // Link to MJDashboardCategoryPermissions
66838
66835
 
66836
+ @Field(() => [MJDashboardPermission_])
66837
+ MJDashboardPermissions_SharedByUserIDArray: MJDashboardPermission_[]; // Link to MJDashboardPermissions
66838
+
66839
66839
  @Field(() => [MJAPIKey_])
66840
66840
  MJAPIKeys_UserIDArray: MJAPIKey_[]; // Link to MJAPIKeys
66841
66841
 
@@ -66854,12 +66854,12 @@ export class MJUser_ {
66854
66854
  @Field(() => [MJAIAgentPermission_])
66855
66855
  MJAIAgentPermissions_UserIDArray: MJAIAgentPermission_[]; // Link to MJAIAgentPermissions
66856
66856
 
66857
- @Field(() => [MJCollection_])
66858
- MJCollections_OwnerIDArray: MJCollection_[]; // Link to MJCollections
66859
-
66860
66857
  @Field(() => [MJCollectionPermission_])
66861
66858
  MJCollectionPermissions_SharedByUserIDArray: MJCollectionPermission_[]; // Link to MJCollectionPermissions
66862
66859
 
66860
+ @Field(() => [MJCollection_])
66861
+ MJCollections_OwnerIDArray: MJCollection_[]; // Link to MJCollections
66862
+
66863
66863
  @Field(() => [MJRecordMergeLog_])
66864
66864
  MJRecordMergeLogs_InitiatedByUserIDArray: MJRecordMergeLog_[]; // Link to MJRecordMergeLogs
66865
66865
 
@@ -67371,16 +67371,6 @@ export class MJUserResolverBase extends ResolverBase {
67371
67371
  return result;
67372
67372
  }
67373
67373
 
67374
- @FieldResolver(() => [MJAIAgentRequest_])
67375
- async MJAIAgentRequests_RequestForUserIDArray(@Root() mjuser_: MJUser_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
67376
- this.CheckUserReadPermissions('MJ: AI Agent Requests', userPayload);
67377
- const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
67378
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwAIAgentRequests')} WHERE ${provider.QuoteIdentifier('RequestForUserID')}='${mjuser_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Agent Requests', userPayload, EntityPermissionType.Read, 'AND');
67379
- const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
67380
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: AI Agent Requests', rows, this.GetUserFromPayload(userPayload));
67381
- return result;
67382
- }
67383
-
67384
67374
  @FieldResolver(() => [MJAIAgentNote_])
67385
67375
  async MJAIAgentNotes_UserIDArray(@Root() mjuser_: MJUser_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
67386
67376
  this.CheckUserReadPermissions('MJ: AI Agent Notes', userPayload);
@@ -67391,6 +67381,16 @@ export class MJUserResolverBase extends ResolverBase {
67391
67381
  return result;
67392
67382
  }
67393
67383
 
67384
+ @FieldResolver(() => [MJAIAgentRequest_])
67385
+ async MJAIAgentRequests_RequestForUserIDArray(@Root() mjuser_: MJUser_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
67386
+ this.CheckUserReadPermissions('MJ: AI Agent Requests', userPayload);
67387
+ const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
67388
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwAIAgentRequests')} WHERE ${provider.QuoteIdentifier('RequestForUserID')}='${mjuser_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Agent Requests', userPayload, EntityPermissionType.Read, 'AND');
67389
+ const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
67390
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: AI Agent Requests', rows, this.GetUserFromPayload(userPayload));
67391
+ return result;
67392
+ }
67393
+
67394
67394
  @FieldResolver(() => [MJReportUserState_])
67395
67395
  async MJReportUserStates_UserIDArray(@Root() mjuser_: MJUser_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
67396
67396
  this.CheckUserReadPermissions('MJ: Report User States', userPayload);
@@ -67541,16 +67541,6 @@ export class MJUserResolverBase extends ResolverBase {
67541
67541
  return result;
67542
67542
  }
67543
67543
 
67544
- @FieldResolver(() => [MJDashboardCategoryPermission_])
67545
- async MJDashboardCategoryPermissions_SharedByUserIDArray(@Root() mjuser_: MJUser_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
67546
- this.CheckUserReadPermissions('MJ: Dashboard Category Permissions', userPayload);
67547
- const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
67548
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwDashboardCategoryPermissions')} WHERE ${provider.QuoteIdentifier('SharedByUserID')}='${mjuser_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Dashboard Category Permissions', userPayload, EntityPermissionType.Read, 'AND');
67549
- const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
67550
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Dashboard Category Permissions', rows, this.GetUserFromPayload(userPayload));
67551
- return result;
67552
- }
67553
-
67554
67544
  @FieldResolver(() => [MJDashboardCategoryLink_])
67555
67545
  async MJDashboardCategoryLinks_UserIDArray(@Root() mjuser_: MJUser_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
67556
67546
  this.CheckUserReadPermissions('MJ: Dashboard Category Links', userPayload);
@@ -67561,6 +67551,16 @@ export class MJUserResolverBase extends ResolverBase {
67561
67551
  return result;
67562
67552
  }
67563
67553
 
67554
+ @FieldResolver(() => [MJDashboardCategoryPermission_])
67555
+ async MJDashboardCategoryPermissions_SharedByUserIDArray(@Root() mjuser_: MJUser_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
67556
+ this.CheckUserReadPermissions('MJ: Dashboard Category Permissions', userPayload);
67557
+ const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
67558
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwDashboardCategoryPermissions')} WHERE ${provider.QuoteIdentifier('SharedByUserID')}='${mjuser_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Dashboard Category Permissions', userPayload, EntityPermissionType.Read, 'AND');
67559
+ const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
67560
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Dashboard Category Permissions', rows, this.GetUserFromPayload(userPayload));
67561
+ return result;
67562
+ }
67563
+
67564
67564
  @FieldResolver(() => [MJDashboardPermission_])
67565
67565
  async MJDashboardPermissions_UserIDArray(@Root() mjuser_: MJUser_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
67566
67566
  this.CheckUserReadPermissions('MJ: Dashboard Permissions', userPayload);
@@ -67731,16 +67731,6 @@ export class MJUserResolverBase extends ResolverBase {
67731
67731
  return result;
67732
67732
  }
67733
67733
 
67734
- @FieldResolver(() => [MJDashboardPermission_])
67735
- async MJDashboardPermissions_SharedByUserIDArray(@Root() mjuser_: MJUser_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
67736
- this.CheckUserReadPermissions('MJ: Dashboard Permissions', userPayload);
67737
- const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
67738
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwDashboardPermissions')} WHERE ${provider.QuoteIdentifier('SharedByUserID')}='${mjuser_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Dashboard Permissions', userPayload, EntityPermissionType.Read, 'AND');
67739
- const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
67740
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Dashboard Permissions', rows, this.GetUserFromPayload(userPayload));
67741
- return result;
67742
- }
67743
-
67744
67734
  @FieldResolver(() => [MJDashboardCategoryPermission_])
67745
67735
  async MJDashboardCategoryPermissions_UserIDArray(@Root() mjuser_: MJUser_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
67746
67736
  this.CheckUserReadPermissions('MJ: Dashboard Category Permissions', userPayload);
@@ -67751,6 +67741,16 @@ export class MJUserResolverBase extends ResolverBase {
67751
67741
  return result;
67752
67742
  }
67753
67743
 
67744
+ @FieldResolver(() => [MJDashboardPermission_])
67745
+ async MJDashboardPermissions_SharedByUserIDArray(@Root() mjuser_: MJUser_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
67746
+ this.CheckUserReadPermissions('MJ: Dashboard Permissions', userPayload);
67747
+ const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
67748
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwDashboardPermissions')} WHERE ${provider.QuoteIdentifier('SharedByUserID')}='${mjuser_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Dashboard Permissions', userPayload, EntityPermissionType.Read, 'AND');
67749
+ const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
67750
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Dashboard Permissions', rows, this.GetUserFromPayload(userPayload));
67751
+ return result;
67752
+ }
67753
+
67754
67754
  @FieldResolver(() => [MJAPIKey_])
67755
67755
  async MJAPIKeys_UserIDArray(@Root() mjuser_: MJUser_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
67756
67756
  this.CheckUserReadPermissions('MJ: API Keys', userPayload);
@@ -67811,16 +67811,6 @@ export class MJUserResolverBase extends ResolverBase {
67811
67811
  return result;
67812
67812
  }
67813
67813
 
67814
- @FieldResolver(() => [MJCollection_])
67815
- async MJCollections_OwnerIDArray(@Root() mjuser_: MJUser_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
67816
- this.CheckUserReadPermissions('MJ: Collections', userPayload);
67817
- const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
67818
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwCollections')} WHERE ${provider.QuoteIdentifier('OwnerID')}='${mjuser_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Collections', userPayload, EntityPermissionType.Read, 'AND');
67819
- const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
67820
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Collections', rows, this.GetUserFromPayload(userPayload));
67821
- return result;
67822
- }
67823
-
67824
67814
  @FieldResolver(() => [MJCollectionPermission_])
67825
67815
  async MJCollectionPermissions_SharedByUserIDArray(@Root() mjuser_: MJUser_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
67826
67816
  this.CheckUserReadPermissions('MJ: Collection Permissions', userPayload);
@@ -67831,6 +67821,16 @@ export class MJUserResolverBase extends ResolverBase {
67831
67821
  return result;
67832
67822
  }
67833
67823
 
67824
+ @FieldResolver(() => [MJCollection_])
67825
+ async MJCollections_OwnerIDArray(@Root() mjuser_: MJUser_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
67826
+ this.CheckUserReadPermissions('MJ: Collections', userPayload);
67827
+ const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
67828
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwCollections')} WHERE ${provider.QuoteIdentifier('OwnerID')}='${mjuser_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Collections', userPayload, EntityPermissionType.Read, 'AND');
67829
+ const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
67830
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Collections', rows, this.GetUserFromPayload(userPayload));
67831
+ return result;
67832
+ }
67833
+
67834
67834
  @FieldResolver(() => [MJRecordMergeLog_])
67835
67835
  async MJRecordMergeLogs_InitiatedByUserIDArray(@Root() mjuser_: MJUser_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
67836
67836
  this.CheckUserReadPermissions('MJ: Record Merge Logs', userPayload);
@@ -68960,14 +68960,14 @@ export class MJVersionLabel_ {
68960
68960
  @Field(() => [MJVersionLabelRestore_])
68961
68961
  MJVersionLabelRestores_VersionLabelIDArray: MJVersionLabelRestore_[]; // Link to MJVersionLabelRestores
68962
68962
 
68963
- @Field(() => [MJVersionLabel_])
68964
- MJVersionLabels_ParentIDArray: MJVersionLabel_[]; // Link to MJVersionLabels
68963
+ @Field(() => [MJVersionLabelItem_])
68964
+ MJVersionLabelItems_VersionLabelIDArray: MJVersionLabelItem_[]; // Link to MJVersionLabelItems
68965
68965
 
68966
68966
  @Field(() => [MJVersionLabelRestore_])
68967
68967
  MJVersionLabelRestores_PreRestoreLabelIDArray: MJVersionLabelRestore_[]; // Link to MJVersionLabelRestores
68968
68968
 
68969
- @Field(() => [MJVersionLabelItem_])
68970
- MJVersionLabelItems_VersionLabelIDArray: MJVersionLabelItem_[]; // Link to MJVersionLabelItems
68969
+ @Field(() => [MJVersionLabel_])
68970
+ MJVersionLabels_ParentIDArray: MJVersionLabel_[]; // Link to MJVersionLabels
68971
68971
 
68972
68972
  }
68973
68973
 
@@ -69126,13 +69126,13 @@ export class MJVersionLabelResolver extends ResolverBase {
69126
69126
  return result;
69127
69127
  }
69128
69128
 
69129
- @FieldResolver(() => [MJVersionLabel_])
69130
- async MJVersionLabels_ParentIDArray(@Root() mjversionlabel_: MJVersionLabel_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
69131
- this.CheckUserReadPermissions('MJ: Version Labels', userPayload);
69129
+ @FieldResolver(() => [MJVersionLabelItem_])
69130
+ async MJVersionLabelItems_VersionLabelIDArray(@Root() mjversionlabel_: MJVersionLabel_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
69131
+ this.CheckUserReadPermissions('MJ: Version Label Items', userPayload);
69132
69132
  const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
69133
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwVersionLabels')} WHERE ${provider.QuoteIdentifier('ParentID')}='${mjversionlabel_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Version Labels', userPayload, EntityPermissionType.Read, 'AND');
69133
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwVersionLabelItems')} WHERE ${provider.QuoteIdentifier('VersionLabelID')}='${mjversionlabel_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Version Label Items', userPayload, EntityPermissionType.Read, 'AND');
69134
69134
  const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
69135
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Version Labels', rows, this.GetUserFromPayload(userPayload));
69135
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Version Label Items', rows, this.GetUserFromPayload(userPayload));
69136
69136
  return result;
69137
69137
  }
69138
69138
 
@@ -69146,13 +69146,13 @@ export class MJVersionLabelResolver extends ResolverBase {
69146
69146
  return result;
69147
69147
  }
69148
69148
 
69149
- @FieldResolver(() => [MJVersionLabelItem_])
69150
- async MJVersionLabelItems_VersionLabelIDArray(@Root() mjversionlabel_: MJVersionLabel_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
69151
- this.CheckUserReadPermissions('MJ: Version Label Items', userPayload);
69149
+ @FieldResolver(() => [MJVersionLabel_])
69150
+ async MJVersionLabels_ParentIDArray(@Root() mjversionlabel_: MJVersionLabel_, @Ctx() { userPayload, providers }: AppContext, @PubSub() pubSub: PubSubEngine) {
69151
+ this.CheckUserReadPermissions('MJ: Version Labels', userPayload);
69152
69152
  const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
69153
- const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwVersionLabelItems')} WHERE ${provider.QuoteIdentifier('VersionLabelID')}='${mjversionlabel_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Version Label Items', userPayload, EntityPermissionType.Read, 'AND');
69153
+ const sSQL = `SELECT * FROM ${provider.QuoteSchemaAndView(Metadata.Provider.ConfigData.MJCoreSchemaName, 'vwVersionLabels')} WHERE ${provider.QuoteIdentifier('ParentID')}='${mjversionlabel_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Version Labels', userPayload, EntityPermissionType.Read, 'AND');
69154
69154
  const rows = await provider.ExecuteSQL(sSQL, undefined, undefined, this.GetUserFromPayload(userPayload));
69155
- const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Version Label Items', rows, this.GetUserFromPayload(userPayload));
69155
+ const result = await this.ArrayMapFieldNamesToCodeNames('MJ: Version Labels', rows, this.GetUserFromPayload(userPayload));
69156
69156
  return result;
69157
69157
  }
69158
69158